From 1f8761d4b0b1047e0d1651bff7be19a2bbd34a4a Mon Sep 17 00:00:00 2001 From: Andy Xie Date: Sun, 30 Jul 2017 14:42:20 +0800 Subject: [PATCH] bump client go to v4.0.0-beta.0 to support kubernetes 1.7 --- Godeps/Godeps.json | 1144 +- collectors/cronjob.go | 4 +- collectors/cronjob_test.go | 62 +- collectors/daemonset_test.go | 6 +- collectors/deployment.go | 2 +- collectors/deployment_test.go | 16 +- collectors/job_test.go | 103 +- collectors/limitrange_test.go | 5 +- collectors/node_test.go | 37 +- collectors/persistentvolumeclaim_test.go | 7 +- collectors/pod_test.go | 43 +- collectors/replicaset_test.go | 6 +- collectors/replicationcontroller_test.go | 5 +- collectors/resourcequota_test.go | 7 +- collectors/service_test.go | 3 +- collectors/statefulset_test.go | 8 +- vendor/github.com/blang/semver/LICENSE | 22 - vendor/github.com/blang/semver/README.md | 142 - vendor/github.com/blang/semver/json.go | 23 - vendor/github.com/blang/semver/semver.go | 395 - vendor/github.com/blang/semver/sort.go | 28 - vendor/github.com/blang/semver/sql.go | 30 - vendor/github.com/coreos/go-oidc/NOTICE | 5 - .../github.com/coreos/go-oidc/http/client.go | 7 - vendor/github.com/coreos/go-oidc/http/http.go | 156 - vendor/github.com/coreos/go-oidc/http/url.go | 29 - .../github.com/coreos/go-oidc/jose/claims.go | 126 - vendor/github.com/coreos/go-oidc/jose/jose.go | 112 - vendor/github.com/coreos/go-oidc/jose/jwk.go | 135 - vendor/github.com/coreos/go-oidc/jose/jws.go | 51 - vendor/github.com/coreos/go-oidc/jose/jwt.go | 82 - vendor/github.com/coreos/go-oidc/jose/sig.go | 24 - .../github.com/coreos/go-oidc/jose/sig_rsa.go | 67 - vendor/github.com/coreos/go-oidc/key/key.go | 153 - .../github.com/coreos/go-oidc/key/manager.go | 99 - vendor/github.com/coreos/go-oidc/key/repo.go | 55 - .../github.com/coreos/go-oidc/key/rotate.go | 159 - vendor/github.com/coreos/go-oidc/key/sync.go | 91 - .../github.com/coreos/go-oidc/oauth2/error.go | 29 - .../coreos/go-oidc/oauth2/oauth2.go | 416 - .../github.com/coreos/go-oidc/oidc/client.go | 846 - .../coreos/go-oidc/oidc/identity.go | 44 - .../coreos/go-oidc/oidc/interface.go | 3 - vendor/github.com/coreos/go-oidc/oidc/key.go | 67 - .../coreos/go-oidc/oidc/provider.go | 690 - .../coreos/go-oidc/oidc/transport.go | 88 - vendor/github.com/coreos/go-oidc/oidc/util.go | 109 - .../coreos/go-oidc/oidc/verification.go | 190 - vendor/github.com/coreos/pkg/NOTICE | 5 - vendor/github.com/coreos/pkg/health/README.md | 11 - vendor/github.com/coreos/pkg/health/health.go | 127 - .../github.com/coreos/pkg/httputil/README.md | 13 - .../github.com/coreos/pkg/httputil/cookie.go | 21 - vendor/github.com/coreos/pkg/httputil/json.go | 27 - .../github.com/coreos/pkg/timeutil/backoff.go | 15 - .../emicklei/go-restful-swagger12/.travis.yml | 4 + .../CHANGES.md | 3 + .../emicklei/go-restful-swagger12/LICENSE | 22 + .../README.md | 7 + .../api_declaration_list.go | 0 .../config.go | 10 +- .../model_builder.go | 38 +- .../model_list.go | 0 .../model_property_ext.go | 15 + .../model_property_list.go | 0 .../ordered_route_map.go | 0 .../swagger.go | 0 .../swagger_builder.go | 0 .../swagger_webservice.go | 23 +- .../github.com/go-openapi/analysis/.drone.sec | 1 + .../github.com/go-openapi/analysis/.drone.yml | 36 + .../github.com/go-openapi/analysis/.gitignore | 2 + .../go-openapi/analysis/.pullapprove.yml | 12 + .../go-openapi/analysis/CODE_OF_CONDUCT.md | 74 + .../go-openapi/analysis}/LICENSE | 2 +- .../github.com/go-openapi/analysis/README.md | 6 + .../go-openapi/analysis/analyzer.go | 614 + vendor/github.com/go-openapi/loads/.drone.sec | 1 + vendor/github.com/go-openapi/loads/.drone.yml | 39 + vendor/github.com/go-openapi/loads/.gitignore | 4 + .../go-openapi/loads/.pullapprove.yml | 13 + .../go-openapi/loads/CODE_OF_CONDUCT.md | 74 + .../go-openapi/loads}/LICENSE | 2 +- vendor/github.com/go-openapi/loads/README.md | 5 + vendor/github.com/go-openapi/loads/spec.go | 203 + vendor/github.com/gogo/protobuf/LICENSE | 6 +- .../github.com/gogo/protobuf/proto/Makefile | 2 +- .../github.com/gogo/protobuf/proto/clone.go | 14 +- .../github.com/gogo/protobuf/proto/decode.go | 137 +- .../gogo/protobuf/proto/decode_gogo.go | 11 +- .../gogo/protobuf/proto/duration.go | 100 + .../gogo/protobuf/proto/duration_gogo.go | 203 + .../github.com/gogo/protobuf/proto/encode.go | 73 +- .../gogo/protobuf/proto/encode_gogo.go | 22 +- .../github.com/gogo/protobuf/proto/equal.go | 34 +- .../gogo/protobuf/proto/extensions.go | 413 +- .../gogo/protobuf/proto/extensions_gogo.go | 88 +- vendor/github.com/gogo/protobuf/proto/lib.go | 6 +- .../gogo/protobuf/proto/lib_gogo.go | 6 +- .../gogo/protobuf/proto/message_set.go | 43 +- .../gogo/protobuf/proto/pointer_reflect.go | 7 +- .../protobuf/proto/pointer_reflect_gogo.go | 85 + .../gogo/protobuf/proto/pointer_unsafe.go | 6 +- .../protobuf/proto/pointer_unsafe_gogo.go | 42 +- .../gogo/protobuf/proto/properties.go | 93 +- .../gogo/protobuf/proto/properties_gogo.go | 51 +- .../gogo/protobuf/proto/skip_gogo.go | 6 +- vendor/github.com/gogo/protobuf/proto/text.go | 213 +- .../gogo/protobuf/proto/text_gogo.go | 12 +- .../gogo/protobuf/proto/text_parser.go | 270 +- .../gogo/protobuf/proto/timestamp.go | 113 + .../gogo/protobuf/proto/timestamp_gogo.go | 229 + .../gogo/protobuf/sortkeys/sortkeys.go | 4 +- .../golang-lru}/.gitignore | 2 - vendor/github.com/hashicorp/golang-lru/2q.go | 212 + .../github.com/hashicorp/golang-lru/LICENSE | 362 + .../github.com/hashicorp/golang-lru/README.md | 25 + vendor/github.com/hashicorp/golang-lru/arc.go | 257 + vendor/github.com/hashicorp/golang-lru/lru.go | 114 + .../hashicorp/golang-lru/simplelru/lru.go | 160 + .../jonboulle/clockwork/.travis.yml | 5 - vendor/github.com/jonboulle/clockwork/LICENSE | 201 - .../github.com/jonboulle/clockwork/README.md | 69 - .../jonboulle/clockwork/clockwork.go | 179 - vendor/github.com/juju/ratelimit/ratelimit.go | 59 +- vendor/github.com/pborman/uuid/CONTRIBUTORS | 1 - vendor/github.com/pborman/uuid/LICENSE | 27 - vendor/github.com/pborman/uuid/dce.go | 84 - vendor/github.com/pborman/uuid/doc.go | 8 - vendor/github.com/pborman/uuid/hash.go | 53 - vendor/github.com/pborman/uuid/json.go | 30 - vendor/github.com/pborman/uuid/node.go | 101 - vendor/github.com/pborman/uuid/time.go | 132 - vendor/github.com/pborman/uuid/util.go | 43 - vendor/github.com/pborman/uuid/uuid.go | 163 - vendor/github.com/pborman/uuid/version1.go | 41 - vendor/github.com/pborman/uuid/version4.go | 25 - .../prometheus/client_golang/AUTHORS.md | 18 - .../client_golang/prometheus/registry.go | 28 +- .../prometheus/procfs/MAINTAINERS.md | 1 - .../github.com/prometheus/procfs/buddyinfo.go | 95 - .../prometheus/procfs/mountstats.go | 556 - .../github.com/prometheus/procfs/xfs/parse.go | 359 - .../github.com/prometheus/procfs/xfs/xfs.go | 163 - vendor/github.com/robfig/cron/.gitignore | 22 + vendor/github.com/robfig/cron/.travis.yml | 1 + .../robfig/cron/constantdelay_test.go | 54 - vendor/github.com/robfig/cron/cron_test.go | 355 - vendor/github.com/robfig/cron/parser_test.go | 234 - vendor/github.com/robfig/cron/spec_test.go | 249 - vendor/github.com/spf13/pflag/.gitignore | 2 + vendor/github.com/spf13/pflag/.travis.yml | 5 +- vendor/github.com/spf13/pflag/README.md | 6 +- vendor/github.com/spf13/pflag/bool.go | 7 +- vendor/github.com/spf13/pflag/bool_slice.go | 147 + vendor/github.com/spf13/pflag/count.go | 7 +- vendor/github.com/spf13/pflag/flag.go | 219 +- vendor/github.com/spf13/pflag/float32.go | 7 +- vendor/github.com/spf13/pflag/float64.go | 7 +- vendor/github.com/spf13/pflag/golangflag.go | 3 - vendor/github.com/spf13/pflag/int.go | 7 +- vendor/github.com/spf13/pflag/int32.go | 7 +- vendor/github.com/spf13/pflag/int64.go | 7 +- vendor/github.com/spf13/pflag/int8.go | 7 +- vendor/github.com/spf13/pflag/ip.go | 2 - vendor/github.com/spf13/pflag/ip_slice.go | 148 + vendor/github.com/spf13/pflag/ipnet.go | 2 - vendor/github.com/spf13/pflag/string.go | 4 +- vendor/github.com/spf13/pflag/string_array.go | 103 + vendor/github.com/spf13/pflag/string_slice.go | 36 +- vendor/github.com/spf13/pflag/uint.go | 7 +- vendor/github.com/spf13/pflag/uint16.go | 9 +- vendor/github.com/spf13/pflag/uint32.go | 11 +- vendor/github.com/spf13/pflag/uint64.go | 7 +- vendor/github.com/spf13/pflag/uint8.go | 7 +- vendor/github.com/spf13/pflag/uint_slice.go | 126 + .../x/net/context/ctxhttp/ctxhttp.go | 64 - .../x/net/context/ctxhttp/ctxhttp_pre17.go | 147 - vendor/golang.org/x/oauth2/.travis.yml | 14 - vendor/golang.org/x/oauth2/AUTHORS | 3 - vendor/golang.org/x/oauth2/CONTRIBUTING.md | 31 - vendor/golang.org/x/oauth2/CONTRIBUTORS | 3 - vendor/golang.org/x/oauth2/LICENSE | 27 - vendor/golang.org/x/oauth2/README.md | 64 - .../golang.org/x/oauth2/client_appengine.go | 25 - .../golang.org/x/oauth2/google/appengine.go | 83 - .../x/oauth2/google/appengine_hook.go | 13 - vendor/golang.org/x/oauth2/google/default.go | 154 - vendor/golang.org/x/oauth2/google/google.go | 145 - vendor/golang.org/x/oauth2/google/sdk.go | 168 - vendor/golang.org/x/oauth2/internal/oauth2.go | 76 - vendor/golang.org/x/oauth2/internal/token.go | 213 - .../golang.org/x/oauth2/internal/transport.go | 67 - vendor/golang.org/x/oauth2/jws/jws.go | 160 - vendor/golang.org/x/oauth2/jwt/jwt.go | 147 - vendor/golang.org/x/oauth2/oauth2.go | 325 - vendor/golang.org/x/oauth2/token.go | 143 - vendor/golang.org/x/oauth2/transport.go | 132 - .../cloud/compute/metadata/metadata.go | 382 - .../google.golang.org/cloud/internal/cloud.go | 128 - .../pkg => k8s.io/apimachinery}/LICENSE | 8 +- .../apimachinery/pkg/api/equality/BUILD | 21 + .../apimachinery/pkg/api/equality/semantic.go | 46 + .../k8s.io/apimachinery/pkg/api/errors/BUILD | 37 + .../k8s.io/apimachinery/pkg/api/errors/OWNERS | 26 + .../pkg/api/errors/doc.go | 0 .../pkg/api/errors/errors.go | 216 +- vendor/k8s.io/apimachinery/pkg/api/meta/BUILD | 59 + .../k8s.io/apimachinery/pkg/api/meta/OWNERS | 26 + .../pkg/api/meta/default.go} | 27 +- .../pkg/api/meta/doc.go | 0 .../pkg/api/meta/errors.go | 18 +- .../pkg/api/meta/firsthit_restmapper.go | 14 +- .../pkg/api/meta/help.go | 17 +- .../pkg/api/meta/interfaces.go | 70 +- .../pkg/api/meta/meta.go | 101 +- .../pkg/api/meta/multirestmapper.go | 53 +- .../pkg/api/meta/priority.go | 54 +- .../pkg/api/meta/restmapper.go | 192 +- .../pkg/api/meta/unstructured.go | 10 +- .../apimachinery/pkg/api/resource/BUILD | 55 + .../apimachinery/pkg/api/resource/OWNERS | 17 + .../pkg/api/resource/amount.go | 0 .../pkg/api/resource/generated.pb.go | 77 + .../pkg/api/resource/generated.proto | 6 +- .../pkg/api/resource/math.go | 13 - .../pkg/api/resource/quantity.go | 6 +- .../pkg/api/resource/quantity_proto.go | 0 .../pkg/api/resource/scale_int.go | 0 .../pkg/api/resource/suffix.go | 0 .../apimachinery/pkg/apimachinery/BUILD | 31 + .../pkg/apimachinery/announced/BUILD | 35 + .../pkg/apimachinery/announced/announced.go | 12 +- .../apimachinery/announced/group_factory.go | 53 +- .../pkg/apimachinery/doc.go | 0 .../pkg/apimachinery/registered/BUILD | 33 + .../pkg/apimachinery/registered/registered.go | 115 +- .../pkg/apimachinery/types.go | 26 +- .../apimachinery/pkg/apis/meta/v1/BUILD | 71 + .../apimachinery/pkg/apis/meta/v1/OWNERS | 33 + .../pkg/apis/meta/v1}/conversion.go | 64 +- .../pkg/apis/meta/v1}/doc.go | 3 +- .../pkg/apis/meta/v1}/duration.go | 2 +- .../pkg/apis/meta/v1/generated.pb.go | 7516 ++ .../pkg/apis/meta/v1/generated.proto | 764 + .../pkg/apis/meta/v1/group_version.go | 148 + .../pkg/apis/meta/v1}/helpers.go | 57 +- .../pkg/apis/meta/v1}/labels.go | 65 +- .../apimachinery/pkg/apis/meta/v1/meta.go | 201 + .../pkg/apis/meta/v1/micro_time.go | 184 + .../pkg/apis/meta/v1/micro_time_proto.go | 72 + .../apimachinery/pkg/apis/meta/v1/register.go | 95 + .../pkg/apis/meta/v1}/time.go | 8 +- .../pkg/apis/meta/v1}/time_proto.go | 4 +- .../pkg/apis/meta/v1}/types.go | 383 +- .../meta/v1/types_swagger_doc_generated.go | 315 + .../pkg/apis/meta/v1/unstructured/BUILD | 32 + .../meta/v1/unstructured}/unstructured.go | 248 +- .../pkg/apis/meta/v1/watch.go} | 50 +- .../pkg/apis/meta/v1/zz_generated.deepcopy.go | 646 + .../pkg/apis/meta/v1/zz_generated.defaults.go | 32 + .../apimachinery/pkg/apis/meta/v1alpha1/BUILD | 29 + .../pkg/apis/meta}/v1alpha1/doc.go | 7 +- .../pkg/apis/meta/v1alpha1/generated.pb.go | 633 + .../pkg/apis/meta/v1alpha1/generated.proto | 55 + .../pkg/apis/meta/v1alpha1/register.go | 51 + .../pkg/apis/meta/v1alpha1/types.go | 157 + .../v1alpha1/types_swagger_doc_generated.go | 104 + .../meta/v1alpha1/zz_generated.deepcopy.go | 164 + .../meta/v1alpha1/zz_generated.defaults.go} | 18 +- .../k8s.io/apimachinery/pkg/conversion/BUILD | 38 + .../pkg/conversion/cloner.go | 0 .../pkg/conversion/converter.go | 55 - .../pkg/conversion/deep_equal.go | 2 +- .../pkg/conversion/doc.go | 0 .../pkg/conversion/helper.go | 0 .../pkg/conversion/queryparams/BUILD | 29 + .../pkg/conversion/queryparams/convert.go | 0 .../pkg/conversion/queryparams/doc.go | 0 .../pkg/conversion/unstructured/BUILD | 38 + .../pkg/conversion/unstructured/converter.go | 690 + .../pkg/conversion/unstructured/doc.go | 19 + vendor/k8s.io/apimachinery/pkg/fields/BUILD | 31 + .../pkg/fields/doc.go | 0 .../pkg/fields/fields.go | 0 .../pkg/fields/requirements.go | 2 +- .../pkg/fields/selector.go | 187 +- vendor/k8s.io/apimachinery/pkg/labels/BUILD | 39 + .../pkg/labels/doc.go | 0 .../pkg/labels/labels.go | 4 +- .../pkg/labels/selector.go | 82 +- vendor/k8s.io/apimachinery/pkg/openapi/BUILD | 21 + .../pkg/openapi}/common.go | 66 +- .../pkg/openapi}/doc.go | 4 +- vendor/k8s.io/apimachinery/pkg/runtime/BUILD | 68 + .../pkg/runtime/codec.go | 66 +- .../pkg/runtime/codec_check.go | 12 +- .../pkg/runtime/conversion.go | 2 +- .../pkg/runtime/doc.go | 0 .../pkg/runtime/embedded.go | 12 +- .../pkg/runtime/error.go | 23 +- .../pkg/runtime/extension.go | 0 .../pkg/runtime/generated.pb.go | 244 +- .../pkg/runtime/generated.proto | 9 +- .../pkg/runtime/helper.go | 10 +- .../pkg/runtime/interfaces.go | 32 +- .../pkg/runtime/register.go | 19 +- .../apimachinery/pkg/runtime/schema/BUILD | 27 + .../pkg/runtime/schema/generated.pb.go | 65 + .../pkg/runtime/schema/generated.proto | 28 + .../pkg/runtime/schema}/group_version.go | 98 +- .../pkg/runtime/schema/interfaces.go | 40 + .../pkg/runtime/scheme.go | 103 +- .../pkg/runtime/scheme_builder.go | 0 .../apimachinery/pkg/runtime/serializer/BUILD | 44 + .../pkg/runtime/serializer/codec_factory.go | 23 +- .../pkg/runtime/serializer/json/BUILD | 46 + .../pkg/runtime/serializer/json/json.go | 14 +- .../pkg/runtime/serializer/json/meta.go | 10 +- .../runtime/serializer/negotiated_codec.go | 2 +- .../pkg/runtime/serializer/protobuf/BUILD | 24 + .../pkg/runtime/serializer/protobuf/doc.go | 0 .../runtime/serializer/protobuf/protobuf.go | 20 +- .../runtime/serializer/protobuf_extension.go | 4 +- .../pkg/runtime/serializer/recognizer/BUILD | 18 + .../serializer/recognizer/recognizer.go | 6 +- .../pkg/runtime/serializer/streaming/BUILD | 31 + .../runtime/serializer/streaming/streaming.go | 8 +- .../pkg/runtime/serializer/versioning/BUILD | 32 + .../serializer/versioning/versioning.go | 24 +- .../pkg/runtime/swagger_doc_generator.go | 0 .../pkg/runtime/types.go | 13 +- .../pkg/runtime/types_proto.go | 0 .../pkg/runtime/zz_generated.deepcopy.go | 42 +- .../k8s.io/apimachinery/pkg/selection/BUILD | 14 + .../pkg/selection/operator.go | 0 vendor/k8s.io/apimachinery/pkg/types/BUILD | 20 + .../pkg/types/doc.go | 0 .../pkg/types/namespacedname.go | 0 .../pkg/types/nodename.go | 0 .../pkg/types/patch.go} | 16 +- .../pkg/types/uid.go | 0 .../k8s.io/apimachinery/pkg/util/cache/BUILD | 33 + .../apimachinery/pkg/util/cache/cache.go | 83 + .../pkg/util/cache/lruexpirecache.go | 102 + .../k8s.io/apimachinery/pkg/util/clock/BUILD | 22 + .../pkg/util/clock/clock.go | 113 +- .../k8s.io/apimachinery/pkg/util/diff/BUILD | 26 + .../pkg/util/diff/diff.go | 2 +- .../k8s.io/apimachinery/pkg/util/errors/BUILD | 25 + .../pkg/util/errors/doc.go | 0 .../pkg/util/errors/errors.go | 19 + .../k8s.io/apimachinery/pkg/util/framer/BUILD | 22 + .../pkg/util/framer/framer.go | 0 .../k8s.io/apimachinery/pkg/util/intstr/BUILD | 33 + .../pkg/util/intstr/generated.pb.go | 142 +- .../pkg/util/intstr/generated.proto | 4 +- .../pkg/util/intstr/intstr.go | 21 +- .../k8s.io/apimachinery/pkg/util/json/BUILD | 22 + .../pkg/util/json/json.go | 0 vendor/k8s.io/apimachinery/pkg/util/net/BUILD | 40 + .../pkg/util/net/http.go | 210 +- .../pkg/util/net/interface.go | 0 .../pkg/util/net/port_range.go | 0 .../pkg/util/net/port_split.go | 2 +- .../pkg/util/net/util.go | 10 + .../k8s.io/apimachinery/pkg/util/rand/BUILD | 22 + .../pkg/util/rand/rand.go | 12 +- .../apimachinery/pkg/util/runtime/BUILD | 23 + .../pkg/util/runtime/runtime.go | 35 +- .../k8s.io/apimachinery/pkg/util/sets/BUILD | 58 + .../pkg/util/sets/byte.go | 2 +- .../pkg/util/sets/doc.go | 2 +- .../pkg/util/sets/empty.go | 2 +- .../pkg/util/sets/int.go | 2 +- .../pkg/util/sets/int64.go | 2 +- .../pkg/util/sets/string.go | 2 +- .../apimachinery/pkg/util/validation/BUILD | 22 + .../pkg/util/validation/field/BUILD | 32 + .../pkg/util/validation/field/errors.go | 50 +- .../pkg/util/validation/field/path.go | 0 .../pkg/util/validation/validation.go | 63 +- .../k8s.io/apimachinery/pkg/util/wait/BUILD | 27 + .../pkg/util/wait/doc.go | 0 .../pkg/util/wait/wait.go | 37 +- .../k8s.io/apimachinery/pkg/util/yaml/BUILD | 26 + .../pkg/util/yaml/decoder.go | 42 +- vendor/k8s.io/apimachinery/pkg/version/BUILD | 17 + vendor/k8s.io/apimachinery/pkg/version/doc.go | 19 + .../k8s.io/apimachinery/pkg/version/types.go | 37 + vendor/k8s.io/apimachinery/pkg/watch/BUILD | 47 + .../pkg/watch/doc.go | 0 .../pkg/watch/filter.go | 0 .../pkg/watch/mux.go | 8 +- .../pkg/watch/streamwatcher.go | 6 +- .../pkg/watch/until.go | 8 +- .../pkg/watch/watch.go | 2 +- .../third_party/forked/golang/reflect/BUILD | 25 + .../forked/golang/reflect/deep_equal.go | 0 .../third_party/forked/golang/reflect/type.go | 0 vendor/k8s.io/client-go/LICENSE | 2 +- vendor/k8s.io/client-go/discovery/BUILD | 63 + .../client-go/discovery/discovery_client.go | 270 +- vendor/k8s.io/client-go/discovery/helper.go | 118 +- .../k8s.io/client-go/discovery/restmapper.go | 70 +- .../client-go/discovery/unstructured.go | 30 +- vendor/k8s.io/client-go/kubernetes/BUILD | 43 + .../k8s.io/client-go/kubernetes/clientset.go | 434 +- vendor/k8s.io/client-go/kubernetes/doc.go | 4 +- .../kubernetes/import_known_versions.go | 41 - .../k8s.io/client-go/kubernetes/scheme/BUILD | 43 + .../k8s.io/client-go/kubernetes/scheme/doc.go | 20 + .../client-go/kubernetes/scheme/register.go | 91 + .../admissionregistration/v1alpha1/BUILD | 29 + .../v1alpha1/admissionregistration_client.go | 93 + .../admissionregistration/v1alpha1/doc.go | 20 + .../externaladmissionhookconfiguration.go | 145 + .../v1alpha1/generated_expansion.go | 21 + .../v1alpha1/initializerconfiguration.go | 145 + .../kubernetes/typed/apps/v1beta1/BUILD | 31 + .../typed/apps/v1beta1/apps_client.go | 43 +- .../typed/apps/v1beta1/controllerrevision.go | 155 + .../typed/apps/v1beta1/deployment.go | 172 + .../kubernetes/typed/apps/v1beta1/doc.go | 4 +- .../typed/apps/v1beta1/generated_expansion.go | 8 +- .../kubernetes/typed/apps/v1beta1/scale.go | 46 + .../typed/apps/v1beta1/statefulset.go | 29 +- .../kubernetes/typed/authentication/v1/BUILD | 26 + .../v1/authentication_client.go | 88 + .../kubernetes/typed/authentication/v1/doc.go | 20 + .../authentication/v1/generated_expansion.go | 17 + .../typed/authentication/v1/tokenreview.go | 44 + .../v1/tokenreview_expansion.go | 35 + .../typed/authentication/v1beta1/BUILD | 26 + .../v1beta1/authentication_client.go | 28 +- .../typed/authentication/v1beta1/doc.go | 4 +- .../v1beta1/generated_expansion.go | 2 +- .../authentication/v1beta1/tokenreview.go | 2 +- .../kubernetes/typed/authorization/v1/BUILD | 30 + .../authorization/v1/authorization_client.go | 98 + .../kubernetes/typed/authorization/v1/doc.go | 20 + .../authorization/v1/generated_expansion.go | 17 + .../v1/localsubjectaccessreview.go | 46 + .../v1/localsubjectaccessreview_expansion.go | 36 + .../v1/selfsubjectaccessreview.go | 44 + .../v1/selfsubjectaccessreview_expansion.go | 35 + .../authorization/v1/subjectaccessreview.go | 44 + .../v1/subjectaccessreview_expansion.go | 36 + .../typed/authorization/v1beta1/BUILD | 30 + .../v1beta1/authorization_client.go | 28 +- .../typed/authorization/v1beta1/doc.go | 4 +- .../v1beta1/generated_expansion.go | 2 +- .../v1beta1/localsubjectaccessreview.go | 2 +- .../v1beta1/selfsubjectaccessreview.go | 2 +- .../v1beta1/subjectaccessreview.go | 2 +- .../kubernetes/typed/autoscaling/v1/BUILD | 28 + .../autoscaling/v1/autoscaling_client.go | 28 +- .../kubernetes/typed/autoscaling/v1/doc.go | 4 +- .../autoscaling/v1/generated_expansion.go | 2 +- .../autoscaling/v1/horizontalpodautoscaler.go | 45 +- .../typed/autoscaling/v2alpha1/BUILD | 28 + .../v2alpha1/autoscaling_client.go | 88 + .../typed/autoscaling/v2alpha1/doc.go | 20 + .../v2alpha1/generated_expansion.go | 19 + .../v2alpha1/horizontalpodautoscaler.go | 172 + .../client-go/kubernetes/typed/batch/v1/BUILD | 28 + .../kubernetes/typed/batch/v1/batch_client.go | 28 +- .../kubernetes/typed/batch/v1/doc.go | 4 +- .../typed/batch/v1/generated_expansion.go | 2 +- .../kubernetes/typed/batch/v1/job.go | 45 +- .../kubernetes/typed/batch/v2alpha1/BUILD | 28 + .../typed/batch/v2alpha1/batch_client.go | 33 +- .../typed/batch/v2alpha1/cronjob.go | 29 +- .../kubernetes/typed/batch/v2alpha1/doc.go | 4 +- .../batch/v2alpha1/generated_expansion.go | 4 +- .../kubernetes/typed/batch/v2alpha1/job.go | 167 - .../v1alpha1/certificates_client.go | 98 - .../typed/certificates/v1beta1/BUILD | 29 + .../v1beta1/certificates_client.go | 88 + .../certificatesigningrequest.go | 63 +- .../certificatesigningrequest_expansion.go | 6 +- .../typed/certificates/v1beta1/doc.go | 20 + .../v1beta1/generated_expansion.go | 17 + .../client-go/kubernetes/typed/core/v1/BUILD | 53 + .../typed/core/v1/componentstatus.go | 41 +- .../kubernetes/typed/core/v1/configmap.go | 41 +- .../kubernetes/typed/core/v1/core_client.go | 28 +- .../client-go/kubernetes/typed/core/v1/doc.go | 4 +- .../kubernetes/typed/core/v1/endpoints.go | 41 +- .../kubernetes/typed/core/v1/event.go | 41 +- .../typed/core/v1/event_expansion.go | 18 +- .../typed/core/v1/generated_expansion.go | 2 +- .../kubernetes/typed/core/v1/limitrange.go | 41 +- .../kubernetes/typed/core/v1/namespace.go | 44 +- .../kubernetes/typed/core/v1/node.go | 44 +- .../typed/core/v1/node_expansion.go | 4 +- .../typed/core/v1/persistentvolume.go | 44 +- .../typed/core/v1/persistentvolumeclaim.go | 44 +- .../client-go/kubernetes/typed/core/v1/pod.go | 44 +- .../kubernetes/typed/core/v1/pod_expansion.go | 10 +- .../kubernetes/typed/core/v1/podtemplate.go | 41 +- .../typed/core/v1/replicationcontroller.go | 44 +- .../kubernetes/typed/core/v1/resourcequota.go | 44 +- .../kubernetes/typed/core/v1/secret.go | 41 +- .../kubernetes/typed/core/v1/service.go | 44 +- .../typed/core/v1/service_expansion.go | 10 +- .../typed/core/v1/serviceaccount.go | 41 +- .../kubernetes/typed/extensions/v1beta1/BUILD | 38 + .../typed/extensions/v1beta1/daemonset.go | 29 +- .../typed/extensions/v1beta1/deployment.go | 29 +- .../typed/extensions/v1beta1/doc.go | 4 +- .../extensions/v1beta1/extensions_client.go | 33 +- .../extensions/v1beta1/generated_expansion.go | 4 +- .../typed/extensions/v1beta1/ingress.go | 29 +- .../typed/extensions/v1beta1/job.go | 167 - .../extensions/v1beta1/podsecuritypolicy.go | 26 +- .../typed/extensions/v1beta1/replicaset.go | 29 +- .../typed/extensions/v1beta1/scale.go | 2 +- .../extensions/v1beta1/scale_expansion.go | 12 +- .../extensions/v1beta1/thirdpartyresource.go | 26 +- .../kubernetes/typed/networking/v1/BUILD | 28 + .../kubernetes/typed/networking/v1/doc.go | 20 + .../networking/v1/generated_expansion.go | 19 + .../typed/networking/v1/networking_client.go | 88 + .../typed/networking/v1/networkpolicy.go | 155 + .../policy/v1alpha1/poddisruptionbudget.go | 167 - .../typed/policy/v1alpha1/policy_client.go | 98 - .../kubernetes/typed/policy/v1beta1/BUILD | 30 + .../kubernetes/typed/policy/v1beta1/doc.go | 4 +- .../typed/policy/v1beta1/eviction.go | 46 + .../policy/v1beta1/eviction_expansion.go | 38 + .../policy/v1beta1/generated_expansion.go | 2 +- .../policy/v1beta1/poddisruptionbudget.go | 29 +- .../typed/policy/v1beta1/policy_client.go | 33 +- .../kubernetes/typed/rbac/v1alpha1/BUILD | 31 + .../typed/rbac/v1alpha1/clusterrole.go | 26 +- .../typed/rbac/v1alpha1/clusterrolebinding.go | 26 +- .../kubernetes/typed/rbac/v1alpha1/doc.go | 4 +- .../rbac/v1alpha1/generated_expansion.go | 2 +- .../typed/rbac/v1alpha1/rbac_client.go | 28 +- .../kubernetes/typed/rbac/v1alpha1/role.go | 26 +- .../typed/rbac/v1alpha1/rolebinding.go | 26 +- .../kubernetes/typed/rbac/v1beta1/BUILD | 31 + .../typed/rbac/v1beta1/clusterrole.go | 145 + .../typed/rbac/v1beta1/clusterrolebinding.go | 145 + .../kubernetes/typed/rbac/v1beta1/doc.go | 20 + .../rbac/v1beta1/generated_expansion.go} | 16 +- .../typed/rbac/v1beta1/rbac_client.go | 103 + .../kubernetes/typed/rbac/v1beta1/role.go | 155 + .../typed/rbac/v1beta1/rolebinding.go | 155 + .../kubernetes/typed/settings/v1alpha1/BUILD | 28 + .../kubernetes/typed/settings/v1alpha1/doc.go | 20 + .../settings/v1alpha1/generated_expansion.go | 19 + .../typed/settings/v1alpha1/podpreset.go | 155 + .../settings/v1alpha1/settings_client.go | 88 + .../kubernetes/typed/storage/v1/BUILD | 28 + .../kubernetes/typed/storage/v1/doc.go | 20 + .../typed/storage/v1/generated_expansion.go | 19 + .../typed/storage/v1/storage_client.go | 88 + .../typed/storage/v1/storageclass.go | 145 + .../kubernetes/typed/storage/v1beta1/BUILD | 28 + .../kubernetes/typed/storage/v1beta1/doc.go | 4 +- .../storage/v1beta1/generated_expansion.go | 2 +- .../typed/storage/v1beta1/storage_client.go | 28 +- .../typed/storage/v1beta1/storageclass.go | 26 +- vendor/k8s.io/client-go/pkg/api/BUILD | 40 + vendor/k8s.io/client-go/pkg/api/OWNERS | 50 +- .../pkg/api/annotation_key_constants.go | 113 + vendor/k8s.io/client-go/pkg/api/context.go | 152 - vendor/k8s.io/client-go/pkg/api/doc.go | 2 - vendor/k8s.io/client-go/pkg/api/helpers.go | 631 - .../client-go/pkg/api/install/install.go | 153 - .../api/{meta/metatypes/types.go => json.go} | 24 +- vendor/k8s.io/client-go/pkg/api/meta.go | 140 - .../client-go/pkg/api/objectreference.go | 34 + vendor/k8s.io/client-go/pkg/api/register.go | 58 +- .../client-go/pkg/api/requestcontext.go | 117 - vendor/k8s.io/client-go/pkg/api/resource.go | 62 + .../pkg/api/resource/generated.pb.go | 70 - .../client-go/pkg/api/resource_helpers.go | 229 - vendor/k8s.io/client-go/pkg/api/taint.go | 36 + vendor/k8s.io/client-go/pkg/api/toleration.go | 30 + .../client-go/pkg/api/types.generated.go | 63626 ---------------- vendor/k8s.io/client-go/pkg/api/types.go | 1809 +- .../pkg/api/unversioned/generated.pb.go | 4537 -- .../pkg/api/unversioned/generated.proto | 400 - .../client-go/pkg/api/unversioned/meta.go | 62 - .../types_swagger_doc_generated.go | 208 - .../pkg/api/unversioned/well_known_labels.go | 67 - .../api/unversioned/zz_generated.deepcopy.go | 390 - vendor/k8s.io/client-go/pkg/api/v1/BUILD | 51 + vendor/k8s.io/client-go/pkg/api/v1/OWNERS | 41 + .../pkg/api/v1/annotation_key_constants.go | 113 + .../k8s.io/client-go/pkg/api/v1/conversion.go | 97 +- .../k8s.io/client-go/pkg/api/v1/defaults.go | 106 +- vendor/k8s.io/client-go/pkg/api/v1/doc.go | 5 - .../client-go/pkg/api/{ => v1}/generate.go | 4 +- .../client-go/pkg/api/v1/generated.pb.go | 21393 ++++-- .../client-go/pkg/api/v1/generated.proto | 1221 +- vendor/k8s.io/client-go/pkg/api/v1/helpers.go | 33 - vendor/k8s.io/client-go/pkg/api/v1/meta.go | 72 +- .../client-go/pkg/api/v1/objectreference.go | 33 + vendor/k8s.io/client-go/pkg/api/v1/ref.go | 133 - vendor/k8s.io/client-go/pkg/api/v1/ref/BUILD | 19 + .../client-go/pkg/api/{ => v1/ref}/ref.go | 33 +- .../k8s.io/client-go/pkg/api/v1/register.go | 35 +- .../k8s.io/client-go/pkg/api/v1/resource.go | 63 + vendor/k8s.io/client-go/pkg/api/v1/taint.go | 33 + .../k8s.io/client-go/pkg/api/v1/toleration.go | 56 + .../client-go/pkg/api/v1/types.generated.go | 59897 +++++++++------ vendor/k8s.io/client-go/pkg/api/v1/types.go | 1399 +- .../pkg/api/v1/types_swagger_doc_generated.go | 763 +- .../pkg/api/v1/zz_generated.conversion.go | 1240 +- .../pkg/api/v1/zz_generated.deepcopy.go | 1798 +- .../pkg/api/v1/zz_generated.defaults.go | 60 +- .../client-go/pkg/api/validation/path/name.go | 66 - .../pkg/api/zz_generated.deepcopy.go | 1812 +- .../pkg/apis/admissionregistration/BUILD | 25 + .../apis/admissionregistration}/doc.go | 12 +- .../apis/admissionregistration/register.go | 53 + .../pkg/apis/admissionregistration/types.go | 216 + .../apis/admissionregistration/v1alpha1/BUILD | 35 + .../v1alpha1/defaults.go | 39 + .../v1alpha1/doc.go | 10 +- .../v1alpha1/generated.pb.go | 2228 + .../v1alpha1/generated.proto | 203 + .../v1alpha1/register.go | 60 + .../v1alpha1/types.generated.go | 4232 + .../admissionregistration/v1alpha1/types.go | 220 + .../v1alpha1/types_swagger_doc_generated.go | 133 + .../v1alpha1/zz_generated.conversion.go | 311 + .../v1alpha1/zz_generated.deepcopy.go | 254 + .../v1alpha1/zz_generated.defaults.go | 70 + .../zz_generated.deepcopy.go | 254 + vendor/k8s.io/client-go/pkg/apis/apps/BUILD | 27 + vendor/k8s.io/client-go/pkg/apis/apps/OWNERS | 21 + vendor/k8s.io/client-go/pkg/apis/apps/doc.go | 4 - .../pkg/apis/apps/install/install.go | 41 - .../client-go/pkg/apis/apps/register.go | 20 +- .../pkg/apis/apps/types.generated.go | 1628 - .../k8s.io/client-go/pkg/apis/apps/types.go | 162 +- .../client-go/pkg/apis/apps/v1beta1/BUILD | 42 + .../pkg/apis/apps/v1beta1/conversion.go | 248 +- .../pkg/apis/apps/v1beta1/defaults.go | 84 +- .../client-go/pkg/apis/apps/v1beta1/doc.go | 6 - .../pkg/apis/apps/v1beta1/generated.pb.go | 4632 +- .../pkg/apis/apps/v1beta1/generated.proto | 369 +- .../pkg/apis/apps/v1beta1/register.go | 42 +- .../pkg/apis/apps/v1beta1/types.generated.go | 8312 +- .../client-go/pkg/apis/apps/v1beta1/types.go | 443 +- .../v1beta1/types_swagger_doc_generated.go | 200 +- .../apps/v1beta1/zz_generated.conversion.go | 190 +- .../apps/v1beta1/zz_generated.deepcopy.go | 373 +- .../apps/v1beta1/zz_generated.defaults.go | 164 +- .../pkg/apis/apps/zz_generated.deepcopy.go | 118 +- .../client-go/pkg/apis/authentication/BUILD | 25 + .../client-go/pkg/apis/authentication/OWNERS | 9 + .../client-go/pkg/apis/authentication/doc.go | 2 - .../apis/authentication/install/install.go | 43 - .../pkg/apis/authentication/register.go | 15 +- .../apis/authentication/types.generated.go | 2394 - .../pkg/apis/authentication/types.go | 9 +- .../pkg/apis/authentication/v1/BUILD | 34 + .../authentication/v1/conversion.go} | 15 +- .../pkg/apis/authentication/v1/defaults.go | 25 + .../pkg/apis/authentication/v1/doc.go | 18 + .../apis/authentication/v1/generated.pb.go | 1301 + .../apis/authentication/v1/generated.proto | 99 + .../pkg/apis/authentication/v1/register.go | 58 + .../pkg/apis/authentication/v1/types.go | 106 + .../v1/types_swagger_doc_generated.go | 72 + .../v1/zz_generated.conversion.go | 153 + .../v1/zz_generated.deepcopy.go | 110 + .../v1/zz_generated.defaults.go | 32 + .../pkg/apis/authentication/v1beta1/BUILD | 37 + .../apis/authentication/v1beta1/conversion.go | 2 +- .../apis/authentication/v1beta1/defaults.go | 4 +- .../pkg/apis/authentication/v1beta1/doc.go | 4 - .../authentication/v1beta1/generated.pb.go | 475 +- .../authentication/v1beta1/generated.proto | 15 +- .../apis/authentication/v1beta1/register.go | 32 +- .../authentication/v1beta1/types.generated.go | 1085 +- .../pkg/apis/authentication/v1beta1/types.go | 7 +- .../v1beta1/zz_generated.conversion.go | 24 +- .../v1beta1/zz_generated.deepcopy.go | 31 +- .../v1beta1/zz_generated.defaults.go | 32 + .../authentication/zz_generated.deepcopy.go | 31 +- .../client-go/pkg/apis/authorization/BUILD | 25 + .../client-go/pkg/apis/authorization/OWNERS | 17 + .../client-go/pkg/apis/authorization/doc.go | 3 - .../pkg/apis/authorization/install/install.go | 43 - .../pkg/apis/authorization/register.go | 10 +- .../pkg/apis/authorization/types.generated.go | 5607 -- .../client-go/pkg/apis/authorization/types.go | 15 +- .../client-go/pkg/apis/authorization/v1/BUILD | 37 + .../pkg/apis/authorization/v1/conversion.go | 26 + .../pkg/apis/authorization/v1/defaults.go | 25 + .../pkg/apis/authorization/v1/doc.go | 18 + .../pkg/apis/authorization/v1/generated.pb.go | 2364 + .../pkg/apis/authorization/v1/generated.proto | 183 + .../pkg/apis/authorization/v1/register.go | 61 + .../apis/authorization/v1/types.generated.go | 3233 + .../pkg/apis/authorization/v1/types.go | 176 + .../v1/types_swagger_doc_generated.go | 119 + .../v1/zz_generated.conversion.go | 279 + .../authorization/v1/zz_generated.deepcopy.go | 187 + .../authorization/v1/zz_generated.defaults.go | 32 + .../pkg/apis/authorization/v1beta1/BUILD | 37 + .../apis/authorization/v1beta1/conversion.go | 2 +- .../apis/authorization/v1beta1/defaults.go | 4 +- .../pkg/apis/authorization/v1beta1/doc.go | 5 - .../authorization/v1beta1/generated.pb.go | 750 +- .../authorization/v1beta1/generated.proto | 19 +- .../apis/authorization/v1beta1/register.go | 38 +- .../authorization/v1beta1/types.generated.go | 2251 +- .../pkg/apis/authorization/v1beta1/types.go | 15 +- .../v1beta1/zz_generated.conversion.go | 52 +- .../v1beta1/zz_generated.deepcopy.go | 67 +- .../v1beta1/zz_generated.defaults.go | 32 + .../authorization/zz_generated.deepcopy.go | 67 +- .../client-go/pkg/apis/autoscaling/BUILD | 28 + .../client-go/pkg/apis/autoscaling/OWNERS | 20 + .../pkg/apis/autoscaling/annotations.go | 34 + .../client-go/pkg/apis/autoscaling/doc.go | 3 - .../pkg/apis/autoscaling/install/install.go | 41 - .../pkg/apis/autoscaling/register.go | 12 +- .../pkg/apis/autoscaling/types.generated.go | 2656 - .../client-go/pkg/apis/autoscaling/types.go | 325 +- .../client-go/pkg/apis/autoscaling/v1/BUILD | 39 + .../pkg/apis/autoscaling/v1/conversion.go | 275 + .../pkg/apis/autoscaling/v1/defaults.go | 10 +- .../client-go/pkg/apis/autoscaling/v1/doc.go | 5 - .../pkg/apis/autoscaling/v1/generated.pb.go | 2774 +- .../pkg/apis/autoscaling/v1/generated.proto | 206 +- .../pkg/apis/autoscaling/v1/register.go | 33 +- .../apis/autoscaling/v1/types.generated.go | 4781 +- .../pkg/apis/autoscaling/v1/types.go | 223 +- .../v1/types_swagger_doc_generated.go | 113 +- .../autoscaling/v1/zz_generated.conversion.go | 338 +- .../autoscaling/v1/zz_generated.deepcopy.go | 226 +- .../autoscaling/v1/zz_generated.defaults.go | 4 +- .../pkg/apis/autoscaling/v2alpha1/BUILD | 38 + .../pkg/apis/autoscaling/v2alpha1/defaults.go | 47 + .../apis/autoscaling/v2alpha1/doc.go} | 2 +- .../apis/autoscaling/v2alpha1/generated.pb.go | 3402 + .../apis/autoscaling/v2alpha1/generated.proto | 302 + .../pkg/apis/autoscaling/v2alpha1/register.go | 59 + .../autoscaling/v2alpha1/types.generated.go | 5218 ++ .../pkg/apis/autoscaling/v2alpha1/types.go | 309 + .../v2alpha1/types_swagger_doc_generated.go | 189 + .../v2alpha1/zz_generated.conversion.go | 449 + .../v2alpha1/zz_generated.deepcopy.go | 319 + .../v2alpha1/zz_generated.defaults.go | 47 + .../apis/autoscaling/zz_generated.deepcopy.go | 255 +- vendor/k8s.io/client-go/pkg/apis/batch/BUILD | 26 + vendor/k8s.io/client-go/pkg/apis/batch/OWNERS | 19 + vendor/k8s.io/client-go/pkg/apis/batch/doc.go | 3 - .../pkg/apis/batch/install/install.go | 43 - .../client-go/pkg/apis/batch/register.go | 12 +- .../pkg/apis/batch/types.generated.go | 4676 -- .../k8s.io/client-go/pkg/apis/batch/types.go | 179 +- .../k8s.io/client-go/pkg/apis/batch/v1/BUILD | 40 + .../client-go/pkg/apis/batch/v1/conversion.go | 9 +- .../client-go/pkg/apis/batch/v1/defaults.go | 7 +- .../k8s.io/client-go/pkg/apis/batch/v1/doc.go | 5 - .../pkg/apis/batch/v1/generated.pb.go | 486 +- .../pkg/apis/batch/v1/generated.proto | 81 +- .../client-go/pkg/apis/batch/v1/register.go | 33 +- .../pkg/apis/batch/v1/types.generated.go | 1910 +- .../client-go/pkg/apis/batch/v1/types.go | 74 +- .../batch/v1/types_swagger_doc_generated.go | 32 +- .../apis/batch/v1/zz_generated.conversion.go | 40 +- .../apis/batch/v1/zz_generated.deepcopy.go | 59 +- .../apis/batch/v1/zz_generated.defaults.go | 21 +- .../client-go/pkg/apis/batch/v2alpha1/BUILD | 41 + .../pkg/apis/batch/v2alpha1/conversion.go | 59 +- .../pkg/apis/batch/v2alpha1/defaults.go | 27 +- .../client-go/pkg/apis/batch/v2alpha1/doc.go | 5 - .../pkg/apis/batch/v2alpha1/generated.pb.go | 1791 +- .../pkg/apis/batch/v2alpha1/generated.proto | 208 +- .../pkg/apis/batch/v2alpha1/register.go | 34 +- .../apis/batch/v2alpha1/types.generated.go | 4391 +- .../pkg/apis/batch/v2alpha1/types.go | 218 +- .../v2alpha1/types_swagger_doc_generated.go | 99 +- .../batch/v2alpha1/zz_generated.conversion.go | 235 +- .../batch/v2alpha1/zz_generated.deepcopy.go | 213 +- .../batch/v2alpha1/zz_generated.defaults.go | 164 +- .../pkg/apis/batch/zz_generated.deepcopy.go | 115 +- .../client-go/pkg/apis/certificates/BUILD | 26 + .../client-go/pkg/apis/certificates/OWNERS | 14 + .../client-go/pkg/apis/certificates/doc.go | 3 - .../pkg/apis/certificates/helpers.go | 38 + .../pkg/apis/certificates/install/install.go | 43 - .../pkg/apis/certificates/register.go | 16 +- .../pkg/apis/certificates/types.generated.go | 1957 - .../client-go/pkg/apis/certificates/types.go | 93 +- .../certificates/v1alpha1/types.generated.go | 1950 - .../v1alpha1/zz_generated.conversion.go | 173 - .../v1alpha1/zz_generated.deepcopy.go | 145 - .../pkg/apis/certificates/v1beta1/BUILD | 38 + .../{v1alpha1 => v1beta1}/conversion.go | 7 +- .../certificates/v1beta1/defaults.go} | 17 +- .../apis/certificates/v1beta1/doc.go} | 5 +- .../{v1alpha1 => v1beta1}/generated.pb.go | 777 +- .../{v1alpha1 => v1beta1}/generated.proto | 51 +- .../pkg/apis/certificates/v1beta1/helpers.go | 38 + .../{v1alpha1 => v1beta1}/register.go | 39 +- .../certificates/v1beta1/types.generated.go | 2624 + .../{v1alpha1 => v1beta1}/types.go | 77 +- .../types_swagger_doc_generated.go | 10 +- .../v1beta1/zz_generated.conversion.go | 189 + .../v1beta1/zz_generated.deepcopy.go | 155 + .../v1beta1/zz_generated.defaults.go | 47 + .../certificates/zz_generated.deepcopy.go | 56 +- .../client-go/pkg/apis/extensions/BUILD | 29 + .../client-go/pkg/apis/extensions/OWNERS | 41 + .../client-go/pkg/apis/extensions/doc.go | 3 - .../pkg/apis/extensions/install/install.go | 43 - .../client-go/pkg/apis/extensions/register.go | 21 +- .../pkg/apis/extensions/types.generated.go | 19454 ----- .../client-go/pkg/apis/extensions/types.go | 566 +- .../pkg/apis/extensions/v1beta1/BUILD | 43 + .../pkg/apis/extensions/v1beta1/conversion.go | 259 +- .../pkg/apis/extensions/v1beta1/defaults.go | 86 +- .../pkg/apis/extensions/v1beta1/doc.go | 7 - .../apis/extensions/v1beta1/generated.pb.go | 7332 +- .../apis/extensions/v1beta1/generated.proto | 523 +- .../pkg/apis/extensions/v1beta1/register.go | 37 +- .../extensions/v1beta1/types.generated.go | 24058 +++--- .../pkg/apis/extensions/v1beta1/types.go | 582 +- .../v1beta1/types_swagger_doc_generated.go | 253 +- .../v1beta1/zz_generated.conversion.go | 740 +- .../v1beta1/zz_generated.deepcopy.go | 759 +- .../v1beta1/zz_generated.defaults.go | 192 +- .../apis/extensions/zz_generated.deepcopy.go | 492 +- .../client-go/pkg/apis/networking/BUILD | 27 + .../client-go/pkg/apis/networking/OWNERS | 4 + .../client-go/pkg/apis/networking/doc.go | 18 + .../client-go/pkg/apis/networking/register.go | 51 + .../client-go/pkg/apis/networking/types.go | 115 + .../client-go/pkg/apis/networking/v1/BUILD | 40 + .../pkg/apis/networking/v1/conversion.go | 195 + .../{api => apis/networking/v1}/defaults.go | 28 +- .../client-go/pkg/apis/networking/v1/doc.go | 18 + .../pkg/apis/networking/v1/generated.pb.go | 1345 + .../pkg/apis/networking/v1/generated.proto | 127 + .../pkg/apis/networking/v1/register.go | 50 + .../pkg/apis/networking/v1/types.generated.go | 2322 + .../client-go/pkg/apis/networking/v1/types.go | 120 + .../v1/types_swagger_doc_generated.go | 90 + .../networking/v1/zz_generated.conversion.go | 195 + .../networking/v1/zz_generated.deepcopy.go | 182 + .../networking/v1/zz_generated.defaults.go | 51 + .../apis/networking/zz_generated.deepcopy.go | 182 + vendor/k8s.io/client-go/pkg/apis/policy/BUILD | 26 + .../k8s.io/client-go/pkg/apis/policy/OWNERS | 4 + .../k8s.io/client-go/pkg/apis/policy/doc.go | 3 - .../pkg/apis/policy/install/install.go | 41 - .../client-go/pkg/apis/policy/register.go | 12 +- .../pkg/apis/policy/types.generated.go | 1986 - .../k8s.io/client-go/pkg/apis/policy/types.go | 48 +- .../pkg/apis/policy/v1alpha1/types.go | 93 - .../client-go/pkg/apis/policy/v1beta1/BUILD | 36 + .../client-go/pkg/apis/policy/v1beta1/doc.go | 4 - .../pkg/apis/policy/v1beta1/generated.pb.go | 589 +- .../pkg/apis/policy/v1beta1/generated.proto | 32 +- .../pkg/apis/policy/v1beta1/register.go | 33 +- .../apis/policy/v1beta1/types.generated.go | 1769 +- .../pkg/apis/policy/v1beta1/types.go | 36 +- .../v1beta1/types_swagger_doc_generated.go | 7 +- .../policy/v1beta1/zz_generated.conversion.go | 63 +- .../policy/v1beta1/zz_generated.deepcopy.go | 68 +- .../policy/v1beta1/zz_generated.defaults.go | 32 + .../pkg/apis/policy/zz_generated.deepcopy.go | 68 +- vendor/k8s.io/client-go/pkg/apis/rbac/BUILD | 27 + vendor/k8s.io/client-go/pkg/apis/rbac/OWNERS | 17 + vendor/k8s.io/client-go/pkg/apis/rbac/doc.go | 3 - .../k8s.io/client-go/pkg/apis/rbac/helpers.go | 211 +- .../pkg/apis/rbac/install/install.go | 43 - .../client-go/pkg/apis/rbac/register.go | 17 +- .../k8s.io/client-go/pkg/apis/rbac/types.go | 51 +- .../client-go/pkg/apis/rbac/v1alpha1/BUILD | 37 + .../pkg/apis/rbac/v1alpha1/conversion.go | 81 + .../pkg/apis/rbac/v1alpha1/defaults.go | 20 +- .../client-go/pkg/apis/rbac/v1alpha1/doc.go | 5 - .../pkg/apis/rbac/v1alpha1/generated.pb.go | 1004 +- .../pkg/apis/rbac/v1alpha1/generated.proto | 55 +- .../pkg/apis/rbac/v1alpha1/helpers.go | 146 + .../pkg/apis/rbac/v1alpha1/register.go | 34 +- .../pkg/apis/rbac/v1alpha1/types.generated.go | 3856 +- .../client-go/pkg/apis/rbac/v1alpha1/types.go | 64 +- .../v1alpha1/types_swagger_doc_generated.go | 15 +- .../rbac/v1alpha1/zz_generated.conversion.go | 314 +- .../rbac/v1alpha1/zz_generated.deepcopy.go | 104 +- .../rbac/v1alpha1/zz_generated.defaults.go | 12 +- .../client-go/pkg/apis/rbac/v1beta1/BUILD | 36 + .../pkg/apis/rbac/v1beta1/defaults.go | 48 + .../client-go/pkg/apis/rbac/v1beta1/doc.go | 18 + .../pkg/apis/rbac/v1beta1/generated.pb.go | 2821 + .../pkg/apis/rbac/v1beta1/generated.proto | 198 + .../pkg/apis/rbac/v1beta1/helpers.go | 146 + .../pkg/apis/rbac/v1beta1/register.go | 65 + .../pkg/apis/rbac/v1beta1/types.generated.go | 4879 ++ .../client-go/pkg/apis/rbac/v1beta1/types.go | 207 + .../v1beta1/types_swagger_doc_generated.go | 148 + .../rbac/v1beta1/zz_generated.conversion.go | 415 + .../rbac/v1beta1/zz_generated.deepcopy.go | 269 + .../rbac/v1beta1/zz_generated.defaults.go | 66 + .../pkg/apis/rbac/zz_generated.deepcopy.go | 108 +- .../k8s.io/client-go/pkg/apis/settings/BUILD | 26 + .../pkg/{util/labels => apis/settings}/doc.go | 4 +- .../{policy/v1alpha1 => settings}/register.go | 42 +- .../client-go/pkg/apis/settings/types.go | 63 + .../pkg/apis/settings/v1alpha1/BUILD | 33 + .../pkg/apis/settings/v1alpha1/doc.go | 18 + .../apis/settings/v1alpha1/generated.pb.go | 929 + .../apis/settings/v1alpha1/generated.proto | 75 + .../pkg/apis/settings/v1alpha1/register.go | 59 + .../pkg/apis/settings/v1alpha1/types.go | 67 + .../v1alpha1/types_swagger_doc_generated.go | 61 + .../v1alpha1/zz_generated.conversion.go | 165 + .../v1alpha1/zz_generated.deepcopy.go | 127 + .../v1alpha1/zz_generated.defaults.go | 98 + .../apis/settings/zz_generated.deepcopy.go | 127 + .../k8s.io/client-go/pkg/apis/storage/BUILD | 25 + .../k8s.io/client-go/pkg/apis/storage/OWNERS | 3 + .../k8s.io/client-go/pkg/apis/storage/doc.go | 2 - .../pkg/apis/storage/install/install.go | 43 - .../client-go/pkg/apis/storage/register.go | 15 +- .../pkg/apis/storage/types.generated.go | 900 - .../client-go/pkg/apis/storage/types.go | 21 +- .../client-go/pkg/apis/storage/v1/BUILD | 32 + .../client-go/pkg/apis/storage/v1/doc.go | 18 + .../pkg/apis/storage/v1/generated.pb.go | 746 + .../pkg/apis/storage/v1/generated.proto | 62 + .../client-go/pkg/apis/storage/v1/register.go | 60 + .../client-go/pkg/apis/storage/v1/types.go | 57 + .../storage/v1/types_swagger_doc_generated.go | 51 + .../storage/v1/zz_generated.conversion.go | 93 + .../apis/storage/v1/zz_generated.deepcopy.go | 82 + .../apis/storage/v1/zz_generated.defaults.go | 32 + .../client-go/pkg/apis/storage/v1beta1/BUILD | 35 + .../client-go/pkg/apis/storage/v1beta1/doc.go | 4 - .../pkg/apis/storage/v1beta1/generated.pb.go | 314 +- .../pkg/apis/storage/v1beta1/generated.proto | 21 +- .../pkg/apis/storage/v1beta1/register.go | 34 +- .../apis/storage/v1beta1/types.generated.go | 657 +- .../pkg/apis/storage/v1beta1/types.go | 15 +- .../v1beta1/types_swagger_doc_generated.go | 4 +- .../v1beta1/zz_generated.conversion.go | 26 +- .../storage/v1beta1/zz_generated.deepcopy.go | 24 +- .../storage/v1beta1/zz_generated.defaults.go | 32 + .../pkg/apis/storage/zz_generated.deepcopy.go | 24 +- vendor/k8s.io/client-go/pkg/auth/user/doc.go | 19 - vendor/k8s.io/client-go/pkg/auth/user/user.go | 78 - vendor/k8s.io/client-go/pkg/conversion/OWNERS | 5 - vendor/k8s.io/client-go/pkg/runtime/OWNERS | 5 - .../forked/golang/template/exec.go | 94 - .../forked/golang/template/funcs.go | 599 - vendor/k8s.io/client-go/pkg/util/BUILD | 19 + .../client-go/pkg/util/jsonpath/jsonpath.go | 498 - .../client-go/pkg/util/jsonpath/node.go | 239 - .../client-go/pkg/util/jsonpath/parser.go | 433 - .../k8s.io/client-go/pkg/util/parsers/BUILD | 15 + .../client-go/pkg/util/ratelimit/bucket.go | 170 - vendor/k8s.io/client-go/pkg/util/trace.go | 72 - vendor/k8s.io/client-go/pkg/util/trie.go | 79 - .../client-go/pkg/util/umask_windows.go | 2 +- vendor/k8s.io/client-go/pkg/util/uuid/uuid.go | 42 - vendor/k8s.io/client-go/pkg/version/BUILD | 19 + vendor/k8s.io/client-go/pkg/version/base.go | 8 +- vendor/k8s.io/client-go/pkg/version/def.bzl | 24 + vendor/k8s.io/client-go/pkg/version/doc.go | 1 - vendor/k8s.io/client-go/pkg/version/semver.go | 50 - .../k8s.io/client-go/pkg/version/version.go | 26 +- .../pkg/watch/versioned/generated.pb.go | 390 - .../pkg/watch/versioned/generated.proto | 44 - .../client-go/pkg/watch/versioned/types.go | 38 - .../plugin/pkg/client/auth/gcp/OWNERS | 3 - .../plugin/pkg/client/auth/gcp/gcp.go | 211 - .../plugin/pkg/client/auth/oidc/OWNERS | 2 - .../plugin/pkg/client/auth/oidc/oidc.go | 270 - vendor/k8s.io/client-go/rest/BUILD | 85 + vendor/k8s.io/client-go/rest/OWNERS | 24 + vendor/k8s.io/client-go/rest/client.go | 20 +- vendor/k8s.io/client-go/rest/config.go | 108 +- vendor/k8s.io/client-go/rest/request.go | 202 +- vendor/k8s.io/client-go/rest/transport.go | 21 +- vendor/k8s.io/client-go/rest/url_utils.go | 11 +- vendor/k8s.io/client-go/rest/urlbackoff.go | 4 +- vendor/k8s.io/client-go/rest/versions.go | 6 +- vendor/k8s.io/client-go/rest/watch/BUILD | 46 + .../watch/versioned => rest/watch}/decoder.go | 11 +- .../watch/versioned => rest/watch}/encoder.go | 13 +- vendor/k8s.io/client-go/tools/auth/BUILD | 23 + .../k8s.io/client-go/tools/auth/clientauth.go | 6 +- vendor/k8s.io/client-go/tools/cache/BUILD | 84 + vendor/k8s.io/client-go/tools/cache/OWNERS | 41 + .../client-go/tools/cache/controller.go | 103 +- .../client-go/tools/cache/delta_fifo.go | 50 +- .../client-go/tools/cache/expiration_cache.go | 2 +- .../tools/cache/expiration_cache_fakes.go | 4 +- vendor/k8s.io/client-go/tools/cache/fifo.go | 39 +- vendor/k8s.io/client-go/tools/cache/index.go | 6 +- .../k8s.io/client-go/tools/cache/listers.go | 342 +- .../client-go/tools/cache/listers_core.go | 348 - .../tools/cache/listers_extensions.go | 210 - .../client-go/tools/cache/listers_rbac.go | 234 - .../k8s.io/client-go/tools/cache/listwatch.go | 42 +- .../client-go/tools/cache/mutation_cache.go | 261 + .../tools/cache/mutation_detector.go | 8 +- .../k8s.io/client-go/tools/cache/reflector.go | 65 +- .../client-go/tools/cache/shared_informer.go | 276 +- vendor/k8s.io/client-go/tools/cache/store.go | 6 +- .../tools/cache/thread_safe_store.go | 20 +- vendor/k8s.io/client-go/tools/clientcmd/BUILD | 62 + .../client-go/tools/clientcmd/api/BUILD | 34 + .../tools/clientcmd/api/latest/BUILD | 22 + .../tools/clientcmd/api/latest/latest.go | 12 +- .../client-go/tools/clientcmd/api/register.go | 14 +- .../client-go/tools/clientcmd/api/types.go | 35 +- .../client-go/tools/clientcmd/api/v1/BUILD | 24 + .../tools/clientcmd/api/v1/conversion.go | 4 +- .../tools/clientcmd/api/v1/register.go | 28 +- .../client-go/tools/clientcmd/api/v1/types.go | 18 +- .../tools/clientcmd/client_config.go | 184 +- .../client-go/tools/clientcmd/config.go | 4 +- .../k8s.io/client-go/tools/clientcmd/doc.go | 2 +- .../client-go/tools/clientcmd/helpers.go | 35 + .../client-go/tools/clientcmd/loader.go | 25 +- .../tools/clientcmd/merged_client_builder.go | 29 +- .../client-go/tools/clientcmd/overrides.go | 120 +- .../client-go/tools/clientcmd/validation.go | 11 +- vendor/k8s.io/client-go/tools/metrics/BUILD | 14 + vendor/k8s.io/client-go/tools/metrics/OWNERS | 7 + vendor/k8s.io/client-go/transport/BUILD | 35 + vendor/k8s.io/client-go/transport/OWNERS | 7 + vendor/k8s.io/client-go/transport/cache.go | 2 +- vendor/k8s.io/client-go/transport/config.go | 17 +- .../client-go/transport/round_trippers.go | 133 +- .../k8s.io/client-go/transport/transport.go | 1 + vendor/k8s.io/client-go/util/cert/BUILD | 30 + .../client-go/{pkg => }/util/cert/cert.go | 18 +- .../client-go/{pkg => }/util/cert/csr.go | 70 +- .../client-go/{pkg => }/util/cert/io.go | 68 +- .../client-go/{pkg => }/util/cert/pem.go | 55 +- .../k8s.io/client-go/util/flowcontrol/BUILD | 34 + .../{pkg => }/util/flowcontrol/backoff.go | 4 +- .../{pkg => }/util/flowcontrol/throttle.go | 18 +- vendor/k8s.io/client-go/util/homedir/BUILD | 14 + .../{pkg => }/util/homedir/homedir.go | 7 + vendor/k8s.io/client-go/util/integer/BUILD | 22 + .../{pkg => }/util/integer/integer.go | 0 .../go-oidc => k8s.io/kubernetes}/LICENSE | 8 +- .../kubernetes/pkg/api/unversioned/BUILD | 36 + .../pkg/api/unversioned/duration.go | 47 + .../kubernetes/pkg/api/unversioned/time.go | 176 + .../kubernetes/pkg/api/unversioned/types.go | 60 + 1058 files changed, 186574 insertions(+), 208833 deletions(-) delete mode 100644 vendor/github.com/blang/semver/LICENSE delete mode 100644 vendor/github.com/blang/semver/README.md delete mode 100644 vendor/github.com/blang/semver/json.go delete mode 100644 vendor/github.com/blang/semver/semver.go delete mode 100644 vendor/github.com/blang/semver/sort.go delete mode 100644 vendor/github.com/blang/semver/sql.go delete mode 100644 vendor/github.com/coreos/go-oidc/NOTICE delete mode 100644 vendor/github.com/coreos/go-oidc/http/client.go delete mode 100644 vendor/github.com/coreos/go-oidc/http/http.go delete mode 100644 vendor/github.com/coreos/go-oidc/http/url.go delete mode 100644 vendor/github.com/coreos/go-oidc/jose/claims.go delete mode 100644 vendor/github.com/coreos/go-oidc/jose/jose.go delete mode 100644 vendor/github.com/coreos/go-oidc/jose/jwk.go delete mode 100644 vendor/github.com/coreos/go-oidc/jose/jws.go delete mode 100644 vendor/github.com/coreos/go-oidc/jose/jwt.go delete mode 100755 vendor/github.com/coreos/go-oidc/jose/sig.go delete mode 100755 vendor/github.com/coreos/go-oidc/jose/sig_rsa.go delete mode 100644 vendor/github.com/coreos/go-oidc/key/key.go delete mode 100644 vendor/github.com/coreos/go-oidc/key/manager.go delete mode 100644 vendor/github.com/coreos/go-oidc/key/repo.go delete mode 100644 vendor/github.com/coreos/go-oidc/key/rotate.go delete mode 100644 vendor/github.com/coreos/go-oidc/key/sync.go delete mode 100644 vendor/github.com/coreos/go-oidc/oauth2/error.go delete mode 100644 vendor/github.com/coreos/go-oidc/oauth2/oauth2.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/client.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/identity.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/interface.go delete mode 100755 vendor/github.com/coreos/go-oidc/oidc/key.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/provider.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/transport.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/util.go delete mode 100644 vendor/github.com/coreos/go-oidc/oidc/verification.go delete mode 100644 vendor/github.com/coreos/pkg/NOTICE delete mode 100644 vendor/github.com/coreos/pkg/health/README.md delete mode 100644 vendor/github.com/coreos/pkg/health/health.go delete mode 100644 vendor/github.com/coreos/pkg/httputil/README.md delete mode 100644 vendor/github.com/coreos/pkg/httputil/cookie.go delete mode 100644 vendor/github.com/coreos/pkg/httputil/json.go delete mode 100644 vendor/github.com/coreos/pkg/timeutil/backoff.go create mode 100644 vendor/github.com/emicklei/go-restful-swagger12/.travis.yml rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/CHANGES.md (95%) create mode 100644 vendor/github.com/emicklei/go-restful-swagger12/LICENSE rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/README.md (87%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/api_declaration_list.go (100%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/config.go (73%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/model_builder.go (92%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/model_list.go (100%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/model_property_ext.go (79%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/model_property_list.go (100%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/ordered_route_map.go (100%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/swagger.go (100%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/swagger_builder.go (100%) rename vendor/github.com/emicklei/{go-restful/swagger => go-restful-swagger12}/swagger_webservice.go (95%) create mode 100644 vendor/github.com/go-openapi/analysis/.drone.sec create mode 100644 vendor/github.com/go-openapi/analysis/.drone.yml create mode 100644 vendor/github.com/go-openapi/analysis/.gitignore create mode 100644 vendor/github.com/go-openapi/analysis/.pullapprove.yml create mode 100644 vendor/github.com/go-openapi/analysis/CODE_OF_CONDUCT.md rename vendor/{cloud.google.com/go => github.com/go-openapi/analysis}/LICENSE (99%) create mode 100644 vendor/github.com/go-openapi/analysis/README.md create mode 100644 vendor/github.com/go-openapi/analysis/analyzer.go create mode 100644 vendor/github.com/go-openapi/loads/.drone.sec create mode 100644 vendor/github.com/go-openapi/loads/.drone.yml create mode 100644 vendor/github.com/go-openapi/loads/.gitignore create mode 100644 vendor/github.com/go-openapi/loads/.pullapprove.yml create mode 100644 vendor/github.com/go-openapi/loads/CODE_OF_CONDUCT.md rename vendor/{google.golang.org/cloud => github.com/go-openapi/loads}/LICENSE (99%) create mode 100644 vendor/github.com/go-openapi/loads/README.md create mode 100644 vendor/github.com/go-openapi/loads/spec.go create mode 100644 vendor/github.com/gogo/protobuf/proto/duration.go create mode 100644 vendor/github.com/gogo/protobuf/proto/duration_gogo.go create mode 100644 vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go create mode 100644 vendor/github.com/gogo/protobuf/proto/timestamp.go create mode 100644 vendor/github.com/gogo/protobuf/proto/timestamp_gogo.go rename vendor/github.com/{jonboulle/clockwork => hashicorp/golang-lru}/.gitignore (97%) create mode 100644 vendor/github.com/hashicorp/golang-lru/2q.go create mode 100644 vendor/github.com/hashicorp/golang-lru/LICENSE create mode 100644 vendor/github.com/hashicorp/golang-lru/README.md create mode 100644 vendor/github.com/hashicorp/golang-lru/arc.go create mode 100644 vendor/github.com/hashicorp/golang-lru/lru.go create mode 100644 vendor/github.com/hashicorp/golang-lru/simplelru/lru.go delete mode 100644 vendor/github.com/jonboulle/clockwork/.travis.yml delete mode 100644 vendor/github.com/jonboulle/clockwork/LICENSE delete mode 100644 vendor/github.com/jonboulle/clockwork/README.md delete mode 100644 vendor/github.com/jonboulle/clockwork/clockwork.go delete mode 100644 vendor/github.com/pborman/uuid/CONTRIBUTORS delete mode 100644 vendor/github.com/pborman/uuid/LICENSE delete mode 100755 vendor/github.com/pborman/uuid/dce.go delete mode 100755 vendor/github.com/pborman/uuid/doc.go delete mode 100644 vendor/github.com/pborman/uuid/hash.go delete mode 100644 vendor/github.com/pborman/uuid/json.go delete mode 100755 vendor/github.com/pborman/uuid/node.go delete mode 100755 vendor/github.com/pborman/uuid/time.go delete mode 100644 vendor/github.com/pborman/uuid/util.go delete mode 100755 vendor/github.com/pborman/uuid/uuid.go delete mode 100644 vendor/github.com/pborman/uuid/version1.go delete mode 100644 vendor/github.com/pborman/uuid/version4.go delete mode 100644 vendor/github.com/prometheus/client_golang/AUTHORS.md delete mode 100644 vendor/github.com/prometheus/procfs/MAINTAINERS.md delete mode 100644 vendor/github.com/prometheus/procfs/buddyinfo.go delete mode 100644 vendor/github.com/prometheus/procfs/mountstats.go delete mode 100644 vendor/github.com/prometheus/procfs/xfs/parse.go delete mode 100644 vendor/github.com/prometheus/procfs/xfs/xfs.go create mode 100644 vendor/github.com/robfig/cron/.gitignore create mode 100644 vendor/github.com/robfig/cron/.travis.yml delete mode 100644 vendor/github.com/robfig/cron/constantdelay_test.go delete mode 100644 vendor/github.com/robfig/cron/cron_test.go delete mode 100644 vendor/github.com/robfig/cron/parser_test.go delete mode 100644 vendor/github.com/robfig/cron/spec_test.go create mode 100644 vendor/github.com/spf13/pflag/.gitignore create mode 100644 vendor/github.com/spf13/pflag/bool_slice.go create mode 100644 vendor/github.com/spf13/pflag/ip_slice.go create mode 100644 vendor/github.com/spf13/pflag/string_array.go create mode 100644 vendor/github.com/spf13/pflag/uint_slice.go delete mode 100644 vendor/golang.org/x/net/context/ctxhttp/ctxhttp.go delete mode 100644 vendor/golang.org/x/net/context/ctxhttp/ctxhttp_pre17.go delete mode 100644 vendor/golang.org/x/oauth2/.travis.yml delete mode 100644 vendor/golang.org/x/oauth2/AUTHORS delete mode 100644 vendor/golang.org/x/oauth2/CONTRIBUTING.md delete mode 100644 vendor/golang.org/x/oauth2/CONTRIBUTORS delete mode 100644 vendor/golang.org/x/oauth2/LICENSE delete mode 100644 vendor/golang.org/x/oauth2/README.md delete mode 100644 vendor/golang.org/x/oauth2/client_appengine.go delete mode 100644 vendor/golang.org/x/oauth2/google/appengine.go delete mode 100644 vendor/golang.org/x/oauth2/google/appengine_hook.go delete mode 100644 vendor/golang.org/x/oauth2/google/default.go delete mode 100644 vendor/golang.org/x/oauth2/google/google.go delete mode 100644 vendor/golang.org/x/oauth2/google/sdk.go delete mode 100644 vendor/golang.org/x/oauth2/internal/oauth2.go delete mode 100644 vendor/golang.org/x/oauth2/internal/token.go delete mode 100644 vendor/golang.org/x/oauth2/internal/transport.go delete mode 100644 vendor/golang.org/x/oauth2/jws/jws.go delete mode 100644 vendor/golang.org/x/oauth2/jwt/jwt.go delete mode 100644 vendor/golang.org/x/oauth2/oauth2.go delete mode 100644 vendor/golang.org/x/oauth2/token.go delete mode 100644 vendor/golang.org/x/oauth2/transport.go delete mode 100644 vendor/google.golang.org/cloud/compute/metadata/metadata.go delete mode 100644 vendor/google.golang.org/cloud/internal/cloud.go rename vendor/{github.com/coreos/pkg => k8s.io/apimachinery}/LICENSE (99%) create mode 100644 vendor/k8s.io/apimachinery/pkg/api/equality/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/api/equality/semantic.go create mode 100644 vendor/k8s.io/apimachinery/pkg/api/errors/BUILD create mode 100755 vendor/k8s.io/apimachinery/pkg/api/errors/OWNERS rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/errors/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/errors/errors.go (68%) create mode 100644 vendor/k8s.io/apimachinery/pkg/api/meta/BUILD create mode 100755 vendor/k8s.io/apimachinery/pkg/api/meta/OWNERS rename vendor/k8s.io/{client-go/pkg/api/mapper.go => apimachinery/pkg/api/meta/default.go} (57%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/errors.go (86%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/firsthit_restmapper.go (79%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/help.go (92%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/interfaces.go (69%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/meta.go (81%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/multirestmapper.go (70%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/priority.go (74%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/restmapper.go (69%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/meta/unstructured.go (71%) create mode 100644 vendor/k8s.io/apimachinery/pkg/api/resource/BUILD create mode 100755 vendor/k8s.io/apimachinery/pkg/api/resource/OWNERS rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/amount.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/api/resource/generated.pb.go rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/generated.proto (96%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/math.go (97%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/quantity.go (99%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/quantity_proto.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/scale_int.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/api/resource/suffix.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apimachinery/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/apimachinery/announced/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/apimachinery/announced/announced.go (91%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/apimachinery/announced/group_factory.go (83%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/apimachinery/doc.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apimachinery/registered/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/apimachinery/registered/registered.go (73%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/apimachinery/types.go (75%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD create mode 100755 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/OWNERS rename vendor/k8s.io/{client-go/pkg/api => apimachinery/pkg/apis/meta/v1}/conversion.go (77%) rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/apis/meta/v1}/doc.go (94%) rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/apis/meta/v1}/duration.go (98%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/apis/meta/v1}/helpers.go (75%) rename vendor/k8s.io/{client-go/pkg/util/labels => apimachinery/pkg/apis/meta/v1}/labels.go (50%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/meta.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/register.go rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/apis/meta/v1}/time.go (96%) rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/apis/meta/v1}/time_proto.go (96%) rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/apis/meta/v1}/types.go (54%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/BUILD rename vendor/k8s.io/{client-go/pkg/runtime => apimachinery/pkg/apis/meta/v1/unstructured}/unstructured.go (65%) rename vendor/k8s.io/{client-go/pkg/watch/versioned/register.go => apimachinery/pkg/apis/meta/v1/watch.go} (50%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/BUILD rename vendor/k8s.io/{client-go/pkg/apis/certificates => apimachinery/pkg/apis/meta}/v1alpha1/doc.go (77%) create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.pb.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/register.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.deepcopy.go rename vendor/k8s.io/{client-go/kubernetes/typed/certificates/v1alpha1/doc.go => apimachinery/pkg/apis/meta/v1alpha1/zz_generated.defaults.go} (54%) create mode 100644 vendor/k8s.io/apimachinery/pkg/conversion/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/cloner.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/converter.go (93%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/deep_equal.go (94%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/helper.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/conversion/queryparams/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/queryparams/convert.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/conversion/queryparams/doc.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/conversion/unstructured/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/conversion/unstructured/converter.go create mode 100644 vendor/k8s.io/apimachinery/pkg/conversion/unstructured/doc.go create mode 100644 vendor/k8s.io/apimachinery/pkg/fields/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/fields/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/fields/fields.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/fields/requirements.go (95%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/fields/selector.go (53%) create mode 100644 vendor/k8s.io/apimachinery/pkg/labels/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/labels/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/labels/labels.go (97%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/labels/selector.go (91%) create mode 100644 vendor/k8s.io/apimachinery/pkg/openapi/BUILD rename vendor/k8s.io/{client-go/pkg/genericapiserver/openapi/common => apimachinery/pkg/openapi}/common.go (72%) rename vendor/k8s.io/{client-go/pkg/genericapiserver/openapi/common => apimachinery/pkg/openapi}/doc.go (83%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/codec.go (76%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/codec_check.go (81%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/conversion.go (98%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/embedded.go (90%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/error.go (80%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/extension.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/generated.pb.go (67%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/generated.proto (91%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/helper.go (95%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/interfaces.go (88%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/register.go (73%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/schema/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.pb.go create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto rename vendor/k8s.io/{client-go/pkg/api/unversioned => apimachinery/pkg/runtime/schema}/group_version.go (73%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/schema/interfaces.go rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/scheme.go (86%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/scheme_builder.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/serializer/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/codec_factory.go (93%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/json/json.go (94%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/json/meta.go (84%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/negotiated_codec.go (97%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/protobuf/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/protobuf/protobuf.go (94%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/protobuf_extension.go (94%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/recognizer/recognizer.go (93%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/streaming/streaming.go (91%) create mode 100644 vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/serializer/versioning/versioning.go (91%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/swagger_doc_generator.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/types.go (87%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/types_proto.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/runtime/zz_generated.deepcopy.go (58%) create mode 100644 vendor/k8s.io/apimachinery/pkg/selection/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/selection/operator.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/types/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/types/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/types/namespacedname.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/types/nodename.go (100%) rename vendor/k8s.io/{client-go/pkg/util/jsonpath/doc.go => apimachinery/pkg/types/patch.go} (56%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/types/uid.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/cache/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/util/cache/cache.go create mode 100644 vendor/k8s.io/apimachinery/pkg/util/cache/lruexpirecache.go create mode 100644 vendor/k8s.io/apimachinery/pkg/util/clock/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/clock/clock.go (65%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/diff/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/diff/diff.go (99%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/errors/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/errors/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/errors/errors.go (90%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/framer/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/framer/framer.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/intstr/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/intstr/generated.pb.go (61%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/intstr/generated.proto (93%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/intstr/intstr.go (88%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/json/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/json/json.go (100%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/net/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/net/http.go (55%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/net/interface.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/net/port_range.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/net/port_split.go (98%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/net/util.go (81%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/rand/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/rand/rand.go (84%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/runtime/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/runtime/runtime.go (76%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/sets/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/sets/byte.go (99%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/sets/doc.go (94%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/sets/empty.go (95%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/sets/int.go (99%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/sets/int64.go (99%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/sets/string.go (99%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/validation/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/util/validation/field/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/validation/field/errors.go (85%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/validation/field/path.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/validation/validation.go (73%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/wait/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/wait/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/wait/wait.go (92%) create mode 100644 vendor/k8s.io/apimachinery/pkg/util/yaml/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/util/yaml/decoder.go (90%) create mode 100644 vendor/k8s.io/apimachinery/pkg/version/BUILD create mode 100644 vendor/k8s.io/apimachinery/pkg/version/doc.go create mode 100644 vendor/k8s.io/apimachinery/pkg/version/types.go create mode 100644 vendor/k8s.io/apimachinery/pkg/watch/BUILD rename vendor/k8s.io/{client-go => apimachinery}/pkg/watch/doc.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/watch/filter.go (100%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/watch/mux.go (97%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/watch/streamwatcher.go (96%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/watch/until.go (91%) rename vendor/k8s.io/{client-go => apimachinery}/pkg/watch/watch.go (99%) create mode 100644 vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/BUILD rename vendor/k8s.io/{client-go/pkg => apimachinery}/third_party/forked/golang/reflect/deep_equal.go (100%) rename vendor/k8s.io/{client-go/pkg => apimachinery}/third_party/forked/golang/reflect/type.go (100%) create mode 100644 vendor/k8s.io/client-go/discovery/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/BUILD delete mode 100644 vendor/k8s.io/client-go/kubernetes/import_known_versions.go create mode 100644 vendor/k8s.io/client-go/kubernetes/scheme/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/scheme/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/scheme/register.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/deployment.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/scale.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/authentication_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/authorization_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/autoscaling_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/horizontalpodautoscaler.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/batch/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/BUILD delete mode 100644 vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/job.go delete mode 100644 vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificates_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificates_client.go rename vendor/k8s.io/client-go/kubernetes/typed/certificates/{v1alpha1 => v1beta1}/certificatesigningrequest.go (65%) rename vendor/k8s.io/client-go/kubernetes/typed/certificates/{v1alpha1 => v1beta1}/certificatesigningrequest_expansion.go (90%) create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/core/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/BUILD delete mode 100644 vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/job.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go delete mode 100644 vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/poddisruptionbudget.go delete mode 100644 vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/policy_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrole.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrolebinding.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/doc.go rename vendor/k8s.io/client-go/{plugin/pkg/client/auth/plugins.go => kubernetes/typed/rbac/v1beta1/generated_expansion.go} (71%) create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rbac_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/role.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rolebinding.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/podpreset.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/settings_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/storage/v1/BUILD create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/storage/v1/doc.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/storage/v1/generated_expansion.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storage_client.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storageclass.go create mode 100644 vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/api/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/api/annotation_key_constants.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/context.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/helpers.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/install/install.go rename vendor/k8s.io/client-go/pkg/api/{meta/metatypes/types.go => json.go} (50%) delete mode 100644 vendor/k8s.io/client-go/pkg/api/meta.go create mode 100644 vendor/k8s.io/client-go/pkg/api/objectreference.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/requestcontext.go create mode 100644 vendor/k8s.io/client-go/pkg/api/resource.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/resource/generated.pb.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/resource_helpers.go create mode 100644 vendor/k8s.io/client-go/pkg/api/taint.go create mode 100644 vendor/k8s.io/client-go/pkg/api/toleration.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/types.generated.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/unversioned/generated.pb.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/unversioned/generated.proto delete mode 100644 vendor/k8s.io/client-go/pkg/api/unversioned/meta.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/unversioned/types_swagger_doc_generated.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/unversioned/well_known_labels.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/unversioned/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/api/v1/OWNERS create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/annotation_key_constants.go rename vendor/k8s.io/client-go/pkg/api/{ => v1}/generate.go (97%) delete mode 100644 vendor/k8s.io/client-go/pkg/api/v1/helpers.go create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/objectreference.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/v1/ref.go create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/ref/BUILD rename vendor/k8s.io/client-go/pkg/api/{ => v1/ref}/ref.go (74%) create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/resource.go create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/taint.go create mode 100644 vendor/k8s.io/client-go/pkg/api/v1/toleration.go delete mode 100644 vendor/k8s.io/client-go/pkg/api/validation/path/name.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/BUILD rename vendor/k8s.io/client-go/{kubernetes/typed/policy/v1alpha1 => pkg/apis/admissionregistration}/doc.go (56%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go rename vendor/k8s.io/client-go/pkg/apis/{policy => admissionregistration}/v1alpha1/doc.go (59%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/apps/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/apps/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/apps/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/apps/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/authentication/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/BUILD rename vendor/k8s.io/client-go/pkg/{types/unix_user_id.go => apis/authentication/v1/conversion.go} (69%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/authorization/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/autoscaling/OWNERS create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/annotations.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/defaults.go rename vendor/k8s.io/client-go/{kubernetes/typed/certificates/v1alpha1/generated_expansion.go => pkg/apis/autoscaling/v2alpha1/doc.go} (97%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/batch/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/batch/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/batch/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/batch/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/batch/v1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/certificates/OWNERS create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/helpers.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/types.generated.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.generated.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.conversion.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/BUILD rename vendor/k8s.io/client-go/pkg/apis/certificates/{v1alpha1 => v1beta1}/conversion.go (83%) rename vendor/k8s.io/client-go/pkg/{api/unversioned/register.go => apis/certificates/v1beta1/defaults.go} (59%) rename vendor/k8s.io/client-go/{kubernetes/typed/policy/v1alpha1/generated_expansion.go => pkg/apis/certificates/v1beta1/doc.go} (89%) rename vendor/k8s.io/client-go/pkg/apis/certificates/{v1alpha1 => v1beta1}/generated.pb.go (55%) rename vendor/k8s.io/client-go/pkg/apis/certificates/{v1alpha1 => v1beta1}/generated.proto (58%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/helpers.go rename vendor/k8s.io/client-go/pkg/apis/certificates/{v1alpha1 => v1beta1}/register.go (55%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.generated.go rename vendor/k8s.io/client-go/pkg/apis/certificates/{v1alpha1 => v1beta1}/types.go (51%) rename vendor/k8s.io/client-go/pkg/apis/certificates/{v1alpha1 => v1beta1}/types_swagger_doc_generated.go (78%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/extensions/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/extensions/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/extensions/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/extensions/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/networking/OWNERS create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/conversion.go rename vendor/k8s.io/client-go/pkg/{api => apis/networking/v1}/defaults.go (61%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/policy/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/policy/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/policy/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/policy/types.generated.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/rbac/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/install/install.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/helpers.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/helpers.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/BUILD rename vendor/k8s.io/client-go/pkg/{util/labels => apis/settings}/doc.go (87%) rename vendor/k8s.io/client-go/pkg/apis/{policy/v1alpha1 => settings}/register.go (57%) create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/settings/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/BUILD create mode 100755 vendor/k8s.io/client-go/pkg/apis/storage/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/install/install.go delete mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/types.generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/doc.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.proto create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/register.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/types.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/types_swagger_doc_generated.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.conversion.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.deepcopy.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.defaults.go create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.defaults.go delete mode 100644 vendor/k8s.io/client-go/pkg/auth/user/doc.go delete mode 100644 vendor/k8s.io/client-go/pkg/auth/user/user.go delete mode 100644 vendor/k8s.io/client-go/pkg/conversion/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/runtime/OWNERS delete mode 100644 vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/exec.go delete mode 100644 vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/funcs.go create mode 100644 vendor/k8s.io/client-go/pkg/util/BUILD delete mode 100644 vendor/k8s.io/client-go/pkg/util/jsonpath/jsonpath.go delete mode 100644 vendor/k8s.io/client-go/pkg/util/jsonpath/node.go delete mode 100644 vendor/k8s.io/client-go/pkg/util/jsonpath/parser.go create mode 100644 vendor/k8s.io/client-go/pkg/util/parsers/BUILD delete mode 100644 vendor/k8s.io/client-go/pkg/util/ratelimit/bucket.go delete mode 100644 vendor/k8s.io/client-go/pkg/util/trace.go delete mode 100644 vendor/k8s.io/client-go/pkg/util/trie.go delete mode 100644 vendor/k8s.io/client-go/pkg/util/uuid/uuid.go create mode 100644 vendor/k8s.io/client-go/pkg/version/BUILD create mode 100644 vendor/k8s.io/client-go/pkg/version/def.bzl delete mode 100644 vendor/k8s.io/client-go/pkg/version/semver.go delete mode 100644 vendor/k8s.io/client-go/pkg/watch/versioned/generated.pb.go delete mode 100644 vendor/k8s.io/client-go/pkg/watch/versioned/generated.proto delete mode 100644 vendor/k8s.io/client-go/pkg/watch/versioned/types.go delete mode 100644 vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/OWNERS delete mode 100644 vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/gcp.go delete mode 100644 vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/OWNERS delete mode 100644 vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/oidc.go create mode 100644 vendor/k8s.io/client-go/rest/BUILD create mode 100755 vendor/k8s.io/client-go/rest/OWNERS create mode 100644 vendor/k8s.io/client-go/rest/watch/BUILD rename vendor/k8s.io/client-go/{pkg/watch/versioned => rest/watch}/decoder.go (88%) rename vendor/k8s.io/client-go/{pkg/watch/versioned => rest/watch}/encoder.go (79%) create mode 100644 vendor/k8s.io/client-go/tools/auth/BUILD create mode 100644 vendor/k8s.io/client-go/tools/cache/BUILD create mode 100755 vendor/k8s.io/client-go/tools/cache/OWNERS delete mode 100644 vendor/k8s.io/client-go/tools/cache/listers_core.go delete mode 100644 vendor/k8s.io/client-go/tools/cache/listers_extensions.go delete mode 100644 vendor/k8s.io/client-go/tools/cache/listers_rbac.go create mode 100644 vendor/k8s.io/client-go/tools/cache/mutation_cache.go create mode 100644 vendor/k8s.io/client-go/tools/clientcmd/BUILD create mode 100644 vendor/k8s.io/client-go/tools/clientcmd/api/BUILD create mode 100644 vendor/k8s.io/client-go/tools/clientcmd/api/latest/BUILD create mode 100644 vendor/k8s.io/client-go/tools/clientcmd/api/v1/BUILD create mode 100644 vendor/k8s.io/client-go/tools/clientcmd/helpers.go create mode 100644 vendor/k8s.io/client-go/tools/metrics/BUILD create mode 100755 vendor/k8s.io/client-go/tools/metrics/OWNERS create mode 100644 vendor/k8s.io/client-go/transport/BUILD create mode 100755 vendor/k8s.io/client-go/transport/OWNERS create mode 100644 vendor/k8s.io/client-go/util/cert/BUILD rename vendor/k8s.io/client-go/{pkg => }/util/cert/cert.go (91%) rename vendor/k8s.io/client-go/{pkg => }/util/cert/csr.go (60%) rename vendor/k8s.io/client-go/{pkg => }/util/cert/io.go (57%) rename vendor/k8s.io/client-go/{pkg => }/util/cert/pem.go (56%) create mode 100644 vendor/k8s.io/client-go/util/flowcontrol/BUILD rename vendor/k8s.io/client-go/{pkg => }/util/flowcontrol/backoff.go (98%) rename vendor/k8s.io/client-go/{pkg => }/util/flowcontrol/throttle.go (84%) create mode 100644 vendor/k8s.io/client-go/util/homedir/BUILD rename vendor/k8s.io/client-go/{pkg => }/util/homedir/homedir.go (87%) create mode 100644 vendor/k8s.io/client-go/util/integer/BUILD rename vendor/k8s.io/client-go/{pkg => }/util/integer/integer.go (100%) rename vendor/{github.com/coreos/go-oidc => k8s.io/kubernetes}/LICENSE (99%) create mode 100644 vendor/k8s.io/kubernetes/pkg/api/unversioned/BUILD create mode 100644 vendor/k8s.io/kubernetes/pkg/api/unversioned/duration.go create mode 100644 vendor/k8s.io/kubernetes/pkg/api/unversioned/time.go create mode 100644 vendor/k8s.io/kubernetes/pkg/api/unversioned/types.go diff --git a/Godeps/Godeps.json b/Godeps/Godeps.json index e0f7d3c615..8fab0c2d11 100644 --- a/Godeps/Godeps.json +++ b/Godeps/Godeps.json @@ -1,7 +1,10 @@ { "ImportPath": "k8s.io/kube-state-metrics", "GoVersion": "go1.7", - "GodepVersion": "v78", + "GodepVersion": "v74", + "Packages": [ + "./..." + ], "Deps": [ { "ImportPath": "github.com/PuerkitoBio/purell", @@ -16,46 +19,6 @@ "ImportPath": "github.com/beorn7/perks/quantile", "Rev": "4c0e84591b9aa9e6dcfdf3e020114cd81f89d5f9" }, - { - "ImportPath": "github.com/blang/semver", - "Comment": "v3.0.1", - "Rev": "31b736133b98f26d5e078ec9eb591666edfd091f" - }, - { - "ImportPath": "github.com/coreos/go-oidc/http", - "Rev": "16c5ecc505f1efa0fe4685826fd9962c4d137e87" - }, - { - "ImportPath": "github.com/coreos/go-oidc/jose", - "Rev": "16c5ecc505f1efa0fe4685826fd9962c4d137e87" - }, - { - "ImportPath": "github.com/coreos/go-oidc/key", - "Rev": "16c5ecc505f1efa0fe4685826fd9962c4d137e87" - }, - { - "ImportPath": "github.com/coreos/go-oidc/oauth2", - "Rev": "16c5ecc505f1efa0fe4685826fd9962c4d137e87" - }, - { - "ImportPath": "github.com/coreos/go-oidc/oidc", - "Rev": "16c5ecc505f1efa0fe4685826fd9962c4d137e87" - }, - { - "ImportPath": "github.com/coreos/pkg/health", - "Comment": "v3", - "Rev": "3ac0863d7acf3bc44daf49afef8919af12f704ef" - }, - { - "ImportPath": "github.com/coreos/pkg/httputil", - "Comment": "v3", - "Rev": "3ac0863d7acf3bc44daf49afef8919af12f704ef" - }, - { - "ImportPath": "github.com/coreos/pkg/timeutil", - "Comment": "v3", - "Rev": "3ac0863d7acf3bc44daf49afef8919af12f704ef" - }, { "ImportPath": "github.com/davecgh/go-spew/spew", "Rev": "5215b55f46b2b919f50a1df0eaa5886afe4e3b3d" @@ -76,12 +39,12 @@ "Rev": "89ef8af493ab468a45a42bb0d89a06fccdd2fb22" }, { - "ImportPath": "github.com/emicklei/go-restful/log", - "Comment": "v1.2-79-g89ef8af", - "Rev": "89ef8af493ab468a45a42bb0d89a06fccdd2fb22" + "ImportPath": "github.com/emicklei/go-restful-swagger12", + "Comment": "1.0.1", + "Rev": "dcef7f55730566d41eae5db10e7d6981829720f6" }, { - "ImportPath": "github.com/emicklei/go-restful/swagger", + "ImportPath": "github.com/emicklei/go-restful/log", "Comment": "v1.2-79-g89ef8af", "Rev": "89ef8af493ab468a45a42bb0d89a06fccdd2fb22" }, @@ -89,6 +52,10 @@ "ImportPath": "github.com/ghodss/yaml", "Rev": "73d445a93680fa1a78ae23a5839bad48f32ba1ee" }, + { + "ImportPath": "github.com/go-openapi/analysis", + "Rev": "b44dc874b601d9e4e2f6e19140e794ba24bead3b" + }, { "ImportPath": "github.com/go-openapi/jsonpointer", "Rev": "46af16f9f7b149af66e5d1bd010e3574dc06de98" @@ -97,6 +64,10 @@ "ImportPath": "github.com/go-openapi/jsonreference", "Rev": "13c6e3589ad90f49bd3e3bbe2c2cb3d7a4142272" }, + { + "ImportPath": "github.com/go-openapi/loads", + "Rev": "18441dfa706d924a39a030ee2c3b1d8d81917b38" + }, { "ImportPath": "github.com/go-openapi/spec", "Rev": "2433d2f0fc794728337e0c5d65716e79e163f04d" @@ -107,13 +78,13 @@ }, { "ImportPath": "github.com/gogo/protobuf/proto", - "Comment": "v0.2-33-ge18d7aa", - "Rev": "e18d7aa8f8c624c915db340349aad4c49b10d173" + "Comment": "v0.3-162-gc0656ed", + "Rev": "c0656edd0d9eab7c66d1eb0c568f9039345796f7" }, { "ImportPath": "github.com/gogo/protobuf/sortkeys", - "Comment": "v0.2-33-ge18d7aa", - "Rev": "e18d7aa8f8c624c915db340349aad4c49b10d173" + "Comment": "v0.3-162-gc0656ed", + "Rev": "c0656edd0d9eab7c66d1eb0c568f9039345796f7" }, { "ImportPath": "github.com/golang/glog", @@ -127,6 +98,14 @@ "ImportPath": "github.com/google/gofuzz", "Rev": "bbcb9da2d746f8bdbd6a936686a0a6067ada0ec5" }, + { + "ImportPath": "github.com/hashicorp/golang-lru", + "Rev": "0a025b7e63adc15a622f29b0b2c4c3848243bbf6" + }, + { + "ImportPath": "github.com/hashicorp/golang-lru/simplelru", + "Rev": "0a025b7e63adc15a622f29b0b2c4c3848243bbf6" + }, { "ImportPath": "github.com/howeyc/gopass", "Rev": "26c6e1184fd5255fa5f5289d0b789a4819c203a4" @@ -136,14 +115,9 @@ "Comment": "0.1.3-8-g6633656", "Rev": "6633656539c1639d9d78127b7d47c622b5d7b6dc" }, - { - "ImportPath": "github.com/jonboulle/clockwork", - "Comment": "v0.1.0-4-gbcac988", - "Rev": "bcac9884e7502bb2b474c0339d889cb981a2f27f" - }, { "ImportPath": "github.com/juju/ratelimit", - "Rev": "77ed1c8a01217656d2080ad51981f6e99adaa177" + "Rev": "5b9ff866471762aa2ab2dced63c9fb6f53921342" }, { "ImportPath": "github.com/mailru/easyjson/buffer", @@ -168,11 +142,12 @@ "Rev": "8f127d736703e5139c0b6cfb423acd15618318ec" }, { - "ImportPath": "github.com/pborman/uuid", - "Rev": "ca53cad383cad2479bbba7f7a1a05797ec1386e4" + "ImportPath": "github.com/prometheus/client_golang/prometheus", + "Comment": "v0.8.0-5-g8aae34f", + "Rev": "8aae34f3ffc9a93c75efeaad87bb192aa7750900" }, { - "ImportPath": "github.com/prometheus/client_golang/prometheus", + "ImportPath": "github.com/prometheus/client_golang/prometheus/promhttp", "Comment": "v0.8.0-5-g8aae34f", "Rev": "8aae34f3ffc9a93c75efeaad87bb192aa7750900" }, @@ -197,9 +172,14 @@ "ImportPath": "github.com/prometheus/procfs", "Rev": "abf152e5f3e97f2fafac028d2cc06c1feb87ffa5" }, + { + "ImportPath": "github.com/robfig/cron", + "Comment": "v1-58-g736158d", + "Rev": "736158dc09e10f1911ca3a1e1b01f11b566ce5db" + }, { "ImportPath": "github.com/spf13/pflag", - "Rev": "1560c1005499d61b80f865c04d39ca7505bf7f0b" + "Rev": "9ff6c6923cfffbcd502984b8e0c80539a94968b7" }, { "ImportPath": "github.com/ugorji/go/codec", @@ -213,10 +193,6 @@ "ImportPath": "golang.org/x/net/context", "Rev": "e90d6d0afc4c315a0d87a568ae68577cc15149a0" }, - { - "ImportPath": "golang.org/x/net/context/ctxhttp", - "Rev": "e90d6d0afc4c315a0d87a568ae68577cc15149a0" - }, { "ImportPath": "golang.org/x/net/http2", "Rev": "e90d6d0afc4c315a0d87a568ae68577cc15149a0" @@ -233,26 +209,6 @@ "ImportPath": "golang.org/x/net/lex/httplex", "Rev": "e90d6d0afc4c315a0d87a568ae68577cc15149a0" }, - { - "ImportPath": "golang.org/x/oauth2", - "Rev": "b5adcc2dcdf009d0391547edc6ecbaff889f5bb9" - }, - { - "ImportPath": "golang.org/x/oauth2/google", - "Rev": "b5adcc2dcdf009d0391547edc6ecbaff889f5bb9" - }, - { - "ImportPath": "golang.org/x/oauth2/internal", - "Rev": "b5adcc2dcdf009d0391547edc6ecbaff889f5bb9" - }, - { - "ImportPath": "golang.org/x/oauth2/jws", - "Rev": "b5adcc2dcdf009d0391547edc6ecbaff889f5bb9" - }, - { - "ImportPath": "golang.org/x/oauth2/jwt", - "Rev": "b5adcc2dcdf009d0391547edc6ecbaff889f5bb9" - }, { "ImportPath": "golang.org/x/sys/unix", "Rev": "30de6d19a3bd89a5f38ae4028e23aaa5582648af" @@ -297,14 +253,6 @@ "ImportPath": "golang.org/x/text/width", "Rev": "1e65e9bf72c307081cea196f47ef37aed17eb316" }, - { - "ImportPath": "google.golang.org/cloud/compute/metadata", - "Rev": "eb47ba841d53d93506cfbfbc03927daf9cc48f88" - }, - { - "ImportPath": "google.golang.org/cloud/internal", - "Rev": "eb47ba841d53d93506cfbfbc03927daf9cc48f88" - }, { "ImportPath": "gopkg.in/inf.v0", "Comment": "v0.9.0", @@ -315,942 +263,560 @@ "Rev": "53feefa2559fb8dfa8d81baad31be332c97d6c77" }, { - "ImportPath": "k8s.io/client-go/discovery", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/api/equality", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/api/errors", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/apps/v1alpha1", - "Rev": "d72c0e162789e1bbb33c33cfa26858a1375efe01" + "ImportPath": "k8s.io/apimachinery/pkg/api/meta", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/authentication/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/api/resource", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/authorization/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/apimachinery", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/autoscaling/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/apimachinery/announced", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/batch/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/apimachinery/registered", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/certificates/v1alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/core/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/extensions/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/apis/meta/v1alpha1", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/policy/v1alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/conversion", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/conversion/queryparams", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/storage/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/conversion/unstructured", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/fields", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/errors", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/labels", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/openapi", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/meta", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/meta/metatypes", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/schema", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/resource", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/unversioned", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/json", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/protobuf", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/api/validation/path", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/recognizer", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apimachinery", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/streaming", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apimachinery/announced", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/runtime/serializer/versioning", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apimachinery/registered", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/selection", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/apps", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/types", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/apps/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/cache", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/apps/v1alpha1", - "Rev": "d72c0e162789e1bbb33c33cfa26858a1375efe01" + "ImportPath": "k8s.io/apimachinery/pkg/util/clock", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/authentication", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/diff", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/authentication/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/errors", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/authentication/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/framer", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/authorization", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/intstr", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/authorization/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/json", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/authorization/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/net", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/autoscaling", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/autoscaling/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/autoscaling/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/batch", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/batch/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/batch/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/batch/v2alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/certificates", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/certificates/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/certificates/v1alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/extensions", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/rand", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/extensions/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/runtime", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/extensions/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/sets", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/policy", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/validation", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/policy/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/validation/field", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/policy/v1alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/wait", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/rbac", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/util/yaml", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/rbac/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/version", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/rbac/v1alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/pkg/watch", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/storage", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/apimachinery/third_party/forked/golang/reflect", + "Rev": "abe34e4f5b4413c282a83011892cbeea5b32223b" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/storage/install", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/apis/storage/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/auth/user", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/conversion", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/conversion/queryparams", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/fields", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/genericapiserver/openapi/common", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/labels", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime/serializer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime/serializer/json", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime/serializer/protobuf", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime/serializer/recognizer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime/serializer/streaming", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/runtime/serializer/versioning", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/selection", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/third_party/forked/golang/reflect", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/types", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/cert", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/clock", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/errors", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/flowcontrol", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/framer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/homedir", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/integer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/intstr", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/json", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/labels", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/net", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/parsers", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/rand", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/runtime", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/sets", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/uuid", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/validation", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/validation/field", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/wait", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/util/yaml", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/version", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/watch", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/pkg/watch/versioned", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/plugin/pkg/client/auth", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/plugin/pkg/client/auth/gcp", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/plugin/pkg/client/auth/oidc", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/rest", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/auth", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/cache", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/clientcmd", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/clientcmd/api", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/clientcmd/api/latest", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/clientcmd/api/v1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/tools/metrics", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/transport", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/vendor/github.com/emicklei/go-restful/swagger", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/vendor/github.com/golang/glog", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/vendor/github.com/emicklei/go-restful", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/vendor/github.com/emicklei/go-restful/log", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" - }, - { - "ImportPath": "k8s.io/client-go/vendor/github.com/davecgh/go-spew/spew", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/discovery", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/ugorji/go/codec", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/net/context", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/scheme", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/go-openapi/spec", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/gogo/protobuf/proto", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/apps/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/gogo/protobuf/sortkeys", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/authentication/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/google/gofuzz", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/authentication/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/blang/semver", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/authorization/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/spf13/pflag", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/authorization/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/gopkg.in/inf.v0", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/autoscaling/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/pborman/uuid", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/go-openapi/jsonpointer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/batch/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/go-openapi/jsonreference", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/batch/v2alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/go-openapi/swag", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/certificates/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/docker/distribution/reference", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/core/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/ghodss/yaml", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/extensions/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/oauth2", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/networking/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/oauth2/google", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/policy/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/pkg/util/jsonpath", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/go-oidc/jose", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/rbac/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/go-oidc/oauth2", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/settings/v1alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/go-oidc/oidc", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/storage/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/pkg/util/ratelimit", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/kubernetes/typed/storage/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/net/http2", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/api", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/PuerkitoBio/purell", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/api/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/mailru/easyjson/jlexer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/api/v1/ref", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/mailru/easyjson/jwriter", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/admissionregistration", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/docker/distribution/digest", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/gopkg.in/yaml.v2", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/apps", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/oauth2/internal", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/apps/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/cloud.google.com/go/compute/metadata", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/authentication", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/oauth2/jws", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/authentication/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/oauth2/jwt", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/authentication/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/authorization", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/pkg/third_party/forked/golang/template", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/authorization/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/go-oidc/http", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/authorization/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/go-oidc/key", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/autoscaling", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/pkg/timeutil", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/autoscaling/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/jonboulle/clockwork", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/autoscaling/v2alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/net/http2/hpack", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/batch", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/net/lex/httplex", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/batch/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/PuerkitoBio/urlesc", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/batch/v2alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/net/idna", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/certificates", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/secure/precis", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/certificates/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/unicode/norm", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/extensions", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/mailru/easyjson/buffer", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/extensions/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/cloud.google.com/go/internal", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/networking", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/net/context/ctxhttp", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/networking/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/golang/protobuf/proto", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/policy", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/policy/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal/app_identity", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/rbac", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal/modules", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/rbac/v1alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/pkg/health", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/rbac/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/cases", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/settings", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/runes", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/settings/v1alpha1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/secure/bidirule", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/storage", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/transform", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/storage/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/width", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/apis/storage/v1beta1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal/base", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/util", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal/datastore", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/util/parsers", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal/log", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/pkg/version", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/google.golang.org/appengine/internal/remote_api", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/rest", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/coreos/pkg/httputil", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/rest/watch", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/language", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/auth", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/unicode/bidi", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/cache", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/text/internal/tag", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/clientcmd", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/apps/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/clientcmd/api", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/batch/v2alpha1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/clientcmd/api/latest", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/kubernetes/typed/policy/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/clientcmd/api/v1", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/apps/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/tools/metrics", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/pkg/apis/policy/v1beta1", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/transport", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/pkg/util/diff", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/util/cert", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/howeyc/gopass", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/util/flowcontrol", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/github.com/imdario/mergo", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/util/homedir", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/crypto/ssh/terminal", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/client-go/util/integer", + "Comment": "v4.0.0-beta.0", + "Rev": "df46f7f13b3da19b90b8b4f0d18b8adc6fbf28dc" }, { - "ImportPath": "k8s.io/client-go/vendor/golang.org/x/sys/unix", - "Comment": "v2.0.0-alpha.1", - "Rev": "d81cb85237595f720d83eda492bae8f6162fc5c0" + "ImportPath": "k8s.io/kubernetes/pkg/api/unversioned", + "Comment": "v1.7.2", + "Rev": "922a86cfcd65915a9b2f69f3f193b8907d741d9c" } ] } diff --git a/collectors/cronjob.go b/collectors/cronjob.go index d70ec4c39a..99cb39ec89 100644 --- a/collectors/cronjob.go +++ b/collectors/cronjob.go @@ -24,9 +24,9 @@ import ( "github.com/prometheus/client_golang/prometheus" "github.com/robfig/cron" "golang.org/x/net/context" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/kubernetes" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" v2batch "k8s.io/client-go/pkg/apis/batch/v2alpha1" "k8s.io/client-go/tools/cache" ) @@ -117,7 +117,7 @@ func (cjc *cronJobCollector) Collect(ch chan<- prometheus.Metric) { } } -func getNextScheduledTime(schedule string, lastScheduleTime *unversioned.Time, createdTime unversioned.Time) (time.Time, error) { +func getNextScheduledTime(schedule string, lastScheduleTime *metav1.Time, createdTime metav1.Time) (time.Time, error) { sched, err := cron.ParseStandard(schedule) if err != nil { return time.Time{}, fmt.Errorf("Failed to parse cron job schedule '%s': %s", schedule, err) diff --git a/collectors/cronjob_test.go b/collectors/cronjob_test.go index 569d1a3879..a69d3a5b18 100644 --- a/collectors/cronjob_test.go +++ b/collectors/cronjob_test.go @@ -20,18 +20,18 @@ import ( "testing" "time" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/api/unversioned" v2batch "k8s.io/client-go/pkg/apis/batch/v2alpha1" ) var ( - SuspendTrue bool = true - SuspendFalse bool = false + SuspendTrue bool = true + SuspendFalse bool = false StartingDeadlineSeconds300 int64 = 300 - ActiveRunningCronJob1LastScheduleTime, _ = time.Parse(time.RFC3339, "2017-05-26T12:00:07Z") - SuspendedCronJob1LastScheduleTime, _ = time.Parse(time.RFC3339, "2017-05-26T17:30:00Z") + ActiveRunningCronJob1LastScheduleTime, _ = time.Parse(time.RFC3339, "2017-05-26T12:00:07Z") + SuspendedCronJob1LastScheduleTime, _ = time.Parse(time.RFC3339, "2017-05-26T17:30:00Z") ActiveCronJob1NoLastScheduledCreationTimestamp, _ = time.Parse(time.RFC3339, "2017-05-26T18:30:00Z") ) @@ -62,58 +62,58 @@ func TestCronJobCollector(t *testing.T) { ` cases := []struct { cronJobs []v2batch.CronJob - want string + want string }{ { cronJobs: []v2batch.CronJob{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "ActiveRunningCronJob1", Namespace: "ns1", Generation: 1, }, Status: v2batch.CronJobStatus{ - Active: []v1.ObjectReference{v1.ObjectReference{Name: "FakeJob1"}, v1.ObjectReference{Name: "FakeJob2"}}, - LastScheduleTime: &unversioned.Time{Time: ActiveRunningCronJob1LastScheduleTime}, + Active: []v1.ObjectReference{v1.ObjectReference{Name: "FakeJob1"}, v1.ObjectReference{Name: "FakeJob2"}}, + LastScheduleTime: &metav1.Time{Time: ActiveRunningCronJob1LastScheduleTime}, }, Spec: v2batch.CronJobSpec{ - StartingDeadlineSeconds: &StartingDeadlineSeconds300, - ConcurrencyPolicy: "Forbid", - Suspend: &SuspendFalse, - Schedule: "0 */6 * * *", + StartingDeadlineSeconds: &StartingDeadlineSeconds300, + ConcurrencyPolicy: "Forbid", + Suspend: &SuspendFalse, + Schedule: "0 */6 * * *", }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "SuspendedCronJob1", Namespace: "ns1", Generation: 1, }, Status: v2batch.CronJobStatus{ - Active: []v1.ObjectReference{}, - LastScheduleTime: &unversioned.Time{Time: SuspendedCronJob1LastScheduleTime}, + Active: []v1.ObjectReference{}, + LastScheduleTime: &metav1.Time{Time: SuspendedCronJob1LastScheduleTime}, }, Spec: v2batch.CronJobSpec{ - StartingDeadlineSeconds: &StartingDeadlineSeconds300, - ConcurrencyPolicy: "Forbid", - Suspend: &SuspendTrue, - Schedule: "0 */3 * * *", + StartingDeadlineSeconds: &StartingDeadlineSeconds300, + ConcurrencyPolicy: "Forbid", + Suspend: &SuspendTrue, + Schedule: "0 */3 * * *", }, }, { - ObjectMeta: v1.ObjectMeta{ - Name: "ActiveCronJob1NoLastScheduled", - CreationTimestamp: unversioned.Time{Time: ActiveCronJob1NoLastScheduledCreationTimestamp}, - Namespace: "ns1", - Generation: 1, + ObjectMeta: metav1.ObjectMeta{ + Name: "ActiveCronJob1NoLastScheduled", + CreationTimestamp: metav1.Time{Time: ActiveCronJob1NoLastScheduledCreationTimestamp}, + Namespace: "ns1", + Generation: 1, }, Status: v2batch.CronJobStatus{ - Active: []v1.ObjectReference{}, - LastScheduleTime: nil, + Active: []v1.ObjectReference{}, + LastScheduleTime: nil, }, Spec: v2batch.CronJobSpec{ - StartingDeadlineSeconds: &StartingDeadlineSeconds300, - ConcurrencyPolicy: "Forbid", - Suspend: &SuspendFalse, - Schedule: "25 * * * *", + StartingDeadlineSeconds: &StartingDeadlineSeconds300, + ConcurrencyPolicy: "Forbid", + Suspend: &SuspendFalse, + Schedule: "25 * * * *", }, }, }, diff --git a/collectors/daemonset_test.go b/collectors/daemonset_test.go index c6dbc1eb05..fdc9af045e 100644 --- a/collectors/daemonset_test.go +++ b/collectors/daemonset_test.go @@ -19,7 +19,7 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/apis/extensions/v1beta1" ) @@ -53,7 +53,7 @@ func TestDaemonSetCollector(t *testing.T) { { dss: []v1beta1.DaemonSet{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "ds1", Namespace: "ns1", Generation: 21, @@ -65,7 +65,7 @@ func TestDaemonSetCollector(t *testing.T) { NumberReady: 5, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "ds2", Namespace: "ns2", Generation: 14, diff --git a/collectors/deployment.go b/collectors/deployment.go index 37c3e6b3b3..7ed8eae1d2 100644 --- a/collectors/deployment.go +++ b/collectors/deployment.go @@ -23,7 +23,7 @@ import ( "k8s.io/client-go/kubernetes" "k8s.io/client-go/pkg/api" "k8s.io/client-go/pkg/apis/extensions/v1beta1" - "k8s.io/client-go/pkg/util/intstr" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/tools/cache" ) diff --git a/collectors/deployment_test.go b/collectors/deployment_test.go index 2496cdd460..4a88571f2c 100644 --- a/collectors/deployment_test.go +++ b/collectors/deployment_test.go @@ -28,9 +28,9 @@ import ( dto "github.com/prometheus/client_model/go" "github.com/prometheus/common/expfmt" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/apis/extensions/v1beta1" - "k8s.io/client-go/pkg/util/intstr" ) var ( @@ -81,9 +81,9 @@ func TestDeploymentCollector(t *testing.T) { { depls: []v1beta1.Deployment{ { - ObjectMeta: v1.ObjectMeta{ - Name: "depl1", - Namespace: "ns1", + ObjectMeta: metav1.ObjectMeta{ + Name: "depl1", + Namespace: "ns1", Labels: map[string]string{ "app": "example1", }, @@ -105,9 +105,9 @@ func TestDeploymentCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ - Name: "depl2", - Namespace: "ns2", + ObjectMeta: metav1.ObjectMeta{ + Name: "depl2", + Namespace: "ns2", Labels: map[string]string{ "app": "example2", }, diff --git a/collectors/job_test.go b/collectors/job_test.go index 848465744d..9b387b982f 100644 --- a/collectors/job_test.go +++ b/collectors/job_test.go @@ -17,26 +17,26 @@ limitations under the License. package collectors import ( - "time" "testing" + "time" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/api/unversioned" v1batch "k8s.io/client-go/pkg/apis/batch/v1" ) var ( - Parallelism1 int32 = 1 - Completions1 int32 = 1 + Parallelism1 int32 = 1 + Completions1 int32 = 1 ActiveDeadlineSeconds900 int64 = 900 - RunningJob1StartTime, _ = time.Parse(time.RFC3339, "2017-05-26T12:00:07Z") + RunningJob1StartTime, _ = time.Parse(time.RFC3339, "2017-05-26T12:00:07Z") SuccessfulJob1StartTime, _ = time.Parse(time.RFC3339, "2017-05-26T12:00:07Z") - FailedJob1StartTime, _ = time.Parse(time.RFC3339, "2017-05-26T14:00:07Z") + FailedJob1StartTime, _ = time.Parse(time.RFC3339, "2017-05-26T14:00:07Z") SuccessfulJob2StartTime, _ = time.Parse(time.RFC3339, "2017-05-26T12:10:07Z") SuccessfulJob1CompletionTime, _ = time.Parse(time.RFC3339, "2017-05-26T13:00:07Z") - FailedJob1CompletionTime, _ = time.Parse(time.RFC3339, "2017-05-26T15:00:07Z") + FailedJob1CompletionTime, _ = time.Parse(time.RFC3339, "2017-05-26T15:00:07Z") SuccessfulJob2CompletionTime, _ = time.Parse(time.RFC3339, "2017-05-26T13:10:07Z") ) @@ -77,93 +77,90 @@ func TestJobCollector(t *testing.T) { ` cases := []struct { jobs []v1batch.Job - want string + want string }{ { jobs: []v1batch.Job{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "RunningJob1", Namespace: "ns1", Generation: 1, }, Status: v1batch.JobStatus{ - Active: 1, - Failed: 0, - Succeeded: 0, - CompletionTime: nil, - StartTime: &unversioned.Time{Time: RunningJob1StartTime}, + Active: 1, + Failed: 0, + Succeeded: 0, + CompletionTime: nil, + StartTime: &metav1.Time{Time: RunningJob1StartTime}, }, Spec: v1batch.JobSpec{ - ActiveDeadlineSeconds: &ActiveDeadlineSeconds900, - Parallelism: &Parallelism1, - Completions: &Completions1, + ActiveDeadlineSeconds: &ActiveDeadlineSeconds900, + Parallelism: &Parallelism1, + Completions: &Completions1, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "SuccessfulJob1", Namespace: "ns1", Generation: 1, }, Status: v1batch.JobStatus{ - Active: 0, - Failed: 0, - Succeeded: 1, - CompletionTime: &unversioned.Time{Time: SuccessfulJob1CompletionTime}, - StartTime: &unversioned.Time{Time: SuccessfulJob1StartTime}, - Conditions: []v1batch.JobCondition{ + Active: 0, + Failed: 0, + Succeeded: 1, + CompletionTime: &metav1.Time{Time: SuccessfulJob1CompletionTime}, + StartTime: &metav1.Time{Time: SuccessfulJob1StartTime}, + Conditions: []v1batch.JobCondition{ {Type: v1batch.JobComplete, Status: v1.ConditionTrue}, - }, - + }, }, Spec: v1batch.JobSpec{ - ActiveDeadlineSeconds: &ActiveDeadlineSeconds900, - Parallelism: &Parallelism1, - Completions: &Completions1, + ActiveDeadlineSeconds: &ActiveDeadlineSeconds900, + Parallelism: &Parallelism1, + Completions: &Completions1, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "FailedJob1", Namespace: "ns1", Generation: 1, }, Status: v1batch.JobStatus{ - Active: 0, - Failed: 1, - Succeeded: 0, - CompletionTime: &unversioned.Time{Time: FailedJob1CompletionTime}, - StartTime: &unversioned.Time{Time: FailedJob1StartTime}, - Conditions: []v1batch.JobCondition{ + Active: 0, + Failed: 1, + Succeeded: 0, + CompletionTime: &metav1.Time{Time: FailedJob1CompletionTime}, + StartTime: &metav1.Time{Time: FailedJob1StartTime}, + Conditions: []v1batch.JobCondition{ {Type: v1batch.JobFailed, Status: v1.ConditionTrue}, - }, - + }, }, Spec: v1batch.JobSpec{ - ActiveDeadlineSeconds: &ActiveDeadlineSeconds900, - Parallelism: &Parallelism1, - Completions: &Completions1, + ActiveDeadlineSeconds: &ActiveDeadlineSeconds900, + Parallelism: &Parallelism1, + Completions: &Completions1, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "SuccessfulJob2NoActiveDeadlineSeconds", Namespace: "ns1", Generation: 1, }, Status: v1batch.JobStatus{ - Active: 0, - Failed: 0, - Succeeded: 1, - CompletionTime: &unversioned.Time{Time: SuccessfulJob2CompletionTime}, - StartTime: &unversioned.Time{Time: SuccessfulJob2StartTime}, - Conditions: []v1batch.JobCondition{ + Active: 0, + Failed: 0, + Succeeded: 1, + CompletionTime: &metav1.Time{Time: SuccessfulJob2CompletionTime}, + StartTime: &metav1.Time{Time: SuccessfulJob2StartTime}, + Conditions: []v1batch.JobCondition{ {Type: v1batch.JobComplete, Status: v1.ConditionTrue}, - }, - + }, }, Spec: v1batch.JobSpec{ - ActiveDeadlineSeconds: nil, - Parallelism: &Parallelism1, - Completions: &Completions1, + ActiveDeadlineSeconds: nil, + Parallelism: &Parallelism1, + Completions: &Completions1, }, }, }, diff --git a/collectors/limitrange_test.go b/collectors/limitrange_test.go index d185206beb..c996d0a5ba 100644 --- a/collectors/limitrange_test.go +++ b/collectors/limitrange_test.go @@ -19,7 +19,8 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/resource" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -48,7 +49,7 @@ func TestLimitRangeollector(t *testing.T) { { ranges: []v1.LimitRange{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "quotaTest", Namespace: "testNS", }, diff --git a/collectors/node_test.go b/collectors/node_test.go index af3fd74968..645a77dc0e 100644 --- a/collectors/node_test.go +++ b/collectors/node_test.go @@ -19,7 +19,8 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/resource" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -73,7 +74,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", }, Status: v1.NodeStatus{ @@ -100,7 +101,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", Labels: map[string]string{ "type": "master", @@ -147,7 +148,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", }, Status: v1.NodeStatus{ @@ -157,7 +158,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.2", }, Status: v1.NodeStatus{ @@ -167,7 +168,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.3", }, Status: v1.NodeStatus{ @@ -194,7 +195,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", }, Status: v1.NodeStatus{ @@ -202,7 +203,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.2", }, Status: v1.NodeStatus{ @@ -210,7 +211,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.3", }, Status: v1.NodeStatus{ @@ -235,7 +236,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", }, Status: v1.NodeStatus{ @@ -245,7 +246,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.2", }, Status: v1.NodeStatus{ @@ -255,7 +256,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.3", }, Status: v1.NodeStatus{ @@ -282,7 +283,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", }, Status: v1.NodeStatus{ @@ -292,7 +293,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.2", }, Status: v1.NodeStatus{ @@ -302,7 +303,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.3", }, Status: v1.NodeStatus{ @@ -329,7 +330,7 @@ func TestNodeCollector(t *testing.T) { { nodes: []v1.Node{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.1", }, Status: v1.NodeStatus{ @@ -339,7 +340,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.2", }, Status: v1.NodeStatus{ @@ -349,7 +350,7 @@ func TestNodeCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "127.0.0.3", }, Status: v1.NodeStatus{ diff --git a/collectors/persistentvolumeclaim_test.go b/collectors/persistentvolumeclaim_test.go index 0987031227..f33915ace9 100644 --- a/collectors/persistentvolumeclaim_test.go +++ b/collectors/persistentvolumeclaim_test.go @@ -19,6 +19,7 @@ package collectors import ( "testing" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -46,7 +47,7 @@ func TestPersistentVolumeClaimCollector(t *testing.T) { { pvcs: []v1.PersistentVolumeClaim{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "mysql-data", Namespace: "default", }, @@ -55,7 +56,7 @@ func TestPersistentVolumeClaimCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "prometheus-data", Namespace: "default", }, @@ -64,7 +65,7 @@ func TestPersistentVolumeClaimCollector(t *testing.T) { }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "mongo-data", }, Status: v1.PersistentVolumeClaimStatus{ diff --git a/collectors/pod_test.go b/collectors/pod_test.go index 014b342281..5ea50cf6f2 100644 --- a/collectors/pod_test.go +++ b/collectors/pod_test.go @@ -19,7 +19,8 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/resource" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -77,7 +78,7 @@ func TestPodCollector(t *testing.T) { { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -92,7 +93,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -123,7 +124,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -136,7 +137,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -163,7 +164,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -176,7 +177,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -203,7 +204,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -218,7 +219,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -259,7 +260,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -271,10 +272,10 @@ func TestPodCollector(t *testing.T) { PodIP: "1.2.3.4", }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", - OwnerReferences: []v1.OwnerReference{ + OwnerReferences: []metav1.OwnerReference{ { Kind: "ReplicaSet", Name: "rs-name", @@ -301,7 +302,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -309,7 +310,7 @@ func TestPodCollector(t *testing.T) { Phase: "Running", }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -326,7 +327,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -339,7 +340,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -365,7 +366,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -378,7 +379,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -404,7 +405,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", }, @@ -440,7 +441,7 @@ func TestPodCollector(t *testing.T) { }, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod2", Namespace: "ns2", }, @@ -508,7 +509,7 @@ func TestPodCollector(t *testing.T) { }, { pods: []v1.Pod{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "pod1", Namespace: "ns1", Labels: map[string]string{ diff --git a/collectors/replicaset_test.go b/collectors/replicaset_test.go index 87978040d1..6a78a8a0fb 100644 --- a/collectors/replicaset_test.go +++ b/collectors/replicaset_test.go @@ -19,7 +19,7 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/apis/extensions/v1beta1" ) @@ -60,7 +60,7 @@ func TestReplicaSetCollector(t *testing.T) { { rss: []v1beta1.ReplicaSet{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "rs1", Namespace: "ns1", Generation: 21, @@ -75,7 +75,7 @@ func TestReplicaSetCollector(t *testing.T) { Replicas: &rs1Replicas, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "rs2", Namespace: "ns2", Generation: 14, diff --git a/collectors/replicationcontroller_test.go b/collectors/replicationcontroller_test.go index eaff5477d1..5592fe0345 100644 --- a/collectors/replicationcontroller_test.go +++ b/collectors/replicationcontroller_test.go @@ -19,6 +19,7 @@ package collectors import ( "testing" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -61,7 +62,7 @@ func TestReplicationControllerCollector(t *testing.T) { { rss: []v1.ReplicationController{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "rc1", Namespace: "ns1", Generation: 21, @@ -77,7 +78,7 @@ func TestReplicationControllerCollector(t *testing.T) { Replicas: &rc1Replicas, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "rc2", Namespace: "ns2", Generation: 14, diff --git a/collectors/resourcequota_test.go b/collectors/resourcequota_test.go index c5eec82100..28be746610 100644 --- a/collectors/resourcequota_test.go +++ b/collectors/resourcequota_test.go @@ -19,7 +19,8 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/resource" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -47,7 +48,7 @@ func TestResourceQuotaCollector(t *testing.T) { { quotas: []v1.ResourceQuota{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "quotaTest", Namespace: "testNS", }, @@ -60,7 +61,7 @@ func TestResourceQuotaCollector(t *testing.T) { { quotas: []v1.ResourceQuota{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "quotaTest", Namespace: "testNS", }, diff --git a/collectors/service_test.go b/collectors/service_test.go index b5cb28531f..53426bf3a6 100644 --- a/collectors/service_test.go +++ b/collectors/service_test.go @@ -19,6 +19,7 @@ package collectors import ( "testing" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -47,7 +48,7 @@ func TestServiceCollector(t *testing.T) { { services: []v1.Service{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "test-service", Namespace: "default", Labels: map[string]string{ diff --git a/collectors/statefulset_test.go b/collectors/statefulset_test.go index 66bdc0510e..4ef29b9d63 100644 --- a/collectors/statefulset_test.go +++ b/collectors/statefulset_test.go @@ -3,7 +3,7 @@ package collectors import ( "testing" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/apis/apps/v1beta1" ) @@ -46,7 +46,7 @@ func TestStatefuleSetCollector(t *testing.T) { { depls: []v1beta1.StatefulSet{ { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "statefulset1", Namespace: "ns1", Labels: map[string]string{ @@ -63,7 +63,7 @@ func TestStatefuleSetCollector(t *testing.T) { Replicas: 2, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "statefulset2", Namespace: "ns2", Labels: map[string]string{ @@ -80,7 +80,7 @@ func TestStatefuleSetCollector(t *testing.T) { Replicas: 5, }, }, { - ObjectMeta: v1.ObjectMeta{ + ObjectMeta: metav1.ObjectMeta{ Name: "statefulset3", Namespace: "ns3", Labels: map[string]string{ diff --git a/vendor/github.com/blang/semver/LICENSE b/vendor/github.com/blang/semver/LICENSE deleted file mode 100644 index 5ba5c86fcb..0000000000 --- a/vendor/github.com/blang/semver/LICENSE +++ /dev/null @@ -1,22 +0,0 @@ -The MIT License - -Copyright (c) 2014 Benedikt Lang - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. - diff --git a/vendor/github.com/blang/semver/README.md b/vendor/github.com/blang/semver/README.md deleted file mode 100644 index 5171c5c557..0000000000 --- a/vendor/github.com/blang/semver/README.md +++ /dev/null @@ -1,142 +0,0 @@ -semver for golang [![Build Status](https://drone.io/github.com/blang/semver/status.png)](https://drone.io/github.com/blang/semver/latest) [![GoDoc](https://godoc.org/github.com/blang/semver?status.png)](https://godoc.org/github.com/blang/semver) [![Coverage Status](https://img.shields.io/coveralls/blang/semver.svg)](https://coveralls.io/r/blang/semver?branch=master) -====== - -semver is a [Semantic Versioning](http://semver.org/) library written in golang. It fully covers spec version `2.0.0`. - -Usage ------ -```bash -$ go get github.com/blang/semver -``` -Note: Always vendor your dependencies or fix on a specific version tag. - -```go -import github.com/blang/semver -v1, err := semver.Make("1.0.0-beta") -v2, err := semver.Make("2.0.0-beta") -v1.Compare(v2) -``` - -Also check the [GoDocs](http://godoc.org/github.com/blang/semver). - -Why should I use this lib? ------ - -- Fully spec compatible -- No reflection -- No regex -- Fully tested (Coverage >99%) -- Readable parsing/validation errors -- Fast (See [Benchmarks](#benchmarks)) -- Only Stdlib -- Uses values instead of pointers -- Many features, see below - - -Features ------ - -- Parsing and validation at all levels -- Comparator-like comparisons -- Compare Helper Methods -- InPlace manipulation -- Sortable (implements sort.Interface) -- database/sql compatible (sql.Scanner/Valuer) -- encoding/json compatible (json.Marshaler/Unmarshaler) - - -Example ------ - -Have a look at full examples in [examples/main.go](examples/main.go) - -```go -import github.com/blang/semver - -v, err := semver.Make("0.0.1-alpha.preview+123.github") -fmt.Printf("Major: %d\n", v.Major) -fmt.Printf("Minor: %d\n", v.Minor) -fmt.Printf("Patch: %d\n", v.Patch) -fmt.Printf("Pre: %s\n", v.Pre) -fmt.Printf("Build: %s\n", v.Build) - -// Prerelease versions array -if len(v.Pre) > 0 { - fmt.Println("Prerelease versions:") - for i, pre := range v.Pre { - fmt.Printf("%d: %q\n", i, pre) - } -} - -// Build meta data array -if len(v.Build) > 0 { - fmt.Println("Build meta data:") - for i, build := range v.Build { - fmt.Printf("%d: %q\n", i, build) - } -} - -v001, err := semver.Make("0.0.1") -// Compare using helpers: v.GT(v2), v.LT, v.GTE, v.LTE -v001.GT(v) == true -v.LT(v001) == true -v.GTE(v) == true -v.LTE(v) == true - -// Or use v.Compare(v2) for comparisons (-1, 0, 1): -v001.Compare(v) == 1 -v.Compare(v001) == -1 -v.Compare(v) == 0 - -// Manipulate Version in place: -v.Pre[0], err = semver.NewPRVersion("beta") -if err != nil { - fmt.Printf("Error parsing pre release version: %q", err) -} - -fmt.Println("\nValidate versions:") -v.Build[0] = "?" - -err = v.Validate() -if err != nil { - fmt.Printf("Validation failed: %s\n", err) -} -``` - -Benchmarks ------ - - BenchmarkParseSimple 5000000 328 ns/op 49 B/op 1 allocs/op - BenchmarkParseComplex 1000000 2105 ns/op 263 B/op 7 allocs/op - BenchmarkParseAverage 1000000 1301 ns/op 168 B/op 4 allocs/op - BenchmarkStringSimple 10000000 130 ns/op 5 B/op 1 allocs/op - BenchmarkStringLarger 5000000 280 ns/op 32 B/op 2 allocs/op - BenchmarkStringComplex 3000000 512 ns/op 80 B/op 3 allocs/op - BenchmarkStringAverage 5000000 387 ns/op 47 B/op 2 allocs/op - BenchmarkValidateSimple 500000000 7.92 ns/op 0 B/op 0 allocs/op - BenchmarkValidateComplex 2000000 923 ns/op 0 B/op 0 allocs/op - BenchmarkValidateAverage 5000000 452 ns/op 0 B/op 0 allocs/op - BenchmarkCompareSimple 100000000 11.2 ns/op 0 B/op 0 allocs/op - BenchmarkCompareComplex 50000000 40.9 ns/op 0 B/op 0 allocs/op - BenchmarkCompareAverage 50000000 43.8 ns/op 0 B/op 0 allocs/op - BenchmarkSort 5000000 436 ns/op 259 B/op 2 allocs/op - -See benchmark cases at [semver_test.go](semver_test.go) - - -Motivation ------ - -I simply couldn't find any lib supporting the full spec. Others were just wrong or used reflection and regex which i don't like. - - -Contribution ------ - -Feel free to make a pull request. For bigger changes create a issue first to discuss about it. - - -License ------ - -See [LICENSE](LICENSE) file. diff --git a/vendor/github.com/blang/semver/json.go b/vendor/github.com/blang/semver/json.go deleted file mode 100644 index a74bf7c449..0000000000 --- a/vendor/github.com/blang/semver/json.go +++ /dev/null @@ -1,23 +0,0 @@ -package semver - -import ( - "encoding/json" -) - -// MarshalJSON implements the encoding/json.Marshaler interface. -func (v Version) MarshalJSON() ([]byte, error) { - return json.Marshal(v.String()) -} - -// UnmarshalJSON implements the encoding/json.Unmarshaler interface. -func (v *Version) UnmarshalJSON(data []byte) (err error) { - var versionString string - - if err = json.Unmarshal(data, &versionString); err != nil { - return - } - - *v, err = Parse(versionString) - - return -} diff --git a/vendor/github.com/blang/semver/semver.go b/vendor/github.com/blang/semver/semver.go deleted file mode 100644 index bbf85ce972..0000000000 --- a/vendor/github.com/blang/semver/semver.go +++ /dev/null @@ -1,395 +0,0 @@ -package semver - -import ( - "errors" - "fmt" - "strconv" - "strings" -) - -const ( - numbers string = "0123456789" - alphas = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ-" - alphanum = alphas + numbers -) - -// SpecVersion is the latest fully supported spec version of semver -var SpecVersion = Version{ - Major: 2, - Minor: 0, - Patch: 0, -} - -// Version represents a semver compatible version -type Version struct { - Major uint64 - Minor uint64 - Patch uint64 - Pre []PRVersion - Build []string //No Precendence -} - -// Version to string -func (v Version) String() string { - b := make([]byte, 0, 5) - b = strconv.AppendUint(b, v.Major, 10) - b = append(b, '.') - b = strconv.AppendUint(b, v.Minor, 10) - b = append(b, '.') - b = strconv.AppendUint(b, v.Patch, 10) - - if len(v.Pre) > 0 { - b = append(b, '-') - b = append(b, v.Pre[0].String()...) - - for _, pre := range v.Pre[1:] { - b = append(b, '.') - b = append(b, pre.String()...) - } - } - - if len(v.Build) > 0 { - b = append(b, '+') - b = append(b, v.Build[0]...) - - for _, build := range v.Build[1:] { - b = append(b, '.') - b = append(b, build...) - } - } - - return string(b) -} - -// Equals checks if v is equal to o. -func (v Version) Equals(o Version) bool { - return (v.Compare(o) == 0) -} - -// EQ checks if v is equal to o. -func (v Version) EQ(o Version) bool { - return (v.Compare(o) == 0) -} - -// NE checks if v is not equal to o. -func (v Version) NE(o Version) bool { - return (v.Compare(o) != 0) -} - -// GT checks if v is greater than o. -func (v Version) GT(o Version) bool { - return (v.Compare(o) == 1) -} - -// GTE checks if v is greater than or equal to o. -func (v Version) GTE(o Version) bool { - return (v.Compare(o) >= 0) -} - -// GE checks if v is greater than or equal to o. -func (v Version) GE(o Version) bool { - return (v.Compare(o) >= 0) -} - -// LT checks if v is less than o. -func (v Version) LT(o Version) bool { - return (v.Compare(o) == -1) -} - -// LTE checks if v is less than or equal to o. -func (v Version) LTE(o Version) bool { - return (v.Compare(o) <= 0) -} - -// LE checks if v is less than or equal to o. -func (v Version) LE(o Version) bool { - return (v.Compare(o) <= 0) -} - -// Compare compares Versions v to o: -// -1 == v is less than o -// 0 == v is equal to o -// 1 == v is greater than o -func (v Version) Compare(o Version) int { - if v.Major != o.Major { - if v.Major > o.Major { - return 1 - } - return -1 - } - if v.Minor != o.Minor { - if v.Minor > o.Minor { - return 1 - } - return -1 - } - if v.Patch != o.Patch { - if v.Patch > o.Patch { - return 1 - } - return -1 - } - - // Quick comparison if a version has no prerelease versions - if len(v.Pre) == 0 && len(o.Pre) == 0 { - return 0 - } else if len(v.Pre) == 0 && len(o.Pre) > 0 { - return 1 - } else if len(v.Pre) > 0 && len(o.Pre) == 0 { - return -1 - } - - i := 0 - for ; i < len(v.Pre) && i < len(o.Pre); i++ { - if comp := v.Pre[i].Compare(o.Pre[i]); comp == 0 { - continue - } else if comp == 1 { - return 1 - } else { - return -1 - } - } - - // If all pr versions are the equal but one has further prversion, this one greater - if i == len(v.Pre) && i == len(o.Pre) { - return 0 - } else if i == len(v.Pre) && i < len(o.Pre) { - return -1 - } else { - return 1 - } - -} - -// Validate validates v and returns error in case -func (v Version) Validate() error { - // Major, Minor, Patch already validated using uint64 - - for _, pre := range v.Pre { - if !pre.IsNum { //Numeric prerelease versions already uint64 - if len(pre.VersionStr) == 0 { - return fmt.Errorf("Prerelease can not be empty %q", pre.VersionStr) - } - if !containsOnly(pre.VersionStr, alphanum) { - return fmt.Errorf("Invalid character(s) found in prerelease %q", pre.VersionStr) - } - } - } - - for _, build := range v.Build { - if len(build) == 0 { - return fmt.Errorf("Build meta data can not be empty %q", build) - } - if !containsOnly(build, alphanum) { - return fmt.Errorf("Invalid character(s) found in build meta data %q", build) - } - } - - return nil -} - -// New is an alias for Parse and returns a pointer, parses version string and returns a validated Version or error -func New(s string) (vp *Version, err error) { - v, err := Parse(s) - vp = &v - return -} - -// Make is an alias for Parse, parses version string and returns a validated Version or error -func Make(s string) (Version, error) { - return Parse(s) -} - -// Parse parses version string and returns a validated Version or error -func Parse(s string) (Version, error) { - if len(s) == 0 { - return Version{}, errors.New("Version string empty") - } - - // Split into major.minor.(patch+pr+meta) - parts := strings.SplitN(s, ".", 3) - if len(parts) != 3 { - return Version{}, errors.New("No Major.Minor.Patch elements found") - } - - // Major - if !containsOnly(parts[0], numbers) { - return Version{}, fmt.Errorf("Invalid character(s) found in major number %q", parts[0]) - } - if hasLeadingZeroes(parts[0]) { - return Version{}, fmt.Errorf("Major number must not contain leading zeroes %q", parts[0]) - } - major, err := strconv.ParseUint(parts[0], 10, 64) - if err != nil { - return Version{}, err - } - - // Minor - if !containsOnly(parts[1], numbers) { - return Version{}, fmt.Errorf("Invalid character(s) found in minor number %q", parts[1]) - } - if hasLeadingZeroes(parts[1]) { - return Version{}, fmt.Errorf("Minor number must not contain leading zeroes %q", parts[1]) - } - minor, err := strconv.ParseUint(parts[1], 10, 64) - if err != nil { - return Version{}, err - } - - v := Version{} - v.Major = major - v.Minor = minor - - var build, prerelease []string - patchStr := parts[2] - - if buildIndex := strings.IndexRune(patchStr, '+'); buildIndex != -1 { - build = strings.Split(patchStr[buildIndex+1:], ".") - patchStr = patchStr[:buildIndex] - } - - if preIndex := strings.IndexRune(patchStr, '-'); preIndex != -1 { - prerelease = strings.Split(patchStr[preIndex+1:], ".") - patchStr = patchStr[:preIndex] - } - - if !containsOnly(patchStr, numbers) { - return Version{}, fmt.Errorf("Invalid character(s) found in patch number %q", patchStr) - } - if hasLeadingZeroes(patchStr) { - return Version{}, fmt.Errorf("Patch number must not contain leading zeroes %q", patchStr) - } - patch, err := strconv.ParseUint(patchStr, 10, 64) - if err != nil { - return Version{}, err - } - - v.Patch = patch - - // Prerelease - for _, prstr := range prerelease { - parsedPR, err := NewPRVersion(prstr) - if err != nil { - return Version{}, err - } - v.Pre = append(v.Pre, parsedPR) - } - - // Build meta data - for _, str := range build { - if len(str) == 0 { - return Version{}, errors.New("Build meta data is empty") - } - if !containsOnly(str, alphanum) { - return Version{}, fmt.Errorf("Invalid character(s) found in build meta data %q", str) - } - v.Build = append(v.Build, str) - } - - return v, nil -} - -// MustParse is like Parse but panics if the version cannot be parsed. -func MustParse(s string) Version { - v, err := Parse(s) - if err != nil { - panic(`semver: Parse(` + s + `): ` + err.Error()) - } - return v -} - -// PRVersion represents a PreRelease Version -type PRVersion struct { - VersionStr string - VersionNum uint64 - IsNum bool -} - -// NewPRVersion creates a new valid prerelease version -func NewPRVersion(s string) (PRVersion, error) { - if len(s) == 0 { - return PRVersion{}, errors.New("Prerelease is empty") - } - v := PRVersion{} - if containsOnly(s, numbers) { - if hasLeadingZeroes(s) { - return PRVersion{}, fmt.Errorf("Numeric PreRelease version must not contain leading zeroes %q", s) - } - num, err := strconv.ParseUint(s, 10, 64) - - // Might never be hit, but just in case - if err != nil { - return PRVersion{}, err - } - v.VersionNum = num - v.IsNum = true - } else if containsOnly(s, alphanum) { - v.VersionStr = s - v.IsNum = false - } else { - return PRVersion{}, fmt.Errorf("Invalid character(s) found in prerelease %q", s) - } - return v, nil -} - -// IsNumeric checks if prerelease-version is numeric -func (v PRVersion) IsNumeric() bool { - return v.IsNum -} - -// Compare compares two PreRelease Versions v and o: -// -1 == v is less than o -// 0 == v is equal to o -// 1 == v is greater than o -func (v PRVersion) Compare(o PRVersion) int { - if v.IsNum && !o.IsNum { - return -1 - } else if !v.IsNum && o.IsNum { - return 1 - } else if v.IsNum && o.IsNum { - if v.VersionNum == o.VersionNum { - return 0 - } else if v.VersionNum > o.VersionNum { - return 1 - } else { - return -1 - } - } else { // both are Alphas - if v.VersionStr == o.VersionStr { - return 0 - } else if v.VersionStr > o.VersionStr { - return 1 - } else { - return -1 - } - } -} - -// PreRelease version to string -func (v PRVersion) String() string { - if v.IsNum { - return strconv.FormatUint(v.VersionNum, 10) - } - return v.VersionStr -} - -func containsOnly(s string, set string) bool { - return strings.IndexFunc(s, func(r rune) bool { - return !strings.ContainsRune(set, r) - }) == -1 -} - -func hasLeadingZeroes(s string) bool { - return len(s) > 1 && s[0] == '0' -} - -// NewBuildVersion creates a new valid build version -func NewBuildVersion(s string) (string, error) { - if len(s) == 0 { - return "", errors.New("Buildversion is empty") - } - if !containsOnly(s, alphanum) { - return "", fmt.Errorf("Invalid character(s) found in build meta data %q", s) - } - return s, nil -} diff --git a/vendor/github.com/blang/semver/sort.go b/vendor/github.com/blang/semver/sort.go deleted file mode 100644 index e18f880826..0000000000 --- a/vendor/github.com/blang/semver/sort.go +++ /dev/null @@ -1,28 +0,0 @@ -package semver - -import ( - "sort" -) - -// Versions represents multiple versions. -type Versions []Version - -// Len returns length of version collection -func (s Versions) Len() int { - return len(s) -} - -// Swap swaps two versions inside the collection by its indices -func (s Versions) Swap(i, j int) { - s[i], s[j] = s[j], s[i] -} - -// Less checks if version at index i is less than version at index j -func (s Versions) Less(i, j int) bool { - return s[i].LT(s[j]) -} - -// Sort sorts a slice of versions -func Sort(versions []Version) { - sort.Sort(Versions(versions)) -} diff --git a/vendor/github.com/blang/semver/sql.go b/vendor/github.com/blang/semver/sql.go deleted file mode 100644 index eb4d802666..0000000000 --- a/vendor/github.com/blang/semver/sql.go +++ /dev/null @@ -1,30 +0,0 @@ -package semver - -import ( - "database/sql/driver" - "fmt" -) - -// Scan implements the database/sql.Scanner interface. -func (v *Version) Scan(src interface{}) (err error) { - var str string - switch src := src.(type) { - case string: - str = src - case []byte: - str = string(src) - default: - return fmt.Errorf("Version.Scan: cannot convert %T to string.", src) - } - - if t, err := Parse(str); err == nil { - *v = t - } - - return -} - -// Value implements the database/sql/driver.Valuer interface. -func (v Version) Value() (driver.Value, error) { - return v.String(), nil -} diff --git a/vendor/github.com/coreos/go-oidc/NOTICE b/vendor/github.com/coreos/go-oidc/NOTICE deleted file mode 100644 index b39ddfa5cb..0000000000 --- a/vendor/github.com/coreos/go-oidc/NOTICE +++ /dev/null @@ -1,5 +0,0 @@ -CoreOS Project -Copyright 2014 CoreOS, Inc - -This product includes software developed at CoreOS, Inc. -(http://www.coreos.com/). diff --git a/vendor/github.com/coreos/go-oidc/http/client.go b/vendor/github.com/coreos/go-oidc/http/client.go deleted file mode 100644 index fd079b4950..0000000000 --- a/vendor/github.com/coreos/go-oidc/http/client.go +++ /dev/null @@ -1,7 +0,0 @@ -package http - -import "net/http" - -type Client interface { - Do(*http.Request) (*http.Response, error) -} diff --git a/vendor/github.com/coreos/go-oidc/http/http.go b/vendor/github.com/coreos/go-oidc/http/http.go deleted file mode 100644 index c3f5121513..0000000000 --- a/vendor/github.com/coreos/go-oidc/http/http.go +++ /dev/null @@ -1,156 +0,0 @@ -package http - -import ( - "encoding/base64" - "encoding/json" - "errors" - "log" - "net/http" - "net/url" - "path" - "strconv" - "strings" - "time" -) - -func WriteError(w http.ResponseWriter, code int, msg string) { - e := struct { - Error string `json:"error"` - }{ - Error: msg, - } - b, err := json.Marshal(e) - if err != nil { - log.Printf("go-oidc: failed to marshal %#v: %v", e, err) - code = http.StatusInternalServerError - b = []byte(`{"error":"server_error"}`) - } - w.Header().Set("Content-Type", "application/json") - w.WriteHeader(code) - w.Write(b) -} - -// BasicAuth parses a username and password from the request's -// Authorization header. This was pulled from golang master: -// https://codereview.appspot.com/76540043 -func BasicAuth(r *http.Request) (username, password string, ok bool) { - auth := r.Header.Get("Authorization") - if auth == "" { - return - } - - if !strings.HasPrefix(auth, "Basic ") { - return - } - c, err := base64.StdEncoding.DecodeString(strings.TrimPrefix(auth, "Basic ")) - if err != nil { - return - } - cs := string(c) - s := strings.IndexByte(cs, ':') - if s < 0 { - return - } - return cs[:s], cs[s+1:], true -} - -func cacheControlMaxAge(hdr string) (time.Duration, bool, error) { - for _, field := range strings.Split(hdr, ",") { - parts := strings.SplitN(strings.TrimSpace(field), "=", 2) - k := strings.ToLower(strings.TrimSpace(parts[0])) - if k != "max-age" { - continue - } - - if len(parts) == 1 { - return 0, false, errors.New("max-age has no value") - } - - v := strings.TrimSpace(parts[1]) - if v == "" { - return 0, false, errors.New("max-age has empty value") - } - - age, err := strconv.Atoi(v) - if err != nil { - return 0, false, err - } - - if age <= 0 { - return 0, false, nil - } - - return time.Duration(age) * time.Second, true, nil - } - - return 0, false, nil -} - -func expires(date, expires string) (time.Duration, bool, error) { - if date == "" || expires == "" { - return 0, false, nil - } - - te, err := time.Parse(time.RFC1123, expires) - if err != nil { - return 0, false, err - } - - td, err := time.Parse(time.RFC1123, date) - if err != nil { - return 0, false, err - } - - ttl := te.Sub(td) - - // headers indicate data already expired, caller should not - // have to care about this case - if ttl <= 0 { - return 0, false, nil - } - - return ttl, true, nil -} - -func Cacheable(hdr http.Header) (time.Duration, bool, error) { - ttl, ok, err := cacheControlMaxAge(hdr.Get("Cache-Control")) - if err != nil || ok { - return ttl, ok, err - } - - return expires(hdr.Get("Date"), hdr.Get("Expires")) -} - -// MergeQuery appends additional query values to an existing URL. -func MergeQuery(u url.URL, q url.Values) url.URL { - uv := u.Query() - for k, vs := range q { - for _, v := range vs { - uv.Add(k, v) - } - } - u.RawQuery = uv.Encode() - return u -} - -// NewResourceLocation appends a resource id to the end of the requested URL path. -func NewResourceLocation(reqURL *url.URL, id string) string { - var u url.URL - u = *reqURL - u.Path = path.Join(u.Path, id) - u.RawQuery = "" - u.Fragment = "" - return u.String() -} - -// CopyRequest returns a clone of the provided *http.Request. -// The returned object is a shallow copy of the struct and a -// deep copy of its Header field. -func CopyRequest(r *http.Request) *http.Request { - r2 := *r - r2.Header = make(http.Header) - for k, s := range r.Header { - r2.Header[k] = s - } - return &r2 -} diff --git a/vendor/github.com/coreos/go-oidc/http/url.go b/vendor/github.com/coreos/go-oidc/http/url.go deleted file mode 100644 index df60eb1a6b..0000000000 --- a/vendor/github.com/coreos/go-oidc/http/url.go +++ /dev/null @@ -1,29 +0,0 @@ -package http - -import ( - "errors" - "net/url" -) - -// ParseNonEmptyURL checks that a string is a parsable URL which is also not empty -// since `url.Parse("")` does not return an error. Must contian a scheme and a host. -func ParseNonEmptyURL(u string) (*url.URL, error) { - if u == "" { - return nil, errors.New("url is empty") - } - - ur, err := url.Parse(u) - if err != nil { - return nil, err - } - - if ur.Scheme == "" { - return nil, errors.New("url scheme is empty") - } - - if ur.Host == "" { - return nil, errors.New("url host is empty") - } - - return ur, nil -} diff --git a/vendor/github.com/coreos/go-oidc/jose/claims.go b/vendor/github.com/coreos/go-oidc/jose/claims.go deleted file mode 100644 index 8b48bfd230..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/claims.go +++ /dev/null @@ -1,126 +0,0 @@ -package jose - -import ( - "encoding/json" - "fmt" - "math" - "time" -) - -type Claims map[string]interface{} - -func (c Claims) Add(name string, value interface{}) { - c[name] = value -} - -func (c Claims) StringClaim(name string) (string, bool, error) { - cl, ok := c[name] - if !ok { - return "", false, nil - } - - v, ok := cl.(string) - if !ok { - return "", false, fmt.Errorf("unable to parse claim as string: %v", name) - } - - return v, true, nil -} - -func (c Claims) StringsClaim(name string) ([]string, bool, error) { - cl, ok := c[name] - if !ok { - return nil, false, nil - } - - if v, ok := cl.([]string); ok { - return v, true, nil - } - - // When unmarshaled, []string will become []interface{}. - if v, ok := cl.([]interface{}); ok { - var ret []string - for _, vv := range v { - str, ok := vv.(string) - if !ok { - return nil, false, fmt.Errorf("unable to parse claim as string array: %v", name) - } - ret = append(ret, str) - } - return ret, true, nil - } - - return nil, false, fmt.Errorf("unable to parse claim as string array: %v", name) -} - -func (c Claims) Int64Claim(name string) (int64, bool, error) { - cl, ok := c[name] - if !ok { - return 0, false, nil - } - - v, ok := cl.(int64) - if !ok { - vf, ok := cl.(float64) - if !ok { - return 0, false, fmt.Errorf("unable to parse claim as int64: %v", name) - } - v = int64(vf) - } - - return v, true, nil -} - -func (c Claims) Float64Claim(name string) (float64, bool, error) { - cl, ok := c[name] - if !ok { - return 0, false, nil - } - - v, ok := cl.(float64) - if !ok { - vi, ok := cl.(int64) - if !ok { - return 0, false, fmt.Errorf("unable to parse claim as float64: %v", name) - } - v = float64(vi) - } - - return v, true, nil -} - -func (c Claims) TimeClaim(name string) (time.Time, bool, error) { - v, ok, err := c.Float64Claim(name) - if !ok || err != nil { - return time.Time{}, ok, err - } - - s := math.Trunc(v) - ns := (v - s) * math.Pow(10, 9) - return time.Unix(int64(s), int64(ns)).UTC(), true, nil -} - -func decodeClaims(payload []byte) (Claims, error) { - var c Claims - if err := json.Unmarshal(payload, &c); err != nil { - return nil, fmt.Errorf("malformed JWT claims, unable to decode: %v", err) - } - return c, nil -} - -func marshalClaims(c Claims) ([]byte, error) { - b, err := json.Marshal(c) - if err != nil { - return nil, err - } - return b, nil -} - -func encodeClaims(c Claims) (string, error) { - b, err := marshalClaims(c) - if err != nil { - return "", err - } - - return encodeSegment(b), nil -} diff --git a/vendor/github.com/coreos/go-oidc/jose/jose.go b/vendor/github.com/coreos/go-oidc/jose/jose.go deleted file mode 100644 index 6209926596..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/jose.go +++ /dev/null @@ -1,112 +0,0 @@ -package jose - -import ( - "encoding/base64" - "encoding/json" - "fmt" - "strings" -) - -const ( - HeaderMediaType = "typ" - HeaderKeyAlgorithm = "alg" - HeaderKeyID = "kid" -) - -const ( - // Encryption Algorithm Header Parameter Values for JWS - // See: https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40#page-6 - AlgHS256 = "HS256" - AlgHS384 = "HS384" - AlgHS512 = "HS512" - AlgRS256 = "RS256" - AlgRS384 = "RS384" - AlgRS512 = "RS512" - AlgES256 = "ES256" - AlgES384 = "ES384" - AlgES512 = "ES512" - AlgPS256 = "PS256" - AlgPS384 = "PS384" - AlgPS512 = "PS512" - AlgNone = "none" -) - -const ( - // Algorithm Header Parameter Values for JWE - // See: https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40#section-4.1 - AlgRSA15 = "RSA1_5" - AlgRSAOAEP = "RSA-OAEP" - AlgRSAOAEP256 = "RSA-OAEP-256" - AlgA128KW = "A128KW" - AlgA192KW = "A192KW" - AlgA256KW = "A256KW" - AlgDir = "dir" - AlgECDHES = "ECDH-ES" - AlgECDHESA128KW = "ECDH-ES+A128KW" - AlgECDHESA192KW = "ECDH-ES+A192KW" - AlgECDHESA256KW = "ECDH-ES+A256KW" - AlgA128GCMKW = "A128GCMKW" - AlgA192GCMKW = "A192GCMKW" - AlgA256GCMKW = "A256GCMKW" - AlgPBES2HS256A128KW = "PBES2-HS256+A128KW" - AlgPBES2HS384A192KW = "PBES2-HS384+A192KW" - AlgPBES2HS512A256KW = "PBES2-HS512+A256KW" -) - -const ( - // Encryption Algorithm Header Parameter Values for JWE - // See: https://tools.ietf.org/html/draft-ietf-jose-json-web-algorithms-40#page-22 - EncA128CBCHS256 = "A128CBC-HS256" - EncA128CBCHS384 = "A128CBC-HS384" - EncA256CBCHS512 = "A256CBC-HS512" - EncA128GCM = "A128GCM" - EncA192GCM = "A192GCM" - EncA256GCM = "A256GCM" -) - -type JOSEHeader map[string]string - -func (j JOSEHeader) Validate() error { - if _, exists := j[HeaderKeyAlgorithm]; !exists { - return fmt.Errorf("header missing %q parameter", HeaderKeyAlgorithm) - } - - return nil -} - -func decodeHeader(seg string) (JOSEHeader, error) { - b, err := decodeSegment(seg) - if err != nil { - return nil, err - } - - var h JOSEHeader - err = json.Unmarshal(b, &h) - if err != nil { - return nil, err - } - - return h, nil -} - -func encodeHeader(h JOSEHeader) (string, error) { - b, err := json.Marshal(h) - if err != nil { - return "", err - } - - return encodeSegment(b), nil -} - -// Decode JWT specific base64url encoding with padding stripped -func decodeSegment(seg string) ([]byte, error) { - if l := len(seg) % 4; l != 0 { - seg += strings.Repeat("=", 4-l) - } - return base64.URLEncoding.DecodeString(seg) -} - -// Encode JWT specific base64url encoding with padding stripped -func encodeSegment(seg []byte) string { - return strings.TrimRight(base64.URLEncoding.EncodeToString(seg), "=") -} diff --git a/vendor/github.com/coreos/go-oidc/jose/jwk.go b/vendor/github.com/coreos/go-oidc/jose/jwk.go deleted file mode 100644 index b7a8e23558..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/jwk.go +++ /dev/null @@ -1,135 +0,0 @@ -package jose - -import ( - "bytes" - "encoding/base64" - "encoding/binary" - "encoding/json" - "math/big" - "strings" -) - -// JSON Web Key -// https://tools.ietf.org/html/draft-ietf-jose-json-web-key-36#page-5 -type JWK struct { - ID string - Type string - Alg string - Use string - Exponent int - Modulus *big.Int - Secret []byte -} - -type jwkJSON struct { - ID string `json:"kid"` - Type string `json:"kty"` - Alg string `json:"alg"` - Use string `json:"use"` - Exponent string `json:"e"` - Modulus string `json:"n"` -} - -func (j *JWK) MarshalJSON() ([]byte, error) { - t := jwkJSON{ - ID: j.ID, - Type: j.Type, - Alg: j.Alg, - Use: j.Use, - Exponent: encodeExponent(j.Exponent), - Modulus: encodeModulus(j.Modulus), - } - - return json.Marshal(&t) -} - -func (j *JWK) UnmarshalJSON(data []byte) error { - var t jwkJSON - err := json.Unmarshal(data, &t) - if err != nil { - return err - } - - e, err := decodeExponent(t.Exponent) - if err != nil { - return err - } - - n, err := decodeModulus(t.Modulus) - if err != nil { - return err - } - - j.ID = t.ID - j.Type = t.Type - j.Alg = t.Alg - j.Use = t.Use - j.Exponent = e - j.Modulus = n - - return nil -} - -type JWKSet struct { - Keys []JWK `json:"keys"` -} - -func decodeExponent(e string) (int, error) { - decE, err := decodeBase64URLPaddingOptional(e) - if err != nil { - return 0, err - } - var eBytes []byte - if len(decE) < 8 { - eBytes = make([]byte, 8-len(decE), 8) - eBytes = append(eBytes, decE...) - } else { - eBytes = decE - } - eReader := bytes.NewReader(eBytes) - var E uint64 - err = binary.Read(eReader, binary.BigEndian, &E) - if err != nil { - return 0, err - } - return int(E), nil -} - -func encodeExponent(e int) string { - b := make([]byte, 8) - binary.BigEndian.PutUint64(b, uint64(e)) - var idx int - for ; idx < 8; idx++ { - if b[idx] != 0x0 { - break - } - } - return base64.URLEncoding.EncodeToString(b[idx:]) -} - -// Turns a URL encoded modulus of a key into a big int. -func decodeModulus(n string) (*big.Int, error) { - decN, err := decodeBase64URLPaddingOptional(n) - if err != nil { - return nil, err - } - N := big.NewInt(0) - N.SetBytes(decN) - return N, nil -} - -func encodeModulus(n *big.Int) string { - return base64.URLEncoding.EncodeToString(n.Bytes()) -} - -// decodeBase64URLPaddingOptional decodes Base64 whether there is padding or not. -// The stdlib version currently doesn't handle this. -// We can get rid of this is if this bug: -// https://github.com/golang/go/issues/4237 -// ever closes. -func decodeBase64URLPaddingOptional(e string) ([]byte, error) { - if m := len(e) % 4; m != 0 { - e += strings.Repeat("=", 4-m) - } - return base64.URLEncoding.DecodeString(e) -} diff --git a/vendor/github.com/coreos/go-oidc/jose/jws.go b/vendor/github.com/coreos/go-oidc/jose/jws.go deleted file mode 100644 index 1049ece831..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/jws.go +++ /dev/null @@ -1,51 +0,0 @@ -package jose - -import ( - "fmt" - "strings" -) - -type JWS struct { - RawHeader string - Header JOSEHeader - RawPayload string - Payload []byte - Signature []byte -} - -// Given a raw encoded JWS token parses it and verifies the structure. -func ParseJWS(raw string) (JWS, error) { - parts := strings.Split(raw, ".") - if len(parts) != 3 { - return JWS{}, fmt.Errorf("malformed JWS, only %d segments", len(parts)) - } - - rawSig := parts[2] - jws := JWS{ - RawHeader: parts[0], - RawPayload: parts[1], - } - - header, err := decodeHeader(jws.RawHeader) - if err != nil { - return JWS{}, fmt.Errorf("malformed JWS, unable to decode header, %s", err) - } - if err = header.Validate(); err != nil { - return JWS{}, fmt.Errorf("malformed JWS, %s", err) - } - jws.Header = header - - payload, err := decodeSegment(jws.RawPayload) - if err != nil { - return JWS{}, fmt.Errorf("malformed JWS, unable to decode payload: %s", err) - } - jws.Payload = payload - - sig, err := decodeSegment(rawSig) - if err != nil { - return JWS{}, fmt.Errorf("malformed JWS, unable to decode signature: %s", err) - } - jws.Signature = sig - - return jws, nil -} diff --git a/vendor/github.com/coreos/go-oidc/jose/jwt.go b/vendor/github.com/coreos/go-oidc/jose/jwt.go deleted file mode 100644 index 3b3e9634b0..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/jwt.go +++ /dev/null @@ -1,82 +0,0 @@ -package jose - -import "strings" - -type JWT JWS - -func ParseJWT(token string) (jwt JWT, err error) { - jws, err := ParseJWS(token) - if err != nil { - return - } - - return JWT(jws), nil -} - -func NewJWT(header JOSEHeader, claims Claims) (jwt JWT, err error) { - jwt = JWT{} - - jwt.Header = header - jwt.Header[HeaderMediaType] = "JWT" - - claimBytes, err := marshalClaims(claims) - if err != nil { - return - } - jwt.Payload = claimBytes - - eh, err := encodeHeader(header) - if err != nil { - return - } - jwt.RawHeader = eh - - ec, err := encodeClaims(claims) - if err != nil { - return - } - jwt.RawPayload = ec - - return -} - -func (j *JWT) KeyID() (string, bool) { - kID, ok := j.Header[HeaderKeyID] - return kID, ok -} - -func (j *JWT) Claims() (Claims, error) { - return decodeClaims(j.Payload) -} - -// Encoded data part of the token which may be signed. -func (j *JWT) Data() string { - return strings.Join([]string{j.RawHeader, j.RawPayload}, ".") -} - -// Full encoded JWT token string in format: header.claims.signature -func (j *JWT) Encode() string { - d := j.Data() - s := encodeSegment(j.Signature) - return strings.Join([]string{d, s}, ".") -} - -func NewSignedJWT(claims Claims, s Signer) (*JWT, error) { - header := JOSEHeader{ - HeaderKeyAlgorithm: s.Alg(), - HeaderKeyID: s.ID(), - } - - jwt, err := NewJWT(header, claims) - if err != nil { - return nil, err - } - - sig, err := s.Sign([]byte(jwt.Data())) - if err != nil { - return nil, err - } - jwt.Signature = sig - - return &jwt, nil -} diff --git a/vendor/github.com/coreos/go-oidc/jose/sig.go b/vendor/github.com/coreos/go-oidc/jose/sig.go deleted file mode 100755 index 7b2b253cca..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/sig.go +++ /dev/null @@ -1,24 +0,0 @@ -package jose - -import ( - "fmt" -) - -type Verifier interface { - ID() string - Alg() string - Verify(sig []byte, data []byte) error -} - -type Signer interface { - Verifier - Sign(data []byte) (sig []byte, err error) -} - -func NewVerifier(jwk JWK) (Verifier, error) { - if jwk.Type != "RSA" { - return nil, fmt.Errorf("unsupported key type %q", jwk.Type) - } - - return NewVerifierRSA(jwk) -} diff --git a/vendor/github.com/coreos/go-oidc/jose/sig_rsa.go b/vendor/github.com/coreos/go-oidc/jose/sig_rsa.go deleted file mode 100755 index 004e45dd83..0000000000 --- a/vendor/github.com/coreos/go-oidc/jose/sig_rsa.go +++ /dev/null @@ -1,67 +0,0 @@ -package jose - -import ( - "crypto" - "crypto/rand" - "crypto/rsa" - "fmt" -) - -type VerifierRSA struct { - KeyID string - Hash crypto.Hash - PublicKey rsa.PublicKey -} - -type SignerRSA struct { - PrivateKey rsa.PrivateKey - VerifierRSA -} - -func NewVerifierRSA(jwk JWK) (*VerifierRSA, error) { - if jwk.Alg != "" && jwk.Alg != "RS256" { - return nil, fmt.Errorf("unsupported key algorithm %q", jwk.Alg) - } - - v := VerifierRSA{ - KeyID: jwk.ID, - PublicKey: rsa.PublicKey{ - N: jwk.Modulus, - E: jwk.Exponent, - }, - Hash: crypto.SHA256, - } - - return &v, nil -} - -func NewSignerRSA(kid string, key rsa.PrivateKey) *SignerRSA { - return &SignerRSA{ - PrivateKey: key, - VerifierRSA: VerifierRSA{ - KeyID: kid, - PublicKey: key.PublicKey, - Hash: crypto.SHA256, - }, - } -} - -func (v *VerifierRSA) ID() string { - return v.KeyID -} - -func (v *VerifierRSA) Alg() string { - return "RS256" -} - -func (v *VerifierRSA) Verify(sig []byte, data []byte) error { - h := v.Hash.New() - h.Write(data) - return rsa.VerifyPKCS1v15(&v.PublicKey, v.Hash, h.Sum(nil), sig) -} - -func (s *SignerRSA) Sign(data []byte) ([]byte, error) { - h := s.Hash.New() - h.Write(data) - return rsa.SignPKCS1v15(rand.Reader, &s.PrivateKey, s.Hash, h.Sum(nil)) -} diff --git a/vendor/github.com/coreos/go-oidc/key/key.go b/vendor/github.com/coreos/go-oidc/key/key.go deleted file mode 100644 index 208c1fc149..0000000000 --- a/vendor/github.com/coreos/go-oidc/key/key.go +++ /dev/null @@ -1,153 +0,0 @@ -package key - -import ( - "crypto/rand" - "crypto/rsa" - "encoding/hex" - "encoding/json" - "io" - "time" - - "github.com/coreos/go-oidc/jose" -) - -func NewPublicKey(jwk jose.JWK) *PublicKey { - return &PublicKey{jwk: jwk} -} - -type PublicKey struct { - jwk jose.JWK -} - -func (k *PublicKey) MarshalJSON() ([]byte, error) { - return json.Marshal(&k.jwk) -} - -func (k *PublicKey) UnmarshalJSON(data []byte) error { - var jwk jose.JWK - if err := json.Unmarshal(data, &jwk); err != nil { - return err - } - k.jwk = jwk - return nil -} - -func (k *PublicKey) ID() string { - return k.jwk.ID -} - -func (k *PublicKey) Verifier() (jose.Verifier, error) { - return jose.NewVerifierRSA(k.jwk) -} - -type PrivateKey struct { - KeyID string - PrivateKey *rsa.PrivateKey -} - -func (k *PrivateKey) ID() string { - return k.KeyID -} - -func (k *PrivateKey) Signer() jose.Signer { - return jose.NewSignerRSA(k.ID(), *k.PrivateKey) -} - -func (k *PrivateKey) JWK() jose.JWK { - return jose.JWK{ - ID: k.KeyID, - Type: "RSA", - Alg: "RS256", - Use: "sig", - Exponent: k.PrivateKey.PublicKey.E, - Modulus: k.PrivateKey.PublicKey.N, - } -} - -type KeySet interface { - ExpiresAt() time.Time -} - -type PublicKeySet struct { - keys []PublicKey - index map[string]*PublicKey - expiresAt time.Time -} - -func NewPublicKeySet(jwks []jose.JWK, exp time.Time) *PublicKeySet { - keys := make([]PublicKey, len(jwks)) - index := make(map[string]*PublicKey) - for i, jwk := range jwks { - keys[i] = *NewPublicKey(jwk) - index[keys[i].ID()] = &keys[i] - } - return &PublicKeySet{ - keys: keys, - index: index, - expiresAt: exp, - } -} - -func (s *PublicKeySet) ExpiresAt() time.Time { - return s.expiresAt -} - -func (s *PublicKeySet) Keys() []PublicKey { - return s.keys -} - -func (s *PublicKeySet) Key(id string) *PublicKey { - return s.index[id] -} - -type PrivateKeySet struct { - keys []*PrivateKey - ActiveKeyID string - expiresAt time.Time -} - -func NewPrivateKeySet(keys []*PrivateKey, exp time.Time) *PrivateKeySet { - return &PrivateKeySet{ - keys: keys, - ActiveKeyID: keys[0].ID(), - expiresAt: exp.UTC(), - } -} - -func (s *PrivateKeySet) Keys() []*PrivateKey { - return s.keys -} - -func (s *PrivateKeySet) ExpiresAt() time.Time { - return s.expiresAt -} - -func (s *PrivateKeySet) Active() *PrivateKey { - for i, k := range s.keys { - if k.ID() == s.ActiveKeyID { - return s.keys[i] - } - } - - return nil -} - -type GeneratePrivateKeyFunc func() (*PrivateKey, error) - -func GeneratePrivateKey() (*PrivateKey, error) { - pk, err := rsa.GenerateKey(rand.Reader, 2048) - if err != nil { - return nil, err - } - keyID := make([]byte, 20) - if _, err := io.ReadFull(rand.Reader, keyID); err != nil { - return nil, err - } - - k := PrivateKey{ - KeyID: hex.EncodeToString(keyID), - PrivateKey: pk, - } - - return &k, nil -} diff --git a/vendor/github.com/coreos/go-oidc/key/manager.go b/vendor/github.com/coreos/go-oidc/key/manager.go deleted file mode 100644 index 476ab6a8d2..0000000000 --- a/vendor/github.com/coreos/go-oidc/key/manager.go +++ /dev/null @@ -1,99 +0,0 @@ -package key - -import ( - "errors" - "time" - - "github.com/jonboulle/clockwork" - - "github.com/coreos/go-oidc/jose" - "github.com/coreos/pkg/health" -) - -type PrivateKeyManager interface { - ExpiresAt() time.Time - Signer() (jose.Signer, error) - JWKs() ([]jose.JWK, error) - PublicKeys() ([]PublicKey, error) - - WritableKeySetRepo - health.Checkable -} - -func NewPrivateKeyManager() PrivateKeyManager { - return &privateKeyManager{ - clock: clockwork.NewRealClock(), - } -} - -type privateKeyManager struct { - keySet *PrivateKeySet - clock clockwork.Clock -} - -func (m *privateKeyManager) ExpiresAt() time.Time { - if m.keySet == nil { - return m.clock.Now().UTC() - } - - return m.keySet.ExpiresAt() -} - -func (m *privateKeyManager) Signer() (jose.Signer, error) { - if err := m.Healthy(); err != nil { - return nil, err - } - - return m.keySet.Active().Signer(), nil -} - -func (m *privateKeyManager) JWKs() ([]jose.JWK, error) { - if err := m.Healthy(); err != nil { - return nil, err - } - - keys := m.keySet.Keys() - jwks := make([]jose.JWK, len(keys)) - for i, k := range keys { - jwks[i] = k.JWK() - } - return jwks, nil -} - -func (m *privateKeyManager) PublicKeys() ([]PublicKey, error) { - jwks, err := m.JWKs() - if err != nil { - return nil, err - } - keys := make([]PublicKey, len(jwks)) - for i, jwk := range jwks { - keys[i] = *NewPublicKey(jwk) - } - return keys, nil -} - -func (m *privateKeyManager) Healthy() error { - if m.keySet == nil { - return errors.New("private key manager uninitialized") - } - - if len(m.keySet.Keys()) == 0 { - return errors.New("private key manager zero keys") - } - - if m.keySet.ExpiresAt().Before(m.clock.Now().UTC()) { - return errors.New("private key manager keys expired") - } - - return nil -} - -func (m *privateKeyManager) Set(keySet KeySet) error { - privKeySet, ok := keySet.(*PrivateKeySet) - if !ok { - return errors.New("unable to cast to PrivateKeySet") - } - - m.keySet = privKeySet - return nil -} diff --git a/vendor/github.com/coreos/go-oidc/key/repo.go b/vendor/github.com/coreos/go-oidc/key/repo.go deleted file mode 100644 index 1acdeb3614..0000000000 --- a/vendor/github.com/coreos/go-oidc/key/repo.go +++ /dev/null @@ -1,55 +0,0 @@ -package key - -import ( - "errors" - "sync" -) - -var ErrorNoKeys = errors.New("no keys found") - -type WritableKeySetRepo interface { - Set(KeySet) error -} - -type ReadableKeySetRepo interface { - Get() (KeySet, error) -} - -type PrivateKeySetRepo interface { - WritableKeySetRepo - ReadableKeySetRepo -} - -func NewPrivateKeySetRepo() PrivateKeySetRepo { - return &memPrivateKeySetRepo{} -} - -type memPrivateKeySetRepo struct { - mu sync.RWMutex - pks PrivateKeySet -} - -func (r *memPrivateKeySetRepo) Set(ks KeySet) error { - pks, ok := ks.(*PrivateKeySet) - if !ok { - return errors.New("unable to cast to PrivateKeySet") - } else if pks == nil { - return errors.New("nil KeySet") - } - - r.mu.Lock() - defer r.mu.Unlock() - - r.pks = *pks - return nil -} - -func (r *memPrivateKeySetRepo) Get() (KeySet, error) { - r.mu.RLock() - defer r.mu.RUnlock() - - if r.pks.keys == nil { - return nil, ErrorNoKeys - } - return KeySet(&r.pks), nil -} diff --git a/vendor/github.com/coreos/go-oidc/key/rotate.go b/vendor/github.com/coreos/go-oidc/key/rotate.go deleted file mode 100644 index bc6cdfb1bd..0000000000 --- a/vendor/github.com/coreos/go-oidc/key/rotate.go +++ /dev/null @@ -1,159 +0,0 @@ -package key - -import ( - "errors" - "log" - "time" - - ptime "github.com/coreos/pkg/timeutil" - "github.com/jonboulle/clockwork" -) - -var ( - ErrorPrivateKeysExpired = errors.New("private keys have expired") -) - -func NewPrivateKeyRotator(repo PrivateKeySetRepo, ttl time.Duration) *PrivateKeyRotator { - return &PrivateKeyRotator{ - repo: repo, - ttl: ttl, - - keep: 2, - generateKey: GeneratePrivateKey, - clock: clockwork.NewRealClock(), - } -} - -type PrivateKeyRotator struct { - repo PrivateKeySetRepo - generateKey GeneratePrivateKeyFunc - clock clockwork.Clock - keep int - ttl time.Duration -} - -func (r *PrivateKeyRotator) expiresAt() time.Time { - return r.clock.Now().UTC().Add(r.ttl) -} - -func (r *PrivateKeyRotator) Healthy() error { - pks, err := r.privateKeySet() - if err != nil { - return err - } - - if r.clock.Now().After(pks.ExpiresAt()) { - return ErrorPrivateKeysExpired - } - - return nil -} - -func (r *PrivateKeyRotator) privateKeySet() (*PrivateKeySet, error) { - ks, err := r.repo.Get() - if err != nil { - return nil, err - } - - pks, ok := ks.(*PrivateKeySet) - if !ok { - return nil, errors.New("unable to cast to PrivateKeySet") - } - return pks, nil -} - -func (r *PrivateKeyRotator) nextRotation() (time.Duration, error) { - pks, err := r.privateKeySet() - if err == ErrorNoKeys { - return 0, nil - } - if err != nil { - return 0, err - } - - now := r.clock.Now() - - // Ideally, we want to rotate after half the TTL has elapsed. - idealRotationTime := pks.ExpiresAt().Add(-r.ttl / 2) - - // If we are past the ideal rotation time, rotate immediatly. - return max(0, idealRotationTime.Sub(now)), nil -} - -func max(a, b time.Duration) time.Duration { - if a > b { - return a - } - return b -} - -func (r *PrivateKeyRotator) Run() chan struct{} { - attempt := func() { - k, err := r.generateKey() - if err != nil { - log.Printf("go-oidc: failed generating signing key: %v", err) - return - } - - exp := r.expiresAt() - if err := rotatePrivateKeys(r.repo, k, r.keep, exp); err != nil { - log.Printf("go-oidc: key rotation failed: %v", err) - return - } - } - - stop := make(chan struct{}) - go func() { - for { - var nextRotation time.Duration - var sleep time.Duration - var err error - for { - if nextRotation, err = r.nextRotation(); err == nil { - break - } - sleep = ptime.ExpBackoff(sleep, time.Minute) - log.Printf("go-oidc: error getting nextRotation, retrying in %v: %v", sleep, err) - time.Sleep(sleep) - } - - select { - case <-r.clock.After(nextRotation): - attempt() - case <-stop: - return - } - } - }() - - return stop -} - -func rotatePrivateKeys(repo PrivateKeySetRepo, k *PrivateKey, keep int, exp time.Time) error { - ks, err := repo.Get() - if err != nil && err != ErrorNoKeys { - return err - } - - var keys []*PrivateKey - if ks != nil { - pks, ok := ks.(*PrivateKeySet) - if !ok { - return errors.New("unable to cast to PrivateKeySet") - } - keys = pks.Keys() - } - - keys = append([]*PrivateKey{k}, keys...) - if l := len(keys); l > keep { - keys = keys[0:keep] - } - - nks := PrivateKeySet{ - keys: keys, - ActiveKeyID: k.ID(), - expiresAt: exp, - } - - return repo.Set(KeySet(&nks)) -} diff --git a/vendor/github.com/coreos/go-oidc/key/sync.go b/vendor/github.com/coreos/go-oidc/key/sync.go deleted file mode 100644 index b887f7b5a5..0000000000 --- a/vendor/github.com/coreos/go-oidc/key/sync.go +++ /dev/null @@ -1,91 +0,0 @@ -package key - -import ( - "errors" - "log" - "time" - - "github.com/jonboulle/clockwork" - - "github.com/coreos/pkg/timeutil" -) - -func NewKeySetSyncer(r ReadableKeySetRepo, w WritableKeySetRepo) *KeySetSyncer { - return &KeySetSyncer{ - readable: r, - writable: w, - clock: clockwork.NewRealClock(), - } -} - -type KeySetSyncer struct { - readable ReadableKeySetRepo - writable WritableKeySetRepo - clock clockwork.Clock -} - -func (s *KeySetSyncer) Run() chan struct{} { - stop := make(chan struct{}) - go func() { - var failing bool - var next time.Duration - for { - exp, err := syncKeySet(s.readable, s.writable, s.clock) - if err != nil || exp == 0 { - if !failing { - failing = true - next = time.Second - } else { - next = timeutil.ExpBackoff(next, time.Minute) - } - if exp == 0 { - log.Printf("Synced to already expired key set, retrying in %v: %v", next, err) - - } else { - log.Printf("Failed syncing key set, retrying in %v: %v", next, err) - } - } else { - failing = false - next = exp / 2 - } - - select { - case <-s.clock.After(next): - continue - case <-stop: - return - } - } - }() - - return stop -} - -func Sync(r ReadableKeySetRepo, w WritableKeySetRepo) (time.Duration, error) { - return syncKeySet(r, w, clockwork.NewRealClock()) -} - -// syncKeySet copies the keyset from r to the KeySet at w and returns the duration in which the KeySet will expire. -// If keyset has already expired, returns a zero duration. -func syncKeySet(r ReadableKeySetRepo, w WritableKeySetRepo, clock clockwork.Clock) (exp time.Duration, err error) { - var ks KeySet - ks, err = r.Get() - if err != nil { - return - } - - if ks == nil { - err = errors.New("no source KeySet") - return - } - - if err = w.Set(ks); err != nil { - return - } - - now := clock.Now() - if ks.ExpiresAt().After(now) { - exp = ks.ExpiresAt().Sub(now) - } - return -} diff --git a/vendor/github.com/coreos/go-oidc/oauth2/error.go b/vendor/github.com/coreos/go-oidc/oauth2/error.go deleted file mode 100644 index 50d890949a..0000000000 --- a/vendor/github.com/coreos/go-oidc/oauth2/error.go +++ /dev/null @@ -1,29 +0,0 @@ -package oauth2 - -const ( - ErrorAccessDenied = "access_denied" - ErrorInvalidClient = "invalid_client" - ErrorInvalidGrant = "invalid_grant" - ErrorInvalidRequest = "invalid_request" - ErrorServerError = "server_error" - ErrorUnauthorizedClient = "unauthorized_client" - ErrorUnsupportedGrantType = "unsupported_grant_type" - ErrorUnsupportedResponseType = "unsupported_response_type" -) - -type Error struct { - Type string `json:"error"` - Description string `json:"error_description,omitempty"` - State string `json:"state,omitempty"` -} - -func (e *Error) Error() string { - if e.Description != "" { - return e.Type + ": " + e.Description - } - return e.Type -} - -func NewError(typ string) *Error { - return &Error{Type: typ} -} diff --git a/vendor/github.com/coreos/go-oidc/oauth2/oauth2.go b/vendor/github.com/coreos/go-oidc/oauth2/oauth2.go deleted file mode 100644 index 72d1d6715b..0000000000 --- a/vendor/github.com/coreos/go-oidc/oauth2/oauth2.go +++ /dev/null @@ -1,416 +0,0 @@ -package oauth2 - -import ( - "encoding/json" - "errors" - "fmt" - "io/ioutil" - "mime" - "net/http" - "net/url" - "sort" - "strconv" - "strings" - - phttp "github.com/coreos/go-oidc/http" -) - -// ResponseTypesEqual compares two response_type values. If either -// contains a space, it is treated as an unordered list. For example, -// comparing "code id_token" and "id_token code" would evaluate to true. -func ResponseTypesEqual(r1, r2 string) bool { - if !strings.Contains(r1, " ") || !strings.Contains(r2, " ") { - // fast route, no split needed - return r1 == r2 - } - - // split, sort, and compare - r1Fields := strings.Fields(r1) - r2Fields := strings.Fields(r2) - if len(r1Fields) != len(r2Fields) { - return false - } - sort.Strings(r1Fields) - sort.Strings(r2Fields) - for i, r1Field := range r1Fields { - if r1Field != r2Fields[i] { - return false - } - } - return true -} - -const ( - // OAuth2.0 response types registered by OIDC. - // - // See: https://openid.net/specs/oauth-v2-multiple-response-types-1_0.html#RegistryContents - ResponseTypeCode = "code" - ResponseTypeCodeIDToken = "code id_token" - ResponseTypeCodeIDTokenToken = "code id_token token" - ResponseTypeIDToken = "id_token" - ResponseTypeIDTokenToken = "id_token token" - ResponseTypeToken = "token" - ResponseTypeNone = "none" -) - -const ( - GrantTypeAuthCode = "authorization_code" - GrantTypeClientCreds = "client_credentials" - GrantTypeUserCreds = "password" - GrantTypeImplicit = "implicit" - GrantTypeRefreshToken = "refresh_token" - - AuthMethodClientSecretPost = "client_secret_post" - AuthMethodClientSecretBasic = "client_secret_basic" - AuthMethodClientSecretJWT = "client_secret_jwt" - AuthMethodPrivateKeyJWT = "private_key_jwt" -) - -type Config struct { - Credentials ClientCredentials - Scope []string - RedirectURL string - AuthURL string - TokenURL string - - // Must be one of the AuthMethodXXX methods above. Right now, only - // AuthMethodClientSecretPost and AuthMethodClientSecretBasic are supported. - AuthMethod string -} - -type Client struct { - hc phttp.Client - creds ClientCredentials - scope []string - authURL *url.URL - redirectURL *url.URL - tokenURL *url.URL - authMethod string -} - -type ClientCredentials struct { - ID string - Secret string -} - -func NewClient(hc phttp.Client, cfg Config) (c *Client, err error) { - if len(cfg.Credentials.ID) == 0 { - err = errors.New("missing client id") - return - } - - if len(cfg.Credentials.Secret) == 0 { - err = errors.New("missing client secret") - return - } - - if cfg.AuthMethod == "" { - cfg.AuthMethod = AuthMethodClientSecretBasic - } else if cfg.AuthMethod != AuthMethodClientSecretPost && cfg.AuthMethod != AuthMethodClientSecretBasic { - err = fmt.Errorf("auth method %q is not supported", cfg.AuthMethod) - return - } - - au, err := phttp.ParseNonEmptyURL(cfg.AuthURL) - if err != nil { - return - } - - tu, err := phttp.ParseNonEmptyURL(cfg.TokenURL) - if err != nil { - return - } - - // Allow empty redirect URL in the case where the client - // only needs to verify a given token. - ru, err := url.Parse(cfg.RedirectURL) - if err != nil { - return - } - - c = &Client{ - creds: cfg.Credentials, - scope: cfg.Scope, - redirectURL: ru, - authURL: au, - tokenURL: tu, - hc: hc, - authMethod: cfg.AuthMethod, - } - - return -} - -// Return the embedded HTTP client -func (c *Client) HttpClient() phttp.Client { - return c.hc -} - -// Generate the url for initial redirect to oauth provider. -func (c *Client) AuthCodeURL(state, accessType, prompt string) string { - v := c.commonURLValues() - v.Set("state", state) - if strings.ToLower(accessType) == "offline" { - v.Set("access_type", "offline") - } - - if prompt != "" { - v.Set("prompt", prompt) - } - v.Set("response_type", "code") - - q := v.Encode() - u := *c.authURL - if u.RawQuery == "" { - u.RawQuery = q - } else { - u.RawQuery += "&" + q - } - return u.String() -} - -func (c *Client) commonURLValues() url.Values { - return url.Values{ - "redirect_uri": {c.redirectURL.String()}, - "scope": {strings.Join(c.scope, " ")}, - "client_id": {c.creds.ID}, - } -} - -func (c *Client) newAuthenticatedRequest(urlToken string, values url.Values) (*http.Request, error) { - var req *http.Request - var err error - switch c.authMethod { - case AuthMethodClientSecretPost: - values.Set("client_secret", c.creds.Secret) - req, err = http.NewRequest("POST", urlToken, strings.NewReader(values.Encode())) - if err != nil { - return nil, err - } - case AuthMethodClientSecretBasic: - req, err = http.NewRequest("POST", urlToken, strings.NewReader(values.Encode())) - if err != nil { - return nil, err - } - encodedID := url.QueryEscape(c.creds.ID) - encodedSecret := url.QueryEscape(c.creds.Secret) - req.SetBasicAuth(encodedID, encodedSecret) - default: - panic("misconfigured client: auth method not supported") - } - - req.Header.Set("Content-Type", "application/x-www-form-urlencoded") - return req, nil - -} - -// ClientCredsToken posts the client id and secret to obtain a token scoped to the OAuth2 client via the "client_credentials" grant type. -// May not be supported by all OAuth2 servers. -func (c *Client) ClientCredsToken(scope []string) (result TokenResponse, err error) { - v := url.Values{ - "scope": {strings.Join(scope, " ")}, - "grant_type": {GrantTypeClientCreds}, - } - - req, err := c.newAuthenticatedRequest(c.tokenURL.String(), v) - if err != nil { - return - } - - resp, err := c.hc.Do(req) - if err != nil { - return - } - defer resp.Body.Close() - - return parseTokenResponse(resp) -} - -// UserCredsToken posts the username and password to obtain a token scoped to the OAuth2 client via the "password" grant_type -// May not be supported by all OAuth2 servers. -func (c *Client) UserCredsToken(username, password string) (result TokenResponse, err error) { - v := url.Values{ - "scope": {strings.Join(c.scope, " ")}, - "grant_type": {GrantTypeUserCreds}, - "username": {username}, - "password": {password}, - } - - req, err := c.newAuthenticatedRequest(c.tokenURL.String(), v) - if err != nil { - return - } - - resp, err := c.hc.Do(req) - if err != nil { - return - } - defer resp.Body.Close() - - return parseTokenResponse(resp) -} - -// RequestToken requests a token from the Token Endpoint with the specified grantType. -// If 'grantType' == GrantTypeAuthCode, then 'value' should be the authorization code. -// If 'grantType' == GrantTypeRefreshToken, then 'value' should be the refresh token. -func (c *Client) RequestToken(grantType, value string) (result TokenResponse, err error) { - v := c.commonURLValues() - - v.Set("grant_type", grantType) - v.Set("client_secret", c.creds.Secret) - switch grantType { - case GrantTypeAuthCode: - v.Set("code", value) - case GrantTypeRefreshToken: - v.Set("refresh_token", value) - default: - err = fmt.Errorf("unsupported grant_type: %v", grantType) - return - } - - req, err := c.newAuthenticatedRequest(c.tokenURL.String(), v) - if err != nil { - return - } - - resp, err := c.hc.Do(req) - if err != nil { - return - } - defer resp.Body.Close() - - return parseTokenResponse(resp) -} - -func parseTokenResponse(resp *http.Response) (result TokenResponse, err error) { - body, err := ioutil.ReadAll(resp.Body) - if err != nil { - return - } - badStatusCode := resp.StatusCode < 200 || resp.StatusCode > 299 - - contentType, _, err := mime.ParseMediaType(resp.Header.Get("Content-Type")) - if err != nil { - return - } - - result = TokenResponse{ - RawBody: body, - } - - newError := func(typ, desc, state string) error { - if typ == "" { - return fmt.Errorf("unrecognized error %s", body) - } - return &Error{typ, desc, state} - } - - if contentType == "application/x-www-form-urlencoded" || contentType == "text/plain" { - var vals url.Values - vals, err = url.ParseQuery(string(body)) - if err != nil { - return - } - if error := vals.Get("error"); error != "" || badStatusCode { - err = newError(error, vals.Get("error_description"), vals.Get("state")) - return - } - e := vals.Get("expires_in") - if e == "" { - e = vals.Get("expires") - } - if e != "" { - result.Expires, err = strconv.Atoi(e) - if err != nil { - return - } - } - result.AccessToken = vals.Get("access_token") - result.TokenType = vals.Get("token_type") - result.IDToken = vals.Get("id_token") - result.RefreshToken = vals.Get("refresh_token") - result.Scope = vals.Get("scope") - } else { - var r struct { - AccessToken string `json:"access_token"` - TokenType string `json:"token_type"` - IDToken string `json:"id_token"` - RefreshToken string `json:"refresh_token"` - Scope string `json:"scope"` - State string `json:"state"` - ExpiresIn json.Number `json:"expires_in"` // Azure AD returns string - Expires int `json:"expires"` - Error string `json:"error"` - Desc string `json:"error_description"` - } - if err = json.Unmarshal(body, &r); err != nil { - return - } - if r.Error != "" || badStatusCode { - err = newError(r.Error, r.Desc, r.State) - return - } - result.AccessToken = r.AccessToken - result.TokenType = r.TokenType - result.IDToken = r.IDToken - result.RefreshToken = r.RefreshToken - result.Scope = r.Scope - if expiresIn, err := r.ExpiresIn.Int64(); err != nil { - result.Expires = r.Expires - } else { - result.Expires = int(expiresIn) - } - } - return -} - -type TokenResponse struct { - AccessToken string - TokenType string - Expires int - IDToken string - RefreshToken string // OPTIONAL. - Scope string // OPTIONAL, if identical to the scope requested by the client, otherwise, REQUIRED. - RawBody []byte // In case callers need some other non-standard info from the token response -} - -type AuthCodeRequest struct { - ResponseType string - ClientID string - RedirectURL *url.URL - Scope []string - State string -} - -func ParseAuthCodeRequest(q url.Values) (AuthCodeRequest, error) { - acr := AuthCodeRequest{ - ResponseType: q.Get("response_type"), - ClientID: q.Get("client_id"), - State: q.Get("state"), - Scope: make([]string, 0), - } - - qs := strings.TrimSpace(q.Get("scope")) - if qs != "" { - acr.Scope = strings.Split(qs, " ") - } - - err := func() error { - if acr.ClientID == "" { - return NewError(ErrorInvalidRequest) - } - - redirectURL := q.Get("redirect_uri") - if redirectURL != "" { - ru, err := url.Parse(redirectURL) - if err != nil { - return NewError(ErrorInvalidRequest) - } - acr.RedirectURL = ru - } - - return nil - }() - - return acr, err -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/client.go b/vendor/github.com/coreos/go-oidc/oidc/client.go deleted file mode 100644 index 7a3cb40f64..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/client.go +++ /dev/null @@ -1,846 +0,0 @@ -package oidc - -import ( - "encoding/json" - "errors" - "fmt" - "net/http" - "net/mail" - "net/url" - "sync" - "time" - - phttp "github.com/coreos/go-oidc/http" - "github.com/coreos/go-oidc/jose" - "github.com/coreos/go-oidc/key" - "github.com/coreos/go-oidc/oauth2" -) - -const ( - // amount of time that must pass after the last key sync - // completes before another attempt may begin - keySyncWindow = 5 * time.Second -) - -var ( - DefaultScope = []string{"openid", "email", "profile"} - - supportedAuthMethods = map[string]struct{}{ - oauth2.AuthMethodClientSecretBasic: struct{}{}, - oauth2.AuthMethodClientSecretPost: struct{}{}, - } -) - -type ClientCredentials oauth2.ClientCredentials - -type ClientIdentity struct { - Credentials ClientCredentials - Metadata ClientMetadata -} - -type JWAOptions struct { - // SigningAlg specifies an JWA alg for signing JWTs. - // - // Specifying this field implies different actions depending on the context. It may - // require objects be serialized and signed as a JWT instead of plain JSON, or - // require an existing JWT object use the specified alg. - // - // See: http://openid.net/specs/openid-connect-registration-1_0.html#ClientMetadata - SigningAlg string - // EncryptionAlg, if provided, specifies that the returned or sent object be stored - // (or nested) within a JWT object and encrypted with the provided JWA alg. - EncryptionAlg string - // EncryptionEnc specifies the JWA enc algorithm to use with EncryptionAlg. If - // EncryptionAlg is provided and EncryptionEnc is omitted, this field defaults - // to A128CBC-HS256. - // - // If EncryptionEnc is provided EncryptionAlg must also be specified. - EncryptionEnc string -} - -func (opt JWAOptions) valid() error { - if opt.EncryptionEnc != "" && opt.EncryptionAlg == "" { - return errors.New("encryption encoding provided with no encryption algorithm") - } - return nil -} - -func (opt JWAOptions) defaults() JWAOptions { - if opt.EncryptionAlg != "" && opt.EncryptionEnc == "" { - opt.EncryptionEnc = jose.EncA128CBCHS256 - } - return opt -} - -var ( - // Ensure ClientMetadata satisfies these interfaces. - _ json.Marshaler = &ClientMetadata{} - _ json.Unmarshaler = &ClientMetadata{} -) - -// ClientMetadata holds metadata that the authorization server associates -// with a client identifier. The fields range from human-facing display -// strings such as client name, to items that impact the security of the -// protocol, such as the list of valid redirect URIs. -// -// See http://openid.net/specs/openid-connect-registration-1_0.html#ClientMetadata -// -// TODO: support language specific claim representations -// http://openid.net/specs/openid-connect-registration-1_0.html#LanguagesAndScripts -type ClientMetadata struct { - RedirectURIs []url.URL // Required - - // A list of OAuth 2.0 "response_type" values that the client wishes to restrict - // itself to. Either "code", "token", or another registered extension. - // - // If omitted, only "code" will be used. - ResponseTypes []string - // A list of OAuth 2.0 grant types the client wishes to restrict itself to. - // The grant type values used by OIDC are "authorization_code", "implicit", - // and "refresh_token". - // - // If ommitted, only "authorization_code" will be used. - GrantTypes []string - // "native" or "web". If omitted, "web". - ApplicationType string - - // List of email addresses. - Contacts []mail.Address - // Name of client to be presented to the end-user. - ClientName string - // URL that references a logo for the Client application. - LogoURI *url.URL - // URL of the home page of the Client. - ClientURI *url.URL - // Profile data policies and terms of use to be provided to the end user. - PolicyURI *url.URL - TermsOfServiceURI *url.URL - - // URL to or the value of the client's JSON Web Key Set document. - JWKSURI *url.URL - JWKS *jose.JWKSet - - // URL referencing a flie with a single JSON array of redirect URIs. - SectorIdentifierURI *url.URL - - SubjectType string - - // Options to restrict the JWS alg and enc values used for server responses and requests. - IDTokenResponseOptions JWAOptions - UserInfoResponseOptions JWAOptions - RequestObjectOptions JWAOptions - - // Client requested authorization method and signing options for the token endpoint. - // - // Defaults to "client_secret_basic" - TokenEndpointAuthMethod string - TokenEndpointAuthSigningAlg string - - // DefaultMaxAge specifies the maximum amount of time in seconds before an authorized - // user must reauthroize. - // - // If 0, no limitation is placed on the maximum. - DefaultMaxAge int64 - // RequireAuthTime specifies if the auth_time claim in the ID token is required. - RequireAuthTime bool - - // Default Authentication Context Class Reference values for authentication requests. - DefaultACRValues []string - - // URI that a third party can use to initiate a login by the relaying party. - // - // See: http://openid.net/specs/openid-connect-core-1_0.html#ThirdPartyInitiatedLogin - InitiateLoginURI *url.URL - // Pre-registered request_uri values that may be cached by the server. - RequestURIs []url.URL -} - -// Defaults returns a shallow copy of ClientMetadata with default -// values replacing omitted fields. -func (m ClientMetadata) Defaults() ClientMetadata { - if len(m.ResponseTypes) == 0 { - m.ResponseTypes = []string{oauth2.ResponseTypeCode} - } - if len(m.GrantTypes) == 0 { - m.GrantTypes = []string{oauth2.GrantTypeAuthCode} - } - if m.ApplicationType == "" { - m.ApplicationType = "web" - } - if m.TokenEndpointAuthMethod == "" { - m.TokenEndpointAuthMethod = oauth2.AuthMethodClientSecretBasic - } - m.IDTokenResponseOptions = m.IDTokenResponseOptions.defaults() - m.UserInfoResponseOptions = m.UserInfoResponseOptions.defaults() - m.RequestObjectOptions = m.RequestObjectOptions.defaults() - return m -} - -func (m *ClientMetadata) MarshalJSON() ([]byte, error) { - e := m.toEncodableStruct() - return json.Marshal(&e) -} - -func (m *ClientMetadata) UnmarshalJSON(data []byte) error { - var e encodableClientMetadata - if err := json.Unmarshal(data, &e); err != nil { - return err - } - meta, err := e.toStruct() - if err != nil { - return err - } - if err := meta.Valid(); err != nil { - return err - } - *m = meta - return nil -} - -type encodableClientMetadata struct { - RedirectURIs []string `json:"redirect_uris"` // Required - ResponseTypes []string `json:"response_types,omitempty"` - GrantTypes []string `json:"grant_types,omitempty"` - ApplicationType string `json:"application_type,omitempty"` - Contacts []string `json:"contacts,omitempty"` - ClientName string `json:"client_name,omitempty"` - LogoURI string `json:"logo_uri,omitempty"` - ClientURI string `json:"client_uri,omitempty"` - PolicyURI string `json:"policy_uri,omitempty"` - TermsOfServiceURI string `json:"tos_uri,omitempty"` - JWKSURI string `json:"jwks_uri,omitempty"` - JWKS *jose.JWKSet `json:"jwks,omitempty"` - SectorIdentifierURI string `json:"sector_identifier_uri,omitempty"` - SubjectType string `json:"subject_type,omitempty"` - IDTokenSignedResponseAlg string `json:"id_token_signed_response_alg,omitempty"` - IDTokenEncryptedResponseAlg string `json:"id_token_encrypted_response_alg,omitempty"` - IDTokenEncryptedResponseEnc string `json:"id_token_encrypted_response_enc,omitempty"` - UserInfoSignedResponseAlg string `json:"userinfo_signed_response_alg,omitempty"` - UserInfoEncryptedResponseAlg string `json:"userinfo_encrypted_response_alg,omitempty"` - UserInfoEncryptedResponseEnc string `json:"userinfo_encrypted_response_enc,omitempty"` - RequestObjectSigningAlg string `json:"request_object_signing_alg,omitempty"` - RequestObjectEncryptionAlg string `json:"request_object_encryption_alg,omitempty"` - RequestObjectEncryptionEnc string `json:"request_object_encryption_enc,omitempty"` - TokenEndpointAuthMethod string `json:"token_endpoint_auth_method,omitempty"` - TokenEndpointAuthSigningAlg string `json:"token_endpoint_auth_signing_alg,omitempty"` - DefaultMaxAge int64 `json:"default_max_age,omitempty"` - RequireAuthTime bool `json:"require_auth_time,omitempty"` - DefaultACRValues []string `json:"default_acr_values,omitempty"` - InitiateLoginURI string `json:"initiate_login_uri,omitempty"` - RequestURIs []string `json:"request_uris,omitempty"` -} - -func (c *encodableClientMetadata) toStruct() (ClientMetadata, error) { - p := stickyErrParser{} - m := ClientMetadata{ - RedirectURIs: p.parseURIs(c.RedirectURIs, "redirect_uris"), - ResponseTypes: c.ResponseTypes, - GrantTypes: c.GrantTypes, - ApplicationType: c.ApplicationType, - Contacts: p.parseEmails(c.Contacts, "contacts"), - ClientName: c.ClientName, - LogoURI: p.parseURI(c.LogoURI, "logo_uri"), - ClientURI: p.parseURI(c.ClientURI, "client_uri"), - PolicyURI: p.parseURI(c.PolicyURI, "policy_uri"), - TermsOfServiceURI: p.parseURI(c.TermsOfServiceURI, "tos_uri"), - JWKSURI: p.parseURI(c.JWKSURI, "jwks_uri"), - JWKS: c.JWKS, - SectorIdentifierURI: p.parseURI(c.SectorIdentifierURI, "sector_identifier_uri"), - SubjectType: c.SubjectType, - TokenEndpointAuthMethod: c.TokenEndpointAuthMethod, - TokenEndpointAuthSigningAlg: c.TokenEndpointAuthSigningAlg, - DefaultMaxAge: c.DefaultMaxAge, - RequireAuthTime: c.RequireAuthTime, - DefaultACRValues: c.DefaultACRValues, - InitiateLoginURI: p.parseURI(c.InitiateLoginURI, "initiate_login_uri"), - RequestURIs: p.parseURIs(c.RequestURIs, "request_uris"), - IDTokenResponseOptions: JWAOptions{ - c.IDTokenSignedResponseAlg, - c.IDTokenEncryptedResponseAlg, - c.IDTokenEncryptedResponseEnc, - }, - UserInfoResponseOptions: JWAOptions{ - c.UserInfoSignedResponseAlg, - c.UserInfoEncryptedResponseAlg, - c.UserInfoEncryptedResponseEnc, - }, - RequestObjectOptions: JWAOptions{ - c.RequestObjectSigningAlg, - c.RequestObjectEncryptionAlg, - c.RequestObjectEncryptionEnc, - }, - } - if p.firstErr != nil { - return ClientMetadata{}, p.firstErr - } - return m, nil -} - -// stickyErrParser parses URIs and email addresses. Once it encounters -// a parse error, subsequent calls become no-op. -type stickyErrParser struct { - firstErr error -} - -func (p *stickyErrParser) parseURI(s, field string) *url.URL { - if p.firstErr != nil || s == "" { - return nil - } - u, err := url.Parse(s) - if err == nil { - if u.Host == "" { - err = errors.New("no host in URI") - } else if u.Scheme != "http" && u.Scheme != "https" { - err = errors.New("invalid URI scheme") - } - } - if err != nil { - p.firstErr = fmt.Errorf("failed to parse %s: %v", field, err) - return nil - } - return u -} - -func (p *stickyErrParser) parseURIs(s []string, field string) []url.URL { - if p.firstErr != nil || len(s) == 0 { - return nil - } - uris := make([]url.URL, len(s)) - for i, val := range s { - if val == "" { - p.firstErr = fmt.Errorf("invalid URI in field %s", field) - return nil - } - if u := p.parseURI(val, field); u != nil { - uris[i] = *u - } - } - return uris -} - -func (p *stickyErrParser) parseEmails(s []string, field string) []mail.Address { - if p.firstErr != nil || len(s) == 0 { - return nil - } - addrs := make([]mail.Address, len(s)) - for i, addr := range s { - if addr == "" { - p.firstErr = fmt.Errorf("invalid email in field %s", field) - return nil - } - a, err := mail.ParseAddress(addr) - if err != nil { - p.firstErr = fmt.Errorf("invalid email in field %s: %v", field, err) - return nil - } - addrs[i] = *a - } - return addrs -} - -func (m *ClientMetadata) toEncodableStruct() encodableClientMetadata { - return encodableClientMetadata{ - RedirectURIs: urisToStrings(m.RedirectURIs), - ResponseTypes: m.ResponseTypes, - GrantTypes: m.GrantTypes, - ApplicationType: m.ApplicationType, - Contacts: emailsToStrings(m.Contacts), - ClientName: m.ClientName, - LogoURI: uriToString(m.LogoURI), - ClientURI: uriToString(m.ClientURI), - PolicyURI: uriToString(m.PolicyURI), - TermsOfServiceURI: uriToString(m.TermsOfServiceURI), - JWKSURI: uriToString(m.JWKSURI), - JWKS: m.JWKS, - SectorIdentifierURI: uriToString(m.SectorIdentifierURI), - SubjectType: m.SubjectType, - IDTokenSignedResponseAlg: m.IDTokenResponseOptions.SigningAlg, - IDTokenEncryptedResponseAlg: m.IDTokenResponseOptions.EncryptionAlg, - IDTokenEncryptedResponseEnc: m.IDTokenResponseOptions.EncryptionEnc, - UserInfoSignedResponseAlg: m.UserInfoResponseOptions.SigningAlg, - UserInfoEncryptedResponseAlg: m.UserInfoResponseOptions.EncryptionAlg, - UserInfoEncryptedResponseEnc: m.UserInfoResponseOptions.EncryptionEnc, - RequestObjectSigningAlg: m.RequestObjectOptions.SigningAlg, - RequestObjectEncryptionAlg: m.RequestObjectOptions.EncryptionAlg, - RequestObjectEncryptionEnc: m.RequestObjectOptions.EncryptionEnc, - TokenEndpointAuthMethod: m.TokenEndpointAuthMethod, - TokenEndpointAuthSigningAlg: m.TokenEndpointAuthSigningAlg, - DefaultMaxAge: m.DefaultMaxAge, - RequireAuthTime: m.RequireAuthTime, - DefaultACRValues: m.DefaultACRValues, - InitiateLoginURI: uriToString(m.InitiateLoginURI), - RequestURIs: urisToStrings(m.RequestURIs), - } -} - -func uriToString(u *url.URL) string { - if u == nil { - return "" - } - return u.String() -} - -func urisToStrings(urls []url.URL) []string { - if len(urls) == 0 { - return nil - } - sli := make([]string, len(urls)) - for i, u := range urls { - sli[i] = u.String() - } - return sli -} - -func emailsToStrings(addrs []mail.Address) []string { - if len(addrs) == 0 { - return nil - } - sli := make([]string, len(addrs)) - for i, addr := range addrs { - sli[i] = addr.String() - } - return sli -} - -// Valid determines if a ClientMetadata conforms with the OIDC specification. -// -// Valid is called by UnmarshalJSON. -// -// NOTE(ericchiang): For development purposes Valid does not mandate 'https' for -// URLs fields where the OIDC spec requires it. This may change in future releases -// of this package. See: https://github.com/coreos/go-oidc/issues/34 -func (m *ClientMetadata) Valid() error { - if len(m.RedirectURIs) == 0 { - return errors.New("zero redirect URLs") - } - - validURI := func(u *url.URL, fieldName string) error { - if u.Host == "" { - return fmt.Errorf("no host for uri field %s", fieldName) - } - if u.Scheme != "http" && u.Scheme != "https" { - return fmt.Errorf("uri field %s scheme is not http or https", fieldName) - } - return nil - } - - uris := []struct { - val *url.URL - name string - }{ - {m.LogoURI, "logo_uri"}, - {m.ClientURI, "client_uri"}, - {m.PolicyURI, "policy_uri"}, - {m.TermsOfServiceURI, "tos_uri"}, - {m.JWKSURI, "jwks_uri"}, - {m.SectorIdentifierURI, "sector_identifier_uri"}, - {m.InitiateLoginURI, "initiate_login_uri"}, - } - - for _, uri := range uris { - if uri.val == nil { - continue - } - if err := validURI(uri.val, uri.name); err != nil { - return err - } - } - - uriLists := []struct { - vals []url.URL - name string - }{ - {m.RedirectURIs, "redirect_uris"}, - {m.RequestURIs, "request_uris"}, - } - for _, list := range uriLists { - for _, uri := range list.vals { - if err := validURI(&uri, list.name); err != nil { - return err - } - } - } - - options := []struct { - option JWAOptions - name string - }{ - {m.IDTokenResponseOptions, "id_token response"}, - {m.UserInfoResponseOptions, "userinfo response"}, - {m.RequestObjectOptions, "request_object"}, - } - for _, option := range options { - if err := option.option.valid(); err != nil { - return fmt.Errorf("invalid JWA values for %s: %v", option.name, err) - } - } - return nil -} - -type ClientRegistrationResponse struct { - ClientID string // Required - ClientSecret string - RegistrationAccessToken string - RegistrationClientURI string - // If IsZero is true, unspecified. - ClientIDIssuedAt time.Time - // Time at which the client_secret will expire. - // If IsZero is true, it will not expire. - ClientSecretExpiresAt time.Time - - ClientMetadata -} - -type encodableClientRegistrationResponse struct { - ClientID string `json:"client_id"` // Required - ClientSecret string `json:"client_secret,omitempty"` - RegistrationAccessToken string `json:"registration_access_token,omitempty"` - RegistrationClientURI string `json:"registration_client_uri,omitempty"` - ClientIDIssuedAt int64 `json:"client_id_issued_at,omitempty"` - // Time at which the client_secret will expire, in seconds since the epoch. - // If 0 it will not expire. - ClientSecretExpiresAt int64 `json:"client_secret_expires_at"` // Required - - encodableClientMetadata -} - -func unixToSec(t time.Time) int64 { - if t.IsZero() { - return 0 - } - return t.Unix() -} - -func (c *ClientRegistrationResponse) MarshalJSON() ([]byte, error) { - e := encodableClientRegistrationResponse{ - ClientID: c.ClientID, - ClientSecret: c.ClientSecret, - RegistrationAccessToken: c.RegistrationAccessToken, - RegistrationClientURI: c.RegistrationClientURI, - ClientIDIssuedAt: unixToSec(c.ClientIDIssuedAt), - ClientSecretExpiresAt: unixToSec(c.ClientSecretExpiresAt), - encodableClientMetadata: c.ClientMetadata.toEncodableStruct(), - } - return json.Marshal(&e) -} - -func secToUnix(sec int64) time.Time { - if sec == 0 { - return time.Time{} - } - return time.Unix(sec, 0) -} - -func (c *ClientRegistrationResponse) UnmarshalJSON(data []byte) error { - var e encodableClientRegistrationResponse - if err := json.Unmarshal(data, &e); err != nil { - return err - } - if e.ClientID == "" { - return errors.New("no client_id in client registration response") - } - metadata, err := e.encodableClientMetadata.toStruct() - if err != nil { - return err - } - *c = ClientRegistrationResponse{ - ClientID: e.ClientID, - ClientSecret: e.ClientSecret, - RegistrationAccessToken: e.RegistrationAccessToken, - RegistrationClientURI: e.RegistrationClientURI, - ClientIDIssuedAt: secToUnix(e.ClientIDIssuedAt), - ClientSecretExpiresAt: secToUnix(e.ClientSecretExpiresAt), - ClientMetadata: metadata, - } - return nil -} - -type ClientConfig struct { - HTTPClient phttp.Client - Credentials ClientCredentials - Scope []string - RedirectURL string - ProviderConfig ProviderConfig - KeySet key.PublicKeySet -} - -func NewClient(cfg ClientConfig) (*Client, error) { - // Allow empty redirect URL in the case where the client - // only needs to verify a given token. - ru, err := url.Parse(cfg.RedirectURL) - if err != nil { - return nil, fmt.Errorf("invalid redirect URL: %v", err) - } - - c := Client{ - credentials: cfg.Credentials, - httpClient: cfg.HTTPClient, - scope: cfg.Scope, - redirectURL: ru.String(), - providerConfig: newProviderConfigRepo(cfg.ProviderConfig), - keySet: cfg.KeySet, - } - - if c.httpClient == nil { - c.httpClient = http.DefaultClient - } - - if c.scope == nil { - c.scope = make([]string, len(DefaultScope)) - copy(c.scope, DefaultScope) - } - - return &c, nil -} - -type Client struct { - httpClient phttp.Client - providerConfig *providerConfigRepo - credentials ClientCredentials - redirectURL string - scope []string - keySet key.PublicKeySet - providerSyncer *ProviderConfigSyncer - - keySetSyncMutex sync.RWMutex - lastKeySetSync time.Time -} - -func (c *Client) Healthy() error { - now := time.Now().UTC() - - cfg := c.providerConfig.Get() - - if cfg.Empty() { - return errors.New("oidc client provider config empty") - } - - if !cfg.ExpiresAt.IsZero() && cfg.ExpiresAt.Before(now) { - return errors.New("oidc client provider config expired") - } - - return nil -} - -func (c *Client) OAuthClient() (*oauth2.Client, error) { - cfg := c.providerConfig.Get() - authMethod, err := chooseAuthMethod(cfg) - if err != nil { - return nil, err - } - - ocfg := oauth2.Config{ - Credentials: oauth2.ClientCredentials(c.credentials), - RedirectURL: c.redirectURL, - AuthURL: cfg.AuthEndpoint.String(), - TokenURL: cfg.TokenEndpoint.String(), - Scope: c.scope, - AuthMethod: authMethod, - } - - return oauth2.NewClient(c.httpClient, ocfg) -} - -func chooseAuthMethod(cfg ProviderConfig) (string, error) { - if len(cfg.TokenEndpointAuthMethodsSupported) == 0 { - return oauth2.AuthMethodClientSecretBasic, nil - } - - for _, authMethod := range cfg.TokenEndpointAuthMethodsSupported { - if _, ok := supportedAuthMethods[authMethod]; ok { - return authMethod, nil - } - } - - return "", errors.New("no supported auth methods") -} - -// SyncProviderConfig starts the provider config syncer -func (c *Client) SyncProviderConfig(discoveryURL string) chan struct{} { - r := NewHTTPProviderConfigGetter(c.httpClient, discoveryURL) - s := NewProviderConfigSyncer(r, c.providerConfig) - stop := s.Run() - s.WaitUntilInitialSync() - return stop -} - -func (c *Client) maybeSyncKeys() error { - tooSoon := func() bool { - return time.Now().UTC().Before(c.lastKeySetSync.Add(keySyncWindow)) - } - - // ignore request to sync keys if a sync operation has been - // attempted too recently - if tooSoon() { - return nil - } - - c.keySetSyncMutex.Lock() - defer c.keySetSyncMutex.Unlock() - - // check again, as another goroutine may have been holding - // the lock while updating the keys - if tooSoon() { - return nil - } - - cfg := c.providerConfig.Get() - r := NewRemotePublicKeyRepo(c.httpClient, cfg.KeysEndpoint.String()) - w := &clientKeyRepo{client: c} - _, err := key.Sync(r, w) - c.lastKeySetSync = time.Now().UTC() - - return err -} - -type clientKeyRepo struct { - client *Client -} - -func (r *clientKeyRepo) Set(ks key.KeySet) error { - pks, ok := ks.(*key.PublicKeySet) - if !ok { - return errors.New("unable to cast to PublicKey") - } - r.client.keySet = *pks - return nil -} - -func (c *Client) ClientCredsToken(scope []string) (jose.JWT, error) { - cfg := c.providerConfig.Get() - - if !cfg.SupportsGrantType(oauth2.GrantTypeClientCreds) { - return jose.JWT{}, fmt.Errorf("%v grant type is not supported", oauth2.GrantTypeClientCreds) - } - - oac, err := c.OAuthClient() - if err != nil { - return jose.JWT{}, err - } - - t, err := oac.ClientCredsToken(scope) - if err != nil { - return jose.JWT{}, err - } - - jwt, err := jose.ParseJWT(t.IDToken) - if err != nil { - return jose.JWT{}, err - } - - return jwt, c.VerifyJWT(jwt) -} - -// ExchangeAuthCode exchanges an OAuth2 auth code for an OIDC JWT ID token. -func (c *Client) ExchangeAuthCode(code string) (jose.JWT, error) { - oac, err := c.OAuthClient() - if err != nil { - return jose.JWT{}, err - } - - t, err := oac.RequestToken(oauth2.GrantTypeAuthCode, code) - if err != nil { - return jose.JWT{}, err - } - - jwt, err := jose.ParseJWT(t.IDToken) - if err != nil { - return jose.JWT{}, err - } - - return jwt, c.VerifyJWT(jwt) -} - -// RefreshToken uses a refresh token to exchange for a new OIDC JWT ID Token. -func (c *Client) RefreshToken(refreshToken string) (jose.JWT, error) { - oac, err := c.OAuthClient() - if err != nil { - return jose.JWT{}, err - } - - t, err := oac.RequestToken(oauth2.GrantTypeRefreshToken, refreshToken) - if err != nil { - return jose.JWT{}, err - } - - jwt, err := jose.ParseJWT(t.IDToken) - if err != nil { - return jose.JWT{}, err - } - - return jwt, c.VerifyJWT(jwt) -} - -func (c *Client) VerifyJWT(jwt jose.JWT) error { - var keysFunc func() []key.PublicKey - if kID, ok := jwt.KeyID(); ok { - keysFunc = c.keysFuncWithID(kID) - } else { - keysFunc = c.keysFuncAll() - } - - v := NewJWTVerifier( - c.providerConfig.Get().Issuer.String(), - c.credentials.ID, - c.maybeSyncKeys, keysFunc) - - return v.Verify(jwt) -} - -// keysFuncWithID returns a function that retrieves at most unexpired -// public key from the Client that matches the provided ID -func (c *Client) keysFuncWithID(kID string) func() []key.PublicKey { - return func() []key.PublicKey { - c.keySetSyncMutex.RLock() - defer c.keySetSyncMutex.RUnlock() - - if c.keySet.ExpiresAt().Before(time.Now()) { - return []key.PublicKey{} - } - - k := c.keySet.Key(kID) - if k == nil { - return []key.PublicKey{} - } - - return []key.PublicKey{*k} - } -} - -// keysFuncAll returns a function that retrieves all unexpired public -// keys from the Client -func (c *Client) keysFuncAll() func() []key.PublicKey { - return func() []key.PublicKey { - c.keySetSyncMutex.RLock() - defer c.keySetSyncMutex.RUnlock() - - if c.keySet.ExpiresAt().Before(time.Now()) { - return []key.PublicKey{} - } - - return c.keySet.Keys() - } -} - -type providerConfigRepo struct { - mu sync.RWMutex - config ProviderConfig // do not access directly, use Get() -} - -func newProviderConfigRepo(pc ProviderConfig) *providerConfigRepo { - return &providerConfigRepo{sync.RWMutex{}, pc} -} - -// returns an error to implement ProviderConfigSetter -func (r *providerConfigRepo) Set(cfg ProviderConfig) error { - r.mu.Lock() - defer r.mu.Unlock() - r.config = cfg - return nil -} - -func (r *providerConfigRepo) Get() ProviderConfig { - r.mu.RLock() - defer r.mu.RUnlock() - return r.config -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/identity.go b/vendor/github.com/coreos/go-oidc/oidc/identity.go deleted file mode 100644 index 9bfa8e3439..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/identity.go +++ /dev/null @@ -1,44 +0,0 @@ -package oidc - -import ( - "errors" - "time" - - "github.com/coreos/go-oidc/jose" -) - -type Identity struct { - ID string - Name string - Email string - ExpiresAt time.Time -} - -func IdentityFromClaims(claims jose.Claims) (*Identity, error) { - if claims == nil { - return nil, errors.New("nil claim set") - } - - var ident Identity - var err error - var ok bool - - if ident.ID, ok, err = claims.StringClaim("sub"); err != nil { - return nil, err - } else if !ok { - return nil, errors.New("missing required claim: sub") - } - - if ident.Email, _, err = claims.StringClaim("email"); err != nil { - return nil, err - } - - exp, ok, err := claims.TimeClaim("exp") - if err != nil { - return nil, err - } else if ok { - ident.ExpiresAt = exp - } - - return &ident, nil -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/interface.go b/vendor/github.com/coreos/go-oidc/oidc/interface.go deleted file mode 100644 index 248cac0b4d..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/interface.go +++ /dev/null @@ -1,3 +0,0 @@ -package oidc - -type LoginFunc func(ident Identity, sessionKey string) (redirectURL string, err error) diff --git a/vendor/github.com/coreos/go-oidc/oidc/key.go b/vendor/github.com/coreos/go-oidc/oidc/key.go deleted file mode 100755 index 82a0f567d5..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/key.go +++ /dev/null @@ -1,67 +0,0 @@ -package oidc - -import ( - "encoding/json" - "errors" - "net/http" - "time" - - phttp "github.com/coreos/go-oidc/http" - "github.com/coreos/go-oidc/jose" - "github.com/coreos/go-oidc/key" -) - -// DefaultPublicKeySetTTL is the default TTL set on the PublicKeySet if no -// Cache-Control header is provided by the JWK Set document endpoint. -const DefaultPublicKeySetTTL = 24 * time.Hour - -// NewRemotePublicKeyRepo is responsible for fetching the JWK Set document. -func NewRemotePublicKeyRepo(hc phttp.Client, ep string) *remotePublicKeyRepo { - return &remotePublicKeyRepo{hc: hc, ep: ep} -} - -type remotePublicKeyRepo struct { - hc phttp.Client - ep string -} - -// Get returns a PublicKeySet fetched from the JWK Set document endpoint. A TTL -// is set on the Key Set to avoid it having to be re-retrieved for every -// encryption event. This TTL is typically controlled by the endpoint returning -// a Cache-Control header, but defaults to 24 hours if no Cache-Control header -// is found. -func (r *remotePublicKeyRepo) Get() (key.KeySet, error) { - req, err := http.NewRequest("GET", r.ep, nil) - if err != nil { - return nil, err - } - - resp, err := r.hc.Do(req) - if err != nil { - return nil, err - } - defer resp.Body.Close() - - var d struct { - Keys []jose.JWK `json:"keys"` - } - if err := json.NewDecoder(resp.Body).Decode(&d); err != nil { - return nil, err - } - - if len(d.Keys) == 0 { - return nil, errors.New("zero keys in response") - } - - ttl, ok, err := phttp.Cacheable(resp.Header) - if err != nil { - return nil, err - } - if !ok { - ttl = DefaultPublicKeySetTTL - } - - exp := time.Now().UTC().Add(ttl) - ks := key.NewPublicKeySet(d.Keys, exp) - return ks, nil -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/provider.go b/vendor/github.com/coreos/go-oidc/oidc/provider.go deleted file mode 100644 index ca2838440b..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/provider.go +++ /dev/null @@ -1,690 +0,0 @@ -package oidc - -import ( - "encoding/json" - "errors" - "fmt" - "log" - "net/http" - "net/url" - "strings" - "sync" - "time" - - "github.com/coreos/pkg/timeutil" - "github.com/jonboulle/clockwork" - - phttp "github.com/coreos/go-oidc/http" - "github.com/coreos/go-oidc/oauth2" -) - -const ( - // Subject Identifier types defined by the OIDC spec. Specifies if the provider - // should provide the same sub claim value to all clients (public) or a unique - // value for each client (pairwise). - // - // See: http://openid.net/specs/openid-connect-core-1_0.html#SubjectIDTypes - SubjectTypePublic = "public" - SubjectTypePairwise = "pairwise" -) - -var ( - // Default values for omitted provider config fields. - // - // Use ProviderConfig's Defaults method to fill a provider config with these values. - DefaultGrantTypesSupported = []string{oauth2.GrantTypeAuthCode, oauth2.GrantTypeImplicit} - DefaultResponseModesSupported = []string{"query", "fragment"} - DefaultTokenEndpointAuthMethodsSupported = []string{oauth2.AuthMethodClientSecretBasic} - DefaultClaimTypesSupported = []string{"normal"} -) - -const ( - MaximumProviderConfigSyncInterval = 24 * time.Hour - MinimumProviderConfigSyncInterval = time.Minute - - discoveryConfigPath = "/.well-known/openid-configuration" -) - -// internally configurable for tests -var minimumProviderConfigSyncInterval = MinimumProviderConfigSyncInterval - -var ( - // Ensure ProviderConfig satisfies these interfaces. - _ json.Marshaler = &ProviderConfig{} - _ json.Unmarshaler = &ProviderConfig{} -) - -// ProviderConfig represents the OpenID Provider Metadata specifying what -// configurations a provider supports. -// -// See: http://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata -type ProviderConfig struct { - Issuer *url.URL // Required - AuthEndpoint *url.URL // Required - TokenEndpoint *url.URL // Required if grant types other than "implicit" are supported - UserInfoEndpoint *url.URL - KeysEndpoint *url.URL // Required - RegistrationEndpoint *url.URL - EndSessionEndpoint *url.URL - CheckSessionIFrame *url.URL - - // Servers MAY choose not to advertise some supported scope values even when this - // parameter is used, although those defined in OpenID Core SHOULD be listed, if supported. - ScopesSupported []string - // OAuth2.0 response types supported. - ResponseTypesSupported []string // Required - // OAuth2.0 response modes supported. - // - // If omitted, defaults to DefaultResponseModesSupported. - ResponseModesSupported []string - // OAuth2.0 grant types supported. - // - // If omitted, defaults to DefaultGrantTypesSupported. - GrantTypesSupported []string - ACRValuesSupported []string - // SubjectTypesSupported specifies strategies for providing values for the sub claim. - SubjectTypesSupported []string // Required - - // JWA signing and encryption algorith values supported for ID tokens. - IDTokenSigningAlgValues []string // Required - IDTokenEncryptionAlgValues []string - IDTokenEncryptionEncValues []string - - // JWA signing and encryption algorith values supported for user info responses. - UserInfoSigningAlgValues []string - UserInfoEncryptionAlgValues []string - UserInfoEncryptionEncValues []string - - // JWA signing and encryption algorith values supported for request objects. - ReqObjSigningAlgValues []string - ReqObjEncryptionAlgValues []string - ReqObjEncryptionEncValues []string - - TokenEndpointAuthMethodsSupported []string - TokenEndpointAuthSigningAlgValuesSupported []string - DisplayValuesSupported []string - ClaimTypesSupported []string - ClaimsSupported []string - ServiceDocs *url.URL - ClaimsLocalsSupported []string - UILocalsSupported []string - ClaimsParameterSupported bool - RequestParameterSupported bool - RequestURIParamaterSupported bool - RequireRequestURIRegistration bool - - Policy *url.URL - TermsOfService *url.URL - - // Not part of the OpenID Provider Metadata - ExpiresAt time.Time -} - -// Defaults returns a shallow copy of ProviderConfig with default -// values replacing omitted fields. -// -// var cfg oidc.ProviderConfig -// // Fill provider config with default values for omitted fields. -// cfg = cfg.Defaults() -// -func (p ProviderConfig) Defaults() ProviderConfig { - setDefault := func(val *[]string, defaultVal []string) { - if len(*val) == 0 { - *val = defaultVal - } - } - setDefault(&p.GrantTypesSupported, DefaultGrantTypesSupported) - setDefault(&p.ResponseModesSupported, DefaultResponseModesSupported) - setDefault(&p.TokenEndpointAuthMethodsSupported, DefaultTokenEndpointAuthMethodsSupported) - setDefault(&p.ClaimTypesSupported, DefaultClaimTypesSupported) - return p -} - -func (p *ProviderConfig) MarshalJSON() ([]byte, error) { - e := p.toEncodableStruct() - return json.Marshal(&e) -} - -func (p *ProviderConfig) UnmarshalJSON(data []byte) error { - var e encodableProviderConfig - if err := json.Unmarshal(data, &e); err != nil { - return err - } - conf, err := e.toStruct() - if err != nil { - return err - } - if err := conf.Valid(); err != nil { - return err - } - *p = conf - return nil -} - -type encodableProviderConfig struct { - Issuer string `json:"issuer"` - AuthEndpoint string `json:"authorization_endpoint"` - TokenEndpoint string `json:"token_endpoint"` - UserInfoEndpoint string `json:"userinfo_endpoint,omitempty"` - KeysEndpoint string `json:"jwks_uri"` - RegistrationEndpoint string `json:"registration_endpoint,omitempty"` - EndSessionEndpoint string `json:"end_session_endpoint,omitempty"` - CheckSessionIFrame string `json:"check_session_iframe,omitempty"` - - // Use 'omitempty' for all slices as per OIDC spec: - // "Claims that return multiple values are represented as JSON arrays. - // Claims with zero elements MUST be omitted from the response." - // http://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationResponse - - ScopesSupported []string `json:"scopes_supported,omitempty"` - ResponseTypesSupported []string `json:"response_types_supported,omitempty"` - ResponseModesSupported []string `json:"response_modes_supported,omitempty"` - GrantTypesSupported []string `json:"grant_types_supported,omitempty"` - ACRValuesSupported []string `json:"acr_values_supported,omitempty"` - SubjectTypesSupported []string `json:"subject_types_supported,omitempty"` - - IDTokenSigningAlgValues []string `json:"id_token_signing_alg_values_supported,omitempty"` - IDTokenEncryptionAlgValues []string `json:"id_token_encryption_alg_values_supported,omitempty"` - IDTokenEncryptionEncValues []string `json:"id_token_encryption_enc_values_supported,omitempty"` - UserInfoSigningAlgValues []string `json:"userinfo_signing_alg_values_supported,omitempty"` - UserInfoEncryptionAlgValues []string `json:"userinfo_encryption_alg_values_supported,omitempty"` - UserInfoEncryptionEncValues []string `json:"userinfo_encryption_enc_values_supported,omitempty"` - ReqObjSigningAlgValues []string `json:"request_object_signing_alg_values_supported,omitempty"` - ReqObjEncryptionAlgValues []string `json:"request_object_encryption_alg_values_supported,omitempty"` - ReqObjEncryptionEncValues []string `json:"request_object_encryption_enc_values_supported,omitempty"` - - TokenEndpointAuthMethodsSupported []string `json:"token_endpoint_auth_methods_supported,omitempty"` - TokenEndpointAuthSigningAlgValuesSupported []string `json:"token_endpoint_auth_signing_alg_values_supported,omitempty"` - - DisplayValuesSupported []string `json:"display_values_supported,omitempty"` - ClaimTypesSupported []string `json:"claim_types_supported,omitempty"` - ClaimsSupported []string `json:"claims_supported,omitempty"` - ServiceDocs string `json:"service_documentation,omitempty"` - ClaimsLocalsSupported []string `json:"claims_locales_supported,omitempty"` - UILocalsSupported []string `json:"ui_locales_supported,omitempty"` - ClaimsParameterSupported bool `json:"claims_parameter_supported,omitempty"` - RequestParameterSupported bool `json:"request_parameter_supported,omitempty"` - RequestURIParamaterSupported bool `json:"request_uri_parameter_supported,omitempty"` - RequireRequestURIRegistration bool `json:"require_request_uri_registration,omitempty"` - - Policy string `json:"op_policy_uri,omitempty"` - TermsOfService string `json:"op_tos_uri,omitempty"` -} - -func (cfg ProviderConfig) toEncodableStruct() encodableProviderConfig { - return encodableProviderConfig{ - Issuer: uriToString(cfg.Issuer), - AuthEndpoint: uriToString(cfg.AuthEndpoint), - TokenEndpoint: uriToString(cfg.TokenEndpoint), - UserInfoEndpoint: uriToString(cfg.UserInfoEndpoint), - KeysEndpoint: uriToString(cfg.KeysEndpoint), - RegistrationEndpoint: uriToString(cfg.RegistrationEndpoint), - EndSessionEndpoint: uriToString(cfg.EndSessionEndpoint), - CheckSessionIFrame: uriToString(cfg.CheckSessionIFrame), - ScopesSupported: cfg.ScopesSupported, - ResponseTypesSupported: cfg.ResponseTypesSupported, - ResponseModesSupported: cfg.ResponseModesSupported, - GrantTypesSupported: cfg.GrantTypesSupported, - ACRValuesSupported: cfg.ACRValuesSupported, - SubjectTypesSupported: cfg.SubjectTypesSupported, - IDTokenSigningAlgValues: cfg.IDTokenSigningAlgValues, - IDTokenEncryptionAlgValues: cfg.IDTokenEncryptionAlgValues, - IDTokenEncryptionEncValues: cfg.IDTokenEncryptionEncValues, - UserInfoSigningAlgValues: cfg.UserInfoSigningAlgValues, - UserInfoEncryptionAlgValues: cfg.UserInfoEncryptionAlgValues, - UserInfoEncryptionEncValues: cfg.UserInfoEncryptionEncValues, - ReqObjSigningAlgValues: cfg.ReqObjSigningAlgValues, - ReqObjEncryptionAlgValues: cfg.ReqObjEncryptionAlgValues, - ReqObjEncryptionEncValues: cfg.ReqObjEncryptionEncValues, - TokenEndpointAuthMethodsSupported: cfg.TokenEndpointAuthMethodsSupported, - TokenEndpointAuthSigningAlgValuesSupported: cfg.TokenEndpointAuthSigningAlgValuesSupported, - DisplayValuesSupported: cfg.DisplayValuesSupported, - ClaimTypesSupported: cfg.ClaimTypesSupported, - ClaimsSupported: cfg.ClaimsSupported, - ServiceDocs: uriToString(cfg.ServiceDocs), - ClaimsLocalsSupported: cfg.ClaimsLocalsSupported, - UILocalsSupported: cfg.UILocalsSupported, - ClaimsParameterSupported: cfg.ClaimsParameterSupported, - RequestParameterSupported: cfg.RequestParameterSupported, - RequestURIParamaterSupported: cfg.RequestURIParamaterSupported, - RequireRequestURIRegistration: cfg.RequireRequestURIRegistration, - Policy: uriToString(cfg.Policy), - TermsOfService: uriToString(cfg.TermsOfService), - } -} - -func (e encodableProviderConfig) toStruct() (ProviderConfig, error) { - p := stickyErrParser{} - conf := ProviderConfig{ - Issuer: p.parseURI(e.Issuer, "issuer"), - AuthEndpoint: p.parseURI(e.AuthEndpoint, "authorization_endpoint"), - TokenEndpoint: p.parseURI(e.TokenEndpoint, "token_endpoint"), - UserInfoEndpoint: p.parseURI(e.UserInfoEndpoint, "userinfo_endpoint"), - KeysEndpoint: p.parseURI(e.KeysEndpoint, "jwks_uri"), - RegistrationEndpoint: p.parseURI(e.RegistrationEndpoint, "registration_endpoint"), - EndSessionEndpoint: p.parseURI(e.EndSessionEndpoint, "end_session_endpoint"), - CheckSessionIFrame: p.parseURI(e.CheckSessionIFrame, "check_session_iframe"), - ScopesSupported: e.ScopesSupported, - ResponseTypesSupported: e.ResponseTypesSupported, - ResponseModesSupported: e.ResponseModesSupported, - GrantTypesSupported: e.GrantTypesSupported, - ACRValuesSupported: e.ACRValuesSupported, - SubjectTypesSupported: e.SubjectTypesSupported, - IDTokenSigningAlgValues: e.IDTokenSigningAlgValues, - IDTokenEncryptionAlgValues: e.IDTokenEncryptionAlgValues, - IDTokenEncryptionEncValues: e.IDTokenEncryptionEncValues, - UserInfoSigningAlgValues: e.UserInfoSigningAlgValues, - UserInfoEncryptionAlgValues: e.UserInfoEncryptionAlgValues, - UserInfoEncryptionEncValues: e.UserInfoEncryptionEncValues, - ReqObjSigningAlgValues: e.ReqObjSigningAlgValues, - ReqObjEncryptionAlgValues: e.ReqObjEncryptionAlgValues, - ReqObjEncryptionEncValues: e.ReqObjEncryptionEncValues, - TokenEndpointAuthMethodsSupported: e.TokenEndpointAuthMethodsSupported, - TokenEndpointAuthSigningAlgValuesSupported: e.TokenEndpointAuthSigningAlgValuesSupported, - DisplayValuesSupported: e.DisplayValuesSupported, - ClaimTypesSupported: e.ClaimTypesSupported, - ClaimsSupported: e.ClaimsSupported, - ServiceDocs: p.parseURI(e.ServiceDocs, "service_documentation"), - ClaimsLocalsSupported: e.ClaimsLocalsSupported, - UILocalsSupported: e.UILocalsSupported, - ClaimsParameterSupported: e.ClaimsParameterSupported, - RequestParameterSupported: e.RequestParameterSupported, - RequestURIParamaterSupported: e.RequestURIParamaterSupported, - RequireRequestURIRegistration: e.RequireRequestURIRegistration, - Policy: p.parseURI(e.Policy, "op_policy-uri"), - TermsOfService: p.parseURI(e.TermsOfService, "op_tos_uri"), - } - if p.firstErr != nil { - return ProviderConfig{}, p.firstErr - } - return conf, nil -} - -// Empty returns if a ProviderConfig holds no information. -// -// This case generally indicates a ProviderConfigGetter has experienced an error -// and has nothing to report. -func (p ProviderConfig) Empty() bool { - return p.Issuer == nil -} - -func contains(sli []string, ele string) bool { - for _, s := range sli { - if s == ele { - return true - } - } - return false -} - -// Valid determines if a ProviderConfig conforms with the OIDC specification. -// If Valid returns successfully it guarantees required field are non-nil and -// URLs are well formed. -// -// Valid is called by UnmarshalJSON. -// -// NOTE(ericchiang): For development purposes Valid does not mandate 'https' for -// URLs fields where the OIDC spec requires it. This may change in future releases -// of this package. See: https://github.com/coreos/go-oidc/issues/34 -func (p ProviderConfig) Valid() error { - grantTypes := p.GrantTypesSupported - if len(grantTypes) == 0 { - grantTypes = DefaultGrantTypesSupported - } - implicitOnly := true - for _, grantType := range grantTypes { - if grantType != oauth2.GrantTypeImplicit { - implicitOnly = false - break - } - } - - if len(p.SubjectTypesSupported) == 0 { - return errors.New("missing required field subject_types_supported") - } - if len(p.IDTokenSigningAlgValues) == 0 { - return errors.New("missing required field id_token_signing_alg_values_supported") - } - - if len(p.ScopesSupported) != 0 && !contains(p.ScopesSupported, "openid") { - return errors.New("scoped_supported must be unspecified or include 'openid'") - } - - if !contains(p.IDTokenSigningAlgValues, "RS256") { - return errors.New("id_token_signing_alg_values_supported must include 'RS256'") - } - if contains(p.TokenEndpointAuthMethodsSupported, "none") { - return errors.New("token_endpoint_auth_signing_alg_values_supported cannot include 'none'") - } - - uris := []struct { - val *url.URL - name string - required bool - }{ - {p.Issuer, "issuer", true}, - {p.AuthEndpoint, "authorization_endpoint", true}, - {p.TokenEndpoint, "token_endpoint", !implicitOnly}, - {p.UserInfoEndpoint, "userinfo_endpoint", false}, - {p.KeysEndpoint, "jwks_uri", true}, - {p.RegistrationEndpoint, "registration_endpoint", false}, - {p.EndSessionEndpoint, "end_session_endpoint", false}, - {p.CheckSessionIFrame, "check_session_iframe", false}, - {p.ServiceDocs, "service_documentation", false}, - {p.Policy, "op_policy_uri", false}, - {p.TermsOfService, "op_tos_uri", false}, - } - - for _, uri := range uris { - if uri.val == nil { - if !uri.required { - continue - } - return fmt.Errorf("empty value for required uri field %s", uri.name) - } - if uri.val.Host == "" { - return fmt.Errorf("no host for uri field %s", uri.name) - } - if uri.val.Scheme != "http" && uri.val.Scheme != "https" { - return fmt.Errorf("uri field %s schemeis not http or https", uri.name) - } - } - return nil -} - -// Supports determines if provider supports a client given their respective metadata. -func (p ProviderConfig) Supports(c ClientMetadata) error { - if err := p.Valid(); err != nil { - return fmt.Errorf("invalid provider config: %v", err) - } - if err := c.Valid(); err != nil { - return fmt.Errorf("invalid client config: %v", err) - } - - // Fill default values for omitted fields - c = c.Defaults() - p = p.Defaults() - - // Do the supported values list the requested one? - supports := []struct { - supported []string - requested string - name string - }{ - {p.IDTokenSigningAlgValues, c.IDTokenResponseOptions.SigningAlg, "id_token_signed_response_alg"}, - {p.IDTokenEncryptionAlgValues, c.IDTokenResponseOptions.EncryptionAlg, "id_token_encryption_response_alg"}, - {p.IDTokenEncryptionEncValues, c.IDTokenResponseOptions.EncryptionEnc, "id_token_encryption_response_enc"}, - {p.UserInfoSigningAlgValues, c.UserInfoResponseOptions.SigningAlg, "userinfo_signed_response_alg"}, - {p.UserInfoEncryptionAlgValues, c.UserInfoResponseOptions.EncryptionAlg, "userinfo_encryption_response_alg"}, - {p.UserInfoEncryptionEncValues, c.UserInfoResponseOptions.EncryptionEnc, "userinfo_encryption_response_enc"}, - {p.ReqObjSigningAlgValues, c.RequestObjectOptions.SigningAlg, "request_object_signing_alg"}, - {p.ReqObjEncryptionAlgValues, c.RequestObjectOptions.EncryptionAlg, "request_object_encryption_alg"}, - {p.ReqObjEncryptionEncValues, c.RequestObjectOptions.EncryptionEnc, "request_object_encryption_enc"}, - } - for _, field := range supports { - if field.requested == "" { - continue - } - if !contains(field.supported, field.requested) { - return fmt.Errorf("provider does not support requested value for field %s", field.name) - } - } - - stringsEqual := func(s1, s2 string) bool { return s1 == s2 } - - // For lists, are the list of requested values a subset of the supported ones? - supportsAll := []struct { - supported []string - requested []string - name string - // OAuth2.0 response_type can be space separated lists where order doesn't matter. - // For example "id_token token" is the same as "token id_token" - // Support a custom compare method. - comp func(s1, s2 string) bool - }{ - {p.GrantTypesSupported, c.GrantTypes, "grant_types", stringsEqual}, - {p.ResponseTypesSupported, c.ResponseTypes, "response_type", oauth2.ResponseTypesEqual}, - } - for _, field := range supportsAll { - requestLoop: - for _, req := range field.requested { - for _, sup := range field.supported { - if field.comp(req, sup) { - continue requestLoop - } - } - return fmt.Errorf("provider does not support requested value for field %s", field.name) - } - } - - // TODO(ericchiang): Are there more checks we feel comfortable with begin strict about? - - return nil -} - -func (p ProviderConfig) SupportsGrantType(grantType string) bool { - var supported []string - if len(p.GrantTypesSupported) == 0 { - supported = DefaultGrantTypesSupported - } else { - supported = p.GrantTypesSupported - } - - for _, t := range supported { - if t == grantType { - return true - } - } - return false -} - -type ProviderConfigGetter interface { - Get() (ProviderConfig, error) -} - -type ProviderConfigSetter interface { - Set(ProviderConfig) error -} - -type ProviderConfigSyncer struct { - from ProviderConfigGetter - to ProviderConfigSetter - clock clockwork.Clock - - initialSyncDone bool - initialSyncWait sync.WaitGroup -} - -func NewProviderConfigSyncer(from ProviderConfigGetter, to ProviderConfigSetter) *ProviderConfigSyncer { - return &ProviderConfigSyncer{ - from: from, - to: to, - clock: clockwork.NewRealClock(), - } -} - -func (s *ProviderConfigSyncer) Run() chan struct{} { - stop := make(chan struct{}) - - var next pcsStepper - next = &pcsStepNext{aft: time.Duration(0)} - - s.initialSyncWait.Add(1) - go func() { - for { - select { - case <-s.clock.After(next.after()): - next = next.step(s.sync) - case <-stop: - return - } - } - }() - - return stop -} - -func (s *ProviderConfigSyncer) WaitUntilInitialSync() { - s.initialSyncWait.Wait() -} - -func (s *ProviderConfigSyncer) sync() (time.Duration, error) { - cfg, err := s.from.Get() - if err != nil { - return 0, err - } - - if err = s.to.Set(cfg); err != nil { - return 0, fmt.Errorf("error setting provider config: %v", err) - } - - if !s.initialSyncDone { - s.initialSyncWait.Done() - s.initialSyncDone = true - } - - return nextSyncAfter(cfg.ExpiresAt, s.clock), nil -} - -type pcsStepFunc func() (time.Duration, error) - -type pcsStepper interface { - after() time.Duration - step(pcsStepFunc) pcsStepper -} - -type pcsStepNext struct { - aft time.Duration -} - -func (n *pcsStepNext) after() time.Duration { - return n.aft -} - -func (n *pcsStepNext) step(fn pcsStepFunc) (next pcsStepper) { - ttl, err := fn() - if err == nil { - next = &pcsStepNext{aft: ttl} - } else { - next = &pcsStepRetry{aft: time.Second} - log.Printf("go-oidc: provider config sync falied, retyring in %v: %v", next.after(), err) - } - return -} - -type pcsStepRetry struct { - aft time.Duration -} - -func (r *pcsStepRetry) after() time.Duration { - return r.aft -} - -func (r *pcsStepRetry) step(fn pcsStepFunc) (next pcsStepper) { - ttl, err := fn() - if err == nil { - next = &pcsStepNext{aft: ttl} - } else { - next = &pcsStepRetry{aft: timeutil.ExpBackoff(r.aft, time.Minute)} - log.Printf("go-oidc: provider config sync falied, retyring in %v: %v", next.after(), err) - } - return -} - -func nextSyncAfter(exp time.Time, clock clockwork.Clock) time.Duration { - if exp.IsZero() { - return MaximumProviderConfigSyncInterval - } - - t := exp.Sub(clock.Now()) / 2 - if t > MaximumProviderConfigSyncInterval { - t = MaximumProviderConfigSyncInterval - } else if t < minimumProviderConfigSyncInterval { - t = minimumProviderConfigSyncInterval - } - - return t -} - -type httpProviderConfigGetter struct { - hc phttp.Client - issuerURL string - clock clockwork.Clock -} - -func NewHTTPProviderConfigGetter(hc phttp.Client, issuerURL string) *httpProviderConfigGetter { - return &httpProviderConfigGetter{ - hc: hc, - issuerURL: issuerURL, - clock: clockwork.NewRealClock(), - } -} - -func (r *httpProviderConfigGetter) Get() (cfg ProviderConfig, err error) { - // If the Issuer value contains a path component, any terminating / MUST be removed before - // appending /.well-known/openid-configuration. - // https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationRequest - discoveryURL := strings.TrimSuffix(r.issuerURL, "/") + discoveryConfigPath - req, err := http.NewRequest("GET", discoveryURL, nil) - if err != nil { - return - } - - resp, err := r.hc.Do(req) - if err != nil { - return - } - defer resp.Body.Close() - - if err = json.NewDecoder(resp.Body).Decode(&cfg); err != nil { - return - } - - var ttl time.Duration - var ok bool - ttl, ok, err = phttp.Cacheable(resp.Header) - if err != nil { - return - } else if ok { - cfg.ExpiresAt = r.clock.Now().UTC().Add(ttl) - } - - // The issuer value returned MUST be identical to the Issuer URL that was directly used to retrieve the configuration information. - // http://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationValidation - if !urlEqual(cfg.Issuer.String(), r.issuerURL) { - err = fmt.Errorf(`"issuer" in config (%v) does not match provided issuer URL (%v)`, cfg.Issuer, r.issuerURL) - return - } - - return -} - -func FetchProviderConfig(hc phttp.Client, issuerURL string) (ProviderConfig, error) { - if hc == nil { - hc = http.DefaultClient - } - - g := NewHTTPProviderConfigGetter(hc, issuerURL) - return g.Get() -} - -func WaitForProviderConfig(hc phttp.Client, issuerURL string) (pcfg ProviderConfig) { - return waitForProviderConfig(hc, issuerURL, clockwork.NewRealClock()) -} - -func waitForProviderConfig(hc phttp.Client, issuerURL string, clock clockwork.Clock) (pcfg ProviderConfig) { - var sleep time.Duration - var err error - for { - pcfg, err = FetchProviderConfig(hc, issuerURL) - if err == nil { - break - } - - sleep = timeutil.ExpBackoff(sleep, time.Minute) - fmt.Printf("Failed fetching provider config, trying again in %v: %v\n", sleep, err) - time.Sleep(sleep) - } - - return -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/transport.go b/vendor/github.com/coreos/go-oidc/oidc/transport.go deleted file mode 100644 index 61c926d7fe..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/transport.go +++ /dev/null @@ -1,88 +0,0 @@ -package oidc - -import ( - "fmt" - "net/http" - "sync" - - phttp "github.com/coreos/go-oidc/http" - "github.com/coreos/go-oidc/jose" -) - -type TokenRefresher interface { - // Verify checks if the provided token is currently valid or not. - Verify(jose.JWT) error - - // Refresh attempts to authenticate and retrieve a new token. - Refresh() (jose.JWT, error) -} - -type ClientCredsTokenRefresher struct { - Issuer string - OIDCClient *Client -} - -func (c *ClientCredsTokenRefresher) Verify(jwt jose.JWT) (err error) { - _, err = VerifyClientClaims(jwt, c.Issuer) - return -} - -func (c *ClientCredsTokenRefresher) Refresh() (jwt jose.JWT, err error) { - if err = c.OIDCClient.Healthy(); err != nil { - err = fmt.Errorf("unable to authenticate, unhealthy OIDC client: %v", err) - return - } - - jwt, err = c.OIDCClient.ClientCredsToken([]string{"openid"}) - if err != nil { - err = fmt.Errorf("unable to verify auth code with issuer: %v", err) - return - } - - return -} - -type AuthenticatedTransport struct { - TokenRefresher - http.RoundTripper - - mu sync.Mutex - jwt jose.JWT -} - -func (t *AuthenticatedTransport) verifiedJWT() (jose.JWT, error) { - t.mu.Lock() - defer t.mu.Unlock() - - if t.TokenRefresher.Verify(t.jwt) == nil { - return t.jwt, nil - } - - jwt, err := t.TokenRefresher.Refresh() - if err != nil { - return jose.JWT{}, fmt.Errorf("unable to acquire valid JWT: %v", err) - } - - t.jwt = jwt - return t.jwt, nil -} - -// SetJWT sets the JWT held by the Transport. -// This is useful for cases in which you want to set an initial JWT. -func (t *AuthenticatedTransport) SetJWT(jwt jose.JWT) { - t.mu.Lock() - defer t.mu.Unlock() - - t.jwt = jwt -} - -func (t *AuthenticatedTransport) RoundTrip(r *http.Request) (*http.Response, error) { - jwt, err := t.verifiedJWT() - if err != nil { - return nil, err - } - - req := phttp.CopyRequest(r) - req.Header.Set("Authorization", fmt.Sprintf("Bearer %s", jwt.Encode())) - return t.RoundTripper.RoundTrip(req) -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/util.go b/vendor/github.com/coreos/go-oidc/oidc/util.go deleted file mode 100644 index f2a5a195e4..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/util.go +++ /dev/null @@ -1,109 +0,0 @@ -package oidc - -import ( - "crypto/rand" - "encoding/base64" - "errors" - "fmt" - "net" - "net/http" - "net/url" - "strings" - "time" - - "github.com/coreos/go-oidc/jose" -) - -// RequestTokenExtractor funcs extract a raw encoded token from a request. -type RequestTokenExtractor func(r *http.Request) (string, error) - -// ExtractBearerToken is a RequestTokenExtractor which extracts a bearer token from a request's -// Authorization header. -func ExtractBearerToken(r *http.Request) (string, error) { - ah := r.Header.Get("Authorization") - if ah == "" { - return "", errors.New("missing Authorization header") - } - - if len(ah) <= 6 || strings.ToUpper(ah[0:6]) != "BEARER" { - return "", errors.New("should be a bearer token") - } - - val := ah[7:] - if len(val) == 0 { - return "", errors.New("bearer token is empty") - } - - return val, nil -} - -// CookieTokenExtractor returns a RequestTokenExtractor which extracts a token from the named cookie in a request. -func CookieTokenExtractor(cookieName string) RequestTokenExtractor { - return func(r *http.Request) (string, error) { - ck, err := r.Cookie(cookieName) - if err != nil { - return "", fmt.Errorf("token cookie not found in request: %v", err) - } - - if ck.Value == "" { - return "", errors.New("token cookie found but is empty") - } - - return ck.Value, nil - } -} - -func NewClaims(iss, sub string, aud interface{}, iat, exp time.Time) jose.Claims { - return jose.Claims{ - // required - "iss": iss, - "sub": sub, - "aud": aud, - "iat": iat.Unix(), - "exp": exp.Unix(), - } -} - -func GenClientID(hostport string) (string, error) { - b, err := randBytes(32) - if err != nil { - return "", err - } - - var host string - if strings.Contains(hostport, ":") { - host, _, err = net.SplitHostPort(hostport) - if err != nil { - return "", err - } - } else { - host = hostport - } - - return fmt.Sprintf("%s@%s", base64.URLEncoding.EncodeToString(b), host), nil -} - -func randBytes(n int) ([]byte, error) { - b := make([]byte, n) - got, err := rand.Read(b) - if err != nil { - return nil, err - } else if n != got { - return nil, errors.New("unable to generate enough random data") - } - return b, nil -} - -// urlEqual checks two urls for equality using only the host and path portions. -func urlEqual(url1, url2 string) bool { - u1, err := url.Parse(url1) - if err != nil { - return false - } - u2, err := url.Parse(url2) - if err != nil { - return false - } - - return strings.ToLower(u1.Host+u1.Path) == strings.ToLower(u2.Host+u2.Path) -} diff --git a/vendor/github.com/coreos/go-oidc/oidc/verification.go b/vendor/github.com/coreos/go-oidc/oidc/verification.go deleted file mode 100644 index d9c6afa697..0000000000 --- a/vendor/github.com/coreos/go-oidc/oidc/verification.go +++ /dev/null @@ -1,190 +0,0 @@ -package oidc - -import ( - "errors" - "fmt" - "time" - - "github.com/jonboulle/clockwork" - - "github.com/coreos/go-oidc/jose" - "github.com/coreos/go-oidc/key" -) - -func VerifySignature(jwt jose.JWT, keys []key.PublicKey) (bool, error) { - jwtBytes := []byte(jwt.Data()) - for _, k := range keys { - v, err := k.Verifier() - if err != nil { - return false, err - } - if v.Verify(jwt.Signature, jwtBytes) == nil { - return true, nil - } - } - return false, nil -} - -// containsString returns true if the given string(needle) is found -// in the string array(haystack). -func containsString(needle string, haystack []string) bool { - for _, v := range haystack { - if v == needle { - return true - } - } - return false -} - -// Verify claims in accordance with OIDC spec -// http://openid.net/specs/openid-connect-basic-1_0.html#IDTokenValidation -func VerifyClaims(jwt jose.JWT, issuer, clientID string) error { - now := time.Now().UTC() - - claims, err := jwt.Claims() - if err != nil { - return err - } - - ident, err := IdentityFromClaims(claims) - if err != nil { - return err - } - - if ident.ExpiresAt.Before(now) { - return errors.New("token is expired") - } - - // iss REQUIRED. Issuer Identifier for the Issuer of the response. - // The iss value is a case sensitive URL using the https scheme that contains scheme, - // host, and optionally, port number and path components and no query or fragment components. - if iss, exists := claims["iss"].(string); exists { - if !urlEqual(iss, issuer) { - return fmt.Errorf("invalid claim value: 'iss'. expected=%s, found=%s.", issuer, iss) - } - } else { - return errors.New("missing claim: 'iss'") - } - - // iat REQUIRED. Time at which the JWT was issued. - // Its value is a JSON number representing the number of seconds from 1970-01-01T0:0:0Z - // as measured in UTC until the date/time. - if _, exists := claims["iat"].(float64); !exists { - return errors.New("missing claim: 'iat'") - } - - // aud REQUIRED. Audience(s) that this ID Token is intended for. - // It MUST contain the OAuth 2.0 client_id of the Relying Party as an audience value. - // It MAY also contain identifiers for other audiences. In the general case, the aud - // value is an array of case sensitive strings. In the common special case when there - // is one audience, the aud value MAY be a single case sensitive string. - if aud, ok, err := claims.StringClaim("aud"); err == nil && ok { - if aud != clientID { - return fmt.Errorf("invalid claims, 'aud' claim and 'client_id' do not match, aud=%s, client_id=%s", aud, clientID) - } - } else if aud, ok, err := claims.StringsClaim("aud"); err == nil && ok { - if !containsString(clientID, aud) { - return fmt.Errorf("invalid claims, cannot find 'client_id' in 'aud' claim, aud=%v, client_id=%s", aud, clientID) - } - } else { - return errors.New("invalid claim value: 'aud' is required, and should be either string or string array") - } - - return nil -} - -// VerifyClientClaims verifies all the required claims are valid for a "client credentials" JWT. -// Returns the client ID if valid, or an error if invalid. -func VerifyClientClaims(jwt jose.JWT, issuer string) (string, error) { - claims, err := jwt.Claims() - if err != nil { - return "", fmt.Errorf("failed to parse JWT claims: %v", err) - } - - iss, ok, err := claims.StringClaim("iss") - if err != nil { - return "", fmt.Errorf("failed to parse 'iss' claim: %v", err) - } else if !ok { - return "", errors.New("missing required 'iss' claim") - } else if !urlEqual(iss, issuer) { - return "", fmt.Errorf("'iss' claim does not match expected issuer, iss=%s", iss) - } - - sub, ok, err := claims.StringClaim("sub") - if err != nil { - return "", fmt.Errorf("failed to parse 'sub' claim: %v", err) - } else if !ok { - return "", errors.New("missing required 'sub' claim") - } - - if aud, ok, err := claims.StringClaim("aud"); err == nil && ok { - if aud != sub { - return "", fmt.Errorf("invalid claims, 'aud' claim and 'sub' claim do not match, aud=%s, sub=%s", aud, sub) - } - } else if aud, ok, err := claims.StringsClaim("aud"); err == nil && ok { - if !containsString(sub, aud) { - return "", fmt.Errorf("invalid claims, cannot find 'sud' in 'aud' claim, aud=%v, sub=%s", aud, sub) - } - } else { - return "", errors.New("invalid claim value: 'aud' is required, and should be either string or string array") - } - - now := time.Now().UTC() - exp, ok, err := claims.TimeClaim("exp") - if err != nil { - return "", fmt.Errorf("failed to parse 'exp' claim: %v", err) - } else if !ok { - return "", errors.New("missing required 'exp' claim") - } else if exp.Before(now) { - return "", fmt.Errorf("token already expired at: %v", exp) - } - - return sub, nil -} - -type JWTVerifier struct { - issuer string - clientID string - syncFunc func() error - keysFunc func() []key.PublicKey - clock clockwork.Clock -} - -func NewJWTVerifier(issuer, clientID string, syncFunc func() error, keysFunc func() []key.PublicKey) JWTVerifier { - return JWTVerifier{ - issuer: issuer, - clientID: clientID, - syncFunc: syncFunc, - keysFunc: keysFunc, - clock: clockwork.NewRealClock(), - } -} - -func (v *JWTVerifier) Verify(jwt jose.JWT) error { - // Verify claims before verifying the signature. This is an optimization to throw out - // tokens we know are invalid without undergoing an expensive signature check and - // possibly a re-sync event. - if err := VerifyClaims(jwt, v.issuer, v.clientID); err != nil { - return fmt.Errorf("oidc: JWT claims invalid: %v", err) - } - - ok, err := VerifySignature(jwt, v.keysFunc()) - if err != nil { - return fmt.Errorf("oidc: JWT signature verification failed: %v", err) - } else if ok { - return nil - } - - if err = v.syncFunc(); err != nil { - return fmt.Errorf("oidc: failed syncing KeySet: %v", err) - } - - ok, err = VerifySignature(jwt, v.keysFunc()) - if err != nil { - return fmt.Errorf("oidc: JWT signature verification failed: %v", err) - } else if !ok { - return errors.New("oidc: unable to verify JWT signature: no matching keys") - } - - return nil -} diff --git a/vendor/github.com/coreos/pkg/NOTICE b/vendor/github.com/coreos/pkg/NOTICE deleted file mode 100644 index b39ddfa5cb..0000000000 --- a/vendor/github.com/coreos/pkg/NOTICE +++ /dev/null @@ -1,5 +0,0 @@ -CoreOS Project -Copyright 2014 CoreOS, Inc - -This product includes software developed at CoreOS, Inc. -(http://www.coreos.com/). diff --git a/vendor/github.com/coreos/pkg/health/README.md b/vendor/github.com/coreos/pkg/health/README.md deleted file mode 100644 index 5ec34c21e0..0000000000 --- a/vendor/github.com/coreos/pkg/health/README.md +++ /dev/null @@ -1,11 +0,0 @@ -health -==== - -A simple framework for implementing an HTTP health check endpoint on servers. - -Users implement their `health.Checkable` types, and create a `health.Checker`, from which they can get an `http.HandlerFunc` using `health.Checker.MakeHealthHandlerFunc`. - -### Documentation - -For more details, visit the docs on [gopkgdoc](http://godoc.org/github.com/coreos/pkg/health) - diff --git a/vendor/github.com/coreos/pkg/health/health.go b/vendor/github.com/coreos/pkg/health/health.go deleted file mode 100644 index a1c3610fa5..0000000000 --- a/vendor/github.com/coreos/pkg/health/health.go +++ /dev/null @@ -1,127 +0,0 @@ -package health - -import ( - "expvar" - "fmt" - "log" - "net/http" - - "github.com/coreos/pkg/httputil" -) - -// Checkables should return nil when the thing they are checking is healthy, and an error otherwise. -type Checkable interface { - Healthy() error -} - -// Checker provides a way to make an endpoint which can be probed for system health. -type Checker struct { - // Checks are the Checkables to be checked when probing. - Checks []Checkable - - // Unhealthyhandler is called when one or more of the checks are unhealthy. - // If not provided DefaultUnhealthyHandler is called. - UnhealthyHandler UnhealthyHandler - - // HealthyHandler is called when all checks are healthy. - // If not provided, DefaultHealthyHandler is called. - HealthyHandler http.HandlerFunc -} - -func (c Checker) ServeHTTP(w http.ResponseWriter, r *http.Request) { - unhealthyHandler := c.UnhealthyHandler - if unhealthyHandler == nil { - unhealthyHandler = DefaultUnhealthyHandler - } - - successHandler := c.HealthyHandler - if successHandler == nil { - successHandler = DefaultHealthyHandler - } - - if r.Method != "GET" { - w.Header().Set("Allow", "GET") - w.WriteHeader(http.StatusMethodNotAllowed) - return - } - - if err := Check(c.Checks); err != nil { - unhealthyHandler(w, r, err) - return - } - - successHandler(w, r) -} - -type UnhealthyHandler func(w http.ResponseWriter, r *http.Request, err error) - -type StatusResponse struct { - Status string `json:"status"` - Details *StatusResponseDetails `json:"details,omitempty"` -} - -type StatusResponseDetails struct { - Code int `json:"code,omitempty"` - Message string `json:"message,omitempty"` -} - -func Check(checks []Checkable) (err error) { - errs := []error{} - for _, c := range checks { - if e := c.Healthy(); e != nil { - errs = append(errs, e) - } - } - - switch len(errs) { - case 0: - err = nil - case 1: - err = errs[0] - default: - err = fmt.Errorf("multiple health check failure: %v", errs) - } - - return -} - -func DefaultHealthyHandler(w http.ResponseWriter, r *http.Request) { - err := httputil.WriteJSONResponse(w, http.StatusOK, StatusResponse{ - Status: "ok", - }) - if err != nil { - // TODO(bobbyrullo): replace with logging from new logging pkg, - // once it lands. - log.Printf("Failed to write JSON response: %v", err) - } -} - -func DefaultUnhealthyHandler(w http.ResponseWriter, r *http.Request, err error) { - writeErr := httputil.WriteJSONResponse(w, http.StatusInternalServerError, StatusResponse{ - Status: "error", - Details: &StatusResponseDetails{ - Code: http.StatusInternalServerError, - Message: err.Error(), - }, - }) - if writeErr != nil { - // TODO(bobbyrullo): replace with logging from new logging pkg, - // once it lands. - log.Printf("Failed to write JSON response: %v", err) - } -} - -// ExpvarHandler is copied from https://golang.org/src/expvar/expvar.go, where it's sadly unexported. -func ExpvarHandler(w http.ResponseWriter, r *http.Request) { - w.Header().Set("Content-Type", "application/json; charset=utf-8") - fmt.Fprintf(w, "{\n") - first := true - expvar.Do(func(kv expvar.KeyValue) { - if !first { - fmt.Fprintf(w, ",\n") - } - first = false - fmt.Fprintf(w, "%q: %s", kv.Key, kv.Value) - }) - fmt.Fprintf(w, "\n}\n") -} diff --git a/vendor/github.com/coreos/pkg/httputil/README.md b/vendor/github.com/coreos/pkg/httputil/README.md deleted file mode 100644 index 44fa751c4a..0000000000 --- a/vendor/github.com/coreos/pkg/httputil/README.md +++ /dev/null @@ -1,13 +0,0 @@ -httputil -==== - -Common code for dealing with HTTP. - -Includes: - -* Code for returning JSON responses. - -### Documentation - -Visit the docs on [gopkgdoc](http://godoc.org/github.com/coreos/pkg/httputil) - diff --git a/vendor/github.com/coreos/pkg/httputil/cookie.go b/vendor/github.com/coreos/pkg/httputil/cookie.go deleted file mode 100644 index c37a37bb27..0000000000 --- a/vendor/github.com/coreos/pkg/httputil/cookie.go +++ /dev/null @@ -1,21 +0,0 @@ -package httputil - -import ( - "net/http" - "time" -) - -// DeleteCookies effectively deletes all named cookies -// by wiping all data and setting to expire immediately. -func DeleteCookies(w http.ResponseWriter, cookieNames ...string) { - for _, n := range cookieNames { - c := &http.Cookie{ - Name: n, - Value: "", - Path: "/", - MaxAge: -1, - Expires: time.Time{}, - } - http.SetCookie(w, c) - } -} diff --git a/vendor/github.com/coreos/pkg/httputil/json.go b/vendor/github.com/coreos/pkg/httputil/json.go deleted file mode 100644 index 0b09235033..0000000000 --- a/vendor/github.com/coreos/pkg/httputil/json.go +++ /dev/null @@ -1,27 +0,0 @@ -package httputil - -import ( - "encoding/json" - "net/http" -) - -const ( - JSONContentType = "application/json" -) - -func WriteJSONResponse(w http.ResponseWriter, code int, resp interface{}) error { - enc, err := json.Marshal(resp) - if err != nil { - w.WriteHeader(http.StatusInternalServerError) - return err - } - - w.Header().Set("Content-Type", JSONContentType) - w.WriteHeader(code) - - _, err = w.Write(enc) - if err != nil { - return err - } - return nil -} diff --git a/vendor/github.com/coreos/pkg/timeutil/backoff.go b/vendor/github.com/coreos/pkg/timeutil/backoff.go deleted file mode 100644 index b34fb49661..0000000000 --- a/vendor/github.com/coreos/pkg/timeutil/backoff.go +++ /dev/null @@ -1,15 +0,0 @@ -package timeutil - -import ( - "time" -) - -func ExpBackoff(prev, max time.Duration) time.Duration { - if prev == 0 { - return time.Second - } - if prev > max/2 { - return max - } - return 2 * prev -} diff --git a/vendor/github.com/emicklei/go-restful-swagger12/.travis.yml b/vendor/github.com/emicklei/go-restful-swagger12/.travis.yml new file mode 100644 index 0000000000..c74e4fa57a --- /dev/null +++ b/vendor/github.com/emicklei/go-restful-swagger12/.travis.yml @@ -0,0 +1,4 @@ +language: go + +go: + - 1.x \ No newline at end of file diff --git a/vendor/github.com/emicklei/go-restful/swagger/CHANGES.md b/vendor/github.com/emicklei/go-restful-swagger12/CHANGES.md similarity index 95% rename from vendor/github.com/emicklei/go-restful/swagger/CHANGES.md rename to vendor/github.com/emicklei/go-restful-swagger12/CHANGES.md index 736f6f37c5..213b8e7b3c 100644 --- a/vendor/github.com/emicklei/go-restful/swagger/CHANGES.md +++ b/vendor/github.com/emicklei/go-restful-swagger12/CHANGES.md @@ -1,5 +1,8 @@ Change history of swagger = +2017-01-30 +- moved from go-restful/swagger to go-restful-swagger12 + 2015-10-16 - add type override mechanism for swagger models (MR 254, nathanejohnson) - replace uses of wildcard in generated apidocs (issue 251) diff --git a/vendor/github.com/emicklei/go-restful-swagger12/LICENSE b/vendor/github.com/emicklei/go-restful-swagger12/LICENSE new file mode 100644 index 0000000000..aeab5b440e --- /dev/null +++ b/vendor/github.com/emicklei/go-restful-swagger12/LICENSE @@ -0,0 +1,22 @@ +Copyright (c) 2017 Ernest Micklei + +MIT License + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/vendor/github.com/emicklei/go-restful/swagger/README.md b/vendor/github.com/emicklei/go-restful-swagger12/README.md similarity index 87% rename from vendor/github.com/emicklei/go-restful/swagger/README.md rename to vendor/github.com/emicklei/go-restful-swagger12/README.md index 6c27c30706..cad28966a9 100644 --- a/vendor/github.com/emicklei/go-restful/swagger/README.md +++ b/vendor/github.com/emicklei/go-restful-swagger12/README.md @@ -1,3 +1,8 @@ +# go-restful-swagger12 + +[![Build Status](https://travis-ci.org/emicklei/go-restful-swagger12.png)](https://travis-ci.org/emicklei/go-restful-swagger12) +[![GoDoc](https://godoc.org/github.com/emicklei/go-restful-swagger12?status.svg)](https://godoc.org/github.com/emicklei/go-restful-swagger12) + How to use Swagger UI with go-restful = @@ -74,3 +79,5 @@ Notes -- - The Nickname of an Operation is automatically set by finding the name of the function. You can override it using RouteBuilder.Operation(..) - The WebServices field of swagger.Config can be used to control which service you want to expose and document ; you can have multiple configs and therefore multiple endpoints. + +© 2017, ernestmicklei.com. MIT License. Contributions welcome. \ No newline at end of file diff --git a/vendor/github.com/emicklei/go-restful/swagger/api_declaration_list.go b/vendor/github.com/emicklei/go-restful-swagger12/api_declaration_list.go similarity index 100% rename from vendor/github.com/emicklei/go-restful/swagger/api_declaration_list.go rename to vendor/github.com/emicklei/go-restful-swagger12/api_declaration_list.go diff --git a/vendor/github.com/emicklei/go-restful/swagger/config.go b/vendor/github.com/emicklei/go-restful-swagger12/config.go similarity index 73% rename from vendor/github.com/emicklei/go-restful/swagger/config.go rename to vendor/github.com/emicklei/go-restful-swagger12/config.go index 510d6fc133..18f8e57d90 100644 --- a/vendor/github.com/emicklei/go-restful/swagger/config.go +++ b/vendor/github.com/emicklei/go-restful-swagger12/config.go @@ -2,6 +2,7 @@ package swagger import ( "net/http" + "reflect" "github.com/emicklei/go-restful" ) @@ -9,8 +10,13 @@ import ( // PostBuildDeclarationMapFunc can be used to modify the api declaration map. type PostBuildDeclarationMapFunc func(apiDeclarationMap *ApiDeclarationList) +// MapSchemaFormatFunc can be used to modify typeName at definition time. type MapSchemaFormatFunc func(typeName string) string +// MapModelTypeNameFunc can be used to return the desired typeName for a given +// type. It will return false if the default name should be used. +type MapModelTypeNameFunc func(t reflect.Type) (string, bool) + type Config struct { // url where the services are available, e.g. http://localhost:8080 // if left empty then the basePath of Swagger is taken from the actual request @@ -33,6 +39,8 @@ type Config struct { PostBuildHandler PostBuildDeclarationMapFunc // Swagger global info struct Info Info - // [optional] If set, model builder should call this handler to get addition typename-to-swagger-format-field convertion. + // [optional] If set, model builder should call this handler to get addition typename-to-swagger-format-field conversion. SchemaFormatHandler MapSchemaFormatFunc + // [optional] If set, model builder should call this handler to retrieve the name for a given type. + ModelTypeNameHandler MapModelTypeNameFunc } diff --git a/vendor/github.com/emicklei/go-restful/swagger/model_builder.go b/vendor/github.com/emicklei/go-restful-swagger12/model_builder.go similarity index 92% rename from vendor/github.com/emicklei/go-restful/swagger/model_builder.go rename to vendor/github.com/emicklei/go-restful-swagger12/model_builder.go index 398e83049c..d40786f251 100644 --- a/vendor/github.com/emicklei/go-restful/swagger/model_builder.go +++ b/vendor/github.com/emicklei/go-restful-swagger12/model_builder.go @@ -43,6 +43,12 @@ func (b modelBuilder) addModelFrom(sample interface{}) { } func (b modelBuilder) addModel(st reflect.Type, nameOverride string) *Model { + // Turn pointers into simpler types so further checks are + // correct. + if st.Kind() == reflect.Ptr { + st = st.Elem() + } + modelName := b.keyFrom(st) if nameOverride != "" { modelName = nameOverride @@ -137,6 +143,11 @@ func (b modelBuilder) buildProperty(field reflect.StructField, model *Model, mod return "", "", prop } + if field.Name == "XMLName" && field.Type.String() == "xml.Name" { + // property is metadata for the xml.Name attribute, can be skipped + return "", "", prop + } + if tag := field.Tag.Get("modelDescription"); tag != "" { modelDescription = tag } @@ -155,7 +166,7 @@ func (b modelBuilder) buildProperty(field reflect.StructField, model *Model, mod prop.Type = &pType } if prop.Format == "" { - prop.Format = b.jsonSchemaFormat(fieldType.String()) + prop.Format = b.jsonSchemaFormat(b.keyFrom(fieldType)) } return jsonName, modelDescription, prop } @@ -192,13 +203,14 @@ func (b modelBuilder) buildProperty(field reflect.StructField, model *Model, mod return jsonName, modelDescription, prop } - if b.isPrimitiveType(fieldType.String()) { - mapped := b.jsonSchemaType(fieldType.String()) + fieldTypeName := b.keyFrom(fieldType) + if b.isPrimitiveType(fieldTypeName) { + mapped := b.jsonSchemaType(fieldTypeName) prop.Type = &mapped - prop.Format = b.jsonSchemaFormat(fieldType.String()) + prop.Format = b.jsonSchemaFormat(fieldTypeName) return jsonName, modelDescription, prop } - modelType := fieldType.String() + modelType := b.keyFrom(fieldType) prop.Ref = &modelType if fieldType.Name() == "" { // override type of anonymous structs @@ -272,7 +284,7 @@ func (b modelBuilder) buildStructTypeProperty(field reflect.StructField, jsonNam } // simple struct b.addModel(fieldType, "") - var pType = fieldType.String() + var pType = b.keyFrom(fieldType) prop.Ref = &pType return jsonName, prop } @@ -336,10 +348,11 @@ func (b modelBuilder) buildPointerTypeProperty(field reflect.StructField, jsonNa } } else { // non-array, pointer type - var pType = b.jsonSchemaType(fieldType.String()[1:]) // no star, include pkg path - if b.isPrimitiveType(fieldType.String()[1:]) { + fieldTypeName := b.keyFrom(fieldType.Elem()) + var pType = b.jsonSchemaType(fieldTypeName) // no star, include pkg path + if b.isPrimitiveType(fieldTypeName) { prop.Type = &pType - prop.Format = b.jsonSchemaFormat(fieldType.String()[1:]) + prop.Format = b.jsonSchemaFormat(fieldTypeName) return jsonName, prop } prop.Ref = &pType @@ -355,7 +368,7 @@ func (b modelBuilder) buildPointerTypeProperty(field reflect.StructField, jsonNa func (b modelBuilder) getElementTypeName(modelName, jsonName string, t reflect.Type) string { if t.Kind() == reflect.Ptr { - return t.String()[1:] + t = t.Elem() } if t.Name() == "" { return modelName + "." + jsonName @@ -365,6 +378,11 @@ func (b modelBuilder) getElementTypeName(modelName, jsonName string, t reflect.T func (b modelBuilder) keyFrom(st reflect.Type) string { key := st.String() + if b.Config != nil && b.Config.ModelTypeNameHandler != nil { + if name, ok := b.Config.ModelTypeNameHandler(st); ok { + key = name + } + } if len(st.Name()) == 0 { // unnamed type // Swagger UI has special meaning for [ key = strings.Replace(key, "[]", "||", -1) diff --git a/vendor/github.com/emicklei/go-restful/swagger/model_list.go b/vendor/github.com/emicklei/go-restful-swagger12/model_list.go similarity index 100% rename from vendor/github.com/emicklei/go-restful/swagger/model_list.go rename to vendor/github.com/emicklei/go-restful-swagger12/model_list.go diff --git a/vendor/github.com/emicklei/go-restful/swagger/model_property_ext.go b/vendor/github.com/emicklei/go-restful-swagger12/model_property_ext.go similarity index 79% rename from vendor/github.com/emicklei/go-restful/swagger/model_property_ext.go rename to vendor/github.com/emicklei/go-restful-swagger12/model_property_ext.go index 04fff2c57a..a433b6b702 100644 --- a/vendor/github.com/emicklei/go-restful/swagger/model_property_ext.go +++ b/vendor/github.com/emicklei/go-restful-swagger12/model_property_ext.go @@ -33,6 +33,21 @@ func (prop *ModelProperty) setMaximum(field reflect.StructField) { func (prop *ModelProperty) setType(field reflect.StructField) { if tag := field.Tag.Get("type"); tag != "" { + // Check if the first two characters of the type tag are + // intended to emulate slice/array behaviour. + // + // If type is intended to be a slice/array then add the + // overriden type to the array item instead of the main property + if len(tag) > 2 && tag[0:2] == "[]" { + pType := "array" + prop.Type = &pType + prop.Items = new(Item) + + iType := tag[2:] + prop.Items.Type = &iType + return + } + prop.Type = &tag } } diff --git a/vendor/github.com/emicklei/go-restful/swagger/model_property_list.go b/vendor/github.com/emicklei/go-restful-swagger12/model_property_list.go similarity index 100% rename from vendor/github.com/emicklei/go-restful/swagger/model_property_list.go rename to vendor/github.com/emicklei/go-restful-swagger12/model_property_list.go diff --git a/vendor/github.com/emicklei/go-restful/swagger/ordered_route_map.go b/vendor/github.com/emicklei/go-restful-swagger12/ordered_route_map.go similarity index 100% rename from vendor/github.com/emicklei/go-restful/swagger/ordered_route_map.go rename to vendor/github.com/emicklei/go-restful-swagger12/ordered_route_map.go diff --git a/vendor/github.com/emicklei/go-restful/swagger/swagger.go b/vendor/github.com/emicklei/go-restful-swagger12/swagger.go similarity index 100% rename from vendor/github.com/emicklei/go-restful/swagger/swagger.go rename to vendor/github.com/emicklei/go-restful-swagger12/swagger.go diff --git a/vendor/github.com/emicklei/go-restful/swagger/swagger_builder.go b/vendor/github.com/emicklei/go-restful-swagger12/swagger_builder.go similarity index 100% rename from vendor/github.com/emicklei/go-restful/swagger/swagger_builder.go rename to vendor/github.com/emicklei/go-restful-swagger12/swagger_builder.go diff --git a/vendor/github.com/emicklei/go-restful/swagger/swagger_webservice.go b/vendor/github.com/emicklei/go-restful-swagger12/swagger_webservice.go similarity index 95% rename from vendor/github.com/emicklei/go-restful/swagger/swagger_webservice.go rename to vendor/github.com/emicklei/go-restful-swagger12/swagger_webservice.go index 58dd625902..d90623120a 100644 --- a/vendor/github.com/emicklei/go-restful/swagger/swagger_webservice.go +++ b/vendor/github.com/emicklei/go-restful-swagger12/swagger_webservice.go @@ -226,6 +226,9 @@ func (sws SwaggerService) composeDeclaration(ws *restful.WebService, pathPrefix pathToRoutes := newOrderedRouteMap() for _, other := range ws.Routes() { if strings.HasPrefix(other.Path, pathPrefix) { + if len(pathPrefix) > 1 && len(other.Path) > len(pathPrefix) && other.Path[len(pathPrefix)] != '/' { + continue + } pathToRoutes.Add(other.Path, other) } } @@ -277,7 +280,7 @@ func composeResponseMessages(route restful.Route, decl *ApiDeclaration, config * } // sort by code codes := sort.IntSlice{} - for code, _ := range route.ResponseErrors { + for code := range route.ResponseErrors { codes = append(codes, code) } codes.Sort() @@ -290,13 +293,12 @@ func composeResponseMessages(route restful.Route, decl *ApiDeclaration, config * if each.Model != nil { st := reflect.TypeOf(each.Model) isCollection, st := detectCollectionType(st) - modelName := modelBuilder{}.keyFrom(st) - if isCollection { - modelName = "array[" + modelName + "]" + // collection cannot be in responsemodel + if !isCollection { + modelName := modelBuilder{}.keyFrom(st) + modelBuilder{Models: &decl.Models, Config: config}.addModel(st, "") + message.ResponseModel = modelName } - modelBuilder{Models: &decl.Models, Config: config}.addModel(st, "") - // reference the model - message.ResponseModel = modelName } messages = append(messages, message) } @@ -331,12 +333,13 @@ func detectCollectionType(st reflect.Type) (bool, reflect.Type) { // addModelFromSample creates and adds (or overwrites) a Model from a sample resource func (sws SwaggerService) addModelFromSampleTo(operation *Operation, isResponse bool, sample interface{}, models *ModelList) { + mb := modelBuilder{Models: models, Config: &sws.config} if isResponse { - type_, items := asDataType(sample, &sws.config) - operation.Type = type_ + sampleType, items := asDataType(sample, &sws.config) + operation.Type = sampleType operation.Items = items } - modelBuilder{Models: models, Config: &sws.config}.addModelFrom(sample) + mb.addModelFrom(sample) } func asSwaggerParameter(param restful.ParameterData) Parameter { diff --git a/vendor/github.com/go-openapi/analysis/.drone.sec b/vendor/github.com/go-openapi/analysis/.drone.sec new file mode 100644 index 0000000000..769db5005e --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/.drone.sec @@ -0,0 +1 @@ +eyJhbGciOiJSU0EtT0FFUCIsImVuYyI6IkExMjhHQ00ifQ.gU9bGHDmyTBt_nmOh7gxp_8MUeL4ckrzh3yys59Crqypnp0Rq52Q4B7T8_4u4elt-KF3jwHXfIjTWByyce8yS6FiYfKPVuCF_7qbSC5ES84Hqs0uigZP5qGFFYXC5EZlSw7giMgLrqfjbOLPhCpnTlWjfvlRssVbvWx4I6eXQEp5EaymJn2K-pgbKLaMpgkFcDUGxDeIkK9X9XQ2sYicoRPdRZgIZfMXBL05hphlCorXp1TCNAYaoI3qDmerzDGcT5YzIRKrlW2TUEy0EI4iySCbTpdlWhj3S1mt03P9Hmo8TkTfAG2Eu6XYs59RoqXCoGZNXHfsPqV5hyLpINNSzg.4VNQ5QHe2Ig7Giam.1fN53mPplTSOg0Mr8fwNH6FVjf8DNc-YyHhaET5IK4LeY0FPoyQZIjEEIqXAgzdKJ7uNfjf_dqLe2hRd-QqYjPacIHqI8FHWTqsDHC9maL3gouDxHZ3TsYVtCnO5iXrqZXpSWjDjEHKR3PQdUbBEIpEDBgkhkAN2eUHZuD1Hjy65SMWNX0eQ2CbIEgcPxHnoeGXx8k1c0VHZuXecuYYJPyGG88UWQD0aIusIR99za5cIIflT7pfvXQMuLLCcy5Y6RWkzLaNBg7R1GOZvCiOi7jmjYSKMdIxHELC4uO37n_UenvE3KWqjt9i82jbq6XMNoN6Gcwq0Qwl7PN1rtJRK6tlczm0G24Tq8t94cDLmEz2AAHdQ9T0d7rz3hS66BK4h49D_1HYoq1ZQ9lOT_Ph0TtVFjd0-_wR3k5h5A1_0azFRt_udYbn_v7-Wbga8CjGnaIpHz5hWTrutP4euorJAyyiANnOUVDeJNZYX4D-zdjT4Yoplk0mU5zo4Uo-oKDS_Nirr71uaZHcvh3jlryi0vMiDCg61CI1i1ulHeTiT65G2zDR4byOcL4cCa_vTRnmjK-2I3arPyYQfDVmXicKo8pP8RghdQ9c8ad5XkTbxOodcONU_yVqoKr8JQDuS6FNx3ck.0btSTYMPtKCu86bQsBX5Ew \ No newline at end of file diff --git a/vendor/github.com/go-openapi/analysis/.drone.yml b/vendor/github.com/go-openapi/analysis/.drone.yml new file mode 100644 index 0000000000..6c26833116 --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/.drone.yml @@ -0,0 +1,36 @@ +clone: + path: github.com/go-openapi/analysis + +matrix: + GO_VERSION: + - "1.6" + +build: + integration: + image: golang:$$GO_VERSION + pull: true + commands: + - go get -u github.com/stretchr/testify/assert + - go get -u gopkg.in/yaml.v2 + - go get -u github.com/go-openapi/swag + - go get -u github.com/go-openapi/jsonpointer + - go get -u github.com/go-openapi/spec + - go get -u github.com/go-openapi/loads/fmts + - go test -race ./... + - go test -v -cover -coverprofile=coverage.out -covermode=count ./... + +notify: + slack: + channel: bots + webhook_url: $$SLACK_URL + username: drone + +publish: + coverage: + server: https://coverage.vmware.run + token: $$GITHUB_TOKEN + # threshold: 70 + # must_increase: true + when: + matrix: + GO_VERSION: "1.6" diff --git a/vendor/github.com/go-openapi/analysis/.gitignore b/vendor/github.com/go-openapi/analysis/.gitignore new file mode 100644 index 0000000000..dd91ed6a04 --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/.gitignore @@ -0,0 +1,2 @@ +secrets.yml +coverage.out diff --git a/vendor/github.com/go-openapi/analysis/.pullapprove.yml b/vendor/github.com/go-openapi/analysis/.pullapprove.yml new file mode 100644 index 0000000000..4ab790edb9 --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/.pullapprove.yml @@ -0,0 +1,12 @@ +approve_by_comment: true +approve_regex: '^(:shipit:|:\+1:|\+1|LGTM|lgtm|Approved)' +reject_regex: ^[Rr]ejected +reset_on_push: false +reviewers: + members: + - casualjim + - frapposelli + - vburenin + - pytlesk4 + name: pullapprove + required: 1 diff --git a/vendor/github.com/go-openapi/analysis/CODE_OF_CONDUCT.md b/vendor/github.com/go-openapi/analysis/CODE_OF_CONDUCT.md new file mode 100644 index 0000000000..9322b065e3 --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/CODE_OF_CONDUCT.md @@ -0,0 +1,74 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, gender identity and expression, level of experience, +nationality, personal appearance, race, religion, or sexual identity and +orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or +advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic + address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or +reject comments, commits, code, wiki edits, issues, and other contributions +that are not aligned to this Code of Conduct, or to ban temporarily or +permanently any contributor for other behaviors that they deem inappropriate, +threatening, offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported by contacting the project team at ivan+abuse@flanders.co.nz. All +complaints will be reviewed and investigated and will result in a response that +is deemed necessary and appropriate to the circumstances. The project team is +obligated to maintain confidentiality with regard to the reporter of an incident. +Further details of specific enforcement policies may be posted separately. + +Project maintainers who do not follow or enforce the Code of Conduct in good +faith may face temporary or permanent repercussions as determined by other +members of the project's leadership. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, +available at [http://contributor-covenant.org/version/1/4][version] + +[homepage]: http://contributor-covenant.org +[version]: http://contributor-covenant.org/version/1/4/ diff --git a/vendor/cloud.google.com/go/LICENSE b/vendor/github.com/go-openapi/analysis/LICENSE similarity index 99% rename from vendor/cloud.google.com/go/LICENSE rename to vendor/github.com/go-openapi/analysis/LICENSE index a4c5efd822..d645695673 100644 --- a/vendor/cloud.google.com/go/LICENSE +++ b/vendor/github.com/go-openapi/analysis/LICENSE @@ -187,7 +187,7 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2014 Google Inc. + Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/vendor/github.com/go-openapi/analysis/README.md b/vendor/github.com/go-openapi/analysis/README.md new file mode 100644 index 0000000000..b6e526c006 --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/README.md @@ -0,0 +1,6 @@ +# OpenAPI initiative analysis [![Build Status](https://ci.vmware.run/api/badges/go-openapi/analysis/status.svg)](https://ci.vmware.run/go-openapi/analysis) [![Coverage](https://coverage.vmware.run/badges/go-openapi/analysis/coverage.svg)](https://coverage.vmware.run/go-openapi/analysis) [![Slack Status](https://slackin.goswagger.io/badge.svg)](https://slackin.goswagger.io) + +[![license](http://img.shields.io/badge/license-Apache%20v2-orange.svg)](https://raw.githubusercontent.com/go-openapi/analysis/master/LICENSE) [![GoDoc](https://godoc.org/github.com/go-openapi/analysis?status.svg)](http://godoc.org/github.com/go-openapi/analysis) + + +A foundational library to analyze an OAI specification document for easier reasoning about the content. \ No newline at end of file diff --git a/vendor/github.com/go-openapi/analysis/analyzer.go b/vendor/github.com/go-openapi/analysis/analyzer.go new file mode 100644 index 0000000000..d388db3a77 --- /dev/null +++ b/vendor/github.com/go-openapi/analysis/analyzer.go @@ -0,0 +1,614 @@ +// Copyright 2015 go-swagger maintainers +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package analysis + +import ( + "fmt" + slashpath "path" + "strconv" + "strings" + + "github.com/go-openapi/jsonpointer" + "github.com/go-openapi/spec" + "github.com/go-openapi/swag" +) + +type referenceAnalysis struct { + schemas map[string]spec.Ref + responses map[string]spec.Ref + parameters map[string]spec.Ref + items map[string]spec.Ref + allRefs map[string]spec.Ref + referenced struct { + schemas map[string]SchemaRef + responses map[string]*spec.Response + parameters map[string]*spec.Parameter + } +} + +func (r *referenceAnalysis) addRef(key string, ref spec.Ref) { + r.allRefs["#"+key] = ref +} + +func (r *referenceAnalysis) addItemsRef(key string, items *spec.Items) { + r.items["#"+key] = items.Ref + r.addRef(key, items.Ref) +} + +func (r *referenceAnalysis) addSchemaRef(key string, ref SchemaRef) { + r.schemas["#"+key] = ref.Schema.Ref + r.addRef(key, ref.Schema.Ref) +} + +func (r *referenceAnalysis) addResponseRef(key string, resp *spec.Response) { + r.responses["#"+key] = resp.Ref + r.addRef(key, resp.Ref) +} + +func (r *referenceAnalysis) addParamRef(key string, param *spec.Parameter) { + r.parameters["#"+key] = param.Ref + r.addRef(key, param.Ref) +} + +// New takes a swagger spec object and returns an analyzed spec document. +// The analyzed document contains a number of indices that make it easier to +// reason about semantics of a swagger specification for use in code generation +// or validation etc. +func New(doc *spec.Swagger) *Spec { + a := &Spec{ + spec: doc, + consumes: make(map[string]struct{}, 150), + produces: make(map[string]struct{}, 150), + authSchemes: make(map[string]struct{}, 150), + operations: make(map[string]map[string]*spec.Operation, 150), + allSchemas: make(map[string]SchemaRef, 150), + allOfs: make(map[string]SchemaRef, 150), + references: referenceAnalysis{ + schemas: make(map[string]spec.Ref, 150), + responses: make(map[string]spec.Ref, 150), + parameters: make(map[string]spec.Ref, 150), + items: make(map[string]spec.Ref, 150), + allRefs: make(map[string]spec.Ref, 150), + }, + } + a.references.referenced.schemas = make(map[string]SchemaRef, 150) + a.references.referenced.responses = make(map[string]*spec.Response, 150) + a.references.referenced.parameters = make(map[string]*spec.Parameter, 150) + a.initialize() + return a +} + +// Spec takes a swagger spec object and turns it into a registry +// with a bunch of utility methods to act on the information in the spec +type Spec struct { + spec *spec.Swagger + consumes map[string]struct{} + produces map[string]struct{} + authSchemes map[string]struct{} + operations map[string]map[string]*spec.Operation + references referenceAnalysis + allSchemas map[string]SchemaRef + allOfs map[string]SchemaRef +} + +func (s *Spec) initialize() { + for _, c := range s.spec.Consumes { + s.consumes[c] = struct{}{} + } + for _, c := range s.spec.Produces { + s.produces[c] = struct{}{} + } + for _, ss := range s.spec.Security { + for k := range ss { + s.authSchemes[k] = struct{}{} + } + } + for path, pathItem := range s.AllPaths() { + s.analyzeOperations(path, &pathItem) + } + + for name, parameter := range s.spec.Parameters { + refPref := slashpath.Join("/parameters", jsonpointer.Escape(name)) + if parameter.Items != nil { + s.analyzeItems("items", parameter.Items, refPref) + } + if parameter.In == "body" && parameter.Schema != nil { + s.analyzeSchema("schema", *parameter.Schema, refPref) + } + } + + for name, response := range s.spec.Responses { + refPref := slashpath.Join("/responses", jsonpointer.Escape(name)) + for _, v := range response.Headers { + if v.Items != nil { + s.analyzeItems("items", v.Items, refPref) + } + } + if response.Schema != nil { + s.analyzeSchema("schema", *response.Schema, refPref) + } + } + + for name, schema := range s.spec.Definitions { + s.analyzeSchema(name, schema, "/definitions") + } + // TODO: after analyzing all things and flattening schemas etc + // resolve all the collected references to their final representations + // best put in a separate method because this could get expensive +} + +func (s *Spec) analyzeOperations(path string, pi *spec.PathItem) { + // TODO: resolve refs here? + op := pi + s.analyzeOperation("GET", path, op.Get) + s.analyzeOperation("PUT", path, op.Put) + s.analyzeOperation("POST", path, op.Post) + s.analyzeOperation("PATCH", path, op.Patch) + s.analyzeOperation("DELETE", path, op.Delete) + s.analyzeOperation("HEAD", path, op.Head) + s.analyzeOperation("OPTIONS", path, op.Options) + for i, param := range op.Parameters { + refPref := slashpath.Join("/paths", jsonpointer.Escape(path), "parameters", strconv.Itoa(i)) + if param.Ref.String() != "" { + s.references.addParamRef(refPref, ¶m) + } + if param.Items != nil { + s.analyzeItems("items", param.Items, refPref) + } + if param.Schema != nil { + s.analyzeSchema("schema", *param.Schema, refPref) + } + } +} + +func (s *Spec) analyzeItems(name string, items *spec.Items, prefix string) { + if items == nil { + return + } + refPref := slashpath.Join(prefix, name) + s.analyzeItems(name, items.Items, refPref) + if items.Ref.String() != "" { + s.references.addItemsRef(refPref, items) + } +} + +func (s *Spec) analyzeOperation(method, path string, op *spec.Operation) { + if op == nil { + return + } + + for _, c := range op.Consumes { + s.consumes[c] = struct{}{} + } + for _, c := range op.Produces { + s.produces[c] = struct{}{} + } + for _, ss := range op.Security { + for k := range ss { + s.authSchemes[k] = struct{}{} + } + } + if _, ok := s.operations[method]; !ok { + s.operations[method] = make(map[string]*spec.Operation) + } + s.operations[method][path] = op + prefix := slashpath.Join("/paths", jsonpointer.Escape(path), strings.ToLower(method)) + for i, param := range op.Parameters { + refPref := slashpath.Join(prefix, "parameters", strconv.Itoa(i)) + if param.Ref.String() != "" { + s.references.addParamRef(refPref, ¶m) + } + s.analyzeItems("items", param.Items, refPref) + if param.In == "body" && param.Schema != nil { + s.analyzeSchema("schema", *param.Schema, refPref) + } + } + if op.Responses != nil { + if op.Responses.Default != nil { + refPref := slashpath.Join(prefix, "responses", "default") + if op.Responses.Default.Ref.String() != "" { + s.references.addResponseRef(refPref, op.Responses.Default) + } + for _, v := range op.Responses.Default.Headers { + s.analyzeItems("items", v.Items, refPref) + } + if op.Responses.Default.Schema != nil { + s.analyzeSchema("schema", *op.Responses.Default.Schema, refPref) + } + } + for k, res := range op.Responses.StatusCodeResponses { + refPref := slashpath.Join(prefix, "responses", strconv.Itoa(k)) + if res.Ref.String() != "" { + s.references.addResponseRef(refPref, &res) + } + for _, v := range res.Headers { + s.analyzeItems("items", v.Items, refPref) + } + if res.Schema != nil { + s.analyzeSchema("schema", *res.Schema, refPref) + } + } + } +} + +func (s *Spec) analyzeSchema(name string, schema spec.Schema, prefix string) { + refURI := slashpath.Join(prefix, jsonpointer.Escape(name)) + schRef := SchemaRef{ + Name: name, + Schema: &schema, + Ref: spec.MustCreateRef("#" + refURI), + } + s.allSchemas["#"+refURI] = schRef + if schema.Ref.String() != "" { + s.references.addSchemaRef(refURI, schRef) + } + for k, v := range schema.Definitions { + s.analyzeSchema(k, v, slashpath.Join(refURI, "definitions")) + } + for k, v := range schema.Properties { + s.analyzeSchema(k, v, slashpath.Join(refURI, "properties")) + } + for k, v := range schema.PatternProperties { + s.analyzeSchema(k, v, slashpath.Join(refURI, "patternProperties")) + } + for i, v := range schema.AllOf { + s.analyzeSchema(strconv.Itoa(i), v, slashpath.Join(refURI, "allOf")) + } + if len(schema.AllOf) > 0 { + s.allOfs["#"+refURI] = SchemaRef{Name: name, Schema: &schema, Ref: spec.MustCreateRef("#" + refURI)} + } + for i, v := range schema.AnyOf { + s.analyzeSchema(strconv.Itoa(i), v, slashpath.Join(refURI, "anyOf")) + } + for i, v := range schema.OneOf { + s.analyzeSchema(strconv.Itoa(i), v, slashpath.Join(refURI, "oneOf")) + } + if schema.Not != nil { + s.analyzeSchema("not", *schema.Not, refURI) + } + if schema.AdditionalProperties != nil && schema.AdditionalProperties.Schema != nil { + s.analyzeSchema("additionalProperties", *schema.AdditionalProperties.Schema, refURI) + } + if schema.AdditionalItems != nil && schema.AdditionalItems.Schema != nil { + s.analyzeSchema("additionalItems", *schema.AdditionalItems.Schema, refURI) + } + if schema.Items != nil { + if schema.Items.Schema != nil { + s.analyzeSchema("items", *schema.Items.Schema, refURI) + } + for i, sch := range schema.Items.Schemas { + s.analyzeSchema(strconv.Itoa(i), sch, slashpath.Join(refURI, "items")) + } + } +} + +// SecurityRequirement is a representation of a security requirement for an operation +type SecurityRequirement struct { + Name string + Scopes []string +} + +// SecurityRequirementsFor gets the security requirements for the operation +func (s *Spec) SecurityRequirementsFor(operation *spec.Operation) []SecurityRequirement { + if s.spec.Security == nil && operation.Security == nil { + return nil + } + + schemes := s.spec.Security + if operation.Security != nil { + schemes = operation.Security + } + + unique := make(map[string]SecurityRequirement) + for _, scheme := range schemes { + for k, v := range scheme { + if _, ok := unique[k]; !ok { + unique[k] = SecurityRequirement{Name: k, Scopes: v} + } + } + } + + var result []SecurityRequirement + for _, v := range unique { + result = append(result, v) + } + return result +} + +// SecurityDefinitionsFor gets the matching security definitions for a set of requirements +func (s *Spec) SecurityDefinitionsFor(operation *spec.Operation) map[string]spec.SecurityScheme { + requirements := s.SecurityRequirementsFor(operation) + if len(requirements) == 0 { + return nil + } + result := make(map[string]spec.SecurityScheme) + for _, v := range requirements { + if definition, ok := s.spec.SecurityDefinitions[v.Name]; ok { + if definition != nil { + result[v.Name] = *definition + } + } + } + return result +} + +// ConsumesFor gets the mediatypes for the operation +func (s *Spec) ConsumesFor(operation *spec.Operation) []string { + + if len(operation.Consumes) == 0 { + cons := make(map[string]struct{}, len(s.spec.Consumes)) + for _, k := range s.spec.Consumes { + cons[k] = struct{}{} + } + return s.structMapKeys(cons) + } + + cons := make(map[string]struct{}, len(operation.Consumes)) + for _, c := range operation.Consumes { + cons[c] = struct{}{} + } + return s.structMapKeys(cons) +} + +// ProducesFor gets the mediatypes for the operation +func (s *Spec) ProducesFor(operation *spec.Operation) []string { + if len(operation.Produces) == 0 { + prod := make(map[string]struct{}, len(s.spec.Produces)) + for _, k := range s.spec.Produces { + prod[k] = struct{}{} + } + return s.structMapKeys(prod) + } + + prod := make(map[string]struct{}, len(operation.Produces)) + for _, c := range operation.Produces { + prod[c] = struct{}{} + } + return s.structMapKeys(prod) +} + +func mapKeyFromParam(param *spec.Parameter) string { + return fmt.Sprintf("%s#%s", param.In, fieldNameFromParam(param)) +} + +func fieldNameFromParam(param *spec.Parameter) string { + if nm, ok := param.Extensions.GetString("go-name"); ok { + return nm + } + return swag.ToGoName(param.Name) +} + +func (s *Spec) paramsAsMap(parameters []spec.Parameter, res map[string]spec.Parameter) { + for _, param := range parameters { + pr := param + if pr.Ref.String() != "" { + obj, _, err := pr.Ref.GetPointer().Get(s.spec) + if err != nil { + panic(err) + } + pr = obj.(spec.Parameter) + } + res[mapKeyFromParam(&pr)] = pr + } +} + +// ParametersFor the specified operation id +func (s *Spec) ParametersFor(operationID string) []spec.Parameter { + gatherParams := func(pi *spec.PathItem, op *spec.Operation) []spec.Parameter { + bag := make(map[string]spec.Parameter) + s.paramsAsMap(pi.Parameters, bag) + s.paramsAsMap(op.Parameters, bag) + + var res []spec.Parameter + for _, v := range bag { + res = append(res, v) + } + return res + } + for _, pi := range s.spec.Paths.Paths { + if pi.Get != nil && pi.Get.ID == operationID { + return gatherParams(&pi, pi.Get) + } + if pi.Head != nil && pi.Head.ID == operationID { + return gatherParams(&pi, pi.Head) + } + if pi.Options != nil && pi.Options.ID == operationID { + return gatherParams(&pi, pi.Options) + } + if pi.Post != nil && pi.Post.ID == operationID { + return gatherParams(&pi, pi.Post) + } + if pi.Patch != nil && pi.Patch.ID == operationID { + return gatherParams(&pi, pi.Patch) + } + if pi.Put != nil && pi.Put.ID == operationID { + return gatherParams(&pi, pi.Put) + } + if pi.Delete != nil && pi.Delete.ID == operationID { + return gatherParams(&pi, pi.Delete) + } + } + return nil +} + +// ParamsFor the specified method and path. Aggregates them with the defaults etc, so it's all the params that +// apply for the method and path. +func (s *Spec) ParamsFor(method, path string) map[string]spec.Parameter { + res := make(map[string]spec.Parameter) + if pi, ok := s.spec.Paths.Paths[path]; ok { + s.paramsAsMap(pi.Parameters, res) + s.paramsAsMap(s.operations[strings.ToUpper(method)][path].Parameters, res) + } + return res +} + +// OperationForName gets the operation for the given id +func (s *Spec) OperationForName(operationID string) (string, string, *spec.Operation, bool) { + for method, pathItem := range s.operations { + for path, op := range pathItem { + if operationID == op.ID { + return method, path, op, true + } + } + } + return "", "", nil, false +} + +// OperationFor the given method and path +func (s *Spec) OperationFor(method, path string) (*spec.Operation, bool) { + if mp, ok := s.operations[strings.ToUpper(method)]; ok { + op, fn := mp[path] + return op, fn + } + return nil, false +} + +// Operations gathers all the operations specified in the spec document +func (s *Spec) Operations() map[string]map[string]*spec.Operation { + return s.operations +} + +func (s *Spec) structMapKeys(mp map[string]struct{}) []string { + if len(mp) == 0 { + return nil + } + + result := make([]string, 0, len(mp)) + for k := range mp { + result = append(result, k) + } + return result +} + +// AllPaths returns all the paths in the swagger spec +func (s *Spec) AllPaths() map[string]spec.PathItem { + if s.spec == nil || s.spec.Paths == nil { + return nil + } + return s.spec.Paths.Paths +} + +// OperationIDs gets all the operation ids based on method an dpath +func (s *Spec) OperationIDs() []string { + if len(s.operations) == 0 { + return nil + } + result := make([]string, 0, len(s.operations)) + for method, v := range s.operations { + for p, o := range v { + if o.ID != "" { + result = append(result, o.ID) + } else { + result = append(result, fmt.Sprintf("%s %s", strings.ToUpper(method), p)) + } + } + } + return result +} + +// RequiredConsumes gets all the distinct consumes that are specified in the specification document +func (s *Spec) RequiredConsumes() []string { + return s.structMapKeys(s.consumes) +} + +// RequiredProduces gets all the distinct produces that are specified in the specification document +func (s *Spec) RequiredProduces() []string { + return s.structMapKeys(s.produces) +} + +// RequiredSecuritySchemes gets all the distinct security schemes that are specified in the swagger spec +func (s *Spec) RequiredSecuritySchemes() []string { + return s.structMapKeys(s.authSchemes) +} + +// SchemaRef is a reference to a schema +type SchemaRef struct { + Name string + Ref spec.Ref + Schema *spec.Schema +} + +// SchemasWithAllOf returns schema references to all schemas that are defined +// with an allOf key +func (s *Spec) SchemasWithAllOf() (result []SchemaRef) { + for _, v := range s.allOfs { + result = append(result, v) + } + return +} + +// AllDefinitions returns schema references for all the definitions that were discovered +func (s *Spec) AllDefinitions() (result []SchemaRef) { + for _, v := range s.allSchemas { + result = append(result, v) + } + return +} + +// AllDefinitionReferences returns json refs for all the discovered schemas +func (s *Spec) AllDefinitionReferences() (result []string) { + for _, v := range s.references.schemas { + result = append(result, v.String()) + } + return +} + +// AllParameterReferences returns json refs for all the discovered parameters +func (s *Spec) AllParameterReferences() (result []string) { + for _, v := range s.references.parameters { + result = append(result, v.String()) + } + return +} + +// AllResponseReferences returns json refs for all the discovered responses +func (s *Spec) AllResponseReferences() (result []string) { + for _, v := range s.references.responses { + result = append(result, v.String()) + } + return +} + +// AllItemsReferences returns the references for all the items +func (s *Spec) AllItemsReferences() (result []string) { + for _, v := range s.references.items { + result = append(result, v.String()) + } + return +} + +// AllReferences returns all the references found in the document +func (s *Spec) AllReferences() (result []string) { + for _, v := range s.references.allRefs { + result = append(result, v.String()) + } + return +} + +// AllRefs returns all the unique references found in the document +func (s *Spec) AllRefs() (result []spec.Ref) { + set := make(map[string]struct{}) + for _, v := range s.references.allRefs { + a := v.String() + if a == "" { + continue + } + if _, ok := set[a]; !ok { + set[a] = struct{}{} + result = append(result, v) + } + } + return +} diff --git a/vendor/github.com/go-openapi/loads/.drone.sec b/vendor/github.com/go-openapi/loads/.drone.sec new file mode 100644 index 0000000000..6d3e843993 --- /dev/null +++ b/vendor/github.com/go-openapi/loads/.drone.sec @@ -0,0 +1 @@ +eyJhbGciOiJSU0EtT0FFUCIsImVuYyI6IkExMjhHQ00ifQ.xUjixvmMMeampw0Doyr_XLvcV5ICmDgDFmlcWqgmO84O3Hwn6dqbMkwOjpKMOyEJW_98b5Om5ED59IFt2S0T_OarlrsJL8jOK5fqxSMNXy2w8LfI-e5l1URverW41ofAVK8m9wK05q2BSJM_M6PyyODaQeDBiCVK1HreMZBlXpuUDVtBMPILQoga0eSZOsTR3DYEpZIS0A0Rsa5yIhMYR5d5-JMYqbqOCB7tNJ-BM83OzYgL7Hrz0J15kqaJmhQ-GJoMJDzOemSO9KxLCOfSPp11R_G3Mfd48xYnuiRuPOTakbOCLxuYviH6uoGVIOhnMyY9qKiDKbOn4BQUi1-igA.6qjQzq9nzAxRRKV_.z79R5cMFAEuEaAh6U9ykiL8oIqzMbs_I2C-hSFRh3HYRJ4fTB-9LrcbF0uASIOq7bBn4OQzW-0QFwYOs1uaawmrByGngV5d0afiZf_LBKcmTF2vtxRi_A_nxD-EHoPmh3lKBU5WNDe_8kLjEeS89HeyyFPuv5iQbqhzdqPFohHKVigwVqVYYLjB8GWQ4t7tC4c8l5rHanaXf71W0e3op2m8bebpZL0JPGhnULVA1oU27TYeLsO112JkIYtBwZxzvAs--bBFoKeGJWVMFzrKN68UACGZ9RFw0uGJbBmVC4-jRuIc6XpqeEqw3KG-rjFzkeEor3575qW-8kiXYqpub9SFUc3SSZkxJ8hB3SrnMBOuDUSenrXNpAbltmV3KAALzN3_bMBQuihwSRIn0Hg7-Dpni8BieMe44RMDvRu6p_71aeU_KW4V7Umy_h8gpIvQFuKGdTQH2ahsyCXL0ojqjMbVMdoWpDQTQ2_Fy8Qt_p2kJ8BgDo-1Akd4a6BNU2NGqsdnrJmtVKcTqLBadf9ylCwxHdGVrtNYORALSms2T6Q1s-poQnMjIwN8lnUD8ABUBpt4uVtrYkiWPVwrwywLQeiHhR-pboe_53kWDAx4Hy4rpbKsaxanYhy_bEbAYKb3aIUA.75GD4kRBCQdcGFYP1QYdCg \ No newline at end of file diff --git a/vendor/github.com/go-openapi/loads/.drone.yml b/vendor/github.com/go-openapi/loads/.drone.yml new file mode 100644 index 0000000000..9822910353 --- /dev/null +++ b/vendor/github.com/go-openapi/loads/.drone.yml @@ -0,0 +1,39 @@ +clone: + path: github.com/go-openapi/loads + +matrix: + GO_VERSION: + - "1.6" + +build: + integration: + image: golang:$$GO_VERSION + pull: true + environment: + GOCOVMODE: "count" + commands: + - go get -u github.com/axw/gocov/gocov + - go get -u gopkg.in/matm/v1/gocov-html + - go get -u github.com/cee-dub/go-junit-report + - go get -u github.com/stretchr/testify/assert + - go get -u gopkg.in/yaml.v2 + - go get -u github.com/go-openapi/swag + - go get -u github.com/go-openapi/analysis + - go get -u github.com/go-openapi/spec + - ./hack/build-drone.sh + +notify: + slack: + channel: bots + webhook_url: $$SLACK_URL + username: drone + +publish: + coverage: + server: https://coverage.vmware.run + token: $$GITHUB_TOKEN + # threshold: 70 + # must_increase: true + when: + matrix: + GO_VERSION: "1.6" diff --git a/vendor/github.com/go-openapi/loads/.gitignore b/vendor/github.com/go-openapi/loads/.gitignore new file mode 100644 index 0000000000..e4f15f17bf --- /dev/null +++ b/vendor/github.com/go-openapi/loads/.gitignore @@ -0,0 +1,4 @@ +secrets.yml +coverage.out +profile.cov +profile.out diff --git a/vendor/github.com/go-openapi/loads/.pullapprove.yml b/vendor/github.com/go-openapi/loads/.pullapprove.yml new file mode 100644 index 0000000000..5ec183e224 --- /dev/null +++ b/vendor/github.com/go-openapi/loads/.pullapprove.yml @@ -0,0 +1,13 @@ +approve_by_comment: true +approve_regex: '^(:shipit:|:\+1:|\+1|LGTM|lgtm|Approved)' +reject_regex: ^[Rr]ejected +reset_on_push: false +reviewers: + members: + - casualjim + - chancez + - frapposelli + - vburenin + - pytlesk4 + name: pullapprove + required: 1 diff --git a/vendor/github.com/go-openapi/loads/CODE_OF_CONDUCT.md b/vendor/github.com/go-openapi/loads/CODE_OF_CONDUCT.md new file mode 100644 index 0000000000..9322b065e3 --- /dev/null +++ b/vendor/github.com/go-openapi/loads/CODE_OF_CONDUCT.md @@ -0,0 +1,74 @@ +# Contributor Covenant Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, gender identity and expression, level of experience, +nationality, personal appearance, race, religion, or sexual identity and +orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or +advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic + address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or +reject comments, commits, code, wiki edits, issues, and other contributions +that are not aligned to this Code of Conduct, or to ban temporarily or +permanently any contributor for other behaviors that they deem inappropriate, +threatening, offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +## Enforcement + +Instances of abusive, harassing, or otherwise unacceptable behavior may be +reported by contacting the project team at ivan+abuse@flanders.co.nz. All +complaints will be reviewed and investigated and will result in a response that +is deemed necessary and appropriate to the circumstances. The project team is +obligated to maintain confidentiality with regard to the reporter of an incident. +Further details of specific enforcement policies may be posted separately. + +Project maintainers who do not follow or enforce the Code of Conduct in good +faith may face temporary or permanent repercussions as determined by other +members of the project's leadership. + +## Attribution + +This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, +available at [http://contributor-covenant.org/version/1/4][version] + +[homepage]: http://contributor-covenant.org +[version]: http://contributor-covenant.org/version/1/4/ diff --git a/vendor/google.golang.org/cloud/LICENSE b/vendor/github.com/go-openapi/loads/LICENSE similarity index 99% rename from vendor/google.golang.org/cloud/LICENSE rename to vendor/github.com/go-openapi/loads/LICENSE index a4c5efd822..d645695673 100644 --- a/vendor/google.golang.org/cloud/LICENSE +++ b/vendor/github.com/go-openapi/loads/LICENSE @@ -187,7 +187,7 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2014 Google Inc. + Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/vendor/github.com/go-openapi/loads/README.md b/vendor/github.com/go-openapi/loads/README.md new file mode 100644 index 0000000000..9d5c899970 --- /dev/null +++ b/vendor/github.com/go-openapi/loads/README.md @@ -0,0 +1,5 @@ +# Loads OAI specs [![Build Status](https://ci.vmware.run/api/badges/go-openapi/loads/status.svg)](https://ci.vmware.run/go-openapi/loads) [![Coverage](https://coverage.vmware.run/badges/go-openapi/loads/coverage.svg)](https://coverage.vmware.run/go-openapi/loads) [![Slack Status](https://slackin.goswagger.io/badge.svg)](https://slackin.goswagger.io) + +[![license](http://img.shields.io/badge/license-Apache%20v2-orange.svg)](https://raw.githubusercontent.com/go-openapi/loads/master/LICENSE) [![GoDoc](https://godoc.org/github.com/go-openapi/loads?status.svg)](http://godoc.org/github.com/go-openapi/loads) + +Loading of OAI specification documents from local or remote locations. diff --git a/vendor/github.com/go-openapi/loads/spec.go b/vendor/github.com/go-openapi/loads/spec.go new file mode 100644 index 0000000000..ff1ee1c9fa --- /dev/null +++ b/vendor/github.com/go-openapi/loads/spec.go @@ -0,0 +1,203 @@ +// Copyright 2015 go-swagger maintainers +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package loads + +import ( + "encoding/json" + "fmt" + "net/url" + + "github.com/go-openapi/analysis" + "github.com/go-openapi/spec" + "github.com/go-openapi/swag" +) + +// JSONDoc loads a json document from either a file or a remote url +func JSONDoc(path string) (json.RawMessage, error) { + data, err := swag.LoadFromFileOrHTTP(path) + if err != nil { + return nil, err + } + return json.RawMessage(data), nil +} + +// DocLoader represents a doc loader type +type DocLoader func(string) (json.RawMessage, error) + +// DocMatcher represents a predicate to check if a loader matches +type DocMatcher func(string) bool + +var loaders = &loader{Match: func(_ string) bool { return true }, Fn: JSONDoc} + +// AddLoader for a document +func AddLoader(predicate DocMatcher, load DocLoader) { + prev := loaders + loaders = &loader{ + Match: predicate, + Fn: load, + Next: prev, + } + +} + +type loader struct { + Fn DocLoader + Match DocMatcher + Next *loader +} + +// JSONSpec loads a spec from a json document +func JSONSpec(path string) (*Document, error) { + data, err := JSONDoc(path) + if err != nil { + return nil, err + } + // convert to json + return Analyzed(json.RawMessage(data), "") +} + +// Document represents a swagger spec document +type Document struct { + // specAnalyzer + Analyzer *analysis.Spec + spec *spec.Swagger + origSpec *spec.Swagger + schema *spec.Schema + raw json.RawMessage +} + +// Spec loads a new spec document +func Spec(path string) (*Document, error) { + specURL, err := url.Parse(path) + if err != nil { + return nil, err + } + for l := loaders.Next; l != nil; l = l.Next { + if loaders.Match(specURL.Path) { + b, err2 := loaders.Fn(path) + if err2 != nil { + return nil, err2 + } + return Analyzed(b, "") + } + } + b, err := loaders.Fn(path) + if err != nil { + return nil, err + } + return Analyzed(b, "") +} + +var swag20Schema = spec.MustLoadSwagger20Schema() + +// Analyzed creates a new analyzed spec document +func Analyzed(data json.RawMessage, version string) (*Document, error) { + if version == "" { + version = "2.0" + } + if version != "2.0" { + return nil, fmt.Errorf("spec version %q is not supported", version) + } + + swspec := new(spec.Swagger) + if err := json.Unmarshal(data, swspec); err != nil { + return nil, err + } + + origsqspec := new(spec.Swagger) + if err := json.Unmarshal(data, origsqspec); err != nil { + return nil, err + } + + d := &Document{ + Analyzer: analysis.New(swspec), + schema: swag20Schema, + spec: swspec, + raw: data, + origSpec: origsqspec, + } + return d, nil +} + +// Expanded expands the ref fields in the spec document and returns a new spec document +func (d *Document) Expanded() (*Document, error) { + swspec := new(spec.Swagger) + if err := json.Unmarshal(d.raw, swspec); err != nil { + return nil, err + } + if err := spec.ExpandSpec(swspec); err != nil { + return nil, err + } + + dd := &Document{ + Analyzer: analysis.New(swspec), + spec: swspec, + schema: swag20Schema, + raw: d.raw, + origSpec: d.origSpec, + } + return dd, nil +} + +// BasePath the base path for this spec +func (d *Document) BasePath() string { + return d.spec.BasePath +} + +// Version returns the version of this spec +func (d *Document) Version() string { + return d.spec.Swagger +} + +// Schema returns the swagger 2.0 schema +func (d *Document) Schema() *spec.Schema { + return d.schema +} + +// Spec returns the swagger spec object model +func (d *Document) Spec() *spec.Swagger { + return d.spec +} + +// Host returns the host for the API +func (d *Document) Host() string { + return d.spec.Host +} + +// Raw returns the raw swagger spec as json bytes +func (d *Document) Raw() json.RawMessage { + return d.raw +} + +func (d *Document) OrigSpec() *spec.Swagger { + return d.origSpec +} + +// ResetDefinitions gives a shallow copy with the models reset +func (d *Document) ResetDefinitions() *Document { + defs := make(map[string]spec.Schema, len(d.origSpec.Definitions)) + for k, v := range d.origSpec.Definitions { + defs[k] = v + } + + d.spec.Definitions = defs + return d +} + +// Pristine creates a new pristine document instance based on the input data +func (d *Document) Pristine() *Document { + dd, _ := Analyzed(d.Raw(), d.Version()) + return dd +} diff --git a/vendor/github.com/gogo/protobuf/LICENSE b/vendor/github.com/gogo/protobuf/LICENSE index 335e38e19b..7be0cc7b62 100644 --- a/vendor/github.com/gogo/protobuf/LICENSE +++ b/vendor/github.com/gogo/protobuf/LICENSE @@ -1,7 +1,7 @@ -Extensions for Protocol Buffers to create more go like structures. +Protocol Buffers for Go with Gadgets -Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -http://github.com/gogo/protobuf/gogoproto +Copyright (c) 2013, The GoGo Authors. All rights reserved. +http://github.com/gogo/protobuf Go support for Protocol Buffers - Google's data interchange format diff --git a/vendor/github.com/gogo/protobuf/proto/Makefile b/vendor/github.com/gogo/protobuf/proto/Makefile index 23a6b17344..41c717573e 100644 --- a/vendor/github.com/gogo/protobuf/proto/Makefile +++ b/vendor/github.com/gogo/protobuf/proto/Makefile @@ -39,5 +39,5 @@ test: install generate-test-pbs generate-test-pbs: make install make -C testdata - protoc-min-version --version="3.0.0" --proto_path=.:../../../../ --gogo_out=. proto3_proto/proto3.proto + protoc-min-version --version="3.0.0" --proto_path=.:../../../../:../protobuf --gogo_out=Mtestdata/test.proto=github.com/gogo/protobuf/proto/testdata,Mgoogle/protobuf/any.proto=github.com/gogo/protobuf/types:. proto3_proto/proto3.proto make diff --git a/vendor/github.com/gogo/protobuf/proto/clone.go b/vendor/github.com/gogo/protobuf/proto/clone.go index 79edb86119..5d4cba4b51 100644 --- a/vendor/github.com/gogo/protobuf/proto/clone.go +++ b/vendor/github.com/gogo/protobuf/proto/clone.go @@ -84,14 +84,20 @@ func mergeStruct(out, in reflect.Value) { mergeAny(out.Field(i), in.Field(i), false, sprop.Prop[i]) } - if emIn, ok := in.Addr().Interface().(extensionsMap); ok { - emOut := out.Addr().Interface().(extensionsMap) - mergeExtension(emOut.ExtensionMap(), emIn.ExtensionMap()) - } else if emIn, ok := in.Addr().Interface().(extensionsBytes); ok { + if emIn, ok := in.Addr().Interface().(extensionsBytes); ok { emOut := out.Addr().Interface().(extensionsBytes) bIn := emIn.GetExtensions() bOut := emOut.GetExtensions() *bOut = append(*bOut, *bIn...) + } else if emIn, ok := extendable(in.Addr().Interface()); ok { + emOut, _ := extendable(out.Addr().Interface()) + mIn, muIn := emIn.extensionsRead() + if mIn != nil { + mOut := emOut.extensionsWrite() + muIn.Lock() + mergeExtension(mOut, mIn) + muIn.Unlock() + } } uf := in.FieldByName("XXX_unrecognized") diff --git a/vendor/github.com/gogo/protobuf/proto/decode.go b/vendor/github.com/gogo/protobuf/proto/decode.go index 7b06266d14..737f2731d4 100644 --- a/vendor/github.com/gogo/protobuf/proto/decode.go +++ b/vendor/github.com/gogo/protobuf/proto/decode.go @@ -61,7 +61,6 @@ var ErrInternalBadWireType = errors.New("proto: internal error: bad wiretype for // int32, int64, uint32, uint64, bool, and enum // protocol buffer types. func DecodeVarint(buf []byte) (x uint64, n int) { - // x, n already 0 for shift := uint(0); shift < 64; shift += 7 { if n >= len(buf) { return 0, 0 @@ -78,13 +77,7 @@ func DecodeVarint(buf []byte) (x uint64, n int) { return 0, 0 } -// DecodeVarint reads a varint-encoded integer from the Buffer. -// This is the format for the -// int32, int64, uint32, uint64, bool, and enum -// protocol buffer types. -func (p *Buffer) DecodeVarint() (x uint64, err error) { - // x, err already 0 - +func (p *Buffer) decodeVarintSlow() (x uint64, err error) { i := p.index l := len(p.buf) @@ -107,6 +100,107 @@ func (p *Buffer) DecodeVarint() (x uint64, err error) { return } +// DecodeVarint reads a varint-encoded integer from the Buffer. +// This is the format for the +// int32, int64, uint32, uint64, bool, and enum +// protocol buffer types. +func (p *Buffer) DecodeVarint() (x uint64, err error) { + i := p.index + buf := p.buf + + if i >= len(buf) { + return 0, io.ErrUnexpectedEOF + } else if buf[i] < 0x80 { + p.index++ + return uint64(buf[i]), nil + } else if len(buf)-i < 10 { + return p.decodeVarintSlow() + } + + var b uint64 + // we already checked the first byte + x = uint64(buf[i]) - 0x80 + i++ + + b = uint64(buf[i]) + i++ + x += b << 7 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 7 + + b = uint64(buf[i]) + i++ + x += b << 14 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 14 + + b = uint64(buf[i]) + i++ + x += b << 21 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 21 + + b = uint64(buf[i]) + i++ + x += b << 28 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 28 + + b = uint64(buf[i]) + i++ + x += b << 35 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 35 + + b = uint64(buf[i]) + i++ + x += b << 42 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 42 + + b = uint64(buf[i]) + i++ + x += b << 49 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 49 + + b = uint64(buf[i]) + i++ + x += b << 56 + if b&0x80 == 0 { + goto done + } + x -= 0x80 << 56 + + b = uint64(buf[i]) + i++ + x += b << 63 + if b&0x80 == 0 { + goto done + } + // x -= 0x80 << 63 // Always zero. + + return 0, errOverflow + +done: + p.index = i + return x, nil +} + // DecodeFixed64 reads a 64-bit integer from the Buffer. // This is the format for the // fixed64, sfixed64, and double protocol buffer types. @@ -340,6 +434,8 @@ func (p *Buffer) DecodeGroup(pb Message) error { // Buffer and places the decoded result in pb. If the struct // underlying pb does not match the data in the buffer, the results can be // unpredictable. +// +// Unlike proto.Unmarshal, this does not reset pb before starting to unmarshal. func (p *Buffer) Unmarshal(pb Message) error { // If the object can unmarshal itself, let it. if u, ok := pb.(Unmarshaler); ok { @@ -378,6 +474,11 @@ func (o *Buffer) unmarshalType(st reflect.Type, prop *StructProperties, is_group wire := int(u & 0x7) if wire == WireEndGroup { if is_group { + if required > 0 { + // Not enough information to determine the exact field. + // (See below.) + return &RequiredNotSetError{"{Unknown}"} + } return nil // input is satisfied } return fmt.Errorf("proto: %s: wiretype end group for non-group", st) @@ -390,16 +491,20 @@ func (o *Buffer) unmarshalType(st reflect.Type, prop *StructProperties, is_group if !ok { // Maybe it's an extension? if prop.extendable { - if e := structPointer_Interface(base, st).(extendableProto); isExtensionField(e, int32(tag)) { - if err = o.skip(st, tag, wire); err == nil { - if ee, eok := e.(extensionsMap); eok { - ext := ee.ExtensionMap()[int32(tag)] // may be missing - ext.enc = append(ext.enc, o.buf[oi:o.index]...) - ee.ExtensionMap()[int32(tag)] = ext - } else if ee, eok := e.(extensionsBytes); eok { - ext := ee.GetExtensions() + if e, eok := structPointer_Interface(base, st).(extensionsBytes); eok { + if isExtensionField(e, int32(tag)) { + if err = o.skip(st, tag, wire); err == nil { + ext := e.GetExtensions() *ext = append(*ext, o.buf[oi:o.index]...) } + continue + } + } else if e, _ := extendable(structPointer_Interface(base, st)); isExtensionField(e, int32(tag)) { + if err = o.skip(st, tag, wire); err == nil { + extmap := e.extensionsWrite() + ext := extmap[int32(tag)] // may be missing + ext.enc = append(ext.enc, o.buf[oi:o.index]...) + extmap[int32(tag)] = ext } continue } diff --git a/vendor/github.com/gogo/protobuf/proto/decode_gogo.go b/vendor/github.com/gogo/protobuf/proto/decode_gogo.go index 603dabec3f..6fb74de4cc 100644 --- a/vendor/github.com/gogo/protobuf/proto/decode_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/decode_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are @@ -96,7 +98,7 @@ func setPtrCustomType(base structPointer, f field, v interface{}) { if v == nil { return } - structPointer_SetStructPointer(base, f, structPointer(reflect.ValueOf(v).Pointer())) + structPointer_SetStructPointer(base, f, toStructPointer(reflect.ValueOf(v))) } func setCustomType(base structPointer, f field, value interface{}) { @@ -163,7 +165,8 @@ func (o *Buffer) dec_custom_slice_bytes(p *Properties, base structPointer) error } newBas := appendStructPointer(base, p.field, p.ctype) - setCustomType(newBas, 0, custom) + var zero field + setCustomType(newBas, zero, custom) return nil } diff --git a/vendor/github.com/gogo/protobuf/proto/duration.go b/vendor/github.com/gogo/protobuf/proto/duration.go new file mode 100644 index 0000000000..93464c91cf --- /dev/null +++ b/vendor/github.com/gogo/protobuf/proto/duration.go @@ -0,0 +1,100 @@ +// Go support for Protocol Buffers - Google's data interchange format +// +// Copyright 2016 The Go Authors. All rights reserved. +// https://github.com/golang/protobuf +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package proto + +// This file implements conversions between google.protobuf.Duration +// and time.Duration. + +import ( + "errors" + "fmt" + "time" +) + +const ( + // Range of a Duration in seconds, as specified in + // google/protobuf/duration.proto. This is about 10,000 years in seconds. + maxSeconds = int64(10000 * 365.25 * 24 * 60 * 60) + minSeconds = -maxSeconds +) + +// validateDuration determines whether the Duration is valid according to the +// definition in google/protobuf/duration.proto. A valid Duration +// may still be too large to fit into a time.Duration (the range of Duration +// is about 10,000 years, and the range of time.Duration is about 290). +func validateDuration(d *duration) error { + if d == nil { + return errors.New("duration: nil Duration") + } + if d.Seconds < minSeconds || d.Seconds > maxSeconds { + return fmt.Errorf("duration: %#v: seconds out of range", d) + } + if d.Nanos <= -1e9 || d.Nanos >= 1e9 { + return fmt.Errorf("duration: %#v: nanos out of range", d) + } + // Seconds and Nanos must have the same sign, unless d.Nanos is zero. + if (d.Seconds < 0 && d.Nanos > 0) || (d.Seconds > 0 && d.Nanos < 0) { + return fmt.Errorf("duration: %#v: seconds and nanos have different signs", d) + } + return nil +} + +// DurationFromProto converts a Duration to a time.Duration. DurationFromProto +// returns an error if the Duration is invalid or is too large to be +// represented in a time.Duration. +func durationFromProto(p *duration) (time.Duration, error) { + if err := validateDuration(p); err != nil { + return 0, err + } + d := time.Duration(p.Seconds) * time.Second + if int64(d/time.Second) != p.Seconds { + return 0, fmt.Errorf("duration: %#v is out of range for time.Duration", p) + } + if p.Nanos != 0 { + d += time.Duration(p.Nanos) + if (d < 0) != (p.Nanos < 0) { + return 0, fmt.Errorf("duration: %#v is out of range for time.Duration", p) + } + } + return d, nil +} + +// DurationProto converts a time.Duration to a Duration. +func durationProto(d time.Duration) *duration { + nanos := d.Nanoseconds() + secs := nanos / 1e9 + nanos -= secs * 1e9 + return &duration{ + Seconds: secs, + Nanos: int32(nanos), + } +} diff --git a/vendor/github.com/gogo/protobuf/proto/duration_gogo.go b/vendor/github.com/gogo/protobuf/proto/duration_gogo.go new file mode 100644 index 0000000000..18e2a5f776 --- /dev/null +++ b/vendor/github.com/gogo/protobuf/proto/duration_gogo.go @@ -0,0 +1,203 @@ +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2016, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package proto + +import ( + "reflect" + "time" +) + +var durationType = reflect.TypeOf((*time.Duration)(nil)).Elem() + +type duration struct { + Seconds int64 `protobuf:"varint,1,opt,name=seconds,proto3" json:"seconds,omitempty"` + Nanos int32 `protobuf:"varint,2,opt,name=nanos,proto3" json:"nanos,omitempty"` +} + +func (m *duration) Reset() { *m = duration{} } +func (*duration) ProtoMessage() {} +func (*duration) String() string { return "duration" } + +func init() { + RegisterType((*duration)(nil), "gogo.protobuf.proto.duration") +} + +func (o *Buffer) decDuration() (time.Duration, error) { + b, err := o.DecodeRawBytes(true) + if err != nil { + return 0, err + } + dproto := &duration{} + if err := Unmarshal(b, dproto); err != nil { + return 0, err + } + return durationFromProto(dproto) +} + +func (o *Buffer) dec_duration(p *Properties, base structPointer) error { + d, err := o.decDuration() + if err != nil { + return err + } + word64_Set(structPointer_Word64(base, p.field), o, uint64(d)) + return nil +} + +func (o *Buffer) dec_ref_duration(p *Properties, base structPointer) error { + d, err := o.decDuration() + if err != nil { + return err + } + word64Val_Set(structPointer_Word64Val(base, p.field), o, uint64(d)) + return nil +} + +func (o *Buffer) dec_slice_duration(p *Properties, base structPointer) error { + d, err := o.decDuration() + if err != nil { + return err + } + newBas := appendStructPointer(base, p.field, reflect.SliceOf(reflect.PtrTo(durationType))) + var zero field + setPtrCustomType(newBas, zero, &d) + return nil +} + +func (o *Buffer) dec_slice_ref_duration(p *Properties, base structPointer) error { + d, err := o.decDuration() + if err != nil { + return err + } + structPointer_Word64Slice(base, p.field).Append(uint64(d)) + return nil +} + +func size_duration(p *Properties, base structPointer) (n int) { + structp := structPointer_GetStructPointer(base, p.field) + if structPointer_IsNil(structp) { + return 0 + } + dur := structPointer_Interface(structp, durationType).(*time.Duration) + d := durationProto(*dur) + size := Size(d) + return size + sizeVarint(uint64(size)) + len(p.tagcode) +} + +func (o *Buffer) enc_duration(p *Properties, base structPointer) error { + structp := structPointer_GetStructPointer(base, p.field) + if structPointer_IsNil(structp) { + return ErrNil + } + dur := structPointer_Interface(structp, durationType).(*time.Duration) + d := durationProto(*dur) + data, err := Marshal(d) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + return nil +} + +func size_ref_duration(p *Properties, base structPointer) (n int) { + dur := structPointer_InterfaceAt(base, p.field, durationType).(*time.Duration) + d := durationProto(*dur) + size := Size(d) + return size + sizeVarint(uint64(size)) + len(p.tagcode) +} + +func (o *Buffer) enc_ref_duration(p *Properties, base structPointer) error { + dur := structPointer_InterfaceAt(base, p.field, durationType).(*time.Duration) + d := durationProto(*dur) + data, err := Marshal(d) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + return nil +} + +func size_slice_duration(p *Properties, base structPointer) (n int) { + pdurs := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(reflect.PtrTo(durationType))).(*[]*time.Duration) + durs := *pdurs + for i := 0; i < len(durs); i++ { + if durs[i] == nil { + return 0 + } + dproto := durationProto(*durs[i]) + size := Size(dproto) + n += len(p.tagcode) + size + sizeVarint(uint64(size)) + } + return n +} + +func (o *Buffer) enc_slice_duration(p *Properties, base structPointer) error { + pdurs := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(reflect.PtrTo(durationType))).(*[]*time.Duration) + durs := *pdurs + for i := 0; i < len(durs); i++ { + if durs[i] == nil { + return errRepeatedHasNil + } + dproto := durationProto(*durs[i]) + data, err := Marshal(dproto) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + } + return nil +} + +func size_slice_ref_duration(p *Properties, base structPointer) (n int) { + pdurs := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(durationType)).(*[]time.Duration) + durs := *pdurs + for i := 0; i < len(durs); i++ { + dproto := durationProto(durs[i]) + size := Size(dproto) + n += len(p.tagcode) + size + sizeVarint(uint64(size)) + } + return n +} + +func (o *Buffer) enc_slice_ref_duration(p *Properties, base structPointer) error { + pdurs := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(durationType)).(*[]time.Duration) + durs := *pdurs + for i := 0; i < len(durs); i++ { + dproto := durationProto(durs[i]) + data, err := Marshal(dproto) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + } + return nil +} diff --git a/vendor/github.com/gogo/protobuf/proto/encode.go b/vendor/github.com/gogo/protobuf/proto/encode.go index eb7e0474ef..2b30f84626 100644 --- a/vendor/github.com/gogo/protobuf/proto/encode.go +++ b/vendor/github.com/gogo/protobuf/proto/encode.go @@ -70,6 +70,10 @@ var ( // ErrNil is the error returned if Marshal is called with nil. ErrNil = errors.New("proto: Marshal called with nil") + + // ErrTooLarge is the error returned if Marshal is called with a + // message that encodes to >2GB. + ErrTooLarge = errors.New("proto: message encodes to over 2 GB") ) // The fundamental encoders that put bytes on the wire. @@ -78,6 +82,10 @@ var ( const maxVarintBytes = 10 // maximum length of a varint +// maxMarshalSize is the largest allowed size of an encoded protobuf, +// since C++ and Java use signed int32s for the size. +const maxMarshalSize = 1<<31 - 1 + // EncodeVarint returns the varint encoding of x. // This is the format for the // int32, int64, uint32, uint64, bool, and enum @@ -226,10 +234,6 @@ func Marshal(pb Message) ([]byte, error) { } p := NewBuffer(nil) err := p.Marshal(pb) - var state errorState - if err != nil && !state.shouldContinue(err, nil) { - return nil, err - } if p.buf == nil && err == nil { // Return a non-nil slice on success. return []byte{}, nil @@ -258,11 +262,8 @@ func (p *Buffer) Marshal(pb Message) error { // Can the object marshal itself? if m, ok := pb.(Marshaler); ok { data, err := m.Marshal() - if err != nil { - return err - } p.buf = append(p.buf, data...) - return nil + return err } t, base, err := getbase(pb) @@ -274,9 +275,12 @@ func (p *Buffer) Marshal(pb Message) error { } if collectStats { - stats.Encode++ + (stats).Encode++ // Parens are to work around a goimports bug. } + if len(p.buf) > maxMarshalSize { + return ErrTooLarge + } return err } @@ -298,7 +302,7 @@ func Size(pb Message) (n int) { } if collectStats { - stats.Size++ + (stats).Size++ // Parens are to work around a goimports bug. } return @@ -1003,7 +1007,6 @@ func size_slice_struct_message(p *Properties, base structPointer) (n int) { if p.isMarshaler { m := structPointer_Interface(structp, p.stype).(Marshaler) data, _ := m.Marshal() - n += len(p.tagcode) n += sizeRawBytes(data) continue } @@ -1062,10 +1065,32 @@ func size_slice_struct_group(p *Properties, base structPointer) (n int) { // Encode an extension map. func (o *Buffer) enc_map(p *Properties, base structPointer) error { - v := *structPointer_ExtMap(base, p.field) - if err := encodeExtensionMap(v); err != nil { + exts := structPointer_ExtMap(base, p.field) + if err := encodeExtensionsMap(*exts); err != nil { return err } + + return o.enc_map_body(*exts) +} + +func (o *Buffer) enc_exts(p *Properties, base structPointer) error { + exts := structPointer_Extensions(base, p.field) + + v, mu := exts.extensionsRead() + if v == nil { + return nil + } + + mu.Lock() + defer mu.Unlock() + if err := encodeExtensionsMap(v); err != nil { + return err + } + + return o.enc_map_body(v) +} + +func (o *Buffer) enc_map_body(v map[int32]Extension) error { // Fast-path for common cases: zero or one extensions. if len(v) <= 1 { for _, e := range v { @@ -1088,8 +1113,13 @@ func (o *Buffer) enc_map(p *Properties, base structPointer) error { } func size_map(p *Properties, base structPointer) int { - v := *structPointer_ExtMap(base, p.field) - return sizeExtensionMap(v) + v := structPointer_ExtMap(base, p.field) + return extensionsMapSize(*v) +} + +func size_exts(p *Properties, base structPointer) int { + v := structPointer_Extensions(base, p.field) + return extensionsSize(v) } // Encode a map field. @@ -1118,7 +1148,7 @@ func (o *Buffer) enc_new_map(p *Properties, base structPointer) error { if err := p.mkeyprop.enc(o, p.mkeyprop, keybase); err != nil { return err } - if err := p.mvalprop.enc(o, p.mvalprop, valbase); err != nil { + if err := p.mvalprop.enc(o, p.mvalprop, valbase); err != nil && err != ErrNil { return err } return nil @@ -1128,11 +1158,6 @@ func (o *Buffer) enc_new_map(p *Properties, base structPointer) error { for _, key := range v.MapKeys() { val := v.MapIndex(key) - // The only illegal map entry values are nil message pointers. - if val.Kind() == reflect.Ptr && val.IsNil() { - return errors.New("proto: map has nil element") - } - keycopy.Set(key) valcopy.Set(val) @@ -1220,6 +1245,9 @@ func (o *Buffer) enc_struct(prop *StructProperties, base structPointer) error { return err } } + if len(o.buf) > maxMarshalSize { + return ErrTooLarge + } } } @@ -1236,6 +1264,9 @@ func (o *Buffer) enc_struct(prop *StructProperties, base structPointer) error { // Add unrecognized fields at the end. if prop.unrecField.IsValid() { v := *structPointer_Bytes(base, prop.unrecField) + if len(o.buf)+len(v) > maxMarshalSize { + return ErrTooLarge + } if len(v) > 0 { o.buf = append(o.buf, v...) } diff --git a/vendor/github.com/gogo/protobuf/proto/encode_gogo.go b/vendor/github.com/gogo/protobuf/proto/encode_gogo.go index f77cfb1eea..32111b7f41 100644 --- a/vendor/github.com/gogo/protobuf/proto/encode_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/encode_gogo.go @@ -1,7 +1,7 @@ -// Extensions for Protocol Buffers to create more go like structures. +// Protocol Buffers for Go with Gadgets // -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Go support for Protocol Buffers - Google's data interchange format // @@ -196,12 +196,10 @@ func size_ref_struct_message(p *Properties, base structPointer) int { // Encode a slice of references to message struct pointers ([]struct). func (o *Buffer) enc_slice_ref_struct_message(p *Properties, base structPointer) error { var state errorState - ss := structPointer_GetStructPointer(base, p.field) - ss1 := structPointer_GetRefStructPointer(ss, field(0)) - size := p.stype.Size() - l := structPointer_Len(base, p.field) + ss := structPointer_StructRefSlice(base, p.field, p.stype.Size()) + l := ss.Len() for i := 0; i < l; i++ { - structp := structPointer_Add(ss1, field(uintptr(i)*size)) + structp := ss.Index(i) if structPointer_IsNil(structp) { return errRepeatedHasNil } @@ -233,13 +231,11 @@ func (o *Buffer) enc_slice_ref_struct_message(p *Properties, base structPointer) //TODO this is only copied, please fix this func size_slice_ref_struct_message(p *Properties, base structPointer) (n int) { - ss := structPointer_GetStructPointer(base, p.field) - ss1 := structPointer_GetRefStructPointer(ss, field(0)) - size := p.stype.Size() - l := structPointer_Len(base, p.field) + ss := structPointer_StructRefSlice(base, p.field, p.stype.Size()) + l := ss.Len() n += l * len(p.tagcode) for i := 0; i < l; i++ { - structp := structPointer_Add(ss1, field(uintptr(i)*size)) + structp := ss.Index(i) if structPointer_IsNil(structp) { return // return the size up to this point } diff --git a/vendor/github.com/gogo/protobuf/proto/equal.go b/vendor/github.com/gogo/protobuf/proto/equal.go index f5db1def3c..2ed1cf5966 100644 --- a/vendor/github.com/gogo/protobuf/proto/equal.go +++ b/vendor/github.com/gogo/protobuf/proto/equal.go @@ -54,13 +54,17 @@ Equality is defined in this way: in a proto3 .proto file, fields are not "set"; specifically, zero length proto3 "bytes" fields are equal (nil == {}). - Two repeated fields are equal iff their lengths are the same, - and their corresponding elements are equal (a "bytes" field, - although represented by []byte, is not a repeated field) + and their corresponding elements are equal. Note a "bytes" field, + although represented by []byte, is not a repeated field and the + rule for the scalar fields described above applies. - Two unset fields are equal. - Two unknown field sets are equal if their current encoded state is equal. - Two extension sets are equal iff they have corresponding elements that are pairwise equal. + - Two map fields are equal iff their lengths are the same, + and they contain the same set of elements. Zero-length map + fields are equal. - Every other combination of things are not equal. The return value is undefined if a and b are not protocol buffers. @@ -121,9 +125,16 @@ func equalStruct(v1, v2 reflect.Value) bool { } } + if em1 := v1.FieldByName("XXX_InternalExtensions"); em1.IsValid() { + em2 := v2.FieldByName("XXX_InternalExtensions") + if !equalExtensions(v1.Type(), em1.Interface().(XXX_InternalExtensions), em2.Interface().(XXX_InternalExtensions)) { + return false + } + } + if em1 := v1.FieldByName("XXX_extensions"); em1.IsValid() { em2 := v2.FieldByName("XXX_extensions") - if !equalExtensions(v1.Type(), em1.Interface().(map[int32]Extension), em2.Interface().(map[int32]Extension)) { + if !equalExtMap(v1.Type(), em1.Interface().(map[int32]Extension), em2.Interface().(map[int32]Extension)) { return false } } @@ -184,6 +195,13 @@ func equalAny(v1, v2 reflect.Value, prop *Properties) bool { } return true case reflect.Ptr: + // Maps may have nil values in them, so check for nil. + if v1.IsNil() && v2.IsNil() { + return true + } + if v1.IsNil() != v2.IsNil() { + return false + } return equalAny(v1.Elem(), v2.Elem(), prop) case reflect.Slice: if v1.Type().Elem().Kind() == reflect.Uint8 { @@ -223,8 +241,14 @@ func equalAny(v1, v2 reflect.Value, prop *Properties) bool { } // base is the struct type that the extensions are based on. -// em1 and em2 are extension maps. -func equalExtensions(base reflect.Type, em1, em2 map[int32]Extension) bool { +// x1 and x2 are InternalExtensions. +func equalExtensions(base reflect.Type, x1, x2 XXX_InternalExtensions) bool { + em1, _ := x1.extensionsRead() + em2, _ := x2.extensionsRead() + return equalExtMap(base, em1, em2) +} + +func equalExtMap(base reflect.Type, em1, em2 map[int32]Extension) bool { if len(em1) != len(em2) { return false } diff --git a/vendor/github.com/gogo/protobuf/proto/extensions.go b/vendor/github.com/gogo/protobuf/proto/extensions.go index 6180347e39..0dfcb538e8 100644 --- a/vendor/github.com/gogo/protobuf/proto/extensions.go +++ b/vendor/github.com/gogo/protobuf/proto/extensions.go @@ -52,23 +52,112 @@ type ExtensionRange struct { Start, End int32 // both inclusive } -// extendableProto is an interface implemented by any protocol buffer that may be extended. +// extendableProto is an interface implemented by any protocol buffer generated by the current +// proto compiler that may be extended. type extendableProto interface { Message ExtensionRangeArray() []ExtensionRange + extensionsWrite() map[int32]Extension + extensionsRead() (map[int32]Extension, sync.Locker) } -type extensionsMap interface { - extendableProto +// extendableProtoV1 is an interface implemented by a protocol buffer generated by the previous +// version of the proto compiler that may be extended. +type extendableProtoV1 interface { + Message + ExtensionRangeArray() []ExtensionRange ExtensionMap() map[int32]Extension } type extensionsBytes interface { - extendableProto + Message + ExtensionRangeArray() []ExtensionRange GetExtensions() *[]byte } +// extensionAdapter is a wrapper around extendableProtoV1 that implements extendableProto. +type extensionAdapter struct { + extendableProtoV1 +} + +func (e extensionAdapter) extensionsWrite() map[int32]Extension { + return e.ExtensionMap() +} + +func (e extensionAdapter) extensionsRead() (map[int32]Extension, sync.Locker) { + return e.ExtensionMap(), notLocker{} +} + +// notLocker is a sync.Locker whose Lock and Unlock methods are nops. +type notLocker struct{} + +func (n notLocker) Lock() {} +func (n notLocker) Unlock() {} + +// extendable returns the extendableProto interface for the given generated proto message. +// If the proto message has the old extension format, it returns a wrapper that implements +// the extendableProto interface. +func extendable(p interface{}) (extendableProto, bool) { + if ep, ok := p.(extendableProto); ok { + return ep, ok + } + if ep, ok := p.(extendableProtoV1); ok { + return extensionAdapter{ep}, ok + } + return nil, false +} + +// XXX_InternalExtensions is an internal representation of proto extensions. +// +// Each generated message struct type embeds an anonymous XXX_InternalExtensions field, +// thus gaining the unexported 'extensions' method, which can be called only from the proto package. +// +// The methods of XXX_InternalExtensions are not concurrency safe in general, +// but calls to logically read-only methods such as has and get may be executed concurrently. +type XXX_InternalExtensions struct { + // The struct must be indirect so that if a user inadvertently copies a + // generated message and its embedded XXX_InternalExtensions, they + // avoid the mayhem of a copied mutex. + // + // The mutex serializes all logically read-only operations to p.extensionMap. + // It is up to the client to ensure that write operations to p.extensionMap are + // mutually exclusive with other accesses. + p *struct { + mu sync.Mutex + extensionMap map[int32]Extension + } +} + +// extensionsWrite returns the extension map, creating it on first use. +func (e *XXX_InternalExtensions) extensionsWrite() map[int32]Extension { + if e.p == nil { + e.p = new(struct { + mu sync.Mutex + extensionMap map[int32]Extension + }) + e.p.extensionMap = make(map[int32]Extension) + } + return e.p.extensionMap +} + +// extensionsRead returns the extensions map for read-only use. It may be nil. +// The caller must hold the returned mutex's lock when accessing Elements within the map. +func (e *XXX_InternalExtensions) extensionsRead() (map[int32]Extension, sync.Locker) { + if e.p == nil { + return nil, nil + } + return e.p.extensionMap, &e.p.mu +} + +type extensionRange interface { + Message + ExtensionRangeArray() []ExtensionRange +} + var extendableProtoType = reflect.TypeOf((*extendableProto)(nil)).Elem() +var extendableProtoV1Type = reflect.TypeOf((*extendableProtoV1)(nil)).Elem() +var extendableBytesType = reflect.TypeOf((*extensionsBytes)(nil)).Elem() +var extensionRangeType = reflect.TypeOf((*extensionRange)(nil)).Elem() // ExtensionDesc represents an extension specification. // Used in generated code from the protocol compiler. @@ -78,6 +167,7 @@ type ExtensionDesc struct { Field int32 // field number Name string // fully-qualified name of extension, for text formatting Tag string // protobuf tag style + Filename string // name of the file in which the extension is defined } func (ed *ExtensionDesc) repeated() bool { @@ -101,20 +191,23 @@ type Extension struct { } // SetRawExtension is for testing only. -func SetRawExtension(base extendableProto, id int32, b []byte) { - if ebase, ok := base.(extensionsMap); ok { - ebase.ExtensionMap()[id] = Extension{enc: b} - } else if ebase, ok := base.(extensionsBytes); ok { +func SetRawExtension(base Message, id int32, b []byte) { + if ebase, ok := base.(extensionsBytes); ok { clearExtension(base, id) ext := ebase.GetExtensions() *ext = append(*ext, b...) - } else { - panic("unreachable") + return + } + epb, ok := extendable(base) + if !ok { + return } + extmap := epb.extensionsWrite() + extmap[id] = Extension{enc: b} } // isExtensionField returns true iff the given field number is in an extension range. -func isExtensionField(pb extendableProto, field int32) bool { +func isExtensionField(pb extensionRange, field int32) bool { for _, er := range pb.ExtensionRangeArray() { if er.Start <= field && field <= er.End { return true @@ -125,8 +218,12 @@ func isExtensionField(pb extendableProto, field int32) bool { // checkExtensionTypes checks that the given extension is valid for pb. func checkExtensionTypes(pb extendableProto, extension *ExtensionDesc) error { + var pbi interface{} = pb // Check the extended type. - if a, b := reflect.TypeOf(pb), reflect.TypeOf(extension.ExtendedType); a != b { + if ea, ok := pbi.(extensionAdapter); ok { + pbi = ea.extendableProtoV1 + } + if a, b := reflect.TypeOf(pbi), reflect.TypeOf(extension.ExtendedType); a != b { return errors.New("proto: bad extended type; " + b.String() + " does not extend " + a.String()) } // Check the range. @@ -172,43 +269,57 @@ func extensionProperties(ed *ExtensionDesc) *Properties { return prop } -// encodeExtensionMap encodes any unmarshaled (unencoded) extensions in m. -func encodeExtensionMap(m map[int32]Extension) error { +// encode encodes any unmarshaled (unencoded) extensions in e. +func encodeExtensions(e *XXX_InternalExtensions) error { + m, mu := e.extensionsRead() + if m == nil { + return nil // fast path + } + mu.Lock() + defer mu.Unlock() + return encodeExtensionsMap(m) +} + +// encode encodes any unmarshaled (unencoded) extensions in e. +func encodeExtensionsMap(m map[int32]Extension) error { for k, e := range m { - err := encodeExtension(&e) - if err != nil { + if e.value == nil || e.desc == nil { + // Extension is only in its encoded form. + continue + } + + // We don't skip extensions that have an encoded form set, + // because the extension value may have been mutated after + // the last time this function was called. + + et := reflect.TypeOf(e.desc.ExtensionType) + props := extensionProperties(e.desc) + + p := NewBuffer(nil) + // If e.value has type T, the encoder expects a *struct{ X T }. + // Pass a *T with a zero field and hope it all works out. + x := reflect.New(et) + x.Elem().Set(reflect.ValueOf(e.value)) + if err := props.enc(p, props, toStructPointer(x)); err != nil { return err } + e.enc = p.buf m[k] = e } return nil } -func encodeExtension(e *Extension) error { - if e.value == nil || e.desc == nil { - // Extension is only in its encoded form. - return nil - } - // We don't skip extensions that have an encoded form set, - // because the extension value may have been mutated after - // the last time this function was called. - - et := reflect.TypeOf(e.desc.ExtensionType) - props := extensionProperties(e.desc) - - p := NewBuffer(nil) - // If e.value has type T, the encoder expects a *struct{ X T }. - // Pass a *T with a zero field and hope it all works out. - x := reflect.New(et) - x.Elem().Set(reflect.ValueOf(e.value)) - if err := props.enc(p, props, toStructPointer(x)); err != nil { - return err +func extensionsSize(e *XXX_InternalExtensions) (n int) { + m, mu := e.extensionsRead() + if m == nil { + return 0 } - e.enc = p.buf - return nil + mu.Lock() + defer mu.Unlock() + return extensionsMapSize(m) } -func sizeExtensionMap(m map[int32]Extension) (n int) { +func extensionsMapSize(m map[int32]Extension) (n int) { for _, e := range m { if e.value == nil || e.desc == nil { // Extension is only in its encoded form. @@ -233,12 +344,8 @@ func sizeExtensionMap(m map[int32]Extension) (n int) { } // HasExtension returns whether the given extension is present in pb. -func HasExtension(pb extendableProto, extension *ExtensionDesc) bool { - // TODO: Check types, field numbers, etc.? - if epb, doki := pb.(extensionsMap); doki { - _, ok := epb.ExtensionMap()[extension.Field] - return ok - } else if epb, doki := pb.(extensionsBytes); doki { +func HasExtension(pb Message, extension *ExtensionDesc) bool { + if epb, doki := pb.(extensionsBytes); doki { ext := epb.GetExtensions() buf := *ext o := 0 @@ -258,7 +365,19 @@ func HasExtension(pb extendableProto, extension *ExtensionDesc) bool { } return false } - panic("unreachable") + // TODO: Check types, field numbers, etc.? + epb, ok := extendable(pb) + if !ok { + return false + } + extmap, mu := epb.extensionsRead() + if extmap == nil { + return false + } + mu.Lock() + _, ok = extmap[extension.Field] + mu.Unlock() + return ok } func deleteExtension(pb extensionsBytes, theFieldNum int32, offset int) int { @@ -281,64 +400,32 @@ func deleteExtension(pb extensionsBytes, theFieldNum int32, offset int) int { return -1 } -func clearExtension(pb extendableProto, fieldNum int32) { - if epb, doki := pb.(extensionsMap); doki { - delete(epb.ExtensionMap(), fieldNum) - } else if epb, doki := pb.(extensionsBytes); doki { +// ClearExtension removes the given extension from pb. +func ClearExtension(pb Message, extension *ExtensionDesc) { + clearExtension(pb, extension.Field) +} + +func clearExtension(pb Message, fieldNum int32) { + if epb, doki := pb.(extensionsBytes); doki { offset := 0 for offset != -1 { offset = deleteExtension(epb, fieldNum, offset) } - } else { - panic("unreachable") + return + } + epb, ok := extendable(pb) + if !ok { + return } -} - -// ClearExtension removes the given extension from pb. -func ClearExtension(pb extendableProto, extension *ExtensionDesc) { // TODO: Check types, field numbers, etc.? - clearExtension(pb, extension.Field) + extmap := epb.extensionsWrite() + delete(extmap, fieldNum) } // GetExtension parses and returns the given extension of pb. -// If the extension is not present it returns ErrMissingExtension. -func GetExtension(pb extendableProto, extension *ExtensionDesc) (interface{}, error) { - if err := checkExtensionTypes(pb, extension); err != nil { - return nil, err - } - - if epb, doki := pb.(extensionsMap); doki { - emap := epb.ExtensionMap() - e, ok := emap[extension.Field] - if !ok { - // defaultExtensionValue returns the default value or - // ErrMissingExtension if there is no default. - return defaultExtensionValue(extension) - } - if e.value != nil { - // Already decoded. Check the descriptor, though. - if e.desc != extension { - // This shouldn't happen. If it does, it means that - // GetExtension was called twice with two different - // descriptors with the same field number. - return nil, errors.New("proto: descriptor conflict") - } - return e.value, nil - } - - v, err := decodeExtension(e.enc, extension) - if err != nil { - return nil, err - } - - // Remember the decoded version and drop the encoded version. - // That way it is safe to mutate what we return. - e.value = v - e.desc = extension - e.enc = nil - emap[extension.Field] = e - return e.value, nil - } else if epb, doki := pb.(extensionsBytes); doki { +// If the extension is not present and has no default value it returns ErrMissingExtension. +func GetExtension(pb Message, extension *ExtensionDesc) (interface{}, error) { + if epb, doki := pb.(extensionsBytes); doki { ext := epb.GetExtensions() o := 0 for o < len(*ext) { @@ -360,7 +447,50 @@ func GetExtension(pb extendableProto, extension *ExtensionDesc) (interface{}, er } return defaultExtensionValue(extension) } - panic("unreachable") + epb, ok := extendable(pb) + if !ok { + return nil, errors.New("proto: not an extendable proto") + } + if err := checkExtensionTypes(epb, extension); err != nil { + return nil, err + } + + emap, mu := epb.extensionsRead() + if emap == nil { + return defaultExtensionValue(extension) + } + mu.Lock() + defer mu.Unlock() + e, ok := emap[extension.Field] + if !ok { + // defaultExtensionValue returns the default value or + // ErrMissingExtension if there is no default. + return defaultExtensionValue(extension) + } + + if e.value != nil { + // Already decoded. Check the descriptor, though. + if e.desc != extension { + // This shouldn't happen. If it does, it means that + // GetExtension was called twice with two different + // descriptors with the same field number. + return nil, errors.New("proto: descriptor conflict") + } + return e.value, nil + } + + v, err := decodeExtension(e.enc, extension) + if err != nil { + return nil, err + } + + // Remember the decoded version and drop the encoded version. + // That way it is safe to mutate what we return. + e.value = v + e.desc = extension + e.enc = nil + emap[extension.Field] = e + return e.value, nil } // defaultExtensionValue returns the default value for extension. @@ -434,14 +564,9 @@ func decodeExtension(b []byte, extension *ExtensionDesc) (interface{}, error) { // GetExtensions returns a slice of the extensions present in pb that are also listed in es. // The returned slice has the same length as es; missing extensions will appear as nil elements. func GetExtensions(pb Message, es []*ExtensionDesc) (extensions []interface{}, err error) { - epb, ok := pb.(extendableProto) - if !ok { - err = errors.New("proto: not an extendable proto") - return - } extensions = make([]interface{}, len(es)) for i, e := range es { - extensions[i], err = GetExtension(epb, e) + extensions[i], err = GetExtension(pb, e) if err == ErrMissingExtension { err = nil } @@ -452,9 +577,58 @@ func GetExtensions(pb Message, es []*ExtensionDesc) (extensions []interface{}, e return } +// ExtensionDescs returns a new slice containing pb's extension descriptors, in undefined order. +// For non-registered extensions, ExtensionDescs returns an incomplete descriptor containing +// just the Field field, which defines the extension's field number. +func ExtensionDescs(pb Message) ([]*ExtensionDesc, error) { + epb, ok := extendable(pb) + if !ok { + return nil, fmt.Errorf("proto: %T is not an extendable proto.Message", pb) + } + registeredExtensions := RegisteredExtensions(pb) + + emap, mu := epb.extensionsRead() + if emap == nil { + return nil, nil + } + mu.Lock() + defer mu.Unlock() + extensions := make([]*ExtensionDesc, 0, len(emap)) + for extid, e := range emap { + desc := e.desc + if desc == nil { + desc = registeredExtensions[extid] + if desc == nil { + desc = &ExtensionDesc{Field: extid} + } + } + + extensions = append(extensions, desc) + } + return extensions, nil +} + // SetExtension sets the specified extension of pb to the specified value. -func SetExtension(pb extendableProto, extension *ExtensionDesc, value interface{}) error { - if err := checkExtensionTypes(pb, extension); err != nil { +func SetExtension(pb Message, extension *ExtensionDesc, value interface{}) error { + if epb, doki := pb.(extensionsBytes); doki { + ClearExtension(pb, extension) + ext := epb.GetExtensions() + et := reflect.TypeOf(extension.ExtensionType) + props := extensionProperties(extension) + p := NewBuffer(nil) + x := reflect.New(et) + x.Elem().Set(reflect.ValueOf(value)) + if err := props.enc(p, props, toStructPointer(x)); err != nil { + return err + } + *ext = append(*ext, p.buf...) + return nil + } + epb, ok := extendable(pb) + if !ok { + return errors.New("proto: not an extendable proto") + } + if err := checkExtensionTypes(epb, extension); err != nil { return err } typ := reflect.TypeOf(extension.ExtensionType) @@ -469,26 +643,27 @@ func SetExtension(pb extendableProto, extension *ExtensionDesc, value interface{ if reflect.ValueOf(value).IsNil() { return fmt.Errorf("proto: SetExtension called with nil value of type %T", value) } - return setExtension(pb, extension, value) + + extmap := epb.extensionsWrite() + extmap[extension.Field] = Extension{desc: extension, value: value} + return nil } -func setExtension(pb extendableProto, extension *ExtensionDesc, value interface{}) error { - if epb, doki := pb.(extensionsMap); doki { - epb.ExtensionMap()[extension.Field] = Extension{desc: extension, value: value} - } else if epb, doki := pb.(extensionsBytes); doki { - ClearExtension(pb, extension) +// ClearAllExtensions clears all extensions from pb. +func ClearAllExtensions(pb Message) { + if epb, doki := pb.(extensionsBytes); doki { ext := epb.GetExtensions() - et := reflect.TypeOf(extension.ExtensionType) - props := extensionProperties(extension) - p := NewBuffer(nil) - x := reflect.New(et) - x.Elem().Set(reflect.ValueOf(value)) - if err := props.enc(p, props, toStructPointer(x)); err != nil { - return err - } - *ext = append(*ext, p.buf...) + *ext = []byte{} + return + } + epb, ok := extendable(pb) + if !ok { + return + } + m := epb.extensionsWrite() + for k := range m { + delete(m, k) } - return nil } // A global registry of extensions. diff --git a/vendor/github.com/gogo/protobuf/proto/extensions_gogo.go b/vendor/github.com/gogo/protobuf/proto/extensions_gogo.go index 86b1fa2344..ea6478f009 100644 --- a/vendor/github.com/gogo/protobuf/proto/extensions_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/extensions_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are @@ -33,9 +35,10 @@ import ( "reflect" "sort" "strings" + "sync" ) -func GetBoolExtension(pb extendableProto, extension *ExtensionDesc, ifnotset bool) bool { +func GetBoolExtension(pb Message, extension *ExtensionDesc, ifnotset bool) bool { if reflect.ValueOf(pb).IsNil() { return ifnotset } @@ -60,8 +63,12 @@ func (this *Extension) Compare(that *Extension) int { return bytes.Compare(this.enc, that.enc) } +func SizeOfInternalExtension(m extendableProto) (n int) { + return SizeOfExtensionMap(m.extensionsWrite()) +} + func SizeOfExtensionMap(m map[int32]Extension) (n int) { - return sizeExtensionMap(m) + return extensionsMapSize(m) } type sortableMapElem struct { @@ -94,6 +101,10 @@ func (this sortableExtensions) String() string { return "map[" + strings.Join(ss, ",") + "]" } +func StringFromInternalExtension(m extendableProto) string { + return StringFromExtensionsMap(m.extensionsWrite()) +} + func StringFromExtensionsMap(m map[int32]Extension) string { return newSortableExtensionsFromMap(m).String() } @@ -106,8 +117,12 @@ func StringFromExtensionsBytes(ext []byte) string { return StringFromExtensionsMap(m) } +func EncodeInternalExtension(m extendableProto, data []byte) (n int, err error) { + return EncodeExtensionMap(m.extensionsWrite(), data) +} + func EncodeExtensionMap(m map[int32]Extension, data []byte) (n int, err error) { - if err := encodeExtensionMap(m); err != nil { + if err := encodeExtensionsMap(m); err != nil { return 0, err } keys := make([]int, 0, len(m)) @@ -125,7 +140,7 @@ func GetRawExtension(m map[int32]Extension, id int32) ([]byte, error) { if m[id].value == nil || m[id].desc == nil { return m[id].enc, nil } - if err := encodeExtensionMap(m); err != nil { + if err := encodeExtensionsMap(m); err != nil { return nil, err } return m[id].enc, nil @@ -189,17 +204,44 @@ func NewExtension(e []byte) Extension { return ee } -func AppendExtension(e extendableProto, tag int32, buf []byte) { - if ee, eok := e.(extensionsMap); eok { - ext := ee.ExtensionMap()[int32(tag)] // may be missing - ext.enc = append(ext.enc, buf...) - ee.ExtensionMap()[int32(tag)] = ext - } else if ee, eok := e.(extensionsBytes); eok { +func AppendExtension(e Message, tag int32, buf []byte) { + if ee, eok := e.(extensionsBytes); eok { ext := ee.GetExtensions() *ext = append(*ext, buf...) + return + } + if ee, eok := e.(extendableProto); eok { + m := ee.extensionsWrite() + ext := m[int32(tag)] // may be missing + ext.enc = append(ext.enc, buf...) + m[int32(tag)] = ext } } +func encodeExtension(e *Extension) error { + if e.value == nil || e.desc == nil { + // Extension is only in its encoded form. + return nil + } + // We don't skip extensions that have an encoded form set, + // because the extension value may have been mutated after + // the last time this function was called. + + et := reflect.TypeOf(e.desc.ExtensionType) + props := extensionProperties(e.desc) + + p := NewBuffer(nil) + // If e.value has type T, the encoder expects a *struct{ X T }. + // Pass a *T with a zero field and hope it all works out. + x := reflect.New(et) + x.Elem().Set(reflect.ValueOf(e.value)) + if err := props.enc(p, props, toStructPointer(x)); err != nil { + return err + } + e.enc = p.buf + return nil +} + func (this Extension) GoString() string { if this.enc == nil { if err := encodeExtension(&this); err != nil { @@ -209,7 +251,7 @@ func (this Extension) GoString() string { return fmt.Sprintf("proto.NewExtension(%#v)", this.enc) } -func SetUnsafeExtension(pb extendableProto, fieldNum int32, value interface{}) error { +func SetUnsafeExtension(pb Message, fieldNum int32, value interface{}) error { typ := reflect.TypeOf(pb).Elem() ext, ok := extensionMaps[typ] if !ok { @@ -219,10 +261,10 @@ func SetUnsafeExtension(pb extendableProto, fieldNum int32, value interface{}) e if !ok { return errors.New("proto: bad extension number; not in declared ranges") } - return setExtension(pb, desc, value) + return SetExtension(pb, desc, value) } -func GetUnsafeExtension(pb extendableProto, fieldNum int32) (interface{}, error) { +func GetUnsafeExtension(pb Message, fieldNum int32) (interface{}, error) { typ := reflect.TypeOf(pb).Elem() ext, ok := extensionMaps[typ] if !ok { @@ -234,3 +276,19 @@ func GetUnsafeExtension(pb extendableProto, fieldNum int32) (interface{}, error) } return GetExtension(pb, desc) } + +func NewUnsafeXXX_InternalExtensions(m map[int32]Extension) XXX_InternalExtensions { + x := &XXX_InternalExtensions{ + p: new(struct { + mu sync.Mutex + extensionMap map[int32]Extension + }), + } + x.p.extensionMap = m + return *x +} + +func GetUnsafeExtensionsMap(extendable Message) map[int32]Extension { + pb := extendable.(extendableProto) + return pb.extensionsWrite() +} diff --git a/vendor/github.com/gogo/protobuf/proto/lib.go b/vendor/github.com/gogo/protobuf/proto/lib.go index 2e35ae2d2a..7580bb45c6 100644 --- a/vendor/github.com/gogo/protobuf/proto/lib.go +++ b/vendor/github.com/gogo/protobuf/proto/lib.go @@ -308,7 +308,7 @@ func GetStats() Stats { return stats } // temporary Buffer and are fine for most applications. type Buffer struct { buf []byte // encode/decode byte stream - index int // write point + index int // read point // pools of basic types to amortize allocation. bools []bool @@ -889,6 +889,10 @@ func isProto3Zero(v reflect.Value) bool { return false } +// ProtoPackageIsVersion2 is referenced from generated protocol buffer files +// to assert that that code is compatible with this version of the proto package. +const GoGoProtoPackageIsVersion2 = true + // ProtoPackageIsVersion1 is referenced from generated protocol buffer files // to assert that that code is compatible with this version of the proto package. const GoGoProtoPackageIsVersion1 = true diff --git a/vendor/github.com/gogo/protobuf/proto/lib_gogo.go b/vendor/github.com/gogo/protobuf/proto/lib_gogo.go index a6c2c06b23..4b4f7c909e 100644 --- a/vendor/github.com/gogo/protobuf/proto/lib_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/lib_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are diff --git a/vendor/github.com/gogo/protobuf/proto/message_set.go b/vendor/github.com/gogo/protobuf/proto/message_set.go index e25e01e637..fd982decd6 100644 --- a/vendor/github.com/gogo/protobuf/proto/message_set.go +++ b/vendor/github.com/gogo/protobuf/proto/message_set.go @@ -149,9 +149,21 @@ func skipVarint(buf []byte) []byte { // MarshalMessageSet encodes the extension map represented by m in the message set wire format. // It is called by generated Marshal methods on protocol buffer messages with the message_set_wire_format option. -func MarshalMessageSet(m map[int32]Extension) ([]byte, error) { - if err := encodeExtensionMap(m); err != nil { - return nil, err +func MarshalMessageSet(exts interface{}) ([]byte, error) { + var m map[int32]Extension + switch exts := exts.(type) { + case *XXX_InternalExtensions: + if err := encodeExtensions(exts); err != nil { + return nil, err + } + m, _ = exts.extensionsRead() + case map[int32]Extension: + if err := encodeExtensionsMap(exts); err != nil { + return nil, err + } + m = exts + default: + return nil, errors.New("proto: not an extension map") } // Sort extension IDs to provide a deterministic encoding. @@ -178,7 +190,17 @@ func MarshalMessageSet(m map[int32]Extension) ([]byte, error) { // UnmarshalMessageSet decodes the extension map encoded in buf in the message set wire format. // It is called by generated Unmarshal methods on protocol buffer messages with the message_set_wire_format option. -func UnmarshalMessageSet(buf []byte, m map[int32]Extension) error { +func UnmarshalMessageSet(buf []byte, exts interface{}) error { + var m map[int32]Extension + switch exts := exts.(type) { + case *XXX_InternalExtensions: + m = exts.extensionsWrite() + case map[int32]Extension: + m = exts + default: + return errors.New("proto: not an extension map") + } + ms := new(messageSet) if err := Unmarshal(buf, ms); err != nil { return err @@ -209,7 +231,16 @@ func UnmarshalMessageSet(buf []byte, m map[int32]Extension) error { // MarshalMessageSetJSON encodes the extension map represented by m in JSON format. // It is called by generated MarshalJSON methods on protocol buffer messages with the message_set_wire_format option. -func MarshalMessageSetJSON(m map[int32]Extension) ([]byte, error) { +func MarshalMessageSetJSON(exts interface{}) ([]byte, error) { + var m map[int32]Extension + switch exts := exts.(type) { + case *XXX_InternalExtensions: + m, _ = exts.extensionsRead() + case map[int32]Extension: + m = exts + default: + return nil, errors.New("proto: not an extension map") + } var b bytes.Buffer b.WriteByte('{') @@ -252,7 +283,7 @@ func MarshalMessageSetJSON(m map[int32]Extension) ([]byte, error) { // UnmarshalMessageSetJSON decodes the extension map encoded in buf in JSON format. // It is called by generated UnmarshalJSON methods on protocol buffer messages with the message_set_wire_format option. -func UnmarshalMessageSetJSON(buf []byte, m map[int32]Extension) error { +func UnmarshalMessageSetJSON(buf []byte, exts interface{}) error { // Common-case fast path. if len(buf) == 0 || bytes.Equal(buf, []byte("{}")) { return nil diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go b/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go index 749919d250..fb512e2e16 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_reflect.go @@ -29,7 +29,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +build appengine +// +build appengine js // This file contains an implementation of proto field accesses using package reflect. // It is slower than the code in pointer_unsafe.go but it avoids package unsafe and can @@ -139,6 +139,11 @@ func structPointer_StringSlice(p structPointer, f field) *[]string { return structPointer_ifield(p, f).(*[]string) } +// Extensions returns the address of an extension map field in the struct. +func structPointer_Extensions(p structPointer, f field) *XXX_InternalExtensions { + return structPointer_ifield(p, f).(*XXX_InternalExtensions) +} + // ExtMap returns the address of an extension map field in the struct. func structPointer_ExtMap(p structPointer, f field) *map[int32]Extension { return structPointer_ifield(p, f).(*map[int32]Extension) diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go b/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go new file mode 100644 index 0000000000..1763a5f227 --- /dev/null +++ b/vendor/github.com/gogo/protobuf/proto/pointer_reflect_gogo.go @@ -0,0 +1,85 @@ +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2016, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +// +build appengine js + +package proto + +import ( + "reflect" +) + +func structPointer_FieldPointer(p structPointer, f field) structPointer { + panic("not implemented") +} + +func appendStructPointer(base structPointer, f field, typ reflect.Type) structPointer { + panic("not implemented") +} + +func structPointer_InterfaceAt(p structPointer, f field, t reflect.Type) interface{} { + panic("not implemented") +} + +func structPointer_InterfaceRef(p structPointer, f field, t reflect.Type) interface{} { + panic("not implemented") +} + +func structPointer_GetRefStructPointer(p structPointer, f field) structPointer { + panic("not implemented") +} + +func structPointer_Add(p structPointer, size field) structPointer { + panic("not implemented") +} + +func structPointer_Len(p structPointer, f field) int { + panic("not implemented") +} + +func structPointer_GetSliceHeader(p structPointer, f field) *reflect.SliceHeader { + panic("not implemented") +} + +func structPointer_Copy(oldptr structPointer, newptr structPointer, size int) { + panic("not implemented") +} + +func structPointer_StructRefSlice(p structPointer, f field, size uintptr) *structRefSlice { + panic("not implemented") +} + +type structRefSlice struct{} + +func (v *structRefSlice) Len() int { + panic("not implemented") +} + +func (v *structRefSlice) Index(i int) structPointer { + panic("not implemented") +} diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go index e9be0fe92e..6b5567d47c 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe.go @@ -29,7 +29,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +build !appengine +// +build !appengine,!js // This file contains the implementation of the proto field accesses using package unsafe. @@ -126,6 +126,10 @@ func structPointer_StringSlice(p structPointer, f field) *[]string { } // ExtMap returns the address of an extension map field in the struct. +func structPointer_Extensions(p structPointer, f field) *XXX_InternalExtensions { + return (*XXX_InternalExtensions)(unsafe.Pointer(uintptr(p) + uintptr(f))) +} + func structPointer_ExtMap(p structPointer, f field) *map[int32]Extension { return (*map[int32]Extension)(unsafe.Pointer(uintptr(p) + uintptr(f))) } diff --git a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go index 6bc85fa987..f156a29f0e 100644 --- a/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/pointer_unsafe_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are @@ -24,7 +26,7 @@ // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -// +build !appengine +// +build !appengine,!js // This file contains the implementation of the proto field accesses using package unsafe. @@ -70,16 +72,13 @@ func structPointer_Copy(oldptr structPointer, newptr structPointer, size int) { func appendStructPointer(base structPointer, f field, typ reflect.Type) structPointer { size := typ.Elem().Size() + oldHeader := structPointer_GetSliceHeader(base, f) + oldSlice := reflect.NewAt(typ, unsafe.Pointer(oldHeader)).Elem() newLen := oldHeader.Len + 1 - slice := reflect.MakeSlice(typ, newLen, newLen) - bas := toStructPointer(slice) - for i := 0; i < oldHeader.Len; i++ { - newElemptr := uintptr(bas) + uintptr(i)*size - oldElemptr := oldHeader.Data + uintptr(i)*size - copyUintPtr(oldElemptr, newElemptr, int(size)) - } - + newSlice := reflect.MakeSlice(typ, newLen, newLen) + reflect.Copy(newSlice, oldSlice) + bas := toStructPointer(newSlice) oldHeader.Data = uintptr(bas) oldHeader.Len = newLen oldHeader.Cap = newLen @@ -106,3 +105,24 @@ func structPointer_Add(p structPointer, size field) structPointer { func structPointer_Len(p structPointer, f field) int { return len(*(*[]interface{})(unsafe.Pointer(structPointer_GetRefStructPointer(p, f)))) } + +func structPointer_StructRefSlice(p structPointer, f field, size uintptr) *structRefSlice { + return &structRefSlice{p: p, f: f, size: size} +} + +// A structRefSlice represents a slice of structs (themselves submessages or groups). +type structRefSlice struct { + p structPointer + f field + size uintptr +} + +func (v *structRefSlice) Len() int { + return structPointer_Len(v.p, v.f) +} + +func (v *structRefSlice) Index(i int) structPointer { + ss := structPointer_GetStructPointer(v.p, v.f) + ss1 := structPointer_GetRefStructPointer(ss, 0) + return structPointer_Add(ss1, field(uintptr(i)*v.size)) +} diff --git a/vendor/github.com/gogo/protobuf/proto/properties.go b/vendor/github.com/gogo/protobuf/proto/properties.go index 5e6a0b3ba7..44b332052e 100644 --- a/vendor/github.com/gogo/protobuf/proto/properties.go +++ b/vendor/github.com/gogo/protobuf/proto/properties.go @@ -1,7 +1,7 @@ -// Extensions for Protocol Buffers to create more go like structures. +// Protocol Buffers for Go with Gadgets // -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Go support for Protocol Buffers - Google's data interchange format // @@ -190,10 +190,11 @@ type Properties struct { proto3 bool // whether this is known to be a proto3 field; set for []byte only oneof bool // whether this is a oneof field - Default string // default value - HasDefault bool // whether an explicit default was provided - CustomType string - def_uint64 uint64 + Default string // default value + HasDefault bool // whether an explicit default was provided + CustomType string + StdTime bool + StdDuration bool enc encoder valEnc valueEncoder // set for bool and numeric types only @@ -340,6 +341,10 @@ func (p *Properties) Parse(s string) { p.OrigName = strings.Split(f, "=")[1] case strings.HasPrefix(f, "customtype="): p.CustomType = strings.Split(f, "=")[1] + case f == "stdtime": + p.StdTime = true + case f == "stdduration": + p.StdDuration = true } } } @@ -355,11 +360,22 @@ func (p *Properties) setEncAndDec(typ reflect.Type, f *reflect.StructField, lock p.enc = nil p.dec = nil p.size = nil - if len(p.CustomType) > 0 { + isMap := typ.Kind() == reflect.Map + if len(p.CustomType) > 0 && !isMap { p.setCustomEncAndDec(typ) p.setTag(lockGetProp) return } + if p.StdTime && !isMap { + p.setTimeEncAndDec(typ) + p.setTag(lockGetProp) + return + } + if p.StdDuration && !isMap { + p.setDurationEncAndDec(typ) + p.setTag(lockGetProp) + return + } switch t1 := typ; t1.Kind() { default: fmt.Fprintf(os.Stderr, "proto: no coders for %v\n", t1) @@ -542,17 +558,13 @@ func (p *Properties) setEncAndDec(typ reflect.Type, f *reflect.StructField, lock p.dec = (*Buffer).dec_slice_int64 p.packedDec = (*Buffer).dec_slice_packed_int64 case reflect.Uint8: - p.enc = (*Buffer).enc_slice_byte p.dec = (*Buffer).dec_slice_byte - p.size = size_slice_byte - // This is a []byte, which is either a bytes field, - // or the value of a map field. In the latter case, - // we always encode an empty []byte, so we should not - // use the proto3 enc/size funcs. - // f == nil iff this is the key/value of a map field. - if p.proto3 && f != nil { + if p.proto3 { p.enc = (*Buffer).enc_proto3_slice_byte p.size = size_proto3_slice_byte + } else { + p.enc = (*Buffer).enc_slice_byte + p.size = size_slice_byte } case reflect.Float32, reflect.Float64: switch t2.Bits() { @@ -634,6 +646,10 @@ func (p *Properties) setEncAndDec(typ reflect.Type, f *reflect.StructField, lock // so we need encoders for the pointer to this type. vtype = reflect.PtrTo(vtype) } + + p.mvalprop.CustomType = p.CustomType + p.mvalprop.StdDuration = p.StdDuration + p.mvalprop.StdTime = p.StdTime p.mvalprop.init(vtype, "Value", f.Tag.Get("protobuf_val"), nil, lockGetProp) } p.setTag(lockGetProp) @@ -744,7 +760,9 @@ func getPropertiesLocked(t reflect.Type) *StructProperties { propertiesMap[t] = prop // build properties - prop.extendable = reflect.PtrTo(t).Implements(extendableProtoType) + prop.extendable = reflect.PtrTo(t).Implements(extendableProtoType) || + reflect.PtrTo(t).Implements(extendableProtoV1Type) || + reflect.PtrTo(t).Implements(extendableBytesType) prop.unrecField = invalidField prop.Prop = make([]*Properties, t.NumField()) prop.order = make([]int, t.NumField()) @@ -756,7 +774,11 @@ func getPropertiesLocked(t reflect.Type) *StructProperties { name := f.Name p.init(f.Type, name, f.Tag.Get("protobuf"), &f, false) - if f.Name == "XXX_extensions" { // special case + if f.Name == "XXX_InternalExtensions" { // special case + p.enc = (*Buffer).enc_exts + p.dec = nil // not needed + p.size = size_exts + } else if f.Name == "XXX_extensions" { // special case if len(f.Tag.Get("protobuf")) > 0 { p.enc = (*Buffer).enc_ext_slice_byte p.dec = nil // not needed @@ -766,13 +788,14 @@ func getPropertiesLocked(t reflect.Type) *StructProperties { p.dec = nil // not needed p.size = size_map } - } - if f.Name == "XXX_unrecognized" { // special case + } else if f.Name == "XXX_unrecognized" { // special case prop.unrecField = toField(&f) } - oneof := f.Tag.Get("protobuf_oneof") != "" // special case - if oneof { + oneof := f.Tag.Get("protobuf_oneof") // special case + if oneof != "" { isOneofMessage = true + // Oneof fields don't use the traditional protobuf tag. + p.OrigName = oneof } prop.Prop[i] = p prop.order[i] = i @@ -783,7 +806,7 @@ func getPropertiesLocked(t reflect.Type) *StructProperties { } print("\n") } - if p.enc == nil && !strings.HasPrefix(f.Name, "XXX_") && !oneof { + if p.enc == nil && !strings.HasPrefix(f.Name, "XXX_") && oneof == "" { fmt.Fprintln(os.Stderr, "proto: no encoder for", f.Name, f.Type.String(), "[GetProperties]") } } @@ -917,7 +940,29 @@ func RegisterType(x Message, name string) { } // MessageName returns the fully-qualified proto name for the given message type. -func MessageName(x Message) string { return revProtoTypes[reflect.TypeOf(x)] } +func MessageName(x Message) string { + type xname interface { + XXX_MessageName() string + } + if m, ok := x.(xname); ok { + return m.XXX_MessageName() + } + return revProtoTypes[reflect.TypeOf(x)] +} // MessageType returns the message type (pointer to struct) for a named message. func MessageType(name string) reflect.Type { return protoTypes[name] } + +// A registry of all linked proto files. +var ( + protoFiles = make(map[string][]byte) // file name => fileDescriptor +) + +// RegisterFile is called from generated code and maps from the +// full file name of a .proto file to its compressed FileDescriptorProto. +func RegisterFile(filename string, fileDescriptor []byte) { + protoFiles[filename] = fileDescriptor +} + +// FileDescriptor returns the compressed FileDescriptorProto for a .proto file. +func FileDescriptor(filename string) []byte { return protoFiles[filename] } diff --git a/vendor/github.com/gogo/protobuf/proto/properties_gogo.go b/vendor/github.com/gogo/protobuf/proto/properties_gogo.go index 8daf9f7768..b6b7176c56 100644 --- a/vendor/github.com/gogo/protobuf/proto/properties_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/properties_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are @@ -49,6 +51,51 @@ func (p *Properties) setCustomEncAndDec(typ reflect.Type) { } } +func (p *Properties) setDurationEncAndDec(typ reflect.Type) { + if p.Repeated { + if typ.Elem().Kind() == reflect.Ptr { + p.enc = (*Buffer).enc_slice_duration + p.dec = (*Buffer).dec_slice_duration + p.size = size_slice_duration + } else { + p.enc = (*Buffer).enc_slice_ref_duration + p.dec = (*Buffer).dec_slice_ref_duration + p.size = size_slice_ref_duration + } + } else if typ.Kind() == reflect.Ptr { + p.enc = (*Buffer).enc_duration + p.dec = (*Buffer).dec_duration + p.size = size_duration + } else { + p.enc = (*Buffer).enc_ref_duration + p.dec = (*Buffer).dec_ref_duration + p.size = size_ref_duration + } +} + +func (p *Properties) setTimeEncAndDec(typ reflect.Type) { + if p.Repeated { + if typ.Elem().Kind() == reflect.Ptr { + p.enc = (*Buffer).enc_slice_time + p.dec = (*Buffer).dec_slice_time + p.size = size_slice_time + } else { + p.enc = (*Buffer).enc_slice_ref_time + p.dec = (*Buffer).dec_slice_ref_time + p.size = size_slice_ref_time + } + } else if typ.Kind() == reflect.Ptr { + p.enc = (*Buffer).enc_time + p.dec = (*Buffer).dec_time + p.size = size_time + } else { + p.enc = (*Buffer).enc_ref_time + p.dec = (*Buffer).dec_ref_time + p.size = size_ref_time + } + +} + func (p *Properties) setSliceOfNonPointerStructs(typ reflect.Type) { t2 := typ.Elem() p.sstype = typ diff --git a/vendor/github.com/gogo/protobuf/proto/skip_gogo.go b/vendor/github.com/gogo/protobuf/proto/skip_gogo.go index 4fe7e0815c..5a5fd93f7c 100644 --- a/vendor/github.com/gogo/protobuf/proto/skip_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/skip_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are diff --git a/vendor/github.com/gogo/protobuf/proto/text.go b/vendor/github.com/gogo/protobuf/proto/text.go index b60be28ab0..d63732fcbd 100644 --- a/vendor/github.com/gogo/protobuf/proto/text.go +++ b/vendor/github.com/gogo/protobuf/proto/text.go @@ -1,7 +1,7 @@ -// Extensions for Protocol Buffers to create more go like structures. +// Protocol Buffers for Go with Gadgets // -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Go support for Protocol Buffers - Google's data interchange format // @@ -50,6 +50,8 @@ import ( "reflect" "sort" "strings" + "sync" + "time" ) var ( @@ -159,7 +161,7 @@ func (w *textWriter) indent() { w.ind++ } func (w *textWriter) unindent() { if w.ind == 0 { - log.Printf("proto: textWriter unindented too far") + log.Print("proto: textWriter unindented too far") return } w.ind-- @@ -180,7 +182,93 @@ type raw interface { Bytes() []byte } -func writeStruct(w *textWriter, sv reflect.Value) error { +func requiresQuotes(u string) bool { + // When type URL contains any characters except [0-9A-Za-z./\-]*, it must be quoted. + for _, ch := range u { + switch { + case ch == '.' || ch == '/' || ch == '_': + continue + case '0' <= ch && ch <= '9': + continue + case 'A' <= ch && ch <= 'Z': + continue + case 'a' <= ch && ch <= 'z': + continue + default: + return true + } + } + return false +} + +// isAny reports whether sv is a google.protobuf.Any message +func isAny(sv reflect.Value) bool { + type wkt interface { + XXX_WellKnownType() string + } + t, ok := sv.Addr().Interface().(wkt) + return ok && t.XXX_WellKnownType() == "Any" +} + +// writeProto3Any writes an expanded google.protobuf.Any message. +// +// It returns (false, nil) if sv value can't be unmarshaled (e.g. because +// required messages are not linked in). +// +// It returns (true, error) when sv was written in expanded format or an error +// was encountered. +func (tm *TextMarshaler) writeProto3Any(w *textWriter, sv reflect.Value) (bool, error) { + turl := sv.FieldByName("TypeUrl") + val := sv.FieldByName("Value") + if !turl.IsValid() || !val.IsValid() { + return true, errors.New("proto: invalid google.protobuf.Any message") + } + + b, ok := val.Interface().([]byte) + if !ok { + return true, errors.New("proto: invalid google.protobuf.Any message") + } + + parts := strings.Split(turl.String(), "/") + mt := MessageType(parts[len(parts)-1]) + if mt == nil { + return false, nil + } + m := reflect.New(mt.Elem()) + if err := Unmarshal(b, m.Interface().(Message)); err != nil { + return false, nil + } + w.Write([]byte("[")) + u := turl.String() + if requiresQuotes(u) { + writeString(w, u) + } else { + w.Write([]byte(u)) + } + if w.compact { + w.Write([]byte("]:<")) + } else { + w.Write([]byte("]: <\n")) + w.ind++ + } + if err := tm.writeStruct(w, m.Elem()); err != nil { + return true, err + } + if w.compact { + w.Write([]byte("> ")) + } else { + w.ind-- + w.Write([]byte(">\n")) + } + return true, nil +} + +func (tm *TextMarshaler) writeStruct(w *textWriter, sv reflect.Value) error { + if tm.ExpandAny && isAny(sv) { + if canExpand, err := tm.writeProto3Any(w, sv); canExpand { + return err + } + } st := sv.Type() sprops := GetProperties(st) for i := 0; i < sv.NumField(); i++ { @@ -233,10 +321,10 @@ func writeStruct(w *textWriter, sv reflect.Value) error { continue } if len(props.Enum) > 0 { - if err := writeEnum(w, v, props); err != nil { + if err := tm.writeEnum(w, v, props); err != nil { return err } - } else if err := writeAny(w, v, props); err != nil { + } else if err := tm.writeAny(w, v, props); err != nil { return err } if err := w.WriteByte('\n'); err != nil { @@ -278,7 +366,7 @@ func writeStruct(w *textWriter, sv reflect.Value) error { return err } } - if err := writeAny(w, key, props.mkeyprop); err != nil { + if err := tm.writeAny(w, key, props.mkeyprop); err != nil { return err } if err := w.WriteByte('\n'); err != nil { @@ -295,7 +383,7 @@ func writeStruct(w *textWriter, sv reflect.Value) error { return err } } - if err := writeAny(w, val, props.mvalprop); err != nil { + if err := tm.writeAny(w, val, props.mvalprop); err != nil { return err } if err := w.WriteByte('\n'); err != nil { @@ -367,10 +455,10 @@ func writeStruct(w *textWriter, sv reflect.Value) error { } if len(props.Enum) > 0 { - if err := writeEnum(w, fv, props); err != nil { + if err := tm.writeEnum(w, fv, props); err != nil { return err } - } else if err := writeAny(w, fv, props); err != nil { + } else if err := tm.writeAny(w, fv, props); err != nil { return err } @@ -387,8 +475,8 @@ func writeStruct(w *textWriter, sv reflect.Value) error { pv = reflect.New(sv.Type()) pv.Elem().Set(sv) } - if pv.Type().Implements(extendableProtoType) { - if err := writeExtensions(w, pv); err != nil { + if pv.Type().Implements(extensionRangeType) { + if err := tm.writeExtensions(w, pv); err != nil { return err } } @@ -418,20 +506,45 @@ func writeRaw(w *textWriter, b []byte) error { } // writeAny writes an arbitrary field. -func writeAny(w *textWriter, v reflect.Value, props *Properties) error { +func (tm *TextMarshaler) writeAny(w *textWriter, v reflect.Value, props *Properties) error { v = reflect.Indirect(v) - if props != nil && len(props.CustomType) > 0 { - custom, ok := v.Interface().(Marshaler) - if ok { - data, err := custom.Marshal() + if props != nil { + if len(props.CustomType) > 0 { + custom, ok := v.Interface().(Marshaler) + if ok { + data, err := custom.Marshal() + if err != nil { + return err + } + if err := writeString(w, string(data)); err != nil { + return err + } + return nil + } + } else if props.StdTime { + t, ok := v.Interface().(time.Time) + if !ok { + return fmt.Errorf("stdtime is not time.Time, but %T", v.Interface()) + } + tproto, err := timestampProto(t) if err != nil { return err } - if err := writeString(w, string(data)); err != nil { - return err + props.StdTime = false + err = tm.writeAny(w, reflect.ValueOf(tproto), props) + props.StdTime = true + return err + } else if props.StdDuration { + d, ok := v.Interface().(time.Duration) + if !ok { + return fmt.Errorf("stdtime is not time.Duration, but %T", v.Interface()) } - return nil + dproto := durationProto(d) + props.StdDuration = false + err := tm.writeAny(w, reflect.ValueOf(dproto), props) + props.StdDuration = true + return err } } @@ -481,15 +594,15 @@ func writeAny(w *textWriter, v reflect.Value, props *Properties) error { } } w.indent() - if tm, ok := v.Interface().(encoding.TextMarshaler); ok { - text, err := tm.MarshalText() + if etm, ok := v.Interface().(encoding.TextMarshaler); ok { + text, err := etm.MarshalText() if err != nil { return err } if _, err = w.Write(text); err != nil { return err } - } else if err := writeStruct(w, v); err != nil { + } else if err := tm.writeStruct(w, v); err != nil { return err } w.unindent() @@ -633,30 +746,39 @@ func (s int32Slice) Swap(i, j int) { s[i], s[j] = s[j], s[i] } // writeExtensions writes all the extensions in pv. // pv is assumed to be a pointer to a protocol message struct that is extendable. -func writeExtensions(w *textWriter, pv reflect.Value) error { +func (tm *TextMarshaler) writeExtensions(w *textWriter, pv reflect.Value) error { emap := extensionMaps[pv.Type().Elem()] - ep := pv.Interface().(extendableProto) + e := pv.Interface().(Message) - // Order the extensions by ID. - // This isn't strictly necessary, but it will give us - // canonical output, which will also make testing easier. var m map[int32]Extension - if em, ok := ep.(extensionsMap); ok { - m = em.ExtensionMap() - } else if em, ok := ep.(extensionsBytes); ok { + var mu sync.Locker + if em, ok := e.(extensionsBytes); ok { eb := em.GetExtensions() var err error m, err = BytesToExtensionsMap(*eb) if err != nil { return err } + mu = notLocker{} + } else if _, ok := e.(extendableProto); ok { + ep, _ := extendable(e) + m, mu = ep.extensionsRead() + if m == nil { + return nil + } } + // Order the extensions by ID. + // This isn't strictly necessary, but it will give us + // canonical output, which will also make testing easier. + + mu.Lock() ids := make([]int32, 0, len(m)) for id := range m { ids = append(ids, id) } sort.Sort(int32Slice(ids)) + mu.Unlock() for _, extNum := range ids { ext := m[extNum] @@ -672,20 +794,20 @@ func writeExtensions(w *textWriter, pv reflect.Value) error { continue } - pb, err := GetExtension(ep, desc) + pb, err := GetExtension(e, desc) if err != nil { return fmt.Errorf("failed getting extension: %v", err) } // Repeated extensions will appear as a slice. if !desc.repeated() { - if err := writeExtension(w, desc.Name, pb); err != nil { + if err := tm.writeExtension(w, desc.Name, pb); err != nil { return err } } else { v := reflect.ValueOf(pb) for i := 0; i < v.Len(); i++ { - if err := writeExtension(w, desc.Name, v.Index(i).Interface()); err != nil { + if err := tm.writeExtension(w, desc.Name, v.Index(i).Interface()); err != nil { return err } } @@ -694,7 +816,7 @@ func writeExtensions(w *textWriter, pv reflect.Value) error { return nil } -func writeExtension(w *textWriter, name string, pb interface{}) error { +func (tm *TextMarshaler) writeExtension(w *textWriter, name string, pb interface{}) error { if _, err := fmt.Fprintf(w, "[%s]:", name); err != nil { return err } @@ -703,7 +825,7 @@ func writeExtension(w *textWriter, name string, pb interface{}) error { return err } } - if err := writeAny(w, reflect.ValueOf(pb), nil); err != nil { + if err := tm.writeAny(w, reflect.ValueOf(pb), nil); err != nil { return err } if err := w.WriteByte('\n'); err != nil { @@ -730,12 +852,13 @@ func (w *textWriter) writeIndent() { // TextMarshaler is a configurable text format marshaler. type TextMarshaler struct { - Compact bool // use compact text format (one line). + Compact bool // use compact text format (one line). + ExpandAny bool // expand google.protobuf.Any messages of known types } // Marshal writes a given protocol buffer in text format. // The only errors returned are from w. -func (m *TextMarshaler) Marshal(w io.Writer, pb Message) error { +func (tm *TextMarshaler) Marshal(w io.Writer, pb Message) error { val := reflect.ValueOf(pb) if pb == nil || val.IsNil() { w.Write([]byte("")) @@ -750,11 +873,11 @@ func (m *TextMarshaler) Marshal(w io.Writer, pb Message) error { aw := &textWriter{ w: ww, complete: true, - compact: m.Compact, + compact: tm.Compact, } - if tm, ok := pb.(encoding.TextMarshaler); ok { - text, err := tm.MarshalText() + if etm, ok := pb.(encoding.TextMarshaler); ok { + text, err := etm.MarshalText() if err != nil { return err } @@ -768,7 +891,7 @@ func (m *TextMarshaler) Marshal(w io.Writer, pb Message) error { } // Dereference the received pointer so we don't have outer < and >. v := reflect.Indirect(val) - if err := writeStruct(aw, v); err != nil { + if err := tm.writeStruct(aw, v); err != nil { return err } if bw != nil { @@ -778,9 +901,9 @@ func (m *TextMarshaler) Marshal(w io.Writer, pb Message) error { } // Text is the same as Marshal, but returns the string directly. -func (m *TextMarshaler) Text(pb Message) string { +func (tm *TextMarshaler) Text(pb Message) string { var buf bytes.Buffer - m.Marshal(&buf, pb) + tm.Marshal(&buf, pb) return buf.String() } diff --git a/vendor/github.com/gogo/protobuf/proto/text_gogo.go b/vendor/github.com/gogo/protobuf/proto/text_gogo.go index cdb23373c3..1d6c6aa0e4 100644 --- a/vendor/github.com/gogo/protobuf/proto/text_gogo.go +++ b/vendor/github.com/gogo/protobuf/proto/text_gogo.go @@ -1,5 +1,7 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are @@ -31,10 +33,10 @@ import ( "reflect" ) -func writeEnum(w *textWriter, v reflect.Value, props *Properties) error { +func (tm *TextMarshaler) writeEnum(w *textWriter, v reflect.Value, props *Properties) error { m, ok := enumStringMaps[props.Enum] if !ok { - if err := writeAny(w, v, props); err != nil { + if err := tm.writeAny(w, v, props); err != nil { return err } } @@ -46,7 +48,7 @@ func writeEnum(w *textWriter, v reflect.Value, props *Properties) error { } s, ok := m[key] if !ok { - if err := writeAny(w, v, props); err != nil { + if err := tm.writeAny(w, v, props); err != nil { return err } } diff --git a/vendor/github.com/gogo/protobuf/proto/text_parser.go b/vendor/github.com/gogo/protobuf/proto/text_parser.go index 61b4bc8cc8..9db12e9601 100644 --- a/vendor/github.com/gogo/protobuf/proto/text_parser.go +++ b/vendor/github.com/gogo/protobuf/proto/text_parser.go @@ -1,7 +1,7 @@ -// Extensions for Protocol Buffers to create more go like structures. +// Protocol Buffers for Go with Gadgets // -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. -// http://github.com/gogo/protobuf/gogoproto +// Copyright (c) 2013, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf // // Go support for Protocol Buffers - Google's data interchange format // @@ -46,9 +46,13 @@ import ( "reflect" "strconv" "strings" + "time" "unicode/utf8" ) +// Error string emitted when deserializing Any and fields are already set +const anyRepeatedlyUnpacked = "Any message unpacked multiple times, or %q already set" + type ParseError struct { Message string Line int // 1-based line number @@ -168,7 +172,7 @@ func (p *textParser) advance() { p.cur.offset, p.cur.line = p.offset, p.line p.cur.unquoted = "" switch p.s[0] { - case '<', '>', '{', '}', ':', '[', ']', ';', ',': + case '<', '>', '{', '}', ':', '[', ']', ';', ',', '/': // Single symbol p.cur.value, p.s = p.s[0:1], p.s[1:len(p.s)] case '"', '\'': @@ -456,7 +460,10 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { fieldSet := make(map[string]bool) // A struct is a sequence of "name: value", terminated by one of // '>' or '}', or the end of the input. A name may also be - // "[extension]". + // "[extension]" or "[type/url]". + // + // The whole struct can also be an expanded Any message, like: + // [type/url] < ... struct contents ... > for { tok := p.next() if tok.err != nil { @@ -466,33 +473,74 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { break } if tok.value == "[" { - // Looks like an extension. + // Looks like an extension or an Any. // // TODO: Check whether we need to handle // namespace rooted names (e.g. ".something.Foo"). - tok = p.next() - if tok.err != nil { - return tok.err + extName, err := p.consumeExtName() + if err != nil { + return err + } + + if s := strings.LastIndex(extName, "/"); s >= 0 { + // If it contains a slash, it's an Any type URL. + messageName := extName[s+1:] + mt := MessageType(messageName) + if mt == nil { + return p.errorf("unrecognized message %q in google.protobuf.Any", messageName) + } + tok = p.next() + if tok.err != nil { + return tok.err + } + // consume an optional colon + if tok.value == ":" { + tok = p.next() + if tok.err != nil { + return tok.err + } + } + var terminator string + switch tok.value { + case "<": + terminator = ">" + case "{": + terminator = "}" + default: + return p.errorf("expected '{' or '<', found %q", tok.value) + } + v := reflect.New(mt.Elem()) + if pe := p.readStruct(v.Elem(), terminator); pe != nil { + return pe + } + b, err := Marshal(v.Interface().(Message)) + if err != nil { + return p.errorf("failed to marshal message of type %q: %v", messageName, err) + } + if fieldSet["type_url"] { + return p.errorf(anyRepeatedlyUnpacked, "type_url") + } + if fieldSet["value"] { + return p.errorf(anyRepeatedlyUnpacked, "value") + } + sv.FieldByName("TypeUrl").SetString(extName) + sv.FieldByName("Value").SetBytes(b) + fieldSet["type_url"] = true + fieldSet["value"] = true + continue } + var desc *ExtensionDesc // This could be faster, but it's functional. // TODO: Do something smarter than a linear scan. for _, d := range RegisteredExtensions(reflect.New(st).Interface().(Message)) { - if d.Name == tok.value { + if d.Name == extName { desc = d break } } if desc == nil { - return p.errorf("unrecognized extension %q", tok.value) - } - // Check the extension terminator. - tok = p.next() - if tok.err != nil { - return tok.err - } - if tok.value != "]" { - return p.errorf("unrecognized extension terminator %q", tok.value) + return p.errorf("unrecognized extension %q", extName) } props := &Properties{} @@ -519,7 +567,7 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { } reqFieldErr = err } - ep := sv.Addr().Interface().(extendableProto) + ep := sv.Addr().Interface().(Message) if !rep { SetExtension(ep, desc, ext.Interface()) } else { @@ -550,7 +598,11 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { props = oop.Prop nv := reflect.New(oop.Type.Elem()) dst = nv.Elem().Field(0) - sv.Field(oop.Field).Set(nv) + field := sv.Field(oop.Field) + if !field.IsNil() { + return p.errorf("field '%s' would overwrite already parsed oneof '%s'", name, sv.Type().Field(oop.Field).Name) + } + field.Set(nv) } if !dst.IsValid() { return p.errorf("unknown field name %q in %v", name, st) @@ -571,8 +623,9 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { // The map entry should be this sequence of tokens: // < key : KEY value : VALUE > - // Technically the "key" and "value" could come in any order, - // but in practice they won't. + // However, implementations may omit key or value, and technically + // we should support them in any order. See b/28924776 for a time + // this went wrong. tok := p.next() var terminator string @@ -584,32 +637,39 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { default: return p.errorf("expected '{' or '<', found %q", tok.value) } - if err := p.consumeToken("key"); err != nil { - return err - } - if err := p.consumeToken(":"); err != nil { - return err - } - if err := p.readAny(key, props.mkeyprop); err != nil { - return err - } - if err := p.consumeOptionalSeparator(); err != nil { - return err - } - if err := p.consumeToken("value"); err != nil { - return err - } - if err := p.checkForColon(props.mvalprop, dst.Type().Elem()); err != nil { - return err - } - if err := p.readAny(val, props.mvalprop); err != nil { - return err - } - if err := p.consumeOptionalSeparator(); err != nil { - return err - } - if err := p.consumeToken(terminator); err != nil { - return err + for { + tok := p.next() + if tok.err != nil { + return tok.err + } + if tok.value == terminator { + break + } + switch tok.value { + case "key": + if err := p.consumeToken(":"); err != nil { + return err + } + if err := p.readAny(key, props.mkeyprop); err != nil { + return err + } + if err := p.consumeOptionalSeparator(); err != nil { + return err + } + case "value": + if err := p.checkForColon(props.mvalprop, dst.Type().Elem()); err != nil { + return err + } + if err := p.readAny(val, props.mvalprop); err != nil { + return err + } + if err := p.consumeOptionalSeparator(); err != nil { + return err + } + default: + p.back() + return p.errorf(`expected "key", "value", or %q, found %q`, terminator, tok.value) + } } dst.SetMapIndex(key, val) @@ -632,7 +692,8 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { return err } reqFieldErr = err - } else if props.Required { + } + if props.Required { reqCount-- } @@ -648,6 +709,35 @@ func (p *textParser) readStruct(sv reflect.Value, terminator string) error { return reqFieldErr } +// consumeExtName consumes extension name or expanded Any type URL and the +// following ']'. It returns the name or URL consumed. +func (p *textParser) consumeExtName() (string, error) { + tok := p.next() + if tok.err != nil { + return "", tok.err + } + + // If extension name or type url is quoted, it's a single token. + if len(tok.value) > 2 && isQuote(tok.value[0]) && tok.value[len(tok.value)-1] == tok.value[0] { + name, err := unquoteC(tok.value[1:len(tok.value)-1], rune(tok.value[0])) + if err != nil { + return "", err + } + return name, p.consumeToken("]") + } + + // Consume everything up to "]" + var parts []string + for tok.value != "]" { + parts = append(parts, tok.value) + tok = p.next() + if tok.err != nil { + return "", p.errorf("unrecognized type_url or extension name: %s", tok.err) + } + } + return strings.Join(parts, ""), nil +} + // consumeOptionalSeparator consumes an optional semicolon or comma. // It is used in readStruct to provide backward compatibility. func (p *textParser) consumeOptionalSeparator() error { @@ -708,6 +798,80 @@ func (p *textParser) readAny(v reflect.Value, props *Properties) error { } return nil } + if props.StdTime { + fv := v + p.back() + props.StdTime = false + tproto := ×tamp{} + err := p.readAny(reflect.ValueOf(tproto).Elem(), props) + props.StdTime = true + if err != nil { + return err + } + tim, err := timestampFromProto(tproto) + if err != nil { + return err + } + if props.Repeated { + t := reflect.TypeOf(v.Interface()) + if t.Kind() == reflect.Slice { + if t.Elem().Kind() == reflect.Ptr { + ts := fv.Interface().([]*time.Time) + ts = append(ts, &tim) + fv.Set(reflect.ValueOf(ts)) + return nil + } else { + ts := fv.Interface().([]time.Time) + ts = append(ts, tim) + fv.Set(reflect.ValueOf(ts)) + return nil + } + } + } + if reflect.TypeOf(v.Interface()).Kind() == reflect.Ptr { + v.Set(reflect.ValueOf(&tim)) + } else { + v.Set(reflect.Indirect(reflect.ValueOf(&tim))) + } + return nil + } + if props.StdDuration { + fv := v + p.back() + props.StdDuration = false + dproto := &duration{} + err := p.readAny(reflect.ValueOf(dproto).Elem(), props) + props.StdDuration = true + if err != nil { + return err + } + dur, err := durationFromProto(dproto) + if err != nil { + return err + } + if props.Repeated { + t := reflect.TypeOf(v.Interface()) + if t.Kind() == reflect.Slice { + if t.Elem().Kind() == reflect.Ptr { + ds := fv.Interface().([]*time.Duration) + ds = append(ds, &dur) + fv.Set(reflect.ValueOf(ds)) + return nil + } else { + ds := fv.Interface().([]time.Duration) + ds = append(ds, dur) + fv.Set(reflect.ValueOf(ds)) + return nil + } + } + } + if reflect.TypeOf(v.Interface()).Kind() == reflect.Ptr { + v.Set(reflect.ValueOf(&dur)) + } else { + v.Set(reflect.Indirect(reflect.ValueOf(&dur))) + } + return nil + } switch fv := v; fv.Kind() { case reflect.Slice: at := v.Type() @@ -750,12 +914,12 @@ func (p *textParser) readAny(v reflect.Value, props *Properties) error { fv.Set(reflect.Append(fv, reflect.New(at.Elem()).Elem())) return p.readAny(fv.Index(fv.Len()-1), props) case reflect.Bool: - // Either "true", "false", 1 or 0. + // true/1/t/True or false/f/0/False. switch tok.value { - case "true", "1": + case "true", "1", "t", "True": fv.SetBool(true) return nil - case "false", "0": + case "false", "0", "f", "False": fv.SetBool(false) return nil } diff --git a/vendor/github.com/gogo/protobuf/proto/timestamp.go b/vendor/github.com/gogo/protobuf/proto/timestamp.go new file mode 100644 index 0000000000..9324f6542b --- /dev/null +++ b/vendor/github.com/gogo/protobuf/proto/timestamp.go @@ -0,0 +1,113 @@ +// Go support for Protocol Buffers - Google's data interchange format +// +// Copyright 2016 The Go Authors. All rights reserved. +// https://github.com/golang/protobuf +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// * Neither the name of Google Inc. nor the names of its +// contributors may be used to endorse or promote products derived from +// this software without specific prior written permission. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package proto + +// This file implements operations on google.protobuf.Timestamp. + +import ( + "errors" + "fmt" + "time" +) + +const ( + // Seconds field of the earliest valid Timestamp. + // This is time.Date(1, 1, 1, 0, 0, 0, 0, time.UTC).Unix(). + minValidSeconds = -62135596800 + // Seconds field just after the latest valid Timestamp. + // This is time.Date(10000, 1, 1, 0, 0, 0, 0, time.UTC).Unix(). + maxValidSeconds = 253402300800 +) + +// validateTimestamp determines whether a Timestamp is valid. +// A valid timestamp represents a time in the range +// [0001-01-01, 10000-01-01) and has a Nanos field +// in the range [0, 1e9). +// +// If the Timestamp is valid, validateTimestamp returns nil. +// Otherwise, it returns an error that describes +// the problem. +// +// Every valid Timestamp can be represented by a time.Time, but the converse is not true. +func validateTimestamp(ts *timestamp) error { + if ts == nil { + return errors.New("timestamp: nil Timestamp") + } + if ts.Seconds < minValidSeconds { + return fmt.Errorf("timestamp: %#v before 0001-01-01", ts) + } + if ts.Seconds >= maxValidSeconds { + return fmt.Errorf("timestamp: %#v after 10000-01-01", ts) + } + if ts.Nanos < 0 || ts.Nanos >= 1e9 { + return fmt.Errorf("timestamp: %#v: nanos not in range [0, 1e9)", ts) + } + return nil +} + +// TimestampFromProto converts a google.protobuf.Timestamp proto to a time.Time. +// It returns an error if the argument is invalid. +// +// Unlike most Go functions, if Timestamp returns an error, the first return value +// is not the zero time.Time. Instead, it is the value obtained from the +// time.Unix function when passed the contents of the Timestamp, in the UTC +// locale. This may or may not be a meaningful time; many invalid Timestamps +// do map to valid time.Times. +// +// A nil Timestamp returns an error. The first return value in that case is +// undefined. +func timestampFromProto(ts *timestamp) (time.Time, error) { + // Don't return the zero value on error, because corresponds to a valid + // timestamp. Instead return whatever time.Unix gives us. + var t time.Time + if ts == nil { + t = time.Unix(0, 0).UTC() // treat nil like the empty Timestamp + } else { + t = time.Unix(ts.Seconds, int64(ts.Nanos)).UTC() + } + return t, validateTimestamp(ts) +} + +// TimestampProto converts the time.Time to a google.protobuf.Timestamp proto. +// It returns an error if the resulting Timestamp is invalid. +func timestampProto(t time.Time) (*timestamp, error) { + seconds := t.Unix() + nanos := int32(t.Sub(time.Unix(seconds, 0))) + ts := ×tamp{ + Seconds: seconds, + Nanos: nanos, + } + if err := validateTimestamp(ts); err != nil { + return nil, err + } + return ts, nil +} diff --git a/vendor/github.com/gogo/protobuf/proto/timestamp_gogo.go b/vendor/github.com/gogo/protobuf/proto/timestamp_gogo.go new file mode 100644 index 0000000000..d427647436 --- /dev/null +++ b/vendor/github.com/gogo/protobuf/proto/timestamp_gogo.go @@ -0,0 +1,229 @@ +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2016, The GoGo Authors. All rights reserved. +// http://github.com/gogo/protobuf +// +// Redistribution and use in source and binary forms, with or without +// modification, are permitted provided that the following conditions are +// met: +// +// * Redistributions of source code must retain the above copyright +// notice, this list of conditions and the following disclaimer. +// * Redistributions in binary form must reproduce the above +// copyright notice, this list of conditions and the following disclaimer +// in the documentation and/or other materials provided with the +// distribution. +// +// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT +// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT +// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +package proto + +import ( + "reflect" + "time" +) + +var timeType = reflect.TypeOf((*time.Time)(nil)).Elem() + +type timestamp struct { + Seconds int64 `protobuf:"varint,1,opt,name=seconds,proto3" json:"seconds,omitempty"` + Nanos int32 `protobuf:"varint,2,opt,name=nanos,proto3" json:"nanos,omitempty"` +} + +func (m *timestamp) Reset() { *m = timestamp{} } +func (*timestamp) ProtoMessage() {} +func (*timestamp) String() string { return "timestamp" } + +func init() { + RegisterType((*timestamp)(nil), "gogo.protobuf.proto.timestamp") +} + +func (o *Buffer) decTimestamp() (time.Time, error) { + b, err := o.DecodeRawBytes(true) + if err != nil { + return time.Time{}, err + } + tproto := ×tamp{} + if err := Unmarshal(b, tproto); err != nil { + return time.Time{}, err + } + return timestampFromProto(tproto) +} + +func (o *Buffer) dec_time(p *Properties, base structPointer) error { + t, err := o.decTimestamp() + if err != nil { + return err + } + setPtrCustomType(base, p.field, &t) + return nil +} + +func (o *Buffer) dec_ref_time(p *Properties, base structPointer) error { + t, err := o.decTimestamp() + if err != nil { + return err + } + setCustomType(base, p.field, &t) + return nil +} + +func (o *Buffer) dec_slice_time(p *Properties, base structPointer) error { + t, err := o.decTimestamp() + if err != nil { + return err + } + newBas := appendStructPointer(base, p.field, reflect.SliceOf(reflect.PtrTo(timeType))) + var zero field + setPtrCustomType(newBas, zero, &t) + return nil +} + +func (o *Buffer) dec_slice_ref_time(p *Properties, base structPointer) error { + t, err := o.decTimestamp() + if err != nil { + return err + } + newBas := appendStructPointer(base, p.field, reflect.SliceOf(timeType)) + var zero field + setCustomType(newBas, zero, &t) + return nil +} + +func size_time(p *Properties, base structPointer) (n int) { + structp := structPointer_GetStructPointer(base, p.field) + if structPointer_IsNil(structp) { + return 0 + } + tim := structPointer_Interface(structp, timeType).(*time.Time) + t, err := timestampProto(*tim) + if err != nil { + return 0 + } + size := Size(t) + return size + sizeVarint(uint64(size)) + len(p.tagcode) +} + +func (o *Buffer) enc_time(p *Properties, base structPointer) error { + structp := structPointer_GetStructPointer(base, p.field) + if structPointer_IsNil(structp) { + return ErrNil + } + tim := structPointer_Interface(structp, timeType).(*time.Time) + t, err := timestampProto(*tim) + if err != nil { + return err + } + data, err := Marshal(t) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + return nil +} + +func size_ref_time(p *Properties, base structPointer) (n int) { + tim := structPointer_InterfaceAt(base, p.field, timeType).(*time.Time) + t, err := timestampProto(*tim) + if err != nil { + return 0 + } + size := Size(t) + return size + sizeVarint(uint64(size)) + len(p.tagcode) +} + +func (o *Buffer) enc_ref_time(p *Properties, base structPointer) error { + tim := structPointer_InterfaceAt(base, p.field, timeType).(*time.Time) + t, err := timestampProto(*tim) + if err != nil { + return err + } + data, err := Marshal(t) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + return nil +} + +func size_slice_time(p *Properties, base structPointer) (n int) { + ptims := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(reflect.PtrTo(timeType))).(*[]*time.Time) + tims := *ptims + for i := 0; i < len(tims); i++ { + if tims[i] == nil { + return 0 + } + tproto, err := timestampProto(*tims[i]) + if err != nil { + return 0 + } + size := Size(tproto) + n += len(p.tagcode) + size + sizeVarint(uint64(size)) + } + return n +} + +func (o *Buffer) enc_slice_time(p *Properties, base structPointer) error { + ptims := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(reflect.PtrTo(timeType))).(*[]*time.Time) + tims := *ptims + for i := 0; i < len(tims); i++ { + if tims[i] == nil { + return errRepeatedHasNil + } + tproto, err := timestampProto(*tims[i]) + if err != nil { + return err + } + data, err := Marshal(tproto) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + } + return nil +} + +func size_slice_ref_time(p *Properties, base structPointer) (n int) { + ptims := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(timeType)).(*[]time.Time) + tims := *ptims + for i := 0; i < len(tims); i++ { + tproto, err := timestampProto(tims[i]) + if err != nil { + return 0 + } + size := Size(tproto) + n += len(p.tagcode) + size + sizeVarint(uint64(size)) + } + return n +} + +func (o *Buffer) enc_slice_ref_time(p *Properties, base structPointer) error { + ptims := structPointer_InterfaceAt(base, p.field, reflect.SliceOf(timeType)).(*[]time.Time) + tims := *ptims + for i := 0; i < len(tims); i++ { + tproto, err := timestampProto(tims[i]) + if err != nil { + return err + } + data, err := Marshal(tproto) + if err != nil { + return err + } + o.buf = append(o.buf, p.tagcode...) + o.EncodeRawBytes(data) + } + return nil +} diff --git a/vendor/github.com/gogo/protobuf/sortkeys/sortkeys.go b/vendor/github.com/gogo/protobuf/sortkeys/sortkeys.go index c52878dd59..ceadde6a5e 100644 --- a/vendor/github.com/gogo/protobuf/sortkeys/sortkeys.go +++ b/vendor/github.com/gogo/protobuf/sortkeys/sortkeys.go @@ -1,4 +1,6 @@ -// Copyright (c) 2013, Vastech SA (PTY) LTD. All rights reserved. +// Protocol Buffers for Go with Gadgets +// +// Copyright (c) 2013, The GoGo Authors. All rights reserved. // http://github.com/gogo/protobuf // // Redistribution and use in source and binary forms, with or without diff --git a/vendor/github.com/jonboulle/clockwork/.gitignore b/vendor/github.com/hashicorp/golang-lru/.gitignore similarity index 97% rename from vendor/github.com/jonboulle/clockwork/.gitignore rename to vendor/github.com/hashicorp/golang-lru/.gitignore index 010c242bd8..836562412f 100644 --- a/vendor/github.com/jonboulle/clockwork/.gitignore +++ b/vendor/github.com/hashicorp/golang-lru/.gitignore @@ -21,5 +21,3 @@ _testmain.go *.exe *.test - -*.swp diff --git a/vendor/github.com/hashicorp/golang-lru/2q.go b/vendor/github.com/hashicorp/golang-lru/2q.go new file mode 100644 index 0000000000..337d963296 --- /dev/null +++ b/vendor/github.com/hashicorp/golang-lru/2q.go @@ -0,0 +1,212 @@ +package lru + +import ( + "fmt" + "sync" + + "github.com/hashicorp/golang-lru/simplelru" +) + +const ( + // Default2QRecentRatio is the ratio of the 2Q cache dedicated + // to recently added entries that have only been accessed once. + Default2QRecentRatio = 0.25 + + // Default2QGhostEntries is the default ratio of ghost + // entries kept to track entries recently evicted + Default2QGhostEntries = 0.50 +) + +// TwoQueueCache is a thread-safe fixed size 2Q cache. +// 2Q is an enhancement over the standard LRU cache +// in that it tracks both frequently and recently used +// entries separately. This avoids a burst in access to new +// entries from evicting frequently used entries. It adds some +// additional tracking overhead to the standard LRU cache, and is +// computationally about 2x the cost, and adds some metadata over +// head. The ARCCache is similar, but does not require setting any +// parameters. +type TwoQueueCache struct { + size int + recentSize int + + recent *simplelru.LRU + frequent *simplelru.LRU + recentEvict *simplelru.LRU + lock sync.RWMutex +} + +// New2Q creates a new TwoQueueCache using the default +// values for the parameters. +func New2Q(size int) (*TwoQueueCache, error) { + return New2QParams(size, Default2QRecentRatio, Default2QGhostEntries) +} + +// New2QParams creates a new TwoQueueCache using the provided +// parameter values. +func New2QParams(size int, recentRatio float64, ghostRatio float64) (*TwoQueueCache, error) { + if size <= 0 { + return nil, fmt.Errorf("invalid size") + } + if recentRatio < 0.0 || recentRatio > 1.0 { + return nil, fmt.Errorf("invalid recent ratio") + } + if ghostRatio < 0.0 || ghostRatio > 1.0 { + return nil, fmt.Errorf("invalid ghost ratio") + } + + // Determine the sub-sizes + recentSize := int(float64(size) * recentRatio) + evictSize := int(float64(size) * ghostRatio) + + // Allocate the LRUs + recent, err := simplelru.NewLRU(size, nil) + if err != nil { + return nil, err + } + frequent, err := simplelru.NewLRU(size, nil) + if err != nil { + return nil, err + } + recentEvict, err := simplelru.NewLRU(evictSize, nil) + if err != nil { + return nil, err + } + + // Initialize the cache + c := &TwoQueueCache{ + size: size, + recentSize: recentSize, + recent: recent, + frequent: frequent, + recentEvict: recentEvict, + } + return c, nil +} + +func (c *TwoQueueCache) Get(key interface{}) (interface{}, bool) { + c.lock.Lock() + defer c.lock.Unlock() + + // Check if this is a frequent value + if val, ok := c.frequent.Get(key); ok { + return val, ok + } + + // If the value is contained in recent, then we + // promote it to frequent + if val, ok := c.recent.Peek(key); ok { + c.recent.Remove(key) + c.frequent.Add(key, val) + return val, ok + } + + // No hit + return nil, false +} + +func (c *TwoQueueCache) Add(key, value interface{}) { + c.lock.Lock() + defer c.lock.Unlock() + + // Check if the value is frequently used already, + // and just update the value + if c.frequent.Contains(key) { + c.frequent.Add(key, value) + return + } + + // Check if the value is recently used, and promote + // the value into the frequent list + if c.recent.Contains(key) { + c.recent.Remove(key) + c.frequent.Add(key, value) + return + } + + // If the value was recently evicted, add it to the + // frequently used list + if c.recentEvict.Contains(key) { + c.ensureSpace(true) + c.recentEvict.Remove(key) + c.frequent.Add(key, value) + return + } + + // Add to the recently seen list + c.ensureSpace(false) + c.recent.Add(key, value) + return +} + +// ensureSpace is used to ensure we have space in the cache +func (c *TwoQueueCache) ensureSpace(recentEvict bool) { + // If we have space, nothing to do + recentLen := c.recent.Len() + freqLen := c.frequent.Len() + if recentLen+freqLen < c.size { + return + } + + // If the recent buffer is larger than + // the target, evict from there + if recentLen > 0 && (recentLen > c.recentSize || (recentLen == c.recentSize && !recentEvict)) { + k, _, _ := c.recent.RemoveOldest() + c.recentEvict.Add(k, nil) + return + } + + // Remove from the frequent list otherwise + c.frequent.RemoveOldest() +} + +func (c *TwoQueueCache) Len() int { + c.lock.RLock() + defer c.lock.RUnlock() + return c.recent.Len() + c.frequent.Len() +} + +func (c *TwoQueueCache) Keys() []interface{} { + c.lock.RLock() + defer c.lock.RUnlock() + k1 := c.frequent.Keys() + k2 := c.recent.Keys() + return append(k1, k2...) +} + +func (c *TwoQueueCache) Remove(key interface{}) { + c.lock.Lock() + defer c.lock.Unlock() + if c.frequent.Remove(key) { + return + } + if c.recent.Remove(key) { + return + } + if c.recentEvict.Remove(key) { + return + } +} + +func (c *TwoQueueCache) Purge() { + c.lock.Lock() + defer c.lock.Unlock() + c.recent.Purge() + c.frequent.Purge() + c.recentEvict.Purge() +} + +func (c *TwoQueueCache) Contains(key interface{}) bool { + c.lock.RLock() + defer c.lock.RUnlock() + return c.frequent.Contains(key) || c.recent.Contains(key) +} + +func (c *TwoQueueCache) Peek(key interface{}) (interface{}, bool) { + c.lock.RLock() + defer c.lock.RUnlock() + if val, ok := c.frequent.Peek(key); ok { + return val, ok + } + return c.recent.Peek(key) +} diff --git a/vendor/github.com/hashicorp/golang-lru/LICENSE b/vendor/github.com/hashicorp/golang-lru/LICENSE new file mode 100644 index 0000000000..be2cc4dfb6 --- /dev/null +++ b/vendor/github.com/hashicorp/golang-lru/LICENSE @@ -0,0 +1,362 @@ +Mozilla Public License, version 2.0 + +1. Definitions + +1.1. "Contributor" + + means each individual or legal entity that creates, contributes to the + creation of, or owns Covered Software. + +1.2. "Contributor Version" + + means the combination of the Contributions of others (if any) used by a + Contributor and that particular Contributor's Contribution. + +1.3. "Contribution" + + means Covered Software of a particular Contributor. + +1.4. "Covered Software" + + means Source Code Form to which the initial Contributor has attached the + notice in Exhibit A, the Executable Form of such Source Code Form, and + Modifications of such Source Code Form, in each case including portions + thereof. + +1.5. "Incompatible With Secondary Licenses" + means + + a. that the initial Contributor has attached the notice described in + Exhibit B to the Covered Software; or + + b. that the Covered Software was made available under the terms of + version 1.1 or earlier of the License, but not also under the terms of + a Secondary License. + +1.6. "Executable Form" + + means any form of the work other than Source Code Form. + +1.7. "Larger Work" + + means a work that combines Covered Software with other material, in a + separate file or files, that is not Covered Software. + +1.8. "License" + + means this document. + +1.9. "Licensable" + + means having the right to grant, to the maximum extent possible, whether + at the time of the initial grant or subsequently, any and all of the + rights conveyed by this License. + +1.10. "Modifications" + + means any of the following: + + a. any file in Source Code Form that results from an addition to, + deletion from, or modification of the contents of Covered Software; or + + b. any new file in Source Code Form that contains any Covered Software. + +1.11. "Patent Claims" of a Contributor + + means any patent claim(s), including without limitation, method, + process, and apparatus claims, in any patent Licensable by such + Contributor that would be infringed, but for the grant of the License, + by the making, using, selling, offering for sale, having made, import, + or transfer of either its Contributions or its Contributor Version. + +1.12. "Secondary License" + + means either the GNU General Public License, Version 2.0, the GNU Lesser + General Public License, Version 2.1, the GNU Affero General Public + License, Version 3.0, or any later versions of those licenses. + +1.13. "Source Code Form" + + means the form of the work preferred for making modifications. + +1.14. "You" (or "Your") + + means an individual or a legal entity exercising rights under this + License. For legal entities, "You" includes any entity that controls, is + controlled by, or is under common control with You. For purposes of this + definition, "control" means (a) the power, direct or indirect, to cause + the direction or management of such entity, whether by contract or + otherwise, or (b) ownership of more than fifty percent (50%) of the + outstanding shares or beneficial ownership of such entity. + + +2. License Grants and Conditions + +2.1. Grants + + Each Contributor hereby grants You a world-wide, royalty-free, + non-exclusive license: + + a. under intellectual property rights (other than patent or trademark) + Licensable by such Contributor to use, reproduce, make available, + modify, display, perform, distribute, and otherwise exploit its + Contributions, either on an unmodified basis, with Modifications, or + as part of a Larger Work; and + + b. under Patent Claims of such Contributor to make, use, sell, offer for + sale, have made, import, and otherwise transfer either its + Contributions or its Contributor Version. + +2.2. Effective Date + + The licenses granted in Section 2.1 with respect to any Contribution + become effective for each Contribution on the date the Contributor first + distributes such Contribution. + +2.3. Limitations on Grant Scope + + The licenses granted in this Section 2 are the only rights granted under + this License. No additional rights or licenses will be implied from the + distribution or licensing of Covered Software under this License. + Notwithstanding Section 2.1(b) above, no patent license is granted by a + Contributor: + + a. for any code that a Contributor has removed from Covered Software; or + + b. for infringements caused by: (i) Your and any other third party's + modifications of Covered Software, or (ii) the combination of its + Contributions with other software (except as part of its Contributor + Version); or + + c. under Patent Claims infringed by Covered Software in the absence of + its Contributions. + + This License does not grant any rights in the trademarks, service marks, + or logos of any Contributor (except as may be necessary to comply with + the notice requirements in Section 3.4). + +2.4. Subsequent Licenses + + No Contributor makes additional grants as a result of Your choice to + distribute the Covered Software under a subsequent version of this + License (see Section 10.2) or under the terms of a Secondary License (if + permitted under the terms of Section 3.3). + +2.5. Representation + + Each Contributor represents that the Contributor believes its + Contributions are its original creation(s) or it has sufficient rights to + grant the rights to its Contributions conveyed by this License. + +2.6. Fair Use + + This License is not intended to limit any rights You have under + applicable copyright doctrines of fair use, fair dealing, or other + equivalents. + +2.7. Conditions + + Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted in + Section 2.1. + + +3. Responsibilities + +3.1. Distribution of Source Form + + All distribution of Covered Software in Source Code Form, including any + Modifications that You create or to which You contribute, must be under + the terms of this License. You must inform recipients that the Source + Code Form of the Covered Software is governed by the terms of this + License, and how they can obtain a copy of this License. You may not + attempt to alter or restrict the recipients' rights in the Source Code + Form. + +3.2. Distribution of Executable Form + + If You distribute Covered Software in Executable Form then: + + a. such Covered Software must also be made available in Source Code Form, + as described in Section 3.1, and You must inform recipients of the + Executable Form how they can obtain a copy of such Source Code Form by + reasonable means in a timely manner, at a charge no more than the cost + of distribution to the recipient; and + + b. You may distribute such Executable Form under the terms of this + License, or sublicense it under different terms, provided that the + license for the Executable Form does not attempt to limit or alter the + recipients' rights in the Source Code Form under this License. + +3.3. Distribution of a Larger Work + + You may create and distribute a Larger Work under terms of Your choice, + provided that You also comply with the requirements of this License for + the Covered Software. If the Larger Work is a combination of Covered + Software with a work governed by one or more Secondary Licenses, and the + Covered Software is not Incompatible With Secondary Licenses, this + License permits You to additionally distribute such Covered Software + under the terms of such Secondary License(s), so that the recipient of + the Larger Work may, at their option, further distribute the Covered + Software under the terms of either this License or such Secondary + License(s). + +3.4. Notices + + You may not remove or alter the substance of any license notices + (including copyright notices, patent notices, disclaimers of warranty, or + limitations of liability) contained within the Source Code Form of the + Covered Software, except that You may alter any license notices to the + extent required to remedy known factual inaccuracies. + +3.5. Application of Additional Terms + + You may choose to offer, and to charge a fee for, warranty, support, + indemnity or liability obligations to one or more recipients of Covered + Software. However, You may do so only on Your own behalf, and not on + behalf of any Contributor. You must make it absolutely clear that any + such warranty, support, indemnity, or liability obligation is offered by + You alone, and You hereby agree to indemnify every Contributor for any + liability incurred by such Contributor as a result of warranty, support, + indemnity or liability terms You offer. You may include additional + disclaimers of warranty and limitations of liability specific to any + jurisdiction. + +4. Inability to Comply Due to Statute or Regulation + + If it is impossible for You to comply with any of the terms of this License + with respect to some or all of the Covered Software due to statute, + judicial order, or regulation then You must: (a) comply with the terms of + this License to the maximum extent possible; and (b) describe the + limitations and the code they affect. Such description must be placed in a + text file included with all distributions of the Covered Software under + this License. Except to the extent prohibited by statute or regulation, + such description must be sufficiently detailed for a recipient of ordinary + skill to be able to understand it. + +5. Termination + +5.1. The rights granted under this License will terminate automatically if You + fail to comply with any of its terms. However, if You become compliant, + then the rights granted under this License from a particular Contributor + are reinstated (a) provisionally, unless and until such Contributor + explicitly and finally terminates Your grants, and (b) on an ongoing + basis, if such Contributor fails to notify You of the non-compliance by + some reasonable means prior to 60 days after You have come back into + compliance. Moreover, Your grants from a particular Contributor are + reinstated on an ongoing basis if such Contributor notifies You of the + non-compliance by some reasonable means, this is the first time You have + received notice of non-compliance with this License from such + Contributor, and You become compliant prior to 30 days after Your receipt + of the notice. + +5.2. If You initiate litigation against any entity by asserting a patent + infringement claim (excluding declaratory judgment actions, + counter-claims, and cross-claims) alleging that a Contributor Version + directly or indirectly infringes any patent, then the rights granted to + You by any and all Contributors for the Covered Software under Section + 2.1 of this License shall terminate. + +5.3. In the event of termination under Sections 5.1 or 5.2 above, all end user + license agreements (excluding distributors and resellers) which have been + validly granted by You or Your distributors under this License prior to + termination shall survive termination. + +6. Disclaimer of Warranty + + Covered Software is provided under this License on an "as is" basis, + without warranty of any kind, either expressed, implied, or statutory, + including, without limitation, warranties that the Covered Software is free + of defects, merchantable, fit for a particular purpose or non-infringing. + The entire risk as to the quality and performance of the Covered Software + is with You. Should any Covered Software prove defective in any respect, + You (not any Contributor) assume the cost of any necessary servicing, + repair, or correction. This disclaimer of warranty constitutes an essential + part of this License. No use of any Covered Software is authorized under + this License except under this disclaimer. + +7. Limitation of Liability + + Under no circumstances and under no legal theory, whether tort (including + negligence), contract, or otherwise, shall any Contributor, or anyone who + distributes Covered Software as permitted above, be liable to You for any + direct, indirect, special, incidental, or consequential damages of any + character including, without limitation, damages for lost profits, loss of + goodwill, work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses, even if such party shall have been + informed of the possibility of such damages. This limitation of liability + shall not apply to liability for death or personal injury resulting from + such party's negligence to the extent applicable law prohibits such + limitation. Some jurisdictions do not allow the exclusion or limitation of + incidental or consequential damages, so this exclusion and limitation may + not apply to You. + +8. Litigation + + Any litigation relating to this License may be brought only in the courts + of a jurisdiction where the defendant maintains its principal place of + business and such litigation shall be governed by laws of that + jurisdiction, without reference to its conflict-of-law provisions. Nothing + in this Section shall prevent a party's ability to bring cross-claims or + counter-claims. + +9. Miscellaneous + + This License represents the complete agreement concerning the subject + matter hereof. If any provision of this License is held to be + unenforceable, such provision shall be reformed only to the extent + necessary to make it enforceable. Any law or regulation which provides that + the language of a contract shall be construed against the drafter shall not + be used to construe this License against a Contributor. + + +10. Versions of the License + +10.1. New Versions + + Mozilla Foundation is the license steward. Except as provided in Section + 10.3, no one other than the license steward has the right to modify or + publish new versions of this License. Each version will be given a + distinguishing version number. + +10.2. Effect of New Versions + + You may distribute the Covered Software under the terms of the version + of the License under which You originally received the Covered Software, + or under the terms of any subsequent version published by the license + steward. + +10.3. Modified Versions + + If you create software not governed by this License, and you want to + create a new license for such software, you may create and use a + modified version of this License if you rename the license and remove + any references to the name of the license steward (except to note that + such modified license differs from this License). + +10.4. Distributing Source Code Form that is Incompatible With Secondary + Licenses If You choose to distribute Source Code Form that is + Incompatible With Secondary Licenses under the terms of this version of + the License, the notice described in Exhibit B of this License must be + attached. + +Exhibit A - Source Code Form License Notice + + This Source Code Form is subject to the + terms of the Mozilla Public License, v. + 2.0. If a copy of the MPL was not + distributed with this file, You can + obtain one at + http://mozilla.org/MPL/2.0/. + +If it is not possible or desirable to put the notice in a particular file, +then You may include the notice in a location (such as a LICENSE file in a +relevant directory) where a recipient would be likely to look for such a +notice. + +You may add additional accurate notices of copyright ownership. + +Exhibit B - "Incompatible With Secondary Licenses" Notice + + This Source Code Form is "Incompatible + With Secondary Licenses", as defined by + the Mozilla Public License, v. 2.0. diff --git a/vendor/github.com/hashicorp/golang-lru/README.md b/vendor/github.com/hashicorp/golang-lru/README.md new file mode 100644 index 0000000000..33e58cfaf9 --- /dev/null +++ b/vendor/github.com/hashicorp/golang-lru/README.md @@ -0,0 +1,25 @@ +golang-lru +========== + +This provides the `lru` package which implements a fixed-size +thread safe LRU cache. It is based on the cache in Groupcache. + +Documentation +============= + +Full docs are available on [Godoc](http://godoc.org/github.com/hashicorp/golang-lru) + +Example +======= + +Using the LRU is very simple: + +```go +l, _ := New(128) +for i := 0; i < 256; i++ { + l.Add(i, nil) +} +if l.Len() != 128 { + panic(fmt.Sprintf("bad len: %v", l.Len())) +} +``` diff --git a/vendor/github.com/hashicorp/golang-lru/arc.go b/vendor/github.com/hashicorp/golang-lru/arc.go new file mode 100644 index 0000000000..a2a2528173 --- /dev/null +++ b/vendor/github.com/hashicorp/golang-lru/arc.go @@ -0,0 +1,257 @@ +package lru + +import ( + "sync" + + "github.com/hashicorp/golang-lru/simplelru" +) + +// ARCCache is a thread-safe fixed size Adaptive Replacement Cache (ARC). +// ARC is an enhancement over the standard LRU cache in that tracks both +// frequency and recency of use. This avoids a burst in access to new +// entries from evicting the frequently used older entries. It adds some +// additional tracking overhead to a standard LRU cache, computationally +// it is roughly 2x the cost, and the extra memory overhead is linear +// with the size of the cache. ARC has been patented by IBM, but is +// similar to the TwoQueueCache (2Q) which requires setting parameters. +type ARCCache struct { + size int // Size is the total capacity of the cache + p int // P is the dynamic preference towards T1 or T2 + + t1 *simplelru.LRU // T1 is the LRU for recently accessed items + b1 *simplelru.LRU // B1 is the LRU for evictions from t1 + + t2 *simplelru.LRU // T2 is the LRU for frequently accessed items + b2 *simplelru.LRU // B2 is the LRU for evictions from t2 + + lock sync.RWMutex +} + +// NewARC creates an ARC of the given size +func NewARC(size int) (*ARCCache, error) { + // Create the sub LRUs + b1, err := simplelru.NewLRU(size, nil) + if err != nil { + return nil, err + } + b2, err := simplelru.NewLRU(size, nil) + if err != nil { + return nil, err + } + t1, err := simplelru.NewLRU(size, nil) + if err != nil { + return nil, err + } + t2, err := simplelru.NewLRU(size, nil) + if err != nil { + return nil, err + } + + // Initialize the ARC + c := &ARCCache{ + size: size, + p: 0, + t1: t1, + b1: b1, + t2: t2, + b2: b2, + } + return c, nil +} + +// Get looks up a key's value from the cache. +func (c *ARCCache) Get(key interface{}) (interface{}, bool) { + c.lock.Lock() + defer c.lock.Unlock() + + // Ff the value is contained in T1 (recent), then + // promote it to T2 (frequent) + if val, ok := c.t1.Peek(key); ok { + c.t1.Remove(key) + c.t2.Add(key, val) + return val, ok + } + + // Check if the value is contained in T2 (frequent) + if val, ok := c.t2.Get(key); ok { + return val, ok + } + + // No hit + return nil, false +} + +// Add adds a value to the cache. +func (c *ARCCache) Add(key, value interface{}) { + c.lock.Lock() + defer c.lock.Unlock() + + // Check if the value is contained in T1 (recent), and potentially + // promote it to frequent T2 + if c.t1.Contains(key) { + c.t1.Remove(key) + c.t2.Add(key, value) + return + } + + // Check if the value is already in T2 (frequent) and update it + if c.t2.Contains(key) { + c.t2.Add(key, value) + return + } + + // Check if this value was recently evicted as part of the + // recently used list + if c.b1.Contains(key) { + // T1 set is too small, increase P appropriately + delta := 1 + b1Len := c.b1.Len() + b2Len := c.b2.Len() + if b2Len > b1Len { + delta = b2Len / b1Len + } + if c.p+delta >= c.size { + c.p = c.size + } else { + c.p += delta + } + + // Potentially need to make room in the cache + if c.t1.Len()+c.t2.Len() >= c.size { + c.replace(false) + } + + // Remove from B1 + c.b1.Remove(key) + + // Add the key to the frequently used list + c.t2.Add(key, value) + return + } + + // Check if this value was recently evicted as part of the + // frequently used list + if c.b2.Contains(key) { + // T2 set is too small, decrease P appropriately + delta := 1 + b1Len := c.b1.Len() + b2Len := c.b2.Len() + if b1Len > b2Len { + delta = b1Len / b2Len + } + if delta >= c.p { + c.p = 0 + } else { + c.p -= delta + } + + // Potentially need to make room in the cache + if c.t1.Len()+c.t2.Len() >= c.size { + c.replace(true) + } + + // Remove from B2 + c.b2.Remove(key) + + // Add the key to the frequntly used list + c.t2.Add(key, value) + return + } + + // Potentially need to make room in the cache + if c.t1.Len()+c.t2.Len() >= c.size { + c.replace(false) + } + + // Keep the size of the ghost buffers trim + if c.b1.Len() > c.size-c.p { + c.b1.RemoveOldest() + } + if c.b2.Len() > c.p { + c.b2.RemoveOldest() + } + + // Add to the recently seen list + c.t1.Add(key, value) + return +} + +// replace is used to adaptively evict from either T1 or T2 +// based on the current learned value of P +func (c *ARCCache) replace(b2ContainsKey bool) { + t1Len := c.t1.Len() + if t1Len > 0 && (t1Len > c.p || (t1Len == c.p && b2ContainsKey)) { + k, _, ok := c.t1.RemoveOldest() + if ok { + c.b1.Add(k, nil) + } + } else { + k, _, ok := c.t2.RemoveOldest() + if ok { + c.b2.Add(k, nil) + } + } +} + +// Len returns the number of cached entries +func (c *ARCCache) Len() int { + c.lock.RLock() + defer c.lock.RUnlock() + return c.t1.Len() + c.t2.Len() +} + +// Keys returns all the cached keys +func (c *ARCCache) Keys() []interface{} { + c.lock.RLock() + defer c.lock.RUnlock() + k1 := c.t1.Keys() + k2 := c.t2.Keys() + return append(k1, k2...) +} + +// Remove is used to purge a key from the cache +func (c *ARCCache) Remove(key interface{}) { + c.lock.Lock() + defer c.lock.Unlock() + if c.t1.Remove(key) { + return + } + if c.t2.Remove(key) { + return + } + if c.b1.Remove(key) { + return + } + if c.b2.Remove(key) { + return + } +} + +// Purge is used to clear the cache +func (c *ARCCache) Purge() { + c.lock.Lock() + defer c.lock.Unlock() + c.t1.Purge() + c.t2.Purge() + c.b1.Purge() + c.b2.Purge() +} + +// Contains is used to check if the cache contains a key +// without updating recency or frequency. +func (c *ARCCache) Contains(key interface{}) bool { + c.lock.RLock() + defer c.lock.RUnlock() + return c.t1.Contains(key) || c.t2.Contains(key) +} + +// Peek is used to inspect the cache value of a key +// without updating recency or frequency. +func (c *ARCCache) Peek(key interface{}) (interface{}, bool) { + c.lock.RLock() + defer c.lock.RUnlock() + if val, ok := c.t1.Peek(key); ok { + return val, ok + } + return c.t2.Peek(key) +} diff --git a/vendor/github.com/hashicorp/golang-lru/lru.go b/vendor/github.com/hashicorp/golang-lru/lru.go new file mode 100644 index 0000000000..a6285f989e --- /dev/null +++ b/vendor/github.com/hashicorp/golang-lru/lru.go @@ -0,0 +1,114 @@ +// This package provides a simple LRU cache. It is based on the +// LRU implementation in groupcache: +// https://github.com/golang/groupcache/tree/master/lru +package lru + +import ( + "sync" + + "github.com/hashicorp/golang-lru/simplelru" +) + +// Cache is a thread-safe fixed size LRU cache. +type Cache struct { + lru *simplelru.LRU + lock sync.RWMutex +} + +// New creates an LRU of the given size +func New(size int) (*Cache, error) { + return NewWithEvict(size, nil) +} + +// NewWithEvict constructs a fixed size cache with the given eviction +// callback. +func NewWithEvict(size int, onEvicted func(key interface{}, value interface{})) (*Cache, error) { + lru, err := simplelru.NewLRU(size, simplelru.EvictCallback(onEvicted)) + if err != nil { + return nil, err + } + c := &Cache{ + lru: lru, + } + return c, nil +} + +// Purge is used to completely clear the cache +func (c *Cache) Purge() { + c.lock.Lock() + c.lru.Purge() + c.lock.Unlock() +} + +// Add adds a value to the cache. Returns true if an eviction occurred. +func (c *Cache) Add(key, value interface{}) bool { + c.lock.Lock() + defer c.lock.Unlock() + return c.lru.Add(key, value) +} + +// Get looks up a key's value from the cache. +func (c *Cache) Get(key interface{}) (interface{}, bool) { + c.lock.Lock() + defer c.lock.Unlock() + return c.lru.Get(key) +} + +// Check if a key is in the cache, without updating the recent-ness +// or deleting it for being stale. +func (c *Cache) Contains(key interface{}) bool { + c.lock.RLock() + defer c.lock.RUnlock() + return c.lru.Contains(key) +} + +// Returns the key value (or undefined if not found) without updating +// the "recently used"-ness of the key. +func (c *Cache) Peek(key interface{}) (interface{}, bool) { + c.lock.RLock() + defer c.lock.RUnlock() + return c.lru.Peek(key) +} + +// ContainsOrAdd checks if a key is in the cache without updating the +// recent-ness or deleting it for being stale, and if not, adds the value. +// Returns whether found and whether an eviction occurred. +func (c *Cache) ContainsOrAdd(key, value interface{}) (ok, evict bool) { + c.lock.Lock() + defer c.lock.Unlock() + + if c.lru.Contains(key) { + return true, false + } else { + evict := c.lru.Add(key, value) + return false, evict + } +} + +// Remove removes the provided key from the cache. +func (c *Cache) Remove(key interface{}) { + c.lock.Lock() + c.lru.Remove(key) + c.lock.Unlock() +} + +// RemoveOldest removes the oldest item from the cache. +func (c *Cache) RemoveOldest() { + c.lock.Lock() + c.lru.RemoveOldest() + c.lock.Unlock() +} + +// Keys returns a slice of the keys in the cache, from oldest to newest. +func (c *Cache) Keys() []interface{} { + c.lock.RLock() + defer c.lock.RUnlock() + return c.lru.Keys() +} + +// Len returns the number of items in the cache. +func (c *Cache) Len() int { + c.lock.RLock() + defer c.lock.RUnlock() + return c.lru.Len() +} diff --git a/vendor/github.com/hashicorp/golang-lru/simplelru/lru.go b/vendor/github.com/hashicorp/golang-lru/simplelru/lru.go new file mode 100644 index 0000000000..cb416b394f --- /dev/null +++ b/vendor/github.com/hashicorp/golang-lru/simplelru/lru.go @@ -0,0 +1,160 @@ +package simplelru + +import ( + "container/list" + "errors" +) + +// EvictCallback is used to get a callback when a cache entry is evicted +type EvictCallback func(key interface{}, value interface{}) + +// LRU implements a non-thread safe fixed size LRU cache +type LRU struct { + size int + evictList *list.List + items map[interface{}]*list.Element + onEvict EvictCallback +} + +// entry is used to hold a value in the evictList +type entry struct { + key interface{} + value interface{} +} + +// NewLRU constructs an LRU of the given size +func NewLRU(size int, onEvict EvictCallback) (*LRU, error) { + if size <= 0 { + return nil, errors.New("Must provide a positive size") + } + c := &LRU{ + size: size, + evictList: list.New(), + items: make(map[interface{}]*list.Element), + onEvict: onEvict, + } + return c, nil +} + +// Purge is used to completely clear the cache +func (c *LRU) Purge() { + for k, v := range c.items { + if c.onEvict != nil { + c.onEvict(k, v.Value.(*entry).value) + } + delete(c.items, k) + } + c.evictList.Init() +} + +// Add adds a value to the cache. Returns true if an eviction occurred. +func (c *LRU) Add(key, value interface{}) bool { + // Check for existing item + if ent, ok := c.items[key]; ok { + c.evictList.MoveToFront(ent) + ent.Value.(*entry).value = value + return false + } + + // Add new item + ent := &entry{key, value} + entry := c.evictList.PushFront(ent) + c.items[key] = entry + + evict := c.evictList.Len() > c.size + // Verify size not exceeded + if evict { + c.removeOldest() + } + return evict +} + +// Get looks up a key's value from the cache. +func (c *LRU) Get(key interface{}) (value interface{}, ok bool) { + if ent, ok := c.items[key]; ok { + c.evictList.MoveToFront(ent) + return ent.Value.(*entry).value, true + } + return +} + +// Check if a key is in the cache, without updating the recent-ness +// or deleting it for being stale. +func (c *LRU) Contains(key interface{}) (ok bool) { + _, ok = c.items[key] + return ok +} + +// Returns the key value (or undefined if not found) without updating +// the "recently used"-ness of the key. +func (c *LRU) Peek(key interface{}) (value interface{}, ok bool) { + if ent, ok := c.items[key]; ok { + return ent.Value.(*entry).value, true + } + return nil, ok +} + +// Remove removes the provided key from the cache, returning if the +// key was contained. +func (c *LRU) Remove(key interface{}) bool { + if ent, ok := c.items[key]; ok { + c.removeElement(ent) + return true + } + return false +} + +// RemoveOldest removes the oldest item from the cache. +func (c *LRU) RemoveOldest() (interface{}, interface{}, bool) { + ent := c.evictList.Back() + if ent != nil { + c.removeElement(ent) + kv := ent.Value.(*entry) + return kv.key, kv.value, true + } + return nil, nil, false +} + +// GetOldest returns the oldest entry +func (c *LRU) GetOldest() (interface{}, interface{}, bool) { + ent := c.evictList.Back() + if ent != nil { + kv := ent.Value.(*entry) + return kv.key, kv.value, true + } + return nil, nil, false +} + +// Keys returns a slice of the keys in the cache, from oldest to newest. +func (c *LRU) Keys() []interface{} { + keys := make([]interface{}, len(c.items)) + i := 0 + for ent := c.evictList.Back(); ent != nil; ent = ent.Prev() { + keys[i] = ent.Value.(*entry).key + i++ + } + return keys +} + +// Len returns the number of items in the cache. +func (c *LRU) Len() int { + return c.evictList.Len() +} + +// removeOldest removes the oldest item from the cache. +func (c *LRU) removeOldest() { + ent := c.evictList.Back() + if ent != nil { + c.removeElement(ent) + } +} + +// removeElement is used to remove a given list element from the cache +func (c *LRU) removeElement(e *list.Element) { + c.evictList.Remove(e) + kv := e.Value.(*entry) + delete(c.items, kv.key) + if c.onEvict != nil { + c.onEvict(kv.key, kv.value) + } +} diff --git a/vendor/github.com/jonboulle/clockwork/.travis.yml b/vendor/github.com/jonboulle/clockwork/.travis.yml deleted file mode 100644 index aefda90bfa..0000000000 --- a/vendor/github.com/jonboulle/clockwork/.travis.yml +++ /dev/null @@ -1,5 +0,0 @@ -language: go -go: - - 1.3 - -sudo: false diff --git a/vendor/github.com/jonboulle/clockwork/LICENSE b/vendor/github.com/jonboulle/clockwork/LICENSE deleted file mode 100644 index 5c304d1a4a..0000000000 --- a/vendor/github.com/jonboulle/clockwork/LICENSE +++ /dev/null @@ -1,201 +0,0 @@ -Apache License - Version 2.0, January 2004 - http://www.apache.org/licenses/ - - TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION - - 1. Definitions. - - "License" shall mean the terms and conditions for use, reproduction, - and distribution as defined by Sections 1 through 9 of this document. - - "Licensor" shall mean the copyright owner or entity authorized by - the copyright owner that is granting the License. - - "Legal Entity" shall mean the union of the acting entity and all - other entities that control, are controlled by, or are under common - control with that entity. For the purposes of this definition, - "control" means (i) the power, direct or indirect, to cause the - direction or management of such entity, whether by contract or - otherwise, or (ii) ownership of fifty percent (50%) or more of the - outstanding shares, or (iii) beneficial ownership of such entity. - - "You" (or "Your") shall mean an individual or Legal Entity - exercising permissions granted by this License. - - "Source" form shall mean the preferred form for making modifications, - including but not limited to software source code, documentation - source, and configuration files. - - "Object" form shall mean any form resulting from mechanical - transformation or translation of a Source form, including but - not limited to compiled object code, generated documentation, - and conversions to other media types. - - "Work" shall mean the work of authorship, whether in Source or - Object form, made available under the License, as indicated by a - copyright notice that is included in or attached to the work - (an example is provided in the Appendix below). - - "Derivative Works" shall mean any work, whether in Source or Object - form, that is based on (or derived from) the Work and for which the - editorial revisions, annotations, elaborations, or other modifications - represent, as a whole, an original work of authorship. For the purposes - of this License, Derivative Works shall not include works that remain - separable from, or merely link (or bind by name) to the interfaces of, - the Work and Derivative Works thereof. - - "Contribution" shall mean any work of authorship, including - the original version of the Work and any modifications or additions - to that Work or Derivative Works thereof, that is intentionally - submitted to Licensor for inclusion in the Work by the copyright owner - or by an individual or Legal Entity authorized to submit on behalf of - the copyright owner. For the purposes of this definition, "submitted" - means any form of electronic, verbal, or written communication sent - to the Licensor or its representatives, including but not limited to - communication on electronic mailing lists, source code control systems, - and issue tracking systems that are managed by, or on behalf of, the - Licensor for the purpose of discussing and improving the Work, but - excluding communication that is conspicuously marked or otherwise - designated in writing by the copyright owner as "Not a Contribution." - - "Contributor" shall mean Licensor and any individual or Legal Entity - on behalf of whom a Contribution has been received by Licensor and - subsequently incorporated within the Work. - - 2. Grant of Copyright License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - copyright license to reproduce, prepare Derivative Works of, - publicly display, publicly perform, sublicense, and distribute the - Work and such Derivative Works in Source or Object form. - - 3. Grant of Patent License. Subject to the terms and conditions of - this License, each Contributor hereby grants to You a perpetual, - worldwide, non-exclusive, no-charge, royalty-free, irrevocable - (except as stated in this section) patent license to make, have made, - use, offer to sell, sell, import, and otherwise transfer the Work, - where such license applies only to those patent claims licensable - by such Contributor that are necessarily infringed by their - Contribution(s) alone or by combination of their Contribution(s) - with the Work to which such Contribution(s) was submitted. If You - institute patent litigation against any entity (including a - cross-claim or counterclaim in a lawsuit) alleging that the Work - or a Contribution incorporated within the Work constitutes direct - or contributory patent infringement, then any patent licenses - granted to You under this License for that Work shall terminate - as of the date such litigation is filed. - - 4. Redistribution. You may reproduce and distribute copies of the - Work or Derivative Works thereof in any medium, with or without - modifications, and in Source or Object form, provided that You - meet the following conditions: - - (a) You must give any other recipients of the Work or - Derivative Works a copy of this License; and - - (b) You must cause any modified files to carry prominent notices - stating that You changed the files; and - - (c) You must retain, in the Source form of any Derivative Works - that You distribute, all copyright, patent, trademark, and - attribution notices from the Source form of the Work, - excluding those notices that do not pertain to any part of - the Derivative Works; and - - (d) If the Work includes a "NOTICE" text file as part of its - distribution, then any Derivative Works that You distribute must - include a readable copy of the attribution notices contained - within such NOTICE file, excluding those notices that do not - pertain to any part of the Derivative Works, in at least one - of the following places: within a NOTICE text file distributed - as part of the Derivative Works; within the Source form or - documentation, if provided along with the Derivative Works; or, - within a display generated by the Derivative Works, if and - wherever such third-party notices normally appear. The contents - of the NOTICE file are for informational purposes only and - do not modify the License. You may add Your own attribution - notices within Derivative Works that You distribute, alongside - or as an addendum to the NOTICE text from the Work, provided - that such additional attribution notices cannot be construed - as modifying the License. - - You may add Your own copyright statement to Your modifications and - may provide additional or different license terms and conditions - for use, reproduction, or distribution of Your modifications, or - for any such Derivative Works as a whole, provided Your use, - reproduction, and distribution of the Work otherwise complies with - the conditions stated in this License. - - 5. Submission of Contributions. Unless You explicitly state otherwise, - any Contribution intentionally submitted for inclusion in the Work - by You to the Licensor shall be under the terms and conditions of - this License, without any additional terms or conditions. - Notwithstanding the above, nothing herein shall supersede or modify - the terms of any separate license agreement you may have executed - with Licensor regarding such Contributions. - - 6. Trademarks. This License does not grant permission to use the trade - names, trademarks, service marks, or product names of the Licensor, - except as required for reasonable and customary use in describing the - origin of the Work and reproducing the content of the NOTICE file. - - 7. Disclaimer of Warranty. Unless required by applicable law or - agreed to in writing, Licensor provides the Work (and each - Contributor provides its Contributions) on an "AS IS" BASIS, - WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or - implied, including, without limitation, any warranties or conditions - of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A - PARTICULAR PURPOSE. You are solely responsible for determining the - appropriateness of using or redistributing the Work and assume any - risks associated with Your exercise of permissions under this License. - - 8. Limitation of Liability. In no event and under no legal theory, - whether in tort (including negligence), contract, or otherwise, - unless required by applicable law (such as deliberate and grossly - negligent acts) or agreed to in writing, shall any Contributor be - liable to You for damages, including any direct, indirect, special, - incidental, or consequential damages of any character arising as a - result of this License or out of the use or inability to use the - Work (including but not limited to damages for loss of goodwill, - work stoppage, computer failure or malfunction, or any and all - other commercial damages or losses), even if such Contributor - has been advised of the possibility of such damages. - - 9. Accepting Warranty or Additional Liability. While redistributing - the Work or Derivative Works thereof, You may choose to offer, - and charge a fee for, acceptance of support, warranty, indemnity, - or other liability obligations and/or rights consistent with this - License. However, in accepting such obligations, You may act only - on Your own behalf and on Your sole responsibility, not on behalf - of any other Contributor, and only if You agree to indemnify, - defend, and hold each Contributor harmless for any liability - incurred by, or claims asserted against, such Contributor by reason - of your accepting any such warranty or additional liability. - - END OF TERMS AND CONDITIONS - - APPENDIX: How to apply the Apache License to your work. - - To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" - replaced with your own identifying information. (Don't include - the brackets!) The text should be enclosed in the appropriate - comment syntax for the file format. We also recommend that a - file or class name and description of purpose be included on the - same "printed page" as the copyright notice for easier - identification within third-party archives. - - Copyright {yyyy} {name of copyright owner} - - 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. diff --git a/vendor/github.com/jonboulle/clockwork/README.md b/vendor/github.com/jonboulle/clockwork/README.md deleted file mode 100644 index 47bc136b0c..0000000000 --- a/vendor/github.com/jonboulle/clockwork/README.md +++ /dev/null @@ -1,69 +0,0 @@ -clockwork -========= - -[![Build Status](https://travis-ci.org/jonboulle/clockwork.png?branch=master)](https://travis-ci.org/jonboulle/clockwork) -[![godoc](https://godoc.org/github.com/jonboulle/clockwork?status.svg)](http://godoc.org/github.com/jonboulle/clockwork) - -a simple fake clock for golang - -# Usage - -Replace uses of the `time` package with the `clockwork.Clock` interface instead. - -For example, instead of using `time.Sleep` directly: - -``` -func my_func() { - time.Sleep(3 * time.Second) - do_something() -} -``` - -inject a clock and use its `Sleep` method instead: - -``` -func my_func(clock clockwork.Clock) { - clock.Sleep(3 * time.Second) - do_something() -} -``` - -Now you can easily test `my_func` with a `FakeClock`: - -``` -func TestMyFunc(t *testing.T) { - c := clockwork.NewFakeClock() - - // Start our sleepy function - var wg sync.WaitGroup - wg.Add(1) - go func() { - my_func(c) - wg.Done() - }() - - // Ensure we wait until my_func is sleeping - c.BlockUntil(1) - - assert_state() - - // Advance the FakeClock forward in time - c.Advance(3 * time.Second) - - // Wait until the function completes - wg.Wait() - - assert_state() -} -``` - -and in production builds, simply inject the real clock instead: -``` -my_func(clockwork.NewRealClock()) -``` - -See [example_test.go](example_test.go) for a full example. - -# Credits - -clockwork is inspired by @wickman's [threaded fake clock](https://gist.github.com/wickman/3840816), and the [Golang playground](http://blog.golang.org/playground#Faking time) diff --git a/vendor/github.com/jonboulle/clockwork/clockwork.go b/vendor/github.com/jonboulle/clockwork/clockwork.go deleted file mode 100644 index 999fddd51a..0000000000 --- a/vendor/github.com/jonboulle/clockwork/clockwork.go +++ /dev/null @@ -1,179 +0,0 @@ -package clockwork - -import ( - "sync" - "time" -) - -// Clock provides an interface that packages can use instead of directly -// using the time module, so that chronology-related behavior can be tested -type Clock interface { - After(d time.Duration) <-chan time.Time - Sleep(d time.Duration) - Now() time.Time - Since(t time.Time) time.Duration -} - -// FakeClock provides an interface for a clock which can be -// manually advanced through time -type FakeClock interface { - Clock - // Advance advances the FakeClock to a new point in time, ensuring any existing - // sleepers are notified appropriately before returning - Advance(d time.Duration) - // BlockUntil will block until the FakeClock has the given number of - // sleepers (callers of Sleep or After) - BlockUntil(n int) -} - -// NewRealClock returns a Clock which simply delegates calls to the actual time -// package; it should be used by packages in production. -func NewRealClock() Clock { - return &realClock{} -} - -// NewFakeClock returns a FakeClock implementation which can be -// manually advanced through time for testing. The initial time of the -// FakeClock will be an arbitrary non-zero time. -func NewFakeClock() FakeClock { - // use a fixture that does not fulfill Time.IsZero() - return NewFakeClockAt(time.Date(1984, time.April, 4, 0, 0, 0, 0, time.UTC)) -} - -// NewFakeClockAt returns a FakeClock initialised at the given time.Time. -func NewFakeClockAt(t time.Time) FakeClock { - return &fakeClock{ - time: t, - } -} - -type realClock struct{} - -func (rc *realClock) After(d time.Duration) <-chan time.Time { - return time.After(d) -} - -func (rc *realClock) Sleep(d time.Duration) { - time.Sleep(d) -} - -func (rc *realClock) Now() time.Time { - return time.Now() -} - -func (rc *realClock) Since(t time.Time) time.Duration { - return rc.Now().Sub(t) -} - -type fakeClock struct { - sleepers []*sleeper - blockers []*blocker - time time.Time - - l sync.RWMutex -} - -// sleeper represents a caller of After or Sleep -type sleeper struct { - until time.Time - done chan time.Time -} - -// blocker represents a caller of BlockUntil -type blocker struct { - count int - ch chan struct{} -} - -// After mimics time.After; it waits for the given duration to elapse on the -// fakeClock, then sends the current time on the returned channel. -func (fc *fakeClock) After(d time.Duration) <-chan time.Time { - fc.l.Lock() - defer fc.l.Unlock() - now := fc.time - done := make(chan time.Time, 1) - if d.Nanoseconds() == 0 { - // special case - trigger immediately - done <- now - } else { - // otherwise, add to the set of sleepers - s := &sleeper{ - until: now.Add(d), - done: done, - } - fc.sleepers = append(fc.sleepers, s) - // and notify any blockers - fc.blockers = notifyBlockers(fc.blockers, len(fc.sleepers)) - } - return done -} - -// notifyBlockers notifies all the blockers waiting until the -// given number of sleepers are waiting on the fakeClock. It -// returns an updated slice of blockers (i.e. those still waiting) -func notifyBlockers(blockers []*blocker, count int) (newBlockers []*blocker) { - for _, b := range blockers { - if b.count == count { - close(b.ch) - } else { - newBlockers = append(newBlockers, b) - } - } - return -} - -// Sleep blocks until the given duration has passed on the fakeClock -func (fc *fakeClock) Sleep(d time.Duration) { - <-fc.After(d) -} - -// Time returns the current time of the fakeClock -func (fc *fakeClock) Now() time.Time { - fc.l.RLock() - t := fc.time - fc.l.RUnlock() - return t -} - -// Since returns the duration that has passed since the given time on the fakeClock -func (fc *fakeClock) Since(t time.Time) time.Duration { - return fc.Now().Sub(t) -} - -// Advance advances fakeClock to a new point in time, ensuring channels from any -// previous invocations of After are notified appropriately before returning -func (fc *fakeClock) Advance(d time.Duration) { - fc.l.Lock() - defer fc.l.Unlock() - end := fc.time.Add(d) - var newSleepers []*sleeper - for _, s := range fc.sleepers { - if end.Sub(s.until) >= 0 { - s.done <- end - } else { - newSleepers = append(newSleepers, s) - } - } - fc.sleepers = newSleepers - fc.blockers = notifyBlockers(fc.blockers, len(fc.sleepers)) - fc.time = end -} - -// BlockUntil will block until the fakeClock has the given number of sleepers -// (callers of Sleep or After) -func (fc *fakeClock) BlockUntil(n int) { - fc.l.Lock() - // Fast path: current number of sleepers is what we're looking for - if len(fc.sleepers) == n { - fc.l.Unlock() - return - } - // Otherwise, set up a new blocker - b := &blocker{ - count: n, - ch: make(chan struct{}), - } - fc.blockers = append(fc.blockers, b) - fc.l.Unlock() - <-b.ch -} diff --git a/vendor/github.com/juju/ratelimit/ratelimit.go b/vendor/github.com/juju/ratelimit/ratelimit.go index 3ef32fbcc0..1c3f25b2ec 100644 --- a/vendor/github.com/juju/ratelimit/ratelimit.go +++ b/vendor/github.com/juju/ratelimit/ratelimit.go @@ -2,7 +2,7 @@ // Licensed under the LGPLv3 with static-linking exception. // See LICENCE file for details. -// The ratelimit package provides an efficient token bucket implementation +// Package ratelimit provides an efficient token bucket implementation // that can be used to limit the rate of arbitrary things. // See http://en.wikipedia.org/wiki/Token_bucket. package ratelimit @@ -21,6 +21,7 @@ type Bucket struct { capacity int64 quantum int64 fillInterval time.Duration + clock Clock // The mutex guards the fields following it. mu sync.Mutex @@ -33,12 +34,37 @@ type Bucket struct { availTick int64 } +// Clock is used to inject testable fakes. +type Clock interface { + Now() time.Time + Sleep(d time.Duration) +} + +// realClock implements Clock in terms of standard time functions. +type realClock struct{} + +// Now is identical to time.Now. +func (realClock) Now() time.Time { + return time.Now() +} + +// Sleep is identical to time.Sleep. +func (realClock) Sleep(d time.Duration) { + time.Sleep(d) +} + // NewBucket returns a new token bucket that fills at the // rate of one token every fillInterval, up to the given // maximum capacity. Both arguments must be // positive. The bucket is initially full. func NewBucket(fillInterval time.Duration, capacity int64) *Bucket { - return NewBucketWithQuantum(fillInterval, capacity, 1) + return NewBucketWithClock(fillInterval, capacity, realClock{}) +} + +// NewBucketWithClock is identical to NewBucket but injects a testable clock +// interface. +func NewBucketWithClock(fillInterval time.Duration, capacity int64, clock Clock) *Bucket { + return NewBucketWithQuantumAndClock(fillInterval, capacity, 1, clock) } // rateMargin specifes the allowed variance of actual @@ -51,12 +77,18 @@ const rateMargin = 0.01 // at high rates, the actual rate may be up to 1% different from the // specified rate. func NewBucketWithRate(rate float64, capacity int64) *Bucket { + return NewBucketWithRateAndClock(rate, capacity, realClock{}) +} + +// NewBucketWithRateAndClock is identical to NewBucketWithRate but injects a +// testable clock interface. +func NewBucketWithRateAndClock(rate float64, capacity int64, clock Clock) *Bucket { for quantum := int64(1); quantum < 1<<50; quantum = nextQuantum(quantum) { fillInterval := time.Duration(1e9 * float64(quantum) / rate) if fillInterval <= 0 { continue } - tb := NewBucketWithQuantum(fillInterval, capacity, quantum) + tb := NewBucketWithQuantumAndClock(fillInterval, capacity, quantum, clock) if diff := math.Abs(tb.Rate() - rate); diff/rate <= rateMargin { return tb } @@ -79,6 +111,12 @@ func nextQuantum(q int64) int64 { // the specification of the quantum size - quantum tokens // are added every fillInterval. func NewBucketWithQuantum(fillInterval time.Duration, capacity, quantum int64) *Bucket { + return NewBucketWithQuantumAndClock(fillInterval, capacity, quantum, realClock{}) +} + +// NewBucketWithQuantumAndClock is identical to NewBucketWithQuantum but injects +// a testable clock interface. +func NewBucketWithQuantumAndClock(fillInterval time.Duration, capacity, quantum int64, clock Clock) *Bucket { if fillInterval <= 0 { panic("token bucket fill interval is not > 0") } @@ -89,7 +127,8 @@ func NewBucketWithQuantum(fillInterval time.Duration, capacity, quantum int64) * panic("token bucket quantum is not > 0") } return &Bucket{ - startTime: time.Now(), + clock: clock, + startTime: clock.Now(), capacity: capacity, quantum: quantum, avail: capacity, @@ -101,7 +140,7 @@ func NewBucketWithQuantum(fillInterval time.Duration, capacity, quantum int64) * // available. func (tb *Bucket) Wait(count int64) { if d := tb.Take(count); d > 0 { - time.Sleep(d) + tb.clock.Sleep(d) } } @@ -113,7 +152,7 @@ func (tb *Bucket) Wait(count int64) { func (tb *Bucket) WaitMaxDuration(count int64, maxWait time.Duration) bool { d, ok := tb.TakeMaxDuration(count, maxWait) if d > 0 { - time.Sleep(d) + tb.clock.Sleep(d) } return ok } @@ -127,7 +166,7 @@ const infinityDuration time.Duration = 0x7fffffffffffffff // Note that if the request is irrevocable - there is no way to return // tokens to the bucket once this method commits us to taking them. func (tb *Bucket) Take(count int64) time.Duration { - d, _ := tb.take(time.Now(), count, infinityDuration) + d, _ := tb.take(tb.clock.Now(), count, infinityDuration) return d } @@ -141,14 +180,14 @@ func (tb *Bucket) Take(count int64) time.Duration { // wait until the tokens are actually available, and reports // true. func (tb *Bucket) TakeMaxDuration(count int64, maxWait time.Duration) (time.Duration, bool) { - return tb.take(time.Now(), count, maxWait) + return tb.take(tb.clock.Now(), count, maxWait) } // TakeAvailable takes up to count immediately available tokens from the // bucket. It returns the number of tokens removed, or zero if there are // no available tokens. It does not block. func (tb *Bucket) TakeAvailable(count int64) int64 { - return tb.takeAvailable(time.Now(), count) + return tb.takeAvailable(tb.clock.Now(), count) } // takeAvailable is the internal version of TakeAvailable - it takes the @@ -178,7 +217,7 @@ func (tb *Bucket) takeAvailable(now time.Time, count int64) int64 { // tokens could have changed in the meantime. This method is intended // primarily for metrics reporting and debugging. func (tb *Bucket) Available() int64 { - return tb.available(time.Now()) + return tb.available(tb.clock.Now()) } // available is the internal version of available - it takes the current time as diff --git a/vendor/github.com/pborman/uuid/CONTRIBUTORS b/vendor/github.com/pborman/uuid/CONTRIBUTORS deleted file mode 100644 index b382a04eda..0000000000 --- a/vendor/github.com/pborman/uuid/CONTRIBUTORS +++ /dev/null @@ -1 +0,0 @@ -Paul Borman diff --git a/vendor/github.com/pborman/uuid/LICENSE b/vendor/github.com/pborman/uuid/LICENSE deleted file mode 100644 index 5dc68268d9..0000000000 --- a/vendor/github.com/pborman/uuid/LICENSE +++ /dev/null @@ -1,27 +0,0 @@ -Copyright (c) 2009,2014 Google Inc. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above -copyright notice, this list of conditions and the following disclaimer -in the documentation and/or other materials provided with the -distribution. - * Neither the name of Google Inc. nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/github.com/pborman/uuid/dce.go b/vendor/github.com/pborman/uuid/dce.go deleted file mode 100755 index 50a0f2d099..0000000000 --- a/vendor/github.com/pborman/uuid/dce.go +++ /dev/null @@ -1,84 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import ( - "encoding/binary" - "fmt" - "os" -) - -// A Domain represents a Version 2 domain -type Domain byte - -// Domain constants for DCE Security (Version 2) UUIDs. -const ( - Person = Domain(0) - Group = Domain(1) - Org = Domain(2) -) - -// NewDCESecurity returns a DCE Security (Version 2) UUID. -// -// The domain should be one of Person, Group or Org. -// On a POSIX system the id should be the users UID for the Person -// domain and the users GID for the Group. The meaning of id for -// the domain Org or on non-POSIX systems is site defined. -// -// For a given domain/id pair the same token may be returned for up to -// 7 minutes and 10 seconds. -func NewDCESecurity(domain Domain, id uint32) UUID { - uuid := NewUUID() - if uuid != nil { - uuid[6] = (uuid[6] & 0x0f) | 0x20 // Version 2 - uuid[9] = byte(domain) - binary.BigEndian.PutUint32(uuid[0:], id) - } - return uuid -} - -// NewDCEPerson returns a DCE Security (Version 2) UUID in the person -// domain with the id returned by os.Getuid. -// -// NewDCEPerson(Person, uint32(os.Getuid())) -func NewDCEPerson() UUID { - return NewDCESecurity(Person, uint32(os.Getuid())) -} - -// NewDCEGroup returns a DCE Security (Version 2) UUID in the group -// domain with the id returned by os.Getgid. -// -// NewDCEGroup(Group, uint32(os.Getgid())) -func NewDCEGroup() UUID { - return NewDCESecurity(Group, uint32(os.Getgid())) -} - -// Domain returns the domain for a Version 2 UUID or false. -func (uuid UUID) Domain() (Domain, bool) { - if v, _ := uuid.Version(); v != 2 { - return 0, false - } - return Domain(uuid[9]), true -} - -// Id returns the id for a Version 2 UUID or false. -func (uuid UUID) Id() (uint32, bool) { - if v, _ := uuid.Version(); v != 2 { - return 0, false - } - return binary.BigEndian.Uint32(uuid[0:4]), true -} - -func (d Domain) String() string { - switch d { - case Person: - return "Person" - case Group: - return "Group" - case Org: - return "Org" - } - return fmt.Sprintf("Domain%d", int(d)) -} diff --git a/vendor/github.com/pborman/uuid/doc.go b/vendor/github.com/pborman/uuid/doc.go deleted file mode 100755 index d8bd013e68..0000000000 --- a/vendor/github.com/pborman/uuid/doc.go +++ /dev/null @@ -1,8 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// The uuid package generates and inspects UUIDs. -// -// UUIDs are based on RFC 4122 and DCE 1.1: Authentication and Security Services. -package uuid diff --git a/vendor/github.com/pborman/uuid/hash.go b/vendor/github.com/pborman/uuid/hash.go deleted file mode 100644 index cdd4192fd9..0000000000 --- a/vendor/github.com/pborman/uuid/hash.go +++ /dev/null @@ -1,53 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import ( - "crypto/md5" - "crypto/sha1" - "hash" -) - -// Well known Name Space IDs and UUIDs -var ( - NameSpace_DNS = Parse("6ba7b810-9dad-11d1-80b4-00c04fd430c8") - NameSpace_URL = Parse("6ba7b811-9dad-11d1-80b4-00c04fd430c8") - NameSpace_OID = Parse("6ba7b812-9dad-11d1-80b4-00c04fd430c8") - NameSpace_X500 = Parse("6ba7b814-9dad-11d1-80b4-00c04fd430c8") - NIL = Parse("00000000-0000-0000-0000-000000000000") -) - -// NewHash returns a new UUID dervied from the hash of space concatenated with -// data generated by h. The hash should be at least 16 byte in length. The -// first 16 bytes of the hash are used to form the UUID. The version of the -// UUID will be the lower 4 bits of version. NewHash is used to implement -// NewMD5 and NewSHA1. -func NewHash(h hash.Hash, space UUID, data []byte, version int) UUID { - h.Reset() - h.Write(space) - h.Write([]byte(data)) - s := h.Sum(nil) - uuid := make([]byte, 16) - copy(uuid, s) - uuid[6] = (uuid[6] & 0x0f) | uint8((version&0xf)<<4) - uuid[8] = (uuid[8] & 0x3f) | 0x80 // RFC 4122 variant - return uuid -} - -// NewMD5 returns a new MD5 (Version 3) UUID based on the -// supplied name space and data. -// -// NewHash(md5.New(), space, data, 3) -func NewMD5(space UUID, data []byte) UUID { - return NewHash(md5.New(), space, data, 3) -} - -// NewSHA1 returns a new SHA1 (Version 5) UUID based on the -// supplied name space and data. -// -// NewHash(sha1.New(), space, data, 5) -func NewSHA1(space UUID, data []byte) UUID { - return NewHash(sha1.New(), space, data, 5) -} diff --git a/vendor/github.com/pborman/uuid/json.go b/vendor/github.com/pborman/uuid/json.go deleted file mode 100644 index 760580a504..0000000000 --- a/vendor/github.com/pborman/uuid/json.go +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright 2014 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import "errors" - -func (u UUID) MarshalJSON() ([]byte, error) { - if len(u) == 0 { - return []byte(`""`), nil - } - return []byte(`"` + u.String() + `"`), nil -} - -func (u *UUID) UnmarshalJSON(data []byte) error { - if len(data) == 0 || string(data) == `""` { - return nil - } - if len(data) < 2 || data[0] != '"' || data[len(data)-1] != '"' { - return errors.New("invalid UUID format") - } - data = data[1 : len(data)-1] - uu := Parse(string(data)) - if uu == nil { - return errors.New("invalid UUID format") - } - *u = uu - return nil -} diff --git a/vendor/github.com/pborman/uuid/node.go b/vendor/github.com/pborman/uuid/node.go deleted file mode 100755 index dd0a8ac189..0000000000 --- a/vendor/github.com/pborman/uuid/node.go +++ /dev/null @@ -1,101 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import "net" - -var ( - interfaces []net.Interface // cached list of interfaces - ifname string // name of interface being used - nodeID []byte // hardware for version 1 UUIDs -) - -// NodeInterface returns the name of the interface from which the NodeID was -// derived. The interface "user" is returned if the NodeID was set by -// SetNodeID. -func NodeInterface() string { - return ifname -} - -// SetNodeInterface selects the hardware address to be used for Version 1 UUIDs. -// If name is "" then the first usable interface found will be used or a random -// Node ID will be generated. If a named interface cannot be found then false -// is returned. -// -// SetNodeInterface never fails when name is "". -func SetNodeInterface(name string) bool { - if interfaces == nil { - var err error - interfaces, err = net.Interfaces() - if err != nil && name != "" { - return false - } - } - - for _, ifs := range interfaces { - if len(ifs.HardwareAddr) >= 6 && (name == "" || name == ifs.Name) { - if setNodeID(ifs.HardwareAddr) { - ifname = ifs.Name - return true - } - } - } - - // We found no interfaces with a valid hardware address. If name - // does not specify a specific interface generate a random Node ID - // (section 4.1.6) - if name == "" { - if nodeID == nil { - nodeID = make([]byte, 6) - } - randomBits(nodeID) - return true - } - return false -} - -// NodeID returns a slice of a copy of the current Node ID, setting the Node ID -// if not already set. -func NodeID() []byte { - if nodeID == nil { - SetNodeInterface("") - } - nid := make([]byte, 6) - copy(nid, nodeID) - return nid -} - -// SetNodeID sets the Node ID to be used for Version 1 UUIDs. The first 6 bytes -// of id are used. If id is less than 6 bytes then false is returned and the -// Node ID is not set. -func SetNodeID(id []byte) bool { - if setNodeID(id) { - ifname = "user" - return true - } - return false -} - -func setNodeID(id []byte) bool { - if len(id) < 6 { - return false - } - if nodeID == nil { - nodeID = make([]byte, 6) - } - copy(nodeID, id) - return true -} - -// NodeID returns the 6 byte node id encoded in uuid. It returns nil if uuid is -// not valid. The NodeID is only well defined for version 1 and 2 UUIDs. -func (uuid UUID) NodeID() []byte { - if len(uuid) != 16 { - return nil - } - node := make([]byte, 6) - copy(node, uuid[10:]) - return node -} diff --git a/vendor/github.com/pborman/uuid/time.go b/vendor/github.com/pborman/uuid/time.go deleted file mode 100755 index 7ebc9bef10..0000000000 --- a/vendor/github.com/pborman/uuid/time.go +++ /dev/null @@ -1,132 +0,0 @@ -// Copyright 2014 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import ( - "encoding/binary" - "sync" - "time" -) - -// A Time represents a time as the number of 100's of nanoseconds since 15 Oct -// 1582. -type Time int64 - -const ( - lillian = 2299160 // Julian day of 15 Oct 1582 - unix = 2440587 // Julian day of 1 Jan 1970 - epoch = unix - lillian // Days between epochs - g1582 = epoch * 86400 // seconds between epochs - g1582ns100 = g1582 * 10000000 // 100s of a nanoseconds between epochs -) - -var ( - mu sync.Mutex - lasttime uint64 // last time we returned - clock_seq uint16 // clock sequence for this run - - timeNow = time.Now // for testing -) - -// UnixTime converts t the number of seconds and nanoseconds using the Unix -// epoch of 1 Jan 1970. -func (t Time) UnixTime() (sec, nsec int64) { - sec = int64(t - g1582ns100) - nsec = (sec % 10000000) * 100 - sec /= 10000000 - return sec, nsec -} - -// GetTime returns the current Time (100s of nanoseconds since 15 Oct 1582) and -// clock sequence as well as adjusting the clock sequence as needed. An error -// is returned if the current time cannot be determined. -func GetTime() (Time, uint16, error) { - defer mu.Unlock() - mu.Lock() - return getTime() -} - -func getTime() (Time, uint16, error) { - t := timeNow() - - // If we don't have a clock sequence already, set one. - if clock_seq == 0 { - setClockSequence(-1) - } - now := uint64(t.UnixNano()/100) + g1582ns100 - - // If time has gone backwards with this clock sequence then we - // increment the clock sequence - if now <= lasttime { - clock_seq = ((clock_seq + 1) & 0x3fff) | 0x8000 - } - lasttime = now - return Time(now), clock_seq, nil -} - -// ClockSequence returns the current clock sequence, generating one if not -// already set. The clock sequence is only used for Version 1 UUIDs. -// -// The uuid package does not use global static storage for the clock sequence or -// the last time a UUID was generated. Unless SetClockSequence a new random -// clock sequence is generated the first time a clock sequence is requested by -// ClockSequence, GetTime, or NewUUID. (section 4.2.1.1) sequence is generated -// for -func ClockSequence() int { - defer mu.Unlock() - mu.Lock() - return clockSequence() -} - -func clockSequence() int { - if clock_seq == 0 { - setClockSequence(-1) - } - return int(clock_seq & 0x3fff) -} - -// SetClockSeq sets the clock sequence to the lower 14 bits of seq. Setting to -// -1 causes a new sequence to be generated. -func SetClockSequence(seq int) { - defer mu.Unlock() - mu.Lock() - setClockSequence(seq) -} - -func setClockSequence(seq int) { - if seq == -1 { - var b [2]byte - randomBits(b[:]) // clock sequence - seq = int(b[0])<<8 | int(b[1]) - } - old_seq := clock_seq - clock_seq = uint16(seq&0x3fff) | 0x8000 // Set our variant - if old_seq != clock_seq { - lasttime = 0 - } -} - -// Time returns the time in 100s of nanoseconds since 15 Oct 1582 encoded in -// uuid. It returns false if uuid is not valid. The time is only well defined -// for version 1 and 2 UUIDs. -func (uuid UUID) Time() (Time, bool) { - if len(uuid) != 16 { - return 0, false - } - time := int64(binary.BigEndian.Uint32(uuid[0:4])) - time |= int64(binary.BigEndian.Uint16(uuid[4:6])) << 32 - time |= int64(binary.BigEndian.Uint16(uuid[6:8])&0xfff) << 48 - return Time(time), true -} - -// ClockSequence returns the clock sequence encoded in uuid. It returns false -// if uuid is not valid. The clock sequence is only well defined for version 1 -// and 2 UUIDs. -func (uuid UUID) ClockSequence() (int, bool) { - if len(uuid) != 16 { - return 0, false - } - return int(binary.BigEndian.Uint16(uuid[8:10])) & 0x3fff, true -} diff --git a/vendor/github.com/pborman/uuid/util.go b/vendor/github.com/pborman/uuid/util.go deleted file mode 100644 index de40b102c4..0000000000 --- a/vendor/github.com/pborman/uuid/util.go +++ /dev/null @@ -1,43 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import ( - "io" -) - -// randomBits completely fills slice b with random data. -func randomBits(b []byte) { - if _, err := io.ReadFull(rander, b); err != nil { - panic(err.Error()) // rand should never fail - } -} - -// xvalues returns the value of a byte as a hexadecimal digit or 255. -var xvalues = []byte{ - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 255, 255, 255, 255, 255, 255, - 255, 10, 11, 12, 13, 14, 15, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 10, 11, 12, 13, 14, 15, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, - 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, -} - -// xtob converts the the first two hex bytes of x into a byte. -func xtob(x string) (byte, bool) { - b1 := xvalues[x[0]] - b2 := xvalues[x[1]] - return (b1 << 4) | b2, b1 != 255 && b2 != 255 -} diff --git a/vendor/github.com/pborman/uuid/uuid.go b/vendor/github.com/pborman/uuid/uuid.go deleted file mode 100755 index 2920fae632..0000000000 --- a/vendor/github.com/pborman/uuid/uuid.go +++ /dev/null @@ -1,163 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import ( - "bytes" - "crypto/rand" - "fmt" - "io" - "strings" -) - -// A UUID is a 128 bit (16 byte) Universal Unique IDentifier as defined in RFC -// 4122. -type UUID []byte - -// A Version represents a UUIDs version. -type Version byte - -// A Variant represents a UUIDs variant. -type Variant byte - -// Constants returned by Variant. -const ( - Invalid = Variant(iota) // Invalid UUID - RFC4122 // The variant specified in RFC4122 - Reserved // Reserved, NCS backward compatibility. - Microsoft // Reserved, Microsoft Corporation backward compatibility. - Future // Reserved for future definition. -) - -var rander = rand.Reader // random function - -// New returns a new random (version 4) UUID as a string. It is a convenience -// function for NewRandom().String(). -func New() string { - return NewRandom().String() -} - -// Parse decodes s into a UUID or returns nil. Both the UUID form of -// xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx and -// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx are decoded. -func Parse(s string) UUID { - if len(s) == 36+9 { - if strings.ToLower(s[:9]) != "urn:uuid:" { - return nil - } - s = s[9:] - } else if len(s) != 36 { - return nil - } - if s[8] != '-' || s[13] != '-' || s[18] != '-' || s[23] != '-' { - return nil - } - uuid := make([]byte, 16) - for i, x := range []int{ - 0, 2, 4, 6, - 9, 11, - 14, 16, - 19, 21, - 24, 26, 28, 30, 32, 34} { - if v, ok := xtob(s[x:]); !ok { - return nil - } else { - uuid[i] = v - } - } - return uuid -} - -// Equal returns true if uuid1 and uuid2 are equal. -func Equal(uuid1, uuid2 UUID) bool { - return bytes.Equal(uuid1, uuid2) -} - -// String returns the string form of uuid, xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx -// , or "" if uuid is invalid. -func (uuid UUID) String() string { - if uuid == nil || len(uuid) != 16 { - return "" - } - b := []byte(uuid) - return fmt.Sprintf("%08x-%04x-%04x-%04x-%012x", - b[:4], b[4:6], b[6:8], b[8:10], b[10:]) -} - -// URN returns the RFC 2141 URN form of uuid, -// urn:uuid:xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx, or "" if uuid is invalid. -func (uuid UUID) URN() string { - if uuid == nil || len(uuid) != 16 { - return "" - } - b := []byte(uuid) - return fmt.Sprintf("urn:uuid:%08x-%04x-%04x-%04x-%012x", - b[:4], b[4:6], b[6:8], b[8:10], b[10:]) -} - -// Variant returns the variant encoded in uuid. It returns Invalid if -// uuid is invalid. -func (uuid UUID) Variant() Variant { - if len(uuid) != 16 { - return Invalid - } - switch { - case (uuid[8] & 0xc0) == 0x80: - return RFC4122 - case (uuid[8] & 0xe0) == 0xc0: - return Microsoft - case (uuid[8] & 0xe0) == 0xe0: - return Future - default: - return Reserved - } - panic("unreachable") -} - -// Version returns the verison of uuid. It returns false if uuid is not -// valid. -func (uuid UUID) Version() (Version, bool) { - if len(uuid) != 16 { - return 0, false - } - return Version(uuid[6] >> 4), true -} - -func (v Version) String() string { - if v > 15 { - return fmt.Sprintf("BAD_VERSION_%d", v) - } - return fmt.Sprintf("VERSION_%d", v) -} - -func (v Variant) String() string { - switch v { - case RFC4122: - return "RFC4122" - case Reserved: - return "Reserved" - case Microsoft: - return "Microsoft" - case Future: - return "Future" - case Invalid: - return "Invalid" - } - return fmt.Sprintf("BadVariant%d", int(v)) -} - -// SetRand sets the random number generator to r, which implents io.Reader. -// If r.Read returns an error when the package requests random data then -// a panic will be issued. -// -// Calling SetRand with nil sets the random number generator to the default -// generator. -func SetRand(r io.Reader) { - if r == nil { - rander = rand.Reader - return - } - rander = r -} diff --git a/vendor/github.com/pborman/uuid/version1.go b/vendor/github.com/pborman/uuid/version1.go deleted file mode 100644 index 0127eacfab..0000000000 --- a/vendor/github.com/pborman/uuid/version1.go +++ /dev/null @@ -1,41 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -import ( - "encoding/binary" -) - -// NewUUID returns a Version 1 UUID based on the current NodeID and clock -// sequence, and the current time. If the NodeID has not been set by SetNodeID -// or SetNodeInterface then it will be set automatically. If the NodeID cannot -// be set NewUUID returns nil. If clock sequence has not been set by -// SetClockSequence then it will be set automatically. If GetTime fails to -// return the current NewUUID returns nil. -func NewUUID() UUID { - if nodeID == nil { - SetNodeInterface("") - } - - now, seq, err := GetTime() - if err != nil { - return nil - } - - uuid := make([]byte, 16) - - time_low := uint32(now & 0xffffffff) - time_mid := uint16((now >> 32) & 0xffff) - time_hi := uint16((now >> 48) & 0x0fff) - time_hi |= 0x1000 // Version 1 - - binary.BigEndian.PutUint32(uuid[0:], time_low) - binary.BigEndian.PutUint16(uuid[4:], time_mid) - binary.BigEndian.PutUint16(uuid[6:], time_hi) - binary.BigEndian.PutUint16(uuid[8:], seq) - copy(uuid[10:], nodeID) - - return uuid -} diff --git a/vendor/github.com/pborman/uuid/version4.go b/vendor/github.com/pborman/uuid/version4.go deleted file mode 100644 index b3d4a368dd..0000000000 --- a/vendor/github.com/pborman/uuid/version4.go +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2011 Google Inc. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package uuid - -// Random returns a Random (Version 4) UUID or panics. -// -// The strength of the UUIDs is based on the strength of the crypto/rand -// package. -// -// A note about uniqueness derived from from the UUID Wikipedia entry: -// -// Randomly generated UUIDs have 122 random bits. One's annual risk of being -// hit by a meteorite is estimated to be one chance in 17 billion, that -// means the probability is about 0.00000000006 (6 × 10−11), -// equivalent to the odds of creating a few tens of trillions of UUIDs in a -// year and having one duplicate. -func NewRandom() UUID { - uuid := make([]byte, 16) - randomBits([]byte(uuid)) - uuid[6] = (uuid[6] & 0x0f) | 0x40 // Version 4 - uuid[8] = (uuid[8] & 0x3f) | 0x80 // Variant is 10 - return uuid -} diff --git a/vendor/github.com/prometheus/client_golang/AUTHORS.md b/vendor/github.com/prometheus/client_golang/AUTHORS.md deleted file mode 100644 index c5275d5ab1..0000000000 --- a/vendor/github.com/prometheus/client_golang/AUTHORS.md +++ /dev/null @@ -1,18 +0,0 @@ -The Prometheus project was started by Matt T. Proud (emeritus) and -Julius Volz in 2012. - -Maintainers of this repository: - -* Björn Rabenstein - -The following individuals have contributed code to this repository -(listed in alphabetical order): - -* Bernerd Schaefer -* Björn Rabenstein -* Daniel Bornkessel -* Jeff Younker -* Julius Volz -* Matt T. Proud -* Tobias Schmidt - diff --git a/vendor/github.com/prometheus/client_golang/prometheus/registry.go b/vendor/github.com/prometheus/client_golang/prometheus/registry.go index 41bcf61dc0..32a3986b06 100644 --- a/vendor/github.com/prometheus/client_golang/prometheus/registry.go +++ b/vendor/github.com/prometheus/client_golang/prometheus/registry.go @@ -409,9 +409,9 @@ func (r *Registry) MustRegister(cs ...Collector) { // Gather implements Gatherer. func (r *Registry) Gather() ([]*dto.MetricFamily, error) { var ( - metricChan = make(chan Metric, capMetricChan) - //metricHashes = map[uint64]struct{}{} - //dimHashes = map[string]uint64{} + metricChan = make(chan Metric, capMetricChan) + metricHashes = map[uint64]struct{}{} + dimHashes = map[string]uint64{} wg sync.WaitGroup errs MultiError // The collected errors to return in the end. registeredDescIDs map[uint64]struct{} // Only used for pedantic checks @@ -542,10 +542,10 @@ func (r *Registry) Gather() ([]*dto.MetricFamily, error) { } metricFamiliesByName[desc.fqName] = metricFamily } - //if err := checkMetricConsistency(metricFamily, dtoMetric, metricHashes, dimHashes); err != nil { - //errs = append(errs, err) - //continue - //} + if err := checkMetricConsistency(metricFamily, dtoMetric, metricHashes, dimHashes); err != nil { + errs = append(errs, err) + continue + } if r.pedanticChecksEnabled { // Is the desc registered at all? if _, exist := registeredDescIDs[desc.id]; !exist { @@ -587,9 +587,9 @@ type Gatherers []Gatherer func (gs Gatherers) Gather() ([]*dto.MetricFamily, error) { var ( metricFamiliesByName = map[string]*dto.MetricFamily{} - //metricHashes = map[uint64]struct{}{} - //dimHashes = map[string]uint64{} - errs MultiError // The collected errors to return in the end. + metricHashes = map[uint64]struct{}{} + dimHashes = map[string]uint64{} + errs MultiError // The collected errors to return in the end. ) for i, g := range gs { @@ -628,10 +628,10 @@ func (gs Gatherers) Gather() ([]*dto.MetricFamily, error) { metricFamiliesByName[mf.GetName()] = existingMF } for _, m := range mf.Metric { - //if err := checkMetricConsistency(existingMF, m, metricHashes, dimHashes); err != nil { - //errs = append(errs, err) - //continue - //} + if err := checkMetricConsistency(existingMF, m, metricHashes, dimHashes); err != nil { + errs = append(errs, err) + continue + } existingMF.Metric = append(existingMF.Metric, m) } } diff --git a/vendor/github.com/prometheus/procfs/MAINTAINERS.md b/vendor/github.com/prometheus/procfs/MAINTAINERS.md deleted file mode 100644 index 35993c41c2..0000000000 --- a/vendor/github.com/prometheus/procfs/MAINTAINERS.md +++ /dev/null @@ -1 +0,0 @@ -* Tobias Schmidt diff --git a/vendor/github.com/prometheus/procfs/buddyinfo.go b/vendor/github.com/prometheus/procfs/buddyinfo.go deleted file mode 100644 index 680a9842a4..0000000000 --- a/vendor/github.com/prometheus/procfs/buddyinfo.go +++ /dev/null @@ -1,95 +0,0 @@ -// Copyright 2017 The Prometheus Authors -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package procfs - -import ( - "bufio" - "fmt" - "io" - "os" - "strconv" - "strings" -) - -// A BuddyInfo is the details parsed from /proc/buddyinfo. -// The data is comprised of an array of free fragments of each size. -// The sizes are 2^n*PAGE_SIZE, where n is the array index. -type BuddyInfo struct { - Node string - Zone string - Sizes []float64 -} - -// NewBuddyInfo reads the buddyinfo statistics. -func NewBuddyInfo() ([]BuddyInfo, error) { - fs, err := NewFS(DefaultMountPoint) - if err != nil { - return nil, err - } - - return fs.NewBuddyInfo() -} - -// NewBuddyInfo reads the buddyinfo statistics from the specified `proc` filesystem. -func (fs FS) NewBuddyInfo() ([]BuddyInfo, error) { - file, err := os.Open(fs.Path("buddyinfo")) - if err != nil { - return nil, err - } - defer file.Close() - - return parseBuddyInfo(file) -} - -func parseBuddyInfo(r io.Reader) ([]BuddyInfo, error) { - var ( - buddyInfo = []BuddyInfo{} - scanner = bufio.NewScanner(r) - bucketCount = -1 - ) - - for scanner.Scan() { - var err error - line := scanner.Text() - parts := strings.Fields(string(line)) - - if len(parts) < 4 { - return nil, fmt.Errorf("invalid number of fields when parsing buddyinfo") - } - - node := strings.TrimRight(parts[1], ",") - zone := strings.TrimRight(parts[3], ",") - arraySize := len(parts[4:]) - - if bucketCount == -1 { - bucketCount = arraySize - } else { - if bucketCount != arraySize { - return nil, fmt.Errorf("mismatch in number of buddyinfo buckets, previous count %d, new count %d", bucketCount, arraySize) - } - } - - sizes := make([]float64, arraySize) - for i := 0; i < arraySize; i++ { - sizes[i], err = strconv.ParseFloat(parts[i+4], 64) - if err != nil { - return nil, fmt.Errorf("invalid value in buddyinfo: %s", err) - } - } - - buddyInfo = append(buddyInfo, BuddyInfo{node, zone, sizes}) - } - - return buddyInfo, scanner.Err() -} diff --git a/vendor/github.com/prometheus/procfs/mountstats.go b/vendor/github.com/prometheus/procfs/mountstats.go deleted file mode 100644 index 6b2b0ba9d9..0000000000 --- a/vendor/github.com/prometheus/procfs/mountstats.go +++ /dev/null @@ -1,556 +0,0 @@ -package procfs - -// While implementing parsing of /proc/[pid]/mountstats, this blog was used -// heavily as a reference: -// https://utcc.utoronto.ca/~cks/space/blog/linux/NFSMountstatsIndex -// -// Special thanks to Chris Siebenmann for all of his posts explaining the -// various statistics available for NFS. - -import ( - "bufio" - "fmt" - "io" - "strconv" - "strings" - "time" -) - -// Constants shared between multiple functions. -const ( - deviceEntryLen = 8 - - fieldBytesLen = 8 - fieldEventsLen = 27 - - statVersion10 = "1.0" - statVersion11 = "1.1" - - fieldTransport10Len = 10 - fieldTransport11Len = 13 -) - -// A Mount is a device mount parsed from /proc/[pid]/mountstats. -type Mount struct { - // Name of the device. - Device string - // The mount point of the device. - Mount string - // The filesystem type used by the device. - Type string - // If available additional statistics related to this Mount. - // Use a type assertion to determine if additional statistics are available. - Stats MountStats -} - -// A MountStats is a type which contains detailed statistics for a specific -// type of Mount. -type MountStats interface { - mountStats() -} - -// A MountStatsNFS is a MountStats implementation for NFSv3 and v4 mounts. -type MountStatsNFS struct { - // The version of statistics provided. - StatVersion string - // The age of the NFS mount. - Age time.Duration - // Statistics related to byte counters for various operations. - Bytes NFSBytesStats - // Statistics related to various NFS event occurrences. - Events NFSEventsStats - // Statistics broken down by filesystem operation. - Operations []NFSOperationStats - // Statistics about the NFS RPC transport. - Transport NFSTransportStats -} - -// mountStats implements MountStats. -func (m MountStatsNFS) mountStats() {} - -// A NFSBytesStats contains statistics about the number of bytes read and written -// by an NFS client to and from an NFS server. -type NFSBytesStats struct { - // Number of bytes read using the read() syscall. - Read uint64 - // Number of bytes written using the write() syscall. - Write uint64 - // Number of bytes read using the read() syscall in O_DIRECT mode. - DirectRead uint64 - // Number of bytes written using the write() syscall in O_DIRECT mode. - DirectWrite uint64 - // Number of bytes read from the NFS server, in total. - ReadTotal uint64 - // Number of bytes written to the NFS server, in total. - WriteTotal uint64 - // Number of pages read directly via mmap()'d files. - ReadPages uint64 - // Number of pages written directly via mmap()'d files. - WritePages uint64 -} - -// A NFSEventsStats contains statistics about NFS event occurrences. -type NFSEventsStats struct { - // Number of times cached inode attributes are re-validated from the server. - InodeRevalidate uint64 - // Number of times cached dentry nodes are re-validated from the server. - DnodeRevalidate uint64 - // Number of times an inode cache is cleared. - DataInvalidate uint64 - // Number of times cached inode attributes are invalidated. - AttributeInvalidate uint64 - // Number of times files or directories have been open()'d. - VFSOpen uint64 - // Number of times a directory lookup has occurred. - VFSLookup uint64 - // Number of times permissions have been checked. - VFSAccess uint64 - // Number of updates (and potential writes) to pages. - VFSUpdatePage uint64 - // Number of pages read directly via mmap()'d files. - VFSReadPage uint64 - // Number of times a group of pages have been read. - VFSReadPages uint64 - // Number of pages written directly via mmap()'d files. - VFSWritePage uint64 - // Number of times a group of pages have been written. - VFSWritePages uint64 - // Number of times directory entries have been read with getdents(). - VFSGetdents uint64 - // Number of times attributes have been set on inodes. - VFSSetattr uint64 - // Number of pending writes that have been forcefully flushed to the server. - VFSFlush uint64 - // Number of times fsync() has been called on directories and files. - VFSFsync uint64 - // Number of times locking has been attempted on a file. - VFSLock uint64 - // Number of times files have been closed and released. - VFSFileRelease uint64 - // Unknown. Possibly unused. - CongestionWait uint64 - // Number of times files have been truncated. - Truncation uint64 - // Number of times a file has been grown due to writes beyond its existing end. - WriteExtension uint64 - // Number of times a file was removed while still open by another process. - SillyRename uint64 - // Number of times the NFS server gave less data than expected while reading. - ShortRead uint64 - // Number of times the NFS server wrote less data than expected while writing. - ShortWrite uint64 - // Number of times the NFS server indicated EJUKEBOX; retrieving data from - // offline storage. - JukeboxDelay uint64 - // Number of NFS v4.1+ pNFS reads. - PNFSRead uint64 - // Number of NFS v4.1+ pNFS writes. - PNFSWrite uint64 -} - -// A NFSOperationStats contains statistics for a single operation. -type NFSOperationStats struct { - // The name of the operation. - Operation string - // Number of requests performed for this operation. - Requests uint64 - // Number of times an actual RPC request has been transmitted for this operation. - Transmissions uint64 - // Number of times a request has had a major timeout. - MajorTimeouts uint64 - // Number of bytes sent for this operation, including RPC headers and payload. - BytesSent uint64 - // Number of bytes received for this operation, including RPC headers and payload. - BytesReceived uint64 - // Duration all requests spent queued for transmission before they were sent. - CumulativeQueueTime time.Duration - // Duration it took to get a reply back after the request was transmitted. - CumulativeTotalResponseTime time.Duration - // Duration from when a request was enqueued to when it was completely handled. - CumulativeTotalRequestTime time.Duration -} - -// A NFSTransportStats contains statistics for the NFS mount RPC requests and -// responses. -type NFSTransportStats struct { - // The local port used for the NFS mount. - Port uint64 - // Number of times the client has had to establish a connection from scratch - // to the NFS server. - Bind uint64 - // Number of times the client has made a TCP connection to the NFS server. - Connect uint64 - // Duration (in jiffies, a kernel internal unit of time) the NFS mount has - // spent waiting for connections to the server to be established. - ConnectIdleTime uint64 - // Duration since the NFS mount last saw any RPC traffic. - IdleTime time.Duration - // Number of RPC requests for this mount sent to the NFS server. - Sends uint64 - // Number of RPC responses for this mount received from the NFS server. - Receives uint64 - // Number of times the NFS server sent a response with a transaction ID - // unknown to this client. - BadTransactionIDs uint64 - // A running counter, incremented on each request as the current difference - // ebetween sends and receives. - CumulativeActiveRequests uint64 - // A running counter, incremented on each request by the current backlog - // queue size. - CumulativeBacklog uint64 - - // Stats below only available with stat version 1.1. - - // Maximum number of simultaneously active RPC requests ever used. - MaximumRPCSlotsUsed uint64 - // A running counter, incremented on each request as the current size of the - // sending queue. - CumulativeSendingQueue uint64 - // A running counter, incremented on each request as the current size of the - // pending queue. - CumulativePendingQueue uint64 -} - -// parseMountStats parses a /proc/[pid]/mountstats file and returns a slice -// of Mount structures containing detailed information about each mount. -// If available, statistics for each mount are parsed as well. -func parseMountStats(r io.Reader) ([]*Mount, error) { - const ( - device = "device" - statVersionPrefix = "statvers=" - - nfs3Type = "nfs" - nfs4Type = "nfs4" - ) - - var mounts []*Mount - - s := bufio.NewScanner(r) - for s.Scan() { - // Only look for device entries in this function - ss := strings.Fields(string(s.Bytes())) - if len(ss) == 0 || ss[0] != device { - continue - } - - m, err := parseMount(ss) - if err != nil { - return nil, err - } - - // Does this mount also possess statistics information? - if len(ss) > deviceEntryLen { - // Only NFSv3 and v4 are supported for parsing statistics - if m.Type != nfs3Type && m.Type != nfs4Type { - return nil, fmt.Errorf("cannot parse MountStats for fstype %q", m.Type) - } - - statVersion := strings.TrimPrefix(ss[8], statVersionPrefix) - - stats, err := parseMountStatsNFS(s, statVersion) - if err != nil { - return nil, err - } - - m.Stats = stats - } - - mounts = append(mounts, m) - } - - return mounts, s.Err() -} - -// parseMount parses an entry in /proc/[pid]/mountstats in the format: -// device [device] mounted on [mount] with fstype [type] -func parseMount(ss []string) (*Mount, error) { - if len(ss) < deviceEntryLen { - return nil, fmt.Errorf("invalid device entry: %v", ss) - } - - // Check for specific words appearing at specific indices to ensure - // the format is consistent with what we expect - format := []struct { - i int - s string - }{ - {i: 0, s: "device"}, - {i: 2, s: "mounted"}, - {i: 3, s: "on"}, - {i: 5, s: "with"}, - {i: 6, s: "fstype"}, - } - - for _, f := range format { - if ss[f.i] != f.s { - return nil, fmt.Errorf("invalid device entry: %v", ss) - } - } - - return &Mount{ - Device: ss[1], - Mount: ss[4], - Type: ss[7], - }, nil -} - -// parseMountStatsNFS parses a MountStatsNFS by scanning additional information -// related to NFS statistics. -func parseMountStatsNFS(s *bufio.Scanner, statVersion string) (*MountStatsNFS, error) { - // Field indicators for parsing specific types of data - const ( - fieldAge = "age:" - fieldBytes = "bytes:" - fieldEvents = "events:" - fieldPerOpStats = "per-op" - fieldTransport = "xprt:" - ) - - stats := &MountStatsNFS{ - StatVersion: statVersion, - } - - for s.Scan() { - ss := strings.Fields(string(s.Bytes())) - if len(ss) == 0 { - break - } - if len(ss) < 2 { - return nil, fmt.Errorf("not enough information for NFS stats: %v", ss) - } - - switch ss[0] { - case fieldAge: - // Age integer is in seconds - d, err := time.ParseDuration(ss[1] + "s") - if err != nil { - return nil, err - } - - stats.Age = d - case fieldBytes: - bstats, err := parseNFSBytesStats(ss[1:]) - if err != nil { - return nil, err - } - - stats.Bytes = *bstats - case fieldEvents: - estats, err := parseNFSEventsStats(ss[1:]) - if err != nil { - return nil, err - } - - stats.Events = *estats - case fieldTransport: - if len(ss) < 3 { - return nil, fmt.Errorf("not enough information for NFS transport stats: %v", ss) - } - - tstats, err := parseNFSTransportStats(ss[2:], statVersion) - if err != nil { - return nil, err - } - - stats.Transport = *tstats - } - - // When encountering "per-operation statistics", we must break this - // loop and parse them separately to ensure we can terminate parsing - // before reaching another device entry; hence why this 'if' statement - // is not just another switch case - if ss[0] == fieldPerOpStats { - break - } - } - - if err := s.Err(); err != nil { - return nil, err - } - - // NFS per-operation stats appear last before the next device entry - perOpStats, err := parseNFSOperationStats(s) - if err != nil { - return nil, err - } - - stats.Operations = perOpStats - - return stats, nil -} - -// parseNFSBytesStats parses a NFSBytesStats line using an input set of -// integer fields. -func parseNFSBytesStats(ss []string) (*NFSBytesStats, error) { - if len(ss) != fieldBytesLen { - return nil, fmt.Errorf("invalid NFS bytes stats: %v", ss) - } - - ns := make([]uint64, 0, fieldBytesLen) - for _, s := range ss { - n, err := strconv.ParseUint(s, 10, 64) - if err != nil { - return nil, err - } - - ns = append(ns, n) - } - - return &NFSBytesStats{ - Read: ns[0], - Write: ns[1], - DirectRead: ns[2], - DirectWrite: ns[3], - ReadTotal: ns[4], - WriteTotal: ns[5], - ReadPages: ns[6], - WritePages: ns[7], - }, nil -} - -// parseNFSEventsStats parses a NFSEventsStats line using an input set of -// integer fields. -func parseNFSEventsStats(ss []string) (*NFSEventsStats, error) { - if len(ss) != fieldEventsLen { - return nil, fmt.Errorf("invalid NFS events stats: %v", ss) - } - - ns := make([]uint64, 0, fieldEventsLen) - for _, s := range ss { - n, err := strconv.ParseUint(s, 10, 64) - if err != nil { - return nil, err - } - - ns = append(ns, n) - } - - return &NFSEventsStats{ - InodeRevalidate: ns[0], - DnodeRevalidate: ns[1], - DataInvalidate: ns[2], - AttributeInvalidate: ns[3], - VFSOpen: ns[4], - VFSLookup: ns[5], - VFSAccess: ns[6], - VFSUpdatePage: ns[7], - VFSReadPage: ns[8], - VFSReadPages: ns[9], - VFSWritePage: ns[10], - VFSWritePages: ns[11], - VFSGetdents: ns[12], - VFSSetattr: ns[13], - VFSFlush: ns[14], - VFSFsync: ns[15], - VFSLock: ns[16], - VFSFileRelease: ns[17], - CongestionWait: ns[18], - Truncation: ns[19], - WriteExtension: ns[20], - SillyRename: ns[21], - ShortRead: ns[22], - ShortWrite: ns[23], - JukeboxDelay: ns[24], - PNFSRead: ns[25], - PNFSWrite: ns[26], - }, nil -} - -// parseNFSOperationStats parses a slice of NFSOperationStats by scanning -// additional information about per-operation statistics until an empty -// line is reached. -func parseNFSOperationStats(s *bufio.Scanner) ([]NFSOperationStats, error) { - const ( - // Number of expected fields in each per-operation statistics set - numFields = 9 - ) - - var ops []NFSOperationStats - - for s.Scan() { - ss := strings.Fields(string(s.Bytes())) - if len(ss) == 0 { - // Must break when reading a blank line after per-operation stats to - // enable top-level function to parse the next device entry - break - } - - if len(ss) != numFields { - return nil, fmt.Errorf("invalid NFS per-operations stats: %v", ss) - } - - // Skip string operation name for integers - ns := make([]uint64, 0, numFields-1) - for _, st := range ss[1:] { - n, err := strconv.ParseUint(st, 10, 64) - if err != nil { - return nil, err - } - - ns = append(ns, n) - } - - ops = append(ops, NFSOperationStats{ - Operation: strings.TrimSuffix(ss[0], ":"), - Requests: ns[0], - Transmissions: ns[1], - MajorTimeouts: ns[2], - BytesSent: ns[3], - BytesReceived: ns[4], - CumulativeQueueTime: time.Duration(ns[5]) * time.Millisecond, - CumulativeTotalResponseTime: time.Duration(ns[6]) * time.Millisecond, - CumulativeTotalRequestTime: time.Duration(ns[7]) * time.Millisecond, - }) - } - - return ops, s.Err() -} - -// parseNFSTransportStats parses a NFSTransportStats line using an input set of -// integer fields matched to a specific stats version. -func parseNFSTransportStats(ss []string, statVersion string) (*NFSTransportStats, error) { - switch statVersion { - case statVersion10: - if len(ss) != fieldTransport10Len { - return nil, fmt.Errorf("invalid NFS transport stats 1.0 statement: %v", ss) - } - case statVersion11: - if len(ss) != fieldTransport11Len { - return nil, fmt.Errorf("invalid NFS transport stats 1.1 statement: %v", ss) - } - default: - return nil, fmt.Errorf("unrecognized NFS transport stats version: %q", statVersion) - } - - // Allocate enough for v1.1 stats since zero value for v1.1 stats will be okay - // in a v1.0 response. - // - // Note: slice length must be set to length of v1.1 stats to avoid a panic when - // only v1.0 stats are present. - // See: https://github.com/prometheus/node_exporter/issues/571. - ns := make([]uint64, fieldTransport11Len) - for i, s := range ss { - n, err := strconv.ParseUint(s, 10, 64) - if err != nil { - return nil, err - } - - ns[i] = n - } - - return &NFSTransportStats{ - Port: ns[0], - Bind: ns[1], - Connect: ns[2], - ConnectIdleTime: ns[3], - IdleTime: time.Duration(ns[4]) * time.Second, - Sends: ns[5], - Receives: ns[6], - BadTransactionIDs: ns[7], - CumulativeActiveRequests: ns[8], - CumulativeBacklog: ns[9], - MaximumRPCSlotsUsed: ns[10], - CumulativeSendingQueue: ns[11], - CumulativePendingQueue: ns[12], - }, nil -} diff --git a/vendor/github.com/prometheus/procfs/xfs/parse.go b/vendor/github.com/prometheus/procfs/xfs/parse.go deleted file mode 100644 index c8f6279f39..0000000000 --- a/vendor/github.com/prometheus/procfs/xfs/parse.go +++ /dev/null @@ -1,359 +0,0 @@ -// Copyright 2017 The Prometheus Authors -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -package xfs - -import ( - "bufio" - "fmt" - "io" - "strconv" - "strings" -) - -// ParseStats parses a Stats from an input io.Reader, using the format -// found in /proc/fs/xfs/stat. -func ParseStats(r io.Reader) (*Stats, error) { - const ( - // Fields parsed into stats structures. - fieldExtentAlloc = "extent_alloc" - fieldAbt = "abt" - fieldBlkMap = "blk_map" - fieldBmbt = "bmbt" - fieldDir = "dir" - fieldTrans = "trans" - fieldIg = "ig" - fieldLog = "log" - fieldRw = "rw" - fieldAttr = "attr" - fieldIcluster = "icluster" - fieldVnodes = "vnodes" - fieldBuf = "buf" - fieldXpc = "xpc" - - // Unimplemented at this time due to lack of documentation. - fieldPushAil = "push_ail" - fieldXstrat = "xstrat" - fieldAbtb2 = "abtb2" - fieldAbtc2 = "abtc2" - fieldBmbt2 = "bmbt2" - fieldIbt2 = "ibt2" - fieldFibt2 = "fibt2" - fieldQm = "qm" - fieldDebug = "debug" - ) - - var xfss Stats - - s := bufio.NewScanner(r) - for s.Scan() { - // Expect at least a string label and a single integer value, ex: - // - abt 0 - // - rw 1 2 - ss := strings.Fields(string(s.Bytes())) - if len(ss) < 2 { - continue - } - label := ss[0] - - // Extended precision counters are uint64 values. - if label == fieldXpc { - us, err := parseUint64s(ss[1:]) - if err != nil { - return nil, err - } - - xfss.ExtendedPrecision, err = extendedPrecisionStats(us) - if err != nil { - return nil, err - } - - continue - } - - // All other counters are uint32 values. - us, err := parseUint32s(ss[1:]) - if err != nil { - return nil, err - } - - switch label { - case fieldExtentAlloc: - xfss.ExtentAllocation, err = extentAllocationStats(us) - case fieldAbt: - xfss.AllocationBTree, err = btreeStats(us) - case fieldBlkMap: - xfss.BlockMapping, err = blockMappingStats(us) - case fieldBmbt: - xfss.BlockMapBTree, err = btreeStats(us) - case fieldDir: - xfss.DirectoryOperation, err = directoryOperationStats(us) - case fieldTrans: - xfss.Transaction, err = transactionStats(us) - case fieldIg: - xfss.InodeOperation, err = inodeOperationStats(us) - case fieldLog: - xfss.LogOperation, err = logOperationStats(us) - case fieldRw: - xfss.ReadWrite, err = readWriteStats(us) - case fieldAttr: - xfss.AttributeOperation, err = attributeOperationStats(us) - case fieldIcluster: - xfss.InodeClustering, err = inodeClusteringStats(us) - case fieldVnodes: - xfss.Vnode, err = vnodeStats(us) - case fieldBuf: - xfss.Buffer, err = bufferStats(us) - } - if err != nil { - return nil, err - } - } - - return &xfss, s.Err() -} - -// extentAllocationStats builds an ExtentAllocationStats from a slice of uint32s. -func extentAllocationStats(us []uint32) (ExtentAllocationStats, error) { - if l := len(us); l != 4 { - return ExtentAllocationStats{}, fmt.Errorf("incorrect number of values for XFS extent allocation stats: %d", l) - } - - return ExtentAllocationStats{ - ExtentsAllocated: us[0], - BlocksAllocated: us[1], - ExtentsFreed: us[2], - BlocksFreed: us[3], - }, nil -} - -// btreeStats builds a BTreeStats from a slice of uint32s. -func btreeStats(us []uint32) (BTreeStats, error) { - if l := len(us); l != 4 { - return BTreeStats{}, fmt.Errorf("incorrect number of values for XFS btree stats: %d", l) - } - - return BTreeStats{ - Lookups: us[0], - Compares: us[1], - RecordsInserted: us[2], - RecordsDeleted: us[3], - }, nil -} - -// BlockMappingStat builds a BlockMappingStats from a slice of uint32s. -func blockMappingStats(us []uint32) (BlockMappingStats, error) { - if l := len(us); l != 7 { - return BlockMappingStats{}, fmt.Errorf("incorrect number of values for XFS block mapping stats: %d", l) - } - - return BlockMappingStats{ - Reads: us[0], - Writes: us[1], - Unmaps: us[2], - ExtentListInsertions: us[3], - ExtentListDeletions: us[4], - ExtentListLookups: us[5], - ExtentListCompares: us[6], - }, nil -} - -// DirectoryOperationStats builds a DirectoryOperationStats from a slice of uint32s. -func directoryOperationStats(us []uint32) (DirectoryOperationStats, error) { - if l := len(us); l != 4 { - return DirectoryOperationStats{}, fmt.Errorf("incorrect number of values for XFS directory operation stats: %d", l) - } - - return DirectoryOperationStats{ - Lookups: us[0], - Creates: us[1], - Removes: us[2], - Getdents: us[3], - }, nil -} - -// TransactionStats builds a TransactionStats from a slice of uint32s. -func transactionStats(us []uint32) (TransactionStats, error) { - if l := len(us); l != 3 { - return TransactionStats{}, fmt.Errorf("incorrect number of values for XFS transaction stats: %d", l) - } - - return TransactionStats{ - Sync: us[0], - Async: us[1], - Empty: us[2], - }, nil -} - -// InodeOperationStats builds an InodeOperationStats from a slice of uint32s. -func inodeOperationStats(us []uint32) (InodeOperationStats, error) { - if l := len(us); l != 7 { - return InodeOperationStats{}, fmt.Errorf("incorrect number of values for XFS inode operation stats: %d", l) - } - - return InodeOperationStats{ - Attempts: us[0], - Found: us[1], - Recycle: us[2], - Missed: us[3], - Duplicate: us[4], - Reclaims: us[5], - AttributeChange: us[6], - }, nil -} - -// LogOperationStats builds a LogOperationStats from a slice of uint32s. -func logOperationStats(us []uint32) (LogOperationStats, error) { - if l := len(us); l != 5 { - return LogOperationStats{}, fmt.Errorf("incorrect number of values for XFS log operation stats: %d", l) - } - - return LogOperationStats{ - Writes: us[0], - Blocks: us[1], - NoInternalBuffers: us[2], - Force: us[3], - ForceSleep: us[4], - }, nil -} - -// ReadWriteStats builds a ReadWriteStats from a slice of uint32s. -func readWriteStats(us []uint32) (ReadWriteStats, error) { - if l := len(us); l != 2 { - return ReadWriteStats{}, fmt.Errorf("incorrect number of values for XFS read write stats: %d", l) - } - - return ReadWriteStats{ - Read: us[0], - Write: us[1], - }, nil -} - -// AttributeOperationStats builds an AttributeOperationStats from a slice of uint32s. -func attributeOperationStats(us []uint32) (AttributeOperationStats, error) { - if l := len(us); l != 4 { - return AttributeOperationStats{}, fmt.Errorf("incorrect number of values for XFS attribute operation stats: %d", l) - } - - return AttributeOperationStats{ - Get: us[0], - Set: us[1], - Remove: us[2], - List: us[3], - }, nil -} - -// InodeClusteringStats builds an InodeClusteringStats from a slice of uint32s. -func inodeClusteringStats(us []uint32) (InodeClusteringStats, error) { - if l := len(us); l != 3 { - return InodeClusteringStats{}, fmt.Errorf("incorrect number of values for XFS inode clustering stats: %d", l) - } - - return InodeClusteringStats{ - Iflush: us[0], - Flush: us[1], - FlushInode: us[2], - }, nil -} - -// VnodeStats builds a VnodeStats from a slice of uint32s. -func vnodeStats(us []uint32) (VnodeStats, error) { - // The attribute "Free" appears to not be available on older XFS - // stats versions. Therefore, 7 or 8 elements may appear in - // this slice. - l := len(us) - if l != 7 && l != 8 { - return VnodeStats{}, fmt.Errorf("incorrect number of values for XFS vnode stats: %d", l) - } - - s := VnodeStats{ - Active: us[0], - Allocate: us[1], - Get: us[2], - Hold: us[3], - Release: us[4], - Reclaim: us[5], - Remove: us[6], - } - - // Skip adding free, unless it is present. The zero value will - // be used in place of an actual count. - if l == 7 { - return s, nil - } - - s.Free = us[7] - return s, nil -} - -// BufferStats builds a BufferStats from a slice of uint32s. -func bufferStats(us []uint32) (BufferStats, error) { - if l := len(us); l != 9 { - return BufferStats{}, fmt.Errorf("incorrect number of values for XFS buffer stats: %d", l) - } - - return BufferStats{ - Get: us[0], - Create: us[1], - GetLocked: us[2], - GetLockedWaited: us[3], - BusyLocked: us[4], - MissLocked: us[5], - PageRetries: us[6], - PageFound: us[7], - GetRead: us[8], - }, nil -} - -// ExtendedPrecisionStats builds an ExtendedPrecisionStats from a slice of uint32s. -func extendedPrecisionStats(us []uint64) (ExtendedPrecisionStats, error) { - if l := len(us); l != 3 { - return ExtendedPrecisionStats{}, fmt.Errorf("incorrect number of values for XFS extended precision stats: %d", l) - } - - return ExtendedPrecisionStats{ - FlushBytes: us[0], - WriteBytes: us[1], - ReadBytes: us[2], - }, nil -} - -// parseUint32s parses a slice of strings into a slice of uint32s. -func parseUint32s(ss []string) ([]uint32, error) { - us := make([]uint32, 0, len(ss)) - for _, s := range ss { - u, err := strconv.ParseUint(s, 10, 32) - if err != nil { - return nil, err - } - - us = append(us, uint32(u)) - } - - return us, nil -} - -// parseUint64s parses a slice of strings into a slice of uint64s. -func parseUint64s(ss []string) ([]uint64, error) { - us := make([]uint64, 0, len(ss)) - for _, s := range ss { - u, err := strconv.ParseUint(s, 10, 64) - if err != nil { - return nil, err - } - - us = append(us, u) - } - - return us, nil -} diff --git a/vendor/github.com/prometheus/procfs/xfs/xfs.go b/vendor/github.com/prometheus/procfs/xfs/xfs.go deleted file mode 100644 index d86794b7ca..0000000000 --- a/vendor/github.com/prometheus/procfs/xfs/xfs.go +++ /dev/null @@ -1,163 +0,0 @@ -// Copyright 2017 The Prometheus Authors -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package xfs provides access to statistics exposed by the XFS filesystem. -package xfs - -// Stats contains XFS filesystem runtime statistics, parsed from -// /proc/fs/xfs/stat. -// -// The names and meanings of each statistic were taken from -// http://xfs.org/index.php/Runtime_Stats and xfs_stats.h in the Linux -// kernel source. Most counters are uint32s (same data types used in -// xfs_stats.h), but some of the "extended precision stats" are uint64s. -type Stats struct { - // The name of the filesystem used to source these statistics. - // If empty, this indicates aggregated statistics for all XFS - // filesystems on the host. - Name string - - ExtentAllocation ExtentAllocationStats - AllocationBTree BTreeStats - BlockMapping BlockMappingStats - BlockMapBTree BTreeStats - DirectoryOperation DirectoryOperationStats - Transaction TransactionStats - InodeOperation InodeOperationStats - LogOperation LogOperationStats - ReadWrite ReadWriteStats - AttributeOperation AttributeOperationStats - InodeClustering InodeClusteringStats - Vnode VnodeStats - Buffer BufferStats - ExtendedPrecision ExtendedPrecisionStats -} - -// ExtentAllocationStats contains statistics regarding XFS extent allocations. -type ExtentAllocationStats struct { - ExtentsAllocated uint32 - BlocksAllocated uint32 - ExtentsFreed uint32 - BlocksFreed uint32 -} - -// BTreeStats contains statistics regarding an XFS internal B-tree. -type BTreeStats struct { - Lookups uint32 - Compares uint32 - RecordsInserted uint32 - RecordsDeleted uint32 -} - -// BlockMappingStats contains statistics regarding XFS block maps. -type BlockMappingStats struct { - Reads uint32 - Writes uint32 - Unmaps uint32 - ExtentListInsertions uint32 - ExtentListDeletions uint32 - ExtentListLookups uint32 - ExtentListCompares uint32 -} - -// DirectoryOperationStats contains statistics regarding XFS directory entries. -type DirectoryOperationStats struct { - Lookups uint32 - Creates uint32 - Removes uint32 - Getdents uint32 -} - -// TransactionStats contains statistics regarding XFS metadata transactions. -type TransactionStats struct { - Sync uint32 - Async uint32 - Empty uint32 -} - -// InodeOperationStats contains statistics regarding XFS inode operations. -type InodeOperationStats struct { - Attempts uint32 - Found uint32 - Recycle uint32 - Missed uint32 - Duplicate uint32 - Reclaims uint32 - AttributeChange uint32 -} - -// LogOperationStats contains statistics regarding the XFS log buffer. -type LogOperationStats struct { - Writes uint32 - Blocks uint32 - NoInternalBuffers uint32 - Force uint32 - ForceSleep uint32 -} - -// ReadWriteStats contains statistics regarding the number of read and write -// system calls for XFS filesystems. -type ReadWriteStats struct { - Read uint32 - Write uint32 -} - -// AttributeOperationStats contains statistics regarding manipulation of -// XFS extended file attributes. -type AttributeOperationStats struct { - Get uint32 - Set uint32 - Remove uint32 - List uint32 -} - -// InodeClusteringStats contains statistics regarding XFS inode clustering -// operations. -type InodeClusteringStats struct { - Iflush uint32 - Flush uint32 - FlushInode uint32 -} - -// VnodeStats contains statistics regarding XFS vnode operations. -type VnodeStats struct { - Active uint32 - Allocate uint32 - Get uint32 - Hold uint32 - Release uint32 - Reclaim uint32 - Remove uint32 - Free uint32 -} - -// BufferStats contains statistics regarding XFS read/write I/O buffers. -type BufferStats struct { - Get uint32 - Create uint32 - GetLocked uint32 - GetLockedWaited uint32 - BusyLocked uint32 - MissLocked uint32 - PageRetries uint32 - PageFound uint32 - GetRead uint32 -} - -// ExtendedPrecisionStats contains high precision counters used to track the -// total number of bytes read, written, or flushed, during XFS operations. -type ExtendedPrecisionStats struct { - FlushBytes uint64 - WriteBytes uint64 - ReadBytes uint64 -} diff --git a/vendor/github.com/robfig/cron/.gitignore b/vendor/github.com/robfig/cron/.gitignore new file mode 100644 index 0000000000..00268614f0 --- /dev/null +++ b/vendor/github.com/robfig/cron/.gitignore @@ -0,0 +1,22 @@ +# Compiled Object files, Static and Dynamic libs (Shared Objects) +*.o +*.a +*.so + +# Folders +_obj +_test + +# Architecture specific extensions/prefixes +*.[568vq] +[568vq].out + +*.cgo1.go +*.cgo2.c +_cgo_defun.c +_cgo_gotypes.go +_cgo_export.* + +_testmain.go + +*.exe diff --git a/vendor/github.com/robfig/cron/.travis.yml b/vendor/github.com/robfig/cron/.travis.yml new file mode 100644 index 0000000000..4f2ee4d973 --- /dev/null +++ b/vendor/github.com/robfig/cron/.travis.yml @@ -0,0 +1 @@ +language: go diff --git a/vendor/github.com/robfig/cron/constantdelay_test.go b/vendor/github.com/robfig/cron/constantdelay_test.go deleted file mode 100644 index f43a58ad26..0000000000 --- a/vendor/github.com/robfig/cron/constantdelay_test.go +++ /dev/null @@ -1,54 +0,0 @@ -package cron - -import ( - "testing" - "time" -) - -func TestConstantDelayNext(t *testing.T) { - tests := []struct { - time string - delay time.Duration - expected string - }{ - // Simple cases - {"Mon Jul 9 14:45 2012", 15*time.Minute + 50*time.Nanosecond, "Mon Jul 9 15:00 2012"}, - {"Mon Jul 9 14:59 2012", 15 * time.Minute, "Mon Jul 9 15:14 2012"}, - {"Mon Jul 9 14:59:59 2012", 15 * time.Minute, "Mon Jul 9 15:14:59 2012"}, - - // Wrap around hours - {"Mon Jul 9 15:45 2012", 35 * time.Minute, "Mon Jul 9 16:20 2012"}, - - // Wrap around days - {"Mon Jul 9 23:46 2012", 14 * time.Minute, "Tue Jul 10 00:00 2012"}, - {"Mon Jul 9 23:45 2012", 35 * time.Minute, "Tue Jul 10 00:20 2012"}, - {"Mon Jul 9 23:35:51 2012", 44*time.Minute + 24*time.Second, "Tue Jul 10 00:20:15 2012"}, - {"Mon Jul 9 23:35:51 2012", 25*time.Hour + 44*time.Minute + 24*time.Second, "Thu Jul 11 01:20:15 2012"}, - - // Wrap around months - {"Mon Jul 9 23:35 2012", 91*24*time.Hour + 25*time.Minute, "Thu Oct 9 00:00 2012"}, - - // Wrap around minute, hour, day, month, and year - {"Mon Dec 31 23:59:45 2012", 15 * time.Second, "Tue Jan 1 00:00:00 2013"}, - - // Round to nearest second on the delay - {"Mon Jul 9 14:45 2012", 15*time.Minute + 50*time.Nanosecond, "Mon Jul 9 15:00 2012"}, - - // Round up to 1 second if the duration is less. - {"Mon Jul 9 14:45:00 2012", 15 * time.Millisecond, "Mon Jul 9 14:45:01 2012"}, - - // Round to nearest second when calculating the next time. - {"Mon Jul 9 14:45:00.005 2012", 15 * time.Minute, "Mon Jul 9 15:00 2012"}, - - // Round to nearest second for both. - {"Mon Jul 9 14:45:00.005 2012", 15*time.Minute + 50*time.Nanosecond, "Mon Jul 9 15:00 2012"}, - } - - for _, c := range tests { - actual := Every(c.delay).Next(getTime(c.time)) - expected := getTime(c.expected) - if actual != expected { - t.Errorf("%s, \"%s\": (expected) %v != %v (actual)", c.time, c.delay, expected, actual) - } - } -} diff --git a/vendor/github.com/robfig/cron/cron_test.go b/vendor/github.com/robfig/cron/cron_test.go deleted file mode 100644 index 7abece4a70..0000000000 --- a/vendor/github.com/robfig/cron/cron_test.go +++ /dev/null @@ -1,355 +0,0 @@ -package cron - -import ( - "fmt" - "sync" - "testing" - "time" -) - -// Many tests schedule a job for every second, and then wait at most a second -// for it to run. This amount is just slightly larger than 1 second to -// compensate for a few milliseconds of runtime. -const OneSecond = 1*time.Second + 10*time.Millisecond - -func TestFuncPanicRecovery(t *testing.T) { - cron := New() - cron.Start() - defer cron.Stop() - cron.AddFunc("* * * * * ?", func() { panic("YOLO") }) - - select { - case <-time.After(OneSecond): - return - } -} - -type DummyJob struct{} - -func (d DummyJob) Run() { - panic("YOLO") -} - -func TestJobPanicRecovery(t *testing.T) { - var job DummyJob - - cron := New() - cron.Start() - defer cron.Stop() - cron.AddJob("* * * * * ?", job) - - select { - case <-time.After(OneSecond): - return - } -} - -// Start and stop cron with no entries. -func TestNoEntries(t *testing.T) { - cron := New() - cron.Start() - - select { - case <-time.After(OneSecond): - t.Fatal("expected cron will be stopped immediately") - case <-stop(cron): - } -} - -// Start, stop, then add an entry. Verify entry doesn't run. -func TestStopCausesJobsToNotRun(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(1) - - cron := New() - cron.Start() - cron.Stop() - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - - select { - case <-time.After(OneSecond): - // No job ran! - case <-wait(wg): - t.Fatal("expected stopped cron does not run any job") - } -} - -// Add a job, start cron, expect it runs. -func TestAddBeforeRunning(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(1) - - cron := New() - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - cron.Start() - defer cron.Stop() - - // Give cron 2 seconds to run our job (which is always activated). - select { - case <-time.After(OneSecond): - t.Fatal("expected job runs") - case <-wait(wg): - } -} - -// Start cron, add a job, expect it runs. -func TestAddWhileRunning(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(1) - - cron := New() - cron.Start() - defer cron.Stop() - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - - select { - case <-time.After(OneSecond): - t.Fatal("expected job runs") - case <-wait(wg): - } -} - -// Test for #34. Adding a job after calling start results in multiple job invocations -func TestAddWhileRunningWithDelay(t *testing.T) { - cron := New() - cron.Start() - defer cron.Stop() - time.Sleep(5 * time.Second) - var calls = 0 - cron.AddFunc("* * * * * *", func() { calls += 1 }) - - <-time.After(OneSecond) - if calls != 1 { - t.Errorf("called %d times, expected 1\n", calls) - } -} - -// Test timing with Entries. -func TestSnapshotEntries(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(1) - - cron := New() - cron.AddFunc("@every 2s", func() { wg.Done() }) - cron.Start() - defer cron.Stop() - - // Cron should fire in 2 seconds. After 1 second, call Entries. - select { - case <-time.After(OneSecond): - cron.Entries() - } - - // Even though Entries was called, the cron should fire at the 2 second mark. - select { - case <-time.After(OneSecond): - t.Error("expected job runs at 2 second mark") - case <-wait(wg): - } - -} - -// Test that the entries are correctly sorted. -// Add a bunch of long-in-the-future entries, and an immediate entry, and ensure -// that the immediate entry runs immediately. -// Also: Test that multiple jobs run in the same instant. -func TestMultipleEntries(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(2) - - cron := New() - cron.AddFunc("0 0 0 1 1 ?", func() {}) - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - cron.AddFunc("0 0 0 31 12 ?", func() {}) - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - - cron.Start() - defer cron.Stop() - - select { - case <-time.After(OneSecond): - t.Error("expected job run in proper order") - case <-wait(wg): - } -} - -// Test running the same job twice. -func TestRunningJobTwice(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(2) - - cron := New() - cron.AddFunc("0 0 0 1 1 ?", func() {}) - cron.AddFunc("0 0 0 31 12 ?", func() {}) - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - - cron.Start() - defer cron.Stop() - - select { - case <-time.After(2 * OneSecond): - t.Error("expected job fires 2 times") - case <-wait(wg): - } -} - -func TestRunningMultipleSchedules(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(2) - - cron := New() - cron.AddFunc("0 0 0 1 1 ?", func() {}) - cron.AddFunc("0 0 0 31 12 ?", func() {}) - cron.AddFunc("* * * * * ?", func() { wg.Done() }) - cron.Schedule(Every(time.Minute), FuncJob(func() {})) - cron.Schedule(Every(time.Second), FuncJob(func() { wg.Done() })) - cron.Schedule(Every(time.Hour), FuncJob(func() {})) - - cron.Start() - defer cron.Stop() - - select { - case <-time.After(2 * OneSecond): - t.Error("expected job fires 2 times") - case <-wait(wg): - } -} - -// Test that the cron is run in the local time zone (as opposed to UTC). -func TestLocalTimezone(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(2) - - now := time.Now() - spec := fmt.Sprintf("%d,%d %d %d %d %d ?", - now.Second()+1, now.Second()+2, now.Minute(), now.Hour(), now.Day(), now.Month()) - - cron := New() - cron.AddFunc(spec, func() { wg.Done() }) - cron.Start() - defer cron.Stop() - - select { - case <-time.After(OneSecond * 2): - t.Error("expected job fires 2 times") - case <-wait(wg): - } -} - -// Test that the cron is run in the given time zone (as opposed to local). -func TestNonLocalTimezone(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(2) - - loc, err := time.LoadLocation("Atlantic/Cape_Verde") - if err != nil { - fmt.Printf("Failed to load time zone Atlantic/Cape_Verde: %+v", err) - t.Fail() - } - - now := time.Now().In(loc) - spec := fmt.Sprintf("%d,%d %d %d %d %d ?", - now.Second()+1, now.Second()+2, now.Minute(), now.Hour(), now.Day(), now.Month()) - - cron := NewWithLocation(loc) - cron.AddFunc(spec, func() { wg.Done() }) - cron.Start() - defer cron.Stop() - - select { - case <-time.After(OneSecond * 2): - t.Error("expected job fires 2 times") - case <-wait(wg): - } -} - -// Test that calling stop before start silently returns without -// blocking the stop channel. -func TestStopWithoutStart(t *testing.T) { - cron := New() - cron.Stop() -} - -type testJob struct { - wg *sync.WaitGroup - name string -} - -func (t testJob) Run() { - t.wg.Done() -} - -// Simple test using Runnables. -func TestJob(t *testing.T) { - wg := &sync.WaitGroup{} - wg.Add(1) - - cron := New() - cron.AddJob("0 0 0 30 Feb ?", testJob{wg, "job0"}) - cron.AddJob("0 0 0 1 1 ?", testJob{wg, "job1"}) - cron.AddJob("* * * * * ?", testJob{wg, "job2"}) - cron.AddJob("1 0 0 1 1 ?", testJob{wg, "job3"}) - cron.Schedule(Every(5*time.Second+5*time.Nanosecond), testJob{wg, "job4"}) - cron.Schedule(Every(5*time.Minute), testJob{wg, "job5"}) - - cron.Start() - defer cron.Stop() - - select { - case <-time.After(OneSecond): - t.FailNow() - case <-wait(wg): - } - - // Ensure the entries are in the right order. - expecteds := []string{"job2", "job4", "job5", "job1", "job3", "job0"} - - var actuals []string - for _, entry := range cron.Entries() { - actuals = append(actuals, entry.Job.(testJob).name) - } - - for i, expected := range expecteds { - if actuals[i] != expected { - t.Fatalf("Jobs not in the right order. (expected) %s != %s (actual)", expecteds, actuals) - } - } -} - -type ZeroSchedule struct{} - -func (*ZeroSchedule) Next(time.Time) time.Time { - return time.Time{} -} - -// Tests that job without time does not run -func TestJobWithZeroTimeDoesNotRun(t *testing.T) { - cron := New() - calls := 0 - cron.AddFunc("* * * * * *", func() { calls += 1 }) - cron.Schedule(new(ZeroSchedule), FuncJob(func() { t.Error("expected zero task will not run") })) - cron.Start() - defer cron.Stop() - <-time.After(OneSecond) - if calls != 1 { - t.Errorf("called %d times, expected 1\n", calls) - } -} - -func wait(wg *sync.WaitGroup) chan bool { - ch := make(chan bool) - go func() { - wg.Wait() - ch <- true - }() - return ch -} - -func stop(cron *Cron) chan bool { - ch := make(chan bool) - go func() { - cron.Stop() - ch <- true - }() - return ch -} diff --git a/vendor/github.com/robfig/cron/parser_test.go b/vendor/github.com/robfig/cron/parser_test.go deleted file mode 100644 index fa70e9b2b9..0000000000 --- a/vendor/github.com/robfig/cron/parser_test.go +++ /dev/null @@ -1,234 +0,0 @@ -package cron - -import ( - "reflect" - "strings" - "testing" - "time" -) - -func TestRange(t *testing.T) { - zero := uint64(0) - ranges := []struct { - expr string - min, max uint - expected uint64 - err string - }{ - {"5", 0, 7, 1 << 5, ""}, - {"0", 0, 7, 1 << 0, ""}, - {"7", 0, 7, 1 << 7, ""}, - - {"5-5", 0, 7, 1 << 5, ""}, - {"5-6", 0, 7, 1<<5 | 1<<6, ""}, - {"5-7", 0, 7, 1<<5 | 1<<6 | 1<<7, ""}, - - {"5-6/2", 0, 7, 1 << 5, ""}, - {"5-7/2", 0, 7, 1<<5 | 1<<7, ""}, - {"5-7/1", 0, 7, 1<<5 | 1<<6 | 1<<7, ""}, - - {"*", 1, 3, 1<<1 | 1<<2 | 1<<3 | starBit, ""}, - {"*/2", 1, 3, 1<<1 | 1<<3 | starBit, ""}, - - {"5--5", 0, 0, zero, "Too many hyphens"}, - {"jan-x", 0, 0, zero, "Failed to parse int from"}, - {"2-x", 1, 5, zero, "Failed to parse int from"}, - {"*/-12", 0, 0, zero, "Negative number"}, - {"*//2", 0, 0, zero, "Too many slashes"}, - {"1", 3, 5, zero, "below minimum"}, - {"6", 3, 5, zero, "above maximum"}, - {"5-3", 3, 5, zero, "beyond end of range"}, - {"*/0", 0, 0, zero, "should be a positive number"}, - } - - for _, c := range ranges { - actual, err := getRange(c.expr, bounds{c.min, c.max, nil}) - if len(c.err) != 0 && (err == nil || !strings.Contains(err.Error(), c.err)) { - t.Errorf("%s => expected %v, got %v", c.expr, c.err, err) - } - if len(c.err) == 0 && err != nil { - t.Errorf("%s => unexpected error %v", c.expr, err) - } - if actual != c.expected { - t.Errorf("%s => expected %d, got %d", c.expr, c.expected, actual) - } - } -} - -func TestField(t *testing.T) { - fields := []struct { - expr string - min, max uint - expected uint64 - }{ - {"5", 1, 7, 1 << 5}, - {"5,6", 1, 7, 1<<5 | 1<<6}, - {"5,6,7", 1, 7, 1<<5 | 1<<6 | 1<<7}, - {"1,5-7/2,3", 1, 7, 1<<1 | 1<<5 | 1<<7 | 1<<3}, - } - - for _, c := range fields { - actual, _ := getField(c.expr, bounds{c.min, c.max, nil}) - if actual != c.expected { - t.Errorf("%s => expected %d, got %d", c.expr, c.expected, actual) - } - } -} - -func TestAll(t *testing.T) { - allBits := []struct { - r bounds - expected uint64 - }{ - {minutes, 0xfffffffffffffff}, // 0-59: 60 ones - {hours, 0xffffff}, // 0-23: 24 ones - {dom, 0xfffffffe}, // 1-31: 31 ones, 1 zero - {months, 0x1ffe}, // 1-12: 12 ones, 1 zero - {dow, 0x7f}, // 0-6: 7 ones - } - - for _, c := range allBits { - actual := all(c.r) // all() adds the starBit, so compensate for that.. - if c.expected|starBit != actual { - t.Errorf("%d-%d/%d => expected %b, got %b", - c.r.min, c.r.max, 1, c.expected|starBit, actual) - } - } -} - -func TestBits(t *testing.T) { - bits := []struct { - min, max, step uint - expected uint64 - }{ - {0, 0, 1, 0x1}, - {1, 1, 1, 0x2}, - {1, 5, 2, 0x2a}, // 101010 - {1, 4, 2, 0xa}, // 1010 - } - - for _, c := range bits { - actual := getBits(c.min, c.max, c.step) - if c.expected != actual { - t.Errorf("%d-%d/%d => expected %b, got %b", - c.min, c.max, c.step, c.expected, actual) - } - } -} - -func TestParse(t *testing.T) { - entries := []struct { - expr string - expected Schedule - err string - }{ - { - expr: "* 5 * * * *", - expected: &SpecSchedule{ - Second: all(seconds), - Minute: 1 << 5, - Hour: all(hours), - Dom: all(dom), - Month: all(months), - Dow: all(dow), - }, - }, - { - expr: "* 5 j * * *", - err: "Failed to parse int from", - }, - { - expr: "@every 5m", - expected: ConstantDelaySchedule{Delay: time.Duration(5) * time.Minute}, - }, - { - expr: "@every Xm", - err: "Failed to parse duration", - }, - { - expr: "@yearly", - expected: &SpecSchedule{ - Second: 1 << seconds.min, - Minute: 1 << minutes.min, - Hour: 1 << hours.min, - Dom: 1 << dom.min, - Month: 1 << months.min, - Dow: all(dow), - }, - }, - { - expr: "@annually", - expected: &SpecSchedule{ - Second: 1 << seconds.min, - Minute: 1 << minutes.min, - Hour: 1 << hours.min, - Dom: 1 << dom.min, - Month: 1 << months.min, - Dow: all(dow), - }, - }, - { - expr: "@unrecognized", - err: "Unrecognized descriptor", - }, - { - expr: "* * * *", - err: "Expected 5 to 6 fields", - }, - { - expr: "", - err: "Empty spec string", - }, - } - - for _, c := range entries { - actual, err := Parse(c.expr) - if len(c.err) != 0 && (err == nil || !strings.Contains(err.Error(), c.err)) { - t.Errorf("%s => expected %v, got %v", c.expr, c.err, err) - } - if len(c.err) == 0 && err != nil { - t.Errorf("%s => unexpected error %v", c.expr, err) - } - if !reflect.DeepEqual(actual, c.expected) { - t.Errorf("%s => expected %b, got %b", c.expr, c.expected, actual) - } - } -} - -func TestStandardSpecSchedule(t *testing.T) { - entries := []struct { - expr string - expected Schedule - err string - }{ - { - expr: "5 * * * *", - expected: &SpecSchedule{1 << seconds.min, 1 << 5, all(hours), all(dom), all(months), all(dow)}, - }, - { - expr: "@every 5m", - expected: ConstantDelaySchedule{time.Duration(5) * time.Minute}, - }, - { - expr: "5 j * * *", - err: "Failed to parse int from", - }, - { - expr: "* * * *", - err: "Expected exactly 5 fields", - }, - } - - for _, c := range entries { - actual, err := ParseStandard(c.expr) - if len(c.err) != 0 && (err == nil || !strings.Contains(err.Error(), c.err)) { - t.Errorf("%s => expected %v, got %v", c.expr, c.err, err) - } - if len(c.err) == 0 && err != nil { - t.Errorf("%s => unexpected error %v", c.expr, err) - } - if !reflect.DeepEqual(actual, c.expected) { - t.Errorf("%s => expected %b, got %b", c.expr, c.expected, actual) - } - } -} diff --git a/vendor/github.com/robfig/cron/spec_test.go b/vendor/github.com/robfig/cron/spec_test.go deleted file mode 100644 index a1be616762..0000000000 --- a/vendor/github.com/robfig/cron/spec_test.go +++ /dev/null @@ -1,249 +0,0 @@ -package cron - -import ( - "testing" - "time" -) - -func TestActivation(t *testing.T) { - tests := []struct { - time, spec string - expected bool - }{ - // Every fifteen minutes. - {"Mon Jul 9 15:00 2012", "0 0/15 * * *", true}, - {"Mon Jul 9 15:45 2012", "0 0/15 * * *", true}, - {"Mon Jul 9 15:40 2012", "0 0/15 * * *", false}, - - // Every fifteen minutes, starting at 5 minutes. - {"Mon Jul 9 15:05 2012", "0 5/15 * * *", true}, - {"Mon Jul 9 15:20 2012", "0 5/15 * * *", true}, - {"Mon Jul 9 15:50 2012", "0 5/15 * * *", true}, - - // Named months - {"Sun Jul 15 15:00 2012", "0 0/15 * * Jul", true}, - {"Sun Jul 15 15:00 2012", "0 0/15 * * Jun", false}, - - // Everything set. - {"Sun Jul 15 08:30 2012", "0 30 08 ? Jul Sun", true}, - {"Sun Jul 15 08:30 2012", "0 30 08 15 Jul ?", true}, - {"Mon Jul 16 08:30 2012", "0 30 08 ? Jul Sun", false}, - {"Mon Jul 16 08:30 2012", "0 30 08 15 Jul ?", false}, - - // Predefined schedules - {"Mon Jul 9 15:00 2012", "@hourly", true}, - {"Mon Jul 9 15:04 2012", "@hourly", false}, - {"Mon Jul 9 15:00 2012", "@daily", false}, - {"Mon Jul 9 00:00 2012", "@daily", true}, - {"Mon Jul 9 00:00 2012", "@weekly", false}, - {"Sun Jul 8 00:00 2012", "@weekly", true}, - {"Sun Jul 8 01:00 2012", "@weekly", false}, - {"Sun Jul 8 00:00 2012", "@monthly", false}, - {"Sun Jul 1 00:00 2012", "@monthly", true}, - - // Test interaction of DOW and DOM. - // If both are specified, then only one needs to match. - {"Sun Jul 15 00:00 2012", "0 * * 1,15 * Sun", true}, - {"Fri Jun 15 00:00 2012", "0 * * 1,15 * Sun", true}, - {"Wed Aug 1 00:00 2012", "0 * * 1,15 * Sun", true}, - - // However, if one has a star, then both need to match. - {"Sun Jul 15 00:00 2012", "0 * * * * Mon", false}, - {"Sun Jul 15 00:00 2012", "0 * * */10 * Sun", false}, - {"Mon Jul 9 00:00 2012", "0 * * 1,15 * *", false}, - {"Sun Jul 15 00:00 2012", "0 * * 1,15 * *", true}, - {"Sun Jul 15 00:00 2012", "0 * * */2 * Sun", true}, - } - - for _, test := range tests { - sched, err := Parse(test.spec) - if err != nil { - t.Error(err) - continue - } - actual := sched.Next(getTime(test.time).Add(-1 * time.Second)) - expected := getTime(test.time) - if test.expected && expected != actual || !test.expected && expected == actual { - t.Errorf("Fail evaluating %s on %s: (expected) %s != %s (actual)", - test.spec, test.time, expected, actual) - } - } -} - -func TestNext(t *testing.T) { - runs := []struct { - time, spec string - expected string - }{ - // Simple cases - {"Mon Jul 9 14:45 2012", "0 0/15 * * *", "Mon Jul 9 15:00 2012"}, - {"Mon Jul 9 14:59 2012", "0 0/15 * * *", "Mon Jul 9 15:00 2012"}, - {"Mon Jul 9 14:59:59 2012", "0 0/15 * * *", "Mon Jul 9 15:00 2012"}, - - // Wrap around hours - {"Mon Jul 9 15:45 2012", "0 20-35/15 * * *", "Mon Jul 9 16:20 2012"}, - - // Wrap around days - {"Mon Jul 9 23:46 2012", "0 */15 * * *", "Tue Jul 10 00:00 2012"}, - {"Mon Jul 9 23:45 2012", "0 20-35/15 * * *", "Tue Jul 10 00:20 2012"}, - {"Mon Jul 9 23:35:51 2012", "15/35 20-35/15 * * *", "Tue Jul 10 00:20:15 2012"}, - {"Mon Jul 9 23:35:51 2012", "15/35 20-35/15 1/2 * *", "Tue Jul 10 01:20:15 2012"}, - {"Mon Jul 9 23:35:51 2012", "15/35 20-35/15 10-12 * *", "Tue Jul 10 10:20:15 2012"}, - - {"Mon Jul 9 23:35:51 2012", "15/35 20-35/15 1/2 */2 * *", "Thu Jul 11 01:20:15 2012"}, - {"Mon Jul 9 23:35:51 2012", "15/35 20-35/15 * 9-20 * *", "Wed Jul 10 00:20:15 2012"}, - {"Mon Jul 9 23:35:51 2012", "15/35 20-35/15 * 9-20 Jul *", "Wed Jul 10 00:20:15 2012"}, - - // Wrap around months - {"Mon Jul 9 23:35 2012", "0 0 0 9 Apr-Oct ?", "Thu Aug 9 00:00 2012"}, - {"Mon Jul 9 23:35 2012", "0 0 0 */5 Apr,Aug,Oct Mon", "Mon Aug 6 00:00 2012"}, - {"Mon Jul 9 23:35 2012", "0 0 0 */5 Oct Mon", "Mon Oct 1 00:00 2012"}, - - // Wrap around years - {"Mon Jul 9 23:35 2012", "0 0 0 * Feb Mon", "Mon Feb 4 00:00 2013"}, - {"Mon Jul 9 23:35 2012", "0 0 0 * Feb Mon/2", "Fri Feb 1 00:00 2013"}, - - // Wrap around minute, hour, day, month, and year - {"Mon Dec 31 23:59:45 2012", "0 * * * * *", "Tue Jan 1 00:00:00 2013"}, - - // Leap year - {"Mon Jul 9 23:35 2012", "0 0 0 29 Feb ?", "Mon Feb 29 00:00 2016"}, - - // Daylight savings time 2am EST (-5) -> 3am EDT (-4) - {"2012-03-11T00:00:00-0500", "0 30 2 11 Mar ?", "2013-03-11T02:30:00-0400"}, - - // hourly job - {"2012-03-11T00:00:00-0500", "0 0 * * * ?", "2012-03-11T01:00:00-0500"}, - {"2012-03-11T01:00:00-0500", "0 0 * * * ?", "2012-03-11T03:00:00-0400"}, - {"2012-03-11T03:00:00-0400", "0 0 * * * ?", "2012-03-11T04:00:00-0400"}, - {"2012-03-11T04:00:00-0400", "0 0 * * * ?", "2012-03-11T05:00:00-0400"}, - - // 1am nightly job - {"2012-03-11T00:00:00-0500", "0 0 1 * * ?", "2012-03-11T01:00:00-0500"}, - {"2012-03-11T01:00:00-0500", "0 0 1 * * ?", "2012-03-12T01:00:00-0400"}, - - // 2am nightly job (skipped) - {"2012-03-11T00:00:00-0500", "0 0 2 * * ?", "2012-03-12T02:00:00-0400"}, - - // Daylight savings time 2am EDT (-4) => 1am EST (-5) - {"2012-11-04T00:00:00-0400", "0 30 2 04 Nov ?", "2012-11-04T02:30:00-0500"}, - {"2012-11-04T01:45:00-0400", "0 30 1 04 Nov ?", "2012-11-04T01:30:00-0500"}, - - // hourly job - {"2012-11-04T00:00:00-0400", "0 0 * * * ?", "2012-11-04T01:00:00-0400"}, - {"2012-11-04T01:00:00-0400", "0 0 * * * ?", "2012-11-04T01:00:00-0500"}, - {"2012-11-04T01:00:00-0500", "0 0 * * * ?", "2012-11-04T02:00:00-0500"}, - - // 1am nightly job (runs twice) - {"2012-11-04T00:00:00-0400", "0 0 1 * * ?", "2012-11-04T01:00:00-0400"}, - {"2012-11-04T01:00:00-0400", "0 0 1 * * ?", "2012-11-04T01:00:00-0500"}, - {"2012-11-04T01:00:00-0500", "0 0 1 * * ?", "2012-11-05T01:00:00-0500"}, - - // 2am nightly job - {"2012-11-04T00:00:00-0400", "0 0 2 * * ?", "2012-11-04T02:00:00-0500"}, - {"2012-11-04T02:00:00-0500", "0 0 2 * * ?", "2012-11-05T02:00:00-0500"}, - - // 3am nightly job - {"2012-11-04T00:00:00-0400", "0 0 3 * * ?", "2012-11-04T03:00:00-0500"}, - {"2012-11-04T03:00:00-0500", "0 0 3 * * ?", "2012-11-05T03:00:00-0500"}, - - // Unsatisfiable - {"Mon Jul 9 23:35 2012", "0 0 0 30 Feb ?", ""}, - {"Mon Jul 9 23:35 2012", "0 0 0 31 Apr ?", ""}, - } - - for _, c := range runs { - sched, err := Parse(c.spec) - if err != nil { - t.Error(err) - continue - } - actual := sched.Next(getTime(c.time)) - expected := getTime(c.expected) - if !actual.Equal(expected) { - t.Errorf("%s, \"%s\": (expected) %v != %v (actual)", c.time, c.spec, expected, actual) - } - } -} - -func TestErrors(t *testing.T) { - invalidSpecs := []string{ - "xyz", - "60 0 * * *", - "0 60 * * *", - "0 0 * * XYZ", - } - for _, spec := range invalidSpecs { - _, err := Parse(spec) - if err == nil { - t.Error("expected an error parsing: ", spec) - } - } -} - -func getTime(value string) time.Time { - if value == "" { - return time.Time{} - } - t, err := time.Parse("Mon Jan 2 15:04 2006", value) - if err != nil { - t, err = time.Parse("Mon Jan 2 15:04:05 2006", value) - if err != nil { - t, err = time.Parse("2006-01-02T15:04:05-0700", value) - if err != nil { - panic(err) - } - // Daylight savings time tests require location - if ny, err := time.LoadLocation("America/New_York"); err == nil { - t = t.In(ny) - } - } - } - - return t -} - -func TestNextWithTz(t *testing.T) { - runs := []struct { - time, spec string - expected string - }{ - // Failing tests - {"2016-01-03T13:09:03+0530", "0 14 14 * * *", "2016-01-03T14:14:00+0530"}, - {"2016-01-03T04:09:03+0530", "0 14 14 * * ?", "2016-01-03T14:14:00+0530"}, - - // Passing tests - {"2016-01-03T14:09:03+0530", "0 14 14 * * *", "2016-01-03T14:14:00+0530"}, - {"2016-01-03T14:00:00+0530", "0 14 14 * * ?", "2016-01-03T14:14:00+0530"}, - } - for _, c := range runs { - sched, err := Parse(c.spec) - if err != nil { - t.Error(err) - continue - } - actual := sched.Next(getTimeTZ(c.time)) - expected := getTimeTZ(c.expected) - if !actual.Equal(expected) { - t.Errorf("%s, \"%s\": (expected) %v != %v (actual)", c.time, c.spec, expected, actual) - } - } -} - -func getTimeTZ(value string) time.Time { - if value == "" { - return time.Time{} - } - t, err := time.Parse("Mon Jan 2 15:04 2006", value) - if err != nil { - t, err = time.Parse("Mon Jan 2 15:04:05 2006", value) - if err != nil { - t, err = time.Parse("2006-01-02T15:04:05-0700", value) - if err != nil { - panic(err) - } - } - } - - return t -} diff --git a/vendor/github.com/spf13/pflag/.gitignore b/vendor/github.com/spf13/pflag/.gitignore new file mode 100644 index 0000000000..c3da290134 --- /dev/null +++ b/vendor/github.com/spf13/pflag/.gitignore @@ -0,0 +1,2 @@ +.idea/* + diff --git a/vendor/github.com/spf13/pflag/.travis.yml b/vendor/github.com/spf13/pflag/.travis.yml index 580ad22f59..707bdc39a7 100644 --- a/vendor/github.com/spf13/pflag/.travis.yml +++ b/vendor/github.com/spf13/pflag/.travis.yml @@ -3,10 +3,13 @@ sudo: false language: go go: - - 1.5.4 - 1.6.3 + - 1.7.3 - tip +matrix: + allow_failures: + - go: tip install: - go get github.com/golang/lint/golint - export PATH=$GOPATH/bin:$PATH diff --git a/vendor/github.com/spf13/pflag/README.md b/vendor/github.com/spf13/pflag/README.md index 08ad945658..eefb46dec8 100644 --- a/vendor/github.com/spf13/pflag/README.md +++ b/vendor/github.com/spf13/pflag/README.md @@ -1,4 +1,6 @@ [![Build Status](https://travis-ci.org/spf13/pflag.svg?branch=master)](https://travis-ci.org/spf13/pflag) +[![Go Report Card](https://goreportcard.com/badge/github.com/spf13/pflag)](https://goreportcard.com/report/github.com/spf13/pflag) +[![GoDoc](https://godoc.org/github.com/spf13/pflag?status.svg)](https://godoc.org/github.com/spf13/pflag) ## Description @@ -106,9 +108,9 @@ that give one-letter shorthands for flags. You can use these by appending var ip = flag.IntP("flagname", "f", 1234, "help message") var flagvar bool func init() { - flag.BoolVarP("boolname", "b", true, "help message") + flag.BoolVarP(&flagvar, "boolname", "b", true, "help message") } -flag.VarP(&flagVar, "varname", "v", 1234, "help message") +flag.VarP(&flagVal, "varname", "v", "help message") ``` Shorthand letters can be used with single dashes on the command line. diff --git a/vendor/github.com/spf13/pflag/bool.go b/vendor/github.com/spf13/pflag/bool.go index d272e40bdd..c4c5c0bfda 100644 --- a/vendor/github.com/spf13/pflag/bool.go +++ b/vendor/github.com/spf13/pflag/bool.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // optional interface to indicate boolean flags that can be // supplied without "=value" text @@ -30,7 +27,7 @@ func (b *boolValue) Type() string { return "bool" } -func (b *boolValue) String() string { return fmt.Sprintf("%v", *b) } +func (b *boolValue) String() string { return strconv.FormatBool(bool(*b)) } func (b *boolValue) IsBoolFlag() bool { return true } diff --git a/vendor/github.com/spf13/pflag/bool_slice.go b/vendor/github.com/spf13/pflag/bool_slice.go new file mode 100644 index 0000000000..5af02f1a75 --- /dev/null +++ b/vendor/github.com/spf13/pflag/bool_slice.go @@ -0,0 +1,147 @@ +package pflag + +import ( + "io" + "strconv" + "strings" +) + +// -- boolSlice Value +type boolSliceValue struct { + value *[]bool + changed bool +} + +func newBoolSliceValue(val []bool, p *[]bool) *boolSliceValue { + bsv := new(boolSliceValue) + bsv.value = p + *bsv.value = val + return bsv +} + +// Set converts, and assigns, the comma-separated boolean argument string representation as the []bool value of this flag. +// If Set is called on a flag that already has a []bool assigned, the newly converted values will be appended. +func (s *boolSliceValue) Set(val string) error { + + // remove all quote characters + rmQuote := strings.NewReplacer(`"`, "", `'`, "", "`", "") + + // read flag arguments with CSV parser + boolStrSlice, err := readAsCSV(rmQuote.Replace(val)) + if err != nil && err != io.EOF { + return err + } + + // parse boolean values into slice + out := make([]bool, 0, len(boolStrSlice)) + for _, boolStr := range boolStrSlice { + b, err := strconv.ParseBool(strings.TrimSpace(boolStr)) + if err != nil { + return err + } + out = append(out, b) + } + + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + + s.changed = true + + return nil +} + +// Type returns a string that uniquely represents this flag's type. +func (s *boolSliceValue) Type() string { + return "boolSlice" +} + +// String defines a "native" format for this boolean slice flag value. +func (s *boolSliceValue) String() string { + + boolStrSlice := make([]string, len(*s.value)) + for i, b := range *s.value { + boolStrSlice[i] = strconv.FormatBool(b) + } + + out, _ := writeAsCSV(boolStrSlice) + + return "[" + out + "]" +} + +func boolSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Empty string would cause a slice with one (empty) entry + if len(val) == 0 { + return []bool{}, nil + } + ss := strings.Split(val, ",") + out := make([]bool, len(ss)) + for i, t := range ss { + var err error + out[i], err = strconv.ParseBool(t) + if err != nil { + return nil, err + } + } + return out, nil +} + +// GetBoolSlice returns the []bool value of a flag with the given name. +func (f *FlagSet) GetBoolSlice(name string) ([]bool, error) { + val, err := f.getFlagType(name, "boolSlice", boolSliceConv) + if err != nil { + return []bool{}, err + } + return val.([]bool), nil +} + +// BoolSliceVar defines a boolSlice flag with specified name, default value, and usage string. +// The argument p points to a []bool variable in which to store the value of the flag. +func (f *FlagSet) BoolSliceVar(p *[]bool, name string, value []bool, usage string) { + f.VarP(newBoolSliceValue(value, p), name, "", usage) +} + +// BoolSliceVarP is like BoolSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BoolSliceVarP(p *[]bool, name, shorthand string, value []bool, usage string) { + f.VarP(newBoolSliceValue(value, p), name, shorthand, usage) +} + +// BoolSliceVar defines a []bool flag with specified name, default value, and usage string. +// The argument p points to a []bool variable in which to store the value of the flag. +func BoolSliceVar(p *[]bool, name string, value []bool, usage string) { + CommandLine.VarP(newBoolSliceValue(value, p), name, "", usage) +} + +// BoolSliceVarP is like BoolSliceVar, but accepts a shorthand letter that can be used after a single dash. +func BoolSliceVarP(p *[]bool, name, shorthand string, value []bool, usage string) { + CommandLine.VarP(newBoolSliceValue(value, p), name, shorthand, usage) +} + +// BoolSlice defines a []bool flag with specified name, default value, and usage string. +// The return value is the address of a []bool variable that stores the value of the flag. +func (f *FlagSet) BoolSlice(name string, value []bool, usage string) *[]bool { + p := []bool{} + f.BoolSliceVarP(&p, name, "", value, usage) + return &p +} + +// BoolSliceP is like BoolSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) BoolSliceP(name, shorthand string, value []bool, usage string) *[]bool { + p := []bool{} + f.BoolSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// BoolSlice defines a []bool flag with specified name, default value, and usage string. +// The return value is the address of a []bool variable that stores the value of the flag. +func BoolSlice(name string, value []bool, usage string) *[]bool { + return CommandLine.BoolSliceP(name, "", value, usage) +} + +// BoolSliceP is like BoolSlice, but accepts a shorthand letter that can be used after a single dash. +func BoolSliceP(name, shorthand string, value []bool, usage string) *[]bool { + return CommandLine.BoolSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/count.go b/vendor/github.com/spf13/pflag/count.go index 7b1f142e78..d22be41f29 100644 --- a/vendor/github.com/spf13/pflag/count.go +++ b/vendor/github.com/spf13/pflag/count.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- count Value type countValue int @@ -28,7 +25,7 @@ func (i *countValue) Type() string { return "count" } -func (i *countValue) String() string { return fmt.Sprintf("%v", *i) } +func (i *countValue) String() string { return strconv.Itoa(int(*i)) } func countConv(sval string) (interface{}, error) { i, err := strconv.Atoi(sval) diff --git a/vendor/github.com/spf13/pflag/flag.go b/vendor/github.com/spf13/pflag/flag.go index 965df13797..746af6327e 100644 --- a/vendor/github.com/spf13/pflag/flag.go +++ b/vendor/github.com/spf13/pflag/flag.go @@ -416,23 +416,39 @@ func Set(name, value string) error { // otherwise, the default values of all defined flags in the set. func (f *FlagSet) PrintDefaults() { usages := f.FlagUsages() - fmt.Fprintf(f.out(), "%s", usages) -} - -// isZeroValue guesses whether the string represents the zero -// value for a flag. It is not accurate but in practice works OK. -func isZeroValue(value string) bool { - switch value { - case "false": - return true - case "": - return true - case "": - return true - case "0": - return true + fmt.Fprint(f.out(), usages) +} + +// defaultIsZeroValue returns true if the default value for this flag represents +// a zero value. +func (f *Flag) defaultIsZeroValue() bool { + switch f.Value.(type) { + case boolFlag: + return f.DefValue == "false" + case *durationValue: + // Beginning in Go 1.7, duration zero values are "0s" + return f.DefValue == "0" || f.DefValue == "0s" + case *intValue, *int8Value, *int32Value, *int64Value, *uintValue, *uint8Value, *uint16Value, *uint32Value, *uint64Value, *countValue, *float32Value, *float64Value: + return f.DefValue == "0" + case *stringValue: + return f.DefValue == "" + case *ipValue, *ipMaskValue, *ipNetValue: + return f.DefValue == "" + case *intSliceValue, *stringSliceValue, *stringArrayValue: + return f.DefValue == "[]" + default: + switch f.Value.String() { + case "false": + return true + case "": + return true + case "": + return true + case "0": + return true + } + return false } - return false } // UnquoteUsage extracts a back-quoted name from the usage @@ -455,28 +471,92 @@ func UnquoteUsage(flag *Flag) (name string, usage string) { break // Only one back quote; use type name. } } - // No explicit name, so use type if we can find one. - name = "value" - switch flag.Value.(type) { - case boolFlag: + + name = flag.Value.Type() + switch name { + case "bool": name = "" - case *durationValue: - name = "duration" - case *float64Value: + case "float64": name = "float" - case *intValue, *int64Value: + case "int64": name = "int" - case *stringValue: - name = "string" - case *uintValue, *uint64Value: + case "uint64": name = "uint" } + return } -// FlagUsages Returns a string containing the usage information for all flags in -// the FlagSet -func (f *FlagSet) FlagUsages() string { +// Splits the string `s` on whitespace into an initial substring up to +// `i` runes in length and the remainder. Will go `slop` over `i` if +// that encompasses the entire string (which allows the caller to +// avoid short orphan words on the final line). +func wrapN(i, slop int, s string) (string, string) { + if i+slop > len(s) { + return s, "" + } + + w := strings.LastIndexAny(s[:i], " \t") + if w <= 0 { + return s, "" + } + + return s[:w], s[w+1:] +} + +// Wraps the string `s` to a maximum width `w` with leading indent +// `i`. The first line is not indented (this is assumed to be done by +// caller). Pass `w` == 0 to do no wrapping +func wrap(i, w int, s string) string { + if w == 0 { + return s + } + + // space between indent i and end of line width w into which + // we should wrap the text. + wrap := w - i + + var r, l string + + // Not enough space for sensible wrapping. Wrap as a block on + // the next line instead. + if wrap < 24 { + i = 16 + wrap = w - i + r += "\n" + strings.Repeat(" ", i) + } + // If still not enough space then don't even try to wrap. + if wrap < 24 { + return s + } + + // Try to avoid short orphan words on the final line, by + // allowing wrapN to go a bit over if that would fit in the + // remainder of the line. + slop := 5 + wrap = wrap - slop + + // Handle first line, which is indented by the caller (or the + // special case above) + l, s = wrapN(wrap, slop, s) + r = r + l + + // Now wrap the rest + for s != "" { + var t string + + t, s = wrapN(wrap, slop, s) + r = r + "\n" + strings.Repeat(" ", i) + t + } + + return r + +} + +// FlagUsagesWrapped returns a string containing the usage information +// for all flags in the FlagSet. Wrapped to `cols` columns (0 for no +// wrapping) +func (f *FlagSet) FlagUsagesWrapped(cols int) string { x := new(bytes.Buffer) lines := make([]string, 0, len(f.formal)) @@ -501,7 +581,7 @@ func (f *FlagSet) FlagUsages() string { if len(flag.NoOptDefVal) > 0 { switch flag.Value.Type() { case "string": - line += fmt.Sprintf("[=%q]", flag.NoOptDefVal) + line += fmt.Sprintf("[=\"%s\"]", flag.NoOptDefVal) case "bool": if flag.NoOptDefVal != "true" { line += fmt.Sprintf("[=%s]", flag.NoOptDefVal) @@ -519,9 +599,9 @@ func (f *FlagSet) FlagUsages() string { } line += usage - if !isZeroValue(flag.DefValue) { + if !flag.defaultIsZeroValue() { if flag.Value.Type() == "string" { - line += fmt.Sprintf(" (default %q)", flag.DefValue) + line += fmt.Sprintf(" (default \"%s\")", flag.DefValue) } else { line += fmt.Sprintf(" (default %s)", flag.DefValue) } @@ -533,12 +613,19 @@ func (f *FlagSet) FlagUsages() string { for _, line := range lines { sidx := strings.Index(line, "\x00") spacing := strings.Repeat(" ", maxlen-sidx) - fmt.Fprintln(x, line[:sidx], spacing, line[sidx+1:]) + // maxlen + 2 comes from + 1 for the \x00 and + 1 for the (deliberate) off-by-one in maxlen-sidx + fmt.Fprintln(x, line[:sidx], spacing, wrap(maxlen+2, cols, line[sidx+1:])) } return x.String() } +// FlagUsages returns a string containing the usage information for all flags in +// the FlagSet +func (f *FlagSet) FlagUsages() string { + return f.FlagUsagesWrapped(0) +} + // PrintDefaults prints to standard error the default values of all defined command-line flags. func PrintDefaults() { CommandLine.PrintDefaults() @@ -622,7 +709,7 @@ func (f *FlagSet) VarPF(value Value, name, shorthand, usage string) *Flag { // VarP is like Var, but accepts a shorthand letter that can be used after a single dash. func (f *FlagSet) VarP(value Value, name, shorthand, usage string) { - _ = f.VarPF(value, name, shorthand, usage) + f.VarPF(value, name, shorthand, usage) } // AddFlag will add the flag to the FlagSet @@ -739,7 +826,7 @@ func containsShorthand(arg, shorthand string) bool { return strings.Contains(arg, shorthand) } -func (f *FlagSet) parseLongArg(s string, args []string) (a []string, err error) { +func (f *FlagSet) parseLongArg(s string, args []string, fn parseFunc) (a []string, err error) { a = args name := s[2:] if len(name) == 0 || name[0] == '-' || name[0] == '=' { @@ -773,11 +860,11 @@ func (f *FlagSet) parseLongArg(s string, args []string) (a []string, err error) err = f.failf("flag needs an argument: %s", s) return } - err = f.setFlag(flag, value, s) + err = fn(flag, value, s) return } -func (f *FlagSet) parseSingleShortArg(shorthands string, args []string) (outShorts string, outArgs []string, err error) { +func (f *FlagSet) parseSingleShortArg(shorthands string, args []string, fn parseFunc) (outShorts string, outArgs []string, err error) { if strings.HasPrefix(shorthands, "test.") { return } @@ -812,16 +899,16 @@ func (f *FlagSet) parseSingleShortArg(shorthands string, args []string) (outShor err = f.failf("flag needs an argument: %q in -%s", c, shorthands) return } - err = f.setFlag(flag, value, shorthands) + err = fn(flag, value, shorthands) return } -func (f *FlagSet) parseShortArg(s string, args []string) (a []string, err error) { +func (f *FlagSet) parseShortArg(s string, args []string, fn parseFunc) (a []string, err error) { a = args shorthands := s[1:] for len(shorthands) > 0 { - shorthands, a, err = f.parseSingleShortArg(shorthands, args) + shorthands, a, err = f.parseSingleShortArg(shorthands, args, fn) if err != nil { return } @@ -830,7 +917,7 @@ func (f *FlagSet) parseShortArg(s string, args []string) (a []string, err error) return } -func (f *FlagSet) parseArgs(args []string) (err error) { +func (f *FlagSet) parseArgs(args []string, fn parseFunc) (err error) { for len(args) > 0 { s := args[0] args = args[1:] @@ -850,9 +937,9 @@ func (f *FlagSet) parseArgs(args []string) (err error) { f.args = append(f.args, args...) break } - args, err = f.parseLongArg(s, args) + args, err = f.parseLongArg(s, args, fn) } else { - args, err = f.parseShortArg(s, args) + args, err = f.parseShortArg(s, args, fn) } if err != nil { return @@ -868,7 +955,41 @@ func (f *FlagSet) parseArgs(args []string) (err error) { func (f *FlagSet) Parse(arguments []string) error { f.parsed = true f.args = make([]string, 0, len(arguments)) - err := f.parseArgs(arguments) + + assign := func(flag *Flag, value, origArg string) error { + return f.setFlag(flag, value, origArg) + } + + err := f.parseArgs(arguments, assign) + if err != nil { + switch f.errorHandling { + case ContinueOnError: + return err + case ExitOnError: + os.Exit(2) + case PanicOnError: + panic(err) + } + } + return nil +} + +type parseFunc func(flag *Flag, value, origArg string) error + +// ParseAll parses flag definitions from the argument list, which should not +// include the command name. The arguments for fn are flag and value. Must be +// called after all flags in the FlagSet are defined and before flags are +// accessed by the program. The return value will be ErrHelp if -help was set +// but not defined. +func (f *FlagSet) ParseAll(arguments []string, fn func(flag *Flag, value string) error) error { + f.parsed = true + f.args = make([]string, 0, len(arguments)) + + assign := func(flag *Flag, value, origArg string) error { + return fn(flag, value) + } + + err := f.parseArgs(arguments, assign) if err != nil { switch f.errorHandling { case ContinueOnError: @@ -894,6 +1015,14 @@ func Parse() { CommandLine.Parse(os.Args[1:]) } +// ParseAll parses the command-line flags from os.Args[1:] and called fn for each. +// The arguments for fn are flag and value. Must be called after all flags are +// defined and before flags are accessed by the program. +func ParseAll(fn func(flag *Flag, value string) error) { + // Ignore errors; CommandLine is set for ExitOnError. + CommandLine.ParseAll(os.Args[1:], fn) +} + // SetInterspersed sets whether to support interspersed option/non-option arguments. func SetInterspersed(interspersed bool) { CommandLine.SetInterspersed(interspersed) diff --git a/vendor/github.com/spf13/pflag/float32.go b/vendor/github.com/spf13/pflag/float32.go index 7683fae1b1..a243f81f7f 100644 --- a/vendor/github.com/spf13/pflag/float32.go +++ b/vendor/github.com/spf13/pflag/float32.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- float32 Value type float32Value float32 @@ -23,7 +20,7 @@ func (f *float32Value) Type() string { return "float32" } -func (f *float32Value) String() string { return fmt.Sprintf("%v", *f) } +func (f *float32Value) String() string { return strconv.FormatFloat(float64(*f), 'g', -1, 32) } func float32Conv(sval string) (interface{}, error) { v, err := strconv.ParseFloat(sval, 32) diff --git a/vendor/github.com/spf13/pflag/float64.go b/vendor/github.com/spf13/pflag/float64.go index 50fbf8cc1a..04b5492a7d 100644 --- a/vendor/github.com/spf13/pflag/float64.go +++ b/vendor/github.com/spf13/pflag/float64.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- float64 Value type float64Value float64 @@ -23,7 +20,7 @@ func (f *float64Value) Type() string { return "float64" } -func (f *float64Value) String() string { return fmt.Sprintf("%v", *f) } +func (f *float64Value) String() string { return strconv.FormatFloat(float64(*f), 'g', -1, 64) } func float64Conv(sval string) (interface{}, error) { return strconv.ParseFloat(sval, 64) diff --git a/vendor/github.com/spf13/pflag/golangflag.go b/vendor/github.com/spf13/pflag/golangflag.go index b056147fd8..c4f47ebe59 100644 --- a/vendor/github.com/spf13/pflag/golangflag.go +++ b/vendor/github.com/spf13/pflag/golangflag.go @@ -6,13 +6,10 @@ package pflag import ( goflag "flag" - "fmt" "reflect" "strings" ) -var _ = fmt.Print - // flagValueWrapper implements pflag.Value around a flag.Value. The main // difference here is the addition of the Type method that returns a string // name of the type. As this is generally unknown, we approximate that with diff --git a/vendor/github.com/spf13/pflag/int.go b/vendor/github.com/spf13/pflag/int.go index b6560368a9..1474b89df6 100644 --- a/vendor/github.com/spf13/pflag/int.go +++ b/vendor/github.com/spf13/pflag/int.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- int Value type intValue int @@ -23,7 +20,7 @@ func (i *intValue) Type() string { return "int" } -func (i *intValue) String() string { return fmt.Sprintf("%v", *i) } +func (i *intValue) String() string { return strconv.Itoa(int(*i)) } func intConv(sval string) (interface{}, error) { return strconv.Atoi(sval) diff --git a/vendor/github.com/spf13/pflag/int32.go b/vendor/github.com/spf13/pflag/int32.go index 41659a9aff..9b95944f0f 100644 --- a/vendor/github.com/spf13/pflag/int32.go +++ b/vendor/github.com/spf13/pflag/int32.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- int32 Value type int32Value int32 @@ -23,7 +20,7 @@ func (i *int32Value) Type() string { return "int32" } -func (i *int32Value) String() string { return fmt.Sprintf("%v", *i) } +func (i *int32Value) String() string { return strconv.FormatInt(int64(*i), 10) } func int32Conv(sval string) (interface{}, error) { v, err := strconv.ParseInt(sval, 0, 32) diff --git a/vendor/github.com/spf13/pflag/int64.go b/vendor/github.com/spf13/pflag/int64.go index 6e67e380f4..0026d781d9 100644 --- a/vendor/github.com/spf13/pflag/int64.go +++ b/vendor/github.com/spf13/pflag/int64.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- int64 Value type int64Value int64 @@ -23,7 +20,7 @@ func (i *int64Value) Type() string { return "int64" } -func (i *int64Value) String() string { return fmt.Sprintf("%v", *i) } +func (i *int64Value) String() string { return strconv.FormatInt(int64(*i), 10) } func int64Conv(sval string) (interface{}, error) { return strconv.ParseInt(sval, 0, 64) diff --git a/vendor/github.com/spf13/pflag/int8.go b/vendor/github.com/spf13/pflag/int8.go index 400db21f5e..4da92228e6 100644 --- a/vendor/github.com/spf13/pflag/int8.go +++ b/vendor/github.com/spf13/pflag/int8.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- int8 Value type int8Value int8 @@ -23,7 +20,7 @@ func (i *int8Value) Type() string { return "int8" } -func (i *int8Value) String() string { return fmt.Sprintf("%v", *i) } +func (i *int8Value) String() string { return strconv.FormatInt(int64(*i), 10) } func int8Conv(sval string) (interface{}, error) { v, err := strconv.ParseInt(sval, 0, 8) diff --git a/vendor/github.com/spf13/pflag/ip.go b/vendor/github.com/spf13/pflag/ip.go index 88a17430a0..3d414ba69f 100644 --- a/vendor/github.com/spf13/pflag/ip.go +++ b/vendor/github.com/spf13/pflag/ip.go @@ -6,8 +6,6 @@ import ( "strings" ) -var _ = strings.TrimSpace - // -- net.IP value type ipValue net.IP diff --git a/vendor/github.com/spf13/pflag/ip_slice.go b/vendor/github.com/spf13/pflag/ip_slice.go new file mode 100644 index 0000000000..7dd196fe3f --- /dev/null +++ b/vendor/github.com/spf13/pflag/ip_slice.go @@ -0,0 +1,148 @@ +package pflag + +import ( + "fmt" + "io" + "net" + "strings" +) + +// -- ipSlice Value +type ipSliceValue struct { + value *[]net.IP + changed bool +} + +func newIPSliceValue(val []net.IP, p *[]net.IP) *ipSliceValue { + ipsv := new(ipSliceValue) + ipsv.value = p + *ipsv.value = val + return ipsv +} + +// Set converts, and assigns, the comma-separated IP argument string representation as the []net.IP value of this flag. +// If Set is called on a flag that already has a []net.IP assigned, the newly converted values will be appended. +func (s *ipSliceValue) Set(val string) error { + + // remove all quote characters + rmQuote := strings.NewReplacer(`"`, "", `'`, "", "`", "") + + // read flag arguments with CSV parser + ipStrSlice, err := readAsCSV(rmQuote.Replace(val)) + if err != nil && err != io.EOF { + return err + } + + // parse ip values into slice + out := make([]net.IP, 0, len(ipStrSlice)) + for _, ipStr := range ipStrSlice { + ip := net.ParseIP(strings.TrimSpace(ipStr)) + if ip == nil { + return fmt.Errorf("invalid string being converted to IP address: %s", ipStr) + } + out = append(out, ip) + } + + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + + s.changed = true + + return nil +} + +// Type returns a string that uniquely represents this flag's type. +func (s *ipSliceValue) Type() string { + return "ipSlice" +} + +// String defines a "native" format for this net.IP slice flag value. +func (s *ipSliceValue) String() string { + + ipStrSlice := make([]string, len(*s.value)) + for i, ip := range *s.value { + ipStrSlice[i] = ip.String() + } + + out, _ := writeAsCSV(ipStrSlice) + + return "[" + out + "]" +} + +func ipSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Emtpy string would cause a slice with one (empty) entry + if len(val) == 0 { + return []net.IP{}, nil + } + ss := strings.Split(val, ",") + out := make([]net.IP, len(ss)) + for i, sval := range ss { + ip := net.ParseIP(strings.TrimSpace(sval)) + if ip == nil { + return nil, fmt.Errorf("invalid string being converted to IP address: %s", sval) + } + out[i] = ip + } + return out, nil +} + +// GetIPSlice returns the []net.IP value of a flag with the given name +func (f *FlagSet) GetIPSlice(name string) ([]net.IP, error) { + val, err := f.getFlagType(name, "ipSlice", ipSliceConv) + if err != nil { + return []net.IP{}, err + } + return val.([]net.IP), nil +} + +// IPSliceVar defines a ipSlice flag with specified name, default value, and usage string. +// The argument p points to a []net.IP variable in which to store the value of the flag. +func (f *FlagSet) IPSliceVar(p *[]net.IP, name string, value []net.IP, usage string) { + f.VarP(newIPSliceValue(value, p), name, "", usage) +} + +// IPSliceVarP is like IPSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPSliceVarP(p *[]net.IP, name, shorthand string, value []net.IP, usage string) { + f.VarP(newIPSliceValue(value, p), name, shorthand, usage) +} + +// IPSliceVar defines a []net.IP flag with specified name, default value, and usage string. +// The argument p points to a []net.IP variable in which to store the value of the flag. +func IPSliceVar(p *[]net.IP, name string, value []net.IP, usage string) { + CommandLine.VarP(newIPSliceValue(value, p), name, "", usage) +} + +// IPSliceVarP is like IPSliceVar, but accepts a shorthand letter that can be used after a single dash. +func IPSliceVarP(p *[]net.IP, name, shorthand string, value []net.IP, usage string) { + CommandLine.VarP(newIPSliceValue(value, p), name, shorthand, usage) +} + +// IPSlice defines a []net.IP flag with specified name, default value, and usage string. +// The return value is the address of a []net.IP variable that stores the value of that flag. +func (f *FlagSet) IPSlice(name string, value []net.IP, usage string) *[]net.IP { + p := []net.IP{} + f.IPSliceVarP(&p, name, "", value, usage) + return &p +} + +// IPSliceP is like IPSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) IPSliceP(name, shorthand string, value []net.IP, usage string) *[]net.IP { + p := []net.IP{} + f.IPSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// IPSlice defines a []net.IP flag with specified name, default value, and usage string. +// The return value is the address of a []net.IP variable that stores the value of the flag. +func IPSlice(name string, value []net.IP, usage string) *[]net.IP { + return CommandLine.IPSliceP(name, "", value, usage) +} + +// IPSliceP is like IPSlice, but accepts a shorthand letter that can be used after a single dash. +func IPSliceP(name, shorthand string, value []net.IP, usage string) *[]net.IP { + return CommandLine.IPSliceP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/ipnet.go b/vendor/github.com/spf13/pflag/ipnet.go index 149b764b1e..e2c1b8bcd5 100644 --- a/vendor/github.com/spf13/pflag/ipnet.go +++ b/vendor/github.com/spf13/pflag/ipnet.go @@ -27,8 +27,6 @@ func (*ipNetValue) Type() string { return "ipNet" } -var _ = strings.TrimSpace - func newIPNetValue(val net.IPNet, p *net.IPNet) *ipNetValue { *p = val return (*ipNetValue)(p) diff --git a/vendor/github.com/spf13/pflag/string.go b/vendor/github.com/spf13/pflag/string.go index e296136e5b..04e0a26ff7 100644 --- a/vendor/github.com/spf13/pflag/string.go +++ b/vendor/github.com/spf13/pflag/string.go @@ -1,7 +1,5 @@ package pflag -import "fmt" - // -- string Value type stringValue string @@ -18,7 +16,7 @@ func (s *stringValue) Type() string { return "string" } -func (s *stringValue) String() string { return fmt.Sprintf("%s", *s) } +func (s *stringValue) String() string { return string(*s) } func stringConv(sval string) (interface{}, error) { return sval, nil diff --git a/vendor/github.com/spf13/pflag/string_array.go b/vendor/github.com/spf13/pflag/string_array.go new file mode 100644 index 0000000000..276b7ed49e --- /dev/null +++ b/vendor/github.com/spf13/pflag/string_array.go @@ -0,0 +1,103 @@ +package pflag + +// -- stringArray Value +type stringArrayValue struct { + value *[]string + changed bool +} + +func newStringArrayValue(val []string, p *[]string) *stringArrayValue { + ssv := new(stringArrayValue) + ssv.value = p + *ssv.value = val + return ssv +} + +func (s *stringArrayValue) Set(val string) error { + if !s.changed { + *s.value = []string{val} + s.changed = true + } else { + *s.value = append(*s.value, val) + } + return nil +} + +func (s *stringArrayValue) Type() string { + return "stringArray" +} + +func (s *stringArrayValue) String() string { + str, _ := writeAsCSV(*s.value) + return "[" + str + "]" +} + +func stringArrayConv(sval string) (interface{}, error) { + sval = sval[1 : len(sval)-1] + // An empty string would cause a array with one (empty) string + if len(sval) == 0 { + return []string{}, nil + } + return readAsCSV(sval) +} + +// GetStringArray return the []string value of a flag with the given name +func (f *FlagSet) GetStringArray(name string) ([]string, error) { + val, err := f.getFlagType(name, "stringArray", stringArrayConv) + if err != nil { + return []string{}, err + } + return val.([]string), nil +} + +// StringArrayVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a []string variable in which to store the values of the multiple flags. +// The value of each argument will not try to be separated by comma +func (f *FlagSet) StringArrayVar(p *[]string, name string, value []string, usage string) { + f.VarP(newStringArrayValue(value, p), name, "", usage) +} + +// StringArrayVarP is like StringArrayVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringArrayVarP(p *[]string, name, shorthand string, value []string, usage string) { + f.VarP(newStringArrayValue(value, p), name, shorthand, usage) +} + +// StringArrayVar defines a string flag with specified name, default value, and usage string. +// The argument p points to a []string variable in which to store the value of the flag. +// The value of each argument will not try to be separated by comma +func StringArrayVar(p *[]string, name string, value []string, usage string) { + CommandLine.VarP(newStringArrayValue(value, p), name, "", usage) +} + +// StringArrayVarP is like StringArrayVar, but accepts a shorthand letter that can be used after a single dash. +func StringArrayVarP(p *[]string, name, shorthand string, value []string, usage string) { + CommandLine.VarP(newStringArrayValue(value, p), name, shorthand, usage) +} + +// StringArray defines a string flag with specified name, default value, and usage string. +// The return value is the address of a []string variable that stores the value of the flag. +// The value of each argument will not try to be separated by comma +func (f *FlagSet) StringArray(name string, value []string, usage string) *[]string { + p := []string{} + f.StringArrayVarP(&p, name, "", value, usage) + return &p +} + +// StringArrayP is like StringArray, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) StringArrayP(name, shorthand string, value []string, usage string) *[]string { + p := []string{} + f.StringArrayVarP(&p, name, shorthand, value, usage) + return &p +} + +// StringArray defines a string flag with specified name, default value, and usage string. +// The return value is the address of a []string variable that stores the value of the flag. +// The value of each argument will not try to be separated by comma +func StringArray(name string, value []string, usage string) *[]string { + return CommandLine.StringArrayP(name, "", value, usage) +} + +// StringArrayP is like StringArray, but accepts a shorthand letter that can be used after a single dash. +func StringArrayP(name, shorthand string, value []string, usage string) *[]string { + return CommandLine.StringArrayP(name, shorthand, value, usage) +} diff --git a/vendor/github.com/spf13/pflag/string_slice.go b/vendor/github.com/spf13/pflag/string_slice.go index b53648b2e5..05eee75438 100644 --- a/vendor/github.com/spf13/pflag/string_slice.go +++ b/vendor/github.com/spf13/pflag/string_slice.go @@ -1,13 +1,11 @@ package pflag import ( + "bytes" "encoding/csv" - "fmt" "strings" ) -var _ = fmt.Fprint - // -- stringSlice Value type stringSliceValue struct { value *[]string @@ -21,10 +19,28 @@ func newStringSliceValue(val []string, p *[]string) *stringSliceValue { return ssv } -func (s *stringSliceValue) Set(val string) error { +func readAsCSV(val string) ([]string, error) { + if val == "" { + return []string{}, nil + } stringReader := strings.NewReader(val) csvReader := csv.NewReader(stringReader) - v, err := csvReader.Read() + return csvReader.Read() +} + +func writeAsCSV(vals []string) (string, error) { + b := &bytes.Buffer{} + w := csv.NewWriter(b) + err := w.Write(vals) + if err != nil { + return "", err + } + w.Flush() + return strings.TrimSuffix(b.String(), "\n"), nil +} + +func (s *stringSliceValue) Set(val string) error { + v, err := readAsCSV(val) if err != nil { return err } @@ -41,16 +57,18 @@ func (s *stringSliceValue) Type() string { return "stringSlice" } -func (s *stringSliceValue) String() string { return "[" + strings.Join(*s.value, ",") + "]" } +func (s *stringSliceValue) String() string { + str, _ := writeAsCSV(*s.value) + return "[" + str + "]" +} func stringSliceConv(sval string) (interface{}, error) { - sval = strings.Trim(sval, "[]") + sval = sval[1 : len(sval)-1] // An empty string would cause a slice with one (empty) string if len(sval) == 0 { return []string{}, nil } - v := strings.Split(sval, ",") - return v, nil + return readAsCSV(sval) } // GetStringSlice return the []string value of a flag with the given name diff --git a/vendor/github.com/spf13/pflag/uint.go b/vendor/github.com/spf13/pflag/uint.go index e142b49964..dcbc2b758c 100644 --- a/vendor/github.com/spf13/pflag/uint.go +++ b/vendor/github.com/spf13/pflag/uint.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- uint Value type uintValue uint @@ -23,7 +20,7 @@ func (i *uintValue) Type() string { return "uint" } -func (i *uintValue) String() string { return fmt.Sprintf("%v", *i) } +func (i *uintValue) String() string { return strconv.FormatUint(uint64(*i), 10) } func uintConv(sval string) (interface{}, error) { v, err := strconv.ParseUint(sval, 0, 0) diff --git a/vendor/github.com/spf13/pflag/uint16.go b/vendor/github.com/spf13/pflag/uint16.go index 5c96c19dcf..7e9914eddd 100644 --- a/vendor/github.com/spf13/pflag/uint16.go +++ b/vendor/github.com/spf13/pflag/uint16.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- uint16 value type uint16Value uint16 @@ -12,7 +9,7 @@ func newUint16Value(val uint16, p *uint16) *uint16Value { *p = val return (*uint16Value)(p) } -func (i *uint16Value) String() string { return fmt.Sprintf("%d", *i) } + func (i *uint16Value) Set(s string) error { v, err := strconv.ParseUint(s, 0, 16) *i = uint16Value(v) @@ -23,6 +20,8 @@ func (i *uint16Value) Type() string { return "uint16" } +func (i *uint16Value) String() string { return strconv.FormatUint(uint64(*i), 10) } + func uint16Conv(sval string) (interface{}, error) { v, err := strconv.ParseUint(sval, 0, 16) if err != nil { diff --git a/vendor/github.com/spf13/pflag/uint32.go b/vendor/github.com/spf13/pflag/uint32.go index 294fcaa32d..d8024539bf 100644 --- a/vendor/github.com/spf13/pflag/uint32.go +++ b/vendor/github.com/spf13/pflag/uint32.go @@ -1,18 +1,15 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" -// -- uint16 value +// -- uint32 value type uint32Value uint32 func newUint32Value(val uint32, p *uint32) *uint32Value { *p = val return (*uint32Value)(p) } -func (i *uint32Value) String() string { return fmt.Sprintf("%d", *i) } + func (i *uint32Value) Set(s string) error { v, err := strconv.ParseUint(s, 0, 32) *i = uint32Value(v) @@ -23,6 +20,8 @@ func (i *uint32Value) Type() string { return "uint32" } +func (i *uint32Value) String() string { return strconv.FormatUint(uint64(*i), 10) } + func uint32Conv(sval string) (interface{}, error) { v, err := strconv.ParseUint(sval, 0, 32) if err != nil { diff --git a/vendor/github.com/spf13/pflag/uint64.go b/vendor/github.com/spf13/pflag/uint64.go index c68188505a..f62240f2ce 100644 --- a/vendor/github.com/spf13/pflag/uint64.go +++ b/vendor/github.com/spf13/pflag/uint64.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- uint64 Value type uint64Value uint64 @@ -23,7 +20,7 @@ func (i *uint64Value) Type() string { return "uint64" } -func (i *uint64Value) String() string { return fmt.Sprintf("%v", *i) } +func (i *uint64Value) String() string { return strconv.FormatUint(uint64(*i), 10) } func uint64Conv(sval string) (interface{}, error) { v, err := strconv.ParseUint(sval, 0, 64) diff --git a/vendor/github.com/spf13/pflag/uint8.go b/vendor/github.com/spf13/pflag/uint8.go index 26db418adf..bb0e83c1f6 100644 --- a/vendor/github.com/spf13/pflag/uint8.go +++ b/vendor/github.com/spf13/pflag/uint8.go @@ -1,9 +1,6 @@ package pflag -import ( - "fmt" - "strconv" -) +import "strconv" // -- uint8 Value type uint8Value uint8 @@ -23,7 +20,7 @@ func (i *uint8Value) Type() string { return "uint8" } -func (i *uint8Value) String() string { return fmt.Sprintf("%v", *i) } +func (i *uint8Value) String() string { return strconv.FormatUint(uint64(*i), 10) } func uint8Conv(sval string) (interface{}, error) { v, err := strconv.ParseUint(sval, 0, 8) diff --git a/vendor/github.com/spf13/pflag/uint_slice.go b/vendor/github.com/spf13/pflag/uint_slice.go new file mode 100644 index 0000000000..edd94c600a --- /dev/null +++ b/vendor/github.com/spf13/pflag/uint_slice.go @@ -0,0 +1,126 @@ +package pflag + +import ( + "fmt" + "strconv" + "strings" +) + +// -- uintSlice Value +type uintSliceValue struct { + value *[]uint + changed bool +} + +func newUintSliceValue(val []uint, p *[]uint) *uintSliceValue { + uisv := new(uintSliceValue) + uisv.value = p + *uisv.value = val + return uisv +} + +func (s *uintSliceValue) Set(val string) error { + ss := strings.Split(val, ",") + out := make([]uint, len(ss)) + for i, d := range ss { + u, err := strconv.ParseUint(d, 10, 0) + if err != nil { + return err + } + out[i] = uint(u) + } + if !s.changed { + *s.value = out + } else { + *s.value = append(*s.value, out...) + } + s.changed = true + return nil +} + +func (s *uintSliceValue) Type() string { + return "uintSlice" +} + +func (s *uintSliceValue) String() string { + out := make([]string, len(*s.value)) + for i, d := range *s.value { + out[i] = fmt.Sprintf("%d", d) + } + return "[" + strings.Join(out, ",") + "]" +} + +func uintSliceConv(val string) (interface{}, error) { + val = strings.Trim(val, "[]") + // Empty string would cause a slice with one (empty) entry + if len(val) == 0 { + return []uint{}, nil + } + ss := strings.Split(val, ",") + out := make([]uint, len(ss)) + for i, d := range ss { + u, err := strconv.ParseUint(d, 10, 0) + if err != nil { + return nil, err + } + out[i] = uint(u) + } + return out, nil +} + +// GetUintSlice returns the []uint value of a flag with the given name. +func (f *FlagSet) GetUintSlice(name string) ([]uint, error) { + val, err := f.getFlagType(name, "uintSlice", uintSliceConv) + if err != nil { + return []uint{}, err + } + return val.([]uint), nil +} + +// UintSliceVar defines a uintSlice flag with specified name, default value, and usage string. +// The argument p points to a []uint variable in which to store the value of the flag. +func (f *FlagSet) UintSliceVar(p *[]uint, name string, value []uint, usage string) { + f.VarP(newUintSliceValue(value, p), name, "", usage) +} + +// UintSliceVarP is like UintSliceVar, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) UintSliceVarP(p *[]uint, name, shorthand string, value []uint, usage string) { + f.VarP(newUintSliceValue(value, p), name, shorthand, usage) +} + +// UintSliceVar defines a uint[] flag with specified name, default value, and usage string. +// The argument p points to a uint[] variable in which to store the value of the flag. +func UintSliceVar(p *[]uint, name string, value []uint, usage string) { + CommandLine.VarP(newUintSliceValue(value, p), name, "", usage) +} + +// UintSliceVarP is like the UintSliceVar, but accepts a shorthand letter that can be used after a single dash. +func UintSliceVarP(p *[]uint, name, shorthand string, value []uint, usage string) { + CommandLine.VarP(newUintSliceValue(value, p), name, shorthand, usage) +} + +// UintSlice defines a []uint flag with specified name, default value, and usage string. +// The return value is the address of a []uint variable that stores the value of the flag. +func (f *FlagSet) UintSlice(name string, value []uint, usage string) *[]uint { + p := []uint{} + f.UintSliceVarP(&p, name, "", value, usage) + return &p +} + +// UintSliceP is like UintSlice, but accepts a shorthand letter that can be used after a single dash. +func (f *FlagSet) UintSliceP(name, shorthand string, value []uint, usage string) *[]uint { + p := []uint{} + f.UintSliceVarP(&p, name, shorthand, value, usage) + return &p +} + +// UintSlice defines a []uint flag with specified name, default value, and usage string. +// The return value is the address of a []uint variable that stores the value of the flag. +func UintSlice(name string, value []uint, usage string) *[]uint { + return CommandLine.UintSliceP(name, "", value, usage) +} + +// UintSliceP is like UintSlice, but accepts a shorthand letter that can be used after a single dash. +func UintSliceP(name, shorthand string, value []uint, usage string) *[]uint { + return CommandLine.UintSliceP(name, shorthand, value, usage) +} diff --git a/vendor/golang.org/x/net/context/ctxhttp/ctxhttp.go b/vendor/golang.org/x/net/context/ctxhttp/ctxhttp.go deleted file mode 100644 index f31d882736..0000000000 --- a/vendor/golang.org/x/net/context/ctxhttp/ctxhttp.go +++ /dev/null @@ -1,64 +0,0 @@ -// Copyright 2016 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build go1.7 - -// Package ctxhttp provides helper functions for performing context-aware HTTP requests. -package ctxhttp - -import ( - "io" - "net/http" - "net/url" - "strings" - - "golang.org/x/net/context" -) - -// Do sends an HTTP request with the provided http.Client and returns -// an HTTP response. -// -// If the client is nil, http.DefaultClient is used. -// -// The provided ctx must be non-nil. If it is canceled or times out, -// ctx.Err() will be returned. -func Do(ctx context.Context, client *http.Client, req *http.Request) (*http.Response, error) { - if client == nil { - client = http.DefaultClient - } - return client.Do(req.WithContext(ctx)) -} - -// Get issues a GET request via the Do function. -func Get(ctx context.Context, client *http.Client, url string) (*http.Response, error) { - req, err := http.NewRequest("GET", url, nil) - if err != nil { - return nil, err - } - return Do(ctx, client, req) -} - -// Head issues a HEAD request via the Do function. -func Head(ctx context.Context, client *http.Client, url string) (*http.Response, error) { - req, err := http.NewRequest("HEAD", url, nil) - if err != nil { - return nil, err - } - return Do(ctx, client, req) -} - -// Post issues a POST request via the Do function. -func Post(ctx context.Context, client *http.Client, url string, bodyType string, body io.Reader) (*http.Response, error) { - req, err := http.NewRequest("POST", url, body) - if err != nil { - return nil, err - } - req.Header.Set("Content-Type", bodyType) - return Do(ctx, client, req) -} - -// PostForm issues a POST request via the Do function. -func PostForm(ctx context.Context, client *http.Client, url string, data url.Values) (*http.Response, error) { - return Post(ctx, client, url, "application/x-www-form-urlencoded", strings.NewReader(data.Encode())) -} diff --git a/vendor/golang.org/x/net/context/ctxhttp/ctxhttp_pre17.go b/vendor/golang.org/x/net/context/ctxhttp/ctxhttp_pre17.go deleted file mode 100644 index 7564b20327..0000000000 --- a/vendor/golang.org/x/net/context/ctxhttp/ctxhttp_pre17.go +++ /dev/null @@ -1,147 +0,0 @@ -// Copyright 2015 The Go Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build !go1.7 - -package ctxhttp - -import ( - "io" - "net/http" - "net/url" - "strings" - - "golang.org/x/net/context" -) - -func nop() {} - -var ( - testHookContextDoneBeforeHeaders = nop - testHookDoReturned = nop - testHookDidBodyClose = nop -) - -// Do sends an HTTP request with the provided http.Client and returns an HTTP response. -// If the client is nil, http.DefaultClient is used. -// If the context is canceled or times out, ctx.Err() will be returned. -func Do(ctx context.Context, client *http.Client, req *http.Request) (*http.Response, error) { - if client == nil { - client = http.DefaultClient - } - - // TODO(djd): Respect any existing value of req.Cancel. - cancel := make(chan struct{}) - req.Cancel = cancel - - type responseAndError struct { - resp *http.Response - err error - } - result := make(chan responseAndError, 1) - - // Make local copies of test hooks closed over by goroutines below. - // Prevents data races in tests. - testHookDoReturned := testHookDoReturned - testHookDidBodyClose := testHookDidBodyClose - - go func() { - resp, err := client.Do(req) - testHookDoReturned() - result <- responseAndError{resp, err} - }() - - var resp *http.Response - - select { - case <-ctx.Done(): - testHookContextDoneBeforeHeaders() - close(cancel) - // Clean up after the goroutine calling client.Do: - go func() { - if r := <-result; r.resp != nil { - testHookDidBodyClose() - r.resp.Body.Close() - } - }() - return nil, ctx.Err() - case r := <-result: - var err error - resp, err = r.resp, r.err - if err != nil { - return resp, err - } - } - - c := make(chan struct{}) - go func() { - select { - case <-ctx.Done(): - close(cancel) - case <-c: - // The response's Body is closed. - } - }() - resp.Body = ¬ifyingReader{resp.Body, c} - - return resp, nil -} - -// Get issues a GET request via the Do function. -func Get(ctx context.Context, client *http.Client, url string) (*http.Response, error) { - req, err := http.NewRequest("GET", url, nil) - if err != nil { - return nil, err - } - return Do(ctx, client, req) -} - -// Head issues a HEAD request via the Do function. -func Head(ctx context.Context, client *http.Client, url string) (*http.Response, error) { - req, err := http.NewRequest("HEAD", url, nil) - if err != nil { - return nil, err - } - return Do(ctx, client, req) -} - -// Post issues a POST request via the Do function. -func Post(ctx context.Context, client *http.Client, url string, bodyType string, body io.Reader) (*http.Response, error) { - req, err := http.NewRequest("POST", url, body) - if err != nil { - return nil, err - } - req.Header.Set("Content-Type", bodyType) - return Do(ctx, client, req) -} - -// PostForm issues a POST request via the Do function. -func PostForm(ctx context.Context, client *http.Client, url string, data url.Values) (*http.Response, error) { - return Post(ctx, client, url, "application/x-www-form-urlencoded", strings.NewReader(data.Encode())) -} - -// notifyingReader is an io.ReadCloser that closes the notify channel after -// Close is called or a Read fails on the underlying ReadCloser. -type notifyingReader struct { - io.ReadCloser - notify chan<- struct{} -} - -func (r *notifyingReader) Read(p []byte) (int, error) { - n, err := r.ReadCloser.Read(p) - if err != nil && r.notify != nil { - close(r.notify) - r.notify = nil - } - return n, err -} - -func (r *notifyingReader) Close() error { - err := r.ReadCloser.Close() - if r.notify != nil { - close(r.notify) - r.notify = nil - } - return err -} diff --git a/vendor/golang.org/x/oauth2/.travis.yml b/vendor/golang.org/x/oauth2/.travis.yml deleted file mode 100644 index a035125c35..0000000000 --- a/vendor/golang.org/x/oauth2/.travis.yml +++ /dev/null @@ -1,14 +0,0 @@ -language: go - -go: - - 1.3 - - 1.4 - -install: - - export GOPATH="$HOME/gopath" - - mkdir -p "$GOPATH/src/golang.org/x" - - mv "$TRAVIS_BUILD_DIR" "$GOPATH/src/golang.org/x/oauth2" - - go get -v -t -d golang.org/x/oauth2/... - -script: - - go test -v golang.org/x/oauth2/... diff --git a/vendor/golang.org/x/oauth2/AUTHORS b/vendor/golang.org/x/oauth2/AUTHORS deleted file mode 100644 index 15167cd746..0000000000 --- a/vendor/golang.org/x/oauth2/AUTHORS +++ /dev/null @@ -1,3 +0,0 @@ -# This source code refers to The Go Authors for copyright purposes. -# The master list of authors is in the main Go distribution, -# visible at http://tip.golang.org/AUTHORS. diff --git a/vendor/golang.org/x/oauth2/CONTRIBUTING.md b/vendor/golang.org/x/oauth2/CONTRIBUTING.md deleted file mode 100644 index 46aa2b12dd..0000000000 --- a/vendor/golang.org/x/oauth2/CONTRIBUTING.md +++ /dev/null @@ -1,31 +0,0 @@ -# Contributing to Go - -Go is an open source project. - -It is the work of hundreds of contributors. We appreciate your help! - - -## Filing issues - -When [filing an issue](https://github.com/golang/oauth2/issues), make sure to answer these five questions: - -1. What version of Go are you using (`go version`)? -2. What operating system and processor architecture are you using? -3. What did you do? -4. What did you expect to see? -5. What did you see instead? - -General questions should go to the [golang-nuts mailing list](https://groups.google.com/group/golang-nuts) instead of the issue tracker. -The gophers there will answer or ask you to file an issue if you've tripped over a bug. - -## Contributing code - -Please read the [Contribution Guidelines](https://golang.org/doc/contribute.html) -before sending patches. - -**We do not accept GitHub pull requests** -(we use [Gerrit](https://code.google.com/p/gerrit/) instead for code review). - -Unless otherwise noted, the Go source files are distributed under -the BSD-style license found in the LICENSE file. - diff --git a/vendor/golang.org/x/oauth2/CONTRIBUTORS b/vendor/golang.org/x/oauth2/CONTRIBUTORS deleted file mode 100644 index 1c4577e968..0000000000 --- a/vendor/golang.org/x/oauth2/CONTRIBUTORS +++ /dev/null @@ -1,3 +0,0 @@ -# This source code was written by the Go contributors. -# The master list of contributors is in the main Go distribution, -# visible at http://tip.golang.org/CONTRIBUTORS. diff --git a/vendor/golang.org/x/oauth2/LICENSE b/vendor/golang.org/x/oauth2/LICENSE deleted file mode 100644 index d02f24fd52..0000000000 --- a/vendor/golang.org/x/oauth2/LICENSE +++ /dev/null @@ -1,27 +0,0 @@ -Copyright (c) 2009 The oauth2 Authors. All rights reserved. - -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above -copyright notice, this list of conditions and the following disclaimer -in the documentation and/or other materials provided with the -distribution. - * Neither the name of Google Inc. nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. - -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vendor/golang.org/x/oauth2/README.md b/vendor/golang.org/x/oauth2/README.md deleted file mode 100644 index 0d5141733f..0000000000 --- a/vendor/golang.org/x/oauth2/README.md +++ /dev/null @@ -1,64 +0,0 @@ -# OAuth2 for Go - -[![Build Status](https://travis-ci.org/golang/oauth2.svg?branch=master)](https://travis-ci.org/golang/oauth2) - -oauth2 package contains a client implementation for OAuth 2.0 spec. - -## Installation - -~~~~ -go get golang.org/x/oauth2 -~~~~ - -See godoc for further documentation and examples. - -* [godoc.org/golang.org/x/oauth2](http://godoc.org/golang.org/x/oauth2) -* [godoc.org/golang.org/x/oauth2/google](http://godoc.org/golang.org/x/oauth2/google) - - -## App Engine - -In change 96e89be (March 2015) we removed the `oauth2.Context2` type in favor -of the [`context.Context`](https://golang.org/x/net/context#Context) type from -the `golang.org/x/net/context` package - -This means its no longer possible to use the "Classic App Engine" -`appengine.Context` type with the `oauth2` package. (You're using -Classic App Engine if you import the package `"appengine"`.) - -To work around this, you may use the new `"google.golang.org/appengine"` -package. This package has almost the same API as the `"appengine"` package, -but it can be fetched with `go get` and used on "Managed VMs" and well as -Classic App Engine. - -See the [new `appengine` package's readme](https://github.com/golang/appengine#updating-a-go-app-engine-app) -for information on updating your app. - -If you don't want to update your entire app to use the new App Engine packages, -you may use both sets of packages in parallel, using only the new packages -with the `oauth2` package. - - import ( - "golang.org/x/net/context" - "golang.org/x/oauth2" - "golang.org/x/oauth2/google" - newappengine "google.golang.org/appengine" - newurlfetch "google.golang.org/appengine/urlfetch" - - "appengine" - ) - - func handler(w http.ResponseWriter, r *http.Request) { - var c appengine.Context = appengine.NewContext(r) - c.Infof("Logging a message with the old package") - - var ctx context.Context = newappengine.NewContext(r) - client := &http.Client{ - Transport: &oauth2.Transport{ - Source: google.AppEngineTokenSource(ctx, "scope"), - Base: &newurlfetch.Transport{Context: ctx}, - }, - } - client.Get("...") - } - diff --git a/vendor/golang.org/x/oauth2/client_appengine.go b/vendor/golang.org/x/oauth2/client_appengine.go deleted file mode 100644 index 4a554cb9bf..0000000000 --- a/vendor/golang.org/x/oauth2/client_appengine.go +++ /dev/null @@ -1,25 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build appengine appenginevm - -// App Engine hooks. - -package oauth2 - -import ( - "net/http" - - "golang.org/x/net/context" - "golang.org/x/oauth2/internal" - "google.golang.org/appengine/urlfetch" -) - -func init() { - internal.RegisterContextClientFunc(contextClientAppEngine) -} - -func contextClientAppEngine(ctx context.Context) (*http.Client, error) { - return urlfetch.Client(ctx), nil -} diff --git a/vendor/golang.org/x/oauth2/google/appengine.go b/vendor/golang.org/x/oauth2/google/appengine.go deleted file mode 100644 index 65dc347314..0000000000 --- a/vendor/golang.org/x/oauth2/google/appengine.go +++ /dev/null @@ -1,83 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package google - -import ( - "sort" - "strings" - "sync" - "time" - - "golang.org/x/net/context" - "golang.org/x/oauth2" -) - -// Set at init time by appengine_hook.go. If nil, we're not on App Engine. -var appengineTokenFunc func(c context.Context, scopes ...string) (token string, expiry time.Time, err error) - -// AppEngineTokenSource returns a token source that fetches tokens -// issued to the current App Engine application's service account. -// If you are implementing a 3-legged OAuth 2.0 flow on App Engine -// that involves user accounts, see oauth2.Config instead. -// -// The provided context must have come from appengine.NewContext. -func AppEngineTokenSource(ctx context.Context, scope ...string) oauth2.TokenSource { - if appengineTokenFunc == nil { - panic("google: AppEngineTokenSource can only be used on App Engine.") - } - scopes := append([]string{}, scope...) - sort.Strings(scopes) - return &appEngineTokenSource{ - ctx: ctx, - scopes: scopes, - key: strings.Join(scopes, " "), - } -} - -// aeTokens helps the fetched tokens to be reused until their expiration. -var ( - aeTokensMu sync.Mutex - aeTokens = make(map[string]*tokenLock) // key is space-separated scopes -) - -type tokenLock struct { - mu sync.Mutex // guards t; held while fetching or updating t - t *oauth2.Token -} - -type appEngineTokenSource struct { - ctx context.Context - scopes []string - key string // to aeTokens map; space-separated scopes -} - -func (ts *appEngineTokenSource) Token() (*oauth2.Token, error) { - if appengineTokenFunc == nil { - panic("google: AppEngineTokenSource can only be used on App Engine.") - } - - aeTokensMu.Lock() - tok, ok := aeTokens[ts.key] - if !ok { - tok = &tokenLock{} - aeTokens[ts.key] = tok - } - aeTokensMu.Unlock() - - tok.mu.Lock() - defer tok.mu.Unlock() - if tok.t.Valid() { - return tok.t, nil - } - access, exp, err := appengineTokenFunc(ts.ctx, ts.scopes...) - if err != nil { - return nil, err - } - tok.t = &oauth2.Token{ - AccessToken: access, - Expiry: exp, - } - return tok.t, nil -} diff --git a/vendor/golang.org/x/oauth2/google/appengine_hook.go b/vendor/golang.org/x/oauth2/google/appengine_hook.go deleted file mode 100644 index 2f9b15432f..0000000000 --- a/vendor/golang.org/x/oauth2/google/appengine_hook.go +++ /dev/null @@ -1,13 +0,0 @@ -// Copyright 2015 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// +build appengine appenginevm - -package google - -import "google.golang.org/appengine" - -func init() { - appengineTokenFunc = appengine.AccessToken -} diff --git a/vendor/golang.org/x/oauth2/google/default.go b/vendor/golang.org/x/oauth2/google/default.go deleted file mode 100644 index 78f8089853..0000000000 --- a/vendor/golang.org/x/oauth2/google/default.go +++ /dev/null @@ -1,154 +0,0 @@ -// Copyright 2015 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package google - -import ( - "encoding/json" - "errors" - "fmt" - "io/ioutil" - "net/http" - "os" - "path/filepath" - "runtime" - - "golang.org/x/net/context" - "golang.org/x/oauth2" - "golang.org/x/oauth2/jwt" - "google.golang.org/cloud/compute/metadata" -) - -// DefaultClient returns an HTTP Client that uses the -// DefaultTokenSource to obtain authentication credentials. -// -// This client should be used when developing services -// that run on Google App Engine or Google Compute Engine -// and use "Application Default Credentials." -// -// For more details, see: -// https://developers.google.com/accounts/docs/application-default-credentials -// -func DefaultClient(ctx context.Context, scope ...string) (*http.Client, error) { - ts, err := DefaultTokenSource(ctx, scope...) - if err != nil { - return nil, err - } - return oauth2.NewClient(ctx, ts), nil -} - -// DefaultTokenSource is a token source that uses -// "Application Default Credentials". -// -// It looks for credentials in the following places, -// preferring the first location found: -// -// 1. A JSON file whose path is specified by the -// GOOGLE_APPLICATION_CREDENTIALS environment variable. -// 2. A JSON file in a location known to the gcloud command-line tool. -// On Windows, this is %APPDATA%/gcloud/application_default_credentials.json. -// On other systems, $HOME/.config/gcloud/application_default_credentials.json. -// 3. On Google App Engine it uses the appengine.AccessToken function. -// 4. On Google Compute Engine, it fetches credentials from the metadata server. -// (In this final case any provided scopes are ignored.) -// -// For more details, see: -// https://developers.google.com/accounts/docs/application-default-credentials -// -func DefaultTokenSource(ctx context.Context, scope ...string) (oauth2.TokenSource, error) { - // First, try the environment variable. - const envVar = "GOOGLE_APPLICATION_CREDENTIALS" - if filename := os.Getenv(envVar); filename != "" { - ts, err := tokenSourceFromFile(ctx, filename, scope) - if err != nil { - return nil, fmt.Errorf("google: error getting credentials using %v environment variable: %v", envVar, err) - } - return ts, nil - } - - // Second, try a well-known file. - filename := wellKnownFile() - _, err := os.Stat(filename) - if err == nil { - ts, err2 := tokenSourceFromFile(ctx, filename, scope) - if err2 == nil { - return ts, nil - } - err = err2 - } else if os.IsNotExist(err) { - err = nil // ignore this error - } - if err != nil { - return nil, fmt.Errorf("google: error getting credentials using well-known file (%v): %v", filename, err) - } - - // Third, if we're on Google App Engine use those credentials. - if appengineTokenFunc != nil { - return AppEngineTokenSource(ctx, scope...), nil - } - - // Fourth, if we're on Google Compute Engine use the metadata server. - if metadata.OnGCE() { - return ComputeTokenSource(""), nil - } - - // None are found; return helpful error. - const url = "https://developers.google.com/accounts/docs/application-default-credentials" - return nil, fmt.Errorf("google: could not find default credentials. See %v for more information.", url) -} - -func wellKnownFile() string { - const f = "application_default_credentials.json" - if runtime.GOOS == "windows" { - return filepath.Join(os.Getenv("APPDATA"), "gcloud", f) - } - return filepath.Join(guessUnixHomeDir(), ".config", "gcloud", f) -} - -func tokenSourceFromFile(ctx context.Context, filename string, scopes []string) (oauth2.TokenSource, error) { - b, err := ioutil.ReadFile(filename) - if err != nil { - return nil, err - } - var d struct { - // Common fields - Type string - ClientID string `json:"client_id"` - - // User Credential fields - ClientSecret string `json:"client_secret"` - RefreshToken string `json:"refresh_token"` - - // Service Account fields - ClientEmail string `json:"client_email"` - PrivateKeyID string `json:"private_key_id"` - PrivateKey string `json:"private_key"` - } - if err := json.Unmarshal(b, &d); err != nil { - return nil, err - } - switch d.Type { - case "authorized_user": - cfg := &oauth2.Config{ - ClientID: d.ClientID, - ClientSecret: d.ClientSecret, - Scopes: append([]string{}, scopes...), // copy - Endpoint: Endpoint, - } - tok := &oauth2.Token{RefreshToken: d.RefreshToken} - return cfg.TokenSource(ctx, tok), nil - case "service_account": - cfg := &jwt.Config{ - Email: d.ClientEmail, - PrivateKey: []byte(d.PrivateKey), - Scopes: append([]string{}, scopes...), // copy - TokenURL: JWTTokenURL, - } - return cfg.TokenSource(ctx), nil - case "": - return nil, errors.New("missing 'type' field in credentials") - default: - return nil, fmt.Errorf("unknown credential type: %q", d.Type) - } -} diff --git a/vendor/golang.org/x/oauth2/google/google.go b/vendor/golang.org/x/oauth2/google/google.go deleted file mode 100644 index 2077d9866f..0000000000 --- a/vendor/golang.org/x/oauth2/google/google.go +++ /dev/null @@ -1,145 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package google provides support for making OAuth2 authorized and -// authenticated HTTP requests to Google APIs. -// It supports the Web server flow, client-side credentials, service accounts, -// Google Compute Engine service accounts, and Google App Engine service -// accounts. -// -// For more information, please read -// https://developers.google.com/accounts/docs/OAuth2 -// and -// https://developers.google.com/accounts/docs/application-default-credentials. -package google - -import ( - "encoding/json" - "errors" - "fmt" - "strings" - "time" - - "golang.org/x/oauth2" - "golang.org/x/oauth2/jwt" - "google.golang.org/cloud/compute/metadata" -) - -// Endpoint is Google's OAuth 2.0 endpoint. -var Endpoint = oauth2.Endpoint{ - AuthURL: "https://accounts.google.com/o/oauth2/auth", - TokenURL: "https://accounts.google.com/o/oauth2/token", -} - -// JWTTokenURL is Google's OAuth 2.0 token URL to use with the JWT flow. -const JWTTokenURL = "https://accounts.google.com/o/oauth2/token" - -// ConfigFromJSON uses a Google Developers Console client_credentials.json -// file to construct a config. -// client_credentials.json can be downloadable from https://console.developers.google.com, -// under "APIs & Auth" > "Credentials". Download the Web application credentials in the -// JSON format and provide the contents of the file as jsonKey. -func ConfigFromJSON(jsonKey []byte, scope ...string) (*oauth2.Config, error) { - type cred struct { - ClientID string `json:"client_id"` - ClientSecret string `json:"client_secret"` - RedirectURIs []string `json:"redirect_uris"` - AuthURI string `json:"auth_uri"` - TokenURI string `json:"token_uri"` - } - var j struct { - Web *cred `json:"web"` - Installed *cred `json:"installed"` - } - if err := json.Unmarshal(jsonKey, &j); err != nil { - return nil, err - } - var c *cred - switch { - case j.Web != nil: - c = j.Web - case j.Installed != nil: - c = j.Installed - default: - return nil, fmt.Errorf("oauth2/google: no credentials found") - } - if len(c.RedirectURIs) < 1 { - return nil, errors.New("oauth2/google: missing redirect URL in the client_credentials.json") - } - return &oauth2.Config{ - ClientID: c.ClientID, - ClientSecret: c.ClientSecret, - RedirectURL: c.RedirectURIs[0], - Scopes: scope, - Endpoint: oauth2.Endpoint{ - AuthURL: c.AuthURI, - TokenURL: c.TokenURI, - }, - }, nil -} - -// JWTConfigFromJSON uses a Google Developers service account JSON key file to read -// the credentials that authorize and authenticate the requests. -// Create a service account on "Credentials" page under "APIs & Auth" for your -// project at https://console.developers.google.com to download a JSON key file. -func JWTConfigFromJSON(jsonKey []byte, scope ...string) (*jwt.Config, error) { - var key struct { - Email string `json:"client_email"` - PrivateKey string `json:"private_key"` - } - if err := json.Unmarshal(jsonKey, &key); err != nil { - return nil, err - } - return &jwt.Config{ - Email: key.Email, - PrivateKey: []byte(key.PrivateKey), - Scopes: scope, - TokenURL: JWTTokenURL, - }, nil -} - -// ComputeTokenSource returns a token source that fetches access tokens -// from Google Compute Engine (GCE)'s metadata server. It's only valid to use -// this token source if your program is running on a GCE instance. -// If no account is specified, "default" is used. -// Further information about retrieving access tokens from the GCE metadata -// server can be found at https://cloud.google.com/compute/docs/authentication. -func ComputeTokenSource(account string) oauth2.TokenSource { - return oauth2.ReuseTokenSource(nil, computeSource{account: account}) -} - -type computeSource struct { - account string -} - -func (cs computeSource) Token() (*oauth2.Token, error) { - if !metadata.OnGCE() { - return nil, errors.New("oauth2/google: can't get a token from the metadata service; not running on GCE") - } - acct := cs.account - if acct == "" { - acct = "default" - } - tokenJSON, err := metadata.Get("instance/service-accounts/" + acct + "/token") - if err != nil { - return nil, err - } - var res struct { - AccessToken string `json:"access_token"` - ExpiresInSec int `json:"expires_in"` - TokenType string `json:"token_type"` - } - err = json.NewDecoder(strings.NewReader(tokenJSON)).Decode(&res) - if err != nil { - return nil, fmt.Errorf("oauth2/google: invalid token JSON from metadata: %v", err) - } - if res.ExpiresInSec == 0 || res.AccessToken == "" { - return nil, fmt.Errorf("oauth2/google: incomplete token received from metadata") - } - return &oauth2.Token{ - AccessToken: res.AccessToken, - TokenType: res.TokenType, - Expiry: time.Now().Add(time.Duration(res.ExpiresInSec) * time.Second), - }, nil -} diff --git a/vendor/golang.org/x/oauth2/google/sdk.go b/vendor/golang.org/x/oauth2/google/sdk.go deleted file mode 100644 index 01ba0ecb00..0000000000 --- a/vendor/golang.org/x/oauth2/google/sdk.go +++ /dev/null @@ -1,168 +0,0 @@ -// Copyright 2015 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package google - -import ( - "encoding/json" - "errors" - "fmt" - "net/http" - "os" - "os/user" - "path/filepath" - "runtime" - "strings" - "time" - - "golang.org/x/net/context" - "golang.org/x/oauth2" - "golang.org/x/oauth2/internal" -) - -type sdkCredentials struct { - Data []struct { - Credential struct { - ClientID string `json:"client_id"` - ClientSecret string `json:"client_secret"` - AccessToken string `json:"access_token"` - RefreshToken string `json:"refresh_token"` - TokenExpiry *time.Time `json:"token_expiry"` - } `json:"credential"` - Key struct { - Account string `json:"account"` - Scope string `json:"scope"` - } `json:"key"` - } -} - -// An SDKConfig provides access to tokens from an account already -// authorized via the Google Cloud SDK. -type SDKConfig struct { - conf oauth2.Config - initialToken *oauth2.Token -} - -// NewSDKConfig creates an SDKConfig for the given Google Cloud SDK -// account. If account is empty, the account currently active in -// Google Cloud SDK properties is used. -// Google Cloud SDK credentials must be created by running `gcloud auth` -// before using this function. -// The Google Cloud SDK is available at https://cloud.google.com/sdk/. -func NewSDKConfig(account string) (*SDKConfig, error) { - configPath, err := sdkConfigPath() - if err != nil { - return nil, fmt.Errorf("oauth2/google: error getting SDK config path: %v", err) - } - credentialsPath := filepath.Join(configPath, "credentials") - f, err := os.Open(credentialsPath) - if err != nil { - return nil, fmt.Errorf("oauth2/google: failed to load SDK credentials: %v", err) - } - defer f.Close() - - var c sdkCredentials - if err := json.NewDecoder(f).Decode(&c); err != nil { - return nil, fmt.Errorf("oauth2/google: failed to decode SDK credentials from %q: %v", credentialsPath, err) - } - if len(c.Data) == 0 { - return nil, fmt.Errorf("oauth2/google: no credentials found in %q, run `gcloud auth login` to create one", credentialsPath) - } - if account == "" { - propertiesPath := filepath.Join(configPath, "properties") - f, err := os.Open(propertiesPath) - if err != nil { - return nil, fmt.Errorf("oauth2/google: failed to load SDK properties: %v", err) - } - defer f.Close() - ini, err := internal.ParseINI(f) - if err != nil { - return nil, fmt.Errorf("oauth2/google: failed to parse SDK properties %q: %v", propertiesPath, err) - } - core, ok := ini["core"] - if !ok { - return nil, fmt.Errorf("oauth2/google: failed to find [core] section in %v", ini) - } - active, ok := core["account"] - if !ok { - return nil, fmt.Errorf("oauth2/google: failed to find %q attribute in %v", "account", core) - } - account = active - } - - for _, d := range c.Data { - if account == "" || d.Key.Account == account { - if d.Credential.AccessToken == "" && d.Credential.RefreshToken == "" { - return nil, fmt.Errorf("oauth2/google: no token available for account %q", account) - } - var expiry time.Time - if d.Credential.TokenExpiry != nil { - expiry = *d.Credential.TokenExpiry - } - return &SDKConfig{ - conf: oauth2.Config{ - ClientID: d.Credential.ClientID, - ClientSecret: d.Credential.ClientSecret, - Scopes: strings.Split(d.Key.Scope, " "), - Endpoint: Endpoint, - RedirectURL: "oob", - }, - initialToken: &oauth2.Token{ - AccessToken: d.Credential.AccessToken, - RefreshToken: d.Credential.RefreshToken, - Expiry: expiry, - }, - }, nil - } - } - return nil, fmt.Errorf("oauth2/google: no such credentials for account %q", account) -} - -// Client returns an HTTP client using Google Cloud SDK credentials to -// authorize requests. The token will auto-refresh as necessary. The -// underlying http.RoundTripper will be obtained using the provided -// context. The returned client and its Transport should not be -// modified. -func (c *SDKConfig) Client(ctx context.Context) *http.Client { - return &http.Client{ - Transport: &oauth2.Transport{ - Source: c.TokenSource(ctx), - }, - } -} - -// TokenSource returns an oauth2.TokenSource that retrieve tokens from -// Google Cloud SDK credentials using the provided context. -// It will returns the current access token stored in the credentials, -// and refresh it when it expires, but it won't update the credentials -// with the new access token. -func (c *SDKConfig) TokenSource(ctx context.Context) oauth2.TokenSource { - return c.conf.TokenSource(ctx, c.initialToken) -} - -// Scopes are the OAuth 2.0 scopes the current account is authorized for. -func (c *SDKConfig) Scopes() []string { - return c.conf.Scopes -} - -// sdkConfigPath tries to guess where the gcloud config is located. -// It can be overridden during tests. -var sdkConfigPath = func() (string, error) { - if runtime.GOOS == "windows" { - return filepath.Join(os.Getenv("APPDATA"), "gcloud"), nil - } - homeDir := guessUnixHomeDir() - if homeDir == "" { - return "", errors.New("unable to get current user home directory: os/user lookup failed; $HOME is empty") - } - return filepath.Join(homeDir, ".config", "gcloud"), nil -} - -func guessUnixHomeDir() string { - usr, err := user.Current() - if err == nil { - return usr.HomeDir - } - return os.Getenv("HOME") -} diff --git a/vendor/golang.org/x/oauth2/internal/oauth2.go b/vendor/golang.org/x/oauth2/internal/oauth2.go deleted file mode 100644 index dc8ebfc4f7..0000000000 --- a/vendor/golang.org/x/oauth2/internal/oauth2.go +++ /dev/null @@ -1,76 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package internal contains support packages for oauth2 package. -package internal - -import ( - "bufio" - "crypto/rsa" - "crypto/x509" - "encoding/pem" - "errors" - "fmt" - "io" - "strings" -) - -// ParseKey converts the binary contents of a private key file -// to an *rsa.PrivateKey. It detects whether the private key is in a -// PEM container or not. If so, it extracts the the private key -// from PEM container before conversion. It only supports PEM -// containers with no passphrase. -func ParseKey(key []byte) (*rsa.PrivateKey, error) { - block, _ := pem.Decode(key) - if block != nil { - key = block.Bytes - } - parsedKey, err := x509.ParsePKCS8PrivateKey(key) - if err != nil { - parsedKey, err = x509.ParsePKCS1PrivateKey(key) - if err != nil { - return nil, fmt.Errorf("private key should be a PEM or plain PKSC1 or PKCS8; parse error: %v", err) - } - } - parsed, ok := parsedKey.(*rsa.PrivateKey) - if !ok { - return nil, errors.New("private key is invalid") - } - return parsed, nil -} - -func ParseINI(ini io.Reader) (map[string]map[string]string, error) { - result := map[string]map[string]string{ - "": map[string]string{}, // root section - } - scanner := bufio.NewScanner(ini) - currentSection := "" - for scanner.Scan() { - line := strings.TrimSpace(scanner.Text()) - if strings.HasPrefix(line, ";") { - // comment. - continue - } - if strings.HasPrefix(line, "[") && strings.HasSuffix(line, "]") { - currentSection = strings.TrimSpace(line[1 : len(line)-1]) - result[currentSection] = map[string]string{} - continue - } - parts := strings.SplitN(line, "=", 2) - if len(parts) == 2 && parts[0] != "" { - result[currentSection][strings.TrimSpace(parts[0])] = strings.TrimSpace(parts[1]) - } - } - if err := scanner.Err(); err != nil { - return nil, fmt.Errorf("error scanning ini: %v", err) - } - return result, nil -} - -func CondVal(v string) []string { - if v == "" { - return nil - } - return []string{v} -} diff --git a/vendor/golang.org/x/oauth2/internal/token.go b/vendor/golang.org/x/oauth2/internal/token.go deleted file mode 100644 index ea6716c98c..0000000000 --- a/vendor/golang.org/x/oauth2/internal/token.go +++ /dev/null @@ -1,213 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package internal contains support packages for oauth2 package. -package internal - -import ( - "encoding/json" - "fmt" - "io" - "io/ioutil" - "mime" - "net/http" - "net/url" - "strconv" - "strings" - "time" - - "golang.org/x/net/context" -) - -// Token represents the crendentials used to authorize -// the requests to access protected resources on the OAuth 2.0 -// provider's backend. -// -// This type is a mirror of oauth2.Token and exists to break -// an otherwise-circular dependency. Other internal packages -// should convert this Token into an oauth2.Token before use. -type Token struct { - // AccessToken is the token that authorizes and authenticates - // the requests. - AccessToken string - - // TokenType is the type of token. - // The Type method returns either this or "Bearer", the default. - TokenType string - - // RefreshToken is a token that's used by the application - // (as opposed to the user) to refresh the access token - // if it expires. - RefreshToken string - - // Expiry is the optional expiration time of the access token. - // - // If zero, TokenSource implementations will reuse the same - // token forever and RefreshToken or equivalent - // mechanisms for that TokenSource will not be used. - Expiry time.Time - - // Raw optionally contains extra metadata from the server - // when updating a token. - Raw interface{} -} - -// tokenJSON is the struct representing the HTTP response from OAuth2 -// providers returning a token in JSON form. -type tokenJSON struct { - AccessToken string `json:"access_token"` - TokenType string `json:"token_type"` - RefreshToken string `json:"refresh_token"` - ExpiresIn expirationTime `json:"expires_in"` // at least PayPal returns string, while most return number - Expires expirationTime `json:"expires"` // broken Facebook spelling of expires_in -} - -func (e *tokenJSON) expiry() (t time.Time) { - if v := e.ExpiresIn; v != 0 { - return time.Now().Add(time.Duration(v) * time.Second) - } - if v := e.Expires; v != 0 { - return time.Now().Add(time.Duration(v) * time.Second) - } - return -} - -type expirationTime int32 - -func (e *expirationTime) UnmarshalJSON(b []byte) error { - var n json.Number - err := json.Unmarshal(b, &n) - if err != nil { - return err - } - i, err := n.Int64() - if err != nil { - return err - } - *e = expirationTime(i) - return nil -} - -var brokenAuthHeaderProviders = []string{ - "https://accounts.google.com/", - "https://www.googleapis.com/", - "https://github.com/", - "https://api.instagram.com/", - "https://www.douban.com/", - "https://api.dropbox.com/", - "https://api.soundcloud.com/", - "https://www.linkedin.com/", - "https://api.twitch.tv/", - "https://oauth.vk.com/", - "https://api.odnoklassniki.ru/", - "https://connect.stripe.com/", - "https://api.pushbullet.com/", - "https://oauth.sandbox.trainingpeaks.com/", - "https://oauth.trainingpeaks.com/", - "https://www.strava.com/oauth/", - "https://app.box.com/", - "https://test-sandbox.auth.corp.google.com", - "https://user.gini.net/", -} - -// providerAuthHeaderWorks reports whether the OAuth2 server identified by the tokenURL -// implements the OAuth2 spec correctly -// See https://code.google.com/p/goauth2/issues/detail?id=31 for background. -// In summary: -// - Reddit only accepts client secret in the Authorization header -// - Dropbox accepts either it in URL param or Auth header, but not both. -// - Google only accepts URL param (not spec compliant?), not Auth header -// - Stripe only accepts client secret in Auth header with Bearer method, not Basic -func providerAuthHeaderWorks(tokenURL string) bool { - for _, s := range brokenAuthHeaderProviders { - if strings.HasPrefix(tokenURL, s) { - // Some sites fail to implement the OAuth2 spec fully. - return false - } - } - - // Assume the provider implements the spec properly - // otherwise. We can add more exceptions as they're - // discovered. We will _not_ be adding configurable hooks - // to this package to let users select server bugs. - return true -} - -func RetrieveToken(ctx context.Context, ClientID, ClientSecret, TokenURL string, v url.Values) (*Token, error) { - hc, err := ContextClient(ctx) - if err != nil { - return nil, err - } - v.Set("client_id", ClientID) - bustedAuth := !providerAuthHeaderWorks(TokenURL) - if bustedAuth && ClientSecret != "" { - v.Set("client_secret", ClientSecret) - } - req, err := http.NewRequest("POST", TokenURL, strings.NewReader(v.Encode())) - if err != nil { - return nil, err - } - req.Header.Set("Content-Type", "application/x-www-form-urlencoded") - if !bustedAuth { - req.SetBasicAuth(ClientID, ClientSecret) - } - r, err := hc.Do(req) - if err != nil { - return nil, err - } - defer r.Body.Close() - body, err := ioutil.ReadAll(io.LimitReader(r.Body, 1<<20)) - if err != nil { - return nil, fmt.Errorf("oauth2: cannot fetch token: %v", err) - } - if code := r.StatusCode; code < 200 || code > 299 { - return nil, fmt.Errorf("oauth2: cannot fetch token: %v\nResponse: %s", r.Status, body) - } - - var token *Token - content, _, _ := mime.ParseMediaType(r.Header.Get("Content-Type")) - switch content { - case "application/x-www-form-urlencoded", "text/plain": - vals, err := url.ParseQuery(string(body)) - if err != nil { - return nil, err - } - token = &Token{ - AccessToken: vals.Get("access_token"), - TokenType: vals.Get("token_type"), - RefreshToken: vals.Get("refresh_token"), - Raw: vals, - } - e := vals.Get("expires_in") - if e == "" { - // TODO(jbd): Facebook's OAuth2 implementation is broken and - // returns expires_in field in expires. Remove the fallback to expires, - // when Facebook fixes their implementation. - e = vals.Get("expires") - } - expires, _ := strconv.Atoi(e) - if expires != 0 { - token.Expiry = time.Now().Add(time.Duration(expires) * time.Second) - } - default: - var tj tokenJSON - if err = json.Unmarshal(body, &tj); err != nil { - return nil, err - } - token = &Token{ - AccessToken: tj.AccessToken, - TokenType: tj.TokenType, - RefreshToken: tj.RefreshToken, - Expiry: tj.expiry(), - Raw: make(map[string]interface{}), - } - json.Unmarshal(body, &token.Raw) // no error checks for optional fields - } - // Don't overwrite `RefreshToken` with an empty value - // if this was a token refreshing request. - if token.RefreshToken == "" { - token.RefreshToken = v.Get("refresh_token") - } - return token, nil -} diff --git a/vendor/golang.org/x/oauth2/internal/transport.go b/vendor/golang.org/x/oauth2/internal/transport.go deleted file mode 100644 index 521e7b49e7..0000000000 --- a/vendor/golang.org/x/oauth2/internal/transport.go +++ /dev/null @@ -1,67 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package internal contains support packages for oauth2 package. -package internal - -import ( - "net/http" - - "golang.org/x/net/context" -) - -// HTTPClient is the context key to use with golang.org/x/net/context's -// WithValue function to associate an *http.Client value with a context. -var HTTPClient ContextKey - -// ContextKey is just an empty struct. It exists so HTTPClient can be -// an immutable public variable with a unique type. It's immutable -// because nobody else can create a ContextKey, being unexported. -type ContextKey struct{} - -// ContextClientFunc is a func which tries to return an *http.Client -// given a Context value. If it returns an error, the search stops -// with that error. If it returns (nil, nil), the search continues -// down the list of registered funcs. -type ContextClientFunc func(context.Context) (*http.Client, error) - -var contextClientFuncs []ContextClientFunc - -func RegisterContextClientFunc(fn ContextClientFunc) { - contextClientFuncs = append(contextClientFuncs, fn) -} - -func ContextClient(ctx context.Context) (*http.Client, error) { - for _, fn := range contextClientFuncs { - c, err := fn(ctx) - if err != nil { - return nil, err - } - if c != nil { - return c, nil - } - } - if hc, ok := ctx.Value(HTTPClient).(*http.Client); ok { - return hc, nil - } - return http.DefaultClient, nil -} - -func ContextTransport(ctx context.Context) http.RoundTripper { - hc, err := ContextClient(ctx) - // This is a rare error case (somebody using nil on App Engine). - if err != nil { - return ErrorTransport{err} - } - return hc.Transport -} - -// ErrorTransport returns the specified error on RoundTrip. -// This RoundTripper should be used in rare error cases where -// error handling can be postponed to response handling time. -type ErrorTransport struct{ Err error } - -func (t ErrorTransport) RoundTrip(*http.Request) (*http.Response, error) { - return nil, t.Err -} diff --git a/vendor/golang.org/x/oauth2/jws/jws.go b/vendor/golang.org/x/oauth2/jws/jws.go deleted file mode 100644 index 396b3fac82..0000000000 --- a/vendor/golang.org/x/oauth2/jws/jws.go +++ /dev/null @@ -1,160 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package jws provides encoding and decoding utilities for -// signed JWS messages. -package jws - -import ( - "bytes" - "crypto" - "crypto/rand" - "crypto/rsa" - "crypto/sha256" - "encoding/base64" - "encoding/json" - "errors" - "fmt" - "strings" - "time" -) - -// ClaimSet contains information about the JWT signature including the -// permissions being requested (scopes), the target of the token, the issuer, -// the time the token was issued, and the lifetime of the token. -type ClaimSet struct { - Iss string `json:"iss"` // email address of the client_id of the application making the access token request - Scope string `json:"scope,omitempty"` // space-delimited list of the permissions the application requests - Aud string `json:"aud"` // descriptor of the intended target of the assertion (Optional). - Exp int64 `json:"exp"` // the expiration time of the assertion - Iat int64 `json:"iat"` // the time the assertion was issued. - Typ string `json:"typ,omitempty"` // token type (Optional). - - // Email for which the application is requesting delegated access (Optional). - Sub string `json:"sub,omitempty"` - - // The old name of Sub. Client keeps setting Prn to be - // complaint with legacy OAuth 2.0 providers. (Optional) - Prn string `json:"prn,omitempty"` - - // See http://tools.ietf.org/html/draft-jones-json-web-token-10#section-4.3 - // This array is marshalled using custom code (see (c *ClaimSet) encode()). - PrivateClaims map[string]interface{} `json:"-"` - - exp time.Time - iat time.Time -} - -func (c *ClaimSet) encode() (string, error) { - if c.exp.IsZero() || c.iat.IsZero() { - // Reverting time back for machines whose time is not perfectly in sync. - // If client machine's time is in the future according - // to Google servers, an access token will not be issued. - now := time.Now().Add(-10 * time.Second) - c.iat = now - c.exp = now.Add(time.Hour) - } - - c.Exp = c.exp.Unix() - c.Iat = c.iat.Unix() - - b, err := json.Marshal(c) - if err != nil { - return "", err - } - - if len(c.PrivateClaims) == 0 { - return base64Encode(b), nil - } - - // Marshal private claim set and then append it to b. - prv, err := json.Marshal(c.PrivateClaims) - if err != nil { - return "", fmt.Errorf("jws: invalid map of private claims %v", c.PrivateClaims) - } - - // Concatenate public and private claim JSON objects. - if !bytes.HasSuffix(b, []byte{'}'}) { - return "", fmt.Errorf("jws: invalid JSON %s", b) - } - if !bytes.HasPrefix(prv, []byte{'{'}) { - return "", fmt.Errorf("jws: invalid JSON %s", prv) - } - b[len(b)-1] = ',' // Replace closing curly brace with a comma. - b = append(b, prv[1:]...) // Append private claims. - return base64Encode(b), nil -} - -// Header represents the header for the signed JWS payloads. -type Header struct { - // The algorithm used for signature. - Algorithm string `json:"alg"` - - // Represents the token type. - Typ string `json:"typ"` -} - -func (h *Header) encode() (string, error) { - b, err := json.Marshal(h) - if err != nil { - return "", err - } - return base64Encode(b), nil -} - -// Decode decodes a claim set from a JWS payload. -func Decode(payload string) (*ClaimSet, error) { - // decode returned id token to get expiry - s := strings.Split(payload, ".") - if len(s) < 2 { - // TODO(jbd): Provide more context about the error. - return nil, errors.New("jws: invalid token received") - } - decoded, err := base64Decode(s[1]) - if err != nil { - return nil, err - } - c := &ClaimSet{} - err = json.NewDecoder(bytes.NewBuffer(decoded)).Decode(c) - return c, err -} - -// Encode encodes a signed JWS with provided header and claim set. -func Encode(header *Header, c *ClaimSet, signature *rsa.PrivateKey) (string, error) { - head, err := header.encode() - if err != nil { - return "", err - } - cs, err := c.encode() - if err != nil { - return "", err - } - ss := fmt.Sprintf("%s.%s", head, cs) - h := sha256.New() - h.Write([]byte(ss)) - b, err := rsa.SignPKCS1v15(rand.Reader, signature, crypto.SHA256, h.Sum(nil)) - if err != nil { - return "", err - } - sig := base64Encode(b) - return fmt.Sprintf("%s.%s", ss, sig), nil -} - -// base64Encode returns and Base64url encoded version of the input string with any -// trailing "=" stripped. -func base64Encode(b []byte) string { - return strings.TrimRight(base64.URLEncoding.EncodeToString(b), "=") -} - -// base64Decode decodes the Base64url encoded string -func base64Decode(s string) ([]byte, error) { - // add back missing padding - switch len(s) % 4 { - case 2: - s += "==" - case 3: - s += "=" - } - return base64.URLEncoding.DecodeString(s) -} diff --git a/vendor/golang.org/x/oauth2/jwt/jwt.go b/vendor/golang.org/x/oauth2/jwt/jwt.go deleted file mode 100644 index 205d23ed43..0000000000 --- a/vendor/golang.org/x/oauth2/jwt/jwt.go +++ /dev/null @@ -1,147 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package jwt implements the OAuth 2.0 JSON Web Token flow, commonly -// known as "two-legged OAuth 2.0". -// -// See: https://tools.ietf.org/html/draft-ietf-oauth-jwt-bearer-12 -package jwt - -import ( - "encoding/json" - "fmt" - "io" - "io/ioutil" - "net/http" - "net/url" - "strings" - "time" - - "golang.org/x/net/context" - "golang.org/x/oauth2" - "golang.org/x/oauth2/internal" - "golang.org/x/oauth2/jws" -) - -var ( - defaultGrantType = "urn:ietf:params:oauth:grant-type:jwt-bearer" - defaultHeader = &jws.Header{Algorithm: "RS256", Typ: "JWT"} -) - -// Config is the configuration for using JWT to fetch tokens, -// commonly known as "two-legged OAuth 2.0". -type Config struct { - // Email is the OAuth client identifier used when communicating with - // the configured OAuth provider. - Email string - - // PrivateKey contains the contents of an RSA private key or the - // contents of a PEM file that contains a private key. The provided - // private key is used to sign JWT payloads. - // PEM containers with a passphrase are not supported. - // Use the following command to convert a PKCS 12 file into a PEM. - // - // $ openssl pkcs12 -in key.p12 -out key.pem -nodes - // - PrivateKey []byte - - // Subject is the optional user to impersonate. - Subject string - - // Scopes optionally specifies a list of requested permission scopes. - Scopes []string - - // TokenURL is the endpoint required to complete the 2-legged JWT flow. - TokenURL string -} - -// TokenSource returns a JWT TokenSource using the configuration -// in c and the HTTP client from the provided context. -func (c *Config) TokenSource(ctx context.Context) oauth2.TokenSource { - return oauth2.ReuseTokenSource(nil, jwtSource{ctx, c}) -} - -// Client returns an HTTP client wrapping the context's -// HTTP transport and adding Authorization headers with tokens -// obtained from c. -// -// The returned client and its Transport should not be modified. -func (c *Config) Client(ctx context.Context) *http.Client { - return oauth2.NewClient(ctx, c.TokenSource(ctx)) -} - -// jwtSource is a source that always does a signed JWT request for a token. -// It should typically be wrapped with a reuseTokenSource. -type jwtSource struct { - ctx context.Context - conf *Config -} - -func (js jwtSource) Token() (*oauth2.Token, error) { - pk, err := internal.ParseKey(js.conf.PrivateKey) - if err != nil { - return nil, err - } - hc := oauth2.NewClient(js.ctx, nil) - claimSet := &jws.ClaimSet{ - Iss: js.conf.Email, - Scope: strings.Join(js.conf.Scopes, " "), - Aud: js.conf.TokenURL, - } - if subject := js.conf.Subject; subject != "" { - claimSet.Sub = subject - // prn is the old name of sub. Keep setting it - // to be compatible with legacy OAuth 2.0 providers. - claimSet.Prn = subject - } - payload, err := jws.Encode(defaultHeader, claimSet, pk) - if err != nil { - return nil, err - } - v := url.Values{} - v.Set("grant_type", defaultGrantType) - v.Set("assertion", payload) - resp, err := hc.PostForm(js.conf.TokenURL, v) - if err != nil { - return nil, fmt.Errorf("oauth2: cannot fetch token: %v", err) - } - defer resp.Body.Close() - body, err := ioutil.ReadAll(io.LimitReader(resp.Body, 1<<20)) - if err != nil { - return nil, fmt.Errorf("oauth2: cannot fetch token: %v", err) - } - if c := resp.StatusCode; c < 200 || c > 299 { - return nil, fmt.Errorf("oauth2: cannot fetch token: %v\nResponse: %s", resp.Status, body) - } - // tokenRes is the JSON response body. - var tokenRes struct { - AccessToken string `json:"access_token"` - TokenType string `json:"token_type"` - IDToken string `json:"id_token"` - ExpiresIn int64 `json:"expires_in"` // relative seconds from now - } - if err := json.Unmarshal(body, &tokenRes); err != nil { - return nil, fmt.Errorf("oauth2: cannot fetch token: %v", err) - } - token := &oauth2.Token{ - AccessToken: tokenRes.AccessToken, - TokenType: tokenRes.TokenType, - } - raw := make(map[string]interface{}) - json.Unmarshal(body, &raw) // no error checks for optional fields - token = token.WithExtra(raw) - - if secs := tokenRes.ExpiresIn; secs > 0 { - token.Expiry = time.Now().Add(time.Duration(secs) * time.Second) - } - if v := tokenRes.IDToken; v != "" { - // decode returned id token to get expiry - claimSet, err := jws.Decode(v) - if err != nil { - return nil, fmt.Errorf("oauth2: error decoding JWT token: %v", err) - } - token.Expiry = time.Unix(claimSet.Exp, 0) - } - return token, nil -} diff --git a/vendor/golang.org/x/oauth2/oauth2.go b/vendor/golang.org/x/oauth2/oauth2.go deleted file mode 100644 index dfcf238d23..0000000000 --- a/vendor/golang.org/x/oauth2/oauth2.go +++ /dev/null @@ -1,325 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -// Package oauth2 provides support for making -// OAuth2 authorized and authenticated HTTP requests. -// It can additionally grant authorization with Bearer JWT. -package oauth2 - -import ( - "bytes" - "errors" - "net/http" - "net/url" - "strings" - "sync" - - "golang.org/x/net/context" - "golang.org/x/oauth2/internal" -) - -// NoContext is the default context you should supply if not using -// your own context.Context (see https://golang.org/x/net/context). -var NoContext = context.TODO() - -// Config describes a typical 3-legged OAuth2 flow, with both the -// client application information and the server's endpoint URLs. -type Config struct { - // ClientID is the application's ID. - ClientID string - - // ClientSecret is the application's secret. - ClientSecret string - - // Endpoint contains the resource server's token endpoint - // URLs. These are constants specific to each server and are - // often available via site-specific packages, such as - // google.Endpoint or github.Endpoint. - Endpoint Endpoint - - // RedirectURL is the URL to redirect users going through - // the OAuth flow, after the resource owner's URLs. - RedirectURL string - - // Scope specifies optional requested permissions. - Scopes []string -} - -// A TokenSource is anything that can return a token. -type TokenSource interface { - // Token returns a token or an error. - // Token must be safe for concurrent use by multiple goroutines. - // The returned Token must not be modified. - Token() (*Token, error) -} - -// Endpoint contains the OAuth 2.0 provider's authorization and token -// endpoint URLs. -type Endpoint struct { - AuthURL string - TokenURL string -} - -var ( - // AccessTypeOnline and AccessTypeOffline are options passed - // to the Options.AuthCodeURL method. They modify the - // "access_type" field that gets sent in the URL returned by - // AuthCodeURL. - // - // Online is the default if neither is specified. If your - // application needs to refresh access tokens when the user - // is not present at the browser, then use offline. This will - // result in your application obtaining a refresh token the - // first time your application exchanges an authorization - // code for a user. - AccessTypeOnline AuthCodeOption = SetAuthURLParam("access_type", "online") - AccessTypeOffline AuthCodeOption = SetAuthURLParam("access_type", "offline") - - // ApprovalForce forces the users to view the consent dialog - // and confirm the permissions request at the URL returned - // from AuthCodeURL, even if they've already done so. - ApprovalForce AuthCodeOption = SetAuthURLParam("approval_prompt", "force") -) - -// An AuthCodeOption is passed to Config.AuthCodeURL. -type AuthCodeOption interface { - setValue(url.Values) -} - -type setParam struct{ k, v string } - -func (p setParam) setValue(m url.Values) { m.Set(p.k, p.v) } - -// SetAuthURLParam builds an AuthCodeOption which passes key/value parameters -// to a provider's authorization endpoint. -func SetAuthURLParam(key, value string) AuthCodeOption { - return setParam{key, value} -} - -// AuthCodeURL returns a URL to OAuth 2.0 provider's consent page -// that asks for permissions for the required scopes explicitly. -// -// State is a token to protect the user from CSRF attacks. You must -// always provide a non-zero string and validate that it matches the -// the state query parameter on your redirect callback. -// See http://tools.ietf.org/html/rfc6749#section-10.12 for more info. -// -// Opts may include AccessTypeOnline or AccessTypeOffline, as well -// as ApprovalForce. -func (c *Config) AuthCodeURL(state string, opts ...AuthCodeOption) string { - var buf bytes.Buffer - buf.WriteString(c.Endpoint.AuthURL) - v := url.Values{ - "response_type": {"code"}, - "client_id": {c.ClientID}, - "redirect_uri": internal.CondVal(c.RedirectURL), - "scope": internal.CondVal(strings.Join(c.Scopes, " ")), - "state": internal.CondVal(state), - } - for _, opt := range opts { - opt.setValue(v) - } - if strings.Contains(c.Endpoint.AuthURL, "?") { - buf.WriteByte('&') - } else { - buf.WriteByte('?') - } - buf.WriteString(v.Encode()) - return buf.String() -} - -// PasswordCredentialsToken converts a resource owner username and password -// pair into a token. -// -// Per the RFC, this grant type should only be used "when there is a high -// degree of trust between the resource owner and the client (e.g., the client -// is part of the device operating system or a highly privileged application), -// and when other authorization grant types are not available." -// See https://tools.ietf.org/html/rfc6749#section-4.3 for more info. -// -// The HTTP client to use is derived from the context. -// If nil, http.DefaultClient is used. -func (c *Config) PasswordCredentialsToken(ctx context.Context, username, password string) (*Token, error) { - return retrieveToken(ctx, c, url.Values{ - "grant_type": {"password"}, - "username": {username}, - "password": {password}, - "scope": internal.CondVal(strings.Join(c.Scopes, " ")), - }) -} - -// Exchange converts an authorization code into a token. -// -// It is used after a resource provider redirects the user back -// to the Redirect URI (the URL obtained from AuthCodeURL). -// -// The HTTP client to use is derived from the context. -// If a client is not provided via the context, http.DefaultClient is used. -// -// The code will be in the *http.Request.FormValue("code"). Before -// calling Exchange, be sure to validate FormValue("state"). -func (c *Config) Exchange(ctx context.Context, code string) (*Token, error) { - return retrieveToken(ctx, c, url.Values{ - "grant_type": {"authorization_code"}, - "code": {code}, - "redirect_uri": internal.CondVal(c.RedirectURL), - "scope": internal.CondVal(strings.Join(c.Scopes, " ")), - }) -} - -// Client returns an HTTP client using the provided token. -// The token will auto-refresh as necessary. The underlying -// HTTP transport will be obtained using the provided context. -// The returned client and its Transport should not be modified. -func (c *Config) Client(ctx context.Context, t *Token) *http.Client { - return NewClient(ctx, c.TokenSource(ctx, t)) -} - -// TokenSource returns a TokenSource that returns t until t expires, -// automatically refreshing it as necessary using the provided context. -// -// Most users will use Config.Client instead. -func (c *Config) TokenSource(ctx context.Context, t *Token) TokenSource { - tkr := &tokenRefresher{ - ctx: ctx, - conf: c, - } - if t != nil { - tkr.refreshToken = t.RefreshToken - } - return &reuseTokenSource{ - t: t, - new: tkr, - } -} - -// tokenRefresher is a TokenSource that makes "grant_type"=="refresh_token" -// HTTP requests to renew a token using a RefreshToken. -type tokenRefresher struct { - ctx context.Context // used to get HTTP requests - conf *Config - refreshToken string -} - -// WARNING: Token is not safe for concurrent access, as it -// updates the tokenRefresher's refreshToken field. -// Within this package, it is used by reuseTokenSource which -// synchronizes calls to this method with its own mutex. -func (tf *tokenRefresher) Token() (*Token, error) { - if tf.refreshToken == "" { - return nil, errors.New("oauth2: token expired and refresh token is not set") - } - - tk, err := retrieveToken(tf.ctx, tf.conf, url.Values{ - "grant_type": {"refresh_token"}, - "refresh_token": {tf.refreshToken}, - }) - - if err != nil { - return nil, err - } - if tf.refreshToken != tk.RefreshToken { - tf.refreshToken = tk.RefreshToken - } - return tk, err -} - -// reuseTokenSource is a TokenSource that holds a single token in memory -// and validates its expiry before each call to retrieve it with -// Token. If it's expired, it will be auto-refreshed using the -// new TokenSource. -type reuseTokenSource struct { - new TokenSource // called when t is expired. - - mu sync.Mutex // guards t - t *Token -} - -// Token returns the current token if it's still valid, else will -// refresh the current token (using r.Context for HTTP client -// information) and return the new one. -func (s *reuseTokenSource) Token() (*Token, error) { - s.mu.Lock() - defer s.mu.Unlock() - if s.t.Valid() { - return s.t, nil - } - t, err := s.new.Token() - if err != nil { - return nil, err - } - s.t = t - return t, nil -} - -// StaticTokenSource returns a TokenSource that always returns the same token. -// Because the provided token t is never refreshed, StaticTokenSource is only -// useful for tokens that never expire. -func StaticTokenSource(t *Token) TokenSource { - return staticTokenSource{t} -} - -// staticTokenSource is a TokenSource that always returns the same Token. -type staticTokenSource struct { - t *Token -} - -func (s staticTokenSource) Token() (*Token, error) { - return s.t, nil -} - -// HTTPClient is the context key to use with golang.org/x/net/context's -// WithValue function to associate an *http.Client value with a context. -var HTTPClient internal.ContextKey - -// NewClient creates an *http.Client from a Context and TokenSource. -// The returned client is not valid beyond the lifetime of the context. -// -// As a special case, if src is nil, a non-OAuth2 client is returned -// using the provided context. This exists to support related OAuth2 -// packages. -func NewClient(ctx context.Context, src TokenSource) *http.Client { - if src == nil { - c, err := internal.ContextClient(ctx) - if err != nil { - return &http.Client{Transport: internal.ErrorTransport{err}} - } - return c - } - return &http.Client{ - Transport: &Transport{ - Base: internal.ContextTransport(ctx), - Source: ReuseTokenSource(nil, src), - }, - } -} - -// ReuseTokenSource returns a TokenSource which repeatedly returns the -// same token as long as it's valid, starting with t. -// When its cached token is invalid, a new token is obtained from src. -// -// ReuseTokenSource is typically used to reuse tokens from a cache -// (such as a file on disk) between runs of a program, rather than -// obtaining new tokens unnecessarily. -// -// The initial token t may be nil, in which case the TokenSource is -// wrapped in a caching version if it isn't one already. This also -// means it's always safe to wrap ReuseTokenSource around any other -// TokenSource without adverse effects. -func ReuseTokenSource(t *Token, src TokenSource) TokenSource { - // Don't wrap a reuseTokenSource in itself. That would work, - // but cause an unnecessary number of mutex operations. - // Just build the equivalent one. - if rt, ok := src.(*reuseTokenSource); ok { - if t == nil { - // Just use it directly. - return rt - } - src = rt.new - } - return &reuseTokenSource{ - t: t, - new: src, - } -} diff --git a/vendor/golang.org/x/oauth2/token.go b/vendor/golang.org/x/oauth2/token.go deleted file mode 100644 index ebbdddbdce..0000000000 --- a/vendor/golang.org/x/oauth2/token.go +++ /dev/null @@ -1,143 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package oauth2 - -import ( - "net/http" - "net/url" - "strings" - "time" - - "golang.org/x/net/context" - "golang.org/x/oauth2/internal" -) - -// expiryDelta determines how earlier a token should be considered -// expired than its actual expiration time. It is used to avoid late -// expirations due to client-server time mismatches. -const expiryDelta = 10 * time.Second - -// Token represents the crendentials used to authorize -// the requests to access protected resources on the OAuth 2.0 -// provider's backend. -// -// Most users of this package should not access fields of Token -// directly. They're exported mostly for use by related packages -// implementing derivative OAuth2 flows. -type Token struct { - // AccessToken is the token that authorizes and authenticates - // the requests. - AccessToken string `json:"access_token"` - - // TokenType is the type of token. - // The Type method returns either this or "Bearer", the default. - TokenType string `json:"token_type,omitempty"` - - // RefreshToken is a token that's used by the application - // (as opposed to the user) to refresh the access token - // if it expires. - RefreshToken string `json:"refresh_token,omitempty"` - - // Expiry is the optional expiration time of the access token. - // - // If zero, TokenSource implementations will reuse the same - // token forever and RefreshToken or equivalent - // mechanisms for that TokenSource will not be used. - Expiry time.Time `json:"expiry,omitempty"` - - // raw optionally contains extra metadata from the server - // when updating a token. - raw interface{} -} - -// Type returns t.TokenType if non-empty, else "Bearer". -func (t *Token) Type() string { - if strings.EqualFold(t.TokenType, "bearer") { - return "Bearer" - } - if strings.EqualFold(t.TokenType, "mac") { - return "MAC" - } - if strings.EqualFold(t.TokenType, "basic") { - return "Basic" - } - if t.TokenType != "" { - return t.TokenType - } - return "Bearer" -} - -// SetAuthHeader sets the Authorization header to r using the access -// token in t. -// -// This method is unnecessary when using Transport or an HTTP Client -// returned by this package. -func (t *Token) SetAuthHeader(r *http.Request) { - r.Header.Set("Authorization", t.Type()+" "+t.AccessToken) -} - -// WithExtra returns a new Token that's a clone of t, but using the -// provided raw extra map. This is only intended for use by packages -// implementing derivative OAuth2 flows. -func (t *Token) WithExtra(extra interface{}) *Token { - t2 := new(Token) - *t2 = *t - t2.raw = extra - return t2 -} - -// Extra returns an extra field. -// Extra fields are key-value pairs returned by the server as a -// part of the token retrieval response. -func (t *Token) Extra(key string) interface{} { - if vals, ok := t.raw.(url.Values); ok { - // TODO(jbd): Cast numeric values to int64 or float64. - return vals.Get(key) - } - if raw, ok := t.raw.(map[string]interface{}); ok { - return raw[key] - } - return nil -} - -// expired reports whether the token is expired. -// t must be non-nil. -func (t *Token) expired() bool { - if t.Expiry.IsZero() { - return false - } - return t.Expiry.Add(-expiryDelta).Before(time.Now()) -} - -// Valid reports whether t is non-nil, has an AccessToken, and is not expired. -func (t *Token) Valid() bool { - return t != nil && t.AccessToken != "" && !t.expired() -} - -// tokenFromInternal maps an *internal.Token struct into -// a *Token struct. -func tokenFromInternal(t *internal.Token) *Token { - if t == nil { - return nil - } - return &Token{ - AccessToken: t.AccessToken, - TokenType: t.TokenType, - RefreshToken: t.RefreshToken, - Expiry: t.Expiry, - raw: t.Raw, - } -} - -// retrieveToken takes a *Config and uses that to retrieve an *internal.Token. -// This token is then mapped from *internal.Token into an *oauth2.Token which is returned along -// with an error.. -func retrieveToken(ctx context.Context, c *Config, v url.Values) (*Token, error) { - tk, err := internal.RetrieveToken(ctx, c.ClientID, c.ClientSecret, c.Endpoint.TokenURL, v) - if err != nil { - return nil, err - } - return tokenFromInternal(tk), nil -} diff --git a/vendor/golang.org/x/oauth2/transport.go b/vendor/golang.org/x/oauth2/transport.go deleted file mode 100644 index 90db088332..0000000000 --- a/vendor/golang.org/x/oauth2/transport.go +++ /dev/null @@ -1,132 +0,0 @@ -// Copyright 2014 The oauth2 Authors. All rights reserved. -// Use of this source code is governed by a BSD-style -// license that can be found in the LICENSE file. - -package oauth2 - -import ( - "errors" - "io" - "net/http" - "sync" -) - -// Transport is an http.RoundTripper that makes OAuth 2.0 HTTP requests, -// wrapping a base RoundTripper and adding an Authorization header -// with a token from the supplied Sources. -// -// Transport is a low-level mechanism. Most code will use the -// higher-level Config.Client method instead. -type Transport struct { - // Source supplies the token to add to outgoing requests' - // Authorization headers. - Source TokenSource - - // Base is the base RoundTripper used to make HTTP requests. - // If nil, http.DefaultTransport is used. - Base http.RoundTripper - - mu sync.Mutex // guards modReq - modReq map[*http.Request]*http.Request // original -> modified -} - -// RoundTrip authorizes and authenticates the request with an -// access token. If no token exists or token is expired, -// tries to refresh/fetch a new token. -func (t *Transport) RoundTrip(req *http.Request) (*http.Response, error) { - if t.Source == nil { - return nil, errors.New("oauth2: Transport's Source is nil") - } - token, err := t.Source.Token() - if err != nil { - return nil, err - } - - req2 := cloneRequest(req) // per RoundTripper contract - token.SetAuthHeader(req2) - t.setModReq(req, req2) - res, err := t.base().RoundTrip(req2) - if err != nil { - t.setModReq(req, nil) - return nil, err - } - res.Body = &onEOFReader{ - rc: res.Body, - fn: func() { t.setModReq(req, nil) }, - } - return res, nil -} - -// CancelRequest cancels an in-flight request by closing its connection. -func (t *Transport) CancelRequest(req *http.Request) { - type canceler interface { - CancelRequest(*http.Request) - } - if cr, ok := t.base().(canceler); ok { - t.mu.Lock() - modReq := t.modReq[req] - delete(t.modReq, req) - t.mu.Unlock() - cr.CancelRequest(modReq) - } -} - -func (t *Transport) base() http.RoundTripper { - if t.Base != nil { - return t.Base - } - return http.DefaultTransport -} - -func (t *Transport) setModReq(orig, mod *http.Request) { - t.mu.Lock() - defer t.mu.Unlock() - if t.modReq == nil { - t.modReq = make(map[*http.Request]*http.Request) - } - if mod == nil { - delete(t.modReq, orig) - } else { - t.modReq[orig] = mod - } -} - -// cloneRequest returns a clone of the provided *http.Request. -// The clone is a shallow copy of the struct and its Header map. -func cloneRequest(r *http.Request) *http.Request { - // shallow copy of the struct - r2 := new(http.Request) - *r2 = *r - // deep copy of the Header - r2.Header = make(http.Header, len(r.Header)) - for k, s := range r.Header { - r2.Header[k] = append([]string(nil), s...) - } - return r2 -} - -type onEOFReader struct { - rc io.ReadCloser - fn func() -} - -func (r *onEOFReader) Read(p []byte) (n int, err error) { - n, err = r.rc.Read(p) - if err == io.EOF { - r.runFunc() - } - return -} - -func (r *onEOFReader) Close() error { - err := r.rc.Close() - r.runFunc() - return err -} - -func (r *onEOFReader) runFunc() { - if fn := r.fn; fn != nil { - fn() - r.fn = nil - } -} diff --git a/vendor/google.golang.org/cloud/compute/metadata/metadata.go b/vendor/google.golang.org/cloud/compute/metadata/metadata.go deleted file mode 100644 index 0a709598df..0000000000 --- a/vendor/google.golang.org/cloud/compute/metadata/metadata.go +++ /dev/null @@ -1,382 +0,0 @@ -// Copyright 2014 Google Inc. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package metadata provides access to Google Compute Engine (GCE) -// metadata and API service accounts. -// -// This package is a wrapper around the GCE metadata service, -// as documented at https://developers.google.com/compute/docs/metadata. -package metadata - -import ( - "encoding/json" - "fmt" - "io/ioutil" - "net" - "net/http" - "net/url" - "os" - "strings" - "sync" - "time" - - "golang.org/x/net/context" - "golang.org/x/net/context/ctxhttp" - - "google.golang.org/cloud/internal" -) - -// metadataIP is the documented metadata server IP address. -const metadataIP = "169.254.169.254" - -type cachedValue struct { - k string - trim bool - mu sync.Mutex - v string -} - -var ( - projID = &cachedValue{k: "project/project-id", trim: true} - projNum = &cachedValue{k: "project/numeric-project-id", trim: true} - instID = &cachedValue{k: "instance/id", trim: true} -) - -var ( - metaClient = &http.Client{ - Transport: &internal.Transport{ - Base: &http.Transport{ - Dial: (&net.Dialer{ - Timeout: 2 * time.Second, - KeepAlive: 30 * time.Second, - }).Dial, - ResponseHeaderTimeout: 2 * time.Second, - }, - }, - } - subscribeClient = &http.Client{ - Transport: &internal.Transport{ - Base: &http.Transport{ - Dial: (&net.Dialer{ - Timeout: 2 * time.Second, - KeepAlive: 30 * time.Second, - }).Dial, - }, - }, - } -) - -// NotDefinedError is returned when requested metadata is not defined. -// -// The underlying string is the suffix after "/computeMetadata/v1/". -// -// This error is not returned if the value is defined to be the empty -// string. -type NotDefinedError string - -func (suffix NotDefinedError) Error() string { - return fmt.Sprintf("metadata: GCE metadata %q not defined", string(suffix)) -} - -// Get returns a value from the metadata service. -// The suffix is appended to "http://${GCE_METADATA_HOST}/computeMetadata/v1/". -// -// If the GCE_METADATA_HOST environment variable is not defined, a default of -// 169.254.169.254 will be used instead. -// -// If the requested metadata is not defined, the returned error will -// be of type NotDefinedError. -func Get(suffix string) (string, error) { - val, _, err := getETag(metaClient, suffix) - return val, err -} - -// getETag returns a value from the metadata service as well as the associated -// ETag using the provided client. This func is otherwise equivalent to Get. -func getETag(client *http.Client, suffix string) (value, etag string, err error) { - // Using a fixed IP makes it very difficult to spoof the metadata service in - // a container, which is an important use-case for local testing of cloud - // deployments. To enable spoofing of the metadata service, the environment - // variable GCE_METADATA_HOST is first inspected to decide where metadata - // requests shall go. - host := os.Getenv("GCE_METADATA_HOST") - if host == "" { - // Using 169.254.169.254 instead of "metadata" here because Go - // binaries built with the "netgo" tag and without cgo won't - // know the search suffix for "metadata" is - // ".google.internal", and this IP address is documented as - // being stable anyway. - host = metadataIP - } - url := "http://" + host + "/computeMetadata/v1/" + suffix - req, _ := http.NewRequest("GET", url, nil) - req.Header.Set("Metadata-Flavor", "Google") - res, err := client.Do(req) - if err != nil { - return "", "", err - } - defer res.Body.Close() - if res.StatusCode == http.StatusNotFound { - return "", "", NotDefinedError(suffix) - } - if res.StatusCode != 200 { - return "", "", fmt.Errorf("status code %d trying to fetch %s", res.StatusCode, url) - } - all, err := ioutil.ReadAll(res.Body) - if err != nil { - return "", "", err - } - return string(all), res.Header.Get("Etag"), nil -} - -func getTrimmed(suffix string) (s string, err error) { - s, err = Get(suffix) - s = strings.TrimSpace(s) - return -} - -func (c *cachedValue) get() (v string, err error) { - defer c.mu.Unlock() - c.mu.Lock() - if c.v != "" { - return c.v, nil - } - if c.trim { - v, err = getTrimmed(c.k) - } else { - v, err = Get(c.k) - } - if err == nil { - c.v = v - } - return -} - -var onGCE struct { - sync.Mutex - set bool - v bool -} - -// OnGCE reports whether this process is running on Google Compute Engine. -func OnGCE() bool { - defer onGCE.Unlock() - onGCE.Lock() - if onGCE.set { - return onGCE.v - } - onGCE.set = true - onGCE.v = testOnGCE() - return onGCE.v -} - -func testOnGCE() bool { - ctx, cancel := context.WithCancel(context.Background()) - defer cancel() - - resc := make(chan bool, 2) - - // Try two strategies in parallel. - // See https://github.com/GoogleCloudPlatform/gcloud-golang/issues/194 - go func() { - res, err := ctxhttp.Get(ctx, metaClient, "http://"+metadataIP) - if err != nil { - resc <- false - return - } - defer res.Body.Close() - resc <- res.Header.Get("Metadata-Flavor") == "Google" - }() - - go func() { - addrs, err := net.LookupHost("metadata.google.internal") - if err != nil || len(addrs) == 0 { - resc <- false - return - } - resc <- strsContains(addrs, metadataIP) - }() - - return <-resc -} - -// Subscribe subscribes to a value from the metadata service. -// The suffix is appended to "http://${GCE_METADATA_HOST}/computeMetadata/v1/". -// The suffix may contain query parameters. -// -// Subscribe calls fn with the latest metadata value indicated by the provided -// suffix. If the metadata value is deleted, fn is called with the empty string -// and ok false. Subscribe blocks until fn returns a non-nil error or the value -// is deleted. Subscribe returns the error value returned from the last call to -// fn, which may be nil when ok == false. -func Subscribe(suffix string, fn func(v string, ok bool) error) error { - const failedSubscribeSleep = time.Second * 5 - - // First check to see if the metadata value exists at all. - val, lastETag, err := getETag(subscribeClient, suffix) - if err != nil { - return err - } - - if err := fn(val, true); err != nil { - return err - } - - ok := true - if strings.ContainsRune(suffix, '?') { - suffix += "&wait_for_change=true&last_etag=" - } else { - suffix += "?wait_for_change=true&last_etag=" - } - for { - val, etag, err := getETag(subscribeClient, suffix+url.QueryEscape(lastETag)) - if err != nil { - if _, deleted := err.(NotDefinedError); !deleted { - time.Sleep(failedSubscribeSleep) - continue // Retry on other errors. - } - ok = false - } - lastETag = etag - - if err := fn(val, ok); err != nil || !ok { - return err - } - } -} - -// ProjectID returns the current instance's project ID string. -func ProjectID() (string, error) { return projID.get() } - -// NumericProjectID returns the current instance's numeric project ID. -func NumericProjectID() (string, error) { return projNum.get() } - -// InternalIP returns the instance's primary internal IP address. -func InternalIP() (string, error) { - return getTrimmed("instance/network-interfaces/0/ip") -} - -// ExternalIP returns the instance's primary external (public) IP address. -func ExternalIP() (string, error) { - return getTrimmed("instance/network-interfaces/0/access-configs/0/external-ip") -} - -// Hostname returns the instance's hostname. This will be of the form -// ".c..internal". -func Hostname() (string, error) { - return getTrimmed("instance/hostname") -} - -// InstanceTags returns the list of user-defined instance tags, -// assigned when initially creating a GCE instance. -func InstanceTags() ([]string, error) { - var s []string - j, err := Get("instance/tags") - if err != nil { - return nil, err - } - if err := json.NewDecoder(strings.NewReader(j)).Decode(&s); err != nil { - return nil, err - } - return s, nil -} - -// InstanceID returns the current VM's numeric instance ID. -func InstanceID() (string, error) { - return instID.get() -} - -// InstanceName returns the current VM's instance ID string. -func InstanceName() (string, error) { - host, err := Hostname() - if err != nil { - return "", err - } - return strings.Split(host, ".")[0], nil -} - -// Zone returns the current VM's zone, such as "us-central1-b". -func Zone() (string, error) { - zone, err := getTrimmed("instance/zone") - // zone is of the form "projects//zones/". - if err != nil { - return "", err - } - return zone[strings.LastIndex(zone, "/")+1:], nil -} - -// InstanceAttributes returns the list of user-defined attributes, -// assigned when initially creating a GCE VM instance. The value of an -// attribute can be obtained with InstanceAttributeValue. -func InstanceAttributes() ([]string, error) { return lines("instance/attributes/") } - -// ProjectAttributes returns the list of user-defined attributes -// applying to the project as a whole, not just this VM. The value of -// an attribute can be obtained with ProjectAttributeValue. -func ProjectAttributes() ([]string, error) { return lines("project/attributes/") } - -func lines(suffix string) ([]string, error) { - j, err := Get(suffix) - if err != nil { - return nil, err - } - s := strings.Split(strings.TrimSpace(j), "\n") - for i := range s { - s[i] = strings.TrimSpace(s[i]) - } - return s, nil -} - -// InstanceAttributeValue returns the value of the provided VM -// instance attribute. -// -// If the requested attribute is not defined, the returned error will -// be of type NotDefinedError. -// -// InstanceAttributeValue may return ("", nil) if the attribute was -// defined to be the empty string. -func InstanceAttributeValue(attr string) (string, error) { - return Get("instance/attributes/" + attr) -} - -// ProjectAttributeValue returns the value of the provided -// project attribute. -// -// If the requested attribute is not defined, the returned error will -// be of type NotDefinedError. -// -// ProjectAttributeValue may return ("", nil) if the attribute was -// defined to be the empty string. -func ProjectAttributeValue(attr string) (string, error) { - return Get("project/attributes/" + attr) -} - -// Scopes returns the service account scopes for the given account. -// The account may be empty or the string "default" to use the instance's -// main account. -func Scopes(serviceAccount string) ([]string, error) { - if serviceAccount == "" { - serviceAccount = "default" - } - return lines("instance/service-accounts/" + serviceAccount + "/scopes") -} - -func strsContains(ss []string, s string) bool { - for _, v := range ss { - if v == s { - return true - } - } - return false -} diff --git a/vendor/google.golang.org/cloud/internal/cloud.go b/vendor/google.golang.org/cloud/internal/cloud.go deleted file mode 100644 index 59428803dd..0000000000 --- a/vendor/google.golang.org/cloud/internal/cloud.go +++ /dev/null @@ -1,128 +0,0 @@ -// Copyright 2014 Google Inc. All Rights Reserved. -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -// Package internal provides support for the cloud packages. -// -// Users should not import this package directly. -package internal - -import ( - "fmt" - "net/http" - "sync" - - "golang.org/x/net/context" -) - -type contextKey struct{} - -func WithContext(parent context.Context, projID string, c *http.Client) context.Context { - if c == nil { - panic("nil *http.Client passed to WithContext") - } - if projID == "" { - panic("empty project ID passed to WithContext") - } - return context.WithValue(parent, contextKey{}, &cloudContext{ - ProjectID: projID, - HTTPClient: c, - }) -} - -const userAgent = "gcloud-golang/0.1" - -type cloudContext struct { - ProjectID string - HTTPClient *http.Client - - mu sync.Mutex // guards svc - svc map[string]interface{} // e.g. "storage" => *rawStorage.Service -} - -// Service returns the result of the fill function if it's never been -// called before for the given name (which is assumed to be an API -// service name, like "datastore"). If it has already been cached, the fill -// func is not run. -// It's safe for concurrent use by multiple goroutines. -func Service(ctx context.Context, name string, fill func(*http.Client) interface{}) interface{} { - return cc(ctx).service(name, fill) -} - -func (c *cloudContext) service(name string, fill func(*http.Client) interface{}) interface{} { - c.mu.Lock() - defer c.mu.Unlock() - - if c.svc == nil { - c.svc = make(map[string]interface{}) - } else if v, ok := c.svc[name]; ok { - return v - } - v := fill(c.HTTPClient) - c.svc[name] = v - return v -} - -// Transport is an http.RoundTripper that appends -// Google Cloud client's user-agent to the original -// request's user-agent header. -type Transport struct { - // Base is the actual http.RoundTripper - // requests will use. It must not be nil. - Base http.RoundTripper -} - -// RoundTrip appends a user-agent to the existing user-agent -// header and delegates the request to the base http.RoundTripper. -func (t *Transport) RoundTrip(req *http.Request) (*http.Response, error) { - req = cloneRequest(req) - ua := req.Header.Get("User-Agent") - if ua == "" { - ua = userAgent - } else { - ua = fmt.Sprintf("%s %s", ua, userAgent) - } - req.Header.Set("User-Agent", ua) - return t.Base.RoundTrip(req) -} - -// cloneRequest returns a clone of the provided *http.Request. -// The clone is a shallow copy of the struct and its Header map. -func cloneRequest(r *http.Request) *http.Request { - // shallow copy of the struct - r2 := new(http.Request) - *r2 = *r - // deep copy of the Header - r2.Header = make(http.Header) - for k, s := range r.Header { - r2.Header[k] = s - } - return r2 -} - -func ProjID(ctx context.Context) string { - return cc(ctx).ProjectID -} - -func HTTPClient(ctx context.Context) *http.Client { - return cc(ctx).HTTPClient -} - -// cc returns the internal *cloudContext (cc) state for a context.Context. -// It panics if the user did it wrong. -func cc(ctx context.Context) *cloudContext { - if c, ok := ctx.Value(contextKey{}).(*cloudContext); ok { - return c - } - panic("invalid context.Context type; it should be created with cloud.NewContext") -} diff --git a/vendor/github.com/coreos/pkg/LICENSE b/vendor/k8s.io/apimachinery/LICENSE similarity index 99% rename from vendor/github.com/coreos/pkg/LICENSE rename to vendor/k8s.io/apimachinery/LICENSE index e06d208186..d645695673 100644 --- a/vendor/github.com/coreos/pkg/LICENSE +++ b/vendor/k8s.io/apimachinery/LICENSE @@ -1,4 +1,5 @@ -Apache License + + Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ @@ -178,7 +179,7 @@ Apache License APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" + boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a @@ -186,7 +187,7 @@ Apache License same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright {yyyy} {name of copyright owner} + Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -199,4 +200,3 @@ Apache License 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. - diff --git a/vendor/k8s.io/apimachinery/pkg/api/equality/BUILD b/vendor/k8s.io/apimachinery/pkg/api/equality/BUILD new file mode 100644 index 0000000000..7a21f2db51 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/equality/BUILD @@ -0,0 +1,21 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["semantic.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + ], +) diff --git a/vendor/k8s.io/apimachinery/pkg/api/equality/semantic.go b/vendor/k8s.io/apimachinery/pkg/api/equality/semantic.go new file mode 100644 index 0000000000..3ebd8c719d --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/equality/semantic.go @@ -0,0 +1,46 @@ +/* +Copyright 2014 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package equality + +import ( + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" +) + +// Semantic can do semantic deep equality checks for api objects. +// Example: apiequality.Semantic.DeepEqual(aPod, aPodWithNonNilButEmptyMaps) == true +var Semantic = conversion.EqualitiesOrDie( + func(a, b resource.Quantity) bool { + // Ignore formatting, only care that numeric value stayed the same. + // TODO: if we decide it's important, it should be safe to start comparing the format. + // + // Uninitialized quantities are equivalent to 0 quantities. + return a.Cmp(b) == 0 + }, + func(a, b metav1.Time) bool { + return a.UTC() == b.UTC() + }, + func(a, b labels.Selector) bool { + return a.String() == b.String() + }, + func(a, b fields.Selector) bool { + return a.String() == b.String() + }, +) diff --git a/vendor/k8s.io/apimachinery/pkg/api/errors/BUILD b/vendor/k8s.io/apimachinery/pkg/api/errors/BUILD new file mode 100644 index 0000000000..50f9237a47 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/errors/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["errors_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "errors.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + ], +) diff --git a/vendor/k8s.io/apimachinery/pkg/api/errors/OWNERS b/vendor/k8s.io/apimachinery/pkg/api/errors/OWNERS new file mode 100755 index 0000000000..e664b2015b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/errors/OWNERS @@ -0,0 +1,26 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- brendandburns +- derekwaynecarr +- caesarxuchao +- mikedanese +- liggitt +- nikhiljindal +- gmarek +- erictune +- saad-ali +- janetkuo +- timstclair +- eparis +- timothysc +- dims +- hongchaodeng +- krousey +- satnam6502 +- cjcullen +- david-mcmahon +- goltermann diff --git a/vendor/k8s.io/client-go/pkg/api/errors/doc.go b/vendor/k8s.io/apimachinery/pkg/api/errors/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/api/errors/doc.go rename to vendor/k8s.io/apimachinery/pkg/api/errors/doc.go diff --git a/vendor/k8s.io/client-go/pkg/api/errors/errors.go b/vendor/k8s.io/apimachinery/pkg/api/errors/errors.go similarity index 68% rename from vendor/k8s.io/client-go/pkg/api/errors/errors.go rename to vendor/k8s.io/apimachinery/pkg/api/errors/errors.go index 93dd52a243..560c889b9c 100644 --- a/vendor/k8s.io/client-go/pkg/api/errors/errors.go +++ b/vendor/k8s.io/apimachinery/pkg/api/errors/errors.go @@ -22,9 +22,10 @@ import ( "net/http" "strings" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/validation/field" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/validation/field" ) // HTTP Status codes not in the golang http package. @@ -40,13 +41,13 @@ const ( // StatusError is an error intended for consumption by a REST API server; it can also be // reconstructed by clients from a REST response. Public to allow easy type switches. type StatusError struct { - ErrStatus unversioned.Status + ErrStatus metav1.Status } // APIStatus is exposed by errors that can be converted to an api.Status object // for finer grained details. type APIStatus interface { - Status() unversioned.Status + Status() metav1.Status } var _ error = &StatusError{} @@ -57,8 +58,8 @@ func (e *StatusError) Error() string { } // Status allows access to e's status without having to know the detailed workings -// of StatusError. Used by pkg/apiserver. -func (e *StatusError) Status() unversioned.Status { +// of StatusError. +func (e *StatusError) Status() metav1.Status { return e.ErrStatus } @@ -80,23 +81,23 @@ func (u *UnexpectedObjectError) Error() string { return fmt.Sprintf("unexpected object: %v", u.Object) } -// FromObject generates an StatusError from an unversioned.Status, if that is the type of obj; otherwise, +// FromObject generates an StatusError from an metav1.Status, if that is the type of obj; otherwise, // returns an UnexpecteObjectError. func FromObject(obj runtime.Object) error { switch t := obj.(type) { - case *unversioned.Status: + case *metav1.Status: return &StatusError{*t} } return &UnexpectedObjectError{obj} } // NewNotFound returns a new error which indicates that the resource of the kind and the name was not found. -func NewNotFound(qualifiedResource unversioned.GroupResource, name string) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, +func NewNotFound(qualifiedResource schema.GroupResource, name string) *StatusError { + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusNotFound, - Reason: unversioned.StatusReasonNotFound, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonNotFound, + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, Name: name, @@ -106,12 +107,12 @@ func NewNotFound(qualifiedResource unversioned.GroupResource, name string) *Stat } // NewAlreadyExists returns an error indicating the item requested exists by that identifier. -func NewAlreadyExists(qualifiedResource unversioned.GroupResource, name string) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, +func NewAlreadyExists(qualifiedResource schema.GroupResource, name string) *StatusError { + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusConflict, - Reason: unversioned.StatusReasonAlreadyExists, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonAlreadyExists, + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, Name: name, @@ -127,21 +128,21 @@ func NewUnauthorized(reason string) *StatusError { if len(message) == 0 { message = "not authorized" } - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusUnauthorized, - Reason: unversioned.StatusReasonUnauthorized, + Reason: metav1.StatusReasonUnauthorized, Message: message, }} } // NewForbidden returns an error indicating the requested action was forbidden -func NewForbidden(qualifiedResource unversioned.GroupResource, name string, err error) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, +func NewForbidden(qualifiedResource schema.GroupResource, name string, err error) *StatusError { + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusForbidden, - Reason: unversioned.StatusReasonForbidden, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonForbidden, + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, Name: name, @@ -151,12 +152,12 @@ func NewForbidden(qualifiedResource unversioned.GroupResource, name string, err } // NewConflict returns an error indicating the item can't be updated as provided. -func NewConflict(qualifiedResource unversioned.GroupResource, name string, err error) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, +func NewConflict(qualifiedResource schema.GroupResource, name string, err error) *StatusError { + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusConflict, - Reason: unversioned.StatusReasonConflict, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonConflict, + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, Name: name, @@ -167,30 +168,30 @@ func NewConflict(qualifiedResource unversioned.GroupResource, name string, err e // NewGone returns an error indicating the item no longer available at the server and no forwarding address is known. func NewGone(message string) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusGone, - Reason: unversioned.StatusReasonGone, + Reason: metav1.StatusReasonGone, Message: message, }} } // NewInvalid returns an error indicating the item is invalid and cannot be processed. -func NewInvalid(qualifiedKind unversioned.GroupKind, name string, errs field.ErrorList) *StatusError { - causes := make([]unversioned.StatusCause, 0, len(errs)) +func NewInvalid(qualifiedKind schema.GroupKind, name string, errs field.ErrorList) *StatusError { + causes := make([]metav1.StatusCause, 0, len(errs)) for i := range errs { err := errs[i] - causes = append(causes, unversioned.StatusCause{ - Type: unversioned.CauseType(err.Type), + causes = append(causes, metav1.StatusCause{ + Type: metav1.CauseType(err.Type), Message: err.ErrorBody(), Field: err.Field, }) } - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: StatusUnprocessableEntity, // RFC 4918: StatusUnprocessableEntity - Reason: unversioned.StatusReasonInvalid, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonInvalid, + Details: &metav1.StatusDetails{ Group: qualifiedKind.Group, Kind: qualifiedKind.Kind, Name: name, @@ -202,31 +203,31 @@ func NewInvalid(qualifiedKind unversioned.GroupKind, name string, errs field.Err // NewBadRequest creates an error that indicates that the request is invalid and can not be processed. func NewBadRequest(reason string) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusBadRequest, - Reason: unversioned.StatusReasonBadRequest, + Reason: metav1.StatusReasonBadRequest, Message: reason, }} } // NewServiceUnavailable creates an error that indicates that the requested service is unavailable. func NewServiceUnavailable(reason string) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusServiceUnavailable, - Reason: unversioned.StatusReasonServiceUnavailable, + Reason: metav1.StatusReasonServiceUnavailable, Message: reason, }} } // NewMethodNotSupported returns an error indicating the requested action is not supported on this kind. -func NewMethodNotSupported(qualifiedResource unversioned.GroupResource, action string) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, +func NewMethodNotSupported(qualifiedResource schema.GroupResource, action string) *StatusError { + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusMethodNotAllowed, - Reason: unversioned.StatusReasonMethodNotAllowed, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonMethodNotAllowed, + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, }, @@ -236,12 +237,12 @@ func NewMethodNotSupported(qualifiedResource unversioned.GroupResource, action s // NewServerTimeout returns an error indicating the requested action could not be completed due to a // transient error, and the client should try again. -func NewServerTimeout(qualifiedResource unversioned.GroupResource, operation string, retryAfterSeconds int) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, +func NewServerTimeout(qualifiedResource schema.GroupResource, operation string, retryAfterSeconds int) *StatusError { + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusInternalServerError, - Reason: unversioned.StatusReasonServerTimeout, - Details: &unversioned.StatusDetails{ + Reason: metav1.StatusReasonServerTimeout, + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, Name: operation, @@ -253,18 +254,18 @@ func NewServerTimeout(qualifiedResource unversioned.GroupResource, operation str // NewServerTimeoutForKind should not exist. Server timeouts happen when accessing resources, the Kind is just what we // happened to be looking at when the request failed. This delegates to keep code sane, but we should work towards removing this. -func NewServerTimeoutForKind(qualifiedKind unversioned.GroupKind, operation string, retryAfterSeconds int) *StatusError { - return NewServerTimeout(unversioned.GroupResource{Group: qualifiedKind.Group, Resource: qualifiedKind.Kind}, operation, retryAfterSeconds) +func NewServerTimeoutForKind(qualifiedKind schema.GroupKind, operation string, retryAfterSeconds int) *StatusError { + return NewServerTimeout(schema.GroupResource{Group: qualifiedKind.Group, Resource: qualifiedKind.Kind}, operation, retryAfterSeconds) } // NewInternalError returns an error indicating the item is invalid and cannot be processed. func NewInternalError(err error) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: http.StatusInternalServerError, - Reason: unversioned.StatusReasonInternalError, - Details: &unversioned.StatusDetails{ - Causes: []unversioned.StatusCause{{Message: err.Error()}}, + Reason: metav1.StatusReasonInternalError, + Details: &metav1.StatusDetails{ + Causes: []metav1.StatusCause{{Message: err.Error()}}, }, Message: fmt.Sprintf("Internal error occurred: %v", err), }} @@ -273,56 +274,57 @@ func NewInternalError(err error) *StatusError { // NewTimeoutError returns an error indicating that a timeout occurred before the request // could be completed. Clients may retry, but the operation may still complete. func NewTimeoutError(message string, retryAfterSeconds int) *StatusError { - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: StatusServerTimeout, - Reason: unversioned.StatusReasonTimeout, + Reason: metav1.StatusReasonTimeout, Message: fmt.Sprintf("Timeout: %s", message), - Details: &unversioned.StatusDetails{ + Details: &metav1.StatusDetails{ RetryAfterSeconds: int32(retryAfterSeconds), }, }} } // NewGenericServerResponse returns a new error for server responses that are not in a recognizable form. -func NewGenericServerResponse(code int, verb string, qualifiedResource unversioned.GroupResource, name, serverMessage string, retryAfterSeconds int, isUnexpectedResponse bool) *StatusError { - reason := unversioned.StatusReasonUnknown +func NewGenericServerResponse(code int, verb string, qualifiedResource schema.GroupResource, name, serverMessage string, retryAfterSeconds int, isUnexpectedResponse bool) *StatusError { + reason := metav1.StatusReasonUnknown message := fmt.Sprintf("the server responded with the status code %d but did not return more information", code) switch code { case http.StatusConflict: if verb == "POST" { - reason = unversioned.StatusReasonAlreadyExists + reason = metav1.StatusReasonAlreadyExists } else { - reason = unversioned.StatusReasonConflict + reason = metav1.StatusReasonConflict } message = "the server reported a conflict" case http.StatusNotFound: - reason = unversioned.StatusReasonNotFound + reason = metav1.StatusReasonNotFound message = "the server could not find the requested resource" case http.StatusBadRequest: - reason = unversioned.StatusReasonBadRequest + reason = metav1.StatusReasonBadRequest message = "the server rejected our request for an unknown reason" case http.StatusUnauthorized: - reason = unversioned.StatusReasonUnauthorized + reason = metav1.StatusReasonUnauthorized message = "the server has asked for the client to provide credentials" case http.StatusForbidden: - reason = unversioned.StatusReasonForbidden - message = "the server does not allow access to the requested resource" + reason = metav1.StatusReasonForbidden + // the server message has details about who is trying to perform what action. Keep its message. + message = serverMessage case http.StatusMethodNotAllowed: - reason = unversioned.StatusReasonMethodNotAllowed + reason = metav1.StatusReasonMethodNotAllowed message = "the server does not allow this method on the requested resource" case StatusUnprocessableEntity: - reason = unversioned.StatusReasonInvalid + reason = metav1.StatusReasonInvalid message = "the server rejected our request due to an error in our request" case StatusServerTimeout: - reason = unversioned.StatusReasonServerTimeout + reason = metav1.StatusReasonServerTimeout message = "the server cannot complete the requested operation at this time, try again later" case StatusTooManyRequests: - reason = unversioned.StatusReasonTimeout + reason = metav1.StatusReasonTimeout message = "the server has received too many requests and has asked us to try again later" default: if code >= 500 { - reason = unversioned.StatusReasonInternalError + reason = metav1.StatusReasonInternalError message = fmt.Sprintf("an error on the server (%q) has prevented the request from succeeding", serverMessage) } } @@ -332,22 +334,22 @@ func NewGenericServerResponse(code int, verb string, qualifiedResource unversion case !qualifiedResource.Empty(): message = fmt.Sprintf("%s (%s %s)", message, strings.ToLower(verb), qualifiedResource.String()) } - var causes []unversioned.StatusCause + var causes []metav1.StatusCause if isUnexpectedResponse { - causes = []unversioned.StatusCause{ + causes = []metav1.StatusCause{ { - Type: unversioned.CauseTypeUnexpectedServerResponse, + Type: metav1.CauseTypeUnexpectedServerResponse, Message: serverMessage, }, } } else { causes = nil } - return &StatusError{unversioned.Status{ - Status: unversioned.StatusFailure, + return &StatusError{metav1.Status{ + Status: metav1.StatusFailure, Code: int32(code), Reason: reason, - Details: &unversioned.StatusDetails{ + Details: &metav1.StatusDetails{ Group: qualifiedResource.Group, Kind: qualifiedResource.Resource, Name: name, @@ -361,56 +363,62 @@ func NewGenericServerResponse(code int, verb string, qualifiedResource unversion // IsNotFound returns true if the specified error was created by NewNotFound. func IsNotFound(err error) bool { - return reasonForError(err) == unversioned.StatusReasonNotFound + return reasonForError(err) == metav1.StatusReasonNotFound } // IsAlreadyExists determines if the err is an error which indicates that a specified resource already exists. func IsAlreadyExists(err error) bool { - return reasonForError(err) == unversioned.StatusReasonAlreadyExists + return reasonForError(err) == metav1.StatusReasonAlreadyExists } // IsConflict determines if the err is an error which indicates the provided update conflicts. func IsConflict(err error) bool { - return reasonForError(err) == unversioned.StatusReasonConflict + return reasonForError(err) == metav1.StatusReasonConflict } // IsInvalid determines if the err is an error which indicates the provided resource is not valid. func IsInvalid(err error) bool { - return reasonForError(err) == unversioned.StatusReasonInvalid + return reasonForError(err) == metav1.StatusReasonInvalid } // IsMethodNotSupported determines if the err is an error which indicates the provided action could not // be performed because it is not supported by the server. func IsMethodNotSupported(err error) bool { - return reasonForError(err) == unversioned.StatusReasonMethodNotAllowed + return reasonForError(err) == metav1.StatusReasonMethodNotAllowed } // IsBadRequest determines if err is an error which indicates that the request is invalid. func IsBadRequest(err error) bool { - return reasonForError(err) == unversioned.StatusReasonBadRequest + return reasonForError(err) == metav1.StatusReasonBadRequest } // IsUnauthorized determines if err is an error which indicates that the request is unauthorized and // requires authentication by the user. func IsUnauthorized(err error) bool { - return reasonForError(err) == unversioned.StatusReasonUnauthorized + return reasonForError(err) == metav1.StatusReasonUnauthorized } // IsForbidden determines if err is an error which indicates that the request is forbidden and cannot // be completed as requested. func IsForbidden(err error) bool { - return reasonForError(err) == unversioned.StatusReasonForbidden + return reasonForError(err) == metav1.StatusReasonForbidden +} + +// IsTimeout determines if err is an error which indicates that request times out due to long +// processing. +func IsTimeout(err error) bool { + return reasonForError(err) == metav1.StatusReasonTimeout } // IsServerTimeout determines if err is an error which indicates that the request needs to be retried // by the client. func IsServerTimeout(err error) bool { - return reasonForError(err) == unversioned.StatusReasonServerTimeout + return reasonForError(err) == metav1.StatusReasonServerTimeout } // IsInternalError determines if err is an error which indicates an internal server error. func IsInternalError(err error) bool { - return reasonForError(err) == unversioned.StatusReasonInternalError + return reasonForError(err) == metav1.StatusReasonInternalError } // IsTooManyRequests determines if err is an error which indicates that there are too many requests @@ -431,7 +439,7 @@ func IsUnexpectedServerError(err error) bool { case APIStatus: if d := t.Status().Details; d != nil { for _, cause := range d.Causes { - if cause.Type == unversioned.CauseTypeUnexpectedServerResponse { + if cause.Type == metav1.CauseTypeUnexpectedServerResponse { return true } } @@ -453,7 +461,7 @@ func SuggestsClientDelay(err error) (int, bool) { case APIStatus: if t.Status().Details != nil { switch t.Status().Reason { - case unversioned.StatusReasonServerTimeout, unversioned.StatusReasonTimeout: + case metav1.StatusReasonServerTimeout, metav1.StatusReasonTimeout: return int(t.Status().Details.RetryAfterSeconds), true } } @@ -461,10 +469,10 @@ func SuggestsClientDelay(err error) (int, bool) { return 0, false } -func reasonForError(err error) unversioned.StatusReason { +func reasonForError(err error) metav1.StatusReason { switch t := err.(type) { case APIStatus: return t.Status().Reason } - return unversioned.StatusReasonUnknown + return metav1.StatusReasonUnknown } diff --git a/vendor/k8s.io/apimachinery/pkg/api/meta/BUILD b/vendor/k8s.io/apimachinery/pkg/api/meta/BUILD new file mode 100644 index 0000000000..b148d5cee9 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/BUILD @@ -0,0 +1,59 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "meta_test.go", + "multirestmapper_test.go", + "priority_test.go", + "restmapper_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "default.go", + "doc.go", + "errors.go", + "firsthit_restmapper.go", + "help.go", + "interfaces.go", + "meta.go", + "multirestmapper.go", + "priority.go", + "restmapper.go", + "unstructured.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) diff --git a/vendor/k8s.io/apimachinery/pkg/api/meta/OWNERS b/vendor/k8s.io/apimachinery/pkg/api/meta/OWNERS new file mode 100755 index 0000000000..6044c031ed --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/OWNERS @@ -0,0 +1,26 @@ +reviewers: +- thockin +- smarterclayton +- wojtek-t +- deads2k +- brendandburns +- derekwaynecarr +- caesarxuchao +- mikedanese +- liggitt +- nikhiljindal +- gmarek +- kargakis +- janetkuo +- ncdc +- eparis +- dims +- krousey +- markturansky +- fabioy +- resouer +- david-mcmahon +- mfojtik +- jianhuiz +- feihujiang +- ghodss diff --git a/vendor/k8s.io/client-go/pkg/api/mapper.go b/vendor/k8s.io/apimachinery/pkg/api/meta/default.go similarity index 57% rename from vendor/k8s.io/client-go/pkg/api/mapper.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/default.go index db72bdfb8e..5ea906a2a7 100644 --- a/vendor/k8s.io/client-go/pkg/api/mapper.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/default.go @@ -14,28 +14,21 @@ See the License for the specific language governing permissions and limitations under the License. */ -package api +package meta import ( "strings" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/sets" ) -// Instantiates a DefaultRESTMapper based on types registered in api.Scheme -func NewDefaultRESTMapper(defaultGroupVersions []unversioned.GroupVersion, interfacesFunc meta.VersionInterfacesFunc, - importPathPrefix string, ignoredKinds, rootScoped sets.String) *meta.DefaultRESTMapper { - return NewDefaultRESTMapperFromScheme(defaultGroupVersions, interfacesFunc, importPathPrefix, ignoredKinds, rootScoped, Scheme) -} - -// Instantiates a DefaultRESTMapper based on types registered in the given scheme. -func NewDefaultRESTMapperFromScheme(defaultGroupVersions []unversioned.GroupVersion, interfacesFunc meta.VersionInterfacesFunc, - importPathPrefix string, ignoredKinds, rootScoped sets.String, scheme *runtime.Scheme) *meta.DefaultRESTMapper { +// NewDefaultRESTMapperFromScheme instantiates a DefaultRESTMapper based on types registered in the given scheme. +func NewDefaultRESTMapperFromScheme(defaultGroupVersions []schema.GroupVersion, interfacesFunc VersionInterfacesFunc, + importPathPrefix string, ignoredKinds, rootScoped sets.String, scheme *runtime.Scheme) *DefaultRESTMapper { - mapper := meta.NewDefaultRESTMapper(defaultGroupVersions, interfacesFunc) + mapper := NewDefaultRESTMapper(defaultGroupVersions, interfacesFunc) // enumerate all supported versions, get the kinds, and register with the mapper how to address // our resources. for _, gv := range defaultGroupVersions { @@ -47,9 +40,9 @@ func NewDefaultRESTMapperFromScheme(defaultGroupVersions []unversioned.GroupVers if !strings.Contains(oType.PkgPath(), importPathPrefix) || ignoredKinds.Has(kind) { continue } - scope := meta.RESTScopeNamespace + scope := RESTScopeNamespace if rootScoped.Has(kind) { - scope = meta.RESTScopeRoot + scope = RESTScopeRoot } mapper.Add(gvk, scope) } diff --git a/vendor/k8s.io/client-go/pkg/api/meta/doc.go b/vendor/k8s.io/apimachinery/pkg/api/meta/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/api/meta/doc.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/doc.go diff --git a/vendor/k8s.io/client-go/pkg/api/meta/errors.go b/vendor/k8s.io/apimachinery/pkg/api/meta/errors.go similarity index 86% rename from vendor/k8s.io/client-go/pkg/api/meta/errors.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/errors.go index 9de77d60ef..1503bd6d84 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/errors.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/errors.go @@ -19,15 +19,15 @@ package meta import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) // AmbiguousResourceError is returned if the RESTMapper finds multiple matches for a resource type AmbiguousResourceError struct { - PartialResource unversioned.GroupVersionResource + PartialResource schema.GroupVersionResource - MatchingResources []unversioned.GroupVersionResource - MatchingKinds []unversioned.GroupVersionKind + MatchingResources []schema.GroupVersionResource + MatchingKinds []schema.GroupVersionKind } func (e *AmbiguousResourceError) Error() string { @@ -44,10 +44,10 @@ func (e *AmbiguousResourceError) Error() string { // AmbiguousKindError is returned if the RESTMapper finds multiple matches for a kind type AmbiguousKindError struct { - PartialKind unversioned.GroupVersionKind + PartialKind schema.GroupVersionKind - MatchingResources []unversioned.GroupVersionResource - MatchingKinds []unversioned.GroupVersionKind + MatchingResources []schema.GroupVersionResource + MatchingKinds []schema.GroupVersionKind } func (e *AmbiguousKindError) Error() string { @@ -76,7 +76,7 @@ func IsAmbiguousError(err error) bool { // NoResourceMatchError is returned if the RESTMapper can't find any match for a resource type NoResourceMatchError struct { - PartialResource unversioned.GroupVersionResource + PartialResource schema.GroupVersionResource } func (e *NoResourceMatchError) Error() string { @@ -85,7 +85,7 @@ func (e *NoResourceMatchError) Error() string { // NoKindMatchError is returned if the RESTMapper can't find any match for a kind type NoKindMatchError struct { - PartialKind unversioned.GroupVersionKind + PartialKind schema.GroupVersionKind } func (e *NoKindMatchError) Error() string { diff --git a/vendor/k8s.io/client-go/pkg/api/meta/firsthit_restmapper.go b/vendor/k8s.io/apimachinery/pkg/api/meta/firsthit_restmapper.go similarity index 79% rename from vendor/k8s.io/client-go/pkg/api/meta/firsthit_restmapper.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/firsthit_restmapper.go index 3c576dbe94..fd22100229 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/firsthit_restmapper.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/firsthit_restmapper.go @@ -19,8 +19,8 @@ package meta import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" - utilerrors "k8s.io/client-go/pkg/util/errors" + "k8s.io/apimachinery/pkg/runtime/schema" + utilerrors "k8s.io/apimachinery/pkg/util/errors" ) // FirstHitRESTMapper is a wrapper for multiple RESTMappers which returns the @@ -33,7 +33,7 @@ func (m FirstHitRESTMapper) String() string { return fmt.Sprintf("FirstHitRESTMapper{\n\t%v\n}", m.MultiRESTMapper) } -func (m FirstHitRESTMapper) ResourceFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionResource, error) { +func (m FirstHitRESTMapper) ResourceFor(resource schema.GroupVersionResource) (schema.GroupVersionResource, error) { errors := []error{} for _, t := range m.MultiRESTMapper { ret, err := t.ResourceFor(resource) @@ -43,10 +43,10 @@ func (m FirstHitRESTMapper) ResourceFor(resource unversioned.GroupVersionResourc errors = append(errors, err) } - return unversioned.GroupVersionResource{}, collapseAggregateErrors(errors) + return schema.GroupVersionResource{}, collapseAggregateErrors(errors) } -func (m FirstHitRESTMapper) KindFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionKind, error) { +func (m FirstHitRESTMapper) KindFor(resource schema.GroupVersionResource) (schema.GroupVersionKind, error) { errors := []error{} for _, t := range m.MultiRESTMapper { ret, err := t.KindFor(resource) @@ -56,13 +56,13 @@ func (m FirstHitRESTMapper) KindFor(resource unversioned.GroupVersionResource) ( errors = append(errors, err) } - return unversioned.GroupVersionKind{}, collapseAggregateErrors(errors) + return schema.GroupVersionKind{}, collapseAggregateErrors(errors) } // RESTMapping provides the REST mapping for the resource based on the // kind and version. This implementation supports multiple REST schemas and // return the first match. -func (m FirstHitRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...string) (*RESTMapping, error) { +func (m FirstHitRESTMapper) RESTMapping(gk schema.GroupKind, versions ...string) (*RESTMapping, error) { errors := []error{} for _, t := range m.MultiRESTMapper { ret, err := t.RESTMapping(gk, versions...) diff --git a/vendor/k8s.io/client-go/pkg/api/meta/help.go b/vendor/k8s.io/apimachinery/pkg/api/meta/help.go similarity index 92% rename from vendor/k8s.io/client-go/pkg/api/meta/help.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/help.go index 607f3fa3fb..9e0fb152ad 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/help.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/help.go @@ -20,18 +20,16 @@ import ( "fmt" "reflect" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" ) // IsListType returns true if the provided Object has a slice called Items func IsListType(obj runtime.Object) bool { - // if we're a runtime.Unstructured, check to see if we have an `items` key - // This is a list type for recognition, but other Items type methods will fail on it - // and give you errors. - if unstructured, ok := obj.(*runtime.Unstructured); ok { - _, ok := unstructured.Object["items"] - return ok + // if we're a runtime.Unstructured, check whether this is a list. + // TODO: refactor GetItemsPtr to use an interface that returns []runtime.Object + if unstructured, ok := obj.(runtime.Unstructured); ok { + return unstructured.IsList() } _, err := GetItemsPtr(obj) @@ -177,6 +175,9 @@ func SetList(list runtime.Object, objects []runtime.Object) error { slice := reflect.MakeSlice(items.Type(), len(objects), len(objects)) for i := range objects { dest := slice.Index(i) + if dest.Type() == reflect.TypeOf(runtime.RawExtension{}) { + dest = dest.FieldByName("Object") + } // check to see if you're directly assignable if reflect.TypeOf(objects[i]).AssignableTo(dest.Type()) { diff --git a/vendor/k8s.io/client-go/pkg/api/meta/interfaces.go b/vendor/k8s.io/apimachinery/pkg/api/meta/interfaces.go similarity index 69% rename from vendor/k8s.io/client-go/pkg/api/meta/interfaces.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/interfaces.go index 6dd570008a..b2c8c97b11 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/interfaces.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/interfaces.go @@ -17,10 +17,10 @@ limitations under the License. package meta import ( - "k8s.io/client-go/pkg/api/meta/metatypes" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/types" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" ) // VersionInterfaces contains the interfaces one should use for dealing with types of a particular version. @@ -29,45 +29,6 @@ type VersionInterfaces struct { MetadataAccessor } -type ObjectMetaAccessor interface { - GetObjectMeta() Object -} - -// Object lets you work with object metadata from any of the versioned or -// internal API objects. Attempting to set or retrieve a field on an object that does -// not support that field (Name, UID, Namespace on lists) will be a no-op and return -// a default value. -type Object interface { - GetNamespace() string - SetNamespace(namespace string) - GetName() string - SetName(name string) - GetGenerateName() string - SetGenerateName(name string) - GetUID() types.UID - SetUID(uid types.UID) - GetResourceVersion() string - SetResourceVersion(version string) - GetSelfLink() string - SetSelfLink(selfLink string) - GetCreationTimestamp() unversioned.Time - SetCreationTimestamp(timestamp unversioned.Time) - GetDeletionTimestamp() *unversioned.Time - SetDeletionTimestamp(timestamp *unversioned.Time) - GetLabels() map[string]string - SetLabels(labels map[string]string) - GetAnnotations() map[string]string - SetAnnotations(annotations map[string]string) - GetFinalizers() []string - SetFinalizers(finalizers []string) - GetOwnerReferences() []metatypes.OwnerReference - SetOwnerReferences([]metatypes.OwnerReference) - GetClusterName() string - SetClusterName(clusterName string) -} - -var _ Object = &runtime.Unstructured{} - type ListMetaAccessor interface { GetListMeta() List } @@ -75,10 +36,10 @@ type ListMetaAccessor interface { // List lets you work with list metadata from any of the versioned or // internal API objects. Attempting to set or retrieve a field on an object that does // not support that field will be a no-op and return a default value. -type List unversioned.List +type List metav1.List // Type exposes the type and APIVersion of versioned or internal API objects. -type Type unversioned.Type +type Type metav1.Type // MetadataAccessor lets you work with object and list metadata from any of the versioned or // internal API objects. Attempting to set or retrieve a field on an object that does @@ -143,7 +104,7 @@ type RESTMapping struct { // Resource is a string representing the name of this resource as a REST client would see it Resource string - GroupVersionKind unversioned.GroupVersionKind + GroupVersionKind schema.GroupVersionKind // Scope contains the information needed to deal with REST Resources that are in a resource hierarchy Scope RESTScope @@ -163,22 +124,23 @@ type RESTMapping struct { // TODO: split into sub-interfaces type RESTMapper interface { // KindFor takes a partial resource and returns the single match. Returns an error if there are multiple matches - KindFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionKind, error) + KindFor(resource schema.GroupVersionResource) (schema.GroupVersionKind, error) // KindsFor takes a partial resource and returns the list of potential kinds in priority order - KindsFor(resource unversioned.GroupVersionResource) ([]unversioned.GroupVersionKind, error) + KindsFor(resource schema.GroupVersionResource) ([]schema.GroupVersionKind, error) // ResourceFor takes a partial resource and returns the single match. Returns an error if there are multiple matches - ResourceFor(input unversioned.GroupVersionResource) (unversioned.GroupVersionResource, error) + ResourceFor(input schema.GroupVersionResource) (schema.GroupVersionResource, error) // ResourcesFor takes a partial resource and returns the list of potential resource in priority order - ResourcesFor(input unversioned.GroupVersionResource) ([]unversioned.GroupVersionResource, error) + ResourcesFor(input schema.GroupVersionResource) ([]schema.GroupVersionResource, error) // RESTMapping identifies a preferred resource mapping for the provided group kind. - RESTMapping(gk unversioned.GroupKind, versions ...string) (*RESTMapping, error) - // RESTMappings returns all resource mappings for the provided group kind. - RESTMappings(gk unversioned.GroupKind) ([]*RESTMapping, error) + RESTMapping(gk schema.GroupKind, versions ...string) (*RESTMapping, error) + // RESTMappings returns all resource mappings for the provided group kind if no + // version search is provided. Otherwise identifies a preferred resource mapping for + // the provided version(s). + RESTMappings(gk schema.GroupKind, versions ...string) ([]*RESTMapping, error) - AliasesForResource(resource string) ([]string, bool) ResourceSingularizer(resource string) (singular string, err error) } diff --git a/vendor/k8s.io/client-go/pkg/api/meta/meta.go b/vendor/k8s.io/apimachinery/pkg/api/meta/meta.go similarity index 81% rename from vendor/k8s.io/client-go/pkg/api/meta/meta.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/meta.go index 9f11215ad1..45d850ea8a 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/meta.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/meta.go @@ -20,13 +20,14 @@ import ( "fmt" "reflect" - "k8s.io/client-go/pkg/api/meta/metatypes" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/types" - "github.com/golang/glog" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + metav1alpha1 "k8s.io/apimachinery/pkg/apis/meta/v1alpha1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" ) // errNotList is returned when an object implements the Object style interfaces but not the List style @@ -42,21 +43,21 @@ func ListAccessor(obj interface{}) (List, error) { switch t := obj.(type) { case List: return t, nil - case unversioned.List: + case metav1.List: return t, nil case ListMetaAccessor: if m := t.GetListMeta(); m != nil { return m, nil } return nil, errNotList - case unversioned.ListMetaAccessor: + case metav1.ListMetaAccessor: if m := t.GetListMeta(); m != nil { return m, nil } return nil, errNotList - case Object: + case metav1.Object: return t, nil - case ObjectMetaAccessor: + case metav1.ObjectMetaAccessor: if m := t.GetObjectMeta(); m != nil { return m, nil } @@ -75,22 +76,50 @@ var errNotObject = fmt.Errorf("object does not implement the Object interfaces") // required fields are missing. Fields that are not required return the default // value and are a no-op if set. // TODO: return bool instead of error -func Accessor(obj interface{}) (Object, error) { +func Accessor(obj interface{}) (metav1.Object, error) { switch t := obj.(type) { - case Object: + case metav1.Object: return t, nil - case ObjectMetaAccessor: + case metav1.ObjectMetaAccessor: if m := t.GetObjectMeta(); m != nil { return m, nil } return nil, errNotObject - case List, unversioned.List, ListMetaAccessor, unversioned.ListMetaAccessor: - return nil, errNotObject default: return nil, errNotObject } } +// AsPartialObjectMetadata takes the metav1 interface and returns a partial object. +// TODO: consider making this solely a conversion action. +func AsPartialObjectMetadata(m metav1.Object) *metav1alpha1.PartialObjectMetadata { + switch t := m.(type) { + case *metav1.ObjectMeta: + return &metav1alpha1.PartialObjectMetadata{ObjectMeta: *t} + default: + return &metav1alpha1.PartialObjectMetadata{ + ObjectMeta: metav1.ObjectMeta{ + Name: m.GetName(), + GenerateName: m.GetGenerateName(), + Namespace: m.GetNamespace(), + SelfLink: m.GetSelfLink(), + UID: m.GetUID(), + ResourceVersion: m.GetResourceVersion(), + Generation: m.GetGeneration(), + CreationTimestamp: m.GetCreationTimestamp(), + DeletionTimestamp: m.GetDeletionTimestamp(), + DeletionGracePeriodSeconds: m.GetDeletionGracePeriodSeconds(), + Labels: m.GetLabels(), + Annotations: m.GetAnnotations(), + OwnerReferences: m.GetOwnerReferences(), + Finalizers: m.GetFinalizers(), + ClusterName: m.GetClusterName(), + Initializers: m.GetInitializers(), + }, + } + } +} + // TypeAccessor returns an interface that allows retrieving and modifying the APIVersion // and Kind of an in-memory internal object. // TODO: this interface is used to test code that does not have ObjectMeta or ListMeta @@ -140,9 +169,9 @@ func (obj objectAccessor) GetAPIVersion() string { func (obj objectAccessor) SetAPIVersion(version string) { gvk := obj.GetObjectKind().GroupVersionKind() - gv, err := unversioned.ParseGroupVersion(version) + gv, err := schema.ParseGroupVersion(version) if err != nil { - gv = unversioned.GroupVersion{Version: version} + gv = schema.GroupVersion{Version: version} } gvk.Group, gvk.Version = gv.Group, gv.Version obj.GetObjectKind().SetGroupVersionKind(gvk) @@ -313,7 +342,7 @@ func (resourceAccessor) SetResourceVersion(obj runtime.Object, version string) e } // extractFromOwnerReference extracts v to o. v is the OwnerReferences field of an object. -func extractFromOwnerReference(v reflect.Value, o *metatypes.OwnerReference) error { +func extractFromOwnerReference(v reflect.Value, o *metav1.OwnerReference) error { if err := runtime.Field(v, "APIVersion", &o.APIVersion); err != nil { return err } @@ -334,11 +363,19 @@ func extractFromOwnerReference(v reflect.Value, o *metatypes.OwnerReference) err controller := *controllerPtr o.Controller = &controller } + var blockOwnerDeletionPtr *bool + if err := runtime.Field(v, "BlockOwnerDeletion", &blockOwnerDeletionPtr); err != nil { + return err + } + if blockOwnerDeletionPtr != nil { + block := *blockOwnerDeletionPtr + o.BlockOwnerDeletion = &block + } return nil } // setOwnerReference sets v to o. v is the OwnerReferences field of an object. -func setOwnerReference(v reflect.Value, o *metatypes.OwnerReference) error { +func setOwnerReference(v reflect.Value, o *metav1.OwnerReference) error { if err := runtime.SetField(o.APIVersion, v, "APIVersion"); err != nil { return err } @@ -357,6 +394,12 @@ func setOwnerReference(v reflect.Value, o *metatypes.OwnerReference) error { return err } } + if o.BlockOwnerDeletion != nil { + block := *(o.BlockOwnerDeletion) + if err := runtime.SetField(&block, v, "BlockOwnerDeletion"); err != nil { + return err + } + } return nil } @@ -371,8 +414,8 @@ type genericAccessor struct { kind *string resourceVersion *string selfLink *string - creationTimestamp *unversioned.Time - deletionTimestamp **unversioned.Time + creationTimestamp *metav1.Time + deletionTimestamp **metav1.Time labels *map[string]string annotations *map[string]string ownerReferences reflect.Value @@ -467,19 +510,19 @@ func (a genericAccessor) SetSelfLink(selfLink string) { *a.selfLink = selfLink } -func (a genericAccessor) GetCreationTimestamp() unversioned.Time { +func (a genericAccessor) GetCreationTimestamp() metav1.Time { return *a.creationTimestamp } -func (a genericAccessor) SetCreationTimestamp(timestamp unversioned.Time) { +func (a genericAccessor) SetCreationTimestamp(timestamp metav1.Time) { *a.creationTimestamp = timestamp } -func (a genericAccessor) GetDeletionTimestamp() *unversioned.Time { +func (a genericAccessor) GetDeletionTimestamp() *metav1.Time { return *a.deletionTimestamp } -func (a genericAccessor) SetDeletionTimestamp(timestamp *unversioned.Time) { +func (a genericAccessor) SetDeletionTimestamp(timestamp *metav1.Time) { *a.deletionTimestamp = timestamp } @@ -520,8 +563,8 @@ func (a genericAccessor) SetFinalizers(finalizers []string) { *a.finalizers = finalizers } -func (a genericAccessor) GetOwnerReferences() []metatypes.OwnerReference { - var ret []metatypes.OwnerReference +func (a genericAccessor) GetOwnerReferences() []metav1.OwnerReference { + var ret []metav1.OwnerReference s := a.ownerReferences if s.Kind() != reflect.Ptr || s.Elem().Kind() != reflect.Slice { glog.Errorf("expect %v to be a pointer to slice", s) @@ -529,7 +572,7 @@ func (a genericAccessor) GetOwnerReferences() []metatypes.OwnerReference { } s = s.Elem() // Set the capacity to one element greater to avoid copy if the caller later append an element. - ret = make([]metatypes.OwnerReference, s.Len(), s.Len()+1) + ret = make([]metav1.OwnerReference, s.Len(), s.Len()+1) for i := 0; i < s.Len(); i++ { if err := extractFromOwnerReference(s.Index(i), &ret[i]); err != nil { glog.Errorf("extractFromOwnerReference failed: %v", err) @@ -539,7 +582,7 @@ func (a genericAccessor) GetOwnerReferences() []metatypes.OwnerReference { return ret } -func (a genericAccessor) SetOwnerReferences(references []metatypes.OwnerReference) { +func (a genericAccessor) SetOwnerReferences(references []metav1.OwnerReference) { s := a.ownerReferences if s.Kind() != reflect.Ptr || s.Elem().Kind() != reflect.Slice { glog.Errorf("expect %v to be a pointer to slice", s) diff --git a/vendor/k8s.io/client-go/pkg/api/meta/multirestmapper.go b/vendor/k8s.io/apimachinery/pkg/api/meta/multirestmapper.go similarity index 70% rename from vendor/k8s.io/client-go/pkg/api/meta/multirestmapper.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/multirestmapper.go index c8ee8d1db8..679098fe56 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/multirestmapper.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/multirestmapper.go @@ -20,9 +20,8 @@ import ( "fmt" "strings" - "k8s.io/client-go/pkg/api/unversioned" - utilerrors "k8s.io/client-go/pkg/util/errors" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/runtime/schema" + utilerrors "k8s.io/apimachinery/pkg/util/errors" ) // MultiRESTMapper is a wrapper for multiple RESTMappers. @@ -51,8 +50,8 @@ func (m MultiRESTMapper) ResourceSingularizer(resource string) (singular string, return } -func (m MultiRESTMapper) ResourcesFor(resource unversioned.GroupVersionResource) ([]unversioned.GroupVersionResource, error) { - allGVRs := []unversioned.GroupVersionResource{} +func (m MultiRESTMapper) ResourcesFor(resource schema.GroupVersionResource) ([]schema.GroupVersionResource, error) { + allGVRs := []schema.GroupVersionResource{} for _, t := range m { gvrs, err := t.ResourcesFor(resource) // ignore "no match" errors, but any other error percolates back up @@ -86,8 +85,8 @@ func (m MultiRESTMapper) ResourcesFor(resource unversioned.GroupVersionResource) return allGVRs, nil } -func (m MultiRESTMapper) KindsFor(resource unversioned.GroupVersionResource) (gvk []unversioned.GroupVersionKind, err error) { - allGVKs := []unversioned.GroupVersionKind{} +func (m MultiRESTMapper) KindsFor(resource schema.GroupVersionResource) (gvk []schema.GroupVersionKind, err error) { + allGVKs := []schema.GroupVersionKind{} for _, t := range m { gvks, err := t.KindsFor(resource) // ignore "no match" errors, but any other error percolates back up @@ -121,34 +120,34 @@ func (m MultiRESTMapper) KindsFor(resource unversioned.GroupVersionResource) (gv return allGVKs, nil } -func (m MultiRESTMapper) ResourceFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionResource, error) { +func (m MultiRESTMapper) ResourceFor(resource schema.GroupVersionResource) (schema.GroupVersionResource, error) { resources, err := m.ResourcesFor(resource) if err != nil { - return unversioned.GroupVersionResource{}, err + return schema.GroupVersionResource{}, err } if len(resources) == 1 { return resources[0], nil } - return unversioned.GroupVersionResource{}, &AmbiguousResourceError{PartialResource: resource, MatchingResources: resources} + return schema.GroupVersionResource{}, &AmbiguousResourceError{PartialResource: resource, MatchingResources: resources} } -func (m MultiRESTMapper) KindFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionKind, error) { +func (m MultiRESTMapper) KindFor(resource schema.GroupVersionResource) (schema.GroupVersionKind, error) { kinds, err := m.KindsFor(resource) if err != nil { - return unversioned.GroupVersionKind{}, err + return schema.GroupVersionKind{}, err } if len(kinds) == 1 { return kinds[0], nil } - return unversioned.GroupVersionKind{}, &AmbiguousResourceError{PartialResource: resource, MatchingKinds: kinds} + return schema.GroupVersionKind{}, &AmbiguousResourceError{PartialResource: resource, MatchingKinds: kinds} } // RESTMapping provides the REST mapping for the resource based on the // kind and version. This implementation supports multiple REST schemas and // return the first match. -func (m MultiRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...string) (*RESTMapping, error) { +func (m MultiRESTMapper) RESTMapping(gk schema.GroupKind, versions ...string) (*RESTMapping, error) { allMappings := []*RESTMapping{} errors := []error{} @@ -171,7 +170,7 @@ func (m MultiRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...strin return allMappings[0], nil } if len(allMappings) > 1 { - var kinds []unversioned.GroupVersionKind + var kinds []schema.GroupVersionKind for _, m := range allMappings { kinds = append(kinds, m.GroupVersionKind) } @@ -185,12 +184,12 @@ func (m MultiRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...strin // RESTMappings returns all possible RESTMappings for the provided group kind, or an error // if the type is not recognized. -func (m MultiRESTMapper) RESTMappings(gk unversioned.GroupKind) ([]*RESTMapping, error) { +func (m MultiRESTMapper) RESTMappings(gk schema.GroupKind, versions ...string) ([]*RESTMapping, error) { var allMappings []*RESTMapping var errors []error for _, t := range m { - currMappings, err := t.RESTMappings(gk) + currMappings, err := t.RESTMappings(gk, versions...) // ignore "no match" errors, but any other error percolates back up if IsNoMatchError(err) { continue @@ -209,23 +208,3 @@ func (m MultiRESTMapper) RESTMappings(gk unversioned.GroupKind) ([]*RESTMapping, } return allMappings, nil } - -// AliasesForResource finds the first alias response for the provided mappers. -func (m MultiRESTMapper) AliasesForResource(alias string) ([]string, bool) { - seenAliases := sets.NewString() - allAliases := []string{} - handled := false - - for _, t := range m { - if currAliases, currOk := t.AliasesForResource(alias); currOk { - for _, currAlias := range currAliases { - if !seenAliases.Has(currAlias) { - allAliases = append(allAliases, currAlias) - seenAliases.Insert(currAlias) - } - } - handled = true - } - } - return allAliases, handled -} diff --git a/vendor/k8s.io/client-go/pkg/api/meta/priority.go b/vendor/k8s.io/apimachinery/pkg/api/meta/priority.go similarity index 74% rename from vendor/k8s.io/client-go/pkg/api/meta/priority.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/priority.go index b0ba309c89..2a14aa7ab1 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/priority.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/priority.go @@ -19,7 +19,7 @@ package meta import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) const ( @@ -39,13 +39,13 @@ type PriorityRESTMapper struct { // The list of all matching resources is narrowed based on the patterns until only one remains. // A pattern with no matches is skipped. A pattern with more than one match uses its // matches as the list to continue matching against. - ResourcePriority []unversioned.GroupVersionResource + ResourcePriority []schema.GroupVersionResource // KindPriority is a list of priority patterns to apply to matching kinds. // The list of all matching kinds is narrowed based on the patterns until only one remains. // A pattern with no matches is skipped. A pattern with more than one match uses its // matches as the list to continue matching against. - KindPriority []unversioned.GroupVersionKind + KindPriority []schema.GroupVersionKind } func (m PriorityRESTMapper) String() string { @@ -53,18 +53,18 @@ func (m PriorityRESTMapper) String() string { } // ResourceFor finds all resources, then passes them through the ResourcePriority patterns to find a single matching hit. -func (m PriorityRESTMapper) ResourceFor(partiallySpecifiedResource unversioned.GroupVersionResource) (unversioned.GroupVersionResource, error) { +func (m PriorityRESTMapper) ResourceFor(partiallySpecifiedResource schema.GroupVersionResource) (schema.GroupVersionResource, error) { originalGVRs, err := m.Delegate.ResourcesFor(partiallySpecifiedResource) if err != nil { - return unversioned.GroupVersionResource{}, err + return schema.GroupVersionResource{}, err } if len(originalGVRs) == 1 { return originalGVRs[0], nil } - remainingGVRs := append([]unversioned.GroupVersionResource{}, originalGVRs...) + remainingGVRs := append([]schema.GroupVersionResource{}, originalGVRs...) for _, pattern := range m.ResourcePriority { - matchedGVRs := []unversioned.GroupVersionResource{} + matchedGVRs := []schema.GroupVersionResource{} for _, gvr := range remainingGVRs { if resourceMatches(pattern, gvr) { matchedGVRs = append(matchedGVRs, gvr) @@ -85,22 +85,22 @@ func (m PriorityRESTMapper) ResourceFor(partiallySpecifiedResource unversioned.G } } - return unversioned.GroupVersionResource{}, &AmbiguousResourceError{PartialResource: partiallySpecifiedResource, MatchingResources: originalGVRs} + return schema.GroupVersionResource{}, &AmbiguousResourceError{PartialResource: partiallySpecifiedResource, MatchingResources: originalGVRs} } // KindFor finds all kinds, then passes them through the KindPriority patterns to find a single matching hit. -func (m PriorityRESTMapper) KindFor(partiallySpecifiedResource unversioned.GroupVersionResource) (unversioned.GroupVersionKind, error) { +func (m PriorityRESTMapper) KindFor(partiallySpecifiedResource schema.GroupVersionResource) (schema.GroupVersionKind, error) { originalGVKs, err := m.Delegate.KindsFor(partiallySpecifiedResource) if err != nil { - return unversioned.GroupVersionKind{}, err + return schema.GroupVersionKind{}, err } if len(originalGVKs) == 1 { return originalGVKs[0], nil } - remainingGVKs := append([]unversioned.GroupVersionKind{}, originalGVKs...) + remainingGVKs := append([]schema.GroupVersionKind{}, originalGVKs...) for _, pattern := range m.KindPriority { - matchedGVKs := []unversioned.GroupVersionKind{} + matchedGVKs := []schema.GroupVersionKind{} for _, gvr := range remainingGVKs { if kindMatches(pattern, gvr) { matchedGVKs = append(matchedGVKs, gvr) @@ -121,10 +121,10 @@ func (m PriorityRESTMapper) KindFor(partiallySpecifiedResource unversioned.Group } } - return unversioned.GroupVersionKind{}, &AmbiguousResourceError{PartialResource: partiallySpecifiedResource, MatchingKinds: originalGVKs} + return schema.GroupVersionKind{}, &AmbiguousResourceError{PartialResource: partiallySpecifiedResource, MatchingKinds: originalGVKs} } -func resourceMatches(pattern unversioned.GroupVersionResource, resource unversioned.GroupVersionResource) bool { +func resourceMatches(pattern schema.GroupVersionResource, resource schema.GroupVersionResource) bool { if pattern.Group != AnyGroup && pattern.Group != resource.Group { return false } @@ -138,7 +138,7 @@ func resourceMatches(pattern unversioned.GroupVersionResource, resource unversio return true } -func kindMatches(pattern unversioned.GroupVersionKind, kind unversioned.GroupVersionKind) bool { +func kindMatches(pattern schema.GroupVersionKind, kind schema.GroupVersionKind) bool { if pattern.Group != AnyGroup && pattern.Group != kind.Group { return false } @@ -152,7 +152,7 @@ func kindMatches(pattern unversioned.GroupVersionKind, kind unversioned.GroupVer return true } -func (m PriorityRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...string) (mapping *RESTMapping, err error) { +func (m PriorityRESTMapper) RESTMapping(gk schema.GroupKind, versions ...string) (mapping *RESTMapping, err error) { mappings, err := m.Delegate.RESTMappings(gk) if err != nil { return nil, err @@ -161,11 +161,11 @@ func (m PriorityRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...st // any versions the user provides take priority priorities := m.KindPriority if len(versions) > 0 { - priorities = make([]unversioned.GroupVersionKind, 0, len(m.KindPriority)+len(versions)) + priorities = make([]schema.GroupVersionKind, 0, len(m.KindPriority)+len(versions)) for _, version := range versions { - gv, err := unversioned.ParseGroupVersion(version) - if err != nil { - return nil, err + gv := schema.GroupVersion{ + Version: version, + Group: gk.Group, } priorities = append(priorities, gv.WithKind(AnyKind)) } @@ -198,29 +198,25 @@ func (m PriorityRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...st return remaining[0], nil } - var kinds []unversioned.GroupVersionKind + var kinds []schema.GroupVersionKind for _, m := range mappings { kinds = append(kinds, m.GroupVersionKind) } return nil, &AmbiguousKindError{PartialKind: gk.WithVersion(""), MatchingKinds: kinds} } -func (m PriorityRESTMapper) RESTMappings(gk unversioned.GroupKind) ([]*RESTMapping, error) { - return m.Delegate.RESTMappings(gk) -} - -func (m PriorityRESTMapper) AliasesForResource(alias string) (aliases []string, ok bool) { - return m.Delegate.AliasesForResource(alias) +func (m PriorityRESTMapper) RESTMappings(gk schema.GroupKind, versions ...string) ([]*RESTMapping, error) { + return m.Delegate.RESTMappings(gk, versions...) } func (m PriorityRESTMapper) ResourceSingularizer(resource string) (singular string, err error) { return m.Delegate.ResourceSingularizer(resource) } -func (m PriorityRESTMapper) ResourcesFor(partiallySpecifiedResource unversioned.GroupVersionResource) ([]unversioned.GroupVersionResource, error) { +func (m PriorityRESTMapper) ResourcesFor(partiallySpecifiedResource schema.GroupVersionResource) ([]schema.GroupVersionResource, error) { return m.Delegate.ResourcesFor(partiallySpecifiedResource) } -func (m PriorityRESTMapper) KindsFor(partiallySpecifiedResource unversioned.GroupVersionResource) (gvk []unversioned.GroupVersionKind, err error) { +func (m PriorityRESTMapper) KindsFor(partiallySpecifiedResource schema.GroupVersionResource) (gvk []schema.GroupVersionKind, err error) { return m.Delegate.KindsFor(partiallySpecifiedResource) } diff --git a/vendor/k8s.io/client-go/pkg/api/meta/restmapper.go b/vendor/k8s.io/apimachinery/pkg/api/meta/restmapper.go similarity index 69% rename from vendor/k8s.io/client-go/pkg/api/meta/restmapper.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/restmapper.go index 98add7fd20..c6b2597dd8 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/restmapper.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/restmapper.go @@ -22,8 +22,8 @@ import ( "sort" "strings" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // Implements RESTScope interface @@ -70,18 +70,15 @@ var RESTScopeRoot = &restScope{ // TODO: Only accept plural for some operations for increased control? // (`get pod bar` vs `get pods bar`) type DefaultRESTMapper struct { - defaultGroupVersions []unversioned.GroupVersion + defaultGroupVersions []schema.GroupVersion - resourceToKind map[unversioned.GroupVersionResource]unversioned.GroupVersionKind - kindToPluralResource map[unversioned.GroupVersionKind]unversioned.GroupVersionResource - kindToScope map[unversioned.GroupVersionKind]RESTScope - singularToPlural map[unversioned.GroupVersionResource]unversioned.GroupVersionResource - pluralToSingular map[unversioned.GroupVersionResource]unversioned.GroupVersionResource + resourceToKind map[schema.GroupVersionResource]schema.GroupVersionKind + kindToPluralResource map[schema.GroupVersionKind]schema.GroupVersionResource + kindToScope map[schema.GroupVersionKind]RESTScope + singularToPlural map[schema.GroupVersionResource]schema.GroupVersionResource + pluralToSingular map[schema.GroupVersionResource]schema.GroupVersionResource interfacesFunc VersionInterfacesFunc - - // aliasToResource is used for mapping aliases to resources - aliasToResource map[string][]string } func (m *DefaultRESTMapper) String() string { @@ -92,20 +89,19 @@ var _ RESTMapper = &DefaultRESTMapper{} // VersionInterfacesFunc returns the appropriate typer, and metadata accessor for a // given api version, or an error if no such api version exists. -type VersionInterfacesFunc func(version unversioned.GroupVersion) (*VersionInterfaces, error) +type VersionInterfacesFunc func(version schema.GroupVersion) (*VersionInterfaces, error) // NewDefaultRESTMapper initializes a mapping between Kind and APIVersion // to a resource name and back based on the objects in a runtime.Scheme // and the Kubernetes API conventions. Takes a group name, a priority list of the versions // to search when an object has no default version (set empty to return an error), // and a function that retrieves the correct metadata for a given version. -func NewDefaultRESTMapper(defaultGroupVersions []unversioned.GroupVersion, f VersionInterfacesFunc) *DefaultRESTMapper { - resourceToKind := make(map[unversioned.GroupVersionResource]unversioned.GroupVersionKind) - kindToPluralResource := make(map[unversioned.GroupVersionKind]unversioned.GroupVersionResource) - kindToScope := make(map[unversioned.GroupVersionKind]RESTScope) - singularToPlural := make(map[unversioned.GroupVersionResource]unversioned.GroupVersionResource) - pluralToSingular := make(map[unversioned.GroupVersionResource]unversioned.GroupVersionResource) - aliasToResource := make(map[string][]string) +func NewDefaultRESTMapper(defaultGroupVersions []schema.GroupVersion, f VersionInterfacesFunc) *DefaultRESTMapper { + resourceToKind := make(map[schema.GroupVersionResource]schema.GroupVersionKind) + kindToPluralResource := make(map[schema.GroupVersionKind]schema.GroupVersionResource) + kindToScope := make(map[schema.GroupVersionKind]RESTScope) + singularToPlural := make(map[schema.GroupVersionResource]schema.GroupVersionResource) + pluralToSingular := make(map[schema.GroupVersionResource]schema.GroupVersionResource) // TODO: verify name mappings work correctly when versions differ return &DefaultRESTMapper{ @@ -115,13 +111,12 @@ func NewDefaultRESTMapper(defaultGroupVersions []unversioned.GroupVersion, f Ver defaultGroupVersions: defaultGroupVersions, singularToPlural: singularToPlural, pluralToSingular: pluralToSingular, - aliasToResource: aliasToResource, interfacesFunc: f, } } -func (m *DefaultRESTMapper) Add(kind unversioned.GroupVersionKind, scope RESTScope) { - plural, singular := KindToResource(kind) +func (m *DefaultRESTMapper) Add(kind schema.GroupVersionKind, scope RESTScope) { + plural, singular := UnsafeGuessKindToResource(kind) m.singularToPlural[singular] = plural m.pluralToSingular[plural] = singular @@ -141,13 +136,13 @@ var unpluralizedSuffixes = []string{ "endpoints", } -// KindToResource converts Kind to a resource name. +// UnsafeGuessKindToResource converts Kind to a resource name. // Broken. This method only "sort of" works when used outside of this package. It assumes that Kinds and Resources match // and they aren't guaranteed to do so. -func KindToResource(kind unversioned.GroupVersionKind) ( /*plural*/ unversioned.GroupVersionResource /*singular*/, unversioned.GroupVersionResource) { +func UnsafeGuessKindToResource(kind schema.GroupVersionKind) ( /*plural*/ schema.GroupVersionResource /*singular*/, schema.GroupVersionResource) { kindName := kind.Kind if len(kindName) == 0 { - return unversioned.GroupVersionResource{}, unversioned.GroupVersionResource{} + return schema.GroupVersionResource{}, schema.GroupVersionResource{} } singularName := strings.ToLower(kindName) singular := kind.GroupVersion().WithResource(singularName) @@ -171,13 +166,13 @@ func KindToResource(kind unversioned.GroupVersionKind) ( /*plural*/ unversioned. // ResourceSingularizer implements RESTMapper // It converts a resource name from plural to singular (e.g., from pods to pod) func (m *DefaultRESTMapper) ResourceSingularizer(resourceType string) (string, error) { - partialResource := unversioned.GroupVersionResource{Resource: resourceType} + partialResource := schema.GroupVersionResource{Resource: resourceType} resources, err := m.ResourcesFor(partialResource) if err != nil { return resourceType, err } - singular := unversioned.GroupVersionResource{} + singular := schema.GroupVersionResource{} for _, curr := range resources { currSingular, ok := m.pluralToSingular[curr] if !ok { @@ -201,7 +196,7 @@ func (m *DefaultRESTMapper) ResourceSingularizer(resourceType string) (string, e } // coerceResourceForMatching makes the resource lower case and converts internal versions to unspecified (legacy behavior) -func coerceResourceForMatching(resource unversioned.GroupVersionResource) unversioned.GroupVersionResource { +func coerceResourceForMatching(resource schema.GroupVersionResource) schema.GroupVersionResource { resource.Resource = strings.ToLower(resource.Resource) if resource.Version == runtime.APIVersionInternal { resource.Version = "" @@ -210,7 +205,7 @@ func coerceResourceForMatching(resource unversioned.GroupVersionResource) unvers return resource } -func (m *DefaultRESTMapper) ResourcesFor(input unversioned.GroupVersionResource) ([]unversioned.GroupVersionResource, error) { +func (m *DefaultRESTMapper) ResourcesFor(input schema.GroupVersionResource) ([]schema.GroupVersionResource, error) { resource := coerceResourceForMatching(input) hasResource := len(resource.Resource) > 0 @@ -221,7 +216,7 @@ func (m *DefaultRESTMapper) ResourcesFor(input unversioned.GroupVersionResource) return nil, fmt.Errorf("a resource must be present, got: %v", resource) } - ret := []unversioned.GroupVersionResource{} + ret := []schema.GroupVersionResource{} switch { case hasGroup && hasVersion: // fully qualified. Find the exact match @@ -297,19 +292,19 @@ func (m *DefaultRESTMapper) ResourcesFor(input unversioned.GroupVersionResource) return ret, nil } -func (m *DefaultRESTMapper) ResourceFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionResource, error) { +func (m *DefaultRESTMapper) ResourceFor(resource schema.GroupVersionResource) (schema.GroupVersionResource, error) { resources, err := m.ResourcesFor(resource) if err != nil { - return unversioned.GroupVersionResource{}, err + return schema.GroupVersionResource{}, err } if len(resources) == 1 { return resources[0], nil } - return unversioned.GroupVersionResource{}, &AmbiguousResourceError{PartialResource: resource, MatchingResources: resources} + return schema.GroupVersionResource{}, &AmbiguousResourceError{PartialResource: resource, MatchingResources: resources} } -func (m *DefaultRESTMapper) KindsFor(input unversioned.GroupVersionResource) ([]unversioned.GroupVersionKind, error) { +func (m *DefaultRESTMapper) KindsFor(input schema.GroupVersionResource) ([]schema.GroupVersionKind, error) { resource := coerceResourceForMatching(input) hasResource := len(resource.Resource) > 0 @@ -320,7 +315,7 @@ func (m *DefaultRESTMapper) KindsFor(input unversioned.GroupVersionResource) ([] return nil, fmt.Errorf("a resource must be present, got: %v", resource) } - ret := []unversioned.GroupVersionKind{} + ret := []schema.GroupVersionKind{} switch { // fully qualified. Find the exact match case hasGroup && hasVersion: @@ -376,21 +371,21 @@ func (m *DefaultRESTMapper) KindsFor(input unversioned.GroupVersionResource) ([] return ret, nil } -func (m *DefaultRESTMapper) KindFor(resource unversioned.GroupVersionResource) (unversioned.GroupVersionKind, error) { +func (m *DefaultRESTMapper) KindFor(resource schema.GroupVersionResource) (schema.GroupVersionKind, error) { kinds, err := m.KindsFor(resource) if err != nil { - return unversioned.GroupVersionKind{}, err + return schema.GroupVersionKind{}, err } if len(kinds) == 1 { return kinds[0], nil } - return unversioned.GroupVersionKind{}, &AmbiguousResourceError{PartialResource: resource, MatchingKinds: kinds} + return schema.GroupVersionKind{}, &AmbiguousResourceError{PartialResource: resource, MatchingKinds: kinds} } type kindByPreferredGroupVersion struct { - list []unversioned.GroupVersionKind - sortOrder []unversioned.GroupVersion + list []schema.GroupVersionKind + sortOrder []schema.GroupVersion } func (o kindByPreferredGroupVersion) Len() int { return len(o.list) } @@ -427,8 +422,8 @@ func (o kindByPreferredGroupVersion) Less(i, j int) bool { } type resourceByPreferredGroupVersion struct { - list []unversioned.GroupVersionResource - sortOrder []unversioned.GroupVersion + list []schema.GroupVersionResource + sortOrder []schema.GroupVersion } func (o resourceByPreferredGroupVersion) Len() int { return len(o.list) } @@ -468,91 +463,56 @@ func (o resourceByPreferredGroupVersion) Less(i, j int) bool { // RESTClient should use to operate on the provided group/kind in order of versions. If a version search // order is not provided, the search order provided to DefaultRESTMapper will be used to resolve which // version should be used to access the named group/kind. -// TODO: consider refactoring to use RESTMappings in a way that preserves version ordering and preference -func (m *DefaultRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...string) (*RESTMapping, error) { - // Pick an appropriate version - var gvk *unversioned.GroupVersionKind +func (m *DefaultRESTMapper) RESTMapping(gk schema.GroupKind, versions ...string) (*RESTMapping, error) { + mappings, err := m.RESTMappings(gk, versions...) + if err != nil { + return nil, err + } + if len(mappings) == 0 { + return nil, &NoKindMatchError{PartialKind: gk.WithVersion("")} + } + // since we rely on RESTMappings method + // take the first match and return to the caller + // as this was the existing behavior. + return mappings[0], nil +} + +// RESTMappings returns the RESTMappings for the provided group kind. If a version search order +// is not provided, the search order provided to DefaultRESTMapper will be used. +func (m *DefaultRESTMapper) RESTMappings(gk schema.GroupKind, versions ...string) ([]*RESTMapping, error) { + mappings := make([]*RESTMapping, 0) + potentialGVK := make([]schema.GroupVersionKind, 0) hadVersion := false + + // Pick an appropriate version for _, version := range versions { if len(version) == 0 || version == runtime.APIVersionInternal { continue } - currGVK := gk.WithVersion(version) hadVersion = true if _, ok := m.kindToPluralResource[currGVK]; ok { - gvk = &currGVK + potentialGVK = append(potentialGVK, currGVK) break } } // Use the default preferred versions - if !hadVersion && (gvk == nil) { + if !hadVersion && len(potentialGVK) == 0 { for _, gv := range m.defaultGroupVersions { if gv.Group != gk.Group { continue } - - currGVK := gk.WithVersion(gv.Version) - if _, ok := m.kindToPluralResource[currGVK]; ok { - gvk = &currGVK - break - } - } - } - if gvk == nil { - return nil, &NoKindMatchError{PartialKind: gk.WithVersion("")} - } - - // Ensure we have a REST mapping - resource, ok := m.kindToPluralResource[*gvk] - if !ok { - found := []unversioned.GroupVersion{} - for _, gv := range m.defaultGroupVersions { - if _, ok := m.kindToPluralResource[*gvk]; ok { - found = append(found, gv) - } - } - if len(found) > 0 { - return nil, fmt.Errorf("object with kind %q exists in versions %v, not %v", gvk.Kind, found, gvk.GroupVersion().String()) + potentialGVK = append(potentialGVK, gk.WithVersion(gv.Version)) } - return nil, fmt.Errorf("the provided version %q and kind %q cannot be mapped to a supported object", gvk.GroupVersion().String(), gvk.Kind) - } - - // Ensure we have a REST scope - scope, ok := m.kindToScope[*gvk] - if !ok { - return nil, fmt.Errorf("the provided version %q and kind %q cannot be mapped to a supported scope", gvk.GroupVersion().String(), gvk.Kind) } - interfaces, err := m.interfacesFunc(gvk.GroupVersion()) - if err != nil { - return nil, fmt.Errorf("the provided version %q has no relevant versions: %v", gvk.GroupVersion().String(), err) - } - - retVal := &RESTMapping{ - Resource: resource.Resource, - GroupVersionKind: *gvk, - Scope: scope, - - ObjectConvertor: interfaces.ObjectConvertor, - MetadataAccessor: interfaces.MetadataAccessor, + if len(potentialGVK) == 0 { + return nil, &NoKindMatchError{PartialKind: gk.WithVersion("")} } - return retVal, nil -} - -// RESTMappings returns the RESTMappings for the provided group kind in a rough internal preferred order. If no -// kind is found it will return a NoResourceMatchError. -func (m *DefaultRESTMapper) RESTMappings(gk unversioned.GroupKind) ([]*RESTMapping, error) { - // Use the default preferred versions - var mappings []*RESTMapping - for _, gv := range m.defaultGroupVersions { - if gv.Group != gk.Group { - continue - } - - gvk := gk.WithVersion(gv.Version) - gvr, ok := m.kindToPluralResource[gvk] + for _, gvk := range potentialGVK { + //Ensure we have a REST mapping + res, ok := m.kindToPluralResource[gvk] if !ok { continue } @@ -569,7 +529,7 @@ func (m *DefaultRESTMapper) RESTMappings(gk unversioned.GroupKind) ([]*RESTMappi } mappings = append(mappings, &RESTMapping{ - Resource: gvr.Resource, + Resource: res.Resource, GroupVersionKind: gvk, Scope: scope, @@ -579,23 +539,7 @@ func (m *DefaultRESTMapper) RESTMappings(gk unversioned.GroupKind) ([]*RESTMappi } if len(mappings) == 0 { - return nil, &NoResourceMatchError{PartialResource: unversioned.GroupVersionResource{Group: gk.Group, Resource: gk.Kind}} + return nil, &NoResourceMatchError{PartialResource: schema.GroupVersionResource{Group: gk.Group, Resource: gk.Kind}} } return mappings, nil } - -// AddResourceAlias maps aliases to resources -func (m *DefaultRESTMapper) AddResourceAlias(alias string, resources ...string) { - if len(resources) == 0 { - return - } - m.aliasToResource[alias] = resources -} - -// AliasesForResource returns whether a resource has an alias or not -func (m *DefaultRESTMapper) AliasesForResource(alias string) ([]string, bool) { - if res, ok := m.aliasToResource[alias]; ok { - return res, true - } - return nil, false -} diff --git a/vendor/k8s.io/client-go/pkg/api/meta/unstructured.go b/vendor/k8s.io/apimachinery/pkg/api/meta/unstructured.go similarity index 71% rename from vendor/k8s.io/client-go/pkg/api/meta/unstructured.go rename to vendor/k8s.io/apimachinery/pkg/api/meta/unstructured.go index cb5a4e35ac..3ebf248157 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/unstructured.go +++ b/vendor/k8s.io/apimachinery/pkg/api/meta/unstructured.go @@ -17,15 +17,15 @@ limitations under the License. package meta import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/apis/meta/v1/unstructured" + "k8s.io/apimachinery/pkg/runtime/schema" ) // InterfacesForUnstructured returns VersionInterfaces suitable for -// dealing with runtime.Unstructured objects. -func InterfacesForUnstructured(unversioned.GroupVersion) (*VersionInterfaces, error) { +// dealing with unstructured.Unstructured objects. +func InterfacesForUnstructured(schema.GroupVersion) (*VersionInterfaces, error) { return &VersionInterfaces{ - ObjectConvertor: &runtime.UnstructuredObjectConverter{}, + ObjectConvertor: &unstructured.UnstructuredObjectConverter{}, MetadataAccessor: NewAccessor(), }, nil } diff --git a/vendor/k8s.io/apimachinery/pkg/api/resource/BUILD b/vendor/k8s.io/apimachinery/pkg/api/resource/BUILD new file mode 100644 index 0000000000..571a6b1e91 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/resource/BUILD @@ -0,0 +1,55 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "amount_test.go", + "math_test.go", + "quantity_proto_test.go", + "quantity_test.go", + "scale_int_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/gopkg.in/inf.v0:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "amount.go", + "generated.pb.go", + "math.go", + "quantity.go", + "quantity_proto.go", + "scale_int.go", + "suffix.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/go-openapi/spec:go_default_library", + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/gopkg.in/inf.v0:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/openapi:go_default_library", + ], +) + +go_test( + name = "go_default_xtest", + srcs = ["quantity_example_test.go"], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library"], +) diff --git a/vendor/k8s.io/apimachinery/pkg/api/resource/OWNERS b/vendor/k8s.io/apimachinery/pkg/api/resource/OWNERS new file mode 100755 index 0000000000..b905e57f0f --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/resource/OWNERS @@ -0,0 +1,17 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- derekwaynecarr +- mikedanese +- saad-ali +- janetkuo +- timstclair +- eparis +- timothysc +- jbeda +- xiang90 +- mbohlool +- david-mcmahon +- goltermann diff --git a/vendor/k8s.io/client-go/pkg/api/resource/amount.go b/vendor/k8s.io/apimachinery/pkg/api/resource/amount.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/api/resource/amount.go rename to vendor/k8s.io/apimachinery/pkg/api/resource/amount.go diff --git a/vendor/k8s.io/apimachinery/pkg/api/resource/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/api/resource/generated.pb.go new file mode 100644 index 0000000000..8b2e338a7e --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/api/resource/generated.pb.go @@ -0,0 +1,77 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/api/resource/generated.proto +// DO NOT EDIT! + +/* + Package resource is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/api/resource/generated.proto + + It has these top-level messages: + Quantity +*/ +package resource + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *Quantity) Reset() { *m = Quantity{} } +func (*Quantity) ProtoMessage() {} +func (*Quantity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func init() { + proto.RegisterType((*Quantity)(nil), "k8s.io.apimachinery.pkg.api.resource.Quantity") +} + +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/api/resource/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 255 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0x8f, 0xa1, 0x4e, 0x03, 0x41, + 0x10, 0x86, 0x77, 0x0d, 0x29, 0x95, 0x0d, 0x21, 0xa4, 0x62, 0xaf, 0x21, 0x08, 0x0c, 0x3b, 0x02, + 0xd3, 0x20, 0xf1, 0x08, 0x90, 0xb8, 0xbb, 0xeb, 0xb0, 0xdd, 0x1c, 0xdd, 0xbd, 0xcc, 0xce, 0x92, + 0xd4, 0x55, 0x22, 0x2b, 0x91, 0xbd, 0xb7, 0xa9, 0xac, 0xac, 0x40, 0x70, 0xcb, 0x8b, 0x90, 0x5e, + 0xdb, 0x84, 0x90, 0xe0, 0xe6, 0xfb, 0x27, 0xdf, 0xe4, 0x9f, 0xfe, 0x43, 0x35, 0x0e, 0xda, 0x7a, + 0xa8, 0x62, 0x81, 0xe4, 0x90, 0x31, 0xc0, 0x1b, 0xba, 0x89, 0x27, 0x38, 0x2c, 0xf2, 0xda, 0xce, + 0xf2, 0x72, 0x6a, 0x1d, 0xd2, 0x1c, 0xea, 0xca, 0xec, 0x02, 0x20, 0x0c, 0x3e, 0x52, 0x89, 0x60, + 0xd0, 0x21, 0xe5, 0x8c, 0x13, 0x5d, 0x93, 0x67, 0x3f, 0xb8, 0xda, 0x5b, 0xfa, 0xb7, 0xa5, 0xeb, + 0xca, 0xec, 0x02, 0x7d, 0xb4, 0x86, 0x37, 0xc6, 0xf2, 0x34, 0x16, 0xba, 0xf4, 0x33, 0x30, 0xde, + 0x78, 0xe8, 0xe4, 0x22, 0xbe, 0x74, 0xd4, 0x41, 0x37, 0xed, 0x8f, 0x0e, 0x6f, 0xff, 0xab, 0x12, + 0xd9, 0xbe, 0x82, 0x75, 0x1c, 0x98, 0xfe, 0x36, 0xb9, 0x1c, 0xf7, 0x7b, 0x8f, 0x31, 0x77, 0x6c, + 0x79, 0x3e, 0x38, 0xef, 0x9f, 0x04, 0x26, 0xeb, 0xcc, 0x85, 0x1c, 0xc9, 0xeb, 0xd3, 0xa7, 0x03, + 0xdd, 0x9d, 0x7d, 0xac, 0x32, 0xf1, 0xde, 0x64, 0x62, 0xd9, 0x64, 0x62, 0xd5, 0x64, 0x62, 0xf1, + 0x39, 0x12, 0xf7, 0x7a, 0xdd, 0x2a, 0xb1, 0x69, 0x95, 0xd8, 0xb6, 0x4a, 0x2c, 0x92, 0x92, 0xeb, + 0xa4, 0xe4, 0x26, 0x29, 0xb9, 0x4d, 0x4a, 0x7e, 0x25, 0x25, 0x97, 0xdf, 0x4a, 0x3c, 0xf7, 0x8e, + 0xdf, 0xfc, 0x04, 0x00, 0x00, 0xff, 0xff, 0x5f, 0x5e, 0xda, 0xf9, 0x43, 0x01, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/api/resource/generated.proto b/vendor/k8s.io/apimachinery/pkg/api/resource/generated.proto similarity index 96% rename from vendor/k8s.io/client-go/pkg/api/resource/generated.proto rename to vendor/k8s.io/apimachinery/pkg/api/resource/generated.proto index c26921d57d..608299da4d 100644 --- a/vendor/k8s.io/client-go/pkg/api/resource/generated.proto +++ b/vendor/k8s.io/apimachinery/pkg/api/resource/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,9 +19,9 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.api.resource; +package k8s.io.apimachinery.pkg.api.resource; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "resource"; diff --git a/vendor/k8s.io/client-go/pkg/api/resource/math.go b/vendor/k8s.io/apimachinery/pkg/api/resource/math.go similarity index 97% rename from vendor/k8s.io/client-go/pkg/api/resource/math.go rename to vendor/k8s.io/apimachinery/pkg/api/resource/math.go index 887ac74c98..72d3880c02 100644 --- a/vendor/k8s.io/client-go/pkg/api/resource/math.go +++ b/vendor/k8s.io/apimachinery/pkg/api/resource/math.go @@ -247,19 +247,6 @@ func pow10Int64(b int64) int64 { } } -// powInt64 raises a to the bth power. Is not overflow aware. -func powInt64(a, b int64) int64 { - p := int64(1) - for b > 0 { - if b&1 != 0 { - p *= a - } - b >>= 1 - a *= a - } - return p -} - // negativeScaleInt64 returns the result of dividing base by scale * 10 and the remainder, or // false if no such division is possible. Dividing by negative scales is undefined. func divideByScaleInt64(base int64, scale Scale) (result, remainder int64, exact bool) { diff --git a/vendor/k8s.io/client-go/pkg/api/resource/quantity.go b/vendor/k8s.io/apimachinery/pkg/api/resource/quantity.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/api/resource/quantity.go rename to vendor/k8s.io/apimachinery/pkg/api/resource/quantity.go index d0a4a4019e..3a95608821 100644 --- a/vendor/k8s.io/client-go/pkg/api/resource/quantity.go +++ b/vendor/k8s.io/apimachinery/pkg/api/resource/quantity.go @@ -29,7 +29,7 @@ import ( "github.com/go-openapi/spec" inf "gopkg.in/inf.v0" - "k8s.io/client-go/pkg/genericapiserver/openapi/common" + "k8s.io/apimachinery/pkg/openapi" ) // Quantity is a fixed-point representation of a number. @@ -399,8 +399,8 @@ func (q Quantity) DeepCopy() Quantity { } // OpenAPIDefinition returns openAPI definition for this type. -func (_ Quantity) OpenAPIDefinition() common.OpenAPIDefinition { - return common.OpenAPIDefinition{ +func (_ Quantity) OpenAPIDefinition() openapi.OpenAPIDefinition { + return openapi.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"string"}, diff --git a/vendor/k8s.io/client-go/pkg/api/resource/quantity_proto.go b/vendor/k8s.io/apimachinery/pkg/api/resource/quantity_proto.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/api/resource/quantity_proto.go rename to vendor/k8s.io/apimachinery/pkg/api/resource/quantity_proto.go diff --git a/vendor/k8s.io/client-go/pkg/api/resource/scale_int.go b/vendor/k8s.io/apimachinery/pkg/api/resource/scale_int.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/api/resource/scale_int.go rename to vendor/k8s.io/apimachinery/pkg/api/resource/scale_int.go diff --git a/vendor/k8s.io/client-go/pkg/api/resource/suffix.go b/vendor/k8s.io/apimachinery/pkg/api/resource/suffix.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/api/resource/suffix.go rename to vendor/k8s.io/apimachinery/pkg/api/resource/suffix.go diff --git a/vendor/k8s.io/apimachinery/pkg/apimachinery/BUILD b/vendor/k8s.io/apimachinery/pkg/apimachinery/BUILD new file mode 100644 index 0000000000..d31194517a --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["types_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "types.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/BUILD b/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/BUILD new file mode 100644 index 0000000000..9c55915a5b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["announced_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "announced.go", + "group_factory.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apimachinery/announced/announced.go b/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/announced.go similarity index 91% rename from vendor/k8s.io/client-go/pkg/apimachinery/announced/announced.go rename to vendor/k8s.io/apimachinery/pkg/apimachinery/announced/announced.go index 90bc100500..2c8568c1f7 100644 --- a/vendor/k8s.io/client-go/pkg/apimachinery/announced/announced.go +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/announced.go @@ -24,16 +24,8 @@ package announced import ( "fmt" - "k8s.io/client-go/pkg/apimachinery/registered" - "k8s.io/client-go/pkg/runtime" -) - -var ( - DefaultGroupFactoryRegistry = make(APIGroupFactoryRegistry) - - // These functions will announce your group or version. - AnnounceGroupVersion = DefaultGroupFactoryRegistry.AnnounceGroupVersion - AnnounceGroup = DefaultGroupFactoryRegistry.AnnounceGroup + "k8s.io/apimachinery/pkg/apimachinery/registered" + "k8s.io/apimachinery/pkg/runtime" ) // APIGroupFactoryRegistry allows for groups and versions to announce themselves, diff --git a/vendor/k8s.io/client-go/pkg/apimachinery/announced/group_factory.go b/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/group_factory.go similarity index 83% rename from vendor/k8s.io/client-go/pkg/apimachinery/announced/group_factory.go rename to vendor/k8s.io/apimachinery/pkg/apimachinery/announced/group_factory.go index 9473ee5694..c469eebcd2 100644 --- a/vendor/k8s.io/client-go/pkg/apimachinery/announced/group_factory.go +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/announced/group_factory.go @@ -21,13 +21,12 @@ import ( "github.com/golang/glog" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/apimachinery" - "k8s.io/client-go/pkg/apimachinery/registered" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/apimachinery" + "k8s.io/apimachinery/pkg/apimachinery/registered" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/sets" ) type SchemeFunc func(*runtime.Scheme) error @@ -43,10 +42,16 @@ type GroupVersionFactoryArgs struct { // GroupMetaFactoryArgs contains the group-level args of a GroupMetaFactory. type GroupMetaFactoryArgs struct { + // GroupName is the name of the API-Group + // + // example: 'servicecatalog.k8s.io' GroupName string VersionPreferenceOrder []string - ImportPrefix string - + // ImportPrefix is the base go package of the API-Group + // + // example: 'k8s.io/kubernetes/pkg/apis/autoscaling' + ImportPrefix string + // RootScopedKinds are resources that are not namespaced. RootScopedKinds sets.String // nil is allowed IgnoredKinds sets.String // nil is allowed @@ -73,14 +78,14 @@ func NewGroupMetaFactory(groupArgs *GroupMetaFactoryArgs, versions VersionToSche // Announce adds this Group factory to the global factory registry. It should // only be called if you constructed the GroupMetaFactory yourself via -// NewGroupMetadFactory. +// NewGroupMetaFactory. // Note that this will panic on an error, since it's expected that you'll be // calling this at initialization time and any error is a result of a // programmer importing the wrong set of packages. If this assumption doesn't // work for you, just call DefaultGroupFactoryRegistry.AnnouncePreconstructedFactory // yourself. -func (gmf *GroupMetaFactory) Announce() *GroupMetaFactory { - if err := DefaultGroupFactoryRegistry.AnnouncePreconstructedFactory(gmf); err != nil { +func (gmf *GroupMetaFactory) Announce(groupFactoryRegistry APIGroupFactoryRegistry) *GroupMetaFactory { + if err := groupFactoryRegistry.AnnouncePreconstructedFactory(gmf); err != nil { panic(err) } return gmf @@ -107,7 +112,7 @@ type GroupMetaFactory struct { VersionArgs map[string]*GroupVersionFactoryArgs // assembled by Register() - prioritizedVersionList []unversioned.GroupVersion + prioritizedVersionList []schema.GroupVersion } // Register constructs the finalized prioritized version list and sanity checks @@ -124,11 +129,11 @@ func (gmf *GroupMetaFactory) Register(m *registered.APIRegistrationManager) erro if pvSet.Len() != len(gmf.GroupArgs.VersionPreferenceOrder) { return fmt.Errorf("preference order for group %v has duplicates: %v", gmf.GroupArgs.GroupName, gmf.GroupArgs.VersionPreferenceOrder) } - prioritizedVersions := []unversioned.GroupVersion{} + prioritizedVersions := []schema.GroupVersion{} for _, v := range gmf.GroupArgs.VersionPreferenceOrder { prioritizedVersions = append( prioritizedVersions, - unversioned.GroupVersion{ + schema.GroupVersion{ Group: gmf.GroupArgs.GroupName, Version: v, }, @@ -136,7 +141,7 @@ func (gmf *GroupMetaFactory) Register(m *registered.APIRegistrationManager) erro } // Go through versions that weren't explicitly prioritized. - unprioritizedVersions := []unversioned.GroupVersion{} + unprioritizedVersions := []schema.GroupVersion{} for _, v := range gmf.VersionArgs { if v.GroupName != gmf.GroupArgs.GroupName { return fmt.Errorf("found %v/%v in group %v?", v.GroupName, v.VersionName, gmf.GroupArgs.GroupName) @@ -145,7 +150,7 @@ func (gmf *GroupMetaFactory) Register(m *registered.APIRegistrationManager) erro pvSet.Delete(v.VersionName) continue } - unprioritizedVersions = append(unprioritizedVersions, unversioned.GroupVersion{Group: v.GroupName, Version: v.VersionName}) + unprioritizedVersions = append(unprioritizedVersions, schema.GroupVersion{Group: v.GroupName, Version: v.VersionName}) } if len(unprioritizedVersions) > 1 { glog.Warningf("group %v has multiple unprioritized versions: %#v. They will have an arbitrary preference order!", gmf.GroupArgs.GroupName, unprioritizedVersions) @@ -159,7 +164,7 @@ func (gmf *GroupMetaFactory) Register(m *registered.APIRegistrationManager) erro return nil } -func (gmf *GroupMetaFactory) newRESTMapper(scheme *runtime.Scheme, externalVersions []unversioned.GroupVersion, groupMeta *apimachinery.GroupMeta) meta.RESTMapper { +func (gmf *GroupMetaFactory) newRESTMapper(scheme *runtime.Scheme, externalVersions []schema.GroupVersion, groupMeta *apimachinery.GroupMeta) meta.RESTMapper { // the list of kinds that are scoped at the root of the api hierarchy // if a kind is not enumerated here, it is assumed to have a namespace scope rootScoped := sets.NewString() @@ -171,7 +176,7 @@ func (gmf *GroupMetaFactory) newRESTMapper(scheme *runtime.Scheme, externalVersi ignoredKinds = gmf.GroupArgs.IgnoredKinds } - return api.NewDefaultRESTMapperFromScheme( + return meta.NewDefaultRESTMapperFromScheme( externalVersions, groupMeta.InterfacesFor, gmf.GroupArgs.ImportPrefix, @@ -183,7 +188,7 @@ func (gmf *GroupMetaFactory) newRESTMapper(scheme *runtime.Scheme, externalVersi // Enable enables group versions that are allowed, adds methods to the scheme, etc. func (gmf *GroupMetaFactory) Enable(m *registered.APIRegistrationManager, scheme *runtime.Scheme) error { - externalVersions := []unversioned.GroupVersion{} + externalVersions := []schema.GroupVersion{} for _, v := range gmf.prioritizedVersionList { if !m.IsAllowedVersion(v) { continue @@ -214,7 +219,7 @@ func (gmf *GroupMetaFactory) Enable(m *registered.APIRegistrationManager, scheme for _, v := range externalVersions { gvf := gmf.VersionArgs[v.Version] if err := groupMeta.AddVersionInterfaces( - unversioned.GroupVersion{Group: gvf.GroupName, Version: gvf.VersionName}, + schema.GroupVersion{Group: gvf.GroupName, Version: gvf.VersionName}, &meta.VersionInterfaces{ ObjectConvertor: scheme, MetadataAccessor: accessor, @@ -235,11 +240,11 @@ func (gmf *GroupMetaFactory) Enable(m *registered.APIRegistrationManager, scheme // RegisterAndEnable is provided only to allow this code to get added in multiple steps. // It's really bad that this is called in init() methods, but supporting this // temporarily lets us do the change incrementally. -func (gmf *GroupMetaFactory) RegisterAndEnable() error { - if err := gmf.Register(registered.DefaultAPIRegistrationManager); err != nil { +func (gmf *GroupMetaFactory) RegisterAndEnable(registry *registered.APIRegistrationManager, scheme *runtime.Scheme) error { + if err := gmf.Register(registry); err != nil { return err } - if err := gmf.Enable(registered.DefaultAPIRegistrationManager, api.Scheme); err != nil { + if err := gmf.Enable(registry, scheme); err != nil { return err } diff --git a/vendor/k8s.io/client-go/pkg/apimachinery/doc.go b/vendor/k8s.io/apimachinery/pkg/apimachinery/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/apimachinery/doc.go rename to vendor/k8s.io/apimachinery/pkg/apimachinery/doc.go diff --git a/vendor/k8s.io/apimachinery/pkg/apimachinery/registered/BUILD b/vendor/k8s.io/apimachinery/pkg/apimachinery/registered/BUILD new file mode 100644 index 0000000000..25dcd3222d --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/registered/BUILD @@ -0,0 +1,33 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["registered_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apimachinery:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["registered.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apimachinery/registered/registered.go b/vendor/k8s.io/apimachinery/pkg/apimachinery/registered/registered.go similarity index 73% rename from vendor/k8s.io/client-go/pkg/apimachinery/registered/registered.go rename to vendor/k8s.io/apimachinery/pkg/apimachinery/registered/registered.go index 887980ea85..f2e32c88cd 100644 --- a/vendor/k8s.io/client-go/pkg/apimachinery/registered/registered.go +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/registered/registered.go @@ -19,20 +19,15 @@ package registered import ( "fmt" - "os" "sort" "strings" "github.com/golang/glog" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/apimachinery" - "k8s.io/client-go/pkg/util/sets" -) - -var ( - DefaultAPIRegistrationManager = NewOrDie(os.Getenv("KUBE_API_VERSIONS")) + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/apimachinery" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/sets" ) // APIRegistrationManager provides the concept of what API groups are enabled. @@ -45,16 +40,16 @@ var ( // isn't easy right now because there are so many callers of this package. type APIRegistrationManager struct { // registeredGroupVersions stores all API group versions for which RegisterGroup is called. - registeredVersions map[unversioned.GroupVersion]struct{} + registeredVersions map[schema.GroupVersion]struct{} // thirdPartyGroupVersions are API versions which are dynamically // registered (and unregistered) via API calls to the apiserver - thirdPartyGroupVersions []unversioned.GroupVersion + thirdPartyGroupVersions []schema.GroupVersion // enabledVersions represents all enabled API versions. It should be a // subset of registeredVersions. Please call EnableVersions() to add // enabled versions. - enabledVersions map[unversioned.GroupVersion]struct{} + enabledVersions map[schema.GroupVersion]struct{} // map of group meta for all groups. groupMetaMap map[string]*apimachinery.GroupMeta @@ -63,7 +58,7 @@ type APIRegistrationManager struct { // KUBE_API_VERSIONS environment variable. The install package of each group // checks this list before add their versions to the latest package and // Scheme. This list is small and order matters, so represent as a slice - envRequestedVersions []unversioned.GroupVersion + envRequestedVersions []schema.GroupVersion } // NewAPIRegistrationManager constructs a new manager. The argument ought to be @@ -71,16 +66,16 @@ type APIRegistrationManager struct { // wish to test. func NewAPIRegistrationManager(kubeAPIVersions string) (*APIRegistrationManager, error) { m := &APIRegistrationManager{ - registeredVersions: map[unversioned.GroupVersion]struct{}{}, - thirdPartyGroupVersions: []unversioned.GroupVersion{}, - enabledVersions: map[unversioned.GroupVersion]struct{}{}, + registeredVersions: map[schema.GroupVersion]struct{}{}, + thirdPartyGroupVersions: []schema.GroupVersion{}, + enabledVersions: map[schema.GroupVersion]struct{}{}, groupMetaMap: map[string]*apimachinery.GroupMeta{}, - envRequestedVersions: []unversioned.GroupVersion{}, + envRequestedVersions: []schema.GroupVersion{}, } if len(kubeAPIVersions) != 0 { for _, version := range strings.Split(kubeAPIVersions, ",") { - gv, err := unversioned.ParseGroupVersion(version) + gv, err := schema.ParseGroupVersion(version) if err != nil { return nil, fmt.Errorf("invalid api version: %s in KUBE_API_VERSIONS: %s.", version, kubeAPIVersions) @@ -99,30 +94,8 @@ func NewOrDie(kubeAPIVersions string) *APIRegistrationManager { return m } -// People are calling global functions. Let them continue to do that (for now). -var ( - ValidateEnvRequestedVersions = DefaultAPIRegistrationManager.ValidateEnvRequestedVersions - AllPreferredGroupVersions = DefaultAPIRegistrationManager.AllPreferredGroupVersions - RESTMapper = DefaultAPIRegistrationManager.RESTMapper - GroupOrDie = DefaultAPIRegistrationManager.GroupOrDie - AddThirdPartyAPIGroupVersions = DefaultAPIRegistrationManager.AddThirdPartyAPIGroupVersions - IsThirdPartyAPIGroupVersion = DefaultAPIRegistrationManager.IsThirdPartyAPIGroupVersion - RegisteredGroupVersions = DefaultAPIRegistrationManager.RegisteredGroupVersions - IsRegisteredVersion = DefaultAPIRegistrationManager.IsRegisteredVersion - IsRegistered = DefaultAPIRegistrationManager.IsRegistered - Group = DefaultAPIRegistrationManager.Group - EnabledVersionsForGroup = DefaultAPIRegistrationManager.EnabledVersionsForGroup - EnabledVersions = DefaultAPIRegistrationManager.EnabledVersions - IsEnabledVersion = DefaultAPIRegistrationManager.IsEnabledVersion - IsAllowedVersion = DefaultAPIRegistrationManager.IsAllowedVersion - EnableVersions = DefaultAPIRegistrationManager.EnableVersions - RegisterGroup = DefaultAPIRegistrationManager.RegisterGroup - RegisterVersions = DefaultAPIRegistrationManager.RegisterVersions - InterfacesFor = DefaultAPIRegistrationManager.InterfacesFor -) - // RegisterVersions adds the given group versions to the list of registered group versions. -func (m *APIRegistrationManager) RegisterVersions(availableVersions []unversioned.GroupVersion) { +func (m *APIRegistrationManager) RegisterVersions(availableVersions []schema.GroupVersion) { for _, v := range availableVersions { m.registeredVersions[v] = struct{}{} } @@ -132,7 +105,7 @@ func (m *APIRegistrationManager) RegisterVersions(availableVersions []unversione func (m *APIRegistrationManager) RegisterGroup(groupMeta apimachinery.GroupMeta) error { groupName := groupMeta.GroupVersion.Group if _, found := m.groupMetaMap[groupName]; found { - return fmt.Errorf("group %v is already registered", m.groupMetaMap) + return fmt.Errorf("group %q is already registered in groupsMap: %v", groupName, m.groupMetaMap) } m.groupMetaMap[groupName] = &groupMeta return nil @@ -141,8 +114,8 @@ func (m *APIRegistrationManager) RegisterGroup(groupMeta apimachinery.GroupMeta) // EnableVersions adds the versions for the given group to the list of enabled versions. // Note that the caller should call RegisterGroup before calling this method. // The caller of this function is responsible to add the versions to scheme and RESTMapper. -func (m *APIRegistrationManager) EnableVersions(versions ...unversioned.GroupVersion) error { - var unregisteredVersions []unversioned.GroupVersion +func (m *APIRegistrationManager) EnableVersions(versions ...schema.GroupVersion) error { + var unregisteredVersions []schema.GroupVersion for _, v := range versions { if _, found := m.registeredVersions[v]; !found { unregisteredVersions = append(unregisteredVersions, v) @@ -158,7 +131,7 @@ func (m *APIRegistrationManager) EnableVersions(versions ...unversioned.GroupVer // IsAllowedVersion returns if the version is allowed by the KUBE_API_VERSIONS // environment variable. If the environment variable is empty, then it always // returns true. -func (m *APIRegistrationManager) IsAllowedVersion(v unversioned.GroupVersion) bool { +func (m *APIRegistrationManager) IsAllowedVersion(v schema.GroupVersion) bool { if len(m.envRequestedVersions) == 0 { return true } @@ -171,15 +144,15 @@ func (m *APIRegistrationManager) IsAllowedVersion(v unversioned.GroupVersion) bo } // IsEnabledVersion returns if a version is enabled. -func (m *APIRegistrationManager) IsEnabledVersion(v unversioned.GroupVersion) bool { +func (m *APIRegistrationManager) IsEnabledVersion(v schema.GroupVersion) bool { _, found := m.enabledVersions[v] return found } // EnabledVersions returns all enabled versions. Groups are randomly ordered, but versions within groups // are priority order from best to worst -func (m *APIRegistrationManager) EnabledVersions() []unversioned.GroupVersion { - ret := []unversioned.GroupVersion{} +func (m *APIRegistrationManager) EnabledVersions() []schema.GroupVersion { + ret := []schema.GroupVersion{} for _, groupMeta := range m.groupMetaMap { for _, version := range groupMeta.GroupVersions { if m.IsEnabledVersion(version) { @@ -191,13 +164,13 @@ func (m *APIRegistrationManager) EnabledVersions() []unversioned.GroupVersion { } // EnabledVersionsForGroup returns all enabled versions for a group in order of best to worst -func (m *APIRegistrationManager) EnabledVersionsForGroup(group string) []unversioned.GroupVersion { +func (m *APIRegistrationManager) EnabledVersionsForGroup(group string) []schema.GroupVersion { groupMeta, ok := m.groupMetaMap[group] if !ok { - return []unversioned.GroupVersion{} + return []schema.GroupVersion{} } - ret := []unversioned.GroupVersion{} + ret := []schema.GroupVersion{} for _, version := range groupMeta.GroupVersions { if m.IsEnabledVersion(version) { ret = append(ret, version) @@ -224,14 +197,14 @@ func (m *APIRegistrationManager) IsRegistered(group string) bool { } // IsRegisteredVersion returns if a version is registered. -func (m *APIRegistrationManager) IsRegisteredVersion(v unversioned.GroupVersion) bool { +func (m *APIRegistrationManager) IsRegisteredVersion(v schema.GroupVersion) bool { _, found := m.registeredVersions[v] return found } // RegisteredGroupVersions returns all registered group versions. -func (m *APIRegistrationManager) RegisteredGroupVersions() []unversioned.GroupVersion { - ret := []unversioned.GroupVersion{} +func (m *APIRegistrationManager) RegisteredGroupVersions() []schema.GroupVersion { + ret := []schema.GroupVersion{} for groupVersion := range m.registeredVersions { ret = append(ret, groupVersion) } @@ -239,7 +212,7 @@ func (m *APIRegistrationManager) RegisteredGroupVersions() []unversioned.GroupVe } // IsThirdPartyAPIGroupVersion returns true if the api version is a user-registered group/version. -func (m *APIRegistrationManager) IsThirdPartyAPIGroupVersion(gv unversioned.GroupVersion) bool { +func (m *APIRegistrationManager) IsThirdPartyAPIGroupVersion(gv schema.GroupVersion) bool { for ix := range m.thirdPartyGroupVersions { if m.thirdPartyGroupVersions[ix] == gv { return true @@ -252,9 +225,9 @@ func (m *APIRegistrationManager) IsThirdPartyAPIGroupVersion(gv unversioned.Grou // registers them in the API machinery and enables them. // Skips GroupVersions that are already registered. // Returns the list of GroupVersions that were skipped. -func (m *APIRegistrationManager) AddThirdPartyAPIGroupVersions(gvs ...unversioned.GroupVersion) []unversioned.GroupVersion { - filteredGVs := []unversioned.GroupVersion{} - skippedGVs := []unversioned.GroupVersion{} +func (m *APIRegistrationManager) AddThirdPartyAPIGroupVersions(gvs ...schema.GroupVersion) []schema.GroupVersion { + filteredGVs := []schema.GroupVersion{} + skippedGVs := []schema.GroupVersion{} for ix := range gvs { if !m.IsRegisteredVersion(gvs[ix]) { filteredGVs = append(filteredGVs, gvs[ix]) @@ -274,7 +247,7 @@ func (m *APIRegistrationManager) AddThirdPartyAPIGroupVersions(gvs ...unversione } // InterfacesFor is a union meta.VersionInterfacesFunc func for all registered types -func (m *APIRegistrationManager) InterfacesFor(version unversioned.GroupVersion) (*meta.VersionInterfaces, error) { +func (m *APIRegistrationManager) InterfacesFor(version schema.GroupVersion) (*meta.VersionInterfaces, error) { groupMeta, err := m.Group(version.Group) if err != nil { return nil, err @@ -303,7 +276,7 @@ func (m *APIRegistrationManager) GroupOrDie(group string) *apimachinery.GroupMet // 1. legacy kube group preferred version, extensions preferred version, metrics perferred version, legacy // kube any version, extensions any version, metrics any version, all other groups alphabetical preferred version, // all other groups alphabetical. -func (m *APIRegistrationManager) RESTMapper(versionPatterns ...unversioned.GroupVersion) meta.RESTMapper { +func (m *APIRegistrationManager) RESTMapper(versionPatterns ...schema.GroupVersion) meta.RESTMapper { unionMapper := meta.MultiRESTMapper{} unionedGroups := sets.NewString() for enabledVersion := range m.enabledVersions { @@ -315,8 +288,8 @@ func (m *APIRegistrationManager) RESTMapper(versionPatterns ...unversioned.Group } if len(versionPatterns) != 0 { - resourcePriority := []unversioned.GroupVersionResource{} - kindPriority := []unversioned.GroupVersionKind{} + resourcePriority := []schema.GroupVersionResource{} + kindPriority := []schema.GroupVersionKind{} for _, versionPriority := range versionPatterns { resourcePriority = append(resourcePriority, versionPriority.WithResource(meta.AnyResource)) kindPriority = append(kindPriority, versionPriority.WithKind(meta.AnyKind)) @@ -326,8 +299,8 @@ func (m *APIRegistrationManager) RESTMapper(versionPatterns ...unversioned.Group } if len(m.envRequestedVersions) != 0 { - resourcePriority := []unversioned.GroupVersionResource{} - kindPriority := []unversioned.GroupVersionKind{} + resourcePriority := []schema.GroupVersionResource{} + kindPriority := []schema.GroupVersionKind{} for _, versionPriority := range m.envRequestedVersions { resourcePriority = append(resourcePriority, versionPriority.WithResource(meta.AnyResource)) @@ -357,9 +330,9 @@ func (m *APIRegistrationManager) RESTMapper(versionPatterns ...unversioned.Group // prioritiesForGroups returns the resource and kind priorities for a PriorityRESTMapper, preferring the preferred version of each group first, // then any non-preferred version of the group second. -func (m *APIRegistrationManager) prioritiesForGroups(groups ...string) ([]unversioned.GroupVersionResource, []unversioned.GroupVersionKind) { - resourcePriority := []unversioned.GroupVersionResource{} - kindPriority := []unversioned.GroupVersionKind{} +func (m *APIRegistrationManager) prioritiesForGroups(groups ...string) ([]schema.GroupVersionResource, []schema.GroupVersionKind) { + resourcePriority := []schema.GroupVersionResource{} + kindPriority := []schema.GroupVersionKind{} for _, group := range groups { availableVersions := m.EnabledVersionsForGroup(group) @@ -369,8 +342,8 @@ func (m *APIRegistrationManager) prioritiesForGroups(groups ...string) ([]unvers } } for _, group := range groups { - resourcePriority = append(resourcePriority, unversioned.GroupVersionResource{Group: group, Version: meta.AnyVersion, Resource: meta.AnyResource}) - kindPriority = append(kindPriority, unversioned.GroupVersionKind{Group: group, Version: meta.AnyVersion, Kind: meta.AnyKind}) + resourcePriority = append(resourcePriority, schema.GroupVersionResource{Group: group, Version: meta.AnyVersion, Resource: meta.AnyResource}) + kindPriority = append(kindPriority, schema.GroupVersionKind{Group: group, Version: meta.AnyVersion, Kind: meta.AnyKind}) } return resourcePriority, kindPriority @@ -392,8 +365,8 @@ func (m *APIRegistrationManager) AllPreferredGroupVersions() string { // ValidateEnvRequestedVersions returns a list of versions that are requested in // the KUBE_API_VERSIONS environment variable, but not enabled. -func (m *APIRegistrationManager) ValidateEnvRequestedVersions() []unversioned.GroupVersion { - var missingVersions []unversioned.GroupVersion +func (m *APIRegistrationManager) ValidateEnvRequestedVersions() []schema.GroupVersion { + var missingVersions []schema.GroupVersion for _, v := range m.envRequestedVersions { if _, found := m.enabledVersions[v]; !found { missingVersions = append(missingVersions, v) diff --git a/vendor/k8s.io/client-go/pkg/apimachinery/types.go b/vendor/k8s.io/apimachinery/pkg/apimachinery/types.go similarity index 75% rename from vendor/k8s.io/client-go/pkg/apimachinery/types.go rename to vendor/k8s.io/apimachinery/pkg/apimachinery/types.go index f520a1572c..213e34bc00 100644 --- a/vendor/k8s.io/client-go/pkg/apimachinery/types.go +++ b/vendor/k8s.io/apimachinery/pkg/apimachinery/types.go @@ -19,24 +19,18 @@ package apimachinery import ( "fmt" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupMeta stores the metadata of a group. type GroupMeta struct { // GroupVersion represents the preferred version of the group. - GroupVersion unversioned.GroupVersion + GroupVersion schema.GroupVersion // GroupVersions is Group + all versions in that group. - GroupVersions []unversioned.GroupVersion - - // Codec is the default codec for serializing output that should use - // the preferred version. Use this Codec when writing to - // disk, a data store that is not dynamically versioned, or in tests. - // This codec can decode any object that the schema is aware of. - Codec runtime.Codec + GroupVersions []schema.GroupVersion // SelfLinker can set or get the SelfLink field of all API types. // TODO: when versioning changes, make this part of each API definition. @@ -52,16 +46,16 @@ type GroupMeta struct { // string, or an error if the version is not known. // TODO: make this stop being a func pointer and always use the default // function provided below once every place that populates this field has been changed. - InterfacesFor func(version unversioned.GroupVersion) (*meta.VersionInterfaces, error) + InterfacesFor func(version schema.GroupVersion) (*meta.VersionInterfaces, error) // InterfacesByVersion stores the per-version interfaces. - InterfacesByVersion map[unversioned.GroupVersion]*meta.VersionInterfaces + InterfacesByVersion map[schema.GroupVersion]*meta.VersionInterfaces } // DefaultInterfacesFor returns the default Codec and ResourceVersioner for a given version // string, or an error if the version is not known. // TODO: Remove the "Default" prefix. -func (gm *GroupMeta) DefaultInterfacesFor(version unversioned.GroupVersion) (*meta.VersionInterfaces, error) { +func (gm *GroupMeta) DefaultInterfacesFor(version schema.GroupVersion) (*meta.VersionInterfaces, error) { if v, ok := gm.InterfacesByVersion[version]; ok { return v, nil } @@ -73,12 +67,12 @@ func (gm *GroupMeta) DefaultInterfacesFor(version unversioned.GroupVersion) (*me // (If you use this, be sure to set .InterfacesFor = .DefaultInterfacesFor) // TODO: remove the "Interfaces" suffix and make this also maintain the // .GroupVersions member. -func (gm *GroupMeta) AddVersionInterfaces(version unversioned.GroupVersion, interfaces *meta.VersionInterfaces) error { +func (gm *GroupMeta) AddVersionInterfaces(version schema.GroupVersion, interfaces *meta.VersionInterfaces) error { if e, a := gm.GroupVersion.Group, version.Group; a != e { return fmt.Errorf("got a version in group %v, but am in group %v", a, e) } if gm.InterfacesByVersion == nil { - gm.InterfacesByVersion = make(map[unversioned.GroupVersion]*meta.VersionInterfaces) + gm.InterfacesByVersion = make(map[schema.GroupVersion]*meta.VersionInterfaces) } gm.InterfacesByVersion[version] = interfaces diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD new file mode 100644 index 0000000000..2ce980fa75 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/BUILD @@ -0,0 +1,71 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "duration_test.go", + "group_version_test.go", + "helpers_test.go", + "labels_test.go", + "micro_time_test.go", + "time_test.go", + "types_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/ghodss/yaml:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "doc.go", + "duration.go", + "generated.pb.go", + "group_version.go", + "helpers.go", + "labels.go", + "meta.go", + "micro_time.go", + "micro_time_proto.go", + "register.go", + "time.go", + "time_proto.go", + "types.go", + "types_swagger_doc_generated.go", + "watch.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/go-openapi/spec:go_default_library", + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/openapi:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/selection:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + ], +) diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/OWNERS b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/OWNERS new file mode 100755 index 0000000000..381a525094 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/OWNERS @@ -0,0 +1,33 @@ +reviewers: +- thockin +- smarterclayton +- wojtek-t +- deads2k +- brendandburns +- caesarxuchao +- liggitt +- nikhiljindal +- gmarek +- erictune +- davidopp +- sttts +- quinton-hoole +- kargakis +- luxas +- janetkuo +- justinsb +- ncdc +- timothysc +- soltysh +- dims +- madhusudancs +- hongchaodeng +- krousey +- mml +- mbohlool +- david-mcmahon +- therc +- mqliang +- kevin-wangzefeng +- jianhuiz +- feihujiang diff --git a/vendor/k8s.io/client-go/pkg/api/conversion.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/conversion.go similarity index 77% rename from vendor/k8s.io/client-go/pkg/api/conversion.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/conversion.go index 3ff0a15825..b9a8fd02d5 100644 --- a/vendor/k8s.io/client-go/pkg/api/conversion.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/conversion.go @@ -14,25 +14,24 @@ See the License for the specific language governing permissions and limitations under the License. */ -package api +package v1 import ( "fmt" - - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/intstr" - utillabels "k8s.io/client-go/pkg/util/labels" - "k8s.io/client-go/pkg/util/validation/field" + "strconv" + "strings" + + "k8s.io/apimachinery/pkg/api/resource" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" ) -func addConversionFuncs(scheme *runtime.Scheme) error { +func AddConversionFuncs(scheme *runtime.Scheme) error { return scheme.AddConversionFuncs( - Convert_unversioned_TypeMeta_To_unversioned_TypeMeta, + Convert_v1_TypeMeta_To_v1_TypeMeta, Convert_unversioned_ListMeta_To_unversioned_ListMeta, @@ -67,6 +66,8 @@ func addConversionFuncs(scheme *runtime.Scheme) error { Convert_map_to_unversioned_LabelSelector, Convert_unversioned_LabelSelector_to_map, + + Convert_Slice_string_To_Slice_int32, ) } @@ -154,7 +155,7 @@ func Convert_bool_To_Pointer_bool(in *bool, out **bool, s conversion.Scope) erro } // +k8s:conversion-fn=drop -func Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(in, out *unversioned.TypeMeta, s conversion.Scope) error { +func Convert_v1_TypeMeta_To_v1_TypeMeta(in, out *TypeMeta, s conversion.Scope) error { // These values are explicitly not copied //out.APIVersion = in.APIVersion //out.Kind = in.Kind @@ -162,7 +163,7 @@ func Convert_unversioned_TypeMeta_To_unversioned_TypeMeta(in, out *unversioned.T } // +k8s:conversion-fn=copy-only -func Convert_unversioned_ListMeta_To_unversioned_ListMeta(in, out *unversioned.ListMeta, s conversion.Scope) error { +func Convert_unversioned_ListMeta_To_unversioned_ListMeta(in, out *ListMeta, s conversion.Scope) error { *out = *in return nil } @@ -174,14 +175,14 @@ func Convert_intstr_IntOrString_To_intstr_IntOrString(in, out *intstr.IntOrStrin } // +k8s:conversion-fn=copy-only -func Convert_unversioned_Time_To_unversioned_Time(in *unversioned.Time, out *unversioned.Time, s conversion.Scope) error { +func Convert_unversioned_Time_To_unversioned_Time(in *Time, out *Time, s conversion.Scope) error { // Cannot deep copy these, because time.Time has unexported fields. *out = *in return nil } // Convert_Slice_string_To_unversioned_Time allows converting a URL query parameter value -func Convert_Slice_string_To_unversioned_Time(input *[]string, out *unversioned.Time, s conversion.Scope) error { +func Convert_Slice_string_To_unversioned_Time(input *[]string, out *Time, s conversion.Scope) error { str := "" if len(*input) > 0 { str = (*input)[0] @@ -229,22 +230,35 @@ func Convert_resource_Quantity_To_resource_Quantity(in *resource.Quantity, out * return nil } -func Convert_map_to_unversioned_LabelSelector(in *map[string]string, out *unversioned.LabelSelector, s conversion.Scope) error { +func Convert_map_to_unversioned_LabelSelector(in *map[string]string, out *LabelSelector, s conversion.Scope) error { if in == nil { return nil } - out = new(unversioned.LabelSelector) + out = new(LabelSelector) for labelKey, labelValue := range *in { - utillabels.AddLabelToSelector(out, labelKey, labelValue) + AddLabelToSelector(out, labelKey, labelValue) } return nil } -func Convert_unversioned_LabelSelector_to_map(in *unversioned.LabelSelector, out *map[string]string, s conversion.Scope) error { +func Convert_unversioned_LabelSelector_to_map(in *LabelSelector, out *map[string]string, s conversion.Scope) error { var err error - *out, err = unversioned.LabelSelectorAsMap(in) - if err != nil { - err = field.Invalid(field.NewPath("labelSelector"), *in, fmt.Sprintf("cannot convert to old selector: %v", err)) - } + *out, err = LabelSelectorAsMap(in) return err } + +// Convert_Slice_string_To_Slice_int32 converts multiple query parameters or +// a single query parameter with a comma delimited value to multiple int32. +// This is used for port forwarding which needs the ports as int32. +func Convert_Slice_string_To_Slice_int32(in *[]string, out *[]int32, s conversion.Scope) error { + for _, s := range *in { + for _, v := range strings.Split(s, ",") { + x, err := strconv.ParseUint(v, 10, 16) + if err != nil { + return fmt.Errorf("cannot convert to []int32: %v", err) + } + *out = append(*out, int32(x)) + } + } + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/doc.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/doc.go similarity index 94% rename from vendor/k8s.io/client-go/pkg/api/unversioned/doc.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/doc.go index 720c686a90..52273240f0 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/doc.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/doc.go @@ -18,4 +18,5 @@ limitations under the License. // +k8s:openapi-gen=true // +k8s:defaulter-gen=TypeMeta -package unversioned +// +groupName=meta.k8s.io +package v1 diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/duration.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/duration.go similarity index 98% rename from vendor/k8s.io/client-go/pkg/api/unversioned/duration.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/duration.go index ed54e515da..fea458dfb3 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/duration.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/duration.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package unversioned +package v1 import ( "encoding/json" diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go new file mode 100644 index 0000000000..9e2b289da1 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.pb.go @@ -0,0 +1,7516 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto + + It has these top-level messages: + APIGroup + APIGroupList + APIResource + APIResourceList + APIVersions + DeleteOptions + Duration + ExportOptions + GetOptions + GroupKind + GroupResource + GroupVersion + GroupVersionForDiscovery + GroupVersionKind + GroupVersionResource + Initializer + Initializers + LabelSelector + LabelSelectorRequirement + ListMeta + ListOptions + MicroTime + ObjectMeta + OwnerReference + Preconditions + RootPaths + ServerAddressByClientCIDR + Status + StatusCause + StatusDetails + Time + Timestamp + TypeMeta + Verbs + WatchEvent +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import time "time" +import k8s_io_apimachinery_pkg_types "k8s.io/apimachinery/pkg/types" + +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf +var _ = time.Kitchen + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *APIGroup) Reset() { *m = APIGroup{} } +func (*APIGroup) ProtoMessage() {} +func (*APIGroup) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *APIGroupList) Reset() { *m = APIGroupList{} } +func (*APIGroupList) ProtoMessage() {} +func (*APIGroupList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *APIResource) Reset() { *m = APIResource{} } +func (*APIResource) ProtoMessage() {} +func (*APIResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *APIResourceList) Reset() { *m = APIResourceList{} } +func (*APIResourceList) ProtoMessage() {} +func (*APIResourceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *APIVersions) Reset() { *m = APIVersions{} } +func (*APIVersions) ProtoMessage() {} +func (*APIVersions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *DeleteOptions) Reset() { *m = DeleteOptions{} } +func (*DeleteOptions) ProtoMessage() {} +func (*DeleteOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func (m *Duration) Reset() { *m = Duration{} } +func (*Duration) ProtoMessage() {} +func (*Duration) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } + +func (m *ExportOptions) Reset() { *m = ExportOptions{} } +func (*ExportOptions) ProtoMessage() {} +func (*ExportOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *GetOptions) Reset() { *m = GetOptions{} } +func (*GetOptions) ProtoMessage() {} +func (*GetOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *GroupKind) Reset() { *m = GroupKind{} } +func (*GroupKind) ProtoMessage() {} +func (*GroupKind) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func (m *GroupResource) Reset() { *m = GroupResource{} } +func (*GroupResource) ProtoMessage() {} +func (*GroupResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } + +func (m *GroupVersion) Reset() { *m = GroupVersion{} } +func (*GroupVersion) ProtoMessage() {} +func (*GroupVersion) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } + +func (m *GroupVersionForDiscovery) Reset() { *m = GroupVersionForDiscovery{} } +func (*GroupVersionForDiscovery) ProtoMessage() {} +func (*GroupVersionForDiscovery) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{12} +} + +func (m *GroupVersionKind) Reset() { *m = GroupVersionKind{} } +func (*GroupVersionKind) ProtoMessage() {} +func (*GroupVersionKind) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } + +func (m *GroupVersionResource) Reset() { *m = GroupVersionResource{} } +func (*GroupVersionResource) ProtoMessage() {} +func (*GroupVersionResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } + +func (m *Initializer) Reset() { *m = Initializer{} } +func (*Initializer) ProtoMessage() {} +func (*Initializer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } + +func (m *Initializers) Reset() { *m = Initializers{} } +func (*Initializers) ProtoMessage() {} +func (*Initializers) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } + +func (m *LabelSelector) Reset() { *m = LabelSelector{} } +func (*LabelSelector) ProtoMessage() {} +func (*LabelSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } + +func (m *LabelSelectorRequirement) Reset() { *m = LabelSelectorRequirement{} } +func (*LabelSelectorRequirement) ProtoMessage() {} +func (*LabelSelectorRequirement) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{18} +} + +func (m *ListMeta) Reset() { *m = ListMeta{} } +func (*ListMeta) ProtoMessage() {} +func (*ListMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{19} } + +func (m *ListOptions) Reset() { *m = ListOptions{} } +func (*ListOptions) ProtoMessage() {} +func (*ListOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } + +func (m *MicroTime) Reset() { *m = MicroTime{} } +func (*MicroTime) ProtoMessage() {} +func (*MicroTime) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } + +func (m *ObjectMeta) Reset() { *m = ObjectMeta{} } +func (*ObjectMeta) ProtoMessage() {} +func (*ObjectMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{22} } + +func (m *OwnerReference) Reset() { *m = OwnerReference{} } +func (*OwnerReference) ProtoMessage() {} +func (*OwnerReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } + +func (m *Preconditions) Reset() { *m = Preconditions{} } +func (*Preconditions) ProtoMessage() {} +func (*Preconditions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{24} } + +func (m *RootPaths) Reset() { *m = RootPaths{} } +func (*RootPaths) ProtoMessage() {} +func (*RootPaths) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{25} } + +func (m *ServerAddressByClientCIDR) Reset() { *m = ServerAddressByClientCIDR{} } +func (*ServerAddressByClientCIDR) ProtoMessage() {} +func (*ServerAddressByClientCIDR) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{26} +} + +func (m *Status) Reset() { *m = Status{} } +func (*Status) ProtoMessage() {} +func (*Status) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } + +func (m *StatusCause) Reset() { *m = StatusCause{} } +func (*StatusCause) ProtoMessage() {} +func (*StatusCause) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{28} } + +func (m *StatusDetails) Reset() { *m = StatusDetails{} } +func (*StatusDetails) ProtoMessage() {} +func (*StatusDetails) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } + +func (m *Time) Reset() { *m = Time{} } +func (*Time) ProtoMessage() {} +func (*Time) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } + +func (m *Timestamp) Reset() { *m = Timestamp{} } +func (*Timestamp) ProtoMessage() {} +func (*Timestamp) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{31} } + +func (m *TypeMeta) Reset() { *m = TypeMeta{} } +func (*TypeMeta) ProtoMessage() {} +func (*TypeMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } + +func (m *Verbs) Reset() { *m = Verbs{} } +func (*Verbs) ProtoMessage() {} +func (*Verbs) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } + +func (m *WatchEvent) Reset() { *m = WatchEvent{} } +func (*WatchEvent) ProtoMessage() {} +func (*WatchEvent) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{34} } + +func init() { + proto.RegisterType((*APIGroup)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.APIGroup") + proto.RegisterType((*APIGroupList)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.APIGroupList") + proto.RegisterType((*APIResource)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.APIResource") + proto.RegisterType((*APIResourceList)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.APIResourceList") + proto.RegisterType((*APIVersions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.APIVersions") + proto.RegisterType((*DeleteOptions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.DeleteOptions") + proto.RegisterType((*Duration)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Duration") + proto.RegisterType((*ExportOptions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ExportOptions") + proto.RegisterType((*GetOptions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GetOptions") + proto.RegisterType((*GroupKind)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GroupKind") + proto.RegisterType((*GroupResource)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GroupResource") + proto.RegisterType((*GroupVersion)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GroupVersion") + proto.RegisterType((*GroupVersionForDiscovery)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GroupVersionForDiscovery") + proto.RegisterType((*GroupVersionKind)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GroupVersionKind") + proto.RegisterType((*GroupVersionResource)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.GroupVersionResource") + proto.RegisterType((*Initializer)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Initializer") + proto.RegisterType((*Initializers)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Initializers") + proto.RegisterType((*LabelSelector)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector") + proto.RegisterType((*LabelSelectorRequirement)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelectorRequirement") + proto.RegisterType((*ListMeta)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta") + proto.RegisterType((*ListOptions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ListOptions") + proto.RegisterType((*MicroTime)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.MicroTime") + proto.RegisterType((*ObjectMeta)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta") + proto.RegisterType((*OwnerReference)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference") + proto.RegisterType((*Preconditions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Preconditions") + proto.RegisterType((*RootPaths)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.RootPaths") + proto.RegisterType((*ServerAddressByClientCIDR)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.ServerAddressByClientCIDR") + proto.RegisterType((*Status)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Status") + proto.RegisterType((*StatusCause)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.StatusCause") + proto.RegisterType((*StatusDetails)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.StatusDetails") + proto.RegisterType((*Time)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Time") + proto.RegisterType((*Timestamp)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Timestamp") + proto.RegisterType((*TypeMeta)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.TypeMeta") + proto.RegisterType((*Verbs)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.Verbs") + proto.RegisterType((*WatchEvent)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1.WatchEvent") +} +func (m *APIGroup) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *APIGroup) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if len(m.Versions) > 0 { + for _, msg := range m.Versions { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PreferredVersion.Size())) + n1, err := m.PreferredVersion.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + if len(m.ServerAddressByClientCIDRs) > 0 { + for _, msg := range m.ServerAddressByClientCIDRs { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *APIGroupList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *APIGroupList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Groups) > 0 { + for _, msg := range m.Groups { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *APIResource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *APIResource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x10 + i++ + if m.Namespaced { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + if m.Verbs != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Verbs.Size())) + n2, err := m.Verbs.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + } + if len(m.ShortNames) > 0 { + for _, s := range m.ShortNames { + dAtA[i] = 0x2a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SingularName))) + i += copy(dAtA[i:], m.SingularName) + if len(m.Categories) > 0 { + for _, s := range m.Categories { + dAtA[i] = 0x3a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *APIResourceList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *APIResourceList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.GroupVersion))) + i += copy(dAtA[i:], m.GroupVersion) + if len(m.APIResources) > 0 { + for _, msg := range m.APIResources { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *APIVersions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *APIVersions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Versions) > 0 { + for _, s := range m.Versions { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.ServerAddressByClientCIDRs) > 0 { + for _, msg := range m.ServerAddressByClientCIDRs { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *DeleteOptions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DeleteOptions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.GracePeriodSeconds != nil { + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.GracePeriodSeconds)) + } + if m.Preconditions != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Preconditions.Size())) + n3, err := m.Preconditions.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + } + if m.OrphanDependents != nil { + dAtA[i] = 0x18 + i++ + if *m.OrphanDependents { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + if m.PropagationPolicy != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.PropagationPolicy))) + i += copy(dAtA[i:], *m.PropagationPolicy) + } + return i, nil +} + +func (m *Duration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Duration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Duration)) + return i, nil +} + +func (m *ExportOptions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExportOptions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + if m.Export { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + dAtA[i] = 0x10 + i++ + if m.Exact { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + return i, nil +} + +func (m *GetOptions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetOptions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) + dAtA[i] = 0x10 + i++ + if m.IncludeUninitialized { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + return i, nil +} + +func (m *GroupKind) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GroupKind) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + return i, nil +} + +func (m *GroupResource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GroupResource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Resource))) + i += copy(dAtA[i:], m.Resource) + return i, nil +} + +func (m *GroupVersion) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GroupVersion) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i += copy(dAtA[i:], m.Version) + return i, nil +} + +func (m *GroupVersionForDiscovery) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GroupVersionForDiscovery) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.GroupVersion))) + i += copy(dAtA[i:], m.GroupVersion) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i += copy(dAtA[i:], m.Version) + return i, nil +} + +func (m *GroupVersionKind) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GroupVersionKind) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i += copy(dAtA[i:], m.Version) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + return i, nil +} + +func (m *GroupVersionResource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GroupVersionResource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i += copy(dAtA[i:], m.Version) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Resource))) + i += copy(dAtA[i:], m.Resource) + return i, nil +} + +func (m *Initializer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Initializer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func (m *Initializers) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Initializers) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Pending) > 0 { + for _, msg := range m.Pending { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.Result != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Result.Size())) + n4, err := m.Result.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + } + return i, nil +} + +func (m *LabelSelector) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LabelSelector) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.MatchLabels) > 0 { + keysForMatchLabels := make([]string, 0, len(m.MatchLabels)) + for k := range m.MatchLabels { + keysForMatchLabels = append(keysForMatchLabels, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForMatchLabels) + for _, k := range keysForMatchLabels { + dAtA[i] = 0xa + i++ + v := m.MatchLabels[string(k)] + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } + } + if len(m.MatchExpressions) > 0 { + for _, msg := range m.MatchExpressions { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *LabelSelectorRequirement) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LabelSelectorRequirement) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Operator))) + i += copy(dAtA[i:], m.Operator) + if len(m.Values) > 0 { + for _, s := range m.Values { + dAtA[i] = 0x1a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *ListMeta) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ListMeta) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SelfLink))) + i += copy(dAtA[i:], m.SelfLink) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) + return i, nil +} + +func (m *ListOptions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ListOptions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.LabelSelector))) + i += copy(dAtA[i:], m.LabelSelector) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldSelector))) + i += copy(dAtA[i:], m.FieldSelector) + dAtA[i] = 0x18 + i++ + if m.Watch { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) + if m.TimeoutSeconds != nil { + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.TimeoutSeconds)) + } + dAtA[i] = 0x30 + i++ + if m.IncludeUninitialized { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + return i, nil +} + +func (m *ObjectMeta) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ObjectMeta) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.GenerateName))) + i += copy(dAtA[i:], m.GenerateName) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SelfLink))) + i += copy(dAtA[i:], m.SelfLink) + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) + dAtA[i] = 0x38 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Generation)) + dAtA[i] = 0x42 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CreationTimestamp.Size())) + n5, err := m.CreationTimestamp.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + if m.DeletionTimestamp != nil { + dAtA[i] = 0x4a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.DeletionTimestamp.Size())) + n6, err := m.DeletionTimestamp.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + } + if m.DeletionGracePeriodSeconds != nil { + dAtA[i] = 0x50 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.DeletionGracePeriodSeconds)) + } + if len(m.Labels) > 0 { + keysForLabels := make([]string, 0, len(m.Labels)) + for k := range m.Labels { + keysForLabels = append(keysForLabels, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) + for _, k := range keysForLabels { + dAtA[i] = 0x5a + i++ + v := m.Labels[string(k)] + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } + } + if len(m.Annotations) > 0 { + keysForAnnotations := make([]string, 0, len(m.Annotations)) + for k := range m.Annotations { + keysForAnnotations = append(keysForAnnotations, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForAnnotations) + for _, k := range keysForAnnotations { + dAtA[i] = 0x62 + i++ + v := m.Annotations[string(k)] + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } + } + if len(m.OwnerReferences) > 0 { + for _, msg := range m.OwnerReferences { + dAtA[i] = 0x6a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.Finalizers) > 0 { + for _, s := range m.Finalizers { + dAtA[i] = 0x72 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + dAtA[i] = 0x7a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ClusterName))) + i += copy(dAtA[i:], m.ClusterName) + if m.Initializers != nil { + dAtA[i] = 0x82 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Initializers.Size())) + n7, err := m.Initializers.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + } + return i, nil +} + +func (m *OwnerReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *OwnerReference) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + if m.Controller != nil { + dAtA[i] = 0x30 + i++ + if *m.Controller { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + if m.BlockOwnerDeletion != nil { + dAtA[i] = 0x38 + i++ + if *m.BlockOwnerDeletion { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + return i, nil +} + +func (m *Preconditions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Preconditions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.UID != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.UID))) + i += copy(dAtA[i:], *m.UID) + } + return i, nil +} + +func (m *RootPaths) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RootPaths) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Paths) > 0 { + for _, s := range m.Paths { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *ServerAddressByClientCIDR) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ServerAddressByClientCIDR) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ClientCIDR))) + i += copy(dAtA[i:], m.ClientCIDR) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ServerAddress))) + i += copy(dAtA[i:], m.ServerAddress) + return i, nil +} + +func (m *Status) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Status) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n8, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + if m.Details != nil { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Details.Size())) + n9, err := m.Details.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + } + dAtA[i] = 0x30 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Code)) + return i, nil +} + +func (m *StatusCause) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatusCause) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Field))) + i += copy(dAtA[i:], m.Field) + return i, nil +} + +func (m *StatusDetails) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatusDetails) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + if len(m.Causes) > 0 { + for _, msg := range m.Causes { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RetryAfterSeconds)) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) + return i, nil +} + +func (m *Timestamp) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Timestamp) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Seconds)) + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Nanos)) + return i, nil +} + +func (m *TypeMeta) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TypeMeta) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + return i, nil +} + +func (m Verbs) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m Verbs) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *WatchEvent) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *WatchEvent) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size())) + n10, err := m.Object.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *APIGroup) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Versions) > 0 { + for _, e := range m.Versions { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.PreferredVersion.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.ServerAddressByClientCIDRs) > 0 { + for _, e := range m.ServerAddressByClientCIDRs { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *APIGroupList) Size() (n int) { + var l int + _ = l + if len(m.Groups) > 0 { + for _, e := range m.Groups { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *APIResource) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + if m.Verbs != nil { + l = m.Verbs.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if len(m.ShortNames) > 0 { + for _, s := range m.ShortNames { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = len(m.SingularName) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Categories) > 0 { + for _, s := range m.Categories { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *APIResourceList) Size() (n int) { + var l int + _ = l + l = len(m.GroupVersion) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.APIResources) > 0 { + for _, e := range m.APIResources { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *APIVersions) Size() (n int) { + var l int + _ = l + if len(m.Versions) > 0 { + for _, s := range m.Versions { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.ServerAddressByClientCIDRs) > 0 { + for _, e := range m.ServerAddressByClientCIDRs { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *DeleteOptions) Size() (n int) { + var l int + _ = l + if m.GracePeriodSeconds != nil { + n += 1 + sovGenerated(uint64(*m.GracePeriodSeconds)) + } + if m.Preconditions != nil { + l = m.Preconditions.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.OrphanDependents != nil { + n += 2 + } + if m.PropagationPolicy != nil { + l = len(*m.PropagationPolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *Duration) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Duration)) + return n +} + +func (m *ExportOptions) Size() (n int) { + var l int + _ = l + n += 2 + n += 2 + return n +} + +func (m *GetOptions) Size() (n int) { + var l int + _ = l + l = len(m.ResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + return n +} + +func (m *GroupKind) Size() (n int) { + var l int + _ = l + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *GroupResource) Size() (n int) { + var l int + _ = l + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Resource) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *GroupVersion) Size() (n int) { + var l int + _ = l + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *GroupVersionForDiscovery) Size() (n int) { + var l int + _ = l + l = len(m.GroupVersion) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *GroupVersionKind) Size() (n int) { + var l int + _ = l + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *GroupVersionResource) Size() (n int) { + var l int + _ = l + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Resource) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Initializer) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Initializers) Size() (n int) { + var l int + _ = l + if len(m.Pending) > 0 { + for _, e := range m.Pending { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.Result != nil { + l = m.Result.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *LabelSelector) Size() (n int) { + var l int + _ = l + if len(m.MatchLabels) > 0 { + for k, v := range m.MatchLabels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + if len(m.MatchExpressions) > 0 { + for _, e := range m.MatchExpressions { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *LabelSelectorRequirement) Size() (n int) { + var l int + _ = l + l = len(m.Key) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Operator) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Values) > 0 { + for _, s := range m.Values { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ListMeta) Size() (n int) { + var l int + _ = l + l = len(m.SelfLink) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.ResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ListOptions) Size() (n int) { + var l int + _ = l + l = len(m.LabelSelector) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.FieldSelector) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + l = len(m.ResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + if m.TimeoutSeconds != nil { + n += 1 + sovGenerated(uint64(*m.TimeoutSeconds)) + } + n += 2 + return n +} + +func (m *ObjectMeta) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.GenerateName) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Namespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.SelfLink) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.UID) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.ResourceVersion) + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.Generation)) + l = m.CreationTimestamp.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.DeletionTimestamp != nil { + l = m.DeletionTimestamp.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.DeletionGracePeriodSeconds != nil { + n += 1 + sovGenerated(uint64(*m.DeletionGracePeriodSeconds)) + } + if len(m.Labels) > 0 { + for k, v := range m.Labels { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + if len(m.Annotations) > 0 { + for k, v := range m.Annotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + if len(m.OwnerReferences) > 0 { + for _, e := range m.OwnerReferences { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Finalizers) > 0 { + for _, s := range m.Finalizers { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = len(m.ClusterName) + n += 1 + l + sovGenerated(uint64(l)) + if m.Initializers != nil { + l = m.Initializers.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *OwnerReference) Size() (n int) { + var l int + _ = l + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.UID) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.APIVersion) + n += 1 + l + sovGenerated(uint64(l)) + if m.Controller != nil { + n += 2 + } + if m.BlockOwnerDeletion != nil { + n += 2 + } + return n +} + +func (m *Preconditions) Size() (n int) { + var l int + _ = l + if m.UID != nil { + l = len(*m.UID) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *RootPaths) Size() (n int) { + var l int + _ = l + if len(m.Paths) > 0 { + for _, s := range m.Paths { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ServerAddressByClientCIDR) Size() (n int) { + var l int + _ = l + l = len(m.ClientCIDR) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.ServerAddress) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Status) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Status) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Message) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Reason) + n += 1 + l + sovGenerated(uint64(l)) + if m.Details != nil { + l = m.Details.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + n += 1 + sovGenerated(uint64(m.Code)) + return n +} + +func (m *StatusCause) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Message) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Field) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *StatusDetails) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Causes) > 0 { + for _, e := range m.Causes { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + n += 1 + sovGenerated(uint64(m.RetryAfterSeconds)) + l = len(m.UID) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Timestamp) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Seconds)) + n += 1 + sovGenerated(uint64(m.Nanos)) + return n +} + +func (m *TypeMeta) Size() (n int) { + var l int + _ = l + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.APIVersion) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m Verbs) Size() (n int) { + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *WatchEvent) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + l = m.Object.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *APIGroup) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&APIGroup{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Versions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Versions), "GroupVersionForDiscovery", "GroupVersionForDiscovery", 1), `&`, ``, 1) + `,`, + `PreferredVersion:` + strings.Replace(strings.Replace(this.PreferredVersion.String(), "GroupVersionForDiscovery", "GroupVersionForDiscovery", 1), `&`, ``, 1) + `,`, + `ServerAddressByClientCIDRs:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ServerAddressByClientCIDRs), "ServerAddressByClientCIDR", "ServerAddressByClientCIDR", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *APIGroupList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&APIGroupList{`, + `Groups:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Groups), "APIGroup", "APIGroup", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *APIResource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&APIResource{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Namespaced:` + fmt.Sprintf("%v", this.Namespaced) + `,`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Verbs:` + strings.Replace(fmt.Sprintf("%v", this.Verbs), "Verbs", "Verbs", 1) + `,`, + `ShortNames:` + fmt.Sprintf("%v", this.ShortNames) + `,`, + `SingularName:` + fmt.Sprintf("%v", this.SingularName) + `,`, + `Categories:` + fmt.Sprintf("%v", this.Categories) + `,`, + `}`, + }, "") + return s +} +func (this *APIResourceList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&APIResourceList{`, + `GroupVersion:` + fmt.Sprintf("%v", this.GroupVersion) + `,`, + `APIResources:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.APIResources), "APIResource", "APIResource", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DeleteOptions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeleteOptions{`, + `GracePeriodSeconds:` + valueToStringGenerated(this.GracePeriodSeconds) + `,`, + `Preconditions:` + strings.Replace(fmt.Sprintf("%v", this.Preconditions), "Preconditions", "Preconditions", 1) + `,`, + `OrphanDependents:` + valueToStringGenerated(this.OrphanDependents) + `,`, + `PropagationPolicy:` + valueToStringGenerated(this.PropagationPolicy) + `,`, + `}`, + }, "") + return s +} +func (this *Duration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Duration{`, + `Duration:` + fmt.Sprintf("%v", this.Duration) + `,`, + `}`, + }, "") + return s +} +func (this *ExportOptions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExportOptions{`, + `Export:` + fmt.Sprintf("%v", this.Export) + `,`, + `Exact:` + fmt.Sprintf("%v", this.Exact) + `,`, + `}`, + }, "") + return s +} +func (this *GetOptions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&GetOptions{`, + `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, + `IncludeUninitialized:` + fmt.Sprintf("%v", this.IncludeUninitialized) + `,`, + `}`, + }, "") + return s +} +func (this *GroupVersionForDiscovery) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&GroupVersionForDiscovery{`, + `GroupVersion:` + fmt.Sprintf("%v", this.GroupVersion) + `,`, + `Version:` + fmt.Sprintf("%v", this.Version) + `,`, + `}`, + }, "") + return s +} +func (this *Initializer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Initializer{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func (this *Initializers) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Initializers{`, + `Pending:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Pending), "Initializer", "Initializer", 1), `&`, ``, 1) + `,`, + `Result:` + strings.Replace(fmt.Sprintf("%v", this.Result), "Status", "Status", 1) + `,`, + `}`, + }, "") + return s +} +func (this *LabelSelector) String() string { + if this == nil { + return "nil" + } + keysForMatchLabels := make([]string, 0, len(this.MatchLabels)) + for k := range this.MatchLabels { + keysForMatchLabels = append(keysForMatchLabels, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForMatchLabels) + mapStringForMatchLabels := "map[string]string{" + for _, k := range keysForMatchLabels { + mapStringForMatchLabels += fmt.Sprintf("%v: %v,", k, this.MatchLabels[k]) + } + mapStringForMatchLabels += "}" + s := strings.Join([]string{`&LabelSelector{`, + `MatchLabels:` + mapStringForMatchLabels + `,`, + `MatchExpressions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.MatchExpressions), "LabelSelectorRequirement", "LabelSelectorRequirement", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *LabelSelectorRequirement) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&LabelSelectorRequirement{`, + `Key:` + fmt.Sprintf("%v", this.Key) + `,`, + `Operator:` + fmt.Sprintf("%v", this.Operator) + `,`, + `Values:` + fmt.Sprintf("%v", this.Values) + `,`, + `}`, + }, "") + return s +} +func (this *ListMeta) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ListMeta{`, + `SelfLink:` + fmt.Sprintf("%v", this.SelfLink) + `,`, + `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, + `}`, + }, "") + return s +} +func (this *ListOptions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ListOptions{`, + `LabelSelector:` + fmt.Sprintf("%v", this.LabelSelector) + `,`, + `FieldSelector:` + fmt.Sprintf("%v", this.FieldSelector) + `,`, + `Watch:` + fmt.Sprintf("%v", this.Watch) + `,`, + `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, + `TimeoutSeconds:` + valueToStringGenerated(this.TimeoutSeconds) + `,`, + `IncludeUninitialized:` + fmt.Sprintf("%v", this.IncludeUninitialized) + `,`, + `}`, + }, "") + return s +} +func (this *ObjectMeta) String() string { + if this == nil { + return "nil" + } + keysForLabels := make([]string, 0, len(this.Labels)) + for k := range this.Labels { + keysForLabels = append(keysForLabels, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) + mapStringForLabels := "map[string]string{" + for _, k := range keysForLabels { + mapStringForLabels += fmt.Sprintf("%v: %v,", k, this.Labels[k]) + } + mapStringForLabels += "}" + keysForAnnotations := make([]string, 0, len(this.Annotations)) + for k := range this.Annotations { + keysForAnnotations = append(keysForAnnotations, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForAnnotations) + mapStringForAnnotations := "map[string]string{" + for _, k := range keysForAnnotations { + mapStringForAnnotations += fmt.Sprintf("%v: %v,", k, this.Annotations[k]) + } + mapStringForAnnotations += "}" + s := strings.Join([]string{`&ObjectMeta{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `GenerateName:` + fmt.Sprintf("%v", this.GenerateName) + `,`, + `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, + `SelfLink:` + fmt.Sprintf("%v", this.SelfLink) + `,`, + `UID:` + fmt.Sprintf("%v", this.UID) + `,`, + `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, + `Generation:` + fmt.Sprintf("%v", this.Generation) + `,`, + `CreationTimestamp:` + strings.Replace(strings.Replace(this.CreationTimestamp.String(), "Time", "Time", 1), `&`, ``, 1) + `,`, + `DeletionTimestamp:` + strings.Replace(fmt.Sprintf("%v", this.DeletionTimestamp), "Time", "Time", 1) + `,`, + `DeletionGracePeriodSeconds:` + valueToStringGenerated(this.DeletionGracePeriodSeconds) + `,`, + `Labels:` + mapStringForLabels + `,`, + `Annotations:` + mapStringForAnnotations + `,`, + `OwnerReferences:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.OwnerReferences), "OwnerReference", "OwnerReference", 1), `&`, ``, 1) + `,`, + `Finalizers:` + fmt.Sprintf("%v", this.Finalizers) + `,`, + `ClusterName:` + fmt.Sprintf("%v", this.ClusterName) + `,`, + `Initializers:` + strings.Replace(fmt.Sprintf("%v", this.Initializers), "Initializers", "Initializers", 1) + `,`, + `}`, + }, "") + return s +} +func (this *OwnerReference) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&OwnerReference{`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `UID:` + fmt.Sprintf("%v", this.UID) + `,`, + `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`, + `Controller:` + valueToStringGenerated(this.Controller) + `,`, + `BlockOwnerDeletion:` + valueToStringGenerated(this.BlockOwnerDeletion) + `,`, + `}`, + }, "") + return s +} +func (this *Preconditions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Preconditions{`, + `UID:` + valueToStringGenerated(this.UID) + `,`, + `}`, + }, "") + return s +} +func (this *RootPaths) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RootPaths{`, + `Paths:` + fmt.Sprintf("%v", this.Paths) + `,`, + `}`, + }, "") + return s +} +func (this *ServerAddressByClientCIDR) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ServerAddressByClientCIDR{`, + `ClientCIDR:` + fmt.Sprintf("%v", this.ClientCIDR) + `,`, + `ServerAddress:` + fmt.Sprintf("%v", this.ServerAddress) + `,`, + `}`, + }, "") + return s +} +func (this *Status) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Status{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "ListMeta", 1), `&`, ``, 1) + `,`, + `Status:` + fmt.Sprintf("%v", this.Status) + `,`, + `Message:` + fmt.Sprintf("%v", this.Message) + `,`, + `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, + `Details:` + strings.Replace(fmt.Sprintf("%v", this.Details), "StatusDetails", "StatusDetails", 1) + `,`, + `Code:` + fmt.Sprintf("%v", this.Code) + `,`, + `}`, + }, "") + return s +} +func (this *StatusCause) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatusCause{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Message:` + fmt.Sprintf("%v", this.Message) + `,`, + `Field:` + fmt.Sprintf("%v", this.Field) + `,`, + `}`, + }, "") + return s +} +func (this *StatusDetails) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatusDetails{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Group:` + fmt.Sprintf("%v", this.Group) + `,`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Causes:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Causes), "StatusCause", "StatusCause", 1), `&`, ``, 1) + `,`, + `RetryAfterSeconds:` + fmt.Sprintf("%v", this.RetryAfterSeconds) + `,`, + `UID:` + fmt.Sprintf("%v", this.UID) + `,`, + `}`, + }, "") + return s +} +func (this *Timestamp) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Timestamp{`, + `Seconds:` + fmt.Sprintf("%v", this.Seconds) + `,`, + `Nanos:` + fmt.Sprintf("%v", this.Nanos) + `,`, + `}`, + }, "") + return s +} +func (this *TypeMeta) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TypeMeta{`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`, + `}`, + }, "") + return s +} +func (this *WatchEvent) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&WatchEvent{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Object:` + strings.Replace(strings.Replace(this.Object.String(), "RawExtension", "k8s_io_apimachinery_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *APIGroup) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: APIGroup: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: APIGroup: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Versions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Versions = append(m.Versions, GroupVersionForDiscovery{}) + if err := m.Versions[len(m.Versions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PreferredVersion", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.PreferredVersion.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ServerAddressByClientCIDRs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ServerAddressByClientCIDRs = append(m.ServerAddressByClientCIDRs, ServerAddressByClientCIDR{}) + if err := m.ServerAddressByClientCIDRs[len(m.ServerAddressByClientCIDRs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *APIGroupList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: APIGroupList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: APIGroupList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Groups", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Groups = append(m.Groups, APIGroup{}) + if err := m.Groups[len(m.Groups)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *APIResource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: APIResource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: APIResource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespaced", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Namespaced = bool(v != 0) + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Verbs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Verbs == nil { + m.Verbs = Verbs{} + } + if err := m.Verbs.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ShortNames", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ShortNames = append(m.ShortNames, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SingularName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SingularName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Categories", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Categories = append(m.Categories, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *APIResourceList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: APIResourceList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: APIResourceList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field GroupVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.GroupVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIResources", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIResources = append(m.APIResources, APIResource{}) + if err := m.APIResources[len(m.APIResources)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *APIVersions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: APIVersions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: APIVersions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Versions", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Versions = append(m.Versions, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ServerAddressByClientCIDRs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ServerAddressByClientCIDRs = append(m.ServerAddressByClientCIDRs, ServerAddressByClientCIDR{}) + if err := m.ServerAddressByClientCIDRs[len(m.ServerAddressByClientCIDRs)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeleteOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeleteOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeleteOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field GracePeriodSeconds", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.GracePeriodSeconds = &v + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Preconditions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Preconditions == nil { + m.Preconditions = &Preconditions{} + } + if err := m.Preconditions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field OrphanDependents", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.OrphanDependents = &b + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PropagationPolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := DeletionPropagation(dAtA[iNdEx:postIndex]) + m.PropagationPolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Duration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Duration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Duration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Duration", wireType) + } + m.Duration = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Duration |= (time.Duration(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExportOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExportOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExportOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Export", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Export = bool(v != 0) + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Exact", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Exact = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field IncludeUninitialized", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.IncludeUninitialized = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GroupKind) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GroupKind: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GroupKind: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GroupResource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GroupResource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GroupResource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resource = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GroupVersion) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GroupVersion: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GroupVersion: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GroupVersionForDiscovery) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GroupVersionForDiscovery: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GroupVersionForDiscovery: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field GroupVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.GroupVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GroupVersionKind) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GroupVersionKind: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GroupVersionKind: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GroupVersionResource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GroupVersionResource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GroupVersionResource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resource = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Initializer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Initializer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Initializer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Initializers) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Initializers: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Initializers: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pending", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Pending = append(m.Pending, Initializer{}) + if err := m.Pending[len(m.Pending)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Result == nil { + m.Result = &Status{} + } + if err := m.Result.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *LabelSelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LabelSelector: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LabelSelector: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MatchLabels", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.MatchLabels == nil { + m.MatchLabels = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.MatchLabels[mapkey] = mapvalue + } else { + var mapvalue string + m.MatchLabels[mapkey] = mapvalue + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MatchExpressions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MatchExpressions = append(m.MatchExpressions, LabelSelectorRequirement{}) + if err := m.MatchExpressions[len(m.MatchExpressions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *LabelSelectorRequirement) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LabelSelectorRequirement: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LabelSelectorRequirement: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Key = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Operator", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Operator = LabelSelectorOperator(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Values", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Values = append(m.Values, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ListMeta) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ListMeta: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ListMeta: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SelfLink", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SelfLink = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ListOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ListOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ListOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.LabelSelector = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FieldSelector", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.FieldSelector = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Watch", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Watch = bool(v != 0) + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TimeoutSeconds", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.TimeoutSeconds = &v + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field IncludeUninitialized", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.IncludeUninitialized = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ObjectMeta) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ObjectMeta: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ObjectMeta: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field GenerateName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.GenerateName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SelfLink", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SelfLink = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.UID = k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Generation", wireType) + } + m.Generation = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Generation |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CreationTimestamp", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.CreationTimestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 9: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field DeletionTimestamp", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.DeletionTimestamp == nil { + m.DeletionTimestamp = &Time{} + } + if err := m.DeletionTimestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 10: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DeletionGracePeriodSeconds", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.DeletionGracePeriodSeconds = &v + case 11: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Labels", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Labels == nil { + m.Labels = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue + } + iNdEx = postIndex + case 12: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Annotations == nil { + m.Annotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue + } + iNdEx = postIndex + case 13: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field OwnerReferences", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.OwnerReferences = append(m.OwnerReferences, OwnerReference{}) + if err := m.OwnerReferences[len(m.OwnerReferences)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 14: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Finalizers", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Finalizers = append(m.Finalizers, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 15: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClusterName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ClusterName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 16: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Initializers", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Initializers == nil { + m.Initializers = &Initializers{} + } + if err := m.Initializers.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *OwnerReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: OwnerReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: OwnerReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.UID = k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Controller", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Controller = &b + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field BlockOwnerDeletion", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.BlockOwnerDeletion = &b + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Preconditions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Preconditions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Preconditions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) + m.UID = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RootPaths) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RootPaths: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RootPaths: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Paths = append(m.Paths, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ServerAddressByClientCIDR) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ServerAddressByClientCIDR: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ServerAddressByClientCIDR: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientCIDR", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ClientCIDR = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ServerAddress", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ServerAddress = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Status) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Status: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Status: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Status = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = StatusReason(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Details", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Details == nil { + m.Details = &StatusDetails{} + } + if err := m.Details.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType) + } + m.Code = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Code |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StatusCause) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StatusCause: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StatusCause: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = CauseType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Field", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Field = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StatusDetails) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StatusDetails: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StatusDetails: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Causes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Causes = append(m.Causes, StatusCause{}) + if err := m.Causes[len(m.Causes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field RetryAfterSeconds", wireType) + } + m.RetryAfterSeconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.RetryAfterSeconds |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.UID = k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Timestamp) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Timestamp: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Timestamp: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Seconds", wireType) + } + m.Seconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Seconds |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Nanos", wireType) + } + m.Nanos = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Nanos |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TypeMeta) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: TypeMeta: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TypeMeta: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Verbs) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Verbs: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Verbs: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + *m = append(*m, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *WatchEvent) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: WatchEvent: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: WatchEvent: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 2351 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xcc, 0x59, 0xcd, 0x6f, 0x1b, 0xc7, + 0x15, 0xd7, 0x52, 0x22, 0x45, 0x3e, 0x8a, 0xfa, 0x98, 0xc8, 0x2d, 0x23, 0xb4, 0xa4, 0xb2, 0x29, + 0x02, 0xa5, 0x75, 0xc8, 0x4a, 0x69, 0x03, 0xd7, 0x6d, 0xdd, 0x6a, 0x45, 0xd9, 0x10, 0x62, 0xd9, + 0xc4, 0x28, 0x76, 0x51, 0xd7, 0x28, 0xba, 0x5a, 0x8e, 0xa8, 0xad, 0x96, 0xbb, 0x9b, 0x99, 0xa1, + 0x6c, 0x35, 0x87, 0xe6, 0xd0, 0x02, 0x3d, 0x14, 0x85, 0x8f, 0x3d, 0x15, 0x31, 0xda, 0xbf, 0xa0, + 0x7f, 0x40, 0x4f, 0x05, 0xea, 0x63, 0x80, 0x5e, 0x72, 0x28, 0x88, 0x98, 0x39, 0xf4, 0x14, 0xf4, + 0x2e, 0xa0, 0x40, 0x31, 0xb3, 0xb3, 0x5f, 0xa4, 0x18, 0x2d, 0xe3, 0xa0, 0xc8, 0x49, 0xdc, 0xf7, + 0xf1, 0x7b, 0x6f, 0x66, 0xde, 0xbc, 0xf7, 0xe6, 0x09, 0xf6, 0x4f, 0xae, 0xb1, 0x86, 0xed, 0x35, + 0x4f, 0xfa, 0x87, 0x84, 0xba, 0x84, 0x13, 0xd6, 0x3c, 0x25, 0x6e, 0xc7, 0xa3, 0x4d, 0xc5, 0x30, + 0x7d, 0xbb, 0x67, 0x5a, 0xc7, 0xb6, 0x4b, 0xe8, 0x59, 0xd3, 0x3f, 0xe9, 0x0a, 0x02, 0x6b, 0xf6, + 0x08, 0x37, 0x9b, 0xa7, 0x9b, 0xcd, 0x2e, 0x71, 0x09, 0x35, 0x39, 0xe9, 0x34, 0x7c, 0xea, 0x71, + 0x0f, 0x7d, 0x23, 0xd0, 0x6a, 0x24, 0xb5, 0x1a, 0xfe, 0x49, 0x57, 0x10, 0x58, 0x43, 0x68, 0x35, + 0x4e, 0x37, 0xd7, 0xde, 0xe8, 0xda, 0xfc, 0xb8, 0x7f, 0xd8, 0xb0, 0xbc, 0x5e, 0xb3, 0xeb, 0x75, + 0xbd, 0xa6, 0x54, 0x3e, 0xec, 0x1f, 0xc9, 0x2f, 0xf9, 0x21, 0x7f, 0x05, 0xa0, 0x6b, 0x13, 0x5d, + 0xa1, 0x7d, 0x97, 0xdb, 0x3d, 0x32, 0xea, 0xc5, 0xda, 0x5b, 0x97, 0x29, 0x30, 0xeb, 0x98, 0xf4, + 0xcc, 0x31, 0xbd, 0x37, 0x27, 0xe9, 0xf5, 0xb9, 0xed, 0x34, 0x6d, 0x97, 0x33, 0x4e, 0x47, 0x95, + 0xf4, 0x7f, 0xcc, 0x42, 0x71, 0xbb, 0xbd, 0x77, 0x8b, 0x7a, 0x7d, 0x1f, 0xad, 0xc3, 0x9c, 0x6b, + 0xf6, 0x48, 0x55, 0x5b, 0xd7, 0x36, 0x4a, 0xc6, 0xc2, 0xb3, 0x41, 0x7d, 0x66, 0x38, 0xa8, 0xcf, + 0xdd, 0x31, 0x7b, 0x04, 0x4b, 0x0e, 0x72, 0xa0, 0x78, 0x4a, 0x28, 0xb3, 0x3d, 0x97, 0x55, 0x73, + 0xeb, 0xb3, 0x1b, 0xe5, 0xad, 0x1b, 0x8d, 0x2c, 0x9b, 0xd6, 0x90, 0x06, 0xee, 0x07, 0xaa, 0x37, + 0x3d, 0xda, 0xb2, 0x99, 0xe5, 0x9d, 0x12, 0x7a, 0x66, 0x2c, 0x2b, 0x2b, 0x45, 0xc5, 0x64, 0x38, + 0xb2, 0x80, 0x7e, 0xa3, 0xc1, 0xb2, 0x4f, 0xc9, 0x11, 0xa1, 0x94, 0x74, 0x14, 0xbf, 0x3a, 0xbb, + 0xae, 0x7d, 0x01, 0x66, 0xab, 0xca, 0xec, 0x72, 0x7b, 0x04, 0x1f, 0x8f, 0x59, 0x44, 0x7f, 0xd6, + 0x60, 0x8d, 0x11, 0x7a, 0x4a, 0xe8, 0x76, 0xa7, 0x43, 0x09, 0x63, 0xc6, 0xd9, 0x8e, 0x63, 0x13, + 0x97, 0xef, 0xec, 0xb5, 0x30, 0xab, 0xce, 0xc9, 0x7d, 0xf8, 0x51, 0x36, 0x87, 0x0e, 0x26, 0xe1, + 0x18, 0xba, 0xf2, 0x68, 0x6d, 0xa2, 0x08, 0xc3, 0x9f, 0xe1, 0x86, 0x7e, 0x04, 0x0b, 0xe1, 0x41, + 0xde, 0xb6, 0x19, 0x47, 0xf7, 0xa1, 0xd0, 0x15, 0x1f, 0xac, 0xaa, 0x49, 0x07, 0x1b, 0xd9, 0x1c, + 0x0c, 0x31, 0x8c, 0x45, 0xe5, 0x4f, 0x41, 0x7e, 0x32, 0xac, 0xd0, 0xf4, 0x4f, 0x73, 0x50, 0xde, + 0x6e, 0xef, 0x61, 0xc2, 0xbc, 0x3e, 0xb5, 0x48, 0x86, 0xa0, 0xd9, 0x02, 0x10, 0x7f, 0x99, 0x6f, + 0x5a, 0xa4, 0x53, 0xcd, 0xad, 0x6b, 0x1b, 0x45, 0x03, 0x29, 0x39, 0xb8, 0x13, 0x71, 0x70, 0x42, + 0x4a, 0xa0, 0x9e, 0xd8, 0x6e, 0x47, 0x9e, 0x76, 0x02, 0xf5, 0x6d, 0xdb, 0xed, 0x60, 0xc9, 0x41, + 0xb7, 0x21, 0x7f, 0x4a, 0xe8, 0xa1, 0xd8, 0x7f, 0x11, 0x10, 0xdf, 0xca, 0xb6, 0xbc, 0xfb, 0x42, + 0xc5, 0x28, 0x0d, 0x07, 0xf5, 0xbc, 0xfc, 0x89, 0x03, 0x10, 0xd4, 0x00, 0x60, 0xc7, 0x1e, 0xe5, + 0xd2, 0x9d, 0x6a, 0x7e, 0x7d, 0x76, 0xa3, 0x64, 0x2c, 0x0a, 0xff, 0x0e, 0x22, 0x2a, 0x4e, 0x48, + 0xa0, 0x6b, 0xb0, 0xc0, 0x6c, 0xb7, 0xdb, 0x77, 0x4c, 0x2a, 0x08, 0xd5, 0x82, 0xf4, 0x73, 0x55, + 0xf9, 0xb9, 0x70, 0x90, 0xe0, 0xe1, 0x94, 0xa4, 0xb0, 0x64, 0x99, 0x9c, 0x74, 0x3d, 0x6a, 0x13, + 0x56, 0x9d, 0x8f, 0x2d, 0xed, 0x44, 0x54, 0x9c, 0x90, 0xd0, 0xff, 0xaa, 0xc1, 0x52, 0x62, 0xbf, + 0xe5, 0xd9, 0x5e, 0x83, 0x85, 0x6e, 0x22, 0xb2, 0xd5, 0xde, 0x47, 0xd6, 0x93, 0x51, 0x8f, 0x53, + 0x92, 0x88, 0x40, 0x89, 0x2a, 0xa4, 0xf0, 0x06, 0x6f, 0x66, 0x0e, 0x8c, 0xd0, 0x87, 0xd8, 0x52, + 0x82, 0xc8, 0x70, 0x8c, 0xac, 0xff, 0x5b, 0x93, 0x41, 0x12, 0xde, 0x69, 0xb4, 0x91, 0xc8, 0x1b, + 0x9a, 0x5c, 0xf2, 0xc2, 0x84, 0x3b, 0x7f, 0xc9, 0x65, 0xcb, 0x7d, 0x29, 0x2e, 0xdb, 0xf5, 0xe2, + 0x1f, 0x3f, 0xa8, 0xcf, 0xbc, 0xff, 0xaf, 0xf5, 0x19, 0xfd, 0x93, 0x1c, 0x54, 0x5a, 0xc4, 0x21, + 0x9c, 0xdc, 0xf5, 0xb9, 0x5c, 0xc1, 0x4d, 0x40, 0x5d, 0x6a, 0x5a, 0xa4, 0x4d, 0xa8, 0xed, 0x75, + 0x0e, 0x88, 0xe5, 0xb9, 0x1d, 0x26, 0x8f, 0x68, 0xd6, 0xf8, 0xca, 0x70, 0x50, 0x47, 0xb7, 0xc6, + 0xb8, 0xf8, 0x02, 0x0d, 0xe4, 0x40, 0xc5, 0xa7, 0xf2, 0xb7, 0xcd, 0x55, 0xc2, 0x15, 0x81, 0xfe, + 0x66, 0xb6, 0xb5, 0xb7, 0x93, 0xaa, 0xc6, 0xca, 0x70, 0x50, 0xaf, 0xa4, 0x48, 0x38, 0x0d, 0x8e, + 0x7e, 0x0c, 0xcb, 0x1e, 0xf5, 0x8f, 0x4d, 0xb7, 0x45, 0x7c, 0xe2, 0x76, 0x88, 0xcb, 0x99, 0xbc, + 0x7c, 0x45, 0x63, 0x55, 0xa4, 0xc9, 0xbb, 0x23, 0x3c, 0x3c, 0x26, 0x8d, 0x1e, 0xc0, 0x8a, 0x4f, + 0x3d, 0xdf, 0xec, 0x9a, 0x02, 0xb1, 0xed, 0x39, 0xb6, 0x75, 0x26, 0x2f, 0x67, 0xc9, 0xb8, 0x3a, + 0x1c, 0xd4, 0x57, 0xda, 0xa3, 0xcc, 0xf3, 0x41, 0xfd, 0x25, 0xb9, 0x75, 0x82, 0x12, 0x33, 0xf1, + 0x38, 0x8c, 0xbe, 0x07, 0xc5, 0x56, 0x9f, 0x4a, 0x0a, 0xfa, 0x21, 0x14, 0x3b, 0xea, 0xb7, 0xda, + 0xd5, 0x57, 0xc2, 0x1a, 0x12, 0xca, 0x9c, 0x0f, 0xea, 0x15, 0x51, 0x2a, 0x1b, 0x21, 0x01, 0x47, + 0x2a, 0xfa, 0x43, 0xa8, 0xec, 0x3e, 0xf6, 0x3d, 0xca, 0xc3, 0xf3, 0x7a, 0x0d, 0x0a, 0x44, 0x12, + 0x24, 0x5a, 0x31, 0x4e, 0x7c, 0x81, 0x18, 0x56, 0x5c, 0xf4, 0x2a, 0xe4, 0xc9, 0x63, 0xd3, 0xe2, + 0x2a, 0x83, 0x55, 0x94, 0x58, 0x7e, 0x57, 0x10, 0x71, 0xc0, 0xd3, 0x9f, 0x6a, 0x00, 0xb7, 0x48, + 0x84, 0xbd, 0x0d, 0x4b, 0xe1, 0xa5, 0x48, 0xdf, 0xd5, 0xaf, 0x2a, 0xed, 0x25, 0x9c, 0x66, 0xe3, + 0x51, 0x79, 0xd4, 0x86, 0x55, 0xdb, 0xb5, 0x9c, 0x7e, 0x87, 0xdc, 0x73, 0x6d, 0xd7, 0xe6, 0xb6, + 0xe9, 0xd8, 0xbf, 0x8a, 0xf2, 0xe8, 0xd7, 0x14, 0xce, 0xea, 0xde, 0x05, 0x32, 0xf8, 0x42, 0x4d, + 0xfd, 0x21, 0x94, 0x64, 0x86, 0x10, 0xc9, 0x54, 0xac, 0x4a, 0x26, 0x08, 0xe5, 0x57, 0xb4, 0x2a, + 0x29, 0x81, 0x03, 0x5e, 0x94, 0x8d, 0x73, 0x93, 0xb2, 0x71, 0xe2, 0x42, 0x38, 0x50, 0x09, 0x74, + 0xc3, 0x02, 0x91, 0xc9, 0xc2, 0x55, 0x28, 0x86, 0x0b, 0x57, 0x56, 0xa2, 0xc6, 0x20, 0x04, 0xc2, + 0x91, 0x44, 0xc2, 0xda, 0x31, 0xa4, 0xb2, 0x5d, 0x36, 0x63, 0xaf, 0xc3, 0xbc, 0xca, 0x37, 0xca, + 0xd6, 0x92, 0x12, 0x9b, 0x0f, 0x4f, 0x21, 0xe4, 0x27, 0x2c, 0xfd, 0x1a, 0xaa, 0x93, 0xba, 0x89, + 0x17, 0xc8, 0xc7, 0xd9, 0x5d, 0xd1, 0xff, 0xa0, 0xc1, 0x72, 0x12, 0x29, 0xfb, 0xf1, 0x65, 0x37, + 0x72, 0x79, 0xdd, 0x4d, 0xec, 0xc8, 0x9f, 0x34, 0x58, 0x4d, 0x2d, 0x6d, 0xaa, 0x13, 0x9f, 0xc2, + 0xa9, 0x64, 0x70, 0xcc, 0x4e, 0x11, 0x1c, 0x4d, 0x28, 0xef, 0x45, 0x71, 0x4f, 0x2f, 0xef, 0x54, + 0xf4, 0xbf, 0x69, 0xb0, 0x90, 0xd0, 0x60, 0xe8, 0x21, 0xcc, 0x8b, 0xfc, 0x66, 0xbb, 0x5d, 0xd5, + 0x45, 0x65, 0x2c, 0x96, 0x09, 0x90, 0x78, 0x5d, 0xed, 0x00, 0x09, 0x87, 0x90, 0xa8, 0x0d, 0x05, + 0x4a, 0x58, 0xdf, 0xe1, 0x2a, 0xb5, 0x5f, 0xcd, 0x58, 0xd6, 0xb8, 0xc9, 0xfb, 0xcc, 0x00, 0x91, + 0xa3, 0xb0, 0xd4, 0xc7, 0x0a, 0x47, 0xff, 0x67, 0x0e, 0x2a, 0xb7, 0xcd, 0x43, 0xe2, 0x1c, 0x10, + 0x87, 0x58, 0xdc, 0xa3, 0xe8, 0x3d, 0x28, 0xf7, 0x4c, 0x6e, 0x1d, 0x4b, 0x6a, 0xd8, 0x0b, 0xb6, + 0xb2, 0x19, 0x4a, 0x21, 0x35, 0xf6, 0x63, 0x98, 0x5d, 0x97, 0xd3, 0x33, 0xe3, 0x25, 0xb5, 0xb0, + 0x72, 0x82, 0x83, 0x93, 0xd6, 0x64, 0x03, 0x2f, 0xbf, 0x77, 0x1f, 0xfb, 0xa2, 0x88, 0x4e, 0xff, + 0x6e, 0x48, 0xb9, 0x80, 0xc9, 0xbb, 0x7d, 0x9b, 0x92, 0x1e, 0x71, 0x79, 0xdc, 0xc0, 0xef, 0x8f, + 0xe0, 0xe3, 0x31, 0x8b, 0x6b, 0x37, 0x60, 0x79, 0xd4, 0x79, 0xb4, 0x0c, 0xb3, 0x27, 0xe4, 0x2c, + 0x88, 0x05, 0x2c, 0x7e, 0xa2, 0x55, 0xc8, 0x9f, 0x9a, 0x4e, 0x5f, 0xe5, 0x1f, 0x1c, 0x7c, 0x5c, + 0xcf, 0x5d, 0xd3, 0xf4, 0xbf, 0x68, 0x50, 0x9d, 0xe4, 0x08, 0xfa, 0x7a, 0x02, 0xc8, 0x28, 0x2b, + 0xaf, 0x66, 0xdf, 0x26, 0x67, 0x01, 0xea, 0x2e, 0x14, 0x3d, 0x5f, 0x3c, 0xb9, 0x3c, 0xaa, 0xe2, + 0xfc, 0xf5, 0x30, 0x76, 0xef, 0x2a, 0xfa, 0xf9, 0xa0, 0x7e, 0x25, 0x05, 0x1f, 0x32, 0x70, 0xa4, + 0x8a, 0x74, 0x28, 0x48, 0x7f, 0x44, 0x51, 0x16, 0xed, 0x93, 0x3c, 0xfc, 0xfb, 0x92, 0x82, 0x15, + 0x47, 0x7f, 0x0f, 0x8a, 0xa2, 0x3b, 0xdc, 0x27, 0xdc, 0x14, 0x57, 0x86, 0x11, 0xe7, 0xe8, 0xb6, + 0xed, 0x9e, 0x28, 0xd7, 0xa2, 0x2b, 0x73, 0xa0, 0xe8, 0x38, 0x92, 0xb8, 0xa8, 0x4c, 0xe5, 0xa6, + 0x2b, 0x53, 0xfa, 0x7f, 0x73, 0x50, 0x16, 0xd6, 0xc3, 0xca, 0xf7, 0x7d, 0xa8, 0x38, 0xc9, 0x35, + 0x29, 0x2f, 0xae, 0x28, 0xc0, 0x74, 0x94, 0xe2, 0xb4, 0xac, 0x50, 0x3e, 0xb2, 0x89, 0xd3, 0x89, + 0x94, 0x73, 0x69, 0xe5, 0x9b, 0x49, 0x26, 0x4e, 0xcb, 0x8a, 0xec, 0xf3, 0x48, 0x9c, 0xb6, 0x6a, + 0x5f, 0xa2, 0xec, 0xf3, 0x13, 0x41, 0xc4, 0x01, 0xef, 0xa2, 0x15, 0xcf, 0x4d, 0x59, 0x98, 0xaf, + 0xc3, 0xa2, 0xe8, 0x31, 0xbc, 0x3e, 0x0f, 0x7b, 0xbc, 0xbc, 0xec, 0x46, 0xd0, 0x70, 0x50, 0x5f, + 0x7c, 0x27, 0xc5, 0xc1, 0x23, 0x92, 0x13, 0x8b, 0x7a, 0xe1, 0x73, 0x17, 0xf5, 0x77, 0xa1, 0xb4, + 0x6f, 0x5b, 0xd4, 0x13, 0x86, 0x45, 0x6e, 0x65, 0xa9, 0xbe, 0x33, 0xca, 0x41, 0xa1, 0x43, 0x21, + 0x5f, 0xec, 0x96, 0x6b, 0xba, 0x5e, 0xd0, 0x5d, 0xe6, 0xe3, 0xdd, 0xba, 0x23, 0x88, 0x38, 0xe0, + 0x5d, 0x5f, 0x15, 0x29, 0xf5, 0x77, 0x4f, 0xeb, 0x33, 0x4f, 0x9e, 0xd6, 0x67, 0x3e, 0x78, 0xaa, + 0xd2, 0xeb, 0xa7, 0x00, 0x70, 0xf7, 0xf0, 0x97, 0xc4, 0x0a, 0x42, 0xee, 0xf2, 0x87, 0xa0, 0x28, + 0x93, 0x6a, 0xfe, 0x20, 0x1f, 0x4d, 0xb9, 0x91, 0x32, 0x99, 0xe0, 0xe1, 0x94, 0x24, 0x6a, 0x42, + 0x29, 0x7a, 0x1c, 0xaa, 0x12, 0xb0, 0xa2, 0xd4, 0x4a, 0xd1, 0x0b, 0x12, 0xc7, 0x32, 0xa9, 0xf8, + 0x9f, 0xbb, 0x34, 0xfe, 0x0d, 0x98, 0xed, 0xdb, 0x1d, 0x79, 0x7e, 0x25, 0xe3, 0xdb, 0xe1, 0x1d, + 0xbe, 0xb7, 0xd7, 0x3a, 0x1f, 0xd4, 0x5f, 0x99, 0x34, 0x56, 0xe1, 0x67, 0x3e, 0x61, 0x8d, 0x7b, + 0x7b, 0x2d, 0x2c, 0x94, 0x2f, 0x8a, 0xa8, 0xc2, 0x94, 0x11, 0xb5, 0x05, 0xa0, 0x56, 0x2d, 0xb4, + 0xe7, 0x83, 0x68, 0x0a, 0x1f, 0xca, 0xb7, 0x22, 0x0e, 0x4e, 0x48, 0x21, 0x06, 0x2b, 0x16, 0x25, + 0xf2, 0xb7, 0x38, 0x7a, 0xc6, 0xcd, 0x9e, 0x5f, 0x2d, 0xca, 0x72, 0xf2, 0xcd, 0x6c, 0x29, 0x56, + 0xa8, 0x19, 0x2f, 0x2b, 0x33, 0x2b, 0x3b, 0xa3, 0x60, 0x78, 0x1c, 0x1f, 0x79, 0xb0, 0xd2, 0x51, + 0x8d, 0x7b, 0x6c, 0xb4, 0x34, 0xb5, 0xd1, 0x2b, 0xc2, 0x60, 0x6b, 0x14, 0x08, 0x8f, 0x63, 0xa3, + 0x9f, 0xc3, 0x5a, 0x48, 0x1c, 0x7f, 0x3d, 0x55, 0x41, 0xee, 0x54, 0x4d, 0xbc, 0xe7, 0x5a, 0x13, + 0xa5, 0xf0, 0x67, 0x20, 0xa0, 0x0e, 0x14, 0x9c, 0xa0, 0x40, 0x96, 0x65, 0x75, 0xfa, 0x41, 0xb6, + 0x55, 0xc4, 0xd1, 0xdf, 0x48, 0x16, 0xc6, 0xe8, 0x05, 0xa1, 0x6a, 0xa2, 0xc2, 0x46, 0x8f, 0xa1, + 0x6c, 0xba, 0xae, 0xc7, 0xcd, 0xe0, 0x3d, 0xb7, 0x20, 0x4d, 0x6d, 0x4f, 0x6d, 0x6a, 0x3b, 0xc6, + 0x18, 0x29, 0xc4, 0x09, 0x0e, 0x4e, 0x9a, 0x42, 0x8f, 0x60, 0xc9, 0x7b, 0xe4, 0x12, 0x8a, 0xc9, + 0x11, 0xa1, 0xc4, 0x15, 0x8f, 0xff, 0x8a, 0xb4, 0xfe, 0x9d, 0x8c, 0xd6, 0x53, 0xca, 0x71, 0x48, + 0xa7, 0xe9, 0x0c, 0x8f, 0x5a, 0x41, 0x0d, 0x80, 0x23, 0xdb, 0x55, 0xed, 0x54, 0x75, 0x31, 0x9e, + 0x76, 0xdc, 0x8c, 0xa8, 0x38, 0x21, 0x81, 0xbe, 0x0b, 0x65, 0xcb, 0xe9, 0x33, 0x4e, 0x82, 0xb1, + 0xca, 0x92, 0xbc, 0x41, 0xd1, 0xfa, 0x76, 0x62, 0x16, 0x4e, 0xca, 0xa1, 0x63, 0x58, 0xb0, 0x13, + 0x7d, 0x5b, 0x75, 0x59, 0xc6, 0xe2, 0xd6, 0xd4, 0xcd, 0x1a, 0x33, 0x96, 0x45, 0x26, 0x4a, 0x52, + 0x70, 0x0a, 0x79, 0xed, 0x7b, 0x50, 0xfe, 0x9c, 0x6d, 0x84, 0x68, 0x43, 0x46, 0x8f, 0x6e, 0xaa, + 0x36, 0xe4, 0xef, 0x39, 0x58, 0x4c, 0x6f, 0x78, 0xd4, 0xae, 0x6b, 0x13, 0xc7, 0x64, 0x61, 0x56, + 0x9e, 0x9d, 0x98, 0x95, 0x55, 0xf2, 0x9b, 0x7b, 0x91, 0xe4, 0xb7, 0x05, 0x60, 0xfa, 0x76, 0x98, + 0xf7, 0x82, 0x3c, 0x1a, 0x65, 0xae, 0x78, 0x10, 0x84, 0x13, 0x52, 0x72, 0x10, 0xe6, 0xb9, 0x9c, + 0x7a, 0x8e, 0x43, 0xa8, 0xaa, 0x7c, 0xc1, 0x20, 0x2c, 0xa2, 0xe2, 0x84, 0x04, 0xba, 0x09, 0xe8, + 0xd0, 0xf1, 0xac, 0x13, 0xb9, 0x05, 0xe1, 0x3d, 0x97, 0x59, 0xb2, 0x18, 0xcc, 0x55, 0x8c, 0x31, + 0x2e, 0xbe, 0x40, 0x43, 0xbf, 0x0b, 0xe9, 0x49, 0x08, 0xba, 0x11, 0x6c, 0x80, 0x16, 0x8d, 0x2a, + 0xa6, 0x5b, 0xbc, 0x7e, 0x15, 0x4a, 0xd8, 0xf3, 0x78, 0xdb, 0xe4, 0xc7, 0x0c, 0xd5, 0x21, 0xef, + 0x8b, 0x1f, 0x6a, 0xcc, 0x25, 0x27, 0x8d, 0x92, 0x83, 0x03, 0xba, 0xfe, 0x7b, 0x0d, 0x5e, 0x9e, + 0x38, 0x75, 0x12, 0x1b, 0x69, 0x45, 0x5f, 0xca, 0xa5, 0x68, 0x23, 0x63, 0x39, 0x9c, 0x90, 0x12, + 0xdd, 0x52, 0x6a, 0x54, 0x35, 0xda, 0x2d, 0xa5, 0xac, 0xe1, 0xb4, 0xac, 0xfe, 0x9f, 0x1c, 0x14, + 0x82, 0x07, 0x05, 0x7a, 0x08, 0x45, 0x71, 0x25, 0x3a, 0x26, 0x37, 0xa5, 0xe5, 0xcc, 0x33, 0xe3, + 0xb0, 0xeb, 0x8c, 0x6b, 0x6c, 0x48, 0xc1, 0x11, 0x22, 0x7a, 0x0d, 0x0a, 0x4c, 0xda, 0x51, 0xee, + 0x45, 0x49, 0x32, 0xb0, 0x8e, 0x15, 0x57, 0xf4, 0x2e, 0x3d, 0xc2, 0x98, 0xd9, 0x0d, 0x63, 0x36, + 0xea, 0x5d, 0xf6, 0x03, 0x32, 0x0e, 0xf9, 0xe8, 0x2d, 0xf1, 0x7e, 0x32, 0x59, 0xd4, 0xbb, 0xd5, + 0x42, 0x48, 0x2c, 0xa9, 0xe7, 0x83, 0xfa, 0x82, 0x02, 0x97, 0xdf, 0x58, 0x49, 0xa3, 0x07, 0x30, + 0xdf, 0x21, 0xdc, 0xb4, 0x9d, 0xa0, 0x65, 0xcb, 0x3c, 0x53, 0x0b, 0xc0, 0x5a, 0x81, 0xaa, 0x51, + 0x16, 0x3e, 0xa9, 0x0f, 0x1c, 0x02, 0x8a, 0xfb, 0x66, 0x79, 0x9d, 0x60, 0x20, 0x9c, 0x8f, 0xef, + 0xdb, 0x8e, 0xd7, 0x21, 0x58, 0x72, 0xf4, 0x27, 0x1a, 0x94, 0x03, 0xa4, 0x1d, 0xb3, 0xcf, 0x08, + 0xda, 0x8c, 0x56, 0x11, 0x1c, 0x77, 0x58, 0x8a, 0xe7, 0xde, 0x39, 0xf3, 0xc9, 0xf9, 0xa0, 0x5e, + 0x92, 0x62, 0xe2, 0x23, 0x5a, 0x40, 0x62, 0x8f, 0x72, 0x97, 0xec, 0xd1, 0xab, 0x90, 0x97, 0xed, + 0xb1, 0xda, 0xcc, 0xa8, 0xbf, 0x93, 0x2d, 0x34, 0x0e, 0x78, 0xfa, 0xc7, 0x39, 0xa8, 0xa4, 0x16, + 0x97, 0xa1, 0x99, 0x8b, 0x1e, 0xf9, 0xb9, 0x0c, 0x83, 0xa3, 0xc9, 0x63, 0xfc, 0x9f, 0x42, 0xc1, + 0x12, 0xeb, 0x0b, 0xff, 0x8f, 0xb2, 0x39, 0xcd, 0x51, 0xc8, 0x9d, 0x89, 0x23, 0x49, 0x7e, 0x32, + 0xac, 0x00, 0xd1, 0x2d, 0x58, 0xa1, 0x84, 0xd3, 0xb3, 0xed, 0x23, 0x4e, 0x68, 0xb2, 0x47, 0xcf, + 0xc7, 0xed, 0x0e, 0x1e, 0x15, 0xc0, 0xe3, 0x3a, 0x61, 0x86, 0x2c, 0xbc, 0x40, 0x86, 0xd4, 0x1d, + 0x98, 0xfb, 0x3f, 0xb6, 0xe6, 0x3f, 0x83, 0x52, 0xdc, 0x3c, 0x7d, 0xc1, 0x26, 0xf5, 0x5f, 0x40, + 0x51, 0x44, 0x63, 0xd8, 0xf4, 0x5f, 0x52, 0x80, 0xd2, 0xa5, 0x21, 0x97, 0xa5, 0x34, 0xe8, 0x5b, + 0x10, 0xfc, 0x77, 0x46, 0x64, 0x53, 0x9b, 0x93, 0x5e, 0x2a, 0x9b, 0xee, 0x09, 0x02, 0x0e, 0xe8, + 0x89, 0x61, 0xcf, 0x6f, 0x35, 0x00, 0xf9, 0xc4, 0xdb, 0x3d, 0x15, 0xcf, 0xf2, 0x75, 0x98, 0x13, + 0x27, 0x30, 0xea, 0x98, 0xbc, 0x46, 0x92, 0x83, 0xee, 0x41, 0xc1, 0x93, 0x4d, 0x95, 0x9a, 0xbe, + 0xbc, 0x31, 0x31, 0xf2, 0xd4, 0x3f, 0x5e, 0x1b, 0xd8, 0x7c, 0xb4, 0xfb, 0x98, 0x13, 0x57, 0xf8, + 0x18, 0x47, 0x5d, 0xd0, 0x99, 0x61, 0x05, 0x66, 0x6c, 0x3c, 0x7b, 0x5e, 0x9b, 0xf9, 0xf0, 0x79, + 0x6d, 0xe6, 0xa3, 0xe7, 0xb5, 0x99, 0xf7, 0x87, 0x35, 0xed, 0xd9, 0xb0, 0xa6, 0x7d, 0x38, 0xac, + 0x69, 0x1f, 0x0d, 0x6b, 0xda, 0xc7, 0xc3, 0x9a, 0xf6, 0xe4, 0x93, 0xda, 0xcc, 0x83, 0xdc, 0xe9, + 0xe6, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0x80, 0x43, 0x11, 0x41, 0xbe, 0x1e, 0x00, 0x00, +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto new file mode 100644 index 0000000000..a6be57a87c --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto @@ -0,0 +1,764 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.apimachinery.pkg.apis.meta.v1; + +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// APIGroup contains the name, the supported versions, and the preferred version +// of a group. +message APIGroup { + // name is the name of the group. + optional string name = 1; + + // versions are the versions supported in this group. + repeated GroupVersionForDiscovery versions = 2; + + // preferredVersion is the version preferred by the API server, which + // probably is the storage version. + // +optional + optional GroupVersionForDiscovery preferredVersion = 3; + + // a map of client CIDR to server address that is serving this group. + // This is to help clients reach servers in the most network-efficient way possible. + // Clients can use the appropriate server address as per the CIDR that they match. + // In case of multiple matches, clients should use the longest matching CIDR. + // The server returns only those CIDRs that it thinks that the client can match. + // For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. + // Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP. + repeated ServerAddressByClientCIDR serverAddressByClientCIDRs = 4; +} + +// APIGroupList is a list of APIGroup, to allow clients to discover the API at +// /apis. +message APIGroupList { + // groups is a list of APIGroup. + repeated APIGroup groups = 1; +} + +// APIResource specifies the name of a resource and whether it is namespaced. +message APIResource { + // name is the plural name of the resource. + optional string name = 1; + + // singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. + // The singularName is more correct for reporting status on a single item and both singular and plural are allowed + // from the kubectl CLI interface. + optional string singularName = 6; + + // namespaced indicates if a resource is namespaced or not. + optional bool namespaced = 2; + + // kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo') + optional string kind = 3; + + // verbs is a list of supported kube verbs (this includes get, list, watch, create, + // update, patch, delete, deletecollection, and proxy) + optional Verbs verbs = 4; + + // shortNames is a list of suggested short names of the resource. + repeated string shortNames = 5; + + // categories is a list of the grouped resources this resource belongs to (e.g. 'all') + repeated string categories = 7; +} + +// APIResourceList is a list of APIResource, it is used to expose the name of the +// resources supported in a specific group and version, and if the resource +// is namespaced. +message APIResourceList { + // groupVersion is the group and version this APIResourceList is for. + optional string groupVersion = 1; + + // resources contains the name of the resources and if they are namespaced. + repeated APIResource resources = 2; +} + +// APIVersions lists the versions that are available, to allow clients to +// discover the API at /api, which is the root path of the legacy v1 API. +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +message APIVersions { + // versions are the api versions that are available. + repeated string versions = 1; + + // a map of client CIDR to server address that is serving this group. + // This is to help clients reach servers in the most network-efficient way possible. + // Clients can use the appropriate server address as per the CIDR that they match. + // In case of multiple matches, clients should use the longest matching CIDR. + // The server returns only those CIDRs that it thinks that the client can match. + // For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. + // Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP. + repeated ServerAddressByClientCIDR serverAddressByClientCIDRs = 2; +} + +// DeleteOptions may be provided when deleting an API object. +message DeleteOptions { + // The duration in seconds before the object should be deleted. Value must be non-negative integer. + // The value zero indicates delete immediately. If this value is nil, the default grace period for the + // specified type will be used. + // Defaults to a per object value if not specified. zero means delete immediately. + // +optional + optional int64 gracePeriodSeconds = 1; + + // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be + // returned. + // +optional + optional Preconditions preconditions = 2; + + // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. + // Should the dependent objects be orphaned. If true/false, the "orphan" + // finalizer will be added to/removed from the object's finalizers list. + // Either this field or PropagationPolicy may be set, but not both. + // +optional + optional bool orphanDependents = 3; + + // Whether and how garbage collection will be performed. + // Either this field or OrphanDependents may be set, but not both. + // The default policy is decided by the existing finalizer set in the + // metadata.finalizers and the resource-specific default policy. + // +optional + optional string propagationPolicy = 4; +} + +// Duration is a wrapper around time.Duration which supports correct +// marshaling to YAML and JSON. In particular, it marshals into strings, which +// can be used as map keys in json. +message Duration { + optional int64 duration = 1; +} + +// ExportOptions is the query options to the standard REST get call. +message ExportOptions { + // Should this value be exported. Export strips fields that a user can not specify. + optional bool export = 1; + + // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. + optional bool exact = 2; +} + +// GetOptions is the standard query options to the standard REST get call. +message GetOptions { + // When specified: + // - if unset, then the result is returned from remote storage based on quorum-read flag; + // - if it's 0, then we simply return what we currently have in cache, no guarantee; + // - if set to non zero, then the result is at least as fresh as given rv. + optional string resourceVersion = 1; + + // If true, partially initialized resources are included in the response. + // +optional + optional bool includeUninitialized = 2; +} + +// GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying +// concepts during lookup stages without having partially valid types +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +message GroupKind { + optional string group = 1; + + optional string kind = 2; +} + +// GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying +// concepts during lookup stages without having partially valid types +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +message GroupResource { + optional string group = 1; + + optional string resource = 2; +} + +// GroupVersion contains the "group" and the "version", which uniquely identifies the API. +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +message GroupVersion { + optional string group = 1; + + optional string version = 2; +} + +// GroupVersion contains the "group/version" and "version" string of a version. +// It is made a struct to keep extensibility. +message GroupVersionForDiscovery { + // groupVersion specifies the API group and version in the form "group/version" + optional string groupVersion = 1; + + // version specifies the version in the form of "version". This is to save + // the clients the trouble of splitting the GroupVersion. + optional string version = 2; +} + +// GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion +// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +message GroupVersionKind { + optional string group = 1; + + optional string version = 2; + + optional string kind = 3; +} + +// GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion +// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +message GroupVersionResource { + optional string group = 1; + + optional string version = 2; + + optional string resource = 3; +} + +// Initializer is information about an initializer that has not yet completed. +message Initializer { + // name of the process that is responsible for initializing this object. + optional string name = 1; +} + +// Initializers tracks the progress of initialization. +message Initializers { + // Pending is a list of initializers that must execute in order before this object is visible. + // When the last pending initializer is removed, and no failing result is set, the initializers + // struct will be set to nil and the object is considered as initialized and visible to all + // clients. + repeated Initializer pending = 1; + + // If result is set with the Failure field, the object will be persisted to storage and then deleted, + // ensuring that other clients can observe the deletion. + optional Status result = 2; +} + +// A label selector is a label query over a set of resources. The result of matchLabels and +// matchExpressions are ANDed. An empty label selector matches all objects. A null +// label selector matches no objects. +message LabelSelector { + // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels + // map is equivalent to an element of matchExpressions, whose key field is "key", the + // operator is "In", and the values array contains only "value". The requirements are ANDed. + // +optional + map matchLabels = 1; + + // matchExpressions is a list of label selector requirements. The requirements are ANDed. + // +optional + repeated LabelSelectorRequirement matchExpressions = 2; +} + +// A label selector requirement is a selector that contains values, a key, and an operator that +// relates the key and values. +message LabelSelectorRequirement { + // key is the label key that the selector applies to. + // +patchMergeKey=key + // +patchStrategy=merge + optional string key = 1; + + // operator represents a key's relationship to a set of values. + // Valid operators ard In, NotIn, Exists and DoesNotExist. + optional string operator = 2; + + // values is an array of string values. If the operator is In or NotIn, + // the values array must be non-empty. If the operator is Exists or DoesNotExist, + // the values array must be empty. This array is replaced during a strategic + // merge patch. + // +optional + repeated string values = 3; +} + +// ListMeta describes metadata that synthetic resources must have, including lists and +// various status objects. A resource may have only one of {ObjectMeta, ListMeta}. +message ListMeta { + // SelfLink is a URL representing this object. + // Populated by the system. + // Read-only. + // +optional + optional string selfLink = 1; + + // String that identifies the server's internal version of this object that + // can be used by clients to determine when objects have changed. + // Value must be treated as opaque by clients and passed unmodified back to the server. + // Populated by the system. + // Read-only. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency + // +optional + optional string resourceVersion = 2; +} + +// ListOptions is the query options to a standard REST list call. +message ListOptions { + // A selector to restrict the list of returned objects by their labels. + // Defaults to everything. + // +optional + optional string labelSelector = 1; + + // A selector to restrict the list of returned objects by their fields. + // Defaults to everything. + // +optional + optional string fieldSelector = 2; + + // If true, partially initialized resources are included in the response. + // +optional + optional bool includeUninitialized = 6; + + // Watch for changes to the described resources and return them as a stream of + // add, update, and remove notifications. Specify resourceVersion. + // +optional + optional bool watch = 3; + + // When specified with a watch call, shows changes that occur after that particular version of a resource. + // Defaults to changes from the beginning of history. + // When specified for list: + // - if unset, then the result is returned from remote storage based on quorum-read flag; + // - if it's 0, then we simply return what we currently have in cache, no guarantee; + // - if set to non zero, then the result is at least as fresh as given rv. + // +optional + optional string resourceVersion = 4; + + // Timeout for the list/watch call. + // +optional + optional int64 timeoutSeconds = 5; +} + +// MicroTime is version of Time with microsecond level precision. +// +// +protobuf.options.marshal=false +// +protobuf.as=Timestamp +// +protobuf.options.(gogoproto.goproto_stringer)=false +message MicroTime { + // Represents seconds of UTC time since Unix epoch + // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to + // 9999-12-31T23:59:59Z inclusive. + optional int64 seconds = 1; + + // Non-negative fractions of a second at nanosecond resolution. Negative + // second values with fractions must still have non-negative nanos values + // that count forward in time. Must be from 0 to 999,999,999 + // inclusive. This field may be limited in precision depending on context. + optional int32 nanos = 2; +} + +// ObjectMeta is metadata that all persisted resources must have, which includes all objects +// users must create. +message ObjectMeta { + // Name must be unique within a namespace. Is required when creating resources, although + // some resources may allow a client to request the generation of an appropriate name + // automatically. Name is primarily intended for creation idempotence and configuration + // definition. + // Cannot be updated. + // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // +optional + optional string name = 1; + + // GenerateName is an optional prefix, used by the server, to generate a unique + // name ONLY IF the Name field has not been provided. + // If this field is used, the name returned to the client will be different + // than the name passed. This value will also be combined with a unique suffix. + // The provided value has the same validation rules as the Name field, + // and may be truncated by the length of the suffix required to make the value + // unique on the server. + // + // If this field is specified and the generated name exists, the server will + // NOT return a 409 - instead, it will either return 201 Created or 500 with Reason + // ServerTimeout indicating a unique name could not be found in the time allotted, and the client + // should retry (optionally after the time indicated in the Retry-After header). + // + // Applied only if Name is not specified. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency + // +optional + optional string generateName = 2; + + // Namespace defines the space within each name must be unique. An empty namespace is + // equivalent to the "default" namespace, but "default" is the canonical representation. + // Not all objects are required to be scoped to a namespace - the value of this field for + // those objects will be empty. + // + // Must be a DNS_LABEL. + // Cannot be updated. + // More info: http://kubernetes.io/docs/user-guide/namespaces + // +optional + optional string namespace = 3; + + // SelfLink is a URL representing this object. + // Populated by the system. + // Read-only. + // +optional + optional string selfLink = 4; + + // UID is the unique in time and space value for this object. It is typically generated by + // the server on successful creation of a resource and is not allowed to change on PUT + // operations. + // + // Populated by the system. + // Read-only. + // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // +optional + optional string uid = 5; + + // An opaque value that represents the internal version of this object that can + // be used by clients to determine when objects have changed. May be used for optimistic + // concurrency, change detection, and the watch operation on a resource or set of resources. + // Clients must treat these values as opaque and passed unmodified back to the server. + // They may only be valid for a particular resource or set of resources. + // + // Populated by the system. + // Read-only. + // Value must be treated as opaque by clients and . + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency + // +optional + optional string resourceVersion = 6; + + // A sequence number representing a specific generation of the desired state. + // Populated by the system. Read-only. + // +optional + optional int64 generation = 7; + + // CreationTimestamp is a timestamp representing the server time when this object was + // created. It is not guaranteed to be set in happens-before order across separate operations. + // Clients may not set this value. It is represented in RFC3339 form and is in UTC. + // + // Populated by the system. + // Read-only. + // Null for lists. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional Time creationTimestamp = 8; + + // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This + // field is set by the server when a graceful deletion is requested by the user, and is not + // directly settable by a client. The resource is expected to be deleted (no longer visible + // from resource lists, and not reachable by name) after the time in this field. Once set, + // this value may not be unset or be set further into the future, although it may be shortened + // or the resource may be deleted prior to this time. For example, a user may request that + // a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination + // signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard + // termination signal (SIGKILL) to the container and after cleanup, remove the pod from the + // API. In the presence of network partitions, this object may still exist after this + // timestamp, until an administrator or automated process can determine the resource is + // fully terminated. + // If not set, graceful deletion of the object has not been requested. + // + // Populated by the system when a graceful deletion is requested. + // Read-only. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional Time deletionTimestamp = 9; + + // Number of seconds allowed for this object to gracefully terminate before + // it will be removed from the system. Only set when deletionTimestamp is also set. + // May only be shortened. + // Read-only. + // +optional + optional int64 deletionGracePeriodSeconds = 10; + + // Map of string keys and values that can be used to organize and categorize + // (scope and select) objects. May match selectors of replication controllers + // and services. + // More info: http://kubernetes.io/docs/user-guide/labels + // +optional + map labels = 11; + + // Annotations is an unstructured key value map stored with a resource that may be + // set by external tools to store and retrieve arbitrary metadata. They are not + // queryable and should be preserved when modifying objects. + // More info: http://kubernetes.io/docs/user-guide/annotations + // +optional + map annotations = 12; + + // List of objects depended by this object. If ALL objects in the list have + // been deleted, this object will be garbage collected. If this object is managed by a controller, + // then an entry in this list will point to this controller, with the controller field set to true. + // There cannot be more than one managing controller. + // +optional + // +patchMergeKey=uid + // +patchStrategy=merge + repeated OwnerReference ownerReferences = 13; + + // An initializer is a controller which enforces some system invariant at object creation time. + // This field is a list of initializers that have not yet acted on this object. If nil or empty, + // this object has been completely initialized. Otherwise, the object is considered uninitialized + // and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to + // observe uninitialized objects. + // + // When an object is created, the system will populate this list with the current set of initializers. + // Only privileged users may set or modify this list. Once it is empty, it may not be modified further + // by any user. + optional Initializers initializers = 16; + + // Must be empty before the object is deleted from the registry. Each entry + // is an identifier for the responsible component that will remove the entry + // from the list. If the deletionTimestamp of the object is non-nil, entries + // in this list can only be removed. + // +optional + // +patchStrategy=merge + repeated string finalizers = 14; + + // The name of the cluster which the object belongs to. + // This is used to distinguish resources with same name and namespace in different clusters. + // This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. + // +optional + optional string clusterName = 15; +} + +// OwnerReference contains enough information to let you identify an owning +// object. Currently, an owning object must be in the same namespace, so there +// is no namespace field. +message OwnerReference { + // API version of the referent. + optional string apiVersion = 5; + + // Kind of the referent. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + optional string kind = 1; + + // Name of the referent. + // More info: http://kubernetes.io/docs/user-guide/identifiers#names + optional string name = 3; + + // UID of the referent. + // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + optional string uid = 4; + + // If true, this reference points to the managing controller. + // +optional + optional bool controller = 6; + + // If true, AND if the owner has the "foregroundDeletion" finalizer, then + // the owner cannot be deleted from the key-value store until this + // reference is removed. + // Defaults to false. + // To set this field, a user needs "delete" permission of the owner, + // otherwise 422 (Unprocessable Entity) will be returned. + // +optional + optional bool blockOwnerDeletion = 7; +} + +// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. +message Preconditions { + // Specifies the target UID. + // +optional + optional string uid = 1; +} + +// RootPaths lists the paths available at root. +// For example: "/healthz", "/apis". +message RootPaths { + // paths are the paths available at root. + repeated string paths = 1; +} + +// ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match. +message ServerAddressByClientCIDR { + // The CIDR with which clients can match their IP to figure out the server address that they should use. + optional string clientCIDR = 1; + + // Address of this server, suitable for a client that matches the above CIDR. + // This can be a hostname, hostname:port, IP or IP:port. + optional string serverAddress = 2; +} + +// Status is a return value for calls that don't return other objects. +message Status { + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + optional ListMeta metadata = 1; + + // Status of the operation. + // One of: "Success" or "Failure". + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status + // +optional + optional string status = 2; + + // A human-readable description of the status of this operation. + // +optional + optional string message = 3; + + // A machine-readable description of why this operation is in the + // "Failure" status. If this value is empty there + // is no information available. A Reason clarifies an HTTP status + // code but does not override it. + // +optional + optional string reason = 4; + + // Extended data associated with the reason. Each reason may define its + // own extended details. This field is optional and the data returned + // is not guaranteed to conform to any schema except that defined by + // the reason type. + // +optional + optional StatusDetails details = 5; + + // Suggested HTTP return code for this status, 0 if not set. + // +optional + optional int32 code = 6; +} + +// StatusCause provides more information about an api.Status failure, including +// cases when multiple errors are encountered. +message StatusCause { + // A machine-readable description of the cause of the error. If this value is + // empty there is no information available. + // +optional + optional string reason = 1; + + // A human-readable description of the cause of the error. This field may be + // presented as-is to a reader. + // +optional + optional string message = 2; + + // The field of the resource that has caused this error, as named by its JSON + // serialization. May include dot and postfix notation for nested attributes. + // Arrays are zero-indexed. Fields may appear more than once in an array of + // causes due to fields having multiple errors. + // Optional. + // + // Examples: + // "name" - the field "name" on the current resource + // "items[0].name" - the field "name" on the first array entry in "items" + // +optional + optional string field = 3; +} + +// StatusDetails is a set of additional properties that MAY be set by the +// server to provide additional information about a response. The Reason +// field of a Status object defines what attributes will be set. Clients +// must ignore fields that do not match the defined type of each attribute, +// and should assume that any attribute may be empty, invalid, or under +// defined. +message StatusDetails { + // The name attribute of the resource associated with the status StatusReason + // (when there is a single name which can be described). + // +optional + optional string name = 1; + + // The group attribute of the resource associated with the status StatusReason. + // +optional + optional string group = 2; + + // The kind attribute of the resource associated with the status StatusReason. + // On some operations may differ from the requested resource Kind. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + optional string kind = 3; + + // UID of the resource. + // (when there is a single resource which can be described). + // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // +optional + optional string uid = 6; + + // The Causes array includes more details associated with the StatusReason + // failure. Not all StatusReasons may provide detailed causes. + // +optional + repeated StatusCause causes = 4; + + // If specified, the time in seconds before the operation should be retried. + // +optional + optional int32 retryAfterSeconds = 5; +} + +// Time is a wrapper around time.Time which supports correct +// marshaling to YAML and JSON. Wrappers are provided for many +// of the factory methods that the time package offers. +// +// +protobuf.options.marshal=false +// +protobuf.as=Timestamp +// +protobuf.options.(gogoproto.goproto_stringer)=false +message Time { + // Represents seconds of UTC time since Unix epoch + // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to + // 9999-12-31T23:59:59Z inclusive. + optional int64 seconds = 1; + + // Non-negative fractions of a second at nanosecond resolution. Negative + // second values with fractions must still have non-negative nanos values + // that count forward in time. Must be from 0 to 999,999,999 + // inclusive. This field may be limited in precision depending on context. + optional int32 nanos = 2; +} + +// Timestamp is a struct that is equivalent to Time, but intended for +// protobuf marshalling/unmarshalling. It is generated into a serialization +// that matches Time. Do not use in Go structs. +message Timestamp { + // Represents seconds of UTC time since Unix epoch + // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to + // 9999-12-31T23:59:59Z inclusive. + optional int64 seconds = 1; + + // Non-negative fractions of a second at nanosecond resolution. Negative + // second values with fractions must still have non-negative nanos values + // that count forward in time. Must be from 0 to 999,999,999 + // inclusive. This field may be limited in precision depending on context. + optional int32 nanos = 2; +} + +// TypeMeta describes an individual object in an API response or request +// with strings representing the type of the object and its API schema version. +// Structures that are versioned or persisted should inline TypeMeta. +message TypeMeta { + // Kind is a string value representing the REST resource this object represents. + // Servers may infer this from the endpoint the client submits requests to. + // Cannot be updated. + // In CamelCase. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + optional string kind = 1; + + // APIVersion defines the versioned schema of this representation of an object. + // Servers should convert recognized schemas to the latest internal value, and + // may reject unrecognized values. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + // +optional + optional string apiVersion = 2; +} + +// Verbs masks the value so protobuf can generate +// +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +message Verbs { + // items, if empty, will result in an empty slice + + repeated string items = 1; +} + +// Event represents a single event to a watched resource. +// +// +protobuf=true +message WatchEvent { + optional string type = 1; + + // Object is: + // * If Type is Added or Modified: the new state of the object. + // * If Type is Deleted: the state of the object immediately before deletion. + // * If Type is Error: *Status is recommended; other types may make sense + // depending on context. + optional k8s.io.apimachinery.pkg.runtime.RawExtension object = 2; +} + diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go new file mode 100644 index 0000000000..bd4c6d9b58 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/group_version.go @@ -0,0 +1,148 @@ +/* +Copyright 2015 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "encoding/json" + "fmt" + "strings" + + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying +// concepts during lookup stages without having partially valid types +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +type GroupResource struct { + Group string `json:"group" protobuf:"bytes,1,opt,name=group"` + Resource string `json:"resource" protobuf:"bytes,2,opt,name=resource"` +} + +func (gr *GroupResource) String() string { + if len(gr.Group) == 0 { + return gr.Resource + } + return gr.Resource + "." + gr.Group +} + +// GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion +// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +type GroupVersionResource struct { + Group string `json:"group" protobuf:"bytes,1,opt,name=group"` + Version string `json:"version" protobuf:"bytes,2,opt,name=version"` + Resource string `json:"resource" protobuf:"bytes,3,opt,name=resource"` +} + +func (gvr *GroupVersionResource) String() string { + return strings.Join([]string{gvr.Group, "/", gvr.Version, ", Resource=", gvr.Resource}, "") +} + +// GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying +// concepts during lookup stages without having partially valid types +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +type GroupKind struct { + Group string `json:"group" protobuf:"bytes,1,opt,name=group"` + Kind string `json:"kind" protobuf:"bytes,2,opt,name=kind"` +} + +func (gk *GroupKind) String() string { + if len(gk.Group) == 0 { + return gk.Kind + } + return gk.Kind + "." + gk.Group +} + +// GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion +// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +type GroupVersionKind struct { + Group string `json:"group" protobuf:"bytes,1,opt,name=group"` + Version string `json:"version" protobuf:"bytes,2,opt,name=version"` + Kind string `json:"kind" protobuf:"bytes,3,opt,name=kind"` +} + +func (gvk GroupVersionKind) String() string { + return gvk.Group + "/" + gvk.Version + ", Kind=" + gvk.Kind +} + +// GroupVersion contains the "group" and the "version", which uniquely identifies the API. +// +// +protobuf.options.(gogoproto.goproto_stringer)=false +type GroupVersion struct { + Group string `json:"group" protobuf:"bytes,1,opt,name=group"` + Version string `json:"version" protobuf:"bytes,2,opt,name=version"` +} + +// Empty returns true if group and version are empty +func (gv GroupVersion) Empty() bool { + return len(gv.Group) == 0 && len(gv.Version) == 0 +} + +// String puts "group" and "version" into a single "group/version" string. For the legacy v1 +// it returns "v1". +func (gv GroupVersion) String() string { + // special case the internal apiVersion for the legacy kube types + if gv.Empty() { + return "" + } + + // special case of "v1" for backward compatibility + if len(gv.Group) == 0 && gv.Version == "v1" { + return gv.Version + } + if len(gv.Group) > 0 { + return gv.Group + "/" + gv.Version + } + return gv.Version +} + +// MarshalJSON implements the json.Marshaller interface. +func (gv GroupVersion) MarshalJSON() ([]byte, error) { + s := gv.String() + if strings.Count(s, "/") > 1 { + return []byte{}, fmt.Errorf("illegal GroupVersion %v: contains more than one /", s) + } + return json.Marshal(s) +} + +func (gv *GroupVersion) unmarshal(value []byte) error { + var s string + if err := json.Unmarshal(value, &s); err != nil { + return err + } + parsed, err := schema.ParseGroupVersion(s) + if err != nil { + return err + } + gv.Group, gv.Version = parsed.Group, parsed.Version + return nil +} + +// UnmarshalJSON implements the json.Unmarshaller interface. +func (gv *GroupVersion) UnmarshalJSON(value []byte) error { + return gv.unmarshal(value) +} + +// UnmarshalTEXT implements the Ugorji's encoding.TextUnmarshaler interface. +func (gv *GroupVersion) UnmarshalText(value []byte) error { + return gv.unmarshal(value) +} diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/helpers.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go similarity index 75% rename from vendor/k8s.io/client-go/pkg/api/unversioned/helpers.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go index 8ef9b038c7..d845d7b0ff 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/helpers.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/helpers.go @@ -14,13 +14,15 @@ See the License for the specific language governing permissions and limitations under the License. */ -package unversioned +package v1 import ( "fmt" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/selection" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/selection" + "k8s.io/apimachinery/pkg/types" ) // LabelSelectorAsSelector converts the LabelSelector api type into a struct that implements @@ -181,3 +183,52 @@ func ExtractGroupVersions(l *APIGroupList) []string { } return groupVersions } + +// HasAnnotation returns a bool if passed in annotation exists +func HasAnnotation(obj ObjectMeta, ann string) bool { + _, found := obj.Annotations[ann] + return found +} + +// SetMetaDataAnnotation sets the annotation and value +func SetMetaDataAnnotation(obj *ObjectMeta, ann string, value string) { + if obj.Annotations == nil { + obj.Annotations = make(map[string]string) + } + obj.Annotations[ann] = value +} + +// SingleObject returns a ListOptions for watching a single object. +func SingleObject(meta ObjectMeta) ListOptions { + return ListOptions{ + FieldSelector: fields.OneTermEqualSelector("metadata.name", meta.Name).String(), + ResourceVersion: meta.ResourceVersion, + } +} + +// NewDeleteOptions returns a DeleteOptions indicating the resource should +// be deleted within the specified grace period. Use zero to indicate +// immediate deletion. If you would prefer to use the default grace period, +// use &metav1.DeleteOptions{} directly. +func NewDeleteOptions(grace int64) *DeleteOptions { + return &DeleteOptions{GracePeriodSeconds: &grace} +} + +// NewPreconditionDeleteOptions returns a DeleteOptions with a UID precondition set. +func NewPreconditionDeleteOptions(uid string) *DeleteOptions { + u := types.UID(uid) + p := Preconditions{UID: &u} + return &DeleteOptions{Preconditions: &p} +} + +// NewUIDPreconditions returns a Preconditions with UID set. +func NewUIDPreconditions(uid string) *Preconditions { + u := types.UID(uid) + return &Preconditions{UID: &u} +} + +// HasObjectMetaSystemFieldValues returns true if fields that are managed by the system on ObjectMeta have values. +func HasObjectMetaSystemFieldValues(meta Object) bool { + return !meta.GetCreationTimestamp().Time.IsZero() || + len(meta.GetUID()) != 0 +} diff --git a/vendor/k8s.io/client-go/pkg/util/labels/labels.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/labels.go similarity index 50% rename from vendor/k8s.io/client-go/pkg/util/labels/labels.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/labels.go index 3e1f623e54..8b4c0423e6 100644 --- a/vendor/k8s.io/client-go/pkg/util/labels/labels.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/labels.go @@ -14,69 +14,18 @@ See the License for the specific language governing permissions and limitations under the License. */ -package labels - -import ( - "fmt" - - "k8s.io/client-go/pkg/api/unversioned" -) - -// Clones the given map and returns a new map with the given key and value added. -// Returns the given map, if labelKey is empty. -func CloneAndAddLabel(labels map[string]string, labelKey string, labelValue uint32) map[string]string { - if labelKey == "" { - // Don't need to add a label. - return labels - } - // Clone. - newLabels := map[string]string{} - for key, value := range labels { - newLabels[key] = value - } - newLabels[labelKey] = fmt.Sprintf("%d", labelValue) - return newLabels -} - -// CloneAndRemoveLabel clones the given map and returns a new map with the given key removed. -// Returns the given map, if labelKey is empty. -func CloneAndRemoveLabel(labels map[string]string, labelKey string) map[string]string { - if labelKey == "" { - // Don't need to add a label. - return labels - } - // Clone. - newLabels := map[string]string{} - for key, value := range labels { - newLabels[key] = value - } - delete(newLabels, labelKey) - return newLabels -} - -// AddLabel returns a map with the given key and value added to the given map. -func AddLabel(labels map[string]string, labelKey string, labelValue string) map[string]string { - if labelKey == "" { - // Don't need to add a label. - return labels - } - if labels == nil { - labels = make(map[string]string) - } - labels[labelKey] = labelValue - return labels -} +package v1 // Clones the given selector and returns a new selector with the given key and value added. // Returns the given selector, if labelKey is empty. -func CloneSelectorAndAddLabel(selector *unversioned.LabelSelector, labelKey string, labelValue uint32) *unversioned.LabelSelector { +func CloneSelectorAndAddLabel(selector *LabelSelector, labelKey, labelValue string) *LabelSelector { if labelKey == "" { // Don't need to add a label. return selector } // Clone. - newSelector := new(unversioned.LabelSelector) + newSelector := new(LabelSelector) // TODO(madhusudancs): Check if you can use deepCopy_extensions_LabelSelector here. newSelector.MatchLabels = make(map[string]string) @@ -85,10 +34,10 @@ func CloneSelectorAndAddLabel(selector *unversioned.LabelSelector, labelKey stri newSelector.MatchLabels[key] = val } } - newSelector.MatchLabels[labelKey] = fmt.Sprintf("%d", labelValue) + newSelector.MatchLabels[labelKey] = labelValue if selector.MatchExpressions != nil { - newMExps := make([]unversioned.LabelSelectorRequirement, len(selector.MatchExpressions)) + newMExps := make([]LabelSelectorRequirement, len(selector.MatchExpressions)) for i, me := range selector.MatchExpressions { newMExps[i].Key = me.Key newMExps[i].Operator = me.Operator @@ -108,7 +57,7 @@ func CloneSelectorAndAddLabel(selector *unversioned.LabelSelector, labelKey stri } // AddLabelToSelector returns a selector with the given key and value added to the given selector's MatchLabels. -func AddLabelToSelector(selector *unversioned.LabelSelector, labelKey string, labelValue string) *unversioned.LabelSelector { +func AddLabelToSelector(selector *LabelSelector, labelKey, labelValue string) *LabelSelector { if labelKey == "" { // Don't need to add a label. return selector @@ -121,6 +70,6 @@ func AddLabelToSelector(selector *unversioned.LabelSelector, labelKey string, la } // SelectorHasLabel checks if the given selector contains the given label key in its MatchLabels -func SelectorHasLabel(selector *unversioned.LabelSelector, labelKey string) bool { +func SelectorHasLabel(selector *LabelSelector, labelKey string) bool { return len(selector.MatchLabels[labelKey]) > 0 } diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/meta.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/meta.go new file mode 100644 index 0000000000..0ee7d99ca1 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/meta.go @@ -0,0 +1,201 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" +) + +// TODO: move this, Object, List, and Type to a different package +type ObjectMetaAccessor interface { + GetObjectMeta() Object +} + +// Object lets you work with object metadata from any of the versioned or +// internal API objects. Attempting to set or retrieve a field on an object that does +// not support that field (Name, UID, Namespace on lists) will be a no-op and return +// a default value. +type Object interface { + GetNamespace() string + SetNamespace(namespace string) + GetName() string + SetName(name string) + GetGenerateName() string + SetGenerateName(name string) + GetUID() types.UID + SetUID(uid types.UID) + GetResourceVersion() string + SetResourceVersion(version string) + GetGeneration() int64 + SetGeneration(generation int64) + GetSelfLink() string + SetSelfLink(selfLink string) + GetCreationTimestamp() Time + SetCreationTimestamp(timestamp Time) + GetDeletionTimestamp() *Time + SetDeletionTimestamp(timestamp *Time) + GetDeletionGracePeriodSeconds() *int64 + SetDeletionGracePeriodSeconds(*int64) + GetLabels() map[string]string + SetLabels(labels map[string]string) + GetAnnotations() map[string]string + SetAnnotations(annotations map[string]string) + GetInitializers() *Initializers + SetInitializers(initializers *Initializers) + GetFinalizers() []string + SetFinalizers(finalizers []string) + GetOwnerReferences() []OwnerReference + SetOwnerReferences([]OwnerReference) + GetClusterName() string + SetClusterName(clusterName string) +} + +// ListMetaAccessor retrieves the list interface from an object +type ListMetaAccessor interface { + GetListMeta() List +} + +// List lets you work with list metadata from any of the versioned or +// internal API objects. Attempting to set or retrieve a field on an object that does +// not support that field will be a no-op and return a default value. +// TODO: move this, and TypeMeta and ListMeta, to a different package +type List interface { + GetResourceVersion() string + SetResourceVersion(version string) + GetSelfLink() string + SetSelfLink(selfLink string) +} + +// Type exposes the type and APIVersion of versioned or internal API objects. +// TODO: move this, and TypeMeta and ListMeta, to a different package +type Type interface { + GetAPIVersion() string + SetAPIVersion(version string) + GetKind() string + SetKind(kind string) +} + +func (meta *ListMeta) GetResourceVersion() string { return meta.ResourceVersion } +func (meta *ListMeta) SetResourceVersion(version string) { meta.ResourceVersion = version } +func (meta *ListMeta) GetSelfLink() string { return meta.SelfLink } +func (meta *ListMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink } + +func (obj *TypeMeta) GetObjectKind() schema.ObjectKind { return obj } + +// SetGroupVersionKind satisfies the ObjectKind interface for all objects that embed TypeMeta +func (obj *TypeMeta) SetGroupVersionKind(gvk schema.GroupVersionKind) { + obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() +} + +// GroupVersionKind satisfies the ObjectKind interface for all objects that embed TypeMeta +func (obj *TypeMeta) GroupVersionKind() schema.GroupVersionKind { + return schema.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) +} + +func (obj *ListMeta) GetListMeta() List { return obj } + +func (obj *ObjectMeta) GetObjectMeta() Object { return obj } + +// Namespace implements metav1.Object for any object with an ObjectMeta typed field. Allows +// fast, direct access to metadata fields for API objects. +func (meta *ObjectMeta) GetNamespace() string { return meta.Namespace } +func (meta *ObjectMeta) SetNamespace(namespace string) { meta.Namespace = namespace } +func (meta *ObjectMeta) GetName() string { return meta.Name } +func (meta *ObjectMeta) SetName(name string) { meta.Name = name } +func (meta *ObjectMeta) GetGenerateName() string { return meta.GenerateName } +func (meta *ObjectMeta) SetGenerateName(generateName string) { meta.GenerateName = generateName } +func (meta *ObjectMeta) GetUID() types.UID { return meta.UID } +func (meta *ObjectMeta) SetUID(uid types.UID) { meta.UID = uid } +func (meta *ObjectMeta) GetResourceVersion() string { return meta.ResourceVersion } +func (meta *ObjectMeta) SetResourceVersion(version string) { meta.ResourceVersion = version } +func (meta *ObjectMeta) GetGeneration() int64 { return meta.Generation } +func (meta *ObjectMeta) SetGeneration(generation int64) { meta.Generation = generation } +func (meta *ObjectMeta) GetSelfLink() string { return meta.SelfLink } +func (meta *ObjectMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink } +func (meta *ObjectMeta) GetCreationTimestamp() Time { return meta.CreationTimestamp } +func (meta *ObjectMeta) SetCreationTimestamp(creationTimestamp Time) { + meta.CreationTimestamp = creationTimestamp +} +func (meta *ObjectMeta) GetDeletionTimestamp() *Time { return meta.DeletionTimestamp } +func (meta *ObjectMeta) SetDeletionTimestamp(deletionTimestamp *Time) { + meta.DeletionTimestamp = deletionTimestamp +} +func (meta *ObjectMeta) GetDeletionGracePeriodSeconds() *int64 { return meta.DeletionGracePeriodSeconds } +func (meta *ObjectMeta) SetDeletionGracePeriodSeconds(deletionGracePeriodSeconds *int64) { + meta.DeletionGracePeriodSeconds = deletionGracePeriodSeconds +} +func (meta *ObjectMeta) GetLabels() map[string]string { return meta.Labels } +func (meta *ObjectMeta) SetLabels(labels map[string]string) { meta.Labels = labels } +func (meta *ObjectMeta) GetAnnotations() map[string]string { return meta.Annotations } +func (meta *ObjectMeta) SetAnnotations(annotations map[string]string) { meta.Annotations = annotations } +func (meta *ObjectMeta) GetInitializers() *Initializers { return meta.Initializers } +func (meta *ObjectMeta) SetInitializers(initializers *Initializers) { meta.Initializers = initializers } +func (meta *ObjectMeta) GetFinalizers() []string { return meta.Finalizers } +func (meta *ObjectMeta) SetFinalizers(finalizers []string) { meta.Finalizers = finalizers } + +func (meta *ObjectMeta) GetOwnerReferences() []OwnerReference { + if meta.OwnerReferences == nil { + return nil + } + ret := make([]OwnerReference, len(meta.OwnerReferences)) + for i := 0; i < len(meta.OwnerReferences); i++ { + ret[i].Kind = meta.OwnerReferences[i].Kind + ret[i].Name = meta.OwnerReferences[i].Name + ret[i].UID = meta.OwnerReferences[i].UID + ret[i].APIVersion = meta.OwnerReferences[i].APIVersion + if meta.OwnerReferences[i].Controller != nil { + value := *meta.OwnerReferences[i].Controller + ret[i].Controller = &value + } + if meta.OwnerReferences[i].BlockOwnerDeletion != nil { + value := *meta.OwnerReferences[i].BlockOwnerDeletion + ret[i].BlockOwnerDeletion = &value + } + } + return ret +} + +func (meta *ObjectMeta) SetOwnerReferences(references []OwnerReference) { + if references == nil { + meta.OwnerReferences = nil + return + } + newReferences := make([]OwnerReference, len(references)) + for i := 0; i < len(references); i++ { + newReferences[i].Kind = references[i].Kind + newReferences[i].Name = references[i].Name + newReferences[i].UID = references[i].UID + newReferences[i].APIVersion = references[i].APIVersion + if references[i].Controller != nil { + value := *references[i].Controller + newReferences[i].Controller = &value + } + if references[i].BlockOwnerDeletion != nil { + value := *references[i].BlockOwnerDeletion + newReferences[i].BlockOwnerDeletion = &value + } + } + meta.OwnerReferences = newReferences +} + +func (meta *ObjectMeta) GetClusterName() string { + return meta.ClusterName +} +func (meta *ObjectMeta) SetClusterName(clusterName string) { + meta.ClusterName = clusterName +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go new file mode 100644 index 0000000000..d55f446b0d --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time.go @@ -0,0 +1,184 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "encoding/json" + "time" + + "k8s.io/apimachinery/pkg/openapi" + + "github.com/go-openapi/spec" + "github.com/google/gofuzz" +) + +const RFC3339Micro = "2006-01-02T15:04:05.000000Z07:00" + +// MicroTime is version of Time with microsecond level precision. +// +// +protobuf.options.marshal=false +// +protobuf.as=Timestamp +// +protobuf.options.(gogoproto.goproto_stringer)=false +type MicroTime struct { + time.Time `protobuf:"-"` +} + +// DeepCopy returns a deep-copy of the MicroTime value. The underlying time.Time +// type is effectively immutable in the time API, so it is safe to +// copy-by-assign, despite the presence of (unexported) Pointer fields. +func (t MicroTime) DeepCopy() MicroTime { + return t +} + +// String returns the representation of the time. +func (t MicroTime) String() string { + return t.Time.String() +} + +// NewMicroTime returns a wrapped instance of the provided time +func NewMicroTime(time time.Time) MicroTime { + return MicroTime{time} +} + +// DateMicro returns the MicroTime corresponding to the supplied parameters +// by wrapping time.Date. +func DateMicro(year int, month time.Month, day, hour, min, sec, nsec int, loc *time.Location) MicroTime { + return MicroTime{time.Date(year, month, day, hour, min, sec, nsec, loc)} +} + +// NowMicro returns the current local time. +func NowMicro() MicroTime { + return MicroTime{time.Now()} +} + +// IsZero returns true if the value is nil or time is zero. +func (t *MicroTime) IsZero() bool { + if t == nil { + return true + } + return t.Time.IsZero() +} + +// Before reports whether the time instant t is before u. +func (t MicroTime) Before(u MicroTime) bool { + return t.Time.Before(u.Time) +} + +// Equal reports whether the time instant t is equal to u. +func (t MicroTime) Equal(u MicroTime) bool { + return t.Time.Equal(u.Time) +} + +// BeforeTime reports whether the time instant t is before second-lever precision u. +func (t MicroTime) BeforeTime(u Time) bool { + return t.Time.Before(u.Time) +} + +// EqualTime reports whether the time instant t is equal to second-lever precision u. +func (t MicroTime) EqualTime(u Time) bool { + return t.Time.Equal(u.Time) +} + +// UnixMicro returns the local time corresponding to the given Unix time +// by wrapping time.Unix. +func UnixMicro(sec int64, nsec int64) MicroTime { + return MicroTime{time.Unix(sec, nsec)} +} + +// UnmarshalJSON implements the json.Unmarshaller interface. +func (t *MicroTime) UnmarshalJSON(b []byte) error { + if len(b) == 4 && string(b) == "null" { + t.Time = time.Time{} + return nil + } + + var str string + json.Unmarshal(b, &str) + + pt, err := time.Parse(RFC3339Micro, str) + if err != nil { + return err + } + + t.Time = pt.Local() + return nil +} + +// UnmarshalQueryParameter converts from a URL query parameter value to an object +func (t *MicroTime) UnmarshalQueryParameter(str string) error { + if len(str) == 0 { + t.Time = time.Time{} + return nil + } + // Tolerate requests from older clients that used JSON serialization to build query params + if len(str) == 4 && str == "null" { + t.Time = time.Time{} + return nil + } + + pt, err := time.Parse(RFC3339Micro, str) + if err != nil { + return err + } + + t.Time = pt.Local() + return nil +} + +// MarshalJSON implements the json.Marshaler interface. +func (t MicroTime) MarshalJSON() ([]byte, error) { + if t.IsZero() { + // Encode unset/nil objects as JSON's "null". + return []byte("null"), nil + } + + return json.Marshal(t.UTC().Format(RFC3339Micro)) +} + +func (_ MicroTime) OpenAPIDefinition() openapi.OpenAPIDefinition { + return openapi.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "date-time", + }, + }, + } +} + +// MarshalQueryParameter converts to a URL query parameter value +func (t MicroTime) MarshalQueryParameter() (string, error) { + if t.IsZero() { + // Encode unset/nil objects as an empty string + return "", nil + } + + return t.UTC().Format(RFC3339Micro), nil +} + +// Fuzz satisfies fuzz.Interface. +func (t *MicroTime) Fuzz(c fuzz.Continue) { + if t == nil { + return + } + // Allow for about 1000 years of randomness. Leave off nanoseconds + // because JSON doesn't represent them so they can't round-trip + // properly. + t.Time = time.Unix(c.Rand.Int63n(1000*365*24*60*60*1000*1000), 0) +} + +var _ fuzz.Interface = &MicroTime{} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go new file mode 100644 index 0000000000..14841be512 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/micro_time_proto.go @@ -0,0 +1,72 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "time" +) + +// Timestamp is declared in time_proto.go + +// Timestamp returns the Time as a new Timestamp value. +func (m *MicroTime) ProtoMicroTime() *Timestamp { + if m == nil { + return &Timestamp{} + } + return &Timestamp{ + Seconds: m.Time.Unix(), + Nanos: int32(m.Time.Nanosecond()), + } +} + +// Size implements the protobuf marshalling interface. +func (m *MicroTime) Size() (n int) { + if m == nil || m.Time.IsZero() { + return 0 + } + return m.ProtoMicroTime().Size() +} + +// Reset implements the protobuf marshalling interface. +func (m *MicroTime) Unmarshal(data []byte) error { + if len(data) == 0 { + m.Time = time.Time{} + return nil + } + p := Timestamp{} + if err := p.Unmarshal(data); err != nil { + return err + } + m.Time = time.Unix(p.Seconds, int64(p.Nanos)).Local() + return nil +} + +// Marshal implements the protobuf marshalling interface. +func (m *MicroTime) Marshal() (data []byte, err error) { + if m == nil || m.Time.IsZero() { + return nil, nil + } + return m.ProtoMicroTime().Marshal() +} + +// MarshalTo implements the protobuf marshalling interface. +func (m *MicroTime) MarshalTo(data []byte) (int, error) { + if m == nil || m.Time.IsZero() { + return 0, nil + } + return m.ProtoMicroTime().MarshalTo(data) +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/register.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/register.go new file mode 100644 index 0000000000..6e449a436a --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/register.go @@ -0,0 +1,95 @@ +/* +Copyright 2014 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name for this API. +const GroupName = "meta.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Unversioned is group version for unversioned API objects +// TODO: this should be v1 probably +var Unversioned = schema.GroupVersion{Group: "", Version: "v1"} + +// WatchEventKind is name reserved for serializing watch events. +const WatchEventKind = "WatchEvent" + +// Kind takes an unqualified kind and returns a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// AddToGroupVersion registers common meta types into schemas. +func AddToGroupVersion(scheme *runtime.Scheme, groupVersion schema.GroupVersion) { + scheme.AddKnownTypeWithName(groupVersion.WithKind(WatchEventKind), &WatchEvent{}) + scheme.AddKnownTypeWithName( + schema.GroupVersion{Group: groupVersion.Group, Version: runtime.APIVersionInternal}.WithKind(WatchEventKind), + &InternalEvent{}, + ) + // Supports legacy code paths, most callers should use metav1.ParameterCodec for now + scheme.AddKnownTypes(groupVersion, + &ListOptions{}, + &ExportOptions{}, + &GetOptions{}, + &DeleteOptions{}, + ) + scheme.AddConversionFuncs( + Convert_versioned_Event_to_watch_Event, + Convert_versioned_InternalEvent_to_versioned_Event, + Convert_watch_Event_to_versioned_Event, + Convert_versioned_Event_to_versioned_InternalEvent, + ) + + // Register Unversioned types under their own special group + scheme.AddUnversionedTypes(Unversioned, + &Status{}, + &APIVersions{}, + &APIGroupList{}, + &APIGroup{}, + &APIResourceList{}, + ) + + // register manually. This usually goes through the SchemeBuilder, which we cannot use here. + scheme.AddGeneratedDeepCopyFuncs(GetGeneratedDeepCopyFuncs()...) + AddConversionFuncs(scheme) + RegisterDefaults(scheme) +} + +// scheme is the registry for the common types that adhere to the meta v1 API spec. +var scheme = runtime.NewScheme() + +// ParameterCodec knows about query parameters used with the meta v1 API spec. +var ParameterCodec = runtime.NewParameterCodec(scheme) + +func init() { + scheme.AddUnversionedTypes(SchemeGroupVersion, + &ListOptions{}, + &ExportOptions{}, + &GetOptions{}, + &DeleteOptions{}, + ) + + // register manually. This usually goes through the SchemeBuilder, which we cannot use here. + scheme.AddGeneratedDeepCopyFuncs(GetGeneratedDeepCopyFuncs()...) + RegisterDefaults(scheme) +} diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/time.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/time.go similarity index 96% rename from vendor/k8s.io/client-go/pkg/api/unversioned/time.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/time.go index d490f3bb9a..a1e01f3443 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/time.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/time.go @@ -14,13 +14,13 @@ See the License for the specific language governing permissions and limitations under the License. */ -package unversioned +package v1 import ( "encoding/json" "time" - "k8s.io/client-go/pkg/genericapiserver/openapi/common" + "k8s.io/apimachinery/pkg/openapi" "github.com/go-openapi/spec" "github.com/google/gofuzz" @@ -145,8 +145,8 @@ func (t Time) MarshalJSON() ([]byte, error) { return json.Marshal(t.UTC().Format(time.RFC3339)) } -func (_ Time) OpenAPIDefinition() common.OpenAPIDefinition { - return common.OpenAPIDefinition{ +func (_ Time) OpenAPIDefinition() openapi.OpenAPIDefinition { + return openapi.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"string"}, diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/time_proto.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/time_proto.go similarity index 96% rename from vendor/k8s.io/client-go/pkg/api/unversioned/time_proto.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/time_proto.go index ba25e9164f..5520529dd3 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/time_proto.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/time_proto.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package unversioned +package v1 import ( "time" @@ -25,7 +25,7 @@ import ( // that matches Time. Do not use in Go structs. type Timestamp struct { // Represents seconds of UTC time since Unix epoch - // 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to + // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to // 9999-12-31T23:59:59Z inclusive. Seconds int64 `json:"seconds" protobuf:"varint,1,opt,name=seconds"` // Non-negative fractions of a second at nanosecond resolution. Negative diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/types.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go similarity index 54% rename from vendor/k8s.io/client-go/pkg/api/unversioned/types.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go index 6178f199b8..c5ac31f791 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/types.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types.go @@ -23,9 +23,14 @@ limitations under the License. // (e.g. LabelSelector). // In the future, we will probably move these categories of objects into // separate packages. -package unversioned +package v1 -import "strings" +import ( + "fmt" + "strings" + + "k8s.io/apimachinery/pkg/types" +) // TypeMeta describes an individual object in an API response or request // with strings representing the type of the object and its API schema version. @@ -35,14 +40,14 @@ type TypeMeta struct { // Servers may infer this from the endpoint the client submits requests to. // Cannot be updated. // In CamelCase. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"` // APIVersion defines the versioned schema of this representation of an object. // Servers should convert recognized schemas to the latest internal value, and // may reject unrecognized values. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources // +optional APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,2,opt,name=apiVersion"` } @@ -61,31 +66,359 @@ type ListMeta struct { // Value must be treated as opaque by clients and passed unmodified back to the server. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency // +optional ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,2,opt,name=resourceVersion"` } +// These are internal finalizer values for Kubernetes-like APIs, must be qualified name unless defined here +const ( + FinalizerOrphanDependents string = "orphan" + FinalizerDeleteDependents string = "foregroundDeletion" +) + +// ObjectMeta is metadata that all persisted resources must have, which includes all objects +// users must create. +type ObjectMeta struct { + // Name must be unique within a namespace. Is required when creating resources, although + // some resources may allow a client to request the generation of an appropriate name + // automatically. Name is primarily intended for creation idempotence and configuration + // definition. + // Cannot be updated. + // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // +optional + Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"` + + // GenerateName is an optional prefix, used by the server, to generate a unique + // name ONLY IF the Name field has not been provided. + // If this field is used, the name returned to the client will be different + // than the name passed. This value will also be combined with a unique suffix. + // The provided value has the same validation rules as the Name field, + // and may be truncated by the length of the suffix required to make the value + // unique on the server. + // + // If this field is specified and the generated name exists, the server will + // NOT return a 409 - instead, it will either return 201 Created or 500 with Reason + // ServerTimeout indicating a unique name could not be found in the time allotted, and the client + // should retry (optionally after the time indicated in the Retry-After header). + // + // Applied only if Name is not specified. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency + // +optional + GenerateName string `json:"generateName,omitempty" protobuf:"bytes,2,opt,name=generateName"` + + // Namespace defines the space within each name must be unique. An empty namespace is + // equivalent to the "default" namespace, but "default" is the canonical representation. + // Not all objects are required to be scoped to a namespace - the value of this field for + // those objects will be empty. + // + // Must be a DNS_LABEL. + // Cannot be updated. + // More info: http://kubernetes.io/docs/user-guide/namespaces + // +optional + Namespace string `json:"namespace,omitempty" protobuf:"bytes,3,opt,name=namespace"` + + // SelfLink is a URL representing this object. + // Populated by the system. + // Read-only. + // +optional + SelfLink string `json:"selfLink,omitempty" protobuf:"bytes,4,opt,name=selfLink"` + + // UID is the unique in time and space value for this object. It is typically generated by + // the server on successful creation of a resource and is not allowed to change on PUT + // operations. + // + // Populated by the system. + // Read-only. + // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // +optional + UID types.UID `json:"uid,omitempty" protobuf:"bytes,5,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"` + + // An opaque value that represents the internal version of this object that can + // be used by clients to determine when objects have changed. May be used for optimistic + // concurrency, change detection, and the watch operation on a resource or set of resources. + // Clients must treat these values as opaque and passed unmodified back to the server. + // They may only be valid for a particular resource or set of resources. + // + // Populated by the system. + // Read-only. + // Value must be treated as opaque by clients and . + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency + // +optional + ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,6,opt,name=resourceVersion"` + + // A sequence number representing a specific generation of the desired state. + // Populated by the system. Read-only. + // +optional + Generation int64 `json:"generation,omitempty" protobuf:"varint,7,opt,name=generation"` + + // CreationTimestamp is a timestamp representing the server time when this object was + // created. It is not guaranteed to be set in happens-before order across separate operations. + // Clients may not set this value. It is represented in RFC3339 form and is in UTC. + // + // Populated by the system. + // Read-only. + // Null for lists. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + CreationTimestamp Time `json:"creationTimestamp,omitempty" protobuf:"bytes,8,opt,name=creationTimestamp"` + + // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This + // field is set by the server when a graceful deletion is requested by the user, and is not + // directly settable by a client. The resource is expected to be deleted (no longer visible + // from resource lists, and not reachable by name) after the time in this field. Once set, + // this value may not be unset or be set further into the future, although it may be shortened + // or the resource may be deleted prior to this time. For example, a user may request that + // a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination + // signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard + // termination signal (SIGKILL) to the container and after cleanup, remove the pod from the + // API. In the presence of network partitions, this object may still exist after this + // timestamp, until an administrator or automated process can determine the resource is + // fully terminated. + // If not set, graceful deletion of the object has not been requested. + // + // Populated by the system when a graceful deletion is requested. + // Read-only. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + DeletionTimestamp *Time `json:"deletionTimestamp,omitempty" protobuf:"bytes,9,opt,name=deletionTimestamp"` + + // Number of seconds allowed for this object to gracefully terminate before + // it will be removed from the system. Only set when deletionTimestamp is also set. + // May only be shortened. + // Read-only. + // +optional + DeletionGracePeriodSeconds *int64 `json:"deletionGracePeriodSeconds,omitempty" protobuf:"varint,10,opt,name=deletionGracePeriodSeconds"` + + // Map of string keys and values that can be used to organize and categorize + // (scope and select) objects. May match selectors of replication controllers + // and services. + // More info: http://kubernetes.io/docs/user-guide/labels + // +optional + Labels map[string]string `json:"labels,omitempty" protobuf:"bytes,11,rep,name=labels"` + + // Annotations is an unstructured key value map stored with a resource that may be + // set by external tools to store and retrieve arbitrary metadata. They are not + // queryable and should be preserved when modifying objects. + // More info: http://kubernetes.io/docs/user-guide/annotations + // +optional + Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,12,rep,name=annotations"` + + // List of objects depended by this object. If ALL objects in the list have + // been deleted, this object will be garbage collected. If this object is managed by a controller, + // then an entry in this list will point to this controller, with the controller field set to true. + // There cannot be more than one managing controller. + // +optional + // +patchMergeKey=uid + // +patchStrategy=merge + OwnerReferences []OwnerReference `json:"ownerReferences,omitempty" patchStrategy:"merge" patchMergeKey:"uid" protobuf:"bytes,13,rep,name=ownerReferences"` + + // An initializer is a controller which enforces some system invariant at object creation time. + // This field is a list of initializers that have not yet acted on this object. If nil or empty, + // this object has been completely initialized. Otherwise, the object is considered uninitialized + // and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to + // observe uninitialized objects. + // + // When an object is created, the system will populate this list with the current set of initializers. + // Only privileged users may set or modify this list. Once it is empty, it may not be modified further + // by any user. + Initializers *Initializers `json:"initializers,omitempty" protobuf:"bytes,16,opt,name=initializers"` + + // Must be empty before the object is deleted from the registry. Each entry + // is an identifier for the responsible component that will remove the entry + // from the list. If the deletionTimestamp of the object is non-nil, entries + // in this list can only be removed. + // +optional + // +patchStrategy=merge + Finalizers []string `json:"finalizers,omitempty" patchStrategy:"merge" protobuf:"bytes,14,rep,name=finalizers"` + + // The name of the cluster which the object belongs to. + // This is used to distinguish resources with same name and namespace in different clusters. + // This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. + // +optional + ClusterName string `json:"clusterName,omitempty" protobuf:"bytes,15,opt,name=clusterName"` +} + +// Initializers tracks the progress of initialization. +type Initializers struct { + // Pending is a list of initializers that must execute in order before this object is visible. + // When the last pending initializer is removed, and no failing result is set, the initializers + // struct will be set to nil and the object is considered as initialized and visible to all + // clients. + Pending []Initializer `json:"pending" protobuf:"bytes,1,rep,name=pending"` + // If result is set with the Failure field, the object will be persisted to storage and then deleted, + // ensuring that other clients can observe the deletion. + Result *Status `json:"result,omitempty" protobuf:"bytes,2,opt,name=result"` +} + +// Initializer is information about an initializer that has not yet completed. +type Initializer struct { + // name of the process that is responsible for initializing this object. + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` +} + +const ( + // NamespaceDefault means the object is in the default namespace which is applied when not specified by clients + NamespaceDefault string = "default" + // NamespaceAll is the default argument to specify on a context when you want to list or filter resources across all namespaces + NamespaceAll string = "" + // NamespaceNone is the argument for a context when there is no namespace. + NamespaceNone string = "" + // NamespaceSystem is the system namespace where we place system components. + NamespaceSystem string = "kube-system" + // NamespacePublic is the namespace where we place public info (ConfigMaps) + NamespacePublic string = "kube-public" +) + +// OwnerReference contains enough information to let you identify an owning +// object. Currently, an owning object must be in the same namespace, so there +// is no namespace field. +type OwnerReference struct { + // API version of the referent. + APIVersion string `json:"apiVersion" protobuf:"bytes,5,opt,name=apiVersion"` + // Kind of the referent. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` + // Name of the referent. + // More info: http://kubernetes.io/docs/user-guide/identifiers#names + Name string `json:"name" protobuf:"bytes,3,opt,name=name"` + // UID of the referent. + // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + UID types.UID `json:"uid" protobuf:"bytes,4,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"` + // If true, this reference points to the managing controller. + // +optional + Controller *bool `json:"controller,omitempty" protobuf:"varint,6,opt,name=controller"` + // If true, AND if the owner has the "foregroundDeletion" finalizer, then + // the owner cannot be deleted from the key-value store until this + // reference is removed. + // Defaults to false. + // To set this field, a user needs "delete" permission of the owner, + // otherwise 422 (Unprocessable Entity) will be returned. + // +optional + BlockOwnerDeletion *bool `json:"blockOwnerDeletion,omitempty" protobuf:"varint,7,opt,name=blockOwnerDeletion"` +} + +// ListOptions is the query options to a standard REST list call. +type ListOptions struct { + TypeMeta `json:",inline"` + + // A selector to restrict the list of returned objects by their labels. + // Defaults to everything. + // +optional + LabelSelector string `json:"labelSelector,omitempty" protobuf:"bytes,1,opt,name=labelSelector"` + // A selector to restrict the list of returned objects by their fields. + // Defaults to everything. + // +optional + FieldSelector string `json:"fieldSelector,omitempty" protobuf:"bytes,2,opt,name=fieldSelector"` + // If true, partially initialized resources are included in the response. + // +optional + IncludeUninitialized bool `json:"includeUninitialized,omitempty" protobuf:"varint,6,opt,name=includeUninitialized"` + // Watch for changes to the described resources and return them as a stream of + // add, update, and remove notifications. Specify resourceVersion. + // +optional + Watch bool `json:"watch,omitempty" protobuf:"varint,3,opt,name=watch"` + // When specified with a watch call, shows changes that occur after that particular version of a resource. + // Defaults to changes from the beginning of history. + // When specified for list: + // - if unset, then the result is returned from remote storage based on quorum-read flag; + // - if it's 0, then we simply return what we currently have in cache, no guarantee; + // - if set to non zero, then the result is at least as fresh as given rv. + // +optional + ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,4,opt,name=resourceVersion"` + // Timeout for the list/watch call. + // +optional + TimeoutSeconds *int64 `json:"timeoutSeconds,omitempty" protobuf:"varint,5,opt,name=timeoutSeconds"` +} + // ExportOptions is the query options to the standard REST get call. type ExportOptions struct { TypeMeta `json:",inline"` - // Should this value be exported. Export strips fields that a user can not specify.` + // Should this value be exported. Export strips fields that a user can not specify. Export bool `json:"export" protobuf:"varint,1,opt,name=export"` - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' + // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'. Exact bool `json:"exact" protobuf:"varint,2,opt,name=exact"` } +// GetOptions is the standard query options to the standard REST get call. +type GetOptions struct { + TypeMeta `json:",inline"` + // When specified: + // - if unset, then the result is returned from remote storage based on quorum-read flag; + // - if it's 0, then we simply return what we currently have in cache, no guarantee; + // - if set to non zero, then the result is at least as fresh as given rv. + ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,1,opt,name=resourceVersion"` + // If true, partially initialized resources are included in the response. + // +optional + IncludeUninitialized bool `json:"includeUninitialized,omitempty" protobuf:"varint,2,opt,name=includeUninitialized"` +} + +// DeletionPropagation decides if a deletion will propagate to the dependents of +// the object, and how the garbage collector will handle the propagation. +type DeletionPropagation string + +const ( + // Orphans the dependents. + DeletePropagationOrphan DeletionPropagation = "Orphan" + // Deletes the object from the key-value store, the garbage collector will + // delete the dependents in the background. + DeletePropagationBackground DeletionPropagation = "Background" + // The object exists in the key-value store until the garbage collector + // deletes all the dependents whose ownerReference.blockOwnerDeletion=true + // from the key-value store. API sever will put the "foregroundDeletion" + // finalizer on the object, and sets its deletionTimestamp. This policy is + // cascading, i.e., the dependents will be deleted with Foreground. + DeletePropagationForeground DeletionPropagation = "Foreground" +) + +// DeleteOptions may be provided when deleting an API object. +type DeleteOptions struct { + TypeMeta `json:",inline"` + + // The duration in seconds before the object should be deleted. Value must be non-negative integer. + // The value zero indicates delete immediately. If this value is nil, the default grace period for the + // specified type will be used. + // Defaults to a per object value if not specified. zero means delete immediately. + // +optional + GracePeriodSeconds *int64 `json:"gracePeriodSeconds,omitempty" protobuf:"varint,1,opt,name=gracePeriodSeconds"` + + // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be + // returned. + // +optional + Preconditions *Preconditions `json:"preconditions,omitempty" protobuf:"bytes,2,opt,name=preconditions"` + + // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. + // Should the dependent objects be orphaned. If true/false, the "orphan" + // finalizer will be added to/removed from the object's finalizers list. + // Either this field or PropagationPolicy may be set, but not both. + // +optional + OrphanDependents *bool `json:"orphanDependents,omitempty" protobuf:"varint,3,opt,name=orphanDependents"` + + // Whether and how garbage collection will be performed. + // Either this field or OrphanDependents may be set, but not both. + // The default policy is decided by the existing finalizer set in the + // metadata.finalizers and the resource-specific default policy. + // +optional + PropagationPolicy *DeletionPropagation `json:"propagationPolicy,omitempty" protobuf:"varint,4,opt,name=propagationPolicy"` +} + +// Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. +type Preconditions struct { + // Specifies the target UID. + // +optional + UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"` +} + // Status is a return value for calls that don't return other objects. type Status struct { TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Status of the operation. // One of: "Success" or "Failure". - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status string `json:"status,omitempty" protobuf:"bytes,2,opt,name=status"` // A human-readable description of the status of this operation. @@ -124,9 +457,14 @@ type StatusDetails struct { Group string `json:"group,omitempty" protobuf:"bytes,2,opt,name=group"` // The kind attribute of the resource associated with the status StatusReason. // On some operations may differ from the requested resource Kind. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional Kind string `json:"kind,omitempty" protobuf:"bytes,3,opt,name=kind"` + // UID of the resource. + // (when there is a single resource which can be described). + // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // +optional + UID types.UID `json:"uid,omitempty" protobuf:"bytes,6,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"` // The Causes array includes more details associated with the StatusReason // failure. Not all StatusReasons may provide detailed causes. // +optional @@ -387,12 +725,33 @@ type GroupVersionForDiscovery struct { // APIResource specifies the name of a resource and whether it is namespaced. type APIResource struct { - // name is the name of the resource. + // name is the plural name of the resource. Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + // singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. + // The singularName is more correct for reporting status on a single item and both singular and plural are allowed + // from the kubectl CLI interface. + SingularName string `json:"singularName" protobuf:"bytes,6,opt,name=singularName"` // namespaced indicates if a resource is namespaced or not. Namespaced bool `json:"namespaced" protobuf:"varint,2,opt,name=namespaced"` // kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo') Kind string `json:"kind" protobuf:"bytes,3,opt,name=kind"` + // verbs is a list of supported kube verbs (this includes get, list, watch, create, + // update, patch, delete, deletecollection, and proxy) + Verbs Verbs `json:"verbs" protobuf:"bytes,4,opt,name=verbs"` + // shortNames is a list of suggested short names of the resource. + ShortNames []string `json:"shortNames,omitempty" protobuf:"bytes,5,rep,name=shortNames"` + // categories is a list of the grouped resources this resource belongs to (e.g. 'all') + Categories []string `json:"categories,omitempty" protobuf:"bytes,7,rep,name=categories"` +} + +// Verbs masks the value so protobuf can generate +// +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +type Verbs []string + +func (vs Verbs) String() string { + return fmt.Sprintf("%v", []string(vs)) } // APIResourceList is a list of APIResource, it is used to expose the name of the @@ -459,6 +818,8 @@ type LabelSelector struct { // relates the key and values. type LabelSelectorRequirement struct { // key is the label key that the selector applies to. + // +patchMergeKey=key + // +patchStrategy=merge Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"` // operator represents a key's relationship to a set of values. // Valid operators ard In, NotIn, Exists and DoesNotExist. diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..159164d7c9 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/types_swagger_doc_generated.go @@ -0,0 +1,315 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_APIGroup = map[string]string{ + "": "APIGroup contains the name, the supported versions, and the preferred version of a group.", + "name": "name is the name of the group.", + "versions": "versions are the versions supported in this group.", + "preferredVersion": "preferredVersion is the version preferred by the API server, which probably is the storage version.", + "serverAddressByClientCIDRs": "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", +} + +func (APIGroup) SwaggerDoc() map[string]string { + return map_APIGroup +} + +var map_APIGroupList = map[string]string{ + "": "APIGroupList is a list of APIGroup, to allow clients to discover the API at /apis.", + "groups": "groups is a list of APIGroup.", +} + +func (APIGroupList) SwaggerDoc() map[string]string { + return map_APIGroupList +} + +var map_APIResource = map[string]string{ + "": "APIResource specifies the name of a resource and whether it is namespaced.", + "name": "name is the plural name of the resource.", + "singularName": "singularName is the singular name of the resource. This allows clients to handle plural and singular opaquely. The singularName is more correct for reporting status on a single item and both singular and plural are allowed from the kubectl CLI interface.", + "namespaced": "namespaced indicates if a resource is namespaced or not.", + "kind": "kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')", + "verbs": "verbs is a list of supported kube verbs (this includes get, list, watch, create, update, patch, delete, deletecollection, and proxy)", + "shortNames": "shortNames is a list of suggested short names of the resource.", + "categories": "categories is a list of the grouped resources this resource belongs to (e.g. 'all')", +} + +func (APIResource) SwaggerDoc() map[string]string { + return map_APIResource +} + +var map_APIResourceList = map[string]string{ + "": "APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.", + "groupVersion": "groupVersion is the group and version this APIResourceList is for.", + "resources": "resources contains the name of the resources and if they are namespaced.", +} + +func (APIResourceList) SwaggerDoc() map[string]string { + return map_APIResourceList +} + +var map_APIVersions = map[string]string{ + "": "APIVersions lists the versions that are available, to allow clients to discover the API at /api, which is the root path of the legacy v1 API.", + "versions": "versions are the api versions that are available.", + "serverAddressByClientCIDRs": "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", +} + +func (APIVersions) SwaggerDoc() map[string]string { + return map_APIVersions +} + +var map_DeleteOptions = map[string]string{ + "": "DeleteOptions may be provided when deleting an API object.", + "gracePeriodSeconds": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", + "preconditions": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.", + "orphanDependents": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "propagationPolicy": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", +} + +func (DeleteOptions) SwaggerDoc() map[string]string { + return map_DeleteOptions +} + +var map_ExportOptions = map[string]string{ + "": "ExportOptions is the query options to the standard REST get call.", + "export": "Should this value be exported. Export strips fields that a user can not specify.", + "exact": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'.", +} + +func (ExportOptions) SwaggerDoc() map[string]string { + return map_ExportOptions +} + +var map_GetOptions = map[string]string{ + "": "GetOptions is the standard query options to the standard REST get call.", + "resourceVersion": "When specified: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "includeUninitialized": "If true, partially initialized resources are included in the response.", +} + +func (GetOptions) SwaggerDoc() map[string]string { + return map_GetOptions +} + +var map_GroupVersionForDiscovery = map[string]string{ + "": "GroupVersion contains the \"group/version\" and \"version\" string of a version. It is made a struct to keep extensibility.", + "groupVersion": "groupVersion specifies the API group and version in the form \"group/version\"", + "version": "version specifies the version in the form of \"version\". This is to save the clients the trouble of splitting the GroupVersion.", +} + +func (GroupVersionForDiscovery) SwaggerDoc() map[string]string { + return map_GroupVersionForDiscovery +} + +var map_Initializer = map[string]string{ + "": "Initializer is information about an initializer that has not yet completed.", + "name": "name of the process that is responsible for initializing this object.", +} + +func (Initializer) SwaggerDoc() map[string]string { + return map_Initializer +} + +var map_Initializers = map[string]string{ + "": "Initializers tracks the progress of initialization.", + "pending": "Pending is a list of initializers that must execute in order before this object is visible. When the last pending initializer is removed, and no failing result is set, the initializers struct will be set to nil and the object is considered as initialized and visible to all clients.", + "result": "If result is set with the Failure field, the object will be persisted to storage and then deleted, ensuring that other clients can observe the deletion.", +} + +func (Initializers) SwaggerDoc() map[string]string { + return map_Initializers +} + +var map_LabelSelector = map[string]string{ + "": "A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.", + "matchLabels": "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is \"key\", the operator is \"In\", and the values array contains only \"value\". The requirements are ANDed.", + "matchExpressions": "matchExpressions is a list of label selector requirements. The requirements are ANDed.", +} + +func (LabelSelector) SwaggerDoc() map[string]string { + return map_LabelSelector +} + +var map_LabelSelectorRequirement = map[string]string{ + "": "A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", + "key": "key is the label key that the selector applies to.", + "operator": "operator represents a key's relationship to a set of values. Valid operators ard In, NotIn, Exists and DoesNotExist.", + "values": "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.", +} + +func (LabelSelectorRequirement) SwaggerDoc() map[string]string { + return map_LabelSelectorRequirement +} + +var map_ListMeta = map[string]string{ + "": "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.", + "selfLink": "SelfLink is a URL representing this object. Populated by the system. Read-only.", + "resourceVersion": "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency", +} + +func (ListMeta) SwaggerDoc() map[string]string { + return map_ListMeta +} + +var map_ListOptions = map[string]string{ + "": "ListOptions is the query options to a standard REST list call.", + "labelSelector": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "fieldSelector": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "includeUninitialized": "If true, partially initialized resources are included in the response.", + "watch": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "resourceVersion": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "timeoutSeconds": "Timeout for the list/watch call.", +} + +func (ListOptions) SwaggerDoc() map[string]string { + return map_ListOptions +} + +var map_ObjectMeta = map[string]string{ + "": "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.", + "name": "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names", + "generateName": "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency", + "namespace": "Namespace defines the space within each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces", + "selfLink": "SelfLink is a URL representing this object. Populated by the system. Read-only.", + "uid": "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids", + "resourceVersion": "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency", + "generation": "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.", + "creationTimestamp": "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "deletionTimestamp": "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "deletionGracePeriodSeconds": "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.", + "labels": "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels", + "annotations": "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations", + "ownerReferences": "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.", + "initializers": "An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects.\n\nWhen an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user.", + "finalizers": "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed.", + "clusterName": "The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request.", +} + +func (ObjectMeta) SwaggerDoc() map[string]string { + return map_ObjectMeta +} + +var map_OwnerReference = map[string]string{ + "": "OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.", + "apiVersion": "API version of the referent.", + "kind": "Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "name": "Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names", + "uid": "UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids", + "controller": "If true, this reference points to the managing controller.", + "blockOwnerDeletion": "If true, AND if the owner has the \"foregroundDeletion\" finalizer, then the owner cannot be deleted from the key-value store until this reference is removed. Defaults to false. To set this field, a user needs \"delete\" permission of the owner, otherwise 422 (Unprocessable Entity) will be returned.", +} + +func (OwnerReference) SwaggerDoc() map[string]string { + return map_OwnerReference +} + +var map_Patch = map[string]string{ + "": "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", +} + +func (Patch) SwaggerDoc() map[string]string { + return map_Patch +} + +var map_Preconditions = map[string]string{ + "": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", + "uid": "Specifies the target UID.", +} + +func (Preconditions) SwaggerDoc() map[string]string { + return map_Preconditions +} + +var map_RootPaths = map[string]string{ + "": "RootPaths lists the paths available at root. For example: \"/healthz\", \"/apis\".", + "paths": "paths are the paths available at root.", +} + +func (RootPaths) SwaggerDoc() map[string]string { + return map_RootPaths +} + +var map_ServerAddressByClientCIDR = map[string]string{ + "": "ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.", + "clientCIDR": "The CIDR with which clients can match their IP to figure out the server address that they should use.", + "serverAddress": "Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port.", +} + +func (ServerAddressByClientCIDR) SwaggerDoc() map[string]string { + return map_ServerAddressByClientCIDR +} + +var map_Status = map[string]string{ + "": "Status is a return value for calls that don't return other objects.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "status": "Status of the operation. One of: \"Success\" or \"Failure\". More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "message": "A human-readable description of the status of this operation.", + "reason": "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.", + "details": "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.", + "code": "Suggested HTTP return code for this status, 0 if not set.", +} + +func (Status) SwaggerDoc() map[string]string { + return map_Status +} + +var map_StatusCause = map[string]string{ + "": "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.", + "reason": "A machine-readable description of the cause of the error. If this value is empty there is no information available.", + "message": "A human-readable description of the cause of the error. This field may be presented as-is to a reader.", + "field": "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.\n\nExamples:\n \"name\" - the field \"name\" on the current resource\n \"items[0].name\" - the field \"name\" on the first array entry in \"items\"", +} + +func (StatusCause) SwaggerDoc() map[string]string { + return map_StatusCause +} + +var map_StatusDetails = map[string]string{ + "": "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.", + "name": "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).", + "group": "The group attribute of the resource associated with the status StatusReason.", + "kind": "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "uid": "UID of the resource. (when there is a single resource which can be described). More info: http://kubernetes.io/docs/user-guide/identifiers#uids", + "causes": "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.", + "retryAfterSeconds": "If specified, the time in seconds before the operation should be retried.", +} + +func (StatusDetails) SwaggerDoc() map[string]string { + return map_StatusDetails +} + +var map_TypeMeta = map[string]string{ + "": "TypeMeta describes an individual object in an API response or request with strings representing the type of the object and its API schema version. Structures that are versioned or persisted should inline TypeMeta.", + "kind": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "apiVersion": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources", +} + +func (TypeMeta) SwaggerDoc() map[string]string { + return map_TypeMeta +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/BUILD b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/BUILD new file mode 100644 index 0000000000..b6b0d2bb5d --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/BUILD @@ -0,0 +1,32 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["unstructured_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["unstructured.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion/unstructured:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/json:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/unstructured.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/unstructured.go similarity index 65% rename from vendor/k8s.io/client-go/pkg/runtime/unstructured.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/unstructured.go index a15208c51c..fed687e9bd 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/unstructured.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/unstructured/unstructured.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package runtime +package unstructured import ( "bytes" @@ -26,12 +26,75 @@ import ( "github.com/golang/glog" - "k8s.io/client-go/pkg/api/meta/metatypes" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/types" - "k8s.io/client-go/pkg/util/json" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion/unstructured" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/util/json" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" ) +// Unstructured allows objects that do not have Golang structs registered to be manipulated +// generically. This can be used to deal with the API objects from a plug-in. Unstructured +// objects still have functioning TypeMeta features-- kind, version, etc. +// +// WARNING: This object has accessors for the v1 standard metadata. You *MUST NOT* use this +// type if you are dealing with objects that are not in the server meta v1 schema. +// +// TODO: make the serialization part of this type distinct from the field accessors. +type Unstructured struct { + // Object is a JSON compatible map with string, float, int, bool, []interface{}, or + // map[string]interface{} + // children. + Object map[string]interface{} +} + +var _ metav1.Object = &Unstructured{} +var _ runtime.Unstructured = &Unstructured{} +var _ runtime.Unstructured = &UnstructuredList{} + +func (obj *Unstructured) GetObjectKind() schema.ObjectKind { return obj } +func (obj *UnstructuredList) GetObjectKind() schema.ObjectKind { return obj } + +func (obj *Unstructured) IsUnstructuredObject() {} +func (obj *UnstructuredList) IsUnstructuredObject() {} + +func (obj *Unstructured) IsList() bool { + if obj.Object != nil { + _, ok := obj.Object["items"] + return ok + } + return false +} +func (obj *UnstructuredList) IsList() bool { return true } + +func (obj *Unstructured) UnstructuredContent() map[string]interface{} { + if obj.Object == nil { + obj.Object = make(map[string]interface{}) + } + return obj.Object +} + +// UnstructuredContent returns a map contain an overlay of the Items field onto +// the Object field. Items always overwrites overlay. Changing "items" in the +// returned object will affect items in the underlying Items field, but changing +// the "items" slice itself will have no effect. +// TODO: expose SetUnstructuredContent on runtime.Unstructured that allows +// items to be changed. +func (obj *UnstructuredList) UnstructuredContent() map[string]interface{} { + out := obj.Object + if out == nil { + out = make(map[string]interface{}) + } + items := make([]interface{}, len(obj.Items)) + for i, item := range obj.Items { + items[i] = item.Object + } + out["items"] = items + return out +} + // MarshalJSON ensures that the unstructured object produces proper // JSON when passed to Go's standard JSON library. func (u *Unstructured) MarshalJSON() ([]byte, error) { @@ -65,6 +128,20 @@ func getNestedString(obj map[string]interface{}, fields ...string) string { return "" } +func getNestedInt64(obj map[string]interface{}, fields ...string) int64 { + if str, ok := getNestedField(obj, fields...).(int64); ok { + return str + } + return 0 +} + +func getNestedInt64Pointer(obj map[string]interface{}, fields ...string) *int64 { + if str, ok := getNestedField(obj, fields...).(*int64); ok { + return str + } + return nil +} + func getNestedSlice(obj map[string]interface{}, fields ...string) []string { if m, ok := getNestedField(obj, fields...).([]interface{}); ok { strSlice := make([]string, 0, len(m)) @@ -141,38 +218,51 @@ func (u *Unstructured) setNestedMap(value map[string]string, fields ...string) { setNestedMap(u.Object, value, fields...) } -func extractOwnerReference(src interface{}) metatypes.OwnerReference { +func extractOwnerReference(src interface{}) metav1.OwnerReference { v := src.(map[string]interface{}) - controllerPtr, ok := (getNestedField(v, "controller")).(*bool) + // though this field is a *bool, but when decoded from JSON, it's + // unmarshalled as bool. + var controllerPtr *bool + controller, ok := (getNestedField(v, "controller")).(bool) if !ok { controllerPtr = nil } else { - if controllerPtr != nil { - controller := *controllerPtr - controllerPtr = &controller - } + controllerCopy := controller + controllerPtr = &controllerCopy } - return metatypes.OwnerReference{ - Kind: getNestedString(v, "kind"), - Name: getNestedString(v, "name"), - APIVersion: getNestedString(v, "apiVersion"), - UID: (types.UID)(getNestedString(v, "uid")), - Controller: controllerPtr, + var blockOwnerDeletionPtr *bool + blockOwnerDeletion, ok := (getNestedField(v, "blockOwnerDeletion")).(bool) + if !ok { + blockOwnerDeletionPtr = nil + } else { + blockOwnerDeletionCopy := blockOwnerDeletion + blockOwnerDeletionPtr = &blockOwnerDeletionCopy + } + return metav1.OwnerReference{ + Kind: getNestedString(v, "kind"), + Name: getNestedString(v, "name"), + APIVersion: getNestedString(v, "apiVersion"), + UID: (types.UID)(getNestedString(v, "uid")), + Controller: controllerPtr, + BlockOwnerDeletion: blockOwnerDeletionPtr, } } -func setOwnerReference(src metatypes.OwnerReference) map[string]interface{} { +func setOwnerReference(src metav1.OwnerReference) map[string]interface{} { ret := make(map[string]interface{}) - controllerPtr := src.Controller - if controllerPtr != nil { - controller := *controllerPtr - controllerPtr = &controller - } setNestedField(ret, src.Kind, "kind") setNestedField(ret, src.Name, "name") setNestedField(ret, src.APIVersion, "apiVersion") setNestedField(ret, string(src.UID), "uid") - setNestedField(ret, controllerPtr, "controller") + // json.Unmarshal() extracts boolean json fields as bool, not as *bool and hence extractOwnerReference() + // expects bool or a missing field, not *bool. So if pointer is nil, fields are omitted from the ret object. + // If pointer is non-nil, they are set to the referenced value. + if src.Controller != nil { + setNestedField(ret, *src.Controller, "controller") + } + if src.BlockOwnerDeletion != nil { + setNestedField(ret, *src.BlockOwnerDeletion, "blockOwnerDeletion") + } return ret } @@ -201,20 +291,20 @@ func getOwnerReferences(object map[string]interface{}) ([]map[string]interface{} return ownerReferences, nil } -func (u *Unstructured) GetOwnerReferences() []metatypes.OwnerReference { +func (u *Unstructured) GetOwnerReferences() []metav1.OwnerReference { original, err := getOwnerReferences(u.Object) if err != nil { glog.V(6).Info(err) return nil } - ret := make([]metatypes.OwnerReference, 0, len(original)) + ret := make([]metav1.OwnerReference, 0, len(original)) for i := 0; i < len(original); i++ { ret = append(ret, extractOwnerReference(original[i])) } return ret } -func (u *Unstructured) SetOwnerReferences(references []metatypes.OwnerReference) { +func (u *Unstructured) SetOwnerReferences(references []metav1.OwnerReference) { var newReferences = make([]map[string]interface{}, 0, len(references)) for i := 0; i < len(references); i++ { newReferences = append(newReferences, setOwnerReference(references[i])) @@ -278,6 +368,14 @@ func (u *Unstructured) SetResourceVersion(version string) { u.setNestedField(version, "metadata", "resourceVersion") } +func (u *Unstructured) GetGeneration() int64 { + return getNestedInt64(u.Object, "metadata", "generation") +} + +func (u *Unstructured) SetGeneration(generation int64) { + u.setNestedField(generation, "metadata", "generation") +} + func (u *Unstructured) GetSelfLink() string { return getNestedString(u.Object, "metadata", "selfLink") } @@ -286,19 +384,19 @@ func (u *Unstructured) SetSelfLink(selfLink string) { u.setNestedField(selfLink, "metadata", "selfLink") } -func (u *Unstructured) GetCreationTimestamp() unversioned.Time { - var timestamp unversioned.Time +func (u *Unstructured) GetCreationTimestamp() metav1.Time { + var timestamp metav1.Time timestamp.UnmarshalQueryParameter(getNestedString(u.Object, "metadata", "creationTimestamp")) return timestamp } -func (u *Unstructured) SetCreationTimestamp(timestamp unversioned.Time) { +func (u *Unstructured) SetCreationTimestamp(timestamp metav1.Time) { ts, _ := timestamp.MarshalQueryParameter() u.setNestedField(ts, "metadata", "creationTimestamp") } -func (u *Unstructured) GetDeletionTimestamp() *unversioned.Time { - var timestamp unversioned.Time +func (u *Unstructured) GetDeletionTimestamp() *metav1.Time { + var timestamp metav1.Time timestamp.UnmarshalQueryParameter(getNestedString(u.Object, "metadata", "deletionTimestamp")) if timestamp.IsZero() { return nil @@ -306,11 +404,23 @@ func (u *Unstructured) GetDeletionTimestamp() *unversioned.Time { return ×tamp } -func (u *Unstructured) SetDeletionTimestamp(timestamp *unversioned.Time) { +func (u *Unstructured) SetDeletionTimestamp(timestamp *metav1.Time) { + if timestamp == nil { + u.setNestedField(nil, "metadata", "deletionTimestamp") + return + } ts, _ := timestamp.MarshalQueryParameter() u.setNestedField(ts, "metadata", "deletionTimestamp") } +func (u *Unstructured) GetDeletionGracePeriodSeconds() *int64 { + return getNestedInt64Pointer(u.Object, "metadata", "deletionGracePeriodSeconds") +} + +func (u *Unstructured) SetDeletionGracePeriodSeconds(deletionGracePeriodSeconds *int64) { + u.setNestedField(deletionGracePeriodSeconds, "metadata", "deletionGracePeriodSeconds") +} + func (u *Unstructured) GetLabels() map[string]string { return getNestedMap(u.Object, "metadata", "labels") } @@ -327,20 +437,50 @@ func (u *Unstructured) SetAnnotations(annotations map[string]string) { u.setNestedMap(annotations, "metadata", "annotations") } -func (u *Unstructured) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { +func (u *Unstructured) SetGroupVersionKind(gvk schema.GroupVersionKind) { u.SetAPIVersion(gvk.GroupVersion().String()) u.SetKind(gvk.Kind) } -func (u *Unstructured) GroupVersionKind() unversioned.GroupVersionKind { - gv, err := unversioned.ParseGroupVersion(u.GetAPIVersion()) +func (u *Unstructured) GroupVersionKind() schema.GroupVersionKind { + gv, err := schema.ParseGroupVersion(u.GetAPIVersion()) if err != nil { - return unversioned.GroupVersionKind{} + return schema.GroupVersionKind{} } gvk := gv.WithKind(u.GetKind()) return gvk } +var converter = unstructured.NewConverter(false) + +func (u *Unstructured) GetInitializers() *metav1.Initializers { + field := getNestedField(u.Object, "metadata", "initializers") + if field == nil { + return nil + } + obj, ok := field.(map[string]interface{}) + if !ok { + return nil + } + out := &metav1.Initializers{} + if err := converter.FromUnstructured(obj, out); err != nil { + utilruntime.HandleError(fmt.Errorf("unable to retrieve initializers for object: %v", err)) + } + return out +} + +func (u *Unstructured) SetInitializers(initializers *metav1.Initializers) { + if initializers == nil { + setNestedField(u.Object, nil, "metadata", "initializers") + return + } + out := make(map[string]interface{}) + if err := converter.ToUnstructured(initializers, &out); err != nil { + utilruntime.HandleError(fmt.Errorf("unable to retrieve initializers for object: %v", err)) + } + setNestedField(u.Object, out, "metadata", "initializers") +} + func (u *Unstructured) GetFinalizers() []string { return getNestedSlice(u.Object, "metadata", "finalizers") } @@ -364,7 +504,7 @@ type UnstructuredList struct { Object map[string]interface{} // Items is a list of unstructured objects. - Items []*Unstructured `json:"items"` + Items []Unstructured `json:"items"` } // MarshalJSON ensures that the unstructured list object produces proper @@ -421,15 +561,15 @@ func (u *UnstructuredList) SetSelfLink(selfLink string) { u.setNestedField(selfLink, "metadata", "selfLink") } -func (u *UnstructuredList) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { +func (u *UnstructuredList) SetGroupVersionKind(gvk schema.GroupVersionKind) { u.SetAPIVersion(gvk.GroupVersion().String()) u.SetKind(gvk.Kind) } -func (u *UnstructuredList) GroupVersionKind() unversioned.GroupVersionKind { - gv, err := unversioned.ParseGroupVersion(u.GetAPIVersion()) +func (u *UnstructuredList) GroupVersionKind() schema.GroupVersionKind { + gv, err := schema.ParseGroupVersion(u.GetAPIVersion()) if err != nil { - return unversioned.GroupVersionKind{} + return schema.GroupVersionKind{} } gvk := gv.WithKind(u.GetKind()) return gvk @@ -438,11 +578,11 @@ func (u *UnstructuredList) GroupVersionKind() unversioned.GroupVersionKind { // UnstructuredJSONScheme is capable of converting JSON data into the Unstructured // type, which can be used for generic access to objects without a predefined scheme. // TODO: move into serializer/json. -var UnstructuredJSONScheme Codec = unstructuredJSONScheme{} +var UnstructuredJSONScheme runtime.Codec = unstructuredJSONScheme{} type unstructuredJSONScheme struct{} -func (s unstructuredJSONScheme) Decode(data []byte, _ *unversioned.GroupVersionKind, obj Object) (Object, *unversioned.GroupVersionKind, error) { +func (s unstructuredJSONScheme) Decode(data []byte, _ *schema.GroupVersionKind, obj runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { var err error if obj != nil { err = s.decodeInto(data, obj) @@ -456,13 +596,13 @@ func (s unstructuredJSONScheme) Decode(data []byte, _ *unversioned.GroupVersionK gvk := obj.GetObjectKind().GroupVersionKind() if len(gvk.Kind) == 0 { - return nil, &gvk, NewMissingKindErr(string(data)) + return nil, &gvk, runtime.NewMissingKindErr(string(data)) } return obj, &gvk, nil } -func (unstructuredJSONScheme) Encode(obj Object, w io.Writer) error { +func (unstructuredJSONScheme) Encode(obj runtime.Object, w io.Writer) error { switch t := obj.(type) { case *Unstructured: return json.NewEncoder(w).Encode(t.Object) @@ -474,7 +614,7 @@ func (unstructuredJSONScheme) Encode(obj Object, w io.Writer) error { t.Object["items"] = items defer func() { delete(t.Object, "items") }() return json.NewEncoder(w).Encode(t.Object) - case *Unknown: + case *runtime.Unknown: // TODO: Unstructured needs to deal with ContentType. _, err := w.Write(t.Raw) return err @@ -483,7 +623,7 @@ func (unstructuredJSONScheme) Encode(obj Object, w io.Writer) error { } } -func (s unstructuredJSONScheme) decode(data []byte) (Object, error) { +func (s unstructuredJSONScheme) decode(data []byte) (runtime.Object, error) { type detector struct { Items gojson.RawMessage } @@ -504,16 +644,16 @@ func (s unstructuredJSONScheme) decode(data []byte) (Object, error) { return unstruct, err } -func (s unstructuredJSONScheme) decodeInto(data []byte, obj Object) error { +func (s unstructuredJSONScheme) decodeInto(data []byte, obj runtime.Object) error { switch x := obj.(type) { case *Unstructured: return s.decodeToUnstructured(data, x) case *UnstructuredList: return s.decodeToList(data, x) - case *VersionedObjects: + case *runtime.VersionedObjects: o, err := s.decode(data) if err == nil { - x.Objects = []Object{o} + x.Objects = []runtime.Object{o} } return err default: @@ -565,7 +705,7 @@ func (s unstructuredJSONScheme) decodeToList(data []byte, list *UnstructuredList unstruct.SetKind(itemKind) unstruct.SetAPIVersion(listAPIVersion) } - list.Items = append(list.Items, unstruct) + list.Items = append(list.Items, *unstruct) } return nil } @@ -595,9 +735,9 @@ func (UnstructuredObjectConverter) Convert(in, out, context interface{}) error { return nil } -func (UnstructuredObjectConverter) ConvertToVersion(in Object, target GroupVersioner) (Object, error) { +func (UnstructuredObjectConverter) ConvertToVersion(in runtime.Object, target runtime.GroupVersioner) (runtime.Object, error) { if kind := in.GetObjectKind().GroupVersionKind(); !kind.Empty() { - gvk, ok := target.KindForGroupVersionKinds([]unversioned.GroupVersionKind{kind}) + gvk, ok := target.KindForGroupVersionKinds([]schema.GroupVersionKind{kind}) if !ok { // TODO: should this be a typed error? return nil, fmt.Errorf("%v is unstructured and is not suitable for converting to %q", kind, target) diff --git a/vendor/k8s.io/client-go/pkg/watch/versioned/register.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/watch.go similarity index 50% rename from vendor/k8s.io/client-go/pkg/watch/versioned/register.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1/watch.go index 2223a934be..a645501a1a 100644 --- a/vendor/k8s.io/client-go/pkg/watch/versioned/register.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/watch.go @@ -14,35 +14,30 @@ See the License for the specific language governing permissions and limitations under the License. */ -package versioned +package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/watch" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/watch" ) -// WatchEventKind is name reserved for serializing watch events. -const WatchEventKind = "WatchEvent" +// Event represents a single event to a watched resource. +// +// +protobuf=true +type WatchEvent struct { + Type string `json:"type" protobuf:"bytes,1,opt,name=type"` -// AddToGroupVersion registers the watch external and internal kinds with the scheme, and ensures the proper -// conversions are in place. -func AddToGroupVersion(scheme *runtime.Scheme, groupVersion unversioned.GroupVersion) { - scheme.AddKnownTypeWithName(groupVersion.WithKind(WatchEventKind), &Event{}) - scheme.AddKnownTypeWithName( - unversioned.GroupVersion{Group: groupVersion.Group, Version: runtime.APIVersionInternal}.WithKind(WatchEventKind), - &InternalEvent{}, - ) - scheme.AddConversionFuncs( - Convert_versioned_Event_to_watch_Event, - Convert_versioned_InternalEvent_to_versioned_Event, - Convert_watch_Event_to_versioned_Event, - Convert_versioned_Event_to_versioned_InternalEvent, - ) + // Object is: + // * If Type is Added or Modified: the new state of the object. + // * If Type is Deleted: the state of the object immediately before deletion. + // * If Type is Error: *Status is recommended; other types may make sense + // depending on context. + Object runtime.RawExtension `json:"object" protobuf:"bytes,2,opt,name=object"` } -func Convert_watch_Event_to_versioned_Event(in *watch.Event, out *Event, s conversion.Scope) error { +func Convert_watch_Event_to_versioned_Event(in *watch.Event, out *WatchEvent, s conversion.Scope) error { out.Type = string(in.Type) switch t := in.Object.(type) { case *runtime.Unknown: @@ -55,11 +50,11 @@ func Convert_watch_Event_to_versioned_Event(in *watch.Event, out *Event, s conve return nil } -func Convert_versioned_InternalEvent_to_versioned_Event(in *InternalEvent, out *Event, s conversion.Scope) error { +func Convert_versioned_InternalEvent_to_versioned_Event(in *InternalEvent, out *WatchEvent, s conversion.Scope) error { return Convert_watch_Event_to_versioned_Event((*watch.Event)(in), out, s) } -func Convert_versioned_Event_to_watch_Event(in *Event, out *watch.Event, s conversion.Scope) error { +func Convert_versioned_Event_to_watch_Event(in *WatchEvent, out *watch.Event, s conversion.Scope) error { out.Type = watch.EventType(in.Type) if in.Object.Object != nil { out.Object = in.Object.Object @@ -73,12 +68,13 @@ func Convert_versioned_Event_to_watch_Event(in *Event, out *watch.Event, s conve return nil } -func Convert_versioned_Event_to_versioned_InternalEvent(in *Event, out *InternalEvent, s conversion.Scope) error { +func Convert_versioned_Event_to_versioned_InternalEvent(in *WatchEvent, out *InternalEvent, s conversion.Scope) error { return Convert_versioned_Event_to_watch_Event(in, (*watch.Event)(out), s) } // InternalEvent makes watch.Event versioned +// +protobuf=false type InternalEvent watch.Event -func (e *InternalEvent) GetObjectKind() unversioned.ObjectKind { return unversioned.EmptyObjectKind } -func (e *Event) GetObjectKind() unversioned.ObjectKind { return unversioned.EmptyObjectKind } +func (e *InternalEvent) GetObjectKind() schema.ObjectKind { return schema.EmptyObjectKind } +func (e *WatchEvent) GetObjectKind() schema.ObjectKind { return schema.EmptyObjectKind } diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..6fac96be40 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.deepcopy.go @@ -0,0 +1,646 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + types "k8s.io/apimachinery/pkg/types" + reflect "reflect" +) + +// GetGeneratedDeepCopyFuncs returns the generated funcs, since we aren't registering them. +func GetGeneratedDeepCopyFuncs() []conversion.GeneratedDeepCopyFunc { + return []conversion.GeneratedDeepCopyFunc{ + {Fn: DeepCopy_v1_APIGroup, InType: reflect.TypeOf(&APIGroup{})}, + {Fn: DeepCopy_v1_APIGroupList, InType: reflect.TypeOf(&APIGroupList{})}, + {Fn: DeepCopy_v1_APIResource, InType: reflect.TypeOf(&APIResource{})}, + {Fn: DeepCopy_v1_APIResourceList, InType: reflect.TypeOf(&APIResourceList{})}, + {Fn: DeepCopy_v1_APIVersions, InType: reflect.TypeOf(&APIVersions{})}, + {Fn: DeepCopy_v1_DeleteOptions, InType: reflect.TypeOf(&DeleteOptions{})}, + {Fn: DeepCopy_v1_Duration, InType: reflect.TypeOf(&Duration{})}, + {Fn: DeepCopy_v1_ExportOptions, InType: reflect.TypeOf(&ExportOptions{})}, + {Fn: DeepCopy_v1_GetOptions, InType: reflect.TypeOf(&GetOptions{})}, + {Fn: DeepCopy_v1_GroupKind, InType: reflect.TypeOf(&GroupKind{})}, + {Fn: DeepCopy_v1_GroupResource, InType: reflect.TypeOf(&GroupResource{})}, + {Fn: DeepCopy_v1_GroupVersion, InType: reflect.TypeOf(&GroupVersion{})}, + {Fn: DeepCopy_v1_GroupVersionForDiscovery, InType: reflect.TypeOf(&GroupVersionForDiscovery{})}, + {Fn: DeepCopy_v1_GroupVersionKind, InType: reflect.TypeOf(&GroupVersionKind{})}, + {Fn: DeepCopy_v1_GroupVersionResource, InType: reflect.TypeOf(&GroupVersionResource{})}, + {Fn: DeepCopy_v1_Initializer, InType: reflect.TypeOf(&Initializer{})}, + {Fn: DeepCopy_v1_Initializers, InType: reflect.TypeOf(&Initializers{})}, + {Fn: DeepCopy_v1_InternalEvent, InType: reflect.TypeOf(&InternalEvent{})}, + {Fn: DeepCopy_v1_LabelSelector, InType: reflect.TypeOf(&LabelSelector{})}, + {Fn: DeepCopy_v1_LabelSelectorRequirement, InType: reflect.TypeOf(&LabelSelectorRequirement{})}, + {Fn: DeepCopy_v1_ListMeta, InType: reflect.TypeOf(&ListMeta{})}, + {Fn: DeepCopy_v1_ListOptions, InType: reflect.TypeOf(&ListOptions{})}, + {Fn: DeepCopy_v1_MicroTime, InType: reflect.TypeOf(&MicroTime{})}, + {Fn: DeepCopy_v1_ObjectMeta, InType: reflect.TypeOf(&ObjectMeta{})}, + {Fn: DeepCopy_v1_OwnerReference, InType: reflect.TypeOf(&OwnerReference{})}, + {Fn: DeepCopy_v1_Patch, InType: reflect.TypeOf(&Patch{})}, + {Fn: DeepCopy_v1_Preconditions, InType: reflect.TypeOf(&Preconditions{})}, + {Fn: DeepCopy_v1_RootPaths, InType: reflect.TypeOf(&RootPaths{})}, + {Fn: DeepCopy_v1_ServerAddressByClientCIDR, InType: reflect.TypeOf(&ServerAddressByClientCIDR{})}, + {Fn: DeepCopy_v1_Status, InType: reflect.TypeOf(&Status{})}, + {Fn: DeepCopy_v1_StatusCause, InType: reflect.TypeOf(&StatusCause{})}, + {Fn: DeepCopy_v1_StatusDetails, InType: reflect.TypeOf(&StatusDetails{})}, + {Fn: DeepCopy_v1_Time, InType: reflect.TypeOf(&Time{})}, + {Fn: DeepCopy_v1_Timestamp, InType: reflect.TypeOf(&Timestamp{})}, + {Fn: DeepCopy_v1_TypeMeta, InType: reflect.TypeOf(&TypeMeta{})}, + {Fn: DeepCopy_v1_WatchEvent, InType: reflect.TypeOf(&WatchEvent{})}, + } +} + +// DeepCopy_v1_APIGroup is an autogenerated deepcopy function. +func DeepCopy_v1_APIGroup(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*APIGroup) + out := out.(*APIGroup) + *out = *in + if in.Versions != nil { + in, out := &in.Versions, &out.Versions + *out = make([]GroupVersionForDiscovery, len(*in)) + copy(*out, *in) + } + if in.ServerAddressByClientCIDRs != nil { + in, out := &in.ServerAddressByClientCIDRs, &out.ServerAddressByClientCIDRs + *out = make([]ServerAddressByClientCIDR, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_APIGroupList is an autogenerated deepcopy function. +func DeepCopy_v1_APIGroupList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*APIGroupList) + out := out.(*APIGroupList) + *out = *in + if in.Groups != nil { + in, out := &in.Groups, &out.Groups + *out = make([]APIGroup, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(*APIGroup) + } + } + } + return nil + } +} + +// DeepCopy_v1_APIResource is an autogenerated deepcopy function. +func DeepCopy_v1_APIResource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*APIResource) + out := out.(*APIResource) + *out = *in + if in.Verbs != nil { + in, out := &in.Verbs, &out.Verbs + *out = make(Verbs, len(*in)) + copy(*out, *in) + } + if in.ShortNames != nil { + in, out := &in.ShortNames, &out.ShortNames + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Categories != nil { + in, out := &in.Categories, &out.Categories + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_APIResourceList is an autogenerated deepcopy function. +func DeepCopy_v1_APIResourceList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*APIResourceList) + out := out.(*APIResourceList) + *out = *in + if in.APIResources != nil { + in, out := &in.APIResources, &out.APIResources + *out = make([]APIResource, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(*APIResource) + } + } + } + return nil + } +} + +// DeepCopy_v1_APIVersions is an autogenerated deepcopy function. +func DeepCopy_v1_APIVersions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*APIVersions) + out := out.(*APIVersions) + *out = *in + if in.Versions != nil { + in, out := &in.Versions, &out.Versions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.ServerAddressByClientCIDRs != nil { + in, out := &in.ServerAddressByClientCIDRs, &out.ServerAddressByClientCIDRs + *out = make([]ServerAddressByClientCIDR, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_DeleteOptions is an autogenerated deepcopy function. +func DeepCopy_v1_DeleteOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeleteOptions) + out := out.(*DeleteOptions) + *out = *in + if in.GracePeriodSeconds != nil { + in, out := &in.GracePeriodSeconds, &out.GracePeriodSeconds + *out = new(int64) + **out = **in + } + if in.Preconditions != nil { + in, out := &in.Preconditions, &out.Preconditions + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*Preconditions) + } + } + if in.OrphanDependents != nil { + in, out := &in.OrphanDependents, &out.OrphanDependents + *out = new(bool) + **out = **in + } + if in.PropagationPolicy != nil { + in, out := &in.PropagationPolicy, &out.PropagationPolicy + *out = new(DeletionPropagation) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_Duration is an autogenerated deepcopy function. +func DeepCopy_v1_Duration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Duration) + out := out.(*Duration) + *out = *in + return nil + } +} + +// DeepCopy_v1_ExportOptions is an autogenerated deepcopy function. +func DeepCopy_v1_ExportOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExportOptions) + out := out.(*ExportOptions) + *out = *in + return nil + } +} + +// DeepCopy_v1_GetOptions is an autogenerated deepcopy function. +func DeepCopy_v1_GetOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GetOptions) + out := out.(*GetOptions) + *out = *in + return nil + } +} + +// DeepCopy_v1_GroupKind is an autogenerated deepcopy function. +func DeepCopy_v1_GroupKind(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupKind) + out := out.(*GroupKind) + *out = *in + return nil + } +} + +// DeepCopy_v1_GroupResource is an autogenerated deepcopy function. +func DeepCopy_v1_GroupResource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupResource) + out := out.(*GroupResource) + *out = *in + return nil + } +} + +// DeepCopy_v1_GroupVersion is an autogenerated deepcopy function. +func DeepCopy_v1_GroupVersion(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupVersion) + out := out.(*GroupVersion) + *out = *in + return nil + } +} + +// DeepCopy_v1_GroupVersionForDiscovery is an autogenerated deepcopy function. +func DeepCopy_v1_GroupVersionForDiscovery(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupVersionForDiscovery) + out := out.(*GroupVersionForDiscovery) + *out = *in + return nil + } +} + +// DeepCopy_v1_GroupVersionKind is an autogenerated deepcopy function. +func DeepCopy_v1_GroupVersionKind(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupVersionKind) + out := out.(*GroupVersionKind) + *out = *in + return nil + } +} + +// DeepCopy_v1_GroupVersionResource is an autogenerated deepcopy function. +func DeepCopy_v1_GroupVersionResource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupVersionResource) + out := out.(*GroupVersionResource) + *out = *in + return nil + } +} + +// DeepCopy_v1_Initializer is an autogenerated deepcopy function. +func DeepCopy_v1_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + return nil + } +} + +// DeepCopy_v1_Initializers is an autogenerated deepcopy function. +func DeepCopy_v1_Initializers(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializers) + out := out.(*Initializers) + *out = *in + if in.Pending != nil { + in, out := &in.Pending, &out.Pending + *out = make([]Initializer, len(*in)) + copy(*out, *in) + } + if in.Result != nil { + in, out := &in.Result, &out.Result + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*Status) + } + } + return nil + } +} + +// DeepCopy_v1_InternalEvent is an autogenerated deepcopy function. +func DeepCopy_v1_InternalEvent(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InternalEvent) + out := out.(*InternalEvent) + *out = *in + // in.Object is kind 'Interface' + if in.Object != nil { + if newVal, err := c.DeepCopy(&in.Object); err != nil { + return err + } else { + out.Object = *newVal.(*runtime.Object) + } + } + return nil + } +} + +// DeepCopy_v1_LabelSelector is an autogenerated deepcopy function. +func DeepCopy_v1_LabelSelector(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*LabelSelector) + out := out.(*LabelSelector) + *out = *in + if in.MatchLabels != nil { + in, out := &in.MatchLabels, &out.MatchLabels + *out = make(map[string]string) + for key, val := range *in { + (*out)[key] = val + } + } + if in.MatchExpressions != nil { + in, out := &in.MatchExpressions, &out.MatchExpressions + *out = make([]LabelSelectorRequirement, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(*LabelSelectorRequirement) + } + } + } + return nil + } +} + +// DeepCopy_v1_LabelSelectorRequirement is an autogenerated deepcopy function. +func DeepCopy_v1_LabelSelectorRequirement(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*LabelSelectorRequirement) + out := out.(*LabelSelectorRequirement) + *out = *in + if in.Values != nil { + in, out := &in.Values, &out.Values + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_ListMeta is an autogenerated deepcopy function. +func DeepCopy_v1_ListMeta(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ListMeta) + out := out.(*ListMeta) + *out = *in + return nil + } +} + +// DeepCopy_v1_ListOptions is an autogenerated deepcopy function. +func DeepCopy_v1_ListOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ListOptions) + out := out.(*ListOptions) + *out = *in + if in.TimeoutSeconds != nil { + in, out := &in.TimeoutSeconds, &out.TimeoutSeconds + *out = new(int64) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_MicroTime is an autogenerated deepcopy function. +func DeepCopy_v1_MicroTime(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MicroTime) + out := out.(*MicroTime) + *out = in.DeepCopy() + return nil + } +} + +// DeepCopy_v1_ObjectMeta is an autogenerated deepcopy function. +func DeepCopy_v1_ObjectMeta(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMeta) + out := out.(*ObjectMeta) + *out = *in + out.CreationTimestamp = in.CreationTimestamp.DeepCopy() + if in.DeletionTimestamp != nil { + in, out := &in.DeletionTimestamp, &out.DeletionTimestamp + *out = new(Time) + **out = (*in).DeepCopy() + } + if in.DeletionGracePeriodSeconds != nil { + in, out := &in.DeletionGracePeriodSeconds, &out.DeletionGracePeriodSeconds + *out = new(int64) + **out = **in + } + if in.Labels != nil { + in, out := &in.Labels, &out.Labels + *out = make(map[string]string) + for key, val := range *in { + (*out)[key] = val + } + } + if in.Annotations != nil { + in, out := &in.Annotations, &out.Annotations + *out = make(map[string]string) + for key, val := range *in { + (*out)[key] = val + } + } + if in.OwnerReferences != nil { + in, out := &in.OwnerReferences, &out.OwnerReferences + *out = make([]OwnerReference, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(*OwnerReference) + } + } + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*Initializers) + } + } + if in.Finalizers != nil { + in, out := &in.Finalizers, &out.Finalizers + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_OwnerReference is an autogenerated deepcopy function. +func DeepCopy_v1_OwnerReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*OwnerReference) + out := out.(*OwnerReference) + *out = *in + if in.Controller != nil { + in, out := &in.Controller, &out.Controller + *out = new(bool) + **out = **in + } + if in.BlockOwnerDeletion != nil { + in, out := &in.BlockOwnerDeletion, &out.BlockOwnerDeletion + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_Patch is an autogenerated deepcopy function. +func DeepCopy_v1_Patch(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Patch) + out := out.(*Patch) + *out = *in + return nil + } +} + +// DeepCopy_v1_Preconditions is an autogenerated deepcopy function. +func DeepCopy_v1_Preconditions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Preconditions) + out := out.(*Preconditions) + *out = *in + if in.UID != nil { + in, out := &in.UID, &out.UID + *out = new(types.UID) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_RootPaths is an autogenerated deepcopy function. +func DeepCopy_v1_RootPaths(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RootPaths) + out := out.(*RootPaths) + *out = *in + if in.Paths != nil { + in, out := &in.Paths, &out.Paths + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_ServerAddressByClientCIDR is an autogenerated deepcopy function. +func DeepCopy_v1_ServerAddressByClientCIDR(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServerAddressByClientCIDR) + out := out.(*ServerAddressByClientCIDR) + *out = *in + return nil + } +} + +// DeepCopy_v1_Status is an autogenerated deepcopy function. +func DeepCopy_v1_Status(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Status) + out := out.(*Status) + *out = *in + if in.Details != nil { + in, out := &in.Details, &out.Details + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*StatusDetails) + } + } + return nil + } +} + +// DeepCopy_v1_StatusCause is an autogenerated deepcopy function. +func DeepCopy_v1_StatusCause(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StatusCause) + out := out.(*StatusCause) + *out = *in + return nil + } +} + +// DeepCopy_v1_StatusDetails is an autogenerated deepcopy function. +func DeepCopy_v1_StatusDetails(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StatusDetails) + out := out.(*StatusDetails) + *out = *in + if in.Causes != nil { + in, out := &in.Causes, &out.Causes + *out = make([]StatusCause, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_Time is an autogenerated deepcopy function. +func DeepCopy_v1_Time(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Time) + out := out.(*Time) + *out = in.DeepCopy() + return nil + } +} + +// DeepCopy_v1_Timestamp is an autogenerated deepcopy function. +func DeepCopy_v1_Timestamp(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Timestamp) + out := out.(*Timestamp) + *out = *in + return nil + } +} + +// DeepCopy_v1_TypeMeta is an autogenerated deepcopy function. +func DeepCopy_v1_TypeMeta(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TypeMeta) + out := out.(*TypeMeta) + *out = *in + return nil + } +} + +// DeepCopy_v1_WatchEvent is an autogenerated deepcopy function. +func DeepCopy_v1_WatchEvent(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*WatchEvent) + out := out.(*WatchEvent) + *out = *in + if newVal, err := c.DeepCopy(&in.Object); err != nil { + return err + } else { + out.Object = *newVal.(*runtime.RawExtension) + } + return nil + } +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.defaults.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.defaults.go new file mode 100644 index 0000000000..6df448eb9f --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/BUILD b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/BUILD new file mode 100644 index 0000000000..e60fab8879 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated.pb.go", + "register.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/doc.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/doc.go similarity index 77% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/doc.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/doc.go index 0e0b1ceabc..eea67c5c83 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/doc.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,10 +14,9 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/certificates +// +k8s:deepcopy-gen=package // +k8s:openapi-gen=true // +k8s:defaulter-gen=TypeMeta -// +groupName=certificates.k8s.io +// +groupName=meta.k8s.io package v1alpha1 diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.pb.go new file mode 100644 index 0000000000..2d43bf94f6 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.pb.go @@ -0,0 +1,633 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto +// DO NOT EDIT! + +/* + Package v1alpha1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto + + It has these top-level messages: + PartialObjectMetadata + PartialObjectMetadataList + TableOptions +*/ +package v1alpha1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *PartialObjectMetadata) Reset() { *m = PartialObjectMetadata{} } +func (*PartialObjectMetadata) ProtoMessage() {} +func (*PartialObjectMetadata) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *PartialObjectMetadataList) Reset() { *m = PartialObjectMetadataList{} } +func (*PartialObjectMetadataList) ProtoMessage() {} +func (*PartialObjectMetadataList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{1} +} + +func (m *TableOptions) Reset() { *m = TableOptions{} } +func (*TableOptions) ProtoMessage() {} +func (*TableOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func init() { + proto.RegisterType((*PartialObjectMetadata)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1alpha1.PartialObjectMetadata") + proto.RegisterType((*PartialObjectMetadataList)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1alpha1.PartialObjectMetadataList") + proto.RegisterType((*TableOptions)(nil), "k8s.io.apimachinery.pkg.apis.meta.v1alpha1.TableOptions") +} +func (m *PartialObjectMetadata) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PartialObjectMetadata) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + return i, nil +} + +func (m *PartialObjectMetadataList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PartialObjectMetadataList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *TableOptions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TableOptions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.IncludeObject))) + i += copy(dAtA[i:], m.IncludeObject) + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *PartialObjectMetadata) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *PartialObjectMetadataList) Size() (n int) { + var l int + _ = l + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *TableOptions) Size() (n int) { + var l int + _ = l + l = len(m.IncludeObject) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *PartialObjectMetadata) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PartialObjectMetadata{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PartialObjectMetadataList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PartialObjectMetadataList{`, + `Items:` + strings.Replace(fmt.Sprintf("%v", this.Items), "PartialObjectMetadata", "PartialObjectMetadata", 1) + `,`, + `}`, + }, "") + return s +} +func (this *TableOptions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TableOptions{`, + `IncludeObject:` + fmt.Sprintf("%v", this.IncludeObject) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *PartialObjectMetadata) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PartialObjectMetadata: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PartialObjectMetadata: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PartialObjectMetadataList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PartialObjectMetadataList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PartialObjectMetadataList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, &PartialObjectMetadata{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TableOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: TableOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TableOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field IncludeObject", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.IncludeObject = IncludeObjectPolicy(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 392 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x91, 0xbf, 0x6e, 0xd4, 0x40, + 0x10, 0x87, 0xbd, 0x42, 0x91, 0x92, 0x0d, 0x69, 0x8c, 0x90, 0xc2, 0x15, 0xeb, 0xe8, 0xaa, 0x08, + 0xc1, 0x2e, 0x09, 0x08, 0xd1, 0xe2, 0x2e, 0x12, 0x28, 0x91, 0xa1, 0xa2, 0x62, 0x6d, 0x0f, 0xf6, + 0x62, 0x7b, 0xd7, 0xda, 0x1d, 0x47, 0xba, 0x0a, 0x1e, 0x81, 0xc7, 0xba, 0x32, 0x65, 0x2a, 0x8b, + 0x33, 0x6f, 0x41, 0x85, 0x6c, 0x5f, 0xc8, 0xbf, 0x3b, 0xe5, 0xba, 0x99, 0xdf, 0xe8, 0xfb, 0x3c, + 0xe3, 0xa5, 0x9f, 0x8a, 0x77, 0x8e, 0x2b, 0x23, 0x8a, 0x26, 0x06, 0xab, 0x01, 0xc1, 0x89, 0x73, + 0xd0, 0xa9, 0xb1, 0x62, 0x39, 0x90, 0xb5, 0xaa, 0x64, 0x92, 0x2b, 0x0d, 0x76, 0x26, 0xea, 0x22, + 0xeb, 0x03, 0x27, 0x2a, 0x40, 0x29, 0xce, 0x8f, 0x64, 0x59, 0xe7, 0xf2, 0x48, 0x64, 0xa0, 0xc1, + 0x4a, 0x84, 0x94, 0xd7, 0xd6, 0xa0, 0xf1, 0x9f, 0x8f, 0x2c, 0xbf, 0xc9, 0xf2, 0xba, 0xc8, 0xfa, + 0xc0, 0xf1, 0x9e, 0xe5, 0x57, 0xec, 0xe4, 0x65, 0xa6, 0x30, 0x6f, 0x62, 0x9e, 0x98, 0x4a, 0x64, + 0x26, 0x33, 0x62, 0x50, 0xc4, 0xcd, 0xb7, 0xa1, 0x1b, 0x9a, 0xa1, 0x1a, 0xd5, 0x93, 0x37, 0x9b, + 0xac, 0x75, 0x77, 0xa1, 0xc9, 0xda, 0x63, 0x6c, 0xa3, 0x51, 0x55, 0x70, 0x0f, 0x78, 0xfb, 0x10, + 0xe0, 0x92, 0x1c, 0x2a, 0x79, 0x8f, 0x7b, 0xbd, 0x8e, 0x6b, 0x50, 0x95, 0x42, 0x69, 0x74, 0x68, + 0xef, 0x42, 0xd3, 0x19, 0x7d, 0x7a, 0x26, 0x2d, 0x2a, 0x59, 0x9e, 0xc6, 0xdf, 0x21, 0xc1, 0x8f, + 0x80, 0x32, 0x95, 0x28, 0xfd, 0xaf, 0x74, 0xbb, 0x5a, 0xd6, 0xfb, 0xe4, 0x80, 0x1c, 0xee, 0x1e, + 0xbf, 0xe2, 0x9b, 0xfc, 0x5a, 0x7e, 0xed, 0x09, 0xfd, 0x79, 0x1b, 0x78, 0x5d, 0x1b, 0xd0, 0xeb, + 0x2c, 0xfa, 0x6f, 0x9d, 0xfe, 0xa0, 0xcf, 0x56, 0x7e, 0xfa, 0x83, 0x72, 0xe8, 0xc7, 0x74, 0x4b, + 0x21, 0x54, 0x6e, 0x9f, 0x1c, 0x3c, 0x3a, 0xdc, 0x3d, 0x7e, 0xcf, 0x37, 0x7f, 0x56, 0xbe, 0xd2, + 0x1a, 0xee, 0x74, 0x6d, 0xb0, 0x75, 0xd2, 0x3b, 0xa3, 0x51, 0x3d, 0x8d, 0xe9, 0xe3, 0xcf, 0x32, + 0x2e, 0xe1, 0xb4, 0x46, 0x65, 0xb4, 0xf3, 0x23, 0xba, 0xa7, 0x74, 0x52, 0x36, 0x29, 0x8c, 0xe8, + 0x70, 0xf7, 0x4e, 0xf8, 0x62, 0x79, 0xc5, 0xde, 0xc9, 0xcd, 0xe1, 0xdf, 0x36, 0x78, 0x72, 0x2b, + 0x38, 0x33, 0xa5, 0x4a, 0x66, 0xd1, 0x6d, 0x45, 0xc8, 0xe7, 0x0b, 0xe6, 0x5d, 0x2c, 0x98, 0x77, + 0xb9, 0x60, 0xde, 0xcf, 0x8e, 0x91, 0x79, 0xc7, 0xc8, 0x45, 0xc7, 0xc8, 0x65, 0xc7, 0xc8, 0xef, + 0x8e, 0x91, 0x5f, 0x7f, 0x98, 0xf7, 0x65, 0xfb, 0x6a, 0xf7, 0x7f, 0x01, 0x00, 0x00, 0xff, 0xff, + 0x97, 0x95, 0xbb, 0xf9, 0x14, 0x03, 0x00, 0x00, +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto new file mode 100644 index 0000000000..06833dbd96 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/generated.proto @@ -0,0 +1,55 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.apimachinery.pkg.apis.meta.v1alpha1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1alpha1"; + +// PartialObjectMetadata is a generic representation of any object with ObjectMeta. It allows clients +// to get access to a particular ObjectMeta schema without knowing the details of the version. +message PartialObjectMetadata { + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; +} + +// PartialObjectMetadataList contains a list of objects containing only their metadata +message PartialObjectMetadataList { + // items contains each of the included items. + repeated PartialObjectMetadata items = 1; +} + +// TableOptions are used when a Table is requested by the caller. +message TableOptions { + // includeObject decides whether to include each object along with its columnar information. + // Specifying "None" will return no object, specifying "Object" will return the full object contents, and + // specifying "Metadata" (the default) will return the object's metadata in the PartialObjectMetadata kind + // in version v1alpha1 of the meta.k8s.io API group. + optional string includeObject = 1; +} + diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/register.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/register.go new file mode 100644 index 0000000000..89f08f3837 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/register.go @@ -0,0 +1,51 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name for this API. +const GroupName = "meta.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} + +// Kind takes an unqualified kind and returns a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// scheme is the registry for the common types that adhere to the meta v1alpha1 API spec. +var scheme = runtime.NewScheme() + +// ParameterCodec knows about query parameters used with the meta v1alpha1 API spec. +var ParameterCodec = runtime.NewParameterCodec(scheme) + +func init() { + scheme.AddKnownTypes(SchemeGroupVersion, + &Table{}, + &TableOptions{}, + &PartialObjectMetadata{}, + &PartialObjectMetadataList{}, + ) + + // register manually. This usually goes through the SchemeBuilder, which we cannot use here. + //scheme.AddGeneratedDeepCopyFuncs(GetGeneratedDeepCopyFuncs()...) +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types.go new file mode 100644 index 0000000000..ef99218061 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types.go @@ -0,0 +1,157 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// package v1alpha1 is alpha objects from meta that will be introduced. +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" +) + +// TODO: Table does not generate to protobuf because of the interface{} - fix protobuf +// generation to support a meta type that can accept any valid JSON. + +// Table is a tabular representation of a set of API resources. The server transforms the +// object into a set of preferred columns for quickly reviewing the objects. +// +protobuf=false +type Table struct { + v1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + v1.ListMeta `json:"metadata,omitempty"` + + // columnDefinitions describes each column in the returned items array. The number of cells per row + // will always match the number of column definitions. + ColumnDefinitions []TableColumnDefinition `json:"columnDefinitions"` + // rows is the list of items in the table. + Rows []TableRow `json:"rows"` +} + +// TableColumnDefinition contains information about a column returned in the Table. +// +protobuf=false +type TableColumnDefinition struct { + // name is a human readable name for the column. + Name string `json:"name"` + // type is an OpenAPI type definition for this column. + // See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more. + Type string `json:"type"` + // format is an optional OpenAPI type definition for this column. The 'name' format is applied + // to the primary identifier column to assist in clients identifying column is the resource name. + // See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more. + Format string `json:"format"` + // description is a human readable description of this column. + Description string `json:"description"` + // priority is an integer defining the relative importance of this column compared to others. Lower + // numbers are considered higher priority. Columns that may be omitted in limited space scenarios + // should be given a higher priority. + Priority int32 `json:"priority"` +} + +// TableRow is an individual row in a table. +// +protobuf=false +type TableRow struct { + // cells will be as wide as headers and may contain strings, numbers, booleans, simple maps, or lists, or + // null. See the type field of the column definition for a more detailed description. + Cells []interface{} `json:"cells"` + // conditions describe additional status of a row that are relevant for a human user. + // +optional + Conditions []TableRowCondition `json:"conditions,omitempty"` + // This field contains the requested additional information about each object based on the includeObject + // policy when requesting the Table. If "None", this field is empty, if "Object" this will be the + // default serialization of the object for the current API version, and if "Metadata" (the default) will + // contain the object metadata. Check the returned kind and apiVersion of the object before parsing. + // +optional + Object runtime.RawExtension `json:"object,omitempty"` +} + +// TableRowCondition allows a row to be marked with additional information. +// +protobuf=false +type TableRowCondition struct { + // Type of row condition. + Type RowConditionType `json:"type"` + // Status of the condition, one of True, False, Unknown. + Status ConditionStatus `json:"status"` + // (brief) machine readable reason for the condition's last transition. + // +optional + Reason string `json:"reason,omitempty"` + // Human readable message indicating details about last transition. + // +optional + Message string `json:"message,omitempty"` +} + +type RowConditionType string + +// These are valid conditions of a row. This list is not exhaustive and new conditions may be +// inculded by other resources. +const ( + // RowCompleted means the underlying resource has reached completion and may be given less + // visual priority than other resources. + RowCompleted RowConditionType = "Completed" +) + +type ConditionStatus string + +// These are valid condition statuses. "ConditionTrue" means a resource is in the condition. +// "ConditionFalse" means a resource is not in the condition. "ConditionUnknown" means kubernetes +// can't decide if a resource is in the condition or not. In the future, we could add other +// intermediate conditions, e.g. ConditionDegraded. +const ( + ConditionTrue ConditionStatus = "True" + ConditionFalse ConditionStatus = "False" + ConditionUnknown ConditionStatus = "Unknown" +) + +// IncludeObjectPolicy controls which portion of the object is returned with a Table. +type IncludeObjectPolicy string + +const ( + // IncludeNone returns no object. + IncludeNone IncludeObjectPolicy = "None" + // IncludeMetadata serializes the object containing only its metadata field. + IncludeMetadata IncludeObjectPolicy = "Metadata" + // IncludeObject contains the full object. + IncludeObject IncludeObjectPolicy = "Object" +) + +// TableOptions are used when a Table is requested by the caller. +type TableOptions struct { + v1.TypeMeta `json:",inline"` + // includeObject decides whether to include each object along with its columnar information. + // Specifying "None" will return no object, specifying "Object" will return the full object contents, and + // specifying "Metadata" (the default) will return the object's metadata in the PartialObjectMetadata kind + // in version v1alpha1 of the meta.k8s.io API group. + IncludeObject IncludeObjectPolicy `json:"includeObject,omitempty" protobuf:"bytes,1,opt,name=includeObject,casttype=IncludeObjectPolicy"` +} + +// PartialObjectMetadata is a generic representation of any object with ObjectMeta. It allows clients +// to get access to a particular ObjectMeta schema without knowing the details of the version. +type PartialObjectMetadata struct { + v1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` +} + +// PartialObjectMetadataList contains a list of objects containing only their metadata +type PartialObjectMetadataList struct { + v1.TypeMeta `json:",inline"` + + // items contains each of the included items. + Items []*PartialObjectMetadata `json:"items" protobuf:"bytes,1,rep,name=items"` +} diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..e8bb626029 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/types_swagger_doc_generated.go @@ -0,0 +1,104 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_PartialObjectMetadata = map[string]string{ + "": "PartialObjectMetadata is a generic representation of any object with ObjectMeta. It allows clients to get access to a particular ObjectMeta schema without knowing the details of the version.", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", +} + +func (PartialObjectMetadata) SwaggerDoc() map[string]string { + return map_PartialObjectMetadata +} + +var map_PartialObjectMetadataList = map[string]string{ + "": "PartialObjectMetadataList contains a list of objects containing only their metadata", + "items": "items contains each of the included items.", +} + +func (PartialObjectMetadataList) SwaggerDoc() map[string]string { + return map_PartialObjectMetadataList +} + +var map_Table = map[string]string{ + "": "Table is a tabular representation of a set of API resources. The server transforms the object into a set of preferred columns for quickly reviewing the objects.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "columnDefinitions": "columnDefinitions describes each column in the returned items array. The number of cells per row will always match the number of column definitions.", + "rows": "rows is the list of items in the table.", +} + +func (Table) SwaggerDoc() map[string]string { + return map_Table +} + +var map_TableColumnDefinition = map[string]string{ + "": "TableColumnDefinition contains information about a column returned in the Table.", + "name": "name is a human readable name for the column.", + "type": "type is an OpenAPI type definition for this column. See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more.", + "format": "format is an optional OpenAPI type definition for this column. The 'name' format is applied to the primary identifier column to assist in clients identifying column is the resource name. See https://github.com/OAI/OpenAPI-Specification/blob/master/versions/2.0.md#data-types for more.", + "description": "description is a human readable description of this column.", + "priority": "priority is an integer defining the relative importance of this column compared to others. Lower numbers are considered higher priority. Columns that may be omitted in limited space scenarios should be given a higher priority.", +} + +func (TableColumnDefinition) SwaggerDoc() map[string]string { + return map_TableColumnDefinition +} + +var map_TableOptions = map[string]string{ + "": "TableOptions are used when a Table is requested by the caller.", + "includeObject": "includeObject decides whether to include each object along with its columnar information. Specifying \"None\" will return no object, specifying \"Object\" will return the full object contents, and specifying \"Metadata\" (the default) will return the object's metadata in the PartialObjectMetadata kind in version v1alpha1 of the meta.k8s.io API group.", +} + +func (TableOptions) SwaggerDoc() map[string]string { + return map_TableOptions +} + +var map_TableRow = map[string]string{ + "": "TableRow is an individual row in a table.", + "cells": "cells will be as wide as headers and may contain strings, numbers, booleans, simple maps, or lists, or null. See the type field of the column definition for a more detailed description.", + "conditions": "conditions describe additional status of a row that are relevant for a human user.", + "object": "This field contains the requested additional information about each object based on the includeObject policy when requesting the Table. If \"None\", this field is empty, if \"Object\" this will be the default serialization of the object for the current API version, and if \"Metadata\" (the default) will contain the object metadata. Check the returned kind and apiVersion of the object before parsing.", +} + +func (TableRow) SwaggerDoc() map[string]string { + return map_TableRow +} + +var map_TableRowCondition = map[string]string{ + "": "TableRowCondition allows a row to be marked with additional information.", + "type": "Type of row condition.", + "status": "Status of the condition, one of True, False, Unknown.", + "reason": "(brief) machine readable reason for the condition's last transition.", + "message": "Human readable message indicating details about last transition.", +} + +func (TableRowCondition) SwaggerDoc() map[string]string { + return map_TableRowCondition +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..ef8a117df8 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.deepcopy.go @@ -0,0 +1,164 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +// GetGeneratedDeepCopyFuncs returns the generated funcs, since we aren't registering them. +func GetGeneratedDeepCopyFuncs() []conversion.GeneratedDeepCopyFunc { + return []conversion.GeneratedDeepCopyFunc{ + {Fn: DeepCopy_v1alpha1_PartialObjectMetadata, InType: reflect.TypeOf(&PartialObjectMetadata{})}, + {Fn: DeepCopy_v1alpha1_PartialObjectMetadataList, InType: reflect.TypeOf(&PartialObjectMetadataList{})}, + {Fn: DeepCopy_v1alpha1_Table, InType: reflect.TypeOf(&Table{})}, + {Fn: DeepCopy_v1alpha1_TableColumnDefinition, InType: reflect.TypeOf(&TableColumnDefinition{})}, + {Fn: DeepCopy_v1alpha1_TableOptions, InType: reflect.TypeOf(&TableOptions{})}, + {Fn: DeepCopy_v1alpha1_TableRow, InType: reflect.TypeOf(&TableRow{})}, + {Fn: DeepCopy_v1alpha1_TableRowCondition, InType: reflect.TypeOf(&TableRowCondition{})}, + } +} + +// DeepCopy_v1alpha1_PartialObjectMetadata is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_PartialObjectMetadata(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PartialObjectMetadata) + out := out.(*PartialObjectMetadata) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + return nil + } +} + +// DeepCopy_v1alpha1_PartialObjectMetadataList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_PartialObjectMetadataList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PartialObjectMetadataList) + out := out.(*PartialObjectMetadataList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]*PartialObjectMetadata, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(**PartialObjectMetadata) + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Table is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Table(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Table) + out := out.(*Table) + *out = *in + if in.ColumnDefinitions != nil { + in, out := &in.ColumnDefinitions, &out.ColumnDefinitions + *out = make([]TableColumnDefinition, len(*in)) + copy(*out, *in) + } + if in.Rows != nil { + in, out := &in.Rows, &out.Rows + *out = make([]TableRow, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(*TableRow) + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_TableColumnDefinition is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_TableColumnDefinition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TableColumnDefinition) + out := out.(*TableColumnDefinition) + *out = *in + return nil + } +} + +// DeepCopy_v1alpha1_TableOptions is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_TableOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TableOptions) + out := out.(*TableOptions) + *out = *in + return nil + } +} + +// DeepCopy_v1alpha1_TableRow is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_TableRow(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TableRow) + out := out.(*TableRow) + *out = *in + if in.Cells != nil { + in, out := &in.Cells, &out.Cells + *out = make([]interface{}, len(*in)) + for i := range *in { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { + return err + } else { + (*out)[i] = *newVal.(*interface{}) + } + } + } + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]TableRowCondition, len(*in)) + copy(*out, *in) + } + if newVal, err := c.DeepCopy(&in.Object); err != nil { + return err + } else { + out.Object = *newVal.(*runtime.RawExtension) + } + return nil + } +} + +// DeepCopy_v1alpha1_TableRowCondition is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_TableRowCondition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TableRowCondition) + out := out.(*TableRowCondition) + *out = *in + return nil + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/doc.go b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.defaults.go similarity index 54% rename from vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/doc.go rename to vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.defaults.go index 4ca4e887ae..7e6df29d4a 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/doc.go +++ b/vendor/k8s.io/apimachinery/pkg/apis/meta/v1alpha1/zz_generated.defaults.go @@ -1,5 +1,7 @@ +// +build !ignore_autogenerated + /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +16,17 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This file was autogenerated by defaulter-gen. Do not edit it manually! -// This package has the automatically generated typed clients. package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/apimachinery/pkg/conversion/BUILD b/vendor/k8s.io/apimachinery/pkg/conversion/BUILD new file mode 100644 index 0000000000..643614ee48 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/conversion/BUILD @@ -0,0 +1,38 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "converter_test.go", + "deep_copy_test.go", + "helper_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "cloner.go", + "converter.go", + "deep_equal.go", + "doc.go", + "helper.go", + ], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/third_party/forked/golang/reflect:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/pkg/conversion/cloner.go b/vendor/k8s.io/apimachinery/pkg/conversion/cloner.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/conversion/cloner.go rename to vendor/k8s.io/apimachinery/pkg/conversion/cloner.go diff --git a/vendor/k8s.io/client-go/pkg/conversion/converter.go b/vendor/k8s.io/apimachinery/pkg/conversion/converter.go similarity index 93% rename from vendor/k8s.io/client-go/pkg/conversion/converter.go rename to vendor/k8s.io/apimachinery/pkg/conversion/converter.go index 9ab468ebe2..7854c207c7 100644 --- a/vendor/k8s.io/client-go/pkg/conversion/converter.go +++ b/vendor/k8s.io/apimachinery/pkg/conversion/converter.go @@ -66,12 +66,6 @@ type Converter struct { // source field name and type to look for. structFieldSources map[typeNamePair][]typeNamePair - // Map from a type to a function which applies defaults. - defaultingFuncs map[reflect.Type]reflect.Value - - // Similar to above, but function is stored as interface{}. - defaultingInterfaces map[reflect.Type]interface{} - // Map from an input type to a function which can apply a key name mapping inputFieldMappingFuncs map[reflect.Type]FieldMappingFunc @@ -93,8 +87,6 @@ func NewConverter(nameFn NameFunc) *Converter { conversionFuncs: NewConversionFuncs(), generatedConversionFuncs: NewConversionFuncs(), ignoredConversions: make(map[typePair]struct{}), - defaultingFuncs: make(map[reflect.Type]reflect.Value), - defaultingInterfaces: make(map[reflect.Type]interface{}), nameFunc: nameFn, structFieldDests: make(map[typeNamePair][]typeNamePair), structFieldSources: make(map[typeNamePair][]typeNamePair), @@ -152,10 +144,6 @@ type Scope interface { // on the current stack frame. This makes it safe to call from a conversion func. DefaultConvert(src, dest interface{}, flags FieldMatchingFlags) error - // If registered, returns a function applying defaults for objects of a given type. - // Used for automatically generating conversion functions. - DefaultingInterface(inType reflect.Type) (interface{}, bool) - // SrcTags and DestTags contain the struct tags that src and dest had, respectively. // If the enclosing object was not a struct, then these will contain no tags, of course. SrcTag() reflect.StructTag @@ -269,11 +257,6 @@ func (s scopeStack) describe() string { return desc } -func (s *scope) DefaultingInterface(inType reflect.Type) (interface{}, bool) { - value, found := s.converter.defaultingInterfaces[inType] - return value, found -} - // Formats src & dest as indices for printing. func (s *scope) setIndices(src, dest int) { s.srcStack.top().key = fmt.Sprintf("[%v]", src) @@ -430,35 +413,6 @@ func (c *Converter) SetStructFieldCopy(srcFieldType interface{}, srcFieldName st return nil } -// RegisterDefaultingFunc registers a value-defaulting func with the Converter. -// defaultingFunc must take one parameter: a pointer to the input type. -// -// Example: -// c.RegisterDefaultingFunc( -// func(in *v1.Pod) { -// // defaulting logic... -// }) -func (c *Converter) RegisterDefaultingFunc(defaultingFunc interface{}) error { - fv := reflect.ValueOf(defaultingFunc) - ft := fv.Type() - if ft.Kind() != reflect.Func { - return fmt.Errorf("expected func, got: %v", ft) - } - if ft.NumIn() != 1 { - return fmt.Errorf("expected one 'in' param, got: %v", ft) - } - if ft.NumOut() != 0 { - return fmt.Errorf("expected zero 'out' params, got: %v", ft) - } - if ft.In(0).Kind() != reflect.Ptr { - return fmt.Errorf("expected pointer arg for 'in' param 0, got: %v", ft) - } - inType := ft.In(0).Elem() - c.defaultingFuncs[inType] = fv - c.defaultingInterfaces[inType] = defaultingFunc - return nil -} - // RegisterInputDefaults registers a field name mapping function, used when converting // from maps to structs. Inputs to the conversion methods are checked for this type and a mapping // applied automatically if the input matches in. A set of default flags for the input conversion @@ -596,15 +550,6 @@ func (c *Converter) callCustom(sv, dv, custom reflect.Value, scope *scope) error // one is registered. func (c *Converter) convert(sv, dv reflect.Value, scope *scope) error { dt, st := dv.Type(), sv.Type() - // Apply default values. - if fv, ok := c.defaultingFuncs[st]; ok { - if c.Debug != nil { - c.Debug.Logf("Applying defaults for '%v'", st) - } - args := []reflect.Value{sv.Addr()} - fv.Call(args) - } - pair := typePair{st, dt} // ignore conversions of this type diff --git a/vendor/k8s.io/client-go/pkg/conversion/deep_equal.go b/vendor/k8s.io/apimachinery/pkg/conversion/deep_equal.go similarity index 94% rename from vendor/k8s.io/client-go/pkg/conversion/deep_equal.go rename to vendor/k8s.io/apimachinery/pkg/conversion/deep_equal.go index d1cf931b51..f21abe1e53 100644 --- a/vendor/k8s.io/client-go/pkg/conversion/deep_equal.go +++ b/vendor/k8s.io/apimachinery/pkg/conversion/deep_equal.go @@ -17,7 +17,7 @@ limitations under the License. package conversion import ( - "k8s.io/client-go/pkg/third_party/forked/golang/reflect" + "k8s.io/apimachinery/third_party/forked/golang/reflect" ) // The code for this type must be located in third_party, since it forks from diff --git a/vendor/k8s.io/client-go/pkg/conversion/doc.go b/vendor/k8s.io/apimachinery/pkg/conversion/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/conversion/doc.go rename to vendor/k8s.io/apimachinery/pkg/conversion/doc.go diff --git a/vendor/k8s.io/client-go/pkg/conversion/helper.go b/vendor/k8s.io/apimachinery/pkg/conversion/helper.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/conversion/helper.go rename to vendor/k8s.io/apimachinery/pkg/conversion/helper.go diff --git a/vendor/k8s.io/apimachinery/pkg/conversion/queryparams/BUILD b/vendor/k8s.io/apimachinery/pkg/conversion/queryparams/BUILD new file mode 100644 index 0000000000..8eeabc5f11 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/conversion/queryparams/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "convert.go", + "doc.go", + ], + tags = ["automanaged"], +) + +go_test( + name = "go_default_xtest", + srcs = ["convert_test.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion/queryparams:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/conversion/queryparams/convert.go b/vendor/k8s.io/apimachinery/pkg/conversion/queryparams/convert.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/conversion/queryparams/convert.go rename to vendor/k8s.io/apimachinery/pkg/conversion/queryparams/convert.go diff --git a/vendor/k8s.io/client-go/pkg/conversion/queryparams/doc.go b/vendor/k8s.io/apimachinery/pkg/conversion/queryparams/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/conversion/queryparams/doc.go rename to vendor/k8s.io/apimachinery/pkg/conversion/queryparams/doc.go diff --git a/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/BUILD b/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/BUILD new file mode 100644 index 0000000000..0804afc330 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/BUILD @@ -0,0 +1,38 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["converter_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/json:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "converter.go", + "doc.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/equality:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/json:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + ], +) diff --git a/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/converter.go b/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/converter.go new file mode 100644 index 0000000000..cf84a61989 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/converter.go @@ -0,0 +1,690 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package unstructured + +import ( + "bytes" + encodingjson "encoding/json" + "fmt" + "math" + "os" + "reflect" + "strconv" + "strings" + "sync" + "sync/atomic" + + apiequality "k8s.io/apimachinery/pkg/api/equality" + "k8s.io/apimachinery/pkg/util/diff" + "k8s.io/apimachinery/pkg/util/json" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + + "github.com/golang/glog" +) + +// Converter is an interface for converting between interface{} +// and map[string]interface representation. +type Converter interface { + ToUnstructured(obj interface{}, u *map[string]interface{}) error + FromUnstructured(u map[string]interface{}, obj interface{}) error +} + +type structField struct { + structType reflect.Type + field int +} + +type fieldInfo struct { + name string + nameValue reflect.Value + omitempty bool +} + +type fieldsCacheMap map[structField]*fieldInfo + +type fieldsCache struct { + sync.Mutex + value atomic.Value +} + +func newFieldsCache() *fieldsCache { + cache := &fieldsCache{} + cache.value.Store(make(fieldsCacheMap)) + return cache +} + +var ( + marshalerType = reflect.TypeOf(new(encodingjson.Marshaler)).Elem() + unmarshalerType = reflect.TypeOf(new(encodingjson.Unmarshaler)).Elem() + mapStringInterfaceType = reflect.TypeOf(map[string]interface{}{}) + stringType = reflect.TypeOf(string("")) + int64Type = reflect.TypeOf(int64(0)) + uint64Type = reflect.TypeOf(uint64(0)) + float64Type = reflect.TypeOf(float64(0)) + boolType = reflect.TypeOf(bool(false)) + fieldCache = newFieldsCache() + DefaultConverter = NewConverter(parseBool(os.Getenv("KUBE_PATCH_CONVERSION_DETECTOR"))) +) + +func parseBool(key string) bool { + if len(key) == 0 { + return false + } + value, err := strconv.ParseBool(key) + if err != nil { + utilruntime.HandleError(fmt.Errorf("Couldn't parse '%s' as bool for unstructured mismatch detection", key)) + } + return value +} + +// ConverterImpl knows how to convert between interface{} and +// Unstructured in both ways. +type converterImpl struct { + // If true, we will be additionally running conversion via json + // to ensure that the result is true. + // This is supposed to be set only in tests. + mismatchDetection bool +} + +func NewConverter(mismatchDetection bool) Converter { + return &converterImpl{ + mismatchDetection: mismatchDetection, + } +} + +func (c *converterImpl) FromUnstructured(u map[string]interface{}, obj interface{}) error { + t := reflect.TypeOf(obj) + value := reflect.ValueOf(obj) + if t.Kind() != reflect.Ptr || value.IsNil() { + return fmt.Errorf("FromUnstructured requires a non-nil pointer to an object, got %v", t) + } + err := fromUnstructured(reflect.ValueOf(u), value.Elem()) + if c.mismatchDetection { + newObj := reflect.New(t.Elem()).Interface() + newErr := fromUnstructuredViaJSON(u, newObj) + if (err != nil) != (newErr != nil) { + glog.Fatalf("FromUnstructured unexpected error for %v: error: %v", u, err) + } + if err == nil && !apiequality.Semantic.DeepEqual(obj, newObj) { + glog.Fatalf("FromUnstructured mismatch for %#v, diff: %v", obj, diff.ObjectReflectDiff(obj, newObj)) + } + } + return err +} + +func fromUnstructuredViaJSON(u map[string]interface{}, obj interface{}) error { + data, err := json.Marshal(u) + if err != nil { + return err + } + return json.Unmarshal(data, obj) +} + +func fromUnstructured(sv, dv reflect.Value) error { + sv = unwrapInterface(sv) + if !sv.IsValid() { + dv.Set(reflect.Zero(dv.Type())) + return nil + } + st, dt := sv.Type(), dv.Type() + + switch dt.Kind() { + case reflect.Map, reflect.Slice, reflect.Ptr, reflect.Struct, reflect.Interface: + // Those require non-trivial conversion. + default: + // This should handle all simple types. + if st.AssignableTo(dt) { + dv.Set(sv) + return nil + } + // We cannot simply use "ConvertibleTo", as JSON doesn't support conversions + // between those four groups: bools, integers, floats and string. We need to + // do the same. + if st.ConvertibleTo(dt) { + switch st.Kind() { + case reflect.String: + switch dt.Kind() { + case reflect.String: + dv.Set(sv.Convert(dt)) + return nil + } + case reflect.Bool: + switch dt.Kind() { + case reflect.Bool: + dv.Set(sv.Convert(dt)) + return nil + } + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64, + reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + switch dt.Kind() { + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64, + reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + dv.Set(sv.Convert(dt)) + return nil + } + case reflect.Float32, reflect.Float64: + switch dt.Kind() { + case reflect.Float32, reflect.Float64: + dv.Set(sv.Convert(dt)) + return nil + } + if sv.Float() == math.Trunc(sv.Float()) { + dv.Set(sv.Convert(dt)) + return nil + } + } + return fmt.Errorf("cannot convert %s to %s", st.String(), dt.String()) + } + } + + // Check if the object has a custom JSON marshaller/unmarshaller. + if reflect.PtrTo(dt).Implements(unmarshalerType) { + data, err := json.Marshal(sv.Interface()) + if err != nil { + return fmt.Errorf("error encoding %s to json: %v", st.String(), err) + } + unmarshaler := dv.Addr().Interface().(encodingjson.Unmarshaler) + return unmarshaler.UnmarshalJSON(data) + } + + switch dt.Kind() { + case reflect.Map: + return mapFromUnstructured(sv, dv) + case reflect.Slice: + return sliceFromUnstructured(sv, dv) + case reflect.Ptr: + return pointerFromUnstructured(sv, dv) + case reflect.Struct: + return structFromUnstructured(sv, dv) + case reflect.Interface: + return interfaceFromUnstructured(sv, dv) + default: + return fmt.Errorf("unrecognized type: %v", dt.Kind()) + } +} + +func fieldInfoFromField(structType reflect.Type, field int) *fieldInfo { + fieldCacheMap := fieldCache.value.Load().(fieldsCacheMap) + if info, ok := fieldCacheMap[structField{structType, field}]; ok { + return info + } + + // Cache miss - we need to compute the field name. + info := &fieldInfo{} + typeField := structType.Field(field) + jsonTag := typeField.Tag.Get("json") + if len(jsonTag) == 0 { + // Make the first character lowercase. + if typeField.Name == "" { + info.name = typeField.Name + } else { + info.name = strings.ToLower(typeField.Name[:1]) + typeField.Name[1:] + } + } else { + items := strings.Split(jsonTag, ",") + info.name = items[0] + for i := range items { + if items[i] == "omitempty" { + info.omitempty = true + } + } + } + info.nameValue = reflect.ValueOf(info.name) + + fieldCache.Lock() + defer fieldCache.Unlock() + fieldCacheMap = fieldCache.value.Load().(fieldsCacheMap) + newFieldCacheMap := make(fieldsCacheMap) + for k, v := range fieldCacheMap { + newFieldCacheMap[k] = v + } + newFieldCacheMap[structField{structType, field}] = info + fieldCache.value.Store(newFieldCacheMap) + return info +} + +func unwrapInterface(v reflect.Value) reflect.Value { + for v.Kind() == reflect.Interface { + v = v.Elem() + } + return v +} + +func mapFromUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + if st.Kind() != reflect.Map { + return fmt.Errorf("cannot restore map from %v", st.Kind()) + } + + if !st.Key().AssignableTo(dt.Key()) && !st.Key().ConvertibleTo(dt.Key()) { + return fmt.Errorf("cannot copy map with non-assignable keys: %v %v", st.Key(), dt.Key()) + } + + if sv.IsNil() { + dv.Set(reflect.Zero(dt)) + return nil + } + dv.Set(reflect.MakeMap(dt)) + for _, key := range sv.MapKeys() { + value := reflect.New(dt.Elem()).Elem() + if val := unwrapInterface(sv.MapIndex(key)); val.IsValid() { + if err := fromUnstructured(val, value); err != nil { + return err + } + } else { + value.Set(reflect.Zero(dt.Elem())) + } + if st.Key().AssignableTo(dt.Key()) { + dv.SetMapIndex(key, value) + } else { + dv.SetMapIndex(key.Convert(dt.Key()), value) + } + } + return nil +} + +func sliceFromUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + if st.Kind() == reflect.String && dt.Elem().Kind() == reflect.Uint8 { + // We store original []byte representation as string. + // This conversion is allowed, but we need to be careful about + // marshaling data appropriately. + if len(sv.Interface().(string)) > 0 { + marshalled, err := json.Marshal(sv.Interface()) + if err != nil { + return fmt.Errorf("error encoding %s to json: %v", st, err) + } + // TODO: Is this Unmarshal needed? + var data []byte + err = json.Unmarshal(marshalled, &data) + if err != nil { + return fmt.Errorf("error decoding from json: %v", err) + } + dv.SetBytes(data) + } else { + dv.Set(reflect.Zero(dt)) + } + return nil + } + if st.Kind() != reflect.Slice { + return fmt.Errorf("cannot restore slice from %v", st.Kind()) + } + + if sv.IsNil() { + dv.Set(reflect.Zero(dt)) + return nil + } + dv.Set(reflect.MakeSlice(dt, sv.Len(), sv.Cap())) + for i := 0; i < sv.Len(); i++ { + if err := fromUnstructured(sv.Index(i), dv.Index(i)); err != nil { + return err + } + } + return nil +} + +func pointerFromUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + + if st.Kind() == reflect.Ptr && sv.IsNil() { + dv.Set(reflect.Zero(dt)) + return nil + } + dv.Set(reflect.New(dt.Elem())) + switch st.Kind() { + case reflect.Ptr, reflect.Interface: + return fromUnstructured(sv.Elem(), dv.Elem()) + default: + return fromUnstructured(sv, dv.Elem()) + } +} + +func structFromUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + if st.Kind() != reflect.Map { + return fmt.Errorf("cannot restore struct from: %v", st.Kind()) + } + + for i := 0; i < dt.NumField(); i++ { + fieldInfo := fieldInfoFromField(dt, i) + fv := dv.Field(i) + + if len(fieldInfo.name) == 0 { + // This field is inlined. + if err := fromUnstructured(sv, fv); err != nil { + return err + } + } else { + value := unwrapInterface(sv.MapIndex(fieldInfo.nameValue)) + if value.IsValid() { + if err := fromUnstructured(value, fv); err != nil { + return err + } + } else { + fv.Set(reflect.Zero(fv.Type())) + } + } + } + return nil +} + +func interfaceFromUnstructured(sv, dv reflect.Value) error { + // TODO: Is this conversion safe? + dv.Set(sv) + return nil +} + +func (c *converterImpl) ToUnstructured(obj interface{}, u *map[string]interface{}) error { + t := reflect.TypeOf(obj) + value := reflect.ValueOf(obj) + if t.Kind() != reflect.Ptr || value.IsNil() { + return fmt.Errorf("ToUnstructured requires a non-nil pointer to an object, got %v", t) + } + err := toUnstructured(value.Elem(), reflect.ValueOf(u).Elem()) + if c.mismatchDetection { + newUnstr := &map[string]interface{}{} + newErr := toUnstructuredViaJSON(obj, newUnstr) + if (err != nil) != (newErr != nil) { + glog.Fatalf("ToUnstructured unexpected error for %v: error: %v", obj, err) + } + if err == nil && !apiequality.Semantic.DeepEqual(u, newUnstr) { + glog.Fatalf("ToUnstructured mismatch for %#v, diff: %v", u, diff.ObjectReflectDiff(u, newUnstr)) + } + } + return err +} + +func toUnstructuredViaJSON(obj interface{}, u *map[string]interface{}) error { + data, err := json.Marshal(obj) + if err != nil { + return err + } + return json.Unmarshal(data, u) +} + +func toUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + + // Check if the object has a custom JSON marshaller/unmarshaller. + if st.Implements(marshalerType) { + if sv.Kind() == reflect.Ptr && sv.IsNil() { + // We're done - we don't need to store anything. + return nil + } + + marshaler := sv.Interface().(encodingjson.Marshaler) + data, err := marshaler.MarshalJSON() + if err != nil { + return err + } + if bytes.Equal(data, []byte("null")) { + // We're done - we don't need to store anything. + } else { + switch { + case len(data) > 0 && data[0] == '"': + var result string + err := json.Unmarshal(data, &result) + if err != nil { + return fmt.Errorf("error decoding from json: %v", err) + } + dv.Set(reflect.ValueOf(result)) + case len(data) > 0 && data[0] == '{': + result := make(map[string]interface{}) + err := json.Unmarshal(data, &result) + if err != nil { + return fmt.Errorf("error decoding from json: %v", err) + } + dv.Set(reflect.ValueOf(result)) + default: + var result int64 + err := json.Unmarshal(data, &result) + if err != nil { + return fmt.Errorf("error decoding from json: %v", err) + } + dv.Set(reflect.ValueOf(result)) + } + } + return nil + } + + switch st.Kind() { + case reflect.String: + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + dv.Set(reflect.New(stringType)) + } + dv.Set(reflect.ValueOf(sv.String())) + return nil + case reflect.Bool: + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + dv.Set(reflect.New(boolType)) + } + dv.Set(reflect.ValueOf(sv.Bool())) + return nil + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + dv.Set(reflect.New(int64Type)) + } + dv.Set(reflect.ValueOf(sv.Int())) + return nil + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + dv.Set(reflect.New(uint64Type)) + } + dv.Set(reflect.ValueOf(sv.Uint())) + return nil + case reflect.Float32, reflect.Float64: + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + dv.Set(reflect.New(float64Type)) + } + dv.Set(reflect.ValueOf(sv.Float())) + return nil + case reflect.Map: + return mapToUnstructured(sv, dv) + case reflect.Slice: + return sliceToUnstructured(sv, dv) + case reflect.Ptr: + return pointerToUnstructured(sv, dv) + case reflect.Struct: + return structToUnstructured(sv, dv) + case reflect.Interface: + return interfaceToUnstructured(sv, dv) + default: + return fmt.Errorf("unrecognized type: %v", st.Kind()) + } +} + +func mapToUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + if sv.IsNil() { + dv.Set(reflect.Zero(dt)) + return nil + } + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + if st.Key().Kind() == reflect.String { + switch st.Elem().Kind() { + // TODO It should be possible to reuse the slice for primitive types. + // However, it is panicing in the following form. + // case reflect.String, reflect.Bool, + // reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64, + // reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + // sv.Set(sv) + // return nil + default: + // We need to do a proper conversion. + } + } + dv.Set(reflect.MakeMap(mapStringInterfaceType)) + dv = dv.Elem() + dt = dv.Type() + } + if dt.Kind() != reflect.Map { + return fmt.Errorf("cannot convert struct to: %v", dt.Kind()) + } + + if !st.Key().AssignableTo(dt.Key()) && !st.Key().ConvertibleTo(dt.Key()) { + return fmt.Errorf("cannot copy map with non-assignable keys: %v %v", st.Key(), dt.Key()) + } + + for _, key := range sv.MapKeys() { + value := reflect.New(dt.Elem()).Elem() + if err := toUnstructured(sv.MapIndex(key), value); err != nil { + return err + } + if st.Key().AssignableTo(dt.Key()) { + dv.SetMapIndex(key, value) + } else { + dv.SetMapIndex(key.Convert(dt.Key()), value) + } + } + return nil +} + +func sliceToUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + if sv.IsNil() { + dv.Set(reflect.Zero(dt)) + return nil + } + if st.Elem().Kind() == reflect.Uint8 { + dv.Set(reflect.New(stringType)) + data, err := json.Marshal(sv.Bytes()) + if err != nil { + return err + } + var result string + if err = json.Unmarshal(data, &result); err != nil { + return err + } + dv.Set(reflect.ValueOf(result)) + return nil + } + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + switch st.Elem().Kind() { + // TODO It should be possible to reuse the slice for primitive types. + // However, it is panicing in the following form. + // case reflect.String, reflect.Bool, + // reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64, + // reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + // sv.Set(sv) + // return nil + default: + // We need to do a proper conversion. + dv.Set(reflect.MakeSlice(reflect.SliceOf(dt), sv.Len(), sv.Cap())) + dv = dv.Elem() + dt = dv.Type() + } + } + if dt.Kind() != reflect.Slice { + return fmt.Errorf("cannot convert slice to: %v", dt.Kind()) + } + for i := 0; i < sv.Len(); i++ { + if err := toUnstructured(sv.Index(i), dv.Index(i)); err != nil { + return err + } + } + return nil +} + +func pointerToUnstructured(sv, dv reflect.Value) error { + if sv.IsNil() { + // We're done - we don't need to store anything. + return nil + } + return toUnstructured(sv.Elem(), dv) +} + +func isZero(v reflect.Value) bool { + switch v.Kind() { + case reflect.Array, reflect.String: + return v.Len() == 0 + case reflect.Bool: + return !v.Bool() + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + return v.Int() == 0 + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + return v.Uint() == 0 + case reflect.Float32, reflect.Float64: + return v.Float() == 0 + case reflect.Map, reflect.Slice: + // TODO: It seems that 0-len maps are ignored in it. + return v.IsNil() || v.Len() == 0 + case reflect.Ptr, reflect.Interface: + return v.IsNil() + } + return false +} + +func structToUnstructured(sv, dv reflect.Value) error { + st, dt := sv.Type(), dv.Type() + if dt.Kind() == reflect.Interface && dv.NumMethod() == 0 { + dv.Set(reflect.MakeMap(mapStringInterfaceType)) + dv = dv.Elem() + dt = dv.Type() + } + if dt.Kind() != reflect.Map { + return fmt.Errorf("cannot convert struct to: %v", dt.Kind()) + } + realMap := dv.Interface().(map[string]interface{}) + + for i := 0; i < st.NumField(); i++ { + fieldInfo := fieldInfoFromField(st, i) + fv := sv.Field(i) + + if fieldInfo.name == "-" { + // This field should be skipped. + continue + } + if fieldInfo.omitempty && isZero(fv) { + // omitempty fields should be ignored. + continue + } + if len(fieldInfo.name) == 0 { + // This field is inlined. + if err := toUnstructured(fv, dv); err != nil { + return err + } + continue + } + switch fv.Type().Kind() { + case reflect.String: + realMap[fieldInfo.name] = fv.String() + case reflect.Bool: + realMap[fieldInfo.name] = fv.Bool() + case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: + realMap[fieldInfo.name] = fv.Int() + case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64: + realMap[fieldInfo.name] = fv.Uint() + case reflect.Float32, reflect.Float64: + realMap[fieldInfo.name] = fv.Float() + default: + subv := reflect.New(dt.Elem()).Elem() + if err := toUnstructured(fv, subv); err != nil { + return err + } + dv.SetMapIndex(fieldInfo.nameValue, subv) + } + } + return nil +} + +func interfaceToUnstructured(sv, dv reflect.Value) error { + if !sv.IsValid() || sv.IsNil() { + dv.Set(reflect.Zero(dv.Type())) + return nil + } + return toUnstructured(sv.Elem(), dv) +} diff --git a/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/doc.go b/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/doc.go new file mode 100644 index 0000000000..75128804e9 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/conversion/unstructured/doc.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Package unstructured provides conversion from runtime objects +// to map[string]interface{} representation. +package unstructured diff --git a/vendor/k8s.io/apimachinery/pkg/fields/BUILD b/vendor/k8s.io/apimachinery/pkg/fields/BUILD new file mode 100644 index 0000000000..7c44f5fd82 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/fields/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "fields_test.go", + "selector_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "fields.go", + "requirements.go", + "selector.go", + ], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/selection:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/pkg/fields/doc.go b/vendor/k8s.io/apimachinery/pkg/fields/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/fields/doc.go rename to vendor/k8s.io/apimachinery/pkg/fields/doc.go diff --git a/vendor/k8s.io/client-go/pkg/fields/fields.go b/vendor/k8s.io/apimachinery/pkg/fields/fields.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/fields/fields.go rename to vendor/k8s.io/apimachinery/pkg/fields/fields.go diff --git a/vendor/k8s.io/client-go/pkg/fields/requirements.go b/vendor/k8s.io/apimachinery/pkg/fields/requirements.go similarity index 95% rename from vendor/k8s.io/client-go/pkg/fields/requirements.go rename to vendor/k8s.io/apimachinery/pkg/fields/requirements.go index fdf81c1239..70d94ded88 100644 --- a/vendor/k8s.io/client-go/pkg/fields/requirements.go +++ b/vendor/k8s.io/apimachinery/pkg/fields/requirements.go @@ -16,7 +16,7 @@ limitations under the License. package fields -import "k8s.io/client-go/pkg/selection" +import "k8s.io/apimachinery/pkg/selection" // Requirements is AND of all requirements. type Requirements []Requirement diff --git a/vendor/k8s.io/client-go/pkg/fields/selector.go b/vendor/k8s.io/apimachinery/pkg/fields/selector.go similarity index 53% rename from vendor/k8s.io/client-go/pkg/fields/selector.go rename to vendor/k8s.io/apimachinery/pkg/fields/selector.go index 836e8ba72d..1305dde086 100644 --- a/vendor/k8s.io/client-go/pkg/fields/selector.go +++ b/vendor/k8s.io/apimachinery/pkg/fields/selector.go @@ -17,11 +17,12 @@ limitations under the License. package fields import ( + "bytes" "fmt" "sort" "strings" - "k8s.io/client-go/pkg/selection" + "k8s.io/apimachinery/pkg/selection" ) // Selector represents a field selector. @@ -39,6 +40,8 @@ type Selector interface { // Transform returns a new copy of the selector after TransformFunc has been // applied to the entire selector, or an error if fn returns an error. + // If for a given requirement both field and value are transformed to empty + // string, the requirement is skipped. Transform(fn TransformFunc) (Selector, error) // Requirements converts this interface to Requirements to expose @@ -78,6 +81,9 @@ func (t *hasTerm) Transform(fn TransformFunc) (Selector, error) { if err != nil { return nil, err } + if len(field) == 0 && len(value) == 0 { + return Everything(), nil + } return &hasTerm{field, value}, nil } @@ -90,7 +96,7 @@ func (t *hasTerm) Requirements() Requirements { } func (t *hasTerm) String() string { - return fmt.Sprintf("%v=%v", t.field, t.value) + return fmt.Sprintf("%v=%v", t.field, EscapeValue(t.value)) } type notHasTerm struct { @@ -114,6 +120,9 @@ func (t *notHasTerm) Transform(fn TransformFunc) (Selector, error) { if err != nil { return nil, err } + if len(field) == 0 && len(value) == 0 { + return Everything(), nil + } return ¬HasTerm{field, value}, nil } @@ -126,7 +135,7 @@ func (t *notHasTerm) Requirements() Requirements { } func (t *notHasTerm) String() string { - return fmt.Sprintf("%v!=%v", t.field, t.value) + return fmt.Sprintf("%v!=%v", t.field, EscapeValue(t.value)) } type andTerm []Selector @@ -168,13 +177,15 @@ func (t andTerm) RequiresExactMatch(field string) (string, bool) { } func (t andTerm) Transform(fn TransformFunc) (Selector, error) { - next := make([]Selector, len([]Selector(t))) - for i, s := range []Selector(t) { + next := make([]Selector, 0, len([]Selector(t))) + for _, s := range []Selector(t) { n, err := s.Transform(fn) if err != nil { return nil, err } - next[i] = n + if !n.Empty() { + next = append(next, n) + } } return andTerm(next), nil } @@ -212,6 +223,81 @@ func SelectorFromSet(ls Set) Selector { return andTerm(items) } +// valueEscaper prefixes \,= characters with a backslash +var valueEscaper = strings.NewReplacer( + // escape \ characters + `\`, `\\`, + // then escape , and = characters to allow unambiguous parsing of the value in a fieldSelector + `,`, `\,`, + `=`, `\=`, +) + +// EscapeValue escapes an arbitrary literal string for use as a fieldSelector value +func EscapeValue(s string) string { + return valueEscaper.Replace(s) +} + +// InvalidEscapeSequence indicates an error occurred unescaping a field selector +type InvalidEscapeSequence struct { + sequence string +} + +func (i InvalidEscapeSequence) Error() string { + return fmt.Sprintf("invalid field selector: invalid escape sequence: %s", i.sequence) +} + +// UnescapedRune indicates an error occurred unescaping a field selector +type UnescapedRune struct { + r rune +} + +func (i UnescapedRune) Error() string { + return fmt.Sprintf("invalid field selector: unescaped character in value: %v", i.r) +} + +// UnescapeValue unescapes a fieldSelector value and returns the original literal value. +// May return the original string if it contains no escaped or special characters. +func UnescapeValue(s string) (string, error) { + // if there's no escaping or special characters, just return to avoid allocation + if !strings.ContainsAny(s, `\,=`) { + return s, nil + } + + v := bytes.NewBuffer(make([]byte, 0, len(s))) + inSlash := false + for _, c := range s { + if inSlash { + switch c { + case '\\', ',', '=': + // omit the \ for recognized escape sequences + v.WriteRune(c) + default: + // error on unrecognized escape sequences + return "", InvalidEscapeSequence{sequence: string([]rune{'\\', c})} + } + inSlash = false + continue + } + + switch c { + case '\\': + inSlash = true + case ',', '=': + // unescaped , and = characters are not allowed in field selector values + return "", UnescapedRune{r: c} + default: + v.WriteRune(c) + } + } + + // Ending with a single backslash is an invalid sequence + if inSlash { + return "", InvalidEscapeSequence{sequence: "\\"} + } + + return v.String(), nil +} + // ParseSelectorOrDie takes a string representing a selector and returns an // object suitable for matching, or panic when an error occur. func ParseSelectorOrDie(s string) Selector { @@ -231,37 +317,91 @@ func ParseSelector(selector string) (Selector, error) { }) } -// Parses the selector and runs them through the given TransformFunc. +// ParseAndTransformSelector parses the selector and runs them through the given TransformFunc. func ParseAndTransformSelector(selector string, fn TransformFunc) (Selector, error) { return parseSelector(selector, fn) } -// Function to transform selectors. +// TransformFunc transforms selectors. type TransformFunc func(field, value string) (newField, newValue string, err error) -func try(selectorPiece, op string) (lhs, rhs string, ok bool) { - pieces := strings.Split(selectorPiece, op) - if len(pieces) == 2 { - return pieces[0], pieces[1], true +// splitTerms returns the comma-separated terms contained in the given fieldSelector. +// Backslash-escaped commas are treated as data instead of delimiters, and are included in the returned terms, with the leading backslash preserved. +func splitTerms(fieldSelector string) []string { + if len(fieldSelector) == 0 { + return nil + } + + terms := make([]string, 0, 1) + startIndex := 0 + inSlash := false + for i, c := range fieldSelector { + switch { + case inSlash: + inSlash = false + case c == '\\': + inSlash = true + case c == ',': + terms = append(terms, fieldSelector[startIndex:i]) + startIndex = i + 1 + } } - return "", "", false + + terms = append(terms, fieldSelector[startIndex:]) + + return terms +} + +const ( + notEqualOperator = "!=" + doubleEqualOperator = "==" + equalOperator = "=" +) + +// termOperators holds the recognized operators supported in fieldSelectors. +// doubleEqualOperator and equal are equivalent, but doubleEqualOperator is checked first +// to avoid leaving a leading = character on the rhs value. +var termOperators = []string{notEqualOperator, doubleEqualOperator, equalOperator} + +// splitTerm returns the lhs, operator, and rhs parsed from the given term, along with an indicator of whether the parse was successful. +// no escaping of special characters is supported in the lhs value, so the first occurance of a recognized operator is used as the split point. +// the literal rhs is returned, and the caller is responsible for applying any desired unescaping. +func splitTerm(term string) (lhs, op, rhs string, ok bool) { + for i := range term { + remaining := term[i:] + for _, op := range termOperators { + if strings.HasPrefix(remaining, op) { + return term[0:i], op, term[i+len(op):], true + } + } + } + return "", "", "", false } func parseSelector(selector string, fn TransformFunc) (Selector, error) { - parts := strings.Split(selector, ",") + parts := splitTerms(selector) sort.StringSlice(parts).Sort() var items []Selector for _, part := range parts { if part == "" { continue } - if lhs, rhs, ok := try(part, "!="); ok { - items = append(items, ¬HasTerm{field: lhs, value: rhs}) - } else if lhs, rhs, ok := try(part, "=="); ok { - items = append(items, &hasTerm{field: lhs, value: rhs}) - } else if lhs, rhs, ok := try(part, "="); ok { - items = append(items, &hasTerm{field: lhs, value: rhs}) - } else { + lhs, op, rhs, ok := splitTerm(part) + if !ok { + return nil, fmt.Errorf("invalid selector: '%s'; can't understand '%s'", selector, part) + } + unescapedRHS, err := UnescapeValue(rhs) + if err != nil { + return nil, err + } + switch op { + case notEqualOperator: + items = append(items, ¬HasTerm{field: lhs, value: unescapedRHS}) + case doubleEqualOperator: + items = append(items, &hasTerm{field: lhs, value: unescapedRHS}) + case equalOperator: + items = append(items, &hasTerm{field: lhs, value: unescapedRHS}) + default: return nil, fmt.Errorf("invalid selector: '%s'; can't understand '%s'", selector, part) } } @@ -276,3 +416,8 @@ func parseSelector(selector string, fn TransformFunc) (Selector, error) { func OneTermEqualSelector(k, v string) Selector { return &hasTerm{field: k, value: v} } + +// AndSelectors creates a selector that is the logical AND of all the given selectors +func AndSelectors(selectors ...Selector) Selector { + return andTerm(selectors) +} diff --git a/vendor/k8s.io/apimachinery/pkg/labels/BUILD b/vendor/k8s.io/apimachinery/pkg/labels/BUILD new file mode 100644 index 0000000000..5e4d9143b3 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/labels/BUILD @@ -0,0 +1,39 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "labels_test.go", + "selector_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/selection:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "labels.go", + "selector.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/selection:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/labels/doc.go b/vendor/k8s.io/apimachinery/pkg/labels/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/labels/doc.go rename to vendor/k8s.io/apimachinery/pkg/labels/doc.go diff --git a/vendor/k8s.io/client-go/pkg/labels/labels.go b/vendor/k8s.io/apimachinery/pkg/labels/labels.go similarity index 97% rename from vendor/k8s.io/client-go/pkg/labels/labels.go rename to vendor/k8s.io/apimachinery/pkg/labels/labels.go index 0d0caa77dc..32db4d96f6 100644 --- a/vendor/k8s.io/client-go/pkg/labels/labels.go +++ b/vendor/k8s.io/apimachinery/pkg/labels/labels.go @@ -66,12 +66,12 @@ func (ls Set) AsSelector() Selector { // assumes that labels are already validated and thus don't // preform any validation. // According to our measurements this is significantly faster -// in codepaths that matter at high sccale. +// in codepaths that matter at high scale. func (ls Set) AsSelectorPreValidated() Selector { return SelectorFromValidatedSet(ls) } -// FormatLables convert label map into plain string +// FormatLabels convert label map into plain string func FormatLabels(labelMap map[string]string) string { l := Set(labelMap).String() if l == "" { diff --git a/vendor/k8s.io/client-go/pkg/labels/selector.go b/vendor/k8s.io/apimachinery/pkg/labels/selector.go similarity index 91% rename from vendor/k8s.io/client-go/pkg/labels/selector.go rename to vendor/k8s.io/apimachinery/pkg/labels/selector.go index d14f6f90bc..50b41f99d2 100644 --- a/vendor/k8s.io/client-go/pkg/labels/selector.go +++ b/vendor/k8s.io/apimachinery/pkg/labels/selector.go @@ -24,9 +24,9 @@ import ( "strings" "github.com/golang/glog" - "k8s.io/client-go/pkg/selection" - "k8s.io/client-go/pkg/util/sets" - "k8s.io/client-go/pkg/util/validation" + "k8s.io/apimachinery/pkg/selection" + "k8s.io/apimachinery/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/validation" ) // Requirements is AND of all requirements. @@ -62,7 +62,7 @@ type nothingSelector struct{} func (n nothingSelector) Matches(_ Labels) bool { return false } func (n nothingSelector) Empty() bool { return false } -func (n nothingSelector) String() string { return "" } +func (n nothingSelector) String() string { return "" } func (n nothingSelector) Add(_ ...Requirement) Selector { return n } func (n nothingSelector) Requirements() (Requirements, bool) { return nil, false } @@ -71,13 +71,14 @@ func Nothing() Selector { return nothingSelector{} } +// NewSelector returns a nil selector func NewSelector() Selector { return internalSelector(nil) } type internalSelector []Requirement -// Sort by key to obtain determisitic parser +// ByKey sorts requirements by key to obtain deterministic parser type ByKey []Requirement func (a ByKey) Len() int { return len(a) } @@ -215,12 +216,17 @@ func (r *Requirement) Matches(ls Labels) bool { } } +// Key returns requirement key func (r *Requirement) Key() string { return r.key } + +// Operator returns requirement operator func (r *Requirement) Operator() selection.Operator { return r.operator } + +// Values returns requirement values func (r *Requirement) Values() sets.String { ret := sets.String{} for i := range r.strValues { @@ -229,7 +235,7 @@ func (r *Requirement) Values() sets.String { return ret } -// Return true if the internalSelector doesn't restrict selection space +// Empty returns true if the internalSelector doesn't restrict selection space func (lsel internalSelector) Empty() bool { if lsel == nil { return true @@ -320,23 +326,37 @@ func (lsel internalSelector) String() string { return strings.Join(reqs, ",") } -// constants definition for lexer token +// Token represents constant definition for lexer token type Token int const ( + // ErrorToken represents scan error ErrorToken Token = iota + // EndOfStringToken represents end of string EndOfStringToken + // ClosedParToken represents close parenthesis ClosedParToken + // CommaToken represents the comma CommaToken + // DoesNotExistToken represents logic not DoesNotExistToken + // DoubleEqualsToken represents double equals DoubleEqualsToken + // EqualsToken represents equal EqualsToken + // GreaterThanToken represents greater than GreaterThanToken - IdentifierToken // to represent keys and values + // IdentifierToken represents identifier, e.g. keys and values + IdentifierToken + // InToken represents in InToken + // LessThanToken represents less than LessThanToken + // NotEqualsToken represents not equal NotEqualsToken + // NotInToken represents not in NotInToken + // OpenParToken represents open parenthesis OpenParToken ) @@ -356,7 +376,7 @@ var string2token = map[string]Token{ "(": OpenParToken, } -// The item produced by the lexer. It contains the Token and the literal. +// ScannedItem contains the Token and the literal produced by the lexer. type ScannedItem struct { tok Token literal string @@ -401,8 +421,8 @@ func (l *Lexer) unread() { l.pos-- } -// scanIdOrKeyword scans string to recognize literal token (for example 'in') or an identifier. -func (l *Lexer) scanIdOrKeyword() (tok Token, lit string) { +// scanIDOrKeyword scans string to recognize literal token (for example 'in') or an identifier. +func (l *Lexer) scanIDOrKeyword() (tok Token, lit string) { var buffer []byte IdentifierLoop: for { @@ -474,7 +494,7 @@ func (l *Lexer) Lex() (tok Token, lit string) { return l.scanSpecialSymbol() default: l.unread() - return l.scanIdOrKeyword() + return l.scanIDOrKeyword() } } @@ -485,14 +505,16 @@ type Parser struct { position int } -// Parser context represents context during parsing: +// ParserContext represents context during parsing: // some literal for example 'in' and 'notin' can be // recognized as operator for example 'x in (a)' but // it can be recognized as value for example 'value in (in)' type ParserContext int const ( + // KeyAndOperator represents key and operator KeyAndOperator ParserContext = iota + // Values represents values Values ) @@ -728,15 +750,16 @@ func (p *Parser) parseExactValue() (sets.String, error) { // as they parse different selectors with different syntaxes. // The input will cause an error if it does not follow this form: // -// ::= | "," ] -// ::= [!] KEY [ | ] -// ::= "" | -// ::= | -// ::= "notin" -// ::= "in" -// ::= "(" ")" -// ::= VALUE | VALUE "," -// ::= ["="|"=="|"!="] VALUE +// ::= | "," +// ::= [!] KEY [ | ] +// ::= "" | +// ::= | +// ::= "notin" +// ::= "in" +// ::= "(" ")" +// ::= VALUE | VALUE "," +// ::= ["="|"=="|"!="] VALUE +// // KEY is a sequence of one or more characters following [ DNS_SUBDOMAIN "/" ] DNS_LABEL. Max length is 63 characters. // VALUE is a sequence of zero or more characters "([A-Za-z0-9_-\.])". Max length is 63 characters. // Delimiter is white space: (' ', '\t') @@ -792,28 +815,29 @@ func validateLabelValue(v string) error { // SelectorFromSet returns a Selector which will match exactly the given Set. A // nil and empty Sets are considered equivalent to Everything(). func SelectorFromSet(ls Set) Selector { - if ls == nil { + if ls == nil || len(ls) == 0 { return internalSelector{} } var requirements internalSelector for label, value := range ls { - if r, err := NewRequirement(label, selection.Equals, []string{value}); err != nil { + r, err := NewRequirement(label, selection.Equals, []string{value}) + if err == nil { + requirements = append(requirements, *r) + } else { //TODO: double check errors when input comes from serialization? return internalSelector{} - } else { - requirements = append(requirements, *r) } } // sort to have deterministic string representation sort.Sort(ByKey(requirements)) - return internalSelector(requirements) + return requirements } // SelectorFromValidatedSet returns a Selector which will match exactly the given Set. // A nil and empty Sets are considered equivalent to Everything(). // It assumes that Set is already validated and doesn't do any validation. func SelectorFromValidatedSet(ls Set) Selector { - if ls == nil { + if ls == nil || len(ls) == 0 { return internalSelector{} } var requirements internalSelector @@ -822,7 +846,7 @@ func SelectorFromValidatedSet(ls Set) Selector { } // sort to have deterministic string representation sort.Sort(ByKey(requirements)) - return internalSelector(requirements) + return requirements } // ParseToRequirements takes a string representing a selector and returns a list of diff --git a/vendor/k8s.io/apimachinery/pkg/openapi/BUILD b/vendor/k8s.io/apimachinery/pkg/openapi/BUILD new file mode 100644 index 0000000000..4b3dfd4a0c --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/openapi/BUILD @@ -0,0 +1,21 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "common.go", + "doc.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/emicklei/go-restful:go_default_library", + "//vendor/github.com/go-openapi/spec:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/genericapiserver/openapi/common/common.go b/vendor/k8s.io/apimachinery/pkg/openapi/common.go similarity index 72% rename from vendor/k8s.io/client-go/pkg/genericapiserver/openapi/common/common.go rename to vendor/k8s.io/apimachinery/pkg/openapi/common.go index d2a80f2e90..bfab64a1c2 100644 --- a/vendor/k8s.io/client-go/pkg/genericapiserver/openapi/common/common.go +++ b/vendor/k8s.io/apimachinery/pkg/openapi/common.go @@ -14,11 +14,12 @@ See the License for the specific language governing permissions and limitations under the License. */ -package common +package openapi import ( "github.com/emicklei/go-restful" "github.com/go-openapi/spec" + "strings" ) // OpenAPIDefinition describes single type. Normally these definitions are auto-generated using gen-openapi. @@ -27,8 +28,10 @@ type OpenAPIDefinition struct { Dependencies []string } +type ReferenceCallback func(path string) spec.Ref + // OpenAPIDefinitions is collection of all definitions. -type OpenAPIDefinitions map[string]OpenAPIDefinition +type GetOpenAPIDefinitions func(ReferenceCallback) map[string]OpenAPIDefinition // OpenAPIDefinitionGetter gets openAPI definitions for a given type. If a type implements this interface, // the definition returned by it will be used, otherwise the auto-generated definitions will be used. See @@ -59,10 +62,17 @@ type Config struct { // OpenAPIDefinitions should provide definition for all models used by routes. Failure to provide this map // or any of the models will result in spec generation failure. - Definitions *OpenAPIDefinitions + GetDefinitions GetOpenAPIDefinitions // GetOperationIDAndTags returns operation id and tags for a restful route. It is an optional function to customize operation IDs. - GetOperationIDAndTags func(servePath string, r *restful.Route) (string, []string, error) + GetOperationIDAndTags func(r *restful.Route) (string, []string, error) + + // GetDefinitionName returns a friendly name for a definition base on the serving path. parameter `name` is the full name of the definition. + // It is an optional function to customize model names. + GetDefinitionName func(name string) (string, spec.Extensions) + + // PostProcessSpec runs after the spec is ready to serve. It allows a final modification to the spec before serving. + PostProcessSpec func(*spec.Swagger) (*spec.Swagger, error) // SecurityDefinitions is list of all security definitions for OpenAPI service. If this is not nil, the user of config // is responsible to provide DefaultSecurity and (maybe) add unauthorized response to CommonResponses. @@ -114,26 +124,27 @@ type Config struct { // func GetOpenAPITypeFormat(typeName string) (string, string) { schemaTypeFormatMap := map[string][]string{ - "uint": {"integer", "int32"}, - "uint8": {"integer", "byte"}, - "uint16": {"integer", "int32"}, - "uint32": {"integer", "int64"}, - "uint64": {"integer", "int64"}, - "int": {"integer", "int32"}, - "int8": {"integer", "byte"}, - "int16": {"integer", "int32"}, - "int32": {"integer", "int32"}, - "int64": {"integer", "int64"}, - "byte": {"integer", "byte"}, - "float64": {"number", "double"}, - "float32": {"number", "float"}, - "bool": {"boolean", ""}, - "time.Time": {"string", "date-time"}, - "string": {"string", ""}, - "integer": {"integer", ""}, - "number": {"number", ""}, - "boolean": {"boolean", ""}, - "[]byte": {"string", "byte"}, // base64 encoded characters + "uint": {"integer", "int32"}, + "uint8": {"integer", "byte"}, + "uint16": {"integer", "int32"}, + "uint32": {"integer", "int64"}, + "uint64": {"integer", "int64"}, + "int": {"integer", "int32"}, + "int8": {"integer", "byte"}, + "int16": {"integer", "int32"}, + "int32": {"integer", "int32"}, + "int64": {"integer", "int64"}, + "byte": {"integer", "byte"}, + "float64": {"number", "double"}, + "float32": {"number", "float"}, + "bool": {"boolean", ""}, + "time.Time": {"string", "date-time"}, + "string": {"string", ""}, + "integer": {"integer", ""}, + "number": {"number", ""}, + "boolean": {"boolean", ""}, + "[]byte": {"string", "byte"}, // base64 encoded characters + "interface{}": {"object", ""}, } mapped, ok := schemaTypeFormatMap[typeName] if !ok { @@ -141,3 +152,10 @@ func GetOpenAPITypeFormat(typeName string) (string, string) { } return mapped[0], mapped[1] } + +func EscapeJsonPointer(p string) string { + // Escaping reference name using rfc6901 + p = strings.Replace(p, "~", "~0", -1) + p = strings.Replace(p, "/", "~1", -1) + return p +} diff --git a/vendor/k8s.io/client-go/pkg/genericapiserver/openapi/common/doc.go b/vendor/k8s.io/apimachinery/pkg/openapi/doc.go similarity index 83% rename from vendor/k8s.io/client-go/pkg/genericapiserver/openapi/common/doc.go rename to vendor/k8s.io/apimachinery/pkg/openapi/doc.go index 0308d58b4d..5ed572cc13 100644 --- a/vendor/k8s.io/client-go/pkg/genericapiserver/openapi/common/doc.go +++ b/vendor/k8s.io/apimachinery/pkg/openapi/doc.go @@ -14,5 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// package common holds shared codes and types between open API code generator and spec generator. -package common +// package openapi holds shared codes and types between open API code generator and spec generator. +package openapi diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/BUILD new file mode 100644 index 0000000000..4fd7d5a7ee --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/BUILD @@ -0,0 +1,68 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["swagger_doc_generator_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "codec.go", + "codec_check.go", + "conversion.go", + "doc.go", + "embedded.go", + "error.go", + "extension.go", + "generated.pb.go", + "helper.go", + "interfaces.go", + "register.go", + "scheme.go", + "scheme_builder.go", + "swagger_doc_generator.go", + "types.go", + "types_proto.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion/queryparams:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", + ], +) + +go_test( + name = "go_default_xtest", + srcs = [ + "conversion_test.go", + "embedded_test.go", + "extension_test.go", + "scheme_test.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/codec.go b/vendor/k8s.io/apimachinery/pkg/runtime/codec.go similarity index 76% rename from vendor/k8s.io/client-go/pkg/runtime/codec.go rename to vendor/k8s.io/apimachinery/pkg/runtime/codec.go index 070738cda5..d9748f0664 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/codec.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/codec.go @@ -24,8 +24,8 @@ import ( "net/url" "reflect" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion/queryparams" + "k8s.io/apimachinery/pkg/conversion/queryparams" + "k8s.io/apimachinery/pkg/runtime/schema" ) // codec binds an encoder and decoder. @@ -85,7 +85,7 @@ type DefaultingSerializer struct { } // Decode performs a decode and then allows the defaulter to act on the provided object. -func (d DefaultingSerializer) Decode(data []byte, defaultGVK *unversioned.GroupVersionKind, into Object) (Object, *unversioned.GroupVersionKind, error) { +func (d DefaultingSerializer) Decode(data []byte, defaultGVK *schema.GroupVersionKind, into Object) (Object, *schema.GroupVersionKind, error) { obj, gvk, err := d.Decoder.Decode(data, defaultGVK, into) if err != nil { return obj, gvk, err @@ -96,7 +96,7 @@ func (d DefaultingSerializer) Decode(data []byte, defaultGVK *unversioned.GroupV // UseOrCreateObject returns obj if the canonical ObjectKind returned by the provided typer matches gvk, or // invokes the ObjectCreator to instantiate a new gvk. Returns an error if the typer cannot find the object. -func UseOrCreateObject(t ObjectTyper, c ObjectCreater, gvk unversioned.GroupVersionKind, obj Object) (Object, error) { +func UseOrCreateObject(t ObjectTyper, c ObjectCreater, gvk schema.GroupVersionKind, obj Object) (Object, error) { if obj != nil { kinds, _, err := t.ObjectKinds(obj) if err != nil { @@ -129,7 +129,7 @@ type NoopDecoder struct { var _ Serializer = NoopDecoder{} -func (n NoopDecoder) Decode(data []byte, gvk *unversioned.GroupVersionKind, into Object) (Object, *unversioned.GroupVersionKind, error) { +func (n NoopDecoder) Decode(data []byte, gvk *schema.GroupVersionKind, into Object) (Object, *schema.GroupVersionKind, error) { return nil, nil, fmt.Errorf("decoding is not allowed for this codec: %v", reflect.TypeOf(n.Encoder)) } @@ -153,7 +153,7 @@ var _ ParameterCodec = ¶meterCodec{} // DecodeParameters converts the provided url.Values into an object of type From with the kind of into, and then // converts that object to into (if necessary). Returns an error if the operation cannot be completed. -func (c *parameterCodec) DecodeParameters(parameters url.Values, from unversioned.GroupVersion, into Object) error { +func (c *parameterCodec) DecodeParameters(parameters url.Values, from schema.GroupVersion, into Object) error { if len(parameters) == 0 { return nil } @@ -161,11 +161,12 @@ func (c *parameterCodec) DecodeParameters(parameters url.Values, from unversione if err != nil { return err } - targetGVK := targetGVKs[0] - if targetGVK.GroupVersion() == from { - return c.convertor.Convert(¶meters, into, nil) + for i := range targetGVKs { + if targetGVKs[i].GroupVersion() == from { + return c.convertor.Convert(¶meters, into, nil) + } } - input, err := c.creator.New(from.WithKind(targetGVK.Kind)) + input, err := c.creator.New(from.WithKind(targetGVKs[0].Kind)) if err != nil { return err } @@ -177,7 +178,7 @@ func (c *parameterCodec) DecodeParameters(parameters url.Values, from unversione // EncodeParameters converts the provided object into the to version, then converts that object to url.Values. // Returns an error if conversion is not possible. -func (c *parameterCodec) EncodeParameters(obj Object, to unversioned.GroupVersion) (url.Values, error) { +func (c *parameterCodec) EncodeParameters(obj Object, to schema.GroupVersion) (url.Values, error) { gvks, _, err := c.typer.ObjectKinds(obj) if err != nil { return nil, err @@ -194,27 +195,28 @@ func (c *parameterCodec) EncodeParameters(obj Object, to unversioned.GroupVersio } type base64Serializer struct { - Serializer + Encoder + Decoder } -func NewBase64Serializer(s Serializer) Serializer { - return &base64Serializer{s} +func NewBase64Serializer(e Encoder, d Decoder) Serializer { + return &base64Serializer{e, d} } func (s base64Serializer) Encode(obj Object, stream io.Writer) error { e := base64.NewEncoder(base64.StdEncoding, stream) - err := s.Serializer.Encode(obj, e) + err := s.Encoder.Encode(obj, e) e.Close() return err } -func (s base64Serializer) Decode(data []byte, defaults *unversioned.GroupVersionKind, into Object) (Object, *unversioned.GroupVersionKind, error) { +func (s base64Serializer) Decode(data []byte, defaults *schema.GroupVersionKind, into Object) (Object, *schema.GroupVersionKind, error) { out := make([]byte, base64.StdEncoding.DecodedLen(len(data))) n, err := base64.StdEncoding.Decode(out, data) if err != nil { return nil, nil, err } - return s.Serializer.Decode(out[:n], defaults, into) + return s.Decoder.Decode(out[:n], defaults, into) } // SerializerInfoForMediaType returns the first info in types that has a matching media type (which cannot @@ -243,30 +245,30 @@ var ( type internalGroupVersioner struct{} // KindForGroupVersionKinds returns an internal Kind if one is found, or converts the first provided kind to the internal version. -func (internalGroupVersioner) KindForGroupVersionKinds(kinds []unversioned.GroupVersionKind) (unversioned.GroupVersionKind, bool) { +func (internalGroupVersioner) KindForGroupVersionKinds(kinds []schema.GroupVersionKind) (schema.GroupVersionKind, bool) { for _, kind := range kinds { if kind.Version == APIVersionInternal { return kind, true } } for _, kind := range kinds { - return unversioned.GroupVersionKind{Group: kind.Group, Version: APIVersionInternal, Kind: kind.Kind}, true + return schema.GroupVersionKind{Group: kind.Group, Version: APIVersionInternal, Kind: kind.Kind}, true } - return unversioned.GroupVersionKind{}, false + return schema.GroupVersionKind{}, false } type disabledGroupVersioner struct{} // KindForGroupVersionKinds returns false for any input. -func (disabledGroupVersioner) KindForGroupVersionKinds(kinds []unversioned.GroupVersionKind) (unversioned.GroupVersionKind, bool) { - return unversioned.GroupVersionKind{}, false +func (disabledGroupVersioner) KindForGroupVersionKinds(kinds []schema.GroupVersionKind) (schema.GroupVersionKind, bool) { + return schema.GroupVersionKind{}, false } // GroupVersioners implements GroupVersioner and resolves to the first exact match for any kind. type GroupVersioners []GroupVersioner // KindForGroupVersionKinds returns the first match of any of the group versioners, or false if no match occured. -func (gvs GroupVersioners) KindForGroupVersionKinds(kinds []unversioned.GroupVersionKind) (unversioned.GroupVersionKind, bool) { +func (gvs GroupVersioners) KindForGroupVersionKinds(kinds []schema.GroupVersionKind) (schema.GroupVersionKind, bool) { for _, gv := range gvs { target, ok := gv.KindForGroupVersionKinds(kinds) if !ok { @@ -274,22 +276,22 @@ func (gvs GroupVersioners) KindForGroupVersionKinds(kinds []unversioned.GroupVer } return target, true } - return unversioned.GroupVersionKind{}, false + return schema.GroupVersionKind{}, false } -// Assert that unversioned.GroupVersion and GroupVersions implement GroupVersioner -var _ GroupVersioner = unversioned.GroupVersion{} -var _ GroupVersioner = unversioned.GroupVersions{} +// Assert that schema.GroupVersion and GroupVersions implement GroupVersioner +var _ GroupVersioner = schema.GroupVersion{} +var _ GroupVersioner = schema.GroupVersions{} var _ GroupVersioner = multiGroupVersioner{} type multiGroupVersioner struct { - target unversioned.GroupVersion - acceptedGroupKinds []unversioned.GroupKind + target schema.GroupVersion + acceptedGroupKinds []schema.GroupKind } // NewMultiGroupVersioner returns the provided group version for any kind that matches one of the provided group kinds. // Kind may be empty in the provided group kind, in which case any kind will match. -func NewMultiGroupVersioner(gv unversioned.GroupVersion, groupKinds ...unversioned.GroupKind) GroupVersioner { +func NewMultiGroupVersioner(gv schema.GroupVersion, groupKinds ...schema.GroupKind) GroupVersioner { if len(groupKinds) == 0 || (len(groupKinds) == 1 && groupKinds[0].Group == gv.Group) { return gv } @@ -298,7 +300,7 @@ func NewMultiGroupVersioner(gv unversioned.GroupVersion, groupKinds ...unversion // KindForGroupVersionKinds returns the target group version if any kind matches any of the original group kinds. It will // use the originating kind where possible. -func (v multiGroupVersioner) KindForGroupVersionKinds(kinds []unversioned.GroupVersionKind) (unversioned.GroupVersionKind, bool) { +func (v multiGroupVersioner) KindForGroupVersionKinds(kinds []schema.GroupVersionKind) (schema.GroupVersionKind, bool) { for _, src := range kinds { for _, kind := range v.acceptedGroupKinds { if kind.Group != src.Group { @@ -310,5 +312,5 @@ func (v multiGroupVersioner) KindForGroupVersionKinds(kinds []unversioned.GroupV return v.target.WithKind(src.Kind), true } } - return unversioned.GroupVersionKind{}, false + return schema.GroupVersionKind{}, false } diff --git a/vendor/k8s.io/client-go/pkg/runtime/codec_check.go b/vendor/k8s.io/apimachinery/pkg/runtime/codec_check.go similarity index 81% rename from vendor/k8s.io/client-go/pkg/runtime/codec_check.go rename to vendor/k8s.io/apimachinery/pkg/runtime/codec_check.go index 9a52ad2e5c..510444a4de 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/codec_check.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/codec_check.go @@ -20,16 +20,15 @@ import ( "fmt" "reflect" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) // CheckCodec makes sure that the codec can encode objects like internalType, // decode all of the external types listed, and also decode them into the given // object. (Will modify internalObject.) (Assumes JSON serialization.) // TODO: verify that the correct external version is chosen on encode... -func CheckCodec(c Codec, internalType Object, externalTypes ...unversioned.GroupVersionKind) error { - _, err := Encode(c, internalType) - if err != nil { +func CheckCodec(c Codec, internalType Object, externalTypes ...schema.GroupVersionKind) error { + if _, err := Encode(c, internalType); err != nil { return fmt.Errorf("Internal type not encodable: %v", err) } for _, et := range externalTypes { @@ -41,9 +40,8 @@ func CheckCodec(c Codec, internalType Object, externalTypes ...unversioned.Group if reflect.TypeOf(obj) != reflect.TypeOf(internalType) { return fmt.Errorf("decode of external type %s produced: %#v", et, obj) } - err = DecodeInto(c, exBytes, internalType) - if err != nil { - return fmt.Errorf("external type %s not convertable to internal type: %v", et, err) + if err = DecodeInto(c, exBytes, internalType); err != nil { + return fmt.Errorf("external type %s not convertible to internal type: %v", et, err) } } return nil diff --git a/vendor/k8s.io/client-go/pkg/runtime/conversion.go b/vendor/k8s.io/apimachinery/pkg/runtime/conversion.go similarity index 98% rename from vendor/k8s.io/client-go/pkg/runtime/conversion.go rename to vendor/k8s.io/apimachinery/pkg/runtime/conversion.go index 034bef9f11..8eedffc9c3 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/conversion.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/conversion.go @@ -23,7 +23,7 @@ import ( "strconv" "strings" - "k8s.io/client-go/pkg/conversion" + "k8s.io/apimachinery/pkg/conversion" ) // JSONKeyMapper uses the struct tags on a conversion to determine the key value for diff --git a/vendor/k8s.io/client-go/pkg/runtime/doc.go b/vendor/k8s.io/apimachinery/pkg/runtime/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/runtime/doc.go rename to vendor/k8s.io/apimachinery/pkg/runtime/doc.go diff --git a/vendor/k8s.io/client-go/pkg/runtime/embedded.go b/vendor/k8s.io/apimachinery/pkg/runtime/embedded.go similarity index 90% rename from vendor/k8s.io/client-go/pkg/runtime/embedded.go rename to vendor/k8s.io/apimachinery/pkg/runtime/embedded.go index f914256b75..e8825a787a 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/embedded.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/embedded.go @@ -19,21 +19,21 @@ package runtime import ( "errors" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime/schema" ) type encodable struct { E Encoder `json:"-"` obj Object - versions []unversioned.GroupVersion + versions []schema.GroupVersion } -func (e encodable) GetObjectKind() unversioned.ObjectKind { return e.obj.GetObjectKind() } +func (e encodable) GetObjectKind() schema.ObjectKind { return e.obj.GetObjectKind() } // NewEncodable creates an object that will be encoded with the provided codec on demand. // Provided as a convenience for test cases dealing with internal objects. -func NewEncodable(e Encoder, obj Object, versions ...unversioned.GroupVersion) Object { +func NewEncodable(e Encoder, obj Object, versions ...schema.GroupVersion) Object { if _, ok := obj.(*Unknown); ok { return obj } @@ -52,7 +52,7 @@ func (re encodable) MarshalJSON() ([]byte, error) { // NewEncodableList creates an object that will be encoded with the provided codec on demand. // Provided as a convenience for test cases dealing with internal objects. -func NewEncodableList(e Encoder, objects []Object, versions ...unversioned.GroupVersion) []Object { +func NewEncodableList(e Encoder, objects []Object, versions ...schema.GroupVersion) []Object { out := make([]Object, len(objects)) for i := range objects { if _, ok := objects[i].(*Unknown); ok { diff --git a/vendor/k8s.io/client-go/pkg/runtime/error.go b/vendor/k8s.io/apimachinery/pkg/runtime/error.go similarity index 80% rename from vendor/k8s.io/client-go/pkg/runtime/error.go rename to vendor/k8s.io/apimachinery/pkg/runtime/error.go index 086507c14c..21a3557077 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/error.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/error.go @@ -20,20 +20,31 @@ import ( "fmt" "reflect" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) type notRegisteredErr struct { - gvk unversioned.GroupVersionKind - t reflect.Type + gvk schema.GroupVersionKind + target GroupVersioner + t reflect.Type } -// NewNotRegisteredErr is exposed for testing. -func NewNotRegisteredErr(gvk unversioned.GroupVersionKind, t reflect.Type) error { - return ¬RegisteredErr{gvk: gvk, t: t} +func NewNotRegisteredErrForKind(gvk schema.GroupVersionKind) error { + return ¬RegisteredErr{gvk: gvk} +} + +func NewNotRegisteredErrForType(t reflect.Type) error { + return ¬RegisteredErr{t: t} +} + +func NewNotRegisteredErrForTarget(t reflect.Type, target GroupVersioner) error { + return ¬RegisteredErr{t: t, target: target} } func (k *notRegisteredErr) Error() string { + if k.t != nil && k.target != nil { + return fmt.Sprintf("%v is not suitable for converting to %q", k.t, k.target) + } if k.t != nil { return fmt.Sprintf("no kind is registered for the type %v", k.t) } diff --git a/vendor/k8s.io/client-go/pkg/runtime/extension.go b/vendor/k8s.io/apimachinery/pkg/runtime/extension.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/runtime/extension.go rename to vendor/k8s.io/apimachinery/pkg/runtime/extension.go diff --git a/vendor/k8s.io/client-go/pkg/runtime/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/runtime/generated.pb.go similarity index 67% rename from vendor/k8s.io/client-go/pkg/runtime/generated.pb.go rename to vendor/k8s.io/apimachinery/pkg/runtime/generated.pb.go index d18d688f57..bce8336a8a 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/generated.pb.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -15,14 +15,14 @@ limitations under the License. */ // Code generated by protoc-gen-gogo. -// source: k8s.io/kubernetes/pkg/runtime/generated.proto +// source: k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/generated.proto // DO NOT EDIT! /* Package runtime is a generated protocol buffer package. It is generated from these files: - k8s.io/kubernetes/pkg/runtime/generated.proto + k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/generated.proto It has these top-level messages: RawExtension @@ -47,7 +47,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *RawExtension) Reset() { *m = RawExtension{} } func (*RawExtension) ProtoMessage() {} @@ -62,125 +64,125 @@ func (*Unknown) ProtoMessage() {} func (*Unknown) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } func init() { - proto.RegisterType((*RawExtension)(nil), "k8s.io.client-go.pkg.runtime.RawExtension") - proto.RegisterType((*TypeMeta)(nil), "k8s.io.client-go.pkg.runtime.TypeMeta") - proto.RegisterType((*Unknown)(nil), "k8s.io.client-go.pkg.runtime.Unknown") + proto.RegisterType((*RawExtension)(nil), "k8s.io.apimachinery.pkg.runtime.RawExtension") + proto.RegisterType((*TypeMeta)(nil), "k8s.io.apimachinery.pkg.runtime.TypeMeta") + proto.RegisterType((*Unknown)(nil), "k8s.io.apimachinery.pkg.runtime.Unknown") } -func (m *RawExtension) Marshal() (data []byte, err error) { +func (m *RawExtension) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RawExtension) MarshalTo(data []byte) (int, error) { +func (m *RawExtension) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Raw != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Raw))) - i += copy(data[i:], m.Raw) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Raw))) + i += copy(dAtA[i:], m.Raw) } return i, nil } -func (m *TypeMeta) Marshal() (data []byte, err error) { +func (m *TypeMeta) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *TypeMeta) MarshalTo(data []byte) (int, error) { +func (m *TypeMeta) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) return i, nil } -func (m *Unknown) Marshal() (data []byte, err error) { +func (m *Unknown) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Unknown) MarshalTo(data []byte) (int, error) { +func (m *Unknown) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.TypeMeta.Size())) - n1, err := m.TypeMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.TypeMeta.Size())) + n1, err := m.TypeMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 if m.Raw != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Raw))) - i += copy(data[i:], m.Raw) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Raw))) + i += copy(dAtA[i:], m.Raw) } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ContentEncoding))) - i += copy(data[i:], m.ContentEncoding) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ContentEncoding))) + i += copy(dAtA[i:], m.ContentEncoding) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ContentType))) - i += copy(data[i:], m.ContentType) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ContentType))) + i += copy(dAtA[i:], m.ContentType) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *RawExtension) Size() (n int) { @@ -274,8 +276,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *RawExtension) Unmarshal(data []byte) error { - l := len(data) +func (m *RawExtension) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -287,7 +289,7 @@ func (m *RawExtension) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -315,7 +317,7 @@ func (m *RawExtension) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -329,14 +331,14 @@ func (m *RawExtension) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Raw = append(m.Raw[:0], data[iNdEx:postIndex]...) + m.Raw = append(m.Raw[:0], dAtA[iNdEx:postIndex]...) if m.Raw == nil { m.Raw = []byte{} } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -355,8 +357,8 @@ func (m *RawExtension) Unmarshal(data []byte) error { } return nil } -func (m *TypeMeta) Unmarshal(data []byte) error { - l := len(data) +func (m *TypeMeta) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -368,7 +370,7 @@ func (m *TypeMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -396,7 +398,7 @@ func (m *TypeMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -411,7 +413,7 @@ func (m *TypeMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.APIVersion = string(data[iNdEx:postIndex]) + m.APIVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -425,7 +427,7 @@ func (m *TypeMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -440,11 +442,11 @@ func (m *TypeMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = string(data[iNdEx:postIndex]) + m.Kind = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -463,8 +465,8 @@ func (m *TypeMeta) Unmarshal(data []byte) error { } return nil } -func (m *Unknown) Unmarshal(data []byte) error { - l := len(data) +func (m *Unknown) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -476,7 +478,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -504,7 +506,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -518,7 +520,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.TypeMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TypeMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -534,7 +536,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -548,7 +550,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Raw = append(m.Raw[:0], data[iNdEx:postIndex]...) + m.Raw = append(m.Raw[:0], dAtA[iNdEx:postIndex]...) if m.Raw == nil { m.Raw = []byte{} } @@ -565,7 +567,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -580,7 +582,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContentEncoding = string(data[iNdEx:postIndex]) + m.ContentEncoding = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -594,7 +596,7 @@ func (m *Unknown) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -609,11 +611,11 @@ func (m *Unknown) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContentType = string(data[iNdEx:postIndex]) + m.ContentType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -632,8 +634,8 @@ func (m *Unknown) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -644,7 +646,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -662,7 +664,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -679,7 +681,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -702,7 +704,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -713,7 +715,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -737,31 +739,35 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 388 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x7c, 0x90, 0x3f, 0x8f, 0xda, 0x30, - 0x18, 0xc6, 0x13, 0x40, 0x82, 0x1a, 0x24, 0x2a, 0x77, 0x68, 0x8a, 0x54, 0x83, 0x58, 0x5a, 0x06, - 0x6c, 0x15, 0xa9, 0x52, 0x57, 0x82, 0x18, 0xaa, 0xaa, 0x52, 0x65, 0x95, 0x0e, 0x9d, 0x1a, 0x12, - 0x37, 0xb5, 0x52, 0xec, 0xc8, 0x71, 0x94, 0x76, 0xeb, 0x47, 0xe8, 0xc7, 0x62, 0x64, 0xbc, 0x09, - 0x1d, 0xb9, 0xcf, 0x70, 0xfb, 0x09, 0x63, 0xfe, 0x1c, 0xa0, 0xdb, 0xe2, 0xf7, 0xf9, 0x3d, 0xcf, - 0xfb, 0xbc, 0x01, 0xc3, 0xe4, 0x43, 0x86, 0xb9, 0x24, 0x49, 0x3e, 0x67, 0x4a, 0x30, 0xcd, 0x32, - 0x92, 0x26, 0x31, 0x51, 0xb9, 0xd0, 0x7c, 0xc1, 0x48, 0xcc, 0x04, 0x53, 0x81, 0x66, 0x11, 0x4e, - 0x95, 0xd4, 0x12, 0xbe, 0xde, 0xe1, 0xf8, 0x88, 0xe3, 0x34, 0x89, 0xb1, 0xc5, 0x3b, 0xc3, 0x98, - 0xeb, 0x5f, 0xf9, 0x1c, 0x87, 0x72, 0x41, 0x62, 0x19, 0x4b, 0x62, 0x5c, 0xf3, 0xfc, 0xa7, 0x79, - 0x99, 0x87, 0xf9, 0xda, 0xa5, 0x75, 0x46, 0xd7, 0x97, 0x07, 0x29, 0x27, 0x8a, 0x65, 0x32, 0x57, - 0xe1, 0x45, 0x83, 0xce, 0xbb, 0xeb, 0x9e, 0x5c, 0xf3, 0xdf, 0x84, 0x0b, 0x9d, 0x69, 0x75, 0x6e, - 0xe9, 0x0f, 0x40, 0x8b, 0x06, 0xc5, 0xf4, 0x8f, 0x66, 0x22, 0xe3, 0x52, 0xc0, 0x57, 0xa0, 0xaa, - 0x82, 0xc2, 0x73, 0x7b, 0xee, 0xdb, 0x96, 0x5f, 0x2f, 0xd7, 0xdd, 0x2a, 0x0d, 0x0a, 0xba, 0x9d, - 0xf5, 0x7f, 0x80, 0xc6, 0xd7, 0xbf, 0x29, 0xfb, 0xcc, 0x74, 0x00, 0x47, 0x00, 0x04, 0x29, 0xff, - 0xc6, 0xd4, 0xd6, 0x64, 0xe8, 0x67, 0x3e, 0x5c, 0xae, 0xbb, 0x4e, 0xb9, 0xee, 0x82, 0xf1, 0x97, - 0x8f, 0x56, 0xa1, 0x27, 0x14, 0xec, 0x81, 0x5a, 0xc2, 0x45, 0xe4, 0x55, 0x0c, 0xdd, 0xb2, 0x74, - 0xed, 0x13, 0x17, 0x11, 0x35, 0x4a, 0xff, 0xde, 0x05, 0xf5, 0x99, 0x48, 0x84, 0x2c, 0x04, 0x9c, - 0x81, 0x86, 0xb6, 0xdb, 0x4c, 0x7e, 0x73, 0xf4, 0x06, 0x3f, 0xf9, 0x83, 0xf1, 0xbe, 0x9c, 0xff, - 0xdc, 0x46, 0x1f, 0xea, 0xd2, 0x43, 0xd4, 0xfe, 0xbe, 0xca, 0xe5, 0x7d, 0x70, 0x0c, 0xda, 0xa1, - 0x14, 0x9a, 0x09, 0x3d, 0x15, 0xa1, 0x8c, 0xb8, 0x88, 0xbd, 0xaa, 0xa9, 0xfa, 0xd2, 0xe6, 0xb5, - 0x27, 0x8f, 0x65, 0x7a, 0xce, 0xc3, 0xf7, 0xa0, 0x69, 0x47, 0xdb, 0xd5, 0x5e, 0xcd, 0xd8, 0x5f, - 0x58, 0x7b, 0x73, 0x72, 0x94, 0xe8, 0x29, 0xe7, 0x0f, 0x96, 0x1b, 0xe4, 0xac, 0x36, 0xc8, 0xb9, - 0xd9, 0x20, 0xe7, 0x5f, 0x89, 0xdc, 0x65, 0x89, 0xdc, 0x55, 0x89, 0xdc, 0xdb, 0x12, 0xb9, 0xff, - 0xef, 0x90, 0xf3, 0xbd, 0x6e, 0x8f, 0x7c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x32, 0xc1, 0x73, 0x2d, - 0x94, 0x02, 0x00, 0x00, + // 395 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x90, 0x4f, 0x6f, 0xd3, 0x30, + 0x18, 0xc6, 0xe3, 0xb5, 0x52, 0x87, 0x5b, 0x69, 0xc8, 0x1c, 0x08, 0x3b, 0x38, 0x53, 0x4f, 0xec, + 0x30, 0x5b, 0x1a, 0x42, 0xe2, 0xba, 0x4c, 0x93, 0x40, 0x08, 0x09, 0x59, 0xfc, 0x91, 0x38, 0xe1, + 0x26, 0x26, 0xb3, 0x42, 0x5f, 0x47, 0x8e, 0x43, 0xd8, 0x8d, 0x8f, 0xc0, 0xc7, 0xea, 0x71, 0xc7, + 0x9e, 0x2a, 0x1a, 0x3e, 0x04, 0x57, 0x54, 0xd7, 0x2d, 0xa5, 0x08, 0xed, 0x16, 0xbf, 0xcf, 0xf3, + 0x7b, 0xde, 0xe7, 0x0d, 0x7e, 0x5e, 0x3e, 0xab, 0x99, 0x36, 0xbc, 0x6c, 0x26, 0xca, 0x82, 0x72, + 0xaa, 0xe6, 0x5f, 0x14, 0xe4, 0xc6, 0xf2, 0x20, 0xc8, 0x4a, 0x4f, 0x65, 0x76, 0xad, 0x41, 0xd9, + 0x1b, 0x5e, 0x95, 0x05, 0xb7, 0x0d, 0x38, 0x3d, 0x55, 0xbc, 0x50, 0xa0, 0xac, 0x74, 0x2a, 0x67, + 0x95, 0x35, 0xce, 0x90, 0x64, 0x0d, 0xb0, 0x5d, 0x80, 0x55, 0x65, 0xc1, 0x02, 0x70, 0x7c, 0x56, + 0x68, 0x77, 0xdd, 0x4c, 0x58, 0x66, 0xa6, 0xbc, 0x30, 0x85, 0xe1, 0x9e, 0x9b, 0x34, 0x9f, 0xfc, + 0xcb, 0x3f, 0xfc, 0xd7, 0x3a, 0xef, 0xf8, 0xc9, 0xff, 0x0a, 0x34, 0x4e, 0x7f, 0xe6, 0x1a, 0x5c, + 0xed, 0xec, 0x7e, 0x89, 0xf1, 0x29, 0x1e, 0x09, 0xd9, 0x5e, 0x7d, 0x75, 0x0a, 0x6a, 0x6d, 0x80, + 0x3c, 0xc2, 0x3d, 0x2b, 0xdb, 0x18, 0x9d, 0xa0, 0xc7, 0xa3, 0x74, 0xd0, 0x2d, 0x92, 0x9e, 0x90, + 0xad, 0x58, 0xcd, 0xc6, 0x1f, 0xf1, 0xe1, 0x9b, 0x9b, 0x4a, 0xbd, 0x52, 0x4e, 0x92, 0x73, 0x8c, + 0x65, 0xa5, 0xdf, 0x29, 0xbb, 0x82, 0xbc, 0xfb, 0x5e, 0x4a, 0x66, 0x8b, 0x24, 0xea, 0x16, 0x09, + 0xbe, 0x78, 0xfd, 0x22, 0x28, 0x62, 0xc7, 0x45, 0x4e, 0x70, 0xbf, 0xd4, 0x90, 0xc7, 0x07, 0xde, + 0x3d, 0x0a, 0xee, 0xfe, 0x4b, 0x0d, 0xb9, 0xf0, 0xca, 0xf8, 0x17, 0xc2, 0x83, 0xb7, 0x50, 0x82, + 0x69, 0x81, 0xbc, 0xc7, 0x87, 0x2e, 0x6c, 0xf3, 0xf9, 0xc3, 0xf3, 0x53, 0x76, 0xc7, 0x0f, 0x63, + 0x9b, 0x7a, 0xe9, 0xfd, 0x10, 0xbe, 0x2d, 0x2c, 0xb6, 0x61, 0x9b, 0x0b, 0x0f, 0xfe, 0xbd, 0x90, + 0x5c, 0xe0, 0xa3, 0xcc, 0x80, 0x53, 0xe0, 0xae, 0x20, 0x33, 0xb9, 0x86, 0x22, 0xee, 0xf9, 0xb2, + 0x0f, 0x43, 0xde, 0xd1, 0xe5, 0xdf, 0xb2, 0xd8, 0xf7, 0x93, 0xa7, 0x78, 0x18, 0x46, 0xab, 0xd5, + 0x71, 0xdf, 0xe3, 0x0f, 0x02, 0x3e, 0xbc, 0xfc, 0x23, 0x89, 0x5d, 0x5f, 0x7a, 0x36, 0x5b, 0xd2, + 0xe8, 0x76, 0x49, 0xa3, 0xf9, 0x92, 0x46, 0xdf, 0x3a, 0x8a, 0x66, 0x1d, 0x45, 0xb7, 0x1d, 0x45, + 0xf3, 0x8e, 0xa2, 0x1f, 0x1d, 0x45, 0xdf, 0x7f, 0xd2, 0xe8, 0xc3, 0x20, 0x1c, 0xfa, 0x3b, 0x00, + 0x00, 0xff, 0xff, 0x3f, 0x1e, 0x24, 0x09, 0x85, 0x02, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/runtime/generated.proto b/vendor/k8s.io/apimachinery/pkg/runtime/generated.proto similarity index 91% rename from vendor/k8s.io/client-go/pkg/runtime/generated.proto rename to vendor/k8s.io/apimachinery/pkg/runtime/generated.proto index 136ab0b5e3..57fc840785 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/generated.proto +++ b/vendor/k8s.io/apimachinery/pkg/runtime/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,10 +19,9 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.runtime; +package k8s.io.apimachinery.pkg.runtime; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "runtime"; @@ -85,7 +84,7 @@ message RawExtension { // runtime.TypeMeta `json:",inline"` // ... // other fields // } -// func (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *unversioned.GroupVersionKind) { unversioned.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind +// func (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *metav1.GroupVersionKind) { metav1.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind // // TypeMeta is provided here for convenience. You may use it directly from this package or define // your own with the same fields. diff --git a/vendor/k8s.io/client-go/pkg/runtime/helper.go b/vendor/k8s.io/apimachinery/pkg/runtime/helper.go similarity index 95% rename from vendor/k8s.io/client-go/pkg/runtime/helper.go rename to vendor/k8s.io/apimachinery/pkg/runtime/helper.go index 3062109f71..a6c1a8d34d 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/helper.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/helper.go @@ -21,9 +21,9 @@ import ( "io" "reflect" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/util/errors" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/errors" ) // unsafeObjectConvertor implements ObjectConvertor using the unsafe conversion path. @@ -173,7 +173,7 @@ type MultiObjectTyper []ObjectTyper var _ ObjectTyper = MultiObjectTyper{} -func (m MultiObjectTyper) ObjectKinds(obj Object) (gvks []unversioned.GroupVersionKind, unversionedType bool, err error) { +func (m MultiObjectTyper) ObjectKinds(obj Object) (gvks []schema.GroupVersionKind, unversionedType bool, err error) { for _, t := range m { gvks, unversionedType, err = t.ObjectKinds(obj) if err == nil { @@ -183,7 +183,7 @@ func (m MultiObjectTyper) ObjectKinds(obj Object) (gvks []unversioned.GroupVersi return } -func (m MultiObjectTyper) Recognizes(gvk unversioned.GroupVersionKind) bool { +func (m MultiObjectTyper) Recognizes(gvk schema.GroupVersionKind) bool { for _, t := range m { if t.Recognizes(gvk) { return true diff --git a/vendor/k8s.io/client-go/pkg/runtime/interfaces.go b/vendor/k8s.io/apimachinery/pkg/runtime/interfaces.go similarity index 88% rename from vendor/k8s.io/client-go/pkg/runtime/interfaces.go rename to vendor/k8s.io/apimachinery/pkg/runtime/interfaces.go index 0315cac512..fcb18ba111 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/interfaces.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/interfaces.go @@ -20,7 +20,7 @@ import ( "io" "net/url" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) const ( @@ -36,7 +36,7 @@ type GroupVersioner interface { // target is known. In general, if the return target is not in the input list, the caller is expected to invoke // Scheme.New(target) and then perform a conversion between the current Go type and the destination Go type. // Sophisticated implementations may use additional information about the input kinds to pick a destination kind. - KindForGroupVersionKinds(kinds []unversioned.GroupVersionKind) (target unversioned.GroupVersionKind, ok bool) + KindForGroupVersionKinds(kinds []schema.GroupVersionKind) (target schema.GroupVersionKind, ok bool) } // Encoders write objects to a serialized form @@ -55,7 +55,7 @@ type Decoder interface { // guaranteed to be populated. The returned object is not guaranteed to match into. If defaults are // provided, they are applied to the data by default. If no defaults or partial defaults are provided, the // type of the into may be used to guide conversion decisions. - Decode(data []byte, defaults *unversioned.GroupVersionKind, into Object) (Object, *unversioned.GroupVersionKind, error) + Decode(data []byte, defaults *schema.GroupVersionKind, into Object) (Object, *schema.GroupVersionKind, error) } // Serializer is the core interface for transforming objects into a serialized format and back. @@ -76,9 +76,9 @@ type Codec Serializer type ParameterCodec interface { // DecodeParameters takes the given url.Values in the specified group version and decodes them // into the provided object, or returns an error. - DecodeParameters(parameters url.Values, from unversioned.GroupVersion, into Object) error + DecodeParameters(parameters url.Values, from schema.GroupVersion, into Object) error // EncodeParameters encodes the provided object as query parameters or returns an error. - EncodeParameters(obj Object, to unversioned.GroupVersion) (url.Values, error) + EncodeParameters(obj Object, to schema.GroupVersion) (url.Values, error) } // Framer is a factory for creating readers and writers that obey a particular framing pattern. @@ -191,16 +191,16 @@ type ObjectTyper interface { // ObjectKinds returns the all possible group,version,kind of the provided object, true if // the object is unversioned, or an error if the object is not recognized // (IsNotRegisteredError will return true). - ObjectKinds(Object) ([]unversioned.GroupVersionKind, bool, error) + ObjectKinds(Object) ([]schema.GroupVersionKind, bool, error) // Recognizes returns true if the scheme is able to handle the provided version and kind, // or more precisely that the provided version is a possible conversion or decoding // target. - Recognizes(gvk unversioned.GroupVersionKind) bool + Recognizes(gvk schema.GroupVersionKind) bool } // ObjectCreater contains methods for instantiating an object by kind and version. type ObjectCreater interface { - New(kind unversioned.GroupVersionKind) (out Object, err error) + New(kind schema.GroupVersionKind) (out Object, err error) } // ObjectCopier duplicates an object. @@ -233,5 +233,19 @@ type SelfLinker interface { // serializers to set the kind, version, and group the object is represented as. An Object may choose // to return a no-op ObjectKindAccessor in cases where it is not expected to be serialized. type Object interface { - GetObjectKind() unversioned.ObjectKind + GetObjectKind() schema.ObjectKind +} + +// Unstructured objects store values as map[string]interface{}, with only values that can be serialized +// to JSON allowed. +type Unstructured interface { + // IsUnstructuredObject is a marker interface to allow objects that can be serialized but not introspected + // to bypass conversion. + IsUnstructuredObject() + // IsList returns true if this type is a list or matches the list convention - has an array called "items". + IsList() bool + // UnstructuredContent returns a non-nil, mutable map of the contents of this object. Values may be + // []interface{}, map[string]interface{}, or any primitive type. Contents are typically serialized to + // and from JSON. + UnstructuredContent() map[string]interface{} } diff --git a/vendor/k8s.io/client-go/pkg/runtime/register.go b/vendor/k8s.io/apimachinery/pkg/runtime/register.go similarity index 73% rename from vendor/k8s.io/client-go/pkg/runtime/register.go rename to vendor/k8s.io/apimachinery/pkg/runtime/register.go index 66f664fa05..2ec6db8201 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/register.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/register.go @@ -16,32 +16,27 @@ limitations under the License. package runtime -import ( - "k8s.io/client-go/pkg/api/unversioned" -) +import "k8s.io/apimachinery/pkg/runtime/schema" // SetGroupVersionKind satisfies the ObjectKind interface for all objects that embed TypeMeta -func (obj *TypeMeta) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { +func (obj *TypeMeta) SetGroupVersionKind(gvk schema.GroupVersionKind) { obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() } // GroupVersionKind satisfies the ObjectKind interface for all objects that embed TypeMeta -func (obj *TypeMeta) GroupVersionKind() unversioned.GroupVersionKind { - return unversioned.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) +func (obj *TypeMeta) GroupVersionKind() schema.GroupVersionKind { + return schema.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) } -func (obj *Unknown) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } - -func (obj *Unstructured) GetObjectKind() unversioned.ObjectKind { return obj } -func (obj *UnstructuredList) GetObjectKind() unversioned.ObjectKind { return obj } +func (obj *Unknown) GetObjectKind() schema.ObjectKind { return &obj.TypeMeta } // GetObjectKind implements Object for VersionedObjects, returning an empty ObjectKind // interface if no objects are provided, or the ObjectKind interface of the object in the // highest array position. -func (obj *VersionedObjects) GetObjectKind() unversioned.ObjectKind { +func (obj *VersionedObjects) GetObjectKind() schema.ObjectKind { last := obj.Last() if last == nil { - return unversioned.EmptyObjectKind + return schema.EmptyObjectKind } return last.GetObjectKind() } diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/schema/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/schema/BUILD new file mode 100644 index 0000000000..660497064b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/schema/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["group_version_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "generated.pb.go", + "group_version.go", + "interfaces.go", + ], + tags = ["automanaged"], + deps = ["//vendor/github.com/gogo/protobuf/proto:go_default_library"], +) diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.pb.go new file mode 100644 index 0000000000..e2cc121661 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.pb.go @@ -0,0 +1,65 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto +// DO NOT EDIT! + +/* + Package schema is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto + + It has these top-level messages: +*/ +package schema + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 202 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x74, 0xce, 0xaf, 0x4e, 0x04, 0x31, + 0x10, 0xc7, 0xf1, 0xd6, 0x20, 0x90, 0xc8, 0x13, 0x23, 0x51, 0xd0, 0x11, 0x18, 0x34, 0x2f, 0x80, + 0xc7, 0x75, 0xf7, 0x86, 0x6e, 0x53, 0xfa, 0x27, 0xed, 0x94, 0x04, 0xc7, 0x23, 0xf0, 0x58, 0x27, + 0x4f, 0xae, 0x64, 0xcb, 0x8b, 0x90, 0xb4, 0x2b, 0x08, 0xc9, 0xb9, 0xfe, 0xd2, 0x7c, 0x26, 0xdf, + 0xeb, 0x67, 0xf7, 0x58, 0x94, 0x8d, 0xe8, 0xea, 0x44, 0x39, 0x10, 0x53, 0xc1, 0x77, 0x0a, 0xc7, + 0x98, 0x71, 0xff, 0xd0, 0xc9, 0x7a, 0x3d, 0x2f, 0x36, 0x50, 0xfe, 0xc0, 0xe4, 0x0c, 0xe6, 0x1a, + 0xd8, 0x7a, 0xc2, 0x32, 0x2f, 0xe4, 0x35, 0x1a, 0x0a, 0x94, 0x35, 0xd3, 0x51, 0xa5, 0x1c, 0x39, + 0xde, 0xdc, 0x0e, 0xa7, 0xfe, 0x3a, 0x95, 0x9c, 0x51, 0xbb, 0x53, 0xc3, 0x1d, 0xee, 0x8d, 0xe5, + 0xa5, 0x4e, 0x6a, 0x8e, 0x1e, 0x4d, 0x34, 0x11, 0x3b, 0x9f, 0xea, 0x6b, 0x5f, 0x7d, 0xf4, 0xd7, + 0x38, 0x7b, 0x78, 0xb8, 0x94, 0x53, 0xd9, 0xbe, 0xa1, 0x0d, 0x5c, 0x38, 0xff, 0x6f, 0x79, 0xba, + 0x3b, 0x6d, 0x20, 0xce, 0x1b, 0x88, 0x75, 0x03, 0xf1, 0xd9, 0x40, 0x9e, 0x1a, 0xc8, 0x73, 0x03, + 0xb9, 0x36, 0x90, 0xdf, 0x0d, 0xe4, 0xd7, 0x0f, 0x88, 0x97, 0xab, 0x51, 0xf4, 0x1b, 0x00, 0x00, + 0xff, 0xff, 0xfd, 0x59, 0x57, 0x93, 0x0b, 0x01, 0x00, 0x00, +} diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto b/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto new file mode 100644 index 0000000000..ebc1a263d2 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/schema/generated.proto @@ -0,0 +1,28 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.apimachinery.pkg.runtime.schema; + +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "schema"; + diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/group_version.go b/vendor/k8s.io/apimachinery/pkg/runtime/schema/group_version.go similarity index 73% rename from vendor/k8s.io/client-go/pkg/api/unversioned/group_version.go rename to vendor/k8s.io/apimachinery/pkg/runtime/schema/group_version.go index db842affe6..1a9bba1060 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/group_version.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/schema/group_version.go @@ -14,10 +14,9 @@ See the License for the specific language governing permissions and limitations under the License. */ -package unversioned +package schema import ( - "encoding/json" "fmt" "strings" ) @@ -39,11 +38,9 @@ func ParseResourceArg(arg string) (*GroupVersionResource, GroupResource) { // GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying // concepts during lookup stages without having partially valid types -// -// +protobuf.options.(gogoproto.goproto_stringer)=false type GroupResource struct { - Group string `protobuf:"bytes,1,opt,name=group"` - Resource string `protobuf:"bytes,2,opt,name=resource"` + Group string + Resource string } func (gr GroupResource) WithVersion(version string) GroupVersionResource { @@ -72,13 +69,11 @@ func ParseGroupResource(gr string) GroupResource { } // GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion -// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling -// -// +protobuf.options.(gogoproto.goproto_stringer)=false +// to avoid automatic coercion. It doesn't use a GroupVersion to avoid custom marshalling type GroupVersionResource struct { - Group string `protobuf:"bytes,1,opt,name=group"` - Version string `protobuf:"bytes,2,opt,name=version"` - Resource string `protobuf:"bytes,3,opt,name=resource"` + Group string + Version string + Resource string } func (gvr GroupVersionResource) Empty() bool { @@ -99,11 +94,9 @@ func (gvr *GroupVersionResource) String() string { // GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying // concepts during lookup stages without having partially valid types -// -// +protobuf.options.(gogoproto.goproto_stringer)=false type GroupKind struct { - Group string `protobuf:"bytes,1,opt,name=group"` - Kind string `protobuf:"bytes,2,opt,name=kind"` + Group string + Kind string } func (gk GroupKind) Empty() bool { @@ -122,13 +115,11 @@ func (gk *GroupKind) String() string { } // GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion -// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling -// -// +protobuf.options.(gogoproto.goproto_stringer)=false +// to avoid automatic coercion. It doesn't use a GroupVersion to avoid custom marshalling type GroupVersionKind struct { - Group string `protobuf:"bytes,1,opt,name=group"` - Version string `protobuf:"bytes,2,opt,name=version"` - Kind string `protobuf:"bytes,3,opt,name=kind"` + Group string + Version string + Kind string } // Empty returns true if group, version, and kind are empty @@ -149,11 +140,9 @@ func (gvk GroupVersionKind) String() string { } // GroupVersion contains the "group" and the "version", which uniquely identifies the API. -// -// +protobuf.options.(gogoproto.goproto_stringer)=false type GroupVersion struct { - Group string `protobuf:"bytes,1,opt,name=group"` - Version string `protobuf:"bytes,2,opt,name=version"` + Group string + Version string } // Empty returns true if group and version are empty @@ -228,38 +217,6 @@ func (gv GroupVersion) WithResource(resource string) GroupVersionResource { return GroupVersionResource{Group: gv.Group, Version: gv.Version, Resource: resource} } -// MarshalJSON implements the json.Marshaller interface. -func (gv GroupVersion) MarshalJSON() ([]byte, error) { - s := gv.String() - if strings.Count(s, "/") > 1 { - return []byte{}, fmt.Errorf("illegal GroupVersion %v: contains more than one /", s) - } - return json.Marshal(s) -} - -func (gv *GroupVersion) unmarshal(value []byte) error { - var s string - if err := json.Unmarshal(value, &s); err != nil { - return err - } - parsed, err := ParseGroupVersion(s) - if err != nil { - return err - } - *gv = parsed - return nil -} - -// UnmarshalJSON implements the json.Unmarshaller interface. -func (gv *GroupVersion) UnmarshalJSON(value []byte) error { - return gv.unmarshal(value) -} - -// UnmarshalTEXT implements the Ugorji's encoding.TextUnmarshaler interface. -func (gv *GroupVersion) UnmarshalText(value []byte) error { - return gv.unmarshal(value) -} - // GroupVersions can be used to represent a set of desired group versions. // TODO: Move GroupVersions to a package under pkg/runtime, since it's used by scheme. // TODO: Introduce an adapter type between GroupVersions and runtime.GroupVersioner, and use LegacyCodec(GroupVersion) @@ -318,28 +275,3 @@ func FromAPIVersionAndKind(apiVersion, kind string) GroupVersionKind { } return GroupVersionKind{Kind: kind} } - -// All objects that are serialized from a Scheme encode their type information. This interface is used -// by serialization to set type information from the Scheme onto the serialized version of an object. -// For objects that cannot be serialized or have unique requirements, this interface may be a no-op. -// TODO: this belongs in pkg/runtime, move unversioned.GVK into runtime. -type ObjectKind interface { - // SetGroupVersionKind sets or clears the intended serialized kind of an object. Passing kind nil - // should clear the current setting. - SetGroupVersionKind(kind GroupVersionKind) - // GroupVersionKind returns the stored group, version, and kind of an object, or nil if the object does - // not expose or provide these fields. - GroupVersionKind() GroupVersionKind -} - -// EmptyObjectKind implements the ObjectKind interface as a noop -// TODO: this belongs in pkg/runtime, move unversioned.GVK into runtime. -var EmptyObjectKind = emptyObjectKind{} - -type emptyObjectKind struct{} - -// SetGroupVersionKind implements the ObjectKind interface -func (emptyObjectKind) SetGroupVersionKind(gvk GroupVersionKind) {} - -// GroupVersionKind implements the ObjectKind interface -func (emptyObjectKind) GroupVersionKind() GroupVersionKind { return GroupVersionKind{} } diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/schema/interfaces.go b/vendor/k8s.io/apimachinery/pkg/runtime/schema/interfaces.go new file mode 100644 index 0000000000..b570668458 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/schema/interfaces.go @@ -0,0 +1,40 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package schema + +// All objects that are serialized from a Scheme encode their type information. This interface is used +// by serialization to set type information from the Scheme onto the serialized version of an object. +// For objects that cannot be serialized or have unique requirements, this interface may be a no-op. +type ObjectKind interface { + // SetGroupVersionKind sets or clears the intended serialized kind of an object. Passing kind nil + // should clear the current setting. + SetGroupVersionKind(kind GroupVersionKind) + // GroupVersionKind returns the stored group, version, and kind of an object, or nil if the object does + // not expose or provide these fields. + GroupVersionKind() GroupVersionKind +} + +// EmptyObjectKind implements the ObjectKind interface as a noop +var EmptyObjectKind = emptyObjectKind{} + +type emptyObjectKind struct{} + +// SetGroupVersionKind implements the ObjectKind interface +func (emptyObjectKind) SetGroupVersionKind(gvk GroupVersionKind) {} + +// GroupVersionKind implements the ObjectKind interface +func (emptyObjectKind) GroupVersionKind() GroupVersionKind { return GroupVersionKind{} } diff --git a/vendor/k8s.io/client-go/pkg/runtime/scheme.go b/vendor/k8s.io/apimachinery/pkg/runtime/scheme.go similarity index 86% rename from vendor/k8s.io/client-go/pkg/runtime/scheme.go rename to vendor/k8s.io/apimachinery/pkg/runtime/scheme.go index b191e5fb42..6c9475fa0d 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/scheme.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/scheme.go @@ -21,8 +21,8 @@ import ( "net/url" "reflect" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime/schema" ) // Scheme defines methods for serializing and deserializing API objects, a type @@ -43,14 +43,14 @@ import ( type Scheme struct { // versionMap allows one to figure out the go type of an object with // the given version and name. - gvkToType map[unversioned.GroupVersionKind]reflect.Type + gvkToType map[schema.GroupVersionKind]reflect.Type // typeToGroupVersion allows one to find metadata for a given go object. // The reflect.Type we index by should *not* be a pointer. - typeToGVK map[reflect.Type][]unversioned.GroupVersionKind + typeToGVK map[reflect.Type][]schema.GroupVersionKind // unversionedTypes are transformed without conversion in ConvertToVersion. - unversionedTypes map[reflect.Type]unversioned.GroupVersionKind + unversionedTypes map[reflect.Type]schema.GroupVersionKind // unversionedKinds are the names of kinds that can be created in the context of any group // or version @@ -80,9 +80,9 @@ type FieldLabelConversionFunc func(label, value string) (internalLabel, internal // NewScheme creates a new Scheme. This scheme is pluggable by default. func NewScheme() *Scheme { s := &Scheme{ - gvkToType: map[unversioned.GroupVersionKind]reflect.Type{}, - typeToGVK: map[reflect.Type][]unversioned.GroupVersionKind{}, - unversionedTypes: map[reflect.Type]unversioned.GroupVersionKind{}, + gvkToType: map[schema.GroupVersionKind]reflect.Type{}, + typeToGVK: map[reflect.Type][]schema.GroupVersionKind{}, + unversionedTypes: map[reflect.Type]schema.GroupVersionKind{}, unversionedKinds: map[string]reflect.Type{}, cloner: conversion.NewCloner(), fieldLabelConversionFuncs: map[string]map[string]FieldLabelConversionFunc{}, @@ -145,14 +145,14 @@ func (s *Scheme) Converter() *conversion.Converter { // // TODO: there is discussion about removing unversioned and replacing it with objects that are manifest into // every version with particular schemas. Resolve this method at that point. -func (s *Scheme) AddUnversionedTypes(version unversioned.GroupVersion, types ...Object) { +func (s *Scheme) AddUnversionedTypes(version schema.GroupVersion, types ...Object) { s.AddKnownTypes(version, types...) for _, obj := range types { t := reflect.TypeOf(obj).Elem() gvk := version.WithKind(t.Name()) s.unversionedTypes[t] = gvk - if _, ok := s.unversionedKinds[gvk.Kind]; ok { - panic(fmt.Sprintf("%v has already been registered as unversioned kind %q - kind name must be unique", reflect.TypeOf(t), gvk.Kind)) + if old, ok := s.unversionedKinds[gvk.Kind]; ok && t != old { + panic(fmt.Sprintf("%v.%v has already been registered as unversioned kind %q - kind name must be unique", old.PkgPath(), old.Name(), gvk)) } s.unversionedKinds[gvk.Kind] = t } @@ -162,23 +162,14 @@ func (s *Scheme) AddUnversionedTypes(version unversioned.GroupVersion, types ... // All objects passed to types should be pointers to structs. The name that go reports for // the struct becomes the "kind" field when encoding. Version may not be empty - use the // APIVersionInternal constant if you have a type that does not have a formal version. -func (s *Scheme) AddKnownTypes(gv unversioned.GroupVersion, types ...Object) { - if len(gv.Version) == 0 { - panic(fmt.Sprintf("version is required on all types: %s %v", gv, types[0])) - } +func (s *Scheme) AddKnownTypes(gv schema.GroupVersion, types ...Object) { for _, obj := range types { t := reflect.TypeOf(obj) if t.Kind() != reflect.Ptr { panic("All types must be pointers to structs.") } t = t.Elem() - if t.Kind() != reflect.Struct { - panic("All types must be pointers to structs.") - } - - gvk := gv.WithKind(t.Name()) - s.gvkToType[gvk] = t - s.typeToGVK[t] = append(s.typeToGVK[t], gvk) + s.AddKnownTypeWithName(gv.WithKind(t.Name()), obj) } } @@ -186,7 +177,7 @@ func (s *Scheme) AddKnownTypes(gv unversioned.GroupVersion, types ...Object) { // be encoded as. Useful for testing when you don't want to make multiple packages to define // your structs. Version may not be empty - use the APIVersionInternal constant if you have a // type that does not have a formal version. -func (s *Scheme) AddKnownTypeWithName(gvk unversioned.GroupVersionKind, obj Object) { +func (s *Scheme) AddKnownTypeWithName(gvk schema.GroupVersionKind, obj Object) { t := reflect.TypeOf(obj) if len(gvk.Version) == 0 { panic(fmt.Sprintf("version is required on all types: %s %v", gvk, t)) @@ -199,12 +190,22 @@ func (s *Scheme) AddKnownTypeWithName(gvk unversioned.GroupVersionKind, obj Obje panic("All types must be pointers to structs.") } + if oldT, found := s.gvkToType[gvk]; found && oldT != t { + panic(fmt.Sprintf("Double registration of different types for %v: old=%v.%v, new=%v.%v", gvk, oldT.PkgPath(), oldT.Name(), t.PkgPath(), t.Name())) + } + s.gvkToType[gvk] = t + + for _, existingGvk := range s.typeToGVK[t] { + if existingGvk == gvk { + return + } + } s.typeToGVK[t] = append(s.typeToGVK[t], gvk) } // KnownTypes returns the types known for the given version. -func (s *Scheme) KnownTypes(gv unversioned.GroupVersion) map[string]reflect.Type { +func (s *Scheme) KnownTypes(gv schema.GroupVersion) map[string]reflect.Type { types := make(map[string]reflect.Type) for gvk, t := range s.gvkToType { if gv != gvk.GroupVersion() { @@ -217,23 +218,23 @@ func (s *Scheme) KnownTypes(gv unversioned.GroupVersion) map[string]reflect.Type } // AllKnownTypes returns the all known types. -func (s *Scheme) AllKnownTypes() map[unversioned.GroupVersionKind]reflect.Type { +func (s *Scheme) AllKnownTypes() map[schema.GroupVersionKind]reflect.Type { return s.gvkToType } // ObjectKind returns the group,version,kind of the go object and true if this object // is considered unversioned, or an error if it's not a pointer or is unregistered. -func (s *Scheme) ObjectKind(obj Object) (unversioned.GroupVersionKind, bool, error) { +func (s *Scheme) ObjectKind(obj Object) (schema.GroupVersionKind, bool, error) { gvks, unversionedType, err := s.ObjectKinds(obj) if err != nil { - return unversioned.GroupVersionKind{}, false, err + return schema.GroupVersionKind{}, false, err } return gvks[0], unversionedType, nil } // ObjectKinds returns all possible group,version,kind of the go object, true if the // object is considered unversioned, or an error if it's not a pointer or is unregistered. -func (s *Scheme) ObjectKinds(obj Object) ([]unversioned.GroupVersionKind, bool, error) { +func (s *Scheme) ObjectKinds(obj Object) ([]schema.GroupVersionKind, bool, error) { v, err := conversion.EnforcePtr(obj) if err != nil { return nil, false, err @@ -242,7 +243,7 @@ func (s *Scheme) ObjectKinds(obj Object) ([]unversioned.GroupVersionKind, bool, gvks, ok := s.typeToGVK[t] if !ok { - return nil, false, NewNotRegisteredErr(unversioned.GroupVersionKind{}, t) + return nil, false, NewNotRegisteredErrForType(t) } _, unversionedType := s.unversionedTypes[t] @@ -251,7 +252,7 @@ func (s *Scheme) ObjectKinds(obj Object) ([]unversioned.GroupVersionKind, bool, // Recognizes returns true if the scheme is able to handle the provided group,version,kind // of an object. -func (s *Scheme) Recognizes(gvk unversioned.GroupVersionKind) bool { +func (s *Scheme) Recognizes(gvk schema.GroupVersionKind) bool { _, exists := s.gvkToType[gvk] return exists } @@ -272,7 +273,7 @@ func (s *Scheme) IsUnversioned(obj Object) (bool, bool) { // New returns a new API object of the given version and name, or an error if it hasn't // been registered. The version and kind fields must be specified. -func (s *Scheme) New(kind unversioned.GroupVersionKind) (Object, error) { +func (s *Scheme) New(kind schema.GroupVersionKind) (Object, error) { if t, exists := s.gvkToType[kind]; exists { return reflect.New(t).Interface().(Object), nil } @@ -280,7 +281,7 @@ func (s *Scheme) New(kind unversioned.GroupVersionKind) (Object, error) { if t, exists := s.unversionedKinds[kind.Kind]; exists { return reflect.New(t).Interface().(Object), nil } - return nil, NewNotRegisteredErr(kind, nil) + return nil, NewNotRegisteredErrForKind(kind) } // AddGenericConversionFunc adds a function that accepts the ConversionFunc call pattern @@ -403,29 +404,6 @@ func (s *Scheme) RegisterInputDefaults(in interface{}, fn conversion.FieldMappin return s.converter.RegisterInputDefaults(in, fn, defaultFlags) } -// AddDefaultingFuncs adds functions to the list of default-value functions. -// Each of the given functions is responsible for applying default values -// when converting an instance of a versioned API object into an internal -// API object. These functions do not need to handle sub-objects. We deduce -// how to call these functions from the types of their two parameters. -// -// s.AddDefaultingFuncs( -// func(obj *v1.Pod) { -// if obj.OptionalField == "" { -// obj.OptionalField = "DefaultValue" -// } -// }, -// ) -func (s *Scheme) AddDefaultingFuncs(defaultingFuncs ...interface{}) error { - for _, f := range defaultingFuncs { - err := s.converter.RegisterDefaultingFunc(f) - if err != nil { - return err - } - } - return nil -} - // AddTypeDefaultingFuncs registers a function that is passed a pointer to an // object and can default fields on the object. These functions will be invoked // when Default() is called. The function will never be called unless the @@ -514,7 +492,7 @@ func (s *Scheme) convertToVersion(copy bool, in Object, target GroupVersioner) ( } kinds, ok := s.typeToGVK[t] if !ok || len(kinds) == 0 { - return nil, NewNotRegisteredErr(unversioned.GroupVersionKind{}, t) + return nil, NewNotRegisteredErrForType(t) } gvk, ok := target.KindForGroupVersionKinds(kinds) @@ -522,14 +500,13 @@ func (s *Scheme) convertToVersion(copy bool, in Object, target GroupVersioner) ( // try to see if this type is listed as unversioned (for legacy support) // TODO: when we move to server API versions, we should completely remove the unversioned concept if unversionedKind, ok := s.unversionedTypes[t]; ok { - if gvk, ok := target.KindForGroupVersionKinds([]unversioned.GroupVersionKind{unversionedKind}); ok { + if gvk, ok := target.KindForGroupVersionKinds([]schema.GroupVersionKind{unversionedKind}); ok { return copyAndSetTargetKind(copy, s, in, gvk) } return copyAndSetTargetKind(copy, s, in, unversionedKind) } - // TODO: should this be a typed error? - return nil, fmt.Errorf("%v is not suitable for converting to %q", t, target) + return nil, NewNotRegisteredErrForTarget(t, target) } // target wants to use the existing type, set kind and return (no conversion necessary) @@ -541,7 +518,7 @@ func (s *Scheme) convertToVersion(copy bool, in Object, target GroupVersioner) ( // type is unversioned, no conversion necessary if unversionedKind, ok := s.unversionedTypes[t]; ok { - if gvk, ok := target.KindForGroupVersionKinds([]unversioned.GroupVersionKind{unversionedKind}); ok { + if gvk, ok := target.KindForGroupVersionKinds([]schema.GroupVersionKind{unversionedKind}); ok { return copyAndSetTargetKind(copy, s, in, gvk) } return copyAndSetTargetKind(copy, s, in, unversionedKind) @@ -576,7 +553,7 @@ func (s *Scheme) generateConvertMeta(in interface{}) (conversion.FieldMatchingFl } // copyAndSetTargetKind performs a conditional copy before returning the object, or an error if copy was not successful. -func copyAndSetTargetKind(copy bool, copier ObjectCopier, obj Object, kind unversioned.GroupVersionKind) (Object, error) { +func copyAndSetTargetKind(copy bool, copier ObjectCopier, obj Object, kind schema.GroupVersionKind) (Object, error) { if copy { copied, err := copier.Copy(obj) if err != nil { @@ -589,11 +566,11 @@ func copyAndSetTargetKind(copy bool, copier ObjectCopier, obj Object, kind unver } // setTargetKind sets the kind on an object, taking into account whether the target kind is the internal version. -func setTargetKind(obj Object, kind unversioned.GroupVersionKind) { +func setTargetKind(obj Object, kind schema.GroupVersionKind) { if kind.Version == APIVersionInternal { // internal is a special case // TODO: look at removing the need to special case this - obj.GetObjectKind().SetGroupVersionKind(unversioned.GroupVersionKind{}) + obj.GetObjectKind().SetGroupVersionKind(schema.GroupVersionKind{}) return } obj.GetObjectKind().SetGroupVersionKind(kind) diff --git a/vendor/k8s.io/client-go/pkg/runtime/scheme_builder.go b/vendor/k8s.io/apimachinery/pkg/runtime/scheme_builder.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/runtime/scheme_builder.go rename to vendor/k8s.io/apimachinery/pkg/runtime/scheme_builder.go diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/serializer/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/BUILD new file mode 100644 index 0000000000..d27fbabb8b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/BUILD @@ -0,0 +1,44 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["codec_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/ghodss/yaml:go_default_library", + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "codec_factory.go", + "negotiated_codec.go", + "protobuf_extension.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/json:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/codec_factory.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/codec_factory.go similarity index 93% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/codec_factory.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/codec_factory.go index 69f56bb610..65f451124d 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/codec_factory.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/codec_factory.go @@ -17,11 +17,11 @@ limitations under the License. package serializer import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/json" - "k8s.io/client-go/pkg/runtime/serializer/recognizer" - "k8s.io/client-go/pkg/runtime/serializer/versioning" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer/json" + "k8s.io/apimachinery/pkg/runtime/serializer/recognizer" + "k8s.io/apimachinery/pkg/runtime/serializer/versioning" ) // serializerExtensions are for serializers that are conditionally compiled in @@ -162,8 +162,8 @@ func (f CodecFactory) SupportedMediaTypes() []runtime.SerializerInfo { // // TODO: make this call exist only in pkg/api, and initialize it with the set of default versions. // All other callers will be forced to request a Codec directly. -func (f CodecFactory) LegacyCodec(version ...unversioned.GroupVersion) runtime.Codec { - return versioning.NewDefaultingCodecForScheme(f.scheme, f.legacySerializer, f.universal, unversioned.GroupVersions(version), runtime.InternalGroupVersioner) +func (f CodecFactory) LegacyCodec(version ...schema.GroupVersion) runtime.Codec { + return versioning.NewDefaultingCodecForScheme(f.scheme, f.legacySerializer, f.universal, schema.GroupVersions(version), runtime.InternalGroupVersioner) } // UniversalDeserializer can convert any stored data recognized by this factory into a Go object that satisfies @@ -181,12 +181,12 @@ func (f CodecFactory) UniversalDeserializer() runtime.Decoder { // // TODO: the decoder will eventually be removed in favor of dealing with objects in their versioned form // TODO: only accept a group versioner -func (f CodecFactory) UniversalDecoder(versions ...unversioned.GroupVersion) runtime.Decoder { +func (f CodecFactory) UniversalDecoder(versions ...schema.GroupVersion) runtime.Decoder { var versioner runtime.GroupVersioner if len(versions) == 0 { versioner = runtime.InternalGroupVersioner } else { - versioner = unversioned.GroupVersions(versions) + versioner = schema.GroupVersions(versions) } return f.CodecForVersions(nil, f.universal, nil, versioner) } @@ -220,9 +220,10 @@ type DirectCodecFactory struct { CodecFactory } -// EncoderForVersion returns an encoder that does not do conversion. gv is ignored. -func (f DirectCodecFactory) EncoderForVersion(serializer runtime.Encoder, _ runtime.GroupVersioner) runtime.Encoder { +// EncoderForVersion returns an encoder that does not do conversion. +func (f DirectCodecFactory) EncoderForVersion(serializer runtime.Encoder, version runtime.GroupVersioner) runtime.Encoder { return versioning.DirectEncoder{ + Version: version, Encoder: serializer, ObjectTyper: f.CodecFactory.scheme, } diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/BUILD new file mode 100644 index 0000000000..6ee9e72b2b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/BUILD @@ -0,0 +1,46 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["meta_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "json.go", + "meta.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/ghodss/yaml:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/framer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/yaml:go_default_library", + ], +) + +go_test( + name = "go_default_xtest", + srcs = ["json_test.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/json:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/json/json.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/json.go similarity index 94% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/json/json.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/json.go index 2f2f69fbbd..28bb91b533 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/json/json.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/json.go @@ -23,11 +23,11 @@ import ( "github.com/ghodss/yaml" "github.com/ugorji/go/codec" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/recognizer" - "k8s.io/client-go/pkg/util/framer" - utilyaml "k8s.io/client-go/pkg/util/yaml" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer/recognizer" + "k8s.io/apimachinery/pkg/util/framer" + utilyaml "k8s.io/apimachinery/pkg/util/yaml" ) // NewSerializer creates a JSON serializer that handles encoding versioned objects into the proper JSON form. If typer @@ -71,7 +71,7 @@ var _ recognizer.RecognizingDecoder = &Serializer{} // extracted and no decoding will be performed. If into is not registered with the typer, then the object will be straight decoded using // normal JSON/YAML unmarshalling. If into is provided and the original data is not fully qualified with kind/version/group, the type of // the into will be used to alter the returned gvk. On success or most errors, the method will return the calculated schema kind. -func (s *Serializer) Decode(originalData []byte, gvk *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (s *Serializer) Decode(originalData []byte, gvk *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { if versioned, ok := into.(*runtime.VersionedObjects); ok { into = versioned.Last() obj, actual, err := s.Decode(originalData, gvk, into) @@ -194,7 +194,7 @@ func (s *Serializer) RecognizesData(peek io.Reader) (ok, unknown bool, err error // we could potentially look for '---' return false, true, nil } - _, ok = utilyaml.GuessJSONStream(peek, 2048) + _, _, ok = utilyaml.GuessJSONStream(peek, 2048) return ok, false, nil } diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/json/meta.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/meta.go similarity index 84% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/json/meta.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/meta.go index 325df63d33..df3f5f989a 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/json/meta.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/json/meta.go @@ -20,7 +20,7 @@ import ( "encoding/json" "fmt" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) // MetaFactory is used to store and retrieve the version and kind @@ -28,7 +28,7 @@ import ( type MetaFactory interface { // Interpret should return the version and kind of the wire-format of // the object. - Interpret(data []byte) (*unversioned.GroupVersionKind, error) + Interpret(data []byte) (*schema.GroupVersionKind, error) } // DefaultMetaFactory is a default factory for versioning objects in JSON. The object @@ -45,7 +45,7 @@ type SimpleMetaFactory struct { // Interpret will return the APIVersion and Kind of the JSON wire-format // encoding of an object, or an error. -func (SimpleMetaFactory) Interpret(data []byte) (*unversioned.GroupVersionKind, error) { +func (SimpleMetaFactory) Interpret(data []byte) (*schema.GroupVersionKind, error) { findKind := struct { // +optional APIVersion string `json:"apiVersion,omitempty"` @@ -55,9 +55,9 @@ func (SimpleMetaFactory) Interpret(data []byte) (*unversioned.GroupVersionKind, if err := json.Unmarshal(data, &findKind); err != nil { return nil, fmt.Errorf("couldn't get version/kind; json parse error: %v", err) } - gv, err := unversioned.ParseGroupVersion(findKind.APIVersion) + gv, err := schema.ParseGroupVersion(findKind.APIVersion) if err != nil { return nil, err } - return &unversioned.GroupVersionKind{Group: gv.Group, Version: gv.Version, Kind: findKind.Kind}, nil + return &schema.GroupVersionKind{Group: gv.Group, Version: gv.Version, Kind: findKind.Kind}, nil } diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/negotiated_codec.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/negotiated_codec.go similarity index 97% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/negotiated_codec.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/negotiated_codec.go index 95e3dd3a5a..a42b4a41a8 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/negotiated_codec.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/negotiated_codec.go @@ -17,7 +17,7 @@ limitations under the License. package serializer import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) // TODO: We should split negotiated serializers that we can change versions on from those we can change diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/BUILD new file mode 100644 index 0000000000..dcb895f872 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/BUILD @@ -0,0 +1,24 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "protobuf.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/framer:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf/doc.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf/doc.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/doc.go diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf/protobuf.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/protobuf.go similarity index 94% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf/protobuf.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/protobuf.go index 0118828eee..8d4ea71180 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf/protobuf.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf/protobuf.go @@ -24,10 +24,10 @@ import ( "github.com/gogo/protobuf/proto" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/recognizer" - "k8s.io/client-go/pkg/util/framer" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer/recognizer" + "k8s.io/apimachinery/pkg/util/framer" ) var ( @@ -36,7 +36,7 @@ var ( // byte being reserved for the encoding style. The only encoding style defined is 0x00, which means that // the rest of the byte stream is a message of type k8s.io.kubernetes.pkg.runtime.Unknown (proto2). // - // See k8s.io/kubernetes/pkg/runtime/generated.proto for details of the runtime.Unknown message. + // See k8s.io/apimachinery/pkg/runtime/generated.proto for details of the runtime.Unknown message. // // This encoding scheme is experimental, and is subject to change at any time. protoEncodingPrefix = []byte{0x6b, 0x38, 0x73, 0x00} @@ -85,7 +85,7 @@ var _ recognizer.RecognizingDecoder = &Serializer{} // be straight decoded using normal protobuf unmarshalling (the MarshalTo interface). If into is provided and the original data is // not fully qualified with kind/version/group, the type of the into will be used to alter the returned gvk. On success or most // errors, the method will return the calculated schema kind. -func (s *Serializer) Decode(originalData []byte, gvk *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (s *Serializer) Decode(originalData []byte, gvk *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { if versioned, ok := into.(*runtime.VersionedObjects); ok { into = versioned.Last() obj, actual, err := s.Decode(originalData, gvk, into) @@ -255,7 +255,7 @@ func (s *Serializer) RecognizesData(peek io.Reader) (bool, bool, error) { } // copyKindDefaults defaults dst to the value in src if dst does not have a value set. -func copyKindDefaults(dst, src *unversioned.GroupVersionKind) { +func copyKindDefaults(dst, src *schema.GroupVersionKind) { if src == nil { return } @@ -316,7 +316,7 @@ var _ runtime.Serializer = &RawSerializer{} // be straight decoded using normal protobuf unmarshalling (the MarshalTo interface). If into is provided and the original data is // not fully qualified with kind/version/group, the type of the into will be used to alter the returned gvk. On success or most // errors, the method will return the calculated schema kind. -func (s *RawSerializer) Decode(originalData []byte, gvk *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (s *RawSerializer) Decode(originalData []byte, gvk *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { if into == nil { return nil, nil, fmt.Errorf("this serializer requires an object to decode into: %#v", s) } @@ -341,7 +341,7 @@ func (s *RawSerializer) Decode(originalData []byte, gvk *unversioned.GroupVersio } data := originalData - actual := &unversioned.GroupVersionKind{} + actual := &schema.GroupVersionKind{} copyKindDefaults(actual, gvk) if intoUnknown, ok := into.(*runtime.Unknown); ok && intoUnknown != nil { @@ -386,7 +386,7 @@ func (s *RawSerializer) Decode(originalData []byte, gvk *unversioned.GroupVersio } // unmarshalToObject is the common code between decode in the raw and normal serializer. -func unmarshalToObject(typer runtime.ObjectTyper, creater runtime.ObjectCreater, actual *unversioned.GroupVersionKind, into runtime.Object, data []byte) (runtime.Object, *unversioned.GroupVersionKind, error) { +func unmarshalToObject(typer runtime.ObjectTyper, creater runtime.ObjectCreater, actual *schema.GroupVersionKind, into runtime.Object, data []byte) (runtime.Object, *schema.GroupVersionKind, error) { // use the target if necessary obj, err := runtime.UseOrCreateObject(typer, creater, *actual, into) if err != nil { diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf_extension.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf_extension.go similarity index 94% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf_extension.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf_extension.go index fa525a372c..545cf78df7 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/protobuf_extension.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/protobuf_extension.go @@ -17,8 +17,8 @@ limitations under the License. package serializer import ( - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/protobuf" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/serializer/protobuf" ) const ( diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/BUILD new file mode 100644 index 0000000000..9cf147c8c7 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/BUILD @@ -0,0 +1,18 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["recognizer.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/recognizer/recognizer.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/recognizer.go similarity index 93% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/recognizer/recognizer.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/recognizer.go index 54d978fb30..38497ab533 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/recognizer/recognizer.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/recognizer/recognizer.go @@ -22,8 +22,8 @@ import ( "fmt" "io" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) type RecognizingDecoder interface { @@ -81,7 +81,7 @@ func (d *decoder) RecognizesData(peek io.Reader) (bool, bool, error) { return false, anyUnknown, lastErr } -func (d *decoder) Decode(data []byte, gvk *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (d *decoder) Decode(data []byte, gvk *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { var ( lastErr error skipped []runtime.Decoder diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/BUILD new file mode 100644 index 0000000000..069f663010 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["streaming_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/framer:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["streaming.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/streaming/streaming.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/streaming.go similarity index 91% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/streaming/streaming.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/streaming.go index 9b91f1ba83..91fd4ed4f0 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/streaming/streaming.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming/streaming.go @@ -23,8 +23,8 @@ import ( "fmt" "io" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // Encoder is a runtime.Encoder on a stream. @@ -37,7 +37,7 @@ type Encoder interface { // Decoder is a runtime.Decoder from a stream. type Decoder interface { // Decode will return io.EOF when no more objects are available. - Decode(defaults *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) + Decode(defaults *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) // Close closes the underlying stream. Close() error } @@ -71,7 +71,7 @@ func NewDecoder(r io.ReadCloser, d runtime.Decoder) Decoder { var ErrObjectTooLarge = fmt.Errorf("object to decode was longer than maximum allowed size") // Decode reads the next object from the stream and decodes it. -func (d *decoder) Decode(defaults *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (d *decoder) Decode(defaults *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { base := 0 for { n, err := d.reader.Read(d.buf[base:]) diff --git a/vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/BUILD b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/BUILD new file mode 100644 index 0000000000..393000bc5b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/BUILD @@ -0,0 +1,32 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["versioning_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = ["versioning.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/runtime/serializer/versioning/versioning.go b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/versioning.go similarity index 91% rename from vendor/k8s.io/client-go/pkg/runtime/serializer/versioning/versioning.go rename to vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/versioning.go index 386397f08a..829d4fa895 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/serializer/versioning/versioning.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning/versioning.go @@ -19,9 +19,9 @@ package versioning import ( "io" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - utilruntime "k8s.io/client-go/pkg/util/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" ) // NewCodecForScheme is a convenience method for callers that are using a scheme. @@ -93,7 +93,7 @@ type codec struct { // Decode attempts a decode of the object, then tries to convert it to the internal version. If into is provided and the decoding is // successful, the returned runtime.Object will be the value passed as into. Note that this may bypass conversion if you pass an // into that matches the serialized version. -func (c *codec) Decode(data []byte, defaultGVK *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (c *codec) Decode(data []byte, defaultGVK *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { versioned, isVersioned := into.(*runtime.VersionedObjects) if isVersioned { into = versioned.Last() @@ -181,7 +181,7 @@ func (c *codec) Decode(data []byte, defaultGVK *unversioned.GroupVersionKind, in // conversion if necessary. Unversioned objects (according to the ObjectTyper) are output as is. func (c *codec) Encode(obj runtime.Object, w io.Writer) error { switch obj.(type) { - case *runtime.Unknown, *runtime.Unstructured, *runtime.UnstructuredList: + case *runtime.Unknown, runtime.Unstructured: return c.encoder.Encode(obj, w) } @@ -227,6 +227,7 @@ func (c *codec) Encode(obj runtime.Object, w io.Writer) error { // DirectEncoder serializes an object and ensures the GVK is set. type DirectEncoder struct { + Version runtime.GroupVersioner runtime.Encoder runtime.ObjectTyper } @@ -242,7 +243,14 @@ func (e DirectEncoder) Encode(obj runtime.Object, stream io.Writer) error { } kind := obj.GetObjectKind() oldGVK := kind.GroupVersionKind() - kind.SetGroupVersionKind(gvks[0]) + gvk := gvks[0] + if e.Version != nil { + preferredGVK, ok := e.Version.KindForGroupVersionKinds(gvks) + if ok { + gvk = preferredGVK + } + } + kind.SetGroupVersionKind(gvk) err = e.Encoder.Encode(obj, stream) kind.SetGroupVersionKind(oldGVK) return err @@ -254,12 +262,12 @@ type DirectDecoder struct { } // Decode does not do conversion. It removes the gvk during deserialization. -func (d DirectDecoder) Decode(data []byte, defaults *unversioned.GroupVersionKind, into runtime.Object) (runtime.Object, *unversioned.GroupVersionKind, error) { +func (d DirectDecoder) Decode(data []byte, defaults *schema.GroupVersionKind, into runtime.Object) (runtime.Object, *schema.GroupVersionKind, error) { obj, gvk, err := d.Decoder.Decode(data, defaults, into) if obj != nil { kind := obj.GetObjectKind() // clearing the gvk is just a convention of a codec - kind.SetGroupVersionKind(unversioned.GroupVersionKind{}) + kind.SetGroupVersionKind(schema.GroupVersionKind{}) } return obj, gvk, err } diff --git a/vendor/k8s.io/client-go/pkg/runtime/swagger_doc_generator.go b/vendor/k8s.io/apimachinery/pkg/runtime/swagger_doc_generator.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/runtime/swagger_doc_generator.go rename to vendor/k8s.io/apimachinery/pkg/runtime/swagger_doc_generator.go diff --git a/vendor/k8s.io/client-go/pkg/runtime/types.go b/vendor/k8s.io/apimachinery/pkg/runtime/types.go similarity index 87% rename from vendor/k8s.io/client-go/pkg/runtime/types.go rename to vendor/k8s.io/apimachinery/pkg/runtime/types.go index ceffdd9f77..f972c5e697 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/types.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/types.go @@ -25,7 +25,7 @@ package runtime // runtime.TypeMeta `json:",inline"` // ... // other fields // } -// func (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *unversioned.GroupVersionKind) { unversioned.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind +// func (obj *MyAwesomeAPIObject) SetGroupVersionKind(gvk *metav1.GroupVersionKind) { metav1.UpdateTypeMeta(obj,gvk) }; GroupVersionKind() *GroupVersionKind // // TypeMeta is provided here for convenience. You may use it directly from this package or define // your own with the same fields. @@ -122,17 +122,6 @@ type Unknown struct { ContentType string `protobuf:"bytes,4,opt,name=contentType"` } -// Unstructured allows objects that do not have Golang structs registered to be manipulated -// generically. This can be used to deal with the API objects from a plug-in. Unstructured -// objects still have functioning TypeMeta features-- kind, version, etc. -// TODO: Make this object have easy access to field based accessors and settors for -// metadata and field mutatation. -type Unstructured struct { - // Object is a JSON compatible map with string, float, int, []interface{}, or map[string]interface{} - // children. - Object map[string]interface{} -} - // VersionedObjects is used by Decoders to give callers a way to access all versions // of an object during the decoding process. type VersionedObjects struct { diff --git a/vendor/k8s.io/client-go/pkg/runtime/types_proto.go b/vendor/k8s.io/apimachinery/pkg/runtime/types_proto.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/runtime/types_proto.go rename to vendor/k8s.io/apimachinery/pkg/runtime/types_proto.go diff --git a/vendor/k8s.io/client-go/pkg/runtime/zz_generated.deepcopy.go b/vendor/k8s.io/apimachinery/pkg/runtime/zz_generated.deepcopy.go similarity index 58% rename from vendor/k8s.io/client-go/pkg/runtime/zz_generated.deepcopy.go rename to vendor/k8s.io/apimachinery/pkg/runtime/zz_generated.deepcopy.go index 09bf660025..54ce6ad59e 100644 --- a/vendor/k8s.io/client-go/pkg/runtime/zz_generated.deepcopy.go +++ b/vendor/k8s.io/apimachinery/pkg/runtime/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,55 +21,63 @@ limitations under the License. package runtime import ( - conversion "k8s.io/client-go/pkg/conversion" + conversion "k8s.io/apimachinery/pkg/conversion" + reflect "reflect" ) +// GetGeneratedDeepCopyFuncs returns the generated funcs, since we aren't registering them. +func GetGeneratedDeepCopyFuncs() []conversion.GeneratedDeepCopyFunc { + return []conversion.GeneratedDeepCopyFunc{ + {Fn: DeepCopy_runtime_RawExtension, InType: reflect.TypeOf(&RawExtension{})}, + {Fn: DeepCopy_runtime_TypeMeta, InType: reflect.TypeOf(&TypeMeta{})}, + {Fn: DeepCopy_runtime_Unknown, InType: reflect.TypeOf(&Unknown{})}, + } +} + +// DeepCopy_runtime_RawExtension is an autogenerated deepcopy function. func DeepCopy_runtime_RawExtension(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RawExtension) out := out.(*RawExtension) + *out = *in if in.Raw != nil { in, out := &in.Raw, &out.Raw *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Raw = nil } - if in.Object == nil { - out.Object = nil - } else if newVal, err := c.DeepCopy(&in.Object); err != nil { - return err - } else { - out.Object = *newVal.(*Object) + // in.Object is kind 'Interface' + if in.Object != nil { + if newVal, err := c.DeepCopy(&in.Object); err != nil { + return err + } else { + out.Object = *newVal.(*Object) + } } return nil } } +// DeepCopy_runtime_TypeMeta is an autogenerated deepcopy function. func DeepCopy_runtime_TypeMeta(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TypeMeta) out := out.(*TypeMeta) - out.APIVersion = in.APIVersion - out.Kind = in.Kind + *out = *in return nil } } +// DeepCopy_runtime_Unknown is an autogenerated deepcopy function. func DeepCopy_runtime_Unknown(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Unknown) out := out.(*Unknown) - out.TypeMeta = in.TypeMeta + *out = *in if in.Raw != nil { in, out := &in.Raw, &out.Raw *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Raw = nil } - out.ContentEncoding = in.ContentEncoding - out.ContentType = in.ContentType return nil } } diff --git a/vendor/k8s.io/apimachinery/pkg/selection/BUILD b/vendor/k8s.io/apimachinery/pkg/selection/BUILD new file mode 100644 index 0000000000..55859fef69 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/selection/BUILD @@ -0,0 +1,14 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["operator.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/selection/operator.go b/vendor/k8s.io/apimachinery/pkg/selection/operator.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/selection/operator.go rename to vendor/k8s.io/apimachinery/pkg/selection/operator.go diff --git a/vendor/k8s.io/apimachinery/pkg/types/BUILD b/vendor/k8s.io/apimachinery/pkg/types/BUILD new file mode 100644 index 0000000000..f6dadfcca8 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/types/BUILD @@ -0,0 +1,20 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "namespacedname.go", + "nodename.go", + "patch.go", + "uid.go", + ], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/types/doc.go b/vendor/k8s.io/apimachinery/pkg/types/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/types/doc.go rename to vendor/k8s.io/apimachinery/pkg/types/doc.go diff --git a/vendor/k8s.io/client-go/pkg/types/namespacedname.go b/vendor/k8s.io/apimachinery/pkg/types/namespacedname.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/types/namespacedname.go rename to vendor/k8s.io/apimachinery/pkg/types/namespacedname.go diff --git a/vendor/k8s.io/client-go/pkg/types/nodename.go b/vendor/k8s.io/apimachinery/pkg/types/nodename.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/types/nodename.go rename to vendor/k8s.io/apimachinery/pkg/types/nodename.go diff --git a/vendor/k8s.io/client-go/pkg/util/jsonpath/doc.go b/vendor/k8s.io/apimachinery/pkg/types/patch.go similarity index 56% rename from vendor/k8s.io/client-go/pkg/util/jsonpath/doc.go rename to vendor/k8s.io/apimachinery/pkg/types/patch.go index 2a6e170617..d522d1dbdc 100644 --- a/vendor/k8s.io/client-go/pkg/util/jsonpath/doc.go +++ b/vendor/k8s.io/apimachinery/pkg/types/patch.go @@ -14,7 +14,15 @@ See the License for the specific language governing permissions and limitations under the License. */ -// package jsonpath is a template engine using jsonpath syntax, -// which can be seen at http://goessner.net/articles/JsonPath/. -// In addition, it has {range} {end} function to iterate list and slice. -package jsonpath +package types + +// Similarly to above, these are constants to support HTTP PATCH utilized by +// both the client and server that didn't make sense for a whole package to be +// dedicated to. +type PatchType string + +const ( + JSONPatchType PatchType = "application/json-patch+json" + MergePatchType PatchType = "application/merge-patch+json" + StrategicMergePatchType PatchType = "application/strategic-merge-patch+json" +) diff --git a/vendor/k8s.io/client-go/pkg/types/uid.go b/vendor/k8s.io/apimachinery/pkg/types/uid.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/types/uid.go rename to vendor/k8s.io/apimachinery/pkg/types/uid.go diff --git a/vendor/k8s.io/apimachinery/pkg/util/cache/BUILD b/vendor/k8s.io/apimachinery/pkg/util/cache/BUILD new file mode 100644 index 0000000000..46e0c6dfb1 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/cache/BUILD @@ -0,0 +1,33 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "cache_test.go", + "lruexpirecache_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/groupcache/lru:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "cache.go", + "lruexpirecache.go", + ], + tags = ["automanaged"], + deps = ["//vendor/github.com/hashicorp/golang-lru:go_default_library"], +) diff --git a/vendor/k8s.io/apimachinery/pkg/util/cache/cache.go b/vendor/k8s.io/apimachinery/pkg/util/cache/cache.go new file mode 100644 index 0000000000..9a09fe54d6 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/cache/cache.go @@ -0,0 +1,83 @@ +/* +Copyright 2014 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package cache + +import ( + "sync" +) + +const ( + shardsCount int = 32 +) + +type Cache []*cacheShard + +func NewCache(maxSize int) Cache { + if maxSize < shardsCount { + maxSize = shardsCount + } + cache := make(Cache, shardsCount) + for i := 0; i < shardsCount; i++ { + cache[i] = &cacheShard{ + items: make(map[uint64]interface{}), + maxSize: maxSize / shardsCount, + } + } + return cache +} + +func (c Cache) getShard(index uint64) *cacheShard { + return c[index%uint64(shardsCount)] +} + +// Returns true if object already existed, false otherwise. +func (c *Cache) Add(index uint64, obj interface{}) bool { + return c.getShard(index).add(index, obj) +} + +func (c *Cache) Get(index uint64) (obj interface{}, found bool) { + return c.getShard(index).get(index) +} + +type cacheShard struct { + items map[uint64]interface{} + sync.RWMutex + maxSize int +} + +// Returns true if object already existed, false otherwise. +func (s *cacheShard) add(index uint64, obj interface{}) bool { + s.Lock() + defer s.Unlock() + _, isOverwrite := s.items[index] + if !isOverwrite && len(s.items) >= s.maxSize { + var randomKey uint64 + for randomKey = range s.items { + break + } + delete(s.items, randomKey) + } + s.items[index] = obj + return isOverwrite +} + +func (s *cacheShard) get(index uint64) (obj interface{}, found bool) { + s.RLock() + defer s.RUnlock() + obj, found = s.items[index] + return +} diff --git a/vendor/k8s.io/apimachinery/pkg/util/cache/lruexpirecache.go b/vendor/k8s.io/apimachinery/pkg/util/cache/lruexpirecache.go new file mode 100644 index 0000000000..f6b307aa68 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/cache/lruexpirecache.go @@ -0,0 +1,102 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package cache + +import ( + "sync" + "time" + + "github.com/hashicorp/golang-lru" +) + +// Clock defines an interface for obtaining the current time +type Clock interface { + Now() time.Time +} + +// realClock implements the Clock interface by calling time.Now() +type realClock struct{} + +func (realClock) Now() time.Time { return time.Now() } + +// LRUExpireCache is a cache that ensures the mostly recently accessed keys are returned with +// a ttl beyond which keys are forcibly expired. +type LRUExpireCache struct { + // clock is used to obtain the current time + clock Clock + + cache *lru.Cache + lock sync.Mutex +} + +// NewLRUExpireCache creates an expiring cache with the given size +func NewLRUExpireCache(maxSize int) *LRUExpireCache { + return NewLRUExpireCacheWithClock(maxSize, realClock{}) +} + +// NewLRUExpireCacheWithClock creates an expiring cache with the given size, using the specified clock to obtain the current time. +func NewLRUExpireCacheWithClock(maxSize int, clock Clock) *LRUExpireCache { + cache, err := lru.New(maxSize) + if err != nil { + // if called with an invalid size + panic(err) + } + return &LRUExpireCache{clock: clock, cache: cache} +} + +type cacheEntry struct { + value interface{} + expireTime time.Time +} + +// Add adds the value to the cache at key with the specified maximum duration. +func (c *LRUExpireCache) Add(key interface{}, value interface{}, ttl time.Duration) { + c.lock.Lock() + defer c.lock.Unlock() + c.cache.Add(key, &cacheEntry{value, c.clock.Now().Add(ttl)}) +} + +// Get returns the value at the specified key from the cache if it exists and is not +// expired, or returns false. +func (c *LRUExpireCache) Get(key interface{}) (interface{}, bool) { + c.lock.Lock() + defer c.lock.Unlock() + e, ok := c.cache.Get(key) + if !ok { + return nil, false + } + if c.clock.Now().After(e.(*cacheEntry).expireTime) { + c.cache.Remove(key) + return nil, false + } + return e.(*cacheEntry).value, true +} + +// Remove removes the specified key from the cache if it exists +func (c *LRUExpireCache) Remove(key interface{}) { + c.lock.Lock() + defer c.lock.Unlock() + c.cache.Remove(key) +} + +// Keys returns all the keys in the cache, even if they are expired. Subsequent calls to +// get may return not found. It returns all keys from oldest to newest. +func (c *LRUExpireCache) Keys() []interface{} { + c.lock.Lock() + defer c.lock.Unlock() + return c.cache.Keys() +} diff --git a/vendor/k8s.io/apimachinery/pkg/util/clock/BUILD b/vendor/k8s.io/apimachinery/pkg/util/clock/BUILD new file mode 100644 index 0000000000..108ddee311 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/clock/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["clock_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["clock.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/clock/clock.go b/vendor/k8s.io/apimachinery/pkg/util/clock/clock.go similarity index 65% rename from vendor/k8s.io/client-go/pkg/util/clock/clock.go rename to vendor/k8s.io/apimachinery/pkg/util/clock/clock.go index 2ea1b53c1a..c303a212a0 100644 --- a/vendor/k8s.io/client-go/pkg/util/clock/clock.go +++ b/vendor/k8s.io/apimachinery/pkg/util/clock/clock.go @@ -27,6 +27,7 @@ type Clock interface { Now() time.Time Since(time.Time) time.Duration After(d time.Duration) <-chan time.Time + NewTimer(d time.Duration) Timer Sleep(d time.Duration) Tick(d time.Duration) <-chan time.Time } @@ -55,6 +56,12 @@ func (RealClock) After(d time.Duration) <-chan time.Time { return time.After(d) } +func (RealClock) NewTimer(d time.Duration) Timer { + return &realTimer{ + timer: time.NewTimer(d), + } +} + func (RealClock) Tick(d time.Duration) <-chan time.Time { return time.Tick(d) } @@ -76,7 +83,8 @@ type fakeClockWaiter struct { targetTime time.Time stepInterval time.Duration skipIfBlocked bool - destChan chan<- time.Time + destChan chan time.Time + fired bool } func NewFakeClock(t time.Time) *FakeClock { @@ -112,6 +120,23 @@ func (f *FakeClock) After(d time.Duration) <-chan time.Time { return ch } +// Fake version of time.NewTimer(d). +func (f *FakeClock) NewTimer(d time.Duration) Timer { + f.lock.Lock() + defer f.lock.Unlock() + stopTime := f.time.Add(d) + ch := make(chan time.Time, 1) // Don't block! + timer := &fakeTimer{ + fakeClock: f, + waiter: fakeClockWaiter{ + targetTime: stopTime, + destChan: ch, + }, + } + f.waiters = append(f.waiters, timer.waiter) + return timer +} + func (f *FakeClock) Tick(d time.Duration) <-chan time.Time { f.lock.Lock() defer f.lock.Unlock() @@ -127,7 +152,7 @@ func (f *FakeClock) Tick(d time.Duration) <-chan time.Time { return ch } -// Move clock by Duration, notify anyone that's called After or Tick +// Move clock by Duration, notify anyone that's called After, Tick, or NewTimer func (f *FakeClock) Step(d time.Duration) { f.lock.Lock() defer f.lock.Unlock() @@ -152,10 +177,12 @@ func (f *FakeClock) setTimeLocked(t time.Time) { if w.skipIfBlocked { select { case w.destChan <- t: + w.fired = true default: } } else { w.destChan <- t + w.fired = true } if w.stepInterval > 0 { @@ -207,6 +234,12 @@ func (*IntervalClock) After(d time.Duration) <-chan time.Time { panic("IntervalClock doesn't implement After") } +// Unimplemented, will panic. +// TODO: make interval clock use FakeClock so this can be implemented. +func (*IntervalClock) NewTimer(d time.Duration) Timer { + panic("IntervalClock doesn't implement NewTimer") +} + // Unimplemented, will panic. // TODO: make interval clock use FakeClock so this can be implemented. func (*IntervalClock) Tick(d time.Duration) <-chan time.Time { @@ -216,3 +249,79 @@ func (*IntervalClock) Tick(d time.Duration) <-chan time.Time { func (*IntervalClock) Sleep(d time.Duration) { panic("IntervalClock doesn't implement Sleep") } + +// Timer allows for injecting fake or real timers into code that +// needs to do arbitrary things based on time. +type Timer interface { + C() <-chan time.Time + Stop() bool + Reset(d time.Duration) bool +} + +var ( + _ = Timer(&realTimer{}) + _ = Timer(&fakeTimer{}) +) + +// realTimer is backed by an actual time.Timer. +type realTimer struct { + timer *time.Timer +} + +// C returns the underlying timer's channel. +func (r *realTimer) C() <-chan time.Time { + return r.timer.C +} + +// Stop calls Stop() on the underlying timer. +func (r *realTimer) Stop() bool { + return r.timer.Stop() +} + +// Reset calls Reset() on the underlying timer. +func (r *realTimer) Reset(d time.Duration) bool { + return r.timer.Reset(d) +} + +// fakeTimer implements Timer based on a FakeClock. +type fakeTimer struct { + fakeClock *FakeClock + waiter fakeClockWaiter +} + +// C returns the channel that notifies when this timer has fired. +func (f *fakeTimer) C() <-chan time.Time { + return f.waiter.destChan +} + +// Stop stops the timer and returns true if the timer has not yet fired, or false otherwise. +func (f *fakeTimer) Stop() bool { + f.fakeClock.lock.Lock() + defer f.fakeClock.lock.Unlock() + + newWaiters := make([]fakeClockWaiter, 0, len(f.fakeClock.waiters)) + for i := range f.fakeClock.waiters { + w := &f.fakeClock.waiters[i] + if w != &f.waiter { + newWaiters = append(newWaiters, *w) + } + } + + f.fakeClock.waiters = newWaiters + + return !f.waiter.fired +} + +// Reset resets the timer to the fake clock's "now" + d. It returns true if the timer has not yet +// fired, or false otherwise. +func (f *fakeTimer) Reset(d time.Duration) bool { + f.fakeClock.lock.Lock() + defer f.fakeClock.lock.Unlock() + + active := !f.waiter.fired + + f.waiter.fired = false + f.waiter.targetTime = f.fakeClock.time.Add(d) + + return active +} diff --git a/vendor/k8s.io/apimachinery/pkg/util/diff/BUILD b/vendor/k8s.io/apimachinery/pkg/util/diff/BUILD new file mode 100644 index 0000000000..ae36f426cf --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/diff/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["diff_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["diff.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/davecgh/go-spew/spew:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/diff/diff.go b/vendor/k8s.io/apimachinery/pkg/util/diff/diff.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/util/diff/diff.go rename to vendor/k8s.io/apimachinery/pkg/util/diff/diff.go index be406a01db..0f730875e8 100644 --- a/vendor/k8s.io/client-go/pkg/util/diff/diff.go +++ b/vendor/k8s.io/apimachinery/pkg/util/diff/diff.go @@ -27,7 +27,7 @@ import ( "github.com/davecgh/go-spew/spew" - "k8s.io/client-go/pkg/util/validation/field" + "k8s.io/apimachinery/pkg/util/validation/field" ) // StringDiff diffs a and b and returns a human readable diff. diff --git a/vendor/k8s.io/apimachinery/pkg/util/errors/BUILD b/vendor/k8s.io/apimachinery/pkg/util/errors/BUILD new file mode 100644 index 0000000000..196de9f621 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/errors/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["errors_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "errors.go", + ], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/errors/doc.go b/vendor/k8s.io/apimachinery/pkg/util/errors/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/errors/doc.go rename to vendor/k8s.io/apimachinery/pkg/util/errors/doc.go diff --git a/vendor/k8s.io/client-go/pkg/util/errors/errors.go b/vendor/k8s.io/apimachinery/pkg/util/errors/errors.go similarity index 90% rename from vendor/k8s.io/client-go/pkg/util/errors/errors.go rename to vendor/k8s.io/apimachinery/pkg/util/errors/errors.go index de62fe3997..bdea0e16c7 100644 --- a/vendor/k8s.io/client-go/pkg/util/errors/errors.go +++ b/vendor/k8s.io/apimachinery/pkg/util/errors/errors.go @@ -21,6 +21,9 @@ import ( "fmt" ) +// MessagesgCountMap contains occurance for each error message. +type MessageCountMap map[string]int + // Aggregate represents an object that contains multiple errors, but does not // necessarily have singular semantic meaning. type Aggregate interface { @@ -147,6 +150,22 @@ func Flatten(agg Aggregate) Aggregate { return NewAggregate(result) } +// CreateAggregateFromMessageCountMap converts MessageCountMap Aggregate +func CreateAggregateFromMessageCountMap(m MessageCountMap) Aggregate { + if m == nil { + return nil + } + result := make([]error, 0, len(m)) + for errStr, count := range m { + var countStr string + if count > 1 { + countStr = fmt.Sprintf(" (repeated %v times)", count) + } + result = append(result, fmt.Errorf("%v%v", errStr, countStr)) + } + return NewAggregate(result) +} + // Reduce will return err or, if err is an Aggregate and only has one item, // the first item in the aggregate. func Reduce(err error) error { diff --git a/vendor/k8s.io/apimachinery/pkg/util/framer/BUILD b/vendor/k8s.io/apimachinery/pkg/util/framer/BUILD new file mode 100644 index 0000000000..fc6d4bff5f --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/framer/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["framer_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["framer.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/framer/framer.go b/vendor/k8s.io/apimachinery/pkg/util/framer/framer.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/framer/framer.go rename to vendor/k8s.io/apimachinery/pkg/util/framer/framer.go diff --git a/vendor/k8s.io/apimachinery/pkg/util/intstr/BUILD b/vendor/k8s.io/apimachinery/pkg/util/intstr/BUILD new file mode 100644 index 0000000000..92968e2c8c --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/intstr/BUILD @@ -0,0 +1,33 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["intstr_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/github.com/ghodss/yaml:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "generated.pb.go", + "intstr.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/go-openapi/spec:go_default_library", + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/openapi:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/intstr/generated.pb.go b/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.pb.go similarity index 61% rename from vendor/k8s.io/client-go/pkg/util/intstr/generated.pb.go rename to vendor/k8s.io/apimachinery/pkg/util/intstr/generated.pb.go index 5165b24d5c..433dfa5cd9 100644 --- a/vendor/k8s.io/client-go/pkg/util/intstr/generated.pb.go +++ b/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -15,14 +15,14 @@ limitations under the License. */ // Code generated by protoc-gen-gogo. -// source: k8s.io/kubernetes/pkg/util/intstr/generated.proto +// source: k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.proto // DO NOT EDIT! /* Package intstr is a generated protocol buffer package. It is generated from these files: - k8s.io/kubernetes/pkg/util/intstr/generated.proto + k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.proto It has these top-level messages: IntOrString @@ -42,68 +42,70 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *IntOrString) Reset() { *m = IntOrString{} } func (*IntOrString) ProtoMessage() {} func (*IntOrString) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } func init() { - proto.RegisterType((*IntOrString)(nil), "k8s.io.client-go.pkg.util.intstr.IntOrString") + proto.RegisterType((*IntOrString)(nil), "k8s.io.apimachinery.pkg.util.intstr.IntOrString") } -func (m *IntOrString) Marshal() (data []byte, err error) { +func (m *IntOrString) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IntOrString) MarshalTo(data []byte) (int, error) { +func (m *IntOrString) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Type)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.Type)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.IntVal)) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(m.IntVal)) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.StrVal))) - i += copy(data[i:], m.StrVal) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.StrVal))) + i += copy(dAtA[i:], m.StrVal) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *IntOrString) Size() (n int) { @@ -129,8 +131,8 @@ func sovGenerated(x uint64) (n int) { func sozGenerated(x uint64) (n int) { return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) } -func (m *IntOrString) Unmarshal(data []byte) error { - l := len(data) +func (m *IntOrString) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -142,7 +144,7 @@ func (m *IntOrString) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -170,7 +172,7 @@ func (m *IntOrString) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Type |= (Type(b) & 0x7F) << shift if b < 0x80 { @@ -189,7 +191,7 @@ func (m *IntOrString) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.IntVal |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -208,7 +210,7 @@ func (m *IntOrString) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -223,11 +225,11 @@ func (m *IntOrString) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.StrVal = string(data[iNdEx:postIndex]) + m.StrVal = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -246,8 +248,8 @@ func (m *IntOrString) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -258,7 +260,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -276,7 +278,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -293,7 +295,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -316,7 +318,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -327,7 +329,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -351,23 +353,29 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/kubernetes/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 269 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x44, 0x8f, 0x31, 0x4e, 0xc3, 0x30, - 0x18, 0x85, 0x6d, 0x5a, 0x2a, 0x08, 0x12, 0x43, 0xc4, 0x50, 0x31, 0x38, 0x81, 0x01, 0x79, 0xc1, - 0x16, 0x1b, 0x62, 0xcc, 0xd6, 0x09, 0x29, 0x45, 0x0c, 0x6c, 0x0d, 0x18, 0x63, 0xa5, 0xd8, 0x96, - 0xf3, 0x67, 0xe8, 0xd6, 0x23, 0xc0, 0xc6, 0xc8, 0x71, 0x32, 0x76, 0x64, 0x40, 0x15, 0x31, 0xb7, - 0x60, 0x42, 0x71, 0x22, 0x75, 0xb2, 0xdf, 0x7b, 0xdf, 0x67, 0xc9, 0xd1, 0x55, 0x79, 0x5d, 0x31, - 0x65, 0x78, 0x59, 0x17, 0xc2, 0x69, 0x01, 0xa2, 0xe2, 0xb6, 0x94, 0xbc, 0x06, 0xb5, 0xe4, 0x4a, - 0x43, 0x05, 0x8e, 0x4b, 0xa1, 0x85, 0x5b, 0x80, 0x78, 0x62, 0xd6, 0x19, 0x30, 0xf1, 0x59, 0xaf, - 0xb0, 0x9d, 0xc2, 0x6c, 0x29, 0x59, 0xa7, 0xb0, 0x5e, 0x39, 0xbd, 0x94, 0x0a, 0x5e, 0xea, 0x82, - 0x3d, 0x9a, 0x57, 0x2e, 0x8d, 0x34, 0x3c, 0x98, 0x45, 0xfd, 0x1c, 0x52, 0x08, 0xe1, 0xd6, 0xbf, - 0x78, 0xfe, 0x8e, 0xa3, 0xa3, 0x99, 0x86, 0x5b, 0x37, 0x07, 0xa7, 0xb4, 0x8c, 0x69, 0x34, 0x86, - 0x95, 0x15, 0x53, 0x9c, 0x62, 0x3a, 0xca, 0x4e, 0x9a, 0x6d, 0x82, 0xfc, 0x36, 0x19, 0xdf, 0xad, - 0xac, 0xf8, 0x1b, 0xce, 0x3c, 0x10, 0xf1, 0x45, 0x34, 0x51, 0x1a, 0xee, 0x17, 0xcb, 0xe9, 0x5e, - 0x8a, 0xe9, 0x7e, 0x76, 0x3c, 0xb0, 0x93, 0x59, 0x68, 0xf3, 0x61, 0xed, 0xb8, 0x0a, 0x5c, 0xc7, - 0x8d, 0x52, 0x4c, 0x0f, 0x77, 0xdc, 0x3c, 0xb4, 0xf9, 0xb0, 0xde, 0x1c, 0x7c, 0x7c, 0x26, 0x68, - 0xfd, 0x9d, 0xa2, 0x8c, 0x36, 0x2d, 0x41, 0x9b, 0x96, 0xa0, 0xaf, 0x96, 0xa0, 0xb5, 0x27, 0xb8, - 0xf1, 0x04, 0x6f, 0x3c, 0xc1, 0x3f, 0x9e, 0xe0, 0xb7, 0x5f, 0x82, 0x1e, 0x26, 0xfd, 0x67, 0xff, - 0x03, 0x00, 0x00, 0xff, 0xff, 0x68, 0x57, 0xfb, 0xfa, 0x43, 0x01, 0x00, 0x00, + // 292 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x4c, 0x8f, 0x31, 0x4b, 0x33, 0x31, + 0x1c, 0xc6, 0x93, 0xb7, 0x7d, 0x8b, 0x9e, 0xe0, 0x50, 0x1c, 0x8a, 0x43, 0x7a, 0x28, 0xc8, 0x0d, + 0x9a, 0xac, 0xe2, 0xd8, 0xad, 0x20, 0x08, 0x57, 0x71, 0x70, 0xbb, 0x6b, 0x63, 0x1a, 0xae, 0x4d, + 0x42, 0xee, 0x7f, 0xc2, 0x6d, 0xfd, 0x08, 0xba, 0x39, 0xfa, 0x71, 0x6e, 0xec, 0xd8, 0x41, 0x8a, + 0x17, 0xbf, 0x85, 0x93, 0x5c, 0xee, 0x40, 0xa7, 0xe4, 0x79, 0x9e, 0xdf, 0x2f, 0x90, 0xe0, 0x36, + 0xbb, 0xce, 0xa9, 0xd4, 0x2c, 0x2b, 0x52, 0x6e, 0x15, 0x07, 0x9e, 0xb3, 0x67, 0xae, 0x16, 0xda, + 0xb2, 0x6e, 0x48, 0x8c, 0x5c, 0x27, 0xf3, 0xa5, 0x54, 0xdc, 0x96, 0xcc, 0x64, 0x82, 0x15, 0x20, + 0x57, 0x4c, 0x2a, 0xc8, 0xc1, 0x32, 0xc1, 0x15, 0xb7, 0x09, 0xf0, 0x05, 0x35, 0x56, 0x83, 0x1e, + 0x9e, 0xb7, 0x12, 0xfd, 0x2b, 0x51, 0x93, 0x09, 0xda, 0x48, 0xb4, 0x95, 0x4e, 0xaf, 0x84, 0x84, + 0x65, 0x91, 0xd2, 0xb9, 0x5e, 0x33, 0xa1, 0x85, 0x66, 0xde, 0x4d, 0x8b, 0x27, 0x9f, 0x7c, 0xf0, + 0xb7, 0xf6, 0xcd, 0xb3, 0x57, 0x1c, 0x1c, 0x4d, 0x15, 0xdc, 0xd9, 0x19, 0x58, 0xa9, 0xc4, 0x30, + 0x0a, 0xfa, 0x50, 0x1a, 0x3e, 0xc2, 0x21, 0x8e, 0x7a, 0x93, 0x93, 0x6a, 0x3f, 0x46, 0x6e, 0x3f, + 0xee, 0xdf, 0x97, 0x86, 0x7f, 0x77, 0x67, 0xec, 0x89, 0xe1, 0x45, 0x30, 0x90, 0x0a, 0x1e, 0x92, + 0xd5, 0xe8, 0x5f, 0x88, 0xa3, 0xff, 0x93, 0xe3, 0x8e, 0x1d, 0x4c, 0x7d, 0x1b, 0x77, 0x6b, 0xc3, + 0xe5, 0x60, 0x1b, 0xae, 0x17, 0xe2, 0xe8, 0xf0, 0x97, 0x9b, 0xf9, 0x36, 0xee, 0xd6, 0x9b, 0x83, + 0xb7, 0xf7, 0x31, 0xda, 0x7c, 0x84, 0x68, 0x72, 0x59, 0xd5, 0x04, 0x6d, 0x6b, 0x82, 0x76, 0x35, + 0x41, 0x1b, 0x47, 0x70, 0xe5, 0x08, 0xde, 0x3a, 0x82, 0x77, 0x8e, 0xe0, 0x4f, 0x47, 0xf0, 0xcb, + 0x17, 0x41, 0x8f, 0x83, 0xf6, 0xc3, 0x3f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x52, 0xa0, 0xb5, 0xc9, + 0x64, 0x01, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/util/intstr/generated.proto b/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.proto similarity index 93% rename from vendor/k8s.io/client-go/pkg/util/intstr/generated.proto rename to vendor/k8s.io/apimachinery/pkg/util/intstr/generated.proto index 4dc4e994a7..cccaf6f689 100644 --- a/vendor/k8s.io/client-go/pkg/util/intstr/generated.proto +++ b/vendor/k8s.io/apimachinery/pkg/util/intstr/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,7 +19,7 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.util.intstr; +package k8s.io.apimachinery.pkg.util.intstr; // Package-wide variables from generator "generated". option go_package = "intstr"; diff --git a/vendor/k8s.io/client-go/pkg/util/intstr/intstr.go b/vendor/k8s.io/apimachinery/pkg/util/intstr/intstr.go similarity index 88% rename from vendor/k8s.io/client-go/pkg/util/intstr/intstr.go rename to vendor/k8s.io/apimachinery/pkg/util/intstr/intstr.go index a365f623e5..02586b3481 100644 --- a/vendor/k8s.io/client-go/pkg/util/intstr/intstr.go +++ b/vendor/k8s.io/apimachinery/pkg/util/intstr/intstr.go @@ -20,12 +20,14 @@ import ( "encoding/json" "fmt" "math" + "runtime/debug" "strconv" "strings" - "k8s.io/client-go/pkg/genericapiserver/openapi/common" + "k8s.io/apimachinery/pkg/openapi" "github.com/go-openapi/spec" + "github.com/golang/glog" "github.com/google/gofuzz" ) @@ -57,6 +59,9 @@ const ( // than int32. // TODO: convert to (val int32) func FromInt(val int) IntOrString { + if val > math.MaxInt32 || val < math.MinInt32 { + glog.Errorf("value: %d overflows int32\n%s\n", val, debug.Stack()) + } return IntOrString{Type: Int, IntVal: int32(val)} } @@ -65,6 +70,16 @@ func FromString(val string) IntOrString { return IntOrString{Type: String, StrVal: val} } +// Parse the given string and try to convert it to an integer before +// setting it as a string value. +func Parse(val string) IntOrString { + i, err := strconv.Atoi(val) + if err != nil { + return FromString(val) + } + return FromInt(i) +} + // UnmarshalJSON implements the json.Unmarshaller interface. func (intstr *IntOrString) UnmarshalJSON(value []byte) error { if value[0] == '"' { @@ -105,8 +120,8 @@ func (intstr IntOrString) MarshalJSON() ([]byte, error) { } } -func (_ IntOrString) OpenAPIDefinition() common.OpenAPIDefinition { - return common.OpenAPIDefinition{ +func (_ IntOrString) OpenAPIDefinition() openapi.OpenAPIDefinition { + return openapi.OpenAPIDefinition{ Schema: spec.Schema{ SchemaProps: spec.SchemaProps{ Type: []string{"string"}, diff --git a/vendor/k8s.io/apimachinery/pkg/util/json/BUILD b/vendor/k8s.io/apimachinery/pkg/util/json/BUILD new file mode 100644 index 0000000000..68ca233394 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/json/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["json_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["json.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/json/json.go b/vendor/k8s.io/apimachinery/pkg/util/json/json.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/json/json.go rename to vendor/k8s.io/apimachinery/pkg/util/json/json.go diff --git a/vendor/k8s.io/apimachinery/pkg/util/net/BUILD b/vendor/k8s.io/apimachinery/pkg/util/net/BUILD new file mode 100644 index 0000000000..09a89c1179 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/net/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "http_test.go", + "interface_test.go", + "port_range_test.go", + "port_split_test.go", + "util_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/github.com/spf13/pflag:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "http.go", + "interface.go", + "port_range.go", + "port_split.go", + "util.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/golang.org/x/net/http2:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/net/http.go b/vendor/k8s.io/apimachinery/pkg/util/net/http.go similarity index 55% rename from vendor/k8s.io/client-go/pkg/util/net/http.go rename to vendor/k8s.io/apimachinery/pkg/util/net/http.go index bfe2e09375..adb80813be 100644 --- a/vendor/k8s.io/client-go/pkg/util/net/http.go +++ b/vendor/k8s.io/apimachinery/pkg/util/net/http.go @@ -17,6 +17,8 @@ limitations under the License. package net import ( + "bufio" + "bytes" "crypto/tls" "fmt" "io" @@ -95,7 +97,7 @@ type RoundTripperWrapper interface { type DialFunc func(net, addr string) (net.Conn, error) -func Dialer(transport http.RoundTripper) (DialFunc, error) { +func DialerFor(transport http.RoundTripper) (DialFunc, error) { if transport == nil { return nil, nil } @@ -104,38 +106,14 @@ func Dialer(transport http.RoundTripper) (DialFunc, error) { case *http.Transport: return transport.Dial, nil case RoundTripperWrapper: - return Dialer(transport.WrappedRoundTripper()) + return DialerFor(transport.WrappedRoundTripper()) default: return nil, fmt.Errorf("unknown transport type: %v", transport) } } -// CloneTLSConfig returns a tls.Config with all exported fields except SessionTicketsDisabled and SessionTicketKey copied. -// This makes it safe to call CloneTLSConfig on a config in active use by a server. -// TODO: replace with tls.Config#Clone when we move to go1.8 -func CloneTLSConfig(cfg *tls.Config) *tls.Config { - if cfg == nil { - return &tls.Config{} - } - return &tls.Config{ - Rand: cfg.Rand, - Time: cfg.Time, - Certificates: cfg.Certificates, - NameToCertificate: cfg.NameToCertificate, - GetCertificate: cfg.GetCertificate, - RootCAs: cfg.RootCAs, - NextProtos: cfg.NextProtos, - ServerName: cfg.ServerName, - ClientAuth: cfg.ClientAuth, - ClientCAs: cfg.ClientCAs, - InsecureSkipVerify: cfg.InsecureSkipVerify, - CipherSuites: cfg.CipherSuites, - PreferServerCipherSuites: cfg.PreferServerCipherSuites, - ClientSessionCache: cfg.ClientSessionCache, - MinVersion: cfg.MinVersion, - MaxVersion: cfg.MaxVersion, - CurvePreferences: cfg.CurvePreferences, - } +type TLSClientConfigHolder interface { + TLSClientConfig() *tls.Config } func TLSClientConfig(transport http.RoundTripper) (*tls.Config, error) { @@ -146,6 +124,8 @@ func TLSClientConfig(transport http.RoundTripper) (*tls.Config, error) { switch transport := transport.(type) { case *http.Transport: return transport.TLSClientConfig, nil + case TLSClientConfigHolder: + return transport.TLSClientConfig(), nil case RoundTripperWrapper: return TLSClientConfig(transport.WrappedRoundTripper()) default: @@ -170,13 +150,13 @@ func GetHTTPClient(req *http.Request) string { return "unknown" } -// Extracts and returns the clients IP from the given request. -// Looks at X-Forwarded-For header, X-Real-Ip header and request.RemoteAddr in that order. -// Returns nil if none of them are set or is set to an invalid value. -func GetClientIP(req *http.Request) net.IP { +// SourceIPs splits the comma separated X-Forwarded-For header or returns the X-Real-Ip header or req.RemoteAddr, +// in that order, ignoring invalid IPs. It returns nil if all of these are empty or invalid. +func SourceIPs(req *http.Request) []net.IP { hdr := req.Header // First check the X-Forwarded-For header for requests via proxy. hdrForwardedFor := hdr.Get("X-Forwarded-For") + forwardedForIPs := []net.IP{} if hdrForwardedFor != "" { // X-Forwarded-For can be a csv of IPs in case of multiple proxies. // Use the first valid one. @@ -184,17 +164,20 @@ func GetClientIP(req *http.Request) net.IP { for _, part := range parts { ip := net.ParseIP(strings.TrimSpace(part)) if ip != nil { - return ip + forwardedForIPs = append(forwardedForIPs, ip) } } } + if len(forwardedForIPs) > 0 { + return forwardedForIPs + } // Try the X-Real-Ip header. hdrRealIp := hdr.Get("X-Real-Ip") if hdrRealIp != "" { ip := net.ParseIP(hdrRealIp) if ip != nil { - return ip + return []net.IP{ip} } } @@ -202,11 +185,43 @@ func GetClientIP(req *http.Request) net.IP { // Remote Address in Go's HTTP server is in the form host:port so we need to split that first. host, _, err := net.SplitHostPort(req.RemoteAddr) if err == nil { - return net.ParseIP(host) + if remoteIP := net.ParseIP(host); remoteIP != nil { + return []net.IP{remoteIP} + } } // Fallback if Remote Address was just IP. - return net.ParseIP(req.RemoteAddr) + if remoteIP := net.ParseIP(req.RemoteAddr); remoteIP != nil { + return []net.IP{remoteIP} + } + + return nil +} + +// Extracts and returns the clients IP from the given request. +// Looks at X-Forwarded-For header, X-Real-Ip header and request.RemoteAddr in that order. +// Returns nil if none of them are set or is set to an invalid value. +func GetClientIP(req *http.Request) net.IP { + ips := SourceIPs(req) + if len(ips) == 0 { + return nil + } + return ips[0] +} + +// Prepares the X-Forwarded-For header for another forwarding hop by appending the previous sender's +// IP address to the X-Forwarded-For chain. +func AppendForwardedForHeader(req *http.Request) { + // Copied from net/http/httputil/reverseproxy.go: + if clientIP, _, err := net.SplitHostPort(req.RemoteAddr); err == nil { + // If we aren't the first proxy retain prior + // X-Forwarded-For information as a comma+space + // separated list and fold multiple headers into one. + if prior, ok := req.Header["X-Forwarded-For"]; ok { + clientIP = strings.Join(prior, ", ") + ", " + clientIP + } + req.Header.Set("X-Forwarded-For", clientIP) + } } var defaultProxyFuncPointer = fmt.Sprintf("%p", http.ProxyFromEnvironment) @@ -261,3 +276,126 @@ func NewProxierWithNoProxyCIDR(delegate func(req *http.Request) (*url.URL, error return delegate(req) } } + +// Dialer dials a host and writes a request to it. +type Dialer interface { + // Dial connects to the host specified by req's URL, writes the request to the connection, and + // returns the opened net.Conn. + Dial(req *http.Request) (net.Conn, error) +} + +// ConnectWithRedirects uses dialer to send req, following up to 10 redirects (relative to +// originalLocation). It returns the opened net.Conn and the raw response bytes. +func ConnectWithRedirects(originalMethod string, originalLocation *url.URL, header http.Header, originalBody io.Reader, dialer Dialer) (net.Conn, []byte, error) { + const ( + maxRedirects = 10 + maxResponseSize = 16384 // play it safe to allow the potential for lots of / large headers + ) + + var ( + location = originalLocation + method = originalMethod + intermediateConn net.Conn + rawResponse = bytes.NewBuffer(make([]byte, 0, 256)) + body = originalBody + ) + + defer func() { + if intermediateConn != nil { + intermediateConn.Close() + } + }() + +redirectLoop: + for redirects := 0; ; redirects++ { + if redirects > maxRedirects { + return nil, nil, fmt.Errorf("too many redirects (%d)", redirects) + } + + req, err := http.NewRequest(method, location.String(), body) + if err != nil { + return nil, nil, err + } + + req.Header = header + + intermediateConn, err = dialer.Dial(req) + if err != nil { + return nil, nil, err + } + + // Peek at the backend response. + rawResponse.Reset() + respReader := bufio.NewReader(io.TeeReader( + io.LimitReader(intermediateConn, maxResponseSize), // Don't read more than maxResponseSize bytes. + rawResponse)) // Save the raw response. + resp, err := http.ReadResponse(respReader, nil) + if err != nil { + // Unable to read the backend response; let the client handle it. + glog.Warningf("Error reading backend response: %v", err) + break redirectLoop + } + + switch resp.StatusCode { + case http.StatusFound: + // Redirect, continue. + default: + // Don't redirect. + break redirectLoop + } + + // Redirected requests switch to "GET" according to the HTTP spec: + // https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.3 + method = "GET" + // don't send a body when following redirects + body = nil + + resp.Body.Close() // not used + + // Reset the connection. + intermediateConn.Close() + intermediateConn = nil + + // Prepare to follow the redirect. + redirectStr := resp.Header.Get("Location") + if redirectStr == "" { + return nil, nil, fmt.Errorf("%d response missing Location header", resp.StatusCode) + } + // We have to parse relative to the current location, NOT originalLocation. For example, + // if we request http://foo.com/a and get back "http://bar.com/b", the result should be + // http://bar.com/b. If we then make that request and get back a redirect to "/c", the result + // should be http://bar.com/c, not http://foo.com/c. + location, err = location.Parse(redirectStr) + if err != nil { + return nil, nil, fmt.Errorf("malformed Location header: %v", err) + } + } + + connToReturn := intermediateConn + intermediateConn = nil // Don't close the connection when we return it. + return connToReturn, rawResponse.Bytes(), nil +} + +// CloneRequest creates a shallow copy of the request along with a deep copy of the Headers. +func CloneRequest(req *http.Request) *http.Request { + r := new(http.Request) + + // shallow clone + *r = *req + + // deep copy headers + r.Header = CloneHeader(req.Header) + + return r +} + +// CloneHeader creates a deep copy of an http.Header. +func CloneHeader(in http.Header) http.Header { + out := make(http.Header, len(in)) + for key, values := range in { + newValues := make([]string, len(values)) + copy(newValues, values) + out[key] = newValues + } + return out +} diff --git a/vendor/k8s.io/client-go/pkg/util/net/interface.go b/vendor/k8s.io/apimachinery/pkg/util/net/interface.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/net/interface.go rename to vendor/k8s.io/apimachinery/pkg/util/net/interface.go diff --git a/vendor/k8s.io/client-go/pkg/util/net/port_range.go b/vendor/k8s.io/apimachinery/pkg/util/net/port_range.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/net/port_range.go rename to vendor/k8s.io/apimachinery/pkg/util/net/port_range.go diff --git a/vendor/k8s.io/client-go/pkg/util/net/port_split.go b/vendor/k8s.io/apimachinery/pkg/util/net/port_split.go similarity index 98% rename from vendor/k8s.io/client-go/pkg/util/net/port_split.go rename to vendor/k8s.io/apimachinery/pkg/util/net/port_split.go index a341983ade..c0fd4e20fe 100644 --- a/vendor/k8s.io/client-go/pkg/util/net/port_split.go +++ b/vendor/k8s.io/apimachinery/pkg/util/net/port_split.go @@ -19,7 +19,7 @@ package net import ( "strings" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/sets" ) var validSchemes = sets.NewString("http", "https", "") diff --git a/vendor/k8s.io/client-go/pkg/util/net/util.go b/vendor/k8s.io/apimachinery/pkg/util/net/util.go similarity index 81% rename from vendor/k8s.io/client-go/pkg/util/net/util.go rename to vendor/k8s.io/apimachinery/pkg/util/net/util.go index 1348f4deeb..461144f0ba 100644 --- a/vendor/k8s.io/client-go/pkg/util/net/util.go +++ b/vendor/k8s.io/apimachinery/pkg/util/net/util.go @@ -19,6 +19,7 @@ package net import ( "net" "reflect" + "syscall" ) // IPNetEqual checks if the two input IPNets are representing the same subnet. @@ -34,3 +35,12 @@ func IPNetEqual(ipnet1, ipnet2 *net.IPNet) bool { } return false } + +// Returns if the given err is "connection reset by peer" error. +func IsConnectionReset(err error) bool { + opErr, ok := err.(*net.OpError) + if ok && opErr.Err.Error() == syscall.ECONNRESET.Error() { + return true + } + return false +} diff --git a/vendor/k8s.io/apimachinery/pkg/util/rand/BUILD b/vendor/k8s.io/apimachinery/pkg/util/rand/BUILD new file mode 100644 index 0000000000..c4880b6e7e --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/rand/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["rand_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["rand.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/rand/rand.go b/vendor/k8s.io/apimachinery/pkg/util/rand/rand.go similarity index 84% rename from vendor/k8s.io/client-go/pkg/util/rand/rand.go rename to vendor/k8s.io/apimachinery/pkg/util/rand/rand.go index 134c152605..db109c2cd2 100644 --- a/vendor/k8s.io/client-go/pkg/util/rand/rand.go +++ b/vendor/k8s.io/apimachinery/pkg/util/rand/rand.go @@ -23,8 +23,6 @@ import ( "time" ) -var letters = []rune("abcdefghijklmnopqrstuvwxyz0123456789") -var numLetters = len(letters) var rng = struct { sync.Mutex rand *rand.Rand @@ -72,12 +70,16 @@ func Perm(n int) []int { return rng.rand.Perm(n) } -// String generates a random alphanumeric string n characters long. This will -// panic if n is less than zero. +// We omit vowels from the set of available characters to reduce the chances +// of "bad words" being formed. +var alphanums = []rune("bcdfghjklmnpqrstvwxz0123456789") + +// String generates a random alphanumeric string, without vowels, which is n +// characters long. This will panic if n is less than zero. func String(length int) string { b := make([]rune, length) for i := range b { - b[i] = letters[Intn(numLetters)] + b[i] = alphanums[Intn(len(alphanums))] } return string(b) } diff --git a/vendor/k8s.io/apimachinery/pkg/util/runtime/BUILD b/vendor/k8s.io/apimachinery/pkg/util/runtime/BUILD new file mode 100644 index 0000000000..d6063ee6dc --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/runtime/BUILD @@ -0,0 +1,23 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["runtime_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["runtime.go"], + tags = ["automanaged"], + deps = ["//vendor/github.com/golang/glog:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go b/vendor/k8s.io/apimachinery/pkg/util/runtime/runtime.go similarity index 76% rename from vendor/k8s.io/client-go/pkg/util/runtime/runtime.go rename to vendor/k8s.io/apimachinery/pkg/util/runtime/runtime.go index 976de49d58..748174e191 100644 --- a/vendor/k8s.io/client-go/pkg/util/runtime/runtime.go +++ b/vendor/k8s.io/apimachinery/pkg/util/runtime/runtime.go @@ -19,6 +19,8 @@ package runtime import ( "fmt" "runtime" + "sync" + "time" "github.com/golang/glog" ) @@ -79,7 +81,18 @@ func getCallers(r interface{}) string { // ErrorHandlers is a list of functions which will be invoked when an unreturnable // error occurs. -var ErrorHandlers = []func(error){logError} +// TODO(lavalamp): for testability, this and the below HandleError function +// should be packaged up into a testable and reusable object. +var ErrorHandlers = []func(error){ + logError, + (&rudimentaryErrorBackoff{ + lastErrorTime: time.Now(), + // 1ms was the number folks were able to stomach as a global rate limit. + // If you need to log errors more than 1000 times a second you + // should probably consider fixing your code instead. :) + minPeriod: time.Millisecond, + }).OnError, +} // HandlerError is a method to invoke when a non-user facing piece of code cannot // return an error and needs to indicate it has been ignored. Invoking this method @@ -101,6 +114,26 @@ func logError(err error) { glog.ErrorDepth(2, err) } +type rudimentaryErrorBackoff struct { + minPeriod time.Duration // immutable + // TODO(lavalamp): use the clock for testability. Need to move that + // package for that to be accessible here. + lastErrorTimeLock sync.Mutex + lastErrorTime time.Time +} + +// OnError will block if it is called more often than the embedded period time. +// This will prevent overly tight hot error loops. +func (r *rudimentaryErrorBackoff) OnError(error) { + r.lastErrorTimeLock.Lock() + defer r.lastErrorTimeLock.Unlock() + d := time.Since(r.lastErrorTime) + if d < r.minPeriod { + time.Sleep(r.minPeriod - d) + } + r.lastErrorTime = time.Now() +} + // GetCaller returns the caller of the function that calls it. func GetCaller() string { var pc [1]uintptr diff --git a/vendor/k8s.io/apimachinery/pkg/util/sets/BUILD b/vendor/k8s.io/apimachinery/pkg/util/sets/BUILD new file mode 100644 index 0000000000..97b4bb9082 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/BUILD @@ -0,0 +1,58 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load("@io_kubernetes_build//defs:go.bzl", "go_genrule") +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "byte.go", + "doc.go", + "empty.go", + "int.go", + "int64.go", + "string.go", + ], + tags = ["automanaged"], +) + +go_genrule( + name = "set-gen", + srcs = [ + "//hack/boilerplate:boilerplate.go.txt", + ], + outs = [ + "byte.go", + "doc.go", + "empty.go", + "int.go", + "int64.go", + "string.go", + ], + cmd = """ +$(location //cmd/libs/go2idl/set-gen) \ + --input-dirs ./vendor/k8s.io/apimachinery/pkg/util/sets/types \ + --output-base $(GENDIR)/vendor/k8s.io/apimachinery/pkg/util \ + --go-header-file $(location //hack/boilerplate:boilerplate.go.txt) \ + --output-package sets + """, + go_deps = [ + "//vendor/k8s.io/apimachinery/pkg/util/sets/types:go_default_library", + ], + tools = [ + "//cmd/libs/go2idl/set-gen", + ], +) + +go_test( + name = "go_default_test", + srcs = ["set_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/sets/byte.go b/vendor/k8s.io/apimachinery/pkg/util/sets/byte.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/util/sets/byte.go rename to vendor/k8s.io/apimachinery/pkg/util/sets/byte.go index 3d6d0dfe43..a460e4b1f5 100644 --- a/vendor/k8s.io/client-go/pkg/util/sets/byte.go +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/byte.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/pkg/util/sets/doc.go b/vendor/k8s.io/apimachinery/pkg/util/sets/doc.go similarity index 94% rename from vendor/k8s.io/client-go/pkg/util/sets/doc.go rename to vendor/k8s.io/apimachinery/pkg/util/sets/doc.go index c5e541621f..28a6a7d5c7 100644 --- a/vendor/k8s.io/client-go/pkg/util/sets/doc.go +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/pkg/util/sets/empty.go b/vendor/k8s.io/apimachinery/pkg/util/sets/empty.go similarity index 95% rename from vendor/k8s.io/client-go/pkg/util/sets/empty.go rename to vendor/k8s.io/apimachinery/pkg/util/sets/empty.go index 5654edd773..cd22b953aa 100644 --- a/vendor/k8s.io/client-go/pkg/util/sets/empty.go +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/empty.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/pkg/util/sets/int.go b/vendor/k8s.io/apimachinery/pkg/util/sets/int.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/util/sets/int.go rename to vendor/k8s.io/apimachinery/pkg/util/sets/int.go index 6d32f84c78..0614e9fb00 100644 --- a/vendor/k8s.io/client-go/pkg/util/sets/int.go +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/int.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/pkg/util/sets/int64.go b/vendor/k8s.io/apimachinery/pkg/util/sets/int64.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/util/sets/int64.go rename to vendor/k8s.io/apimachinery/pkg/util/sets/int64.go index 1de18319b7..82e1ba7821 100644 --- a/vendor/k8s.io/client-go/pkg/util/sets/int64.go +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/int64.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/pkg/util/sets/string.go b/vendor/k8s.io/apimachinery/pkg/util/sets/string.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/util/sets/string.go rename to vendor/k8s.io/apimachinery/pkg/util/sets/string.go index da66eaf8e7..baef7a6a2b 100644 --- a/vendor/k8s.io/client-go/pkg/util/sets/string.go +++ b/vendor/k8s.io/apimachinery/pkg/util/sets/string.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/apimachinery/pkg/util/validation/BUILD b/vendor/k8s.io/apimachinery/pkg/util/validation/BUILD new file mode 100644 index 0000000000..5b5d461e9d --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/validation/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["validation_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["validation.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/apimachinery/pkg/util/validation/field/BUILD b/vendor/k8s.io/apimachinery/pkg/util/validation/field/BUILD new file mode 100644 index 0000000000..7a777062a4 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/validation/field/BUILD @@ -0,0 +1,32 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "errors_test.go", + "path_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "errors.go", + "path.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/validation/field/errors.go b/vendor/k8s.io/apimachinery/pkg/util/validation/field/errors.go similarity index 85% rename from vendor/k8s.io/client-go/pkg/util/validation/field/errors.go rename to vendor/k8s.io/apimachinery/pkg/util/validation/field/errors.go index 6d11ec6165..43c779a11b 100644 --- a/vendor/k8s.io/client-go/pkg/util/validation/field/errors.go +++ b/vendor/k8s.io/apimachinery/pkg/util/validation/field/errors.go @@ -17,11 +17,12 @@ limitations under the License. package field import ( - "encoding/json" "fmt" + "reflect" "strings" - utilerrors "k8s.io/client-go/pkg/util/errors" + utilerrors "k8s.io/apimachinery/pkg/util/errors" + "k8s.io/apimachinery/pkg/util/sets" ) // Error is an implementation of the 'error' interface, which represents a @@ -48,14 +49,33 @@ func (v *Error) ErrorBody() string { case ErrorTypeRequired, ErrorTypeForbidden, ErrorTypeTooLong, ErrorTypeInternal: s = fmt.Sprintf("%s", v.Type) default: - var bad string - badBytes, err := json.Marshal(v.BadValue) - if err != nil { - bad = err.Error() - } else { - bad = string(badBytes) + value := v.BadValue + valueType := reflect.TypeOf(value) + if value == nil || valueType == nil { + value = "null" + } else if valueType.Kind() == reflect.Ptr { + if reflectValue := reflect.ValueOf(value); reflectValue.IsNil() { + value = "null" + } else { + value = reflectValue.Elem().Interface() + } + } + switch t := value.(type) { + case int64, int32, float64, float32, bool: + // use simple printer for simple types + s = fmt.Sprintf("%s: %v", v.Type, value) + case string: + s = fmt.Sprintf("%s: %q", v.Type, t) + case fmt.Stringer: + // anything that defines String() is better than raw struct + s = fmt.Sprintf("%s: %s", v.Type, t.String()) + default: + // fallback to raw struct + // TODO: internal types have panic guards against json.Marshalling to prevent + // accidental use of internal types in external serialized form. For now, use + // %#v, although it would be better to show a more expressive output in the future + s = fmt.Sprintf("%s: %#v", v.Type, value) } - s = fmt.Sprintf("%s: %s", v.Type, bad) } if len(v.Detail) != 0 { s += fmt.Sprintf(": %s", v.Detail) @@ -201,9 +221,15 @@ func NewErrorTypeMatcher(t ErrorType) utilerrors.Matcher { // ToAggregate converts the ErrorList into an errors.Aggregate. func (list ErrorList) ToAggregate() utilerrors.Aggregate { - errs := make([]error, len(list)) - for i := range list { - errs[i] = list[i] + errs := make([]error, 0, len(list)) + errorMsgs := sets.NewString() + for _, err := range list { + msg := fmt.Sprintf("%v", err) + if errorMsgs.Has(msg) { + continue + } + errorMsgs.Insert(msg) + errs = append(errs, err) } return utilerrors.NewAggregate(errs) } diff --git a/vendor/k8s.io/client-go/pkg/util/validation/field/path.go b/vendor/k8s.io/apimachinery/pkg/util/validation/field/path.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/validation/field/path.go rename to vendor/k8s.io/apimachinery/pkg/util/validation/field/path.go diff --git a/vendor/k8s.io/client-go/pkg/util/validation/validation.go b/vendor/k8s.io/apimachinery/pkg/util/validation/validation.go similarity index 73% rename from vendor/k8s.io/client-go/pkg/util/validation/validation.go rename to vendor/k8s.io/apimachinery/pkg/util/validation/validation.go index aaf6319088..b1fcc57081 100644 --- a/vendor/k8s.io/client-go/pkg/util/validation/validation.go +++ b/vendor/k8s.io/apimachinery/pkg/util/validation/validation.go @@ -27,6 +27,7 @@ import ( const qnameCharFmt string = "[A-Za-z0-9]" const qnameExtCharFmt string = "[-A-Za-z0-9_.]" const qualifiedNameFmt string = "(" + qnameCharFmt + qnameExtCharFmt + "*)?" + qnameCharFmt +const qualifiedNameErrMsg string = "must consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character" const qualifiedNameMaxLength int = 63 var qualifiedNameRegexp = regexp.MustCompile("^" + qualifiedNameFmt + "$") @@ -51,8 +52,8 @@ func IsQualifiedName(value string) []string { errs = append(errs, prefixEach(msgs, "prefix part ")...) } default: - return append(errs, RegexError(qualifiedNameFmt, "MyName", "my.name", "123-abc")+ - " with an optional DNS subdomain prefix and '/' (e.g. 'example.com/MyName'") + return append(errs, "a qualified name "+RegexError(qualifiedNameErrMsg, qualifiedNameFmt, "MyName", "my.name", "123-abc")+ + " with an optional DNS subdomain prefix and '/' (e.g. 'example.com/MyName')") } if len(name) == 0 { @@ -61,12 +62,13 @@ func IsQualifiedName(value string) []string { errs = append(errs, "name part "+MaxLenError(qualifiedNameMaxLength)) } if !qualifiedNameRegexp.MatchString(name) { - errs = append(errs, "name part "+RegexError(qualifiedNameFmt, "MyName", "my.name", "123-abc")) + errs = append(errs, "name part "+RegexError(qualifiedNameErrMsg, qualifiedNameFmt, "MyName", "my.name", "123-abc")) } return errs } const labelValueFmt string = "(" + qualifiedNameFmt + ")?" +const labelValueErrMsg string = "a valid label must be an empty string or consist of alphanumeric characters, '-', '_' or '.', and must start and end with an alphanumeric character" const LabelValueMaxLength int = 63 var labelValueRegexp = regexp.MustCompile("^" + labelValueFmt + "$") @@ -80,12 +82,13 @@ func IsValidLabelValue(value string) []string { errs = append(errs, MaxLenError(LabelValueMaxLength)) } if !labelValueRegexp.MatchString(value) { - errs = append(errs, RegexError(labelValueFmt, "MyValue", "my_value", "12345")) + errs = append(errs, RegexError(labelValueErrMsg, labelValueFmt, "MyValue", "my_value", "12345")) } return errs } const dns1123LabelFmt string = "[a-z0-9]([-a-z0-9]*[a-z0-9])?" +const dns1123LabelErrMsg string = "a DNS-1123 label must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character" const DNS1123LabelMaxLength int = 63 var dns1123LabelRegexp = regexp.MustCompile("^" + dns1123LabelFmt + "$") @@ -98,12 +101,13 @@ func IsDNS1123Label(value string) []string { errs = append(errs, MaxLenError(DNS1123LabelMaxLength)) } if !dns1123LabelRegexp.MatchString(value) { - errs = append(errs, RegexError(dns1123LabelFmt, "my-name", "123-abc")) + errs = append(errs, RegexError(dns1123LabelErrMsg, dns1123LabelFmt, "my-name", "123-abc")) } return errs } const dns1123SubdomainFmt string = dns1123LabelFmt + "(\\." + dns1123LabelFmt + ")*" +const dns1123SubdomainErrorMsg string = "a DNS-1123 subdomain must consist of lower case alphanumeric characters, '-' or '.', and must start and end with an alphanumeric character" const DNS1123SubdomainMaxLength int = 253 var dns1123SubdomainRegexp = regexp.MustCompile("^" + dns1123SubdomainFmt + "$") @@ -116,12 +120,13 @@ func IsDNS1123Subdomain(value string) []string { errs = append(errs, MaxLenError(DNS1123SubdomainMaxLength)) } if !dns1123SubdomainRegexp.MatchString(value) { - errs = append(errs, RegexError(dns1123SubdomainFmt, "example.com")) + errs = append(errs, RegexError(dns1123SubdomainErrorMsg, dns1123SubdomainFmt, "example.com")) } return errs } const dns1035LabelFmt string = "[a-z]([-a-z0-9]*[a-z0-9])?" +const dns1035LabelErrMsg string = "a DNS-1035 label must consist of lower case alphanumeric characters or '-', and must start and end with an alphanumeric character" const DNS1035LabelMaxLength int = 63 var dns1035LabelRegexp = regexp.MustCompile("^" + dns1035LabelFmt + "$") @@ -134,7 +139,7 @@ func IsDNS1035Label(value string) []string { errs = append(errs, MaxLenError(DNS1035LabelMaxLength)) } if !dns1035LabelRegexp.MatchString(value) { - errs = append(errs, RegexError(dns1035LabelFmt, "my-name", "abc-123")) + errs = append(errs, RegexError(dns1035LabelErrMsg, dns1035LabelFmt, "my-name", "abc-123")) } return errs } @@ -143,24 +148,26 @@ func IsDNS1035Label(value string) []string { // examples: // - valid: *.bar.com, *.foo.bar.com // - invalid: *.*.bar.com, *.foo.*.com, *bar.com, f*.bar.com, * -const wildcardDNF1123SubdomainFmt = "\\*\\." + dns1123SubdomainFmt +const wildcardDNS1123SubdomainFmt = "\\*\\." + dns1123SubdomainFmt +const wildcardDNS1123SubdomainErrMsg = "a wildcard DNS-1123 subdomain must start with '*.', followed by a valid DNS subdomain, which must consist of lower case alphanumeric characters, '-' or '.' and end with an alphanumeric character" // IsWildcardDNS1123Subdomain tests for a string that conforms to the definition of a // wildcard subdomain in DNS (RFC 1034 section 4.3.3). func IsWildcardDNS1123Subdomain(value string) []string { - wildcardDNS1123SubdomainRegexp := regexp.MustCompile("^\\*\\." + dns1123SubdomainFmt + "$") + wildcardDNS1123SubdomainRegexp := regexp.MustCompile("^" + wildcardDNS1123SubdomainFmt + "$") var errs []string if len(value) > DNS1123SubdomainMaxLength { errs = append(errs, MaxLenError(DNS1123SubdomainMaxLength)) } if !wildcardDNS1123SubdomainRegexp.MatchString(value) { - errs = append(errs, RegexError(wildcardDNF1123SubdomainFmt, "*.example.com")) + errs = append(errs, RegexError(wildcardDNS1123SubdomainErrMsg, wildcardDNS1123SubdomainFmt, "*.example.com")) } return errs } const cIdentifierFmt string = "[A-Za-z_][A-Za-z0-9_]*" +const identifierErrMsg string = "a valid C identifier must start with alphabetic character or '_', followed by a string of alphanumeric characters or '_'" var cIdentifierRegexp = regexp.MustCompile("^" + cIdentifierFmt + "$") @@ -168,7 +175,7 @@ var cIdentifierRegexp = regexp.MustCompile("^" + cIdentifierFmt + "$") // in C. This checks the format, but not the length. func IsCIdentifier(value string) []string { if !cIdentifierRegexp.MatchString(value) { - return []string{RegexError(cIdentifierFmt, "my_name", "MY_NAME", "MyName")} + return []string{RegexError(identifierErrMsg, cIdentifierFmt, "my_name", "MY_NAME", "MyName")} } return nil } @@ -190,16 +197,16 @@ const ( maxGroupID = math.MaxInt32 ) -// IsValidGroupId tests that the argument is a valid Unix GID. -func IsValidGroupId(gid int64) []string { +// IsValidGroupID tests that the argument is a valid Unix GID. +func IsValidGroupID(gid int64) []string { if minGroupID <= gid && gid <= maxGroupID { return nil } return []string{InclusiveRangeError(minGroupID, maxGroupID)} } -// IsValidUserId tests that the argument is a valid Unix UID. -func IsValidUserId(uid int64) []string { +// IsValidUserID tests that the argument is a valid Unix UID. +func IsValidUserID(uid int64) []string { if minUserID <= uid && uid <= maxUserID { return nil } @@ -245,17 +252,19 @@ func IsValidIP(value string) []string { } const percentFmt string = "[0-9]+%" +const percentErrMsg string = "a valid percent string must be a numeric string followed by an ending '%'" var percentRegexp = regexp.MustCompile("^" + percentFmt + "$") func IsValidPercent(percent string) []string { if !percentRegexp.MatchString(percent) { - return []string{RegexError(percentFmt, "1%", "93%")} + return []string{RegexError(percentErrMsg, percentFmt, "1%", "93%")} } return nil } const httpHeaderNameFmt string = "[-A-Za-z0-9]+" +const httpHeaderNameErrMsg string = "a valid HTTP header must consist of alphanumeric characters or '-'" var httpHeaderNameRegexp = regexp.MustCompile("^" + httpHeaderNameFmt + "$") @@ -263,12 +272,13 @@ var httpHeaderNameRegexp = regexp.MustCompile("^" + httpHeaderNameFmt + "$") // definition of a valid header field name (a stricter subset than RFC7230). func IsHTTPHeaderName(value string) []string { if !httpHeaderNameRegexp.MatchString(value) { - return []string{RegexError(httpHeaderNameFmt, "X-Header-Name")} + return []string{RegexError(httpHeaderNameErrMsg, httpHeaderNameFmt, "X-Header-Name")} } return nil } const configMapKeyFmt = `[-._a-zA-Z0-9]+` +const configMapKeyErrMsg string = "a valid config key must consist of alphanumeric characters, '-', '_' or '.'" var configMapKeyRegexp = regexp.MustCompile("^" + configMapKeyFmt + "$") @@ -279,12 +289,11 @@ func IsConfigMapKey(value string) []string { errs = append(errs, MaxLenError(DNS1123SubdomainMaxLength)) } if !configMapKeyRegexp.MatchString(value) { - errs = append(errs, RegexError(configMapKeyFmt, "key.name", "KEY_NAME", "key-name")) + errs = append(errs, RegexError(configMapKeyErrMsg, configMapKeyFmt, "key.name", "KEY_NAME", "key-name")) } if value == "." { errs = append(errs, `must not be '.'`) - } - if value == ".." { + } else if value == ".." { errs = append(errs, `must not be '..'`) } else if strings.HasPrefix(value, "..") { errs = append(errs, `must not start with '..'`) @@ -299,19 +308,19 @@ func MaxLenError(length int) string { } // RegexError returns a string explanation of a regex validation failure. -func RegexError(fmt string, examples ...string) string { - s := "must match the regex " + fmt +func RegexError(msg string, fmt string, examples ...string) string { if len(examples) == 0 { - return s + return msg + " (regex used for validation is '" + fmt + "')" } - s += " (e.g. " + msg += " (e.g. " for i := range examples { if i > 0 { - s += " or " + msg += " or " } - s += "'" + examples[i] + "'" + msg += "'" + examples[i] + "', " } - return s + ")" + msg += "regex used for validation is '" + fmt + "')" + return msg } // EmptyError returns a string explanation of a "must not be empty" validation diff --git a/vendor/k8s.io/apimachinery/pkg/util/wait/BUILD b/vendor/k8s.io/apimachinery/pkg/util/wait/BUILD new file mode 100644 index 0000000000..3a98b65b92 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/wait/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["wait_test.go"], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "wait.go", + ], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/wait/doc.go b/vendor/k8s.io/apimachinery/pkg/util/wait/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/wait/doc.go rename to vendor/k8s.io/apimachinery/pkg/util/wait/doc.go diff --git a/vendor/k8s.io/client-go/pkg/util/wait/wait.go b/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go similarity index 92% rename from vendor/k8s.io/client-go/pkg/util/wait/wait.go rename to vendor/k8s.io/apimachinery/pkg/util/wait/wait.go index 5bda688b0c..badaa21596 100644 --- a/vendor/k8s.io/client-go/pkg/util/wait/wait.go +++ b/vendor/k8s.io/apimachinery/pkg/util/wait/wait.go @@ -21,7 +21,7 @@ import ( "math/rand" "time" - "k8s.io/client-go/pkg/util/runtime" + "k8s.io/apimachinery/pkg/util/runtime" ) // For any test of the style: @@ -65,16 +65,18 @@ func NonSlidingUntil(f func(), period time.Duration, stopCh <-chan struct{}) { // JitterUntil loops until stop channel is closed, running f every period. // // If jitterFactor is positive, the period is jittered before every run of f. -// If jitterFactor is not positive, the period is unchanged and not jitterd. +// If jitterFactor is not positive, the period is unchanged and not jittered. // -// If slidingis true, the period is computed after f runs. If it is false then +// If sliding is true, the period is computed after f runs. If it is false then // period includes the runtime for f. // // Close stopCh to stop. f may not be invoked if stop channel is already // closed. Pass NeverStop to if you don't want it stop. func JitterUntil(f func(), period time.Duration, jitterFactor float64, sliding bool, stopCh <-chan struct{}) { - for { + var t *time.Timer + var sawTimeout bool + for { select { case <-stopCh: return @@ -86,9 +88,8 @@ func JitterUntil(f func(), period time.Duration, jitterFactor float64, sliding b jitteredPeriod = Jitter(period, jitterFactor) } - var t *time.Timer if !sliding { - t = time.NewTimer(jitteredPeriod) + t = resetOrReuseTimer(t, jitteredPeriod, sawTimeout) } func() { @@ -97,7 +98,7 @@ func JitterUntil(f func(), period time.Duration, jitterFactor float64, sliding b }() if sliding { - t = time.NewTimer(jitteredPeriod) + t = resetOrReuseTimer(t, jitteredPeriod, sawTimeout) } // NOTE: b/c there is no priority selection in golang @@ -109,6 +110,7 @@ func JitterUntil(f func(), period time.Duration, jitterFactor float64, sliding b case <-stopCh: return case <-t.C: + sawTimeout = true } } } @@ -136,14 +138,14 @@ type ConditionFunc func() (done bool, err error) // Backoff holds parameters applied to a Backoff function. type Backoff struct { Duration time.Duration // the base duration - Factor float64 // Duration is multipled by factor each iteration + Factor float64 // Duration is multiplied by factor each iteration Jitter float64 // The amount of jitter applied each iteration Steps int // Exit with error after this many steps } // ExponentialBackoff repeats a condition check with exponential backoff. // -// It checks the condition up to Steps times, increasing the wait by multipling +// It checks the condition up to Steps times, increasing the wait by multiplying // the previous duration by Factor. // // If Jitter is greater than zero, a random amount of each duration is added @@ -184,7 +186,9 @@ func Poll(interval, timeout time.Duration, condition ConditionFunc) error { } func pollInternal(wait WaitFunc, condition ConditionFunc) error { - return WaitFor(wait, condition, NeverStop) + done := make(chan struct{}) + defer close(done) + return WaitFor(wait, condition, done) } // PollImmediate tries a condition func until it returns true, an error, or the timeout @@ -330,3 +334,16 @@ func poller(interval, timeout time.Duration) WaitFunc { return ch }) } + +// resetOrReuseTimer avoids allocating a new timer if one is already in use. +// Not safe for multiple threads. +func resetOrReuseTimer(t *time.Timer, d time.Duration, sawTimeout bool) *time.Timer { + if t == nil { + return time.NewTimer(d) + } + if !t.Stop() && !sawTimeout { + <-t.C + } + t.Reset(d) + return t +} diff --git a/vendor/k8s.io/apimachinery/pkg/util/yaml/BUILD b/vendor/k8s.io/apimachinery/pkg/util/yaml/BUILD new file mode 100644 index 0000000000..645295f7cb --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/util/yaml/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["decoder_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["decoder.go"], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/ghodss/yaml:go_default_library", + "//vendor/github.com/golang/glog:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/yaml/decoder.go b/vendor/k8s.io/apimachinery/pkg/util/yaml/decoder.go similarity index 90% rename from vendor/k8s.io/client-go/pkg/util/yaml/decoder.go rename to vendor/k8s.io/apimachinery/pkg/util/yaml/decoder.go index ed503d0390..6ebfaea707 100644 --- a/vendor/k8s.io/client-go/pkg/util/yaml/decoder.go +++ b/vendor/k8s.io/apimachinery/pkg/util/yaml/decoder.go @@ -69,11 +69,10 @@ func (d *YAMLToJSONDecoder) Decode(into interface{}) error { } if len(bytes) != 0 { - data, err := yaml.YAMLToJSON(bytes) + err := yaml.Unmarshal(bytes, into) if err != nil { - return err + return YAMLSyntaxError{err} } - return json.Unmarshal(data, into) } return err } @@ -181,6 +180,24 @@ type YAMLOrJSONDecoder struct { bufferSize int decoder decoder + rawData []byte +} + +type JSONSyntaxError struct { + Line int + Err error +} + +func (e JSONSyntaxError) Error() string { + return fmt.Sprintf("json: line %d: %s", e.Line, e.Err.Error()) +} + +type YAMLSyntaxError struct { + err error +} + +func (e YAMLSyntaxError) Error() string { + return e.err.Error() } // NewYAMLOrJSONDecoder returns a decoder that will process YAML documents @@ -198,10 +215,11 @@ func NewYAMLOrJSONDecoder(r io.Reader, bufferSize int) *YAMLOrJSONDecoder { // provide object, or returns an error. func (d *YAMLOrJSONDecoder) Decode(into interface{}) error { if d.decoder == nil { - buffer, isJSON := GuessJSONStream(d.r, d.bufferSize) + buffer, origData, isJSON := GuessJSONStream(d.r, d.bufferSize) if isJSON { glog.V(4).Infof("decoding stream as JSON") d.decoder = json.NewDecoder(buffer) + d.rawData = origData } else { glog.V(4).Infof("decoding stream as YAML") d.decoder = NewYAMLToJSONDecoder(buffer) @@ -215,9 +233,19 @@ func (d *YAMLOrJSONDecoder) Decode(into interface{}) error { glog.V(4).Infof("reading stream failed: %v", readErr) } js := string(data) + + // if contents from io.Reader are not complete, + // use the original raw data to prevent panic + if int64(len(js)) <= syntax.Offset { + js = string(d.rawData) + } + start := strings.LastIndex(js[:syntax.Offset], "\n") + 1 line := strings.Count(js[:start], "\n") - return fmt.Errorf("json: line %d: %s", line, syntax.Error()) + return JSONSyntaxError{ + Line: line, + Err: fmt.Errorf(syntax.Error()), + } } } return err @@ -296,10 +324,10 @@ func (r *LineReader) Read() ([]byte, error) { // GuessJSONStream scans the provided reader up to size, looking // for an open brace indicating this is JSON. It will return the // bufio.Reader it creates for the consumer. -func GuessJSONStream(r io.Reader, size int) (io.Reader, bool) { +func GuessJSONStream(r io.Reader, size int) (io.Reader, []byte, bool) { buffer := bufio.NewReaderSize(r, size) b, _ := buffer.Peek(size) - return buffer, hasJSONPrefix(b) + return buffer, b, hasJSONPrefix(b) } var jsonPrefix = []byte("{") diff --git a/vendor/k8s.io/apimachinery/pkg/version/BUILD b/vendor/k8s.io/apimachinery/pkg/version/BUILD new file mode 100644 index 0000000000..c0ca2cff03 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/version/BUILD @@ -0,0 +1,17 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "types.go", + ], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/apimachinery/pkg/version/doc.go b/vendor/k8s.io/apimachinery/pkg/version/doc.go new file mode 100644 index 0000000000..00431d4899 --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/version/doc.go @@ -0,0 +1,19 @@ +/* +Copyright 2014 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Package version supplies the type for version information collected at build time. +// +k8s:openapi-gen=true +package version diff --git a/vendor/k8s.io/apimachinery/pkg/version/types.go b/vendor/k8s.io/apimachinery/pkg/version/types.go new file mode 100644 index 0000000000..72727b503b --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/version/types.go @@ -0,0 +1,37 @@ +/* +Copyright 2014 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package version + +// Info contains versioning information. +// TODO: Add []string of api versions supported? It's still unclear +// how we'll want to distribute that information. +type Info struct { + Major string `json:"major"` + Minor string `json:"minor"` + GitVersion string `json:"gitVersion"` + GitCommit string `json:"gitCommit"` + GitTreeState string `json:"gitTreeState"` + BuildDate string `json:"buildDate"` + GoVersion string `json:"goVersion"` + Compiler string `json:"compiler"` + Platform string `json:"platform"` +} + +// String returns info as a human-friendly version string. +func (info Info) String() string { + return info.GitVersion +} diff --git a/vendor/k8s.io/apimachinery/pkg/watch/BUILD b/vendor/k8s.io/apimachinery/pkg/watch/BUILD new file mode 100644 index 0000000000..29ca5c810c --- /dev/null +++ b/vendor/k8s.io/apimachinery/pkg/watch/BUILD @@ -0,0 +1,47 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "filter.go", + "mux.go", + "streamwatcher.go", + "until.go", + "watch.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + ], +) + +go_test( + name = "go_default_xtest", + srcs = [ + "filter_test.go", + "mux_test.go", + "streamwatcher_test.go", + "watch_test.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/watch/doc.go b/vendor/k8s.io/apimachinery/pkg/watch/doc.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/watch/doc.go rename to vendor/k8s.io/apimachinery/pkg/watch/doc.go diff --git a/vendor/k8s.io/client-go/pkg/watch/filter.go b/vendor/k8s.io/apimachinery/pkg/watch/filter.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/watch/filter.go rename to vendor/k8s.io/apimachinery/pkg/watch/filter.go diff --git a/vendor/k8s.io/client-go/pkg/watch/mux.go b/vendor/k8s.io/apimachinery/pkg/watch/mux.go similarity index 97% rename from vendor/k8s.io/client-go/pkg/watch/mux.go rename to vendor/k8s.io/apimachinery/pkg/watch/mux.go index 3c7cfd1b10..fafccd78ef 100644 --- a/vendor/k8s.io/client-go/pkg/watch/mux.go +++ b/vendor/k8s.io/apimachinery/pkg/watch/mux.go @@ -19,8 +19,8 @@ package watch import ( "sync" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // FullChannelBehavior controls how the Broadcaster reacts if a watcher's watch @@ -81,8 +81,8 @@ const internalRunFunctionMarker = "internal-do-function" // a function type we can shoehorn into the queue. type functionFakeRuntimeObject func() -func (obj functionFakeRuntimeObject) GetObjectKind() unversioned.ObjectKind { - return unversioned.EmptyObjectKind +func (obj functionFakeRuntimeObject) GetObjectKind() schema.ObjectKind { + return schema.EmptyObjectKind } // Execute f, blocking the incoming queue (and waiting for it to drain first). diff --git a/vendor/k8s.io/client-go/pkg/watch/streamwatcher.go b/vendor/k8s.io/apimachinery/pkg/watch/streamwatcher.go similarity index 96% rename from vendor/k8s.io/client-go/pkg/watch/streamwatcher.go rename to vendor/k8s.io/apimachinery/pkg/watch/streamwatcher.go index 5b0f6882f6..93bb1cdf7f 100644 --- a/vendor/k8s.io/client-go/pkg/watch/streamwatcher.go +++ b/vendor/k8s.io/apimachinery/pkg/watch/streamwatcher.go @@ -21,9 +21,9 @@ import ( "sync" "github.com/golang/glog" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/net" - utilruntime "k8s.io/client-go/pkg/util/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/net" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" ) // Decoder allows StreamWatcher to watch any stream for which a Decoder can be written. diff --git a/vendor/k8s.io/client-go/pkg/watch/until.go b/vendor/k8s.io/apimachinery/pkg/watch/until.go similarity index 91% rename from vendor/k8s.io/client-go/pkg/watch/until.go rename to vendor/k8s.io/apimachinery/pkg/watch/until.go index f05eecc824..c2772ddb57 100644 --- a/vendor/k8s.io/client-go/pkg/watch/until.go +++ b/vendor/k8s.io/apimachinery/pkg/watch/until.go @@ -17,9 +17,10 @@ limitations under the License. package watch import ( + "errors" "time" - "k8s.io/client-go/pkg/util/wait" + "k8s.io/apimachinery/pkg/util/wait" ) // ConditionFunc returns true if the condition has been reached, false if it has not been reached yet, @@ -28,6 +29,9 @@ import ( // from false to true). type ConditionFunc func(event Event) (bool, error) +// ErrWatchClosed is returned when the watch channel is closed before timeout in Until. +var ErrWatchClosed = errors.New("watch closed before Until timeout") + // Until reads items from the watch until each provided condition succeeds, and then returns the last watch // encountered. The first condition that returns an error terminates the watch (and the event is also returned). // If no event has been received, the returned event will be nil. @@ -61,7 +65,7 @@ func Until(timeout time.Duration, watcher Interface, conditions ...ConditionFunc select { case event, ok := <-ch: if !ok { - return lastEvent, wait.ErrWaitTimeout + return lastEvent, ErrWatchClosed } lastEvent = &event diff --git a/vendor/k8s.io/client-go/pkg/watch/watch.go b/vendor/k8s.io/apimachinery/pkg/watch/watch.go similarity index 99% rename from vendor/k8s.io/client-go/pkg/watch/watch.go rename to vendor/k8s.io/apimachinery/pkg/watch/watch.go index 0995e03c62..dd49c41f9a 100644 --- a/vendor/k8s.io/client-go/pkg/watch/watch.go +++ b/vendor/k8s.io/apimachinery/pkg/watch/watch.go @@ -20,7 +20,7 @@ import ( "fmt" "sync" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" "github.com/golang/glog" ) diff --git a/vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/BUILD b/vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/BUILD new file mode 100644 index 0000000000..985afc384f --- /dev/null +++ b/vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["deep_equal_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "deep_equal.go", + "type.go", + ], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/third_party/forked/golang/reflect/deep_equal.go b/vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/deep_equal.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/third_party/forked/golang/reflect/deep_equal.go rename to vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/deep_equal.go diff --git a/vendor/k8s.io/client-go/pkg/third_party/forked/golang/reflect/type.go b/vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/type.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/third_party/forked/golang/reflect/type.go rename to vendor/k8s.io/apimachinery/third_party/forked/golang/reflect/type.go diff --git a/vendor/k8s.io/client-go/LICENSE b/vendor/k8s.io/client-go/LICENSE index 00b2401109..d645695673 100644 --- a/vendor/k8s.io/client-go/LICENSE +++ b/vendor/k8s.io/client-go/LICENSE @@ -187,7 +187,7 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2014 The Kubernetes Authors. + Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/vendor/k8s.io/client-go/discovery/BUILD b/vendor/k8s.io/client-go/discovery/BUILD new file mode 100644 index 0000000000..987e41f87e --- /dev/null +++ b/vendor/k8s.io/client-go/discovery/BUILD @@ -0,0 +1,63 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "discovery_client.go", + "helper.go", + "restmapper.go", + "unstructured.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/emicklei/go-restful-swagger12:go_default_library", + "//vendor/github.com/go-openapi/loads:go_default_library", + "//vendor/github.com/go-openapi/spec:go_default_library", + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/version:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) + +go_test( + name = "go_default_xtest", + srcs = [ + "discovery_client_test.go", + "helper_blackbox_test.go", + "restmapper_test.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/emicklei/go-restful-swagger12:go_default_library", + "//vendor/github.com/go-openapi/spec:go_default_library", + "//vendor/github.com/stretchr/testify/assert:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/version:go_default_library", + "//vendor/k8s.io/client-go/discovery:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/rest/fake:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/discovery/discovery_client.go b/vendor/k8s.io/client-go/discovery/discovery_client.go index f9a3686962..0ee46b863b 100644 --- a/vendor/k8s.io/client-go/discovery/discovery_client.go +++ b/vendor/k8s.io/client-go/discovery/discovery_client.go @@ -23,26 +23,33 @@ import ( "sort" "strings" - "github.com/emicklei/go-restful/swagger" - - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/api/unversioned" + "github.com/emicklei/go-restful-swagger12" + + "github.com/go-openapi/loads" + "github.com/go-openapi/spec" + "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/apimachinery/pkg/version" + "k8s.io/client-go/kubernetes/scheme" "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer" - "k8s.io/client-go/pkg/version" - "k8s.io/client-go/rest" + restclient "k8s.io/client-go/rest" ) +// defaultRetries is the number of times a resource discovery is repeated if an api group disappears on the fly (e.g. ThirdPartyResources). +const defaultRetries = 2 + // DiscoveryInterface holds the methods that discover server-supported API groups, // versions and resources. type DiscoveryInterface interface { - RESTClient() rest.Interface + RESTClient() restclient.Interface ServerGroupsInterface ServerResourcesInterface ServerVersionInterface SwaggerSchemaInterface + OpenAPISchemaInterface } // CachedDiscoveryInterface is a DiscoveryInterface with cache invalidation and freshness. @@ -58,21 +65,21 @@ type CachedDiscoveryInterface interface { type ServerGroupsInterface interface { // ServerGroups returns the supported groups, with information like supported versions and the // preferred version. - ServerGroups() (*unversioned.APIGroupList, error) + ServerGroups() (*metav1.APIGroupList, error) } // ServerResourcesInterface has methods for obtaining supported resources on the API server type ServerResourcesInterface interface { // ServerResourcesForGroupVersion returns the supported resources for a group and version. - ServerResourcesForGroupVersion(groupVersion string) (*unversioned.APIResourceList, error) + ServerResourcesForGroupVersion(groupVersion string) (*metav1.APIResourceList, error) // ServerResources returns the supported resources for all groups and versions. - ServerResources() (map[string]*unversioned.APIResourceList, error) + ServerResources() ([]*metav1.APIResourceList, error) // ServerPreferredResources returns the supported resources with the version preferred by the // server. - ServerPreferredResources() ([]unversioned.GroupVersionResource, error) + ServerPreferredResources() ([]*metav1.APIResourceList, error) // ServerPreferredNamespacedResources returns the supported namespaced resources with the // version preferred by the server. - ServerPreferredNamespacedResources() ([]unversioned.GroupVersionResource, error) + ServerPreferredNamespacedResources() ([]*metav1.APIResourceList, error) } // ServerVersionInterface has a method for retrieving the server's version. @@ -84,23 +91,29 @@ type ServerVersionInterface interface { // SwaggerSchemaInterface has a method to retrieve the swagger schema. type SwaggerSchemaInterface interface { // SwaggerSchema retrieves and parses the swagger API schema the server supports. - SwaggerSchema(version unversioned.GroupVersion) (*swagger.ApiDeclaration, error) + SwaggerSchema(version schema.GroupVersion) (*swagger.ApiDeclaration, error) +} + +// OpenAPISchemaInterface has a method to retrieve the open API schema. +type OpenAPISchemaInterface interface { + // OpenAPISchema retrieves and parses the swagger API schema the server supports. + OpenAPISchema() (*spec.Swagger, error) } // DiscoveryClient implements the functions that discover server-supported API groups, // versions and resources. type DiscoveryClient struct { - restClient rest.Interface + restClient restclient.Interface LegacyPrefix string } -// Convert unversioned.APIVersions to unversioned.APIGroup. APIVersions is used by legacy v1, so +// Convert metav1.APIVersions to metav1.APIGroup. APIVersions is used by legacy v1, so // group would be "". -func apiVersionsToAPIGroup(apiVersions *unversioned.APIVersions) (apiGroup unversioned.APIGroup) { - groupVersions := []unversioned.GroupVersionForDiscovery{} +func apiVersionsToAPIGroup(apiVersions *metav1.APIVersions) (apiGroup metav1.APIGroup) { + groupVersions := []metav1.GroupVersionForDiscovery{} for _, version := range apiVersions.Versions { - groupVersion := unversioned.GroupVersionForDiscovery{ + groupVersion := metav1.GroupVersionForDiscovery{ GroupVersion: version, Version: version, } @@ -114,12 +127,12 @@ func apiVersionsToAPIGroup(apiVersions *unversioned.APIVersions) (apiGroup unver // ServerGroups returns the supported groups, with information like supported versions and the // preferred version. -func (d *DiscoveryClient) ServerGroups() (apiGroupList *unversioned.APIGroupList, err error) { +func (d *DiscoveryClient) ServerGroups() (apiGroupList *metav1.APIGroupList, err error) { // Get the groupVersions exposed at /api - v := &unversioned.APIVersions{} + v := &metav1.APIVersions{} err = d.restClient.Get().AbsPath(d.LegacyPrefix).Do().Into(v) - apiGroup := unversioned.APIGroup{} - if err == nil { + apiGroup := metav1.APIGroup{} + if err == nil && len(v.Versions) != 0 { apiGroup = apiVersionsToAPIGroup(v) } if err != nil && !errors.IsNotFound(err) && !errors.IsForbidden(err) { @@ -127,23 +140,25 @@ func (d *DiscoveryClient) ServerGroups() (apiGroupList *unversioned.APIGroupList } // Get the groupVersions exposed at /apis - apiGroupList = &unversioned.APIGroupList{} + apiGroupList = &metav1.APIGroupList{} err = d.restClient.Get().AbsPath("/apis").Do().Into(apiGroupList) if err != nil && !errors.IsNotFound(err) && !errors.IsForbidden(err) { return nil, err } // to be compatible with a v1.0 server, if it's a 403 or 404, ignore and return whatever we got from /api if err != nil && (errors.IsNotFound(err) || errors.IsForbidden(err)) { - apiGroupList = &unversioned.APIGroupList{} + apiGroupList = &metav1.APIGroupList{} } - // append the group retrieved from /api to the list - apiGroupList.Groups = append(apiGroupList.Groups, apiGroup) + // append the group retrieved from /api to the list if not empty + if len(v.Versions) != 0 { + apiGroupList.Groups = append(apiGroupList.Groups, apiGroup) + } return apiGroupList, nil } // ServerResourcesForGroupVersion returns the supported resources for a group and version. -func (d *DiscoveryClient) ServerResourcesForGroupVersion(groupVersion string) (resources *unversioned.APIResourceList, err error) { +func (d *DiscoveryClient) ServerResourcesForGroupVersion(groupVersion string) (resources *metav1.APIResourceList, err error) { url := url.URL{} if len(groupVersion) == 0 { return nil, fmt.Errorf("groupVersion shouldn't be empty") @@ -153,7 +168,9 @@ func (d *DiscoveryClient) ServerResourcesForGroupVersion(groupVersion string) (r } else { url.Path = "/apis/" + groupVersion } - resources = &unversioned.APIResourceList{} + resources = &metav1.APIResourceList{ + GroupVersion: groupVersion, + } err = d.restClient.Get().AbsPath(url.String()).Do().Into(resources) if err != nil { // ignore 403 or 404 error to be compatible with an v1.0 server. @@ -165,28 +182,49 @@ func (d *DiscoveryClient) ServerResourcesForGroupVersion(groupVersion string) (r return resources, nil } -// ServerResources returns the supported resources for all groups and versions. -func (d *DiscoveryClient) ServerResources() (map[string]*unversioned.APIResourceList, error) { +// serverResources returns the supported resources for all groups and versions. +func (d *DiscoveryClient) serverResources(failEarly bool) ([]*metav1.APIResourceList, error) { apiGroups, err := d.ServerGroups() if err != nil { return nil, err } - groupVersions := unversioned.ExtractGroupVersions(apiGroups) - result := map[string]*unversioned.APIResourceList{} - for _, groupVersion := range groupVersions { - resources, err := d.ServerResourcesForGroupVersion(groupVersion) - if err != nil { - return nil, err + + result := []*metav1.APIResourceList{} + failedGroups := make(map[schema.GroupVersion]error) + + for _, apiGroup := range apiGroups.Groups { + for _, version := range apiGroup.Versions { + gv := schema.GroupVersion{Group: apiGroup.Name, Version: version.Version} + resources, err := d.ServerResourcesForGroupVersion(version.GroupVersion) + if err != nil { + // TODO: maybe restrict this to NotFound errors + failedGroups[gv] = err + if failEarly { + return nil, &ErrGroupDiscoveryFailed{Groups: failedGroups} + } + continue + } + + result = append(result, resources) } - result[groupVersion] = resources } - return result, nil + + if len(failedGroups) == 0 { + return result, nil + } + + return result, &ErrGroupDiscoveryFailed{Groups: failedGroups} +} + +// ServerResources returns the supported resources for all groups and versions. +func (d *DiscoveryClient) ServerResources() ([]*metav1.APIResourceList, error) { + return withRetries(defaultRetries, d.serverResources) } // ErrGroupDiscoveryFailed is returned if one or more API groups fail to load. type ErrGroupDiscoveryFailed struct { // Groups is a list of the groups that failed to load and the error cause - Groups map[unversioned.GroupVersion]error + Groups map[schema.GroupVersion]error } // Error implements the error interface @@ -206,61 +244,86 @@ func IsGroupDiscoveryFailedError(err error) bool { return err != nil && ok } -// serverPreferredResources returns the supported resources with the version preferred by the -// server. If namespaced is true, only namespaced resources will be returned. -func (d *DiscoveryClient) serverPreferredResources(namespaced bool) ([]unversioned.GroupVersionResource, error) { - // retry in case the groups supported by the server change after ServerGroup() returns. - const maxRetries = 2 - var failedGroups map[unversioned.GroupVersion]error - var results []unversioned.GroupVersionResource -RetrieveGroups: - for i := 0; i < maxRetries; i++ { - results = []unversioned.GroupVersionResource{} - failedGroups = make(map[unversioned.GroupVersion]error) - serverGroupList, err := d.ServerGroups() - if err != nil { - return results, err - } +// serverPreferredResources returns the supported resources with the version preferred by the server. +func (d *DiscoveryClient) serverPreferredResources(failEarly bool) ([]*metav1.APIResourceList, error) { + serverGroupList, err := d.ServerGroups() + if err != nil { + return nil, err + } + + result := []*metav1.APIResourceList{} + failedGroups := make(map[schema.GroupVersion]error) + + grVersions := map[schema.GroupResource]string{} // selected version of a GroupResource + grApiResources := map[schema.GroupResource]*metav1.APIResource{} // selected APIResource for a GroupResource + gvApiResourceLists := map[schema.GroupVersion]*metav1.APIResourceList{} // blueprint for a APIResourceList for later grouping - for _, apiGroup := range serverGroupList.Groups { - preferredVersion := apiGroup.PreferredVersion - groupVersion := unversioned.GroupVersion{Group: apiGroup.Name, Version: preferredVersion.Version} - apiResourceList, err := d.ServerResourcesForGroupVersion(preferredVersion.GroupVersion) + for _, apiGroup := range serverGroupList.Groups { + for _, version := range apiGroup.Versions { + groupVersion := schema.GroupVersion{Group: apiGroup.Name, Version: version.Version} + apiResourceList, err := d.ServerResourcesForGroupVersion(version.GroupVersion) if err != nil { - if i < maxRetries-1 { - continue RetrieveGroups - } + // TODO: maybe restrict this to NotFound errors failedGroups[groupVersion] = err + if failEarly { + return nil, &ErrGroupDiscoveryFailed{Groups: failedGroups} + } continue } - for _, apiResource := range apiResourceList.APIResources { - // ignore the root scoped resources if "namespaced" is true. - if namespaced && !apiResource.Namespaced { + + // create empty list which is filled later in another loop + emptyApiResourceList := metav1.APIResourceList{ + GroupVersion: version.GroupVersion, + } + gvApiResourceLists[groupVersion] = &emptyApiResourceList + result = append(result, &emptyApiResourceList) + + for i := range apiResourceList.APIResources { + apiResource := &apiResourceList.APIResources[i] + if strings.Contains(apiResource.Name, "/") { continue } - if strings.Contains(apiResource.Name, "/") { + gv := schema.GroupResource{Group: apiGroup.Name, Resource: apiResource.Name} + if _, ok := grApiResources[gv]; ok && version.Version != apiGroup.PreferredVersion.Version { + // only override with preferred version continue } - results = append(results, groupVersion.WithResource(apiResource.Name)) + grVersions[gv] = version.Version + grApiResources[gv] = apiResource } } - if len(failedGroups) == 0 { - return results, nil - } } - return results, &ErrGroupDiscoveryFailed{Groups: failedGroups} + + // group selected APIResources according to GroupVersion into APIResourceLists + for groupResource, apiResource := range grApiResources { + version := grVersions[groupResource] + groupVersion := schema.GroupVersion{Group: groupResource.Group, Version: version} + apiResourceList := gvApiResourceLists[groupVersion] + apiResourceList.APIResources = append(apiResourceList.APIResources, *apiResource) + } + + if len(failedGroups) == 0 { + return result, nil + } + + return result, &ErrGroupDiscoveryFailed{Groups: failedGroups} } // ServerPreferredResources returns the supported resources with the version preferred by the // server. -func (d *DiscoveryClient) ServerPreferredResources() ([]unversioned.GroupVersionResource, error) { - return d.serverPreferredResources(false) +func (d *DiscoveryClient) ServerPreferredResources() ([]*metav1.APIResourceList, error) { + return withRetries(defaultRetries, func(retryEarly bool) ([]*metav1.APIResourceList, error) { + return d.serverPreferredResources(retryEarly) + }) } // ServerPreferredNamespacedResources returns the supported namespaced resources with the // version preferred by the server. -func (d *DiscoveryClient) ServerPreferredNamespacedResources() ([]unversioned.GroupVersionResource, error) { - return d.serverPreferredResources(true) +func (d *DiscoveryClient) ServerPreferredNamespacedResources() ([]*metav1.APIResourceList, error) { + all, err := d.ServerPreferredResources() + return FilteredBy(ResourcePredicateFunc(func(groupVersion string, r *metav1.APIResource) bool { + return r.Namespaced + }), all), err } // ServerVersion retrieves and parses the server's version (git version). @@ -278,7 +341,8 @@ func (d *DiscoveryClient) ServerVersion() (*version.Info, error) { } // SwaggerSchema retrieves and parses the swagger API schema the server supports. -func (d *DiscoveryClient) SwaggerSchema(version unversioned.GroupVersion) (*swagger.ApiDeclaration, error) { +// TODO: Replace usages with Open API. Tracked in https://github.com/kubernetes/kubernetes/issues/44589 +func (d *DiscoveryClient) SwaggerSchema(version schema.GroupVersion) (*swagger.ApiDeclaration, error) { if version.Empty() { return nil, fmt.Errorf("groupVersion cannot be empty") } @@ -287,7 +351,7 @@ func (d *DiscoveryClient) SwaggerSchema(version unversioned.GroupVersion) (*swag if err != nil { return nil, err } - groupVersions := unversioned.ExtractGroupVersions(groupList) + groupVersions := metav1.ExtractGroupVersions(groupList) // This check also takes care the case that kubectl is newer than the running endpoint if stringDoesntExistIn(version.String(), groupVersions) { return nil, fmt.Errorf("API version: %v is not supported by the server. Use one of: %v", version, groupVersions) @@ -311,31 +375,63 @@ func (d *DiscoveryClient) SwaggerSchema(version unversioned.GroupVersion) (*swag return &schema, nil } -func setDiscoveryDefaults(config *rest.Config) error { +// OpenAPISchema fetches the open api schema using a rest client and parses the json. +// Warning: this is very expensive (~1.2s) +func (d *DiscoveryClient) OpenAPISchema() (*spec.Swagger, error) { + data, err := d.restClient.Get().AbsPath("/swagger.json").Do().Raw() + if err != nil { + return nil, err + } + msg := json.RawMessage(data) + doc, err := loads.Analyzed(msg, "") + if err != nil { + return nil, err + } + return doc.Spec(), err +} + +// withRetries retries the given recovery function in case the groups supported by the server change after ServerGroup() returns. +func withRetries(maxRetries int, f func(failEarly bool) ([]*metav1.APIResourceList, error)) ([]*metav1.APIResourceList, error) { + var result []*metav1.APIResourceList + var err error + for i := 0; i < maxRetries; i++ { + failEarly := i < maxRetries-1 + result, err = f(failEarly) + if err == nil { + return result, nil + } + if _, ok := err.(*ErrGroupDiscoveryFailed); !ok { + return nil, err + } + } + return result, err +} + +func setDiscoveryDefaults(config *restclient.Config) error { config.APIPath = "" config.GroupVersion = nil - codec := runtime.NoopEncoder{Decoder: api.Codecs.UniversalDecoder()} + codec := runtime.NoopEncoder{Decoder: scheme.Codecs.UniversalDecoder()} config.NegotiatedSerializer = serializer.NegotiatedSerializerWrapper(runtime.SerializerInfo{Serializer: codec}) if len(config.UserAgent) == 0 { - config.UserAgent = rest.DefaultKubernetesUserAgent() + config.UserAgent = restclient.DefaultKubernetesUserAgent() } return nil } // NewDiscoveryClientForConfig creates a new DiscoveryClient for the given config. This client // can be used to discover supported resources in the API server. -func NewDiscoveryClientForConfig(c *rest.Config) (*DiscoveryClient, error) { +func NewDiscoveryClientForConfig(c *restclient.Config) (*DiscoveryClient, error) { config := *c if err := setDiscoveryDefaults(&config); err != nil { return nil, err } - client, err := rest.UnversionedRESTClientFor(&config) + client, err := restclient.UnversionedRESTClientFor(&config) return &DiscoveryClient{restClient: client, LegacyPrefix: "/api"}, err } // NewDiscoveryClientForConfig creates a new DiscoveryClient for the given config. If // there is an error, it panics. -func NewDiscoveryClientForConfigOrDie(c *rest.Config) *DiscoveryClient { +func NewDiscoveryClientForConfigOrDie(c *restclient.Config) *DiscoveryClient { client, err := NewDiscoveryClientForConfig(c) if err != nil { panic(err) @@ -345,7 +441,7 @@ func NewDiscoveryClientForConfigOrDie(c *rest.Config) *DiscoveryClient { } // New creates a new DiscoveryClient for the given RESTClient. -func NewDiscoveryClient(c rest.Interface) *DiscoveryClient { +func NewDiscoveryClient(c restclient.Interface) *DiscoveryClient { return &DiscoveryClient{restClient: c, LegacyPrefix: "/api"} } @@ -360,7 +456,7 @@ func stringDoesntExistIn(str string, slice []string) bool { // RESTClient returns a RESTClient that is used to communicate // with API server by this client implementation. -func (c *DiscoveryClient) RESTClient() rest.Interface { +func (c *DiscoveryClient) RESTClient() restclient.Interface { if c == nil { return nil } diff --git a/vendor/k8s.io/client-go/discovery/helper.go b/vendor/k8s.io/client-go/discovery/helper.go index 9494735ddf..353d34b3c5 100644 --- a/vendor/k8s.io/client-go/discovery/helper.go +++ b/vendor/k8s.io/client-go/discovery/helper.go @@ -19,91 +19,103 @@ package discovery import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/util/sets" - "k8s.io/client-go/pkg/version" - // Import solely to initialize client auth plugins. - _ "k8s.io/client-go/plugin/pkg/client/auth" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/sets" + apimachineryversion "k8s.io/apimachinery/pkg/version" ) // MatchesServerVersion queries the server to compares the build version // (git hash) of the client with the server's build version. It returns an error // if it failed to contact the server or if the versions are not an exact match. -func MatchesServerVersion(client DiscoveryInterface) error { - cVer := version.Get() +func MatchesServerVersion(clientVersion apimachineryversion.Info, client DiscoveryInterface) error { sVer, err := client.ServerVersion() if err != nil { return fmt.Errorf("couldn't read version from server: %v\n", err) } // GitVersion includes GitCommit and GitTreeState, but best to be safe? - if cVer.GitVersion != sVer.GitVersion || cVer.GitCommit != sVer.GitCommit || cVer.GitTreeState != sVer.GitTreeState { - return fmt.Errorf("server version (%#v) differs from client version (%#v)!\n", sVer, cVer) + if clientVersion.GitVersion != sVer.GitVersion || clientVersion.GitCommit != sVer.GitCommit || clientVersion.GitTreeState != sVer.GitTreeState { + return fmt.Errorf("server version (%#v) differs from client version (%#v)!\n", sVer, clientVersion) } return nil } -// NegotiateVersion queries the server's supported api versions to find -// a version that both client and server support. -// - If no version is provided, try registered client versions in order of -// preference. -// - If version is provided and the server does not support it, -// return an error. -func NegotiateVersion(client DiscoveryInterface, requiredGV *unversioned.GroupVersion, clientRegisteredGVs []unversioned.GroupVersion) (*unversioned.GroupVersion, error) { - clientVersions := sets.String{} - for _, gv := range clientRegisteredGVs { - clientVersions.Insert(gv.String()) - } +// ServerSupportsVersion returns an error if the server doesn't have the required version +func ServerSupportsVersion(client DiscoveryInterface, requiredGV schema.GroupVersion) error { groups, err := client.ServerGroups() if err != nil { // This is almost always a connection error, and higher level code should treat this as a generic error, // not a negotiation specific error. - return nil, err + return err } - versions := unversioned.ExtractGroupVersions(groups) + versions := metav1.ExtractGroupVersions(groups) serverVersions := sets.String{} for _, v := range versions { serverVersions.Insert(v) } - // If version explicitly requested verify that both client and server support it. - // If server does not support warn, but try to negotiate a lower version. - if requiredGV != nil { - if !clientVersions.Has(requiredGV.String()) { - return nil, fmt.Errorf("client does not support API version %q; client supported API versions: %v", requiredGV, clientVersions) + if serverVersions.Has(requiredGV.String()) { + return nil + } + // If the server supports no versions, then we should pretend it has the version because of old servers. + // This can happen because discovery fails due to 403 Forbidden errors + if len(serverVersions) == 0 { + return nil + } + + return fmt.Errorf("server does not support API version %q", requiredGV) +} + +// GroupVersionResources converts APIResourceLists to the GroupVersionResources. +func GroupVersionResources(rls []*metav1.APIResourceList) (map[schema.GroupVersionResource]struct{}, error) { + gvrs := map[schema.GroupVersionResource]struct{}{} + for _, rl := range rls { + gv, err := schema.ParseGroupVersion(rl.GroupVersion) + if err != nil { + return nil, err } - // If the server supports no versions, then we should just use the preferredGV - // This can happen because discovery fails due to 403 Forbidden errors - if len(serverVersions) == 0 { - return requiredGV, nil - } - if serverVersions.Has(requiredGV.String()) { - return requiredGV, nil + for i := range rl.APIResources { + gvrs[schema.GroupVersionResource{Group: gv.Group, Version: gv.Version, Resource: rl.APIResources[i].Name}] = struct{}{} } - // If we are using an explicit config version the server does not support, fail. - return nil, fmt.Errorf("server does not support API version %q", requiredGV) } + return gvrs, nil +} - for _, clientGV := range clientRegisteredGVs { - if serverVersions.Has(clientGV.String()) { - // Version was not explicitly requested in command config (--api-version). - // Ok to fall back to a supported version with a warning. - // TODO: caesarxuchao: enable the warning message when we have - // proper fix. Please refer to issue #14895. - // if len(version) != 0 { - // glog.Warningf("Server does not support API version '%s'. Falling back to '%s'.", version, clientVersion) - // } - t := clientGV - return &t, nil +// FilteredBy filters by the given predicate. Empty APIResourceLists are dropped. +func FilteredBy(pred ResourcePredicate, rls []*metav1.APIResourceList) []*metav1.APIResourceList { + result := []*metav1.APIResourceList{} + for _, rl := range rls { + filtered := *rl + filtered.APIResources = nil + for i := range rl.APIResources { + if pred.Match(rl.GroupVersion, &rl.APIResources[i]) { + filtered.APIResources = append(filtered.APIResources, rl.APIResources[i]) + } + } + if filtered.APIResources != nil { + result = append(result, &filtered) } } + return result +} - // if we have no server versions and we have no required version, choose the first clientRegisteredVersion - if len(serverVersions) == 0 && len(clientRegisteredGVs) > 0 { - return &clientRegisteredGVs[0], nil - } +type ResourcePredicate interface { + Match(groupVersion string, r *metav1.APIResource) bool +} + +type ResourcePredicateFunc func(groupVersion string, r *metav1.APIResource) bool + +func (fn ResourcePredicateFunc) Match(groupVersion string, r *metav1.APIResource) bool { + return fn(groupVersion, r) +} + +// SupportsAllVerbs is a predicate matching a resource iff all given verbs are supported. +type SupportsAllVerbs struct { + Verbs []string +} - return nil, fmt.Errorf("failed to negotiate an api version; server supports: %v, client supports: %v", - serverVersions, clientVersions) +func (p SupportsAllVerbs) Match(groupVersion string, r *metav1.APIResource) bool { + return sets.NewString([]string(r.Verbs)...).HasAll(p.Verbs...) } diff --git a/vendor/k8s.io/client-go/discovery/restmapper.go b/vendor/k8s.io/client-go/discovery/restmapper.go index 7f846d2fb1..756669001f 100644 --- a/vendor/k8s.io/client-go/discovery/restmapper.go +++ b/vendor/k8s.io/client-go/discovery/restmapper.go @@ -20,9 +20,9 @@ import ( "fmt" "sync" - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/api/meta" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime/schema" "github.com/golang/glog" ) @@ -30,10 +30,10 @@ import ( // APIGroupResources is an API group with a mapping of versions to // resources. type APIGroupResources struct { - Group unversioned.APIGroup + Group metav1.APIGroup // A mapping of version string to a slice of APIResources for // that version. - VersionedResources map[string][]unversioned.APIResource + VersionedResources map[string][]metav1.APIResource } // NewRESTMapper returns a PriorityRESTMapper based on the discovered @@ -42,8 +42,9 @@ func NewRESTMapper(groupResources []*APIGroupResources, versionInterfaces meta.V unionMapper := meta.MultiRESTMapper{} var groupPriority []string - var resourcePriority []unversioned.GroupVersionResource - var kindPriority []unversioned.GroupVersionKind + // /v1 is special. It should always come first + resourcePriority := []schema.GroupVersionResource{{Group: "", Version: "v1", Resource: meta.AnyResource}} + kindPriority := []schema.GroupVersionKind{{Group: "", Version: "v1", Kind: meta.AnyKind}} for _, group := range groupResources { groupPriority = append(groupPriority, group.Group.Name) @@ -51,13 +52,13 @@ func NewRESTMapper(groupResources []*APIGroupResources, versionInterfaces meta.V if len(group.Group.PreferredVersion.Version) != 0 { preferred := group.Group.PreferredVersion.Version if _, ok := group.VersionedResources[preferred]; ok { - resourcePriority = append(resourcePriority, unversioned.GroupVersionResource{ + resourcePriority = append(resourcePriority, schema.GroupVersionResource{ Group: group.Group.Name, Version: group.Group.PreferredVersion.Version, Resource: meta.AnyResource, }) - kindPriority = append(kindPriority, unversioned.GroupVersionKind{ + kindPriority = append(kindPriority, schema.GroupVersionKind{ Group: group.Group.Name, Version: group.Group.PreferredVersion.Version, Kind: meta.AnyKind, @@ -71,8 +72,8 @@ func NewRESTMapper(groupResources []*APIGroupResources, versionInterfaces meta.V continue } - gv := unversioned.GroupVersion{Group: group.Group.Name, Version: discoveryVersion.Version} - versionMapper := meta.NewDefaultRESTMapper([]unversioned.GroupVersion{gv}, versionInterfaces) + gv := schema.GroupVersion{Group: group.Group.Name, Version: discoveryVersion.Version} + versionMapper := meta.NewDefaultRESTMapper([]schema.GroupVersion{gv}, versionInterfaces) for _, resource := range resources { scope := meta.RESTScopeNamespace @@ -90,12 +91,12 @@ func NewRESTMapper(groupResources []*APIGroupResources, versionInterfaces meta.V } for _, group := range groupPriority { - resourcePriority = append(resourcePriority, unversioned.GroupVersionResource{ + resourcePriority = append(resourcePriority, schema.GroupVersionResource{ Group: group, Version: meta.AnyVersion, Resource: meta.AnyResource, }) - kindPriority = append(kindPriority, unversioned.GroupVersionKind{ + kindPriority = append(kindPriority, schema.GroupVersionKind{ Group: group, Version: meta.AnyVersion, Kind: meta.AnyKind, @@ -120,15 +121,14 @@ func GetAPIGroupResources(cl DiscoveryInterface) ([]*APIGroupResources, error) { for _, group := range apiGroups.Groups { groupResources := &APIGroupResources{ Group: group, - VersionedResources: make(map[string][]unversioned.APIResource), + VersionedResources: make(map[string][]metav1.APIResource), } for _, version := range group.Versions { resources, err := cl.ServerResourcesForGroupVersion(version.GroupVersion) if err != nil { - if errors.IsNotFound(err) { - continue // ignore as this can race with deletion of 3rd party APIs - } - return nil, err + // continue as best we can + // TODO track the errors and update callers to handle partial errors. + continue } groupResources.VersionedResources[version.Version] = resources.APIResources } @@ -188,10 +188,10 @@ func (d *DeferredDiscoveryRESTMapper) Reset() { // KindFor takes a partial resource and returns back the single match. // It returns an error if there are multiple matches. -func (d *DeferredDiscoveryRESTMapper) KindFor(resource unversioned.GroupVersionResource) (gvk unversioned.GroupVersionKind, err error) { +func (d *DeferredDiscoveryRESTMapper) KindFor(resource schema.GroupVersionResource) (gvk schema.GroupVersionKind, err error) { del, err := d.getDelegate() if err != nil { - return unversioned.GroupVersionKind{}, err + return schema.GroupVersionKind{}, err } gvk, err = del.KindFor(resource) if err != nil && !d.cl.Fresh() { @@ -203,7 +203,7 @@ func (d *DeferredDiscoveryRESTMapper) KindFor(resource unversioned.GroupVersionR // KindsFor takes a partial resource and returns back the list of // potential kinds in priority order. -func (d *DeferredDiscoveryRESTMapper) KindsFor(resource unversioned.GroupVersionResource) (gvks []unversioned.GroupVersionKind, err error) { +func (d *DeferredDiscoveryRESTMapper) KindsFor(resource schema.GroupVersionResource) (gvks []schema.GroupVersionKind, err error) { del, err := d.getDelegate() if err != nil { return nil, err @@ -218,10 +218,10 @@ func (d *DeferredDiscoveryRESTMapper) KindsFor(resource unversioned.GroupVersion // ResourceFor takes a partial resource and returns back the single // match. It returns an error if there are multiple matches. -func (d *DeferredDiscoveryRESTMapper) ResourceFor(input unversioned.GroupVersionResource) (gvr unversioned.GroupVersionResource, err error) { +func (d *DeferredDiscoveryRESTMapper) ResourceFor(input schema.GroupVersionResource) (gvr schema.GroupVersionResource, err error) { del, err := d.getDelegate() if err != nil { - return unversioned.GroupVersionResource{}, err + return schema.GroupVersionResource{}, err } gvr, err = del.ResourceFor(input) if err != nil && !d.cl.Fresh() { @@ -233,7 +233,7 @@ func (d *DeferredDiscoveryRESTMapper) ResourceFor(input unversioned.GroupVersion // ResourcesFor takes a partial resource and returns back the list of // potential resource in priority order. -func (d *DeferredDiscoveryRESTMapper) ResourcesFor(input unversioned.GroupVersionResource) (gvrs []unversioned.GroupVersionResource, err error) { +func (d *DeferredDiscoveryRESTMapper) ResourcesFor(input schema.GroupVersionResource) (gvrs []schema.GroupVersionResource, err error) { del, err := d.getDelegate() if err != nil { return nil, err @@ -248,7 +248,7 @@ func (d *DeferredDiscoveryRESTMapper) ResourcesFor(input unversioned.GroupVersio // RESTMapping identifies a preferred resource mapping for the // provided group kind. -func (d *DeferredDiscoveryRESTMapper) RESTMapping(gk unversioned.GroupKind, versions ...string) (m *meta.RESTMapping, err error) { +func (d *DeferredDiscoveryRESTMapper) RESTMapping(gk schema.GroupKind, versions ...string) (m *meta.RESTMapping, err error) { del, err := d.getDelegate() if err != nil { return nil, err @@ -264,29 +264,15 @@ func (d *DeferredDiscoveryRESTMapper) RESTMapping(gk unversioned.GroupKind, vers // RESTMappings returns the RESTMappings for the provided group kind // in a rough internal preferred order. If no kind is found, it will // return a NoResourceMatchError. -func (d *DeferredDiscoveryRESTMapper) RESTMappings(gk unversioned.GroupKind) (ms []*meta.RESTMapping, err error) { +func (d *DeferredDiscoveryRESTMapper) RESTMappings(gk schema.GroupKind, versions ...string) (ms []*meta.RESTMapping, err error) { del, err := d.getDelegate() if err != nil { return nil, err } - ms, err = del.RESTMappings(gk) + ms, err = del.RESTMappings(gk, versions...) if len(ms) == 0 && !d.cl.Fresh() { d.Reset() - ms, err = d.RESTMappings(gk) - } - return -} - -// AliasesForResource returns whether a resource has an alias or not. -func (d *DeferredDiscoveryRESTMapper) AliasesForResource(resource string) (as []string, ok bool) { - del, err := d.getDelegate() - if err != nil { - return nil, false - } - as, ok = del.AliasesForResource(resource) - if len(as) == 0 && !d.cl.Fresh() { - d.Reset() - as, ok = d.AliasesForResource(resource) + ms, err = d.RESTMappings(gk, versions...) } return } diff --git a/vendor/k8s.io/client-go/discovery/unstructured.go b/vendor/k8s.io/client-go/discovery/unstructured.go index c4b8791fa2..ee72d668bc 100644 --- a/vendor/k8s.io/client-go/discovery/unstructured.go +++ b/vendor/k8s.io/client-go/discovery/unstructured.go @@ -19,20 +19,20 @@ package discovery import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // UnstructuredObjectTyper provides a runtime.ObjectTyper implmentation for // runtime.Unstructured object based on discovery information. type UnstructuredObjectTyper struct { - registered map[unversioned.GroupVersionKind]bool + registered map[schema.GroupVersionKind]bool } // NewUnstructuredObjectTyper returns a runtime.ObjectTyper for // unstructred objects based on discovery information. func NewUnstructuredObjectTyper(groupResources []*APIGroupResources) *UnstructuredObjectTyper { - dot := &UnstructuredObjectTyper{registered: make(map[unversioned.GroupVersionKind]bool)} + dot := &UnstructuredObjectTyper{registered: make(map[schema.GroupVersionKind]bool)} for _, group := range groupResources { for _, discoveryVersion := range group.Group.Versions { resources, ok := group.VersionedResources[discoveryVersion.Version] @@ -40,7 +40,7 @@ func NewUnstructuredObjectTyper(groupResources []*APIGroupResources) *Unstructur continue } - gv := unversioned.GroupVersion{Group: group.Group.Name, Version: discoveryVersion.Version} + gv := schema.GroupVersion{Group: group.Group.Name, Version: discoveryVersion.Version} for _, resource := range resources { dot.registered[gv.WithKind(resource.Kind)] = true } @@ -50,39 +50,39 @@ func NewUnstructuredObjectTyper(groupResources []*APIGroupResources) *Unstructur } // ObjectKind returns the group,version,kind of the provided object, or an error -// if the object in not *runtime.Unstructured or has no group,version,kind +// if the object in not runtime.Unstructured or has no group,version,kind // information. -func (d *UnstructuredObjectTyper) ObjectKind(obj runtime.Object) (unversioned.GroupVersionKind, error) { - if _, ok := obj.(*runtime.Unstructured); !ok { - return unversioned.GroupVersionKind{}, fmt.Errorf("type %T is invalid for dynamic object typer", obj) +func (d *UnstructuredObjectTyper) ObjectKind(obj runtime.Object) (schema.GroupVersionKind, error) { + if _, ok := obj.(runtime.Unstructured); !ok { + return schema.GroupVersionKind{}, fmt.Errorf("type %T is invalid for dynamic object typer", obj) } return obj.GetObjectKind().GroupVersionKind(), nil } // ObjectKinds returns a slice of one element with the group,version,kind of the -// provided object, or an error if the object is not *runtime.Unstructured or +// provided object, or an error if the object is not runtime.Unstructured or // has no group,version,kind information. unversionedType will always be false // because runtime.Unstructured object should always have group,version,kind // information set. -func (d *UnstructuredObjectTyper) ObjectKinds(obj runtime.Object) (gvks []unversioned.GroupVersionKind, unversionedType bool, err error) { +func (d *UnstructuredObjectTyper) ObjectKinds(obj runtime.Object) (gvks []schema.GroupVersionKind, unversionedType bool, err error) { gvk, err := d.ObjectKind(obj) if err != nil { return nil, false, err } - return []unversioned.GroupVersionKind{gvk}, false, nil + return []schema.GroupVersionKind{gvk}, false, nil } // Recognizes returns true if the provided group,version,kind was in the // discovery information. -func (d *UnstructuredObjectTyper) Recognizes(gvk unversioned.GroupVersionKind) bool { +func (d *UnstructuredObjectTyper) Recognizes(gvk schema.GroupVersionKind) bool { return d.registered[gvk] } -// IsUnversioned returns false always because *runtime.Unstructured objects +// IsUnversioned returns false always because runtime.Unstructured objects // should always have group,version,kind information set. ok will be true if the -// object's group,version,kind is registered. +// object's group,version,kind is api.Registry. func (d *UnstructuredObjectTyper) IsUnversioned(obj runtime.Object) (unversioned bool, ok bool) { gvk, err := d.ObjectKind(obj) if err != nil { diff --git a/vendor/k8s.io/client-go/kubernetes/BUILD b/vendor/k8s.io/client-go/kubernetes/BUILD new file mode 100644 index 0000000000..089edd660f --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "clientset.go", + "doc.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/client-go/discovery:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/authentication/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/authorization/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/batch/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/core/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/storage/v1:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/util/flowcontrol:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/clientset.go b/vendor/k8s.io/client-go/kubernetes/clientset.go index 432162a87a..8a05da50d1 100644 --- a/vendor/k8s.io/client-go/kubernetes/clientset.go +++ b/vendor/k8s.io/client-go/kubernetes/clientset.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,84 +17,129 @@ limitations under the License. package kubernetes import ( - "github.com/golang/glog" + glog "github.com/golang/glog" discovery "k8s.io/client-go/discovery" - v1beta1apps "k8s.io/client-go/kubernetes/typed/apps/v1beta1" - v1beta1authentication "k8s.io/client-go/kubernetes/typed/authentication/v1beta1" - v1beta1authorization "k8s.io/client-go/kubernetes/typed/authorization/v1beta1" - v1autoscaling "k8s.io/client-go/kubernetes/typed/autoscaling/v1" - v1batch "k8s.io/client-go/kubernetes/typed/batch/v1" - v2alpha1batch "k8s.io/client-go/kubernetes/typed/batch/v2alpha1" - v1alpha1certificates "k8s.io/client-go/kubernetes/typed/certificates/v1alpha1" - v1core "k8s.io/client-go/kubernetes/typed/core/v1" - v1beta1extensions "k8s.io/client-go/kubernetes/typed/extensions/v1beta1" - v1beta1policy "k8s.io/client-go/kubernetes/typed/policy/v1beta1" - v1alpha1rbac "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1" - v1beta1storage "k8s.io/client-go/kubernetes/typed/storage/v1beta1" - "k8s.io/client-go/pkg/util/flowcontrol" - _ "k8s.io/client-go/plugin/pkg/client/auth" + admissionregistrationv1alpha1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1" + appsv1beta1 "k8s.io/client-go/kubernetes/typed/apps/v1beta1" + authenticationv1 "k8s.io/client-go/kubernetes/typed/authentication/v1" + authenticationv1beta1 "k8s.io/client-go/kubernetes/typed/authentication/v1beta1" + authorizationv1 "k8s.io/client-go/kubernetes/typed/authorization/v1" + authorizationv1beta1 "k8s.io/client-go/kubernetes/typed/authorization/v1beta1" + autoscalingv1 "k8s.io/client-go/kubernetes/typed/autoscaling/v1" + autoscalingv2alpha1 "k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1" + batchv1 "k8s.io/client-go/kubernetes/typed/batch/v1" + batchv2alpha1 "k8s.io/client-go/kubernetes/typed/batch/v2alpha1" + certificatesv1beta1 "k8s.io/client-go/kubernetes/typed/certificates/v1beta1" + corev1 "k8s.io/client-go/kubernetes/typed/core/v1" + extensionsv1beta1 "k8s.io/client-go/kubernetes/typed/extensions/v1beta1" + networkingv1 "k8s.io/client-go/kubernetes/typed/networking/v1" + policyv1beta1 "k8s.io/client-go/kubernetes/typed/policy/v1beta1" + rbacv1alpha1 "k8s.io/client-go/kubernetes/typed/rbac/v1alpha1" + rbacv1beta1 "k8s.io/client-go/kubernetes/typed/rbac/v1beta1" + settingsv1alpha1 "k8s.io/client-go/kubernetes/typed/settings/v1alpha1" + storagev1 "k8s.io/client-go/kubernetes/typed/storage/v1" + storagev1beta1 "k8s.io/client-go/kubernetes/typed/storage/v1beta1" rest "k8s.io/client-go/rest" + flowcontrol "k8s.io/client-go/util/flowcontrol" ) type Interface interface { Discovery() discovery.DiscoveryInterface - CoreV1() v1core.CoreV1Interface + AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface // Deprecated: please explicitly pick a version if possible. - Core() v1core.CoreV1Interface - AppsV1beta1() v1beta1apps.AppsV1beta1Interface + Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface + CoreV1() corev1.CoreV1Interface // Deprecated: please explicitly pick a version if possible. - Apps() v1beta1apps.AppsV1beta1Interface - AuthenticationV1beta1() v1beta1authentication.AuthenticationV1beta1Interface + Core() corev1.CoreV1Interface + AppsV1beta1() appsv1beta1.AppsV1beta1Interface // Deprecated: please explicitly pick a version if possible. - Authentication() v1beta1authentication.AuthenticationV1beta1Interface - AuthorizationV1beta1() v1beta1authorization.AuthorizationV1beta1Interface + Apps() appsv1beta1.AppsV1beta1Interface + AuthenticationV1() authenticationv1.AuthenticationV1Interface // Deprecated: please explicitly pick a version if possible. - Authorization() v1beta1authorization.AuthorizationV1beta1Interface - AutoscalingV1() v1autoscaling.AutoscalingV1Interface + Authentication() authenticationv1.AuthenticationV1Interface + AuthenticationV1beta1() authenticationv1beta1.AuthenticationV1beta1Interface + AuthorizationV1() authorizationv1.AuthorizationV1Interface // Deprecated: please explicitly pick a version if possible. - Autoscaling() v1autoscaling.AutoscalingV1Interface - BatchV1() v1batch.BatchV1Interface + Authorization() authorizationv1.AuthorizationV1Interface + AuthorizationV1beta1() authorizationv1beta1.AuthorizationV1beta1Interface + AutoscalingV1() autoscalingv1.AutoscalingV1Interface // Deprecated: please explicitly pick a version if possible. - Batch() v1batch.BatchV1Interface - BatchV2alpha1() v2alpha1batch.BatchV2alpha1Interface - - CertificatesV1alpha1() v1alpha1certificates.CertificatesV1alpha1Interface + Autoscaling() autoscalingv1.AutoscalingV1Interface + AutoscalingV2alpha1() autoscalingv2alpha1.AutoscalingV2alpha1Interface + BatchV1() batchv1.BatchV1Interface + // Deprecated: please explicitly pick a version if possible. + Batch() batchv1.BatchV1Interface + BatchV2alpha1() batchv2alpha1.BatchV2alpha1Interface + CertificatesV1beta1() certificatesv1beta1.CertificatesV1beta1Interface + // Deprecated: please explicitly pick a version if possible. + Certificates() certificatesv1beta1.CertificatesV1beta1Interface + ExtensionsV1beta1() extensionsv1beta1.ExtensionsV1beta1Interface + // Deprecated: please explicitly pick a version if possible. + Extensions() extensionsv1beta1.ExtensionsV1beta1Interface + NetworkingV1() networkingv1.NetworkingV1Interface // Deprecated: please explicitly pick a version if possible. - Certificates() v1alpha1certificates.CertificatesV1alpha1Interface - ExtensionsV1beta1() v1beta1extensions.ExtensionsV1beta1Interface + Networking() networkingv1.NetworkingV1Interface + PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface // Deprecated: please explicitly pick a version if possible. - Extensions() v1beta1extensions.ExtensionsV1beta1Interface - PolicyV1beta1() v1beta1policy.PolicyV1beta1Interface + Policy() policyv1beta1.PolicyV1beta1Interface + RbacV1beta1() rbacv1beta1.RbacV1beta1Interface // Deprecated: please explicitly pick a version if possible. - Policy() v1beta1policy.PolicyV1beta1Interface - RbacV1alpha1() v1alpha1rbac.RbacV1alpha1Interface + Rbac() rbacv1beta1.RbacV1beta1Interface + RbacV1alpha1() rbacv1alpha1.RbacV1alpha1Interface + SettingsV1alpha1() settingsv1alpha1.SettingsV1alpha1Interface // Deprecated: please explicitly pick a version if possible. - Rbac() v1alpha1rbac.RbacV1alpha1Interface - StorageV1beta1() v1beta1storage.StorageV1beta1Interface + Settings() settingsv1alpha1.SettingsV1alpha1Interface + StorageV1beta1() storagev1beta1.StorageV1beta1Interface + StorageV1() storagev1.StorageV1Interface // Deprecated: please explicitly pick a version if possible. - Storage() v1beta1storage.StorageV1beta1Interface + Storage() storagev1.StorageV1Interface } // Clientset contains the clients for groups. Each group has exactly one // version included in a Clientset. type Clientset struct { *discovery.DiscoveryClient - *v1core.CoreV1Client - *v1beta1apps.AppsV1beta1Client - *v1beta1authentication.AuthenticationV1beta1Client - *v1beta1authorization.AuthorizationV1beta1Client - *v1autoscaling.AutoscalingV1Client - *v1batch.BatchV1Client - *v2alpha1batch.BatchV2alpha1Client - *v1alpha1certificates.CertificatesV1alpha1Client - *v1beta1extensions.ExtensionsV1beta1Client - *v1beta1policy.PolicyV1beta1Client - *v1alpha1rbac.RbacV1alpha1Client - *v1beta1storage.StorageV1beta1Client + *admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Client + *corev1.CoreV1Client + *appsv1beta1.AppsV1beta1Client + *authenticationv1.AuthenticationV1Client + *authenticationv1beta1.AuthenticationV1beta1Client + *authorizationv1.AuthorizationV1Client + *authorizationv1beta1.AuthorizationV1beta1Client + *autoscalingv1.AutoscalingV1Client + *autoscalingv2alpha1.AutoscalingV2alpha1Client + *batchv1.BatchV1Client + *batchv2alpha1.BatchV2alpha1Client + *certificatesv1beta1.CertificatesV1beta1Client + *extensionsv1beta1.ExtensionsV1beta1Client + *networkingv1.NetworkingV1Client + *policyv1beta1.PolicyV1beta1Client + *rbacv1beta1.RbacV1beta1Client + *rbacv1alpha1.RbacV1alpha1Client + *settingsv1alpha1.SettingsV1alpha1Client + *storagev1beta1.StorageV1beta1Client + *storagev1.StorageV1Client +} + +// AdmissionregistrationV1alpha1 retrieves the AdmissionregistrationV1alpha1Client +func (c *Clientset) AdmissionregistrationV1alpha1() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + if c == nil { + return nil + } + return c.AdmissionregistrationV1alpha1Client +} + +// Deprecated: Admissionregistration retrieves the default version of AdmissionregistrationClient. +// Please explicitly pick a version. +func (c *Clientset) Admissionregistration() admissionregistrationv1alpha1.AdmissionregistrationV1alpha1Interface { + if c == nil { + return nil + } + return c.AdmissionregistrationV1alpha1Client } // CoreV1 retrieves the CoreV1Client -func (c *Clientset) CoreV1() v1core.CoreV1Interface { +func (c *Clientset) CoreV1() corev1.CoreV1Interface { if c == nil { return nil } @@ -103,7 +148,7 @@ func (c *Clientset) CoreV1() v1core.CoreV1Interface { // Deprecated: Core retrieves the default version of CoreClient. // Please explicitly pick a version. -func (c *Clientset) Core() v1core.CoreV1Interface { +func (c *Clientset) Core() corev1.CoreV1Interface { if c == nil { return nil } @@ -111,7 +156,7 @@ func (c *Clientset) Core() v1core.CoreV1Interface { } // AppsV1beta1 retrieves the AppsV1beta1Client -func (c *Clientset) AppsV1beta1() v1beta1apps.AppsV1beta1Interface { +func (c *Clientset) AppsV1beta1() appsv1beta1.AppsV1beta1Interface { if c == nil { return nil } @@ -120,41 +165,57 @@ func (c *Clientset) AppsV1beta1() v1beta1apps.AppsV1beta1Interface { // Deprecated: Apps retrieves the default version of AppsClient. // Please explicitly pick a version. -func (c *Clientset) Apps() v1beta1apps.AppsV1beta1Interface { +func (c *Clientset) Apps() appsv1beta1.AppsV1beta1Interface { if c == nil { return nil } return c.AppsV1beta1Client } -// AuthenticationV1beta1 retrieves the AuthenticationV1beta1Client -func (c *Clientset) AuthenticationV1beta1() v1beta1authentication.AuthenticationV1beta1Interface { +// AuthenticationV1 retrieves the AuthenticationV1Client +func (c *Clientset) AuthenticationV1() authenticationv1.AuthenticationV1Interface { if c == nil { return nil } - return c.AuthenticationV1beta1Client + return c.AuthenticationV1Client } // Deprecated: Authentication retrieves the default version of AuthenticationClient. // Please explicitly pick a version. -func (c *Clientset) Authentication() v1beta1authentication.AuthenticationV1beta1Interface { +func (c *Clientset) Authentication() authenticationv1.AuthenticationV1Interface { + if c == nil { + return nil + } + return c.AuthenticationV1Client +} + +// AuthenticationV1beta1 retrieves the AuthenticationV1beta1Client +func (c *Clientset) AuthenticationV1beta1() authenticationv1beta1.AuthenticationV1beta1Interface { if c == nil { return nil } return c.AuthenticationV1beta1Client } -// AuthorizationV1beta1 retrieves the AuthorizationV1beta1Client -func (c *Clientset) AuthorizationV1beta1() v1beta1authorization.AuthorizationV1beta1Interface { +// AuthorizationV1 retrieves the AuthorizationV1Client +func (c *Clientset) AuthorizationV1() authorizationv1.AuthorizationV1Interface { if c == nil { return nil } - return c.AuthorizationV1beta1Client + return c.AuthorizationV1Client } // Deprecated: Authorization retrieves the default version of AuthorizationClient. // Please explicitly pick a version. -func (c *Clientset) Authorization() v1beta1authorization.AuthorizationV1beta1Interface { +func (c *Clientset) Authorization() authorizationv1.AuthorizationV1Interface { + if c == nil { + return nil + } + return c.AuthorizationV1Client +} + +// AuthorizationV1beta1 retrieves the AuthorizationV1beta1Client +func (c *Clientset) AuthorizationV1beta1() authorizationv1beta1.AuthorizationV1beta1Interface { if c == nil { return nil } @@ -162,7 +223,7 @@ func (c *Clientset) Authorization() v1beta1authorization.AuthorizationV1beta1Int } // AutoscalingV1 retrieves the AutoscalingV1Client -func (c *Clientset) AutoscalingV1() v1autoscaling.AutoscalingV1Interface { +func (c *Clientset) AutoscalingV1() autoscalingv1.AutoscalingV1Interface { if c == nil { return nil } @@ -171,15 +232,23 @@ func (c *Clientset) AutoscalingV1() v1autoscaling.AutoscalingV1Interface { // Deprecated: Autoscaling retrieves the default version of AutoscalingClient. // Please explicitly pick a version. -func (c *Clientset) Autoscaling() v1autoscaling.AutoscalingV1Interface { +func (c *Clientset) Autoscaling() autoscalingv1.AutoscalingV1Interface { if c == nil { return nil } return c.AutoscalingV1Client } +// AutoscalingV2alpha1 retrieves the AutoscalingV2alpha1Client +func (c *Clientset) AutoscalingV2alpha1() autoscalingv2alpha1.AutoscalingV2alpha1Interface { + if c == nil { + return nil + } + return c.AutoscalingV2alpha1Client +} + // BatchV1 retrieves the BatchV1Client -func (c *Clientset) BatchV1() v1batch.BatchV1Interface { +func (c *Clientset) BatchV1() batchv1.BatchV1Interface { if c == nil { return nil } @@ -188,7 +257,7 @@ func (c *Clientset) BatchV1() v1batch.BatchV1Interface { // Deprecated: Batch retrieves the default version of BatchClient. // Please explicitly pick a version. -func (c *Clientset) Batch() v1batch.BatchV1Interface { +func (c *Clientset) Batch() batchv1.BatchV1Interface { if c == nil { return nil } @@ -196,32 +265,32 @@ func (c *Clientset) Batch() v1batch.BatchV1Interface { } // BatchV2alpha1 retrieves the BatchV2alpha1Client -func (c *Clientset) BatchV2alpha1() v2alpha1batch.BatchV2alpha1Interface { +func (c *Clientset) BatchV2alpha1() batchv2alpha1.BatchV2alpha1Interface { if c == nil { return nil } return c.BatchV2alpha1Client } -// CertificatesV1alpha1 retrieves the CertificatesV1alpha1Client -func (c *Clientset) CertificatesV1alpha1() v1alpha1certificates.CertificatesV1alpha1Interface { +// CertificatesV1beta1 retrieves the CertificatesV1beta1Client +func (c *Clientset) CertificatesV1beta1() certificatesv1beta1.CertificatesV1beta1Interface { if c == nil { return nil } - return c.CertificatesV1alpha1Client + return c.CertificatesV1beta1Client } // Deprecated: Certificates retrieves the default version of CertificatesClient. // Please explicitly pick a version. -func (c *Clientset) Certificates() v1alpha1certificates.CertificatesV1alpha1Interface { +func (c *Clientset) Certificates() certificatesv1beta1.CertificatesV1beta1Interface { if c == nil { return nil } - return c.CertificatesV1alpha1Client + return c.CertificatesV1beta1Client } // ExtensionsV1beta1 retrieves the ExtensionsV1beta1Client -func (c *Clientset) ExtensionsV1beta1() v1beta1extensions.ExtensionsV1beta1Interface { +func (c *Clientset) ExtensionsV1beta1() extensionsv1beta1.ExtensionsV1beta1Interface { if c == nil { return nil } @@ -230,15 +299,32 @@ func (c *Clientset) ExtensionsV1beta1() v1beta1extensions.ExtensionsV1beta1Inter // Deprecated: Extensions retrieves the default version of ExtensionsClient. // Please explicitly pick a version. -func (c *Clientset) Extensions() v1beta1extensions.ExtensionsV1beta1Interface { +func (c *Clientset) Extensions() extensionsv1beta1.ExtensionsV1beta1Interface { if c == nil { return nil } return c.ExtensionsV1beta1Client } +// NetworkingV1 retrieves the NetworkingV1Client +func (c *Clientset) NetworkingV1() networkingv1.NetworkingV1Interface { + if c == nil { + return nil + } + return c.NetworkingV1Client +} + +// Deprecated: Networking retrieves the default version of NetworkingClient. +// Please explicitly pick a version. +func (c *Clientset) Networking() networkingv1.NetworkingV1Interface { + if c == nil { + return nil + } + return c.NetworkingV1Client +} + // PolicyV1beta1 retrieves the PolicyV1beta1Client -func (c *Clientset) PolicyV1beta1() v1beta1policy.PolicyV1beta1Interface { +func (c *Clientset) PolicyV1beta1() policyv1beta1.PolicyV1beta1Interface { if c == nil { return nil } @@ -247,49 +333,85 @@ func (c *Clientset) PolicyV1beta1() v1beta1policy.PolicyV1beta1Interface { // Deprecated: Policy retrieves the default version of PolicyClient. // Please explicitly pick a version. -func (c *Clientset) Policy() v1beta1policy.PolicyV1beta1Interface { +func (c *Clientset) Policy() policyv1beta1.PolicyV1beta1Interface { if c == nil { return nil } return c.PolicyV1beta1Client } -// RbacV1alpha1 retrieves the RbacV1alpha1Client -func (c *Clientset) RbacV1alpha1() v1alpha1rbac.RbacV1alpha1Interface { +// RbacV1beta1 retrieves the RbacV1beta1Client +func (c *Clientset) RbacV1beta1() rbacv1beta1.RbacV1beta1Interface { if c == nil { return nil } - return c.RbacV1alpha1Client + return c.RbacV1beta1Client } // Deprecated: Rbac retrieves the default version of RbacClient. // Please explicitly pick a version. -func (c *Clientset) Rbac() v1alpha1rbac.RbacV1alpha1Interface { +func (c *Clientset) Rbac() rbacv1beta1.RbacV1beta1Interface { + if c == nil { + return nil + } + return c.RbacV1beta1Client +} + +// RbacV1alpha1 retrieves the RbacV1alpha1Client +func (c *Clientset) RbacV1alpha1() rbacv1alpha1.RbacV1alpha1Interface { if c == nil { return nil } return c.RbacV1alpha1Client } +// SettingsV1alpha1 retrieves the SettingsV1alpha1Client +func (c *Clientset) SettingsV1alpha1() settingsv1alpha1.SettingsV1alpha1Interface { + if c == nil { + return nil + } + return c.SettingsV1alpha1Client +} + +// Deprecated: Settings retrieves the default version of SettingsClient. +// Please explicitly pick a version. +func (c *Clientset) Settings() settingsv1alpha1.SettingsV1alpha1Interface { + if c == nil { + return nil + } + return c.SettingsV1alpha1Client +} + // StorageV1beta1 retrieves the StorageV1beta1Client -func (c *Clientset) StorageV1beta1() v1beta1storage.StorageV1beta1Interface { +func (c *Clientset) StorageV1beta1() storagev1beta1.StorageV1beta1Interface { if c == nil { return nil } return c.StorageV1beta1Client } +// StorageV1 retrieves the StorageV1Client +func (c *Clientset) StorageV1() storagev1.StorageV1Interface { + if c == nil { + return nil + } + return c.StorageV1Client +} + // Deprecated: Storage retrieves the default version of StorageClient. // Please explicitly pick a version. -func (c *Clientset) Storage() v1beta1storage.StorageV1beta1Interface { +func (c *Clientset) Storage() storagev1.StorageV1Interface { if c == nil { return nil } - return c.StorageV1beta1Client + return c.StorageV1Client } // Discovery retrieves the DiscoveryClient func (c *Clientset) Discovery() discovery.DiscoveryInterface { + if c == nil { + return nil + } return c.DiscoveryClient } @@ -299,102 +421,150 @@ func NewForConfig(c *rest.Config) (*Clientset, error) { if configShallowCopy.RateLimiter == nil && configShallowCopy.QPS > 0 { configShallowCopy.RateLimiter = flowcontrol.NewTokenBucketRateLimiter(configShallowCopy.QPS, configShallowCopy.Burst) } - var clientset Clientset + var cs Clientset var err error - clientset.CoreV1Client, err = v1core.NewForConfig(&configShallowCopy) + cs.AdmissionregistrationV1alpha1Client, err = admissionregistrationv1alpha1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.CoreV1Client, err = corev1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AppsV1beta1Client, err = appsv1beta1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AuthenticationV1Client, err = authenticationv1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AuthenticationV1beta1Client, err = authenticationv1beta1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AuthorizationV1Client, err = authorizationv1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AuthorizationV1beta1Client, err = authorizationv1beta1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AutoscalingV1Client, err = autoscalingv1.NewForConfig(&configShallowCopy) + if err != nil { + return nil, err + } + cs.AutoscalingV2alpha1Client, err = autoscalingv2alpha1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.AppsV1beta1Client, err = v1beta1apps.NewForConfig(&configShallowCopy) + cs.BatchV1Client, err = batchv1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.AuthenticationV1beta1Client, err = v1beta1authentication.NewForConfig(&configShallowCopy) + cs.BatchV2alpha1Client, err = batchv2alpha1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.AuthorizationV1beta1Client, err = v1beta1authorization.NewForConfig(&configShallowCopy) + cs.CertificatesV1beta1Client, err = certificatesv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.AutoscalingV1Client, err = v1autoscaling.NewForConfig(&configShallowCopy) + cs.ExtensionsV1beta1Client, err = extensionsv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.BatchV1Client, err = v1batch.NewForConfig(&configShallowCopy) + cs.NetworkingV1Client, err = networkingv1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.BatchV2alpha1Client, err = v2alpha1batch.NewForConfig(&configShallowCopy) + cs.PolicyV1beta1Client, err = policyv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.CertificatesV1alpha1Client, err = v1alpha1certificates.NewForConfig(&configShallowCopy) + cs.RbacV1beta1Client, err = rbacv1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.ExtensionsV1beta1Client, err = v1beta1extensions.NewForConfig(&configShallowCopy) + cs.RbacV1alpha1Client, err = rbacv1alpha1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.PolicyV1beta1Client, err = v1beta1policy.NewForConfig(&configShallowCopy) + cs.SettingsV1alpha1Client, err = settingsv1alpha1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.RbacV1alpha1Client, err = v1alpha1rbac.NewForConfig(&configShallowCopy) + cs.StorageV1beta1Client, err = storagev1beta1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.StorageV1beta1Client, err = v1beta1storage.NewForConfig(&configShallowCopy) + cs.StorageV1Client, err = storagev1.NewForConfig(&configShallowCopy) if err != nil { return nil, err } - clientset.DiscoveryClient, err = discovery.NewDiscoveryClientForConfig(&configShallowCopy) + cs.DiscoveryClient, err = discovery.NewDiscoveryClientForConfig(&configShallowCopy) if err != nil { glog.Errorf("failed to create the DiscoveryClient: %v", err) return nil, err } - return &clientset, nil + return &cs, nil } // NewForConfigOrDie creates a new Clientset for the given config and // panics if there is an error in the config. func NewForConfigOrDie(c *rest.Config) *Clientset { - var clientset Clientset - clientset.CoreV1Client = v1core.NewForConfigOrDie(c) - clientset.AppsV1beta1Client = v1beta1apps.NewForConfigOrDie(c) - clientset.AuthenticationV1beta1Client = v1beta1authentication.NewForConfigOrDie(c) - clientset.AuthorizationV1beta1Client = v1beta1authorization.NewForConfigOrDie(c) - clientset.AutoscalingV1Client = v1autoscaling.NewForConfigOrDie(c) - clientset.BatchV1Client = v1batch.NewForConfigOrDie(c) - clientset.BatchV2alpha1Client = v2alpha1batch.NewForConfigOrDie(c) - clientset.CertificatesV1alpha1Client = v1alpha1certificates.NewForConfigOrDie(c) - clientset.ExtensionsV1beta1Client = v1beta1extensions.NewForConfigOrDie(c) - clientset.PolicyV1beta1Client = v1beta1policy.NewForConfigOrDie(c) - clientset.RbacV1alpha1Client = v1alpha1rbac.NewForConfigOrDie(c) - clientset.StorageV1beta1Client = v1beta1storage.NewForConfigOrDie(c) - - clientset.DiscoveryClient = discovery.NewDiscoveryClientForConfigOrDie(c) - return &clientset + var cs Clientset + cs.AdmissionregistrationV1alpha1Client = admissionregistrationv1alpha1.NewForConfigOrDie(c) + cs.CoreV1Client = corev1.NewForConfigOrDie(c) + cs.AppsV1beta1Client = appsv1beta1.NewForConfigOrDie(c) + cs.AuthenticationV1Client = authenticationv1.NewForConfigOrDie(c) + cs.AuthenticationV1beta1Client = authenticationv1beta1.NewForConfigOrDie(c) + cs.AuthorizationV1Client = authorizationv1.NewForConfigOrDie(c) + cs.AuthorizationV1beta1Client = authorizationv1beta1.NewForConfigOrDie(c) + cs.AutoscalingV1Client = autoscalingv1.NewForConfigOrDie(c) + cs.AutoscalingV2alpha1Client = autoscalingv2alpha1.NewForConfigOrDie(c) + cs.BatchV1Client = batchv1.NewForConfigOrDie(c) + cs.BatchV2alpha1Client = batchv2alpha1.NewForConfigOrDie(c) + cs.CertificatesV1beta1Client = certificatesv1beta1.NewForConfigOrDie(c) + cs.ExtensionsV1beta1Client = extensionsv1beta1.NewForConfigOrDie(c) + cs.NetworkingV1Client = networkingv1.NewForConfigOrDie(c) + cs.PolicyV1beta1Client = policyv1beta1.NewForConfigOrDie(c) + cs.RbacV1beta1Client = rbacv1beta1.NewForConfigOrDie(c) + cs.RbacV1alpha1Client = rbacv1alpha1.NewForConfigOrDie(c) + cs.SettingsV1alpha1Client = settingsv1alpha1.NewForConfigOrDie(c) + cs.StorageV1beta1Client = storagev1beta1.NewForConfigOrDie(c) + cs.StorageV1Client = storagev1.NewForConfigOrDie(c) + + cs.DiscoveryClient = discovery.NewDiscoveryClientForConfigOrDie(c) + return &cs } // New creates a new Clientset for the given RESTClient. func New(c rest.Interface) *Clientset { - var clientset Clientset - clientset.CoreV1Client = v1core.New(c) - clientset.AppsV1beta1Client = v1beta1apps.New(c) - clientset.AuthenticationV1beta1Client = v1beta1authentication.New(c) - clientset.AuthorizationV1beta1Client = v1beta1authorization.New(c) - clientset.AutoscalingV1Client = v1autoscaling.New(c) - clientset.BatchV1Client = v1batch.New(c) - clientset.BatchV2alpha1Client = v2alpha1batch.New(c) - clientset.CertificatesV1alpha1Client = v1alpha1certificates.New(c) - clientset.ExtensionsV1beta1Client = v1beta1extensions.New(c) - clientset.PolicyV1beta1Client = v1beta1policy.New(c) - clientset.RbacV1alpha1Client = v1alpha1rbac.New(c) - clientset.StorageV1beta1Client = v1beta1storage.New(c) - - clientset.DiscoveryClient = discovery.NewDiscoveryClient(c) - return &clientset + var cs Clientset + cs.AdmissionregistrationV1alpha1Client = admissionregistrationv1alpha1.New(c) + cs.CoreV1Client = corev1.New(c) + cs.AppsV1beta1Client = appsv1beta1.New(c) + cs.AuthenticationV1Client = authenticationv1.New(c) + cs.AuthenticationV1beta1Client = authenticationv1beta1.New(c) + cs.AuthorizationV1Client = authorizationv1.New(c) + cs.AuthorizationV1beta1Client = authorizationv1beta1.New(c) + cs.AutoscalingV1Client = autoscalingv1.New(c) + cs.AutoscalingV2alpha1Client = autoscalingv2alpha1.New(c) + cs.BatchV1Client = batchv1.New(c) + cs.BatchV2alpha1Client = batchv2alpha1.New(c) + cs.CertificatesV1beta1Client = certificatesv1beta1.New(c) + cs.ExtensionsV1beta1Client = extensionsv1beta1.New(c) + cs.NetworkingV1Client = networkingv1.New(c) + cs.PolicyV1beta1Client = policyv1beta1.New(c) + cs.RbacV1beta1Client = rbacv1beta1.New(c) + cs.RbacV1alpha1Client = rbacv1alpha1.New(c) + cs.SettingsV1alpha1Client = settingsv1alpha1.New(c) + cs.StorageV1beta1Client = storagev1beta1.New(c) + cs.StorageV1Client = storagev1.New(c) + + cs.DiscoveryClient = discovery.NewDiscoveryClient(c) + return &cs } diff --git a/vendor/k8s.io/client-go/kubernetes/doc.go b/vendor/k8s.io/client-go/kubernetes/doc.go index 2f2e8e111e..2af84c6699 100644 --- a/vendor/k8s.io/client-go/kubernetes/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated clientset. package kubernetes diff --git a/vendor/k8s.io/client-go/kubernetes/import_known_versions.go b/vendor/k8s.io/client-go/kubernetes/import_known_versions.go deleted file mode 100644 index 57fb7f9428..0000000000 --- a/vendor/k8s.io/client-go/kubernetes/import_known_versions.go +++ /dev/null @@ -1,41 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package kubernetes - -// These imports are the API groups the client will support. -import ( - "fmt" - - _ "k8s.io/client-go/pkg/api/install" - "k8s.io/client-go/pkg/apimachinery/registered" - _ "k8s.io/client-go/pkg/apis/apps/install" - _ "k8s.io/client-go/pkg/apis/authentication/install" - _ "k8s.io/client-go/pkg/apis/authorization/install" - _ "k8s.io/client-go/pkg/apis/autoscaling/install" - _ "k8s.io/client-go/pkg/apis/batch/install" - _ "k8s.io/client-go/pkg/apis/certificates/install" - _ "k8s.io/client-go/pkg/apis/extensions/install" - _ "k8s.io/client-go/pkg/apis/policy/install" - _ "k8s.io/client-go/pkg/apis/rbac/install" - _ "k8s.io/client-go/pkg/apis/storage/install" -) - -func init() { - if missingVersions := registered.ValidateEnvRequestedVersions(); len(missingVersions) != 0 { - panic(fmt.Sprintf("KUBE_API_VERSIONS contains versions that are not installed: %q.", missingVersions)) - } -} diff --git a/vendor/k8s.io/client-go/kubernetes/scheme/BUILD b/vendor/k8s.io/client-go/kubernetes/scheme/BUILD new file mode 100644 index 0000000000..93447ef075 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/scheme/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authentication/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authorization/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/autoscaling/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/policy/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/storage/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/storage/v1beta1:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/scheme/doc.go b/vendor/k8s.io/client-go/kubernetes/scheme/doc.go new file mode 100644 index 0000000000..5d8ec824f0 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/scheme/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package contains the scheme of the automatically generated clientset. +package scheme diff --git a/vendor/k8s.io/client-go/kubernetes/scheme/register.go b/vendor/k8s.io/client-go/kubernetes/scheme/register.go new file mode 100644 index 0000000000..c4af63a465 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/scheme/register.go @@ -0,0 +1,91 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package scheme + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + runtime "k8s.io/apimachinery/pkg/runtime" + schema "k8s.io/apimachinery/pkg/runtime/schema" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + corev1 "k8s.io/client-go/pkg/api/v1" + admissionregistrationv1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + appsv1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + authenticationv1 "k8s.io/client-go/pkg/apis/authentication/v1" + authenticationv1beta1 "k8s.io/client-go/pkg/apis/authentication/v1beta1" + authorizationv1 "k8s.io/client-go/pkg/apis/authorization/v1" + authorizationv1beta1 "k8s.io/client-go/pkg/apis/authorization/v1beta1" + autoscalingv1 "k8s.io/client-go/pkg/apis/autoscaling/v1" + autoscalingv2alpha1 "k8s.io/client-go/pkg/apis/autoscaling/v2alpha1" + batchv1 "k8s.io/client-go/pkg/apis/batch/v1" + batchv2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" + certificatesv1beta1 "k8s.io/client-go/pkg/apis/certificates/v1beta1" + extensionsv1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" + networkingv1 "k8s.io/client-go/pkg/apis/networking/v1" + policyv1beta1 "k8s.io/client-go/pkg/apis/policy/v1beta1" + rbacv1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" + rbacv1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" + settingsv1alpha1 "k8s.io/client-go/pkg/apis/settings/v1alpha1" + storagev1 "k8s.io/client-go/pkg/apis/storage/v1" + storagev1beta1 "k8s.io/client-go/pkg/apis/storage/v1beta1" +) + +var Scheme = runtime.NewScheme() +var Codecs = serializer.NewCodecFactory(Scheme) +var ParameterCodec = runtime.NewParameterCodec(Scheme) + +func init() { + v1.AddToGroupVersion(Scheme, schema.GroupVersion{Version: "v1"}) + AddToScheme(Scheme) +} + +// AddToScheme adds all types of this clientset into the given scheme. This allows composition +// of clientsets, like in: +// +// import ( +// "k8s.io/client-go/kubernetes" +// clientsetscheme "k8s.io/client-go/kuberentes/scheme" +// aggregatorclientsetscheme "k8s.io/kube-aggregator/pkg/client/clientset_generated/clientset/scheme" +// ) +// +// kclientset, _ := kubernetes.NewForConfig(c) +// aggregatorclientsetscheme.AddToScheme(clientsetscheme.Scheme) +// +// After this, RawExtensions in Kubernetes types will serialize kube-aggregator types +// correctly. +func AddToScheme(scheme *runtime.Scheme) { + admissionregistrationv1alpha1.AddToScheme(scheme) + corev1.AddToScheme(scheme) + appsv1beta1.AddToScheme(scheme) + authenticationv1.AddToScheme(scheme) + authenticationv1beta1.AddToScheme(scheme) + authorizationv1.AddToScheme(scheme) + authorizationv1beta1.AddToScheme(scheme) + autoscalingv1.AddToScheme(scheme) + autoscalingv2alpha1.AddToScheme(scheme) + batchv1.AddToScheme(scheme) + batchv2alpha1.AddToScheme(scheme) + certificatesv1beta1.AddToScheme(scheme) + extensionsv1beta1.AddToScheme(scheme) + networkingv1.AddToScheme(scheme) + policyv1beta1.AddToScheme(scheme) + rbacv1beta1.AddToScheme(scheme) + rbacv1alpha1.AddToScheme(scheme) + settingsv1alpha1.AddToScheme(scheme) + storagev1beta1.AddToScheme(scheme) + storagev1.AddToScheme(scheme) + +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000..e51dda3dfb --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "admissionregistration_client.go", + "doc.go", + "externaladmissionhookconfiguration.go", + "generated_expansion.go", + "initializerconfiguration.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go new file mode 100644 index 0000000000..1ac48c8f32 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/admissionregistration_client.go @@ -0,0 +1,93 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" +) + +type AdmissionregistrationV1alpha1Interface interface { + RESTClient() rest.Interface + ExternalAdmissionHookConfigurationsGetter + InitializerConfigurationsGetter +} + +// AdmissionregistrationV1alpha1Client is used to interact with features provided by the admissionregistration.k8s.io group. +type AdmissionregistrationV1alpha1Client struct { + restClient rest.Interface +} + +func (c *AdmissionregistrationV1alpha1Client) ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInterface { + return newExternalAdmissionHookConfigurations(c) +} + +func (c *AdmissionregistrationV1alpha1Client) InitializerConfigurations() InitializerConfigurationInterface { + return newInitializerConfigurations(c) +} + +// NewForConfig creates a new AdmissionregistrationV1alpha1Client for the given config. +func NewForConfig(c *rest.Config) (*AdmissionregistrationV1alpha1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AdmissionregistrationV1alpha1Client{client}, nil +} + +// NewForConfigOrDie creates a new AdmissionregistrationV1alpha1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AdmissionregistrationV1alpha1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AdmissionregistrationV1alpha1Client for the given RESTClient. +func New(c rest.Interface) *AdmissionregistrationV1alpha1Client { + return &AdmissionregistrationV1alpha1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1alpha1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AdmissionregistrationV1alpha1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go new file mode 100644 index 0000000000..ba8d10d3b6 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1alpha1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go new file mode 100644 index 0000000000..08d68dd0d5 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/externaladmissionhookconfiguration.go @@ -0,0 +1,145 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" +) + +// ExternalAdmissionHookConfigurationsGetter has a method to return a ExternalAdmissionHookConfigurationInterface. +// A group's client should implement this interface. +type ExternalAdmissionHookConfigurationsGetter interface { + ExternalAdmissionHookConfigurations() ExternalAdmissionHookConfigurationInterface +} + +// ExternalAdmissionHookConfigurationInterface has methods to work with ExternalAdmissionHookConfiguration resources. +type ExternalAdmissionHookConfigurationInterface interface { + Create(*v1alpha1.ExternalAdmissionHookConfiguration) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + Update(*v1alpha1.ExternalAdmissionHookConfiguration) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.ExternalAdmissionHookConfiguration, error) + List(opts v1.ListOptions) (*v1alpha1.ExternalAdmissionHookConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) + ExternalAdmissionHookConfigurationExpansion +} + +// externalAdmissionHookConfigurations implements ExternalAdmissionHookConfigurationInterface +type externalAdmissionHookConfigurations struct { + client rest.Interface +} + +// newExternalAdmissionHookConfigurations returns a ExternalAdmissionHookConfigurations +func newExternalAdmissionHookConfigurations(c *AdmissionregistrationV1alpha1Client) *externalAdmissionHookConfigurations { + return &externalAdmissionHookConfigurations{ + client: c.RESTClient(), + } +} + +// Create takes the representation of a externalAdmissionHookConfiguration and creates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Create(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Post(). + Resource("externaladmissionhookconfigurations"). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a externalAdmissionHookConfiguration and updates it. Returns the server's representation of the externalAdmissionHookConfiguration, and an error, if there is any. +func (c *externalAdmissionHookConfigurations) Update(externalAdmissionHookConfiguration *v1alpha1.ExternalAdmissionHookConfiguration) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Put(). + Resource("externaladmissionhookconfigurations"). + Name(externalAdmissionHookConfiguration.Name). + Body(externalAdmissionHookConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the externalAdmissionHookConfiguration and deletes it. Returns an error if one occurs. +func (c *externalAdmissionHookConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Resource("externaladmissionhookconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *externalAdmissionHookConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the externalAdmissionHookConfiguration, and returns the corresponding externalAdmissionHookConfiguration object, and an error if there is any. +func (c *externalAdmissionHookConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Get(). + Resource("externaladmissionhookconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ExternalAdmissionHookConfigurations that match those selectors. +func (c *externalAdmissionHookConfigurations) List(opts v1.ListOptions) (result *v1alpha1.ExternalAdmissionHookConfigurationList, err error) { + result = &v1alpha1.ExternalAdmissionHookConfigurationList{} + err = c.client.Get(). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested externalAdmissionHookConfigurations. +func (c *externalAdmissionHookConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Resource("externaladmissionhookconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched externalAdmissionHookConfiguration. +func (c *externalAdmissionHookConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ExternalAdmissionHookConfiguration, err error) { + result = &v1alpha1.ExternalAdmissionHookConfiguration{} + err = c.client.Patch(pt). + Resource("externaladmissionhookconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go new file mode 100644 index 0000000000..eef439ab47 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/generated_expansion.go @@ -0,0 +1,21 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +type ExternalAdmissionHookConfigurationExpansion interface{} + +type InitializerConfigurationExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go new file mode 100644 index 0000000000..25fee85022 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/admissionregistration/v1alpha1/initializerconfiguration.go @@ -0,0 +1,145 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1" + rest "k8s.io/client-go/rest" +) + +// InitializerConfigurationsGetter has a method to return a InitializerConfigurationInterface. +// A group's client should implement this interface. +type InitializerConfigurationsGetter interface { + InitializerConfigurations() InitializerConfigurationInterface +} + +// InitializerConfigurationInterface has methods to work with InitializerConfiguration resources. +type InitializerConfigurationInterface interface { + Create(*v1alpha1.InitializerConfiguration) (*v1alpha1.InitializerConfiguration, error) + Update(*v1alpha1.InitializerConfiguration) (*v1alpha1.InitializerConfiguration, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.InitializerConfiguration, error) + List(opts v1.ListOptions) (*v1alpha1.InitializerConfigurationList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) + InitializerConfigurationExpansion +} + +// initializerConfigurations implements InitializerConfigurationInterface +type initializerConfigurations struct { + client rest.Interface +} + +// newInitializerConfigurations returns a InitializerConfigurations +func newInitializerConfigurations(c *AdmissionregistrationV1alpha1Client) *initializerConfigurations { + return &initializerConfigurations{ + client: c.RESTClient(), + } +} + +// Create takes the representation of a initializerConfiguration and creates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Create(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Post(). + Resource("initializerconfigurations"). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Update takes the representation of a initializerConfiguration and updates it. Returns the server's representation of the initializerConfiguration, and an error, if there is any. +func (c *initializerConfigurations) Update(initializerConfiguration *v1alpha1.InitializerConfiguration) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Put(). + Resource("initializerconfigurations"). + Name(initializerConfiguration.Name). + Body(initializerConfiguration). + Do(). + Into(result) + return +} + +// Delete takes name of the initializerConfiguration and deletes it. Returns an error if one occurs. +func (c *initializerConfigurations) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Resource("initializerconfigurations"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *initializerConfigurations) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Resource("initializerconfigurations"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the initializerConfiguration, and returns the corresponding initializerConfiguration object, and an error if there is any. +func (c *initializerConfigurations) Get(name string, options v1.GetOptions) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Get(). + Resource("initializerconfigurations"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of InitializerConfigurations that match those selectors. +func (c *initializerConfigurations) List(opts v1.ListOptions) (result *v1alpha1.InitializerConfigurationList, err error) { + result = &v1alpha1.InitializerConfigurationList{} + err = c.client.Get(). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested initializerConfigurations. +func (c *initializerConfigurations) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Resource("initializerconfigurations"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched initializerConfiguration. +func (c *initializerConfigurations) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.InitializerConfiguration, err error) { + result = &v1alpha1.InitializerConfiguration{} + err = c.client.Patch(pt). + Resource("initializerconfigurations"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD new file mode 100644 index 0000000000..ba6ffd4217 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "apps_client.go", + "controllerrevision.go", + "deployment.go", + "doc.go", + "generated_expansion.go", + "scale.go", + "statefulset.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go index 0155927e43..c18da39f6d 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/apps_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,24 +17,37 @@ limitations under the License. package v1beta1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" rest "k8s.io/client-go/rest" ) type AppsV1beta1Interface interface { RESTClient() rest.Interface + ControllerRevisionsGetter + DeploymentsGetter + ScalesGetter StatefulSetsGetter } -// AppsV1beta1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// AppsV1beta1Client is used to interact with features provided by the apps group. type AppsV1beta1Client struct { restClient rest.Interface } +func (c *AppsV1beta1Client) ControllerRevisions(namespace string) ControllerRevisionInterface { + return newControllerRevisions(c, namespace) +} + +func (c *AppsV1beta1Client) Deployments(namespace string) DeploymentInterface { + return newDeployments(c, namespace) +} + +func (c *AppsV1beta1Client) Scales(namespace string) ScaleInterface { + return newScales(c, namespace) +} + func (c *AppsV1beta1Client) StatefulSets(namespace string) StatefulSetInterface { return newStatefulSets(c, namespace) } @@ -68,22 +81,14 @@ func New(c rest.Interface) *AppsV1beta1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("apps/v1beta1") - if err != nil { - return err - } - // if apps/v1beta1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("apps/v1beta1 is not enabled") - } + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go new file mode 100644 index 0000000000..de24bbb582 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/controllerrevision.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + rest "k8s.io/client-go/rest" +) + +// ControllerRevisionsGetter has a method to return a ControllerRevisionInterface. +// A group's client should implement this interface. +type ControllerRevisionsGetter interface { + ControllerRevisions(namespace string) ControllerRevisionInterface +} + +// ControllerRevisionInterface has methods to work with ControllerRevision resources. +type ControllerRevisionInterface interface { + Create(*v1beta1.ControllerRevision) (*v1beta1.ControllerRevision, error) + Update(*v1beta1.ControllerRevision) (*v1beta1.ControllerRevision, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.ControllerRevision, error) + List(opts v1.ListOptions) (*v1beta1.ControllerRevisionList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) + ControllerRevisionExpansion +} + +// controllerRevisions implements ControllerRevisionInterface +type controllerRevisions struct { + client rest.Interface + ns string +} + +// newControllerRevisions returns a ControllerRevisions +func newControllerRevisions(c *AppsV1beta1Client, namespace string) *controllerRevisions { + return &controllerRevisions{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a controllerRevision and creates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Create(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Post(). + Namespace(c.ns). + Resource("controllerrevisions"). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Update takes the representation of a controllerRevision and updates it. Returns the server's representation of the controllerRevision, and an error, if there is any. +func (c *controllerRevisions) Update(controllerRevision *v1beta1.ControllerRevision) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Put(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(controllerRevision.Name). + Body(controllerRevision). + Do(). + Into(result) + return +} + +// Delete takes name of the controllerRevision and deletes it. Returns an error if one occurs. +func (c *controllerRevisions) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *controllerRevisions) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the controllerRevision, and returns the corresponding controllerRevision object, and an error if there is any. +func (c *controllerRevisions) Get(name string, options v1.GetOptions) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ControllerRevisions that match those selectors. +func (c *controllerRevisions) List(opts v1.ListOptions) (result *v1beta1.ControllerRevisionList, err error) { + result = &v1beta1.ControllerRevisionList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested controllerRevisions. +func (c *controllerRevisions) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("controllerrevisions"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched controllerRevision. +func (c *controllerRevisions) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ControllerRevision, err error) { + result = &v1beta1.ControllerRevision{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("controllerrevisions"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/deployment.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/deployment.go new file mode 100644 index 0000000000..b30965ee78 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/deployment.go @@ -0,0 +1,172 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" + rest "k8s.io/client-go/rest" +) + +// DeploymentsGetter has a method to return a DeploymentInterface. +// A group's client should implement this interface. +type DeploymentsGetter interface { + Deployments(namespace string) DeploymentInterface +} + +// DeploymentInterface has methods to work with Deployment resources. +type DeploymentInterface interface { + Create(*v1beta1.Deployment) (*v1beta1.Deployment, error) + Update(*v1beta1.Deployment) (*v1beta1.Deployment, error) + UpdateStatus(*v1beta1.Deployment) (*v1beta1.Deployment, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.Deployment, error) + List(opts v1.ListOptions) (*v1beta1.DeploymentList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) + DeploymentExpansion +} + +// deployments implements DeploymentInterface +type deployments struct { + client rest.Interface + ns string +} + +// newDeployments returns a Deployments +func newDeployments(c *AppsV1beta1Client, namespace string) *deployments { + return &deployments{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a deployment and creates it. Returns the server's representation of the deployment, and an error, if there is any. +func (c *deployments) Create(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) { + result = &v1beta1.Deployment{} + err = c.client.Post(). + Namespace(c.ns). + Resource("deployments"). + Body(deployment). + Do(). + Into(result) + return +} + +// Update takes the representation of a deployment and updates it. Returns the server's representation of the deployment, and an error, if there is any. +func (c *deployments) Update(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) { + result = &v1beta1.Deployment{} + err = c.client.Put(). + Namespace(c.ns). + Resource("deployments"). + Name(deployment.Name). + Body(deployment). + Do(). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + +func (c *deployments) UpdateStatus(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) { + result = &v1beta1.Deployment{} + err = c.client.Put(). + Namespace(c.ns). + Resource("deployments"). + Name(deployment.Name). + SubResource("status"). + Body(deployment). + Do(). + Into(result) + return +} + +// Delete takes name of the deployment and deletes it. Returns an error if one occurs. +func (c *deployments) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("deployments"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *deployments) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("deployments"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the deployment, and returns the corresponding deployment object, and an error if there is any. +func (c *deployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) { + result = &v1beta1.Deployment{} + err = c.client.Get(). + Namespace(c.ns). + Resource("deployments"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of Deployments that match those selectors. +func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err error) { + result = &v1beta1.DeploymentList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("deployments"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested deployments. +func (c *deployments) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("deployments"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched deployment. +func (c *deployments) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) { + result = &v1beta1.Deployment{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("deployments"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/doc.go index c15d0baccf..11b5238972 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go index b09a7bae5e..a091b902ad 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -16,4 +16,10 @@ limitations under the License. package v1beta1 +type ControllerRevisionExpansion interface{} + +type DeploymentExpansion interface{} + +type ScaleExpansion interface{} + type StatefulSetExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/scale.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/scale.go new file mode 100644 index 0000000000..d3bf9e1032 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/scale.go @@ -0,0 +1,46 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + rest "k8s.io/client-go/rest" +) + +// ScalesGetter has a method to return a ScaleInterface. +// A group's client should implement this interface. +type ScalesGetter interface { + Scales(namespace string) ScaleInterface +} + +// ScaleInterface has methods to work with Scale resources. +type ScaleInterface interface { + ScaleExpansion +} + +// scales implements ScaleInterface +type scales struct { + client rest.Interface + ns string +} + +// newScales returns a Scales +func newScales(c *AppsV1beta1Client, namespace string) *scales { + return &scales{ + client: c.RESTClient(), + ns: namespace, + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/statefulset.go b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/statefulset.go index 88920c3010..8b5a7822fc 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/statefulset.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/apps/v1beta1/statefulset.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type StatefulSetInterface interface { UpdateStatus(*v1beta1.StatefulSet) (*v1beta1.StatefulSet, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.StatefulSet, error) + Get(name string, options v1.GetOptions) (*v1beta1.StatefulSet, error) List(opts v1.ListOptions) (*v1beta1.StatefulSetList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.StatefulSet, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StatefulSet, err error) StatefulSetExpansion } @@ -83,6 +84,9 @@ func (c *statefulSets) Update(statefulSet *v1beta1.StatefulSet) (result *v1beta1 return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *statefulSets) UpdateStatus(statefulSet *v1beta1.StatefulSet) (result *v1beta1.StatefulSet, err error) { result = &v1beta1.StatefulSet{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *statefulSets) DeleteCollection(options *v1.DeleteOptions, listOptions v return c.client.Delete(). Namespace(c.ns). Resource("statefulsets"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the statefulSet, and returns the corresponding statefulSet object, and an error if there is any. -func (c *statefulSets) Get(name string) (result *v1beta1.StatefulSet, err error) { +func (c *statefulSets) Get(name string, options v1.GetOptions) (result *v1beta1.StatefulSet, err error) { result = &v1beta1.StatefulSet{} err = c.client.Get(). Namespace(c.ns). Resource("statefulsets"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *statefulSets) List(opts v1.ListOptions) (result *v1beta1.StatefulSetLis err = c.client.Get(). Namespace(c.ns). Resource("statefulsets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *statefulSets) List(opts v1.ListOptions) (result *v1beta1.StatefulSetLis // Watch returns a watch.Interface that watches the requested statefulSets. func (c *statefulSets) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("statefulsets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched statefulSet. -func (c *statefulSets) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.StatefulSet, err error) { +func (c *statefulSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StatefulSet, err error) { result = &v1beta1.StatefulSet{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/BUILD new file mode 100644 index 0000000000..ece030fc3e --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "authentication_client.go", + "doc.go", + "generated_expansion.go", + "tokenreview.go", + "tokenreview_expansion.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authentication/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/authentication_client.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/authentication_client.go new file mode 100644 index 0000000000..bd53fc2498 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/authentication_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/authentication/v1" + rest "k8s.io/client-go/rest" +) + +type AuthenticationV1Interface interface { + RESTClient() rest.Interface + TokenReviewsGetter +} + +// AuthenticationV1Client is used to interact with features provided by the authentication.k8s.io group. +type AuthenticationV1Client struct { + restClient rest.Interface +} + +func (c *AuthenticationV1Client) TokenReviews() TokenReviewInterface { + return newTokenReviews(c) +} + +// NewForConfig creates a new AuthenticationV1Client for the given config. +func NewForConfig(c *rest.Config) (*AuthenticationV1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AuthenticationV1Client{client}, nil +} + +// NewForConfigOrDie creates a new AuthenticationV1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AuthenticationV1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AuthenticationV1Client for the given RESTClient. +func New(c rest.Interface) *AuthenticationV1Client { + return &AuthenticationV1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AuthenticationV1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/doc.go new file mode 100644 index 0000000000..54673bfa73 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/generated_expansion.go new file mode 100644 index 0000000000..42e76d5e43 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/generated_expansion.go @@ -0,0 +1,17 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview.go new file mode 100644 index 0000000000..9cfef4e6ac --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + rest "k8s.io/client-go/rest" +) + +// TokenReviewsGetter has a method to return a TokenReviewInterface. +// A group's client should implement this interface. +type TokenReviewsGetter interface { + TokenReviews() TokenReviewInterface +} + +// TokenReviewInterface has methods to work with TokenReview resources. +type TokenReviewInterface interface { + TokenReviewExpansion +} + +// tokenReviews implements TokenReviewInterface +type tokenReviews struct { + client rest.Interface +} + +// newTokenReviews returns a TokenReviews +func newTokenReviews(c *AuthenticationV1Client) *tokenReviews { + return &tokenReviews{ + client: c.RESTClient(), + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview_expansion.go new file mode 100644 index 0000000000..fb41782fe5 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1/tokenreview_expansion.go @@ -0,0 +1,35 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + authenticationapi "k8s.io/client-go/pkg/apis/authentication/v1" +) + +type TokenReviewExpansion interface { + Create(tokenReview *authenticationapi.TokenReview) (result *authenticationapi.TokenReview, err error) +} + +func (c *tokenReviews) Create(tokenReview *authenticationapi.TokenReview) (result *authenticationapi.TokenReview, err error) { + result = &authenticationapi.TokenReview{} + err = c.client.Post(). + Resource("tokenreviews"). + Body(tokenReview). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/BUILD new file mode 100644 index 0000000000..1fde7ba8e8 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "authentication_client.go", + "doc.go", + "generated_expansion.go", + "tokenreview.go", + "tokenreview_expansion.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/authentication_client.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/authentication_client.go index 7f976b0624..419dc2cb67 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/authentication_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/authentication_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1beta1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/authentication/v1beta1" rest "k8s.io/client-go/rest" ) @@ -30,7 +28,7 @@ type AuthenticationV1beta1Interface interface { TokenReviewsGetter } -// AuthenticationV1beta1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// AuthenticationV1beta1Client is used to interact with features provided by the authentication.k8s.io group. type AuthenticationV1beta1Client struct { restClient rest.Interface } @@ -68,22 +66,14 @@ func New(c rest.Interface) *AuthenticationV1beta1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("authentication.k8s.io/v1beta1") - if err != nil { - return err - } - // if authentication.k8s.io/v1beta1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("authentication.k8s.io/v1beta1 is not enabled") - } + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/doc.go index c15d0baccf..11b5238972 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/generated_expansion.go index a397b30e92..2b7e8ca0bf 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/tokenreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/tokenreview.go index 04c2ab09b0..7f9f1e9fa0 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/tokenreview.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authentication/v1beta1/tokenreview.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/BUILD new file mode 100644 index 0000000000..f7f79fceb9 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/BUILD @@ -0,0 +1,30 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "authorization_client.go", + "doc.go", + "generated_expansion.go", + "localsubjectaccessreview.go", + "localsubjectaccessreview_expansion.go", + "selfsubjectaccessreview.go", + "selfsubjectaccessreview_expansion.go", + "subjectaccessreview.go", + "subjectaccessreview_expansion.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authorization/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/authorization_client.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/authorization_client.go new file mode 100644 index 0000000000..af2924a300 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/authorization_client.go @@ -0,0 +1,98 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/authorization/v1" + rest "k8s.io/client-go/rest" +) + +type AuthorizationV1Interface interface { + RESTClient() rest.Interface + LocalSubjectAccessReviewsGetter + SelfSubjectAccessReviewsGetter + SubjectAccessReviewsGetter +} + +// AuthorizationV1Client is used to interact with features provided by the authorization.k8s.io group. +type AuthorizationV1Client struct { + restClient rest.Interface +} + +func (c *AuthorizationV1Client) LocalSubjectAccessReviews(namespace string) LocalSubjectAccessReviewInterface { + return newLocalSubjectAccessReviews(c, namespace) +} + +func (c *AuthorizationV1Client) SelfSubjectAccessReviews() SelfSubjectAccessReviewInterface { + return newSelfSubjectAccessReviews(c) +} + +func (c *AuthorizationV1Client) SubjectAccessReviews() SubjectAccessReviewInterface { + return newSubjectAccessReviews(c) +} + +// NewForConfig creates a new AuthorizationV1Client for the given config. +func NewForConfig(c *rest.Config) (*AuthorizationV1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AuthorizationV1Client{client}, nil +} + +// NewForConfigOrDie creates a new AuthorizationV1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AuthorizationV1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AuthorizationV1Client for the given RESTClient. +func New(c rest.Interface) *AuthorizationV1Client { + return &AuthorizationV1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AuthorizationV1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/doc.go new file mode 100644 index 0000000000..54673bfa73 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/generated_expansion.go new file mode 100644 index 0000000000..42e76d5e43 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/generated_expansion.go @@ -0,0 +1,17 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview.go new file mode 100644 index 0000000000..b2085bceb2 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview.go @@ -0,0 +1,46 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + rest "k8s.io/client-go/rest" +) + +// LocalSubjectAccessReviewsGetter has a method to return a LocalSubjectAccessReviewInterface. +// A group's client should implement this interface. +type LocalSubjectAccessReviewsGetter interface { + LocalSubjectAccessReviews(namespace string) LocalSubjectAccessReviewInterface +} + +// LocalSubjectAccessReviewInterface has methods to work with LocalSubjectAccessReview resources. +type LocalSubjectAccessReviewInterface interface { + LocalSubjectAccessReviewExpansion +} + +// localSubjectAccessReviews implements LocalSubjectAccessReviewInterface +type localSubjectAccessReviews struct { + client rest.Interface + ns string +} + +// newLocalSubjectAccessReviews returns a LocalSubjectAccessReviews +func newLocalSubjectAccessReviews(c *AuthorizationV1Client, namespace string) *localSubjectAccessReviews { + return &localSubjectAccessReviews{ + client: c.RESTClient(), + ns: namespace, + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview_expansion.go new file mode 100644 index 0000000000..c3b487c72c --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/localsubjectaccessreview_expansion.go @@ -0,0 +1,36 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + authorizationapi "k8s.io/client-go/pkg/apis/authorization/v1" +) + +type LocalSubjectAccessReviewExpansion interface { + Create(sar *authorizationapi.LocalSubjectAccessReview) (result *authorizationapi.LocalSubjectAccessReview, err error) +} + +func (c *localSubjectAccessReviews) Create(sar *authorizationapi.LocalSubjectAccessReview) (result *authorizationapi.LocalSubjectAccessReview, err error) { + result = &authorizationapi.LocalSubjectAccessReview{} + err = c.client.Post(). + Namespace(c.ns). + Resource("localsubjectaccessreviews"). + Body(sar). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview.go new file mode 100644 index 0000000000..cfb019eaaf --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + rest "k8s.io/client-go/rest" +) + +// SelfSubjectAccessReviewsGetter has a method to return a SelfSubjectAccessReviewInterface. +// A group's client should implement this interface. +type SelfSubjectAccessReviewsGetter interface { + SelfSubjectAccessReviews() SelfSubjectAccessReviewInterface +} + +// SelfSubjectAccessReviewInterface has methods to work with SelfSubjectAccessReview resources. +type SelfSubjectAccessReviewInterface interface { + SelfSubjectAccessReviewExpansion +} + +// selfSubjectAccessReviews implements SelfSubjectAccessReviewInterface +type selfSubjectAccessReviews struct { + client rest.Interface +} + +// newSelfSubjectAccessReviews returns a SelfSubjectAccessReviews +func newSelfSubjectAccessReviews(c *AuthorizationV1Client) *selfSubjectAccessReviews { + return &selfSubjectAccessReviews{ + client: c.RESTClient(), + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview_expansion.go new file mode 100644 index 0000000000..1076150801 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/selfsubjectaccessreview_expansion.go @@ -0,0 +1,35 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + authorizationapi "k8s.io/client-go/pkg/apis/authorization/v1" +) + +type SelfSubjectAccessReviewExpansion interface { + Create(sar *authorizationapi.SelfSubjectAccessReview) (result *authorizationapi.SelfSubjectAccessReview, err error) +} + +func (c *selfSubjectAccessReviews) Create(sar *authorizationapi.SelfSubjectAccessReview) (result *authorizationapi.SelfSubjectAccessReview, err error) { + result = &authorizationapi.SelfSubjectAccessReview{} + err = c.client.Post(). + Resource("selfsubjectaccessreviews"). + Body(sar). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview.go new file mode 100644 index 0000000000..08f6d60952 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview.go @@ -0,0 +1,44 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + rest "k8s.io/client-go/rest" +) + +// SubjectAccessReviewsGetter has a method to return a SubjectAccessReviewInterface. +// A group's client should implement this interface. +type SubjectAccessReviewsGetter interface { + SubjectAccessReviews() SubjectAccessReviewInterface +} + +// SubjectAccessReviewInterface has methods to work with SubjectAccessReview resources. +type SubjectAccessReviewInterface interface { + SubjectAccessReviewExpansion +} + +// subjectAccessReviews implements SubjectAccessReviewInterface +type subjectAccessReviews struct { + client rest.Interface +} + +// newSubjectAccessReviews returns a SubjectAccessReviews +func newSubjectAccessReviews(c *AuthorizationV1Client) *subjectAccessReviews { + return &subjectAccessReviews{ + client: c.RESTClient(), + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview_expansion.go new file mode 100644 index 0000000000..dfdf6521ae --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1/subjectaccessreview_expansion.go @@ -0,0 +1,36 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + authorizationapi "k8s.io/client-go/pkg/apis/authorization/v1" +) + +// The SubjectAccessReviewExpansion interface allows manually adding extra methods to the AuthorizationInterface. +type SubjectAccessReviewExpansion interface { + Create(sar *authorizationapi.SubjectAccessReview) (result *authorizationapi.SubjectAccessReview, err error) +} + +func (c *subjectAccessReviews) Create(sar *authorizationapi.SubjectAccessReview) (result *authorizationapi.SubjectAccessReview, err error) { + result = &authorizationapi.SubjectAccessReview{} + err = c.client.Post(). + Resource("subjectaccessreviews"). + Body(sar). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/BUILD new file mode 100644 index 0000000000..31c2eaa5a0 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/BUILD @@ -0,0 +1,30 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "authorization_client.go", + "doc.go", + "generated_expansion.go", + "localsubjectaccessreview.go", + "localsubjectaccessreview_expansion.go", + "selfsubjectaccessreview.go", + "selfsubjectaccessreview_expansion.go", + "subjectaccessreview.go", + "subjectaccessreview_expansion.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/authorization_client.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/authorization_client.go index 5993283735..b49b3b30b6 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/authorization_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/authorization_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1beta1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/authorization/v1beta1" rest "k8s.io/client-go/rest" ) @@ -32,7 +30,7 @@ type AuthorizationV1beta1Interface interface { SubjectAccessReviewsGetter } -// AuthorizationV1beta1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// AuthorizationV1beta1Client is used to interact with features provided by the authorization.k8s.io group. type AuthorizationV1beta1Client struct { restClient rest.Interface } @@ -78,22 +76,14 @@ func New(c rest.Interface) *AuthorizationV1beta1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("authorization.k8s.io/v1beta1") - if err != nil { - return err - } - // if authorization.k8s.io/v1beta1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("authorization.k8s.io/v1beta1 is not enabled") - } + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/doc.go index c15d0baccf..11b5238972 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/generated_expansion.go index a397b30e92..2b7e8ca0bf 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/localsubjectaccessreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/localsubjectaccessreview.go index e522706c62..9b8e103419 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/localsubjectaccessreview.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/localsubjectaccessreview.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/selfsubjectaccessreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/selfsubjectaccessreview.go index 24a92eded9..1ef3e49afe 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/selfsubjectaccessreview.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/selfsubjectaccessreview.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/subjectaccessreview.go b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/subjectaccessreview.go index af9b07697a..cd60e9df6b 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/subjectaccessreview.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/authorization/v1beta1/subjectaccessreview.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/BUILD new file mode 100644 index 0000000000..d2de5c6c45 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "autoscaling_client.go", + "doc.go", + "generated_expansion.go", + "horizontalpodautoscaler.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/autoscaling/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/autoscaling_client.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/autoscaling_client.go index d3edda79b0..b235891c91 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/autoscaling_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/autoscaling_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/autoscaling/v1" rest "k8s.io/client-go/rest" ) @@ -30,7 +28,7 @@ type AutoscalingV1Interface interface { HorizontalPodAutoscalersGetter } -// AutoscalingV1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// AutoscalingV1Client is used to interact with features provided by the autoscaling group. type AutoscalingV1Client struct { restClient rest.Interface } @@ -68,22 +66,14 @@ func New(c rest.Interface) *AutoscalingV1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("autoscaling/v1") - if err != nil { - return err - } - // if autoscaling/v1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("autoscaling/v1 is not enabled") - } + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/doc.go index ce67c0e5d5..54673bfa73 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/generated_expansion.go index 3e37a64ef6..effefbd50b 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/horizontalpodautoscaler.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/horizontalpodautoscaler.go index 933df32615..f9c790af22 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/horizontalpodautoscaler.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v1/horizontalpodautoscaler.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" - api_v1 "k8s.io/client-go/pkg/api/v1" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/apis/autoscaling/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -35,12 +36,12 @@ type HorizontalPodAutoscalerInterface interface { Create(*v1.HorizontalPodAutoscaler) (*v1.HorizontalPodAutoscaler, error) Update(*v1.HorizontalPodAutoscaler) (*v1.HorizontalPodAutoscaler, error) UpdateStatus(*v1.HorizontalPodAutoscaler) (*v1.HorizontalPodAutoscaler, error) - Delete(name string, options *api_v1.DeleteOptions) error - DeleteCollection(options *api_v1.DeleteOptions, listOptions api_v1.ListOptions) error - Get(name string) (*v1.HorizontalPodAutoscaler, error) - List(opts api_v1.ListOptions) (*v1.HorizontalPodAutoscalerList, error) - Watch(opts api_v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.HorizontalPodAutoscaler, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.HorizontalPodAutoscaler, error) + List(opts meta_v1.ListOptions) (*v1.HorizontalPodAutoscalerList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.HorizontalPodAutoscaler, err error) HorizontalPodAutoscalerExpansion } @@ -83,6 +84,9 @@ func (c *horizontalPodAutoscalers) Update(horizontalPodAutoscaler *v1.Horizontal return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *horizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *v1.HorizontalPodAutoscaler) (result *v1.HorizontalPodAutoscaler, err error) { result = &v1.HorizontalPodAutoscaler{} err = c.client.Put(). @@ -97,7 +101,7 @@ func (c *horizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *v1.Hori } // Delete takes name of the horizontalPodAutoscaler and deletes it. Returns an error if one occurs. -func (c *horizontalPodAutoscalers) Delete(name string, options *api_v1.DeleteOptions) error { +func (c *horizontalPodAutoscalers) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("horizontalpodautoscalers"). @@ -108,52 +112,53 @@ func (c *horizontalPodAutoscalers) Delete(name string, options *api_v1.DeleteOpt } // DeleteCollection deletes a collection of objects. -func (c *horizontalPodAutoscalers) DeleteCollection(options *api_v1.DeleteOptions, listOptions api_v1.ListOptions) error { +func (c *horizontalPodAutoscalers) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("horizontalpodautoscalers"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the horizontalPodAutoscaler, and returns the corresponding horizontalPodAutoscaler object, and an error if there is any. -func (c *horizontalPodAutoscalers) Get(name string) (result *v1.HorizontalPodAutoscaler, err error) { +func (c *horizontalPodAutoscalers) Get(name string, options meta_v1.GetOptions) (result *v1.HorizontalPodAutoscaler, err error) { result = &v1.HorizontalPodAutoscaler{} err = c.client.Get(). Namespace(c.ns). Resource("horizontalpodautoscalers"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of HorizontalPodAutoscalers that match those selectors. -func (c *horizontalPodAutoscalers) List(opts api_v1.ListOptions) (result *v1.HorizontalPodAutoscalerList, err error) { +func (c *horizontalPodAutoscalers) List(opts meta_v1.ListOptions) (result *v1.HorizontalPodAutoscalerList, err error) { result = &v1.HorizontalPodAutoscalerList{} err = c.client.Get(). Namespace(c.ns). Resource("horizontalpodautoscalers"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers. -func (c *horizontalPodAutoscalers) Watch(opts api_v1.ListOptions) (watch.Interface, error) { +func (c *horizontalPodAutoscalers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("horizontalpodautoscalers"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched horizontalPodAutoscaler. -func (c *horizontalPodAutoscalers) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.HorizontalPodAutoscaler, err error) { +func (c *horizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.HorizontalPodAutoscaler, err error) { result = &v1.HorizontalPodAutoscaler{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/BUILD new file mode 100644 index 0000000000..a9a9cc562e --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "autoscaling_client.go", + "doc.go", + "generated_expansion.go", + "horizontalpodautoscaler.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/autoscaling_client.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/autoscaling_client.go new file mode 100644 index 0000000000..0d16aa3e97 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/autoscaling_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v2alpha1 "k8s.io/client-go/pkg/apis/autoscaling/v2alpha1" + rest "k8s.io/client-go/rest" +) + +type AutoscalingV2alpha1Interface interface { + RESTClient() rest.Interface + HorizontalPodAutoscalersGetter +} + +// AutoscalingV2alpha1Client is used to interact with features provided by the autoscaling group. +type AutoscalingV2alpha1Client struct { + restClient rest.Interface +} + +func (c *AutoscalingV2alpha1Client) HorizontalPodAutoscalers(namespace string) HorizontalPodAutoscalerInterface { + return newHorizontalPodAutoscalers(c, namespace) +} + +// NewForConfig creates a new AutoscalingV2alpha1Client for the given config. +func NewForConfig(c *rest.Config) (*AutoscalingV2alpha1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &AutoscalingV2alpha1Client{client}, nil +} + +// NewForConfigOrDie creates a new AutoscalingV2alpha1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *AutoscalingV2alpha1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new AutoscalingV2alpha1Client for the given RESTClient. +func New(c rest.Interface) *AutoscalingV2alpha1Client { + return &AutoscalingV2alpha1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v2alpha1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *AutoscalingV2alpha1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/doc.go new file mode 100644 index 0000000000..d29bd3f4e1 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v2alpha1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/generated_expansion.go new file mode 100644 index 0000000000..e40f2c5a13 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +type HorizontalPodAutoscalerExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/horizontalpodautoscaler.go b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/horizontalpodautoscaler.go new file mode 100644 index 0000000000..c85bfd9f3c --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/autoscaling/v2alpha1/horizontalpodautoscaler.go @@ -0,0 +1,172 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v2alpha1 "k8s.io/client-go/pkg/apis/autoscaling/v2alpha1" + rest "k8s.io/client-go/rest" +) + +// HorizontalPodAutoscalersGetter has a method to return a HorizontalPodAutoscalerInterface. +// A group's client should implement this interface. +type HorizontalPodAutoscalersGetter interface { + HorizontalPodAutoscalers(namespace string) HorizontalPodAutoscalerInterface +} + +// HorizontalPodAutoscalerInterface has methods to work with HorizontalPodAutoscaler resources. +type HorizontalPodAutoscalerInterface interface { + Create(*v2alpha1.HorizontalPodAutoscaler) (*v2alpha1.HorizontalPodAutoscaler, error) + Update(*v2alpha1.HorizontalPodAutoscaler) (*v2alpha1.HorizontalPodAutoscaler, error) + UpdateStatus(*v2alpha1.HorizontalPodAutoscaler) (*v2alpha1.HorizontalPodAutoscaler, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v2alpha1.HorizontalPodAutoscaler, error) + List(opts v1.ListOptions) (*v2alpha1.HorizontalPodAutoscalerList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.HorizontalPodAutoscaler, err error) + HorizontalPodAutoscalerExpansion +} + +// horizontalPodAutoscalers implements HorizontalPodAutoscalerInterface +type horizontalPodAutoscalers struct { + client rest.Interface + ns string +} + +// newHorizontalPodAutoscalers returns a HorizontalPodAutoscalers +func newHorizontalPodAutoscalers(c *AutoscalingV2alpha1Client, namespace string) *horizontalPodAutoscalers { + return &horizontalPodAutoscalers{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a horizontalPodAutoscaler and creates it. Returns the server's representation of the horizontalPodAutoscaler, and an error, if there is any. +func (c *horizontalPodAutoscalers) Create(horizontalPodAutoscaler *v2alpha1.HorizontalPodAutoscaler) (result *v2alpha1.HorizontalPodAutoscaler, err error) { + result = &v2alpha1.HorizontalPodAutoscaler{} + err = c.client.Post(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + Body(horizontalPodAutoscaler). + Do(). + Into(result) + return +} + +// Update takes the representation of a horizontalPodAutoscaler and updates it. Returns the server's representation of the horizontalPodAutoscaler, and an error, if there is any. +func (c *horizontalPodAutoscalers) Update(horizontalPodAutoscaler *v2alpha1.HorizontalPodAutoscaler) (result *v2alpha1.HorizontalPodAutoscaler, err error) { + result = &v2alpha1.HorizontalPodAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + Name(horizontalPodAutoscaler.Name). + Body(horizontalPodAutoscaler). + Do(). + Into(result) + return +} + +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + +func (c *horizontalPodAutoscalers) UpdateStatus(horizontalPodAutoscaler *v2alpha1.HorizontalPodAutoscaler) (result *v2alpha1.HorizontalPodAutoscaler, err error) { + result = &v2alpha1.HorizontalPodAutoscaler{} + err = c.client.Put(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + Name(horizontalPodAutoscaler.Name). + SubResource("status"). + Body(horizontalPodAutoscaler). + Do(). + Into(result) + return +} + +// Delete takes name of the horizontalPodAutoscaler and deletes it. Returns an error if one occurs. +func (c *horizontalPodAutoscalers) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *horizontalPodAutoscalers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the horizontalPodAutoscaler, and returns the corresponding horizontalPodAutoscaler object, and an error if there is any. +func (c *horizontalPodAutoscalers) Get(name string, options v1.GetOptions) (result *v2alpha1.HorizontalPodAutoscaler, err error) { + result = &v2alpha1.HorizontalPodAutoscaler{} + err = c.client.Get(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of HorizontalPodAutoscalers that match those selectors. +func (c *horizontalPodAutoscalers) List(opts v1.ListOptions) (result *v2alpha1.HorizontalPodAutoscalerList, err error) { + result = &v2alpha1.HorizontalPodAutoscalerList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested horizontalPodAutoscalers. +func (c *horizontalPodAutoscalers) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched horizontalPodAutoscaler. +func (c *horizontalPodAutoscalers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.HorizontalPodAutoscaler, err error) { + result = &v2alpha1.HorizontalPodAutoscaler{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("horizontalpodautoscalers"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/BUILD new file mode 100644 index 0000000000..96b346b164 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "batch_client.go", + "doc.go", + "generated_expansion.go", + "job.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/batch_client.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/batch_client.go index 5b4012b72c..c8766f5b60 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/batch_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/batch_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/batch/v1" rest "k8s.io/client-go/rest" ) @@ -30,7 +28,7 @@ type BatchV1Interface interface { JobsGetter } -// BatchV1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// BatchV1Client is used to interact with features provided by the batch group. type BatchV1Client struct { restClient rest.Interface } @@ -68,22 +66,14 @@ func New(c rest.Interface) *BatchV1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("batch/v1") - if err != nil { - return err - } - // if batch/v1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("batch/v1 is not enabled") - } + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/doc.go index ce67c0e5d5..54673bfa73 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/generated_expansion.go index b24faa3157..68d7741fa0 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/job.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/job.go index dc2e738ed3..c8120f6d85 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/job.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v1/job.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" - api_v1 "k8s.io/client-go/pkg/api/v1" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/apis/batch/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -35,12 +36,12 @@ type JobInterface interface { Create(*v1.Job) (*v1.Job, error) Update(*v1.Job) (*v1.Job, error) UpdateStatus(*v1.Job) (*v1.Job, error) - Delete(name string, options *api_v1.DeleteOptions) error - DeleteCollection(options *api_v1.DeleteOptions, listOptions api_v1.ListOptions) error - Get(name string) (*v1.Job, error) - List(opts api_v1.ListOptions) (*v1.JobList, error) - Watch(opts api_v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Job, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Job, error) + List(opts meta_v1.ListOptions) (*v1.JobList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Job, err error) JobExpansion } @@ -83,6 +84,9 @@ func (c *jobs) Update(job *v1.Job) (result *v1.Job, err error) { return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *jobs) UpdateStatus(job *v1.Job) (result *v1.Job, err error) { result = &v1.Job{} err = c.client.Put(). @@ -97,7 +101,7 @@ func (c *jobs) UpdateStatus(job *v1.Job) (result *v1.Job, err error) { } // Delete takes name of the job and deletes it. Returns an error if one occurs. -func (c *jobs) Delete(name string, options *api_v1.DeleteOptions) error { +func (c *jobs) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("jobs"). @@ -108,52 +112,53 @@ func (c *jobs) Delete(name string, options *api_v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *jobs) DeleteCollection(options *api_v1.DeleteOptions, listOptions api_v1.ListOptions) error { +func (c *jobs) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("jobs"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the job, and returns the corresponding job object, and an error if there is any. -func (c *jobs) Get(name string) (result *v1.Job, err error) { +func (c *jobs) Get(name string, options meta_v1.GetOptions) (result *v1.Job, err error) { result = &v1.Job{} err = c.client.Get(). Namespace(c.ns). Resource("jobs"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Jobs that match those selectors. -func (c *jobs) List(opts api_v1.ListOptions) (result *v1.JobList, err error) { +func (c *jobs) List(opts meta_v1.ListOptions) (result *v1.JobList, err error) { result = &v1.JobList{} err = c.client.Get(). Namespace(c.ns). Resource("jobs"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested jobs. -func (c *jobs) Watch(opts api_v1.ListOptions) (watch.Interface, error) { +func (c *jobs) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("jobs"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched job. -func (c *jobs) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Job, err error) { +func (c *jobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Job, err error) { result = &v1.Job{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/BUILD new file mode 100644 index 0000000000..853dda84d6 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "batch_client.go", + "cronjob.go", + "doc.go", + "generated_expansion.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/batch_client.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/batch_client.go index c9440702ac..e2b2dd5cd0 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/batch_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/batch_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,21 +17,18 @@ limitations under the License. package v2alpha1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" rest "k8s.io/client-go/rest" ) type BatchV2alpha1Interface interface { RESTClient() rest.Interface CronJobsGetter - JobsGetter } -// BatchV2alpha1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// BatchV2alpha1Client is used to interact with features provided by the batch group. type BatchV2alpha1Client struct { restClient rest.Interface } @@ -40,10 +37,6 @@ func (c *BatchV2alpha1Client) CronJobs(namespace string) CronJobInterface { return newCronJobs(c, namespace) } -func (c *BatchV2alpha1Client) Jobs(namespace string) JobInterface { - return newJobs(c, namespace) -} - // NewForConfig creates a new BatchV2alpha1Client for the given config. func NewForConfig(c *rest.Config) (*BatchV2alpha1Client, error) { config := *c @@ -73,22 +66,14 @@ func New(c rest.Interface) *BatchV2alpha1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("batch/v2alpha1") - if err != nil { - return err - } - // if batch/v2alpha1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("batch/v2alpha1 is not enabled") - } + gv := v2alpha1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/cronjob.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/cronjob.go index 5f728afa1d..2447f2add0 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/cronjob.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/cronjob.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v2alpha1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type CronJobInterface interface { UpdateStatus(*v2alpha1.CronJob) (*v2alpha1.CronJob, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v2alpha1.CronJob, error) + Get(name string, options v1.GetOptions) (*v2alpha1.CronJob, error) List(opts v1.ListOptions) (*v2alpha1.CronJobList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v2alpha1.CronJob, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.CronJob, err error) CronJobExpansion } @@ -83,6 +84,9 @@ func (c *cronJobs) Update(cronJob *v2alpha1.CronJob) (result *v2alpha1.CronJob, return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *cronJobs) UpdateStatus(cronJob *v2alpha1.CronJob) (result *v2alpha1.CronJob, err error) { result = &v2alpha1.CronJob{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *cronJobs) DeleteCollection(options *v1.DeleteOptions, listOptions v1.Li return c.client.Delete(). Namespace(c.ns). Resource("cronjobs"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the cronJob, and returns the corresponding cronJob object, and an error if there is any. -func (c *cronJobs) Get(name string) (result *v2alpha1.CronJob, err error) { +func (c *cronJobs) Get(name string, options v1.GetOptions) (result *v2alpha1.CronJob, err error) { result = &v2alpha1.CronJob{} err = c.client.Get(). Namespace(c.ns). Resource("cronjobs"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *cronJobs) List(opts v1.ListOptions) (result *v2alpha1.CronJobList, err err = c.client.Get(). Namespace(c.ns). Resource("cronjobs"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *cronJobs) List(opts v1.ListOptions) (result *v2alpha1.CronJobList, err // Watch returns a watch.Interface that watches the requested cronJobs. func (c *cronJobs) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("cronjobs"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched cronJob. -func (c *cronJobs) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v2alpha1.CronJob, err error) { +func (c *cronJobs) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v2alpha1.CronJob, err error) { result = &v2alpha1.CronJob{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/doc.go index 05887a553d..d29bd3f4e1 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v2alpha1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/generated_expansion.go index 2a4b63a2a7..078027ef49 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,5 +17,3 @@ limitations under the License. package v2alpha1 type CronJobExpansion interface{} - -type JobExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/job.go b/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/job.go deleted file mode 100644 index f7a1fdb616..0000000000 --- a/vendor/k8s.io/client-go/kubernetes/typed/batch/v2alpha1/job.go +++ /dev/null @@ -1,167 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v2alpha1 - -import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" - v2alpha1 "k8s.io/client-go/pkg/apis/batch/v2alpha1" - watch "k8s.io/client-go/pkg/watch" - rest "k8s.io/client-go/rest" -) - -// JobsGetter has a method to return a JobInterface. -// A group's client should implement this interface. -type JobsGetter interface { - Jobs(namespace string) JobInterface -} - -// JobInterface has methods to work with Job resources. -type JobInterface interface { - Create(*v2alpha1.Job) (*v2alpha1.Job, error) - Update(*v2alpha1.Job) (*v2alpha1.Job, error) - UpdateStatus(*v2alpha1.Job) (*v2alpha1.Job, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v2alpha1.Job, error) - List(opts v1.ListOptions) (*v2alpha1.JobList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v2alpha1.Job, err error) - JobExpansion -} - -// jobs implements JobInterface -type jobs struct { - client rest.Interface - ns string -} - -// newJobs returns a Jobs -func newJobs(c *BatchV2alpha1Client, namespace string) *jobs { - return &jobs{ - client: c.RESTClient(), - ns: namespace, - } -} - -// Create takes the representation of a job and creates it. Returns the server's representation of the job, and an error, if there is any. -func (c *jobs) Create(job *v2alpha1.Job) (result *v2alpha1.Job, err error) { - result = &v2alpha1.Job{} - err = c.client.Post(). - Namespace(c.ns). - Resource("jobs"). - Body(job). - Do(). - Into(result) - return -} - -// Update takes the representation of a job and updates it. Returns the server's representation of the job, and an error, if there is any. -func (c *jobs) Update(job *v2alpha1.Job) (result *v2alpha1.Job, err error) { - result = &v2alpha1.Job{} - err = c.client.Put(). - Namespace(c.ns). - Resource("jobs"). - Name(job.Name). - Body(job). - Do(). - Into(result) - return -} - -func (c *jobs) UpdateStatus(job *v2alpha1.Job) (result *v2alpha1.Job, err error) { - result = &v2alpha1.Job{} - err = c.client.Put(). - Namespace(c.ns). - Resource("jobs"). - Name(job.Name). - SubResource("status"). - Body(job). - Do(). - Into(result) - return -} - -// Delete takes name of the job and deletes it. Returns an error if one occurs. -func (c *jobs) Delete(name string, options *v1.DeleteOptions) error { - return c.client.Delete(). - Namespace(c.ns). - Resource("jobs"). - Name(name). - Body(options). - Do(). - Error() -} - -// DeleteCollection deletes a collection of objects. -func (c *jobs) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { - return c.client.Delete(). - Namespace(c.ns). - Resource("jobs"). - VersionedParams(&listOptions, api.ParameterCodec). - Body(options). - Do(). - Error() -} - -// Get takes name of the job, and returns the corresponding job object, and an error if there is any. -func (c *jobs) Get(name string) (result *v2alpha1.Job, err error) { - result = &v2alpha1.Job{} - err = c.client.Get(). - Namespace(c.ns). - Resource("jobs"). - Name(name). - Do(). - Into(result) - return -} - -// List takes label and field selectors, and returns the list of Jobs that match those selectors. -func (c *jobs) List(opts v1.ListOptions) (result *v2alpha1.JobList, err error) { - result = &v2alpha1.JobList{} - err = c.client.Get(). - Namespace(c.ns). - Resource("jobs"). - VersionedParams(&opts, api.ParameterCodec). - Do(). - Into(result) - return -} - -// Watch returns a watch.Interface that watches the requested jobs. -func (c *jobs) Watch(opts v1.ListOptions) (watch.Interface, error) { - return c.client.Get(). - Prefix("watch"). - Namespace(c.ns). - Resource("jobs"). - VersionedParams(&opts, api.ParameterCodec). - Watch() -} - -// Patch applies the patch and returns the patched job. -func (c *jobs) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v2alpha1.Job, err error) { - result = &v2alpha1.Job{} - err = c.client.Patch(pt). - Namespace(c.ns). - Resource("jobs"). - SubResource(subresources...). - Name(name). - Body(data). - Do(). - Into(result) - return -} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificates_client.go b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificates_client.go deleted file mode 100644 index b7fcc70078..0000000000 --- a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificates_client.go +++ /dev/null @@ -1,98 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" - rest "k8s.io/client-go/rest" -) - -type CertificatesV1alpha1Interface interface { - RESTClient() rest.Interface - CertificateSigningRequestsGetter -} - -// CertificatesV1alpha1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. -type CertificatesV1alpha1Client struct { - restClient rest.Interface -} - -func (c *CertificatesV1alpha1Client) CertificateSigningRequests() CertificateSigningRequestInterface { - return newCertificateSigningRequests(c) -} - -// NewForConfig creates a new CertificatesV1alpha1Client for the given config. -func NewForConfig(c *rest.Config) (*CertificatesV1alpha1Client, error) { - config := *c - if err := setConfigDefaults(&config); err != nil { - return nil, err - } - client, err := rest.RESTClientFor(&config) - if err != nil { - return nil, err - } - return &CertificatesV1alpha1Client{client}, nil -} - -// NewForConfigOrDie creates a new CertificatesV1alpha1Client for the given config and -// panics if there is an error in the config. -func NewForConfigOrDie(c *rest.Config) *CertificatesV1alpha1Client { - client, err := NewForConfig(c) - if err != nil { - panic(err) - } - return client -} - -// New creates a new CertificatesV1alpha1Client for the given RESTClient. -func New(c rest.Interface) *CertificatesV1alpha1Client { - return &CertificatesV1alpha1Client{c} -} - -func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("certificates.k8s.io/v1alpha1") - if err != nil { - return err - } - // if certificates.k8s.io/v1alpha1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("certificates.k8s.io/v1alpha1 is not enabled") - } - config.APIPath = "/apis" - if config.UserAgent == "" { - config.UserAgent = rest.DefaultKubernetesUserAgent() - } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} - - return nil -} - -// RESTClient returns a RESTClient that is used to communicate -// with API server by this client implementation. -func (c *CertificatesV1alpha1Client) RESTClient() rest.Interface { - if c == nil { - return nil - } - return c.restClient -} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/BUILD new file mode 100644 index 0000000000..1ccad8ef33 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "certificates_client.go", + "certificatesigningrequest.go", + "certificatesigningrequest_expansion.go", + "doc.go", + "generated_expansion.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificates_client.go b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificates_client.go new file mode 100644 index 0000000000..c9c39acb20 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificates_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/certificates/v1beta1" + rest "k8s.io/client-go/rest" +) + +type CertificatesV1beta1Interface interface { + RESTClient() rest.Interface + CertificateSigningRequestsGetter +} + +// CertificatesV1beta1Client is used to interact with features provided by the certificates.k8s.io group. +type CertificatesV1beta1Client struct { + restClient rest.Interface +} + +func (c *CertificatesV1beta1Client) CertificateSigningRequests() CertificateSigningRequestInterface { + return newCertificateSigningRequests(c) +} + +// NewForConfig creates a new CertificatesV1beta1Client for the given config. +func NewForConfig(c *rest.Config) (*CertificatesV1beta1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &CertificatesV1beta1Client{client}, nil +} + +// NewForConfigOrDie creates a new CertificatesV1beta1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *CertificatesV1beta1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new CertificatesV1beta1Client for the given RESTClient. +func New(c rest.Interface) *CertificatesV1beta1Client { + return &CertificatesV1beta1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *CertificatesV1beta1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificatesigningrequest.go b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificatesigningrequest.go similarity index 65% rename from vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificatesigningrequest.go rename to vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificatesigningrequest.go index f0cfd274eb..7407ef0688 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificatesigningrequest.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificatesigningrequest.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,13 +14,14 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" - v1alpha1 "k8s.io/client-go/pkg/apis/certificates/v1alpha1" - watch "k8s.io/client-go/pkg/watch" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/certificates/v1beta1" rest "k8s.io/client-go/rest" ) @@ -32,15 +33,15 @@ type CertificateSigningRequestsGetter interface { // CertificateSigningRequestInterface has methods to work with CertificateSigningRequest resources. type CertificateSigningRequestInterface interface { - Create(*v1alpha1.CertificateSigningRequest) (*v1alpha1.CertificateSigningRequest, error) - Update(*v1alpha1.CertificateSigningRequest) (*v1alpha1.CertificateSigningRequest, error) - UpdateStatus(*v1alpha1.CertificateSigningRequest) (*v1alpha1.CertificateSigningRequest, error) + Create(*v1beta1.CertificateSigningRequest) (*v1beta1.CertificateSigningRequest, error) + Update(*v1beta1.CertificateSigningRequest) (*v1beta1.CertificateSigningRequest, error) + UpdateStatus(*v1beta1.CertificateSigningRequest) (*v1beta1.CertificateSigningRequest, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1alpha1.CertificateSigningRequest, error) - List(opts v1.ListOptions) (*v1alpha1.CertificateSigningRequestList, error) + Get(name string, options v1.GetOptions) (*v1beta1.CertificateSigningRequest, error) + List(opts v1.ListOptions) (*v1beta1.CertificateSigningRequestList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.CertificateSigningRequest, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CertificateSigningRequest, err error) CertificateSigningRequestExpansion } @@ -50,15 +51,15 @@ type certificateSigningRequests struct { } // newCertificateSigningRequests returns a CertificateSigningRequests -func newCertificateSigningRequests(c *CertificatesV1alpha1Client) *certificateSigningRequests { +func newCertificateSigningRequests(c *CertificatesV1beta1Client) *certificateSigningRequests { return &certificateSigningRequests{ client: c.RESTClient(), } } // Create takes the representation of a certificateSigningRequest and creates it. Returns the server's representation of the certificateSigningRequest, and an error, if there is any. -func (c *certificateSigningRequests) Create(certificateSigningRequest *v1alpha1.CertificateSigningRequest) (result *v1alpha1.CertificateSigningRequest, err error) { - result = &v1alpha1.CertificateSigningRequest{} +func (c *certificateSigningRequests) Create(certificateSigningRequest *v1beta1.CertificateSigningRequest) (result *v1beta1.CertificateSigningRequest, err error) { + result = &v1beta1.CertificateSigningRequest{} err = c.client.Post(). Resource("certificatesigningrequests"). Body(certificateSigningRequest). @@ -68,8 +69,8 @@ func (c *certificateSigningRequests) Create(certificateSigningRequest *v1alpha1. } // Update takes the representation of a certificateSigningRequest and updates it. Returns the server's representation of the certificateSigningRequest, and an error, if there is any. -func (c *certificateSigningRequests) Update(certificateSigningRequest *v1alpha1.CertificateSigningRequest) (result *v1alpha1.CertificateSigningRequest, err error) { - result = &v1alpha1.CertificateSigningRequest{} +func (c *certificateSigningRequests) Update(certificateSigningRequest *v1beta1.CertificateSigningRequest) (result *v1beta1.CertificateSigningRequest, err error) { + result = &v1beta1.CertificateSigningRequest{} err = c.client.Put(). Resource("certificatesigningrequests"). Name(certificateSigningRequest.Name). @@ -79,8 +80,11 @@ func (c *certificateSigningRequests) Update(certificateSigningRequest *v1alpha1. return } -func (c *certificateSigningRequests) UpdateStatus(certificateSigningRequest *v1alpha1.CertificateSigningRequest) (result *v1alpha1.CertificateSigningRequest, err error) { - result = &v1alpha1.CertificateSigningRequest{} +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + +func (c *certificateSigningRequests) UpdateStatus(certificateSigningRequest *v1beta1.CertificateSigningRequest) (result *v1beta1.CertificateSigningRequest, err error) { + result = &v1beta1.CertificateSigningRequest{} err = c.client.Put(). Resource("certificatesigningrequests"). Name(certificateSigningRequest.Name). @@ -105,29 +109,30 @@ func (c *certificateSigningRequests) Delete(name string, options *v1.DeleteOptio func (c *certificateSigningRequests) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { return c.client.Delete(). Resource("certificatesigningrequests"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the certificateSigningRequest, and returns the corresponding certificateSigningRequest object, and an error if there is any. -func (c *certificateSigningRequests) Get(name string) (result *v1alpha1.CertificateSigningRequest, err error) { - result = &v1alpha1.CertificateSigningRequest{} +func (c *certificateSigningRequests) Get(name string, options v1.GetOptions) (result *v1beta1.CertificateSigningRequest, err error) { + result = &v1beta1.CertificateSigningRequest{} err = c.client.Get(). Resource("certificatesigningrequests"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of CertificateSigningRequests that match those selectors. -func (c *certificateSigningRequests) List(opts v1.ListOptions) (result *v1alpha1.CertificateSigningRequestList, err error) { - result = &v1alpha1.CertificateSigningRequestList{} +func (c *certificateSigningRequests) List(opts v1.ListOptions) (result *v1beta1.CertificateSigningRequestList, err error) { + result = &v1beta1.CertificateSigningRequestList{} err = c.client.Get(). Resource("certificatesigningrequests"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -135,16 +140,16 @@ func (c *certificateSigningRequests) List(opts v1.ListOptions) (result *v1alpha1 // Watch returns a watch.Interface that watches the requested certificateSigningRequests. func (c *certificateSigningRequests) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("certificatesigningrequests"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched certificateSigningRequest. -func (c *certificateSigningRequests) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.CertificateSigningRequest, err error) { - result = &v1alpha1.CertificateSigningRequest{} +func (c *certificateSigningRequests) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.CertificateSigningRequest, err error) { + result = &v1beta1.CertificateSigningRequest{} err = c.client.Patch(pt). Resource("certificatesigningrequests"). SubResource(subresources...). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificatesigningrequest_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificatesigningrequest_expansion.go similarity index 90% rename from vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificatesigningrequest_expansion.go rename to vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificatesigningrequest_expansion.go index 580f92c202..4765bba8ab 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/certificatesigningrequest_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/certificatesigningrequest_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,10 +14,10 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( - certificates "k8s.io/client-go/pkg/apis/certificates/v1alpha1" + certificates "k8s.io/client-go/pkg/apis/certificates/v1beta1" ) type CertificateSigningRequestExpansion interface { diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/doc.go new file mode 100644 index 0000000000..11b5238972 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/generated_expansion.go new file mode 100644 index 0000000000..2b7e8ca0bf --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1beta1/generated_expansion.go @@ -0,0 +1,17 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/BUILD new file mode 100644 index 0000000000..c77524e891 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/BUILD @@ -0,0 +1,53 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "componentstatus.go", + "configmap.go", + "core_client.go", + "doc.go", + "endpoints.go", + "event.go", + "event_expansion.go", + "generated_expansion.go", + "limitrange.go", + "namespace.go", + "namespace_expansion.go", + "node.go", + "node_expansion.go", + "persistentvolume.go", + "persistentvolumeclaim.go", + "pod.go", + "pod_expansion.go", + "podtemplate.go", + "replicationcontroller.go", + "resourcequota.go", + "secret.go", + "service.go", + "service_expansion.go", + "serviceaccount.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1/ref:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/policy/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/componentstatus.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/componentstatus.go index 0a594b41e5..50671976aa 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/componentstatus.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/componentstatus.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type ComponentStatusesGetter interface { type ComponentStatusInterface interface { Create(*v1.ComponentStatus) (*v1.ComponentStatus, error) Update(*v1.ComponentStatus) (*v1.ComponentStatus, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.ComponentStatus, error) - List(opts v1.ListOptions) (*v1.ComponentStatusList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ComponentStatus, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.ComponentStatus, error) + List(opts meta_v1.ListOptions) (*v1.ComponentStatusList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ComponentStatus, err error) ComponentStatusExpansion } @@ -78,7 +80,7 @@ func (c *componentStatuses) Update(componentStatus *v1.ComponentStatus) (result } // Delete takes name of the componentStatus and deletes it. Returns an error if one occurs. -func (c *componentStatuses) Delete(name string, options *v1.DeleteOptions) error { +func (c *componentStatuses) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Resource("componentstatuses"). Name(name). @@ -88,48 +90,49 @@ func (c *componentStatuses) Delete(name string, options *v1.DeleteOptions) error } // DeleteCollection deletes a collection of objects. -func (c *componentStatuses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *componentStatuses) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Resource("componentstatuses"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the componentStatus, and returns the corresponding componentStatus object, and an error if there is any. -func (c *componentStatuses) Get(name string) (result *v1.ComponentStatus, err error) { +func (c *componentStatuses) Get(name string, options meta_v1.GetOptions) (result *v1.ComponentStatus, err error) { result = &v1.ComponentStatus{} err = c.client.Get(). Resource("componentstatuses"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of ComponentStatuses that match those selectors. -func (c *componentStatuses) List(opts v1.ListOptions) (result *v1.ComponentStatusList, err error) { +func (c *componentStatuses) List(opts meta_v1.ListOptions) (result *v1.ComponentStatusList, err error) { result = &v1.ComponentStatusList{} err = c.client.Get(). Resource("componentstatuses"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested componentStatuses. -func (c *componentStatuses) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *componentStatuses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("componentstatuses"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched componentStatus. -func (c *componentStatuses) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ComponentStatus, err error) { +func (c *componentStatuses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ComponentStatus, err error) { result = &v1.ComponentStatus{} err = c.client.Patch(pt). Resource("componentstatuses"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/configmap.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/configmap.go index db0298035a..bb21636e2d 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/configmap.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/configmap.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type ConfigMapsGetter interface { type ConfigMapInterface interface { Create(*v1.ConfigMap) (*v1.ConfigMap, error) Update(*v1.ConfigMap) (*v1.ConfigMap, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.ConfigMap, error) - List(opts v1.ListOptions) (*v1.ConfigMapList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ConfigMap, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.ConfigMap, error) + List(opts meta_v1.ListOptions) (*v1.ConfigMapList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ConfigMap, err error) ConfigMapExpansion } @@ -82,7 +84,7 @@ func (c *configMaps) Update(configMap *v1.ConfigMap) (result *v1.ConfigMap, err } // Delete takes name of the configMap and deletes it. Returns an error if one occurs. -func (c *configMaps) Delete(name string, options *v1.DeleteOptions) error { +func (c *configMaps) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("configmaps"). @@ -93,52 +95,53 @@ func (c *configMaps) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *configMaps) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *configMaps) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("configmaps"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the configMap, and returns the corresponding configMap object, and an error if there is any. -func (c *configMaps) Get(name string) (result *v1.ConfigMap, err error) { +func (c *configMaps) Get(name string, options meta_v1.GetOptions) (result *v1.ConfigMap, err error) { result = &v1.ConfigMap{} err = c.client.Get(). Namespace(c.ns). Resource("configmaps"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of ConfigMaps that match those selectors. -func (c *configMaps) List(opts v1.ListOptions) (result *v1.ConfigMapList, err error) { +func (c *configMaps) List(opts meta_v1.ListOptions) (result *v1.ConfigMapList, err error) { result = &v1.ConfigMapList{} err = c.client.Get(). Namespace(c.ns). Resource("configmaps"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested configMaps. -func (c *configMaps) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *configMaps) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("configmaps"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched configMap. -func (c *configMaps) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ConfigMap, err error) { +func (c *configMaps) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ConfigMap, err error) { result = &v1.ConfigMap{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/core_client.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/core_client.go index 0c9139ade4..0972960d10 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/core_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/core_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/api/v1" rest "k8s.io/client-go/rest" ) @@ -45,7 +43,7 @@ type CoreV1Interface interface { ServiceAccountsGetter } -// CoreV1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// CoreV1Client is used to interact with features provided by the group. type CoreV1Client struct { restClient rest.Interface } @@ -143,22 +141,14 @@ func New(c rest.Interface) *CoreV1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("/v1") - if err != nil { - return err - } - // if /v1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("/v1 is not enabled") - } + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/api" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/doc.go index ce67c0e5d5..54673bfa73 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/endpoints.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/endpoints.go index 5462e64d65..3580742a86 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/endpoints.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/endpoints.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type EndpointsGetter interface { type EndpointsInterface interface { Create(*v1.Endpoints) (*v1.Endpoints, error) Update(*v1.Endpoints) (*v1.Endpoints, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Endpoints, error) - List(opts v1.ListOptions) (*v1.EndpointsList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Endpoints, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Endpoints, error) + List(opts meta_v1.ListOptions) (*v1.EndpointsList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Endpoints, err error) EndpointsExpansion } @@ -82,7 +84,7 @@ func (c *endpoints) Update(endpoints *v1.Endpoints) (result *v1.Endpoints, err e } // Delete takes name of the endpoints and deletes it. Returns an error if one occurs. -func (c *endpoints) Delete(name string, options *v1.DeleteOptions) error { +func (c *endpoints) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("endpoints"). @@ -93,52 +95,53 @@ func (c *endpoints) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *endpoints) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *endpoints) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("endpoints"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the endpoints, and returns the corresponding endpoints object, and an error if there is any. -func (c *endpoints) Get(name string) (result *v1.Endpoints, err error) { +func (c *endpoints) Get(name string, options meta_v1.GetOptions) (result *v1.Endpoints, err error) { result = &v1.Endpoints{} err = c.client.Get(). Namespace(c.ns). Resource("endpoints"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Endpoints that match those selectors. -func (c *endpoints) List(opts v1.ListOptions) (result *v1.EndpointsList, err error) { +func (c *endpoints) List(opts meta_v1.ListOptions) (result *v1.EndpointsList, err error) { result = &v1.EndpointsList{} err = c.client.Get(). Namespace(c.ns). Resource("endpoints"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested endpoints. -func (c *endpoints) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *endpoints) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("endpoints"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched endpoints. -func (c *endpoints) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Endpoints, err error) { +func (c *endpoints) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Endpoints, err error) { result = &v1.Endpoints{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event.go index 94710ebfa1..c4ac11006c 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type EventsGetter interface { type EventInterface interface { Create(*v1.Event) (*v1.Event, error) Update(*v1.Event) (*v1.Event, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Event, error) - List(opts v1.ListOptions) (*v1.EventList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Event, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Event, error) + List(opts meta_v1.ListOptions) (*v1.EventList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Event, err error) EventExpansion } @@ -82,7 +84,7 @@ func (c *events) Update(event *v1.Event) (result *v1.Event, err error) { } // Delete takes name of the event and deletes it. Returns an error if one occurs. -func (c *events) Delete(name string, options *v1.DeleteOptions) error { +func (c *events) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("events"). @@ -93,52 +95,53 @@ func (c *events) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *events) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *events) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("events"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the event, and returns the corresponding event object, and an error if there is any. -func (c *events) Get(name string) (result *v1.Event, err error) { +func (c *events) Get(name string, options meta_v1.GetOptions) (result *v1.Event, err error) { result = &v1.Event{} err = c.client.Get(). Namespace(c.ns). Resource("events"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Events that match those selectors. -func (c *events) List(opts v1.ListOptions) (result *v1.EventList, err error) { +func (c *events) List(opts meta_v1.ListOptions) (result *v1.EventList, err error) { result = &v1.EventList{} err = c.client.Get(). Namespace(c.ns). Resource("events"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested events. -func (c *events) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *events) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("events"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched event. -func (c *events) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Event, err error) { +func (c *events) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Event, err error) { result = &v1.Event{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event_expansion.go index 5a893ca2db..0ad170b3d7 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/event_expansion.go @@ -19,10 +19,12 @@ package v1 import ( "fmt" - "k8s.io/client-go/pkg/api" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/runtime" + "k8s.io/client-go/pkg/api/v1/ref" ) // The EventExpansion interface allows manually adding extra methods to the EventInterface. @@ -33,7 +35,7 @@ type EventExpansion interface { UpdateWithEventNamespace(event *v1.Event) (*v1.Event, error) PatchWithEventNamespace(event *v1.Event, data []byte) (*v1.Event, error) // Search finds events about the specified object - Search(objOrRef runtime.Object) (*v1.EventList, error) + Search(scheme *runtime.Scheme, objOrRef runtime.Object) (*v1.EventList, error) // Returns the appropriate field selector based on the API version being used to communicate with the server. // The returned field selector can be used with List and Watch to filter desired events. GetFieldSelector(involvedObjectName, involvedObjectNamespace, involvedObjectKind, involvedObjectUID *string) fields.Selector @@ -84,7 +86,7 @@ func (e *events) PatchWithEventNamespace(incompleteEvent *v1.Event, data []byte) return nil, fmt.Errorf("can't patch an event with namespace '%v' in namespace '%v'", incompleteEvent.Namespace, e.ns) } result := &v1.Event{} - err := e.client.Patch(api.StrategicMergePatchType). + err := e.client.Patch(types.StrategicMergePatchType). NamespaceIfScoped(incompleteEvent.Namespace, len(incompleteEvent.Namespace) > 0). Resource("events"). Name(incompleteEvent.Name). @@ -97,8 +99,8 @@ func (e *events) PatchWithEventNamespace(incompleteEvent *v1.Event, data []byte) // Search finds events about the specified object. The namespace of the // object must match this event's client namespace unless the event client // was made with the "" namespace. -func (e *events) Search(objOrRef runtime.Object) (*v1.EventList, error) { - ref, err := api.GetReference(objOrRef) +func (e *events) Search(scheme *runtime.Scheme, objOrRef runtime.Object) (*v1.EventList, error) { + ref, err := ref.GetReference(scheme, objOrRef) if err != nil { return nil, err } @@ -116,7 +118,7 @@ func (e *events) Search(objOrRef runtime.Object) (*v1.EventList, error) { refUID = &stringRefUID } fieldSelector := e.GetFieldSelector(&ref.Name, &ref.Namespace, refKind, refUID) - return e.List(v1.ListOptions{FieldSelector: fieldSelector.String()}) + return e.List(metav1.ListOptions{FieldSelector: fieldSelector.String()}) } // Returns the appropriate field selector based on the API version being used to communicate with the server. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/generated_expansion.go index 616adfa18e..5fe0585b41 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/limitrange.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/limitrange.go index d61496b498..998f03452c 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/limitrange.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/limitrange.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type LimitRangesGetter interface { type LimitRangeInterface interface { Create(*v1.LimitRange) (*v1.LimitRange, error) Update(*v1.LimitRange) (*v1.LimitRange, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.LimitRange, error) - List(opts v1.ListOptions) (*v1.LimitRangeList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.LimitRange, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.LimitRange, error) + List(opts meta_v1.ListOptions) (*v1.LimitRangeList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.LimitRange, err error) LimitRangeExpansion } @@ -82,7 +84,7 @@ func (c *limitRanges) Update(limitRange *v1.LimitRange) (result *v1.LimitRange, } // Delete takes name of the limitRange and deletes it. Returns an error if one occurs. -func (c *limitRanges) Delete(name string, options *v1.DeleteOptions) error { +func (c *limitRanges) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("limitranges"). @@ -93,52 +95,53 @@ func (c *limitRanges) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *limitRanges) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *limitRanges) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("limitranges"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the limitRange, and returns the corresponding limitRange object, and an error if there is any. -func (c *limitRanges) Get(name string) (result *v1.LimitRange, err error) { +func (c *limitRanges) Get(name string, options meta_v1.GetOptions) (result *v1.LimitRange, err error) { result = &v1.LimitRange{} err = c.client.Get(). Namespace(c.ns). Resource("limitranges"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of LimitRanges that match those selectors. -func (c *limitRanges) List(opts v1.ListOptions) (result *v1.LimitRangeList, err error) { +func (c *limitRanges) List(opts meta_v1.ListOptions) (result *v1.LimitRangeList, err error) { result = &v1.LimitRangeList{} err = c.client.Get(). Namespace(c.ns). Resource("limitranges"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested limitRanges. -func (c *limitRanges) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *limitRanges) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("limitranges"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched limitRange. -func (c *limitRanges) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.LimitRange, err error) { +func (c *limitRanges) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.LimitRange, err error) { result = &v1.LimitRange{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/namespace.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/namespace.go index 3f1bd4f3fe..3092bd8e18 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/namespace.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/namespace.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type NamespaceInterface interface { Create(*v1.Namespace) (*v1.Namespace, error) Update(*v1.Namespace) (*v1.Namespace, error) UpdateStatus(*v1.Namespace) (*v1.Namespace, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Namespace, error) - List(opts v1.ListOptions) (*v1.NamespaceList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Namespace, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Namespace, error) + List(opts meta_v1.ListOptions) (*v1.NamespaceList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Namespace, err error) NamespaceExpansion } @@ -78,6 +80,9 @@ func (c *namespaces) Update(namespace *v1.Namespace) (result *v1.Namespace, err return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *namespaces) UpdateStatus(namespace *v1.Namespace) (result *v1.Namespace, err error) { result = &v1.Namespace{} err = c.client.Put(). @@ -91,7 +96,7 @@ func (c *namespaces) UpdateStatus(namespace *v1.Namespace) (result *v1.Namespace } // Delete takes name of the namespace and deletes it. Returns an error if one occurs. -func (c *namespaces) Delete(name string, options *v1.DeleteOptions) error { +func (c *namespaces) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Resource("namespaces"). Name(name). @@ -101,48 +106,49 @@ func (c *namespaces) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *namespaces) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *namespaces) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Resource("namespaces"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the namespace, and returns the corresponding namespace object, and an error if there is any. -func (c *namespaces) Get(name string) (result *v1.Namespace, err error) { +func (c *namespaces) Get(name string, options meta_v1.GetOptions) (result *v1.Namespace, err error) { result = &v1.Namespace{} err = c.client.Get(). Resource("namespaces"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Namespaces that match those selectors. -func (c *namespaces) List(opts v1.ListOptions) (result *v1.NamespaceList, err error) { +func (c *namespaces) List(opts meta_v1.ListOptions) (result *v1.NamespaceList, err error) { result = &v1.NamespaceList{} err = c.client.Get(). Resource("namespaces"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested namespaces. -func (c *namespaces) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *namespaces) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("namespaces"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched namespace. -func (c *namespaces) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Namespace, err error) { +func (c *namespaces) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Namespace, err error) { result = &v1.Namespace{} err = c.client.Patch(pt). Resource("namespaces"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node.go index 0f459a4a29..6b82d4fabd 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type NodeInterface interface { Create(*v1.Node) (*v1.Node, error) Update(*v1.Node) (*v1.Node, error) UpdateStatus(*v1.Node) (*v1.Node, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Node, error) - List(opts v1.ListOptions) (*v1.NodeList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Node, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Node, error) + List(opts meta_v1.ListOptions) (*v1.NodeList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Node, err error) NodeExpansion } @@ -78,6 +80,9 @@ func (c *nodes) Update(node *v1.Node) (result *v1.Node, err error) { return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *nodes) UpdateStatus(node *v1.Node) (result *v1.Node, err error) { result = &v1.Node{} err = c.client.Put(). @@ -91,7 +96,7 @@ func (c *nodes) UpdateStatus(node *v1.Node) (result *v1.Node, err error) { } // Delete takes name of the node and deletes it. Returns an error if one occurs. -func (c *nodes) Delete(name string, options *v1.DeleteOptions) error { +func (c *nodes) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Resource("nodes"). Name(name). @@ -101,48 +106,49 @@ func (c *nodes) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *nodes) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *nodes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Resource("nodes"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the node, and returns the corresponding node object, and an error if there is any. -func (c *nodes) Get(name string) (result *v1.Node, err error) { +func (c *nodes) Get(name string, options meta_v1.GetOptions) (result *v1.Node, err error) { result = &v1.Node{} err = c.client.Get(). Resource("nodes"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Nodes that match those selectors. -func (c *nodes) List(opts v1.ListOptions) (result *v1.NodeList, err error) { +func (c *nodes) List(opts meta_v1.ListOptions) (result *v1.NodeList, err error) { result = &v1.NodeList{} err = c.client.Get(). Resource("nodes"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested nodes. -func (c *nodes) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *nodes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("nodes"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched node. -func (c *nodes) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Node, err error) { +func (c *nodes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Node, err error) { result = &v1.Node{} err = c.client.Patch(pt). Resource("nodes"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node_expansion.go index 748b8c6afb..29c12aabcd 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/node_expansion.go @@ -17,7 +17,7 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api" + "k8s.io/apimachinery/pkg/types" "k8s.io/client-go/pkg/api/v1" ) @@ -32,7 +32,7 @@ type NodeExpansion interface { // the node that the server returns, or an error. func (c *nodes) PatchStatus(nodeName string, data []byte) (*v1.Node, error) { result := &v1.Node{} - err := c.client.Patch(api.StrategicMergePatchType). + err := c.client.Patch(types.StrategicMergePatchType). Resource("nodes"). Name(nodeName). SubResource("status"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolume.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolume.go index bfcafcba59..16a4b7316f 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolume.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolume.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type PersistentVolumeInterface interface { Create(*v1.PersistentVolume) (*v1.PersistentVolume, error) Update(*v1.PersistentVolume) (*v1.PersistentVolume, error) UpdateStatus(*v1.PersistentVolume) (*v1.PersistentVolume, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.PersistentVolume, error) - List(opts v1.ListOptions) (*v1.PersistentVolumeList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolume, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.PersistentVolume, error) + List(opts meta_v1.ListOptions) (*v1.PersistentVolumeList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolume, err error) PersistentVolumeExpansion } @@ -78,6 +80,9 @@ func (c *persistentVolumes) Update(persistentVolume *v1.PersistentVolume) (resul return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *persistentVolumes) UpdateStatus(persistentVolume *v1.PersistentVolume) (result *v1.PersistentVolume, err error) { result = &v1.PersistentVolume{} err = c.client.Put(). @@ -91,7 +96,7 @@ func (c *persistentVolumes) UpdateStatus(persistentVolume *v1.PersistentVolume) } // Delete takes name of the persistentVolume and deletes it. Returns an error if one occurs. -func (c *persistentVolumes) Delete(name string, options *v1.DeleteOptions) error { +func (c *persistentVolumes) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Resource("persistentvolumes"). Name(name). @@ -101,48 +106,49 @@ func (c *persistentVolumes) Delete(name string, options *v1.DeleteOptions) error } // DeleteCollection deletes a collection of objects. -func (c *persistentVolumes) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *persistentVolumes) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Resource("persistentvolumes"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the persistentVolume, and returns the corresponding persistentVolume object, and an error if there is any. -func (c *persistentVolumes) Get(name string) (result *v1.PersistentVolume, err error) { +func (c *persistentVolumes) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolume, err error) { result = &v1.PersistentVolume{} err = c.client.Get(). Resource("persistentvolumes"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of PersistentVolumes that match those selectors. -func (c *persistentVolumes) List(opts v1.ListOptions) (result *v1.PersistentVolumeList, err error) { +func (c *persistentVolumes) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeList, err error) { result = &v1.PersistentVolumeList{} err = c.client.Get(). Resource("persistentvolumes"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested persistentVolumes. -func (c *persistentVolumes) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *persistentVolumes) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("persistentvolumes"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched persistentVolume. -func (c *persistentVolumes) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolume, err error) { +func (c *persistentVolumes) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolume, err error) { result = &v1.PersistentVolume{} err = c.client.Patch(pt). Resource("persistentvolumes"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolumeclaim.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolumeclaim.go index ece0efc629..ae7cc4a4f4 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolumeclaim.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/persistentvolumeclaim.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type PersistentVolumeClaimInterface interface { Create(*v1.PersistentVolumeClaim) (*v1.PersistentVolumeClaim, error) Update(*v1.PersistentVolumeClaim) (*v1.PersistentVolumeClaim, error) UpdateStatus(*v1.PersistentVolumeClaim) (*v1.PersistentVolumeClaim, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.PersistentVolumeClaim, error) - List(opts v1.ListOptions) (*v1.PersistentVolumeClaimList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolumeClaim, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.PersistentVolumeClaim, error) + List(opts meta_v1.ListOptions) (*v1.PersistentVolumeClaimList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolumeClaim, err error) PersistentVolumeClaimExpansion } @@ -82,6 +84,9 @@ func (c *persistentVolumeClaims) Update(persistentVolumeClaim *v1.PersistentVolu return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *persistentVolumeClaims) UpdateStatus(persistentVolumeClaim *v1.PersistentVolumeClaim) (result *v1.PersistentVolumeClaim, err error) { result = &v1.PersistentVolumeClaim{} err = c.client.Put(). @@ -96,7 +101,7 @@ func (c *persistentVolumeClaims) UpdateStatus(persistentVolumeClaim *v1.Persiste } // Delete takes name of the persistentVolumeClaim and deletes it. Returns an error if one occurs. -func (c *persistentVolumeClaims) Delete(name string, options *v1.DeleteOptions) error { +func (c *persistentVolumeClaims) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("persistentvolumeclaims"). @@ -107,52 +112,53 @@ func (c *persistentVolumeClaims) Delete(name string, options *v1.DeleteOptions) } // DeleteCollection deletes a collection of objects. -func (c *persistentVolumeClaims) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *persistentVolumeClaims) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("persistentvolumeclaims"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the persistentVolumeClaim, and returns the corresponding persistentVolumeClaim object, and an error if there is any. -func (c *persistentVolumeClaims) Get(name string) (result *v1.PersistentVolumeClaim, err error) { +func (c *persistentVolumeClaims) Get(name string, options meta_v1.GetOptions) (result *v1.PersistentVolumeClaim, err error) { result = &v1.PersistentVolumeClaim{} err = c.client.Get(). Namespace(c.ns). Resource("persistentvolumeclaims"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of PersistentVolumeClaims that match those selectors. -func (c *persistentVolumeClaims) List(opts v1.ListOptions) (result *v1.PersistentVolumeClaimList, err error) { +func (c *persistentVolumeClaims) List(opts meta_v1.ListOptions) (result *v1.PersistentVolumeClaimList, err error) { result = &v1.PersistentVolumeClaimList{} err = c.client.Get(). Namespace(c.ns). Resource("persistentvolumeclaims"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested persistentVolumeClaims. -func (c *persistentVolumeClaims) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *persistentVolumeClaims) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("persistentvolumeclaims"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched persistentVolumeClaim. -func (c *persistentVolumeClaims) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolumeClaim, err error) { +func (c *persistentVolumeClaims) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PersistentVolumeClaim, err error) { result = &v1.PersistentVolumeClaim{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod.go index f5a171944d..5648750eaa 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type PodInterface interface { Create(*v1.Pod) (*v1.Pod, error) Update(*v1.Pod) (*v1.Pod, error) UpdateStatus(*v1.Pod) (*v1.Pod, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Pod, error) - List(opts v1.ListOptions) (*v1.PodList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Pod, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Pod, error) + List(opts meta_v1.ListOptions) (*v1.PodList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Pod, err error) PodExpansion } @@ -82,6 +84,9 @@ func (c *pods) Update(pod *v1.Pod) (result *v1.Pod, err error) { return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *pods) UpdateStatus(pod *v1.Pod) (result *v1.Pod, err error) { result = &v1.Pod{} err = c.client.Put(). @@ -96,7 +101,7 @@ func (c *pods) UpdateStatus(pod *v1.Pod) (result *v1.Pod, err error) { } // Delete takes name of the pod and deletes it. Returns an error if one occurs. -func (c *pods) Delete(name string, options *v1.DeleteOptions) error { +func (c *pods) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("pods"). @@ -107,52 +112,53 @@ func (c *pods) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *pods) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *pods) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("pods"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the pod, and returns the corresponding pod object, and an error if there is any. -func (c *pods) Get(name string) (result *v1.Pod, err error) { +func (c *pods) Get(name string, options meta_v1.GetOptions) (result *v1.Pod, err error) { result = &v1.Pod{} err = c.client.Get(). Namespace(c.ns). Resource("pods"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Pods that match those selectors. -func (c *pods) List(opts v1.ListOptions) (result *v1.PodList, err error) { +func (c *pods) List(opts meta_v1.ListOptions) (result *v1.PodList, err error) { result = &v1.PodList{} err = c.client.Get(). Namespace(c.ns). Resource("pods"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested pods. -func (c *pods) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *pods) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("pods"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched pod. -func (c *pods) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Pod, err error) { +func (c *pods) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Pod, err error) { result = &v1.Pod{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod_expansion.go index c54ba6a7af..3919289e55 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/pod_expansion.go @@ -17,17 +17,17 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api" + "k8s.io/client-go/kubernetes/scheme" "k8s.io/client-go/pkg/api/v1" policy "k8s.io/client-go/pkg/apis/policy/v1beta1" - "k8s.io/client-go/rest" + restclient "k8s.io/client-go/rest" ) // The PodExpansion interface allows manually adding extra methods to the PodInterface. type PodExpansion interface { Bind(binding *v1.Binding) error Evict(eviction *policy.Eviction) error - GetLogs(name string, opts *v1.PodLogOptions) *rest.Request + GetLogs(name string, opts *v1.PodLogOptions) *restclient.Request } // Bind applies the provided binding to the named pod in the current namespace (binding.Namespace is ignored). @@ -40,6 +40,6 @@ func (c *pods) Evict(eviction *policy.Eviction) error { } // Get constructs a request for getting the logs for a pod -func (c *pods) GetLogs(name string, opts *v1.PodLogOptions) *rest.Request { - return c.client.Get().Namespace(c.ns).Name(name).Resource("pods").SubResource("log").VersionedParams(opts, api.ParameterCodec) +func (c *pods) GetLogs(name string, opts *v1.PodLogOptions) *restclient.Request { + return c.client.Get().Namespace(c.ns).Name(name).Resource("pods").SubResource("log").VersionedParams(opts, scheme.ParameterCodec) } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/podtemplate.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/podtemplate.go index 419726b565..19c82f17b3 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/podtemplate.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/podtemplate.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type PodTemplatesGetter interface { type PodTemplateInterface interface { Create(*v1.PodTemplate) (*v1.PodTemplate, error) Update(*v1.PodTemplate) (*v1.PodTemplate, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.PodTemplate, error) - List(opts v1.ListOptions) (*v1.PodTemplateList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.PodTemplate, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.PodTemplate, error) + List(opts meta_v1.ListOptions) (*v1.PodTemplateList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PodTemplate, err error) PodTemplateExpansion } @@ -82,7 +84,7 @@ func (c *podTemplates) Update(podTemplate *v1.PodTemplate) (result *v1.PodTempla } // Delete takes name of the podTemplate and deletes it. Returns an error if one occurs. -func (c *podTemplates) Delete(name string, options *v1.DeleteOptions) error { +func (c *podTemplates) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("podtemplates"). @@ -93,52 +95,53 @@ func (c *podTemplates) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *podTemplates) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *podTemplates) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("podtemplates"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the podTemplate, and returns the corresponding podTemplate object, and an error if there is any. -func (c *podTemplates) Get(name string) (result *v1.PodTemplate, err error) { +func (c *podTemplates) Get(name string, options meta_v1.GetOptions) (result *v1.PodTemplate, err error) { result = &v1.PodTemplate{} err = c.client.Get(). Namespace(c.ns). Resource("podtemplates"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of PodTemplates that match those selectors. -func (c *podTemplates) List(opts v1.ListOptions) (result *v1.PodTemplateList, err error) { +func (c *podTemplates) List(opts meta_v1.ListOptions) (result *v1.PodTemplateList, err error) { result = &v1.PodTemplateList{} err = c.client.Get(). Namespace(c.ns). Resource("podtemplates"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested podTemplates. -func (c *podTemplates) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *podTemplates) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("podtemplates"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched podTemplate. -func (c *podTemplates) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.PodTemplate, err error) { +func (c *podTemplates) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.PodTemplate, err error) { result = &v1.PodTemplate{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/replicationcontroller.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/replicationcontroller.go index e9d7cc0cdb..2f4f4fa9e1 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/replicationcontroller.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/replicationcontroller.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type ReplicationControllerInterface interface { Create(*v1.ReplicationController) (*v1.ReplicationController, error) Update(*v1.ReplicationController) (*v1.ReplicationController, error) UpdateStatus(*v1.ReplicationController) (*v1.ReplicationController, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.ReplicationController, error) - List(opts v1.ListOptions) (*v1.ReplicationControllerList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ReplicationController, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.ReplicationController, error) + List(opts meta_v1.ListOptions) (*v1.ReplicationControllerList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ReplicationController, err error) ReplicationControllerExpansion } @@ -82,6 +84,9 @@ func (c *replicationControllers) Update(replicationController *v1.ReplicationCon return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *replicationControllers) UpdateStatus(replicationController *v1.ReplicationController) (result *v1.ReplicationController, err error) { result = &v1.ReplicationController{} err = c.client.Put(). @@ -96,7 +101,7 @@ func (c *replicationControllers) UpdateStatus(replicationController *v1.Replicat } // Delete takes name of the replicationController and deletes it. Returns an error if one occurs. -func (c *replicationControllers) Delete(name string, options *v1.DeleteOptions) error { +func (c *replicationControllers) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("replicationcontrollers"). @@ -107,52 +112,53 @@ func (c *replicationControllers) Delete(name string, options *v1.DeleteOptions) } // DeleteCollection deletes a collection of objects. -func (c *replicationControllers) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *replicationControllers) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("replicationcontrollers"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the replicationController, and returns the corresponding replicationController object, and an error if there is any. -func (c *replicationControllers) Get(name string) (result *v1.ReplicationController, err error) { +func (c *replicationControllers) Get(name string, options meta_v1.GetOptions) (result *v1.ReplicationController, err error) { result = &v1.ReplicationController{} err = c.client.Get(). Namespace(c.ns). Resource("replicationcontrollers"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of ReplicationControllers that match those selectors. -func (c *replicationControllers) List(opts v1.ListOptions) (result *v1.ReplicationControllerList, err error) { +func (c *replicationControllers) List(opts meta_v1.ListOptions) (result *v1.ReplicationControllerList, err error) { result = &v1.ReplicationControllerList{} err = c.client.Get(). Namespace(c.ns). Resource("replicationcontrollers"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested replicationControllers. -func (c *replicationControllers) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *replicationControllers) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("replicationcontrollers"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched replicationController. -func (c *replicationControllers) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ReplicationController, err error) { +func (c *replicationControllers) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ReplicationController, err error) { result = &v1.ReplicationController{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/resourcequota.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/resourcequota.go index 629a58d146..565fe1e6d6 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/resourcequota.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/resourcequota.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type ResourceQuotaInterface interface { Create(*v1.ResourceQuota) (*v1.ResourceQuota, error) Update(*v1.ResourceQuota) (*v1.ResourceQuota, error) UpdateStatus(*v1.ResourceQuota) (*v1.ResourceQuota, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.ResourceQuota, error) - List(opts v1.ListOptions) (*v1.ResourceQuotaList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ResourceQuota, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.ResourceQuota, error) + List(opts meta_v1.ListOptions) (*v1.ResourceQuotaList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ResourceQuota, err error) ResourceQuotaExpansion } @@ -82,6 +84,9 @@ func (c *resourceQuotas) Update(resourceQuota *v1.ResourceQuota) (result *v1.Res return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *resourceQuotas) UpdateStatus(resourceQuota *v1.ResourceQuota) (result *v1.ResourceQuota, err error) { result = &v1.ResourceQuota{} err = c.client.Put(). @@ -96,7 +101,7 @@ func (c *resourceQuotas) UpdateStatus(resourceQuota *v1.ResourceQuota) (result * } // Delete takes name of the resourceQuota and deletes it. Returns an error if one occurs. -func (c *resourceQuotas) Delete(name string, options *v1.DeleteOptions) error { +func (c *resourceQuotas) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("resourcequotas"). @@ -107,52 +112,53 @@ func (c *resourceQuotas) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *resourceQuotas) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *resourceQuotas) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("resourcequotas"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the resourceQuota, and returns the corresponding resourceQuota object, and an error if there is any. -func (c *resourceQuotas) Get(name string) (result *v1.ResourceQuota, err error) { +func (c *resourceQuotas) Get(name string, options meta_v1.GetOptions) (result *v1.ResourceQuota, err error) { result = &v1.ResourceQuota{} err = c.client.Get(). Namespace(c.ns). Resource("resourcequotas"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of ResourceQuotas that match those selectors. -func (c *resourceQuotas) List(opts v1.ListOptions) (result *v1.ResourceQuotaList, err error) { +func (c *resourceQuotas) List(opts meta_v1.ListOptions) (result *v1.ResourceQuotaList, err error) { result = &v1.ResourceQuotaList{} err = c.client.Get(). Namespace(c.ns). Resource("resourcequotas"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested resourceQuotas. -func (c *resourceQuotas) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *resourceQuotas) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("resourcequotas"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched resourceQuota. -func (c *resourceQuotas) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ResourceQuota, err error) { +func (c *resourceQuotas) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ResourceQuota, err error) { result = &v1.ResourceQuota{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/secret.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/secret.go index 96a0420ddf..fbcede8185 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/secret.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/secret.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type SecretsGetter interface { type SecretInterface interface { Create(*v1.Secret) (*v1.Secret, error) Update(*v1.Secret) (*v1.Secret, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Secret, error) - List(opts v1.ListOptions) (*v1.SecretList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Secret, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Secret, error) + List(opts meta_v1.ListOptions) (*v1.SecretList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Secret, err error) SecretExpansion } @@ -82,7 +84,7 @@ func (c *secrets) Update(secret *v1.Secret) (result *v1.Secret, err error) { } // Delete takes name of the secret and deletes it. Returns an error if one occurs. -func (c *secrets) Delete(name string, options *v1.DeleteOptions) error { +func (c *secrets) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("secrets"). @@ -93,52 +95,53 @@ func (c *secrets) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *secrets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *secrets) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("secrets"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the secret, and returns the corresponding secret object, and an error if there is any. -func (c *secrets) Get(name string) (result *v1.Secret, err error) { +func (c *secrets) Get(name string, options meta_v1.GetOptions) (result *v1.Secret, err error) { result = &v1.Secret{} err = c.client.Get(). Namespace(c.ns). Resource("secrets"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Secrets that match those selectors. -func (c *secrets) List(opts v1.ListOptions) (result *v1.SecretList, err error) { +func (c *secrets) List(opts meta_v1.ListOptions) (result *v1.SecretList, err error) { result = &v1.SecretList{} err = c.client.Get(). Namespace(c.ns). Resource("secrets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested secrets. -func (c *secrets) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *secrets) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("secrets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched secret. -func (c *secrets) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Secret, err error) { +func (c *secrets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Secret, err error) { result = &v1.Secret{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service.go index 7f40b79153..0eccf79a80 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -34,12 +36,12 @@ type ServiceInterface interface { Create(*v1.Service) (*v1.Service, error) Update(*v1.Service) (*v1.Service, error) UpdateStatus(*v1.Service) (*v1.Service, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.Service, error) - List(opts v1.ListOptions) (*v1.ServiceList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Service, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.Service, error) + List(opts meta_v1.ListOptions) (*v1.ServiceList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Service, err error) ServiceExpansion } @@ -82,6 +84,9 @@ func (c *services) Update(service *v1.Service) (result *v1.Service, err error) { return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *services) UpdateStatus(service *v1.Service) (result *v1.Service, err error) { result = &v1.Service{} err = c.client.Put(). @@ -96,7 +101,7 @@ func (c *services) UpdateStatus(service *v1.Service) (result *v1.Service, err er } // Delete takes name of the service and deletes it. Returns an error if one occurs. -func (c *services) Delete(name string, options *v1.DeleteOptions) error { +func (c *services) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("services"). @@ -107,52 +112,53 @@ func (c *services) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *services) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *services) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("services"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the service, and returns the corresponding service object, and an error if there is any. -func (c *services) Get(name string) (result *v1.Service, err error) { +func (c *services) Get(name string, options meta_v1.GetOptions) (result *v1.Service, err error) { result = &v1.Service{} err = c.client.Get(). Namespace(c.ns). Resource("services"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of Services that match those selectors. -func (c *services) List(opts v1.ListOptions) (result *v1.ServiceList, err error) { +func (c *services) List(opts meta_v1.ListOptions) (result *v1.ServiceList, err error) { result = &v1.ServiceList{} err = c.client.Get(). Namespace(c.ns). Resource("services"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested services. -func (c *services) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *services) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("services"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched service. -func (c *services) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.Service, err error) { +func (c *services) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.Service, err error) { result = &v1.Service{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service_expansion.go index 687589c26b..4937fd1a39 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/service_expansion.go @@ -17,21 +17,21 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/util/net" - "k8s.io/client-go/rest" + "k8s.io/apimachinery/pkg/util/net" + restclient "k8s.io/client-go/rest" ) // The ServiceExpansion interface allows manually adding extra methods to the ServiceInterface. type ServiceExpansion interface { - ProxyGet(scheme, name, port, path string, params map[string]string) rest.ResponseWrapper + ProxyGet(scheme, name, port, path string, params map[string]string) restclient.ResponseWrapper } // ProxyGet returns a response of the service by calling it through the proxy. -func (c *services) ProxyGet(scheme, name, port, path string, params map[string]string) rest.ResponseWrapper { +func (c *services) ProxyGet(scheme, name, port, path string, params map[string]string) restclient.ResponseWrapper { request := c.client.Get(). - Prefix("proxy"). Namespace(c.ns). Resource("services"). + SubResource("proxy"). Name(net.JoinSchemeNamePort(scheme, name, port)). Suffix(path) for k, v := range params { diff --git a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/serviceaccount.go b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/serviceaccount.go index 0af0c714b8..f71789f6ab 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/core/v1/serviceaccount.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/core/v1/serviceaccount.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,9 +17,11 @@ limitations under the License. package v1 import ( - api "k8s.io/client-go/pkg/api" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1 "k8s.io/client-go/pkg/api/v1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -33,12 +35,12 @@ type ServiceAccountsGetter interface { type ServiceAccountInterface interface { Create(*v1.ServiceAccount) (*v1.ServiceAccount, error) Update(*v1.ServiceAccount) (*v1.ServiceAccount, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1.ServiceAccount, error) - List(opts v1.ListOptions) (*v1.ServiceAccountList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ServiceAccount, err error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.ServiceAccount, error) + List(opts meta_v1.ListOptions) (*v1.ServiceAccountList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ServiceAccount, err error) ServiceAccountExpansion } @@ -82,7 +84,7 @@ func (c *serviceAccounts) Update(serviceAccount *v1.ServiceAccount) (result *v1. } // Delete takes name of the serviceAccount and deletes it. Returns an error if one occurs. -func (c *serviceAccounts) Delete(name string, options *v1.DeleteOptions) error { +func (c *serviceAccounts) Delete(name string, options *meta_v1.DeleteOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("serviceaccounts"). @@ -93,52 +95,53 @@ func (c *serviceAccounts) Delete(name string, options *v1.DeleteOptions) error { } // DeleteCollection deletes a collection of objects. -func (c *serviceAccounts) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { +func (c *serviceAccounts) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { return c.client.Delete(). Namespace(c.ns). Resource("serviceaccounts"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the serviceAccount, and returns the corresponding serviceAccount object, and an error if there is any. -func (c *serviceAccounts) Get(name string) (result *v1.ServiceAccount, err error) { +func (c *serviceAccounts) Get(name string, options meta_v1.GetOptions) (result *v1.ServiceAccount, err error) { result = &v1.ServiceAccount{} err = c.client.Get(). Namespace(c.ns). Resource("serviceaccounts"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return } // List takes label and field selectors, and returns the list of ServiceAccounts that match those selectors. -func (c *serviceAccounts) List(opts v1.ListOptions) (result *v1.ServiceAccountList, err error) { +func (c *serviceAccounts) List(opts meta_v1.ListOptions) (result *v1.ServiceAccountList, err error) { result = &v1.ServiceAccountList{} err = c.client.Get(). Namespace(c.ns). Resource("serviceaccounts"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return } // Watch returns a watch.Interface that watches the requested serviceAccounts. -func (c *serviceAccounts) Watch(opts v1.ListOptions) (watch.Interface, error) { +func (c *serviceAccounts) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("serviceaccounts"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched serviceAccount. -func (c *serviceAccounts) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1.ServiceAccount, err error) { +func (c *serviceAccounts) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.ServiceAccount, err error) { result = &v1.ServiceAccount{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/BUILD new file mode 100644 index 0000000000..53fd8f28dd --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/BUILD @@ -0,0 +1,38 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "daemonset.go", + "deployment.go", + "deployment_expansion.go", + "doc.go", + "extensions_client.go", + "generated_expansion.go", + "ingress.go", + "podsecuritypolicy.go", + "replicaset.go", + "scale.go", + "scale_expansion.go", + "thirdpartyresource.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/daemonset.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/daemonset.go index a562d1a9fd..8c132db9ba 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/daemonset.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/daemonset.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type DaemonSetInterface interface { UpdateStatus(*v1beta1.DaemonSet) (*v1beta1.DaemonSet, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.DaemonSet, error) + Get(name string, options v1.GetOptions) (*v1beta1.DaemonSet, error) List(opts v1.ListOptions) (*v1beta1.DaemonSetList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) DaemonSetExpansion } @@ -83,6 +84,9 @@ func (c *daemonSets) Update(daemonSet *v1beta1.DaemonSet) (result *v1beta1.Daemo return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *daemonSets) UpdateStatus(daemonSet *v1beta1.DaemonSet) (result *v1beta1.DaemonSet, err error) { result = &v1beta1.DaemonSet{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *daemonSets) DeleteCollection(options *v1.DeleteOptions, listOptions v1. return c.client.Delete(). Namespace(c.ns). Resource("daemonsets"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the daemonSet, and returns the corresponding daemonSet object, and an error if there is any. -func (c *daemonSets) Get(name string) (result *v1beta1.DaemonSet, err error) { +func (c *daemonSets) Get(name string, options v1.GetOptions) (result *v1beta1.DaemonSet, err error) { result = &v1beta1.DaemonSet{} err = c.client.Get(). Namespace(c.ns). Resource("daemonsets"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *daemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, e err = c.client.Get(). Namespace(c.ns). Resource("daemonsets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *daemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, e // Watch returns a watch.Interface that watches the requested daemonSets. func (c *daemonSets) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("daemonsets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched daemonSet. -func (c *daemonSets) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) { +func (c *daemonSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) { result = &v1beta1.DaemonSet{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/deployment.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/deployment.go index b31d43668d..7d0122c2ae 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/deployment.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/deployment.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type DeploymentInterface interface { UpdateStatus(*v1beta1.Deployment) (*v1beta1.Deployment, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.Deployment, error) + Get(name string, options v1.GetOptions) (*v1beta1.Deployment, error) List(opts v1.ListOptions) (*v1beta1.DeploymentList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) DeploymentExpansion } @@ -83,6 +84,9 @@ func (c *deployments) Update(deployment *v1beta1.Deployment) (result *v1beta1.De return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *deployments) UpdateStatus(deployment *v1beta1.Deployment) (result *v1beta1.Deployment, err error) { result = &v1beta1.Deployment{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *deployments) DeleteCollection(options *v1.DeleteOptions, listOptions v1 return c.client.Delete(). Namespace(c.ns). Resource("deployments"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the deployment, and returns the corresponding deployment object, and an error if there is any. -func (c *deployments) Get(name string) (result *v1beta1.Deployment, err error) { +func (c *deployments) Get(name string, options v1.GetOptions) (result *v1beta1.Deployment, err error) { result = &v1beta1.Deployment{} err = c.client.Get(). Namespace(c.ns). Resource("deployments"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, err = c.client.Get(). Namespace(c.ns). Resource("deployments"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *deployments) List(opts v1.ListOptions) (result *v1beta1.DeploymentList, // Watch returns a watch.Interface that watches the requested deployments. func (c *deployments) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("deployments"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched deployment. -func (c *deployments) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) { +func (c *deployments) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Deployment, err error) { result = &v1beta1.Deployment{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/doc.go index c15d0baccf..11b5238972 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/extensions_client.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/extensions_client.go index 6b90d4b76a..5284346e19 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/extensions_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/extensions_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1beta1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" rest "k8s.io/client-go/rest" ) @@ -30,14 +28,13 @@ type ExtensionsV1beta1Interface interface { DaemonSetsGetter DeploymentsGetter IngressesGetter - JobsGetter PodSecurityPoliciesGetter ReplicaSetsGetter ScalesGetter ThirdPartyResourcesGetter } -// ExtensionsV1beta1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// ExtensionsV1beta1Client is used to interact with features provided by the extensions group. type ExtensionsV1beta1Client struct { restClient rest.Interface } @@ -54,10 +51,6 @@ func (c *ExtensionsV1beta1Client) Ingresses(namespace string) IngressInterface { return newIngresses(c, namespace) } -func (c *ExtensionsV1beta1Client) Jobs(namespace string) JobInterface { - return newJobs(c, namespace) -} - func (c *ExtensionsV1beta1Client) PodSecurityPolicies() PodSecurityPolicyInterface { return newPodSecurityPolicies(c) } @@ -103,22 +96,14 @@ func New(c rest.Interface) *ExtensionsV1beta1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("extensions/v1beta1") - if err != nil { - return err - } - // if extensions/v1beta1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("extensions/v1beta1 is not enabled") - } + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/generated_expansion.go index 60cf61d4b2..d0a3d64bcf 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -20,8 +20,6 @@ type DaemonSetExpansion interface{} type IngressExpansion interface{} -type JobExpansion interface{} - type PodSecurityPolicyExpansion interface{} type ReplicaSetExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/ingress.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/ingress.go index 5864b1a07a..86bf65b8f5 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/ingress.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/ingress.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type IngressInterface interface { UpdateStatus(*v1beta1.Ingress) (*v1beta1.Ingress, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.Ingress, error) + Get(name string, options v1.GetOptions) (*v1beta1.Ingress, error) List(opts v1.ListOptions) (*v1beta1.IngressList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.Ingress, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Ingress, err error) IngressExpansion } @@ -83,6 +84,9 @@ func (c *ingresses) Update(ingress *v1beta1.Ingress) (result *v1beta1.Ingress, e return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *ingresses) UpdateStatus(ingress *v1beta1.Ingress) (result *v1beta1.Ingress, err error) { result = &v1beta1.Ingress{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *ingresses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.L return c.client.Delete(). Namespace(c.ns). Resource("ingresses"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the ingress, and returns the corresponding ingress object, and an error if there is any. -func (c *ingresses) Get(name string) (result *v1beta1.Ingress, err error) { +func (c *ingresses) Get(name string, options v1.GetOptions) (result *v1beta1.Ingress, err error) { result = &v1beta1.Ingress{} err = c.client.Get(). Namespace(c.ns). Resource("ingresses"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *ingresses) List(opts v1.ListOptions) (result *v1beta1.IngressList, err err = c.client.Get(). Namespace(c.ns). Resource("ingresses"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *ingresses) List(opts v1.ListOptions) (result *v1beta1.IngressList, err // Watch returns a watch.Interface that watches the requested ingresses. func (c *ingresses) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("ingresses"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched ingress. -func (c *ingresses) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.Ingress, err error) { +func (c *ingresses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Ingress, err error) { result = &v1beta1.Ingress{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/job.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/job.go deleted file mode 100644 index c27449bbfb..0000000000 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/job.go +++ /dev/null @@ -1,167 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1beta1 - -import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" - v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" - rest "k8s.io/client-go/rest" -) - -// JobsGetter has a method to return a JobInterface. -// A group's client should implement this interface. -type JobsGetter interface { - Jobs(namespace string) JobInterface -} - -// JobInterface has methods to work with Job resources. -type JobInterface interface { - Create(*v1beta1.Job) (*v1beta1.Job, error) - Update(*v1beta1.Job) (*v1beta1.Job, error) - UpdateStatus(*v1beta1.Job) (*v1beta1.Job, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.Job, error) - List(opts v1.ListOptions) (*v1beta1.JobList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.Job, err error) - JobExpansion -} - -// jobs implements JobInterface -type jobs struct { - client rest.Interface - ns string -} - -// newJobs returns a Jobs -func newJobs(c *ExtensionsV1beta1Client, namespace string) *jobs { - return &jobs{ - client: c.RESTClient(), - ns: namespace, - } -} - -// Create takes the representation of a job and creates it. Returns the server's representation of the job, and an error, if there is any. -func (c *jobs) Create(job *v1beta1.Job) (result *v1beta1.Job, err error) { - result = &v1beta1.Job{} - err = c.client.Post(). - Namespace(c.ns). - Resource("jobs"). - Body(job). - Do(). - Into(result) - return -} - -// Update takes the representation of a job and updates it. Returns the server's representation of the job, and an error, if there is any. -func (c *jobs) Update(job *v1beta1.Job) (result *v1beta1.Job, err error) { - result = &v1beta1.Job{} - err = c.client.Put(). - Namespace(c.ns). - Resource("jobs"). - Name(job.Name). - Body(job). - Do(). - Into(result) - return -} - -func (c *jobs) UpdateStatus(job *v1beta1.Job) (result *v1beta1.Job, err error) { - result = &v1beta1.Job{} - err = c.client.Put(). - Namespace(c.ns). - Resource("jobs"). - Name(job.Name). - SubResource("status"). - Body(job). - Do(). - Into(result) - return -} - -// Delete takes name of the job and deletes it. Returns an error if one occurs. -func (c *jobs) Delete(name string, options *v1.DeleteOptions) error { - return c.client.Delete(). - Namespace(c.ns). - Resource("jobs"). - Name(name). - Body(options). - Do(). - Error() -} - -// DeleteCollection deletes a collection of objects. -func (c *jobs) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { - return c.client.Delete(). - Namespace(c.ns). - Resource("jobs"). - VersionedParams(&listOptions, api.ParameterCodec). - Body(options). - Do(). - Error() -} - -// Get takes name of the job, and returns the corresponding job object, and an error if there is any. -func (c *jobs) Get(name string) (result *v1beta1.Job, err error) { - result = &v1beta1.Job{} - err = c.client.Get(). - Namespace(c.ns). - Resource("jobs"). - Name(name). - Do(). - Into(result) - return -} - -// List takes label and field selectors, and returns the list of Jobs that match those selectors. -func (c *jobs) List(opts v1.ListOptions) (result *v1beta1.JobList, err error) { - result = &v1beta1.JobList{} - err = c.client.Get(). - Namespace(c.ns). - Resource("jobs"). - VersionedParams(&opts, api.ParameterCodec). - Do(). - Into(result) - return -} - -// Watch returns a watch.Interface that watches the requested jobs. -func (c *jobs) Watch(opts v1.ListOptions) (watch.Interface, error) { - return c.client.Get(). - Prefix("watch"). - Namespace(c.ns). - Resource("jobs"). - VersionedParams(&opts, api.ParameterCodec). - Watch() -} - -// Patch applies the patch and returns the patched job. -func (c *jobs) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.Job, err error) { - result = &v1beta1.Job{} - err = c.client.Patch(pt). - Namespace(c.ns). - Resource("jobs"). - SubResource(subresources...). - Name(name). - Body(data). - Do(). - Into(result) - return -} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/podsecuritypolicy.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/podsecuritypolicy.go index c691415d3f..ad57a6cabf 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/podsecuritypolicy.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/podsecuritypolicy.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type PodSecurityPolicyInterface interface { Update(*v1beta1.PodSecurityPolicy) (*v1beta1.PodSecurityPolicy, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.PodSecurityPolicy, error) + Get(name string, options v1.GetOptions) (*v1beta1.PodSecurityPolicy, error) List(opts v1.ListOptions) (*v1beta1.PodSecurityPolicyList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.PodSecurityPolicy, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodSecurityPolicy, err error) PodSecurityPolicyExpansion } @@ -92,18 +93,19 @@ func (c *podSecurityPolicies) Delete(name string, options *v1.DeleteOptions) err func (c *podSecurityPolicies) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { return c.client.Delete(). Resource("podsecuritypolicies"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the podSecurityPolicy, and returns the corresponding podSecurityPolicy object, and an error if there is any. -func (c *podSecurityPolicies) Get(name string) (result *v1beta1.PodSecurityPolicy, err error) { +func (c *podSecurityPolicies) Get(name string, options v1.GetOptions) (result *v1beta1.PodSecurityPolicy, err error) { result = &v1beta1.PodSecurityPolicy{} err = c.client.Get(). Resource("podsecuritypolicies"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -114,7 +116,7 @@ func (c *podSecurityPolicies) List(opts v1.ListOptions) (result *v1beta1.PodSecu result = &v1beta1.PodSecurityPolicyList{} err = c.client.Get(). Resource("podsecuritypolicies"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -122,15 +124,15 @@ func (c *podSecurityPolicies) List(opts v1.ListOptions) (result *v1beta1.PodSecu // Watch returns a watch.Interface that watches the requested podSecurityPolicies. func (c *podSecurityPolicies) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("podsecuritypolicies"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched podSecurityPolicy. -func (c *podSecurityPolicies) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.PodSecurityPolicy, err error) { +func (c *podSecurityPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodSecurityPolicy, err error) { result = &v1beta1.PodSecurityPolicy{} err = c.client.Patch(pt). Resource("podsecuritypolicies"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/replicaset.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/replicaset.go index d51b990f1f..aa6f505a2b 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/replicaset.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/replicaset.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type ReplicaSetInterface interface { UpdateStatus(*v1beta1.ReplicaSet) (*v1beta1.ReplicaSet, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.ReplicaSet, error) + Get(name string, options v1.GetOptions) (*v1beta1.ReplicaSet, error) List(opts v1.ListOptions) (*v1beta1.ReplicaSetList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.ReplicaSet, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ReplicaSet, err error) ReplicaSetExpansion } @@ -83,6 +84,9 @@ func (c *replicaSets) Update(replicaSet *v1beta1.ReplicaSet) (result *v1beta1.Re return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *replicaSets) UpdateStatus(replicaSet *v1beta1.ReplicaSet) (result *v1beta1.ReplicaSet, err error) { result = &v1beta1.ReplicaSet{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *replicaSets) DeleteCollection(options *v1.DeleteOptions, listOptions v1 return c.client.Delete(). Namespace(c.ns). Resource("replicasets"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the replicaSet, and returns the corresponding replicaSet object, and an error if there is any. -func (c *replicaSets) Get(name string) (result *v1beta1.ReplicaSet, err error) { +func (c *replicaSets) Get(name string, options v1.GetOptions) (result *v1beta1.ReplicaSet, err error) { result = &v1beta1.ReplicaSet{} err = c.client.Get(). Namespace(c.ns). Resource("replicasets"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *replicaSets) List(opts v1.ListOptions) (result *v1beta1.ReplicaSetList, err = c.client.Get(). Namespace(c.ns). Resource("replicasets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *replicaSets) List(opts v1.ListOptions) (result *v1beta1.ReplicaSetList, // Watch returns a watch.Interface that watches the requested replicaSets. func (c *replicaSets) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("replicasets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched replicaSet. -func (c *replicaSets) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.ReplicaSet, err error) { +func (c *replicaSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ReplicaSet, err error) { result = &v1beta1.ReplicaSet{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale.go index 87c7837760..733012adee 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale_expansion.go index 08421dc45e..85d7c40a8b 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/scale_expansion.go @@ -17,8 +17,8 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/client-go/pkg/apis/extensions/v1beta1" ) @@ -33,8 +33,8 @@ func (c *scales) Get(kind string, name string) (result *v1beta1.Scale, err error result = &v1beta1.Scale{} // TODO this method needs to take a proper unambiguous kind - fullyQualifiedKind := unversioned.GroupVersionKind{Kind: kind} - resource, _ := meta.KindToResource(fullyQualifiedKind) + fullyQualifiedKind := schema.GroupVersionKind{Kind: kind} + resource, _ := meta.UnsafeGuessKindToResource(fullyQualifiedKind) err = c.client.Get(). Namespace(c.ns). @@ -50,8 +50,8 @@ func (c *scales) Update(kind string, scale *v1beta1.Scale) (result *v1beta1.Scal result = &v1beta1.Scale{} // TODO this method needs to take a proper unambiguous kind - fullyQualifiedKind := unversioned.GroupVersionKind{Kind: kind} - resource, _ := meta.KindToResource(fullyQualifiedKind) + fullyQualifiedKind := schema.GroupVersionKind{Kind: kind} + resource, _ := meta.UnsafeGuessKindToResource(fullyQualifiedKind) err = c.client.Put(). Namespace(scale.Namespace). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/thirdpartyresource.go b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/thirdpartyresource.go index 935f2abd9f..617c2069be 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/thirdpartyresource.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/extensions/v1beta1/thirdpartyresource.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/extensions/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type ThirdPartyResourceInterface interface { Update(*v1beta1.ThirdPartyResource) (*v1beta1.ThirdPartyResource, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.ThirdPartyResource, error) + Get(name string, options v1.GetOptions) (*v1beta1.ThirdPartyResource, error) List(opts v1.ListOptions) (*v1beta1.ThirdPartyResourceList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.ThirdPartyResource, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ThirdPartyResource, err error) ThirdPartyResourceExpansion } @@ -92,18 +93,19 @@ func (c *thirdPartyResources) Delete(name string, options *v1.DeleteOptions) err func (c *thirdPartyResources) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { return c.client.Delete(). Resource("thirdpartyresources"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the thirdPartyResource, and returns the corresponding thirdPartyResource object, and an error if there is any. -func (c *thirdPartyResources) Get(name string) (result *v1beta1.ThirdPartyResource, err error) { +func (c *thirdPartyResources) Get(name string, options v1.GetOptions) (result *v1beta1.ThirdPartyResource, err error) { result = &v1beta1.ThirdPartyResource{} err = c.client.Get(). Resource("thirdpartyresources"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -114,7 +116,7 @@ func (c *thirdPartyResources) List(opts v1.ListOptions) (result *v1beta1.ThirdPa result = &v1beta1.ThirdPartyResourceList{} err = c.client.Get(). Resource("thirdpartyresources"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -122,15 +124,15 @@ func (c *thirdPartyResources) List(opts v1.ListOptions) (result *v1beta1.ThirdPa // Watch returns a watch.Interface that watches the requested thirdPartyResources. func (c *thirdPartyResources) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("thirdpartyresources"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched thirdPartyResource. -func (c *thirdPartyResources) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.ThirdPartyResource, err error) { +func (c *thirdPartyResources) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ThirdPartyResource, err error) { result = &v1beta1.ThirdPartyResource{} err = c.client.Patch(pt). Resource("thirdpartyresources"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD new file mode 100644 index 0000000000..49ce9f31b0 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "networking_client.go", + "networkpolicy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go new file mode 100644 index 0000000000..54673bfa73 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go new file mode 100644 index 0000000000..cdd70ae353 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +type NetworkPolicyExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go new file mode 100644 index 0000000000..20429dd5d7 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networking_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/networking/v1" + rest "k8s.io/client-go/rest" +) + +type NetworkingV1Interface interface { + RESTClient() rest.Interface + NetworkPoliciesGetter +} + +// NetworkingV1Client is used to interact with features provided by the networking.k8s.io group. +type NetworkingV1Client struct { + restClient rest.Interface +} + +func (c *NetworkingV1Client) NetworkPolicies(namespace string) NetworkPolicyInterface { + return newNetworkPolicies(c, namespace) +} + +// NewForConfig creates a new NetworkingV1Client for the given config. +func NewForConfig(c *rest.Config) (*NetworkingV1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &NetworkingV1Client{client}, nil +} + +// NewForConfigOrDie creates a new NetworkingV1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *NetworkingV1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new NetworkingV1Client for the given RESTClient. +func New(c rest.Interface) *NetworkingV1Client { + return &NetworkingV1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *NetworkingV1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go new file mode 100644 index 0000000000..14d1e669b1 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/networking/v1/networkpolicy.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/networking/v1" + rest "k8s.io/client-go/rest" +) + +// NetworkPoliciesGetter has a method to return a NetworkPolicyInterface. +// A group's client should implement this interface. +type NetworkPoliciesGetter interface { + NetworkPolicies(namespace string) NetworkPolicyInterface +} + +// NetworkPolicyInterface has methods to work with NetworkPolicy resources. +type NetworkPolicyInterface interface { + Create(*v1.NetworkPolicy) (*v1.NetworkPolicy, error) + Update(*v1.NetworkPolicy) (*v1.NetworkPolicy, error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.NetworkPolicy, error) + List(opts meta_v1.ListOptions) (*v1.NetworkPolicyList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) + NetworkPolicyExpansion +} + +// networkPolicies implements NetworkPolicyInterface +type networkPolicies struct { + client rest.Interface + ns string +} + +// newNetworkPolicies returns a NetworkPolicies +func newNetworkPolicies(c *NetworkingV1Client, namespace string) *networkPolicies { + return &networkPolicies{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a networkPolicy and creates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Create(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Post(). + Namespace(c.ns). + Resource("networkpolicies"). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Update takes the representation of a networkPolicy and updates it. Returns the server's representation of the networkPolicy, and an error, if there is any. +func (c *networkPolicies) Update(networkPolicy *v1.NetworkPolicy) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Put(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(networkPolicy.Name). + Body(networkPolicy). + Do(). + Into(result) + return +} + +// Delete takes name of the networkPolicy and deletes it. Returns an error if one occurs. +func (c *networkPolicies) Delete(name string, options *meta_v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *networkPolicies) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the networkPolicy, and returns the corresponding networkPolicy object, and an error if there is any. +func (c *networkPolicies) Get(name string, options meta_v1.GetOptions) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of NetworkPolicies that match those selectors. +func (c *networkPolicies) List(opts meta_v1.ListOptions) (result *v1.NetworkPolicyList, err error) { + result = &v1.NetworkPolicyList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested networkPolicies. +func (c *networkPolicies) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("networkpolicies"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched networkPolicy. +func (c *networkPolicies) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.NetworkPolicy, err error) { + result = &v1.NetworkPolicy{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("networkpolicies"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/poddisruptionbudget.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/poddisruptionbudget.go deleted file mode 100644 index 2d02a10113..0000000000 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/poddisruptionbudget.go +++ /dev/null @@ -1,167 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" - v1alpha1 "k8s.io/client-go/pkg/apis/policy/v1alpha1" - watch "k8s.io/client-go/pkg/watch" - rest "k8s.io/client-go/rest" -) - -// PodDisruptionBudgetsGetter has a method to return a PodDisruptionBudgetInterface. -// A group's client should implement this interface. -type PodDisruptionBudgetsGetter interface { - PodDisruptionBudgets(namespace string) PodDisruptionBudgetInterface -} - -// PodDisruptionBudgetInterface has methods to work with PodDisruptionBudget resources. -type PodDisruptionBudgetInterface interface { - Create(*v1alpha1.PodDisruptionBudget) (*v1alpha1.PodDisruptionBudget, error) - Update(*v1alpha1.PodDisruptionBudget) (*v1alpha1.PodDisruptionBudget, error) - UpdateStatus(*v1alpha1.PodDisruptionBudget) (*v1alpha1.PodDisruptionBudget, error) - Delete(name string, options *v1.DeleteOptions) error - DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1alpha1.PodDisruptionBudget, error) - List(opts v1.ListOptions) (*v1alpha1.PodDisruptionBudgetList, error) - Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.PodDisruptionBudget, err error) - PodDisruptionBudgetExpansion -} - -// podDisruptionBudgets implements PodDisruptionBudgetInterface -type podDisruptionBudgets struct { - client rest.Interface - ns string -} - -// newPodDisruptionBudgets returns a PodDisruptionBudgets -func newPodDisruptionBudgets(c *PolicyV1alpha1Client, namespace string) *podDisruptionBudgets { - return &podDisruptionBudgets{ - client: c.RESTClient(), - ns: namespace, - } -} - -// Create takes the representation of a podDisruptionBudget and creates it. Returns the server's representation of the podDisruptionBudget, and an error, if there is any. -func (c *podDisruptionBudgets) Create(podDisruptionBudget *v1alpha1.PodDisruptionBudget) (result *v1alpha1.PodDisruptionBudget, err error) { - result = &v1alpha1.PodDisruptionBudget{} - err = c.client.Post(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - Body(podDisruptionBudget). - Do(). - Into(result) - return -} - -// Update takes the representation of a podDisruptionBudget and updates it. Returns the server's representation of the podDisruptionBudget, and an error, if there is any. -func (c *podDisruptionBudgets) Update(podDisruptionBudget *v1alpha1.PodDisruptionBudget) (result *v1alpha1.PodDisruptionBudget, err error) { - result = &v1alpha1.PodDisruptionBudget{} - err = c.client.Put(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - Name(podDisruptionBudget.Name). - Body(podDisruptionBudget). - Do(). - Into(result) - return -} - -func (c *podDisruptionBudgets) UpdateStatus(podDisruptionBudget *v1alpha1.PodDisruptionBudget) (result *v1alpha1.PodDisruptionBudget, err error) { - result = &v1alpha1.PodDisruptionBudget{} - err = c.client.Put(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - Name(podDisruptionBudget.Name). - SubResource("status"). - Body(podDisruptionBudget). - Do(). - Into(result) - return -} - -// Delete takes name of the podDisruptionBudget and deletes it. Returns an error if one occurs. -func (c *podDisruptionBudgets) Delete(name string, options *v1.DeleteOptions) error { - return c.client.Delete(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - Name(name). - Body(options). - Do(). - Error() -} - -// DeleteCollection deletes a collection of objects. -func (c *podDisruptionBudgets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { - return c.client.Delete(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - VersionedParams(&listOptions, api.ParameterCodec). - Body(options). - Do(). - Error() -} - -// Get takes name of the podDisruptionBudget, and returns the corresponding podDisruptionBudget object, and an error if there is any. -func (c *podDisruptionBudgets) Get(name string) (result *v1alpha1.PodDisruptionBudget, err error) { - result = &v1alpha1.PodDisruptionBudget{} - err = c.client.Get(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - Name(name). - Do(). - Into(result) - return -} - -// List takes label and field selectors, and returns the list of PodDisruptionBudgets that match those selectors. -func (c *podDisruptionBudgets) List(opts v1.ListOptions) (result *v1alpha1.PodDisruptionBudgetList, err error) { - result = &v1alpha1.PodDisruptionBudgetList{} - err = c.client.Get(). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - VersionedParams(&opts, api.ParameterCodec). - Do(). - Into(result) - return -} - -// Watch returns a watch.Interface that watches the requested podDisruptionBudgets. -func (c *podDisruptionBudgets) Watch(opts v1.ListOptions) (watch.Interface, error) { - return c.client.Get(). - Prefix("watch"). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - VersionedParams(&opts, api.ParameterCodec). - Watch() -} - -// Patch applies the patch and returns the patched podDisruptionBudget. -func (c *podDisruptionBudgets) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.PodDisruptionBudget, err error) { - result = &v1alpha1.PodDisruptionBudget{} - err = c.client.Patch(pt). - Namespace(c.ns). - Resource("poddisruptionbudgets"). - SubResource(subresources...). - Name(name). - Body(data). - Do(). - Into(result) - return -} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/policy_client.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/policy_client.go deleted file mode 100644 index 4f1b535dcc..0000000000 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/policy_client.go +++ /dev/null @@ -1,98 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" - rest "k8s.io/client-go/rest" -) - -type PolicyV1alpha1Interface interface { - RESTClient() rest.Interface - PodDisruptionBudgetsGetter -} - -// PolicyV1alpha1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. -type PolicyV1alpha1Client struct { - restClient rest.Interface -} - -func (c *PolicyV1alpha1Client) PodDisruptionBudgets(namespace string) PodDisruptionBudgetInterface { - return newPodDisruptionBudgets(c, namespace) -} - -// NewForConfig creates a new PolicyV1alpha1Client for the given config. -func NewForConfig(c *rest.Config) (*PolicyV1alpha1Client, error) { - config := *c - if err := setConfigDefaults(&config); err != nil { - return nil, err - } - client, err := rest.RESTClientFor(&config) - if err != nil { - return nil, err - } - return &PolicyV1alpha1Client{client}, nil -} - -// NewForConfigOrDie creates a new PolicyV1alpha1Client for the given config and -// panics if there is an error in the config. -func NewForConfigOrDie(c *rest.Config) *PolicyV1alpha1Client { - client, err := NewForConfig(c) - if err != nil { - panic(err) - } - return client -} - -// New creates a new PolicyV1alpha1Client for the given RESTClient. -func New(c rest.Interface) *PolicyV1alpha1Client { - return &PolicyV1alpha1Client{c} -} - -func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("policy/v1alpha1") - if err != nil { - return err - } - // if policy/v1alpha1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("policy/v1alpha1 is not enabled") - } - config.APIPath = "/apis" - if config.UserAgent == "" { - config.UserAgent = rest.DefaultKubernetesUserAgent() - } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} - - return nil -} - -// RESTClient returns a RESTClient that is used to communicate -// with API server by this client implementation. -func (c *PolicyV1alpha1Client) RESTClient() rest.Interface { - if c == nil { - return nil - } - return c.restClient -} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/BUILD new file mode 100644 index 0000000000..ed70f8c88d --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/BUILD @@ -0,0 +1,30 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "eviction.go", + "eviction_expansion.go", + "generated_expansion.go", + "poddisruptionbudget.go", + "policy_client.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/policy/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/doc.go index c15d0baccf..11b5238972 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction.go new file mode 100644 index 0000000000..9c4133e369 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction.go @@ -0,0 +1,46 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + rest "k8s.io/client-go/rest" +) + +// EvictionsGetter has a method to return a EvictionInterface. +// A group's client should implement this interface. +type EvictionsGetter interface { + Evictions(namespace string) EvictionInterface +} + +// EvictionInterface has methods to work with Eviction resources. +type EvictionInterface interface { + EvictionExpansion +} + +// evictions implements EvictionInterface +type evictions struct { + client rest.Interface + ns string +} + +// newEvictions returns a Evictions +func newEvictions(c *PolicyV1beta1Client, namespace string) *evictions { + return &evictions{ + client: c.RESTClient(), + ns: namespace, + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction_expansion.go new file mode 100644 index 0000000000..bde1baca6e --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/eviction_expansion.go @@ -0,0 +1,38 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + policy "k8s.io/client-go/pkg/apis/policy/v1beta1" +) + +// The EvictionExpansion interface allows manually adding extra methods to the ScaleInterface. +type EvictionExpansion interface { + Evict(eviction *policy.Eviction) error +} + +func (c *evictions) Evict(eviction *policy.Eviction) error { + return c.client.Post(). + AbsPath("/api/v1"). + Namespace(eviction.Namespace). + Resource("pods"). + Name(eviction.Name). + SubResource("eviction"). + Body(eviction). + Do(). + Error() +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/generated_expansion.go index 33896c65b9..511adc6ef7 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/poddisruptionbudget.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/poddisruptionbudget.go index 7c8d69785b..8088dd0196 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/poddisruptionbudget.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/poddisruptionbudget.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/policy/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -37,10 +38,10 @@ type PodDisruptionBudgetInterface interface { UpdateStatus(*v1beta1.PodDisruptionBudget) (*v1beta1.PodDisruptionBudget, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.PodDisruptionBudget, error) + Get(name string, options v1.GetOptions) (*v1beta1.PodDisruptionBudget, error) List(opts v1.ListOptions) (*v1beta1.PodDisruptionBudgetList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.PodDisruptionBudget, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodDisruptionBudget, err error) PodDisruptionBudgetExpansion } @@ -83,6 +84,9 @@ func (c *podDisruptionBudgets) Update(podDisruptionBudget *v1beta1.PodDisruption return } +// UpdateStatus was generated because the type contains a Status member. +// Add a +genclientstatus=false comment above the type to avoid generating UpdateStatus(). + func (c *podDisruptionBudgets) UpdateStatus(podDisruptionBudget *v1beta1.PodDisruptionBudget) (result *v1beta1.PodDisruptionBudget, err error) { result = &v1beta1.PodDisruptionBudget{} err = c.client.Put(). @@ -112,19 +116,20 @@ func (c *podDisruptionBudgets) DeleteCollection(options *v1.DeleteOptions, listO return c.client.Delete(). Namespace(c.ns). Resource("poddisruptionbudgets"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the podDisruptionBudget, and returns the corresponding podDisruptionBudget object, and an error if there is any. -func (c *podDisruptionBudgets) Get(name string) (result *v1beta1.PodDisruptionBudget, err error) { +func (c *podDisruptionBudgets) Get(name string, options v1.GetOptions) (result *v1beta1.PodDisruptionBudget, err error) { result = &v1beta1.PodDisruptionBudget{} err = c.client.Get(). Namespace(c.ns). Resource("poddisruptionbudgets"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -136,7 +141,7 @@ func (c *podDisruptionBudgets) List(opts v1.ListOptions) (result *v1beta1.PodDis err = c.client.Get(). Namespace(c.ns). Resource("poddisruptionbudgets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -144,16 +149,16 @@ func (c *podDisruptionBudgets) List(opts v1.ListOptions) (result *v1beta1.PodDis // Watch returns a watch.Interface that watches the requested podDisruptionBudgets. func (c *podDisruptionBudgets) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("poddisruptionbudgets"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched podDisruptionBudget. -func (c *podDisruptionBudgets) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.PodDisruptionBudget, err error) { +func (c *podDisruptionBudgets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.PodDisruptionBudget, err error) { result = &v1beta1.PodDisruptionBudget{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/policy_client.go b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/policy_client.go index a2605d472d..9d62aad04e 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/policy_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/policy/v1beta1/policy_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,24 +17,27 @@ limitations under the License. package v1beta1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/policy/v1beta1" rest "k8s.io/client-go/rest" ) type PolicyV1beta1Interface interface { RESTClient() rest.Interface + EvictionsGetter PodDisruptionBudgetsGetter } -// PolicyV1beta1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// PolicyV1beta1Client is used to interact with features provided by the policy group. type PolicyV1beta1Client struct { restClient rest.Interface } +func (c *PolicyV1beta1Client) Evictions(namespace string) EvictionInterface { + return newEvictions(c, namespace) +} + func (c *PolicyV1beta1Client) PodDisruptionBudgets(namespace string) PodDisruptionBudgetInterface { return newPodDisruptionBudgets(c, namespace) } @@ -68,22 +71,14 @@ func New(c rest.Interface) *PolicyV1beta1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("policy/v1beta1") - if err != nil { - return err - } - // if policy/v1beta1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("policy/v1beta1 is not enabled") - } + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/BUILD new file mode 100644 index 0000000000..9c1b627160 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "clusterrole.go", + "clusterrolebinding.go", + "doc.go", + "generated_expansion.go", + "rbac_client.go", + "role.go", + "rolebinding.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrole.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrole.go index 09d96c91f0..241061025a 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrole.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrole.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1alpha1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type ClusterRoleInterface interface { Update(*v1alpha1.ClusterRole) (*v1alpha1.ClusterRole, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1alpha1.ClusterRole, error) + Get(name string, options v1.GetOptions) (*v1alpha1.ClusterRole, error) List(opts v1.ListOptions) (*v1alpha1.ClusterRoleList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRole, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRole, err error) ClusterRoleExpansion } @@ -92,18 +93,19 @@ func (c *clusterRoles) Delete(name string, options *v1.DeleteOptions) error { func (c *clusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { return c.client.Delete(). Resource("clusterroles"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the clusterRole, and returns the corresponding clusterRole object, and an error if there is any. -func (c *clusterRoles) Get(name string) (result *v1alpha1.ClusterRole, err error) { +func (c *clusterRoles) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRole, err error) { result = &v1alpha1.ClusterRole{} err = c.client.Get(). Resource("clusterroles"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -114,7 +116,7 @@ func (c *clusterRoles) List(opts v1.ListOptions) (result *v1alpha1.ClusterRoleLi result = &v1alpha1.ClusterRoleList{} err = c.client.Get(). Resource("clusterroles"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -122,15 +124,15 @@ func (c *clusterRoles) List(opts v1.ListOptions) (result *v1alpha1.ClusterRoleLi // Watch returns a watch.Interface that watches the requested clusterRoles. func (c *clusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("clusterroles"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched clusterRole. -func (c *clusterRoles) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRole, err error) { +func (c *clusterRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRole, err error) { result = &v1alpha1.ClusterRole{} err = c.client.Patch(pt). Resource("clusterroles"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrolebinding.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrolebinding.go index a1ce7c0bdc..bc48873a59 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrolebinding.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/clusterrolebinding.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1alpha1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type ClusterRoleBindingInterface interface { Update(*v1alpha1.ClusterRoleBinding) (*v1alpha1.ClusterRoleBinding, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1alpha1.ClusterRoleBinding, error) + Get(name string, options v1.GetOptions) (*v1alpha1.ClusterRoleBinding, error) List(opts v1.ListOptions) (*v1alpha1.ClusterRoleBindingList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRoleBinding, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRoleBinding, err error) ClusterRoleBindingExpansion } @@ -92,18 +93,19 @@ func (c *clusterRoleBindings) Delete(name string, options *v1.DeleteOptions) err func (c *clusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { return c.client.Delete(). Resource("clusterrolebindings"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the clusterRoleBinding, and returns the corresponding clusterRoleBinding object, and an error if there is any. -func (c *clusterRoleBindings) Get(name string) (result *v1alpha1.ClusterRoleBinding, err error) { +func (c *clusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.ClusterRoleBinding, err error) { result = &v1alpha1.ClusterRoleBinding{} err = c.client.Get(). Resource("clusterrolebindings"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -114,7 +116,7 @@ func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1alpha1.Cluste result = &v1alpha1.ClusterRoleBindingList{} err = c.client.Get(). Resource("clusterrolebindings"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -122,15 +124,15 @@ func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1alpha1.Cluste // Watch returns a watch.Interface that watches the requested clusterRoleBindings. func (c *clusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("clusterrolebindings"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched clusterRoleBinding. -func (c *clusterRoleBindings) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRoleBinding, err error) { +func (c *clusterRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.ClusterRoleBinding, err error) { result = &v1alpha1.ClusterRoleBinding{} err = c.client.Patch(pt). Resource("clusterrolebindings"). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/doc.go index 4ca4e887ae..ba8d10d3b6 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1alpha1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/generated_expansion.go index 86def26631..f506fc3468 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rbac_client.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rbac_client.go index 7dbb9f2dbe..67256d50f5 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rbac_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rbac_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1alpha1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" rest "k8s.io/client-go/rest" ) @@ -33,7 +31,7 @@ type RbacV1alpha1Interface interface { RoleBindingsGetter } -// RbacV1alpha1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// RbacV1alpha1Client is used to interact with features provided by the rbac.authorization.k8s.io group. type RbacV1alpha1Client struct { restClient rest.Interface } @@ -83,22 +81,14 @@ func New(c rest.Interface) *RbacV1alpha1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("rbac.authorization.k8s.io/v1alpha1") - if err != nil { - return err - } - // if rbac.authorization.k8s.io/v1alpha1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("rbac.authorization.k8s.io/v1alpha1 is not enabled") - } + gv := v1alpha1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/role.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/role.go index b5939664e4..9c4fa915eb 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/role.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/role.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1alpha1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type RoleInterface interface { Update(*v1alpha1.Role) (*v1alpha1.Role, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1alpha1.Role, error) + Get(name string, options v1.GetOptions) (*v1alpha1.Role, error) List(opts v1.ListOptions) (*v1alpha1.RoleList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.Role, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.Role, err error) RoleExpansion } @@ -98,19 +99,20 @@ func (c *roles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListO return c.client.Delete(). Namespace(c.ns). Resource("roles"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the role, and returns the corresponding role object, and an error if there is any. -func (c *roles) Get(name string) (result *v1alpha1.Role, err error) { +func (c *roles) Get(name string, options v1.GetOptions) (result *v1alpha1.Role, err error) { result = &v1alpha1.Role{} err = c.client.Get(). Namespace(c.ns). Resource("roles"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -122,7 +124,7 @@ func (c *roles) List(opts v1.ListOptions) (result *v1alpha1.RoleList, err error) err = c.client.Get(). Namespace(c.ns). Resource("roles"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -130,16 +132,16 @@ func (c *roles) List(opts v1.ListOptions) (result *v1alpha1.RoleList, err error) // Watch returns a watch.Interface that watches the requested roles. func (c *roles) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("roles"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched role. -func (c *roles) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.Role, err error) { +func (c *roles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.Role, err error) { result = &v1alpha1.Role{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rolebinding.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rolebinding.go index a032717ec5..5e81967f17 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rolebinding.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1alpha1/rolebinding.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1alpha1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1alpha1 "k8s.io/client-go/pkg/apis/rbac/v1alpha1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type RoleBindingInterface interface { Update(*v1alpha1.RoleBinding) (*v1alpha1.RoleBinding, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1alpha1.RoleBinding, error) + Get(name string, options v1.GetOptions) (*v1alpha1.RoleBinding, error) List(opts v1.ListOptions) (*v1alpha1.RoleBindingList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.RoleBinding, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.RoleBinding, err error) RoleBindingExpansion } @@ -98,19 +99,20 @@ func (c *roleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v return c.client.Delete(). Namespace(c.ns). Resource("rolebindings"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the roleBinding, and returns the corresponding roleBinding object, and an error if there is any. -func (c *roleBindings) Get(name string) (result *v1alpha1.RoleBinding, err error) { +func (c *roleBindings) Get(name string, options v1.GetOptions) (result *v1alpha1.RoleBinding, err error) { result = &v1alpha1.RoleBinding{} err = c.client.Get(). Namespace(c.ns). Resource("rolebindings"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -122,7 +124,7 @@ func (c *roleBindings) List(opts v1.ListOptions) (result *v1alpha1.RoleBindingLi err = c.client.Get(). Namespace(c.ns). Resource("rolebindings"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -130,16 +132,16 @@ func (c *roleBindings) List(opts v1.ListOptions) (result *v1alpha1.RoleBindingLi // Watch returns a watch.Interface that watches the requested roleBindings. func (c *roleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Namespace(c.ns). Resource("rolebindings"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched roleBinding. -func (c *roleBindings) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1alpha1.RoleBinding, err error) { +func (c *roleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.RoleBinding, err error) { result = &v1alpha1.RoleBinding{} err = c.client.Patch(pt). Namespace(c.ns). diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/BUILD new file mode 100644 index 0000000000..efbfaa1770 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/BUILD @@ -0,0 +1,31 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "clusterrole.go", + "clusterrolebinding.go", + "doc.go", + "generated_expansion.go", + "rbac_client.go", + "role.go", + "rolebinding.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrole.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrole.go new file mode 100644 index 0000000000..6a63571f39 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrole.go @@ -0,0 +1,145 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" + rest "k8s.io/client-go/rest" +) + +// ClusterRolesGetter has a method to return a ClusterRoleInterface. +// A group's client should implement this interface. +type ClusterRolesGetter interface { + ClusterRoles() ClusterRoleInterface +} + +// ClusterRoleInterface has methods to work with ClusterRole resources. +type ClusterRoleInterface interface { + Create(*v1beta1.ClusterRole) (*v1beta1.ClusterRole, error) + Update(*v1beta1.ClusterRole) (*v1beta1.ClusterRole, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.ClusterRole, error) + List(opts v1.ListOptions) (*v1beta1.ClusterRoleList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRole, err error) + ClusterRoleExpansion +} + +// clusterRoles implements ClusterRoleInterface +type clusterRoles struct { + client rest.Interface +} + +// newClusterRoles returns a ClusterRoles +func newClusterRoles(c *RbacV1beta1Client) *clusterRoles { + return &clusterRoles{ + client: c.RESTClient(), + } +} + +// Create takes the representation of a clusterRole and creates it. Returns the server's representation of the clusterRole, and an error, if there is any. +func (c *clusterRoles) Create(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) { + result = &v1beta1.ClusterRole{} + err = c.client.Post(). + Resource("clusterroles"). + Body(clusterRole). + Do(). + Into(result) + return +} + +// Update takes the representation of a clusterRole and updates it. Returns the server's representation of the clusterRole, and an error, if there is any. +func (c *clusterRoles) Update(clusterRole *v1beta1.ClusterRole) (result *v1beta1.ClusterRole, err error) { + result = &v1beta1.ClusterRole{} + err = c.client.Put(). + Resource("clusterroles"). + Name(clusterRole.Name). + Body(clusterRole). + Do(). + Into(result) + return +} + +// Delete takes name of the clusterRole and deletes it. Returns an error if one occurs. +func (c *clusterRoles) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Resource("clusterroles"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *clusterRoles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Resource("clusterroles"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the clusterRole, and returns the corresponding clusterRole object, and an error if there is any. +func (c *clusterRoles) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRole, err error) { + result = &v1beta1.ClusterRole{} + err = c.client.Get(). + Resource("clusterroles"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ClusterRoles that match those selectors. +func (c *clusterRoles) List(opts v1.ListOptions) (result *v1beta1.ClusterRoleList, err error) { + result = &v1beta1.ClusterRoleList{} + err = c.client.Get(). + Resource("clusterroles"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested clusterRoles. +func (c *clusterRoles) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Resource("clusterroles"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched clusterRole. +func (c *clusterRoles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRole, err error) { + result = &v1beta1.ClusterRole{} + err = c.client.Patch(pt). + Resource("clusterroles"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrolebinding.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrolebinding.go new file mode 100644 index 0000000000..a2f3875096 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/clusterrolebinding.go @@ -0,0 +1,145 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" + rest "k8s.io/client-go/rest" +) + +// ClusterRoleBindingsGetter has a method to return a ClusterRoleBindingInterface. +// A group's client should implement this interface. +type ClusterRoleBindingsGetter interface { + ClusterRoleBindings() ClusterRoleBindingInterface +} + +// ClusterRoleBindingInterface has methods to work with ClusterRoleBinding resources. +type ClusterRoleBindingInterface interface { + Create(*v1beta1.ClusterRoleBinding) (*v1beta1.ClusterRoleBinding, error) + Update(*v1beta1.ClusterRoleBinding) (*v1beta1.ClusterRoleBinding, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.ClusterRoleBinding, error) + List(opts v1.ListOptions) (*v1beta1.ClusterRoleBindingList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRoleBinding, err error) + ClusterRoleBindingExpansion +} + +// clusterRoleBindings implements ClusterRoleBindingInterface +type clusterRoleBindings struct { + client rest.Interface +} + +// newClusterRoleBindings returns a ClusterRoleBindings +func newClusterRoleBindings(c *RbacV1beta1Client) *clusterRoleBindings { + return &clusterRoleBindings{ + client: c.RESTClient(), + } +} + +// Create takes the representation of a clusterRoleBinding and creates it. Returns the server's representation of the clusterRoleBinding, and an error, if there is any. +func (c *clusterRoleBindings) Create(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) { + result = &v1beta1.ClusterRoleBinding{} + err = c.client.Post(). + Resource("clusterrolebindings"). + Body(clusterRoleBinding). + Do(). + Into(result) + return +} + +// Update takes the representation of a clusterRoleBinding and updates it. Returns the server's representation of the clusterRoleBinding, and an error, if there is any. +func (c *clusterRoleBindings) Update(clusterRoleBinding *v1beta1.ClusterRoleBinding) (result *v1beta1.ClusterRoleBinding, err error) { + result = &v1beta1.ClusterRoleBinding{} + err = c.client.Put(). + Resource("clusterrolebindings"). + Name(clusterRoleBinding.Name). + Body(clusterRoleBinding). + Do(). + Into(result) + return +} + +// Delete takes name of the clusterRoleBinding and deletes it. Returns an error if one occurs. +func (c *clusterRoleBindings) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Resource("clusterrolebindings"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *clusterRoleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Resource("clusterrolebindings"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the clusterRoleBinding, and returns the corresponding clusterRoleBinding object, and an error if there is any. +func (c *clusterRoleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.ClusterRoleBinding, err error) { + result = &v1beta1.ClusterRoleBinding{} + err = c.client.Get(). + Resource("clusterrolebindings"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of ClusterRoleBindings that match those selectors. +func (c *clusterRoleBindings) List(opts v1.ListOptions) (result *v1beta1.ClusterRoleBindingList, err error) { + result = &v1beta1.ClusterRoleBindingList{} + err = c.client.Get(). + Resource("clusterrolebindings"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested clusterRoleBindings. +func (c *clusterRoleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Resource("clusterrolebindings"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched clusterRoleBinding. +func (c *clusterRoleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.ClusterRoleBinding, err error) { + result = &v1beta1.ClusterRoleBinding{} + err = c.client.Patch(pt). + Resource("clusterrolebindings"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/doc.go new file mode 100644 index 0000000000..11b5238972 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1beta1 diff --git a/vendor/k8s.io/client-go/plugin/pkg/client/auth/plugins.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/generated_expansion.go similarity index 71% rename from vendor/k8s.io/client-go/plugin/pkg/client/auth/plugins.go rename to vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/generated_expansion.go index 5cb2375ffb..d7f80c0042 100644 --- a/vendor/k8s.io/client-go/plugin/pkg/client/auth/plugins.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,10 +14,12 @@ See the License for the specific language governing permissions and limitations under the License. */ -package auth +package v1beta1 -import ( - // Initialize all known client auth plugins. - _ "k8s.io/client-go/plugin/pkg/client/auth/gcp" - _ "k8s.io/client-go/plugin/pkg/client/auth/oidc" -) +type ClusterRoleExpansion interface{} + +type ClusterRoleBindingExpansion interface{} + +type RoleExpansion interface{} + +type RoleBindingExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rbac_client.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rbac_client.go new file mode 100644 index 0000000000..a24ef4f9ab --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rbac_client.go @@ -0,0 +1,103 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" + rest "k8s.io/client-go/rest" +) + +type RbacV1beta1Interface interface { + RESTClient() rest.Interface + ClusterRolesGetter + ClusterRoleBindingsGetter + RolesGetter + RoleBindingsGetter +} + +// RbacV1beta1Client is used to interact with features provided by the rbac.authorization.k8s.io group. +type RbacV1beta1Client struct { + restClient rest.Interface +} + +func (c *RbacV1beta1Client) ClusterRoles() ClusterRoleInterface { + return newClusterRoles(c) +} + +func (c *RbacV1beta1Client) ClusterRoleBindings() ClusterRoleBindingInterface { + return newClusterRoleBindings(c) +} + +func (c *RbacV1beta1Client) Roles(namespace string) RoleInterface { + return newRoles(c, namespace) +} + +func (c *RbacV1beta1Client) RoleBindings(namespace string) RoleBindingInterface { + return newRoleBindings(c, namespace) +} + +// NewForConfig creates a new RbacV1beta1Client for the given config. +func NewForConfig(c *rest.Config) (*RbacV1beta1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &RbacV1beta1Client{client}, nil +} + +// NewForConfigOrDie creates a new RbacV1beta1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *RbacV1beta1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new RbacV1beta1Client for the given RESTClient. +func New(c rest.Interface) *RbacV1beta1Client { + return &RbacV1beta1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *RbacV1beta1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/role.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/role.go new file mode 100644 index 0000000000..aa57ac3196 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/role.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" + rest "k8s.io/client-go/rest" +) + +// RolesGetter has a method to return a RoleInterface. +// A group's client should implement this interface. +type RolesGetter interface { + Roles(namespace string) RoleInterface +} + +// RoleInterface has methods to work with Role resources. +type RoleInterface interface { + Create(*v1beta1.Role) (*v1beta1.Role, error) + Update(*v1beta1.Role) (*v1beta1.Role, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.Role, error) + List(opts v1.ListOptions) (*v1beta1.RoleList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Role, err error) + RoleExpansion +} + +// roles implements RoleInterface +type roles struct { + client rest.Interface + ns string +} + +// newRoles returns a Roles +func newRoles(c *RbacV1beta1Client, namespace string) *roles { + return &roles{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a role and creates it. Returns the server's representation of the role, and an error, if there is any. +func (c *roles) Create(role *v1beta1.Role) (result *v1beta1.Role, err error) { + result = &v1beta1.Role{} + err = c.client.Post(). + Namespace(c.ns). + Resource("roles"). + Body(role). + Do(). + Into(result) + return +} + +// Update takes the representation of a role and updates it. Returns the server's representation of the role, and an error, if there is any. +func (c *roles) Update(role *v1beta1.Role) (result *v1beta1.Role, err error) { + result = &v1beta1.Role{} + err = c.client.Put(). + Namespace(c.ns). + Resource("roles"). + Name(role.Name). + Body(role). + Do(). + Into(result) + return +} + +// Delete takes name of the role and deletes it. Returns an error if one occurs. +func (c *roles) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("roles"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *roles) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("roles"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the role, and returns the corresponding role object, and an error if there is any. +func (c *roles) Get(name string, options v1.GetOptions) (result *v1beta1.Role, err error) { + result = &v1beta1.Role{} + err = c.client.Get(). + Namespace(c.ns). + Resource("roles"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of Roles that match those selectors. +func (c *roles) List(opts v1.ListOptions) (result *v1beta1.RoleList, err error) { + result = &v1beta1.RoleList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("roles"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested roles. +func (c *roles) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("roles"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched role. +func (c *roles) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.Role, err error) { + result = &v1beta1.Role{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("roles"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rolebinding.go b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rolebinding.go new file mode 100644 index 0000000000..3dee9107e1 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/rbac/v1beta1/rolebinding.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/rbac/v1beta1" + rest "k8s.io/client-go/rest" +) + +// RoleBindingsGetter has a method to return a RoleBindingInterface. +// A group's client should implement this interface. +type RoleBindingsGetter interface { + RoleBindings(namespace string) RoleBindingInterface +} + +// RoleBindingInterface has methods to work with RoleBinding resources. +type RoleBindingInterface interface { + Create(*v1beta1.RoleBinding) (*v1beta1.RoleBinding, error) + Update(*v1beta1.RoleBinding) (*v1beta1.RoleBinding, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1beta1.RoleBinding, error) + List(opts v1.ListOptions) (*v1beta1.RoleBindingList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.RoleBinding, err error) + RoleBindingExpansion +} + +// roleBindings implements RoleBindingInterface +type roleBindings struct { + client rest.Interface + ns string +} + +// newRoleBindings returns a RoleBindings +func newRoleBindings(c *RbacV1beta1Client, namespace string) *roleBindings { + return &roleBindings{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a roleBinding and creates it. Returns the server's representation of the roleBinding, and an error, if there is any. +func (c *roleBindings) Create(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) { + result = &v1beta1.RoleBinding{} + err = c.client.Post(). + Namespace(c.ns). + Resource("rolebindings"). + Body(roleBinding). + Do(). + Into(result) + return +} + +// Update takes the representation of a roleBinding and updates it. Returns the server's representation of the roleBinding, and an error, if there is any. +func (c *roleBindings) Update(roleBinding *v1beta1.RoleBinding) (result *v1beta1.RoleBinding, err error) { + result = &v1beta1.RoleBinding{} + err = c.client.Put(). + Namespace(c.ns). + Resource("rolebindings"). + Name(roleBinding.Name). + Body(roleBinding). + Do(). + Into(result) + return +} + +// Delete takes name of the roleBinding and deletes it. Returns an error if one occurs. +func (c *roleBindings) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("rolebindings"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *roleBindings) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("rolebindings"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the roleBinding, and returns the corresponding roleBinding object, and an error if there is any. +func (c *roleBindings) Get(name string, options v1.GetOptions) (result *v1beta1.RoleBinding, err error) { + result = &v1beta1.RoleBinding{} + err = c.client.Get(). + Namespace(c.ns). + Resource("rolebindings"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of RoleBindings that match those selectors. +func (c *roleBindings) List(opts v1.ListOptions) (result *v1beta1.RoleBindingList, err error) { + result = &v1beta1.RoleBindingList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("rolebindings"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested roleBindings. +func (c *roleBindings) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("rolebindings"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched roleBinding. +func (c *roleBindings) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.RoleBinding, err error) { + result = &v1beta1.RoleBinding{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("rolebindings"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/BUILD new file mode 100644 index 0000000000..181d6dfd41 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "podpreset.go", + "settings_client.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/doc.go new file mode 100644 index 0000000000..ba8d10d3b6 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1alpha1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/generated_expansion.go new file mode 100644 index 0000000000..d599b2935c --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +type PodPresetExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/podpreset.go b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/podpreset.go new file mode 100644 index 0000000000..b8fc0a022a --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/podpreset.go @@ -0,0 +1,155 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/settings/v1alpha1" + rest "k8s.io/client-go/rest" +) + +// PodPresetsGetter has a method to return a PodPresetInterface. +// A group's client should implement this interface. +type PodPresetsGetter interface { + PodPresets(namespace string) PodPresetInterface +} + +// PodPresetInterface has methods to work with PodPreset resources. +type PodPresetInterface interface { + Create(*v1alpha1.PodPreset) (*v1alpha1.PodPreset, error) + Update(*v1alpha1.PodPreset) (*v1alpha1.PodPreset, error) + Delete(name string, options *v1.DeleteOptions) error + DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error + Get(name string, options v1.GetOptions) (*v1alpha1.PodPreset, error) + List(opts v1.ListOptions) (*v1alpha1.PodPresetList, error) + Watch(opts v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.PodPreset, err error) + PodPresetExpansion +} + +// podPresets implements PodPresetInterface +type podPresets struct { + client rest.Interface + ns string +} + +// newPodPresets returns a PodPresets +func newPodPresets(c *SettingsV1alpha1Client, namespace string) *podPresets { + return &podPresets{ + client: c.RESTClient(), + ns: namespace, + } +} + +// Create takes the representation of a podPreset and creates it. Returns the server's representation of the podPreset, and an error, if there is any. +func (c *podPresets) Create(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) { + result = &v1alpha1.PodPreset{} + err = c.client.Post(). + Namespace(c.ns). + Resource("podpresets"). + Body(podPreset). + Do(). + Into(result) + return +} + +// Update takes the representation of a podPreset and updates it. Returns the server's representation of the podPreset, and an error, if there is any. +func (c *podPresets) Update(podPreset *v1alpha1.PodPreset) (result *v1alpha1.PodPreset, err error) { + result = &v1alpha1.PodPreset{} + err = c.client.Put(). + Namespace(c.ns). + Resource("podpresets"). + Name(podPreset.Name). + Body(podPreset). + Do(). + Into(result) + return +} + +// Delete takes name of the podPreset and deletes it. Returns an error if one occurs. +func (c *podPresets) Delete(name string, options *v1.DeleteOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("podpresets"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *podPresets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { + return c.client.Delete(). + Namespace(c.ns). + Resource("podpresets"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the podPreset, and returns the corresponding podPreset object, and an error if there is any. +func (c *podPresets) Get(name string, options v1.GetOptions) (result *v1alpha1.PodPreset, err error) { + result = &v1alpha1.PodPreset{} + err = c.client.Get(). + Namespace(c.ns). + Resource("podpresets"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of PodPresets that match those selectors. +func (c *podPresets) List(opts v1.ListOptions) (result *v1alpha1.PodPresetList, err error) { + result = &v1alpha1.PodPresetList{} + err = c.client.Get(). + Namespace(c.ns). + Resource("podpresets"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested podPresets. +func (c *podPresets) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Namespace(c.ns). + Resource("podpresets"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched podPreset. +func (c *podPresets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1alpha1.PodPreset, err error) { + result = &v1alpha1.PodPreset{} + err = c.client.Patch(pt). + Namespace(c.ns). + Resource("podpresets"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/settings_client.go b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/settings_client.go new file mode 100644 index 0000000000..1a90034bcd --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/settings/v1alpha1/settings_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1alpha1 "k8s.io/client-go/pkg/apis/settings/v1alpha1" + rest "k8s.io/client-go/rest" +) + +type SettingsV1alpha1Interface interface { + RESTClient() rest.Interface + PodPresetsGetter +} + +// SettingsV1alpha1Client is used to interact with features provided by the settings.k8s.io group. +type SettingsV1alpha1Client struct { + restClient rest.Interface +} + +func (c *SettingsV1alpha1Client) PodPresets(namespace string) PodPresetInterface { + return newPodPresets(c, namespace) +} + +// NewForConfig creates a new SettingsV1alpha1Client for the given config. +func NewForConfig(c *rest.Config) (*SettingsV1alpha1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &SettingsV1alpha1Client{client}, nil +} + +// NewForConfigOrDie creates a new SettingsV1alpha1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *SettingsV1alpha1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new SettingsV1alpha1Client for the given RESTClient. +func New(c rest.Interface) *SettingsV1alpha1Client { + return &SettingsV1alpha1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1alpha1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *SettingsV1alpha1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/BUILD new file mode 100644 index 0000000000..18100507d6 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "storage_client.go", + "storageclass.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/storage/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/doc.go new file mode 100644 index 0000000000..54673bfa73 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/doc.go @@ -0,0 +1,20 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This package is generated by client-gen with custom arguments. + +// This package has the automatically generated typed clients. +package v1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/generated_expansion.go new file mode 100644 index 0000000000..39df9fb879 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/generated_expansion.go @@ -0,0 +1,19 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +type StorageClassExpansion interface{} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storage_client.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storage_client.go new file mode 100644 index 0000000000..a95d30b2d7 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storage_client.go @@ -0,0 +1,88 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/storage/v1" + rest "k8s.io/client-go/rest" +) + +type StorageV1Interface interface { + RESTClient() rest.Interface + StorageClassesGetter +} + +// StorageV1Client is used to interact with features provided by the storage.k8s.io group. +type StorageV1Client struct { + restClient rest.Interface +} + +func (c *StorageV1Client) StorageClasses() StorageClassInterface { + return newStorageClasses(c) +} + +// NewForConfig creates a new StorageV1Client for the given config. +func NewForConfig(c *rest.Config) (*StorageV1Client, error) { + config := *c + if err := setConfigDefaults(&config); err != nil { + return nil, err + } + client, err := rest.RESTClientFor(&config) + if err != nil { + return nil, err + } + return &StorageV1Client{client}, nil +} + +// NewForConfigOrDie creates a new StorageV1Client for the given config and +// panics if there is an error in the config. +func NewForConfigOrDie(c *rest.Config) *StorageV1Client { + client, err := NewForConfig(c) + if err != nil { + panic(err) + } + return client +} + +// New creates a new StorageV1Client for the given RESTClient. +func New(c rest.Interface) *StorageV1Client { + return &StorageV1Client{c} +} + +func setConfigDefaults(config *rest.Config) error { + gv := v1.SchemeGroupVersion + config.GroupVersion = &gv + config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + + if config.UserAgent == "" { + config.UserAgent = rest.DefaultKubernetesUserAgent() + } + + return nil +} + +// RESTClient returns a RESTClient that is used to communicate +// with API server by this client implementation. +func (c *StorageV1Client) RESTClient() rest.Interface { + if c == nil { + return nil + } + return c.restClient +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storageclass.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storageclass.go new file mode 100644 index 0000000000..0283c99709 --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1/storageclass.go @@ -0,0 +1,145 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" + v1 "k8s.io/client-go/pkg/apis/storage/v1" + rest "k8s.io/client-go/rest" +) + +// StorageClassesGetter has a method to return a StorageClassInterface. +// A group's client should implement this interface. +type StorageClassesGetter interface { + StorageClasses() StorageClassInterface +} + +// StorageClassInterface has methods to work with StorageClass resources. +type StorageClassInterface interface { + Create(*v1.StorageClass) (*v1.StorageClass, error) + Update(*v1.StorageClass) (*v1.StorageClass, error) + Delete(name string, options *meta_v1.DeleteOptions) error + DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error + Get(name string, options meta_v1.GetOptions) (*v1.StorageClass, error) + List(opts meta_v1.ListOptions) (*v1.StorageClassList, error) + Watch(opts meta_v1.ListOptions) (watch.Interface, error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.StorageClass, err error) + StorageClassExpansion +} + +// storageClasses implements StorageClassInterface +type storageClasses struct { + client rest.Interface +} + +// newStorageClasses returns a StorageClasses +func newStorageClasses(c *StorageV1Client) *storageClasses { + return &storageClasses{ + client: c.RESTClient(), + } +} + +// Create takes the representation of a storageClass and creates it. Returns the server's representation of the storageClass, and an error, if there is any. +func (c *storageClasses) Create(storageClass *v1.StorageClass) (result *v1.StorageClass, err error) { + result = &v1.StorageClass{} + err = c.client.Post(). + Resource("storageclasses"). + Body(storageClass). + Do(). + Into(result) + return +} + +// Update takes the representation of a storageClass and updates it. Returns the server's representation of the storageClass, and an error, if there is any. +func (c *storageClasses) Update(storageClass *v1.StorageClass) (result *v1.StorageClass, err error) { + result = &v1.StorageClass{} + err = c.client.Put(). + Resource("storageclasses"). + Name(storageClass.Name). + Body(storageClass). + Do(). + Into(result) + return +} + +// Delete takes name of the storageClass and deletes it. Returns an error if one occurs. +func (c *storageClasses) Delete(name string, options *meta_v1.DeleteOptions) error { + return c.client.Delete(). + Resource("storageclasses"). + Name(name). + Body(options). + Do(). + Error() +} + +// DeleteCollection deletes a collection of objects. +func (c *storageClasses) DeleteCollection(options *meta_v1.DeleteOptions, listOptions meta_v1.ListOptions) error { + return c.client.Delete(). + Resource("storageclasses"). + VersionedParams(&listOptions, scheme.ParameterCodec). + Body(options). + Do(). + Error() +} + +// Get takes name of the storageClass, and returns the corresponding storageClass object, and an error if there is any. +func (c *storageClasses) Get(name string, options meta_v1.GetOptions) (result *v1.StorageClass, err error) { + result = &v1.StorageClass{} + err = c.client.Get(). + Resource("storageclasses"). + Name(name). + VersionedParams(&options, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// List takes label and field selectors, and returns the list of StorageClasses that match those selectors. +func (c *storageClasses) List(opts meta_v1.ListOptions) (result *v1.StorageClassList, err error) { + result = &v1.StorageClassList{} + err = c.client.Get(). + Resource("storageclasses"). + VersionedParams(&opts, scheme.ParameterCodec). + Do(). + Into(result) + return +} + +// Watch returns a watch.Interface that watches the requested storageClasses. +func (c *storageClasses) Watch(opts meta_v1.ListOptions) (watch.Interface, error) { + opts.Watch = true + return c.client.Get(). + Resource("storageclasses"). + VersionedParams(&opts, scheme.ParameterCodec). + Watch() +} + +// Patch applies the patch and returns the patched storageClass. +func (c *storageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1.StorageClass, err error) { + result = &v1.StorageClass{} + err = c.client.Patch(pt). + Resource("storageclasses"). + SubResource(subresources...). + Name(name). + Body(data). + Do(). + Into(result) + return +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/BUILD b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/BUILD new file mode 100644 index 0000000000..120f0a781b --- /dev/null +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated_expansion.go", + "storage_client.go", + "storageclass.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/storage/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/doc.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/doc.go index c15d0baccf..11b5238972 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1beta1,rbac/v1alpha1,storage/v1beta1] +// This package is generated by client-gen with custom arguments. // This package has the automatically generated typed clients. package v1beta1 diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/generated_expansion.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/generated_expansion.go index b18dda009f..6f3f0c55e6 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/generated_expansion.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/generated_expansion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storage_client.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storage_client.go index b7eb26fd67..7abb99e573 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storage_client.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storage_client.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,11 +17,9 @@ limitations under the License. package v1beta1 import ( - fmt "fmt" - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - registered "k8s.io/client-go/pkg/apimachinery/registered" - serializer "k8s.io/client-go/pkg/runtime/serializer" + serializer "k8s.io/apimachinery/pkg/runtime/serializer" + "k8s.io/client-go/kubernetes/scheme" + v1beta1 "k8s.io/client-go/pkg/apis/storage/v1beta1" rest "k8s.io/client-go/rest" ) @@ -30,7 +28,7 @@ type StorageV1beta1Interface interface { StorageClassesGetter } -// StorageV1beta1Client is used to interact with features provided by the k8s.io/kubernetes/pkg/apimachinery/registered.Group group. +// StorageV1beta1Client is used to interact with features provided by the storage.k8s.io group. type StorageV1beta1Client struct { restClient rest.Interface } @@ -68,22 +66,14 @@ func New(c rest.Interface) *StorageV1beta1Client { } func setConfigDefaults(config *rest.Config) error { - gv, err := unversioned.ParseGroupVersion("storage.k8s.io/v1beta1") - if err != nil { - return err - } - // if storage.k8s.io/v1beta1 is not enabled, return an error - if !registered.IsEnabledVersion(gv) { - return fmt.Errorf("storage.k8s.io/v1beta1 is not enabled") - } + gv := v1beta1.SchemeGroupVersion + config.GroupVersion = &gv config.APIPath = "/apis" + config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: scheme.Codecs} + if config.UserAgent == "" { config.UserAgent = rest.DefaultKubernetesUserAgent() } - copyGroupVersion := gv - config.GroupVersion = ©GroupVersion - - config.NegotiatedSerializer = serializer.DirectCodecFactory{CodecFactory: api.Codecs} return nil } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storageclass.go b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storageclass.go index b6f2e74cd1..6980fc78bf 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storageclass.go +++ b/vendor/k8s.io/client-go/kubernetes/typed/storage/v1beta1/storageclass.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + types "k8s.io/apimachinery/pkg/types" + watch "k8s.io/apimachinery/pkg/watch" + scheme "k8s.io/client-go/kubernetes/scheme" v1beta1 "k8s.io/client-go/pkg/apis/storage/v1beta1" - watch "k8s.io/client-go/pkg/watch" rest "k8s.io/client-go/rest" ) @@ -36,10 +37,10 @@ type StorageClassInterface interface { Update(*v1beta1.StorageClass) (*v1beta1.StorageClass, error) Delete(name string, options *v1.DeleteOptions) error DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error - Get(name string) (*v1beta1.StorageClass, error) + Get(name string, options v1.GetOptions) (*v1beta1.StorageClass, error) List(opts v1.ListOptions) (*v1beta1.StorageClassList, error) Watch(opts v1.ListOptions) (watch.Interface, error) - Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.StorageClass, err error) + Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StorageClass, err error) StorageClassExpansion } @@ -92,18 +93,19 @@ func (c *storageClasses) Delete(name string, options *v1.DeleteOptions) error { func (c *storageClasses) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error { return c.client.Delete(). Resource("storageclasses"). - VersionedParams(&listOptions, api.ParameterCodec). + VersionedParams(&listOptions, scheme.ParameterCodec). Body(options). Do(). Error() } // Get takes name of the storageClass, and returns the corresponding storageClass object, and an error if there is any. -func (c *storageClasses) Get(name string) (result *v1beta1.StorageClass, err error) { +func (c *storageClasses) Get(name string, options v1.GetOptions) (result *v1beta1.StorageClass, err error) { result = &v1beta1.StorageClass{} err = c.client.Get(). Resource("storageclasses"). Name(name). + VersionedParams(&options, scheme.ParameterCodec). Do(). Into(result) return @@ -114,7 +116,7 @@ func (c *storageClasses) List(opts v1.ListOptions) (result *v1beta1.StorageClass result = &v1beta1.StorageClassList{} err = c.client.Get(). Resource("storageclasses"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Do(). Into(result) return @@ -122,15 +124,15 @@ func (c *storageClasses) List(opts v1.ListOptions) (result *v1beta1.StorageClass // Watch returns a watch.Interface that watches the requested storageClasses. func (c *storageClasses) Watch(opts v1.ListOptions) (watch.Interface, error) { + opts.Watch = true return c.client.Get(). - Prefix("watch"). Resource("storageclasses"). - VersionedParams(&opts, api.ParameterCodec). + VersionedParams(&opts, scheme.ParameterCodec). Watch() } // Patch applies the patch and returns the patched storageClass. -func (c *storageClasses) Patch(name string, pt api.PatchType, data []byte, subresources ...string) (result *v1beta1.StorageClass, err error) { +func (c *storageClasses) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.StorageClass, err error) { result = &v1beta1.StorageClass{} err = c.client.Patch(pt). Resource("storageclasses"). diff --git a/vendor/k8s.io/client-go/pkg/api/BUILD b/vendor/k8s.io/client-go/pkg/api/BUILD new file mode 100644 index 0000000000..8f4154d53c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "annotation_key_constants.go", + "doc.go", + "field_constants.go", + "json.go", + "objectreference.go", + "register.go", + "resource.go", + "taint.go", + "toleration.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/announced:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apimachinery/registered:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/api/OWNERS b/vendor/k8s.io/client-go/pkg/api/OWNERS index d28472e0fd..3a9b0c6d15 100644 --- a/vendor/k8s.io/client-go/pkg/api/OWNERS +++ b/vendor/k8s.io/client-go/pkg/api/OWNERS @@ -1,6 +1,44 @@ -assignees: - - bgrant0607 - - erictune - - lavalamp - - smarterclayton - - thockin +approvers: +- erictune +- lavalamp +- smarterclayton +- thockin +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- yujuhong +- brendandburns +- derekwaynecarr +- caesarxuchao +- vishh +- mikedanese +- liggitt +- nikhiljindal +- bprashanth +- gmarek +- erictune +- davidopp +- pmorie +- sttts +- kargakis +- dchen1107 +- saad-ali +- zmerlynn +- luxas +- janetkuo +- justinsb +- pwittrock +- roberthbailey +- ncdc +- timstclair +- yifan-gu +- eparis +- mwielgus +- timothysc +- soltysh +- piosz +- jsafrane +- jbeda diff --git a/vendor/k8s.io/client-go/pkg/api/annotation_key_constants.go b/vendor/k8s.io/client-go/pkg/api/annotation_key_constants.go new file mode 100644 index 0000000000..e1080a34a2 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/annotation_key_constants.go @@ -0,0 +1,113 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file should be consistent with pkg/api/v1/annotation_key_constants.go. + +package api + +const ( + // ImagePolicyFailedOpenKey is added to pods created by failing open when the image policy + // webhook backend fails. + ImagePolicyFailedOpenKey string = "alpha.image-policy.k8s.io/failed-open" + + // PodPresetOptOutAnnotationKey represents the annotation key for a pod to exempt itself from pod preset manipulation + PodPresetOptOutAnnotationKey string = "podpreset.admission.kubernetes.io/exclude" + + // MirrorAnnotationKey represents the annotation key set by kubelets when creating mirror pods + MirrorPodAnnotationKey string = "kubernetes.io/config.mirror" + + // TolerationsAnnotationKey represents the key of tolerations data (json serialized) + // in the Annotations of a Pod. + TolerationsAnnotationKey string = "scheduler.alpha.kubernetes.io/tolerations" + + // TaintsAnnotationKey represents the key of taints data (json serialized) + // in the Annotations of a Node. + TaintsAnnotationKey string = "scheduler.alpha.kubernetes.io/taints" + + // SeccompPodAnnotationKey represents the key of a seccomp profile applied + // to all containers of a pod. + SeccompPodAnnotationKey string = "seccomp.security.alpha.kubernetes.io/pod" + + // SeccompContainerAnnotationKeyPrefix represents the key of a seccomp profile applied + // to one container of a pod. + SeccompContainerAnnotationKeyPrefix string = "container.seccomp.security.alpha.kubernetes.io/" + + // CreatedByAnnotation represents the key used to store the spec(json) + // used to create the resource. + CreatedByAnnotation = "kubernetes.io/created-by" + + // PreferAvoidPodsAnnotationKey represents the key of preferAvoidPods data (json serialized) + // in the Annotations of a Node. + PreferAvoidPodsAnnotationKey string = "scheduler.alpha.kubernetes.io/preferAvoidPods" + + // SysctlsPodAnnotationKey represents the key of sysctls which are set for the infrastructure + // container of a pod. The annotation value is a comma separated list of sysctl_name=value + // key-value pairs. Only a limited set of whitelisted and isolated sysctls is supported by + // the kubelet. Pods with other sysctls will fail to launch. + SysctlsPodAnnotationKey string = "security.alpha.kubernetes.io/sysctls" + + // UnsafeSysctlsPodAnnotationKey represents the key of sysctls which are set for the infrastructure + // container of a pod. The annotation value is a comma separated list of sysctl_name=value + // key-value pairs. Unsafe sysctls must be explicitly enabled for a kubelet. They are properly + // namespaced to a pod or a container, but their isolation is usually unclear or weak. Their use + // is at-your-own-risk. Pods that attempt to set an unsafe sysctl that is not enabled for a kubelet + // will fail to launch. + UnsafeSysctlsPodAnnotationKey string = "security.alpha.kubernetes.io/unsafe-sysctls" + + // ObjectTTLAnnotations represents a suggestion for kubelet for how long it can cache + // an object (e.g. secret, config map) before fetching it again from apiserver. + // This annotation can be attached to node. + ObjectTTLAnnotationKey string = "node.alpha.kubernetes.io/ttl" + + // AffinityAnnotationKey represents the key of affinity data (json serialized) + // in the Annotations of a Pod. + // TODO: remove when alpha support for affinity is removed + AffinityAnnotationKey string = "scheduler.alpha.kubernetes.io/affinity" + + // annotation key prefix used to identify non-convertible json paths. + NonConvertibleAnnotationPrefix = "non-convertible.kubernetes.io" + + kubectlPrefix = "kubectl.kubernetes.io/" + + // LastAppliedConfigAnnotation is the annotation used to store the previous + // configuration of a resource for use in a three way diff by UpdateApplyAnnotation. + LastAppliedConfigAnnotation = kubectlPrefix + "last-applied-configuration" + + // AnnotationLoadBalancerSourceRangesKey is the key of the annotation on a service to set allowed ingress ranges on their LoadBalancers + // + // It should be a comma-separated list of CIDRs, e.g. `0.0.0.0/0` to + // allow full access (the default) or `18.0.0.0/8,56.0.0.0/8` to allow + // access only from the CIDRs currently allocated to MIT & the USPS. + // + // Not all cloud providers support this annotation, though AWS & GCE do. + AnnotationLoadBalancerSourceRangesKey = "service.beta.kubernetes.io/load-balancer-source-ranges" + + // AnnotationValueExternalTrafficLocal Value of annotation to specify local endpoints behavior. + AnnotationValueExternalTrafficLocal = "OnlyLocal" + // AnnotationValueExternalTrafficGlobal Value of annotation to specify global (legacy) behavior. + AnnotationValueExternalTrafficGlobal = "Global" + + // TODO: The beta annotations have been deprecated, remove them when we release k8s 1.8. + + // BetaAnnotationHealthCheckNodePort Annotation specifying the healthcheck nodePort for the service. + // If not specified, annotation is created by the service api backend with the allocated nodePort. + // Will use user-specified nodePort value if specified by the client. + BetaAnnotationHealthCheckNodePort = "service.beta.kubernetes.io/healthcheck-nodeport" + + // BetaAnnotationExternalTraffic An annotation that denotes if this Service desires to route + // external traffic to local endpoints only. This preserves Source IP and avoids a second hop. + BetaAnnotationExternalTraffic = "service.beta.kubernetes.io/external-traffic" +) diff --git a/vendor/k8s.io/client-go/pkg/api/context.go b/vendor/k8s.io/client-go/pkg/api/context.go deleted file mode 100644 index 71e0e2dd70..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/context.go +++ /dev/null @@ -1,152 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package api - -import ( - stderrs "errors" - "time" - - "golang.org/x/net/context" - "k8s.io/client-go/pkg/auth/user" - "k8s.io/client-go/pkg/types" -) - -// Context carries values across API boundaries. -// This context matches the context.Context interface -// (https://blog.golang.org/context), for the purposes -// of passing the api.Context through to the storage tier. -// TODO: Determine the extent that this abstraction+interface -// is used by the api, and whether we can remove. -type Context interface { - // Value returns the value associated with key or nil if none. - Value(key interface{}) interface{} - - // Deadline returns the time when this Context will be canceled, if any. - Deadline() (deadline time.Time, ok bool) - - // Done returns a channel that is closed when this Context is canceled - // or times out. - Done() <-chan struct{} - - // Err indicates why this context was canceled, after the Done channel - // is closed. - Err() error -} - -// The key type is unexported to prevent collisions -type key int - -const ( - // namespaceKey is the context key for the request namespace. - namespaceKey key = iota - - // userKey is the context key for the request user. - userKey - - // uidKey is the context key for the uid to assign to an object on create. - uidKey - - // userAgentKey is the context key for the request user agent. - userAgentKey -) - -// NewContext instantiates a base context object for request flows. -func NewContext() Context { - return context.TODO() -} - -// NewDefaultContext instantiates a base context object for request flows in the default namespace -func NewDefaultContext() Context { - return WithNamespace(NewContext(), NamespaceDefault) -} - -// WithValue returns a copy of parent in which the value associated with key is val. -func WithValue(parent Context, key interface{}, val interface{}) Context { - internalCtx, ok := parent.(context.Context) - if !ok { - panic(stderrs.New("Invalid context type")) - } - return context.WithValue(internalCtx, key, val) -} - -// WithNamespace returns a copy of parent in which the namespace value is set -func WithNamespace(parent Context, namespace string) Context { - return WithValue(parent, namespaceKey, namespace) -} - -// NamespaceFrom returns the value of the namespace key on the ctx -func NamespaceFrom(ctx Context) (string, bool) { - namespace, ok := ctx.Value(namespaceKey).(string) - return namespace, ok -} - -// NamespaceValue returns the value of the namespace key on the ctx, or the empty string if none -func NamespaceValue(ctx Context) string { - namespace, _ := NamespaceFrom(ctx) - return namespace -} - -// ValidNamespace returns false if the namespace on the context differs from the resource. If the resource has no namespace, it is set to the value in the context. -func ValidNamespace(ctx Context, resource *ObjectMeta) bool { - ns, ok := NamespaceFrom(ctx) - if len(resource.Namespace) == 0 { - resource.Namespace = ns - } - return ns == resource.Namespace && ok -} - -// WithNamespaceDefaultIfNone returns a context whose namespace is the default if and only if the parent context has no namespace value -func WithNamespaceDefaultIfNone(parent Context) Context { - namespace, ok := NamespaceFrom(parent) - if !ok || len(namespace) == 0 { - return WithNamespace(parent, NamespaceDefault) - } - return parent -} - -// WithUser returns a copy of parent in which the user value is set -func WithUser(parent Context, user user.Info) Context { - return WithValue(parent, userKey, user) -} - -// UserFrom returns the value of the user key on the ctx -func UserFrom(ctx Context) (user.Info, bool) { - user, ok := ctx.Value(userKey).(user.Info) - return user, ok -} - -// WithUID returns a copy of parent in which the uid value is set -func WithUID(parent Context, uid types.UID) Context { - return WithValue(parent, uidKey, uid) -} - -// UIDFrom returns the value of the uid key on the ctx -func UIDFrom(ctx Context) (types.UID, bool) { - uid, ok := ctx.Value(uidKey).(types.UID) - return uid, ok -} - -// WithUserAgent returns a copy of parent in which the user value is set -func WithUserAgent(parent Context, userAgent string) Context { - return WithValue(parent, userAgentKey, userAgent) -} - -// UserAgentFrom returns the value of the userAgent key on the ctx -func UserAgentFrom(ctx Context) (string, bool) { - userAgent, ok := ctx.Value(userAgentKey).(string) - return userAgent, ok -} diff --git a/vendor/k8s.io/client-go/pkg/api/doc.go b/vendor/k8s.io/client-go/pkg/api/doc.go index 1507a8823b..a4262ab361 100644 --- a/vendor/k8s.io/client-go/pkg/api/doc.go +++ b/vendor/k8s.io/client-go/pkg/api/doc.go @@ -14,8 +14,6 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register - // Package api contains the latest (or "internal") version of the // Kubernetes API objects. This is the API objects as represented in memory. // The contract presented to clients is located in the versioned packages, diff --git a/vendor/k8s.io/client-go/pkg/api/helpers.go b/vendor/k8s.io/client-go/pkg/api/helpers.go deleted file mode 100644 index 8f494c1947..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/helpers.go +++ /dev/null @@ -1,631 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package api - -import ( - "crypto/md5" - "encoding/json" - "fmt" - "reflect" - "strings" - "time" - - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/selection" - "k8s.io/client-go/pkg/types" - "k8s.io/client-go/pkg/util/sets" - - "github.com/davecgh/go-spew/spew" -) - -// Conversion error conveniently packages up errors in conversions. -type ConversionError struct { - In, Out interface{} - Message string -} - -// Return a helpful string about the error -func (c *ConversionError) Error() string { - return spew.Sprintf( - "Conversion error: %s. (in: %v(%+v) out: %v)", - c.Message, reflect.TypeOf(c.In), c.In, reflect.TypeOf(c.Out), - ) -} - -// Semantic can do semantic deep equality checks for api objects. -// Example: api.Semantic.DeepEqual(aPod, aPodWithNonNilButEmptyMaps) == true -var Semantic = conversion.EqualitiesOrDie( - func(a, b resource.Quantity) bool { - // Ignore formatting, only care that numeric value stayed the same. - // TODO: if we decide it's important, it should be safe to start comparing the format. - // - // Uninitialized quantities are equivalent to 0 quantities. - return a.Cmp(b) == 0 - }, - func(a, b unversioned.Time) bool { - return a.UTC() == b.UTC() - }, - func(a, b labels.Selector) bool { - return a.String() == b.String() - }, - func(a, b fields.Selector) bool { - return a.String() == b.String() - }, -) - -var standardResourceQuotaScopes = sets.NewString( - string(ResourceQuotaScopeTerminating), - string(ResourceQuotaScopeNotTerminating), - string(ResourceQuotaScopeBestEffort), - string(ResourceQuotaScopeNotBestEffort), -) - -// IsStandardResourceQuotaScope returns true if the scope is a standard value -func IsStandardResourceQuotaScope(str string) bool { - return standardResourceQuotaScopes.Has(str) -} - -var podObjectCountQuotaResources = sets.NewString( - string(ResourcePods), -) - -var podComputeQuotaResources = sets.NewString( - string(ResourceCPU), - string(ResourceMemory), - string(ResourceLimitsCPU), - string(ResourceLimitsMemory), - string(ResourceRequestsCPU), - string(ResourceRequestsMemory), -) - -// IsResourceQuotaScopeValidForResource returns true if the resource applies to the specified scope -func IsResourceQuotaScopeValidForResource(scope ResourceQuotaScope, resource string) bool { - switch scope { - case ResourceQuotaScopeTerminating, ResourceQuotaScopeNotTerminating, ResourceQuotaScopeNotBestEffort: - return podObjectCountQuotaResources.Has(resource) || podComputeQuotaResources.Has(resource) - case ResourceQuotaScopeBestEffort: - return podObjectCountQuotaResources.Has(resource) - default: - return true - } -} - -var standardContainerResources = sets.NewString( - string(ResourceCPU), - string(ResourceMemory), -) - -// IsStandardContainerResourceName returns true if the container can make a resource request -// for the specified resource -func IsStandardContainerResourceName(str string) bool { - return standardContainerResources.Has(str) -} - -// IsOpaqueIntResourceName returns true if the resource name has the opaque -// integer resource prefix. -func IsOpaqueIntResourceName(name ResourceName) bool { - return strings.HasPrefix(string(name), ResourceOpaqueIntPrefix) -} - -// OpaqueIntResourceName returns a ResourceName with the canonical opaque -// integer prefix prepended. If the argument already has the prefix, it is -// returned unmodified. -func OpaqueIntResourceName(name string) ResourceName { - if IsOpaqueIntResourceName(ResourceName(name)) { - return ResourceName(name) - } - return ResourceName(fmt.Sprintf("%s%s", ResourceOpaqueIntPrefix, name)) -} - -var standardLimitRangeTypes = sets.NewString( - string(LimitTypePod), - string(LimitTypeContainer), - string(LimitTypePersistentVolumeClaim), -) - -// IsStandardLimitRangeType returns true if the type is Pod or Container -func IsStandardLimitRangeType(str string) bool { - return standardLimitRangeTypes.Has(str) -} - -var standardQuotaResources = sets.NewString( - string(ResourceCPU), - string(ResourceMemory), - string(ResourceRequestsCPU), - string(ResourceRequestsMemory), - string(ResourceRequestsStorage), - string(ResourceLimitsCPU), - string(ResourceLimitsMemory), - string(ResourcePods), - string(ResourceQuotas), - string(ResourceServices), - string(ResourceReplicationControllers), - string(ResourceSecrets), - string(ResourcePersistentVolumeClaims), - string(ResourceConfigMaps), - string(ResourceServicesNodePorts), - string(ResourceServicesLoadBalancers), -) - -// IsStandardQuotaResourceName returns true if the resource is known to -// the quota tracking system -func IsStandardQuotaResourceName(str string) bool { - return standardQuotaResources.Has(str) -} - -var standardResources = sets.NewString( - string(ResourceCPU), - string(ResourceMemory), - string(ResourceRequestsCPU), - string(ResourceRequestsMemory), - string(ResourceLimitsCPU), - string(ResourceLimitsMemory), - string(ResourcePods), - string(ResourceQuotas), - string(ResourceServices), - string(ResourceReplicationControllers), - string(ResourceSecrets), - string(ResourceConfigMaps), - string(ResourcePersistentVolumeClaims), - string(ResourceStorage), - string(ResourceRequestsStorage), -) - -// IsStandardResourceName returns true if the resource is known to the system -func IsStandardResourceName(str string) bool { - return standardResources.Has(str) -} - -var integerResources = sets.NewString( - string(ResourcePods), - string(ResourceQuotas), - string(ResourceServices), - string(ResourceReplicationControllers), - string(ResourceSecrets), - string(ResourceConfigMaps), - string(ResourcePersistentVolumeClaims), - string(ResourceServicesNodePorts), - string(ResourceServicesLoadBalancers), -) - -// IsIntegerResourceName returns true if the resource is measured in integer values -func IsIntegerResourceName(str string) bool { - return integerResources.Has(str) || IsOpaqueIntResourceName(ResourceName(str)) -} - -// NewDeleteOptions returns a DeleteOptions indicating the resource should -// be deleted within the specified grace period. Use zero to indicate -// immediate deletion. If you would prefer to use the default grace period, -// use &api.DeleteOptions{} directly. -func NewDeleteOptions(grace int64) *DeleteOptions { - return &DeleteOptions{GracePeriodSeconds: &grace} -} - -// NewPreconditionDeleteOptions returns a DeleteOptions with a UID precondition set. -func NewPreconditionDeleteOptions(uid string) *DeleteOptions { - u := types.UID(uid) - p := Preconditions{UID: &u} - return &DeleteOptions{Preconditions: &p} -} - -// NewUIDPreconditions returns a Preconditions with UID set. -func NewUIDPreconditions(uid string) *Preconditions { - u := types.UID(uid) - return &Preconditions{UID: &u} -} - -// this function aims to check if the service's ClusterIP is set or not -// the objective is not to perform validation here -func IsServiceIPSet(service *Service) bool { - return service.Spec.ClusterIP != ClusterIPNone && service.Spec.ClusterIP != "" -} - -// this function aims to check if the service's cluster IP is requested or not -func IsServiceIPRequested(service *Service) bool { - // ExternalName services are CNAME aliases to external ones. Ignore the IP. - if service.Spec.Type == ServiceTypeExternalName { - return false - } - return service.Spec.ClusterIP == "" -} - -var standardFinalizers = sets.NewString( - string(FinalizerKubernetes), - FinalizerOrphan, -) - -// HasAnnotation returns a bool if passed in annotation exists -func HasAnnotation(obj ObjectMeta, ann string) bool { - _, found := obj.Annotations[ann] - return found -} - -// SetMetaDataAnnotation sets the annotation and value -func SetMetaDataAnnotation(obj *ObjectMeta, ann string, value string) { - if obj.Annotations == nil { - obj.Annotations = make(map[string]string) - } - obj.Annotations[ann] = value -} - -func IsStandardFinalizerName(str string) bool { - return standardFinalizers.Has(str) -} - -// SingleObject returns a ListOptions for watching a single object. -func SingleObject(meta ObjectMeta) ListOptions { - return ListOptions{ - FieldSelector: fields.OneTermEqualSelector("metadata.name", meta.Name), - ResourceVersion: meta.ResourceVersion, - } -} - -// AddToNodeAddresses appends the NodeAddresses to the passed-by-pointer slice, -// only if they do not already exist -func AddToNodeAddresses(addresses *[]NodeAddress, addAddresses ...NodeAddress) { - for _, add := range addAddresses { - exists := false - for _, existing := range *addresses { - if existing.Address == add.Address && existing.Type == add.Type { - exists = true - break - } - } - if !exists { - *addresses = append(*addresses, add) - } - } -} - -func HashObject(obj runtime.Object, codec runtime.Codec) (string, error) { - data, err := runtime.Encode(codec, obj) - if err != nil { - return "", err - } - return fmt.Sprintf("%x", md5.Sum(data)), nil -} - -// TODO: make method on LoadBalancerStatus? -func LoadBalancerStatusEqual(l, r *LoadBalancerStatus) bool { - return ingressSliceEqual(l.Ingress, r.Ingress) -} - -func ingressSliceEqual(lhs, rhs []LoadBalancerIngress) bool { - if len(lhs) != len(rhs) { - return false - } - for i := range lhs { - if !ingressEqual(&lhs[i], &rhs[i]) { - return false - } - } - return true -} - -func ingressEqual(lhs, rhs *LoadBalancerIngress) bool { - if lhs.IP != rhs.IP { - return false - } - if lhs.Hostname != rhs.Hostname { - return false - } - return true -} - -// TODO: make method on LoadBalancerStatus? -func LoadBalancerStatusDeepCopy(lb *LoadBalancerStatus) *LoadBalancerStatus { - c := &LoadBalancerStatus{} - c.Ingress = make([]LoadBalancerIngress, len(lb.Ingress)) - for i := range lb.Ingress { - c.Ingress[i] = lb.Ingress[i] - } - return c -} - -// GetAccessModesAsString returns a string representation of an array of access modes. -// modes, when present, are always in the same order: RWO,ROX,RWX. -func GetAccessModesAsString(modes []PersistentVolumeAccessMode) string { - modes = removeDuplicateAccessModes(modes) - modesStr := []string{} - if containsAccessMode(modes, ReadWriteOnce) { - modesStr = append(modesStr, "RWO") - } - if containsAccessMode(modes, ReadOnlyMany) { - modesStr = append(modesStr, "ROX") - } - if containsAccessMode(modes, ReadWriteMany) { - modesStr = append(modesStr, "RWX") - } - return strings.Join(modesStr, ",") -} - -// GetAccessModesAsString returns an array of AccessModes from a string created by GetAccessModesAsString -func GetAccessModesFromString(modes string) []PersistentVolumeAccessMode { - strmodes := strings.Split(modes, ",") - accessModes := []PersistentVolumeAccessMode{} - for _, s := range strmodes { - s = strings.Trim(s, " ") - switch { - case s == "RWO": - accessModes = append(accessModes, ReadWriteOnce) - case s == "ROX": - accessModes = append(accessModes, ReadOnlyMany) - case s == "RWX": - accessModes = append(accessModes, ReadWriteMany) - } - } - return accessModes -} - -// removeDuplicateAccessModes returns an array of access modes without any duplicates -func removeDuplicateAccessModes(modes []PersistentVolumeAccessMode) []PersistentVolumeAccessMode { - accessModes := []PersistentVolumeAccessMode{} - for _, m := range modes { - if !containsAccessMode(accessModes, m) { - accessModes = append(accessModes, m) - } - } - return accessModes -} - -func containsAccessMode(modes []PersistentVolumeAccessMode, mode PersistentVolumeAccessMode) bool { - for _, m := range modes { - if m == mode { - return true - } - } - return false -} - -// ParseRFC3339 parses an RFC3339 date in either RFC3339Nano or RFC3339 format. -func ParseRFC3339(s string, nowFn func() unversioned.Time) (unversioned.Time, error) { - if t, timeErr := time.Parse(time.RFC3339Nano, s); timeErr == nil { - return unversioned.Time{Time: t}, nil - } - t, err := time.Parse(time.RFC3339, s) - if err != nil { - return unversioned.Time{}, err - } - return unversioned.Time{Time: t}, nil -} - -// NodeSelectorRequirementsAsSelector converts the []NodeSelectorRequirement api type into a struct that implements -// labels.Selector. -func NodeSelectorRequirementsAsSelector(nsm []NodeSelectorRequirement) (labels.Selector, error) { - if len(nsm) == 0 { - return labels.Nothing(), nil - } - selector := labels.NewSelector() - for _, expr := range nsm { - var op selection.Operator - switch expr.Operator { - case NodeSelectorOpIn: - op = selection.In - case NodeSelectorOpNotIn: - op = selection.NotIn - case NodeSelectorOpExists: - op = selection.Exists - case NodeSelectorOpDoesNotExist: - op = selection.DoesNotExist - case NodeSelectorOpGt: - op = selection.GreaterThan - case NodeSelectorOpLt: - op = selection.LessThan - default: - return nil, fmt.Errorf("%q is not a valid node selector operator", expr.Operator) - } - r, err := labels.NewRequirement(expr.Key, op, expr.Values) - if err != nil { - return nil, err - } - selector = selector.Add(*r) - } - return selector, nil -} - -const ( - // AffinityAnnotationKey represents the key of affinity data (json serialized) - // in the Annotations of a Pod. - AffinityAnnotationKey string = "scheduler.alpha.kubernetes.io/affinity" - - // TolerationsAnnotationKey represents the key of tolerations data (json serialized) - // in the Annotations of a Pod. - TolerationsAnnotationKey string = "scheduler.alpha.kubernetes.io/tolerations" - - // TaintsAnnotationKey represents the key of taints data (json serialized) - // in the Annotations of a Node. - TaintsAnnotationKey string = "scheduler.alpha.kubernetes.io/taints" - - // SeccompPodAnnotationKey represents the key of a seccomp profile applied - // to all containers of a pod. - SeccompPodAnnotationKey string = "seccomp.security.alpha.kubernetes.io/pod" - - // SeccompContainerAnnotationKeyPrefix represents the key of a seccomp profile applied - // to one container of a pod. - SeccompContainerAnnotationKeyPrefix string = "container.seccomp.security.alpha.kubernetes.io/" - - // CreatedByAnnotation represents the key used to store the spec(json) - // used to create the resource. - CreatedByAnnotation = "kubernetes.io/created-by" - - // PreferAvoidPodsAnnotationKey represents the key of preferAvoidPods data (json serialized) - // in the Annotations of a Node. - PreferAvoidPodsAnnotationKey string = "scheduler.alpha.kubernetes.io/preferAvoidPods" - - // SysctlsPodAnnotationKey represents the key of sysctls which are set for the infrastructure - // container of a pod. The annotation value is a comma separated list of sysctl_name=value - // key-value pairs. Only a limited set of whitelisted and isolated sysctls is supported by - // the kubelet. Pods with other sysctls will fail to launch. - SysctlsPodAnnotationKey string = "security.alpha.kubernetes.io/sysctls" - - // UnsafeSysctlsPodAnnotationKey represents the key of sysctls which are set for the infrastructure - // container of a pod. The annotation value is a comma separated list of sysctl_name=value - // key-value pairs. Unsafe sysctls must be explicitly enabled for a kubelet. They are properly - // namespaced to a pod or a container, but their isolation is usually unclear or weak. Their use - // is at-your-own-risk. Pods that attempt to set an unsafe sysctl that is not enabled for a kubelet - // will fail to launch. - UnsafeSysctlsPodAnnotationKey string = "security.alpha.kubernetes.io/unsafe-sysctls" -) - -// GetAffinityFromPod gets the json serialized affinity data from Pod.Annotations -// and converts it to the Affinity type in api. -func GetAffinityFromPodAnnotations(annotations map[string]string) (*Affinity, error) { - if len(annotations) > 0 && annotations[AffinityAnnotationKey] != "" { - var affinity Affinity - err := json.Unmarshal([]byte(annotations[AffinityAnnotationKey]), &affinity) - if err != nil { - return nil, err - } - return &affinity, nil - } - return nil, nil -} - -// GetTolerationsFromPodAnnotations gets the json serialized tolerations data from Pod.Annotations -// and converts it to the []Toleration type in api. -func GetTolerationsFromPodAnnotations(annotations map[string]string) ([]Toleration, error) { - var tolerations []Toleration - if len(annotations) > 0 && annotations[TolerationsAnnotationKey] != "" { - err := json.Unmarshal([]byte(annotations[TolerationsAnnotationKey]), &tolerations) - if err != nil { - return tolerations, err - } - } - return tolerations, nil -} - -// GetTaintsFromNodeAnnotations gets the json serialized taints data from Pod.Annotations -// and converts it to the []Taint type in api. -func GetTaintsFromNodeAnnotations(annotations map[string]string) ([]Taint, error) { - var taints []Taint - if len(annotations) > 0 && annotations[TaintsAnnotationKey] != "" { - err := json.Unmarshal([]byte(annotations[TaintsAnnotationKey]), &taints) - if err != nil { - return []Taint{}, err - } - } - return taints, nil -} - -// TolerationToleratesTaint checks if the toleration tolerates the taint. -func TolerationToleratesTaint(toleration *Toleration, taint *Taint) bool { - if len(toleration.Effect) != 0 && toleration.Effect != taint.Effect { - return false - } - - if toleration.Key != taint.Key { - return false - } - // TODO: Use proper defaulting when Toleration becomes a field of PodSpec - if (len(toleration.Operator) == 0 || toleration.Operator == TolerationOpEqual) && toleration.Value == taint.Value { - return true - } - if toleration.Operator == TolerationOpExists { - return true - } - return false -} - -// TaintToleratedByTolerations checks if taint is tolerated by any of the tolerations. -func TaintToleratedByTolerations(taint *Taint, tolerations []Toleration) bool { - tolerated := false - for i := range tolerations { - if TolerationToleratesTaint(&tolerations[i], taint) { - tolerated = true - break - } - } - return tolerated -} - -// MatchTaint checks if the taint matches taintToMatch. Taints are unique by key:effect, -// if the two taints have same key:effect, regard as they match. -func (t *Taint) MatchTaint(taintToMatch Taint) bool { - return t.Key == taintToMatch.Key && t.Effect == taintToMatch.Effect -} - -// taint.ToString() converts taint struct to string in format key=value:effect or key:effect. -func (t *Taint) ToString() string { - if len(t.Value) == 0 { - return fmt.Sprintf("%v:%v", t.Key, t.Effect) - } - return fmt.Sprintf("%v=%v:%v", t.Key, t.Value, t.Effect) -} - -func GetAvoidPodsFromNodeAnnotations(annotations map[string]string) (AvoidPods, error) { - var avoidPods AvoidPods - if len(annotations) > 0 && annotations[PreferAvoidPodsAnnotationKey] != "" { - err := json.Unmarshal([]byte(annotations[PreferAvoidPodsAnnotationKey]), &avoidPods) - if err != nil { - return avoidPods, err - } - } - return avoidPods, nil -} - -// SysctlsFromPodAnnotations parses the sysctl annotations into a slice of safe Sysctls -// and a slice of unsafe Sysctls. This is only a convenience wrapper around -// SysctlsFromPodAnnotation. -func SysctlsFromPodAnnotations(a map[string]string) ([]Sysctl, []Sysctl, error) { - safe, err := SysctlsFromPodAnnotation(a[SysctlsPodAnnotationKey]) - if err != nil { - return nil, nil, err - } - unsafe, err := SysctlsFromPodAnnotation(a[UnsafeSysctlsPodAnnotationKey]) - if err != nil { - return nil, nil, err - } - - return safe, unsafe, nil -} - -// SysctlsFromPodAnnotation parses an annotation value into a slice of Sysctls. -func SysctlsFromPodAnnotation(annotation string) ([]Sysctl, error) { - if len(annotation) == 0 { - return nil, nil - } - - kvs := strings.Split(annotation, ",") - sysctls := make([]Sysctl, len(kvs)) - for i, kv := range kvs { - cs := strings.Split(kv, "=") - if len(cs) != 2 || len(cs[0]) == 0 { - return nil, fmt.Errorf("sysctl %q not of the format sysctl_name=value", kv) - } - sysctls[i].Name = cs[0] - sysctls[i].Value = cs[1] - } - return sysctls, nil -} - -// PodAnnotationsFromSysctls creates an annotation value for a slice of Sysctls. -func PodAnnotationsFromSysctls(sysctls []Sysctl) string { - if len(sysctls) == 0 { - return "" - } - - kvs := make([]string, len(sysctls)) - for i := range sysctls { - kvs[i] = fmt.Sprintf("%s=%s", sysctls[i].Name, sysctls[i].Value) - } - return strings.Join(kvs, ",") -} diff --git a/vendor/k8s.io/client-go/pkg/api/install/install.go b/vendor/k8s.io/client-go/pkg/api/install/install.go deleted file mode 100644 index e41dd63784..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/install/install.go +++ /dev/null @@ -1,153 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the v1 monolithic api, making it available as an -// option to all of the API encoding/decoding machinery. -package install - -import ( - "fmt" - - "github.com/golang/glog" - - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/apimachinery" - "k8s.io/client-go/pkg/apimachinery/registered" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/sets" -) - -const importPrefix = "k8s.io/client-go/pkg/api" - -var accessor = meta.NewAccessor() - -// availableVersions lists all known external versions for this group from most preferred to least preferred -var availableVersions = []unversioned.GroupVersion{v1.SchemeGroupVersion} - -func init() { - registered.RegisterVersions(availableVersions) - externalVersions := []unversioned.GroupVersion{} - for _, v := range availableVersions { - if registered.IsAllowedVersion(v) { - externalVersions = append(externalVersions, v) - } - } - if len(externalVersions) == 0 { - glog.V(4).Infof("No version is registered for group %v", api.GroupName) - return - } - - if err := registered.EnableVersions(externalVersions...); err != nil { - glog.V(4).Infof("%v", err) - return - } - if err := enableVersions(externalVersions); err != nil { - glog.V(4).Infof("%v", err) - return - } -} - -// TODO: enableVersions should be centralized rather than spread in each API -// group. -// We can combine registered.RegisterVersions, registered.EnableVersions and -// registered.RegisterGroup once we have moved enableVersions there. -func enableVersions(externalVersions []unversioned.GroupVersion) error { - addVersionsToScheme(externalVersions...) - preferredExternalVersion := externalVersions[0] - - groupMeta := apimachinery.GroupMeta{ - GroupVersion: preferredExternalVersion, - GroupVersions: externalVersions, - RESTMapper: newRESTMapper(externalVersions), - SelfLinker: runtime.SelfLinker(accessor), - InterfacesFor: interfacesFor, - } - - if err := registered.RegisterGroup(groupMeta); err != nil { - return err - } - return nil -} - -func newRESTMapper(externalVersions []unversioned.GroupVersion) meta.RESTMapper { - // the list of kinds that are scoped at the root of the api hierarchy - // if a kind is not enumerated here, it is assumed to have a namespace scope - rootScoped := sets.NewString( - "Node", - "Namespace", - "PersistentVolume", - "ComponentStatus", - ) - - // these kinds should be excluded from the list of resources - ignoredKinds := sets.NewString( - "ListOptions", - "DeleteOptions", - "Status", - "PodLogOptions", - "PodExecOptions", - "PodAttachOptions", - "PodProxyOptions", - "NodeProxyOptions", - "ServiceProxyOptions", - "ThirdPartyResource", - "ThirdPartyResourceData", - "ThirdPartyResourceList") - - mapper := api.NewDefaultRESTMapper(externalVersions, interfacesFor, importPrefix, ignoredKinds, rootScoped) - - return mapper -} - -// InterfacesFor returns the default Codec and ResourceVersioner for a given version -// string, or an error if the version is not known. -func interfacesFor(version unversioned.GroupVersion) (*meta.VersionInterfaces, error) { - switch version { - case v1.SchemeGroupVersion: - return &meta.VersionInterfaces{ - ObjectConvertor: api.Scheme, - MetadataAccessor: accessor, - }, nil - default: - g, _ := registered.Group(api.GroupName) - return nil, fmt.Errorf("unsupported storage version: %s (valid: %v)", version, g.GroupVersions) - } -} - -func addVersionsToScheme(externalVersions ...unversioned.GroupVersion) { - // add the internal version to Scheme - if err := api.AddToScheme(api.Scheme); err != nil { - // Programmer error, detect immediately - panic(err) - } - // add the enabled external versions to Scheme - for _, v := range externalVersions { - if !registered.IsEnabledVersion(v) { - glog.Errorf("Version %s is not enabled, so it will not be added to the Scheme.", v) - continue - } - switch v { - case v1.SchemeGroupVersion: - if err := v1.AddToScheme(api.Scheme); err != nil { - // Programmer error, detect immediately - panic(err) - } - } - } -} diff --git a/vendor/k8s.io/client-go/pkg/api/meta/metatypes/types.go b/vendor/k8s.io/client-go/pkg/api/json.go similarity index 50% rename from vendor/k8s.io/client-go/pkg/api/meta/metatypes/types.go rename to vendor/k8s.io/client-go/pkg/api/json.go index 70b5aadaaa..3a6e04c182 100644 --- a/vendor/k8s.io/client-go/pkg/api/meta/metatypes/types.go +++ b/vendor/k8s.io/client-go/pkg/api/json.go @@ -1,5 +1,5 @@ /* -Copyright 2014 The Kubernetes Authors. +Copyright 2017 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. @@ -14,17 +14,15 @@ See the License for the specific language governing permissions and limitations under the License. */ -// The types defined in this package are used by the meta package to represent -// the in-memory version of objects. We cannot reuse the __internal version of -// API objects because it causes import cycle. -package metatypes +package api -import "k8s.io/client-go/pkg/types" +import "encoding/json" -type OwnerReference struct { - APIVersion string - Kind string - UID types.UID - Name string - Controller *bool -} +// This file implements json marshaling/unmarshaling interfaces on objects that are currently marshaled into annotations +// to prevent anyone from marshaling these internal structs. + +var _ = json.Marshaler(&AvoidPods{}) +var _ = json.Unmarshaler(&AvoidPods{}) + +func (AvoidPods) MarshalJSON() ([]byte, error) { panic("do not marshal internal struct") } +func (*AvoidPods) UnmarshalJSON([]byte) error { panic("do not unmarshal to internal struct") } diff --git a/vendor/k8s.io/client-go/pkg/api/meta.go b/vendor/k8s.io/client-go/pkg/api/meta.go deleted file mode 100644 index 0f76d946a5..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/meta.go +++ /dev/null @@ -1,140 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package api - -import ( - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/meta/metatypes" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/types" - "k8s.io/client-go/pkg/util/uuid" -) - -// FillObjectMetaSystemFields populates fields that are managed by the system on ObjectMeta. -func FillObjectMetaSystemFields(ctx Context, meta *ObjectMeta) { - meta.CreationTimestamp = unversioned.Now() - // allows admission controllers to assign a UID earlier in the request processing - // to support tracking resources pending creation. - uid, found := UIDFrom(ctx) - if !found { - uid = uuid.NewUUID() - } - meta.UID = uid - meta.SelfLink = "" -} - -// HasObjectMetaSystemFieldValues returns true if fields that are managed by the system on ObjectMeta have values. -func HasObjectMetaSystemFieldValues(meta *ObjectMeta) bool { - return !meta.CreationTimestamp.Time.IsZero() || - len(meta.UID) != 0 -} - -// ObjectMetaFor returns a pointer to a provided object's ObjectMeta. -// TODO: allow runtime.Unknown to extract this object -// TODO: Remove this function and use meta.Accessor() instead. -func ObjectMetaFor(obj runtime.Object) (*ObjectMeta, error) { - v, err := conversion.EnforcePtr(obj) - if err != nil { - return nil, err - } - var meta *ObjectMeta - err = runtime.FieldPtr(v, "ObjectMeta", &meta) - return meta, err -} - -// ListMetaFor returns a pointer to a provided object's ListMeta, -// or an error if the object does not have that pointer. -// TODO: allow runtime.Unknown to extract this object -func ListMetaFor(obj runtime.Object) (*unversioned.ListMeta, error) { - v, err := conversion.EnforcePtr(obj) - if err != nil { - return nil, err - } - var meta *unversioned.ListMeta - err = runtime.FieldPtr(v, "ListMeta", &meta) - return meta, err -} - -func (obj *ObjectMeta) GetObjectMeta() meta.Object { return obj } - -// Namespace implements meta.Object for any object with an ObjectMeta typed field. Allows -// fast, direct access to metadata fields for API objects. -func (meta *ObjectMeta) GetNamespace() string { return meta.Namespace } -func (meta *ObjectMeta) SetNamespace(namespace string) { meta.Namespace = namespace } -func (meta *ObjectMeta) GetName() string { return meta.Name } -func (meta *ObjectMeta) SetName(name string) { meta.Name = name } -func (meta *ObjectMeta) GetGenerateName() string { return meta.GenerateName } -func (meta *ObjectMeta) SetGenerateName(generateName string) { meta.GenerateName = generateName } -func (meta *ObjectMeta) GetUID() types.UID { return meta.UID } -func (meta *ObjectMeta) SetUID(uid types.UID) { meta.UID = uid } -func (meta *ObjectMeta) GetResourceVersion() string { return meta.ResourceVersion } -func (meta *ObjectMeta) SetResourceVersion(version string) { meta.ResourceVersion = version } -func (meta *ObjectMeta) GetSelfLink() string { return meta.SelfLink } -func (meta *ObjectMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink } -func (meta *ObjectMeta) GetCreationTimestamp() unversioned.Time { return meta.CreationTimestamp } -func (meta *ObjectMeta) SetCreationTimestamp(creationTimestamp unversioned.Time) { - meta.CreationTimestamp = creationTimestamp -} -func (meta *ObjectMeta) GetDeletionTimestamp() *unversioned.Time { return meta.DeletionTimestamp } -func (meta *ObjectMeta) SetDeletionTimestamp(deletionTimestamp *unversioned.Time) { - meta.DeletionTimestamp = deletionTimestamp -} -func (meta *ObjectMeta) GetLabels() map[string]string { return meta.Labels } -func (meta *ObjectMeta) SetLabels(labels map[string]string) { meta.Labels = labels } -func (meta *ObjectMeta) GetAnnotations() map[string]string { return meta.Annotations } -func (meta *ObjectMeta) SetAnnotations(annotations map[string]string) { meta.Annotations = annotations } -func (meta *ObjectMeta) GetFinalizers() []string { return meta.Finalizers } -func (meta *ObjectMeta) SetFinalizers(finalizers []string) { meta.Finalizers = finalizers } - -func (meta *ObjectMeta) GetOwnerReferences() []metatypes.OwnerReference { - ret := make([]metatypes.OwnerReference, len(meta.OwnerReferences)) - for i := 0; i < len(meta.OwnerReferences); i++ { - ret[i].Kind = meta.OwnerReferences[i].Kind - ret[i].Name = meta.OwnerReferences[i].Name - ret[i].UID = meta.OwnerReferences[i].UID - ret[i].APIVersion = meta.OwnerReferences[i].APIVersion - if meta.OwnerReferences[i].Controller != nil { - value := *meta.OwnerReferences[i].Controller - ret[i].Controller = &value - } - } - return ret -} - -func (meta *ObjectMeta) SetOwnerReferences(references []metatypes.OwnerReference) { - newReferences := make([]OwnerReference, len(references)) - for i := 0; i < len(references); i++ { - newReferences[i].Kind = references[i].Kind - newReferences[i].Name = references[i].Name - newReferences[i].UID = references[i].UID - newReferences[i].APIVersion = references[i].APIVersion - if references[i].Controller != nil { - value := *references[i].Controller - newReferences[i].Controller = &value - } - } - meta.OwnerReferences = newReferences -} - -func (meta *ObjectMeta) GetClusterName() string { - return meta.ClusterName -} -func (meta *ObjectMeta) SetClusterName(clusterName string) { - meta.ClusterName = clusterName -} diff --git a/vendor/k8s.io/client-go/pkg/api/objectreference.go b/vendor/k8s.io/client-go/pkg/api/objectreference.go new file mode 100644 index 0000000000..b36ecab27f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/objectreference.go @@ -0,0 +1,34 @@ +/* +Copyright 2017 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. +*/ + +//TODO: consider making these methods functions, because we don't want helper +//functions in the k8s.io/api repo. + +package api + +import ( + "k8s.io/apimachinery/pkg/runtime/schema" +) + +func (obj *ObjectReference) SetGroupVersionKind(gvk schema.GroupVersionKind) { + obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() +} + +func (obj *ObjectReference) GroupVersionKind() schema.GroupVersionKind { + return schema.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) +} + +func (obj *ObjectReference) GetObjectKind() schema.ObjectKind { return obj } diff --git a/vendor/k8s.io/client-go/pkg/api/register.go b/vendor/k8s.io/client-go/pkg/api/register.go index d5533b40c3..5f261bdfb5 100644 --- a/vendor/k8s.io/client-go/pkg/api/register.go +++ b/vendor/k8s.io/client-go/pkg/api/register.go @@ -17,11 +17,23 @@ limitations under the License. package api import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer" + "os" + + "k8s.io/apimachinery/pkg/apimachinery/announced" + "k8s.io/apimachinery/pkg/apimachinery/registered" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer" ) +// GroupFactoryRegistry is the APIGroupFactoryRegistry (overlaps a bit with Registry, see comments in package for details) +var GroupFactoryRegistry = make(announced.APIGroupFactoryRegistry) + +// Registry is an instance of an API registry. This is an interim step to start removing the idea of a global +// API registry. +var Registry = registered.NewOrDie(os.Getenv("KUBE_API_VERSIONS")) + // Scheme is the default instance of runtime.Scheme to which types in the Kubernetes API are already registered. // NOTE: If you are copying this file to start a new api group, STOP! Copy the // extensions group instead. This Scheme is special and should appear ONLY in @@ -36,46 +48,28 @@ var Codecs = serializer.NewCodecFactory(Scheme) const GroupName = "" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} - -// Unversioned is group version for unversioned API objects -// TODO: this should be v1 probably -var Unversioned = unversioned.GroupVersion{Group: "", Version: "v1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // ParameterCodec handles versioning of objects that are converted to query parameters. var ParameterCodec = runtime.NewParameterCodec(Scheme) // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs) + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme ) -func init() { - // TODO(lavalamp): move this call to scheme builder above. Can't - // remove it from here because lots of people inappropriately rely on it - // (specifically the unversioned time conversion). Can't have it in - // both places because then it gets double registered. Consequence of - // current state is that it only ever gets registered in the main - // api.Scheme, even though everyone that uses anything from unversioned - // needs these. - if err := addConversionFuncs(Scheme); err != nil { - // Programmer error. - panic(err) - } -} - func addKnownTypes(scheme *runtime.Scheme) error { - if err := scheme.AddIgnoredConversionType(&unversioned.TypeMeta{}, &unversioned.TypeMeta{}); err != nil { + if err := scheme.AddIgnoredConversionType(&metav1.TypeMeta{}, &metav1.TypeMeta{}); err != nil { return err } scheme.AddKnownTypes(SchemeGroupVersion, @@ -112,11 +106,10 @@ func addKnownTypes(scheme *runtime.Scheme) error { &PersistentVolumeList{}, &PersistentVolumeClaim{}, &PersistentVolumeClaimList{}, - &DeleteOptions{}, - &ListOptions{}, &PodAttachOptions{}, &PodLogOptions{}, &PodExecOptions{}, + &PodPortForwardOptions{}, &PodProxyOptions{}, &ComponentStatus{}, &ComponentStatusList{}, @@ -126,14 +119,5 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ConfigMapList{}, ) - // Register Unversioned types under their own special group - scheme.AddUnversionedTypes(Unversioned, - &unversioned.ExportOptions{}, - &unversioned.Status{}, - &unversioned.APIVersions{}, - &unversioned.APIGroupList{}, - &unversioned.APIGroup{}, - &unversioned.APIResourceList{}, - ) return nil } diff --git a/vendor/k8s.io/client-go/pkg/api/requestcontext.go b/vendor/k8s.io/client-go/pkg/api/requestcontext.go deleted file mode 100644 index 724fea811d..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/requestcontext.go +++ /dev/null @@ -1,117 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package api - -import ( - "errors" - "net/http" - "sync" - - "github.com/golang/glog" -) - -// RequestContextMapper keeps track of the context associated with a particular request -type RequestContextMapper interface { - // Get returns the context associated with the given request (if any), and true if the request has an associated context, and false if it does not. - Get(req *http.Request) (Context, bool) - // Update maps the request to the given context. If no context was previously associated with the request, an error is returned. - // Update should only be called with a descendant context of the previously associated context. - // Updating to an unrelated context may return an error in the future. - // The context associated with a request should only be updated by a limited set of callers. - // Valid examples include the authentication layer, or an audit/tracing layer. - Update(req *http.Request, context Context) error -} - -type requestContextMap struct { - contexts map[*http.Request]Context - lock sync.Mutex -} - -// NewRequestContextMapper returns a new RequestContextMapper. -// The returned mapper must be added as a request filter using NewRequestContextFilter. -func NewRequestContextMapper() RequestContextMapper { - return &requestContextMap{ - contexts: make(map[*http.Request]Context), - } -} - -// Get returns the context associated with the given request (if any), and true if the request has an associated context, and false if it does not. -// Get will only return a valid context when called from inside the filter chain set up by NewRequestContextFilter() -func (c *requestContextMap) Get(req *http.Request) (Context, bool) { - c.lock.Lock() - defer c.lock.Unlock() - context, ok := c.contexts[req] - return context, ok -} - -// Update maps the request to the given context. -// If no context was previously associated with the request, an error is returned and the context is ignored. -func (c *requestContextMap) Update(req *http.Request, context Context) error { - c.lock.Lock() - defer c.lock.Unlock() - if _, ok := c.contexts[req]; !ok { - return errors.New("No context associated") - } - // TODO: ensure the new context is a descendant of the existing one - c.contexts[req] = context - return nil -} - -// init maps the request to the given context and returns true if there was no context associated with the request already. -// if a context was already associated with the request, it ignores the given context and returns false. -// init is intentionally unexported to ensure that all init calls are paired with a remove after a request is handled -func (c *requestContextMap) init(req *http.Request, context Context) bool { - c.lock.Lock() - defer c.lock.Unlock() - if _, exists := c.contexts[req]; exists { - return false - } - c.contexts[req] = context - return true -} - -// remove is intentionally unexported to ensure that the context is not removed until a request is handled -func (c *requestContextMap) remove(req *http.Request) { - c.lock.Lock() - defer c.lock.Unlock() - delete(c.contexts, req) -} - -// WithRequestContext ensures there is a Context object associated with the request before calling the passed handler. -// After the passed handler runs, the context is cleaned up. -func WithRequestContext(handler http.Handler, mapper RequestContextMapper) http.Handler { - rcMap, ok := mapper.(*requestContextMap) - if !ok { - glog.Fatal("Unknown RequestContextMapper implementation.") - } - - return http.HandlerFunc(func(w http.ResponseWriter, req *http.Request) { - if rcMap.init(req, NewContext()) { - // If we were the ones to successfully initialize, pair with a remove - defer rcMap.remove(req) - } - handler.ServeHTTP(w, req) - }) -} - -// IsEmpty returns true if there are no contexts registered, or an error if it could not be determined. Intended for use by tests. -func IsEmpty(requestsToContexts RequestContextMapper) (bool, error) { - if requestsToContexts, ok := requestsToContexts.(*requestContextMap); ok { - return len(requestsToContexts.contexts) == 0, nil - } - return true, errors.New("Unknown RequestContextMapper implementation") -} diff --git a/vendor/k8s.io/client-go/pkg/api/resource.go b/vendor/k8s.io/client-go/pkg/api/resource.go new file mode 100644 index 0000000000..27b7fd6650 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/resource.go @@ -0,0 +1,62 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package api + +import ( + "k8s.io/apimachinery/pkg/api/resource" +) + +func (self ResourceName) String() string { + return string(self) +} + +// Returns the CPU limit if specified. +func (self *ResourceList) Cpu() *resource.Quantity { + if val, ok := (*self)[ResourceCPU]; ok { + return &val + } + return &resource.Quantity{Format: resource.DecimalSI} +} + +// Returns the Memory limit if specified. +func (self *ResourceList) Memory() *resource.Quantity { + if val, ok := (*self)[ResourceMemory]; ok { + return &val + } + return &resource.Quantity{Format: resource.BinarySI} +} + +func (self *ResourceList) Pods() *resource.Quantity { + if val, ok := (*self)[ResourcePods]; ok { + return &val + } + return &resource.Quantity{} +} + +func (self *ResourceList) NvidiaGPU() *resource.Quantity { + if val, ok := (*self)[ResourceNvidiaGPU]; ok { + return &val + } + return &resource.Quantity{} +} + +func (self *ResourceList) StorageOverlay() *resource.Quantity { + if val, ok := (*self)[ResourceStorageOverlay]; ok { + return &val + } + return &resource.Quantity{} +} diff --git a/vendor/k8s.io/client-go/pkg/api/resource/generated.pb.go b/vendor/k8s.io/client-go/pkg/api/resource/generated.pb.go deleted file mode 100644 index d70ee30741..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/resource/generated.pb.go +++ /dev/null @@ -1,70 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Code generated by protoc-gen-gogo. -// source: k8s.io/kubernetes/pkg/api/resource/generated.proto -// DO NOT EDIT! - -/* - Package resource is a generated protocol buffer package. - - It is generated from these files: - k8s.io/kubernetes/pkg/api/resource/generated.proto - - It has these top-level messages: - Quantity -*/ -package resource - -import proto "github.com/gogo/protobuf/proto" -import fmt "fmt" -import math "math" - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 - -func (m *Quantity) Reset() { *m = Quantity{} } -func (*Quantity) ProtoMessage() {} -func (*Quantity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } - -func init() { - proto.RegisterType((*Quantity)(nil), "k8s.io.client-go.pkg.api.resource.Quantity") -} - -var fileDescriptorGenerated = []byte{ - // 236 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x6c, 0x8f, 0xa1, 0x4e, 0x03, 0x41, - 0x10, 0x86, 0x67, 0x0d, 0x29, 0x27, 0x1b, 0x42, 0x48, 0xc5, 0x5e, 0x53, 0x45, 0x48, 0xd8, 0x09, - 0xa8, 0x06, 0xc9, 0x1b, 0x80, 0xc4, 0xdd, 0x95, 0x61, 0x99, 0x1c, 0xec, 0x6e, 0x76, 0x67, 0x05, - 0xae, 0x12, 0x59, 0x89, 0xec, 0xbd, 0x4d, 0x65, 0x25, 0x02, 0xc1, 0x1d, 0x2f, 0x42, 0x72, 0xa5, - 0x21, 0x21, 0xb8, 0xf9, 0xc4, 0x37, 0xf9, 0xfe, 0xe2, 0xb2, 0x99, 0x27, 0xc3, 0x1e, 0x9b, 0x5c, - 0x53, 0x74, 0x24, 0x94, 0x30, 0x34, 0x16, 0xab, 0xc0, 0x18, 0x29, 0xf9, 0x1c, 0x17, 0x84, 0x96, - 0x1c, 0xc5, 0x4a, 0xe8, 0xde, 0x84, 0xe8, 0xc5, 0x8f, 0x67, 0x3b, 0xc7, 0xfc, 0x3a, 0x26, 0x34, - 0xd6, 0x54, 0x81, 0xcd, 0xde, 0x99, 0x9c, 0x5b, 0x96, 0xc7, 0x5c, 0x9b, 0x85, 0x7f, 0x46, 0xeb, - 0xad, 0xc7, 0x41, 0xad, 0xf3, 0xc3, 0x40, 0x03, 0x0c, 0xd7, 0xee, 0xe5, 0xe4, 0xe2, 0xff, 0x8c, - 0x2c, 0xfc, 0x84, 0xec, 0x24, 0x49, 0xfc, 0x5b, 0x31, 0x9b, 0x17, 0xa3, 0x9b, 0x5c, 0x39, 0x61, - 0x79, 0x19, 0x1f, 0x17, 0x07, 0x49, 0x22, 0x3b, 0x7b, 0xa2, 0xa6, 0xea, 0xf4, 0xf0, 0xf6, 0x87, - 0xae, 0x8e, 0xde, 0xd6, 0x25, 0xbc, 0xb6, 0x25, 0xac, 0xda, 0x12, 0xd6, 0x6d, 0x09, 0xcb, 0x8f, - 0x29, 0x5c, 0x9f, 0x6d, 0x3a, 0x0d, 0xdb, 0x4e, 0xc3, 0x7b, 0xa7, 0x61, 0xd9, 0x6b, 0xb5, 0xe9, - 0xb5, 0xda, 0xf6, 0x5a, 0x7d, 0xf6, 0x5a, 0xad, 0xbe, 0x34, 0xdc, 0x8d, 0xf6, 0x3b, 0xbe, 0x03, - 0x00, 0x00, 0xff, 0xff, 0x90, 0x1c, 0x7f, 0xff, 0x20, 0x01, 0x00, 0x00, -} diff --git a/vendor/k8s.io/client-go/pkg/api/resource_helpers.go b/vendor/k8s.io/client-go/pkg/api/resource_helpers.go deleted file mode 100644 index 3d78fc892a..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/resource_helpers.go +++ /dev/null @@ -1,229 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package api - -import ( - "time" - - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" -) - -// Returns string version of ResourceName. -func (self ResourceName) String() string { - return string(self) -} - -// Returns the CPU limit if specified. -func (self *ResourceList) Cpu() *resource.Quantity { - if val, ok := (*self)[ResourceCPU]; ok { - return &val - } - return &resource.Quantity{Format: resource.DecimalSI} -} - -// Returns the Memory limit if specified. -func (self *ResourceList) Memory() *resource.Quantity { - if val, ok := (*self)[ResourceMemory]; ok { - return &val - } - return &resource.Quantity{Format: resource.BinarySI} -} - -func (self *ResourceList) Pods() *resource.Quantity { - if val, ok := (*self)[ResourcePods]; ok { - return &val - } - return &resource.Quantity{} -} - -func (self *ResourceList) NvidiaGPU() *resource.Quantity { - if val, ok := (*self)[ResourceNvidiaGPU]; ok { - return &val - } - return &resource.Quantity{} -} - -func GetContainerStatus(statuses []ContainerStatus, name string) (ContainerStatus, bool) { - for i := range statuses { - if statuses[i].Name == name { - return statuses[i], true - } - } - return ContainerStatus{}, false -} - -func GetExistingContainerStatus(statuses []ContainerStatus, name string) ContainerStatus { - for i := range statuses { - if statuses[i].Name == name { - return statuses[i] - } - } - return ContainerStatus{} -} - -// IsPodAvailable returns true if a pod is available; false otherwise. -// Precondition for an available pod is that it must be ready. On top -// of that, there are two cases when a pod can be considered available: -// 1. minReadySeconds == 0, or -// 2. LastTransitionTime (is set) + minReadySeconds < current time -func IsPodAvailable(pod *Pod, minReadySeconds int32, now unversioned.Time) bool { - if !IsPodReady(pod) { - return false - } - - c := GetPodReadyCondition(pod.Status) - minReadySecondsDuration := time.Duration(minReadySeconds) * time.Second - if minReadySeconds == 0 || !c.LastTransitionTime.IsZero() && c.LastTransitionTime.Add(minReadySecondsDuration).Before(now.Time) { - return true - } - return false -} - -// IsPodReady returns true if a pod is ready; false otherwise. -func IsPodReady(pod *Pod) bool { - return IsPodReadyConditionTrue(pod.Status) -} - -// IsPodReady retruns true if a pod is ready; false otherwise. -func IsPodReadyConditionTrue(status PodStatus) bool { - condition := GetPodReadyCondition(status) - return condition != nil && condition.Status == ConditionTrue -} - -// Extracts the pod ready condition from the given status and returns that. -// Returns nil if the condition is not present. -func GetPodReadyCondition(status PodStatus) *PodCondition { - _, condition := GetPodCondition(&status, PodReady) - return condition -} - -// GetPodCondition extracts the provided condition from the given status and returns that. -// Returns nil and -1 if the condition is not present, and the index of the located condition. -func GetPodCondition(status *PodStatus, conditionType PodConditionType) (int, *PodCondition) { - if status == nil { - return -1, nil - } - for i := range status.Conditions { - if status.Conditions[i].Type == conditionType { - return i, &status.Conditions[i] - } - } - return -1, nil -} - -// GetNodeCondition extracts the provided condition from the given status and returns that. -// Returns nil and -1 if the condition is not present, and the index of the located condition. -func GetNodeCondition(status *NodeStatus, conditionType NodeConditionType) (int, *NodeCondition) { - if status == nil { - return -1, nil - } - for i := range status.Conditions { - if status.Conditions[i].Type == conditionType { - return i, &status.Conditions[i] - } - } - return -1, nil -} - -// Updates existing pod condition or creates a new one. Sets LastTransitionTime to now if the -// status has changed. -// Returns true if pod condition has changed or has been added. -func UpdatePodCondition(status *PodStatus, condition *PodCondition) bool { - condition.LastTransitionTime = unversioned.Now() - // Try to find this pod condition. - conditionIndex, oldCondition := GetPodCondition(status, condition.Type) - - if oldCondition == nil { - // We are adding new pod condition. - status.Conditions = append(status.Conditions, *condition) - return true - } else { - // We are updating an existing condition, so we need to check if it has changed. - if condition.Status == oldCondition.Status { - condition.LastTransitionTime = oldCondition.LastTransitionTime - } - - isEqual := condition.Status == oldCondition.Status && - condition.Reason == oldCondition.Reason && - condition.Message == oldCondition.Message && - condition.LastProbeTime.Equal(oldCondition.LastProbeTime) && - condition.LastTransitionTime.Equal(oldCondition.LastTransitionTime) - - status.Conditions[conditionIndex] = *condition - // Return true if one of the fields have changed. - return !isEqual - } -} - -// IsNodeReady returns true if a node is ready; false otherwise. -func IsNodeReady(node *Node) bool { - for _, c := range node.Status.Conditions { - if c.Type == NodeReady { - return c.Status == ConditionTrue - } - } - return false -} - -// PodRequestsAndLimits returns a dictionary of all defined resources summed up for all -// containers of the pod. -func PodRequestsAndLimits(pod *Pod) (reqs map[ResourceName]resource.Quantity, limits map[ResourceName]resource.Quantity, err error) { - reqs, limits = map[ResourceName]resource.Quantity{}, map[ResourceName]resource.Quantity{} - for _, container := range pod.Spec.Containers { - for name, quantity := range container.Resources.Requests { - if value, ok := reqs[name]; !ok { - reqs[name] = *quantity.Copy() - } else { - value.Add(quantity) - reqs[name] = value - } - } - for name, quantity := range container.Resources.Limits { - if value, ok := limits[name]; !ok { - limits[name] = *quantity.Copy() - } else { - value.Add(quantity) - limits[name] = value - } - } - } - // init containers define the minimum of any resource - for _, container := range pod.Spec.InitContainers { - for name, quantity := range container.Resources.Requests { - value, ok := reqs[name] - if !ok { - reqs[name] = *quantity.Copy() - continue - } - if quantity.Cmp(value) > 0 { - reqs[name] = *quantity.Copy() - } - } - for name, quantity := range container.Resources.Limits { - value, ok := limits[name] - if !ok { - limits[name] = *quantity.Copy() - continue - } - if quantity.Cmp(value) > 0 { - limits[name] = *quantity.Copy() - } - } - } - return -} diff --git a/vendor/k8s.io/client-go/pkg/api/taint.go b/vendor/k8s.io/client-go/pkg/api/taint.go new file mode 100644 index 0000000000..173e4e6016 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/taint.go @@ -0,0 +1,36 @@ +/* +Copyright 2017 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. +*/ + +//TODO: consider making these methods functions, because we don't want helper +//functions in the k8s.io/api repo. + +package api + +import "fmt" + +// MatchTaint checks if the taint matches taintToMatch. Taints are unique by key:effect, +// if the two taints have same key:effect, regard as they match. +func (t *Taint) MatchTaint(taintToMatch Taint) bool { + return t.Key == taintToMatch.Key && t.Effect == taintToMatch.Effect +} + +// taint.ToString() converts taint struct to string in format key=value:effect or key:effect. +func (t *Taint) ToString() string { + if len(t.Value) == 0 { + return fmt.Sprintf("%v:%v", t.Key, t.Effect) + } + return fmt.Sprintf("%v=%v:%v", t.Key, t.Value, t.Effect) +} diff --git a/vendor/k8s.io/client-go/pkg/api/toleration.go b/vendor/k8s.io/client-go/pkg/api/toleration.go new file mode 100644 index 0000000000..edb73b74e1 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/toleration.go @@ -0,0 +1,30 @@ +/* +Copyright 2017 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. +*/ + +//TODO: consider making these methods functions, because we don't want helper +//functions in the k8s.io/api repo. + +package api + +// MatchToleration checks if the toleration matches tolerationToMatch. Tolerations are unique by , +// if the two tolerations have same combination, regard as they match. +// TODO: uniqueness check for tolerations in api validations. +func (t *Toleration) MatchToleration(tolerationToMatch *Toleration) bool { + return t.Key == tolerationToMatch.Key && + t.Effect == tolerationToMatch.Effect && + t.Operator == tolerationToMatch.Operator && + t.Value == tolerationToMatch.Value +} diff --git a/vendor/k8s.io/client-go/pkg/api/types.generated.go b/vendor/k8s.io/client-go/pkg/api/types.generated.go deleted file mode 100644 index 2cc36139e8..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/types.generated.go +++ /dev/null @@ -1,63626 +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 api - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg3_resource "k8s.io/client-go/pkg/api/resource" - pkg2_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg6_fields "k8s.io/client-go/pkg/fields" - pkg5_labels "k8s.io/client-go/pkg/labels" - pkg7_runtime "k8s.io/client-go/pkg/runtime" - pkg1_types "k8s.io/client-go/pkg/types" - pkg4_intstr "k8s.io/client-go/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 pkg6_fields.Selector - var v3 pkg5_labels.Selector - var v4 pkg7_runtime.Object - var v5 pkg1_types.UID - var v6 pkg4_intstr.IntOrString - var v7 time.Time - _, _, _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5, v6, v7 - } -} - -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 [24]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.Quobyte != nil && x.Quobyte != nil - yyq101[13] = x.VolumeSource.FlexVolume != nil && x.FlexVolume != nil - yyq101[14] = x.VolumeSource.Cinder != nil && x.Cinder != nil - yyq101[15] = x.VolumeSource.CephFS != nil && x.CephFS != nil - yyq101[16] = x.VolumeSource.Flocker != nil && x.Flocker != nil - yyq101[17] = x.VolumeSource.DownwardAPI != nil && x.DownwardAPI != nil - yyq101[18] = x.VolumeSource.FC != nil && x.FC != nil - yyq101[19] = x.VolumeSource.AzureFile != nil && x.AzureFile != nil - yyq101[20] = x.VolumeSource.ConfigMap != nil && x.ConfigMap != nil - yyq101[21] = x.VolumeSource.VsphereVolume != nil && x.VsphereVolume != nil - yyq101[22] = x.VolumeSource.AzureDisk != nil && x.AzureDisk != nil - yyq101[23] = x.VolumeSource.PhotonPersistentDisk != nil && x.PhotonPersistentDisk != nil - var yynn101 int - if yyr101 || yy2arr101 { - r.EncodeArrayStart(24) - } 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.Quobyte == nil { - yyn116 = true - goto LABEL116 - } - LABEL116: - if yyr101 || yy2arr101 { - if yyn116 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[12] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("quobyte")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn116 { - r.EncodeNil() - } else { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } - } - } - var yyn117 bool - if x.VolumeSource.FlexVolume == nil { - yyn117 = true - goto LABEL117 - } - LABEL117: - if yyr101 || yy2arr101 { - if yyn117 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[13] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn117 { - r.EncodeNil() - } else { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn118 bool - if x.VolumeSource.Cinder == nil { - yyn118 = true - goto LABEL118 - } - LABEL118: - if yyr101 || yy2arr101 { - if yyn118 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[14] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cinder")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn118 { - r.EncodeNil() - } else { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } - } - } - var yyn119 bool - if x.VolumeSource.CephFS == nil { - yyn119 = true - goto LABEL119 - } - LABEL119: - if yyr101 || yy2arr101 { - if yyn119 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[15] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cephfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn119 { - r.EncodeNil() - } else { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } - } - } - var yyn120 bool - if x.VolumeSource.Flocker == nil { - yyn120 = true - goto LABEL120 - } - LABEL120: - if yyr101 || yy2arr101 { - if yyn120 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[16] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flocker")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn120 { - r.EncodeNil() - } else { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } - } - } - var yyn121 bool - if x.VolumeSource.DownwardAPI == nil { - yyn121 = true - goto LABEL121 - } - LABEL121: - if yyr101 || yy2arr101 { - if yyn121 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[17] { - if x.DownwardAPI == nil { - r.EncodeNil() - } else { - x.DownwardAPI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[17] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("downwardAPI")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn121 { - r.EncodeNil() - } else { - if x.DownwardAPI == nil { - r.EncodeNil() - } else { - x.DownwardAPI.CodecEncodeSelf(e) - } - } - } - } - var yyn122 bool - if x.VolumeSource.FC == nil { - yyn122 = true - goto LABEL122 - } - LABEL122: - if yyr101 || yy2arr101 { - if yyn122 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[18] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[18] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fc")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn122 { - r.EncodeNil() - } else { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } - } - } - var yyn123 bool - if x.VolumeSource.AzureFile == nil { - yyn123 = true - goto LABEL123 - } - LABEL123: - if yyr101 || yy2arr101 { - if yyn123 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[19] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[19] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureFile")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn123 { - r.EncodeNil() - } else { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } - } - } - var yyn124 bool - if x.VolumeSource.ConfigMap == nil { - yyn124 = true - goto LABEL124 - } - LABEL124: - if yyr101 || yy2arr101 { - if yyn124 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[20] { - if x.ConfigMap == nil { - r.EncodeNil() - } else { - x.ConfigMap.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[20] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("configMap")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn124 { - r.EncodeNil() - } else { - if x.ConfigMap == nil { - r.EncodeNil() - } else { - x.ConfigMap.CodecEncodeSelf(e) - } - } - } - } - var yyn125 bool - if x.VolumeSource.VsphereVolume == nil { - yyn125 = true - goto LABEL125 - } - LABEL125: - if yyr101 || yy2arr101 { - if yyn125 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[21] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[21] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn125 { - r.EncodeNil() - } else { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.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) - } - } - } - } - var yyn127 bool - if x.VolumeSource.PhotonPersistentDisk == nil { - yyn127 = true - goto LABEL127 - } - LABEL127: - if yyr101 || yy2arr101 { - if yyn127 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[23] { - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq101[23] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn127 { - r.EncodeNil() - } else { - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.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 - yym128 := z.DecBinary() - _ = yym128 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct129 := r.ContainerType() - if yyct129 == codecSelferValueTypeMap1234 { - yyl129 := r.ReadMapStart() - if yyl129 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl129, d) - } - } else if yyct129 == codecSelferValueTypeArray1234 { - yyl129 := r.ReadArrayStart() - if yyl129 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl129, 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 yys130Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys130Slc - var yyhl130 bool = l >= 0 - for yyj130 := 0; ; yyj130++ { - if yyhl130 { - if yyj130 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys130Slc = r.DecodeBytes(yys130Slc, true, true) - yys130 := string(yys130Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys130 { - 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 "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 "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 "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) - } - case "photonPersistentDisk": - if x.VolumeSource.PhotonPersistentDisk == nil { - x.VolumeSource.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys130) - } // end switch yys130 - } // end for yyj130 - 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 yyj155 int - var yyb155 bool - var yyhl155 bool = l >= 0 - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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.Quobyte == nil { - x.VolumeSource.Quobyte = new(QuobyteVolumeSource) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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.FlexVolume == nil { - x.VolumeSource.FlexVolume = new(FlexVolumeSource) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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.AzureDisk == nil { - x.VolumeSource.AzureDisk = new(AzureDiskVolumeSource) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - 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) - } - if x.VolumeSource.PhotonPersistentDisk == nil { - x.VolumeSource.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - for { - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l - } else { - yyb155 = r.CheckBreak() - } - if yyb155 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj155-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 { - yym180 := z.EncBinary() - _ = yym180 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep181 := !z.EncBinary() - yy2arr181 := z.EncBasicHandle().StructToArray - var yyq181 [23]bool - _, _, _ = yysep181, yyq181, yy2arr181 - const yyr181 bool = false - yyq181[0] = x.HostPath != nil - yyq181[1] = x.EmptyDir != nil - yyq181[2] = x.GCEPersistentDisk != nil - yyq181[3] = x.AWSElasticBlockStore != nil - yyq181[4] = x.GitRepo != nil - yyq181[5] = x.Secret != nil - yyq181[6] = x.NFS != nil - yyq181[7] = x.ISCSI != nil - yyq181[8] = x.Glusterfs != nil - yyq181[9] = x.PersistentVolumeClaim != nil - yyq181[10] = x.RBD != nil - yyq181[11] = x.Quobyte != nil - yyq181[12] = x.FlexVolume != nil - yyq181[13] = x.Cinder != nil - yyq181[14] = x.CephFS != nil - yyq181[15] = x.Flocker != nil - yyq181[16] = x.DownwardAPI != nil - yyq181[17] = x.FC != nil - yyq181[18] = x.AzureFile != nil - yyq181[19] = x.ConfigMap != nil - yyq181[20] = x.VsphereVolume != nil - yyq181[21] = x.AzureDisk != nil - yyq181[22] = x.PhotonPersistentDisk != nil - var yynn181 int - if yyr181 || yy2arr181 { - r.EncodeArrayStart(23) - } else { - yynn181 = 0 - for _, b := range yyq181 { - if b { - yynn181++ - } - } - r.EncodeMapStart(yynn181) - yynn181 = 0 - } - if yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[0] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[1] { - if x.EmptyDir == nil { - r.EncodeNil() - } else { - x.EmptyDir.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[2] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[3] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[4] { - if x.GitRepo == nil { - r.EncodeNil() - } else { - x.GitRepo.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[5] { - if x.Secret == nil { - r.EncodeNil() - } else { - x.Secret.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[6] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[7] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[8] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[9] { - if x.PersistentVolumeClaim == nil { - r.EncodeNil() - } else { - x.PersistentVolumeClaim.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[10] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[11] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[11] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[12] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[12] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[13] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[13] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[14] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[14] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[15] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[15] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[16] { - if x.DownwardAPI == nil { - r.EncodeNil() - } else { - x.DownwardAPI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[16] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[17] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[17] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[18] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[18] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[19] { - if x.ConfigMap == nil { - r.EncodeNil() - } else { - x.ConfigMap.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[19] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[20] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[20] { - 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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[21] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[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 yyr181 || yy2arr181 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[22] { - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq181[22] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } - } - if yyr181 || yy2arr181 { - 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 - yym205 := z.DecBinary() - _ = yym205 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct206 := r.ContainerType() - if yyct206 == codecSelferValueTypeMap1234 { - yyl206 := r.ReadMapStart() - if yyl206 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl206, d) - } - } else if yyct206 == codecSelferValueTypeArray1234 { - yyl206 := r.ReadArrayStart() - if yyl206 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl206, 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 yys207Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys207Slc - var yyhl207 bool = l >= 0 - for yyj207 := 0; ; yyj207++ { - if yyhl207 { - if yyj207 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys207Slc = r.DecodeBytes(yys207Slc, true, true) - yys207 := string(yys207Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys207 { - 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 "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 "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 "azureDisk": - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - case "photonPersistentDisk": - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys207) - } // end switch yys207 - } // end for yyj207 - 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 yyj231 int - var yyb231 bool - var yyhl231 bool = l >= 0 - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - 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) - } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - for { - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l - } else { - yyb231 = r.CheckBreak() - } - if yyb231 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj231-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 { - yym255 := z.EncBinary() - _ = yym255 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep256 := !z.EncBinary() - yy2arr256 := z.EncBasicHandle().StructToArray - var yyq256 [17]bool - _, _, _ = yysep256, yyq256, yy2arr256 - const yyr256 bool = false - yyq256[0] = x.GCEPersistentDisk != nil - yyq256[1] = x.AWSElasticBlockStore != nil - yyq256[2] = x.HostPath != nil - yyq256[3] = x.Glusterfs != nil - yyq256[4] = x.NFS != nil - yyq256[5] = x.RBD != nil - yyq256[6] = x.Quobyte != nil - yyq256[7] = x.ISCSI != nil - yyq256[8] = x.FlexVolume != nil - yyq256[9] = x.Cinder != nil - yyq256[10] = x.CephFS != nil - yyq256[11] = x.FC != nil - yyq256[12] = x.Flocker != nil - yyq256[13] = x.AzureFile != nil - yyq256[14] = x.VsphereVolume != nil - yyq256[15] = x.AzureDisk != nil - yyq256[16] = x.PhotonPersistentDisk != nil - var yynn256 int - if yyr256 || yy2arr256 { - r.EncodeArrayStart(17) - } else { - yynn256 = 0 - for _, b := range yyq256 { - if b { - yynn256++ - } - } - r.EncodeMapStart(yynn256) - yynn256 = 0 - } - if yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[0] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[1] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[2] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[3] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[4] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[5] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[6] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[6] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[7] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[8] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[8] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[9] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[9] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[10] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[10] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[11] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[11] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[12] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[12] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[13] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[13] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[14] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[14] { - 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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[15] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[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 yyr256 || yy2arr256 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[16] { - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq256[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } - } - if yyr256 || yy2arr256 { - 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 - yym274 := z.DecBinary() - _ = yym274 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct275 := r.ContainerType() - if yyct275 == codecSelferValueTypeMap1234 { - yyl275 := r.ReadMapStart() - if yyl275 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl275, d) - } - } else if yyct275 == codecSelferValueTypeArray1234 { - yyl275 := r.ReadArrayStart() - if yyl275 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl275, 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 yys276Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys276Slc - var yyhl276 bool = l >= 0 - for yyj276 := 0; ; yyj276++ { - if yyhl276 { - if yyj276 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys276Slc = r.DecodeBytes(yys276Slc, true, true) - yys276 := string(yys276Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys276 { - 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 "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 "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 "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 "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 "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 "azureDisk": - if r.TryDecodeAsNil() { - if x.AzureDisk != nil { - x.AzureDisk = nil - } - } else { - if x.AzureDisk == nil { - x.AzureDisk = new(AzureDiskVolumeSource) - } - x.AzureDisk.CodecDecodeSelf(d) - } - case "photonPersistentDisk": - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys276) - } // end switch yys276 - } // end for yyj276 - 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 yyj294 int - var yyb294 bool - var yyhl294 bool = l >= 0 - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - 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) - } - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - for { - yyj294++ - if yyhl294 { - yyb294 = yyj294 > l - } else { - yyb294 = r.CheckBreak() - } - if yyb294 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj294-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 { - yym312 := z.EncBinary() - _ = yym312 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep313 := !z.EncBinary() - yy2arr313 := z.EncBasicHandle().StructToArray - var yyq313 [2]bool - _, _, _ = yysep313, yyq313, yy2arr313 - const yyr313 bool = false - yyq313[1] = x.ReadOnly != false - var yynn313 int - if yyr313 || yy2arr313 { - r.EncodeArrayStart(2) - } else { - yynn313 = 1 - for _, b := range yyq313 { - if b { - yynn313++ - } - } - r.EncodeMapStart(yynn313) - yynn313 = 0 - } - if yyr313 || yy2arr313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym315 := z.EncBinary() - _ = yym315 - 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) - yym316 := z.EncBinary() - _ = yym316 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClaimName)) - } - } - if yyr313 || yy2arr313 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq313[1] { - yym318 := z.EncBinary() - _ = yym318 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq313[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym319 := z.EncBinary() - _ = yym319 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr313 || yy2arr313 { - 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 - yym320 := z.DecBinary() - _ = yym320 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct321 := r.ContainerType() - if yyct321 == codecSelferValueTypeMap1234 { - yyl321 := r.ReadMapStart() - if yyl321 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl321, d) - } - } else if yyct321 == codecSelferValueTypeArray1234 { - yyl321 := r.ReadArrayStart() - if yyl321 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl321, 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 yys322Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys322Slc - var yyhl322 bool = l >= 0 - for yyj322 := 0; ; yyj322++ { - if yyhl322 { - if yyj322 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys322Slc = r.DecodeBytes(yys322Slc, true, true) - yys322 := string(yys322Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys322 { - 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, yys322) - } // end switch yys322 - } // end for yyj322 - 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 yyj325 int - var yyb325 bool - var yyhl325 bool = l >= 0 - yyj325++ - if yyhl325 { - yyb325 = yyj325 > l - } else { - yyb325 = r.CheckBreak() - } - if yyb325 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClaimName = "" - } else { - x.ClaimName = string(r.DecodeString()) - } - yyj325++ - if yyhl325 { - yyb325 = yyj325 > l - } else { - yyb325 = r.CheckBreak() - } - if yyb325 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj325++ - if yyhl325 { - yyb325 = yyj325 > l - } else { - yyb325 = r.CheckBreak() - } - if yyb325 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj325-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 { - yym328 := z.EncBinary() - _ = yym328 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep329 := !z.EncBinary() - yy2arr329 := z.EncBasicHandle().StructToArray - var yyq329 [5]bool - _, _, _ = yysep329, yyq329, yy2arr329 - const yyr329 bool = false - yyq329[0] = x.Kind != "" - yyq329[1] = x.APIVersion != "" - yyq329[2] = true - yyq329[3] = true - yyq329[4] = true - var yynn329 int - if yyr329 || yy2arr329 { - r.EncodeArrayStart(5) - } else { - yynn329 = 0 - for _, b := range yyq329 { - if b { - yynn329++ - } - } - r.EncodeMapStart(yynn329) - yynn329 = 0 - } - if yyr329 || yy2arr329 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[0] { - yym331 := z.EncBinary() - _ = yym331 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq329[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym332 := z.EncBinary() - _ = yym332 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr329 || yy2arr329 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[1] { - yym334 := z.EncBinary() - _ = yym334 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq329[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym335 := z.EncBinary() - _ = yym335 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr329 || yy2arr329 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[2] { - yy337 := &x.ObjectMeta - yy337.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq329[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy338 := &x.ObjectMeta - yy338.CodecEncodeSelf(e) - } - } - if yyr329 || yy2arr329 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[3] { - yy340 := &x.Spec - yy340.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq329[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy341 := &x.Spec - yy341.CodecEncodeSelf(e) - } - } - if yyr329 || yy2arr329 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[4] { - yy343 := &x.Status - yy343.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq329[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy344 := &x.Status - yy344.CodecEncodeSelf(e) - } - } - if yyr329 || yy2arr329 { - 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 - yym345 := z.DecBinary() - _ = yym345 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct346 := r.ContainerType() - if yyct346 == codecSelferValueTypeMap1234 { - yyl346 := r.ReadMapStart() - if yyl346 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl346, d) - } - } else if yyct346 == codecSelferValueTypeArray1234 { - yyl346 := r.ReadArrayStart() - if yyl346 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl346, 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 yys347Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys347Slc - var yyhl347 bool = l >= 0 - for yyj347 := 0; ; yyj347++ { - if yyhl347 { - if yyj347 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys347Slc = r.DecodeBytes(yys347Slc, true, true) - yys347 := string(yys347Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys347 { - 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 { - yyv350 := &x.ObjectMeta - yyv350.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeSpec{} - } else { - yyv351 := &x.Spec - yyv351.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeStatus{} - } else { - yyv352 := &x.Status - yyv352.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys347) - } // end switch yys347 - } // end for yyj347 - 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 yyj353 int - var yyb353 bool - var yyhl353 bool = l >= 0 - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l - } else { - yyb353 = r.CheckBreak() - } - if yyb353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l - } else { - yyb353 = r.CheckBreak() - } - if yyb353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l - } else { - yyb353 = r.CheckBreak() - } - if yyb353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv356 := &x.ObjectMeta - yyv356.CodecDecodeSelf(d) - } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l - } else { - yyb353 = r.CheckBreak() - } - if yyb353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeSpec{} - } else { - yyv357 := &x.Spec - yyv357.CodecDecodeSelf(d) - } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l - } else { - yyb353 = r.CheckBreak() - } - if yyb353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeStatus{} - } else { - yyv358 := &x.Status - yyv358.CodecDecodeSelf(d) - } - for { - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l - } else { - yyb353 = r.CheckBreak() - } - if yyb353 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj353-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 { - yym359 := z.EncBinary() - _ = yym359 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep360 := !z.EncBinary() - yy2arr360 := z.EncBasicHandle().StructToArray - var yyq360 [21]bool - _, _, _ = yysep360, yyq360, yy2arr360 - const yyr360 bool = false - yyq360[1] = x.PersistentVolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil - yyq360[2] = x.PersistentVolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil - yyq360[3] = x.PersistentVolumeSource.HostPath != nil && x.HostPath != nil - yyq360[4] = x.PersistentVolumeSource.Glusterfs != nil && x.Glusterfs != nil - yyq360[5] = x.PersistentVolumeSource.NFS != nil && x.NFS != nil - yyq360[6] = x.PersistentVolumeSource.RBD != nil && x.RBD != nil - yyq360[7] = x.PersistentVolumeSource.Quobyte != nil && x.Quobyte != nil - yyq360[8] = x.PersistentVolumeSource.ISCSI != nil && x.ISCSI != nil - yyq360[9] = x.PersistentVolumeSource.FlexVolume != nil && x.FlexVolume != nil - yyq360[10] = x.PersistentVolumeSource.Cinder != nil && x.Cinder != nil - yyq360[11] = x.PersistentVolumeSource.CephFS != nil && x.CephFS != nil - yyq360[12] = x.PersistentVolumeSource.FC != nil && x.FC != nil - yyq360[13] = x.PersistentVolumeSource.Flocker != nil && x.Flocker != nil - yyq360[14] = x.PersistentVolumeSource.AzureFile != nil && x.AzureFile != nil - yyq360[15] = x.PersistentVolumeSource.VsphereVolume != nil && x.VsphereVolume != nil - yyq360[16] = x.PersistentVolumeSource.AzureDisk != nil && x.AzureDisk != nil - yyq360[17] = x.PersistentVolumeSource.PhotonPersistentDisk != nil && x.PhotonPersistentDisk != nil - yyq360[18] = len(x.AccessModes) != 0 - yyq360[19] = x.ClaimRef != nil - yyq360[20] = x.PersistentVolumeReclaimPolicy != "" - var yynn360 int - if yyr360 || yy2arr360 { - r.EncodeArrayStart(21) - } else { - yynn360 = 1 - for _, b := range yyq360 { - if b { - yynn360++ - } - } - r.EncodeMapStart(yynn360) - yynn360 = 0 - } - if yyr360 || yy2arr360 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - 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 yyn362 bool - if x.PersistentVolumeSource.GCEPersistentDisk == nil { - yyn362 = true - goto LABEL362 - } - LABEL362: - if yyr360 || yy2arr360 { - if yyn362 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[1] { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn362 { - r.EncodeNil() - } else { - if x.GCEPersistentDisk == nil { - r.EncodeNil() - } else { - x.GCEPersistentDisk.CodecEncodeSelf(e) - } - } - } - } - var yyn363 bool - if x.PersistentVolumeSource.AWSElasticBlockStore == nil { - yyn363 = true - goto LABEL363 - } - LABEL363: - if yyr360 || yy2arr360 { - if yyn363 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[2] { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn363 { - r.EncodeNil() - } else { - if x.AWSElasticBlockStore == nil { - r.EncodeNil() - } else { - x.AWSElasticBlockStore.CodecEncodeSelf(e) - } - } - } - } - var yyn364 bool - if x.PersistentVolumeSource.HostPath == nil { - yyn364 = true - goto LABEL364 - } - LABEL364: - if yyr360 || yy2arr360 { - if yyn364 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[3] { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn364 { - r.EncodeNil() - } else { - if x.HostPath == nil { - r.EncodeNil() - } else { - x.HostPath.CodecEncodeSelf(e) - } - } - } - } - var yyn365 bool - if x.PersistentVolumeSource.Glusterfs == nil { - yyn365 = true - goto LABEL365 - } - LABEL365: - if yyr360 || yy2arr360 { - if yyn365 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[4] { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn365 { - r.EncodeNil() - } else { - if x.Glusterfs == nil { - r.EncodeNil() - } else { - x.Glusterfs.CodecEncodeSelf(e) - } - } - } - } - var yyn366 bool - if x.PersistentVolumeSource.NFS == nil { - yyn366 = true - goto LABEL366 - } - LABEL366: - if yyr360 || yy2arr360 { - if yyn366 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[5] { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn366 { - r.EncodeNil() - } else { - if x.NFS == nil { - r.EncodeNil() - } else { - x.NFS.CodecEncodeSelf(e) - } - } - } - } - var yyn367 bool - if x.PersistentVolumeSource.RBD == nil { - yyn367 = true - goto LABEL367 - } - LABEL367: - if yyr360 || yy2arr360 { - if yyn367 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[6] { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rbd")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn367 { - r.EncodeNil() - } else { - if x.RBD == nil { - r.EncodeNil() - } else { - x.RBD.CodecEncodeSelf(e) - } - } - } - } - var yyn368 bool - if x.PersistentVolumeSource.Quobyte == nil { - yyn368 = true - goto LABEL368 - } - LABEL368: - if yyr360 || yy2arr360 { - if yyn368 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[7] { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("quobyte")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn368 { - r.EncodeNil() - } else { - if x.Quobyte == nil { - r.EncodeNil() - } else { - x.Quobyte.CodecEncodeSelf(e) - } - } - } - } - var yyn369 bool - if x.PersistentVolumeSource.ISCSI == nil { - yyn369 = true - goto LABEL369 - } - LABEL369: - if yyr360 || yy2arr360 { - if yyn369 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[8] { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iscsi")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn369 { - r.EncodeNil() - } else { - if x.ISCSI == nil { - r.EncodeNil() - } else { - x.ISCSI.CodecEncodeSelf(e) - } - } - } - } - var yyn370 bool - if x.PersistentVolumeSource.FlexVolume == nil { - yyn370 = true - goto LABEL370 - } - LABEL370: - if yyr360 || yy2arr360 { - if yyn370 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[9] { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn370 { - r.EncodeNil() - } else { - if x.FlexVolume == nil { - r.EncodeNil() - } else { - x.FlexVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn371 bool - if x.PersistentVolumeSource.Cinder == nil { - yyn371 = true - goto LABEL371 - } - LABEL371: - if yyr360 || yy2arr360 { - if yyn371 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[10] { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cinder")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn371 { - r.EncodeNil() - } else { - if x.Cinder == nil { - r.EncodeNil() - } else { - x.Cinder.CodecEncodeSelf(e) - } - } - } - } - var yyn372 bool - if x.PersistentVolumeSource.CephFS == nil { - yyn372 = true - goto LABEL372 - } - LABEL372: - if yyr360 || yy2arr360 { - if yyn372 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[11] { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cephfs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn372 { - r.EncodeNil() - } else { - if x.CephFS == nil { - r.EncodeNil() - } else { - x.CephFS.CodecEncodeSelf(e) - } - } - } - } - var yyn373 bool - if x.PersistentVolumeSource.FC == nil { - yyn373 = true - goto LABEL373 - } - LABEL373: - if yyr360 || yy2arr360 { - if yyn373 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[12] { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fc")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn373 { - r.EncodeNil() - } else { - if x.FC == nil { - r.EncodeNil() - } else { - x.FC.CodecEncodeSelf(e) - } - } - } - } - var yyn374 bool - if x.PersistentVolumeSource.Flocker == nil { - yyn374 = true - goto LABEL374 - } - LABEL374: - if yyr360 || yy2arr360 { - if yyn374 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[13] { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("flocker")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn374 { - r.EncodeNil() - } else { - if x.Flocker == nil { - r.EncodeNil() - } else { - x.Flocker.CodecEncodeSelf(e) - } - } - } - } - var yyn375 bool - if x.PersistentVolumeSource.AzureFile == nil { - yyn375 = true - goto LABEL375 - } - LABEL375: - if yyr360 || yy2arr360 { - if yyn375 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[14] { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureFile")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn375 { - r.EncodeNil() - } else { - if x.AzureFile == nil { - r.EncodeNil() - } else { - x.AzureFile.CodecEncodeSelf(e) - } - } - } - } - var yyn376 bool - if x.PersistentVolumeSource.VsphereVolume == nil { - yyn376 = true - goto LABEL376 - } - LABEL376: - if yyr360 || yy2arr360 { - if yyn376 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[15] { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn376 { - r.EncodeNil() - } else { - if x.VsphereVolume == nil { - r.EncodeNil() - } else { - x.VsphereVolume.CodecEncodeSelf(e) - } - } - } - } - var yyn377 bool - if x.PersistentVolumeSource.AzureDisk == nil { - yyn377 = true - goto LABEL377 - } - LABEL377: - if yyr360 || yy2arr360 { - if yyn377 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[16] { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn377 { - r.EncodeNil() - } else { - if x.AzureDisk == nil { - r.EncodeNil() - } else { - x.AzureDisk.CodecEncodeSelf(e) - } - } - } - } - var yyn378 bool - if x.PersistentVolumeSource.PhotonPersistentDisk == nil { - yyn378 = true - goto LABEL378 - } - LABEL378: - if yyr360 || yy2arr360 { - if yyn378 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[17] { - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq360[17] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn378 { - r.EncodeNil() - } else { - if x.PhotonPersistentDisk == nil { - r.EncodeNil() - } else { - x.PhotonPersistentDisk.CodecEncodeSelf(e) - } - } - } - } - if yyr360 || yy2arr360 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[18] { - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym380 := z.EncBinary() - _ = yym380 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq360[18] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("accessModes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym381 := z.EncBinary() - _ = yym381 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } - } - if yyr360 || yy2arr360 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[19] { - if x.ClaimRef == nil { - r.EncodeNil() - } else { - x.ClaimRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq360[19] { - 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 yyr360 || yy2arr360 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[20] { - x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq360[20] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeReclaimPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e) - } - } - if yyr360 || yy2arr360 { - 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 - yym384 := z.DecBinary() - _ = yym384 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct385 := r.ContainerType() - if yyct385 == codecSelferValueTypeMap1234 { - yyl385 := r.ReadMapStart() - if yyl385 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl385, d) - } - } else if yyct385 == codecSelferValueTypeArray1234 { - yyl385 := r.ReadArrayStart() - if yyl385 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl385, 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 yys386Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys386Slc - var yyhl386 bool = l >= 0 - for yyj386 := 0; ; yyj386++ { - if yyhl386 { - if yyj386 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys386Slc = r.DecodeBytes(yys386Slc, true, true) - yys386 := string(yys386Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys386 { - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv387 := &x.Capacity - yyv387.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 "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 "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 "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 "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 "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 "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 "photonPersistentDisk": - if x.PersistentVolumeSource.PhotonPersistentDisk == nil { - x.PersistentVolumeSource.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - case "accessModes": - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv405 := &x.AccessModes - yym406 := z.DecBinary() - _ = yym406 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv405), 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, yys386) - } // end switch yys386 - } // end for yyj386 - 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 yyj409 int - var yyb409 bool - var yyhl409 bool = l >= 0 - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv410 := &x.Capacity - yyv410.CodecDecodeSelf(d) - } - if x.PersistentVolumeSource.GCEPersistentDisk == nil { - x.PersistentVolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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.Quobyte == nil { - x.PersistentVolumeSource.Quobyte = new(QuobyteVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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.ISCSI == nil { - x.PersistentVolumeSource.ISCSI = new(ISCSIVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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.FlexVolume == nil { - x.PersistentVolumeSource.FlexVolume = new(FlexVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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.Cinder == nil { - x.PersistentVolumeSource.Cinder = new(CinderVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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.AzureFile == nil { - x.PersistentVolumeSource.AzureFile = new(AzureFileVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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.AzureDisk == nil { - x.PersistentVolumeSource.AzureDisk = new(AzureDiskVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - if x.PersistentVolumeSource.PhotonPersistentDisk == nil { - x.PersistentVolumeSource.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.PhotonPersistentDisk != nil { - x.PhotonPersistentDisk = nil - } - } else { - if x.PhotonPersistentDisk == nil { - x.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) - } - x.PhotonPersistentDisk.CodecDecodeSelf(d) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv428 := &x.AccessModes - yym429 := z.DecBinary() - _ = yym429 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv428), d) - } - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - 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) - } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PersistentVolumeReclaimPolicy = "" - } else { - x.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(r.DecodeString()) - } - for { - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l - } else { - yyb409 = r.CheckBreak() - } - if yyb409 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj409-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PersistentVolumeReclaimPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym432 := z.EncBinary() - _ = yym432 - 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 - yym433 := z.DecBinary() - _ = yym433 - 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 { - yym434 := z.EncBinary() - _ = yym434 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep435 := !z.EncBinary() - yy2arr435 := z.EncBasicHandle().StructToArray - var yyq435 [3]bool - _, _, _ = yysep435, yyq435, yy2arr435 - const yyr435 bool = false - yyq435[0] = x.Phase != "" - yyq435[1] = x.Message != "" - yyq435[2] = x.Reason != "" - var yynn435 int - if yyr435 || yy2arr435 { - r.EncodeArrayStart(3) - } else { - yynn435 = 0 - for _, b := range yyq435 { - if b { - yynn435++ - } - } - r.EncodeMapStart(yynn435) - yynn435 = 0 - } - if yyr435 || yy2arr435 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq435[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq435[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr435 || yy2arr435 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq435[1] { - yym438 := z.EncBinary() - _ = yym438 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq435[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym439 := z.EncBinary() - _ = yym439 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr435 || yy2arr435 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq435[2] { - yym441 := z.EncBinary() - _ = yym441 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq435[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym442 := z.EncBinary() - _ = yym442 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr435 || yy2arr435 { - 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 - yym443 := z.DecBinary() - _ = yym443 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct444 := r.ContainerType() - if yyct444 == codecSelferValueTypeMap1234 { - yyl444 := r.ReadMapStart() - if yyl444 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl444, d) - } - } else if yyct444 == codecSelferValueTypeArray1234 { - yyl444 := r.ReadArrayStart() - if yyl444 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl444, 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 yys445Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys445Slc - var yyhl445 bool = l >= 0 - for yyj445 := 0; ; yyj445++ { - if yyhl445 { - if yyj445 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys445Slc = r.DecodeBytes(yys445Slc, true, true) - yys445 := string(yys445Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys445 { - 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, yys445) - } // end switch yys445 - } // end for yyj445 - 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 yyj449 int - var yyb449 bool - var yyhl449 bool = l >= 0 - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PersistentVolumePhase(r.DecodeString()) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - for { - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj449-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 { - yym453 := z.EncBinary() - _ = yym453 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep454 := !z.EncBinary() - yy2arr454 := z.EncBasicHandle().StructToArray - var yyq454 [4]bool - _, _, _ = yysep454, yyq454, yy2arr454 - const yyr454 bool = false - yyq454[0] = x.Kind != "" - yyq454[1] = x.APIVersion != "" - yyq454[2] = true - var yynn454 int - if yyr454 || yy2arr454 { - r.EncodeArrayStart(4) - } else { - yynn454 = 1 - for _, b := range yyq454 { - if b { - yynn454++ - } - } - r.EncodeMapStart(yynn454) - yynn454 = 0 - } - if yyr454 || yy2arr454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq454[0] { - yym456 := z.EncBinary() - _ = yym456 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq454[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym457 := z.EncBinary() - _ = yym457 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr454 || yy2arr454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq454[1] { - yym459 := z.EncBinary() - _ = yym459 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq454[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym460 := z.EncBinary() - _ = yym460 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr454 || yy2arr454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq454[2] { - yy462 := &x.ListMeta - yym463 := z.EncBinary() - _ = yym463 - if false { - } else if z.HasExtensions() && z.EncExt(yy462) { - } else { - z.EncFallback(yy462) - } - } else { - r.EncodeNil() - } - } else { - if yyq454[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy464 := &x.ListMeta - yym465 := z.EncBinary() - _ = yym465 - if false { - } else if z.HasExtensions() && z.EncExt(yy464) { - } else { - z.EncFallback(yy464) - } - } - } - if yyr454 || yy2arr454 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym467 := z.EncBinary() - _ = yym467 - 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 { - yym468 := z.EncBinary() - _ = yym468 - if false { - } else { - h.encSlicePersistentVolume(([]PersistentVolume)(x.Items), e) - } - } - } - if yyr454 || yy2arr454 { - 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 - yym469 := z.DecBinary() - _ = yym469 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct470 := r.ContainerType() - if yyct470 == codecSelferValueTypeMap1234 { - yyl470 := r.ReadMapStart() - if yyl470 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl470, d) - } - } else if yyct470 == codecSelferValueTypeArray1234 { - yyl470 := r.ReadArrayStart() - if yyl470 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl470, 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 yys471Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys471Slc - var yyhl471 bool = l >= 0 - for yyj471 := 0; ; yyj471++ { - if yyhl471 { - if yyj471 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys471Slc = r.DecodeBytes(yys471Slc, true, true) - yys471 := string(yys471Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys471 { - 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 { - yyv474 := &x.ListMeta - yym475 := z.DecBinary() - _ = yym475 - if false { - } else if z.HasExtensions() && z.DecExt(yyv474) { - } else { - z.DecFallback(yyv474, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv476 := &x.Items - yym477 := z.DecBinary() - _ = yym477 - if false { - } else { - h.decSlicePersistentVolume((*[]PersistentVolume)(yyv476), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys471) - } // end switch yys471 - } // end for yyj471 - 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 yyj478 int - var yyb478 bool - var yyhl478 bool = l >= 0 - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l - } else { - yyb478 = r.CheckBreak() - } - if yyb478 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l - } else { - yyb478 = r.CheckBreak() - } - if yyb478 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l - } else { - yyb478 = r.CheckBreak() - } - if yyb478 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv481 := &x.ListMeta - yym482 := z.DecBinary() - _ = yym482 - if false { - } else if z.HasExtensions() && z.DecExt(yyv481) { - } else { - z.DecFallback(yyv481, false) - } - } - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l - } else { - yyb478 = r.CheckBreak() - } - if yyb478 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv483 := &x.Items - yym484 := z.DecBinary() - _ = yym484 - if false { - } else { - h.decSlicePersistentVolume((*[]PersistentVolume)(yyv483), d) - } - } - for { - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l - } else { - yyb478 = r.CheckBreak() - } - if yyb478 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj478-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 { - yym485 := z.EncBinary() - _ = yym485 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep486 := !z.EncBinary() - yy2arr486 := z.EncBasicHandle().StructToArray - var yyq486 [5]bool - _, _, _ = yysep486, yyq486, yy2arr486 - const yyr486 bool = false - yyq486[0] = x.Kind != "" - yyq486[1] = x.APIVersion != "" - yyq486[2] = true - yyq486[3] = true - yyq486[4] = true - var yynn486 int - if yyr486 || yy2arr486 { - r.EncodeArrayStart(5) - } else { - yynn486 = 0 - for _, b := range yyq486 { - if b { - yynn486++ - } - } - r.EncodeMapStart(yynn486) - yynn486 = 0 - } - if yyr486 || yy2arr486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[0] { - yym488 := z.EncBinary() - _ = yym488 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq486[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym489 := z.EncBinary() - _ = yym489 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr486 || yy2arr486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[1] { - yym491 := z.EncBinary() - _ = yym491 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq486[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym492 := z.EncBinary() - _ = yym492 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr486 || yy2arr486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[2] { - yy494 := &x.ObjectMeta - yy494.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq486[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy495 := &x.ObjectMeta - yy495.CodecEncodeSelf(e) - } - } - if yyr486 || yy2arr486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[3] { - yy497 := &x.Spec - yy497.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq486[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy498 := &x.Spec - yy498.CodecEncodeSelf(e) - } - } - if yyr486 || yy2arr486 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[4] { - yy500 := &x.Status - yy500.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq486[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy501 := &x.Status - yy501.CodecEncodeSelf(e) - } - } - if yyr486 || yy2arr486 { - 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 - yym502 := z.DecBinary() - _ = yym502 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct503 := r.ContainerType() - if yyct503 == codecSelferValueTypeMap1234 { - yyl503 := r.ReadMapStart() - if yyl503 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl503, d) - } - } else if yyct503 == codecSelferValueTypeArray1234 { - yyl503 := r.ReadArrayStart() - if yyl503 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl503, 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 yys504Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys504Slc - var yyhl504 bool = l >= 0 - for yyj504 := 0; ; yyj504++ { - if yyhl504 { - if yyj504 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys504Slc = r.DecodeBytes(yys504Slc, true, true) - yys504 := string(yys504Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys504 { - 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 { - yyv507 := &x.ObjectMeta - yyv507.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeClaimSpec{} - } else { - yyv508 := &x.Spec - yyv508.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeClaimStatus{} - } else { - yyv509 := &x.Status - yyv509.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys504) - } // end switch yys504 - } // end for yyj504 - 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 yyj510 int - var yyb510 bool - var yyhl510 bool = l >= 0 - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l - } else { - yyb510 = r.CheckBreak() - } - if yyb510 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l - } else { - yyb510 = r.CheckBreak() - } - if yyb510 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l - } else { - yyb510 = r.CheckBreak() - } - if yyb510 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv513 := &x.ObjectMeta - yyv513.CodecDecodeSelf(d) - } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l - } else { - yyb510 = r.CheckBreak() - } - if yyb510 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PersistentVolumeClaimSpec{} - } else { - yyv514 := &x.Spec - yyv514.CodecDecodeSelf(d) - } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l - } else { - yyb510 = r.CheckBreak() - } - if yyb510 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PersistentVolumeClaimStatus{} - } else { - yyv515 := &x.Status - yyv515.CodecDecodeSelf(d) - } - for { - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l - } else { - yyb510 = r.CheckBreak() - } - if yyb510 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj510-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 { - yym516 := z.EncBinary() - _ = yym516 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep517 := !z.EncBinary() - yy2arr517 := z.EncBasicHandle().StructToArray - var yyq517 [4]bool - _, _, _ = yysep517, yyq517, yy2arr517 - const yyr517 bool = false - yyq517[0] = x.Kind != "" - yyq517[1] = x.APIVersion != "" - yyq517[2] = true - var yynn517 int - if yyr517 || yy2arr517 { - r.EncodeArrayStart(4) - } else { - yynn517 = 1 - for _, b := range yyq517 { - if b { - yynn517++ - } - } - r.EncodeMapStart(yynn517) - yynn517 = 0 - } - if yyr517 || yy2arr517 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq517[0] { - yym519 := z.EncBinary() - _ = yym519 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq517[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym520 := z.EncBinary() - _ = yym520 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr517 || yy2arr517 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq517[1] { - yym522 := z.EncBinary() - _ = yym522 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq517[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym523 := z.EncBinary() - _ = yym523 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr517 || yy2arr517 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq517[2] { - yy525 := &x.ListMeta - yym526 := z.EncBinary() - _ = yym526 - if false { - } else if z.HasExtensions() && z.EncExt(yy525) { - } else { - z.EncFallback(yy525) - } - } else { - r.EncodeNil() - } - } else { - if yyq517[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy527 := &x.ListMeta - yym528 := z.EncBinary() - _ = yym528 - if false { - } else if z.HasExtensions() && z.EncExt(yy527) { - } else { - z.EncFallback(yy527) - } - } - } - if yyr517 || yy2arr517 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym530 := z.EncBinary() - _ = yym530 - 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 { - yym531 := z.EncBinary() - _ = yym531 - if false { - } else { - h.encSlicePersistentVolumeClaim(([]PersistentVolumeClaim)(x.Items), e) - } - } - } - if yyr517 || yy2arr517 { - 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 - yym532 := z.DecBinary() - _ = yym532 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct533 := r.ContainerType() - if yyct533 == codecSelferValueTypeMap1234 { - yyl533 := r.ReadMapStart() - if yyl533 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl533, d) - } - } else if yyct533 == codecSelferValueTypeArray1234 { - yyl533 := r.ReadArrayStart() - if yyl533 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl533, 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 yys534Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys534Slc - var yyhl534 bool = l >= 0 - for yyj534 := 0; ; yyj534++ { - if yyhl534 { - if yyj534 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys534Slc = r.DecodeBytes(yys534Slc, true, true) - yys534 := string(yys534Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys534 { - 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 { - yyv537 := &x.ListMeta - yym538 := z.DecBinary() - _ = yym538 - if false { - } else if z.HasExtensions() && z.DecExt(yyv537) { - } else { - z.DecFallback(yyv537, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv539 := &x.Items - yym540 := z.DecBinary() - _ = yym540 - if false { - } else { - h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv539), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys534) - } // end switch yys534 - } // end for yyj534 - 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 yyj541 int - var yyb541 bool - var yyhl541 bool = l >= 0 - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv544 := &x.ListMeta - yym545 := z.DecBinary() - _ = yym545 - if false { - } else if z.HasExtensions() && z.DecExt(yyv544) { - } else { - z.DecFallback(yyv544, false) - } - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv546 := &x.Items - yym547 := z.DecBinary() - _ = yym547 - if false { - } else { - h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv546), d) - } - } - for { - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj541-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 { - yym548 := z.EncBinary() - _ = yym548 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep549 := !z.EncBinary() - yy2arr549 := z.EncBasicHandle().StructToArray - var yyq549 [4]bool - _, _, _ = yysep549, yyq549, yy2arr549 - const yyr549 bool = false - yyq549[0] = len(x.AccessModes) != 0 - yyq549[1] = x.Selector != nil - yyq549[2] = true - yyq549[3] = x.VolumeName != "" - var yynn549 int - if yyr549 || yy2arr549 { - r.EncodeArrayStart(4) - } else { - yynn549 = 0 - for _, b := range yyq549 { - if b { - yynn549++ - } - } - r.EncodeMapStart(yynn549) - yynn549 = 0 - } - if yyr549 || yy2arr549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[0] { - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym551 := z.EncBinary() - _ = yym551 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq549[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("accessModes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym552 := z.EncBinary() - _ = yym552 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } - } - if yyr549 || yy2arr549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym554 := z.EncBinary() - _ = yym554 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq549[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym555 := z.EncBinary() - _ = yym555 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr549 || yy2arr549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[2] { - yy557 := &x.Resources - yy557.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq549[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resources")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy558 := &x.Resources - yy558.CodecEncodeSelf(e) - } - } - if yyr549 || yy2arr549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[3] { - yym560 := z.EncBinary() - _ = yym560 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq549[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumeName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym561 := z.EncBinary() - _ = yym561 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) - } - } - } - if yyr549 || yy2arr549 { - 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 - yym562 := z.DecBinary() - _ = yym562 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct563 := r.ContainerType() - if yyct563 == codecSelferValueTypeMap1234 { - yyl563 := r.ReadMapStart() - if yyl563 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl563, d) - } - } else if yyct563 == codecSelferValueTypeArray1234 { - yyl563 := r.ReadArrayStart() - if yyl563 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl563, 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 yys564Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys564Slc - var yyhl564 bool = l >= 0 - for yyj564 := 0; ; yyj564++ { - if yyhl564 { - if yyj564 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys564Slc = r.DecodeBytes(yys564Slc, true, true) - yys564 := string(yys564Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys564 { - case "accessModes": - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv565 := &x.AccessModes - yym566 := z.DecBinary() - _ = yym566 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv565), d) - } - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) - } - yym568 := z.DecBinary() - _ = yym568 - 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 { - yyv569 := &x.Resources - yyv569.CodecDecodeSelf(d) - } - case "volumeName": - if r.TryDecodeAsNil() { - x.VolumeName = "" - } else { - x.VolumeName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys564) - } // end switch yys564 - } // end for yyj564 - 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 yyj571 int - var yyb571 bool - var yyhl571 bool = l >= 0 - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l - } else { - yyb571 = r.CheckBreak() - } - if yyb571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv572 := &x.AccessModes - yym573 := z.DecBinary() - _ = yym573 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv572), d) - } - } - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l - } else { - yyb571 = r.CheckBreak() - } - if yyb571 { - 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) - } - yym575 := z.DecBinary() - _ = yym575 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l - } else { - yyb571 = r.CheckBreak() - } - if yyb571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Resources = ResourceRequirements{} - } else { - yyv576 := &x.Resources - yyv576.CodecDecodeSelf(d) - } - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l - } else { - yyb571 = r.CheckBreak() - } - if yyb571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeName = "" - } else { - x.VolumeName = string(r.DecodeString()) - } - for { - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l - } else { - yyb571 = r.CheckBreak() - } - if yyb571 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj571-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 { - yym578 := z.EncBinary() - _ = yym578 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep579 := !z.EncBinary() - yy2arr579 := z.EncBasicHandle().StructToArray - var yyq579 [3]bool - _, _, _ = yysep579, yyq579, yy2arr579 - const yyr579 bool = false - yyq579[0] = x.Phase != "" - yyq579[1] = len(x.AccessModes) != 0 - yyq579[2] = len(x.Capacity) != 0 - var yynn579 int - if yyr579 || yy2arr579 { - r.EncodeArrayStart(3) - } else { - yynn579 = 0 - for _, b := range yyq579 { - if b { - yynn579++ - } - } - r.EncodeMapStart(yynn579) - yynn579 = 0 - } - if yyr579 || yy2arr579 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq579[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq579[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr579 || yy2arr579 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq579[1] { - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym582 := z.EncBinary() - _ = yym582 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq579[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("accessModes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AccessModes == nil { - r.EncodeNil() - } else { - yym583 := z.EncBinary() - _ = yym583 - if false { - } else { - h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) - } - } - } - } - if yyr579 || yy2arr579 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq579[2] { - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq579[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 yyr579 || yy2arr579 { - 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 - yym585 := z.DecBinary() - _ = yym585 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct586 := r.ContainerType() - if yyct586 == codecSelferValueTypeMap1234 { - yyl586 := r.ReadMapStart() - if yyl586 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl586, d) - } - } else if yyct586 == codecSelferValueTypeArray1234 { - yyl586 := r.ReadArrayStart() - if yyl586 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl586, 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 yys587Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys587Slc - var yyhl587 bool = l >= 0 - for yyj587 := 0; ; yyj587++ { - if yyhl587 { - if yyj587 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys587Slc = r.DecodeBytes(yys587Slc, true, true) - yys587 := string(yys587Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys587 { - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PersistentVolumeClaimPhase(r.DecodeString()) - } - case "accessModes": - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv589 := &x.AccessModes - yym590 := z.DecBinary() - _ = yym590 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv589), d) - } - } - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv591 := &x.Capacity - yyv591.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys587) - } // end switch yys587 - } // end for yyj587 - 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 yyj592 int - var yyb592 bool - var yyhl592 bool = l >= 0 - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l - } else { - yyb592 = r.CheckBreak() - } - if yyb592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PersistentVolumeClaimPhase(r.DecodeString()) - } - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l - } else { - yyb592 = r.CheckBreak() - } - if yyb592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AccessModes = nil - } else { - yyv594 := &x.AccessModes - yym595 := z.DecBinary() - _ = yym595 - if false { - } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv594), d) - } - } - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l - } else { - yyb592 = r.CheckBreak() - } - if yyb592 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv596 := &x.Capacity - yyv596.CodecDecodeSelf(d) - } - for { - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l - } else { - yyb592 = r.CheckBreak() - } - if yyb592 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj592-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PersistentVolumeAccessMode) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym597 := z.EncBinary() - _ = yym597 - 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 - yym598 := z.DecBinary() - _ = yym598 - 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 - yym599 := z.EncBinary() - _ = yym599 - 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 - yym600 := z.DecBinary() - _ = yym600 - 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 - yym601 := z.EncBinary() - _ = yym601 - 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 - yym602 := z.DecBinary() - _ = yym602 - 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 { - yym603 := z.EncBinary() - _ = yym603 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep604 := !z.EncBinary() - yy2arr604 := z.EncBasicHandle().StructToArray - var yyq604 [1]bool - _, _, _ = yysep604, yyq604, yy2arr604 - const yyr604 bool = false - var yynn604 int - if yyr604 || yy2arr604 { - r.EncodeArrayStart(1) - } else { - yynn604 = 1 - for _, b := range yyq604 { - if b { - yynn604++ - } - } - r.EncodeMapStart(yynn604) - yynn604 = 0 - } - if yyr604 || yy2arr604 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym606 := z.EncBinary() - _ = yym606 - 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) - yym607 := z.EncBinary() - _ = yym607 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr604 || yy2arr604 { - 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 - yym608 := z.DecBinary() - _ = yym608 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct609 := r.ContainerType() - if yyct609 == codecSelferValueTypeMap1234 { - yyl609 := r.ReadMapStart() - if yyl609 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl609, d) - } - } else if yyct609 == codecSelferValueTypeArray1234 { - yyl609 := r.ReadArrayStart() - if yyl609 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl609, 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 yys610Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys610Slc - var yyhl610 bool = l >= 0 - for yyj610 := 0; ; yyj610++ { - if yyhl610 { - if yyj610 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys610Slc = r.DecodeBytes(yys610Slc, true, true) - yys610 := string(yys610Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys610 { - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys610) - } // end switch yys610 - } // end for yyj610 - 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 yyj612 int - var yyb612 bool - var yyhl612 bool = l >= 0 - yyj612++ - if yyhl612 { - yyb612 = yyj612 > l - } else { - yyb612 = r.CheckBreak() - } - if yyb612 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj612++ - if yyhl612 { - yyb612 = yyj612 > l - } else { - yyb612 = r.CheckBreak() - } - if yyb612 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj612-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 { - yym614 := z.EncBinary() - _ = yym614 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep615 := !z.EncBinary() - yy2arr615 := z.EncBasicHandle().StructToArray - var yyq615 [1]bool - _, _, _ = yysep615, yyq615, yy2arr615 - const yyr615 bool = false - yyq615[0] = x.Medium != "" - var yynn615 int - if yyr615 || yy2arr615 { - r.EncodeArrayStart(1) - } else { - yynn615 = 0 - for _, b := range yyq615 { - if b { - yynn615++ - } - } - r.EncodeMapStart(yynn615) - yynn615 = 0 - } - if yyr615 || yy2arr615 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq615[0] { - x.Medium.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq615[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("medium")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Medium.CodecEncodeSelf(e) - } - } - if yyr615 || yy2arr615 { - 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 - yym617 := z.DecBinary() - _ = yym617 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct618 := r.ContainerType() - if yyct618 == codecSelferValueTypeMap1234 { - yyl618 := r.ReadMapStart() - if yyl618 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl618, d) - } - } else if yyct618 == codecSelferValueTypeArray1234 { - yyl618 := r.ReadArrayStart() - if yyl618 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl618, 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 yys619Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys619Slc - var yyhl619 bool = l >= 0 - for yyj619 := 0; ; yyj619++ { - if yyhl619 { - if yyj619 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys619Slc = r.DecodeBytes(yys619Slc, true, true) - yys619 := string(yys619Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys619 { - case "medium": - if r.TryDecodeAsNil() { - x.Medium = "" - } else { - x.Medium = StorageMedium(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys619) - } // end switch yys619 - } // end for yyj619 - 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 yyj621 int - var yyb621 bool - var yyhl621 bool = l >= 0 - yyj621++ - if yyhl621 { - yyb621 = yyj621 > l - } else { - yyb621 = r.CheckBreak() - } - if yyb621 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Medium = "" - } else { - x.Medium = StorageMedium(r.DecodeString()) - } - for { - yyj621++ - if yyhl621 { - yyb621 = yyj621 > l - } else { - yyb621 = r.CheckBreak() - } - if yyb621 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj621-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x StorageMedium) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym623 := z.EncBinary() - _ = yym623 - 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 - yym624 := z.DecBinary() - _ = yym624 - 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 - yym625 := z.EncBinary() - _ = yym625 - 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 - yym626 := z.DecBinary() - _ = yym626 - 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 { - yym627 := z.EncBinary() - _ = yym627 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep628 := !z.EncBinary() - yy2arr628 := z.EncBasicHandle().StructToArray - var yyq628 [4]bool - _, _, _ = yysep628, yyq628, yy2arr628 - const yyr628 bool = false - yyq628[1] = x.FSType != "" - yyq628[2] = x.Partition != 0 - yyq628[3] = x.ReadOnly != false - var yynn628 int - if yyr628 || yy2arr628 { - r.EncodeArrayStart(4) - } else { - yynn628 = 1 - for _, b := range yyq628 { - if b { - yynn628++ - } - } - r.EncodeMapStart(yynn628) - yynn628 = 0 - } - if yyr628 || yy2arr628 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym630 := z.EncBinary() - _ = yym630 - 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) - yym631 := z.EncBinary() - _ = yym631 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PDName)) - } - } - if yyr628 || yy2arr628 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq628[1] { - yym633 := z.EncBinary() - _ = yym633 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq628[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym634 := z.EncBinary() - _ = yym634 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr628 || yy2arr628 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq628[2] { - yym636 := z.EncBinary() - _ = yym636 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq628[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("partition")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym637 := z.EncBinary() - _ = yym637 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } - } - if yyr628 || yy2arr628 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq628[3] { - yym639 := z.EncBinary() - _ = yym639 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq628[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym640 := z.EncBinary() - _ = yym640 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr628 || yy2arr628 { - 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 - yym641 := z.DecBinary() - _ = yym641 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct642 := r.ContainerType() - if yyct642 == codecSelferValueTypeMap1234 { - yyl642 := r.ReadMapStart() - if yyl642 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl642, d) - } - } else if yyct642 == codecSelferValueTypeArray1234 { - yyl642 := r.ReadArrayStart() - if yyl642 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl642, 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 yys643Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys643Slc - var yyhl643 bool = l >= 0 - for yyj643 := 0; ; yyj643++ { - if yyhl643 { - if yyj643 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys643Slc = r.DecodeBytes(yys643Slc, true, true) - yys643 := string(yys643Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys643 { - 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, yys643) - } // end switch yys643 - } // end for yyj643 - 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 yyj648 int - var yyb648 bool - var yyhl648 bool = l >= 0 - yyj648++ - if yyhl648 { - yyb648 = yyj648 > l - } else { - yyb648 = r.CheckBreak() - } - if yyb648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PDName = "" - } else { - x.PDName = string(r.DecodeString()) - } - yyj648++ - if yyhl648 { - yyb648 = yyj648 > l - } else { - yyb648 = r.CheckBreak() - } - if yyb648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj648++ - if yyhl648 { - yyb648 = yyj648 > l - } else { - yyb648 = r.CheckBreak() - } - if yyb648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Partition = 0 - } else { - x.Partition = int32(r.DecodeInt(32)) - } - yyj648++ - if yyhl648 { - yyb648 = yyj648 > l - } else { - yyb648 = r.CheckBreak() - } - if yyb648 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj648++ - if yyhl648 { - yyb648 = yyj648 > l - } else { - yyb648 = r.CheckBreak() - } - if yyb648 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj648-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 { - yym653 := z.EncBinary() - _ = yym653 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep654 := !z.EncBinary() - yy2arr654 := z.EncBasicHandle().StructToArray - var yyq654 [6]bool - _, _, _ = yysep654, yyq654, yy2arr654 - const yyr654 bool = false - yyq654[0] = x.TargetPortal != "" - yyq654[1] = x.IQN != "" - yyq654[2] = x.Lun != 0 - yyq654[3] = x.ISCSIInterface != "" - yyq654[4] = x.FSType != "" - yyq654[5] = x.ReadOnly != false - var yynn654 int - if yyr654 || yy2arr654 { - r.EncodeArrayStart(6) - } else { - yynn654 = 0 - for _, b := range yyq654 { - if b { - yynn654++ - } - } - r.EncodeMapStart(yynn654) - yynn654 = 0 - } - if yyr654 || yy2arr654 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq654[0] { - yym656 := z.EncBinary() - _ = yym656 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq654[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("targetPortal")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym657 := z.EncBinary() - _ = yym657 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal)) - } - } - } - if yyr654 || yy2arr654 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq654[1] { - yym659 := z.EncBinary() - _ = yym659 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq654[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iqn")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym660 := z.EncBinary() - _ = yym660 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) - } - } - } - if yyr654 || yy2arr654 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq654[2] { - yym662 := z.EncBinary() - _ = yym662 - if false { - } else { - r.EncodeInt(int64(x.Lun)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq654[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lun")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym663 := z.EncBinary() - _ = yym663 - if false { - } else { - r.EncodeInt(int64(x.Lun)) - } - } - } - if yyr654 || yy2arr654 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq654[3] { - yym665 := z.EncBinary() - _ = yym665 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq654[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iscsiInterface")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym666 := z.EncBinary() - _ = yym666 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) - } - } - } - if yyr654 || yy2arr654 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq654[4] { - yym668 := z.EncBinary() - _ = yym668 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq654[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym669 := z.EncBinary() - _ = yym669 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr654 || yy2arr654 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq654[5] { - yym671 := z.EncBinary() - _ = yym671 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq654[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym672 := z.EncBinary() - _ = yym672 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr654 || yy2arr654 { - 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 - yym673 := z.DecBinary() - _ = yym673 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct674 := r.ContainerType() - if yyct674 == codecSelferValueTypeMap1234 { - yyl674 := r.ReadMapStart() - if yyl674 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl674, d) - } - } else if yyct674 == codecSelferValueTypeArray1234 { - yyl674 := r.ReadArrayStart() - if yyl674 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl674, 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 yys675Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys675Slc - var yyhl675 bool = l >= 0 - for yyj675 := 0; ; yyj675++ { - if yyhl675 { - if yyj675 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys675Slc = r.DecodeBytes(yys675Slc, true, true) - yys675 := string(yys675Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys675 { - 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, yys675) - } // end switch yys675 - } // end for yyj675 - 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 yyj682 int - var yyb682 bool - var yyhl682 bool = l >= 0 - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetPortal = "" - } else { - x.TargetPortal = string(r.DecodeString()) - } - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.IQN = "" - } else { - x.IQN = string(r.DecodeString()) - } - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Lun = 0 - } else { - x.Lun = int32(r.DecodeInt(32)) - } - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ISCSIInterface = "" - } else { - x.ISCSIInterface = string(r.DecodeString()) - } - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj682++ - if yyhl682 { - yyb682 = yyj682 > l - } else { - yyb682 = r.CheckBreak() - } - if yyb682 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj682-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 { - yym689 := z.EncBinary() - _ = yym689 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep690 := !z.EncBinary() - yy2arr690 := z.EncBasicHandle().StructToArray - var yyq690 [4]bool - _, _, _ = yysep690, yyq690, yy2arr690 - const yyr690 bool = false - yyq690[2] = x.FSType != "" - yyq690[3] = x.ReadOnly != false - var yynn690 int - if yyr690 || yy2arr690 { - r.EncodeArrayStart(4) - } else { - yynn690 = 2 - for _, b := range yyq690 { - if b { - yynn690++ - } - } - r.EncodeMapStart(yynn690) - yynn690 = 0 - } - if yyr690 || yy2arr690 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.TargetWWNs == nil { - r.EncodeNil() - } else { - yym692 := z.EncBinary() - _ = yym692 - 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 { - yym693 := z.EncBinary() - _ = yym693 - if false { - } else { - z.F.EncSliceStringV(x.TargetWWNs, false, e) - } - } - } - if yyr690 || yy2arr690 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Lun == nil { - r.EncodeNil() - } else { - yy695 := *x.Lun - yym696 := z.EncBinary() - _ = yym696 - if false { - } else { - r.EncodeInt(int64(yy695)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lun")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Lun == nil { - r.EncodeNil() - } else { - yy697 := *x.Lun - yym698 := z.EncBinary() - _ = yym698 - if false { - } else { - r.EncodeInt(int64(yy697)) - } - } - } - if yyr690 || yy2arr690 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq690[2] { - yym700 := z.EncBinary() - _ = yym700 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq690[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym701 := z.EncBinary() - _ = yym701 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr690 || yy2arr690 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq690[3] { - yym703 := z.EncBinary() - _ = yym703 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq690[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym704 := z.EncBinary() - _ = yym704 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr690 || yy2arr690 { - 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 - yym705 := z.DecBinary() - _ = yym705 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct706 := r.ContainerType() - if yyct706 == codecSelferValueTypeMap1234 { - yyl706 := r.ReadMapStart() - if yyl706 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl706, d) - } - } else if yyct706 == codecSelferValueTypeArray1234 { - yyl706 := r.ReadArrayStart() - if yyl706 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl706, 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 yys707Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys707Slc - var yyhl707 bool = l >= 0 - for yyj707 := 0; ; yyj707++ { - if yyhl707 { - if yyj707 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys707Slc = r.DecodeBytes(yys707Slc, true, true) - yys707 := string(yys707Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys707 { - case "targetWWNs": - if r.TryDecodeAsNil() { - x.TargetWWNs = nil - } else { - yyv708 := &x.TargetWWNs - yym709 := z.DecBinary() - _ = yym709 - if false { - } else { - z.F.DecSliceStringX(yyv708, false, d) - } - } - case "lun": - if r.TryDecodeAsNil() { - if x.Lun != nil { - x.Lun = nil - } - } else { - if x.Lun == nil { - x.Lun = new(int32) - } - yym711 := z.DecBinary() - _ = yym711 - 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, yys707) - } // end switch yys707 - } // end for yyj707 - 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 yyj714 int - var yyb714 bool - var yyhl714 bool = l >= 0 - yyj714++ - if yyhl714 { - yyb714 = yyj714 > l - } else { - yyb714 = r.CheckBreak() - } - if yyb714 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetWWNs = nil - } else { - yyv715 := &x.TargetWWNs - yym716 := z.DecBinary() - _ = yym716 - if false { - } else { - z.F.DecSliceStringX(yyv715, false, d) - } - } - yyj714++ - if yyhl714 { - yyb714 = yyj714 > l - } else { - yyb714 = r.CheckBreak() - } - if yyb714 { - 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) - } - yym718 := z.DecBinary() - _ = yym718 - if false { - } else { - *((*int32)(x.Lun)) = int32(r.DecodeInt(32)) - } - } - yyj714++ - if yyhl714 { - yyb714 = yyj714 > l - } else { - yyb714 = r.CheckBreak() - } - if yyb714 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj714++ - if yyhl714 { - yyb714 = yyj714 > l - } else { - yyb714 = r.CheckBreak() - } - if yyb714 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj714++ - if yyhl714 { - yyb714 = yyj714 > l - } else { - yyb714 = r.CheckBreak() - } - if yyb714 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj714-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 { - yym721 := z.EncBinary() - _ = yym721 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep722 := !z.EncBinary() - yy2arr722 := z.EncBasicHandle().StructToArray - var yyq722 [5]bool - _, _, _ = yysep722, yyq722, yy2arr722 - const yyr722 bool = false - yyq722[1] = x.FSType != "" - yyq722[2] = x.SecretRef != nil - yyq722[3] = x.ReadOnly != false - yyq722[4] = len(x.Options) != 0 - var yynn722 int - if yyr722 || yy2arr722 { - r.EncodeArrayStart(5) - } else { - yynn722 = 1 - for _, b := range yyq722 { - if b { - yynn722++ - } - } - r.EncodeMapStart(yynn722) - yynn722 = 0 - } - if yyr722 || yy2arr722 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym724 := z.EncBinary() - _ = yym724 - 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) - yym725 := z.EncBinary() - _ = yym725 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Driver)) - } - } - if yyr722 || yy2arr722 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq722[1] { - yym727 := z.EncBinary() - _ = yym727 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq722[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym728 := z.EncBinary() - _ = yym728 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr722 || yy2arr722 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq722[2] { - if x.SecretRef == nil { - r.EncodeNil() - } else { - x.SecretRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq722[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 yyr722 || yy2arr722 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq722[3] { - yym731 := z.EncBinary() - _ = yym731 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq722[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym732 := z.EncBinary() - _ = yym732 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr722 || yy2arr722 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq722[4] { - if x.Options == nil { - r.EncodeNil() - } else { - yym734 := z.EncBinary() - _ = yym734 - if false { - } else { - z.F.EncMapStringStringV(x.Options, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq722[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("options")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Options == nil { - r.EncodeNil() - } else { - yym735 := z.EncBinary() - _ = yym735 - if false { - } else { - z.F.EncMapStringStringV(x.Options, false, e) - } - } - } - } - if yyr722 || yy2arr722 { - 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 - yym736 := z.DecBinary() - _ = yym736 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct737 := r.ContainerType() - if yyct737 == codecSelferValueTypeMap1234 { - yyl737 := r.ReadMapStart() - if yyl737 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl737, d) - } - } else if yyct737 == codecSelferValueTypeArray1234 { - yyl737 := r.ReadArrayStart() - if yyl737 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl737, 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 yys738Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys738Slc - var yyhl738 bool = l >= 0 - for yyj738 := 0; ; yyj738++ { - if yyhl738 { - if yyj738 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys738Slc = r.DecodeBytes(yys738Slc, true, true) - yys738 := string(yys738Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys738 { - 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 { - yyv743 := &x.Options - yym744 := z.DecBinary() - _ = yym744 - if false { - } else { - z.F.DecMapStringStringX(yyv743, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys738) - } // end switch yys738 - } // end for yyj738 - 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 yyj745 int - var yyb745 bool - var yyhl745 bool = l >= 0 - yyj745++ - if yyhl745 { - yyb745 = yyj745 > l - } else { - yyb745 = r.CheckBreak() - } - if yyb745 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Driver = "" - } else { - x.Driver = string(r.DecodeString()) - } - yyj745++ - if yyhl745 { - yyb745 = yyj745 > l - } else { - yyb745 = r.CheckBreak() - } - if yyb745 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj745++ - if yyhl745 { - yyb745 = yyj745 > l - } else { - yyb745 = r.CheckBreak() - } - if yyb745 { - 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) - } - yyj745++ - if yyhl745 { - yyb745 = yyj745 > l - } else { - yyb745 = r.CheckBreak() - } - if yyb745 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - yyj745++ - if yyhl745 { - yyb745 = yyj745 > l - } else { - yyb745 = r.CheckBreak() - } - if yyb745 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Options = nil - } else { - yyv750 := &x.Options - yym751 := z.DecBinary() - _ = yym751 - if false { - } else { - z.F.DecMapStringStringX(yyv750, false, d) - } - } - for { - yyj745++ - if yyhl745 { - yyb745 = yyj745 > l - } else { - yyb745 = r.CheckBreak() - } - if yyb745 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj745-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 { - yym752 := z.EncBinary() - _ = yym752 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep753 := !z.EncBinary() - yy2arr753 := z.EncBasicHandle().StructToArray - var yyq753 [4]bool - _, _, _ = yysep753, yyq753, yy2arr753 - const yyr753 bool = false - yyq753[1] = x.FSType != "" - yyq753[2] = x.Partition != 0 - yyq753[3] = x.ReadOnly != false - var yynn753 int - if yyr753 || yy2arr753 { - r.EncodeArrayStart(4) - } else { - yynn753 = 1 - for _, b := range yyq753 { - if b { - yynn753++ - } - } - r.EncodeMapStart(yynn753) - yynn753 = 0 - } - if yyr753 || yy2arr753 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym755 := z.EncBinary() - _ = yym755 - 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) - yym756 := z.EncBinary() - _ = yym756 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) - } - } - if yyr753 || yy2arr753 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq753[1] { - yym758 := z.EncBinary() - _ = yym758 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq753[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym759 := z.EncBinary() - _ = yym759 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr753 || yy2arr753 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq753[2] { - yym761 := z.EncBinary() - _ = yym761 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq753[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("partition")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym762 := z.EncBinary() - _ = yym762 - if false { - } else { - r.EncodeInt(int64(x.Partition)) - } - } - } - if yyr753 || yy2arr753 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq753[3] { - yym764 := z.EncBinary() - _ = yym764 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq753[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym765 := z.EncBinary() - _ = yym765 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr753 || yy2arr753 { - 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 - yym766 := z.DecBinary() - _ = yym766 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct767 := r.ContainerType() - if yyct767 == codecSelferValueTypeMap1234 { - yyl767 := r.ReadMapStart() - if yyl767 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl767, d) - } - } else if yyct767 == codecSelferValueTypeArray1234 { - yyl767 := r.ReadArrayStart() - if yyl767 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl767, 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 yys768Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys768Slc - var yyhl768 bool = l >= 0 - for yyj768 := 0; ; yyj768++ { - if yyhl768 { - if yyj768 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys768Slc = r.DecodeBytes(yys768Slc, true, true) - yys768 := string(yys768Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys768 { - 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, yys768) - } // end switch yys768 - } // end for yyj768 - 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 yyj773 int - var yyb773 bool - var yyhl773 bool = l >= 0 - yyj773++ - if yyhl773 { - yyb773 = yyj773 > l - } else { - yyb773 = r.CheckBreak() - } - if yyb773 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeID = "" - } else { - x.VolumeID = string(r.DecodeString()) - } - yyj773++ - if yyhl773 { - yyb773 = yyj773 > l - } else { - yyb773 = r.CheckBreak() - } - if yyb773 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj773++ - if yyhl773 { - yyb773 = yyj773 > l - } else { - yyb773 = r.CheckBreak() - } - if yyb773 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Partition = 0 - } else { - x.Partition = int32(r.DecodeInt(32)) - } - yyj773++ - if yyhl773 { - yyb773 = yyj773 > l - } else { - yyb773 = r.CheckBreak() - } - if yyb773 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj773++ - if yyhl773 { - yyb773 = yyj773 > l - } else { - yyb773 = r.CheckBreak() - } - if yyb773 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj773-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 { - yym778 := z.EncBinary() - _ = yym778 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep779 := !z.EncBinary() - yy2arr779 := z.EncBasicHandle().StructToArray - var yyq779 [3]bool - _, _, _ = yysep779, yyq779, yy2arr779 - const yyr779 bool = false - yyq779[1] = x.Revision != "" - yyq779[2] = x.Directory != "" - var yynn779 int - if yyr779 || yy2arr779 { - r.EncodeArrayStart(3) - } else { - yynn779 = 1 - for _, b := range yyq779 { - if b { - yynn779++ - } - } - r.EncodeMapStart(yynn779) - yynn779 = 0 - } - if yyr779 || yy2arr779 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym781 := z.EncBinary() - _ = yym781 - 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) - yym782 := z.EncBinary() - _ = yym782 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Repository)) - } - } - if yyr779 || yy2arr779 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq779[1] { - yym784 := z.EncBinary() - _ = yym784 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Revision)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq779[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revision")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym785 := z.EncBinary() - _ = yym785 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Revision)) - } - } - } - if yyr779 || yy2arr779 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq779[2] { - yym787 := z.EncBinary() - _ = yym787 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Directory)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq779[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("directory")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym788 := z.EncBinary() - _ = yym788 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Directory)) - } - } - } - if yyr779 || yy2arr779 { - 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 - yym789 := z.DecBinary() - _ = yym789 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct790 := r.ContainerType() - if yyct790 == codecSelferValueTypeMap1234 { - yyl790 := r.ReadMapStart() - if yyl790 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl790, d) - } - } else if yyct790 == codecSelferValueTypeArray1234 { - yyl790 := r.ReadArrayStart() - if yyl790 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl790, 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 yys791Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys791Slc - var yyhl791 bool = l >= 0 - for yyj791 := 0; ; yyj791++ { - if yyhl791 { - if yyj791 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys791Slc = r.DecodeBytes(yys791Slc, true, true) - yys791 := string(yys791Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys791 { - 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, yys791) - } // end switch yys791 - } // end for yyj791 - 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 yyj795 int - var yyb795 bool - var yyhl795 bool = l >= 0 - yyj795++ - if yyhl795 { - yyb795 = yyj795 > l - } else { - yyb795 = r.CheckBreak() - } - if yyb795 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Repository = "" - } else { - x.Repository = string(r.DecodeString()) - } - yyj795++ - if yyhl795 { - yyb795 = yyj795 > l - } else { - yyb795 = r.CheckBreak() - } - if yyb795 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Revision = "" - } else { - x.Revision = string(r.DecodeString()) - } - yyj795++ - if yyhl795 { - yyb795 = yyj795 > l - } else { - yyb795 = r.CheckBreak() - } - if yyb795 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Directory = "" - } else { - x.Directory = string(r.DecodeString()) - } - for { - yyj795++ - if yyhl795 { - yyb795 = yyj795 > l - } else { - yyb795 = r.CheckBreak() - } - if yyb795 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj795-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 { - yym799 := z.EncBinary() - _ = yym799 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep800 := !z.EncBinary() - yy2arr800 := z.EncBasicHandle().StructToArray - var yyq800 [3]bool - _, _, _ = yysep800, yyq800, yy2arr800 - const yyr800 bool = false - yyq800[0] = x.SecretName != "" - yyq800[1] = len(x.Items) != 0 - yyq800[2] = x.DefaultMode != nil - var yynn800 int - if yyr800 || yy2arr800 { - r.EncodeArrayStart(3) - } else { - yynn800 = 0 - for _, b := range yyq800 { - if b { - yynn800++ - } - } - r.EncodeMapStart(yynn800) - yynn800 = 0 - } - if yyr800 || yy2arr800 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq800[0] { - yym802 := z.EncBinary() - _ = yym802 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq800[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym803 := z.EncBinary() - _ = yym803 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } - } - if yyr800 || yy2arr800 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq800[1] { - if x.Items == nil { - r.EncodeNil() - } else { - yym805 := z.EncBinary() - _ = yym805 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq800[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym806 := z.EncBinary() - _ = yym806 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } - } - if yyr800 || yy2arr800 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq800[2] { - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy808 := *x.DefaultMode - yym809 := z.EncBinary() - _ = yym809 - if false { - } else { - r.EncodeInt(int64(yy808)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq800[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy810 := *x.DefaultMode - yym811 := z.EncBinary() - _ = yym811 - if false { - } else { - r.EncodeInt(int64(yy810)) - } - } - } - } - if yyr800 || yy2arr800 { - 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 - yym812 := z.DecBinary() - _ = yym812 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct813 := r.ContainerType() - if yyct813 == codecSelferValueTypeMap1234 { - yyl813 := r.ReadMapStart() - if yyl813 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl813, d) - } - } else if yyct813 == codecSelferValueTypeArray1234 { - yyl813 := r.ReadArrayStart() - if yyl813 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl813, 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 yys814Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys814Slc - var yyhl814 bool = l >= 0 - for yyj814 := 0; ; yyj814++ { - if yyhl814 { - if yyj814 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys814Slc = r.DecodeBytes(yys814Slc, true, true) - yys814 := string(yys814Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys814 { - case "secretName": - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv816 := &x.Items - yym817 := z.DecBinary() - _ = yym817 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv816), d) - } - } - case "defaultMode": - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym819 := z.DecBinary() - _ = yym819 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys814) - } // end switch yys814 - } // end for yyj814 - 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 yyj820 int - var yyb820 bool - var yyhl820 bool = l >= 0 - yyj820++ - if yyhl820 { - yyb820 = yyj820 > l - } else { - yyb820 = r.CheckBreak() - } - if yyb820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - yyj820++ - if yyhl820 { - yyb820 = yyj820 > l - } else { - yyb820 = r.CheckBreak() - } - if yyb820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv822 := &x.Items - yym823 := z.DecBinary() - _ = yym823 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv822), d) - } - } - yyj820++ - if yyhl820 { - yyb820 = yyj820 > l - } else { - yyb820 = r.CheckBreak() - } - if yyb820 { - 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) - } - yym825 := z.DecBinary() - _ = yym825 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj820++ - if yyhl820 { - yyb820 = yyj820 > l - } else { - yyb820 = r.CheckBreak() - } - if yyb820 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj820-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 { - yym826 := z.EncBinary() - _ = yym826 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep827 := !z.EncBinary() - yy2arr827 := z.EncBasicHandle().StructToArray - var yyq827 [3]bool - _, _, _ = yysep827, yyq827, yy2arr827 - const yyr827 bool = false - yyq827[2] = x.ReadOnly != false - var yynn827 int - if yyr827 || yy2arr827 { - r.EncodeArrayStart(3) - } else { - yynn827 = 2 - for _, b := range yyq827 { - if b { - yynn827++ - } - } - r.EncodeMapStart(yynn827) - yynn827 = 0 - } - if yyr827 || yy2arr827 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym829 := z.EncBinary() - _ = yym829 - 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) - yym830 := z.EncBinary() - _ = yym830 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Server)) - } - } - if yyr827 || yy2arr827 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym832 := z.EncBinary() - _ = yym832 - 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) - yym833 := z.EncBinary() - _ = yym833 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr827 || yy2arr827 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq827[2] { - yym835 := z.EncBinary() - _ = yym835 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq827[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym836 := z.EncBinary() - _ = yym836 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr827 || yy2arr827 { - 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 - yym837 := z.DecBinary() - _ = yym837 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct838 := r.ContainerType() - if yyct838 == codecSelferValueTypeMap1234 { - yyl838 := r.ReadMapStart() - if yyl838 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl838, d) - } - } else if yyct838 == codecSelferValueTypeArray1234 { - yyl838 := r.ReadArrayStart() - if yyl838 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl838, 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 yys839Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys839Slc - var yyhl839 bool = l >= 0 - for yyj839 := 0; ; yyj839++ { - if yyhl839 { - if yyj839 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys839Slc = r.DecodeBytes(yys839Slc, true, true) - yys839 := string(yys839Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys839 { - 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, yys839) - } // end switch yys839 - } // end for yyj839 - 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 yyj843 int - var yyb843 bool - var yyhl843 bool = l >= 0 - yyj843++ - if yyhl843 { - yyb843 = yyj843 > l - } else { - yyb843 = r.CheckBreak() - } - if yyb843 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Server = "" - } else { - x.Server = string(r.DecodeString()) - } - yyj843++ - if yyhl843 { - yyb843 = yyj843 > l - } else { - yyb843 = r.CheckBreak() - } - if yyb843 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj843++ - if yyhl843 { - yyb843 = yyj843 > l - } else { - yyb843 = r.CheckBreak() - } - if yyb843 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj843++ - if yyhl843 { - yyb843 = yyj843 > l - } else { - yyb843 = r.CheckBreak() - } - if yyb843 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj843-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 { - yym847 := z.EncBinary() - _ = yym847 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep848 := !z.EncBinary() - yy2arr848 := z.EncBasicHandle().StructToArray - var yyq848 [5]bool - _, _, _ = yysep848, yyq848, yy2arr848 - const yyr848 bool = false - yyq848[2] = x.ReadOnly != false - yyq848[3] = x.User != "" - yyq848[4] = x.Group != "" - var yynn848 int - if yyr848 || yy2arr848 { - r.EncodeArrayStart(5) - } else { - yynn848 = 2 - for _, b := range yyq848 { - if b { - yynn848++ - } - } - r.EncodeMapStart(yynn848) - yynn848 = 0 - } - if yyr848 || yy2arr848 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym850 := z.EncBinary() - _ = yym850 - 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) - yym851 := z.EncBinary() - _ = yym851 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Registry)) - } - } - if yyr848 || yy2arr848 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym853 := z.EncBinary() - _ = yym853 - 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) - yym854 := z.EncBinary() - _ = yym854 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Volume)) - } - } - if yyr848 || yy2arr848 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq848[2] { - yym856 := z.EncBinary() - _ = yym856 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq848[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym857 := z.EncBinary() - _ = yym857 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr848 || yy2arr848 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq848[3] { - yym859 := z.EncBinary() - _ = yym859 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq848[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym860 := z.EncBinary() - _ = yym860 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - } - if yyr848 || yy2arr848 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq848[4] { - yym862 := z.EncBinary() - _ = yym862 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Group)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq848[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("group")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym863 := z.EncBinary() - _ = yym863 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Group)) - } - } - } - if yyr848 || yy2arr848 { - 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 - yym864 := z.DecBinary() - _ = yym864 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct865 := r.ContainerType() - if yyct865 == codecSelferValueTypeMap1234 { - yyl865 := r.ReadMapStart() - if yyl865 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl865, d) - } - } else if yyct865 == codecSelferValueTypeArray1234 { - yyl865 := r.ReadArrayStart() - if yyl865 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl865, 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 yys866Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys866Slc - var yyhl866 bool = l >= 0 - for yyj866 := 0; ; yyj866++ { - if yyhl866 { - if yyj866 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys866Slc = r.DecodeBytes(yys866Slc, true, true) - yys866 := string(yys866Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys866 { - 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, yys866) - } // end switch yys866 - } // end for yyj866 - 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 yyj872 int - var yyb872 bool - var yyhl872 bool = l >= 0 - yyj872++ - if yyhl872 { - yyb872 = yyj872 > l - } else { - yyb872 = r.CheckBreak() - } - if yyb872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Registry = "" - } else { - x.Registry = string(r.DecodeString()) - } - yyj872++ - if yyhl872 { - yyb872 = yyj872 > l - } else { - yyb872 = r.CheckBreak() - } - if yyb872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Volume = "" - } else { - x.Volume = string(r.DecodeString()) - } - yyj872++ - if yyhl872 { - yyb872 = yyj872 > l - } else { - yyb872 = r.CheckBreak() - } - if yyb872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - yyj872++ - if yyhl872 { - yyb872 = yyj872 > l - } else { - yyb872 = r.CheckBreak() - } - if yyb872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - yyj872++ - if yyhl872 { - yyb872 = yyj872 > l - } else { - yyb872 = r.CheckBreak() - } - if yyb872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Group = "" - } else { - x.Group = string(r.DecodeString()) - } - for { - yyj872++ - if yyhl872 { - yyb872 = yyj872 > l - } else { - yyb872 = r.CheckBreak() - } - if yyb872 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj872-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 { - yym878 := z.EncBinary() - _ = yym878 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep879 := !z.EncBinary() - yy2arr879 := z.EncBasicHandle().StructToArray - var yyq879 [3]bool - _, _, _ = yysep879, yyq879, yy2arr879 - const yyr879 bool = false - yyq879[2] = x.ReadOnly != false - var yynn879 int - if yyr879 || yy2arr879 { - r.EncodeArrayStart(3) - } else { - yynn879 = 2 - for _, b := range yyq879 { - if b { - yynn879++ - } - } - r.EncodeMapStart(yynn879) - yynn879 = 0 - } - if yyr879 || yy2arr879 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym881 := z.EncBinary() - _ = yym881 - 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) - yym882 := z.EncBinary() - _ = yym882 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.EndpointsName)) - } - } - if yyr879 || yy2arr879 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym884 := z.EncBinary() - _ = yym884 - 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) - yym885 := z.EncBinary() - _ = yym885 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr879 || yy2arr879 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq879[2] { - yym887 := z.EncBinary() - _ = yym887 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq879[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym888 := z.EncBinary() - _ = yym888 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr879 || yy2arr879 { - 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 - yym889 := z.DecBinary() - _ = yym889 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct890 := r.ContainerType() - if yyct890 == codecSelferValueTypeMap1234 { - yyl890 := r.ReadMapStart() - if yyl890 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl890, d) - } - } else if yyct890 == codecSelferValueTypeArray1234 { - yyl890 := r.ReadArrayStart() - if yyl890 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl890, 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 yys891Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys891Slc - var yyhl891 bool = l >= 0 - for yyj891 := 0; ; yyj891++ { - if yyhl891 { - if yyj891 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys891Slc = r.DecodeBytes(yys891Slc, true, true) - yys891 := string(yys891Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys891 { - 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, yys891) - } // end switch yys891 - } // end for yyj891 - 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 yyj895 int - var yyb895 bool - var yyhl895 bool = l >= 0 - yyj895++ - if yyhl895 { - yyb895 = yyj895 > l - } else { - yyb895 = r.CheckBreak() - } - if yyb895 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.EndpointsName = "" - } else { - x.EndpointsName = string(r.DecodeString()) - } - yyj895++ - if yyhl895 { - yyb895 = yyj895 > l - } else { - yyb895 = r.CheckBreak() - } - if yyb895 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj895++ - if yyhl895 { - yyb895 = yyj895 > l - } else { - yyb895 = r.CheckBreak() - } - if yyb895 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj895++ - if yyhl895 { - yyb895 = yyj895 > l - } else { - yyb895 = r.CheckBreak() - } - if yyb895 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj895-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 { - yym899 := z.EncBinary() - _ = yym899 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep900 := !z.EncBinary() - yy2arr900 := z.EncBasicHandle().StructToArray - var yyq900 [8]bool - _, _, _ = yysep900, yyq900, yy2arr900 - const yyr900 bool = false - yyq900[2] = x.FSType != "" - yyq900[3] = x.RBDPool != "" - yyq900[4] = x.RadosUser != "" - yyq900[5] = x.Keyring != "" - yyq900[6] = x.SecretRef != nil - yyq900[7] = x.ReadOnly != false - var yynn900 int - if yyr900 || yy2arr900 { - r.EncodeArrayStart(8) - } else { - yynn900 = 2 - for _, b := range yyq900 { - if b { - yynn900++ - } - } - r.EncodeMapStart(yynn900) - yynn900 = 0 - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.CephMonitors == nil { - r.EncodeNil() - } else { - yym902 := z.EncBinary() - _ = yym902 - 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 { - yym903 := z.EncBinary() - _ = yym903 - if false { - } else { - z.F.EncSliceStringV(x.CephMonitors, false, e) - } - } - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym905 := z.EncBinary() - _ = yym905 - 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) - yym906 := z.EncBinary() - _ = yym906 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RBDImage)) - } - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq900[2] { - yym908 := z.EncBinary() - _ = yym908 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq900[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym909 := z.EncBinary() - _ = yym909 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq900[3] { - yym911 := z.EncBinary() - _ = yym911 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq900[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("pool")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym912 := z.EncBinary() - _ = yym912 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool)) - } - } - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq900[4] { - yym914 := z.EncBinary() - _ = yym914 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq900[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym915 := z.EncBinary() - _ = yym915 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser)) - } - } - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq900[5] { - yym917 := z.EncBinary() - _ = yym917 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Keyring)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq900[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("keyring")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym918 := z.EncBinary() - _ = yym918 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Keyring)) - } - } - } - if yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq900[6] { - if x.SecretRef == nil { - r.EncodeNil() - } else { - x.SecretRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq900[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 yyr900 || yy2arr900 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq900[7] { - yym921 := z.EncBinary() - _ = yym921 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq900[7] { - 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 yyr900 || yy2arr900 { - 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 - 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 *RBDVolumeSource) 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 "monitors": - if r.TryDecodeAsNil() { - x.CephMonitors = nil - } else { - yyv926 := &x.CephMonitors - yym927 := z.DecBinary() - _ = yym927 - if false { - } else { - z.F.DecSliceStringX(yyv926, 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, yys925) - } // end switch yys925 - } // end for yyj925 - 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 yyj935 int - var yyb935 bool - var yyhl935 bool = l >= 0 - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CephMonitors = nil - } else { - yyv936 := &x.CephMonitors - yym937 := z.DecBinary() - _ = yym937 - if false { - } else { - z.F.DecSliceStringX(yyv936, false, d) - } - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RBDImage = "" - } else { - x.RBDImage = string(r.DecodeString()) - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RBDPool = "" - } else { - x.RBDPool = string(r.DecodeString()) - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RadosUser = "" - } else { - x.RadosUser = string(r.DecodeString()) - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Keyring = "" - } else { - x.Keyring = string(r.DecodeString()) - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - 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) - } - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj935++ - if yyhl935 { - yyb935 = yyj935 > l - } else { - yyb935 = r.CheckBreak() - } - if yyb935 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj935-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 { - yym945 := z.EncBinary() - _ = yym945 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep946 := !z.EncBinary() - yy2arr946 := z.EncBasicHandle().StructToArray - var yyq946 [3]bool - _, _, _ = yysep946, yyq946, yy2arr946 - const yyr946 bool = false - yyq946[1] = x.FSType != "" - yyq946[2] = x.ReadOnly != false - var yynn946 int - if yyr946 || yy2arr946 { - r.EncodeArrayStart(3) - } else { - yynn946 = 1 - for _, b := range yyq946 { - if b { - yynn946++ - } - } - r.EncodeMapStart(yynn946) - yynn946 = 0 - } - if yyr946 || yy2arr946 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym948 := z.EncBinary() - _ = yym948 - 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) - yym949 := z.EncBinary() - _ = yym949 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) - } - } - if yyr946 || yy2arr946 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq946[1] { - yym951 := z.EncBinary() - _ = yym951 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq946[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym952 := z.EncBinary() - _ = yym952 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr946 || yy2arr946 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq946[2] { - yym954 := z.EncBinary() - _ = yym954 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq946[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym955 := z.EncBinary() - _ = yym955 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr946 || yy2arr946 { - 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 - yym956 := z.DecBinary() - _ = yym956 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct957 := r.ContainerType() - if yyct957 == codecSelferValueTypeMap1234 { - yyl957 := r.ReadMapStart() - if yyl957 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl957, d) - } - } else if yyct957 == codecSelferValueTypeArray1234 { - yyl957 := r.ReadArrayStart() - if yyl957 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl957, 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 yys958Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys958Slc - var yyhl958 bool = l >= 0 - for yyj958 := 0; ; yyj958++ { - if yyhl958 { - if yyj958 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys958Slc = r.DecodeBytes(yys958Slc, true, true) - yys958 := string(yys958Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys958 { - 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, yys958) - } // end switch yys958 - } // end for yyj958 - 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 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.VolumeID = "" - } else { - x.VolumeID = 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 *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym966 := z.EncBinary() - _ = yym966 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep967 := !z.EncBinary() - yy2arr967 := z.EncBasicHandle().StructToArray - var yyq967 [6]bool - _, _, _ = yysep967, yyq967, yy2arr967 - const yyr967 bool = false - yyq967[1] = x.Path != "" - yyq967[2] = x.User != "" - yyq967[3] = x.SecretFile != "" - yyq967[4] = x.SecretRef != nil - yyq967[5] = x.ReadOnly != false - var yynn967 int - if yyr967 || yy2arr967 { - r.EncodeArrayStart(6) - } else { - yynn967 = 1 - for _, b := range yyq967 { - if b { - yynn967++ - } - } - r.EncodeMapStart(yynn967) - yynn967 = 0 - } - if yyr967 || yy2arr967 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Monitors == nil { - r.EncodeNil() - } else { - yym969 := z.EncBinary() - _ = yym969 - 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 { - yym970 := z.EncBinary() - _ = yym970 - if false { - } else { - z.F.EncSliceStringV(x.Monitors, false, e) - } - } - } - if yyr967 || yy2arr967 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq967[1] { - yym972 := z.EncBinary() - _ = yym972 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq967[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym973 := z.EncBinary() - _ = yym973 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr967 || yy2arr967 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq967[2] { - yym975 := z.EncBinary() - _ = yym975 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq967[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym976 := z.EncBinary() - _ = yym976 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - } - if yyr967 || yy2arr967 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq967[3] { - yym978 := z.EncBinary() - _ = yym978 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq967[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretFile")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym979 := z.EncBinary() - _ = yym979 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile)) - } - } - } - if yyr967 || yy2arr967 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq967[4] { - if x.SecretRef == nil { - r.EncodeNil() - } else { - x.SecretRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq967[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 yyr967 || yy2arr967 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq967[5] { - yym982 := z.EncBinary() - _ = yym982 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq967[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym983 := z.EncBinary() - _ = yym983 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr967 || yy2arr967 { - 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 - yym984 := z.DecBinary() - _ = yym984 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct985 := r.ContainerType() - if yyct985 == codecSelferValueTypeMap1234 { - yyl985 := r.ReadMapStart() - if yyl985 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl985, d) - } - } else if yyct985 == codecSelferValueTypeArray1234 { - yyl985 := r.ReadArrayStart() - if yyl985 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl985, 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 yys986Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys986Slc - var yyhl986 bool = l >= 0 - for yyj986 := 0; ; yyj986++ { - if yyhl986 { - if yyj986 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys986Slc = r.DecodeBytes(yys986Slc, true, true) - yys986 := string(yys986Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys986 { - case "monitors": - if r.TryDecodeAsNil() { - x.Monitors = nil - } else { - yyv987 := &x.Monitors - yym988 := z.DecBinary() - _ = yym988 - if false { - } else { - z.F.DecSliceStringX(yyv987, 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, yys986) - } // end switch yys986 - } // end for yyj986 - 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 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.Monitors = nil - } else { - yyv995 := &x.Monitors - 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() { - x.Path = "" - } else { - x.Path = 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.User = "" - } else { - x.User = 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.SecretFile = "" - } else { - x.SecretFile = 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() { - if x.SecretRef != nil { - x.SecretRef = nil - } - } else { - if x.SecretRef == nil { - x.SecretRef = new(LocalObjectReference) - } - x.SecretRef.CodecDecodeSelf(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() { - 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 *FlockerVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1002 := z.EncBinary() - _ = yym1002 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1003 := !z.EncBinary() - yy2arr1003 := z.EncBasicHandle().StructToArray - var yyq1003 [2]bool - _, _, _ = yysep1003, yyq1003, yy2arr1003 - const yyr1003 bool = false - yyq1003[0] = x.DatasetName != "" - yyq1003[1] = x.DatasetUUID != "" - var yynn1003 int - if yyr1003 || yy2arr1003 { - r.EncodeArrayStart(2) - } else { - yynn1003 = 0 - for _, b := range yyq1003 { - if b { - yynn1003++ - } - } - r.EncodeMapStart(yynn1003) - yynn1003 = 0 - } - if yyr1003 || yy2arr1003 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1003[0] { - yym1005 := z.EncBinary() - _ = yym1005 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1003[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("datasetName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1006 := z.EncBinary() - _ = yym1006 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName)) - } - } - } - if yyr1003 || yy2arr1003 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1003[1] { - yym1008 := z.EncBinary() - _ = yym1008 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DatasetUUID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1003[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("datasetUUID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1009 := z.EncBinary() - _ = yym1009 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DatasetUUID)) - } - } - } - if yyr1003 || yy2arr1003 { - 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 - yym1010 := z.DecBinary() - _ = yym1010 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1011 := r.ContainerType() - if yyct1011 == codecSelferValueTypeMap1234 { - yyl1011 := r.ReadMapStart() - if yyl1011 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1011, d) - } - } else if yyct1011 == codecSelferValueTypeArray1234 { - yyl1011 := r.ReadArrayStart() - if yyl1011 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1011, 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 yys1012Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1012Slc - var yyhl1012 bool = l >= 0 - for yyj1012 := 0; ; yyj1012++ { - if yyhl1012 { - if yyj1012 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1012Slc = r.DecodeBytes(yys1012Slc, true, true) - yys1012 := string(yys1012Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1012 { - case "datasetName": - if r.TryDecodeAsNil() { - x.DatasetName = "" - } else { - x.DatasetName = string(r.DecodeString()) - } - case "datasetUUID": - if r.TryDecodeAsNil() { - x.DatasetUUID = "" - } else { - x.DatasetUUID = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1012) - } // end switch yys1012 - } // end for yyj1012 - 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 yyj1015 int - var yyb1015 bool - var yyhl1015 bool = l >= 0 - yyj1015++ - if yyhl1015 { - yyb1015 = yyj1015 > l - } else { - yyb1015 = r.CheckBreak() - } - if yyb1015 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DatasetName = "" - } else { - x.DatasetName = string(r.DecodeString()) - } - yyj1015++ - if yyhl1015 { - yyb1015 = yyj1015 > l - } else { - yyb1015 = r.CheckBreak() - } - if yyb1015 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DatasetUUID = "" - } else { - x.DatasetUUID = string(r.DecodeString()) - } - for { - yyj1015++ - if yyhl1015 { - yyb1015 = yyj1015 > l - } else { - yyb1015 = r.CheckBreak() - } - if yyb1015 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1015-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 { - yym1018 := z.EncBinary() - _ = yym1018 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1019 := !z.EncBinary() - yy2arr1019 := z.EncBasicHandle().StructToArray - var yyq1019 [2]bool - _, _, _ = yysep1019, yyq1019, yy2arr1019 - const yyr1019 bool = false - yyq1019[0] = len(x.Items) != 0 - yyq1019[1] = x.DefaultMode != nil - var yynn1019 int - if yyr1019 || yy2arr1019 { - r.EncodeArrayStart(2) - } else { - yynn1019 = 0 - for _, b := range yyq1019 { - if b { - yynn1019++ - } - } - r.EncodeMapStart(yynn1019) - yynn1019 = 0 - } - if yyr1019 || yy2arr1019 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1019[0] { - if x.Items == nil { - r.EncodeNil() - } else { - yym1021 := z.EncBinary() - _ = yym1021 - if false { - } else { - h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1019[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1022 := z.EncBinary() - _ = yym1022 - if false { - } else { - h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) - } - } - } - } - if yyr1019 || yy2arr1019 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1019[1] { - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy1024 := *x.DefaultMode - yym1025 := z.EncBinary() - _ = yym1025 - if false { - } else { - r.EncodeInt(int64(yy1024)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1019[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy1026 := *x.DefaultMode - yym1027 := z.EncBinary() - _ = yym1027 - if false { - } else { - r.EncodeInt(int64(yy1026)) - } - } - } - } - if yyr1019 || yy2arr1019 { - 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 - yym1028 := z.DecBinary() - _ = yym1028 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1029 := r.ContainerType() - if yyct1029 == codecSelferValueTypeMap1234 { - yyl1029 := r.ReadMapStart() - if yyl1029 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1029, d) - } - } else if yyct1029 == codecSelferValueTypeArray1234 { - yyl1029 := r.ReadArrayStart() - if yyl1029 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1029, 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 yys1030Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1030Slc - var yyhl1030 bool = l >= 0 - for yyj1030 := 0; ; yyj1030++ { - if yyhl1030 { - if yyj1030 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1030Slc = r.DecodeBytes(yys1030Slc, true, true) - yys1030 := string(yys1030Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1030 { - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1031 := &x.Items - yym1032 := z.DecBinary() - _ = yym1032 - if false { - } else { - h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv1031), d) - } - } - case "defaultMode": - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym1034 := z.DecBinary() - _ = yym1034 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys1030) - } // end switch yys1030 - } // end for yyj1030 - 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 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.Items = nil - } else { - yyv1036 := &x.Items - yym1037 := z.DecBinary() - _ = yym1037 - if false { - } else { - h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv1036), d) - } - } - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l - } else { - yyb1035 = r.CheckBreak() - } - if yyb1035 { - 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) - } - yym1039 := z.DecBinary() - _ = yym1039 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - 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 *DownwardAPIVolumeFile) 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 [4]bool - _, _, _ = yysep1041, yyq1041, yy2arr1041 - const yyr1041 bool = false - yyq1041[1] = x.FieldRef != nil - yyq1041[2] = x.ResourceFieldRef != nil - yyq1041[3] = x.Mode != nil - var yynn1041 int - if yyr1041 || yy2arr1041 { - r.EncodeArrayStart(4) - } else { - yynn1041 = 1 - 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.Path)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1044 := z.EncBinary() - _ = yym1044 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1041[1] { - if x.FieldRef == nil { - r.EncodeNil() - } else { - x.FieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1041[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 yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1041[2] { - if x.ResourceFieldRef == nil { - r.EncodeNil() - } else { - x.ResourceFieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1041[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 yyr1041 || yy2arr1041 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1041[3] { - if x.Mode == nil { - r.EncodeNil() - } else { - yy1048 := *x.Mode - yym1049 := z.EncBinary() - _ = yym1049 - if false { - } else { - r.EncodeInt(int64(yy1048)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1041[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("mode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Mode == nil { - r.EncodeNil() - } else { - yy1050 := *x.Mode - yym1051 := z.EncBinary() - _ = yym1051 - if false { - } else { - r.EncodeInt(int64(yy1050)) - } - } - } - } - if yyr1041 || yy2arr1041 { - 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 - yym1052 := z.DecBinary() - _ = yym1052 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1053 := r.ContainerType() - if yyct1053 == codecSelferValueTypeMap1234 { - yyl1053 := r.ReadMapStart() - if yyl1053 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1053, d) - } - } else if yyct1053 == codecSelferValueTypeArray1234 { - yyl1053 := r.ReadArrayStart() - if yyl1053 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1053, 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 yys1054Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1054Slc - var yyhl1054 bool = l >= 0 - for yyj1054 := 0; ; yyj1054++ { - if yyhl1054 { - if yyj1054 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1054Slc = r.DecodeBytes(yys1054Slc, true, true) - yys1054 := string(yys1054Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1054 { - 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) - } - yym1059 := z.DecBinary() - _ = yym1059 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys1054) - } // end switch yys1054 - } // end for yyj1054 - 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 yyj1060 int - var yyb1060 bool - var yyhl1060 bool = l >= 0 - yyj1060++ - if yyhl1060 { - yyb1060 = yyj1060 > l - } else { - yyb1060 = r.CheckBreak() - } - if yyb1060 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj1060++ - if yyhl1060 { - yyb1060 = yyj1060 > l - } else { - yyb1060 = r.CheckBreak() - } - if yyb1060 { - 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) - } - yyj1060++ - if yyhl1060 { - yyb1060 = yyj1060 > l - } else { - yyb1060 = r.CheckBreak() - } - if yyb1060 { - 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) - } - yyj1060++ - if yyhl1060 { - yyb1060 = yyj1060 > l - } else { - yyb1060 = r.CheckBreak() - } - if yyb1060 { - 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) - } - yym1065 := z.DecBinary() - _ = yym1065 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj1060++ - if yyhl1060 { - yyb1060 = yyj1060 > l - } else { - yyb1060 = r.CheckBreak() - } - if yyb1060 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1060-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 { - yym1066 := z.EncBinary() - _ = yym1066 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1067 := !z.EncBinary() - yy2arr1067 := z.EncBasicHandle().StructToArray - var yyq1067 [3]bool - _, _, _ = yysep1067, yyq1067, yy2arr1067 - const yyr1067 bool = false - yyq1067[2] = x.ReadOnly != false - var yynn1067 int - if yyr1067 || yy2arr1067 { - r.EncodeArrayStart(3) - } else { - yynn1067 = 2 - for _, b := range yyq1067 { - if b { - yynn1067++ - } - } - r.EncodeMapStart(yynn1067) - yynn1067 = 0 - } - if yyr1067 || yy2arr1067 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1069 := z.EncBinary() - _ = yym1069 - 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) - yym1070 := z.EncBinary() - _ = yym1070 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } - if yyr1067 || yy2arr1067 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1072 := z.EncBinary() - _ = yym1072 - 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) - yym1073 := z.EncBinary() - _ = yym1073 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ShareName)) - } - } - if yyr1067 || yy2arr1067 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1067[2] { - yym1075 := z.EncBinary() - _ = yym1075 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1067[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1076 := z.EncBinary() - _ = yym1076 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr1067 || yy2arr1067 { - 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 - yym1077 := z.DecBinary() - _ = yym1077 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1078 := r.ContainerType() - if yyct1078 == codecSelferValueTypeMap1234 { - yyl1078 := r.ReadMapStart() - if yyl1078 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1078, d) - } - } else if yyct1078 == codecSelferValueTypeArray1234 { - yyl1078 := r.ReadArrayStart() - if yyl1078 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1078, 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 yys1079Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1079Slc - var yyhl1079 bool = l >= 0 - for yyj1079 := 0; ; yyj1079++ { - if yyhl1079 { - if yyj1079 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1079Slc = r.DecodeBytes(yys1079Slc, true, true) - yys1079 := string(yys1079Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1079 { - 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, yys1079) - } // end switch yys1079 - } // end for yyj1079 - 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 yyj1083 int - var yyb1083 bool - var yyhl1083 bool = l >= 0 - yyj1083++ - if yyhl1083 { - yyb1083 = yyj1083 > l - } else { - yyb1083 = r.CheckBreak() - } - if yyb1083 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - yyj1083++ - if yyhl1083 { - yyb1083 = yyj1083 > l - } else { - yyb1083 = r.CheckBreak() - } - if yyb1083 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ShareName = "" - } else { - x.ShareName = string(r.DecodeString()) - } - yyj1083++ - if yyhl1083 { - yyb1083 = yyj1083 > l - } else { - yyb1083 = r.CheckBreak() - } - if yyb1083 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - for { - yyj1083++ - if yyhl1083 { - yyb1083 = yyj1083 > l - } else { - yyb1083 = r.CheckBreak() - } - if yyb1083 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1083-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 { - yym1087 := z.EncBinary() - _ = yym1087 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1088 := !z.EncBinary() - yy2arr1088 := z.EncBasicHandle().StructToArray - var yyq1088 [2]bool - _, _, _ = yysep1088, yyq1088, yy2arr1088 - const yyr1088 bool = false - yyq1088[1] = x.FSType != "" - var yynn1088 int - if yyr1088 || yy2arr1088 { - r.EncodeArrayStart(2) - } else { - yynn1088 = 1 - for _, b := range yyq1088 { - if b { - yynn1088++ - } - } - r.EncodeMapStart(yynn1088) - yynn1088 = 0 - } - if yyr1088 || yy2arr1088 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1090 := z.EncBinary() - _ = yym1090 - 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) - yym1091 := z.EncBinary() - _ = yym1091 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath)) - } - } - if yyr1088 || yy2arr1088 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1088[1] { - yym1093 := z.EncBinary() - _ = yym1093 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1088[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1094 := z.EncBinary() - _ = yym1094 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr1088 || yy2arr1088 { - 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 - yym1095 := z.DecBinary() - _ = yym1095 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1096 := r.ContainerType() - if yyct1096 == codecSelferValueTypeMap1234 { - yyl1096 := r.ReadMapStart() - if yyl1096 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1096, d) - } - } else if yyct1096 == codecSelferValueTypeArray1234 { - yyl1096 := r.ReadArrayStart() - if yyl1096 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1096, 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 yys1097Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1097Slc - var yyhl1097 bool = l >= 0 - for yyj1097 := 0; ; yyj1097++ { - if yyhl1097 { - if yyj1097 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1097Slc = r.DecodeBytes(yys1097Slc, true, true) - yys1097 := string(yys1097Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1097 { - 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, yys1097) - } // end switch yys1097 - } // end for yyj1097 - 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 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.VolumePath = "" - } else { - x.VolumePath = 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.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - 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 *PhotonPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1103 := z.EncBinary() - _ = yym1103 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1104 := !z.EncBinary() - yy2arr1104 := z.EncBasicHandle().StructToArray - var yyq1104 [2]bool - _, _, _ = yysep1104, yyq1104, yy2arr1104 - const yyr1104 bool = false - yyq1104[1] = x.FSType != "" - var yynn1104 int - if yyr1104 || yy2arr1104 { - r.EncodeArrayStart(2) - } else { - yynn1104 = 1 - for _, b := range yyq1104 { - if b { - yynn1104++ - } - } - r.EncodeMapStart(yynn1104) - yynn1104 = 0 - } - if yyr1104 || yy2arr1104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1106 := z.EncBinary() - _ = yym1106 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PdID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("pdID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1107 := z.EncBinary() - _ = yym1107 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PdID)) - } - } - if yyr1104 || yy2arr1104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1104[1] { - yym1109 := z.EncBinary() - _ = yym1109 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1104[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1110 := z.EncBinary() - _ = yym1110 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } - } - if yyr1104 || yy2arr1104 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PhotonPersistentDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1111 := z.DecBinary() - _ = yym1111 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1112 := r.ContainerType() - if yyct1112 == codecSelferValueTypeMap1234 { - yyl1112 := r.ReadMapStart() - if yyl1112 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1112, d) - } - } else if yyct1112 == codecSelferValueTypeArray1234 { - yyl1112 := r.ReadArrayStart() - if yyl1112 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1112, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1113Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1113Slc - var yyhl1113 bool = l >= 0 - for yyj1113 := 0; ; yyj1113++ { - if yyhl1113 { - if yyj1113 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1113Slc = r.DecodeBytes(yys1113Slc, true, true) - yys1113 := string(yys1113Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1113 { - case "pdID": - if r.TryDecodeAsNil() { - x.PdID = "" - } else { - x.PdID = string(r.DecodeString()) - } - case "fsType": - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1113) - } // end switch yys1113 - } // end for yyj1113 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1116 int - var yyb1116 bool - var yyhl1116 bool = l >= 0 - yyj1116++ - if yyhl1116 { - yyb1116 = yyj1116 > l - } else { - yyb1116 = r.CheckBreak() - } - if yyb1116 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PdID = "" - } else { - x.PdID = string(r.DecodeString()) - } - yyj1116++ - if yyhl1116 { - yyb1116 = yyj1116 > l - } else { - yyb1116 = r.CheckBreak() - } - if yyb1116 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" - } else { - x.FSType = string(r.DecodeString()) - } - for { - yyj1116++ - if yyhl1116 { - yyb1116 = yyj1116 > l - } else { - yyb1116 = r.CheckBreak() - } - if yyb1116 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1116-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x AzureDataDiskCachingMode) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1119 := z.EncBinary() - _ = yym1119 - 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 - yym1120 := z.DecBinary() - _ = yym1120 - 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 { - yym1121 := z.EncBinary() - _ = yym1121 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1122 := !z.EncBinary() - yy2arr1122 := z.EncBasicHandle().StructToArray - var yyq1122 [5]bool - _, _, _ = yysep1122, yyq1122, yy2arr1122 - const yyr1122 bool = false - yyq1122[2] = x.CachingMode != nil - yyq1122[3] = x.FSType != nil - yyq1122[4] = x.ReadOnly != nil - var yynn1122 int - if yyr1122 || yy2arr1122 { - r.EncodeArrayStart(5) - } else { - yynn1122 = 2 - for _, b := range yyq1122 { - if b { - yynn1122++ - } - } - r.EncodeMapStart(yynn1122) - yynn1122 = 0 - } - if yyr1122 || yy2arr1122 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1124 := z.EncBinary() - _ = yym1124 - 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) - yym1125 := z.EncBinary() - _ = yym1125 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DiskName)) - } - } - if yyr1122 || yy2arr1122 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1127 := z.EncBinary() - _ = yym1127 - 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) - yym1128 := z.EncBinary() - _ = yym1128 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DataDiskURI)) - } - } - if yyr1122 || yy2arr1122 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1122[2] { - if x.CachingMode == nil { - r.EncodeNil() - } else { - yy1130 := *x.CachingMode - yy1130.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1122[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cachingMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CachingMode == nil { - r.EncodeNil() - } else { - yy1131 := *x.CachingMode - yy1131.CodecEncodeSelf(e) - } - } - } - if yyr1122 || yy2arr1122 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1122[3] { - if x.FSType == nil { - r.EncodeNil() - } else { - yy1133 := *x.FSType - yym1134 := z.EncBinary() - _ = yym1134 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1133)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1122[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FSType == nil { - r.EncodeNil() - } else { - yy1135 := *x.FSType - yym1136 := z.EncBinary() - _ = yym1136 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1135)) - } - } - } - } - if yyr1122 || yy2arr1122 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1122[4] { - if x.ReadOnly == nil { - r.EncodeNil() - } else { - yy1138 := *x.ReadOnly - yym1139 := z.EncBinary() - _ = yym1139 - if false { - } else { - r.EncodeBool(bool(yy1138)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1122[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ReadOnly == nil { - r.EncodeNil() - } else { - yy1140 := *x.ReadOnly - yym1141 := z.EncBinary() - _ = yym1141 - if false { - } else { - r.EncodeBool(bool(yy1140)) - } - } - } - } - if yyr1122 || yy2arr1122 { - 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 - yym1142 := z.DecBinary() - _ = yym1142 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1143 := r.ContainerType() - if yyct1143 == codecSelferValueTypeMap1234 { - yyl1143 := r.ReadMapStart() - if yyl1143 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1143, d) - } - } else if yyct1143 == codecSelferValueTypeArray1234 { - yyl1143 := r.ReadArrayStart() - if yyl1143 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1143, 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 yys1144Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1144Slc - var yyhl1144 bool = l >= 0 - for yyj1144 := 0; ; yyj1144++ { - if yyhl1144 { - if yyj1144 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1144Slc = r.DecodeBytes(yys1144Slc, true, true) - yys1144 := string(yys1144Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1144 { - 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) - } - yym1149 := z.DecBinary() - _ = yym1149 - 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) - } - yym1151 := z.DecBinary() - _ = yym1151 - if false { - } else { - *((*bool)(x.ReadOnly)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys1144) - } // end switch yys1144 - } // end for yyj1144 - 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 yyj1152 int - var yyb1152 bool - var yyhl1152 bool = l >= 0 - yyj1152++ - if yyhl1152 { - yyb1152 = yyj1152 > l - } else { - yyb1152 = r.CheckBreak() - } - if yyb1152 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DiskName = "" - } else { - x.DiskName = string(r.DecodeString()) - } - yyj1152++ - if yyhl1152 { - yyb1152 = yyj1152 > l - } else { - yyb1152 = r.CheckBreak() - } - if yyb1152 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DataDiskURI = "" - } else { - x.DataDiskURI = string(r.DecodeString()) - } - yyj1152++ - if yyhl1152 { - yyb1152 = yyj1152 > l - } else { - yyb1152 = r.CheckBreak() - } - if yyb1152 { - 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) - } - yyj1152++ - if yyhl1152 { - yyb1152 = yyj1152 > l - } else { - yyb1152 = r.CheckBreak() - } - if yyb1152 { - 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) - } - yym1157 := z.DecBinary() - _ = yym1157 - if false { - } else { - *((*string)(x.FSType)) = r.DecodeString() - } - } - yyj1152++ - if yyhl1152 { - yyb1152 = yyj1152 > l - } else { - yyb1152 = r.CheckBreak() - } - if yyb1152 { - 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) - } - yym1159 := z.DecBinary() - _ = yym1159 - if false { - } else { - *((*bool)(x.ReadOnly)) = r.DecodeBool() - } - } - for { - yyj1152++ - if yyhl1152 { - yyb1152 = yyj1152 > l - } else { - yyb1152 = r.CheckBreak() - } - if yyb1152 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1152-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 { - yym1160 := z.EncBinary() - _ = yym1160 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1161 := !z.EncBinary() - yy2arr1161 := z.EncBasicHandle().StructToArray - var yyq1161 [3]bool - _, _, _ = yysep1161, yyq1161, yy2arr1161 - const yyr1161 bool = false - yyq1161[1] = len(x.Items) != 0 - yyq1161[2] = x.DefaultMode != nil - var yynn1161 int - if yyr1161 || yy2arr1161 { - r.EncodeArrayStart(3) - } else { - yynn1161 = 1 - 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] { - if x.Items == nil { - r.EncodeNil() - } else { - yym1166 := z.EncBinary() - _ = yym1166 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1161[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1167 := z.EncBinary() - _ = yym1167 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } - } - } - if yyr1161 || yy2arr1161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1161[2] { - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy1169 := *x.DefaultMode - yym1170 := z.EncBinary() - _ = yym1170 - if false { - } else { - r.EncodeInt(int64(yy1169)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1161[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() - } else { - yy1171 := *x.DefaultMode - yym1172 := z.EncBinary() - _ = yym1172 - if false { - } else { - r.EncodeInt(int64(yy1171)) - } - } - } - } - if yyr1161 || yy2arr1161 { - 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 - yym1173 := z.DecBinary() - _ = yym1173 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1174 := r.ContainerType() - if yyct1174 == codecSelferValueTypeMap1234 { - yyl1174 := r.ReadMapStart() - if yyl1174 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1174, d) - } - } else if yyct1174 == codecSelferValueTypeArray1234 { - yyl1174 := r.ReadArrayStart() - if yyl1174 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1174, 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 yys1175Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1175Slc - var yyhl1175 bool = l >= 0 - for yyj1175 := 0; ; yyj1175++ { - if yyhl1175 { - if yyj1175 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1175Slc = r.DecodeBytes(yys1175Slc, true, true) - yys1175 := string(yys1175Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1175 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1177 := &x.Items - yym1178 := z.DecBinary() - _ = yym1178 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv1177), d) - } - } - case "defaultMode": - if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } - } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) - } - yym1180 := z.DecBinary() - _ = yym1180 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys1175) - } // end switch yys1175 - } // end for yyj1175 - 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 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.Items = nil - } else { - yyv1183 := &x.Items - yym1184 := z.DecBinary() - _ = yym1184 - if false { - } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv1183), d) - } - } - yyj1181++ - if yyhl1181 { - yyb1181 = yyj1181 > l - } else { - yyb1181 = r.CheckBreak() - } - if yyb1181 { - 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) - } - yym1186 := z.DecBinary() - _ = yym1186 - if false { - } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) - } - } - 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 *KeyToPath) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1187 := z.EncBinary() - _ = yym1187 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1188 := !z.EncBinary() - yy2arr1188 := z.EncBasicHandle().StructToArray - var yyq1188 [3]bool - _, _, _ = yysep1188, yyq1188, yy2arr1188 - const yyr1188 bool = false - yyq1188[2] = x.Mode != nil - var yynn1188 int - if yyr1188 || yy2arr1188 { - r.EncodeArrayStart(3) - } else { - yynn1188 = 2 - for _, b := range yyq1188 { - if b { - yynn1188++ - } - } - r.EncodeMapStart(yynn1188) - yynn1188 = 0 - } - if yyr1188 || yy2arr1188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1190 := z.EncBinary() - _ = yym1190 - 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) - yym1191 := z.EncBinary() - _ = yym1191 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1188 || yy2arr1188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1193 := z.EncBinary() - _ = yym1193 - 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) - yym1194 := z.EncBinary() - _ = yym1194 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr1188 || yy2arr1188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1188[2] { - if x.Mode == nil { - r.EncodeNil() - } else { - yy1196 := *x.Mode - yym1197 := z.EncBinary() - _ = yym1197 - if false { - } else { - r.EncodeInt(int64(yy1196)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1188[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("mode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Mode == nil { - r.EncodeNil() - } else { - yy1198 := *x.Mode - yym1199 := z.EncBinary() - _ = yym1199 - if false { - } else { - r.EncodeInt(int64(yy1198)) - } - } - } - } - if yyr1188 || yy2arr1188 { - 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 - yym1200 := z.DecBinary() - _ = yym1200 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1201 := r.ContainerType() - if yyct1201 == codecSelferValueTypeMap1234 { - yyl1201 := r.ReadMapStart() - if yyl1201 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1201, d) - } - } else if yyct1201 == codecSelferValueTypeArray1234 { - yyl1201 := r.ReadArrayStart() - if yyl1201 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1201, 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 yys1202Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1202Slc - var yyhl1202 bool = l >= 0 - for yyj1202 := 0; ; yyj1202++ { - if yyhl1202 { - if yyj1202 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1202Slc = r.DecodeBytes(yys1202Slc, true, true) - yys1202 := string(yys1202Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1202 { - 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) - } - yym1206 := z.DecBinary() - _ = yym1206 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys1202) - } // end switch yys1202 - } // end for yyj1202 - 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 yyj1207 int - var yyb1207 bool - var yyhl1207 bool = l >= 0 - yyj1207++ - if yyhl1207 { - yyb1207 = yyj1207 > l - } else { - yyb1207 = r.CheckBreak() - } - if yyb1207 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj1207++ - if yyhl1207 { - yyb1207 = yyj1207 > l - } else { - yyb1207 = r.CheckBreak() - } - if yyb1207 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj1207++ - if yyhl1207 { - yyb1207 = yyj1207 > l - } else { - yyb1207 = r.CheckBreak() - } - if yyb1207 { - 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) - } - yym1211 := z.DecBinary() - _ = yym1211 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) - } - } - for { - yyj1207++ - if yyhl1207 { - yyb1207 = yyj1207 > l - } else { - yyb1207 = r.CheckBreak() - } - if yyb1207 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1207-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 { - yym1212 := z.EncBinary() - _ = yym1212 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1213 := !z.EncBinary() - yy2arr1213 := z.EncBasicHandle().StructToArray - var yyq1213 [5]bool - _, _, _ = yysep1213, yyq1213, yy2arr1213 - const yyr1213 bool = false - yyq1213[0] = x.Name != "" - yyq1213[1] = x.HostPort != 0 - yyq1213[3] = x.Protocol != "" - yyq1213[4] = x.HostIP != "" - var yynn1213 int - if yyr1213 || yy2arr1213 { - r.EncodeArrayStart(5) - } else { - yynn1213 = 1 - for _, b := range yyq1213 { - if b { - yynn1213++ - } - } - r.EncodeMapStart(yynn1213) - yynn1213 = 0 - } - if yyr1213 || yy2arr1213 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1213[0] { - yym1215 := z.EncBinary() - _ = yym1215 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1213[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1216 := z.EncBinary() - _ = yym1216 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr1213 || yy2arr1213 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1213[1] { - yym1218 := z.EncBinary() - _ = yym1218 - if false { - } else { - r.EncodeInt(int64(x.HostPort)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1213[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1219 := z.EncBinary() - _ = yym1219 - if false { - } else { - r.EncodeInt(int64(x.HostPort)) - } - } - } - if yyr1213 || yy2arr1213 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1221 := z.EncBinary() - _ = yym1221 - if false { - } else { - r.EncodeInt(int64(x.ContainerPort)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1222 := z.EncBinary() - _ = yym1222 - if false { - } else { - r.EncodeInt(int64(x.ContainerPort)) - } - } - if yyr1213 || yy2arr1213 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1213[3] { - x.Protocol.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1213[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) - } - } - if yyr1213 || yy2arr1213 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1213[4] { - yym1225 := z.EncBinary() - _ = yym1225 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1213[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1226 := z.EncBinary() - _ = yym1226 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } - } - if yyr1213 || yy2arr1213 { - 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 - yym1227 := z.DecBinary() - _ = yym1227 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1228 := r.ContainerType() - if yyct1228 == codecSelferValueTypeMap1234 { - yyl1228 := r.ReadMapStart() - if yyl1228 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1228, d) - } - } else if yyct1228 == codecSelferValueTypeArray1234 { - yyl1228 := r.ReadArrayStart() - if yyl1228 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1228, 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 yys1229Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1229Slc - var yyhl1229 bool = l >= 0 - for yyj1229 := 0; ; yyj1229++ { - if yyhl1229 { - if yyj1229 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1229Slc = r.DecodeBytes(yys1229Slc, true, true) - yys1229 := string(yys1229Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1229 { - 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, yys1229) - } // end switch yys1229 - } // end for yyj1229 - 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 yyj1235 int - var yyb1235 bool - var yyhl1235 bool = l >= 0 - yyj1235++ - if yyhl1235 { - yyb1235 = yyj1235 > l - } else { - yyb1235 = r.CheckBreak() - } - if yyb1235 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1235++ - if yyhl1235 { - yyb1235 = yyj1235 > l - } else { - yyb1235 = r.CheckBreak() - } - if yyb1235 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostPort = 0 - } else { - x.HostPort = int32(r.DecodeInt(32)) - } - yyj1235++ - if yyhl1235 { - yyb1235 = yyj1235 > l - } else { - yyb1235 = r.CheckBreak() - } - if yyb1235 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerPort = 0 - } else { - x.ContainerPort = int32(r.DecodeInt(32)) - } - yyj1235++ - if yyhl1235 { - yyb1235 = yyj1235 > l - } else { - yyb1235 = r.CheckBreak() - } - if yyb1235 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - x.Protocol = Protocol(r.DecodeString()) - } - yyj1235++ - if yyhl1235 { - yyb1235 = yyj1235 > l - } else { - yyb1235 = r.CheckBreak() - } - if yyb1235 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIP = "" - } else { - x.HostIP = string(r.DecodeString()) - } - for { - yyj1235++ - if yyhl1235 { - yyb1235 = yyj1235 > l - } else { - yyb1235 = r.CheckBreak() - } - if yyb1235 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1235-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 { - yym1241 := z.EncBinary() - _ = yym1241 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1242 := !z.EncBinary() - yy2arr1242 := z.EncBasicHandle().StructToArray - var yyq1242 [4]bool - _, _, _ = yysep1242, yyq1242, yy2arr1242 - const yyr1242 bool = false - yyq1242[1] = x.ReadOnly != false - yyq1242[3] = x.SubPath != "" - var yynn1242 int - if yyr1242 || yy2arr1242 { - r.EncodeArrayStart(4) - } else { - yynn1242 = 2 - for _, b := range yyq1242 { - if b { - yynn1242++ - } - } - r.EncodeMapStart(yynn1242) - yynn1242 = 0 - } - if yyr1242 || yy2arr1242 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1244 := z.EncBinary() - _ = yym1244 - 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) - yym1245 := z.EncBinary() - _ = yym1245 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1242 || yy2arr1242 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1242[1] { - yym1247 := z.EncBinary() - _ = yym1247 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1242[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1248 := z.EncBinary() - _ = yym1248 - if false { - } else { - r.EncodeBool(bool(x.ReadOnly)) - } - } - } - if yyr1242 || yy2arr1242 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1250 := z.EncBinary() - _ = yym1250 - 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) - yym1251 := z.EncBinary() - _ = yym1251 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.MountPath)) - } - } - if yyr1242 || yy2arr1242 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1242[3] { - yym1253 := z.EncBinary() - _ = yym1253 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1242[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("subPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1254 := z.EncBinary() - _ = yym1254 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) - } - } - } - if yyr1242 || yy2arr1242 { - 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 - yym1255 := z.DecBinary() - _ = yym1255 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1256 := r.ContainerType() - if yyct1256 == codecSelferValueTypeMap1234 { - yyl1256 := r.ReadMapStart() - if yyl1256 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1256, d) - } - } else if yyct1256 == codecSelferValueTypeArray1234 { - yyl1256 := r.ReadArrayStart() - if yyl1256 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1256, 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 yys1257Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1257Slc - var yyhl1257 bool = l >= 0 - for yyj1257 := 0; ; yyj1257++ { - if yyhl1257 { - if yyj1257 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1257Slc = r.DecodeBytes(yys1257Slc, true, true) - yys1257 := string(yys1257Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1257 { - 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, yys1257) - } // end switch yys1257 - } // end for yyj1257 - 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 yyj1262 int - var yyb1262 bool - var yyhl1262 bool = l >= 0 - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false - } else { - x.ReadOnly = bool(r.DecodeBool()) - } - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MountPath = "" - } else { - x.MountPath = string(r.DecodeString()) - } - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SubPath = "" - } else { - x.SubPath = string(r.DecodeString()) - } - for { - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1262-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 { - yym1267 := z.EncBinary() - _ = yym1267 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1268 := !z.EncBinary() - yy2arr1268 := z.EncBasicHandle().StructToArray - var yyq1268 [3]bool - _, _, _ = yysep1268, yyq1268, yy2arr1268 - const yyr1268 bool = false - yyq1268[1] = x.Value != "" - yyq1268[2] = x.ValueFrom != nil - var yynn1268 int - if yyr1268 || yy2arr1268 { - r.EncodeArrayStart(3) - } else { - yynn1268 = 1 - for _, b := range yyq1268 { - if b { - yynn1268++ - } - } - r.EncodeMapStart(yynn1268) - yynn1268 = 0 - } - if yyr1268 || yy2arr1268 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1270 := z.EncBinary() - _ = yym1270 - 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) - yym1271 := z.EncBinary() - _ = yym1271 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1268 || yy2arr1268 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1268[1] { - yym1273 := z.EncBinary() - _ = yym1273 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1268[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1274 := z.EncBinary() - _ = yym1274 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - } - if yyr1268 || yy2arr1268 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1268[2] { - if x.ValueFrom == nil { - r.EncodeNil() - } else { - x.ValueFrom.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1268[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 yyr1268 || yy2arr1268 { - 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 - yym1276 := z.DecBinary() - _ = yym1276 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1277 := r.ContainerType() - if yyct1277 == codecSelferValueTypeMap1234 { - yyl1277 := r.ReadMapStart() - if yyl1277 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1277, d) - } - } else if yyct1277 == codecSelferValueTypeArray1234 { - yyl1277 := r.ReadArrayStart() - if yyl1277 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1277, 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 yys1278Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1278Slc - var yyhl1278 bool = l >= 0 - for yyj1278 := 0; ; yyj1278++ { - if yyhl1278 { - if yyj1278 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1278Slc = r.DecodeBytes(yys1278Slc, true, true) - yys1278 := string(yys1278Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1278 { - 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, yys1278) - } // end switch yys1278 - } // end for yyj1278 - 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 yyj1282 int - var yyb1282 bool - var yyhl1282 bool = l >= 0 - yyj1282++ - if yyhl1282 { - yyb1282 = yyj1282 > l - } else { - yyb1282 = r.CheckBreak() - } - if yyb1282 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1282++ - if yyhl1282 { - yyb1282 = yyj1282 > l - } else { - yyb1282 = r.CheckBreak() - } - if yyb1282 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - yyj1282++ - if yyhl1282 { - yyb1282 = yyj1282 > l - } else { - yyb1282 = r.CheckBreak() - } - if yyb1282 { - 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 { - yyj1282++ - if yyhl1282 { - yyb1282 = yyj1282 > l - } else { - yyb1282 = r.CheckBreak() - } - if yyb1282 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1282-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 { - yym1286 := z.EncBinary() - _ = yym1286 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1287 := !z.EncBinary() - yy2arr1287 := z.EncBasicHandle().StructToArray - var yyq1287 [4]bool - _, _, _ = yysep1287, yyq1287, yy2arr1287 - const yyr1287 bool = false - yyq1287[0] = x.FieldRef != nil - yyq1287[1] = x.ResourceFieldRef != nil - yyq1287[2] = x.ConfigMapKeyRef != nil - yyq1287[3] = x.SecretKeyRef != nil - var yynn1287 int - if yyr1287 || yy2arr1287 { - r.EncodeArrayStart(4) - } else { - yynn1287 = 0 - for _, b := range yyq1287 { - if b { - yynn1287++ - } - } - r.EncodeMapStart(yynn1287) - yynn1287 = 0 - } - if yyr1287 || yy2arr1287 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1287[0] { - if x.FieldRef == nil { - r.EncodeNil() - } else { - x.FieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1287[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 yyr1287 || yy2arr1287 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1287[1] { - if x.ResourceFieldRef == nil { - r.EncodeNil() - } else { - x.ResourceFieldRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1287[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 yyr1287 || yy2arr1287 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1287[2] { - if x.ConfigMapKeyRef == nil { - r.EncodeNil() - } else { - x.ConfigMapKeyRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1287[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 yyr1287 || yy2arr1287 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1287[3] { - if x.SecretKeyRef == nil { - r.EncodeNil() - } else { - x.SecretKeyRef.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1287[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 yyr1287 || yy2arr1287 { - 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 - yym1292 := z.DecBinary() - _ = yym1292 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1293 := r.ContainerType() - if yyct1293 == codecSelferValueTypeMap1234 { - yyl1293 := r.ReadMapStart() - if yyl1293 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1293, d) - } - } else if yyct1293 == codecSelferValueTypeArray1234 { - yyl1293 := r.ReadArrayStart() - if yyl1293 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1293, 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 yys1294Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1294Slc - var yyhl1294 bool = l >= 0 - for yyj1294 := 0; ; yyj1294++ { - if yyhl1294 { - if yyj1294 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1294Slc = r.DecodeBytes(yys1294Slc, true, true) - yys1294 := string(yys1294Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1294 { - 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, yys1294) - } // end switch yys1294 - } // end for yyj1294 - 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 yyj1299 int - var yyb1299 bool - var yyhl1299 bool = l >= 0 - yyj1299++ - if yyhl1299 { - yyb1299 = yyj1299 > l - } else { - yyb1299 = r.CheckBreak() - } - if yyb1299 { - 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) - } - yyj1299++ - if yyhl1299 { - yyb1299 = yyj1299 > l - } else { - yyb1299 = r.CheckBreak() - } - if yyb1299 { - 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) - } - yyj1299++ - if yyhl1299 { - yyb1299 = yyj1299 > l - } else { - yyb1299 = r.CheckBreak() - } - if yyb1299 { - 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) - } - yyj1299++ - if yyhl1299 { - yyb1299 = yyj1299 > l - } else { - yyb1299 = r.CheckBreak() - } - if yyb1299 { - 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 { - yyj1299++ - if yyhl1299 { - yyb1299 = yyj1299 > l - } else { - yyb1299 = r.CheckBreak() - } - if yyb1299 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1299-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 { - yym1304 := z.EncBinary() - _ = yym1304 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1305 := !z.EncBinary() - yy2arr1305 := z.EncBasicHandle().StructToArray - var yyq1305 [2]bool - _, _, _ = yysep1305, yyq1305, yy2arr1305 - const yyr1305 bool = false - var yynn1305 int - if yyr1305 || yy2arr1305 { - r.EncodeArrayStart(2) - } else { - yynn1305 = 2 - for _, b := range yyq1305 { - if b { - yynn1305++ - } - } - r.EncodeMapStart(yynn1305) - yynn1305 = 0 - } - if yyr1305 || yy2arr1305 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1307 := z.EncBinary() - _ = yym1307 - 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) - yym1308 := z.EncBinary() - _ = yym1308 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - if yyr1305 || yy2arr1305 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1310 := z.EncBinary() - _ = yym1310 - 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) - yym1311 := z.EncBinary() - _ = yym1311 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) - } - } - if yyr1305 || yy2arr1305 { - 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 - yym1312 := z.DecBinary() - _ = yym1312 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1313 := r.ContainerType() - if yyct1313 == codecSelferValueTypeMap1234 { - yyl1313 := r.ReadMapStart() - if yyl1313 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1313, d) - } - } else if yyct1313 == codecSelferValueTypeArray1234 { - yyl1313 := r.ReadArrayStart() - if yyl1313 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1313, 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 yys1314Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1314Slc - var yyhl1314 bool = l >= 0 - for yyj1314 := 0; ; yyj1314++ { - if yyhl1314 { - if yyj1314 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1314Slc = r.DecodeBytes(yys1314Slc, true, true) - yys1314 := string(yys1314Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1314 { - 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, yys1314) - } // end switch yys1314 - } // end for yyj1314 - 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 yyj1317 int - var yyb1317 bool - var yyhl1317 bool = l >= 0 - yyj1317++ - if yyhl1317 { - yyb1317 = yyj1317 > l - } else { - yyb1317 = r.CheckBreak() - } - if yyb1317 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1317++ - if yyhl1317 { - yyb1317 = yyj1317 > l - } else { - yyb1317 = r.CheckBreak() - } - if yyb1317 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FieldPath = "" - } else { - x.FieldPath = string(r.DecodeString()) - } - for { - yyj1317++ - if yyhl1317 { - yyb1317 = yyj1317 > l - } else { - yyb1317 = r.CheckBreak() - } - if yyb1317 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1317-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 { - yym1320 := z.EncBinary() - _ = yym1320 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1321 := !z.EncBinary() - yy2arr1321 := z.EncBasicHandle().StructToArray - var yyq1321 [3]bool - _, _, _ = yysep1321, yyq1321, yy2arr1321 - const yyr1321 bool = false - yyq1321[0] = x.ContainerName != "" - yyq1321[2] = true - var yynn1321 int - if yyr1321 || yy2arr1321 { - r.EncodeArrayStart(3) - } else { - yynn1321 = 1 - for _, b := range yyq1321 { - if b { - yynn1321++ - } - } - r.EncodeMapStart(yynn1321) - yynn1321 = 0 - } - if yyr1321 || yy2arr1321 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1321[0] { - yym1323 := z.EncBinary() - _ = yym1323 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1321[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1324 := z.EncBinary() - _ = yym1324 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) - } - } - } - if yyr1321 || yy2arr1321 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1326 := z.EncBinary() - _ = yym1326 - 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) - yym1327 := z.EncBinary() - _ = yym1327 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) - } - } - if yyr1321 || yy2arr1321 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1321[2] { - yy1329 := &x.Divisor - yym1330 := z.EncBinary() - _ = yym1330 - if false { - } else if z.HasExtensions() && z.EncExt(yy1329) { - } else if !yym1330 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1329) - } else { - z.EncFallback(yy1329) - } - } else { - r.EncodeNil() - } - } else { - if yyq1321[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("divisor")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1331 := &x.Divisor - yym1332 := z.EncBinary() - _ = yym1332 - if false { - } else if z.HasExtensions() && z.EncExt(yy1331) { - } else if !yym1332 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1331) - } else { - z.EncFallback(yy1331) - } - } - } - if yyr1321 || yy2arr1321 { - 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 - yym1333 := z.DecBinary() - _ = yym1333 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1334 := r.ContainerType() - if yyct1334 == codecSelferValueTypeMap1234 { - yyl1334 := r.ReadMapStart() - if yyl1334 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1334, d) - } - } else if yyct1334 == codecSelferValueTypeArray1234 { - yyl1334 := r.ReadArrayStart() - if yyl1334 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1334, 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 yys1335Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1335Slc - var yyhl1335 bool = l >= 0 - for yyj1335 := 0; ; yyj1335++ { - if yyhl1335 { - if yyj1335 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1335Slc = r.DecodeBytes(yys1335Slc, true, true) - yys1335 := string(yys1335Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1335 { - 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 { - yyv1338 := &x.Divisor - yym1339 := z.DecBinary() - _ = yym1339 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1338) { - } else if !yym1339 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1338) - } else { - z.DecFallback(yyv1338, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1335) - } // end switch yys1335 - } // end for yyj1335 - 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 yyj1340 int - var yyb1340 bool - var yyhl1340 bool = l >= 0 - yyj1340++ - if yyhl1340 { - yyb1340 = yyj1340 > l - } else { - yyb1340 = r.CheckBreak() - } - if yyb1340 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerName = "" - } else { - x.ContainerName = string(r.DecodeString()) - } - yyj1340++ - if yyhl1340 { - yyb1340 = yyj1340 > l - } else { - yyb1340 = r.CheckBreak() - } - if yyb1340 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Resource = "" - } else { - x.Resource = string(r.DecodeString()) - } - yyj1340++ - if yyhl1340 { - yyb1340 = yyj1340 > l - } else { - yyb1340 = r.CheckBreak() - } - if yyb1340 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Divisor = pkg3_resource.Quantity{} - } else { - yyv1343 := &x.Divisor - yym1344 := z.DecBinary() - _ = yym1344 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1343) { - } else if !yym1344 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1343) - } else { - z.DecFallback(yyv1343, false) - } - } - for { - yyj1340++ - if yyhl1340 { - yyb1340 = yyj1340 > l - } else { - yyb1340 = r.CheckBreak() - } - if yyb1340 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1340-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 { - yym1345 := z.EncBinary() - _ = yym1345 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1346 := !z.EncBinary() - yy2arr1346 := z.EncBasicHandle().StructToArray - var yyq1346 [2]bool - _, _, _ = yysep1346, yyq1346, yy2arr1346 - const yyr1346 bool = false - var yynn1346 int - if yyr1346 || yy2arr1346 { - r.EncodeArrayStart(2) - } else { - yynn1346 = 2 - for _, b := range yyq1346 { - if b { - yynn1346++ - } - } - r.EncodeMapStart(yynn1346) - yynn1346 = 0 - } - if yyr1346 || yy2arr1346 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1348 := z.EncBinary() - _ = yym1348 - 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) - yym1349 := z.EncBinary() - _ = yym1349 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1346 || yy2arr1346 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1351 := z.EncBinary() - _ = yym1351 - 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) - yym1352 := z.EncBinary() - _ = yym1352 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1346 || yy2arr1346 { - 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 - yym1353 := z.DecBinary() - _ = yym1353 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1354 := r.ContainerType() - if yyct1354 == codecSelferValueTypeMap1234 { - yyl1354 := r.ReadMapStart() - if yyl1354 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1354, d) - } - } else if yyct1354 == codecSelferValueTypeArray1234 { - yyl1354 := r.ReadArrayStart() - if yyl1354 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1354, 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 yys1355Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1355Slc - var yyhl1355 bool = l >= 0 - for yyj1355 := 0; ; yyj1355++ { - if yyhl1355 { - if yyj1355 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1355Slc = r.DecodeBytes(yys1355Slc, true, true) - yys1355 := string(yys1355Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1355 { - 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, yys1355) - } // end switch yys1355 - } // end for yyj1355 - 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 yyj1358 int - var yyb1358 bool - var yyhl1358 bool = l >= 0 - yyj1358++ - if yyhl1358 { - yyb1358 = yyj1358 > l - } else { - yyb1358 = r.CheckBreak() - } - if yyb1358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1358++ - if yyhl1358 { - yyb1358 = yyj1358 > l - } else { - yyb1358 = r.CheckBreak() - } - if yyb1358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - for { - yyj1358++ - if yyhl1358 { - yyb1358 = yyj1358 > l - } else { - yyb1358 = r.CheckBreak() - } - if yyb1358 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1358-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 { - yym1361 := z.EncBinary() - _ = yym1361 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1362 := !z.EncBinary() - yy2arr1362 := z.EncBasicHandle().StructToArray - var yyq1362 [2]bool - _, _, _ = yysep1362, yyq1362, yy2arr1362 - const yyr1362 bool = false - var yynn1362 int - if yyr1362 || yy2arr1362 { - r.EncodeArrayStart(2) - } else { - yynn1362 = 2 - for _, b := range yyq1362 { - if b { - yynn1362++ - } - } - r.EncodeMapStart(yynn1362) - yynn1362 = 0 - } - if yyr1362 || yy2arr1362 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1364 := z.EncBinary() - _ = yym1364 - 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) - yym1365 := z.EncBinary() - _ = yym1365 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1362 || yy2arr1362 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1367 := z.EncBinary() - _ = yym1367 - 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) - yym1368 := z.EncBinary() - _ = yym1368 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1362 || yy2arr1362 { - 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 - 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 *SecretKeySelector) 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 "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, yys1371) - } // end switch yys1371 - } // end for yyj1371 - 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 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.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - 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.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - 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 *HTTPHeader) 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 [2]bool - _, _, _ = yysep1378, yyq1378, yy2arr1378 - const yyr1378 bool = false - var yynn1378 int - if yyr1378 || yy2arr1378 { - r.EncodeArrayStart(2) - } else { - yynn1378 = 2 - for _, b := range yyq1378 { - if b { - yynn1378++ - } - } - r.EncodeMapStart(yynn1378) - yynn1378 = 0 - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1380 := z.EncBinary() - _ = yym1380 - 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) - yym1381 := z.EncBinary() - _ = yym1381 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1383 := z.EncBinary() - _ = yym1383 - 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) - yym1384 := z.EncBinary() - _ = yym1384 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - if yyr1378 || yy2arr1378 { - 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 - yym1385 := z.DecBinary() - _ = yym1385 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1386 := r.ContainerType() - if yyct1386 == codecSelferValueTypeMap1234 { - yyl1386 := r.ReadMapStart() - if yyl1386 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1386, d) - } - } else if yyct1386 == codecSelferValueTypeArray1234 { - yyl1386 := r.ReadArrayStart() - if yyl1386 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1386, 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 yys1387Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1387Slc - var yyhl1387 bool = l >= 0 - for yyj1387 := 0; ; yyj1387++ { - if yyhl1387 { - if yyj1387 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1387Slc = r.DecodeBytes(yys1387Slc, true, true) - yys1387 := string(yys1387Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1387 { - 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, yys1387) - } // end switch yys1387 - } // end for yyj1387 - 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 yyj1390 int - var yyb1390 bool - var yyhl1390 bool = l >= 0 - yyj1390++ - if yyhl1390 { - yyb1390 = yyj1390 > l - } else { - yyb1390 = r.CheckBreak() - } - if yyb1390 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1390++ - if yyhl1390 { - yyb1390 = yyj1390 > l - } else { - yyb1390 = r.CheckBreak() - } - if yyb1390 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - for { - yyj1390++ - if yyhl1390 { - yyb1390 = yyj1390 > l - } else { - yyb1390 = r.CheckBreak() - } - if yyb1390 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1390-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 { - yym1393 := z.EncBinary() - _ = yym1393 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1394 := !z.EncBinary() - yy2arr1394 := z.EncBasicHandle().StructToArray - var yyq1394 [5]bool - _, _, _ = yysep1394, yyq1394, yy2arr1394 - const yyr1394 bool = false - yyq1394[0] = x.Path != "" - yyq1394[1] = true - yyq1394[2] = x.Host != "" - yyq1394[3] = x.Scheme != "" - yyq1394[4] = len(x.HTTPHeaders) != 0 - var yynn1394 int - if yyr1394 || yy2arr1394 { - r.EncodeArrayStart(5) - } else { - yynn1394 = 0 - for _, b := range yyq1394 { - if b { - yynn1394++ - } - } - r.EncodeMapStart(yynn1394) - yynn1394 = 0 - } - if yyr1394 || yy2arr1394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1394[0] { - yym1396 := z.EncBinary() - _ = yym1396 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1394[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1397 := z.EncBinary() - _ = yym1397 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr1394 || yy2arr1394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1394[1] { - yy1399 := &x.Port - yym1400 := z.EncBinary() - _ = yym1400 - if false { - } else if z.HasExtensions() && z.EncExt(yy1399) { - } else if !yym1400 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1399) - } else { - z.EncFallback(yy1399) - } - } else { - r.EncodeNil() - } - } else { - if yyq1394[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1401 := &x.Port - yym1402 := z.EncBinary() - _ = yym1402 - if false { - } else if z.HasExtensions() && z.EncExt(yy1401) { - } else if !yym1402 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1401) - } else { - z.EncFallback(yy1401) - } - } - } - if yyr1394 || yy2arr1394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1394[2] { - yym1404 := z.EncBinary() - _ = yym1404 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1394[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("host")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1405 := z.EncBinary() - _ = yym1405 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } - } - if yyr1394 || yy2arr1394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1394[3] { - x.Scheme.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1394[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("scheme")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Scheme.CodecEncodeSelf(e) - } - } - if yyr1394 || yy2arr1394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1394[4] { - if x.HTTPHeaders == nil { - r.EncodeNil() - } else { - yym1408 := z.EncBinary() - _ = yym1408 - if false { - } else { - h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1394[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("httpHeaders")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.HTTPHeaders == nil { - r.EncodeNil() - } else { - yym1409 := z.EncBinary() - _ = yym1409 - if false { - } else { - h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e) - } - } - } - } - if yyr1394 || yy2arr1394 { - 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 - yym1410 := z.DecBinary() - _ = yym1410 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1411 := r.ContainerType() - if yyct1411 == codecSelferValueTypeMap1234 { - yyl1411 := r.ReadMapStart() - if yyl1411 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1411, d) - } - } else if yyct1411 == codecSelferValueTypeArray1234 { - yyl1411 := r.ReadArrayStart() - if yyl1411 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1411, 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 yys1412Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1412Slc - var yyhl1412 bool = l >= 0 - for yyj1412 := 0; ; yyj1412++ { - if yyhl1412 { - if yyj1412 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1412Slc = r.DecodeBytes(yys1412Slc, true, true) - yys1412 := string(yys1412Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1412 { - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - case "port": - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1414 := &x.Port - yym1415 := z.DecBinary() - _ = yym1415 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1414) { - } else if !yym1415 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1414) - } else { - z.DecFallback(yyv1414, 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 { - yyv1418 := &x.HTTPHeaders - yym1419 := z.DecBinary() - _ = yym1419 - if false { - } else { - h.decSliceHTTPHeader((*[]HTTPHeader)(yyv1418), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1412) - } // end switch yys1412 - } // end for yyj1412 - 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 yyj1420 int - var yyb1420 bool - var yyhl1420 bool = l >= 0 - yyj1420++ - if yyhl1420 { - yyb1420 = yyj1420 > l - } else { - yyb1420 = r.CheckBreak() - } - if yyb1420 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj1420++ - if yyhl1420 { - yyb1420 = yyj1420 > l - } else { - yyb1420 = r.CheckBreak() - } - if yyb1420 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1422 := &x.Port - yym1423 := z.DecBinary() - _ = yym1423 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1422) { - } else if !yym1423 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1422) - } else { - z.DecFallback(yyv1422, false) - } - } - yyj1420++ - if yyhl1420 { - yyb1420 = yyj1420 > l - } else { - yyb1420 = r.CheckBreak() - } - if yyb1420 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Host = "" - } else { - x.Host = string(r.DecodeString()) - } - yyj1420++ - if yyhl1420 { - yyb1420 = yyj1420 > l - } else { - yyb1420 = r.CheckBreak() - } - if yyb1420 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Scheme = "" - } else { - x.Scheme = URIScheme(r.DecodeString()) - } - yyj1420++ - if yyhl1420 { - yyb1420 = yyj1420 > l - } else { - yyb1420 = r.CheckBreak() - } - if yyb1420 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HTTPHeaders = nil - } else { - yyv1426 := &x.HTTPHeaders - yym1427 := z.DecBinary() - _ = yym1427 - if false { - } else { - h.decSliceHTTPHeader((*[]HTTPHeader)(yyv1426), d) - } - } - for { - yyj1420++ - if yyhl1420 { - yyb1420 = yyj1420 > l - } else { - yyb1420 = r.CheckBreak() - } - if yyb1420 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1420-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x URIScheme) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1428 := z.EncBinary() - _ = yym1428 - 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 - yym1429 := z.DecBinary() - _ = yym1429 - 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 { - yym1430 := z.EncBinary() - _ = yym1430 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1431 := !z.EncBinary() - yy2arr1431 := z.EncBasicHandle().StructToArray - var yyq1431 [1]bool - _, _, _ = yysep1431, yyq1431, yy2arr1431 - const yyr1431 bool = false - yyq1431[0] = true - var yynn1431 int - if yyr1431 || yy2arr1431 { - r.EncodeArrayStart(1) - } else { - yynn1431 = 0 - for _, b := range yyq1431 { - if b { - yynn1431++ - } - } - r.EncodeMapStart(yynn1431) - yynn1431 = 0 - } - if yyr1431 || yy2arr1431 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1431[0] { - yy1433 := &x.Port - yym1434 := z.EncBinary() - _ = yym1434 - if false { - } else if z.HasExtensions() && z.EncExt(yy1433) { - } else if !yym1434 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1433) - } else { - z.EncFallback(yy1433) - } - } else { - r.EncodeNil() - } - } else { - if yyq1431[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1435 := &x.Port - yym1436 := z.EncBinary() - _ = yym1436 - if false { - } else if z.HasExtensions() && z.EncExt(yy1435) { - } else if !yym1436 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1435) - } else { - z.EncFallback(yy1435) - } - } - } - if yyr1431 || yy2arr1431 { - 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 - yym1437 := z.DecBinary() - _ = yym1437 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1438 := r.ContainerType() - if yyct1438 == codecSelferValueTypeMap1234 { - yyl1438 := r.ReadMapStart() - if yyl1438 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1438, d) - } - } else if yyct1438 == codecSelferValueTypeArray1234 { - yyl1438 := r.ReadArrayStart() - if yyl1438 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1438, 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 yys1439Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1439Slc - var yyhl1439 bool = l >= 0 - for yyj1439 := 0; ; yyj1439++ { - if yyhl1439 { - if yyj1439 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1439Slc = r.DecodeBytes(yys1439Slc, true, true) - yys1439 := string(yys1439Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1439 { - case "port": - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1440 := &x.Port - yym1441 := z.DecBinary() - _ = yym1441 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1440) { - } else if !yym1441 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1440) - } else { - z.DecFallback(yyv1440, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1439) - } // end switch yys1439 - } // end for yyj1439 - 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 yyj1442 int - var yyb1442 bool - var yyhl1442 bool = l >= 0 - yyj1442++ - if yyhl1442 { - yyb1442 = yyj1442 > l - } else { - yyb1442 = r.CheckBreak() - } - if yyb1442 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = pkg4_intstr.IntOrString{} - } else { - yyv1443 := &x.Port - yym1444 := z.DecBinary() - _ = yym1444 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1443) { - } else if !yym1444 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1443) - } else { - z.DecFallback(yyv1443, false) - } - } - for { - yyj1442++ - if yyhl1442 { - yyb1442 = yyj1442 > l - } else { - yyb1442 = r.CheckBreak() - } - if yyb1442 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1442-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 { - yym1445 := z.EncBinary() - _ = yym1445 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1446 := !z.EncBinary() - yy2arr1446 := z.EncBasicHandle().StructToArray - var yyq1446 [1]bool - _, _, _ = yysep1446, yyq1446, yy2arr1446 - const yyr1446 bool = false - yyq1446[0] = len(x.Command) != 0 - var yynn1446 int - if yyr1446 || yy2arr1446 { - r.EncodeArrayStart(1) - } else { - yynn1446 = 0 - for _, b := range yyq1446 { - if b { - yynn1446++ - } - } - r.EncodeMapStart(yynn1446) - yynn1446 = 0 - } - if yyr1446 || yy2arr1446 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1446[0] { - if x.Command == nil { - r.EncodeNil() - } else { - yym1448 := z.EncBinary() - _ = yym1448 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1446[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("command")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Command == nil { - r.EncodeNil() - } else { - yym1449 := z.EncBinary() - _ = yym1449 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } - } - if yyr1446 || yy2arr1446 { - 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 - yym1450 := z.DecBinary() - _ = yym1450 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1451 := r.ContainerType() - if yyct1451 == codecSelferValueTypeMap1234 { - yyl1451 := r.ReadMapStart() - if yyl1451 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1451, d) - } - } else if yyct1451 == codecSelferValueTypeArray1234 { - yyl1451 := r.ReadArrayStart() - if yyl1451 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1451, 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 yys1452Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1452Slc - var yyhl1452 bool = l >= 0 - for yyj1452 := 0; ; yyj1452++ { - if yyhl1452 { - if yyj1452 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1452Slc = r.DecodeBytes(yys1452Slc, true, true) - yys1452 := string(yys1452Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1452 { - case "command": - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv1453 := &x.Command - yym1454 := z.DecBinary() - _ = yym1454 - if false { - } else { - z.F.DecSliceStringX(yyv1453, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1452) - } // end switch yys1452 - } // end for yyj1452 - 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 yyj1455 int - var yyb1455 bool - var yyhl1455 bool = l >= 0 - yyj1455++ - if yyhl1455 { - yyb1455 = yyj1455 > l - } else { - yyb1455 = r.CheckBreak() - } - if yyb1455 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv1456 := &x.Command - yym1457 := z.DecBinary() - _ = yym1457 - if false { - } else { - z.F.DecSliceStringX(yyv1456, false, d) - } - } - for { - yyj1455++ - if yyhl1455 { - yyb1455 = yyj1455 > l - } else { - yyb1455 = r.CheckBreak() - } - if yyb1455 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1455-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 { - yym1458 := z.EncBinary() - _ = yym1458 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1459 := !z.EncBinary() - yy2arr1459 := z.EncBasicHandle().StructToArray - var yyq1459 [8]bool - _, _, _ = yysep1459, yyq1459, yy2arr1459 - const yyr1459 bool = false - yyq1459[0] = x.Handler.Exec != nil && x.Exec != nil - yyq1459[1] = x.Handler.HTTPGet != nil && x.HTTPGet != nil - yyq1459[2] = x.Handler.TCPSocket != nil && x.TCPSocket != nil - yyq1459[3] = x.InitialDelaySeconds != 0 - yyq1459[4] = x.TimeoutSeconds != 0 - yyq1459[5] = x.PeriodSeconds != 0 - yyq1459[6] = x.SuccessThreshold != 0 - yyq1459[7] = x.FailureThreshold != 0 - var yynn1459 int - if yyr1459 || yy2arr1459 { - r.EncodeArrayStart(8) - } else { - yynn1459 = 0 - for _, b := range yyq1459 { - if b { - yynn1459++ - } - } - r.EncodeMapStart(yynn1459) - yynn1459 = 0 - } - var yyn1460 bool - if x.Handler.Exec == nil { - yyn1460 = true - goto LABEL1460 - } - LABEL1460: - if yyr1459 || yy2arr1459 { - if yyn1460 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[0] { - if x.Exec == nil { - r.EncodeNil() - } else { - x.Exec.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq1459[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1460 { - r.EncodeNil() - } else { - if x.Exec == nil { - r.EncodeNil() - } else { - x.Exec.CodecEncodeSelf(e) - } - } - } - } - var yyn1461 bool - if x.Handler.HTTPGet == nil { - yyn1461 = true - goto LABEL1461 - } - LABEL1461: - if yyr1459 || yy2arr1459 { - if yyn1461 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[1] { - if x.HTTPGet == nil { - r.EncodeNil() - } else { - x.HTTPGet.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq1459[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("httpGet")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1461 { - r.EncodeNil() - } else { - if x.HTTPGet == nil { - r.EncodeNil() - } else { - x.HTTPGet.CodecEncodeSelf(e) - } - } - } - } - var yyn1462 bool - if x.Handler.TCPSocket == nil { - yyn1462 = true - goto LABEL1462 - } - LABEL1462: - if yyr1459 || yy2arr1459 { - if yyn1462 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[2] { - if x.TCPSocket == nil { - r.EncodeNil() - } else { - x.TCPSocket.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq1459[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tcpSocket")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1462 { - r.EncodeNil() - } else { - if x.TCPSocket == nil { - r.EncodeNil() - } else { - x.TCPSocket.CodecEncodeSelf(e) - } - } - } - } - if yyr1459 || yy2arr1459 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[3] { - yym1464 := z.EncBinary() - _ = yym1464 - if false { - } else { - r.EncodeInt(int64(x.InitialDelaySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1459[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("initialDelaySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1465 := z.EncBinary() - _ = yym1465 - if false { - } else { - r.EncodeInt(int64(x.InitialDelaySeconds)) - } - } - } - if yyr1459 || yy2arr1459 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[4] { - yym1467 := z.EncBinary() - _ = yym1467 - if false { - } else { - r.EncodeInt(int64(x.TimeoutSeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1459[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1468 := z.EncBinary() - _ = yym1468 - if false { - } else { - r.EncodeInt(int64(x.TimeoutSeconds)) - } - } - } - if yyr1459 || yy2arr1459 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[5] { - yym1470 := z.EncBinary() - _ = yym1470 - if false { - } else { - r.EncodeInt(int64(x.PeriodSeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1459[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("periodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1471 := z.EncBinary() - _ = yym1471 - if false { - } else { - r.EncodeInt(int64(x.PeriodSeconds)) - } - } - } - if yyr1459 || yy2arr1459 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[6] { - yym1473 := z.EncBinary() - _ = yym1473 - if false { - } else { - r.EncodeInt(int64(x.SuccessThreshold)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1459[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("successThreshold")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1474 := z.EncBinary() - _ = yym1474 - if false { - } else { - r.EncodeInt(int64(x.SuccessThreshold)) - } - } - } - if yyr1459 || yy2arr1459 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1459[7] { - yym1476 := z.EncBinary() - _ = yym1476 - if false { - } else { - r.EncodeInt(int64(x.FailureThreshold)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1459[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("failureThreshold")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1477 := z.EncBinary() - _ = yym1477 - if false { - } else { - r.EncodeInt(int64(x.FailureThreshold)) - } - } - } - if yyr1459 || yy2arr1459 { - 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 - yym1478 := z.DecBinary() - _ = yym1478 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1479 := r.ContainerType() - if yyct1479 == codecSelferValueTypeMap1234 { - yyl1479 := r.ReadMapStart() - if yyl1479 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1479, d) - } - } else if yyct1479 == codecSelferValueTypeArray1234 { - yyl1479 := r.ReadArrayStart() - if yyl1479 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1479, 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 yys1480Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1480Slc - var yyhl1480 bool = l >= 0 - for yyj1480 := 0; ; yyj1480++ { - if yyhl1480 { - if yyj1480 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1480Slc = r.DecodeBytes(yys1480Slc, true, true) - yys1480 := string(yys1480Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1480 { - 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, yys1480) - } // end switch yys1480 - } // end for yyj1480 - 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 yyj1489 int - var yyb1489 bool - var yyhl1489 bool = l >= 0 - if x.Handler.Exec == nil { - x.Handler.Exec = new(ExecAction) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - 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) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - 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) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - 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) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.InitialDelaySeconds = 0 - } else { - x.InitialDelaySeconds = int32(r.DecodeInt(32)) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TimeoutSeconds = 0 - } else { - x.TimeoutSeconds = int32(r.DecodeInt(32)) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PeriodSeconds = 0 - } else { - x.PeriodSeconds = int32(r.DecodeInt(32)) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SuccessThreshold = 0 - } else { - x.SuccessThreshold = int32(r.DecodeInt(32)) - } - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FailureThreshold = 0 - } else { - x.FailureThreshold = int32(r.DecodeInt(32)) - } - for { - yyj1489++ - if yyhl1489 { - yyb1489 = yyj1489 > l - } else { - yyb1489 = r.CheckBreak() - } - if yyb1489 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1489-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PullPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1498 := z.EncBinary() - _ = yym1498 - 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 - yym1499 := z.DecBinary() - _ = yym1499 - 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 - yym1500 := z.EncBinary() - _ = yym1500 - 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 - yym1501 := z.DecBinary() - _ = yym1501 - 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 { - yym1502 := z.EncBinary() - _ = yym1502 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1503 := !z.EncBinary() - yy2arr1503 := z.EncBasicHandle().StructToArray - var yyq1503 [2]bool - _, _, _ = yysep1503, yyq1503, yy2arr1503 - const yyr1503 bool = false - yyq1503[0] = len(x.Add) != 0 - yyq1503[1] = len(x.Drop) != 0 - var yynn1503 int - if yyr1503 || yy2arr1503 { - r.EncodeArrayStart(2) - } else { - yynn1503 = 0 - for _, b := range yyq1503 { - if b { - yynn1503++ - } - } - r.EncodeMapStart(yynn1503) - yynn1503 = 0 - } - if yyr1503 || yy2arr1503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1503[0] { - if x.Add == nil { - r.EncodeNil() - } else { - yym1505 := z.EncBinary() - _ = yym1505 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Add), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1503[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("add")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Add == nil { - r.EncodeNil() - } else { - yym1506 := z.EncBinary() - _ = yym1506 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Add), e) - } - } - } - } - if yyr1503 || yy2arr1503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1503[1] { - if x.Drop == nil { - r.EncodeNil() - } else { - yym1508 := z.EncBinary() - _ = yym1508 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Drop), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1503[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("drop")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Drop == nil { - r.EncodeNil() - } else { - yym1509 := z.EncBinary() - _ = yym1509 - if false { - } else { - h.encSliceCapability(([]Capability)(x.Drop), e) - } - } - } - } - if yyr1503 || yy2arr1503 { - 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 - yym1510 := z.DecBinary() - _ = yym1510 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1511 := r.ContainerType() - if yyct1511 == codecSelferValueTypeMap1234 { - yyl1511 := r.ReadMapStart() - if yyl1511 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1511, d) - } - } else if yyct1511 == codecSelferValueTypeArray1234 { - yyl1511 := r.ReadArrayStart() - if yyl1511 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1511, 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 yys1512Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1512Slc - var yyhl1512 bool = l >= 0 - for yyj1512 := 0; ; yyj1512++ { - if yyhl1512 { - if yyj1512 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1512Slc = r.DecodeBytes(yys1512Slc, true, true) - yys1512 := string(yys1512Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1512 { - case "add": - if r.TryDecodeAsNil() { - x.Add = nil - } else { - yyv1513 := &x.Add - yym1514 := z.DecBinary() - _ = yym1514 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1513), d) - } - } - case "drop": - if r.TryDecodeAsNil() { - x.Drop = nil - } else { - yyv1515 := &x.Drop - yym1516 := z.DecBinary() - _ = yym1516 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1515), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1512) - } // end switch yys1512 - } // end for yyj1512 - 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 yyj1517 int - var yyb1517 bool - var yyhl1517 bool = l >= 0 - yyj1517++ - if yyhl1517 { - yyb1517 = yyj1517 > l - } else { - yyb1517 = r.CheckBreak() - } - if yyb1517 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Add = nil - } else { - yyv1518 := &x.Add - yym1519 := z.DecBinary() - _ = yym1519 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1518), d) - } - } - yyj1517++ - if yyhl1517 { - yyb1517 = yyj1517 > l - } else { - yyb1517 = r.CheckBreak() - } - if yyb1517 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Drop = nil - } else { - yyv1520 := &x.Drop - yym1521 := z.DecBinary() - _ = yym1521 - if false { - } else { - h.decSliceCapability((*[]Capability)(yyv1520), d) - } - } - for { - yyj1517++ - if yyhl1517 { - yyb1517 = yyj1517 > l - } else { - yyb1517 = r.CheckBreak() - } - if yyb1517 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1517-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 { - yym1522 := z.EncBinary() - _ = yym1522 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1523 := !z.EncBinary() - yy2arr1523 := z.EncBasicHandle().StructToArray - var yyq1523 [2]bool - _, _, _ = yysep1523, yyq1523, yy2arr1523 - const yyr1523 bool = false - yyq1523[0] = len(x.Limits) != 0 - yyq1523[1] = len(x.Requests) != 0 - var yynn1523 int - if yyr1523 || yy2arr1523 { - r.EncodeArrayStart(2) - } else { - yynn1523 = 0 - for _, b := range yyq1523 { - if b { - yynn1523++ - } - } - r.EncodeMapStart(yynn1523) - yynn1523 = 0 - } - if yyr1523 || yy2arr1523 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1523[0] { - if x.Limits == nil { - r.EncodeNil() - } else { - x.Limits.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1523[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 yyr1523 || yy2arr1523 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1523[1] { - if x.Requests == nil { - r.EncodeNil() - } else { - x.Requests.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1523[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 yyr1523 || yy2arr1523 { - 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 - yym1526 := z.DecBinary() - _ = yym1526 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1527 := r.ContainerType() - if yyct1527 == codecSelferValueTypeMap1234 { - yyl1527 := r.ReadMapStart() - if yyl1527 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1527, d) - } - } else if yyct1527 == codecSelferValueTypeArray1234 { - yyl1527 := r.ReadArrayStart() - if yyl1527 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1527, 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 yys1528Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1528Slc - var yyhl1528 bool = l >= 0 - for yyj1528 := 0; ; yyj1528++ { - if yyhl1528 { - if yyj1528 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1528Slc = r.DecodeBytes(yys1528Slc, true, true) - yys1528 := string(yys1528Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1528 { - case "limits": - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv1529 := &x.Limits - yyv1529.CodecDecodeSelf(d) - } - case "requests": - if r.TryDecodeAsNil() { - x.Requests = nil - } else { - yyv1530 := &x.Requests - yyv1530.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1528) - } // end switch yys1528 - } // end for yyj1528 - 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 yyj1531 int - var yyb1531 bool - var yyhl1531 bool = l >= 0 - yyj1531++ - if yyhl1531 { - yyb1531 = yyj1531 > l - } else { - yyb1531 = r.CheckBreak() - } - if yyb1531 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv1532 := &x.Limits - yyv1532.CodecDecodeSelf(d) - } - yyj1531++ - if yyhl1531 { - yyb1531 = yyj1531 > l - } else { - yyb1531 = r.CheckBreak() - } - if yyb1531 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Requests = nil - } else { - yyv1533 := &x.Requests - yyv1533.CodecDecodeSelf(d) - } - for { - yyj1531++ - if yyhl1531 { - yyb1531 = yyj1531 > l - } else { - yyb1531 = r.CheckBreak() - } - if yyb1531 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1531-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 { - yym1534 := z.EncBinary() - _ = yym1534 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1535 := !z.EncBinary() - yy2arr1535 := z.EncBasicHandle().StructToArray - var yyq1535 [18]bool - _, _, _ = yysep1535, yyq1535, yy2arr1535 - const yyr1535 bool = false - yyq1535[2] = len(x.Command) != 0 - yyq1535[3] = len(x.Args) != 0 - yyq1535[4] = x.WorkingDir != "" - yyq1535[5] = len(x.Ports) != 0 - yyq1535[6] = len(x.Env) != 0 - yyq1535[7] = true - yyq1535[8] = len(x.VolumeMounts) != 0 - yyq1535[9] = x.LivenessProbe != nil - yyq1535[10] = x.ReadinessProbe != nil - yyq1535[11] = x.Lifecycle != nil - yyq1535[12] = x.TerminationMessagePath != "" - yyq1535[14] = x.SecurityContext != nil - yyq1535[15] = x.Stdin != false - yyq1535[16] = x.StdinOnce != false - yyq1535[17] = x.TTY != false - var yynn1535 int - if yyr1535 || yy2arr1535 { - r.EncodeArrayStart(18) - } else { - yynn1535 = 3 - for _, b := range yyq1535 { - if b { - yynn1535++ - } - } - r.EncodeMapStart(yynn1535) - yynn1535 = 0 - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1537 := z.EncBinary() - _ = yym1537 - 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) - yym1538 := z.EncBinary() - _ = yym1538 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1540 := z.EncBinary() - _ = yym1540 - 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) - yym1541 := z.EncBinary() - _ = yym1541 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[2] { - if x.Command == nil { - r.EncodeNil() - } else { - yym1543 := z.EncBinary() - _ = yym1543 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("command")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Command == nil { - r.EncodeNil() - } else { - yym1544 := z.EncBinary() - _ = yym1544 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[3] { - if x.Args == nil { - r.EncodeNil() - } else { - yym1546 := z.EncBinary() - _ = yym1546 - if false { - } else { - z.F.EncSliceStringV(x.Args, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("args")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Args == nil { - r.EncodeNil() - } else { - yym1547 := z.EncBinary() - _ = yym1547 - if false { - } else { - z.F.EncSliceStringV(x.Args, false, e) - } - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[4] { - yym1549 := z.EncBinary() - _ = yym1549 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1535[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("workingDir")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1550 := z.EncBinary() - _ = yym1550 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir)) - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[5] { - if x.Ports == nil { - r.EncodeNil() - } else { - yym1552 := z.EncBinary() - _ = yym1552 - if false { - } else { - h.encSliceContainerPort(([]ContainerPort)(x.Ports), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ports")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym1553 := z.EncBinary() - _ = yym1553 - if false { - } else { - h.encSliceContainerPort(([]ContainerPort)(x.Ports), e) - } - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[6] { - if x.Env == nil { - r.EncodeNil() - } else { - yym1555 := z.EncBinary() - _ = yym1555 - if false { - } else { - h.encSliceEnvVar(([]EnvVar)(x.Env), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("env")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Env == nil { - r.EncodeNil() - } else { - yym1556 := z.EncBinary() - _ = yym1556 - if false { - } else { - h.encSliceEnvVar(([]EnvVar)(x.Env), e) - } - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[7] { - yy1558 := &x.Resources - yy1558.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1535[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resources")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1559 := &x.Resources - yy1559.CodecEncodeSelf(e) - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[8] { - if x.VolumeMounts == nil { - r.EncodeNil() - } else { - yym1561 := z.EncBinary() - _ = yym1561 - if false { - } else { - h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumeMounts")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumeMounts == nil { - r.EncodeNil() - } else { - yym1562 := z.EncBinary() - _ = yym1562 - if false { - } else { - h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e) - } - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[9] { - if x.LivenessProbe == nil { - r.EncodeNil() - } else { - x.LivenessProbe.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[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 yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[10] { - if x.ReadinessProbe == nil { - r.EncodeNil() - } else { - x.ReadinessProbe.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[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 yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[11] { - if x.Lifecycle == nil { - r.EncodeNil() - } else { - x.Lifecycle.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[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 yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[12] { - yym1567 := z.EncBinary() - _ = yym1567 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1535[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("terminationMessagePath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1568 := z.EncBinary() - _ = yym1568 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath)) - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - x.ImagePullPolicy.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("imagePullPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.ImagePullPolicy.CodecEncodeSelf(e) - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[14] { - if x.SecurityContext == nil { - r.EncodeNil() - } else { - x.SecurityContext.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1535[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 yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[15] { - yym1572 := z.EncBinary() - _ = yym1572 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1535[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdin")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1573 := z.EncBinary() - _ = yym1573 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[16] { - yym1575 := z.EncBinary() - _ = yym1575 - if false { - } else { - r.EncodeBool(bool(x.StdinOnce)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1535[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdinOnce")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1576 := z.EncBinary() - _ = yym1576 - if false { - } else { - r.EncodeBool(bool(x.StdinOnce)) - } - } - } - if yyr1535 || yy2arr1535 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1535[17] { - yym1578 := z.EncBinary() - _ = yym1578 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1535[17] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tty")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1579 := z.EncBinary() - _ = yym1579 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } - } - if yyr1535 || yy2arr1535 { - 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 - yym1580 := z.DecBinary() - _ = yym1580 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1581 := r.ContainerType() - if yyct1581 == codecSelferValueTypeMap1234 { - yyl1581 := r.ReadMapStart() - if yyl1581 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1581, d) - } - } else if yyct1581 == codecSelferValueTypeArray1234 { - yyl1581 := r.ReadArrayStart() - if yyl1581 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1581, 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 yys1582Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1582Slc - var yyhl1582 bool = l >= 0 - for yyj1582 := 0; ; yyj1582++ { - if yyhl1582 { - if yyj1582 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1582Slc = r.DecodeBytes(yys1582Slc, true, true) - yys1582 := string(yys1582Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1582 { - 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 { - yyv1585 := &x.Command - yym1586 := z.DecBinary() - _ = yym1586 - if false { - } else { - z.F.DecSliceStringX(yyv1585, false, d) - } - } - case "args": - if r.TryDecodeAsNil() { - x.Args = nil - } else { - yyv1587 := &x.Args - yym1588 := z.DecBinary() - _ = yym1588 - if false { - } else { - z.F.DecSliceStringX(yyv1587, false, d) - } - } - case "workingDir": - if r.TryDecodeAsNil() { - x.WorkingDir = "" - } else { - x.WorkingDir = string(r.DecodeString()) - } - case "ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv1590 := &x.Ports - yym1591 := z.DecBinary() - _ = yym1591 - if false { - } else { - h.decSliceContainerPort((*[]ContainerPort)(yyv1590), d) - } - } - case "env": - if r.TryDecodeAsNil() { - x.Env = nil - } else { - yyv1592 := &x.Env - yym1593 := z.DecBinary() - _ = yym1593 - if false { - } else { - h.decSliceEnvVar((*[]EnvVar)(yyv1592), d) - } - } - case "resources": - if r.TryDecodeAsNil() { - x.Resources = ResourceRequirements{} - } else { - yyv1594 := &x.Resources - yyv1594.CodecDecodeSelf(d) - } - case "volumeMounts": - if r.TryDecodeAsNil() { - x.VolumeMounts = nil - } else { - yyv1595 := &x.VolumeMounts - yym1596 := z.DecBinary() - _ = yym1596 - if false { - } else { - h.decSliceVolumeMount((*[]VolumeMount)(yyv1595), 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, yys1582) - } // end switch yys1582 - } // end for yyj1582 - 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 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.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - 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.Image = "" - } else { - x.Image = string(r.DecodeString()) - } - 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.Command = nil - } else { - yyv1609 := &x.Command - yym1610 := z.DecBinary() - _ = yym1610 - if false { - } else { - z.F.DecSliceStringX(yyv1609, false, d) - } - } - 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.Args = nil - } else { - yyv1611 := &x.Args - yym1612 := z.DecBinary() - _ = yym1612 - if false { - } else { - z.F.DecSliceStringX(yyv1611, false, d) - } - } - 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.WorkingDir = "" - } else { - x.WorkingDir = string(r.DecodeString()) - } - 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.Ports = nil - } else { - yyv1614 := &x.Ports - yym1615 := z.DecBinary() - _ = yym1615 - if false { - } else { - h.decSliceContainerPort((*[]ContainerPort)(yyv1614), d) - } - } - 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.Env = nil - } else { - yyv1616 := &x.Env - yym1617 := z.DecBinary() - _ = yym1617 - if false { - } else { - h.decSliceEnvVar((*[]EnvVar)(yyv1616), d) - } - } - 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.Resources = ResourceRequirements{} - } else { - yyv1618 := &x.Resources - yyv1618.CodecDecodeSelf(d) - } - 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.VolumeMounts = nil - } else { - yyv1619 := &x.VolumeMounts - yym1620 := z.DecBinary() - _ = yym1620 - if false { - } else { - h.decSliceVolumeMount((*[]VolumeMount)(yyv1619), d) - } - } - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l - } else { - yyb1606 = r.CheckBreak() - } - if yyb1606 { - 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) - } - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l - } else { - yyb1606 = r.CheckBreak() - } - if yyb1606 { - 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) - } - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l - } else { - yyb1606 = r.CheckBreak() - } - if yyb1606 { - 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) - } - 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.TerminationMessagePath = "" - } else { - x.TerminationMessagePath = string(r.DecodeString()) - } - 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.ImagePullPolicy = "" - } else { - x.ImagePullPolicy = PullPolicy(r.DecodeString()) - } - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l - } else { - yyb1606 = r.CheckBreak() - } - if yyb1606 { - 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) - } - 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.Stdin = false - } else { - x.Stdin = bool(r.DecodeBool()) - } - 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.StdinOnce = false - } else { - x.StdinOnce = bool(r.DecodeBool()) - } - 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.TTY = false - } else { - x.TTY = bool(r.DecodeBool()) - } - 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 *Handler) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1630 := z.EncBinary() - _ = yym1630 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1631 := !z.EncBinary() - yy2arr1631 := z.EncBasicHandle().StructToArray - var yyq1631 [3]bool - _, _, _ = yysep1631, yyq1631, yy2arr1631 - const yyr1631 bool = false - yyq1631[0] = x.Exec != nil - yyq1631[1] = x.HTTPGet != nil - yyq1631[2] = x.TCPSocket != nil - var yynn1631 int - if yyr1631 || yy2arr1631 { - r.EncodeArrayStart(3) - } else { - yynn1631 = 0 - for _, b := range yyq1631 { - if b { - yynn1631++ - } - } - r.EncodeMapStart(yynn1631) - yynn1631 = 0 - } - if yyr1631 || yy2arr1631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1631[0] { - if x.Exec == nil { - r.EncodeNil() - } else { - x.Exec.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1631[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 yyr1631 || yy2arr1631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1631[1] { - if x.HTTPGet == nil { - r.EncodeNil() - } else { - x.HTTPGet.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1631[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 yyr1631 || yy2arr1631 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1631[2] { - if x.TCPSocket == nil { - r.EncodeNil() - } else { - x.TCPSocket.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1631[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 yyr1631 || yy2arr1631 { - 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 - yym1635 := z.DecBinary() - _ = yym1635 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1636 := r.ContainerType() - if yyct1636 == codecSelferValueTypeMap1234 { - yyl1636 := r.ReadMapStart() - if yyl1636 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1636, d) - } - } else if yyct1636 == codecSelferValueTypeArray1234 { - yyl1636 := r.ReadArrayStart() - if yyl1636 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1636, 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 yys1637Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1637Slc - var yyhl1637 bool = l >= 0 - for yyj1637 := 0; ; yyj1637++ { - if yyhl1637 { - if yyj1637 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1637Slc = r.DecodeBytes(yys1637Slc, true, true) - yys1637 := string(yys1637Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1637 { - 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, yys1637) - } // end switch yys1637 - } // end for yyj1637 - 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 yyj1641 int - var yyb1641 bool - var yyhl1641 bool = l >= 0 - yyj1641++ - if yyhl1641 { - yyb1641 = yyj1641 > l - } else { - yyb1641 = r.CheckBreak() - } - if yyb1641 { - 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) - } - yyj1641++ - if yyhl1641 { - yyb1641 = yyj1641 > l - } else { - yyb1641 = r.CheckBreak() - } - if yyb1641 { - 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) - } - yyj1641++ - if yyhl1641 { - yyb1641 = yyj1641 > l - } else { - yyb1641 = r.CheckBreak() - } - if yyb1641 { - 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 { - yyj1641++ - if yyhl1641 { - yyb1641 = yyj1641 > l - } else { - yyb1641 = r.CheckBreak() - } - if yyb1641 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1641-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 { - yym1645 := z.EncBinary() - _ = yym1645 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1646 := !z.EncBinary() - yy2arr1646 := z.EncBasicHandle().StructToArray - var yyq1646 [2]bool - _, _, _ = yysep1646, yyq1646, yy2arr1646 - const yyr1646 bool = false - yyq1646[0] = x.PostStart != nil - yyq1646[1] = x.PreStop != nil - var yynn1646 int - if yyr1646 || yy2arr1646 { - r.EncodeArrayStart(2) - } else { - yynn1646 = 0 - for _, b := range yyq1646 { - if b { - yynn1646++ - } - } - r.EncodeMapStart(yynn1646) - yynn1646 = 0 - } - if yyr1646 || yy2arr1646 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1646[0] { - if x.PostStart == nil { - r.EncodeNil() - } else { - x.PostStart.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1646[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 yyr1646 || yy2arr1646 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1646[1] { - if x.PreStop == nil { - r.EncodeNil() - } else { - x.PreStop.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1646[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 yyr1646 || yy2arr1646 { - 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 - yym1649 := z.DecBinary() - _ = yym1649 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1650 := r.ContainerType() - if yyct1650 == codecSelferValueTypeMap1234 { - yyl1650 := r.ReadMapStart() - if yyl1650 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1650, d) - } - } else if yyct1650 == codecSelferValueTypeArray1234 { - yyl1650 := r.ReadArrayStart() - if yyl1650 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1650, 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 yys1651Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1651Slc - var yyhl1651 bool = l >= 0 - for yyj1651 := 0; ; yyj1651++ { - if yyhl1651 { - if yyj1651 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1651Slc = r.DecodeBytes(yys1651Slc, true, true) - yys1651 := string(yys1651Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1651 { - 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, yys1651) - } // end switch yys1651 - } // end for yyj1651 - 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 yyj1654 int - var yyb1654 bool - var yyhl1654 bool = l >= 0 - yyj1654++ - if yyhl1654 { - yyb1654 = yyj1654 > l - } else { - yyb1654 = r.CheckBreak() - } - if yyb1654 { - 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) - } - yyj1654++ - if yyhl1654 { - yyb1654 = yyj1654 > l - } else { - yyb1654 = r.CheckBreak() - } - if yyb1654 { - 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 { - yyj1654++ - if yyhl1654 { - yyb1654 = yyj1654 > l - } else { - yyb1654 = r.CheckBreak() - } - if yyb1654 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1654-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ConditionStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1657 := z.EncBinary() - _ = yym1657 - 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 - yym1658 := z.DecBinary() - _ = yym1658 - 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 { - yym1659 := z.EncBinary() - _ = yym1659 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1660 := !z.EncBinary() - yy2arr1660 := z.EncBasicHandle().StructToArray - var yyq1660 [2]bool - _, _, _ = yysep1660, yyq1660, yy2arr1660 - const yyr1660 bool = false - yyq1660[0] = x.Reason != "" - yyq1660[1] = x.Message != "" - var yynn1660 int - if yyr1660 || yy2arr1660 { - r.EncodeArrayStart(2) - } else { - yynn1660 = 0 - for _, b := range yyq1660 { - if b { - yynn1660++ - } - } - r.EncodeMapStart(yynn1660) - yynn1660 = 0 - } - if yyr1660 || yy2arr1660 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1660[0] { - yym1662 := z.EncBinary() - _ = yym1662 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1660[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1663 := z.EncBinary() - _ = yym1663 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr1660 || yy2arr1660 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1660[1] { - yym1665 := z.EncBinary() - _ = yym1665 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1660[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1666 := z.EncBinary() - _ = yym1666 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr1660 || yy2arr1660 { - 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 - yym1667 := z.DecBinary() - _ = yym1667 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1668 := r.ContainerType() - if yyct1668 == codecSelferValueTypeMap1234 { - yyl1668 := r.ReadMapStart() - if yyl1668 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1668, d) - } - } else if yyct1668 == codecSelferValueTypeArray1234 { - yyl1668 := r.ReadArrayStart() - if yyl1668 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1668, 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 yys1669Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1669Slc - var yyhl1669 bool = l >= 0 - for yyj1669 := 0; ; yyj1669++ { - if yyhl1669 { - if yyj1669 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1669Slc = r.DecodeBytes(yys1669Slc, true, true) - yys1669 := string(yys1669Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1669 { - 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, yys1669) - } // end switch yys1669 - } // end for yyj1669 - 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 yyj1672 int - var yyb1672 bool - var yyhl1672 bool = l >= 0 - yyj1672++ - if yyhl1672 { - yyb1672 = yyj1672 > l - } else { - yyb1672 = r.CheckBreak() - } - if yyb1672 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1672++ - if yyhl1672 { - yyb1672 = yyj1672 > l - } else { - yyb1672 = r.CheckBreak() - } - if yyb1672 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj1672++ - if yyhl1672 { - yyb1672 = yyj1672 > l - } else { - yyb1672 = r.CheckBreak() - } - if yyb1672 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1672-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 { - yym1675 := z.EncBinary() - _ = yym1675 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1676 := !z.EncBinary() - yy2arr1676 := z.EncBasicHandle().StructToArray - var yyq1676 [1]bool - _, _, _ = yysep1676, yyq1676, yy2arr1676 - const yyr1676 bool = false - yyq1676[0] = true - var yynn1676 int - if yyr1676 || yy2arr1676 { - r.EncodeArrayStart(1) - } else { - yynn1676 = 0 - for _, b := range yyq1676 { - if b { - yynn1676++ - } - } - r.EncodeMapStart(yynn1676) - yynn1676 = 0 - } - if yyr1676 || yy2arr1676 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1676[0] { - yy1678 := &x.StartedAt - yym1679 := z.EncBinary() - _ = yym1679 - if false { - } else if z.HasExtensions() && z.EncExt(yy1678) { - } else if yym1679 { - z.EncBinaryMarshal(yy1678) - } else if !yym1679 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1678) - } else { - z.EncFallback(yy1678) - } - } else { - r.EncodeNil() - } - } else { - if yyq1676[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1680 := &x.StartedAt - yym1681 := z.EncBinary() - _ = yym1681 - if false { - } else if z.HasExtensions() && z.EncExt(yy1680) { - } else if yym1681 { - z.EncBinaryMarshal(yy1680) - } else if !yym1681 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1680) - } else { - z.EncFallback(yy1680) - } - } - } - if yyr1676 || yy2arr1676 { - 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 - yym1682 := z.DecBinary() - _ = yym1682 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1683 := r.ContainerType() - if yyct1683 == codecSelferValueTypeMap1234 { - yyl1683 := r.ReadMapStart() - if yyl1683 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1683, d) - } - } else if yyct1683 == codecSelferValueTypeArray1234 { - yyl1683 := r.ReadArrayStart() - if yyl1683 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1683, 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 yys1684Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1684Slc - var yyhl1684 bool = l >= 0 - for yyj1684 := 0; ; yyj1684++ { - if yyhl1684 { - if yyj1684 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1684Slc = r.DecodeBytes(yys1684Slc, true, true) - yys1684 := string(yys1684Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1684 { - case "startedAt": - if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} - } else { - yyv1685 := &x.StartedAt - yym1686 := z.DecBinary() - _ = yym1686 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1685) { - } else if yym1686 { - z.DecBinaryUnmarshal(yyv1685) - } else if !yym1686 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1685) - } else { - z.DecFallback(yyv1685, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1684) - } // end switch yys1684 - } // end for yyj1684 - 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 yyj1687 int - var yyb1687 bool - var yyhl1687 bool = l >= 0 - yyj1687++ - if yyhl1687 { - yyb1687 = yyj1687 > l - } else { - yyb1687 = r.CheckBreak() - } - if yyb1687 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} - } else { - yyv1688 := &x.StartedAt - yym1689 := z.DecBinary() - _ = yym1689 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1688) { - } else if yym1689 { - z.DecBinaryUnmarshal(yyv1688) - } else if !yym1689 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1688) - } else { - z.DecFallback(yyv1688, false) - } - } - for { - yyj1687++ - if yyhl1687 { - yyb1687 = yyj1687 > l - } else { - yyb1687 = r.CheckBreak() - } - if yyb1687 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1687-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 { - yym1690 := z.EncBinary() - _ = yym1690 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1691 := !z.EncBinary() - yy2arr1691 := z.EncBasicHandle().StructToArray - var yyq1691 [7]bool - _, _, _ = yysep1691, yyq1691, yy2arr1691 - const yyr1691 bool = false - yyq1691[1] = x.Signal != 0 - yyq1691[2] = x.Reason != "" - yyq1691[3] = x.Message != "" - yyq1691[4] = true - yyq1691[5] = true - yyq1691[6] = x.ContainerID != "" - var yynn1691 int - if yyr1691 || yy2arr1691 { - r.EncodeArrayStart(7) - } else { - yynn1691 = 1 - for _, b := range yyq1691 { - if b { - yynn1691++ - } - } - r.EncodeMapStart(yynn1691) - yynn1691 = 0 - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1693 := z.EncBinary() - _ = yym1693 - if false { - } else { - r.EncodeInt(int64(x.ExitCode)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exitCode")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1694 := z.EncBinary() - _ = yym1694 - if false { - } else { - r.EncodeInt(int64(x.ExitCode)) - } - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1691[1] { - yym1696 := z.EncBinary() - _ = yym1696 - if false { - } else { - r.EncodeInt(int64(x.Signal)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq1691[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("signal")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1697 := z.EncBinary() - _ = yym1697 - if false { - } else { - r.EncodeInt(int64(x.Signal)) - } - } - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1691[2] { - yym1699 := z.EncBinary() - _ = yym1699 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1691[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1700 := z.EncBinary() - _ = yym1700 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1691[3] { - yym1702 := z.EncBinary() - _ = yym1702 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1691[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1703 := z.EncBinary() - _ = yym1703 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1691[4] { - yy1705 := &x.StartedAt - yym1706 := z.EncBinary() - _ = yym1706 - if false { - } else if z.HasExtensions() && z.EncExt(yy1705) { - } else if yym1706 { - z.EncBinaryMarshal(yy1705) - } else if !yym1706 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1705) - } else { - z.EncFallback(yy1705) - } - } else { - r.EncodeNil() - } - } else { - if yyq1691[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1707 := &x.StartedAt - yym1708 := z.EncBinary() - _ = yym1708 - if false { - } else if z.HasExtensions() && z.EncExt(yy1707) { - } else if yym1708 { - z.EncBinaryMarshal(yy1707) - } else if !yym1708 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1707) - } else { - z.EncFallback(yy1707) - } - } - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1691[5] { - yy1710 := &x.FinishedAt - yym1711 := z.EncBinary() - _ = yym1711 - if false { - } else if z.HasExtensions() && z.EncExt(yy1710) { - } else if yym1711 { - z.EncBinaryMarshal(yy1710) - } else if !yym1711 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1710) - } else { - z.EncFallback(yy1710) - } - } else { - r.EncodeNil() - } - } else { - if yyq1691[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finishedAt")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1712 := &x.FinishedAt - yym1713 := z.EncBinary() - _ = yym1713 - if false { - } else if z.HasExtensions() && z.EncExt(yy1712) { - } else if yym1713 { - z.EncBinaryMarshal(yy1712) - } else if !yym1713 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1712) - } else { - z.EncFallback(yy1712) - } - } - } - if yyr1691 || yy2arr1691 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1691[6] { - yym1715 := z.EncBinary() - _ = yym1715 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1691[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1716 := z.EncBinary() - _ = yym1716 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } - } - if yyr1691 || yy2arr1691 { - 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 - yym1717 := z.DecBinary() - _ = yym1717 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1718 := r.ContainerType() - if yyct1718 == codecSelferValueTypeMap1234 { - yyl1718 := r.ReadMapStart() - if yyl1718 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1718, d) - } - } else if yyct1718 == codecSelferValueTypeArray1234 { - yyl1718 := r.ReadArrayStart() - if yyl1718 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1718, 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 yys1719Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1719Slc - var yyhl1719 bool = l >= 0 - for yyj1719 := 0; ; yyj1719++ { - if yyhl1719 { - if yyj1719 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1719Slc = r.DecodeBytes(yys1719Slc, true, true) - yys1719 := string(yys1719Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1719 { - 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 { - yyv1724 := &x.StartedAt - yym1725 := z.DecBinary() - _ = yym1725 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1724) { - } else if yym1725 { - z.DecBinaryUnmarshal(yyv1724) - } else if !yym1725 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1724) - } else { - z.DecFallback(yyv1724, false) - } - } - case "finishedAt": - if r.TryDecodeAsNil() { - x.FinishedAt = pkg2_unversioned.Time{} - } else { - yyv1726 := &x.FinishedAt - yym1727 := z.DecBinary() - _ = yym1727 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1726) { - } else if yym1727 { - z.DecBinaryUnmarshal(yyv1726) - } else if !yym1727 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1726) - } else { - z.DecFallback(yyv1726, false) - } - } - case "containerID": - if r.TryDecodeAsNil() { - x.ContainerID = "" - } else { - x.ContainerID = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys1719) - } // end switch yys1719 - } // end for yyj1719 - 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 yyj1729 int - var yyb1729 bool - var yyhl1729 bool = l >= 0 - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExitCode = 0 - } else { - x.ExitCode = int32(r.DecodeInt(32)) - } - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Signal = 0 - } else { - x.Signal = int32(r.DecodeInt(32)) - } - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} - } else { - yyv1734 := &x.StartedAt - yym1735 := z.DecBinary() - _ = yym1735 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1734) { - } else if yym1735 { - z.DecBinaryUnmarshal(yyv1734) - } else if !yym1735 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1734) - } else { - z.DecFallback(yyv1734, false) - } - } - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FinishedAt = pkg2_unversioned.Time{} - } else { - yyv1736 := &x.FinishedAt - yym1737 := z.DecBinary() - _ = yym1737 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1736) { - } else if yym1737 { - z.DecBinaryUnmarshal(yyv1736) - } else if !yym1737 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1736) - } else { - z.DecFallback(yyv1736, false) - } - } - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerID = "" - } else { - x.ContainerID = string(r.DecodeString()) - } - for { - yyj1729++ - if yyhl1729 { - yyb1729 = yyj1729 > l - } else { - yyb1729 = r.CheckBreak() - } - if yyb1729 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1729-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 { - yym1739 := z.EncBinary() - _ = yym1739 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1740 := !z.EncBinary() - yy2arr1740 := z.EncBasicHandle().StructToArray - var yyq1740 [3]bool - _, _, _ = yysep1740, yyq1740, yy2arr1740 - const yyr1740 bool = false - yyq1740[0] = x.Waiting != nil - yyq1740[1] = x.Running != nil - yyq1740[2] = x.Terminated != nil - var yynn1740 int - if yyr1740 || yy2arr1740 { - r.EncodeArrayStart(3) - } else { - yynn1740 = 0 - for _, b := range yyq1740 { - if b { - yynn1740++ - } - } - r.EncodeMapStart(yynn1740) - yynn1740 = 0 - } - if yyr1740 || yy2arr1740 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1740[0] { - if x.Waiting == nil { - r.EncodeNil() - } else { - x.Waiting.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1740[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 yyr1740 || yy2arr1740 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1740[1] { - if x.Running == nil { - r.EncodeNil() - } else { - x.Running.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1740[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 yyr1740 || yy2arr1740 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1740[2] { - if x.Terminated == nil { - r.EncodeNil() - } else { - x.Terminated.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1740[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 yyr1740 || yy2arr1740 { - 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 - yym1744 := z.DecBinary() - _ = yym1744 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1745 := r.ContainerType() - if yyct1745 == codecSelferValueTypeMap1234 { - yyl1745 := r.ReadMapStart() - if yyl1745 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1745, d) - } - } else if yyct1745 == codecSelferValueTypeArray1234 { - yyl1745 := r.ReadArrayStart() - if yyl1745 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1745, 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 yys1746Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1746Slc - var yyhl1746 bool = l >= 0 - for yyj1746 := 0; ; yyj1746++ { - if yyhl1746 { - if yyj1746 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1746Slc = r.DecodeBytes(yys1746Slc, true, true) - yys1746 := string(yys1746Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1746 { - 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, yys1746) - } // end switch yys1746 - } // end for yyj1746 - 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 yyj1750 int - var yyb1750 bool - var yyhl1750 bool = l >= 0 - yyj1750++ - if yyhl1750 { - yyb1750 = yyj1750 > l - } else { - yyb1750 = r.CheckBreak() - } - if yyb1750 { - 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) - } - yyj1750++ - if yyhl1750 { - yyb1750 = yyj1750 > l - } else { - yyb1750 = r.CheckBreak() - } - if yyb1750 { - 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) - } - yyj1750++ - if yyhl1750 { - yyb1750 = yyj1750 > l - } else { - yyb1750 = r.CheckBreak() - } - if yyb1750 { - 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 { - yyj1750++ - if yyhl1750 { - yyb1750 = yyj1750 > l - } else { - yyb1750 = r.CheckBreak() - } - if yyb1750 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1750-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 { - yym1754 := z.EncBinary() - _ = yym1754 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1755 := !z.EncBinary() - yy2arr1755 := z.EncBasicHandle().StructToArray - var yyq1755 [8]bool - _, _, _ = yysep1755, yyq1755, yy2arr1755 - const yyr1755 bool = false - yyq1755[1] = true - yyq1755[2] = true - yyq1755[7] = x.ContainerID != "" - var yynn1755 int - if yyr1755 || yy2arr1755 { - r.EncodeArrayStart(8) - } else { - yynn1755 = 5 - for _, b := range yyq1755 { - if b { - yynn1755++ - } - } - r.EncodeMapStart(yynn1755) - yynn1755 = 0 - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1757 := z.EncBinary() - _ = yym1757 - 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) - yym1758 := z.EncBinary() - _ = yym1758 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1755[1] { - yy1760 := &x.State - yy1760.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1755[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("state")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1761 := &x.State - yy1761.CodecEncodeSelf(e) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1755[2] { - yy1763 := &x.LastTerminationState - yy1763.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1755[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastState")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1764 := &x.LastTerminationState - yy1764.CodecEncodeSelf(e) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1766 := z.EncBinary() - _ = yym1766 - if false { - } else { - r.EncodeBool(bool(x.Ready)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ready")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1767 := z.EncBinary() - _ = yym1767 - if false { - } else { - r.EncodeBool(bool(x.Ready)) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1769 := z.EncBinary() - _ = yym1769 - if false { - } else { - r.EncodeInt(int64(x.RestartCount)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("restartCount")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1770 := z.EncBinary() - _ = yym1770 - if false { - } else { - r.EncodeInt(int64(x.RestartCount)) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1772 := z.EncBinary() - _ = yym1772 - 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) - yym1773 := z.EncBinary() - _ = yym1773 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1775 := z.EncBinary() - _ = yym1775 - 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) - yym1776 := z.EncBinary() - _ = yym1776 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ImageID)) - } - } - if yyr1755 || yy2arr1755 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1755[7] { - yym1778 := z.EncBinary() - _ = yym1778 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1755[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1779 := z.EncBinary() - _ = yym1779 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) - } - } - } - if yyr1755 || yy2arr1755 { - 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 - yym1780 := z.DecBinary() - _ = yym1780 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1781 := r.ContainerType() - if yyct1781 == codecSelferValueTypeMap1234 { - yyl1781 := r.ReadMapStart() - if yyl1781 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1781, d) - } - } else if yyct1781 == codecSelferValueTypeArray1234 { - yyl1781 := r.ReadArrayStart() - if yyl1781 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1781, 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 yys1782Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1782Slc - var yyhl1782 bool = l >= 0 - for yyj1782 := 0; ; yyj1782++ { - if yyhl1782 { - if yyj1782 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1782Slc = r.DecodeBytes(yys1782Slc, true, true) - yys1782 := string(yys1782Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1782 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "state": - if r.TryDecodeAsNil() { - x.State = ContainerState{} - } else { - yyv1784 := &x.State - yyv1784.CodecDecodeSelf(d) - } - case "lastState": - if r.TryDecodeAsNil() { - x.LastTerminationState = ContainerState{} - } else { - yyv1785 := &x.LastTerminationState - yyv1785.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, yys1782) - } // end switch yys1782 - } // end for yyj1782 - 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 yyj1791 int - var yyb1791 bool - var yyhl1791 bool = l >= 0 - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.State = ContainerState{} - } else { - yyv1793 := &x.State - yyv1793.CodecDecodeSelf(d) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTerminationState = ContainerState{} - } else { - yyv1794 := &x.LastTerminationState - yyv1794.CodecDecodeSelf(d) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ready = false - } else { - x.Ready = bool(r.DecodeBool()) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RestartCount = 0 - } else { - x.RestartCount = int32(r.DecodeInt(32)) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Image = "" - } else { - x.Image = string(r.DecodeString()) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImageID = "" - } else { - x.ImageID = string(r.DecodeString()) - } - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerID = "" - } else { - x.ContainerID = string(r.DecodeString()) - } - for { - yyj1791++ - if yyhl1791 { - yyb1791 = yyj1791 > l - } else { - yyb1791 = r.CheckBreak() - } - if yyb1791 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1791-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PodPhase) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1800 := z.EncBinary() - _ = yym1800 - 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 - yym1801 := z.DecBinary() - _ = yym1801 - 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 - yym1802 := z.EncBinary() - _ = yym1802 - 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 - yym1803 := z.DecBinary() - _ = yym1803 - 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 { - yym1804 := z.EncBinary() - _ = yym1804 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1805 := !z.EncBinary() - yy2arr1805 := z.EncBasicHandle().StructToArray - var yyq1805 [6]bool - _, _, _ = yysep1805, yyq1805, yy2arr1805 - const yyr1805 bool = false - yyq1805[2] = true - yyq1805[3] = true - yyq1805[4] = x.Reason != "" - yyq1805[5] = x.Message != "" - var yynn1805 int - if yyr1805 || yy2arr1805 { - r.EncodeArrayStart(6) - } else { - yynn1805 = 2 - for _, b := range yyq1805 { - if b { - yynn1805++ - } - } - r.EncodeMapStart(yynn1805) - yynn1805 = 0 - } - if yyr1805 || yy2arr1805 { - 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 yyr1805 || yy2arr1805 { - 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 yyr1805 || yy2arr1805 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1805[2] { - yy1809 := &x.LastProbeTime - yym1810 := z.EncBinary() - _ = yym1810 - if false { - } else if z.HasExtensions() && z.EncExt(yy1809) { - } else if yym1810 { - z.EncBinaryMarshal(yy1809) - } else if !yym1810 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1809) - } else { - z.EncFallback(yy1809) - } - } else { - r.EncodeNil() - } - } else { - if yyq1805[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1811 := &x.LastProbeTime - yym1812 := z.EncBinary() - _ = yym1812 - if false { - } else if z.HasExtensions() && z.EncExt(yy1811) { - } else if yym1812 { - z.EncBinaryMarshal(yy1811) - } else if !yym1812 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1811) - } else { - z.EncFallback(yy1811) - } - } - } - if yyr1805 || yy2arr1805 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1805[3] { - yy1814 := &x.LastTransitionTime - yym1815 := z.EncBinary() - _ = yym1815 - if false { - } else if z.HasExtensions() && z.EncExt(yy1814) { - } else if yym1815 { - z.EncBinaryMarshal(yy1814) - } else if !yym1815 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1814) - } else { - z.EncFallback(yy1814) - } - } else { - r.EncodeNil() - } - } else { - if yyq1805[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1816 := &x.LastTransitionTime - yym1817 := z.EncBinary() - _ = yym1817 - if false { - } else if z.HasExtensions() && z.EncExt(yy1816) { - } else if yym1817 { - z.EncBinaryMarshal(yy1816) - } else if !yym1817 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1816) - } else { - z.EncFallback(yy1816) - } - } - } - if yyr1805 || yy2arr1805 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1805[4] { - yym1819 := z.EncBinary() - _ = yym1819 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1805[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1820 := z.EncBinary() - _ = yym1820 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr1805 || yy2arr1805 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1805[5] { - yym1822 := z.EncBinary() - _ = yym1822 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1805[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1823 := z.EncBinary() - _ = yym1823 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr1805 || yy2arr1805 { - 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 - yym1824 := z.DecBinary() - _ = yym1824 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1825 := r.ContainerType() - if yyct1825 == codecSelferValueTypeMap1234 { - yyl1825 := r.ReadMapStart() - if yyl1825 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1825, d) - } - } else if yyct1825 == codecSelferValueTypeArray1234 { - yyl1825 := r.ReadArrayStart() - if yyl1825 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1825, 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 yys1826Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1826Slc - var yyhl1826 bool = l >= 0 - for yyj1826 := 0; ; yyj1826++ { - if yyhl1826 { - if yyj1826 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1826Slc = r.DecodeBytes(yys1826Slc, true, true) - yys1826 := string(yys1826Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1826 { - 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 { - yyv1829 := &x.LastProbeTime - yym1830 := z.DecBinary() - _ = yym1830 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1829) { - } else if yym1830 { - z.DecBinaryUnmarshal(yyv1829) - } else if !yym1830 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1829) - } else { - z.DecFallback(yyv1829, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv1831 := &x.LastTransitionTime - yym1832 := z.DecBinary() - _ = yym1832 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1831) { - } else if yym1832 { - z.DecBinaryUnmarshal(yyv1831) - } else if !yym1832 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1831) - } else { - z.DecFallback(yyv1831, 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, yys1826) - } // end switch yys1826 - } // end for yyj1826 - 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 yyj1835 int - var yyb1835 bool - var yyhl1835 bool = l >= 0 - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = PodConditionType(r.DecodeString()) - } - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastProbeTime = pkg2_unversioned.Time{} - } else { - yyv1838 := &x.LastProbeTime - yym1839 := z.DecBinary() - _ = yym1839 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1838) { - } else if yym1839 { - z.DecBinaryUnmarshal(yyv1838) - } else if !yym1839 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1838) - } else { - z.DecFallback(yyv1838, false) - } - } - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv1840 := &x.LastTransitionTime - yym1841 := z.DecBinary() - _ = yym1841 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1840) { - } else if yym1841 { - z.DecBinaryUnmarshal(yyv1840) - } else if !yym1841 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1840) - } else { - z.DecFallback(yyv1840, false) - } - } - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj1835++ - if yyhl1835 { - yyb1835 = yyj1835 > l - } else { - yyb1835 = r.CheckBreak() - } - if yyb1835 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1835-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x RestartPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1844 := z.EncBinary() - _ = yym1844 - 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 - yym1845 := z.DecBinary() - _ = yym1845 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *PodList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1846 := z.EncBinary() - _ = yym1846 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1847 := !z.EncBinary() - yy2arr1847 := z.EncBasicHandle().StructToArray - var yyq1847 [4]bool - _, _, _ = yysep1847, yyq1847, yy2arr1847 - const yyr1847 bool = false - yyq1847[0] = x.Kind != "" - yyq1847[1] = x.APIVersion != "" - yyq1847[2] = true - var yynn1847 int - if yyr1847 || yy2arr1847 { - r.EncodeArrayStart(4) - } else { - yynn1847 = 1 - for _, b := range yyq1847 { - if b { - yynn1847++ - } - } - r.EncodeMapStart(yynn1847) - yynn1847 = 0 - } - if yyr1847 || yy2arr1847 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1847[0] { - yym1849 := z.EncBinary() - _ = yym1849 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1847[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1850 := z.EncBinary() - _ = yym1850 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr1847 || yy2arr1847 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1847[1] { - yym1852 := z.EncBinary() - _ = yym1852 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1847[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1853 := z.EncBinary() - _ = yym1853 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1847 || yy2arr1847 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1847[2] { - yy1855 := &x.ListMeta - yym1856 := z.EncBinary() - _ = yym1856 - if false { - } else if z.HasExtensions() && z.EncExt(yy1855) { - } else { - z.EncFallback(yy1855) - } - } else { - r.EncodeNil() - } - } else { - if yyq1847[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1857 := &x.ListMeta - yym1858 := z.EncBinary() - _ = yym1858 - if false { - } else if z.HasExtensions() && z.EncExt(yy1857) { - } else { - z.EncFallback(yy1857) - } - } - } - if yyr1847 || yy2arr1847 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1860 := z.EncBinary() - _ = yym1860 - 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 { - yym1861 := z.EncBinary() - _ = yym1861 - if false { - } else { - h.encSlicePod(([]Pod)(x.Items), e) - } - } - } - if yyr1847 || yy2arr1847 { - 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 - yym1862 := z.DecBinary() - _ = yym1862 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1863 := r.ContainerType() - if yyct1863 == codecSelferValueTypeMap1234 { - yyl1863 := r.ReadMapStart() - if yyl1863 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1863, d) - } - } else if yyct1863 == codecSelferValueTypeArray1234 { - yyl1863 := r.ReadArrayStart() - if yyl1863 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1863, 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 yys1864Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1864Slc - var yyhl1864 bool = l >= 0 - for yyj1864 := 0; ; yyj1864++ { - if yyhl1864 { - if yyj1864 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1864Slc = r.DecodeBytes(yys1864Slc, true, true) - yys1864 := string(yys1864Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1864 { - 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 { - yyv1867 := &x.ListMeta - yym1868 := z.DecBinary() - _ = yym1868 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1867) { - } else { - z.DecFallback(yyv1867, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1869 := &x.Items - yym1870 := z.DecBinary() - _ = yym1870 - if false { - } else { - h.decSlicePod((*[]Pod)(yyv1869), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1864) - } // end switch yys1864 - } // end for yyj1864 - 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 yyj1871 int - var yyb1871 bool - var yyhl1871 bool = l >= 0 - yyj1871++ - if yyhl1871 { - yyb1871 = yyj1871 > l - } else { - yyb1871 = r.CheckBreak() - } - if yyb1871 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj1871++ - if yyhl1871 { - yyb1871 = yyj1871 > l - } else { - yyb1871 = r.CheckBreak() - } - if yyb1871 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1871++ - if yyhl1871 { - yyb1871 = yyj1871 > l - } else { - yyb1871 = r.CheckBreak() - } - if yyb1871 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv1874 := &x.ListMeta - yym1875 := z.DecBinary() - _ = yym1875 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1874) { - } else { - z.DecFallback(yyv1874, false) - } - } - yyj1871++ - if yyhl1871 { - yyb1871 = yyj1871 > l - } else { - yyb1871 = r.CheckBreak() - } - if yyb1871 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1876 := &x.Items - yym1877 := z.DecBinary() - _ = yym1877 - if false { - } else { - h.decSlicePod((*[]Pod)(yyv1876), d) - } - } - for { - yyj1871++ - if yyhl1871 { - yyb1871 = yyj1871 > l - } else { - yyb1871 = r.CheckBreak() - } - if yyb1871 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1871-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x DNSPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1878 := z.EncBinary() - _ = yym1878 - 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 - yym1879 := z.DecBinary() - _ = yym1879 - 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 { - yym1880 := z.EncBinary() - _ = yym1880 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1881 := !z.EncBinary() - yy2arr1881 := z.EncBasicHandle().StructToArray - var yyq1881 [1]bool - _, _, _ = yysep1881, yyq1881, yy2arr1881 - const yyr1881 bool = false - var yynn1881 int - if yyr1881 || yy2arr1881 { - r.EncodeArrayStart(1) - } else { - yynn1881 = 1 - for _, b := range yyq1881 { - if b { - yynn1881++ - } - } - r.EncodeMapStart(yynn1881) - yynn1881 = 0 - } - if yyr1881 || yy2arr1881 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.NodeSelectorTerms == nil { - r.EncodeNil() - } else { - yym1883 := z.EncBinary() - _ = yym1883 - 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 { - yym1884 := z.EncBinary() - _ = yym1884 - if false { - } else { - h.encSliceNodeSelectorTerm(([]NodeSelectorTerm)(x.NodeSelectorTerms), e) - } - } - } - if yyr1881 || yy2arr1881 { - 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 - yym1885 := z.DecBinary() - _ = yym1885 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1886 := r.ContainerType() - if yyct1886 == codecSelferValueTypeMap1234 { - yyl1886 := r.ReadMapStart() - if yyl1886 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1886, d) - } - } else if yyct1886 == codecSelferValueTypeArray1234 { - yyl1886 := r.ReadArrayStart() - if yyl1886 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1886, 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 yys1887Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1887Slc - var yyhl1887 bool = l >= 0 - for yyj1887 := 0; ; yyj1887++ { - if yyhl1887 { - if yyj1887 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1887Slc = r.DecodeBytes(yys1887Slc, true, true) - yys1887 := string(yys1887Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1887 { - case "nodeSelectorTerms": - if r.TryDecodeAsNil() { - x.NodeSelectorTerms = nil - } else { - yyv1888 := &x.NodeSelectorTerms - yym1889 := z.DecBinary() - _ = yym1889 - if false { - } else { - h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv1888), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1887) - } // end switch yys1887 - } // end for yyj1887 - 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 yyj1890 int - var yyb1890 bool - var yyhl1890 bool = l >= 0 - yyj1890++ - if yyhl1890 { - yyb1890 = yyj1890 > l - } else { - yyb1890 = r.CheckBreak() - } - if yyb1890 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeSelectorTerms = nil - } else { - yyv1891 := &x.NodeSelectorTerms - yym1892 := z.DecBinary() - _ = yym1892 - if false { - } else { - h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv1891), d) - } - } - for { - yyj1890++ - if yyhl1890 { - yyb1890 = yyj1890 > l - } else { - yyb1890 = r.CheckBreak() - } - if yyb1890 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1890-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 { - yym1893 := z.EncBinary() - _ = yym1893 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1894 := !z.EncBinary() - yy2arr1894 := z.EncBasicHandle().StructToArray - var yyq1894 [1]bool - _, _, _ = yysep1894, yyq1894, yy2arr1894 - const yyr1894 bool = false - var yynn1894 int - if yyr1894 || yy2arr1894 { - r.EncodeArrayStart(1) - } else { - yynn1894 = 1 - for _, b := range yyq1894 { - if b { - yynn1894++ - } - } - r.EncodeMapStart(yynn1894) - yynn1894 = 0 - } - if yyr1894 || yy2arr1894 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.MatchExpressions == nil { - r.EncodeNil() - } else { - yym1896 := z.EncBinary() - _ = yym1896 - 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 { - yym1897 := z.EncBinary() - _ = yym1897 - if false { - } else { - h.encSliceNodeSelectorRequirement(([]NodeSelectorRequirement)(x.MatchExpressions), e) - } - } - } - if yyr1894 || yy2arr1894 { - 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 - 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 *NodeSelectorTerm) 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 "matchExpressions": - if r.TryDecodeAsNil() { - x.MatchExpressions = nil - } else { - yyv1901 := &x.MatchExpressions - yym1902 := z.DecBinary() - _ = yym1902 - if false { - } else { - h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv1901), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1900) - } // end switch yys1900 - } // end for yyj1900 - 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 yyj1903 int - var yyb1903 bool - var yyhl1903 bool = l >= 0 - yyj1903++ - if yyhl1903 { - yyb1903 = yyj1903 > l - } else { - yyb1903 = r.CheckBreak() - } - if yyb1903 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MatchExpressions = nil - } else { - yyv1904 := &x.MatchExpressions - yym1905 := z.DecBinary() - _ = yym1905 - if false { - } else { - h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv1904), d) - } - } - for { - yyj1903++ - if yyhl1903 { - yyb1903 = yyj1903 > l - } else { - yyb1903 = r.CheckBreak() - } - if yyb1903 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1903-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 { - yym1906 := z.EncBinary() - _ = yym1906 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1907 := !z.EncBinary() - yy2arr1907 := z.EncBasicHandle().StructToArray - var yyq1907 [3]bool - _, _, _ = yysep1907, yyq1907, yy2arr1907 - const yyr1907 bool = false - yyq1907[2] = len(x.Values) != 0 - var yynn1907 int - if yyr1907 || yy2arr1907 { - r.EncodeArrayStart(3) - } else { - yynn1907 = 2 - for _, b := range yyq1907 { - if b { - yynn1907++ - } - } - r.EncodeMapStart(yynn1907) - yynn1907 = 0 - } - if yyr1907 || yy2arr1907 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1909 := z.EncBinary() - _ = yym1909 - 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) - yym1910 := z.EncBinary() - _ = yym1910 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr1907 || yy2arr1907 { - 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 yyr1907 || yy2arr1907 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1907[2] { - if x.Values == nil { - r.EncodeNil() - } else { - yym1913 := z.EncBinary() - _ = yym1913 - if false { - } else { - z.F.EncSliceStringV(x.Values, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1907[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("values")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Values == nil { - r.EncodeNil() - } else { - yym1914 := z.EncBinary() - _ = yym1914 - if false { - } else { - z.F.EncSliceStringV(x.Values, false, e) - } - } - } - } - if yyr1907 || yy2arr1907 { - 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 - yym1915 := z.DecBinary() - _ = yym1915 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1916 := r.ContainerType() - if yyct1916 == codecSelferValueTypeMap1234 { - yyl1916 := r.ReadMapStart() - if yyl1916 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1916, d) - } - } else if yyct1916 == codecSelferValueTypeArray1234 { - yyl1916 := r.ReadArrayStart() - if yyl1916 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1916, 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 yys1917Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1917Slc - var yyhl1917 bool = l >= 0 - for yyj1917 := 0; ; yyj1917++ { - if yyhl1917 { - if yyj1917 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1917Slc = r.DecodeBytes(yys1917Slc, true, true) - yys1917 := string(yys1917Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1917 { - 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 { - yyv1920 := &x.Values - yym1921 := z.DecBinary() - _ = yym1921 - if false { - } else { - z.F.DecSliceStringX(yyv1920, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1917) - } // end switch yys1917 - } // end for yyj1917 - 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 yyj1922 int - var yyb1922 bool - var yyhl1922 bool = l >= 0 - yyj1922++ - if yyhl1922 { - yyb1922 = yyj1922 > l - } else { - yyb1922 = r.CheckBreak() - } - if yyb1922 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj1922++ - if yyhl1922 { - yyb1922 = yyj1922 > l - } else { - yyb1922 = r.CheckBreak() - } - if yyb1922 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Operator = "" - } else { - x.Operator = NodeSelectorOperator(r.DecodeString()) - } - yyj1922++ - if yyhl1922 { - yyb1922 = yyj1922 > l - } else { - yyb1922 = r.CheckBreak() - } - if yyb1922 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Values = nil - } else { - yyv1925 := &x.Values - yym1926 := z.DecBinary() - _ = yym1926 - if false { - } else { - z.F.DecSliceStringX(yyv1925, false, d) - } - } - for { - yyj1922++ - if yyhl1922 { - yyb1922 = yyj1922 > l - } else { - yyb1922 = r.CheckBreak() - } - if yyb1922 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1922-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NodeSelectorOperator) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1927 := z.EncBinary() - _ = yym1927 - 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 - yym1928 := z.DecBinary() - _ = yym1928 - 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 { - yym1929 := z.EncBinary() - _ = yym1929 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1930 := !z.EncBinary() - yy2arr1930 := z.EncBasicHandle().StructToArray - var yyq1930 [3]bool - _, _, _ = yysep1930, yyq1930, yy2arr1930 - const yyr1930 bool = false - yyq1930[0] = x.NodeAffinity != nil - yyq1930[1] = x.PodAffinity != nil - yyq1930[2] = x.PodAntiAffinity != nil - var yynn1930 int - if yyr1930 || yy2arr1930 { - r.EncodeArrayStart(3) - } else { - yynn1930 = 0 - for _, b := range yyq1930 { - if b { - yynn1930++ - } - } - r.EncodeMapStart(yynn1930) - yynn1930 = 0 - } - if yyr1930 || yy2arr1930 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1930[0] { - if x.NodeAffinity == nil { - r.EncodeNil() - } else { - x.NodeAffinity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1930[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 yyr1930 || yy2arr1930 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1930[1] { - if x.PodAffinity == nil { - r.EncodeNil() - } else { - x.PodAffinity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1930[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 yyr1930 || yy2arr1930 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1930[2] { - if x.PodAntiAffinity == nil { - r.EncodeNil() - } else { - x.PodAntiAffinity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1930[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 yyr1930 || yy2arr1930 { - 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 - yym1934 := z.DecBinary() - _ = yym1934 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1935 := r.ContainerType() - if yyct1935 == codecSelferValueTypeMap1234 { - yyl1935 := r.ReadMapStart() - if yyl1935 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1935, d) - } - } else if yyct1935 == codecSelferValueTypeArray1234 { - yyl1935 := r.ReadArrayStart() - if yyl1935 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1935, 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 yys1936Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1936Slc - var yyhl1936 bool = l >= 0 - for yyj1936 := 0; ; yyj1936++ { - if yyhl1936 { - if yyj1936 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1936Slc = r.DecodeBytes(yys1936Slc, true, true) - yys1936 := string(yys1936Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1936 { - 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, yys1936) - } // end switch yys1936 - } // end for yyj1936 - 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 yyj1940 int - var yyb1940 bool - var yyhl1940 bool = l >= 0 - yyj1940++ - if yyhl1940 { - yyb1940 = yyj1940 > l - } else { - yyb1940 = r.CheckBreak() - } - if yyb1940 { - 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) - } - yyj1940++ - if yyhl1940 { - yyb1940 = yyj1940 > l - } else { - yyb1940 = r.CheckBreak() - } - if yyb1940 { - 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) - } - yyj1940++ - if yyhl1940 { - yyb1940 = yyj1940 > l - } else { - yyb1940 = r.CheckBreak() - } - if yyb1940 { - 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 { - yyj1940++ - if yyhl1940 { - yyb1940 = yyj1940 > l - } else { - yyb1940 = r.CheckBreak() - } - if yyb1940 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1940-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 { - yym1944 := z.EncBinary() - _ = yym1944 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1945 := !z.EncBinary() - yy2arr1945 := z.EncBasicHandle().StructToArray - var yyq1945 [2]bool - _, _, _ = yysep1945, yyq1945, yy2arr1945 - const yyr1945 bool = false - yyq1945[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 - yyq1945[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1945 int - if yyr1945 || yy2arr1945 { - r.EncodeArrayStart(2) - } else { - yynn1945 = 0 - for _, b := range yyq1945 { - if b { - yynn1945++ - } - } - r.EncodeMapStart(yynn1945) - yynn1945 = 0 - } - if yyr1945 || yy2arr1945 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1945[0] { - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1947 := z.EncBinary() - _ = yym1947 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1945[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1948 := z.EncBinary() - _ = yym1948 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1945 || yy2arr1945 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1945[1] { - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1950 := z.EncBinary() - _ = yym1950 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1945[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1951 := z.EncBinary() - _ = yym1951 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1945 || yy2arr1945 { - 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 - yym1952 := z.DecBinary() - _ = yym1952 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1953 := r.ContainerType() - if yyct1953 == codecSelferValueTypeMap1234 { - yyl1953 := r.ReadMapStart() - if yyl1953 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1953, d) - } - } else if yyct1953 == codecSelferValueTypeArray1234 { - yyl1953 := r.ReadArrayStart() - if yyl1953 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1953, 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 yys1954Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1954Slc - var yyhl1954 bool = l >= 0 - for yyj1954 := 0; ; yyj1954++ { - if yyhl1954 { - if yyj1954 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1954Slc = r.DecodeBytes(yys1954Slc, true, true) - yys1954 := string(yys1954Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1954 { - case "requiredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1955 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1956 := z.DecBinary() - _ = yym1956 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1955), d) - } - } - case "preferredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1957 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1958 := z.DecBinary() - _ = yym1958 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1957), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1954) - } // end switch yys1954 - } // end for yyj1954 - 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 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.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1960 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1961 := z.DecBinary() - _ = yym1961 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1960), d) - } - } - 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.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1962 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1963 := z.DecBinary() - _ = yym1963 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1962), d) - } - } - 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 *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1964 := z.EncBinary() - _ = yym1964 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1965 := !z.EncBinary() - yy2arr1965 := z.EncBasicHandle().StructToArray - var yyq1965 [2]bool - _, _, _ = yysep1965, yyq1965, yy2arr1965 - const yyr1965 bool = false - yyq1965[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 - yyq1965[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1965 int - if yyr1965 || yy2arr1965 { - r.EncodeArrayStart(2) - } else { - yynn1965 = 0 - for _, b := range yyq1965 { - if b { - yynn1965++ - } - } - r.EncodeMapStart(yynn1965) - yynn1965 = 0 - } - if yyr1965 || yy2arr1965 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1965[0] { - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1967 := z.EncBinary() - _ = yym1967 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1965[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1968 := z.EncBinary() - _ = yym1968 - if false { - } else { - h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1965 || yy2arr1965 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1965[1] { - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1970 := z.EncBinary() - _ = yym1970 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1965[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym1971 := z.EncBinary() - _ = yym1971 - if false { - } else { - h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr1965 || yy2arr1965 { - 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 - yym1972 := z.DecBinary() - _ = yym1972 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1973 := r.ContainerType() - if yyct1973 == codecSelferValueTypeMap1234 { - yyl1973 := r.ReadMapStart() - if yyl1973 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1973, d) - } - } else if yyct1973 == codecSelferValueTypeArray1234 { - yyl1973 := r.ReadArrayStart() - if yyl1973 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1973, 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 yys1974Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1974Slc - var yyhl1974 bool = l >= 0 - for yyj1974 := 0; ; yyj1974++ { - if yyhl1974 { - if yyj1974 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1974Slc = r.DecodeBytes(yys1974Slc, true, true) - yys1974 := string(yys1974Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1974 { - case "requiredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1975 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1976 := z.DecBinary() - _ = yym1976 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1975), d) - } - } - case "preferredDuringSchedulingIgnoredDuringExecution": - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1977 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1978 := z.DecBinary() - _ = yym1978 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1977), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1974) - } // end switch yys1974 - } // end for yyj1974 - 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 yyj1979 int - var yyb1979 bool - var yyhl1979 bool = l >= 0 - yyj1979++ - if yyhl1979 { - yyb1979 = yyj1979 > l - } else { - yyb1979 = r.CheckBreak() - } - if yyb1979 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RequiredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1980 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1981 := z.DecBinary() - _ = yym1981 - if false { - } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1980), d) - } - } - yyj1979++ - if yyhl1979 { - yyb1979 = yyj1979 > l - } else { - yyb1979 = r.CheckBreak() - } - if yyb1979 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv1982 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1983 := z.DecBinary() - _ = yym1983 - if false { - } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1982), d) - } - } - for { - yyj1979++ - if yyhl1979 { - yyb1979 = yyj1979 > l - } else { - yyb1979 = r.CheckBreak() - } - if yyb1979 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1979-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 { - yym1984 := z.EncBinary() - _ = yym1984 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1985 := !z.EncBinary() - yy2arr1985 := z.EncBasicHandle().StructToArray - var yyq1985 [2]bool - _, _, _ = yysep1985, yyq1985, yy2arr1985 - const yyr1985 bool = false - var yynn1985 int - if yyr1985 || yy2arr1985 { - r.EncodeArrayStart(2) - } else { - yynn1985 = 2 - for _, b := range yyq1985 { - if b { - yynn1985++ - } - } - r.EncodeMapStart(yynn1985) - yynn1985 = 0 - } - if yyr1985 || yy2arr1985 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1987 := z.EncBinary() - _ = yym1987 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("weight")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1988 := z.EncBinary() - _ = yym1988 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } - if yyr1985 || yy2arr1985 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1990 := &x.PodAffinityTerm - yy1990.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podAffinityTerm")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1991 := &x.PodAffinityTerm - yy1991.CodecEncodeSelf(e) - } - if yyr1985 || yy2arr1985 { - 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 - yym1992 := z.DecBinary() - _ = yym1992 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1993 := r.ContainerType() - if yyct1993 == codecSelferValueTypeMap1234 { - yyl1993 := r.ReadMapStart() - if yyl1993 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1993, d) - } - } else if yyct1993 == codecSelferValueTypeArray1234 { - yyl1993 := r.ReadArrayStart() - if yyl1993 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1993, 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 yys1994Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1994Slc - var yyhl1994 bool = l >= 0 - for yyj1994 := 0; ; yyj1994++ { - if yyhl1994 { - if yyj1994 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1994Slc = r.DecodeBytes(yys1994Slc, true, true) - yys1994 := string(yys1994Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1994 { - case "weight": - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - case "podAffinityTerm": - if r.TryDecodeAsNil() { - x.PodAffinityTerm = PodAffinityTerm{} - } else { - yyv1996 := &x.PodAffinityTerm - yyv1996.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1994) - } // end switch yys1994 - } // end for yyj1994 - 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 yyj1997 int - var yyb1997 bool - var yyhl1997 bool = l >= 0 - yyj1997++ - if yyhl1997 { - yyb1997 = yyj1997 > l - } else { - yyb1997 = r.CheckBreak() - } - if yyb1997 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - yyj1997++ - if yyhl1997 { - yyb1997 = yyj1997 > l - } else { - yyb1997 = r.CheckBreak() - } - if yyb1997 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodAffinityTerm = PodAffinityTerm{} - } else { - yyv1999 := &x.PodAffinityTerm - yyv1999.CodecDecodeSelf(d) - } - for { - yyj1997++ - if yyhl1997 { - yyb1997 = yyj1997 > l - } else { - yyb1997 = r.CheckBreak() - } - if yyb1997 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1997-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 { - yym2000 := z.EncBinary() - _ = yym2000 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2001 := !z.EncBinary() - yy2arr2001 := z.EncBasicHandle().StructToArray - var yyq2001 [3]bool - _, _, _ = yysep2001, yyq2001, yy2arr2001 - const yyr2001 bool = false - yyq2001[0] = x.LabelSelector != nil - yyq2001[2] = x.TopologyKey != "" - var yynn2001 int - if yyr2001 || yy2arr2001 { - r.EncodeArrayStart(3) - } else { - yynn2001 = 1 - for _, b := range yyq2001 { - if b { - yynn2001++ - } - } - r.EncodeMapStart(yynn2001) - yynn2001 = 0 - } - if yyr2001 || yy2arr2001 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2001[0] { - if x.LabelSelector == nil { - r.EncodeNil() - } else { - yym2003 := z.EncBinary() - _ = yym2003 - if false { - } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { - } else { - z.EncFallback(x.LabelSelector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2001[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labelSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LabelSelector == nil { - r.EncodeNil() - } else { - yym2004 := z.EncBinary() - _ = yym2004 - if false { - } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { - } else { - z.EncFallback(x.LabelSelector) - } - } - } - } - if yyr2001 || yy2arr2001 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Namespaces == nil { - r.EncodeNil() - } else { - yym2006 := z.EncBinary() - _ = yym2006 - 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 { - yym2007 := z.EncBinary() - _ = yym2007 - if false { - } else { - z.F.EncSliceStringV(x.Namespaces, false, e) - } - } - } - if yyr2001 || yy2arr2001 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2001[2] { - yym2009 := z.EncBinary() - _ = yym2009 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2001[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("topologyKey")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2010 := z.EncBinary() - _ = yym2010 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey)) - } - } - } - if yyr2001 || yy2arr2001 { - 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 - yym2011 := z.DecBinary() - _ = yym2011 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2012 := r.ContainerType() - if yyct2012 == codecSelferValueTypeMap1234 { - yyl2012 := r.ReadMapStart() - if yyl2012 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2012, d) - } - } else if yyct2012 == codecSelferValueTypeArray1234 { - yyl2012 := r.ReadArrayStart() - if yyl2012 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2012, 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 yys2013Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2013Slc - var yyhl2013 bool = l >= 0 - for yyj2013 := 0; ; yyj2013++ { - if yyhl2013 { - if yyj2013 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2013Slc = r.DecodeBytes(yys2013Slc, true, true) - yys2013 := string(yys2013Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2013 { - case "labelSelector": - if r.TryDecodeAsNil() { - if x.LabelSelector != nil { - x.LabelSelector = nil - } - } else { - if x.LabelSelector == nil { - x.LabelSelector = new(pkg2_unversioned.LabelSelector) - } - yym2015 := z.DecBinary() - _ = yym2015 - 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 { - yyv2016 := &x.Namespaces - yym2017 := z.DecBinary() - _ = yym2017 - if false { - } else { - z.F.DecSliceStringX(yyv2016, false, d) - } - } - case "topologyKey": - if r.TryDecodeAsNil() { - x.TopologyKey = "" - } else { - x.TopologyKey = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys2013) - } // end switch yys2013 - } // end for yyj2013 - 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 yyj2019 int - var yyb2019 bool - var yyhl2019 bool = l >= 0 - yyj2019++ - if yyhl2019 { - yyb2019 = yyj2019 > l - } else { - yyb2019 = r.CheckBreak() - } - if yyb2019 { - 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) - } - yym2021 := z.DecBinary() - _ = yym2021 - if false { - } else if z.HasExtensions() && z.DecExt(x.LabelSelector) { - } else { - z.DecFallback(x.LabelSelector, false) - } - } - yyj2019++ - if yyhl2019 { - yyb2019 = yyj2019 > l - } else { - yyb2019 = r.CheckBreak() - } - if yyb2019 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespaces = nil - } else { - yyv2022 := &x.Namespaces - yym2023 := z.DecBinary() - _ = yym2023 - if false { - } else { - z.F.DecSliceStringX(yyv2022, false, d) - } - } - yyj2019++ - if yyhl2019 { - yyb2019 = yyj2019 > l - } else { - yyb2019 = r.CheckBreak() - } - if yyb2019 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TopologyKey = "" - } else { - x.TopologyKey = string(r.DecodeString()) - } - for { - yyj2019++ - if yyhl2019 { - yyb2019 = yyj2019 > l - } else { - yyb2019 = r.CheckBreak() - } - if yyb2019 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2019-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 { - yym2025 := z.EncBinary() - _ = yym2025 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2026 := !z.EncBinary() - yy2arr2026 := z.EncBasicHandle().StructToArray - var yyq2026 [2]bool - _, _, _ = yysep2026, yyq2026, yy2arr2026 - const yyr2026 bool = false - yyq2026[0] = x.RequiredDuringSchedulingIgnoredDuringExecution != nil - yyq2026[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn2026 int - if yyr2026 || yy2arr2026 { - r.EncodeArrayStart(2) - } else { - yynn2026 = 0 - for _, b := range yyq2026 { - if b { - yynn2026++ - } - } - r.EncodeMapStart(yynn2026) - yynn2026 = 0 - } - if yyr2026 || yy2arr2026 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2026[0] { - if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - x.RequiredDuringSchedulingIgnoredDuringExecution.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2026[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 yyr2026 || yy2arr2026 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2026[1] { - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym2029 := z.EncBinary() - _ = yym2029 - if false { - } else { - h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2026[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { - r.EncodeNil() - } else { - yym2030 := z.EncBinary() - _ = yym2030 - if false { - } else { - h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) - } - } - } - } - if yyr2026 || yy2arr2026 { - 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 - yym2031 := z.DecBinary() - _ = yym2031 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2032 := r.ContainerType() - if yyct2032 == codecSelferValueTypeMap1234 { - yyl2032 := r.ReadMapStart() - if yyl2032 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2032, d) - } - } else if yyct2032 == codecSelferValueTypeArray1234 { - yyl2032 := r.ReadArrayStart() - if yyl2032 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2032, 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 yys2033Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2033Slc - var yyhl2033 bool = l >= 0 - for yyj2033 := 0; ; yyj2033++ { - if yyhl2033 { - if yyj2033 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2033Slc = r.DecodeBytes(yys2033Slc, true, true) - yys2033 := string(yys2033Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2033 { - 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 { - yyv2035 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym2036 := z.DecBinary() - _ = yym2036 - if false { - } else { - h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv2035), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2033) - } // end switch yys2033 - } // end for yyj2033 - 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 yyj2037 int - var yyb2037 bool - var yyhl2037 bool = l >= 0 - yyj2037++ - if yyhl2037 { - yyb2037 = yyj2037 > l - } else { - yyb2037 = r.CheckBreak() - } - if yyb2037 { - 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) - } - yyj2037++ - if yyhl2037 { - yyb2037 = yyj2037 > l - } else { - yyb2037 = r.CheckBreak() - } - if yyb2037 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferredDuringSchedulingIgnoredDuringExecution = nil - } else { - yyv2039 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym2040 := z.DecBinary() - _ = yym2040 - if false { - } else { - h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv2039), d) - } - } - for { - yyj2037++ - if yyhl2037 { - yyb2037 = yyj2037 > l - } else { - yyb2037 = r.CheckBreak() - } - if yyb2037 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2037-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 { - yym2041 := z.EncBinary() - _ = yym2041 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2042 := !z.EncBinary() - yy2arr2042 := z.EncBasicHandle().StructToArray - var yyq2042 [2]bool - _, _, _ = yysep2042, yyq2042, yy2arr2042 - const yyr2042 bool = false - var yynn2042 int - if yyr2042 || yy2arr2042 { - r.EncodeArrayStart(2) - } else { - yynn2042 = 2 - for _, b := range yyq2042 { - if b { - yynn2042++ - } - } - r.EncodeMapStart(yynn2042) - yynn2042 = 0 - } - if yyr2042 || yy2arr2042 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2044 := z.EncBinary() - _ = yym2044 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("weight")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2045 := z.EncBinary() - _ = yym2045 - if false { - } else { - r.EncodeInt(int64(x.Weight)) - } - } - if yyr2042 || yy2arr2042 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy2047 := &x.Preference - yy2047.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preference")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2048 := &x.Preference - yy2048.CodecEncodeSelf(e) - } - if yyr2042 || yy2arr2042 { - 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 - yym2049 := z.DecBinary() - _ = yym2049 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2050 := r.ContainerType() - if yyct2050 == codecSelferValueTypeMap1234 { - yyl2050 := r.ReadMapStart() - if yyl2050 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2050, d) - } - } else if yyct2050 == codecSelferValueTypeArray1234 { - yyl2050 := r.ReadArrayStart() - if yyl2050 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2050, 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 yys2051Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2051Slc - var yyhl2051 bool = l >= 0 - for yyj2051 := 0; ; yyj2051++ { - if yyhl2051 { - if yyj2051 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2051Slc = r.DecodeBytes(yys2051Slc, true, true) - yys2051 := string(yys2051Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2051 { - case "weight": - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - case "preference": - if r.TryDecodeAsNil() { - x.Preference = NodeSelectorTerm{} - } else { - yyv2053 := &x.Preference - yyv2053.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2051) - } // end switch yys2051 - } // end for yyj2051 - 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 yyj2054 int - var yyb2054 bool - var yyhl2054 bool = l >= 0 - yyj2054++ - if yyhl2054 { - yyb2054 = yyj2054 > l - } else { - yyb2054 = r.CheckBreak() - } - if yyb2054 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Weight = 0 - } else { - x.Weight = int32(r.DecodeInt(32)) - } - yyj2054++ - if yyhl2054 { - yyb2054 = yyj2054 > l - } else { - yyb2054 = r.CheckBreak() - } - if yyb2054 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Preference = NodeSelectorTerm{} - } else { - yyv2056 := &x.Preference - yyv2056.CodecDecodeSelf(d) - } - for { - yyj2054++ - if yyhl2054 { - yyb2054 = yyj2054 > l - } else { - yyb2054 = r.CheckBreak() - } - if yyb2054 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2054-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 { - yym2057 := z.EncBinary() - _ = yym2057 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2058 := !z.EncBinary() - yy2arr2058 := z.EncBasicHandle().StructToArray - var yyq2058 [3]bool - _, _, _ = yysep2058, yyq2058, yy2arr2058 - const yyr2058 bool = false - yyq2058[1] = x.Value != "" - var yynn2058 int - if yyr2058 || yy2arr2058 { - r.EncodeArrayStart(3) - } else { - yynn2058 = 2 - for _, b := range yyq2058 { - if b { - yynn2058++ - } - } - r.EncodeMapStart(yynn2058) - yynn2058 = 0 - } - if yyr2058 || yy2arr2058 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2060 := z.EncBinary() - _ = yym2060 - 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) - yym2061 := z.EncBinary() - _ = yym2061 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - if yyr2058 || yy2arr2058 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2058[1] { - yym2063 := z.EncBinary() - _ = yym2063 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2058[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2064 := z.EncBinary() - _ = yym2064 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - } - if yyr2058 || yy2arr2058 { - 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 yyr2058 || yy2arr2058 { - 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 - yym2066 := z.DecBinary() - _ = yym2066 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2067 := r.ContainerType() - if yyct2067 == codecSelferValueTypeMap1234 { - yyl2067 := r.ReadMapStart() - if yyl2067 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2067, d) - } - } else if yyct2067 == codecSelferValueTypeArray1234 { - yyl2067 := r.ReadArrayStart() - if yyl2067 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2067, 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 yys2068Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2068Slc - var yyhl2068 bool = l >= 0 - for yyj2068 := 0; ; yyj2068++ { - if yyhl2068 { - if yyj2068 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2068Slc = r.DecodeBytes(yys2068Slc, true, true) - yys2068 := string(yys2068Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2068 { - 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, yys2068) - } // end switch yys2068 - } // end for yyj2068 - 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 yyj2072 int - var yyb2072 bool - var yyhl2072 bool = l >= 0 - yyj2072++ - if yyhl2072 { - yyb2072 = yyj2072 > l - } else { - yyb2072 = r.CheckBreak() - } - if yyb2072 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj2072++ - if yyhl2072 { - yyb2072 = yyj2072 > l - } else { - yyb2072 = r.CheckBreak() - } - if yyb2072 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - yyj2072++ - if yyhl2072 { - yyb2072 = yyj2072 > l - } else { - yyb2072 = r.CheckBreak() - } - if yyb2072 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Effect = "" - } else { - x.Effect = TaintEffect(r.DecodeString()) - } - for { - yyj2072++ - if yyhl2072 { - yyb2072 = yyj2072 > l - } else { - yyb2072 = r.CheckBreak() - } - if yyb2072 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2072-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x TaintEffect) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym2076 := z.EncBinary() - _ = yym2076 - 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 - yym2077 := z.DecBinary() - _ = yym2077 - 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 { - yym2078 := z.EncBinary() - _ = yym2078 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2079 := !z.EncBinary() - yy2arr2079 := z.EncBasicHandle().StructToArray - var yyq2079 [4]bool - _, _, _ = yysep2079, yyq2079, yy2arr2079 - const yyr2079 bool = false - yyq2079[0] = x.Key != "" - yyq2079[1] = x.Operator != "" - yyq2079[2] = x.Value != "" - yyq2079[3] = x.Effect != "" - var yynn2079 int - if yyr2079 || yy2arr2079 { - r.EncodeArrayStart(4) - } else { - yynn2079 = 0 - for _, b := range yyq2079 { - if b { - yynn2079++ - } - } - r.EncodeMapStart(yynn2079) - yynn2079 = 0 - } - if yyr2079 || yy2arr2079 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2079[0] { - yym2081 := z.EncBinary() - _ = yym2081 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2079[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("key")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2082 := z.EncBinary() - _ = yym2082 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) - } - } - } - if yyr2079 || yy2arr2079 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2079[1] { - x.Operator.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2079[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("operator")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Operator.CodecEncodeSelf(e) - } - } - if yyr2079 || yy2arr2079 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2079[2] { - yym2085 := z.EncBinary() - _ = yym2085 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2079[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2086 := z.EncBinary() - _ = yym2086 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - } - if yyr2079 || yy2arr2079 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2079[3] { - x.Effect.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2079[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("effect")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Effect.CodecEncodeSelf(e) - } - } - if yyr2079 || yy2arr2079 { - 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 - yym2088 := z.DecBinary() - _ = yym2088 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2089 := r.ContainerType() - if yyct2089 == codecSelferValueTypeMap1234 { - yyl2089 := r.ReadMapStart() - if yyl2089 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2089, d) - } - } else if yyct2089 == codecSelferValueTypeArray1234 { - yyl2089 := r.ReadArrayStart() - if yyl2089 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2089, 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 yys2090Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2090Slc - var yyhl2090 bool = l >= 0 - for yyj2090 := 0; ; yyj2090++ { - if yyhl2090 { - if yyj2090 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2090Slc = r.DecodeBytes(yys2090Slc, true, true) - yys2090 := string(yys2090Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2090 { - 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, yys2090) - } // end switch yys2090 - } // end for yyj2090 - 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 yyj2095 int - var yyb2095 bool - var yyhl2095 bool = l >= 0 - yyj2095++ - if yyhl2095 { - yyb2095 = yyj2095 > l - } else { - yyb2095 = r.CheckBreak() - } - if yyb2095 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Key = "" - } else { - x.Key = string(r.DecodeString()) - } - yyj2095++ - if yyhl2095 { - yyb2095 = yyj2095 > l - } else { - yyb2095 = r.CheckBreak() - } - if yyb2095 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Operator = "" - } else { - x.Operator = TolerationOperator(r.DecodeString()) - } - yyj2095++ - if yyhl2095 { - yyb2095 = yyj2095 > l - } else { - yyb2095 = r.CheckBreak() - } - if yyb2095 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - yyj2095++ - if yyhl2095 { - yyb2095 = yyj2095 > l - } else { - yyb2095 = r.CheckBreak() - } - if yyb2095 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Effect = "" - } else { - x.Effect = TaintEffect(r.DecodeString()) - } - for { - yyj2095++ - if yyhl2095 { - yyb2095 = yyj2095 > l - } else { - yyb2095 = r.CheckBreak() - } - if yyb2095 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2095-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x TolerationOperator) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym2100 := z.EncBinary() - _ = yym2100 - 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 - yym2101 := z.DecBinary() - _ = yym2101 - 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 { - yym2102 := z.EncBinary() - _ = yym2102 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2103 := !z.EncBinary() - yy2arr2103 := z.EncBasicHandle().StructToArray - var yyq2103 [13]bool - _, _, _ = yysep2103, yyq2103, yy2arr2103 - const yyr2103 bool = false - yyq2103[2] = x.RestartPolicy != "" - yyq2103[3] = x.TerminationGracePeriodSeconds != nil - yyq2103[4] = x.ActiveDeadlineSeconds != nil - yyq2103[5] = x.DNSPolicy != "" - yyq2103[6] = len(x.NodeSelector) != 0 - yyq2103[8] = x.NodeName != "" - yyq2103[9] = x.SecurityContext != nil - yyq2103[10] = len(x.ImagePullSecrets) != 0 - yyq2103[11] = x.Hostname != "" - yyq2103[12] = x.Subdomain != "" - var yynn2103 int - if yyr2103 || yy2arr2103 { - r.EncodeArrayStart(13) - } else { - yynn2103 = 3 - for _, b := range yyq2103 { - if b { - yynn2103++ - } - } - r.EncodeMapStart(yynn2103) - yynn2103 = 0 - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Volumes == nil { - r.EncodeNil() - } else { - yym2105 := z.EncBinary() - _ = yym2105 - if false { - } else { - h.encSliceVolume(([]Volume)(x.Volumes), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Volumes == nil { - r.EncodeNil() - } else { - yym2106 := z.EncBinary() - _ = yym2106 - if false { - } else { - h.encSliceVolume(([]Volume)(x.Volumes), e) - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Containers == nil { - r.EncodeNil() - } else { - yym2108 := z.EncBinary() - _ = yym2108 - 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 { - yym2109 := z.EncBinary() - _ = yym2109 - if false { - } else { - h.encSliceContainer(([]Container)(x.Containers), e) - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[2] { - x.RestartPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2103[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("restartPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.RestartPolicy.CodecEncodeSelf(e) - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[3] { - if x.TerminationGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy2112 := *x.TerminationGracePeriodSeconds - yym2113 := z.EncBinary() - _ = yym2113 - if false { - } else { - r.EncodeInt(int64(yy2112)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2103[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("terminationGracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TerminationGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy2114 := *x.TerminationGracePeriodSeconds - yym2115 := z.EncBinary() - _ = yym2115 - if false { - } else { - r.EncodeInt(int64(yy2114)) - } - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[4] { - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy2117 := *x.ActiveDeadlineSeconds - yym2118 := z.EncBinary() - _ = yym2118 - if false { - } else { - r.EncodeInt(int64(yy2117)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2103[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy2119 := *x.ActiveDeadlineSeconds - yym2120 := z.EncBinary() - _ = yym2120 - if false { - } else { - r.EncodeInt(int64(yy2119)) - } - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[5] { - x.DNSPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2103[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("dnsPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.DNSPolicy.CodecEncodeSelf(e) - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[6] { - if x.NodeSelector == nil { - r.EncodeNil() - } else { - yym2123 := z.EncBinary() - _ = yym2123 - if false { - } else { - z.F.EncMapStringStringV(x.NodeSelector, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2103[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NodeSelector == nil { - r.EncodeNil() - } else { - yym2124 := z.EncBinary() - _ = yym2124 - if false { - } else { - z.F.EncMapStringStringV(x.NodeSelector, false, e) - } - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2126 := z.EncBinary() - _ = yym2126 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("serviceAccountName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2127 := z.EncBinary() - _ = yym2127 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName)) - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[8] { - yym2129 := z.EncBinary() - _ = yym2129 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.NodeName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2103[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2130 := z.EncBinary() - _ = yym2130 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.NodeName)) - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[9] { - if x.SecurityContext == nil { - r.EncodeNil() - } else { - x.SecurityContext.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2103[9] { - 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 yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[10] { - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2133 := z.EncBinary() - _ = yym2133 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2103[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2134 := z.EncBinary() - _ = yym2134 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[11] { - yym2136 := z.EncBinary() - _ = yym2136 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2103[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostname")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2137 := z.EncBinary() - _ = yym2137 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } - } - if yyr2103 || yy2arr2103 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2103[12] { - yym2139 := z.EncBinary() - _ = yym2139 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2103[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("subdomain")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2140 := z.EncBinary() - _ = yym2140 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain)) - } - } - } - if yyr2103 || yy2arr2103 { - 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 - yym2141 := z.DecBinary() - _ = yym2141 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2142 := r.ContainerType() - if yyct2142 == codecSelferValueTypeMap1234 { - yyl2142 := r.ReadMapStart() - if yyl2142 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2142, d) - } - } else if yyct2142 == codecSelferValueTypeArray1234 { - yyl2142 := r.ReadArrayStart() - if yyl2142 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2142, 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 yys2143Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2143Slc - var yyhl2143 bool = l >= 0 - for yyj2143 := 0; ; yyj2143++ { - if yyhl2143 { - if yyj2143 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2143Slc = r.DecodeBytes(yys2143Slc, true, true) - yys2143 := string(yys2143Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2143 { - case "volumes": - if r.TryDecodeAsNil() { - x.Volumes = nil - } else { - yyv2144 := &x.Volumes - yym2145 := z.DecBinary() - _ = yym2145 - if false { - } else { - h.decSliceVolume((*[]Volume)(yyv2144), d) - } - } - case "containers": - if r.TryDecodeAsNil() { - x.Containers = nil - } else { - yyv2146 := &x.Containers - yym2147 := z.DecBinary() - _ = yym2147 - if false { - } else { - h.decSliceContainer((*[]Container)(yyv2146), 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) - } - yym2150 := z.DecBinary() - _ = yym2150 - 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) - } - yym2152 := z.DecBinary() - _ = yym2152 - 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 { - yyv2154 := &x.NodeSelector - yym2155 := z.DecBinary() - _ = yym2155 - if false { - } else { - z.F.DecMapStringStringX(yyv2154, false, d) - } - } - case "serviceAccountName": - if r.TryDecodeAsNil() { - x.ServiceAccountName = "" - } else { - x.ServiceAccountName = string(r.DecodeString()) - } - case "nodeName": - if r.TryDecodeAsNil() { - x.NodeName = "" - } else { - x.NodeName = string(r.DecodeString()) - } - 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 { - yyv2159 := &x.ImagePullSecrets - yym2160 := z.DecBinary() - _ = yym2160 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2159), 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, yys2143) - } // end switch yys2143 - } // end for yyj2143 - 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 yyj2163 int - var yyb2163 bool - var yyhl2163 bool = l >= 0 - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Volumes = nil - } else { - yyv2164 := &x.Volumes - yym2165 := z.DecBinary() - _ = yym2165 - if false { - } else { - h.decSliceVolume((*[]Volume)(yyv2164), d) - } - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Containers = nil - } else { - yyv2166 := &x.Containers - yym2167 := z.DecBinary() - _ = yym2167 - if false { - } else { - h.decSliceContainer((*[]Container)(yyv2166), d) - } - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RestartPolicy = "" - } else { - x.RestartPolicy = RestartPolicy(r.DecodeString()) - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - 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) - } - yym2170 := z.DecBinary() - _ = yym2170 - if false { - } else { - *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - 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) - } - yym2172 := z.DecBinary() - _ = yym2172 - if false { - } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DNSPolicy = "" - } else { - x.DNSPolicy = DNSPolicy(r.DecodeString()) - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeSelector = nil - } else { - yyv2174 := &x.NodeSelector - yym2175 := z.DecBinary() - _ = yym2175 - if false { - } else { - z.F.DecMapStringStringX(yyv2174, false, d) - } - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ServiceAccountName = "" - } else { - x.ServiceAccountName = string(r.DecodeString()) - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeName = "" - } else { - x.NodeName = string(r.DecodeString()) - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - 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) - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil - } else { - yyv2179 := &x.ImagePullSecrets - yym2180 := z.DecBinary() - _ = yym2180 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2179), d) - } - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hostname = "" - } else { - x.Hostname = string(r.DecodeString()) - } - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Subdomain = "" - } else { - x.Subdomain = string(r.DecodeString()) - } - for { - yyj2163++ - if yyhl2163 { - yyb2163 = yyj2163 > l - } else { - yyb2163 = r.CheckBreak() - } - if yyb2163 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2163-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *Sysctl) 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 [2]bool - _, _, _ = yysep2184, yyq2184, yy2arr2184 - const yyr2184 bool = false - var yynn2184 int - if yyr2184 || yy2arr2184 { - r.EncodeArrayStart(2) - } else { - yynn2184 = 2 - for _, b := range yyq2184 { - if b { - yynn2184++ - } - } - r.EncodeMapStart(yynn2184) - yynn2184 = 0 - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2186 := z.EncBinary() - _ = yym2186 - 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) - yym2187 := z.EncBinary() - _ = yym2187 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2189 := z.EncBinary() - _ = yym2189 - 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) - yym2190 := z.EncBinary() - _ = yym2190 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) - } - } - if yyr2184 || yy2arr2184 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Sysctl) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym2191 := z.DecBinary() - _ = yym2191 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2192 := r.ContainerType() - if yyct2192 == codecSelferValueTypeMap1234 { - yyl2192 := r.ReadMapStart() - if yyl2192 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2192, d) - } - } else if yyct2192 == codecSelferValueTypeArray1234 { - yyl2192 := r.ReadArrayStart() - if yyl2192 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2192, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *Sysctl) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys2193Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2193Slc - var yyhl2193 bool = l >= 0 - for yyj2193 := 0; ; yyj2193++ { - if yyhl2193 { - if yyj2193 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2193Slc = r.DecodeBytes(yys2193Slc, true, true) - yys2193 := string(yys2193Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2193 { - 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, yys2193) - } // end switch yys2193 - } // end for yyj2193 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Sysctl) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj2196 int - var yyb2196 bool - var yyhl2196 bool = l >= 0 - yyj2196++ - if yyhl2196 { - yyb2196 = yyj2196 > l - } else { - yyb2196 = r.CheckBreak() - } - if yyb2196 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj2196++ - if yyhl2196 { - yyb2196 = yyj2196 > l - } else { - yyb2196 = r.CheckBreak() - } - if yyb2196 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Value = "" - } else { - x.Value = string(r.DecodeString()) - } - for { - yyj2196++ - if yyhl2196 { - yyb2196 = yyj2196 > l - } else { - yyb2196 = r.CheckBreak() - } - if yyb2196 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2196-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 { - yym2199 := z.EncBinary() - _ = yym2199 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2200 := !z.EncBinary() - yy2arr2200 := z.EncBasicHandle().StructToArray - var yyq2200 [8]bool - _, _, _ = yysep2200, yyq2200, yy2arr2200 - const yyr2200 bool = false - yyq2200[0] = x.HostNetwork != false - yyq2200[1] = x.HostPID != false - yyq2200[2] = x.HostIPC != false - yyq2200[3] = x.SELinuxOptions != nil - yyq2200[4] = x.RunAsUser != nil - yyq2200[5] = x.RunAsNonRoot != nil - yyq2200[6] = len(x.SupplementalGroups) != 0 - yyq2200[7] = x.FSGroup != nil - var yynn2200 int - if yyr2200 || yy2arr2200 { - r.EncodeArrayStart(8) - } else { - yynn2200 = 0 - for _, b := range yyq2200 { - if b { - yynn2200++ - } - } - r.EncodeMapStart(yynn2200) - yynn2200 = 0 - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[0] { - yym2202 := z.EncBinary() - _ = yym2202 - if false { - } else { - r.EncodeBool(bool(x.HostNetwork)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq2200[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostNetwork")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2203 := z.EncBinary() - _ = yym2203 - if false { - } else { - r.EncodeBool(bool(x.HostNetwork)) - } - } - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[1] { - yym2205 := z.EncBinary() - _ = yym2205 - if false { - } else { - r.EncodeBool(bool(x.HostPID)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq2200[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2206 := z.EncBinary() - _ = yym2206 - if false { - } else { - r.EncodeBool(bool(x.HostPID)) - } - } - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[2] { - yym2208 := z.EncBinary() - _ = yym2208 - if false { - } else { - r.EncodeBool(bool(x.HostIPC)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq2200[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIPC")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2209 := z.EncBinary() - _ = yym2209 - if false { - } else { - r.EncodeBool(bool(x.HostIPC)) - } - } - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[3] { - if x.SELinuxOptions == nil { - r.EncodeNil() - } else { - x.SELinuxOptions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2200[3] { - 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 yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[4] { - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy2212 := *x.RunAsUser - yym2213 := z.EncBinary() - _ = yym2213 - if false { - } else { - r.EncodeInt(int64(yy2212)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2200[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy2214 := *x.RunAsUser - yym2215 := z.EncBinary() - _ = yym2215 - if false { - } else { - r.EncodeInt(int64(yy2214)) - } - } - } - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[5] { - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy2217 := *x.RunAsNonRoot - yym2218 := z.EncBinary() - _ = yym2218 - if false { - } else { - r.EncodeBool(bool(yy2217)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2200[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy2219 := *x.RunAsNonRoot - yym2220 := z.EncBinary() - _ = yym2220 - if false { - } else { - r.EncodeBool(bool(yy2219)) - } - } - } - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[6] { - if x.SupplementalGroups == nil { - r.EncodeNil() - } else { - yym2222 := z.EncBinary() - _ = yym2222 - if false { - } else { - z.F.EncSliceInt64V(x.SupplementalGroups, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2200[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("supplementalGroups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SupplementalGroups == nil { - r.EncodeNil() - } else { - yym2223 := z.EncBinary() - _ = yym2223 - if false { - } else { - z.F.EncSliceInt64V(x.SupplementalGroups, false, e) - } - } - } - } - if yyr2200 || yy2arr2200 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2200[7] { - if x.FSGroup == nil { - r.EncodeNil() - } else { - yy2225 := *x.FSGroup - yym2226 := z.EncBinary() - _ = yym2226 - if false { - } else { - r.EncodeInt(int64(yy2225)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2200[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsGroup")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FSGroup == nil { - r.EncodeNil() - } else { - yy2227 := *x.FSGroup - yym2228 := z.EncBinary() - _ = yym2228 - if false { - } else { - r.EncodeInt(int64(yy2227)) - } - } - } - } - if yyr2200 || yy2arr2200 { - 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 - yym2229 := z.DecBinary() - _ = yym2229 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2230 := r.ContainerType() - if yyct2230 == codecSelferValueTypeMap1234 { - yyl2230 := r.ReadMapStart() - if yyl2230 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2230, d) - } - } else if yyct2230 == codecSelferValueTypeArray1234 { - yyl2230 := r.ReadArrayStart() - if yyl2230 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2230, 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 yys2231Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2231Slc - var yyhl2231 bool = l >= 0 - for yyj2231 := 0; ; yyj2231++ { - if yyhl2231 { - if yyj2231 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2231Slc = r.DecodeBytes(yys2231Slc, true, true) - yys2231 := string(yys2231Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2231 { - 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 "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) - } - yym2237 := z.DecBinary() - _ = yym2237 - 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) - } - yym2239 := z.DecBinary() - _ = yym2239 - if false { - } else { - *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() - } - } - case "supplementalGroups": - if r.TryDecodeAsNil() { - x.SupplementalGroups = nil - } else { - yyv2240 := &x.SupplementalGroups - yym2241 := z.DecBinary() - _ = yym2241 - if false { - } else { - z.F.DecSliceInt64X(yyv2240, false, d) - } - } - case "fsGroup": - if r.TryDecodeAsNil() { - if x.FSGroup != nil { - x.FSGroup = nil - } - } else { - if x.FSGroup == nil { - x.FSGroup = new(int64) - } - yym2243 := z.DecBinary() - _ = yym2243 - if false { - } else { - *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys2231) - } // end switch yys2231 - } // end for yyj2231 - 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 yyj2244 int - var yyb2244 bool - var yyhl2244 bool = l >= 0 - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostNetwork = false - } else { - x.HostNetwork = bool(r.DecodeBool()) - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostPID = false - } else { - x.HostPID = bool(r.DecodeBool()) - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIPC = false - } else { - x.HostIPC = bool(r.DecodeBool()) - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - 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) - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - 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) - } - yym2250 := z.DecBinary() - _ = yym2250 - if false { - } else { - *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) - } - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - 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) - } - yym2252 := z.DecBinary() - _ = yym2252 - if false { - } else { - *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() - } - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SupplementalGroups = nil - } else { - yyv2253 := &x.SupplementalGroups - yym2254 := z.DecBinary() - _ = yym2254 - if false { - } else { - z.F.DecSliceInt64X(yyv2253, false, d) - } - } - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - 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) - } - yym2256 := z.DecBinary() - _ = yym2256 - if false { - } else { - *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64)) - } - } - for { - yyj2244++ - if yyhl2244 { - yyb2244 = yyj2244 > l - } else { - yyb2244 = r.CheckBreak() - } - if yyb2244 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2244-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 { - yym2257 := z.EncBinary() - _ = yym2257 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2258 := !z.EncBinary() - yy2arr2258 := z.EncBasicHandle().StructToArray - var yyq2258 [8]bool - _, _, _ = yysep2258, yyq2258, yy2arr2258 - const yyr2258 bool = false - yyq2258[0] = x.Phase != "" - yyq2258[1] = len(x.Conditions) != 0 - yyq2258[2] = x.Message != "" - yyq2258[3] = x.Reason != "" - yyq2258[4] = x.HostIP != "" - yyq2258[5] = x.PodIP != "" - yyq2258[6] = x.StartTime != nil - yyq2258[7] = len(x.ContainerStatuses) != 0 - var yynn2258 int - if yyr2258 || yy2arr2258 { - r.EncodeArrayStart(8) - } else { - yynn2258 = 0 - for _, b := range yyq2258 { - if b { - yynn2258++ - } - } - r.EncodeMapStart(yynn2258) - yynn2258 = 0 - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2258[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[1] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2261 := z.EncBinary() - _ = yym2261 - if false { - } else { - h.encSlicePodCondition(([]PodCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2258[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2262 := z.EncBinary() - _ = yym2262 - if false { - } else { - h.encSlicePodCondition(([]PodCondition)(x.Conditions), e) - } - } - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[2] { - yym2264 := z.EncBinary() - _ = yym2264 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2258[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2265 := z.EncBinary() - _ = yym2265 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[3] { - yym2267 := z.EncBinary() - _ = yym2267 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2258[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2268 := z.EncBinary() - _ = yym2268 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[4] { - yym2270 := z.EncBinary() - _ = yym2270 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2258[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2271 := z.EncBinary() - _ = yym2271 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) - } - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[5] { - yym2273 := z.EncBinary() - _ = yym2273 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2258[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2274 := z.EncBinary() - _ = yym2274 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodIP)) - } - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[6] { - if x.StartTime == nil { - r.EncodeNil() - } else { - yym2276 := z.EncBinary() - _ = yym2276 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym2276 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym2276 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2258[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StartTime == nil { - r.EncodeNil() - } else { - yym2277 := z.EncBinary() - _ = yym2277 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym2277 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym2277 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } - } - if yyr2258 || yy2arr2258 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2258[7] { - if x.ContainerStatuses == nil { - r.EncodeNil() - } else { - yym2279 := z.EncBinary() - _ = yym2279 - if false { - } else { - h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2258[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerStatuses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ContainerStatuses == nil { - r.EncodeNil() - } else { - yym2280 := z.EncBinary() - _ = yym2280 - if false { - } else { - h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e) - } - } - } - } - if yyr2258 || yy2arr2258 { - 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 - yym2281 := z.DecBinary() - _ = yym2281 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2282 := r.ContainerType() - if yyct2282 == codecSelferValueTypeMap1234 { - yyl2282 := r.ReadMapStart() - if yyl2282 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2282, d) - } - } else if yyct2282 == codecSelferValueTypeArray1234 { - yyl2282 := r.ReadArrayStart() - if yyl2282 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2282, 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 yys2283Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2283Slc - var yyhl2283 bool = l >= 0 - for yyj2283 := 0; ; yyj2283++ { - if yyhl2283 { - if yyj2283 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2283Slc = r.DecodeBytes(yys2283Slc, true, true) - yys2283 := string(yys2283Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2283 { - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PodPhase(r.DecodeString()) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2285 := &x.Conditions - yym2286 := z.DecBinary() - _ = yym2286 - if false { - } else { - h.decSlicePodCondition((*[]PodCondition)(yyv2285), 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) - } - yym2292 := z.DecBinary() - _ = yym2292 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym2292 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym2292 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - case "containerStatuses": - if r.TryDecodeAsNil() { - x.ContainerStatuses = nil - } else { - yyv2293 := &x.ContainerStatuses - yym2294 := z.DecBinary() - _ = yym2294 - if false { - } else { - h.decSliceContainerStatus((*[]ContainerStatus)(yyv2293), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2283) - } // end switch yys2283 - } // end for yyj2283 - 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 yyj2295 int - var yyb2295 bool - var yyhl2295 bool = l >= 0 - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = PodPhase(r.DecodeString()) - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2297 := &x.Conditions - yym2298 := z.DecBinary() - _ = yym2298 - if false { - } else { - h.decSlicePodCondition((*[]PodCondition)(yyv2297), d) - } - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIP = "" - } else { - x.HostIP = string(r.DecodeString()) - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodIP = "" - } else { - x.PodIP = string(r.DecodeString()) - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - 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) - } - yym2304 := z.DecBinary() - _ = yym2304 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym2304 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym2304 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerStatuses = nil - } else { - yyv2305 := &x.ContainerStatuses - yym2306 := z.DecBinary() - _ = yym2306 - if false { - } else { - h.decSliceContainerStatus((*[]ContainerStatus)(yyv2305), d) - } - } - for { - yyj2295++ - if yyhl2295 { - yyb2295 = yyj2295 > l - } else { - yyb2295 = r.CheckBreak() - } - if yyb2295 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2295-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 { - yym2307 := z.EncBinary() - _ = yym2307 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2308 := !z.EncBinary() - yy2arr2308 := z.EncBasicHandle().StructToArray - var yyq2308 [4]bool - _, _, _ = yysep2308, yyq2308, yy2arr2308 - const yyr2308 bool = false - yyq2308[0] = x.Kind != "" - yyq2308[1] = x.APIVersion != "" - yyq2308[2] = true - yyq2308[3] = true - var yynn2308 int - if yyr2308 || yy2arr2308 { - r.EncodeArrayStart(4) - } else { - yynn2308 = 0 - for _, b := range yyq2308 { - if b { - yynn2308++ - } - } - r.EncodeMapStart(yynn2308) - yynn2308 = 0 - } - if yyr2308 || yy2arr2308 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2308[0] { - yym2310 := z.EncBinary() - _ = yym2310 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2308[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2311 := z.EncBinary() - _ = yym2311 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2308 || yy2arr2308 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2308[1] { - yym2313 := z.EncBinary() - _ = yym2313 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2308[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2314 := z.EncBinary() - _ = yym2314 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2308 || yy2arr2308 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2308[2] { - yy2316 := &x.ObjectMeta - yy2316.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2308[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2317 := &x.ObjectMeta - yy2317.CodecEncodeSelf(e) - } - } - if yyr2308 || yy2arr2308 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2308[3] { - yy2319 := &x.Status - yy2319.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2308[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2320 := &x.Status - yy2320.CodecEncodeSelf(e) - } - } - if yyr2308 || yy2arr2308 { - 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 - yym2321 := z.DecBinary() - _ = yym2321 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2322 := r.ContainerType() - if yyct2322 == codecSelferValueTypeMap1234 { - yyl2322 := r.ReadMapStart() - if yyl2322 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2322, d) - } - } else if yyct2322 == codecSelferValueTypeArray1234 { - yyl2322 := r.ReadArrayStart() - if yyl2322 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2322, 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 yys2323Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2323Slc - var yyhl2323 bool = l >= 0 - for yyj2323 := 0; ; yyj2323++ { - if yyhl2323 { - if yyj2323 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2323Slc = r.DecodeBytes(yys2323Slc, true, true) - yys2323 := string(yys2323Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2323 { - 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 { - yyv2326 := &x.ObjectMeta - yyv2326.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2327 := &x.Status - yyv2327.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2323) - } // end switch yys2323 - } // end for yyj2323 - 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 yyj2328 int - var yyb2328 bool - var yyhl2328 bool = l >= 0 - yyj2328++ - if yyhl2328 { - yyb2328 = yyj2328 > l - } else { - yyb2328 = r.CheckBreak() - } - if yyb2328 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2328++ - if yyhl2328 { - yyb2328 = yyj2328 > l - } else { - yyb2328 = r.CheckBreak() - } - if yyb2328 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2328++ - if yyhl2328 { - yyb2328 = yyj2328 > l - } else { - yyb2328 = r.CheckBreak() - } - if yyb2328 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2331 := &x.ObjectMeta - yyv2331.CodecDecodeSelf(d) - } - yyj2328++ - if yyhl2328 { - yyb2328 = yyj2328 > l - } else { - yyb2328 = r.CheckBreak() - } - if yyb2328 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2332 := &x.Status - yyv2332.CodecDecodeSelf(d) - } - for { - yyj2328++ - if yyhl2328 { - yyb2328 = yyj2328 > l - } else { - yyb2328 = r.CheckBreak() - } - if yyb2328 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2328-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 { - yym2333 := z.EncBinary() - _ = yym2333 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2334 := !z.EncBinary() - yy2arr2334 := z.EncBasicHandle().StructToArray - var yyq2334 [5]bool - _, _, _ = yysep2334, yyq2334, yy2arr2334 - const yyr2334 bool = false - yyq2334[0] = x.Kind != "" - yyq2334[1] = x.APIVersion != "" - yyq2334[2] = true - yyq2334[3] = true - yyq2334[4] = true - var yynn2334 int - if yyr2334 || yy2arr2334 { - r.EncodeArrayStart(5) - } else { - yynn2334 = 0 - for _, b := range yyq2334 { - if b { - yynn2334++ - } - } - r.EncodeMapStart(yynn2334) - yynn2334 = 0 - } - if yyr2334 || yy2arr2334 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2334[0] { - yym2336 := z.EncBinary() - _ = yym2336 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2334[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2337 := z.EncBinary() - _ = yym2337 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2334 || yy2arr2334 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2334[1] { - yym2339 := z.EncBinary() - _ = yym2339 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2334[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2340 := z.EncBinary() - _ = yym2340 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2334 || yy2arr2334 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2334[2] { - yy2342 := &x.ObjectMeta - yy2342.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2334[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2343 := &x.ObjectMeta - yy2343.CodecEncodeSelf(e) - } - } - if yyr2334 || yy2arr2334 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2334[3] { - yy2345 := &x.Spec - yy2345.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2334[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2346 := &x.Spec - yy2346.CodecEncodeSelf(e) - } - } - if yyr2334 || yy2arr2334 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2334[4] { - yy2348 := &x.Status - yy2348.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2334[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2349 := &x.Status - yy2349.CodecEncodeSelf(e) - } - } - if yyr2334 || yy2arr2334 { - 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 - yym2350 := z.DecBinary() - _ = yym2350 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2351 := r.ContainerType() - if yyct2351 == codecSelferValueTypeMap1234 { - yyl2351 := r.ReadMapStart() - if yyl2351 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2351, d) - } - } else if yyct2351 == codecSelferValueTypeArray1234 { - yyl2351 := r.ReadArrayStart() - if yyl2351 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2351, 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 yys2352Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2352Slc - var yyhl2352 bool = l >= 0 - for yyj2352 := 0; ; yyj2352++ { - if yyhl2352 { - if yyj2352 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2352Slc = r.DecodeBytes(yys2352Slc, true, true) - yys2352 := string(yys2352Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2352 { - 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 { - yyv2355 := &x.ObjectMeta - yyv2355.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2356 := &x.Spec - yyv2356.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2357 := &x.Status - yyv2357.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2352) - } // end switch yys2352 - } // end for yyj2352 - 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 yyj2358 int - var yyb2358 bool - var yyhl2358 bool = l >= 0 - yyj2358++ - if yyhl2358 { - yyb2358 = yyj2358 > l - } else { - yyb2358 = r.CheckBreak() - } - if yyb2358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2358++ - if yyhl2358 { - yyb2358 = yyj2358 > l - } else { - yyb2358 = r.CheckBreak() - } - if yyb2358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2358++ - if yyhl2358 { - yyb2358 = yyj2358 > l - } else { - yyb2358 = r.CheckBreak() - } - if yyb2358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2361 := &x.ObjectMeta - yyv2361.CodecDecodeSelf(d) - } - yyj2358++ - if yyhl2358 { - yyb2358 = yyj2358 > l - } else { - yyb2358 = r.CheckBreak() - } - if yyb2358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2362 := &x.Spec - yyv2362.CodecDecodeSelf(d) - } - yyj2358++ - if yyhl2358 { - yyb2358 = yyj2358 > l - } else { - yyb2358 = r.CheckBreak() - } - if yyb2358 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PodStatus{} - } else { - yyv2363 := &x.Status - yyv2363.CodecDecodeSelf(d) - } - for { - yyj2358++ - if yyhl2358 { - yyb2358 = yyj2358 > l - } else { - yyb2358 = r.CheckBreak() - } - if yyb2358 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2358-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 { - yym2364 := z.EncBinary() - _ = yym2364 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2365 := !z.EncBinary() - yy2arr2365 := z.EncBasicHandle().StructToArray - var yyq2365 [2]bool - _, _, _ = yysep2365, yyq2365, yy2arr2365 - const yyr2365 bool = false - yyq2365[0] = true - yyq2365[1] = true - var yynn2365 int - if yyr2365 || yy2arr2365 { - r.EncodeArrayStart(2) - } else { - yynn2365 = 0 - for _, b := range yyq2365 { - if b { - yynn2365++ - } - } - r.EncodeMapStart(yynn2365) - yynn2365 = 0 - } - if yyr2365 || yy2arr2365 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2365[0] { - yy2367 := &x.ObjectMeta - yy2367.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2365[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2368 := &x.ObjectMeta - yy2368.CodecEncodeSelf(e) - } - } - if yyr2365 || yy2arr2365 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2365[1] { - yy2370 := &x.Spec - yy2370.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2365[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2371 := &x.Spec - yy2371.CodecEncodeSelf(e) - } - } - if yyr2365 || yy2arr2365 { - 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 - yym2372 := z.DecBinary() - _ = yym2372 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2373 := r.ContainerType() - if yyct2373 == codecSelferValueTypeMap1234 { - yyl2373 := r.ReadMapStart() - if yyl2373 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2373, d) - } - } else if yyct2373 == codecSelferValueTypeArray1234 { - yyl2373 := r.ReadArrayStart() - if yyl2373 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2373, 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 yys2374Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2374Slc - var yyhl2374 bool = l >= 0 - for yyj2374 := 0; ; yyj2374++ { - if yyhl2374 { - if yyj2374 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2374Slc = r.DecodeBytes(yys2374Slc, true, true) - yys2374 := string(yys2374Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2374 { - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2375 := &x.ObjectMeta - yyv2375.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2376 := &x.Spec - yyv2376.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2374) - } // end switch yys2374 - } // end for yyj2374 - 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 yyj2377 int - var yyb2377 bool - var yyhl2377 bool = l >= 0 - yyj2377++ - if yyhl2377 { - yyb2377 = yyj2377 > l - } else { - yyb2377 = r.CheckBreak() - } - if yyb2377 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2378 := &x.ObjectMeta - yyv2378.CodecDecodeSelf(d) - } - yyj2377++ - if yyhl2377 { - yyb2377 = yyj2377 > l - } else { - yyb2377 = r.CheckBreak() - } - if yyb2377 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PodSpec{} - } else { - yyv2379 := &x.Spec - yyv2379.CodecDecodeSelf(d) - } - for { - yyj2377++ - if yyhl2377 { - yyb2377 = yyj2377 > l - } else { - yyb2377 = r.CheckBreak() - } - if yyb2377 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2377-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 { - yym2380 := z.EncBinary() - _ = yym2380 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2381 := !z.EncBinary() - yy2arr2381 := z.EncBasicHandle().StructToArray - var yyq2381 [4]bool - _, _, _ = yysep2381, yyq2381, yy2arr2381 - const yyr2381 bool = false - yyq2381[0] = x.Kind != "" - yyq2381[1] = x.APIVersion != "" - yyq2381[2] = true - yyq2381[3] = true - var yynn2381 int - if yyr2381 || yy2arr2381 { - r.EncodeArrayStart(4) - } else { - yynn2381 = 0 - for _, b := range yyq2381 { - if b { - yynn2381++ - } - } - r.EncodeMapStart(yynn2381) - yynn2381 = 0 - } - if yyr2381 || yy2arr2381 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2381[0] { - yym2383 := z.EncBinary() - _ = yym2383 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2381[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2384 := z.EncBinary() - _ = yym2384 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2381 || yy2arr2381 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2381[1] { - yym2386 := z.EncBinary() - _ = yym2386 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2381[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2387 := z.EncBinary() - _ = yym2387 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2381 || yy2arr2381 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2381[2] { - yy2389 := &x.ObjectMeta - yy2389.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2381[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2390 := &x.ObjectMeta - yy2390.CodecEncodeSelf(e) - } - } - if yyr2381 || yy2arr2381 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2381[3] { - yy2392 := &x.Template - yy2392.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2381[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2393 := &x.Template - yy2393.CodecEncodeSelf(e) - } - } - if yyr2381 || yy2arr2381 { - 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 - yym2394 := z.DecBinary() - _ = yym2394 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2395 := r.ContainerType() - if yyct2395 == codecSelferValueTypeMap1234 { - yyl2395 := r.ReadMapStart() - if yyl2395 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2395, d) - } - } else if yyct2395 == codecSelferValueTypeArray1234 { - yyl2395 := r.ReadArrayStart() - if yyl2395 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2395, 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 yys2396Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2396Slc - var yyhl2396 bool = l >= 0 - for yyj2396 := 0; ; yyj2396++ { - if yyhl2396 { - if yyj2396 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2396Slc = r.DecodeBytes(yys2396Slc, true, true) - yys2396 := string(yys2396Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2396 { - 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 { - yyv2399 := &x.ObjectMeta - yyv2399.CodecDecodeSelf(d) - } - case "template": - if r.TryDecodeAsNil() { - x.Template = PodTemplateSpec{} - } else { - yyv2400 := &x.Template - yyv2400.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2396) - } // end switch yys2396 - } // end for yyj2396 - 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 yyj2401 int - var yyb2401 bool - var yyhl2401 bool = l >= 0 - yyj2401++ - if yyhl2401 { - yyb2401 = yyj2401 > l - } else { - yyb2401 = r.CheckBreak() - } - if yyb2401 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2401++ - if yyhl2401 { - yyb2401 = yyj2401 > l - } else { - yyb2401 = r.CheckBreak() - } - if yyb2401 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2401++ - if yyhl2401 { - yyb2401 = yyj2401 > l - } else { - yyb2401 = r.CheckBreak() - } - if yyb2401 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2404 := &x.ObjectMeta - yyv2404.CodecDecodeSelf(d) - } - yyj2401++ - if yyhl2401 { - yyb2401 = yyj2401 > l - } else { - yyb2401 = r.CheckBreak() - } - if yyb2401 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = PodTemplateSpec{} - } else { - yyv2405 := &x.Template - yyv2405.CodecDecodeSelf(d) - } - for { - yyj2401++ - if yyhl2401 { - yyb2401 = yyj2401 > l - } else { - yyb2401 = r.CheckBreak() - } - if yyb2401 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2401-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 { - yym2406 := z.EncBinary() - _ = yym2406 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2407 := !z.EncBinary() - yy2arr2407 := z.EncBasicHandle().StructToArray - var yyq2407 [4]bool - _, _, _ = yysep2407, yyq2407, yy2arr2407 - const yyr2407 bool = false - yyq2407[0] = x.Kind != "" - yyq2407[1] = x.APIVersion != "" - yyq2407[2] = true - var yynn2407 int - if yyr2407 || yy2arr2407 { - r.EncodeArrayStart(4) - } else { - yynn2407 = 1 - for _, b := range yyq2407 { - if b { - yynn2407++ - } - } - r.EncodeMapStart(yynn2407) - yynn2407 = 0 - } - if yyr2407 || yy2arr2407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2407[0] { - yym2409 := z.EncBinary() - _ = yym2409 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2407[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2410 := z.EncBinary() - _ = yym2410 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2407 || yy2arr2407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2407[1] { - yym2412 := z.EncBinary() - _ = yym2412 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2407[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2413 := z.EncBinary() - _ = yym2413 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2407 || yy2arr2407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2407[2] { - yy2415 := &x.ListMeta - yym2416 := z.EncBinary() - _ = yym2416 - if false { - } else if z.HasExtensions() && z.EncExt(yy2415) { - } else { - z.EncFallback(yy2415) - } - } else { - r.EncodeNil() - } - } else { - if yyq2407[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2417 := &x.ListMeta - yym2418 := z.EncBinary() - _ = yym2418 - if false { - } else if z.HasExtensions() && z.EncExt(yy2417) { - } else { - z.EncFallback(yy2417) - } - } - } - if yyr2407 || yy2arr2407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2420 := z.EncBinary() - _ = yym2420 - 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 { - yym2421 := z.EncBinary() - _ = yym2421 - if false { - } else { - h.encSlicePodTemplate(([]PodTemplate)(x.Items), e) - } - } - } - if yyr2407 || yy2arr2407 { - 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 - yym2422 := z.DecBinary() - _ = yym2422 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2423 := r.ContainerType() - if yyct2423 == codecSelferValueTypeMap1234 { - yyl2423 := r.ReadMapStart() - if yyl2423 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2423, d) - } - } else if yyct2423 == codecSelferValueTypeArray1234 { - yyl2423 := r.ReadArrayStart() - if yyl2423 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2423, 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 yys2424Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2424Slc - var yyhl2424 bool = l >= 0 - for yyj2424 := 0; ; yyj2424++ { - if yyhl2424 { - if yyj2424 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2424Slc = r.DecodeBytes(yys2424Slc, true, true) - yys2424 := string(yys2424Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2424 { - 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 { - yyv2427 := &x.ListMeta - yym2428 := z.DecBinary() - _ = yym2428 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2427) { - } else { - z.DecFallback(yyv2427, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2429 := &x.Items - yym2430 := z.DecBinary() - _ = yym2430 - if false { - } else { - h.decSlicePodTemplate((*[]PodTemplate)(yyv2429), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2424) - } // end switch yys2424 - } // end for yyj2424 - 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 yyj2431 int - var yyb2431 bool - var yyhl2431 bool = l >= 0 - yyj2431++ - if yyhl2431 { - yyb2431 = yyj2431 > l - } else { - yyb2431 = r.CheckBreak() - } - if yyb2431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2431++ - if yyhl2431 { - yyb2431 = yyj2431 > l - } else { - yyb2431 = r.CheckBreak() - } - if yyb2431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2431++ - if yyhl2431 { - yyb2431 = yyj2431 > l - } else { - yyb2431 = r.CheckBreak() - } - if yyb2431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2434 := &x.ListMeta - yym2435 := z.DecBinary() - _ = yym2435 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2434) { - } else { - z.DecFallback(yyv2434, false) - } - } - yyj2431++ - if yyhl2431 { - yyb2431 = yyj2431 > l - } else { - yyb2431 = r.CheckBreak() - } - if yyb2431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2436 := &x.Items - yym2437 := z.DecBinary() - _ = yym2437 - if false { - } else { - h.decSlicePodTemplate((*[]PodTemplate)(yyv2436), d) - } - } - for { - yyj2431++ - if yyhl2431 { - yyb2431 = yyj2431 > l - } else { - yyb2431 = r.CheckBreak() - } - if yyb2431 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2431-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 { - yym2438 := z.EncBinary() - _ = yym2438 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2439 := !z.EncBinary() - yy2arr2439 := z.EncBasicHandle().StructToArray - var yyq2439 [4]bool - _, _, _ = yysep2439, yyq2439, yy2arr2439 - const yyr2439 bool = false - yyq2439[1] = x.MinReadySeconds != 0 - yyq2439[3] = x.Template != nil - var yynn2439 int - if yyr2439 || yy2arr2439 { - r.EncodeArrayStart(4) - } else { - yynn2439 = 2 - for _, b := range yyq2439 { - if b { - yynn2439++ - } - } - r.EncodeMapStart(yynn2439) - yynn2439 = 0 - } - if yyr2439 || yy2arr2439 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2441 := z.EncBinary() - _ = yym2441 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2442 := z.EncBinary() - _ = yym2442 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr2439 || yy2arr2439 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2439[1] { - yym2444 := z.EncBinary() - _ = yym2444 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2439[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2445 := z.EncBinary() - _ = yym2445 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } - } - if yyr2439 || yy2arr2439 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym2447 := z.EncBinary() - _ = yym2447 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym2448 := z.EncBinary() - _ = yym2448 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } - if yyr2439 || yy2arr2439 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2439[3] { - if x.Template == nil { - r.EncodeNil() - } else { - x.Template.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq2439[3] { - 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 yyr2439 || yy2arr2439 { - 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 - yym2450 := z.DecBinary() - _ = yym2450 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2451 := r.ContainerType() - if yyct2451 == codecSelferValueTypeMap1234 { - yyl2451 := r.ReadMapStart() - if yyl2451 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2451, d) - } - } else if yyct2451 == codecSelferValueTypeArray1234 { - yyl2451 := r.ReadArrayStart() - if yyl2451 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2451, 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 yys2452Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2452Slc - var yyhl2452 bool = l >= 0 - for yyj2452 := 0; ; yyj2452++ { - if yyhl2452 { - if yyj2452 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2452Slc = r.DecodeBytes(yys2452Slc, true, true) - yys2452 := string(yys2452Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2452 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "minReadySeconds": - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - case "selector": - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2455 := &x.Selector - yym2456 := z.DecBinary() - _ = yym2456 - if false { - } else { - z.F.DecMapStringStringX(yyv2455, 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, yys2452) - } // end switch yys2452 - } // end for yyj2452 - 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 yyj2458 int - var yyb2458 bool - var yyhl2458 bool = l >= 0 - yyj2458++ - if yyhl2458 { - yyb2458 = yyj2458 > l - } else { - yyb2458 = r.CheckBreak() - } - if yyb2458 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj2458++ - if yyhl2458 { - yyb2458 = yyj2458 > l - } else { - yyb2458 = r.CheckBreak() - } - if yyb2458 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - yyj2458++ - if yyhl2458 { - yyb2458 = yyj2458 > l - } else { - yyb2458 = r.CheckBreak() - } - if yyb2458 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2461 := &x.Selector - yym2462 := z.DecBinary() - _ = yym2462 - if false { - } else { - z.F.DecMapStringStringX(yyv2461, false, d) - } - } - yyj2458++ - if yyhl2458 { - yyb2458 = yyj2458 > l - } else { - yyb2458 = r.CheckBreak() - } - if yyb2458 { - 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 { - yyj2458++ - if yyhl2458 { - yyb2458 = yyj2458 > l - } else { - yyb2458 = r.CheckBreak() - } - if yyb2458 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2458-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 { - yym2464 := z.EncBinary() - _ = yym2464 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2465 := !z.EncBinary() - yy2arr2465 := z.EncBasicHandle().StructToArray - var yyq2465 [6]bool - _, _, _ = yysep2465, yyq2465, yy2arr2465 - const yyr2465 bool = false - yyq2465[1] = x.FullyLabeledReplicas != 0 - yyq2465[2] = x.ReadyReplicas != 0 - yyq2465[3] = x.AvailableReplicas != 0 - yyq2465[4] = x.ObservedGeneration != 0 - yyq2465[5] = len(x.Conditions) != 0 - var yynn2465 int - if yyr2465 || yy2arr2465 { - r.EncodeArrayStart(6) - } else { - yynn2465 = 1 - for _, b := range yyq2465 { - if b { - yynn2465++ - } - } - r.EncodeMapStart(yynn2465) - yynn2465 = 0 - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2467 := z.EncBinary() - _ = yym2467 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2468 := z.EncBinary() - _ = yym2468 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2465[1] { - yym2470 := z.EncBinary() - _ = yym2470 - if false { - } else { - r.EncodeInt(int64(x.FullyLabeledReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2465[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fullyLabeledReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2471 := z.EncBinary() - _ = yym2471 - if false { - } else { - r.EncodeInt(int64(x.FullyLabeledReplicas)) - } - } - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2465[2] { - yym2473 := z.EncBinary() - _ = yym2473 - if false { - } else { - r.EncodeInt(int64(x.ReadyReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2465[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2474 := z.EncBinary() - _ = yym2474 - if false { - } else { - r.EncodeInt(int64(x.ReadyReplicas)) - } - } - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2465[3] { - yym2476 := z.EncBinary() - _ = yym2476 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2465[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2477 := z.EncBinary() - _ = yym2477 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2465[4] { - yym2479 := z.EncBinary() - _ = yym2479 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2465[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2480 := z.EncBinary() - _ = yym2480 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } - } - if yyr2465 || yy2arr2465 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2465[5] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2482 := z.EncBinary() - _ = yym2482 - if false { - } else { - h.encSliceReplicationControllerCondition(([]ReplicationControllerCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2465[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym2483 := z.EncBinary() - _ = yym2483 - if false { - } else { - h.encSliceReplicationControllerCondition(([]ReplicationControllerCondition)(x.Conditions), e) - } - } - } - } - if yyr2465 || yy2arr2465 { - 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 - yym2484 := z.DecBinary() - _ = yym2484 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2485 := r.ContainerType() - if yyct2485 == codecSelferValueTypeMap1234 { - yyl2485 := r.ReadMapStart() - if yyl2485 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2485, d) - } - } else if yyct2485 == codecSelferValueTypeArray1234 { - yyl2485 := r.ReadArrayStart() - if yyl2485 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2485, 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 yys2486Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2486Slc - var yyhl2486 bool = l >= 0 - for yyj2486 := 0; ; yyj2486++ { - if yyhl2486 { - if yyj2486 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2486Slc = r.DecodeBytes(yys2486Slc, true, true) - yys2486 := string(yys2486Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2486 { - 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 "availableReplicas": - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - case "observedGeneration": - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2492 := &x.Conditions - yym2493 := z.DecBinary() - _ = yym2493 - if false { - } else { - h.decSliceReplicationControllerCondition((*[]ReplicationControllerCondition)(yyv2492), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2486) - } // end switch yys2486 - } // end for yyj2486 - 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 yyj2494 int - var yyb2494 bool - var yyhl2494 bool = l >= 0 - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FullyLabeledReplicas = 0 - } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) - } - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadyReplicas = 0 - } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) - } - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv2500 := &x.Conditions - yym2501 := z.DecBinary() - _ = yym2501 - if false { - } else { - h.decSliceReplicationControllerCondition((*[]ReplicationControllerCondition)(yyv2500), d) - } - } - for { - yyj2494++ - if yyhl2494 { - yyb2494 = yyj2494 > l - } else { - yyb2494 = r.CheckBreak() - } - if yyb2494 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2494-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ReplicationControllerConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym2502 := z.EncBinary() - _ = yym2502 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *ReplicationControllerConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym2503 := z.DecBinary() - _ = yym2503 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *ReplicationControllerCondition) 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 [5]bool - _, _, _ = yysep2505, yyq2505, yy2arr2505 - const yyr2505 bool = false - yyq2505[2] = true - yyq2505[3] = x.Reason != "" - yyq2505[4] = x.Message != "" - var yynn2505 int - if yyr2505 || yy2arr2505 { - r.EncodeArrayStart(5) - } else { - yynn2505 = 2 - for _, b := range yyq2505 { - if b { - yynn2505++ - } - } - r.EncodeMapStart(yynn2505) - yynn2505 = 0 - } - if yyr2505 || yy2arr2505 { - 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 yyr2505 || yy2arr2505 { - 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 yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[2] { - yy2509 := &x.LastTransitionTime - yym2510 := z.EncBinary() - _ = yym2510 - if false { - } else if z.HasExtensions() && z.EncExt(yy2509) { - } else if yym2510 { - z.EncBinaryMarshal(yy2509) - } else if !yym2510 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2509) - } else { - z.EncFallback(yy2509) - } - } else { - r.EncodeNil() - } - } else { - if yyq2505[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2511 := &x.LastTransitionTime - yym2512 := z.EncBinary() - _ = yym2512 - if false { - } else if z.HasExtensions() && z.EncExt(yy2511) { - } else if yym2512 { - z.EncBinaryMarshal(yy2511) - } else if !yym2512 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2511) - } else { - z.EncFallback(yy2511) - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[3] { - yym2514 := z.EncBinary() - _ = yym2514 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2515 := z.EncBinary() - _ = yym2515 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2505[4] { - yym2517 := z.EncBinary() - _ = yym2517 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2505[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2518 := z.EncBinary() - _ = yym2518 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr2505 || yy2arr2505 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicationControllerCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym2519 := z.DecBinary() - _ = yym2519 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2520 := r.ContainerType() - if yyct2520 == codecSelferValueTypeMap1234 { - yyl2520 := r.ReadMapStart() - if yyl2520 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2520, d) - } - } else if yyct2520 == codecSelferValueTypeArray1234 { - yyl2520 := r.ReadArrayStart() - if yyl2520 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2520, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicationControllerCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys2521Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2521Slc - var yyhl2521 bool = l >= 0 - for yyj2521 := 0; ; yyj2521++ { - if yyhl2521 { - if yyj2521 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2521Slc = r.DecodeBytes(yys2521Slc, true, true) - yys2521 := string(yys2521Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2521 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ReplicationControllerConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv2524 := &x.LastTransitionTime - yym2525 := z.DecBinary() - _ = yym2525 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2524) { - } else if yym2525 { - z.DecBinaryUnmarshal(yyv2524) - } else if !yym2525 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2524) - } else { - z.DecFallback(yyv2524, 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, yys2521) - } // end switch yys2521 - } // end for yyj2521 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicationControllerCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj2528 int - var yyb2528 bool - var yyhl2528 bool = l >= 0 - yyj2528++ - if yyhl2528 { - yyb2528 = yyj2528 > l - } else { - yyb2528 = r.CheckBreak() - } - if yyb2528 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ReplicationControllerConditionType(r.DecodeString()) - } - yyj2528++ - if yyhl2528 { - yyb2528 = yyj2528 > l - } else { - yyb2528 = r.CheckBreak() - } - if yyb2528 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj2528++ - if yyhl2528 { - yyb2528 = yyj2528 > l - } else { - yyb2528 = r.CheckBreak() - } - if yyb2528 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv2531 := &x.LastTransitionTime - yym2532 := z.DecBinary() - _ = yym2532 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2531) { - } else if yym2532 { - z.DecBinaryUnmarshal(yyv2531) - } else if !yym2532 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2531) - } else { - z.DecFallback(yyv2531, false) - } - } - yyj2528++ - if yyhl2528 { - yyb2528 = yyj2528 > l - } else { - yyb2528 = r.CheckBreak() - } - if yyb2528 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj2528++ - if yyhl2528 { - yyb2528 = yyj2528 > l - } else { - yyb2528 = r.CheckBreak() - } - if yyb2528 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj2528++ - if yyhl2528 { - yyb2528 = yyj2528 > l - } else { - yyb2528 = r.CheckBreak() - } - if yyb2528 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2528-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 { - yym2535 := z.EncBinary() - _ = yym2535 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2536 := !z.EncBinary() - yy2arr2536 := z.EncBasicHandle().StructToArray - var yyq2536 [5]bool - _, _, _ = yysep2536, yyq2536, yy2arr2536 - const yyr2536 bool = false - yyq2536[0] = x.Kind != "" - yyq2536[1] = x.APIVersion != "" - yyq2536[2] = true - yyq2536[3] = true - yyq2536[4] = true - var yynn2536 int - if yyr2536 || yy2arr2536 { - r.EncodeArrayStart(5) - } else { - yynn2536 = 0 - for _, b := range yyq2536 { - if b { - yynn2536++ - } - } - r.EncodeMapStart(yynn2536) - yynn2536 = 0 - } - if yyr2536 || yy2arr2536 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2536[0] { - yym2538 := z.EncBinary() - _ = yym2538 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2536[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2539 := z.EncBinary() - _ = yym2539 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2536 || yy2arr2536 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2536[1] { - yym2541 := z.EncBinary() - _ = yym2541 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2536[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2542 := z.EncBinary() - _ = yym2542 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2536 || yy2arr2536 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2536[2] { - yy2544 := &x.ObjectMeta - yy2544.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2536[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2545 := &x.ObjectMeta - yy2545.CodecEncodeSelf(e) - } - } - if yyr2536 || yy2arr2536 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2536[3] { - yy2547 := &x.Spec - yy2547.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2536[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2548 := &x.Spec - yy2548.CodecEncodeSelf(e) - } - } - if yyr2536 || yy2arr2536 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2536[4] { - yy2550 := &x.Status - yy2550.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2536[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2551 := &x.Status - yy2551.CodecEncodeSelf(e) - } - } - if yyr2536 || yy2arr2536 { - 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 - yym2552 := z.DecBinary() - _ = yym2552 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2553 := r.ContainerType() - if yyct2553 == codecSelferValueTypeMap1234 { - yyl2553 := r.ReadMapStart() - if yyl2553 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2553, d) - } - } else if yyct2553 == codecSelferValueTypeArray1234 { - yyl2553 := r.ReadArrayStart() - if yyl2553 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2553, 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 yys2554Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2554Slc - var yyhl2554 bool = l >= 0 - for yyj2554 := 0; ; yyj2554++ { - if yyhl2554 { - if yyj2554 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2554Slc = r.DecodeBytes(yys2554Slc, true, true) - yys2554 := string(yys2554Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2554 { - 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 { - yyv2557 := &x.ObjectMeta - yyv2557.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ReplicationControllerSpec{} - } else { - yyv2558 := &x.Spec - yyv2558.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ReplicationControllerStatus{} - } else { - yyv2559 := &x.Status - yyv2559.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2554) - } // end switch yys2554 - } // end for yyj2554 - 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 yyj2560 int - var yyb2560 bool - var yyhl2560 bool = l >= 0 - yyj2560++ - if yyhl2560 { - yyb2560 = yyj2560 > l - } else { - yyb2560 = r.CheckBreak() - } - if yyb2560 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2560++ - if yyhl2560 { - yyb2560 = yyj2560 > l - } else { - yyb2560 = r.CheckBreak() - } - if yyb2560 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2560++ - if yyhl2560 { - yyb2560 = yyj2560 > l - } else { - yyb2560 = r.CheckBreak() - } - if yyb2560 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2563 := &x.ObjectMeta - yyv2563.CodecDecodeSelf(d) - } - yyj2560++ - if yyhl2560 { - yyb2560 = yyj2560 > l - } else { - yyb2560 = r.CheckBreak() - } - if yyb2560 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ReplicationControllerSpec{} - } else { - yyv2564 := &x.Spec - yyv2564.CodecDecodeSelf(d) - } - yyj2560++ - if yyhl2560 { - yyb2560 = yyj2560 > l - } else { - yyb2560 = r.CheckBreak() - } - if yyb2560 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ReplicationControllerStatus{} - } else { - yyv2565 := &x.Status - yyv2565.CodecDecodeSelf(d) - } - for { - yyj2560++ - if yyhl2560 { - yyb2560 = yyj2560 > l - } else { - yyb2560 = r.CheckBreak() - } - if yyb2560 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2560-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 { - yym2566 := z.EncBinary() - _ = yym2566 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2567 := !z.EncBinary() - yy2arr2567 := z.EncBasicHandle().StructToArray - var yyq2567 [4]bool - _, _, _ = yysep2567, yyq2567, yy2arr2567 - const yyr2567 bool = false - yyq2567[0] = x.Kind != "" - yyq2567[1] = x.APIVersion != "" - yyq2567[2] = true - var yynn2567 int - if yyr2567 || yy2arr2567 { - r.EncodeArrayStart(4) - } 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.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2567[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2570 := z.EncBinary() - _ = yym2570 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2567[1] { - yym2572 := z.EncBinary() - _ = yym2572 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2567[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2573 := z.EncBinary() - _ = yym2573 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2567[2] { - yy2575 := &x.ListMeta - yym2576 := z.EncBinary() - _ = yym2576 - if false { - } else if z.HasExtensions() && z.EncExt(yy2575) { - } else { - z.EncFallback(yy2575) - } - } else { - r.EncodeNil() - } - } else { - if yyq2567[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2577 := &x.ListMeta - yym2578 := z.EncBinary() - _ = yym2578 - if false { - } else if z.HasExtensions() && z.EncExt(yy2577) { - } else { - z.EncFallback(yy2577) - } - } - } - if yyr2567 || yy2arr2567 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2580 := z.EncBinary() - _ = yym2580 - 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 { - yym2581 := z.EncBinary() - _ = yym2581 - if false { - } else { - h.encSliceReplicationController(([]ReplicationController)(x.Items), e) - } - } - } - if yyr2567 || yy2arr2567 { - 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 - yym2582 := z.DecBinary() - _ = yym2582 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2583 := r.ContainerType() - if yyct2583 == codecSelferValueTypeMap1234 { - yyl2583 := r.ReadMapStart() - if yyl2583 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2583, d) - } - } else if yyct2583 == codecSelferValueTypeArray1234 { - yyl2583 := r.ReadArrayStart() - if yyl2583 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2583, 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 yys2584Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2584Slc - var yyhl2584 bool = l >= 0 - for yyj2584 := 0; ; yyj2584++ { - if yyhl2584 { - if yyj2584 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2584Slc = r.DecodeBytes(yys2584Slc, true, true) - yys2584 := string(yys2584Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2584 { - 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 { - yyv2587 := &x.ListMeta - yym2588 := z.DecBinary() - _ = yym2588 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2587) { - } else { - z.DecFallback(yyv2587, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2589 := &x.Items - yym2590 := z.DecBinary() - _ = yym2590 - if false { - } else { - h.decSliceReplicationController((*[]ReplicationController)(yyv2589), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2584) - } // end switch yys2584 - } // end for yyj2584 - 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 yyj2591 int - var yyb2591 bool - var yyhl2591 bool = l >= 0 - yyj2591++ - if yyhl2591 { - yyb2591 = yyj2591 > l - } else { - yyb2591 = r.CheckBreak() - } - if yyb2591 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2591++ - if yyhl2591 { - yyb2591 = yyj2591 > l - } else { - yyb2591 = r.CheckBreak() - } - if yyb2591 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2591++ - if yyhl2591 { - yyb2591 = yyj2591 > l - } else { - yyb2591 = r.CheckBreak() - } - if yyb2591 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2594 := &x.ListMeta - yym2595 := z.DecBinary() - _ = yym2595 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2594) { - } else { - z.DecFallback(yyv2594, false) - } - } - yyj2591++ - if yyhl2591 { - yyb2591 = yyj2591 > l - } else { - yyb2591 = r.CheckBreak() - } - if yyb2591 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2596 := &x.Items - yym2597 := z.DecBinary() - _ = yym2597 - if false { - } else { - h.decSliceReplicationController((*[]ReplicationController)(yyv2596), d) - } - } - for { - yyj2591++ - if yyhl2591 { - yyb2591 = yyj2591 > l - } else { - yyb2591 = r.CheckBreak() - } - if yyb2591 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2591-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 { - yym2598 := z.EncBinary() - _ = yym2598 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2599 := !z.EncBinary() - yy2arr2599 := z.EncBasicHandle().StructToArray - var yyq2599 [4]bool - _, _, _ = yysep2599, yyq2599, yy2arr2599 - const yyr2599 bool = false - yyq2599[0] = x.Kind != "" - yyq2599[1] = x.APIVersion != "" - yyq2599[2] = true - var yynn2599 int - if yyr2599 || yy2arr2599 { - r.EncodeArrayStart(4) - } else { - yynn2599 = 1 - for _, b := range yyq2599 { - if b { - yynn2599++ - } - } - r.EncodeMapStart(yynn2599) - yynn2599 = 0 - } - if yyr2599 || yy2arr2599 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2599[0] { - yym2601 := z.EncBinary() - _ = yym2601 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2599[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2602 := z.EncBinary() - _ = yym2602 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2599 || yy2arr2599 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2599[1] { - yym2604 := z.EncBinary() - _ = yym2604 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2599[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2605 := z.EncBinary() - _ = yym2605 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2599 || yy2arr2599 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2599[2] { - yy2607 := &x.ListMeta - yym2608 := z.EncBinary() - _ = yym2608 - if false { - } else if z.HasExtensions() && z.EncExt(yy2607) { - } else { - z.EncFallback(yy2607) - } - } else { - r.EncodeNil() - } - } else { - if yyq2599[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2609 := &x.ListMeta - yym2610 := z.EncBinary() - _ = yym2610 - if false { - } else if z.HasExtensions() && z.EncExt(yy2609) { - } else { - z.EncFallback(yy2609) - } - } - } - if yyr2599 || yy2arr2599 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2612 := z.EncBinary() - _ = yym2612 - 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 { - yym2613 := z.EncBinary() - _ = yym2613 - if false { - } else { - h.encSliceService(([]Service)(x.Items), e) - } - } - } - if yyr2599 || yy2arr2599 { - 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 - yym2614 := z.DecBinary() - _ = yym2614 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2615 := r.ContainerType() - if yyct2615 == codecSelferValueTypeMap1234 { - yyl2615 := r.ReadMapStart() - if yyl2615 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2615, d) - } - } else if yyct2615 == codecSelferValueTypeArray1234 { - yyl2615 := r.ReadArrayStart() - if yyl2615 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2615, 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 yys2616Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2616Slc - var yyhl2616 bool = l >= 0 - for yyj2616 := 0; ; yyj2616++ { - if yyhl2616 { - if yyj2616 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2616Slc = r.DecodeBytes(yys2616Slc, true, true) - yys2616 := string(yys2616Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2616 { - 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 { - yyv2619 := &x.ListMeta - yym2620 := z.DecBinary() - _ = yym2620 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2619) { - } else { - z.DecFallback(yyv2619, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2621 := &x.Items - yym2622 := z.DecBinary() - _ = yym2622 - if false { - } else { - h.decSliceService((*[]Service)(yyv2621), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2616) - } // end switch yys2616 - } // end for yyj2616 - 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 yyj2623 int - var yyb2623 bool - var yyhl2623 bool = l >= 0 - yyj2623++ - if yyhl2623 { - yyb2623 = yyj2623 > l - } else { - yyb2623 = r.CheckBreak() - } - if yyb2623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2623++ - if yyhl2623 { - yyb2623 = yyj2623 > l - } else { - yyb2623 = r.CheckBreak() - } - if yyb2623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2623++ - if yyhl2623 { - yyb2623 = yyj2623 > l - } else { - yyb2623 = r.CheckBreak() - } - if yyb2623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2626 := &x.ListMeta - yym2627 := z.DecBinary() - _ = yym2627 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2626) { - } else { - z.DecFallback(yyv2626, false) - } - } - yyj2623++ - if yyhl2623 { - yyb2623 = yyj2623 > l - } else { - yyb2623 = r.CheckBreak() - } - if yyb2623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2628 := &x.Items - yym2629 := z.DecBinary() - _ = yym2629 - if false { - } else { - h.decSliceService((*[]Service)(yyv2628), d) - } - } - for { - yyj2623++ - if yyhl2623 { - yyb2623 = yyj2623 > l - } else { - yyb2623 = r.CheckBreak() - } - if yyb2623 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2623-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ServiceAffinity) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym2630 := z.EncBinary() - _ = yym2630 - 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 - yym2631 := z.DecBinary() - _ = yym2631 - 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 - yym2632 := z.EncBinary() - _ = yym2632 - 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 - yym2633 := z.DecBinary() - _ = yym2633 - 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 { - yym2634 := z.EncBinary() - _ = yym2634 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2635 := !z.EncBinary() - yy2arr2635 := z.EncBasicHandle().StructToArray - var yyq2635 [1]bool - _, _, _ = yysep2635, yyq2635, yy2arr2635 - const yyr2635 bool = false - yyq2635[0] = true - var yynn2635 int - if yyr2635 || yy2arr2635 { - r.EncodeArrayStart(1) - } else { - yynn2635 = 0 - for _, b := range yyq2635 { - if b { - yynn2635++ - } - } - r.EncodeMapStart(yynn2635) - yynn2635 = 0 - } - if yyr2635 || yy2arr2635 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2635[0] { - yy2637 := &x.LoadBalancer - yy2637.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2635[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancer")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2638 := &x.LoadBalancer - yy2638.CodecEncodeSelf(e) - } - } - if yyr2635 || yy2arr2635 { - 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 - yym2639 := z.DecBinary() - _ = yym2639 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2640 := r.ContainerType() - if yyct2640 == codecSelferValueTypeMap1234 { - yyl2640 := r.ReadMapStart() - if yyl2640 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2640, d) - } - } else if yyct2640 == codecSelferValueTypeArray1234 { - yyl2640 := r.ReadArrayStart() - if yyl2640 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2640, 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 yys2641Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2641Slc - var yyhl2641 bool = l >= 0 - for yyj2641 := 0; ; yyj2641++ { - if yyhl2641 { - if yyj2641 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2641Slc = r.DecodeBytes(yys2641Slc, true, true) - yys2641 := string(yys2641Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2641 { - case "loadBalancer": - if r.TryDecodeAsNil() { - x.LoadBalancer = LoadBalancerStatus{} - } else { - yyv2642 := &x.LoadBalancer - yyv2642.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2641) - } // end switch yys2641 - } // end for yyj2641 - 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 yyj2643 int - var yyb2643 bool - var yyhl2643 bool = l >= 0 - yyj2643++ - if yyhl2643 { - yyb2643 = yyj2643 > l - } else { - yyb2643 = r.CheckBreak() - } - if yyb2643 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancer = LoadBalancerStatus{} - } else { - yyv2644 := &x.LoadBalancer - yyv2644.CodecDecodeSelf(d) - } - for { - yyj2643++ - if yyhl2643 { - yyb2643 = yyj2643 > l - } else { - yyb2643 = r.CheckBreak() - } - if yyb2643 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2643-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 { - yym2645 := z.EncBinary() - _ = yym2645 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2646 := !z.EncBinary() - yy2arr2646 := z.EncBasicHandle().StructToArray - var yyq2646 [1]bool - _, _, _ = yysep2646, yyq2646, yy2arr2646 - const yyr2646 bool = false - yyq2646[0] = len(x.Ingress) != 0 - var yynn2646 int - if yyr2646 || yy2arr2646 { - r.EncodeArrayStart(1) - } else { - yynn2646 = 0 - for _, b := range yyq2646 { - if b { - yynn2646++ - } - } - r.EncodeMapStart(yynn2646) - yynn2646 = 0 - } - if yyr2646 || yy2arr2646 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2646[0] { - if x.Ingress == nil { - r.EncodeNil() - } else { - yym2648 := z.EncBinary() - _ = yym2648 - if false { - } else { - h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2646[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ingress")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ingress == nil { - r.EncodeNil() - } else { - yym2649 := z.EncBinary() - _ = yym2649 - if false { - } else { - h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e) - } - } - } - } - if yyr2646 || yy2arr2646 { - 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 - yym2650 := z.DecBinary() - _ = yym2650 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2651 := r.ContainerType() - if yyct2651 == codecSelferValueTypeMap1234 { - yyl2651 := r.ReadMapStart() - if yyl2651 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2651, d) - } - } else if yyct2651 == codecSelferValueTypeArray1234 { - yyl2651 := r.ReadArrayStart() - if yyl2651 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2651, 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 yys2652Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2652Slc - var yyhl2652 bool = l >= 0 - for yyj2652 := 0; ; yyj2652++ { - if yyhl2652 { - if yyj2652 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2652Slc = r.DecodeBytes(yys2652Slc, true, true) - yys2652 := string(yys2652Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2652 { - case "ingress": - if r.TryDecodeAsNil() { - x.Ingress = nil - } else { - yyv2653 := &x.Ingress - yym2654 := z.DecBinary() - _ = yym2654 - if false { - } else { - h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv2653), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2652) - } // end switch yys2652 - } // end for yyj2652 - 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 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.Ingress = nil - } else { - yyv2656 := &x.Ingress - yym2657 := z.DecBinary() - _ = yym2657 - if false { - } else { - h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv2656), 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 *LoadBalancerIngress) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym2658 := z.EncBinary() - _ = yym2658 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2659 := !z.EncBinary() - yy2arr2659 := z.EncBasicHandle().StructToArray - var yyq2659 [2]bool - _, _, _ = yysep2659, yyq2659, yy2arr2659 - const yyr2659 bool = false - yyq2659[0] = x.IP != "" - yyq2659[1] = x.Hostname != "" - var yynn2659 int - if yyr2659 || yy2arr2659 { - r.EncodeArrayStart(2) - } else { - yynn2659 = 0 - for _, b := range yyq2659 { - if b { - yynn2659++ - } - } - r.EncodeMapStart(yynn2659) - yynn2659 = 0 - } - if yyr2659 || yy2arr2659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2659[0] { - yym2661 := z.EncBinary() - _ = yym2661 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2659[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ip")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2662 := z.EncBinary() - _ = yym2662 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IP)) - } - } - } - if yyr2659 || yy2arr2659 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2659[1] { - yym2664 := z.EncBinary() - _ = yym2664 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2659[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostname")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2665 := z.EncBinary() - _ = yym2665 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } - } - if yyr2659 || yy2arr2659 { - 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 - yym2666 := z.DecBinary() - _ = yym2666 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2667 := r.ContainerType() - if yyct2667 == codecSelferValueTypeMap1234 { - yyl2667 := r.ReadMapStart() - if yyl2667 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2667, d) - } - } else if yyct2667 == codecSelferValueTypeArray1234 { - yyl2667 := r.ReadArrayStart() - if yyl2667 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2667, 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 yys2668Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2668Slc - var yyhl2668 bool = l >= 0 - for yyj2668 := 0; ; yyj2668++ { - if yyhl2668 { - if yyj2668 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2668Slc = r.DecodeBytes(yys2668Slc, true, true) - yys2668 := string(yys2668Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2668 { - 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, yys2668) - } // end switch yys2668 - } // end for yyj2668 - 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 yyj2671 int - var yyb2671 bool - var yyhl2671 bool = l >= 0 - yyj2671++ - if yyhl2671 { - yyb2671 = yyj2671 > l - } else { - yyb2671 = r.CheckBreak() - } - if yyb2671 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.IP = "" - } else { - x.IP = string(r.DecodeString()) - } - yyj2671++ - if yyhl2671 { - yyb2671 = yyj2671 > l - } else { - yyb2671 = r.CheckBreak() - } - if yyb2671 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hostname = "" - } else { - x.Hostname = string(r.DecodeString()) - } - for { - yyj2671++ - if yyhl2671 { - yyb2671 = yyj2671 > l - } else { - yyb2671 = r.CheckBreak() - } - if yyb2671 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2671-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 { - yym2674 := z.EncBinary() - _ = yym2674 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2675 := !z.EncBinary() - yy2arr2675 := z.EncBasicHandle().StructToArray - var yyq2675 [9]bool - _, _, _ = yysep2675, yyq2675, yy2arr2675 - const yyr2675 bool = false - yyq2675[0] = x.Type != "" - yyq2675[3] = x.ClusterIP != "" - yyq2675[5] = len(x.ExternalIPs) != 0 - yyq2675[6] = x.LoadBalancerIP != "" - yyq2675[7] = x.SessionAffinity != "" - yyq2675[8] = len(x.LoadBalancerSourceRanges) != 0 - var yynn2675 int - if yyr2675 || yy2arr2675 { - r.EncodeArrayStart(9) - } else { - yynn2675 = 3 - for _, b := range yyq2675 { - if b { - yynn2675++ - } - } - r.EncodeMapStart(yynn2675) - yynn2675 = 0 - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2675[0] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2675[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym2678 := z.EncBinary() - _ = yym2678 - 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 { - yym2679 := z.EncBinary() - _ = yym2679 - if false { - } else { - h.encSliceServicePort(([]ServicePort)(x.Ports), e) - } - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym2681 := z.EncBinary() - _ = yym2681 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym2682 := z.EncBinary() - _ = yym2682 - if false { - } else { - z.F.EncMapStringStringV(x.Selector, false, e) - } - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2675[3] { - yym2684 := z.EncBinary() - _ = yym2684 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2675[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2685 := z.EncBinary() - _ = yym2685 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP)) - } - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2687 := z.EncBinary() - _ = yym2687 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalName)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ExternalName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2688 := z.EncBinary() - _ = yym2688 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalName)) - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2675[5] { - if x.ExternalIPs == nil { - r.EncodeNil() - } else { - yym2690 := z.EncBinary() - _ = yym2690 - if false { - } else { - z.F.EncSliceStringV(x.ExternalIPs, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2675[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("externalIPs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ExternalIPs == nil { - r.EncodeNil() - } else { - yym2691 := z.EncBinary() - _ = yym2691 - if false { - } else { - z.F.EncSliceStringV(x.ExternalIPs, false, e) - } - } - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2675[6] { - yym2693 := z.EncBinary() - _ = yym2693 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2675[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancerIP")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2694 := z.EncBinary() - _ = yym2694 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP)) - } - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2675[7] { - x.SessionAffinity.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2675[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("sessionAffinity")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.SessionAffinity.CodecEncodeSelf(e) - } - } - if yyr2675 || yy2arr2675 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2675[8] { - if x.LoadBalancerSourceRanges == nil { - r.EncodeNil() - } else { - yym2697 := z.EncBinary() - _ = yym2697 - if false { - } else { - z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2675[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancerSourceRanges")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LoadBalancerSourceRanges == nil { - r.EncodeNil() - } else { - yym2698 := z.EncBinary() - _ = yym2698 - if false { - } else { - z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e) - } - } - } - } - if yyr2675 || yy2arr2675 { - 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 - yym2699 := z.DecBinary() - _ = yym2699 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2700 := r.ContainerType() - if yyct2700 == codecSelferValueTypeMap1234 { - yyl2700 := r.ReadMapStart() - if yyl2700 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2700, d) - } - } else if yyct2700 == codecSelferValueTypeArray1234 { - yyl2700 := r.ReadArrayStart() - if yyl2700 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2700, 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 yys2701Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2701Slc - var yyhl2701 bool = l >= 0 - for yyj2701 := 0; ; yyj2701++ { - if yyhl2701 { - if yyj2701 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2701Slc = r.DecodeBytes(yys2701Slc, true, true) - yys2701 := string(yys2701Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2701 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ServiceType(r.DecodeString()) - } - case "ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2703 := &x.Ports - yym2704 := z.DecBinary() - _ = yym2704 - if false { - } else { - h.decSliceServicePort((*[]ServicePort)(yyv2703), d) - } - } - case "selector": - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2705 := &x.Selector - yym2706 := z.DecBinary() - _ = yym2706 - if false { - } else { - z.F.DecMapStringStringX(yyv2705, false, d) - } - } - case "clusterIP": - if r.TryDecodeAsNil() { - x.ClusterIP = "" - } else { - x.ClusterIP = string(r.DecodeString()) - } - case "ExternalName": - if r.TryDecodeAsNil() { - x.ExternalName = "" - } else { - x.ExternalName = string(r.DecodeString()) - } - case "externalIPs": - if r.TryDecodeAsNil() { - x.ExternalIPs = nil - } else { - yyv2709 := &x.ExternalIPs - yym2710 := z.DecBinary() - _ = yym2710 - if false { - } else { - z.F.DecSliceStringX(yyv2709, false, d) - } - } - case "loadBalancerIP": - if r.TryDecodeAsNil() { - x.LoadBalancerIP = "" - } else { - x.LoadBalancerIP = string(r.DecodeString()) - } - case "sessionAffinity": - if r.TryDecodeAsNil() { - x.SessionAffinity = "" - } else { - x.SessionAffinity = ServiceAffinity(r.DecodeString()) - } - case "loadBalancerSourceRanges": - if r.TryDecodeAsNil() { - x.LoadBalancerSourceRanges = nil - } else { - yyv2713 := &x.LoadBalancerSourceRanges - yym2714 := z.DecBinary() - _ = yym2714 - if false { - } else { - z.F.DecSliceStringX(yyv2713, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2701) - } // end switch yys2701 - } // end for yyj2701 - 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 yyj2715 int - var yyb2715 bool - var yyhl2715 bool = l >= 0 - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ServiceType(r.DecodeString()) - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2717 := &x.Ports - yym2718 := z.DecBinary() - _ = yym2718 - if false { - } else { - h.decSliceServicePort((*[]ServicePort)(yyv2717), d) - } - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Selector = nil - } else { - yyv2719 := &x.Selector - yym2720 := z.DecBinary() - _ = yym2720 - if false { - } else { - z.F.DecMapStringStringX(yyv2719, false, d) - } - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterIP = "" - } else { - x.ClusterIP = string(r.DecodeString()) - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExternalName = "" - } else { - x.ExternalName = string(r.DecodeString()) - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExternalIPs = nil - } else { - yyv2723 := &x.ExternalIPs - yym2724 := z.DecBinary() - _ = yym2724 - if false { - } else { - z.F.DecSliceStringX(yyv2723, false, d) - } - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancerIP = "" - } else { - x.LoadBalancerIP = string(r.DecodeString()) - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SessionAffinity = "" - } else { - x.SessionAffinity = ServiceAffinity(r.DecodeString()) - } - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancerSourceRanges = nil - } else { - yyv2727 := &x.LoadBalancerSourceRanges - yym2728 := z.DecBinary() - _ = yym2728 - if false { - } else { - z.F.DecSliceStringX(yyv2727, false, d) - } - } - for { - yyj2715++ - if yyhl2715 { - yyb2715 = yyj2715 > l - } else { - yyb2715 = r.CheckBreak() - } - if yyb2715 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2715-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 { - yym2729 := z.EncBinary() - _ = yym2729 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2730 := !z.EncBinary() - yy2arr2730 := z.EncBasicHandle().StructToArray - var yyq2730 [5]bool - _, _, _ = yysep2730, yyq2730, yy2arr2730 - const yyr2730 bool = false - var yynn2730 int - if yyr2730 || yy2arr2730 { - r.EncodeArrayStart(5) - } else { - yynn2730 = 5 - for _, b := range yyq2730 { - if b { - yynn2730++ - } - } - r.EncodeMapStart(yynn2730) - yynn2730 = 0 - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2732 := z.EncBinary() - _ = yym2732 - 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) - yym2733 := z.EncBinary() - _ = yym2733 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - x.Protocol.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2736 := z.EncBinary() - _ = yym2736 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2737 := z.EncBinary() - _ = yym2737 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy2739 := &x.TargetPort - yym2740 := z.EncBinary() - _ = yym2740 - if false { - } else if z.HasExtensions() && z.EncExt(yy2739) { - } else if !yym2740 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2739) - } else { - z.EncFallback(yy2739) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("targetPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2741 := &x.TargetPort - yym2742 := z.EncBinary() - _ = yym2742 - if false { - } else if z.HasExtensions() && z.EncExt(yy2741) { - } else if !yym2742 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2741) - } else { - z.EncFallback(yy2741) - } - } - if yyr2730 || yy2arr2730 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2744 := z.EncBinary() - _ = yym2744 - if false { - } else { - r.EncodeInt(int64(x.NodePort)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodePort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2745 := z.EncBinary() - _ = yym2745 - if false { - } else { - r.EncodeInt(int64(x.NodePort)) - } - } - if yyr2730 || yy2arr2730 { - 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 - yym2746 := z.DecBinary() - _ = yym2746 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2747 := r.ContainerType() - if yyct2747 == codecSelferValueTypeMap1234 { - yyl2747 := r.ReadMapStart() - if yyl2747 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2747, d) - } - } else if yyct2747 == codecSelferValueTypeArray1234 { - yyl2747 := r.ReadArrayStart() - if yyl2747 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2747, 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 yys2748Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2748Slc - var yyhl2748 bool = l >= 0 - for yyj2748 := 0; ; yyj2748++ { - if yyhl2748 { - if yyj2748 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2748Slc = r.DecodeBytes(yys2748Slc, true, true) - yys2748 := string(yys2748Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2748 { - 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 { - yyv2752 := &x.TargetPort - yym2753 := z.DecBinary() - _ = yym2753 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2752) { - } else if !yym2753 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2752) - } else { - z.DecFallback(yyv2752, false) - } - } - case "nodePort": - if r.TryDecodeAsNil() { - x.NodePort = 0 - } else { - x.NodePort = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys2748) - } // end switch yys2748 - } // end for yyj2748 - 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 yyj2755 int - var yyb2755 bool - var yyhl2755 bool = l >= 0 - yyj2755++ - if yyhl2755 { - yyb2755 = yyj2755 > l - } else { - yyb2755 = r.CheckBreak() - } - if yyb2755 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj2755++ - if yyhl2755 { - yyb2755 = yyj2755 > l - } else { - yyb2755 = r.CheckBreak() - } - if yyb2755 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - x.Protocol = Protocol(r.DecodeString()) - } - yyj2755++ - if yyhl2755 { - yyb2755 = yyj2755 > l - } else { - yyb2755 = r.CheckBreak() - } - if yyb2755 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - yyj2755++ - if yyhl2755 { - yyb2755 = yyj2755 > l - } else { - yyb2755 = r.CheckBreak() - } - if yyb2755 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetPort = pkg4_intstr.IntOrString{} - } else { - yyv2759 := &x.TargetPort - yym2760 := z.DecBinary() - _ = yym2760 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2759) { - } else if !yym2760 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2759) - } else { - z.DecFallback(yyv2759, false) - } - } - yyj2755++ - if yyhl2755 { - yyb2755 = yyj2755 > l - } else { - yyb2755 = r.CheckBreak() - } - if yyb2755 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodePort = 0 - } else { - x.NodePort = int32(r.DecodeInt(32)) - } - for { - yyj2755++ - if yyhl2755 { - yyb2755 = yyj2755 > l - } else { - yyb2755 = r.CheckBreak() - } - if yyb2755 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2755-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 { - yym2762 := z.EncBinary() - _ = yym2762 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2763 := !z.EncBinary() - yy2arr2763 := z.EncBasicHandle().StructToArray - var yyq2763 [5]bool - _, _, _ = yysep2763, yyq2763, yy2arr2763 - const yyr2763 bool = false - yyq2763[0] = x.Kind != "" - yyq2763[1] = x.APIVersion != "" - yyq2763[2] = true - yyq2763[3] = true - yyq2763[4] = true - var yynn2763 int - if yyr2763 || yy2arr2763 { - r.EncodeArrayStart(5) - } else { - yynn2763 = 0 - for _, b := range yyq2763 { - if b { - yynn2763++ - } - } - r.EncodeMapStart(yynn2763) - yynn2763 = 0 - } - if yyr2763 || yy2arr2763 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2763[0] { - yym2765 := z.EncBinary() - _ = yym2765 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2763[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2766 := z.EncBinary() - _ = yym2766 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2763 || yy2arr2763 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2763[1] { - yym2768 := z.EncBinary() - _ = yym2768 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2763[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2769 := z.EncBinary() - _ = yym2769 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2763 || yy2arr2763 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2763[2] { - yy2771 := &x.ObjectMeta - yy2771.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2763[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2772 := &x.ObjectMeta - yy2772.CodecEncodeSelf(e) - } - } - if yyr2763 || yy2arr2763 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2763[3] { - yy2774 := &x.Spec - yy2774.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2763[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2775 := &x.Spec - yy2775.CodecEncodeSelf(e) - } - } - if yyr2763 || yy2arr2763 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2763[4] { - yy2777 := &x.Status - yy2777.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2763[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2778 := &x.Status - yy2778.CodecEncodeSelf(e) - } - } - if yyr2763 || yy2arr2763 { - 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 - yym2779 := z.DecBinary() - _ = yym2779 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2780 := r.ContainerType() - if yyct2780 == codecSelferValueTypeMap1234 { - yyl2780 := r.ReadMapStart() - if yyl2780 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2780, d) - } - } else if yyct2780 == codecSelferValueTypeArray1234 { - yyl2780 := r.ReadArrayStart() - if yyl2780 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2780, 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 yys2781Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2781Slc - var yyhl2781 bool = l >= 0 - for yyj2781 := 0; ; yyj2781++ { - if yyhl2781 { - if yyj2781 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2781Slc = r.DecodeBytes(yys2781Slc, true, true) - yys2781 := string(yys2781Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2781 { - 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 { - yyv2784 := &x.ObjectMeta - yyv2784.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ServiceSpec{} - } else { - yyv2785 := &x.Spec - yyv2785.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ServiceStatus{} - } else { - yyv2786 := &x.Status - yyv2786.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys2781) - } // end switch yys2781 - } // end for yyj2781 - 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 yyj2787 int - var yyb2787 bool - var yyhl2787 bool = l >= 0 - yyj2787++ - if yyhl2787 { - yyb2787 = yyj2787 > l - } else { - yyb2787 = r.CheckBreak() - } - if yyb2787 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2787++ - if yyhl2787 { - yyb2787 = yyj2787 > l - } else { - yyb2787 = r.CheckBreak() - } - if yyb2787 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2787++ - if yyhl2787 { - yyb2787 = yyj2787 > l - } else { - yyb2787 = r.CheckBreak() - } - if yyb2787 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2790 := &x.ObjectMeta - yyv2790.CodecDecodeSelf(d) - } - yyj2787++ - if yyhl2787 { - yyb2787 = yyj2787 > l - } else { - yyb2787 = r.CheckBreak() - } - if yyb2787 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ServiceSpec{} - } else { - yyv2791 := &x.Spec - yyv2791.CodecDecodeSelf(d) - } - yyj2787++ - if yyhl2787 { - yyb2787 = yyj2787 > l - } else { - yyb2787 = r.CheckBreak() - } - if yyb2787 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ServiceStatus{} - } else { - yyv2792 := &x.Status - yyv2792.CodecDecodeSelf(d) - } - for { - yyj2787++ - if yyhl2787 { - yyb2787 = yyj2787 > l - } else { - yyb2787 = r.CheckBreak() - } - if yyb2787 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2787-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 { - yym2793 := z.EncBinary() - _ = yym2793 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2794 := !z.EncBinary() - yy2arr2794 := z.EncBasicHandle().StructToArray - var yyq2794 [5]bool - _, _, _ = yysep2794, yyq2794, yy2arr2794 - const yyr2794 bool = false - yyq2794[0] = x.Kind != "" - yyq2794[1] = x.APIVersion != "" - yyq2794[2] = true - yyq2794[4] = len(x.ImagePullSecrets) != 0 - var yynn2794 int - if yyr2794 || yy2arr2794 { - r.EncodeArrayStart(5) - } else { - yynn2794 = 1 - for _, b := range yyq2794 { - if b { - yynn2794++ - } - } - r.EncodeMapStart(yynn2794) - yynn2794 = 0 - } - if yyr2794 || yy2arr2794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2794[0] { - yym2796 := z.EncBinary() - _ = yym2796 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2794[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2797 := z.EncBinary() - _ = yym2797 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2794 || yy2arr2794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2794[1] { - yym2799 := z.EncBinary() - _ = yym2799 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2794[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2800 := z.EncBinary() - _ = yym2800 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2794 || yy2arr2794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2794[2] { - yy2802 := &x.ObjectMeta - yy2802.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2794[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2803 := &x.ObjectMeta - yy2803.CodecEncodeSelf(e) - } - } - if yyr2794 || yy2arr2794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Secrets == nil { - r.EncodeNil() - } else { - yym2805 := z.EncBinary() - _ = yym2805 - if false { - } else { - h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secrets")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Secrets == nil { - r.EncodeNil() - } else { - yym2806 := z.EncBinary() - _ = yym2806 - if false { - } else { - h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e) - } - } - } - if yyr2794 || yy2arr2794 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2794[4] { - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2808 := z.EncBinary() - _ = yym2808 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2794[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ImagePullSecrets == nil { - r.EncodeNil() - } else { - yym2809 := z.EncBinary() - _ = yym2809 - if false { - } else { - h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) - } - } - } - } - if yyr2794 || yy2arr2794 { - 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 - yym2810 := z.DecBinary() - _ = yym2810 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2811 := r.ContainerType() - if yyct2811 == codecSelferValueTypeMap1234 { - yyl2811 := r.ReadMapStart() - if yyl2811 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2811, d) - } - } else if yyct2811 == codecSelferValueTypeArray1234 { - yyl2811 := r.ReadArrayStart() - if yyl2811 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2811, 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 yys2812Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2812Slc - var yyhl2812 bool = l >= 0 - for yyj2812 := 0; ; yyj2812++ { - if yyhl2812 { - if yyj2812 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2812Slc = r.DecodeBytes(yys2812Slc, true, true) - yys2812 := string(yys2812Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2812 { - 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 { - yyv2815 := &x.ObjectMeta - yyv2815.CodecDecodeSelf(d) - } - case "secrets": - if r.TryDecodeAsNil() { - x.Secrets = nil - } else { - yyv2816 := &x.Secrets - yym2817 := z.DecBinary() - _ = yym2817 - if false { - } else { - h.decSliceObjectReference((*[]ObjectReference)(yyv2816), d) - } - } - case "imagePullSecrets": - if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil - } else { - yyv2818 := &x.ImagePullSecrets - yym2819 := z.DecBinary() - _ = yym2819 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2818), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2812) - } // end switch yys2812 - } // end for yyj2812 - 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 yyj2820 int - var yyb2820 bool - var yyhl2820 bool = l >= 0 - yyj2820++ - if yyhl2820 { - yyb2820 = yyj2820 > l - } else { - yyb2820 = r.CheckBreak() - } - if yyb2820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2820++ - if yyhl2820 { - yyb2820 = yyj2820 > l - } else { - yyb2820 = r.CheckBreak() - } - if yyb2820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2820++ - if yyhl2820 { - yyb2820 = yyj2820 > l - } else { - yyb2820 = r.CheckBreak() - } - if yyb2820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2823 := &x.ObjectMeta - yyv2823.CodecDecodeSelf(d) - } - yyj2820++ - if yyhl2820 { - yyb2820 = yyj2820 > l - } else { - yyb2820 = r.CheckBreak() - } - if yyb2820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Secrets = nil - } else { - yyv2824 := &x.Secrets - yym2825 := z.DecBinary() - _ = yym2825 - if false { - } else { - h.decSliceObjectReference((*[]ObjectReference)(yyv2824), d) - } - } - yyj2820++ - if yyhl2820 { - yyb2820 = yyj2820 > l - } else { - yyb2820 = r.CheckBreak() - } - if yyb2820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil - } else { - yyv2826 := &x.ImagePullSecrets - yym2827 := z.DecBinary() - _ = yym2827 - if false { - } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2826), d) - } - } - for { - yyj2820++ - if yyhl2820 { - yyb2820 = yyj2820 > l - } else { - yyb2820 = r.CheckBreak() - } - if yyb2820 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2820-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 { - yym2828 := z.EncBinary() - _ = yym2828 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2829 := !z.EncBinary() - yy2arr2829 := z.EncBasicHandle().StructToArray - var yyq2829 [4]bool - _, _, _ = yysep2829, yyq2829, yy2arr2829 - const yyr2829 bool = false - yyq2829[0] = x.Kind != "" - yyq2829[1] = x.APIVersion != "" - yyq2829[2] = true - var yynn2829 int - if yyr2829 || yy2arr2829 { - r.EncodeArrayStart(4) - } else { - yynn2829 = 1 - for _, b := range yyq2829 { - if b { - yynn2829++ - } - } - r.EncodeMapStart(yynn2829) - yynn2829 = 0 - } - if yyr2829 || yy2arr2829 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2829[0] { - yym2831 := z.EncBinary() - _ = yym2831 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2829[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2832 := z.EncBinary() - _ = yym2832 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2829 || yy2arr2829 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2829[1] { - yym2834 := z.EncBinary() - _ = yym2834 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2829[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2835 := z.EncBinary() - _ = yym2835 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2829 || yy2arr2829 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2829[2] { - yy2837 := &x.ListMeta - yym2838 := z.EncBinary() - _ = yym2838 - if false { - } else if z.HasExtensions() && z.EncExt(yy2837) { - } else { - z.EncFallback(yy2837) - } - } else { - r.EncodeNil() - } - } else { - if yyq2829[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2839 := &x.ListMeta - yym2840 := z.EncBinary() - _ = yym2840 - if false { - } else if z.HasExtensions() && z.EncExt(yy2839) { - } else { - z.EncFallback(yy2839) - } - } - } - if yyr2829 || yy2arr2829 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2842 := z.EncBinary() - _ = yym2842 - 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 { - yym2843 := z.EncBinary() - _ = yym2843 - if false { - } else { - h.encSliceServiceAccount(([]ServiceAccount)(x.Items), e) - } - } - } - if yyr2829 || yy2arr2829 { - 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 - yym2844 := z.DecBinary() - _ = yym2844 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2845 := r.ContainerType() - if yyct2845 == codecSelferValueTypeMap1234 { - yyl2845 := r.ReadMapStart() - if yyl2845 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2845, d) - } - } else if yyct2845 == codecSelferValueTypeArray1234 { - yyl2845 := r.ReadArrayStart() - if yyl2845 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2845, 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 yys2846Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2846Slc - var yyhl2846 bool = l >= 0 - for yyj2846 := 0; ; yyj2846++ { - if yyhl2846 { - if yyj2846 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2846Slc = r.DecodeBytes(yys2846Slc, true, true) - yys2846 := string(yys2846Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2846 { - 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 { - yyv2849 := &x.ListMeta - yym2850 := z.DecBinary() - _ = yym2850 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2849) { - } else { - z.DecFallback(yyv2849, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2851 := &x.Items - yym2852 := z.DecBinary() - _ = yym2852 - if false { - } else { - h.decSliceServiceAccount((*[]ServiceAccount)(yyv2851), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2846) - } // end switch yys2846 - } // end for yyj2846 - 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 yyj2853 int - var yyb2853 bool - var yyhl2853 bool = l >= 0 - yyj2853++ - if yyhl2853 { - yyb2853 = yyj2853 > l - } else { - yyb2853 = r.CheckBreak() - } - if yyb2853 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2853++ - if yyhl2853 { - yyb2853 = yyj2853 > l - } else { - yyb2853 = r.CheckBreak() - } - if yyb2853 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2853++ - if yyhl2853 { - yyb2853 = yyj2853 > l - } else { - yyb2853 = r.CheckBreak() - } - if yyb2853 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2856 := &x.ListMeta - yym2857 := z.DecBinary() - _ = yym2857 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2856) { - } else { - z.DecFallback(yyv2856, false) - } - } - yyj2853++ - if yyhl2853 { - yyb2853 = yyj2853 > l - } else { - yyb2853 = r.CheckBreak() - } - if yyb2853 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2858 := &x.Items - yym2859 := z.DecBinary() - _ = yym2859 - if false { - } else { - h.decSliceServiceAccount((*[]ServiceAccount)(yyv2858), d) - } - } - for { - yyj2853++ - if yyhl2853 { - yyb2853 = yyj2853 > l - } else { - yyb2853 = r.CheckBreak() - } - if yyb2853 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2853-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 { - yym2860 := z.EncBinary() - _ = yym2860 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2861 := !z.EncBinary() - yy2arr2861 := z.EncBasicHandle().StructToArray - var yyq2861 [4]bool - _, _, _ = yysep2861, yyq2861, yy2arr2861 - const yyr2861 bool = false - yyq2861[0] = x.Kind != "" - yyq2861[1] = x.APIVersion != "" - yyq2861[2] = true - var yynn2861 int - if yyr2861 || yy2arr2861 { - r.EncodeArrayStart(4) - } else { - yynn2861 = 1 - for _, b := range yyq2861 { - if b { - yynn2861++ - } - } - r.EncodeMapStart(yynn2861) - yynn2861 = 0 - } - if yyr2861 || yy2arr2861 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2861[0] { - yym2863 := z.EncBinary() - _ = yym2863 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2861[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2864 := z.EncBinary() - _ = yym2864 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2861 || yy2arr2861 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2861[1] { - yym2866 := z.EncBinary() - _ = yym2866 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2861[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2867 := z.EncBinary() - _ = yym2867 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2861 || yy2arr2861 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2861[2] { - yy2869 := &x.ObjectMeta - yy2869.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2861[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2870 := &x.ObjectMeta - yy2870.CodecEncodeSelf(e) - } - } - if yyr2861 || yy2arr2861 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Subsets == nil { - r.EncodeNil() - } else { - yym2872 := z.EncBinary() - _ = yym2872 - 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 { - yym2873 := z.EncBinary() - _ = yym2873 - if false { - } else { - h.encSliceEndpointSubset(([]EndpointSubset)(x.Subsets), e) - } - } - } - if yyr2861 || yy2arr2861 { - 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 - yym2874 := z.DecBinary() - _ = yym2874 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2875 := r.ContainerType() - if yyct2875 == codecSelferValueTypeMap1234 { - yyl2875 := r.ReadMapStart() - if yyl2875 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2875, d) - } - } else if yyct2875 == codecSelferValueTypeArray1234 { - yyl2875 := r.ReadArrayStart() - if yyl2875 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2875, 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 yys2876Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2876Slc - var yyhl2876 bool = l >= 0 - for yyj2876 := 0; ; yyj2876++ { - if yyhl2876 { - if yyj2876 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2876Slc = r.DecodeBytes(yys2876Slc, true, true) - yys2876 := string(yys2876Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2876 { - 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 { - yyv2879 := &x.ObjectMeta - yyv2879.CodecDecodeSelf(d) - } - case "Subsets": - if r.TryDecodeAsNil() { - x.Subsets = nil - } else { - yyv2880 := &x.Subsets - yym2881 := z.DecBinary() - _ = yym2881 - if false { - } else { - h.decSliceEndpointSubset((*[]EndpointSubset)(yyv2880), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2876) - } // end switch yys2876 - } // end for yyj2876 - 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 yyj2882 int - var yyb2882 bool - var yyhl2882 bool = l >= 0 - yyj2882++ - if yyhl2882 { - yyb2882 = yyj2882 > l - } else { - yyb2882 = r.CheckBreak() - } - if yyb2882 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2882++ - if yyhl2882 { - yyb2882 = yyj2882 > l - } else { - yyb2882 = r.CheckBreak() - } - if yyb2882 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2882++ - if yyhl2882 { - yyb2882 = yyj2882 > l - } else { - yyb2882 = r.CheckBreak() - } - if yyb2882 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv2885 := &x.ObjectMeta - yyv2885.CodecDecodeSelf(d) - } - yyj2882++ - if yyhl2882 { - yyb2882 = yyj2882 > l - } else { - yyb2882 = r.CheckBreak() - } - if yyb2882 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Subsets = nil - } else { - yyv2886 := &x.Subsets - yym2887 := z.DecBinary() - _ = yym2887 - if false { - } else { - h.decSliceEndpointSubset((*[]EndpointSubset)(yyv2886), d) - } - } - for { - yyj2882++ - if yyhl2882 { - yyb2882 = yyj2882 > l - } else { - yyb2882 = r.CheckBreak() - } - if yyb2882 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2882-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 { - yym2888 := z.EncBinary() - _ = yym2888 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2889 := !z.EncBinary() - yy2arr2889 := z.EncBasicHandle().StructToArray - var yyq2889 [3]bool - _, _, _ = yysep2889, yyq2889, yy2arr2889 - const yyr2889 bool = false - var yynn2889 int - if yyr2889 || yy2arr2889 { - r.EncodeArrayStart(3) - } else { - yynn2889 = 3 - for _, b := range yyq2889 { - if b { - yynn2889++ - } - } - r.EncodeMapStart(yynn2889) - yynn2889 = 0 - } - if yyr2889 || yy2arr2889 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Addresses == nil { - r.EncodeNil() - } else { - yym2891 := z.EncBinary() - _ = yym2891 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Addresses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Addresses == nil { - r.EncodeNil() - } else { - yym2892 := z.EncBinary() - _ = yym2892 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e) - } - } - } - if yyr2889 || yy2arr2889 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.NotReadyAddresses == nil { - r.EncodeNil() - } else { - yym2894 := z.EncBinary() - _ = yym2894 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("NotReadyAddresses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NotReadyAddresses == nil { - r.EncodeNil() - } else { - yym2895 := z.EncBinary() - _ = yym2895 - if false { - } else { - h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e) - } - } - } - if yyr2889 || yy2arr2889 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym2897 := z.EncBinary() - _ = yym2897 - if false { - } else { - h.encSliceEndpointPort(([]EndpointPort)(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 { - yym2898 := z.EncBinary() - _ = yym2898 - if false { - } else { - h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e) - } - } - } - if yyr2889 || yy2arr2889 { - 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 - yym2899 := z.DecBinary() - _ = yym2899 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2900 := r.ContainerType() - if yyct2900 == codecSelferValueTypeMap1234 { - yyl2900 := r.ReadMapStart() - if yyl2900 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2900, d) - } - } else if yyct2900 == codecSelferValueTypeArray1234 { - yyl2900 := r.ReadArrayStart() - if yyl2900 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2900, 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 yys2901Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2901Slc - var yyhl2901 bool = l >= 0 - for yyj2901 := 0; ; yyj2901++ { - if yyhl2901 { - if yyj2901 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2901Slc = r.DecodeBytes(yys2901Slc, true, true) - yys2901 := string(yys2901Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2901 { - case "Addresses": - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv2902 := &x.Addresses - yym2903 := z.DecBinary() - _ = yym2903 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2902), d) - } - } - case "NotReadyAddresses": - if r.TryDecodeAsNil() { - x.NotReadyAddresses = nil - } else { - yyv2904 := &x.NotReadyAddresses - yym2905 := z.DecBinary() - _ = yym2905 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2904), d) - } - } - case "Ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2906 := &x.Ports - yym2907 := z.DecBinary() - _ = yym2907 - if false { - } else { - h.decSliceEndpointPort((*[]EndpointPort)(yyv2906), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2901) - } // end switch yys2901 - } // end for yyj2901 - 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 yyj2908 int - var yyb2908 bool - var yyhl2908 bool = l >= 0 - yyj2908++ - if yyhl2908 { - yyb2908 = yyj2908 > l - } else { - yyb2908 = r.CheckBreak() - } - if yyb2908 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv2909 := &x.Addresses - yym2910 := z.DecBinary() - _ = yym2910 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2909), d) - } - } - yyj2908++ - if yyhl2908 { - yyb2908 = yyj2908 > l - } else { - yyb2908 = r.CheckBreak() - } - if yyb2908 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NotReadyAddresses = nil - } else { - yyv2911 := &x.NotReadyAddresses - yym2912 := z.DecBinary() - _ = yym2912 - if false { - } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2911), d) - } - } - yyj2908++ - if yyhl2908 { - yyb2908 = yyj2908 > l - } else { - yyb2908 = r.CheckBreak() - } - if yyb2908 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv2913 := &x.Ports - yym2914 := z.DecBinary() - _ = yym2914 - if false { - } else { - h.decSliceEndpointPort((*[]EndpointPort)(yyv2913), d) - } - } - for { - yyj2908++ - if yyhl2908 { - yyb2908 = yyj2908 > l - } else { - yyb2908 = r.CheckBreak() - } - if yyb2908 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2908-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 { - yym2915 := z.EncBinary() - _ = yym2915 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2916 := !z.EncBinary() - yy2arr2916 := z.EncBasicHandle().StructToArray - var yyq2916 [4]bool - _, _, _ = yysep2916, yyq2916, yy2arr2916 - const yyr2916 bool = false - yyq2916[1] = x.Hostname != "" - yyq2916[2] = x.NodeName != nil - var yynn2916 int - if yyr2916 || yy2arr2916 { - r.EncodeArrayStart(4) - } else { - yynn2916 = 2 - for _, b := range yyq2916 { - if b { - yynn2916++ - } - } - r.EncodeMapStart(yynn2916) - yynn2916 = 0 - } - if yyr2916 || yy2arr2916 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2918 := z.EncBinary() - _ = yym2918 - 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) - yym2919 := z.EncBinary() - _ = yym2919 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IP)) - } - } - if yyr2916 || yy2arr2916 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2916[1] { - yym2921 := z.EncBinary() - _ = yym2921 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2916[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostname")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2922 := z.EncBinary() - _ = yym2922 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) - } - } - } - if yyr2916 || yy2arr2916 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2916[2] { - if x.NodeName == nil { - r.EncodeNil() - } else { - yy2924 := *x.NodeName - yym2925 := z.EncBinary() - _ = yym2925 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy2924)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2916[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NodeName == nil { - r.EncodeNil() - } else { - yy2926 := *x.NodeName - yym2927 := z.EncBinary() - _ = yym2927 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy2926)) - } - } - } - } - if yyr2916 || yy2arr2916 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.TargetRef == nil { - r.EncodeNil() - } else { - x.TargetRef.CodecEncodeSelf(e) - } - } else { - 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 yyr2916 || yy2arr2916 { - 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 - yym2929 := z.DecBinary() - _ = yym2929 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2930 := r.ContainerType() - if yyct2930 == codecSelferValueTypeMap1234 { - yyl2930 := r.ReadMapStart() - if yyl2930 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2930, d) - } - } else if yyct2930 == codecSelferValueTypeArray1234 { - yyl2930 := r.ReadArrayStart() - if yyl2930 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2930, 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 yys2931Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2931Slc - var yyhl2931 bool = l >= 0 - for yyj2931 := 0; ; yyj2931++ { - if yyhl2931 { - if yyj2931 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2931Slc = r.DecodeBytes(yys2931Slc, true, true) - yys2931 := string(yys2931Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2931 { - 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) - } - yym2935 := z.DecBinary() - _ = yym2935 - 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, yys2931) - } // end switch yys2931 - } // end for yyj2931 - 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 yyj2937 int - var yyb2937 bool - var yyhl2937 bool = l >= 0 - yyj2937++ - if yyhl2937 { - yyb2937 = yyj2937 > l - } else { - yyb2937 = r.CheckBreak() - } - if yyb2937 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.IP = "" - } else { - x.IP = string(r.DecodeString()) - } - yyj2937++ - if yyhl2937 { - yyb2937 = yyj2937 > l - } else { - yyb2937 = r.CheckBreak() - } - if yyb2937 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hostname = "" - } else { - x.Hostname = string(r.DecodeString()) - } - yyj2937++ - if yyhl2937 { - yyb2937 = yyj2937 > l - } else { - yyb2937 = r.CheckBreak() - } - if yyb2937 { - 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) - } - yym2941 := z.DecBinary() - _ = yym2941 - if false { - } else { - *((*string)(x.NodeName)) = r.DecodeString() - } - } - yyj2937++ - if yyhl2937 { - yyb2937 = yyj2937 > l - } else { - yyb2937 = r.CheckBreak() - } - if yyb2937 { - 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 { - yyj2937++ - if yyhl2937 { - yyb2937 = yyj2937 > l - } else { - yyb2937 = r.CheckBreak() - } - if yyb2937 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2937-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 { - yym2943 := z.EncBinary() - _ = yym2943 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2944 := !z.EncBinary() - yy2arr2944 := z.EncBasicHandle().StructToArray - var yyq2944 [3]bool - _, _, _ = yysep2944, yyq2944, yy2arr2944 - const yyr2944 bool = false - var yynn2944 int - if yyr2944 || yy2arr2944 { - r.EncodeArrayStart(3) - } else { - yynn2944 = 3 - for _, b := range yyq2944 { - if b { - yynn2944++ - } - } - r.EncodeMapStart(yynn2944) - yynn2944 = 0 - } - if yyr2944 || yy2arr2944 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2946 := z.EncBinary() - _ = yym2946 - 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) - yym2947 := z.EncBinary() - _ = yym2947 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr2944 || yy2arr2944 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2949 := z.EncBinary() - _ = yym2949 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2950 := z.EncBinary() - _ = yym2950 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } - if yyr2944 || yy2arr2944 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - x.Protocol.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) - } - if yyr2944 || yy2arr2944 { - 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 - yym2952 := z.DecBinary() - _ = yym2952 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2953 := r.ContainerType() - if yyct2953 == codecSelferValueTypeMap1234 { - yyl2953 := r.ReadMapStart() - if yyl2953 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2953, d) - } - } else if yyct2953 == codecSelferValueTypeArray1234 { - yyl2953 := r.ReadArrayStart() - if yyl2953 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2953, 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 yys2954Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2954Slc - var yyhl2954 bool = l >= 0 - for yyj2954 := 0; ; yyj2954++ { - if yyhl2954 { - if yyj2954 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2954Slc = r.DecodeBytes(yys2954Slc, true, true) - yys2954 := string(yys2954Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2954 { - 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, yys2954) - } // end switch yys2954 - } // end for yyj2954 - 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 yyj2958 int - var yyb2958 bool - var yyhl2958 bool = l >= 0 - yyj2958++ - if yyhl2958 { - yyb2958 = yyj2958 > l - } else { - yyb2958 = r.CheckBreak() - } - if yyb2958 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj2958++ - if yyhl2958 { - yyb2958 = yyj2958 > l - } else { - yyb2958 = r.CheckBreak() - } - if yyb2958 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - yyj2958++ - if yyhl2958 { - yyb2958 = yyj2958 > l - } else { - yyb2958 = r.CheckBreak() - } - if yyb2958 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Protocol = "" - } else { - x.Protocol = Protocol(r.DecodeString()) - } - for { - yyj2958++ - if yyhl2958 { - yyb2958 = yyj2958 > l - } else { - yyb2958 = r.CheckBreak() - } - if yyb2958 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2958-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 { - yym2962 := z.EncBinary() - _ = yym2962 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2963 := !z.EncBinary() - yy2arr2963 := z.EncBasicHandle().StructToArray - var yyq2963 [4]bool - _, _, _ = yysep2963, yyq2963, yy2arr2963 - const yyr2963 bool = false - yyq2963[0] = x.Kind != "" - yyq2963[1] = x.APIVersion != "" - yyq2963[2] = true - var yynn2963 int - if yyr2963 || yy2arr2963 { - r.EncodeArrayStart(4) - } else { - yynn2963 = 1 - for _, b := range yyq2963 { - if b { - yynn2963++ - } - } - r.EncodeMapStart(yynn2963) - yynn2963 = 0 - } - if yyr2963 || yy2arr2963 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2963[0] { - yym2965 := z.EncBinary() - _ = yym2965 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2963[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2966 := z.EncBinary() - _ = yym2966 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2963 || yy2arr2963 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2963[1] { - yym2968 := z.EncBinary() - _ = yym2968 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2963[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2969 := z.EncBinary() - _ = yym2969 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2963 || yy2arr2963 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2963[2] { - yy2971 := &x.ListMeta - yym2972 := z.EncBinary() - _ = yym2972 - if false { - } else if z.HasExtensions() && z.EncExt(yy2971) { - } else { - z.EncFallback(yy2971) - } - } else { - r.EncodeNil() - } - } else { - if yyq2963[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2973 := &x.ListMeta - yym2974 := z.EncBinary() - _ = yym2974 - if false { - } else if z.HasExtensions() && z.EncExt(yy2973) { - } else { - z.EncFallback(yy2973) - } - } - } - if yyr2963 || yy2arr2963 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym2976 := z.EncBinary() - _ = yym2976 - 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 { - yym2977 := z.EncBinary() - _ = yym2977 - if false { - } else { - h.encSliceEndpoints(([]Endpoints)(x.Items), e) - } - } - } - if yyr2963 || yy2arr2963 { - 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 - yym2978 := z.DecBinary() - _ = yym2978 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct2979 := r.ContainerType() - if yyct2979 == codecSelferValueTypeMap1234 { - yyl2979 := r.ReadMapStart() - if yyl2979 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl2979, d) - } - } else if yyct2979 == codecSelferValueTypeArray1234 { - yyl2979 := r.ReadArrayStart() - if yyl2979 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl2979, 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 yys2980Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2980Slc - var yyhl2980 bool = l >= 0 - for yyj2980 := 0; ; yyj2980++ { - if yyhl2980 { - if yyj2980 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2980Slc = r.DecodeBytes(yys2980Slc, true, true) - yys2980 := string(yys2980Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2980 { - 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 { - yyv2983 := &x.ListMeta - yym2984 := z.DecBinary() - _ = yym2984 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2983) { - } else { - z.DecFallback(yyv2983, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2985 := &x.Items - yym2986 := z.DecBinary() - _ = yym2986 - if false { - } else { - h.decSliceEndpoints((*[]Endpoints)(yyv2985), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys2980) - } // end switch yys2980 - } // end for yyj2980 - 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 yyj2987 int - var yyb2987 bool - var yyhl2987 bool = l >= 0 - yyj2987++ - if yyhl2987 { - yyb2987 = yyj2987 > l - } else { - yyb2987 = r.CheckBreak() - } - if yyb2987 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj2987++ - if yyhl2987 { - yyb2987 = yyj2987 > l - } else { - yyb2987 = r.CheckBreak() - } - if yyb2987 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj2987++ - if yyhl2987 { - yyb2987 = yyj2987 > l - } else { - yyb2987 = r.CheckBreak() - } - if yyb2987 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv2990 := &x.ListMeta - yym2991 := z.DecBinary() - _ = yym2991 - if false { - } else if z.HasExtensions() && z.DecExt(yyv2990) { - } else { - z.DecFallback(yyv2990, false) - } - } - yyj2987++ - if yyhl2987 { - yyb2987 = yyj2987 > l - } else { - yyb2987 = r.CheckBreak() - } - if yyb2987 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv2992 := &x.Items - yym2993 := z.DecBinary() - _ = yym2993 - if false { - } else { - h.decSliceEndpoints((*[]Endpoints)(yyv2992), d) - } - } - for { - yyj2987++ - if yyhl2987 { - yyb2987 = yyj2987 > l - } else { - yyb2987 = r.CheckBreak() - } - if yyb2987 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2987-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 { - yym2994 := z.EncBinary() - _ = yym2994 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2995 := !z.EncBinary() - yy2arr2995 := z.EncBasicHandle().StructToArray - var yyq2995 [4]bool - _, _, _ = yysep2995, yyq2995, yy2arr2995 - const yyr2995 bool = false - yyq2995[0] = x.PodCIDR != "" - yyq2995[1] = x.ExternalID != "" - yyq2995[2] = x.ProviderID != "" - yyq2995[3] = x.Unschedulable != false - var yynn2995 int - if yyr2995 || yy2arr2995 { - r.EncodeArrayStart(4) - } else { - yynn2995 = 0 - for _, b := range yyq2995 { - if b { - yynn2995++ - } - } - r.EncodeMapStart(yynn2995) - yynn2995 = 0 - } - if yyr2995 || yy2arr2995 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2995[0] { - yym2997 := z.EncBinary() - _ = yym2997 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2995[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podCIDR")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2998 := z.EncBinary() - _ = yym2998 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR)) - } - } - } - if yyr2995 || yy2arr2995 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2995[1] { - yym3000 := z.EncBinary() - _ = yym3000 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2995[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("externalID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3001 := z.EncBinary() - _ = yym3001 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID)) - } - } - } - if yyr2995 || yy2arr2995 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2995[2] { - yym3003 := z.EncBinary() - _ = yym3003 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2995[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("providerID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3004 := z.EncBinary() - _ = yym3004 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID)) - } - } - } - if yyr2995 || yy2arr2995 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2995[3] { - yym3006 := z.EncBinary() - _ = yym3006 - if false { - } else { - r.EncodeBool(bool(x.Unschedulable)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq2995[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("unschedulable")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3007 := z.EncBinary() - _ = yym3007 - if false { - } else { - r.EncodeBool(bool(x.Unschedulable)) - } - } - } - if yyr2995 || yy2arr2995 { - 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 - yym3008 := z.DecBinary() - _ = yym3008 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3009 := r.ContainerType() - if yyct3009 == codecSelferValueTypeMap1234 { - yyl3009 := r.ReadMapStart() - if yyl3009 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3009, d) - } - } else if yyct3009 == codecSelferValueTypeArray1234 { - yyl3009 := r.ReadArrayStart() - if yyl3009 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3009, 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 yys3010Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3010Slc - var yyhl3010 bool = l >= 0 - for yyj3010 := 0; ; yyj3010++ { - if yyhl3010 { - if yyj3010 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3010Slc = r.DecodeBytes(yys3010Slc, true, true) - yys3010 := string(yys3010Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3010 { - 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, yys3010) - } // end switch yys3010 - } // end for yyj3010 - 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 yyj3015 int - var yyb3015 bool - var yyhl3015 bool = l >= 0 - yyj3015++ - if yyhl3015 { - yyb3015 = yyj3015 > l - } else { - yyb3015 = r.CheckBreak() - } - if yyb3015 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodCIDR = "" - } else { - x.PodCIDR = string(r.DecodeString()) - } - yyj3015++ - if yyhl3015 { - yyb3015 = yyj3015 > l - } else { - yyb3015 = r.CheckBreak() - } - if yyb3015 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExternalID = "" - } else { - x.ExternalID = string(r.DecodeString()) - } - yyj3015++ - if yyhl3015 { - yyb3015 = yyj3015 > l - } else { - yyb3015 = r.CheckBreak() - } - if yyb3015 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ProviderID = "" - } else { - x.ProviderID = string(r.DecodeString()) - } - yyj3015++ - if yyhl3015 { - yyb3015 = yyj3015 > l - } else { - yyb3015 = r.CheckBreak() - } - if yyb3015 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Unschedulable = false - } else { - x.Unschedulable = bool(r.DecodeBool()) - } - for { - yyj3015++ - if yyhl3015 { - yyb3015 = yyj3015 > l - } else { - yyb3015 = r.CheckBreak() - } - if yyb3015 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3015-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 { - yym3020 := z.EncBinary() - _ = yym3020 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3021 := !z.EncBinary() - yy2arr3021 := z.EncBasicHandle().StructToArray - var yyq3021 [1]bool - _, _, _ = yysep3021, yyq3021, yy2arr3021 - const yyr3021 bool = false - var yynn3021 int - if yyr3021 || yy2arr3021 { - r.EncodeArrayStart(1) - } else { - yynn3021 = 1 - for _, b := range yyq3021 { - if b { - yynn3021++ - } - } - r.EncodeMapStart(yynn3021) - yynn3021 = 0 - } - if yyr3021 || yy2arr3021 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3023 := z.EncBinary() - _ = yym3023 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3024 := z.EncBinary() - _ = yym3024 - if false { - } else { - r.EncodeInt(int64(x.Port)) - } - } - if yyr3021 || yy2arr3021 { - 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 - yym3025 := z.DecBinary() - _ = yym3025 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3026 := r.ContainerType() - if yyct3026 == codecSelferValueTypeMap1234 { - yyl3026 := r.ReadMapStart() - if yyl3026 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3026, d) - } - } else if yyct3026 == codecSelferValueTypeArray1234 { - yyl3026 := r.ReadArrayStart() - if yyl3026 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3026, 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 yys3027Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3027Slc - var yyhl3027 bool = l >= 0 - for yyj3027 := 0; ; yyj3027++ { - if yyhl3027 { - if yyj3027 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3027Slc = r.DecodeBytes(yys3027Slc, true, true) - yys3027 := string(yys3027Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3027 { - case "Port": - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys3027) - } // end switch yys3027 - } // end for yyj3027 - 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 yyj3029 int - var yyb3029 bool - var yyhl3029 bool = l >= 0 - yyj3029++ - if yyhl3029 { - yyb3029 = yyj3029 > l - } else { - yyb3029 = r.CheckBreak() - } - if yyb3029 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Port = 0 - } else { - x.Port = int32(r.DecodeInt(32)) - } - for { - yyj3029++ - if yyhl3029 { - yyb3029 = yyj3029 > l - } else { - yyb3029 = r.CheckBreak() - } - if yyb3029 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3029-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 { - yym3031 := z.EncBinary() - _ = yym3031 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3032 := !z.EncBinary() - yy2arr3032 := z.EncBasicHandle().StructToArray - var yyq3032 [1]bool - _, _, _ = yysep3032, yyq3032, yy2arr3032 - const yyr3032 bool = false - yyq3032[0] = true - var yynn3032 int - if yyr3032 || yy2arr3032 { - r.EncodeArrayStart(1) - } else { - yynn3032 = 0 - for _, b := range yyq3032 { - if b { - yynn3032++ - } - } - r.EncodeMapStart(yynn3032) - yynn3032 = 0 - } - if yyr3032 || yy2arr3032 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3032[0] { - yy3034 := &x.KubeletEndpoint - yy3034.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3032[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kubeletEndpoint")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3035 := &x.KubeletEndpoint - yy3035.CodecEncodeSelf(e) - } - } - if yyr3032 || yy2arr3032 { - 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 - yym3036 := z.DecBinary() - _ = yym3036 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3037 := r.ContainerType() - if yyct3037 == codecSelferValueTypeMap1234 { - yyl3037 := r.ReadMapStart() - if yyl3037 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3037, d) - } - } else if yyct3037 == codecSelferValueTypeArray1234 { - yyl3037 := r.ReadArrayStart() - if yyl3037 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3037, 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 yys3038Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3038Slc - var yyhl3038 bool = l >= 0 - for yyj3038 := 0; ; yyj3038++ { - if yyhl3038 { - if yyj3038 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3038Slc = r.DecodeBytes(yys3038Slc, true, true) - yys3038 := string(yys3038Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3038 { - case "kubeletEndpoint": - if r.TryDecodeAsNil() { - x.KubeletEndpoint = DaemonEndpoint{} - } else { - yyv3039 := &x.KubeletEndpoint - yyv3039.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3038) - } // end switch yys3038 - } // end for yyj3038 - 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 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.KubeletEndpoint = DaemonEndpoint{} - } else { - yyv3041 := &x.KubeletEndpoint - yyv3041.CodecDecodeSelf(d) - } - 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 *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3042 := z.EncBinary() - _ = yym3042 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3043 := !z.EncBinary() - yy2arr3043 := z.EncBasicHandle().StructToArray - var yyq3043 [10]bool - _, _, _ = yysep3043, yyq3043, yy2arr3043 - const yyr3043 bool = false - var yynn3043 int - if yyr3043 || yy2arr3043 { - r.EncodeArrayStart(10) - } else { - yynn3043 = 10 - for _, b := range yyq3043 { - if b { - yynn3043++ - } - } - r.EncodeMapStart(yynn3043) - yynn3043 = 0 - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3045 := z.EncBinary() - _ = yym3045 - 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) - yym3046 := z.EncBinary() - _ = yym3046 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.MachineID)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3048 := z.EncBinary() - _ = yym3048 - 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) - yym3049 := z.EncBinary() - _ = yym3049 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SystemUUID)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3051 := z.EncBinary() - _ = yym3051 - 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) - yym3052 := z.EncBinary() - _ = yym3052 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.BootID)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3054 := z.EncBinary() - _ = yym3054 - 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) - yym3055 := z.EncBinary() - _ = yym3055 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.KernelVersion)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3057 := z.EncBinary() - _ = yym3057 - 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) - yym3058 := z.EncBinary() - _ = yym3058 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.OSImage)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3060 := z.EncBinary() - _ = yym3060 - 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) - yym3061 := z.EncBinary() - _ = yym3061 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerRuntimeVersion)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3063 := z.EncBinary() - _ = yym3063 - 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) - yym3064 := z.EncBinary() - _ = yym3064 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.KubeletVersion)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3066 := z.EncBinary() - _ = yym3066 - 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) - yym3067 := z.EncBinary() - _ = yym3067 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.KubeProxyVersion)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3069 := z.EncBinary() - _ = yym3069 - 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) - yym3070 := z.EncBinary() - _ = yym3070 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.OperatingSystem)) - } - } - if yyr3043 || yy2arr3043 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3072 := z.EncBinary() - _ = yym3072 - 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) - yym3073 := z.EncBinary() - _ = yym3073 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Architecture)) - } - } - if yyr3043 || yy2arr3043 { - 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 - yym3074 := z.DecBinary() - _ = yym3074 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3075 := r.ContainerType() - if yyct3075 == codecSelferValueTypeMap1234 { - yyl3075 := r.ReadMapStart() - if yyl3075 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3075, d) - } - } else if yyct3075 == codecSelferValueTypeArray1234 { - yyl3075 := r.ReadArrayStart() - if yyl3075 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3075, 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 yys3076Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3076Slc - var yyhl3076 bool = l >= 0 - for yyj3076 := 0; ; yyj3076++ { - if yyhl3076 { - if yyj3076 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3076Slc = r.DecodeBytes(yys3076Slc, true, true) - yys3076 := string(yys3076Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3076 { - 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, yys3076) - } // end switch yys3076 - } // end for yyj3076 - 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 yyj3087 int - var yyb3087 bool - var yyhl3087 bool = l >= 0 - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MachineID = "" - } else { - x.MachineID = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SystemUUID = "" - } else { - x.SystemUUID = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.BootID = "" - } else { - x.BootID = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KernelVersion = "" - } else { - x.KernelVersion = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OSImage = "" - } else { - x.OSImage = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ContainerRuntimeVersion = "" - } else { - x.ContainerRuntimeVersion = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KubeletVersion = "" - } else { - x.KubeletVersion = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.KubeProxyVersion = "" - } else { - x.KubeProxyVersion = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OperatingSystem = "" - } else { - x.OperatingSystem = string(r.DecodeString()) - } - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Architecture = "" - } else { - x.Architecture = string(r.DecodeString()) - } - for { - yyj3087++ - if yyhl3087 { - yyb3087 = yyj3087 > l - } else { - yyb3087 = r.CheckBreak() - } - if yyb3087 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3087-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 { - yym3098 := z.EncBinary() - _ = yym3098 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3099 := !z.EncBinary() - yy2arr3099 := z.EncBasicHandle().StructToArray - var yyq3099 [10]bool - _, _, _ = yysep3099, yyq3099, yy2arr3099 - const yyr3099 bool = false - yyq3099[0] = len(x.Capacity) != 0 - yyq3099[1] = len(x.Allocatable) != 0 - yyq3099[2] = x.Phase != "" - yyq3099[3] = len(x.Conditions) != 0 - yyq3099[4] = len(x.Addresses) != 0 - yyq3099[5] = true - yyq3099[6] = true - yyq3099[7] = len(x.Images) != 0 - yyq3099[8] = len(x.VolumesInUse) != 0 - yyq3099[9] = len(x.VolumesAttached) != 0 - var yynn3099 int - if yyr3099 || yy2arr3099 { - r.EncodeArrayStart(10) - } else { - yynn3099 = 0 - for _, b := range yyq3099 { - if b { - yynn3099++ - } - } - r.EncodeMapStart(yynn3099) - yynn3099 = 0 - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[0] { - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[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 yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[1] { - if x.Allocatable == nil { - r.EncodeNil() - } else { - x.Allocatable.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[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 yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[2] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3099[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[3] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym3104 := z.EncBinary() - _ = yym3104 - if false { - } else { - h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym3105 := z.EncBinary() - _ = yym3105 - if false { - } else { - h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e) - } - } - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[4] { - if x.Addresses == nil { - r.EncodeNil() - } else { - yym3107 := z.EncBinary() - _ = yym3107 - if false { - } else { - h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("addresses")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Addresses == nil { - r.EncodeNil() - } else { - yym3108 := z.EncBinary() - _ = yym3108 - if false { - } else { - h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e) - } - } - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[5] { - yy3110 := &x.DaemonEndpoints - yy3110.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3099[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("daemonEndpoints")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3111 := &x.DaemonEndpoints - yy3111.CodecEncodeSelf(e) - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[6] { - yy3113 := &x.NodeInfo - yy3113.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3099[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("nodeInfo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3114 := &x.NodeInfo - yy3114.CodecEncodeSelf(e) - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[7] { - if x.Images == nil { - r.EncodeNil() - } else { - yym3116 := z.EncBinary() - _ = yym3116 - if false { - } else { - h.encSliceContainerImage(([]ContainerImage)(x.Images), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("images")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Images == nil { - r.EncodeNil() - } else { - yym3117 := z.EncBinary() - _ = yym3117 - if false { - } else { - h.encSliceContainerImage(([]ContainerImage)(x.Images), e) - } - } - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[8] { - if x.VolumesInUse == nil { - r.EncodeNil() - } else { - yym3119 := z.EncBinary() - _ = yym3119 - if false { - } else { - h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumesInUse")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumesInUse == nil { - r.EncodeNil() - } else { - yym3120 := z.EncBinary() - _ = yym3120 - if false { - } else { - h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e) - } - } - } - } - if yyr3099 || yy2arr3099 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3099[9] { - if x.VolumesAttached == nil { - r.EncodeNil() - } else { - yym3122 := z.EncBinary() - _ = yym3122 - if false { - } else { - h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3099[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumesAttached")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumesAttached == nil { - r.EncodeNil() - } else { - yym3123 := z.EncBinary() - _ = yym3123 - if false { - } else { - h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e) - } - } - } - } - if yyr3099 || yy2arr3099 { - 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 - yym3124 := z.DecBinary() - _ = yym3124 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3125 := r.ContainerType() - if yyct3125 == codecSelferValueTypeMap1234 { - yyl3125 := r.ReadMapStart() - if yyl3125 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3125, d) - } - } else if yyct3125 == codecSelferValueTypeArray1234 { - yyl3125 := r.ReadArrayStart() - if yyl3125 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3125, 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 yys3126Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3126Slc - var yyhl3126 bool = l >= 0 - for yyj3126 := 0; ; yyj3126++ { - if yyhl3126 { - if yyj3126 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3126Slc = r.DecodeBytes(yys3126Slc, true, true) - yys3126 := string(yys3126Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3126 { - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv3127 := &x.Capacity - yyv3127.CodecDecodeSelf(d) - } - case "allocatable": - if r.TryDecodeAsNil() { - x.Allocatable = nil - } else { - yyv3128 := &x.Allocatable - yyv3128.CodecDecodeSelf(d) - } - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NodePhase(r.DecodeString()) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv3130 := &x.Conditions - yym3131 := z.DecBinary() - _ = yym3131 - if false { - } else { - h.decSliceNodeCondition((*[]NodeCondition)(yyv3130), d) - } - } - case "addresses": - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv3132 := &x.Addresses - yym3133 := z.DecBinary() - _ = yym3133 - if false { - } else { - h.decSliceNodeAddress((*[]NodeAddress)(yyv3132), d) - } - } - case "daemonEndpoints": - if r.TryDecodeAsNil() { - x.DaemonEndpoints = NodeDaemonEndpoints{} - } else { - yyv3134 := &x.DaemonEndpoints - yyv3134.CodecDecodeSelf(d) - } - case "nodeInfo": - if r.TryDecodeAsNil() { - x.NodeInfo = NodeSystemInfo{} - } else { - yyv3135 := &x.NodeInfo - yyv3135.CodecDecodeSelf(d) - } - case "images": - if r.TryDecodeAsNil() { - x.Images = nil - } else { - yyv3136 := &x.Images - yym3137 := z.DecBinary() - _ = yym3137 - if false { - } else { - h.decSliceContainerImage((*[]ContainerImage)(yyv3136), d) - } - } - case "volumesInUse": - if r.TryDecodeAsNil() { - x.VolumesInUse = nil - } else { - yyv3138 := &x.VolumesInUse - yym3139 := z.DecBinary() - _ = yym3139 - if false { - } else { - h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv3138), d) - } - } - case "volumesAttached": - if r.TryDecodeAsNil() { - x.VolumesAttached = nil - } else { - yyv3140 := &x.VolumesAttached - yym3141 := z.DecBinary() - _ = yym3141 - if false { - } else { - h.decSliceAttachedVolume((*[]AttachedVolume)(yyv3140), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3126) - } // end switch yys3126 - } // end for yyj3126 - 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 yyj3142 int - var yyb3142 bool - var yyhl3142 bool = l >= 0 - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv3143 := &x.Capacity - yyv3143.CodecDecodeSelf(d) - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Allocatable = nil - } else { - yyv3144 := &x.Allocatable - yyv3144.CodecDecodeSelf(d) - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NodePhase(r.DecodeString()) - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv3146 := &x.Conditions - yym3147 := z.DecBinary() - _ = yym3147 - if false { - } else { - h.decSliceNodeCondition((*[]NodeCondition)(yyv3146), d) - } - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Addresses = nil - } else { - yyv3148 := &x.Addresses - yym3149 := z.DecBinary() - _ = yym3149 - if false { - } else { - h.decSliceNodeAddress((*[]NodeAddress)(yyv3148), d) - } - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DaemonEndpoints = NodeDaemonEndpoints{} - } else { - yyv3150 := &x.DaemonEndpoints - yyv3150.CodecDecodeSelf(d) - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NodeInfo = NodeSystemInfo{} - } else { - yyv3151 := &x.NodeInfo - yyv3151.CodecDecodeSelf(d) - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Images = nil - } else { - yyv3152 := &x.Images - yym3153 := z.DecBinary() - _ = yym3153 - if false { - } else { - h.decSliceContainerImage((*[]ContainerImage)(yyv3152), d) - } - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumesInUse = nil - } else { - yyv3154 := &x.VolumesInUse - yym3155 := z.DecBinary() - _ = yym3155 - if false { - } else { - h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv3154), d) - } - } - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumesAttached = nil - } else { - yyv3156 := &x.VolumesAttached - yym3157 := z.DecBinary() - _ = yym3157 - if false { - } else { - h.decSliceAttachedVolume((*[]AttachedVolume)(yyv3156), d) - } - } - for { - yyj3142++ - if yyhl3142 { - yyb3142 = yyj3142 > l - } else { - yyb3142 = r.CheckBreak() - } - if yyb3142 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3142-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x UniqueVolumeName) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3158 := z.EncBinary() - _ = yym3158 - 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 - yym3159 := z.DecBinary() - _ = yym3159 - 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 { - yym3160 := z.EncBinary() - _ = yym3160 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3161 := !z.EncBinary() - yy2arr3161 := z.EncBasicHandle().StructToArray - var yyq3161 [2]bool - _, _, _ = yysep3161, yyq3161, yy2arr3161 - const yyr3161 bool = false - var yynn3161 int - if yyr3161 || yy2arr3161 { - r.EncodeArrayStart(2) - } else { - yynn3161 = 2 - for _, b := range yyq3161 { - if b { - yynn3161++ - } - } - r.EncodeMapStart(yynn3161) - yynn3161 = 0 - } - if yyr3161 || yy2arr3161 { - 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 yyr3161 || yy2arr3161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3164 := z.EncBinary() - _ = yym3164 - 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) - yym3165 := z.EncBinary() - _ = yym3165 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DevicePath)) - } - } - if yyr3161 || yy2arr3161 { - 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 - yym3166 := z.DecBinary() - _ = yym3166 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3167 := r.ContainerType() - if yyct3167 == codecSelferValueTypeMap1234 { - yyl3167 := r.ReadMapStart() - if yyl3167 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3167, d) - } - } else if yyct3167 == codecSelferValueTypeArray1234 { - yyl3167 := r.ReadArrayStart() - if yyl3167 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3167, 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 yys3168Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3168Slc - var yyhl3168 bool = l >= 0 - for yyj3168 := 0; ; yyj3168++ { - if yyhl3168 { - if yyj3168 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3168Slc = r.DecodeBytes(yys3168Slc, true, true) - yys3168 := string(yys3168Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3168 { - 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, yys3168) - } // end switch yys3168 - } // end for yyj3168 - 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 yyj3171 int - var yyb3171 bool - var yyhl3171 bool = l >= 0 - yyj3171++ - if yyhl3171 { - yyb3171 = yyj3171 > l - } else { - yyb3171 = r.CheckBreak() - } - if yyb3171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = UniqueVolumeName(r.DecodeString()) - } - yyj3171++ - if yyhl3171 { - yyb3171 = yyj3171 > l - } else { - yyb3171 = r.CheckBreak() - } - if yyb3171 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DevicePath = "" - } else { - x.DevicePath = string(r.DecodeString()) - } - for { - yyj3171++ - if yyhl3171 { - yyb3171 = yyj3171 > l - } else { - yyb3171 = r.CheckBreak() - } - if yyb3171 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3171-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 { - yym3174 := z.EncBinary() - _ = yym3174 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3175 := !z.EncBinary() - yy2arr3175 := z.EncBasicHandle().StructToArray - var yyq3175 [1]bool - _, _, _ = yysep3175, yyq3175, yy2arr3175 - const yyr3175 bool = false - yyq3175[0] = len(x.PreferAvoidPods) != 0 - var yynn3175 int - if yyr3175 || yy2arr3175 { - r.EncodeArrayStart(1) - } else { - yynn3175 = 0 - for _, b := range yyq3175 { - if b { - yynn3175++ - } - } - r.EncodeMapStart(yynn3175) - yynn3175 = 0 - } - if yyr3175 || yy2arr3175 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3175[0] { - if x.PreferAvoidPods == nil { - r.EncodeNil() - } else { - yym3177 := z.EncBinary() - _ = yym3177 - if false { - } else { - h.encSlicePreferAvoidPodsEntry(([]PreferAvoidPodsEntry)(x.PreferAvoidPods), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3175[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("preferAvoidPods")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PreferAvoidPods == nil { - r.EncodeNil() - } else { - yym3178 := z.EncBinary() - _ = yym3178 - if false { - } else { - h.encSlicePreferAvoidPodsEntry(([]PreferAvoidPodsEntry)(x.PreferAvoidPods), e) - } - } - } - } - if yyr3175 || yy2arr3175 { - 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 - yym3179 := z.DecBinary() - _ = yym3179 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3180 := r.ContainerType() - if yyct3180 == codecSelferValueTypeMap1234 { - yyl3180 := r.ReadMapStart() - if yyl3180 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3180, d) - } - } else if yyct3180 == codecSelferValueTypeArray1234 { - yyl3180 := r.ReadArrayStart() - if yyl3180 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3180, 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 yys3181Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3181Slc - var yyhl3181 bool = l >= 0 - for yyj3181 := 0; ; yyj3181++ { - if yyhl3181 { - if yyj3181 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3181Slc = r.DecodeBytes(yys3181Slc, true, true) - yys3181 := string(yys3181Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3181 { - case "preferAvoidPods": - if r.TryDecodeAsNil() { - x.PreferAvoidPods = nil - } else { - yyv3182 := &x.PreferAvoidPods - yym3183 := z.DecBinary() - _ = yym3183 - if false { - } else { - h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv3182), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3181) - } // end switch yys3181 - } // end for yyj3181 - 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 yyj3184 int - var yyb3184 bool - var yyhl3184 bool = l >= 0 - yyj3184++ - if yyhl3184 { - yyb3184 = yyj3184 > l - } else { - yyb3184 = r.CheckBreak() - } - if yyb3184 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PreferAvoidPods = nil - } else { - yyv3185 := &x.PreferAvoidPods - yym3186 := z.DecBinary() - _ = yym3186 - if false { - } else { - h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv3185), d) - } - } - for { - yyj3184++ - if yyhl3184 { - yyb3184 = yyj3184 > l - } else { - yyb3184 = r.CheckBreak() - } - if yyb3184 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3184-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 { - yym3187 := z.EncBinary() - _ = yym3187 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3188 := !z.EncBinary() - yy2arr3188 := z.EncBasicHandle().StructToArray - var yyq3188 [4]bool - _, _, _ = yysep3188, yyq3188, yy2arr3188 - const yyr3188 bool = false - yyq3188[1] = true - yyq3188[2] = x.Reason != "" - yyq3188[3] = x.Message != "" - var yynn3188 int - if yyr3188 || yy2arr3188 { - r.EncodeArrayStart(4) - } else { - yynn3188 = 1 - for _, b := range yyq3188 { - if b { - yynn3188++ - } - } - r.EncodeMapStart(yynn3188) - yynn3188 = 0 - } - if yyr3188 || yy2arr3188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3190 := &x.PodSignature - yy3190.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podSignature")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3191 := &x.PodSignature - yy3191.CodecEncodeSelf(e) - } - if yyr3188 || yy2arr3188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3188[1] { - yy3193 := &x.EvictionTime - yym3194 := z.EncBinary() - _ = yym3194 - if false { - } else if z.HasExtensions() && z.EncExt(yy3193) { - } else if yym3194 { - z.EncBinaryMarshal(yy3193) - } else if !yym3194 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3193) - } else { - z.EncFallback(yy3193) - } - } else { - r.EncodeNil() - } - } else { - if yyq3188[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("evictionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3195 := &x.EvictionTime - yym3196 := z.EncBinary() - _ = yym3196 - if false { - } else if z.HasExtensions() && z.EncExt(yy3195) { - } else if yym3196 { - z.EncBinaryMarshal(yy3195) - } else if !yym3196 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3195) - } else { - z.EncFallback(yy3195) - } - } - } - if yyr3188 || yy2arr3188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3188[2] { - yym3198 := z.EncBinary() - _ = yym3198 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3188[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3199 := z.EncBinary() - _ = yym3199 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr3188 || yy2arr3188 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3188[3] { - yym3201 := z.EncBinary() - _ = yym3201 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3188[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3202 := z.EncBinary() - _ = yym3202 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr3188 || yy2arr3188 { - 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 - yym3203 := z.DecBinary() - _ = yym3203 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3204 := r.ContainerType() - if yyct3204 == codecSelferValueTypeMap1234 { - yyl3204 := r.ReadMapStart() - if yyl3204 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3204, d) - } - } else if yyct3204 == codecSelferValueTypeArray1234 { - yyl3204 := r.ReadArrayStart() - if yyl3204 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3204, 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 yys3205Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3205Slc - var yyhl3205 bool = l >= 0 - for yyj3205 := 0; ; yyj3205++ { - if yyhl3205 { - if yyj3205 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3205Slc = r.DecodeBytes(yys3205Slc, true, true) - yys3205 := string(yys3205Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3205 { - case "podSignature": - if r.TryDecodeAsNil() { - x.PodSignature = PodSignature{} - } else { - yyv3206 := &x.PodSignature - yyv3206.CodecDecodeSelf(d) - } - case "evictionTime": - if r.TryDecodeAsNil() { - x.EvictionTime = pkg2_unversioned.Time{} - } else { - yyv3207 := &x.EvictionTime - yym3208 := z.DecBinary() - _ = yym3208 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3207) { - } else if yym3208 { - z.DecBinaryUnmarshal(yyv3207) - } else if !yym3208 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3207) - } else { - z.DecFallback(yyv3207, 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, yys3205) - } // end switch yys3205 - } // end for yyj3205 - 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 yyj3211 int - var yyb3211 bool - var yyhl3211 bool = l >= 0 - yyj3211++ - if yyhl3211 { - yyb3211 = yyj3211 > l - } else { - yyb3211 = r.CheckBreak() - } - if yyb3211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodSignature = PodSignature{} - } else { - yyv3212 := &x.PodSignature - yyv3212.CodecDecodeSelf(d) - } - yyj3211++ - if yyhl3211 { - yyb3211 = yyj3211 > l - } else { - yyb3211 = r.CheckBreak() - } - if yyb3211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.EvictionTime = pkg2_unversioned.Time{} - } else { - yyv3213 := &x.EvictionTime - yym3214 := z.DecBinary() - _ = yym3214 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3213) { - } else if yym3214 { - z.DecBinaryUnmarshal(yyv3213) - } else if !yym3214 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3213) - } else { - z.DecFallback(yyv3213, false) - } - } - yyj3211++ - if yyhl3211 { - yyb3211 = yyj3211 > l - } else { - yyb3211 = r.CheckBreak() - } - if yyb3211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj3211++ - if yyhl3211 { - yyb3211 = yyj3211 > l - } else { - yyb3211 = r.CheckBreak() - } - if yyb3211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj3211++ - if yyhl3211 { - yyb3211 = yyj3211 > l - } else { - yyb3211 = r.CheckBreak() - } - if yyb3211 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3211-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 { - yym3217 := z.EncBinary() - _ = yym3217 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3218 := !z.EncBinary() - yy2arr3218 := z.EncBasicHandle().StructToArray - var yyq3218 [1]bool - _, _, _ = yysep3218, yyq3218, yy2arr3218 - const yyr3218 bool = false - yyq3218[0] = x.PodController != nil - var yynn3218 int - if yyr3218 || yy2arr3218 { - r.EncodeArrayStart(1) - } else { - yynn3218 = 0 - for _, b := range yyq3218 { - if b { - yynn3218++ - } - } - r.EncodeMapStart(yynn3218) - yynn3218 = 0 - } - if yyr3218 || yy2arr3218 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3218[0] { - if x.PodController == nil { - r.EncodeNil() - } else { - x.PodController.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3218[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 yyr3218 || yy2arr3218 { - 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 - yym3220 := z.DecBinary() - _ = yym3220 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3221 := r.ContainerType() - if yyct3221 == codecSelferValueTypeMap1234 { - yyl3221 := r.ReadMapStart() - if yyl3221 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3221, d) - } - } else if yyct3221 == codecSelferValueTypeArray1234 { - yyl3221 := r.ReadArrayStart() - if yyl3221 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3221, 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 yys3222Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3222Slc - var yyhl3222 bool = l >= 0 - for yyj3222 := 0; ; yyj3222++ { - if yyhl3222 { - if yyj3222 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3222Slc = r.DecodeBytes(yys3222Slc, true, true) - yys3222 := string(yys3222Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3222 { - 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, yys3222) - } // end switch yys3222 - } // end for yyj3222 - 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 yyj3224 int - var yyb3224 bool - var yyhl3224 bool = l >= 0 - yyj3224++ - if yyhl3224 { - yyb3224 = yyj3224 > l - } else { - yyb3224 = r.CheckBreak() - } - if yyb3224 { - 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 { - yyj3224++ - if yyhl3224 { - yyb3224 = yyj3224 > l - } else { - yyb3224 = r.CheckBreak() - } - if yyb3224 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3224-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 { - yym3226 := z.EncBinary() - _ = yym3226 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3227 := !z.EncBinary() - yy2arr3227 := z.EncBasicHandle().StructToArray - var yyq3227 [2]bool - _, _, _ = yysep3227, yyq3227, yy2arr3227 - const yyr3227 bool = false - yyq3227[1] = x.SizeBytes != 0 - var yynn3227 int - if yyr3227 || yy2arr3227 { - r.EncodeArrayStart(2) - } else { - yynn3227 = 1 - for _, b := range yyq3227 { - if b { - yynn3227++ - } - } - r.EncodeMapStart(yynn3227) - yynn3227 = 0 - } - if yyr3227 || yy2arr3227 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Names == nil { - r.EncodeNil() - } else { - yym3229 := z.EncBinary() - _ = yym3229 - 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 { - yym3230 := z.EncBinary() - _ = yym3230 - if false { - } else { - z.F.EncSliceStringV(x.Names, false, e) - } - } - } - if yyr3227 || yy2arr3227 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3227[1] { - yym3232 := z.EncBinary() - _ = yym3232 - if false { - } else { - r.EncodeInt(int64(x.SizeBytes)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq3227[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("sizeBytes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3233 := z.EncBinary() - _ = yym3233 - if false { - } else { - r.EncodeInt(int64(x.SizeBytes)) - } - } - } - if yyr3227 || yy2arr3227 { - 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 - yym3234 := z.DecBinary() - _ = yym3234 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3235 := r.ContainerType() - if yyct3235 == codecSelferValueTypeMap1234 { - yyl3235 := r.ReadMapStart() - if yyl3235 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3235, d) - } - } else if yyct3235 == codecSelferValueTypeArray1234 { - yyl3235 := r.ReadArrayStart() - if yyl3235 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3235, 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 yys3236Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3236Slc - var yyhl3236 bool = l >= 0 - for yyj3236 := 0; ; yyj3236++ { - if yyhl3236 { - if yyj3236 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3236Slc = r.DecodeBytes(yys3236Slc, true, true) - yys3236 := string(yys3236Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3236 { - case "names": - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv3237 := &x.Names - yym3238 := z.DecBinary() - _ = yym3238 - if false { - } else { - z.F.DecSliceStringX(yyv3237, false, d) - } - } - case "sizeBytes": - if r.TryDecodeAsNil() { - x.SizeBytes = 0 - } else { - x.SizeBytes = int64(r.DecodeInt(64)) - } - default: - z.DecStructFieldNotFound(-1, yys3236) - } // end switch yys3236 - } // end for yyj3236 - 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 yyj3240 int - var yyb3240 bool - var yyhl3240 bool = l >= 0 - yyj3240++ - if yyhl3240 { - yyb3240 = yyj3240 > l - } else { - yyb3240 = r.CheckBreak() - } - if yyb3240 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Names = nil - } else { - yyv3241 := &x.Names - yym3242 := z.DecBinary() - _ = yym3242 - if false { - } else { - z.F.DecSliceStringX(yyv3241, false, d) - } - } - yyj3240++ - if yyhl3240 { - yyb3240 = yyj3240 > l - } else { - yyb3240 = r.CheckBreak() - } - if yyb3240 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SizeBytes = 0 - } else { - x.SizeBytes = int64(r.DecodeInt(64)) - } - for { - yyj3240++ - if yyhl3240 { - yyb3240 = yyj3240 > l - } else { - yyb3240 = r.CheckBreak() - } - if yyb3240 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3240-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NodePhase) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3244 := z.EncBinary() - _ = yym3244 - 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 - yym3245 := z.DecBinary() - _ = yym3245 - 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 - yym3246 := z.EncBinary() - _ = yym3246 - 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 - yym3247 := z.DecBinary() - _ = yym3247 - 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 { - yym3248 := z.EncBinary() - _ = yym3248 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3249 := !z.EncBinary() - yy2arr3249 := z.EncBasicHandle().StructToArray - var yyq3249 [6]bool - _, _, _ = yysep3249, yyq3249, yy2arr3249 - const yyr3249 bool = false - yyq3249[2] = true - yyq3249[3] = true - yyq3249[4] = x.Reason != "" - yyq3249[5] = x.Message != "" - var yynn3249 int - if yyr3249 || yy2arr3249 { - r.EncodeArrayStart(6) - } else { - yynn3249 = 2 - for _, b := range yyq3249 { - if b { - yynn3249++ - } - } - r.EncodeMapStart(yynn3249) - yynn3249 = 0 - } - if yyr3249 || yy2arr3249 { - 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 yyr3249 || yy2arr3249 { - 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 yyr3249 || yy2arr3249 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3249[2] { - yy3253 := &x.LastHeartbeatTime - yym3254 := z.EncBinary() - _ = yym3254 - if false { - } else if z.HasExtensions() && z.EncExt(yy3253) { - } else if yym3254 { - z.EncBinaryMarshal(yy3253) - } else if !yym3254 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3253) - } else { - z.EncFallback(yy3253) - } - } else { - r.EncodeNil() - } - } else { - if yyq3249[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastHeartbeatTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3255 := &x.LastHeartbeatTime - yym3256 := z.EncBinary() - _ = yym3256 - if false { - } else if z.HasExtensions() && z.EncExt(yy3255) { - } else if yym3256 { - z.EncBinaryMarshal(yy3255) - } else if !yym3256 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3255) - } else { - z.EncFallback(yy3255) - } - } - } - if yyr3249 || yy2arr3249 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3249[3] { - yy3258 := &x.LastTransitionTime - yym3259 := z.EncBinary() - _ = yym3259 - if false { - } else if z.HasExtensions() && z.EncExt(yy3258) { - } else if yym3259 { - z.EncBinaryMarshal(yy3258) - } else if !yym3259 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3258) - } else { - z.EncFallback(yy3258) - } - } else { - r.EncodeNil() - } - } else { - if yyq3249[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3260 := &x.LastTransitionTime - yym3261 := z.EncBinary() - _ = yym3261 - if false { - } else if z.HasExtensions() && z.EncExt(yy3260) { - } else if yym3261 { - z.EncBinaryMarshal(yy3260) - } else if !yym3261 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3260) - } else { - z.EncFallback(yy3260) - } - } - } - if yyr3249 || yy2arr3249 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3249[4] { - yym3263 := z.EncBinary() - _ = yym3263 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3249[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3264 := z.EncBinary() - _ = yym3264 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr3249 || yy2arr3249 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3249[5] { - yym3266 := z.EncBinary() - _ = yym3266 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3249[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3267 := z.EncBinary() - _ = yym3267 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr3249 || yy2arr3249 { - 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 - yym3268 := z.DecBinary() - _ = yym3268 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3269 := r.ContainerType() - if yyct3269 == codecSelferValueTypeMap1234 { - yyl3269 := r.ReadMapStart() - if yyl3269 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3269, d) - } - } else if yyct3269 == codecSelferValueTypeArray1234 { - yyl3269 := r.ReadArrayStart() - if yyl3269 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3269, 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 yys3270Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3270Slc - var yyhl3270 bool = l >= 0 - for yyj3270 := 0; ; yyj3270++ { - if yyhl3270 { - if yyj3270 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3270Slc = r.DecodeBytes(yys3270Slc, true, true) - yys3270 := string(yys3270Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3270 { - 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 { - yyv3273 := &x.LastHeartbeatTime - yym3274 := z.DecBinary() - _ = yym3274 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3273) { - } else if yym3274 { - z.DecBinaryUnmarshal(yyv3273) - } else if !yym3274 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3273) - } else { - z.DecFallback(yyv3273, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv3275 := &x.LastTransitionTime - yym3276 := z.DecBinary() - _ = yym3276 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3275) { - } else if yym3276 { - z.DecBinaryUnmarshal(yyv3275) - } else if !yym3276 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3275) - } else { - z.DecFallback(yyv3275, 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, yys3270) - } // end switch yys3270 - } // end for yyj3270 - 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 yyj3279 int - var yyb3279 bool - var yyhl3279 bool = l >= 0 - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = NodeConditionType(r.DecodeString()) - } - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastHeartbeatTime = pkg2_unversioned.Time{} - } else { - yyv3282 := &x.LastHeartbeatTime - yym3283 := z.DecBinary() - _ = yym3283 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3282) { - } else if yym3283 { - z.DecBinaryUnmarshal(yyv3282) - } else if !yym3283 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3282) - } else { - z.DecFallback(yyv3282, false) - } - } - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} - } else { - yyv3284 := &x.LastTransitionTime - yym3285 := z.DecBinary() - _ = yym3285 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3284) { - } else if yym3285 { - z.DecBinaryUnmarshal(yyv3284) - } else if !yym3285 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3284) - } else { - z.DecFallback(yyv3284, false) - } - } - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj3279++ - if yyhl3279 { - yyb3279 = yyj3279 > l - } else { - yyb3279 = r.CheckBreak() - } - if yyb3279 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3279-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NodeAddressType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3288 := z.EncBinary() - _ = yym3288 - 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 - yym3289 := z.DecBinary() - _ = yym3289 - 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 { - yym3290 := z.EncBinary() - _ = yym3290 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3291 := !z.EncBinary() - yy2arr3291 := z.EncBasicHandle().StructToArray - var yyq3291 [2]bool - _, _, _ = yysep3291, yyq3291, yy2arr3291 - const yyr3291 bool = false - var yynn3291 int - if yyr3291 || yy2arr3291 { - r.EncodeArrayStart(2) - } else { - yynn3291 = 2 - for _, b := range yyq3291 { - if b { - yynn3291++ - } - } - r.EncodeMapStart(yynn3291) - yynn3291 = 0 - } - if yyr3291 || yy2arr3291 { - 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 yyr3291 || yy2arr3291 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3294 := z.EncBinary() - _ = yym3294 - 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) - yym3295 := z.EncBinary() - _ = yym3295 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Address)) - } - } - if yyr3291 || yy2arr3291 { - 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 - yym3296 := z.DecBinary() - _ = yym3296 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3297 := r.ContainerType() - if yyct3297 == codecSelferValueTypeMap1234 { - yyl3297 := r.ReadMapStart() - if yyl3297 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3297, d) - } - } else if yyct3297 == codecSelferValueTypeArray1234 { - yyl3297 := r.ReadArrayStart() - if yyl3297 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3297, 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 yys3298Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3298Slc - var yyhl3298 bool = l >= 0 - for yyj3298 := 0; ; yyj3298++ { - if yyhl3298 { - if yyj3298 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3298Slc = r.DecodeBytes(yys3298Slc, true, true) - yys3298 := string(yys3298Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3298 { - 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, yys3298) - } // end switch yys3298 - } // end for yyj3298 - 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 yyj3301 int - var yyb3301 bool - var yyhl3301 bool = l >= 0 - yyj3301++ - if yyhl3301 { - yyb3301 = yyj3301 > l - } else { - yyb3301 = r.CheckBreak() - } - if yyb3301 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = NodeAddressType(r.DecodeString()) - } - yyj3301++ - if yyhl3301 { - yyb3301 = yyj3301 > l - } else { - yyb3301 = r.CheckBreak() - } - if yyb3301 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Address = "" - } else { - x.Address = string(r.DecodeString()) - } - for { - yyj3301++ - if yyhl3301 { - yyb3301 = yyj3301 > l - } else { - yyb3301 = r.CheckBreak() - } - if yyb3301 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3301-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NodeResources) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3304 := z.EncBinary() - _ = yym3304 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3305 := !z.EncBinary() - yy2arr3305 := z.EncBasicHandle().StructToArray - var yyq3305 [1]bool - _, _, _ = yysep3305, yyq3305, yy2arr3305 - const yyr3305 bool = false - yyq3305[0] = len(x.Capacity) != 0 - var yynn3305 int - if yyr3305 || yy2arr3305 { - r.EncodeArrayStart(1) - } else { - yynn3305 = 0 - for _, b := range yyq3305 { - if b { - yynn3305++ - } - } - r.EncodeMapStart(yynn3305) - yynn3305 = 0 - } - if yyr3305 || yy2arr3305 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3305[0] { - if x.Capacity == nil { - r.EncodeNil() - } else { - x.Capacity.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3305[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 yyr3305 || yy2arr3305 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NodeResources) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym3307 := z.DecBinary() - _ = yym3307 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3308 := r.ContainerType() - if yyct3308 == codecSelferValueTypeMap1234 { - yyl3308 := r.ReadMapStart() - if yyl3308 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3308, d) - } - } else if yyct3308 == codecSelferValueTypeArray1234 { - yyl3308 := r.ReadArrayStart() - if yyl3308 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3308, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NodeResources) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3309Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3309Slc - var yyhl3309 bool = l >= 0 - for yyj3309 := 0; ; yyj3309++ { - if yyhl3309 { - if yyj3309 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3309Slc = r.DecodeBytes(yys3309Slc, true, true) - yys3309 := string(yys3309Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3309 { - case "capacity": - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv3310 := &x.Capacity - yyv3310.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3309) - } // end switch yys3309 - } // end for yyj3309 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NodeResources) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj3311 int - var yyb3311 bool - var yyhl3311 bool = l >= 0 - yyj3311++ - if yyhl3311 { - yyb3311 = yyj3311 > l - } else { - yyb3311 = r.CheckBreak() - } - if yyb3311 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Capacity = nil - } else { - yyv3312 := &x.Capacity - yyv3312.CodecDecodeSelf(d) - } - for { - yyj3311++ - if yyhl3311 { - yyb3311 = yyj3311 > l - } else { - yyb3311 = r.CheckBreak() - } - if yyb3311 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3311-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ResourceName) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3313 := z.EncBinary() - _ = yym3313 - 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 - yym3314 := z.DecBinary() - _ = yym3314 - 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 { - yym3315 := z.EncBinary() - _ = yym3315 - 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 - yym3316 := z.DecBinary() - _ = yym3316 - 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 { - yym3317 := z.EncBinary() - _ = yym3317 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3318 := !z.EncBinary() - yy2arr3318 := z.EncBasicHandle().StructToArray - var yyq3318 [5]bool - _, _, _ = yysep3318, yyq3318, yy2arr3318 - const yyr3318 bool = false - yyq3318[0] = x.Kind != "" - yyq3318[1] = x.APIVersion != "" - yyq3318[2] = true - yyq3318[3] = true - yyq3318[4] = true - var yynn3318 int - if yyr3318 || yy2arr3318 { - r.EncodeArrayStart(5) - } else { - yynn3318 = 0 - for _, b := range yyq3318 { - if b { - yynn3318++ - } - } - r.EncodeMapStart(yynn3318) - yynn3318 = 0 - } - if yyr3318 || yy2arr3318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3318[0] { - yym3320 := z.EncBinary() - _ = yym3320 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3318[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3321 := z.EncBinary() - _ = yym3321 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3318 || yy2arr3318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3318[1] { - yym3323 := z.EncBinary() - _ = yym3323 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3318[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3324 := z.EncBinary() - _ = yym3324 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3318 || yy2arr3318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3318[2] { - yy3326 := &x.ObjectMeta - yy3326.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3318[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3327 := &x.ObjectMeta - yy3327.CodecEncodeSelf(e) - } - } - if yyr3318 || yy2arr3318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3318[3] { - yy3329 := &x.Spec - yy3329.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3318[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3330 := &x.Spec - yy3330.CodecEncodeSelf(e) - } - } - if yyr3318 || yy2arr3318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3318[4] { - yy3332 := &x.Status - yy3332.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3318[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3333 := &x.Status - yy3333.CodecEncodeSelf(e) - } - } - if yyr3318 || yy2arr3318 { - 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 - yym3334 := z.DecBinary() - _ = yym3334 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3335 := r.ContainerType() - if yyct3335 == codecSelferValueTypeMap1234 { - yyl3335 := r.ReadMapStart() - if yyl3335 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3335, d) - } - } else if yyct3335 == codecSelferValueTypeArray1234 { - yyl3335 := r.ReadArrayStart() - if yyl3335 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3335, 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 yys3336Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3336Slc - var yyhl3336 bool = l >= 0 - for yyj3336 := 0; ; yyj3336++ { - if yyhl3336 { - if yyj3336 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3336Slc = r.DecodeBytes(yys3336Slc, true, true) - yys3336 := string(yys3336Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3336 { - 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 { - yyv3339 := &x.ObjectMeta - yyv3339.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = NodeSpec{} - } else { - yyv3340 := &x.Spec - yyv3340.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = NodeStatus{} - } else { - yyv3341 := &x.Status - yyv3341.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3336) - } // end switch yys3336 - } // end for yyj3336 - 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 yyj3342 int - var yyb3342 bool - var yyhl3342 bool = l >= 0 - yyj3342++ - if yyhl3342 { - yyb3342 = yyj3342 > l - } else { - yyb3342 = r.CheckBreak() - } - if yyb3342 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3342++ - if yyhl3342 { - yyb3342 = yyj3342 > l - } else { - yyb3342 = r.CheckBreak() - } - if yyb3342 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3342++ - if yyhl3342 { - yyb3342 = yyj3342 > l - } else { - yyb3342 = r.CheckBreak() - } - if yyb3342 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3345 := &x.ObjectMeta - yyv3345.CodecDecodeSelf(d) - } - yyj3342++ - if yyhl3342 { - yyb3342 = yyj3342 > l - } else { - yyb3342 = r.CheckBreak() - } - if yyb3342 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = NodeSpec{} - } else { - yyv3346 := &x.Spec - yyv3346.CodecDecodeSelf(d) - } - yyj3342++ - if yyhl3342 { - yyb3342 = yyj3342 > l - } else { - yyb3342 = r.CheckBreak() - } - if yyb3342 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = NodeStatus{} - } else { - yyv3347 := &x.Status - yyv3347.CodecDecodeSelf(d) - } - for { - yyj3342++ - if yyhl3342 { - yyb3342 = yyj3342 > l - } else { - yyb3342 = r.CheckBreak() - } - if yyb3342 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3342-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 { - yym3348 := z.EncBinary() - _ = yym3348 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3349 := !z.EncBinary() - yy2arr3349 := z.EncBasicHandle().StructToArray - var yyq3349 [4]bool - _, _, _ = yysep3349, yyq3349, yy2arr3349 - const yyr3349 bool = false - yyq3349[0] = x.Kind != "" - yyq3349[1] = x.APIVersion != "" - yyq3349[2] = true - var yynn3349 int - if yyr3349 || yy2arr3349 { - r.EncodeArrayStart(4) - } else { - yynn3349 = 1 - for _, b := range yyq3349 { - if b { - yynn3349++ - } - } - r.EncodeMapStart(yynn3349) - yynn3349 = 0 - } - if yyr3349 || yy2arr3349 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3349[0] { - yym3351 := z.EncBinary() - _ = yym3351 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3349[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3352 := z.EncBinary() - _ = yym3352 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3349 || yy2arr3349 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3349[1] { - yym3354 := z.EncBinary() - _ = yym3354 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3349[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3355 := z.EncBinary() - _ = yym3355 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3349 || yy2arr3349 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3349[2] { - yy3357 := &x.ListMeta - yym3358 := z.EncBinary() - _ = yym3358 - if false { - } else if z.HasExtensions() && z.EncExt(yy3357) { - } else { - z.EncFallback(yy3357) - } - } else { - r.EncodeNil() - } - } else { - if yyq3349[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3359 := &x.ListMeta - yym3360 := z.EncBinary() - _ = yym3360 - if false { - } else if z.HasExtensions() && z.EncExt(yy3359) { - } else { - z.EncFallback(yy3359) - } - } - } - if yyr3349 || yy2arr3349 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym3362 := z.EncBinary() - _ = yym3362 - 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 { - yym3363 := z.EncBinary() - _ = yym3363 - if false { - } else { - h.encSliceNode(([]Node)(x.Items), e) - } - } - } - if yyr3349 || yy2arr3349 { - 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 - yym3364 := z.DecBinary() - _ = yym3364 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3365 := r.ContainerType() - if yyct3365 == codecSelferValueTypeMap1234 { - yyl3365 := r.ReadMapStart() - if yyl3365 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3365, d) - } - } else if yyct3365 == codecSelferValueTypeArray1234 { - yyl3365 := r.ReadArrayStart() - if yyl3365 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3365, 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 yys3366Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3366Slc - var yyhl3366 bool = l >= 0 - for yyj3366 := 0; ; yyj3366++ { - if yyhl3366 { - if yyj3366 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3366Slc = r.DecodeBytes(yys3366Slc, true, true) - yys3366 := string(yys3366Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3366 { - 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 { - yyv3369 := &x.ListMeta - yym3370 := z.DecBinary() - _ = yym3370 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3369) { - } else { - z.DecFallback(yyv3369, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3371 := &x.Items - yym3372 := z.DecBinary() - _ = yym3372 - if false { - } else { - h.decSliceNode((*[]Node)(yyv3371), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3366) - } // end switch yys3366 - } // end for yyj3366 - 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 yyj3373 int - var yyb3373 bool - var yyhl3373 bool = l >= 0 - yyj3373++ - if yyhl3373 { - yyb3373 = yyj3373 > l - } else { - yyb3373 = r.CheckBreak() - } - if yyb3373 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3373++ - if yyhl3373 { - yyb3373 = yyj3373 > l - } else { - yyb3373 = r.CheckBreak() - } - if yyb3373 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3373++ - if yyhl3373 { - yyb3373 = yyj3373 > l - } else { - yyb3373 = r.CheckBreak() - } - if yyb3373 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3376 := &x.ListMeta - yym3377 := z.DecBinary() - _ = yym3377 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3376) { - } else { - z.DecFallback(yyv3376, false) - } - } - yyj3373++ - if yyhl3373 { - yyb3373 = yyj3373 > l - } else { - yyb3373 = r.CheckBreak() - } - if yyb3373 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3378 := &x.Items - yym3379 := z.DecBinary() - _ = yym3379 - if false { - } else { - h.decSliceNode((*[]Node)(yyv3378), d) - } - } - for { - yyj3373++ - if yyhl3373 { - yyb3373 = yyj3373 > l - } else { - yyb3373 = r.CheckBreak() - } - if yyb3373 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3373-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NamespaceSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3380 := z.EncBinary() - _ = yym3380 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3381 := !z.EncBinary() - yy2arr3381 := z.EncBasicHandle().StructToArray - var yyq3381 [1]bool - _, _, _ = yysep3381, yyq3381, yy2arr3381 - const yyr3381 bool = false - var yynn3381 int - if yyr3381 || yy2arr3381 { - r.EncodeArrayStart(1) - } else { - yynn3381 = 1 - for _, b := range yyq3381 { - if b { - yynn3381++ - } - } - r.EncodeMapStart(yynn3381) - yynn3381 = 0 - } - if yyr3381 || yy2arr3381 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym3383 := z.EncBinary() - _ = yym3383 - if false { - } else { - h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Finalizers")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym3384 := z.EncBinary() - _ = yym3384 - if false { - } else { - h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e) - } - } - } - if yyr3381 || yy2arr3381 { - 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 - yym3385 := z.DecBinary() - _ = yym3385 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3386 := r.ContainerType() - if yyct3386 == codecSelferValueTypeMap1234 { - yyl3386 := r.ReadMapStart() - if yyl3386 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3386, d) - } - } else if yyct3386 == codecSelferValueTypeArray1234 { - yyl3386 := r.ReadArrayStart() - if yyl3386 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3386, 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 yys3387Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3387Slc - var yyhl3387 bool = l >= 0 - for yyj3387 := 0; ; yyj3387++ { - if yyhl3387 { - if yyj3387 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3387Slc = r.DecodeBytes(yys3387Slc, true, true) - yys3387 := string(yys3387Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3387 { - case "Finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv3388 := &x.Finalizers - yym3389 := z.DecBinary() - _ = yym3389 - if false { - } else { - h.decSliceFinalizerName((*[]FinalizerName)(yyv3388), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3387) - } // end switch yys3387 - } // end for yyj3387 - 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 yyj3390 int - var yyb3390 bool - var yyhl3390 bool = l >= 0 - yyj3390++ - if yyhl3390 { - yyb3390 = yyj3390 > l - } else { - yyb3390 = r.CheckBreak() - } - if yyb3390 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv3391 := &x.Finalizers - yym3392 := z.DecBinary() - _ = yym3392 - if false { - } else { - h.decSliceFinalizerName((*[]FinalizerName)(yyv3391), d) - } - } - for { - yyj3390++ - if yyhl3390 { - yyb3390 = yyj3390 > l - } else { - yyb3390 = r.CheckBreak() - } - if yyb3390 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3390-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x FinalizerName) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3393 := z.EncBinary() - _ = yym3393 - 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 - yym3394 := z.DecBinary() - _ = yym3394 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *NamespaceStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym3395 := z.EncBinary() - _ = yym3395 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3396 := !z.EncBinary() - yy2arr3396 := z.EncBasicHandle().StructToArray - var yyq3396 [1]bool - _, _, _ = yysep3396, yyq3396, yy2arr3396 - const yyr3396 bool = false - yyq3396[0] = x.Phase != "" - var yynn3396 int - if yyr3396 || yy2arr3396 { - r.EncodeArrayStart(1) - } else { - yynn3396 = 0 - for _, b := range yyq3396 { - if b { - yynn3396++ - } - } - r.EncodeMapStart(yynn3396) - yynn3396 = 0 - } - if yyr3396 || yy2arr3396 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3396[0] { - x.Phase.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3396[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("phase")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Phase.CodecEncodeSelf(e) - } - } - if yyr3396 || yy2arr3396 { - 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 - yym3398 := z.DecBinary() - _ = yym3398 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3399 := r.ContainerType() - if yyct3399 == codecSelferValueTypeMap1234 { - yyl3399 := r.ReadMapStart() - if yyl3399 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3399, d) - } - } else if yyct3399 == codecSelferValueTypeArray1234 { - yyl3399 := r.ReadArrayStart() - if yyl3399 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3399, 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 yys3400Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3400Slc - var yyhl3400 bool = l >= 0 - for yyj3400 := 0; ; yyj3400++ { - if yyhl3400 { - if yyj3400 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3400Slc = r.DecodeBytes(yys3400Slc, true, true) - yys3400 := string(yys3400Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3400 { - case "phase": - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NamespacePhase(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3400) - } // end switch yys3400 - } // end for yyj3400 - 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 yyj3402 int - var yyb3402 bool - var yyhl3402 bool = l >= 0 - yyj3402++ - if yyhl3402 { - yyb3402 = yyj3402 > l - } else { - yyb3402 = r.CheckBreak() - } - if yyb3402 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Phase = "" - } else { - x.Phase = NamespacePhase(r.DecodeString()) - } - for { - yyj3402++ - if yyhl3402 { - yyb3402 = yyj3402 > l - } else { - yyb3402 = r.CheckBreak() - } - if yyb3402 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3402-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x NamespacePhase) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym3404 := z.EncBinary() - _ = yym3404 - 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 - yym3405 := z.DecBinary() - _ = yym3405 - 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 { - yym3406 := z.EncBinary() - _ = yym3406 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3407 := !z.EncBinary() - yy2arr3407 := z.EncBasicHandle().StructToArray - var yyq3407 [5]bool - _, _, _ = yysep3407, yyq3407, yy2arr3407 - const yyr3407 bool = false - yyq3407[0] = x.Kind != "" - yyq3407[1] = x.APIVersion != "" - yyq3407[2] = true - yyq3407[3] = true - yyq3407[4] = true - var yynn3407 int - if yyr3407 || yy2arr3407 { - r.EncodeArrayStart(5) - } else { - yynn3407 = 0 - for _, b := range yyq3407 { - if b { - yynn3407++ - } - } - r.EncodeMapStart(yynn3407) - yynn3407 = 0 - } - if yyr3407 || yy2arr3407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3407[0] { - yym3409 := z.EncBinary() - _ = yym3409 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3407[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3410 := z.EncBinary() - _ = yym3410 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3407 || yy2arr3407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3407[1] { - yym3412 := z.EncBinary() - _ = yym3412 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3407[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3413 := z.EncBinary() - _ = yym3413 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3407 || yy2arr3407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3407[2] { - yy3415 := &x.ObjectMeta - yy3415.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3407[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3416 := &x.ObjectMeta - yy3416.CodecEncodeSelf(e) - } - } - if yyr3407 || yy2arr3407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3407[3] { - yy3418 := &x.Spec - yy3418.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3407[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3419 := &x.Spec - yy3419.CodecEncodeSelf(e) - } - } - if yyr3407 || yy2arr3407 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3407[4] { - yy3421 := &x.Status - yy3421.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3407[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3422 := &x.Status - yy3422.CodecEncodeSelf(e) - } - } - if yyr3407 || yy2arr3407 { - 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 - yym3423 := z.DecBinary() - _ = yym3423 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3424 := r.ContainerType() - if yyct3424 == codecSelferValueTypeMap1234 { - yyl3424 := r.ReadMapStart() - if yyl3424 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3424, d) - } - } else if yyct3424 == codecSelferValueTypeArray1234 { - yyl3424 := r.ReadArrayStart() - if yyl3424 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3424, 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 yys3425Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3425Slc - var yyhl3425 bool = l >= 0 - for yyj3425 := 0; ; yyj3425++ { - if yyhl3425 { - if yyj3425 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3425Slc = r.DecodeBytes(yys3425Slc, true, true) - yys3425 := string(yys3425Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3425 { - 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 { - yyv3428 := &x.ObjectMeta - yyv3428.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = NamespaceSpec{} - } else { - yyv3429 := &x.Spec - yyv3429.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = NamespaceStatus{} - } else { - yyv3430 := &x.Status - yyv3430.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3425) - } // end switch yys3425 - } // end for yyj3425 - 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 yyj3431 int - var yyb3431 bool - var yyhl3431 bool = l >= 0 - yyj3431++ - if yyhl3431 { - yyb3431 = yyj3431 > l - } else { - yyb3431 = r.CheckBreak() - } - if yyb3431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3431++ - if yyhl3431 { - yyb3431 = yyj3431 > l - } else { - yyb3431 = r.CheckBreak() - } - if yyb3431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3431++ - if yyhl3431 { - yyb3431 = yyj3431 > l - } else { - yyb3431 = r.CheckBreak() - } - if yyb3431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3434 := &x.ObjectMeta - yyv3434.CodecDecodeSelf(d) - } - yyj3431++ - if yyhl3431 { - yyb3431 = yyj3431 > l - } else { - yyb3431 = r.CheckBreak() - } - if yyb3431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = NamespaceSpec{} - } else { - yyv3435 := &x.Spec - yyv3435.CodecDecodeSelf(d) - } - yyj3431++ - if yyhl3431 { - yyb3431 = yyj3431 > l - } else { - yyb3431 = r.CheckBreak() - } - if yyb3431 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = NamespaceStatus{} - } else { - yyv3436 := &x.Status - yyv3436.CodecDecodeSelf(d) - } - for { - yyj3431++ - if yyhl3431 { - yyb3431 = yyj3431 > l - } else { - yyb3431 = r.CheckBreak() - } - if yyb3431 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3431-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 { - yym3437 := z.EncBinary() - _ = yym3437 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3438 := !z.EncBinary() - yy2arr3438 := z.EncBasicHandle().StructToArray - var yyq3438 [4]bool - _, _, _ = yysep3438, yyq3438, yy2arr3438 - const yyr3438 bool = false - yyq3438[0] = x.Kind != "" - yyq3438[1] = x.APIVersion != "" - yyq3438[2] = true - var yynn3438 int - if yyr3438 || yy2arr3438 { - r.EncodeArrayStart(4) - } else { - yynn3438 = 1 - for _, b := range yyq3438 { - if b { - yynn3438++ - } - } - r.EncodeMapStart(yynn3438) - yynn3438 = 0 - } - if yyr3438 || yy2arr3438 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3438[0] { - yym3440 := z.EncBinary() - _ = yym3440 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3438[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3441 := z.EncBinary() - _ = yym3441 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3438 || yy2arr3438 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3438[1] { - yym3443 := z.EncBinary() - _ = yym3443 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3438[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3444 := z.EncBinary() - _ = yym3444 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3438 || yy2arr3438 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3438[2] { - yy3446 := &x.ListMeta - yym3447 := z.EncBinary() - _ = yym3447 - if false { - } else if z.HasExtensions() && z.EncExt(yy3446) { - } else { - z.EncFallback(yy3446) - } - } else { - r.EncodeNil() - } - } else { - if yyq3438[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3448 := &x.ListMeta - yym3449 := z.EncBinary() - _ = yym3449 - if false { - } else if z.HasExtensions() && z.EncExt(yy3448) { - } else { - z.EncFallback(yy3448) - } - } - } - if yyr3438 || yy2arr3438 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym3451 := z.EncBinary() - _ = yym3451 - 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 { - yym3452 := z.EncBinary() - _ = yym3452 - if false { - } else { - h.encSliceNamespace(([]Namespace)(x.Items), e) - } - } - } - if yyr3438 || yy2arr3438 { - 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 - yym3453 := z.DecBinary() - _ = yym3453 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3454 := r.ContainerType() - if yyct3454 == codecSelferValueTypeMap1234 { - yyl3454 := r.ReadMapStart() - if yyl3454 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3454, d) - } - } else if yyct3454 == codecSelferValueTypeArray1234 { - yyl3454 := r.ReadArrayStart() - if yyl3454 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3454, 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 yys3455Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3455Slc - var yyhl3455 bool = l >= 0 - for yyj3455 := 0; ; yyj3455++ { - if yyhl3455 { - if yyj3455 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3455Slc = r.DecodeBytes(yys3455Slc, true, true) - yys3455 := string(yys3455Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3455 { - 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 { - yyv3458 := &x.ListMeta - yym3459 := z.DecBinary() - _ = yym3459 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3458) { - } else { - z.DecFallback(yyv3458, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3460 := &x.Items - yym3461 := z.DecBinary() - _ = yym3461 - if false { - } else { - h.decSliceNamespace((*[]Namespace)(yyv3460), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3455) - } // end switch yys3455 - } // end for yyj3455 - 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 yyj3462 int - var yyb3462 bool - var yyhl3462 bool = l >= 0 - yyj3462++ - if yyhl3462 { - yyb3462 = yyj3462 > l - } else { - yyb3462 = r.CheckBreak() - } - if yyb3462 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3462++ - if yyhl3462 { - yyb3462 = yyj3462 > l - } else { - yyb3462 = r.CheckBreak() - } - if yyb3462 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3462++ - if yyhl3462 { - yyb3462 = yyj3462 > l - } else { - yyb3462 = r.CheckBreak() - } - if yyb3462 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv3465 := &x.ListMeta - yym3466 := z.DecBinary() - _ = yym3466 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3465) { - } else { - z.DecFallback(yyv3465, false) - } - } - yyj3462++ - if yyhl3462 { - yyb3462 = yyj3462 > l - } else { - yyb3462 = r.CheckBreak() - } - if yyb3462 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv3467 := &x.Items - yym3468 := z.DecBinary() - _ = yym3468 - if false { - } else { - h.decSliceNamespace((*[]Namespace)(yyv3467), d) - } - } - for { - yyj3462++ - if yyhl3462 { - yyb3462 = yyj3462 > l - } else { - yyb3462 = r.CheckBreak() - } - if yyb3462 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3462-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 { - yym3469 := z.EncBinary() - _ = yym3469 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3470 := !z.EncBinary() - yy2arr3470 := z.EncBasicHandle().StructToArray - var yyq3470 [4]bool - _, _, _ = yysep3470, yyq3470, yy2arr3470 - const yyr3470 bool = false - yyq3470[0] = x.Kind != "" - yyq3470[1] = x.APIVersion != "" - yyq3470[2] = true - var yynn3470 int - if yyr3470 || yy2arr3470 { - r.EncodeArrayStart(4) - } else { - yynn3470 = 1 - for _, b := range yyq3470 { - if b { - yynn3470++ - } - } - r.EncodeMapStart(yynn3470) - yynn3470 = 0 - } - if yyr3470 || yy2arr3470 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3470[0] { - yym3472 := z.EncBinary() - _ = yym3472 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3470[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3473 := z.EncBinary() - _ = yym3473 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3470 || yy2arr3470 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3470[1] { - yym3475 := z.EncBinary() - _ = yym3475 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3470[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3476 := z.EncBinary() - _ = yym3476 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3470 || yy2arr3470 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3470[2] { - yy3478 := &x.ObjectMeta - yy3478.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3470[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3479 := &x.ObjectMeta - yy3479.CodecEncodeSelf(e) - } - } - if yyr3470 || yy2arr3470 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3481 := &x.Target - yy3481.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("target")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3482 := &x.Target - yy3482.CodecEncodeSelf(e) - } - if yyr3470 || yy2arr3470 { - 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 - yym3483 := z.DecBinary() - _ = yym3483 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3484 := r.ContainerType() - if yyct3484 == codecSelferValueTypeMap1234 { - yyl3484 := r.ReadMapStart() - if yyl3484 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3484, d) - } - } else if yyct3484 == codecSelferValueTypeArray1234 { - yyl3484 := r.ReadArrayStart() - if yyl3484 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3484, 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 yys3485Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3485Slc - var yyhl3485 bool = l >= 0 - for yyj3485 := 0; ; yyj3485++ { - if yyhl3485 { - if yyj3485 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3485Slc = r.DecodeBytes(yys3485Slc, true, true) - yys3485 := string(yys3485Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3485 { - 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 { - yyv3488 := &x.ObjectMeta - yyv3488.CodecDecodeSelf(d) - } - case "target": - if r.TryDecodeAsNil() { - x.Target = ObjectReference{} - } else { - yyv3489 := &x.Target - yyv3489.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3485) - } // end switch yys3485 - } // end for yyj3485 - 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 yyj3490 int - var yyb3490 bool - var yyhl3490 bool = l >= 0 - yyj3490++ - if yyhl3490 { - yyb3490 = yyj3490 > l - } else { - yyb3490 = r.CheckBreak() - } - if yyb3490 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3490++ - if yyhl3490 { - yyb3490 = yyj3490 > l - } else { - yyb3490 = r.CheckBreak() - } - if yyb3490 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3490++ - if yyhl3490 { - yyb3490 = yyj3490 > l - } else { - yyb3490 = r.CheckBreak() - } - if yyb3490 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv3493 := &x.ObjectMeta - yyv3493.CodecDecodeSelf(d) - } - yyj3490++ - if yyhl3490 { - yyb3490 = yyj3490 > l - } else { - yyb3490 = r.CheckBreak() - } - if yyb3490 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Target = ObjectReference{} - } else { - yyv3494 := &x.Target - yyv3494.CodecDecodeSelf(d) - } - for { - yyj3490++ - if yyhl3490 { - yyb3490 = yyj3490 > l - } else { - yyb3490 = r.CheckBreak() - } - if yyb3490 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3490-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 { - yym3495 := z.EncBinary() - _ = yym3495 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3496 := !z.EncBinary() - yy2arr3496 := z.EncBasicHandle().StructToArray - var yyq3496 [1]bool - _, _, _ = yysep3496, yyq3496, yy2arr3496 - const yyr3496 bool = false - yyq3496[0] = x.UID != nil - var yynn3496 int - if yyr3496 || yy2arr3496 { - r.EncodeArrayStart(1) - } else { - yynn3496 = 0 - for _, b := range yyq3496 { - if b { - yynn3496++ - } - } - r.EncodeMapStart(yynn3496) - yynn3496 = 0 - } - if yyr3496 || yy2arr3496 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3496[0] { - if x.UID == nil { - r.EncodeNil() - } else { - yy3498 := *x.UID - yym3499 := z.EncBinary() - _ = yym3499 - if false { - } else if z.HasExtensions() && z.EncExt(yy3498) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy3498)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3496[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.UID == nil { - r.EncodeNil() - } else { - yy3500 := *x.UID - yym3501 := z.EncBinary() - _ = yym3501 - if false { - } else if z.HasExtensions() && z.EncExt(yy3500) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy3500)) - } - } - } - } - if yyr3496 || yy2arr3496 { - 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 - yym3502 := z.DecBinary() - _ = yym3502 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3503 := r.ContainerType() - if yyct3503 == codecSelferValueTypeMap1234 { - yyl3503 := r.ReadMapStart() - if yyl3503 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3503, d) - } - } else if yyct3503 == codecSelferValueTypeArray1234 { - yyl3503 := r.ReadArrayStart() - if yyl3503 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3503, 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 yys3504Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3504Slc - var yyhl3504 bool = l >= 0 - for yyj3504 := 0; ; yyj3504++ { - if yyhl3504 { - if yyj3504 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3504Slc = r.DecodeBytes(yys3504Slc, true, true) - yys3504 := string(yys3504Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3504 { - case "uid": - if r.TryDecodeAsNil() { - if x.UID != nil { - x.UID = nil - } - } else { - if x.UID == nil { - x.UID = new(pkg1_types.UID) - } - yym3506 := z.DecBinary() - _ = yym3506 - if false { - } else if z.HasExtensions() && z.DecExt(x.UID) { - } else { - *((*string)(x.UID)) = r.DecodeString() - } - } - default: - z.DecStructFieldNotFound(-1, yys3504) - } // end switch yys3504 - } // end for yyj3504 - 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 yyj3507 int - var yyb3507 bool - var yyhl3507 bool = l >= 0 - yyj3507++ - if yyhl3507 { - yyb3507 = yyj3507 > l - } else { - yyb3507 = r.CheckBreak() - } - if yyb3507 { - 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) - } - yym3509 := z.DecBinary() - _ = yym3509 - if false { - } else if z.HasExtensions() && z.DecExt(x.UID) { - } else { - *((*string)(x.UID)) = r.DecodeString() - } - } - for { - yyj3507++ - if yyhl3507 { - yyb3507 = yyj3507 > l - } else { - yyb3507 = r.CheckBreak() - } - if yyb3507 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3507-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 { - yym3510 := z.EncBinary() - _ = yym3510 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3511 := !z.EncBinary() - yy2arr3511 := z.EncBasicHandle().StructToArray - var yyq3511 [5]bool - _, _, _ = yysep3511, yyq3511, yy2arr3511 - const yyr3511 bool = false - yyq3511[0] = x.Kind != "" - yyq3511[1] = x.APIVersion != "" - yyq3511[2] = x.GracePeriodSeconds != nil - yyq3511[3] = x.Preconditions != nil - yyq3511[4] = x.OrphanDependents != nil - var yynn3511 int - if yyr3511 || yy2arr3511 { - r.EncodeArrayStart(5) - } else { - yynn3511 = 0 - for _, b := range yyq3511 { - if b { - yynn3511++ - } - } - r.EncodeMapStart(yynn3511) - yynn3511 = 0 - } - if yyr3511 || yy2arr3511 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3511[0] { - yym3513 := z.EncBinary() - _ = yym3513 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3511[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3514 := z.EncBinary() - _ = yym3514 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3511 || yy2arr3511 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3511[1] { - yym3516 := z.EncBinary() - _ = yym3516 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3511[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3517 := z.EncBinary() - _ = yym3517 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3511 || yy2arr3511 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3511[2] { - if x.GracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy3519 := *x.GracePeriodSeconds - yym3520 := z.EncBinary() - _ = yym3520 - if false { - } else { - r.EncodeInt(int64(yy3519)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3511[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("gracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.GracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy3521 := *x.GracePeriodSeconds - yym3522 := z.EncBinary() - _ = yym3522 - if false { - } else { - r.EncodeInt(int64(yy3521)) - } - } - } - } - if yyr3511 || yy2arr3511 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3511[3] { - if x.Preconditions == nil { - r.EncodeNil() - } else { - x.Preconditions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq3511[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 yyr3511 || yy2arr3511 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3511[4] { - if x.OrphanDependents == nil { - r.EncodeNil() - } else { - yy3525 := *x.OrphanDependents - yym3526 := z.EncBinary() - _ = yym3526 - if false { - } else { - r.EncodeBool(bool(yy3525)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3511[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("orphanDependents")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.OrphanDependents == nil { - r.EncodeNil() - } else { - yy3527 := *x.OrphanDependents - yym3528 := z.EncBinary() - _ = yym3528 - if false { - } else { - r.EncodeBool(bool(yy3527)) - } - } - } - } - if yyr3511 || yy2arr3511 { - 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 - yym3529 := z.DecBinary() - _ = yym3529 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3530 := r.ContainerType() - if yyct3530 == codecSelferValueTypeMap1234 { - yyl3530 := r.ReadMapStart() - if yyl3530 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3530, d) - } - } else if yyct3530 == codecSelferValueTypeArray1234 { - yyl3530 := r.ReadArrayStart() - if yyl3530 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3530, 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 yys3531Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3531Slc - var yyhl3531 bool = l >= 0 - for yyj3531 := 0; ; yyj3531++ { - if yyhl3531 { - if yyj3531 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3531Slc = r.DecodeBytes(yys3531Slc, true, true) - yys3531 := string(yys3531Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3531 { - 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) - } - yym3535 := z.DecBinary() - _ = yym3535 - 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) - } - yym3538 := z.DecBinary() - _ = yym3538 - if false { - } else { - *((*bool)(x.OrphanDependents)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3531) - } // end switch yys3531 - } // end for yyj3531 - 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 yyj3539 int - var yyb3539 bool - var yyhl3539 bool = l >= 0 - yyj3539++ - if yyhl3539 { - yyb3539 = yyj3539 > l - } else { - yyb3539 = r.CheckBreak() - } - if yyb3539 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3539++ - if yyhl3539 { - yyb3539 = yyj3539 > l - } else { - yyb3539 = r.CheckBreak() - } - if yyb3539 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3539++ - if yyhl3539 { - yyb3539 = yyj3539 > l - } else { - yyb3539 = r.CheckBreak() - } - if yyb3539 { - 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) - } - yym3543 := z.DecBinary() - _ = yym3543 - if false { - } else { - *((*int64)(x.GracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj3539++ - if yyhl3539 { - yyb3539 = yyj3539 > l - } else { - yyb3539 = r.CheckBreak() - } - if yyb3539 { - 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) - } - yyj3539++ - if yyhl3539 { - yyb3539 = yyj3539 > l - } else { - yyb3539 = r.CheckBreak() - } - if yyb3539 { - 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) - } - yym3546 := z.DecBinary() - _ = yym3546 - if false { - } else { - *((*bool)(x.OrphanDependents)) = r.DecodeBool() - } - } - for { - yyj3539++ - if yyhl3539 { - yyb3539 = yyj3539 > l - } else { - yyb3539 = r.CheckBreak() - } - if yyb3539 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3539-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 { - yym3547 := z.EncBinary() - _ = yym3547 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3548 := !z.EncBinary() - yy2arr3548 := z.EncBasicHandle().StructToArray - var yyq3548 [4]bool - _, _, _ = yysep3548, yyq3548, yy2arr3548 - const yyr3548 bool = false - yyq3548[0] = x.Kind != "" - yyq3548[1] = x.APIVersion != "" - var yynn3548 int - if yyr3548 || yy2arr3548 { - r.EncodeArrayStart(4) - } else { - yynn3548 = 2 - for _, b := range yyq3548 { - if b { - yynn3548++ - } - } - r.EncodeMapStart(yynn3548) - yynn3548 = 0 - } - if yyr3548 || yy2arr3548 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3548[0] { - yym3550 := z.EncBinary() - _ = yym3550 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3548[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3551 := z.EncBinary() - _ = yym3551 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3548 || yy2arr3548 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3548[1] { - yym3553 := z.EncBinary() - _ = yym3553 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3548[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3554 := z.EncBinary() - _ = yym3554 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3548 || yy2arr3548 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3556 := z.EncBinary() - _ = yym3556 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("export")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3557 := z.EncBinary() - _ = yym3557 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } - if yyr3548 || yy2arr3548 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3559 := z.EncBinary() - _ = yym3559 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exact")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3560 := z.EncBinary() - _ = yym3560 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } - if yyr3548 || yy2arr3548 { - 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 - yym3561 := z.DecBinary() - _ = yym3561 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3562 := r.ContainerType() - if yyct3562 == codecSelferValueTypeMap1234 { - yyl3562 := r.ReadMapStart() - if yyl3562 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3562, d) - } - } else if yyct3562 == codecSelferValueTypeArray1234 { - yyl3562 := r.ReadArrayStart() - if yyl3562 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3562, 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 yys3563Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3563Slc - var yyhl3563 bool = l >= 0 - for yyj3563 := 0; ; yyj3563++ { - if yyhl3563 { - if yyj3563 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3563Slc = r.DecodeBytes(yys3563Slc, true, true) - yys3563 := string(yys3563Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3563 { - 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, yys3563) - } // end switch yys3563 - } // end for yyj3563 - 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 yyj3568 int - var yyb3568 bool - var yyhl3568 bool = l >= 0 - yyj3568++ - if yyhl3568 { - yyb3568 = yyj3568 > l - } else { - yyb3568 = r.CheckBreak() - } - if yyb3568 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3568++ - if yyhl3568 { - yyb3568 = yyj3568 > l - } else { - yyb3568 = r.CheckBreak() - } - if yyb3568 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3568++ - if yyhl3568 { - yyb3568 = yyj3568 > l - } else { - yyb3568 = r.CheckBreak() - } - if yyb3568 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Export = false - } else { - x.Export = bool(r.DecodeBool()) - } - yyj3568++ - if yyhl3568 { - yyb3568 = yyj3568 > l - } else { - yyb3568 = r.CheckBreak() - } - if yyb3568 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Exact = false - } else { - x.Exact = bool(r.DecodeBool()) - } - for { - yyj3568++ - if yyhl3568 { - yyb3568 = yyj3568 > l - } else { - yyb3568 = r.CheckBreak() - } - if yyb3568 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3568-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 { - yym3573 := z.EncBinary() - _ = yym3573 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3574 := !z.EncBinary() - yy2arr3574 := z.EncBasicHandle().StructToArray - var yyq3574 [7]bool - _, _, _ = yysep3574, yyq3574, yy2arr3574 - const yyr3574 bool = false - yyq3574[0] = x.Kind != "" - yyq3574[1] = x.APIVersion != "" - var yynn3574 int - if yyr3574 || yy2arr3574 { - r.EncodeArrayStart(7) - } else { - yynn3574 = 5 - for _, b := range yyq3574 { - if b { - yynn3574++ - } - } - r.EncodeMapStart(yynn3574) - yynn3574 = 0 - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3574[0] { - yym3576 := z.EncBinary() - _ = yym3576 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3574[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3577 := z.EncBinary() - _ = yym3577 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3574[1] { - yym3579 := z.EncBinary() - _ = yym3579 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3574[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3580 := z.EncBinary() - _ = yym3580 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.LabelSelector == nil { - r.EncodeNil() - } else { - yym3582 := z.EncBinary() - _ = yym3582 - if false { - } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { - } else { - z.EncFallback(x.LabelSelector) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("LabelSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LabelSelector == nil { - r.EncodeNil() - } else { - yym3583 := z.EncBinary() - _ = yym3583 - if false { - } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { - } else { - z.EncFallback(x.LabelSelector) - } - } - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.FieldSelector == nil { - r.EncodeNil() - } else { - yym3585 := z.EncBinary() - _ = yym3585 - if false { - } else if z.HasExtensions() && z.EncExt(x.FieldSelector) { - } else { - z.EncFallback(x.FieldSelector) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("FieldSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FieldSelector == nil { - r.EncodeNil() - } else { - yym3586 := z.EncBinary() - _ = yym3586 - if false { - } else if z.HasExtensions() && z.EncExt(x.FieldSelector) { - } else { - z.EncFallback(x.FieldSelector) - } - } - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3588 := z.EncBinary() - _ = yym3588 - if false { - } else { - r.EncodeBool(bool(x.Watch)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Watch")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3589 := z.EncBinary() - _ = yym3589 - if false { - } else { - r.EncodeBool(bool(x.Watch)) - } - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3591 := z.EncBinary() - _ = yym3591 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ResourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3592 := z.EncBinary() - _ = yym3592 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - if yyr3574 || yy2arr3574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.TimeoutSeconds == nil { - r.EncodeNil() - } else { - yy3594 := *x.TimeoutSeconds - yym3595 := z.EncBinary() - _ = yym3595 - if false { - } else { - r.EncodeInt(int64(yy3594)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("TimeoutSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TimeoutSeconds == nil { - r.EncodeNil() - } else { - yy3596 := *x.TimeoutSeconds - yym3597 := z.EncBinary() - _ = yym3597 - if false { - } else { - r.EncodeInt(int64(yy3596)) - } - } - } - if yyr3574 || yy2arr3574 { - 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 - yym3598 := z.DecBinary() - _ = yym3598 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3599 := r.ContainerType() - if yyct3599 == codecSelferValueTypeMap1234 { - yyl3599 := r.ReadMapStart() - if yyl3599 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3599, d) - } - } else if yyct3599 == codecSelferValueTypeArray1234 { - yyl3599 := r.ReadArrayStart() - if yyl3599 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3599, 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 yys3600Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3600Slc - var yyhl3600 bool = l >= 0 - for yyj3600 := 0; ; yyj3600++ { - if yyhl3600 { - if yyj3600 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3600Slc = r.DecodeBytes(yys3600Slc, true, true) - yys3600 := string(yys3600Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3600 { - 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 = nil - } else { - yyv3603 := &x.LabelSelector - yym3604 := z.DecBinary() - _ = yym3604 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3603) { - } else { - z.DecFallback(yyv3603, true) - } - } - case "FieldSelector": - if r.TryDecodeAsNil() { - x.FieldSelector = nil - } else { - yyv3605 := &x.FieldSelector - yym3606 := z.DecBinary() - _ = yym3606 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3605) { - } else { - z.DecFallback(yyv3605, true) - } - } - 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) - } - yym3610 := z.DecBinary() - _ = yym3610 - if false { - } else { - *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3600) - } // end switch yys3600 - } // end for yyj3600 - 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 yyj3611 int - var yyb3611 bool - var yyhl3611 bool = l >= 0 - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LabelSelector = nil - } else { - yyv3614 := &x.LabelSelector - yym3615 := z.DecBinary() - _ = yym3615 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3614) { - } else { - z.DecFallback(yyv3614, true) - } - } - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FieldSelector = nil - } else { - yyv3616 := &x.FieldSelector - yym3617 := z.DecBinary() - _ = yym3617 - if false { - } else if z.HasExtensions() && z.DecExt(yyv3616) { - } else { - z.DecFallback(yyv3616, true) - } - } - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Watch = false - } else { - x.Watch = bool(r.DecodeBool()) - } - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - 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) - } - yym3621 := z.DecBinary() - _ = yym3621 - if false { - } else { - *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64)) - } - } - for { - yyj3611++ - if yyhl3611 { - yyb3611 = yyj3611 > l - } else { - yyb3611 = r.CheckBreak() - } - if yyb3611 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3611-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 { - yym3622 := z.EncBinary() - _ = yym3622 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3623 := !z.EncBinary() - yy2arr3623 := z.EncBasicHandle().StructToArray - var yyq3623 [10]bool - _, _, _ = yysep3623, yyq3623, yy2arr3623 - const yyr3623 bool = false - yyq3623[0] = x.Kind != "" - yyq3623[1] = x.APIVersion != "" - var yynn3623 int - if yyr3623 || yy2arr3623 { - r.EncodeArrayStart(10) - } else { - yynn3623 = 8 - for _, b := range yyq3623 { - if b { - yynn3623++ - } - } - r.EncodeMapStart(yynn3623) - yynn3623 = 0 - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3623[0] { - yym3625 := z.EncBinary() - _ = yym3625 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3623[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3626 := z.EncBinary() - _ = yym3626 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3623[1] { - yym3628 := z.EncBinary() - _ = yym3628 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3623[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3629 := z.EncBinary() - _ = yym3629 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3631 := z.EncBinary() - _ = yym3631 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Container")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3632 := z.EncBinary() - _ = yym3632 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3634 := z.EncBinary() - _ = yym3634 - if false { - } else { - r.EncodeBool(bool(x.Follow)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Follow")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3635 := z.EncBinary() - _ = yym3635 - if false { - } else { - r.EncodeBool(bool(x.Follow)) - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3637 := z.EncBinary() - _ = yym3637 - if false { - } else { - r.EncodeBool(bool(x.Previous)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Previous")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3638 := z.EncBinary() - _ = yym3638 - if false { - } else { - r.EncodeBool(bool(x.Previous)) - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.SinceSeconds == nil { - r.EncodeNil() - } else { - yy3640 := *x.SinceSeconds - yym3641 := z.EncBinary() - _ = yym3641 - if false { - } else { - r.EncodeInt(int64(yy3640)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("SinceSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SinceSeconds == nil { - r.EncodeNil() - } else { - yy3642 := *x.SinceSeconds - yym3643 := z.EncBinary() - _ = yym3643 - if false { - } else { - r.EncodeInt(int64(yy3642)) - } - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.SinceTime == nil { - r.EncodeNil() - } else { - yym3645 := z.EncBinary() - _ = yym3645 - if false { - } else if z.HasExtensions() && z.EncExt(x.SinceTime) { - } else if yym3645 { - z.EncBinaryMarshal(x.SinceTime) - } else if !yym3645 && z.IsJSONHandle() { - z.EncJSONMarshal(x.SinceTime) - } else { - z.EncFallback(x.SinceTime) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("SinceTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SinceTime == nil { - r.EncodeNil() - } else { - yym3646 := z.EncBinary() - _ = yym3646 - if false { - } else if z.HasExtensions() && z.EncExt(x.SinceTime) { - } else if yym3646 { - z.EncBinaryMarshal(x.SinceTime) - } else if !yym3646 && z.IsJSONHandle() { - z.EncJSONMarshal(x.SinceTime) - } else { - z.EncFallback(x.SinceTime) - } - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3648 := z.EncBinary() - _ = yym3648 - if false { - } else { - r.EncodeBool(bool(x.Timestamps)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Timestamps")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3649 := z.EncBinary() - _ = yym3649 - if false { - } else { - r.EncodeBool(bool(x.Timestamps)) - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.TailLines == nil { - r.EncodeNil() - } else { - yy3651 := *x.TailLines - yym3652 := z.EncBinary() - _ = yym3652 - if false { - } else { - r.EncodeInt(int64(yy3651)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("TailLines")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TailLines == nil { - r.EncodeNil() - } else { - yy3653 := *x.TailLines - yym3654 := z.EncBinary() - _ = yym3654 - if false { - } else { - r.EncodeInt(int64(yy3653)) - } - } - } - if yyr3623 || yy2arr3623 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.LimitBytes == nil { - r.EncodeNil() - } else { - yy3656 := *x.LimitBytes - yym3657 := z.EncBinary() - _ = yym3657 - if false { - } else { - r.EncodeInt(int64(yy3656)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("LimitBytes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LimitBytes == nil { - r.EncodeNil() - } else { - yy3658 := *x.LimitBytes - yym3659 := z.EncBinary() - _ = yym3659 - if false { - } else { - r.EncodeInt(int64(yy3658)) - } - } - } - if yyr3623 || yy2arr3623 { - 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 - yym3660 := z.DecBinary() - _ = yym3660 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3661 := r.ContainerType() - if yyct3661 == codecSelferValueTypeMap1234 { - yyl3661 := r.ReadMapStart() - if yyl3661 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3661, d) - } - } else if yyct3661 == codecSelferValueTypeArray1234 { - yyl3661 := r.ReadArrayStart() - if yyl3661 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3661, 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 yys3662Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3662Slc - var yyhl3662 bool = l >= 0 - for yyj3662 := 0; ; yyj3662++ { - if yyhl3662 { - if yyj3662 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3662Slc = r.DecodeBytes(yys3662Slc, true, true) - yys3662 := string(yys3662Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3662 { - 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) - } - yym3669 := z.DecBinary() - _ = yym3669 - 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) - } - yym3671 := z.DecBinary() - _ = yym3671 - if false { - } else if z.HasExtensions() && z.DecExt(x.SinceTime) { - } else if yym3671 { - z.DecBinaryUnmarshal(x.SinceTime) - } else if !yym3671 && 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) - } - yym3674 := z.DecBinary() - _ = yym3674 - 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) - } - yym3676 := z.DecBinary() - _ = yym3676 - if false { - } else { - *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64)) - } - } - default: - z.DecStructFieldNotFound(-1, yys3662) - } // end switch yys3662 - } // end for yyj3662 - 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 yyj3677 int - var yyb3677 bool - var yyhl3677 bool = l >= 0 - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Container = "" - } else { - x.Container = string(r.DecodeString()) - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Follow = false - } else { - x.Follow = bool(r.DecodeBool()) - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Previous = false - } else { - x.Previous = bool(r.DecodeBool()) - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - 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) - } - yym3684 := z.DecBinary() - _ = yym3684 - if false { - } else { - *((*int64)(x.SinceSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - 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) - } - yym3686 := z.DecBinary() - _ = yym3686 - if false { - } else if z.HasExtensions() && z.DecExt(x.SinceTime) { - } else if yym3686 { - z.DecBinaryUnmarshal(x.SinceTime) - } else if !yym3686 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.SinceTime) - } else { - z.DecFallback(x.SinceTime, false) - } - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Timestamps = false - } else { - x.Timestamps = bool(r.DecodeBool()) - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - 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) - } - yym3689 := z.DecBinary() - _ = yym3689 - if false { - } else { - *((*int64)(x.TailLines)) = int64(r.DecodeInt(64)) - } - } - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - 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) - } - yym3691 := z.DecBinary() - _ = yym3691 - if false { - } else { - *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64)) - } - } - for { - yyj3677++ - if yyhl3677 { - yyb3677 = yyj3677 > l - } else { - yyb3677 = r.CheckBreak() - } - if yyb3677 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3677-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 { - yym3692 := z.EncBinary() - _ = yym3692 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3693 := !z.EncBinary() - yy2arr3693 := z.EncBasicHandle().StructToArray - var yyq3693 [7]bool - _, _, _ = yysep3693, yyq3693, yy2arr3693 - const yyr3693 bool = false - yyq3693[0] = x.Kind != "" - yyq3693[1] = x.APIVersion != "" - yyq3693[2] = x.Stdin != false - yyq3693[3] = x.Stdout != false - yyq3693[4] = x.Stderr != false - yyq3693[5] = x.TTY != false - yyq3693[6] = x.Container != "" - var yynn3693 int - if yyr3693 || yy2arr3693 { - r.EncodeArrayStart(7) - } else { - yynn3693 = 0 - for _, b := range yyq3693 { - if b { - yynn3693++ - } - } - r.EncodeMapStart(yynn3693) - yynn3693 = 0 - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[0] { - yym3695 := z.EncBinary() - _ = yym3695 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3693[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3696 := z.EncBinary() - _ = yym3696 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[1] { - yym3698 := z.EncBinary() - _ = yym3698 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3693[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3699 := z.EncBinary() - _ = yym3699 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[2] { - yym3701 := z.EncBinary() - _ = yym3701 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3693[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdin")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3702 := z.EncBinary() - _ = yym3702 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[3] { - yym3704 := z.EncBinary() - _ = yym3704 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3693[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stdout")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3705 := z.EncBinary() - _ = yym3705 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[4] { - yym3707 := z.EncBinary() - _ = yym3707 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3693[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("stderr")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3708 := z.EncBinary() - _ = yym3708 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[5] { - yym3710 := z.EncBinary() - _ = yym3710 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq3693[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tty")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3711 := z.EncBinary() - _ = yym3711 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } - } - if yyr3693 || yy2arr3693 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3693[6] { - yym3713 := z.EncBinary() - _ = yym3713 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3693[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("container")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3714 := z.EncBinary() - _ = yym3714 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } - } - if yyr3693 || yy2arr3693 { - 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 - yym3715 := z.DecBinary() - _ = yym3715 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3716 := r.ContainerType() - if yyct3716 == codecSelferValueTypeMap1234 { - yyl3716 := r.ReadMapStart() - if yyl3716 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3716, d) - } - } else if yyct3716 == codecSelferValueTypeArray1234 { - yyl3716 := r.ReadArrayStart() - if yyl3716 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3716, 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 yys3717Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3717Slc - var yyhl3717 bool = l >= 0 - for yyj3717 := 0; ; yyj3717++ { - if yyhl3717 { - if yyj3717 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3717Slc = r.DecodeBytes(yys3717Slc, true, true) - yys3717 := string(yys3717Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3717 { - 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, yys3717) - } // end switch yys3717 - } // end for yyj3717 - 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 yyj3725 int - var yyb3725 bool - var yyhl3725 bool = l >= 0 - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdin = false - } else { - x.Stdin = bool(r.DecodeBool()) - } - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdout = false - } else { - x.Stdout = bool(r.DecodeBool()) - } - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stderr = false - } else { - x.Stderr = bool(r.DecodeBool()) - } - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TTY = false - } else { - x.TTY = bool(r.DecodeBool()) - } - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Container = "" - } else { - x.Container = string(r.DecodeString()) - } - for { - yyj3725++ - if yyhl3725 { - yyb3725 = yyj3725 > l - } else { - yyb3725 = r.CheckBreak() - } - if yyb3725 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3725-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 { - yym3733 := z.EncBinary() - _ = yym3733 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3734 := !z.EncBinary() - yy2arr3734 := z.EncBasicHandle().StructToArray - var yyq3734 [8]bool - _, _, _ = yysep3734, yyq3734, yy2arr3734 - const yyr3734 bool = false - yyq3734[0] = x.Kind != "" - yyq3734[1] = x.APIVersion != "" - var yynn3734 int - if yyr3734 || yy2arr3734 { - r.EncodeArrayStart(8) - } else { - yynn3734 = 6 - for _, b := range yyq3734 { - if b { - yynn3734++ - } - } - r.EncodeMapStart(yynn3734) - yynn3734 = 0 - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3734[0] { - yym3736 := z.EncBinary() - _ = yym3736 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3734[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3737 := z.EncBinary() - _ = yym3737 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3734[1] { - yym3739 := z.EncBinary() - _ = yym3739 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3734[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3740 := z.EncBinary() - _ = yym3740 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3742 := z.EncBinary() - _ = yym3742 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Stdin")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3743 := z.EncBinary() - _ = yym3743 - if false { - } else { - r.EncodeBool(bool(x.Stdin)) - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3745 := z.EncBinary() - _ = yym3745 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Stdout")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3746 := z.EncBinary() - _ = yym3746 - if false { - } else { - r.EncodeBool(bool(x.Stdout)) - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3748 := z.EncBinary() - _ = yym3748 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Stderr")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3749 := z.EncBinary() - _ = yym3749 - if false { - } else { - r.EncodeBool(bool(x.Stderr)) - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3751 := z.EncBinary() - _ = yym3751 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("TTY")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3752 := z.EncBinary() - _ = yym3752 - if false { - } else { - r.EncodeBool(bool(x.TTY)) - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3754 := z.EncBinary() - _ = yym3754 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Container")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3755 := z.EncBinary() - _ = yym3755 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Container)) - } - } - if yyr3734 || yy2arr3734 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Command == nil { - r.EncodeNil() - } else { - yym3757 := z.EncBinary() - _ = yym3757 - 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 { - yym3758 := z.EncBinary() - _ = yym3758 - if false { - } else { - z.F.EncSliceStringV(x.Command, false, e) - } - } - } - if yyr3734 || yy2arr3734 { - 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 - yym3759 := z.DecBinary() - _ = yym3759 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3760 := r.ContainerType() - if yyct3760 == codecSelferValueTypeMap1234 { - yyl3760 := r.ReadMapStart() - if yyl3760 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3760, d) - } - } else if yyct3760 == codecSelferValueTypeArray1234 { - yyl3760 := r.ReadArrayStart() - if yyl3760 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3760, 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 yys3761Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3761Slc - var yyhl3761 bool = l >= 0 - for yyj3761 := 0; ; yyj3761++ { - if yyhl3761 { - if yyj3761 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3761Slc = r.DecodeBytes(yys3761Slc, true, true) - yys3761 := string(yys3761Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3761 { - 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 { - yyv3769 := &x.Command - yym3770 := z.DecBinary() - _ = yym3770 - if false { - } else { - z.F.DecSliceStringX(yyv3769, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys3761) - } // end switch yys3761 - } // end for yyj3761 - 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 yyj3771 int - var yyb3771 bool - var yyhl3771 bool = l >= 0 - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdin = false - } else { - x.Stdin = bool(r.DecodeBool()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stdout = false - } else { - x.Stdout = bool(r.DecodeBool()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Stderr = false - } else { - x.Stderr = bool(r.DecodeBool()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TTY = false - } else { - x.TTY = bool(r.DecodeBool()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Container = "" - } else { - x.Container = string(r.DecodeString()) - } - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Command = nil - } else { - yyv3779 := &x.Command - yym3780 := z.DecBinary() - _ = yym3780 - if false { - } else { - z.F.DecSliceStringX(yyv3779, false, d) - } - } - for { - yyj3771++ - if yyhl3771 { - yyb3771 = yyj3771 > l - } else { - yyb3771 = r.CheckBreak() - } - if yyb3771 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3771-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 { - yym3781 := z.EncBinary() - _ = yym3781 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3782 := !z.EncBinary() - yy2arr3782 := z.EncBasicHandle().StructToArray - var yyq3782 [3]bool - _, _, _ = yysep3782, yyq3782, yy2arr3782 - const yyr3782 bool = false - yyq3782[0] = x.Kind != "" - yyq3782[1] = x.APIVersion != "" - var yynn3782 int - if yyr3782 || yy2arr3782 { - r.EncodeArrayStart(3) - } else { - yynn3782 = 1 - for _, b := range yyq3782 { - if b { - yynn3782++ - } - } - r.EncodeMapStart(yynn3782) - yynn3782 = 0 - } - if yyr3782 || yy2arr3782 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3782[0] { - yym3784 := z.EncBinary() - _ = yym3784 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3782[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3785 := z.EncBinary() - _ = yym3785 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3782 || yy2arr3782 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3782[1] { - yym3787 := z.EncBinary() - _ = yym3787 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3782[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3788 := z.EncBinary() - _ = yym3788 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3782 || yy2arr3782 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3790 := z.EncBinary() - _ = yym3790 - 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) - yym3791 := z.EncBinary() - _ = yym3791 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr3782 || yy2arr3782 { - 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 - yym3792 := z.DecBinary() - _ = yym3792 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3793 := r.ContainerType() - if yyct3793 == codecSelferValueTypeMap1234 { - yyl3793 := r.ReadMapStart() - if yyl3793 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3793, d) - } - } else if yyct3793 == codecSelferValueTypeArray1234 { - yyl3793 := r.ReadArrayStart() - if yyl3793 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3793, 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 yys3794Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3794Slc - var yyhl3794 bool = l >= 0 - for yyj3794 := 0; ; yyj3794++ { - if yyhl3794 { - if yyj3794 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3794Slc = r.DecodeBytes(yys3794Slc, true, true) - yys3794 := string(yys3794Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3794 { - 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, yys3794) - } // end switch yys3794 - } // end for yyj3794 - 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 yyj3798 int - var yyb3798 bool - var yyhl3798 bool = l >= 0 - yyj3798++ - if yyhl3798 { - yyb3798 = yyj3798 > l - } else { - yyb3798 = r.CheckBreak() - } - if yyb3798 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3798++ - if yyhl3798 { - yyb3798 = yyj3798 > l - } else { - yyb3798 = r.CheckBreak() - } - if yyb3798 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3798++ - if yyhl3798 { - yyb3798 = yyj3798 > l - } else { - yyb3798 = r.CheckBreak() - } - if yyb3798 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3798++ - if yyhl3798 { - yyb3798 = yyj3798 > l - } else { - yyb3798 = r.CheckBreak() - } - if yyb3798 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3798-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 { - yym3802 := z.EncBinary() - _ = yym3802 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3803 := !z.EncBinary() - yy2arr3803 := z.EncBasicHandle().StructToArray - var yyq3803 [3]bool - _, _, _ = yysep3803, yyq3803, yy2arr3803 - const yyr3803 bool = false - yyq3803[0] = x.Kind != "" - yyq3803[1] = x.APIVersion != "" - var yynn3803 int - if yyr3803 || yy2arr3803 { - r.EncodeArrayStart(3) - } else { - yynn3803 = 1 - for _, b := range yyq3803 { - if b { - yynn3803++ - } - } - r.EncodeMapStart(yynn3803) - yynn3803 = 0 - } - if yyr3803 || yy2arr3803 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3803[0] { - yym3805 := z.EncBinary() - _ = yym3805 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3803[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3806 := z.EncBinary() - _ = yym3806 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3803 || yy2arr3803 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3803[1] { - yym3808 := z.EncBinary() - _ = yym3808 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3803[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3809 := z.EncBinary() - _ = yym3809 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3803 || yy2arr3803 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3811 := z.EncBinary() - _ = yym3811 - 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) - yym3812 := z.EncBinary() - _ = yym3812 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr3803 || yy2arr3803 { - 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 - yym3813 := z.DecBinary() - _ = yym3813 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3814 := r.ContainerType() - if yyct3814 == codecSelferValueTypeMap1234 { - yyl3814 := r.ReadMapStart() - if yyl3814 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3814, d) - } - } else if yyct3814 == codecSelferValueTypeArray1234 { - yyl3814 := r.ReadArrayStart() - if yyl3814 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3814, 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 yys3815Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3815Slc - var yyhl3815 bool = l >= 0 - for yyj3815 := 0; ; yyj3815++ { - if yyhl3815 { - if yyj3815 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3815Slc = r.DecodeBytes(yys3815Slc, true, true) - yys3815 := string(yys3815Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3815 { - 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, yys3815) - } // end switch yys3815 - } // end for yyj3815 - 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 yyj3819 int - var yyb3819 bool - var yyhl3819 bool = l >= 0 - yyj3819++ - if yyhl3819 { - yyb3819 = yyj3819 > l - } else { - yyb3819 = r.CheckBreak() - } - if yyb3819 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3819++ - if yyhl3819 { - yyb3819 = yyj3819 > l - } else { - yyb3819 = r.CheckBreak() - } - if yyb3819 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3819++ - if yyhl3819 { - yyb3819 = yyj3819 > l - } else { - yyb3819 = r.CheckBreak() - } - if yyb3819 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3819++ - if yyhl3819 { - yyb3819 = yyj3819 > l - } else { - yyb3819 = r.CheckBreak() - } - if yyb3819 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3819-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 { - yym3823 := z.EncBinary() - _ = yym3823 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3824 := !z.EncBinary() - yy2arr3824 := z.EncBasicHandle().StructToArray - var yyq3824 [3]bool - _, _, _ = yysep3824, yyq3824, yy2arr3824 - const yyr3824 bool = false - yyq3824[0] = x.Kind != "" - yyq3824[1] = x.APIVersion != "" - var yynn3824 int - if yyr3824 || yy2arr3824 { - r.EncodeArrayStart(3) - } else { - yynn3824 = 1 - for _, b := range yyq3824 { - if b { - yynn3824++ - } - } - r.EncodeMapStart(yynn3824) - yynn3824 = 0 - } - if yyr3824 || yy2arr3824 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3824[0] { - yym3826 := z.EncBinary() - _ = yym3826 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3824[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3827 := z.EncBinary() - _ = yym3827 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3824 || yy2arr3824 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3824[1] { - yym3829 := z.EncBinary() - _ = yym3829 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3824[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3830 := z.EncBinary() - _ = yym3830 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3824 || yy2arr3824 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3832 := z.EncBinary() - _ = yym3832 - 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) - yym3833 := z.EncBinary() - _ = yym3833 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr3824 || yy2arr3824 { - 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 - yym3834 := z.DecBinary() - _ = yym3834 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3835 := r.ContainerType() - if yyct3835 == codecSelferValueTypeMap1234 { - yyl3835 := r.ReadMapStart() - if yyl3835 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3835, d) - } - } else if yyct3835 == codecSelferValueTypeArray1234 { - yyl3835 := r.ReadArrayStart() - if yyl3835 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3835, 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 yys3836Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3836Slc - var yyhl3836 bool = l >= 0 - for yyj3836 := 0; ; yyj3836++ { - if yyhl3836 { - if yyj3836 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3836Slc = r.DecodeBytes(yys3836Slc, true, true) - yys3836 := string(yys3836Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3836 { - 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, yys3836) - } // end switch yys3836 - } // end for yyj3836 - 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 yyj3840 int - var yyb3840 bool - var yyhl3840 bool = l >= 0 - yyj3840++ - if yyhl3840 { - yyb3840 = yyj3840 > l - } else { - yyb3840 = r.CheckBreak() - } - if yyb3840 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3840++ - if yyhl3840 { - yyb3840 = yyj3840 > l - } else { - yyb3840 = r.CheckBreak() - } - if yyb3840 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3840++ - if yyhl3840 { - yyb3840 = yyj3840 > l - } else { - yyb3840 = r.CheckBreak() - } - if yyb3840 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3840++ - if yyhl3840 { - yyb3840 = yyj3840 > l - } else { - yyb3840 = r.CheckBreak() - } - if yyb3840 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3840-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 { - yym3844 := z.EncBinary() - _ = yym3844 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3845 := !z.EncBinary() - yy2arr3845 := z.EncBasicHandle().StructToArray - var yyq3845 [5]bool - _, _, _ = yysep3845, yyq3845, yy2arr3845 - const yyr3845 bool = false - yyq3845[4] = x.Controller != nil - var yynn3845 int - if yyr3845 || yy2arr3845 { - r.EncodeArrayStart(5) - } else { - yynn3845 = 4 - for _, b := range yyq3845 { - if b { - yynn3845++ - } - } - r.EncodeMapStart(yynn3845) - yynn3845 = 0 - } - if yyr3845 || yy2arr3845 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3847 := z.EncBinary() - _ = yym3847 - 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) - yym3848 := z.EncBinary() - _ = yym3848 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - if yyr3845 || yy2arr3845 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3850 := z.EncBinary() - _ = yym3850 - 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) - yym3851 := z.EncBinary() - _ = yym3851 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - if yyr3845 || yy2arr3845 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3853 := z.EncBinary() - _ = yym3853 - 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) - yym3854 := z.EncBinary() - _ = yym3854 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr3845 || yy2arr3845 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3856 := z.EncBinary() - _ = yym3856 - 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) - yym3857 := z.EncBinary() - _ = yym3857 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - if yyr3845 || yy2arr3845 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3845[4] { - if x.Controller == nil { - r.EncodeNil() - } else { - yy3859 := *x.Controller - yym3860 := z.EncBinary() - _ = yym3860 - if false { - } else { - r.EncodeBool(bool(yy3859)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3845[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("controller")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Controller == nil { - r.EncodeNil() - } else { - yy3861 := *x.Controller - yym3862 := z.EncBinary() - _ = yym3862 - if false { - } else { - r.EncodeBool(bool(yy3861)) - } - } - } - } - if yyr3845 || yy2arr3845 { - 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 - 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 *OwnerReference) 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 "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) - } - yym3871 := z.DecBinary() - _ = yym3871 - if false { - } else { - *((*bool)(x.Controller)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3865) - } // end switch yys3865 - } // end for yyj3865 - 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 yyj3872 int - var yyb3872 bool - var yyhl3872 bool = l >= 0 - yyj3872++ - if yyhl3872 { - yyb3872 = yyj3872 > l - } else { - yyb3872 = r.CheckBreak() - } - if yyb3872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3872++ - if yyhl3872 { - yyb3872 = yyj3872 > l - } else { - yyb3872 = r.CheckBreak() - } - if yyb3872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3872++ - if yyhl3872 { - yyb3872 = yyj3872 > l - } else { - yyb3872 = r.CheckBreak() - } - if yyb3872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj3872++ - if yyhl3872 { - yyb3872 = yyj3872 > l - } else { - yyb3872 = r.CheckBreak() - } - if yyb3872 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg1_types.UID(r.DecodeString()) - } - yyj3872++ - if yyhl3872 { - yyb3872 = yyj3872 > l - } else { - yyb3872 = r.CheckBreak() - } - if yyb3872 { - 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) - } - yym3878 := z.DecBinary() - _ = yym3878 - if false { - } else { - *((*bool)(x.Controller)) = r.DecodeBool() - } - } - for { - yyj3872++ - if yyhl3872 { - yyb3872 = yyj3872 > l - } else { - yyb3872 = r.CheckBreak() - } - if yyb3872 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3872-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 { - yym3879 := z.EncBinary() - _ = yym3879 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3880 := !z.EncBinary() - yy2arr3880 := z.EncBasicHandle().StructToArray - var yyq3880 [7]bool - _, _, _ = yysep3880, yyq3880, yy2arr3880 - const yyr3880 bool = false - yyq3880[0] = x.Kind != "" - yyq3880[1] = x.Namespace != "" - yyq3880[2] = x.Name != "" - yyq3880[3] = x.UID != "" - yyq3880[4] = x.APIVersion != "" - yyq3880[5] = x.ResourceVersion != "" - yyq3880[6] = x.FieldPath != "" - var yynn3880 int - if yyr3880 || yy2arr3880 { - r.EncodeArrayStart(7) - } else { - yynn3880 = 0 - for _, b := range yyq3880 { - if b { - yynn3880++ - } - } - r.EncodeMapStart(yynn3880) - yynn3880 = 0 - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[0] { - yym3882 := z.EncBinary() - _ = yym3882 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3880[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3883 := z.EncBinary() - _ = yym3883 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[1] { - yym3885 := z.EncBinary() - _ = yym3885 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3880[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3886 := z.EncBinary() - _ = yym3886 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[2] { - yym3888 := z.EncBinary() - _ = yym3888 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3880[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3889 := z.EncBinary() - _ = yym3889 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[3] { - yym3891 := z.EncBinary() - _ = yym3891 - 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 yyq3880[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3892 := z.EncBinary() - _ = yym3892 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[4] { - yym3894 := z.EncBinary() - _ = yym3894 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3880[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3895 := z.EncBinary() - _ = yym3895 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[5] { - yym3897 := z.EncBinary() - _ = yym3897 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3880[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3898 := z.EncBinary() - _ = yym3898 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr3880 || yy2arr3880 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3880[6] { - yym3900 := z.EncBinary() - _ = yym3900 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3880[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fieldPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3901 := z.EncBinary() - _ = yym3901 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) - } - } - } - if yyr3880 || yy2arr3880 { - 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 - yym3902 := z.DecBinary() - _ = yym3902 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3903 := r.ContainerType() - if yyct3903 == codecSelferValueTypeMap1234 { - yyl3903 := r.ReadMapStart() - if yyl3903 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3903, d) - } - } else if yyct3903 == codecSelferValueTypeArray1234 { - yyl3903 := r.ReadArrayStart() - if yyl3903 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3903, 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 yys3904Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3904Slc - var yyhl3904 bool = l >= 0 - for yyj3904 := 0; ; yyj3904++ { - if yyhl3904 { - if yyj3904 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3904Slc = r.DecodeBytes(yys3904Slc, true, true) - yys3904 := string(yys3904Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3904 { - 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, yys3904) - } // end switch yys3904 - } // end for yyj3904 - 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 yyj3912 int - var yyb3912 bool - var yyhl3912 bool = l >= 0 - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg1_types.UID(r.DecodeString()) - } - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FieldPath = "" - } else { - x.FieldPath = string(r.DecodeString()) - } - for { - yyj3912++ - if yyhl3912 { - yyb3912 = yyj3912 > l - } else { - yyb3912 = r.CheckBreak() - } - if yyb3912 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3912-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 { - yym3920 := z.EncBinary() - _ = yym3920 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3921 := !z.EncBinary() - yy2arr3921 := z.EncBasicHandle().StructToArray - var yyq3921 [1]bool - _, _, _ = yysep3921, yyq3921, yy2arr3921 - const yyr3921 bool = false - var yynn3921 int - if yyr3921 || yy2arr3921 { - r.EncodeArrayStart(1) - } else { - yynn3921 = 1 - for _, b := range yyq3921 { - if b { - yynn3921++ - } - } - r.EncodeMapStart(yynn3921) - yynn3921 = 0 - } - if yyr3921 || yy2arr3921 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3923 := z.EncBinary() - _ = yym3923 - 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) - yym3924 := z.EncBinary() - _ = yym3924 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr3921 || yy2arr3921 { - 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 - yym3925 := z.DecBinary() - _ = yym3925 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3926 := r.ContainerType() - if yyct3926 == codecSelferValueTypeMap1234 { - yyl3926 := r.ReadMapStart() - if yyl3926 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3926, d) - } - } else if yyct3926 == codecSelferValueTypeArray1234 { - yyl3926 := r.ReadArrayStart() - if yyl3926 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3926, 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 yys3927Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3927Slc - var yyhl3927 bool = l >= 0 - for yyj3927 := 0; ; yyj3927++ { - if yyhl3927 { - if yyj3927 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3927Slc = r.DecodeBytes(yys3927Slc, true, true) - yys3927 := string(yys3927Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3927 { - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys3927) - } // end switch yys3927 - } // end for yyj3927 - 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 yyj3929 int - var yyb3929 bool - var yyhl3929 bool = l >= 0 - yyj3929++ - if yyhl3929 { - yyb3929 = yyj3929 > l - } else { - yyb3929 = r.CheckBreak() - } - if yyb3929 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - for { - yyj3929++ - if yyhl3929 { - yyb3929 = yyj3929 > l - } else { - yyb3929 = r.CheckBreak() - } - if yyb3929 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3929-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 { - yym3931 := z.EncBinary() - _ = yym3931 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3932 := !z.EncBinary() - yy2arr3932 := z.EncBasicHandle().StructToArray - var yyq3932 [3]bool - _, _, _ = yysep3932, yyq3932, yy2arr3932 - const yyr3932 bool = false - yyq3932[0] = x.Kind != "" - yyq3932[1] = x.APIVersion != "" - yyq3932[2] = true - var yynn3932 int - if yyr3932 || yy2arr3932 { - r.EncodeArrayStart(3) - } else { - yynn3932 = 0 - for _, b := range yyq3932 { - if b { - yynn3932++ - } - } - r.EncodeMapStart(yynn3932) - yynn3932 = 0 - } - if yyr3932 || yy2arr3932 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3932[0] { - yym3934 := z.EncBinary() - _ = yym3934 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3932[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3935 := z.EncBinary() - _ = yym3935 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3932 || yy2arr3932 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3932[1] { - yym3937 := z.EncBinary() - _ = yym3937 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3932[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3938 := z.EncBinary() - _ = yym3938 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3932 || yy2arr3932 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3932[2] { - yy3940 := &x.Reference - yy3940.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3932[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reference")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3941 := &x.Reference - yy3941.CodecEncodeSelf(e) - } - } - if yyr3932 || yy2arr3932 { - 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 - yym3942 := z.DecBinary() - _ = yym3942 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3943 := r.ContainerType() - if yyct3943 == codecSelferValueTypeMap1234 { - yyl3943 := r.ReadMapStart() - if yyl3943 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3943, d) - } - } else if yyct3943 == codecSelferValueTypeArray1234 { - yyl3943 := r.ReadArrayStart() - if yyl3943 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3943, 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 yys3944Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3944Slc - var yyhl3944 bool = l >= 0 - for yyj3944 := 0; ; yyj3944++ { - if yyhl3944 { - if yyj3944 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3944Slc = r.DecodeBytes(yys3944Slc, true, true) - yys3944 := string(yys3944Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3944 { - 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 { - yyv3947 := &x.Reference - yyv3947.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys3944) - } // end switch yys3944 - } // end for yyj3944 - 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 yyj3948 int - var yyb3948 bool - var yyhl3948 bool = l >= 0 - yyj3948++ - if yyhl3948 { - yyb3948 = yyj3948 > l - } else { - yyb3948 = r.CheckBreak() - } - if yyb3948 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3948++ - if yyhl3948 { - yyb3948 = yyj3948 > l - } else { - yyb3948 = r.CheckBreak() - } - if yyb3948 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3948++ - if yyhl3948 { - yyb3948 = yyj3948 > l - } else { - yyb3948 = r.CheckBreak() - } - if yyb3948 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reference = ObjectReference{} - } else { - yyv3951 := &x.Reference - yyv3951.CodecDecodeSelf(d) - } - for { - yyj3948++ - if yyhl3948 { - yyb3948 = yyj3948 > l - } else { - yyb3948 = r.CheckBreak() - } - if yyb3948 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3948-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 { - yym3952 := z.EncBinary() - _ = yym3952 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3953 := !z.EncBinary() - yy2arr3953 := z.EncBasicHandle().StructToArray - var yyq3953 [2]bool - _, _, _ = yysep3953, yyq3953, yy2arr3953 - const yyr3953 bool = false - yyq3953[0] = x.Component != "" - yyq3953[1] = x.Host != "" - var yynn3953 int - if yyr3953 || yy2arr3953 { - r.EncodeArrayStart(2) - } else { - yynn3953 = 0 - for _, b := range yyq3953 { - if b { - yynn3953++ - } - } - r.EncodeMapStart(yynn3953) - yynn3953 = 0 - } - if yyr3953 || yy2arr3953 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3953[0] { - yym3955 := z.EncBinary() - _ = yym3955 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Component)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3953[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("component")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3956 := z.EncBinary() - _ = yym3956 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Component)) - } - } - } - if yyr3953 || yy2arr3953 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3953[1] { - yym3958 := z.EncBinary() - _ = yym3958 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3953[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("host")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3959 := z.EncBinary() - _ = yym3959 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } - } - if yyr3953 || yy2arr3953 { - 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 - yym3960 := z.DecBinary() - _ = yym3960 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3961 := r.ContainerType() - if yyct3961 == codecSelferValueTypeMap1234 { - yyl3961 := r.ReadMapStart() - if yyl3961 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3961, d) - } - } else if yyct3961 == codecSelferValueTypeArray1234 { - yyl3961 := r.ReadArrayStart() - if yyl3961 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3961, 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 yys3962Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3962Slc - var yyhl3962 bool = l >= 0 - for yyj3962 := 0; ; yyj3962++ { - if yyhl3962 { - if yyj3962 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3962Slc = r.DecodeBytes(yys3962Slc, true, true) - yys3962 := string(yys3962Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3962 { - 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, yys3962) - } // end switch yys3962 - } // end for yyj3962 - 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 yyj3965 int - var yyb3965 bool - var yyhl3965 bool = l >= 0 - yyj3965++ - if yyhl3965 { - yyb3965 = yyj3965 > l - } else { - yyb3965 = r.CheckBreak() - } - if yyb3965 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Component = "" - } else { - x.Component = string(r.DecodeString()) - } - yyj3965++ - if yyhl3965 { - yyb3965 = yyj3965 > l - } else { - yyb3965 = r.CheckBreak() - } - if yyb3965 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Host = "" - } else { - x.Host = string(r.DecodeString()) - } - for { - yyj3965++ - if yyhl3965 { - yyb3965 = yyj3965 > l - } else { - yyb3965 = r.CheckBreak() - } - if yyb3965 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3965-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 { - yym3968 := z.EncBinary() - _ = yym3968 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3969 := !z.EncBinary() - yy2arr3969 := z.EncBasicHandle().StructToArray - var yyq3969 [11]bool - _, _, _ = yysep3969, yyq3969, yy2arr3969 - const yyr3969 bool = false - yyq3969[0] = x.Kind != "" - yyq3969[1] = x.APIVersion != "" - yyq3969[2] = true - yyq3969[3] = true - yyq3969[4] = x.Reason != "" - yyq3969[5] = x.Message != "" - yyq3969[6] = true - yyq3969[7] = true - yyq3969[8] = true - yyq3969[9] = x.Count != 0 - yyq3969[10] = x.Type != "" - var yynn3969 int - if yyr3969 || yy2arr3969 { - r.EncodeArrayStart(11) - } else { - yynn3969 = 0 - for _, b := range yyq3969 { - if b { - yynn3969++ - } - } - r.EncodeMapStart(yynn3969) - yynn3969 = 0 - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[0] { - yym3971 := z.EncBinary() - _ = yym3971 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3969[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3972 := z.EncBinary() - _ = yym3972 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[1] { - yym3974 := z.EncBinary() - _ = yym3974 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3969[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3975 := z.EncBinary() - _ = yym3975 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[2] { - yy3977 := &x.ObjectMeta - yy3977.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3969[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3978 := &x.ObjectMeta - yy3978.CodecEncodeSelf(e) - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[3] { - yy3980 := &x.InvolvedObject - yy3980.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3969[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("involvedObject")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3981 := &x.InvolvedObject - yy3981.CodecEncodeSelf(e) - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[4] { - yym3983 := z.EncBinary() - _ = yym3983 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3969[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3984 := z.EncBinary() - _ = yym3984 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[5] { - yym3986 := z.EncBinary() - _ = yym3986 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3969[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3987 := z.EncBinary() - _ = yym3987 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[6] { - yy3989 := &x.Source - yy3989.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq3969[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("source")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3990 := &x.Source - yy3990.CodecEncodeSelf(e) - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[7] { - yy3992 := &x.FirstTimestamp - yym3993 := z.EncBinary() - _ = yym3993 - if false { - } else if z.HasExtensions() && z.EncExt(yy3992) { - } else if yym3993 { - z.EncBinaryMarshal(yy3992) - } else if !yym3993 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3992) - } else { - z.EncFallback(yy3992) - } - } else { - r.EncodeNil() - } - } else { - if yyq3969[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("firstTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3994 := &x.FirstTimestamp - yym3995 := z.EncBinary() - _ = yym3995 - if false { - } else if z.HasExtensions() && z.EncExt(yy3994) { - } else if yym3995 { - z.EncBinaryMarshal(yy3994) - } else if !yym3995 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3994) - } else { - z.EncFallback(yy3994) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[8] { - yy3997 := &x.LastTimestamp - yym3998 := z.EncBinary() - _ = yym3998 - if false { - } else if z.HasExtensions() && z.EncExt(yy3997) { - } else if yym3998 { - z.EncBinaryMarshal(yy3997) - } else if !yym3998 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3997) - } else { - z.EncFallback(yy3997) - } - } else { - r.EncodeNil() - } - } else { - if yyq3969[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3999 := &x.LastTimestamp - yym4000 := z.EncBinary() - _ = yym4000 - if false { - } else if z.HasExtensions() && z.EncExt(yy3999) { - } else if yym4000 { - z.EncBinaryMarshal(yy3999) - } else if !yym4000 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3999) - } else { - z.EncFallback(yy3999) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[9] { - yym4002 := z.EncBinary() - _ = yym4002 - if false { - } else { - r.EncodeInt(int64(x.Count)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq3969[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("count")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4003 := z.EncBinary() - _ = yym4003 - if false { - } else { - r.EncodeInt(int64(x.Count)) - } - } - } - if yyr3969 || yy2arr3969 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3969[10] { - yym4005 := z.EncBinary() - _ = yym4005 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3969[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4006 := z.EncBinary() - _ = yym4006 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } - } - if yyr3969 || yy2arr3969 { - 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 - yym4007 := z.DecBinary() - _ = yym4007 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4008 := r.ContainerType() - if yyct4008 == codecSelferValueTypeMap1234 { - yyl4008 := r.ReadMapStart() - if yyl4008 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4008, d) - } - } else if yyct4008 == codecSelferValueTypeArray1234 { - yyl4008 := r.ReadArrayStart() - if yyl4008 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4008, 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 yys4009Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4009Slc - var yyhl4009 bool = l >= 0 - for yyj4009 := 0; ; yyj4009++ { - if yyhl4009 { - if yyj4009 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4009Slc = r.DecodeBytes(yys4009Slc, true, true) - yys4009 := string(yys4009Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4009 { - 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 { - yyv4012 := &x.ObjectMeta - yyv4012.CodecDecodeSelf(d) - } - case "involvedObject": - if r.TryDecodeAsNil() { - x.InvolvedObject = ObjectReference{} - } else { - yyv4013 := &x.InvolvedObject - yyv4013.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 { - yyv4016 := &x.Source - yyv4016.CodecDecodeSelf(d) - } - case "firstTimestamp": - if r.TryDecodeAsNil() { - x.FirstTimestamp = pkg2_unversioned.Time{} - } else { - yyv4017 := &x.FirstTimestamp - yym4018 := z.DecBinary() - _ = yym4018 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4017) { - } else if yym4018 { - z.DecBinaryUnmarshal(yyv4017) - } else if !yym4018 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4017) - } else { - z.DecFallback(yyv4017, false) - } - } - case "lastTimestamp": - if r.TryDecodeAsNil() { - x.LastTimestamp = pkg2_unversioned.Time{} - } else { - yyv4019 := &x.LastTimestamp - yym4020 := z.DecBinary() - _ = yym4020 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4019) { - } else if yym4020 { - z.DecBinaryUnmarshal(yyv4019) - } else if !yym4020 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4019) - } else { - z.DecFallback(yyv4019, 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, yys4009) - } // end switch yys4009 - } // end for yyj4009 - 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 yyj4023 int - var yyb4023 bool - var yyhl4023 bool = l >= 0 - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4026 := &x.ObjectMeta - yyv4026.CodecDecodeSelf(d) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.InvolvedObject = ObjectReference{} - } else { - yyv4027 := &x.InvolvedObject - yyv4027.CodecDecodeSelf(d) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Source = EventSource{} - } else { - yyv4030 := &x.Source - yyv4030.CodecDecodeSelf(d) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FirstTimestamp = pkg2_unversioned.Time{} - } else { - yyv4031 := &x.FirstTimestamp - yym4032 := z.DecBinary() - _ = yym4032 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4031) { - } else if yym4032 { - z.DecBinaryUnmarshal(yyv4031) - } else if !yym4032 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4031) - } else { - z.DecFallback(yyv4031, false) - } - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTimestamp = pkg2_unversioned.Time{} - } else { - yyv4033 := &x.LastTimestamp - yym4034 := z.DecBinary() - _ = yym4034 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4033) { - } else if yym4034 { - z.DecBinaryUnmarshal(yyv4033) - } else if !yym4034 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4033) - } else { - z.DecFallback(yyv4033, false) - } - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Count = 0 - } else { - x.Count = int32(r.DecodeInt(32)) - } - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = string(r.DecodeString()) - } - for { - yyj4023++ - if yyhl4023 { - yyb4023 = yyj4023 > l - } else { - yyb4023 = r.CheckBreak() - } - if yyb4023 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4023-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 { - yym4037 := z.EncBinary() - _ = yym4037 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4038 := !z.EncBinary() - yy2arr4038 := z.EncBasicHandle().StructToArray - var yyq4038 [4]bool - _, _, _ = yysep4038, yyq4038, yy2arr4038 - const yyr4038 bool = false - yyq4038[0] = x.Kind != "" - yyq4038[1] = x.APIVersion != "" - yyq4038[2] = true - var yynn4038 int - if yyr4038 || yy2arr4038 { - r.EncodeArrayStart(4) - } else { - yynn4038 = 1 - for _, b := range yyq4038 { - if b { - yynn4038++ - } - } - r.EncodeMapStart(yynn4038) - yynn4038 = 0 - } - if yyr4038 || yy2arr4038 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4038[0] { - yym4040 := z.EncBinary() - _ = yym4040 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4038[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4041 := z.EncBinary() - _ = yym4041 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4038 || yy2arr4038 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4038[1] { - yym4043 := z.EncBinary() - _ = yym4043 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4038[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4044 := z.EncBinary() - _ = yym4044 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4038 || yy2arr4038 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4038[2] { - yy4046 := &x.ListMeta - yym4047 := z.EncBinary() - _ = yym4047 - if false { - } else if z.HasExtensions() && z.EncExt(yy4046) { - } else { - z.EncFallback(yy4046) - } - } else { - r.EncodeNil() - } - } else { - if yyq4038[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4048 := &x.ListMeta - yym4049 := z.EncBinary() - _ = yym4049 - if false { - } else if z.HasExtensions() && z.EncExt(yy4048) { - } else { - z.EncFallback(yy4048) - } - } - } - if yyr4038 || yy2arr4038 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4051 := z.EncBinary() - _ = yym4051 - 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 { - yym4052 := z.EncBinary() - _ = yym4052 - if false { - } else { - h.encSliceEvent(([]Event)(x.Items), e) - } - } - } - if yyr4038 || yy2arr4038 { - 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 - yym4053 := z.DecBinary() - _ = yym4053 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4054 := r.ContainerType() - if yyct4054 == codecSelferValueTypeMap1234 { - yyl4054 := r.ReadMapStart() - if yyl4054 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4054, d) - } - } else if yyct4054 == codecSelferValueTypeArray1234 { - yyl4054 := r.ReadArrayStart() - if yyl4054 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4054, 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 yys4055Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4055Slc - var yyhl4055 bool = l >= 0 - for yyj4055 := 0; ; yyj4055++ { - if yyhl4055 { - if yyj4055 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4055Slc = r.DecodeBytes(yys4055Slc, true, true) - yys4055 := string(yys4055Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4055 { - 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 { - yyv4058 := &x.ListMeta - yym4059 := z.DecBinary() - _ = yym4059 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4058) { - } else { - z.DecFallback(yyv4058, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4060 := &x.Items - yym4061 := z.DecBinary() - _ = yym4061 - if false { - } else { - h.decSliceEvent((*[]Event)(yyv4060), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4055) - } // end switch yys4055 - } // end for yyj4055 - 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 yyj4062 int - var yyb4062 bool - var yyhl4062 bool = l >= 0 - yyj4062++ - if yyhl4062 { - yyb4062 = yyj4062 > l - } else { - yyb4062 = r.CheckBreak() - } - if yyb4062 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4062++ - if yyhl4062 { - yyb4062 = yyj4062 > l - } else { - yyb4062 = r.CheckBreak() - } - if yyb4062 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4062++ - if yyhl4062 { - yyb4062 = yyj4062 > l - } else { - yyb4062 = r.CheckBreak() - } - if yyb4062 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4065 := &x.ListMeta - yym4066 := z.DecBinary() - _ = yym4066 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4065) { - } else { - z.DecFallback(yyv4065, false) - } - } - yyj4062++ - if yyhl4062 { - yyb4062 = yyj4062 > l - } else { - yyb4062 = r.CheckBreak() - } - if yyb4062 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4067 := &x.Items - yym4068 := z.DecBinary() - _ = yym4068 - if false { - } else { - h.decSliceEvent((*[]Event)(yyv4067), d) - } - } - for { - yyj4062++ - if yyhl4062 { - yyb4062 = yyj4062 > l - } else { - yyb4062 = r.CheckBreak() - } - if yyb4062 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4062-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 { - yym4069 := z.EncBinary() - _ = yym4069 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4070 := !z.EncBinary() - yy2arr4070 := z.EncBasicHandle().StructToArray - var yyq4070 [4]bool - _, _, _ = yysep4070, yyq4070, yy2arr4070 - const yyr4070 bool = false - yyq4070[0] = x.Kind != "" - yyq4070[1] = x.APIVersion != "" - yyq4070[2] = true - var yynn4070 int - if yyr4070 || yy2arr4070 { - r.EncodeArrayStart(4) - } else { - yynn4070 = 1 - for _, b := range yyq4070 { - if b { - yynn4070++ - } - } - r.EncodeMapStart(yynn4070) - yynn4070 = 0 - } - if yyr4070 || yy2arr4070 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4070[0] { - yym4072 := z.EncBinary() - _ = yym4072 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4070[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4073 := z.EncBinary() - _ = yym4073 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4070 || yy2arr4070 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4070[1] { - yym4075 := z.EncBinary() - _ = yym4075 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4070[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4076 := z.EncBinary() - _ = yym4076 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4070 || yy2arr4070 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4070[2] { - yy4078 := &x.ListMeta - yym4079 := z.EncBinary() - _ = yym4079 - if false { - } else if z.HasExtensions() && z.EncExt(yy4078) { - } else { - z.EncFallback(yy4078) - } - } else { - r.EncodeNil() - } - } else { - if yyq4070[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4080 := &x.ListMeta - yym4081 := z.EncBinary() - _ = yym4081 - if false { - } else if z.HasExtensions() && z.EncExt(yy4080) { - } else { - z.EncFallback(yy4080) - } - } - } - if yyr4070 || yy2arr4070 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4083 := z.EncBinary() - _ = yym4083 - if false { - } else { - h.encSliceruntime_Object(([]pkg7_runtime.Object)(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 { - yym4084 := z.EncBinary() - _ = yym4084 - if false { - } else { - h.encSliceruntime_Object(([]pkg7_runtime.Object)(x.Items), e) - } - } - } - if yyr4070 || yy2arr4070 { - 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 - yym4085 := z.DecBinary() - _ = yym4085 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4086 := r.ContainerType() - if yyct4086 == codecSelferValueTypeMap1234 { - yyl4086 := r.ReadMapStart() - if yyl4086 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4086, d) - } - } else if yyct4086 == codecSelferValueTypeArray1234 { - yyl4086 := r.ReadArrayStart() - if yyl4086 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4086, 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 yys4087Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4087Slc - var yyhl4087 bool = l >= 0 - for yyj4087 := 0; ; yyj4087++ { - if yyhl4087 { - if yyj4087 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4087Slc = r.DecodeBytes(yys4087Slc, true, true) - yys4087 := string(yys4087Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4087 { - 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 { - yyv4090 := &x.ListMeta - yym4091 := z.DecBinary() - _ = yym4091 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4090) { - } else { - z.DecFallback(yyv4090, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4092 := &x.Items - yym4093 := z.DecBinary() - _ = yym4093 - if false { - } else { - h.decSliceruntime_Object((*[]pkg7_runtime.Object)(yyv4092), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4087) - } // end switch yys4087 - } // end for yyj4087 - 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 yyj4094 int - var yyb4094 bool - var yyhl4094 bool = l >= 0 - yyj4094++ - if yyhl4094 { - yyb4094 = yyj4094 > l - } else { - yyb4094 = r.CheckBreak() - } - if yyb4094 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4094++ - if yyhl4094 { - yyb4094 = yyj4094 > l - } else { - yyb4094 = r.CheckBreak() - } - if yyb4094 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4094++ - if yyhl4094 { - yyb4094 = yyj4094 > l - } else { - yyb4094 = r.CheckBreak() - } - if yyb4094 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4097 := &x.ListMeta - yym4098 := z.DecBinary() - _ = yym4098 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4097) { - } else { - z.DecFallback(yyv4097, false) - } - } - yyj4094++ - if yyhl4094 { - yyb4094 = yyj4094 > l - } else { - yyb4094 = r.CheckBreak() - } - if yyb4094 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4099 := &x.Items - yym4100 := z.DecBinary() - _ = yym4100 - if false { - } else { - h.decSliceruntime_Object((*[]pkg7_runtime.Object)(yyv4099), d) - } - } - for { - yyj4094++ - if yyhl4094 { - yyb4094 = yyj4094 > l - } else { - yyb4094 = r.CheckBreak() - } - if yyb4094 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4094-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x LimitType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4101 := z.EncBinary() - _ = yym4101 - 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 - yym4102 := z.DecBinary() - _ = yym4102 - 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 { - yym4103 := z.EncBinary() - _ = yym4103 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4104 := !z.EncBinary() - yy2arr4104 := z.EncBasicHandle().StructToArray - var yyq4104 [6]bool - _, _, _ = yysep4104, yyq4104, yy2arr4104 - const yyr4104 bool = false - yyq4104[0] = x.Type != "" - yyq4104[1] = len(x.Max) != 0 - yyq4104[2] = len(x.Min) != 0 - yyq4104[3] = len(x.Default) != 0 - yyq4104[4] = len(x.DefaultRequest) != 0 - yyq4104[5] = len(x.MaxLimitRequestRatio) != 0 - var yynn4104 int - if yyr4104 || yy2arr4104 { - r.EncodeArrayStart(6) - } else { - yynn4104 = 0 - for _, b := range yyq4104 { - if b { - yynn4104++ - } - } - r.EncodeMapStart(yynn4104) - yynn4104 = 0 - } - if yyr4104 || yy2arr4104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4104[0] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4104[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr4104 || yy2arr4104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4104[1] { - if x.Max == nil { - r.EncodeNil() - } else { - x.Max.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4104[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 yyr4104 || yy2arr4104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4104[2] { - if x.Min == nil { - r.EncodeNil() - } else { - x.Min.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4104[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 yyr4104 || yy2arr4104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4104[3] { - if x.Default == nil { - r.EncodeNil() - } else { - x.Default.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4104[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 yyr4104 || yy2arr4104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4104[4] { - if x.DefaultRequest == nil { - r.EncodeNil() - } else { - x.DefaultRequest.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4104[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 yyr4104 || yy2arr4104 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4104[5] { - if x.MaxLimitRequestRatio == nil { - r.EncodeNil() - } else { - x.MaxLimitRequestRatio.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4104[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 yyr4104 || yy2arr4104 { - 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 - yym4111 := z.DecBinary() - _ = yym4111 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4112 := r.ContainerType() - if yyct4112 == codecSelferValueTypeMap1234 { - yyl4112 := r.ReadMapStart() - if yyl4112 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4112, d) - } - } else if yyct4112 == codecSelferValueTypeArray1234 { - yyl4112 := r.ReadArrayStart() - if yyl4112 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4112, 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 yys4113Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4113Slc - var yyhl4113 bool = l >= 0 - for yyj4113 := 0; ; yyj4113++ { - if yyhl4113 { - if yyj4113 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4113Slc = r.DecodeBytes(yys4113Slc, true, true) - yys4113 := string(yys4113Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4113 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = LimitType(r.DecodeString()) - } - case "max": - if r.TryDecodeAsNil() { - x.Max = nil - } else { - yyv4115 := &x.Max - yyv4115.CodecDecodeSelf(d) - } - case "min": - if r.TryDecodeAsNil() { - x.Min = nil - } else { - yyv4116 := &x.Min - yyv4116.CodecDecodeSelf(d) - } - case "default": - if r.TryDecodeAsNil() { - x.Default = nil - } else { - yyv4117 := &x.Default - yyv4117.CodecDecodeSelf(d) - } - case "defaultRequest": - if r.TryDecodeAsNil() { - x.DefaultRequest = nil - } else { - yyv4118 := &x.DefaultRequest - yyv4118.CodecDecodeSelf(d) - } - case "maxLimitRequestRatio": - if r.TryDecodeAsNil() { - x.MaxLimitRequestRatio = nil - } else { - yyv4119 := &x.MaxLimitRequestRatio - yyv4119.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4113) - } // end switch yys4113 - } // end for yyj4113 - 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 yyj4120 int - var yyb4120 bool - var yyhl4120 bool = l >= 0 - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = LimitType(r.DecodeString()) - } - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Max = nil - } else { - yyv4122 := &x.Max - yyv4122.CodecDecodeSelf(d) - } - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Min = nil - } else { - yyv4123 := &x.Min - yyv4123.CodecDecodeSelf(d) - } - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Default = nil - } else { - yyv4124 := &x.Default - yyv4124.CodecDecodeSelf(d) - } - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DefaultRequest = nil - } else { - yyv4125 := &x.DefaultRequest - yyv4125.CodecDecodeSelf(d) - } - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MaxLimitRequestRatio = nil - } else { - yyv4126 := &x.MaxLimitRequestRatio - yyv4126.CodecDecodeSelf(d) - } - for { - yyj4120++ - if yyhl4120 { - yyb4120 = yyj4120 > l - } else { - yyb4120 = r.CheckBreak() - } - if yyb4120 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4120-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 { - yym4127 := z.EncBinary() - _ = yym4127 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4128 := !z.EncBinary() - yy2arr4128 := z.EncBasicHandle().StructToArray - var yyq4128 [1]bool - _, _, _ = yysep4128, yyq4128, yy2arr4128 - const yyr4128 bool = false - var yynn4128 int - if yyr4128 || yy2arr4128 { - r.EncodeArrayStart(1) - } else { - yynn4128 = 1 - for _, b := range yyq4128 { - if b { - yynn4128++ - } - } - r.EncodeMapStart(yynn4128) - yynn4128 = 0 - } - if yyr4128 || yy2arr4128 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Limits == nil { - r.EncodeNil() - } else { - yym4130 := z.EncBinary() - _ = yym4130 - 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 { - yym4131 := z.EncBinary() - _ = yym4131 - if false { - } else { - h.encSliceLimitRangeItem(([]LimitRangeItem)(x.Limits), e) - } - } - } - if yyr4128 || yy2arr4128 { - 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 - yym4132 := z.DecBinary() - _ = yym4132 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4133 := r.ContainerType() - if yyct4133 == codecSelferValueTypeMap1234 { - yyl4133 := r.ReadMapStart() - if yyl4133 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4133, d) - } - } else if yyct4133 == codecSelferValueTypeArray1234 { - yyl4133 := r.ReadArrayStart() - if yyl4133 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4133, 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 yys4134Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4134Slc - var yyhl4134 bool = l >= 0 - for yyj4134 := 0; ; yyj4134++ { - if yyhl4134 { - if yyj4134 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4134Slc = r.DecodeBytes(yys4134Slc, true, true) - yys4134 := string(yys4134Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4134 { - case "limits": - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv4135 := &x.Limits - yym4136 := z.DecBinary() - _ = yym4136 - if false { - } else { - h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv4135), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4134) - } // end switch yys4134 - } // end for yyj4134 - 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 yyj4137 int - var yyb4137 bool - var yyhl4137 bool = l >= 0 - yyj4137++ - if yyhl4137 { - yyb4137 = yyj4137 > l - } else { - yyb4137 = r.CheckBreak() - } - if yyb4137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Limits = nil - } else { - yyv4138 := &x.Limits - yym4139 := z.DecBinary() - _ = yym4139 - if false { - } else { - h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv4138), d) - } - } - for { - yyj4137++ - if yyhl4137 { - yyb4137 = yyj4137 > l - } else { - yyb4137 = r.CheckBreak() - } - if yyb4137 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4137-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 { - yym4140 := z.EncBinary() - _ = yym4140 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4141 := !z.EncBinary() - yy2arr4141 := z.EncBasicHandle().StructToArray - var yyq4141 [4]bool - _, _, _ = yysep4141, yyq4141, yy2arr4141 - const yyr4141 bool = false - yyq4141[0] = x.Kind != "" - yyq4141[1] = x.APIVersion != "" - yyq4141[2] = true - yyq4141[3] = true - var yynn4141 int - if yyr4141 || yy2arr4141 { - r.EncodeArrayStart(4) - } else { - yynn4141 = 0 - for _, b := range yyq4141 { - if b { - yynn4141++ - } - } - r.EncodeMapStart(yynn4141) - yynn4141 = 0 - } - if yyr4141 || yy2arr4141 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4141[0] { - yym4143 := z.EncBinary() - _ = yym4143 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4141[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4144 := z.EncBinary() - _ = yym4144 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4141 || yy2arr4141 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4141[1] { - yym4146 := z.EncBinary() - _ = yym4146 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4141[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4147 := z.EncBinary() - _ = yym4147 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4141 || yy2arr4141 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4141[2] { - yy4149 := &x.ObjectMeta - yy4149.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4141[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4150 := &x.ObjectMeta - yy4150.CodecEncodeSelf(e) - } - } - if yyr4141 || yy2arr4141 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4141[3] { - yy4152 := &x.Spec - yy4152.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4141[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4153 := &x.Spec - yy4153.CodecEncodeSelf(e) - } - } - if yyr4141 || yy2arr4141 { - 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 - yym4154 := z.DecBinary() - _ = yym4154 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4155 := r.ContainerType() - if yyct4155 == codecSelferValueTypeMap1234 { - yyl4155 := r.ReadMapStart() - if yyl4155 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4155, d) - } - } else if yyct4155 == codecSelferValueTypeArray1234 { - yyl4155 := r.ReadArrayStart() - if yyl4155 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4155, 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 yys4156Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4156Slc - var yyhl4156 bool = l >= 0 - for yyj4156 := 0; ; yyj4156++ { - if yyhl4156 { - if yyj4156 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4156Slc = r.DecodeBytes(yys4156Slc, true, true) - yys4156 := string(yys4156Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4156 { - 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 { - yyv4159 := &x.ObjectMeta - yyv4159.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = LimitRangeSpec{} - } else { - yyv4160 := &x.Spec - yyv4160.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4156) - } // end switch yys4156 - } // end for yyj4156 - 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 yyj4161 int - var yyb4161 bool - var yyhl4161 bool = l >= 0 - yyj4161++ - if yyhl4161 { - yyb4161 = yyj4161 > l - } else { - yyb4161 = r.CheckBreak() - } - if yyb4161 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4161++ - if yyhl4161 { - yyb4161 = yyj4161 > l - } else { - yyb4161 = r.CheckBreak() - } - if yyb4161 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4161++ - if yyhl4161 { - yyb4161 = yyj4161 > l - } else { - yyb4161 = r.CheckBreak() - } - if yyb4161 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4164 := &x.ObjectMeta - yyv4164.CodecDecodeSelf(d) - } - yyj4161++ - if yyhl4161 { - yyb4161 = yyj4161 > l - } else { - yyb4161 = r.CheckBreak() - } - if yyb4161 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = LimitRangeSpec{} - } else { - yyv4165 := &x.Spec - yyv4165.CodecDecodeSelf(d) - } - for { - yyj4161++ - if yyhl4161 { - yyb4161 = yyj4161 > l - } else { - yyb4161 = r.CheckBreak() - } - if yyb4161 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4161-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 { - yym4166 := z.EncBinary() - _ = yym4166 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4167 := !z.EncBinary() - yy2arr4167 := z.EncBasicHandle().StructToArray - var yyq4167 [4]bool - _, _, _ = yysep4167, yyq4167, yy2arr4167 - const yyr4167 bool = false - yyq4167[0] = x.Kind != "" - yyq4167[1] = x.APIVersion != "" - yyq4167[2] = true - var yynn4167 int - if yyr4167 || yy2arr4167 { - r.EncodeArrayStart(4) - } else { - yynn4167 = 1 - for _, b := range yyq4167 { - if b { - yynn4167++ - } - } - r.EncodeMapStart(yynn4167) - yynn4167 = 0 - } - if yyr4167 || yy2arr4167 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4167[0] { - yym4169 := z.EncBinary() - _ = yym4169 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4167[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4170 := z.EncBinary() - _ = yym4170 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4167 || yy2arr4167 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4167[1] { - yym4172 := z.EncBinary() - _ = yym4172 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4167[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4173 := z.EncBinary() - _ = yym4173 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4167 || yy2arr4167 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4167[2] { - yy4175 := &x.ListMeta - yym4176 := z.EncBinary() - _ = yym4176 - if false { - } else if z.HasExtensions() && z.EncExt(yy4175) { - } else { - z.EncFallback(yy4175) - } - } else { - r.EncodeNil() - } - } else { - if yyq4167[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4177 := &x.ListMeta - yym4178 := z.EncBinary() - _ = yym4178 - if false { - } else if z.HasExtensions() && z.EncExt(yy4177) { - } else { - z.EncFallback(yy4177) - } - } - } - if yyr4167 || yy2arr4167 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4180 := z.EncBinary() - _ = yym4180 - 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 { - yym4181 := z.EncBinary() - _ = yym4181 - if false { - } else { - h.encSliceLimitRange(([]LimitRange)(x.Items), e) - } - } - } - if yyr4167 || yy2arr4167 { - 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 - yym4182 := z.DecBinary() - _ = yym4182 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4183 := r.ContainerType() - if yyct4183 == codecSelferValueTypeMap1234 { - yyl4183 := r.ReadMapStart() - if yyl4183 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4183, d) - } - } else if yyct4183 == codecSelferValueTypeArray1234 { - yyl4183 := r.ReadArrayStart() - if yyl4183 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4183, 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 yys4184Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4184Slc - var yyhl4184 bool = l >= 0 - for yyj4184 := 0; ; yyj4184++ { - if yyhl4184 { - if yyj4184 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4184Slc = r.DecodeBytes(yys4184Slc, true, true) - yys4184 := string(yys4184Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4184 { - 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 { - yyv4187 := &x.ListMeta - yym4188 := z.DecBinary() - _ = yym4188 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4187) { - } else { - z.DecFallback(yyv4187, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4189 := &x.Items - yym4190 := z.DecBinary() - _ = yym4190 - if false { - } else { - h.decSliceLimitRange((*[]LimitRange)(yyv4189), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4184) - } // end switch yys4184 - } // end for yyj4184 - 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 yyj4191 int - var yyb4191 bool - var yyhl4191 bool = l >= 0 - yyj4191++ - if yyhl4191 { - yyb4191 = yyj4191 > l - } else { - yyb4191 = r.CheckBreak() - } - if yyb4191 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4191++ - if yyhl4191 { - yyb4191 = yyj4191 > l - } else { - yyb4191 = r.CheckBreak() - } - if yyb4191 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4191++ - if yyhl4191 { - yyb4191 = yyj4191 > l - } else { - yyb4191 = r.CheckBreak() - } - if yyb4191 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4194 := &x.ListMeta - yym4195 := z.DecBinary() - _ = yym4195 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4194) { - } else { - z.DecFallback(yyv4194, false) - } - } - yyj4191++ - if yyhl4191 { - yyb4191 = yyj4191 > l - } else { - yyb4191 = r.CheckBreak() - } - if yyb4191 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4196 := &x.Items - yym4197 := z.DecBinary() - _ = yym4197 - if false { - } else { - h.decSliceLimitRange((*[]LimitRange)(yyv4196), d) - } - } - for { - yyj4191++ - if yyhl4191 { - yyb4191 = yyj4191 > l - } else { - yyb4191 = r.CheckBreak() - } - if yyb4191 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4191-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ResourceQuotaScope) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4198 := z.EncBinary() - _ = yym4198 - 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 - yym4199 := z.DecBinary() - _ = yym4199 - 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 { - yym4200 := z.EncBinary() - _ = yym4200 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4201 := !z.EncBinary() - yy2arr4201 := z.EncBasicHandle().StructToArray - var yyq4201 [2]bool - _, _, _ = yysep4201, yyq4201, yy2arr4201 - const yyr4201 bool = false - yyq4201[0] = len(x.Hard) != 0 - yyq4201[1] = len(x.Scopes) != 0 - var yynn4201 int - if yyr4201 || yy2arr4201 { - r.EncodeArrayStart(2) - } else { - yynn4201 = 0 - for _, b := range yyq4201 { - if b { - yynn4201++ - } - } - r.EncodeMapStart(yynn4201) - yynn4201 = 0 - } - if yyr4201 || yy2arr4201 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4201[0] { - if x.Hard == nil { - r.EncodeNil() - } else { - x.Hard.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4201[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 yyr4201 || yy2arr4201 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4201[1] { - if x.Scopes == nil { - r.EncodeNil() - } else { - yym4204 := z.EncBinary() - _ = yym4204 - if false { - } else { - h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4201[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("scopes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Scopes == nil { - r.EncodeNil() - } else { - yym4205 := z.EncBinary() - _ = yym4205 - if false { - } else { - h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e) - } - } - } - } - if yyr4201 || yy2arr4201 { - 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 - yym4206 := z.DecBinary() - _ = yym4206 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4207 := r.ContainerType() - if yyct4207 == codecSelferValueTypeMap1234 { - yyl4207 := r.ReadMapStart() - if yyl4207 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4207, d) - } - } else if yyct4207 == codecSelferValueTypeArray1234 { - yyl4207 := r.ReadArrayStart() - if yyl4207 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4207, 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 yys4208Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4208Slc - var yyhl4208 bool = l >= 0 - for yyj4208 := 0; ; yyj4208++ { - if yyhl4208 { - if yyj4208 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4208Slc = r.DecodeBytes(yys4208Slc, true, true) - yys4208 := string(yys4208Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4208 { - case "hard": - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4209 := &x.Hard - yyv4209.CodecDecodeSelf(d) - } - case "scopes": - if r.TryDecodeAsNil() { - x.Scopes = nil - } else { - yyv4210 := &x.Scopes - yym4211 := z.DecBinary() - _ = yym4211 - if false { - } else { - h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv4210), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4208) - } // end switch yys4208 - } // end for yyj4208 - 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 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.Hard = nil - } else { - yyv4213 := &x.Hard - yyv4213.CodecDecodeSelf(d) - } - 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.Scopes = nil - } else { - yyv4214 := &x.Scopes - yym4215 := z.DecBinary() - _ = yym4215 - if false { - } else { - h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv4214), 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 *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym4216 := z.EncBinary() - _ = yym4216 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4217 := !z.EncBinary() - yy2arr4217 := z.EncBasicHandle().StructToArray - var yyq4217 [2]bool - _, _, _ = yysep4217, yyq4217, yy2arr4217 - const yyr4217 bool = false - yyq4217[0] = len(x.Hard) != 0 - yyq4217[1] = len(x.Used) != 0 - var yynn4217 int - if yyr4217 || yy2arr4217 { - r.EncodeArrayStart(2) - } else { - yynn4217 = 0 - for _, b := range yyq4217 { - if b { - yynn4217++ - } - } - r.EncodeMapStart(yynn4217) - yynn4217 = 0 - } - if yyr4217 || yy2arr4217 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4217[0] { - if x.Hard == nil { - r.EncodeNil() - } else { - x.Hard.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4217[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 yyr4217 || yy2arr4217 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4217[1] { - if x.Used == nil { - r.EncodeNil() - } else { - x.Used.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4217[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 yyr4217 || yy2arr4217 { - 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 - yym4220 := z.DecBinary() - _ = yym4220 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4221 := r.ContainerType() - if yyct4221 == codecSelferValueTypeMap1234 { - yyl4221 := r.ReadMapStart() - if yyl4221 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4221, d) - } - } else if yyct4221 == codecSelferValueTypeArray1234 { - yyl4221 := r.ReadArrayStart() - if yyl4221 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4221, 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 yys4222Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4222Slc - var yyhl4222 bool = l >= 0 - for yyj4222 := 0; ; yyj4222++ { - if yyhl4222 { - if yyj4222 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4222Slc = r.DecodeBytes(yys4222Slc, true, true) - yys4222 := string(yys4222Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4222 { - case "hard": - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4223 := &x.Hard - yyv4223.CodecDecodeSelf(d) - } - case "used": - if r.TryDecodeAsNil() { - x.Used = nil - } else { - yyv4224 := &x.Used - yyv4224.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4222) - } // end switch yys4222 - } // end for yyj4222 - 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 yyj4225 int - var yyb4225 bool - var yyhl4225 bool = l >= 0 - yyj4225++ - if yyhl4225 { - yyb4225 = yyj4225 > l - } else { - yyb4225 = r.CheckBreak() - } - if yyb4225 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hard = nil - } else { - yyv4226 := &x.Hard - yyv4226.CodecDecodeSelf(d) - } - yyj4225++ - if yyhl4225 { - yyb4225 = yyj4225 > l - } else { - yyb4225 = r.CheckBreak() - } - if yyb4225 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Used = nil - } else { - yyv4227 := &x.Used - yyv4227.CodecDecodeSelf(d) - } - for { - yyj4225++ - if yyhl4225 { - yyb4225 = yyj4225 > l - } else { - yyb4225 = r.CheckBreak() - } - if yyb4225 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4225-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 { - yym4228 := z.EncBinary() - _ = yym4228 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4229 := !z.EncBinary() - yy2arr4229 := z.EncBasicHandle().StructToArray - var yyq4229 [5]bool - _, _, _ = yysep4229, yyq4229, yy2arr4229 - const yyr4229 bool = false - yyq4229[0] = x.Kind != "" - yyq4229[1] = x.APIVersion != "" - yyq4229[2] = true - yyq4229[3] = true - yyq4229[4] = true - var yynn4229 int - if yyr4229 || yy2arr4229 { - r.EncodeArrayStart(5) - } else { - yynn4229 = 0 - for _, b := range yyq4229 { - if b { - yynn4229++ - } - } - r.EncodeMapStart(yynn4229) - yynn4229 = 0 - } - if yyr4229 || yy2arr4229 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4229[0] { - yym4231 := z.EncBinary() - _ = yym4231 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4229[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4232 := z.EncBinary() - _ = yym4232 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4229 || yy2arr4229 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4229[1] { - yym4234 := z.EncBinary() - _ = yym4234 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4229[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4235 := z.EncBinary() - _ = yym4235 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4229 || yy2arr4229 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4229[2] { - yy4237 := &x.ObjectMeta - yy4237.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4229[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4238 := &x.ObjectMeta - yy4238.CodecEncodeSelf(e) - } - } - if yyr4229 || yy2arr4229 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4229[3] { - yy4240 := &x.Spec - yy4240.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4229[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4241 := &x.Spec - yy4241.CodecEncodeSelf(e) - } - } - if yyr4229 || yy2arr4229 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4229[4] { - yy4243 := &x.Status - yy4243.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4229[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4244 := &x.Status - yy4244.CodecEncodeSelf(e) - } - } - if yyr4229 || yy2arr4229 { - 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 - yym4245 := z.DecBinary() - _ = yym4245 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4246 := r.ContainerType() - if yyct4246 == codecSelferValueTypeMap1234 { - yyl4246 := r.ReadMapStart() - if yyl4246 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4246, d) - } - } else if yyct4246 == codecSelferValueTypeArray1234 { - yyl4246 := r.ReadArrayStart() - if yyl4246 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4246, 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 yys4247Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4247Slc - var yyhl4247 bool = l >= 0 - for yyj4247 := 0; ; yyj4247++ { - if yyhl4247 { - if yyj4247 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4247Slc = r.DecodeBytes(yys4247Slc, true, true) - yys4247 := string(yys4247Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4247 { - 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 { - yyv4250 := &x.ObjectMeta - yyv4250.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ResourceQuotaSpec{} - } else { - yyv4251 := &x.Spec - yyv4251.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ResourceQuotaStatus{} - } else { - yyv4252 := &x.Status - yyv4252.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys4247) - } // end switch yys4247 - } // end for yyj4247 - 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 yyj4253 int - var yyb4253 bool - var yyhl4253 bool = l >= 0 - yyj4253++ - if yyhl4253 { - yyb4253 = yyj4253 > l - } else { - yyb4253 = r.CheckBreak() - } - if yyb4253 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4253++ - if yyhl4253 { - yyb4253 = yyj4253 > l - } else { - yyb4253 = r.CheckBreak() - } - if yyb4253 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4253++ - if yyhl4253 { - yyb4253 = yyj4253 > l - } else { - yyb4253 = r.CheckBreak() - } - if yyb4253 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4256 := &x.ObjectMeta - yyv4256.CodecDecodeSelf(d) - } - yyj4253++ - if yyhl4253 { - yyb4253 = yyj4253 > l - } else { - yyb4253 = r.CheckBreak() - } - if yyb4253 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ResourceQuotaSpec{} - } else { - yyv4257 := &x.Spec - yyv4257.CodecDecodeSelf(d) - } - yyj4253++ - if yyhl4253 { - yyb4253 = yyj4253 > l - } else { - yyb4253 = r.CheckBreak() - } - if yyb4253 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ResourceQuotaStatus{} - } else { - yyv4258 := &x.Status - yyv4258.CodecDecodeSelf(d) - } - for { - yyj4253++ - if yyhl4253 { - yyb4253 = yyj4253 > l - } else { - yyb4253 = r.CheckBreak() - } - if yyb4253 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4253-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 { - yym4259 := z.EncBinary() - _ = yym4259 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4260 := !z.EncBinary() - yy2arr4260 := z.EncBasicHandle().StructToArray - var yyq4260 [4]bool - _, _, _ = yysep4260, yyq4260, yy2arr4260 - const yyr4260 bool = false - yyq4260[0] = x.Kind != "" - yyq4260[1] = x.APIVersion != "" - yyq4260[2] = true - var yynn4260 int - if yyr4260 || yy2arr4260 { - r.EncodeArrayStart(4) - } else { - yynn4260 = 1 - for _, b := range yyq4260 { - if b { - yynn4260++ - } - } - r.EncodeMapStart(yynn4260) - yynn4260 = 0 - } - if yyr4260 || yy2arr4260 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4260[0] { - yym4262 := z.EncBinary() - _ = yym4262 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4260[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4263 := z.EncBinary() - _ = yym4263 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4260 || yy2arr4260 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4260[1] { - yym4265 := z.EncBinary() - _ = yym4265 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4260[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4266 := z.EncBinary() - _ = yym4266 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4260 || yy2arr4260 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4260[2] { - yy4268 := &x.ListMeta - yym4269 := z.EncBinary() - _ = yym4269 - if false { - } else if z.HasExtensions() && z.EncExt(yy4268) { - } else { - z.EncFallback(yy4268) - } - } else { - r.EncodeNil() - } - } else { - if yyq4260[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4270 := &x.ListMeta - yym4271 := z.EncBinary() - _ = yym4271 - if false { - } else if z.HasExtensions() && z.EncExt(yy4270) { - } else { - z.EncFallback(yy4270) - } - } - } - if yyr4260 || yy2arr4260 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4273 := z.EncBinary() - _ = yym4273 - 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 { - yym4274 := z.EncBinary() - _ = yym4274 - if false { - } else { - h.encSliceResourceQuota(([]ResourceQuota)(x.Items), e) - } - } - } - if yyr4260 || yy2arr4260 { - 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 - yym4275 := z.DecBinary() - _ = yym4275 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4276 := r.ContainerType() - if yyct4276 == codecSelferValueTypeMap1234 { - yyl4276 := r.ReadMapStart() - if yyl4276 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4276, d) - } - } else if yyct4276 == codecSelferValueTypeArray1234 { - yyl4276 := r.ReadArrayStart() - if yyl4276 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4276, 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 yys4277Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4277Slc - var yyhl4277 bool = l >= 0 - for yyj4277 := 0; ; yyj4277++ { - if yyhl4277 { - if yyj4277 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4277Slc = r.DecodeBytes(yys4277Slc, true, true) - yys4277 := string(yys4277Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4277 { - 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 { - yyv4280 := &x.ListMeta - yym4281 := z.DecBinary() - _ = yym4281 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4280) { - } else { - z.DecFallback(yyv4280, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4282 := &x.Items - yym4283 := z.DecBinary() - _ = yym4283 - if false { - } else { - h.decSliceResourceQuota((*[]ResourceQuota)(yyv4282), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4277) - } // end switch yys4277 - } // end for yyj4277 - 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 yyj4284 int - var yyb4284 bool - var yyhl4284 bool = l >= 0 - yyj4284++ - if yyhl4284 { - yyb4284 = yyj4284 > l - } else { - yyb4284 = r.CheckBreak() - } - if yyb4284 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4284++ - if yyhl4284 { - yyb4284 = yyj4284 > l - } else { - yyb4284 = r.CheckBreak() - } - if yyb4284 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4284++ - if yyhl4284 { - yyb4284 = yyj4284 > l - } else { - yyb4284 = r.CheckBreak() - } - if yyb4284 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4287 := &x.ListMeta - yym4288 := z.DecBinary() - _ = yym4288 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4287) { - } else { - z.DecFallback(yyv4287, false) - } - } - yyj4284++ - if yyhl4284 { - yyb4284 = yyj4284 > l - } else { - yyb4284 = r.CheckBreak() - } - if yyb4284 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4289 := &x.Items - yym4290 := z.DecBinary() - _ = yym4290 - if false { - } else { - h.decSliceResourceQuota((*[]ResourceQuota)(yyv4289), d) - } - } - for { - yyj4284++ - if yyhl4284 { - yyb4284 = yyj4284 > l - } else { - yyb4284 = r.CheckBreak() - } - if yyb4284 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4284-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 { - yym4291 := z.EncBinary() - _ = yym4291 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4292 := !z.EncBinary() - yy2arr4292 := z.EncBasicHandle().StructToArray - var yyq4292 [5]bool - _, _, _ = yysep4292, yyq4292, yy2arr4292 - const yyr4292 bool = false - yyq4292[0] = x.Kind != "" - yyq4292[1] = x.APIVersion != "" - yyq4292[2] = true - yyq4292[3] = len(x.Data) != 0 - yyq4292[4] = x.Type != "" - var yynn4292 int - if yyr4292 || yy2arr4292 { - r.EncodeArrayStart(5) - } else { - yynn4292 = 0 - for _, b := range yyq4292 { - if b { - yynn4292++ - } - } - r.EncodeMapStart(yynn4292) - yynn4292 = 0 - } - if yyr4292 || yy2arr4292 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4292[0] { - yym4294 := z.EncBinary() - _ = yym4294 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4292[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4295 := z.EncBinary() - _ = yym4295 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4292 || yy2arr4292 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4292[1] { - yym4297 := z.EncBinary() - _ = yym4297 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4292[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4298 := z.EncBinary() - _ = yym4298 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4292 || yy2arr4292 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4292[2] { - yy4300 := &x.ObjectMeta - yy4300.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4292[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4301 := &x.ObjectMeta - yy4301.CodecEncodeSelf(e) - } - } - if yyr4292 || yy2arr4292 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4292[3] { - if x.Data == nil { - r.EncodeNil() - } else { - yym4303 := z.EncBinary() - _ = yym4303 - if false { - } else { - h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4292[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("data")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym4304 := z.EncBinary() - _ = yym4304 - if false { - } else { - h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e) - } - } - } - } - if yyr4292 || yy2arr4292 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4292[4] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4292[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr4292 || yy2arr4292 { - 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 - yym4306 := z.DecBinary() - _ = yym4306 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4307 := r.ContainerType() - if yyct4307 == codecSelferValueTypeMap1234 { - yyl4307 := r.ReadMapStart() - if yyl4307 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4307, d) - } - } else if yyct4307 == codecSelferValueTypeArray1234 { - yyl4307 := r.ReadArrayStart() - if yyl4307 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4307, 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 yys4308Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4308Slc - var yyhl4308 bool = l >= 0 - for yyj4308 := 0; ; yyj4308++ { - if yyhl4308 { - if yyj4308 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4308Slc = r.DecodeBytes(yys4308Slc, true, true) - yys4308 := string(yys4308Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4308 { - 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 { - yyv4311 := &x.ObjectMeta - yyv4311.CodecDecodeSelf(d) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4312 := &x.Data - yym4313 := z.DecBinary() - _ = yym4313 - if false { - } else { - h.decMapstringSliceuint8((*map[string][]uint8)(yyv4312), d) - } - } - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = SecretType(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys4308) - } // end switch yys4308 - } // end for yyj4308 - 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 yyj4315 int - var yyb4315 bool - var yyhl4315 bool = l >= 0 - yyj4315++ - if yyhl4315 { - yyb4315 = yyj4315 > l - } else { - yyb4315 = r.CheckBreak() - } - if yyb4315 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4315++ - if yyhl4315 { - yyb4315 = yyj4315 > l - } else { - yyb4315 = r.CheckBreak() - } - if yyb4315 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4315++ - if yyhl4315 { - yyb4315 = yyj4315 > l - } else { - yyb4315 = r.CheckBreak() - } - if yyb4315 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4318 := &x.ObjectMeta - yyv4318.CodecDecodeSelf(d) - } - yyj4315++ - if yyhl4315 { - yyb4315 = yyj4315 > l - } else { - yyb4315 = r.CheckBreak() - } - if yyb4315 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4319 := &x.Data - yym4320 := z.DecBinary() - _ = yym4320 - if false { - } else { - h.decMapstringSliceuint8((*map[string][]uint8)(yyv4319), d) - } - } - yyj4315++ - if yyhl4315 { - yyb4315 = yyj4315 > l - } else { - yyb4315 = r.CheckBreak() - } - if yyb4315 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = SecretType(r.DecodeString()) - } - for { - yyj4315++ - if yyhl4315 { - yyb4315 = yyj4315 > l - } else { - yyb4315 = r.CheckBreak() - } - if yyb4315 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4315-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x SecretType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4322 := z.EncBinary() - _ = yym4322 - 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 - yym4323 := z.DecBinary() - _ = yym4323 - 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 { - yym4324 := z.EncBinary() - _ = yym4324 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4325 := !z.EncBinary() - yy2arr4325 := z.EncBasicHandle().StructToArray - var yyq4325 [4]bool - _, _, _ = yysep4325, yyq4325, yy2arr4325 - const yyr4325 bool = false - yyq4325[0] = x.Kind != "" - yyq4325[1] = x.APIVersion != "" - yyq4325[2] = true - var yynn4325 int - if yyr4325 || yy2arr4325 { - r.EncodeArrayStart(4) - } else { - yynn4325 = 1 - for _, b := range yyq4325 { - if b { - yynn4325++ - } - } - r.EncodeMapStart(yynn4325) - yynn4325 = 0 - } - if yyr4325 || yy2arr4325 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4325[0] { - yym4327 := z.EncBinary() - _ = yym4327 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4325[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4328 := z.EncBinary() - _ = yym4328 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4325 || yy2arr4325 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4325[1] { - yym4330 := z.EncBinary() - _ = yym4330 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4325[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4331 := z.EncBinary() - _ = yym4331 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4325 || yy2arr4325 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4325[2] { - yy4333 := &x.ListMeta - yym4334 := z.EncBinary() - _ = yym4334 - if false { - } else if z.HasExtensions() && z.EncExt(yy4333) { - } else { - z.EncFallback(yy4333) - } - } else { - r.EncodeNil() - } - } else { - if yyq4325[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4335 := &x.ListMeta - yym4336 := z.EncBinary() - _ = yym4336 - if false { - } else if z.HasExtensions() && z.EncExt(yy4335) { - } else { - z.EncFallback(yy4335) - } - } - } - if yyr4325 || yy2arr4325 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4338 := z.EncBinary() - _ = yym4338 - 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 { - yym4339 := z.EncBinary() - _ = yym4339 - if false { - } else { - h.encSliceSecret(([]Secret)(x.Items), e) - } - } - } - if yyr4325 || yy2arr4325 { - 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 - yym4340 := z.DecBinary() - _ = yym4340 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4341 := r.ContainerType() - if yyct4341 == codecSelferValueTypeMap1234 { - yyl4341 := r.ReadMapStart() - if yyl4341 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4341, d) - } - } else if yyct4341 == codecSelferValueTypeArray1234 { - yyl4341 := r.ReadArrayStart() - if yyl4341 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4341, 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 yys4342Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4342Slc - var yyhl4342 bool = l >= 0 - for yyj4342 := 0; ; yyj4342++ { - if yyhl4342 { - if yyj4342 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4342Slc = r.DecodeBytes(yys4342Slc, true, true) - yys4342 := string(yys4342Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4342 { - 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 { - yyv4345 := &x.ListMeta - yym4346 := z.DecBinary() - _ = yym4346 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4345) { - } else { - z.DecFallback(yyv4345, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4347 := &x.Items - yym4348 := z.DecBinary() - _ = yym4348 - if false { - } else { - h.decSliceSecret((*[]Secret)(yyv4347), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4342) - } // end switch yys4342 - } // end for yyj4342 - 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 yyj4349 int - var yyb4349 bool - var yyhl4349 bool = l >= 0 - yyj4349++ - if yyhl4349 { - yyb4349 = yyj4349 > l - } else { - yyb4349 = r.CheckBreak() - } - if yyb4349 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4349++ - if yyhl4349 { - yyb4349 = yyj4349 > l - } else { - yyb4349 = r.CheckBreak() - } - if yyb4349 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4349++ - if yyhl4349 { - yyb4349 = yyj4349 > l - } else { - yyb4349 = r.CheckBreak() - } - if yyb4349 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - 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) - } - } - yyj4349++ - if yyhl4349 { - yyb4349 = yyj4349 > l - } else { - yyb4349 = r.CheckBreak() - } - if yyb4349 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4354 := &x.Items - yym4355 := z.DecBinary() - _ = yym4355 - if false { - } else { - h.decSliceSecret((*[]Secret)(yyv4354), d) - } - } - for { - yyj4349++ - if yyhl4349 { - yyb4349 = yyj4349 > l - } else { - yyb4349 = r.CheckBreak() - } - if yyb4349 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4349-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 { - yym4356 := z.EncBinary() - _ = yym4356 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4357 := !z.EncBinary() - yy2arr4357 := z.EncBasicHandle().StructToArray - var yyq4357 [4]bool - _, _, _ = yysep4357, yyq4357, yy2arr4357 - const yyr4357 bool = false - yyq4357[0] = x.Kind != "" - yyq4357[1] = x.APIVersion != "" - yyq4357[2] = true - yyq4357[3] = len(x.Data) != 0 - var yynn4357 int - if yyr4357 || yy2arr4357 { - r.EncodeArrayStart(4) - } else { - yynn4357 = 0 - for _, b := range yyq4357 { - if b { - yynn4357++ - } - } - r.EncodeMapStart(yynn4357) - yynn4357 = 0 - } - if yyr4357 || yy2arr4357 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4357[0] { - yym4359 := z.EncBinary() - _ = yym4359 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4357[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4360 := z.EncBinary() - _ = yym4360 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4357 || yy2arr4357 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4357[1] { - yym4362 := z.EncBinary() - _ = yym4362 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4357[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4363 := z.EncBinary() - _ = yym4363 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4357 || yy2arr4357 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4357[2] { - yy4365 := &x.ObjectMeta - yy4365.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4357[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4366 := &x.ObjectMeta - yy4366.CodecEncodeSelf(e) - } - } - if yyr4357 || yy2arr4357 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4357[3] { - if x.Data == nil { - r.EncodeNil() - } else { - yym4368 := z.EncBinary() - _ = yym4368 - if false { - } else { - z.F.EncMapStringStringV(x.Data, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4357[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("data")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym4369 := z.EncBinary() - _ = yym4369 - if false { - } else { - z.F.EncMapStringStringV(x.Data, false, e) - } - } - } - } - if yyr4357 || yy2arr4357 { - 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 - yym4370 := z.DecBinary() - _ = yym4370 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4371 := r.ContainerType() - if yyct4371 == codecSelferValueTypeMap1234 { - yyl4371 := r.ReadMapStart() - if yyl4371 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4371, d) - } - } else if yyct4371 == codecSelferValueTypeArray1234 { - yyl4371 := r.ReadArrayStart() - if yyl4371 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4371, 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 yys4372Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4372Slc - var yyhl4372 bool = l >= 0 - for yyj4372 := 0; ; yyj4372++ { - if yyhl4372 { - if yyj4372 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4372Slc = r.DecodeBytes(yys4372Slc, true, true) - yys4372 := string(yys4372Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4372 { - 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 { - yyv4375 := &x.ObjectMeta - yyv4375.CodecDecodeSelf(d) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4376 := &x.Data - yym4377 := z.DecBinary() - _ = yym4377 - if false { - } else { - z.F.DecMapStringStringX(yyv4376, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4372) - } // end switch yys4372 - } // end for yyj4372 - 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 yyj4378 int - var yyb4378 bool - var yyhl4378 bool = l >= 0 - yyj4378++ - if yyhl4378 { - yyb4378 = yyj4378 > l - } else { - yyb4378 = r.CheckBreak() - } - if yyb4378 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4378++ - if yyhl4378 { - yyb4378 = yyj4378 > l - } else { - yyb4378 = r.CheckBreak() - } - if yyb4378 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4378++ - if yyhl4378 { - yyb4378 = yyj4378 > l - } else { - yyb4378 = r.CheckBreak() - } - if yyb4378 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4381 := &x.ObjectMeta - yyv4381.CodecDecodeSelf(d) - } - yyj4378++ - if yyhl4378 { - yyb4378 = yyj4378 > l - } else { - yyb4378 = r.CheckBreak() - } - if yyb4378 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4382 := &x.Data - yym4383 := z.DecBinary() - _ = yym4383 - if false { - } else { - z.F.DecMapStringStringX(yyv4382, false, d) - } - } - for { - yyj4378++ - if yyhl4378 { - yyb4378 = yyj4378 > l - } else { - yyb4378 = r.CheckBreak() - } - if yyb4378 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4378-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 { - yym4384 := z.EncBinary() - _ = yym4384 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4385 := !z.EncBinary() - yy2arr4385 := z.EncBasicHandle().StructToArray - var yyq4385 [4]bool - _, _, _ = yysep4385, yyq4385, yy2arr4385 - const yyr4385 bool = false - yyq4385[0] = x.Kind != "" - yyq4385[1] = x.APIVersion != "" - yyq4385[2] = true - var yynn4385 int - if yyr4385 || yy2arr4385 { - r.EncodeArrayStart(4) - } else { - yynn4385 = 1 - for _, b := range yyq4385 { - if b { - yynn4385++ - } - } - r.EncodeMapStart(yynn4385) - yynn4385 = 0 - } - if yyr4385 || yy2arr4385 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4385[0] { - yym4387 := z.EncBinary() - _ = yym4387 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4385[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4388 := z.EncBinary() - _ = yym4388 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4385 || yy2arr4385 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4385[1] { - yym4390 := z.EncBinary() - _ = yym4390 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4385[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4391 := z.EncBinary() - _ = yym4391 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4385 || yy2arr4385 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4385[2] { - yy4393 := &x.ListMeta - yym4394 := z.EncBinary() - _ = yym4394 - if false { - } else if z.HasExtensions() && z.EncExt(yy4393) { - } else { - z.EncFallback(yy4393) - } - } else { - r.EncodeNil() - } - } else { - if yyq4385[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4395 := &x.ListMeta - yym4396 := z.EncBinary() - _ = yym4396 - if false { - } else if z.HasExtensions() && z.EncExt(yy4395) { - } else { - z.EncFallback(yy4395) - } - } - } - if yyr4385 || yy2arr4385 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4398 := z.EncBinary() - _ = yym4398 - 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 { - yym4399 := z.EncBinary() - _ = yym4399 - if false { - } else { - h.encSliceConfigMap(([]ConfigMap)(x.Items), e) - } - } - } - if yyr4385 || yy2arr4385 { - 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 - yym4400 := z.DecBinary() - _ = yym4400 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4401 := r.ContainerType() - if yyct4401 == codecSelferValueTypeMap1234 { - yyl4401 := r.ReadMapStart() - if yyl4401 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4401, d) - } - } else if yyct4401 == codecSelferValueTypeArray1234 { - yyl4401 := r.ReadArrayStart() - if yyl4401 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4401, 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 yys4402Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4402Slc - var yyhl4402 bool = l >= 0 - for yyj4402 := 0; ; yyj4402++ { - if yyhl4402 { - if yyj4402 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4402Slc = r.DecodeBytes(yys4402Slc, true, true) - yys4402 := string(yys4402Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4402 { - 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 { - yyv4405 := &x.ListMeta - yym4406 := z.DecBinary() - _ = yym4406 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4405) { - } else { - z.DecFallback(yyv4405, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4407 := &x.Items - yym4408 := z.DecBinary() - _ = yym4408 - if false { - } else { - h.decSliceConfigMap((*[]ConfigMap)(yyv4407), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4402) - } // end switch yys4402 - } // end for yyj4402 - 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 yyj4409 int - var yyb4409 bool - var yyhl4409 bool = l >= 0 - yyj4409++ - if yyhl4409 { - yyb4409 = yyj4409 > l - } else { - yyb4409 = r.CheckBreak() - } - if yyb4409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4409++ - if yyhl4409 { - yyb4409 = yyj4409 > l - } else { - yyb4409 = r.CheckBreak() - } - if yyb4409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4409++ - if yyhl4409 { - yyb4409 = yyj4409 > l - } else { - yyb4409 = r.CheckBreak() - } - if yyb4409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4412 := &x.ListMeta - yym4413 := z.DecBinary() - _ = yym4413 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4412) { - } else { - z.DecFallback(yyv4412, false) - } - } - yyj4409++ - if yyhl4409 { - yyb4409 = yyj4409 > l - } else { - yyb4409 = r.CheckBreak() - } - if yyb4409 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4414 := &x.Items - yym4415 := z.DecBinary() - _ = yym4415 - if false { - } else { - h.decSliceConfigMap((*[]ConfigMap)(yyv4414), d) - } - } - for { - yyj4409++ - if yyhl4409 { - yyb4409 = yyj4409 > l - } else { - yyb4409 = r.CheckBreak() - } - if yyb4409 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4409-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x PatchType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4416 := z.EncBinary() - _ = yym4416 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *PatchType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym4417 := z.DecBinary() - _ = yym4417 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x ComponentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym4418 := z.EncBinary() - _ = yym4418 - 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 - yym4419 := z.DecBinary() - _ = yym4419 - 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 { - yym4420 := z.EncBinary() - _ = yym4420 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4421 := !z.EncBinary() - yy2arr4421 := z.EncBasicHandle().StructToArray - var yyq4421 [4]bool - _, _, _ = yysep4421, yyq4421, yy2arr4421 - const yyr4421 bool = false - yyq4421[2] = x.Message != "" - yyq4421[3] = x.Error != "" - var yynn4421 int - if yyr4421 || yy2arr4421 { - r.EncodeArrayStart(4) - } else { - yynn4421 = 2 - for _, b := range yyq4421 { - if b { - yynn4421++ - } - } - r.EncodeMapStart(yynn4421) - yynn4421 = 0 - } - if yyr4421 || yy2arr4421 { - 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 yyr4421 || yy2arr4421 { - 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 yyr4421 || yy2arr4421 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4421[2] { - yym4425 := z.EncBinary() - _ = yym4425 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4421[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4426 := z.EncBinary() - _ = yym4426 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr4421 || yy2arr4421 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4421[3] { - yym4428 := z.EncBinary() - _ = yym4428 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Error)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4421[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("error")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4429 := z.EncBinary() - _ = yym4429 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Error)) - } - } - } - if yyr4421 || yy2arr4421 { - 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 - yym4430 := z.DecBinary() - _ = yym4430 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4431 := r.ContainerType() - if yyct4431 == codecSelferValueTypeMap1234 { - yyl4431 := r.ReadMapStart() - if yyl4431 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4431, d) - } - } else if yyct4431 == codecSelferValueTypeArray1234 { - yyl4431 := r.ReadArrayStart() - if yyl4431 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4431, 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 yys4432Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4432Slc - var yyhl4432 bool = l >= 0 - for yyj4432 := 0; ; yyj4432++ { - if yyhl4432 { - if yyj4432 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4432Slc = r.DecodeBytes(yys4432Slc, true, true) - yys4432 := string(yys4432Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4432 { - 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, yys4432) - } // end switch yys4432 - } // end for yyj4432 - 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 yyj4437 int - var yyb4437 bool - var yyhl4437 bool = l >= 0 - yyj4437++ - if yyhl4437 { - yyb4437 = yyj4437 > l - } else { - yyb4437 = r.CheckBreak() - } - if yyb4437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ComponentConditionType(r.DecodeString()) - } - yyj4437++ - if yyhl4437 { - yyb4437 = yyj4437 > l - } else { - yyb4437 = r.CheckBreak() - } - if yyb4437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = ConditionStatus(r.DecodeString()) - } - yyj4437++ - if yyhl4437 { - yyb4437 = yyj4437 > l - } else { - yyb4437 = r.CheckBreak() - } - if yyb4437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj4437++ - if yyhl4437 { - yyb4437 = yyj4437 > l - } else { - yyb4437 = r.CheckBreak() - } - if yyb4437 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Error = "" - } else { - x.Error = string(r.DecodeString()) - } - for { - yyj4437++ - if yyhl4437 { - yyb4437 = yyj4437 > l - } else { - yyb4437 = r.CheckBreak() - } - if yyb4437 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4437-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 { - yym4442 := z.EncBinary() - _ = yym4442 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4443 := !z.EncBinary() - yy2arr4443 := z.EncBasicHandle().StructToArray - var yyq4443 [4]bool - _, _, _ = yysep4443, yyq4443, yy2arr4443 - const yyr4443 bool = false - yyq4443[0] = x.Kind != "" - yyq4443[1] = x.APIVersion != "" - yyq4443[2] = true - yyq4443[3] = len(x.Conditions) != 0 - var yynn4443 int - if yyr4443 || yy2arr4443 { - r.EncodeArrayStart(4) - } else { - yynn4443 = 0 - for _, b := range yyq4443 { - if b { - yynn4443++ - } - } - r.EncodeMapStart(yynn4443) - yynn4443 = 0 - } - if yyr4443 || yy2arr4443 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4443[0] { - yym4445 := z.EncBinary() - _ = yym4445 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4443[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4446 := z.EncBinary() - _ = yym4446 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4443 || yy2arr4443 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4443[1] { - yym4448 := z.EncBinary() - _ = yym4448 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4443[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4449 := z.EncBinary() - _ = yym4449 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4443 || yy2arr4443 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4443[2] { - yy4451 := &x.ObjectMeta - yy4451.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4443[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4452 := &x.ObjectMeta - yy4452.CodecEncodeSelf(e) - } - } - if yyr4443 || yy2arr4443 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4443[3] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym4454 := z.EncBinary() - _ = yym4454 - if false { - } else { - h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4443[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym4455 := z.EncBinary() - _ = yym4455 - if false { - } else { - h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e) - } - } - } - } - if yyr4443 || yy2arr4443 { - 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 - yym4456 := z.DecBinary() - _ = yym4456 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4457 := r.ContainerType() - if yyct4457 == codecSelferValueTypeMap1234 { - yyl4457 := r.ReadMapStart() - if yyl4457 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4457, d) - } - } else if yyct4457 == codecSelferValueTypeArray1234 { - yyl4457 := r.ReadArrayStart() - if yyl4457 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4457, 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 yys4458Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4458Slc - var yyhl4458 bool = l >= 0 - for yyj4458 := 0; ; yyj4458++ { - if yyhl4458 { - if yyj4458 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4458Slc = r.DecodeBytes(yys4458Slc, true, true) - yys4458 := string(yys4458Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4458 { - 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 { - yyv4461 := &x.ObjectMeta - yyv4461.CodecDecodeSelf(d) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv4462 := &x.Conditions - yym4463 := z.DecBinary() - _ = yym4463 - if false { - } else { - h.decSliceComponentCondition((*[]ComponentCondition)(yyv4462), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4458) - } // end switch yys4458 - } // end for yyj4458 - 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 yyj4464 int - var yyb4464 bool - var yyhl4464 bool = l >= 0 - yyj4464++ - if yyhl4464 { - yyb4464 = yyj4464 > l - } else { - yyb4464 = r.CheckBreak() - } - if yyb4464 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4464++ - if yyhl4464 { - yyb4464 = yyj4464 > l - } else { - yyb4464 = r.CheckBreak() - } - if yyb4464 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4464++ - if yyhl4464 { - yyb4464 = yyj4464 > l - } else { - yyb4464 = r.CheckBreak() - } - if yyb4464 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4467 := &x.ObjectMeta - yyv4467.CodecDecodeSelf(d) - } - yyj4464++ - if yyhl4464 { - yyb4464 = yyj4464 > l - } else { - yyb4464 = r.CheckBreak() - } - if yyb4464 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv4468 := &x.Conditions - yym4469 := z.DecBinary() - _ = yym4469 - if false { - } else { - h.decSliceComponentCondition((*[]ComponentCondition)(yyv4468), d) - } - } - for { - yyj4464++ - if yyhl4464 { - yyb4464 = yyj4464 > l - } else { - yyb4464 = r.CheckBreak() - } - if yyb4464 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4464-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 { - yym4470 := z.EncBinary() - _ = yym4470 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4471 := !z.EncBinary() - yy2arr4471 := z.EncBasicHandle().StructToArray - var yyq4471 [4]bool - _, _, _ = yysep4471, yyq4471, yy2arr4471 - const yyr4471 bool = false - yyq4471[0] = x.Kind != "" - yyq4471[1] = x.APIVersion != "" - yyq4471[2] = true - var yynn4471 int - if yyr4471 || yy2arr4471 { - r.EncodeArrayStart(4) - } else { - yynn4471 = 1 - for _, b := range yyq4471 { - if b { - yynn4471++ - } - } - r.EncodeMapStart(yynn4471) - yynn4471 = 0 - } - if yyr4471 || yy2arr4471 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4471[0] { - yym4473 := z.EncBinary() - _ = yym4473 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4471[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4474 := z.EncBinary() - _ = yym4474 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4471 || yy2arr4471 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4471[1] { - yym4476 := z.EncBinary() - _ = yym4476 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4471[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4477 := z.EncBinary() - _ = yym4477 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4471 || yy2arr4471 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4471[2] { - yy4479 := &x.ListMeta - yym4480 := z.EncBinary() - _ = yym4480 - if false { - } else if z.HasExtensions() && z.EncExt(yy4479) { - } else { - z.EncFallback(yy4479) - } - } else { - r.EncodeNil() - } - } else { - if yyq4471[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4481 := &x.ListMeta - yym4482 := z.EncBinary() - _ = yym4482 - if false { - } else if z.HasExtensions() && z.EncExt(yy4481) { - } else { - z.EncFallback(yy4481) - } - } - } - if yyr4471 || yy2arr4471 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym4484 := z.EncBinary() - _ = yym4484 - 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 { - yym4485 := z.EncBinary() - _ = yym4485 - if false { - } else { - h.encSliceComponentStatus(([]ComponentStatus)(x.Items), e) - } - } - } - if yyr4471 || yy2arr4471 { - 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 - yym4486 := z.DecBinary() - _ = yym4486 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4487 := r.ContainerType() - if yyct4487 == codecSelferValueTypeMap1234 { - yyl4487 := r.ReadMapStart() - if yyl4487 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4487, d) - } - } else if yyct4487 == codecSelferValueTypeArray1234 { - yyl4487 := r.ReadArrayStart() - if yyl4487 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4487, 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 yys4488Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4488Slc - var yyhl4488 bool = l >= 0 - for yyj4488 := 0; ; yyj4488++ { - if yyhl4488 { - if yyj4488 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4488Slc = r.DecodeBytes(yys4488Slc, true, true) - yys4488 := string(yys4488Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4488 { - 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 { - yyv4491 := &x.ListMeta - yym4492 := z.DecBinary() - _ = yym4492 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4491) { - } else { - z.DecFallback(yyv4491, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4493 := &x.Items - yym4494 := z.DecBinary() - _ = yym4494 - if false { - } else { - h.decSliceComponentStatus((*[]ComponentStatus)(yyv4493), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys4488) - } // end switch yys4488 - } // end for yyj4488 - 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 yyj4495 int - var yyb4495 bool - var yyhl4495 bool = l >= 0 - yyj4495++ - if yyhl4495 { - yyb4495 = yyj4495 > l - } else { - yyb4495 = r.CheckBreak() - } - if yyb4495 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4495++ - if yyhl4495 { - yyb4495 = yyj4495 > l - } else { - yyb4495 = r.CheckBreak() - } - if yyb4495 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4495++ - if yyhl4495 { - yyb4495 = yyj4495 > l - } else { - yyb4495 = r.CheckBreak() - } - if yyb4495 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv4498 := &x.ListMeta - yym4499 := z.DecBinary() - _ = yym4499 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4498) { - } else { - z.DecFallback(yyv4498, false) - } - } - yyj4495++ - if yyhl4495 { - yyb4495 = yyj4495 > l - } else { - yyb4495 = r.CheckBreak() - } - if yyb4495 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv4500 := &x.Items - yym4501 := z.DecBinary() - _ = yym4501 - if false { - } else { - h.decSliceComponentStatus((*[]ComponentStatus)(yyv4500), d) - } - } - for { - yyj4495++ - if yyhl4495 { - yyb4495 = yyj4495 > l - } else { - yyb4495 = r.CheckBreak() - } - if yyb4495 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4495-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 { - yym4502 := z.EncBinary() - _ = yym4502 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4503 := !z.EncBinary() - yy2arr4503 := z.EncBasicHandle().StructToArray - var yyq4503 [6]bool - _, _, _ = yysep4503, yyq4503, yy2arr4503 - const yyr4503 bool = false - yyq4503[0] = x.Capabilities != nil - yyq4503[1] = x.Privileged != nil - yyq4503[2] = x.SELinuxOptions != nil - yyq4503[3] = x.RunAsUser != nil - yyq4503[4] = x.RunAsNonRoot != nil - yyq4503[5] = x.ReadOnlyRootFilesystem != nil - var yynn4503 int - if yyr4503 || yy2arr4503 { - r.EncodeArrayStart(6) - } else { - yynn4503 = 0 - for _, b := range yyq4503 { - if b { - yynn4503++ - } - } - r.EncodeMapStart(yynn4503) - yynn4503 = 0 - } - if yyr4503 || yy2arr4503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4503[0] { - if x.Capabilities == nil { - r.EncodeNil() - } else { - x.Capabilities.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4503[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 yyr4503 || yy2arr4503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4503[1] { - if x.Privileged == nil { - r.EncodeNil() - } else { - yy4506 := *x.Privileged - yym4507 := z.EncBinary() - _ = yym4507 - if false { - } else { - r.EncodeBool(bool(yy4506)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4503[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("privileged")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Privileged == nil { - r.EncodeNil() - } else { - yy4508 := *x.Privileged - yym4509 := z.EncBinary() - _ = yym4509 - if false { - } else { - r.EncodeBool(bool(yy4508)) - } - } - } - } - if yyr4503 || yy2arr4503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4503[2] { - if x.SELinuxOptions == nil { - r.EncodeNil() - } else { - x.SELinuxOptions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq4503[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 yyr4503 || yy2arr4503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4503[3] { - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy4512 := *x.RunAsUser - yym4513 := z.EncBinary() - _ = yym4513 - if false { - } else { - r.EncodeInt(int64(yy4512)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4503[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsUser == nil { - r.EncodeNil() - } else { - yy4514 := *x.RunAsUser - yym4515 := z.EncBinary() - _ = yym4515 - if false { - } else { - r.EncodeInt(int64(yy4514)) - } - } - } - } - if yyr4503 || yy2arr4503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4503[4] { - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy4517 := *x.RunAsNonRoot - yym4518 := z.EncBinary() - _ = yym4518 - if false { - } else { - r.EncodeBool(bool(yy4517)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4503[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RunAsNonRoot == nil { - r.EncodeNil() - } else { - yy4519 := *x.RunAsNonRoot - yym4520 := z.EncBinary() - _ = yym4520 - if false { - } else { - r.EncodeBool(bool(yy4519)) - } - } - } - } - if yyr4503 || yy2arr4503 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4503[5] { - if x.ReadOnlyRootFilesystem == nil { - r.EncodeNil() - } else { - yy4522 := *x.ReadOnlyRootFilesystem - yym4523 := z.EncBinary() - _ = yym4523 - if false { - } else { - r.EncodeBool(bool(yy4522)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq4503[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnlyRootFilesystem")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ReadOnlyRootFilesystem == nil { - r.EncodeNil() - } else { - yy4524 := *x.ReadOnlyRootFilesystem - yym4525 := z.EncBinary() - _ = yym4525 - if false { - } else { - r.EncodeBool(bool(yy4524)) - } - } - } - } - if yyr4503 || yy2arr4503 { - 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 - yym4526 := z.DecBinary() - _ = yym4526 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4527 := r.ContainerType() - if yyct4527 == codecSelferValueTypeMap1234 { - yyl4527 := r.ReadMapStart() - if yyl4527 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4527, d) - } - } else if yyct4527 == codecSelferValueTypeArray1234 { - yyl4527 := r.ReadArrayStart() - if yyl4527 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4527, 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 yys4528Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4528Slc - var yyhl4528 bool = l >= 0 - for yyj4528 := 0; ; yyj4528++ { - if yyhl4528 { - if yyj4528 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4528Slc = r.DecodeBytes(yys4528Slc, true, true) - yys4528 := string(yys4528Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4528 { - 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) - } - yym4531 := z.DecBinary() - _ = yym4531 - 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) - } - yym4534 := z.DecBinary() - _ = yym4534 - 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) - } - yym4536 := z.DecBinary() - _ = yym4536 - 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) - } - yym4538 := z.DecBinary() - _ = yym4538 - if false { - } else { - *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys4528) - } // end switch yys4528 - } // end for yyj4528 - 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 yyj4539 int - var yyb4539 bool - var yyhl4539 bool = l >= 0 - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - 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) - } - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - 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) - } - yym4542 := z.DecBinary() - _ = yym4542 - if false { - } else { - *((*bool)(x.Privileged)) = r.DecodeBool() - } - } - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - 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) - } - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - 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) - } - yym4545 := z.DecBinary() - _ = yym4545 - if false { - } else { - *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) - } - } - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - 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) - } - yym4547 := z.DecBinary() - _ = yym4547 - if false { - } else { - *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() - } - } - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - 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) - } - yym4549 := z.DecBinary() - _ = yym4549 - if false { - } else { - *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool() - } - } - for { - yyj4539++ - if yyhl4539 { - yyb4539 = yyj4539 > l - } else { - yyb4539 = r.CheckBreak() - } - if yyb4539 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4539-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 { - yym4550 := z.EncBinary() - _ = yym4550 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4551 := !z.EncBinary() - yy2arr4551 := z.EncBasicHandle().StructToArray - var yyq4551 [4]bool - _, _, _ = yysep4551, yyq4551, yy2arr4551 - const yyr4551 bool = false - yyq4551[0] = x.User != "" - yyq4551[1] = x.Role != "" - yyq4551[2] = x.Type != "" - yyq4551[3] = x.Level != "" - var yynn4551 int - if yyr4551 || yy2arr4551 { - r.EncodeArrayStart(4) - } else { - yynn4551 = 0 - for _, b := range yyq4551 { - if b { - yynn4551++ - } - } - r.EncodeMapStart(yynn4551) - yynn4551 = 0 - } - if yyr4551 || yy2arr4551 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4551[0] { - yym4553 := z.EncBinary() - _ = yym4553 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4551[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("user")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4554 := z.EncBinary() - _ = yym4554 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - } - if yyr4551 || yy2arr4551 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4551[1] { - yym4556 := z.EncBinary() - _ = yym4556 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Role)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4551[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("role")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4557 := z.EncBinary() - _ = yym4557 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Role)) - } - } - } - if yyr4551 || yy2arr4551 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4551[2] { - yym4559 := z.EncBinary() - _ = yym4559 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4551[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4560 := z.EncBinary() - _ = yym4560 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Type)) - } - } - } - if yyr4551 || yy2arr4551 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4551[3] { - yym4562 := z.EncBinary() - _ = yym4562 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Level)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4551[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("level")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4563 := z.EncBinary() - _ = yym4563 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Level)) - } - } - } - if yyr4551 || yy2arr4551 { - 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 - yym4564 := z.DecBinary() - _ = yym4564 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4565 := r.ContainerType() - if yyct4565 == codecSelferValueTypeMap1234 { - yyl4565 := r.ReadMapStart() - if yyl4565 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4565, d) - } - } else if yyct4565 == codecSelferValueTypeArray1234 { - yyl4565 := r.ReadArrayStart() - if yyl4565 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4565, 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 yys4566Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4566Slc - var yyhl4566 bool = l >= 0 - for yyj4566 := 0; ; yyj4566++ { - if yyhl4566 { - if yyj4566 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4566Slc = r.DecodeBytes(yys4566Slc, true, true) - yys4566 := string(yys4566Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4566 { - 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, yys4566) - } // end switch yys4566 - } // end for yyj4566 - 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 yyj4571 int - var yyb4571 bool - var yyhl4571 bool = l >= 0 - yyj4571++ - if yyhl4571 { - yyb4571 = yyj4571 > l - } else { - yyb4571 = r.CheckBreak() - } - if yyb4571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - yyj4571++ - if yyhl4571 { - yyb4571 = yyj4571 > l - } else { - yyb4571 = r.CheckBreak() - } - if yyb4571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Role = "" - } else { - x.Role = string(r.DecodeString()) - } - yyj4571++ - if yyhl4571 { - yyb4571 = yyj4571 > l - } else { - yyb4571 = r.CheckBreak() - } - if yyb4571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = string(r.DecodeString()) - } - yyj4571++ - if yyhl4571 { - yyb4571 = yyj4571 > l - } else { - yyb4571 = r.CheckBreak() - } - if yyb4571 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Level = "" - } else { - x.Level = string(r.DecodeString()) - } - for { - yyj4571++ - if yyhl4571 { - yyb4571 = yyj4571 > l - } else { - yyb4571 = r.CheckBreak() - } - if yyb4571 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4571-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 { - yym4576 := z.EncBinary() - _ = yym4576 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep4577 := !z.EncBinary() - yy2arr4577 := z.EncBasicHandle().StructToArray - var yyq4577 [5]bool - _, _, _ = yysep4577, yyq4577, yy2arr4577 - const yyr4577 bool = false - yyq4577[0] = x.Kind != "" - yyq4577[1] = x.APIVersion != "" - yyq4577[2] = true - var yynn4577 int - if yyr4577 || yy2arr4577 { - r.EncodeArrayStart(5) - } else { - yynn4577 = 2 - for _, b := range yyq4577 { - if b { - yynn4577++ - } - } - r.EncodeMapStart(yynn4577) - yynn4577 = 0 - } - if yyr4577 || yy2arr4577 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4577[0] { - yym4579 := z.EncBinary() - _ = yym4579 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4577[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4580 := z.EncBinary() - _ = yym4580 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr4577 || yy2arr4577 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4577[1] { - yym4582 := z.EncBinary() - _ = yym4582 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq4577[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4583 := z.EncBinary() - _ = yym4583 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr4577 || yy2arr4577 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4577[2] { - yy4585 := &x.ObjectMeta - yy4585.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq4577[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4586 := &x.ObjectMeta - yy4586.CodecEncodeSelf(e) - } - } - if yyr4577 || yy2arr4577 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym4588 := z.EncBinary() - _ = yym4588 - 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) - yym4589 := z.EncBinary() - _ = yym4589 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Range)) - } - } - if yyr4577 || yy2arr4577 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym4591 := z.EncBinary() - _ = yym4591 - 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 { - yym4592 := z.EncBinary() - _ = yym4592 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) - } - } - } - if yyr4577 || yy2arr4577 { - 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 - yym4593 := z.DecBinary() - _ = yym4593 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct4594 := r.ContainerType() - if yyct4594 == codecSelferValueTypeMap1234 { - yyl4594 := r.ReadMapStart() - if yyl4594 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl4594, d) - } - } else if yyct4594 == codecSelferValueTypeArray1234 { - yyl4594 := r.ReadArrayStart() - if yyl4594 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl4594, 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 yys4595Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4595Slc - var yyhl4595 bool = l >= 0 - for yyj4595 := 0; ; yyj4595++ { - if yyhl4595 { - if yyj4595 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4595Slc = r.DecodeBytes(yys4595Slc, true, true) - yys4595 := string(yys4595Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4595 { - 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 { - yyv4598 := &x.ObjectMeta - yyv4598.CodecDecodeSelf(d) - } - case "range": - if r.TryDecodeAsNil() { - x.Range = "" - } else { - x.Range = string(r.DecodeString()) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4600 := &x.Data - yym4601 := z.DecBinary() - _ = yym4601 - if false { - } else { - *yyv4600 = r.DecodeBytes(*(*[]byte)(yyv4600), false, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys4595) - } // end switch yys4595 - } // end for yyj4595 - 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 yyj4602 int - var yyb4602 bool - var yyhl4602 bool = l >= 0 - yyj4602++ - if yyhl4602 { - yyb4602 = yyj4602 > l - } else { - yyb4602 = r.CheckBreak() - } - if yyb4602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj4602++ - if yyhl4602 { - yyb4602 = yyj4602 > l - } else { - yyb4602 = r.CheckBreak() - } - if yyb4602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj4602++ - if yyhl4602 { - yyb4602 = yyj4602 > l - } else { - yyb4602 = r.CheckBreak() - } - if yyb4602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} - } else { - yyv4605 := &x.ObjectMeta - yyv4605.CodecDecodeSelf(d) - } - yyj4602++ - if yyhl4602 { - yyb4602 = yyj4602 > l - } else { - yyb4602 = r.CheckBreak() - } - if yyb4602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Range = "" - } else { - x.Range = string(r.DecodeString()) - } - yyj4602++ - if yyhl4602 { - yyb4602 = yyj4602 > l - } else { - yyb4602 = r.CheckBreak() - } - if yyb4602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv4607 := &x.Data - yym4608 := z.DecBinary() - _ = yym4608 - if false { - } else { - *yyv4607 = r.DecodeBytes(*(*[]byte)(yyv4607), false, false) - } - } - for { - yyj4602++ - if yyhl4602 { - yyb4602 = yyj4602 > l - } else { - yyb4602 = r.CheckBreak() - } - if yyb4602 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4602-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 _, yyv4609 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4610 := &yyv4609 - yy4610.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 - - yyv4611 := *v - yyh4611, yyl4611 := z.DecSliceHelperStart() - var yyc4611 bool - if yyl4611 == 0 { - if yyv4611 == nil { - yyv4611 = []OwnerReference{} - yyc4611 = true - } else if len(yyv4611) != 0 { - yyv4611 = yyv4611[:0] - yyc4611 = true - } - } else if yyl4611 > 0 { - var yyrr4611, yyrl4611 int - var yyrt4611 bool - if yyl4611 > cap(yyv4611) { - - yyrg4611 := len(yyv4611) > 0 - yyv24611 := yyv4611 - yyrl4611, yyrt4611 = z.DecInferLen(yyl4611, z.DecBasicHandle().MaxInitLen, 72) - if yyrt4611 { - if yyrl4611 <= cap(yyv4611) { - yyv4611 = yyv4611[:yyrl4611] - } else { - yyv4611 = make([]OwnerReference, yyrl4611) - } - } else { - yyv4611 = make([]OwnerReference, yyrl4611) - } - yyc4611 = true - yyrr4611 = len(yyv4611) - if yyrg4611 { - copy(yyv4611, yyv24611) - } - } else if yyl4611 != len(yyv4611) { - yyv4611 = yyv4611[:yyl4611] - yyc4611 = true - } - yyj4611 := 0 - for ; yyj4611 < yyrr4611; yyj4611++ { - yyh4611.ElemContainerState(yyj4611) - if r.TryDecodeAsNil() { - yyv4611[yyj4611] = OwnerReference{} - } else { - yyv4612 := &yyv4611[yyj4611] - yyv4612.CodecDecodeSelf(d) - } - - } - if yyrt4611 { - for ; yyj4611 < yyl4611; yyj4611++ { - yyv4611 = append(yyv4611, OwnerReference{}) - yyh4611.ElemContainerState(yyj4611) - if r.TryDecodeAsNil() { - yyv4611[yyj4611] = OwnerReference{} - } else { - yyv4613 := &yyv4611[yyj4611] - yyv4613.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4611 := 0 - for ; !r.CheckBreak(); yyj4611++ { - - if yyj4611 >= len(yyv4611) { - yyv4611 = append(yyv4611, OwnerReference{}) // var yyz4611 OwnerReference - yyc4611 = true - } - yyh4611.ElemContainerState(yyj4611) - if yyj4611 < len(yyv4611) { - if r.TryDecodeAsNil() { - yyv4611[yyj4611] = OwnerReference{} - } else { - yyv4614 := &yyv4611[yyj4611] - yyv4614.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4611 < len(yyv4611) { - yyv4611 = yyv4611[:yyj4611] - yyc4611 = true - } else if yyj4611 == 0 && yyv4611 == nil { - yyv4611 = []OwnerReference{} - yyc4611 = true - } - } - yyh4611.End() - if yyc4611 { - *v = yyv4611 - } -} - -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 _, yyv4615 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4615.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 - - yyv4616 := *v - yyh4616, yyl4616 := z.DecSliceHelperStart() - var yyc4616 bool - if yyl4616 == 0 { - if yyv4616 == nil { - yyv4616 = []PersistentVolumeAccessMode{} - yyc4616 = true - } else if len(yyv4616) != 0 { - yyv4616 = yyv4616[:0] - yyc4616 = true - } - } else if yyl4616 > 0 { - var yyrr4616, yyrl4616 int - var yyrt4616 bool - if yyl4616 > cap(yyv4616) { - - yyrl4616, yyrt4616 = z.DecInferLen(yyl4616, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4616 { - if yyrl4616 <= cap(yyv4616) { - yyv4616 = yyv4616[:yyrl4616] - } else { - yyv4616 = make([]PersistentVolumeAccessMode, yyrl4616) - } - } else { - yyv4616 = make([]PersistentVolumeAccessMode, yyrl4616) - } - yyc4616 = true - yyrr4616 = len(yyv4616) - } else if yyl4616 != len(yyv4616) { - yyv4616 = yyv4616[:yyl4616] - yyc4616 = true - } - yyj4616 := 0 - for ; yyj4616 < yyrr4616; yyj4616++ { - yyh4616.ElemContainerState(yyj4616) - if r.TryDecodeAsNil() { - yyv4616[yyj4616] = "" - } else { - yyv4616[yyj4616] = PersistentVolumeAccessMode(r.DecodeString()) - } - - } - if yyrt4616 { - for ; yyj4616 < yyl4616; yyj4616++ { - yyv4616 = append(yyv4616, "") - yyh4616.ElemContainerState(yyj4616) - if r.TryDecodeAsNil() { - yyv4616[yyj4616] = "" - } else { - yyv4616[yyj4616] = PersistentVolumeAccessMode(r.DecodeString()) - } - - } - } - - } else { - yyj4616 := 0 - for ; !r.CheckBreak(); yyj4616++ { - - if yyj4616 >= len(yyv4616) { - yyv4616 = append(yyv4616, "") // var yyz4616 PersistentVolumeAccessMode - yyc4616 = true - } - yyh4616.ElemContainerState(yyj4616) - if yyj4616 < len(yyv4616) { - if r.TryDecodeAsNil() { - yyv4616[yyj4616] = "" - } else { - yyv4616[yyj4616] = PersistentVolumeAccessMode(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4616 < len(yyv4616) { - yyv4616 = yyv4616[:yyj4616] - yyc4616 = true - } else if yyj4616 == 0 && yyv4616 == nil { - yyv4616 = []PersistentVolumeAccessMode{} - yyc4616 = true - } - } - yyh4616.End() - if yyc4616 { - *v = yyv4616 - } -} - -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 _, yyv4620 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4621 := &yyv4620 - yy4621.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 - - yyv4622 := *v - yyh4622, yyl4622 := z.DecSliceHelperStart() - var yyc4622 bool - if yyl4622 == 0 { - if yyv4622 == nil { - yyv4622 = []PersistentVolume{} - yyc4622 = true - } else if len(yyv4622) != 0 { - yyv4622 = yyv4622[:0] - yyc4622 = true - } - } else if yyl4622 > 0 { - var yyrr4622, yyrl4622 int - var yyrt4622 bool - if yyl4622 > cap(yyv4622) { - - yyrg4622 := len(yyv4622) > 0 - yyv24622 := yyv4622 - yyrl4622, yyrt4622 = z.DecInferLen(yyl4622, z.DecBasicHandle().MaxInitLen, 496) - if yyrt4622 { - if yyrl4622 <= cap(yyv4622) { - yyv4622 = yyv4622[:yyrl4622] - } else { - yyv4622 = make([]PersistentVolume, yyrl4622) - } - } else { - yyv4622 = make([]PersistentVolume, yyrl4622) - } - yyc4622 = true - yyrr4622 = len(yyv4622) - if yyrg4622 { - copy(yyv4622, yyv24622) - } - } else if yyl4622 != len(yyv4622) { - yyv4622 = yyv4622[:yyl4622] - yyc4622 = true - } - yyj4622 := 0 - for ; yyj4622 < yyrr4622; yyj4622++ { - yyh4622.ElemContainerState(yyj4622) - if r.TryDecodeAsNil() { - yyv4622[yyj4622] = PersistentVolume{} - } else { - yyv4623 := &yyv4622[yyj4622] - yyv4623.CodecDecodeSelf(d) - } - - } - if yyrt4622 { - for ; yyj4622 < yyl4622; yyj4622++ { - yyv4622 = append(yyv4622, PersistentVolume{}) - yyh4622.ElemContainerState(yyj4622) - if r.TryDecodeAsNil() { - yyv4622[yyj4622] = PersistentVolume{} - } else { - yyv4624 := &yyv4622[yyj4622] - yyv4624.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4622 := 0 - for ; !r.CheckBreak(); yyj4622++ { - - if yyj4622 >= len(yyv4622) { - yyv4622 = append(yyv4622, PersistentVolume{}) // var yyz4622 PersistentVolume - yyc4622 = true - } - yyh4622.ElemContainerState(yyj4622) - if yyj4622 < len(yyv4622) { - if r.TryDecodeAsNil() { - yyv4622[yyj4622] = PersistentVolume{} - } else { - yyv4625 := &yyv4622[yyj4622] - yyv4625.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4622 < len(yyv4622) { - yyv4622 = yyv4622[:yyj4622] - yyc4622 = true - } else if yyj4622 == 0 && yyv4622 == nil { - yyv4622 = []PersistentVolume{} - yyc4622 = true - } - } - yyh4622.End() - if yyc4622 { - *v = yyv4622 - } -} - -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 _, yyv4626 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4627 := &yyv4626 - yy4627.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 - - yyv4628 := *v - yyh4628, yyl4628 := z.DecSliceHelperStart() - var yyc4628 bool - if yyl4628 == 0 { - if yyv4628 == nil { - yyv4628 = []PersistentVolumeClaim{} - yyc4628 = true - } else if len(yyv4628) != 0 { - yyv4628 = yyv4628[:0] - yyc4628 = true - } - } else if yyl4628 > 0 { - var yyrr4628, yyrl4628 int - var yyrt4628 bool - if yyl4628 > cap(yyv4628) { - - yyrg4628 := len(yyv4628) > 0 - yyv24628 := yyv4628 - yyrl4628, yyrt4628 = z.DecInferLen(yyl4628, z.DecBasicHandle().MaxInitLen, 368) - if yyrt4628 { - if yyrl4628 <= cap(yyv4628) { - yyv4628 = yyv4628[:yyrl4628] - } else { - yyv4628 = make([]PersistentVolumeClaim, yyrl4628) - } - } else { - yyv4628 = make([]PersistentVolumeClaim, yyrl4628) - } - yyc4628 = true - yyrr4628 = len(yyv4628) - if yyrg4628 { - copy(yyv4628, yyv24628) - } - } else if yyl4628 != len(yyv4628) { - yyv4628 = yyv4628[:yyl4628] - yyc4628 = true - } - yyj4628 := 0 - for ; yyj4628 < yyrr4628; yyj4628++ { - yyh4628.ElemContainerState(yyj4628) - if r.TryDecodeAsNil() { - yyv4628[yyj4628] = PersistentVolumeClaim{} - } else { - yyv4629 := &yyv4628[yyj4628] - yyv4629.CodecDecodeSelf(d) - } - - } - if yyrt4628 { - for ; yyj4628 < yyl4628; yyj4628++ { - yyv4628 = append(yyv4628, PersistentVolumeClaim{}) - yyh4628.ElemContainerState(yyj4628) - if r.TryDecodeAsNil() { - yyv4628[yyj4628] = PersistentVolumeClaim{} - } else { - yyv4630 := &yyv4628[yyj4628] - yyv4630.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4628 := 0 - for ; !r.CheckBreak(); yyj4628++ { - - if yyj4628 >= len(yyv4628) { - yyv4628 = append(yyv4628, PersistentVolumeClaim{}) // var yyz4628 PersistentVolumeClaim - yyc4628 = true - } - yyh4628.ElemContainerState(yyj4628) - if yyj4628 < len(yyv4628) { - if r.TryDecodeAsNil() { - yyv4628[yyj4628] = PersistentVolumeClaim{} - } else { - yyv4631 := &yyv4628[yyj4628] - yyv4631.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4628 < len(yyv4628) { - yyv4628 = yyv4628[:yyj4628] - yyc4628 = true - } else if yyj4628 == 0 && yyv4628 == nil { - yyv4628 = []PersistentVolumeClaim{} - yyc4628 = true - } - } - yyh4628.End() - if yyc4628 { - *v = yyv4628 - } -} - -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 _, yyv4632 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4633 := &yyv4632 - yy4633.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 - - yyv4634 := *v - yyh4634, yyl4634 := z.DecSliceHelperStart() - var yyc4634 bool - if yyl4634 == 0 { - if yyv4634 == nil { - yyv4634 = []KeyToPath{} - yyc4634 = true - } else if len(yyv4634) != 0 { - yyv4634 = yyv4634[:0] - yyc4634 = true - } - } else if yyl4634 > 0 { - var yyrr4634, yyrl4634 int - var yyrt4634 bool - if yyl4634 > cap(yyv4634) { - - yyrg4634 := len(yyv4634) > 0 - yyv24634 := yyv4634 - yyrl4634, yyrt4634 = z.DecInferLen(yyl4634, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4634 { - if yyrl4634 <= cap(yyv4634) { - yyv4634 = yyv4634[:yyrl4634] - } else { - yyv4634 = make([]KeyToPath, yyrl4634) - } - } else { - yyv4634 = make([]KeyToPath, yyrl4634) - } - yyc4634 = true - yyrr4634 = len(yyv4634) - if yyrg4634 { - copy(yyv4634, yyv24634) - } - } else if yyl4634 != len(yyv4634) { - yyv4634 = yyv4634[:yyl4634] - yyc4634 = true - } - yyj4634 := 0 - for ; yyj4634 < yyrr4634; yyj4634++ { - yyh4634.ElemContainerState(yyj4634) - if r.TryDecodeAsNil() { - yyv4634[yyj4634] = KeyToPath{} - } else { - yyv4635 := &yyv4634[yyj4634] - yyv4635.CodecDecodeSelf(d) - } - - } - if yyrt4634 { - for ; yyj4634 < yyl4634; yyj4634++ { - yyv4634 = append(yyv4634, KeyToPath{}) - yyh4634.ElemContainerState(yyj4634) - if r.TryDecodeAsNil() { - yyv4634[yyj4634] = KeyToPath{} - } else { - yyv4636 := &yyv4634[yyj4634] - yyv4636.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4634 := 0 - for ; !r.CheckBreak(); yyj4634++ { - - if yyj4634 >= len(yyv4634) { - yyv4634 = append(yyv4634, KeyToPath{}) // var yyz4634 KeyToPath - yyc4634 = true - } - yyh4634.ElemContainerState(yyj4634) - if yyj4634 < len(yyv4634) { - if r.TryDecodeAsNil() { - yyv4634[yyj4634] = KeyToPath{} - } else { - yyv4637 := &yyv4634[yyj4634] - yyv4637.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4634 < len(yyv4634) { - yyv4634 = yyv4634[:yyj4634] - yyc4634 = true - } else if yyj4634 == 0 && yyv4634 == nil { - yyv4634 = []KeyToPath{} - yyc4634 = true - } - } - yyh4634.End() - if yyc4634 { - *v = yyv4634 - } -} - -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 _, yyv4638 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4639 := &yyv4638 - yy4639.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 - - yyv4640 := *v - yyh4640, yyl4640 := z.DecSliceHelperStart() - var yyc4640 bool - if yyl4640 == 0 { - if yyv4640 == nil { - yyv4640 = []DownwardAPIVolumeFile{} - yyc4640 = true - } else if len(yyv4640) != 0 { - yyv4640 = yyv4640[:0] - yyc4640 = true - } - } else if yyl4640 > 0 { - var yyrr4640, yyrl4640 int - var yyrt4640 bool - if yyl4640 > cap(yyv4640) { - - yyrg4640 := len(yyv4640) > 0 - yyv24640 := yyv4640 - yyrl4640, yyrt4640 = z.DecInferLen(yyl4640, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4640 { - if yyrl4640 <= cap(yyv4640) { - yyv4640 = yyv4640[:yyrl4640] - } else { - yyv4640 = make([]DownwardAPIVolumeFile, yyrl4640) - } - } else { - yyv4640 = make([]DownwardAPIVolumeFile, yyrl4640) - } - yyc4640 = true - yyrr4640 = len(yyv4640) - if yyrg4640 { - copy(yyv4640, yyv24640) - } - } else if yyl4640 != len(yyv4640) { - yyv4640 = yyv4640[:yyl4640] - yyc4640 = true - } - yyj4640 := 0 - for ; yyj4640 < yyrr4640; yyj4640++ { - yyh4640.ElemContainerState(yyj4640) - if r.TryDecodeAsNil() { - yyv4640[yyj4640] = DownwardAPIVolumeFile{} - } else { - yyv4641 := &yyv4640[yyj4640] - yyv4641.CodecDecodeSelf(d) - } - - } - if yyrt4640 { - for ; yyj4640 < yyl4640; yyj4640++ { - yyv4640 = append(yyv4640, DownwardAPIVolumeFile{}) - yyh4640.ElemContainerState(yyj4640) - if r.TryDecodeAsNil() { - yyv4640[yyj4640] = DownwardAPIVolumeFile{} - } else { - yyv4642 := &yyv4640[yyj4640] - yyv4642.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4640 := 0 - for ; !r.CheckBreak(); yyj4640++ { - - if yyj4640 >= len(yyv4640) { - yyv4640 = append(yyv4640, DownwardAPIVolumeFile{}) // var yyz4640 DownwardAPIVolumeFile - yyc4640 = true - } - yyh4640.ElemContainerState(yyj4640) - if yyj4640 < len(yyv4640) { - if r.TryDecodeAsNil() { - yyv4640[yyj4640] = DownwardAPIVolumeFile{} - } else { - yyv4643 := &yyv4640[yyj4640] - yyv4643.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4640 < len(yyv4640) { - yyv4640 = yyv4640[:yyj4640] - yyc4640 = true - } else if yyj4640 == 0 && yyv4640 == nil { - yyv4640 = []DownwardAPIVolumeFile{} - yyc4640 = true - } - } - yyh4640.End() - if yyc4640 { - *v = yyv4640 - } -} - -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 _, yyv4644 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4645 := &yyv4644 - yy4645.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 - - yyv4646 := *v - yyh4646, yyl4646 := z.DecSliceHelperStart() - var yyc4646 bool - if yyl4646 == 0 { - if yyv4646 == nil { - yyv4646 = []HTTPHeader{} - yyc4646 = true - } else if len(yyv4646) != 0 { - yyv4646 = yyv4646[:0] - yyc4646 = true - } - } else if yyl4646 > 0 { - var yyrr4646, yyrl4646 int - var yyrt4646 bool - if yyl4646 > cap(yyv4646) { - - yyrg4646 := len(yyv4646) > 0 - yyv24646 := yyv4646 - yyrl4646, yyrt4646 = z.DecInferLen(yyl4646, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4646 { - if yyrl4646 <= cap(yyv4646) { - yyv4646 = yyv4646[:yyrl4646] - } else { - yyv4646 = make([]HTTPHeader, yyrl4646) - } - } else { - yyv4646 = make([]HTTPHeader, yyrl4646) - } - yyc4646 = true - yyrr4646 = len(yyv4646) - if yyrg4646 { - copy(yyv4646, yyv24646) - } - } else if yyl4646 != len(yyv4646) { - yyv4646 = yyv4646[:yyl4646] - yyc4646 = true - } - yyj4646 := 0 - for ; yyj4646 < yyrr4646; yyj4646++ { - yyh4646.ElemContainerState(yyj4646) - if r.TryDecodeAsNil() { - yyv4646[yyj4646] = HTTPHeader{} - } else { - yyv4647 := &yyv4646[yyj4646] - yyv4647.CodecDecodeSelf(d) - } - - } - if yyrt4646 { - for ; yyj4646 < yyl4646; yyj4646++ { - yyv4646 = append(yyv4646, HTTPHeader{}) - yyh4646.ElemContainerState(yyj4646) - if r.TryDecodeAsNil() { - yyv4646[yyj4646] = HTTPHeader{} - } else { - yyv4648 := &yyv4646[yyj4646] - yyv4648.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4646 := 0 - for ; !r.CheckBreak(); yyj4646++ { - - if yyj4646 >= len(yyv4646) { - yyv4646 = append(yyv4646, HTTPHeader{}) // var yyz4646 HTTPHeader - yyc4646 = true - } - yyh4646.ElemContainerState(yyj4646) - if yyj4646 < len(yyv4646) { - if r.TryDecodeAsNil() { - yyv4646[yyj4646] = HTTPHeader{} - } else { - yyv4649 := &yyv4646[yyj4646] - yyv4649.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4646 < len(yyv4646) { - yyv4646 = yyv4646[:yyj4646] - yyc4646 = true - } else if yyj4646 == 0 && yyv4646 == nil { - yyv4646 = []HTTPHeader{} - yyc4646 = true - } - } - yyh4646.End() - if yyc4646 { - *v = yyv4646 - } -} - -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 _, yyv4650 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4650.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 - - yyv4651 := *v - yyh4651, yyl4651 := z.DecSliceHelperStart() - var yyc4651 bool - if yyl4651 == 0 { - if yyv4651 == nil { - yyv4651 = []Capability{} - yyc4651 = true - } else if len(yyv4651) != 0 { - yyv4651 = yyv4651[:0] - yyc4651 = true - } - } else if yyl4651 > 0 { - var yyrr4651, yyrl4651 int - var yyrt4651 bool - if yyl4651 > cap(yyv4651) { - - yyrl4651, yyrt4651 = z.DecInferLen(yyl4651, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4651 { - if yyrl4651 <= cap(yyv4651) { - yyv4651 = yyv4651[:yyrl4651] - } else { - yyv4651 = make([]Capability, yyrl4651) - } - } else { - yyv4651 = make([]Capability, yyrl4651) - } - yyc4651 = true - yyrr4651 = len(yyv4651) - } else if yyl4651 != len(yyv4651) { - yyv4651 = yyv4651[:yyl4651] - yyc4651 = true - } - yyj4651 := 0 - for ; yyj4651 < yyrr4651; yyj4651++ { - yyh4651.ElemContainerState(yyj4651) - if r.TryDecodeAsNil() { - yyv4651[yyj4651] = "" - } else { - yyv4651[yyj4651] = Capability(r.DecodeString()) - } - - } - if yyrt4651 { - for ; yyj4651 < yyl4651; yyj4651++ { - yyv4651 = append(yyv4651, "") - yyh4651.ElemContainerState(yyj4651) - if r.TryDecodeAsNil() { - yyv4651[yyj4651] = "" - } else { - yyv4651[yyj4651] = Capability(r.DecodeString()) - } - - } - } - - } else { - yyj4651 := 0 - for ; !r.CheckBreak(); yyj4651++ { - - if yyj4651 >= len(yyv4651) { - yyv4651 = append(yyv4651, "") // var yyz4651 Capability - yyc4651 = true - } - yyh4651.ElemContainerState(yyj4651) - if yyj4651 < len(yyv4651) { - if r.TryDecodeAsNil() { - yyv4651[yyj4651] = "" - } else { - yyv4651[yyj4651] = Capability(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4651 < len(yyv4651) { - yyv4651 = yyv4651[:yyj4651] - yyc4651 = true - } else if yyj4651 == 0 && yyv4651 == nil { - yyv4651 = []Capability{} - yyc4651 = true - } - } - yyh4651.End() - if yyc4651 { - *v = yyv4651 - } -} - -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 _, yyv4655 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4656 := &yyv4655 - yy4656.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 - - yyv4657 := *v - yyh4657, yyl4657 := z.DecSliceHelperStart() - var yyc4657 bool - if yyl4657 == 0 { - if yyv4657 == nil { - yyv4657 = []ContainerPort{} - yyc4657 = true - } else if len(yyv4657) != 0 { - yyv4657 = yyv4657[:0] - yyc4657 = true - } - } else if yyl4657 > 0 { - var yyrr4657, yyrl4657 int - var yyrt4657 bool - if yyl4657 > cap(yyv4657) { - - yyrg4657 := len(yyv4657) > 0 - yyv24657 := yyv4657 - yyrl4657, yyrt4657 = z.DecInferLen(yyl4657, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4657 { - if yyrl4657 <= cap(yyv4657) { - yyv4657 = yyv4657[:yyrl4657] - } else { - yyv4657 = make([]ContainerPort, yyrl4657) - } - } else { - yyv4657 = make([]ContainerPort, yyrl4657) - } - yyc4657 = true - yyrr4657 = len(yyv4657) - if yyrg4657 { - copy(yyv4657, yyv24657) - } - } else if yyl4657 != len(yyv4657) { - yyv4657 = yyv4657[:yyl4657] - yyc4657 = true - } - yyj4657 := 0 - for ; yyj4657 < yyrr4657; yyj4657++ { - yyh4657.ElemContainerState(yyj4657) - if r.TryDecodeAsNil() { - yyv4657[yyj4657] = ContainerPort{} - } else { - yyv4658 := &yyv4657[yyj4657] - yyv4658.CodecDecodeSelf(d) - } - - } - if yyrt4657 { - for ; yyj4657 < yyl4657; yyj4657++ { - yyv4657 = append(yyv4657, ContainerPort{}) - yyh4657.ElemContainerState(yyj4657) - if r.TryDecodeAsNil() { - yyv4657[yyj4657] = ContainerPort{} - } else { - yyv4659 := &yyv4657[yyj4657] - yyv4659.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4657 := 0 - for ; !r.CheckBreak(); yyj4657++ { - - if yyj4657 >= len(yyv4657) { - yyv4657 = append(yyv4657, ContainerPort{}) // var yyz4657 ContainerPort - yyc4657 = true - } - yyh4657.ElemContainerState(yyj4657) - if yyj4657 < len(yyv4657) { - if r.TryDecodeAsNil() { - yyv4657[yyj4657] = ContainerPort{} - } else { - yyv4660 := &yyv4657[yyj4657] - yyv4660.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4657 < len(yyv4657) { - yyv4657 = yyv4657[:yyj4657] - yyc4657 = true - } else if yyj4657 == 0 && yyv4657 == nil { - yyv4657 = []ContainerPort{} - yyc4657 = true - } - } - yyh4657.End() - if yyc4657 { - *v = yyv4657 - } -} - -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 _, yyv4661 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4662 := &yyv4661 - yy4662.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 - - yyv4663 := *v - yyh4663, yyl4663 := z.DecSliceHelperStart() - var yyc4663 bool - if yyl4663 == 0 { - if yyv4663 == nil { - yyv4663 = []EnvVar{} - yyc4663 = true - } else if len(yyv4663) != 0 { - yyv4663 = yyv4663[:0] - yyc4663 = true - } - } else if yyl4663 > 0 { - var yyrr4663, yyrl4663 int - var yyrt4663 bool - if yyl4663 > cap(yyv4663) { - - yyrg4663 := len(yyv4663) > 0 - yyv24663 := yyv4663 - yyrl4663, yyrt4663 = z.DecInferLen(yyl4663, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4663 { - if yyrl4663 <= cap(yyv4663) { - yyv4663 = yyv4663[:yyrl4663] - } else { - yyv4663 = make([]EnvVar, yyrl4663) - } - } else { - yyv4663 = make([]EnvVar, yyrl4663) - } - yyc4663 = true - yyrr4663 = len(yyv4663) - if yyrg4663 { - copy(yyv4663, yyv24663) - } - } else if yyl4663 != len(yyv4663) { - yyv4663 = yyv4663[:yyl4663] - yyc4663 = true - } - yyj4663 := 0 - for ; yyj4663 < yyrr4663; yyj4663++ { - yyh4663.ElemContainerState(yyj4663) - if r.TryDecodeAsNil() { - yyv4663[yyj4663] = EnvVar{} - } else { - yyv4664 := &yyv4663[yyj4663] - yyv4664.CodecDecodeSelf(d) - } - - } - if yyrt4663 { - for ; yyj4663 < yyl4663; yyj4663++ { - yyv4663 = append(yyv4663, EnvVar{}) - yyh4663.ElemContainerState(yyj4663) - if r.TryDecodeAsNil() { - yyv4663[yyj4663] = EnvVar{} - } else { - yyv4665 := &yyv4663[yyj4663] - yyv4665.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4663 := 0 - for ; !r.CheckBreak(); yyj4663++ { - - if yyj4663 >= len(yyv4663) { - yyv4663 = append(yyv4663, EnvVar{}) // var yyz4663 EnvVar - yyc4663 = true - } - yyh4663.ElemContainerState(yyj4663) - if yyj4663 < len(yyv4663) { - if r.TryDecodeAsNil() { - yyv4663[yyj4663] = EnvVar{} - } else { - yyv4666 := &yyv4663[yyj4663] - yyv4666.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4663 < len(yyv4663) { - yyv4663 = yyv4663[:yyj4663] - yyc4663 = true - } else if yyj4663 == 0 && yyv4663 == nil { - yyv4663 = []EnvVar{} - yyc4663 = true - } - } - yyh4663.End() - if yyc4663 { - *v = yyv4663 - } -} - -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 _, yyv4667 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4668 := &yyv4667 - yy4668.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 - - yyv4669 := *v - yyh4669, yyl4669 := z.DecSliceHelperStart() - var yyc4669 bool - if yyl4669 == 0 { - if yyv4669 == nil { - yyv4669 = []VolumeMount{} - yyc4669 = true - } else if len(yyv4669) != 0 { - yyv4669 = yyv4669[:0] - yyc4669 = true - } - } else if yyl4669 > 0 { - var yyrr4669, yyrl4669 int - var yyrt4669 bool - if yyl4669 > cap(yyv4669) { - - yyrg4669 := len(yyv4669) > 0 - yyv24669 := yyv4669 - yyrl4669, yyrt4669 = z.DecInferLen(yyl4669, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4669 { - if yyrl4669 <= cap(yyv4669) { - yyv4669 = yyv4669[:yyrl4669] - } else { - yyv4669 = make([]VolumeMount, yyrl4669) - } - } else { - yyv4669 = make([]VolumeMount, yyrl4669) - } - yyc4669 = true - yyrr4669 = len(yyv4669) - if yyrg4669 { - copy(yyv4669, yyv24669) - } - } else if yyl4669 != len(yyv4669) { - yyv4669 = yyv4669[:yyl4669] - yyc4669 = true - } - yyj4669 := 0 - for ; yyj4669 < yyrr4669; yyj4669++ { - yyh4669.ElemContainerState(yyj4669) - if r.TryDecodeAsNil() { - yyv4669[yyj4669] = VolumeMount{} - } else { - yyv4670 := &yyv4669[yyj4669] - yyv4670.CodecDecodeSelf(d) - } - - } - if yyrt4669 { - for ; yyj4669 < yyl4669; yyj4669++ { - yyv4669 = append(yyv4669, VolumeMount{}) - yyh4669.ElemContainerState(yyj4669) - if r.TryDecodeAsNil() { - yyv4669[yyj4669] = VolumeMount{} - } else { - yyv4671 := &yyv4669[yyj4669] - yyv4671.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4669 := 0 - for ; !r.CheckBreak(); yyj4669++ { - - if yyj4669 >= len(yyv4669) { - yyv4669 = append(yyv4669, VolumeMount{}) // var yyz4669 VolumeMount - yyc4669 = true - } - yyh4669.ElemContainerState(yyj4669) - if yyj4669 < len(yyv4669) { - if r.TryDecodeAsNil() { - yyv4669[yyj4669] = VolumeMount{} - } else { - yyv4672 := &yyv4669[yyj4669] - yyv4672.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4669 < len(yyv4669) { - yyv4669 = yyv4669[:yyj4669] - yyc4669 = true - } else if yyj4669 == 0 && yyv4669 == nil { - yyv4669 = []VolumeMount{} - yyc4669 = true - } - } - yyh4669.End() - if yyc4669 { - *v = yyv4669 - } -} - -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 _, yyv4673 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4674 := &yyv4673 - yy4674.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 - - yyv4675 := *v - yyh4675, yyl4675 := z.DecSliceHelperStart() - var yyc4675 bool - if yyl4675 == 0 { - if yyv4675 == nil { - yyv4675 = []Pod{} - yyc4675 = true - } else if len(yyv4675) != 0 { - yyv4675 = yyv4675[:0] - yyc4675 = true - } - } else if yyl4675 > 0 { - var yyrr4675, yyrl4675 int - var yyrt4675 bool - if yyl4675 > cap(yyv4675) { - - yyrg4675 := len(yyv4675) > 0 - yyv24675 := yyv4675 - yyrl4675, yyrt4675 = z.DecInferLen(yyl4675, z.DecBasicHandle().MaxInitLen, 640) - if yyrt4675 { - if yyrl4675 <= cap(yyv4675) { - yyv4675 = yyv4675[:yyrl4675] - } else { - yyv4675 = make([]Pod, yyrl4675) - } - } else { - yyv4675 = make([]Pod, yyrl4675) - } - yyc4675 = true - yyrr4675 = len(yyv4675) - if yyrg4675 { - copy(yyv4675, yyv24675) - } - } else if yyl4675 != len(yyv4675) { - yyv4675 = yyv4675[:yyl4675] - yyc4675 = true - } - yyj4675 := 0 - for ; yyj4675 < yyrr4675; yyj4675++ { - yyh4675.ElemContainerState(yyj4675) - if r.TryDecodeAsNil() { - yyv4675[yyj4675] = Pod{} - } else { - yyv4676 := &yyv4675[yyj4675] - yyv4676.CodecDecodeSelf(d) - } - - } - if yyrt4675 { - for ; yyj4675 < yyl4675; yyj4675++ { - yyv4675 = append(yyv4675, Pod{}) - yyh4675.ElemContainerState(yyj4675) - if r.TryDecodeAsNil() { - yyv4675[yyj4675] = Pod{} - } else { - yyv4677 := &yyv4675[yyj4675] - yyv4677.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4675 := 0 - for ; !r.CheckBreak(); yyj4675++ { - - if yyj4675 >= len(yyv4675) { - yyv4675 = append(yyv4675, Pod{}) // var yyz4675 Pod - yyc4675 = true - } - yyh4675.ElemContainerState(yyj4675) - if yyj4675 < len(yyv4675) { - if r.TryDecodeAsNil() { - yyv4675[yyj4675] = Pod{} - } else { - yyv4678 := &yyv4675[yyj4675] - yyv4678.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4675 < len(yyv4675) { - yyv4675 = yyv4675[:yyj4675] - yyc4675 = true - } else if yyj4675 == 0 && yyv4675 == nil { - yyv4675 = []Pod{} - yyc4675 = true - } - } - yyh4675.End() - if yyc4675 { - *v = yyv4675 - } -} - -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 _, yyv4679 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4680 := &yyv4679 - yy4680.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 - - yyv4681 := *v - yyh4681, yyl4681 := z.DecSliceHelperStart() - var yyc4681 bool - if yyl4681 == 0 { - if yyv4681 == nil { - yyv4681 = []NodeSelectorTerm{} - yyc4681 = true - } else if len(yyv4681) != 0 { - yyv4681 = yyv4681[:0] - yyc4681 = true - } - } else if yyl4681 > 0 { - var yyrr4681, yyrl4681 int - var yyrt4681 bool - if yyl4681 > cap(yyv4681) { - - yyrg4681 := len(yyv4681) > 0 - yyv24681 := yyv4681 - yyrl4681, yyrt4681 = z.DecInferLen(yyl4681, z.DecBasicHandle().MaxInitLen, 24) - if yyrt4681 { - if yyrl4681 <= cap(yyv4681) { - yyv4681 = yyv4681[:yyrl4681] - } else { - yyv4681 = make([]NodeSelectorTerm, yyrl4681) - } - } else { - yyv4681 = make([]NodeSelectorTerm, yyrl4681) - } - yyc4681 = true - yyrr4681 = len(yyv4681) - if yyrg4681 { - copy(yyv4681, yyv24681) - } - } else if yyl4681 != len(yyv4681) { - yyv4681 = yyv4681[:yyl4681] - yyc4681 = true - } - yyj4681 := 0 - for ; yyj4681 < yyrr4681; yyj4681++ { - yyh4681.ElemContainerState(yyj4681) - if r.TryDecodeAsNil() { - yyv4681[yyj4681] = NodeSelectorTerm{} - } else { - yyv4682 := &yyv4681[yyj4681] - yyv4682.CodecDecodeSelf(d) - } - - } - if yyrt4681 { - for ; yyj4681 < yyl4681; yyj4681++ { - yyv4681 = append(yyv4681, NodeSelectorTerm{}) - yyh4681.ElemContainerState(yyj4681) - if r.TryDecodeAsNil() { - yyv4681[yyj4681] = NodeSelectorTerm{} - } else { - yyv4683 := &yyv4681[yyj4681] - yyv4683.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4681 := 0 - for ; !r.CheckBreak(); yyj4681++ { - - if yyj4681 >= len(yyv4681) { - yyv4681 = append(yyv4681, NodeSelectorTerm{}) // var yyz4681 NodeSelectorTerm - yyc4681 = true - } - yyh4681.ElemContainerState(yyj4681) - if yyj4681 < len(yyv4681) { - if r.TryDecodeAsNil() { - yyv4681[yyj4681] = NodeSelectorTerm{} - } else { - yyv4684 := &yyv4681[yyj4681] - yyv4684.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4681 < len(yyv4681) { - yyv4681 = yyv4681[:yyj4681] - yyc4681 = true - } else if yyj4681 == 0 && yyv4681 == nil { - yyv4681 = []NodeSelectorTerm{} - yyc4681 = true - } - } - yyh4681.End() - if yyc4681 { - *v = yyv4681 - } -} - -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 _, yyv4685 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4686 := &yyv4685 - yy4686.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 - - yyv4687 := *v - yyh4687, yyl4687 := z.DecSliceHelperStart() - var yyc4687 bool - if yyl4687 == 0 { - if yyv4687 == nil { - yyv4687 = []NodeSelectorRequirement{} - yyc4687 = true - } else if len(yyv4687) != 0 { - yyv4687 = yyv4687[:0] - yyc4687 = true - } - } else if yyl4687 > 0 { - var yyrr4687, yyrl4687 int - var yyrt4687 bool - if yyl4687 > cap(yyv4687) { - - yyrg4687 := len(yyv4687) > 0 - yyv24687 := yyv4687 - yyrl4687, yyrt4687 = z.DecInferLen(yyl4687, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4687 { - if yyrl4687 <= cap(yyv4687) { - yyv4687 = yyv4687[:yyrl4687] - } else { - yyv4687 = make([]NodeSelectorRequirement, yyrl4687) - } - } else { - yyv4687 = make([]NodeSelectorRequirement, yyrl4687) - } - yyc4687 = true - yyrr4687 = len(yyv4687) - if yyrg4687 { - copy(yyv4687, yyv24687) - } - } else if yyl4687 != len(yyv4687) { - yyv4687 = yyv4687[:yyl4687] - yyc4687 = true - } - yyj4687 := 0 - for ; yyj4687 < yyrr4687; yyj4687++ { - yyh4687.ElemContainerState(yyj4687) - if r.TryDecodeAsNil() { - yyv4687[yyj4687] = NodeSelectorRequirement{} - } else { - yyv4688 := &yyv4687[yyj4687] - yyv4688.CodecDecodeSelf(d) - } - - } - if yyrt4687 { - for ; yyj4687 < yyl4687; yyj4687++ { - yyv4687 = append(yyv4687, NodeSelectorRequirement{}) - yyh4687.ElemContainerState(yyj4687) - if r.TryDecodeAsNil() { - yyv4687[yyj4687] = NodeSelectorRequirement{} - } else { - yyv4689 := &yyv4687[yyj4687] - yyv4689.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4687 := 0 - for ; !r.CheckBreak(); yyj4687++ { - - if yyj4687 >= len(yyv4687) { - yyv4687 = append(yyv4687, NodeSelectorRequirement{}) // var yyz4687 NodeSelectorRequirement - yyc4687 = true - } - yyh4687.ElemContainerState(yyj4687) - if yyj4687 < len(yyv4687) { - if r.TryDecodeAsNil() { - yyv4687[yyj4687] = NodeSelectorRequirement{} - } else { - yyv4690 := &yyv4687[yyj4687] - yyv4690.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4687 < len(yyv4687) { - yyv4687 = yyv4687[:yyj4687] - yyc4687 = true - } else if yyj4687 == 0 && yyv4687 == nil { - yyv4687 = []NodeSelectorRequirement{} - yyc4687 = true - } - } - yyh4687.End() - if yyc4687 { - *v = yyv4687 - } -} - -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 _, yyv4691 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4692 := &yyv4691 - yy4692.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 - - yyv4693 := *v - yyh4693, yyl4693 := z.DecSliceHelperStart() - var yyc4693 bool - if yyl4693 == 0 { - if yyv4693 == nil { - yyv4693 = []PodAffinityTerm{} - yyc4693 = true - } else if len(yyv4693) != 0 { - yyv4693 = yyv4693[:0] - yyc4693 = true - } - } else if yyl4693 > 0 { - var yyrr4693, yyrl4693 int - var yyrt4693 bool - if yyl4693 > cap(yyv4693) { - - yyrg4693 := len(yyv4693) > 0 - yyv24693 := yyv4693 - yyrl4693, yyrt4693 = z.DecInferLen(yyl4693, z.DecBasicHandle().MaxInitLen, 48) - if yyrt4693 { - if yyrl4693 <= cap(yyv4693) { - yyv4693 = yyv4693[:yyrl4693] - } else { - yyv4693 = make([]PodAffinityTerm, yyrl4693) - } - } else { - yyv4693 = make([]PodAffinityTerm, yyrl4693) - } - yyc4693 = true - yyrr4693 = len(yyv4693) - if yyrg4693 { - copy(yyv4693, yyv24693) - } - } else if yyl4693 != len(yyv4693) { - yyv4693 = yyv4693[:yyl4693] - yyc4693 = true - } - yyj4693 := 0 - for ; yyj4693 < yyrr4693; yyj4693++ { - yyh4693.ElemContainerState(yyj4693) - if r.TryDecodeAsNil() { - yyv4693[yyj4693] = PodAffinityTerm{} - } else { - yyv4694 := &yyv4693[yyj4693] - yyv4694.CodecDecodeSelf(d) - } - - } - if yyrt4693 { - for ; yyj4693 < yyl4693; yyj4693++ { - yyv4693 = append(yyv4693, PodAffinityTerm{}) - yyh4693.ElemContainerState(yyj4693) - if r.TryDecodeAsNil() { - yyv4693[yyj4693] = PodAffinityTerm{} - } else { - yyv4695 := &yyv4693[yyj4693] - yyv4695.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4693 := 0 - for ; !r.CheckBreak(); yyj4693++ { - - if yyj4693 >= len(yyv4693) { - yyv4693 = append(yyv4693, PodAffinityTerm{}) // var yyz4693 PodAffinityTerm - yyc4693 = true - } - yyh4693.ElemContainerState(yyj4693) - if yyj4693 < len(yyv4693) { - if r.TryDecodeAsNil() { - yyv4693[yyj4693] = PodAffinityTerm{} - } else { - yyv4696 := &yyv4693[yyj4693] - yyv4696.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4693 < len(yyv4693) { - yyv4693 = yyv4693[:yyj4693] - yyc4693 = true - } else if yyj4693 == 0 && yyv4693 == nil { - yyv4693 = []PodAffinityTerm{} - yyc4693 = true - } - } - yyh4693.End() - if yyc4693 { - *v = yyv4693 - } -} - -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 _, yyv4697 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4698 := &yyv4697 - yy4698.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 - - yyv4699 := *v - yyh4699, yyl4699 := z.DecSliceHelperStart() - var yyc4699 bool - if yyl4699 == 0 { - if yyv4699 == nil { - yyv4699 = []WeightedPodAffinityTerm{} - yyc4699 = true - } else if len(yyv4699) != 0 { - yyv4699 = yyv4699[:0] - yyc4699 = true - } - } else if yyl4699 > 0 { - var yyrr4699, yyrl4699 int - var yyrt4699 bool - if yyl4699 > cap(yyv4699) { - - yyrg4699 := len(yyv4699) > 0 - yyv24699 := yyv4699 - yyrl4699, yyrt4699 = z.DecInferLen(yyl4699, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4699 { - if yyrl4699 <= cap(yyv4699) { - yyv4699 = yyv4699[:yyrl4699] - } else { - yyv4699 = make([]WeightedPodAffinityTerm, yyrl4699) - } - } else { - yyv4699 = make([]WeightedPodAffinityTerm, yyrl4699) - } - yyc4699 = true - yyrr4699 = len(yyv4699) - if yyrg4699 { - copy(yyv4699, yyv24699) - } - } else if yyl4699 != len(yyv4699) { - yyv4699 = yyv4699[:yyl4699] - yyc4699 = true - } - yyj4699 := 0 - for ; yyj4699 < yyrr4699; yyj4699++ { - yyh4699.ElemContainerState(yyj4699) - if r.TryDecodeAsNil() { - yyv4699[yyj4699] = WeightedPodAffinityTerm{} - } else { - yyv4700 := &yyv4699[yyj4699] - yyv4700.CodecDecodeSelf(d) - } - - } - if yyrt4699 { - for ; yyj4699 < yyl4699; yyj4699++ { - yyv4699 = append(yyv4699, WeightedPodAffinityTerm{}) - yyh4699.ElemContainerState(yyj4699) - if r.TryDecodeAsNil() { - yyv4699[yyj4699] = WeightedPodAffinityTerm{} - } else { - yyv4701 := &yyv4699[yyj4699] - yyv4701.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4699 := 0 - for ; !r.CheckBreak(); yyj4699++ { - - if yyj4699 >= len(yyv4699) { - yyv4699 = append(yyv4699, WeightedPodAffinityTerm{}) // var yyz4699 WeightedPodAffinityTerm - yyc4699 = true - } - yyh4699.ElemContainerState(yyj4699) - if yyj4699 < len(yyv4699) { - if r.TryDecodeAsNil() { - yyv4699[yyj4699] = WeightedPodAffinityTerm{} - } else { - yyv4702 := &yyv4699[yyj4699] - yyv4702.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4699 < len(yyv4699) { - yyv4699 = yyv4699[:yyj4699] - yyc4699 = true - } else if yyj4699 == 0 && yyv4699 == nil { - yyv4699 = []WeightedPodAffinityTerm{} - yyc4699 = true - } - } - yyh4699.End() - if yyc4699 { - *v = yyv4699 - } -} - -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 _, yyv4703 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4704 := &yyv4703 - yy4704.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 - - yyv4705 := *v - yyh4705, yyl4705 := z.DecSliceHelperStart() - var yyc4705 bool - if yyl4705 == 0 { - if yyv4705 == nil { - yyv4705 = []PreferredSchedulingTerm{} - yyc4705 = true - } else if len(yyv4705) != 0 { - yyv4705 = yyv4705[:0] - yyc4705 = true - } - } else if yyl4705 > 0 { - var yyrr4705, yyrl4705 int - var yyrt4705 bool - if yyl4705 > cap(yyv4705) { - - yyrg4705 := len(yyv4705) > 0 - yyv24705 := yyv4705 - yyrl4705, yyrt4705 = z.DecInferLen(yyl4705, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4705 { - if yyrl4705 <= cap(yyv4705) { - yyv4705 = yyv4705[:yyrl4705] - } else { - yyv4705 = make([]PreferredSchedulingTerm, yyrl4705) - } - } else { - yyv4705 = make([]PreferredSchedulingTerm, yyrl4705) - } - yyc4705 = true - yyrr4705 = len(yyv4705) - if yyrg4705 { - copy(yyv4705, yyv24705) - } - } else if yyl4705 != len(yyv4705) { - yyv4705 = yyv4705[:yyl4705] - yyc4705 = true - } - yyj4705 := 0 - for ; yyj4705 < yyrr4705; yyj4705++ { - yyh4705.ElemContainerState(yyj4705) - if r.TryDecodeAsNil() { - yyv4705[yyj4705] = PreferredSchedulingTerm{} - } else { - yyv4706 := &yyv4705[yyj4705] - yyv4706.CodecDecodeSelf(d) - } - - } - if yyrt4705 { - for ; yyj4705 < yyl4705; yyj4705++ { - yyv4705 = append(yyv4705, PreferredSchedulingTerm{}) - yyh4705.ElemContainerState(yyj4705) - if r.TryDecodeAsNil() { - yyv4705[yyj4705] = PreferredSchedulingTerm{} - } else { - yyv4707 := &yyv4705[yyj4705] - yyv4707.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4705 := 0 - for ; !r.CheckBreak(); yyj4705++ { - - if yyj4705 >= len(yyv4705) { - yyv4705 = append(yyv4705, PreferredSchedulingTerm{}) // var yyz4705 PreferredSchedulingTerm - yyc4705 = true - } - yyh4705.ElemContainerState(yyj4705) - if yyj4705 < len(yyv4705) { - if r.TryDecodeAsNil() { - yyv4705[yyj4705] = PreferredSchedulingTerm{} - } else { - yyv4708 := &yyv4705[yyj4705] - yyv4708.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4705 < len(yyv4705) { - yyv4705 = yyv4705[:yyj4705] - yyc4705 = true - } else if yyj4705 == 0 && yyv4705 == nil { - yyv4705 = []PreferredSchedulingTerm{} - yyc4705 = true - } - } - yyh4705.End() - if yyc4705 { - *v = yyv4705 - } -} - -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 _, yyv4709 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4710 := &yyv4709 - yy4710.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 - - yyv4711 := *v - yyh4711, yyl4711 := z.DecSliceHelperStart() - var yyc4711 bool - if yyl4711 == 0 { - if yyv4711 == nil { - yyv4711 = []Volume{} - yyc4711 = true - } else if len(yyv4711) != 0 { - yyv4711 = yyv4711[:0] - yyc4711 = true - } - } else if yyl4711 > 0 { - var yyrr4711, yyrl4711 int - var yyrt4711 bool - if yyl4711 > cap(yyv4711) { - - yyrg4711 := len(yyv4711) > 0 - yyv24711 := yyv4711 - yyrl4711, yyrt4711 = z.DecInferLen(yyl4711, z.DecBasicHandle().MaxInitLen, 200) - if yyrt4711 { - if yyrl4711 <= cap(yyv4711) { - yyv4711 = yyv4711[:yyrl4711] - } else { - yyv4711 = make([]Volume, yyrl4711) - } - } else { - yyv4711 = make([]Volume, yyrl4711) - } - yyc4711 = true - yyrr4711 = len(yyv4711) - if yyrg4711 { - copy(yyv4711, yyv24711) - } - } else if yyl4711 != len(yyv4711) { - yyv4711 = yyv4711[:yyl4711] - yyc4711 = true - } - yyj4711 := 0 - for ; yyj4711 < yyrr4711; yyj4711++ { - yyh4711.ElemContainerState(yyj4711) - if r.TryDecodeAsNil() { - yyv4711[yyj4711] = Volume{} - } else { - yyv4712 := &yyv4711[yyj4711] - yyv4712.CodecDecodeSelf(d) - } - - } - if yyrt4711 { - for ; yyj4711 < yyl4711; yyj4711++ { - yyv4711 = append(yyv4711, Volume{}) - yyh4711.ElemContainerState(yyj4711) - if r.TryDecodeAsNil() { - yyv4711[yyj4711] = Volume{} - } else { - yyv4713 := &yyv4711[yyj4711] - yyv4713.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4711 := 0 - for ; !r.CheckBreak(); yyj4711++ { - - if yyj4711 >= len(yyv4711) { - yyv4711 = append(yyv4711, Volume{}) // var yyz4711 Volume - yyc4711 = true - } - yyh4711.ElemContainerState(yyj4711) - if yyj4711 < len(yyv4711) { - if r.TryDecodeAsNil() { - yyv4711[yyj4711] = Volume{} - } else { - yyv4714 := &yyv4711[yyj4711] - yyv4714.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4711 < len(yyv4711) { - yyv4711 = yyv4711[:yyj4711] - yyc4711 = true - } else if yyj4711 == 0 && yyv4711 == nil { - yyv4711 = []Volume{} - yyc4711 = true - } - } - yyh4711.End() - if yyc4711 { - *v = yyv4711 - } -} - -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 _, yyv4715 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4716 := &yyv4715 - yy4716.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 - - yyv4717 := *v - yyh4717, yyl4717 := z.DecSliceHelperStart() - var yyc4717 bool - if yyl4717 == 0 { - if yyv4717 == nil { - yyv4717 = []Container{} - yyc4717 = true - } else if len(yyv4717) != 0 { - yyv4717 = yyv4717[:0] - yyc4717 = true - } - } else if yyl4717 > 0 { - var yyrr4717, yyrl4717 int - var yyrt4717 bool - if yyl4717 > cap(yyv4717) { - - yyrg4717 := len(yyv4717) > 0 - yyv24717 := yyv4717 - yyrl4717, yyrt4717 = z.DecInferLen(yyl4717, z.DecBasicHandle().MaxInitLen, 256) - if yyrt4717 { - if yyrl4717 <= cap(yyv4717) { - yyv4717 = yyv4717[:yyrl4717] - } else { - yyv4717 = make([]Container, yyrl4717) - } - } else { - yyv4717 = make([]Container, yyrl4717) - } - yyc4717 = true - yyrr4717 = len(yyv4717) - if yyrg4717 { - copy(yyv4717, yyv24717) - } - } else if yyl4717 != len(yyv4717) { - yyv4717 = yyv4717[:yyl4717] - yyc4717 = true - } - yyj4717 := 0 - for ; yyj4717 < yyrr4717; yyj4717++ { - yyh4717.ElemContainerState(yyj4717) - if r.TryDecodeAsNil() { - yyv4717[yyj4717] = Container{} - } else { - yyv4718 := &yyv4717[yyj4717] - yyv4718.CodecDecodeSelf(d) - } - - } - if yyrt4717 { - for ; yyj4717 < yyl4717; yyj4717++ { - yyv4717 = append(yyv4717, Container{}) - yyh4717.ElemContainerState(yyj4717) - if r.TryDecodeAsNil() { - yyv4717[yyj4717] = Container{} - } else { - yyv4719 := &yyv4717[yyj4717] - yyv4719.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4717 := 0 - for ; !r.CheckBreak(); yyj4717++ { - - if yyj4717 >= len(yyv4717) { - yyv4717 = append(yyv4717, Container{}) // var yyz4717 Container - yyc4717 = true - } - yyh4717.ElemContainerState(yyj4717) - if yyj4717 < len(yyv4717) { - if r.TryDecodeAsNil() { - yyv4717[yyj4717] = Container{} - } else { - yyv4720 := &yyv4717[yyj4717] - yyv4720.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4717 < len(yyv4717) { - yyv4717 = yyv4717[:yyj4717] - yyc4717 = true - } else if yyj4717 == 0 && yyv4717 == nil { - yyv4717 = []Container{} - yyc4717 = true - } - } - yyh4717.End() - if yyc4717 { - *v = yyv4717 - } -} - -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 _, yyv4721 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4722 := &yyv4721 - yy4722.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 - - yyv4723 := *v - yyh4723, yyl4723 := z.DecSliceHelperStart() - var yyc4723 bool - if yyl4723 == 0 { - if yyv4723 == nil { - yyv4723 = []LocalObjectReference{} - yyc4723 = true - } else if len(yyv4723) != 0 { - yyv4723 = yyv4723[:0] - yyc4723 = true - } - } else if yyl4723 > 0 { - var yyrr4723, yyrl4723 int - var yyrt4723 bool - if yyl4723 > cap(yyv4723) { - - yyrg4723 := len(yyv4723) > 0 - yyv24723 := yyv4723 - yyrl4723, yyrt4723 = z.DecInferLen(yyl4723, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4723 { - if yyrl4723 <= cap(yyv4723) { - yyv4723 = yyv4723[:yyrl4723] - } else { - yyv4723 = make([]LocalObjectReference, yyrl4723) - } - } else { - yyv4723 = make([]LocalObjectReference, yyrl4723) - } - yyc4723 = true - yyrr4723 = len(yyv4723) - if yyrg4723 { - copy(yyv4723, yyv24723) - } - } else if yyl4723 != len(yyv4723) { - yyv4723 = yyv4723[:yyl4723] - yyc4723 = true - } - yyj4723 := 0 - for ; yyj4723 < yyrr4723; yyj4723++ { - yyh4723.ElemContainerState(yyj4723) - if r.TryDecodeAsNil() { - yyv4723[yyj4723] = LocalObjectReference{} - } else { - yyv4724 := &yyv4723[yyj4723] - yyv4724.CodecDecodeSelf(d) - } - - } - if yyrt4723 { - for ; yyj4723 < yyl4723; yyj4723++ { - yyv4723 = append(yyv4723, LocalObjectReference{}) - yyh4723.ElemContainerState(yyj4723) - if r.TryDecodeAsNil() { - yyv4723[yyj4723] = LocalObjectReference{} - } else { - yyv4725 := &yyv4723[yyj4723] - yyv4725.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4723 := 0 - for ; !r.CheckBreak(); yyj4723++ { - - if yyj4723 >= len(yyv4723) { - yyv4723 = append(yyv4723, LocalObjectReference{}) // var yyz4723 LocalObjectReference - yyc4723 = true - } - yyh4723.ElemContainerState(yyj4723) - if yyj4723 < len(yyv4723) { - if r.TryDecodeAsNil() { - yyv4723[yyj4723] = LocalObjectReference{} - } else { - yyv4726 := &yyv4723[yyj4723] - yyv4726.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4723 < len(yyv4723) { - yyv4723 = yyv4723[:yyj4723] - yyc4723 = true - } else if yyj4723 == 0 && yyv4723 == nil { - yyv4723 = []LocalObjectReference{} - yyc4723 = true - } - } - yyh4723.End() - if yyc4723 { - *v = yyv4723 - } -} - -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 _, yyv4727 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4728 := &yyv4727 - yy4728.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 - - yyv4729 := *v - yyh4729, yyl4729 := z.DecSliceHelperStart() - var yyc4729 bool - if yyl4729 == 0 { - if yyv4729 == nil { - yyv4729 = []PodCondition{} - yyc4729 = true - } else if len(yyv4729) != 0 { - yyv4729 = yyv4729[:0] - yyc4729 = true - } - } else if yyl4729 > 0 { - var yyrr4729, yyrl4729 int - var yyrt4729 bool - if yyl4729 > cap(yyv4729) { - - yyrg4729 := len(yyv4729) > 0 - yyv24729 := yyv4729 - yyrl4729, yyrt4729 = z.DecInferLen(yyl4729, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4729 { - if yyrl4729 <= cap(yyv4729) { - yyv4729 = yyv4729[:yyrl4729] - } else { - yyv4729 = make([]PodCondition, yyrl4729) - } - } else { - yyv4729 = make([]PodCondition, yyrl4729) - } - yyc4729 = true - yyrr4729 = len(yyv4729) - if yyrg4729 { - copy(yyv4729, yyv24729) - } - } else if yyl4729 != len(yyv4729) { - yyv4729 = yyv4729[:yyl4729] - yyc4729 = true - } - yyj4729 := 0 - for ; yyj4729 < yyrr4729; yyj4729++ { - yyh4729.ElemContainerState(yyj4729) - if r.TryDecodeAsNil() { - yyv4729[yyj4729] = PodCondition{} - } else { - yyv4730 := &yyv4729[yyj4729] - yyv4730.CodecDecodeSelf(d) - } - - } - if yyrt4729 { - for ; yyj4729 < yyl4729; yyj4729++ { - yyv4729 = append(yyv4729, PodCondition{}) - yyh4729.ElemContainerState(yyj4729) - if r.TryDecodeAsNil() { - yyv4729[yyj4729] = PodCondition{} - } else { - yyv4731 := &yyv4729[yyj4729] - yyv4731.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4729 := 0 - for ; !r.CheckBreak(); yyj4729++ { - - if yyj4729 >= len(yyv4729) { - yyv4729 = append(yyv4729, PodCondition{}) // var yyz4729 PodCondition - yyc4729 = true - } - yyh4729.ElemContainerState(yyj4729) - if yyj4729 < len(yyv4729) { - if r.TryDecodeAsNil() { - yyv4729[yyj4729] = PodCondition{} - } else { - yyv4732 := &yyv4729[yyj4729] - yyv4732.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4729 < len(yyv4729) { - yyv4729 = yyv4729[:yyj4729] - yyc4729 = true - } else if yyj4729 == 0 && yyv4729 == nil { - yyv4729 = []PodCondition{} - yyc4729 = true - } - } - yyh4729.End() - if yyc4729 { - *v = yyv4729 - } -} - -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 _, yyv4733 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4734 := &yyv4733 - yy4734.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 - - yyv4735 := *v - yyh4735, yyl4735 := z.DecSliceHelperStart() - var yyc4735 bool - if yyl4735 == 0 { - if yyv4735 == nil { - yyv4735 = []ContainerStatus{} - yyc4735 = true - } else if len(yyv4735) != 0 { - yyv4735 = yyv4735[:0] - yyc4735 = true - } - } else if yyl4735 > 0 { - var yyrr4735, yyrl4735 int - var yyrt4735 bool - if yyl4735 > cap(yyv4735) { - - yyrg4735 := len(yyv4735) > 0 - yyv24735 := yyv4735 - yyrl4735, yyrt4735 = z.DecInferLen(yyl4735, z.DecBasicHandle().MaxInitLen, 120) - if yyrt4735 { - if yyrl4735 <= cap(yyv4735) { - yyv4735 = yyv4735[:yyrl4735] - } else { - yyv4735 = make([]ContainerStatus, yyrl4735) - } - } else { - yyv4735 = make([]ContainerStatus, yyrl4735) - } - yyc4735 = true - yyrr4735 = len(yyv4735) - if yyrg4735 { - copy(yyv4735, yyv24735) - } - } else if yyl4735 != len(yyv4735) { - yyv4735 = yyv4735[:yyl4735] - yyc4735 = true - } - yyj4735 := 0 - for ; yyj4735 < yyrr4735; yyj4735++ { - yyh4735.ElemContainerState(yyj4735) - if r.TryDecodeAsNil() { - yyv4735[yyj4735] = ContainerStatus{} - } else { - yyv4736 := &yyv4735[yyj4735] - yyv4736.CodecDecodeSelf(d) - } - - } - if yyrt4735 { - for ; yyj4735 < yyl4735; yyj4735++ { - yyv4735 = append(yyv4735, ContainerStatus{}) - yyh4735.ElemContainerState(yyj4735) - if r.TryDecodeAsNil() { - yyv4735[yyj4735] = ContainerStatus{} - } else { - yyv4737 := &yyv4735[yyj4735] - yyv4737.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4735 := 0 - for ; !r.CheckBreak(); yyj4735++ { - - if yyj4735 >= len(yyv4735) { - yyv4735 = append(yyv4735, ContainerStatus{}) // var yyz4735 ContainerStatus - yyc4735 = true - } - yyh4735.ElemContainerState(yyj4735) - if yyj4735 < len(yyv4735) { - if r.TryDecodeAsNil() { - yyv4735[yyj4735] = ContainerStatus{} - } else { - yyv4738 := &yyv4735[yyj4735] - yyv4738.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4735 < len(yyv4735) { - yyv4735 = yyv4735[:yyj4735] - yyc4735 = true - } else if yyj4735 == 0 && yyv4735 == nil { - yyv4735 = []ContainerStatus{} - yyc4735 = true - } - } - yyh4735.End() - if yyc4735 { - *v = yyv4735 - } -} - -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 _, yyv4739 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4740 := &yyv4739 - yy4740.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 - - yyv4741 := *v - yyh4741, yyl4741 := z.DecSliceHelperStart() - var yyc4741 bool - if yyl4741 == 0 { - if yyv4741 == nil { - yyv4741 = []PodTemplate{} - yyc4741 = true - } else if len(yyv4741) != 0 { - yyv4741 = yyv4741[:0] - yyc4741 = true - } - } else if yyl4741 > 0 { - var yyrr4741, yyrl4741 int - var yyrt4741 bool - if yyl4741 > cap(yyv4741) { - - yyrg4741 := len(yyv4741) > 0 - yyv24741 := yyv4741 - yyrl4741, yyrt4741 = z.DecInferLen(yyl4741, z.DecBasicHandle().MaxInitLen, 704) - if yyrt4741 { - if yyrl4741 <= cap(yyv4741) { - yyv4741 = yyv4741[:yyrl4741] - } else { - yyv4741 = make([]PodTemplate, yyrl4741) - } - } else { - yyv4741 = make([]PodTemplate, yyrl4741) - } - yyc4741 = true - yyrr4741 = len(yyv4741) - if yyrg4741 { - copy(yyv4741, yyv24741) - } - } else if yyl4741 != len(yyv4741) { - yyv4741 = yyv4741[:yyl4741] - yyc4741 = true - } - yyj4741 := 0 - for ; yyj4741 < yyrr4741; yyj4741++ { - yyh4741.ElemContainerState(yyj4741) - if r.TryDecodeAsNil() { - yyv4741[yyj4741] = PodTemplate{} - } else { - yyv4742 := &yyv4741[yyj4741] - yyv4742.CodecDecodeSelf(d) - } - - } - if yyrt4741 { - for ; yyj4741 < yyl4741; yyj4741++ { - yyv4741 = append(yyv4741, PodTemplate{}) - yyh4741.ElemContainerState(yyj4741) - if r.TryDecodeAsNil() { - yyv4741[yyj4741] = PodTemplate{} - } else { - yyv4743 := &yyv4741[yyj4741] - yyv4743.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4741 := 0 - for ; !r.CheckBreak(); yyj4741++ { - - if yyj4741 >= len(yyv4741) { - yyv4741 = append(yyv4741, PodTemplate{}) // var yyz4741 PodTemplate - yyc4741 = true - } - yyh4741.ElemContainerState(yyj4741) - if yyj4741 < len(yyv4741) { - if r.TryDecodeAsNil() { - yyv4741[yyj4741] = PodTemplate{} - } else { - yyv4744 := &yyv4741[yyj4741] - yyv4744.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4741 < len(yyv4741) { - yyv4741 = yyv4741[:yyj4741] - yyc4741 = true - } else if yyj4741 == 0 && yyv4741 == nil { - yyv4741 = []PodTemplate{} - yyc4741 = true - } - } - yyh4741.End() - if yyc4741 { - *v = yyv4741 - } -} - -func (x codecSelfer1234) encSliceReplicationControllerCondition(v []ReplicationControllerCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv4745 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4746 := &yyv4745 - yy4746.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceReplicationControllerCondition(v *[]ReplicationControllerCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv4747 := *v - yyh4747, yyl4747 := z.DecSliceHelperStart() - var yyc4747 bool - if yyl4747 == 0 { - if yyv4747 == nil { - yyv4747 = []ReplicationControllerCondition{} - yyc4747 = true - } else if len(yyv4747) != 0 { - yyv4747 = yyv4747[:0] - yyc4747 = true - } - } else if yyl4747 > 0 { - var yyrr4747, yyrl4747 int - var yyrt4747 bool - if yyl4747 > cap(yyv4747) { - - yyrg4747 := len(yyv4747) > 0 - yyv24747 := yyv4747 - yyrl4747, yyrt4747 = z.DecInferLen(yyl4747, z.DecBasicHandle().MaxInitLen, 88) - if yyrt4747 { - if yyrl4747 <= cap(yyv4747) { - yyv4747 = yyv4747[:yyrl4747] - } else { - yyv4747 = make([]ReplicationControllerCondition, yyrl4747) - } - } else { - yyv4747 = make([]ReplicationControllerCondition, yyrl4747) - } - yyc4747 = true - yyrr4747 = len(yyv4747) - if yyrg4747 { - copy(yyv4747, yyv24747) - } - } else if yyl4747 != len(yyv4747) { - yyv4747 = yyv4747[:yyl4747] - yyc4747 = true - } - yyj4747 := 0 - for ; yyj4747 < yyrr4747; yyj4747++ { - yyh4747.ElemContainerState(yyj4747) - if r.TryDecodeAsNil() { - yyv4747[yyj4747] = ReplicationControllerCondition{} - } else { - yyv4748 := &yyv4747[yyj4747] - yyv4748.CodecDecodeSelf(d) - } - - } - if yyrt4747 { - for ; yyj4747 < yyl4747; yyj4747++ { - yyv4747 = append(yyv4747, ReplicationControllerCondition{}) - yyh4747.ElemContainerState(yyj4747) - if r.TryDecodeAsNil() { - yyv4747[yyj4747] = ReplicationControllerCondition{} - } else { - yyv4749 := &yyv4747[yyj4747] - yyv4749.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4747 := 0 - for ; !r.CheckBreak(); yyj4747++ { - - if yyj4747 >= len(yyv4747) { - yyv4747 = append(yyv4747, ReplicationControllerCondition{}) // var yyz4747 ReplicationControllerCondition - yyc4747 = true - } - yyh4747.ElemContainerState(yyj4747) - if yyj4747 < len(yyv4747) { - if r.TryDecodeAsNil() { - yyv4747[yyj4747] = ReplicationControllerCondition{} - } else { - yyv4750 := &yyv4747[yyj4747] - yyv4750.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4747 < len(yyv4747) { - yyv4747 = yyv4747[:yyj4747] - yyc4747 = true - } else if yyj4747 == 0 && yyv4747 == nil { - yyv4747 = []ReplicationControllerCondition{} - yyc4747 = true - } - } - yyh4747.End() - if yyc4747 { - *v = yyv4747 - } -} - -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 _, yyv4751 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4752 := &yyv4751 - yy4752.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 - - yyv4753 := *v - yyh4753, yyl4753 := z.DecSliceHelperStart() - var yyc4753 bool - if yyl4753 == 0 { - if yyv4753 == nil { - yyv4753 = []ReplicationController{} - yyc4753 = true - } else if len(yyv4753) != 0 { - yyv4753 = yyv4753[:0] - yyc4753 = true - } - } else if yyl4753 > 0 { - var yyrr4753, yyrl4753 int - var yyrt4753 bool - if yyl4753 > cap(yyv4753) { - - yyrg4753 := len(yyv4753) > 0 - yyv24753 := yyv4753 - yyrl4753, yyrt4753 = z.DecInferLen(yyl4753, z.DecBasicHandle().MaxInitLen, 328) - if yyrt4753 { - if yyrl4753 <= cap(yyv4753) { - yyv4753 = yyv4753[:yyrl4753] - } else { - yyv4753 = make([]ReplicationController, yyrl4753) - } - } else { - yyv4753 = make([]ReplicationController, yyrl4753) - } - yyc4753 = true - yyrr4753 = len(yyv4753) - if yyrg4753 { - copy(yyv4753, yyv24753) - } - } else if yyl4753 != len(yyv4753) { - yyv4753 = yyv4753[:yyl4753] - yyc4753 = true - } - yyj4753 := 0 - for ; yyj4753 < yyrr4753; yyj4753++ { - yyh4753.ElemContainerState(yyj4753) - if r.TryDecodeAsNil() { - yyv4753[yyj4753] = ReplicationController{} - } else { - yyv4754 := &yyv4753[yyj4753] - yyv4754.CodecDecodeSelf(d) - } - - } - if yyrt4753 { - for ; yyj4753 < yyl4753; yyj4753++ { - yyv4753 = append(yyv4753, ReplicationController{}) - yyh4753.ElemContainerState(yyj4753) - if r.TryDecodeAsNil() { - yyv4753[yyj4753] = ReplicationController{} - } else { - yyv4755 := &yyv4753[yyj4753] - yyv4755.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4753 := 0 - for ; !r.CheckBreak(); yyj4753++ { - - if yyj4753 >= len(yyv4753) { - yyv4753 = append(yyv4753, ReplicationController{}) // var yyz4753 ReplicationController - yyc4753 = true - } - yyh4753.ElemContainerState(yyj4753) - if yyj4753 < len(yyv4753) { - if r.TryDecodeAsNil() { - yyv4753[yyj4753] = ReplicationController{} - } else { - yyv4756 := &yyv4753[yyj4753] - yyv4756.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4753 < len(yyv4753) { - yyv4753 = yyv4753[:yyj4753] - yyc4753 = true - } else if yyj4753 == 0 && yyv4753 == nil { - yyv4753 = []ReplicationController{} - yyc4753 = true - } - } - yyh4753.End() - if yyc4753 { - *v = yyv4753 - } -} - -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 _, yyv4757 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4758 := &yyv4757 - yy4758.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 - - yyv4759 := *v - yyh4759, yyl4759 := z.DecSliceHelperStart() - var yyc4759 bool - if yyl4759 == 0 { - if yyv4759 == nil { - yyv4759 = []Service{} - yyc4759 = true - } else if len(yyv4759) != 0 { - yyv4759 = yyv4759[:0] - yyc4759 = true - } - } else if yyl4759 > 0 { - var yyrr4759, yyrl4759 int - var yyrt4759 bool - if yyl4759 > cap(yyv4759) { - - yyrg4759 := len(yyv4759) > 0 - yyv24759 := yyv4759 - yyrl4759, yyrt4759 = z.DecInferLen(yyl4759, z.DecBasicHandle().MaxInitLen, 440) - if yyrt4759 { - if yyrl4759 <= cap(yyv4759) { - yyv4759 = yyv4759[:yyrl4759] - } else { - yyv4759 = make([]Service, yyrl4759) - } - } else { - yyv4759 = make([]Service, yyrl4759) - } - yyc4759 = true - yyrr4759 = len(yyv4759) - if yyrg4759 { - copy(yyv4759, yyv24759) - } - } else if yyl4759 != len(yyv4759) { - yyv4759 = yyv4759[:yyl4759] - yyc4759 = true - } - yyj4759 := 0 - for ; yyj4759 < yyrr4759; yyj4759++ { - yyh4759.ElemContainerState(yyj4759) - if r.TryDecodeAsNil() { - yyv4759[yyj4759] = Service{} - } else { - yyv4760 := &yyv4759[yyj4759] - yyv4760.CodecDecodeSelf(d) - } - - } - if yyrt4759 { - for ; yyj4759 < yyl4759; yyj4759++ { - yyv4759 = append(yyv4759, Service{}) - yyh4759.ElemContainerState(yyj4759) - if r.TryDecodeAsNil() { - yyv4759[yyj4759] = Service{} - } else { - yyv4761 := &yyv4759[yyj4759] - yyv4761.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4759 := 0 - for ; !r.CheckBreak(); yyj4759++ { - - if yyj4759 >= len(yyv4759) { - yyv4759 = append(yyv4759, Service{}) // var yyz4759 Service - yyc4759 = true - } - yyh4759.ElemContainerState(yyj4759) - if yyj4759 < len(yyv4759) { - if r.TryDecodeAsNil() { - yyv4759[yyj4759] = Service{} - } else { - yyv4762 := &yyv4759[yyj4759] - yyv4762.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4759 < len(yyv4759) { - yyv4759 = yyv4759[:yyj4759] - yyc4759 = true - } else if yyj4759 == 0 && yyv4759 == nil { - yyv4759 = []Service{} - yyc4759 = true - } - } - yyh4759.End() - if yyc4759 { - *v = yyv4759 - } -} - -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 _, yyv4763 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4764 := &yyv4763 - yy4764.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 - - yyv4765 := *v - yyh4765, yyl4765 := z.DecSliceHelperStart() - var yyc4765 bool - if yyl4765 == 0 { - if yyv4765 == nil { - yyv4765 = []LoadBalancerIngress{} - yyc4765 = true - } else if len(yyv4765) != 0 { - yyv4765 = yyv4765[:0] - yyc4765 = true - } - } else if yyl4765 > 0 { - var yyrr4765, yyrl4765 int - var yyrt4765 bool - if yyl4765 > cap(yyv4765) { - - yyrg4765 := len(yyv4765) > 0 - yyv24765 := yyv4765 - yyrl4765, yyrt4765 = z.DecInferLen(yyl4765, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4765 { - if yyrl4765 <= cap(yyv4765) { - yyv4765 = yyv4765[:yyrl4765] - } else { - yyv4765 = make([]LoadBalancerIngress, yyrl4765) - } - } else { - yyv4765 = make([]LoadBalancerIngress, yyrl4765) - } - yyc4765 = true - yyrr4765 = len(yyv4765) - if yyrg4765 { - copy(yyv4765, yyv24765) - } - } else if yyl4765 != len(yyv4765) { - yyv4765 = yyv4765[:yyl4765] - yyc4765 = true - } - yyj4765 := 0 - for ; yyj4765 < yyrr4765; yyj4765++ { - yyh4765.ElemContainerState(yyj4765) - if r.TryDecodeAsNil() { - yyv4765[yyj4765] = LoadBalancerIngress{} - } else { - yyv4766 := &yyv4765[yyj4765] - yyv4766.CodecDecodeSelf(d) - } - - } - if yyrt4765 { - for ; yyj4765 < yyl4765; yyj4765++ { - yyv4765 = append(yyv4765, LoadBalancerIngress{}) - yyh4765.ElemContainerState(yyj4765) - if r.TryDecodeAsNil() { - yyv4765[yyj4765] = LoadBalancerIngress{} - } else { - yyv4767 := &yyv4765[yyj4765] - yyv4767.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4765 := 0 - for ; !r.CheckBreak(); yyj4765++ { - - if yyj4765 >= len(yyv4765) { - yyv4765 = append(yyv4765, LoadBalancerIngress{}) // var yyz4765 LoadBalancerIngress - yyc4765 = true - } - yyh4765.ElemContainerState(yyj4765) - if yyj4765 < len(yyv4765) { - if r.TryDecodeAsNil() { - yyv4765[yyj4765] = LoadBalancerIngress{} - } else { - yyv4768 := &yyv4765[yyj4765] - yyv4768.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4765 < len(yyv4765) { - yyv4765 = yyv4765[:yyj4765] - yyc4765 = true - } else if yyj4765 == 0 && yyv4765 == nil { - yyv4765 = []LoadBalancerIngress{} - yyc4765 = true - } - } - yyh4765.End() - if yyc4765 { - *v = yyv4765 - } -} - -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 _, yyv4769 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4770 := &yyv4769 - yy4770.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 - - yyv4771 := *v - yyh4771, yyl4771 := z.DecSliceHelperStart() - var yyc4771 bool - if yyl4771 == 0 { - if yyv4771 == nil { - yyv4771 = []ServicePort{} - yyc4771 = true - } else if len(yyv4771) != 0 { - yyv4771 = yyv4771[:0] - yyc4771 = true - } - } else if yyl4771 > 0 { - var yyrr4771, yyrl4771 int - var yyrt4771 bool - if yyl4771 > cap(yyv4771) { - - yyrg4771 := len(yyv4771) > 0 - yyv24771 := yyv4771 - yyrl4771, yyrt4771 = z.DecInferLen(yyl4771, z.DecBasicHandle().MaxInitLen, 80) - if yyrt4771 { - if yyrl4771 <= cap(yyv4771) { - yyv4771 = yyv4771[:yyrl4771] - } else { - yyv4771 = make([]ServicePort, yyrl4771) - } - } else { - yyv4771 = make([]ServicePort, yyrl4771) - } - yyc4771 = true - yyrr4771 = len(yyv4771) - if yyrg4771 { - copy(yyv4771, yyv24771) - } - } else if yyl4771 != len(yyv4771) { - yyv4771 = yyv4771[:yyl4771] - yyc4771 = true - } - yyj4771 := 0 - for ; yyj4771 < yyrr4771; yyj4771++ { - yyh4771.ElemContainerState(yyj4771) - if r.TryDecodeAsNil() { - yyv4771[yyj4771] = ServicePort{} - } else { - yyv4772 := &yyv4771[yyj4771] - yyv4772.CodecDecodeSelf(d) - } - - } - if yyrt4771 { - for ; yyj4771 < yyl4771; yyj4771++ { - yyv4771 = append(yyv4771, ServicePort{}) - yyh4771.ElemContainerState(yyj4771) - if r.TryDecodeAsNil() { - yyv4771[yyj4771] = ServicePort{} - } else { - yyv4773 := &yyv4771[yyj4771] - yyv4773.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4771 := 0 - for ; !r.CheckBreak(); yyj4771++ { - - if yyj4771 >= len(yyv4771) { - yyv4771 = append(yyv4771, ServicePort{}) // var yyz4771 ServicePort - yyc4771 = true - } - yyh4771.ElemContainerState(yyj4771) - if yyj4771 < len(yyv4771) { - if r.TryDecodeAsNil() { - yyv4771[yyj4771] = ServicePort{} - } else { - yyv4774 := &yyv4771[yyj4771] - yyv4774.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4771 < len(yyv4771) { - yyv4771 = yyv4771[:yyj4771] - yyc4771 = true - } else if yyj4771 == 0 && yyv4771 == nil { - yyv4771 = []ServicePort{} - yyc4771 = true - } - } - yyh4771.End() - if yyc4771 { - *v = yyv4771 - } -} - -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 _, yyv4775 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4776 := &yyv4775 - yy4776.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 - - yyv4777 := *v - yyh4777, yyl4777 := z.DecSliceHelperStart() - var yyc4777 bool - if yyl4777 == 0 { - if yyv4777 == nil { - yyv4777 = []ObjectReference{} - yyc4777 = true - } else if len(yyv4777) != 0 { - yyv4777 = yyv4777[:0] - yyc4777 = true - } - } else if yyl4777 > 0 { - var yyrr4777, yyrl4777 int - var yyrt4777 bool - if yyl4777 > cap(yyv4777) { - - yyrg4777 := len(yyv4777) > 0 - yyv24777 := yyv4777 - yyrl4777, yyrt4777 = z.DecInferLen(yyl4777, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4777 { - if yyrl4777 <= cap(yyv4777) { - yyv4777 = yyv4777[:yyrl4777] - } else { - yyv4777 = make([]ObjectReference, yyrl4777) - } - } else { - yyv4777 = make([]ObjectReference, yyrl4777) - } - yyc4777 = true - yyrr4777 = len(yyv4777) - if yyrg4777 { - copy(yyv4777, yyv24777) - } - } else if yyl4777 != len(yyv4777) { - yyv4777 = yyv4777[:yyl4777] - yyc4777 = true - } - yyj4777 := 0 - for ; yyj4777 < yyrr4777; yyj4777++ { - yyh4777.ElemContainerState(yyj4777) - if r.TryDecodeAsNil() { - yyv4777[yyj4777] = ObjectReference{} - } else { - yyv4778 := &yyv4777[yyj4777] - yyv4778.CodecDecodeSelf(d) - } - - } - if yyrt4777 { - for ; yyj4777 < yyl4777; yyj4777++ { - yyv4777 = append(yyv4777, ObjectReference{}) - yyh4777.ElemContainerState(yyj4777) - if r.TryDecodeAsNil() { - yyv4777[yyj4777] = ObjectReference{} - } else { - yyv4779 := &yyv4777[yyj4777] - yyv4779.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4777 := 0 - for ; !r.CheckBreak(); yyj4777++ { - - if yyj4777 >= len(yyv4777) { - yyv4777 = append(yyv4777, ObjectReference{}) // var yyz4777 ObjectReference - yyc4777 = true - } - yyh4777.ElemContainerState(yyj4777) - if yyj4777 < len(yyv4777) { - if r.TryDecodeAsNil() { - yyv4777[yyj4777] = ObjectReference{} - } else { - yyv4780 := &yyv4777[yyj4777] - yyv4780.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4777 < len(yyv4777) { - yyv4777 = yyv4777[:yyj4777] - yyc4777 = true - } else if yyj4777 == 0 && yyv4777 == nil { - yyv4777 = []ObjectReference{} - yyc4777 = true - } - } - yyh4777.End() - if yyc4777 { - *v = yyv4777 - } -} - -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 _, yyv4781 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4782 := &yyv4781 - yy4782.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 - - yyv4783 := *v - yyh4783, yyl4783 := z.DecSliceHelperStart() - var yyc4783 bool - if yyl4783 == 0 { - if yyv4783 == nil { - yyv4783 = []ServiceAccount{} - yyc4783 = true - } else if len(yyv4783) != 0 { - yyv4783 = yyv4783[:0] - yyc4783 = true - } - } else if yyl4783 > 0 { - var yyrr4783, yyrl4783 int - var yyrt4783 bool - if yyl4783 > cap(yyv4783) { - - yyrg4783 := len(yyv4783) > 0 - yyv24783 := yyv4783 - yyrl4783, yyrt4783 = z.DecInferLen(yyl4783, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4783 { - if yyrl4783 <= cap(yyv4783) { - yyv4783 = yyv4783[:yyrl4783] - } else { - yyv4783 = make([]ServiceAccount, yyrl4783) - } - } else { - yyv4783 = make([]ServiceAccount, yyrl4783) - } - yyc4783 = true - yyrr4783 = len(yyv4783) - if yyrg4783 { - copy(yyv4783, yyv24783) - } - } else if yyl4783 != len(yyv4783) { - yyv4783 = yyv4783[:yyl4783] - yyc4783 = true - } - yyj4783 := 0 - for ; yyj4783 < yyrr4783; yyj4783++ { - yyh4783.ElemContainerState(yyj4783) - if r.TryDecodeAsNil() { - yyv4783[yyj4783] = ServiceAccount{} - } else { - yyv4784 := &yyv4783[yyj4783] - yyv4784.CodecDecodeSelf(d) - } - - } - if yyrt4783 { - for ; yyj4783 < yyl4783; yyj4783++ { - yyv4783 = append(yyv4783, ServiceAccount{}) - yyh4783.ElemContainerState(yyj4783) - if r.TryDecodeAsNil() { - yyv4783[yyj4783] = ServiceAccount{} - } else { - yyv4785 := &yyv4783[yyj4783] - yyv4785.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4783 := 0 - for ; !r.CheckBreak(); yyj4783++ { - - if yyj4783 >= len(yyv4783) { - yyv4783 = append(yyv4783, ServiceAccount{}) // var yyz4783 ServiceAccount - yyc4783 = true - } - yyh4783.ElemContainerState(yyj4783) - if yyj4783 < len(yyv4783) { - if r.TryDecodeAsNil() { - yyv4783[yyj4783] = ServiceAccount{} - } else { - yyv4786 := &yyv4783[yyj4783] - yyv4786.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4783 < len(yyv4783) { - yyv4783 = yyv4783[:yyj4783] - yyc4783 = true - } else if yyj4783 == 0 && yyv4783 == nil { - yyv4783 = []ServiceAccount{} - yyc4783 = true - } - } - yyh4783.End() - if yyc4783 { - *v = yyv4783 - } -} - -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 _, yyv4787 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4788 := &yyv4787 - yy4788.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 - - yyv4789 := *v - yyh4789, yyl4789 := z.DecSliceHelperStart() - var yyc4789 bool - if yyl4789 == 0 { - if yyv4789 == nil { - yyv4789 = []EndpointSubset{} - yyc4789 = true - } else if len(yyv4789) != 0 { - yyv4789 = yyv4789[:0] - yyc4789 = true - } - } else if yyl4789 > 0 { - var yyrr4789, yyrl4789 int - var yyrt4789 bool - if yyl4789 > cap(yyv4789) { - - yyrg4789 := len(yyv4789) > 0 - yyv24789 := yyv4789 - yyrl4789, yyrt4789 = z.DecInferLen(yyl4789, z.DecBasicHandle().MaxInitLen, 72) - if yyrt4789 { - if yyrl4789 <= cap(yyv4789) { - yyv4789 = yyv4789[:yyrl4789] - } else { - yyv4789 = make([]EndpointSubset, yyrl4789) - } - } else { - yyv4789 = make([]EndpointSubset, yyrl4789) - } - yyc4789 = true - yyrr4789 = len(yyv4789) - if yyrg4789 { - copy(yyv4789, yyv24789) - } - } else if yyl4789 != len(yyv4789) { - yyv4789 = yyv4789[:yyl4789] - yyc4789 = true - } - yyj4789 := 0 - for ; yyj4789 < yyrr4789; yyj4789++ { - yyh4789.ElemContainerState(yyj4789) - if r.TryDecodeAsNil() { - yyv4789[yyj4789] = EndpointSubset{} - } else { - yyv4790 := &yyv4789[yyj4789] - yyv4790.CodecDecodeSelf(d) - } - - } - if yyrt4789 { - for ; yyj4789 < yyl4789; yyj4789++ { - yyv4789 = append(yyv4789, EndpointSubset{}) - yyh4789.ElemContainerState(yyj4789) - if r.TryDecodeAsNil() { - yyv4789[yyj4789] = EndpointSubset{} - } else { - yyv4791 := &yyv4789[yyj4789] - yyv4791.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4789 := 0 - for ; !r.CheckBreak(); yyj4789++ { - - if yyj4789 >= len(yyv4789) { - yyv4789 = append(yyv4789, EndpointSubset{}) // var yyz4789 EndpointSubset - yyc4789 = true - } - yyh4789.ElemContainerState(yyj4789) - if yyj4789 < len(yyv4789) { - if r.TryDecodeAsNil() { - yyv4789[yyj4789] = EndpointSubset{} - } else { - yyv4792 := &yyv4789[yyj4789] - yyv4792.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4789 < len(yyv4789) { - yyv4789 = yyv4789[:yyj4789] - yyc4789 = true - } else if yyj4789 == 0 && yyv4789 == nil { - yyv4789 = []EndpointSubset{} - yyc4789 = true - } - } - yyh4789.End() - if yyc4789 { - *v = yyv4789 - } -} - -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 _, yyv4793 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4794 := &yyv4793 - yy4794.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 - - yyv4795 := *v - yyh4795, yyl4795 := z.DecSliceHelperStart() - var yyc4795 bool - if yyl4795 == 0 { - if yyv4795 == nil { - yyv4795 = []EndpointAddress{} - yyc4795 = true - } else if len(yyv4795) != 0 { - yyv4795 = yyv4795[:0] - yyc4795 = true - } - } else if yyl4795 > 0 { - var yyrr4795, yyrl4795 int - var yyrt4795 bool - if yyl4795 > cap(yyv4795) { - - yyrg4795 := len(yyv4795) > 0 - yyv24795 := yyv4795 - yyrl4795, yyrt4795 = z.DecInferLen(yyl4795, z.DecBasicHandle().MaxInitLen, 48) - if yyrt4795 { - if yyrl4795 <= cap(yyv4795) { - yyv4795 = yyv4795[:yyrl4795] - } else { - yyv4795 = make([]EndpointAddress, yyrl4795) - } - } else { - yyv4795 = make([]EndpointAddress, yyrl4795) - } - yyc4795 = true - yyrr4795 = len(yyv4795) - if yyrg4795 { - copy(yyv4795, yyv24795) - } - } else if yyl4795 != len(yyv4795) { - yyv4795 = yyv4795[:yyl4795] - yyc4795 = true - } - yyj4795 := 0 - for ; yyj4795 < yyrr4795; yyj4795++ { - yyh4795.ElemContainerState(yyj4795) - if r.TryDecodeAsNil() { - yyv4795[yyj4795] = EndpointAddress{} - } else { - yyv4796 := &yyv4795[yyj4795] - yyv4796.CodecDecodeSelf(d) - } - - } - if yyrt4795 { - for ; yyj4795 < yyl4795; yyj4795++ { - yyv4795 = append(yyv4795, EndpointAddress{}) - yyh4795.ElemContainerState(yyj4795) - if r.TryDecodeAsNil() { - yyv4795[yyj4795] = EndpointAddress{} - } else { - yyv4797 := &yyv4795[yyj4795] - yyv4797.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4795 := 0 - for ; !r.CheckBreak(); yyj4795++ { - - if yyj4795 >= len(yyv4795) { - yyv4795 = append(yyv4795, EndpointAddress{}) // var yyz4795 EndpointAddress - yyc4795 = true - } - yyh4795.ElemContainerState(yyj4795) - if yyj4795 < len(yyv4795) { - if r.TryDecodeAsNil() { - yyv4795[yyj4795] = EndpointAddress{} - } else { - yyv4798 := &yyv4795[yyj4795] - yyv4798.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4795 < len(yyv4795) { - yyv4795 = yyv4795[:yyj4795] - yyc4795 = true - } else if yyj4795 == 0 && yyv4795 == nil { - yyv4795 = []EndpointAddress{} - yyc4795 = true - } - } - yyh4795.End() - if yyc4795 { - *v = yyv4795 - } -} - -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 _, yyv4799 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4800 := &yyv4799 - yy4800.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 - - yyv4801 := *v - yyh4801, yyl4801 := z.DecSliceHelperStart() - var yyc4801 bool - if yyl4801 == 0 { - if yyv4801 == nil { - yyv4801 = []EndpointPort{} - yyc4801 = true - } else if len(yyv4801) != 0 { - yyv4801 = yyv4801[:0] - yyc4801 = true - } - } else if yyl4801 > 0 { - var yyrr4801, yyrl4801 int - var yyrt4801 bool - if yyl4801 > cap(yyv4801) { - - yyrg4801 := len(yyv4801) > 0 - yyv24801 := yyv4801 - yyrl4801, yyrt4801 = z.DecInferLen(yyl4801, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4801 { - if yyrl4801 <= cap(yyv4801) { - yyv4801 = yyv4801[:yyrl4801] - } else { - yyv4801 = make([]EndpointPort, yyrl4801) - } - } else { - yyv4801 = make([]EndpointPort, yyrl4801) - } - yyc4801 = true - yyrr4801 = len(yyv4801) - if yyrg4801 { - copy(yyv4801, yyv24801) - } - } else if yyl4801 != len(yyv4801) { - yyv4801 = yyv4801[:yyl4801] - yyc4801 = true - } - yyj4801 := 0 - for ; yyj4801 < yyrr4801; yyj4801++ { - yyh4801.ElemContainerState(yyj4801) - if r.TryDecodeAsNil() { - yyv4801[yyj4801] = EndpointPort{} - } else { - yyv4802 := &yyv4801[yyj4801] - yyv4802.CodecDecodeSelf(d) - } - - } - if yyrt4801 { - for ; yyj4801 < yyl4801; yyj4801++ { - yyv4801 = append(yyv4801, EndpointPort{}) - yyh4801.ElemContainerState(yyj4801) - if r.TryDecodeAsNil() { - yyv4801[yyj4801] = EndpointPort{} - } else { - yyv4803 := &yyv4801[yyj4801] - yyv4803.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4801 := 0 - for ; !r.CheckBreak(); yyj4801++ { - - if yyj4801 >= len(yyv4801) { - yyv4801 = append(yyv4801, EndpointPort{}) // var yyz4801 EndpointPort - yyc4801 = true - } - yyh4801.ElemContainerState(yyj4801) - if yyj4801 < len(yyv4801) { - if r.TryDecodeAsNil() { - yyv4801[yyj4801] = EndpointPort{} - } else { - yyv4804 := &yyv4801[yyj4801] - yyv4804.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4801 < len(yyv4801) { - yyv4801 = yyv4801[:yyj4801] - yyc4801 = true - } else if yyj4801 == 0 && yyv4801 == nil { - yyv4801 = []EndpointPort{} - yyc4801 = true - } - } - yyh4801.End() - if yyc4801 { - *v = yyv4801 - } -} - -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 _, yyv4805 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4806 := &yyv4805 - yy4806.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 - - yyv4807 := *v - yyh4807, yyl4807 := z.DecSliceHelperStart() - var yyc4807 bool - if yyl4807 == 0 { - if yyv4807 == nil { - yyv4807 = []Endpoints{} - yyc4807 = true - } else if len(yyv4807) != 0 { - yyv4807 = yyv4807[:0] - yyc4807 = true - } - } else if yyl4807 > 0 { - var yyrr4807, yyrl4807 int - var yyrt4807 bool - if yyl4807 > cap(yyv4807) { - - yyrg4807 := len(yyv4807) > 0 - yyv24807 := yyv4807 - yyrl4807, yyrt4807 = z.DecInferLen(yyl4807, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4807 { - if yyrl4807 <= cap(yyv4807) { - yyv4807 = yyv4807[:yyrl4807] - } else { - yyv4807 = make([]Endpoints, yyrl4807) - } - } else { - yyv4807 = make([]Endpoints, yyrl4807) - } - yyc4807 = true - yyrr4807 = len(yyv4807) - if yyrg4807 { - copy(yyv4807, yyv24807) - } - } else if yyl4807 != len(yyv4807) { - yyv4807 = yyv4807[:yyl4807] - yyc4807 = true - } - yyj4807 := 0 - for ; yyj4807 < yyrr4807; yyj4807++ { - yyh4807.ElemContainerState(yyj4807) - if r.TryDecodeAsNil() { - yyv4807[yyj4807] = Endpoints{} - } else { - yyv4808 := &yyv4807[yyj4807] - yyv4808.CodecDecodeSelf(d) - } - - } - if yyrt4807 { - for ; yyj4807 < yyl4807; yyj4807++ { - yyv4807 = append(yyv4807, Endpoints{}) - yyh4807.ElemContainerState(yyj4807) - if r.TryDecodeAsNil() { - yyv4807[yyj4807] = Endpoints{} - } else { - yyv4809 := &yyv4807[yyj4807] - yyv4809.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4807 := 0 - for ; !r.CheckBreak(); yyj4807++ { - - if yyj4807 >= len(yyv4807) { - yyv4807 = append(yyv4807, Endpoints{}) // var yyz4807 Endpoints - yyc4807 = true - } - yyh4807.ElemContainerState(yyj4807) - if yyj4807 < len(yyv4807) { - if r.TryDecodeAsNil() { - yyv4807[yyj4807] = Endpoints{} - } else { - yyv4810 := &yyv4807[yyj4807] - yyv4810.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4807 < len(yyv4807) { - yyv4807 = yyv4807[:yyj4807] - yyc4807 = true - } else if yyj4807 == 0 && yyv4807 == nil { - yyv4807 = []Endpoints{} - yyc4807 = true - } - } - yyh4807.End() - if yyc4807 { - *v = yyv4807 - } -} - -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 _, yyv4811 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4812 := &yyv4811 - yy4812.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 - - yyv4813 := *v - yyh4813, yyl4813 := z.DecSliceHelperStart() - var yyc4813 bool - if yyl4813 == 0 { - if yyv4813 == nil { - yyv4813 = []NodeCondition{} - yyc4813 = true - } else if len(yyv4813) != 0 { - yyv4813 = yyv4813[:0] - yyc4813 = true - } - } else if yyl4813 > 0 { - var yyrr4813, yyrl4813 int - var yyrt4813 bool - if yyl4813 > cap(yyv4813) { - - yyrg4813 := len(yyv4813) > 0 - yyv24813 := yyv4813 - yyrl4813, yyrt4813 = z.DecInferLen(yyl4813, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4813 { - if yyrl4813 <= cap(yyv4813) { - yyv4813 = yyv4813[:yyrl4813] - } else { - yyv4813 = make([]NodeCondition, yyrl4813) - } - } else { - yyv4813 = make([]NodeCondition, yyrl4813) - } - yyc4813 = true - yyrr4813 = len(yyv4813) - if yyrg4813 { - copy(yyv4813, yyv24813) - } - } else if yyl4813 != len(yyv4813) { - yyv4813 = yyv4813[:yyl4813] - yyc4813 = true - } - yyj4813 := 0 - for ; yyj4813 < yyrr4813; yyj4813++ { - yyh4813.ElemContainerState(yyj4813) - if r.TryDecodeAsNil() { - yyv4813[yyj4813] = NodeCondition{} - } else { - yyv4814 := &yyv4813[yyj4813] - yyv4814.CodecDecodeSelf(d) - } - - } - if yyrt4813 { - for ; yyj4813 < yyl4813; yyj4813++ { - yyv4813 = append(yyv4813, NodeCondition{}) - yyh4813.ElemContainerState(yyj4813) - if r.TryDecodeAsNil() { - yyv4813[yyj4813] = NodeCondition{} - } else { - yyv4815 := &yyv4813[yyj4813] - yyv4815.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4813 := 0 - for ; !r.CheckBreak(); yyj4813++ { - - if yyj4813 >= len(yyv4813) { - yyv4813 = append(yyv4813, NodeCondition{}) // var yyz4813 NodeCondition - yyc4813 = true - } - yyh4813.ElemContainerState(yyj4813) - if yyj4813 < len(yyv4813) { - if r.TryDecodeAsNil() { - yyv4813[yyj4813] = NodeCondition{} - } else { - yyv4816 := &yyv4813[yyj4813] - yyv4816.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4813 < len(yyv4813) { - yyv4813 = yyv4813[:yyj4813] - yyc4813 = true - } else if yyj4813 == 0 && yyv4813 == nil { - yyv4813 = []NodeCondition{} - yyc4813 = true - } - } - yyh4813.End() - if yyc4813 { - *v = yyv4813 - } -} - -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 _, yyv4817 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4818 := &yyv4817 - yy4818.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 - - yyv4819 := *v - yyh4819, yyl4819 := z.DecSliceHelperStart() - var yyc4819 bool - if yyl4819 == 0 { - if yyv4819 == nil { - yyv4819 = []NodeAddress{} - yyc4819 = true - } else if len(yyv4819) != 0 { - yyv4819 = yyv4819[:0] - yyc4819 = true - } - } else if yyl4819 > 0 { - var yyrr4819, yyrl4819 int - var yyrt4819 bool - if yyl4819 > cap(yyv4819) { - - yyrg4819 := len(yyv4819) > 0 - yyv24819 := yyv4819 - yyrl4819, yyrt4819 = z.DecInferLen(yyl4819, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4819 { - if yyrl4819 <= cap(yyv4819) { - yyv4819 = yyv4819[:yyrl4819] - } else { - yyv4819 = make([]NodeAddress, yyrl4819) - } - } else { - yyv4819 = make([]NodeAddress, yyrl4819) - } - yyc4819 = true - yyrr4819 = len(yyv4819) - if yyrg4819 { - copy(yyv4819, yyv24819) - } - } else if yyl4819 != len(yyv4819) { - yyv4819 = yyv4819[:yyl4819] - yyc4819 = true - } - yyj4819 := 0 - for ; yyj4819 < yyrr4819; yyj4819++ { - yyh4819.ElemContainerState(yyj4819) - if r.TryDecodeAsNil() { - yyv4819[yyj4819] = NodeAddress{} - } else { - yyv4820 := &yyv4819[yyj4819] - yyv4820.CodecDecodeSelf(d) - } - - } - if yyrt4819 { - for ; yyj4819 < yyl4819; yyj4819++ { - yyv4819 = append(yyv4819, NodeAddress{}) - yyh4819.ElemContainerState(yyj4819) - if r.TryDecodeAsNil() { - yyv4819[yyj4819] = NodeAddress{} - } else { - yyv4821 := &yyv4819[yyj4819] - yyv4821.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4819 := 0 - for ; !r.CheckBreak(); yyj4819++ { - - if yyj4819 >= len(yyv4819) { - yyv4819 = append(yyv4819, NodeAddress{}) // var yyz4819 NodeAddress - yyc4819 = true - } - yyh4819.ElemContainerState(yyj4819) - if yyj4819 < len(yyv4819) { - if r.TryDecodeAsNil() { - yyv4819[yyj4819] = NodeAddress{} - } else { - yyv4822 := &yyv4819[yyj4819] - yyv4822.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4819 < len(yyv4819) { - yyv4819 = yyv4819[:yyj4819] - yyc4819 = true - } else if yyj4819 == 0 && yyv4819 == nil { - yyv4819 = []NodeAddress{} - yyc4819 = true - } - } - yyh4819.End() - if yyc4819 { - *v = yyv4819 - } -} - -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 _, yyv4823 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4824 := &yyv4823 - yy4824.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 - - yyv4825 := *v - yyh4825, yyl4825 := z.DecSliceHelperStart() - var yyc4825 bool - if yyl4825 == 0 { - if yyv4825 == nil { - yyv4825 = []ContainerImage{} - yyc4825 = true - } else if len(yyv4825) != 0 { - yyv4825 = yyv4825[:0] - yyc4825 = true - } - } else if yyl4825 > 0 { - var yyrr4825, yyrl4825 int - var yyrt4825 bool - if yyl4825 > cap(yyv4825) { - - yyrg4825 := len(yyv4825) > 0 - yyv24825 := yyv4825 - yyrl4825, yyrt4825 = z.DecInferLen(yyl4825, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4825 { - if yyrl4825 <= cap(yyv4825) { - yyv4825 = yyv4825[:yyrl4825] - } else { - yyv4825 = make([]ContainerImage, yyrl4825) - } - } else { - yyv4825 = make([]ContainerImage, yyrl4825) - } - yyc4825 = true - yyrr4825 = len(yyv4825) - if yyrg4825 { - copy(yyv4825, yyv24825) - } - } else if yyl4825 != len(yyv4825) { - yyv4825 = yyv4825[:yyl4825] - yyc4825 = true - } - yyj4825 := 0 - for ; yyj4825 < yyrr4825; yyj4825++ { - yyh4825.ElemContainerState(yyj4825) - if r.TryDecodeAsNil() { - yyv4825[yyj4825] = ContainerImage{} - } else { - yyv4826 := &yyv4825[yyj4825] - yyv4826.CodecDecodeSelf(d) - } - - } - if yyrt4825 { - for ; yyj4825 < yyl4825; yyj4825++ { - yyv4825 = append(yyv4825, ContainerImage{}) - yyh4825.ElemContainerState(yyj4825) - if r.TryDecodeAsNil() { - yyv4825[yyj4825] = ContainerImage{} - } else { - yyv4827 := &yyv4825[yyj4825] - yyv4827.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4825 := 0 - for ; !r.CheckBreak(); yyj4825++ { - - if yyj4825 >= len(yyv4825) { - yyv4825 = append(yyv4825, ContainerImage{}) // var yyz4825 ContainerImage - yyc4825 = true - } - yyh4825.ElemContainerState(yyj4825) - if yyj4825 < len(yyv4825) { - if r.TryDecodeAsNil() { - yyv4825[yyj4825] = ContainerImage{} - } else { - yyv4828 := &yyv4825[yyj4825] - yyv4828.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4825 < len(yyv4825) { - yyv4825 = yyv4825[:yyj4825] - yyc4825 = true - } else if yyj4825 == 0 && yyv4825 == nil { - yyv4825 = []ContainerImage{} - yyc4825 = true - } - } - yyh4825.End() - if yyc4825 { - *v = yyv4825 - } -} - -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 _, yyv4829 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4829.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 - - yyv4830 := *v - yyh4830, yyl4830 := z.DecSliceHelperStart() - var yyc4830 bool - if yyl4830 == 0 { - if yyv4830 == nil { - yyv4830 = []UniqueVolumeName{} - yyc4830 = true - } else if len(yyv4830) != 0 { - yyv4830 = yyv4830[:0] - yyc4830 = true - } - } else if yyl4830 > 0 { - var yyrr4830, yyrl4830 int - var yyrt4830 bool - if yyl4830 > cap(yyv4830) { - - yyrl4830, yyrt4830 = z.DecInferLen(yyl4830, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4830 { - if yyrl4830 <= cap(yyv4830) { - yyv4830 = yyv4830[:yyrl4830] - } else { - yyv4830 = make([]UniqueVolumeName, yyrl4830) - } - } else { - yyv4830 = make([]UniqueVolumeName, yyrl4830) - } - yyc4830 = true - yyrr4830 = len(yyv4830) - } else if yyl4830 != len(yyv4830) { - yyv4830 = yyv4830[:yyl4830] - yyc4830 = true - } - yyj4830 := 0 - for ; yyj4830 < yyrr4830; yyj4830++ { - yyh4830.ElemContainerState(yyj4830) - if r.TryDecodeAsNil() { - yyv4830[yyj4830] = "" - } else { - yyv4830[yyj4830] = UniqueVolumeName(r.DecodeString()) - } - - } - if yyrt4830 { - for ; yyj4830 < yyl4830; yyj4830++ { - yyv4830 = append(yyv4830, "") - yyh4830.ElemContainerState(yyj4830) - if r.TryDecodeAsNil() { - yyv4830[yyj4830] = "" - } else { - yyv4830[yyj4830] = UniqueVolumeName(r.DecodeString()) - } - - } - } - - } else { - yyj4830 := 0 - for ; !r.CheckBreak(); yyj4830++ { - - if yyj4830 >= len(yyv4830) { - yyv4830 = append(yyv4830, "") // var yyz4830 UniqueVolumeName - yyc4830 = true - } - yyh4830.ElemContainerState(yyj4830) - if yyj4830 < len(yyv4830) { - if r.TryDecodeAsNil() { - yyv4830[yyj4830] = "" - } else { - yyv4830[yyj4830] = UniqueVolumeName(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4830 < len(yyv4830) { - yyv4830 = yyv4830[:yyj4830] - yyc4830 = true - } else if yyj4830 == 0 && yyv4830 == nil { - yyv4830 = []UniqueVolumeName{} - yyc4830 = true - } - } - yyh4830.End() - if yyc4830 { - *v = yyv4830 - } -} - -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 _, yyv4834 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4835 := &yyv4834 - yy4835.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 - - yyv4836 := *v - yyh4836, yyl4836 := z.DecSliceHelperStart() - var yyc4836 bool - if yyl4836 == 0 { - if yyv4836 == nil { - yyv4836 = []AttachedVolume{} - yyc4836 = true - } else if len(yyv4836) != 0 { - yyv4836 = yyv4836[:0] - yyc4836 = true - } - } else if yyl4836 > 0 { - var yyrr4836, yyrl4836 int - var yyrt4836 bool - if yyl4836 > cap(yyv4836) { - - yyrg4836 := len(yyv4836) > 0 - yyv24836 := yyv4836 - yyrl4836, yyrt4836 = z.DecInferLen(yyl4836, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4836 { - if yyrl4836 <= cap(yyv4836) { - yyv4836 = yyv4836[:yyrl4836] - } else { - yyv4836 = make([]AttachedVolume, yyrl4836) - } - } else { - yyv4836 = make([]AttachedVolume, yyrl4836) - } - yyc4836 = true - yyrr4836 = len(yyv4836) - if yyrg4836 { - copy(yyv4836, yyv24836) - } - } else if yyl4836 != len(yyv4836) { - yyv4836 = yyv4836[:yyl4836] - yyc4836 = true - } - yyj4836 := 0 - for ; yyj4836 < yyrr4836; yyj4836++ { - yyh4836.ElemContainerState(yyj4836) - if r.TryDecodeAsNil() { - yyv4836[yyj4836] = AttachedVolume{} - } else { - yyv4837 := &yyv4836[yyj4836] - yyv4837.CodecDecodeSelf(d) - } - - } - if yyrt4836 { - for ; yyj4836 < yyl4836; yyj4836++ { - yyv4836 = append(yyv4836, AttachedVolume{}) - yyh4836.ElemContainerState(yyj4836) - if r.TryDecodeAsNil() { - yyv4836[yyj4836] = AttachedVolume{} - } else { - yyv4838 := &yyv4836[yyj4836] - yyv4838.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4836 := 0 - for ; !r.CheckBreak(); yyj4836++ { - - if yyj4836 >= len(yyv4836) { - yyv4836 = append(yyv4836, AttachedVolume{}) // var yyz4836 AttachedVolume - yyc4836 = true - } - yyh4836.ElemContainerState(yyj4836) - if yyj4836 < len(yyv4836) { - if r.TryDecodeAsNil() { - yyv4836[yyj4836] = AttachedVolume{} - } else { - yyv4839 := &yyv4836[yyj4836] - yyv4839.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4836 < len(yyv4836) { - yyv4836 = yyv4836[:yyj4836] - yyc4836 = true - } else if yyj4836 == 0 && yyv4836 == nil { - yyv4836 = []AttachedVolume{} - yyc4836 = true - } - } - yyh4836.End() - if yyc4836 { - *v = yyv4836 - } -} - -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 _, yyv4840 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4841 := &yyv4840 - yy4841.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 - - yyv4842 := *v - yyh4842, yyl4842 := z.DecSliceHelperStart() - var yyc4842 bool - if yyl4842 == 0 { - if yyv4842 == nil { - yyv4842 = []PreferAvoidPodsEntry{} - yyc4842 = true - } else if len(yyv4842) != 0 { - yyv4842 = yyv4842[:0] - yyc4842 = true - } - } else if yyl4842 > 0 { - var yyrr4842, yyrl4842 int - var yyrt4842 bool - if yyl4842 > cap(yyv4842) { - - yyrg4842 := len(yyv4842) > 0 - yyv24842 := yyv4842 - yyrl4842, yyrt4842 = z.DecInferLen(yyl4842, z.DecBasicHandle().MaxInitLen, 64) - if yyrt4842 { - if yyrl4842 <= cap(yyv4842) { - yyv4842 = yyv4842[:yyrl4842] - } else { - yyv4842 = make([]PreferAvoidPodsEntry, yyrl4842) - } - } else { - yyv4842 = make([]PreferAvoidPodsEntry, yyrl4842) - } - yyc4842 = true - yyrr4842 = len(yyv4842) - if yyrg4842 { - copy(yyv4842, yyv24842) - } - } else if yyl4842 != len(yyv4842) { - yyv4842 = yyv4842[:yyl4842] - yyc4842 = true - } - yyj4842 := 0 - for ; yyj4842 < yyrr4842; yyj4842++ { - yyh4842.ElemContainerState(yyj4842) - if r.TryDecodeAsNil() { - yyv4842[yyj4842] = PreferAvoidPodsEntry{} - } else { - yyv4843 := &yyv4842[yyj4842] - yyv4843.CodecDecodeSelf(d) - } - - } - if yyrt4842 { - for ; yyj4842 < yyl4842; yyj4842++ { - yyv4842 = append(yyv4842, PreferAvoidPodsEntry{}) - yyh4842.ElemContainerState(yyj4842) - if r.TryDecodeAsNil() { - yyv4842[yyj4842] = PreferAvoidPodsEntry{} - } else { - yyv4844 := &yyv4842[yyj4842] - yyv4844.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4842 := 0 - for ; !r.CheckBreak(); yyj4842++ { - - if yyj4842 >= len(yyv4842) { - yyv4842 = append(yyv4842, PreferAvoidPodsEntry{}) // var yyz4842 PreferAvoidPodsEntry - yyc4842 = true - } - yyh4842.ElemContainerState(yyj4842) - if yyj4842 < len(yyv4842) { - if r.TryDecodeAsNil() { - yyv4842[yyj4842] = PreferAvoidPodsEntry{} - } else { - yyv4845 := &yyv4842[yyj4842] - yyv4845.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4842 < len(yyv4842) { - yyv4842 = yyv4842[:yyj4842] - yyc4842 = true - } else if yyj4842 == 0 && yyv4842 == nil { - yyv4842 = []PreferAvoidPodsEntry{} - yyc4842 = true - } - } - yyh4842.End() - if yyc4842 { - *v = yyv4842 - } -} - -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 yyk4846, yyv4846 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yyk4846.CodecEncodeSelf(e) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4847 := &yyv4846 - yym4848 := z.EncBinary() - _ = yym4848 - if false { - } else if z.HasExtensions() && z.EncExt(yy4847) { - } else if !yym4848 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4847) - } else { - z.EncFallback(yy4847) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) decResourceList(v *ResourceList, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv4849 := *v - yyl4849 := r.ReadMapStart() - yybh4849 := z.DecBasicHandle() - if yyv4849 == nil { - yyrl4849, _ := z.DecInferLen(yyl4849, yybh4849.MaxInitLen, 72) - yyv4849 = make(map[ResourceName]pkg3_resource.Quantity, yyrl4849) - *v = yyv4849 - } - var yymk4849 ResourceName - var yymv4849 pkg3_resource.Quantity - var yymg4849 bool - if yybh4849.MapValueReset { - yymg4849 = true - } - if yyl4849 > 0 { - for yyj4849 := 0; yyj4849 < yyl4849; yyj4849++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4849 = "" - } else { - yymk4849 = ResourceName(r.DecodeString()) - } - - if yymg4849 { - yymv4849 = yyv4849[yymk4849] - } else { - yymv4849 = pkg3_resource.Quantity{} - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4849 = pkg3_resource.Quantity{} - } else { - yyv4851 := &yymv4849 - yym4852 := z.DecBinary() - _ = yym4852 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4851) { - } else if !yym4852 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4851) - } else { - z.DecFallback(yyv4851, false) - } - } - - if yyv4849 != nil { - yyv4849[yymk4849] = yymv4849 - } - } - } else if yyl4849 < 0 { - for yyj4849 := 0; !r.CheckBreak(); yyj4849++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4849 = "" - } else { - yymk4849 = ResourceName(r.DecodeString()) - } - - if yymg4849 { - yymv4849 = yyv4849[yymk4849] - } else { - yymv4849 = pkg3_resource.Quantity{} - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4849 = pkg3_resource.Quantity{} - } else { - yyv4854 := &yymv4849 - yym4855 := z.DecBinary() - _ = yym4855 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4854) { - } else if !yym4855 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4854) - } else { - z.DecFallback(yyv4854, false) - } - } - - if yyv4849 != nil { - yyv4849[yymk4849] = yymv4849 - } - } - } // 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 _, yyv4856 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4857 := &yyv4856 - yy4857.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 - - yyv4858 := *v - yyh4858, yyl4858 := z.DecSliceHelperStart() - var yyc4858 bool - if yyl4858 == 0 { - if yyv4858 == nil { - yyv4858 = []Node{} - yyc4858 = true - } else if len(yyv4858) != 0 { - yyv4858 = yyv4858[:0] - yyc4858 = true - } - } else if yyl4858 > 0 { - var yyrr4858, yyrl4858 int - var yyrt4858 bool - if yyl4858 > cap(yyv4858) { - - yyrg4858 := len(yyv4858) > 0 - yyv24858 := yyv4858 - yyrl4858, yyrt4858 = z.DecInferLen(yyl4858, z.DecBasicHandle().MaxInitLen, 632) - if yyrt4858 { - if yyrl4858 <= cap(yyv4858) { - yyv4858 = yyv4858[:yyrl4858] - } else { - yyv4858 = make([]Node, yyrl4858) - } - } else { - yyv4858 = make([]Node, yyrl4858) - } - yyc4858 = true - yyrr4858 = len(yyv4858) - if yyrg4858 { - copy(yyv4858, yyv24858) - } - } else if yyl4858 != len(yyv4858) { - yyv4858 = yyv4858[:yyl4858] - yyc4858 = true - } - yyj4858 := 0 - for ; yyj4858 < yyrr4858; yyj4858++ { - yyh4858.ElemContainerState(yyj4858) - if r.TryDecodeAsNil() { - yyv4858[yyj4858] = Node{} - } else { - yyv4859 := &yyv4858[yyj4858] - yyv4859.CodecDecodeSelf(d) - } - - } - if yyrt4858 { - for ; yyj4858 < yyl4858; yyj4858++ { - yyv4858 = append(yyv4858, Node{}) - yyh4858.ElemContainerState(yyj4858) - if r.TryDecodeAsNil() { - yyv4858[yyj4858] = Node{} - } else { - yyv4860 := &yyv4858[yyj4858] - yyv4860.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4858 := 0 - for ; !r.CheckBreak(); yyj4858++ { - - if yyj4858 >= len(yyv4858) { - yyv4858 = append(yyv4858, Node{}) // var yyz4858 Node - yyc4858 = true - } - yyh4858.ElemContainerState(yyj4858) - if yyj4858 < len(yyv4858) { - if r.TryDecodeAsNil() { - yyv4858[yyj4858] = Node{} - } else { - yyv4861 := &yyv4858[yyj4858] - yyv4861.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4858 < len(yyv4858) { - yyv4858 = yyv4858[:yyj4858] - yyc4858 = true - } else if yyj4858 == 0 && yyv4858 == nil { - yyv4858 = []Node{} - yyc4858 = true - } - } - yyh4858.End() - if yyc4858 { - *v = yyv4858 - } -} - -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 _, yyv4862 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4862.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 - - yyv4863 := *v - yyh4863, yyl4863 := z.DecSliceHelperStart() - var yyc4863 bool - if yyl4863 == 0 { - if yyv4863 == nil { - yyv4863 = []FinalizerName{} - yyc4863 = true - } else if len(yyv4863) != 0 { - yyv4863 = yyv4863[:0] - yyc4863 = true - } - } else if yyl4863 > 0 { - var yyrr4863, yyrl4863 int - var yyrt4863 bool - if yyl4863 > cap(yyv4863) { - - yyrl4863, yyrt4863 = z.DecInferLen(yyl4863, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4863 { - if yyrl4863 <= cap(yyv4863) { - yyv4863 = yyv4863[:yyrl4863] - } else { - yyv4863 = make([]FinalizerName, yyrl4863) - } - } else { - yyv4863 = make([]FinalizerName, yyrl4863) - } - yyc4863 = true - yyrr4863 = len(yyv4863) - } else if yyl4863 != len(yyv4863) { - yyv4863 = yyv4863[:yyl4863] - yyc4863 = true - } - yyj4863 := 0 - for ; yyj4863 < yyrr4863; yyj4863++ { - yyh4863.ElemContainerState(yyj4863) - if r.TryDecodeAsNil() { - yyv4863[yyj4863] = "" - } else { - yyv4863[yyj4863] = FinalizerName(r.DecodeString()) - } - - } - if yyrt4863 { - for ; yyj4863 < yyl4863; yyj4863++ { - yyv4863 = append(yyv4863, "") - yyh4863.ElemContainerState(yyj4863) - if r.TryDecodeAsNil() { - yyv4863[yyj4863] = "" - } else { - yyv4863[yyj4863] = FinalizerName(r.DecodeString()) - } - - } - } - - } else { - yyj4863 := 0 - for ; !r.CheckBreak(); yyj4863++ { - - if yyj4863 >= len(yyv4863) { - yyv4863 = append(yyv4863, "") // var yyz4863 FinalizerName - yyc4863 = true - } - yyh4863.ElemContainerState(yyj4863) - if yyj4863 < len(yyv4863) { - if r.TryDecodeAsNil() { - yyv4863[yyj4863] = "" - } else { - yyv4863[yyj4863] = FinalizerName(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4863 < len(yyv4863) { - yyv4863 = yyv4863[:yyj4863] - yyc4863 = true - } else if yyj4863 == 0 && yyv4863 == nil { - yyv4863 = []FinalizerName{} - yyc4863 = true - } - } - yyh4863.End() - if yyc4863 { - *v = yyv4863 - } -} - -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 _, yyv4867 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4868 := &yyv4867 - yy4868.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 - - yyv4869 := *v - yyh4869, yyl4869 := z.DecSliceHelperStart() - var yyc4869 bool - if yyl4869 == 0 { - if yyv4869 == nil { - yyv4869 = []Namespace{} - yyc4869 = true - } else if len(yyv4869) != 0 { - yyv4869 = yyv4869[:0] - yyc4869 = true - } - } else if yyl4869 > 0 { - var yyrr4869, yyrl4869 int - var yyrt4869 bool - if yyl4869 > cap(yyv4869) { - - yyrg4869 := len(yyv4869) > 0 - yyv24869 := yyv4869 - yyrl4869, yyrt4869 = z.DecInferLen(yyl4869, z.DecBasicHandle().MaxInitLen, 296) - if yyrt4869 { - if yyrl4869 <= cap(yyv4869) { - yyv4869 = yyv4869[:yyrl4869] - } else { - yyv4869 = make([]Namespace, yyrl4869) - } - } else { - yyv4869 = make([]Namespace, yyrl4869) - } - yyc4869 = true - yyrr4869 = len(yyv4869) - if yyrg4869 { - copy(yyv4869, yyv24869) - } - } else if yyl4869 != len(yyv4869) { - yyv4869 = yyv4869[:yyl4869] - yyc4869 = true - } - yyj4869 := 0 - for ; yyj4869 < yyrr4869; yyj4869++ { - yyh4869.ElemContainerState(yyj4869) - if r.TryDecodeAsNil() { - yyv4869[yyj4869] = Namespace{} - } else { - yyv4870 := &yyv4869[yyj4869] - yyv4870.CodecDecodeSelf(d) - } - - } - if yyrt4869 { - for ; yyj4869 < yyl4869; yyj4869++ { - yyv4869 = append(yyv4869, Namespace{}) - yyh4869.ElemContainerState(yyj4869) - if r.TryDecodeAsNil() { - yyv4869[yyj4869] = Namespace{} - } else { - yyv4871 := &yyv4869[yyj4869] - yyv4871.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4869 := 0 - for ; !r.CheckBreak(); yyj4869++ { - - if yyj4869 >= len(yyv4869) { - yyv4869 = append(yyv4869, Namespace{}) // var yyz4869 Namespace - yyc4869 = true - } - yyh4869.ElemContainerState(yyj4869) - if yyj4869 < len(yyv4869) { - if r.TryDecodeAsNil() { - yyv4869[yyj4869] = Namespace{} - } else { - yyv4872 := &yyv4869[yyj4869] - yyv4872.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4869 < len(yyv4869) { - yyv4869 = yyv4869[:yyj4869] - yyc4869 = true - } else if yyj4869 == 0 && yyv4869 == nil { - yyv4869 = []Namespace{} - yyc4869 = true - } - } - yyh4869.End() - if yyc4869 { - *v = yyv4869 - } -} - -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 _, yyv4873 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4874 := &yyv4873 - yy4874.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 - - yyv4875 := *v - yyh4875, yyl4875 := z.DecSliceHelperStart() - var yyc4875 bool - if yyl4875 == 0 { - if yyv4875 == nil { - yyv4875 = []Event{} - yyc4875 = true - } else if len(yyv4875) != 0 { - yyv4875 = yyv4875[:0] - yyc4875 = true - } - } else if yyl4875 > 0 { - var yyrr4875, yyrl4875 int - var yyrt4875 bool - if yyl4875 > cap(yyv4875) { - - yyrg4875 := len(yyv4875) > 0 - yyv24875 := yyv4875 - yyrl4875, yyrt4875 = z.DecInferLen(yyl4875, z.DecBasicHandle().MaxInitLen, 504) - if yyrt4875 { - if yyrl4875 <= cap(yyv4875) { - yyv4875 = yyv4875[:yyrl4875] - } else { - yyv4875 = make([]Event, yyrl4875) - } - } else { - yyv4875 = make([]Event, yyrl4875) - } - yyc4875 = true - yyrr4875 = len(yyv4875) - if yyrg4875 { - copy(yyv4875, yyv24875) - } - } else if yyl4875 != len(yyv4875) { - yyv4875 = yyv4875[:yyl4875] - yyc4875 = true - } - yyj4875 := 0 - for ; yyj4875 < yyrr4875; yyj4875++ { - yyh4875.ElemContainerState(yyj4875) - if r.TryDecodeAsNil() { - yyv4875[yyj4875] = Event{} - } else { - yyv4876 := &yyv4875[yyj4875] - yyv4876.CodecDecodeSelf(d) - } - - } - if yyrt4875 { - for ; yyj4875 < yyl4875; yyj4875++ { - yyv4875 = append(yyv4875, Event{}) - yyh4875.ElemContainerState(yyj4875) - if r.TryDecodeAsNil() { - yyv4875[yyj4875] = Event{} - } else { - yyv4877 := &yyv4875[yyj4875] - yyv4877.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4875 := 0 - for ; !r.CheckBreak(); yyj4875++ { - - if yyj4875 >= len(yyv4875) { - yyv4875 = append(yyv4875, Event{}) // var yyz4875 Event - yyc4875 = true - } - yyh4875.ElemContainerState(yyj4875) - if yyj4875 < len(yyv4875) { - if r.TryDecodeAsNil() { - yyv4875[yyj4875] = Event{} - } else { - yyv4878 := &yyv4875[yyj4875] - yyv4878.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4875 < len(yyv4875) { - yyv4875 = yyv4875[:yyj4875] - yyc4875 = true - } else if yyj4875 == 0 && yyv4875 == nil { - yyv4875 = []Event{} - yyc4875 = true - } - } - yyh4875.End() - if yyc4875 { - *v = yyv4875 - } -} - -func (x codecSelfer1234) encSliceruntime_Object(v []pkg7_runtime.Object, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv4879 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyv4879 == nil { - r.EncodeNil() - } else { - yym4880 := z.EncBinary() - _ = yym4880 - if false { - } else if z.HasExtensions() && z.EncExt(yyv4879) { - } else { - z.EncFallback(yyv4879) - } - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceruntime_Object(v *[]pkg7_runtime.Object, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv4881 := *v - yyh4881, yyl4881 := z.DecSliceHelperStart() - var yyc4881 bool - if yyl4881 == 0 { - if yyv4881 == nil { - yyv4881 = []pkg7_runtime.Object{} - yyc4881 = true - } else if len(yyv4881) != 0 { - yyv4881 = yyv4881[:0] - yyc4881 = true - } - } else if yyl4881 > 0 { - var yyrr4881, yyrl4881 int - var yyrt4881 bool - if yyl4881 > cap(yyv4881) { - - yyrg4881 := len(yyv4881) > 0 - yyv24881 := yyv4881 - yyrl4881, yyrt4881 = z.DecInferLen(yyl4881, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4881 { - if yyrl4881 <= cap(yyv4881) { - yyv4881 = yyv4881[:yyrl4881] - } else { - yyv4881 = make([]pkg7_runtime.Object, yyrl4881) - } - } else { - yyv4881 = make([]pkg7_runtime.Object, yyrl4881) - } - yyc4881 = true - yyrr4881 = len(yyv4881) - if yyrg4881 { - copy(yyv4881, yyv24881) - } - } else if yyl4881 != len(yyv4881) { - yyv4881 = yyv4881[:yyl4881] - yyc4881 = true - } - yyj4881 := 0 - for ; yyj4881 < yyrr4881; yyj4881++ { - yyh4881.ElemContainerState(yyj4881) - if r.TryDecodeAsNil() { - yyv4881[yyj4881] = nil - } else { - yyv4882 := &yyv4881[yyj4881] - yym4883 := z.DecBinary() - _ = yym4883 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4882) { - } else { - z.DecFallback(yyv4882, true) - } - } - - } - if yyrt4881 { - for ; yyj4881 < yyl4881; yyj4881++ { - yyv4881 = append(yyv4881, nil) - yyh4881.ElemContainerState(yyj4881) - if r.TryDecodeAsNil() { - yyv4881[yyj4881] = nil - } else { - yyv4884 := &yyv4881[yyj4881] - yym4885 := z.DecBinary() - _ = yym4885 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4884) { - } else { - z.DecFallback(yyv4884, true) - } - } - - } - } - - } else { - yyj4881 := 0 - for ; !r.CheckBreak(); yyj4881++ { - - if yyj4881 >= len(yyv4881) { - yyv4881 = append(yyv4881, nil) // var yyz4881 pkg7_runtime.Object - yyc4881 = true - } - yyh4881.ElemContainerState(yyj4881) - if yyj4881 < len(yyv4881) { - if r.TryDecodeAsNil() { - yyv4881[yyj4881] = nil - } else { - yyv4886 := &yyv4881[yyj4881] - yym4887 := z.DecBinary() - _ = yym4887 - if false { - } else if z.HasExtensions() && z.DecExt(yyv4886) { - } else { - z.DecFallback(yyv4886, true) - } - } - - } else { - z.DecSwallow() - } - - } - if yyj4881 < len(yyv4881) { - yyv4881 = yyv4881[:yyj4881] - yyc4881 = true - } else if yyj4881 == 0 && yyv4881 == nil { - yyv4881 = []pkg7_runtime.Object{} - yyc4881 = true - } - } - yyh4881.End() - if yyc4881 { - *v = yyv4881 - } -} - -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 _, yyv4888 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4889 := &yyv4888 - yy4889.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 - - yyv4890 := *v - yyh4890, yyl4890 := z.DecSliceHelperStart() - var yyc4890 bool - if yyl4890 == 0 { - if yyv4890 == nil { - yyv4890 = []LimitRangeItem{} - yyc4890 = true - } else if len(yyv4890) != 0 { - yyv4890 = yyv4890[:0] - yyc4890 = true - } - } else if yyl4890 > 0 { - var yyrr4890, yyrl4890 int - var yyrt4890 bool - if yyl4890 > cap(yyv4890) { - - yyrg4890 := len(yyv4890) > 0 - yyv24890 := yyv4890 - yyrl4890, yyrt4890 = z.DecInferLen(yyl4890, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4890 { - if yyrl4890 <= cap(yyv4890) { - yyv4890 = yyv4890[:yyrl4890] - } else { - yyv4890 = make([]LimitRangeItem, yyrl4890) - } - } else { - yyv4890 = make([]LimitRangeItem, yyrl4890) - } - yyc4890 = true - yyrr4890 = len(yyv4890) - if yyrg4890 { - copy(yyv4890, yyv24890) - } - } else if yyl4890 != len(yyv4890) { - yyv4890 = yyv4890[:yyl4890] - yyc4890 = true - } - yyj4890 := 0 - for ; yyj4890 < yyrr4890; yyj4890++ { - yyh4890.ElemContainerState(yyj4890) - if r.TryDecodeAsNil() { - yyv4890[yyj4890] = LimitRangeItem{} - } else { - yyv4891 := &yyv4890[yyj4890] - yyv4891.CodecDecodeSelf(d) - } - - } - if yyrt4890 { - for ; yyj4890 < yyl4890; yyj4890++ { - yyv4890 = append(yyv4890, LimitRangeItem{}) - yyh4890.ElemContainerState(yyj4890) - if r.TryDecodeAsNil() { - yyv4890[yyj4890] = LimitRangeItem{} - } else { - yyv4892 := &yyv4890[yyj4890] - yyv4892.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4890 := 0 - for ; !r.CheckBreak(); yyj4890++ { - - if yyj4890 >= len(yyv4890) { - yyv4890 = append(yyv4890, LimitRangeItem{}) // var yyz4890 LimitRangeItem - yyc4890 = true - } - yyh4890.ElemContainerState(yyj4890) - if yyj4890 < len(yyv4890) { - if r.TryDecodeAsNil() { - yyv4890[yyj4890] = LimitRangeItem{} - } else { - yyv4893 := &yyv4890[yyj4890] - yyv4893.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4890 < len(yyv4890) { - yyv4890 = yyv4890[:yyj4890] - yyc4890 = true - } else if yyj4890 == 0 && yyv4890 == nil { - yyv4890 = []LimitRangeItem{} - yyc4890 = true - } - } - yyh4890.End() - if yyc4890 { - *v = yyv4890 - } -} - -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 _, yyv4894 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4895 := &yyv4894 - yy4895.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 - - yyv4896 := *v - yyh4896, yyl4896 := z.DecSliceHelperStart() - var yyc4896 bool - if yyl4896 == 0 { - if yyv4896 == nil { - yyv4896 = []LimitRange{} - yyc4896 = true - } else if len(yyv4896) != 0 { - yyv4896 = yyv4896[:0] - yyc4896 = true - } - } else if yyl4896 > 0 { - var yyrr4896, yyrl4896 int - var yyrt4896 bool - if yyl4896 > cap(yyv4896) { - - yyrg4896 := len(yyv4896) > 0 - yyv24896 := yyv4896 - yyrl4896, yyrt4896 = z.DecInferLen(yyl4896, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4896 { - if yyrl4896 <= cap(yyv4896) { - yyv4896 = yyv4896[:yyrl4896] - } else { - yyv4896 = make([]LimitRange, yyrl4896) - } - } else { - yyv4896 = make([]LimitRange, yyrl4896) - } - yyc4896 = true - yyrr4896 = len(yyv4896) - if yyrg4896 { - copy(yyv4896, yyv24896) - } - } else if yyl4896 != len(yyv4896) { - yyv4896 = yyv4896[:yyl4896] - yyc4896 = true - } - yyj4896 := 0 - for ; yyj4896 < yyrr4896; yyj4896++ { - yyh4896.ElemContainerState(yyj4896) - if r.TryDecodeAsNil() { - yyv4896[yyj4896] = LimitRange{} - } else { - yyv4897 := &yyv4896[yyj4896] - yyv4897.CodecDecodeSelf(d) - } - - } - if yyrt4896 { - for ; yyj4896 < yyl4896; yyj4896++ { - yyv4896 = append(yyv4896, LimitRange{}) - yyh4896.ElemContainerState(yyj4896) - if r.TryDecodeAsNil() { - yyv4896[yyj4896] = LimitRange{} - } else { - yyv4898 := &yyv4896[yyj4896] - yyv4898.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4896 := 0 - for ; !r.CheckBreak(); yyj4896++ { - - if yyj4896 >= len(yyv4896) { - yyv4896 = append(yyv4896, LimitRange{}) // var yyz4896 LimitRange - yyc4896 = true - } - yyh4896.ElemContainerState(yyj4896) - if yyj4896 < len(yyv4896) { - if r.TryDecodeAsNil() { - yyv4896[yyj4896] = LimitRange{} - } else { - yyv4899 := &yyv4896[yyj4896] - yyv4899.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4896 < len(yyv4896) { - yyv4896 = yyv4896[:yyj4896] - yyc4896 = true - } else if yyj4896 == 0 && yyv4896 == nil { - yyv4896 = []LimitRange{} - yyc4896 = true - } - } - yyh4896.End() - if yyc4896 { - *v = yyv4896 - } -} - -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 _, yyv4900 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4900.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 - - yyv4901 := *v - yyh4901, yyl4901 := z.DecSliceHelperStart() - var yyc4901 bool - if yyl4901 == 0 { - if yyv4901 == nil { - yyv4901 = []ResourceQuotaScope{} - yyc4901 = true - } else if len(yyv4901) != 0 { - yyv4901 = yyv4901[:0] - yyc4901 = true - } - } else if yyl4901 > 0 { - var yyrr4901, yyrl4901 int - var yyrt4901 bool - if yyl4901 > cap(yyv4901) { - - yyrl4901, yyrt4901 = z.DecInferLen(yyl4901, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4901 { - if yyrl4901 <= cap(yyv4901) { - yyv4901 = yyv4901[:yyrl4901] - } else { - yyv4901 = make([]ResourceQuotaScope, yyrl4901) - } - } else { - yyv4901 = make([]ResourceQuotaScope, yyrl4901) - } - yyc4901 = true - yyrr4901 = len(yyv4901) - } else if yyl4901 != len(yyv4901) { - yyv4901 = yyv4901[:yyl4901] - yyc4901 = true - } - yyj4901 := 0 - for ; yyj4901 < yyrr4901; yyj4901++ { - yyh4901.ElemContainerState(yyj4901) - if r.TryDecodeAsNil() { - yyv4901[yyj4901] = "" - } else { - yyv4901[yyj4901] = ResourceQuotaScope(r.DecodeString()) - } - - } - if yyrt4901 { - for ; yyj4901 < yyl4901; yyj4901++ { - yyv4901 = append(yyv4901, "") - yyh4901.ElemContainerState(yyj4901) - if r.TryDecodeAsNil() { - yyv4901[yyj4901] = "" - } else { - yyv4901[yyj4901] = ResourceQuotaScope(r.DecodeString()) - } - - } - } - - } else { - yyj4901 := 0 - for ; !r.CheckBreak(); yyj4901++ { - - if yyj4901 >= len(yyv4901) { - yyv4901 = append(yyv4901, "") // var yyz4901 ResourceQuotaScope - yyc4901 = true - } - yyh4901.ElemContainerState(yyj4901) - if yyj4901 < len(yyv4901) { - if r.TryDecodeAsNil() { - yyv4901[yyj4901] = "" - } else { - yyv4901[yyj4901] = ResourceQuotaScope(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj4901 < len(yyv4901) { - yyv4901 = yyv4901[:yyj4901] - yyc4901 = true - } else if yyj4901 == 0 && yyv4901 == nil { - yyv4901 = []ResourceQuotaScope{} - yyc4901 = true - } - } - yyh4901.End() - if yyc4901 { - *v = yyv4901 - } -} - -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 _, yyv4905 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4906 := &yyv4905 - yy4906.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 - - yyv4907 := *v - yyh4907, yyl4907 := z.DecSliceHelperStart() - var yyc4907 bool - if yyl4907 == 0 { - if yyv4907 == nil { - yyv4907 = []ResourceQuota{} - yyc4907 = true - } else if len(yyv4907) != 0 { - yyv4907 = yyv4907[:0] - yyc4907 = true - } - } else if yyl4907 > 0 { - var yyrr4907, yyrl4907 int - var yyrt4907 bool - if yyl4907 > cap(yyv4907) { - - yyrg4907 := len(yyv4907) > 0 - yyv24907 := yyv4907 - yyrl4907, yyrt4907 = z.DecInferLen(yyl4907, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4907 { - if yyrl4907 <= cap(yyv4907) { - yyv4907 = yyv4907[:yyrl4907] - } else { - yyv4907 = make([]ResourceQuota, yyrl4907) - } - } else { - yyv4907 = make([]ResourceQuota, yyrl4907) - } - yyc4907 = true - yyrr4907 = len(yyv4907) - if yyrg4907 { - copy(yyv4907, yyv24907) - } - } else if yyl4907 != len(yyv4907) { - yyv4907 = yyv4907[:yyl4907] - yyc4907 = true - } - yyj4907 := 0 - for ; yyj4907 < yyrr4907; yyj4907++ { - yyh4907.ElemContainerState(yyj4907) - if r.TryDecodeAsNil() { - yyv4907[yyj4907] = ResourceQuota{} - } else { - yyv4908 := &yyv4907[yyj4907] - yyv4908.CodecDecodeSelf(d) - } - - } - if yyrt4907 { - for ; yyj4907 < yyl4907; yyj4907++ { - yyv4907 = append(yyv4907, ResourceQuota{}) - yyh4907.ElemContainerState(yyj4907) - if r.TryDecodeAsNil() { - yyv4907[yyj4907] = ResourceQuota{} - } else { - yyv4909 := &yyv4907[yyj4907] - yyv4909.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4907 := 0 - for ; !r.CheckBreak(); yyj4907++ { - - if yyj4907 >= len(yyv4907) { - yyv4907 = append(yyv4907, ResourceQuota{}) // var yyz4907 ResourceQuota - yyc4907 = true - } - yyh4907.ElemContainerState(yyj4907) - if yyj4907 < len(yyv4907) { - if r.TryDecodeAsNil() { - yyv4907[yyj4907] = ResourceQuota{} - } else { - yyv4910 := &yyv4907[yyj4907] - yyv4910.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4907 < len(yyv4907) { - yyv4907 = yyv4907[:yyj4907] - yyc4907 = true - } else if yyj4907 == 0 && yyv4907 == nil { - yyv4907 = []ResourceQuota{} - yyc4907 = true - } - } - yyh4907.End() - if yyc4907 { - *v = yyv4907 - } -} - -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 yyk4911, yyv4911 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym4912 := z.EncBinary() - _ = yym4912 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk4911)) - } - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv4911 == nil { - r.EncodeNil() - } else { - yym4913 := z.EncBinary() - _ = yym4913 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(yyv4911)) - } - } - } - 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 - - yyv4914 := *v - yyl4914 := r.ReadMapStart() - yybh4914 := z.DecBasicHandle() - if yyv4914 == nil { - yyrl4914, _ := z.DecInferLen(yyl4914, yybh4914.MaxInitLen, 40) - yyv4914 = make(map[string][]uint8, yyrl4914) - *v = yyv4914 - } - var yymk4914 string - var yymv4914 []uint8 - var yymg4914 bool - if yybh4914.MapValueReset { - yymg4914 = true - } - if yyl4914 > 0 { - for yyj4914 := 0; yyj4914 < yyl4914; yyj4914++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4914 = "" - } else { - yymk4914 = string(r.DecodeString()) - } - - if yymg4914 { - yymv4914 = yyv4914[yymk4914] - } else { - yymv4914 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4914 = nil - } else { - yyv4916 := &yymv4914 - yym4917 := z.DecBinary() - _ = yym4917 - if false { - } else { - *yyv4916 = r.DecodeBytes(*(*[]byte)(yyv4916), false, false) - } - } - - if yyv4914 != nil { - yyv4914[yymk4914] = yymv4914 - } - } - } else if yyl4914 < 0 { - for yyj4914 := 0; !r.CheckBreak(); yyj4914++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk4914 = "" - } else { - yymk4914 = string(r.DecodeString()) - } - - if yymg4914 { - yymv4914 = yyv4914[yymk4914] - } else { - yymv4914 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv4914 = nil - } else { - yyv4919 := &yymv4914 - yym4920 := z.DecBinary() - _ = yym4920 - if false { - } else { - *yyv4919 = r.DecodeBytes(*(*[]byte)(yyv4919), false, false) - } - } - - if yyv4914 != nil { - yyv4914[yymk4914] = yymv4914 - } - } - } // 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 _, yyv4921 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4922 := &yyv4921 - yy4922.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 - - yyv4923 := *v - yyh4923, yyl4923 := z.DecSliceHelperStart() - var yyc4923 bool - if yyl4923 == 0 { - if yyv4923 == nil { - yyv4923 = []Secret{} - yyc4923 = true - } else if len(yyv4923) != 0 { - yyv4923 = yyv4923[:0] - yyc4923 = true - } - } else if yyl4923 > 0 { - var yyrr4923, yyrl4923 int - var yyrt4923 bool - if yyl4923 > cap(yyv4923) { - - yyrg4923 := len(yyv4923) > 0 - yyv24923 := yyv4923 - yyrl4923, yyrt4923 = z.DecInferLen(yyl4923, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4923 { - if yyrl4923 <= cap(yyv4923) { - yyv4923 = yyv4923[:yyrl4923] - } else { - yyv4923 = make([]Secret, yyrl4923) - } - } else { - yyv4923 = make([]Secret, yyrl4923) - } - yyc4923 = true - yyrr4923 = len(yyv4923) - if yyrg4923 { - copy(yyv4923, yyv24923) - } - } else if yyl4923 != len(yyv4923) { - yyv4923 = yyv4923[:yyl4923] - yyc4923 = true - } - yyj4923 := 0 - for ; yyj4923 < yyrr4923; yyj4923++ { - yyh4923.ElemContainerState(yyj4923) - if r.TryDecodeAsNil() { - yyv4923[yyj4923] = Secret{} - } else { - yyv4924 := &yyv4923[yyj4923] - yyv4924.CodecDecodeSelf(d) - } - - } - if yyrt4923 { - for ; yyj4923 < yyl4923; yyj4923++ { - yyv4923 = append(yyv4923, Secret{}) - yyh4923.ElemContainerState(yyj4923) - if r.TryDecodeAsNil() { - yyv4923[yyj4923] = Secret{} - } else { - yyv4925 := &yyv4923[yyj4923] - yyv4925.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4923 := 0 - for ; !r.CheckBreak(); yyj4923++ { - - if yyj4923 >= len(yyv4923) { - yyv4923 = append(yyv4923, Secret{}) // var yyz4923 Secret - yyc4923 = true - } - yyh4923.ElemContainerState(yyj4923) - if yyj4923 < len(yyv4923) { - if r.TryDecodeAsNil() { - yyv4923[yyj4923] = Secret{} - } else { - yyv4926 := &yyv4923[yyj4923] - yyv4926.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4923 < len(yyv4923) { - yyv4923 = yyv4923[:yyj4923] - yyc4923 = true - } else if yyj4923 == 0 && yyv4923 == nil { - yyv4923 = []Secret{} - yyc4923 = true - } - } - yyh4923.End() - if yyc4923 { - *v = yyv4923 - } -} - -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 _, yyv4927 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4928 := &yyv4927 - yy4928.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 - - yyv4929 := *v - yyh4929, yyl4929 := z.DecSliceHelperStart() - var yyc4929 bool - if yyl4929 == 0 { - if yyv4929 == nil { - yyv4929 = []ConfigMap{} - yyc4929 = true - } else if len(yyv4929) != 0 { - yyv4929 = yyv4929[:0] - yyc4929 = true - } - } else if yyl4929 > 0 { - var yyrr4929, yyrl4929 int - var yyrt4929 bool - if yyl4929 > cap(yyv4929) { - - yyrg4929 := len(yyv4929) > 0 - yyv24929 := yyv4929 - yyrl4929, yyrt4929 = z.DecInferLen(yyl4929, z.DecBasicHandle().MaxInitLen, 264) - if yyrt4929 { - if yyrl4929 <= cap(yyv4929) { - yyv4929 = yyv4929[:yyrl4929] - } else { - yyv4929 = make([]ConfigMap, yyrl4929) - } - } else { - yyv4929 = make([]ConfigMap, yyrl4929) - } - yyc4929 = true - yyrr4929 = len(yyv4929) - if yyrg4929 { - copy(yyv4929, yyv24929) - } - } else if yyl4929 != len(yyv4929) { - yyv4929 = yyv4929[:yyl4929] - yyc4929 = true - } - yyj4929 := 0 - for ; yyj4929 < yyrr4929; yyj4929++ { - yyh4929.ElemContainerState(yyj4929) - if r.TryDecodeAsNil() { - yyv4929[yyj4929] = ConfigMap{} - } else { - yyv4930 := &yyv4929[yyj4929] - yyv4930.CodecDecodeSelf(d) - } - - } - if yyrt4929 { - for ; yyj4929 < yyl4929; yyj4929++ { - yyv4929 = append(yyv4929, ConfigMap{}) - yyh4929.ElemContainerState(yyj4929) - if r.TryDecodeAsNil() { - yyv4929[yyj4929] = ConfigMap{} - } else { - yyv4931 := &yyv4929[yyj4929] - yyv4931.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4929 := 0 - for ; !r.CheckBreak(); yyj4929++ { - - if yyj4929 >= len(yyv4929) { - yyv4929 = append(yyv4929, ConfigMap{}) // var yyz4929 ConfigMap - yyc4929 = true - } - yyh4929.ElemContainerState(yyj4929) - if yyj4929 < len(yyv4929) { - if r.TryDecodeAsNil() { - yyv4929[yyj4929] = ConfigMap{} - } else { - yyv4932 := &yyv4929[yyj4929] - yyv4932.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4929 < len(yyv4929) { - yyv4929 = yyv4929[:yyj4929] - yyc4929 = true - } else if yyj4929 == 0 && yyv4929 == nil { - yyv4929 = []ConfigMap{} - yyc4929 = true - } - } - yyh4929.End() - if yyc4929 { - *v = yyv4929 - } -} - -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 _, yyv4933 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4934 := &yyv4933 - yy4934.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 - - yyv4935 := *v - yyh4935, yyl4935 := z.DecSliceHelperStart() - var yyc4935 bool - if yyl4935 == 0 { - if yyv4935 == nil { - yyv4935 = []ComponentCondition{} - yyc4935 = true - } else if len(yyv4935) != 0 { - yyv4935 = yyv4935[:0] - yyc4935 = true - } - } else if yyl4935 > 0 { - var yyrr4935, yyrl4935 int - var yyrt4935 bool - if yyl4935 > cap(yyv4935) { - - yyrg4935 := len(yyv4935) > 0 - yyv24935 := yyv4935 - yyrl4935, yyrt4935 = z.DecInferLen(yyl4935, z.DecBasicHandle().MaxInitLen, 64) - if yyrt4935 { - if yyrl4935 <= cap(yyv4935) { - yyv4935 = yyv4935[:yyrl4935] - } else { - yyv4935 = make([]ComponentCondition, yyrl4935) - } - } else { - yyv4935 = make([]ComponentCondition, yyrl4935) - } - yyc4935 = true - yyrr4935 = len(yyv4935) - if yyrg4935 { - copy(yyv4935, yyv24935) - } - } else if yyl4935 != len(yyv4935) { - yyv4935 = yyv4935[:yyl4935] - yyc4935 = true - } - yyj4935 := 0 - for ; yyj4935 < yyrr4935; yyj4935++ { - yyh4935.ElemContainerState(yyj4935) - if r.TryDecodeAsNil() { - yyv4935[yyj4935] = ComponentCondition{} - } else { - yyv4936 := &yyv4935[yyj4935] - yyv4936.CodecDecodeSelf(d) - } - - } - if yyrt4935 { - for ; yyj4935 < yyl4935; yyj4935++ { - yyv4935 = append(yyv4935, ComponentCondition{}) - yyh4935.ElemContainerState(yyj4935) - if r.TryDecodeAsNil() { - yyv4935[yyj4935] = ComponentCondition{} - } else { - yyv4937 := &yyv4935[yyj4935] - yyv4937.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4935 := 0 - for ; !r.CheckBreak(); yyj4935++ { - - if yyj4935 >= len(yyv4935) { - yyv4935 = append(yyv4935, ComponentCondition{}) // var yyz4935 ComponentCondition - yyc4935 = true - } - yyh4935.ElemContainerState(yyj4935) - if yyj4935 < len(yyv4935) { - if r.TryDecodeAsNil() { - yyv4935[yyj4935] = ComponentCondition{} - } else { - yyv4938 := &yyv4935[yyj4935] - yyv4938.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4935 < len(yyv4935) { - yyv4935 = yyv4935[:yyj4935] - yyc4935 = true - } else if yyj4935 == 0 && yyv4935 == nil { - yyv4935 = []ComponentCondition{} - yyc4935 = true - } - } - yyh4935.End() - if yyc4935 { - *v = yyv4935 - } -} - -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 _, yyv4939 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4940 := &yyv4939 - yy4940.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 - - yyv4941 := *v - yyh4941, yyl4941 := z.DecSliceHelperStart() - var yyc4941 bool - if yyl4941 == 0 { - if yyv4941 == nil { - yyv4941 = []ComponentStatus{} - yyc4941 = true - } else if len(yyv4941) != 0 { - yyv4941 = yyv4941[:0] - yyc4941 = true - } - } else if yyl4941 > 0 { - var yyrr4941, yyrl4941 int - var yyrt4941 bool - if yyl4941 > cap(yyv4941) { - - yyrg4941 := len(yyv4941) > 0 - yyv24941 := yyv4941 - yyrl4941, yyrt4941 = z.DecInferLen(yyl4941, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4941 { - if yyrl4941 <= cap(yyv4941) { - yyv4941 = yyv4941[:yyrl4941] - } else { - yyv4941 = make([]ComponentStatus, yyrl4941) - } - } else { - yyv4941 = make([]ComponentStatus, yyrl4941) - } - yyc4941 = true - yyrr4941 = len(yyv4941) - if yyrg4941 { - copy(yyv4941, yyv24941) - } - } else if yyl4941 != len(yyv4941) { - yyv4941 = yyv4941[:yyl4941] - yyc4941 = true - } - yyj4941 := 0 - for ; yyj4941 < yyrr4941; yyj4941++ { - yyh4941.ElemContainerState(yyj4941) - if r.TryDecodeAsNil() { - yyv4941[yyj4941] = ComponentStatus{} - } else { - yyv4942 := &yyv4941[yyj4941] - yyv4942.CodecDecodeSelf(d) - } - - } - if yyrt4941 { - for ; yyj4941 < yyl4941; yyj4941++ { - yyv4941 = append(yyv4941, ComponentStatus{}) - yyh4941.ElemContainerState(yyj4941) - if r.TryDecodeAsNil() { - yyv4941[yyj4941] = ComponentStatus{} - } else { - yyv4943 := &yyv4941[yyj4941] - yyv4943.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj4941 := 0 - for ; !r.CheckBreak(); yyj4941++ { - - if yyj4941 >= len(yyv4941) { - yyv4941 = append(yyv4941, ComponentStatus{}) // var yyz4941 ComponentStatus - yyc4941 = true - } - yyh4941.ElemContainerState(yyj4941) - if yyj4941 < len(yyv4941) { - if r.TryDecodeAsNil() { - yyv4941[yyj4941] = ComponentStatus{} - } else { - yyv4944 := &yyv4941[yyj4941] - yyv4944.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj4941 < len(yyv4941) { - yyv4941 = yyv4941[:yyj4941] - yyc4941 = true - } else if yyj4941 == 0 && yyv4941 == nil { - yyv4941 = []ComponentStatus{} - yyc4941 = true - } - } - yyh4941.End() - if yyc4941 { - *v = yyv4941 - } -} diff --git a/vendor/k8s.io/client-go/pkg/api/types.go b/vendor/k8s.io/client-go/pkg/api/types.go index a4eaeb9d5a..b59f7202e4 100644 --- a/vendor/k8s.io/client-go/pkg/api/types.go +++ b/vendor/k8s.io/client-go/pkg/api/types.go @@ -17,13 +17,13 @@ limitations under the License. package api import ( - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/types" - "k8s.io/client-go/pkg/util/intstr" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/util/intstr" ) // Common string formats @@ -57,13 +57,14 @@ import ( // ObjectMeta is metadata that all persisted resources must have, which includes all objects // users must create. +// DEPRECATED: Use k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta instead - this type will be removed soon. type ObjectMeta struct { // Name is unique within a namespace. Name is required when creating resources, although // some resources may allow a client to request the generation of an appropriate name // automatically. Name is primarily intended for creation idempotence and configuration // definition. // +optional - Name string `json:"name,omitempty"` + Name string // GenerateName indicates that the name should be made unique by the server prior to persisting // it. A non-empty value for the field indicates the name will be made unique (and the name @@ -77,42 +78,42 @@ type ObjectMeta struct { // ServerTimeout indicating a unique name could not be found in the time allotted, and the client // should retry (optionally after the time indicated in the Retry-After header). // +optional - GenerateName string `json:"generateName,omitempty"` + GenerateName string // Namespace defines the space within which name must be unique. An empty namespace is // equivalent to the "default" namespace, but "default" is the canonical representation. // Not all objects are required to be scoped to a namespace - the value of this field for // those objects will be empty. // +optional - Namespace string `json:"namespace,omitempty"` + Namespace string // SelfLink is a URL representing this object. // +optional - SelfLink string `json:"selfLink,omitempty"` + SelfLink string // UID is the unique in time and space value for this object. It is typically generated by // the server on successful creation of a resource and is not allowed to change on PUT // operations. // +optional - UID types.UID `json:"uid,omitempty"` + UID types.UID // An opaque value that represents the version of this resource. May be used for optimistic // concurrency, change detection, and the watch operation on a resource or set of resources. // Clients must treat these values as opaque and values may only be valid for a particular // resource or set of resources. Only servers will generate resource versions. // +optional - ResourceVersion string `json:"resourceVersion,omitempty"` + ResourceVersion string // A sequence number representing a specific generation of the desired state. // Populated by the system. Read-only. // +optional - Generation int64 `json:"generation,omitempty"` + Generation int64 // CreationTimestamp is a timestamp representing the server time when this object was // created. It is not guaranteed to be set in happens-before order across separate operations. // Clients may not set this value. It is represented in RFC3339 form and is in UTC. // +optional - CreationTimestamp unversioned.Time `json:"creationTimestamp,omitempty"` + CreationTimestamp metav1.Time // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This // field is set by the server when a graceful deletion is requested by the user, and is not @@ -130,14 +131,14 @@ type ObjectMeta struct { // // Populated by the system when a graceful deletion is requested. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - DeletionTimestamp *unversioned.Time `json:"deletionTimestamp,omitempty"` + DeletionTimestamp *metav1.Time // DeletionGracePeriodSeconds records the graceful deletion value set when graceful deletion // was requested. Represents the most recent grace period, and may only be shortened once set. // +optional - DeletionGracePeriodSeconds *int64 `json:"deletionGracePeriodSeconds,omitempty"` + DeletionGracePeriodSeconds *int64 // Labels are key value pairs that may be used to scope and select individual resources. // Label keys are of the form: @@ -149,34 +150,45 @@ type ObjectMeta struct { // to the user. Other system components that wish to use labels must specify a prefix. The // "kubernetes.io/" prefix is reserved for use by kubernetes components. // +optional - Labels map[string]string `json:"labels,omitempty"` + Labels map[string]string // Annotations are unstructured key value data stored with a resource that may be set by // external tooling. They are not queryable and should be preserved when modifying // objects. Annotation keys have the same formatting restrictions as Label keys. See the // comments on Labels for details. // +optional - Annotations map[string]string `json:"annotations,omitempty"` + Annotations map[string]string // List of objects depended by this object. If ALL objects in the list have // been deleted, this object will be garbage collected. If this object is managed by a controller, // then an entry in this list will point to this controller, with the controller field set to true. // There cannot be more than one managing controller. // +optional - OwnerReferences []OwnerReference `json:"ownerReferences,omitempty"` + OwnerReferences []metav1.OwnerReference + + // An initializer is a controller which enforces some system invariant at object creation time. + // This field is a list of initializers that have not yet acted on this object. If nil or empty, + // this object has been completely initialized. Otherwise, the object is considered uninitialized + // and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to + // observe uninitialized objects. + // + // When an object is created, the system will populate this list with the current set of initializers. + // Only privileged users may set or modify this list. Once it is empty, it may not be modified further + // by any user. + Initializers *metav1.Initializers // Must be empty before the object is deleted from the registry. Each entry // is an identifier for the responsible component that will remove the entry // from the list. If the deletionTimestamp of the object is non-nil, entries // in this list can only be removed. // +optional - Finalizers []string `json:"finalizers,omitempty"` + Finalizers []string // The name of the cluster which the object belongs to. // This is used to distinguish resources with same name and namespace in different clusters. // This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request. // +optional - ClusterName string `json:"clusterName,omitempty"` + ClusterName string } const ( @@ -188,6 +200,8 @@ const ( NamespaceNone string = "" // NamespaceSystem is the system namespace where we place system components. NamespaceSystem string = "kube-system" + // NamespacePublic is the namespace where we place public info (ConfigMaps) + NamespacePublic string = "kube-public" // TerminationMessagePathDefault means the default path to capture the application termination message running in a container TerminationMessagePathDefault string = "/dev/termination-log" ) @@ -196,12 +210,12 @@ const ( type Volume struct { // Required: This must be a DNS_LABEL. Each volume in a pod must have // a unique name. - Name string `json:"name"` + Name string // The VolumeSource represents the location and type of a volume to mount. // This is optional for now. If not specified, the Volume is implied to be an EmptyDir. // This implied behavior is deprecated and will be removed in a future version. // +optional - VolumeSource `json:",inline,omitempty"` + VolumeSource } // VolumeSource represents the source location of a volume to mount. @@ -215,82 +229,93 @@ type VolumeSource struct { // TODO(jonesdl) We need to restrict who can use host directory mounts and who can/can not // mount host directories as read/write. // +optional - HostPath *HostPathVolumeSource `json:"hostPath,omitempty"` + HostPath *HostPathVolumeSource // EmptyDir represents a temporary directory that shares a pod's lifetime. // +optional - EmptyDir *EmptyDirVolumeSource `json:"emptyDir,omitempty"` + EmptyDir *EmptyDirVolumeSource // GCEPersistentDisk represents a GCE Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. // +optional - GCEPersistentDisk *GCEPersistentDiskVolumeSource `json:"gcePersistentDisk,omitempty"` + GCEPersistentDisk *GCEPersistentDiskVolumeSource // AWSElasticBlockStore represents an AWS EBS disk that is attached to a // kubelet's host machine and then exposed to the pod. // +optional - AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource `json:"awsElasticBlockStore,omitempty"` + AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource // GitRepo represents a git repository at a particular revision. // +optional - GitRepo *GitRepoVolumeSource `json:"gitRepo,omitempty"` + GitRepo *GitRepoVolumeSource // Secret represents a secret that should populate this volume. // +optional - Secret *SecretVolumeSource `json:"secret,omitempty"` + Secret *SecretVolumeSource // NFS represents an NFS mount on the host that shares a pod's lifetime // +optional - NFS *NFSVolumeSource `json:"nfs,omitempty"` + NFS *NFSVolumeSource // ISCSIVolumeSource represents an ISCSI Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. // +optional - ISCSI *ISCSIVolumeSource `json:"iscsi,omitempty"` + ISCSI *ISCSIVolumeSource // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime // +optional - Glusterfs *GlusterfsVolumeSource `json:"glusterfs,omitempty"` + Glusterfs *GlusterfsVolumeSource // PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace // +optional - PersistentVolumeClaim *PersistentVolumeClaimVolumeSource `json:"persistentVolumeClaim,omitempty"` + PersistentVolumeClaim *PersistentVolumeClaimVolumeSource // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime // +optional - RBD *RBDVolumeSource `json:"rbd,omitempty"` + RBD *RBDVolumeSource // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime // +optional - Quobyte *QuobyteVolumeSource `json:"quobyte,omitempty"` + Quobyte *QuobyteVolumeSource // FlexVolume represents a generic volume resource that is // provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. // +optional - FlexVolume *FlexVolumeSource `json:"flexVolume,omitempty"` + FlexVolume *FlexVolumeSource // Cinder represents a cinder volume attached and mounted on kubelets host machine // +optional - Cinder *CinderVolumeSource `json:"cinder,omitempty"` + Cinder *CinderVolumeSource // CephFS represents a Cephfs mount on the host that shares a pod's lifetime // +optional - CephFS *CephFSVolumeSource `json:"cephfs,omitempty"` + CephFS *CephFSVolumeSource // Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running // +optional - Flocker *FlockerVolumeSource `json:"flocker,omitempty"` + Flocker *FlockerVolumeSource // DownwardAPI represents metadata about the pod that should populate this volume // +optional - DownwardAPI *DownwardAPIVolumeSource `json:"downwardAPI,omitempty"` + DownwardAPI *DownwardAPIVolumeSource // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod. // +optional - FC *FCVolumeSource `json:"fc,omitempty"` + FC *FCVolumeSource // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. // +optional - AzureFile *AzureFileVolumeSource `json:"azureFile,omitempty"` + AzureFile *AzureFileVolumeSource // ConfigMap represents a configMap that should populate this volume // +optional - ConfigMap *ConfigMapVolumeSource `json:"configMap,omitempty"` + ConfigMap *ConfigMapVolumeSource // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine // +optional - VsphereVolume *VsphereVirtualDiskVolumeSource `json:"vsphereVolume,omitempty"` + VsphereVolume *VsphereVirtualDiskVolumeSource // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. // +optional - AzureDisk *AzureDiskVolumeSource `json:"azureDisk,omitempty"` + AzureDisk *AzureDiskVolumeSource // PhotonPersistentDisk represents a Photon Controller persistent disk attached and mounted on kubelets host machine - PhotonPersistentDisk *PhotonPersistentDiskVolumeSource `json:"photonPersistentDisk,omitempty"` + PhotonPersistentDisk *PhotonPersistentDiskVolumeSource + // Items for all in one resources secrets, configmaps, and downward API + Projected *ProjectedVolumeSource + // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine + // +optional + PortworxVolume *PortworxVolumeSource + // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. + // +optional + ScaleIO *ScaleIOVolumeSource + // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod + // +optional + StorageOS *StorageOSVolumeSource } // Similar to VolumeSource but meant for the administrator who creates PVs. @@ -299,106 +324,136 @@ type PersistentVolumeSource struct { // GCEPersistentDisk represents a GCE Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. // +optional - GCEPersistentDisk *GCEPersistentDiskVolumeSource `json:"gcePersistentDisk,omitempty"` + GCEPersistentDisk *GCEPersistentDiskVolumeSource // AWSElasticBlockStore represents an AWS EBS disk that is attached to a // kubelet's host machine and then exposed to the pod. // +optional - AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource `json:"awsElasticBlockStore,omitempty"` + AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource // HostPath represents a directory on the host. // Provisioned by a developer or tester. // This is useful for single-node development and testing only! // On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. // +optional - HostPath *HostPathVolumeSource `json:"hostPath,omitempty"` + HostPath *HostPathVolumeSource // Glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod // +optional - Glusterfs *GlusterfsVolumeSource `json:"glusterfs,omitempty"` + Glusterfs *GlusterfsVolumeSource // NFS represents an NFS mount on the host that shares a pod's lifetime // +optional - NFS *NFSVolumeSource `json:"nfs,omitempty"` + NFS *NFSVolumeSource // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime // +optional - RBD *RBDVolumeSource `json:"rbd,omitempty"` + RBD *RBDVolumeSource // Quobyte represents a Quobyte mount on the host that shares a pod's lifetime // +optional - Quobyte *QuobyteVolumeSource `json:"quobyte,omitempty"` + Quobyte *QuobyteVolumeSource // ISCSIVolumeSource represents an ISCSI resource that is attached to a // kubelet's host machine and then exposed to the pod. // +optional - ISCSI *ISCSIVolumeSource `json:"iscsi,omitempty"` + ISCSI *ISCSIVolumeSource // FlexVolume represents a generic volume resource that is // provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. // +optional - FlexVolume *FlexVolumeSource `json:"flexVolume,omitempty"` + FlexVolume *FlexVolumeSource // Cinder represents a cinder volume attached and mounted on kubelets host machine // +optional - Cinder *CinderVolumeSource `json:"cinder,omitempty"` + Cinder *CinderVolumeSource // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime // +optional - CephFS *CephFSVolumeSource `json:"cephfs,omitempty"` + CephFS *CephFSVolumeSource // FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod. // +optional - FC *FCVolumeSource `json:"fc,omitempty"` + FC *FCVolumeSource // Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running // +optional - Flocker *FlockerVolumeSource `json:"flocker,omitempty"` + Flocker *FlockerVolumeSource // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. // +optional - AzureFile *AzureFileVolumeSource `json:"azureFile,omitempty"` + AzureFile *AzureFileVolumeSource // VsphereVolume represents a vSphere volume attached and mounted on kubelets host machine // +optional - VsphereVolume *VsphereVirtualDiskVolumeSource `json:"vsphereVolume,omitempty"` + VsphereVolume *VsphereVirtualDiskVolumeSource // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. // +optional - AzureDisk *AzureDiskVolumeSource `json:"azureDisk,omitempty"` + AzureDisk *AzureDiskVolumeSource // PhotonPersistentDisk represents a Photon Controller persistent disk attached and mounted on kubelets host machine - PhotonPersistentDisk *PhotonPersistentDiskVolumeSource `json:"photonPersistentDisk,omitempty"` + PhotonPersistentDisk *PhotonPersistentDiskVolumeSource + // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine + // +optional + PortworxVolume *PortworxVolumeSource + // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. + // +optional + ScaleIO *ScaleIOVolumeSource + // Local represents directly-attached storage with node affinity + // +optional + Local *LocalVolumeSource + // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md + // +optional + StorageOS *StorageOSPersistentVolumeSource } type PersistentVolumeClaimVolumeSource struct { // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume - ClaimName string `json:"claimName"` + ClaimName string // Optional: Defaults to false (read/write). ReadOnly here // will force the ReadOnly setting in VolumeMounts // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } +const ( + // BetaStorageClassAnnotation represents the beta/previous StorageClass annotation. + // It's currently still used and will be held for backwards compatibility + BetaStorageClassAnnotation = "volume.beta.kubernetes.io/storage-class" + + // MountOptionAnnotation defines mount option annotation used in PVs + MountOptionAnnotation = "volume.beta.kubernetes.io/mount-options" + + // AlphaStorageNodeAffinityAnnotation defines node affinity policies for a PersistentVolume. + // Value is a string of the json representation of type NodeAffinity + AlphaStorageNodeAffinityAnnotation = "volume.alpha.kubernetes.io/node-affinity" +) + // +genclient=true // +nonNamespaced=true type PersistentVolume struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta //Spec defines a persistent volume owned by the cluster // +optional - Spec PersistentVolumeSpec `json:"spec,omitempty"` + Spec PersistentVolumeSpec // Status represents the current information about persistent volume. // +optional - Status PersistentVolumeStatus `json:"status,omitempty"` + Status PersistentVolumeStatus } type PersistentVolumeSpec struct { // Resources represents the actual resources of the volume - Capacity ResourceList `json:"capacity"` + Capacity ResourceList // Source represents the location and type of a volume to mount. - PersistentVolumeSource `json:",inline"` + PersistentVolumeSource // AccessModes contains all ways the volume can be mounted // +optional - AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty"` + AccessModes []PersistentVolumeAccessMode // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. // ClaimRef is expected to be non-nil when bound. // claim.VolumeName is the authoritative bind between PV and PVC. // When set to non-nil value, PVC.Spec.Selector of the referenced PVC is // ignored, i.e. labels of this PV do not need to match PVC selector. // +optional - ClaimRef *ObjectReference `json:"claimRef,omitempty"` + ClaimRef *ObjectReference // Optional: what happens to a persistent volume when released from its claim. // +optional - PersistentVolumeReclaimPolicy PersistentVolumeReclaimPolicy `json:"persistentVolumeReclaimPolicy,omitempty"` + PersistentVolumeReclaimPolicy PersistentVolumeReclaimPolicy + // Name of StorageClass to which this persistent volume belongs. Empty value + // means that this volume does not belong to any StorageClass. + // +optional + StorageClassName string } // PersistentVolumeReclaimPolicy describes a policy for end-of-life maintenance of persistent volumes @@ -419,44 +474,44 @@ const ( type PersistentVolumeStatus struct { // Phase indicates if a volume is available, bound to a claim, or released by a claim // +optional - Phase PersistentVolumePhase `json:"phase,omitempty"` + Phase PersistentVolumePhase // A human-readable message indicating details about why the volume is in this state. // +optional - Message string `json:"message,omitempty"` + Message string // Reason is a brief CamelCase string that describes any failure and is meant for machine parsing and tidy display in the CLI // +optional - Reason string `json:"reason,omitempty"` + Reason string } type PersistentVolumeList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` - Items []PersistentVolume `json:"items"` + metav1.ListMeta + Items []PersistentVolume } // +genclient=true // PersistentVolumeClaim is a user's request for and claim to a persistent volume type PersistentVolumeClaim struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the volume requested by a pod author // +optional - Spec PersistentVolumeClaimSpec `json:"spec,omitempty"` + Spec PersistentVolumeClaimSpec // Status represents the current information about a claim // +optional - Status PersistentVolumeClaimStatus `json:"status,omitempty"` + Status PersistentVolumeClaimStatus } type PersistentVolumeClaimList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` - Items []PersistentVolumeClaim `json:"items"` + metav1.ListMeta + Items []PersistentVolumeClaim } // PersistentVolumeClaimSpec describes the common attributes of storage devices @@ -464,30 +519,34 @@ type PersistentVolumeClaimList struct { type PersistentVolumeClaimSpec struct { // Contains the types of access modes required // +optional - AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty"` + AccessModes []PersistentVolumeAccessMode // A label query over volumes to consider for binding. This selector is // ignored when VolumeName is set // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector // Resources represents the minimum resources required // +optional - Resources ResourceRequirements `json:"resources,omitempty"` + Resources ResourceRequirements // VolumeName is the binding reference to the PersistentVolume backing this // claim. When set to non-empty value Selector is not evaluated // +optional - VolumeName string `json:"volumeName,omitempty"` + VolumeName string + // Name of the StorageClass required by the claim. + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes/#class-1 + // +optional + StorageClassName *string } type PersistentVolumeClaimStatus struct { // Phase represents the current phase of PersistentVolumeClaim // +optional - Phase PersistentVolumeClaimPhase `json:"phase,omitempty"` + Phase PersistentVolumeClaimPhase // AccessModes contains all ways the volume backing the PVC can be mounted // +optional - AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty"` + AccessModes []PersistentVolumeAccessMode // Represents the actual resources of the underlying volume // +optional - Capacity ResourceList `json:"capacity,omitempty"` + Capacity ResourceList } type PersistentVolumeAccessMode string @@ -535,7 +594,7 @@ const ( // Represents a host path mapped into a pod. // Host path volumes do not support ownership management or SELinux relabeling. type HostPathVolumeSource struct { - Path string `json:"path"` + Path string } // Represents an empty directory for a pod. @@ -548,7 +607,15 @@ type EmptyDirVolumeSource struct { // Optional: what type of storage medium should back this directory. // The default is "" which means to use the node's default medium. // +optional - Medium StorageMedium `json:"medium,omitempty"` + Medium StorageMedium + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + SizeLimit resource.Quantity } // StorageMedium defines ways that storage can be allocated to a volume. @@ -577,22 +644,22 @@ const ( // PDs support ownership management and SELinux relabeling. type GCEPersistentDiskVolumeSource struct { // Unique name of the PD resource. Used to identify the disk in GCE - PDName string `json:"pdName"` + PDName string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: Partition on the disk to mount. // If omitted, kubelet will attempt to mount the device name. // Ex. For /dev/sda1, this field is "1", for /dev/sda, this field is 0 or empty. // +optional - Partition int32 `json:"partition,omitempty"` + Partition int32 // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents an ISCSI disk. @@ -602,26 +669,40 @@ type ISCSIVolumeSource struct { // Required: iSCSI target portal // the portal is either an IP or ip_addr:port if port is other than default (typically TCP ports 860 and 3260) // +optional - TargetPortal string `json:"targetPortal,omitempty"` + TargetPortal string // Required: target iSCSI Qualified Name // +optional - IQN string `json:"iqn,omitempty"` + IQN string // Required: iSCSI target lun number // +optional - Lun int32 `json:"lun,omitempty"` + Lun int32 // Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport. // +optional - ISCSIInterface string `json:"iscsiInterface,omitempty"` + ISCSIInterface string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool + // Optional: list of iSCSI target portal ips for high availability. + // the portal is either an IP or ip_addr:port if port is other than default (typically TCP ports 860 and 3260) + // +optional + Portals []string + // Optional: whether support iSCSI Discovery CHAP authentication + // +optional + DiscoveryCHAPAuth bool + // Optional: whether support iSCSI Session CHAP authentication + // +optional + SessionCHAPAuth bool + // Optional: CHAP secret for iSCSI target and initiator authentication. + // The secret is used if either DiscoveryCHAPAuth or SessionCHAPAuth is true + // +optional + SecretRef *LocalObjectReference } // Represents a Fibre Channel volume. @@ -629,45 +710,45 @@ type ISCSIVolumeSource struct { // Fibre Channel volumes support ownership management and SELinux relabeling. type FCVolumeSource struct { // Required: FC target worldwide names (WWNs) - TargetWWNs []string `json:"targetWWNs"` + TargetWWNs []string // Required: FC target lun number - Lun *int32 `json:"lun"` + Lun *int32 // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // FlexVolume represents a generic volume resource that is // provisioned/attached using an exec based plugin. This is an alpha feature and may change in future. type FlexVolumeSource struct { // Driver is the name of the driver to use for this volume. - Driver string `json:"driver"` + Driver string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". The default filesystem depends on FlexVolume script. // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: SecretRef is reference to the secret object containing // sensitive information to pass to the plugin scripts. This may be // empty if no secret object is specified. If the secret object // contains more than one secret, all secrets are passed to the plugin // scripts. // +optional - SecretRef *LocalObjectReference `json:"secretRef,omitempty"` + SecretRef *LocalObjectReference // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool // Optional: Extra driver options if any. // +optional - Options map[string]string `json:"options,omitempty"` + Options map[string]string } // Represents a Persistent Disk resource in AWS. @@ -678,22 +759,22 @@ type FlexVolumeSource struct { // ownership management and SELinux relabeling. type AWSElasticBlockStoreVolumeSource struct { // Unique id of the persistent disk resource. Used to identify the disk in AWS - VolumeID string `json:"volumeID"` + VolumeID string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: Partition on the disk to mount. // If omitted, kubelet will attempt to mount the device name. // Ex. For /dev/sda1, this field is "1", for /dev/sda, this field is 0 or empty. // +optional - Partition int32 `json:"partition,omitempty"` + Partition int32 // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a volume that is populated with the contents of a git repository. @@ -701,16 +782,16 @@ type AWSElasticBlockStoreVolumeSource struct { // Git repo volumes support SELinux relabeling. type GitRepoVolumeSource struct { // Repository URL - Repository string `json:"repository"` + Repository string // Commit hash, this is optional // +optional - Revision string `json:"revision,omitempty"` + Revision string // Clone target, this is optional // Must not contain or start with '..'. If '.' is supplied, the volume directory will be the // git repository. Otherwise, if specified, the volume will contain the git repository in // the subdirectory with the given name. // +optional - Directory string `json:"directory,omitempty"` + Directory string // TODO: Consider credentials here. } @@ -722,38 +803,63 @@ type GitRepoVolumeSource struct { type SecretVolumeSource struct { // Name of the secret in the pod's namespace to use. // +optional - SecretName string `json:"secretName,omitempty"` + SecretName string // If unspecified, each key-value pair in the Data field of the referenced // Secret will be projected into the volume as a file whose name is the // key and content is the value. If specified, the listed keys will be // projected into the specified paths, and unlisted keys will not be // present. If a key is specified which is not present in the Secret, - // the volume setup will error. Paths must be relative and may not contain - // the '..' path or start with '..'. + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. // +optional - Items []KeyToPath `json:"items,omitempty"` + Items []KeyToPath // Mode bits to use on created files by default. Must be a value between // 0 and 0777. // Directories within the path are not affected by this setting. // This might be in conflict with other options that affect the file // mode, like fsGroup, and the result can be other mode bits set. // +optional - DefaultMode *int32 `json:"defaultMode,omitempty"` + DefaultMode *int32 + // Specify whether the Secret or its key must be defined + // +optional + Optional *bool +} + +// Adapts a secret into a projected volume. +// +// The contents of the target Secret's Data field will be presented in a +// projected volume as files using the keys in the Data field as the file names. +// Note that this is identical to a secret volume source without the default +// mode. +type SecretProjection struct { + LocalObjectReference + // If unspecified, each key-value pair in the Data field of the referenced + // Secret will be projected into the volume as a file whose name is the + // key and content is the value. If specified, the listed keys will be + // projected into the specified paths, and unlisted keys will not be + // present. If a key is specified which is not present in the Secret, + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. + // +optional + Items []KeyToPath + // Specify whether the Secret or its key must be defined + // +optional + Optional *bool } // Represents an NFS mount that lasts the lifetime of a pod. // NFS volumes do not support ownership management or SELinux relabeling. type NFSVolumeSource struct { // Server is the hostname or IP address of the NFS server - Server string `json:"server"` + Server string // Path is the exported NFS share - Path string `json:"path"` + Path string // Optional: Defaults to false (read/write). ReadOnly here will force // the NFS export to be mounted with read-only permissions // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a Quobyte mount that lasts the lifetime of a pod. @@ -762,71 +868,71 @@ type QuobyteVolumeSource struct { // Registry represents a single or multiple Quobyte Registry services // specified as a string as host:port pair (multiple entries are separated with commas) // which acts as the central registry for volumes - Registry string `json:"registry"` + Registry string // Volume is a string that references an already created Quobyte volume by name. - Volume string `json:"volume"` + Volume string // Defaults to false (read/write). ReadOnly here will force // the Quobyte to be mounted with read-only permissions // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool // User to map volume access to // Defaults to the root user // +optional - User string `json:"user,omitempty"` + User string // Group to map volume access to // Default is no group // +optional - Group string `json:"group,omitempty"` + Group string } // Represents a Glusterfs mount that lasts the lifetime of a pod. // Glusterfs volumes do not support ownership management or SELinux relabeling. type GlusterfsVolumeSource struct { // Required: EndpointsName is the endpoint name that details Glusterfs topology - EndpointsName string `json:"endpoints"` + EndpointsName string // Required: Path is the Glusterfs volume path - Path string `json:"path"` + Path string // Optional: Defaults to false (read/write). ReadOnly here will force // the Glusterfs to be mounted with read-only permissions // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a Rados Block Device mount that lasts the lifetime of a pod. // RBD volumes support ownership management and SELinux relabeling. type RBDVolumeSource struct { // Required: CephMonitors is a collection of Ceph monitors - CephMonitors []string `json:"monitors"` + CephMonitors []string // Required: RBDImage is the rados image name - RBDImage string `json:"image"` + RBDImage string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: RadosPool is the rados pool name,default is rbd // +optional - RBDPool string `json:"pool,omitempty"` + RBDPool string // Optional: RBDUser is the rados user name, default is admin // +optional - RadosUser string `json:"user,omitempty"` + RadosUser string // Optional: Keyring is the path to key ring for RBDUser, default is /etc/ceph/keyring // +optional - Keyring string `json:"keyring,omitempty"` + Keyring string // Optional: SecretRef is name of the authentication secret for RBDUser, default is nil. // +optional - SecretRef *LocalObjectReference `json:"secretRef,omitempty"` + SecretRef *LocalObjectReference // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a cinder volume resource in Openstack. A Cinder volume @@ -835,39 +941,39 @@ type RBDVolumeSource struct { // management and SELinux relabeling. type CinderVolumeSource struct { // Unique id of the volume used to identify the cinder volume - VolumeID string `json:"volumeID"` + VolumeID string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // +optional - FSType string `json:"fsType,omitempty"` + FSType string // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a Ceph Filesystem mount that lasts the lifetime of a pod // Cephfs volumes do not support ownership management or SELinux relabeling. type CephFSVolumeSource struct { // Required: Monitors is a collection of Ceph monitors - Monitors []string `json:"monitors"` + Monitors []string // Optional: Used as the mounted root, rather than the full Ceph tree, default is / // +optional - Path string `json:"path,omitempty"` + Path string // Optional: User is the rados user name, default is admin // +optional - User string `json:"user,omitempty"` + User string // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret // +optional - SecretFile string `json:"secretFile,omitempty"` + SecretFile string // Optional: SecretRef is reference to the authentication secret for User, default is empty. // +optional - SecretRef *LocalObjectReference `json:"secretRef,omitempty"` + SecretRef *LocalObjectReference // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a Flocker volume mounted by the Flocker agent. @@ -877,10 +983,10 @@ type FlockerVolumeSource struct { // Name of the dataset stored as metadata -> name on the dataset for Flocker // should be considered as deprecated // +optional - DatasetName string `json:"datasetName,omitempty"` + DatasetName string // UUID of the dataset. This is unique identifier of a Flocker dataset // +optional - DatasetUUID string `json:"datasetUUID,omitempty"` + DatasetUUID string } // Represents a volume containing downward API info. @@ -888,94 +994,222 @@ type FlockerVolumeSource struct { type DownwardAPIVolumeSource struct { // Items is a list of DownwardAPIVolume file // +optional - Items []DownwardAPIVolumeFile `json:"items,omitempty"` + Items []DownwardAPIVolumeFile // Mode bits to use on created files by default. Must be a value between // 0 and 0777. // Directories within the path are not affected by this setting. // This might be in conflict with other options that affect the file // mode, like fsGroup, and the result can be other mode bits set. // +optional - DefaultMode *int32 `json:"defaultMode,omitempty"` + DefaultMode *int32 } // Represents a single file containing information from the downward API type DownwardAPIVolumeFile struct { // Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..' - Path string `json:"path"` + Path string // Required: Selects a field of the pod: only annotations, labels, name and namespace are supported. // +optional - FieldRef *ObjectFieldSelector `json:"fieldRef,omitempty"` + FieldRef *ObjectFieldSelector // Selects a resource of the container: only resources limits and requests // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported. // +optional - ResourceFieldRef *ResourceFieldSelector `json:"resourceFieldRef,omitempty"` + ResourceFieldRef *ResourceFieldSelector // Optional: mode bits to use on this file, must be a value between 0 // and 0777. If not specified, the volume defaultMode will be used. // This might be in conflict with other options that affect the file // mode, like fsGroup, and the result can be other mode bits set. // +optional - Mode *int32 `json:"mode,omitempty"` + Mode *int32 +} + +// Represents downward API info for projecting into a projected volume. +// Note that this is identical to a downwardAPI volume source without the default +// mode. +type DownwardAPIProjection struct { + // Items is a list of DownwardAPIVolume file + // +optional + Items []DownwardAPIVolumeFile } // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. type AzureFileVolumeSource struct { // the name of secret that contains Azure Storage Account Name and Key - SecretName string `json:"secretName"` + SecretName string // Share Name - ShareName string `json:"shareName"` + ShareName string // Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool } // Represents a vSphere volume resource. type VsphereVirtualDiskVolumeSource struct { // Path that identifies vSphere volume vmdk - VolumePath string `json:"volumePath"` + VolumePath string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // +optional - FSType string `json:"fsType,omitempty"` + FSType string + // Storage Policy Based Management (SPBM) profile name. + // +optional + StoragePolicyName string + // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. + // +optional + StoragePolicyID string } // Represents a Photon Controller persistent disk resource. type PhotonPersistentDiskVolumeSource struct { // ID that identifies Photon Controller persistent disk - PdID string `json:"pdID"` + PdID string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - FSType string `json:"fsType,omitempty"` + FSType string +} + +// PortworxVolumeSource represents a Portworx volume resource. +type PortworxVolumeSource struct { + // VolumeID uniquely identifies a Portworx volume + VolumeID string + // FSType represents the filesystem type to mount + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType string + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool } type AzureDataDiskCachingMode string +type AzureDataDiskKind string const ( AzureDataDiskCachingNone AzureDataDiskCachingMode = "None" AzureDataDiskCachingReadOnly AzureDataDiskCachingMode = "ReadOnly" AzureDataDiskCachingReadWrite AzureDataDiskCachingMode = "ReadWrite" + + AzureSharedBlobDisk AzureDataDiskKind = "Shared" + AzureDedicatedBlobDisk AzureDataDiskKind = "Dedicated" + AzureManagedDisk AzureDataDiskKind = "Managed" ) // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. type AzureDiskVolumeSource struct { // The Name of the data disk in the blob storage - DiskName string `json:"diskName"` - // The URI the the data disk in the blob storage - DataDiskURI string `json:"diskURI"` + DiskName string + // The URI of the data disk in the blob storage + DataDiskURI string // Host Caching mode: None, Read Only, Read Write. // +optional - CachingMode *AzureDataDiskCachingMode `json:"cachingMode,omitempty"` + CachingMode *AzureDataDiskCachingMode + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType *string + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly *bool + // Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared + Kind *AzureDataDiskKind +} + +// ScaleIOVolumeSource represents a persistent ScaleIO volume +type ScaleIOVolumeSource struct { + // The host address of the ScaleIO API Gateway. + Gateway string + // The name of the storage system as configured in ScaleIO. + System string + // SecretRef references to the secret for ScaleIO user and other + // sensitive information. If this is not provided, Login operation will fail. + SecretRef *LocalObjectReference + // Flag to enable/disable SSL communication with Gateway, default false + // +optional + SSLEnabled bool + // The name of the Protection Domain for the configured storage (defaults to "default"). + // +optional + ProtectionDomain string + // The Storage Pool associated with the protection domain (defaults to "default"). + // +optional + StoragePool string + // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). + // +optional + StorageMode string + // The name of a volume already created in the ScaleIO system + // that is associated with this volume source. + VolumeName string + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType string + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool +} + +// Represents a StorageOS persistent volume resource. +type StorageOSVolumeSource struct { + // VolumeName is the human-readable name of the StorageOS volume. Volume + // names are only unique within a namespace. + VolumeName string + // VolumeNamespace specifies the scope of the volume within StorageOS. If no + // namespace is specified then the Pod's namespace will be used. This allows the + // Kubernetes name scoping to be mirrored within StorageOS for tighter integration. + // Set VolumeName to any name to override the default behaviour. + // Set to "default" if you are not using namespaces within StorageOS. + // Namespaces that do not pre-exist within StorageOS will be created. + // +optional + VolumeNamespace string + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType string + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool + // SecretRef specifies the secret to use for obtaining the StorageOS API + // credentials. If not specified, default values will be attempted. + // +optional + SecretRef *LocalObjectReference +} + +// Represents a StorageOS persistent volume resource. +type StorageOSPersistentVolumeSource struct { + // VolumeName is the human-readable name of the StorageOS volume. Volume + // names are only unique within a namespace. + VolumeName string + // VolumeNamespace specifies the scope of the volume within StorageOS. If no + // namespace is specified then the Pod's namespace will be used. This allows the + // Kubernetes name scoping to be mirrored within StorageOS for tighter integration. + // Set VolumeName to any name to override the default behaviour. + // Set to "default" if you are not using namespaces within StorageOS. + // Namespaces that do not pre-exist within StorageOS will be created. + // +optional + VolumeNamespace string // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // +optional - FSType *string `json:"fsType,omitempty"` + FSType string // Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. // +optional - ReadOnly *bool `json:"readOnly,omitempty"` + ReadOnly bool + // SecretRef specifies the secret to use for obtaining the StorageOS API + // credentials. If not specified, default values will be attempted. + // +optional + SecretRef *ObjectReference } // Adapts a ConfigMap into a volume. @@ -985,41 +1219,100 @@ type AzureDiskVolumeSource struct { // the items element is populated with specific mappings of keys to paths. // ConfigMap volumes support ownership management and SELinux relabeling. type ConfigMapVolumeSource struct { - LocalObjectReference `json:",inline"` + LocalObjectReference // If unspecified, each key-value pair in the Data field of the referenced // ConfigMap will be projected into the volume as a file whose name is the // key and content is the value. If specified, the listed keys will be // projected into the specified paths, and unlisted keys will not be // present. If a key is specified which is not present in the ConfigMap, - // the volume setup will error. Paths must be relative and may not contain - // the '..' path or start with '..'. + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. // +optional - Items []KeyToPath `json:"items,omitempty"` + Items []KeyToPath // Mode bits to use on created files by default. Must be a value between // 0 and 0777. // Directories within the path are not affected by this setting. // This might be in conflict with other options that affect the file // mode, like fsGroup, and the result can be other mode bits set. // +optional - DefaultMode *int32 `json:"defaultMode,omitempty"` + DefaultMode *int32 + // Specify whether the ConfigMap or it's keys must be defined + // +optional + Optional *bool +} + +// Adapts a ConfigMap into a projected volume. +// +// The contents of the target ConfigMap's Data field will be presented in a +// projected volume as files using the keys in the Data field as the file names, +// unless the items element is populated with specific mappings of keys to paths. +// Note that this is identical to a configmap volume source without the default +// mode. +type ConfigMapProjection struct { + LocalObjectReference + // If unspecified, each key-value pair in the Data field of the referenced + // ConfigMap will be projected into the volume as a file whose name is the + // key and content is the value. If specified, the listed keys will be + // projected into the specified paths, and unlisted keys will not be + // present. If a key is specified which is not present in the ConfigMap, + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. + // +optional + Items []KeyToPath + // Specify whether the ConfigMap or it's keys must be defined + // +optional + Optional *bool +} + +// Represents a projected volume source +type ProjectedVolumeSource struct { + // list of volume projections + Sources []VolumeProjection + // Mode bits to use on created files by default. Must be a value between + // 0 and 0777. + // Directories within the path are not affected by this setting. + // This might be in conflict with other options that affect the file + // mode, like fsGroup, and the result can be other mode bits set. + // +optional + DefaultMode *int32 +} + +// Projection that may be projected along with other supported volume types +type VolumeProjection struct { + // all types below are the supported types for projection into the same volume + + // information about the secret data to project + Secret *SecretProjection + // information about the downwardAPI data to project + DownwardAPI *DownwardAPIProjection + // information about the configMap data to project + ConfigMap *ConfigMapProjection } // Maps a string key to a path within a volume. type KeyToPath struct { // The key to project. - Key string `json:"key"` + Key string // The relative path of the file to map the key to. // May not be an absolute path. // May not contain the path element '..'. // May not start with the string '..'. - Path string `json:"path"` + Path string // Optional: mode bits to use on this file, should be a value between 0 // and 0777. If not specified, the volume defaultMode will be used. // This might be in conflict with other options that affect the file // mode, like fsGroup, and the result can be other mode bits set. // +optional - Mode *int32 `json:"mode,omitempty"` + Mode *int32 +} + +// Local represents directly-attached storage with node affinity +type LocalVolumeSource struct { + // The full path to the volume on the node + // For alpha, this path must be a directory + // Once block as a source is supported, then this path can point to a block device + Path string } // ContainerPort represents a network port in a single container @@ -1027,40 +1320,40 @@ type ContainerPort struct { // Optional: If specified, this must be an IANA_SVC_NAME Each named port // in a pod must have a unique name. // +optional - Name string `json:"name,omitempty"` + Name string // Optional: If specified, this must be a valid port number, 0 < x < 65536. // If HostNetwork is specified, this must match ContainerPort. // +optional - HostPort int32 `json:"hostPort,omitempty"` + HostPort int32 // Required: This must be a valid port number, 0 < x < 65536. - ContainerPort int32 `json:"containerPort"` + ContainerPort int32 // Required: Supports "TCP" and "UDP". // +optional - Protocol Protocol `json:"protocol,omitempty"` + Protocol Protocol // Optional: What host IP to bind the external port to. // +optional - HostIP string `json:"hostIP,omitempty"` + HostIP string } // VolumeMount describes a mounting of a Volume within a container. type VolumeMount struct { // Required: This must match the Name of a Volume [above]. - Name string `json:"name"` + Name string // Optional: Defaults to false (read-write). // +optional - ReadOnly bool `json:"readOnly,omitempty"` + ReadOnly bool // Required. Must not contain ':'. - MountPath string `json:"mountPath"` + MountPath string // Path within the volume from which the container's volume should be mounted. // Defaults to "" (volume's root). // +optional - SubPath string `json:"subPath,omitempty"` + SubPath string } // EnvVar represents an environment variable present in a Container. type EnvVar struct { // Required: This must be a C_IDENTIFIER. - Name string `json:"name"` + Name string // Optional: no more than one of the following may be specified. // Optional: Defaults to ""; variable references $(VAR_NAME) are expanded // using the previous defined environment variables in the container and @@ -1070,29 +1363,29 @@ type EnvVar struct { // references will never be expanded, regardless of whether the variable // exists or not. // +optional - Value string `json:"value,omitempty"` + Value string // Optional: Specifies a source the value of this var should come from. // +optional - ValueFrom *EnvVarSource `json:"valueFrom,omitempty"` + ValueFrom *EnvVarSource } // EnvVarSource represents a source for the value of an EnvVar. // Only one of its fields may be set. type EnvVarSource struct { // Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, - // spec.nodeName, spec.serviceAccountName, status.podIP. + // spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP. // +optional - FieldRef *ObjectFieldSelector `json:"fieldRef,omitempty"` + FieldRef *ObjectFieldSelector // Selects a resource of the container: only resources limits and requests // (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported. // +optional - ResourceFieldRef *ResourceFieldSelector `json:"resourceFieldRef,omitempty"` + ResourceFieldRef *ResourceFieldSelector // Selects a key of a ConfigMap. // +optional - ConfigMapKeyRef *ConfigMapKeySelector `json:"configMapKeyRef,omitempty"` + ConfigMapKeyRef *ConfigMapKeySelector // Selects a key of a secret in the pod's namespace. // +optional - SecretKeyRef *SecretKeySelector `json:"secretKeyRef,omitempty"` + SecretKeyRef *SecretKeySelector } // ObjectFieldSelector selects an APIVersioned field of an object. @@ -1100,65 +1393,110 @@ type ObjectFieldSelector struct { // Required: Version of the schema the FieldPath is written in terms of. // If no value is specified, it will be defaulted to the APIVersion of the // enclosing object. - APIVersion string `json:"apiVersion"` + APIVersion string // Required: Path of the field to select in the specified API version - FieldPath string `json:"fieldPath"` + FieldPath string } // ResourceFieldSelector represents container resources (cpu, memory) and their output format type ResourceFieldSelector struct { // Container name: required for volumes, optional for env vars // +optional - ContainerName string `json:"containerName,omitempty"` + ContainerName string // Required: resource to select - Resource string `json:"resource"` + Resource string // Specifies the output format of the exposed resources, defaults to "1" // +optional - Divisor resource.Quantity `json:"divisor,omitempty"` + Divisor resource.Quantity } // Selects a key from a ConfigMap. type ConfigMapKeySelector struct { // The ConfigMap to select from. - LocalObjectReference `json:",inline"` + LocalObjectReference // The key to select. - Key string `json:"key"` + Key string + // Specify whether the ConfigMap or it's key must be defined + // +optional + Optional *bool } // SecretKeySelector selects a key of a Secret. type SecretKeySelector struct { // The name of the secret in the pod's namespace to select from. - LocalObjectReference `json:",inline"` + LocalObjectReference // The key of the secret to select from. Must be a valid secret key. - Key string `json:"key"` + Key string + // Specify whether the Secret or it's key must be defined + // +optional + Optional *bool +} + +// EnvFromSource represents the source of a set of ConfigMaps +type EnvFromSource struct { + // An optional identifier to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. + // +optional + Prefix string + // The ConfigMap to select from. + //+optional + ConfigMapRef *ConfigMapEnvSource + // The Secret to select from. + //+optional + SecretRef *SecretEnvSource +} + +// ConfigMapEnvSource selects a ConfigMap to populate the environment +// variables with. +// +// The contents of the target ConfigMap's Data field will represent the +// key-value pairs as environment variables. +type ConfigMapEnvSource struct { + // The ConfigMap to select from. + LocalObjectReference + // Specify whether the ConfigMap must be defined + // +optional + Optional *bool +} + +// SecretEnvSource selects a Secret to populate the environment +// variables with. +// +// The contents of the target Secret's Data field will represent the +// key-value pairs as environment variables. +type SecretEnvSource struct { + // The Secret to select from. + LocalObjectReference + // Specify whether the Secret must be defined + // +optional + Optional *bool } // HTTPHeader describes a custom header to be used in HTTP probes type HTTPHeader struct { // The header field name - Name string `json:"name"` + Name string // The header field value - Value string `json:"value"` + Value string } // HTTPGetAction describes an action based on HTTP Get requests. type HTTPGetAction struct { // Optional: Path to access on the HTTP server. // +optional - Path string `json:"path,omitempty"` + Path string // Required: Name or number of the port to access on the container. // +optional - Port intstr.IntOrString `json:"port,omitempty"` + Port intstr.IntOrString // Optional: Host name to connect to, defaults to the pod IP. You // probably want to set "Host" in httpHeaders instead. // +optional - Host string `json:"host,omitempty"` + Host string // Optional: Scheme to use for connecting to the host, defaults to HTTP. // +optional - Scheme URIScheme `json:"scheme,omitempty"` + Scheme URIScheme // Optional: Custom headers to set in the request. HTTP allows repeated headers. // +optional - HTTPHeaders []HTTPHeader `json:"httpHeaders,omitempty"` + HTTPHeaders []HTTPHeader } // URIScheme identifies the scheme used for connection to a host for Get actions @@ -1175,7 +1513,10 @@ const ( type TCPSocketAction struct { // Required: Port to connect to. // +optional - Port intstr.IntOrString `json:"port,omitempty"` + Port intstr.IntOrString + // Optional: Host name to connect to, defaults to the pod IP. + // +optional + Host string } // ExecAction describes a "run in container" action. @@ -1185,30 +1526,30 @@ type ExecAction struct { // not run inside a shell, so traditional shell instructions ('|', etc) won't work. To use // a shell, you need to explicitly call out to that shell. // +optional - Command []string `json:"command,omitempty"` + Command []string } // Probe describes a health check to be performed against a container to determine whether it is // alive or ready to receive traffic. type Probe struct { // The action taken to determine the health of a container - Handler `json:",inline"` + Handler // Length of time before health checking is activated. In seconds. // +optional - InitialDelaySeconds int32 `json:"initialDelaySeconds,omitempty"` + InitialDelaySeconds int32 // Length of time before health checking times out. In seconds. // +optional - TimeoutSeconds int32 `json:"timeoutSeconds,omitempty"` + TimeoutSeconds int32 // How often (in seconds) to perform the probe. // +optional - PeriodSeconds int32 `json:"periodSeconds,omitempty"` + PeriodSeconds int32 // Minimum consecutive successes for the probe to be considered successful after having failed. // Must be 1 for liveness. // +optional - SuccessThreshold int32 `json:"successThreshold,omitempty"` + SuccessThreshold int32 // Minimum consecutive failures for the probe to be considered failed after having succeeded. // +optional - FailureThreshold int32 `json:"failureThreshold,omitempty"` + FailureThreshold int32 } // PullPolicy describes a policy for if/when to pull a container image @@ -1223,6 +1564,19 @@ const ( PullIfNotPresent PullPolicy = "IfNotPresent" ) +// TerminationMessagePolicy describes how termination messages are retrieved from a container. +type TerminationMessagePolicy string + +const ( + // TerminationMessageReadFile is the default behavior and will set the container status message to + // the contents of the container's terminationMessagePath when the container exits. + TerminationMessageReadFile TerminationMessagePolicy = "File" + // TerminationMessageFallbackToLogsOnError will read the most recent contents of the container logs + // for the container status message when the container exits with an error and the + // terminationMessagePath has no contents. + TerminationMessageFallbackToLogsOnError TerminationMessagePolicy = "FallbackToLogsOnError" +) + // Capability represent POSIX capabilities type type Capability string @@ -1230,81 +1584,91 @@ type Capability string type Capabilities struct { // Added capabilities // +optional - Add []Capability `json:"add,omitempty"` + Add []Capability // Removed capabilities // +optional - Drop []Capability `json:"drop,omitempty"` + Drop []Capability } // ResourceRequirements describes the compute resource requirements. type ResourceRequirements struct { // Limits describes the maximum amount of compute resources allowed. // +optional - Limits ResourceList `json:"limits,omitempty"` + Limits ResourceList // Requests describes the minimum amount of compute resources required. // If Request is omitted for a container, it defaults to Limits if that is explicitly specified, // otherwise to an implementation-defined value // +optional - Requests ResourceList `json:"requests,omitempty"` + Requests ResourceList } // Container represents a single container that is expected to be run on the host. type Container struct { // Required: This must be a DNS_LABEL. Each container in a pod must // have a unique name. - Name string `json:"name"` + Name string // Required. - Image string `json:"image"` + Image string // Optional: The docker image's entrypoint is used if this is not provided; cannot be updated. // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, // regardless of whether the variable exists or not. // +optional - Command []string `json:"command,omitempty"` + Command []string // Optional: The docker image's cmd is used if this is not provided; cannot be updated. // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable // cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, // regardless of whether the variable exists or not. // +optional - Args []string `json:"args,omitempty"` + Args []string // Optional: Defaults to Docker's default. // +optional - WorkingDir string `json:"workingDir,omitempty"` + WorkingDir string // +optional - Ports []ContainerPort `json:"ports,omitempty"` + Ports []ContainerPort + // List of sources to populate environment variables in the container. + // The keys defined within a source must be a C_IDENTIFIER. All invalid keys + // will be reported as an event when the container is starting. When a key exists in multiple + // sources, the value associated with the last source will take precedence. + // Values defined by an Env with a duplicate key will take precedence. + // Cannot be updated. // +optional - Env []EnvVar `json:"env,omitempty"` + EnvFrom []EnvFromSource + // +optional + Env []EnvVar // Compute resource requirements. // +optional - Resources ResourceRequirements `json:"resources,omitempty"` + Resources ResourceRequirements // +optional - VolumeMounts []VolumeMount `json:"volumeMounts,omitempty"` + VolumeMounts []VolumeMount // +optional - LivenessProbe *Probe `json:"livenessProbe,omitempty"` + LivenessProbe *Probe // +optional - ReadinessProbe *Probe `json:"readinessProbe,omitempty"` + ReadinessProbe *Probe // +optional - Lifecycle *Lifecycle `json:"lifecycle,omitempty"` + Lifecycle *Lifecycle // Required. // +optional - TerminationMessagePath string `json:"terminationMessagePath,omitempty"` + TerminationMessagePath string + // +optional + TerminationMessagePolicy TerminationMessagePolicy // Required: Policy for pulling images for this container - ImagePullPolicy PullPolicy `json:"imagePullPolicy"` + ImagePullPolicy PullPolicy // Optional: SecurityContext defines the security options the container should be run with. // If set, the fields of SecurityContext override the equivalent fields of PodSecurityContext. // +optional - SecurityContext *SecurityContext `json:"securityContext,omitempty"` + SecurityContext *SecurityContext // Variables for interactive containers, these have very specialized use-cases (e.g. debugging) // and shouldn't be used for general purpose containers. // +optional - Stdin bool `json:"stdin,omitempty"` + Stdin bool // +optional - StdinOnce bool `json:"stdinOnce,omitempty"` + StdinOnce bool // +optional - TTY bool `json:"tty,omitempty"` + TTY bool } // Handler defines a specific action that should be taken @@ -1313,14 +1677,14 @@ type Handler struct { // One and only one of the following should be specified. // Exec specifies the action to take. // +optional - Exec *ExecAction `json:"exec,omitempty"` + Exec *ExecAction // HTTPGet specifies the http request to perform. // +optional - HTTPGet *HTTPGetAction `json:"httpGet,omitempty"` + HTTPGet *HTTPGetAction // TCPSocket specifies an action involving a TCP port. // TODO: implement a realistic TCP lifecycle hook // +optional - TCPSocket *TCPSocketAction `json:"tcpSocket,omitempty"` + TCPSocket *TCPSocketAction } // Lifecycle describes actions that the management system should take in response to container lifecycle @@ -1330,11 +1694,11 @@ type Lifecycle struct { // PostStart is called immediately after a container is created. If the handler fails, the container // is terminated and restarted. // +optional - PostStart *Handler `json:"postStart,omitempty"` + PostStart *Handler // PreStop is called immediately before a container is terminated. The reason for termination is // passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. // +optional - PreStop *Handler `json:"preStop,omitempty"` + PreStop *Handler } // The below types are used by kube_client and api_server. @@ -1354,31 +1718,31 @@ const ( type ContainerStateWaiting struct { // A brief CamelCase string indicating details about why the container is in waiting state. // +optional - Reason string `json:"reason,omitempty"` + Reason string // A human-readable message indicating details about why the container is in waiting state. // +optional - Message string `json:"message,omitempty"` + Message string } type ContainerStateRunning struct { // +optional - StartedAt unversioned.Time `json:"startedAt,omitempty"` + StartedAt metav1.Time } type ContainerStateTerminated struct { - ExitCode int32 `json:"exitCode"` + ExitCode int32 // +optional - Signal int32 `json:"signal,omitempty"` + Signal int32 // +optional - Reason string `json:"reason,omitempty"` + Reason string // +optional - Message string `json:"message,omitempty"` + Message string // +optional - StartedAt unversioned.Time `json:"startedAt,omitempty"` + StartedAt metav1.Time // +optional - FinishedAt unversioned.Time `json:"finishedAt,omitempty"` + FinishedAt metav1.Time // +optional - ContainerID string `json:"containerID,omitempty"` + ContainerID string } // ContainerState holds a possible state of container. @@ -1386,29 +1750,29 @@ type ContainerStateTerminated struct { // If none of them is specified, the default one is ContainerStateWaiting. type ContainerState struct { // +optional - Waiting *ContainerStateWaiting `json:"waiting,omitempty"` + Waiting *ContainerStateWaiting // +optional - Running *ContainerStateRunning `json:"running,omitempty"` + Running *ContainerStateRunning // +optional - Terminated *ContainerStateTerminated `json:"terminated,omitempty"` + Terminated *ContainerStateTerminated } type ContainerStatus struct { // Each container in a pod must have a unique name. - Name string `json:"name"` + Name string // +optional - State ContainerState `json:"state,omitempty"` + State ContainerState // +optional - LastTerminationState ContainerState `json:"lastState,omitempty"` + LastTerminationState ContainerState // Ready specifies whether the container has passed its readiness check. - Ready bool `json:"ready"` + Ready bool // Note that this is calculated from dead containers. But those containers are subject to // garbage collection. This value will get capped at 5 by GC. - RestartCount int32 `json:"restartCount"` - Image string `json:"image"` - ImageID string `json:"imageID"` + RestartCount int32 + Image string + ImageID string // +optional - ContainerID string `json:"containerID,omitempty"` + ContainerID string } // PodPhase is a label for the condition of a pod at the current time. @@ -1451,16 +1815,16 @@ const ( ) type PodCondition struct { - Type PodConditionType `json:"type"` - Status ConditionStatus `json:"status"` + Type PodConditionType + Status ConditionStatus // +optional - LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty"` + LastProbeTime metav1.Time // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"` + LastTransitionTime metav1.Time // +optional - Reason string `json:"reason,omitempty"` + Reason string // +optional - Message string `json:"message,omitempty"` + Message string } // RestartPolicy describes how the container should be restarted. @@ -1477,20 +1841,25 @@ const ( // PodList is a list of Pods. type PodList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Pod `json:"items"` + Items []Pod } // DNSPolicy defines how a pod's DNS will be configured. type DNSPolicy string const ( + // DNSClusterFirstWithHostNet indicates that the pod should use cluster DNS + // first, if it is available, then fall back on the default + // (as determined by kubelet) DNS settings. + DNSClusterFirstWithHostNet DNSPolicy = "ClusterFirstWithHostNet" + // DNSClusterFirst indicates that the pod should use cluster DNS - // first, if it is available, then fall back on the default (as - // determined by kubelet) DNS settings. + // first unless hostNetwork is true, if it is available, then + // fall back on the default (as determined by kubelet) DNS settings. DNSClusterFirst DNSPolicy = "ClusterFirst" // DNSDefault indicates that the pod should use the default (as @@ -1503,30 +1872,30 @@ const ( // by the node selector terms. type NodeSelector struct { //Required. A list of node selector terms. The terms are ORed. - NodeSelectorTerms []NodeSelectorTerm `json:"nodeSelectorTerms"` + NodeSelectorTerms []NodeSelectorTerm } // A null or empty node selector term matches no objects. type NodeSelectorTerm struct { //Required. A list of node selector requirements. The requirements are ANDed. - MatchExpressions []NodeSelectorRequirement `json:"matchExpressions"` + MatchExpressions []NodeSelectorRequirement } // A node selector requirement is a selector that contains values, a key, and an operator // that relates the key and values. type NodeSelectorRequirement struct { // The label key that the selector applies to. - Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key"` + Key string // Represents a key's relationship to a set of values. // Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt. - Operator NodeSelectorOperator `json:"operator"` + Operator NodeSelectorOperator // An array of string values. If the operator is In or NotIn, // the values array must be non-empty. If the operator is Exists or DoesNotExist, // the values array must be empty. If the operator is Gt or Lt, the values // array must have a single element, which will be interpreted as an integer. // This array is replaced during a strategic merge patch. // +optional - Values []string `json:"values,omitempty"` + Values []string } // A node selector operator is the set of operators that can be used in @@ -1546,13 +1915,13 @@ const ( type Affinity struct { // Describes node affinity scheduling rules for the pod. // +optional - NodeAffinity *NodeAffinity `json:"nodeAffinity,omitempty"` + NodeAffinity *NodeAffinity // Describes pod affinity scheduling rules (e.g. co-locate this pod in the same node, zone, etc. as some other pod(s)). // +optional - PodAffinity *PodAffinity `json:"podAffinity,omitempty"` + PodAffinity *PodAffinity // Describes pod anti-affinity scheduling rules (e.g. avoid putting this pod in the same node, zone, etc. as some other pod(s)). // +optional - PodAntiAffinity *PodAntiAffinity `json:"podAntiAffinity,omitempty"` + PodAntiAffinity *PodAntiAffinity } // Pod affinity is a group of inter pod affinity scheduling rules. @@ -1566,7 +1935,7 @@ type PodAffinity struct { // When there are multiple elements, the lists of nodes corresponding to each // podAffinityTerm are intersected, i.e. all terms must be satisfied. // +optional - // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` + // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm // If the affinity requirements specified by this field are not met at // scheduling time, the pod will not be scheduled onto the node. // If the affinity requirements specified by this field cease to be met @@ -1575,7 +1944,7 @@ type PodAffinity struct { // When there are multiple elements, the lists of nodes corresponding to each // podAffinityTerm are intersected, i.e. all terms must be satisfied. // +optional - RequiredDuringSchedulingIgnoredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingIgnoredDuringExecution,omitempty"` + RequiredDuringSchedulingIgnoredDuringExecution []PodAffinityTerm // The scheduler will prefer to schedule pods to nodes that satisfy // the affinity expressions specified by this field, but it may choose // a node that violates one or more of the expressions. The node that is @@ -1586,7 +1955,7 @@ type PodAffinity struct { // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the // node(s) with the highest sum are the most preferred. // +optional - PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm `json:"preferredDuringSchedulingIgnoredDuringExecution,omitempty"` + PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm } // Pod anti affinity is a group of inter pod anti affinity scheduling rules. @@ -1600,7 +1969,7 @@ type PodAntiAffinity struct { // When there are multiple elements, the lists of nodes corresponding to each // podAffinityTerm are intersected, i.e. all terms must be satisfied. // +optional - // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` + // RequiredDuringSchedulingRequiredDuringExecution []PodAffinityTerm // If the anti-affinity requirements specified by this field are not met at // scheduling time, the pod will not be scheduled onto the node. // If the anti-affinity requirements specified by this field cease to be met @@ -1609,7 +1978,7 @@ type PodAntiAffinity struct { // When there are multiple elements, the lists of nodes corresponding to each // podAffinityTerm are intersected, i.e. all terms must be satisfied. // +optional - RequiredDuringSchedulingIgnoredDuringExecution []PodAffinityTerm `json:"requiredDuringSchedulingIgnoredDuringExecution,omitempty"` + RequiredDuringSchedulingIgnoredDuringExecution []PodAffinityTerm // The scheduler will prefer to schedule pods to nodes that satisfy // the anti-affinity expressions specified by this field, but it may choose // a node that violates one or more of the expressions. The node that is @@ -1620,16 +1989,16 @@ type PodAntiAffinity struct { // "weight" to the sum if the node has pods which matches the corresponding podAffinityTerm; the // node(s) with the highest sum are the most preferred. // +optional - PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm `json:"preferredDuringSchedulingIgnoredDuringExecution,omitempty"` + PreferredDuringSchedulingIgnoredDuringExecution []WeightedPodAffinityTerm } // The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s) type WeightedPodAffinityTerm struct { // weight associated with matching the corresponding podAffinityTerm, // in the range 1-100. - Weight int32 `json:"weight"` + Weight int32 // Required. A pod affinity term, associated with the corresponding weight. - PodAffinityTerm PodAffinityTerm `json:"podAffinityTerm"` + PodAffinityTerm PodAffinityTerm } // Defines a set of pods (namely those matching the labelSelector @@ -1641,12 +2010,10 @@ type WeightedPodAffinityTerm struct { type PodAffinityTerm struct { // A label query over a set of resources, in this case pods. // +optional - LabelSelector *unversioned.LabelSelector `json:"labelSelector,omitempty"` + LabelSelector *metav1.LabelSelector // namespaces specifies which namespaces the labelSelector applies to (matches against); - // nil list means "this pod's namespace," empty list means "all namespaces" - // The json tag here is not "omitempty" since we need to distinguish nil and empty. - // See https://golang.org/pkg/encoding/json/#Marshal for more details. - Namespaces []string `json:"namespaces"` + // null or empty list means "this pod's namespace" + Namespaces []string // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching // the labelSelector in the specified namespaces, where co-located is defined as running on a node // whose value of the label with key topologyKey matches that of any node on which any of the @@ -1655,7 +2022,7 @@ type PodAffinityTerm struct { // ("all topologies" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); // for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed. // +optional - TopologyKey string `json:"topologyKey,omitempty"` + TopologyKey string } // Node affinity is a group of node affinity scheduling rules. @@ -1667,7 +2034,7 @@ type NodeAffinity struct { // at some point during pod execution (e.g. due to an update), the system // will try to eventually evict the pod from its node. // +optional - // RequiredDuringSchedulingRequiredDuringExecution *NodeSelector `json:"requiredDuringSchedulingRequiredDuringExecution,omitempty"` + // RequiredDuringSchedulingRequiredDuringExecution *NodeSelector // If the affinity requirements specified by this field are not met at // scheduling time, the pod will not be scheduled onto the node. @@ -1675,7 +2042,7 @@ type NodeAffinity struct { // at some point during pod execution (e.g. due to an update), the system // may or may not try to eventually evict the pod from its node. // +optional - RequiredDuringSchedulingIgnoredDuringExecution *NodeSelector `json:"requiredDuringSchedulingIgnoredDuringExecution,omitempty"` + RequiredDuringSchedulingIgnoredDuringExecution *NodeSelector // The scheduler will prefer to schedule pods to nodes that satisfy // the affinity expressions specified by this field, but it may choose // a node that violates one or more of the expressions. The node that is @@ -1686,30 +2053,34 @@ type NodeAffinity struct { // "weight" to the sum if the node matches the corresponding matchExpressions; the // node(s) with the highest sum are the most preferred. // +optional - PreferredDuringSchedulingIgnoredDuringExecution []PreferredSchedulingTerm `json:"preferredDuringSchedulingIgnoredDuringExecution,omitempty"` + PreferredDuringSchedulingIgnoredDuringExecution []PreferredSchedulingTerm } // An empty preferred scheduling term matches all objects with implicit weight 0 // (i.e. it's a no-op). A null preferred scheduling term matches no objects (i.e. is also a no-op). type PreferredSchedulingTerm struct { // Weight associated with matching the corresponding nodeSelectorTerm, in the range 1-100. - Weight int32 `json:"weight"` + Weight int32 // A node selector term, associated with the corresponding weight. - Preference NodeSelectorTerm `json:"preference"` + Preference NodeSelectorTerm } // The node this Taint is attached to has the effect "effect" on // any pod that that does not tolerate the Taint. type Taint struct { // Required. The taint key to be applied to a node. - Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key"` + Key string // Required. The taint value corresponding to the taint key. // +optional - Value string `json:"value,omitempty"` + Value string // Required. The effect of the taint on pods // that do not tolerate the taint. - // Valid effects are NoSchedule and PreferNoSchedule. - Effect TaintEffect `json:"effect"` + // Valid effects are NoSchedule, PreferNoSchedule and NoExecute. + Effect TaintEffect + // TimeAdded represents the time at which the taint was added. + // It is only written for NoExecute taints. + // +optional + TimeAdded metav1.Time } type TaintEffect string @@ -1725,41 +2096,42 @@ const ( // onto the node entirely. Enforced by the scheduler. TaintEffectPreferNoSchedule TaintEffect = "PreferNoSchedule" // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. - // Do not allow new pods to schedule onto the node unless they tolerate the taint, - // do not allow pods to start on Kubelet unless they tolerate the taint, - // but allow all already-running pods to continue running. - // Enforced by the scheduler and Kubelet. + // Like TaintEffectNoSchedule, but additionally do not allow pods submitted to + // Kubelet without going through the scheduler to start. + // Enforced by Kubelet and the scheduler. // TaintEffectNoScheduleNoAdmit TaintEffect = "NoScheduleNoAdmit" - // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. - // Do not allow new pods to schedule onto the node unless they tolerate the taint, - // do not allow pods to start on Kubelet unless they tolerate the taint, - // and evict any already-running pods that do not tolerate the taint. - // Enforced by the scheduler and Kubelet. - // TaintEffectNoScheduleNoAdmitNoExecute = "NoScheduleNoAdmitNoExecute" + // Evict any already-running pods that do not tolerate the taint. + // Currently enforced by NodeController. + TaintEffectNoExecute TaintEffect = "NoExecute" ) // The pod this Toleration is attached to tolerates any taint that matches // the triple using the matching operator . type Toleration struct { - // Required. Key is the taint key that the toleration applies to. + // Key is the taint key that the toleration applies to. Empty means match all taint keys. + // If the key is empty, operator must be Exists; this combination means to match all values and all keys. // +optional - Key string `json:"key,omitempty" patchStrategy:"merge" patchMergeKey:"key"` - // operator represents a key's relationship to the value. + Key string + // Operator represents a key's relationship to the value. // Valid operators are Exists and Equal. Defaults to Equal. // Exists is equivalent to wildcard for value, so that a pod can // tolerate all taints of a particular category. // +optional - Operator TolerationOperator `json:"operator,omitempty"` + Operator TolerationOperator // Value is the taint value the toleration matches to. // If the operator is Exists, the value should be empty, otherwise just a regular string. // +optional - Value string `json:"value,omitempty"` + Value string // Effect indicates the taint effect to match. Empty means match all taint effects. - // When specified, allowed values are NoSchedule and PreferNoSchedule. + // When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. + // +optional + Effect TaintEffect + // TolerationSeconds represents the period of time the toleration (which must be + // of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, + // it is not set, which means tolerate the taint forever (do not evict). Zero and + // negative values will be treated as 0 (evict immediately) by the system. // +optional - Effect TaintEffect `json:"effect,omitempty"` - // TODO: For forgiveness (#1574), we'd eventually add at least a grace period - // here, and possibly an occurrence threshold and period. + TolerationSeconds *int64 } // A toleration operator is the set of operators that can be used in a toleration. @@ -1772,13 +2144,13 @@ const ( // PodSpec is a description of a pod type PodSpec struct { - Volumes []Volume `json:"volumes"` + Volumes []Volume // List of initialization containers belonging to the pod. - InitContainers []Container `json:"-"` + InitContainers []Container // List of containers belonging to the pod. - Containers []Container `json:"containers"` + Containers []Container // +optional - RestartPolicy RestartPolicy `json:"restartPolicy,omitempty"` + RestartPolicy RestartPolicy // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. // Value must be non-negative integer. The value zero indicates delete immediately. // If this value is nil, the default grace period will be used instead. @@ -1786,52 +2158,76 @@ type PodSpec struct { // a termination signal and the time when the processes are forcibly halted with a kill signal. // Set this value longer than the expected cleanup time for your process. // +optional - TerminationGracePeriodSeconds *int64 `json:"terminationGracePeriodSeconds,omitempty"` + TerminationGracePeriodSeconds *int64 // Optional duration in seconds relative to the StartTime that the pod may be active on a node // before the system actively tries to terminate the pod; value must be positive integer // +optional - ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty"` + ActiveDeadlineSeconds *int64 // Required: Set DNS policy. // +optional - DNSPolicy DNSPolicy `json:"dnsPolicy,omitempty"` + DNSPolicy DNSPolicy // NodeSelector is a selector which must be true for the pod to fit on a node // +optional - NodeSelector map[string]string `json:"nodeSelector,omitempty"` + NodeSelector map[string]string // ServiceAccountName is the name of the ServiceAccount to use to run this pod // The pod will be allowed to use secrets referenced by the ServiceAccount - ServiceAccountName string `json:"serviceAccountName"` + ServiceAccountName string + // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. + // +optional + AutomountServiceAccountToken *bool // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, // the scheduler simply schedules this pod onto that node, assuming that it fits resource // requirements. // +optional - NodeName string `json:"nodeName,omitempty"` + NodeName string // SecurityContext holds pod-level security attributes and common container settings. // Optional: Defaults to empty. See type description for default values of each field. // +optional - SecurityContext *PodSecurityContext `json:"securityContext,omitempty"` + SecurityContext *PodSecurityContext // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. // If specified, these secrets will be passed to individual puller implementations for them to use. For example, // in the case of docker, only DockerConfig type secrets are honored. // +optional - ImagePullSecrets []LocalObjectReference `json:"imagePullSecrets,omitempty"` + ImagePullSecrets []LocalObjectReference // Specifies the hostname of the Pod. // If not specified, the pod's hostname will be set to a system-defined value. // +optional - Hostname string `json:"hostname,omitempty"` + Hostname string // If specified, the fully qualified Pod hostname will be "...svc.". // If not specified, the pod will not have a domainname at all. // +optional - Subdomain string `json:"subdomain,omitempty"` + Subdomain string + // If specified, the pod's scheduling constraints + // +optional + Affinity *Affinity + // If specified, the pod will be dispatched by specified scheduler. + // If not specified, the pod will be dispatched by default scheduler. + // +optional + SchedulerName string + // If specified, the pod's tolerations. + // +optional + Tolerations []Toleration + // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts + // file if specified. This is only valid for non-hostNetwork pods. + // +optional + HostAliases []HostAlias +} + +// HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the +// pod's hosts file. +type HostAlias struct { + IP string + Hostnames []string } // Sysctl defines a kernel parameter to be set type Sysctl struct { // Name of a property to set - Name string `json:"name"` + Name string // Value of a property to set - Value string `json:"value"` + Value string } // PodSecurityContext holds pod-level security attributes and common container settings. @@ -1843,31 +2239,31 @@ type PodSecurityContext struct { // Optional: Default to false // +k8s:conversion-gen=false // +optional - HostNetwork bool `json:"hostNetwork,omitempty"` + HostNetwork bool // Use the host's pid namespace. // Optional: Default to false. // +k8s:conversion-gen=false // +optional - HostPID bool `json:"hostPID,omitempty"` + HostPID bool // Use the host's ipc namespace. // Optional: Default to false. // +k8s:conversion-gen=false // +optional - HostIPC bool `json:"hostIPC,omitempty"` + HostIPC bool // The SELinux context to be applied to all containers. // If unspecified, the container runtime will allocate a random SELinux context for each // container. May also be set in SecurityContext. If set in // both SecurityContext and PodSecurityContext, the value specified in SecurityContext // takes precedence for that container. // +optional - SELinuxOptions *SELinuxOptions `json:"seLinuxOptions,omitempty"` + SELinuxOptions *SELinuxOptions // The UID to run the entrypoint of the container process. // Defaults to user specified in image metadata if unspecified. // May also be set in SecurityContext. If set in both SecurityContext and // PodSecurityContext, the value specified in SecurityContext takes precedence // for that container. // +optional - RunAsUser *int64 `json:"runAsUser,omitempty"` + RunAsUser *int64 // Indicates that the container must run as a non-root user. // If true, the Kubelet will validate the image at runtime to ensure that it // does not run as UID 0 (root) and fail to start the container if it does. @@ -1875,12 +2271,12 @@ type PodSecurityContext struct { // May also be set in SecurityContext. If set in both SecurityContext and // PodSecurityContext, the value specified in SecurityContext takes precedence. // +optional - RunAsNonRoot *bool `json:"runAsNonRoot,omitempty"` + RunAsNonRoot *bool // A list of groups applied to the first process run in each container, in addition // to the container's primary GID. If unspecified, no groups will be added to // any container. // +optional - SupplementalGroups []int64 `json:"supplementalGroups,omitempty"` + SupplementalGroups []int64 // A special supplemental group that applies to all containers in a pod. // Some volume types allow the Kubelet to change the ownership of that volume // to be owned by the pod: @@ -1891,107 +2287,121 @@ type PodSecurityContext struct { // // If unset, the Kubelet will not modify the ownership and permissions of any volume. // +optional - FSGroup *int64 `json:"fsGroup,omitempty"` + FSGroup *int64 } +// PodQOSClass defines the supported qos classes of Pods. +type PodQOSClass string + +const ( + // PodQOSGuaranteed is the Guaranteed qos class. + PodQOSGuaranteed PodQOSClass = "Guaranteed" + // PodQOSBurstable is the Burstable qos class. + PodQOSBurstable PodQOSClass = "Burstable" + // PodQOSBestEffort is the BestEffort qos class. + PodQOSBestEffort PodQOSClass = "BestEffort" +) + // PodStatus represents information about the status of a pod. Status may trail the actual // state of a system. type PodStatus struct { // +optional - Phase PodPhase `json:"phase,omitempty"` + Phase PodPhase // +optional - Conditions []PodCondition `json:"conditions,omitempty"` + Conditions []PodCondition // A human readable message indicating details about why the pod is in this state. // +optional - Message string `json:"message,omitempty"` + Message string // A brief CamelCase message indicating details about why the pod is in this state. e.g. 'OutOfDisk' // +optional - Reason string `json:"reason,omitempty"` + Reason string // +optional - HostIP string `json:"hostIP,omitempty"` + HostIP string // +optional - PodIP string `json:"podIP,omitempty"` + PodIP string // Date and time at which the object was acknowledged by the Kubelet. // This is before the Kubelet pulled the container image(s) for the pod. // +optional - StartTime *unversioned.Time `json:"startTime,omitempty"` + StartTime *metav1.Time + // +optional + QOSClass PodQOSClass // The list has one entry per init container in the manifest. The most recent successful // init container will have ready = true, the most recently started container will have // startTime set. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-statuses - InitContainerStatuses []ContainerStatus `json:"-"` + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#pod-and-container-status + InitContainerStatuses []ContainerStatus // The list has one entry per container in the manifest. Each entry is // currently the output of `docker inspect`. This output format is *not* // final and should not be relied upon. // TODO: Make real decisions about what our info should look like. Re-enable fuzz test // when we have done this. // +optional - ContainerStatuses []ContainerStatus `json:"containerStatuses,omitempty"` + ContainerStatuses []ContainerStatus } // PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded type PodStatusResult struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Status represents the current information about a pod. This data may not be up // to date. // +optional - Status PodStatus `json:"status,omitempty"` + Status PodStatus } // +genclient=true // Pod is a collection of containers, used as either input (create, update) or as output (list, get). type Pod struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the behavior of a pod. // +optional - Spec PodSpec `json:"spec,omitempty"` + Spec PodSpec // Status represents the current information about a pod. This data may not be up // to date. // +optional - Status PodStatus `json:"status,omitempty"` + Status PodStatus } // PodTemplateSpec describes the data a pod should have when created from a template type PodTemplateSpec struct { // Metadata of the pods created from this template. // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the behavior of a pod. // +optional - Spec PodSpec `json:"spec,omitempty"` + Spec PodSpec } // +genclient=true // PodTemplate describes a template for creating copies of a predefined pod. type PodTemplate struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Template defines the pods that will be created from this pod template // +optional - Template PodTemplateSpec `json:"template,omitempty"` + Template PodTemplateSpec } // PodTemplateList is a list of PodTemplates. type PodTemplateList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []PodTemplate `json:"items"` + Items []PodTemplate } // ReplicationControllerSpec is the specification of a replication controller. @@ -1999,55 +2409,55 @@ type PodTemplateList struct { // a TemplateRef or a Template set. type ReplicationControllerSpec struct { // Replicas is the number of desired replicas. - Replicas int32 `json:"replicas"` + Replicas int32 // Minimum number of seconds for which a newly created pod should be ready // without any of its container crashing, for it to be considered available. // Defaults to 0 (pod will be considered available as soon as it is ready) // +optional - MinReadySeconds int32 `json:"minReadySeconds,omitempty"` + MinReadySeconds int32 // Selector is a label query over pods that should match the Replicas count. - Selector map[string]string `json:"selector"` + Selector map[string]string // TemplateRef is a reference to an object that describes the pod that will be created if // insufficient replicas are detected. This reference is ignored if a Template is set. // Must be set before converting to a versioned API object // +optional - //TemplateRef *ObjectReference `json:"templateRef,omitempty"` + //TemplateRef *ObjectReference // Template is the object that describes the pod that will be created if // insufficient replicas are detected. Internally, this takes precedence over a // TemplateRef. // +optional - Template *PodTemplateSpec `json:"template,omitempty"` + Template *PodTemplateSpec } // ReplicationControllerStatus represents the current status of a replication // controller. type ReplicationControllerStatus struct { // Replicas is the number of actual replicas. - Replicas int32 `json:"replicas"` + Replicas int32 // The number of pods that have labels matching the labels of the pod template of the replication controller. // +optional - FullyLabeledReplicas int32 `json:"fullyLabeledReplicas,omitempty"` + FullyLabeledReplicas int32 // The number of ready replicas for this replication controller. // +optional - ReadyReplicas int32 `json:"readyReplicas,omitempty"` + ReadyReplicas int32 // The number of available replicas (ready for at least minReadySeconds) for this replication controller. // +optional - AvailableReplicas int32 `json:"availableReplicas,omitempty"` + AvailableReplicas int32 // ObservedGeneration is the most recent generation observed by the controller. // +optional - ObservedGeneration int64 `json:"observedGeneration,omitempty"` + ObservedGeneration int64 // Represents the latest available observations of a replication controller's current state. // +optional - Conditions []ReplicationControllerCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` + Conditions []ReplicationControllerCondition } type ReplicationControllerConditionType string @@ -2063,45 +2473,45 @@ const ( // ReplicationControllerCondition describes the state of a replication controller at a certain point. type ReplicationControllerCondition struct { // Type of replication controller condition. - Type ReplicationControllerConditionType `json:"type"` + Type ReplicationControllerConditionType // Status of the condition, one of True, False, Unknown. - Status ConditionStatus `json:"status"` + Status ConditionStatus // The last time the condition transitioned from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"` + LastTransitionTime metav1.Time // The reason for the condition's last transition. // +optional - Reason string `json:"reason,omitempty"` + Reason string // A human readable message indicating details about the transition. // +optional - Message string `json:"message,omitempty"` + Message string } // +genclient=true // ReplicationController represents the configuration of a replication controller. type ReplicationController struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the desired behavior of this replication controller. // +optional - Spec ReplicationControllerSpec `json:"spec,omitempty"` + Spec ReplicationControllerSpec // Status is the current status of this replication controller. This data may be // out of date by some window of time. // +optional - Status ReplicationControllerStatus `json:"status,omitempty"` + Status ReplicationControllerStatus } // ReplicationControllerList is a collection of replication controllers. type ReplicationControllerList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []ReplicationController `json:"items"` + Items []ReplicationController } const ( @@ -2112,11 +2522,11 @@ const ( // ServiceList holds a list of services. type ServiceList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Service `json:"items"` + Items []Service } // Session Affinity Type string @@ -2153,12 +2563,22 @@ const ( ServiceTypeExternalName ServiceType = "ExternalName" ) +// Service External Traffic Policy Type string +type ServiceExternalTrafficPolicyType string + +const ( + // ServiceExternalTrafficPolicyTypeLocal specifies node-local endpoints behavior. + ServiceExternalTrafficPolicyTypeLocal ServiceExternalTrafficPolicyType = "Local" + // ServiceExternalTrafficPolicyTypeCluster specifies cluster-wide (legacy) behavior. + ServiceExternalTrafficPolicyTypeCluster ServiceExternalTrafficPolicyType = "Cluster" +) + // ServiceStatus represents the current status of a service type ServiceStatus struct { // LoadBalancer contains the current status of the load-balancer, // if one is present. // +optional - LoadBalancer LoadBalancerStatus `json:"loadBalancer,omitempty"` + LoadBalancer LoadBalancerStatus } // LoadBalancerStatus represents the status of a load-balancer @@ -2166,7 +2586,7 @@ type LoadBalancerStatus struct { // Ingress is a list containing ingress points for the load-balancer; // traffic intended for the service should be sent to these ingress points. // +optional - Ingress []LoadBalancerIngress `json:"ingress,omitempty"` + Ingress []LoadBalancerIngress } // LoadBalancerIngress represents the status of a load-balancer ingress point: @@ -2175,12 +2595,12 @@ type LoadBalancerIngress struct { // IP is set for load-balancer ingress points that are IP based // (typically GCE or OpenStack load-balancers) // +optional - IP string `json:"ip,omitempty"` + IP string // Hostname is set for load-balancer ingress points that are DNS based // (typically AWS load-balancers) // +optional - Hostname string `json:"hostname,omitempty"` + Hostname string } // ServiceSpec describes the attributes that a user creates on a service @@ -2198,20 +2618,20 @@ type ServiceSpec struct { // "LoadBalancer" builds on NodePort and creates an // external load-balancer (if supported in the current cloud) which routes // to the clusterIP. - // More info: http://kubernetes.io/docs/user-guide/services#overview + // More info: https://kubernetes.io/docs/concepts/services-networking/service/ // +optional - Type ServiceType `json:"type,omitempty"` + Type ServiceType // Required: The list of ports that are exposed by this service. - Ports []ServicePort `json:"ports"` + Ports []ServicePort // Route service traffic to pods with label keys and values matching this // selector. If empty or not present, the service is assumed to have an // external process managing its endpoints, which Kubernetes will not // modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. // Ignored if type is ExternalName. - // More info: http://kubernetes.io/docs/user-guide/services#overview - Selector map[string]string `json:"selector"` + // More info: https://kubernetes.io/docs/concepts/services-networking/service/ + Selector map[string]string // ClusterIP is the IP address of the service and is usually assigned // randomly by the master. If an address is specified manually and is not in @@ -2221,9 +2641,9 @@ type ServiceSpec struct { // can be specified for headless services when proxying is not required. // Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if // type is ExternalName. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies // +optional - ClusterIP string `json:"clusterIP,omitempty"` + ClusterIP string // ExternalName is the external reference that kubedns or equivalent will // return as a CNAME record for this service. No proxying will be involved. @@ -2233,7 +2653,7 @@ type ServiceSpec struct { // ExternalIPs are used by external load balancers, or can be set by // users to handle external traffic that arrives at a node. // +optional - ExternalIPs []string `json:"externalIPs,omitempty"` + ExternalIPs []string // Only applies to Service Type: LoadBalancer // LoadBalancer will get created with the IP specified in this field. @@ -2241,17 +2661,34 @@ type ServiceSpec struct { // the loadBalancerIP when a load balancer is created. // This field will be ignored if the cloud-provider does not support the feature. // +optional - LoadBalancerIP string `json:"loadBalancerIP,omitempty"` + LoadBalancerIP string // Optional: Supports "ClientIP" and "None". Used to maintain session affinity. // +optional - SessionAffinity ServiceAffinity `json:"sessionAffinity,omitempty"` + SessionAffinity ServiceAffinity // Optional: If specified and supported by the platform, this will restrict traffic through the cloud-provider // load-balancer will be restricted to the specified client IPs. This field will be ignored if the // cloud-provider does not support the feature." // +optional - LoadBalancerSourceRanges []string `json:"loadBalancerSourceRanges,omitempty"` + LoadBalancerSourceRanges []string + + // externalTrafficPolicy denotes if this Service desires to route external + // traffic to node-local or cluster-wide endpoints. "Local" preserves the + // client source IP and avoids a second hop for LoadBalancer and Nodeport + // type services, but risks potentially imbalanced traffic spreading. + // "Cluster" obscures the client source IP and may cause a second hop to + // another node, but should have good overall load-spreading. + // +optional + ExternalTrafficPolicy ServiceExternalTrafficPolicyType + + // healthCheckNodePort specifies the healthcheck nodePort for the service. + // If not specified, HealthCheckNodePort is created by the service api + // backend with the allocated nodePort. Will use user-specified nodePort value + // if specified by the client. Only effects when Type is set to LoadBalancer + // and ExternalTrafficPolicy is set to Local. + // +optional + HealthCheckNodePort int32 } type ServicePort struct { @@ -2259,13 +2696,13 @@ type ServicePort struct { // name of this port within the service. This must be a DNS_LABEL. // All ports within a ServiceSpec must have unique names. This maps to // the 'Name' field in EndpointPort objects. - Name string `json:"name"` + Name string // The IP protocol for this port. Supports "TCP" and "UDP". - Protocol Protocol `json:"protocol"` + Protocol Protocol // The port that will be exposed on the service. - Port int32 `json:"port"` + Port int32 // Optional: The target port on pods selected by this service. If this // is a string, it will be looked up as a named port in the target @@ -2273,11 +2710,11 @@ type ServicePort struct { // of the 'port' field is used (an identity map). // This field is ignored for services with clusterIP=None, and should be // omitted or set equal to the 'port' field. - TargetPort intstr.IntOrString `json:"targetPort"` + TargetPort intstr.IntOrString // The port on each node on which this service is exposed. // Default is to auto-allocate a port if the ServiceType of this Service requires one. - NodePort int32 `json:"nodePort"` + NodePort int32 } // +genclient=true @@ -2286,17 +2723,17 @@ type ServicePort struct { // (for example 3306) that the proxy listens on, and the selector that determines which pods // will answer requests sent through the proxy. type Service struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the behavior of a service. // +optional - Spec ServiceSpec `json:"spec,omitempty"` + Spec ServiceSpec // Status represents the current status of a service. // +optional - Status ServiceStatus `json:"status,omitempty"` + Status ServiceStatus } // +genclient=true @@ -2306,27 +2743,32 @@ type Service struct { // * a principal that can be authenticated and authorized // * a set of secrets type ServiceAccount struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount - Secrets []ObjectReference `json:"secrets"` + Secrets []ObjectReference // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images // in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets // can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. // +optional - ImagePullSecrets []LocalObjectReference `json:"imagePullSecrets,omitempty"` + ImagePullSecrets []LocalObjectReference + + // AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. + // Can be overridden at the pod level. + // +optional + AutomountServiceAccountToken *bool } // ServiceAccountList is a list of ServiceAccount objects type ServiceAccountList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []ServiceAccount `json:"items"` + Items []ServiceAccount } // +genclient=true @@ -2344,9 +2786,9 @@ type ServiceAccountList struct { // }, // ] type Endpoints struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // The set of all endpoints is the union of all subsets. Subsets []EndpointSubset @@ -2378,10 +2820,10 @@ type EndpointAddress struct { // Optional: Hostname of this endpoint // Meant to be used by DNS servers etc. // +optional - Hostname string `json:"hostname,omitempty"` + Hostname string // Optional: Node hosting this endpoint. This can be used to determine endpoints local to a node. // +optional - NodeName *string `json:"nodeName,omitempty"` + NodeName *string // Optional: The kubernetes object related to the entry point. TargetRef *ObjectReference } @@ -2401,11 +2843,11 @@ type EndpointPort struct { // EndpointsList is a list of endpoints. type EndpointsList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Endpoints `json:"items"` + Items []Endpoints } // NodeSpec describes the attributes that a node is created with. @@ -2413,20 +2855,24 @@ type NodeSpec struct { // PodCIDR represents the pod IP range assigned to the node // Note: assigning IP ranges to nodes might need to be revisited when we support migratable IPs. // +optional - PodCIDR string `json:"podCIDR,omitempty"` + PodCIDR string // External ID of the node assigned by some machine database (e.g. a cloud provider) // +optional - ExternalID string `json:"externalID,omitempty"` + ExternalID string // ID of the node assigned by the cloud provider // Note: format is "://" // +optional - ProviderID string `json:"providerID,omitempty"` + ProviderID string // Unschedulable controls node schedulability of new pods. By default node is schedulable. // +optional - Unschedulable bool `json:"unschedulable,omitempty"` + Unschedulable bool + + // If specified, the node's taints. + // +optional + Taints []Taint } // DaemonEndpoint contains information about a single Daemon endpoint. @@ -2438,76 +2884,76 @@ type DaemonEndpoint struct { */ // Port number of the given endpoint. - Port int32 `json:"Port"` + Port int32 } // NodeDaemonEndpoints lists ports opened by daemons running on the Node. type NodeDaemonEndpoints struct { // Endpoint on which Kubelet is listening. // +optional - KubeletEndpoint DaemonEndpoint `json:"kubeletEndpoint,omitempty"` + KubeletEndpoint DaemonEndpoint } // NodeSystemInfo is a set of ids/uuids to uniquely identify the node. type NodeSystemInfo struct { // MachineID reported by the node. For unique machine identification - // in the cluster this field is prefered. Learn more from man(5) + // in the cluster this field is preferred. Learn more from man(5) // machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html - MachineID string `json:"machineID"` + MachineID string // SystemUUID reported by the node. For unique machine identification - // MachineID is prefered. This field is specific to Red Hat hosts + // MachineID is preferred. This field is specific to Red Hat hosts // https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html - SystemUUID string `json:"systemUUID"` + SystemUUID string // Boot ID reported by the node. - BootID string `json:"bootID"` + BootID string // Kernel Version reported by the node. - KernelVersion string `json:"kernelVersion"` + KernelVersion string // OS Image reported by the node. - OSImage string `json:"osImage"` + OSImage string // ContainerRuntime Version reported by the node. - ContainerRuntimeVersion string `json:"containerRuntimeVersion"` + ContainerRuntimeVersion string // Kubelet Version reported by the node. - KubeletVersion string `json:"kubeletVersion"` + KubeletVersion string // KubeProxy Version reported by the node. - KubeProxyVersion string `json:"kubeProxyVersion"` + KubeProxyVersion string // The Operating System reported by the node - OperatingSystem string `json:"operatingSystem"` + OperatingSystem string // The Architecture reported by the node - Architecture string `json:"architecture"` + Architecture string } // NodeStatus is information about the current status of a node. type NodeStatus struct { // Capacity represents the total resources of a node. // +optional - Capacity ResourceList `json:"capacity,omitempty"` + Capacity ResourceList // Allocatable represents the resources of a node that are available for scheduling. // +optional - Allocatable ResourceList `json:"allocatable,omitempty"` + Allocatable ResourceList // NodePhase is the current lifecycle phase of the node. // +optional - Phase NodePhase `json:"phase,omitempty"` + Phase NodePhase // Conditions is an array of current node conditions. // +optional - Conditions []NodeCondition `json:"conditions,omitempty"` + Conditions []NodeCondition // Queried from cloud provider, if available. // +optional - Addresses []NodeAddress `json:"addresses,omitempty"` + Addresses []NodeAddress // Endpoints of daemons running on the Node. // +optional - DaemonEndpoints NodeDaemonEndpoints `json:"daemonEndpoints,omitempty"` + DaemonEndpoints NodeDaemonEndpoints // Set of ids/uuids to uniquely identify the node. // +optional - NodeInfo NodeSystemInfo `json:"nodeInfo,omitempty"` + NodeInfo NodeSystemInfo // List of container images on this node // +optional - Images []ContainerImage `json:"images,omitempty"` + Images []ContainerImage // List of attachable volumes in use (mounted) by the node. // +optional - VolumesInUse []UniqueVolumeName `json:"volumesInUse,omitempty"` + VolumesInUse []UniqueVolumeName // List of volumes that are attached to the node. // +optional - VolumesAttached []AttachedVolume `json:"volumesAttached,omitempty"` + VolumesAttached []AttachedVolume } type UniqueVolumeName string @@ -2515,10 +2961,10 @@ type UniqueVolumeName string // AttachedVolume describes a volume attached to a node type AttachedVolume struct { // Name of the attached volume - Name UniqueVolumeName `json:"name"` + Name UniqueVolumeName // DevicePath represents the device path where the volume should be available - DevicePath string `json:"devicePath"` + DevicePath string } // AvoidPods describes pods that should avoid this node. This is the value for a @@ -2528,22 +2974,22 @@ type AvoidPods struct { // Bounded-sized list of signatures of pods that should avoid this node, sorted // in timestamp order from oldest to newest. Size of the slice is unspecified. // +optional - PreferAvoidPods []PreferAvoidPodsEntry `json:"preferAvoidPods,omitempty"` + PreferAvoidPods []PreferAvoidPodsEntry } // Describes a class of pods that should avoid this node. type PreferAvoidPodsEntry struct { // The class of pods. - PodSignature PodSignature `json:"podSignature"` + PodSignature PodSignature // Time at which this entry was added to the list. // +optional - EvictionTime unversioned.Time `json:"evictionTime,omitempty"` + EvictionTime metav1.Time // (brief) reason why this entry was added to the list. // +optional - Reason string `json:"reason,omitempty"` + Reason string // Human readable message indicating why this entry was added to the list. // +optional - Message string `json:"message,omitempty"` + Message string } // Describes the class of pods that should avoid this node. @@ -2551,16 +2997,16 @@ type PreferAvoidPodsEntry struct { type PodSignature struct { // Reference to controller whose pods should avoid this node. // +optional - PodController *OwnerReference `json:"podController,omitempty"` + PodController *metav1.OwnerReference } // Describe a container image type ContainerImage struct { // Names by which this image is known. - Names []string `json:"names"` + Names []string // The size of the image in bytes. // +optional - SizeBytes int64 `json:"sizeBytes,omitempty"` + SizeBytes int64 } type NodePhase string @@ -2595,33 +3041,31 @@ const ( ) type NodeCondition struct { - Type NodeConditionType `json:"type"` - Status ConditionStatus `json:"status"` + Type NodeConditionType + Status ConditionStatus // +optional - LastHeartbeatTime unversioned.Time `json:"lastHeartbeatTime,omitempty"` + LastHeartbeatTime metav1.Time // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"` + LastTransitionTime metav1.Time // +optional - Reason string `json:"reason,omitempty"` + Reason string // +optional - Message string `json:"message,omitempty"` + Message string } type NodeAddressType string -// These are valid address types of node. NodeLegacyHostIP is used to transit -// from out-dated HostIP field to NodeAddress. const ( - // Deprecated: NodeLegacyHostIP will be removed in 1.7. - NodeLegacyHostIP NodeAddressType = "LegacyHostIP" - NodeHostName NodeAddressType = "Hostname" - NodeExternalIP NodeAddressType = "ExternalIP" - NodeInternalIP NodeAddressType = "InternalIP" + NodeHostName NodeAddressType = "Hostname" + NodeExternalIP NodeAddressType = "ExternalIP" + NodeInternalIP NodeAddressType = "InternalIP" + NodeExternalDNS NodeAddressType = "ExternalDNS" + NodeInternalDNS NodeAddressType = "InternalDNS" ) type NodeAddress struct { - Type NodeAddressType `json:"type"` - Address string `json:"address"` + Type NodeAddressType + Address string } // NodeResources is an object for conveying resource information about a node. @@ -2629,7 +3073,7 @@ type NodeAddress struct { type NodeResources struct { // Capacity represents the available resources of a node // +optional - Capacity ResourceList `json:"capacity,omitempty"` + Capacity ResourceList } // ResourceName is the name identifying various resources in a ResourceList. @@ -2647,6 +3091,12 @@ const ( ResourceMemory ResourceName = "memory" // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024) ResourceStorage ResourceName = "storage" + // Local Storage for overlay filesystem, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageOverlay is alpha and it can change across releases. + ResourceStorageOverlay ResourceName = "storage.kubernetes.io/overlay" + // Local Storage for scratch space, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageScratch is alpha and it can change across releases. + ResourceStorageScratch ResourceName = "storage.kubernetes.io/scratch" // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned. ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu" // Number of Pods that may be running on this Node: see ResourcePods @@ -2666,26 +3116,26 @@ type ResourceList map[ResourceName]resource.Quantity // Node is a worker node in Kubernetes // The name of the node according to etcd is in ObjectMeta.Name. type Node struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the behavior of a node. // +optional - Spec NodeSpec `json:"spec,omitempty"` + Spec NodeSpec // Status describes the current status of a Node // +optional - Status NodeStatus `json:"status,omitempty"` + Status NodeStatus } // NodeList is a list of nodes. type NodeList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Node `json:"items"` + Items []Node } // NamespaceSpec describes the attributes on a Namespace @@ -2694,19 +3144,20 @@ type NamespaceSpec struct { Finalizers []FinalizerName } +// FinalizerName is the name identifying a finalizer during namespace lifecycle. type FinalizerName string -// These are internal finalizer values to Kubernetes, must be qualified name unless defined here +// These are internal finalizer values to Kubernetes, must be qualified name unless defined here or +// in metav1. const ( FinalizerKubernetes FinalizerName = "kubernetes" - FinalizerOrphan string = "orphan" ) // NamespaceStatus is information about the current status of a Namespace. type NamespaceStatus struct { // Phase is the current lifecycle phase of the namespace. // +optional - Phase NamespacePhase `json:"phase,omitempty"` + Phase NamespacePhase } type NamespacePhase string @@ -2725,92 +3176,114 @@ const ( // A namespace provides a scope for Names. // Use of multiple namespaces is optional type Namespace struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the behavior of the Namespace. // +optional - Spec NamespaceSpec `json:"spec,omitempty"` + Spec NamespaceSpec // Status describes the current status of a Namespace // +optional - Status NamespaceStatus `json:"status,omitempty"` + Status NamespaceStatus } // NamespaceList is a list of Namespaces. type NamespaceList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Namespace `json:"items"` + Items []Namespace } -// Binding ties one object to another - for example, a pod is bound to a node by a scheduler. +// Binding ties one object to another; for example, a pod is bound to a node by a scheduler. +// Deprecated in 1.7, please use the bindings subresource of pods instead. type Binding struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // ObjectMeta describes the object that is being bound. // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Target is the object to bind to. - Target ObjectReference `json:"target"` + Target ObjectReference } // Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. type Preconditions struct { // Specifies the target UID. // +optional - UID *types.UID `json:"uid,omitempty"` + UID *types.UID } +// DeletionPropagation decides whether and how garbage collection will be performed. +type DeletionPropagation string + +const ( + // Orphans the dependents. + DeletePropagationOrphan DeletionPropagation = "Orphan" + // Deletes the object from the key-value store, the garbage collector will delete the dependents in the background. + DeletePropagationBackground DeletionPropagation = "Background" + // The object exists in the key-value store until the garbage collector deletes all the dependents whose ownerReference.blockOwnerDeletion=true from the key-value store. + // API sever will put the "DeletingDependents" finalizer on the object, and sets its deletionTimestamp. + // This policy is cascading, i.e., the dependents will be deleted with Foreground. + DeletePropagationForeground DeletionPropagation = "Foreground" +) + // DeleteOptions may be provided when deleting an API object +// DEPRECATED: This type has been moved to meta/v1 and will be removed soon. type DeleteOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Optional duration in seconds before the object should be deleted. Value must be non-negative integer. // The value zero indicates delete immediately. If this value is nil, the default grace period for the // specified type will be used. // +optional - GracePeriodSeconds *int64 `json:"gracePeriodSeconds,omitempty"` + GracePeriodSeconds *int64 // Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be // returned. // +optional - Preconditions *Preconditions `json:"preconditions,omitempty"` + Preconditions *Preconditions + // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. // Should the dependent objects be orphaned. If true/false, the "orphan" // finalizer will be added to/removed from the object's finalizers list. + // Either this field or PropagationPolicy may be set, but not both. // +optional - OrphanDependents *bool `json:"orphanDependents,omitempty"` -} + OrphanDependents *bool -// ExportOptions is the query options to the standard REST get call. -type ExportOptions struct { - unversioned.TypeMeta `json:",inline"` - // Should this value be exported. Export strips fields that a user can not specify. - Export bool `json:"export"` - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' - Exact bool `json:"exact"` + // Whether and how garbage collection will be performed. + // Either this field or OrphanDependents may be set, but not both. + // The default policy is decided by the existing finalizer set in the + // metadata.finalizers and the resource-specific default policy. + // +optional + PropagationPolicy *DeletionPropagation } // ListOptions is the query options to a standard REST list call, and has future support for // watch calls. +// DEPRECATED: This type has been moved to meta/v1 and will be removed soon. type ListOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // A selector based on labels LabelSelector labels.Selector // A selector based on fields FieldSelector fields.Selector + + // If true, partially initialized resources are included in the response. + IncludeUninitialized bool + // If true, watch for changes to this list Watch bool - // For watch, it's the resource version to watch. - // For list, + // When specified with a watch call, shows changes that occur after that particular version of a resource. + // Defaults to changes from the beginning of history. + // When specified for list: // - if unset, then the result is returned from remote storage based on quorum-read flag; // - if it's 0, then we simply return what we currently have in cache, no guarantee; - // - if set to non zero, then the result is as fresh as given rv. + // - if set to non zero, then the result is at least as fresh as given rv. ResourceVersion string // Timeout for the list/watch call. TimeoutSeconds *int64 @@ -2818,7 +3291,7 @@ type ListOptions struct { // PodLogOptions is the query options for a Pod's logs REST call type PodLogOptions struct { - unversioned.TypeMeta + metav1.TypeMeta // Container for which to return logs Container string @@ -2835,7 +3308,7 @@ type PodLogOptions struct { // precedes the time a pod was started, only logs since the pod start will be returned. // If this value is in the future, no logs will be returned. // Only one of sinceSeconds or sinceTime may be specified. - SinceTime *unversioned.Time + SinceTime *metav1.Time // If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line // of log output. Timestamps bool @@ -2851,32 +3324,32 @@ type PodLogOptions struct { // PodAttachOptions is the query options to a Pod's remote attach call // TODO: merge w/ PodExecOptions below for stdin, stdout, etc type PodAttachOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Stdin if true indicates that stdin is to be redirected for the attach call // +optional - Stdin bool `json:"stdin,omitempty"` + Stdin bool // Stdout if true indicates that stdout is to be redirected for the attach call // +optional - Stdout bool `json:"stdout,omitempty"` + Stdout bool // Stderr if true indicates that stderr is to be redirected for the attach call // +optional - Stderr bool `json:"stderr,omitempty"` + Stderr bool // TTY if true indicates that a tty will be allocated for the attach call // +optional - TTY bool `json:"tty,omitempty"` + TTY bool // Container to attach to. // +optional - Container string `json:"container,omitempty"` + Container string } // PodExecOptions is the query options to a Pod's remote exec call type PodExecOptions struct { - unversioned.TypeMeta + metav1.TypeMeta // Stdin if true indicates that stdin is to be redirected for the exec call Stdin bool @@ -2897,9 +3370,18 @@ type PodExecOptions struct { Command []string } +// PodPortForwardOptions is the query options to a Pod's port forward call +type PodPortForwardOptions struct { + metav1.TypeMeta + + // The list of ports to forward + // +optional + Ports []int32 +} + // PodProxyOptions is the query options to a Pod's proxy call type PodProxyOptions struct { - unversioned.TypeMeta + metav1.TypeMeta // Path is the URL path to use for the current proxy request Path string @@ -2907,7 +3389,7 @@ type PodProxyOptions struct { // NodeProxyOptions is the query options to a Node's proxy call type NodeProxyOptions struct { - unversioned.TypeMeta + metav1.TypeMeta // Path is the URL path to use for the current proxy request Path string @@ -2915,7 +3397,7 @@ type NodeProxyOptions struct { // ServiceProxyOptions is the query options to a Service's proxy call. type ServiceProxyOptions struct { - unversioned.TypeMeta + metav1.TypeMeta // Path is the part of URLs that include service endpoints, suffixes, // and parameters to use for the current proxy request to service. @@ -2925,40 +3407,20 @@ type ServiceProxyOptions struct { Path string } -// OwnerReference contains enough information to let you identify an owning -// object. Currently, an owning object must be in the same namespace, so there -// is no namespace field. -type OwnerReference struct { - // API version of the referent. - APIVersion string `json:"apiVersion"` - // Kind of the referent. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - Kind string `json:"kind"` - // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names - Name string `json:"name"` - // UID of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids - UID types.UID `json:"uid"` - // If true, this reference points to the managing controller. - // +optional - Controller *bool `json:"controller,omitempty"` -} - // ObjectReference contains enough information to let you inspect or modify the referred object. type ObjectReference struct { // +optional - Kind string `json:"kind,omitempty"` + Kind string // +optional - Namespace string `json:"namespace,omitempty"` + Namespace string // +optional - Name string `json:"name,omitempty"` + Name string // +optional - UID types.UID `json:"uid,omitempty"` + UID types.UID // +optional - APIVersion string `json:"apiVersion,omitempty"` + APIVersion string // +optional - ResourceVersion string `json:"resourceVersion,omitempty"` + ResourceVersion string // Optional. If referring to a piece of an object instead of an entire object, this string // should contain information to identify the sub-object. For example, if the object @@ -2969,7 +3431,7 @@ type ObjectReference struct { // referencing a part of an object. // TODO: this design is not final and this field is subject to change in the future. // +optional - FieldPath string `json:"fieldPath,omitempty"` + FieldPath string } // LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace. @@ -2979,18 +3441,18 @@ type LocalObjectReference struct { } type SerializedReference struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - Reference ObjectReference `json:"reference,omitempty"` + Reference ObjectReference } type EventSource struct { // Component from which the event is generated. // +optional - Component string `json:"component,omitempty"` + Component string // Node name on which the event is generated. // +optional - Host string `json:"host,omitempty"` + Host string } // Valid values for event types (new types could be added in future) @@ -3006,63 +3468,63 @@ const ( // Event is a report of an event somewhere in the cluster. // TODO: Decide whether to store these separately or with the object they apply to. type Event struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Required. The object that this event is about. // +optional - InvolvedObject ObjectReference `json:"involvedObject,omitempty"` + InvolvedObject ObjectReference // Optional; this should be a short, machine understandable string that gives the reason // for this event being generated. For example, if the event is reporting that a container // can't start, the Reason might be "ImageNotFound". // TODO: provide exact specification for format. // +optional - Reason string `json:"reason,omitempty"` + Reason string // Optional. A human-readable description of the status of this operation. // TODO: decide on maximum length. // +optional - Message string `json:"message,omitempty"` + Message string // Optional. The component reporting this event. Should be a short machine understandable string. // +optional - Source EventSource `json:"source,omitempty"` + Source EventSource // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.) // +optional - FirstTimestamp unversioned.Time `json:"firstTimestamp,omitempty"` + FirstTimestamp metav1.Time // The time at which the most recent occurrence of this event was recorded. // +optional - LastTimestamp unversioned.Time `json:"lastTimestamp,omitempty"` + LastTimestamp metav1.Time // The number of times this event has occurred. // +optional - Count int32 `json:"count,omitempty"` + Count int32 // Type of this event (Normal, Warning), new types could be added in the future. // +optional - Type string `json:"type,omitempty"` + Type string } // EventList is a list of events. type EventList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Event `json:"items"` + Items []Event } // List holds a list of objects, which may not be known by the server. type List struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []runtime.Object `json:"items"` + Items []runtime.Object } // A type of object that is limited @@ -3081,51 +3543,51 @@ const ( type LimitRangeItem struct { // Type of resource that this limit applies to // +optional - Type LimitType `json:"type,omitempty"` + Type LimitType // Max usage constraints on this kind by resource name // +optional - Max ResourceList `json:"max,omitempty"` + Max ResourceList // Min usage constraints on this kind by resource name // +optional - Min ResourceList `json:"min,omitempty"` + Min ResourceList // Default resource requirement limit value by resource name. // +optional - Default ResourceList `json:"default,omitempty"` + Default ResourceList // DefaultRequest resource requirement request value by resource name. // +optional - DefaultRequest ResourceList `json:"defaultRequest,omitempty"` + DefaultRequest ResourceList // MaxLimitRequestRatio represents the max burst value for the named resource // +optional - MaxLimitRequestRatio ResourceList `json:"maxLimitRequestRatio,omitempty"` + MaxLimitRequestRatio ResourceList } // LimitRangeSpec defines a min/max usage limit for resources that match on kind type LimitRangeSpec struct { // Limits is the list of LimitRangeItem objects that are enforced - Limits []LimitRangeItem `json:"limits"` + Limits []LimitRangeItem } // +genclient=true // LimitRange sets resource usage limits for each kind of resource in a Namespace type LimitRange struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the limits enforced // +optional - Spec LimitRangeSpec `json:"spec,omitempty"` + Spec LimitRangeSpec } // LimitRangeList is a list of LimitRange items. type LimitRangeList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is a list of LimitRange objects - Items []LimitRange `json:"items"` + Items []LimitRange } // The following identify resource constants for Kubernetes object types @@ -3178,48 +3640,48 @@ const ( type ResourceQuotaSpec struct { // Hard is the set of desired hard limits for each named resource // +optional - Hard ResourceList `json:"hard,omitempty"` + Hard ResourceList // A collection of filters that must match each object tracked by a quota. // If not specified, the quota matches all objects. // +optional - Scopes []ResourceQuotaScope `json:"scopes,omitempty"` + Scopes []ResourceQuotaScope } // ResourceQuotaStatus defines the enforced hard limits and observed use type ResourceQuotaStatus struct { // Hard is the set of enforced hard limits for each named resource // +optional - Hard ResourceList `json:"hard,omitempty"` + Hard ResourceList // Used is the current observed total usage of the resource in the namespace // +optional - Used ResourceList `json:"used,omitempty"` + Used ResourceList } // +genclient=true // ResourceQuota sets aggregate quota restrictions enforced per namespace type ResourceQuota struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the desired quota // +optional - Spec ResourceQuotaSpec `json:"spec,omitempty"` + Spec ResourceQuotaSpec // Status defines the actual enforced quota and its current usage // +optional - Status ResourceQuotaStatus `json:"status,omitempty"` + Status ResourceQuotaStatus } // ResourceQuotaList is a list of ResourceQuota items type ResourceQuotaList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is a list of ResourceQuota objects - Items []ResourceQuota `json:"items"` + Items []ResourceQuota } // +genclient=true @@ -3227,20 +3689,20 @@ type ResourceQuotaList struct { // Secret holds secret data of a certain type. The total bytes of the values in // the Data field must be less than MaxSecretSize bytes. type Secret struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN - // or leading dot followed by valid DNS_SUBDOMAIN. - // The serialized form of the secret data is a base64 encoded string, - // representing the arbitrary (possibly non-string) data value here. + // Data contains the secret data. Each key must consist of alphanumeric + // characters, '-', '_' or '.'. The serialized form of the secret data is a + // base64 encoded string, representing the arbitrary (possibly non-string) + // data value here. // +optional - Data map[string][]byte `json:"data,omitempty"` + Data map[string][]byte // Used to facilitate programmatic handling of secret data. // +optional - Type SecretType `json:"type,omitempty"` + Type SecretType } const MaxSecretSize = 1 * 1024 * 1024 @@ -3328,35 +3790,35 @@ const ( ) type SecretList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []Secret `json:"items"` + Items []Secret } // +genclient=true // ConfigMap holds configuration data for components or applications to consume. type ConfigMap struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Data contains the configuration data. - // Each key must be a valid DNS_SUBDOMAIN with an optional leading dot. + // Each key must consist of alphanumeric characters, '-', '_' or '.'. // +optional - Data map[string]string `json:"data,omitempty"` + Data map[string]string } // ConfigMapList is a resource containing a list of ConfigMap objects. type ConfigMapList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is the list of ConfigMaps. - Items []ConfigMap `json:"items"` + Items []ConfigMap } // These constants are for remote command execution and port forwarding and are @@ -3400,17 +3862,6 @@ const ( PortForwardRequestIDHeader = "requestID" ) -// Similarly to above, these are constants to support HTTP PATCH utilized by -// both the client and server that didn't make sense for a whole package to be -// dedicated to. -type PatchType string - -const ( - JSONPatchType PatchType = "application/json-patch+json" - MergePatchType PatchType = "application/merge-patch+json" - StrategicMergePatchType PatchType = "application/strategic-merge-patch+json" -) - // Type and constants for component health validation. type ComponentConditionType string @@ -3420,12 +3871,12 @@ const ( ) type ComponentCondition struct { - Type ComponentConditionType `json:"type"` - Status ConditionStatus `json:"status"` + Type ComponentConditionType + Status ConditionStatus // +optional - Message string `json:"message,omitempty"` + Message string // +optional - Error string `json:"error,omitempty"` + Error string } // +genclient=true @@ -3433,20 +3884,20 @@ type ComponentCondition struct { // ComponentStatus (and ComponentStatusList) holds the cluster validation info. type ComponentStatus struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // +optional - Conditions []ComponentCondition `json:"conditions,omitempty"` + Conditions []ComponentCondition } type ComponentStatusList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []ComponentStatus `json:"items"` + Items []ComponentStatus } // SecurityContext holds security configuration that will be applied to a container. @@ -3456,24 +3907,24 @@ type SecurityContext struct { // The capabilities to add/drop when running containers. // Defaults to the default set of capabilities granted by the container runtime. // +optional - Capabilities *Capabilities `json:"capabilities,omitempty"` + Capabilities *Capabilities // Run container in privileged mode. // Processes in privileged containers are essentially equivalent to root on the host. // Defaults to false. // +optional - Privileged *bool `json:"privileged,omitempty"` + Privileged *bool // The SELinux context to be applied to the container. // If unspecified, the container runtime will allocate a random SELinux context for each // container. May also be set in PodSecurityContext. If set in both SecurityContext and // PodSecurityContext, the value specified in SecurityContext takes precedence. // +optional - SELinuxOptions *SELinuxOptions `json:"seLinuxOptions,omitempty"` + SELinuxOptions *SELinuxOptions // The UID to run the entrypoint of the container process. // Defaults to user specified in image metadata if unspecified. // May also be set in PodSecurityContext. If set in both SecurityContext and // PodSecurityContext, the value specified in SecurityContext takes precedence. // +optional - RunAsUser *int64 `json:"runAsUser,omitempty"` + RunAsUser *int64 // Indicates that the container must run as a non-root user. // If true, the Kubelet will validate the image at runtime to ensure that it // does not run as UID 0 (root) and fail to start the container if it does. @@ -3481,27 +3932,27 @@ type SecurityContext struct { // May also be set in PodSecurityContext. If set in both SecurityContext and // PodSecurityContext, the value specified in SecurityContext takes precedence. // +optional - RunAsNonRoot *bool `json:"runAsNonRoot,omitempty"` + RunAsNonRoot *bool // The read-only root filesystem allows you to restrict the locations that an application can write // files to, ensuring the persistent data can only be written to mounts. // +optional - ReadOnlyRootFilesystem *bool `json:"readOnlyRootFilesystem,omitempty"` + ReadOnlyRootFilesystem *bool } // SELinuxOptions are the labels to be applied to the container. type SELinuxOptions struct { // SELinux user label // +optional - User string `json:"user,omitempty"` + User string // SELinux role label // +optional - Role string `json:"role,omitempty"` + Role string // SELinux type label // +optional - Type string `json:"type,omitempty"` + Type string // SELinux level label. // +optional - Level string `json:"level,omitempty"` + Level string } // RangeAllocation is an opaque API object (not exposed to end users) that can be persisted to record @@ -3512,18 +3963,18 @@ type SELinuxOptions struct { // data encoding hints). A range allocation should *ALWAYS* be recreatable at any time by observation // of the cluster, thus the object is less strongly typed than most. type RangeAllocation struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // A string representing a unique label for a range of resources, such as a CIDR "10.0.0.0/8" or // port range "10000-30000". Range is not strongly schema'd here. The Range is expected to define // a start and end unless there is an implicit end. - Range string `json:"range"` + Range string // A byte array representing the serialized state of a range allocation. Additional clarifiers on // the type or format of data should be represented with annotations. For IP allocations, this is // represented as a bit array starting at the base IP of the CIDR in Range, with each bit representing // a single allocated address (the fifth bit on CIDR 10.0.0.0/8 is 10.0.0.4). - Data []byte `json:"data"` + Data []byte } const ( @@ -3535,8 +3986,4 @@ const ( // When the --hard-pod-affinity-weight scheduler flag is not specified, // DefaultHardPodAffinityWeight defines the weight of the implicit PreferredDuringScheduling affinity rule. DefaultHardPodAffinitySymmetricWeight int = 1 - - // When the --failure-domains scheduler flag is not specified, - // DefaultFailureDomains defines the set of label keys used when TopologyKey is empty in PreferredDuringScheduling anti-affinity. - DefaultFailureDomains string = unversioned.LabelHostname + "," + unversioned.LabelZoneFailureDomain + "," + unversioned.LabelZoneRegion ) diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/generated.pb.go b/vendor/k8s.io/client-go/pkg/api/unversioned/generated.pb.go deleted file mode 100644 index a50052dace..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/generated.pb.go +++ /dev/null @@ -1,4537 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Code generated by protoc-gen-gogo. -// source: k8s.io/kubernetes/pkg/api/unversioned/generated.proto -// DO NOT EDIT! - -/* - Package unversioned is a generated protocol buffer package. - - It is generated from these files: - k8s.io/kubernetes/pkg/api/unversioned/generated.proto - - It has these top-level messages: - APIGroup - APIGroupList - APIResource - APIResourceList - APIVersions - Duration - ExportOptions - GroupKind - GroupResource - GroupVersion - GroupVersionForDiscovery - GroupVersionKind - GroupVersionResource - LabelSelector - LabelSelectorRequirement - ListMeta - RootPaths - ServerAddressByClientCIDR - Status - StatusCause - StatusDetails - Time - Timestamp - TypeMeta -*/ -package unversioned - -import proto "github.com/gogo/protobuf/proto" -import fmt "fmt" -import math "math" - -import time "time" - -import strings "strings" -import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" - -import io "io" - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 - -func (m *APIGroup) Reset() { *m = APIGroup{} } -func (*APIGroup) ProtoMessage() {} -func (*APIGroup) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } - -func (m *APIGroupList) Reset() { *m = APIGroupList{} } -func (*APIGroupList) ProtoMessage() {} -func (*APIGroupList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } - -func (m *APIResource) Reset() { *m = APIResource{} } -func (*APIResource) ProtoMessage() {} -func (*APIResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } - -func (m *APIResourceList) Reset() { *m = APIResourceList{} } -func (*APIResourceList) ProtoMessage() {} -func (*APIResourceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } - -func (m *APIVersions) Reset() { *m = APIVersions{} } -func (*APIVersions) ProtoMessage() {} -func (*APIVersions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } - -func (m *Duration) Reset() { *m = Duration{} } -func (*Duration) ProtoMessage() {} -func (*Duration) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } - -func (m *ExportOptions) Reset() { *m = ExportOptions{} } -func (*ExportOptions) ProtoMessage() {} -func (*ExportOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } - -func (m *GroupKind) Reset() { *m = GroupKind{} } -func (*GroupKind) ProtoMessage() {} -func (*GroupKind) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } - -func (m *GroupResource) Reset() { *m = GroupResource{} } -func (*GroupResource) ProtoMessage() {} -func (*GroupResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } - -func (m *GroupVersion) Reset() { *m = GroupVersion{} } -func (*GroupVersion) ProtoMessage() {} -func (*GroupVersion) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } - -func (m *GroupVersionForDiscovery) Reset() { *m = GroupVersionForDiscovery{} } -func (*GroupVersionForDiscovery) ProtoMessage() {} -func (*GroupVersionForDiscovery) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{10} -} - -func (m *GroupVersionKind) Reset() { *m = GroupVersionKind{} } -func (*GroupVersionKind) ProtoMessage() {} -func (*GroupVersionKind) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } - -func (m *GroupVersionResource) Reset() { *m = GroupVersionResource{} } -func (*GroupVersionResource) ProtoMessage() {} -func (*GroupVersionResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } - -func (m *LabelSelector) Reset() { *m = LabelSelector{} } -func (*LabelSelector) ProtoMessage() {} -func (*LabelSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } - -func (m *LabelSelectorRequirement) Reset() { *m = LabelSelectorRequirement{} } -func (*LabelSelectorRequirement) ProtoMessage() {} -func (*LabelSelectorRequirement) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{14} -} - -func (m *ListMeta) Reset() { *m = ListMeta{} } -func (*ListMeta) ProtoMessage() {} -func (*ListMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } - -func (m *RootPaths) Reset() { *m = RootPaths{} } -func (*RootPaths) ProtoMessage() {} -func (*RootPaths) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } - -func (m *ServerAddressByClientCIDR) Reset() { *m = ServerAddressByClientCIDR{} } -func (*ServerAddressByClientCIDR) ProtoMessage() {} -func (*ServerAddressByClientCIDR) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{17} -} - -func (m *Status) Reset() { *m = Status{} } -func (*Status) ProtoMessage() {} -func (*Status) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} } - -func (m *StatusCause) Reset() { *m = StatusCause{} } -func (*StatusCause) ProtoMessage() {} -func (*StatusCause) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{19} } - -func (m *StatusDetails) Reset() { *m = StatusDetails{} } -func (*StatusDetails) ProtoMessage() {} -func (*StatusDetails) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } - -func (m *Time) Reset() { *m = Time{} } -func (*Time) ProtoMessage() {} -func (*Time) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } - -func (m *Timestamp) Reset() { *m = Timestamp{} } -func (*Timestamp) ProtoMessage() {} -func (*Timestamp) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{22} } - -func (m *TypeMeta) Reset() { *m = TypeMeta{} } -func (*TypeMeta) ProtoMessage() {} -func (*TypeMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } - -func init() { - proto.RegisterType((*APIGroup)(nil), "k8s.io.client-go.pkg.api.unversioned.APIGroup") - proto.RegisterType((*APIGroupList)(nil), "k8s.io.client-go.pkg.api.unversioned.APIGroupList") - proto.RegisterType((*APIResource)(nil), "k8s.io.client-go.pkg.api.unversioned.APIResource") - proto.RegisterType((*APIResourceList)(nil), "k8s.io.client-go.pkg.api.unversioned.APIResourceList") - proto.RegisterType((*APIVersions)(nil), "k8s.io.client-go.pkg.api.unversioned.APIVersions") - proto.RegisterType((*Duration)(nil), "k8s.io.client-go.pkg.api.unversioned.Duration") - proto.RegisterType((*ExportOptions)(nil), "k8s.io.client-go.pkg.api.unversioned.ExportOptions") - proto.RegisterType((*GroupKind)(nil), "k8s.io.client-go.pkg.api.unversioned.GroupKind") - proto.RegisterType((*GroupResource)(nil), "k8s.io.client-go.pkg.api.unversioned.GroupResource") - proto.RegisterType((*GroupVersion)(nil), "k8s.io.client-go.pkg.api.unversioned.GroupVersion") - proto.RegisterType((*GroupVersionForDiscovery)(nil), "k8s.io.client-go.pkg.api.unversioned.GroupVersionForDiscovery") - proto.RegisterType((*GroupVersionKind)(nil), "k8s.io.client-go.pkg.api.unversioned.GroupVersionKind") - proto.RegisterType((*GroupVersionResource)(nil), "k8s.io.client-go.pkg.api.unversioned.GroupVersionResource") - proto.RegisterType((*LabelSelector)(nil), "k8s.io.client-go.pkg.api.unversioned.LabelSelector") - proto.RegisterType((*LabelSelectorRequirement)(nil), "k8s.io.client-go.pkg.api.unversioned.LabelSelectorRequirement") - proto.RegisterType((*ListMeta)(nil), "k8s.io.client-go.pkg.api.unversioned.ListMeta") - proto.RegisterType((*RootPaths)(nil), "k8s.io.client-go.pkg.api.unversioned.RootPaths") - proto.RegisterType((*ServerAddressByClientCIDR)(nil), "k8s.io.client-go.pkg.api.unversioned.ServerAddressByClientCIDR") - proto.RegisterType((*Status)(nil), "k8s.io.client-go.pkg.api.unversioned.Status") - proto.RegisterType((*StatusCause)(nil), "k8s.io.client-go.pkg.api.unversioned.StatusCause") - proto.RegisterType((*StatusDetails)(nil), "k8s.io.client-go.pkg.api.unversioned.StatusDetails") - proto.RegisterType((*Time)(nil), "k8s.io.client-go.pkg.api.unversioned.Time") - proto.RegisterType((*Timestamp)(nil), "k8s.io.client-go.pkg.api.unversioned.Timestamp") - proto.RegisterType((*TypeMeta)(nil), "k8s.io.client-go.pkg.api.unversioned.TypeMeta") -} -func (m *APIGroup) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *APIGroup) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - if len(m.Versions) > 0 { - for _, msg := range m.Versions { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.PreferredVersion.Size())) - n1, err := m.PreferredVersion.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n1 - if len(m.ServerAddressByClientCIDRs) > 0 { - for _, msg := range m.ServerAddressByClientCIDRs { - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *APIGroupList) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *APIGroupList) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Groups) > 0 { - for _, msg := range m.Groups { - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *APIResource) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *APIResource) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x10 - i++ - if m.Namespaced { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - return i, nil -} - -func (m *APIResourceList) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *APIResourceList) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.GroupVersion))) - i += copy(data[i:], m.GroupVersion) - if len(m.APIResources) > 0 { - for _, msg := range m.APIResources { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *APIVersions) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *APIVersions) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Versions) > 0 { - for _, s := range m.Versions { - data[i] = 0xa - i++ - l = len(s) - for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) - l >>= 7 - i++ - } - data[i] = uint8(l) - i++ - i += copy(data[i:], s) - } - } - if len(m.ServerAddressByClientCIDRs) > 0 { - for _, msg := range m.ServerAddressByClientCIDRs { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *Duration) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *Duration) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0x8 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Duration)) - return i, nil -} - -func (m *ExportOptions) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *ExportOptions) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0x8 - i++ - if m.Export { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - data[i] = 0x10 - i++ - if m.Exact { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - return i, nil -} - -func (m *GroupKind) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *GroupKind) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - return i, nil -} - -func (m *GroupResource) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *GroupResource) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Resource))) - i += copy(data[i:], m.Resource) - return i, nil -} - -func (m *GroupVersion) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *GroupVersion) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Version))) - i += copy(data[i:], m.Version) - return i, nil -} - -func (m *GroupVersionForDiscovery) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *GroupVersionForDiscovery) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.GroupVersion))) - i += copy(data[i:], m.GroupVersion) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Version))) - i += copy(data[i:], m.Version) - return i, nil -} - -func (m *GroupVersionKind) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *GroupVersionKind) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Version))) - i += copy(data[i:], m.Version) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - return i, nil -} - -func (m *GroupVersionResource) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *GroupVersionResource) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Version))) - i += copy(data[i:], m.Version) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Resource))) - i += copy(data[i:], m.Resource) - return i, nil -} - -func (m *LabelSelector) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *LabelSelector) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.MatchLabels) > 0 { - for k := range m.MatchLabels { - data[i] = 0xa - i++ - v := m.MatchLabels[k] - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) - } - } - if len(m.MatchExpressions) > 0 { - for _, msg := range m.MatchExpressions { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *LabelSelectorRequirement) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *LabelSelectorRequirement) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Operator))) - i += copy(data[i:], m.Operator) - if len(m.Values) > 0 { - for _, s := range m.Values { - data[i] = 0x1a - i++ - l = len(s) - for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) - l >>= 7 - i++ - } - data[i] = uint8(l) - i++ - i += copy(data[i:], s) - } - } - return i, nil -} - -func (m *ListMeta) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *ListMeta) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SelfLink))) - i += copy(data[i:], m.SelfLink) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion))) - i += copy(data[i:], m.ResourceVersion) - return i, nil -} - -func (m *RootPaths) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *RootPaths) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Paths) > 0 { - for _, s := range m.Paths { - data[i] = 0xa - i++ - l = len(s) - for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) - l >>= 7 - i++ - } - data[i] = uint8(l) - i++ - i += copy(data[i:], s) - } - } - return i, nil -} - -func (m *ServerAddressByClientCIDR) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *ServerAddressByClientCIDR) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ClientCIDR))) - i += copy(data[i:], m.ClientCIDR) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ServerAddress))) - i += copy(data[i:], m.ServerAddress) - return i, nil -} - -func (m *Status) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *Status) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n2, err := m.ListMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n2 - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - if m.Details != nil { - data[i] = 0x2a - i++ - i = encodeVarintGenerated(data, i, uint64(m.Details.Size())) - n3, err := m.Details.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n3 - } - data[i] = 0x30 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Code)) - return i, nil -} - -func (m *StatusCause) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *StatusCause) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Field))) - i += copy(data[i:], m.Field) - return i, nil -} - -func (m *StatusDetails) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *StatusDetails) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - if len(m.Causes) > 0 { - for _, msg := range m.Causes { - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - data[i] = 0x28 - i++ - i = encodeVarintGenerated(data, i, uint64(m.RetryAfterSeconds)) - return i, nil -} - -func (m *Timestamp) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *Timestamp) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0x8 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Seconds)) - data[i] = 0x10 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Nanos)) - return i, nil -} - -func (m *TypeMeta) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *TypeMeta) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - return i, nil -} - -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) - return offset + 8 -} -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - return offset + 4 -} -func encodeVarintGenerated(data []byte, offset int, v uint64) int { - for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - data[offset] = uint8(v) - return offset + 1 -} -func (m *APIGroup) Size() (n int) { - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Versions) > 0 { - for _, e := range m.Versions { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - l = m.PreferredVersion.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.ServerAddressByClientCIDRs) > 0 { - for _, e := range m.ServerAddressByClientCIDRs { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *APIGroupList) Size() (n int) { - var l int - _ = l - if len(m.Groups) > 0 { - for _, e := range m.Groups { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *APIResource) Size() (n int) { - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - n += 2 - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *APIResourceList) Size() (n int) { - var l int - _ = l - l = len(m.GroupVersion) - n += 1 + l + sovGenerated(uint64(l)) - if len(m.APIResources) > 0 { - for _, e := range m.APIResources { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *APIVersions) Size() (n int) { - var l int - _ = l - if len(m.Versions) > 0 { - for _, s := range m.Versions { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } - } - if len(m.ServerAddressByClientCIDRs) > 0 { - for _, e := range m.ServerAddressByClientCIDRs { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *Duration) Size() (n int) { - var l int - _ = l - n += 1 + sovGenerated(uint64(m.Duration)) - return n -} - -func (m *ExportOptions) Size() (n int) { - var l int - _ = l - n += 2 - n += 2 - return n -} - -func (m *GroupKind) Size() (n int) { - var l int - _ = l - l = len(m.Group) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *GroupResource) Size() (n int) { - var l int - _ = l - l = len(m.Group) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Resource) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *GroupVersion) Size() (n int) { - var l int - _ = l - l = len(m.Group) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *GroupVersionForDiscovery) Size() (n int) { - var l int - _ = l - l = len(m.GroupVersion) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *GroupVersionKind) Size() (n int) { - var l int - _ = l - l = len(m.Group) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *GroupVersionResource) Size() (n int) { - var l int - _ = l - l = len(m.Group) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Version) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Resource) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *LabelSelector) Size() (n int) { - var l int - _ = l - if len(m.MatchLabels) > 0 { - for k, v := range m.MatchLabels { - _ = k - _ = v - mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) - } - } - if len(m.MatchExpressions) > 0 { - for _, e := range m.MatchExpressions { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *LabelSelectorRequirement) Size() (n int) { - var l int - _ = l - l = len(m.Key) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Operator) - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Values) > 0 { - for _, s := range m.Values { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *ListMeta) Size() (n int) { - var l int - _ = l - l = len(m.SelfLink) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.ResourceVersion) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *RootPaths) Size() (n int) { - var l int - _ = l - if len(m.Paths) > 0 { - for _, s := range m.Paths { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *ServerAddressByClientCIDR) Size() (n int) { - var l int - _ = l - l = len(m.ClientCIDR) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.ServerAddress) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *Status) Size() (n int) { - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Status) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Message) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Reason) - n += 1 + l + sovGenerated(uint64(l)) - if m.Details != nil { - l = m.Details.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - n += 1 + sovGenerated(uint64(m.Code)) - return n -} - -func (m *StatusCause) Size() (n int) { - var l int - _ = l - l = len(m.Type) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Message) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Field) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *StatusDetails) Size() (n int) { - var l int - _ = l - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Group) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Causes) > 0 { - for _, e := range m.Causes { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - n += 1 + sovGenerated(uint64(m.RetryAfterSeconds)) - return n -} - -func (m *Timestamp) Size() (n int) { - var l int - _ = l - n += 1 + sovGenerated(uint64(m.Seconds)) - n += 1 + sovGenerated(uint64(m.Nanos)) - return n -} - -func (m *TypeMeta) Size() (n int) { - var l int - _ = l - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.APIVersion) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func sovGenerated(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } - } - return n -} -func sozGenerated(x uint64) (n int) { - return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (this *APIGroup) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&APIGroup{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Versions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Versions), "GroupVersionForDiscovery", "GroupVersionForDiscovery", 1), `&`, ``, 1) + `,`, - `PreferredVersion:` + strings.Replace(strings.Replace(this.PreferredVersion.String(), "GroupVersionForDiscovery", "GroupVersionForDiscovery", 1), `&`, ``, 1) + `,`, - `ServerAddressByClientCIDRs:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ServerAddressByClientCIDRs), "ServerAddressByClientCIDR", "ServerAddressByClientCIDR", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *APIGroupList) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&APIGroupList{`, - `Groups:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Groups), "APIGroup", "APIGroup", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *APIResource) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&APIResource{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Namespaced:` + fmt.Sprintf("%v", this.Namespaced) + `,`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `}`, - }, "") - return s -} -func (this *APIResourceList) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&APIResourceList{`, - `GroupVersion:` + fmt.Sprintf("%v", this.GroupVersion) + `,`, - `APIResources:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.APIResources), "APIResource", "APIResource", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *Duration) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Duration{`, - `Duration:` + fmt.Sprintf("%v", this.Duration) + `,`, - `}`, - }, "") - return s -} -func (this *ExportOptions) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ExportOptions{`, - `Export:` + fmt.Sprintf("%v", this.Export) + `,`, - `Exact:` + fmt.Sprintf("%v", this.Exact) + `,`, - `}`, - }, "") - return s -} -func (this *GroupVersionForDiscovery) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&GroupVersionForDiscovery{`, - `GroupVersion:` + fmt.Sprintf("%v", this.GroupVersion) + `,`, - `Version:` + fmt.Sprintf("%v", this.Version) + `,`, - `}`, - }, "") - return s -} -func (this *LabelSelector) String() string { - if this == nil { - return "nil" - } - keysForMatchLabels := make([]string, 0, len(this.MatchLabels)) - for k := range this.MatchLabels { - keysForMatchLabels = append(keysForMatchLabels, k) - } - github_com_gogo_protobuf_sortkeys.Strings(keysForMatchLabels) - mapStringForMatchLabels := "map[string]string{" - for _, k := range keysForMatchLabels { - mapStringForMatchLabels += fmt.Sprintf("%v: %v,", k, this.MatchLabels[k]) - } - mapStringForMatchLabels += "}" - s := strings.Join([]string{`&LabelSelector{`, - `MatchLabels:` + mapStringForMatchLabels + `,`, - `MatchExpressions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.MatchExpressions), "LabelSelectorRequirement", "LabelSelectorRequirement", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *LabelSelectorRequirement) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&LabelSelectorRequirement{`, - `Key:` + fmt.Sprintf("%v", this.Key) + `,`, - `Operator:` + fmt.Sprintf("%v", this.Operator) + `,`, - `Values:` + fmt.Sprintf("%v", this.Values) + `,`, - `}`, - }, "") - return s -} -func (this *ListMeta) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ListMeta{`, - `SelfLink:` + fmt.Sprintf("%v", this.SelfLink) + `,`, - `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, - `}`, - }, "") - return s -} -func (this *RootPaths) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&RootPaths{`, - `Paths:` + fmt.Sprintf("%v", this.Paths) + `,`, - `}`, - }, "") - return s -} -func (this *ServerAddressByClientCIDR) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ServerAddressByClientCIDR{`, - `ClientCIDR:` + fmt.Sprintf("%v", this.ClientCIDR) + `,`, - `ServerAddress:` + fmt.Sprintf("%v", this.ServerAddress) + `,`, - `}`, - }, "") - return s -} -func (this *Status) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Status{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "ListMeta", 1), `&`, ``, 1) + `,`, - `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, - `Details:` + strings.Replace(fmt.Sprintf("%v", this.Details), "StatusDetails", "StatusDetails", 1) + `,`, - `Code:` + fmt.Sprintf("%v", this.Code) + `,`, - `}`, - }, "") - return s -} -func (this *StatusCause) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&StatusCause{`, - `Type:` + fmt.Sprintf("%v", this.Type) + `,`, - `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `Field:` + fmt.Sprintf("%v", this.Field) + `,`, - `}`, - }, "") - return s -} -func (this *StatusDetails) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&StatusDetails{`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `Group:` + fmt.Sprintf("%v", this.Group) + `,`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `Causes:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Causes), "StatusCause", "StatusCause", 1), `&`, ``, 1) + `,`, - `RetryAfterSeconds:` + fmt.Sprintf("%v", this.RetryAfterSeconds) + `,`, - `}`, - }, "") - return s -} -func (this *Timestamp) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Timestamp{`, - `Seconds:` + fmt.Sprintf("%v", this.Seconds) + `,`, - `Nanos:` + fmt.Sprintf("%v", this.Nanos) + `,`, - `}`, - }, "") - return s -} -func (this *TypeMeta) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&TypeMeta{`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`, - `}`, - }, "") - return s -} -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" - } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) -} -func (m *APIGroup) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: APIGroup: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: APIGroup: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Versions", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Versions = append(m.Versions, GroupVersionForDiscovery{}) - if err := m.Versions[len(m.Versions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PreferredVersion", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.PreferredVersion.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServerAddressByClientCIDRs", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ServerAddressByClientCIDRs = append(m.ServerAddressByClientCIDRs, ServerAddressByClientCIDR{}) - if err := m.ServerAddressByClientCIDRs[len(m.ServerAddressByClientCIDRs)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *APIGroupList) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: APIGroupList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: APIGroupList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Groups", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Groups = append(m.Groups, APIGroup{}) - if err := m.Groups[len(m.Groups)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *APIResource) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: APIResource: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: APIResource: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Namespaced", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.Namespaced = bool(v != 0) - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *APIResourceList) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: APIResourceList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: APIResourceList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field GroupVersion", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.GroupVersion = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field APIResources", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.APIResources = append(m.APIResources, APIResource{}) - if err := m.APIResources[len(m.APIResources)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *APIVersions) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: APIVersions: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: APIVersions: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Versions", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Versions = append(m.Versions, string(data[iNdEx:postIndex])) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServerAddressByClientCIDRs", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ServerAddressByClientCIDRs = append(m.ServerAddressByClientCIDRs, ServerAddressByClientCIDR{}) - if err := m.ServerAddressByClientCIDRs[len(m.ServerAddressByClientCIDRs)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Duration) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Duration: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Duration: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Duration", wireType) - } - m.Duration = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Duration |= (time.Duration(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ExportOptions) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ExportOptions: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ExportOptions: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Export", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.Export = bool(v != 0) - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Exact", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.Exact = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *GroupKind) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: GroupKind: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: GroupKind: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Group = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *GroupResource) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: GroupResource: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: GroupResource: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Group = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Resource = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *GroupVersion) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: GroupVersion: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: GroupVersion: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Group = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Version = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *GroupVersionForDiscovery) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: GroupVersionForDiscovery: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: GroupVersionForDiscovery: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field GroupVersion", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.GroupVersion = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Version = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *GroupVersionKind) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: GroupVersionKind: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: GroupVersionKind: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Group = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Version = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *GroupVersionResource) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: GroupVersionResource: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: GroupVersionResource: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Group = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Version = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Resource = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *LabelSelector) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: LabelSelector: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: LabelSelector: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MatchLabels", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey := string(data[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.MatchLabels == nil { - m.MatchLabels = make(map[string]string) - } - m.MatchLabels[mapkey] = mapvalue - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MatchExpressions", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.MatchExpressions = append(m.MatchExpressions, LabelSelectorRequirement{}) - if err := m.MatchExpressions[len(m.MatchExpressions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *LabelSelectorRequirement) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: LabelSelectorRequirement: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: LabelSelectorRequirement: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Key = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Operator", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Operator = LabelSelectorOperator(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Values", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Values = append(m.Values, string(data[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ListMeta) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ListMeta: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ListMeta: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SelfLink", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.SelfLink = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ResourceVersion", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ResourceVersion = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *RootPaths) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: RootPaths: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: RootPaths: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Paths = append(m.Paths, string(data[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *ServerAddressByClientCIDR) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: ServerAddressByClientCIDR: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: ServerAddressByClientCIDR: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClientCIDR", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ClientCIDR = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServerAddress", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ServerAddress = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Status) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Status: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Status: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Status = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Reason = StatusReason(data[iNdEx:postIndex]) - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Details", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Details == nil { - m.Details = &StatusDetails{} - } - if err := m.Details.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType) - } - m.Code = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Code |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StatusCause) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StatusCause: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StatusCause: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Type = CauseType(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Field", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Field = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StatusDetails) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StatusDetails: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StatusDetails: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Name = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Group = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Causes", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Causes = append(m.Causes, StatusCause{}) - if err := m.Causes[len(m.Causes)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field RetryAfterSeconds", wireType) - } - m.RetryAfterSeconds = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.RetryAfterSeconds |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Timestamp) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Timestamp: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Timestamp: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Seconds", wireType) - } - m.Seconds = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Seconds |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Nanos", wireType) - } - m.Nanos = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Nanos |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TypeMeta) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: TypeMeta: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TypeMeta: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.APIVersion = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipGenerated(data []byte) (n int, err error) { - l := len(data) - iNdEx := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if data[iNdEx-1] < 0x80 { - break - } - } - return iNdEx, nil - case 1: - iNdEx += 8 - return iNdEx, nil - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - iNdEx += length - if length < 0 { - return 0, ErrInvalidLengthGenerated - } - return iNdEx, nil - case 3: - for { - var innerWire uint64 - var start int = iNdEx - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - innerWire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - innerWireType := int(innerWire & 0x7) - if innerWireType == 4 { - break - } - next, err := skipGenerated(data[start:]) - if err != nil { - return 0, err - } - iNdEx = start + next - } - return iNdEx, nil - case 4: - return iNdEx, nil - case 5: - iNdEx += 4 - return iNdEx, nil - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - } - panic("unreachable") -} - -var ( - ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") -) - -var fileDescriptorGenerated = []byte{ - // 1390 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xcc, 0x57, 0x4f, 0x6f, 0x1b, 0x45, - 0x14, 0xf7, 0xda, 0xb1, 0xbb, 0x7e, 0x8e, 0x49, 0xba, 0xa4, 0x62, 0x1b, 0x09, 0xdb, 0x6c, 0x05, - 0x4a, 0xa5, 0xd6, 0x56, 0x23, 0x40, 0x55, 0x11, 0x7f, 0xe2, 0x24, 0xad, 0xa2, 0x36, 0x6d, 0x34, - 0xa9, 0x8a, 0xd4, 0x16, 0x89, 0x8d, 0x77, 0xe2, 0xac, 0x6c, 0xef, 0x2e, 0x33, 0xb3, 0x51, 0x2d, - 0x90, 0xe8, 0xa5, 0x12, 0x07, 0x84, 0x7a, 0xe4, 0x02, 0x6a, 0xa5, 0x7e, 0x03, 0xbe, 0x44, 0xc5, - 0xa9, 0x17, 0x24, 0x0e, 0xc8, 0xa2, 0xe1, 0xc2, 0x95, 0x6b, 0x4e, 0x68, 0x66, 0x67, 0xd6, 0xbb, - 0x6e, 0x4d, 0x36, 0xd0, 0x03, 0x27, 0xef, 0xfb, 0xff, 0xe6, 0xbd, 0xdf, 0xbc, 0x37, 0x86, 0xf7, - 0x7a, 0x17, 0x69, 0xd3, 0xf5, 0x5b, 0xbd, 0x70, 0x07, 0x13, 0x0f, 0x33, 0x4c, 0x5b, 0x41, 0xaf, - 0xdb, 0xb2, 0x03, 0xb7, 0x15, 0x7a, 0xfb, 0x98, 0x50, 0xd7, 0xf7, 0xb0, 0xd3, 0xea, 0x62, 0x0f, - 0x13, 0x9b, 0x61, 0xa7, 0x19, 0x10, 0x9f, 0xf9, 0xc6, 0xdb, 0x91, 0x59, 0x73, 0x6c, 0xd6, 0x0c, - 0x7a, 0xdd, 0xa6, 0x1d, 0xb8, 0xcd, 0x84, 0xd9, 0xe2, 0xf9, 0xae, 0xcb, 0xf6, 0xc2, 0x9d, 0x66, - 0xc7, 0x1f, 0xb4, 0xba, 0x7e, 0xd7, 0x6f, 0x09, 0xeb, 0x9d, 0x70, 0x57, 0x50, 0x82, 0x10, 0x5f, - 0x91, 0xd7, 0xc5, 0xf3, 0x2f, 0x4f, 0x86, 0x84, 0x1e, 0x73, 0x07, 0x78, 0x32, 0x89, 0xc5, 0x0b, - 0x2f, 0x57, 0x0f, 0x99, 0xdb, 0x6f, 0xb9, 0x1e, 0xa3, 0x8c, 0x4c, 0x9a, 0x58, 0x3f, 0x17, 0x40, - 0x5f, 0xd9, 0xda, 0xb8, 0x42, 0xfc, 0x30, 0x30, 0x1a, 0x30, 0xe3, 0xd9, 0x03, 0x6c, 0x6a, 0x0d, - 0x6d, 0xa9, 0xdc, 0x9e, 0x7d, 0x3a, 0xaa, 0xe7, 0x0e, 0x46, 0xf5, 0x99, 0xeb, 0xf6, 0x00, 0x23, - 0x21, 0x31, 0x06, 0xa0, 0xcb, 0xc3, 0x50, 0x33, 0xdf, 0x28, 0x2c, 0x55, 0x96, 0x3f, 0x6e, 0x66, - 0x3a, 0x79, 0x53, 0x44, 0xb8, 0x15, 0x91, 0x97, 0x7d, 0xb2, 0xe6, 0xd2, 0x8e, 0xbf, 0x8f, 0xc9, - 0xb0, 0x3d, 0x2f, 0xc3, 0xe8, 0x52, 0x48, 0x51, 0x1c, 0xc2, 0x78, 0xa0, 0xc1, 0x7c, 0x40, 0xf0, - 0x2e, 0x26, 0x04, 0x3b, 0x52, 0x6e, 0x16, 0x1a, 0xda, 0xab, 0x88, 0x6b, 0xca, 0xb8, 0xf3, 0x5b, - 0x13, 0x01, 0xd0, 0x0b, 0x21, 0x8d, 0x27, 0x1a, 0x2c, 0x52, 0x4c, 0xf6, 0x31, 0x59, 0x71, 0x1c, - 0x82, 0x29, 0x6d, 0x0f, 0x57, 0xfb, 0x2e, 0xf6, 0xd8, 0xea, 0xc6, 0x1a, 0xa2, 0xe6, 0x8c, 0xa8, - 0xc4, 0x27, 0x19, 0x33, 0xda, 0x9e, 0xe6, 0xa8, 0x6d, 0xc9, 0x94, 0x16, 0xa7, 0xaa, 0x50, 0xf4, - 0x0f, 0x79, 0x58, 0x5d, 0x98, 0x55, 0xbd, 0xbc, 0xe6, 0x52, 0x66, 0x7c, 0x0a, 0xa5, 0x2e, 0x27, - 0xa8, 0xa9, 0x89, 0x0c, 0x5b, 0x19, 0x33, 0x54, 0x4e, 0xda, 0xaf, 0xc9, 0x84, 0x4a, 0x82, 0xa4, - 0x48, 0xba, 0xb3, 0x1e, 0x68, 0x50, 0x59, 0xd9, 0xda, 0x40, 0x98, 0xfa, 0x21, 0xe9, 0xe0, 0x0c, - 0xc0, 0x59, 0x06, 0xe0, 0xbf, 0x34, 0xb0, 0x3b, 0xd8, 0x31, 0xf3, 0x0d, 0x6d, 0x49, 0x6f, 0x1b, - 0x52, 0x0f, 0xae, 0xc7, 0x12, 0x94, 0xd0, 0xe2, 0x5e, 0x7b, 0xae, 0xe7, 0x88, 0x86, 0x27, 0xbc, - 0x5e, 0x75, 0x3d, 0x07, 0x09, 0x89, 0xf5, 0x93, 0x06, 0x73, 0x89, 0x3c, 0xc4, 0xa1, 0x2f, 0xc2, - 0x6c, 0x37, 0xd1, 0x73, 0x99, 0xd3, 0x82, 0xb4, 0x9e, 0x4d, 0xe2, 0x01, 0xa5, 0x34, 0x8d, 0x5d, - 0x28, 0x13, 0xe9, 0x49, 0xa1, 0x7b, 0x39, 0x7b, 0xc5, 0x54, 0x12, 0xe3, 0x50, 0x09, 0x26, 0x45, - 0x63, 0xd7, 0xd6, 0x9f, 0x51, 0xf5, 0x14, 0xde, 0x8d, 0xa5, 0xc4, 0xa5, 0xe2, 0x8d, 0x2a, 0xb7, - 0x67, 0xa7, 0xdc, 0x87, 0x23, 0x70, 0x98, 0xff, 0x7f, 0xe0, 0xf0, 0x92, 0xfe, 0xfd, 0xa3, 0x7a, - 0xee, 0xfe, 0x6f, 0x8d, 0x9c, 0xb5, 0x01, 0xfa, 0x5a, 0x48, 0x6c, 0xc6, 0xcb, 0xfb, 0x21, 0xe8, - 0x8e, 0xfc, 0x16, 0x4d, 0x29, 0xb4, 0xdf, 0x52, 0x57, 0x5f, 0xe9, 0x1c, 0x8e, 0xea, 0x55, 0x3e, - 0xd9, 0x9a, 0x8a, 0x81, 0x62, 0x13, 0xeb, 0x2e, 0x54, 0xd7, 0xef, 0x05, 0x3e, 0x61, 0x37, 0x02, - 0x26, 0x8a, 0xf1, 0x0e, 0x94, 0xb0, 0x60, 0x08, 0x6f, 0xfa, 0x18, 0xac, 0x91, 0x1a, 0x92, 0x52, - 0xe3, 0x0c, 0x14, 0xf1, 0x3d, 0xbb, 0xc3, 0x24, 0xea, 0xaa, 0x52, 0xad, 0xb8, 0xce, 0x99, 0x28, - 0x92, 0x59, 0x77, 0xa1, 0x2c, 0x90, 0xc1, 0xc1, 0xc5, 0x2d, 0x04, 0x30, 0x24, 0x76, 0x62, 0x0b, - 0xa1, 0x81, 0x22, 0x59, 0x8c, 0xce, 0xfc, 0x34, 0x74, 0x26, 0xca, 0xd0, 0x87, 0x6a, 0x64, 0xab, - 0x2e, 0x4c, 0xa6, 0x08, 0xe7, 0x40, 0x57, 0xa0, 0x91, 0x51, 0xe2, 0x59, 0xa9, 0x1c, 0xa1, 0x58, - 0x23, 0x11, 0x6d, 0x0f, 0x52, 0x28, 0xcf, 0x16, 0xec, 0x2c, 0x9c, 0x90, 0xd0, 0x90, 0xb1, 0xe6, - 0xa4, 0xda, 0x09, 0x75, 0x59, 0x94, 0x3c, 0x11, 0xe9, 0x6b, 0x30, 0xa7, 0xcd, 0xd7, 0xff, 0x70, - 0x0f, 0xb3, 0xa7, 0x62, 0x7d, 0xa7, 0xc1, 0x7c, 0xd2, 0x53, 0xf6, 0xf6, 0x65, 0x0f, 0x72, 0xf4, - 0x1c, 0x4a, 0x54, 0xe4, 0x47, 0x0d, 0x16, 0x52, 0x47, 0x3b, 0x56, 0xc7, 0x8f, 0x91, 0x54, 0x12, - 0x1c, 0x85, 0x63, 0x80, 0xe3, 0x97, 0x3c, 0x54, 0xaf, 0xd9, 0x3b, 0xb8, 0xbf, 0x8d, 0xfb, 0xb8, - 0xc3, 0x7c, 0x62, 0x7c, 0x05, 0x95, 0x81, 0xcd, 0x3a, 0x7b, 0x82, 0xab, 0x56, 0xc5, 0x7a, 0xc6, - 0x21, 0x92, 0x72, 0xd5, 0xdc, 0x1c, 0xfb, 0x59, 0xf7, 0x18, 0x19, 0xb6, 0x5f, 0x97, 0x39, 0x55, - 0x12, 0x12, 0x94, 0x0c, 0x27, 0x56, 0xbc, 0xa0, 0xd7, 0xef, 0x05, 0x7c, 0x92, 0xfc, 0x8b, 0xa7, - 0x45, 0x2a, 0x07, 0x84, 0xbf, 0x08, 0x5d, 0x82, 0x07, 0xd8, 0x63, 0xe3, 0x15, 0xbf, 0x39, 0x11, - 0x00, 0xbd, 0x10, 0x72, 0xf1, 0x23, 0x98, 0x9f, 0xcc, 0xde, 0x98, 0x87, 0x42, 0x0f, 0x0f, 0xa3, - 0x8e, 0x21, 0xfe, 0x69, 0x2c, 0x40, 0x71, 0xdf, 0xee, 0x87, 0xf2, 0x3e, 0xa2, 0x88, 0xb8, 0x94, - 0xbf, 0xa8, 0x59, 0x4f, 0x34, 0x30, 0xa7, 0x25, 0x62, 0xbc, 0x99, 0x70, 0xd4, 0xae, 0xc8, 0xac, - 0x0a, 0x57, 0xf1, 0x30, 0xf2, 0xba, 0x0e, 0xba, 0x1f, 0xf0, 0x67, 0x99, 0x4f, 0x64, 0xdf, 0xcf, - 0xaa, 0x5e, 0xde, 0x90, 0xfc, 0xc3, 0x51, 0xfd, 0x54, 0xca, 0xbd, 0x12, 0xa0, 0xd8, 0xd4, 0xb0, - 0xa0, 0x24, 0xf2, 0xa1, 0x66, 0x41, 0x6c, 0x11, 0xe0, 0xc3, 0xf0, 0x96, 0xe0, 0x20, 0x29, 0xb1, - 0xbe, 0x04, 0x9d, 0x6f, 0xc9, 0x4d, 0xcc, 0x6c, 0x0e, 0x21, 0x8a, 0xfb, 0xbb, 0xd7, 0x5c, 0xaf, - 0x27, 0x53, 0x8b, 0x21, 0xb4, 0x2d, 0xf9, 0x28, 0xd6, 0x30, 0x56, 0x60, 0x4e, 0xc1, 0xe9, 0x56, - 0x0a, 0xa3, 0x6f, 0x48, 0xa3, 0x39, 0x94, 0x16, 0xa3, 0x49, 0x7d, 0xeb, 0x1c, 0x94, 0x91, 0xef, - 0xb3, 0x2d, 0x9b, 0xed, 0x51, 0xa3, 0x0e, 0xc5, 0x80, 0x7f, 0xc8, 0x95, 0x57, 0xe6, 0x97, 0x41, - 0x48, 0x50, 0xc4, 0xb7, 0xbe, 0xd5, 0xe0, 0xf4, 0xd4, 0x05, 0xc4, 0x1f, 0x14, 0x9d, 0x98, 0x92, - 0xe9, 0xc7, 0x0f, 0x8a, 0xb1, 0x1e, 0x4a, 0x68, 0x19, 0x1f, 0x40, 0x35, 0xb5, 0xb5, 0xe4, 0x01, - 0x4e, 0x49, 0xb3, 0x6a, 0x2a, 0x1a, 0x4a, 0xeb, 0x5a, 0x7f, 0xe5, 0xa1, 0xb4, 0xcd, 0x6c, 0x16, - 0x52, 0xe3, 0x33, 0xd0, 0x07, 0x98, 0xd9, 0x8e, 0xcd, 0x6c, 0x11, 0x39, 0xfb, 0xcb, 0x4a, 0xd5, - 0x7e, 0x5c, 0x69, 0xc5, 0x41, 0xb1, 0x4b, 0xbe, 0xd8, 0xa8, 0x08, 0x24, 0xf3, 0x8b, 0x17, 0x5b, - 0x14, 0x1e, 0x49, 0x29, 0x9f, 0x16, 0x03, 0x4c, 0xa9, 0xdd, 0x55, 0x13, 0x20, 0x9e, 0x16, 0x9b, - 0x11, 0x1b, 0x29, 0xb9, 0xf1, 0x3e, 0x94, 0x08, 0xb6, 0xa9, 0xef, 0x99, 0x33, 0x42, 0xb3, 0xa6, - 0x5c, 0x22, 0xc1, 0x3d, 0x1c, 0xd5, 0x67, 0xa5, 0x73, 0x41, 0x23, 0xa9, 0x6d, 0xdc, 0x81, 0x13, - 0x0e, 0x66, 0xb6, 0xdb, 0xa7, 0x66, 0x51, 0x1c, 0xf4, 0xdd, 0xac, 0x8f, 0x0b, 0xe1, 0x6d, 0x2d, - 0xb2, 0x6d, 0x57, 0x78, 0x52, 0x92, 0x40, 0xca, 0x23, 0x9f, 0xab, 0x1d, 0xdf, 0xc1, 0x66, 0xa9, - 0xa1, 0x2d, 0x15, 0xc7, 0x73, 0x75, 0xd5, 0x77, 0x30, 0x12, 0x12, 0xeb, 0xa1, 0x06, 0x95, 0xc8, - 0xd3, 0xaa, 0x1d, 0x52, 0x6c, 0x5c, 0x88, 0x8f, 0x11, 0x35, 0xfc, 0xb4, 0xb2, 0xb9, 0x39, 0x0c, - 0xf0, 0xe1, 0xa8, 0x5e, 0x16, 0x6a, 0x9c, 0x88, 0x4f, 0x90, 0x28, 0x52, 0xfe, 0x88, 0x22, 0x9d, - 0x81, 0xe2, 0xae, 0x8b, 0xfb, 0x6a, 0xd0, 0xc7, 0x23, 0xfa, 0x32, 0x67, 0xa2, 0x48, 0x66, 0xfd, - 0x90, 0x87, 0x6a, 0xea, 0x70, 0x19, 0x1e, 0xbf, 0xf1, 0xec, 0xcf, 0x67, 0x78, 0x4f, 0x4c, 0xdd, - 0x32, 0xc6, 0x6d, 0x28, 0x75, 0xf8, 0xf9, 0xd4, 0x1f, 0x8e, 0xe5, 0x63, 0xf5, 0x42, 0x94, 0x66, - 0x8c, 0x25, 0x41, 0x52, 0x24, 0x3d, 0x1a, 0x57, 0xe0, 0x24, 0xc1, 0x8c, 0x0c, 0x57, 0x76, 0x19, - 0x26, 0xdb, 0xb8, 0xe3, 0x7b, 0x4e, 0xd4, 0xf2, 0x62, 0x5c, 0xe4, 0x93, 0x68, 0x52, 0x01, 0xbd, - 0x68, 0x63, 0xf5, 0x61, 0xe6, 0xa6, 0x3b, 0xc0, 0xbc, 0xee, 0x54, 0xba, 0x89, 0x1e, 0x7b, 0x71, - 0xdd, 0x95, 0xb1, 0x92, 0xf3, 0xf2, 0x78, 0xb6, 0xe7, 0x47, 0x70, 0x2f, 0x8e, 0xcb, 0x73, 0x9d, - 0x33, 0x51, 0x24, 0xbb, 0xb4, 0xc0, 0x37, 0xd8, 0x37, 0x8f, 0xeb, 0xb9, 0x87, 0x8f, 0xeb, 0xb9, - 0x47, 0x8f, 0xe5, 0x36, 0xbb, 0x03, 0x65, 0x1e, 0x8d, 0x32, 0x7b, 0x10, 0xbc, 0xea, 0x90, 0xd6, - 0xe7, 0xa0, 0x73, 0x28, 0x89, 0x59, 0xa9, 0xba, 0xa3, 0x4d, 0xed, 0xce, 0x32, 0x80, 0x1d, 0xb8, - 0xe9, 0xd1, 0x18, 0x0f, 0xa4, 0xf1, 0x73, 0x1f, 0x25, 0xb4, 0xda, 0xe7, 0x9f, 0x3e, 0xaf, 0xe5, - 0x9e, 0x3d, 0xaf, 0xe5, 0x7e, 0x7d, 0x5e, 0xcb, 0xdd, 0x3f, 0xa8, 0x69, 0x4f, 0x0f, 0x6a, 0xda, - 0xb3, 0x83, 0x9a, 0xf6, 0xfb, 0x41, 0x4d, 0x7b, 0xf8, 0x47, 0x2d, 0x77, 0xbb, 0x92, 0x68, 0xe4, - 0xdf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x0a, 0x22, 0x00, 0xde, 0x9c, 0x10, 0x00, 0x00, -} diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/generated.proto b/vendor/k8s.io/client-go/pkg/api/unversioned/generated.proto deleted file mode 100644 index 91d3fbf651..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/generated.proto +++ /dev/null @@ -1,400 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - - -// This file was autogenerated by go-to-protobuf. Do not edit it manually! - -syntax = 'proto2'; - -package k8s.io.kubernetes.pkg.api.unversioned; - -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; - -// Package-wide variables from generator "generated". -option go_package = "unversioned"; - -// APIGroup contains the name, the supported versions, and the preferred version -// of a group. -message APIGroup { - // name is the name of the group. - optional string name = 1; - - // versions are the versions supported in this group. - repeated GroupVersionForDiscovery versions = 2; - - // preferredVersion is the version preferred by the API server, which - // probably is the storage version. - // +optional - optional GroupVersionForDiscovery preferredVersion = 3; - - // a map of client CIDR to server address that is serving this group. - // This is to help clients reach servers in the most network-efficient way possible. - // Clients can use the appropriate server address as per the CIDR that they match. - // In case of multiple matches, clients should use the longest matching CIDR. - // The server returns only those CIDRs that it thinks that the client can match. - // For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. - // Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP. - repeated ServerAddressByClientCIDR serverAddressByClientCIDRs = 4; -} - -// APIGroupList is a list of APIGroup, to allow clients to discover the API at -// /apis. -message APIGroupList { - // groups is a list of APIGroup. - repeated APIGroup groups = 1; -} - -// APIResource specifies the name of a resource and whether it is namespaced. -message APIResource { - // name is the name of the resource. - optional string name = 1; - - // namespaced indicates if a resource is namespaced or not. - optional bool namespaced = 2; - - // kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo') - optional string kind = 3; -} - -// APIResourceList is a list of APIResource, it is used to expose the name of the -// resources supported in a specific group and version, and if the resource -// is namespaced. -message APIResourceList { - // groupVersion is the group and version this APIResourceList is for. - optional string groupVersion = 1; - - // resources contains the name of the resources and if they are namespaced. - repeated APIResource resources = 2; -} - -// APIVersions lists the versions that are available, to allow clients to -// discover the API at /api, which is the root path of the legacy v1 API. -// -// +protobuf.options.(gogoproto.goproto_stringer)=false -message APIVersions { - // versions are the api versions that are available. - repeated string versions = 1; - - // a map of client CIDR to server address that is serving this group. - // This is to help clients reach servers in the most network-efficient way possible. - // Clients can use the appropriate server address as per the CIDR that they match. - // In case of multiple matches, clients should use the longest matching CIDR. - // The server returns only those CIDRs that it thinks that the client can match. - // For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. - // Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP. - repeated ServerAddressByClientCIDR serverAddressByClientCIDRs = 2; -} - -// Duration is a wrapper around time.Duration which supports correct -// marshaling to YAML and JSON. In particular, it marshals into strings, which -// can be used as map keys in json. -message Duration { - optional int64 duration = 1; -} - -// ExportOptions is the query options to the standard REST get call. -message ExportOptions { - // Should this value be exported. Export strips fields that a user can not specify.` - optional bool export = 1; - - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' - optional bool exact = 2; -} - -// GroupKind specifies a Group and a Kind, but does not force a version. This is useful for identifying -// concepts during lookup stages without having partially valid types -// -// +protobuf.options.(gogoproto.goproto_stringer)=false -message GroupKind { - optional string group = 1; - - optional string kind = 2; -} - -// GroupResource specifies a Group and a Resource, but does not force a version. This is useful for identifying -// concepts during lookup stages without having partially valid types -// -// +protobuf.options.(gogoproto.goproto_stringer)=false -message GroupResource { - optional string group = 1; - - optional string resource = 2; -} - -// GroupVersion contains the "group" and the "version", which uniquely identifies the API. -// -// +protobuf.options.(gogoproto.goproto_stringer)=false -message GroupVersion { - optional string group = 1; - - optional string version = 2; -} - -// GroupVersion contains the "group/version" and "version" string of a version. -// It is made a struct to keep extensibility. -message GroupVersionForDiscovery { - // groupVersion specifies the API group and version in the form "group/version" - optional string groupVersion = 1; - - // version specifies the version in the form of "version". This is to save - // the clients the trouble of splitting the GroupVersion. - optional string version = 2; -} - -// GroupVersionKind unambiguously identifies a kind. It doesn't anonymously include GroupVersion -// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling -// -// +protobuf.options.(gogoproto.goproto_stringer)=false -message GroupVersionKind { - optional string group = 1; - - optional string version = 2; - - optional string kind = 3; -} - -// GroupVersionResource unambiguously identifies a resource. It doesn't anonymously include GroupVersion -// to avoid automatic coersion. It doesn't use a GroupVersion to avoid custom marshalling -// -// +protobuf.options.(gogoproto.goproto_stringer)=false -message GroupVersionResource { - optional string group = 1; - - optional string version = 2; - - optional string resource = 3; -} - -// A label selector is a label query over a set of resources. The result of matchLabels and -// matchExpressions are ANDed. An empty label selector matches all objects. A null -// label selector matches no objects. -message LabelSelector { - // matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels - // map is equivalent to an element of matchExpressions, whose key field is "key", the - // operator is "In", and the values array contains only "value". The requirements are ANDed. - // +optional - map matchLabels = 1; - - // matchExpressions is a list of label selector requirements. The requirements are ANDed. - // +optional - repeated LabelSelectorRequirement matchExpressions = 2; -} - -// A label selector requirement is a selector that contains values, a key, and an operator that -// relates the key and values. -message LabelSelectorRequirement { - // key is the label key that the selector applies to. - optional string key = 1; - - // operator represents a key's relationship to a set of values. - // Valid operators ard In, NotIn, Exists and DoesNotExist. - optional string operator = 2; - - // values is an array of string values. If the operator is In or NotIn, - // the values array must be non-empty. If the operator is Exists or DoesNotExist, - // the values array must be empty. This array is replaced during a strategic - // merge patch. - // +optional - repeated string values = 3; -} - -// ListMeta describes metadata that synthetic resources must have, including lists and -// various status objects. A resource may have only one of {ObjectMeta, ListMeta}. -message ListMeta { - // SelfLink is a URL representing this object. - // Populated by the system. - // Read-only. - // +optional - optional string selfLink = 1; - - // String that identifies the server's internal version of this object that - // can be used by clients to determine when objects have changed. - // Value must be treated as opaque by clients and passed unmodified back to the server. - // Populated by the system. - // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency - // +optional - optional string resourceVersion = 2; -} - -// RootPaths lists the paths available at root. -// For example: "/healthz", "/apis". -message RootPaths { - // paths are the paths available at root. - repeated string paths = 1; -} - -// ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match. -message ServerAddressByClientCIDR { - // The CIDR with which clients can match their IP to figure out the server address that they should use. - optional string clientCIDR = 1; - - // Address of this server, suitable for a client that matches the above CIDR. - // This can be a hostname, hostname:port, IP or IP:port. - optional string serverAddress = 2; -} - -// Status is a return value for calls that don't return other objects. -message Status { - // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - // +optional - optional ListMeta metadata = 1; - - // Status of the operation. - // One of: "Success" or "Failure". - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - optional string status = 2; - - // A human-readable description of the status of this operation. - // +optional - optional string message = 3; - - // A machine-readable description of why this operation is in the - // "Failure" status. If this value is empty there - // is no information available. A Reason clarifies an HTTP status - // code but does not override it. - // +optional - optional string reason = 4; - - // Extended data associated with the reason. Each reason may define its - // own extended details. This field is optional and the data returned - // is not guaranteed to conform to any schema except that defined by - // the reason type. - // +optional - optional StatusDetails details = 5; - - // Suggested HTTP return code for this status, 0 if not set. - // +optional - optional int32 code = 6; -} - -// StatusCause provides more information about an api.Status failure, including -// cases when multiple errors are encountered. -message StatusCause { - // A machine-readable description of the cause of the error. If this value is - // empty there is no information available. - // +optional - optional string reason = 1; - - // A human-readable description of the cause of the error. This field may be - // presented as-is to a reader. - // +optional - optional string message = 2; - - // The field of the resource that has caused this error, as named by its JSON - // serialization. May include dot and postfix notation for nested attributes. - // Arrays are zero-indexed. Fields may appear more than once in an array of - // causes due to fields having multiple errors. - // Optional. - // - // Examples: - // "name" - the field "name" on the current resource - // "items[0].name" - the field "name" on the first array entry in "items" - // +optional - optional string field = 3; -} - -// StatusDetails is a set of additional properties that MAY be set by the -// server to provide additional information about a response. The Reason -// field of a Status object defines what attributes will be set. Clients -// must ignore fields that do not match the defined type of each attribute, -// and should assume that any attribute may be empty, invalid, or under -// defined. -message StatusDetails { - // The name attribute of the resource associated with the status StatusReason - // (when there is a single name which can be described). - // +optional - optional string name = 1; - - // The group attribute of the resource associated with the status StatusReason. - // +optional - optional string group = 2; - - // The kind attribute of the resource associated with the status StatusReason. - // On some operations may differ from the requested resource Kind. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - // +optional - optional string kind = 3; - - // The Causes array includes more details associated with the StatusReason - // failure. Not all StatusReasons may provide detailed causes. - // +optional - repeated StatusCause causes = 4; - - // If specified, the time in seconds before the operation should be retried. - // +optional - optional int32 retryAfterSeconds = 5; -} - -// Time is a wrapper around time.Time which supports correct -// marshaling to YAML and JSON. Wrappers are provided for many -// of the factory methods that the time package offers. -// -// +protobuf.options.marshal=false -// +protobuf.as=Timestamp -// +protobuf.options.(gogoproto.goproto_stringer)=false -message Time { - // Represents seconds of UTC time since Unix epoch - // 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to - // 9999-12-31T23:59:59Z inclusive. - optional int64 seconds = 1; - - // Non-negative fractions of a second at nanosecond resolution. Negative - // second values with fractions must still have non-negative nanos values - // that count forward in time. Must be from 0 to 999,999,999 - // inclusive. This field may be limited in precision depending on context. - optional int32 nanos = 2; -} - -// Timestamp is a struct that is equivalent to Time, but intended for -// protobuf marshalling/unmarshalling. It is generated into a serialization -// that matches Time. Do not use in Go structs. -message Timestamp { - // Represents seconds of UTC time since Unix epoch - // 1970-01-01T00:00:00Z. Must be from from 0001-01-01T00:00:00Z to - // 9999-12-31T23:59:59Z inclusive. - optional int64 seconds = 1; - - // Non-negative fractions of a second at nanosecond resolution. Negative - // second values with fractions must still have non-negative nanos values - // that count forward in time. Must be from 0 to 999,999,999 - // inclusive. This field may be limited in precision depending on context. - optional int32 nanos = 2; -} - -// TypeMeta describes an individual object in an API response or request -// with strings representing the type of the object and its API schema version. -// Structures that are versioned or persisted should inline TypeMeta. -message TypeMeta { - // Kind is a string value representing the REST resource this object represents. - // Servers may infer this from the endpoint the client submits requests to. - // Cannot be updated. - // In CamelCase. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - // +optional - optional string kind = 1; - - // APIVersion defines the versioned schema of this representation of an object. - // Servers should convert recognized schemas to the latest internal value, and - // may reject unrecognized values. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources - // +optional - optional string apiVersion = 2; -} - diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/meta.go b/vendor/k8s.io/client-go/pkg/api/unversioned/meta.go deleted file mode 100644 index 48009da162..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/meta.go +++ /dev/null @@ -1,62 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package unversioned - -// ListMetaAccessor retrieves the list interface from an object -// TODO: move this, and TypeMeta and ListMeta, to a different package -type ListMetaAccessor interface { - GetListMeta() List -} - -// List lets you work with list metadata from any of the versioned or -// internal API objects. Attempting to set or retrieve a field on an object that does -// not support that field will be a no-op and return a default value. -// TODO: move this, and TypeMeta and ListMeta, to a different package -type List interface { - GetResourceVersion() string - SetResourceVersion(version string) - GetSelfLink() string - SetSelfLink(selfLink string) -} - -// Type exposes the type and APIVersion of versioned or internal API objects. -// TODO: move this, and TypeMeta and ListMeta, to a different package -type Type interface { - GetAPIVersion() string - SetAPIVersion(version string) - GetKind() string - SetKind(kind string) -} - -func (meta *ListMeta) GetResourceVersion() string { return meta.ResourceVersion } -func (meta *ListMeta) SetResourceVersion(version string) { meta.ResourceVersion = version } -func (meta *ListMeta) GetSelfLink() string { return meta.SelfLink } -func (meta *ListMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink } - -func (obj *TypeMeta) GetObjectKind() ObjectKind { return obj } - -// SetGroupVersionKind satisfies the ObjectKind interface for all objects that embed TypeMeta -func (obj *TypeMeta) SetGroupVersionKind(gvk GroupVersionKind) { - obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() -} - -// GroupVersionKind satisfies the ObjectKind interface for all objects that embed TypeMeta -func (obj *TypeMeta) GroupVersionKind() GroupVersionKind { - return FromAPIVersionAndKind(obj.APIVersion, obj.Kind) -} - -func (obj *ListMeta) GetListMeta() List { return obj } diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/api/unversioned/types_swagger_doc_generated.go deleted file mode 100644 index 3f08115a6c..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/types_swagger_doc_generated.go +++ /dev/null @@ -1,208 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package unversioned - -// This file contains a collection of methods that can be used from go-restful to -// generate Swagger API documentation for its models. Please read this PR for more -// information on the implementation: https://github.com/emicklei/go-restful/pull/215 -// -// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if -// they are on one line! For multiple line or blocks that you want to ignore use ---. -// Any context after a --- is ignored. -// -// Those methods can be generated by using hack/update-generated-swagger-docs.sh - -// AUTO-GENERATED FUNCTIONS START HERE -var map_APIGroup = map[string]string{ - "": "APIGroup contains the name, the supported versions, and the preferred version of a group.", - "name": "name is the name of the group.", - "versions": "versions are the versions supported in this group.", - "preferredVersion": "preferredVersion is the version preferred by the API server, which probably is the storage version.", - "serverAddressByClientCIDRs": "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", -} - -func (APIGroup) SwaggerDoc() map[string]string { - return map_APIGroup -} - -var map_APIGroupList = map[string]string{ - "": "APIGroupList is a list of APIGroup, to allow clients to discover the API at /apis.", - "groups": "groups is a list of APIGroup.", -} - -func (APIGroupList) SwaggerDoc() map[string]string { - return map_APIGroupList -} - -var map_APIResource = map[string]string{ - "": "APIResource specifies the name of a resource and whether it is namespaced.", - "name": "name is the name of the resource.", - "namespaced": "namespaced indicates if a resource is namespaced or not.", - "kind": "kind is the kind for the resource (e.g. 'Foo' is the kind for a resource 'foo')", -} - -func (APIResource) SwaggerDoc() map[string]string { - return map_APIResource -} - -var map_APIResourceList = map[string]string{ - "": "APIResourceList is a list of APIResource, it is used to expose the name of the resources supported in a specific group and version, and if the resource is namespaced.", - "groupVersion": "groupVersion is the group and version this APIResourceList is for.", - "resources": "resources contains the name of the resources and if they are namespaced.", -} - -func (APIResourceList) SwaggerDoc() map[string]string { - return map_APIResourceList -} - -var map_APIVersions = map[string]string{ - "": "APIVersions lists the versions that are available, to allow clients to discover the API at /api, which is the root path of the legacy v1 API.", - "versions": "versions are the api versions that are available.", - "serverAddressByClientCIDRs": "a map of client CIDR to server address that is serving this group. This is to help clients reach servers in the most network-efficient way possible. Clients can use the appropriate server address as per the CIDR that they match. In case of multiple matches, clients should use the longest matching CIDR. The server returns only those CIDRs that it thinks that the client can match. For example: the master will return an internal IP CIDR only, if the client reaches the server using an internal IP. Server looks at X-Forwarded-For header or X-Real-Ip header or request.RemoteAddr (in that order) to get the client IP.", -} - -func (APIVersions) SwaggerDoc() map[string]string { - return map_APIVersions -} - -var map_ExportOptions = map[string]string{ - "": "ExportOptions is the query options to the standard REST get call.", - "export": "Should this value be exported. Export strips fields that a user can not specify.`", - "exact": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'", -} - -func (ExportOptions) SwaggerDoc() map[string]string { - return map_ExportOptions -} - -var map_GroupVersionForDiscovery = map[string]string{ - "": "GroupVersion contains the \"group/version\" and \"version\" string of a version. It is made a struct to keep extensibility.", - "groupVersion": "groupVersion specifies the API group and version in the form \"group/version\"", - "version": "version specifies the version in the form of \"version\". This is to save the clients the trouble of splitting the GroupVersion.", -} - -func (GroupVersionForDiscovery) SwaggerDoc() map[string]string { - return map_GroupVersionForDiscovery -} - -var map_LabelSelector = map[string]string{ - "": "A label selector is a label query over a set of resources. The result of matchLabels and matchExpressions are ANDed. An empty label selector matches all objects. A null label selector matches no objects.", - "matchLabels": "matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels map is equivalent to an element of matchExpressions, whose key field is \"key\", the operator is \"In\", and the values array contains only \"value\". The requirements are ANDed.", - "matchExpressions": "matchExpressions is a list of label selector requirements. The requirements are ANDed.", -} - -func (LabelSelector) SwaggerDoc() map[string]string { - return map_LabelSelector -} - -var map_LabelSelectorRequirement = map[string]string{ - "": "A label selector requirement is a selector that contains values, a key, and an operator that relates the key and values.", - "key": "key is the label key that the selector applies to.", - "operator": "operator represents a key's relationship to a set of values. Valid operators ard In, NotIn, Exists and DoesNotExist.", - "values": "values is an array of string values. If the operator is In or NotIn, the values array must be non-empty. If the operator is Exists or DoesNotExist, the values array must be empty. This array is replaced during a strategic merge patch.", -} - -func (LabelSelectorRequirement) SwaggerDoc() map[string]string { - return map_LabelSelectorRequirement -} - -var map_ListMeta = map[string]string{ - "": "ListMeta describes metadata that synthetic resources must have, including lists and various status objects. A resource may have only one of {ObjectMeta, ListMeta}.", - "selfLink": "SelfLink is a URL representing this object. Populated by the system. Read-only.", - "resourceVersion": "String that identifies the server's internal version of this object that can be used by clients to determine when objects have changed. Value must be treated as opaque by clients and passed unmodified back to the server. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency", -} - -func (ListMeta) SwaggerDoc() map[string]string { - return map_ListMeta -} - -var map_Patch = map[string]string{ - "": "Patch is provided to give a concrete name and type to the Kubernetes PATCH request body.", -} - -func (Patch) SwaggerDoc() map[string]string { - return map_Patch -} - -var map_RootPaths = map[string]string{ - "": "RootPaths lists the paths available at root. For example: \"/healthz\", \"/apis\".", - "paths": "paths are the paths available at root.", -} - -func (RootPaths) SwaggerDoc() map[string]string { - return map_RootPaths -} - -var map_ServerAddressByClientCIDR = map[string]string{ - "": "ServerAddressByClientCIDR helps the client to determine the server address that they should use, depending on the clientCIDR that they match.", - "clientCIDR": "The CIDR with which clients can match their IP to figure out the server address that they should use.", - "serverAddress": "Address of this server, suitable for a client that matches the above CIDR. This can be a hostname, hostname:port, IP or IP:port.", -} - -func (ServerAddressByClientCIDR) SwaggerDoc() map[string]string { - return map_ServerAddressByClientCIDR -} - -var map_Status = map[string]string{ - "": "Status is a return value for calls that don't return other objects.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "status": "Status of the operation. One of: \"Success\" or \"Failure\". More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "message": "A human-readable description of the status of this operation.", - "reason": "A machine-readable description of why this operation is in the \"Failure\" status. If this value is empty there is no information available. A Reason clarifies an HTTP status code but does not override it.", - "details": "Extended data associated with the reason. Each reason may define its own extended details. This field is optional and the data returned is not guaranteed to conform to any schema except that defined by the reason type.", - "code": "Suggested HTTP return code for this status, 0 if not set.", -} - -func (Status) SwaggerDoc() map[string]string { - return map_Status -} - -var map_StatusCause = map[string]string{ - "": "StatusCause provides more information about an api.Status failure, including cases when multiple errors are encountered.", - "reason": "A machine-readable description of the cause of the error. If this value is empty there is no information available.", - "message": "A human-readable description of the cause of the error. This field may be presented as-is to a reader.", - "field": "The field of the resource that has caused this error, as named by its JSON serialization. May include dot and postfix notation for nested attributes. Arrays are zero-indexed. Fields may appear more than once in an array of causes due to fields having multiple errors. Optional.\n\nExamples:\n \"name\" - the field \"name\" on the current resource\n \"items[0].name\" - the field \"name\" on the first array entry in \"items\"", -} - -func (StatusCause) SwaggerDoc() map[string]string { - return map_StatusCause -} - -var map_StatusDetails = map[string]string{ - "": "StatusDetails is a set of additional properties that MAY be set by the server to provide additional information about a response. The Reason field of a Status object defines what attributes will be set. Clients must ignore fields that do not match the defined type of each attribute, and should assume that any attribute may be empty, invalid, or under defined.", - "name": "The name attribute of the resource associated with the status StatusReason (when there is a single name which can be described).", - "group": "The group attribute of the resource associated with the status StatusReason.", - "kind": "The kind attribute of the resource associated with the status StatusReason. On some operations may differ from the requested resource Kind. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "causes": "The Causes array includes more details associated with the StatusReason failure. Not all StatusReasons may provide detailed causes.", - "retryAfterSeconds": "If specified, the time in seconds before the operation should be retried.", -} - -func (StatusDetails) SwaggerDoc() map[string]string { - return map_StatusDetails -} - -var map_TypeMeta = map[string]string{ - "": "TypeMeta describes an individual object in an API response or request with strings representing the type of the object and its API schema version. Structures that are versioned or persisted should inline TypeMeta.", - "kind": "Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "apiVersion": "APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#resources", -} - -func (TypeMeta) SwaggerDoc() map[string]string { - return map_TypeMeta -} - -// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/well_known_labels.go b/vendor/k8s.io/client-go/pkg/api/unversioned/well_known_labels.go deleted file mode 100644 index 7556181e88..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/well_known_labels.go +++ /dev/null @@ -1,67 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package unversioned - -const ( - // If you add a new topology domain here, also consider adding it to the set of default values - // for the scheduler's --failure-domain command-line argument. - LabelHostname = "kubernetes.io/hostname" - LabelZoneFailureDomain = "failure-domain.beta.kubernetes.io/zone" - LabelZoneRegion = "failure-domain.beta.kubernetes.io/region" - - LabelInstanceType = "beta.kubernetes.io/instance-type" - - LabelOS = "beta.kubernetes.io/os" - LabelArch = "beta.kubernetes.io/arch" -) - -// Role labels are applied to Nodes to mark their purpose. In particular, we -// usually want to distinguish the master, so that we can isolate privileged -// pods and operations. -// -// Originally we relied on not registering the master, on the fact that the -// master was Unschedulable, and on static manifests for master components. -// But we now do register masters in many environments, are generally moving -// away from static manifests (for better manageability), and working towards -// deprecating the unschedulable field (replacing it with taints & tolerations -// instead). -// -// Even with tainting, a label remains the easiest way of making a positive -// selection, so that pods can schedule only to master nodes for example, and -// thus installations will likely define a label for their master nodes. -// -// So that we can recognize master nodes in consequent places though (such as -// kubectl get nodes), we encourage installations to use the well-known labels. -// We define NodeLabelRole, which is the preferred form, but we will also recognize -// other forms that are known to be in widespread use (NodeLabelKubeadmAlphaRole). - -const ( - // NodeLabelRole is the preferred label applied to a Node as a hint that it has a particular purpose (defined by the value). - NodeLabelRole = "kubernetes.io/role" - - // NodeLabelKubeadmAlphaRole is a label that kubeadm applies to a Node as a hint that it has a particular purpose. - // Use of NodeLabelRole is preferred. - NodeLabelKubeadmAlphaRole = "kubeadm.alpha.kubernetes.io/role" - - // NodeLabelRoleMaster is the value of a NodeLabelRole or NodeLabelKubeadmAlphaRole label, indicating a master node. - // A master node typically runs kubernetes system components and will not typically run user workloads. - NodeLabelRoleMaster = "master" - - // NodeLabelRoleNode is the value of a NodeLabelRole or NodeLabelKubeadmAlphaRole label, indicating a "normal" node, - // as opposed to a RoleMaster node. - NodeLabelRoleNode = "node" -) diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/api/unversioned/zz_generated.deepcopy.go deleted file mode 100644 index d70b91c7fb..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/zz_generated.deepcopy.go +++ /dev/null @@ -1,390 +0,0 @@ -// +build !ignore_autogenerated - -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// This file was autogenerated by deepcopy-gen. Do not edit it manually! - -package unversioned - -import ( - conversion "k8s.io/client-go/pkg/conversion" - time "time" -) - -func DeepCopy_unversioned_APIGroup(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*APIGroup) - out := out.(*APIGroup) - out.TypeMeta = in.TypeMeta - out.Name = in.Name - if in.Versions != nil { - in, out := &in.Versions, &out.Versions - *out = make([]GroupVersionForDiscovery, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Versions = nil - } - out.PreferredVersion = in.PreferredVersion - if in.ServerAddressByClientCIDRs != nil { - in, out := &in.ServerAddressByClientCIDRs, &out.ServerAddressByClientCIDRs - *out = make([]ServerAddressByClientCIDR, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.ServerAddressByClientCIDRs = nil - } - return nil - } -} - -func DeepCopy_unversioned_APIGroupList(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*APIGroupList) - out := out.(*APIGroupList) - out.TypeMeta = in.TypeMeta - if in.Groups != nil { - in, out := &in.Groups, &out.Groups - *out = make([]APIGroup, len(*in)) - for i := range *in { - if err := DeepCopy_unversioned_APIGroup(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Groups = nil - } - return nil - } -} - -func DeepCopy_unversioned_APIResource(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*APIResource) - out := out.(*APIResource) - out.Name = in.Name - out.Namespaced = in.Namespaced - out.Kind = in.Kind - return nil - } -} - -func DeepCopy_unversioned_APIResourceList(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*APIResourceList) - out := out.(*APIResourceList) - out.TypeMeta = in.TypeMeta - out.GroupVersion = in.GroupVersion - if in.APIResources != nil { - in, out := &in.APIResources, &out.APIResources - *out = make([]APIResource, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.APIResources = nil - } - return nil - } -} - -func DeepCopy_unversioned_APIVersions(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*APIVersions) - out := out.(*APIVersions) - out.TypeMeta = in.TypeMeta - if in.Versions != nil { - in, out := &in.Versions, &out.Versions - *out = make([]string, len(*in)) - copy(*out, *in) - } else { - out.Versions = nil - } - if in.ServerAddressByClientCIDRs != nil { - in, out := &in.ServerAddressByClientCIDRs, &out.ServerAddressByClientCIDRs - *out = make([]ServerAddressByClientCIDR, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.ServerAddressByClientCIDRs = nil - } - return nil - } -} - -func DeepCopy_unversioned_Duration(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Duration) - out := out.(*Duration) - out.Duration = in.Duration - return nil - } -} - -func DeepCopy_unversioned_ExportOptions(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ExportOptions) - out := out.(*ExportOptions) - out.TypeMeta = in.TypeMeta - out.Export = in.Export - out.Exact = in.Exact - return nil - } -} - -func DeepCopy_unversioned_GroupKind(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*GroupKind) - out := out.(*GroupKind) - out.Group = in.Group - out.Kind = in.Kind - return nil - } -} - -func DeepCopy_unversioned_GroupResource(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*GroupResource) - out := out.(*GroupResource) - out.Group = in.Group - out.Resource = in.Resource - return nil - } -} - -func DeepCopy_unversioned_GroupVersion(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*GroupVersion) - out := out.(*GroupVersion) - out.Group = in.Group - out.Version = in.Version - return nil - } -} - -func DeepCopy_unversioned_GroupVersionForDiscovery(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*GroupVersionForDiscovery) - out := out.(*GroupVersionForDiscovery) - out.GroupVersion = in.GroupVersion - out.Version = in.Version - return nil - } -} - -func DeepCopy_unversioned_GroupVersionKind(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*GroupVersionKind) - out := out.(*GroupVersionKind) - out.Group = in.Group - out.Version = in.Version - out.Kind = in.Kind - return nil - } -} - -func DeepCopy_unversioned_GroupVersionResource(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*GroupVersionResource) - out := out.(*GroupVersionResource) - out.Group = in.Group - out.Version = in.Version - out.Resource = in.Resource - return nil - } -} - -func DeepCopy_unversioned_LabelSelector(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*LabelSelector) - out := out.(*LabelSelector) - if in.MatchLabels != nil { - in, out := &in.MatchLabels, &out.MatchLabels - *out = make(map[string]string) - for key, val := range *in { - (*out)[key] = val - } - } else { - out.MatchLabels = nil - } - if in.MatchExpressions != nil { - in, out := &in.MatchExpressions, &out.MatchExpressions - *out = make([]LabelSelectorRequirement, len(*in)) - for i := range *in { - if err := DeepCopy_unversioned_LabelSelectorRequirement(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.MatchExpressions = nil - } - return nil - } -} - -func DeepCopy_unversioned_LabelSelectorRequirement(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*LabelSelectorRequirement) - out := out.(*LabelSelectorRequirement) - out.Key = in.Key - out.Operator = in.Operator - if in.Values != nil { - in, out := &in.Values, &out.Values - *out = make([]string, len(*in)) - copy(*out, *in) - } else { - out.Values = nil - } - return nil - } -} - -func DeepCopy_unversioned_ListMeta(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ListMeta) - out := out.(*ListMeta) - out.SelfLink = in.SelfLink - out.ResourceVersion = in.ResourceVersion - return nil - } -} - -func DeepCopy_unversioned_Patch(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Patch) - out := out.(*Patch) - _ = in - _ = out - return nil - } -} - -func DeepCopy_unversioned_RootPaths(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*RootPaths) - out := out.(*RootPaths) - if in.Paths != nil { - in, out := &in.Paths, &out.Paths - *out = make([]string, len(*in)) - copy(*out, *in) - } else { - out.Paths = nil - } - return nil - } -} - -func DeepCopy_unversioned_ServerAddressByClientCIDR(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ServerAddressByClientCIDR) - out := out.(*ServerAddressByClientCIDR) - out.ClientCIDR = in.ClientCIDR - out.ServerAddress = in.ServerAddress - return nil - } -} - -func DeepCopy_unversioned_Status(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Status) - out := out.(*Status) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta - out.Status = in.Status - out.Message = in.Message - out.Reason = in.Reason - if in.Details != nil { - in, out := &in.Details, &out.Details - *out = new(StatusDetails) - if err := DeepCopy_unversioned_StatusDetails(*in, *out, c); err != nil { - return err - } - } else { - out.Details = nil - } - out.Code = in.Code - return nil - } -} - -func DeepCopy_unversioned_StatusCause(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*StatusCause) - out := out.(*StatusCause) - out.Type = in.Type - out.Message = in.Message - out.Field = in.Field - return nil - } -} - -func DeepCopy_unversioned_StatusDetails(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*StatusDetails) - out := out.(*StatusDetails) - out.Name = in.Name - out.Group = in.Group - out.Kind = in.Kind - if in.Causes != nil { - in, out := &in.Causes, &out.Causes - *out = make([]StatusCause, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Causes = nil - } - out.RetryAfterSeconds = in.RetryAfterSeconds - return nil - } -} - -func DeepCopy_unversioned_Time(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Time) - out := out.(*Time) - if newVal, err := c.DeepCopy(&in.Time); err != nil { - return err - } else { - out.Time = *newVal.(*time.Time) - } - return nil - } -} - -func DeepCopy_unversioned_Timestamp(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Timestamp) - out := out.(*Timestamp) - out.Seconds = in.Seconds - out.Nanos = in.Nanos - return nil - } -} - -func DeepCopy_unversioned_TypeMeta(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*TypeMeta) - out := out.(*TypeMeta) - out.Kind = in.Kind - out.APIVersion = in.APIVersion - return nil - } -} diff --git a/vendor/k8s.io/client-go/pkg/api/v1/BUILD b/vendor/k8s.io/client-go/pkg/api/v1/BUILD new file mode 100644 index 0000000000..46e8c54bcd --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/BUILD @@ -0,0 +1,51 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "annotation_key_constants.go", + "conversion.go", + "defaults.go", + "doc.go", + "generate.go", + "generated.pb.go", + "meta.go", + "objectreference.go", + "register.go", + "resource.go", + "taint.go", + "toleration.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/rand:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation/field:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + "//vendor/k8s.io/client-go/pkg/util:go_default_library", + "//vendor/k8s.io/client-go/pkg/util/parsers:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/api/v1/OWNERS b/vendor/k8s.io/client-go/pkg/api/v1/OWNERS new file mode 100755 index 0000000000..fdb84b24a9 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/OWNERS @@ -0,0 +1,41 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- yujuhong +- brendandburns +- derekwaynecarr +- caesarxuchao +- vishh +- mikedanese +- liggitt +- nikhiljindal +- bprashanth +- gmarek +- erictune +- davidopp +- pmorie +- sttts +- kargakis +- dchen1107 +- saad-ali +- zmerlynn +- luxas +- janetkuo +- justinsb +- roberthbailey +- ncdc +- timstclair +- eparis +- timothysc +- piosz +- jsafrane +- dims +- errordeveloper +- madhusudancs +- krousey +- jayunit100 +- rootfs +- markturansky diff --git a/vendor/k8s.io/client-go/pkg/api/v1/annotation_key_constants.go b/vendor/k8s.io/client-go/pkg/api/v1/annotation_key_constants.go new file mode 100644 index 0000000000..bb4588554a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/annotation_key_constants.go @@ -0,0 +1,113 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file should be consistent with pkg/api/annotation_key_constants.go. + +package v1 + +const ( + // ImagePolicyFailedOpenKey is added to pods created by failing open when the image policy + // webhook backend fails. + ImagePolicyFailedOpenKey string = "alpha.image-policy.k8s.io/failed-open" + + // PodPresetOptOutAnnotationKey represents the annotation key for a pod to exempt itself from pod preset manipulation + PodPresetOptOutAnnotationKey string = "podpreset.admission.kubernetes.io/exclude" + + // MirrorAnnotationKey represents the annotation key set by kubelets when creating mirror pods + MirrorPodAnnotationKey string = "kubernetes.io/config.mirror" + + // TolerationsAnnotationKey represents the key of tolerations data (json serialized) + // in the Annotations of a Pod. + TolerationsAnnotationKey string = "scheduler.alpha.kubernetes.io/tolerations" + + // TaintsAnnotationKey represents the key of taints data (json serialized) + // in the Annotations of a Node. + TaintsAnnotationKey string = "scheduler.alpha.kubernetes.io/taints" + + // SeccompPodAnnotationKey represents the key of a seccomp profile applied + // to all containers of a pod. + SeccompPodAnnotationKey string = "seccomp.security.alpha.kubernetes.io/pod" + + // SeccompContainerAnnotationKeyPrefix represents the key of a seccomp profile applied + // to one container of a pod. + SeccompContainerAnnotationKeyPrefix string = "container.seccomp.security.alpha.kubernetes.io/" + + // CreatedByAnnotation represents the key used to store the spec(json) + // used to create the resource. + CreatedByAnnotation = "kubernetes.io/created-by" + + // PreferAvoidPodsAnnotationKey represents the key of preferAvoidPods data (json serialized) + // in the Annotations of a Node. + PreferAvoidPodsAnnotationKey string = "scheduler.alpha.kubernetes.io/preferAvoidPods" + + // SysctlsPodAnnotationKey represents the key of sysctls which are set for the infrastructure + // container of a pod. The annotation value is a comma separated list of sysctl_name=value + // key-value pairs. Only a limited set of whitelisted and isolated sysctls is supported by + // the kubelet. Pods with other sysctls will fail to launch. + SysctlsPodAnnotationKey string = "security.alpha.kubernetes.io/sysctls" + + // UnsafeSysctlsPodAnnotationKey represents the key of sysctls which are set for the infrastructure + // container of a pod. The annotation value is a comma separated list of sysctl_name=value + // key-value pairs. Unsafe sysctls must be explicitly enabled for a kubelet. They are properly + // namespaced to a pod or a container, but their isolation is usually unclear or weak. Their use + // is at-your-own-risk. Pods that attempt to set an unsafe sysctl that is not enabled for a kubelet + // will fail to launch. + UnsafeSysctlsPodAnnotationKey string = "security.alpha.kubernetes.io/unsafe-sysctls" + + // ObjectTTLAnnotations represents a suggestion for kubelet for how long it can cache + // an object (e.g. secret, config map) before fetching it again from apiserver. + // This annotation can be attached to node. + ObjectTTLAnnotationKey string = "node.alpha.kubernetes.io/ttl" + + // AffinityAnnotationKey represents the key of affinity data (json serialized) + // in the Annotations of a Pod. + // TODO: remove when alpha support for affinity is removed + AffinityAnnotationKey string = "scheduler.alpha.kubernetes.io/affinity" + + // annotation key prefix used to identify non-convertible json paths. + NonConvertibleAnnotationPrefix = "non-convertible.kubernetes.io" + + kubectlPrefix = "kubectl.kubernetes.io/" + + // LastAppliedConfigAnnotation is the annotation used to store the previous + // configuration of a resource for use in a three way diff by UpdateApplyAnnotation. + LastAppliedConfigAnnotation = kubectlPrefix + "last-applied-configuration" + + // AnnotationLoadBalancerSourceRangesKey is the key of the annotation on a service to set allowed ingress ranges on their LoadBalancers + // + // It should be a comma-separated list of CIDRs, e.g. `0.0.0.0/0` to + // allow full access (the default) or `18.0.0.0/8,56.0.0.0/8` to allow + // access only from the CIDRs currently allocated to MIT & the USPS. + // + // Not all cloud providers support this annotation, though AWS & GCE do. + AnnotationLoadBalancerSourceRangesKey = "service.beta.kubernetes.io/load-balancer-source-ranges" + + // AnnotationValueExternalTrafficLocal Value of annotation to specify local endpoints behavior. + AnnotationValueExternalTrafficLocal = "OnlyLocal" + // AnnotationValueExternalTrafficGlobal Value of annotation to specify global (legacy) behavior. + AnnotationValueExternalTrafficGlobal = "Global" + + // TODO: The beta annotations have been deprecated, remove them when we release k8s 1.8. + + // BetaAnnotationHealthCheckNodePort Annotation specifying the healthcheck nodePort for the service. + // If not specified, annotation is created by the service api backend with the allocated nodePort. + // Will use user-specified nodePort value if specified by the client. + BetaAnnotationHealthCheckNodePort = "service.beta.kubernetes.io/healthcheck-nodeport" + + // BetaAnnotationExternalTraffic An annotation that denotes if this Service desires to route + // external traffic to local endpoints only. This preserves Source IP and avoids a second hop. + BetaAnnotationExternalTraffic = "service.beta.kubernetes.io/external-traffic" +) diff --git a/vendor/k8s.io/client-go/pkg/api/v1/conversion.go b/vendor/k8s.io/client-go/pkg/api/v1/conversion.go index dba084a0e4..4ded76091e 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/conversion.go @@ -21,23 +21,12 @@ import ( "fmt" "reflect" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/validation/field" "k8s.io/client-go/pkg/api" "k8s.io/client-go/pkg/apis/extensions" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/validation/field" - "k8s.io/client-go/pkg/watch/versioned" -) - -const ( - // Annotation key used to identify mirror pods. - mirrorAnnotationKey = "kubernetes.io/config.mirror" - - // Value used to identify mirror pods from pre-v1.1 kubelet. - mirrorAnnotationValue_1_0 = "mirror" - - // annotation key prefix used to identify non-convertible json paths. - NonConvertibleAnnotationPrefix = "kubernetes.io/non-convertible" ) // This is a "fast-path" that avoids reflection for common types. It focuses on the objects that are @@ -123,15 +112,15 @@ func addFastPathConversionFuncs(scheme *runtime.Scheme) error { return true, Convert_api_Endpoints_To_v1_Endpoints(a, b, s) } - case *versioned.Event: + case *metav1.WatchEvent: switch b := objB.(type) { - case *versioned.InternalEvent: - return true, versioned.Convert_versioned_Event_to_versioned_InternalEvent(a, b, s) + case *metav1.InternalEvent: + return true, metav1.Convert_versioned_Event_to_versioned_InternalEvent(a, b, s) } - case *versioned.InternalEvent: + case *metav1.InternalEvent: switch b := objB.(type) { - case *versioned.Event: - return true, versioned.Convert_versioned_InternalEvent_to_versioned_Event(a, b, s) + case *metav1.WatchEvent: + return true, metav1.Convert_versioned_InternalEvent_to_versioned_Event(a, b, s) } } return false, nil @@ -201,6 +190,7 @@ func addConversionFuncs(scheme *runtime.Scheme) error { "spec.restartPolicy", "spec.serviceAccountName", "status.phase", + "status.hostIP", "status.podIP": return label, value, nil // This is for backwards compatibility with old v1 clients which send spec.host @@ -269,9 +259,7 @@ func addConversionFuncs(scheme *runtime.Scheme) error { } func Convert_v1_ReplicationController_to_extensions_ReplicaSet(in *ReplicationController, out *extensions.ReplicaSet, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ReplicationControllerSpec_to_extensions_ReplicaSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -284,7 +272,7 @@ func Convert_v1_ReplicationController_to_extensions_ReplicaSet(in *ReplicationCo func Convert_v1_ReplicationControllerSpec_to_extensions_ReplicaSetSpec(in *ReplicationControllerSpec, out *extensions.ReplicaSetSpec, s conversion.Scope) error { out.Replicas = *in.Replicas if in.Selector != nil { - api.Convert_map_to_unversioned_LabelSelector(&in.Selector, out.Selector, s) + metav1.Convert_map_to_unversioned_LabelSelector(&in.Selector, out.Selector, s) } if in.Template != nil { if err := Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in.Template, &out.Template, s); err != nil { @@ -304,9 +292,7 @@ func Convert_v1_ReplicationControllerStatus_to_extensions_ReplicaSetStatus(in *R } func Convert_extensions_ReplicaSet_to_v1_ReplicationController(in *extensions.ReplicaSet, out *ReplicationController, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_ReplicaSetSpec_to_v1_ReplicationControllerSpec(&in.Spec, &out.Spec, s); err != nil { fieldErr, ok := err.(*field.Error) if !ok { @@ -329,7 +315,7 @@ func Convert_extensions_ReplicaSetSpec_to_v1_ReplicationControllerSpec(in *exten out.MinReadySeconds = in.MinReadySeconds var invalidErr error if in.Selector != nil { - invalidErr = api.Convert_unversioned_LabelSelector_to_map(in.Selector, &out.Selector, s) + invalidErr = metav1.Convert_unversioned_LabelSelector_to_map(in.Selector, &out.Selector, s) } out.Template = new(PodTemplateSpec) if err := Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, out.Template, s); err != nil { @@ -493,6 +479,18 @@ func Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in *PodTemplateSpec, out // taking responsibility to ensure mutation of in is not exposed // back to the caller. in.Spec.InitContainers = values + + // Call defaulters explicitly until annotations are removed + tmpPodTemp := &PodTemplate{ + Template: PodTemplateSpec{ + Spec: PodSpec{ + HostNetwork: in.Spec.HostNetwork, + InitContainers: values, + }, + }, + } + SetObjectDefaults_PodTemplate(tmpPodTemp) + in.Spec.InitContainers = tmpPodTemp.Template.Spec.InitContainers } if err := autoConvert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in, out, s); err != nil { @@ -588,17 +586,6 @@ func Convert_api_Pod_To_v1_Pod(in *api.Pod, out *Pod, s conversion.Scope) error out.Annotations[PodInitContainerStatusesBetaAnnotationKey] = string(value) } - // We need to reset certain fields for mirror pods from pre-v1.1 kubelet - // (#15960). - // TODO: Remove this code after we drop support for v1.0 kubelets. - if value, ok := in.Annotations[mirrorAnnotationKey]; ok && value == mirrorAnnotationValue_1_0 { - // Reset the TerminationGracePeriodSeconds. - out.Spec.TerminationGracePeriodSeconds = nil - // Reset the resource requests. - for i := range out.Spec.Containers { - out.Spec.Containers[i].Resources.Requests = nil - } - } return nil } @@ -623,10 +610,14 @@ func Convert_v1_Pod_To_api_Pod(in *Pod, out *api.Pod, s conversion.Scope) error // back to the caller. in.Spec.InitContainers = values // Call defaulters explicitly until annotations are removed - for i := range in.Spec.InitContainers { - c := &in.Spec.InitContainers[i] - SetDefaults_Container(c) + tmpPod := &Pod{ + Spec: PodSpec{ + HostNetwork: in.Spec.HostNetwork, + InitContainers: values, + }, } + SetObjectDefaults_Pod(tmpPod) + in.Spec.InitContainers = tmpPod.Spec.InitContainers } // If there is a beta annotation, copy to alpha key. // See commit log for PR #31026 for why we do this. @@ -664,15 +655,6 @@ func Convert_v1_Pod_To_api_Pod(in *Pod, out *api.Pod, s conversion.Scope) error return nil } -func Convert_api_ServiceSpec_To_v1_ServiceSpec(in *api.ServiceSpec, out *ServiceSpec, s conversion.Scope) error { - if err := autoConvert_api_ServiceSpec_To_v1_ServiceSpec(in, out, s); err != nil { - return err - } - // Publish both externalIPs and deprecatedPublicIPs fields in v1. - out.DeprecatedPublicIPs = in.ExternalIPs - return nil -} - func Convert_v1_Secret_To_api_Secret(in *Secret, out *api.Secret, s conversion.Scope) error { if err := autoConvert_v1_Secret_To_api_Secret(in, out, s); err != nil { return err @@ -691,17 +673,6 @@ func Convert_v1_Secret_To_api_Secret(in *Secret, out *api.Secret, s conversion.S return nil } -func Convert_v1_ServiceSpec_To_api_ServiceSpec(in *ServiceSpec, out *api.ServiceSpec, s conversion.Scope) error { - if err := autoConvert_v1_ServiceSpec_To_api_ServiceSpec(in, out, s); err != nil { - return err - } - // Prefer the legacy deprecatedPublicIPs field, if provided. - if len(in.DeprecatedPublicIPs) > 0 { - out.ExternalIPs = in.DeprecatedPublicIPs - } - return nil -} - func Convert_api_PodSecurityContext_To_v1_PodSecurityContext(in *api.PodSecurityContext, out *PodSecurityContext, s conversion.Scope) error { out.SupplementalGroups = in.SupplementalGroups if in.SELinuxOptions != nil { diff --git a/vendor/k8s.io/client-go/pkg/api/v1/defaults.go b/vendor/k8s.io/client-go/pkg/api/v1/defaults.go index 92ddd38448..a791ba7b5c 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/defaults.go @@ -17,43 +17,14 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/util" - "k8s.io/client-go/pkg/util/intstr" "k8s.io/client-go/pkg/util/parsers" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_PodExecOptions, - SetDefaults_PodAttachOptions, - SetDefaults_ReplicationController, - SetDefaults_Volume, - SetDefaults_ContainerPort, - SetDefaults_Container, - SetDefaults_ServiceSpec, - SetDefaults_Pod, - SetDefaults_PodSpec, - SetDefaults_Probe, - SetDefaults_SecretVolumeSource, - SetDefaults_ConfigMapVolumeSource, - SetDefaults_DownwardAPIVolumeSource, - SetDefaults_Secret, - SetDefaults_PersistentVolume, - SetDefaults_PersistentVolumeClaim, - SetDefaults_ISCSIVolumeSource, - SetDefaults_Endpoints, - SetDefaults_HTTPGetAction, - SetDefaults_NamespaceStatus, - SetDefaults_Node, - SetDefaults_NodeStatus, - SetDefaults_ObjectFieldSelector, - SetDefaults_LimitRangeItem, - SetDefaults_ConfigMap, - SetDefaults_RBDVolumeSource, - SetDefaults_ResourceList, - ) + return RegisterDefaults(scheme) } func SetDefaults_ResourceList(obj *ResourceList) { @@ -112,7 +83,6 @@ func SetDefaults_Container(obj *Container) { _, tag, _, _ := parsers.ParseImageName(obj.Image) // Check image tag - if tag == "latest" { obj.ImagePullPolicy = PullAlways } else { @@ -122,16 +92,19 @@ func SetDefaults_Container(obj *Container) { if obj.TerminationMessagePath == "" { obj.TerminationMessagePath = TerminationMessagePathDefault } + if obj.TerminationMessagePolicy == "" { + obj.TerminationMessagePolicy = TerminationMessageReadFile + } } -func SetDefaults_ServiceSpec(obj *ServiceSpec) { - if obj.SessionAffinity == "" { - obj.SessionAffinity = ServiceAffinityNone +func SetDefaults_Service(obj *Service) { + if obj.Spec.SessionAffinity == "" { + obj.Spec.SessionAffinity = ServiceAffinityNone } - if obj.Type == "" { - obj.Type = ServiceTypeClusterIP + if obj.Spec.Type == "" { + obj.Spec.Type = ServiceTypeClusterIP } - for i := range obj.Ports { - sp := &obj.Ports[i] + for i := range obj.Spec.Ports { + sp := &obj.Spec.Ports[i] if sp.Protocol == "" { sp.Protocol = ProtocolTCP } @@ -139,6 +112,16 @@ func SetDefaults_ServiceSpec(obj *ServiceSpec) { sp.TargetPort = intstr.FromInt(int(sp.Port)) } } + // Defaults ExternalTrafficPolicy field for NodePort / LoadBalancer service + // to Global for consistency. + if _, ok := obj.Annotations[BetaAnnotationExternalTraffic]; ok { + // Don't default this field if beta annotation exists. + return + } else if (obj.Spec.Type == ServiceTypeNodePort || + obj.Spec.Type == ServiceTypeLoadBalancer) && + obj.Spec.ExternalTrafficPolicy == "" { + obj.Spec.ExternalTrafficPolicy = ServiceExternalTrafficPolicyTypeCluster + } } func SetDefaults_Pod(obj *Pod) { // If limits are specified, but requests are not, default requests to limits @@ -157,6 +140,18 @@ func SetDefaults_Pod(obj *Pod) { } } } + for i := range obj.Spec.InitContainers { + if obj.Spec.InitContainers[i].Resources.Limits != nil { + if obj.Spec.InitContainers[i].Resources.Requests == nil { + obj.Spec.InitContainers[i].Resources.Requests = make(ResourceList) + } + for key, value := range obj.Spec.InitContainers[i].Resources.Limits { + if _, exists := obj.Spec.InitContainers[i].Resources.Requests[key]; !exists { + obj.Spec.InitContainers[i].Resources.Requests[key] = *(value.Copy()) + } + } + } + } } func SetDefaults_PodSpec(obj *PodSpec) { if obj.DNSPolicy == "" { @@ -167,6 +162,7 @@ func SetDefaults_PodSpec(obj *PodSpec) { } if obj.HostNetwork { defaultHostNetworkPorts(&obj.Containers) + defaultHostNetworkPorts(&obj.InitContainers) } if obj.SecurityContext == nil { obj.SecurityContext = &PodSecurityContext{} @@ -175,6 +171,9 @@ func SetDefaults_PodSpec(obj *PodSpec) { period := int64(DefaultTerminationGracePeriodSeconds) obj.TerminationGracePeriodSeconds = &period } + if obj.SchedulerName == "" { + obj.SchedulerName = DefaultSchedulerName + } } func SetDefaults_Probe(obj *Probe) { if obj.TimeoutSeconds == 0 { @@ -213,6 +212,12 @@ func SetDefaults_Secret(obj *Secret) { obj.Type = SecretTypeOpaque } } +func SetDefaults_ProjectedVolumeSource(obj *ProjectedVolumeSource) { + if obj.DefaultMode == nil { + perm := int32(ProjectedVolumeSourceDefaultMode) + obj.DefaultMode = &perm + } +} func SetDefaults_PersistentVolume(obj *PersistentVolume) { if obj.Status.Phase == "" { obj.Status.Phase = VolumePending @@ -234,7 +239,11 @@ func SetDefaults_ISCSIVolumeSource(obj *ISCSIVolumeSource) { func SetDefaults_AzureDiskVolumeSource(obj *AzureDiskVolumeSource) { if obj.CachingMode == nil { obj.CachingMode = new(AzureDataDiskCachingMode) - *obj.CachingMode = AzureDataDiskCachingNone + *obj.CachingMode = AzureDataDiskCachingReadWrite + } + if obj.Kind == nil { + obj.Kind = new(AzureDataDiskKind) + *obj.Kind = AzureSharedBlobDisk } if obj.FSType == nil { obj.FSType = new(string) @@ -347,3 +356,18 @@ func SetDefaults_RBDVolumeSource(obj *RBDVolumeSource) { obj.Keyring = "/etc/ceph/keyring" } } + +func SetDefaults_ScaleIOVolumeSource(obj *ScaleIOVolumeSource) { + if obj.ProtectionDomain == "" { + obj.ProtectionDomain = "default" + } + if obj.StoragePool == "" { + obj.StoragePool = "default" + } + if obj.StorageMode == "" { + obj.StorageMode = "ThinProvisioned" + } + if obj.FSType == "" { + obj.FSType = "xfs" + } +} diff --git a/vendor/k8s.io/client-go/pkg/api/v1/doc.go b/vendor/k8s.io/client-go/pkg/api/v1/doc.go index 7c4d493241..0fdd87f750 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/doc.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/doc.go @@ -14,10 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/api -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - // Package v1 is the v1 version of the API. package v1 diff --git a/vendor/k8s.io/client-go/pkg/api/generate.go b/vendor/k8s.io/client-go/pkg/api/v1/generate.go similarity index 97% rename from vendor/k8s.io/client-go/pkg/api/generate.go rename to vendor/k8s.io/client-go/pkg/api/v1/generate.go index a4a003bac0..b8c44e4c7f 100644 --- a/vendor/k8s.io/client-go/pkg/api/generate.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/generate.go @@ -14,12 +14,12 @@ See the License for the specific language governing permissions and limitations under the License. */ -package api +package v1 import ( "fmt" - utilrand "k8s.io/client-go/pkg/util/rand" + utilrand "k8s.io/apimachinery/pkg/util/rand" ) // NameGenerator generates names for objects. Some backends may have more information diff --git a/vendor/k8s.io/client-go/pkg/api/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/api/v1/generated.pb.go index 69d224ce3c..dcfc99ea0f 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -39,8 +39,10 @@ limitations under the License. ComponentStatus ComponentStatusList ConfigMap + ConfigMapEnvSource ConfigMapKeySelector ConfigMapList + ConfigMapProjection ConfigMapVolumeSource Container ContainerImage @@ -52,6 +54,7 @@ limitations under the License. ContainerStatus DaemonEndpoint DeleteOptions + DownwardAPIProjection DownwardAPIVolumeFile DownwardAPIVolumeSource EmptyDirVolumeSource @@ -60,13 +63,13 @@ limitations under the License. EndpointSubset Endpoints EndpointsList + EnvFromSource EnvVar EnvVarSource Event EventList EventSource ExecAction - ExportOptions FCVolumeSource FlexVolumeSource FlockerVolumeSource @@ -76,6 +79,7 @@ limitations under the License. HTTPGetAction HTTPHeader Handler + HostAlias HostPathVolumeSource ISCSIVolumeSource KeyToPath @@ -89,6 +93,7 @@ limitations under the License. LoadBalancerIngress LoadBalancerStatus LocalObjectReference + LocalVolumeSource NFSVolumeSource Namespace NamespaceList @@ -101,6 +106,7 @@ limitations under the License. NodeDaemonEndpoints NodeList NodeProxyOptions + NodeResources NodeSelector NodeSelectorRequirement NodeSelectorTerm @@ -110,7 +116,6 @@ limitations under the License. ObjectFieldSelector ObjectMeta ObjectReference - OwnerReference PersistentVolume PersistentVolumeClaim PersistentVolumeClaimList @@ -131,6 +136,7 @@ limitations under the License. PodExecOptions PodList PodLogOptions + PodPortForwardOptions PodProxyOptions PodSecurityContext PodSignature @@ -140,10 +146,12 @@ limitations under the License. PodTemplate PodTemplateList PodTemplateSpec + PortworxVolumeSource Preconditions PreferAvoidPodsEntry PreferredSchedulingTerm Probe + ProjectedVolumeSource QuobyteVolumeSource RBDVolumeSource RangeAllocation @@ -159,9 +167,12 @@ limitations under the License. ResourceQuotaStatus ResourceRequirements SELinuxOptions + ScaleIOVolumeSource Secret + SecretEnvSource SecretKeySelector SecretList + SecretProjection SecretVolumeSource SecurityContext SerializedReference @@ -173,11 +184,15 @@ limitations under the License. ServiceProxyOptions ServiceSpec ServiceStatus + StorageOSPersistentVolumeSource + StorageOSVolumeSource + Sysctl TCPSocketAction Taint Toleration Volume VolumeMount + VolumeProjection VolumeSource VsphereVirtualDiskVolumeSource WeightedPodAffinityTerm @@ -188,15 +203,16 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_resource "k8s.io/client-go/pkg/api/resource" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" -import k8s_io_kubernetes_pkg_runtime "k8s.io/client-go/pkg/runtime" +import k8s_io_apimachinery_pkg_api_resource "k8s.io/apimachinery/pkg/api/resource" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" +import k8s_io_apimachinery_pkg_runtime "k8s.io/apimachinery/pkg/runtime" -import k8s_io_kubernetes_pkg_types "k8s.io/client-go/pkg/types" +import k8s_io_apimachinery_pkg_types "k8s.io/apimachinery/pkg/types" + +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import strings "strings" import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import io "io" @@ -207,7 +223,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *AWSElasticBlockStoreVolumeSource) Reset() { *m = AWSElasticBlockStoreVolumeSource{} } func (*AWSElasticBlockStoreVolumeSource) ProtoMessage() {} @@ -267,604 +285,668 @@ func (m *ConfigMap) Reset() { *m = ConfigMap{} } func (*ConfigMap) ProtoMessage() {} func (*ConfigMap) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } +func (m *ConfigMapEnvSource) Reset() { *m = ConfigMapEnvSource{} } +func (*ConfigMapEnvSource) ProtoMessage() {} +func (*ConfigMapEnvSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } + func (m *ConfigMapKeySelector) Reset() { *m = ConfigMapKeySelector{} } func (*ConfigMapKeySelector) ProtoMessage() {} -func (*ConfigMapKeySelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } +func (*ConfigMapKeySelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } func (m *ConfigMapList) Reset() { *m = ConfigMapList{} } func (*ConfigMapList) ProtoMessage() {} -func (*ConfigMapList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } +func (*ConfigMapList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } + +func (m *ConfigMapProjection) Reset() { *m = ConfigMapProjection{} } +func (*ConfigMapProjection) ProtoMessage() {} +func (*ConfigMapProjection) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } func (m *ConfigMapVolumeSource) Reset() { *m = ConfigMapVolumeSource{} } func (*ConfigMapVolumeSource) ProtoMessage() {} -func (*ConfigMapVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } +func (*ConfigMapVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} } func (m *Container) Reset() { *m = Container{} } func (*Container) ProtoMessage() {} -func (*Container) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } +func (*Container) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{19} } func (m *ContainerImage) Reset() { *m = ContainerImage{} } func (*ContainerImage) ProtoMessage() {} -func (*ContainerImage) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} } +func (*ContainerImage) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } func (m *ContainerPort) Reset() { *m = ContainerPort{} } func (*ContainerPort) ProtoMessage() {} -func (*ContainerPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{19} } +func (*ContainerPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } func (m *ContainerState) Reset() { *m = ContainerState{} } func (*ContainerState) ProtoMessage() {} -func (*ContainerState) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } +func (*ContainerState) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{22} } func (m *ContainerStateRunning) Reset() { *m = ContainerStateRunning{} } func (*ContainerStateRunning) ProtoMessage() {} -func (*ContainerStateRunning) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } +func (*ContainerStateRunning) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } func (m *ContainerStateTerminated) Reset() { *m = ContainerStateTerminated{} } func (*ContainerStateTerminated) ProtoMessage() {} func (*ContainerStateTerminated) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{22} + return fileDescriptorGenerated, []int{24} } func (m *ContainerStateWaiting) Reset() { *m = ContainerStateWaiting{} } func (*ContainerStateWaiting) ProtoMessage() {} -func (*ContainerStateWaiting) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } +func (*ContainerStateWaiting) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{25} } func (m *ContainerStatus) Reset() { *m = ContainerStatus{} } func (*ContainerStatus) ProtoMessage() {} -func (*ContainerStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{24} } +func (*ContainerStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{26} } func (m *DaemonEndpoint) Reset() { *m = DaemonEndpoint{} } func (*DaemonEndpoint) ProtoMessage() {} -func (*DaemonEndpoint) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{25} } +func (*DaemonEndpoint) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } func (m *DeleteOptions) Reset() { *m = DeleteOptions{} } func (*DeleteOptions) ProtoMessage() {} -func (*DeleteOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{26} } +func (*DeleteOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{28} } + +func (m *DownwardAPIProjection) Reset() { *m = DownwardAPIProjection{} } +func (*DownwardAPIProjection) ProtoMessage() {} +func (*DownwardAPIProjection) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } func (m *DownwardAPIVolumeFile) Reset() { *m = DownwardAPIVolumeFile{} } func (*DownwardAPIVolumeFile) ProtoMessage() {} -func (*DownwardAPIVolumeFile) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } +func (*DownwardAPIVolumeFile) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } func (m *DownwardAPIVolumeSource) Reset() { *m = DownwardAPIVolumeSource{} } func (*DownwardAPIVolumeSource) ProtoMessage() {} func (*DownwardAPIVolumeSource) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{28} + return fileDescriptorGenerated, []int{31} } func (m *EmptyDirVolumeSource) Reset() { *m = EmptyDirVolumeSource{} } func (*EmptyDirVolumeSource) ProtoMessage() {} -func (*EmptyDirVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } +func (*EmptyDirVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } func (m *EndpointAddress) Reset() { *m = EndpointAddress{} } func (*EndpointAddress) ProtoMessage() {} -func (*EndpointAddress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } +func (*EndpointAddress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } func (m *EndpointPort) Reset() { *m = EndpointPort{} } func (*EndpointPort) ProtoMessage() {} -func (*EndpointPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{31} } +func (*EndpointPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{34} } func (m *EndpointSubset) Reset() { *m = EndpointSubset{} } func (*EndpointSubset) ProtoMessage() {} -func (*EndpointSubset) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } +func (*EndpointSubset) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{35} } func (m *Endpoints) Reset() { *m = Endpoints{} } func (*Endpoints) ProtoMessage() {} -func (*Endpoints) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } +func (*Endpoints) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{36} } func (m *EndpointsList) Reset() { *m = EndpointsList{} } func (*EndpointsList) ProtoMessage() {} -func (*EndpointsList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{34} } +func (*EndpointsList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{37} } + +func (m *EnvFromSource) Reset() { *m = EnvFromSource{} } +func (*EnvFromSource) ProtoMessage() {} +func (*EnvFromSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{38} } func (m *EnvVar) Reset() { *m = EnvVar{} } func (*EnvVar) ProtoMessage() {} -func (*EnvVar) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{35} } +func (*EnvVar) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{39} } func (m *EnvVarSource) Reset() { *m = EnvVarSource{} } func (*EnvVarSource) ProtoMessage() {} -func (*EnvVarSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{36} } +func (*EnvVarSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{40} } func (m *Event) Reset() { *m = Event{} } func (*Event) ProtoMessage() {} -func (*Event) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{37} } +func (*Event) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{41} } func (m *EventList) Reset() { *m = EventList{} } func (*EventList) ProtoMessage() {} -func (*EventList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{38} } +func (*EventList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{42} } func (m *EventSource) Reset() { *m = EventSource{} } func (*EventSource) ProtoMessage() {} -func (*EventSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{39} } +func (*EventSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{43} } func (m *ExecAction) Reset() { *m = ExecAction{} } func (*ExecAction) ProtoMessage() {} -func (*ExecAction) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{40} } - -func (m *ExportOptions) Reset() { *m = ExportOptions{} } -func (*ExportOptions) ProtoMessage() {} -func (*ExportOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{41} } +func (*ExecAction) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{44} } func (m *FCVolumeSource) Reset() { *m = FCVolumeSource{} } func (*FCVolumeSource) ProtoMessage() {} -func (*FCVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{42} } +func (*FCVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{45} } func (m *FlexVolumeSource) Reset() { *m = FlexVolumeSource{} } func (*FlexVolumeSource) ProtoMessage() {} -func (*FlexVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{43} } +func (*FlexVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{46} } func (m *FlockerVolumeSource) Reset() { *m = FlockerVolumeSource{} } func (*FlockerVolumeSource) ProtoMessage() {} -func (*FlockerVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{44} } +func (*FlockerVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{47} } func (m *GCEPersistentDiskVolumeSource) Reset() { *m = GCEPersistentDiskVolumeSource{} } func (*GCEPersistentDiskVolumeSource) ProtoMessage() {} func (*GCEPersistentDiskVolumeSource) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{45} + return fileDescriptorGenerated, []int{48} } func (m *GitRepoVolumeSource) Reset() { *m = GitRepoVolumeSource{} } func (*GitRepoVolumeSource) ProtoMessage() {} -func (*GitRepoVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{46} } +func (*GitRepoVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{49} } func (m *GlusterfsVolumeSource) Reset() { *m = GlusterfsVolumeSource{} } func (*GlusterfsVolumeSource) ProtoMessage() {} -func (*GlusterfsVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{47} } +func (*GlusterfsVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{50} } func (m *HTTPGetAction) Reset() { *m = HTTPGetAction{} } func (*HTTPGetAction) ProtoMessage() {} -func (*HTTPGetAction) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{48} } +func (*HTTPGetAction) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{51} } func (m *HTTPHeader) Reset() { *m = HTTPHeader{} } func (*HTTPHeader) ProtoMessage() {} -func (*HTTPHeader) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{49} } +func (*HTTPHeader) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{52} } func (m *Handler) Reset() { *m = Handler{} } func (*Handler) ProtoMessage() {} -func (*Handler) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{50} } +func (*Handler) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{53} } + +func (m *HostAlias) Reset() { *m = HostAlias{} } +func (*HostAlias) ProtoMessage() {} +func (*HostAlias) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{54} } func (m *HostPathVolumeSource) Reset() { *m = HostPathVolumeSource{} } func (*HostPathVolumeSource) ProtoMessage() {} -func (*HostPathVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{51} } +func (*HostPathVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{55} } func (m *ISCSIVolumeSource) Reset() { *m = ISCSIVolumeSource{} } func (*ISCSIVolumeSource) ProtoMessage() {} -func (*ISCSIVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{52} } +func (*ISCSIVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{56} } func (m *KeyToPath) Reset() { *m = KeyToPath{} } func (*KeyToPath) ProtoMessage() {} -func (*KeyToPath) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{53} } +func (*KeyToPath) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{57} } func (m *Lifecycle) Reset() { *m = Lifecycle{} } func (*Lifecycle) ProtoMessage() {} -func (*Lifecycle) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{54} } +func (*Lifecycle) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{58} } func (m *LimitRange) Reset() { *m = LimitRange{} } func (*LimitRange) ProtoMessage() {} -func (*LimitRange) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{55} } +func (*LimitRange) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{59} } func (m *LimitRangeItem) Reset() { *m = LimitRangeItem{} } func (*LimitRangeItem) ProtoMessage() {} -func (*LimitRangeItem) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{56} } +func (*LimitRangeItem) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{60} } func (m *LimitRangeList) Reset() { *m = LimitRangeList{} } func (*LimitRangeList) ProtoMessage() {} -func (*LimitRangeList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{57} } +func (*LimitRangeList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{61} } func (m *LimitRangeSpec) Reset() { *m = LimitRangeSpec{} } func (*LimitRangeSpec) ProtoMessage() {} -func (*LimitRangeSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{58} } +func (*LimitRangeSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{62} } func (m *List) Reset() { *m = List{} } func (*List) ProtoMessage() {} -func (*List) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{59} } +func (*List) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{63} } func (m *ListOptions) Reset() { *m = ListOptions{} } func (*ListOptions) ProtoMessage() {} -func (*ListOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{60} } +func (*ListOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{64} } func (m *LoadBalancerIngress) Reset() { *m = LoadBalancerIngress{} } func (*LoadBalancerIngress) ProtoMessage() {} -func (*LoadBalancerIngress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{61} } +func (*LoadBalancerIngress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{65} } func (m *LoadBalancerStatus) Reset() { *m = LoadBalancerStatus{} } func (*LoadBalancerStatus) ProtoMessage() {} -func (*LoadBalancerStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{62} } +func (*LoadBalancerStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{66} } func (m *LocalObjectReference) Reset() { *m = LocalObjectReference{} } func (*LocalObjectReference) ProtoMessage() {} -func (*LocalObjectReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{63} } +func (*LocalObjectReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{67} } + +func (m *LocalVolumeSource) Reset() { *m = LocalVolumeSource{} } +func (*LocalVolumeSource) ProtoMessage() {} +func (*LocalVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{68} } func (m *NFSVolumeSource) Reset() { *m = NFSVolumeSource{} } func (*NFSVolumeSource) ProtoMessage() {} -func (*NFSVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{64} } +func (*NFSVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{69} } func (m *Namespace) Reset() { *m = Namespace{} } func (*Namespace) ProtoMessage() {} -func (*Namespace) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{65} } +func (*Namespace) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{70} } func (m *NamespaceList) Reset() { *m = NamespaceList{} } func (*NamespaceList) ProtoMessage() {} -func (*NamespaceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{66} } +func (*NamespaceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{71} } func (m *NamespaceSpec) Reset() { *m = NamespaceSpec{} } func (*NamespaceSpec) ProtoMessage() {} -func (*NamespaceSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{67} } +func (*NamespaceSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{72} } func (m *NamespaceStatus) Reset() { *m = NamespaceStatus{} } func (*NamespaceStatus) ProtoMessage() {} -func (*NamespaceStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{68} } +func (*NamespaceStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{73} } func (m *Node) Reset() { *m = Node{} } func (*Node) ProtoMessage() {} -func (*Node) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{69} } +func (*Node) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{74} } func (m *NodeAddress) Reset() { *m = NodeAddress{} } func (*NodeAddress) ProtoMessage() {} -func (*NodeAddress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{70} } +func (*NodeAddress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{75} } func (m *NodeAffinity) Reset() { *m = NodeAffinity{} } func (*NodeAffinity) ProtoMessage() {} -func (*NodeAffinity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{71} } +func (*NodeAffinity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{76} } func (m *NodeCondition) Reset() { *m = NodeCondition{} } func (*NodeCondition) ProtoMessage() {} -func (*NodeCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{72} } +func (*NodeCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{77} } func (m *NodeDaemonEndpoints) Reset() { *m = NodeDaemonEndpoints{} } func (*NodeDaemonEndpoints) ProtoMessage() {} -func (*NodeDaemonEndpoints) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{73} } +func (*NodeDaemonEndpoints) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{78} } func (m *NodeList) Reset() { *m = NodeList{} } func (*NodeList) ProtoMessage() {} -func (*NodeList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{74} } +func (*NodeList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{79} } func (m *NodeProxyOptions) Reset() { *m = NodeProxyOptions{} } func (*NodeProxyOptions) ProtoMessage() {} -func (*NodeProxyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{75} } +func (*NodeProxyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{80} } + +func (m *NodeResources) Reset() { *m = NodeResources{} } +func (*NodeResources) ProtoMessage() {} +func (*NodeResources) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{81} } func (m *NodeSelector) Reset() { *m = NodeSelector{} } func (*NodeSelector) ProtoMessage() {} -func (*NodeSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{76} } +func (*NodeSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{82} } func (m *NodeSelectorRequirement) Reset() { *m = NodeSelectorRequirement{} } func (*NodeSelectorRequirement) ProtoMessage() {} func (*NodeSelectorRequirement) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{77} + return fileDescriptorGenerated, []int{83} } func (m *NodeSelectorTerm) Reset() { *m = NodeSelectorTerm{} } func (*NodeSelectorTerm) ProtoMessage() {} -func (*NodeSelectorTerm) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{78} } +func (*NodeSelectorTerm) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{84} } func (m *NodeSpec) Reset() { *m = NodeSpec{} } func (*NodeSpec) ProtoMessage() {} -func (*NodeSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{79} } +func (*NodeSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{85} } func (m *NodeStatus) Reset() { *m = NodeStatus{} } func (*NodeStatus) ProtoMessage() {} -func (*NodeStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{80} } +func (*NodeStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{86} } func (m *NodeSystemInfo) Reset() { *m = NodeSystemInfo{} } func (*NodeSystemInfo) ProtoMessage() {} -func (*NodeSystemInfo) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{81} } +func (*NodeSystemInfo) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{87} } func (m *ObjectFieldSelector) Reset() { *m = ObjectFieldSelector{} } func (*ObjectFieldSelector) ProtoMessage() {} -func (*ObjectFieldSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{82} } +func (*ObjectFieldSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{88} } func (m *ObjectMeta) Reset() { *m = ObjectMeta{} } func (*ObjectMeta) ProtoMessage() {} -func (*ObjectMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{83} } +func (*ObjectMeta) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{89} } func (m *ObjectReference) Reset() { *m = ObjectReference{} } func (*ObjectReference) ProtoMessage() {} -func (*ObjectReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{84} } - -func (m *OwnerReference) Reset() { *m = OwnerReference{} } -func (*OwnerReference) ProtoMessage() {} -func (*OwnerReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{85} } +func (*ObjectReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{90} } func (m *PersistentVolume) Reset() { *m = PersistentVolume{} } func (*PersistentVolume) ProtoMessage() {} -func (*PersistentVolume) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{86} } +func (*PersistentVolume) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{91} } func (m *PersistentVolumeClaim) Reset() { *m = PersistentVolumeClaim{} } func (*PersistentVolumeClaim) ProtoMessage() {} -func (*PersistentVolumeClaim) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{87} } +func (*PersistentVolumeClaim) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{92} } func (m *PersistentVolumeClaimList) Reset() { *m = PersistentVolumeClaimList{} } func (*PersistentVolumeClaimList) ProtoMessage() {} func (*PersistentVolumeClaimList) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{88} + return fileDescriptorGenerated, []int{93} } func (m *PersistentVolumeClaimSpec) Reset() { *m = PersistentVolumeClaimSpec{} } func (*PersistentVolumeClaimSpec) ProtoMessage() {} func (*PersistentVolumeClaimSpec) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{89} + return fileDescriptorGenerated, []int{94} } func (m *PersistentVolumeClaimStatus) Reset() { *m = PersistentVolumeClaimStatus{} } func (*PersistentVolumeClaimStatus) ProtoMessage() {} func (*PersistentVolumeClaimStatus) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{90} + return fileDescriptorGenerated, []int{95} } func (m *PersistentVolumeClaimVolumeSource) Reset() { *m = PersistentVolumeClaimVolumeSource{} } func (*PersistentVolumeClaimVolumeSource) ProtoMessage() {} func (*PersistentVolumeClaimVolumeSource) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{91} + return fileDescriptorGenerated, []int{96} } func (m *PersistentVolumeList) Reset() { *m = PersistentVolumeList{} } func (*PersistentVolumeList) ProtoMessage() {} -func (*PersistentVolumeList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{92} } +func (*PersistentVolumeList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{97} } func (m *PersistentVolumeSource) Reset() { *m = PersistentVolumeSource{} } func (*PersistentVolumeSource) ProtoMessage() {} -func (*PersistentVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{93} } +func (*PersistentVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{98} } func (m *PersistentVolumeSpec) Reset() { *m = PersistentVolumeSpec{} } func (*PersistentVolumeSpec) ProtoMessage() {} -func (*PersistentVolumeSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{94} } +func (*PersistentVolumeSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{99} } -func (m *PersistentVolumeStatus) Reset() { *m = PersistentVolumeStatus{} } -func (*PersistentVolumeStatus) ProtoMessage() {} -func (*PersistentVolumeStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{95} } +func (m *PersistentVolumeStatus) Reset() { *m = PersistentVolumeStatus{} } +func (*PersistentVolumeStatus) ProtoMessage() {} +func (*PersistentVolumeStatus) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{100} +} func (m *PhotonPersistentDiskVolumeSource) Reset() { *m = PhotonPersistentDiskVolumeSource{} } func (*PhotonPersistentDiskVolumeSource) ProtoMessage() {} func (*PhotonPersistentDiskVolumeSource) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{96} + return fileDescriptorGenerated, []int{101} } func (m *Pod) Reset() { *m = Pod{} } func (*Pod) ProtoMessage() {} -func (*Pod) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{97} } +func (*Pod) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{102} } func (m *PodAffinity) Reset() { *m = PodAffinity{} } func (*PodAffinity) ProtoMessage() {} -func (*PodAffinity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{98} } +func (*PodAffinity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{103} } func (m *PodAffinityTerm) Reset() { *m = PodAffinityTerm{} } func (*PodAffinityTerm) ProtoMessage() {} -func (*PodAffinityTerm) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{99} } +func (*PodAffinityTerm) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{104} } func (m *PodAntiAffinity) Reset() { *m = PodAntiAffinity{} } func (*PodAntiAffinity) ProtoMessage() {} -func (*PodAntiAffinity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{100} } +func (*PodAntiAffinity) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{105} } func (m *PodAttachOptions) Reset() { *m = PodAttachOptions{} } func (*PodAttachOptions) ProtoMessage() {} -func (*PodAttachOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{101} } +func (*PodAttachOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{106} } func (m *PodCondition) Reset() { *m = PodCondition{} } func (*PodCondition) ProtoMessage() {} -func (*PodCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{102} } +func (*PodCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{107} } func (m *PodExecOptions) Reset() { *m = PodExecOptions{} } func (*PodExecOptions) ProtoMessage() {} -func (*PodExecOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{103} } +func (*PodExecOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{108} } func (m *PodList) Reset() { *m = PodList{} } func (*PodList) ProtoMessage() {} -func (*PodList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{104} } +func (*PodList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{109} } func (m *PodLogOptions) Reset() { *m = PodLogOptions{} } func (*PodLogOptions) ProtoMessage() {} -func (*PodLogOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{105} } +func (*PodLogOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{110} } + +func (m *PodPortForwardOptions) Reset() { *m = PodPortForwardOptions{} } +func (*PodPortForwardOptions) ProtoMessage() {} +func (*PodPortForwardOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{111} } func (m *PodProxyOptions) Reset() { *m = PodProxyOptions{} } func (*PodProxyOptions) ProtoMessage() {} -func (*PodProxyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{106} } +func (*PodProxyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{112} } func (m *PodSecurityContext) Reset() { *m = PodSecurityContext{} } func (*PodSecurityContext) ProtoMessage() {} -func (*PodSecurityContext) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{107} } +func (*PodSecurityContext) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{113} } func (m *PodSignature) Reset() { *m = PodSignature{} } func (*PodSignature) ProtoMessage() {} -func (*PodSignature) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{108} } +func (*PodSignature) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{114} } func (m *PodSpec) Reset() { *m = PodSpec{} } func (*PodSpec) ProtoMessage() {} -func (*PodSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{109} } +func (*PodSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{115} } func (m *PodStatus) Reset() { *m = PodStatus{} } func (*PodStatus) ProtoMessage() {} -func (*PodStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{110} } +func (*PodStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{116} } func (m *PodStatusResult) Reset() { *m = PodStatusResult{} } func (*PodStatusResult) ProtoMessage() {} -func (*PodStatusResult) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{111} } +func (*PodStatusResult) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{117} } func (m *PodTemplate) Reset() { *m = PodTemplate{} } func (*PodTemplate) ProtoMessage() {} -func (*PodTemplate) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{112} } +func (*PodTemplate) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{118} } func (m *PodTemplateList) Reset() { *m = PodTemplateList{} } func (*PodTemplateList) ProtoMessage() {} -func (*PodTemplateList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{113} } +func (*PodTemplateList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{119} } func (m *PodTemplateSpec) Reset() { *m = PodTemplateSpec{} } func (*PodTemplateSpec) ProtoMessage() {} -func (*PodTemplateSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{114} } +func (*PodTemplateSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{120} } + +func (m *PortworxVolumeSource) Reset() { *m = PortworxVolumeSource{} } +func (*PortworxVolumeSource) ProtoMessage() {} +func (*PortworxVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{121} } func (m *Preconditions) Reset() { *m = Preconditions{} } func (*Preconditions) ProtoMessage() {} -func (*Preconditions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{115} } +func (*Preconditions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{122} } func (m *PreferAvoidPodsEntry) Reset() { *m = PreferAvoidPodsEntry{} } func (*PreferAvoidPodsEntry) ProtoMessage() {} -func (*PreferAvoidPodsEntry) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{116} } +func (*PreferAvoidPodsEntry) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{123} } func (m *PreferredSchedulingTerm) Reset() { *m = PreferredSchedulingTerm{} } func (*PreferredSchedulingTerm) ProtoMessage() {} func (*PreferredSchedulingTerm) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{117} + return fileDescriptorGenerated, []int{124} } func (m *Probe) Reset() { *m = Probe{} } func (*Probe) ProtoMessage() {} -func (*Probe) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{118} } +func (*Probe) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{125} } + +func (m *ProjectedVolumeSource) Reset() { *m = ProjectedVolumeSource{} } +func (*ProjectedVolumeSource) ProtoMessage() {} +func (*ProjectedVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{126} } func (m *QuobyteVolumeSource) Reset() { *m = QuobyteVolumeSource{} } func (*QuobyteVolumeSource) ProtoMessage() {} -func (*QuobyteVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{119} } +func (*QuobyteVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{127} } func (m *RBDVolumeSource) Reset() { *m = RBDVolumeSource{} } func (*RBDVolumeSource) ProtoMessage() {} -func (*RBDVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{120} } +func (*RBDVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{128} } func (m *RangeAllocation) Reset() { *m = RangeAllocation{} } func (*RangeAllocation) ProtoMessage() {} -func (*RangeAllocation) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{121} } +func (*RangeAllocation) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{129} } func (m *ReplicationController) Reset() { *m = ReplicationController{} } func (*ReplicationController) ProtoMessage() {} -func (*ReplicationController) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{122} } +func (*ReplicationController) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{130} } func (m *ReplicationControllerCondition) Reset() { *m = ReplicationControllerCondition{} } func (*ReplicationControllerCondition) ProtoMessage() {} func (*ReplicationControllerCondition) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{123} + return fileDescriptorGenerated, []int{131} } func (m *ReplicationControllerList) Reset() { *m = ReplicationControllerList{} } func (*ReplicationControllerList) ProtoMessage() {} func (*ReplicationControllerList) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{124} + return fileDescriptorGenerated, []int{132} } func (m *ReplicationControllerSpec) Reset() { *m = ReplicationControllerSpec{} } func (*ReplicationControllerSpec) ProtoMessage() {} func (*ReplicationControllerSpec) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{125} + return fileDescriptorGenerated, []int{133} } func (m *ReplicationControllerStatus) Reset() { *m = ReplicationControllerStatus{} } func (*ReplicationControllerStatus) ProtoMessage() {} func (*ReplicationControllerStatus) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{126} + return fileDescriptorGenerated, []int{134} } func (m *ResourceFieldSelector) Reset() { *m = ResourceFieldSelector{} } func (*ResourceFieldSelector) ProtoMessage() {} -func (*ResourceFieldSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{127} } +func (*ResourceFieldSelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{135} } func (m *ResourceQuota) Reset() { *m = ResourceQuota{} } func (*ResourceQuota) ProtoMessage() {} -func (*ResourceQuota) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{128} } +func (*ResourceQuota) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{136} } func (m *ResourceQuotaList) Reset() { *m = ResourceQuotaList{} } func (*ResourceQuotaList) ProtoMessage() {} -func (*ResourceQuotaList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{129} } +func (*ResourceQuotaList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{137} } func (m *ResourceQuotaSpec) Reset() { *m = ResourceQuotaSpec{} } func (*ResourceQuotaSpec) ProtoMessage() {} -func (*ResourceQuotaSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{130} } +func (*ResourceQuotaSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{138} } func (m *ResourceQuotaStatus) Reset() { *m = ResourceQuotaStatus{} } func (*ResourceQuotaStatus) ProtoMessage() {} -func (*ResourceQuotaStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{131} } +func (*ResourceQuotaStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{139} } func (m *ResourceRequirements) Reset() { *m = ResourceRequirements{} } func (*ResourceRequirements) ProtoMessage() {} -func (*ResourceRequirements) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{132} } +func (*ResourceRequirements) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{140} } func (m *SELinuxOptions) Reset() { *m = SELinuxOptions{} } func (*SELinuxOptions) ProtoMessage() {} -func (*SELinuxOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{133} } +func (*SELinuxOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{141} } + +func (m *ScaleIOVolumeSource) Reset() { *m = ScaleIOVolumeSource{} } +func (*ScaleIOVolumeSource) ProtoMessage() {} +func (*ScaleIOVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{142} } func (m *Secret) Reset() { *m = Secret{} } func (*Secret) ProtoMessage() {} -func (*Secret) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{134} } +func (*Secret) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{143} } + +func (m *SecretEnvSource) Reset() { *m = SecretEnvSource{} } +func (*SecretEnvSource) ProtoMessage() {} +func (*SecretEnvSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{144} } func (m *SecretKeySelector) Reset() { *m = SecretKeySelector{} } func (*SecretKeySelector) ProtoMessage() {} -func (*SecretKeySelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{135} } +func (*SecretKeySelector) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{145} } func (m *SecretList) Reset() { *m = SecretList{} } func (*SecretList) ProtoMessage() {} -func (*SecretList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{136} } +func (*SecretList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{146} } + +func (m *SecretProjection) Reset() { *m = SecretProjection{} } +func (*SecretProjection) ProtoMessage() {} +func (*SecretProjection) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{147} } func (m *SecretVolumeSource) Reset() { *m = SecretVolumeSource{} } func (*SecretVolumeSource) ProtoMessage() {} -func (*SecretVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{137} } +func (*SecretVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{148} } func (m *SecurityContext) Reset() { *m = SecurityContext{} } func (*SecurityContext) ProtoMessage() {} -func (*SecurityContext) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{138} } +func (*SecurityContext) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{149} } func (m *SerializedReference) Reset() { *m = SerializedReference{} } func (*SerializedReference) ProtoMessage() {} -func (*SerializedReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{139} } +func (*SerializedReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{150} } func (m *Service) Reset() { *m = Service{} } func (*Service) ProtoMessage() {} -func (*Service) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{140} } +func (*Service) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{151} } func (m *ServiceAccount) Reset() { *m = ServiceAccount{} } func (*ServiceAccount) ProtoMessage() {} -func (*ServiceAccount) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{141} } +func (*ServiceAccount) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{152} } func (m *ServiceAccountList) Reset() { *m = ServiceAccountList{} } func (*ServiceAccountList) ProtoMessage() {} -func (*ServiceAccountList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{142} } +func (*ServiceAccountList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{153} } func (m *ServiceList) Reset() { *m = ServiceList{} } func (*ServiceList) ProtoMessage() {} -func (*ServiceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{143} } +func (*ServiceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{154} } func (m *ServicePort) Reset() { *m = ServicePort{} } func (*ServicePort) ProtoMessage() {} -func (*ServicePort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{144} } +func (*ServicePort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{155} } func (m *ServiceProxyOptions) Reset() { *m = ServiceProxyOptions{} } func (*ServiceProxyOptions) ProtoMessage() {} -func (*ServiceProxyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{145} } +func (*ServiceProxyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{156} } func (m *ServiceSpec) Reset() { *m = ServiceSpec{} } func (*ServiceSpec) ProtoMessage() {} -func (*ServiceSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{146} } +func (*ServiceSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{157} } func (m *ServiceStatus) Reset() { *m = ServiceStatus{} } func (*ServiceStatus) ProtoMessage() {} -func (*ServiceStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{147} } +func (*ServiceStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{158} } + +func (m *StorageOSPersistentVolumeSource) Reset() { *m = StorageOSPersistentVolumeSource{} } +func (*StorageOSPersistentVolumeSource) ProtoMessage() {} +func (*StorageOSPersistentVolumeSource) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{159} +} + +func (m *StorageOSVolumeSource) Reset() { *m = StorageOSVolumeSource{} } +func (*StorageOSVolumeSource) ProtoMessage() {} +func (*StorageOSVolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{160} } + +func (m *Sysctl) Reset() { *m = Sysctl{} } +func (*Sysctl) ProtoMessage() {} +func (*Sysctl) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{161} } func (m *TCPSocketAction) Reset() { *m = TCPSocketAction{} } func (*TCPSocketAction) ProtoMessage() {} -func (*TCPSocketAction) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{148} } +func (*TCPSocketAction) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{162} } func (m *Taint) Reset() { *m = Taint{} } func (*Taint) ProtoMessage() {} -func (*Taint) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{149} } +func (*Taint) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{163} } func (m *Toleration) Reset() { *m = Toleration{} } func (*Toleration) ProtoMessage() {} -func (*Toleration) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{150} } +func (*Toleration) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{164} } func (m *Volume) Reset() { *m = Volume{} } func (*Volume) ProtoMessage() {} -func (*Volume) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{151} } +func (*Volume) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{165} } func (m *VolumeMount) Reset() { *m = VolumeMount{} } func (*VolumeMount) ProtoMessage() {} -func (*VolumeMount) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{152} } +func (*VolumeMount) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{166} } + +func (m *VolumeProjection) Reset() { *m = VolumeProjection{} } +func (*VolumeProjection) ProtoMessage() {} +func (*VolumeProjection) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{167} } func (m *VolumeSource) Reset() { *m = VolumeSource{} } func (*VolumeSource) ProtoMessage() {} -func (*VolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{153} } +func (*VolumeSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{168} } func (m *VsphereVirtualDiskVolumeSource) Reset() { *m = VsphereVirtualDiskVolumeSource{} } func (*VsphereVirtualDiskVolumeSource) ProtoMessage() {} func (*VsphereVirtualDiskVolumeSource) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{154} + return fileDescriptorGenerated, []int{169} } func (m *WeightedPodAffinityTerm) Reset() { *m = WeightedPodAffinityTerm{} } func (*WeightedPodAffinityTerm) ProtoMessage() {} func (*WeightedPodAffinityTerm) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{155} + return fileDescriptorGenerated, []int{170} } func init() { @@ -882,8 +964,10 @@ func init() { proto.RegisterType((*ComponentStatus)(nil), "k8s.io.client-go.pkg.api.v1.ComponentStatus") proto.RegisterType((*ComponentStatusList)(nil), "k8s.io.client-go.pkg.api.v1.ComponentStatusList") proto.RegisterType((*ConfigMap)(nil), "k8s.io.client-go.pkg.api.v1.ConfigMap") + proto.RegisterType((*ConfigMapEnvSource)(nil), "k8s.io.client-go.pkg.api.v1.ConfigMapEnvSource") proto.RegisterType((*ConfigMapKeySelector)(nil), "k8s.io.client-go.pkg.api.v1.ConfigMapKeySelector") proto.RegisterType((*ConfigMapList)(nil), "k8s.io.client-go.pkg.api.v1.ConfigMapList") + proto.RegisterType((*ConfigMapProjection)(nil), "k8s.io.client-go.pkg.api.v1.ConfigMapProjection") proto.RegisterType((*ConfigMapVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.ConfigMapVolumeSource") proto.RegisterType((*Container)(nil), "k8s.io.client-go.pkg.api.v1.Container") proto.RegisterType((*ContainerImage)(nil), "k8s.io.client-go.pkg.api.v1.ContainerImage") @@ -895,6 +979,7 @@ func init() { proto.RegisterType((*ContainerStatus)(nil), "k8s.io.client-go.pkg.api.v1.ContainerStatus") proto.RegisterType((*DaemonEndpoint)(nil), "k8s.io.client-go.pkg.api.v1.DaemonEndpoint") proto.RegisterType((*DeleteOptions)(nil), "k8s.io.client-go.pkg.api.v1.DeleteOptions") + proto.RegisterType((*DownwardAPIProjection)(nil), "k8s.io.client-go.pkg.api.v1.DownwardAPIProjection") proto.RegisterType((*DownwardAPIVolumeFile)(nil), "k8s.io.client-go.pkg.api.v1.DownwardAPIVolumeFile") proto.RegisterType((*DownwardAPIVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.DownwardAPIVolumeSource") proto.RegisterType((*EmptyDirVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.EmptyDirVolumeSource") @@ -903,13 +988,13 @@ func init() { proto.RegisterType((*EndpointSubset)(nil), "k8s.io.client-go.pkg.api.v1.EndpointSubset") proto.RegisterType((*Endpoints)(nil), "k8s.io.client-go.pkg.api.v1.Endpoints") proto.RegisterType((*EndpointsList)(nil), "k8s.io.client-go.pkg.api.v1.EndpointsList") + proto.RegisterType((*EnvFromSource)(nil), "k8s.io.client-go.pkg.api.v1.EnvFromSource") proto.RegisterType((*EnvVar)(nil), "k8s.io.client-go.pkg.api.v1.EnvVar") proto.RegisterType((*EnvVarSource)(nil), "k8s.io.client-go.pkg.api.v1.EnvVarSource") proto.RegisterType((*Event)(nil), "k8s.io.client-go.pkg.api.v1.Event") proto.RegisterType((*EventList)(nil), "k8s.io.client-go.pkg.api.v1.EventList") proto.RegisterType((*EventSource)(nil), "k8s.io.client-go.pkg.api.v1.EventSource") proto.RegisterType((*ExecAction)(nil), "k8s.io.client-go.pkg.api.v1.ExecAction") - proto.RegisterType((*ExportOptions)(nil), "k8s.io.client-go.pkg.api.v1.ExportOptions") proto.RegisterType((*FCVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.FCVolumeSource") proto.RegisterType((*FlexVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.FlexVolumeSource") proto.RegisterType((*FlockerVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.FlockerVolumeSource") @@ -919,6 +1004,7 @@ func init() { proto.RegisterType((*HTTPGetAction)(nil), "k8s.io.client-go.pkg.api.v1.HTTPGetAction") proto.RegisterType((*HTTPHeader)(nil), "k8s.io.client-go.pkg.api.v1.HTTPHeader") proto.RegisterType((*Handler)(nil), "k8s.io.client-go.pkg.api.v1.Handler") + proto.RegisterType((*HostAlias)(nil), "k8s.io.client-go.pkg.api.v1.HostAlias") proto.RegisterType((*HostPathVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.HostPathVolumeSource") proto.RegisterType((*ISCSIVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.ISCSIVolumeSource") proto.RegisterType((*KeyToPath)(nil), "k8s.io.client-go.pkg.api.v1.KeyToPath") @@ -932,6 +1018,7 @@ func init() { proto.RegisterType((*LoadBalancerIngress)(nil), "k8s.io.client-go.pkg.api.v1.LoadBalancerIngress") proto.RegisterType((*LoadBalancerStatus)(nil), "k8s.io.client-go.pkg.api.v1.LoadBalancerStatus") proto.RegisterType((*LocalObjectReference)(nil), "k8s.io.client-go.pkg.api.v1.LocalObjectReference") + proto.RegisterType((*LocalVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.LocalVolumeSource") proto.RegisterType((*NFSVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.NFSVolumeSource") proto.RegisterType((*Namespace)(nil), "k8s.io.client-go.pkg.api.v1.Namespace") proto.RegisterType((*NamespaceList)(nil), "k8s.io.client-go.pkg.api.v1.NamespaceList") @@ -944,6 +1031,7 @@ func init() { proto.RegisterType((*NodeDaemonEndpoints)(nil), "k8s.io.client-go.pkg.api.v1.NodeDaemonEndpoints") proto.RegisterType((*NodeList)(nil), "k8s.io.client-go.pkg.api.v1.NodeList") proto.RegisterType((*NodeProxyOptions)(nil), "k8s.io.client-go.pkg.api.v1.NodeProxyOptions") + proto.RegisterType((*NodeResources)(nil), "k8s.io.client-go.pkg.api.v1.NodeResources") proto.RegisterType((*NodeSelector)(nil), "k8s.io.client-go.pkg.api.v1.NodeSelector") proto.RegisterType((*NodeSelectorRequirement)(nil), "k8s.io.client-go.pkg.api.v1.NodeSelectorRequirement") proto.RegisterType((*NodeSelectorTerm)(nil), "k8s.io.client-go.pkg.api.v1.NodeSelectorTerm") @@ -953,7 +1041,6 @@ func init() { proto.RegisterType((*ObjectFieldSelector)(nil), "k8s.io.client-go.pkg.api.v1.ObjectFieldSelector") proto.RegisterType((*ObjectMeta)(nil), "k8s.io.client-go.pkg.api.v1.ObjectMeta") proto.RegisterType((*ObjectReference)(nil), "k8s.io.client-go.pkg.api.v1.ObjectReference") - proto.RegisterType((*OwnerReference)(nil), "k8s.io.client-go.pkg.api.v1.OwnerReference") proto.RegisterType((*PersistentVolume)(nil), "k8s.io.client-go.pkg.api.v1.PersistentVolume") proto.RegisterType((*PersistentVolumeClaim)(nil), "k8s.io.client-go.pkg.api.v1.PersistentVolumeClaim") proto.RegisterType((*PersistentVolumeClaimList)(nil), "k8s.io.client-go.pkg.api.v1.PersistentVolumeClaimList") @@ -974,6 +1061,7 @@ func init() { proto.RegisterType((*PodExecOptions)(nil), "k8s.io.client-go.pkg.api.v1.PodExecOptions") proto.RegisterType((*PodList)(nil), "k8s.io.client-go.pkg.api.v1.PodList") proto.RegisterType((*PodLogOptions)(nil), "k8s.io.client-go.pkg.api.v1.PodLogOptions") + proto.RegisterType((*PodPortForwardOptions)(nil), "k8s.io.client-go.pkg.api.v1.PodPortForwardOptions") proto.RegisterType((*PodProxyOptions)(nil), "k8s.io.client-go.pkg.api.v1.PodProxyOptions") proto.RegisterType((*PodSecurityContext)(nil), "k8s.io.client-go.pkg.api.v1.PodSecurityContext") proto.RegisterType((*PodSignature)(nil), "k8s.io.client-go.pkg.api.v1.PodSignature") @@ -983,10 +1071,12 @@ func init() { proto.RegisterType((*PodTemplate)(nil), "k8s.io.client-go.pkg.api.v1.PodTemplate") proto.RegisterType((*PodTemplateList)(nil), "k8s.io.client-go.pkg.api.v1.PodTemplateList") proto.RegisterType((*PodTemplateSpec)(nil), "k8s.io.client-go.pkg.api.v1.PodTemplateSpec") + proto.RegisterType((*PortworxVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.PortworxVolumeSource") proto.RegisterType((*Preconditions)(nil), "k8s.io.client-go.pkg.api.v1.Preconditions") proto.RegisterType((*PreferAvoidPodsEntry)(nil), "k8s.io.client-go.pkg.api.v1.PreferAvoidPodsEntry") proto.RegisterType((*PreferredSchedulingTerm)(nil), "k8s.io.client-go.pkg.api.v1.PreferredSchedulingTerm") proto.RegisterType((*Probe)(nil), "k8s.io.client-go.pkg.api.v1.Probe") + proto.RegisterType((*ProjectedVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.ProjectedVolumeSource") proto.RegisterType((*QuobyteVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.QuobyteVolumeSource") proto.RegisterType((*RBDVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.RBDVolumeSource") proto.RegisterType((*RangeAllocation)(nil), "k8s.io.client-go.pkg.api.v1.RangeAllocation") @@ -1002,9 +1092,12 @@ func init() { proto.RegisterType((*ResourceQuotaStatus)(nil), "k8s.io.client-go.pkg.api.v1.ResourceQuotaStatus") proto.RegisterType((*ResourceRequirements)(nil), "k8s.io.client-go.pkg.api.v1.ResourceRequirements") proto.RegisterType((*SELinuxOptions)(nil), "k8s.io.client-go.pkg.api.v1.SELinuxOptions") + proto.RegisterType((*ScaleIOVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.ScaleIOVolumeSource") proto.RegisterType((*Secret)(nil), "k8s.io.client-go.pkg.api.v1.Secret") + proto.RegisterType((*SecretEnvSource)(nil), "k8s.io.client-go.pkg.api.v1.SecretEnvSource") proto.RegisterType((*SecretKeySelector)(nil), "k8s.io.client-go.pkg.api.v1.SecretKeySelector") proto.RegisterType((*SecretList)(nil), "k8s.io.client-go.pkg.api.v1.SecretList") + proto.RegisterType((*SecretProjection)(nil), "k8s.io.client-go.pkg.api.v1.SecretProjection") proto.RegisterType((*SecretVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.SecretVolumeSource") proto.RegisterType((*SecurityContext)(nil), "k8s.io.client-go.pkg.api.v1.SecurityContext") proto.RegisterType((*SerializedReference)(nil), "k8s.io.client-go.pkg.api.v1.SerializedReference") @@ -1016,92 +1109,96 @@ func init() { proto.RegisterType((*ServiceProxyOptions)(nil), "k8s.io.client-go.pkg.api.v1.ServiceProxyOptions") proto.RegisterType((*ServiceSpec)(nil), "k8s.io.client-go.pkg.api.v1.ServiceSpec") proto.RegisterType((*ServiceStatus)(nil), "k8s.io.client-go.pkg.api.v1.ServiceStatus") + proto.RegisterType((*StorageOSPersistentVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.StorageOSPersistentVolumeSource") + proto.RegisterType((*StorageOSVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.StorageOSVolumeSource") + proto.RegisterType((*Sysctl)(nil), "k8s.io.client-go.pkg.api.v1.Sysctl") proto.RegisterType((*TCPSocketAction)(nil), "k8s.io.client-go.pkg.api.v1.TCPSocketAction") proto.RegisterType((*Taint)(nil), "k8s.io.client-go.pkg.api.v1.Taint") proto.RegisterType((*Toleration)(nil), "k8s.io.client-go.pkg.api.v1.Toleration") proto.RegisterType((*Volume)(nil), "k8s.io.client-go.pkg.api.v1.Volume") proto.RegisterType((*VolumeMount)(nil), "k8s.io.client-go.pkg.api.v1.VolumeMount") + proto.RegisterType((*VolumeProjection)(nil), "k8s.io.client-go.pkg.api.v1.VolumeProjection") proto.RegisterType((*VolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.VolumeSource") proto.RegisterType((*VsphereVirtualDiskVolumeSource)(nil), "k8s.io.client-go.pkg.api.v1.VsphereVirtualDiskVolumeSource") proto.RegisterType((*WeightedPodAffinityTerm)(nil), "k8s.io.client-go.pkg.api.v1.WeightedPodAffinityTerm") } -func (m *AWSElasticBlockStoreVolumeSource) Marshal() (data []byte, err error) { +func (m *AWSElasticBlockStoreVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *AWSElasticBlockStoreVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *AWSElasticBlockStoreVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.VolumeID))) - i += copy(data[i:], m.VolumeID) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeID))) + i += copy(dAtA[i:], m.VolumeID) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.Partition)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.Partition)) + dAtA[i] = 0x20 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *Affinity) Marshal() (data []byte, err error) { +func (m *Affinity) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Affinity) MarshalTo(data []byte) (int, error) { +func (m *Affinity) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.NodeAffinity != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.NodeAffinity.Size())) - n1, err := m.NodeAffinity.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NodeAffinity.Size())) + n1, err := m.NodeAffinity.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 } if m.PodAffinity != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.PodAffinity.Size())) - n2, err := m.PodAffinity.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodAffinity.Size())) + n2, err := m.PodAffinity.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 } if m.PodAntiAffinity != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.PodAntiAffinity.Size())) - n3, err := m.PodAntiAffinity.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodAntiAffinity.Size())) + n3, err := m.PodAntiAffinity.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1110,53 +1207,53 @@ func (m *Affinity) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *AttachedVolume) Marshal() (data []byte, err error) { +func (m *AttachedVolume) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *AttachedVolume) MarshalTo(data []byte) (int, error) { +func (m *AttachedVolume) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DevicePath))) - i += copy(data[i:], m.DevicePath) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DevicePath))) + i += copy(dAtA[i:], m.DevicePath) return i, nil } -func (m *AvoidPods) Marshal() (data []byte, err error) { +func (m *AvoidPods) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *AvoidPods) MarshalTo(data []byte) (int, error) { +func (m *AvoidPods) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.PreferAvoidPods) > 0 { for _, msg := range m.PreferAvoidPods { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1166,115 +1263,121 @@ func (m *AvoidPods) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *AzureDiskVolumeSource) Marshal() (data []byte, err error) { +func (m *AzureDiskVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *AzureDiskVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *AzureDiskVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DiskName))) - i += copy(data[i:], m.DiskName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DiskName))) + i += copy(dAtA[i:], m.DiskName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DataDiskURI))) - i += copy(data[i:], m.DataDiskURI) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DataDiskURI))) + i += copy(dAtA[i:], m.DataDiskURI) if m.CachingMode != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(*m.CachingMode))) - i += copy(data[i:], *m.CachingMode) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.CachingMode))) + i += copy(dAtA[i:], *m.CachingMode) } if m.FSType != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(*m.FSType))) - i += copy(data[i:], *m.FSType) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FSType))) + i += copy(dAtA[i:], *m.FSType) } if m.ReadOnly != nil { - data[i] = 0x28 + dAtA[i] = 0x28 i++ if *m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } + if m.Kind != nil { + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Kind))) + i += copy(dAtA[i:], *m.Kind) + } return i, nil } -func (m *AzureFileVolumeSource) Marshal() (data []byte, err error) { +func (m *AzureFileVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *AzureFileVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *AzureFileVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SecretName))) - i += copy(data[i:], m.SecretName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SecretName))) + i += copy(dAtA[i:], m.SecretName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ShareName))) - i += copy(data[i:], m.ShareName) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ShareName))) + i += copy(dAtA[i:], m.ShareName) + dAtA[i] = 0x18 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *Binding) Marshal() (data []byte, err error) { +func (m *Binding) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Binding) MarshalTo(data []byte) (int, error) { +func (m *Binding) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n4, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Target.Size())) - n5, err := m.Target.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size())) + n5, err := m.Target.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1282,214 +1385,214 @@ func (m *Binding) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *Capabilities) Marshal() (data []byte, err error) { +func (m *Capabilities) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Capabilities) MarshalTo(data []byte) (int, error) { +func (m *Capabilities) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Add) > 0 { for _, s := range m.Add { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Drop) > 0 { for _, s := range m.Drop { - data[i] = 0x12 + dAtA[i] = 0x12 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *CephFSVolumeSource) Marshal() (data []byte, err error) { +func (m *CephFSVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CephFSVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *CephFSVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Monitors) > 0 { for _, s := range m.Monitors { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.User))) - i += copy(data[i:], m.User) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.User))) + i += copy(dAtA[i:], m.User) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SecretFile))) - i += copy(data[i:], m.SecretFile) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SecretFile))) + i += copy(dAtA[i:], m.SecretFile) if m.SecretRef != nil { - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.SecretRef.Size())) - n6, err := m.SecretRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n6, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n6 } - data[i] = 0x30 + dAtA[i] = 0x30 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *CinderVolumeSource) Marshal() (data []byte, err error) { +func (m *CinderVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CinderVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *CinderVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.VolumeID))) - i += copy(data[i:], m.VolumeID) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeID))) + i += copy(dAtA[i:], m.VolumeID) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x18 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *ComponentCondition) Marshal() (data []byte, err error) { +func (m *ComponentCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ComponentCondition) MarshalTo(data []byte) (int, error) { +func (m *ComponentCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Error))) - i += copy(data[i:], m.Error) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Error))) + i += copy(dAtA[i:], m.Error) return i, nil } -func (m *ComponentStatus) Marshal() (data []byte, err error) { +func (m *ComponentStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ComponentStatus) MarshalTo(data []byte) (int, error) { +func (m *ComponentStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n7, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n7, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1499,35 +1602,35 @@ func (m *ComponentStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ComponentStatusList) Marshal() (data []byte, err error) { +func (m *ComponentStatusList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ComponentStatusList) MarshalTo(data []byte) (int, error) { +func (m *ComponentStatusList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n8, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n8, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n8 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1537,108 +1640,159 @@ func (m *ComponentStatusList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ConfigMap) Marshal() (data []byte, err error) { +func (m *ConfigMap) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ConfigMap) MarshalTo(data []byte) (int, error) { +func (m *ConfigMap) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n9, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n9 if len(m.Data) > 0 { + keysForData := make([]string, 0, len(m.Data)) for k := range m.Data { - data[i] = 0x12 + keysForData = append(keysForData, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForData) + for _, k := range keysForData { + dAtA[i] = 0x12 i++ - v := m.Data[k] + v := m.Data[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } return i, nil } -func (m *ConfigMapKeySelector) Marshal() (data []byte, err error) { +func (m *ConfigMapEnvSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ConfigMapKeySelector) MarshalTo(data []byte) (int, error) { +func (m *ConfigMapEnvSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.LocalObjectReference.Size())) - n10, err := m.LocalObjectReference.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n10, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n10 - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) + if m.Optional != nil { + dAtA[i] = 0x10 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } return i, nil } -func (m *ConfigMapList) Marshal() (data []byte, err error) { +func (m *ConfigMapKeySelector) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ConfigMapList) MarshalTo(data []byte) (int, error) { +func (m *ConfigMapKeySelector) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n11, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n11, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n11 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + if m.Optional != nil { + dAtA[i] = 0x18 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + return i, nil +} + +func (m *ConfigMapList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ConfigMapList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n12, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n12 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1648,35 +1802,83 @@ func (m *ConfigMapList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ConfigMapVolumeSource) Marshal() (data []byte, err error) { +func (m *ConfigMapProjection) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ConfigMapVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *ConfigMapProjection) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.LocalObjectReference.Size())) - n12, err := m.LocalObjectReference.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n13, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n12 + i += n13 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.Optional != nil { + dAtA[i] = 0x20 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + return i, nil +} + +func (m *ConfigMapVolumeSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ConfigMapVolumeSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n14, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n14 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1684,76 +1886,86 @@ func (m *ConfigMapVolumeSource) MarshalTo(data []byte) (int, error) { } } if m.DefaultMode != nil { - data[i] = 0x18 + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.DefaultMode)) + } + if m.Optional != nil { + dAtA[i] = 0x20 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } i++ - i = encodeVarintGenerated(data, i, uint64(*m.DefaultMode)) } return i, nil } -func (m *Container) Marshal() (data []byte, err error) { +func (m *Container) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Container) MarshalTo(data []byte) (int, error) { +func (m *Container) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Image))) - i += copy(data[i:], m.Image) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Image))) + i += copy(dAtA[i:], m.Image) if len(m.Command) > 0 { for _, s := range m.Command { - data[i] = 0x1a + dAtA[i] = 0x1a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Args) > 0 { for _, s := range m.Args { - data[i] = 0x22 + dAtA[i] = 0x22 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.WorkingDir))) - i += copy(data[i:], m.WorkingDir) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.WorkingDir))) + i += copy(dAtA[i:], m.WorkingDir) if len(m.Ports) > 0 { for _, msg := range m.Ports { - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1762,30 +1974,30 @@ func (m *Container) MarshalTo(data []byte) (int, error) { } if len(m.Env) > 0 { for _, msg := range m.Env { - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(m.Resources.Size())) - n13, err := m.Resources.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Resources.Size())) + n15, err := m.Resources.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n13 + i += n15 if len(m.VolumeMounts) > 0 { for _, msg := range m.VolumeMounts { - data[i] = 0x4a + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1793,503 +2005,559 @@ func (m *Container) MarshalTo(data []byte) (int, error) { } } if m.LivenessProbe != nil { - data[i] = 0x52 + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(m.LivenessProbe.Size())) - n14, err := m.LivenessProbe.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LivenessProbe.Size())) + n16, err := m.LivenessProbe.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n14 + i += n16 } if m.ReadinessProbe != nil { - data[i] = 0x5a + dAtA[i] = 0x5a i++ - i = encodeVarintGenerated(data, i, uint64(m.ReadinessProbe.Size())) - n15, err := m.ReadinessProbe.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ReadinessProbe.Size())) + n17, err := m.ReadinessProbe.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n15 + i += n17 } if m.Lifecycle != nil { - data[i] = 0x62 + dAtA[i] = 0x62 i++ - i = encodeVarintGenerated(data, i, uint64(m.Lifecycle.Size())) - n16, err := m.Lifecycle.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Lifecycle.Size())) + n18, err := m.Lifecycle.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n16 + i += n18 } - data[i] = 0x6a + dAtA[i] = 0x6a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.TerminationMessagePath))) - i += copy(data[i:], m.TerminationMessagePath) - data[i] = 0x72 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TerminationMessagePath))) + i += copy(dAtA[i:], m.TerminationMessagePath) + dAtA[i] = 0x72 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ImagePullPolicy))) - i += copy(data[i:], m.ImagePullPolicy) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ImagePullPolicy))) + i += copy(dAtA[i:], m.ImagePullPolicy) if m.SecurityContext != nil { - data[i] = 0x7a + dAtA[i] = 0x7a i++ - i = encodeVarintGenerated(data, i, uint64(m.SecurityContext.Size())) - n17, err := m.SecurityContext.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SecurityContext.Size())) + n19, err := m.SecurityContext.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n17 + i += n19 } - data[i] = 0x80 + dAtA[i] = 0x80 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ if m.Stdin { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x88 + dAtA[i] = 0x88 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ if m.StdinOnce { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x90 + dAtA[i] = 0x90 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ if m.TTY { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ + if len(m.EnvFrom) > 0 { + for _, msg := range m.EnvFrom { + dAtA[i] = 0x9a + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + dAtA[i] = 0xa2 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TerminationMessagePolicy))) + i += copy(dAtA[i:], m.TerminationMessagePolicy) return i, nil } -func (m *ContainerImage) Marshal() (data []byte, err error) { +func (m *ContainerImage) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerImage) MarshalTo(data []byte) (int, error) { +func (m *ContainerImage) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Names) > 0 { for _, s := range m.Names { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.SizeBytes)) + i = encodeVarintGenerated(dAtA, i, uint64(m.SizeBytes)) return i, nil } -func (m *ContainerPort) Marshal() (data []byte, err error) { +func (m *ContainerPort) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerPort) MarshalTo(data []byte) (int, error) { +func (m *ContainerPort) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.HostPort)) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.HostPort)) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.ContainerPort)) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(m.ContainerPort)) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Protocol))) - i += copy(data[i:], m.Protocol) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) + i += copy(dAtA[i:], m.Protocol) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.HostIP))) - i += copy(data[i:], m.HostIP) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.HostIP))) + i += copy(dAtA[i:], m.HostIP) return i, nil } -func (m *ContainerState) Marshal() (data []byte, err error) { +func (m *ContainerState) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerState) MarshalTo(data []byte) (int, error) { +func (m *ContainerState) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Waiting != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Waiting.Size())) - n18, err := m.Waiting.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Waiting.Size())) + n20, err := m.Waiting.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n18 + i += n20 } if m.Running != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Running.Size())) - n19, err := m.Running.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Running.Size())) + n21, err := m.Running.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n19 + i += n21 } if m.Terminated != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Terminated.Size())) - n20, err := m.Terminated.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Terminated.Size())) + n22, err := m.Terminated.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n20 + i += n22 } return i, nil } -func (m *ContainerStateRunning) Marshal() (data []byte, err error) { +func (m *ContainerStateRunning) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerStateRunning) MarshalTo(data []byte) (int, error) { +func (m *ContainerStateRunning) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.StartedAt.Size())) - n21, err := m.StartedAt.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.StartedAt.Size())) + n23, err := m.StartedAt.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n21 + i += n23 return i, nil } -func (m *ContainerStateTerminated) Marshal() (data []byte, err error) { +func (m *ContainerStateTerminated) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerStateTerminated) MarshalTo(data []byte) (int, error) { +func (m *ContainerStateTerminated) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.ExitCode)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.ExitCode)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.Signal)) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(m.Signal)) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.StartedAt.Size())) - n22, err := m.StartedAt.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.StartedAt.Size())) + n24, err := m.StartedAt.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n22 - data[i] = 0x32 + i += n24 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.FinishedAt.Size())) - n23, err := m.FinishedAt.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FinishedAt.Size())) + n25, err := m.FinishedAt.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n23 - data[i] = 0x3a + i += n25 + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ContainerID))) - i += copy(data[i:], m.ContainerID) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ContainerID))) + i += copy(dAtA[i:], m.ContainerID) return i, nil } -func (m *ContainerStateWaiting) Marshal() (data []byte, err error) { +func (m *ContainerStateWaiting) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerStateWaiting) MarshalTo(data []byte) (int, error) { +func (m *ContainerStateWaiting) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *ContainerStatus) Marshal() (data []byte, err error) { +func (m *ContainerStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ContainerStatus) MarshalTo(data []byte) (int, error) { +func (m *ContainerStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.State.Size())) - n24, err := m.State.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.State.Size())) + n26, err := m.State.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n24 - data[i] = 0x1a + i += n26 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTerminationState.Size())) - n25, err := m.LastTerminationState.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTerminationState.Size())) + n27, err := m.LastTerminationState.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n25 - data[i] = 0x20 + i += n27 + dAtA[i] = 0x20 i++ if m.Ready { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x28 + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.RestartCount)) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(m.RestartCount)) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Image))) - i += copy(data[i:], m.Image) - data[i] = 0x3a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Image))) + i += copy(dAtA[i:], m.Image) + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ImageID))) - i += copy(data[i:], m.ImageID) - data[i] = 0x42 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ImageID))) + i += copy(dAtA[i:], m.ImageID) + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ContainerID))) - i += copy(data[i:], m.ContainerID) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ContainerID))) + i += copy(dAtA[i:], m.ContainerID) return i, nil } -func (m *DaemonEndpoint) Marshal() (data []byte, err error) { +func (m *DaemonEndpoint) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DaemonEndpoint) MarshalTo(data []byte) (int, error) { +func (m *DaemonEndpoint) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Port)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) return i, nil } -func (m *DeleteOptions) Marshal() (data []byte, err error) { +func (m *DeleteOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeleteOptions) MarshalTo(data []byte) (int, error) { +func (m *DeleteOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.GracePeriodSeconds != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.GracePeriodSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.GracePeriodSeconds)) } if m.Preconditions != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Preconditions.Size())) - n26, err := m.Preconditions.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Preconditions.Size())) + n28, err := m.Preconditions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n26 + i += n28 } if m.OrphanDependents != nil { - data[i] = 0x18 + dAtA[i] = 0x18 i++ if *m.OrphanDependents { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } + if m.PropagationPolicy != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.PropagationPolicy))) + i += copy(dAtA[i:], *m.PropagationPolicy) + } + return i, nil +} + +func (m *DownwardAPIProjection) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DownwardAPIProjection) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } return i, nil } -func (m *DownwardAPIVolumeFile) Marshal() (data []byte, err error) { +func (m *DownwardAPIVolumeFile) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DownwardAPIVolumeFile) MarshalTo(data []byte) (int, error) { +func (m *DownwardAPIVolumeFile) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) if m.FieldRef != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.FieldRef.Size())) - n27, err := m.FieldRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FieldRef.Size())) + n29, err := m.FieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n27 + i += n29 } if m.ResourceFieldRef != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.ResourceFieldRef.Size())) - n28, err := m.ResourceFieldRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceFieldRef.Size())) + n30, err := m.ResourceFieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n28 + i += n30 } if m.Mode != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Mode)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Mode)) } return i, nil } -func (m *DownwardAPIVolumeSource) Marshal() (data []byte, err error) { +func (m *DownwardAPIVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DownwardAPIVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *DownwardAPIVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2297,127 +2565,135 @@ func (m *DownwardAPIVolumeSource) MarshalTo(data []byte) (int, error) { } } if m.DefaultMode != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.DefaultMode)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.DefaultMode)) } return i, nil } -func (m *EmptyDirVolumeSource) Marshal() (data []byte, err error) { +func (m *EmptyDirVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EmptyDirVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *EmptyDirVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Medium))) - i += copy(data[i:], m.Medium) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Medium))) + i += copy(dAtA[i:], m.Medium) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SizeLimit.Size())) + n31, err := m.SizeLimit.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n31 return i, nil } -func (m *EndpointAddress) Marshal() (data []byte, err error) { +func (m *EndpointAddress) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EndpointAddress) MarshalTo(data []byte) (int, error) { +func (m *EndpointAddress) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.IP))) - i += copy(data[i:], m.IP) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.IP))) + i += copy(dAtA[i:], m.IP) if m.TargetRef != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.TargetRef.Size())) - n29, err := m.TargetRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetRef.Size())) + n32, err := m.TargetRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n29 + i += n32 } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Hostname))) - i += copy(data[i:], m.Hostname) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Hostname))) + i += copy(dAtA[i:], m.Hostname) if m.NodeName != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(*m.NodeName))) - i += copy(data[i:], *m.NodeName) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.NodeName))) + i += copy(dAtA[i:], *m.NodeName) } return i, nil } -func (m *EndpointPort) Marshal() (data []byte, err error) { +func (m *EndpointPort) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EndpointPort) MarshalTo(data []byte) (int, error) { +func (m *EndpointPort) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.Port)) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Protocol))) - i += copy(data[i:], m.Protocol) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) + i += copy(dAtA[i:], m.Protocol) return i, nil } -func (m *EndpointSubset) Marshal() (data []byte, err error) { +func (m *EndpointSubset) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EndpointSubset) MarshalTo(data []byte) (int, error) { +func (m *EndpointSubset) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Addresses) > 0 { for _, msg := range m.Addresses { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2426,10 +2702,10 @@ func (m *EndpointSubset) MarshalTo(data []byte) (int, error) { } if len(m.NotReadyAddresses) > 0 { for _, msg := range m.NotReadyAddresses { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2438,10 +2714,10 @@ func (m *EndpointSubset) MarshalTo(data []byte) (int, error) { } if len(m.Ports) > 0 { for _, msg := range m.Ports { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2451,35 +2727,35 @@ func (m *EndpointSubset) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *Endpoints) Marshal() (data []byte, err error) { +func (m *Endpoints) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Endpoints) MarshalTo(data []byte) (int, error) { +func (m *Endpoints) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n30, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n33, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n30 + i += n33 if len(m.Subsets) > 0 { for _, msg := range m.Subsets { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2489,35 +2765,35 @@ func (m *Endpoints) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *EndpointsList) Marshal() (data []byte, err error) { +func (m *EndpointsList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EndpointsList) MarshalTo(data []byte) (int, error) { +func (m *EndpointsList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n31, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n34, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n31 + i += n34 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2527,202 +2803,244 @@ func (m *EndpointsList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *EnvVar) Marshal() (data []byte, err error) { +func (m *EnvFromSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *EnvFromSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Prefix))) + i += copy(dAtA[i:], m.Prefix) + if m.ConfigMapRef != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMapRef.Size())) + n35, err := m.ConfigMapRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n35 + } + if m.SecretRef != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n36, err := m.SecretRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n36 + } + return i, nil +} + +func (m *EnvVar) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EnvVar) MarshalTo(data []byte) (int, error) { +func (m *EnvVar) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Value))) - i += copy(data[i:], m.Value) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Value))) + i += copy(dAtA[i:], m.Value) if m.ValueFrom != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.ValueFrom.Size())) - n32, err := m.ValueFrom.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ValueFrom.Size())) + n37, err := m.ValueFrom.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n32 + i += n37 } return i, nil } -func (m *EnvVarSource) Marshal() (data []byte, err error) { +func (m *EnvVarSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EnvVarSource) MarshalTo(data []byte) (int, error) { +func (m *EnvVarSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.FieldRef != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.FieldRef.Size())) - n33, err := m.FieldRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FieldRef.Size())) + n38, err := m.FieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n33 + i += n38 } if m.ResourceFieldRef != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.ResourceFieldRef.Size())) - n34, err := m.ResourceFieldRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceFieldRef.Size())) + n39, err := m.ResourceFieldRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n34 + i += n39 } if m.ConfigMapKeyRef != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.ConfigMapKeyRef.Size())) - n35, err := m.ConfigMapKeyRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMapKeyRef.Size())) + n40, err := m.ConfigMapKeyRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n35 + i += n40 } if m.SecretKeyRef != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.SecretKeyRef.Size())) - n36, err := m.SecretKeyRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretKeyRef.Size())) + n41, err := m.SecretKeyRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n36 + i += n41 } return i, nil } -func (m *Event) Marshal() (data []byte, err error) { +func (m *Event) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Event) MarshalTo(data []byte) (int, error) { +func (m *Event) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n37, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n42, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n37 - data[i] = 0x12 + i += n42 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.InvolvedObject.Size())) - n38, err := m.InvolvedObject.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.InvolvedObject.Size())) + n43, err := m.InvolvedObject.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n38 - data[i] = 0x1a + i += n43 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.Source.Size())) - n39, err := m.Source.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Source.Size())) + n44, err := m.Source.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n39 - data[i] = 0x32 + i += n44 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.FirstTimestamp.Size())) - n40, err := m.FirstTimestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FirstTimestamp.Size())) + n45, err := m.FirstTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n40 - data[i] = 0x3a + i += n45 + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTimestamp.Size())) - n41, err := m.LastTimestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTimestamp.Size())) + n46, err := m.LastTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n41 - data[i] = 0x40 + i += n46 + dAtA[i] = 0x40 i++ - i = encodeVarintGenerated(data, i, uint64(m.Count)) - data[i] = 0x4a + i = encodeVarintGenerated(dAtA, i, uint64(m.Count)) + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) return i, nil } -func (m *EventList) Marshal() (data []byte, err error) { +func (m *EventList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EventList) MarshalTo(data []byte) (int, error) { +func (m *EventList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n42, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n47, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n42 + i += n47 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2732,378 +3050,349 @@ func (m *EventList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *EventSource) Marshal() (data []byte, err error) { +func (m *EventSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *EventSource) MarshalTo(data []byte) (int, error) { +func (m *EventSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Component))) - i += copy(data[i:], m.Component) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Component))) + i += copy(dAtA[i:], m.Component) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Host))) - i += copy(data[i:], m.Host) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) + i += copy(dAtA[i:], m.Host) return i, nil } -func (m *ExecAction) Marshal() (data []byte, err error) { +func (m *ExecAction) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ExecAction) MarshalTo(data []byte) (int, error) { +func (m *ExecAction) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Command) > 0 { for _, s := range m.Command { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *ExportOptions) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *ExportOptions) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0x8 - i++ - if m.Export { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - data[i] = 0x10 - i++ - if m.Exact { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - return i, nil -} - -func (m *FCVolumeSource) Marshal() (data []byte, err error) { +func (m *FCVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *FCVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *FCVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.TargetWWNs) > 0 { for _, s := range m.TargetWWNs { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if m.Lun != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Lun)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Lun)) } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x20 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *FlexVolumeSource) Marshal() (data []byte, err error) { +func (m *FlexVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *FlexVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *FlexVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Driver))) - i += copy(data[i:], m.Driver) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Driver))) + i += copy(dAtA[i:], m.Driver) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) if m.SecretRef != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.SecretRef.Size())) - n43, err := m.SecretRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n48, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n43 + i += n48 } - data[i] = 0x20 + dAtA[i] = 0x20 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if len(m.Options) > 0 { + keysForOptions := make([]string, 0, len(m.Options)) for k := range m.Options { - data[i] = 0x2a + keysForOptions = append(keysForOptions, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForOptions) + for _, k := range keysForOptions { + dAtA[i] = 0x2a i++ - v := m.Options[k] + v := m.Options[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } return i, nil } -func (m *FlockerVolumeSource) Marshal() (data []byte, err error) { +func (m *FlockerVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *FlockerVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *FlockerVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DatasetName))) - i += copy(data[i:], m.DatasetName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DatasetName))) + i += copy(dAtA[i:], m.DatasetName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DatasetUUID))) - i += copy(data[i:], m.DatasetUUID) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DatasetUUID))) + i += copy(dAtA[i:], m.DatasetUUID) return i, nil } -func (m *GCEPersistentDiskVolumeSource) Marshal() (data []byte, err error) { +func (m *GCEPersistentDiskVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *GCEPersistentDiskVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *GCEPersistentDiskVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.PDName))) - i += copy(data[i:], m.PDName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.PDName))) + i += copy(dAtA[i:], m.PDName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.Partition)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.Partition)) + dAtA[i] = 0x20 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *GitRepoVolumeSource) Marshal() (data []byte, err error) { +func (m *GitRepoVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *GitRepoVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *GitRepoVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Repository))) - i += copy(data[i:], m.Repository) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Repository))) + i += copy(dAtA[i:], m.Repository) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Revision))) - i += copy(data[i:], m.Revision) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Revision))) + i += copy(dAtA[i:], m.Revision) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Directory))) - i += copy(data[i:], m.Directory) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Directory))) + i += copy(dAtA[i:], m.Directory) return i, nil } -func (m *GlusterfsVolumeSource) Marshal() (data []byte, err error) { +func (m *GlusterfsVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *GlusterfsVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *GlusterfsVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.EndpointsName))) - i += copy(data[i:], m.EndpointsName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.EndpointsName))) + i += copy(dAtA[i:], m.EndpointsName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x18 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *HTTPGetAction) Marshal() (data []byte, err error) { +func (m *HTTPGetAction) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HTTPGetAction) MarshalTo(data []byte) (int, error) { +func (m *HTTPGetAction) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Port.Size())) - n44, err := m.Port.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) + n49, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n44 - data[i] = 0x1a + i += n49 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Host))) - i += copy(data[i:], m.Host) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) + i += copy(dAtA[i:], m.Host) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Scheme))) - i += copy(data[i:], m.Scheme) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Scheme))) + i += copy(dAtA[i:], m.Scheme) if len(m.HTTPHeaders) > 0 { for _, msg := range m.HTTPHeaders { - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3113,411 +3402,534 @@ func (m *HTTPGetAction) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *HTTPHeader) Marshal() (data []byte, err error) { +func (m *HTTPHeader) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HTTPHeader) MarshalTo(data []byte) (int, error) { +func (m *HTTPHeader) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Value))) - i += copy(data[i:], m.Value) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Value))) + i += copy(dAtA[i:], m.Value) return i, nil } -func (m *Handler) Marshal() (data []byte, err error) { +func (m *Handler) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Handler) MarshalTo(data []byte) (int, error) { +func (m *Handler) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Exec != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Exec.Size())) - n45, err := m.Exec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Exec.Size())) + n50, err := m.Exec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n45 + i += n50 } if m.HTTPGet != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.HTTPGet.Size())) - n46, err := m.HTTPGet.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.HTTPGet.Size())) + n51, err := m.HTTPGet.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n46 + i += n51 } if m.TCPSocket != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.TCPSocket.Size())) - n47, err := m.TCPSocket.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.TCPSocket.Size())) + n52, err := m.TCPSocket.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n47 + i += n52 + } + return i, nil +} + +func (m *HostAlias) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HostAlias) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.IP))) + i += copy(dAtA[i:], m.IP) + if len(m.Hostnames) > 0 { + for _, s := range m.Hostnames { + dAtA[i] = 0x12 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } } return i, nil } -func (m *HostPathVolumeSource) Marshal() (data []byte, err error) { +func (m *HostPathVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HostPathVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *HostPathVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) return i, nil } -func (m *ISCSIVolumeSource) Marshal() (data []byte, err error) { +func (m *ISCSIVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ISCSIVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *ISCSIVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.TargetPortal))) - i += copy(data[i:], m.TargetPortal) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TargetPortal))) + i += copy(dAtA[i:], m.TargetPortal) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.IQN))) - i += copy(data[i:], m.IQN) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.IQN))) + i += copy(dAtA[i:], m.IQN) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.Lun)) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(m.Lun)) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ISCSIInterface))) - i += copy(data[i:], m.ISCSIInterface) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ISCSIInterface))) + i += copy(dAtA[i:], m.ISCSIInterface) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) - data[i] = 0x30 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x30 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + if len(m.Portals) > 0 { + for _, s := range m.Portals { + dAtA[i] = 0x3a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + dAtA[i] = 0x40 + i++ + if m.DiscoveryCHAPAuth { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + if m.SecretRef != nil { + dAtA[i] = 0x52 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n53, err := m.SecretRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n53 + } + dAtA[i] = 0x58 + i++ + if m.SessionCHAPAuth { + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *KeyToPath) Marshal() (data []byte, err error) { +func (m *KeyToPath) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *KeyToPath) MarshalTo(data []byte) (int, error) { +func (m *KeyToPath) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) if m.Mode != nil { - data[i] = 0x18 + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Mode)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Mode)) } return i, nil } -func (m *Lifecycle) Marshal() (data []byte, err error) { +func (m *Lifecycle) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Lifecycle) MarshalTo(data []byte) (int, error) { +func (m *Lifecycle) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.PostStart != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.PostStart.Size())) - n48, err := m.PostStart.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PostStart.Size())) + n54, err := m.PostStart.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n48 + i += n54 } if m.PreStop != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.PreStop.Size())) - n49, err := m.PreStop.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PreStop.Size())) + n55, err := m.PreStop.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n49 + i += n55 } return i, nil } -func (m *LimitRange) Marshal() (data []byte, err error) { +func (m *LimitRange) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LimitRange) MarshalTo(data []byte) (int, error) { +func (m *LimitRange) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n50, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n56, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n50 - data[i] = 0x12 + i += n56 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n51, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n57, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n51 + i += n57 return i, nil } -func (m *LimitRangeItem) Marshal() (data []byte, err error) { +func (m *LimitRangeItem) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LimitRangeItem) MarshalTo(data []byte) (int, error) { +func (m *LimitRangeItem) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) if len(m.Max) > 0 { + keysForMax := make([]string, 0, len(m.Max)) for k := range m.Max { - data[i] = 0x12 + keysForMax = append(keysForMax, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForMax) + for _, k := range keysForMax { + dAtA[i] = 0x12 i++ - v := m.Max[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Max[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n52, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n58, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n52 + i += n58 } } if len(m.Min) > 0 { + keysForMin := make([]string, 0, len(m.Min)) for k := range m.Min { - data[i] = 0x1a + keysForMin = append(keysForMin, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForMin) + for _, k := range keysForMin { + dAtA[i] = 0x1a i++ - v := m.Min[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Min[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n53, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n59, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n53 + i += n59 } } if len(m.Default) > 0 { + keysForDefault := make([]string, 0, len(m.Default)) for k := range m.Default { - data[i] = 0x22 + keysForDefault = append(keysForDefault, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForDefault) + for _, k := range keysForDefault { + dAtA[i] = 0x22 i++ - v := m.Default[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Default[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n54, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n60, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n54 + i += n60 } } if len(m.DefaultRequest) > 0 { + keysForDefaultRequest := make([]string, 0, len(m.DefaultRequest)) for k := range m.DefaultRequest { - data[i] = 0x2a + keysForDefaultRequest = append(keysForDefaultRequest, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForDefaultRequest) + for _, k := range keysForDefaultRequest { + dAtA[i] = 0x2a i++ - v := m.DefaultRequest[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.DefaultRequest[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n55, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n61, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n55 + i += n61 } } if len(m.MaxLimitRequestRatio) > 0 { + keysForMaxLimitRequestRatio := make([]string, 0, len(m.MaxLimitRequestRatio)) for k := range m.MaxLimitRequestRatio { - data[i] = 0x32 + keysForMaxLimitRequestRatio = append(keysForMaxLimitRequestRatio, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForMaxLimitRequestRatio) + for _, k := range keysForMaxLimitRequestRatio { + dAtA[i] = 0x32 i++ - v := m.MaxLimitRequestRatio[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.MaxLimitRequestRatio[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n56, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n62, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n56 + i += n62 } } return i, nil } -func (m *LimitRangeList) Marshal() (data []byte, err error) { +func (m *LimitRangeList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LimitRangeList) MarshalTo(data []byte) (int, error) { +func (m *LimitRangeList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n57, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n63, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n57 + i += n63 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3527,27 +3939,27 @@ func (m *LimitRangeList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *LimitRangeSpec) Marshal() (data []byte, err error) { +func (m *LimitRangeSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LimitRangeSpec) MarshalTo(data []byte) (int, error) { +func (m *LimitRangeSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Limits) > 0 { for _, msg := range m.Limits { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3557,35 +3969,35 @@ func (m *LimitRangeSpec) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *List) Marshal() (data []byte, err error) { +func (m *List) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *List) MarshalTo(data []byte) (int, error) { +func (m *List) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n58, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n64, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n58 + i += n64 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3595,96 +4007,104 @@ func (m *List) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ListOptions) Marshal() (data []byte, err error) { +func (m *ListOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ListOptions) MarshalTo(data []byte) (int, error) { +func (m *ListOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.LabelSelector))) - i += copy(data[i:], m.LabelSelector) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.LabelSelector))) + i += copy(dAtA[i:], m.LabelSelector) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FieldSelector))) - i += copy(data[i:], m.FieldSelector) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldSelector))) + i += copy(dAtA[i:], m.FieldSelector) + dAtA[i] = 0x18 i++ if m.Watch { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion))) - i += copy(data[i:], m.ResourceVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) if m.TimeoutSeconds != nil { - data[i] = 0x28 + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(*m.TimeoutSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.TimeoutSeconds)) } + dAtA[i] = 0x30 + i++ + if m.IncludeUninitialized { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ return i, nil } -func (m *LoadBalancerIngress) Marshal() (data []byte, err error) { +func (m *LoadBalancerIngress) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LoadBalancerIngress) MarshalTo(data []byte) (int, error) { +func (m *LoadBalancerIngress) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.IP))) - i += copy(data[i:], m.IP) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.IP))) + i += copy(dAtA[i:], m.IP) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Hostname))) - i += copy(data[i:], m.Hostname) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Hostname))) + i += copy(dAtA[i:], m.Hostname) return i, nil } -func (m *LoadBalancerStatus) Marshal() (data []byte, err error) { +func (m *LoadBalancerStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LoadBalancerStatus) MarshalTo(data []byte) (int, error) { +func (m *LoadBalancerStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Ingress) > 0 { for _, msg := range m.Ingress { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3694,133 +4114,155 @@ func (m *LoadBalancerStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *LocalObjectReference) Marshal() (data []byte, err error) { +func (m *LocalObjectReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LocalObjectReference) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func (m *LocalVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LocalObjectReference) MarshalTo(data []byte) (int, error) { +func (m *LocalVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) return i, nil } -func (m *NFSVolumeSource) Marshal() (data []byte, err error) { +func (m *NFSVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NFSVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *NFSVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Server))) - i += copy(data[i:], m.Server) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Server))) + i += copy(dAtA[i:], m.Server) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x18 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *Namespace) Marshal() (data []byte, err error) { +func (m *Namespace) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Namespace) MarshalTo(data []byte) (int, error) { +func (m *Namespace) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n59, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n65, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n59 - data[i] = 0x12 + i += n65 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n60, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n66, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n60 - data[i] = 0x1a + i += n66 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n61, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n67, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n61 + i += n67 return i, nil } -func (m *NamespaceList) Marshal() (data []byte, err error) { +func (m *NamespaceList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NamespaceList) MarshalTo(data []byte) (int, error) { +func (m *NamespaceList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n62, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n68, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n62 + i += n68 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3830,160 +4272,160 @@ func (m *NamespaceList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NamespaceSpec) Marshal() (data []byte, err error) { +func (m *NamespaceSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NamespaceSpec) MarshalTo(data []byte) (int, error) { +func (m *NamespaceSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Finalizers) > 0 { for _, s := range m.Finalizers { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *NamespaceStatus) Marshal() (data []byte, err error) { +func (m *NamespaceStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NamespaceStatus) MarshalTo(data []byte) (int, error) { +func (m *NamespaceStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Phase))) - i += copy(data[i:], m.Phase) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Phase))) + i += copy(dAtA[i:], m.Phase) return i, nil } -func (m *Node) Marshal() (data []byte, err error) { +func (m *Node) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Node) MarshalTo(data []byte) (int, error) { +func (m *Node) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n63, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n69, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n63 - data[i] = 0x12 + i += n69 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n64, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n70, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n64 - data[i] = 0x1a + i += n70 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n65, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n71, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n65 + i += n71 return i, nil } -func (m *NodeAddress) Marshal() (data []byte, err error) { +func (m *NodeAddress) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeAddress) MarshalTo(data []byte) (int, error) { +func (m *NodeAddress) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Address))) - i += copy(data[i:], m.Address) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Address))) + i += copy(dAtA[i:], m.Address) return i, nil } -func (m *NodeAffinity) Marshal() (data []byte, err error) { +func (m *NodeAffinity) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeAffinity) MarshalTo(data []byte) (int, error) { +func (m *NodeAffinity) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.RequiredDuringSchedulingIgnoredDuringExecution != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.RequiredDuringSchedulingIgnoredDuringExecution.Size())) - n66, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RequiredDuringSchedulingIgnoredDuringExecution.Size())) + n72, err := m.RequiredDuringSchedulingIgnoredDuringExecution.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n66 + i += n72 } if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3993,111 +4435,111 @@ func (m *NodeAffinity) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeCondition) Marshal() (data []byte, err error) { +func (m *NodeCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeCondition) MarshalTo(data []byte) (int, error) { +func (m *NodeCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastHeartbeatTime.Size())) - n67, err := m.LastHeartbeatTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastHeartbeatTime.Size())) + n73, err := m.LastHeartbeatTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n67 - data[i] = 0x22 + i += n73 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n68, err := m.LastTransitionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n74, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n68 - data[i] = 0x2a + i += n74 + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *NodeDaemonEndpoints) Marshal() (data []byte, err error) { +func (m *NodeDaemonEndpoints) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeDaemonEndpoints) MarshalTo(data []byte) (int, error) { +func (m *NodeDaemonEndpoints) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.KubeletEndpoint.Size())) - n69, err := m.KubeletEndpoint.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.KubeletEndpoint.Size())) + n75, err := m.KubeletEndpoint.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n69 + i += n75 return i, nil } -func (m *NodeList) Marshal() (data []byte, err error) { +func (m *NodeList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeList) MarshalTo(data []byte) (int, error) { +func (m *NodeList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n70, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n76, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n70 + i += n76 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4107,49 +4549,98 @@ func (m *NodeList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeProxyOptions) Marshal() (data []byte, err error) { +func (m *NodeProxyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeProxyOptions) MarshalTo(data []byte) (int, error) { +func (m *NodeProxyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + return i, nil +} + +func (m *NodeResources) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NodeResources) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Capacity) > 0 { + keysForCapacity := make([]string, 0, len(m.Capacity)) + for k := range m.Capacity { + keysForCapacity = append(keysForCapacity, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForCapacity) + for _, k := range keysForCapacity { + dAtA[i] = 0xa + i++ + v := m.Capacity[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n77, err := (&v).MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n77 + } + } return i, nil } -func (m *NodeSelector) Marshal() (data []byte, err error) { +func (m *NodeSelector) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeSelector) MarshalTo(data []byte) (int, error) { +func (m *NodeSelector) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.NodeSelectorTerms) > 0 { for _, msg := range m.NodeSelectorTerms { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4159,68 +4650,68 @@ func (m *NodeSelector) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeSelectorRequirement) Marshal() (data []byte, err error) { +func (m *NodeSelectorRequirement) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeSelectorRequirement) MarshalTo(data []byte) (int, error) { +func (m *NodeSelectorRequirement) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Operator))) - i += copy(data[i:], m.Operator) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Operator))) + i += copy(dAtA[i:], m.Operator) if len(m.Values) > 0 { for _, s := range m.Values { - data[i] = 0x1a + dAtA[i] = 0x1a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *NodeSelectorTerm) Marshal() (data []byte, err error) { +func (m *NodeSelectorTerm) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeSelectorTerm) MarshalTo(data []byte) (int, error) { +func (m *NodeSelectorTerm) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.MatchExpressions) > 0 { for _, msg := range m.MatchExpressions { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4230,113 +4721,143 @@ func (m *NodeSelectorTerm) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeSpec) Marshal() (data []byte, err error) { +func (m *NodeSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeSpec) MarshalTo(data []byte) (int, error) { +func (m *NodeSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.PodCIDR))) - i += copy(data[i:], m.PodCIDR) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.PodCIDR))) + i += copy(dAtA[i:], m.PodCIDR) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ExternalID))) - i += copy(data[i:], m.ExternalID) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ExternalID))) + i += copy(dAtA[i:], m.ExternalID) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ProviderID))) - i += copy(data[i:], m.ProviderID) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ProviderID))) + i += copy(dAtA[i:], m.ProviderID) + dAtA[i] = 0x20 i++ if m.Unschedulable { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ + if len(m.Taints) > 0 { + for _, msg := range m.Taints { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } return i, nil } -func (m *NodeStatus) Marshal() (data []byte, err error) { +func (m *NodeStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeStatus) MarshalTo(data []byte) (int, error) { +func (m *NodeStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Capacity) > 0 { + keysForCapacity := make([]string, 0, len(m.Capacity)) for k := range m.Capacity { - data[i] = 0xa + keysForCapacity = append(keysForCapacity, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForCapacity) + for _, k := range keysForCapacity { + dAtA[i] = 0xa i++ - v := m.Capacity[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Capacity[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n71, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n78, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n71 + i += n78 } } if len(m.Allocatable) > 0 { + keysForAllocatable := make([]string, 0, len(m.Allocatable)) for k := range m.Allocatable { - data[i] = 0x12 + keysForAllocatable = append(keysForAllocatable, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForAllocatable) + for _, k := range keysForAllocatable { + dAtA[i] = 0x12 i++ - v := m.Allocatable[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Allocatable[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n72, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n79, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n72 + i += n79 } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Phase))) - i += copy(data[i:], m.Phase) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Phase))) + i += copy(dAtA[i:], m.Phase) if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4345,38 +4866,38 @@ func (m *NodeStatus) MarshalTo(data []byte) (int, error) { } if len(m.Addresses) > 0 { for _, msg := range m.Addresses { - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.DaemonEndpoints.Size())) - n73, err := m.DaemonEndpoints.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.DaemonEndpoints.Size())) + n80, err := m.DaemonEndpoints.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n73 - data[i] = 0x3a + i += n80 + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.NodeInfo.Size())) - n74, err := m.NodeInfo.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NodeInfo.Size())) + n81, err := m.NodeInfo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n74 + i += n81 if len(m.Images) > 0 { for _, msg := range m.Images { - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4385,25 +4906,25 @@ func (m *NodeStatus) MarshalTo(data []byte) (int, error) { } if len(m.VolumesInUse) > 0 { for _, s := range m.VolumesInUse { - data[i] = 0x4a + dAtA[i] = 0x4a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.VolumesAttached) > 0 { for _, msg := range m.VolumesAttached { - data[i] = 0x52 + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4413,195 +4934,205 @@ func (m *NodeStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NodeSystemInfo) Marshal() (data []byte, err error) { +func (m *NodeSystemInfo) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NodeSystemInfo) MarshalTo(data []byte) (int, error) { +func (m *NodeSystemInfo) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.MachineID))) - i += copy(data[i:], m.MachineID) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MachineID))) + i += copy(dAtA[i:], m.MachineID) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SystemUUID))) - i += copy(data[i:], m.SystemUUID) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SystemUUID))) + i += copy(dAtA[i:], m.SystemUUID) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.BootID))) - i += copy(data[i:], m.BootID) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.BootID))) + i += copy(dAtA[i:], m.BootID) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.KernelVersion))) - i += copy(data[i:], m.KernelVersion) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.KernelVersion))) + i += copy(dAtA[i:], m.KernelVersion) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.OSImage))) - i += copy(data[i:], m.OSImage) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.OSImage))) + i += copy(dAtA[i:], m.OSImage) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ContainerRuntimeVersion))) - i += copy(data[i:], m.ContainerRuntimeVersion) - data[i] = 0x3a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ContainerRuntimeVersion))) + i += copy(dAtA[i:], m.ContainerRuntimeVersion) + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.KubeletVersion))) - i += copy(data[i:], m.KubeletVersion) - data[i] = 0x42 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.KubeletVersion))) + i += copy(dAtA[i:], m.KubeletVersion) + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.KubeProxyVersion))) - i += copy(data[i:], m.KubeProxyVersion) - data[i] = 0x4a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.KubeProxyVersion))) + i += copy(dAtA[i:], m.KubeProxyVersion) + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.OperatingSystem))) - i += copy(data[i:], m.OperatingSystem) - data[i] = 0x52 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.OperatingSystem))) + i += copy(dAtA[i:], m.OperatingSystem) + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Architecture))) - i += copy(data[i:], m.Architecture) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Architecture))) + i += copy(dAtA[i:], m.Architecture) return i, nil } -func (m *ObjectFieldSelector) Marshal() (data []byte, err error) { +func (m *ObjectFieldSelector) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ObjectFieldSelector) MarshalTo(data []byte) (int, error) { +func (m *ObjectFieldSelector) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FieldPath))) - i += copy(data[i:], m.FieldPath) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldPath))) + i += copy(dAtA[i:], m.FieldPath) return i, nil } -func (m *ObjectMeta) Marshal() (data []byte, err error) { +func (m *ObjectMeta) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ObjectMeta) MarshalTo(data []byte) (int, error) { +func (m *ObjectMeta) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.GenerateName))) - i += copy(data[i:], m.GenerateName) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.GenerateName))) + i += copy(dAtA[i:], m.GenerateName) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Namespace))) - i += copy(data[i:], m.Namespace) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SelfLink))) - i += copy(data[i:], m.SelfLink) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SelfLink))) + i += copy(dAtA[i:], m.SelfLink) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.UID))) - i += copy(data[i:], m.UID) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion))) - i += copy(data[i:], m.ResourceVersion) - data[i] = 0x38 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) + dAtA[i] = 0x38 i++ - i = encodeVarintGenerated(data, i, uint64(m.Generation)) - data[i] = 0x42 + i = encodeVarintGenerated(dAtA, i, uint64(m.Generation)) + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(m.CreationTimestamp.Size())) - n75, err := m.CreationTimestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.CreationTimestamp.Size())) + n82, err := m.CreationTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n75 + i += n82 if m.DeletionTimestamp != nil { - data[i] = 0x4a + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(m.DeletionTimestamp.Size())) - n76, err := m.DeletionTimestamp.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.DeletionTimestamp.Size())) + n83, err := m.DeletionTimestamp.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n76 + i += n83 } if m.DeletionGracePeriodSeconds != nil { - data[i] = 0x50 + dAtA[i] = 0x50 i++ - i = encodeVarintGenerated(data, i, uint64(*m.DeletionGracePeriodSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.DeletionGracePeriodSeconds)) } if len(m.Labels) > 0 { + keysForLabels := make([]string, 0, len(m.Labels)) for k := range m.Labels { - data[i] = 0x5a + keysForLabels = append(keysForLabels, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForLabels) + for _, k := range keysForLabels { + dAtA[i] = 0x5a i++ - v := m.Labels[k] + v := m.Labels[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } if len(m.Annotations) > 0 { + keysForAnnotations := make([]string, 0, len(m.Annotations)) for k := range m.Annotations { - data[i] = 0x62 + keysForAnnotations = append(keysForAnnotations, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForAnnotations) + for _, k := range keysForAnnotations { + dAtA[i] = 0x62 i++ - v := m.Annotations[k] + v := m.Annotations[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } if len(m.OwnerReferences) > 0 { for _, msg := range m.OwnerReferences { - data[i] = 0x6a + dAtA[i] = 0x6a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4610,229 +5141,197 @@ func (m *ObjectMeta) MarshalTo(data []byte) (int, error) { } if len(m.Finalizers) > 0 { for _, s := range m.Finalizers { - data[i] = 0x72 + dAtA[i] = 0x72 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x7a + dAtA[i] = 0x7a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ClusterName))) - i += copy(data[i:], m.ClusterName) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ClusterName))) + i += copy(dAtA[i:], m.ClusterName) + if m.Initializers != nil { + dAtA[i] = 0x82 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Initializers.Size())) + n84, err := m.Initializers.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n84 + } return i, nil } -func (m *ObjectReference) Marshal() (data []byte, err error) { +func (m *ObjectReference) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ObjectReference) MarshalTo(data []byte) (int, error) { +func (m *ObjectReference) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x12 + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Namespace))) - i += copy(data[i:], m.Namespace) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.UID))) - i += copy(data[i:], m.UID) - data[i] = 0x2a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - data[i] = 0x32 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ResourceVersion))) - i += copy(data[i:], m.ResourceVersion) - data[i] = 0x3a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FieldPath))) - i += copy(data[i:], m.FieldPath) - return i, nil -} - -func (m *OwnerReference) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *OwnerReference) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.UID))) - i += copy(data[i:], m.UID) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ResourceVersion))) + i += copy(dAtA[i:], m.ResourceVersion) + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - if m.Controller != nil { - data[i] = 0x30 - i++ - if *m.Controller { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - } + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FieldPath))) + i += copy(dAtA[i:], m.FieldPath) return i, nil } -func (m *PersistentVolume) Marshal() (data []byte, err error) { +func (m *PersistentVolume) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolume) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolume) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n77, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n85, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n77 - data[i] = 0x12 + i += n85 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n78, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n86, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n78 - data[i] = 0x1a + i += n86 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n79, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n87, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n79 + i += n87 return i, nil } -func (m *PersistentVolumeClaim) Marshal() (data []byte, err error) { +func (m *PersistentVolumeClaim) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeClaim) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeClaim) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n80, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n88, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n80 - data[i] = 0x12 + i += n88 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n81, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n89, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n81 - data[i] = 0x1a + i += n89 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n82, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n90, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n82 + i += n90 return i, nil } -func (m *PersistentVolumeClaimList) Marshal() (data []byte, err error) { +func (m *PersistentVolumeClaimList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeClaimList) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeClaimList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n83, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n91, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n83 + i += n91 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -4842,179 +5341,194 @@ func (m *PersistentVolumeClaimList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PersistentVolumeClaimSpec) Marshal() (data []byte, err error) { +func (m *PersistentVolumeClaimSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeClaimSpec) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeClaimSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.AccessModes) > 0 { for _, s := range m.AccessModes { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Resources.Size())) - n84, err := m.Resources.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Resources.Size())) + n92, err := m.Resources.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n84 - data[i] = 0x1a + i += n92 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.VolumeName))) - i += copy(data[i:], m.VolumeName) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeName))) + i += copy(dAtA[i:], m.VolumeName) if m.Selector != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n85, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n93, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n85 + i += n93 + } + if m.StorageClassName != nil { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.StorageClassName))) + i += copy(dAtA[i:], *m.StorageClassName) } return i, nil } -func (m *PersistentVolumeClaimStatus) Marshal() (data []byte, err error) { +func (m *PersistentVolumeClaimStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeClaimStatus) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeClaimStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Phase))) - i += copy(data[i:], m.Phase) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Phase))) + i += copy(dAtA[i:], m.Phase) if len(m.AccessModes) > 0 { for _, s := range m.AccessModes { - data[i] = 0x12 + dAtA[i] = 0x12 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Capacity) > 0 { + keysForCapacity := make([]string, 0, len(m.Capacity)) for k := range m.Capacity { - data[i] = 0x1a + keysForCapacity = append(keysForCapacity, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForCapacity) + for _, k := range keysForCapacity { + dAtA[i] = 0x1a i++ - v := m.Capacity[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Capacity[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n86, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n94, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n86 + i += n94 } } return i, nil } -func (m *PersistentVolumeClaimVolumeSource) Marshal() (data []byte, err error) { +func (m *PersistentVolumeClaimVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeClaimVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeClaimVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ClaimName))) - i += copy(data[i:], m.ClaimName) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ClaimName))) + i += copy(dAtA[i:], m.ClaimName) + dAtA[i] = 0x10 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *PersistentVolumeList) Marshal() (data []byte, err error) { +func (m *PersistentVolumeList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeList) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n87, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n95, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n87 + i += n95 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5024,394 +5538,455 @@ func (m *PersistentVolumeList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PersistentVolumeSource) Marshal() (data []byte, err error) { +func (m *PersistentVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.GCEPersistentDisk != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.GCEPersistentDisk.Size())) - n88, err := m.GCEPersistentDisk.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.GCEPersistentDisk.Size())) + n96, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n88 + i += n96 } if m.AWSElasticBlockStore != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.AWSElasticBlockStore.Size())) - n89, err := m.AWSElasticBlockStore.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.AWSElasticBlockStore.Size())) + n97, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n89 + i += n97 } if m.HostPath != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.HostPath.Size())) - n90, err := m.HostPath.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.HostPath.Size())) + n98, err := m.HostPath.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n90 + i += n98 } if m.Glusterfs != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.Glusterfs.Size())) - n91, err := m.Glusterfs.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Glusterfs.Size())) + n99, err := m.Glusterfs.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n91 + i += n99 } if m.NFS != nil { - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.NFS.Size())) - n92, err := m.NFS.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NFS.Size())) + n100, err := m.NFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n92 + i += n100 } if m.RBD != nil { - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.RBD.Size())) - n93, err := m.RBD.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RBD.Size())) + n101, err := m.RBD.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n93 + i += n101 } if m.ISCSI != nil { - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.ISCSI.Size())) - n94, err := m.ISCSI.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ISCSI.Size())) + n102, err := m.ISCSI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n94 + i += n102 } if m.Cinder != nil { - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(m.Cinder.Size())) - n95, err := m.Cinder.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Cinder.Size())) + n103, err := m.Cinder.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n95 + i += n103 } if m.CephFS != nil { - data[i] = 0x4a + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(m.CephFS.Size())) - n96, err := m.CephFS.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.CephFS.Size())) + n104, err := m.CephFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n96 + i += n104 } if m.FC != nil { - data[i] = 0x52 + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(m.FC.Size())) - n97, err := m.FC.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FC.Size())) + n105, err := m.FC.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n97 + i += n105 } if m.Flocker != nil { - data[i] = 0x5a + dAtA[i] = 0x5a i++ - i = encodeVarintGenerated(data, i, uint64(m.Flocker.Size())) - n98, err := m.Flocker.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Flocker.Size())) + n106, err := m.Flocker.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n98 + i += n106 } if m.FlexVolume != nil { - data[i] = 0x62 + dAtA[i] = 0x62 i++ - i = encodeVarintGenerated(data, i, uint64(m.FlexVolume.Size())) - n99, err := m.FlexVolume.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FlexVolume.Size())) + n107, err := m.FlexVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n99 + i += n107 } if m.AzureFile != nil { - data[i] = 0x6a + dAtA[i] = 0x6a i++ - i = encodeVarintGenerated(data, i, uint64(m.AzureFile.Size())) - n100, err := m.AzureFile.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.AzureFile.Size())) + n108, err := m.AzureFile.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n100 + i += n108 } if m.VsphereVolume != nil { - data[i] = 0x72 + dAtA[i] = 0x72 i++ - i = encodeVarintGenerated(data, i, uint64(m.VsphereVolume.Size())) - n101, err := m.VsphereVolume.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.VsphereVolume.Size())) + n109, err := m.VsphereVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n101 + i += n109 } if m.Quobyte != nil { - data[i] = 0x7a + dAtA[i] = 0x7a i++ - i = encodeVarintGenerated(data, i, uint64(m.Quobyte.Size())) - n102, err := m.Quobyte.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Quobyte.Size())) + n110, err := m.Quobyte.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n102 + i += n110 } if m.AzureDisk != nil { - data[i] = 0x82 + dAtA[i] = 0x82 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.AzureDisk.Size())) - n103, err := m.AzureDisk.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.AzureDisk.Size())) + n111, err := m.AzureDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n103 + i += n111 } if m.PhotonPersistentDisk != nil { - data[i] = 0x8a + dAtA[i] = 0x8a i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.PhotonPersistentDisk.Size())) - n104, err := m.PhotonPersistentDisk.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PhotonPersistentDisk.Size())) + n112, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n104 + i += n112 + } + if m.PortworxVolume != nil { + dAtA[i] = 0x92 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PortworxVolume.Size())) + n113, err := m.PortworxVolume.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n113 + } + if m.ScaleIO != nil { + dAtA[i] = 0x9a + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleIO.Size())) + n114, err := m.ScaleIO.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n114 + } + if m.Local != nil { + dAtA[i] = 0xa2 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Local.Size())) + n115, err := m.Local.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n115 + } + if m.StorageOS != nil { + dAtA[i] = 0xaa + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.StorageOS.Size())) + n116, err := m.StorageOS.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n116 } return i, nil } -func (m *PersistentVolumeSpec) Marshal() (data []byte, err error) { +func (m *PersistentVolumeSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeSpec) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Capacity) > 0 { + keysForCapacity := make([]string, 0, len(m.Capacity)) for k := range m.Capacity { - data[i] = 0xa + keysForCapacity = append(keysForCapacity, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForCapacity) + for _, k := range keysForCapacity { + dAtA[i] = 0xa i++ - v := m.Capacity[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Capacity[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n105, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n117, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n105 + i += n117 } } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.PersistentVolumeSource.Size())) - n106, err := m.PersistentVolumeSource.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PersistentVolumeSource.Size())) + n118, err := m.PersistentVolumeSource.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n106 + i += n118 if len(m.AccessModes) > 0 { for _, s := range m.AccessModes { - data[i] = 0x1a + dAtA[i] = 0x1a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if m.ClaimRef != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.ClaimRef.Size())) - n107, err := m.ClaimRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ClaimRef.Size())) + n119, err := m.ClaimRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n107 + i += n119 } - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.PersistentVolumeReclaimPolicy))) - i += copy(data[i:], m.PersistentVolumeReclaimPolicy) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.PersistentVolumeReclaimPolicy))) + i += copy(dAtA[i:], m.PersistentVolumeReclaimPolicy) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.StorageClassName))) + i += copy(dAtA[i:], m.StorageClassName) return i, nil } -func (m *PersistentVolumeStatus) Marshal() (data []byte, err error) { +func (m *PersistentVolumeStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PersistentVolumeStatus) MarshalTo(data []byte) (int, error) { +func (m *PersistentVolumeStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Phase))) - i += copy(data[i:], m.Phase) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Phase))) + i += copy(dAtA[i:], m.Phase) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) return i, nil } -func (m *PhotonPersistentDiskVolumeSource) Marshal() (data []byte, err error) { +func (m *PhotonPersistentDiskVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PhotonPersistentDiskVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *PhotonPersistentDiskVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.PdID))) - i += copy(data[i:], m.PdID) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.PdID))) + i += copy(dAtA[i:], m.PdID) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) return i, nil } -func (m *Pod) Marshal() (data []byte, err error) { +func (m *Pod) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Pod) MarshalTo(data []byte) (int, error) { +func (m *Pod) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n108, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n120, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n108 - data[i] = 0x12 + i += n120 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n109, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n121, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n109 - data[i] = 0x1a + i += n121 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n110, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n122, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n110 + i += n122 return i, nil } -func (m *PodAffinity) Marshal() (data []byte, err error) { +func (m *PodAffinity) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodAffinity) MarshalTo(data []byte) (int, error) { +func (m *PodAffinity) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.RequiredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.RequiredDuringSchedulingIgnoredDuringExecution { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5420,10 +5995,10 @@ func (m *PodAffinity) MarshalTo(data []byte) (int, error) { } if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5433,74 +6008,74 @@ func (m *PodAffinity) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodAffinityTerm) Marshal() (data []byte, err error) { +func (m *PodAffinityTerm) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodAffinityTerm) MarshalTo(data []byte) (int, error) { +func (m *PodAffinityTerm) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.LabelSelector != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.LabelSelector.Size())) - n111, err := m.LabelSelector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LabelSelector.Size())) + n123, err := m.LabelSelector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n111 + i += n123 } if len(m.Namespaces) > 0 { for _, s := range m.Namespaces { - data[i] = 0x12 + dAtA[i] = 0x12 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.TopologyKey))) - i += copy(data[i:], m.TopologyKey) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TopologyKey))) + i += copy(dAtA[i:], m.TopologyKey) return i, nil } -func (m *PodAntiAffinity) Marshal() (data []byte, err error) { +func (m *PodAntiAffinity) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodAntiAffinity) MarshalTo(data []byte) (int, error) { +func (m *PodAntiAffinity) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.RequiredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.RequiredDuringSchedulingIgnoredDuringExecution { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5509,10 +6084,10 @@ func (m *PodAntiAffinity) MarshalTo(data []byte) (int, error) { } if len(m.PreferredDuringSchedulingIgnoredDuringExecution) > 0 { for _, msg := range m.PreferredDuringSchedulingIgnoredDuringExecution { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5522,208 +6097,208 @@ func (m *PodAntiAffinity) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodAttachOptions) Marshal() (data []byte, err error) { +func (m *PodAttachOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodAttachOptions) MarshalTo(data []byte) (int, error) { +func (m *PodAttachOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ if m.Stdin { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x10 + dAtA[i] = 0x10 i++ if m.Stdout { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x18 + dAtA[i] = 0x18 i++ if m.Stderr { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x20 + dAtA[i] = 0x20 i++ if m.TTY { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Container))) - i += copy(data[i:], m.Container) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Container))) + i += copy(dAtA[i:], m.Container) return i, nil } -func (m *PodCondition) Marshal() (data []byte, err error) { +func (m *PodCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodCondition) MarshalTo(data []byte) (int, error) { +func (m *PodCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastProbeTime.Size())) - n112, err := m.LastProbeTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastProbeTime.Size())) + n124, err := m.LastProbeTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n112 - data[i] = 0x22 + i += n124 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n113, err := m.LastTransitionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n125, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n113 - data[i] = 0x2a + i += n125 + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *PodExecOptions) Marshal() (data []byte, err error) { +func (m *PodExecOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodExecOptions) MarshalTo(data []byte) (int, error) { +func (m *PodExecOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ if m.Stdin { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x10 + dAtA[i] = 0x10 i++ if m.Stdout { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x18 + dAtA[i] = 0x18 i++ if m.Stderr { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x20 + dAtA[i] = 0x20 i++ if m.TTY { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Container))) - i += copy(data[i:], m.Container) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Container))) + i += copy(dAtA[i:], m.Container) if len(m.Command) > 0 { for _, s := range m.Command { - data[i] = 0x32 + dAtA[i] = 0x32 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *PodList) Marshal() (data []byte, err error) { +func (m *PodList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodList) MarshalTo(data []byte) (int, error) { +func (m *PodList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n114, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n126, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n114 + i += n126 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5733,203 +6308,228 @@ func (m *PodList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodLogOptions) Marshal() (data []byte, err error) { +func (m *PodLogOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodLogOptions) MarshalTo(data []byte) (int, error) { +func (m *PodLogOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Container))) - i += copy(data[i:], m.Container) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Container))) + i += copy(dAtA[i:], m.Container) + dAtA[i] = 0x10 i++ if m.Follow { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x18 + dAtA[i] = 0x18 i++ if m.Previous { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if m.SinceSeconds != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(*m.SinceSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.SinceSeconds)) } if m.SinceTime != nil { - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.SinceTime.Size())) - n115, err := m.SinceTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SinceTime.Size())) + n127, err := m.SinceTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n115 + i += n127 } - data[i] = 0x30 + dAtA[i] = 0x30 i++ if m.Timestamps { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if m.TailLines != nil { - data[i] = 0x38 + dAtA[i] = 0x38 i++ - i = encodeVarintGenerated(data, i, uint64(*m.TailLines)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.TailLines)) } if m.LimitBytes != nil { - data[i] = 0x40 + dAtA[i] = 0x40 i++ - i = encodeVarintGenerated(data, i, uint64(*m.LimitBytes)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.LimitBytes)) + } + return i, nil +} + +func (m *PodPortForwardOptions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodPortForwardOptions) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Ports) > 0 { + for _, num := range m.Ports { + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(num)) + } } return i, nil } -func (m *PodProxyOptions) Marshal() (data []byte, err error) { +func (m *PodProxyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodProxyOptions) MarshalTo(data []byte) (int, error) { +func (m *PodProxyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) return i, nil } -func (m *PodSecurityContext) Marshal() (data []byte, err error) { +func (m *PodSecurityContext) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodSecurityContext) MarshalTo(data []byte) (int, error) { +func (m *PodSecurityContext) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.SELinuxOptions != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.SELinuxOptions.Size())) - n116, err := m.SELinuxOptions.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) + n128, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n116 + i += n128 } if m.RunAsUser != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.RunAsUser)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.RunAsUser)) } if m.RunAsNonRoot != nil { - data[i] = 0x18 + dAtA[i] = 0x18 i++ if *m.RunAsNonRoot { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } if len(m.SupplementalGroups) > 0 { for _, num := range m.SupplementalGroups { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(num)) + i = encodeVarintGenerated(dAtA, i, uint64(num)) } } if m.FSGroup != nil { - data[i] = 0x28 + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(*m.FSGroup)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.FSGroup)) } return i, nil } -func (m *PodSignature) Marshal() (data []byte, err error) { +func (m *PodSignature) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodSignature) MarshalTo(data []byte) (int, error) { +func (m *PodSignature) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.PodController != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.PodController.Size())) - n117, err := m.PodController.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodController.Size())) + n129, err := m.PodController.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n117 + i += n129 } return i, nil } -func (m *PodSpec) Marshal() (data []byte, err error) { +func (m *PodSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodSpec) MarshalTo(data []byte) (int, error) { +func (m *PodSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Volumes) > 0 { for _, msg := range m.Volumes { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -5938,293 +6538,280 @@ func (m *PodSpec) MarshalTo(data []byte) (int, error) { } if len(m.Containers) > 0 { for _, msg := range m.Containers { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.RestartPolicy))) - i += copy(data[i:], m.RestartPolicy) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RestartPolicy))) + i += copy(dAtA[i:], m.RestartPolicy) if m.TerminationGracePeriodSeconds != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(*m.TerminationGracePeriodSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.TerminationGracePeriodSeconds)) } if m.ActiveDeadlineSeconds != nil { - data[i] = 0x28 + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(*m.ActiveDeadlineSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.ActiveDeadlineSeconds)) } - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DNSPolicy))) - i += copy(data[i:], m.DNSPolicy) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DNSPolicy))) + i += copy(dAtA[i:], m.DNSPolicy) if len(m.NodeSelector) > 0 { + keysForNodeSelector := make([]string, 0, len(m.NodeSelector)) for k := range m.NodeSelector { - data[i] = 0x3a + keysForNodeSelector = append(keysForNodeSelector, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForNodeSelector) + for _, k := range keysForNodeSelector { + dAtA[i] = 0x3a i++ - v := m.NodeSelector[k] + v := m.NodeSelector[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ServiceAccountName))) - i += copy(data[i:], m.ServiceAccountName) - data[i] = 0x4a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ServiceAccountName))) + i += copy(dAtA[i:], m.ServiceAccountName) + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.DeprecatedServiceAccount))) - i += copy(data[i:], m.DeprecatedServiceAccount) - data[i] = 0x52 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.DeprecatedServiceAccount))) + i += copy(dAtA[i:], m.DeprecatedServiceAccount) + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.NodeName))) - i += copy(data[i:], m.NodeName) - data[i] = 0x58 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.NodeName))) + i += copy(dAtA[i:], m.NodeName) + dAtA[i] = 0x58 i++ if m.HostNetwork { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x60 + dAtA[i] = 0x60 i++ if m.HostPID { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x68 + dAtA[i] = 0x68 i++ if m.HostIPC { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if m.SecurityContext != nil { - data[i] = 0x72 + dAtA[i] = 0x72 i++ - i = encodeVarintGenerated(data, i, uint64(m.SecurityContext.Size())) - n118, err := m.SecurityContext.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SecurityContext.Size())) + n130, err := m.SecurityContext.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n118 + i += n130 } if len(m.ImagePullSecrets) > 0 { for _, msg := range m.ImagePullSecrets { - data[i] = 0x7a + dAtA[i] = 0x7a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x82 + dAtA[i] = 0x82 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Hostname))) - i += copy(data[i:], m.Hostname) - data[i] = 0x8a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Hostname))) + i += copy(dAtA[i:], m.Hostname) + dAtA[i] = 0x8a i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Subdomain))) - i += copy(data[i:], m.Subdomain) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Subdomain))) + i += copy(dAtA[i:], m.Subdomain) + if m.Affinity != nil { + dAtA[i] = 0x92 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Affinity.Size())) + n131, err := m.Affinity.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n131 + } + dAtA[i] = 0x9a + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SchedulerName))) + i += copy(dAtA[i:], m.SchedulerName) + if len(m.InitContainers) > 0 { + for _, msg := range m.InitContainers { + dAtA[i] = 0xa2 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.AutomountServiceAccountToken != nil { + dAtA[i] = 0xa8 + i++ + dAtA[i] = 0x1 + i++ + if *m.AutomountServiceAccountToken { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + if len(m.Tolerations) > 0 { + for _, msg := range m.Tolerations { + dAtA[i] = 0xb2 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.HostAliases) > 0 { + for _, msg := range m.HostAliases { + dAtA[i] = 0xba + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } return i, nil } -func (m *PodStatus) Marshal() (data []byte, err error) { +func (m *PodStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodStatus) MarshalTo(data []byte) (int, error) { +func (m *PodStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Phase))) - i += copy(data[i:], m.Phase) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Phase))) + i += copy(dAtA[i:], m.Phase) if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.HostIP))) - i += copy(data[i:], m.HostIP) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.HostIP))) + i += copy(dAtA[i:], m.HostIP) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.PodIP))) - i += copy(data[i:], m.PodIP) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.PodIP))) + i += copy(dAtA[i:], m.PodIP) if m.StartTime != nil { - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.StartTime.Size())) - n119, err := m.StartTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.StartTime.Size())) + n132, err := m.StartTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n119 + i += n132 } if len(m.ContainerStatuses) > 0 { for _, msg := range m.ContainerStatuses { - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - return i, nil -} - -func (m *PodStatusResult) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *PodStatusResult) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n120, err := m.ObjectMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n120 - data[i] = 0x12 + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n121, err := m.Status.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n121 - return i, nil -} - -func (m *PodTemplate) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *PodTemplate) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n122, err := m.ObjectMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n122 - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n123, err := m.Template.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n123 - return i, nil -} - -func (m *PodTemplateList) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *PodTemplateList) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n124, err := m.ListMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n124 - if len(m.Items) > 0 { - for _, msg := range m.Items { - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.QOSClass))) + i += copy(dAtA[i:], m.QOSClass) + if len(m.InitContainerStatuses) > 0 { + for _, msg := range m.InitContainerStatuses { + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -6234,438 +6821,613 @@ func (m *PodTemplateList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodTemplateSpec) Marshal() (data []byte, err error) { +func (m *PodStatusResult) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodTemplateSpec) MarshalTo(data []byte) (int, error) { +func (m *PodStatusResult) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n125, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n133, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n125 - data[i] = 0x12 + i += n133 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n126, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n134, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n126 + i += n134 return i, nil } -func (m *Preconditions) Marshal() (data []byte, err error) { +func (m *PodTemplate) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Preconditions) MarshalTo(data []byte) (int, error) { +func (m *PodTemplate) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n135, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n135 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n136, err := m.Template.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n136 + return i, nil +} + +func (m *PodTemplateList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodTemplateList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n137, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n137 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *PodTemplateSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodTemplateSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n138, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n138 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n139, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n139 + return i, nil +} + +func (m *PortworxVolumeSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PortworxVolumeSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeID))) + i += copy(dAtA[i:], m.VolumeID) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x18 + i++ + if m.ReadOnly { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + return i, nil +} + +func (m *Preconditions) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Preconditions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.UID != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(*m.UID))) - i += copy(data[i:], *m.UID) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.UID))) + i += copy(dAtA[i:], *m.UID) } return i, nil } -func (m *PreferAvoidPodsEntry) Marshal() (data []byte, err error) { +func (m *PreferAvoidPodsEntry) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PreferAvoidPodsEntry) MarshalTo(data []byte) (int, error) { +func (m *PreferAvoidPodsEntry) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.PodSignature.Size())) - n127, err := m.PodSignature.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSignature.Size())) + n140, err := m.PodSignature.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n127 - data[i] = 0x12 + i += n140 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.EvictionTime.Size())) - n128, err := m.EvictionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.EvictionTime.Size())) + n141, err := m.EvictionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n128 - data[i] = 0x1a + i += n141 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *PreferredSchedulingTerm) Marshal() (data []byte, err error) { +func (m *PreferredSchedulingTerm) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PreferredSchedulingTerm) MarshalTo(data []byte) (int, error) { +func (m *PreferredSchedulingTerm) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Weight)) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(m.Weight)) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Preference.Size())) - n129, err := m.Preference.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Preference.Size())) + n142, err := m.Preference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n129 + i += n142 return i, nil } -func (m *Probe) Marshal() (data []byte, err error) { +func (m *Probe) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Probe) MarshalTo(data []byte) (int, error) { +func (m *Probe) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Handler.Size())) - n130, err := m.Handler.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Handler.Size())) + n143, err := m.Handler.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n130 - data[i] = 0x10 + i += n143 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.InitialDelaySeconds)) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.InitialDelaySeconds)) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.TimeoutSeconds)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.TimeoutSeconds)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.PeriodSeconds)) - data[i] = 0x28 + i = encodeVarintGenerated(dAtA, i, uint64(m.PeriodSeconds)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.SuccessThreshold)) - data[i] = 0x30 + i = encodeVarintGenerated(dAtA, i, uint64(m.SuccessThreshold)) + dAtA[i] = 0x30 i++ - i = encodeVarintGenerated(data, i, uint64(m.FailureThreshold)) + i = encodeVarintGenerated(dAtA, i, uint64(m.FailureThreshold)) + return i, nil +} + +func (m *ProjectedVolumeSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ProjectedVolumeSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Sources) > 0 { + for _, msg := range m.Sources { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.DefaultMode != nil { + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.DefaultMode)) + } return i, nil } -func (m *QuobyteVolumeSource) Marshal() (data []byte, err error) { +func (m *QuobyteVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *QuobyteVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *QuobyteVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Registry))) - i += copy(data[i:], m.Registry) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Registry))) + i += copy(dAtA[i:], m.Registry) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Volume))) - i += copy(data[i:], m.Volume) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Volume))) + i += copy(dAtA[i:], m.Volume) + dAtA[i] = 0x18 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.User))) - i += copy(data[i:], m.User) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.User))) + i += copy(dAtA[i:], m.User) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) return i, nil } -func (m *RBDVolumeSource) Marshal() (data []byte, err error) { +func (m *RBDVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RBDVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *RBDVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.CephMonitors) > 0 { for _, s := range m.CephMonitors { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.RBDImage))) - i += copy(data[i:], m.RBDImage) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RBDImage))) + i += copy(dAtA[i:], m.RBDImage) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.RBDPool))) - i += copy(data[i:], m.RBDPool) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RBDPool))) + i += copy(dAtA[i:], m.RBDPool) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.RadosUser))) - i += copy(data[i:], m.RadosUser) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.RadosUser))) + i += copy(dAtA[i:], m.RadosUser) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Keyring))) - i += copy(data[i:], m.Keyring) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Keyring))) + i += copy(dAtA[i:], m.Keyring) if m.SecretRef != nil { - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.SecretRef.Size())) - n131, err := m.SecretRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n144, err := m.SecretRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n131 + i += n144 } - data[i] = 0x40 + dAtA[i] = 0x40 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *RangeAllocation) Marshal() (data []byte, err error) { +func (m *RangeAllocation) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RangeAllocation) MarshalTo(data []byte) (int, error) { +func (m *RangeAllocation) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n132, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n145, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n132 - data[i] = 0x12 + i += n145 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Range))) - i += copy(data[i:], m.Range) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Range))) + i += copy(dAtA[i:], m.Range) if m.Data != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Data))) - i += copy(data[i:], m.Data) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Data))) + i += copy(dAtA[i:], m.Data) } return i, nil } -func (m *ReplicationController) Marshal() (data []byte, err error) { +func (m *ReplicationController) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicationController) MarshalTo(data []byte) (int, error) { +func (m *ReplicationController) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n133, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n146, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n133 - data[i] = 0x12 + i += n146 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n134, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n147, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n134 - data[i] = 0x1a + i += n147 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n135, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n148, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n135 + i += n148 return i, nil } -func (m *ReplicationControllerCondition) Marshal() (data []byte, err error) { +func (m *ReplicationControllerCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicationControllerCondition) MarshalTo(data []byte) (int, error) { +func (m *ReplicationControllerCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n136, err := m.LastTransitionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n149, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n136 - data[i] = 0x22 + i += n149 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *ReplicationControllerList) Marshal() (data []byte, err error) { +func (m *ReplicationControllerList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicationControllerList) MarshalTo(data []byte) (int, error) { +func (m *ReplicationControllerList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n137, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n150, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n137 + i += n150 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -6675,95 +7437,100 @@ func (m *ReplicationControllerList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ReplicationControllerSpec) Marshal() (data []byte, err error) { +func (m *ReplicationControllerSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicationControllerSpec) MarshalTo(data []byte) (int, error) { +func (m *ReplicationControllerSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Replicas != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Replicas)) } if len(m.Selector) > 0 { + keysForSelector := make([]string, 0, len(m.Selector)) for k := range m.Selector { - data[i] = 0x12 + keysForSelector = append(keysForSelector, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForSelector) + for _, k := range keysForSelector { + dAtA[i] = 0x12 i++ - v := m.Selector[k] + v := m.Selector[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } if m.Template != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n138, err := m.Template.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n151, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n138 + i += n151 } - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.MinReadySeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) return i, nil } -func (m *ReplicationControllerStatus) Marshal() (data []byte, err error) { +func (m *ReplicationControllerStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicationControllerStatus) MarshalTo(data []byte) (int, error) { +func (m *ReplicationControllerStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.FullyLabeledReplicas)) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.FullyLabeledReplicas)) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.ObservedGeneration)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.ObservedGeneration)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.ReadyReplicas)) - data[i] = 0x28 + i = encodeVarintGenerated(dAtA, i, uint64(m.ReadyReplicas)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.AvailableReplicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.AvailableReplicas)) if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -6773,111 +7540,111 @@ func (m *ReplicationControllerStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ResourceFieldSelector) Marshal() (data []byte, err error) { +func (m *ResourceFieldSelector) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceFieldSelector) MarshalTo(data []byte) (int, error) { +func (m *ResourceFieldSelector) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ContainerName))) - i += copy(data[i:], m.ContainerName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ContainerName))) + i += copy(dAtA[i:], m.ContainerName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Resource))) - i += copy(data[i:], m.Resource) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Resource))) + i += copy(dAtA[i:], m.Resource) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Divisor.Size())) - n139, err := m.Divisor.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Divisor.Size())) + n152, err := m.Divisor.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n139 + i += n152 return i, nil } -func (m *ResourceQuota) Marshal() (data []byte, err error) { +func (m *ResourceQuota) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceQuota) MarshalTo(data []byte) (int, error) { +func (m *ResourceQuota) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n140, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n153, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n140 - data[i] = 0x12 + i += n153 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n141, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n154, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n141 - data[i] = 0x1a + i += n154 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n142, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n155, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n142 + i += n155 return i, nil } -func (m *ResourceQuotaList) Marshal() (data []byte, err error) { +func (m *ResourceQuotaList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceQuotaList) MarshalTo(data []byte) (int, error) { +func (m *ResourceQuotaList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n143, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n156, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n143 + i += n156 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -6887,376 +7654,603 @@ func (m *ResourceQuotaList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ResourceQuotaSpec) Marshal() (data []byte, err error) { +func (m *ResourceQuotaSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceQuotaSpec) MarshalTo(data []byte) (int, error) { +func (m *ResourceQuotaSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Hard) > 0 { + keysForHard := make([]string, 0, len(m.Hard)) for k := range m.Hard { - data[i] = 0xa + keysForHard = append(keysForHard, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForHard) + for _, k := range keysForHard { + dAtA[i] = 0xa i++ - v := m.Hard[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Hard[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n144, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n157, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n144 + i += n157 } } if len(m.Scopes) > 0 { for _, s := range m.Scopes { - data[i] = 0x12 + dAtA[i] = 0x12 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *ResourceQuotaStatus) Marshal() (data []byte, err error) { +func (m *ResourceQuotaStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceQuotaStatus) MarshalTo(data []byte) (int, error) { +func (m *ResourceQuotaStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Hard) > 0 { + keysForHard := make([]string, 0, len(m.Hard)) for k := range m.Hard { - data[i] = 0xa + keysForHard = append(keysForHard, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForHard) + for _, k := range keysForHard { + dAtA[i] = 0xa i++ - v := m.Hard[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Hard[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n145, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n158, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n145 + i += n158 } } if len(m.Used) > 0 { + keysForUsed := make([]string, 0, len(m.Used)) for k := range m.Used { - data[i] = 0x12 + keysForUsed = append(keysForUsed, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForUsed) + for _, k := range keysForUsed { + dAtA[i] = 0x12 i++ - v := m.Used[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Used[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n146, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n159, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n146 + i += n159 } } return i, nil } -func (m *ResourceRequirements) Marshal() (data []byte, err error) { +func (m *ResourceRequirements) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceRequirements) MarshalTo(data []byte) (int, error) { +func (m *ResourceRequirements) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Limits) > 0 { + keysForLimits := make([]string, 0, len(m.Limits)) for k := range m.Limits { - data[i] = 0xa + keysForLimits = append(keysForLimits, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForLimits) + for _, k := range keysForLimits { + dAtA[i] = 0xa i++ - v := m.Limits[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Limits[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n147, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n160, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n147 + i += n160 } } if len(m.Requests) > 0 { + keysForRequests := make([]string, 0, len(m.Requests)) for k := range m.Requests { - data[i] = 0x12 + keysForRequests = append(keysForRequests, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForRequests) + for _, k := range keysForRequests { + dAtA[i] = 0x12 i++ - v := m.Requests[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Requests[ResourceName(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n148, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n161, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n148 + i += n161 } } return i, nil } -func (m *SELinuxOptions) Marshal() (data []byte, err error) { +func (m *SELinuxOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SELinuxOptions) MarshalTo(data []byte) (int, error) { +func (m *SELinuxOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.User))) - i += copy(data[i:], m.User) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.User))) + i += copy(dAtA[i:], m.User) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Role))) - i += copy(data[i:], m.Role) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Role))) + i += copy(dAtA[i:], m.Role) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Level))) - i += copy(data[i:], m.Level) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Level))) + i += copy(dAtA[i:], m.Level) return i, nil } -func (m *Secret) Marshal() (data []byte, err error) { +func (m *ScaleIOVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Secret) MarshalTo(data []byte) (int, error) { +func (m *ScaleIOVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Gateway))) + i += copy(dAtA[i:], m.Gateway) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.System))) + i += copy(dAtA[i:], m.System) + if m.SecretRef != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n162, err := m.SecretRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n162 + } + dAtA[i] = 0x20 + i++ + if m.SSLEnabled { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ProtectionDomain))) + i += copy(dAtA[i:], m.ProtectionDomain) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.StoragePool))) + i += copy(dAtA[i:], m.StoragePool) + dAtA[i] = 0x3a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.StorageMode))) + i += copy(dAtA[i:], m.StorageMode) + dAtA[i] = 0x42 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeName))) + i += copy(dAtA[i:], m.VolumeName) + dAtA[i] = 0x4a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x50 i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n149, err := m.ObjectMeta.MarshalTo(data[i:]) + if m.ReadOnly { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + return i, nil +} + +func (m *Secret) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Secret) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n163, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n149 + i += n163 if len(m.Data) > 0 { + keysForData := make([]string, 0, len(m.Data)) for k := range m.Data { - data[i] = 0x12 - i++ - v := m.Data[k] - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + keysForData = append(keysForData, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForData) + for _, k := range keysForData { + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + v := m.Data[string(k)] + byteSize := 0 + if v != nil { + byteSize = 1 + len(v) + sovGenerated(uint64(len(v))) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + byteSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + if v != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) if len(m.StringData) > 0 { + keysForStringData := make([]string, 0, len(m.StringData)) for k := range m.StringData { - data[i] = 0x22 + keysForStringData = append(keysForStringData, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForStringData) + for _, k := range keysForStringData { + dAtA[i] = 0x22 i++ - v := m.StringData[k] + v := m.StringData[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } return i, nil } -func (m *SecretKeySelector) Marshal() (data []byte, err error) { +func (m *SecretEnvSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SecretKeySelector) MarshalTo(data []byte) (int, error) { +func (m *SecretEnvSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.LocalObjectReference.Size())) - n150, err := m.LocalObjectReference.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n164, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n150 - data[i] = 0x12 + i += n164 + if m.Optional != nil { + dAtA[i] = 0x10 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + return i, nil +} + +func (m *SecretKeySelector) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SecretKeySelector) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n165, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n165 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + if m.Optional != nil { + dAtA[i] = 0x18 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } + return i, nil +} + +func (m *SecretList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SecretList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n166, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n166 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } return i, nil } -func (m *SecretList) Marshal() (data []byte, err error) { +func (m *SecretProjection) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SecretList) MarshalTo(data []byte) (int, error) { +func (m *SecretProjection) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n151, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LocalObjectReference.Size())) + n167, err := m.LocalObjectReference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n151 + i += n167 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } + if m.Optional != nil { + dAtA[i] = 0x20 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } return i, nil } -func (m *SecretVolumeSource) Marshal() (data []byte, err error) { +func (m *SecretVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SecretVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *SecretVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SecretName))) - i += copy(data[i:], m.SecretName) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SecretName))) + i += copy(dAtA[i:], m.SecretName) if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -7264,183 +8258,193 @@ func (m *SecretVolumeSource) MarshalTo(data []byte) (int, error) { } } if m.DefaultMode != nil { - data[i] = 0x18 + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.DefaultMode)) + } + if m.Optional != nil { + dAtA[i] = 0x20 + i++ + if *m.Optional { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } i++ - i = encodeVarintGenerated(data, i, uint64(*m.DefaultMode)) } return i, nil } -func (m *SecurityContext) Marshal() (data []byte, err error) { +func (m *SecurityContext) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SecurityContext) MarshalTo(data []byte) (int, error) { +func (m *SecurityContext) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Capabilities != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Capabilities.Size())) - n152, err := m.Capabilities.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Capabilities.Size())) + n168, err := m.Capabilities.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n152 + i += n168 } if m.Privileged != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ if *m.Privileged { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } if m.SELinuxOptions != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.SELinuxOptions.Size())) - n153, err := m.SELinuxOptions.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) + n169, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n153 + i += n169 } if m.RunAsUser != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(*m.RunAsUser)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.RunAsUser)) } if m.RunAsNonRoot != nil { - data[i] = 0x28 + dAtA[i] = 0x28 i++ if *m.RunAsNonRoot { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } if m.ReadOnlyRootFilesystem != nil { - data[i] = 0x30 + dAtA[i] = 0x30 i++ if *m.ReadOnlyRootFilesystem { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } return i, nil } -func (m *SerializedReference) Marshal() (data []byte, err error) { +func (m *SerializedReference) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SerializedReference) MarshalTo(data []byte) (int, error) { +func (m *SerializedReference) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Reference.Size())) - n154, err := m.Reference.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Reference.Size())) + n170, err := m.Reference.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n154 + i += n170 return i, nil } -func (m *Service) Marshal() (data []byte, err error) { +func (m *Service) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Service) MarshalTo(data []byte) (int, error) { +func (m *Service) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n155, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n171, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n155 - data[i] = 0x12 + i += n171 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n156, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n172, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n156 - data[i] = 0x1a + i += n172 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n157, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n173, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n157 + i += n173 return i, nil } -func (m *ServiceAccount) Marshal() (data []byte, err error) { +func (m *ServiceAccount) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServiceAccount) MarshalTo(data []byte) (int, error) { +func (m *ServiceAccount) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n158, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n174, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n158 + i += n174 if len(m.Secrets) > 0 { for _, msg := range m.Secrets { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -7449,48 +8453,58 @@ func (m *ServiceAccount) MarshalTo(data []byte) (int, error) { } if len(m.ImagePullSecrets) > 0 { for _, msg := range m.ImagePullSecrets { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } + if m.AutomountServiceAccountToken != nil { + dAtA[i] = 0x20 + i++ + if *m.AutomountServiceAccountToken { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + } return i, nil } -func (m *ServiceAccountList) Marshal() (data []byte, err error) { +func (m *ServiceAccountList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServiceAccountList) MarshalTo(data []byte) (int, error) { +func (m *ServiceAccountList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n159, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n175, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n159 + i += n175 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -7500,35 +8514,35 @@ func (m *ServiceAccountList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ServiceList) Marshal() (data []byte, err error) { +func (m *ServiceList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServiceList) MarshalTo(data []byte) (int, error) { +func (m *ServiceList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n160, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n176, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n160 + i += n176 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -7538,89 +8552,89 @@ func (m *ServiceList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ServicePort) Marshal() (data []byte, err error) { +func (m *ServicePort) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServicePort) MarshalTo(data []byte) (int, error) { +func (m *ServicePort) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Protocol))) - i += copy(data[i:], m.Protocol) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Protocol))) + i += copy(dAtA[i:], m.Protocol) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.Port)) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(m.Port)) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.TargetPort.Size())) - n161, err := m.TargetPort.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetPort.Size())) + n177, err := m.TargetPort.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n161 - data[i] = 0x28 + i += n177 + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.NodePort)) + i = encodeVarintGenerated(dAtA, i, uint64(m.NodePort)) return i, nil } -func (m *ServiceProxyOptions) Marshal() (data []byte, err error) { +func (m *ServiceProxyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServiceProxyOptions) MarshalTo(data []byte) (int, error) { +func (m *ServiceProxyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) return i, nil } -func (m *ServiceSpec) Marshal() (data []byte, err error) { +func (m *ServiceSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServiceSpec) MarshalTo(data []byte) (int, error) { +func (m *ServiceSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Ports) > 0 { for _, msg := range m.Ports { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -7628,618 +8642,858 @@ func (m *ServiceSpec) MarshalTo(data []byte) (int, error) { } } if len(m.Selector) > 0 { + keysForSelector := make([]string, 0, len(m.Selector)) for k := range m.Selector { - data[i] = 0x12 + keysForSelector = append(keysForSelector, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForSelector) + for _, k := range keysForSelector { + dAtA[i] = 0x12 i++ - v := m.Selector[k] + v := m.Selector[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ClusterIP))) - i += copy(data[i:], m.ClusterIP) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ClusterIP))) + i += copy(dAtA[i:], m.ClusterIP) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) if len(m.ExternalIPs) > 0 { for _, s := range m.ExternalIPs { - data[i] = 0x2a + dAtA[i] = 0x2a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - if len(m.DeprecatedPublicIPs) > 0 { - for _, s := range m.DeprecatedPublicIPs { - data[i] = 0x32 - i++ - l = len(s) - for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) - l >>= 7 - i++ - } - data[i] = uint8(l) - i++ - i += copy(data[i:], s) - } - } - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SessionAffinity))) - i += copy(data[i:], m.SessionAffinity) - data[i] = 0x42 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SessionAffinity))) + i += copy(dAtA[i:], m.SessionAffinity) + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.LoadBalancerIP))) - i += copy(data[i:], m.LoadBalancerIP) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.LoadBalancerIP))) + i += copy(dAtA[i:], m.LoadBalancerIP) if len(m.LoadBalancerSourceRanges) > 0 { for _, s := range m.LoadBalancerSourceRanges { - data[i] = 0x4a + dAtA[i] = 0x4a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x52 + dAtA[i] = 0x52 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ExternalName))) + i += copy(dAtA[i:], m.ExternalName) + dAtA[i] = 0x5a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ExternalTrafficPolicy))) + i += copy(dAtA[i:], m.ExternalTrafficPolicy) + dAtA[i] = 0x60 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ExternalName))) - i += copy(data[i:], m.ExternalName) + i = encodeVarintGenerated(dAtA, i, uint64(m.HealthCheckNodePort)) return i, nil } -func (m *ServiceStatus) Marshal() (data []byte, err error) { +func (m *ServiceStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ServiceStatus) MarshalTo(data []byte) (int, error) { +func (m *ServiceStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.LoadBalancer.Size())) - n162, err := m.LoadBalancer.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LoadBalancer.Size())) + n178, err := m.LoadBalancer.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n162 + i += n178 + return i, nil +} + +func (m *StorageOSPersistentVolumeSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StorageOSPersistentVolumeSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeName))) + i += copy(dAtA[i:], m.VolumeName) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeNamespace))) + i += copy(dAtA[i:], m.VolumeNamespace) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x20 + i++ + if m.ReadOnly { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + if m.SecretRef != nil { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n179, err := m.SecretRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n179 + } return i, nil } -func (m *TCPSocketAction) Marshal() (data []byte, err error) { +func (m *StorageOSVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *TCPSocketAction) MarshalTo(data []byte) (int, error) { +func (m *StorageOSVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeName))) + i += copy(dAtA[i:], m.VolumeName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Port.Size())) - n163, err := m.Port.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumeNamespace))) + i += copy(dAtA[i:], m.VolumeNamespace) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x20 + i++ + if m.ReadOnly { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + if m.SecretRef != nil { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.SecretRef.Size())) + n180, err := m.SecretRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n180 + } + return i, nil +} + +func (m *Sysctl) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Sysctl) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Value))) + i += copy(dAtA[i:], m.Value) + return i, nil +} + +func (m *TCPSocketAction) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TCPSocketAction) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) + n181, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n163 + i += n181 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) + i += copy(dAtA[i:], m.Host) return i, nil } -func (m *Taint) Marshal() (data []byte, err error) { +func (m *Taint) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Taint) MarshalTo(data []byte) (int, error) { +func (m *Taint) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Value))) + i += copy(dAtA[i:], m.Value) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Value))) - i += copy(data[i:], m.Value) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Effect))) + i += copy(dAtA[i:], m.Effect) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Effect))) - i += copy(data[i:], m.Effect) + i = encodeVarintGenerated(dAtA, i, uint64(m.TimeAdded.Size())) + n182, err := m.TimeAdded.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n182 return i, nil } -func (m *Toleration) Marshal() (data []byte, err error) { +func (m *Toleration) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Toleration) MarshalTo(data []byte) (int, error) { +func (m *Toleration) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Key))) - i += copy(data[i:], m.Key) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Key))) + i += copy(dAtA[i:], m.Key) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Operator))) - i += copy(data[i:], m.Operator) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Operator))) + i += copy(dAtA[i:], m.Operator) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Value))) - i += copy(data[i:], m.Value) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Value))) + i += copy(dAtA[i:], m.Value) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Effect))) - i += copy(data[i:], m.Effect) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Effect))) + i += copy(dAtA[i:], m.Effect) + if m.TolerationSeconds != nil { + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.TolerationSeconds)) + } return i, nil } -func (m *Volume) Marshal() (data []byte, err error) { +func (m *Volume) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Volume) MarshalTo(data []byte) (int, error) { +func (m *Volume) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.VolumeSource.Size())) - n164, err := m.VolumeSource.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.VolumeSource.Size())) + n183, err := m.VolumeSource.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n164 + i += n183 return i, nil } -func (m *VolumeMount) Marshal() (data []byte, err error) { +func (m *VolumeMount) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *VolumeMount) MarshalTo(data []byte) (int, error) { +func (m *VolumeMount) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x10 i++ if m.ReadOnly { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.MountPath))) - i += copy(data[i:], m.MountPath) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MountPath))) + i += copy(dAtA[i:], m.MountPath) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SubPath))) - i += copy(data[i:], m.SubPath) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SubPath))) + i += copy(dAtA[i:], m.SubPath) + return i, nil +} + +func (m *VolumeProjection) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *VolumeProjection) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.Secret != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Secret.Size())) + n184, err := m.Secret.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n184 + } + if m.DownwardAPI != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.DownwardAPI.Size())) + n185, err := m.DownwardAPI.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n185 + } + if m.ConfigMap != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMap.Size())) + n186, err := m.ConfigMap.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n186 + } return i, nil } -func (m *VolumeSource) Marshal() (data []byte, err error) { +func (m *VolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *VolumeSource) MarshalTo(data []byte) (int, error) { +func (m *VolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.HostPath != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.HostPath.Size())) - n165, err := m.HostPath.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.HostPath.Size())) + n187, err := m.HostPath.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n165 + i += n187 } if m.EmptyDir != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.EmptyDir.Size())) - n166, err := m.EmptyDir.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.EmptyDir.Size())) + n188, err := m.EmptyDir.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n166 + i += n188 } if m.GCEPersistentDisk != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.GCEPersistentDisk.Size())) - n167, err := m.GCEPersistentDisk.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.GCEPersistentDisk.Size())) + n189, err := m.GCEPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n167 + i += n189 } if m.AWSElasticBlockStore != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.AWSElasticBlockStore.Size())) - n168, err := m.AWSElasticBlockStore.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.AWSElasticBlockStore.Size())) + n190, err := m.AWSElasticBlockStore.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n168 + i += n190 } if m.GitRepo != nil { - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.GitRepo.Size())) - n169, err := m.GitRepo.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.GitRepo.Size())) + n191, err := m.GitRepo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n169 + i += n191 } if m.Secret != nil { - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.Secret.Size())) - n170, err := m.Secret.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Secret.Size())) + n192, err := m.Secret.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n170 + i += n192 } if m.NFS != nil { - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.NFS.Size())) - n171, err := m.NFS.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NFS.Size())) + n193, err := m.NFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n171 + i += n193 } if m.ISCSI != nil { - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(m.ISCSI.Size())) - n172, err := m.ISCSI.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ISCSI.Size())) + n194, err := m.ISCSI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n172 + i += n194 } if m.Glusterfs != nil { - data[i] = 0x4a + dAtA[i] = 0x4a i++ - i = encodeVarintGenerated(data, i, uint64(m.Glusterfs.Size())) - n173, err := m.Glusterfs.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Glusterfs.Size())) + n195, err := m.Glusterfs.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n173 + i += n195 } if m.PersistentVolumeClaim != nil { - data[i] = 0x52 + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(m.PersistentVolumeClaim.Size())) - n174, err := m.PersistentVolumeClaim.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PersistentVolumeClaim.Size())) + n196, err := m.PersistentVolumeClaim.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n174 + i += n196 } if m.RBD != nil { - data[i] = 0x5a + dAtA[i] = 0x5a i++ - i = encodeVarintGenerated(data, i, uint64(m.RBD.Size())) - n175, err := m.RBD.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RBD.Size())) + n197, err := m.RBD.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n175 + i += n197 } if m.FlexVolume != nil { - data[i] = 0x62 + dAtA[i] = 0x62 i++ - i = encodeVarintGenerated(data, i, uint64(m.FlexVolume.Size())) - n176, err := m.FlexVolume.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FlexVolume.Size())) + n198, err := m.FlexVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n176 + i += n198 } if m.Cinder != nil { - data[i] = 0x6a + dAtA[i] = 0x6a i++ - i = encodeVarintGenerated(data, i, uint64(m.Cinder.Size())) - n177, err := m.Cinder.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Cinder.Size())) + n199, err := m.Cinder.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n177 + i += n199 } if m.CephFS != nil { - data[i] = 0x72 + dAtA[i] = 0x72 i++ - i = encodeVarintGenerated(data, i, uint64(m.CephFS.Size())) - n178, err := m.CephFS.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.CephFS.Size())) + n200, err := m.CephFS.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n178 + i += n200 } if m.Flocker != nil { - data[i] = 0x7a + dAtA[i] = 0x7a i++ - i = encodeVarintGenerated(data, i, uint64(m.Flocker.Size())) - n179, err := m.Flocker.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Flocker.Size())) + n201, err := m.Flocker.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n179 + i += n201 } if m.DownwardAPI != nil { - data[i] = 0x82 + dAtA[i] = 0x82 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.DownwardAPI.Size())) - n180, err := m.DownwardAPI.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.DownwardAPI.Size())) + n202, err := m.DownwardAPI.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n180 + i += n202 } if m.FC != nil { - data[i] = 0x8a + dAtA[i] = 0x8a i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.FC.Size())) - n181, err := m.FC.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FC.Size())) + n203, err := m.FC.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n181 + i += n203 } if m.AzureFile != nil { - data[i] = 0x92 + dAtA[i] = 0x92 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.AzureFile.Size())) - n182, err := m.AzureFile.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.AzureFile.Size())) + n204, err := m.AzureFile.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n182 + i += n204 } if m.ConfigMap != nil { - data[i] = 0x9a + dAtA[i] = 0x9a i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.ConfigMap.Size())) - n183, err := m.ConfigMap.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ConfigMap.Size())) + n205, err := m.ConfigMap.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n183 + i += n205 } if m.VsphereVolume != nil { - data[i] = 0xa2 + dAtA[i] = 0xa2 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.VsphereVolume.Size())) - n184, err := m.VsphereVolume.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.VsphereVolume.Size())) + n206, err := m.VsphereVolume.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n184 + i += n206 } if m.Quobyte != nil { - data[i] = 0xaa + dAtA[i] = 0xaa i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.Quobyte.Size())) - n185, err := m.Quobyte.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Quobyte.Size())) + n207, err := m.Quobyte.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n185 + i += n207 } if m.AzureDisk != nil { - data[i] = 0xb2 + dAtA[i] = 0xb2 i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.AzureDisk.Size())) - n186, err := m.AzureDisk.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.AzureDisk.Size())) + n208, err := m.AzureDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n186 + i += n208 } if m.PhotonPersistentDisk != nil { - data[i] = 0xba + dAtA[i] = 0xba i++ - data[i] = 0x1 + dAtA[i] = 0x1 i++ - i = encodeVarintGenerated(data, i, uint64(m.PhotonPersistentDisk.Size())) - n187, err := m.PhotonPersistentDisk.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PhotonPersistentDisk.Size())) + n209, err := m.PhotonPersistentDisk.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n187 + i += n209 + } + if m.PortworxVolume != nil { + dAtA[i] = 0xc2 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PortworxVolume.Size())) + n210, err := m.PortworxVolume.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n210 + } + if m.ScaleIO != nil { + dAtA[i] = 0xca + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleIO.Size())) + n211, err := m.ScaleIO.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n211 + } + if m.Projected != nil { + dAtA[i] = 0xd2 + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Projected.Size())) + n212, err := m.Projected.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n212 + } + if m.StorageOS != nil { + dAtA[i] = 0xda + i++ + dAtA[i] = 0x1 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.StorageOS.Size())) + n213, err := m.StorageOS.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n213 } return i, nil } -func (m *VsphereVirtualDiskVolumeSource) Marshal() (data []byte, err error) { +func (m *VsphereVirtualDiskVolumeSource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *VsphereVirtualDiskVolumeSource) MarshalTo(data []byte) (int, error) { +func (m *VsphereVirtualDiskVolumeSource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.VolumePath))) - i += copy(data[i:], m.VolumePath) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.VolumePath))) + i += copy(dAtA[i:], m.VolumePath) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.FSType))) - i += copy(data[i:], m.FSType) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.FSType))) + i += copy(dAtA[i:], m.FSType) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.StoragePolicyName))) + i += copy(dAtA[i:], m.StoragePolicyName) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.StoragePolicyID))) + i += copy(dAtA[i:], m.StoragePolicyID) return i, nil } -func (m *WeightedPodAffinityTerm) Marshal() (data []byte, err error) { +func (m *WeightedPodAffinityTerm) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *WeightedPodAffinityTerm) MarshalTo(data []byte) (int, error) { +func (m *WeightedPodAffinityTerm) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Weight)) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(m.Weight)) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.PodAffinityTerm.Size())) - n188, err := m.PodAffinityTerm.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodAffinityTerm.Size())) + n214, err := m.PodAffinityTerm.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n188 + i += n214 return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *AWSElasticBlockStoreVolumeSource) Size() (n int) { @@ -8312,6 +9566,10 @@ func (m *AzureDiskVolumeSource) Size() (n int) { if m.ReadOnly != nil { n += 2 } + if m.Kind != nil { + l = len(*m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + } return n } @@ -8446,6 +9704,17 @@ func (m *ConfigMap) Size() (n int) { return n } +func (m *ConfigMapEnvSource) Size() (n int) { + var l int + _ = l + l = m.LocalObjectReference.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.Optional != nil { + n += 2 + } + return n +} + func (m *ConfigMapKeySelector) Size() (n int) { var l int _ = l @@ -8453,6 +9722,9 @@ func (m *ConfigMapKeySelector) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.Key) n += 1 + l + sovGenerated(uint64(l)) + if m.Optional != nil { + n += 2 + } return n } @@ -8470,6 +9742,23 @@ func (m *ConfigMapList) Size() (n int) { return n } +func (m *ConfigMapProjection) Size() (n int) { + var l int + _ = l + l = m.LocalObjectReference.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.Optional != nil { + n += 2 + } + return n +} + func (m *ConfigMapVolumeSource) Size() (n int) { var l int _ = l @@ -8484,6 +9773,9 @@ func (m *ConfigMapVolumeSource) Size() (n int) { if m.DefaultMode != nil { n += 1 + sovGenerated(uint64(*m.DefaultMode)) } + if m.Optional != nil { + n += 2 + } return n } @@ -8551,6 +9843,14 @@ func (m *Container) Size() (n int) { n += 3 n += 3 n += 3 + if len(m.EnvFrom) > 0 { + for _, e := range m.EnvFrom { + l = e.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + } + l = len(m.TerminationMessagePolicy) + n += 2 + l + sovGenerated(uint64(l)) return n } @@ -8675,6 +9975,22 @@ func (m *DeleteOptions) Size() (n int) { if m.OrphanDependents != nil { n += 2 } + if m.PropagationPolicy != nil { + l = len(*m.PropagationPolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *DownwardAPIProjection) Size() (n int) { + var l int + _ = l + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } @@ -8717,6 +10033,8 @@ func (m *EmptyDirVolumeSource) Size() (n int) { _ = l l = len(m.Medium) n += 1 + l + sovGenerated(uint64(l)) + l = m.SizeLimit.Size() + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -8801,6 +10119,22 @@ func (m *EndpointsList) Size() (n int) { return n } +func (m *EnvFromSource) Size() (n int) { + var l int + _ = l + l = len(m.Prefix) + n += 1 + l + sovGenerated(uint64(l)) + if m.ConfigMapRef != nil { + l = m.ConfigMapRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.SecretRef != nil { + l = m.SecretRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + func (m *EnvVar) Size() (n int) { var l int _ = l @@ -8896,14 +10230,6 @@ func (m *ExecAction) Size() (n int) { return n } -func (m *ExportOptions) Size() (n int) { - var l int - _ = l - n += 2 - n += 2 - return n -} - func (m *FCVolumeSource) Size() (n int) { var l int _ = l @@ -9038,6 +10364,20 @@ func (m *Handler) Size() (n int) { return n } +func (m *HostAlias) Size() (n int) { + var l int + _ = l + l = len(m.IP) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Hostnames) > 0 { + for _, s := range m.Hostnames { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + func (m *HostPathVolumeSource) Size() (n int) { var l int _ = l @@ -9059,6 +10399,18 @@ func (m *ISCSIVolumeSource) Size() (n int) { l = len(m.FSType) n += 1 + l + sovGenerated(uint64(l)) n += 2 + if len(m.Portals) > 0 { + for _, s := range m.Portals { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + n += 2 + if m.SecretRef != nil { + l = m.SecretRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + n += 2 return n } @@ -9205,6 +10557,7 @@ func (m *ListOptions) Size() (n int) { if m.TimeoutSeconds != nil { n += 1 + sovGenerated(uint64(*m.TimeoutSeconds)) } + n += 2 return n } @@ -9238,6 +10591,14 @@ func (m *LocalObjectReference) Size() (n int) { return n } +func (m *LocalVolumeSource) Size() (n int) { + var l int + _ = l + l = len(m.Path) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + func (m *NFSVolumeSource) Size() (n int) { var l int _ = l @@ -9381,6 +10742,21 @@ func (m *NodeProxyOptions) Size() (n int) { return n } +func (m *NodeResources) Size() (n int) { + var l int + _ = l + if len(m.Capacity) > 0 { + for k, v := range m.Capacity { + _ = k + _ = v + l = v.Size() + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l)) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + return n +} + func (m *NodeSelector) Size() (n int) { var l int _ = l @@ -9431,6 +10807,12 @@ func (m *NodeSpec) Size() (n int) { l = len(m.ProviderID) n += 1 + l + sovGenerated(uint64(l)) n += 2 + if len(m.Taints) > 0 { + for _, e := range m.Taints { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } @@ -9585,6 +10967,10 @@ func (m *ObjectMeta) Size() (n int) { } l = len(m.ClusterName) n += 1 + l + sovGenerated(uint64(l)) + if m.Initializers != nil { + l = m.Initializers.Size() + n += 2 + l + sovGenerated(uint64(l)) + } return n } @@ -9608,23 +10994,6 @@ func (m *ObjectReference) Size() (n int) { return n } -func (m *OwnerReference) Size() (n int) { - var l int - _ = l - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.UID) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.APIVersion) - n += 1 + l + sovGenerated(uint64(l)) - if m.Controller != nil { - n += 2 - } - return n -} - func (m *PersistentVolume) Size() (n int) { var l int _ = l @@ -9680,6 +11049,10 @@ func (m *PersistentVolumeClaimSpec) Size() (n int) { l = m.Selector.Size() n += 1 + l + sovGenerated(uint64(l)) } + if m.StorageClassName != nil { + l = len(*m.StorageClassName) + n += 1 + l + sovGenerated(uint64(l)) + } return n } @@ -9800,6 +11173,22 @@ func (m *PersistentVolumeSource) Size() (n int) { l = m.PhotonPersistentDisk.Size() n += 2 + l + sovGenerated(uint64(l)) } + if m.PortworxVolume != nil { + l = m.PortworxVolume.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + if m.ScaleIO != nil { + l = m.ScaleIO.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + if m.Local != nil { + l = m.Local.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + if m.StorageOS != nil { + l = m.StorageOS.Size() + n += 2 + l + sovGenerated(uint64(l)) + } return n } @@ -9829,6 +11218,8 @@ func (m *PersistentVolumeSpec) Size() (n int) { } l = len(m.PersistentVolumeReclaimPolicy) n += 1 + l + sovGenerated(uint64(l)) + l = len(m.StorageClassName) + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -10006,6 +11397,17 @@ func (m *PodLogOptions) Size() (n int) { return n } +func (m *PodPortForwardOptions) Size() (n int) { + var l int + _ = l + if len(m.Ports) > 0 { + for _, e := range m.Ports { + n += 1 + sovGenerated(uint64(e)) + } + } + return n +} + func (m *PodProxyOptions) Size() (n int) { var l int _ = l @@ -10104,6 +11506,33 @@ func (m *PodSpec) Size() (n int) { n += 2 + l + sovGenerated(uint64(l)) l = len(m.Subdomain) n += 2 + l + sovGenerated(uint64(l)) + if m.Affinity != nil { + l = m.Affinity.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + l = len(m.SchedulerName) + n += 2 + l + sovGenerated(uint64(l)) + if len(m.InitContainers) > 0 { + for _, e := range m.InitContainers { + l = e.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + } + if m.AutomountServiceAccountToken != nil { + n += 3 + } + if len(m.Tolerations) > 0 { + for _, e := range m.Tolerations { + l = e.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + } + if len(m.HostAliases) > 0 { + for _, e := range m.HostAliases { + l = e.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + } return n } @@ -10136,6 +11565,14 @@ func (m *PodStatus) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) } } + l = len(m.QOSClass) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.InitContainerStatuses) > 0 { + for _, e := range m.InitContainerStatuses { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } return n } @@ -10183,6 +11620,17 @@ func (m *PodTemplateSpec) Size() (n int) { return n } +func (m *PortworxVolumeSource) Size() (n int) { + var l int + _ = l + l = len(m.VolumeID) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.FSType) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + return n +} + func (m *Preconditions) Size() (n int) { var l int _ = l @@ -10229,6 +11677,21 @@ func (m *Probe) Size() (n int) { return n } +func (m *ProjectedVolumeSource) Size() (n int) { + var l int + _ = l + if len(m.Sources) > 0 { + for _, e := range m.Sources { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.DefaultMode != nil { + n += 1 + sovGenerated(uint64(*m.DefaultMode)) + } + return n +} + func (m *QuobyteVolumeSource) Size() (n int) { var l int _ = l @@ -10487,6 +11950,32 @@ func (m *SELinuxOptions) Size() (n int) { return n } +func (m *ScaleIOVolumeSource) Size() (n int) { + var l int + _ = l + l = len(m.Gateway) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.System) + n += 1 + l + sovGenerated(uint64(l)) + if m.SecretRef != nil { + l = m.SecretRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + n += 2 + l = len(m.ProtectionDomain) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.StoragePool) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.StorageMode) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.VolumeName) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.FSType) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + return n +} + func (m *Secret) Size() (n int) { var l int _ = l @@ -10496,7 +11985,11 @@ func (m *Secret) Size() (n int) { for k, v := range m.Data { _ = k _ = v - mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + l = 0 + if v != nil { + l = 1 + len(v) + sovGenerated(uint64(len(v))) + } + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + l n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) } } @@ -10513,6 +12006,17 @@ func (m *Secret) Size() (n int) { return n } +func (m *SecretEnvSource) Size() (n int) { + var l int + _ = l + l = m.LocalObjectReference.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.Optional != nil { + n += 2 + } + return n +} + func (m *SecretKeySelector) Size() (n int) { var l int _ = l @@ -10520,6 +12024,9 @@ func (m *SecretKeySelector) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.Key) n += 1 + l + sovGenerated(uint64(l)) + if m.Optional != nil { + n += 2 + } return n } @@ -10537,6 +12044,23 @@ func (m *SecretList) Size() (n int) { return n } +func (m *SecretProjection) Size() (n int) { + var l int + _ = l + l = m.LocalObjectReference.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.Optional != nil { + n += 2 + } + return n +} + func (m *SecretVolumeSource) Size() (n int) { var l int _ = l @@ -10551,6 +12075,9 @@ func (m *SecretVolumeSource) Size() (n int) { if m.DefaultMode != nil { n += 1 + sovGenerated(uint64(*m.DefaultMode)) } + if m.Optional != nil { + n += 2 + } return n } @@ -10617,6 +12144,9 @@ func (m *ServiceAccount) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) } } + if m.AutomountServiceAccountToken != nil { + n += 2 + } return n } @@ -10697,12 +12227,6 @@ func (m *ServiceSpec) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) } } - if len(m.DeprecatedPublicIPs) > 0 { - for _, s := range m.DeprecatedPublicIPs { - l = len(s) - n += 1 + l + sovGenerated(uint64(l)) - } - } l = len(m.SessionAffinity) n += 1 + l + sovGenerated(uint64(l)) l = len(m.LoadBalancerIP) @@ -10715,6 +12239,9 @@ func (m *ServiceSpec) Size() (n int) { } l = len(m.ExternalName) n += 1 + l + sovGenerated(uint64(l)) + l = len(m.ExternalTrafficPolicy) + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.HealthCheckNodePort)) return n } @@ -10726,11 +12253,57 @@ func (m *ServiceStatus) Size() (n int) { return n } +func (m *StorageOSPersistentVolumeSource) Size() (n int) { + var l int + _ = l + l = len(m.VolumeName) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.VolumeNamespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.FSType) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + if m.SecretRef != nil { + l = m.SecretRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *StorageOSVolumeSource) Size() (n int) { + var l int + _ = l + l = len(m.VolumeName) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.VolumeNamespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.FSType) + n += 1 + l + sovGenerated(uint64(l)) + n += 2 + if m.SecretRef != nil { + l = m.SecretRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *Sysctl) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Value) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + func (m *TCPSocketAction) Size() (n int) { var l int _ = l l = m.Port.Size() n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Host) + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -10743,6 +12316,8 @@ func (m *Taint) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.Effect) n += 1 + l + sovGenerated(uint64(l)) + l = m.TimeAdded.Size() + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -10757,6 +12332,9 @@ func (m *Toleration) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.Effect) n += 1 + l + sovGenerated(uint64(l)) + if m.TolerationSeconds != nil { + n += 1 + sovGenerated(uint64(*m.TolerationSeconds)) + } return n } @@ -10783,6 +12361,24 @@ func (m *VolumeMount) Size() (n int) { return n } +func (m *VolumeProjection) Size() (n int) { + var l int + _ = l + if m.Secret != nil { + l = m.Secret.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.DownwardAPI != nil { + l = m.DownwardAPI.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.ConfigMap != nil { + l = m.ConfigMap.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + func (m *VolumeSource) Size() (n int) { var l int _ = l @@ -10878,6 +12474,22 @@ func (m *VolumeSource) Size() (n int) { l = m.PhotonPersistentDisk.Size() n += 2 + l + sovGenerated(uint64(l)) } + if m.PortworxVolume != nil { + l = m.PortworxVolume.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + if m.ScaleIO != nil { + l = m.ScaleIO.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + if m.Projected != nil { + l = m.Projected.Size() + n += 2 + l + sovGenerated(uint64(l)) + } + if m.StorageOS != nil { + l = m.StorageOS.Size() + n += 2 + l + sovGenerated(uint64(l)) + } return n } @@ -10888,6 +12500,10 @@ func (m *VsphereVirtualDiskVolumeSource) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) l = len(m.FSType) n += 1 + l + sovGenerated(uint64(l)) + l = len(m.StoragePolicyName) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.StoragePolicyID) + n += 1 + l + sovGenerated(uint64(l)) return n } @@ -10969,6 +12585,7 @@ func (this *AzureDiskVolumeSource) String() string { `CachingMode:` + valueToStringGenerated(this.CachingMode) + `,`, `FSType:` + valueToStringGenerated(this.FSType) + `,`, `ReadOnly:` + valueToStringGenerated(this.ReadOnly) + `,`, + `Kind:` + valueToStringGenerated(this.Kind) + `,`, `}`, }, "") return s @@ -10990,7 +12607,7 @@ func (this *Binding) String() string { return "nil" } s := strings.Join([]string{`&Binding{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Target:` + strings.Replace(strings.Replace(this.Target.String(), "ObjectReference", "ObjectReference", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11052,7 +12669,7 @@ func (this *ComponentStatus) String() string { return "nil" } s := strings.Join([]string{`&ComponentStatus{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "ComponentCondition", "ComponentCondition", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11063,7 +12680,7 @@ func (this *ComponentStatusList) String() string { return "nil" } s := strings.Join([]string{`&ComponentStatusList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ComponentStatus", "ComponentStatus", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11084,12 +12701,23 @@ func (this *ConfigMap) String() string { } mapStringForData += "}" s := strings.Join([]string{`&ConfigMap{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Data:` + mapStringForData + `,`, `}`, }, "") return s } +func (this *ConfigMapEnvSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigMapEnvSource{`, + `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, + `}`, + }, "") + return s +} func (this *ConfigMapKeySelector) String() string { if this == nil { return "nil" @@ -11097,6 +12725,7 @@ func (this *ConfigMapKeySelector) String() string { s := strings.Join([]string{`&ConfigMapKeySelector{`, `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, `Key:` + fmt.Sprintf("%v", this.Key) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, `}`, }, "") return s @@ -11106,12 +12735,24 @@ func (this *ConfigMapList) String() string { return "nil" } s := strings.Join([]string{`&ConfigMapList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ConfigMap", "ConfigMap", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } +func (this *ConfigMapProjection) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ConfigMapProjection{`, + `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "KeyToPath", "KeyToPath", 1), `&`, ``, 1) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, + `}`, + }, "") + return s +} func (this *ConfigMapVolumeSource) String() string { if this == nil { return "nil" @@ -11120,6 +12761,7 @@ func (this *ConfigMapVolumeSource) String() string { `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "KeyToPath", "KeyToPath", 1), `&`, ``, 1) + `,`, `DefaultMode:` + valueToStringGenerated(this.DefaultMode) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, `}`, }, "") return s @@ -11147,6 +12789,8 @@ func (this *Container) String() string { `Stdin:` + fmt.Sprintf("%v", this.Stdin) + `,`, `StdinOnce:` + fmt.Sprintf("%v", this.StdinOnce) + `,`, `TTY:` + fmt.Sprintf("%v", this.TTY) + `,`, + `EnvFrom:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.EnvFrom), "EnvFromSource", "EnvFromSource", 1), `&`, ``, 1) + `,`, + `TerminationMessagePolicy:` + fmt.Sprintf("%v", this.TerminationMessagePolicy) + `,`, `}`, }, "") return s @@ -11193,7 +12837,7 @@ func (this *ContainerStateRunning) String() string { return "nil" } s := strings.Join([]string{`&ContainerStateRunning{`, - `StartedAt:` + strings.Replace(strings.Replace(this.StartedAt.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `StartedAt:` + strings.Replace(strings.Replace(this.StartedAt.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -11207,8 +12851,8 @@ func (this *ContainerStateTerminated) String() string { `Signal:` + fmt.Sprintf("%v", this.Signal) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `StartedAt:` + strings.Replace(strings.Replace(this.StartedAt.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `FinishedAt:` + strings.Replace(strings.Replace(this.FinishedAt.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `StartedAt:` + strings.Replace(strings.Replace(this.StartedAt.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `FinishedAt:` + strings.Replace(strings.Replace(this.FinishedAt.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `ContainerID:` + fmt.Sprintf("%v", this.ContainerID) + `,`, `}`, }, "") @@ -11260,6 +12904,17 @@ func (this *DeleteOptions) String() string { `GracePeriodSeconds:` + valueToStringGenerated(this.GracePeriodSeconds) + `,`, `Preconditions:` + strings.Replace(fmt.Sprintf("%v", this.Preconditions), "Preconditions", "Preconditions", 1) + `,`, `OrphanDependents:` + valueToStringGenerated(this.OrphanDependents) + `,`, + `PropagationPolicy:` + valueToStringGenerated(this.PropagationPolicy) + `,`, + `}`, + }, "") + return s +} +func (this *DownwardAPIProjection) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DownwardAPIProjection{`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "DownwardAPIVolumeFile", "DownwardAPIVolumeFile", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -11294,6 +12949,7 @@ func (this *EmptyDirVolumeSource) String() string { } s := strings.Join([]string{`&EmptyDirVolumeSource{`, `Medium:` + fmt.Sprintf("%v", this.Medium) + `,`, + `SizeLimit:` + strings.Replace(strings.Replace(this.SizeLimit.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -11340,7 +12996,7 @@ func (this *Endpoints) String() string { return "nil" } s := strings.Join([]string{`&Endpoints{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Subsets:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Subsets), "EndpointSubset", "EndpointSubset", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11351,12 +13007,24 @@ func (this *EndpointsList) String() string { return "nil" } s := strings.Join([]string{`&EndpointsList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Endpoints", "Endpoints", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } +func (this *EnvFromSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&EnvFromSource{`, + `Prefix:` + fmt.Sprintf("%v", this.Prefix) + `,`, + `ConfigMapRef:` + strings.Replace(fmt.Sprintf("%v", this.ConfigMapRef), "ConfigMapEnvSource", "ConfigMapEnvSource", 1) + `,`, + `SecretRef:` + strings.Replace(fmt.Sprintf("%v", this.SecretRef), "SecretEnvSource", "SecretEnvSource", 1) + `,`, + `}`, + }, "") + return s +} func (this *EnvVar) String() string { if this == nil { return "nil" @@ -11387,13 +13055,13 @@ func (this *Event) String() string { return "nil" } s := strings.Join([]string{`&Event{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `InvolvedObject:` + strings.Replace(strings.Replace(this.InvolvedObject.String(), "ObjectReference", "ObjectReference", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `Source:` + strings.Replace(strings.Replace(this.Source.String(), "EventSource", "EventSource", 1), `&`, ``, 1) + `,`, - `FirstTimestamp:` + strings.Replace(strings.Replace(this.FirstTimestamp.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTimestamp:` + strings.Replace(strings.Replace(this.LastTimestamp.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `FirstTimestamp:` + strings.Replace(strings.Replace(this.FirstTimestamp.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `LastTimestamp:` + strings.Replace(strings.Replace(this.LastTimestamp.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Count:` + fmt.Sprintf("%v", this.Count) + `,`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `}`, @@ -11405,7 +13073,7 @@ func (this *EventList) String() string { return "nil" } s := strings.Join([]string{`&EventList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Event", "Event", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11432,17 +13100,6 @@ func (this *ExecAction) String() string { }, "") return s } -func (this *ExportOptions) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ExportOptions{`, - `Export:` + fmt.Sprintf("%v", this.Export) + `,`, - `Exact:` + fmt.Sprintf("%v", this.Exact) + `,`, - `}`, - }, "") - return s -} func (this *FCVolumeSource) String() string { if this == nil { return "nil" @@ -11534,7 +13191,7 @@ func (this *HTTPGetAction) String() string { } s := strings.Join([]string{`&HTTPGetAction{`, `Path:` + fmt.Sprintf("%v", this.Path) + `,`, - `Port:` + strings.Replace(strings.Replace(this.Port.String(), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, + `Port:` + strings.Replace(strings.Replace(this.Port.String(), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, `Host:` + fmt.Sprintf("%v", this.Host) + `,`, `Scheme:` + fmt.Sprintf("%v", this.Scheme) + `,`, `HTTPHeaders:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.HTTPHeaders), "HTTPHeader", "HTTPHeader", 1), `&`, ``, 1) + `,`, @@ -11565,6 +13222,17 @@ func (this *Handler) String() string { }, "") return s } +func (this *HostAlias) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HostAlias{`, + `IP:` + fmt.Sprintf("%v", this.IP) + `,`, + `Hostnames:` + fmt.Sprintf("%v", this.Hostnames) + `,`, + `}`, + }, "") + return s +} func (this *HostPathVolumeSource) String() string { if this == nil { return "nil" @@ -11586,6 +13254,10 @@ func (this *ISCSIVolumeSource) String() string { `ISCSIInterface:` + fmt.Sprintf("%v", this.ISCSIInterface) + `,`, `FSType:` + fmt.Sprintf("%v", this.FSType) + `,`, `ReadOnly:` + fmt.Sprintf("%v", this.ReadOnly) + `,`, + `Portals:` + fmt.Sprintf("%v", this.Portals) + `,`, + `DiscoveryCHAPAuth:` + fmt.Sprintf("%v", this.DiscoveryCHAPAuth) + `,`, + `SecretRef:` + strings.Replace(fmt.Sprintf("%v", this.SecretRef), "LocalObjectReference", "LocalObjectReference", 1) + `,`, + `SessionCHAPAuth:` + fmt.Sprintf("%v", this.SessionCHAPAuth) + `,`, `}`, }, "") return s @@ -11618,7 +13290,7 @@ func (this *LimitRange) String() string { return "nil" } s := strings.Join([]string{`&LimitRange{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "LimitRangeSpec", "LimitRangeSpec", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11694,7 +13366,7 @@ func (this *LimitRangeList) String() string { return "nil" } s := strings.Join([]string{`&LimitRangeList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "LimitRange", "LimitRange", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11715,8 +13387,8 @@ func (this *List) String() string { return "nil" } s := strings.Join([]string{`&List{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "RawExtension", "k8s_io_kubernetes_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "RawExtension", "k8s_io_apimachinery_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -11731,6 +13403,7 @@ func (this *ListOptions) String() string { `Watch:` + fmt.Sprintf("%v", this.Watch) + `,`, `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, `TimeoutSeconds:` + valueToStringGenerated(this.TimeoutSeconds) + `,`, + `IncludeUninitialized:` + fmt.Sprintf("%v", this.IncludeUninitialized) + `,`, `}`, }, "") return s @@ -11766,6 +13439,16 @@ func (this *LocalObjectReference) String() string { }, "") return s } +func (this *LocalVolumeSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&LocalVolumeSource{`, + `Path:` + fmt.Sprintf("%v", this.Path) + `,`, + `}`, + }, "") + return s +} func (this *NFSVolumeSource) String() string { if this == nil { return "nil" @@ -11783,7 +13466,7 @@ func (this *Namespace) String() string { return "nil" } s := strings.Join([]string{`&Namespace{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "NamespaceSpec", "NamespaceSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "NamespaceStatus", "NamespaceStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -11795,7 +13478,7 @@ func (this *NamespaceList) String() string { return "nil" } s := strings.Join([]string{`&NamespaceList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Namespace", "Namespace", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11826,7 +13509,7 @@ func (this *Node) String() string { return "nil" } s := strings.Join([]string{`&Node{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "NodeSpec", "NodeSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "NodeStatus", "NodeStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -11862,8 +13545,8 @@ func (this *NodeCondition) String() string { s := strings.Join([]string{`&NodeCondition{`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastHeartbeatTime:` + strings.Replace(strings.Replace(this.LastHeartbeatTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastHeartbeatTime:` + strings.Replace(strings.Replace(this.LastHeartbeatTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `}`, @@ -11885,7 +13568,7 @@ func (this *NodeList) String() string { return "nil" } s := strings.Join([]string{`&NodeList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Node", "Node", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -11901,6 +13584,26 @@ func (this *NodeProxyOptions) String() string { }, "") return s } +func (this *NodeResources) String() string { + if this == nil { + return "nil" + } + keysForCapacity := make([]string, 0, len(this.Capacity)) + for k := range this.Capacity { + keysForCapacity = append(keysForCapacity, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForCapacity) + mapStringForCapacity := "ResourceList{" + for _, k := range keysForCapacity { + mapStringForCapacity += fmt.Sprintf("%v: %v,", k, this.Capacity[ResourceName(k)]) + } + mapStringForCapacity += "}" + s := strings.Join([]string{`&NodeResources{`, + `Capacity:` + mapStringForCapacity + `,`, + `}`, + }, "") + return s +} func (this *NodeSelector) String() string { if this == nil { return "nil" @@ -11942,6 +13645,7 @@ func (this *NodeSpec) String() string { `ExternalID:` + fmt.Sprintf("%v", this.ExternalID) + `,`, `ProviderID:` + fmt.Sprintf("%v", this.ProviderID) + `,`, `Unschedulable:` + fmt.Sprintf("%v", this.Unschedulable) + `,`, + `Taints:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Taints), "Taint", "Taint", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -12047,14 +13751,15 @@ func (this *ObjectMeta) String() string { `UID:` + fmt.Sprintf("%v", this.UID) + `,`, `ResourceVersion:` + fmt.Sprintf("%v", this.ResourceVersion) + `,`, `Generation:` + fmt.Sprintf("%v", this.Generation) + `,`, - `CreationTimestamp:` + strings.Replace(strings.Replace(this.CreationTimestamp.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `DeletionTimestamp:` + strings.Replace(fmt.Sprintf("%v", this.DeletionTimestamp), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, + `CreationTimestamp:` + strings.Replace(strings.Replace(this.CreationTimestamp.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `DeletionTimestamp:` + strings.Replace(fmt.Sprintf("%v", this.DeletionTimestamp), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, `DeletionGracePeriodSeconds:` + valueToStringGenerated(this.DeletionGracePeriodSeconds) + `,`, `Labels:` + mapStringForLabels + `,`, `Annotations:` + mapStringForAnnotations + `,`, - `OwnerReferences:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.OwnerReferences), "OwnerReference", "OwnerReference", 1), `&`, ``, 1) + `,`, + `OwnerReferences:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.OwnerReferences), "OwnerReference", "k8s_io_apimachinery_pkg_apis_meta_v1.OwnerReference", 1), `&`, ``, 1) + `,`, `Finalizers:` + fmt.Sprintf("%v", this.Finalizers) + `,`, `ClusterName:` + fmt.Sprintf("%v", this.ClusterName) + `,`, + `Initializers:` + strings.Replace(fmt.Sprintf("%v", this.Initializers), "Initializers", "k8s_io_apimachinery_pkg_apis_meta_v1.Initializers", 1) + `,`, `}`, }, "") return s @@ -12075,26 +13780,12 @@ func (this *ObjectReference) String() string { }, "") return s } -func (this *OwnerReference) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&OwnerReference{`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `UID:` + fmt.Sprintf("%v", this.UID) + `,`, - `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`, - `Controller:` + valueToStringGenerated(this.Controller) + `,`, - `}`, - }, "") - return s -} func (this *PersistentVolume) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&PersistentVolume{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PersistentVolumeSpec", "PersistentVolumeSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "PersistentVolumeStatus", "PersistentVolumeStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -12106,7 +13797,7 @@ func (this *PersistentVolumeClaim) String() string { return "nil" } s := strings.Join([]string{`&PersistentVolumeClaim{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PersistentVolumeClaimSpec", "PersistentVolumeClaimSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "PersistentVolumeClaimStatus", "PersistentVolumeClaimStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -12118,7 +13809,7 @@ func (this *PersistentVolumeClaimList) String() string { return "nil" } s := strings.Join([]string{`&PersistentVolumeClaimList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "PersistentVolumeClaim", "PersistentVolumeClaim", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12132,7 +13823,8 @@ func (this *PersistentVolumeClaimSpec) String() string { `AccessModes:` + fmt.Sprintf("%v", this.AccessModes) + `,`, `Resources:` + strings.Replace(strings.Replace(this.Resources.String(), "ResourceRequirements", "ResourceRequirements", 1), `&`, ``, 1) + `,`, `VolumeName:` + fmt.Sprintf("%v", this.VolumeName) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `StorageClassName:` + valueToStringGenerated(this.StorageClassName) + `,`, `}`, }, "") return s @@ -12175,7 +13867,7 @@ func (this *PersistentVolumeList) String() string { return "nil" } s := strings.Join([]string{`&PersistentVolumeList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "PersistentVolume", "PersistentVolume", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12203,6 +13895,10 @@ func (this *PersistentVolumeSource) String() string { `Quobyte:` + strings.Replace(fmt.Sprintf("%v", this.Quobyte), "QuobyteVolumeSource", "QuobyteVolumeSource", 1) + `,`, `AzureDisk:` + strings.Replace(fmt.Sprintf("%v", this.AzureDisk), "AzureDiskVolumeSource", "AzureDiskVolumeSource", 1) + `,`, `PhotonPersistentDisk:` + strings.Replace(fmt.Sprintf("%v", this.PhotonPersistentDisk), "PhotonPersistentDiskVolumeSource", "PhotonPersistentDiskVolumeSource", 1) + `,`, + `PortworxVolume:` + strings.Replace(fmt.Sprintf("%v", this.PortworxVolume), "PortworxVolumeSource", "PortworxVolumeSource", 1) + `,`, + `ScaleIO:` + strings.Replace(fmt.Sprintf("%v", this.ScaleIO), "ScaleIOVolumeSource", "ScaleIOVolumeSource", 1) + `,`, + `Local:` + strings.Replace(fmt.Sprintf("%v", this.Local), "LocalVolumeSource", "LocalVolumeSource", 1) + `,`, + `StorageOS:` + strings.Replace(fmt.Sprintf("%v", this.StorageOS), "StorageOSPersistentVolumeSource", "StorageOSPersistentVolumeSource", 1) + `,`, `}`, }, "") return s @@ -12227,6 +13923,7 @@ func (this *PersistentVolumeSpec) String() string { `AccessModes:` + fmt.Sprintf("%v", this.AccessModes) + `,`, `ClaimRef:` + strings.Replace(fmt.Sprintf("%v", this.ClaimRef), "ObjectReference", "ObjectReference", 1) + `,`, `PersistentVolumeReclaimPolicy:` + fmt.Sprintf("%v", this.PersistentVolumeReclaimPolicy) + `,`, + `StorageClassName:` + fmt.Sprintf("%v", this.StorageClassName) + `,`, `}`, }, "") return s @@ -12259,7 +13956,7 @@ func (this *Pod) String() string { return "nil" } s := strings.Join([]string{`&Pod{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PodSpec", "PodSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "PodStatus", "PodStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -12282,7 +13979,7 @@ func (this *PodAffinityTerm) String() string { return "nil" } s := strings.Join([]string{`&PodAffinityTerm{`, - `LabelSelector:` + strings.Replace(fmt.Sprintf("%v", this.LabelSelector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `LabelSelector:` + strings.Replace(fmt.Sprintf("%v", this.LabelSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, `Namespaces:` + fmt.Sprintf("%v", this.Namespaces) + `,`, `TopologyKey:` + fmt.Sprintf("%v", this.TopologyKey) + `,`, `}`, @@ -12321,8 +14018,8 @@ func (this *PodCondition) String() string { s := strings.Join([]string{`&PodCondition{`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastProbeTime:` + strings.Replace(strings.Replace(this.LastProbeTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastProbeTime:` + strings.Replace(strings.Replace(this.LastProbeTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `}`, @@ -12349,7 +14046,7 @@ func (this *PodList) String() string { return "nil" } s := strings.Join([]string{`&PodList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Pod", "Pod", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12364,7 +14061,7 @@ func (this *PodLogOptions) String() string { `Follow:` + fmt.Sprintf("%v", this.Follow) + `,`, `Previous:` + fmt.Sprintf("%v", this.Previous) + `,`, `SinceSeconds:` + valueToStringGenerated(this.SinceSeconds) + `,`, - `SinceTime:` + strings.Replace(fmt.Sprintf("%v", this.SinceTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, + `SinceTime:` + strings.Replace(fmt.Sprintf("%v", this.SinceTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, `Timestamps:` + fmt.Sprintf("%v", this.Timestamps) + `,`, `TailLines:` + valueToStringGenerated(this.TailLines) + `,`, `LimitBytes:` + valueToStringGenerated(this.LimitBytes) + `,`, @@ -12372,6 +14069,16 @@ func (this *PodLogOptions) String() string { }, "") return s } +func (this *PodPortForwardOptions) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodPortForwardOptions{`, + `Ports:` + fmt.Sprintf("%v", this.Ports) + `,`, + `}`, + }, "") + return s +} func (this *PodProxyOptions) String() string { if this == nil { return "nil" @@ -12401,7 +14108,7 @@ func (this *PodSignature) String() string { return "nil" } s := strings.Join([]string{`&PodSignature{`, - `PodController:` + strings.Replace(fmt.Sprintf("%v", this.PodController), "OwnerReference", "OwnerReference", 1) + `,`, + `PodController:` + strings.Replace(fmt.Sprintf("%v", this.PodController), "OwnerReference", "k8s_io_apimachinery_pkg_apis_meta_v1.OwnerReference", 1) + `,`, `}`, }, "") return s @@ -12438,6 +14145,12 @@ func (this *PodSpec) String() string { `ImagePullSecrets:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ImagePullSecrets), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, `Hostname:` + fmt.Sprintf("%v", this.Hostname) + `,`, `Subdomain:` + fmt.Sprintf("%v", this.Subdomain) + `,`, + `Affinity:` + strings.Replace(fmt.Sprintf("%v", this.Affinity), "Affinity", "Affinity", 1) + `,`, + `SchedulerName:` + fmt.Sprintf("%v", this.SchedulerName) + `,`, + `InitContainers:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.InitContainers), "Container", "Container", 1), `&`, ``, 1) + `,`, + `AutomountServiceAccountToken:` + valueToStringGenerated(this.AutomountServiceAccountToken) + `,`, + `Tolerations:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Tolerations), "Toleration", "Toleration", 1), `&`, ``, 1) + `,`, + `HostAliases:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.HostAliases), "HostAlias", "HostAlias", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -12453,8 +14166,10 @@ func (this *PodStatus) String() string { `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `HostIP:` + fmt.Sprintf("%v", this.HostIP) + `,`, `PodIP:` + fmt.Sprintf("%v", this.PodIP) + `,`, - `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, + `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, `ContainerStatuses:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ContainerStatuses), "ContainerStatus", "ContainerStatus", 1), `&`, ``, 1) + `,`, + `QOSClass:` + fmt.Sprintf("%v", this.QOSClass) + `,`, + `InitContainerStatuses:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.InitContainerStatuses), "ContainerStatus", "ContainerStatus", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -12464,7 +14179,7 @@ func (this *PodStatusResult) String() string { return "nil" } s := strings.Join([]string{`&PodStatusResult{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "PodStatus", "PodStatus", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12475,7 +14190,7 @@ func (this *PodTemplate) String() string { return "nil" } s := strings.Join([]string{`&PodTemplate{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "PodTemplateSpec", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12486,7 +14201,7 @@ func (this *PodTemplateList) String() string { return "nil" } s := strings.Join([]string{`&PodTemplateList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "PodTemplate", "PodTemplate", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12497,12 +14212,24 @@ func (this *PodTemplateSpec) String() string { return "nil" } s := strings.Join([]string{`&PodTemplateSpec{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PodSpec", "PodSpec", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } +func (this *PortworxVolumeSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PortworxVolumeSource{`, + `VolumeID:` + fmt.Sprintf("%v", this.VolumeID) + `,`, + `FSType:` + fmt.Sprintf("%v", this.FSType) + `,`, + `ReadOnly:` + fmt.Sprintf("%v", this.ReadOnly) + `,`, + `}`, + }, "") + return s +} func (this *Preconditions) String() string { if this == nil { return "nil" @@ -12519,7 +14246,7 @@ func (this *PreferAvoidPodsEntry) String() string { } s := strings.Join([]string{`&PreferAvoidPodsEntry{`, `PodSignature:` + strings.Replace(strings.Replace(this.PodSignature.String(), "PodSignature", "PodSignature", 1), `&`, ``, 1) + `,`, - `EvictionTime:` + strings.Replace(strings.Replace(this.EvictionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `EvictionTime:` + strings.Replace(strings.Replace(this.EvictionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `}`, @@ -12552,6 +14279,17 @@ func (this *Probe) String() string { }, "") return s } +func (this *ProjectedVolumeSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ProjectedVolumeSource{`, + `Sources:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Sources), "VolumeProjection", "VolumeProjection", 1), `&`, ``, 1) + `,`, + `DefaultMode:` + valueToStringGenerated(this.DefaultMode) + `,`, + `}`, + }, "") + return s +} func (this *QuobyteVolumeSource) String() string { if this == nil { return "nil" @@ -12588,7 +14326,7 @@ func (this *RangeAllocation) String() string { return "nil" } s := strings.Join([]string{`&RangeAllocation{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Range:` + fmt.Sprintf("%v", this.Range) + `,`, `Data:` + valueToStringGenerated(this.Data) + `,`, `}`, @@ -12600,7 +14338,7 @@ func (this *ReplicationController) String() string { return "nil" } s := strings.Join([]string{`&ReplicationController{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ReplicationControllerSpec", "ReplicationControllerSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ReplicationControllerStatus", "ReplicationControllerStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -12614,7 +14352,7 @@ func (this *ReplicationControllerCondition) String() string { s := strings.Join([]string{`&ReplicationControllerCondition{`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `}`, @@ -12626,7 +14364,7 @@ func (this *ReplicationControllerList) String() string { return "nil" } s := strings.Join([]string{`&ReplicationControllerList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ReplicationController", "ReplicationController", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12677,7 +14415,7 @@ func (this *ResourceFieldSelector) String() string { s := strings.Join([]string{`&ResourceFieldSelector{`, `ContainerName:` + fmt.Sprintf("%v", this.ContainerName) + `,`, `Resource:` + fmt.Sprintf("%v", this.Resource) + `,`, - `Divisor:` + strings.Replace(strings.Replace(this.Divisor.String(), "Quantity", "k8s_io_kubernetes_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `Divisor:` + strings.Replace(strings.Replace(this.Divisor.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -12687,7 +14425,7 @@ func (this *ResourceQuota) String() string { return "nil" } s := strings.Join([]string{`&ResourceQuota{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ResourceQuotaSpec", "ResourceQuotaSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ResourceQuotaStatus", "ResourceQuotaStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -12699,7 +14437,7 @@ func (this *ResourceQuotaList) String() string { return "nil" } s := strings.Join([]string{`&ResourceQuotaList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ResourceQuota", "ResourceQuota", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12801,6 +14539,25 @@ func (this *SELinuxOptions) String() string { }, "") return s } +func (this *ScaleIOVolumeSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ScaleIOVolumeSource{`, + `Gateway:` + fmt.Sprintf("%v", this.Gateway) + `,`, + `System:` + fmt.Sprintf("%v", this.System) + `,`, + `SecretRef:` + strings.Replace(fmt.Sprintf("%v", this.SecretRef), "LocalObjectReference", "LocalObjectReference", 1) + `,`, + `SSLEnabled:` + fmt.Sprintf("%v", this.SSLEnabled) + `,`, + `ProtectionDomain:` + fmt.Sprintf("%v", this.ProtectionDomain) + `,`, + `StoragePool:` + fmt.Sprintf("%v", this.StoragePool) + `,`, + `StorageMode:` + fmt.Sprintf("%v", this.StorageMode) + `,`, + `VolumeName:` + fmt.Sprintf("%v", this.VolumeName) + `,`, + `FSType:` + fmt.Sprintf("%v", this.FSType) + `,`, + `ReadOnly:` + fmt.Sprintf("%v", this.ReadOnly) + `,`, + `}`, + }, "") + return s +} func (this *Secret) String() string { if this == nil { return "nil" @@ -12826,7 +14583,7 @@ func (this *Secret) String() string { } mapStringForStringData += "}" s := strings.Join([]string{`&Secret{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Data:` + mapStringForData + `,`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `StringData:` + mapStringForStringData + `,`, @@ -12834,6 +14591,17 @@ func (this *Secret) String() string { }, "") return s } +func (this *SecretEnvSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SecretEnvSource{`, + `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, + `}`, + }, "") + return s +} func (this *SecretKeySelector) String() string { if this == nil { return "nil" @@ -12841,6 +14609,7 @@ func (this *SecretKeySelector) String() string { s := strings.Join([]string{`&SecretKeySelector{`, `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, `Key:` + fmt.Sprintf("%v", this.Key) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, `}`, }, "") return s @@ -12850,12 +14619,24 @@ func (this *SecretList) String() string { return "nil" } s := strings.Join([]string{`&SecretList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Secret", "Secret", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } +func (this *SecretProjection) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SecretProjection{`, + `LocalObjectReference:` + strings.Replace(strings.Replace(this.LocalObjectReference.String(), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "KeyToPath", "KeyToPath", 1), `&`, ``, 1) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, + `}`, + }, "") + return s +} func (this *SecretVolumeSource) String() string { if this == nil { return "nil" @@ -12864,6 +14645,7 @@ func (this *SecretVolumeSource) String() string { `SecretName:` + fmt.Sprintf("%v", this.SecretName) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "KeyToPath", "KeyToPath", 1), `&`, ``, 1) + `,`, `DefaultMode:` + valueToStringGenerated(this.DefaultMode) + `,`, + `Optional:` + valueToStringGenerated(this.Optional) + `,`, `}`, }, "") return s @@ -12898,7 +14680,7 @@ func (this *Service) String() string { return "nil" } s := strings.Join([]string{`&Service{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ServiceSpec", "ServiceSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ServiceStatus", "ServiceStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -12910,9 +14692,10 @@ func (this *ServiceAccount) String() string { return "nil" } s := strings.Join([]string{`&ServiceAccount{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Secrets:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Secrets), "ObjectReference", "ObjectReference", 1), `&`, ``, 1) + `,`, `ImagePullSecrets:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ImagePullSecrets), "LocalObjectReference", "LocalObjectReference", 1), `&`, ``, 1) + `,`, + `AutomountServiceAccountToken:` + valueToStringGenerated(this.AutomountServiceAccountToken) + `,`, `}`, }, "") return s @@ -12922,7 +14705,7 @@ func (this *ServiceAccountList) String() string { return "nil" } s := strings.Join([]string{`&ServiceAccountList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ServiceAccount", "ServiceAccount", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12933,7 +14716,7 @@ func (this *ServiceList) String() string { return "nil" } s := strings.Join([]string{`&ServiceList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Service", "Service", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -12947,7 +14730,7 @@ func (this *ServicePort) String() string { `Name:` + fmt.Sprintf("%v", this.Name) + `,`, `Protocol:` + fmt.Sprintf("%v", this.Protocol) + `,`, `Port:` + fmt.Sprintf("%v", this.Port) + `,`, - `TargetPort:` + strings.Replace(strings.Replace(this.TargetPort.String(), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, + `TargetPort:` + strings.Replace(strings.Replace(this.TargetPort.String(), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, `NodePort:` + fmt.Sprintf("%v", this.NodePort) + `,`, `}`, }, "") @@ -12983,11 +14766,12 @@ func (this *ServiceSpec) String() string { `ClusterIP:` + fmt.Sprintf("%v", this.ClusterIP) + `,`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `ExternalIPs:` + fmt.Sprintf("%v", this.ExternalIPs) + `,`, - `DeprecatedPublicIPs:` + fmt.Sprintf("%v", this.DeprecatedPublicIPs) + `,`, `SessionAffinity:` + fmt.Sprintf("%v", this.SessionAffinity) + `,`, `LoadBalancerIP:` + fmt.Sprintf("%v", this.LoadBalancerIP) + `,`, `LoadBalancerSourceRanges:` + fmt.Sprintf("%v", this.LoadBalancerSourceRanges) + `,`, `ExternalName:` + fmt.Sprintf("%v", this.ExternalName) + `,`, + `ExternalTrafficPolicy:` + fmt.Sprintf("%v", this.ExternalTrafficPolicy) + `,`, + `HealthCheckNodePort:` + fmt.Sprintf("%v", this.HealthCheckNodePort) + `,`, `}`, }, "") return s @@ -13002,12 +14786,52 @@ func (this *ServiceStatus) String() string { }, "") return s } +func (this *StorageOSPersistentVolumeSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StorageOSPersistentVolumeSource{`, + `VolumeName:` + fmt.Sprintf("%v", this.VolumeName) + `,`, + `VolumeNamespace:` + fmt.Sprintf("%v", this.VolumeNamespace) + `,`, + `FSType:` + fmt.Sprintf("%v", this.FSType) + `,`, + `ReadOnly:` + fmt.Sprintf("%v", this.ReadOnly) + `,`, + `SecretRef:` + strings.Replace(fmt.Sprintf("%v", this.SecretRef), "ObjectReference", "ObjectReference", 1) + `,`, + `}`, + }, "") + return s +} +func (this *StorageOSVolumeSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StorageOSVolumeSource{`, + `VolumeName:` + fmt.Sprintf("%v", this.VolumeName) + `,`, + `VolumeNamespace:` + fmt.Sprintf("%v", this.VolumeNamespace) + `,`, + `FSType:` + fmt.Sprintf("%v", this.FSType) + `,`, + `ReadOnly:` + fmt.Sprintf("%v", this.ReadOnly) + `,`, + `SecretRef:` + strings.Replace(fmt.Sprintf("%v", this.SecretRef), "LocalObjectReference", "LocalObjectReference", 1) + `,`, + `}`, + }, "") + return s +} +func (this *Sysctl) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Sysctl{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Value:` + fmt.Sprintf("%v", this.Value) + `,`, + `}`, + }, "") + return s +} func (this *TCPSocketAction) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&TCPSocketAction{`, - `Port:` + strings.Replace(strings.Replace(this.Port.String(), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, + `Port:` + strings.Replace(strings.Replace(this.Port.String(), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, + `Host:` + fmt.Sprintf("%v", this.Host) + `,`, `}`, }, "") return s @@ -13020,6 +14844,7 @@ func (this *Taint) String() string { `Key:` + fmt.Sprintf("%v", this.Key) + `,`, `Value:` + fmt.Sprintf("%v", this.Value) + `,`, `Effect:` + fmt.Sprintf("%v", this.Effect) + `,`, + `TimeAdded:` + strings.Replace(strings.Replace(this.TimeAdded.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -13033,6 +14858,7 @@ func (this *Toleration) String() string { `Operator:` + fmt.Sprintf("%v", this.Operator) + `,`, `Value:` + fmt.Sprintf("%v", this.Value) + `,`, `Effect:` + fmt.Sprintf("%v", this.Effect) + `,`, + `TolerationSeconds:` + valueToStringGenerated(this.TolerationSeconds) + `,`, `}`, }, "") return s @@ -13061,6 +14887,18 @@ func (this *VolumeMount) String() string { }, "") return s } +func (this *VolumeProjection) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&VolumeProjection{`, + `Secret:` + strings.Replace(fmt.Sprintf("%v", this.Secret), "SecretProjection", "SecretProjection", 1) + `,`, + `DownwardAPI:` + strings.Replace(fmt.Sprintf("%v", this.DownwardAPI), "DownwardAPIProjection", "DownwardAPIProjection", 1) + `,`, + `ConfigMap:` + strings.Replace(fmt.Sprintf("%v", this.ConfigMap), "ConfigMapProjection", "ConfigMapProjection", 1) + `,`, + `}`, + }, "") + return s +} func (this *VolumeSource) String() string { if this == nil { return "nil" @@ -13089,6 +14927,10 @@ func (this *VolumeSource) String() string { `Quobyte:` + strings.Replace(fmt.Sprintf("%v", this.Quobyte), "QuobyteVolumeSource", "QuobyteVolumeSource", 1) + `,`, `AzureDisk:` + strings.Replace(fmt.Sprintf("%v", this.AzureDisk), "AzureDiskVolumeSource", "AzureDiskVolumeSource", 1) + `,`, `PhotonPersistentDisk:` + strings.Replace(fmt.Sprintf("%v", this.PhotonPersistentDisk), "PhotonPersistentDiskVolumeSource", "PhotonPersistentDiskVolumeSource", 1) + `,`, + `PortworxVolume:` + strings.Replace(fmt.Sprintf("%v", this.PortworxVolume), "PortworxVolumeSource", "PortworxVolumeSource", 1) + `,`, + `ScaleIO:` + strings.Replace(fmt.Sprintf("%v", this.ScaleIO), "ScaleIOVolumeSource", "ScaleIOVolumeSource", 1) + `,`, + `Projected:` + strings.Replace(fmt.Sprintf("%v", this.Projected), "ProjectedVolumeSource", "ProjectedVolumeSource", 1) + `,`, + `StorageOS:` + strings.Replace(fmt.Sprintf("%v", this.StorageOS), "StorageOSVolumeSource", "StorageOSVolumeSource", 1) + `,`, `}`, }, "") return s @@ -13100,6 +14942,8 @@ func (this *VsphereVirtualDiskVolumeSource) String() string { s := strings.Join([]string{`&VsphereVirtualDiskVolumeSource{`, `VolumePath:` + fmt.Sprintf("%v", this.VolumePath) + `,`, `FSType:` + fmt.Sprintf("%v", this.FSType) + `,`, + `StoragePolicyName:` + fmt.Sprintf("%v", this.StoragePolicyName) + `,`, + `StoragePolicyID:` + fmt.Sprintf("%v", this.StoragePolicyID) + `,`, `}`, }, "") return s @@ -13123,8 +14967,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13136,7 +14980,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13164,7 +15008,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13179,7 +15023,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.VolumeID = string(data[iNdEx:postIndex]) + m.VolumeID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -13193,7 +15037,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13208,7 +15052,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -13222,7 +15066,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Partition |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -13241,7 +15085,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13251,7 +15095,7 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13270,8 +15114,8 @@ func (m *AWSElasticBlockStoreVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *Affinity) Unmarshal(data []byte) error { - l := len(data) +func (m *Affinity) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13283,7 +15127,7 @@ func (m *Affinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13311,7 +15155,7 @@ func (m *Affinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13328,7 +15172,7 @@ func (m *Affinity) Unmarshal(data []byte) error { if m.NodeAffinity == nil { m.NodeAffinity = &NodeAffinity{} } - if err := m.NodeAffinity.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NodeAffinity.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13344,7 +15188,7 @@ func (m *Affinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13361,7 +15205,7 @@ func (m *Affinity) Unmarshal(data []byte) error { if m.PodAffinity == nil { m.PodAffinity = &PodAffinity{} } - if err := m.PodAffinity.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodAffinity.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13377,7 +15221,7 @@ func (m *Affinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13394,13 +15238,13 @@ func (m *Affinity) Unmarshal(data []byte) error { if m.PodAntiAffinity == nil { m.PodAntiAffinity = &PodAntiAffinity{} } - if err := m.PodAntiAffinity.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodAntiAffinity.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13419,8 +15263,8 @@ func (m *Affinity) Unmarshal(data []byte) error { } return nil } -func (m *AttachedVolume) Unmarshal(data []byte) error { - l := len(data) +func (m *AttachedVolume) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13432,7 +15276,7 @@ func (m *AttachedVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13460,7 +15304,7 @@ func (m *AttachedVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13475,7 +15319,7 @@ func (m *AttachedVolume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = UniqueVolumeName(data[iNdEx:postIndex]) + m.Name = UniqueVolumeName(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -13489,7 +15333,7 @@ func (m *AttachedVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13504,11 +15348,11 @@ func (m *AttachedVolume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DevicePath = string(data[iNdEx:postIndex]) + m.DevicePath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13527,8 +15371,8 @@ func (m *AttachedVolume) Unmarshal(data []byte) error { } return nil } -func (m *AvoidPods) Unmarshal(data []byte) error { - l := len(data) +func (m *AvoidPods) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13540,7 +15384,7 @@ func (m *AvoidPods) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13568,7 +15412,7 @@ func (m *AvoidPods) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13583,13 +15427,13 @@ func (m *AvoidPods) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.PreferAvoidPods = append(m.PreferAvoidPods, PreferAvoidPodsEntry{}) - if err := m.PreferAvoidPods[len(m.PreferAvoidPods)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PreferAvoidPods[len(m.PreferAvoidPods)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13608,8 +15452,8 @@ func (m *AvoidPods) Unmarshal(data []byte) error { } return nil } -func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *AzureDiskVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13621,7 +15465,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13649,7 +15493,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13664,7 +15508,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DiskName = string(data[iNdEx:postIndex]) + m.DiskName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -13678,7 +15522,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13693,7 +15537,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DataDiskURI = string(data[iNdEx:postIndex]) + m.DataDiskURI = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -13707,7 +15551,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13722,7 +15566,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := AzureDataDiskCachingMode(data[iNdEx:postIndex]) + s := AzureDataDiskCachingMode(dAtA[iNdEx:postIndex]) m.CachingMode = &s iNdEx = postIndex case 4: @@ -13737,7 +15581,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13752,7 +15596,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := string(data[iNdEx:postIndex]) + s := string(dAtA[iNdEx:postIndex]) m.FSType = &s iNdEx = postIndex case 5: @@ -13767,7 +15611,7 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13776,9 +15620,39 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { } b := bool(v != 0) m.ReadOnly = &b + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := AzureDataDiskKind(dAtA[iNdEx:postIndex]) + m.Kind = &s + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13797,8 +15671,8 @@ func (m *AzureDiskVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *AzureFileVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13810,7 +15684,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13838,7 +15712,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13853,7 +15727,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.SecretName = string(data[iNdEx:postIndex]) + m.SecretName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -13867,7 +15741,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13882,7 +15756,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ShareName = string(data[iNdEx:postIndex]) + m.ShareName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -13896,7 +15770,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13906,7 +15780,7 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13925,8 +15799,8 @@ func (m *AzureFileVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *Binding) Unmarshal(data []byte) error { - l := len(data) +func (m *Binding) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13938,7 +15812,7 @@ func (m *Binding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13966,7 +15840,7 @@ func (m *Binding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13980,7 +15854,7 @@ func (m *Binding) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13996,7 +15870,7 @@ func (m *Binding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14010,13 +15884,13 @@ func (m *Binding) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Target.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14035,8 +15909,8 @@ func (m *Binding) Unmarshal(data []byte) error { } return nil } -func (m *Capabilities) Unmarshal(data []byte) error { - l := len(data) +func (m *Capabilities) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14048,7 +15922,7 @@ func (m *Capabilities) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14076,7 +15950,7 @@ func (m *Capabilities) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14091,7 +15965,7 @@ func (m *Capabilities) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Add = append(m.Add, Capability(data[iNdEx:postIndex])) + m.Add = append(m.Add, Capability(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 2: if wireType != 2 { @@ -14105,7 +15979,7 @@ func (m *Capabilities) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14120,11 +15994,11 @@ func (m *Capabilities) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Drop = append(m.Drop, Capability(data[iNdEx:postIndex])) + m.Drop = append(m.Drop, Capability(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14143,8 +16017,8 @@ func (m *Capabilities) Unmarshal(data []byte) error { } return nil } -func (m *CephFSVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *CephFSVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14156,7 +16030,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14184,7 +16058,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14199,7 +16073,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Monitors = append(m.Monitors, string(data[iNdEx:postIndex])) + m.Monitors = append(m.Monitors, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 2: if wireType != 2 { @@ -14213,7 +16087,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14228,7 +16102,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -14242,7 +16116,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14257,7 +16131,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.User = string(data[iNdEx:postIndex]) + m.User = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -14271,7 +16145,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14286,7 +16160,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.SecretFile = string(data[iNdEx:postIndex]) + m.SecretFile = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -14300,7 +16174,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14317,7 +16191,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if m.SecretRef == nil { m.SecretRef = &LocalObjectReference{} } - if err := m.SecretRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -14333,7 +16207,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14343,7 +16217,7 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14362,8 +16236,8 @@ func (m *CephFSVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *CinderVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *CinderVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14375,7 +16249,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14403,7 +16277,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14418,7 +16292,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.VolumeID = string(data[iNdEx:postIndex]) + m.VolumeID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -14432,7 +16306,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14447,7 +16321,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -14461,7 +16335,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14471,7 +16345,7 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14490,8 +16364,8 @@ func (m *CinderVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *ComponentCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *ComponentCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14503,7 +16377,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14531,7 +16405,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14546,7 +16420,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = ComponentConditionType(data[iNdEx:postIndex]) + m.Type = ComponentConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -14560,7 +16434,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14575,7 +16449,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Status = ConditionStatus(data[iNdEx:postIndex]) + m.Status = ConditionStatus(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -14589,7 +16463,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14604,7 +16478,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -14618,7 +16492,7 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14633,11 +16507,11 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Error = string(data[iNdEx:postIndex]) + m.Error = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14656,8 +16530,8 @@ func (m *ComponentCondition) Unmarshal(data []byte) error { } return nil } -func (m *ComponentStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ComponentStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14669,7 +16543,7 @@ func (m *ComponentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14697,7 +16571,7 @@ func (m *ComponentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14711,7 +16585,7 @@ func (m *ComponentStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -14727,7 +16601,7 @@ func (m *ComponentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14742,13 +16616,13 @@ func (m *ComponentStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, ComponentCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14767,8 +16641,8 @@ func (m *ComponentStatus) Unmarshal(data []byte) error { } return nil } -func (m *ComponentStatusList) Unmarshal(data []byte) error { - l := len(data) +func (m *ComponentStatusList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14780,7 +16654,7 @@ func (m *ComponentStatusList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14808,7 +16682,7 @@ func (m *ComponentStatusList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14822,7 +16696,7 @@ func (m *ComponentStatusList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -14838,7 +16712,7 @@ func (m *ComponentStatusList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14853,13 +16727,13 @@ func (m *ComponentStatusList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ComponentStatus{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -14878,8 +16752,8 @@ func (m *ComponentStatusList) Unmarshal(data []byte) error { } return nil } -func (m *ConfigMap) Unmarshal(data []byte) error { - l := len(data) +func (m *ConfigMap) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -14891,7 +16765,7 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14919,7 +16793,7 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14933,7 +16807,7 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -14949,7 +16823,7 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -14971,7 +16845,7 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -14986,7 +16860,7 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15001,9 +16875,113 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 + if m.Data == nil { + m.Data = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Data[mapkey] = mapvalue + } else { + var mapvalue string + m.Data[mapkey] = mapvalue + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigMapEnvSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigMapEnvSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigMapEnvSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -15011,14 +16989,29 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapvalue uint64 + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -15026,31 +17019,18 @@ func (m *ConfigMap) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Data == nil { - m.Data = make(map[string]string) - } - m.Data[mapkey] = mapvalue - iNdEx = postIndex + b := bool(v != 0) + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -15069,8 +17049,8 @@ func (m *ConfigMap) Unmarshal(data []byte) error { } return nil } -func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { - l := len(data) +func (m *ConfigMapKeySelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -15082,7 +17062,7 @@ func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15110,7 +17090,7 @@ func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15124,7 +17104,7 @@ func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LocalObjectReference.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15140,7 +17120,7 @@ func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15155,11 +17135,32 @@ func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Key = string(data[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -15178,8 +17179,8 @@ func (m *ConfigMapKeySelector) Unmarshal(data []byte) error { } return nil } -func (m *ConfigMapList) Unmarshal(data []byte) error { - l := len(data) +func (m *ConfigMapList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -15191,7 +17192,7 @@ func (m *ConfigMapList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15219,7 +17220,7 @@ func (m *ConfigMapList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15233,7 +17234,7 @@ func (m *ConfigMapList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15249,7 +17250,7 @@ func (m *ConfigMapList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15264,13 +17265,13 @@ func (m *ConfigMapList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ConfigMap{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -15289,8 +17290,8 @@ func (m *ConfigMapList) Unmarshal(data []byte) error { } return nil } -func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *ConfigMapProjection) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -15302,7 +17303,139 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ConfigMapProjection: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ConfigMapProjection: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, KeyToPath{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Optional = &b + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ConfigMapVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15330,7 +17463,7 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15344,7 +17477,7 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LocalObjectReference.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15360,7 +17493,7 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15375,7 +17508,7 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, KeyToPath{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15391,7 +17524,7 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -15399,9 +17532,30 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { } } m.DefaultMode = &v + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -15420,8 +17574,8 @@ func (m *ConfigMapVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *Container) Unmarshal(data []byte) error { - l := len(data) +func (m *Container) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -15433,7 +17587,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15461,7 +17615,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15476,7 +17630,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -15490,7 +17644,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15505,7 +17659,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Image = string(data[iNdEx:postIndex]) + m.Image = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -15519,7 +17673,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15534,7 +17688,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Command = append(m.Command, string(data[iNdEx:postIndex])) + m.Command = append(m.Command, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 4: if wireType != 2 { @@ -15548,7 +17702,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15563,7 +17717,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Args = append(m.Args, string(data[iNdEx:postIndex])) + m.Args = append(m.Args, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 5: if wireType != 2 { @@ -15577,7 +17731,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15592,7 +17746,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.WorkingDir = string(data[iNdEx:postIndex]) + m.WorkingDir = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -15606,7 +17760,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15621,7 +17775,7 @@ func (m *Container) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ports = append(m.Ports, ContainerPort{}) - if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15637,7 +17791,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15652,7 +17806,7 @@ func (m *Container) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Env = append(m.Env, EnvVar{}) - if err := m.Env[len(m.Env)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Env[len(m.Env)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15668,7 +17822,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15682,7 +17836,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Resources.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Resources.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15698,7 +17852,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15713,7 +17867,7 @@ func (m *Container) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.VolumeMounts = append(m.VolumeMounts, VolumeMount{}) - if err := m.VolumeMounts[len(m.VolumeMounts)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.VolumeMounts[len(m.VolumeMounts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15729,7 +17883,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15746,7 +17900,7 @@ func (m *Container) Unmarshal(data []byte) error { if m.LivenessProbe == nil { m.LivenessProbe = &Probe{} } - if err := m.LivenessProbe.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LivenessProbe.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15762,7 +17916,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15779,7 +17933,7 @@ func (m *Container) Unmarshal(data []byte) error { if m.ReadinessProbe == nil { m.ReadinessProbe = &Probe{} } - if err := m.ReadinessProbe.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ReadinessProbe.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15795,7 +17949,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15812,7 +17966,7 @@ func (m *Container) Unmarshal(data []byte) error { if m.Lifecycle == nil { m.Lifecycle = &Lifecycle{} } - if err := m.Lifecycle.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Lifecycle.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15828,7 +17982,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15843,7 +17997,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.TerminationMessagePath = string(data[iNdEx:postIndex]) + m.TerminationMessagePath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 14: if wireType != 2 { @@ -15857,7 +18011,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -15872,7 +18026,7 @@ func (m *Container) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ImagePullPolicy = PullPolicy(data[iNdEx:postIndex]) + m.ImagePullPolicy = PullPolicy(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 15: if wireType != 2 { @@ -15886,7 +18040,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15903,7 +18057,7 @@ func (m *Container) Unmarshal(data []byte) error { if m.SecurityContext == nil { m.SecurityContext = &SecurityContext{} } - if err := m.SecurityContext.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SecurityContext.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -15919,7 +18073,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15939,7 +18093,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15959,7 +18113,7 @@ func (m *Container) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -15967,9 +18121,69 @@ func (m *Container) Unmarshal(data []byte) error { } } m.TTY = bool(v != 0) + case 19: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EnvFrom", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.EnvFrom = append(m.EnvFrom, EnvFromSource{}) + if err := m.EnvFrom[len(m.EnvFrom)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 20: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TerminationMessagePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.TerminationMessagePolicy = TerminationMessagePolicy(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -15988,8 +18202,8 @@ func (m *Container) Unmarshal(data []byte) error { } return nil } -func (m *ContainerImage) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerImage) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16001,7 +18215,7 @@ func (m *ContainerImage) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16029,7 +18243,7 @@ func (m *ContainerImage) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16044,7 +18258,7 @@ func (m *ContainerImage) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Names = append(m.Names, string(data[iNdEx:postIndex])) + m.Names = append(m.Names, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 2: if wireType != 0 { @@ -16058,7 +18272,7 @@ func (m *ContainerImage) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.SizeBytes |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -16067,7 +18281,7 @@ func (m *ContainerImage) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -16086,8 +18300,8 @@ func (m *ContainerImage) Unmarshal(data []byte) error { } return nil } -func (m *ContainerPort) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerPort) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16099,7 +18313,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16127,7 +18341,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16142,7 +18356,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { @@ -16156,7 +18370,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.HostPort |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -16175,7 +18389,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ContainerPort |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -16194,7 +18408,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16209,7 +18423,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Protocol = Protocol(data[iNdEx:postIndex]) + m.Protocol = Protocol(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -16223,7 +18437,7 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16238,11 +18452,11 @@ func (m *ContainerPort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.HostIP = string(data[iNdEx:postIndex]) + m.HostIP = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -16261,8 +18475,8 @@ func (m *ContainerPort) Unmarshal(data []byte) error { } return nil } -func (m *ContainerState) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerState) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16274,7 +18488,7 @@ func (m *ContainerState) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16302,7 +18516,7 @@ func (m *ContainerState) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16319,7 +18533,7 @@ func (m *ContainerState) Unmarshal(data []byte) error { if m.Waiting == nil { m.Waiting = &ContainerStateWaiting{} } - if err := m.Waiting.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Waiting.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -16335,7 +18549,7 @@ func (m *ContainerState) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16352,7 +18566,7 @@ func (m *ContainerState) Unmarshal(data []byte) error { if m.Running == nil { m.Running = &ContainerStateRunning{} } - if err := m.Running.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Running.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -16368,7 +18582,7 @@ func (m *ContainerState) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16385,13 +18599,13 @@ func (m *ContainerState) Unmarshal(data []byte) error { if m.Terminated == nil { m.Terminated = &ContainerStateTerminated{} } - if err := m.Terminated.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Terminated.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -16410,8 +18624,8 @@ func (m *ContainerState) Unmarshal(data []byte) error { } return nil } -func (m *ContainerStateRunning) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerStateRunning) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16423,7 +18637,7 @@ func (m *ContainerStateRunning) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16451,7 +18665,7 @@ func (m *ContainerStateRunning) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16465,13 +18679,13 @@ func (m *ContainerStateRunning) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.StartedAt.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.StartedAt.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -16490,8 +18704,8 @@ func (m *ContainerStateRunning) Unmarshal(data []byte) error { } return nil } -func (m *ContainerStateTerminated) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerStateTerminated) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16503,7 +18717,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16531,7 +18745,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ExitCode |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -16550,7 +18764,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Signal |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -16569,7 +18783,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16584,7 +18798,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -16598,7 +18812,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16613,7 +18827,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -16627,7 +18841,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16641,7 +18855,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.StartedAt.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.StartedAt.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -16657,7 +18871,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16671,7 +18885,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.FinishedAt.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FinishedAt.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -16687,7 +18901,7 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16702,11 +18916,11 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerID = string(data[iNdEx:postIndex]) + m.ContainerID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -16725,8 +18939,8 @@ func (m *ContainerStateTerminated) Unmarshal(data []byte) error { } return nil } -func (m *ContainerStateWaiting) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerStateWaiting) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16738,7 +18952,7 @@ func (m *ContainerStateWaiting) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16766,7 +18980,7 @@ func (m *ContainerStateWaiting) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16781,7 +18995,7 @@ func (m *ContainerStateWaiting) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -16795,7 +19009,7 @@ func (m *ContainerStateWaiting) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16810,11 +19024,11 @@ func (m *ContainerStateWaiting) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -16833,8 +19047,8 @@ func (m *ContainerStateWaiting) Unmarshal(data []byte) error { } return nil } -func (m *ContainerStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ContainerStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -16846,7 +19060,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16874,7 +19088,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -16889,7 +19103,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -16903,7 +19117,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16917,7 +19131,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.State.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.State.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -16933,7 +19147,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16947,7 +19161,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTerminationState.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTerminationState.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -16963,7 +19177,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -16983,7 +19197,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.RestartCount |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -17002,7 +19216,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17017,7 +19231,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Image = string(data[iNdEx:postIndex]) + m.Image = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -17031,7 +19245,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17046,7 +19260,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ImageID = string(data[iNdEx:postIndex]) + m.ImageID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 8: if wireType != 2 { @@ -17060,7 +19274,7 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17075,11 +19289,11 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerID = string(data[iNdEx:postIndex]) + m.ContainerID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17098,8 +19312,8 @@ func (m *ContainerStatus) Unmarshal(data []byte) error { } return nil } -func (m *DaemonEndpoint) Unmarshal(data []byte) error { - l := len(data) +func (m *DaemonEndpoint) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17111,7 +19325,7 @@ func (m *DaemonEndpoint) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17139,7 +19353,7 @@ func (m *DaemonEndpoint) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Port |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -17148,7 +19362,7 @@ func (m *DaemonEndpoint) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17167,8 +19381,8 @@ func (m *DaemonEndpoint) Unmarshal(data []byte) error { } return nil } -func (m *DeleteOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *DeleteOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17180,7 +19394,7 @@ func (m *DeleteOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17208,7 +19422,7 @@ func (m *DeleteOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -17228,7 +19442,7 @@ func (m *DeleteOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17245,7 +19459,7 @@ func (m *DeleteOptions) Unmarshal(data []byte) error { if m.Preconditions == nil { m.Preconditions = &Preconditions{} } - if err := m.Preconditions.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Preconditions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -17261,7 +19475,7 @@ func (m *DeleteOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17270,59 +19484,9 @@ func (m *DeleteOptions) Unmarshal(data []byte) error { } b := bool(v != 0) m.OrphanDependents = &b - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: DownwardAPIVolumeFile: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: DownwardAPIVolumeFile: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PropagationPolicy", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -17332,7 +19496,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17347,7 +19511,168 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + s := DeletionPropagation(dAtA[iNdEx:postIndex]) + m.PropagationPolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DownwardAPIProjection) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DownwardAPIProjection: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DownwardAPIProjection: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, DownwardAPIVolumeFile{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DownwardAPIVolumeFile) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DownwardAPIVolumeFile: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DownwardAPIVolumeFile: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -17361,7 +19686,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17378,7 +19703,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if m.FieldRef == nil { m.FieldRef = &ObjectFieldSelector{} } - if err := m.FieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FieldRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -17394,7 +19719,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17411,7 +19736,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if m.ResourceFieldRef == nil { m.ResourceFieldRef = &ResourceFieldSelector{} } - if err := m.ResourceFieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ResourceFieldRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -17427,7 +19752,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -17437,7 +19762,7 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { m.Mode = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17456,8 +19781,8 @@ func (m *DownwardAPIVolumeFile) Unmarshal(data []byte) error { } return nil } -func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *DownwardAPIVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17469,7 +19794,7 @@ func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17497,7 +19822,7 @@ func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17512,7 +19837,7 @@ func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, DownwardAPIVolumeFile{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -17528,7 +19853,7 @@ func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -17538,7 +19863,7 @@ func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { m.DefaultMode = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17557,8 +19882,8 @@ func (m *DownwardAPIVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *EmptyDirVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *EmptyDirVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17570,7 +19895,7 @@ func (m *EmptyDirVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17598,7 +19923,7 @@ func (m *EmptyDirVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17613,11 +19938,41 @@ func (m *EmptyDirVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Medium = StorageMedium(data[iNdEx:postIndex]) + m.Medium = StorageMedium(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SizeLimit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.SizeLimit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17636,8 +19991,8 @@ func (m *EmptyDirVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *EndpointAddress) Unmarshal(data []byte) error { - l := len(data) +func (m *EndpointAddress) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17649,7 +20004,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17677,7 +20032,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17692,7 +20047,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.IP = string(data[iNdEx:postIndex]) + m.IP = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -17706,7 +20061,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17723,7 +20078,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if m.TargetRef == nil { m.TargetRef = &ObjectReference{} } - if err := m.TargetRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TargetRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -17739,7 +20094,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17754,7 +20109,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Hostname = string(data[iNdEx:postIndex]) + m.Hostname = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -17768,7 +20123,7 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17783,12 +20138,12 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := string(data[iNdEx:postIndex]) + s := string(dAtA[iNdEx:postIndex]) m.NodeName = &s iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17807,8 +20162,8 @@ func (m *EndpointAddress) Unmarshal(data []byte) error { } return nil } -func (m *EndpointPort) Unmarshal(data []byte) error { - l := len(data) +func (m *EndpointPort) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17820,7 +20175,7 @@ func (m *EndpointPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17848,7 +20203,7 @@ func (m *EndpointPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17863,7 +20218,7 @@ func (m *EndpointPort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { @@ -17877,7 +20232,7 @@ func (m *EndpointPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Port |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -17896,7 +20251,7 @@ func (m *EndpointPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17911,11 +20266,11 @@ func (m *EndpointPort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Protocol = Protocol(data[iNdEx:postIndex]) + m.Protocol = Protocol(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -17934,8 +20289,8 @@ func (m *EndpointPort) Unmarshal(data []byte) error { } return nil } -func (m *EndpointSubset) Unmarshal(data []byte) error { - l := len(data) +func (m *EndpointSubset) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -17947,7 +20302,7 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -17975,7 +20330,7 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -17990,7 +20345,7 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Addresses = append(m.Addresses, EndpointAddress{}) - if err := m.Addresses[len(m.Addresses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Addresses[len(m.Addresses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18006,7 +20361,7 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18021,7 +20376,7 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.NotReadyAddresses = append(m.NotReadyAddresses, EndpointAddress{}) - if err := m.NotReadyAddresses[len(m.NotReadyAddresses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NotReadyAddresses[len(m.NotReadyAddresses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18037,7 +20392,7 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18052,13 +20407,13 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ports = append(m.Ports, EndpointPort{}) - if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -18077,8 +20432,8 @@ func (m *EndpointSubset) Unmarshal(data []byte) error { } return nil } -func (m *Endpoints) Unmarshal(data []byte) error { - l := len(data) +func (m *Endpoints) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -18090,7 +20445,7 @@ func (m *Endpoints) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18118,7 +20473,7 @@ func (m *Endpoints) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18132,7 +20487,7 @@ func (m *Endpoints) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18148,7 +20503,7 @@ func (m *Endpoints) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18163,13 +20518,13 @@ func (m *Endpoints) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Subsets = append(m.Subsets, EndpointSubset{}) - if err := m.Subsets[len(m.Subsets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Subsets[len(m.Subsets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -18188,8 +20543,8 @@ func (m *Endpoints) Unmarshal(data []byte) error { } return nil } -func (m *EndpointsList) Unmarshal(data []byte) error { - l := len(data) +func (m *EndpointsList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -18201,7 +20556,7 @@ func (m *EndpointsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18229,7 +20584,7 @@ func (m *EndpointsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18243,7 +20598,7 @@ func (m *EndpointsList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18259,7 +20614,7 @@ func (m *EndpointsList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18274,13 +20629,13 @@ func (m *EndpointsList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Endpoints{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -18299,8 +20654,8 @@ func (m *EndpointsList) Unmarshal(data []byte) error { } return nil } -func (m *EnvVar) Unmarshal(data []byte) error { - l := len(data) +func (m *EnvFromSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -18312,7 +20667,7 @@ func (m *EnvVar) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18322,15 +20677,15 @@ func (m *EnvVar) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: EnvVar: wiretype end group for non-group") + return fmt.Errorf("proto: EnvFromSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: EnvVar: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: EnvFromSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Prefix", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -18340,7 +20695,7 @@ func (m *EnvVar) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18355,13 +20710,13 @@ func (m *EnvVar) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Prefix = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConfigMapRef", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -18369,26 +20724,30 @@ func (m *EnvVar) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Value = string(data[iNdEx:postIndex]) + if m.ConfigMapRef == nil { + m.ConfigMapRef = &ConfigMapEnvSource{} + } + if err := m.ConfigMapRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ValueFrom", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -18398,7 +20757,7 @@ func (m *EnvVar) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18412,16 +20771,16 @@ func (m *EnvVar) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.ValueFrom == nil { - m.ValueFrom = &EnvVarSource{} + if m.SecretRef == nil { + m.SecretRef = &SecretEnvSource{} } - if err := m.ValueFrom.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -18440,8 +20799,8 @@ func (m *EnvVar) Unmarshal(data []byte) error { } return nil } -func (m *EnvVarSource) Unmarshal(data []byte) error { - l := len(data) +func (m *EnvVar) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -18453,7 +20812,7 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18463,17 +20822,17 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: EnvVarSource: wiretype end group for non-group") + return fmt.Errorf("proto: EnvVar: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: EnvVarSource: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: EnvVar: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field FieldRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -18481,32 +20840,28 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.FieldRef == nil { - m.FieldRef = &ObjectFieldSelector{} - } - if err := m.FieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ResourceFieldRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -18514,63 +20869,26 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.ResourceFieldRef == nil { - m.ResourceFieldRef = &ResourceFieldSelector{} - } - if err := m.ResourceFieldRef.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ConfigMapKeyRef", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.ConfigMapKeyRef == nil { - m.ConfigMapKeyRef = &ConfigMapKeySelector{} - } - if err := m.ConfigMapKeyRef.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecretKeyRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ValueFrom", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -18580,7 +20898,7 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18594,16 +20912,16 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.SecretKeyRef == nil { - m.SecretKeyRef = &SecretKeySelector{} + if m.ValueFrom == nil { + m.ValueFrom = &EnvVarSource{} } - if err := m.SecretKeyRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ValueFrom.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -18622,8 +20940,8 @@ func (m *EnvVarSource) Unmarshal(data []byte) error { } return nil } -func (m *Event) Unmarshal(data []byte) error { - l := len(data) +func (m *EnvVarSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -18635,7 +20953,189 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: EnvVarSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: EnvVarSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FieldRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.FieldRef == nil { + m.FieldRef = &ObjectFieldSelector{} + } + if err := m.FieldRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceFieldRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ResourceFieldRef == nil { + m.ResourceFieldRef = &ResourceFieldSelector{} + } + if err := m.ResourceFieldRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ConfigMapKeyRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ConfigMapKeyRef == nil { + m.ConfigMapKeyRef = &ConfigMapKeySelector{} + } + if err := m.ConfigMapKeyRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SecretKeyRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SecretKeyRef == nil { + m.SecretKeyRef = &SecretKeySelector{} + } + if err := m.SecretKeyRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Event) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18663,7 +21163,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18677,7 +21177,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18693,7 +21193,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18707,7 +21207,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.InvolvedObject.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.InvolvedObject.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18723,7 +21223,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18738,7 +21238,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -18752,7 +21252,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18767,7 +21267,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -18781,7 +21281,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18795,7 +21295,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Source.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Source.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18811,7 +21311,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18825,7 +21325,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.FirstTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FirstTimestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18841,7 +21341,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18855,7 +21355,7 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTimestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18871,7 +21371,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Count |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -18890,7 +21390,7 @@ func (m *Event) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18905,11 +21405,11 @@ func (m *Event) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = string(data[iNdEx:postIndex]) + m.Type = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -18928,8 +21428,8 @@ func (m *Event) Unmarshal(data []byte) error { } return nil } -func (m *EventList) Unmarshal(data []byte) error { - l := len(data) +func (m *EventList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -18941,7 +21441,7 @@ func (m *EventList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -18969,7 +21469,7 @@ func (m *EventList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -18983,7 +21483,7 @@ func (m *EventList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -18999,7 +21499,7 @@ func (m *EventList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -19014,13 +21514,13 @@ func (m *EventList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Event{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19039,8 +21539,8 @@ func (m *EventList) Unmarshal(data []byte) error { } return nil } -func (m *EventSource) Unmarshal(data []byte) error { - l := len(data) +func (m *EventSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -19052,7 +21552,7 @@ func (m *EventSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19080,7 +21580,7 @@ func (m *EventSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19095,7 +21595,7 @@ func (m *EventSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Component = string(data[iNdEx:postIndex]) + m.Component = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -19109,7 +21609,7 @@ func (m *EventSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19124,11 +21624,11 @@ func (m *EventSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Host = string(data[iNdEx:postIndex]) + m.Host = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19147,8 +21647,8 @@ func (m *EventSource) Unmarshal(data []byte) error { } return nil } -func (m *ExecAction) Unmarshal(data []byte) error { - l := len(data) +func (m *ExecAction) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -19160,7 +21660,7 @@ func (m *ExecAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19188,7 +21688,7 @@ func (m *ExecAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19203,11 +21703,11 @@ func (m *ExecAction) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Command = append(m.Command, string(data[iNdEx:postIndex])) + m.Command = append(m.Command, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19226,8 +21726,8 @@ func (m *ExecAction) Unmarshal(data []byte) error { } return nil } -func (m *ExportOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *FCVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -19239,7 +21739,7 @@ func (m *ExportOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19249,17 +21749,17 @@ func (m *ExportOptions) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ExportOptions: wiretype end group for non-group") + return fmt.Errorf("proto: FCVolumeSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ExportOptions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: FCVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Export", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetWWNs", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -19267,17 +21767,75 @@ func (m *ExportOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Export = bool(v != 0) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.TargetWWNs = append(m.TargetWWNs, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex case 2: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Exact", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Lun", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Lun = &v + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.FSType = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) } var v int for shift := uint(0); ; shift += 7 { @@ -19287,17 +21845,17 @@ func (m *ExportOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Exact = bool(v != 0) + m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19316,8 +21874,8 @@ func (m *ExportOptions) Unmarshal(data []byte) error { } return nil } -func (m *FCVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *FlexVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -19329,7 +21887,7 @@ func (m *FCVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19339,15 +21897,15 @@ func (m *FCVolumeSource) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: FCVolumeSource: wiretype end group for non-group") + return fmt.Errorf("proto: FlexVolumeSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: FCVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: FlexVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetWWNs", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Driver", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -19357,7 +21915,7 @@ func (m *FCVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19372,29 +21930,9 @@ func (m *FCVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.TargetWWNs = append(m.TargetWWNs, string(data[iNdEx:postIndex])) + m.Driver = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Lun", wireType) - } - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.Lun = &v - case 3: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) } @@ -19406,7 +21944,7 @@ func (m *FCVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19421,135 +21959,7 @@ func (m *FCVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.ReadOnly = bool(v != 0) - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *FlexVolumeSource) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: FlexVolumeSource: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: FlexVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Driver", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Driver = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.FSType = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -19563,7 +21973,7 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -19580,7 +21990,7 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if m.SecretRef == nil { m.SecretRef = &LocalObjectReference{} } - if err := m.SecretRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -19596,7 +22006,7 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -19616,7 +22026,7 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -19638,7 +22048,7 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19653,7 +22063,7 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19668,56 +22078,61 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.Options == nil { + m.Options = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Options == nil { - m.Options = make(map[string]string) + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Options[mapkey] = mapvalue + } else { + var mapvalue string + m.Options[mapkey] = mapvalue } - m.Options[mapkey] = mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19736,8 +22151,8 @@ func (m *FlexVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *FlockerVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *FlockerVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -19749,7 +22164,7 @@ func (m *FlockerVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19777,7 +22192,7 @@ func (m *FlockerVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19792,7 +22207,7 @@ func (m *FlockerVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DatasetName = string(data[iNdEx:postIndex]) + m.DatasetName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -19806,7 +22221,7 @@ func (m *FlockerVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19821,11 +22236,11 @@ func (m *FlockerVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DatasetUUID = string(data[iNdEx:postIndex]) + m.DatasetUUID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19844,8 +22259,8 @@ func (m *FlockerVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *GCEPersistentDiskVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -19857,7 +22272,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19885,7 +22300,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19900,7 +22315,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PDName = string(data[iNdEx:postIndex]) + m.PDName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -19914,7 +22329,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -19929,7 +22344,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -19943,7 +22358,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Partition |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -19962,7 +22377,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -19972,7 +22387,7 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -19991,8 +22406,8 @@ func (m *GCEPersistentDiskVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *GitRepoVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20004,7 +22419,7 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20032,7 +22447,7 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20047,7 +22462,7 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Repository = string(data[iNdEx:postIndex]) + m.Repository = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -20061,7 +22476,7 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20076,7 +22491,7 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Revision = string(data[iNdEx:postIndex]) + m.Revision = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -20090,7 +22505,7 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20105,11 +22520,11 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Directory = string(data[iNdEx:postIndex]) + m.Directory = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20128,8 +22543,8 @@ func (m *GitRepoVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *GlusterfsVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20141,7 +22556,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20169,7 +22584,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20184,7 +22599,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.EndpointsName = string(data[iNdEx:postIndex]) + m.EndpointsName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -20198,7 +22613,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20213,7 +22628,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -20227,7 +22642,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20237,7 +22652,7 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20256,8 +22671,8 @@ func (m *GlusterfsVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *HTTPGetAction) Unmarshal(data []byte) error { - l := len(data) +func (m *HTTPGetAction) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20269,7 +22684,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20297,7 +22712,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20312,7 +22727,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -20326,7 +22741,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20340,7 +22755,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Port.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Port.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -20356,7 +22771,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20371,7 +22786,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Host = string(data[iNdEx:postIndex]) + m.Host = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -20385,7 +22800,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20400,7 +22815,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Scheme = URIScheme(data[iNdEx:postIndex]) + m.Scheme = URIScheme(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -20414,7 +22829,7 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20429,13 +22844,13 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.HTTPHeaders = append(m.HTTPHeaders, HTTPHeader{}) - if err := m.HTTPHeaders[len(m.HTTPHeaders)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.HTTPHeaders[len(m.HTTPHeaders)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20454,8 +22869,8 @@ func (m *HTTPGetAction) Unmarshal(data []byte) error { } return nil } -func (m *HTTPHeader) Unmarshal(data []byte) error { - l := len(data) +func (m *HTTPHeader) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20467,7 +22882,7 @@ func (m *HTTPHeader) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20495,7 +22910,7 @@ func (m *HTTPHeader) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20510,7 +22925,7 @@ func (m *HTTPHeader) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -20524,7 +22939,7 @@ func (m *HTTPHeader) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20539,11 +22954,11 @@ func (m *HTTPHeader) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Value = string(data[iNdEx:postIndex]) + m.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20562,8 +22977,8 @@ func (m *HTTPHeader) Unmarshal(data []byte) error { } return nil } -func (m *Handler) Unmarshal(data []byte) error { - l := len(data) +func (m *Handler) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20575,7 +22990,7 @@ func (m *Handler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20603,7 +23018,7 @@ func (m *Handler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20620,7 +23035,7 @@ func (m *Handler) Unmarshal(data []byte) error { if m.Exec == nil { m.Exec = &ExecAction{} } - if err := m.Exec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Exec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -20636,7 +23051,7 @@ func (m *Handler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20653,7 +23068,7 @@ func (m *Handler) Unmarshal(data []byte) error { if m.HTTPGet == nil { m.HTTPGet = &HTTPGetAction{} } - if err := m.HTTPGet.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.HTTPGet.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -20669,7 +23084,7 @@ func (m *Handler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20686,13 +23101,121 @@ func (m *Handler) Unmarshal(data []byte) error { if m.TCPSocket == nil { m.TCPSocket = &TCPSocketAction{} } - if err := m.TCPSocket.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TCPSocket.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HostAlias) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HostAlias: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HostAlias: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field IP", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.IP = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Hostnames", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Hostnames = append(m.Hostnames, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20711,8 +23234,8 @@ func (m *Handler) Unmarshal(data []byte) error { } return nil } -func (m *HostPathVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *HostPathVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20724,7 +23247,7 @@ func (m *HostPathVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20752,7 +23275,7 @@ func (m *HostPathVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20767,11 +23290,11 @@ func (m *HostPathVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20790,8 +23313,8 @@ func (m *HostPathVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *ISCSIVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -20803,7 +23326,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20831,7 +23354,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20846,7 +23369,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.TargetPortal = string(data[iNdEx:postIndex]) + m.TargetPortal = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -20860,7 +23383,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20875,7 +23398,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.IQN = string(data[iNdEx:postIndex]) + m.IQN = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -20889,7 +23412,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Lun |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -20908,7 +23431,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20923,7 +23446,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ISCSIInterface = string(data[iNdEx:postIndex]) + m.ISCSIInterface = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -20937,7 +23460,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -20952,7 +23475,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 0 { @@ -20966,7 +23489,7 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -20974,9 +23497,111 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { } } m.ReadOnly = bool(v != 0) + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Portals", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Portals = append(m.Portals, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DiscoveryCHAPAuth", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.DiscoveryCHAPAuth = bool(v != 0) + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SecretRef == nil { + m.SecretRef = &LocalObjectReference{} + } + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 11: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field SessionCHAPAuth", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.SessionCHAPAuth = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -20995,8 +23620,8 @@ func (m *ISCSIVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *KeyToPath) Unmarshal(data []byte) error { - l := len(data) +func (m *KeyToPath) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -21008,7 +23633,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21036,7 +23661,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21051,7 +23676,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Key = string(data[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -21065,7 +23690,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21080,7 +23705,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -21094,7 +23719,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -21104,7 +23729,7 @@ func (m *KeyToPath) Unmarshal(data []byte) error { m.Mode = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -21123,8 +23748,8 @@ func (m *KeyToPath) Unmarshal(data []byte) error { } return nil } -func (m *Lifecycle) Unmarshal(data []byte) error { - l := len(data) +func (m *Lifecycle) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -21136,7 +23761,7 @@ func (m *Lifecycle) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21164,7 +23789,7 @@ func (m *Lifecycle) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21181,7 +23806,7 @@ func (m *Lifecycle) Unmarshal(data []byte) error { if m.PostStart == nil { m.PostStart = &Handler{} } - if err := m.PostStart.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PostStart.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -21197,7 +23822,7 @@ func (m *Lifecycle) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21214,13 +23839,13 @@ func (m *Lifecycle) Unmarshal(data []byte) error { if m.PreStop == nil { m.PreStop = &Handler{} } - if err := m.PreStop.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PreStop.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -21239,8 +23864,8 @@ func (m *Lifecycle) Unmarshal(data []byte) error { } return nil } -func (m *LimitRange) Unmarshal(data []byte) error { - l := len(data) +func (m *LimitRange) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -21252,7 +23877,7 @@ func (m *LimitRange) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21280,7 +23905,7 @@ func (m *LimitRange) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21294,7 +23919,7 @@ func (m *LimitRange) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -21310,7 +23935,7 @@ func (m *LimitRange) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21324,13 +23949,13 @@ func (m *LimitRange) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -21349,8 +23974,8 @@ func (m *LimitRange) Unmarshal(data []byte) error { } return nil } -func (m *LimitRangeItem) Unmarshal(data []byte) error { - l := len(data) +func (m *LimitRangeItem) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -21362,7 +23987,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21390,7 +24015,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21405,7 +24030,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = LimitType(data[iNdEx:postIndex]) + m.Type = LimitType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -21419,7 +24044,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21441,7 +24066,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21456,7 +24081,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21471,9 +24096,68 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 + if m.Max == nil { + m.Max = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Max[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Max[ResourceName(mapkey)] = mapvalue + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -21481,14 +24165,21 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - var mapmsglen int + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -21496,36 +24187,217 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if mapmsglen < 0 { + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthGenerated } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Min == nil { + m.Min = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Min[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Min[ResourceName(mapkey)] = mapvalue + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Default", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { return ErrInvalidLengthGenerated } - if postmsgIndex > l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx = postmsgIndex - if m.Max == nil { - m.Max = make(ResourceList) + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Default == nil { + m.Default = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Default[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Default[ResourceName(mapkey)] = mapvalue } - m.Max[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex - case 3: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DefaultRequest", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -21535,7 +24407,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21557,7 +24429,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21572,7 +24444,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21587,289 +24459,62 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Min == nil { - m.Min = make(ResourceList) - } - m.Min[ResourceName(mapkey)] = *mapvalue - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Default", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Default == nil { - m.Default = make(ResourceList) - } - m.Default[ResourceName(mapkey)] = *mapvalue - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DefaultRequest", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF + if m.DefaultRequest == nil { + m.DefaultRequest = make(ResourceList) } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.DefaultRequest[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.DefaultRequest[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.DefaultRequest == nil { - m.DefaultRequest = make(ResourceList) - } - m.DefaultRequest[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex case 6: if wireType != 2 { @@ -21883,7 +24528,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -21905,7 +24550,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21920,7 +24565,7 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -21935,61 +24580,66 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.MaxLimitRequestRatio == nil { + m.MaxLimitRequestRatio = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.MaxLimitRequestRatio[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.MaxLimitRequestRatio[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.MaxLimitRequestRatio == nil { - m.MaxLimitRequestRatio = make(ResourceList) - } - m.MaxLimitRequestRatio[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22008,8 +24658,8 @@ func (m *LimitRangeItem) Unmarshal(data []byte) error { } return nil } -func (m *LimitRangeList) Unmarshal(data []byte) error { - l := len(data) +func (m *LimitRangeList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22021,7 +24671,7 @@ func (m *LimitRangeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22049,7 +24699,7 @@ func (m *LimitRangeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22063,7 +24713,7 @@ func (m *LimitRangeList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -22079,7 +24729,7 @@ func (m *LimitRangeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22094,13 +24744,13 @@ func (m *LimitRangeList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, LimitRange{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22119,8 +24769,8 @@ func (m *LimitRangeList) Unmarshal(data []byte) error { } return nil } -func (m *LimitRangeSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *LimitRangeSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22132,7 +24782,7 @@ func (m *LimitRangeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22160,7 +24810,7 @@ func (m *LimitRangeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22175,13 +24825,13 @@ func (m *LimitRangeSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Limits = append(m.Limits, LimitRangeItem{}) - if err := m.Limits[len(m.Limits)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Limits[len(m.Limits)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22200,8 +24850,8 @@ func (m *LimitRangeSpec) Unmarshal(data []byte) error { } return nil } -func (m *List) Unmarshal(data []byte) error { - l := len(data) +func (m *List) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22213,7 +24863,7 @@ func (m *List) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22241,7 +24891,7 @@ func (m *List) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22255,7 +24905,7 @@ func (m *List) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -22271,7 +24921,7 @@ func (m *List) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22285,14 +24935,14 @@ func (m *List) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, k8s_io_kubernetes_pkg_runtime.RawExtension{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, k8s_io_apimachinery_pkg_runtime.RawExtension{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22311,8 +24961,8 @@ func (m *List) Unmarshal(data []byte) error { } return nil } -func (m *ListOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *ListOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22324,7 +24974,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22352,7 +25002,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22367,7 +25017,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.LabelSelector = string(data[iNdEx:postIndex]) + m.LabelSelector = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -22381,7 +25031,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22396,7 +25046,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FieldSelector = string(data[iNdEx:postIndex]) + m.FieldSelector = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -22410,7 +25060,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22430,7 +25080,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22445,7 +25095,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ResourceVersion = string(data[iNdEx:postIndex]) + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 0 { @@ -22459,7 +25109,7 @@ func (m *ListOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -22467,9 +25117,29 @@ func (m *ListOptions) Unmarshal(data []byte) error { } } m.TimeoutSeconds = &v + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field IncludeUninitialized", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.IncludeUninitialized = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22488,8 +25158,8 @@ func (m *ListOptions) Unmarshal(data []byte) error { } return nil } -func (m *LoadBalancerIngress) Unmarshal(data []byte) error { - l := len(data) +func (m *LoadBalancerIngress) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22501,7 +25171,7 @@ func (m *LoadBalancerIngress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22529,7 +25199,7 @@ func (m *LoadBalancerIngress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22544,7 +25214,7 @@ func (m *LoadBalancerIngress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.IP = string(data[iNdEx:postIndex]) + m.IP = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -22558,7 +25228,7 @@ func (m *LoadBalancerIngress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22573,11 +25243,11 @@ func (m *LoadBalancerIngress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Hostname = string(data[iNdEx:postIndex]) + m.Hostname = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22596,8 +25266,8 @@ func (m *LoadBalancerIngress) Unmarshal(data []byte) error { } return nil } -func (m *LoadBalancerStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *LoadBalancerStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22609,7 +25279,7 @@ func (m *LoadBalancerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22637,7 +25307,7 @@ func (m *LoadBalancerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22652,13 +25322,13 @@ func (m *LoadBalancerStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ingress = append(m.Ingress, LoadBalancerIngress{}) - if err := m.Ingress[len(m.Ingress)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ingress[len(m.Ingress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22677,8 +25347,8 @@ func (m *LoadBalancerStatus) Unmarshal(data []byte) error { } return nil } -func (m *LocalObjectReference) Unmarshal(data []byte) error { - l := len(data) +func (m *LocalObjectReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22690,7 +25360,7 @@ func (m *LocalObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22718,7 +25388,7 @@ func (m *LocalObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22733,11 +25403,11 @@ func (m *LocalObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22756,8 +25426,8 @@ func (m *LocalObjectReference) Unmarshal(data []byte) error { } return nil } -func (m *NFSVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *LocalVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22769,7 +25439,86 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LocalVolumeSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LocalVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Path = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NFSVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22797,7 +25546,7 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22812,7 +25561,7 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Server = string(data[iNdEx:postIndex]) + m.Server = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -22826,7 +25575,7 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22841,7 +25590,7 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -22855,7 +25604,7 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22865,7 +25614,7 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -22884,8 +25633,8 @@ func (m *NFSVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *Namespace) Unmarshal(data []byte) error { - l := len(data) +func (m *Namespace) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -22897,7 +25646,7 @@ func (m *Namespace) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -22925,7 +25674,7 @@ func (m *Namespace) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22939,7 +25688,7 @@ func (m *Namespace) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -22955,7 +25704,7 @@ func (m *Namespace) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22969,7 +25718,7 @@ func (m *Namespace) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -22985,7 +25734,7 @@ func (m *Namespace) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -22999,13 +25748,13 @@ func (m *Namespace) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23024,8 +25773,8 @@ func (m *Namespace) Unmarshal(data []byte) error { } return nil } -func (m *NamespaceList) Unmarshal(data []byte) error { - l := len(data) +func (m *NamespaceList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23037,7 +25786,7 @@ func (m *NamespaceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23065,7 +25814,7 @@ func (m *NamespaceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23079,7 +25828,7 @@ func (m *NamespaceList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -23095,7 +25844,7 @@ func (m *NamespaceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23110,13 +25859,13 @@ func (m *NamespaceList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Namespace{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23135,8 +25884,8 @@ func (m *NamespaceList) Unmarshal(data []byte) error { } return nil } -func (m *NamespaceSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *NamespaceSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23148,7 +25897,7 @@ func (m *NamespaceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23176,7 +25925,7 @@ func (m *NamespaceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23191,11 +25940,11 @@ func (m *NamespaceSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Finalizers = append(m.Finalizers, FinalizerName(data[iNdEx:postIndex])) + m.Finalizers = append(m.Finalizers, FinalizerName(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23214,8 +25963,8 @@ func (m *NamespaceSpec) Unmarshal(data []byte) error { } return nil } -func (m *NamespaceStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *NamespaceStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23227,7 +25976,7 @@ func (m *NamespaceStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23255,7 +26004,7 @@ func (m *NamespaceStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23270,11 +26019,11 @@ func (m *NamespaceStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Phase = NamespacePhase(data[iNdEx:postIndex]) + m.Phase = NamespacePhase(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23293,8 +26042,8 @@ func (m *NamespaceStatus) Unmarshal(data []byte) error { } return nil } -func (m *Node) Unmarshal(data []byte) error { - l := len(data) +func (m *Node) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23306,7 +26055,7 @@ func (m *Node) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23334,7 +26083,7 @@ func (m *Node) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23348,7 +26097,7 @@ func (m *Node) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -23364,7 +26113,7 @@ func (m *Node) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23378,7 +26127,7 @@ func (m *Node) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -23394,7 +26143,7 @@ func (m *Node) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23408,13 +26157,13 @@ func (m *Node) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23433,8 +26182,8 @@ func (m *Node) Unmarshal(data []byte) error { } return nil } -func (m *NodeAddress) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeAddress) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23446,7 +26195,7 @@ func (m *NodeAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23474,7 +26223,7 @@ func (m *NodeAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23489,7 +26238,7 @@ func (m *NodeAddress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = NodeAddressType(data[iNdEx:postIndex]) + m.Type = NodeAddressType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -23503,7 +26252,7 @@ func (m *NodeAddress) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23518,11 +26267,11 @@ func (m *NodeAddress) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Address = string(data[iNdEx:postIndex]) + m.Address = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23541,8 +26290,8 @@ func (m *NodeAddress) Unmarshal(data []byte) error { } return nil } -func (m *NodeAffinity) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeAffinity) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23554,7 +26303,7 @@ func (m *NodeAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23582,7 +26331,7 @@ func (m *NodeAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23599,7 +26348,7 @@ func (m *NodeAffinity) Unmarshal(data []byte) error { if m.RequiredDuringSchedulingIgnoredDuringExecution == nil { m.RequiredDuringSchedulingIgnoredDuringExecution = &NodeSelector{} } - if err := m.RequiredDuringSchedulingIgnoredDuringExecution.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RequiredDuringSchedulingIgnoredDuringExecution.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -23615,7 +26364,7 @@ func (m *NodeAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23630,13 +26379,13 @@ func (m *NodeAffinity) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, PreferredSchedulingTerm{}) - if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23655,8 +26404,8 @@ func (m *NodeAffinity) Unmarshal(data []byte) error { } return nil } -func (m *NodeCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23668,7 +26417,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23696,7 +26445,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23711,7 +26460,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = NodeConditionType(data[iNdEx:postIndex]) + m.Type = NodeConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -23725,7 +26474,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23740,7 +26489,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Status = ConditionStatus(data[iNdEx:postIndex]) + m.Status = ConditionStatus(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -23754,7 +26503,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23768,7 +26517,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastHeartbeatTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastHeartbeatTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -23784,7 +26533,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23798,7 +26547,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -23814,7 +26563,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23829,7 +26578,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -23843,7 +26592,7 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23858,11 +26607,11 @@ func (m *NodeCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23881,8 +26630,8 @@ func (m *NodeCondition) Unmarshal(data []byte) error { } return nil } -func (m *NodeDaemonEndpoints) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeDaemonEndpoints) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23894,7 +26643,7 @@ func (m *NodeDaemonEndpoints) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -23922,7 +26671,7 @@ func (m *NodeDaemonEndpoints) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -23936,13 +26685,13 @@ func (m *NodeDaemonEndpoints) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.KubeletEndpoint.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.KubeletEndpoint.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -23961,8 +26710,8 @@ func (m *NodeDaemonEndpoints) Unmarshal(data []byte) error { } return nil } -func (m *NodeList) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -23974,7 +26723,7 @@ func (m *NodeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24002,7 +26751,7 @@ func (m *NodeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24016,7 +26765,7 @@ func (m *NodeList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -24032,7 +26781,7 @@ func (m *NodeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24047,13 +26796,13 @@ func (m *NodeList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Node{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -24072,8 +26821,8 @@ func (m *NodeList) Unmarshal(data []byte) error { } return nil } -func (m *NodeProxyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeProxyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -24085,7 +26834,7 @@ func (m *NodeProxyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24113,7 +26862,7 @@ func (m *NodeProxyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24128,11 +26877,11 @@ func (m *NodeProxyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -24151,8 +26900,8 @@ func (m *NodeProxyOptions) Unmarshal(data []byte) error { } return nil } -func (m *NodeSelector) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeResources) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -24164,7 +26913,7 @@ func (m *NodeSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24174,15 +26923,15 @@ func (m *NodeSelector) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: NodeSelector: wiretype end group for non-group") + return fmt.Errorf("proto: NodeResources: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: NodeSelector: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: NodeResources: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field NodeSelectorTerms", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -24192,7 +26941,7 @@ func (m *NodeSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24206,66 +26955,7 @@ func (m *NodeSelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.NodeSelectorTerms = append(m.NodeSelectorTerms, NodeSelectorTerm{}) - if err := m.NodeSelectorTerms[len(m.NodeSelectorTerms)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *NodeSelectorRequirement) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: NodeSelectorRequirement: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: NodeSelectorRequirement: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) - } - var stringLen uint64 + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24273,28 +26963,14 @@ func (m *NodeSelectorRequirement) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Key = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Operator", wireType) - } - var stringLen uint64 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24302,136 +26978,81 @@ func (m *NodeSelectorRequirement) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen - if postIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - m.Operator = NodeSelectorOperator(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Values", wireType) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Capacity == nil { + m.Capacity = make(ResourceList) } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Values = append(m.Values, string(data[iNdEx:postIndex])) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *NodeSelectorTerm) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: NodeSelectorTerm: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: NodeSelectorTerm: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MatchExpressions", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.MatchExpressions = append(m.MatchExpressions, NodeSelectorRequirement{}) - if err := m.MatchExpressions[len(m.MatchExpressions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + iNdEx = postmsgIndex + m.Capacity[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Capacity[ResourceName(mapkey)] = mapvalue } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -24450,8 +27071,8 @@ func (m *NodeSelectorTerm) Unmarshal(data []byte) error { } return nil } -func (m *NodeSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeSelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -24463,7 +27084,7 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24473,15 +27094,96 @@ func (m *NodeSpec) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: NodeSpec: wiretype end group for non-group") + return fmt.Errorf("proto: NodeSelector: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: NodeSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: NodeSelector: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodCIDR", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field NodeSelectorTerms", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.NodeSelectorTerms = append(m.NodeSelectorTerms, NodeSelectorTerm{}) + if err := m.NodeSelectorTerms[len(m.NodeSelectorTerms)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NodeSelectorRequirement) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NodeSelectorRequirement: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NodeSelectorRequirement: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -24491,7 +27193,7 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24506,11 +27208,11 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PodCIDR = string(data[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ExternalID", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Operator", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -24520,7 +27222,7 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24535,11 +27237,11 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ExternalID = string(data[iNdEx:postIndex]) + m.Operator = NodeSelectorOperator(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ProviderID", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Values", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -24549,7 +27251,7 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24564,13 +27266,63 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ProviderID = string(data[iNdEx:postIndex]) + m.Values = append(m.Values, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Unschedulable", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - var v int + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NodeSelectorTerm) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NodeSelectorTerm: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NodeSelectorTerm: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MatchExpressions", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24578,17 +27330,28 @@ func (m *NodeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Unschedulable = bool(v != 0) + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MatchExpressions = append(m.MatchExpressions, NodeSelectorRequirement{}) + if err := m.MatchExpressions[len(m.MatchExpressions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -24607,8 +27370,8 @@ func (m *NodeSpec) Unmarshal(data []byte) error { } return nil } -func (m *NodeStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -24620,7 +27383,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24630,17 +27393,17 @@ func (m *NodeStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: NodeStatus: wiretype end group for non-group") + return fmt.Errorf("proto: NodeSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: NodeStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: NodeSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodCIDR", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24648,21 +27411,28 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 + m.PodCIDR = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExternalID", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24670,14 +27440,28 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapkey uint64 + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExternalID = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProviderID", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24685,24 +27469,28 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - var valuekey uint64 + m.ProviderID = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Unschedulable", wireType) + } + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24710,14 +27498,19 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - var mapmsglen int + m.Unschedulable = bool(v != 0) + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Taints", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24725,36 +27518,78 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - if mapmsglen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Taints = append(m.Taints, Taint{}) + if err := m.Taints[len(m.Taints)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthGenerated } - if postmsgIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NodeStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated } - iNdEx = postmsgIndex - if m.Capacity == nil { - m.Capacity = make(ResourceList) + if iNdEx >= l { + return io.ErrUnexpectedEOF } - m.Capacity[ResourceName(mapkey)] = *mapvalue - iNdEx = postIndex - case 2: + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NodeStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NodeStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Allocatable", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -24764,7 +27599,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24786,7 +27621,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24801,7 +27636,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24816,9 +27651,68 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 + if m.Capacity == nil { + m.Capacity = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Capacity[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Capacity[ResourceName(mapkey)] = mapvalue + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Allocatable", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24826,14 +27720,21 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - var mapmsglen int + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -24841,32 +27742,92 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthGenerated } - if postmsgIndex > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey if m.Allocatable == nil { m.Allocatable = make(ResourceList) } - m.Allocatable[ResourceName(mapkey)] = *mapvalue + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Allocatable[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Allocatable[ResourceName(mapkey)] = mapvalue + } iNdEx = postIndex case 3: if wireType != 2 { @@ -24880,7 +27841,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -24895,7 +27856,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Phase = NodePhase(data[iNdEx:postIndex]) + m.Phase = NodePhase(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -24909,7 +27870,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24924,7 +27885,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, NodeCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -24940,7 +27901,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24955,7 +27916,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Addresses = append(m.Addresses, NodeAddress{}) - if err := m.Addresses[len(m.Addresses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Addresses[len(m.Addresses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -24971,7 +27932,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -24985,7 +27946,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.DaemonEndpoints.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.DaemonEndpoints.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -25001,7 +27962,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -25015,7 +27976,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.NodeInfo.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NodeInfo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -25031,7 +27992,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -25046,7 +28007,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Images = append(m.Images, ContainerImage{}) - if err := m.Images[len(m.Images)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Images[len(m.Images)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -25062,7 +28023,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25077,7 +28038,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.VolumesInUse = append(m.VolumesInUse, UniqueVolumeName(data[iNdEx:postIndex])) + m.VolumesInUse = append(m.VolumesInUse, UniqueVolumeName(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 10: if wireType != 2 { @@ -25091,7 +28052,7 @@ func (m *NodeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -25106,13 +28067,13 @@ func (m *NodeStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.VolumesAttached = append(m.VolumesAttached, AttachedVolume{}) - if err := m.VolumesAttached[len(m.VolumesAttached)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.VolumesAttached[len(m.VolumesAttached)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -25131,8 +28092,8 @@ func (m *NodeStatus) Unmarshal(data []byte) error { } return nil } -func (m *NodeSystemInfo) Unmarshal(data []byte) error { - l := len(data) +func (m *NodeSystemInfo) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -25144,7 +28105,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25172,7 +28133,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25187,7 +28148,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.MachineID = string(data[iNdEx:postIndex]) + m.MachineID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -25201,7 +28162,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25216,7 +28177,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.SystemUUID = string(data[iNdEx:postIndex]) + m.SystemUUID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -25230,7 +28191,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25245,7 +28206,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.BootID = string(data[iNdEx:postIndex]) + m.BootID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -25259,7 +28220,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25274,7 +28235,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.KernelVersion = string(data[iNdEx:postIndex]) + m.KernelVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -25288,7 +28249,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25303,7 +28264,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.OSImage = string(data[iNdEx:postIndex]) + m.OSImage = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -25317,7 +28278,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25332,7 +28293,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerRuntimeVersion = string(data[iNdEx:postIndex]) + m.ContainerRuntimeVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -25346,7 +28307,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25361,7 +28322,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.KubeletVersion = string(data[iNdEx:postIndex]) + m.KubeletVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 8: if wireType != 2 { @@ -25375,7 +28336,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25390,7 +28351,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.KubeProxyVersion = string(data[iNdEx:postIndex]) + m.KubeProxyVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 9: if wireType != 2 { @@ -25404,7 +28365,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25419,7 +28380,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.OperatingSystem = string(data[iNdEx:postIndex]) + m.OperatingSystem = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 10: if wireType != 2 { @@ -25433,7 +28394,7 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25448,11 +28409,11 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Architecture = string(data[iNdEx:postIndex]) + m.Architecture = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -25471,8 +28432,8 @@ func (m *NodeSystemInfo) Unmarshal(data []byte) error { } return nil } -func (m *ObjectFieldSelector) Unmarshal(data []byte) error { - l := len(data) +func (m *ObjectFieldSelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -25484,7 +28445,7 @@ func (m *ObjectFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25512,7 +28473,7 @@ func (m *ObjectFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25527,7 +28488,7 @@ func (m *ObjectFieldSelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.APIVersion = string(data[iNdEx:postIndex]) + m.APIVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -25541,7 +28502,7 @@ func (m *ObjectFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25556,11 +28517,11 @@ func (m *ObjectFieldSelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FieldPath = string(data[iNdEx:postIndex]) + m.FieldPath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -25579,8 +28540,8 @@ func (m *ObjectFieldSelector) Unmarshal(data []byte) error { } return nil } -func (m *ObjectMeta) Unmarshal(data []byte) error { - l := len(data) +func (m *ObjectMeta) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -25592,7 +28553,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25620,7 +28581,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25635,7 +28596,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -25649,7 +28610,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25664,7 +28625,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.GenerateName = string(data[iNdEx:postIndex]) + m.GenerateName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -25678,7 +28639,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25693,7 +28654,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Namespace = string(data[iNdEx:postIndex]) + m.Namespace = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -25707,7 +28668,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25722,7 +28683,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.SelfLink = string(data[iNdEx:postIndex]) + m.SelfLink = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -25736,7 +28697,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25751,7 +28712,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.UID = k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex]) + m.UID = k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -25765,7 +28726,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25780,7 +28741,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ResourceVersion = string(data[iNdEx:postIndex]) + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 0 { @@ -25794,7 +28755,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Generation |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -25813,7 +28774,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -25827,7 +28788,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.CreationTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.CreationTimestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -25843,7 +28804,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -25858,9 +28819,9 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.DeletionTimestamp == nil { - m.DeletionTimestamp = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + m.DeletionTimestamp = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} } - if err := m.DeletionTimestamp.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.DeletionTimestamp.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -25876,7 +28837,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -25896,7 +28857,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -25918,7 +28879,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25933,7 +28894,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -25948,52 +28909,57 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.Labels == nil { + m.Labels = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Labels[mapkey] = mapvalue + } else { + var mapvalue string + m.Labels[mapkey] = mapvalue } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Labels == nil { - m.Labels = make(map[string]string) - } - m.Labels[mapkey] = mapvalue iNdEx = postIndex case 12: if wireType != 2 { @@ -26007,7 +28973,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26029,7 +28995,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26044,7 +29010,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26059,52 +29025,57 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.Annotations == nil { + m.Annotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Annotations[mapkey] = mapvalue + } else { + var mapvalue string + m.Annotations[mapkey] = mapvalue } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Annotations == nil { - m.Annotations = make(map[string]string) - } - m.Annotations[mapkey] = mapvalue iNdEx = postIndex case 13: if wireType != 2 { @@ -26118,7 +29089,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26132,8 +29103,8 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.OwnerReferences = append(m.OwnerReferences, OwnerReference{}) - if err := m.OwnerReferences[len(m.OwnerReferences)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + m.OwnerReferences = append(m.OwnerReferences, k8s_io_apimachinery_pkg_apis_meta_v1.OwnerReference{}) + if err := m.OwnerReferences[len(m.OwnerReferences)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -26149,7 +29120,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26164,7 +29135,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Finalizers = append(m.Finalizers, string(data[iNdEx:postIndex])) + m.Finalizers = append(m.Finalizers, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 15: if wireType != 2 { @@ -26178,7 +29149,7 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26193,11 +29164,44 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ClusterName = string(data[iNdEx:postIndex]) + m.ClusterName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 16: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Initializers", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Initializers == nil { + m.Initializers = &k8s_io_apimachinery_pkg_apis_meta_v1.Initializers{} + } + if err := m.Initializers.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -26216,8 +29220,8 @@ func (m *ObjectMeta) Unmarshal(data []byte) error { } return nil } -func (m *ObjectReference) Unmarshal(data []byte) error { - l := len(data) +func (m *ObjectReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -26229,7 +29233,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26257,7 +29261,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26272,7 +29276,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = string(data[iNdEx:postIndex]) + m.Kind = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -26286,7 +29290,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26301,7 +29305,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Namespace = string(data[iNdEx:postIndex]) + m.Namespace = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -26315,7 +29319,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26330,7 +29334,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -26344,7 +29348,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26359,7 +29363,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.UID = k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex]) + m.UID = k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -26373,7 +29377,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26388,7 +29392,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.APIVersion = string(data[iNdEx:postIndex]) + m.APIVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -26402,7 +29406,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26417,7 +29421,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ResourceVersion = string(data[iNdEx:postIndex]) + m.ResourceVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -26431,7 +29435,7 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26446,11 +29450,11 @@ func (m *ObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FieldPath = string(data[iNdEx:postIndex]) + m.FieldPath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -26469,8 +29473,8 @@ func (m *ObjectReference) Unmarshal(data []byte) error { } return nil } -func (m *OwnerReference) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolume) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -26482,7 +29486,7 @@ func (m *OwnerReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26492,17 +29496,17 @@ func (m *OwnerReference) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: OwnerReference: wiretype end group for non-group") + return fmt.Errorf("proto: PersistentVolume: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: OwnerReference: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PersistentVolume: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -26510,57 +29514,29 @@ func (m *OwnerReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.Name = string(data[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -26568,28 +29544,29 @@ func (m *OwnerReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.UID = k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex]) + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 5: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -26597,47 +29574,27 @@ func (m *OwnerReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.APIVersion = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Controller", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - b := bool(v != 0) - m.Controller = &b + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -26656,8 +29613,8 @@ func (m *OwnerReference) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolume) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeClaim) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -26669,7 +29626,7 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26679,10 +29636,10 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PersistentVolume: wiretype end group for non-group") + return fmt.Errorf("proto: PersistentVolumeClaim: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PersistentVolume: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PersistentVolumeClaim: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -26697,7 +29654,7 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26711,7 +29668,7 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -26727,7 +29684,7 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26741,7 +29698,7 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -26757,7 +29714,7 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26771,13 +29728,13 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -26796,8 +29753,8 @@ func (m *PersistentVolume) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeClaimList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -26809,7 +29766,7 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26819,15 +29776,15 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PersistentVolumeClaim: wiretype end group for non-group") + return fmt.Errorf("proto: PersistentVolumeClaimList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PersistentVolumeClaim: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PersistentVolumeClaimList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -26837,7 +29794,7 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26851,43 +29808,13 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -26897,7 +29824,7 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -26911,13 +29838,14 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, PersistentVolumeClaim{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -26936,8 +29864,8 @@ func (m *PersistentVolumeClaim) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeClaimSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -26949,7 +29877,7 @@ func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -26959,17 +29887,17 @@ func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PersistentVolumeClaimList: wiretype end group for non-group") + return fmt.Errorf("proto: PersistentVolumeClaimSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PersistentVolumeClaimList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PersistentVolumeClaimSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -26977,27 +29905,26 @@ func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -27007,7 +29934,7 @@ func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27021,64 +29948,13 @@ func (m *PersistentVolumeClaimList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, PersistentVolumeClaim{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Resources.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: PersistentVolumeClaimSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PersistentVolumeClaimSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field VolumeName", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -27088,7 +29964,7 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27103,11 +29979,11 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(data[iNdEx:postIndex])) + m.VolumeName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -27117,7 +29993,7 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27131,13 +30007,16 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Resources.Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.Selector == nil { + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field VolumeName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field StorageClassName", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -27147,7 +30026,7 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27162,44 +30041,12 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.VolumeName = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} - } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + s := string(dAtA[iNdEx:postIndex]) + m.StorageClassName = &s iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -27218,8 +30065,8 @@ func (m *PersistentVolumeClaimSpec) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeClaimStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -27231,7 +30078,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27259,7 +30106,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27274,7 +30121,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Phase = PersistentVolumeClaimPhase(data[iNdEx:postIndex]) + m.Phase = PersistentVolumeClaimPhase(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -27288,7 +30135,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27303,7 +30150,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(data[iNdEx:postIndex])) + m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 3: if wireType != 2 { @@ -27317,7 +30164,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27339,7 +30186,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27354,7 +30201,7 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27369,61 +30216,66 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Capacity == nil { + m.Capacity = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Capacity[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Capacity[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Capacity == nil { - m.Capacity = make(ResourceList) - } - m.Capacity[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -27442,8 +30294,8 @@ func (m *PersistentVolumeClaimStatus) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeClaimVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -27455,7 +30307,7 @@ func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27483,7 +30335,7 @@ func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27498,7 +30350,7 @@ func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ClaimName = string(data[iNdEx:postIndex]) + m.ClaimName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { @@ -27512,7 +30364,7 @@ func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27522,7 +30374,7 @@ func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -27541,8 +30393,8 @@ func (m *PersistentVolumeClaimVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeList) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -27554,7 +30406,7 @@ func (m *PersistentVolumeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27582,7 +30434,7 @@ func (m *PersistentVolumeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27596,7 +30448,7 @@ func (m *PersistentVolumeList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27612,7 +30464,7 @@ func (m *PersistentVolumeList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27627,13 +30479,13 @@ func (m *PersistentVolumeList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, PersistentVolume{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -27652,8 +30504,8 @@ func (m *PersistentVolumeList) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -27665,7 +30517,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -27693,7 +30545,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27710,7 +30562,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.GCEPersistentDisk == nil { m.GCEPersistentDisk = &GCEPersistentDiskVolumeSource{} } - if err := m.GCEPersistentDisk.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.GCEPersistentDisk.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27726,7 +30578,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27743,7 +30595,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.AWSElasticBlockStore == nil { m.AWSElasticBlockStore = &AWSElasticBlockStoreVolumeSource{} } - if err := m.AWSElasticBlockStore.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.AWSElasticBlockStore.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27759,7 +30611,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27776,7 +30628,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.HostPath == nil { m.HostPath = &HostPathVolumeSource{} } - if err := m.HostPath.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.HostPath.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27792,7 +30644,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27809,7 +30661,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.Glusterfs == nil { m.Glusterfs = &GlusterfsVolumeSource{} } - if err := m.Glusterfs.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Glusterfs.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27825,7 +30677,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27842,7 +30694,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.NFS == nil { m.NFS = &NFSVolumeSource{} } - if err := m.NFS.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NFS.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27858,7 +30710,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27875,7 +30727,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.RBD == nil { m.RBD = &RBDVolumeSource{} } - if err := m.RBD.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RBD.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27891,7 +30743,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27908,7 +30760,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.ISCSI == nil { m.ISCSI = &ISCSIVolumeSource{} } - if err := m.ISCSI.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ISCSI.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27924,7 +30776,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27941,7 +30793,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.Cinder == nil { m.Cinder = &CinderVolumeSource{} } - if err := m.Cinder.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Cinder.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27957,7 +30809,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -27974,7 +30826,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.CephFS == nil { m.CephFS = &CephFSVolumeSource{} } - if err := m.CephFS.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.CephFS.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -27990,7 +30842,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28007,7 +30859,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.FC == nil { m.FC = &FCVolumeSource{} } - if err := m.FC.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FC.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28023,7 +30875,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28040,7 +30892,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.Flocker == nil { m.Flocker = &FlockerVolumeSource{} } - if err := m.Flocker.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Flocker.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28056,7 +30908,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28073,7 +30925,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.FlexVolume == nil { m.FlexVolume = &FlexVolumeSource{} } - if err := m.FlexVolume.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FlexVolume.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28089,7 +30941,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28106,7 +30958,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.AzureFile == nil { m.AzureFile = &AzureFileVolumeSource{} } - if err := m.AzureFile.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.AzureFile.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28122,7 +30974,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28139,7 +30991,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.VsphereVolume == nil { m.VsphereVolume = &VsphereVirtualDiskVolumeSource{} } - if err := m.VsphereVolume.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.VsphereVolume.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28155,7 +31007,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28172,7 +31024,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.Quobyte == nil { m.Quobyte = &QuobyteVolumeSource{} } - if err := m.Quobyte.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Quobyte.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28188,7 +31040,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28205,7 +31057,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.AzureDisk == nil { m.AzureDisk = &AzureDiskVolumeSource{} } - if err := m.AzureDisk.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.AzureDisk.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -28221,7 +31073,7 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28238,63 +31090,13 @@ func (m *PersistentVolumeSource) Unmarshal(data []byte) error { if m.PhotonPersistentDisk == nil { m.PhotonPersistentDisk = &PhotonPersistentDiskVolumeSource{} } - if err := m.PhotonPersistentDisk.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PhotonPersistentDisk.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: PersistentVolumeSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PersistentVolumeSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 18: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PortworxVolume", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -28304,7 +31106,7 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28318,99 +31120,16 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapkey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { - return io.ErrUnexpectedEOF - } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated + if m.PortworxVolume == nil { + m.PortworxVolume = &PortworxVolumeSource{} } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { + if err := m.PortworxVolume.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } - iNdEx = postmsgIndex - if m.Capacity == nil { - m.Capacity = make(ResourceList) - } - m.Capacity[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex - case 2: + case 19: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeSource", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ScaleIO", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -28420,7 +31139,7 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28434,42 +31153,16 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.PersistentVolumeSource.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType) + if m.ScaleIO == nil { + m.ScaleIO = &ScaleIOVolumeSource{} } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF + if err := m.ScaleIO.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(data[iNdEx:postIndex])) iNdEx = postIndex - case 4: + case 20: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClaimRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Local", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -28479,7 +31172,7 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -28493,18 +31186,18 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.ClaimRef == nil { - m.ClaimRef = &ObjectReference{} + if m.Local == nil { + m.Local = &LocalVolumeSource{} } - if err := m.ClaimRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Local.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 5: + case 21: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeReclaimPolicy", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field StorageOS", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28512,26 +31205,30 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(data[iNdEx:postIndex]) + if m.StorageOS == nil { + m.StorageOS = &StorageOSPersistentVolumeSource{} + } + if err := m.StorageOS.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -28550,8 +31247,8 @@ func (m *PersistentVolumeSpec) Unmarshal(data []byte) error { } return nil } -func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -28563,7 +31260,7 @@ func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -28573,17 +31270,17 @@ func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PersistentVolumeStatus: wiretype end group for non-group") + return fmt.Errorf("proto: PersistentVolumeSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PersistentVolumeStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PersistentVolumeSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Capacity", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28591,28 +31288,120 @@ func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Phase = PersistentVolumePhase(data[iNdEx:postIndex]) + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Capacity == nil { + m.Capacity = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Capacity[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Capacity[ResourceName(mapkey)] = mapvalue + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeSource", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28620,26 +31409,27 @@ func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + if err := m.PersistentVolumeSource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field AccessModes", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -28649,7 +31439,7 @@ func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -28664,61 +31454,44 @@ func (m *PersistentVolumeStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.AccessModes = append(m.AccessModes, PersistentVolumeAccessMode(dAtA[iNdEx:postIndex])) iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClaimRef", wireType) } - if skippy < 0 { + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { return ErrInvalidLengthGenerated } - if (iNdEx + skippy) > l { + postIndex := iNdEx + msglen + if postIndex > l { return io.ErrUnexpectedEOF } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *PhotonPersistentDiskVolumeSource) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.ClaimRef == nil { + m.ClaimRef = &ObjectReference{} } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if err := m.ClaimRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: PhotonPersistentDiskVolumeSource: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PhotonPersistentDiskVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + iNdEx = postIndex + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PdID", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PersistentVolumeReclaimPolicy", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -28728,7 +31501,7 @@ func (m *PhotonPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -28743,11 +31516,11 @@ func (m *PhotonPersistentDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PdID = string(data[iNdEx:postIndex]) + m.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field StorageClassName", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -28757,7 +31530,7 @@ func (m *PhotonPersistentDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -28772,11 +31545,11 @@ func (m *PhotonPersistentDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.StorageClassName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -28795,8 +31568,8 @@ func (m *PhotonPersistentDiskVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *Pod) Unmarshal(data []byte) error { - l := len(data) +func (m *PersistentVolumeStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -28808,7 +31581,7 @@ func (m *Pod) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -28818,17 +31591,17 @@ func (m *Pod) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Pod: wiretype end group for non-group") + return fmt.Errorf("proto: PersistentVolumeStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Pod: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PersistentVolumeStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Phase", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28836,29 +31609,28 @@ func (m *Pod) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Phase = PersistentVolumePhase(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28866,29 +31638,28 @@ func (m *Pod) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28896,27 +31667,26 @@ func (m *Pod) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -28935,8 +31705,8 @@ func (m *Pod) Unmarshal(data []byte) error { } return nil } -func (m *PodAffinity) Unmarshal(data []byte) error { - l := len(data) +func (m *PhotonPersistentDiskVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -28948,7 +31718,7 @@ func (m *PodAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -28958,17 +31728,17 @@ func (m *PodAffinity) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodAffinity: wiretype end group for non-group") + return fmt.Errorf("proto: PhotonPersistentDiskVolumeSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodAffinity: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PhotonPersistentDiskVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field RequiredDuringSchedulingIgnoredDuringExecution", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PdID", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -28976,30 +31746,28 @@ func (m *PodAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.RequiredDuringSchedulingIgnoredDuringExecution = append(m.RequiredDuringSchedulingIgnoredDuringExecution, PodAffinityTerm{}) - if err := m.RequiredDuringSchedulingIgnoredDuringExecution[len(m.RequiredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.PdID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PreferredDuringSchedulingIgnoredDuringExecution", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -29007,28 +31775,26 @@ func (m *PodAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, WeightedPodAffinityTerm{}) - if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29047,8 +31813,8 @@ func (m *PodAffinity) Unmarshal(data []byte) error { } return nil } -func (m *PodAffinityTerm) Unmarshal(data []byte) error { - l := len(data) +func (m *Pod) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29060,7 +31826,7 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29070,15 +31836,15 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodAffinityTerm: wiretype end group for non-group") + return fmt.Errorf("proto: Pod: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodAffinityTerm: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Pod: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -29088,7 +31854,7 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29102,18 +31868,15 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.LabelSelector == nil { - m.LabelSelector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} - } - if err := m.LabelSelector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Namespaces", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -29121,28 +31884,29 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Namespaces = append(m.Namespaces, string(data[iNdEx:postIndex])) + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TopologyKey", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -29150,26 +31914,27 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.TopologyKey = string(data[iNdEx:postIndex]) + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29188,8 +31953,8 @@ func (m *PodAffinityTerm) Unmarshal(data []byte) error { } return nil } -func (m *PodAntiAffinity) Unmarshal(data []byte) error { - l := len(data) +func (m *PodAffinity) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29201,7 +31966,7 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29211,10 +31976,10 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodAntiAffinity: wiretype end group for non-group") + return fmt.Errorf("proto: PodAffinity: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodAntiAffinity: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodAffinity: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -29229,7 +31994,7 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29244,7 +32009,7 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.RequiredDuringSchedulingIgnoredDuringExecution = append(m.RequiredDuringSchedulingIgnoredDuringExecution, PodAffinityTerm{}) - if err := m.RequiredDuringSchedulingIgnoredDuringExecution[len(m.RequiredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RequiredDuringSchedulingIgnoredDuringExecution[len(m.RequiredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -29260,7 +32025,7 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29275,13 +32040,13 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, WeightedPodAffinityTerm{}) - if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29300,8 +32065,8 @@ func (m *PodAntiAffinity) Unmarshal(data []byte) error { } return nil } -func (m *PodAttachOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *PodAffinityTerm) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29313,7 +32078,7 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29323,17 +32088,17 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodAttachOptions: wiretype end group for non-group") + return fmt.Errorf("proto: PodAffinityTerm: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodAttachOptions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodAffinityTerm: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LabelSelector", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -29341,59 +32106,32 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Stdin = bool(v != 0) - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Stdout", wireType) + if msglen < 0 { + return ErrInvalidLengthGenerated } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF } - m.Stdout = bool(v != 0) - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Stderr", wireType) + if m.LabelSelector == nil { + m.LabelSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.LabelSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.Stderr = bool(v != 0) - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field TTY", wireType) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespaces", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -29401,17 +32139,26 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.TTY = bool(v != 0) - case 5: + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespaces = append(m.Namespaces, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Container", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TopologyKey", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -29421,7 +32168,7 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29436,11 +32183,11 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Container = string(data[iNdEx:postIndex]) + m.TopologyKey = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29459,8 +32206,8 @@ func (m *PodAttachOptions) Unmarshal(data []byte) error { } return nil } -func (m *PodCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *PodAntiAffinity) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29472,7 +32219,7 @@ func (m *PodCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29482,73 +32229,15 @@ func (m *PodCondition) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodCondition: wiretype end group for non-group") + return fmt.Errorf("proto: PodAntiAffinity: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodCondition: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodAntiAffinity: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Type = PodConditionType(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Status = ConditionStatus(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastProbeTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RequiredDuringSchedulingIgnoredDuringExecution", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -29558,7 +32247,7 @@ func (m *PodCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29572,13 +32261,14 @@ func (m *PodCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastProbeTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.RequiredDuringSchedulingIgnoredDuringExecution = append(m.RequiredDuringSchedulingIgnoredDuringExecution, PodAffinityTerm{}) + if err := m.RequiredDuringSchedulingIgnoredDuringExecution[len(m.RequiredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PreferredDuringSchedulingIgnoredDuringExecution", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -29588,7 +32278,7 @@ func (m *PodCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29602,71 +32292,14 @@ func (m *PodCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.PreferredDuringSchedulingIgnoredDuringExecution = append(m.PreferredDuringSchedulingIgnoredDuringExecution, WeightedPodAffinityTerm{}) + if err := m.PreferredDuringSchedulingIgnoredDuringExecution[len(m.PreferredDuringSchedulingIgnoredDuringExecution)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Reason = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(data[iNdEx:postIndex]) - iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29685,8 +32318,8 @@ func (m *PodCondition) Unmarshal(data []byte) error { } return nil } -func (m *PodExecOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *PodAttachOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29698,7 +32331,7 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29708,10 +32341,10 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodExecOptions: wiretype end group for non-group") + return fmt.Errorf("proto: PodAttachOptions: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodExecOptions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodAttachOptions: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -29726,7 +32359,7 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29746,7 +32379,7 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29766,7 +32399,7 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29786,7 +32419,7 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29806,36 +32439,7 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Container = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29850,11 +32454,11 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Command = append(m.Command, string(data[iNdEx:postIndex])) + m.Container = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29873,8 +32477,8 @@ func (m *PodExecOptions) Unmarshal(data []byte) error { } return nil } -func (m *PodList) Unmarshal(data []byte) error { - l := len(data) +func (m *PodCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29886,7 +32490,421 @@ func (m *PodList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodCondition: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodCondition: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = PodConditionType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Status = ConditionStatus(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastProbeTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LastProbeTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodExecOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodExecOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodExecOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Stdin", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Stdin = bool(v != 0) + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Stdout", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Stdout = bool(v != 0) + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Stderr", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Stderr = bool(v != 0) + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TTY", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.TTY = bool(v != 0) + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Container", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Container = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Command", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Command = append(m.Command, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -29914,7 +32932,7 @@ func (m *PodList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29928,7 +32946,7 @@ func (m *PodList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -29944,7 +32962,7 @@ func (m *PodList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -29959,13 +32977,13 @@ func (m *PodList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Pod{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -29984,8 +33002,8 @@ func (m *PodList) Unmarshal(data []byte) error { } return nil } -func (m *PodLogOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *PodLogOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -29997,7 +33015,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30025,7 +33043,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30040,7 +33058,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Container = string(data[iNdEx:postIndex]) + m.Container = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { @@ -30054,7 +33072,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30074,7 +33092,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30094,7 +33112,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30114,7 +33132,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30129,9 +33147,9 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.SinceTime == nil { - m.SinceTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + m.SinceTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} } - if err := m.SinceTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SinceTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -30147,7 +33165,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30167,7 +33185,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30187,7 +33205,7 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30197,7 +33215,119 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { m.LimitBytes = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodPortForwardOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodPortForwardOptions: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodPortForwardOptions: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType == 0 { + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Ports = append(m.Ports, v) + } else if wireType == 2 { + var packedLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + packedLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if packedLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + packedLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + for iNdEx < postIndex { + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Ports = append(m.Ports, v) + } + } else { + return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType) + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -30216,8 +33346,8 @@ func (m *PodLogOptions) Unmarshal(data []byte) error { } return nil } -func (m *PodProxyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *PodProxyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -30229,7 +33359,7 @@ func (m *PodProxyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30257,7 +33387,7 @@ func (m *PodProxyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30272,11 +33402,11 @@ func (m *PodProxyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -30295,8 +33425,8 @@ func (m *PodProxyOptions) Unmarshal(data []byte) error { } return nil } -func (m *PodSecurityContext) Unmarshal(data []byte) error { - l := len(data) +func (m *PodSecurityContext) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -30308,7 +33438,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30336,7 +33466,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30353,7 +33483,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { if m.SELinuxOptions == nil { m.SELinuxOptions = &SELinuxOptions{} } - if err := m.SELinuxOptions.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SELinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -30369,7 +33499,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30389,7 +33519,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30399,25 +33529,67 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { b := bool(v != 0) m.RunAsNonRoot = &b case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType) - } - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if wireType == 0 { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + m.SupplementalGroups = append(m.SupplementalGroups, v) + } else if wireType == 2 { + var packedLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + packedLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break + if packedLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + packedLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + for iNdEx < postIndex { + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.SupplementalGroups = append(m.SupplementalGroups, v) } + } else { + return fmt.Errorf("proto: wrong wireType = %d for field SupplementalGroups", wireType) } - m.SupplementalGroups = append(m.SupplementalGroups, v) case 5: if wireType != 0 { return fmt.Errorf("proto: wrong wireType = %d for field FSGroup", wireType) @@ -30430,7 +33602,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30440,7 +33612,7 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { m.FSGroup = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -30459,8 +33631,8 @@ func (m *PodSecurityContext) Unmarshal(data []byte) error { } return nil } -func (m *PodSignature) Unmarshal(data []byte) error { - l := len(data) +func (m *PodSignature) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -30472,7 +33644,7 @@ func (m *PodSignature) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30500,7 +33672,7 @@ func (m *PodSignature) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30515,15 +33687,15 @@ func (m *PodSignature) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.PodController == nil { - m.PodController = &OwnerReference{} + m.PodController = &k8s_io_apimachinery_pkg_apis_meta_v1.OwnerReference{} } - if err := m.PodController.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodController.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -30542,8 +33714,8 @@ func (m *PodSignature) Unmarshal(data []byte) error { } return nil } -func (m *PodSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *PodSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -30555,7 +33727,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30583,7 +33755,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30598,7 +33770,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Volumes = append(m.Volumes, Volume{}) - if err := m.Volumes[len(m.Volumes)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Volumes[len(m.Volumes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -30614,7 +33786,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30629,7 +33801,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Containers = append(m.Containers, Container{}) - if err := m.Containers[len(m.Containers)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Containers[len(m.Containers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -30645,7 +33817,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30660,7 +33832,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RestartPolicy = RestartPolicy(data[iNdEx:postIndex]) + m.RestartPolicy = RestartPolicy(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 0 { @@ -30674,7 +33846,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30694,7 +33866,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -30714,7 +33886,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30729,7 +33901,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DNSPolicy = DNSPolicy(data[iNdEx:postIndex]) + m.DNSPolicy = DNSPolicy(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -30743,7 +33915,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30765,7 +33937,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30780,7 +33952,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30795,52 +33967,57 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if m.NodeSelector == nil { + m.NodeSelector = make(map[string]string) } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.NodeSelector == nil { - m.NodeSelector = make(map[string]string) + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.NodeSelector[mapkey] = mapvalue + } else { + var mapvalue string + m.NodeSelector[mapkey] = mapvalue } - m.NodeSelector[mapkey] = mapvalue iNdEx = postIndex case 8: if wireType != 2 { @@ -30854,7 +34031,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30869,7 +34046,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ServiceAccountName = string(data[iNdEx:postIndex]) + m.ServiceAccountName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 9: if wireType != 2 { @@ -30883,7 +34060,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30898,7 +34075,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DeprecatedServiceAccount = string(data[iNdEx:postIndex]) + m.DeprecatedServiceAccount = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 10: if wireType != 2 { @@ -30912,7 +34089,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -30927,7 +34104,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.NodeName = string(data[iNdEx:postIndex]) + m.NodeName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 11: if wireType != 0 { @@ -30941,7 +34118,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30961,7 +34138,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -30981,7 +34158,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31001,7 +34178,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31018,7 +34195,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if m.SecurityContext == nil { m.SecurityContext = &PodSecurityContext{} } - if err := m.SecurityContext.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SecurityContext.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -31034,7 +34211,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31049,7 +34226,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.ImagePullSecrets = append(m.ImagePullSecrets, LocalObjectReference{}) - if err := m.ImagePullSecrets[len(m.ImagePullSecrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ImagePullSecrets[len(m.ImagePullSecrets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -31065,7 +34242,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31080,7 +34257,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Hostname = string(data[iNdEx:postIndex]) + m.Hostname = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 17: if wireType != 2 { @@ -31094,7 +34271,7 @@ func (m *PodSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31109,11 +34286,187 @@ func (m *PodSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Subdomain = string(data[iNdEx:postIndex]) + m.Subdomain = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 18: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Affinity", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Affinity == nil { + m.Affinity = &Affinity{} + } + if err := m.Affinity.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 19: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SchedulerName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SchedulerName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 20: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field InitContainers", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.InitContainers = append(m.InitContainers, Container{}) + if err := m.InitContainers[len(m.InitContainers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 21: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field AutomountServiceAccountToken", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.AutomountServiceAccountToken = &b + case 22: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Tolerations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Tolerations = append(m.Tolerations, Toleration{}) + if err := m.Tolerations[len(m.Tolerations)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 23: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field HostAliases", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.HostAliases = append(m.HostAliases, HostAlias{}) + if err := m.HostAliases[len(m.HostAliases)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -31132,8 +34485,8 @@ func (m *PodSpec) Unmarshal(data []byte) error { } return nil } -func (m *PodStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *PodStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -31145,7 +34498,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31173,7 +34526,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31188,7 +34541,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Phase = PodPhase(data[iNdEx:postIndex]) + m.Phase = PodPhase(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -31202,7 +34555,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31217,7 +34570,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, PodCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -31233,7 +34586,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31248,7 +34601,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -31262,7 +34615,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31277,7 +34630,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -31291,7 +34644,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31306,7 +34659,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.HostIP = string(data[iNdEx:postIndex]) + m.HostIP = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -31320,7 +34673,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31335,7 +34688,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.PodIP = string(data[iNdEx:postIndex]) + m.PodIP = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -31349,7 +34702,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31364,9 +34717,9 @@ func (m *PodStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.StartTime == nil { - m.StartTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + m.StartTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} } - if err := m.StartTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.StartTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -31382,7 +34735,7 @@ func (m *PodStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31397,65 +34750,15 @@ func (m *PodStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.ContainerStatuses = append(m.ContainerStatuses, ContainerStatus{}) - if err := m.ContainerStatuses[len(m.ContainerStatuses)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ContainerStatuses[len(m.ContainerStatuses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *PodStatusResult) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: PodStatusResult: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: PodStatusResult: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 9: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field QOSClass", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -31463,27 +34766,26 @@ func (m *PodStatusResult) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.QOSClass = PodQOSClass(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 10: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field InitContainerStatuses", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -31493,7 +34795,7 @@ func (m *PodStatusResult) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31507,13 +34809,14 @@ func (m *PodStatusResult) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.InitContainerStatuses = append(m.InitContainerStatuses, ContainerStatus{}) + if err := m.InitContainerStatuses[len(m.InitContainerStatuses)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -31532,8 +34835,8 @@ func (m *PodStatusResult) Unmarshal(data []byte) error { } return nil } -func (m *PodTemplate) Unmarshal(data []byte) error { - l := len(data) +func (m *PodStatusResult) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -31545,7 +34848,7 @@ func (m *PodTemplate) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31555,10 +34858,10 @@ func (m *PodTemplate) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodTemplate: wiretype end group for non-group") + return fmt.Errorf("proto: PodStatusResult: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodTemplate: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodStatusResult: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -31573,7 +34876,7 @@ func (m *PodTemplate) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31587,13 +34890,13 @@ func (m *PodTemplate) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -31603,7 +34906,7 @@ func (m *PodTemplate) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31617,13 +34920,13 @@ func (m *PodTemplate) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -31642,8 +34945,8 @@ func (m *PodTemplate) Unmarshal(data []byte) error { } return nil } -func (m *PodTemplateList) Unmarshal(data []byte) error { - l := len(data) +func (m *PodTemplate) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -31655,7 +34958,7 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31665,15 +34968,15 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodTemplateList: wiretype end group for non-group") + return fmt.Errorf("proto: PodTemplate: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodTemplateList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodTemplate: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -31683,7 +34986,7 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31697,13 +35000,13 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -31713,7 +35016,7 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31727,14 +35030,13 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, PodTemplate{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -31753,8 +35055,8 @@ func (m *PodTemplateList) Unmarshal(data []byte) error { } return nil } -func (m *PodTemplateSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *PodTemplateList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -31766,7 +35068,7 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31776,15 +35078,15 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PodTemplateSpec: wiretype end group for non-group") + return fmt.Errorf("proto: PodTemplateList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PodTemplateSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodTemplateList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -31794,7 +35096,7 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31808,13 +35110,13 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -31824,7 +35126,7 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -31838,13 +35140,14 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, PodTemplate{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -31863,8 +35166,8 @@ func (m *PodTemplateSpec) Unmarshal(data []byte) error { } return nil } -func (m *Preconditions) Unmarshal(data []byte) error { - l := len(data) +func (m *PodTemplateSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -31876,7 +35179,7 @@ func (m *Preconditions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31886,17 +35189,17 @@ func (m *Preconditions) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Preconditions: wiretype end group for non-group") + return fmt.Errorf("proto: PodTemplateSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Preconditions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodTemplateSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -31904,27 +35207,57 @@ func (m *Preconditions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - s := k8s_io_kubernetes_pkg_types.UID(data[iNdEx:postIndex]) - m.UID = &s + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -31943,8 +35276,8 @@ func (m *Preconditions) Unmarshal(data []byte) error { } return nil } -func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { - l := len(data) +func (m *PortworxVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -31956,7 +35289,7 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -31966,17 +35299,17 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PreferAvoidPodsEntry: wiretype end group for non-group") + return fmt.Errorf("proto: PortworxVolumeSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PreferAvoidPodsEntry: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PortworxVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field PodSignature", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field VolumeID", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -31984,57 +35317,26 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.PodSignature.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.VolumeID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field EvictionTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.EvictionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -32044,7 +35346,7 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32059,13 +35361,13 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) } - var stringLen uint64 + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32073,26 +35375,17 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(data[iNdEx:postIndex]) - iNdEx = postIndex + m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -32111,8 +35404,8 @@ func (m *PreferAvoidPodsEntry) Unmarshal(data []byte) error { } return nil } -func (m *PreferredSchedulingTerm) Unmarshal(data []byte) error { - l := len(data) +func (m *Preconditions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -32124,7 +35417,7 @@ func (m *PreferredSchedulingTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32134,36 +35427,17 @@ func (m *PreferredSchedulingTerm) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: PreferredSchedulingTerm: wiretype end group for non-group") + return fmt.Errorf("proto: Preconditions: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: PreferredSchedulingTerm: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Preconditions: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType) - } - m.Weight = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Weight |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Preference", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32171,27 +35445,27 @@ func (m *PreferredSchedulingTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Preference.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + s := k8s_io_apimachinery_pkg_types.UID(dAtA[iNdEx:postIndex]) + m.UID = &s iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -32210,8 +35484,8 @@ func (m *PreferredSchedulingTerm) Unmarshal(data []byte) error { } return nil } -func (m *Probe) Unmarshal(data []byte) error { - l := len(data) +func (m *PreferAvoidPodsEntry) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -32223,7 +35497,7 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32233,15 +35507,15 @@ func (m *Probe) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Probe: wiretype end group for non-group") + return fmt.Errorf("proto: PreferAvoidPodsEntry: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Probe: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PreferAvoidPodsEntry: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Handler", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodSignature", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -32251,7 +35525,7 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -32265,15 +35539,15 @@ func (m *Probe) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Handler.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodSignature.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field InitialDelaySeconds", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EvictionTime", wireType) } - m.InitialDelaySeconds = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32281,18 +35555,29 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.InitialDelaySeconds |= (int32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.EvictionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field TimeoutSeconds", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) } - m.TimeoutSeconds = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32300,18 +35585,28 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.TimeoutSeconds |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field PeriodSeconds", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) } - m.PeriodSeconds = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32319,18 +35614,78 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.PeriodSeconds |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - case 5: + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PreferredSchedulingTerm) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PreferredSchedulingTerm: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PreferredSchedulingTerm: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field SuccessThreshold", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Weight", wireType) } - m.SuccessThreshold = 0 + m.Weight = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32338,18 +35693,18 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.SuccessThreshold |= (int32(b) & 0x7F) << shift + m.Weight |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field FailureThreshold", wireType) + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Preference", wireType) } - m.FailureThreshold = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -32357,16 +35712,27 @@ func (m *Probe) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.FailureThreshold |= (int32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Preference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -32385,8 +35751,8 @@ func (m *Probe) Unmarshal(data []byte) error { } return nil } -func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *Probe) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -32398,7 +35764,283 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Probe: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Probe: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Handler", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Handler.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field InitialDelaySeconds", wireType) + } + m.InitialDelaySeconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.InitialDelaySeconds |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TimeoutSeconds", wireType) + } + m.TimeoutSeconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.TimeoutSeconds |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field PeriodSeconds", wireType) + } + m.PeriodSeconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.PeriodSeconds |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field SuccessThreshold", wireType) + } + m.SuccessThreshold = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.SuccessThreshold |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field FailureThreshold", wireType) + } + m.FailureThreshold = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.FailureThreshold |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ProjectedVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ProjectedVolumeSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ProjectedVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Sources", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Sources = append(m.Sources, VolumeProjection{}) + if err := m.Sources[len(m.Sources)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DefaultMode", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.DefaultMode = &v + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *QuobyteVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32426,7 +36068,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32441,7 +36083,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Registry = string(data[iNdEx:postIndex]) + m.Registry = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -32455,7 +36097,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32470,7 +36112,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Volume = string(data[iNdEx:postIndex]) + m.Volume = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -32484,7 +36126,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -32504,7 +36146,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32519,7 +36161,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.User = string(data[iNdEx:postIndex]) + m.User = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -32533,7 +36175,7 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32548,11 +36190,11 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Group = string(data[iNdEx:postIndex]) + m.Group = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -32571,8 +36213,8 @@ func (m *QuobyteVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *RBDVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *RBDVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -32584,7 +36226,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32612,7 +36254,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32627,7 +36269,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.CephMonitors = append(m.CephMonitors, string(data[iNdEx:postIndex])) + m.CephMonitors = append(m.CephMonitors, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 2: if wireType != 2 { @@ -32641,7 +36283,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32656,7 +36298,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RBDImage = string(data[iNdEx:postIndex]) + m.RBDImage = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -32670,7 +36312,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32685,7 +36327,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -32699,7 +36341,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32714,7 +36356,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RBDPool = string(data[iNdEx:postIndex]) + m.RBDPool = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -32728,7 +36370,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32743,7 +36385,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RadosUser = string(data[iNdEx:postIndex]) + m.RadosUser = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -32757,7 +36399,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32772,7 +36414,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Keyring = string(data[iNdEx:postIndex]) + m.Keyring = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -32786,7 +36428,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -32803,7 +36445,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if m.SecretRef == nil { m.SecretRef = &LocalObjectReference{} } - if err := m.SecretRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -32819,7 +36461,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -32829,7 +36471,7 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { m.ReadOnly = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -32848,8 +36490,8 @@ func (m *RBDVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *RangeAllocation) Unmarshal(data []byte) error { - l := len(data) +func (m *RangeAllocation) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -32861,7 +36503,7 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32889,7 +36531,7 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -32903,7 +36545,7 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -32919,7 +36561,7 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -32934,7 +36576,7 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Range = string(data[iNdEx:postIndex]) + m.Range = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -32948,7 +36590,7 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -32962,14 +36604,14 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Data = append(m.Data[:0], data[iNdEx:postIndex]...) + m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...) if m.Data == nil { m.Data = []byte{} } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -32988,8 +36630,8 @@ func (m *RangeAllocation) Unmarshal(data []byte) error { } return nil } -func (m *ReplicationController) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicationController) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33001,7 +36643,7 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33029,7 +36671,7 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33043,7 +36685,7 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -33059,7 +36701,7 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33073,7 +36715,7 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -33089,7 +36731,7 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33103,13 +36745,13 @@ func (m *ReplicationController) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -33128,8 +36770,8 @@ func (m *ReplicationController) Unmarshal(data []byte) error { } return nil } -func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicationControllerCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33141,7 +36783,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33169,7 +36811,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33184,7 +36826,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = ReplicationControllerConditionType(data[iNdEx:postIndex]) + m.Type = ReplicationControllerConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -33198,7 +36840,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33213,7 +36855,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Status = ConditionStatus(data[iNdEx:postIndex]) + m.Status = ConditionStatus(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -33227,7 +36869,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33241,7 +36883,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -33257,7 +36899,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33272,7 +36914,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -33286,7 +36928,7 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33301,11 +36943,11 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -33324,8 +36966,8 @@ func (m *ReplicationControllerCondition) Unmarshal(data []byte) error { } return nil } -func (m *ReplicationControllerList) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicationControllerList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33337,7 +36979,7 @@ func (m *ReplicationControllerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33365,7 +37007,7 @@ func (m *ReplicationControllerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33379,7 +37021,7 @@ func (m *ReplicationControllerList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -33395,7 +37037,7 @@ func (m *ReplicationControllerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33410,13 +37052,13 @@ func (m *ReplicationControllerList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ReplicationController{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -33435,8 +37077,8 @@ func (m *ReplicationControllerList) Unmarshal(data []byte) error { } return nil } -func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicationControllerSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33448,7 +37090,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33476,7 +37118,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -33496,7 +37138,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33518,7 +37160,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33533,7 +37175,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33548,52 +37190,57 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.Selector == nil { + m.Selector = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Selector == nil { - m.Selector = make(map[string]string) + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Selector[mapkey] = mapvalue + } else { + var mapvalue string + m.Selector[mapkey] = mapvalue } - m.Selector[mapkey] = mapvalue iNdEx = postIndex case 3: if wireType != 2 { @@ -33607,7 +37254,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33624,7 +37271,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if m.Template == nil { m.Template = &PodTemplateSpec{} } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -33640,7 +37287,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.MinReadySeconds |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -33649,7 +37296,7 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -33668,8 +37315,8 @@ func (m *ReplicationControllerSpec) Unmarshal(data []byte) error { } return nil } -func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicationControllerStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33681,7 +37328,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33709,7 +37356,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -33728,7 +37375,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.FullyLabeledReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -33747,7 +37394,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ObservedGeneration |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -33766,7 +37413,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ReadyReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -33785,7 +37432,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.AvailableReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -33804,7 +37451,7 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33819,13 +37466,13 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, ReplicationControllerCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -33844,8 +37491,8 @@ func (m *ReplicationControllerStatus) Unmarshal(data []byte) error { } return nil } -func (m *ResourceFieldSelector) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceFieldSelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33857,7 +37504,7 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33885,7 +37532,7 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33900,7 +37547,7 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ContainerName = string(data[iNdEx:postIndex]) + m.ContainerName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -33914,7 +37561,7 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -33929,7 +37576,7 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Resource = string(data[iNdEx:postIndex]) + m.Resource = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -33943,7 +37590,7 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -33957,13 +37604,13 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Divisor.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Divisor.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -33982,8 +37629,8 @@ func (m *ResourceFieldSelector) Unmarshal(data []byte) error { } return nil } -func (m *ResourceQuota) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceQuota) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -33995,7 +37642,7 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34023,7 +37670,7 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34037,7 +37684,7 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -34053,7 +37700,7 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34067,7 +37714,7 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -34083,7 +37730,7 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34097,13 +37744,13 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -34122,8 +37769,8 @@ func (m *ResourceQuota) Unmarshal(data []byte) error { } return nil } -func (m *ResourceQuotaList) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceQuotaList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -34135,7 +37782,7 @@ func (m *ResourceQuotaList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34163,7 +37810,7 @@ func (m *ResourceQuotaList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34177,7 +37824,7 @@ func (m *ResourceQuotaList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -34193,7 +37840,7 @@ func (m *ResourceQuotaList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34208,13 +37855,13 @@ func (m *ResourceQuotaList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ResourceQuota{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -34233,8 +37880,8 @@ func (m *ResourceQuotaList) Unmarshal(data []byte) error { } return nil } -func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceQuotaSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -34246,7 +37893,7 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34274,7 +37921,7 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34296,7 +37943,7 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34311,7 +37958,7 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34326,57 +37973,62 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Hard == nil { + m.Hard = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Hard[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Hard[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Hard == nil { - m.Hard = make(ResourceList) - } - m.Hard[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex case 2: if wireType != 2 { @@ -34390,7 +38042,7 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34405,11 +38057,11 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Scopes = append(m.Scopes, ResourceQuotaScope(data[iNdEx:postIndex])) + m.Scopes = append(m.Scopes, ResourceQuotaScope(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -34428,8 +38080,8 @@ func (m *ResourceQuotaSpec) Unmarshal(data []byte) error { } return nil } -func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceQuotaStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -34441,7 +38093,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34469,7 +38121,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34491,7 +38143,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34506,7 +38158,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34521,57 +38173,62 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Hard == nil { + m.Hard = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Hard[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Hard[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Hard == nil { - m.Hard = make(ResourceList) - } - m.Hard[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex case 2: if wireType != 2 { @@ -34585,7 +38242,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34607,7 +38264,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34622,7 +38279,7 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34637,61 +38294,66 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Used == nil { + m.Used = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Used[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Used[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Used == nil { - m.Used = make(ResourceList) - } - m.Used[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -34710,8 +38372,8 @@ func (m *ResourceQuotaStatus) Unmarshal(data []byte) error { } return nil } -func (m *ResourceRequirements) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceRequirements) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -34723,7 +38385,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34751,7 +38413,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34773,7 +38435,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34788,7 +38450,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34803,57 +38465,62 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Limits == nil { + m.Limits = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Limits[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Limits[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Limits == nil { - m.Limits = make(ResourceList) - } - m.Limits[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex case 2: if wireType != 2 { @@ -34867,7 +38534,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -34889,7 +38556,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34904,7 +38571,7 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -34919,61 +38586,66 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := ResourceName(data[iNdEx:postStringIndexmapkey]) + mapkey := ResourceName(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Requests == nil { + m.Requests = make(ResourceList) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_api_resource.Quantity{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Requests[ResourceName(mapkey)] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_api_resource.Quantity + m.Requests[ResourceName(mapkey)] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_resource.Quantity{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Requests == nil { - m.Requests = make(ResourceList) - } - m.Requests[ResourceName(mapkey)] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -34992,8 +38664,8 @@ func (m *ResourceRequirements) Unmarshal(data []byte) error { } return nil } -func (m *SELinuxOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *SELinuxOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -35005,7 +38677,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35033,7 +38705,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35048,7 +38720,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.User = string(data[iNdEx:postIndex]) + m.User = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -35062,7 +38734,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35077,7 +38749,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Role = string(data[iNdEx:postIndex]) + m.Role = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -35091,7 +38763,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35106,7 +38778,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = string(data[iNdEx:postIndex]) + m.Type = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -35120,7 +38792,7 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35135,11 +38807,11 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Level = string(data[iNdEx:postIndex]) + m.Level = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -35158,8 +38830,8 @@ func (m *SELinuxOptions) Unmarshal(data []byte) error { } return nil } -func (m *Secret) Unmarshal(data []byte) error { - l := len(data) +func (m *ScaleIOVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -35171,7 +38843,7 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35181,17 +38853,17 @@ func (m *Secret) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Secret: wiretype end group for non-group") + return fmt.Errorf("proto: ScaleIOVolumeSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Secret: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ScaleIOVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Gateway", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35199,27 +38871,55 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Gateway = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field System", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.System = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -35229,7 +38929,7 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35243,7 +38943,18 @@ func (m *Secret) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - var keykey uint64 + if m.SecretRef == nil { + m.SecretRef = &LocalObjectReference{} + } + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field SSLEnabled", wireType) + } + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35251,14 +38962,19 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - keykey |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapkey uint64 + m.SSLEnabled = bool(v != 0) + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProtectionDomain", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35266,24 +38982,28 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLenmapkey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapkey := int(stringLenmapkey) - if intStringLenmapkey < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postStringIndexmapkey := iNdEx + intStringLenmapkey - if postStringIndexmapkey > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) - iNdEx = postStringIndexmapkey - var valuekey uint64 + m.ProtectionDomain = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StoragePool", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35291,14 +39011,28 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - var mapbyteLen uint64 + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.StoragePool = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StorageMode", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35306,32 +39040,55 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - mapbyteLen |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intMapbyteLen := int(mapbyteLen) - if intMapbyteLen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postbytesIndex := iNdEx + intMapbyteLen - if postbytesIndex > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapvalue := make([]byte, mapbyteLen) - copy(mapvalue, data[iNdEx:postbytesIndex]) - iNdEx = postbytesIndex - if m.Data == nil { - m.Data = make(map[string][]byte) + m.StorageMode = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VolumeName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } - m.Data[mapkey] = mapvalue + m.VolumeName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + case 9: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -35341,7 +39098,7 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35356,11 +39113,111 @@ func (m *Secret) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = SecretType(data[iNdEx:postIndex]) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 10: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ReadOnly = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Secret) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Secret: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Secret: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field StringData", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -35370,7 +39227,7 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35392,7 +39249,7 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35407,7 +39264,7 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35422,9 +39279,115 @@ func (m *Secret) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 + if m.Data == nil { + m.Data = make(map[string][]byte) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapbyteLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapbyteLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intMapbyteLen := int(mapbyteLen) + if intMapbyteLen < 0 { + return ErrInvalidLengthGenerated + } + postbytesIndex := iNdEx + intMapbyteLen + if postbytesIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := make([]byte, mapbyteLen) + copy(mapvalue, dAtA[iNdEx:postbytesIndex]) + iNdEx = postbytesIndex + m.Data[mapkey] = mapvalue + } else { + var mapvalue []byte + m.Data[mapkey] = mapvalue + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = SecretType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StringData", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35432,14 +39395,14 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift + keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - var stringLenmapvalue uint64 + var stringLenmapkey uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35447,31 +39410,177 @@ func (m *Secret) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift + stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { return ErrInvalidLengthGenerated } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey if m.StringData == nil { m.StringData = make(map[string]string) } - m.StringData[mapkey] = mapvalue + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.StringData[mapkey] = mapvalue + } else { + var mapvalue string + m.StringData[mapkey] = mapvalue + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SecretEnvSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SecretEnvSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SecretEnvSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -35490,8 +39599,8 @@ func (m *Secret) Unmarshal(data []byte) error { } return nil } -func (m *SecretKeySelector) Unmarshal(data []byte) error { - l := len(data) +func (m *SecretKeySelector) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -35503,7 +39612,7 @@ func (m *SecretKeySelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35531,7 +39640,7 @@ func (m *SecretKeySelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35545,7 +39654,7 @@ func (m *SecretKeySelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LocalObjectReference.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -35561,7 +39670,7 @@ func (m *SecretKeySelector) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35576,11 +39685,32 @@ func (m *SecretKeySelector) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Key = string(data[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -35599,8 +39729,8 @@ func (m *SecretKeySelector) Unmarshal(data []byte) error { } return nil } -func (m *SecretList) Unmarshal(data []byte) error { - l := len(data) +func (m *SecretList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -35612,7 +39742,7 @@ func (m *SecretList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35640,7 +39770,7 @@ func (m *SecretList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35654,7 +39784,7 @@ func (m *SecretList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -35670,7 +39800,7 @@ func (m *SecretList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35685,13 +39815,13 @@ func (m *SecretList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Secret{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -35710,8 +39840,8 @@ func (m *SecretList) Unmarshal(data []byte) error { } return nil } -func (m *SecretVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *SecretProjection) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -35723,7 +39853,7 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35733,17 +39863,17 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SecretVolumeSource: wiretype end group for non-group") + return fmt.Errorf("proto: SecretProjection: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SecretVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SecretProjection: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecretName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LocalObjectReference", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35751,22 +39881,23 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.SecretName = string(data[iNdEx:postIndex]) + if err := m.LocalObjectReference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { @@ -35780,7 +39911,7 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35795,15 +39926,15 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, KeyToPath{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: + case 4: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DefaultMode", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) } - var v int32 + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35811,17 +39942,18 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int32(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.DefaultMode = &v + b := bool(v != 0) + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -35840,8 +39972,8 @@ func (m *SecretVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *SecurityContext) Unmarshal(data []byte) error { - l := len(data) +func (m *SecretVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -35853,7 +39985,7 @@ func (m *SecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -35863,17 +39995,17 @@ func (m *SecurityContext) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SecurityContext: wiretype end group for non-group") + return fmt.Errorf("proto: SecretVolumeSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SecurityContext: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SecretVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Capabilities", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SecretName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35881,51 +40013,26 @@ func (m *SecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.Capabilities == nil { - m.Capabilities = &Capabilities{} - } - if err := m.Capabilities.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.SecretName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - b := bool(v != 0) - m.Privileged = &b - case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SELinuxOptions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -35935,7 +40042,7 @@ func (m *SecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -35949,38 +40056,16 @@ func (m *SecurityContext) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.SELinuxOptions == nil { - m.SELinuxOptions = &SELinuxOptions{} - } - if err := m.SELinuxOptions.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, KeyToPath{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType) - } - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.RunAsUser = &v - case 5: + case 3: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field RunAsNonRoot", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DefaultMode", wireType) } - var v int + var v int32 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -35988,18 +40073,17 @@ func (m *SecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + v |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - b := bool(v != 0) - m.RunAsNonRoot = &b - case 6: + m.DefaultMode = &v + case 4: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ReadOnlyRootFilesystem", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Optional", wireType) } var v int for shift := uint(0); ; shift += 7 { @@ -36009,7 +40093,7 @@ func (m *SecurityContext) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36017,10 +40101,10 @@ func (m *SecurityContext) Unmarshal(data []byte) error { } } b := bool(v != 0) - m.ReadOnlyRootFilesystem = &b + m.Optional = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36039,8 +40123,8 @@ func (m *SecurityContext) Unmarshal(data []byte) error { } return nil } -func (m *SerializedReference) Unmarshal(data []byte) error { - l := len(data) +func (m *SecurityContext) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36052,7 +40136,7 @@ func (m *SerializedReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36062,15 +40146,15 @@ func (m *SerializedReference) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: SerializedReference: wiretype end group for non-group") + return fmt.Errorf("proto: SecurityContext: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: SerializedReference: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: SecurityContext: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reference", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Capabilities", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -36080,7 +40164,7 @@ func (m *SerializedReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36094,13 +40178,132 @@ func (m *SerializedReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Reference.Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.Capabilities == nil { + m.Capabilities = &Capabilities{} + } + if err := m.Capabilities.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Privileged", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.Privileged = &b + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SELinuxOptions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SELinuxOptions == nil { + m.SELinuxOptions = &SELinuxOptions{} + } + if err := m.SELinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field RunAsUser", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.RunAsUser = &v + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field RunAsNonRoot", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.RunAsNonRoot = &b + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnlyRootFilesystem", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.ReadOnlyRootFilesystem = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36119,8 +40322,8 @@ func (m *SerializedReference) Unmarshal(data []byte) error { } return nil } -func (m *Service) Unmarshal(data []byte) error { - l := len(data) +func (m *SerializedReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36132,7 +40335,87 @@ func (m *Service) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SerializedReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SerializedReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reference", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Reference.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Service) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36160,7 +40443,7 @@ func (m *Service) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36174,7 +40457,7 @@ func (m *Service) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36190,7 +40473,7 @@ func (m *Service) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36204,7 +40487,7 @@ func (m *Service) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36220,7 +40503,7 @@ func (m *Service) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36234,13 +40517,13 @@ func (m *Service) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36259,8 +40542,8 @@ func (m *Service) Unmarshal(data []byte) error { } return nil } -func (m *ServiceAccount) Unmarshal(data []byte) error { - l := len(data) +func (m *ServiceAccount) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36272,7 +40555,7 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36300,7 +40583,7 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36314,7 +40597,7 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36330,7 +40613,7 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36345,7 +40628,7 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Secrets = append(m.Secrets, ObjectReference{}) - if err := m.Secrets[len(m.Secrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Secrets[len(m.Secrets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36361,7 +40644,7 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36376,13 +40659,34 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.ImagePullSecrets = append(m.ImagePullSecrets, LocalObjectReference{}) - if err := m.ImagePullSecrets[len(m.ImagePullSecrets)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ImagePullSecrets[len(m.ImagePullSecrets)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field AutomountServiceAccountToken", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + b := bool(v != 0) + m.AutomountServiceAccountToken = &b default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36401,8 +40705,8 @@ func (m *ServiceAccount) Unmarshal(data []byte) error { } return nil } -func (m *ServiceAccountList) Unmarshal(data []byte) error { - l := len(data) +func (m *ServiceAccountList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36414,7 +40718,7 @@ func (m *ServiceAccountList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36442,7 +40746,7 @@ func (m *ServiceAccountList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36456,7 +40760,7 @@ func (m *ServiceAccountList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36472,7 +40776,7 @@ func (m *ServiceAccountList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36487,13 +40791,13 @@ func (m *ServiceAccountList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ServiceAccount{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36512,8 +40816,8 @@ func (m *ServiceAccountList) Unmarshal(data []byte) error { } return nil } -func (m *ServiceList) Unmarshal(data []byte) error { - l := len(data) +func (m *ServiceList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36525,7 +40829,7 @@ func (m *ServiceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36553,7 +40857,7 @@ func (m *ServiceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36567,7 +40871,7 @@ func (m *ServiceList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36583,7 +40887,7 @@ func (m *ServiceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36598,13 +40902,13 @@ func (m *ServiceList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Service{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36623,8 +40927,8 @@ func (m *ServiceList) Unmarshal(data []byte) error { } return nil } -func (m *ServicePort) Unmarshal(data []byte) error { - l := len(data) +func (m *ServicePort) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36636,7 +40940,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36664,7 +40968,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36679,7 +40983,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -36693,7 +40997,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36708,7 +41012,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Protocol = Protocol(data[iNdEx:postIndex]) + m.Protocol = Protocol(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 0 { @@ -36722,7 +41026,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Port |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -36741,7 +41045,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36755,7 +41059,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.TargetPort.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TargetPort.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36771,7 +41075,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.NodePort |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -36780,7 +41084,7 @@ func (m *ServicePort) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36799,8 +41103,8 @@ func (m *ServicePort) Unmarshal(data []byte) error { } return nil } -func (m *ServiceProxyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *ServiceProxyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36812,7 +41116,7 @@ func (m *ServiceProxyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36840,7 +41144,7 @@ func (m *ServiceProxyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36855,11 +41159,11 @@ func (m *ServiceProxyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -36878,8 +41182,8 @@ func (m *ServiceProxyOptions) Unmarshal(data []byte) error { } return nil } -func (m *ServiceSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *ServiceSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -36891,7 +41195,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36919,7 +41223,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36934,7 +41238,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ports = append(m.Ports, ServicePort{}) - if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -36950,7 +41254,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -36972,7 +41276,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -36987,7 +41291,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37002,24 +41306,63 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Selector == nil { + m.Selector = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Selector[mapkey] = mapvalue + } else { + var mapvalue string + m.Selector[mapkey] = mapvalue + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClusterIP", wireType) } - var stringLenmapvalue uint64 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37027,31 +41370,26 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Selector == nil { - m.Selector = make(map[string]string) - } - m.Selector[mapkey] = mapvalue + m.ClusterIP = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 3: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ClusterIP", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -37061,7 +41399,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37076,11 +41414,11 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ClusterIP = string(data[iNdEx:postIndex]) + m.Type = ServiceType(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 4: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ExternalIPs", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -37090,7 +41428,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37105,11 +41443,553 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = ServiceType(data[iNdEx:postIndex]) + m.ExternalIPs = append(m.ExternalIPs, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SessionAffinity", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SessionAffinity = ServiceAffinity(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancerIP", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.LoadBalancerIP = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 9: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancerSourceRanges", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.LoadBalancerSourceRanges = append(m.LoadBalancerSourceRanges, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExternalName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExternalName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 11: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExternalTrafficPolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExternalTrafficPolicy = ServiceExternalTrafficPolicyType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 12: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field HealthCheckNodePort", wireType) + } + m.HealthCheckNodePort = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.HealthCheckNodePort |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ServiceStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ServiceStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ServiceStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancer", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LoadBalancer.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StorageOSPersistentVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StorageOSPersistentVolumeSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StorageOSPersistentVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VolumeName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.VolumeName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VolumeNamespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.VolumeNamespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.FSType = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ReadOnly = bool(v != 0) case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ExternalIPs", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.SecretRef == nil { + m.SecretRef = &ObjectReference{} + } + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StorageOSVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StorageOSVolumeSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StorageOSVolumeSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VolumeName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.VolumeName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VolumeNamespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.VolumeNamespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FSType", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -37119,7 +41999,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37134,13 +42014,13 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ExternalIPs = append(m.ExternalIPs, string(data[iNdEx:postIndex])) + m.FSType = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field DeprecatedPublicIPs", wireType) + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) } - var stringLen uint64 + var v int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37148,28 +42028,19 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + v |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.DeprecatedPublicIPs = append(m.DeprecatedPublicIPs, string(data[iNdEx:postIndex])) - iNdEx = postIndex - case 7: + m.ReadOnly = bool(v != 0) + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SessionAffinity", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SecretRef", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37177,55 +42048,80 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.SessionAffinity = ServiceAffinity(data[iNdEx:postIndex]) - iNdEx = postIndex - case 8: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancerIP", wireType) + if m.SecretRef == nil { + m.SecretRef = &LocalObjectReference{} } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.SecretRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - intStringLen := int(stringLen) - if intStringLen < 0 { + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - m.LoadBalancerIP = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 9: + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Sysctl) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Sysctl: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Sysctl: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancerSourceRanges", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -37235,7 +42131,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37250,11 +42146,11 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.LoadBalancerSourceRanges = append(m.LoadBalancerSourceRanges, string(data[iNdEx:postIndex])) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 10: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ExternalName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -37264,7 +42160,7 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37279,11 +42175,11 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ExternalName = string(data[iNdEx:postIndex]) + m.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -37302,8 +42198,8 @@ func (m *ServiceSpec) Unmarshal(data []byte) error { } return nil } -func (m *ServiceStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *TCPSocketAction) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -37315,7 +42211,7 @@ func (m *ServiceStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37325,15 +42221,15 @@ func (m *ServiceStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ServiceStatus: wiretype end group for non-group") + return fmt.Errorf("proto: TCPSocketAction: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ServiceStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: TCPSocketAction: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancer", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -37343,7 +42239,7 @@ func (m *ServiceStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -37357,65 +42253,15 @@ func (m *ServiceStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LoadBalancer.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Port.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *TCPSocketAction) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: TCPSocketAction: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: TCPSocketAction: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37423,27 +42269,26 @@ func (m *TCPSocketAction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Port.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Host = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -37462,8 +42307,8 @@ func (m *TCPSocketAction) Unmarshal(data []byte) error { } return nil } -func (m *Taint) Unmarshal(data []byte) error { - l := len(data) +func (m *Taint) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -37475,7 +42320,7 @@ func (m *Taint) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37503,7 +42348,7 @@ func (m *Taint) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37518,7 +42363,7 @@ func (m *Taint) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Key = string(data[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -37532,7 +42377,7 @@ func (m *Taint) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37547,7 +42392,7 @@ func (m *Taint) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Value = string(data[iNdEx:postIndex]) + m.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -37561,7 +42406,7 @@ func (m *Taint) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37576,11 +42421,41 @@ func (m *Taint) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Effect = TaintEffect(data[iNdEx:postIndex]) + m.Effect = TaintEffect(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TimeAdded", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.TimeAdded.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -37599,8 +42474,8 @@ func (m *Taint) Unmarshal(data []byte) error { } return nil } -func (m *Toleration) Unmarshal(data []byte) error { - l := len(data) +func (m *Toleration) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -37612,7 +42487,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37640,7 +42515,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37655,7 +42530,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Key = string(data[iNdEx:postIndex]) + m.Key = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -37669,7 +42544,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37684,7 +42559,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Operator = TolerationOperator(data[iNdEx:postIndex]) + m.Operator = TolerationOperator(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -37698,7 +42573,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37713,7 +42588,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Value = string(data[iNdEx:postIndex]) + m.Value = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -37727,7 +42602,7 @@ func (m *Toleration) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37742,11 +42617,31 @@ func (m *Toleration) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Effect = TaintEffect(data[iNdEx:postIndex]) + m.Effect = TaintEffect(dAtA[iNdEx:postIndex]) iNdEx = postIndex + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TolerationSeconds", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.TolerationSeconds = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -37765,8 +42660,8 @@ func (m *Toleration) Unmarshal(data []byte) error { } return nil } -func (m *Volume) Unmarshal(data []byte) error { - l := len(data) +func (m *Volume) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -37778,7 +42673,7 @@ func (m *Volume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37806,7 +42701,7 @@ func (m *Volume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37821,7 +42716,7 @@ func (m *Volume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -37835,7 +42730,7 @@ func (m *Volume) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -37849,13 +42744,13 @@ func (m *Volume) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.VolumeSource.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.VolumeSource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -37874,8 +42769,8 @@ func (m *Volume) Unmarshal(data []byte) error { } return nil } -func (m *VolumeMount) Unmarshal(data []byte) error { - l := len(data) +func (m *VolumeMount) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -37887,7 +42782,7 @@ func (m *VolumeMount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37915,7 +42810,85 @@ func (m *VolumeMount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ReadOnly = bool(v != 0) + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MountPath", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MountPath = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SubPath", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -37930,13 +42903,63 @@ func (m *VolumeMount) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.SubPath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ReadOnly", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - var v int + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *VolumeProjection) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: VolumeProjection: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: VolumeProjection: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Secret", wireType) + } + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37944,19 +42967,32 @@ func (m *VolumeMount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.ReadOnly = bool(v != 0) - case 3: + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Secret == nil { + m.Secret = &SecretProjection{} + } + if err := m.Secret.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field MountPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field DownwardAPI", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37964,28 +43000,32 @@ func (m *VolumeMount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.MountPath = string(data[iNdEx:postIndex]) + if m.DownwardAPI == nil { + m.DownwardAPI = &DownwardAPIProjection{} + } + if err := m.DownwardAPI.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 4: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SubPath", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ConfigMap", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -37993,26 +43033,30 @@ func (m *VolumeMount) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.SubPath = string(data[iNdEx:postIndex]) + if m.ConfigMap == nil { + m.ConfigMap = &ConfigMapProjection{} + } + if err := m.ConfigMap.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -38031,8 +43075,8 @@ func (m *VolumeMount) Unmarshal(data []byte) error { } return nil } -func (m *VolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *VolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -38044,7 +43088,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -38072,7 +43116,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38089,7 +43133,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.HostPath == nil { m.HostPath = &HostPathVolumeSource{} } - if err := m.HostPath.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.HostPath.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38105,7 +43149,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38122,7 +43166,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.EmptyDir == nil { m.EmptyDir = &EmptyDirVolumeSource{} } - if err := m.EmptyDir.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.EmptyDir.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38138,7 +43182,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38155,7 +43199,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.GCEPersistentDisk == nil { m.GCEPersistentDisk = &GCEPersistentDiskVolumeSource{} } - if err := m.GCEPersistentDisk.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.GCEPersistentDisk.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38171,7 +43215,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38188,7 +43232,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.AWSElasticBlockStore == nil { m.AWSElasticBlockStore = &AWSElasticBlockStoreVolumeSource{} } - if err := m.AWSElasticBlockStore.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.AWSElasticBlockStore.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38204,7 +43248,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38221,7 +43265,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.GitRepo == nil { m.GitRepo = &GitRepoVolumeSource{} } - if err := m.GitRepo.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.GitRepo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38237,7 +43281,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38254,7 +43298,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.Secret == nil { m.Secret = &SecretVolumeSource{} } - if err := m.Secret.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Secret.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38270,7 +43314,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38287,7 +43331,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.NFS == nil { m.NFS = &NFSVolumeSource{} } - if err := m.NFS.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NFS.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38303,7 +43347,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38320,7 +43364,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.ISCSI == nil { m.ISCSI = &ISCSIVolumeSource{} } - if err := m.ISCSI.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ISCSI.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38336,7 +43380,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38353,7 +43397,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.Glusterfs == nil { m.Glusterfs = &GlusterfsVolumeSource{} } - if err := m.Glusterfs.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Glusterfs.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38369,7 +43413,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38386,7 +43430,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.PersistentVolumeClaim == nil { m.PersistentVolumeClaim = &PersistentVolumeClaimVolumeSource{} } - if err := m.PersistentVolumeClaim.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PersistentVolumeClaim.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38402,7 +43446,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38419,7 +43463,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.RBD == nil { m.RBD = &RBDVolumeSource{} } - if err := m.RBD.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RBD.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38435,7 +43479,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38452,7 +43496,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.FlexVolume == nil { m.FlexVolume = &FlexVolumeSource{} } - if err := m.FlexVolume.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FlexVolume.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38468,7 +43512,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38485,7 +43529,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.Cinder == nil { m.Cinder = &CinderVolumeSource{} } - if err := m.Cinder.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Cinder.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38501,7 +43545,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38518,7 +43562,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.CephFS == nil { m.CephFS = &CephFSVolumeSource{} } - if err := m.CephFS.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.CephFS.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38534,7 +43578,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38551,7 +43595,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.Flocker == nil { m.Flocker = &FlockerVolumeSource{} } - if err := m.Flocker.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Flocker.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38567,7 +43611,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38584,7 +43628,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.DownwardAPI == nil { m.DownwardAPI = &DownwardAPIVolumeSource{} } - if err := m.DownwardAPI.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.DownwardAPI.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38600,7 +43644,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38617,7 +43661,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.FC == nil { m.FC = &FCVolumeSource{} } - if err := m.FC.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FC.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38633,7 +43677,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38650,7 +43694,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.AzureFile == nil { m.AzureFile = &AzureFileVolumeSource{} } - if err := m.AzureFile.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.AzureFile.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38666,7 +43710,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38683,7 +43727,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.ConfigMap == nil { m.ConfigMap = &ConfigMapVolumeSource{} } - if err := m.ConfigMap.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ConfigMap.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38699,7 +43743,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38716,7 +43760,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.VsphereVolume == nil { m.VsphereVolume = &VsphereVirtualDiskVolumeSource{} } - if err := m.VsphereVolume.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.VsphereVolume.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38732,7 +43776,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38749,7 +43793,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.Quobyte == nil { m.Quobyte = &QuobyteVolumeSource{} } - if err := m.Quobyte.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Quobyte.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38765,7 +43809,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38782,7 +43826,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.AzureDisk == nil { m.AzureDisk = &AzureDiskVolumeSource{} } - if err := m.AzureDisk.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.AzureDisk.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -38798,7 +43842,7 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -38815,13 +43859,145 @@ func (m *VolumeSource) Unmarshal(data []byte) error { if m.PhotonPersistentDisk == nil { m.PhotonPersistentDisk = &PhotonPersistentDiskVolumeSource{} } - if err := m.PhotonPersistentDisk.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PhotonPersistentDisk.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 24: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PortworxVolume", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.PortworxVolume == nil { + m.PortworxVolume = &PortworxVolumeSource{} + } + if err := m.PortworxVolume.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 25: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ScaleIO", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ScaleIO == nil { + m.ScaleIO = &ScaleIOVolumeSource{} + } + if err := m.ScaleIO.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 26: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Projected", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Projected == nil { + m.Projected = &ProjectedVolumeSource{} + } + if err := m.Projected.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 27: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StorageOS", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.StorageOS == nil { + m.StorageOS = &StorageOSVolumeSource{} + } + if err := m.StorageOS.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -38840,8 +44016,8 @@ func (m *VolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { - l := len(data) +func (m *VsphereVirtualDiskVolumeSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -38853,7 +44029,7 @@ func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -38881,7 +44057,7 @@ func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -38896,7 +44072,7 @@ func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.VolumePath = string(data[iNdEx:postIndex]) + m.VolumePath = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -38910,7 +44086,36 @@ func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.FSType = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StoragePolicyName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -38925,11 +44130,40 @@ func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.FSType = string(data[iNdEx:postIndex]) + m.StoragePolicyName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field StoragePolicyID", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.StoragePolicyID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -38948,8 +44182,8 @@ func (m *VsphereVirtualDiskVolumeSource) Unmarshal(data []byte) error { } return nil } -func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error { - l := len(data) +func (m *WeightedPodAffinityTerm) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -38961,7 +44195,7 @@ func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -38989,7 +44223,7 @@ func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Weight |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -39008,7 +44242,7 @@ func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -39022,13 +44256,13 @@ func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.PodAffinityTerm.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodAffinityTerm.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -39047,8 +44281,8 @@ func (m *WeightedPodAffinityTerm) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -39059,7 +44293,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -39077,7 +44311,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -39094,7 +44328,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -39117,7 +44351,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -39128,7 +44362,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -39152,632 +44386,725 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/api/v1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 10015 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x6c, 0x25, 0xd7, - 0x75, 0x98, 0xe7, 0x3d, 0x7e, 0xbd, 0xc3, 0xcf, 0xbd, 0xfb, 0x21, 0x8a, 0x91, 0x96, 0xeb, 0x91, - 0xb5, 0x5e, 0x49, 0x2b, 0xae, 0x77, 0x25, 0x45, 0xb2, 0xa5, 0xca, 0x26, 0xf9, 0xc8, 0x5d, 0x7a, - 0x97, 0xbb, 0x4f, 0xf7, 0x71, 0xb5, 0xb2, 0xad, 0x4a, 0x1e, 0xbe, 0xb9, 0x24, 0xc7, 0x3b, 0x9c, - 0x79, 0x9a, 0x99, 0xc7, 0x5d, 0xda, 0x0d, 0x90, 0x3a, 0x6a, 0x8a, 0x22, 0x46, 0xea, 0xa2, 0x35, - 0x5a, 0xa0, 0x2d, 0xea, 0x16, 0x68, 0x91, 0x36, 0x68, 0x1a, 0xa7, 0x6e, 0x62, 0xb7, 0x86, 0x51, - 0xa0, 0xa9, 0xe1, 0x7e, 0xa4, 0x70, 0x80, 0xa0, 0x09, 0x12, 0x80, 0x8d, 0x18, 0x14, 0xfd, 0xd1, - 0x1f, 0x2d, 0xd0, 0x5f, 0x25, 0x82, 0xb6, 0xb8, 0x9f, 0x73, 0xef, 0xbc, 0x79, 0x9c, 0x79, 0xd4, - 0x92, 0x51, 0x82, 0xfe, 0x7b, 0xef, 0x9c, 0x73, 0xcf, 0xfd, 0x98, 0x73, 0xcf, 0x3d, 0xf7, 0xdc, - 0x73, 0xcf, 0x85, 0xcb, 0xf7, 0x5f, 0x89, 0xe7, 0xbc, 0xf0, 0xca, 0xfd, 0xce, 0x3a, 0x89, 0x02, - 0x92, 0x90, 0xf8, 0x4a, 0xfb, 0xfe, 0xe6, 0x15, 0xa7, 0xed, 0x5d, 0xd9, 0xb9, 0x7a, 0x65, 0x93, - 0x04, 0x24, 0x72, 0x12, 0xe2, 0xce, 0xb5, 0xa3, 0x30, 0x09, 0xd1, 0x13, 0x9c, 0x7a, 0x2e, 0xa5, - 0x9e, 0x6b, 0xdf, 0xdf, 0x9c, 0x73, 0xda, 0xde, 0xdc, 0xce, 0xd5, 0x99, 0xe7, 0x37, 0xbd, 0x64, - 0xab, 0xb3, 0x3e, 0xd7, 0x0a, 0xb7, 0xaf, 0x6c, 0x86, 0x9b, 0xe1, 0x15, 0x56, 0x68, 0xbd, 0xb3, - 0xc1, 0xfe, 0xb1, 0x3f, 0xec, 0x17, 0x67, 0x36, 0x73, 0xad, 0x77, 0xd5, 0x11, 0x89, 0xc3, 0x4e, - 0xd4, 0x22, 0xd9, 0x06, 0xcc, 0xbc, 0xd4, 0xbb, 0x4c, 0x27, 0xd8, 0x21, 0x51, 0xec, 0x85, 0x01, - 0x71, 0xbb, 0x8a, 0x3d, 0x9f, 0x5f, 0x2c, 0xea, 0x04, 0x89, 0xb7, 0xdd, 0x5d, 0xcb, 0xd5, 0x7c, - 0xf2, 0x4e, 0xe2, 0xf9, 0x57, 0xbc, 0x20, 0x89, 0x93, 0x28, 0x5b, 0xc4, 0xfe, 0x5d, 0x0b, 0x2e, - 0xcc, 0xdf, 0x6b, 0x2e, 0xf9, 0x4e, 0x9c, 0x78, 0xad, 0x05, 0x3f, 0x6c, 0xdd, 0x6f, 0x26, 0x61, - 0x44, 0xde, 0x0c, 0xfd, 0xce, 0x36, 0x69, 0xb2, 0xde, 0xa0, 0xcb, 0x30, 0xb2, 0xc3, 0xfe, 0xaf, - 0xd4, 0xa7, 0xad, 0x0b, 0xd6, 0xa5, 0xda, 0xc2, 0xd4, 0x8f, 0xf7, 0x66, 0x3f, 0xb6, 0xbf, 0x37, - 0x3b, 0xf2, 0xa6, 0x80, 0x63, 0x45, 0x81, 0x2e, 0xc2, 0xd0, 0x46, 0xbc, 0xb6, 0xdb, 0x26, 0xd3, - 0x15, 0x46, 0x3b, 0x21, 0x68, 0x87, 0x96, 0x9b, 0x14, 0x8a, 0x05, 0x16, 0x5d, 0x81, 0x5a, 0xdb, - 0x89, 0x12, 0x2f, 0xf1, 0xc2, 0x60, 0xba, 0x7a, 0xc1, 0xba, 0x34, 0xb8, 0x70, 0x4a, 0x90, 0xd6, - 0x1a, 0x12, 0x81, 0x53, 0x1a, 0xda, 0x8c, 0x88, 0x38, 0xee, 0x9d, 0xc0, 0xdf, 0x9d, 0x1e, 0xb8, - 0x60, 0x5d, 0x1a, 0x49, 0x9b, 0x81, 0x05, 0x1c, 0x2b, 0x0a, 0xfb, 0x7b, 0x15, 0x18, 0x99, 0xdf, - 0xd8, 0xf0, 0x02, 0x2f, 0xd9, 0x45, 0x5f, 0x86, 0xb1, 0x20, 0x74, 0x89, 0xfc, 0xcf, 0x7a, 0x31, - 0x7a, 0xed, 0xd9, 0xb9, 0xc3, 0xe4, 0x62, 0xee, 0xb6, 0x56, 0x62, 0x61, 0x6a, 0x7f, 0x6f, 0x76, - 0x4c, 0x87, 0x60, 0x83, 0x23, 0x7a, 0x1b, 0x46, 0xdb, 0xa1, 0xab, 0x2a, 0xa8, 0xb0, 0x0a, 0x9e, - 0x39, 0xbc, 0x82, 0x46, 0x5a, 0x60, 0x61, 0x72, 0x7f, 0x6f, 0x76, 0x54, 0x03, 0x60, 0x9d, 0x1d, - 0xf2, 0x61, 0x92, 0xfe, 0x0d, 0x12, 0x4f, 0xd5, 0x50, 0x65, 0x35, 0x3c, 0x5f, 0x5c, 0x83, 0x56, - 0x68, 0xe1, 0xf4, 0xfe, 0xde, 0xec, 0x64, 0x06, 0x88, 0xb3, 0xac, 0xed, 0xaf, 0xc2, 0xc4, 0x7c, - 0x92, 0x38, 0xad, 0x2d, 0xe2, 0xf2, 0xef, 0x8b, 0x5e, 0x84, 0x81, 0xc0, 0xd9, 0x26, 0xe2, 0xeb, - 0x5f, 0x10, 0xc3, 0x3e, 0x70, 0xdb, 0xd9, 0x26, 0x07, 0x7b, 0xb3, 0x53, 0x77, 0x03, 0xef, 0xbd, - 0x8e, 0x90, 0x19, 0x0a, 0xc3, 0x8c, 0x1a, 0x5d, 0x03, 0x70, 0xc9, 0x8e, 0xd7, 0x22, 0x0d, 0x27, - 0xd9, 0x12, 0xd2, 0x80, 0x44, 0x59, 0xa8, 0x2b, 0x0c, 0xd6, 0xa8, 0xec, 0xaf, 0x5b, 0x50, 0x9b, - 0xdf, 0x09, 0x3d, 0xb7, 0x11, 0xba, 0x31, 0xea, 0xc0, 0x64, 0x3b, 0x22, 0x1b, 0x24, 0x52, 0xa0, - 0x69, 0xeb, 0x42, 0xf5, 0xd2, 0xe8, 0xb5, 0x6b, 0x05, 0xfd, 0x36, 0x0b, 0x2d, 0x05, 0x49, 0xb4, - 0xbb, 0xf0, 0x98, 0xa8, 0x7a, 0x32, 0x83, 0xc5, 0xd9, 0x3a, 0xec, 0xbf, 0x56, 0x81, 0xb3, 0xf3, - 0x5f, 0xed, 0x44, 0xa4, 0xee, 0xc5, 0xf7, 0xb3, 0x53, 0xc1, 0xf5, 0xe2, 0xfb, 0xb7, 0xd3, 0xc1, - 0x50, 0x32, 0x58, 0x17, 0x70, 0xac, 0x28, 0xd0, 0xf3, 0x30, 0x4c, 0x7f, 0xdf, 0xc5, 0x2b, 0xa2, - 0xf7, 0xa7, 0x05, 0xf1, 0x68, 0xdd, 0x49, 0x9c, 0x3a, 0x47, 0x61, 0x49, 0x83, 0x56, 0x61, 0xb4, - 0xe5, 0xb4, 0xb6, 0xbc, 0x60, 0x73, 0x35, 0x74, 0x09, 0xfb, 0xc2, 0xb5, 0x85, 0xe7, 0x28, 0xf9, - 0x62, 0x0a, 0x3e, 0xd8, 0x9b, 0x9d, 0xe6, 0x6d, 0x13, 0x2c, 0x34, 0x1c, 0xd6, 0xcb, 0x23, 0x5b, - 0x4d, 0xc4, 0x01, 0xc6, 0x09, 0x72, 0x26, 0xe1, 0x25, 0x6d, 0x4e, 0x0d, 0xb2, 0x39, 0x35, 0xd6, - 0x63, 0x3e, 0xfd, 0x13, 0x4b, 0x8c, 0xc9, 0xb2, 0xe7, 0x9b, 0xea, 0xe1, 0x1a, 0x40, 0x4c, 0x5a, - 0x11, 0x49, 0xb4, 0x51, 0x51, 0x9f, 0xb9, 0xa9, 0x30, 0x58, 0xa3, 0xa2, 0x93, 0x3f, 0xde, 0x72, - 0x22, 0x26, 0x2d, 0x62, 0x6c, 0xd4, 0xe4, 0x6f, 0x4a, 0x04, 0x4e, 0x69, 0x8c, 0xc9, 0x5f, 0x2d, - 0x9c, 0xfc, 0xff, 0xd2, 0x82, 0xe1, 0x05, 0x2f, 0x70, 0xbd, 0x60, 0x13, 0xbd, 0x05, 0x23, 0xdb, - 0x24, 0x71, 0x5c, 0x27, 0x71, 0xc4, 0xbc, 0xbf, 0x74, 0xb8, 0xf0, 0xdc, 0x59, 0xff, 0x0a, 0x69, - 0x25, 0xab, 0x24, 0x71, 0xd2, 0x6e, 0xa4, 0x30, 0xac, 0xb8, 0xa1, 0xbb, 0x30, 0x94, 0x38, 0xd1, - 0x26, 0x49, 0xc4, 0x74, 0x7f, 0xbe, 0x0c, 0x5f, 0x4c, 0x45, 0x8d, 0x04, 0x2d, 0x92, 0x2a, 0xc6, - 0x35, 0xc6, 0x04, 0x0b, 0x66, 0x76, 0x0b, 0xc6, 0x16, 0x9d, 0xb6, 0xb3, 0xee, 0xf9, 0x5e, 0xe2, - 0x91, 0x18, 0x7d, 0x12, 0xaa, 0x8e, 0xeb, 0x32, 0xc1, 0xaf, 0x2d, 0x9c, 0xdd, 0xdf, 0x9b, 0xad, - 0xce, 0xbb, 0xee, 0xc1, 0xde, 0x2c, 0x28, 0xaa, 0x5d, 0x4c, 0x29, 0xd0, 0xb3, 0x30, 0xe0, 0x46, - 0x61, 0x7b, 0xba, 0xc2, 0x28, 0xcf, 0xd1, 0x19, 0x5a, 0x8f, 0xc2, 0x76, 0x86, 0x94, 0xd1, 0xd8, - 0xff, 0xb6, 0x02, 0x68, 0x91, 0xb4, 0xb7, 0x96, 0x9b, 0xc6, 0xb7, 0xbc, 0x04, 0x23, 0xdb, 0x61, - 0xe0, 0x25, 0x61, 0x14, 0x8b, 0x0a, 0x99, 0x3c, 0xac, 0x0a, 0x18, 0x56, 0x58, 0x74, 0x01, 0x06, - 0xda, 0xe9, 0xb4, 0x1e, 0x93, 0x2a, 0x81, 0x4d, 0x68, 0x86, 0xa1, 0x14, 0x9d, 0x98, 0x44, 0x42, - 0x8e, 0x15, 0xc5, 0xdd, 0x98, 0x44, 0x98, 0x61, 0x52, 0xc9, 0xa1, 0x32, 0x25, 0xa4, 0x34, 0x23, - 0x39, 0x14, 0x83, 0x35, 0x2a, 0xf4, 0x2e, 0xd4, 0xf8, 0x3f, 0x4c, 0x36, 0x98, 0xc8, 0x16, 0x2a, - 0x83, 0x5b, 0x61, 0xcb, 0xf1, 0xb3, 0x83, 0x3f, 0xce, 0x24, 0x4d, 0x32, 0xc2, 0x29, 0x4f, 0x43, - 0xd2, 0x86, 0x0a, 0x25, 0xed, 0x6f, 0x59, 0x80, 0x16, 0xbd, 0xc0, 0x25, 0xd1, 0x09, 0x2c, 0x99, - 0xfd, 0x4d, 0x82, 0x3f, 0xa0, 0x4d, 0x0b, 0xb7, 0xdb, 0x61, 0x40, 0x82, 0x64, 0x31, 0x0c, 0x5c, - 0xbe, 0x8c, 0x7e, 0x06, 0x06, 0x12, 0x5a, 0x15, 0x6f, 0xd6, 0x45, 0xf9, 0x59, 0x68, 0x05, 0x07, - 0x7b, 0xb3, 0xe7, 0xba, 0x4b, 0xb0, 0x26, 0xb0, 0x32, 0xe8, 0xd3, 0x30, 0x14, 0x27, 0x4e, 0xd2, - 0x89, 0x45, 0x43, 0x3f, 0x2e, 0x1b, 0xda, 0x64, 0xd0, 0x83, 0xbd, 0xd9, 0x49, 0x55, 0x8c, 0x83, - 0xb0, 0x28, 0x80, 0x9e, 0x81, 0xe1, 0x6d, 0x12, 0xc7, 0xce, 0xa6, 0x54, 0x6c, 0x93, 0xa2, 0xec, - 0xf0, 0x2a, 0x07, 0x63, 0x89, 0x47, 0x4f, 0xc1, 0x20, 0x89, 0xa2, 0x30, 0x12, 0x12, 0x31, 0x2e, - 0x08, 0x07, 0x97, 0x28, 0x10, 0x73, 0x9c, 0xfd, 0xdb, 0x16, 0x4c, 0xaa, 0xb6, 0xf2, 0xba, 0x8e, - 0x71, 0xaa, 0xbb, 0x00, 0x2d, 0xd9, 0xb1, 0x98, 0x4d, 0xb0, 0xd1, 0x6b, 0x9f, 0x3a, 0x9c, 0x77, - 0xf7, 0x40, 0xa6, 0x75, 0x28, 0x50, 0x8c, 0x35, 0xbe, 0xf6, 0x8f, 0x2d, 0x38, 0x9d, 0xe9, 0xd3, - 0x2d, 0x2f, 0x4e, 0xd0, 0x9f, 0xef, 0xea, 0xd7, 0x95, 0x43, 0xea, 0xd6, 0x2c, 0xca, 0x39, 0x5a, - 0x9c, 0x75, 0x4f, 0x09, 0x8a, 0x84, 0x68, 0x9d, 0xc3, 0x30, 0xe8, 0x25, 0x64, 0x5b, 0xf6, 0xeb, - 0xf9, 0x92, 0xfd, 0xe2, 0x0d, 0x4c, 0x3f, 0xcf, 0x0a, 0xe5, 0x81, 0x39, 0x2b, 0xfb, 0x7f, 0x59, - 0x50, 0x5b, 0x0c, 0x83, 0x0d, 0x6f, 0x73, 0xd5, 0x69, 0x1f, 0xe3, 0x87, 0x69, 0xc2, 0x00, 0xe3, - 0xca, 0x9b, 0x7e, 0xb5, 0xa8, 0xe9, 0xa2, 0x41, 0x73, 0x74, 0xf1, 0xe4, 0x56, 0x81, 0xd2, 0x4b, - 0x14, 0x84, 0x19, 0xb3, 0x99, 0x97, 0xa1, 0xa6, 0x08, 0xd0, 0x14, 0x54, 0xef, 0x13, 0x6e, 0x32, - 0xd6, 0x30, 0xfd, 0x89, 0xce, 0xc0, 0xe0, 0x8e, 0xe3, 0x77, 0xc4, 0x6c, 0xc5, 0xfc, 0xcf, 0x67, - 0x2a, 0xaf, 0x58, 0xf6, 0x0f, 0x2c, 0x38, 0xa3, 0x2a, 0xb9, 0x49, 0x76, 0x9b, 0xc4, 0x27, 0xad, - 0x24, 0x8c, 0xd0, 0xfb, 0x16, 0x9c, 0xf1, 0x73, 0xf4, 0x90, 0x18, 0x8d, 0xa3, 0x68, 0xb0, 0x27, - 0x44, 0xc3, 0xcf, 0xe4, 0x61, 0x71, 0x6e, 0x6d, 0xe8, 0x49, 0xde, 0x17, 0x3e, 0x79, 0x47, 0x05, - 0x83, 0xea, 0x4d, 0xb2, 0xcb, 0x3a, 0x46, 0x9b, 0x3f, 0xae, 0x9a, 0x7f, 0x12, 0x92, 0x77, 0xcb, - 0x94, 0xbc, 0x4f, 0x96, 0xfc, 0x7c, 0x3d, 0x64, 0xee, 0xef, 0x55, 0xe0, 0xac, 0xa2, 0x31, 0xd4, - 0xf1, 0x47, 0x64, 0xf8, 0xfb, 0xeb, 0xee, 0x4d, 0xb2, 0xbb, 0x16, 0xd2, 0xf5, 0x34, 0xbf, 0xbb, - 0xe8, 0x2a, 0x8c, 0xba, 0x64, 0xc3, 0xe9, 0xf8, 0x89, 0x32, 0x17, 0x07, 0xf9, 0x3e, 0xa2, 0x9e, - 0x82, 0xb1, 0x4e, 0x63, 0xff, 0x56, 0x8d, 0xcd, 0xca, 0xc4, 0xf1, 0x02, 0x12, 0xd1, 0x05, 0x5a, - 0xb3, 0xea, 0xc7, 0x74, 0xab, 0x5e, 0x58, 0xf0, 0x4f, 0xc1, 0xa0, 0xb7, 0x4d, 0x55, 0x76, 0xc5, - 0xd4, 0xc4, 0x2b, 0x14, 0x88, 0x39, 0x0e, 0x3d, 0x0d, 0xc3, 0xad, 0x70, 0x7b, 0xdb, 0x09, 0xdc, - 0xe9, 0x2a, 0x33, 0x19, 0x46, 0xa9, 0x56, 0x5f, 0xe4, 0x20, 0x2c, 0x71, 0xe8, 0x09, 0x18, 0x70, - 0xa2, 0xcd, 0x78, 0x7a, 0x80, 0xd1, 0x8c, 0xd0, 0x9a, 0xe6, 0xa3, 0xcd, 0x18, 0x33, 0x28, 0x35, - 0x05, 0x1e, 0x84, 0xd1, 0x7d, 0x2f, 0xd8, 0xac, 0x7b, 0x11, 0x5b, 0xd7, 0x35, 0x53, 0xe0, 0x9e, - 0xc2, 0x60, 0x8d, 0x0a, 0x35, 0x60, 0xb0, 0x1d, 0x46, 0x49, 0x3c, 0x3d, 0xc4, 0x86, 0xf3, 0xb9, - 0x42, 0xe9, 0xe1, 0xfd, 0x6e, 0x84, 0x51, 0x92, 0x76, 0x85, 0xfe, 0x8b, 0x31, 0x67, 0x84, 0x16, - 0xa1, 0x4a, 0x82, 0x9d, 0xe9, 0x61, 0xc6, 0xef, 0x13, 0x87, 0xf3, 0x5b, 0x0a, 0x76, 0xde, 0x74, - 0xa2, 0x74, 0x16, 0x2d, 0x05, 0x3b, 0x98, 0x96, 0x46, 0x2d, 0xa8, 0x49, 0x47, 0x40, 0x3c, 0x3d, - 0x52, 0x46, 0xc0, 0xb0, 0x20, 0xc7, 0xe4, 0xbd, 0x8e, 0x17, 0x91, 0x6d, 0x12, 0x24, 0x71, 0x6a, - 0x0f, 0x4b, 0x6c, 0x8c, 0x53, 0xbe, 0xa8, 0x05, 0x63, 0xdc, 0x7c, 0x58, 0x0d, 0x3b, 0x41, 0x12, - 0x4f, 0xd7, 0x58, 0x93, 0x0b, 0x36, 0x9c, 0x6f, 0xa6, 0x25, 0x16, 0xce, 0x08, 0xf6, 0x63, 0x1a, - 0x30, 0xc6, 0x06, 0x53, 0xf4, 0x36, 0x8c, 0xfb, 0xde, 0x0e, 0x09, 0x48, 0x1c, 0x37, 0xa2, 0x70, - 0x9d, 0x4c, 0x03, 0xeb, 0xcd, 0x53, 0x45, 0x9b, 0xaf, 0x70, 0x9d, 0x2c, 0x9c, 0xda, 0xdf, 0x9b, - 0x1d, 0xbf, 0xa5, 0x97, 0xc6, 0x26, 0x33, 0xf4, 0x2e, 0x4c, 0x50, 0x5b, 0xc5, 0x4b, 0xd9, 0x8f, - 0x96, 0x67, 0x8f, 0xf6, 0xf7, 0x66, 0x27, 0xb0, 0x51, 0x1c, 0x67, 0xd8, 0xa1, 0x35, 0xa8, 0xf9, - 0xde, 0x06, 0x69, 0xed, 0xb6, 0x7c, 0x32, 0x3d, 0xc6, 0x78, 0x17, 0x4c, 0xb9, 0x5b, 0x92, 0x9c, - 0xdb, 0x87, 0xea, 0x2f, 0x4e, 0x19, 0xa1, 0x37, 0xe1, 0x5c, 0x42, 0xa2, 0x6d, 0x2f, 0x70, 0xe8, - 0xa2, 0x2d, 0x8c, 0x17, 0xb6, 0xc3, 0x1d, 0x67, 0x52, 0x7b, 0x5e, 0x0c, 0xec, 0xb9, 0xb5, 0x5c, - 0x2a, 0xdc, 0xa3, 0x34, 0xba, 0x03, 0x93, 0x6c, 0x3e, 0x35, 0x3a, 0xbe, 0xdf, 0x08, 0x7d, 0xaf, - 0xb5, 0x3b, 0x3d, 0xc1, 0x18, 0x3e, 0x2d, 0xf7, 0xad, 0x2b, 0x26, 0x9a, 0xda, 0xf5, 0xe9, 0x3f, - 0x9c, 0x2d, 0x8d, 0x7c, 0x98, 0x8c, 0x49, 0xab, 0x13, 0x79, 0xc9, 0x2e, 0x95, 0x7d, 0xf2, 0x30, - 0x99, 0x9e, 0x2c, 0xb3, 0x4f, 0x69, 0x9a, 0x85, 0xb8, 0xd3, 0x20, 0x03, 0xc4, 0x59, 0xd6, 0x54, - 0x55, 0xc4, 0x89, 0xeb, 0x05, 0xd3, 0x53, 0xcc, 0x30, 0x55, 0xf3, 0xab, 0x49, 0x81, 0x98, 0xe3, - 0xd8, 0xb6, 0x8f, 0xfe, 0xb8, 0x43, 0x75, 0xef, 0x29, 0x46, 0x98, 0x6e, 0xfb, 0x24, 0x02, 0xa7, - 0x34, 0x74, 0xc1, 0x4a, 0x92, 0xdd, 0x69, 0xc4, 0x48, 0xd5, 0x54, 0x5b, 0x5b, 0xfb, 0x02, 0xa6, - 0x70, 0x7b, 0x1d, 0x26, 0xd4, 0xb4, 0x66, 0xa3, 0x83, 0x66, 0x61, 0x90, 0x6a, 0x2e, 0xb9, 0x7b, - 0xa9, 0xd1, 0x26, 0x50, 0x85, 0x16, 0x63, 0x0e, 0x67, 0x4d, 0xf0, 0xbe, 0x4a, 0x16, 0x76, 0x13, - 0xc2, 0xad, 0xd8, 0xaa, 0xd6, 0x04, 0x89, 0xc0, 0x29, 0x8d, 0xfd, 0x7f, 0xf8, 0xa2, 0x98, 0xea, - 0x8e, 0x12, 0x7a, 0xf3, 0x32, 0x8c, 0x6c, 0x85, 0x71, 0x42, 0xa9, 0x59, 0x1d, 0x83, 0xe9, 0x2a, - 0x78, 0x43, 0xc0, 0xb1, 0xa2, 0x40, 0xaf, 0xc2, 0x78, 0x4b, 0xaf, 0x40, 0xa8, 0xf2, 0xb3, 0xa2, - 0x88, 0x59, 0x3b, 0x36, 0x69, 0xd1, 0x2b, 0x30, 0xc2, 0x5c, 0x79, 0xad, 0xd0, 0x17, 0xf6, 0xb2, - 0x5c, 0x99, 0x46, 0x1a, 0x02, 0x7e, 0xa0, 0xfd, 0xc6, 0x8a, 0x9a, 0xee, 0x3a, 0x68, 0x13, 0x56, - 0x1a, 0x42, 0xdd, 0xaa, 0x5d, 0xc7, 0x0d, 0x06, 0xc5, 0x02, 0x6b, 0xff, 0x6a, 0x45, 0x1b, 0x65, - 0x6a, 0xf4, 0x11, 0xf4, 0x45, 0x18, 0x7e, 0xe0, 0x78, 0x89, 0x17, 0x6c, 0x8a, 0x15, 0xf4, 0x85, - 0x92, 0xba, 0x97, 0x15, 0xbf, 0xc7, 0x8b, 0xf2, 0x75, 0x42, 0xfc, 0xc1, 0x92, 0x21, 0xe5, 0x1d, - 0x75, 0x82, 0x80, 0xf2, 0xae, 0xf4, 0xcf, 0x1b, 0xf3, 0xa2, 0x9c, 0xb7, 0xf8, 0x83, 0x25, 0x43, - 0xb4, 0x01, 0x20, 0x67, 0x1f, 0x71, 0x85, 0x0b, 0xed, 0xa7, 0xfb, 0x61, 0xbf, 0xa6, 0x4a, 0x2f, - 0x4c, 0xd0, 0x95, 0x29, 0xfd, 0x8f, 0x35, 0xce, 0x76, 0x87, 0x19, 0x22, 0xdd, 0xcd, 0x42, 0x6f, - 0xd3, 0x09, 0xe0, 0x44, 0x09, 0x71, 0xe7, 0x13, 0x31, 0x74, 0xcf, 0x95, 0x34, 0xa8, 0xd6, 0xbc, - 0x6d, 0xa2, 0xcf, 0x16, 0xc1, 0x05, 0xa7, 0x0c, 0xed, 0xef, 0x57, 0x61, 0xba, 0x57, 0x7b, 0xa9, - 0x4c, 0x92, 0x87, 0x5e, 0xb2, 0x48, 0x6d, 0x05, 0xcb, 0x94, 0xc9, 0x25, 0x01, 0xc7, 0x8a, 0x82, - 0x0a, 0x47, 0xec, 0x6d, 0x06, 0x8e, 0x2f, 0xe4, 0x57, 0x09, 0x47, 0x93, 0x41, 0xb1, 0xc0, 0x52, - 0xba, 0x88, 0x38, 0xb1, 0x70, 0xe1, 0x6a, 0x42, 0x84, 0x19, 0x14, 0x0b, 0xac, 0xbe, 0xfd, 0x1b, - 0x28, 0xd8, 0xfe, 0x19, 0x63, 0x34, 0xf8, 0x88, 0xc7, 0x08, 0xbd, 0x0b, 0xb0, 0xe1, 0x05, 0x5e, - 0xbc, 0xc5, 0xd8, 0x0f, 0xf5, 0xcf, 0x5e, 0x59, 0x25, 0xcb, 0x8a, 0x0d, 0xd6, 0x58, 0xa2, 0x97, - 0x60, 0x54, 0xcd, 0xd0, 0x95, 0xfa, 0xf4, 0xb0, 0xe9, 0xf8, 0x4b, 0xd5, 0x55, 0x1d, 0xeb, 0x74, - 0xf6, 0x57, 0xb2, 0x22, 0x23, 0x26, 0x86, 0x36, 0xc2, 0x56, 0xd9, 0x11, 0xae, 0x1c, 0x3e, 0xc2, - 0xf6, 0x7f, 0xae, 0xd2, 0xbd, 0xb3, 0x56, 0x59, 0x27, 0x2e, 0xa1, 0xd4, 0xde, 0xa0, 0x1a, 0xde, - 0x49, 0x88, 0x98, 0x96, 0x97, 0xfb, 0x99, 0x37, 0xfa, 0x7a, 0x40, 0xa7, 0x03, 0xe7, 0x84, 0xb6, - 0xa0, 0xe6, 0x3b, 0x31, 0xdb, 0x49, 0x12, 0x31, 0x1d, 0xfb, 0x63, 0x9b, 0x5a, 0xe1, 0x4e, 0x9c, - 0x68, 0x0b, 0x2e, 0xaf, 0x25, 0x65, 0x4e, 0x97, 0x27, 0x6a, 0x1d, 0xc8, 0x93, 0x03, 0xd5, 0x1c, - 0x6a, 0x42, 0xec, 0x62, 0x8e, 0x43, 0xaf, 0xc0, 0x58, 0x44, 0x98, 0xa8, 0x2c, 0x52, 0x03, 0x88, - 0x09, 0xdf, 0x60, 0x6a, 0x29, 0x61, 0x0d, 0x87, 0x0d, 0xca, 0xd4, 0x50, 0x1e, 0x3a, 0xc4, 0x50, - 0x7e, 0x06, 0x86, 0xd9, 0x0f, 0x25, 0x15, 0xea, 0x0b, 0xad, 0x70, 0x30, 0x96, 0xf8, 0xac, 0x10, - 0x8d, 0x94, 0x14, 0xa2, 0x67, 0x61, 0xa2, 0xee, 0x90, 0xed, 0x30, 0x58, 0x0a, 0xdc, 0x76, 0xe8, - 0x05, 0x09, 0x9a, 0x86, 0x01, 0xb6, 0xa4, 0xf0, 0x19, 0x3f, 0x40, 0x39, 0xe0, 0x01, 0x6a, 0xec, - 0xda, 0xff, 0xd7, 0x82, 0xf1, 0x3a, 0xf1, 0x49, 0x42, 0xee, 0xb4, 0x99, 0xfb, 0x01, 0x2d, 0x03, - 0xda, 0x8c, 0x9c, 0x16, 0x69, 0x90, 0xc8, 0x0b, 0xdd, 0x26, 0x69, 0x85, 0x01, 0x73, 0xb8, 0xd3, - 0x35, 0xf2, 0xdc, 0xfe, 0xde, 0x2c, 0xba, 0xde, 0x85, 0xc5, 0x39, 0x25, 0x90, 0x0b, 0xe3, 0xed, - 0x88, 0x18, 0xfe, 0x12, 0xab, 0xd8, 0x3e, 0x6f, 0xe8, 0x45, 0xb8, 0xf9, 0x68, 0x80, 0xb0, 0xc9, - 0x14, 0x7d, 0x0e, 0xa6, 0xc2, 0xa8, 0xbd, 0xe5, 0x04, 0x75, 0xd2, 0x26, 0x81, 0x4b, 0x6d, 0x66, - 0xe1, 0x14, 0x3b, 0xb3, 0xbf, 0x37, 0x3b, 0x75, 0x27, 0x83, 0xc3, 0x5d, 0xd4, 0xf6, 0x2f, 0x57, - 0xe0, 0x6c, 0x3d, 0x7c, 0x10, 0x3c, 0x70, 0x22, 0x77, 0xbe, 0xb1, 0xc2, 0x0d, 0x61, 0xe6, 0x64, - 0x94, 0xce, 0x4d, 0xab, 0xa7, 0x73, 0xf3, 0x4b, 0x30, 0xb2, 0xe1, 0x11, 0xdf, 0xc5, 0x64, 0x43, - 0x74, 0xef, 0x6a, 0x19, 0x8f, 0xc6, 0x32, 0x2d, 0x23, 0xbd, 0x02, 0xdc, 0xb7, 0xba, 0x2c, 0xd8, - 0x60, 0xc5, 0x10, 0x75, 0x60, 0x4a, 0x5a, 0xfa, 0x12, 0x2b, 0x66, 0xc7, 0x0b, 0xe5, 0x36, 0x12, - 0x66, 0x35, 0x6c, 0x3c, 0x70, 0x86, 0x21, 0xee, 0xaa, 0x82, 0xee, 0xd0, 0xb6, 0xe9, 0xea, 0x30, - 0xc0, 0x64, 0x85, 0xed, 0xd0, 0xd8, 0x16, 0x92, 0x41, 0xed, 0x7f, 0x64, 0xc1, 0x63, 0x5d, 0xa3, - 0x25, 0xf6, 0xd7, 0x6f, 0xc9, 0x8d, 0x2d, 0x3f, 0x9d, 0x29, 0x68, 0x65, 0xee, 0x98, 0x97, 0xdb, - 0xe4, 0x56, 0x4a, 0x6c, 0x72, 0xef, 0xc0, 0x99, 0xa5, 0xed, 0x76, 0xb2, 0x5b, 0xf7, 0x4c, 0x9f, - 0xec, 0xcb, 0x30, 0xb4, 0x4d, 0x5c, 0xaf, 0xb3, 0x2d, 0x3e, 0xeb, 0xac, 0x54, 0xa4, 0xab, 0x0c, - 0x7a, 0xb0, 0x37, 0x3b, 0xde, 0x4c, 0xc2, 0xc8, 0xd9, 0x24, 0x1c, 0x80, 0x05, 0xb9, 0xfd, 0x81, - 0x05, 0x93, 0x72, 0x42, 0xcd, 0xbb, 0x6e, 0x44, 0xe2, 0x18, 0xcd, 0x40, 0xc5, 0x6b, 0x0b, 0x46, - 0x20, 0x18, 0x55, 0x56, 0x1a, 0xb8, 0xe2, 0xb5, 0xd1, 0x17, 0xa1, 0xc6, 0x5d, 0xf9, 0xa9, 0x70, - 0xf4, 0x79, 0x34, 0xc0, 0x76, 0x1f, 0x6b, 0x92, 0x07, 0x4e, 0xd9, 0x49, 0xcb, 0x92, 0xa9, 0xea, - 0xaa, 0xe9, 0x58, 0xbe, 0x21, 0xe0, 0x58, 0x51, 0xa0, 0x4b, 0x30, 0x12, 0x84, 0x2e, 0x3f, 0x65, - 0xe1, 0xcb, 0x2e, 0x13, 0xb9, 0xdb, 0x02, 0x86, 0x15, 0xd6, 0xfe, 0x86, 0x05, 0x63, 0xb2, 0x8f, - 0x25, 0x8d, 0x5c, 0x3a, 0x49, 0x52, 0x03, 0x37, 0x9d, 0x24, 0xd4, 0x48, 0x65, 0x18, 0xc3, 0x36, - 0xad, 0xf6, 0x63, 0x9b, 0xda, 0xdf, 0xaf, 0xc0, 0x84, 0x6c, 0x4e, 0xb3, 0xb3, 0x1e, 0x93, 0x04, - 0xbd, 0x03, 0x35, 0x87, 0x0f, 0x3e, 0x91, 0x72, 0xf6, 0x7c, 0xd1, 0x0e, 0xdd, 0xf8, 0x66, 0xa9, - 0x61, 0x30, 0x2f, 0xf9, 0xe0, 0x94, 0x25, 0xda, 0x81, 0x53, 0x41, 0x98, 0xb0, 0xf5, 0x40, 0xe1, - 0xcb, 0x79, 0x44, 0xb3, 0xf5, 0x3c, 0x2e, 0xea, 0x39, 0x75, 0x3b, 0xcb, 0x0f, 0x77, 0x57, 0x81, - 0xee, 0x48, 0x2f, 0x46, 0x95, 0xd5, 0xf5, 0x6c, 0xb9, 0xba, 0x7a, 0x3b, 0x31, 0xec, 0x1f, 0x5a, - 0x50, 0x93, 0x64, 0xc7, 0xe9, 0x13, 0xbf, 0x07, 0xc3, 0x31, 0xfb, 0x34, 0x72, 0x98, 0x2e, 0x97, - 0x6b, 0x3a, 0xff, 0x9e, 0xe9, 0xe2, 0xc7, 0xff, 0xc7, 0x58, 0x72, 0x63, 0x6e, 0x48, 0xd5, 0x81, - 0x8f, 0x9e, 0x1b, 0x52, 0x35, 0xad, 0x87, 0x1b, 0xf2, 0x97, 0x2c, 0x18, 0xe2, 0xce, 0xa1, 0x72, - 0x1e, 0x36, 0xcd, 0x97, 0x9c, 0x72, 0x7c, 0x93, 0x02, 0x85, 0x6b, 0x19, 0xdd, 0x83, 0x1a, 0xfb, - 0xb1, 0x1c, 0x85, 0xdb, 0x62, 0x21, 0x78, 0xb6, 0x8c, 0x73, 0x8a, 0x2b, 0x3e, 0xae, 0x4d, 0xde, - 0x94, 0x0c, 0x70, 0xca, 0xcb, 0xfe, 0x41, 0x95, 0xce, 0xfa, 0x94, 0xd4, 0x58, 0xd6, 0xac, 0x93, - 0x58, 0xd6, 0x2a, 0xc7, 0xbf, 0xac, 0xbd, 0x07, 0x93, 0x2d, 0xcd, 0x27, 0x9f, 0x2e, 0xa6, 0xd7, - 0x4a, 0xba, 0x9b, 0x35, 0x47, 0x3e, 0x77, 0x86, 0x2c, 0x9a, 0xec, 0x70, 0x96, 0x3f, 0x22, 0x30, - 0xc6, 0x0f, 0x14, 0x45, 0x7d, 0x03, 0x85, 0x32, 0xcb, 0xfd, 0x2e, 0xbc, 0x84, 0xaa, 0x8c, 0x05, - 0x9d, 0x34, 0x35, 0x46, 0xd8, 0x60, 0x6b, 0xff, 0x8d, 0x41, 0x18, 0x5c, 0xda, 0x21, 0x41, 0x72, - 0x8c, 0xb3, 0x7c, 0x1b, 0x26, 0xbc, 0x60, 0x27, 0xf4, 0x77, 0x88, 0xcb, 0xf1, 0x47, 0x5b, 0xd1, - 0xce, 0x89, 0x4a, 0x26, 0x56, 0x0c, 0x66, 0x38, 0xc3, 0xfc, 0x38, 0xf6, 0x93, 0x6f, 0xc0, 0x10, - 0x97, 0x08, 0xb1, 0x99, 0x2c, 0x70, 0x92, 0xb2, 0x01, 0x15, 0x33, 0x27, 0xdd, 0xf5, 0x72, 0xff, - 0xac, 0x60, 0x84, 0xee, 0xc3, 0xc4, 0x86, 0x17, 0xc5, 0x09, 0xdd, 0x10, 0xc6, 0x89, 0xb3, 0xdd, - 0x3e, 0xca, 0x46, 0x52, 0x0d, 0xc9, 0xb2, 0xc1, 0x0a, 0x67, 0x58, 0xa3, 0x2d, 0x18, 0xa7, 0xfb, - 0x98, 0xb4, 0xae, 0xe1, 0xfe, 0xeb, 0x52, 0xbe, 0xa4, 0x5b, 0x3a, 0x27, 0x6c, 0x32, 0xa6, 0xca, - 0xa8, 0xc5, 0x36, 0x3e, 0x23, 0x6c, 0x49, 0x57, 0xca, 0x88, 0xef, 0x78, 0x38, 0x8e, 0xea, 0x34, - 0x76, 0x7e, 0x5c, 0x33, 0x75, 0x5a, 0x7a, 0x4a, 0x6c, 0x7f, 0x97, 0x2e, 0x40, 0x74, 0x14, 0x4f, - 0x42, 0x77, 0xdf, 0x30, 0x75, 0xf7, 0x53, 0x25, 0x3e, 0x6e, 0x0f, 0xbd, 0xfd, 0x65, 0x18, 0xd5, - 0xbe, 0x3d, 0xba, 0x02, 0xb5, 0x96, 0x3c, 0xea, 0x14, 0x0a, 0x5c, 0x19, 0x10, 0xea, 0x0c, 0x14, - 0xa7, 0x34, 0x74, 0x60, 0xa8, 0xe1, 0x95, 0x8d, 0x88, 0xa0, 0x66, 0x19, 0x66, 0x18, 0xfb, 0x05, - 0x80, 0xa5, 0x87, 0xa4, 0x35, 0xdf, 0x62, 0x07, 0xf1, 0xda, 0xb9, 0x89, 0xd5, 0xfb, 0xdc, 0xc4, - 0x7e, 0x1b, 0xc6, 0x97, 0x1e, 0xd2, 0x95, 0x5d, 0x6e, 0xd3, 0x2e, 0xc2, 0x10, 0x61, 0x00, 0xd6, - 0xaa, 0x91, 0x54, 0x48, 0x39, 0x19, 0x16, 0x58, 0x76, 0x8c, 0xfe, 0xd0, 0x11, 0x13, 0x56, 0xdb, - 0xf2, 0x2e, 0x51, 0x20, 0xe6, 0x38, 0xfb, 0x3b, 0x16, 0x4c, 0x2c, 0x2f, 0x1a, 0x76, 0xf2, 0x1c, - 0x00, 0xb7, 0x37, 0xef, 0xdd, 0xbb, 0x2d, 0xfd, 0xa8, 0xdc, 0xd9, 0xa5, 0xa0, 0x58, 0xa3, 0x40, - 0x8f, 0x43, 0xd5, 0xef, 0x04, 0xc2, 0x0c, 0x1c, 0xde, 0xdf, 0x9b, 0xad, 0xde, 0xea, 0x04, 0x98, - 0xc2, 0xb4, 0xc0, 0x86, 0x6a, 0xe9, 0xc0, 0x86, 0xe2, 0xd0, 0xbe, 0x6f, 0x55, 0x61, 0x6a, 0xd9, - 0x27, 0x0f, 0x8d, 0x56, 0x5f, 0x84, 0x21, 0x37, 0xf2, 0x76, 0x48, 0x94, 0x75, 0x93, 0xd4, 0x19, - 0x14, 0x0b, 0x6c, 0xe9, 0x58, 0x0b, 0x23, 0xce, 0xa4, 0x7a, 0xcc, 0x71, 0x26, 0x85, 0x7d, 0x46, - 0x1b, 0x30, 0x1c, 0xf2, 0xef, 0x3f, 0x3d, 0xc8, 0x04, 0xfd, 0xd5, 0xc3, 0x1b, 0x93, 0x1d, 0x9f, - 0x39, 0x21, 0x3d, 0xfc, 0xd0, 0x5b, 0x29, 0x4b, 0x01, 0xc5, 0x92, 0xf9, 0xcc, 0x67, 0x60, 0x4c, - 0xa7, 0xec, 0xeb, 0xf4, 0xfb, 0xe7, 0x2c, 0x38, 0xbd, 0xec, 0x87, 0xad, 0xfb, 0x99, 0x60, 0x98, - 0x97, 0x60, 0x94, 0x4e, 0xd5, 0xd8, 0x88, 0x10, 0x33, 0x42, 0xe1, 0x04, 0x0a, 0xeb, 0x74, 0x5a, - 0xb1, 0xbb, 0x77, 0x57, 0xea, 0x79, 0x11, 0x74, 0x02, 0x85, 0x75, 0x3a, 0xfb, 0x3f, 0x59, 0xf0, - 0xe4, 0xf5, 0xc5, 0xa5, 0x06, 0x55, 0x23, 0x71, 0x42, 0x82, 0xa4, 0x2b, 0x88, 0xef, 0x22, 0x0c, - 0xb5, 0x5d, 0xad, 0x29, 0x4a, 0x04, 0x1a, 0x75, 0xd6, 0x0a, 0x81, 0xfd, 0xa8, 0x44, 0xb2, 0xfe, - 0x92, 0x05, 0xa7, 0xaf, 0x7b, 0x09, 0x26, 0xed, 0x30, 0x1b, 0x77, 0x17, 0x91, 0x76, 0x18, 0x7b, - 0x49, 0x18, 0xed, 0x66, 0xe3, 0xee, 0xb0, 0xc2, 0x60, 0x8d, 0x8a, 0xd7, 0xbc, 0xe3, 0x51, 0x05, - 0x2b, 0x3a, 0xa5, 0xd5, 0xcc, 0xe1, 0x58, 0x51, 0xd0, 0x8e, 0xb9, 0x5e, 0xc4, 0x6c, 0x91, 0x5d, - 0x31, 0x83, 0x55, 0xc7, 0xea, 0x12, 0x81, 0x53, 0x1a, 0xfb, 0xef, 0x58, 0x70, 0xf6, 0xba, 0xdf, - 0x89, 0x13, 0x12, 0x6d, 0xc4, 0x46, 0x63, 0x5f, 0x80, 0x1a, 0x91, 0x76, 0xb3, 0x68, 0xab, 0x5a, - 0x93, 0x94, 0x41, 0xcd, 0x83, 0xfe, 0x14, 0x5d, 0x89, 0x18, 0xb3, 0xfe, 0x22, 0xa2, 0xfe, 0x55, - 0x05, 0xc6, 0x6f, 0xac, 0xad, 0x35, 0xae, 0x93, 0x44, 0xe8, 0xe0, 0x62, 0x47, 0x4f, 0x43, 0xdb, - 0xe5, 0x8e, 0x5e, 0x9b, 0xeb, 0x31, 0xeb, 0x3a, 0x89, 0xe7, 0xcf, 0xf1, 0x18, 0xeb, 0xb9, 0x95, - 0x20, 0xb9, 0x13, 0x35, 0x93, 0xc8, 0x0b, 0x36, 0x73, 0x77, 0xc5, 0x72, 0x9d, 0xa8, 0xf6, 0x5a, - 0x27, 0xd0, 0x0b, 0x30, 0x14, 0xb7, 0xb6, 0x88, 0xda, 0xb4, 0xff, 0x94, 0x32, 0x43, 0x18, 0xf4, - 0x60, 0x6f, 0xb6, 0x76, 0x17, 0xaf, 0xf0, 0x3f, 0x58, 0x90, 0xa2, 0x77, 0x61, 0x74, 0x2b, 0x49, - 0xda, 0x37, 0x88, 0xe3, 0x92, 0x48, 0x6a, 0x89, 0x02, 0x2b, 0x90, 0x0e, 0x06, 0x2f, 0x90, 0x4e, - 0xac, 0x14, 0x16, 0x63, 0x9d, 0xa3, 0xdd, 0x04, 0x48, 0x71, 0x8f, 0x68, 0x6b, 0x63, 0xff, 0xc5, - 0x0a, 0x0c, 0xdf, 0x70, 0x02, 0xd7, 0x27, 0x11, 0x5a, 0x86, 0x01, 0xf2, 0x90, 0xb4, 0xca, 0x19, - 0xb0, 0xe9, 0x42, 0xca, 0x3d, 0x55, 0xf4, 0x3f, 0x66, 0xe5, 0x11, 0x86, 0x61, 0xda, 0xee, 0xeb, - 0x2a, 0x30, 0xf3, 0xb9, 0xe2, 0x51, 0x50, 0x22, 0xc1, 0x57, 0x61, 0x01, 0xc2, 0x92, 0x11, 0xf3, - 0xe9, 0xb4, 0xda, 0x4d, 0xaa, 0xdc, 0x92, 0x72, 0xb1, 0xd7, 0x6b, 0x8b, 0x0d, 0x4e, 0x2e, 0xf8, - 0x72, 0x9f, 0x8e, 0x04, 0xe2, 0x94, 0x9d, 0xfd, 0x0a, 0x9c, 0x61, 0xa7, 0x82, 0x4e, 0xb2, 0x65, - 0xcc, 0x99, 0x42, 0xe1, 0xb4, 0xff, 0x7e, 0x05, 0x4e, 0xad, 0x34, 0x17, 0x9b, 0xa6, 0x37, 0xee, - 0x15, 0x18, 0xe3, 0xcb, 0x33, 0x15, 0x3a, 0xc7, 0x17, 0xe5, 0x95, 0x1b, 0x7b, 0x4d, 0xc3, 0x61, - 0x83, 0x12, 0x3d, 0x09, 0x55, 0xef, 0xbd, 0x20, 0x1b, 0x1f, 0xb4, 0xf2, 0xc6, 0x6d, 0x4c, 0xe1, - 0x14, 0x4d, 0x57, 0x7a, 0xae, 0xe2, 0x14, 0x5a, 0xad, 0xf6, 0xaf, 0xc3, 0x84, 0x17, 0xb7, 0x62, - 0x6f, 0x25, 0xa0, 0xf3, 0xdf, 0x69, 0x49, 0xf1, 0x4d, 0x6d, 0x7f, 0xda, 0x54, 0x85, 0xc5, 0x19, - 0x6a, 0x4d, 0xdf, 0x0e, 0x96, 0xb6, 0x16, 0x8a, 0x23, 0x34, 0xbf, 0x02, 0x35, 0x15, 0x49, 0x23, - 0x03, 0xa0, 0xac, 0xfc, 0x00, 0xa8, 0x12, 0x0a, 0x47, 0xfa, 0x48, 0xab, 0xb9, 0x3e, 0xd2, 0x7f, - 0x6a, 0x41, 0x1a, 0x34, 0x80, 0x30, 0xd4, 0xda, 0x21, 0x3b, 0x80, 0x88, 0xe4, 0x61, 0xdf, 0xd3, - 0x05, 0x92, 0xc8, 0x67, 0x02, 0x97, 0x95, 0x86, 0x2c, 0x8b, 0x53, 0x36, 0xe8, 0x16, 0x0c, 0xb7, - 0x23, 0xd2, 0x4c, 0x58, 0x98, 0x6f, 0x1f, 0x1c, 0x99, 0x54, 0x37, 0x78, 0x49, 0x2c, 0x59, 0xd8, - 0xbf, 0x6e, 0x01, 0xdc, 0xf2, 0xb6, 0xbd, 0x04, 0x3b, 0xc1, 0x26, 0x39, 0xc6, 0x5d, 0xe4, 0x6d, - 0x18, 0x88, 0xdb, 0xa4, 0x55, 0xee, 0xe8, 0x28, 0x6d, 0x51, 0xb3, 0x4d, 0x5a, 0xe9, 0x67, 0xa0, - 0xff, 0x30, 0xe3, 0x63, 0xff, 0x0a, 0xc0, 0x44, 0x4a, 0x46, 0xcd, 0x78, 0xf4, 0xbc, 0x11, 0xd7, - 0xfa, 0x78, 0x26, 0xae, 0xb5, 0xc6, 0xa8, 0xb5, 0x50, 0xd6, 0x04, 0xaa, 0xdb, 0xce, 0x43, 0xb1, - 0x6b, 0x78, 0xa9, 0x6c, 0x83, 0x68, 0x4d, 0x73, 0xab, 0xce, 0x43, 0x6e, 0x46, 0x3d, 0x27, 0x05, - 0x68, 0xd5, 0x79, 0x78, 0xc0, 0x0f, 0x88, 0xd8, 0x0c, 0xa4, 0xdb, 0x94, 0xaf, 0xff, 0x97, 0xf4, - 0x3f, 0x53, 0x8a, 0xb4, 0x3a, 0x56, 0xab, 0x17, 0x08, 0x57, 0x5f, 0x9f, 0xb5, 0x7a, 0x41, 0xb6, - 0x56, 0x2f, 0x28, 0x51, 0xab, 0x17, 0xa0, 0xf7, 0x2d, 0x18, 0x16, 0x1e, 0x72, 0x16, 0x7e, 0x35, - 0x7a, 0xed, 0xd3, 0x7d, 0x55, 0x2d, 0x5c, 0xed, 0xbc, 0xfa, 0x2b, 0xd2, 0x76, 0x14, 0xd0, 0xc2, - 0x26, 0xc8, 0xaa, 0xd1, 0xb7, 0x2d, 0x98, 0x10, 0xbf, 0x31, 0x79, 0xaf, 0x43, 0xe2, 0x44, 0xac, - 0x52, 0x9f, 0x3b, 0x4a, 0x6b, 0x04, 0x0b, 0xde, 0xa8, 0x9f, 0x96, 0x2a, 0xc6, 0x44, 0x16, 0xb6, - 0x2d, 0xd3, 0x1e, 0xf4, 0x3d, 0x0b, 0xce, 0x6c, 0x3b, 0x0f, 0x79, 0x8d, 0x1c, 0x86, 0x9d, 0xc4, - 0x0b, 0x45, 0x88, 0xd9, 0x72, 0xbf, 0x72, 0xd2, 0xc5, 0x88, 0x37, 0xf7, 0x35, 0x79, 0x6c, 0x99, - 0x47, 0x52, 0xd8, 0xe8, 0xdc, 0x16, 0xce, 0xb8, 0x30, 0x22, 0x05, 0x33, 0xc7, 0x6a, 0x5f, 0xd0, - 0x17, 0xe3, 0xc3, 0x67, 0xa0, 0x74, 0xa0, 0xcd, 0xbd, 0xd1, 0x71, 0x82, 0xc4, 0x4b, 0x76, 0x35, - 0x1b, 0x9f, 0xd5, 0x22, 0x04, 0xf1, 0x18, 0x6b, 0xd9, 0x82, 0x31, 0x5d, 0xe6, 0x8e, 0xb1, 0xa6, - 0x10, 0x4e, 0xe7, 0xc8, 0xd3, 0x31, 0x56, 0xd8, 0x81, 0xc7, 0x7b, 0xca, 0xc5, 0xf1, 0x55, 0x6b, - 0xff, 0xd0, 0xd2, 0x15, 0xe6, 0x49, 0x38, 0x66, 0x56, 0x4d, 0xc7, 0xcc, 0xa5, 0xb2, 0x53, 0xa7, - 0x87, 0x77, 0x66, 0x43, 0x6f, 0x3f, 0x5d, 0x09, 0xd0, 0x1a, 0x0c, 0xf9, 0x14, 0x22, 0x4f, 0x83, - 0x2e, 0xf7, 0x33, 0x39, 0x53, 0xe3, 0x82, 0xc1, 0x63, 0x2c, 0x78, 0xd9, 0xbf, 0x61, 0xc1, 0xc0, - 0x49, 0x0c, 0x4f, 0xc3, 0x1c, 0x9e, 0x5e, 0x26, 0xaa, 0xb8, 0xeb, 0x39, 0x87, 0x9d, 0x07, 0x4b, - 0x0f, 0x13, 0x12, 0xc4, 0xcc, 0x94, 0xcc, 0x1d, 0xa1, 0x5f, 0xae, 0xc0, 0x28, 0xad, 0x48, 0xfa, - 0x89, 0x5e, 0x85, 0x71, 0xdf, 0x59, 0x27, 0xbe, 0x74, 0x27, 0x67, 0xb7, 0x5d, 0xb7, 0x74, 0x24, - 0x36, 0x69, 0x69, 0xe1, 0x0d, 0xdd, 0xdb, 0x2e, 0x4c, 0x22, 0x55, 0xd8, 0x70, 0xc5, 0x63, 0x93, - 0x96, 0x5a, 0xfe, 0x0f, 0x9c, 0xa4, 0xb5, 0x25, 0xb6, 0x64, 0xaa, 0xb9, 0xf7, 0x28, 0x10, 0x73, - 0x1c, 0x9a, 0x87, 0x49, 0x29, 0xb1, 0x6f, 0xf2, 0xa1, 0x13, 0xe6, 0xa2, 0xba, 0xa7, 0x87, 0x4d, - 0x34, 0xce, 0xd2, 0xa3, 0xcf, 0xc0, 0x04, 0x1d, 0x9c, 0xb0, 0x93, 0xc8, 0x60, 0x85, 0x41, 0x16, - 0xac, 0xc0, 0x82, 0x43, 0xd7, 0x0c, 0x0c, 0xce, 0x50, 0xda, 0xef, 0xc2, 0xe9, 0x5b, 0xa1, 0xe3, - 0x2e, 0x38, 0xbe, 0x13, 0xb4, 0x48, 0xb4, 0x12, 0x6c, 0x16, 0x9e, 0xeb, 0xea, 0x67, 0xaf, 0x95, - 0xa2, 0xb3, 0x57, 0x3b, 0x02, 0xa4, 0x57, 0x20, 0xc2, 0x6c, 0xde, 0x86, 0x61, 0x8f, 0x57, 0x25, - 0xa4, 0xf6, 0x6a, 0x91, 0x53, 0xa9, 0xab, 0x8d, 0x5a, 0xd8, 0x08, 0x07, 0x60, 0xc9, 0x92, 0xee, - 0x24, 0xf2, 0xbc, 0x50, 0xc5, 0x9b, 0x35, 0xfb, 0xaf, 0x58, 0x30, 0x79, 0x3b, 0x73, 0x19, 0xec, - 0x22, 0x0c, 0xc5, 0x24, 0xca, 0x71, 0xa9, 0x35, 0x19, 0x14, 0x0b, 0xec, 0x23, 0xdf, 0xa6, 0xff, - 0x42, 0x05, 0x6a, 0x2c, 0x66, 0xb3, 0xed, 0xb4, 0x8e, 0xd3, 0x28, 0x5d, 0x35, 0x8c, 0xd2, 0x82, - 0x4d, 0xa2, 0x6a, 0x50, 0x2f, 0x9b, 0x14, 0xdd, 0x55, 0x97, 0xa3, 0x4a, 0xed, 0x0f, 0x53, 0x86, - 0xfc, 0x1e, 0xcd, 0x84, 0x79, 0x97, 0x4a, 0x5e, 0x9c, 0x62, 0xa7, 0xa1, 0x8a, 0xf6, 0xa3, 0x77, - 0x1a, 0xaa, 0x9a, 0xd6, 0x43, 0x2b, 0x35, 0xb4, 0xd6, 0x33, 0xb5, 0xfd, 0x59, 0x16, 0x80, 0xe7, - 0xf8, 0xde, 0x57, 0x89, 0xba, 0x64, 0x38, 0x2b, 0xe2, 0xe9, 0x04, 0xf4, 0x80, 0x29, 0x18, 0xf1, - 0x8f, 0xdf, 0x1d, 0x4d, 0x8b, 0xd8, 0x37, 0x60, 0x32, 0x33, 0x76, 0xe8, 0x25, 0x18, 0x6c, 0x6f, - 0x39, 0x31, 0xc9, 0x44, 0x76, 0x0c, 0x36, 0x28, 0xf0, 0x60, 0x6f, 0x76, 0x42, 0x15, 0x60, 0x10, - 0xcc, 0xa9, 0xed, 0x3f, 0xb6, 0x60, 0xe0, 0x76, 0xe8, 0x1e, 0xa7, 0x8c, 0xdd, 0x30, 0x64, 0xec, - 0x62, 0xf1, 0x8d, 0xf3, 0x9e, 0xe2, 0xd5, 0xc8, 0x88, 0xd7, 0xa5, 0x12, 0xbc, 0x0e, 0x97, 0xac, - 0x6d, 0x18, 0x65, 0x37, 0xda, 0x45, 0x48, 0xcb, 0x0b, 0xc6, 0x06, 0x6a, 0x36, 0xb3, 0x81, 0x9a, - 0xd4, 0x48, 0xb5, 0x6d, 0xd4, 0x33, 0x30, 0x2c, 0x42, 0x28, 0xb2, 0x51, 0x87, 0x82, 0x16, 0x4b, - 0xbc, 0xfd, 0x6b, 0x55, 0x30, 0x6e, 0xd0, 0xa3, 0x1f, 0x59, 0x30, 0x17, 0xf1, 0x2b, 0x0f, 0x6e, - 0xbd, 0x13, 0x79, 0xc1, 0x66, 0xb3, 0xb5, 0x45, 0xdc, 0x8e, 0xef, 0x05, 0x9b, 0x2b, 0x9b, 0x41, - 0xa8, 0xc0, 0x4b, 0x0f, 0x49, 0xab, 0xc3, 0xbc, 0xab, 0xa5, 0x2f, 0xee, 0xab, 0x33, 0xd4, 0x6b, - 0xfb, 0x7b, 0xb3, 0x73, 0xb8, 0xaf, 0x5a, 0x70, 0x9f, 0xad, 0x42, 0xbf, 0x67, 0xc1, 0x15, 0x7e, - 0x87, 0xbc, 0x7c, 0x4f, 0x4a, 0x6d, 0x3c, 0x1b, 0x92, 0x69, 0xca, 0x6e, 0x8d, 0x44, 0xdb, 0x0b, - 0x2f, 0x8b, 0x41, 0xbe, 0xd2, 0xe8, 0xaf, 0x56, 0xdc, 0x6f, 0x33, 0xed, 0x7f, 0x53, 0x85, 0x71, - 0x3a, 0x9e, 0xe9, 0xfd, 0xd1, 0x97, 0x0c, 0x31, 0xf9, 0x78, 0x46, 0x4c, 0x4e, 0x19, 0xc4, 0x8f, - 0xe6, 0xea, 0x68, 0x02, 0xa7, 0x7c, 0x27, 0x4e, 0x6e, 0x10, 0x27, 0x4a, 0xd6, 0x89, 0xc3, 0x0e, - 0x2c, 0xc5, 0x24, 0xe8, 0xeb, 0x10, 0x54, 0xc5, 0xe5, 0xdc, 0xca, 0x72, 0xc3, 0xdd, 0x15, 0xa0, - 0x07, 0x80, 0xd8, 0xe9, 0x68, 0xe4, 0x04, 0x31, 0xef, 0x8c, 0x27, 0x1c, 0xb2, 0x7d, 0x56, 0x3b, - 0x23, 0xaa, 0x45, 0xb7, 0xba, 0xd8, 0xe1, 0x9c, 0x2a, 0xb4, 0x23, 0xf0, 0xc1, 0xb2, 0x47, 0xe0, - 0x43, 0x05, 0x01, 0xbf, 0x3f, 0x6f, 0xc1, 0x69, 0xfa, 0x61, 0xcc, 0xe0, 0xd0, 0x18, 0x85, 0x30, - 0x49, 0x7b, 0xe0, 0x93, 0x44, 0xc2, 0xc4, 0x0c, 0x2b, 0xb0, 0xa5, 0x4d, 0x3e, 0xa9, 0xc5, 0x76, - 0xd3, 0x64, 0x86, 0xb3, 0xdc, 0xed, 0x5f, 0xb3, 0x80, 0x45, 0x9f, 0x9d, 0xc4, 0x3a, 0x76, 0xdd, - 0x5c, 0xc7, 0xec, 0x62, 0xa5, 0xd1, 0x63, 0x09, 0x7b, 0x11, 0xa6, 0x28, 0xb6, 0x11, 0x85, 0x0f, - 0x77, 0xa5, 0x71, 0x5d, 0xec, 0x9b, 0xfd, 0xcb, 0x16, 0x57, 0x77, 0xca, 0x2a, 0x7e, 0x00, 0xa7, - 0x02, 0xed, 0x3f, 0x9d, 0xc8, 0xd2, 0x08, 0x9c, 0x2b, 0xaf, 0xd0, 0xd8, 0xfc, 0xd7, 0x22, 0xcc, - 0x32, 0x0c, 0x71, 0x77, 0x1d, 0xf6, 0x3f, 0xb0, 0xe0, 0x31, 0x9d, 0x50, 0xbb, 0x66, 0x56, 0xe4, - 0x10, 0xad, 0xc3, 0x48, 0xd8, 0x26, 0x91, 0x93, 0xee, 0x00, 0x2e, 0xc9, 0x11, 0xbf, 0x23, 0xe0, - 0x07, 0x7b, 0xb3, 0x67, 0x74, 0xee, 0x12, 0x8e, 0x55, 0x49, 0x64, 0xc3, 0x10, 0xdb, 0x89, 0xc6, - 0xe2, 0x82, 0x20, 0xcb, 0x44, 0xc1, 0x8e, 0x01, 0x62, 0x2c, 0x30, 0xf6, 0x5f, 0xb5, 0xf8, 0x28, - 0xeb, 0x4d, 0x47, 0x5f, 0x83, 0xa9, 0x6d, 0xba, 0x59, 0x58, 0x7a, 0xd8, 0xa6, 0x4b, 0x08, 0x3b, - 0xfe, 0xb4, 0xca, 0x28, 0xce, 0x1e, 0xdd, 0x5d, 0x98, 0x16, 0xad, 0x9f, 0x5a, 0xcd, 0xb0, 0xc5, - 0x5d, 0x15, 0xd9, 0xbf, 0x2f, 0x64, 0x95, 0x59, 0x2d, 0xcf, 0xc0, 0x70, 0x3b, 0x74, 0x17, 0x57, - 0xea, 0x58, 0x8c, 0x95, 0x9a, 0x6c, 0x0d, 0x0e, 0xc6, 0x12, 0x8f, 0xae, 0x01, 0x90, 0x87, 0x09, - 0x89, 0x02, 0xc7, 0x57, 0xc7, 0x96, 0xca, 0x48, 0x58, 0x52, 0x18, 0xac, 0x51, 0xd1, 0x32, 0xed, - 0x28, 0xdc, 0xf1, 0x5c, 0x16, 0xee, 0x5d, 0x35, 0xcb, 0x34, 0x14, 0x06, 0x6b, 0x54, 0x74, 0x8b, - 0xd6, 0x09, 0x62, 0xae, 0xc0, 0x9d, 0x75, 0x91, 0x40, 0x61, 0x24, 0xdd, 0xa2, 0xdd, 0xd5, 0x91, - 0xd8, 0xa4, 0xb5, 0x7f, 0xbb, 0x06, 0x90, 0x9a, 0x08, 0xe8, 0x7d, 0x0b, 0x46, 0x5a, 0x4e, 0xdb, - 0x69, 0xf1, 0xec, 0x38, 0xd5, 0xe2, 0x7b, 0x31, 0x69, 0xe1, 0xb9, 0x45, 0x51, 0x90, 0xfb, 0xb6, - 0x3e, 0x25, 0x05, 0x44, 0x82, 0x0b, 0xfd, 0x59, 0xaa, 0x66, 0xf4, 0x4d, 0x0b, 0x46, 0x1d, 0xdf, - 0x0f, 0x5b, 0x4e, 0xc2, 0x7a, 0x54, 0x29, 0xe3, 0xac, 0xd4, 0x5a, 0x32, 0x9f, 0x96, 0xe5, 0x8d, - 0x79, 0x41, 0x9e, 0x6a, 0x69, 0x98, 0xc2, 0xf6, 0xe8, 0x4d, 0x40, 0x9f, 0x92, 0xa6, 0x25, 0xff, - 0x28, 0x33, 0x59, 0xd3, 0xb2, 0xc6, 0x54, 0x83, 0x66, 0x55, 0xa2, 0x77, 0x8d, 0x5c, 0x01, 0x03, - 0x65, 0xee, 0xa6, 0x1a, 0x8b, 0x66, 0x51, 0x9a, 0x00, 0xf4, 0x45, 0x3d, 0x12, 0x76, 0xb0, 0xcc, - 0xc5, 0x4f, 0xcd, 0x76, 0x2b, 0x88, 0x82, 0x4d, 0x60, 0xd2, 0x35, 0x17, 0x09, 0x11, 0xda, 0x74, - 0xb5, 0xb8, 0x86, 0xcc, 0xea, 0x92, 0x2e, 0x0b, 0x19, 0x04, 0xce, 0x56, 0x81, 0xbe, 0xc8, 0xe3, - 0x94, 0x57, 0x82, 0x8d, 0x50, 0x44, 0x37, 0x5d, 0x2e, 0xf1, 0xcd, 0x77, 0xe3, 0x84, 0x6c, 0xd3, - 0x32, 0xe9, 0x32, 0x70, 0x5b, 0x70, 0xc1, 0x8a, 0x1f, 0x5a, 0x83, 0x21, 0x76, 0xab, 0x22, 0x9e, - 0x1e, 0x29, 0xe3, 0x26, 0x32, 0xef, 0x13, 0xa6, 0x8b, 0x2f, 0xfb, 0x1b, 0x63, 0xc1, 0x0b, 0xdd, - 0x90, 0xf7, 0x6f, 0xe3, 0x95, 0xe0, 0x6e, 0x4c, 0xd8, 0xfd, 0xdb, 0xda, 0xc2, 0x27, 0xd2, 0x0b, - 0xb5, 0x1c, 0x9e, 0x9b, 0x1d, 0xc9, 0x28, 0x49, 0xd7, 0x60, 0xf1, 0x5f, 0x26, 0x5d, 0x9a, 0x86, - 0x32, 0x0d, 0x35, 0x53, 0x34, 0xa5, 0x83, 0xfd, 0xa6, 0xc9, 0x0c, 0x67, 0xb9, 0xcf, 0x78, 0x30, - 0x6e, 0xcc, 0xd8, 0x63, 0x74, 0x76, 0xfa, 0x30, 0x95, 0x9d, 0x92, 0xc7, 0xe8, 0xe3, 0xfc, 0xa3, - 0x01, 0x98, 0x30, 0x05, 0x03, 0x5d, 0x81, 0xda, 0x36, 0x4b, 0x89, 0x94, 0x26, 0x62, 0x51, 0xf2, - 0xbf, 0x2a, 0x11, 0x38, 0xa5, 0x61, 0x29, 0x69, 0x58, 0x71, 0x2d, 0xe6, 0x24, 0x4d, 0x49, 0xa3, - 0x30, 0x58, 0xa3, 0xa2, 0x06, 0xdb, 0x7a, 0x18, 0x26, 0x4a, 0x71, 0x2b, 0x99, 0x59, 0x60, 0x50, - 0x2c, 0xb0, 0x54, 0x61, 0xdf, 0xa7, 0x1d, 0xf2, 0x4d, 0x7f, 0x97, 0x52, 0xd8, 0x37, 0x75, 0x24, - 0x36, 0x69, 0xe9, 0x02, 0x14, 0xc6, 0x4c, 0x08, 0x85, 0x59, 0x98, 0xc6, 0xf0, 0x34, 0xf9, 0x2d, - 0x23, 0x89, 0x47, 0x5f, 0x80, 0xc7, 0xd4, 0xa5, 0x20, 0xcc, 0xfd, 0x87, 0xb2, 0xc6, 0x21, 0x63, - 0x6f, 0xf7, 0xd8, 0x62, 0x3e, 0x19, 0xee, 0x55, 0x1e, 0xbd, 0x0e, 0x13, 0xc2, 0xa4, 0x93, 0x1c, - 0x87, 0xcd, 0x23, 0xde, 0x9b, 0x06, 0x16, 0x67, 0xa8, 0x51, 0x1d, 0xa6, 0x28, 0x84, 0x99, 0x52, - 0x92, 0x03, 0xbf, 0xdc, 0xa4, 0x56, 0xe6, 0x9b, 0x19, 0x3c, 0xee, 0x2a, 0x81, 0xe6, 0x61, 0x92, - 0xdb, 0x16, 0x74, 0x07, 0xc3, 0xbe, 0x83, 0x88, 0x46, 0x54, 0x93, 0xe0, 0x8e, 0x89, 0xc6, 0x59, - 0x7a, 0xf4, 0x0a, 0x8c, 0x39, 0x51, 0x6b, 0xcb, 0x4b, 0x48, 0x2b, 0xe9, 0x44, 0xfc, 0x66, 0xbb, - 0x76, 0x46, 0x3e, 0xaf, 0xe1, 0xb0, 0x41, 0x69, 0x7f, 0x15, 0x4e, 0xe7, 0x04, 0x3d, 0x53, 0xc1, - 0x71, 0xda, 0x9e, 0xec, 0x53, 0x26, 0x1a, 0x67, 0xbe, 0xb1, 0x22, 0x7b, 0xa3, 0x51, 0x51, 0xe9, - 0x64, 0x8e, 0x53, 0x2d, 0x3f, 0x9a, 0x92, 0xce, 0x65, 0x89, 0xc0, 0x29, 0x8d, 0xfd, 0xdf, 0x6b, - 0xa0, 0xb9, 0x19, 0x4a, 0xc4, 0x60, 0xbc, 0x02, 0x63, 0x32, 0xe5, 0x9f, 0x96, 0x6a, 0x4b, 0x75, - 0xf3, 0xba, 0x86, 0xc3, 0x06, 0x25, 0x6d, 0x5b, 0x20, 0x9d, 0x26, 0xd9, 0xd8, 0x1f, 0xe5, 0x4d, - 0xc1, 0x29, 0x0d, 0xba, 0x0c, 0x23, 0x31, 0xf1, 0x37, 0x6e, 0x79, 0xc1, 0x7d, 0x21, 0xd8, 0x4a, - 0x2b, 0x37, 0x05, 0x1c, 0x2b, 0x0a, 0xf4, 0x39, 0xa8, 0x76, 0x3c, 0x57, 0x88, 0xf2, 0x9c, 0xb4, - 0x3b, 0xef, 0xae, 0xd4, 0x0f, 0xf6, 0x66, 0x67, 0xf3, 0xf3, 0x18, 0xd2, 0x6d, 0x64, 0x3c, 0x47, - 0x27, 0x1f, 0x2d, 0x9a, 0xe7, 0x3f, 0x1e, 0xea, 0xd3, 0x7f, 0x7c, 0x0d, 0x40, 0xf4, 0x59, 0x4a, - 0x72, 0x35, 0xfd, 0x66, 0xd7, 0x15, 0x06, 0x6b, 0x54, 0x74, 0x33, 0xda, 0x8a, 0x88, 0x23, 0x77, - 0x6b, 0x3c, 0x22, 0x77, 0xe4, 0x43, 0x6c, 0x46, 0x17, 0xb3, 0xdc, 0x70, 0x77, 0x05, 0xa8, 0x0d, - 0xa7, 0x5c, 0x3a, 0x8f, 0x8c, 0x5a, 0x6b, 0x47, 0x88, 0x03, 0xa6, 0x35, 0xd6, 0xb3, 0x9c, 0x70, - 0x37, 0x73, 0xf4, 0x0e, 0xcc, 0x48, 0x60, 0xf7, 0xb5, 0x3f, 0x36, 0x5d, 0xaa, 0x0b, 0xe7, 0xf7, - 0xf7, 0x66, 0x67, 0xea, 0x3d, 0xa9, 0xf0, 0x21, 0x1c, 0xd0, 0xdb, 0x30, 0xc4, 0x4e, 0x1c, 0xe2, - 0xe9, 0x51, 0xb6, 0xda, 0xbd, 0x58, 0xd6, 0xe1, 0x36, 0xc7, 0xce, 0x2d, 0x44, 0x20, 0x63, 0x7a, - 0x8a, 0xc3, 0x80, 0x58, 0xf0, 0x44, 0x6d, 0x18, 0x75, 0x82, 0x20, 0x4c, 0x1c, 0x6e, 0x84, 0x8d, - 0x95, 0xb1, 0x23, 0xb5, 0x2a, 0xe6, 0xd3, 0xb2, 0xbc, 0x1e, 0x15, 0x1d, 0xa5, 0x61, 0xb0, 0x5e, - 0x05, 0x5d, 0xc6, 0xc3, 0x07, 0x54, 0x61, 0x4a, 0xa7, 0x7b, 0x3c, 0x3d, 0x5e, 0x66, 0x19, 0xbf, - 0x63, 0x14, 0xd2, 0x34, 0x98, 0xc9, 0x0c, 0x67, 0xb9, 0xa3, 0x39, 0xc3, 0x8f, 0x3a, 0x91, 0x86, - 0xe9, 0xa6, 0x7e, 0x54, 0xdd, 0x6d, 0xca, 0xae, 0x94, 0xf2, 0xd0, 0x3c, 0xa6, 0x09, 0x26, 0x33, - 0x57, 0x4a, 0x53, 0x14, 0xd6, 0xe9, 0x66, 0x3e, 0x0d, 0xa3, 0xda, 0x80, 0xf7, 0x13, 0x0f, 0x3a, - 0xf3, 0x3a, 0x4c, 0x65, 0x07, 0xb2, 0xaf, 0x78, 0xd2, 0xff, 0x59, 0x81, 0xc9, 0x9c, 0x93, 0x8c, - 0xfb, 0x1e, 0x8b, 0x98, 0x36, 0x54, 0xde, 0x4d, 0x2f, 0x70, 0x31, 0xc3, 0x98, 0x8a, 0xab, 0x52, - 0x42, 0x71, 0x49, 0x2d, 0x5a, 0xed, 0xa9, 0x45, 0x85, 0xb2, 0x1a, 0x38, 0xba, 0xb2, 0x32, 0x57, - 0x87, 0xc1, 0x52, 0xab, 0xc3, 0x23, 0x50, 0x70, 0xc6, 0x02, 0x33, 0x5c, 0x62, 0x81, 0x39, 0xb0, - 0x60, 0xc2, 0x94, 0xbc, 0x12, 0x23, 0xfe, 0x51, 0x1d, 0xc0, 0x39, 0xb6, 0x11, 0x4b, 0xa2, 0xd0, - 0xf7, 0x49, 0x24, 0x22, 0xc5, 0x26, 0xc4, 0xbe, 0x4a, 0x40, 0xb1, 0x46, 0x61, 0x7f, 0xbb, 0x02, - 0x53, 0x69, 0xd8, 0xb0, 0x48, 0x7d, 0x7a, 0x7c, 0x47, 0x03, 0x6b, 0xc6, 0xd1, 0x40, 0x51, 0x46, - 0xd3, 0x4c, 0xbb, 0x7a, 0x1e, 0x13, 0xbc, 0x9d, 0x39, 0x26, 0x78, 0xb1, 0x4f, 0xbe, 0x87, 0x1f, - 0x19, 0xfc, 0xb3, 0x0a, 0x9c, 0xcd, 0x16, 0x59, 0xf4, 0x1d, 0x6f, 0xfb, 0x18, 0xc7, 0xe9, 0x0b, - 0xc6, 0x38, 0xbd, 0xdc, 0x5f, 0x7f, 0x58, 0xe3, 0x7a, 0x0e, 0x96, 0x93, 0x19, 0xac, 0x4f, 0x1f, - 0x85, 0xf9, 0xe1, 0x23, 0xf6, 0x3b, 0x16, 0x3c, 0x9e, 0x5b, 0xee, 0x24, 0x5c, 0xa0, 0x6f, 0x99, - 0x2e, 0xd0, 0x17, 0x8e, 0xd0, 0xbd, 0x1e, 0x3e, 0xd1, 0xff, 0x5a, 0xe9, 0xd1, 0x2d, 0xe6, 0x2d, - 0xbb, 0x03, 0xa3, 0x4e, 0xab, 0x45, 0xe2, 0x78, 0x35, 0x74, 0x55, 0x2e, 0x9e, 0xe7, 0xd9, 0xfa, - 0x99, 0x82, 0x0f, 0xf6, 0x66, 0x67, 0xb2, 0x2c, 0x52, 0x34, 0xd6, 0x39, 0x98, 0x39, 0xb5, 0x2a, - 0xc7, 0x94, 0x53, 0xeb, 0x1a, 0xc0, 0x8e, 0xda, 0xa5, 0x67, 0x9d, 0x70, 0xda, 0xfe, 0x5d, 0xa3, - 0x42, 0xef, 0x30, 0xab, 0x97, 0x87, 0x48, 0x0c, 0x14, 0x4e, 0x38, 0xe3, 0x03, 0xea, 0xf1, 0x16, - 0xfc, 0xce, 0xa4, 0xf2, 0x58, 0x2a, 0x9e, 0xf6, 0x77, 0xab, 0xf0, 0x53, 0x87, 0x88, 0x1d, 0x9a, - 0x37, 0x4f, 0x3e, 0x9f, 0xcb, 0xba, 0xa7, 0x66, 0x72, 0x0b, 0x1b, 0xfe, 0xaa, 0xcc, 0xc7, 0xaa, - 0x7c, 0xe8, 0x8f, 0xf5, 0x2d, 0xdd, 0x99, 0xc8, 0x43, 0x1d, 0xaf, 0x1f, 0x79, 0x62, 0x3d, 0x3a, - 0xef, 0xe2, 0x09, 0x3a, 0x3e, 0xec, 0xaf, 0x5b, 0xf0, 0xf1, 0xdc, 0x4e, 0x19, 0x01, 0x16, 0x57, - 0xa0, 0xd6, 0xa2, 0x40, 0xed, 0x2e, 0x4a, 0x7a, 0xc5, 0x4c, 0x22, 0x70, 0x4a, 0x63, 0xc4, 0x51, - 0x54, 0x0a, 0xe3, 0x28, 0xfe, 0xbd, 0x05, 0x67, 0xb2, 0x8d, 0x38, 0x09, 0xad, 0xd3, 0x34, 0xb5, - 0xce, 0x5c, 0x7f, 0xdf, 0xbe, 0x87, 0xc2, 0xf9, 0xf6, 0x38, 0x9c, 0xeb, 0x5a, 0xac, 0xf8, 0x30, - 0xfe, 0xac, 0x05, 0xa7, 0x36, 0xd9, 0xfe, 0x42, 0xbb, 0xf1, 0x23, 0x3a, 0x56, 0x70, 0x4d, 0xea, - 0xd0, 0x8b, 0x42, 0x7c, 0xb7, 0xd4, 0x45, 0x82, 0xbb, 0x2b, 0x43, 0xdf, 0xb0, 0xe0, 0x8c, 0xf3, - 0x20, 0xee, 0xca, 0xa3, 0x2f, 0xe4, 0xe8, 0xf5, 0x02, 0x57, 0x5e, 0x41, 0x06, 0xfe, 0x85, 0xe9, - 0xfd, 0xbd, 0xd9, 0x33, 0x79, 0x54, 0x38, 0xb7, 0x56, 0xf4, 0xb6, 0xc8, 0x3f, 0x46, 0xcd, 0xbe, - 0x52, 0x77, 0xd7, 0xf2, 0xee, 0x1f, 0x70, 0x9d, 0x24, 0x31, 0x58, 0x71, 0x44, 0x5f, 0x86, 0xda, - 0xa6, 0xbc, 0xe4, 0x23, 0x94, 0x5e, 0xc1, 0xca, 0x92, 0x7b, 0x27, 0x88, 0x47, 0xb9, 0x2b, 0x14, - 0x4e, 0x99, 0xa2, 0x1b, 0x50, 0x0d, 0x36, 0x62, 0x71, 0x5f, 0xb7, 0x28, 0x8e, 0xc6, 0x8c, 0x5a, - 0xe2, 0x37, 0x10, 0x6f, 0x2f, 0x37, 0x31, 0x65, 0x41, 0x39, 0x45, 0xeb, 0xae, 0xf0, 0x61, 0x17, - 0x70, 0xc2, 0x0b, 0xf5, 0x6e, 0x4e, 0x78, 0xa1, 0x8e, 0x29, 0x0b, 0x16, 0xb0, 0x17, 0xb7, 0x62, - 0x4f, 0x38, 0xa8, 0x0b, 0x2e, 0x73, 0x77, 0xdd, 0xca, 0xe0, 0xa9, 0xe8, 0x18, 0x18, 0x73, 0x46, - 0x68, 0x0d, 0x86, 0x5a, 0x2c, 0x75, 0xb4, 0xf0, 0x1f, 0x14, 0x25, 0x14, 0xee, 0x4a, 0x33, 0xcd, - 0x0f, 0xd2, 0x38, 0x1c, 0x0b, 0x5e, 0x8c, 0x2b, 0x69, 0x6f, 0x6d, 0xc4, 0xc2, 0x3f, 0x50, 0xc4, - 0xb5, 0x2b, 0x09, 0xb8, 0xe0, 0xca, 0xe0, 0x58, 0xf0, 0x42, 0x75, 0xa8, 0x6c, 0xb4, 0x44, 0xfe, - 0xc7, 0x82, 0x1d, 0xad, 0x79, 0x9d, 0x74, 0x61, 0x68, 0x7f, 0x6f, 0xb6, 0xb2, 0xbc, 0x88, 0x2b, - 0x1b, 0x2d, 0xf4, 0x16, 0x0c, 0x6f, 0xf0, 0x0b, 0x82, 0x22, 0xd7, 0xe3, 0xd5, 0xa2, 0x5b, 0x8c, - 0x5d, 0xb7, 0x09, 0xf9, 0x4d, 0x06, 0x81, 0xc0, 0x92, 0x1d, 0x7a, 0x07, 0x60, 0x43, 0x5d, 0x79, - 0x14, 0xc9, 0x1e, 0xe7, 0xfa, 0xbb, 0x22, 0x29, 0x76, 0xcf, 0x0a, 0x8a, 0x35, 0x8e, 0x54, 0xe6, - 0x1d, 0x99, 0xfd, 0x9e, 0x25, 0x7a, 0x2c, 0x94, 0xf9, 0xdc, 0x64, 0xf9, 0x5c, 0xe6, 0x15, 0x0a, - 0xa7, 0x4c, 0x51, 0x07, 0xc6, 0x77, 0xe2, 0xf6, 0x16, 0x91, 0x53, 0x9f, 0x65, 0x7f, 0x1c, 0xbd, - 0xf6, 0x5a, 0x41, 0x4a, 0x4f, 0x51, 0xc4, 0x8b, 0x92, 0x8e, 0xe3, 0x77, 0x69, 0x30, 0x96, 0x46, - 0xe9, 0x4d, 0x9d, 0x2d, 0x36, 0x6b, 0xa1, 0x9f, 0xe4, 0xbd, 0x4e, 0xb8, 0xbe, 0x9b, 0x10, 0x91, - 0x1d, 0xb2, 0xe0, 0x93, 0xbc, 0xc1, 0x89, 0xbb, 0x3f, 0x89, 0x40, 0x60, 0xc9, 0x4e, 0x0d, 0x19, - 0xd3, 0xc6, 0x53, 0xa5, 0x87, 0xac, 0xab, 0x0f, 0xe9, 0x90, 0x31, 0xed, 0x9b, 0x32, 0x65, 0x5a, - 0xb7, 0xbd, 0x15, 0x26, 0x61, 0x90, 0xd1, 0xfd, 0xa7, 0xca, 0x68, 0xdd, 0x46, 0x4e, 0xc9, 0x6e, - 0xad, 0x9b, 0x47, 0x85, 0x73, 0x6b, 0xb5, 0x7f, 0x7f, 0xb0, 0x7b, 0xbd, 0x65, 0xe6, 0xf0, 0x2f, - 0x76, 0x9f, 0xae, 0x7e, 0xae, 0xff, 0xed, 0xde, 0x23, 0x3c, 0x67, 0xfd, 0x86, 0x05, 0xe7, 0xda, - 0xb9, 0x8b, 0xa9, 0x58, 0xb0, 0xfa, 0xdd, 0x35, 0xf2, 0x01, 0x53, 0xa9, 0x4f, 0xf3, 0xf1, 0xb8, - 0x47, 0x9d, 0x59, 0x0b, 0xb4, 0xfa, 0xa1, 0x2d, 0xd0, 0x7b, 0x30, 0xc2, 0x8c, 0xa6, 0x34, 0xf7, - 0x46, 0x9f, 0xe9, 0x2a, 0xd8, 0xd2, 0xb7, 0x28, 0x58, 0x60, 0xc5, 0x8c, 0x0e, 0xdc, 0x93, 0xd9, - 0x4e, 0x60, 0xc2, 0xd0, 0x22, 0x67, 0x2b, 0x77, 0x4d, 0x2c, 0x8b, 0x91, 0x78, 0xb2, 0x71, 0x18, - 0xf1, 0x41, 0x11, 0x01, 0x3e, 0xbc, 0xb2, 0x93, 0xb4, 0x68, 0xff, 0xb1, 0x95, 0x63, 0x7f, 0xf1, - 0x3d, 0xc8, 0x6b, 0xe6, 0x1e, 0xe4, 0x62, 0x76, 0x0f, 0xd2, 0xe5, 0x31, 0x30, 0xb6, 0x1f, 0xe5, - 0xf3, 0x16, 0x96, 0x4d, 0x0e, 0x62, 0xfb, 0x70, 0xa1, 0x68, 0x72, 0xb3, 0x00, 0x1e, 0x57, 0x1d, - 0x0a, 0xa6, 0x01, 0x3c, 0xee, 0x4a, 0x1d, 0x33, 0x4c, 0xd9, 0xeb, 0xdf, 0xf6, 0xff, 0xb6, 0xa0, - 0xda, 0x08, 0xdd, 0x63, 0xf4, 0x80, 0x5c, 0x37, 0x3c, 0x20, 0x4f, 0x17, 0xbe, 0xf9, 0xd3, 0xd3, - 0xdf, 0x71, 0x27, 0xe3, 0xef, 0xf8, 0x64, 0x31, 0xab, 0xc3, 0xbd, 0x1b, 0xdf, 0xab, 0x82, 0xfe, - 0x6a, 0x11, 0xfa, 0xad, 0xa3, 0x84, 0x74, 0x56, 0xcb, 0x3d, 0x64, 0x24, 0xea, 0x60, 0x01, 0x50, - 0xf2, 0xbe, 0xd7, 0x9f, 0xda, 0xc8, 0xce, 0x7b, 0xc4, 0xdb, 0xdc, 0x4a, 0x88, 0x9b, 0xed, 0xd8, - 0xc9, 0x45, 0x76, 0xfe, 0x37, 0x0b, 0x26, 0x33, 0xb5, 0xa3, 0xed, 0xbc, 0x2b, 0x23, 0x47, 0x75, - 0x69, 0x9c, 0x2a, 0xbc, 0x64, 0x32, 0x07, 0xa0, 0xdc, 0xf0, 0xd2, 0xf1, 0xc0, 0x8c, 0x30, 0xe5, - 0xa7, 0x8f, 0xb1, 0x46, 0x81, 0x5e, 0x82, 0xd1, 0x24, 0x6c, 0x87, 0x7e, 0xb8, 0xb9, 0x7b, 0x93, - 0xc8, 0x8c, 0x04, 0xea, 0x08, 0x63, 0x2d, 0x45, 0x61, 0x9d, 0xce, 0xfe, 0x41, 0x15, 0xb2, 0x8f, - 0x5e, 0xfd, 0x7f, 0x41, 0xfd, 0xd3, 0x23, 0xa8, 0xbf, 0x6b, 0xc1, 0x14, 0xad, 0x9d, 0xc5, 0xaf, - 0xc8, 0xf8, 0x4b, 0x95, 0x6e, 0xdc, 0x3a, 0x24, 0xdd, 0xf8, 0x45, 0xaa, 0xee, 0xdc, 0xb0, 0x23, - 0x53, 0xe0, 0x68, 0x5a, 0x8c, 0x42, 0xb1, 0xc0, 0x0a, 0x3a, 0x12, 0x45, 0xe2, 0x72, 0x8a, 0x4e, - 0x47, 0xa2, 0x08, 0x0b, 0xac, 0xcc, 0x46, 0x3e, 0x90, 0x9f, 0x8d, 0x9c, 0x67, 0x0c, 0x12, 0x71, - 0x13, 0xc2, 0x0e, 0xd0, 0x32, 0x06, 0xc9, 0x80, 0x8a, 0x94, 0xc6, 0xfe, 0x17, 0x55, 0x18, 0x6b, - 0x84, 0x6e, 0x1a, 0x5b, 0xfd, 0xa2, 0x11, 0x5b, 0x7d, 0x21, 0x13, 0x5b, 0x3d, 0xa5, 0xd3, 0x3e, - 0x9a, 0xd0, 0x6a, 0x91, 0x5b, 0x8a, 0xe5, 0xcb, 0x3f, 0x6a, 0x58, 0xb5, 0x91, 0x5b, 0x4a, 0x71, - 0xc2, 0x26, 0xe3, 0x3f, 0x53, 0xe1, 0xd4, 0x7f, 0x6c, 0xc1, 0x44, 0x23, 0x74, 0xa9, 0x88, 0xfe, - 0x59, 0x92, 0x47, 0x3d, 0x23, 0xd5, 0xd0, 0x21, 0x19, 0xa9, 0x7e, 0xd5, 0x82, 0xe1, 0x46, 0xe8, - 0x9e, 0x84, 0x2b, 0x71, 0xd9, 0x74, 0x25, 0x7e, 0xbc, 0x50, 0xf9, 0xf6, 0xf0, 0x1e, 0xfe, 0x46, - 0x15, 0xc6, 0x69, 0x93, 0xc3, 0x4d, 0xf9, 0xc1, 0x8c, 0xc1, 0xb1, 0x4a, 0x0c, 0x0e, 0x35, 0x07, - 0x43, 0xdf, 0x0f, 0x1f, 0x64, 0x3f, 0xde, 0x32, 0x83, 0x62, 0x81, 0x45, 0x97, 0x61, 0xa4, 0x1d, - 0x91, 0x1d, 0x2f, 0xec, 0xc4, 0xd9, 0xbb, 0x6e, 0x0d, 0x01, 0xc7, 0x8a, 0x02, 0xbd, 0x08, 0x63, - 0xb1, 0x17, 0xb4, 0x88, 0x0c, 0xac, 0x18, 0x60, 0x81, 0x15, 0x3c, 0xf1, 0x9f, 0x06, 0xc7, 0x06, - 0x15, 0x7a, 0x0b, 0x6a, 0xec, 0x3f, 0x9b, 0x43, 0x47, 0x48, 0x91, 0xce, 0xb3, 0x52, 0x49, 0x0e, - 0x38, 0x65, 0x86, 0xae, 0x01, 0x24, 0x32, 0x06, 0x24, 0x16, 0x67, 0xa6, 0xca, 0x38, 0x55, 0xd1, - 0x21, 0x31, 0xd6, 0xa8, 0xd0, 0x73, 0x50, 0x4b, 0x1c, 0xcf, 0xbf, 0xe5, 0x05, 0x24, 0x16, 0x51, - 0x34, 0x22, 0x81, 0xad, 0x00, 0xe2, 0x14, 0x4f, 0xd7, 0x7c, 0x76, 0xd3, 0x96, 0x3f, 0xc0, 0x30, - 0xc2, 0xa8, 0xd9, 0x9a, 0x7f, 0x4b, 0x41, 0xb1, 0x46, 0x61, 0xbf, 0xc0, 0xd6, 0xee, 0x3e, 0x63, - 0xef, 0x7f, 0x52, 0x01, 0xd4, 0x60, 0xb1, 0x26, 0xc6, 0x1b, 0x15, 0x5b, 0x30, 0x11, 0x93, 0x5b, - 0x5e, 0xd0, 0x79, 0x28, 0x58, 0x95, 0xbb, 0xed, 0xd0, 0x5c, 0xd2, 0xcb, 0xf0, 0xdb, 0xa5, 0x26, - 0x0c, 0x67, 0xf8, 0xd2, 0x21, 0x89, 0x3a, 0xc1, 0x7c, 0x7c, 0x37, 0x26, 0x91, 0x78, 0x65, 0x82, - 0x0d, 0x09, 0x96, 0x40, 0x9c, 0xe2, 0xa9, 0x0c, 0xb0, 0x3f, 0xb7, 0xc3, 0x00, 0x87, 0x61, 0x22, - 0xa5, 0x86, 0xa5, 0x1c, 0xd7, 0xe0, 0xd8, 0xa0, 0x42, 0xcb, 0x80, 0xe2, 0x4e, 0xbb, 0xed, 0xb3, - 0xa3, 0x2d, 0xc7, 0xbf, 0x1e, 0x85, 0x9d, 0x36, 0x0f, 0x37, 0x16, 0xd9, 0xba, 0x9b, 0x5d, 0x58, - 0x9c, 0x53, 0x82, 0x4e, 0xfa, 0x8d, 0x98, 0xfd, 0x16, 0xb7, 0x67, 0xb9, 0x83, 0xad, 0xc9, 0x40, - 0x58, 0xe2, 0xec, 0x0e, 0x5b, 0xaa, 0x58, 0xf6, 0xff, 0xa4, 0x13, 0x11, 0x44, 0x60, 0xbc, 0xcd, - 0x96, 0x23, 0x79, 0xbe, 0x5e, 0x6a, 0x28, 0x33, 0xd1, 0x2e, 0x3c, 0xcb, 0xb7, 0xce, 0x06, 0x9b, - 0x5c, 0xed, 0xff, 0x08, 0x4c, 0xd7, 0x88, 0x53, 0xc5, 0x61, 0x11, 0xcb, 0x2a, 0x6c, 0xb1, 0x4f, - 0x94, 0x79, 0xee, 0x26, 0xd5, 0xe3, 0x22, 0x32, 0x16, 0x4b, 0x2e, 0xe8, 0x4b, 0x3c, 0x40, 0x80, - 0xcd, 0xef, 0xf2, 0x6f, 0x50, 0x71, 0x7a, 0x23, 0x4a, 0x5b, 0xb0, 0xc0, 0x1a, 0x3b, 0x74, 0x0b, - 0xc6, 0x45, 0x8a, 0x78, 0xe1, 0x19, 0xa8, 0x1a, 0xbb, 0xe3, 0x71, 0xac, 0x23, 0x0f, 0xb2, 0x00, - 0x6c, 0x16, 0x46, 0x9b, 0xf0, 0xa4, 0xf6, 0x6e, 0x4c, 0x4e, 0x44, 0x16, 0x57, 0x1c, 0x1f, 0xdf, - 0xdf, 0x9b, 0x7d, 0x72, 0xed, 0x30, 0x42, 0x7c, 0x38, 0x1f, 0x74, 0x07, 0xce, 0x3a, 0xad, 0xc4, - 0xdb, 0x21, 0x75, 0xe2, 0xb8, 0xbe, 0x17, 0x10, 0xf3, 0x6a, 0xf5, 0xe3, 0xfb, 0x7b, 0xb3, 0x67, - 0xe7, 0xf3, 0x08, 0x70, 0x7e, 0x39, 0xf4, 0x1a, 0xd4, 0xdc, 0x20, 0x16, 0x63, 0x30, 0x64, 0x3c, - 0x91, 0x53, 0xab, 0xdf, 0x6e, 0xaa, 0xfe, 0xa7, 0x7f, 0x70, 0x5a, 0x00, 0xbd, 0xc7, 0x5f, 0xee, - 0x55, 0x1b, 0x12, 0xfe, 0x34, 0xd3, 0xcb, 0xa5, 0xb6, 0xc0, 0xc6, 0x2d, 0x10, 0xee, 0x34, 0x53, - 0x91, 0x8f, 0xc6, 0x05, 0x11, 0xa3, 0x0a, 0xf4, 0x79, 0x40, 0x31, 0x89, 0x76, 0xbc, 0x16, 0x99, - 0x6f, 0xb1, 0x94, 0x97, 0xec, 0x78, 0x6e, 0xc4, 0x08, 0xff, 0x47, 0xcd, 0x2e, 0x0a, 0x9c, 0x53, - 0x0a, 0xdd, 0xa0, 0x1a, 0x47, 0x87, 0x8a, 0x40, 0x55, 0x69, 0xda, 0x4d, 0xd7, 0x49, 0x3b, 0x22, - 0x2d, 0x27, 0x21, 0xae, 0xc9, 0x11, 0x67, 0xca, 0xd1, 0x65, 0x45, 0xa5, 0xf2, 0x06, 0x33, 0xbc, - 0xb2, 0x3b, 0x9d, 0x37, 0xdd, 0x29, 0x6d, 0x85, 0x71, 0x72, 0x9b, 0x24, 0x0f, 0xc2, 0xe8, 0x3e, - 0x73, 0xb6, 0x8f, 0x68, 0x29, 0xbe, 0x52, 0x14, 0xd6, 0xe9, 0xa8, 0x0d, 0xc4, 0x4e, 0x79, 0x56, - 0xea, 0xcc, 0x85, 0x3e, 0x92, 0xce, 0x9d, 0x1b, 0x1c, 0x8c, 0x25, 0x5e, 0x92, 0xae, 0x34, 0x16, - 0x99, 0x3b, 0x3c, 0x43, 0xba, 0xd2, 0x58, 0xc4, 0x12, 0x8f, 0xc2, 0xee, 0x87, 0x88, 0x26, 0xca, - 0x1c, 0x4d, 0x74, 0x6b, 0xf0, 0x92, 0x6f, 0x11, 0x3d, 0x84, 0x29, 0xf5, 0x18, 0x12, 0xcf, 0xbd, - 0x18, 0x4f, 0x4f, 0x96, 0x79, 0x37, 0x38, 0x37, 0x85, 0xa3, 0x8a, 0x4c, 0x5e, 0xc9, 0xf0, 0xc4, - 0x5d, 0xb5, 0x18, 0x29, 0x02, 0xa6, 0x0a, 0xd3, 0xb3, 0x5f, 0x81, 0x5a, 0xdc, 0x59, 0x77, 0xc3, - 0x6d, 0xc7, 0x0b, 0x98, 0xcf, 0x5a, 0x7f, 0x05, 0x57, 0x22, 0x70, 0x4a, 0x33, 0xf3, 0x59, 0x38, - 0xd5, 0x25, 0xd3, 0x7d, 0x85, 0xd4, 0xfd, 0xe2, 0x00, 0xd4, 0x94, 0x57, 0x07, 0x5d, 0x31, 0x1d, - 0x77, 0x8f, 0x67, 0x1d, 0x77, 0x23, 0x74, 0xe5, 0xd5, 0x7d, 0x75, 0xef, 0xe4, 0x3c, 0x83, 0xf9, - 0x6c, 0xe1, 0x47, 0x2c, 0x7f, 0xb3, 0xa5, 0x8f, 0x47, 0x42, 0x53, 0xb3, 0x7e, 0xe0, 0x50, 0xb3, - 0xbe, 0xe4, 0x2b, 0x47, 0xd4, 0x80, 0x6f, 0x87, 0xee, 0x4a, 0x23, 0xfb, 0x82, 0x47, 0x83, 0x02, - 0x31, 0xc7, 0x31, 0xbb, 0x8b, 0x2a, 0x65, 0x66, 0x77, 0x0d, 0x1f, 0xd5, 0xee, 0x92, 0x1c, 0x70, - 0xca, 0x0c, 0xed, 0xc0, 0xa9, 0x96, 0xf9, 0x22, 0x8b, 0xba, 0xb0, 0xf2, 0x7c, 0x1f, 0x2f, 0xa2, - 0x74, 0xb4, 0xec, 0xf3, 0x8b, 0x59, 0x7e, 0xb8, 0xbb, 0x0a, 0xfb, 0x07, 0xdc, 0x0b, 0x24, 0xb6, - 0x85, 0x24, 0xee, 0xf8, 0xc7, 0x99, 0x4c, 0xfa, 0x8e, 0xb1, 0x53, 0x7d, 0x04, 0xfe, 0xc7, 0xdf, - 0xb4, 0x98, 0xff, 0x71, 0x8d, 0x6c, 0xb7, 0x7d, 0x27, 0x39, 0xce, 0x68, 0xbd, 0x2f, 0xc1, 0x48, - 0x22, 0x6a, 0x29, 0x97, 0x01, 0x5b, 0x6b, 0x16, 0xf3, 0xc7, 0x2a, 0x45, 0x20, 0xa1, 0x58, 0x31, - 0xb4, 0xff, 0x35, 0xff, 0x0a, 0x12, 0x73, 0x12, 0x3b, 0xab, 0xdb, 0xe6, 0xce, 0xea, 0x99, 0xd2, - 0x9d, 0xe9, 0xb1, 0xc3, 0xfa, 0xae, 0xd9, 0x05, 0x66, 0xb0, 0x7d, 0xf4, 0x3d, 0xe2, 0xf6, 0x2a, - 0x98, 0xaf, 0xcc, 0xa0, 0xd7, 0x78, 0xa8, 0x2a, 0xd7, 0x88, 0xcf, 0xf6, 0x19, 0xa6, 0x6a, 0xff, - 0x7a, 0x05, 0xce, 0xe4, 0x3d, 0x3e, 0x8f, 0x5c, 0x18, 0x6b, 0x6b, 0xe6, 0x73, 0xb9, 0x44, 0x06, - 0xba, 0xc1, 0x9d, 0x9a, 0x2e, 0x3a, 0x14, 0x1b, 0x5c, 0x11, 0x81, 0x31, 0xb2, 0xe3, 0xb5, 0x94, - 0x7b, 0xa5, 0xd2, 0xbf, 0x8a, 0x52, 0xd5, 0x2c, 0x69, 0x8c, 0xb0, 0xc1, 0xf6, 0x18, 0x92, 0xb4, - 0xdb, 0xff, 0xd0, 0x82, 0xc7, 0x7a, 0x64, 0x3b, 0xa0, 0xd5, 0x3d, 0x60, 0x5e, 0x48, 0xf1, 0x8a, - 0x91, 0xaa, 0x8e, 0xfb, 0x26, 0xb1, 0xc0, 0xa2, 0x75, 0x00, 0xee, 0x5b, 0x64, 0x4f, 0xbb, 0x56, - 0xca, 0xc4, 0x00, 0x74, 0xdd, 0xac, 0xd6, 0x2e, 0xdd, 0xaa, 0xc7, 0x5c, 0x35, 0xae, 0xf6, 0x77, - 0xaa, 0x30, 0xc8, 0x5f, 0x97, 0x6c, 0xc0, 0xf0, 0x16, 0x4f, 0xae, 0xd8, 0x5f, 0x6e, 0xc7, 0xd4, - 0x4e, 0xe2, 0x00, 0x2c, 0xd9, 0xa0, 0x55, 0x38, 0xed, 0x05, 0x5e, 0xe2, 0x39, 0x7e, 0x9d, 0xf8, - 0xce, 0xae, 0x34, 0xbc, 0x79, 0x62, 0x6d, 0x99, 0x03, 0xf6, 0xf4, 0x4a, 0x37, 0x09, 0xce, 0x2b, - 0x87, 0x5e, 0xef, 0xca, 0x8e, 0xc4, 0x93, 0x56, 0xaa, 0xbb, 0x5a, 0x87, 0x67, 0x48, 0x42, 0xaf, - 0xc2, 0x78, 0xbb, 0x6b, 0x8b, 0xa1, 0x3d, 0x4b, 0x68, 0x6e, 0x2b, 0x4c, 0x5a, 0x54, 0x87, 0xa9, - 0xb8, 0xc3, 0x4e, 0x64, 0xd7, 0xb6, 0x22, 0x12, 0x6f, 0x85, 0xbe, 0x2b, 0x9e, 0xd3, 0x52, 0xe6, - 0x54, 0x33, 0x83, 0xc7, 0x5d, 0x25, 0x28, 0x97, 0x0d, 0xc7, 0xf3, 0x3b, 0x11, 0x49, 0xb9, 0x0c, - 0x99, 0x5c, 0x96, 0x33, 0x78, 0xdc, 0x55, 0xc2, 0xfe, 0x43, 0x0b, 0x4e, 0xe7, 0x84, 0x2d, 0xf0, - 0x68, 0xba, 0x4d, 0x2f, 0x4e, 0x54, 0xfa, 0x64, 0x2d, 0x9a, 0x8e, 0xc3, 0xb1, 0xa2, 0xa0, 0x52, - 0xc8, 0xf7, 0x8d, 0xd9, 0xe3, 0x40, 0x71, 0x30, 0x2b, 0xb0, 0xfd, 0xe5, 0x3a, 0x52, 0x8f, 0xe4, - 0x0f, 0xf4, 0x7c, 0x24, 0xff, 0x29, 0x18, 0xdc, 0x54, 0xbb, 0x73, 0xcd, 0x30, 0xe1, 0xfb, 0x73, - 0x8e, 0xb3, 0xbf, 0x55, 0x85, 0xc9, 0x4c, 0xf8, 0x12, 0x6d, 0x48, 0xe6, 0x2d, 0x7f, 0xe6, 0x52, - 0x58, 0x24, 0xed, 0xad, 0x9c, 0xf7, 0xfc, 0x2f, 0x9a, 0x4f, 0xfd, 0xa6, 0x6d, 0x5e, 0xa8, 0x1b, - 0x8f, 0x98, 0x95, 0x4d, 0xe9, 0xfe, 0x14, 0x0c, 0xb4, 0x43, 0xf5, 0x26, 0xa5, 0x12, 0x7a, 0xbc, - 0x50, 0x6f, 0x84, 0xa1, 0x8f, 0x19, 0x12, 0x3d, 0x2d, 0x7a, 0x9f, 0x71, 0x4e, 0x62, 0xc7, 0x0d, - 0x63, 0x6d, 0x08, 0x9e, 0x81, 0xe1, 0xfb, 0x64, 0x37, 0xf2, 0x82, 0xcd, 0xac, 0x6b, 0xf6, 0x26, - 0x07, 0x63, 0x89, 0x37, 0xd3, 0xb6, 0x0f, 0x1f, 0x73, 0xda, 0xf6, 0x91, 0xc2, 0x10, 0xcc, 0x5f, - 0xb1, 0x60, 0x92, 0xe5, 0x9c, 0x13, 0xd7, 0x60, 0xbd, 0x30, 0x38, 0xc6, 0x55, 0xf1, 0x29, 0x18, - 0x8c, 0x68, 0x65, 0xd9, 0x8c, 0xcb, 0xac, 0x05, 0x98, 0xe3, 0xd0, 0x13, 0xe2, 0xc5, 0x74, 0xfa, - 0xf9, 0xc6, 0x78, 0x06, 0xdb, 0xf4, 0xe9, 0x73, 0x16, 0xe0, 0x8f, 0x49, 0xdb, 0xf7, 0x78, 0x63, - 0x53, 0x4f, 0xcc, 0x47, 0x25, 0xc0, 0x3f, 0xb7, 0x71, 0x8f, 0x2a, 0xc0, 0x3f, 0x9f, 0xf9, 0xe1, - 0x26, 0xe8, 0xff, 0xa8, 0xc0, 0xf9, 0xdc, 0x72, 0xe9, 0xb1, 0xce, 0xb2, 0x71, 0xac, 0x73, 0x2d, - 0x73, 0xac, 0x63, 0x1f, 0x5e, 0xfa, 0xd1, 0x1c, 0xf4, 0xe4, 0x1f, 0xbf, 0x54, 0x4f, 0xf2, 0xf8, - 0x65, 0xa0, 0xac, 0xad, 0x30, 0x58, 0x60, 0x2b, 0xfc, 0x8e, 0x05, 0x8f, 0xe7, 0x8e, 0xd9, 0x47, - 0xef, 0x4a, 0x45, 0x6e, 0x33, 0x7b, 0x58, 0xd0, 0x7f, 0xbd, 0xda, 0xa3, 0x5b, 0xcc, 0x96, 0xbe, - 0x44, 0xf5, 0x0e, 0x43, 0xc6, 0xc2, 0x0c, 0x1a, 0xe3, 0x3a, 0x87, 0xc3, 0xb0, 0xc2, 0xa2, 0x58, - 0xbb, 0x92, 0xc0, 0x1b, 0xb9, 0x74, 0xc4, 0x29, 0x35, 0x67, 0x3a, 0xcf, 0xf4, 0xfb, 0xbc, 0x99, - 0x7b, 0x0a, 0xe8, 0x9e, 0xb6, 0x3d, 0xaa, 0x1e, 0x65, 0x7b, 0x34, 0x96, 0xbf, 0x35, 0x42, 0xf3, - 0x30, 0xb9, 0xed, 0x05, 0xec, 0xcd, 0x34, 0xd3, 0x0e, 0x51, 0xb7, 0xe0, 0x56, 0x4d, 0x34, 0xce, - 0xd2, 0xcf, 0xbc, 0x0a, 0xe3, 0x47, 0xf7, 0x98, 0x7c, 0x50, 0x85, 0x9f, 0x3a, 0x44, 0x2d, 0xf0, - 0xf5, 0xc0, 0xf8, 0x2e, 0xda, 0x7a, 0xd0, 0xf5, 0x6d, 0x1a, 0x70, 0x66, 0xa3, 0xe3, 0xfb, 0xbb, - 0x2c, 0x2c, 0x82, 0xb8, 0x92, 0x42, 0xd8, 0x78, 0xea, 0x35, 0xd3, 0xe5, 0x1c, 0x1a, 0x9c, 0x5b, - 0x12, 0x7d, 0x1e, 0x50, 0xb8, 0xce, 0x12, 0x31, 0xba, 0xe9, 0x8d, 0x65, 0xf6, 0x09, 0xaa, 0xe9, - 0x5c, 0xbd, 0xd3, 0x45, 0x81, 0x73, 0x4a, 0x51, 0x8b, 0x8f, 0x3d, 0x84, 0xaa, 0x9a, 0x95, 0xb1, - 0xf8, 0xb0, 0x8e, 0xc4, 0x26, 0x2d, 0xba, 0x0e, 0xa7, 0x9c, 0x1d, 0xc7, 0xe3, 0xd9, 0x66, 0x24, - 0x03, 0x6e, 0xf2, 0x29, 0x97, 0xc4, 0x7c, 0x96, 0x00, 0x77, 0x97, 0x41, 0x6d, 0xc3, 0xc9, 0xc4, - 0x13, 0x2f, 0xbf, 0x76, 0x04, 0x09, 0x2e, 0xed, 0x76, 0xb2, 0xff, 0xc0, 0xa2, 0x8b, 0x5e, 0xce, - 0x1b, 0x63, 0xc6, 0xd3, 0xdc, 0xda, 0x2d, 0x8d, 0xee, 0xa7, 0xb9, 0x99, 0xff, 0xd5, 0xa4, 0xe5, - 0xa2, 0x11, 0xa7, 0x61, 0x95, 0x86, 0x7d, 0x29, 0x6e, 0x27, 0x29, 0x0a, 0x74, 0x0f, 0x86, 0x5d, - 0x6f, 0xc7, 0x8b, 0xc3, 0xa8, 0xc4, 0x4b, 0xb8, 0x5d, 0xa1, 0x7a, 0xa9, 0xba, 0xac, 0x73, 0x26, - 0x58, 0x72, 0xb3, 0xff, 0x66, 0x05, 0xc6, 0x65, 0x7d, 0x6f, 0x74, 0x42, 0xa6, 0xc3, 0x8e, 0x6b, - 0x29, 0x7f, 0xc3, 0x58, 0xca, 0xaf, 0x94, 0xbb, 0xa2, 0xc5, 0x1a, 0xd5, 0x73, 0x09, 0xff, 0x42, - 0x66, 0x09, 0xbf, 0xda, 0x0f, 0xd3, 0x42, 0xef, 0xd1, 0x29, 0x83, 0xfe, 0x23, 0x94, 0xf8, 0x37, - 0xaf, 0x3b, 0x3d, 0x16, 0x8e, 0xef, 0x54, 0x32, 0xdd, 0x60, 0x0b, 0xc6, 0xd7, 0x60, 0x60, 0xcb, - 0x89, 0x5c, 0x71, 0x54, 0xf6, 0xe9, 0x3e, 0x3f, 0xc5, 0xdc, 0x0d, 0x27, 0x72, 0xb9, 0xda, 0xbf, - 0xac, 0x5e, 0x28, 0x71, 0x22, 0xb7, 0x30, 0xc8, 0x98, 0x55, 0x8a, 0x5e, 0x81, 0xa1, 0xb8, 0x15, - 0xb6, 0x55, 0x54, 0xd7, 0x05, 0xfe, 0x7a, 0x09, 0x85, 0x1c, 0xec, 0xcd, 0x22, 0xb3, 0x3a, 0x0a, - 0xc6, 0x82, 0x7e, 0x86, 0x40, 0x4d, 0x55, 0x7d, 0x8c, 0xe1, 0xac, 0x1f, 0x54, 0xe1, 0x74, 0x8e, - 0xa8, 0xa0, 0x9f, 0x31, 0x46, 0xed, 0xd5, 0xbe, 0x65, 0xed, 0x43, 0x8e, 0xdb, 0xcf, 0xb0, 0x0d, - 0x91, 0x2b, 0x64, 0xe3, 0x08, 0xd5, 0xdf, 0x8d, 0x49, 0xb6, 0x7a, 0x0a, 0x2a, 0xae, 0x9e, 0x56, - 0x7b, 0x42, 0x83, 0x4f, 0xab, 0x51, 0xed, 0x3c, 0xc6, 0x6f, 0xfc, 0xfe, 0x00, 0x9c, 0xc9, 0xbb, - 0x06, 0x8a, 0x7e, 0xde, 0xca, 0xa4, 0x0e, 0x7f, 0xbd, 0xff, 0xbb, 0xa4, 0x3c, 0x9f, 0xb8, 0x48, - 0x0f, 0x31, 0x67, 0x26, 0x13, 0x2f, 0x1c, 0x6d, 0x51, 0x3b, 0xbb, 0x18, 0x10, 0xf1, 0x2c, 0xf0, - 0x52, 0x1f, 0x7c, 0xee, 0x08, 0x4d, 0x11, 0x89, 0xe4, 0xe3, 0xcc, 0xc5, 0x00, 0x09, 0x2e, 0xbe, - 0x18, 0x20, 0xdb, 0x30, 0xb3, 0x09, 0xa3, 0x5a, 0xbf, 0x8e, 0x51, 0x04, 0x3c, 0xba, 0x26, 0x69, - 0xad, 0x3e, 0x46, 0x31, 0xf8, 0xdb, 0x16, 0x64, 0xc2, 0x35, 0x94, 0xd7, 0xc5, 0xea, 0xe9, 0x75, - 0xb9, 0x00, 0x03, 0x51, 0xe8, 0x93, 0x6c, 0x4e, 0x6b, 0x1c, 0xfa, 0x04, 0x33, 0x8c, 0x7a, 0x07, - 0xb1, 0xda, 0xeb, 0x1d, 0x44, 0xba, 0x1d, 0xf7, 0xc9, 0x0e, 0x91, 0x3e, 0x10, 0xa5, 0xbc, 0x6f, - 0x51, 0x20, 0xe6, 0x38, 0xfb, 0x47, 0x55, 0x18, 0xe2, 0x8e, 0x86, 0x63, 0x5c, 0x96, 0x1b, 0x62, - 0xcf, 0x5f, 0xea, 0x42, 0x26, 0x6f, 0xcd, 0x5c, 0xdd, 0x49, 0x1c, 0x2e, 0x50, 0xaa, 0x6f, 0xa9, - 0x9f, 0x00, 0xcd, 0x19, 0xbd, 0x9f, 0xc9, 0x6c, 0x69, 0x81, 0xf3, 0xd0, 0xc6, 0x62, 0x0b, 0x20, - 0x66, 0x4f, 0x62, 0x51, 0x1e, 0x22, 0x29, 0xde, 0x8b, 0xa5, 0xda, 0xd1, 0x54, 0xc5, 0x78, 0x6b, - 0xd2, 0x6c, 0x5c, 0x0a, 0x81, 0x35, 0xde, 0x33, 0x2f, 0x43, 0x4d, 0x11, 0x17, 0x59, 0xfa, 0x63, - 0xba, 0x48, 0xfe, 0x39, 0x98, 0xcc, 0xd4, 0xd5, 0xd7, 0x46, 0xe1, 0xfb, 0x16, 0x9c, 0xea, 0x7a, - 0xc2, 0x15, 0xbd, 0x6f, 0xc1, 0x19, 0x3f, 0xc7, 0xc3, 0x24, 0x3e, 0xf0, 0x51, 0x7c, 0x53, 0x6a, - 0x97, 0x90, 0x87, 0xc5, 0xb9, 0xb5, 0xc9, 0x34, 0x9f, 0x95, 0xfc, 0x34, 0x9f, 0xec, 0x1d, 0x20, - 0xde, 0xf6, 0x93, 0xb0, 0x80, 0x56, 0x4c, 0x0b, 0xe8, 0x13, 0x65, 0xc4, 0xa0, 0x87, 0xe9, 0xf3, - 0xef, 0x2c, 0x40, 0x9c, 0x20, 0xfb, 0x34, 0x1e, 0xf7, 0xd8, 0x69, 0x36, 0x7b, 0x2a, 0x37, 0x0a, - 0x83, 0x35, 0xaa, 0x3e, 0xd3, 0x9e, 0xab, 0x27, 0xa5, 0xca, 0xbd, 0x5b, 0x5f, 0x2d, 0xf1, 0x6e, - 0xfd, 0x6f, 0x56, 0x21, 0x1b, 0xda, 0x80, 0xbe, 0x0c, 0x63, 0x2d, 0xa7, 0xed, 0xac, 0x7b, 0xbe, - 0x97, 0x78, 0x24, 0x2e, 0x77, 0x6c, 0xb4, 0xa8, 0x95, 0x10, 0x3e, 0x5f, 0x0d, 0x82, 0x0d, 0x8e, - 0x68, 0x0e, 0xa0, 0x1d, 0x79, 0x3b, 0x9e, 0x4f, 0x36, 0x99, 0xdd, 0xa1, 0x92, 0xa4, 0x34, 0x14, - 0x14, 0x6b, 0x14, 0x39, 0x31, 0x74, 0xd5, 0x93, 0x88, 0xa1, 0x1b, 0xe8, 0x33, 0x86, 0x6e, 0xb0, - 0x54, 0x0c, 0x1d, 0x86, 0x73, 0xd2, 0x55, 0x4b, 0xff, 0x2f, 0x7b, 0x3e, 0xe1, 0x79, 0xfd, 0x44, - 0xe4, 0xe3, 0xcc, 0xfe, 0xde, 0xec, 0x39, 0x9c, 0x4b, 0x81, 0x7b, 0x94, 0xb4, 0x3b, 0x70, 0xba, - 0x49, 0x22, 0x8f, 0xa5, 0x5d, 0x72, 0xd3, 0x19, 0xf8, 0x0e, 0xd4, 0xa2, 0xcc, 0xe4, 0xef, 0xf3, - 0x4e, 0x9a, 0x96, 0xbc, 0x42, 0x4e, 0xf6, 0x94, 0xa5, 0xfd, 0x97, 0x2a, 0x30, 0x2c, 0x42, 0x88, - 0x8e, 0x71, 0x21, 0xb9, 0x69, 0xec, 0xef, 0x9e, 0x29, 0x9a, 0xb9, 0xac, 0x39, 0x3d, 0x77, 0x76, - 0xcd, 0xcc, 0xce, 0xee, 0xb9, 0x72, 0xec, 0x0e, 0xdf, 0xd3, 0xfd, 0xb0, 0x02, 0x13, 0x66, 0x28, - 0xd5, 0x31, 0x0e, 0xc7, 0x5b, 0x30, 0x1c, 0x8b, 0xf8, 0xa2, 0x4a, 0x99, 0x58, 0x8d, 0xec, 0x27, - 0x4d, 0xdf, 0xc0, 0x17, 0x11, 0x45, 0x92, 0x5d, 0x6e, 0x08, 0x53, 0xf5, 0x24, 0x42, 0x98, 0xec, - 0x1f, 0x31, 0x95, 0xaa, 0x0f, 0xe0, 0x49, 0xac, 0x09, 0x6f, 0x98, 0xda, 0xf7, 0x72, 0x29, 0x51, - 0x10, 0xed, 0xeb, 0xb1, 0x36, 0x7c, 0xcf, 0x82, 0x51, 0x41, 0x78, 0x12, 0x3d, 0xf8, 0xbc, 0xd9, - 0x83, 0xa7, 0x4b, 0xf5, 0xa0, 0x47, 0xd3, 0xff, 0x6e, 0x45, 0x35, 0xbd, 0x21, 0x9e, 0x0c, 0x2d, - 0x4c, 0xf4, 0x38, 0xd2, 0x8e, 0xc2, 0x24, 0x6c, 0x85, 0xbe, 0x58, 0xe5, 0x9f, 0x48, 0xa3, 0xce, - 0x39, 0xfc, 0x40, 0xfb, 0x8d, 0x15, 0x35, 0x8b, 0xa6, 0x0e, 0xa3, 0x44, 0x2c, 0x51, 0x79, 0x0f, - 0x96, 0xae, 0xcb, 0x07, 0xa1, 0x29, 0x4c, 0x5c, 0xd9, 0xe8, 0xf7, 0x21, 0xd4, 0x34, 0x86, 0x5c, - 0x71, 0xc2, 0x1a, 0x57, 0x19, 0xde, 0xc8, 0x6a, 0x18, 0x34, 0xdd, 0xa8, 0xb7, 0x05, 0x1c, 0x2b, - 0x0a, 0xfb, 0x65, 0xa6, 0x63, 0xd9, 0xf0, 0xf4, 0x17, 0x18, 0xfe, 0x0b, 0x43, 0x6a, 0x60, 0x99, - 0x93, 0xe4, 0x36, 0x0c, 0xd2, 0x2e, 0xca, 0x7d, 0x60, 0x39, 0x85, 0x46, 0x9b, 0xa0, 0x07, 0x88, - 0x45, 0x49, 0x8c, 0x39, 0x1b, 0x44, 0xba, 0x7c, 0xef, 0x2f, 0x97, 0xd6, 0x91, 0x7d, 0x78, 0xdb, - 0x59, 0xe2, 0x18, 0x96, 0x2c, 0x63, 0xa5, 0x91, 0x4d, 0xce, 0xb9, 0x28, 0x11, 0x38, 0xa5, 0x41, - 0x57, 0x84, 0xb9, 0x6e, 0xbe, 0x27, 0x2b, 0xcd, 0x75, 0x39, 0x24, 0x9a, 0xbd, 0x7e, 0x15, 0x46, - 0x55, 0x7a, 0xf2, 0x06, 0xcf, 0x32, 0x5d, 0xe3, 0xf6, 0xcb, 0x52, 0x0a, 0xc6, 0x3a, 0x0d, 0x5a, - 0x81, 0xd3, 0xae, 0x8a, 0x66, 0x6d, 0x74, 0xd6, 0x7d, 0xaf, 0x45, 0x8b, 0xf2, 0x9b, 0x24, 0x8f, - 0xed, 0xef, 0xcd, 0x9e, 0xae, 0x77, 0xa3, 0x71, 0x5e, 0x19, 0xb4, 0x06, 0x93, 0x31, 0x4f, 0xc3, - 0x2e, 0xef, 0x9c, 0x89, 0xec, 0x75, 0xcf, 0x4a, 0xa7, 0x7f, 0xd3, 0x44, 0x1f, 0x30, 0x10, 0x57, - 0x0a, 0x02, 0x84, 0xb3, 0x2c, 0xd0, 0xeb, 0x30, 0xe1, 0xeb, 0xcf, 0x29, 0x35, 0x44, 0x50, 0xaf, - 0x0a, 0x88, 0x30, 0x1e, 0x5b, 0x6a, 0xe0, 0x0c, 0x35, 0x7a, 0x0b, 0xa6, 0x75, 0x88, 0xb8, 0xd4, - 0xee, 0x04, 0x9b, 0x24, 0x16, 0xf9, 0x9f, 0x9f, 0xd8, 0xdf, 0x9b, 0x9d, 0xbe, 0xd5, 0x83, 0x06, - 0xf7, 0x2c, 0x8d, 0x5e, 0x81, 0x31, 0x39, 0x92, 0x5a, 0x80, 0x6f, 0x1a, 0x8a, 0xa3, 0xe1, 0xb0, - 0x41, 0xf9, 0xe1, 0xce, 0x36, 0xbe, 0x46, 0x0b, 0x6b, 0x8b, 0x2a, 0xfa, 0x0a, 0x8c, 0xe9, 0x6d, - 0x14, 0x6a, 0xf2, 0x53, 0xe5, 0x9f, 0xa8, 0x12, 0x8b, 0xb3, 0x6a, 0xb9, 0x8e, 0xc3, 0x06, 0x6f, - 0xbb, 0x05, 0x93, 0x99, 0x27, 0x72, 0xd5, 0x5b, 0xcb, 0xd6, 0xa3, 0x7a, 0x6b, 0xd9, 0xfe, 0xba, - 0x05, 0x83, 0x6b, 0x8e, 0x57, 0xfc, 0xd0, 0x41, 0x99, 0xc7, 0x8a, 0xd1, 0x4b, 0x30, 0x44, 0x36, - 0x36, 0x48, 0x4b, 0xbe, 0xdd, 0xfc, 0xa4, 0x7a, 0x79, 0x9f, 0x41, 0xe9, 0x4c, 0x62, 0x95, 0xf1, - 0xbf, 0x58, 0x10, 0xdb, 0xff, 0xc1, 0x02, 0x58, 0x0b, 0x7d, 0x79, 0xca, 0x52, 0xd0, 0x92, 0x85, - 0xae, 0x27, 0x17, 0x2e, 0xe6, 0x3c, 0xb9, 0x80, 0x52, 0x86, 0x39, 0x0f, 0x2e, 0xa8, 0xde, 0x54, - 0x4b, 0xf5, 0x66, 0xa0, 0x9f, 0xde, 0x7c, 0xd3, 0x02, 0x11, 0xf2, 0x52, 0x62, 0x59, 0x72, 0x65, - 0x9a, 0x74, 0x23, 0xbb, 0xc4, 0xb3, 0x65, 0xee, 0x6d, 0x88, 0x9c, 0x12, 0x4a, 0x94, 0x8c, 0x4c, - 0x12, 0x06, 0x57, 0xba, 0xf5, 0x1e, 0xe5, 0xe8, 0x55, 0x66, 0xf0, 0x15, 0xb7, 0xab, 0xaf, 0x44, - 0x5a, 0x2c, 0x8b, 0x38, 0x65, 0xac, 0xf2, 0x29, 0xe9, 0x59, 0xc4, 0x25, 0x02, 0xa7, 0x34, 0xe8, - 0x19, 0x18, 0x8e, 0x3b, 0xeb, 0x8c, 0x3c, 0x13, 0xff, 0xd2, 0xe4, 0x60, 0x2c, 0xf1, 0xf6, 0xcf, - 0x21, 0x30, 0xba, 0x66, 0xe4, 0x6e, 0xb2, 0x1e, 0x79, 0xee, 0xa6, 0xb7, 0x61, 0x84, 0x6c, 0xb7, - 0x93, 0xdd, 0xba, 0x17, 0x95, 0xcb, 0xa3, 0xb7, 0x24, 0xa8, 0xbb, 0xb9, 0x4b, 0x0c, 0x56, 0x1c, - 0x7b, 0x64, 0xe2, 0xaa, 0x7e, 0x24, 0x32, 0x71, 0x0d, 0xfc, 0x89, 0x64, 0xe2, 0x7a, 0x0b, 0x86, - 0x37, 0xf9, 0xdb, 0xfd, 0xe2, 0x9e, 0x5e, 0xc1, 0xf1, 0x55, 0xce, 0x43, 0xff, 0xfc, 0x42, 0x96, - 0x40, 0x60, 0xc9, 0x0e, 0xad, 0xc1, 0x10, 0xdf, 0x2c, 0x88, 0xe4, 0x56, 0x9f, 0x2a, 0xe3, 0x46, - 0xe9, 0xce, 0xf3, 0x24, 0x82, 0x9c, 0x04, 0x2f, 0x99, 0x79, 0x6b, 0xf8, 0xc3, 0x67, 0xde, 0x52, - 0xf9, 0xb2, 0x46, 0x1e, 0x55, 0xbe, 0x2c, 0x23, 0xef, 0x58, 0xed, 0x38, 0xf2, 0x8e, 0x7d, 0xd3, - 0x82, 0xb3, 0xed, 0xbc, 0xb4, 0x7d, 0x22, 0xf3, 0xd5, 0x67, 0x8f, 0x90, 0xc6, 0xd0, 0xa8, 0x9a, - 0x5d, 0x9f, 0xca, 0x25, 0xc3, 0xf9, 0x15, 0xcb, 0x04, 0x66, 0xa3, 0x1f, 0x3e, 0x81, 0xd9, 0x71, - 0xa7, 0xc8, 0x4a, 0xd3, 0x99, 0x8d, 0x1f, 0x4b, 0x3a, 0xb3, 0x89, 0x47, 0x98, 0xce, 0x4c, 0x4b, - 0x44, 0x36, 0xf9, 0x68, 0x13, 0x91, 0x6d, 0xc1, 0xa8, 0x1b, 0x3e, 0x08, 0x1e, 0x38, 0x91, 0x3b, - 0xdf, 0x58, 0x11, 0x79, 0xaf, 0x0a, 0x72, 0x2c, 0xd4, 0xd3, 0x02, 0x46, 0x0d, 0xdc, 0x5f, 0x98, - 0x22, 0xb1, 0xce, 0x5a, 0xa4, 0x64, 0x3b, 0xf5, 0x21, 0x53, 0xb2, 0x19, 0x89, 0xcd, 0xd0, 0x71, - 0x24, 0x36, 0xfb, 0x32, 0xbb, 0x69, 0xbd, 0xe1, 0x6d, 0xae, 0x3a, 0xed, 0xe9, 0xd3, 0x65, 0x6a, - 0x58, 0x94, 0xe4, 0xdd, 0x35, 0x28, 0x14, 0x4e, 0x99, 0x76, 0xa7, 0x4e, 0x3b, 0x73, 0xd2, 0xa9, - 0xd3, 0xce, 0x1e, 0x63, 0xea, 0xb4, 0x73, 0x27, 0x9a, 0x3a, 0xed, 0xb1, 0x3f, 0x91, 0xd4, 0x69, - 0x7f, 0x01, 0xce, 0x1f, 0xfe, 0x39, 0xd2, 0xe4, 0xbc, 0x8d, 0x74, 0x87, 0x9f, 0x49, 0xce, 0xcb, - 0x4c, 0x1d, 0x8d, 0xaa, 0x74, 0x06, 0xa7, 0x7f, 0x6e, 0xc1, 0x63, 0x3d, 0xf2, 0x9c, 0x94, 0xbe, - 0x7c, 0xd0, 0x86, 0xc9, 0xb6, 0x59, 0xb4, 0xf4, 0x35, 0x21, 0x23, 0xaf, 0x8a, 0x0a, 0x6b, 0xcb, - 0x20, 0x70, 0x96, 0xfd, 0xc2, 0x27, 0x7e, 0xfc, 0xc1, 0xf9, 0x8f, 0xfd, 0xe4, 0x83, 0xf3, 0x1f, - 0xfb, 0xbd, 0x0f, 0xce, 0x7f, 0xec, 0x67, 0xf7, 0xcf, 0x5b, 0x3f, 0xde, 0x3f, 0x6f, 0xfd, 0x64, - 0xff, 0xbc, 0xf5, 0x87, 0xfb, 0xe7, 0xad, 0x6f, 0xfe, 0xd1, 0xf9, 0x8f, 0x7d, 0xb1, 0xb2, 0x73, - 0xf5, 0xff, 0x05, 0x00, 0x00, 0xff, 0xff, 0x70, 0xfd, 0x33, 0x79, 0x2a, 0xb5, 0x00, 0x00, + // 11429 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x7d, 0x6d, 0x8c, 0x24, 0xc7, + 0x75, 0x98, 0x7a, 0x66, 0xf6, 0x63, 0xde, 0x7e, 0xd7, 0xed, 0x1d, 0x97, 0x2b, 0xf2, 0xf6, 0xd8, + 0x14, 0xe9, 0x23, 0x79, 0xdc, 0xd3, 0x1d, 0x49, 0x91, 0x12, 0x65, 0x5a, 0xbb, 0x3b, 0xbb, 0x77, + 0xeb, 0xfb, 0x1a, 0xd6, 0xec, 0xdd, 0x51, 0x14, 0x43, 0xb2, 0x6f, 0xba, 0x76, 0xb7, 0x79, 0xb3, + 0xdd, 0xc3, 0xee, 0x9e, 0xbd, 0x5b, 0x1a, 0x06, 0x6c, 0x45, 0xb0, 0x14, 0x40, 0x49, 0x64, 0x38, + 0x02, 0x02, 0x27, 0x80, 0x02, 0x03, 0x71, 0x94, 0x6f, 0x2b, 0x82, 0x3e, 0x0c, 0xcb, 0x09, 0xe2, + 0x48, 0x8e, 0x1c, 0x24, 0x8e, 0x00, 0x23, 0xb1, 0x02, 0xc3, 0x6b, 0x6b, 0x85, 0xf8, 0x4f, 0x80, + 0xfc, 0x48, 0xfe, 0x6d, 0x3e, 0x10, 0xd4, 0x67, 0x57, 0xf5, 0xf4, 0x6c, 0xf7, 0x2c, 0x6f, 0xd7, + 0x94, 0x90, 0x7f, 0x33, 0xf5, 0x5e, 0xbd, 0xaa, 0xae, 0x8f, 0x57, 0xef, 0xbd, 0x7a, 0xef, 0x15, + 0x9c, 0xbb, 0xfb, 0x52, 0x34, 0xef, 0x05, 0xe7, 0xef, 0x76, 0xee, 0x90, 0xd0, 0x27, 0x31, 0x89, + 0xce, 0xb7, 0xef, 0x6e, 0x9c, 0x77, 0xda, 0xde, 0xf9, 0xed, 0x0b, 0xe7, 0x37, 0x88, 0x4f, 0x42, + 0x27, 0x26, 0xee, 0x7c, 0x3b, 0x0c, 0xe2, 0x00, 0x3d, 0xc2, 0xb1, 0xe7, 0x13, 0xec, 0xf9, 0xf6, + 0xdd, 0x8d, 0x79, 0xa7, 0xed, 0xcd, 0x6f, 0x5f, 0x98, 0x7d, 0x76, 0xc3, 0x8b, 0x37, 0x3b, 0x77, + 0xe6, 0x9b, 0xc1, 0xd6, 0xf9, 0x8d, 0x60, 0x23, 0x38, 0xcf, 0x2a, 0xdd, 0xe9, 0xac, 0xb3, 0x7f, + 0xec, 0x0f, 0xfb, 0xc5, 0x89, 0xcd, 0x3e, 0x2f, 0x9a, 0x76, 0xda, 0xde, 0x96, 0xd3, 0xdc, 0xf4, + 0x7c, 0x12, 0xee, 0xa8, 0xc6, 0x43, 0x12, 0x05, 0x9d, 0xb0, 0x49, 0xd2, 0x5d, 0x38, 0xb0, 0x56, + 0x74, 0x7e, 0x8b, 0xc4, 0x4e, 0x46, 0xc7, 0x67, 0xcf, 0xf7, 0xaa, 0x15, 0x76, 0xfc, 0xd8, 0xdb, + 0xea, 0x6e, 0xe6, 0x63, 0x79, 0x15, 0xa2, 0xe6, 0x26, 0xd9, 0x72, 0xba, 0xea, 0x3d, 0xd7, 0xab, + 0x5e, 0x27, 0xf6, 0x5a, 0xe7, 0x3d, 0x3f, 0x8e, 0xe2, 0x30, 0x5d, 0xc9, 0xfe, 0x63, 0x0b, 0xce, + 0x2c, 0xdc, 0x6e, 0x2c, 0xb7, 0x9c, 0x28, 0xf6, 0x9a, 0x8b, 0xad, 0xa0, 0x79, 0xb7, 0x11, 0x07, + 0x21, 0xb9, 0x15, 0xb4, 0x3a, 0x5b, 0xa4, 0xc1, 0x06, 0x02, 0x9d, 0x83, 0xe1, 0x6d, 0xf6, 0x7f, + 0xb5, 0x36, 0x63, 0x9d, 0xb1, 0xce, 0x56, 0x17, 0x27, 0xbf, 0xbf, 0x3b, 0xf7, 0xa1, 0xbd, 0xdd, + 0xb9, 0xe1, 0x5b, 0xa2, 0x1c, 0x2b, 0x0c, 0xf4, 0x24, 0x0c, 0xae, 0x47, 0x6b, 0x3b, 0x6d, 0x32, + 0x53, 0x62, 0xb8, 0xe3, 0x02, 0x77, 0x70, 0xa5, 0x41, 0x4b, 0xb1, 0x80, 0xa2, 0xf3, 0x50, 0x6d, + 0x3b, 0x61, 0xec, 0xc5, 0x5e, 0xe0, 0xcf, 0x94, 0xcf, 0x58, 0x67, 0x07, 0x16, 0xa7, 0x04, 0x6a, + 0xb5, 0x2e, 0x01, 0x38, 0xc1, 0xa1, 0xdd, 0x08, 0x89, 0xe3, 0xde, 0xf0, 0x5b, 0x3b, 0x33, 0x95, + 0x33, 0xd6, 0xd9, 0xe1, 0xa4, 0x1b, 0x58, 0x94, 0x63, 0x85, 0x61, 0x7f, 0xbb, 0x04, 0xc3, 0x0b, + 0xeb, 0xeb, 0x9e, 0xef, 0xc5, 0x3b, 0xe8, 0x6d, 0x18, 0xf5, 0x03, 0x97, 0xc8, 0xff, 0xec, 0x2b, + 0x46, 0x2e, 0x3e, 0x3d, 0x7f, 0xd0, 0xa2, 0x9a, 0xbf, 0xae, 0xd5, 0x58, 0x9c, 0xdc, 0xdb, 0x9d, + 0x1b, 0xd5, 0x4b, 0xb0, 0x41, 0x11, 0xbd, 0x01, 0x23, 0xed, 0xc0, 0x55, 0x0d, 0x94, 0x58, 0x03, + 0x4f, 0x1d, 0xdc, 0x40, 0x3d, 0xa9, 0xb0, 0x38, 0xb1, 0xb7, 0x3b, 0x37, 0xa2, 0x15, 0x60, 0x9d, + 0x1c, 0x6a, 0xc1, 0x04, 0xfd, 0xeb, 0xc7, 0x9e, 0x6a, 0xa1, 0xcc, 0x5a, 0x78, 0x36, 0xbf, 0x05, + 0xad, 0xd2, 0xe2, 0x89, 0xbd, 0xdd, 0xb9, 0x89, 0x54, 0x21, 0x4e, 0x93, 0xb6, 0xdf, 0x83, 0xf1, + 0x85, 0x38, 0x76, 0x9a, 0x9b, 0xc4, 0xe5, 0xf3, 0x8b, 0x9e, 0x87, 0x8a, 0xef, 0x6c, 0x11, 0x31, + 0xfb, 0x67, 0xc4, 0xb0, 0x57, 0xae, 0x3b, 0x5b, 0x64, 0x7f, 0x77, 0x6e, 0xf2, 0xa6, 0xef, 0xbd, + 0xdb, 0x11, 0x6b, 0x86, 0x96, 0x61, 0x86, 0x8d, 0x2e, 0x02, 0xb8, 0x64, 0xdb, 0x6b, 0x92, 0xba, + 0x13, 0x6f, 0x8a, 0xd5, 0x80, 0x44, 0x5d, 0xa8, 0x29, 0x08, 0xd6, 0xb0, 0xec, 0xcf, 0x5a, 0x50, + 0x5d, 0xd8, 0x0e, 0x3c, 0xb7, 0x1e, 0xb8, 0x11, 0xea, 0xc0, 0x44, 0x3b, 0x24, 0xeb, 0x24, 0x54, + 0x45, 0x33, 0xd6, 0x99, 0xf2, 0xd9, 0x91, 0x8b, 0x17, 0x73, 0xbe, 0xdb, 0xac, 0xb4, 0xec, 0xc7, + 0xe1, 0xce, 0xe2, 0x43, 0xa2, 0xe9, 0x89, 0x14, 0x14, 0xa7, 0xdb, 0xb0, 0xbf, 0x5b, 0x82, 0x93, + 0x0b, 0xef, 0x75, 0x42, 0x52, 0xf3, 0xa2, 0xbb, 0xe9, 0xad, 0xe0, 0x7a, 0xd1, 0xdd, 0xeb, 0xc9, + 0x60, 0xa8, 0x35, 0x58, 0x13, 0xe5, 0x58, 0x61, 0xa0, 0x67, 0x61, 0x88, 0xfe, 0xbe, 0x89, 0x57, + 0xc5, 0xd7, 0x9f, 0x10, 0xc8, 0x23, 0x35, 0x27, 0x76, 0x6a, 0x1c, 0x84, 0x25, 0x0e, 0xba, 0x06, + 0x23, 0x4d, 0xb6, 0x73, 0x37, 0xae, 0x05, 0x2e, 0x61, 0x33, 0x5c, 0x5d, 0x7c, 0x86, 0xa2, 0x2f, + 0x25, 0xc5, 0xfb, 0xbb, 0x73, 0x33, 0xbc, 0x6f, 0x82, 0x84, 0x06, 0xc3, 0x7a, 0x7d, 0x64, 0xab, + 0x8d, 0x58, 0x61, 0x94, 0x20, 0x63, 0x13, 0x9e, 0xd5, 0xf6, 0xd4, 0x00, 0xdb, 0x53, 0xa3, 0xd9, + 0xfb, 0x09, 0x5d, 0x80, 0xca, 0x5d, 0xcf, 0x77, 0x67, 0x06, 0x19, 0xad, 0x47, 0xe9, 0xf4, 0x5f, + 0xf1, 0x7c, 0x77, 0x7f, 0x77, 0x6e, 0xca, 0xe8, 0x0e, 0x2d, 0xc4, 0x0c, 0xd5, 0xfe, 0x47, 0x96, + 0x18, 0xc6, 0x15, 0xaf, 0x65, 0x72, 0x94, 0x8b, 0x00, 0x11, 0x69, 0x86, 0x24, 0xd6, 0x06, 0x52, + 0xad, 0x8c, 0x86, 0x82, 0x60, 0x0d, 0x8b, 0xf2, 0x8b, 0x68, 0xd3, 0x09, 0xd9, 0x02, 0x13, 0xc3, + 0xa9, 0xf8, 0x45, 0x43, 0x02, 0x70, 0x82, 0x63, 0xf0, 0x8b, 0x72, 0x2e, 0xbf, 0xf8, 0x3d, 0x0b, + 0x86, 0x16, 0x3d, 0xdf, 0xf5, 0xfc, 0x0d, 0xf4, 0x36, 0x0c, 0x53, 0x76, 0xee, 0x3a, 0xb1, 0x23, + 0x58, 0xc5, 0x47, 0xe5, 0x7a, 0xd3, 0xb9, 0xab, 0x5c, 0x71, 0xd1, 0x3c, 0xc5, 0xa6, 0xeb, 0xee, + 0xc6, 0x9d, 0x77, 0x48, 0x33, 0xbe, 0x46, 0x62, 0x27, 0xf9, 0x9c, 0xa4, 0x0c, 0x2b, 0xaa, 0xe8, + 0x26, 0x0c, 0xc6, 0x4e, 0xb8, 0x41, 0x62, 0xc1, 0x29, 0x72, 0xf6, 0x31, 0xa7, 0x81, 0xe9, 0x2a, + 0x25, 0x7e, 0x93, 0x24, 0x3c, 0x75, 0x8d, 0x11, 0xc1, 0x82, 0x98, 0xdd, 0x84, 0xd1, 0x25, 0xa7, + 0xed, 0xdc, 0xf1, 0x5a, 0x5e, 0xec, 0x91, 0x08, 0xfd, 0x0c, 0x94, 0x1d, 0xd7, 0x65, 0x7b, 0xa6, + 0xba, 0x78, 0x72, 0x6f, 0x77, 0xae, 0xbc, 0xe0, 0xd2, 0x29, 0x03, 0x85, 0xb5, 0x83, 0x29, 0x06, + 0x7a, 0x1a, 0x2a, 0x6e, 0x18, 0xb4, 0x67, 0x4a, 0x0c, 0xf3, 0x14, 0x9d, 0xdd, 0x5a, 0x18, 0xb4, + 0x53, 0xa8, 0x0c, 0xc7, 0xfe, 0x5e, 0x09, 0xd0, 0x12, 0x69, 0x6f, 0xae, 0x34, 0x8c, 0x39, 0x3d, + 0x0b, 0xc3, 0x5b, 0x81, 0xef, 0xc5, 0x41, 0x18, 0x89, 0x06, 0xd9, 0x52, 0xba, 0x26, 0xca, 0xb0, + 0x82, 0xa2, 0x33, 0x50, 0x69, 0x27, 0x1c, 0x61, 0x54, 0x72, 0x13, 0xc6, 0x0b, 0x18, 0x84, 0x62, + 0x74, 0x22, 0x12, 0x8a, 0x2d, 0xa0, 0x30, 0x6e, 0x46, 0x24, 0xc4, 0x0c, 0x92, 0xac, 0x20, 0xba, + 0xb6, 0xc4, 0x02, 0x4f, 0xad, 0x20, 0x0a, 0xc1, 0x1a, 0x16, 0x7a, 0x0b, 0xaa, 0xfc, 0x1f, 0x26, + 0xeb, 0x6c, 0xb5, 0xe7, 0xf2, 0x91, 0xab, 0x41, 0xd3, 0x69, 0xa5, 0x07, 0x7f, 0x8c, 0xad, 0x38, + 0x49, 0x08, 0x27, 0x34, 0x8d, 0x15, 0x37, 0x98, 0xbb, 0xe2, 0xfe, 0xb6, 0x05, 0x68, 0xc9, 0xf3, + 0x5d, 0x12, 0x1e, 0xc3, 0x69, 0xdb, 0xdf, 0x66, 0xf8, 0x13, 0xda, 0xb5, 0x60, 0xab, 0x1d, 0xf8, + 0xc4, 0x8f, 0x97, 0x02, 0xdf, 0xe5, 0x27, 0xf0, 0x27, 0xa0, 0x12, 0xd3, 0xa6, 0x78, 0xb7, 0x9e, + 0x94, 0xd3, 0x42, 0x1b, 0xd8, 0xdf, 0x9d, 0x3b, 0xd5, 0x5d, 0x83, 0x75, 0x81, 0xd5, 0x41, 0x1f, + 0x87, 0xc1, 0x28, 0x76, 0xe2, 0x4e, 0x24, 0x3a, 0xfa, 0x98, 0xec, 0x68, 0x83, 0x95, 0xee, 0xef, + 0xce, 0x4d, 0xa8, 0x6a, 0xbc, 0x08, 0x8b, 0x0a, 0xe8, 0x29, 0x18, 0xda, 0x22, 0x51, 0xe4, 0x6c, + 0x48, 0x9e, 0x38, 0x21, 0xea, 0x0e, 0x5d, 0xe3, 0xc5, 0x58, 0xc2, 0xd1, 0xe3, 0x30, 0x40, 0xc2, + 0x30, 0x08, 0xc5, 0x8a, 0x18, 0x13, 0x88, 0x03, 0xcb, 0xb4, 0x10, 0x73, 0x98, 0xfd, 0x5f, 0x2c, + 0x98, 0x50, 0x7d, 0xe5, 0x6d, 0x1d, 0xc3, 0x96, 0x77, 0x01, 0x9a, 0xf2, 0x03, 0x23, 0xb6, 0xd1, + 0xb4, 0x36, 0xb2, 0x97, 0x5f, 0xf7, 0x80, 0x26, 0x6d, 0xa8, 0xa2, 0x08, 0x6b, 0x74, 0xed, 0x7f, + 0x6b, 0xc1, 0x89, 0xd4, 0xb7, 0x5d, 0xf5, 0xa2, 0x18, 0xbd, 0xd1, 0xf5, 0x7d, 0xf3, 0xc5, 0xbe, + 0x8f, 0xd6, 0x66, 0x5f, 0xa7, 0xd6, 0x8b, 0x2c, 0xd1, 0xbe, 0x0d, 0xc3, 0x80, 0x17, 0x93, 0x2d, + 0xf9, 0x59, 0xcf, 0x16, 0xfc, 0x2c, 0xde, 0xbf, 0x64, 0x96, 0x56, 0x29, 0x0d, 0xcc, 0x49, 0xd9, + 0xff, 0xcb, 0x82, 0xea, 0x52, 0xe0, 0xaf, 0x7b, 0x1b, 0xd7, 0x9c, 0xf6, 0x31, 0xcc, 0x4f, 0x03, + 0x2a, 0x8c, 0x3a, 0xff, 0x84, 0x0b, 0x79, 0x9f, 0x20, 0x3a, 0x36, 0x4f, 0xcf, 0x3d, 0x2e, 0x5f, + 0x28, 0x36, 0x45, 0x8b, 0x30, 0x23, 0x36, 0xfb, 0x22, 0x54, 0x15, 0x02, 0x9a, 0x84, 0xf2, 0x5d, + 0xc2, 0x85, 0xcf, 0x2a, 0xa6, 0x3f, 0xd1, 0x34, 0x0c, 0x6c, 0x3b, 0xad, 0x8e, 0xd8, 0xbc, 0x98, + 0xff, 0xf9, 0x44, 0xe9, 0x25, 0xcb, 0xfe, 0x1e, 0xdb, 0x81, 0xa2, 0x91, 0x65, 0x7f, 0x5b, 0x30, + 0x87, 0xcf, 0x59, 0x30, 0xdd, 0xca, 0x60, 0x4a, 0x62, 0x4c, 0x0e, 0xc3, 0xce, 0x1e, 0x11, 0xdd, + 0x9e, 0xce, 0x82, 0xe2, 0xcc, 0xd6, 0x28, 0xaf, 0x0f, 0xda, 0x74, 0xc1, 0x39, 0x2d, 0xd6, 0x75, + 0x21, 0x36, 0xdc, 0x10, 0x65, 0x58, 0x41, 0xed, 0xbf, 0xb0, 0x60, 0x5a, 0x7d, 0xc7, 0x15, 0xb2, + 0xd3, 0x20, 0x2d, 0xd2, 0x8c, 0x83, 0xf0, 0x83, 0xf2, 0x25, 0x8f, 0xf2, 0x39, 0xe1, 0x3c, 0x69, + 0x44, 0x10, 0x28, 0x5f, 0x21, 0x3b, 0x7c, 0x82, 0xf4, 0x0f, 0x2d, 0x1f, 0xf8, 0xa1, 0xbf, 0x63, + 0xc1, 0x98, 0xfa, 0xd0, 0x63, 0xd8, 0x72, 0x57, 0xcd, 0x2d, 0xf7, 0x33, 0x05, 0xd7, 0x6b, 0x8f, + 0xcd, 0xf6, 0xb7, 0x4a, 0x94, 0x6d, 0x08, 0x9c, 0x7a, 0x18, 0xd0, 0x41, 0xa2, 0x1c, 0xff, 0x03, + 0x32, 0x4b, 0xfd, 0x7d, 0xec, 0x15, 0xb2, 0xb3, 0x16, 0x50, 0x69, 0x22, 0xfb, 0x63, 0x8d, 0x49, + 0xad, 0x1c, 0x38, 0xa9, 0x7f, 0x50, 0x82, 0x93, 0x6a, 0x58, 0x8c, 0x53, 0xfa, 0xa7, 0x72, 0x60, + 0x2e, 0xc0, 0x88, 0x4b, 0xd6, 0x9d, 0x4e, 0x2b, 0x56, 0x0a, 0xc8, 0x00, 0xd7, 0x4c, 0x6b, 0x49, + 0x31, 0xd6, 0x71, 0xfa, 0x18, 0xcb, 0xaf, 0x8c, 0x30, 0x7e, 0x1e, 0x3b, 0x74, 0xd5, 0x53, 0x09, + 0x4f, 0xd3, 0x28, 0x47, 0x75, 0x8d, 0x52, 0x68, 0x8f, 0x8f, 0xc3, 0x80, 0xb7, 0x45, 0xcf, 0xfc, + 0x92, 0x79, 0x94, 0xaf, 0xd2, 0x42, 0xcc, 0x61, 0xe8, 0x09, 0x18, 0x6a, 0x06, 0x5b, 0x5b, 0x8e, + 0xef, 0xce, 0x94, 0x99, 0xcc, 0x39, 0x42, 0xc5, 0x82, 0x25, 0x5e, 0x84, 0x25, 0x0c, 0x3d, 0x02, + 0x15, 0x27, 0xdc, 0x88, 0x66, 0x2a, 0x0c, 0x67, 0x98, 0xb6, 0xb4, 0x10, 0x6e, 0x44, 0x98, 0x95, + 0x52, 0x59, 0xf2, 0x5e, 0x10, 0xde, 0xf5, 0xfc, 0x8d, 0x9a, 0x17, 0x32, 0xc1, 0x50, 0x93, 0x25, + 0x6f, 0x2b, 0x08, 0xd6, 0xb0, 0x50, 0x1d, 0x06, 0xda, 0x41, 0x18, 0x47, 0x33, 0x83, 0x6c, 0xe0, + 0x9f, 0xc9, 0xdd, 0x7e, 0xfc, 0xbb, 0xeb, 0x41, 0x18, 0x27, 0x9f, 0x42, 0xff, 0x45, 0x98, 0x13, + 0x42, 0x4b, 0x50, 0x26, 0xfe, 0xf6, 0xcc, 0x10, 0xa3, 0xf7, 0x91, 0x83, 0xe9, 0x2d, 0xfb, 0xdb, + 0xb7, 0x9c, 0x30, 0xe1, 0x57, 0xcb, 0xfe, 0x36, 0xa6, 0xb5, 0x51, 0x13, 0xaa, 0xd2, 0x7e, 0x15, + 0xcd, 0x0c, 0x17, 0x59, 0x8a, 0x58, 0xa0, 0x63, 0xf2, 0x6e, 0xc7, 0x0b, 0xc9, 0x16, 0xf1, 0xe3, + 0x28, 0x51, 0xac, 0x24, 0x34, 0xc2, 0x09, 0x5d, 0xd4, 0x84, 0x51, 0x2e, 0x7f, 0x5e, 0x0b, 0x3a, + 0x7e, 0x1c, 0xcd, 0x54, 0x59, 0x97, 0x73, 0x8c, 0x1d, 0xb7, 0x92, 0x1a, 0x8b, 0xd3, 0x82, 0xfc, + 0xa8, 0x56, 0x18, 0x61, 0x83, 0x28, 0x7a, 0x03, 0xc6, 0x5a, 0xde, 0x36, 0xf1, 0x49, 0x14, 0xd5, + 0xc3, 0xe0, 0x0e, 0x99, 0x01, 0xf6, 0x35, 0x8f, 0xe7, 0x29, 0xfe, 0xc1, 0x1d, 0xb2, 0x38, 0xb5, + 0xb7, 0x3b, 0x37, 0x76, 0x55, 0xaf, 0x8d, 0x4d, 0x62, 0xe8, 0x2d, 0x18, 0xa7, 0xc2, 0xae, 0x97, + 0x90, 0x1f, 0x29, 0x4e, 0x1e, 0xed, 0xed, 0xce, 0x8d, 0x63, 0xa3, 0x3a, 0x4e, 0x91, 0x43, 0x6b, + 0x50, 0x6d, 0x79, 0xeb, 0xa4, 0xb9, 0xd3, 0x6c, 0x91, 0x99, 0x51, 0x46, 0x3b, 0x67, 0x73, 0x5e, + 0x95, 0xe8, 0x5c, 0xc1, 0x50, 0x7f, 0x71, 0x42, 0x08, 0xdd, 0x82, 0x53, 0x31, 0x09, 0xb7, 0x3c, + 0xdf, 0xa1, 0x9b, 0x4a, 0x48, 0xbf, 0xcc, 0xba, 0x32, 0xc6, 0x56, 0xed, 0x69, 0x31, 0xb0, 0xa7, + 0xd6, 0x32, 0xb1, 0x70, 0x8f, 0xda, 0xe8, 0x06, 0x4c, 0xb0, 0xfd, 0x54, 0xef, 0xb4, 0x5a, 0xf5, + 0xa0, 0xe5, 0x35, 0x77, 0x66, 0xc6, 0x19, 0xc1, 0x27, 0xa4, 0xcd, 0x64, 0xd5, 0x04, 0x53, 0xc5, + 0x30, 0xf9, 0x87, 0xd3, 0xb5, 0x51, 0x0b, 0x26, 0x22, 0xd2, 0xec, 0x84, 0x5e, 0xbc, 0x43, 0xd7, + 0x3e, 0xb9, 0x1f, 0xcf, 0x4c, 0x14, 0x51, 0x74, 0x1b, 0x66, 0x25, 0x6e, 0xb0, 0x4a, 0x15, 0xe2, + 0x34, 0x69, 0xca, 0x2a, 0xa2, 0xd8, 0xf5, 0xfc, 0x99, 0x49, 0xc6, 0x81, 0xd4, 0xfe, 0x6a, 0xd0, + 0x42, 0xcc, 0x61, 0xcc, 0x7e, 0x40, 0x7f, 0xdc, 0xa0, 0x5c, 0x7a, 0x8a, 0x21, 0x26, 0xf6, 0x03, + 0x09, 0xc0, 0x09, 0x0e, 0x15, 0x0d, 0xe2, 0x78, 0x67, 0x06, 0x31, 0x54, 0xb5, 0xd5, 0xd6, 0xd6, + 0x3e, 0x8d, 0x69, 0x39, 0xba, 0x05, 0x43, 0xc4, 0xdf, 0x5e, 0x09, 0x83, 0xad, 0x99, 0x13, 0x45, + 0x78, 0xc0, 0x32, 0x47, 0xe6, 0xe7, 0x47, 0xa2, 0xc2, 0x88, 0x62, 0x2c, 0x89, 0xa1, 0xfb, 0x30, + 0x93, 0x31, 0x4b, 0x7c, 0x52, 0xa6, 0xd9, 0xa4, 0x7c, 0x52, 0xd4, 0x9d, 0x59, 0xeb, 0x81, 0xb7, + 0x7f, 0x00, 0x0c, 0xf7, 0xa4, 0x6e, 0xdf, 0x81, 0x71, 0xc5, 0xa8, 0xd8, 0x7c, 0xa3, 0x39, 0x18, + 0xa0, 0xbc, 0x58, 0x2a, 0xf4, 0x55, 0x3a, 0xa8, 0x94, 0x45, 0x47, 0x98, 0x97, 0xb3, 0x41, 0xf5, + 0xde, 0x23, 0x8b, 0x3b, 0x31, 0xe1, 0x8a, 0x5d, 0x59, 0x1b, 0x54, 0x09, 0xc0, 0x09, 0x8e, 0xfd, + 0x7f, 0xb9, 0x98, 0x94, 0x70, 0xc3, 0x02, 0x27, 0xc1, 0x39, 0x18, 0xde, 0x0c, 0xa2, 0x98, 0x62, + 0xb3, 0x36, 0x06, 0x12, 0xc1, 0xe8, 0xb2, 0x28, 0xc7, 0x0a, 0x03, 0xbd, 0x0c, 0x63, 0x4d, 0xbd, + 0x01, 0x71, 0x8c, 0x9d, 0x14, 0x55, 0xcc, 0xd6, 0xb1, 0x89, 0x8b, 0x5e, 0x82, 0x61, 0x66, 0x18, + 0x6f, 0x06, 0x2d, 0xa1, 0x42, 0xca, 0x53, 0x79, 0xb8, 0x2e, 0xca, 0xf7, 0xb5, 0xdf, 0x58, 0x61, + 0x53, 0x45, 0x9c, 0x76, 0x61, 0xb5, 0x2e, 0x0e, 0x10, 0xa5, 0x88, 0x5f, 0x66, 0xa5, 0x58, 0x40, + 0xed, 0xdf, 0x2a, 0x69, 0xa3, 0x4c, 0x15, 0x20, 0x82, 0x5e, 0x87, 0xa1, 0x7b, 0x8e, 0x17, 0x7b, + 0xfe, 0x86, 0x90, 0x1e, 0x9e, 0x2b, 0x78, 0x9a, 0xb0, 0xea, 0xb7, 0x79, 0x55, 0x7e, 0xf2, 0x89, + 0x3f, 0x58, 0x12, 0xa4, 0xb4, 0xc3, 0x8e, 0xef, 0x53, 0xda, 0xa5, 0xfe, 0x69, 0x63, 0x5e, 0x95, + 0xd3, 0x16, 0x7f, 0xb0, 0x24, 0x88, 0xd6, 0x01, 0xe4, 0x5a, 0x22, 0xae, 0x30, 0x48, 0x7f, 0xac, + 0x1f, 0xf2, 0x6b, 0xaa, 0xf6, 0xe2, 0x38, 0x3d, 0x6b, 0x93, 0xff, 0x58, 0xa3, 0x6c, 0xc7, 0x4c, + 0x08, 0xeb, 0xee, 0x16, 0xfa, 0x0c, 0xdd, 0xd2, 0x4e, 0x18, 0x13, 0x77, 0x21, 0x4e, 0xdb, 0xf4, + 0x0f, 0x16, 0xb1, 0xd7, 0xbc, 0x2d, 0xa2, 0x6f, 0x7f, 0x41, 0x04, 0x27, 0xf4, 0xec, 0x6f, 0x95, + 0x61, 0xa6, 0x57, 0x77, 0xe9, 0x92, 0x24, 0xf7, 0xbd, 0x78, 0x89, 0x8a, 0x49, 0x96, 0xb9, 0x24, + 0x97, 0x45, 0x39, 0x56, 0x18, 0x74, 0x6d, 0x44, 0xde, 0x86, 0x54, 0x96, 0x06, 0x92, 0xb5, 0xd1, + 0x60, 0xa5, 0x58, 0x40, 0x29, 0x5e, 0x48, 0x9c, 0x48, 0xdc, 0x87, 0x68, 0x6b, 0x08, 0xb3, 0x52, + 0x2c, 0xa0, 0xba, 0x41, 0xa4, 0x92, 0x63, 0x10, 0x31, 0x86, 0x68, 0xe0, 0xc1, 0x0e, 0x11, 0x7a, + 0x13, 0x60, 0xdd, 0xf3, 0xbd, 0x68, 0x93, 0x51, 0x1f, 0xec, 0x9b, 0xba, 0x12, 0xb2, 0x56, 0x14, + 0x15, 0xac, 0x51, 0x44, 0x2f, 0xc0, 0x88, 0xda, 0x9e, 0xab, 0xb5, 0x99, 0x21, 0xd3, 0x86, 0x9e, + 0xf0, 0xaa, 0x1a, 0xd6, 0xf1, 0xec, 0x77, 0xd2, 0xeb, 0x45, 0xec, 0x0a, 0x6d, 0x7c, 0xad, 0xa2, + 0xe3, 0x5b, 0x3a, 0x78, 0x7c, 0xed, 0xff, 0x5c, 0x86, 0x09, 0xa3, 0xb1, 0x4e, 0x54, 0x80, 0xa3, + 0xbd, 0x4a, 0x0f, 0x2c, 0x27, 0x26, 0x62, 0x4f, 0x9e, 0xeb, 0x67, 0xd3, 0xe8, 0xc7, 0x1b, 0xdd, + 0x0b, 0x9c, 0x12, 0xda, 0x84, 0x6a, 0xcb, 0x89, 0x98, 0x49, 0x85, 0x88, 0xbd, 0xd8, 0x1f, 0xd9, + 0x44, 0xfd, 0x70, 0xa2, 0x58, 0x3b, 0x3d, 0x78, 0x2b, 0x09, 0x71, 0x7a, 0xda, 0x52, 0x61, 0x47, + 0x5e, 0xc2, 0xa9, 0xee, 0x50, 0x89, 0x68, 0x07, 0x73, 0x18, 0x7a, 0x09, 0x46, 0x43, 0xc2, 0x56, + 0xca, 0x12, 0x95, 0xe7, 0xd8, 0xd2, 0x1b, 0x48, 0x04, 0x3f, 0xac, 0xc1, 0xb0, 0x81, 0x99, 0xc8, + 0xfd, 0x83, 0x07, 0xc8, 0xfd, 0x4f, 0xc1, 0x10, 0xfb, 0xa1, 0x56, 0x85, 0x9a, 0xa1, 0x55, 0x5e, + 0x8c, 0x25, 0x3c, 0xbd, 0x88, 0x86, 0x0b, 0x2e, 0xa2, 0xa7, 0x61, 0xbc, 0xe6, 0x90, 0xad, 0xc0, + 0x5f, 0xf6, 0xdd, 0x76, 0xe0, 0xf9, 0x31, 0x9a, 0x81, 0x0a, 0x3b, 0x4f, 0xf8, 0x7e, 0xaf, 0x50, + 0x0a, 0xb8, 0x42, 0x65, 0x77, 0xfb, 0x4f, 0x4a, 0x30, 0x56, 0x23, 0x2d, 0x12, 0x13, 0xae, 0xf7, + 0x44, 0x68, 0x05, 0xd0, 0x46, 0xe8, 0x34, 0x49, 0x9d, 0x84, 0x5e, 0xe0, 0x36, 0x48, 0x33, 0xf0, + 0xd9, 0xdd, 0x15, 0x3d, 0x20, 0x4f, 0xed, 0xed, 0xce, 0xa1, 0x4b, 0x5d, 0x50, 0x9c, 0x51, 0x03, + 0xb9, 0x30, 0xd6, 0x0e, 0x89, 0x61, 0x37, 0xb4, 0xf2, 0x45, 0x8d, 0xba, 0x5e, 0x85, 0x4b, 0xc3, + 0x46, 0x11, 0x36, 0x89, 0xa2, 0x4f, 0xc1, 0x64, 0x10, 0xb6, 0x37, 0x1d, 0xbf, 0x46, 0xda, 0xc4, + 0x77, 0xa9, 0x0a, 0x20, 0xac, 0x1d, 0xd3, 0x7b, 0xbb, 0x73, 0x93, 0x37, 0x52, 0x30, 0xdc, 0x85, + 0x8d, 0x5e, 0x87, 0xa9, 0x76, 0x18, 0xb4, 0x9d, 0x0d, 0xb6, 0x64, 0x84, 0xb4, 0xc2, 0x79, 0xd3, + 0xb9, 0xbd, 0xdd, 0xb9, 0xa9, 0x7a, 0x1a, 0xb8, 0xbf, 0x3b, 0x77, 0x82, 0x0d, 0x19, 0x2d, 0x49, + 0x80, 0xb8, 0x9b, 0x8c, 0xfd, 0x2e, 0x9c, 0xac, 0x05, 0xf7, 0xfc, 0x7b, 0x4e, 0xe8, 0x2e, 0xd4, + 0x57, 0x35, 0xe3, 0xc4, 0x6b, 0x52, 0xf9, 0xe5, 0x77, 0x82, 0x39, 0x27, 0x9b, 0x46, 0x83, 0xab, + 0x1d, 0x2b, 0x5e, 0x8b, 0xf4, 0x30, 0x87, 0xfc, 0xe3, 0x92, 0xd1, 0x66, 0x82, 0xaf, 0xee, 0x2e, + 0xac, 0x9e, 0x77, 0x17, 0x9f, 0x81, 0xe1, 0x75, 0x8f, 0xb4, 0x5c, 0x4c, 0xd6, 0xc5, 0x6c, 0x5d, + 0x28, 0x72, 0xb9, 0xb3, 0x42, 0xeb, 0x48, 0xeb, 0x18, 0x57, 0xa2, 0x57, 0x04, 0x19, 0xac, 0x08, + 0xa2, 0x0e, 0x4c, 0x4a, 0x3d, 0x4c, 0x42, 0xc5, 0x66, 0x7f, 0xae, 0x98, 0x9a, 0x67, 0x36, 0xc3, + 0xa6, 0x17, 0xa7, 0x08, 0xe2, 0xae, 0x26, 0xa8, 0xfe, 0xbc, 0x45, 0x8f, 0xba, 0x0a, 0x5b, 0xfa, + 0x4c, 0x7f, 0x66, 0xa6, 0x00, 0x56, 0x6a, 0xff, 0xa6, 0x05, 0x0f, 0x75, 0x8d, 0x96, 0xb0, 0x93, + 0x1c, 0xd9, 0x1c, 0xa5, 0x8d, 0x15, 0xa5, 0x7c, 0x63, 0x85, 0xfd, 0x5b, 0x16, 0x4c, 0x2f, 0x6f, + 0xb5, 0xe3, 0x9d, 0x9a, 0x67, 0xde, 0xb9, 0xbc, 0x08, 0x83, 0x5b, 0xc4, 0xf5, 0x3a, 0x5b, 0x62, + 0x5e, 0xe7, 0xe4, 0xc1, 0x70, 0x8d, 0x95, 0xee, 0xef, 0xce, 0x8d, 0x35, 0xe2, 0x20, 0x74, 0x36, + 0x08, 0x2f, 0xc0, 0x02, 0x9d, 0x5d, 0x29, 0x79, 0xef, 0x91, 0xab, 0xde, 0x96, 0x27, 0xaf, 0xf2, + 0x0e, 0x34, 0xf2, 0xcd, 0xcb, 0xa1, 0x9d, 0x7f, 0xb5, 0xe3, 0xf8, 0xb1, 0x17, 0xef, 0x98, 0xf2, + 0x32, 0x23, 0x84, 0x13, 0x9a, 0xf6, 0x8f, 0x2c, 0x98, 0x90, 0x1c, 0x68, 0xc1, 0x75, 0x43, 0x12, + 0x45, 0x68, 0x16, 0x4a, 0x5e, 0x5b, 0xf4, 0x14, 0x44, 0xed, 0xd2, 0x6a, 0x1d, 0x97, 0xbc, 0x36, + 0x7a, 0x1d, 0xaa, 0xfc, 0x2e, 0x30, 0x59, 0x7e, 0x7d, 0xde, 0x2d, 0x32, 0xed, 0x73, 0x4d, 0xd2, + 0xc0, 0x09, 0x39, 0x29, 0x87, 0xb3, 0xb3, 0xad, 0x6c, 0xde, 0x4c, 0x5d, 0x16, 0xe5, 0x58, 0x61, + 0xa0, 0xb3, 0x30, 0xec, 0x07, 0x2e, 0xbf, 0xae, 0xe5, 0x9c, 0x80, 0x2d, 0xea, 0xeb, 0xa2, 0x0c, + 0x2b, 0xa8, 0xfd, 0x45, 0x0b, 0x46, 0xe5, 0x37, 0x16, 0x54, 0x09, 0xe8, 0x36, 0x4c, 0xd4, 0x81, + 0x64, 0x1b, 0x52, 0x91, 0x9e, 0x41, 0x0c, 0x49, 0xbe, 0xdc, 0x8f, 0x24, 0x6f, 0xff, 0x76, 0x09, + 0xc6, 0x65, 0x77, 0x1a, 0x9d, 0x3b, 0x11, 0xa1, 0x82, 0x4e, 0xd5, 0xe1, 0x83, 0x4f, 0xe4, 0x4a, + 0x7e, 0x36, 0x4f, 0xdb, 0x33, 0xe6, 0x2c, 0x99, 0xe5, 0x05, 0x49, 0x07, 0x27, 0x24, 0xd1, 0x36, + 0x4c, 0xf9, 0x41, 0xcc, 0x0e, 0x50, 0x05, 0x2f, 0x76, 0x97, 0x92, 0x6e, 0xe7, 0x61, 0xd1, 0xce, + 0xd4, 0xf5, 0x34, 0x3d, 0xdc, 0xdd, 0x04, 0xba, 0x21, 0xad, 0x58, 0x65, 0xd6, 0xd6, 0xd3, 0xc5, + 0xda, 0xea, 0x6d, 0xc4, 0xb2, 0x7f, 0xdf, 0x82, 0xaa, 0x44, 0x3b, 0x8e, 0x4b, 0xb5, 0xdb, 0x30, + 0x14, 0xb1, 0x29, 0x92, 0xc3, 0x75, 0xae, 0xd8, 0x27, 0xf0, 0x79, 0x4d, 0xa4, 0x06, 0xfe, 0x3f, + 0xc2, 0x92, 0x1a, 0x33, 0xe7, 0xab, 0x0f, 0xf9, 0xc0, 0x99, 0xf3, 0x55, 0xcf, 0x7a, 0xdf, 0x9d, + 0x8d, 0x19, 0xf6, 0x06, 0x2a, 0xfa, 0xb6, 0x43, 0xb2, 0xee, 0xdd, 0x4f, 0x8b, 0xbe, 0x75, 0x56, + 0x8a, 0x05, 0x14, 0xad, 0xc3, 0x68, 0x53, 0x1a, 0xbc, 0x13, 0x16, 0xf2, 0xd1, 0x82, 0xb7, 0x0b, + 0xea, 0xa2, 0x8a, 0xfb, 0x4b, 0x2d, 0x69, 0x94, 0xb0, 0x41, 0x97, 0xf2, 0xa9, 0xe4, 0x2e, 0xbe, + 0x5c, 0xd0, 0x34, 0x14, 0x92, 0x38, 0x69, 0xa1, 0xe7, 0x35, 0xbc, 0xfd, 0x55, 0x0b, 0x06, 0xb9, + 0x85, 0xb4, 0x98, 0x99, 0x59, 0xbb, 0x82, 0x4b, 0xc6, 0xf3, 0x16, 0x2d, 0x14, 0x37, 0x72, 0xe8, + 0x36, 0x54, 0xd9, 0x0f, 0x66, 0xed, 0x29, 0x17, 0x71, 0x1e, 0xe3, 0xed, 0xeb, 0x5d, 0xbd, 0x25, + 0x09, 0xe0, 0x84, 0x96, 0xfd, 0x9d, 0x32, 0x65, 0x7d, 0x09, 0xaa, 0x21, 0x3d, 0x58, 0xc7, 0x21, + 0x3d, 0x94, 0x8e, 0x5e, 0x7a, 0x78, 0x17, 0x26, 0x9a, 0xda, 0x15, 0x60, 0x32, 0xe3, 0x17, 0x0b, + 0x2e, 0x2b, 0xed, 0xde, 0x90, 0x5b, 0x04, 0x97, 0x4c, 0x72, 0x38, 0x4d, 0x1f, 0x11, 0x18, 0xe5, + 0xeb, 0x41, 0xb4, 0x57, 0x61, 0xed, 0x9d, 0x2f, 0xb2, 0xc2, 0xf4, 0xc6, 0xd8, 0x2a, 0x6e, 0x68, + 0x84, 0xb0, 0x41, 0xd6, 0xfe, 0xf5, 0x01, 0x18, 0x58, 0xde, 0x26, 0x7e, 0x7c, 0x0c, 0xac, 0x6e, + 0x0b, 0xc6, 0x3d, 0x7f, 0x3b, 0x68, 0x6d, 0x13, 0x97, 0xc3, 0x0f, 0x77, 0xbc, 0x9f, 0x12, 0x8d, + 0x8c, 0xaf, 0x1a, 0xc4, 0x70, 0x8a, 0xf8, 0x51, 0xd8, 0x22, 0x5e, 0x85, 0x41, 0xbe, 0x32, 0x84, + 0x21, 0x22, 0xe7, 0xc6, 0x80, 0x0d, 0xac, 0xd8, 0x41, 0x89, 0xc5, 0x84, 0x5f, 0x56, 0x08, 0x42, + 0xe8, 0x1d, 0x18, 0x5f, 0xf7, 0xc2, 0x28, 0x5e, 0xf3, 0xb6, 0xa8, 0x0e, 0xb9, 0xd5, 0x3e, 0x84, + 0x15, 0x42, 0x8d, 0xc8, 0x8a, 0x41, 0x09, 0xa7, 0x28, 0xa3, 0x0d, 0x18, 0xa3, 0x4a, 0x70, 0xd2, + 0xd4, 0x50, 0xdf, 0x4d, 0x29, 0x23, 0xe4, 0x55, 0x9d, 0x10, 0x36, 0xe9, 0x52, 0x96, 0xd4, 0x64, + 0x4a, 0xf3, 0x30, 0x93, 0x6e, 0x14, 0x4b, 0xe2, 0xda, 0x32, 0x87, 0x51, 0xce, 0xc6, 0x7c, 0x71, + 0xaa, 0x26, 0x67, 0x4b, 0x3c, 0x6e, 0xec, 0xaf, 0xd3, 0xb3, 0x98, 0x8e, 0xe1, 0x31, 0x1c, 0x5f, + 0x97, 0xcd, 0xe3, 0xeb, 0xf1, 0x02, 0x33, 0xdb, 0xe3, 0xe8, 0x7a, 0x1b, 0x46, 0xb4, 0x89, 0x47, + 0xe7, 0xa1, 0xda, 0x94, 0xee, 0x22, 0x82, 0x8b, 0x2b, 0x51, 0x4a, 0xf9, 0x91, 0xe0, 0x04, 0x87, + 0x8e, 0x0b, 0x15, 0x41, 0xd3, 0xce, 0x65, 0x54, 0x40, 0xc5, 0x0c, 0x62, 0x3f, 0x07, 0xb0, 0x7c, + 0x9f, 0x34, 0x17, 0xb8, 0x12, 0xa9, 0xdd, 0x20, 0x5a, 0xbd, 0x6f, 0x10, 0xed, 0xaf, 0x59, 0x30, + 0xbe, 0xb2, 0x64, 0x28, 0x0d, 0xf3, 0x00, 0x5c, 0x36, 0xbe, 0x7d, 0xfb, 0xba, 0xb4, 0x90, 0x73, + 0x33, 0xa6, 0x2a, 0xc5, 0x1a, 0x06, 0x7a, 0x18, 0xca, 0xad, 0x8e, 0x2f, 0x44, 0xd6, 0xa1, 0xbd, + 0xdd, 0xb9, 0xf2, 0xd5, 0x8e, 0x8f, 0x69, 0x99, 0xe6, 0xc5, 0x55, 0x2e, 0xec, 0xc5, 0x95, 0xef, + 0x02, 0xfd, 0xe5, 0x32, 0x4c, 0xae, 0xb4, 0xc8, 0x7d, 0xa3, 0xd7, 0x4f, 0xc2, 0xa0, 0x1b, 0x7a, + 0xdb, 0x24, 0x4c, 0x0b, 0x02, 0x35, 0x56, 0x8a, 0x05, 0xb4, 0xb0, 0x63, 0xd9, 0x5b, 0xdd, 0x07, + 0xf9, 0xd1, 0x39, 0xd5, 0xe5, 0x7e, 0x33, 0x5a, 0x87, 0x21, 0x7e, 0xe3, 0x1c, 0xcd, 0x0c, 0xb0, + 0xa5, 0xf8, 0xf2, 0xc1, 0x9d, 0x49, 0x8f, 0xcf, 0xbc, 0xb0, 0xe0, 0x70, 0x97, 0x1e, 0xc5, 0xcb, + 0x44, 0x29, 0x96, 0xc4, 0x67, 0x3f, 0x01, 0xa3, 0x3a, 0x66, 0x5f, 0xbe, 0x3d, 0x7f, 0xd5, 0x82, + 0x13, 0x2b, 0xad, 0xa0, 0x79, 0x37, 0xe5, 0xf9, 0xf7, 0x02, 0x8c, 0xd0, 0xcd, 0x14, 0x19, 0x6e, + 0xb1, 0x86, 0xcb, 0xb0, 0x00, 0x61, 0x1d, 0x4f, 0xab, 0x76, 0xf3, 0xe6, 0x6a, 0x2d, 0xcb, 0xd3, + 0x58, 0x80, 0xb0, 0x8e, 0x67, 0xff, 0xa1, 0x05, 0x8f, 0x5e, 0x5a, 0x5a, 0xae, 0x93, 0x30, 0xf2, + 0xa2, 0x98, 0xf8, 0x71, 0x97, 0xb3, 0x33, 0x95, 0x19, 0x5d, 0xad, 0x2b, 0x89, 0xcc, 0x58, 0x63, + 0xbd, 0x10, 0xd0, 0x0f, 0x8a, 0xc7, 0xff, 0x57, 0x2d, 0x38, 0x71, 0xc9, 0x8b, 0x31, 0x69, 0x07, + 0x69, 0x67, 0xe3, 0x90, 0xb4, 0x83, 0xc8, 0x8b, 0x83, 0x70, 0x27, 0xed, 0x6c, 0x8c, 0x15, 0x04, + 0x6b, 0x58, 0xbc, 0xe5, 0x6d, 0x2f, 0xa2, 0x3d, 0x2d, 0x99, 0xaa, 0x2e, 0x16, 0xe5, 0x58, 0x61, + 0xd0, 0x0f, 0x73, 0xbd, 0x90, 0x89, 0x0c, 0x3b, 0x62, 0x07, 0xab, 0x0f, 0xab, 0x49, 0x00, 0x4e, + 0x70, 0xec, 0xbf, 0x6b, 0xc1, 0xc9, 0x4b, 0xad, 0x4e, 0x14, 0x93, 0x70, 0x3d, 0x32, 0x3a, 0xfb, + 0x1c, 0x54, 0x89, 0x14, 0xee, 0x45, 0x5f, 0xd5, 0xa1, 0xa1, 0xa4, 0x7e, 0xee, 0xe9, 0xac, 0xf0, + 0x0a, 0x38, 0xd4, 0xf6, 0xe7, 0xfe, 0xf9, 0xbb, 0x25, 0x18, 0xbb, 0xbc, 0xb6, 0x56, 0xbf, 0x44, + 0x62, 0xc1, 0x25, 0xf3, 0xcd, 0x5e, 0x58, 0xd3, 0xc8, 0x0f, 0x12, 0x7e, 0x3a, 0xb1, 0xd7, 0x9a, + 0xe7, 0xd1, 0x28, 0xf3, 0xab, 0x7e, 0x7c, 0x23, 0x6c, 0xc4, 0xa1, 0xe7, 0x6f, 0x64, 0xea, 0xf0, + 0x92, 0x97, 0x97, 0x7b, 0xf1, 0x72, 0xf4, 0x1c, 0x0c, 0xb2, 0x70, 0x18, 0x29, 0x7c, 0x7c, 0x58, + 0xc9, 0x09, 0xac, 0x74, 0x7f, 0x77, 0xae, 0x7a, 0x13, 0xaf, 0xf2, 0x3f, 0x58, 0xa0, 0xa2, 0xb7, + 0x60, 0x64, 0x33, 0x8e, 0xdb, 0x97, 0x89, 0xe3, 0x92, 0x50, 0xf2, 0x89, 0xb3, 0x07, 0xf3, 0x09, + 0x3a, 0x1c, 0xbc, 0x42, 0xb2, 0xb5, 0x92, 0xb2, 0x08, 0xeb, 0x14, 0xed, 0x06, 0x40, 0x02, 0x7b, + 0x40, 0x3a, 0x88, 0xfd, 0xcb, 0x25, 0x18, 0xba, 0xec, 0xf8, 0x6e, 0x8b, 0x84, 0x68, 0x05, 0x2a, + 0xe4, 0x3e, 0x69, 0x8a, 0x83, 0x3c, 0xa7, 0xeb, 0xc9, 0x61, 0xc7, 0x2d, 0x77, 0xf4, 0x3f, 0x66, + 0xf5, 0x11, 0x86, 0x21, 0xda, 0xef, 0x4b, 0xca, 0x0f, 0xfd, 0x99, 0xfc, 0x51, 0x50, 0x8b, 0x82, + 0x9f, 0x94, 0xa2, 0x08, 0x4b, 0x42, 0xcc, 0x02, 0xd5, 0x6c, 0x37, 0x28, 0x7b, 0x8b, 0x8b, 0x69, + 0x76, 0x6b, 0x4b, 0x75, 0x8e, 0x2e, 0xe8, 0x72, 0x0b, 0x94, 0x2c, 0xc4, 0x09, 0x39, 0x7b, 0x0d, + 0xaa, 0x74, 0xf2, 0x17, 0x5a, 0x9e, 0x73, 0xb0, 0x19, 0xec, 0x19, 0xa8, 0x4a, 0x43, 0x54, 0x24, + 0x9c, 0xda, 0x19, 0x55, 0x69, 0xa7, 0x8a, 0x70, 0x02, 0xb7, 0x5f, 0x82, 0x69, 0x76, 0x8f, 0xec, + 0xc4, 0x9b, 0xc6, 0x5e, 0xcc, 0x5d, 0xf4, 0xf6, 0x37, 0x2a, 0x30, 0xb5, 0xda, 0x58, 0x6a, 0x98, + 0x36, 0xcf, 0x97, 0x60, 0x94, 0x1f, 0xfb, 0x74, 0x29, 0x3b, 0x2d, 0x51, 0x5f, 0xdd, 0x7d, 0xac, + 0x69, 0x30, 0x6c, 0x60, 0xa2, 0x47, 0xa1, 0xec, 0xbd, 0xeb, 0xa7, 0xbd, 0x11, 0x57, 0x5f, 0xbd, + 0x8e, 0x69, 0x39, 0x05, 0x53, 0x09, 0x82, 0xb3, 0x4e, 0x05, 0x56, 0x52, 0xc4, 0x2b, 0x30, 0xee, + 0x45, 0xcd, 0xc8, 0x5b, 0xf5, 0x29, 0x5f, 0x71, 0x9a, 0x72, 0x53, 0x24, 0x22, 0x3f, 0xed, 0xaa, + 0x82, 0xe2, 0x14, 0xb6, 0xc6, 0xc7, 0x07, 0x0a, 0x4b, 0x21, 0xb9, 0x6e, 0xee, 0x54, 0xc0, 0x6a, + 0xb3, 0xaf, 0x8b, 0x98, 0x6f, 0x93, 0x10, 0xb0, 0xf8, 0x07, 0x47, 0x58, 0xc2, 0xd0, 0x25, 0x98, + 0x6a, 0x6e, 0x3a, 0xed, 0x85, 0x4e, 0xbc, 0x59, 0xf3, 0xa2, 0x66, 0xb0, 0x4d, 0xc2, 0x1d, 0x26, + 0x00, 0x0f, 0x27, 0x36, 0x2d, 0x05, 0x58, 0xba, 0xbc, 0x50, 0xa7, 0x98, 0xb8, 0xbb, 0x8e, 0x29, + 0x90, 0xc0, 0x11, 0x08, 0x24, 0x0b, 0x30, 0x21, 0x5b, 0x6d, 0x90, 0x88, 0x1d, 0x11, 0x23, 0xac, + 0x9f, 0x2a, 0xc0, 0x48, 0x14, 0xab, 0x5e, 0xa6, 0xf1, 0xed, 0x77, 0xa0, 0xaa, 0x7c, 0xf1, 0xa4, + 0x0b, 0xaa, 0xd5, 0xc3, 0x05, 0x35, 0x9f, 0xb9, 0x4b, 0xeb, 0x7c, 0x39, 0xd3, 0x3a, 0xff, 0x4f, + 0x2d, 0x48, 0x9c, 0x89, 0x10, 0x86, 0x6a, 0x3b, 0x60, 0x37, 0x79, 0xa1, 0xbc, 0x32, 0x7f, 0x22, + 0x67, 0xcf, 0x73, 0x9e, 0xc3, 0x07, 0xa4, 0x2e, 0xeb, 0xe2, 0x84, 0x0c, 0xba, 0x0a, 0x43, 0xed, + 0x90, 0x34, 0x62, 0x16, 0x3f, 0xd2, 0x07, 0x45, 0xbe, 0x10, 0x78, 0x4d, 0x2c, 0x49, 0xd8, 0xff, + 0xd2, 0x02, 0xe0, 0x66, 0x70, 0xc7, 0xdf, 0x20, 0xc7, 0xa0, 0x58, 0x5f, 0x87, 0x4a, 0xd4, 0x26, + 0xcd, 0x62, 0x77, 0xb1, 0x49, 0xcf, 0x1a, 0x6d, 0xd2, 0x4c, 0xa6, 0x83, 0xfe, 0xc3, 0x8c, 0x8e, + 0xfd, 0x6d, 0x80, 0xf1, 0x04, 0x8d, 0x2a, 0x37, 0xe8, 0x59, 0x23, 0x70, 0xe2, 0xe1, 0x54, 0xe0, + 0x44, 0x95, 0x61, 0x6b, 0xb1, 0x12, 0x31, 0x94, 0xb7, 0x9c, 0xfb, 0x42, 0x97, 0x7a, 0xa1, 0x68, + 0x87, 0x68, 0x4b, 0xf3, 0xd7, 0x9c, 0xfb, 0x5c, 0x74, 0x7d, 0x46, 0x2e, 0xa4, 0x6b, 0xce, 0xfd, + 0x7d, 0x7e, 0xe3, 0xca, 0xb8, 0x13, 0x55, 0xde, 0x3e, 0xfb, 0x67, 0xc9, 0x7f, 0x76, 0x0c, 0xd1, + 0xe6, 0x58, 0xab, 0x9e, 0x2f, 0x4c, 0xc1, 0x7d, 0xb6, 0xea, 0xf9, 0xe9, 0x56, 0x3d, 0xbf, 0x40, + 0xab, 0x1e, 0xf3, 0x30, 0x1e, 0x12, 0x77, 0x34, 0xcc, 0x3d, 0x73, 0xe4, 0xe2, 0xc7, 0xfb, 0x6a, + 0x5a, 0x5c, 0xf6, 0xf0, 0xe6, 0xcf, 0x4b, 0x79, 0x5d, 0x94, 0xe6, 0x76, 0x41, 0x36, 0x8d, 0xfe, + 0x9e, 0x05, 0xe3, 0xe2, 0x37, 0x26, 0xef, 0x76, 0x48, 0x14, 0x0b, 0xb9, 0xe0, 0x53, 0x87, 0xe9, + 0x8d, 0x20, 0xc1, 0x3b, 0xf5, 0x31, 0xc9, 0x7e, 0x4d, 0x60, 0x6e, 0xdf, 0x52, 0xfd, 0x41, 0xdf, + 0xb6, 0x60, 0x7a, 0xcb, 0xb9, 0xcf, 0x5b, 0xe4, 0x65, 0xd8, 0x89, 0xbd, 0x40, 0xb8, 0xa0, 0xae, + 0xf4, 0xbb, 0x4e, 0xba, 0x08, 0xf1, 0xee, 0x4a, 0xef, 0xb2, 0xe9, 0x2c, 0x94, 0xdc, 0x4e, 0x67, + 0xf6, 0x70, 0x76, 0x1d, 0x86, 0xe5, 0xc2, 0xcc, 0xd0, 0x94, 0x6a, 0xba, 0xf8, 0xd3, 0xf7, 0x05, + 0x9a, 0xa6, 0x59, 0xb1, 0x76, 0xc4, 0x52, 0x3c, 0xd2, 0x76, 0xde, 0x81, 0x51, 0x7d, 0xdd, 0x1d, + 0x69, 0x5b, 0xef, 0xc2, 0x89, 0x8c, 0x55, 0x75, 0xa4, 0x4d, 0xde, 0x83, 0x87, 0x7b, 0xae, 0x8f, + 0xa3, 0x6c, 0xd8, 0xfe, 0x5d, 0x4b, 0x67, 0x9d, 0xc7, 0x60, 0xb7, 0xba, 0x66, 0xda, 0xad, 0xce, + 0x16, 0xdd, 0x43, 0x3d, 0x8c, 0x57, 0xeb, 0x7a, 0xf7, 0xe9, 0x91, 0x80, 0xd6, 0x60, 0xb0, 0x45, + 0x4b, 0xe4, 0xb5, 0xe1, 0xb9, 0x7e, 0x76, 0x69, 0x22, 0x81, 0xb1, 0xf2, 0x08, 0x0b, 0x5a, 0xf6, + 0xb7, 0x2d, 0xa8, 0xfc, 0x25, 0x86, 0x75, 0x75, 0x91, 0x16, 0xa9, 0x09, 0xe6, 0xb1, 0x73, 0x6f, + 0xf9, 0x7e, 0x4c, 0xfc, 0x88, 0x89, 0xf1, 0x99, 0x43, 0xf4, 0x7f, 0x4a, 0x30, 0x42, 0x9b, 0x92, + 0x9e, 0x32, 0x2f, 0xc3, 0x58, 0xcb, 0xb9, 0x43, 0x5a, 0xd2, 0xe6, 0x9e, 0x56, 0x7a, 0xaf, 0xea, + 0x40, 0x6c, 0xe2, 0xd2, 0xca, 0xeb, 0xfa, 0x95, 0x84, 0x10, 0x92, 0x54, 0x65, 0xe3, 0xbe, 0x02, + 0x9b, 0xb8, 0x54, 0xeb, 0xba, 0xe7, 0xc4, 0xcd, 0x4d, 0xa1, 0x10, 0xab, 0xee, 0xde, 0xa6, 0x85, + 0x98, 0xc3, 0xa8, 0xb0, 0x27, 0x57, 0xec, 0x2d, 0x12, 0x32, 0x61, 0x8f, 0x0b, 0xd5, 0x4a, 0xd8, + 0xc3, 0x26, 0x18, 0xa7, 0xf1, 0xd1, 0x27, 0x60, 0x9c, 0x0e, 0x4e, 0xd0, 0x89, 0xa5, 0x1f, 0xd0, + 0x00, 0xf3, 0x03, 0x62, 0x6e, 0xe4, 0x6b, 0x06, 0x04, 0xa7, 0x30, 0x51, 0x1d, 0xa6, 0x3d, 0xbf, + 0xd9, 0xea, 0xb8, 0xe4, 0xa6, 0xef, 0xf9, 0x5e, 0xec, 0x39, 0x2d, 0xef, 0x3d, 0xe2, 0x0a, 0xb1, + 0x5b, 0xb9, 0x6c, 0xad, 0x66, 0xe0, 0xe0, 0xcc, 0x9a, 0xf6, 0x5b, 0x70, 0xe2, 0x6a, 0xe0, 0xb8, + 0x8b, 0x4e, 0xcb, 0xf1, 0x9b, 0x24, 0x5c, 0xf5, 0x37, 0x72, 0x7d, 0x0a, 0xf4, 0x7b, 0xff, 0x52, + 0xde, 0xbd, 0xbf, 0x1d, 0x02, 0xd2, 0x1b, 0x10, 0x3e, 0x71, 0x6f, 0xc0, 0x90, 0xc7, 0x9b, 0x12, + 0x1b, 0xe1, 0x42, 0x9e, 0x4c, 0xde, 0xd5, 0x47, 0xcd, 0xc7, 0x8b, 0x17, 0x60, 0x49, 0x92, 0x6a, + 0x70, 0x59, 0x42, 0x7c, 0xbe, 0xea, 0x6d, 0xbf, 0x00, 0x53, 0xac, 0x66, 0x9f, 0x8a, 0xdf, 0x5f, + 0xb3, 0x60, 0xe2, 0x7a, 0x2a, 0x00, 0xfa, 0x49, 0x18, 0x8c, 0x48, 0x98, 0x61, 0x59, 0x6d, 0xb0, + 0x52, 0x2c, 0xa0, 0x0f, 0xdc, 0x5a, 0xf3, 0x6b, 0x25, 0xa8, 0x32, 0xa7, 0xec, 0x36, 0x55, 0xe2, + 0x8e, 0x5e, 0x5e, 0xbe, 0x66, 0xc8, 0xcb, 0x39, 0x16, 0x03, 0xd5, 0xb1, 0x5e, 0xe2, 0x32, 0xba, + 0xa9, 0x02, 0x83, 0x0b, 0x19, 0x0b, 0x12, 0x82, 0x3c, 0x78, 0x74, 0xdc, 0x8c, 0x23, 0x96, 0x41, + 0xc3, 0xec, 0x02, 0x5f, 0xe1, 0x7e, 0xe0, 0x2e, 0xf0, 0x55, 0xcf, 0x7a, 0x70, 0xc9, 0xba, 0xd6, + 0x79, 0x76, 0x8e, 0xfc, 0x1c, 0x73, 0xb5, 0x65, 0x7b, 0x58, 0xc5, 0xd7, 0xcf, 0x09, 0xd7, 0x59, + 0x51, 0xba, 0xcf, 0x18, 0x9e, 0xf8, 0xc7, 0xd3, 0x27, 0x24, 0x55, 0xec, 0xcb, 0x30, 0x91, 0x1a, + 0x3a, 0xf4, 0x02, 0x0c, 0xb4, 0x37, 0x9d, 0x88, 0xa4, 0x9c, 0x9e, 0x06, 0xea, 0xb4, 0x70, 0x7f, + 0x77, 0x6e, 0x5c, 0x55, 0x60, 0x25, 0x98, 0x63, 0xdb, 0x9f, 0x2b, 0x41, 0xe5, 0x7a, 0xe0, 0x1e, + 0xc7, 0x52, 0xbb, 0x6c, 0x2c, 0xb5, 0x27, 0xf3, 0xf3, 0xb5, 0xf4, 0x5c, 0x65, 0xf5, 0xd4, 0x2a, + 0x3b, 0x5b, 0x80, 0xd6, 0xc1, 0x0b, 0x6c, 0x0b, 0x46, 0x58, 0x3e, 0x18, 0xe1, 0x94, 0xf5, 0x9c, + 0xa1, 0xe2, 0xcd, 0xa5, 0x54, 0xbc, 0x09, 0x0d, 0x55, 0x53, 0xf4, 0x9e, 0x82, 0x21, 0xe1, 0x04, + 0x94, 0x76, 0x34, 0x16, 0xb8, 0x58, 0xc2, 0xed, 0x7f, 0x51, 0x06, 0x23, 0xff, 0x0c, 0xfa, 0x7d, + 0x0b, 0xe6, 0x43, 0x1e, 0xb4, 0xe5, 0xd6, 0x3a, 0xa1, 0xe7, 0x6f, 0x34, 0x9a, 0x9b, 0xc4, 0xed, + 0xb4, 0x3c, 0x7f, 0x63, 0x75, 0xc3, 0x0f, 0x54, 0xf1, 0xf2, 0x7d, 0xd2, 0xec, 0x30, 0x9b, 0x7b, + 0xe1, 0xb4, 0x37, 0xea, 0x02, 0xfc, 0xe2, 0xde, 0xee, 0xdc, 0x3c, 0xee, 0xab, 0x15, 0xdc, 0x67, + 0xaf, 0xd0, 0x0f, 0x2d, 0x38, 0xcf, 0x33, 0xb0, 0x14, 0xff, 0x92, 0x42, 0xaa, 0x71, 0x5d, 0x12, + 0x4d, 0xc8, 0xad, 0x91, 0x70, 0x6b, 0xf1, 0x45, 0x31, 0xc8, 0xe7, 0xeb, 0xfd, 0xb5, 0x8a, 0xfb, + 0xed, 0xa6, 0xfd, 0xaf, 0xcb, 0x30, 0x46, 0xc7, 0x33, 0x49, 0xa1, 0xf0, 0x82, 0xb1, 0x4c, 0x1e, + 0x4b, 0x2d, 0x93, 0x29, 0x03, 0xf9, 0xc1, 0x64, 0x4f, 0x88, 0x60, 0xaa, 0xe5, 0x44, 0xf1, 0x65, + 0xe2, 0x84, 0xf1, 0x1d, 0xe2, 0xb0, 0x7b, 0xe6, 0xb4, 0x0f, 0x4b, 0x81, 0xab, 0x6b, 0x65, 0x84, + 0xbb, 0x9a, 0x26, 0x86, 0xbb, 0xe9, 0xa3, 0x6d, 0x40, 0xec, 0x4e, 0x3b, 0x74, 0xfc, 0x88, 0x7f, + 0x8b, 0x27, 0x6c, 0xf4, 0xfd, 0xb5, 0x3a, 0x2b, 0x5a, 0x45, 0x57, 0xbb, 0xa8, 0xe1, 0x8c, 0x16, + 0x34, 0xaf, 0x85, 0x81, 0xa2, 0x5e, 0x0b, 0x83, 0x39, 0x1e, 0xfe, 0xbf, 0x62, 0xc1, 0x09, 0x3a, + 0x2d, 0xa6, 0x37, 0x78, 0x84, 0x02, 0x98, 0xa0, 0xcb, 0xae, 0x45, 0x62, 0x59, 0x26, 0xf6, 0x57, + 0x8e, 0x88, 0x6f, 0xd2, 0x49, 0xe4, 0xc8, 0x2b, 0x26, 0x31, 0x9c, 0xa6, 0x6e, 0x7f, 0xcd, 0x02, + 0xe6, 0x3d, 0x79, 0x0c, 0x87, 0xd9, 0x25, 0xf3, 0x30, 0xb3, 0xf3, 0x39, 0x46, 0x8f, 0x73, 0xec, + 0x79, 0x98, 0xa4, 0xd0, 0x7a, 0x18, 0xdc, 0xdf, 0x91, 0x12, 0x7f, 0xbe, 0x74, 0xf5, 0x2b, 0x25, + 0xbe, 0x6d, 0x54, 0xf4, 0x29, 0xfa, 0xbc, 0x05, 0xc3, 0x4d, 0xa7, 0xed, 0x34, 0x79, 0xf6, 0xae, + 0x02, 0x66, 0x22, 0xa3, 0xfe, 0xfc, 0x92, 0xa8, 0xcb, 0x4d, 0x1c, 0x1f, 0x95, 0x9f, 0x2e, 0x8b, + 0x73, 0xcd, 0x1a, 0xaa, 0xf1, 0xd9, 0xbb, 0x30, 0x66, 0x10, 0x3b, 0x52, 0x7d, 0xf8, 0xf3, 0x16, + 0x67, 0xfa, 0x4a, 0x67, 0xb9, 0x07, 0x53, 0xbe, 0xf6, 0x9f, 0xb2, 0x33, 0x29, 0x50, 0xcf, 0x17, + 0x67, 0xeb, 0x8c, 0x0b, 0x6a, 0x9e, 0xa2, 0x29, 0x82, 0xb8, 0xbb, 0x0d, 0xfb, 0x37, 0x2c, 0x78, + 0x48, 0x47, 0xd4, 0xc2, 0x85, 0xf3, 0x0c, 0xd8, 0x35, 0x18, 0x0e, 0xda, 0x24, 0x74, 0x12, 0xfd, + 0xec, 0xac, 0x1c, 0xff, 0x1b, 0xa2, 0x7c, 0x7f, 0x77, 0x6e, 0x5a, 0xa7, 0x2e, 0xcb, 0xb1, 0xaa, + 0x89, 0x6c, 0x18, 0x64, 0xe3, 0x12, 0x89, 0x40, 0x6f, 0x96, 0xcd, 0x8a, 0x5d, 0x90, 0x45, 0x58, + 0x40, 0xec, 0xbf, 0x69, 0xf1, 0xe5, 0xa6, 0x77, 0x1d, 0xfd, 0x02, 0x4c, 0x6e, 0x51, 0x55, 0x6e, + 0xf9, 0x7e, 0x3b, 0xe4, 0xe6, 0x77, 0x39, 0x62, 0x2f, 0x14, 0x1f, 0x31, 0xed, 0x73, 0x17, 0x67, + 0x44, 0xef, 0x27, 0xaf, 0xa5, 0xc8, 0xe2, 0xae, 0x86, 0xec, 0x7f, 0x50, 0xe2, 0x7b, 0x96, 0xc9, + 0x70, 0x4f, 0xc1, 0x50, 0x3b, 0x70, 0x97, 0x56, 0x6b, 0x58, 0x8c, 0x95, 0x62, 0x3a, 0x75, 0x5e, + 0x8c, 0x25, 0x1c, 0x5d, 0x04, 0x20, 0xf7, 0x63, 0x12, 0xfa, 0x4e, 0x4b, 0x5d, 0xe9, 0x2b, 0x51, + 0x69, 0x59, 0x41, 0xb0, 0x86, 0x45, 0xeb, 0xb4, 0xc3, 0x60, 0xdb, 0x73, 0x59, 0x9c, 0x4b, 0xd9, + 0xac, 0x53, 0x57, 0x10, 0xac, 0x61, 0x51, 0x05, 0xba, 0xe3, 0x47, 0xfc, 0x18, 0x73, 0xee, 0x88, + 0x4c, 0x4a, 0xc3, 0x89, 0x02, 0x7d, 0x53, 0x07, 0x62, 0x13, 0x17, 0x5d, 0x81, 0xc1, 0xd8, 0x61, + 0x17, 0xd5, 0x03, 0x45, 0xbc, 0x7e, 0xd6, 0x28, 0xae, 0x9e, 0xba, 0x8a, 0x56, 0xc5, 0x82, 0x84, + 0xfd, 0x9f, 0xaa, 0x00, 0x89, 0xd4, 0x85, 0x3e, 0xd7, 0xbd, 0xe1, 0x3f, 0x56, 0x54, 0x64, 0x7b, + 0x70, 0xbb, 0x1d, 0x7d, 0xc9, 0x82, 0x11, 0xa7, 0xd5, 0x0a, 0x9a, 0x4e, 0xcc, 0x86, 0xa7, 0x54, + 0x94, 0xf5, 0x88, 0x9e, 0x2c, 0x24, 0x75, 0x79, 0x67, 0x9e, 0x93, 0x97, 0xc7, 0x1a, 0x24, 0xb7, + 0x3f, 0x7a, 0x17, 0xd0, 0x47, 0xa5, 0xd4, 0xce, 0x67, 0x78, 0x36, 0x2d, 0xb5, 0x57, 0x19, 0xc3, + 0xd5, 0x04, 0x76, 0xf4, 0x96, 0x91, 0x79, 0xa8, 0x52, 0x24, 0x58, 0xd9, 0x90, 0x43, 0xf2, 0x92, + 0x0e, 0xa1, 0xd7, 0x75, 0xf7, 0xf8, 0x81, 0x22, 0xd9, 0x00, 0x34, 0x71, 0x38, 0xc7, 0x35, 0x3e, + 0x86, 0x09, 0xd7, 0x3c, 0x79, 0x85, 0x8b, 0xdf, 0x85, 0xfc, 0x16, 0x52, 0x47, 0x76, 0x72, 0xd6, + 0xa6, 0x00, 0x38, 0xdd, 0x04, 0x7a, 0x9d, 0x07, 0x2f, 0xac, 0xfa, 0xeb, 0x81, 0x70, 0xf3, 0x3b, + 0x57, 0x60, 0xce, 0x77, 0xa2, 0x98, 0x6c, 0xd1, 0x3a, 0xc9, 0xe1, 0x7a, 0x5d, 0x50, 0xc1, 0x8a, + 0x1e, 0x5a, 0x83, 0x41, 0x16, 0x9b, 0x16, 0xcd, 0x0c, 0x17, 0x31, 0x09, 0x9a, 0x21, 0xd9, 0xc9, + 0xfe, 0x61, 0x7f, 0x23, 0x2c, 0x68, 0xa1, 0xcb, 0x32, 0x29, 0x43, 0xb4, 0xea, 0xdf, 0x8c, 0x08, + 0x4b, 0xca, 0x50, 0x5d, 0xfc, 0x48, 0x92, 0x65, 0x81, 0x97, 0x67, 0xa6, 0x6b, 0x34, 0x6a, 0x52, + 0xc1, 0x46, 0xfc, 0x97, 0x59, 0x20, 0x67, 0xa0, 0x48, 0x47, 0xcd, 0x9c, 0x91, 0xc9, 0x60, 0xdf, + 0x32, 0x89, 0xe1, 0x34, 0xf5, 0x63, 0x3d, 0x52, 0x67, 0x7d, 0x98, 0x4c, 0x6f, 0xca, 0x23, 0x3d, + 0xc2, 0x7f, 0x5c, 0x81, 0x71, 0x73, 0x71, 0xa0, 0xf3, 0x50, 0x15, 0x44, 0x54, 0x8a, 0x37, 0xb5, + 0x07, 0xae, 0x49, 0x00, 0x4e, 0x70, 0x58, 0xb2, 0x3b, 0x56, 0x5d, 0x73, 0xf0, 0x4a, 0x92, 0xdd, + 0x29, 0x08, 0xd6, 0xb0, 0xa8, 0x24, 0x7c, 0x27, 0x08, 0x62, 0x75, 0x12, 0xa8, 0x75, 0xb3, 0xc8, + 0x4a, 0xb1, 0x80, 0xd2, 0x13, 0xe0, 0x2e, 0x9d, 0xcc, 0x96, 0x69, 0xde, 0x54, 0x27, 0xc0, 0x15, + 0x1d, 0x88, 0x4d, 0x5c, 0x7a, 0xa2, 0x05, 0x11, 0x5b, 0x88, 0x42, 0xde, 0x4e, 0x1c, 0xe6, 0x1a, + 0x3c, 0x5e, 0x53, 0xc2, 0xd1, 0xa7, 0xe1, 0x21, 0x15, 0x5e, 0x89, 0xb9, 0xb9, 0x58, 0xb6, 0x38, + 0x68, 0xa8, 0xcc, 0x0f, 0x2d, 0x65, 0xa3, 0xe1, 0x5e, 0xf5, 0xd1, 0x2b, 0x30, 0x2e, 0x64, 0x65, + 0x49, 0x71, 0xc8, 0xf4, 0x7b, 0xb8, 0x62, 0x40, 0x71, 0x0a, 0x1b, 0xd5, 0x60, 0x92, 0x96, 0x30, + 0x21, 0x55, 0x52, 0xe0, 0x61, 0xa2, 0xea, 0xa8, 0xbf, 0x92, 0x82, 0xe3, 0xae, 0x1a, 0x68, 0x01, + 0x26, 0xb8, 0xb0, 0x42, 0x15, 0x43, 0x36, 0x0f, 0xc2, 0x37, 0x57, 0x6d, 0x84, 0x1b, 0x26, 0x18, + 0xa7, 0xf1, 0xd1, 0x4b, 0x30, 0xea, 0x84, 0xcd, 0x4d, 0x2f, 0x26, 0xcd, 0xb8, 0x13, 0xf2, 0x94, + 0x27, 0x9a, 0xe3, 0xc8, 0x82, 0x06, 0xc3, 0x06, 0xa6, 0xfd, 0x1e, 0x9c, 0xc8, 0x08, 0x04, 0xa0, + 0x0b, 0xc7, 0x69, 0x7b, 0xf2, 0x9b, 0x52, 0xae, 0x6f, 0x0b, 0xf5, 0x55, 0xf9, 0x35, 0x1a, 0x16, + 0x5d, 0x9d, 0xcc, 0x4e, 0xae, 0x25, 0x6d, 0x55, 0xab, 0x73, 0x45, 0x02, 0x70, 0x82, 0x63, 0xff, + 0x29, 0x80, 0x66, 0xbd, 0x29, 0xe0, 0xee, 0xf4, 0x12, 0x8c, 0xca, 0x3c, 0xc4, 0x5a, 0x32, 0x4f, + 0xf5, 0x99, 0x97, 0x34, 0x18, 0x36, 0x30, 0x69, 0xdf, 0x7c, 0x69, 0x93, 0x4a, 0x3b, 0xda, 0x29, + 0x63, 0x15, 0x4e, 0x70, 0xd0, 0x39, 0x18, 0x8e, 0x48, 0x6b, 0xfd, 0xaa, 0xe7, 0xdf, 0x15, 0x0b, + 0x5b, 0x71, 0xe6, 0x86, 0x28, 0xc7, 0x0a, 0x03, 0x2d, 0x42, 0xb9, 0xe3, 0xb9, 0x62, 0x29, 0x4b, + 0xb1, 0xa1, 0x7c, 0x73, 0xb5, 0xb6, 0xbf, 0x3b, 0xf7, 0x58, 0xaf, 0xf4, 0xca, 0x54, 0x3f, 0x8f, + 0xe6, 0xe9, 0xf6, 0xa3, 0x95, 0xb3, 0x2e, 0x0c, 0x06, 0xfb, 0xbc, 0x30, 0xb8, 0x08, 0x20, 0xbe, + 0x5a, 0xae, 0xe5, 0x72, 0x32, 0x6b, 0x97, 0x14, 0x04, 0x6b, 0x58, 0x54, 0xcb, 0x6f, 0x86, 0xc4, + 0x91, 0x8a, 0x30, 0x77, 0x50, 0x1f, 0x3e, 0xbc, 0x96, 0xbf, 0x94, 0x26, 0x86, 0xbb, 0xe9, 0xa3, + 0x00, 0xa6, 0x5c, 0x11, 0xc3, 0x9b, 0x34, 0x5a, 0xed, 0xdf, 0x2b, 0x9e, 0xf9, 0xf6, 0xa4, 0x09, + 0xe1, 0x6e, 0xda, 0xe8, 0x4d, 0x98, 0x95, 0x85, 0xdd, 0x01, 0xd4, 0x6c, 0xbb, 0x94, 0x17, 0x4f, + 0xef, 0xed, 0xce, 0xcd, 0xd6, 0x7a, 0x62, 0xe1, 0x03, 0x28, 0xa0, 0x37, 0x60, 0x90, 0x5d, 0x30, + 0x45, 0x33, 0x23, 0xec, 0xc4, 0x7b, 0xbe, 0x48, 0x6c, 0x05, 0x5d, 0xf5, 0xf3, 0xec, 0x9a, 0x4a, + 0x78, 0x0d, 0x27, 0xb7, 0x76, 0xac, 0x10, 0x0b, 0x9a, 0xa8, 0x0d, 0x23, 0x8e, 0xef, 0x07, 0xb1, + 0xc3, 0x05, 0xb1, 0xd1, 0x22, 0xb2, 0xa4, 0xd6, 0xc4, 0x42, 0x52, 0x97, 0xb7, 0xa3, 0x1c, 0x11, + 0x35, 0x08, 0xd6, 0x9b, 0x40, 0xf7, 0x60, 0x22, 0xb8, 0x47, 0x19, 0xa6, 0xbc, 0x11, 0x89, 0x66, + 0xc6, 0xcc, 0x0f, 0xcb, 0x31, 0xd4, 0x1a, 0x95, 0x35, 0x4e, 0x66, 0x12, 0xc5, 0xe9, 0x56, 0xd0, + 0xbc, 0x61, 0xae, 0x1e, 0x4f, 0x7c, 0xe3, 0x13, 0x73, 0xb5, 0x6e, 0x9d, 0x66, 0x41, 0xfa, 0xdc, + 0x1f, 0x96, 0x71, 0x84, 0x89, 0x54, 0x90, 0x7e, 0x02, 0xc2, 0x3a, 0x1e, 0xda, 0x84, 0xd1, 0xe4, + 0x6e, 0x2b, 0x8c, 0x58, 0xfe, 0x1f, 0xcd, 0xdd, 0xeb, 0xe0, 0x8f, 0x5b, 0xd5, 0x6a, 0xf2, 0x48, + 0x1f, 0xbd, 0x04, 0x1b, 0x94, 0x67, 0x3f, 0x0e, 0x23, 0xda, 0x14, 0xf7, 0xe3, 0xee, 0x3d, 0xfb, + 0x0a, 0x4c, 0xa6, 0xa7, 0xae, 0x2f, 0x77, 0xf1, 0xff, 0x51, 0x82, 0x89, 0x8c, 0x8b, 0x2d, 0x96, + 0x8d, 0x39, 0xc5, 0x64, 0x93, 0xe4, 0xcb, 0x26, 0xab, 0x2c, 0x15, 0x60, 0x95, 0x92, 0x6f, 0x97, + 0x7b, 0xf2, 0x6d, 0xc1, 0x1e, 0x2b, 0xef, 0x87, 0x3d, 0x9a, 0x27, 0xd2, 0x40, 0xa1, 0x13, 0xe9, + 0x01, 0xb0, 0x54, 0xe3, 0x50, 0x1b, 0x2a, 0x70, 0xa8, 0x7d, 0xb5, 0x04, 0x93, 0x89, 0x6b, 0xbc, + 0x48, 0x83, 0x7e, 0xf4, 0x17, 0x1e, 0x6b, 0xc6, 0x85, 0x47, 0x5e, 0x96, 0xf3, 0x54, 0xff, 0x7a, + 0x5e, 0x7e, 0xbc, 0x91, 0xba, 0xfc, 0x78, 0xbe, 0x4f, 0xba, 0x07, 0x5f, 0x84, 0x7c, 0xab, 0x04, + 0x27, 0xd3, 0x55, 0x96, 0x5a, 0x8e, 0xb7, 0x75, 0x0c, 0xe3, 0xf5, 0x69, 0x63, 0xbc, 0x5e, 0xec, + 0xef, 0xbb, 0x58, 0x27, 0x7b, 0x0e, 0x9a, 0x93, 0x1a, 0xb4, 0x8f, 0x1f, 0x86, 0xf8, 0xc1, 0x23, + 0xf7, 0x47, 0x16, 0x3c, 0x9c, 0x59, 0xef, 0x18, 0x4c, 0xbc, 0xaf, 0x99, 0x26, 0xde, 0xe7, 0x0e, + 0xf1, 0x75, 0x3d, 0x6c, 0xbe, 0xbf, 0x59, 0xee, 0xf1, 0x55, 0xcc, 0x08, 0x76, 0x03, 0x46, 0x9c, + 0x66, 0x93, 0x44, 0xd1, 0xb5, 0xc0, 0x55, 0x89, 0xc5, 0x9e, 0x65, 0xa7, 0x58, 0x52, 0xbc, 0xbf, + 0x3b, 0x37, 0x9b, 0x26, 0x91, 0x80, 0xb1, 0x4e, 0xc1, 0x4c, 0x79, 0x58, 0x3a, 0xa2, 0x94, 0x87, + 0x17, 0x01, 0xb6, 0x95, 0xbe, 0x9c, 0xb6, 0xad, 0x69, 0x9a, 0xb4, 0x86, 0x85, 0xfe, 0x0a, 0x93, + 0x3d, 0xb9, 0x5f, 0x4a, 0xc5, 0x8c, 0xb2, 0xcd, 0x99, 0x3f, 0xdd, 0xc7, 0x85, 0x07, 0xf3, 0x2a, + 0x3b, 0xa4, 0x22, 0x89, 0x3e, 0x05, 0x93, 0x11, 0xcf, 0x49, 0xb1, 0xd4, 0x72, 0x22, 0x16, 0x13, + 0x22, 0xf8, 0x29, 0x8b, 0xcb, 0x6d, 0xa4, 0x60, 0xb8, 0x0b, 0xdb, 0xfe, 0x66, 0x19, 0x3e, 0x7c, + 0xc0, 0xb2, 0x45, 0x0b, 0xe6, 0xfd, 0xf0, 0x33, 0x69, 0x4b, 0xd3, 0x6c, 0x66, 0x65, 0xc3, 0xf4, + 0x94, 0x9a, 0xed, 0xd2, 0xfb, 0x9e, 0xed, 0x2f, 0xeb, 0x76, 0x41, 0xee, 0xaa, 0x7a, 0xe9, 0xd0, + 0x1b, 0xf3, 0x27, 0xf5, 0x5a, 0xe0, 0xb3, 0x16, 0x3c, 0x96, 0xf9, 0x59, 0x86, 0x3f, 0xca, 0x79, + 0xa8, 0x36, 0x69, 0xa1, 0x16, 0xc1, 0x95, 0x84, 0x4e, 0x4a, 0x00, 0x4e, 0x70, 0x0c, 0xb7, 0x93, + 0x52, 0xae, 0xdb, 0xc9, 0x1f, 0x58, 0x30, 0x9d, 0xee, 0xc4, 0x31, 0xf0, 0xad, 0x86, 0xc9, 0xb7, + 0xe6, 0xfb, 0x9b, 0xfc, 0x1e, 0x2c, 0xeb, 0xab, 0x93, 0x70, 0xaa, 0xeb, 0xd4, 0xe3, 0xa3, 0xf8, + 0x4b, 0x16, 0x4c, 0x6d, 0x30, 0x3d, 0x41, 0x0b, 0x93, 0x13, 0xdf, 0x95, 0x13, 0x5b, 0x78, 0x60, + 0x74, 0x1d, 0xd7, 0x7a, 0xba, 0x50, 0x70, 0x77, 0x63, 0xe8, 0x8b, 0x16, 0x4c, 0x3b, 0xf7, 0xa2, + 0xae, 0x47, 0x7a, 0xc4, 0x42, 0x7a, 0x25, 0xc7, 0x2c, 0x97, 0xf3, 0xbc, 0xcf, 0xe2, 0xcc, 0xde, + 0xee, 0xdc, 0x74, 0x16, 0x16, 0xce, 0x6c, 0x95, 0xce, 0xef, 0xa6, 0x08, 0x97, 0x29, 0x16, 0xf0, + 0x99, 0x15, 0x5c, 0xc3, 0xd9, 0x9a, 0x84, 0x60, 0x45, 0x11, 0xbd, 0x0d, 0xd5, 0x0d, 0x19, 0x19, + 0x97, 0x66, 0x9b, 0x3d, 0x86, 0x39, 0x2b, 0x90, 0x8e, 0x87, 0x2b, 0x28, 0x10, 0x4e, 0x88, 0xa2, + 0xcb, 0x50, 0xf6, 0xd7, 0x23, 0x11, 0x83, 0x9e, 0xe7, 0x6d, 0x64, 0xfa, 0x78, 0xf1, 0xb0, 0xdd, + 0xeb, 0x2b, 0x0d, 0x4c, 0x49, 0x50, 0x4a, 0xe1, 0x1d, 0x57, 0xd8, 0xa3, 0x73, 0x28, 0xe1, 0xc5, + 0x5a, 0x37, 0x25, 0xbc, 0x58, 0xc3, 0x94, 0x04, 0xaa, 0xc3, 0x00, 0x0b, 0xc6, 0x11, 0xc6, 0xe6, + 0x9c, 0x44, 0x05, 0x5d, 0x21, 0x47, 0x3c, 0x33, 0x27, 0x2b, 0xc6, 0x9c, 0x10, 0x5a, 0x83, 0xc1, + 0x26, 0x7b, 0x5c, 0x42, 0x58, 0x01, 0xf2, 0x52, 0x78, 0x74, 0x3d, 0x44, 0xc1, 0x6f, 0xd8, 0x78, + 0x39, 0x16, 0xb4, 0x18, 0x55, 0xd2, 0xde, 0x5c, 0x8f, 0x84, 0x9a, 0x9f, 0x47, 0xb5, 0xeb, 0x99, + 0x10, 0x41, 0x95, 0x95, 0x63, 0x41, 0x0b, 0xd5, 0xa0, 0xb4, 0xde, 0x14, 0xb1, 0x3a, 0x39, 0x46, + 0x66, 0x33, 0x06, 0x7b, 0x71, 0x70, 0x6f, 0x77, 0xae, 0xb4, 0xb2, 0x84, 0x4b, 0xeb, 0x4d, 0xf4, + 0x1a, 0x0c, 0xad, 0xf3, 0xa8, 0x5a, 0x91, 0xcc, 0xf7, 0x42, 0x5e, 0xe8, 0x6f, 0x57, 0x08, 0x2e, + 0x0f, 0x49, 0x11, 0x00, 0x2c, 0xc9, 0xb1, 0x3c, 0x87, 0x2a, 0x4e, 0x58, 0x64, 0xf3, 0x9d, 0xef, + 0x2f, 0xae, 0x58, 0x68, 0xbf, 0xaa, 0x14, 0x6b, 0x14, 0xe9, 0x9a, 0x77, 0xe4, 0x3b, 0x39, 0x2c, + 0x93, 0x6f, 0xee, 0x9a, 0xcf, 0x7c, 0x56, 0x87, 0xaf, 0x79, 0x05, 0xc2, 0x09, 0x51, 0xd4, 0x81, + 0xb1, 0xed, 0xa8, 0xbd, 0x49, 0xe4, 0xd6, 0x67, 0xe9, 0x7d, 0x47, 0x2e, 0x7e, 0x32, 0x27, 0x67, + 0xb3, 0xa8, 0xe2, 0x85, 0x71, 0xc7, 0x69, 0x75, 0x71, 0x30, 0x96, 0x58, 0xee, 0x96, 0x4e, 0x16, + 0x9b, 0xad, 0xd0, 0x29, 0x79, 0xb7, 0x13, 0xdc, 0xd9, 0x89, 0x89, 0x48, 0xff, 0x9b, 0x33, 0x25, + 0xaf, 0x72, 0xe4, 0xee, 0x29, 0x11, 0x00, 0x2c, 0xc9, 0xa9, 0x21, 0x63, 0xdc, 0x78, 0xb2, 0xf0, + 0x90, 0x75, 0x7d, 0x43, 0x32, 0x64, 0x8c, 0xfb, 0x26, 0x44, 0x19, 0xd7, 0x6d, 0x6f, 0x06, 0x71, + 0xe0, 0xa7, 0x78, 0xff, 0x54, 0x11, 0xae, 0x5b, 0xcf, 0xa8, 0xd9, 0xcd, 0x75, 0xb3, 0xb0, 0x70, + 0x66, 0xab, 0xc8, 0x87, 0xf1, 0x76, 0x10, 0xc6, 0xf7, 0x82, 0x50, 0xae, 0x43, 0x54, 0x48, 0x47, + 0x34, 0xea, 0x88, 0xb6, 0x99, 0xe7, 0xb1, 0x09, 0xc1, 0x29, 0xea, 0x74, 0xea, 0xa2, 0xa6, 0xd3, + 0x22, 0xab, 0x37, 0x66, 0x4e, 0x14, 0x99, 0xba, 0x06, 0x47, 0xee, 0x9e, 0x3a, 0x01, 0xc0, 0x92, + 0x1c, 0xe5, 0x75, 0x2c, 0x97, 0x3d, 0xcb, 0x66, 0x9c, 0xcb, 0xeb, 0xba, 0xbc, 0x73, 0x39, 0xaf, + 0x63, 0xc5, 0x98, 0x13, 0x42, 0xef, 0x40, 0x55, 0x08, 0xb7, 0x41, 0x34, 0x73, 0x92, 0x51, 0xfd, + 0xd9, 0x9c, 0xde, 0x72, 0xf4, 0x1b, 0x8d, 0xec, 0x53, 0x5f, 0x44, 0xff, 0x49, 0x24, 0x9c, 0x90, + 0xb7, 0x7f, 0x63, 0xb0, 0x5b, 0xec, 0x61, 0x8a, 0xcd, 0xdf, 0xe8, 0xbe, 0xb1, 0xfe, 0x54, 0xff, + 0xfa, 0xfb, 0x03, 0xbc, 0xbb, 0xfe, 0xa2, 0x05, 0xa7, 0xda, 0x99, 0x9f, 0x27, 0x04, 0x87, 0x7e, + 0xcd, 0x00, 0x7c, 0x68, 0x54, 0x8e, 0xf1, 0x6c, 0x38, 0xee, 0xd1, 0x66, 0x5a, 0x15, 0x28, 0xbf, + 0x6f, 0x55, 0xe0, 0x36, 0x0c, 0x33, 0xd9, 0x35, 0xc9, 0xef, 0xd3, 0x67, 0x2a, 0x1c, 0x26, 0x82, + 0x2c, 0x09, 0x12, 0x58, 0x11, 0xa3, 0x03, 0xf7, 0x68, 0xfa, 0x23, 0x30, 0x61, 0x60, 0x91, 0xd9, + 0x92, 0xeb, 0x59, 0x2b, 0x62, 0x24, 0x1e, 0xad, 0x1f, 0x84, 0xbc, 0x9f, 0x87, 0x80, 0x0f, 0x6e, + 0x0c, 0xd5, 0x32, 0x14, 0xbd, 0x41, 0xf3, 0x7a, 0x2a, 0x5f, 0xd9, 0x3b, 0x5e, 0x05, 0xe5, 0x1f, + 0x5a, 0x19, 0xf2, 0x34, 0x57, 0x2a, 0x3f, 0x69, 0x2a, 0x95, 0x4f, 0xa6, 0x95, 0xca, 0x2e, 0x53, + 0x92, 0xa1, 0x4f, 0x16, 0xcf, 0xcc, 0x5b, 0x34, 0x81, 0x91, 0xdd, 0x82, 0x33, 0x79, 0xcc, 0x9a, + 0xb9, 0xac, 0xb9, 0xea, 0xb2, 0x36, 0x71, 0x59, 0x73, 0x57, 0x6b, 0x98, 0x41, 0x8a, 0xe6, 0xc0, + 0xb0, 0x7f, 0xb9, 0x04, 0xe5, 0x7a, 0xe0, 0x1e, 0x83, 0x69, 0xec, 0x92, 0x61, 0x1a, 0x7b, 0x22, + 0xf7, 0xa1, 0xc8, 0x9e, 0x86, 0xb0, 0x1b, 0x29, 0x43, 0xd8, 0xcf, 0xe4, 0x93, 0x3a, 0xd8, 0xec, + 0xf5, 0xed, 0x32, 0xe8, 0x4f, 0x5d, 0xa2, 0xff, 0x70, 0x18, 0x4f, 0xe6, 0x72, 0xb1, 0xd7, 0x2f, + 0x45, 0x1b, 0xcc, 0xe3, 0x4d, 0x06, 0x62, 0xfe, 0xc4, 0x3a, 0x34, 0xdf, 0x26, 0xde, 0xc6, 0x66, + 0x4c, 0xdc, 0xf4, 0x87, 0x1d, 0x9f, 0x43, 0xf3, 0x5f, 0x58, 0x30, 0x91, 0x6a, 0x1d, 0xb5, 0xb2, + 0x22, 0xb8, 0x0e, 0x69, 0xec, 0x9a, 0xca, 0x0d, 0xf9, 0x9a, 0x07, 0x50, 0x77, 0x16, 0xd2, 0xa0, + 0xc4, 0x64, 0x6b, 0x75, 0xa9, 0x11, 0x61, 0x0d, 0x03, 0xbd, 0x00, 0x23, 0x71, 0xd0, 0x0e, 0x5a, + 0xc1, 0xc6, 0xce, 0x15, 0x22, 0xb3, 0xb3, 0xa8, 0x9b, 0xa5, 0xb5, 0x04, 0x84, 0x75, 0x3c, 0xfb, + 0x3b, 0x65, 0x48, 0x3f, 0x94, 0xfa, 0xff, 0xd7, 0xe9, 0x4f, 0xce, 0x3a, 0xfd, 0x63, 0x0b, 0x26, + 0x69, 0xeb, 0xcc, 0xc5, 0x48, 0x3a, 0x1e, 0xab, 0x67, 0x42, 0xac, 0x03, 0x9e, 0x09, 0x79, 0x92, + 0x72, 0x3b, 0x37, 0xe8, 0xc4, 0xc2, 0x04, 0xa6, 0x31, 0x31, 0x5a, 0x8a, 0x05, 0x54, 0xe0, 0x91, + 0x30, 0x14, 0x11, 0x5a, 0x3a, 0x1e, 0x09, 0x43, 0x2c, 0xa0, 0xf2, 0x15, 0x91, 0x4a, 0x8f, 0x57, + 0x44, 0x58, 0x7e, 0x33, 0xe1, 0xd6, 0x22, 0xc4, 0x0a, 0x2d, 0xbf, 0x99, 0xf4, 0x77, 0x49, 0x70, + 0xec, 0xaf, 0x97, 0x61, 0xb4, 0x1e, 0xb8, 0x49, 0x44, 0xc1, 0xf3, 0x46, 0x44, 0xc1, 0x99, 0x54, + 0x44, 0xc1, 0xa4, 0x8e, 0xfb, 0x60, 0x02, 0x0a, 0x44, 0x1e, 0x3c, 0xf6, 0xce, 0xcd, 0x21, 0x83, + 0x09, 0x8c, 0x3c, 0x78, 0x8a, 0x10, 0x36, 0xe9, 0xfe, 0x34, 0x05, 0x11, 0xfc, 0x6f, 0x0b, 0xc6, + 0xeb, 0x81, 0x4b, 0x17, 0xe8, 0x4f, 0xd3, 0x6a, 0xd4, 0xb3, 0xe7, 0x0d, 0x1e, 0x90, 0x3d, 0xef, + 0x9f, 0x5b, 0x30, 0x54, 0x0f, 0xdc, 0x63, 0x30, 0x0f, 0xaf, 0x98, 0xe6, 0xe1, 0xc7, 0x72, 0x39, + 0x6f, 0x0f, 0x8b, 0xf0, 0x37, 0xcb, 0x30, 0x46, 0x7b, 0x1c, 0x6c, 0xc8, 0xf9, 0x32, 0xc6, 0xc6, + 0x2a, 0x30, 0x36, 0x54, 0x24, 0x0c, 0x5a, 0xad, 0xe0, 0x5e, 0x7a, 0xee, 0x56, 0x58, 0x29, 0x16, + 0x50, 0x74, 0x0e, 0x86, 0xdb, 0x21, 0xd9, 0xf6, 0x82, 0x4e, 0x94, 0x8e, 0xf6, 0xac, 0x8b, 0x72, + 0xac, 0x30, 0xd0, 0xf3, 0x30, 0x1a, 0x79, 0x7e, 0x93, 0x48, 0xa7, 0x97, 0x0a, 0x73, 0x7a, 0xe1, + 0x89, 0x4a, 0xb5, 0x72, 0x6c, 0x60, 0xa1, 0xdb, 0x50, 0x65, 0xff, 0xd9, 0x0e, 0xea, 0xff, 0x19, + 0x10, 0xae, 0x0e, 0x4b, 0x02, 0x38, 0xa1, 0x85, 0x2e, 0x02, 0xc4, 0xd2, 0x3d, 0x27, 0x12, 0x61, + 0xc9, 0x4a, 0x2e, 0x55, 0x8e, 0x3b, 0x11, 0xd6, 0xb0, 0xd0, 0x33, 0x50, 0x8d, 0x1d, 0xaf, 0x75, + 0xd5, 0xf3, 0x49, 0x24, 0xdc, 0x9b, 0x44, 0xd2, 0x71, 0x51, 0x88, 0x13, 0x38, 0x3d, 0xef, 0x59, + 0xd0, 0x3b, 0x7f, 0x62, 0x68, 0x98, 0x61, 0xb3, 0xf3, 0xfe, 0xaa, 0x2a, 0xc5, 0x1a, 0x86, 0xfd, + 0x12, 0x9c, 0xac, 0x07, 0x6e, 0x3d, 0x08, 0xe3, 0x95, 0x20, 0xbc, 0xe7, 0x84, 0xae, 0x9c, 0xbf, + 0x39, 0x99, 0xeb, 0x9a, 0x9e, 0xc9, 0x03, 0xdc, 0x8a, 0x60, 0xe4, 0xae, 0x7e, 0x8e, 0x9d, 0xf8, + 0x7d, 0x86, 0xaa, 0xfc, 0xa0, 0x04, 0xa8, 0xce, 0x1c, 0x88, 0x8c, 0x17, 0xa9, 0x36, 0x61, 0x3c, + 0x22, 0x57, 0x3d, 0xbf, 0x73, 0x5f, 0x90, 0x2a, 0x16, 0x1b, 0xd4, 0x58, 0xd6, 0xeb, 0x70, 0x3b, + 0x8d, 0x59, 0x86, 0x53, 0x74, 0xe9, 0x60, 0x86, 0x1d, 0x7f, 0x21, 0xba, 0x19, 0x91, 0x50, 0xbc, + 0xc0, 0xc4, 0x06, 0x13, 0xcb, 0x42, 0x9c, 0xc0, 0xe9, 0xe2, 0x61, 0x7f, 0xae, 0x07, 0x3e, 0x0e, + 0x82, 0x58, 0x2e, 0x37, 0xf6, 0x22, 0x87, 0x56, 0x8e, 0x0d, 0x2c, 0xb4, 0x02, 0x28, 0xea, 0xb4, + 0xdb, 0x2d, 0x76, 0x53, 0xea, 0xb4, 0x2e, 0x85, 0x41, 0xa7, 0xcd, 0xfd, 0xc8, 0xc5, 0x63, 0x16, + 0x8d, 0x2e, 0x28, 0xce, 0xa8, 0x41, 0x99, 0xc5, 0x7a, 0xc4, 0x7e, 0x8b, 0x08, 0x78, 0x6e, 0x6d, + 0x6d, 0xb0, 0x22, 0x2c, 0x61, 0xf6, 0x2f, 0xb2, 0x03, 0x8e, 0x3d, 0x8d, 0x13, 0x77, 0x42, 0x82, + 0xb6, 0x60, 0xac, 0xcd, 0x0e, 0xb1, 0x38, 0x0c, 0x5a, 0x2d, 0x22, 0xe5, 0xcb, 0xc3, 0xb9, 0x30, + 0xf1, 0xc7, 0x30, 0x74, 0x72, 0xd8, 0xa4, 0x6e, 0xff, 0xb7, 0x71, 0xc6, 0xab, 0xc4, 0x65, 0xf5, + 0x90, 0x70, 0x56, 0x16, 0x92, 0xdc, 0x47, 0x8a, 0x3c, 0x72, 0x97, 0x9c, 0x03, 0xc2, 0xf5, 0x19, + 0x4b, 0x2a, 0xe8, 0x33, 0xcc, 0x15, 0x9f, 0x33, 0x88, 0xe2, 0x4f, 0x77, 0x72, 0x7c, 0xc3, 0x0d, + 0x5f, 0x90, 0xc0, 0x1a, 0x39, 0x74, 0x15, 0xc6, 0xc4, 0x4b, 0x2a, 0xc2, 0x4c, 0x51, 0x36, 0x54, + 0xec, 0x31, 0xac, 0x03, 0xf7, 0xd3, 0x05, 0xd8, 0xac, 0x8c, 0x36, 0xe0, 0x51, 0xed, 0xa5, 0xb0, + 0x0c, 0x77, 0x3b, 0xce, 0x79, 0x1e, 0xdb, 0xdb, 0x9d, 0x7b, 0x74, 0xed, 0x20, 0x44, 0x7c, 0x30, + 0x1d, 0x74, 0x03, 0x4e, 0x3a, 0xcd, 0xd8, 0xdb, 0x26, 0x35, 0xe2, 0xb8, 0x2d, 0xcf, 0x27, 0x66, + 0x9a, 0x84, 0x87, 0xf7, 0x76, 0xe7, 0x4e, 0x2e, 0x64, 0x21, 0xe0, 0xec, 0x7a, 0xe8, 0x93, 0x50, + 0x75, 0xfd, 0x48, 0x8c, 0xc1, 0xa0, 0xf1, 0x30, 0x5e, 0xb5, 0x76, 0xbd, 0xa1, 0xbe, 0x3f, 0xf9, + 0x83, 0x93, 0x0a, 0xe8, 0x5d, 0x18, 0xd5, 0xc3, 0x9f, 0xc4, 0x83, 0x8c, 0x2f, 0x16, 0xd2, 0x9f, + 0x8d, 0x98, 0x21, 0x6e, 0xc1, 0x53, 0x6e, 0xad, 0x46, 0x38, 0x91, 0xd1, 0x04, 0xfa, 0x79, 0x40, + 0x11, 0x09, 0xb7, 0xbd, 0x26, 0x59, 0x68, 0xb2, 0xec, 0xbe, 0xcc, 0xc6, 0x33, 0x6c, 0xc4, 0x77, + 0xa0, 0x46, 0x17, 0x06, 0xce, 0xa8, 0x85, 0x2e, 0x53, 0xce, 0xa3, 0x97, 0x0a, 0x2f, 0x64, 0x29, + 0x18, 0xce, 0xd4, 0x48, 0x3b, 0x24, 0x4d, 0x27, 0x26, 0xae, 0x49, 0x11, 0xa7, 0xea, 0xd1, 0x73, + 0x49, 0x3d, 0xe0, 0x00, 0xa6, 0xef, 0x6c, 0xf7, 0x23, 0x0e, 0x54, 0xcf, 0xda, 0x0c, 0xa2, 0xf8, + 0x3a, 0x89, 0xef, 0x05, 0xe1, 0x5d, 0x91, 0x11, 0x2d, 0x49, 0x95, 0x98, 0x80, 0xb0, 0x8e, 0x47, + 0x65, 0x28, 0x76, 0xf5, 0xb7, 0x5a, 0x63, 0xf7, 0x2a, 0xc3, 0xc9, 0xde, 0xb9, 0xcc, 0x8b, 0xb1, + 0x84, 0x4b, 0xd4, 0xd5, 0xfa, 0x12, 0xbb, 0x23, 0x49, 0xa1, 0xae, 0xd6, 0x97, 0xb0, 0x84, 0xa3, + 0xa0, 0xfb, 0xf9, 0xc1, 0xf1, 0x22, 0xf7, 0x55, 0xdd, 0x9c, 0xbc, 0xe0, 0x0b, 0x84, 0xf7, 0x61, + 0x52, 0x3d, 0x81, 0xc8, 0x93, 0xc6, 0x45, 0x33, 0x13, 0x6c, 0xe1, 0x1c, 0x26, 0xf7, 0x9c, 0xb2, + 0xeb, 0xad, 0xa6, 0x68, 0xe2, 0xae, 0x56, 0x8c, 0xe4, 0x1c, 0x93, 0xb9, 0x8f, 0x72, 0x9c, 0x87, + 0x6a, 0xd4, 0xb9, 0xe3, 0x06, 0x5b, 0x8e, 0xe7, 0xb3, 0x8b, 0x0c, 0x4d, 0x88, 0x69, 0x48, 0x00, + 0x4e, 0x70, 0x50, 0x1d, 0x86, 0x1d, 0xa1, 0xc2, 0x89, 0x0b, 0x87, 0x9c, 0x28, 0x7c, 0xa9, 0xf0, + 0x71, 0xeb, 0xaa, 0xfc, 0x87, 0x15, 0x15, 0xf4, 0x32, 0x8c, 0x89, 0x20, 0x32, 0xe1, 0xec, 0x79, + 0xc2, 0x0c, 0x38, 0x68, 0xe8, 0x40, 0x6c, 0xe2, 0xa2, 0x0d, 0x18, 0xa7, 0x54, 0x12, 0x06, 0x38, + 0x33, 0xdd, 0x1f, 0x0f, 0xd5, 0xd2, 0x9f, 0xeb, 0x64, 0x70, 0x8a, 0x2c, 0x72, 0xe1, 0x11, 0xa7, + 0x13, 0x07, 0x5b, 0x74, 0x27, 0x98, 0xfb, 0x64, 0x2d, 0xb8, 0x4b, 0x7c, 0x76, 0xcb, 0x30, 0xbc, + 0x78, 0x66, 0x6f, 0x77, 0xee, 0x91, 0x85, 0x03, 0xf0, 0xf0, 0x81, 0x54, 0xd0, 0x5b, 0x30, 0x12, + 0x07, 0x2d, 0xe1, 0xc3, 0x1d, 0xcd, 0x9c, 0x2a, 0x92, 0x84, 0x68, 0x4d, 0x55, 0xd0, 0xcd, 0x18, + 0x8a, 0x08, 0xd6, 0x29, 0xa2, 0x37, 0xf9, 0xae, 0x64, 0x09, 0x33, 0x49, 0x34, 0xf3, 0x50, 0x91, + 0xc1, 0x52, 0x19, 0x36, 0xcd, 0xed, 0x2b, 0x68, 0x60, 0x9d, 0xe0, 0xec, 0xcf, 0xc1, 0x54, 0x17, + 0xcb, 0xeb, 0xcb, 0xb9, 0xf5, 0x3f, 0x0e, 0x40, 0x55, 0x59, 0x0c, 0xd1, 0x79, 0xd3, 0x38, 0xfc, + 0x70, 0xda, 0x38, 0x3c, 0x4c, 0x05, 0x34, 0xdd, 0x1e, 0xfc, 0x66, 0xc6, 0xa3, 0xfa, 0x4f, 0xe7, + 0xee, 0xf1, 0xe2, 0x91, 0x6d, 0x9a, 0x8a, 0x57, 0x2e, 0x6c, 0x6f, 0xae, 0x1c, 0xa8, 0x35, 0x16, + 0x7c, 0x28, 0x92, 0xea, 0x87, 0xed, 0xc0, 0x5d, 0xad, 0xa7, 0xdf, 0x41, 0xab, 0xd3, 0x42, 0xcc, + 0x61, 0x4c, 0xae, 0xa7, 0x67, 0x36, 0x93, 0xeb, 0x87, 0x0e, 0x29, 0xd7, 0x4b, 0x02, 0x38, 0xa1, + 0x85, 0xb6, 0x61, 0xaa, 0x69, 0x3e, 0x6b, 0xa7, 0xe2, 0xd5, 0x9e, 0xed, 0xe3, 0x59, 0xb9, 0x8e, + 0xf6, 0x22, 0xcd, 0x52, 0x9a, 0x1e, 0xee, 0x6e, 0x02, 0xbd, 0x0c, 0xc3, 0xef, 0x06, 0x11, 0xbb, + 0xb6, 0x10, 0x07, 0x97, 0x8c, 0x0b, 0x1a, 0x7e, 0xf5, 0x46, 0x83, 0x95, 0xef, 0xef, 0xce, 0x8d, + 0xd4, 0x03, 0x57, 0xfe, 0xc5, 0xaa, 0x02, 0xfa, 0xac, 0x05, 0x27, 0x8d, 0x7d, 0xac, 0x7a, 0x0e, + 0x87, 0xe9, 0xf9, 0xa3, 0xa2, 0xe5, 0x93, 0xab, 0x59, 0x34, 0x71, 0x76, 0x53, 0xf6, 0x77, 0xb9, + 0x89, 0x54, 0x18, 0x4d, 0x48, 0xd4, 0x69, 0x1d, 0xc7, 0xeb, 0x10, 0x37, 0x0c, 0x7b, 0xce, 0x03, + 0x30, 0xd2, 0xff, 0x7b, 0x8b, 0x19, 0xe9, 0xd7, 0xc8, 0x56, 0xbb, 0xe5, 0xc4, 0xc7, 0xe1, 0xfb, + 0xfc, 0x19, 0x18, 0x8e, 0x45, 0x6b, 0xc5, 0x9e, 0xb6, 0xd0, 0xba, 0xc7, 0x2e, 0x2f, 0xd4, 0xc1, + 0x27, 0x4b, 0xb1, 0x22, 0x68, 0xff, 0x2b, 0x3e, 0x2b, 0x12, 0x72, 0x0c, 0x96, 0x88, 0xeb, 0xa6, + 0x25, 0xe2, 0xa9, 0xc2, 0xdf, 0xd2, 0xc3, 0x22, 0xf1, 0x1d, 0xf3, 0x0b, 0x98, 0x7e, 0xf2, 0x93, + 0x73, 0x8b, 0x64, 0xff, 0xba, 0x05, 0xd3, 0x59, 0xce, 0x08, 0x54, 0x80, 0xe1, 0xda, 0x91, 0xba, + 0x5f, 0x53, 0xa3, 0x7a, 0x4b, 0x94, 0x63, 0x85, 0x51, 0x38, 0xd7, 0x7c, 0x7f, 0x29, 0xb4, 0x6e, + 0x80, 0xf9, 0x40, 0x22, 0x7a, 0x85, 0x87, 0x3a, 0x58, 0xea, 0x05, 0xc3, 0xfe, 0xc2, 0x1c, 0xec, + 0x6f, 0x94, 0x60, 0x9a, 0x1b, 0xb9, 0x17, 0xb6, 0x03, 0xcf, 0xad, 0x07, 0xae, 0x08, 0xfc, 0x70, + 0x61, 0xb4, 0xad, 0x29, 0xb7, 0xc5, 0x52, 0xf2, 0xe8, 0xea, 0x70, 0xa2, 0x50, 0xe8, 0xa5, 0xd8, + 0xa0, 0x4a, 0x5b, 0x21, 0xdb, 0x5e, 0x53, 0xd9, 0x4c, 0x4b, 0x7d, 0x9f, 0x0c, 0xaa, 0x95, 0x65, + 0x8d, 0x0e, 0x36, 0xa8, 0x1e, 0xc1, 0x13, 0x31, 0xf6, 0xdf, 0xb7, 0xe0, 0xa1, 0x1e, 0x69, 0x7b, + 0x68, 0x73, 0xf7, 0xd8, 0xc5, 0x82, 0x78, 0x81, 0x53, 0x35, 0xc7, 0xaf, 0x1b, 0xb0, 0x80, 0xa2, + 0x3b, 0x00, 0xfc, 0xba, 0x80, 0xca, 0xd2, 0xe9, 0xbb, 0xec, 0x82, 0xc9, 0x31, 0xb4, 0xbc, 0x09, + 0x92, 0x12, 0xd6, 0xa8, 0xda, 0x5f, 0x2b, 0xc3, 0x00, 0x7f, 0xe8, 0xbd, 0x0e, 0x43, 0x9b, 0x3c, + 0x9f, 0x71, 0x7f, 0xe9, 0x94, 0x13, 0xe5, 0x85, 0x17, 0x60, 0x49, 0x06, 0x5d, 0x83, 0x13, 0x22, + 0xf4, 0xa8, 0x46, 0x5a, 0xce, 0x8e, 0xd4, 0x86, 0xf9, 0xbb, 0x21, 0x32, 0xc1, 0xfd, 0x89, 0xd5, + 0x6e, 0x14, 0x9c, 0x55, 0x0f, 0xbd, 0xd2, 0x95, 0x7e, 0x90, 0xe7, 0x89, 0x56, 0x92, 0x70, 0x4e, + 0x0a, 0xc2, 0x97, 0x61, 0xac, 0xdd, 0xa5, 0xf7, 0x6b, 0xef, 0x69, 0x9b, 0xba, 0xbe, 0x89, 0xcb, + 0x7c, 0x17, 0x3a, 0xcc, 0x67, 0x63, 0x6d, 0x33, 0x24, 0xd1, 0x66, 0xd0, 0x72, 0xc5, 0x53, 0xb0, + 0x89, 0xef, 0x42, 0x0a, 0x8e, 0xbb, 0x6a, 0x50, 0x2a, 0xeb, 0x8e, 0xd7, 0xea, 0x84, 0x24, 0xa1, + 0x32, 0x68, 0x52, 0x59, 0x49, 0xc1, 0x71, 0x57, 0x0d, 0xba, 0xb6, 0x4e, 0x8a, 0xd7, 0x43, 0x65, + 0x90, 0xba, 0x60, 0x41, 0x9f, 0x86, 0x21, 0x19, 0x40, 0x50, 0x28, 0x97, 0x8a, 0x70, 0x4c, 0x50, + 0x2f, 0x91, 0x6a, 0xef, 0xc8, 0x89, 0xd0, 0x01, 0x49, 0xef, 0x30, 0xaf, 0x54, 0xfe, 0xb9, 0x05, + 0x27, 0x32, 0x1c, 0xe1, 0x38, 0x4b, 0xdb, 0xf0, 0xa2, 0x58, 0xbd, 0x62, 0xa1, 0xb1, 0x34, 0x5e, + 0x8e, 0x15, 0x06, 0xdd, 0x2d, 0x9c, 0x69, 0xa6, 0x19, 0xa5, 0x70, 0x31, 0x11, 0xd0, 0xfe, 0x18, + 0x25, 0x3a, 0x03, 0x95, 0x4e, 0x44, 0x42, 0xf9, 0xa0, 0xa3, 0xe4, 0xf3, 0xcc, 0xce, 0xc8, 0x20, + 0x54, 0x6c, 0xdd, 0x50, 0x26, 0x3e, 0x4d, 0x6c, 0xe5, 0x46, 0x3e, 0x0e, 0xb3, 0xbf, 0x5c, 0x86, + 0x89, 0x94, 0x43, 0x2c, 0xed, 0xc8, 0x56, 0xe0, 0x7b, 0x71, 0xa0, 0xf2, 0xdb, 0xf1, 0x37, 0xe4, + 0x48, 0x7b, 0xf3, 0x9a, 0x28, 0xc7, 0x0a, 0x03, 0x3d, 0x29, 0x5f, 0x09, 0x4e, 0xbf, 0xce, 0xb1, + 0x58, 0x33, 0x1e, 0x0a, 0x2e, 0xfa, 0xb2, 0xce, 0xe3, 0x50, 0x69, 0x07, 0xea, 0xd1, 0x77, 0x35, + 0x9f, 0x78, 0xb1, 0x56, 0x0f, 0x82, 0x16, 0x66, 0x40, 0xf4, 0x84, 0xf8, 0xfa, 0xd4, 0xcd, 0x08, + 0x76, 0xdc, 0x20, 0xd2, 0x86, 0xe0, 0x29, 0x18, 0xba, 0x4b, 0x76, 0x42, 0xcf, 0xdf, 0x48, 0xdf, + 0x0b, 0x5d, 0xe1, 0xc5, 0x58, 0xc2, 0xcd, 0x64, 0xf5, 0x43, 0x47, 0xfc, 0x7a, 0xce, 0x70, 0xee, + 0x39, 0xf8, 0x4d, 0x0b, 0x26, 0x58, 0xf6, 0x59, 0x91, 0x22, 0xc1, 0x0b, 0xfc, 0x63, 0x90, 0x31, + 0x1e, 0x87, 0x81, 0x90, 0x36, 0x9a, 0x7e, 0xfe, 0x82, 0xf5, 0x04, 0x73, 0x18, 0x7a, 0x04, 0x2a, + 0xac, 0x0b, 0x74, 0x1a, 0x47, 0x79, 0x92, 0xfb, 0x9a, 0x13, 0x3b, 0x98, 0x95, 0xb2, 0x18, 0x34, + 0x4c, 0xda, 0x2d, 0x8f, 0x77, 0x3a, 0x31, 0xe7, 0x7e, 0xd0, 0x62, 0xd0, 0x32, 0x3b, 0xf9, 0xa0, + 0x62, 0xd0, 0xb2, 0x89, 0x1f, 0x2c, 0xe7, 0xff, 0xf7, 0x12, 0x9c, 0xce, 0xac, 0x97, 0xdc, 0x30, + 0xaf, 0x18, 0x37, 0xcc, 0x17, 0x53, 0x37, 0xcc, 0xf6, 0xc1, 0xb5, 0x1f, 0xcc, 0x9d, 0x73, 0xf6, + 0x55, 0x70, 0xf9, 0x18, 0xaf, 0x82, 0x2b, 0x45, 0x45, 0x9c, 0x81, 0x1c, 0x11, 0xe7, 0x8f, 0x2c, + 0x78, 0x38, 0x73, 0xc8, 0x3e, 0x70, 0x41, 0x7f, 0x99, 0xbd, 0xec, 0xa1, 0x9d, 0xfc, 0x5a, 0xb9, + 0xc7, 0x57, 0x31, 0x3d, 0xe5, 0x2c, 0xe5, 0x42, 0x0c, 0x18, 0x09, 0xe1, 0x6d, 0x94, 0x73, 0x20, + 0x5e, 0x86, 0x15, 0x14, 0x45, 0x5a, 0xd0, 0x1c, 0xef, 0xe4, 0xf2, 0x21, 0x37, 0xd4, 0xbc, 0x69, + 0x87, 0xd7, 0xf3, 0x3e, 0xa4, 0x43, 0xe9, 0x6e, 0x6b, 0x9a, 0x67, 0xf9, 0x30, 0x9a, 0xe7, 0x68, + 0xb6, 0xd6, 0x89, 0x16, 0x60, 0x62, 0xcb, 0xf3, 0xd9, 0xa3, 0xbb, 0xa6, 0xf4, 0xa4, 0x22, 0x97, + 0xaf, 0x99, 0x60, 0x9c, 0xc6, 0x9f, 0x7d, 0x19, 0xc6, 0x0e, 0x6f, 0x5d, 0xfb, 0x51, 0x19, 0x3e, + 0x7c, 0x00, 0x53, 0xe0, 0xa7, 0x83, 0x31, 0x2f, 0xda, 0xe9, 0xd0, 0x35, 0x37, 0x75, 0x98, 0x5e, + 0xef, 0xb4, 0x5a, 0x3b, 0xcc, 0x3f, 0x8b, 0xb8, 0x12, 0x43, 0x08, 0x35, 0x2a, 0x19, 0xf5, 0x4a, + 0x06, 0x0e, 0xce, 0xac, 0x89, 0x7e, 0x1e, 0x50, 0x70, 0x87, 0xa5, 0x45, 0x76, 0x93, 0xbc, 0x16, + 0x6c, 0x0a, 0xca, 0xc9, 0x56, 0xbd, 0xd1, 0x85, 0x81, 0x33, 0x6a, 0x51, 0x39, 0x95, 0x9e, 0x63, + 0x3b, 0xaa, 0x5b, 0x29, 0x39, 0x15, 0xeb, 0x40, 0x6c, 0xe2, 0xa2, 0x4b, 0x30, 0xe5, 0x6c, 0x3b, + 0x1e, 0x4f, 0x73, 0x26, 0x09, 0x70, 0x41, 0x55, 0xd9, 0xaf, 0x16, 0xd2, 0x08, 0xb8, 0xbb, 0x0e, + 0x6a, 0x1b, 0x06, 0x49, 0xfe, 0x32, 0xc3, 0x27, 0x0f, 0xb1, 0x82, 0x0b, 0x9b, 0x28, 0xed, 0x3f, + 0xb5, 0xe8, 0xd1, 0x97, 0xf1, 0x3e, 0x2b, 0x1d, 0x11, 0x65, 0x60, 0xd3, 0x82, 0x00, 0xd5, 0x88, + 0x2c, 0xe9, 0x40, 0x6c, 0xe2, 0xf2, 0xa5, 0x11, 0x25, 0xee, 0xe2, 0x86, 0xb4, 0x29, 0xe2, 0x67, + 0x15, 0x06, 0x95, 0xa0, 0x5d, 0x6f, 0xdb, 0x8b, 0x82, 0x50, 0x6c, 0xa0, 0x7e, 0x5f, 0x41, 0x57, + 0xfc, 0xb2, 0xc6, 0xc9, 0x60, 0x49, 0xcf, 0xfe, 0x4a, 0x09, 0xc6, 0x64, 0x8b, 0xaf, 0x76, 0x82, + 0xd8, 0x39, 0x86, 0x23, 0xfd, 0x55, 0xe3, 0x48, 0x3f, 0x5f, 0x2c, 0x9c, 0x98, 0x75, 0xae, 0xe7, + 0x51, 0xfe, 0xe9, 0xd4, 0x51, 0x7e, 0xa1, 0x1f, 0xa2, 0x07, 0x1f, 0xe1, 0xff, 0xc6, 0x82, 0x29, + 0x03, 0xff, 0x18, 0x4e, 0x92, 0xba, 0x79, 0x92, 0x3c, 0xd3, 0xc7, 0xd7, 0xf4, 0x38, 0x41, 0xbe, + 0x5e, 0x4a, 0x7d, 0x05, 0x3b, 0x39, 0x7e, 0x01, 0x2a, 0x9b, 0x4e, 0xe8, 0x16, 0xcb, 0xf9, 0xd9, + 0x55, 0x7d, 0xfe, 0xb2, 0x13, 0xba, 0x9c, 0xff, 0x9f, 0x53, 0xaf, 0xc7, 0x39, 0xa1, 0x9b, 0x1b, + 0x45, 0xc1, 0x1a, 0x45, 0x2f, 0xc1, 0x60, 0xd4, 0x0c, 0xda, 0xca, 0xcf, 0xf4, 0x0c, 0x7f, 0x59, + 0x8e, 0x96, 0xec, 0xef, 0xce, 0x21, 0xb3, 0x39, 0x5a, 0x8c, 0x05, 0xfe, 0xec, 0x06, 0x54, 0x55, + 0xd3, 0x47, 0xea, 0x69, 0xff, 0x5f, 0xcb, 0x70, 0x22, 0x63, 0xad, 0xa0, 0x5f, 0x34, 0xc6, 0xed, + 0xe5, 0xbe, 0x17, 0xdb, 0xfb, 0x1c, 0xb9, 0x5f, 0x64, 0x9a, 0x92, 0x2b, 0x56, 0xc7, 0x21, 0x9a, + 0xbf, 0x19, 0x91, 0x74, 0xf3, 0xb4, 0x28, 0xbf, 0x79, 0xda, 0xec, 0xb1, 0x0d, 0x3f, 0x6d, 0x48, + 0xf5, 0xf4, 0x48, 0xe7, 0xf9, 0x0b, 0x15, 0x98, 0xce, 0xca, 0x5b, 0x80, 0x7e, 0xc5, 0x4a, 0xbd, + 0x30, 0xf2, 0x4a, 0xff, 0xc9, 0x0f, 0xf8, 0xb3, 0x23, 0x22, 0xab, 0xd0, 0xbc, 0xf9, 0xe6, 0x48, + 0xee, 0x88, 0x8b, 0xd6, 0x59, 0xfc, 0x53, 0xc8, 0x5f, 0x8b, 0x91, 0x5c, 0xe1, 0x53, 0x87, 0xe8, + 0x8a, 0x78, 0x70, 0x26, 0x4a, 0xc5, 0x3f, 0xc9, 0xe2, 0xfc, 0xf8, 0x27, 0xd9, 0x87, 0x59, 0x0f, + 0x46, 0xb4, 0xef, 0x3a, 0xd2, 0x65, 0x70, 0x97, 0x1e, 0x51, 0x5a, 0xbf, 0x8f, 0x74, 0x29, 0xfc, + 0x1d, 0x0b, 0x52, 0x4e, 0x61, 0xca, 0x2c, 0x63, 0xf5, 0x34, 0xcb, 0x9c, 0x81, 0x4a, 0x18, 0xb4, + 0x48, 0xfa, 0xd1, 0x09, 0x1c, 0xb4, 0x08, 0x66, 0x10, 0xf5, 0xa0, 0x74, 0xb9, 0xd7, 0x83, 0xd2, + 0x54, 0x4f, 0x6f, 0x91, 0x6d, 0x22, 0x8d, 0x24, 0x8a, 0x8d, 0x5f, 0xa5, 0x85, 0x98, 0xc3, 0xec, + 0xdf, 0xa9, 0xc0, 0x89, 0x8c, 0x58, 0x40, 0xaa, 0x21, 0x6d, 0x38, 0x31, 0xb9, 0xe7, 0xec, 0xa4, + 0x93, 0xdf, 0x5e, 0xe2, 0xc5, 0x58, 0xc2, 0x99, 0x33, 0x2b, 0x4f, 0xa0, 0x97, 0x32, 0x5d, 0x89, + 0xbc, 0x79, 0x02, 0x7a, 0xf4, 0x4f, 0x0f, 0x5f, 0x04, 0x88, 0xa2, 0xd6, 0xb2, 0x4f, 0x25, 0x3c, + 0x57, 0x38, 0xcd, 0x26, 0x79, 0x17, 0x1b, 0x57, 0x05, 0x04, 0x6b, 0x58, 0xa8, 0x06, 0x93, 0xed, + 0x30, 0x88, 0xb9, 0x61, 0xb0, 0xc6, 0x1d, 0x2d, 0x06, 0xcc, 0x68, 0xad, 0x7a, 0x0a, 0x8e, 0xbb, + 0x6a, 0xa0, 0x17, 0x60, 0x44, 0x44, 0x70, 0xd5, 0x83, 0xa0, 0x25, 0xcc, 0x48, 0xea, 0x3a, 0xbe, + 0x91, 0x80, 0xb0, 0x8e, 0xa7, 0x55, 0x63, 0xd6, 0xc6, 0xa1, 0xcc, 0x6a, 0xdc, 0xe2, 0xa8, 0xe1, + 0xa5, 0xb2, 0x9b, 0x0c, 0x17, 0xca, 0x6e, 0x92, 0x18, 0xd6, 0xaa, 0x85, 0x2f, 0x62, 0x20, 0xd7, + 0x00, 0xf5, 0x87, 0x65, 0x18, 0xe4, 0x53, 0x71, 0x0c, 0x52, 0x5e, 0x5d, 0x98, 0x94, 0x0a, 0x65, + 0x92, 0xe0, 0xbd, 0x9a, 0xaf, 0x39, 0xb1, 0xc3, 0x59, 0x93, 0xda, 0x21, 0x89, 0x19, 0x0a, 0xcd, + 0x1b, 0x7b, 0x68, 0x36, 0x65, 0x29, 0x01, 0x4e, 0x43, 0xdb, 0x51, 0x9b, 0x00, 0x11, 0x7b, 0xfe, + 0x96, 0xd2, 0x10, 0x99, 0x79, 0x9f, 0x2f, 0xd4, 0x8f, 0x86, 0xaa, 0xc6, 0x7b, 0x93, 0x2c, 0x4b, + 0x05, 0xc0, 0x1a, 0xed, 0xd9, 0x17, 0xa1, 0xaa, 0x90, 0xf3, 0x54, 0xc8, 0x51, 0x9d, 0xb5, 0xfd, + 0x2c, 0x4c, 0xa4, 0xda, 0xea, 0x4b, 0x03, 0xfd, 0x3d, 0x0b, 0x26, 0x78, 0x97, 0x97, 0xfd, 0x6d, + 0xc1, 0x0a, 0x3e, 0x67, 0xc1, 0x74, 0x2b, 0x63, 0x27, 0x8a, 0x69, 0x3e, 0xcc, 0x1e, 0x56, 0xca, + 0x67, 0x16, 0x14, 0x67, 0xb6, 0x86, 0xce, 0xc2, 0x30, 0x7f, 0xcd, 0xdb, 0x69, 0x09, 0x0f, 0xed, + 0x51, 0x9e, 0x93, 0x9c, 0x97, 0x61, 0x05, 0xb5, 0x7f, 0x6c, 0xc1, 0x14, 0xff, 0x88, 0x2b, 0x64, + 0x47, 0xa9, 0x57, 0x1f, 0x90, 0xcf, 0x10, 0xd9, 0xd7, 0x4b, 0x3d, 0xb2, 0xaf, 0xeb, 0x5f, 0x59, + 0x3e, 0xf0, 0x2b, 0xbf, 0x61, 0x81, 0x58, 0xa1, 0xc7, 0xa0, 0x3f, 0xac, 0x9a, 0xfa, 0xc3, 0x47, + 0x8a, 0x2c, 0xfa, 0x1e, 0x8a, 0xc3, 0xaf, 0x96, 0x60, 0x92, 0x23, 0x24, 0x37, 0x32, 0x1f, 0x94, + 0xc9, 0xe9, 0xef, 0x55, 0x20, 0xf5, 0x26, 0x6c, 0xf6, 0x97, 0x1a, 0x73, 0x59, 0x39, 0x70, 0x2e, + 0xff, 0xa7, 0x05, 0x88, 0x8f, 0x49, 0xfa, 0x29, 0x74, 0x7e, 0xba, 0x69, 0xe6, 0x80, 0x84, 0x73, + 0x28, 0x08, 0xd6, 0xb0, 0x1e, 0xf0, 0x27, 0xa4, 0xee, 0xc3, 0xca, 0xf9, 0xf7, 0x61, 0x7d, 0x7c, + 0xf5, 0x77, 0xcb, 0x90, 0x76, 0xd5, 0x44, 0x6f, 0xc3, 0x68, 0xd3, 0x69, 0x3b, 0x77, 0xbc, 0x96, + 0x17, 0x7b, 0x24, 0x2a, 0x76, 0xe1, 0xbe, 0xa4, 0xd5, 0x10, 0xd7, 0x50, 0x5a, 0x09, 0x36, 0x28, + 0xa2, 0x79, 0x80, 0x76, 0xe8, 0x6d, 0x7b, 0x2d, 0xb2, 0xc1, 0x34, 0x1e, 0x16, 0xeb, 0xc1, 0xef, + 0x8e, 0x65, 0x29, 0xd6, 0x30, 0x32, 0x62, 0x03, 0xca, 0xc7, 0x11, 0x1b, 0x50, 0xe9, 0x33, 0x36, + 0x60, 0xa0, 0x50, 0x6c, 0x00, 0x86, 0x53, 0xf2, 0xf0, 0xa6, 0xff, 0x57, 0xbc, 0x16, 0x11, 0xb2, + 0x1b, 0x8f, 0x05, 0x99, 0xdd, 0xdb, 0x9d, 0x3b, 0x85, 0x33, 0x31, 0x70, 0x8f, 0x9a, 0x76, 0x07, + 0x4e, 0x34, 0x48, 0x28, 0x9f, 0xb1, 0x53, 0x7b, 0xe9, 0x4d, 0xa8, 0x86, 0xa9, 0x6d, 0xdc, 0x67, + 0xc0, 0xbf, 0x96, 0xe3, 0x4d, 0x6e, 0xdb, 0x84, 0xa4, 0xfd, 0xd7, 0x4b, 0x30, 0x24, 0x9c, 0x34, + 0x8f, 0x41, 0xf8, 0xb8, 0x62, 0x98, 0x98, 0x9e, 0xca, 0xe3, 0x7f, 0xac, 0x5b, 0x3d, 0x8d, 0x4b, + 0x8d, 0x94, 0x71, 0xe9, 0x99, 0x62, 0xe4, 0x0e, 0x36, 0x2b, 0xfd, 0x93, 0x32, 0x8c, 0x9b, 0x4e, + 0xab, 0xc7, 0x30, 0x2c, 0xaf, 0xc1, 0x50, 0x24, 0xfc, 0xa7, 0x4b, 0x45, 0x7c, 0xf6, 0xd2, 0x53, + 0x9c, 0xdc, 0xc4, 0x0b, 0x8f, 0x69, 0x49, 0x2e, 0xd3, 0x45, 0xbb, 0x7c, 0x2c, 0x2e, 0xda, 0x79, + 0xbe, 0xc4, 0x95, 0x07, 0xe1, 0x4b, 0x6c, 0x7f, 0x8f, 0xb1, 0x7c, 0xbd, 0xfc, 0x18, 0x8e, 0xf1, + 0x57, 0xcd, 0xc3, 0xe1, 0x5c, 0xa1, 0x75, 0x27, 0xba, 0xd7, 0xe3, 0x38, 0xff, 0x96, 0x05, 0x23, + 0x02, 0xf1, 0x18, 0x3e, 0xe0, 0xe7, 0xcd, 0x0f, 0x78, 0xa2, 0xd0, 0x07, 0xf4, 0xe8, 0xf9, 0x57, + 0x4a, 0xaa, 0xe7, 0xf5, 0x20, 0x8c, 0x0b, 0x65, 0x42, 0x1f, 0xa6, 0xaa, 0x5f, 0xd0, 0x0c, 0x5a, + 0x42, 0x80, 0x7b, 0x24, 0x09, 0xfd, 0xe3, 0xe5, 0xfb, 0xda, 0x6f, 0xac, 0xb0, 0x59, 0x64, 0x5a, + 0x10, 0xc6, 0xe2, 0x00, 0x4d, 0x22, 0xd3, 0x82, 0x30, 0xc6, 0x0c, 0x82, 0x5c, 0x80, 0xd8, 0x09, + 0x37, 0x48, 0x4c, 0xcb, 0x44, 0xd4, 0x6c, 0xef, 0xdd, 0xda, 0x89, 0xbd, 0xd6, 0xbc, 0xe7, 0xc7, + 0x51, 0x1c, 0xce, 0xaf, 0xfa, 0xf1, 0x8d, 0x90, 0x0b, 0xfd, 0x5a, 0x2c, 0x9f, 0xa2, 0x85, 0x35, + 0xba, 0x32, 0x48, 0x84, 0xb5, 0x31, 0x60, 0xde, 0x20, 0x5d, 0x17, 0xe5, 0x58, 0x61, 0xd8, 0x2f, + 0x32, 0xce, 0xce, 0x06, 0xa8, 0xbf, 0x30, 0xbb, 0x2f, 0x0c, 0xa9, 0xa1, 0x65, 0x66, 0xe1, 0xeb, + 0x7a, 0x30, 0x5f, 0x51, 0xf6, 0x49, 0xbb, 0xa0, 0xfb, 0x51, 0x27, 0xb1, 0x7f, 0x88, 0x74, 0x5d, + 0x3b, 0xbe, 0x58, 0x98, 0x23, 0xf7, 0x71, 0xd1, 0xc8, 0x52, 0x32, 0xb2, 0x3c, 0x74, 0xab, 0xf5, + 0x74, 0xfe, 0xfa, 0x25, 0x09, 0xc0, 0x09, 0x0e, 0x3a, 0x2f, 0x14, 0x4a, 0x6e, 0x71, 0xf9, 0x70, + 0x4a, 0xa1, 0x94, 0x43, 0xa2, 0x69, 0x94, 0x17, 0x60, 0x44, 0x3d, 0x09, 0x54, 0xe7, 0x8f, 0xb1, + 0x54, 0xb9, 0x7c, 0xb5, 0x9c, 0x14, 0x63, 0x1d, 0x07, 0xad, 0xc1, 0x44, 0xc4, 0xdf, 0x2b, 0x92, + 0xd1, 0x1a, 0xc2, 0x70, 0xf0, 0xb4, 0xbc, 0xa4, 0x6c, 0x98, 0xe0, 0x7d, 0x56, 0xc4, 0xb7, 0xb2, + 0x8c, 0xef, 0x48, 0x93, 0x40, 0xaf, 0xc0, 0x78, 0x4b, 0x7f, 0xc3, 0xb5, 0x2e, 0xec, 0x0a, 0xca, + 0xed, 0xcc, 0x78, 0xe1, 0xb5, 0x8e, 0x53, 0xd8, 0xe8, 0x35, 0x98, 0xd1, 0x4b, 0x44, 0x72, 0x21, + 0xc7, 0xdf, 0x20, 0x91, 0x78, 0xdb, 0xe4, 0x91, 0xbd, 0xdd, 0xb9, 0x99, 0xab, 0x3d, 0x70, 0x70, + 0xcf, 0xda, 0xe8, 0x25, 0x18, 0x95, 0x9f, 0xaf, 0xc5, 0x36, 0x25, 0x0e, 0x8f, 0x1a, 0x0c, 0x1b, + 0x98, 0xe8, 0x1e, 0x9c, 0x94, 0xff, 0xd7, 0x42, 0x67, 0x7d, 0xdd, 0x6b, 0x8a, 0x20, 0xb3, 0x11, + 0x46, 0x62, 0x41, 0xfa, 0x8b, 0x2f, 0x67, 0x21, 0xed, 0xef, 0xce, 0x9d, 0x11, 0xa3, 0x96, 0x09, + 0x67, 0x93, 0x98, 0x4d, 0x1f, 0x5d, 0x83, 0x13, 0x9b, 0xc4, 0x69, 0xc5, 0x9b, 0x4b, 0x9b, 0xa4, + 0x79, 0x57, 0x6e, 0x2c, 0x16, 0x31, 0xa5, 0xb9, 0x04, 0x5e, 0xee, 0x46, 0xc1, 0x59, 0xf5, 0xde, + 0xdf, 0x9d, 0xf2, 0x2f, 0xd0, 0xca, 0x9a, 0xfc, 0x80, 0xde, 0x81, 0x51, 0x7d, 0xac, 0xd3, 0x82, + 0x41, 0xfe, 0xfb, 0xbe, 0x42, 0x0e, 0x51, 0x33, 0xa0, 0xc3, 0xb0, 0x41, 0xdb, 0xfe, 0x77, 0x25, + 0x98, 0xcb, 0xc9, 0xdd, 0x95, 0xb2, 0x66, 0x59, 0x85, 0xac, 0x59, 0x0b, 0xf2, 0xcd, 0x9b, 0xeb, + 0xa9, 0x9c, 0xe9, 0xa9, 0x57, 0x6c, 0x92, 0xcc, 0xe9, 0x69, 0xfc, 0xc2, 0x9e, 0x66, 0xba, 0x41, + 0xac, 0x92, 0xeb, 0x70, 0xf7, 0xba, 0x6e, 0xe3, 0x1c, 0x38, 0x8c, 0xd0, 0xdb, 0xd3, 0xbc, 0x69, + 0x7f, 0xaf, 0x04, 0x27, 0xd5, 0x60, 0xfe, 0xf4, 0x0e, 0xe1, 0x5b, 0xdd, 0x43, 0xf8, 0x40, 0xcd, + 0xc4, 0xf6, 0x0d, 0x18, 0x6c, 0xec, 0x44, 0xcd, 0xb8, 0x55, 0xe0, 0xc4, 0x7f, 0xdc, 0xd8, 0x57, + 0xc9, 0x69, 0xc4, 0x5e, 0xb2, 0x13, 0xdb, 0xcc, 0xfe, 0xbc, 0x05, 0x13, 0x6b, 0x4b, 0xf5, 0x46, + 0xd0, 0xbc, 0x4b, 0xe2, 0x05, 0x6e, 0xd0, 0xc0, 0xe2, 0xc0, 0xb7, 0x0e, 0x79, 0x90, 0x67, 0x89, + 0x08, 0x67, 0xa0, 0xb2, 0x19, 0x44, 0x71, 0xfa, 0x52, 0xe0, 0x72, 0x10, 0xc5, 0x98, 0x41, 0xec, + 0x3f, 0xb3, 0x60, 0x80, 0x3d, 0xd4, 0x96, 0xf7, 0xc8, 0x5f, 0x91, 0xef, 0x42, 0x2f, 0xc0, 0x20, + 0x59, 0x5f, 0x27, 0xcd, 0x58, 0xcc, 0xaf, 0x0c, 0xb0, 0x19, 0x5c, 0x66, 0xa5, 0xf4, 0x44, 0x63, + 0x8d, 0xf1, 0xbf, 0x58, 0x20, 0xa3, 0xcf, 0x40, 0x35, 0xf6, 0xb6, 0xc8, 0x82, 0xeb, 0x0a, 0x2b, + 0x7c, 0x7f, 0x3e, 0x5f, 0xea, 0x84, 0x5d, 0x93, 0x44, 0x70, 0x42, 0xcf, 0xfe, 0x52, 0x09, 0x20, + 0x09, 0x9f, 0xcb, 0xfb, 0xcc, 0xc5, 0xae, 0xb7, 0x0c, 0x9f, 0xcc, 0x78, 0xcb, 0x10, 0x25, 0x04, + 0x33, 0x5e, 0x32, 0x54, 0x43, 0x55, 0x2e, 0x34, 0x54, 0x95, 0x7e, 0x86, 0x6a, 0x09, 0xa6, 0x92, + 0xf0, 0x3f, 0x33, 0x8e, 0x9a, 0xe5, 0x1b, 0x5e, 0x4b, 0x03, 0x71, 0x37, 0xbe, 0xfd, 0x25, 0x0b, + 0x84, 0x97, 0x70, 0x81, 0x05, 0xed, 0xca, 0x77, 0xc7, 0x8c, 0xd4, 0x82, 0x4f, 0x17, 0x71, 0xa0, + 0x16, 0x09, 0x05, 0x15, 0xdf, 0x37, 0xd2, 0x08, 0x1a, 0x54, 0xed, 0xdf, 0xb6, 0x60, 0x84, 0x83, + 0xaf, 0x31, 0x45, 0x34, 0xbf, 0x5f, 0x7d, 0x25, 0xb3, 0x66, 0x4f, 0x72, 0x51, 0xc2, 0x2a, 0xa9, + 0xb1, 0xfe, 0x24, 0x97, 0x04, 0xe0, 0x04, 0x07, 0x3d, 0x05, 0x43, 0x51, 0xe7, 0x0e, 0x43, 0x4f, + 0xb9, 0x0c, 0x37, 0x78, 0x31, 0x96, 0x70, 0xfb, 0x9f, 0x95, 0x60, 0x32, 0xed, 0x31, 0x8e, 0x30, + 0x0c, 0x72, 0x06, 0x92, 0xd6, 0x69, 0x0e, 0x32, 0x80, 0x6a, 0x1e, 0xe7, 0xc0, 0x1f, 0x96, 0x67, + 0x2c, 0x48, 0x50, 0x42, 0xeb, 0x30, 0xe2, 0x06, 0xf7, 0xfc, 0x7b, 0x4e, 0xe8, 0x2e, 0xd4, 0x57, + 0xc5, 0x4c, 0xe4, 0xf8, 0xf8, 0xd5, 0x92, 0x0a, 0xba, 0x3f, 0x3b, 0x33, 0xc8, 0x25, 0x20, 0xac, + 0x13, 0x46, 0x6f, 0xb2, 0x4c, 0x28, 0xeb, 0xde, 0xc6, 0x35, 0xa7, 0x5d, 0xcc, 0x9b, 0x65, 0x49, + 0xa2, 0x6b, 0x6d, 0x8c, 0x89, 0xc4, 0x29, 0x1c, 0x80, 0x13, 0x92, 0xf6, 0xaf, 0x9e, 0x04, 0x63, + 0x2d, 0x18, 0x19, 0xa7, 0xad, 0x07, 0x9e, 0x71, 0xfa, 0x0d, 0x18, 0x26, 0x5b, 0xed, 0x78, 0xa7, + 0xe6, 0x85, 0xc5, 0xde, 0x0f, 0x58, 0x16, 0xd8, 0xdd, 0xd4, 0x25, 0x04, 0x2b, 0x8a, 0x3d, 0xf2, + 0x87, 0x97, 0x3f, 0x10, 0xf9, 0xc3, 0x2b, 0x7f, 0x29, 0xf9, 0xc3, 0x5f, 0x83, 0xa1, 0x0d, 0x2f, + 0xc6, 0xa4, 0x1d, 0x88, 0xd3, 0x38, 0x67, 0xf1, 0x5c, 0xe2, 0xc8, 0xdd, 0x99, 0x65, 0x05, 0x00, + 0x4b, 0x72, 0x68, 0x4d, 0x6d, 0xaa, 0xc1, 0x22, 0x32, 0x68, 0xb7, 0x81, 0x3c, 0x73, 0x5b, 0x89, + 0x7c, 0xe1, 0x43, 0xef, 0x3f, 0x5f, 0xb8, 0xca, 0xf2, 0x3d, 0xfc, 0xa0, 0xb2, 0x7c, 0x1b, 0xd9, + 0xd2, 0xab, 0x47, 0x91, 0x2d, 0xfd, 0x4b, 0x16, 0x9c, 0x6c, 0x67, 0xbd, 0x35, 0x20, 0xf2, 0x75, + 0xff, 0xdc, 0x21, 0x5e, 0x5f, 0x30, 0x9a, 0x66, 0xf9, 0x3d, 0x32, 0xd1, 0x70, 0x76, 0xc3, 0x32, + 0xed, 0xfa, 0xc8, 0xfb, 0x4f, 0xbb, 0x7e, 0xd4, 0x89, 0xbd, 0x93, 0x24, 0xec, 0x63, 0x47, 0x92, + 0x84, 0x7d, 0xfc, 0x01, 0x26, 0x61, 0xd7, 0xd2, 0xa7, 0x4f, 0x3c, 0xd8, 0xf4, 0xe9, 0x9b, 0xe6, + 0xb9, 0xc4, 0xb3, 0x75, 0xbf, 0x50, 0xf8, 0x5c, 0x32, 0x5a, 0x38, 0xf8, 0x64, 0xe2, 0x89, 0xe4, + 0xa7, 0xde, 0x67, 0x22, 0x79, 0x23, 0x1d, 0x3b, 0x3a, 0x8a, 0x74, 0xec, 0x6f, 0xeb, 0x27, 0xe8, + 0x89, 0x22, 0x2d, 0xa8, 0x83, 0xb2, 0xbb, 0x85, 0xac, 0x33, 0xb4, 0x3b, 0xe1, 0xfb, 0xf4, 0x71, + 0x27, 0x7c, 0x3f, 0x79, 0x84, 0x09, 0xdf, 0x4f, 0x1d, 0x6b, 0xc2, 0xf7, 0x87, 0x3e, 0x20, 0x09, + 0xdf, 0x67, 0x8e, 0x2b, 0xe1, 0xfb, 0xc3, 0x0f, 0x36, 0xe1, 0xfb, 0xdb, 0x50, 0x6d, 0xcb, 0xb8, + 0xcb, 0x99, 0xd9, 0x22, 0x53, 0x97, 0x19, 0xa6, 0xc9, 0xa7, 0x4e, 0x81, 0x70, 0x42, 0x94, 0xb6, + 0x90, 0x24, 0x80, 0xff, 0x70, 0x91, 0x16, 0x32, 0xed, 0x1e, 0x07, 0xa4, 0x7d, 0xff, 0x42, 0x09, + 0x4e, 0x1f, 0xbc, 0x3b, 0x12, 0xa3, 0x49, 0x3d, 0xb1, 0x65, 0xa7, 0x8c, 0x26, 0x4c, 0xf2, 0xd4, + 0xb0, 0x0a, 0x87, 0xb3, 0x5f, 0x82, 0x29, 0xe5, 0xe7, 0xd5, 0xf2, 0x9a, 0x3b, 0xda, 0x33, 0x54, + 0x2a, 0x3e, 0xa1, 0x91, 0x46, 0xc0, 0xdd, 0x75, 0xd0, 0x02, 0x4c, 0x18, 0x85, 0xab, 0x35, 0xa1, + 0xbf, 0x28, 0x2b, 0x4d, 0xc3, 0x04, 0xe3, 0x34, 0xbe, 0xfd, 0x75, 0x0b, 0x1e, 0xea, 0x91, 0xe1, + 0xb5, 0x70, 0x8c, 0x76, 0x1b, 0x26, 0xda, 0x66, 0xd5, 0xc2, 0x29, 0x1f, 0x8c, 0x8c, 0xb2, 0xaa, + 0xd7, 0x29, 0x00, 0x4e, 0x93, 0x5f, 0x3c, 0xfb, 0xfd, 0x1f, 0x9d, 0xfe, 0xd0, 0x0f, 0x7e, 0x74, + 0xfa, 0x43, 0x3f, 0xfc, 0xd1, 0xe9, 0x0f, 0xfd, 0xd2, 0xde, 0x69, 0xeb, 0xfb, 0x7b, 0xa7, 0xad, + 0x1f, 0xec, 0x9d, 0xb6, 0x7e, 0xb8, 0x77, 0xda, 0xfa, 0xf3, 0xbd, 0xd3, 0xd6, 0x97, 0x7e, 0x7c, + 0xfa, 0x43, 0xaf, 0x97, 0xb6, 0x2f, 0xfc, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x06, 0xe5, 0xd7, + 0x49, 0x99, 0xd0, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/generated.proto b/vendor/k8s.io/client-go/pkg/api/v1/generated.proto index 0599bb1ecb..0874552d85 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/api/v1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,12 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.api.v1; +package k8s.io.client_go.pkg.api.v1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; @@ -37,13 +38,13 @@ option go_package = "v1"; // ownership management and SELinux relabeling. message AWSElasticBlockStoreVolumeSource { // Unique ID of the persistent disk resource in AWS (Amazon EBS volume). - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore optional string volumeID = 1; // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional optional string fsType = 2; @@ -57,7 +58,7 @@ message AWSElasticBlockStoreVolumeSource { // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true". // If omitted, the default is "false". - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // +optional optional bool readOnly = 4; } @@ -118,6 +119,9 @@ message AzureDiskVolumeSource { // the ReadOnly setting in VolumeMounts. // +optional optional bool readOnly = 5; + + // Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared + optional string kind = 6; } // AzureFile represents an Azure File Service mount on the host and bind mount to the pod. @@ -134,13 +138,13 @@ message AzureFileVolumeSource { optional bool readOnly = 3; } -// Binding ties one object to another. -// For example, a pod is bound to a node by a scheduler. +// Binding ties one object to another; for example, a pod is bound to a node by a scheduler. +// Deprecated in 1.7, please use the bindings subresource of pods instead. message Binding { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // The target object that you want to bind to the standard object. optional ObjectReference target = 2; @@ -161,7 +165,7 @@ message Capabilities { // Cephfs volumes do not support ownership management or SELinux relabeling. message CephFSVolumeSource { // Required: Monitors is a collection of Ceph monitors - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it repeated string monitors = 1; // Optional: Used as the mounted root, rather than the full Ceph tree, default is / @@ -169,23 +173,23 @@ message CephFSVolumeSource { optional string path = 2; // Optional: User is the rados user name, default is admin - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional optional string user = 3; // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional optional string secretFile = 4; // Optional: SecretRef is reference to the authentication secret for User, default is empty. - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional optional LocalObjectReference secretRef = 5; // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional optional bool readOnly = 6; } @@ -196,19 +200,19 @@ message CephFSVolumeSource { // Cinder volumes support ownership management and SELinux relabeling. message CinderVolumeSource { // volume id used to identify the volume in cinder - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md optional string volumeID = 1; // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional optional string fsType = 2; // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional optional bool readOnly = 3; } @@ -237,21 +241,23 @@ message ComponentCondition { // ComponentStatus (and ComponentStatusList) holds the cluster validation info. message ComponentStatus { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // List of component conditions observed // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated ComponentCondition conditions = 2; } // Status of all the conditions for the component as a list of ComponentStatus objects. message ComponentStatusList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of ComponentStatus objects. repeated ComponentStatus items = 2; @@ -260,16 +266,30 @@ message ComponentStatusList { // ConfigMap holds configuration data for pods to consume. message ConfigMap { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Data contains the configuration data. - // Each key must be a valid DNS_SUBDOMAIN with an optional leading dot. + // Each key must consist of alphanumeric characters, '-', '_' or '.'. // +optional map data = 2; } +// ConfigMapEnvSource selects a ConfigMap to populate the environment +// variables with. +// +// The contents of the target ConfigMap's Data field will represent the +// key-value pairs as environment variables. +message ConfigMapEnvSource { + // The ConfigMap to select from. + optional LocalObjectReference localObjectReference = 1; + + // Specify whether the ConfigMap must be defined + // +optional + optional bool optional = 2; +} + // Selects a key from a ConfigMap. message ConfigMapKeySelector { // The ConfigMap to select from. @@ -277,18 +297,47 @@ message ConfigMapKeySelector { // The key to select. optional string key = 2; + + // Specify whether the ConfigMap or it's key must be defined + // +optional + optional bool optional = 3; } // ConfigMapList is a resource containing a list of ConfigMap objects. message ConfigMapList { - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of ConfigMaps. repeated ConfigMap items = 2; } +// Adapts a ConfigMap into a projected volume. +// +// The contents of the target ConfigMap's Data field will be presented in a +// projected volume as files using the keys in the Data field as the file names, +// unless the items element is populated with specific mappings of keys to paths. +// Note that this is identical to a configmap volume source without the default +// mode. +message ConfigMapProjection { + optional LocalObjectReference localObjectReference = 1; + + // If unspecified, each key-value pair in the Data field of the referenced + // ConfigMap will be projected into the volume as a file whose name is the + // key and content is the value. If specified, the listed keys will be + // projected into the specified paths, and unlisted keys will not be + // present. If a key is specified which is not present in the ConfigMap, + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. + // +optional + repeated KeyToPath items = 2; + + // Specify whether the ConfigMap or it's keys must be defined + // +optional + optional bool optional = 4; +} + // Adapts a ConfigMap into a volume. // // The contents of the target ConfigMap's Data field will be presented in a @@ -303,8 +352,8 @@ message ConfigMapVolumeSource { // key and content is the value. If specified, the listed keys will be // projected into the specified paths, and unlisted keys will not be // present. If a key is specified which is not present in the ConfigMap, - // the volume setup will error. Paths must be relative and may not contain - // the '..' path or start with '..'. + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. // +optional repeated KeyToPath items = 2; @@ -315,6 +364,10 @@ message ConfigMapVolumeSource { // mode, like fsGroup, and the result can be other mode bits set. // +optional optional int32 defaultMode = 3; + + // Specify whether the ConfigMap or it's keys must be defined + // +optional + optional bool optional = 4; } // A single application container that you want to run within a pod. @@ -325,8 +378,7 @@ message Container { optional string name = 1; // Docker image name. - // More info: http://kubernetes.io/docs/user-guide/images - // +optional + // More info: https://kubernetes.io/docs/concepts/containers/images optional string image = 2; // Entrypoint array. Not executed within a shell. @@ -336,7 +388,7 @@ message Container { // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, // regardless of whether the variable exists or not. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers#containers-and-commands + // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell // +optional repeated string command = 3; @@ -347,7 +399,7 @@ message Container { // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, // regardless of whether the variable exists or not. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers#containers-and-commands + // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell // +optional repeated string args = 4; @@ -366,35 +418,50 @@ message Container { // accessible from the network. // Cannot be updated. // +optional + // +patchMergeKey=containerPort + // +patchStrategy=merge repeated ContainerPort ports = 6; + // List of sources to populate environment variables in the container. + // The keys defined within a source must be a C_IDENTIFIER. All invalid keys + // will be reported as an event when the container is starting. When a key exists in multiple + // sources, the value associated with the last source will take precedence. + // Values defined by an Env with a duplicate key will take precedence. + // Cannot be updated. + // +optional + repeated EnvFromSource envFrom = 19; + // List of environment variables to set in the container. // Cannot be updated. // +optional + // +patchMergeKey=name + // +patchStrategy=merge repeated EnvVar env = 7; // Compute Resources required by this container. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#resources + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources // +optional optional ResourceRequirements resources = 8; // Pod volumes to mount into the container's filesystem. // Cannot be updated. // +optional + // +patchMergeKey=mountPath + // +patchStrategy=merge repeated VolumeMount volumeMounts = 9; // Periodic probe of container liveness. // Container will be restarted if the probe fails. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional optional Probe livenessProbe = 10; // Periodic probe of container service readiness. // Container will be removed from service endpoints if the probe fails. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional optional Probe readinessProbe = 11; @@ -406,21 +473,34 @@ message Container { // Optional: Path at which the file to which the container's termination message // will be written is mounted into the container's filesystem. // Message written is intended to be brief final status, such as an assertion failure message. + // Will be truncated by the node if greater than 4096 bytes. The total message length across + // all containers will be limited to 12kb. // Defaults to /dev/termination-log. // Cannot be updated. // +optional optional string terminationMessagePath = 13; + // Indicate how the termination message should be populated. File will use the contents of + // terminationMessagePath to populate the container status message on both success and failure. + // FallbackToLogsOnError will use the last chunk of container log output if the termination + // message file is empty and the container exited with an error. + // The log output is limited to 2048 bytes or 80 lines, whichever is smaller. + // Defaults to File. + // Cannot be updated. + // +optional + optional string terminationMessagePolicy = 20; + // Image pull policy. // One of Always, Never, IfNotPresent. // Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/images#updating-images + // More info: https://kubernetes.io/docs/concepts/containers/images#updating-images // +optional optional string imagePullPolicy = 14; // Security options the pod should run with. - // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md + // More info: https://kubernetes.io/docs/concepts/policy/security-context/ + // More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md // +optional optional SecurityContext securityContext = 15; @@ -507,7 +587,7 @@ message ContainerState { message ContainerStateRunning { // Time at which the container was last (re-)started // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time startedAt = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startedAt = 1; } // ContainerStateTerminated is a terminated state of a container. @@ -529,11 +609,11 @@ message ContainerStateTerminated { // Time at which previous execution of the container started // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time startedAt = 5; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startedAt = 5; // Time at which the container last terminated // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time finishedAt = 6; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time finishedAt = 6; // Container's ID in the format 'docker://' // +optional @@ -575,7 +655,7 @@ message ContainerStatus { optional int32 restartCount = 5; // The image the container is running. - // More info: http://kubernetes.io/docs/user-guide/images + // More info: https://kubernetes.io/docs/concepts/containers/images // TODO(dchen1107): Which image the container is running with? optional string image = 6; @@ -583,7 +663,6 @@ message ContainerStatus { optional string imageID = 7; // Container's ID in the format 'docker://'. - // More info: http://kubernetes.io/docs/user-guide/container-environment#container-information // +optional optional string containerID = 8; } @@ -595,6 +674,8 @@ message DaemonEndpoint { } // DeleteOptions may be provided when deleting an API object +// DEPRECATED: This type has been moved to meta/v1 and will be removed soon. +// +k8s:openapi-gen=false message DeleteOptions { // The duration in seconds before the object should be deleted. Value must be non-negative integer. // The value zero indicates delete immediately. If this value is nil, the default grace period for the @@ -608,10 +689,28 @@ message DeleteOptions { // +optional optional Preconditions preconditions = 2; + // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. // Should the dependent objects be orphaned. If true/false, the "orphan" // finalizer will be added to/removed from the object's finalizers list. + // Either this field or PropagationPolicy may be set, but not both. // +optional optional bool orphanDependents = 3; + + // Whether and how garbage collection will be performed. + // Either this field or OrphanDependents may be set, but not both. + // The default policy is decided by the existing finalizer set in the + // metadata.finalizers and the resource-specific default policy. + // +optional + optional string propagationPolicy = 4; +} + +// Represents downward API info for projecting into a projected volume. +// Note that this is identical to a downwardAPI volume source without the default +// mode. +message DownwardAPIProjection { + // Items is a list of DownwardAPIVolume file + // +optional + repeated DownwardAPIVolumeFile items = 1; } // DownwardAPIVolumeFile represents information to create the file containing the pod field @@ -658,9 +757,18 @@ message EmptyDirVolumeSource { // What type of storage medium should back this directory. // The default is "" which means to use the node's default medium. // Must be an empty string (default) or Memory. - // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional optional string medium = 1; + + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + optional k8s.io.apimachinery.pkg.api.resource.Quantity sizeLimit = 2; } // EndpointAddress is a tuple that describes single IP address. @@ -745,9 +853,9 @@ message EndpointSubset { // ] message Endpoints { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // The set of all endpoints is the union of all subsets. Addresses are placed into // subsets according to the IPs they share. A single address with multiple ports, @@ -762,14 +870,29 @@ message Endpoints { // EndpointsList is a list of endpoints. message EndpointsList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of endpoints. repeated Endpoints items = 2; } +// EnvFromSource represents the source of a set of ConfigMaps +message EnvFromSource { + // An optional identifer to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. + // +optional + optional string prefix = 1; + + // The ConfigMap to select from + // +optional + optional ConfigMapEnvSource configMapRef = 2; + + // The Secret to select from + // +optional + optional SecretEnvSource secretRef = 3; +} + // EnvVar represents an environment variable present in a Container. message EnvVar { // Name of the environment variable. Must be a C_IDENTIFIER. @@ -794,7 +917,7 @@ message EnvVar { // EnvVarSource represents a source for the value of an EnvVar. message EnvVarSource { // Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, - // spec.nodeName, spec.serviceAccountName, status.podIP. + // spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP. // +optional optional ObjectFieldSelector fieldRef = 1; @@ -816,8 +939,8 @@ message EnvVarSource { // TODO: Decide whether to store these separately or with the object they apply to. message Event { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - optional ObjectMeta metadata = 1; + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // The object that this event is about. optional ObjectReference involvedObject = 2; @@ -839,11 +962,11 @@ message Event { // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.) // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time firstTimestamp = 6; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time firstTimestamp = 6; // The time at which the most recent occurrence of this event was recorded. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTimestamp = 7; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTimestamp = 7; // The number of times this event has occurred. // +optional @@ -857,9 +980,9 @@ message Event { // EventList is a list of events. message EventList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of events repeated Event items = 2; @@ -887,15 +1010,6 @@ message ExecAction { repeated string command = 1; } -// ExportOptions is the query options to the standard REST get call. -message ExportOptions { - // Should this value be exported. Export strips fields that a user can not specify. - optional bool export = 1; - - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' - optional bool exact = 2; -} - // Represents a Fibre Channel volume. // Fibre Channel volumes can only be mounted as read/write once. // Fibre Channel volumes support ownership management and SELinux relabeling. @@ -971,13 +1085,13 @@ message FlockerVolumeSource { // PDs support ownership management and SELinux relabeling. message GCEPersistentDiskVolumeSource { // Unique name of the PD resource in GCE. Used to identify the disk in GCE. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk optional string pdName = 1; // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional optional string fsType = 2; @@ -986,13 +1100,13 @@ message GCEPersistentDiskVolumeSource { // If omitted, the default is to mount by volume name. // Examples: For volume /dev/sda1, you specify the partition as "1". // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional optional int32 partition = 3; // ReadOnly here will force the ReadOnly setting in VolumeMounts. // Defaults to false. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional optional bool readOnly = 4; } @@ -1020,16 +1134,16 @@ message GitRepoVolumeSource { // Glusterfs volumes do not support ownership management or SELinux relabeling. message GlusterfsVolumeSource { // EndpointsName is the endpoint name that details Glusterfs topology. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod optional string endpoints = 1; // Path is the Glusterfs volume path. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod optional string path = 2; // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. // Defaults to false. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod // +optional optional bool readOnly = 3; } @@ -1043,7 +1157,7 @@ message HTTPGetAction { // Name or number of the port to access on the container. // Number must be in the range 1 to 65535. // Name must be an IANA_SVC_NAME. - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString port = 2; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 2; // Host name to connect to, defaults to the pod IP. You probably want to set // "Host" in httpHeaders instead. @@ -1088,11 +1202,21 @@ message Handler { optional TCPSocketAction tcpSocket = 3; } +// HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the +// pod's hosts file. +message HostAlias { + // IP address of the host file entry. + optional string ip = 1; + + // Hostnames for the above IP address. + repeated string hostnames = 2; +} + // Represents a host path mapped into a pod. // Host path volumes do not support ownership management or SELinux relabeling. message HostPathVolumeSource { // Path of the directory on the host. - // More info: http://kubernetes.io/docs/user-guide/volumes#hostpath + // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath optional string path = 1; } @@ -1117,7 +1241,7 @@ message ISCSIVolumeSource { // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#iscsi + // More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional optional string fsType = 5; @@ -1126,6 +1250,23 @@ message ISCSIVolumeSource { // Defaults to false. // +optional optional bool readOnly = 6; + + // iSCSI target portal List. The portal is either an IP or ip_addr:port if the port + // is other than default (typically TCP ports 860 and 3260). + // +optional + repeated string portals = 7; + + // whether support iSCSI Discovery CHAP authentication + // +optional + optional bool chapAuthDiscovery = 8; + + // whether support iSCSI Session CHAP authentication + // +optional + optional bool chapAuthSession = 11; + + // CHAP secret for iSCSI target and initiator authentication + // +optional + optional LocalObjectReference secretRef = 10; } // Maps a string key to a path within a volume. @@ -1154,7 +1295,7 @@ message Lifecycle { // PostStart is called immediately after a container is created. If the handler fails, // the container is terminated and restarted according to its restart policy. // Other management of the container blocks until the hook completes. - // More info: http://kubernetes.io/docs/user-guide/container-environment#hook-details + // More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks // +optional optional Handler postStart = 1; @@ -1163,7 +1304,7 @@ message Lifecycle { // The reason for termination is passed to the handler. // Regardless of the outcome of the handler, the container is eventually terminated. // Other management of the container blocks until the hook completes. - // More info: http://kubernetes.io/docs/user-guide/container-environment#hook-details + // More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks // +optional optional Handler preStop = 2; } @@ -1171,12 +1312,12 @@ message Lifecycle { // LimitRange sets resource usage limits for each kind of resource in a Namespace. message LimitRange { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the limits enforced. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional LimitRangeSpec spec = 2; } @@ -1189,34 +1330,34 @@ message LimitRangeItem { // Max usage constraints on this kind by resource name. // +optional - map max = 2; + map max = 2; // Min usage constraints on this kind by resource name. // +optional - map min = 3; + map min = 3; // Default resource requirement limit value by resource name if resource limit is omitted. // +optional - map default = 4; + map default = 4; // DefaultRequest is the default resource requirement request value by resource name if resource request is omitted. // +optional - map defaultRequest = 5; + map defaultRequest = 5; // MaxLimitRequestRatio if specified, the named resource must have a request and limit that are both non-zero where limit divided by request is less than or equal to the enumerated value; this represents the max burst for the named resource. // +optional - map maxLimitRequestRatio = 6; + map maxLimitRequestRatio = 6; } // LimitRangeList is a list of LimitRange items. message LimitRangeList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of LimitRange objects. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_limit_range.md + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_limit_range.md repeated LimitRange items = 2; } @@ -1229,15 +1370,17 @@ message LimitRangeSpec { // List holds a list of objects, which may not be known by the server. message List { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of objects - repeated k8s.io.kubernetes.pkg.runtime.RawExtension items = 2; + repeated k8s.io.apimachinery.pkg.runtime.RawExtension items = 2; } // ListOptions is the query options to a standard REST list call. +// DEPRECATED: This type has been moved to meta/v1 and will be removed soon. +// +k8s:openapi-gen=false message ListOptions { // A selector to restrict the list of returned objects by their labels. // Defaults to everything. @@ -1249,6 +1392,10 @@ message ListOptions { // +optional optional string fieldSelector = 2; + // If true, partially initialized resources are included in the response. + // +optional + optional bool includeUninitialized = 6; + // Watch for changes to the described resources and return them as a stream of // add, update, and remove notifications. Specify resourceVersion. // +optional @@ -1256,6 +1403,10 @@ message ListOptions { // When specified with a watch call, shows changes that occur after that particular version of a resource. // Defaults to changes from the beginning of history. + // When specified for list: + // - if unset, then the result is returned from remote storage based on quorum-read flag; + // - if it's 0, then we simply return what we currently have in cache, no guarantee; + // - if set to non zero, then the result is at least as fresh as given rv. // +optional optional string resourceVersion = 4; @@ -1290,27 +1441,35 @@ message LoadBalancerStatus { // referenced object inside the same namespace. message LocalObjectReference { // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names // TODO: Add other useful fields. apiVersion, kind, uid? // +optional optional string name = 1; } +// Local represents directly-attached storage with node affinity +message LocalVolumeSource { + // The full path to the volume on the node + // For alpha, this path must be a directory + // Once block as a source is supported, then this path can point to a block device + optional string path = 1; +} + // Represents an NFS mount that lasts the lifetime of a pod. // NFS volumes do not support ownership management or SELinux relabeling. message NFSVolumeSource { // Server is the hostname or IP address of the NFS server. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs optional string server = 1; // Path that is exported by the NFS server. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs optional string path = 2; // ReadOnly here will force // the NFS export to be mounted with read-only permissions. // Defaults to false. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs // +optional optional bool readOnly = 3; } @@ -1319,17 +1478,17 @@ message NFSVolumeSource { // Use of multiple namespaces is optional. message Namespace { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the behavior of the Namespace. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional NamespaceSpec spec = 2; // Status describes the current status of a Namespace. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional NamespaceStatus status = 3; } @@ -1337,19 +1496,19 @@ message Namespace { // NamespaceList is a list of Namespaces. message NamespaceList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of Namespace objects in the list. - // More info: http://kubernetes.io/docs/user-guide/namespaces + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ repeated Namespace items = 2; } // NamespaceSpec describes the attributes on a Namespace. message NamespaceSpec { // Finalizers is an opaque list of values that must be empty to permanently remove object from storage. - // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#finalizers + // More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#finalizers // +optional repeated string finalizers = 1; } @@ -1357,7 +1516,7 @@ message NamespaceSpec { // NamespaceStatus is information about the current status of a Namespace. message NamespaceStatus { // Phase is the current lifecycle phase of the namespace. - // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#phases + // More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#phases // +optional optional string phase = 1; } @@ -1366,19 +1525,19 @@ message NamespaceStatus { // Each node will have a unique identifier in the cache (i.e. in etcd). message Node { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the behavior of a node. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional NodeSpec spec = 2; // Most recently observed status of the node. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional NodeStatus status = 3; } @@ -1425,11 +1584,11 @@ message NodeCondition { // Last time we got an update on a given condition. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastHeartbeatTime = 3; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastHeartbeatTime = 3; // Last time the condition transit from one status to another. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 4; // (brief) reason for the condition's last transition. // +optional @@ -1450,9 +1609,9 @@ message NodeDaemonEndpoints { // NodeList is the whole list of all Nodes which have been registered with master. message NodeList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of nodes repeated Node items = 2; @@ -1465,6 +1624,13 @@ message NodeProxyOptions { optional string path = 1; } +// NodeResources is an object for conveying resource information about a node. +// see http://releases.k8s.io/HEAD/docs/design/resources.md for more details. +message NodeResources { + // Capacity represents the available resources of a node + map capacity = 1; +} + // A node selector represents the union of the results of one or more label queries // over a set of nodes; that is, it represents the OR of the selectors represented // by the node selector terms. @@ -1477,6 +1643,8 @@ message NodeSelector { // that relates the key and values. message NodeSelectorRequirement { // The label key that the selector applies to. + // +patchMergeKey=key + // +patchStrategy=merge optional string key = 1; // Represents a key's relationship to a set of values. @@ -1514,38 +1682,46 @@ message NodeSpec { optional string providerID = 3; // Unschedulable controls node schedulability of new pods. By default, node is schedulable. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#manual-node-administration"` + // More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration // +optional optional bool unschedulable = 4; + + // If specified, the node's taints. + // +optional + repeated Taint taints = 5; } // NodeStatus is information about the current status of a node. message NodeStatus { // Capacity represents the total resources of a node. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#capacity for more details. + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity // +optional - map capacity = 1; + map capacity = 1; // Allocatable represents the resources of a node that are available for scheduling. // Defaults to Capacity. // +optional - map allocatable = 2; + map allocatable = 2; // NodePhase is the recently observed lifecycle phase of the node. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-phase + // More info: https://kubernetes.io/docs/concepts/nodes/node/#phase // The field is never populated, and now is deprecated. // +optional optional string phase = 3; // Conditions is an array of current observed node conditions. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-condition + // More info: https://kubernetes.io/docs/concepts/nodes/node/#condition // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated NodeCondition conditions = 4; // List of addresses reachable to the node. // Queried from cloud provider, if available. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-addresses + // More info: https://kubernetes.io/docs/concepts/nodes/node/#addresses // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated NodeAddress addresses = 5; // Endpoints of daemons running on the Node. @@ -1553,7 +1729,7 @@ message NodeStatus { optional NodeDaemonEndpoints daemonEndpoints = 6; // Set of ids/uuids to uniquely identify the node. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-info + // More info: https://kubernetes.io/docs/concepts/nodes/node/#info // +optional optional NodeSystemInfo nodeInfo = 7; @@ -1573,12 +1749,12 @@ message NodeStatus { // NodeSystemInfo is a set of ids/uuids to uniquely identify the node. message NodeSystemInfo { // MachineID reported by the node. For unique machine identification - // in the cluster this field is prefered. Learn more from man(5) + // in the cluster this field is preferred. Learn more from man(5) // machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html optional string machineID = 1; // SystemUUID reported by the node. For unique machine identification - // MachineID is prefered. This field is specific to Red Hat hosts + // MachineID is preferred. This field is specific to Red Hat hosts // https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html optional string systemUUID = 2; @@ -1619,13 +1795,15 @@ message ObjectFieldSelector { // ObjectMeta is metadata that all persisted resources must have, which includes all objects // users must create. +// DEPRECATED: Use k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta instead - this type will be removed soon. +// +k8s:openapi-gen=false message ObjectMeta { // Name must be unique within a namespace. Is required when creating resources, although // some resources may allow a client to request the generation of an appropriate name // automatically. Name is primarily intended for creation idempotence and configuration // definition. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names // +optional optional string name = 1; @@ -1643,7 +1821,7 @@ message ObjectMeta { // should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency // +optional optional string generateName = 2; @@ -1654,7 +1832,7 @@ message ObjectMeta { // // Must be a DNS_LABEL. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/namespaces + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ // +optional optional string namespace = 3; @@ -1670,7 +1848,7 @@ message ObjectMeta { // // Populated by the system. // Read-only. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids // +optional optional string uid = 5; @@ -1683,7 +1861,7 @@ message ObjectMeta { // Populated by the system. // Read-only. // Value must be treated as opaque by clients and . - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency // +optional optional string resourceVersion = 6; @@ -1699,9 +1877,9 @@ message ObjectMeta { // Populated by the system. // Read-only. // Null for lists. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time creationTimestamp = 8; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time creationTimestamp = 8; // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This // field is set by the server when a graceful deletion is requested by the user, and is not @@ -1719,9 +1897,9 @@ message ObjectMeta { // // Populated by the system when a graceful deletion is requested. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time deletionTimestamp = 9; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time deletionTimestamp = 9; // Number of seconds allowed for this object to gracefully terminate before // it will be removed from the system. Only set when deletionTimestamp is also set. @@ -1733,14 +1911,14 @@ message ObjectMeta { // Map of string keys and values that can be used to organize and categorize // (scope and select) objects. May match selectors of replication controllers // and services. - // More info: http://kubernetes.io/docs/user-guide/labels + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ // +optional map labels = 11; // Annotations is an unstructured key value map stored with a resource that may be // set by external tools to store and retrieve arbitrary metadata. They are not // queryable and should be preserved when modifying objects. - // More info: http://kubernetes.io/docs/user-guide/annotations + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ // +optional map annotations = 12; @@ -1749,13 +1927,27 @@ message ObjectMeta { // then an entry in this list will point to this controller, with the controller field set to true. // There cannot be more than one managing controller. // +optional - repeated OwnerReference ownerReferences = 13; + // +patchMergeKey=uid + // +patchStrategy=merge + repeated k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference ownerReferences = 13; + + // An initializer is a controller which enforces some system invariant at object creation time. + // This field is a list of initializers that have not yet acted on this object. If nil or empty, + // this object has been completely initialized. Otherwise, the object is considered uninitialized + // and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to + // observe uninitialized objects. + // + // When an object is created, the system will populate this list with the current set of initializers. + // Only privileged users may set or modify this list. Once it is empty, it may not be modified further + // by any user. + optional k8s.io.apimachinery.pkg.apis.meta.v1.Initializers initializers = 16; // Must be empty before the object is deleted from the registry. Each entry // is an identifier for the responsible component that will remove the entry // from the list. If the deletionTimestamp of the object is non-nil, entries // in this list can only be removed. // +optional + // +patchStrategy=merge repeated string finalizers = 14; // The name of the cluster which the object belongs to. @@ -1768,22 +1960,22 @@ message ObjectMeta { // ObjectReference contains enough information to let you inspect or modify the referred object. message ObjectReference { // Kind of the referent. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional optional string kind = 1; // Namespace of the referent. - // More info: http://kubernetes.io/docs/user-guide/namespaces + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ // +optional optional string namespace = 2; // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names // +optional optional string name = 3; // UID of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids // +optional optional string uid = 4; @@ -1792,7 +1984,7 @@ message ObjectReference { optional string apiVersion = 5; // Specific resourceVersion to which this reference is made, if any. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency // +optional optional string resourceVersion = 6; @@ -1808,49 +2000,25 @@ message ObjectReference { optional string fieldPath = 7; } -// OwnerReference contains enough information to let you identify an owning -// object. Currently, an owning object must be in the same namespace, so there -// is no namespace field. -message OwnerReference { - // API version of the referent. - optional string apiVersion = 5; - - // Kind of the referent. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - optional string kind = 1; - - // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names - optional string name = 3; - - // UID of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids - optional string uid = 4; - - // If true, this reference points to the managing controller. - // +optional - optional bool controller = 6; -} - // PersistentVolume (PV) is a storage resource provisioned by an administrator. // It is analogous to a node. -// More info: http://kubernetes.io/docs/user-guide/persistent-volumes +// More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes message PersistentVolume { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines a specification of a persistent volume owned by the cluster. // Provisioned by an administrator. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistent-volumes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes // +optional optional PersistentVolumeSpec spec = 2; // Status represents the current information/status for the persistent volume. // Populated by the system. // Read-only. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistent-volumes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes // +optional optional PersistentVolumeStatus status = 3; } @@ -1858,18 +2026,18 @@ message PersistentVolume { // PersistentVolumeClaim is a user's request for and claim to a persistent volume message PersistentVolumeClaim { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the desired characteristics of a volume requested by a pod author. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims // +optional optional PersistentVolumeClaimSpec spec = 2; // Status represents the current information/status of a persistent volume claim. // Read-only. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims // +optional optional PersistentVolumeClaimStatus status = 3; } @@ -1877,12 +2045,12 @@ message PersistentVolumeClaim { // PersistentVolumeClaimList is a list of PersistentVolumeClaim items. message PersistentVolumeClaimList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // A list of persistent volume claims. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims repeated PersistentVolumeClaim items = 2; } @@ -1890,22 +2058,27 @@ message PersistentVolumeClaimList { // and allows a Source for provider-specific attributes message PersistentVolumeClaimSpec { // AccessModes contains the desired access modes the volume should have. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes-1 + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 // +optional repeated string accessModes = 1; // A label query over volumes to consider for binding. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 4; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 4; // Resources represents the minimum resources the volume should have. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#resources + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources // +optional optional ResourceRequirements resources = 2; // VolumeName is the binding reference to the PersistentVolume backing this claim. // +optional optional string volumeName = 3; + + // Name of the StorageClass required by the claim. + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1 + // +optional + optional string storageClassName = 5; } // PersistentVolumeClaimStatus is the current status of a persistent volume claim. @@ -1915,13 +2088,13 @@ message PersistentVolumeClaimStatus { optional string phase = 1; // AccessModes contains the actual access modes the volume backing the PVC has. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes-1 + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 // +optional repeated string accessModes = 2; // Represents the actual resources of the underlying volume. // +optional - map capacity = 3; + map capacity = 3; } // PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. @@ -1930,7 +2103,7 @@ message PersistentVolumeClaimStatus { // type of volume that is owned by someone else (the system). message PersistentVolumeClaimVolumeSource { // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims optional string claimName = 1; // Will force the ReadOnly setting in VolumeMounts. @@ -1942,12 +2115,12 @@ message PersistentVolumeClaimVolumeSource { // PersistentVolumeList is a list of PersistentVolume items. message PersistentVolumeList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of persistent volumes. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes repeated PersistentVolume items = 2; } @@ -1956,13 +2129,13 @@ message PersistentVolumeList { message PersistentVolumeSource { // GCEPersistentDisk represents a GCE Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. Provisioned by an admin. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional optional GCEPersistentDiskVolumeSource gcePersistentDisk = 1; // AWSElasticBlockStore represents an AWS Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // +optional optional AWSElasticBlockStoreVolumeSource awsElasticBlockStore = 2; @@ -1970,23 +2143,23 @@ message PersistentVolumeSource { // Provisioned by a developer or tester. // This is useful for single-node development and testing only! // On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. - // More info: http://kubernetes.io/docs/user-guide/volumes#hostpath + // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath // +optional optional HostPathVolumeSource hostPath = 3; // Glusterfs represents a Glusterfs volume that is attached to a host and // exposed to the pod. Provisioned by an admin. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md // +optional optional GlusterfsVolumeSource glusterfs = 4; // NFS represents an NFS mount on the host. Provisioned by an admin. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs // +optional optional NFSVolumeSource nfs = 5; // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md // +optional optional RBDVolumeSource rbd = 6; @@ -1996,7 +2169,7 @@ message PersistentVolumeSource { optional ISCSIVolumeSource iscsi = 7; // Cinder represents a cinder volume attached and mounted on kubelets host machine - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional optional CinderVolumeSource cinder = 8; @@ -2036,42 +2209,64 @@ message PersistentVolumeSource { // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine optional PhotonPersistentDiskVolumeSource photonPersistentDisk = 17; + + // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine + // +optional + optional PortworxVolumeSource portworxVolume = 18; + + // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. + // +optional + optional ScaleIOVolumeSource scaleIO = 19; + + // Local represents directly-attached storage with node affinity + // +optional + optional LocalVolumeSource local = 20; + + // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md + // +optional + optional StorageOSPersistentVolumeSource storageos = 21; } // PersistentVolumeSpec is the specification of a persistent volume. message PersistentVolumeSpec { // A description of the persistent volume's resources and capacity. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#capacity + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity // +optional - map capacity = 1; + map capacity = 1; // The actual volume backing the persistent volume. optional PersistentVolumeSource persistentVolumeSource = 2; // AccessModes contains all ways the volume can be mounted. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes // +optional repeated string accessModes = 3; // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. // Expected to be non-nil when bound. // claim.VolumeName is the authoritative bind between PV and PVC. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#binding + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding // +optional optional ObjectReference claimRef = 4; // What happens to a persistent volume when released from its claim. // Valid options are Retain (default) and Recycle. // Recycling must be supported by the volume plugin underlying this persistent volume. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#recycling-policy + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming // +optional optional string persistentVolumeReclaimPolicy = 5; + + // Name of StorageClass to which this persistent volume belongs. Empty value + // means that this volume does not belong to any StorageClass. + // +optional + optional string storageClassName = 6; } // PersistentVolumeStatus is the current status of a persistent volume. message PersistentVolumeStatus { // Phase indicates if a volume is available, bound to a claim, or released by a claim. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#phase + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase // +optional optional string phase = 1; @@ -2100,12 +2295,12 @@ message PhotonPersistentDiskVolumeSource { // by clients and scheduled onto hosts. message Pod { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Specification of the desired behavior of the pod. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional PodSpec spec = 2; @@ -2113,7 +2308,7 @@ message Pod { // This data may not be up to date. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional PodStatus status = 3; } @@ -2162,12 +2357,10 @@ message PodAffinity { message PodAffinityTerm { // A label query over a set of resources, in this case pods. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector labelSelector = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector labelSelector = 1; // namespaces specifies which namespaces the labelSelector applies to (matches against); - // nil list means "this pod's namespace," empty list means "all namespaces" - // The json tag here is not "omitempty" since we need to distinguish nil and empty. - // See https://golang.org/pkg/encoding/json/#Marshal for more details. + // null or empty list means "this pod's namespace" repeated string namespaces = 2; // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching @@ -2253,21 +2446,21 @@ message PodAttachOptions { message PodCondition { // Type is the type of the condition. // Currently only Ready. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions optional string type = 1; // Status is the status of the condition. // Can be True, False, Unknown. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions optional string status = 2; // Last time we probed the condition. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastProbeTime = 3; // Last time the condition transitioned from one status to another. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 4; // Unique, one-word, CamelCase reason for the condition's last transition. // +optional @@ -2315,12 +2508,12 @@ message PodExecOptions { // PodList is a list of Pods. message PodList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of pods. - // More info: http://kubernetes.io/docs/user-guide/pods + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md repeated Pod items = 2; } @@ -2350,7 +2543,7 @@ message PodLogOptions { // If this value is in the future, no logs will be returned. // Only one of sinceSeconds or sinceTime may be specified. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time sinceTime = 5; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time sinceTime = 5; // If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line // of log output. Defaults to false. @@ -2369,6 +2562,19 @@ message PodLogOptions { optional int64 limitBytes = 8; } +// PodPortForwardOptions is the query options to a Pod's port forward call +// when using WebSockets. +// The `port` query parameter must specify the port or +// ports (comma separated) to forward over. +// Port forwarding over SPDY does not use these options. It requires the port +// to be passed in the `port` header as part of request. +message PodPortForwardOptions { + // List of ports to forward + // Required when using WebSockets + // +optional + repeated int32 ports = 1; +} + // PodProxyOptions is the query options to a Pod's proxy call. message PodProxyOptions { // Path is the URL path to use for the current proxy request to pod. @@ -2429,27 +2635,47 @@ message PodSecurityContext { message PodSignature { // Reference to controller whose pods should avoid this node. // +optional - optional OwnerReference podController = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.OwnerReference podController = 1; } // PodSpec is a description of a pod. message PodSpec { // List of volumes that can be mounted by containers belonging to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes + // More info: https://kubernetes.io/docs/concepts/storage/volumes // +optional + // +patchMergeKey=name + // +patchStrategy=merge repeated Volume volumes = 1; + // List of initialization containers belonging to the pod. + // Init containers are executed in order prior to containers being started. If any + // init container fails, the pod is considered to have failed and is handled according + // to its restartPolicy. The name for an init container or normal container must be + // unique among all containers. + // Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. + // The resourceRequirements of an init container are taken into account during scheduling + // by finding the highest request/limit for each resource type, and then using the max of + // of that value or the sum of the normal containers. Limits are applied to init containers + // in a similar fashion. + // Init containers cannot currently be added or removed. + // Cannot be updated. + // More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + // +patchMergeKey=name + // +patchStrategy=merge + repeated Container initContainers = 20; + // List of containers belonging to the pod. // Containers cannot currently be added or removed. // There must be at least one container in a Pod. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers + // +patchMergeKey=name + // +patchStrategy=merge repeated Container containers = 2; // Restart policy for all containers within the pod. // One of Always, OnFailure, Never. // Default to Always. - // More info: http://kubernetes.io/docs/user-guide/pod-states#restartpolicy + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy // +optional optional string restartPolicy = 3; @@ -2470,19 +2696,20 @@ message PodSpec { optional int64 activeDeadlineSeconds = 5; // Set DNS policy for containers within the pod. - // One of 'ClusterFirst' or 'Default'. + // One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. // Defaults to "ClusterFirst". + // To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. // +optional optional string dnsPolicy = 6; // NodeSelector is a selector which must be true for the pod to fit on a node. // Selector which must match a node's labels for the pod to be scheduled on that node. - // More info: http://kubernetes.io/docs/user-guide/node-selection/README + // More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ // +optional map nodeSelector = 7; // ServiceAccountName is the name of the ServiceAccount to use to run this pod. - // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md + // More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ // +optional optional string serviceAccountName = 8; @@ -2492,6 +2719,10 @@ message PodSpec { // +optional optional string serviceAccount = 9; + // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. + // +optional + optional bool automountServiceAccountToken = 21; + // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, // the scheduler simply schedules this pod onto that node, assuming that it fits resource // requirements. @@ -2525,8 +2756,10 @@ message PodSpec { // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. // If specified, these secrets will be passed to individual puller implementations for them to use. For example, // in the case of docker, only DockerConfig type secrets are honored. - // More info: http://kubernetes.io/docs/user-guide/images#specifying-imagepullsecrets-on-a-pod + // More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod // +optional + // +patchMergeKey=name + // +patchStrategy=merge repeated LocalObjectReference imagePullSecrets = 15; // Specifies the hostname of the Pod @@ -2538,19 +2771,41 @@ message PodSpec { // If not specified, the pod will not have a domainname at all. // +optional optional string subdomain = 17; + + // If specified, the pod's scheduling constraints + // +optional + optional Affinity affinity = 18; + + // If specified, the pod will be dispatched by specified scheduler. + // If not specified, the pod will be dispatched by default scheduler. + // +optional + optional string schedulerName = 19; + + // If specified, the pod's tolerations. + // +optional + repeated Toleration tolerations = 22; + + // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts + // file if specified. This is only valid for non-hostNetwork pods. + // +optional + // +patchMergeKey=ip + // +patchStrategy=merge + repeated HostAlias hostAliases = 23; } // PodStatus represents information about the status of a pod. Status may trail the actual // state of a system. message PodStatus { // Current condition of the pod. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-phase + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase // +optional optional string phase = 1; // Current service state of pod. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated PodCondition conditions = 2; // A human readable message indicating details about why the pod is in this condition. @@ -2574,27 +2829,39 @@ message PodStatus { // RFC 3339 date and time at which the object was acknowledged by the Kubelet. // This is before the Kubelet pulled the container image(s) for the pod. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 7; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startTime = 7; + + // The list has one entry per init container in the manifest. The most recent successful + // init container will have ready = true, the most recently started container will have + // startTime set. + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status + repeated ContainerStatus initContainerStatuses = 10; // The list has one entry per container in the manifest. Each entry is currently the output // of `docker inspect`. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-statuses + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status // +optional repeated ContainerStatus containerStatuses = 8; + + // The Quality of Service (QOS) classification assigned to the pod based on resource requirements + // See PodQOSClass type for available QOS classes + // More info: https://github.com/kubernetes/kubernetes/blob/master/docs/design/resource-qos.md + // +optional + optional string qosClass = 9; } // PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded message PodStatusResult { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Most recently observed status of the pod. // This data may not be up to date. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional PodStatus status = 2; } @@ -2602,12 +2869,12 @@ message PodStatusResult { // PodTemplate describes a template for creating copies of a predefined pod. message PodTemplate { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Template defines the pods that will be created from this pod template. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional PodTemplateSpec template = 2; } @@ -2615,9 +2882,9 @@ message PodTemplate { // PodTemplateList is a list of PodTemplates. message PodTemplateList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of pod templates repeated PodTemplate items = 2; @@ -2626,17 +2893,34 @@ message PodTemplateList { // PodTemplateSpec describes the data a pod should have when created from a template message PodTemplateSpec { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Specification of the desired behavior of the pod. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional PodSpec spec = 2; } +// PortworxVolumeSource represents a Portworx volume resource. +message PortworxVolumeSource { + // VolumeID uniquely identifies a Portworx volume + optional string volumeID = 1; + + // FSType represents the filesystem type to mount + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. + optional string fsType = 2; + + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + optional bool readOnly = 3; +} + // Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. +// +k8s:openapi-gen=false message Preconditions { // Specifies the target UID. // +optional @@ -2650,7 +2934,7 @@ message PreferAvoidPodsEntry { // Time at which this entry was added to the list. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time evictionTime = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time evictionTime = 2; // (brief) reason why this entry was added to the list. // +optional @@ -2678,13 +2962,13 @@ message Probe { optional Handler handler = 1; // Number of seconds after the container has started before liveness probes are initiated. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional optional int32 initialDelaySeconds = 2; // Number of seconds after which the probe times out. // Defaults to 1 second. Minimum value is 1. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional optional int32 timeoutSeconds = 3; @@ -2704,6 +2988,20 @@ message Probe { optional int32 failureThreshold = 6; } +// Represents a projected volume source +message ProjectedVolumeSource { + // list of volume projections + repeated VolumeProjection sources = 1; + + // Mode bits to use on created files by default. Must be a value between + // 0 and 0777. + // Directories within the path are not affected by this setting. + // This might be in conflict with other options that affect the file + // mode, like fsGroup, and the result can be other mode bits set. + // +optional + optional int32 defaultMode = 2; +} + // Represents a Quobyte mount that lasts the lifetime of a pod. // Quobyte volumes do not support ownership management or SELinux relabeling. message QuobyteVolumeSource { @@ -2735,49 +3033,49 @@ message QuobyteVolumeSource { // RBD volumes support ownership management and SELinux relabeling. message RBDVolumeSource { // A collection of Ceph monitors. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it repeated string monitors = 1; // The rados image name. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it optional string image = 2; // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#rbd + // More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional optional string fsType = 3; // The rados pool name. // Default is rbd. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it. + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional optional string pool = 4; // The rados user name. // Default is admin. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional optional string user = 5; // Keyring is the path to key ring for RBDUser. // Default is /etc/ceph/keyring. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional optional string keyring = 6; // SecretRef is name of the authentication secret for RBDUser. If provided // overrides keyring. // Default is nil. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional optional LocalObjectReference secretRef = 7; // ReadOnly here will force the ReadOnly setting in VolumeMounts. // Defaults to false. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional optional bool readOnly = 8; } @@ -2785,9 +3083,9 @@ message RBDVolumeSource { // RangeAllocation is not a public type. message RangeAllocation { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Range is string that identifies the range represented by 'data'. optional string range = 2; @@ -2800,12 +3098,12 @@ message RangeAllocation { message ReplicationController { // If the Labels of a ReplicationController are empty, they are defaulted to // be the same as the Pod(s) that the replication controller manages. - // Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the specification of the desired behavior of the replication controller. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ReplicationControllerSpec spec = 2; @@ -2813,7 +3111,7 @@ message ReplicationController { // This data may be out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ReplicationControllerStatus status = 3; } @@ -2828,7 +3126,7 @@ message ReplicationControllerCondition { // The last time the condition transitioned from one status to another. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 3; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 3; // The reason for the condition's last transition. // +optional @@ -2842,12 +3140,12 @@ message ReplicationControllerCondition { // ReplicationControllerList is a collection of replication controllers. message ReplicationControllerList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of replication controllers. - // More info: http://kubernetes.io/docs/user-guide/replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller repeated ReplicationController items = 2; } @@ -2856,7 +3154,7 @@ message ReplicationControllerSpec { // Replicas is the number of desired replicas. // This is a pointer to distinguish between explicit zero and unspecified. // Defaults to 1. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller // +optional optional int32 replicas = 1; @@ -2870,13 +3168,13 @@ message ReplicationControllerSpec { // If Selector is empty, it is defaulted to the labels present on the Pod template. // Label keys and values that must match in order to be controlled by this replication // controller, if empty defaulted to labels on Pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional map selector = 2; // Template is the object that describes the pod that will be created if // insufficient replicas are detected. This takes precedence over a TemplateRef. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template // +optional optional PodTemplateSpec template = 3; } @@ -2885,7 +3183,7 @@ message ReplicationControllerSpec { // controller. message ReplicationControllerStatus { // Replicas is the most recently oberved number of replicas. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller optional int32 replicas = 1; // The number of pods that have labels matching the labels of the pod template of the replication controller. @@ -2906,6 +3204,8 @@ message ReplicationControllerStatus { // Represents the latest available observations of a replication controller's current state. // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated ReplicationControllerCondition conditions = 6; } @@ -2920,23 +3220,23 @@ message ResourceFieldSelector { // Specifies the output format of the exposed resources, defaults to "1" // +optional - optional k8s.io.kubernetes.pkg.api.resource.Quantity divisor = 3; + optional k8s.io.apimachinery.pkg.api.resource.Quantity divisor = 3; } // ResourceQuota sets aggregate quota restrictions enforced per namespace message ResourceQuota { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the desired quota. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ResourceQuotaSpec spec = 2; // Status defines the actual enforced quota and its current usage. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ResourceQuotaStatus status = 3; } @@ -2944,21 +3244,21 @@ message ResourceQuota { // ResourceQuotaList is a list of ResourceQuota items. message ResourceQuotaList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of ResourceQuota objects. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md repeated ResourceQuota items = 2; } // ResourceQuotaSpec defines the desired hard limits to enforce for Quota. message ResourceQuotaSpec { // Hard is the set of desired hard limits for each named resource. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md // +optional - map hard = 1; + map hard = 1; // A collection of filters that must match each object tracked by a quota. // If not specified, the quota matches all objects. @@ -2969,28 +3269,28 @@ message ResourceQuotaSpec { // ResourceQuotaStatus defines the enforced hard limits and observed use. message ResourceQuotaStatus { // Hard is the set of enforced hard limits for each named resource. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md // +optional - map hard = 1; + map hard = 1; // Used is the current observed total usage of the resource in the namespace. // +optional - map used = 2; + map used = 2; } // ResourceRequirements describes the compute resource requirements. message ResourceRequirements { // Limits describes the maximum amount of compute resources allowed. - // More info: http://kubernetes.io/docs/user-guide/compute-resources/ + // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional - map limits = 1; + map limits = 1; // Requests describes the minimum amount of compute resources required. // If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, // otherwise to an implementation-defined value. - // More info: http://kubernetes.io/docs/user-guide/compute-resources/ + // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional - map requests = 2; + map requests = 2; } // SELinuxOptions are the labels to be applied to the container @@ -3012,19 +3312,62 @@ message SELinuxOptions { optional string level = 4; } +// ScaleIOVolumeSource represents a persistent ScaleIO volume +message ScaleIOVolumeSource { + // The host address of the ScaleIO API Gateway. + optional string gateway = 1; + + // The name of the storage system as configured in ScaleIO. + optional string system = 2; + + // SecretRef references to the secret for ScaleIO user and other + // sensitive information. If this is not provided, Login operation will fail. + optional LocalObjectReference secretRef = 3; + + // Flag to enable/disable SSL communication with Gateway, default false + // +optional + optional bool sslEnabled = 4; + + // The name of the Protection Domain for the configured storage (defaults to "default"). + // +optional + optional string protectionDomain = 5; + + // The Storage Pool associated with the protection domain (defaults to "default"). + // +optional + optional string storagePool = 6; + + // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). + // +optional + optional string storageMode = 7; + + // The name of a volume already created in the ScaleIO system + // that is associated with this volume source. + optional string volumeName = 8; + + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + optional string fsType = 9; + + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + optional bool readOnly = 10; +} + // Secret holds secret data of a certain type. The total bytes of the values in // the Data field must be less than MaxSecretSize bytes. message Secret { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN - // or leading dot followed by valid DNS_SUBDOMAIN. - // The serialized form of the secret data is a base64 encoded string, - // representing the arbitrary (possibly non-string) data value here. - // Described in https://tools.ietf.org/html/rfc4648#section-4 + // Data contains the secret data. Each key must consist of alphanumeric + // characters, '-', '_' or '.'. The serialized form of the secret data is a + // base64 encoded string, representing the arbitrary (possibly non-string) + // data value here. Described in https://tools.ietf.org/html/rfc4648#section-4 // +optional map data = 2; @@ -3041,6 +3384,20 @@ message Secret { optional string type = 3; } +// SecretEnvSource selects a Secret to populate the environment +// variables with. +// +// The contents of the target Secret's Data field will represent the +// key-value pairs as environment variables. +message SecretEnvSource { + // The Secret to select from. + optional LocalObjectReference localObjectReference = 1; + + // Specify whether the Secret must be defined + // +optional + optional bool optional = 2; +} + // SecretKeySelector selects a key of a Secret. message SecretKeySelector { // The name of the secret in the pod's namespace to select from. @@ -3048,20 +3405,48 @@ message SecretKeySelector { // The key of the secret to select from. Must be a valid secret key. optional string key = 2; + + // Specify whether the Secret or it's key must be defined + // +optional + optional bool optional = 3; } // SecretList is a list of Secret. message SecretList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of secret objects. - // More info: http://kubernetes.io/docs/user-guide/secrets + // More info: https://kubernetes.io/docs/concepts/configuration/secret repeated Secret items = 2; } +// Adapts a secret into a projected volume. +// +// The contents of the target Secret's Data field will be presented in a +// projected volume as files using the keys in the Data field as the file names. +// Note that this is identical to a secret volume source without the default +// mode. +message SecretProjection { + optional LocalObjectReference localObjectReference = 1; + + // If unspecified, each key-value pair in the Data field of the referenced + // Secret will be projected into the volume as a file whose name is the + // key and content is the value. If specified, the listed keys will be + // projected into the specified paths, and unlisted keys will not be + // present. If a key is specified which is not present in the Secret, + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. + // +optional + repeated KeyToPath items = 2; + + // Specify whether the Secret or its key must be defined + // +optional + optional bool optional = 4; +} + // Adapts a Secret into a volume. // // The contents of the target Secret's Data field will be presented in a volume @@ -3069,7 +3454,7 @@ message SecretList { // Secret volumes support ownership management and SELinux relabeling. message SecretVolumeSource { // Name of the secret in the pod's namespace to use. - // More info: http://kubernetes.io/docs/user-guide/volumes#secrets + // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret // +optional optional string secretName = 1; @@ -3078,8 +3463,8 @@ message SecretVolumeSource { // key and content is the value. If specified, the listed keys will be // projected into the specified paths, and unlisted keys will not be // present. If a key is specified which is not present in the Secret, - // the volume setup will error. Paths must be relative and may not contain - // the '..' path or start with '..'. + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. // +optional repeated KeyToPath items = 2; @@ -3090,6 +3475,10 @@ message SecretVolumeSource { // mode, like fsGroup, and the result can be other mode bits set. // +optional optional int32 defaultMode = 3; + + // Specify whether the Secret or it's keys must be defined + // +optional + optional bool optional = 4; } // SecurityContext holds security configuration that will be applied to a container. @@ -3148,19 +3537,19 @@ message SerializedReference { // will answer requests sent through the proxy. message Service { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the behavior of a service. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ServiceSpec spec = 2; // Most recently observed status of the service. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ServiceStatus status = 3; } @@ -3171,41 +3560,48 @@ message Service { // * a set of secrets message ServiceAccount { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount. - // More info: http://kubernetes.io/docs/user-guide/secrets + // More info: https://kubernetes.io/docs/concepts/configuration/secret // +optional + // +patchMergeKey=name + // +patchStrategy=merge repeated ObjectReference secrets = 2; // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images // in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets // can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. - // More info: http://kubernetes.io/docs/user-guide/secrets#manually-specifying-an-imagepullsecret + // More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod // +optional repeated LocalObjectReference imagePullSecrets = 3; + + // AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. + // Can be overridden at the pod level. + // +optional + optional bool automountServiceAccountToken = 4; } // ServiceAccountList is a list of ServiceAccount objects message ServiceAccountList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of ServiceAccounts. - // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md#service-accounts + // More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ repeated ServiceAccount items = 2; } // ServiceList holds a list of services. message ServiceList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of services repeated Service items = 2; @@ -3235,15 +3631,15 @@ message ServicePort { // of the 'port' field is used (an identity map). // This field is ignored for services with clusterIP=None, and should be // omitted or set equal to the 'port' field. - // More info: http://kubernetes.io/docs/user-guide/services#defining-a-service + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service // +optional - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString targetPort = 4; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString targetPort = 4; // The port on each node on which this service is exposed when type=NodePort or LoadBalancer. // Usually assigned by the system. If specified, it will be allocated to the service // if unused or else creation of the service will fail. // Default is to auto-allocate a port if the ServiceType of this Service requires one. - // More info: http://kubernetes.io/docs/user-guide/services#type--nodeport + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport // +optional optional int32 nodePort = 5; } @@ -3262,7 +3658,9 @@ message ServiceProxyOptions { // ServiceSpec describes the attributes that a user creates on a service. message ServiceSpec { // The list of ports that are exposed by this service. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies + // +patchMergeKey=port + // +patchStrategy=merge repeated ServicePort ports = 1; // Route service traffic to pods with label keys and values matching this @@ -3270,7 +3668,7 @@ message ServiceSpec { // external process managing its endpoints, which Kubernetes will not // modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. // Ignored if type is ExternalName. - // More info: http://kubernetes.io/docs/user-guide/services#overview + // More info: https://kubernetes.io/docs/concepts/services-networking/service/ // +optional map selector = 2; @@ -3282,7 +3680,7 @@ message ServiceSpec { // can be specified for headless services when proxying is not required. // Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if // type is ExternalName. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies // +optional optional string clusterIP = 3; @@ -3299,7 +3697,7 @@ message ServiceSpec { // "LoadBalancer" builds on NodePort and creates an // external load-balancer (if supported in the current cloud) which routes // to the clusterIP. - // More info: http://kubernetes.io/docs/user-guide/services#overview + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services---service-types // +optional optional string type = 4; @@ -3307,26 +3705,15 @@ message ServiceSpec { // will also accept traffic for this service. These IPs are not managed by // Kubernetes. The user is responsible for ensuring that traffic arrives // at a node with this IP. A common example is external load-balancers - // that are not part of the Kubernetes system. A previous form of this - // functionality exists as the deprecatedPublicIPs field. When using this - // field, callers should also clear the deprecatedPublicIPs field. + // that are not part of the Kubernetes system. // +optional repeated string externalIPs = 5; - // deprecatedPublicIPs is deprecated and replaced by the externalIPs field - // with almost the exact same semantics. This field is retained in the v1 - // API for compatibility until at least 8/20/2016. It will be removed from - // any new API revisions. If both deprecatedPublicIPs *and* externalIPs are - // set, deprecatedPublicIPs is used. - // +k8s:conversion-gen=false - // +optional - repeated string deprecatedPublicIPs = 6; - // Supports "ClientIP" and "None". Used to maintain session affinity. // Enable client IP based session affinity. // Must be ClientIP or None. // Defaults to None. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies // +optional optional string sessionAffinity = 7; @@ -3341,7 +3728,7 @@ message ServiceSpec { // If specified and supported by the platform, this will restrict traffic through the cloud-provider // load-balancer will be restricted to the specified client IPs. This field will be ignored if the // cloud-provider does not support the feature." - // More info: http://kubernetes.io/docs/user-guide/services-firewalls + // More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/ // +optional repeated string loadBalancerSourceRanges = 9; @@ -3350,6 +3737,23 @@ message ServiceSpec { // Must be a valid DNS name and requires Type to be ExternalName. // +optional optional string externalName = 10; + + // externalTrafficPolicy denotes if this Service desires to route external + // traffic to node-local or cluster-wide endpoints. "Local" preserves the + // client source IP and avoids a second hop for LoadBalancer and Nodeport + // type services, but risks potentially imbalanced traffic spreading. + // "Cluster" obscures the client source IP and may cause a second hop to + // another node, but should have good overall load-spreading. + // +optional + optional string externalTrafficPolicy = 11; + + // healthCheckNodePort specifies the healthcheck nodePort for the service. + // If not specified, HealthCheckNodePort is created by the service api + // backend with the allocated nodePort. Will use user-specified nodePort value + // if specified by the client. Only effects when Type is set to LoadBalancer + // and ExternalTrafficPolicy is set to Local. + // +optional + optional int32 healthCheckNodePort = 12; } // ServiceStatus represents the current status of a service. @@ -3360,18 +3764,97 @@ message ServiceStatus { optional LoadBalancerStatus loadBalancer = 1; } +// Represents a StorageOS persistent volume resource. +message StorageOSPersistentVolumeSource { + // VolumeName is the human-readable name of the StorageOS volume. Volume + // names are only unique within a namespace. + optional string volumeName = 1; + + // VolumeNamespace specifies the scope of the volume within StorageOS. If no + // namespace is specified then the Pod's namespace will be used. This allows the + // Kubernetes name scoping to be mirrored within StorageOS for tighter integration. + // Set VolumeName to any name to override the default behaviour. + // Set to "default" if you are not using namespaces within StorageOS. + // Namespaces that do not pre-exist within StorageOS will be created. + // +optional + optional string volumeNamespace = 2; + + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + optional string fsType = 3; + + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + optional bool readOnly = 4; + + // SecretRef specifies the secret to use for obtaining the StorageOS API + // credentials. If not specified, default values will be attempted. + // +optional + optional ObjectReference secretRef = 5; +} + +// Represents a StorageOS persistent volume resource. +message StorageOSVolumeSource { + // VolumeName is the human-readable name of the StorageOS volume. Volume + // names are only unique within a namespace. + optional string volumeName = 1; + + // VolumeNamespace specifies the scope of the volume within StorageOS. If no + // namespace is specified then the Pod's namespace will be used. This allows the + // Kubernetes name scoping to be mirrored within StorageOS for tighter integration. + // Set VolumeName to any name to override the default behaviour. + // Set to "default" if you are not using namespaces within StorageOS. + // Namespaces that do not pre-exist within StorageOS will be created. + // +optional + optional string volumeNamespace = 2; + + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + optional string fsType = 3; + + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + optional bool readOnly = 4; + + // SecretRef specifies the secret to use for obtaining the StorageOS API + // credentials. If not specified, default values will be attempted. + // +optional + optional LocalObjectReference secretRef = 5; +} + +// Sysctl defines a kernel parameter to be set +message Sysctl { + // Name of a property to set + optional string name = 1; + + // Value of a property to set + optional string value = 2; +} + // TCPSocketAction describes an action based on opening a socket message TCPSocketAction { // Number or name of the port to access on the container. // Number must be in the range 1 to 65535. // Name must be an IANA_SVC_NAME. - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString port = 1; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 1; + + // Optional: Host name to connect to, defaults to the pod IP. + // +optional + optional string host = 2; } // The node this Taint is attached to has the effect "effect" on // any pod that that does not tolerate the Taint. message Taint { // Required. The taint key to be applied to a node. + // +patchMergeKey=key + // +patchStrategy=merge optional string key = 1; // Required. The taint value corresponding to the taint key. @@ -3380,18 +3863,26 @@ message Taint { // Required. The effect of the taint on pods // that do not tolerate the taint. - // Valid effects are NoSchedule and PreferNoSchedule. + // Valid effects are NoSchedule, PreferNoSchedule and NoExecute. optional string effect = 3; + + // TimeAdded represents the time at which the taint was added. + // It is only written for NoExecute taints. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time timeAdded = 4; } // The pod this Toleration is attached to tolerates any taint that matches // the triple using the matching operator . message Toleration { - // Required. Key is the taint key that the toleration applies to. + // Key is the taint key that the toleration applies to. Empty means match all taint keys. + // If the key is empty, operator must be Exists; this combination means to match all values and all keys. // +optional + // +patchMergeKey=key + // +patchStrategy=merge optional string key = 1; - // operator represents a key's relationship to the value. + // Operator represents a key's relationship to the value. // Valid operators are Exists and Equal. Defaults to Equal. // Exists is equivalent to wildcard for value, so that a pod can // tolerate all taints of a particular category. @@ -3404,16 +3895,23 @@ message Toleration { optional string value = 3; // Effect indicates the taint effect to match. Empty means match all taint effects. - // When specified, allowed values are NoSchedule and PreferNoSchedule. + // When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. // +optional optional string effect = 4; + + // TolerationSeconds represents the period of time the toleration (which must be + // of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, + // it is not set, which means tolerate the taint forever (do not evict). Zero and + // negative values will be treated as 0 (evict immediately) by the system. + // +optional + optional int64 tolerationSeconds = 5; } // Volume represents a named volume in a pod that may be accessed by any container in the pod. message Volume { // Volume's name. // Must be a DNS_LABEL and unique within the pod. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names optional string name = 1; // VolumeSource represents the location and type of the mounted volume. @@ -3442,6 +3940,18 @@ message VolumeMount { optional string subPath = 4; } +// Projection that may be projected along with other supported volume types +message VolumeProjection { + // information about the secret data to project + optional SecretProjection secret = 1; + + // information about the downwardAPI data to project + optional DownwardAPIProjection downwardAPI = 2; + + // information about the configMap data to project + optional ConfigMapProjection configMap = 3; +} + // Represents the source of a volume to mount. // Only one of its members may be specified. message VolumeSource { @@ -3449,7 +3959,7 @@ message VolumeSource { // machine that is directly exposed to the container. This is generally // used for system agents or other privileged things that are allowed // to see the host machine. Most containers will NOT need this. - // More info: http://kubernetes.io/docs/user-guide/volumes#hostpath + // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath // --- // TODO(jonesdl) We need to restrict who can use host directory mounts and who can/can not // mount host directories as read/write. @@ -3457,19 +3967,19 @@ message VolumeSource { optional HostPathVolumeSource hostPath = 1; // EmptyDir represents a temporary directory that shares a pod's lifetime. - // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional optional EmptyDirVolumeSource emptyDir = 2; // GCEPersistentDisk represents a GCE Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional optional GCEPersistentDiskVolumeSource gcePersistentDisk = 3; // AWSElasticBlockStore represents an AWS Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // +optional optional AWSElasticBlockStoreVolumeSource awsElasticBlockStore = 4; @@ -3478,34 +3988,34 @@ message VolumeSource { optional GitRepoVolumeSource gitRepo = 5; // Secret represents a secret that should populate this volume. - // More info: http://kubernetes.io/docs/user-guide/volumes#secrets + // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret // +optional optional SecretVolumeSource secret = 6; // NFS represents an NFS mount on the host that shares a pod's lifetime - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs // +optional optional NFSVolumeSource nfs = 7; // ISCSI represents an ISCSI Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md // +optional optional ISCSIVolumeSource iscsi = 8; // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md // +optional optional GlusterfsVolumeSource glusterfs = 9; // PersistentVolumeClaimVolumeSource represents a reference to a // PersistentVolumeClaim in the same namespace. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims // +optional optional PersistentVolumeClaimVolumeSource persistentVolumeClaim = 10; // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md // +optional optional RBDVolumeSource rbd = 11; @@ -3516,7 +4026,7 @@ message VolumeSource { optional FlexVolumeSource flexVolume = 12; // Cinder represents a cinder volume attached and mounted on kubelets host machine - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional optional CinderVolumeSource cinder = 13; @@ -3558,6 +4068,21 @@ message VolumeSource { // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine optional PhotonPersistentDiskVolumeSource photonPersistentDisk = 23; + + // Items for all in one resources secrets, configmaps, and downward API + optional ProjectedVolumeSource projected = 26; + + // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine + // +optional + optional PortworxVolumeSource portworxVolume = 24; + + // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. + // +optional + optional ScaleIOVolumeSource scaleIO = 25; + + // StorageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. + // +optional + optional StorageOSVolumeSource storageos = 27; } // Represents a vSphere volume resource. @@ -3570,6 +4095,14 @@ message VsphereVirtualDiskVolumeSource { // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // +optional optional string fsType = 2; + + // Storage Policy Based Management (SPBM) profile name. + // +optional + optional string storagePolicyName = 3; + + // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. + // +optional + optional string storagePolicyID = 4; } // The weights of all of the matched WeightedPodAffinityTerm fields are added per-node to find the most preferred node(s) diff --git a/vendor/k8s.io/client-go/pkg/api/v1/helpers.go b/vendor/k8s.io/client-go/pkg/api/v1/helpers.go deleted file mode 100644 index d33a79c724..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/v1/helpers.go +++ /dev/null @@ -1,33 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1 - -import "k8s.io/client-go/pkg/types" - -// NewDeleteOptions returns a DeleteOptions indicating the resource should -// be deleted within the specified grace period. Use zero to indicate -// immediate deletion. If you would prefer to use the default grace period, -// use &v1.DeleteOptions{} directly. -func NewDeleteOptions(grace int64) *DeleteOptions { - return &DeleteOptions{GracePeriodSeconds: &grace} -} - -// NewUIDPreconditions returns a Preconditions with UID set. -func NewUIDPreconditions(uid string) *Preconditions { - u := types.UID(uid) - return &Preconditions{UID: &u} -} diff --git a/vendor/k8s.io/client-go/pkg/api/v1/meta.go b/vendor/k8s.io/client-go/pkg/api/v1/meta.go index a641eb2b53..0e3f5d9209 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/meta.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/meta.go @@ -17,45 +17,53 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/meta/metatypes" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/types" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/types" ) -func (obj *ObjectMeta) GetObjectMeta() meta.Object { return obj } +func (obj *ObjectMeta) GetObjectMeta() metav1.Object { return obj } -// Namespace implements meta.Object for any object with an ObjectMeta typed field. Allows +// Namespace implements metav1.Object for any object with an ObjectMeta typed field. Allows // fast, direct access to metadata fields for API objects. -func (meta *ObjectMeta) GetNamespace() string { return meta.Namespace } -func (meta *ObjectMeta) SetNamespace(namespace string) { meta.Namespace = namespace } -func (meta *ObjectMeta) GetName() string { return meta.Name } -func (meta *ObjectMeta) SetName(name string) { meta.Name = name } -func (meta *ObjectMeta) GetGenerateName() string { return meta.GenerateName } -func (meta *ObjectMeta) SetGenerateName(generateName string) { meta.GenerateName = generateName } -func (meta *ObjectMeta) GetUID() types.UID { return meta.UID } -func (meta *ObjectMeta) SetUID(uid types.UID) { meta.UID = uid } -func (meta *ObjectMeta) GetResourceVersion() string { return meta.ResourceVersion } -func (meta *ObjectMeta) SetResourceVersion(version string) { meta.ResourceVersion = version } -func (meta *ObjectMeta) GetSelfLink() string { return meta.SelfLink } -func (meta *ObjectMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink } -func (meta *ObjectMeta) GetCreationTimestamp() unversioned.Time { return meta.CreationTimestamp } -func (meta *ObjectMeta) SetCreationTimestamp(creationTimestamp unversioned.Time) { +func (meta *ObjectMeta) GetNamespace() string { return meta.Namespace } +func (meta *ObjectMeta) SetNamespace(namespace string) { meta.Namespace = namespace } +func (meta *ObjectMeta) GetName() string { return meta.Name } +func (meta *ObjectMeta) SetName(name string) { meta.Name = name } +func (meta *ObjectMeta) GetGenerateName() string { return meta.GenerateName } +func (meta *ObjectMeta) SetGenerateName(generateName string) { meta.GenerateName = generateName } +func (meta *ObjectMeta) GetUID() types.UID { return meta.UID } +func (meta *ObjectMeta) SetUID(uid types.UID) { meta.UID = uid } +func (meta *ObjectMeta) GetResourceVersion() string { return meta.ResourceVersion } +func (meta *ObjectMeta) SetResourceVersion(version string) { meta.ResourceVersion = version } +func (meta *ObjectMeta) GetGeneration() int64 { return meta.Generation } +func (meta *ObjectMeta) SetGeneration(generation int64) { meta.Generation = generation } +func (meta *ObjectMeta) GetSelfLink() string { return meta.SelfLink } +func (meta *ObjectMeta) SetSelfLink(selfLink string) { meta.SelfLink = selfLink } +func (meta *ObjectMeta) GetCreationTimestamp() metav1.Time { return meta.CreationTimestamp } +func (meta *ObjectMeta) SetCreationTimestamp(creationTimestamp metav1.Time) { meta.CreationTimestamp = creationTimestamp } -func (meta *ObjectMeta) GetDeletionTimestamp() *unversioned.Time { return meta.DeletionTimestamp } -func (meta *ObjectMeta) SetDeletionTimestamp(deletionTimestamp *unversioned.Time) { +func (meta *ObjectMeta) GetDeletionTimestamp() *metav1.Time { return meta.DeletionTimestamp } +func (meta *ObjectMeta) SetDeletionTimestamp(deletionTimestamp *metav1.Time) { meta.DeletionTimestamp = deletionTimestamp } +func (meta *ObjectMeta) GetDeletionGracePeriodSeconds() *int64 { return meta.DeletionGracePeriodSeconds } +func (meta *ObjectMeta) SetDeletionGracePeriodSeconds(deletionGracePeriodSeconds *int64) { + meta.DeletionGracePeriodSeconds = deletionGracePeriodSeconds +} func (meta *ObjectMeta) GetLabels() map[string]string { return meta.Labels } func (meta *ObjectMeta) SetLabels(labels map[string]string) { meta.Labels = labels } func (meta *ObjectMeta) GetAnnotations() map[string]string { return meta.Annotations } func (meta *ObjectMeta) SetAnnotations(annotations map[string]string) { meta.Annotations = annotations } -func (meta *ObjectMeta) GetFinalizers() []string { return meta.Finalizers } -func (meta *ObjectMeta) SetFinalizers(finalizers []string) { meta.Finalizers = finalizers } +func (meta *ObjectMeta) GetInitializers() *metav1.Initializers { return meta.Initializers } +func (meta *ObjectMeta) SetInitializers(initializers *metav1.Initializers) { + meta.Initializers = initializers +} +func (meta *ObjectMeta) GetFinalizers() []string { return meta.Finalizers } +func (meta *ObjectMeta) SetFinalizers(finalizers []string) { meta.Finalizers = finalizers } -func (meta *ObjectMeta) GetOwnerReferences() []metatypes.OwnerReference { - ret := make([]metatypes.OwnerReference, len(meta.OwnerReferences)) +func (meta *ObjectMeta) GetOwnerReferences() []metav1.OwnerReference { + ret := make([]metav1.OwnerReference, len(meta.OwnerReferences)) for i := 0; i < len(meta.OwnerReferences); i++ { ret[i].Kind = meta.OwnerReferences[i].Kind ret[i].Name = meta.OwnerReferences[i].Name @@ -65,12 +73,16 @@ func (meta *ObjectMeta) GetOwnerReferences() []metatypes.OwnerReference { value := *meta.OwnerReferences[i].Controller ret[i].Controller = &value } + if meta.OwnerReferences[i].BlockOwnerDeletion != nil { + value := *meta.OwnerReferences[i].BlockOwnerDeletion + ret[i].BlockOwnerDeletion = &value + } } return ret } -func (meta *ObjectMeta) SetOwnerReferences(references []metatypes.OwnerReference) { - newReferences := make([]OwnerReference, len(references)) +func (meta *ObjectMeta) SetOwnerReferences(references []metav1.OwnerReference) { + newReferences := make([]metav1.OwnerReference, len(references)) for i := 0; i < len(references); i++ { newReferences[i].Kind = references[i].Kind newReferences[i].Name = references[i].Name @@ -80,6 +92,10 @@ func (meta *ObjectMeta) SetOwnerReferences(references []metatypes.OwnerReference value := *references[i].Controller newReferences[i].Controller = &value } + if references[i].BlockOwnerDeletion != nil { + value := *references[i].BlockOwnerDeletion + newReferences[i].BlockOwnerDeletion = &value + } } meta.OwnerReferences = newReferences } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/objectreference.go b/vendor/k8s.io/client-go/pkg/api/v1/objectreference.go new file mode 100644 index 0000000000..ee5335ee87 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/objectreference.go @@ -0,0 +1,33 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// IsAnAPIObject allows clients to preemptively get a reference to an API object and pass it to places that +// intend only to get a reference to that object. This simplifies the event recording interface. +func (obj *ObjectReference) SetGroupVersionKind(gvk schema.GroupVersionKind) { + obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() +} + +func (obj *ObjectReference) GroupVersionKind() schema.GroupVersionKind { + return schema.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) +} + +func (obj *ObjectReference) GetObjectKind() schema.ObjectKind { return obj } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/ref.go b/vendor/k8s.io/client-go/pkg/api/v1/ref.go deleted file mode 100644 index 69bed2fa8c..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/v1/ref.go +++ /dev/null @@ -1,133 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1 - -import ( - "errors" - "fmt" - "k8s.io/client-go/pkg/api" - "net/url" - "strings" - - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" -) - -var ( - // Errors that could be returned by GetReference. - ErrNilObject = errors.New("can't reference a nil object") - ErrNoSelfLink = errors.New("selfLink was empty, can't make reference") -) - -// GetReference returns an ObjectReference which refers to the given -// object, or an error if the object doesn't follow the conventions -// that would allow this. -// TODO: should take a meta.Interface see http://issue.k8s.io/7127 -func GetReference(obj runtime.Object) (*ObjectReference, error) { - if obj == nil { - return nil, ErrNilObject - } - if ref, ok := obj.(*ObjectReference); ok { - // Don't make a reference to a reference. - return ref, nil - } - - gvk := obj.GetObjectKind().GroupVersionKind() - - // if the object referenced is actually persisted, we can just get kind from meta - // if we are building an object reference to something not yet persisted, we should fallback to scheme - kind := gvk.Kind - if len(kind) == 0 { - // TODO: this is wrong - gvks, _, err := api.Scheme.ObjectKinds(obj) - if err != nil { - return nil, err - } - kind = gvks[0].Kind - } - - // An object that implements only List has enough metadata to build a reference - var listMeta meta.List - objectMeta, err := meta.Accessor(obj) - if err != nil { - listMeta, err = meta.ListAccessor(obj) - if err != nil { - return nil, err - } - } else { - listMeta = objectMeta - } - - // if the object referenced is actually persisted, we can also get version from meta - version := gvk.GroupVersion().String() - if len(version) == 0 { - selfLink := listMeta.GetSelfLink() - if len(selfLink) == 0 { - return nil, ErrNoSelfLink - } - selfLinkUrl, err := url.Parse(selfLink) - if err != nil { - return nil, err - } - // example paths: ///* - parts := strings.Split(selfLinkUrl.Path, "/") - if len(parts) < 3 { - return nil, fmt.Errorf("unexpected self link format: '%v'; got version '%v'", selfLink, version) - } - version = parts[2] - } - - // only has list metadata - if objectMeta == nil { - return &ObjectReference{ - Kind: kind, - APIVersion: version, - ResourceVersion: listMeta.GetResourceVersion(), - }, nil - } - - return &ObjectReference{ - Kind: kind, - APIVersion: version, - Name: objectMeta.GetName(), - Namespace: objectMeta.GetNamespace(), - UID: objectMeta.GetUID(), - ResourceVersion: objectMeta.GetResourceVersion(), - }, nil -} - -// GetPartialReference is exactly like GetReference, but allows you to set the FieldPath. -func GetPartialReference(obj runtime.Object, fieldPath string) (*ObjectReference, error) { - ref, err := GetReference(obj) - if err != nil { - return nil, err - } - ref.FieldPath = fieldPath - return ref, nil -} - -// IsAnAPIObject allows clients to preemptively get a reference to an API object and pass it to places that -// intend only to get a reference to that object. This simplifies the event recording interface. -func (obj *ObjectReference) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { - obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() -} -func (obj *ObjectReference) GroupVersionKind() unversioned.GroupVersionKind { - return unversioned.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) -} - -func (obj *ObjectReference) GetObjectKind() unversioned.ObjectKind { return obj } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/ref/BUILD b/vendor/k8s.io/client-go/pkg/api/v1/ref/BUILD new file mode 100644 index 0000000000..f9d8716b7e --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/ref/BUILD @@ -0,0 +1,19 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["ref.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/api/ref.go b/vendor/k8s.io/client-go/pkg/api/v1/ref/ref.go similarity index 74% rename from vendor/k8s.io/client-go/pkg/api/ref.go rename to vendor/k8s.io/client-go/pkg/api/v1/ref/ref.go index afa80004a4..51f69555d7 100644 --- a/vendor/k8s.io/client-go/pkg/api/ref.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/ref/ref.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package api +package ref import ( "errors" @@ -22,9 +22,9 @@ import ( "net/url" "strings" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api/v1" ) var ( @@ -37,11 +37,11 @@ var ( // object, or an error if the object doesn't follow the conventions // that would allow this. // TODO: should take a meta.Interface see http://issue.k8s.io/7127 -func GetReference(obj runtime.Object) (*ObjectReference, error) { +func GetReference(scheme *runtime.Scheme, obj runtime.Object) (*v1.ObjectReference, error) { if obj == nil { return nil, ErrNilObject } - if ref, ok := obj.(*ObjectReference); ok { + if ref, ok := obj.(*v1.ObjectReference); ok { // Don't make a reference to a reference. return ref, nil } @@ -53,7 +53,7 @@ func GetReference(obj runtime.Object) (*ObjectReference, error) { kind := gvk.Kind if len(kind) == 0 { // TODO: this is wrong - gvks, _, err := Scheme.ObjectKinds(obj) + gvks, _, err := scheme.ObjectKinds(obj) if err != nil { return nil, err } @@ -93,14 +93,14 @@ func GetReference(obj runtime.Object) (*ObjectReference, error) { // only has list metadata if objectMeta == nil { - return &ObjectReference{ + return &v1.ObjectReference{ Kind: kind, APIVersion: version, ResourceVersion: listMeta.GetResourceVersion(), }, nil } - return &ObjectReference{ + return &v1.ObjectReference{ Kind: kind, APIVersion: version, Name: objectMeta.GetName(), @@ -111,22 +111,11 @@ func GetReference(obj runtime.Object) (*ObjectReference, error) { } // GetPartialReference is exactly like GetReference, but allows you to set the FieldPath. -func GetPartialReference(obj runtime.Object, fieldPath string) (*ObjectReference, error) { - ref, err := GetReference(obj) +func GetPartialReference(scheme *runtime.Scheme, obj runtime.Object, fieldPath string) (*v1.ObjectReference, error) { + ref, err := GetReference(scheme, obj) if err != nil { return nil, err } ref.FieldPath = fieldPath return ref, nil } - -// IsAnAPIObject allows clients to preemptively get a reference to an API object and pass it to places that -// intend only to get a reference to that object. This simplifies the event recording interface. -func (obj *ObjectReference) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { - obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() -} -func (obj *ObjectReference) GroupVersionKind() unversioned.GroupVersionKind { - return unversioned.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) -} - -func (obj *ObjectReference) GetObjectKind() unversioned.ObjectKind { return obj } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/register.go b/vendor/k8s.io/client-go/pkg/api/v1/register.go index 7f31222fbf..c70d6ac561 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/register.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/register.go @@ -17,22 +17,37 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs, addFastPathConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs, addFastPathConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, @@ -69,12 +84,10 @@ func addKnownTypes(scheme *runtime.Scheme) error { &PersistentVolumeList{}, &PersistentVolumeClaim{}, &PersistentVolumeClaimList{}, - &DeleteOptions{}, - &ExportOptions{}, - &ListOptions{}, &PodAttachOptions{}, &PodLogOptions{}, &PodExecOptions{}, + &PodPortForwardOptions{}, &PodProxyOptions{}, &ComponentStatus{}, &ComponentStatusList{}, @@ -85,9 +98,9 @@ func addKnownTypes(scheme *runtime.Scheme) error { ) // Add common types - scheme.AddKnownTypes(SchemeGroupVersion, &unversioned.Status{}) + scheme.AddKnownTypes(SchemeGroupVersion, &metav1.Status{}) // Add the watch version that applies - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/resource.go b/vendor/k8s.io/client-go/pkg/api/v1/resource.go new file mode 100644 index 0000000000..0d1c1dccd2 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/resource.go @@ -0,0 +1,63 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/api/resource" +) + +// Returns string version of ResourceName. +func (self ResourceName) String() string { + return string(self) +} + +// Returns the CPU limit if specified. +func (self *ResourceList) Cpu() *resource.Quantity { + if val, ok := (*self)[ResourceCPU]; ok { + return &val + } + return &resource.Quantity{Format: resource.DecimalSI} +} + +// Returns the Memory limit if specified. +func (self *ResourceList) Memory() *resource.Quantity { + if val, ok := (*self)[ResourceMemory]; ok { + return &val + } + return &resource.Quantity{Format: resource.BinarySI} +} + +func (self *ResourceList) Pods() *resource.Quantity { + if val, ok := (*self)[ResourcePods]; ok { + return &val + } + return &resource.Quantity{} +} + +func (self *ResourceList) NvidiaGPU() *resource.Quantity { + if val, ok := (*self)[ResourceNvidiaGPU]; ok { + return &val + } + return &resource.Quantity{} +} + +func (self *ResourceList) StorageOverlay() *resource.Quantity { + if val, ok := (*self)[ResourceStorageOverlay]; ok { + return &val + } + return &resource.Quantity{} +} diff --git a/vendor/k8s.io/client-go/pkg/api/v1/taint.go b/vendor/k8s.io/client-go/pkg/api/v1/taint.go new file mode 100644 index 0000000000..7b606a3090 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/taint.go @@ -0,0 +1,33 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import "fmt" + +// MatchTaint checks if the taint matches taintToMatch. Taints are unique by key:effect, +// if the two taints have same key:effect, regard as they match. +func (t *Taint) MatchTaint(taintToMatch *Taint) bool { + return t.Key == taintToMatch.Key && t.Effect == taintToMatch.Effect +} + +// taint.ToString() converts taint struct to string in format key=value:effect or key:effect. +func (t *Taint) ToString() string { + if len(t.Value) == 0 { + return fmt.Sprintf("%v:%v", t.Key, t.Effect) + } + return fmt.Sprintf("%v=%v:%v", t.Key, t.Value, t.Effect) +} diff --git a/vendor/k8s.io/client-go/pkg/api/v1/toleration.go b/vendor/k8s.io/client-go/pkg/api/v1/toleration.go new file mode 100644 index 0000000000..b203d335b6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/api/v1/toleration.go @@ -0,0 +1,56 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +// MatchToleration checks if the toleration matches tolerationToMatch. Tolerations are unique by , +// if the two tolerations have same combination, regard as they match. +// TODO: uniqueness check for tolerations in api validations. +func (t *Toleration) MatchToleration(tolerationToMatch *Toleration) bool { + return t.Key == tolerationToMatch.Key && + t.Effect == tolerationToMatch.Effect && + t.Operator == tolerationToMatch.Operator && + t.Value == tolerationToMatch.Value +} + +// ToleratesTaint checks if the toleration tolerates the taint. +// The matching follows the rules below: +// (1) Empty toleration.effect means to match all taint effects, +// otherwise taint effect must equal to toleration.effect. +// (2) If toleration.operator is 'Exists', it means to match all taint values. +// (3) Empty toleration.key means to match all taint keys. +// If toleration.key is empty, toleration.operator must be 'Exists'; +// this combination means to match all taint values and all taint keys. +func (t *Toleration) ToleratesTaint(taint *Taint) bool { + if len(t.Effect) > 0 && t.Effect != taint.Effect { + return false + } + + if len(t.Key) > 0 && t.Key != taint.Key { + return false + } + + // TODO: Use proper defaulting when Toleration becomes a field of PodSpec + switch t.Operator { + // empty operator means Equal + case "", TolerationOpEqual: + return t.Value == taint.Value + case TolerationOpExists: + return true + default: + return false + } +} diff --git a/vendor/k8s.io/client-go/pkg/api/v1/types.generated.go b/vendor/k8s.io/client-go/pkg/api/v1/types.generated.go index 2c30987d83..9bd5aa8456 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/types.generated.go @@ -25,11 +25,11 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg3_resource "k8s.io/client-go/pkg/api/resource" - pkg2_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg5_runtime "k8s.io/client-go/pkg/runtime" - pkg1_types "k8s.io/client-go/pkg/types" - pkg4_intstr "k8s.io/client-go/pkg/util/intstr" + pkg3_resource "k8s.io/apimachinery/pkg/api/resource" + pkg2_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg5_runtime "k8s.io/apimachinery/pkg/runtime" + pkg1_types "k8s.io/apimachinery/pkg/types" + pkg4_intstr "k8s.io/apimachinery/pkg/util/intstr" "reflect" "runtime" time "time" @@ -66,7 +66,7 @@ func init() { } if false { // reference the types, but skip this branch at build/run time var v0 pkg3_resource.Quantity - var v1 pkg2_unversioned.Time + var v1 pkg2_v1.Time var v2 pkg5_runtime.RawExtension var v3 pkg1_types.UID var v4 pkg4_intstr.IntOrString @@ -89,7 +89,7 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [15]bool + var yyq2 [16]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false yyq2[0] = x.Name != "" @@ -105,11 +105,12 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { 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 != "" + yyq2[13] = x.Initializers != nil + yyq2[14] = len(x.Finalizers) != 0 + yyq2[15] = x.ClusterName != "" var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(15) + r.EncodeArrayStart(16) } else { yynn2 = 0 for _, b := range yyq2 { @@ -488,7 +489,7 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { _ = yym44 if false { } else { - h.encSliceOwnerReference(([]OwnerReference)(x.OwnerReferences), e) + h.encSlicev1_OwnerReference(([]pkg2_v1.OwnerReference)(x.OwnerReferences), e) } } } else { @@ -506,7 +507,7 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { _ = yym45 if false { } else { - h.encSliceOwnerReference(([]OwnerReference)(x.OwnerReferences), e) + h.encSlicev1_OwnerReference(([]pkg2_v1.OwnerReference)(x.OwnerReferences), e) } } } @@ -514,14 +515,15 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[13] { - if x.Finalizers == nil { + if x.Initializers == nil { r.EncodeNil() } else { yym47 := z.EncBinary() _ = yym47 if false { + } else if z.HasExtensions() && z.EncExt(x.Initializers) { } else { - z.F.EncSliceStringV(x.Finalizers, false, e) + z.EncFallback(x.Initializers) } } } else { @@ -530,16 +532,17 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { } else { if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finalizers")) + r.EncodeString(codecSelferC_UTF81234, string("initializers")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { + if x.Initializers == nil { r.EncodeNil() } else { yym48 := z.EncBinary() _ = yym48 if false { + } else if z.HasExtensions() && z.EncExt(x.Initializers) { } else { - z.F.EncSliceStringV(x.Finalizers, false, e) + z.EncFallback(x.Initializers) } } } @@ -547,8 +550,41 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[14] { - yym50 := z.EncBinary() - _ = yym50 + if x.Finalizers == nil { + r.EncodeNil() + } else { + yym50 := z.EncBinary() + _ = yym50 + if false { + } else { + z.F.EncSliceStringV(x.Finalizers, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[14] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("finalizers")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Finalizers == nil { + r.EncodeNil() + } else { + yym51 := z.EncBinary() + _ = yym51 + if false { + } else { + z.F.EncSliceStringV(x.Finalizers, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[15] { + yym53 := z.EncBinary() + _ = yym53 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) @@ -557,12 +593,12 @@ func (x *ObjectMeta) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2[14] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("clusterName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym51 := z.EncBinary() - _ = yym51 + yym54 := z.EncBinary() + _ = yym54 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) @@ -582,25 +618,25 @@ func (x *ObjectMeta) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym52 := z.DecBinary() - _ = yym52 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct53 := r.ContainerType() - if yyct53 == codecSelferValueTypeMap1234 { - yyl53 := r.ReadMapStart() - if yyl53 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl53, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct53 == codecSelferValueTypeArray1234 { - yyl53 := r.ReadArrayStart() - if yyl53 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl53, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -612,12 +648,12 @@ 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 { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -626,67 +662,110 @@ func (x *ObjectMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys54Slc = r.DecodeBytes(yys54Slc, true, true) - yys54 := string(yys54Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys54 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "generateName": if r.TryDecodeAsNil() { x.GenerateName = "" } else { - x.GenerateName = string(r.DecodeString()) + yyv6 := &x.GenerateName + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "namespace": if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv8 := &x.Namespace + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "selfLink": if r.TryDecodeAsNil() { x.SelfLink = "" } else { - x.SelfLink = string(r.DecodeString()) + yyv10 := &x.SelfLink + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "uid": if r.TryDecodeAsNil() { x.UID = "" } else { - x.UID = pkg1_types.UID(r.DecodeString()) + yyv12 := &x.UID + yym13 := z.DecBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "resourceVersion": if r.TryDecodeAsNil() { x.ResourceVersion = "" } else { - x.ResourceVersion = string(r.DecodeString()) + yyv14 := &x.ResourceVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "generation": if r.TryDecodeAsNil() { x.Generation = 0 } else { - x.Generation = int64(r.DecodeInt(64)) + yyv16 := &x.Generation + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*int64)(yyv16)) = int64(r.DecodeInt(64)) + } } case "creationTimestamp": if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg2_unversioned.Time{} + x.CreationTimestamp = pkg2_v1.Time{} } else { - yyv62 := &x.CreationTimestamp - yym63 := z.DecBinary() - _ = yym63 + yyv18 := &x.CreationTimestamp + yym19 := z.DecBinary() + _ = yym19 if false { - } else if z.HasExtensions() && z.DecExt(yyv62) { - } else if yym63 { - z.DecBinaryUnmarshal(yyv62) - } else if !yym63 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv62) + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else if yym19 { + z.DecBinaryUnmarshal(yyv18) + } else if !yym19 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv18) } else { - z.DecFallback(yyv62, false) + z.DecFallback(yyv18, false) } } case "deletionTimestamp": @@ -696,15 +775,15 @@ func (x *ObjectMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg2_unversioned.Time) + x.DeletionTimestamp = new(pkg2_v1.Time) } - yym65 := z.DecBinary() - _ = yym65 + yym21 := z.DecBinary() + _ = yym21 if false { } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym65 { + } else if yym21 { z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym65 && z.IsJSONHandle() { + } else if !yym21 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.DeletionTimestamp) } else { z.DecFallback(x.DeletionTimestamp, false) @@ -719,8 +798,8 @@ func (x *ObjectMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.DeletionGracePeriodSeconds == nil { x.DeletionGracePeriodSeconds = new(int64) } - yym67 := z.DecBinary() - _ = yym67 + yym23 := z.DecBinary() + _ = yym23 if false { } else { *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) @@ -730,60 +809,83 @@ func (x *ObjectMeta) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Labels = nil } else { - yyv68 := &x.Labels - yym69 := z.DecBinary() - _ = yym69 + yyv24 := &x.Labels + yym25 := z.DecBinary() + _ = yym25 if false { } else { - z.F.DecMapStringStringX(yyv68, false, d) + z.F.DecMapStringStringX(yyv24, false, d) } } case "annotations": if r.TryDecodeAsNil() { x.Annotations = nil } else { - yyv70 := &x.Annotations - yym71 := z.DecBinary() - _ = yym71 + yyv26 := &x.Annotations + yym27 := z.DecBinary() + _ = yym27 if false { } else { - z.F.DecMapStringStringX(yyv70, false, d) + z.F.DecMapStringStringX(yyv26, false, d) } } case "ownerReferences": if r.TryDecodeAsNil() { x.OwnerReferences = nil } else { - yyv72 := &x.OwnerReferences - yym73 := z.DecBinary() - _ = yym73 + yyv28 := &x.OwnerReferences + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + h.decSlicev1_OwnerReference((*[]pkg2_v1.OwnerReference)(yyv28), d) + } + } + case "initializers": + if r.TryDecodeAsNil() { + if x.Initializers != nil { + x.Initializers = nil + } + } else { + if x.Initializers == nil { + x.Initializers = new(pkg2_v1.Initializers) + } + yym31 := z.DecBinary() + _ = yym31 if false { + } else if z.HasExtensions() && z.DecExt(x.Initializers) { } else { - h.decSliceOwnerReference((*[]OwnerReference)(yyv72), d) + z.DecFallback(x.Initializers, false) } } case "finalizers": if r.TryDecodeAsNil() { x.Finalizers = nil } else { - yyv74 := &x.Finalizers - yym75 := z.DecBinary() - _ = yym75 + yyv32 := &x.Finalizers + yym33 := z.DecBinary() + _ = yym33 if false { } else { - z.F.DecSliceStringX(yyv74, false, d) + z.F.DecSliceStringX(yyv32, false, d) } } case "clusterName": if r.TryDecodeAsNil() { x.ClusterName = "" } else { - x.ClusterName = string(r.DecodeString()) + yyv34 := &x.ClusterName + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys54) - } // end switch yys54 - } // end for yyj54 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -791,16 +893,16 @@ 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 + var yyj36 int + var yyb36 bool + var yyhl36 bool = l >= 0 + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -808,15 +910,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv37 := &x.Name + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -824,15 +932,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.GenerateName = "" } else { - x.GenerateName = string(r.DecodeString()) + yyv39 := &x.GenerateName + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -840,15 +954,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv41 := &x.Namespace + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*string)(yyv41)) = r.DecodeString() + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -856,15 +976,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.SelfLink = "" } else { - x.SelfLink = string(r.DecodeString()) + yyv43 := &x.SelfLink + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*string)(yyv43)) = r.DecodeString() + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -872,15 +998,22 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.UID = "" } else { - x.UID = pkg1_types.UID(r.DecodeString()) + yyv45 := &x.UID + yym46 := z.DecBinary() + _ = yym46 + if false { + } else if z.HasExtensions() && z.DecExt(yyv45) { + } else { + *((*string)(yyv45)) = r.DecodeString() + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -888,15 +1021,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ResourceVersion = "" } else { - x.ResourceVersion = string(r.DecodeString()) + yyv47 := &x.ResourceVersion + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + *((*string)(yyv47)) = r.DecodeString() + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -904,42 +1043,48 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Generation = 0 } else { - x.Generation = int64(r.DecodeInt(64)) + yyv49 := &x.Generation + yym50 := z.DecBinary() + _ = yym50 + if false { + } else { + *((*int64)(yyv49)) = int64(r.DecodeInt(64)) + } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg2_unversioned.Time{} + x.CreationTimestamp = pkg2_v1.Time{} } else { - yyv85 := &x.CreationTimestamp - yym86 := z.DecBinary() - _ = yym86 + yyv51 := &x.CreationTimestamp + yym52 := z.DecBinary() + _ = yym52 if false { - } else if z.HasExtensions() && z.DecExt(yyv85) { - } else if yym86 { - z.DecBinaryUnmarshal(yyv85) - } else if !yym86 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv85) + } else if z.HasExtensions() && z.DecExt(yyv51) { + } else if yym52 { + z.DecBinaryUnmarshal(yyv51) + } else if !yym52 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv51) } else { - z.DecFallback(yyv85, false) + z.DecFallback(yyv51, false) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -950,27 +1095,27 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg2_unversioned.Time) + x.DeletionTimestamp = new(pkg2_v1.Time) } - yym88 := z.DecBinary() - _ = yym88 + yym54 := z.DecBinary() + _ = yym54 if false { } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym88 { + } else if yym54 { z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym88 && z.IsJSONHandle() { + } else if !yym54 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.DeletionTimestamp) } else { z.DecFallback(x.DeletionTimestamp, false) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -983,20 +1128,20 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.DeletionGracePeriodSeconds == nil { x.DeletionGracePeriodSeconds = new(int64) } - yym90 := z.DecBinary() - _ = yym90 + yym56 := z.DecBinary() + _ = yym56 if false { } else { *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1004,21 +1149,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Labels = nil } else { - yyv91 := &x.Labels - yym92 := z.DecBinary() - _ = yym92 + yyv57 := &x.Labels + yym58 := z.DecBinary() + _ = yym58 if false { } else { - z.F.DecMapStringStringX(yyv91, false, d) + z.F.DecMapStringStringX(yyv57, false, d) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1026,21 +1171,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Annotations = nil } else { - yyv93 := &x.Annotations - yym94 := z.DecBinary() - _ = yym94 + yyv59 := &x.Annotations + yym60 := z.DecBinary() + _ = yym60 if false { } else { - z.F.DecMapStringStringX(yyv93, false, d) + z.F.DecMapStringStringX(yyv59, false, d) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1048,21 +1193,48 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.OwnerReferences = nil } else { - yyv95 := &x.OwnerReferences - yym96 := z.DecBinary() - _ = yym96 + yyv61 := &x.OwnerReferences + yym62 := z.DecBinary() + _ = yym62 + if false { + } else { + h.decSlicev1_OwnerReference((*[]pkg2_v1.OwnerReference)(yyv61), d) + } + } + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l + } else { + yyb36 = r.CheckBreak() + } + if yyb36 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Initializers != nil { + x.Initializers = nil + } + } else { + if x.Initializers == nil { + x.Initializers = new(pkg2_v1.Initializers) + } + yym64 := z.DecBinary() + _ = yym64 if false { + } else if z.HasExtensions() && z.DecExt(x.Initializers) { } else { - h.decSliceOwnerReference((*[]OwnerReference)(yyv95), d) + z.DecFallback(x.Initializers, false) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1070,21 +1242,21 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Finalizers = nil } else { - yyv97 := &x.Finalizers - yym98 := z.DecBinary() - _ = yym98 + yyv65 := &x.Finalizers + yym66 := z.DecBinary() + _ = yym66 if false { } else { - z.F.DecSliceStringX(yyv97, false, d) + z.F.DecSliceStringX(yyv65, false, d) } } - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1092,20 +1264,26 @@ func (x *ObjectMeta) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ClusterName = "" } else { - x.ClusterName = string(r.DecodeString()) + yyv67 := &x.ClusterName + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*string)(yyv67)) = r.DecodeString() + } } for { - yyj77++ - if yyhl77 { - yyb77 = yyj77 > l + yyj36++ + if yyhl36 { + yyb36 = yyj36 > l } else { - yyb77 = r.CheckBreak() + yyb36 = r.CheckBreak() } - if yyb77 { + if yyb36 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj77-1, "") + z.DecStructFieldNotFound(yyj36-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1117,56 +1295,60 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym100 := z.EncBinary() - _ = yym100 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep101 := !z.EncBinary() - yy2arr101 := z.EncBasicHandle().StructToArray - var yyq101 [24]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 - yyq101[23] = x.VolumeSource.PhotonPersistentDisk != nil && x.PhotonPersistentDisk != nil - var yynn101 int - if yyr101 || yy2arr101 { - r.EncodeArrayStart(24) - } else { - yynn101 = 1 - for _, b := range yyq101 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [28]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.VolumeSource.HostPath != nil && x.HostPath != nil + yyq2[2] = x.VolumeSource.EmptyDir != nil && x.EmptyDir != nil + yyq2[3] = x.VolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil + yyq2[4] = x.VolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil + yyq2[5] = x.VolumeSource.GitRepo != nil && x.GitRepo != nil + yyq2[6] = x.VolumeSource.Secret != nil && x.Secret != nil + yyq2[7] = x.VolumeSource.NFS != nil && x.NFS != nil + yyq2[8] = x.VolumeSource.ISCSI != nil && x.ISCSI != nil + yyq2[9] = x.VolumeSource.Glusterfs != nil && x.Glusterfs != nil + yyq2[10] = x.VolumeSource.PersistentVolumeClaim != nil && x.PersistentVolumeClaim != nil + yyq2[11] = x.VolumeSource.RBD != nil && x.RBD != nil + yyq2[12] = x.VolumeSource.FlexVolume != nil && x.FlexVolume != nil + yyq2[13] = x.VolumeSource.Cinder != nil && x.Cinder != nil + yyq2[14] = x.VolumeSource.CephFS != nil && x.CephFS != nil + yyq2[15] = x.VolumeSource.Flocker != nil && x.Flocker != nil + yyq2[16] = x.VolumeSource.DownwardAPI != nil && x.DownwardAPI != nil + yyq2[17] = x.VolumeSource.FC != nil && x.FC != nil + yyq2[18] = x.VolumeSource.AzureFile != nil && x.AzureFile != nil + yyq2[19] = x.VolumeSource.ConfigMap != nil && x.ConfigMap != nil + yyq2[20] = x.VolumeSource.VsphereVolume != nil && x.VsphereVolume != nil + yyq2[21] = x.VolumeSource.Quobyte != nil && x.Quobyte != nil + yyq2[22] = x.VolumeSource.AzureDisk != nil && x.AzureDisk != nil + yyq2[23] = x.VolumeSource.PhotonPersistentDisk != nil && x.PhotonPersistentDisk != nil + yyq2[24] = x.VolumeSource.Projected != nil && x.Projected != nil + yyq2[25] = x.VolumeSource.PortworxVolume != nil && x.PortworxVolume != nil + yyq2[26] = x.VolumeSource.ScaleIO != nil && x.ScaleIO != nil + yyq2[27] = x.VolumeSource.StorageOS != nil && x.StorageOS != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(28) + } else { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn101++ + yynn2++ } } - r.EncodeMapStart(yynn101) - yynn101 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr101 || yy2arr101 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym103 := z.EncBinary() - _ = yym103 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -1175,25 +1357,25 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym104 := z.EncBinary() - _ = yym104 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - var yyn105 bool + var yyn6 bool if x.VolumeSource.HostPath == nil { - yyn105 = true - goto LABEL105 + yyn6 = true + goto LABEL6 } - LABEL105: - if yyr101 || yy2arr101 { - if yyn105 { + LABEL6: + if yyr2 || yy2arr2 { + if yyn6 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[1] { + if yyq2[1] { if x.HostPath == nil { r.EncodeNil() } else { @@ -1204,11 +1386,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn105 { + if yyn6 { r.EncodeNil() } else { if x.HostPath == nil { @@ -1219,18 +1401,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn106 bool + var yyn9 bool if x.VolumeSource.EmptyDir == nil { - yyn106 = true - goto LABEL106 + yyn9 = true + goto LABEL9 } - LABEL106: - if yyr101 || yy2arr101 { - if yyn106 { + LABEL9: + if yyr2 || yy2arr2 { + if yyn9 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[2] { + if yyq2[2] { if x.EmptyDir == nil { r.EncodeNil() } else { @@ -1241,11 +1423,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("emptyDir")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn106 { + if yyn9 { r.EncodeNil() } else { if x.EmptyDir == nil { @@ -1256,18 +1438,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn107 bool + var yyn12 bool if x.VolumeSource.GCEPersistentDisk == nil { - yyn107 = true - goto LABEL107 + yyn12 = true + goto LABEL12 } - LABEL107: - if yyr101 || yy2arr101 { - if yyn107 { + LABEL12: + if yyr2 || yy2arr2 { + if yyn12 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[3] { + if yyq2[3] { if x.GCEPersistentDisk == nil { r.EncodeNil() } else { @@ -1278,11 +1460,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn107 { + if yyn12 { r.EncodeNil() } else { if x.GCEPersistentDisk == nil { @@ -1293,18 +1475,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn108 bool + var yyn15 bool if x.VolumeSource.AWSElasticBlockStore == nil { - yyn108 = true - goto LABEL108 + yyn15 = true + goto LABEL15 } - LABEL108: - if yyr101 || yy2arr101 { - if yyn108 { + LABEL15: + if yyr2 || yy2arr2 { + if yyn15 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[4] { + if yyq2[4] { if x.AWSElasticBlockStore == nil { r.EncodeNil() } else { @@ -1315,11 +1497,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn108 { + if yyn15 { r.EncodeNil() } else { if x.AWSElasticBlockStore == nil { @@ -1330,18 +1512,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn109 bool + var yyn18 bool if x.VolumeSource.GitRepo == nil { - yyn109 = true - goto LABEL109 + yyn18 = true + goto LABEL18 } - LABEL109: - if yyr101 || yy2arr101 { - if yyn109 { + LABEL18: + if yyr2 || yy2arr2 { + if yyn18 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[5] { + if yyq2[5] { if x.GitRepo == nil { r.EncodeNil() } else { @@ -1352,11 +1534,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gitRepo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn109 { + if yyn18 { r.EncodeNil() } else { if x.GitRepo == nil { @@ -1367,18 +1549,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn110 bool + var yyn21 bool if x.VolumeSource.Secret == nil { - yyn110 = true - goto LABEL110 + yyn21 = true + goto LABEL21 } - LABEL110: - if yyr101 || yy2arr101 { - if yyn110 { + LABEL21: + if yyr2 || yy2arr2 { + if yyn21 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[6] { + if yyq2[6] { if x.Secret == nil { r.EncodeNil() } else { @@ -1389,11 +1571,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secret")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn110 { + if yyn21 { r.EncodeNil() } else { if x.Secret == nil { @@ -1404,18 +1586,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn111 bool + var yyn24 bool if x.VolumeSource.NFS == nil { - yyn111 = true - goto LABEL111 + yyn24 = true + goto LABEL24 } - LABEL111: - if yyr101 || yy2arr101 { - if yyn111 { + LABEL24: + if yyr2 || yy2arr2 { + if yyn24 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[7] { + if yyq2[7] { if x.NFS == nil { r.EncodeNil() } else { @@ -1426,11 +1608,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn111 { + if yyn24 { r.EncodeNil() } else { if x.NFS == nil { @@ -1441,18 +1623,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn112 bool + var yyn27 bool if x.VolumeSource.ISCSI == nil { - yyn112 = true - goto LABEL112 + yyn27 = true + goto LABEL27 } - LABEL112: - if yyr101 || yy2arr101 { - if yyn112 { + LABEL27: + if yyr2 || yy2arr2 { + if yyn27 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[8] { + if yyq2[8] { if x.ISCSI == nil { r.EncodeNil() } else { @@ -1463,11 +1645,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("iscsi")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn112 { + if yyn27 { r.EncodeNil() } else { if x.ISCSI == nil { @@ -1478,18 +1660,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn113 bool + var yyn30 bool if x.VolumeSource.Glusterfs == nil { - yyn113 = true - goto LABEL113 + yyn30 = true + goto LABEL30 } - LABEL113: - if yyr101 || yy2arr101 { - if yyn113 { + LABEL30: + if yyr2 || yy2arr2 { + if yyn30 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[9] { + if yyq2[9] { if x.Glusterfs == nil { r.EncodeNil() } else { @@ -1500,11 +1682,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn113 { + if yyn30 { r.EncodeNil() } else { if x.Glusterfs == nil { @@ -1515,18 +1697,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn114 bool + var yyn33 bool if x.VolumeSource.PersistentVolumeClaim == nil { - yyn114 = true - goto LABEL114 + yyn33 = true + goto LABEL33 } - LABEL114: - if yyr101 || yy2arr101 { - if yyn114 { + LABEL33: + if yyr2 || yy2arr2 { + if yyn33 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[10] { + if yyq2[10] { if x.PersistentVolumeClaim == nil { r.EncodeNil() } else { @@ -1537,11 +1719,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[10] { + if yyq2[10] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeClaim")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn114 { + if yyn33 { r.EncodeNil() } else { if x.PersistentVolumeClaim == nil { @@ -1552,18 +1734,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn115 bool + var yyn36 bool if x.VolumeSource.RBD == nil { - yyn115 = true - goto LABEL115 + yyn36 = true + goto LABEL36 } - LABEL115: - if yyr101 || yy2arr101 { - if yyn115 { + LABEL36: + if yyr2 || yy2arr2 { + if yyn36 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[11] { + if yyq2[11] { if x.RBD == nil { r.EncodeNil() } else { @@ -1574,11 +1756,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[11] { + if yyq2[11] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rbd")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn115 { + if yyn36 { r.EncodeNil() } else { if x.RBD == nil { @@ -1589,18 +1771,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn116 bool + var yyn39 bool if x.VolumeSource.FlexVolume == nil { - yyn116 = true - goto LABEL116 + yyn39 = true + goto LABEL39 } - LABEL116: - if yyr101 || yy2arr101 { - if yyn116 { + LABEL39: + if yyr2 || yy2arr2 { + if yyn39 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[12] { + if yyq2[12] { if x.FlexVolume == nil { r.EncodeNil() } else { @@ -1611,11 +1793,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[12] { + if yyq2[12] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn116 { + if yyn39 { r.EncodeNil() } else { if x.FlexVolume == nil { @@ -1626,18 +1808,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn117 bool + var yyn42 bool if x.VolumeSource.Cinder == nil { - yyn117 = true - goto LABEL117 + yyn42 = true + goto LABEL42 } - LABEL117: - if yyr101 || yy2arr101 { - if yyn117 { + LABEL42: + if yyr2 || yy2arr2 { + if yyn42 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[13] { + if yyq2[13] { if x.Cinder == nil { r.EncodeNil() } else { @@ -1648,11 +1830,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[13] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cinder")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn117 { + if yyn42 { r.EncodeNil() } else { if x.Cinder == nil { @@ -1663,18 +1845,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn118 bool + var yyn45 bool if x.VolumeSource.CephFS == nil { - yyn118 = true - goto LABEL118 + yyn45 = true + goto LABEL45 } - LABEL118: - if yyr101 || yy2arr101 { - if yyn118 { + LABEL45: + if yyr2 || yy2arr2 { + if yyn45 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[14] { + if yyq2[14] { if x.CephFS == nil { r.EncodeNil() } else { @@ -1685,11 +1867,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[14] { + if yyq2[14] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cephfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn118 { + if yyn45 { r.EncodeNil() } else { if x.CephFS == nil { @@ -1700,18 +1882,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn119 bool + var yyn48 bool if x.VolumeSource.Flocker == nil { - yyn119 = true - goto LABEL119 + yyn48 = true + goto LABEL48 } - LABEL119: - if yyr101 || yy2arr101 { - if yyn119 { + LABEL48: + if yyr2 || yy2arr2 { + if yyn48 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[15] { + if yyq2[15] { if x.Flocker == nil { r.EncodeNil() } else { @@ -1722,11 +1904,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[15] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flocker")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn119 { + if yyn48 { r.EncodeNil() } else { if x.Flocker == nil { @@ -1737,18 +1919,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn120 bool + var yyn51 bool if x.VolumeSource.DownwardAPI == nil { - yyn120 = true - goto LABEL120 + yyn51 = true + goto LABEL51 } - LABEL120: - if yyr101 || yy2arr101 { - if yyn120 { + LABEL51: + if yyr2 || yy2arr2 { + if yyn51 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[16] { + if yyq2[16] { if x.DownwardAPI == nil { r.EncodeNil() } else { @@ -1759,11 +1941,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[16] { + if yyq2[16] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("downwardAPI")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn120 { + if yyn51 { r.EncodeNil() } else { if x.DownwardAPI == nil { @@ -1774,18 +1956,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn121 bool + var yyn54 bool if x.VolumeSource.FC == nil { - yyn121 = true - goto LABEL121 + yyn54 = true + goto LABEL54 } - LABEL121: - if yyr101 || yy2arr101 { - if yyn121 { + LABEL54: + if yyr2 || yy2arr2 { + if yyn54 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[17] { + if yyq2[17] { if x.FC == nil { r.EncodeNil() } else { @@ -1796,11 +1978,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[17] { + if yyq2[17] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fc")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn121 { + if yyn54 { r.EncodeNil() } else { if x.FC == nil { @@ -1811,18 +1993,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn122 bool + var yyn57 bool if x.VolumeSource.AzureFile == nil { - yyn122 = true - goto LABEL122 + yyn57 = true + goto LABEL57 } - LABEL122: - if yyr101 || yy2arr101 { - if yyn122 { + LABEL57: + if yyr2 || yy2arr2 { + if yyn57 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[18] { + if yyq2[18] { if x.AzureFile == nil { r.EncodeNil() } else { @@ -1833,11 +2015,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[18] { + if yyq2[18] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureFile")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn122 { + if yyn57 { r.EncodeNil() } else { if x.AzureFile == nil { @@ -1848,18 +2030,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn123 bool + var yyn60 bool if x.VolumeSource.ConfigMap == nil { - yyn123 = true - goto LABEL123 + yyn60 = true + goto LABEL60 } - LABEL123: - if yyr101 || yy2arr101 { - if yyn123 { + LABEL60: + if yyr2 || yy2arr2 { + if yyn60 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[19] { + if yyq2[19] { if x.ConfigMap == nil { r.EncodeNil() } else { @@ -1870,11 +2052,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[19] { + if yyq2[19] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("configMap")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn123 { + if yyn60 { r.EncodeNil() } else { if x.ConfigMap == nil { @@ -1885,18 +2067,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn124 bool + var yyn63 bool if x.VolumeSource.VsphereVolume == nil { - yyn124 = true - goto LABEL124 + yyn63 = true + goto LABEL63 } - LABEL124: - if yyr101 || yy2arr101 { - if yyn124 { + LABEL63: + if yyr2 || yy2arr2 { + if yyn63 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[20] { + if yyq2[20] { if x.VsphereVolume == nil { r.EncodeNil() } else { @@ -1907,11 +2089,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[20] { + if yyq2[20] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn124 { + if yyn63 { r.EncodeNil() } else { if x.VsphereVolume == nil { @@ -1922,18 +2104,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn125 bool + var yyn66 bool if x.VolumeSource.Quobyte == nil { - yyn125 = true - goto LABEL125 + yyn66 = true + goto LABEL66 } - LABEL125: - if yyr101 || yy2arr101 { - if yyn125 { + LABEL66: + if yyr2 || yy2arr2 { + if yyn66 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[21] { + if yyq2[21] { if x.Quobyte == nil { r.EncodeNil() } else { @@ -1944,11 +2126,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[21] { + if yyq2[21] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("quobyte")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn125 { + if yyn66 { r.EncodeNil() } else { if x.Quobyte == nil { @@ -1959,18 +2141,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn126 bool + var yyn69 bool if x.VolumeSource.AzureDisk == nil { - yyn126 = true - goto LABEL126 + yyn69 = true + goto LABEL69 } - LABEL126: - if yyr101 || yy2arr101 { - if yyn126 { + LABEL69: + if yyr2 || yy2arr2 { + if yyn69 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[22] { + if yyq2[22] { if x.AzureDisk == nil { r.EncodeNil() } else { @@ -1981,11 +2163,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[22] { + if yyq2[22] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn126 { + if yyn69 { r.EncodeNil() } else { if x.AzureDisk == nil { @@ -1996,18 +2178,18 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn127 bool + var yyn72 bool if x.VolumeSource.PhotonPersistentDisk == nil { - yyn127 = true - goto LABEL127 + yyn72 = true + goto LABEL72 } - LABEL127: - if yyr101 || yy2arr101 { - if yyn127 { + LABEL72: + if yyr2 || yy2arr2 { + if yyn72 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq101[23] { + if yyq2[23] { if x.PhotonPersistentDisk == nil { r.EncodeNil() } else { @@ -2018,11 +2200,11 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq101[23] { + if yyq2[23] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn127 { + if yyn72 { r.EncodeNil() } else { if x.PhotonPersistentDisk == nil { @@ -2033,7 +2215,155 @@ func (x *Volume) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr101 || yy2arr101 { + var yyn75 bool + if x.VolumeSource.Projected == nil { + yyn75 = true + goto LABEL75 + } + LABEL75: + if yyr2 || yy2arr2 { + if yyn75 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[24] { + if x.Projected == nil { + r.EncodeNil() + } else { + x.Projected.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[24] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("projected")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn75 { + r.EncodeNil() + } else { + if x.Projected == nil { + r.EncodeNil() + } else { + x.Projected.CodecEncodeSelf(e) + } + } + } + } + var yyn78 bool + if x.VolumeSource.PortworxVolume == nil { + yyn78 = true + goto LABEL78 + } + LABEL78: + if yyr2 || yy2arr2 { + if yyn78 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[25] { + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[25] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("portworxVolume")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn78 { + r.EncodeNil() + } else { + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } + } + } + var yyn81 bool + if x.VolumeSource.ScaleIO == nil { + yyn81 = true + goto LABEL81 + } + LABEL81: + if yyr2 || yy2arr2 { + if yyn81 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[26] { + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[26] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("scaleIO")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn81 { + r.EncodeNil() + } else { + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } + } + } + var yyn84 bool + if x.VolumeSource.StorageOS == nil { + yyn84 = true + goto LABEL84 + } + LABEL84: + if yyr2 || yy2arr2 { + if yyn84 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[27] { + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[27] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageos")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn84 { + r.EncodeNil() + } else { + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2046,25 +2376,25 @@ func (x *Volume) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym128 := z.DecBinary() - _ = yym128 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct129 := r.ContainerType() - if yyct129 == codecSelferValueTypeMap1234 { - yyl129 := r.ReadMapStart() - if yyl129 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl129, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct129 == codecSelferValueTypeArray1234 { - yyl129 := r.ReadArrayStart() - if yyl129 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl129, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2076,12 +2406,12 @@ func (x *Volume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys130Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys130Slc - var yyhl130 bool = l >= 0 - for yyj130 := 0; ; yyj130++ { - if yyhl130 { - if yyj130 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2090,15 +2420,21 @@ func (x *Volume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys130Slc = r.DecodeBytes(yys130Slc, true, true) - yys130 := string(yys130Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys130 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "hostPath": if x.VolumeSource.HostPath == nil { @@ -2422,10 +2758,66 @@ func (x *Volume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + case "projected": + if x.VolumeSource.Projected == nil { + x.VolumeSource.Projected = new(ProjectedVolumeSource) + } + if r.TryDecodeAsNil() { + if x.Projected != nil { + x.Projected = nil + } + } else { + if x.Projected == nil { + x.Projected = new(ProjectedVolumeSource) + } + x.Projected.CodecDecodeSelf(d) + } + case "portworxVolume": + if x.VolumeSource.PortworxVolume == nil { + x.VolumeSource.PortworxVolume = new(PortworxVolumeSource) + } + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + case "scaleIO": + if x.VolumeSource.ScaleIO == nil { + x.VolumeSource.ScaleIO = new(ScaleIOVolumeSource) + } + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + case "storageos": + if x.VolumeSource.StorageOS == nil { + x.VolumeSource.StorageOS = new(StorageOSVolumeSource) + } + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } default: - z.DecStructFieldNotFound(-1, yys130) - } // end switch yys130 - } // end for yyj130 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2433,16 +2825,16 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj155 int - var yyb155 bool - var yyhl155 bool = l >= 0 - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + var yyj33 int + var yyb33 bool + var yyhl33 bool = l >= 0 + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2450,18 +2842,24 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv34 := &x.Name + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } } if x.VolumeSource.HostPath == nil { x.VolumeSource.HostPath = new(HostPathVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2479,13 +2877,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.EmptyDir == nil { x.VolumeSource.EmptyDir = new(EmptyDirVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2503,13 +2901,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.GCEPersistentDisk == nil { x.VolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2527,13 +2925,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.AWSElasticBlockStore == nil { x.VolumeSource.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2551,13 +2949,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.GitRepo == nil { x.VolumeSource.GitRepo = new(GitRepoVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2575,13 +2973,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.Secret == nil { x.VolumeSource.Secret = new(SecretVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2599,13 +2997,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.NFS == nil { x.VolumeSource.NFS = new(NFSVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2623,13 +3021,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.ISCSI == nil { x.VolumeSource.ISCSI = new(ISCSIVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2647,13 +3045,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.Glusterfs == nil { x.VolumeSource.Glusterfs = new(GlusterfsVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2671,13 +3069,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.PersistentVolumeClaim == nil { x.VolumeSource.PersistentVolumeClaim = new(PersistentVolumeClaimVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2695,13 +3093,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.RBD == nil { x.VolumeSource.RBD = new(RBDVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2719,13 +3117,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.FlexVolume == nil { x.VolumeSource.FlexVolume = new(FlexVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2743,13 +3141,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.Cinder == nil { x.VolumeSource.Cinder = new(CinderVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2767,13 +3165,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.CephFS == nil { x.VolumeSource.CephFS = new(CephFSVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2791,13 +3189,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.Flocker == nil { x.VolumeSource.Flocker = new(FlockerVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2815,13 +3213,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.DownwardAPI == nil { x.VolumeSource.DownwardAPI = new(DownwardAPIVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2839,13 +3237,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.FC == nil { x.VolumeSource.FC = new(FCVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2863,13 +3261,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.AzureFile == nil { x.VolumeSource.AzureFile = new(AzureFileVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2887,13 +3285,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.ConfigMap == nil { x.VolumeSource.ConfigMap = new(ConfigMapVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2911,13 +3309,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.VsphereVolume == nil { x.VolumeSource.VsphereVolume = new(VsphereVirtualDiskVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2935,13 +3333,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.Quobyte == nil { x.VolumeSource.Quobyte = new(QuobyteVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2959,13 +3357,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.AzureDisk == nil { x.VolumeSource.AzureDisk = new(AzureDiskVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2983,13 +3381,13 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.VolumeSource.PhotonPersistentDisk == nil { x.VolumeSource.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) } - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3004,18 +3402,114 @@ func (x *Volume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + if x.VolumeSource.Projected == nil { + x.VolumeSource.Projected = new(ProjectedVolumeSource) + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Projected != nil { + x.Projected = nil + } + } else { + if x.Projected == nil { + x.Projected = new(ProjectedVolumeSource) + } + x.Projected.CodecDecodeSelf(d) + } + if x.VolumeSource.PortworxVolume == nil { + x.VolumeSource.PortworxVolume = new(PortworxVolumeSource) + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + if x.VolumeSource.ScaleIO == nil { + x.VolumeSource.ScaleIO = new(ScaleIOVolumeSource) + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + if x.VolumeSource.StorageOS == nil { + x.VolumeSource.StorageOS = new(StorageOSVolumeSource) + } + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l + } else { + yyb33 = r.CheckBreak() + } + if yyb33 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } for { - yyj155++ - if yyhl155 { - yyb155 = yyj155 > l + yyj33++ + if yyhl33 { + yyb33 = yyj33 > l } else { - yyb155 = r.CheckBreak() + yyb33 = r.CheckBreak() } - if yyb155 { + if yyb33 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj155-1, "") + z.DecStructFieldNotFound(yyj33-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3027,55 +3521,59 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym180 := z.EncBinary() - _ = yym180 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep181 := !z.EncBinary() - yy2arr181 := z.EncBasicHandle().StructToArray - var yyq181 [23]bool - _, _, _ = yysep181, yyq181, yy2arr181 - const yyr181 bool = false - yyq181[0] = x.HostPath != nil - yyq181[1] = x.EmptyDir != nil - yyq181[2] = x.GCEPersistentDisk != nil - yyq181[3] = x.AWSElasticBlockStore != nil - yyq181[4] = x.GitRepo != nil - yyq181[5] = x.Secret != nil - yyq181[6] = x.NFS != nil - yyq181[7] = x.ISCSI != nil - yyq181[8] = x.Glusterfs != nil - yyq181[9] = x.PersistentVolumeClaim != nil - yyq181[10] = x.RBD != nil - yyq181[11] = x.FlexVolume != nil - yyq181[12] = x.Cinder != nil - yyq181[13] = x.CephFS != nil - yyq181[14] = x.Flocker != nil - yyq181[15] = x.DownwardAPI != nil - yyq181[16] = x.FC != nil - yyq181[17] = x.AzureFile != nil - yyq181[18] = x.ConfigMap != nil - yyq181[19] = x.VsphereVolume != nil - yyq181[20] = x.Quobyte != nil - yyq181[21] = x.AzureDisk != nil - yyq181[22] = x.PhotonPersistentDisk != nil - var yynn181 int - if yyr181 || yy2arr181 { - r.EncodeArrayStart(23) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [27]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.HostPath != nil + yyq2[1] = x.EmptyDir != nil + yyq2[2] = x.GCEPersistentDisk != nil + yyq2[3] = x.AWSElasticBlockStore != nil + yyq2[4] = x.GitRepo != nil + yyq2[5] = x.Secret != nil + yyq2[6] = x.NFS != nil + yyq2[7] = x.ISCSI != nil + yyq2[8] = x.Glusterfs != nil + yyq2[9] = x.PersistentVolumeClaim != nil + yyq2[10] = x.RBD != nil + yyq2[11] = x.FlexVolume != nil + yyq2[12] = x.Cinder != nil + yyq2[13] = x.CephFS != nil + yyq2[14] = x.Flocker != nil + yyq2[15] = x.DownwardAPI != nil + yyq2[16] = x.FC != nil + yyq2[17] = x.AzureFile != nil + yyq2[18] = x.ConfigMap != nil + yyq2[19] = x.VsphereVolume != nil + yyq2[20] = x.Quobyte != nil + yyq2[21] = x.AzureDisk != nil + yyq2[22] = x.PhotonPersistentDisk != nil + yyq2[23] = x.Projected != nil + yyq2[24] = x.PortworxVolume != nil + yyq2[25] = x.ScaleIO != nil + yyq2[26] = x.StorageOS != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(27) } else { - yynn181 = 0 - for _, b := range yyq181 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn181++ + yynn2++ } } - r.EncodeMapStart(yynn181) - yynn181 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[0] { + if yyq2[0] { if x.HostPath == nil { r.EncodeNil() } else { @@ -3085,7 +3583,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3096,9 +3594,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[1] { + if yyq2[1] { if x.EmptyDir == nil { r.EncodeNil() } else { @@ -3108,7 +3606,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("emptyDir")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3119,9 +3617,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[2] { + if yyq2[2] { if x.GCEPersistentDisk == nil { r.EncodeNil() } else { @@ -3131,7 +3629,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3142,9 +3640,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[3] { + if yyq2[3] { if x.AWSElasticBlockStore == nil { r.EncodeNil() } else { @@ -3154,7 +3652,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3165,9 +3663,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[4] { + if yyq2[4] { if x.GitRepo == nil { r.EncodeNil() } else { @@ -3177,7 +3675,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gitRepo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3188,9 +3686,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[5] { + if yyq2[5] { if x.Secret == nil { r.EncodeNil() } else { @@ -3200,7 +3698,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secret")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3211,9 +3709,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[6] { + if yyq2[6] { if x.NFS == nil { r.EncodeNil() } else { @@ -3223,7 +3721,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3234,9 +3732,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[7] { + if yyq2[7] { if x.ISCSI == nil { r.EncodeNil() } else { @@ -3246,7 +3744,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("iscsi")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3257,9 +3755,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[8] { + if yyq2[8] { if x.Glusterfs == nil { r.EncodeNil() } else { @@ -3269,7 +3767,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3280,9 +3778,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[9] { + if yyq2[9] { if x.PersistentVolumeClaim == nil { r.EncodeNil() } else { @@ -3292,7 +3790,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeClaim")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3303,9 +3801,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[10] { + if yyq2[10] { if x.RBD == nil { r.EncodeNil() } else { @@ -3315,7 +3813,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[10] { + if yyq2[10] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rbd")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3326,9 +3824,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[11] { + if yyq2[11] { if x.FlexVolume == nil { r.EncodeNil() } else { @@ -3338,7 +3836,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[11] { + if yyq2[11] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3349,9 +3847,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[12] { + if yyq2[12] { if x.Cinder == nil { r.EncodeNil() } else { @@ -3361,7 +3859,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[12] { + if yyq2[12] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cinder")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3372,9 +3870,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[13] { + if yyq2[13] { if x.CephFS == nil { r.EncodeNil() } else { @@ -3384,7 +3882,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[13] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cephfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3395,9 +3893,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[14] { + if yyq2[14] { if x.Flocker == nil { r.EncodeNil() } else { @@ -3407,7 +3905,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[14] { + if yyq2[14] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flocker")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3418,9 +3916,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[15] { + if yyq2[15] { if x.DownwardAPI == nil { r.EncodeNil() } else { @@ -3430,7 +3928,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[15] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("downwardAPI")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3441,9 +3939,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[16] { + if yyq2[16] { if x.FC == nil { r.EncodeNil() } else { @@ -3453,7 +3951,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[16] { + if yyq2[16] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fc")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3464,9 +3962,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[17] { + if yyq2[17] { if x.AzureFile == nil { r.EncodeNil() } else { @@ -3476,7 +3974,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[17] { + if yyq2[17] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureFile")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3487,9 +3985,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[18] { + if yyq2[18] { if x.ConfigMap == nil { r.EncodeNil() } else { @@ -3499,7 +3997,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[18] { + if yyq2[18] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("configMap")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3510,9 +4008,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[19] { + if yyq2[19] { if x.VsphereVolume == nil { r.EncodeNil() } else { @@ -3522,7 +4020,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[19] { + if yyq2[19] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3533,9 +4031,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[20] { + if yyq2[20] { if x.Quobyte == nil { r.EncodeNil() } else { @@ -3545,7 +4043,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[20] { + if yyq2[20] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("quobyte")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3556,9 +4054,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[21] { + if yyq2[21] { if x.AzureDisk == nil { r.EncodeNil() } else { @@ -3568,7 +4066,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[21] { + if yyq2[21] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3579,9 +4077,9 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq181[22] { + if yyq2[22] { if x.PhotonPersistentDisk == nil { r.EncodeNil() } else { @@ -3591,7 +4089,7 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq181[22] { + if yyq2[22] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -3602,7 +4100,99 @@ func (x *VolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr181 || yy2arr181 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[23] { + if x.Projected == nil { + r.EncodeNil() + } else { + x.Projected.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[23] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("projected")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Projected == nil { + r.EncodeNil() + } else { + x.Projected.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[24] { + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[24] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("portworxVolume")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[25] { + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[25] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("scaleIO")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[26] { + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[26] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageos")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -3615,25 +4205,25 @@ func (x *VolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym205 := z.DecBinary() - _ = yym205 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct206 := r.ContainerType() - if yyct206 == codecSelferValueTypeMap1234 { - yyl206 := r.ReadMapStart() - if yyl206 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl206, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct206 == codecSelferValueTypeArray1234 { - yyl206 := r.ReadArrayStart() - if yyl206 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl206, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3645,12 +4235,12 @@ func (x *VolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys207Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys207Slc - var yyhl207 bool = l >= 0 - for yyj207 := 0; ; yyj207++ { - if yyhl207 { - if yyj207 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3659,10 +4249,10 @@ func (x *VolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys207Slc = r.DecodeBytes(yys207Slc, true, true) - yys207 := string(yys207Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys207 { + switch yys3 { case "hostPath": if r.TryDecodeAsNil() { if x.HostPath != nil { @@ -3916,10 +4506,54 @@ func (x *VolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + case "projected": + if r.TryDecodeAsNil() { + if x.Projected != nil { + x.Projected = nil + } + } else { + if x.Projected == nil { + x.Projected = new(ProjectedVolumeSource) + } + x.Projected.CodecDecodeSelf(d) + } + case "portworxVolume": + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + case "scaleIO": + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + case "storageos": + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } default: - z.DecStructFieldNotFound(-1, yys207) - } // end switch yys207 - } // end for yyj207 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3927,16 +4561,16 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj231 int - var yyb231 bool - var yyhl231 bool = l >= 0 - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + var yyj31 int + var yyb31 bool + var yyhl31 bool = l >= 0 + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3951,13 +4585,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.HostPath.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3972,13 +4606,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.EmptyDir.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3993,13 +4627,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.GCEPersistentDisk.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4014,13 +4648,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.AWSElasticBlockStore.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4035,13 +4669,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.GitRepo.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4056,13 +4690,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Secret.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4077,13 +4711,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.NFS.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4098,13 +4732,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.ISCSI.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4119,13 +4753,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Glusterfs.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4140,13 +4774,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.PersistentVolumeClaim.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4161,13 +4795,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.RBD.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4182,13 +4816,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.FlexVolume.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4203,13 +4837,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Cinder.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4224,13 +4858,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.CephFS.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4245,13 +4879,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Flocker.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4266,13 +4900,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.DownwardAPI.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4287,13 +4921,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.FC.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4308,13 +4942,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.AzureFile.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4329,13 +4963,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.ConfigMap.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4350,13 +4984,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.VsphereVolume.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4371,13 +5005,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Quobyte.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4392,13 +5026,13 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.AzureDisk.CodecDecodeSelf(d) } - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4413,18 +5047,102 @@ func (x *VolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l + } else { + yyb31 = r.CheckBreak() + } + if yyb31 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Projected != nil { + x.Projected = nil + } + } else { + if x.Projected == nil { + x.Projected = new(ProjectedVolumeSource) + } + x.Projected.CodecDecodeSelf(d) + } + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l + } else { + yyb31 = r.CheckBreak() + } + if yyb31 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l + } else { + yyb31 = r.CheckBreak() + } + if yyb31 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l + } else { + yyb31 = r.CheckBreak() + } + if yyb31 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } for { - yyj231++ - if yyhl231 { - yyb231 = yyj231 > l + yyj31++ + if yyhl31 { + yyb31 = yyj31 > l } else { - yyb231 = r.CheckBreak() + yyb31 = r.CheckBreak() } - if yyb231 { + if yyb31 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj231-1, "") + z.DecStructFieldNotFound(yyj31-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4436,34 +5154,34 @@ func (x *PersistentVolumeClaimVolumeSource) CodecEncodeSelf(e *codec1978.Encoder if x == nil { r.EncodeNil() } else { - yym255 := z.EncBinary() - _ = yym255 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep256 := !z.EncBinary() - yy2arr256 := z.EncBasicHandle().StructToArray - var yyq256 [2]bool - _, _, _ = yysep256, yyq256, yy2arr256 - const yyr256 bool = false - yyq256[1] = x.ReadOnly != false - var yynn256 int - if yyr256 || yy2arr256 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn256 = 1 - for _, b := range yyq256 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn256++ + yynn2++ } } - r.EncodeMapStart(yynn256) - yynn256 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr256 || yy2arr256 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym258 := z.EncBinary() - _ = yym258 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ClaimName)) @@ -4472,18 +5190,18 @@ func (x *PersistentVolumeClaimVolumeSource) CodecEncodeSelf(e *codec1978.Encoder z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("claimName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym259 := z.EncBinary() - _ = yym259 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ClaimName)) } } - if yyr256 || yy2arr256 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq256[1] { - yym261 := z.EncBinary() - _ = yym261 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -4492,19 +5210,19 @@ func (x *PersistentVolumeClaimVolumeSource) CodecEncodeSelf(e *codec1978.Encoder r.EncodeBool(false) } } else { - if yyq256[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym262 := z.EncBinary() - _ = yym262 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr256 || yy2arr256 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -4517,25 +5235,25 @@ func (x *PersistentVolumeClaimVolumeSource) CodecDecodeSelf(d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym263 := z.DecBinary() - _ = yym263 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct264 := r.ContainerType() - if yyct264 == codecSelferValueTypeMap1234 { - yyl264 := r.ReadMapStart() - if yyl264 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl264, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct264 == codecSelferValueTypeArray1234 { - yyl264 := r.ReadArrayStart() - if yyl264 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl264, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -4547,12 +5265,12 @@ func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromMap(l int, d *cod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys265Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys265Slc - var yyhl265 bool = l >= 0 - for yyj265 := 0; ; yyj265++ { - if yyhl265 { - if yyj265 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -4561,26 +5279,38 @@ func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromMap(l int, d *cod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys265Slc = r.DecodeBytes(yys265Slc, true, true) - yys265 := string(yys265Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys265 { + switch yys3 { case "claimName": if r.TryDecodeAsNil() { x.ClaimName = "" } else { - x.ClaimName = string(r.DecodeString()) + yyv4 := &x.ClaimName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv6 := &x.ReadOnly + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(yyv6)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys265) - } // end switch yys265 - } // end for yyj265 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -4588,16 +5318,16 @@ func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromArray(l int, d *c var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj268 int - var yyb268 bool - var yyhl268 bool = l >= 0 - yyj268++ - if yyhl268 { - yyb268 = yyj268 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb268 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb268 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4605,15 +5335,21 @@ func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromArray(l int, d *c if r.TryDecodeAsNil() { x.ClaimName = "" } else { - x.ClaimName = string(r.DecodeString()) + yyv9 := &x.ClaimName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj268++ - if yyhl268 { - yyb268 = yyj268 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb268 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb268 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4621,20 +5357,26 @@ func (x *PersistentVolumeClaimVolumeSource) codecDecodeSelfFromArray(l int, d *c if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv11 := &x.ReadOnly + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(yyv11)) = r.DecodeBool() + } } for { - yyj268++ - if yyhl268 { - yyb268 = yyj268 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb268 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb268 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj268-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4646,49 +5388,53 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym271 := z.EncBinary() - _ = yym271 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep272 := !z.EncBinary() - yy2arr272 := z.EncBasicHandle().StructToArray - var yyq272 [17]bool - _, _, _ = yysep272, yyq272, yy2arr272 - const yyr272 bool = false - yyq272[0] = x.GCEPersistentDisk != nil - yyq272[1] = x.AWSElasticBlockStore != nil - yyq272[2] = x.HostPath != nil - yyq272[3] = x.Glusterfs != nil - yyq272[4] = x.NFS != nil - yyq272[5] = x.RBD != nil - yyq272[6] = x.ISCSI != nil - yyq272[7] = x.Cinder != nil - yyq272[8] = x.CephFS != nil - yyq272[9] = x.FC != nil - yyq272[10] = x.Flocker != nil - yyq272[11] = x.FlexVolume != nil - yyq272[12] = x.AzureFile != nil - yyq272[13] = x.VsphereVolume != nil - yyq272[14] = x.Quobyte != nil - yyq272[15] = x.AzureDisk != nil - yyq272[16] = x.PhotonPersistentDisk != nil - var yynn272 int - if yyr272 || yy2arr272 { - r.EncodeArrayStart(17) - } else { - yynn272 = 0 - for _, b := range yyq272 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [21]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.GCEPersistentDisk != nil + yyq2[1] = x.AWSElasticBlockStore != nil + yyq2[2] = x.HostPath != nil + yyq2[3] = x.Glusterfs != nil + yyq2[4] = x.NFS != nil + yyq2[5] = x.RBD != nil + yyq2[6] = x.ISCSI != nil + yyq2[7] = x.Cinder != nil + yyq2[8] = x.CephFS != nil + yyq2[9] = x.FC != nil + yyq2[10] = x.Flocker != nil + yyq2[11] = x.FlexVolume != nil + yyq2[12] = x.AzureFile != nil + yyq2[13] = x.VsphereVolume != nil + yyq2[14] = x.Quobyte != nil + yyq2[15] = x.AzureDisk != nil + yyq2[16] = x.PhotonPersistentDisk != nil + yyq2[17] = x.PortworxVolume != nil + yyq2[18] = x.ScaleIO != nil + yyq2[19] = x.Local != nil + yyq2[20] = x.StorageOS != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(21) + } else { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn272++ + yynn2++ } } - r.EncodeMapStart(yynn272) - yynn272 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[0] { + if yyq2[0] { if x.GCEPersistentDisk == nil { r.EncodeNil() } else { @@ -4698,7 +5444,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4709,9 +5455,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[1] { + if yyq2[1] { if x.AWSElasticBlockStore == nil { r.EncodeNil() } else { @@ -4721,7 +5467,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4732,9 +5478,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[2] { + if yyq2[2] { if x.HostPath == nil { r.EncodeNil() } else { @@ -4744,7 +5490,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4755,9 +5501,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[3] { + if yyq2[3] { if x.Glusterfs == nil { r.EncodeNil() } else { @@ -4767,7 +5513,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4778,9 +5524,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[4] { + if yyq2[4] { if x.NFS == nil { r.EncodeNil() } else { @@ -4790,7 +5536,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4801,9 +5547,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[5] { + if yyq2[5] { if x.RBD == nil { r.EncodeNil() } else { @@ -4813,7 +5559,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rbd")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4824,9 +5570,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[6] { + if yyq2[6] { if x.ISCSI == nil { r.EncodeNil() } else { @@ -4836,7 +5582,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("iscsi")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4847,9 +5593,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[7] { + if yyq2[7] { if x.Cinder == nil { r.EncodeNil() } else { @@ -4859,7 +5605,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cinder")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4870,9 +5616,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[8] { + if yyq2[8] { if x.CephFS == nil { r.EncodeNil() } else { @@ -4882,7 +5628,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cephfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4893,9 +5639,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[9] { + if yyq2[9] { if x.FC == nil { r.EncodeNil() } else { @@ -4905,7 +5651,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fc")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4916,9 +5662,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[10] { + if yyq2[10] { if x.Flocker == nil { r.EncodeNil() } else { @@ -4928,7 +5674,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[10] { + if yyq2[10] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flocker")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4939,9 +5685,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[11] { + if yyq2[11] { if x.FlexVolume == nil { r.EncodeNil() } else { @@ -4951,7 +5697,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[11] { + if yyq2[11] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4962,9 +5708,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[12] { + if yyq2[12] { if x.AzureFile == nil { r.EncodeNil() } else { @@ -4974,7 +5720,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[12] { + if yyq2[12] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureFile")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -4985,9 +5731,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[13] { + if yyq2[13] { if x.VsphereVolume == nil { r.EncodeNil() } else { @@ -4997,7 +5743,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[13] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -5008,9 +5754,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[14] { + if yyq2[14] { if x.Quobyte == nil { r.EncodeNil() } else { @@ -5020,7 +5766,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[14] { + if yyq2[14] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("quobyte")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -5031,9 +5777,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[15] { + if yyq2[15] { if x.AzureDisk == nil { r.EncodeNil() } else { @@ -5043,7 +5789,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[15] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -5054,9 +5800,9 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq272[16] { + if yyq2[16] { if x.PhotonPersistentDisk == nil { r.EncodeNil() } else { @@ -5066,7 +5812,7 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq272[16] { + if yyq2[16] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -5077,7 +5823,99 @@ func (x *PersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr272 || yy2arr272 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[17] { + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[17] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("portworxVolume")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[18] { + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[18] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("scaleIO")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[19] { + if x.Local == nil { + r.EncodeNil() + } else { + x.Local.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[19] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("local")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Local == nil { + r.EncodeNil() + } else { + x.Local.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[20] { + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[20] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageos")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -5090,25 +5928,25 @@ func (x *PersistentVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym290 := z.DecBinary() - _ = yym290 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct291 := r.ContainerType() - if yyct291 == codecSelferValueTypeMap1234 { - yyl291 := r.ReadMapStart() - if yyl291 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl291, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct291 == codecSelferValueTypeArray1234 { - yyl291 := r.ReadArrayStart() - if yyl291 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl291, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -5120,12 +5958,12 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys292Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys292Slc - var yyhl292 bool = l >= 0 - for yyj292 := 0; ; yyj292++ { - if yyhl292 { - if yyj292 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -5134,10 +5972,10 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys292Slc = r.DecodeBytes(yys292Slc, true, true) - yys292 := string(yys292Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys292 { + switch yys3 { case "gcePersistentDisk": if r.TryDecodeAsNil() { if x.GCEPersistentDisk != nil { @@ -5325,10 +6163,54 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Deco } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + case "portworxVolume": + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + case "scaleIO": + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + case "local": + if r.TryDecodeAsNil() { + if x.Local != nil { + x.Local = nil + } + } else { + if x.Local == nil { + x.Local = new(LocalVolumeSource) + } + x.Local.CodecDecodeSelf(d) + } + case "storageos": + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSPersistentVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } default: - z.DecStructFieldNotFound(-1, yys292) - } // end switch yys292 - } // end for yyj292 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -5336,16 +6218,16 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj310 int - var yyb310 bool - var yyhl310 bool = l >= 0 - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + var yyj25 int + var yyb25 bool + var yyhl25 bool = l >= 0 + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5360,13 +6242,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.GCEPersistentDisk.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5381,13 +6263,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.AWSElasticBlockStore.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5402,13 +6284,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.HostPath.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5423,13 +6305,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.Glusterfs.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5444,13 +6326,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.NFS.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5465,13 +6347,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.RBD.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5486,13 +6368,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.ISCSI.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5507,13 +6389,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.Cinder.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5528,13 +6410,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.CephFS.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5549,13 +6431,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.FC.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5570,13 +6452,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.Flocker.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5591,13 +6473,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.FlexVolume.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5612,13 +6494,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.AzureFile.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5633,13 +6515,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.VsphereVolume.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5654,13 +6536,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.Quobyte.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5675,13 +6557,13 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.AzureDisk.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5696,18 +6578,102 @@ func (x *PersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.De } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Local != nil { + x.Local = nil + } + } else { + if x.Local == nil { + x.Local = new(LocalVolumeSource) + } + x.Local.CodecDecodeSelf(d) + } + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l + } else { + yyb25 = r.CheckBreak() + } + if yyb25 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSPersistentVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } for { - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj25++ + if yyhl25 { + yyb25 = yyj25 > l } else { - yyb310 = r.CheckBreak() + yyb25 = r.CheckBreak() } - if yyb310 { + if yyb25 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj310-1, "") + z.DecStructFieldNotFound(yyj25-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -5719,39 +6685,39 @@ func (x *PersistentVolume) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym328 := z.EncBinary() - _ = yym328 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep329 := !z.EncBinary() - yy2arr329 := z.EncBasicHandle().StructToArray - var yyq329 [5]bool - _, _, _ = yysep329, yyq329, yy2arr329 - const yyr329 bool = false - yyq329[0] = x.Kind != "" - yyq329[1] = x.APIVersion != "" - yyq329[2] = true - yyq329[3] = true - yyq329[4] = true - var yynn329 int - if yyr329 || yy2arr329 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn329 = 0 - for _, b := range yyq329 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn329++ + yynn2++ } } - r.EncodeMapStart(yynn329) - yynn329 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr329 || yy2arr329 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[0] { - yym331 := z.EncBinary() - _ = yym331 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -5760,23 +6726,23 @@ func (x *PersistentVolume) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq329[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym332 := z.EncBinary() - _ = yym332 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr329 || yy2arr329 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[1] { - yym334 := z.EncBinary() - _ = yym334 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -5785,70 +6751,82 @@ func (x *PersistentVolume) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq329[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym335 := z.EncBinary() - _ = yym335 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr329 || yy2arr329 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[2] { - yy337 := &x.ObjectMeta - yy337.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq329[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy338 := &x.ObjectMeta - yy338.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr329 || yy2arr329 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[3] { - yy340 := &x.Spec - yy340.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq329[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy341 := &x.Spec - yy341.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr329 || yy2arr329 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq329[4] { - yy343 := &x.Status - yy343.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq329[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy344 := &x.Status - yy344.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr329 || yy2arr329 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -5861,25 +6839,25 @@ func (x *PersistentVolume) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym345 := z.DecBinary() - _ = yym345 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct346 := r.ContainerType() - if yyct346 == codecSelferValueTypeMap1234 { - yyl346 := r.ReadMapStart() - if yyl346 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl346, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct346 == codecSelferValueTypeArray1234 { - yyl346 := r.ReadArrayStart() - if yyl346 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl346, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -5891,12 +6869,12 @@ func (x *PersistentVolume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys347Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys347Slc - var yyhl347 bool = l >= 0 - for yyj347 := 0; ; yyj347++ { - if yyhl347 { - if yyj347 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -5905,47 +6883,65 @@ func (x *PersistentVolume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys347Slc = r.DecodeBytes(yys347Slc, true, true) - yys347 := string(yys347Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys347 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv350 := &x.ObjectMeta - yyv350.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = PersistentVolumeSpec{} } else { - yyv351 := &x.Spec - yyv351.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = PersistentVolumeStatus{} } else { - yyv352 := &x.Status - yyv352.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys347) - } // end switch yys347 - } // end for yyj347 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -5953,16 +6949,16 @@ func (x *PersistentVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj353 int - var yyb353 bool - var yyhl353 bool = l >= 0 - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb353 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb353 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5970,15 +6966,21 @@ func (x *PersistentVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb353 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb353 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -5986,32 +6988,44 @@ func (x *PersistentVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb353 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb353 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv356 := &x.ObjectMeta - yyv356.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb353 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb353 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6019,16 +7033,16 @@ func (x *PersistentVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Spec = PersistentVolumeSpec{} } else { - yyv357 := &x.Spec - yyv357.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb353 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb353 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -6036,21 +7050,21 @@ func (x *PersistentVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Status = PersistentVolumeStatus{} } else { - yyv358 := &x.Status - yyv358.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj353++ - if yyhl353 { - yyb353 = yyj353 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb353 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb353 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj353-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -6062,53 +7076,58 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym359 := z.EncBinary() - _ = yym359 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep360 := !z.EncBinary() - yy2arr360 := z.EncBasicHandle().StructToArray - var yyq360 [21]bool - _, _, _ = yysep360, yyq360, yy2arr360 - const yyr360 bool = false - yyq360[0] = len(x.Capacity) != 0 - yyq360[1] = x.PersistentVolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil - yyq360[2] = x.PersistentVolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil - yyq360[3] = x.PersistentVolumeSource.HostPath != nil && x.HostPath != nil - yyq360[4] = x.PersistentVolumeSource.Glusterfs != nil && x.Glusterfs != nil - yyq360[5] = x.PersistentVolumeSource.NFS != nil && x.NFS != nil - yyq360[6] = x.PersistentVolumeSource.RBD != nil && x.RBD != nil - yyq360[7] = x.PersistentVolumeSource.ISCSI != nil && x.ISCSI != nil - yyq360[8] = x.PersistentVolumeSource.Cinder != nil && x.Cinder != nil - yyq360[9] = x.PersistentVolumeSource.CephFS != nil && x.CephFS != nil - yyq360[10] = x.PersistentVolumeSource.FC != nil && x.FC != nil - yyq360[11] = x.PersistentVolumeSource.Flocker != nil && x.Flocker != nil - yyq360[12] = x.PersistentVolumeSource.FlexVolume != nil && x.FlexVolume != nil - yyq360[13] = x.PersistentVolumeSource.AzureFile != nil && x.AzureFile != nil - yyq360[14] = x.PersistentVolumeSource.VsphereVolume != nil && x.VsphereVolume != nil - yyq360[15] = x.PersistentVolumeSource.Quobyte != nil && x.Quobyte != nil - yyq360[16] = x.PersistentVolumeSource.AzureDisk != nil && x.AzureDisk != nil - yyq360[17] = x.PersistentVolumeSource.PhotonPersistentDisk != nil && x.PhotonPersistentDisk != nil - yyq360[18] = len(x.AccessModes) != 0 - yyq360[19] = x.ClaimRef != nil - yyq360[20] = x.PersistentVolumeReclaimPolicy != "" - var yynn360 int - if yyr360 || yy2arr360 { - r.EncodeArrayStart(21) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [26]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Capacity) != 0 + yyq2[1] = x.PersistentVolumeSource.GCEPersistentDisk != nil && x.GCEPersistentDisk != nil + yyq2[2] = x.PersistentVolumeSource.AWSElasticBlockStore != nil && x.AWSElasticBlockStore != nil + yyq2[3] = x.PersistentVolumeSource.HostPath != nil && x.HostPath != nil + yyq2[4] = x.PersistentVolumeSource.Glusterfs != nil && x.Glusterfs != nil + yyq2[5] = x.PersistentVolumeSource.NFS != nil && x.NFS != nil + yyq2[6] = x.PersistentVolumeSource.RBD != nil && x.RBD != nil + yyq2[7] = x.PersistentVolumeSource.ISCSI != nil && x.ISCSI != nil + yyq2[8] = x.PersistentVolumeSource.Cinder != nil && x.Cinder != nil + yyq2[9] = x.PersistentVolumeSource.CephFS != nil && x.CephFS != nil + yyq2[10] = x.PersistentVolumeSource.FC != nil && x.FC != nil + yyq2[11] = x.PersistentVolumeSource.Flocker != nil && x.Flocker != nil + yyq2[12] = x.PersistentVolumeSource.FlexVolume != nil && x.FlexVolume != nil + yyq2[13] = x.PersistentVolumeSource.AzureFile != nil && x.AzureFile != nil + yyq2[14] = x.PersistentVolumeSource.VsphereVolume != nil && x.VsphereVolume != nil + yyq2[15] = x.PersistentVolumeSource.Quobyte != nil && x.Quobyte != nil + yyq2[16] = x.PersistentVolumeSource.AzureDisk != nil && x.AzureDisk != nil + yyq2[17] = x.PersistentVolumeSource.PhotonPersistentDisk != nil && x.PhotonPersistentDisk != nil + yyq2[18] = x.PersistentVolumeSource.PortworxVolume != nil && x.PortworxVolume != nil + yyq2[19] = x.PersistentVolumeSource.ScaleIO != nil && x.ScaleIO != nil + yyq2[20] = x.PersistentVolumeSource.Local != nil && x.Local != nil + yyq2[21] = x.PersistentVolumeSource.StorageOS != nil && x.StorageOS != nil + yyq2[22] = len(x.AccessModes) != 0 + yyq2[23] = x.ClaimRef != nil + yyq2[24] = x.PersistentVolumeReclaimPolicy != "" + yyq2[25] = x.StorageClassName != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(26) } else { - yynn360 = 0 - for _, b := range yyq360 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn360++ + yynn2++ } } - r.EncodeMapStart(yynn360) - yynn360 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr360 || yy2arr360 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[0] { + if yyq2[0] { if x.Capacity == nil { r.EncodeNil() } else { @@ -6118,7 +7137,7 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq360[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("capacity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -6129,18 +7148,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn362 bool + var yyn6 bool if x.PersistentVolumeSource.GCEPersistentDisk == nil { - yyn362 = true - goto LABEL362 + yyn6 = true + goto LABEL6 } - LABEL362: - if yyr360 || yy2arr360 { - if yyn362 { + LABEL6: + if yyr2 || yy2arr2 { + if yyn6 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[1] { + if yyq2[1] { if x.GCEPersistentDisk == nil { r.EncodeNil() } else { @@ -6151,11 +7170,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gcePersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn362 { + if yyn6 { r.EncodeNil() } else { if x.GCEPersistentDisk == nil { @@ -6166,18 +7185,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn363 bool + var yyn9 bool if x.PersistentVolumeSource.AWSElasticBlockStore == nil { - yyn363 = true - goto LABEL363 + yyn9 = true + goto LABEL9 } - LABEL363: - if yyr360 || yy2arr360 { - if yyn363 { + LABEL9: + if yyr2 || yy2arr2 { + if yyn9 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[2] { + if yyq2[2] { if x.AWSElasticBlockStore == nil { r.EncodeNil() } else { @@ -6188,11 +7207,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("awsElasticBlockStore")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn363 { + if yyn9 { r.EncodeNil() } else { if x.AWSElasticBlockStore == nil { @@ -6203,18 +7222,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn364 bool + var yyn12 bool if x.PersistentVolumeSource.HostPath == nil { - yyn364 = true - goto LABEL364 + yyn12 = true + goto LABEL12 } - LABEL364: - if yyr360 || yy2arr360 { - if yyn364 { + LABEL12: + if yyr2 || yy2arr2 { + if yyn12 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[3] { + if yyq2[3] { if x.HostPath == nil { r.EncodeNil() } else { @@ -6225,11 +7244,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn364 { + if yyn12 { r.EncodeNil() } else { if x.HostPath == nil { @@ -6240,18 +7259,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn365 bool + var yyn15 bool if x.PersistentVolumeSource.Glusterfs == nil { - yyn365 = true - goto LABEL365 + yyn15 = true + goto LABEL15 } - LABEL365: - if yyr360 || yy2arr360 { - if yyn365 { + LABEL15: + if yyr2 || yy2arr2 { + if yyn15 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[4] { + if yyq2[4] { if x.Glusterfs == nil { r.EncodeNil() } else { @@ -6262,11 +7281,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("glusterfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn365 { + if yyn15 { r.EncodeNil() } else { if x.Glusterfs == nil { @@ -6277,18 +7296,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn366 bool + var yyn18 bool if x.PersistentVolumeSource.NFS == nil { - yyn366 = true - goto LABEL366 + yyn18 = true + goto LABEL18 } - LABEL366: - if yyr360 || yy2arr360 { - if yyn366 { + LABEL18: + if yyr2 || yy2arr2 { + if yyn18 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[5] { + if yyq2[5] { if x.NFS == nil { r.EncodeNil() } else { @@ -6299,11 +7318,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn366 { + if yyn18 { r.EncodeNil() } else { if x.NFS == nil { @@ -6314,18 +7333,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn367 bool + var yyn21 bool if x.PersistentVolumeSource.RBD == nil { - yyn367 = true - goto LABEL367 + yyn21 = true + goto LABEL21 } - LABEL367: - if yyr360 || yy2arr360 { - if yyn367 { + LABEL21: + if yyr2 || yy2arr2 { + if yyn21 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[6] { + if yyq2[6] { if x.RBD == nil { r.EncodeNil() } else { @@ -6336,11 +7355,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rbd")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn367 { + if yyn21 { r.EncodeNil() } else { if x.RBD == nil { @@ -6351,18 +7370,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn368 bool + var yyn24 bool if x.PersistentVolumeSource.ISCSI == nil { - yyn368 = true - goto LABEL368 + yyn24 = true + goto LABEL24 } - LABEL368: - if yyr360 || yy2arr360 { - if yyn368 { + LABEL24: + if yyr2 || yy2arr2 { + if yyn24 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[7] { + if yyq2[7] { if x.ISCSI == nil { r.EncodeNil() } else { @@ -6373,11 +7392,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("iscsi")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn368 { + if yyn24 { r.EncodeNil() } else { if x.ISCSI == nil { @@ -6388,18 +7407,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn369 bool + var yyn27 bool if x.PersistentVolumeSource.Cinder == nil { - yyn369 = true - goto LABEL369 + yyn27 = true + goto LABEL27 } - LABEL369: - if yyr360 || yy2arr360 { - if yyn369 { + LABEL27: + if yyr2 || yy2arr2 { + if yyn27 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[8] { + if yyq2[8] { if x.Cinder == nil { r.EncodeNil() } else { @@ -6410,11 +7429,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cinder")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn369 { + if yyn27 { r.EncodeNil() } else { if x.Cinder == nil { @@ -6425,18 +7444,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn370 bool + var yyn30 bool if x.PersistentVolumeSource.CephFS == nil { - yyn370 = true - goto LABEL370 + yyn30 = true + goto LABEL30 } - LABEL370: - if yyr360 || yy2arr360 { - if yyn370 { + LABEL30: + if yyr2 || yy2arr2 { + if yyn30 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[9] { + if yyq2[9] { if x.CephFS == nil { r.EncodeNil() } else { @@ -6447,11 +7466,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("cephfs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn370 { + if yyn30 { r.EncodeNil() } else { if x.CephFS == nil { @@ -6462,18 +7481,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn371 bool + var yyn33 bool if x.PersistentVolumeSource.FC == nil { - yyn371 = true - goto LABEL371 + yyn33 = true + goto LABEL33 } - LABEL371: - if yyr360 || yy2arr360 { - if yyn371 { + LABEL33: + if yyr2 || yy2arr2 { + if yyn33 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[10] { + if yyq2[10] { if x.FC == nil { r.EncodeNil() } else { @@ -6484,11 +7503,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[10] { + if yyq2[10] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fc")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn371 { + if yyn33 { r.EncodeNil() } else { if x.FC == nil { @@ -6499,18 +7518,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn372 bool + var yyn36 bool if x.PersistentVolumeSource.Flocker == nil { - yyn372 = true - goto LABEL372 + yyn36 = true + goto LABEL36 } - LABEL372: - if yyr360 || yy2arr360 { - if yyn372 { + LABEL36: + if yyr2 || yy2arr2 { + if yyn36 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[11] { + if yyq2[11] { if x.Flocker == nil { r.EncodeNil() } else { @@ -6521,11 +7540,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[11] { + if yyq2[11] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flocker")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn372 { + if yyn36 { r.EncodeNil() } else { if x.Flocker == nil { @@ -6536,18 +7555,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn373 bool + var yyn39 bool if x.PersistentVolumeSource.FlexVolume == nil { - yyn373 = true - goto LABEL373 + yyn39 = true + goto LABEL39 } - LABEL373: - if yyr360 || yy2arr360 { - if yyn373 { + LABEL39: + if yyr2 || yy2arr2 { + if yyn39 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[12] { + if yyq2[12] { if x.FlexVolume == nil { r.EncodeNil() } else { @@ -6558,11 +7577,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[12] { + if yyq2[12] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("flexVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn373 { + if yyn39 { r.EncodeNil() } else { if x.FlexVolume == nil { @@ -6573,18 +7592,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn374 bool + var yyn42 bool if x.PersistentVolumeSource.AzureFile == nil { - yyn374 = true - goto LABEL374 + yyn42 = true + goto LABEL42 } - LABEL374: - if yyr360 || yy2arr360 { - if yyn374 { + LABEL42: + if yyr2 || yy2arr2 { + if yyn42 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[13] { + if yyq2[13] { if x.AzureFile == nil { r.EncodeNil() } else { @@ -6595,11 +7614,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[13] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureFile")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn374 { + if yyn42 { r.EncodeNil() } else { if x.AzureFile == nil { @@ -6610,18 +7629,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn375 bool + var yyn45 bool if x.PersistentVolumeSource.VsphereVolume == nil { - yyn375 = true - goto LABEL375 + yyn45 = true + goto LABEL45 } - LABEL375: - if yyr360 || yy2arr360 { - if yyn375 { + LABEL45: + if yyr2 || yy2arr2 { + if yyn45 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[14] { + if yyq2[14] { if x.VsphereVolume == nil { r.EncodeNil() } else { @@ -6632,11 +7651,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[14] { + if yyq2[14] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("vsphereVolume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn375 { + if yyn45 { r.EncodeNil() } else { if x.VsphereVolume == nil { @@ -6647,18 +7666,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn376 bool + var yyn48 bool if x.PersistentVolumeSource.Quobyte == nil { - yyn376 = true - goto LABEL376 + yyn48 = true + goto LABEL48 } - LABEL376: - if yyr360 || yy2arr360 { - if yyn376 { + LABEL48: + if yyr2 || yy2arr2 { + if yyn48 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[15] { + if yyq2[15] { if x.Quobyte == nil { r.EncodeNil() } else { @@ -6669,11 +7688,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[15] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("quobyte")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn376 { + if yyn48 { r.EncodeNil() } else { if x.Quobyte == nil { @@ -6684,18 +7703,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn377 bool + var yyn51 bool if x.PersistentVolumeSource.AzureDisk == nil { - yyn377 = true - goto LABEL377 + yyn51 = true + goto LABEL51 } - LABEL377: - if yyr360 || yy2arr360 { - if yyn377 { + LABEL51: + if yyr2 || yy2arr2 { + if yyn51 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[16] { + if yyq2[16] { if x.AzureDisk == nil { r.EncodeNil() } else { @@ -6706,11 +7725,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[16] { + if yyq2[16] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("azureDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn377 { + if yyn51 { r.EncodeNil() } else { if x.AzureDisk == nil { @@ -6721,18 +7740,18 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn378 bool + var yyn54 bool if x.PersistentVolumeSource.PhotonPersistentDisk == nil { - yyn378 = true - goto LABEL378 + yyn54 = true + goto LABEL54 } - LABEL378: - if yyr360 || yy2arr360 { - if yyn378 { + LABEL54: + if yyr2 || yy2arr2 { + if yyn54 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[17] { + if yyq2[17] { if x.PhotonPersistentDisk == nil { r.EncodeNil() } else { @@ -6743,11 +7762,11 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq360[17] { + if yyq2[17] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("photonPersistentDisk")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn378 { + if yyn54 { r.EncodeNil() } else { if x.PhotonPersistentDisk == nil { @@ -6758,14 +7777,162 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr360 || yy2arr360 { + var yyn57 bool + if x.PersistentVolumeSource.PortworxVolume == nil { + yyn57 = true + goto LABEL57 + } + LABEL57: + if yyr2 || yy2arr2 { + if yyn57 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[18] { + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[18] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("portworxVolume")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn57 { + r.EncodeNil() + } else { + if x.PortworxVolume == nil { + r.EncodeNil() + } else { + x.PortworxVolume.CodecEncodeSelf(e) + } + } + } + } + var yyn60 bool + if x.PersistentVolumeSource.ScaleIO == nil { + yyn60 = true + goto LABEL60 + } + LABEL60: + if yyr2 || yy2arr2 { + if yyn60 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[19] { + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[19] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("scaleIO")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn60 { + r.EncodeNil() + } else { + if x.ScaleIO == nil { + r.EncodeNil() + } else { + x.ScaleIO.CodecEncodeSelf(e) + } + } + } + } + var yyn63 bool + if x.PersistentVolumeSource.Local == nil { + yyn63 = true + goto LABEL63 + } + LABEL63: + if yyr2 || yy2arr2 { + if yyn63 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[20] { + if x.Local == nil { + r.EncodeNil() + } else { + x.Local.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[20] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("local")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn63 { + r.EncodeNil() + } else { + if x.Local == nil { + r.EncodeNil() + } else { + x.Local.CodecEncodeSelf(e) + } + } + } + } + var yyn66 bool + if x.PersistentVolumeSource.StorageOS == nil { + yyn66 = true + goto LABEL66 + } + LABEL66: + if yyr2 || yy2arr2 { + if yyn66 { + r.EncodeNil() + } else { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[21] { + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } + } else { + if yyq2[21] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageos")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyn66 { + r.EncodeNil() + } else { + if x.StorageOS == nil { + r.EncodeNil() + } else { + x.StorageOS.CodecEncodeSelf(e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[18] { + if yyq2[22] { if x.AccessModes == nil { r.EncodeNil() } else { - yym380 := z.EncBinary() - _ = yym380 + yym70 := z.EncBinary() + _ = yym70 if false { } else { h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) @@ -6775,15 +7942,15 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq360[18] { + if yyq2[22] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("accessModes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.AccessModes == nil { r.EncodeNil() } else { - yym381 := z.EncBinary() - _ = yym381 + yym71 := z.EncBinary() + _ = yym71 if false { } else { h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) @@ -6791,9 +7958,9 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr360 || yy2arr360 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[19] { + if yyq2[23] { if x.ClaimRef == nil { r.EncodeNil() } else { @@ -6803,7 +7970,7 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq360[19] { + if yyq2[23] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("claimRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -6814,22 +7981,47 @@ func (x *PersistentVolumeSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr360 || yy2arr360 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq360[20] { + if yyq2[24] { x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq360[20] { + if yyq2[24] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("persistentVolumeReclaimPolicy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.PersistentVolumeReclaimPolicy.CodecEncodeSelf(e) } } - if yyr360 || yy2arr360 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[25] { + yym79 := z.EncBinary() + _ = yym79 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StorageClassName)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[25] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageClassName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym80 := z.EncBinary() + _ = yym80 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StorageClassName)) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -6842,25 +8034,25 @@ func (x *PersistentVolumeSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym384 := z.DecBinary() - _ = yym384 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct385 := r.ContainerType() - if yyct385 == codecSelferValueTypeMap1234 { - yyl385 := r.ReadMapStart() - if yyl385 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl385, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct385 == codecSelferValueTypeArray1234 { - yyl385 := r.ReadArrayStart() - if yyl385 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl385, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -6872,12 +8064,12 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys386Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys386Slc - var yyhl386 bool = l >= 0 - for yyj386 := 0; ; yyj386++ { - if yyhl386 { - if yyj386 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -6886,16 +8078,16 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys386Slc = r.DecodeBytes(yys386Slc, true, true) - yys386 := string(yys386Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys386 { + switch yys3 { case "capacity": if r.TryDecodeAsNil() { x.Capacity = nil } else { - yyv387 := &x.Capacity - yyv387.CodecDecodeSelf(d) + yyv4 := &x.Capacity + yyv4.CodecDecodeSelf(d) } case "gcePersistentDisk": if x.PersistentVolumeSource.GCEPersistentDisk == nil { @@ -7135,16 +8327,72 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decode } x.PhotonPersistentDisk.CodecDecodeSelf(d) } + case "portworxVolume": + if x.PersistentVolumeSource.PortworxVolume == nil { + x.PersistentVolumeSource.PortworxVolume = new(PortworxVolumeSource) + } + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + case "scaleIO": + if x.PersistentVolumeSource.ScaleIO == nil { + x.PersistentVolumeSource.ScaleIO = new(ScaleIOVolumeSource) + } + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + case "local": + if x.PersistentVolumeSource.Local == nil { + x.PersistentVolumeSource.Local = new(LocalVolumeSource) + } + if r.TryDecodeAsNil() { + if x.Local != nil { + x.Local = nil + } + } else { + if x.Local == nil { + x.Local = new(LocalVolumeSource) + } + x.Local.CodecDecodeSelf(d) + } + case "storageos": + if x.PersistentVolumeSource.StorageOS == nil { + x.PersistentVolumeSource.StorageOS = new(StorageOSPersistentVolumeSource) + } + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSPersistentVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } case "accessModes": if r.TryDecodeAsNil() { x.AccessModes = nil } else { - yyv405 := &x.AccessModes - yym406 := z.DecBinary() - _ = yym406 + yyv26 := &x.AccessModes + yym27 := z.DecBinary() + _ = yym27 if false { } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv405), d) + h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv26), d) } } case "claimRef": @@ -7162,12 +8410,25 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.PersistentVolumeReclaimPolicy = "" } else { - x.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(r.DecodeString()) + yyv29 := &x.PersistentVolumeReclaimPolicy + yyv29.CodecDecodeSelf(d) + } + case "storageClassName": + if r.TryDecodeAsNil() { + x.StorageClassName = "" + } else { + yyv30 := &x.StorageClassName + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys386) - } // end switch yys386 - } // end for yyj386 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -7175,16 +8436,16 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj409 int - var yyb409 bool - var yyhl409 bool = l >= 0 - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + var yyj32 int + var yyb32 bool + var yyhl32 bool = l >= 0 + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7192,19 +8453,19 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Capacity = nil } else { - yyv410 := &x.Capacity - yyv410.CodecDecodeSelf(d) + yyv33 := &x.Capacity + yyv33.CodecDecodeSelf(d) } if x.PersistentVolumeSource.GCEPersistentDisk == nil { x.PersistentVolumeSource.GCEPersistentDisk = new(GCEPersistentDiskVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7222,13 +8483,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.AWSElasticBlockStore == nil { x.PersistentVolumeSource.AWSElasticBlockStore = new(AWSElasticBlockStoreVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7246,13 +8507,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.HostPath == nil { x.PersistentVolumeSource.HostPath = new(HostPathVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7270,13 +8531,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.Glusterfs == nil { x.PersistentVolumeSource.Glusterfs = new(GlusterfsVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7294,13 +8555,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.NFS == nil { x.PersistentVolumeSource.NFS = new(NFSVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7318,13 +8579,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.RBD == nil { x.PersistentVolumeSource.RBD = new(RBDVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7342,13 +8603,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.ISCSI == nil { x.PersistentVolumeSource.ISCSI = new(ISCSIVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7366,13 +8627,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.Cinder == nil { x.PersistentVolumeSource.Cinder = new(CinderVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7390,13 +8651,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.CephFS == nil { x.PersistentVolumeSource.CephFS = new(CephFSVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7414,13 +8675,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.FC == nil { x.PersistentVolumeSource.FC = new(FCVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7438,13 +8699,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.Flocker == nil { x.PersistentVolumeSource.Flocker = new(FlockerVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7462,13 +8723,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.FlexVolume == nil { x.PersistentVolumeSource.FlexVolume = new(FlexVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7486,13 +8747,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.AzureFile == nil { x.PersistentVolumeSource.AzureFile = new(AzureFileVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7510,13 +8771,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.VsphereVolume == nil { x.PersistentVolumeSource.VsphereVolume = new(VsphereVirtualDiskVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7534,13 +8795,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.Quobyte == nil { x.PersistentVolumeSource.Quobyte = new(QuobyteVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7558,13 +8819,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.AzureDisk == nil { x.PersistentVolumeSource.AzureDisk = new(AzureDiskVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7582,13 +8843,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if x.PersistentVolumeSource.PhotonPersistentDisk == nil { x.PersistentVolumeSource.PhotonPersistentDisk = new(PhotonPersistentDiskVolumeSource) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7603,13 +8864,109 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco } x.PhotonPersistentDisk.CodecDecodeSelf(d) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + if x.PersistentVolumeSource.PortworxVolume == nil { + x.PersistentVolumeSource.PortworxVolume = new(PortworxVolumeSource) + } + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l + } else { + yyb32 = r.CheckBreak() + } + if yyb32 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PortworxVolume != nil { + x.PortworxVolume = nil + } + } else { + if x.PortworxVolume == nil { + x.PortworxVolume = new(PortworxVolumeSource) + } + x.PortworxVolume.CodecDecodeSelf(d) + } + if x.PersistentVolumeSource.ScaleIO == nil { + x.PersistentVolumeSource.ScaleIO = new(ScaleIOVolumeSource) + } + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l + } else { + yyb32 = r.CheckBreak() + } + if yyb32 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ScaleIO != nil { + x.ScaleIO = nil + } + } else { + if x.ScaleIO == nil { + x.ScaleIO = new(ScaleIOVolumeSource) + } + x.ScaleIO.CodecDecodeSelf(d) + } + if x.PersistentVolumeSource.Local == nil { + x.PersistentVolumeSource.Local = new(LocalVolumeSource) + } + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l + } else { + yyb32 = r.CheckBreak() + } + if yyb32 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Local != nil { + x.Local = nil + } + } else { + if x.Local == nil { + x.Local = new(LocalVolumeSource) + } + x.Local.CodecDecodeSelf(d) + } + if x.PersistentVolumeSource.StorageOS == nil { + x.PersistentVolumeSource.StorageOS = new(StorageOSPersistentVolumeSource) + } + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l + } else { + yyb32 = r.CheckBreak() + } + if yyb32 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.StorageOS != nil { + x.StorageOS = nil + } + } else { + if x.StorageOS == nil { + x.StorageOS = new(StorageOSPersistentVolumeSource) + } + x.StorageOS.CodecDecodeSelf(d) + } + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7617,21 +8974,21 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.AccessModes = nil } else { - yyv428 := &x.AccessModes - yym429 := z.DecBinary() - _ = yym429 + yyv55 := &x.AccessModes + yym56 := z.DecBinary() + _ = yym56 if false { } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv428), d) + h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv55), d) } } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7646,13 +9003,13 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco } x.ClaimRef.CodecDecodeSelf(d) } - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7660,20 +9017,43 @@ func (x *PersistentVolumeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.PersistentVolumeReclaimPolicy = "" } else { - x.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(r.DecodeString()) + yyv58 := &x.PersistentVolumeReclaimPolicy + yyv58.CodecDecodeSelf(d) + } + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l + } else { + yyb32 = r.CheckBreak() + } + if yyb32 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.StorageClassName = "" + } else { + yyv59 := &x.StorageClassName + yym60 := z.DecBinary() + _ = yym60 + if false { + } else { + *((*string)(yyv59)) = r.DecodeString() + } } for { - yyj409++ - if yyhl409 { - yyb409 = yyj409 > l + yyj32++ + if yyhl32 { + yyb32 = yyj32 > l } else { - yyb409 = r.CheckBreak() + yyb32 = r.CheckBreak() } - if yyb409 { + if yyb32 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj409-1, "") + z.DecStructFieldNotFound(yyj32-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -7682,8 +9062,8 @@ func (x PersistentVolumeReclaimPolicy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym432 := z.EncBinary() - _ = yym432 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -7695,8 +9075,8 @@ func (x *PersistentVolumeReclaimPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym433 := z.DecBinary() - _ = yym433 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -7711,52 +9091,52 @@ func (x *PersistentVolumeStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym434 := z.EncBinary() - _ = yym434 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep435 := !z.EncBinary() - yy2arr435 := z.EncBasicHandle().StructToArray - var yyq435 [3]bool - _, _, _ = yysep435, yyq435, yy2arr435 - const yyr435 bool = false - yyq435[0] = x.Phase != "" - yyq435[1] = x.Message != "" - yyq435[2] = x.Reason != "" - var yynn435 int - if yyr435 || yy2arr435 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Phase != "" + yyq2[1] = x.Message != "" + yyq2[2] = x.Reason != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn435 = 0 - for _, b := range yyq435 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn435++ + yynn2++ } } - r.EncodeMapStart(yynn435) - yynn435 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr435 || yy2arr435 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq435[0] { + if yyq2[0] { x.Phase.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq435[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("phase")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Phase.CodecEncodeSelf(e) } } - if yyr435 || yy2arr435 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq435[1] { - yym438 := z.EncBinary() - _ = yym438 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -7765,23 +9145,23 @@ func (x *PersistentVolumeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq435[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym439 := z.EncBinary() - _ = yym439 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr435 || yy2arr435 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq435[2] { - yym441 := z.EncBinary() - _ = yym441 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -7790,19 +9170,19 @@ func (x *PersistentVolumeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq435[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym442 := z.EncBinary() - _ = yym442 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr435 || yy2arr435 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -7815,25 +9195,25 @@ func (x *PersistentVolumeStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym443 := z.DecBinary() - _ = yym443 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct444 := r.ContainerType() - if yyct444 == codecSelferValueTypeMap1234 { - yyl444 := r.ReadMapStart() - if yyl444 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl444, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct444 == codecSelferValueTypeArray1234 { - yyl444 := r.ReadArrayStart() - if yyl444 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl444, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -7845,12 +9225,12 @@ func (x *PersistentVolumeStatus) codecDecodeSelfFromMap(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys445Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys445Slc - var yyhl445 bool = l >= 0 - for yyj445 := 0; ; yyj445++ { - if yyhl445 { - if yyj445 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -7859,32 +9239,45 @@ func (x *PersistentVolumeStatus) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys445Slc = r.DecodeBytes(yys445Slc, true, true) - yys445 := string(yys445Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys445 { + switch yys3 { case "phase": if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = PersistentVolumePhase(r.DecodeString()) + yyv4 := &x.Phase + yyv4.CodecDecodeSelf(d) } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv5 := &x.Message + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv7 := &x.Reason + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys445) - } // end switch yys445 - } // end for yyj445 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -7892,16 +9285,16 @@ func (x *PersistentVolumeStatus) codecDecodeSelfFromArray(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj449 int - var yyb449 bool - var yyhl449 bool = l >= 0 - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb449 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb449 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7909,15 +9302,16 @@ func (x *PersistentVolumeStatus) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = PersistentVolumePhase(r.DecodeString()) + yyv10 := &x.Phase + yyv10.CodecDecodeSelf(d) } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb449 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb449 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7925,15 +9319,21 @@ func (x *PersistentVolumeStatus) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv11 := &x.Message + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb449 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb449 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -7941,20 +9341,26 @@ func (x *PersistentVolumeStatus) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv13 := &x.Reason + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } for { - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb449 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb449 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj449-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -7966,37 +9372,37 @@ func (x *PersistentVolumeList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym453 := z.EncBinary() - _ = yym453 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep454 := !z.EncBinary() - yy2arr454 := z.EncBasicHandle().StructToArray - var yyq454 [4]bool - _, _, _ = yysep454, yyq454, yy2arr454 - const yyr454 bool = false - yyq454[0] = x.Kind != "" - yyq454[1] = x.APIVersion != "" - yyq454[2] = true - var yynn454 int - if yyr454 || yy2arr454 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn454 = 1 - for _, b := range yyq454 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn454++ + yynn2++ } } - r.EncodeMapStart(yynn454) - yynn454 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr454 || yy2arr454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq454[0] { - yym456 := z.EncBinary() - _ = yym456 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -8005,23 +9411,23 @@ func (x *PersistentVolumeList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq454[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym457 := z.EncBinary() - _ = yym457 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr454 || yy2arr454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq454[1] { - yym459 := z.EncBinary() - _ = yym459 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -8030,54 +9436,54 @@ func (x *PersistentVolumeList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq454[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym460 := z.EncBinary() - _ = yym460 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr454 || yy2arr454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq454[2] { - yy462 := &x.ListMeta - yym463 := z.EncBinary() - _ = yym463 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy462) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy462) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq454[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy464 := &x.ListMeta - yym465 := z.EncBinary() - _ = yym465 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy464) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy464) + z.EncFallback(yy12) } } } - if yyr454 || yy2arr454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym467 := z.EncBinary() - _ = yym467 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePersistentVolume(([]PersistentVolume)(x.Items), e) @@ -8090,15 +9496,15 @@ func (x *PersistentVolumeList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym468 := z.EncBinary() - _ = yym468 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePersistentVolume(([]PersistentVolume)(x.Items), e) } } } - if yyr454 || yy2arr454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -8111,25 +9517,25 @@ func (x *PersistentVolumeList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym469 := z.DecBinary() - _ = yym469 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct470 := r.ContainerType() - if yyct470 == codecSelferValueTypeMap1234 { - yyl470 := r.ReadMapStart() - if yyl470 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl470, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct470 == codecSelferValueTypeArray1234 { - yyl470 := r.ReadArrayStart() - if yyl470 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl470, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -8141,12 +9547,12 @@ func (x *PersistentVolumeList) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys471Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys471Slc - var yyhl471 bool = l >= 0 - for yyj471 := 0; ; yyj471++ { - if yyhl471 { - if yyj471 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -8155,51 +9561,63 @@ func (x *PersistentVolumeList) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys471Slc = r.DecodeBytes(yys471Slc, true, true) - yys471 := string(yys471Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys471 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv474 := &x.ListMeta - yym475 := z.DecBinary() - _ = yym475 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv474) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv474, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv476 := &x.Items - yym477 := z.DecBinary() - _ = yym477 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePersistentVolume((*[]PersistentVolume)(yyv476), d) + h.decSlicePersistentVolume((*[]PersistentVolume)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys471) - } // end switch yys471 - } // end for yyj471 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -8207,16 +9625,16 @@ func (x *PersistentVolumeList) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj478 int - var yyb478 bool - var yyhl478 bool = l >= 0 - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb478 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb478 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8224,15 +9642,21 @@ func (x *PersistentVolumeList) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb478 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb478 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8240,38 +9664,44 @@ func (x *PersistentVolumeList) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb478 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb478 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv481 := &x.ListMeta - yym482 := z.DecBinary() - _ = yym482 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv481) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv481, false) + z.DecFallback(yyv17, false) } } - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb478 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb478 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8279,26 +9709,26 @@ func (x *PersistentVolumeList) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Items = nil } else { - yyv483 := &x.Items - yym484 := z.DecBinary() - _ = yym484 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePersistentVolume((*[]PersistentVolume)(yyv483), d) + h.decSlicePersistentVolume((*[]PersistentVolume)(yyv19), d) } } for { - yyj478++ - if yyhl478 { - yyb478 = yyj478 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb478 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb478 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj478-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -8310,39 +9740,39 @@ func (x *PersistentVolumeClaim) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym485 := z.EncBinary() - _ = yym485 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep486 := !z.EncBinary() - yy2arr486 := z.EncBasicHandle().StructToArray - var yyq486 [5]bool - _, _, _ = yysep486, yyq486, yy2arr486 - const yyr486 bool = false - yyq486[0] = x.Kind != "" - yyq486[1] = x.APIVersion != "" - yyq486[2] = true - yyq486[3] = true - yyq486[4] = true - var yynn486 int - if yyr486 || yy2arr486 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn486 = 0 - for _, b := range yyq486 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn486++ + yynn2++ } } - r.EncodeMapStart(yynn486) - yynn486 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr486 || yy2arr486 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[0] { - yym488 := z.EncBinary() - _ = yym488 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -8351,23 +9781,23 @@ func (x *PersistentVolumeClaim) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq486[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym489 := z.EncBinary() - _ = yym489 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr486 || yy2arr486 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[1] { - yym491 := z.EncBinary() - _ = yym491 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -8376,70 +9806,82 @@ func (x *PersistentVolumeClaim) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq486[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym492 := z.EncBinary() - _ = yym492 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr486 || yy2arr486 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[2] { - yy494 := &x.ObjectMeta - yy494.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq486[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy495 := &x.ObjectMeta - yy495.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr486 || yy2arr486 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[3] { - yy497 := &x.Spec - yy497.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq486[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy498 := &x.Spec - yy498.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr486 || yy2arr486 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq486[4] { - yy500 := &x.Status - yy500.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq486[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy501 := &x.Status - yy501.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr486 || yy2arr486 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -8452,25 +9894,25 @@ func (x *PersistentVolumeClaim) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym502 := z.DecBinary() - _ = yym502 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct503 := r.ContainerType() - if yyct503 == codecSelferValueTypeMap1234 { - yyl503 := r.ReadMapStart() - if yyl503 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl503, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct503 == codecSelferValueTypeArray1234 { - yyl503 := r.ReadArrayStart() - if yyl503 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl503, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -8482,12 +9924,12 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys504Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys504Slc - var yyhl504 bool = l >= 0 - for yyj504 := 0; ; yyj504++ { - if yyhl504 { - if yyj504 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -8496,47 +9938,65 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys504Slc = r.DecodeBytes(yys504Slc, true, true) - yys504 := string(yys504Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys504 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv507 := &x.ObjectMeta - yyv507.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = PersistentVolumeClaimSpec{} } else { - yyv508 := &x.Spec - yyv508.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = PersistentVolumeClaimStatus{} } else { - yyv509 := &x.Status - yyv509.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys504) - } // end switch yys504 - } // end for yyj504 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -8544,16 +10004,16 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj510 int - var yyb510 bool - var yyhl510 bool = l >= 0 - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb510 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb510 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8561,15 +10021,21 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb510 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb510 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8577,32 +10043,44 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb510 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb510 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv513 := &x.ObjectMeta - yyv513.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb510 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb510 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8610,16 +10088,16 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Spec = PersistentVolumeClaimSpec{} } else { - yyv514 := &x.Spec - yyv514.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb510 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb510 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8627,21 +10105,21 @@ func (x *PersistentVolumeClaim) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Status = PersistentVolumeClaimStatus{} } else { - yyv515 := &x.Status - yyv515.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj510++ - if yyhl510 { - yyb510 = yyj510 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb510 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb510 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj510-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -8653,37 +10131,37 @@ func (x *PersistentVolumeClaimList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym516 := z.EncBinary() - _ = yym516 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep517 := !z.EncBinary() - yy2arr517 := z.EncBasicHandle().StructToArray - var yyq517 [4]bool - _, _, _ = yysep517, yyq517, yy2arr517 - const yyr517 bool = false - yyq517[0] = x.Kind != "" - yyq517[1] = x.APIVersion != "" - yyq517[2] = true - var yynn517 int - if yyr517 || yy2arr517 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn517 = 1 - for _, b := range yyq517 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn517++ + yynn2++ } } - r.EncodeMapStart(yynn517) - yynn517 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr517 || yy2arr517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq517[0] { - yym519 := z.EncBinary() - _ = yym519 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -8692,23 +10170,23 @@ func (x *PersistentVolumeClaimList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq517[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym520 := z.EncBinary() - _ = yym520 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr517 || yy2arr517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq517[1] { - yym522 := z.EncBinary() - _ = yym522 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -8717,54 +10195,54 @@ func (x *PersistentVolumeClaimList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq517[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym523 := z.EncBinary() - _ = yym523 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr517 || yy2arr517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq517[2] { - yy525 := &x.ListMeta - yym526 := z.EncBinary() - _ = yym526 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy525) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy525) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq517[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy527 := &x.ListMeta - yym528 := z.EncBinary() - _ = yym528 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy527) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy527) + z.EncFallback(yy12) } } } - if yyr517 || yy2arr517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym530 := z.EncBinary() - _ = yym530 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePersistentVolumeClaim(([]PersistentVolumeClaim)(x.Items), e) @@ -8777,15 +10255,15 @@ func (x *PersistentVolumeClaimList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym531 := z.EncBinary() - _ = yym531 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePersistentVolumeClaim(([]PersistentVolumeClaim)(x.Items), e) } } } - if yyr517 || yy2arr517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -8798,25 +10276,25 @@ func (x *PersistentVolumeClaimList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym532 := z.DecBinary() - _ = yym532 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct533 := r.ContainerType() - if yyct533 == codecSelferValueTypeMap1234 { - yyl533 := r.ReadMapStart() - if yyl533 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl533, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct533 == codecSelferValueTypeArray1234 { - yyl533 := r.ReadArrayStart() - if yyl533 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl533, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -8828,12 +10306,12 @@ func (x *PersistentVolumeClaimList) codecDecodeSelfFromMap(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys534Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys534Slc - var yyhl534 bool = l >= 0 - for yyj534 := 0; ; yyj534++ { - if yyhl534 { - if yyj534 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -8842,51 +10320,63 @@ func (x *PersistentVolumeClaimList) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys534Slc = r.DecodeBytes(yys534Slc, true, true) - yys534 := string(yys534Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys534 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv537 := &x.ListMeta - yym538 := z.DecBinary() - _ = yym538 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv537) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv537, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv539 := &x.Items - yym540 := z.DecBinary() - _ = yym540 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv539), d) + h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys534) - } // end switch yys534 - } // end for yyj534 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -8894,16 +10384,16 @@ func (x *PersistentVolumeClaimList) codecDecodeSelfFromArray(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj541 int - var yyb541 bool - var yyhl541 bool = l >= 0 - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb541 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb541 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8911,15 +10401,21 @@ func (x *PersistentVolumeClaimList) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb541 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb541 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8927,38 +10423,44 @@ func (x *PersistentVolumeClaimList) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb541 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb541 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv544 := &x.ListMeta - yym545 := z.DecBinary() - _ = yym545 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv544) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv544, false) + z.DecFallback(yyv17, false) } } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb541 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb541 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -8966,26 +10468,26 @@ func (x *PersistentVolumeClaimList) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Items = nil } else { - yyv546 := &x.Items - yym547 := z.DecBinary() - _ = yym547 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv546), d) + h.decSlicePersistentVolumeClaim((*[]PersistentVolumeClaim)(yyv19), d) } } for { - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb541 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb541 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj541-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -8997,41 +10499,42 @@ func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym548 := z.EncBinary() - _ = yym548 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep549 := !z.EncBinary() - yy2arr549 := z.EncBasicHandle().StructToArray - var yyq549 [4]bool - _, _, _ = yysep549, yyq549, yy2arr549 - const yyr549 bool = false - yyq549[0] = len(x.AccessModes) != 0 - yyq549[1] = x.Selector != nil - yyq549[2] = true - yyq549[3] = x.VolumeName != "" - var yynn549 int - if yyr549 || yy2arr549 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.AccessModes) != 0 + yyq2[1] = x.Selector != nil + yyq2[2] = true + yyq2[3] = x.VolumeName != "" + yyq2[4] = x.StorageClassName != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) } else { - yynn549 = 0 - for _, b := range yyq549 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn549++ + yynn2++ } } - r.EncodeMapStart(yynn549) - yynn549 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr549 || yy2arr549 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[0] { + if yyq2[0] { if x.AccessModes == nil { r.EncodeNil() } else { - yym551 := z.EncBinary() - _ = yym551 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) @@ -9041,15 +10544,15 @@ func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq549[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("accessModes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.AccessModes == nil { r.EncodeNil() } else { - yym552 := z.EncBinary() - _ = yym552 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) @@ -9057,14 +10560,14 @@ func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr549 || yy2arr549 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[1] { + if yyq2[1] { if x.Selector == nil { r.EncodeNil() } else { - yym554 := z.EncBinary() - _ = yym554 + yym7 := z.EncBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -9075,15 +10578,15 @@ func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq549[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Selector == nil { r.EncodeNil() } else { - yym555 := z.EncBinary() - _ = yym555 + yym8 := z.EncBinary() + _ = yym8 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -9092,28 +10595,28 @@ func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr549 || yy2arr549 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[2] { - yy557 := &x.Resources - yy557.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.Resources + yy10.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq549[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resources")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy558 := &x.Resources - yy558.CodecEncodeSelf(e) + yy12 := &x.Resources + yy12.CodecEncodeSelf(e) } } - if yyr549 || yy2arr549 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[3] { - yym560 := z.EncBinary() - _ = yym560 + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) @@ -9122,19 +10625,54 @@ func (x *PersistentVolumeClaimSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq549[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumeName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym561 := z.EncBinary() - _ = yym561 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) } } } - if yyr549 || yy2arr549 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.StorageClassName == nil { + r.EncodeNil() + } else { + yy18 := *x.StorageClassName + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yy18)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageClassName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.StorageClassName == nil { + r.EncodeNil() + } else { + yy20 := *x.StorageClassName + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yy20)) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9147,25 +10685,25 @@ func (x *PersistentVolumeClaimSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym562 := z.DecBinary() - _ = yym562 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct563 := r.ContainerType() - if yyct563 == codecSelferValueTypeMap1234 { - yyl563 := r.ReadMapStart() - if yyl563 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl563, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct563 == codecSelferValueTypeArray1234 { - yyl563 := r.ReadArrayStart() - if yyl563 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl563, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9177,12 +10715,12 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromMap(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys564Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys564Slc - var yyhl564 bool = l >= 0 - for yyj564 := 0; ; yyj564++ { - if yyhl564 { - if yyj564 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9191,20 +10729,20 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys564Slc = r.DecodeBytes(yys564Slc, true, true) - yys564 := string(yys564Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys564 { + switch yys3 { case "accessModes": if r.TryDecodeAsNil() { x.AccessModes = nil } else { - yyv565 := &x.AccessModes - yym566 := z.DecBinary() - _ = yym566 + yyv4 := &x.AccessModes + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv565), d) + h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv4), d) } } case "selector": @@ -9214,10 +10752,10 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromMap(l int, d *codec1978.D } } else { if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) + x.Selector = new(pkg2_v1.LabelSelector) } - yym568 := z.DecBinary() - _ = yym568 + yym7 := z.DecBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { @@ -9228,19 +10766,41 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromMap(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Resources = ResourceRequirements{} } else { - yyv569 := &x.Resources - yyv569.CodecDecodeSelf(d) + yyv8 := &x.Resources + yyv8.CodecDecodeSelf(d) } case "volumeName": if r.TryDecodeAsNil() { x.VolumeName = "" } else { - x.VolumeName = string(r.DecodeString()) + yyv9 := &x.VolumeName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + case "storageClassName": + if r.TryDecodeAsNil() { + if x.StorageClassName != nil { + x.StorageClassName = nil + } + } else { + if x.StorageClassName == nil { + x.StorageClassName = new(string) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(x.StorageClassName)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys564) - } // end switch yys564 - } // end for yyj564 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -9248,16 +10808,16 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromArray(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj571 int - var yyb571 bool - var yyhl571 bool = l >= 0 - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb571 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb571 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9265,21 +10825,21 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.AccessModes = nil } else { - yyv572 := &x.AccessModes - yym573 := z.DecBinary() - _ = yym573 + yyv14 := &x.AccessModes + yym15 := z.DecBinary() + _ = yym15 if false { } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv572), d) + h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv14), d) } } - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb571 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb571 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9290,23 +10850,23 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromArray(l int, d *codec1978 } } else { if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) + x.Selector = new(pkg2_v1.LabelSelector) } - yym575 := z.DecBinary() - _ = yym575 + yym17 := z.DecBinary() + _ = yym17 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { z.DecFallback(x.Selector, false) } } - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb571 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb571 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9314,16 +10874,16 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Resources = ResourceRequirements{} } else { - yyv576 := &x.Resources - yyv576.CodecDecodeSelf(d) + yyv18 := &x.Resources + yyv18.CodecDecodeSelf(d) } - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb571 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb571 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9331,20 +10891,52 @@ func (x *PersistentVolumeClaimSpec) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.VolumeName = "" } else { - x.VolumeName = string(r.DecodeString()) + yyv19 := &x.VolumeName + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.StorageClassName != nil { + x.StorageClassName = nil + } + } else { + if x.StorageClassName == nil { + x.StorageClassName = new(string) + } + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(x.StorageClassName)) = r.DecodeString() + } } for { - yyj571++ - if yyhl571 { - yyb571 = yyj571 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb571 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb571 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj571-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -9356,55 +10948,55 @@ func (x *PersistentVolumeClaimStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym578 := z.EncBinary() - _ = yym578 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep579 := !z.EncBinary() - yy2arr579 := z.EncBasicHandle().StructToArray - var yyq579 [3]bool - _, _, _ = yysep579, yyq579, yy2arr579 - const yyr579 bool = false - yyq579[0] = x.Phase != "" - yyq579[1] = len(x.AccessModes) != 0 - yyq579[2] = len(x.Capacity) != 0 - var yynn579 int - if yyr579 || yy2arr579 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Phase != "" + yyq2[1] = len(x.AccessModes) != 0 + yyq2[2] = len(x.Capacity) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn579 = 0 - for _, b := range yyq579 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn579++ + yynn2++ } } - r.EncodeMapStart(yynn579) - yynn579 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr579 || yy2arr579 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq579[0] { + if yyq2[0] { x.Phase.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq579[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("phase")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Phase.CodecEncodeSelf(e) } } - if yyr579 || yy2arr579 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq579[1] { + if yyq2[1] { if x.AccessModes == nil { r.EncodeNil() } else { - yym582 := z.EncBinary() - _ = yym582 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) @@ -9414,15 +11006,15 @@ func (x *PersistentVolumeClaimStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq579[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("accessModes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.AccessModes == nil { r.EncodeNil() } else { - yym583 := z.EncBinary() - _ = yym583 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSlicePersistentVolumeAccessMode(([]PersistentVolumeAccessMode)(x.AccessModes), e) @@ -9430,9 +11022,9 @@ func (x *PersistentVolumeClaimStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr579 || yy2arr579 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq579[2] { + if yyq2[2] { if x.Capacity == nil { r.EncodeNil() } else { @@ -9442,7 +11034,7 @@ func (x *PersistentVolumeClaimStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq579[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("capacity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -9453,7 +11045,7 @@ func (x *PersistentVolumeClaimStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr579 || yy2arr579 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9466,25 +11058,25 @@ func (x *PersistentVolumeClaimStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym585 := z.DecBinary() - _ = yym585 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct586 := r.ContainerType() - if yyct586 == codecSelferValueTypeMap1234 { - yyl586 := r.ReadMapStart() - if yyl586 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl586, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct586 == codecSelferValueTypeArray1234 { - yyl586 := r.ReadArrayStart() - if yyl586 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl586, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9496,12 +11088,12 @@ func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromMap(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys587Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys587Slc - var yyhl587 bool = l >= 0 - for yyj587 := 0; ; yyj587++ { - if yyhl587 { - if yyj587 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9510,39 +11102,40 @@ func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys587Slc = r.DecodeBytes(yys587Slc, true, true) - yys587 := string(yys587Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys587 { + switch yys3 { case "phase": if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = PersistentVolumeClaimPhase(r.DecodeString()) + yyv4 := &x.Phase + yyv4.CodecDecodeSelf(d) } case "accessModes": if r.TryDecodeAsNil() { x.AccessModes = nil } else { - yyv589 := &x.AccessModes - yym590 := z.DecBinary() - _ = yym590 + yyv5 := &x.AccessModes + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv589), d) + h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv5), d) } } case "capacity": if r.TryDecodeAsNil() { x.Capacity = nil } else { - yyv591 := &x.Capacity - yyv591.CodecDecodeSelf(d) + yyv7 := &x.Capacity + yyv7.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys587) - } // end switch yys587 - } // end for yyj587 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -9550,16 +11143,16 @@ func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromArray(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj592 int - var yyb592 bool - var yyhl592 bool = l >= 0 - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb592 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb592 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9567,15 +11160,16 @@ func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = PersistentVolumeClaimPhase(r.DecodeString()) + yyv9 := &x.Phase + yyv9.CodecDecodeSelf(d) } - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb592 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb592 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9583,21 +11177,21 @@ func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.AccessModes = nil } else { - yyv594 := &x.AccessModes - yym595 := z.DecBinary() - _ = yym595 + yyv10 := &x.AccessModes + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv594), d) + h.decSlicePersistentVolumeAccessMode((*[]PersistentVolumeAccessMode)(yyv10), d) } } - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb592 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb592 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9605,21 +11199,21 @@ func (x *PersistentVolumeClaimStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Capacity = nil } else { - yyv596 := &x.Capacity - yyv596.CodecDecodeSelf(d) + yyv12 := &x.Capacity + yyv12.CodecDecodeSelf(d) } for { - yyj592++ - if yyhl592 { - yyb592 = yyj592 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb592 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb592 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj592-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -9628,8 +11222,8 @@ func (x PersistentVolumeAccessMode) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym597 := z.EncBinary() - _ = yym597 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -9641,8 +11235,8 @@ func (x *PersistentVolumeAccessMode) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym598 := z.DecBinary() - _ = yym598 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -9654,8 +11248,8 @@ func (x PersistentVolumePhase) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym599 := z.EncBinary() - _ = yym599 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -9667,8 +11261,8 @@ func (x *PersistentVolumePhase) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym600 := z.DecBinary() - _ = yym600 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -9680,8 +11274,8 @@ func (x PersistentVolumeClaimPhase) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym601 := z.EncBinary() - _ = yym601 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -9693,8 +11287,8 @@ func (x *PersistentVolumeClaimPhase) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym602 := z.DecBinary() - _ = yym602 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -9709,33 +11303,33 @@ func (x *HostPathVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym603 := z.EncBinary() - _ = yym603 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep604 := !z.EncBinary() - yy2arr604 := z.EncBasicHandle().StructToArray - var yyq604 [1]bool - _, _, _ = yysep604, yyq604, yy2arr604 - const yyr604 bool = false - var yynn604 int - if yyr604 || yy2arr604 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn604 = 1 - for _, b := range yyq604 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn604++ + yynn2++ } } - r.EncodeMapStart(yynn604) - yynn604 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr604 || yy2arr604 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym606 := z.EncBinary() - _ = yym606 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -9744,14 +11338,14 @@ func (x *HostPathVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym607 := z.EncBinary() - _ = yym607 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } - if yyr604 || yy2arr604 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9764,25 +11358,25 @@ func (x *HostPathVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym608 := z.DecBinary() - _ = yym608 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct609 := r.ContainerType() - if yyct609 == codecSelferValueTypeMap1234 { - yyl609 := r.ReadMapStart() - if yyl609 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl609, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct609 == codecSelferValueTypeArray1234 { - yyl609 := r.ReadArrayStart() - if yyl609 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl609, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9794,12 +11388,12 @@ func (x *HostPathVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys610Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys610Slc - var yyhl610 bool = l >= 0 - for yyj610 := 0; ; yyj610++ { - if yyhl610 { - if yyj610 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9808,20 +11402,26 @@ func (x *HostPathVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys610Slc = r.DecodeBytes(yys610Slc, true, true) - yys610 := string(yys610Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys610 { + switch yys3 { case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys610) - } // end switch yys610 - } // end for yyj610 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -9829,16 +11429,16 @@ func (x *HostPathVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj612 int - var yyb612 bool - var yyhl612 bool = l >= 0 - yyj612++ - if yyhl612 { - yyb612 = yyj612 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb612 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb612 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9846,20 +11446,26 @@ func (x *HostPathVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv7 := &x.Path + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } for { - yyj612++ - if yyhl612 { - yyb612 = yyj612 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb612 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb612 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj612-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -9871,46 +11477,80 @@ func (x *EmptyDirVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym614 := z.EncBinary() - _ = yym614 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep615 := !z.EncBinary() - yy2arr615 := z.EncBasicHandle().StructToArray - var yyq615 [1]bool - _, _, _ = yysep615, yyq615, yy2arr615 - const yyr615 bool = false - yyq615[0] = x.Medium != "" - var yynn615 int - if yyr615 || yy2arr615 { - r.EncodeArrayStart(1) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Medium != "" + yyq2[1] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn615 = 0 - for _, b := range yyq615 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn615++ + yynn2++ } } - r.EncodeMapStart(yynn615) - yynn615 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr615 || yy2arr615 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq615[0] { + if yyq2[0] { x.Medium.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq615[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("medium")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Medium.CodecEncodeSelf(e) } } - if yyr615 || yy2arr615 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yy7 := &x.SizeLimit + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("sizeLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.SizeLimit + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9923,25 +11563,25 @@ func (x *EmptyDirVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym617 := z.DecBinary() - _ = yym617 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct618 := r.ContainerType() - if yyct618 == codecSelferValueTypeMap1234 { - yyl618 := r.ReadMapStart() - if yyl618 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl618, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct618 == codecSelferValueTypeArray1234 { - yyl618 := r.ReadArrayStart() - if yyl618 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl618, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9953,12 +11593,12 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys619Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys619Slc - var yyhl619 bool = l >= 0 - for yyj619 := 0; ; yyj619++ { - if yyhl619 { - if yyj619 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9967,20 +11607,36 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys619Slc = r.DecodeBytes(yys619Slc, true, true) - yys619 := string(yys619Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys619 { + switch yys3 { case "medium": if r.TryDecodeAsNil() { x.Medium = "" } else { - x.Medium = StorageMedium(r.DecodeString()) + yyv4 := &x.Medium + yyv4.CodecDecodeSelf(d) + } + case "sizeLimit": + if r.TryDecodeAsNil() { + x.SizeLimit = pkg3_resource.Quantity{} + } else { + yyv5 := &x.SizeLimit + yym6 := z.DecBinary() + _ = yym6 + if false { + } else if z.HasExtensions() && z.DecExt(yyv5) { + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv5) + } else { + z.DecFallback(yyv5, false) + } } default: - z.DecStructFieldNotFound(-1, yys619) - } // end switch yys619 - } // end for yyj619 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -9988,16 +11644,16 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj621 int - var yyb621 bool - var yyhl621 bool = l >= 0 - yyj621++ - if yyhl621 { - yyb621 = yyj621 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb621 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb621 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10005,20 +11661,46 @@ func (x *EmptyDirVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Medium = "" } else { - x.Medium = StorageMedium(r.DecodeString()) + yyv8 := &x.Medium + yyv8.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SizeLimit = pkg3_resource.Quantity{} + } else { + yyv9 := &x.SizeLimit + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) + } else { + z.DecFallback(yyv9, false) + } } for { - yyj621++ - if yyhl621 { - yyb621 = yyj621 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb621 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb621 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj621-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -10030,34 +11712,34 @@ func (x *GlusterfsVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym623 := z.EncBinary() - _ = yym623 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep624 := !z.EncBinary() - yy2arr624 := z.EncBasicHandle().StructToArray - var yyq624 [3]bool - _, _, _ = yysep624, yyq624, yy2arr624 - const yyr624 bool = false - yyq624[2] = x.ReadOnly != false - var yynn624 int - if yyr624 || yy2arr624 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn624 = 2 - for _, b := range yyq624 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn624++ + yynn2++ } } - r.EncodeMapStart(yynn624) - yynn624 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr624 || yy2arr624 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym626 := z.EncBinary() - _ = yym626 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.EndpointsName)) @@ -10066,17 +11748,17 @@ func (x *GlusterfsVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("endpoints")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym627 := z.EncBinary() - _ = yym627 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.EndpointsName)) } } - if yyr624 || yy2arr624 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym629 := z.EncBinary() - _ = yym629 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -10085,18 +11767,18 @@ func (x *GlusterfsVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym630 := z.EncBinary() - _ = yym630 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } - if yyr624 || yy2arr624 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq624[2] { - yym632 := z.EncBinary() - _ = yym632 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -10105,19 +11787,19 @@ func (x *GlusterfsVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq624[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym633 := z.EncBinary() - _ = yym633 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr624 || yy2arr624 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -10130,25 +11812,25 @@ func (x *GlusterfsVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym634 := z.DecBinary() - _ = yym634 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct635 := r.ContainerType() - if yyct635 == codecSelferValueTypeMap1234 { - yyl635 := r.ReadMapStart() - if yyl635 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl635, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct635 == codecSelferValueTypeArray1234 { - yyl635 := r.ReadArrayStart() - if yyl635 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl635, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -10160,12 +11842,12 @@ func (x *GlusterfsVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys636Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys636Slc - var yyhl636 bool = l >= 0 - for yyj636 := 0; ; yyj636++ { - if yyhl636 { - if yyj636 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -10174,32 +11856,50 @@ func (x *GlusterfsVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys636Slc = r.DecodeBytes(yys636Slc, true, true) - yys636 := string(yys636Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys636 { + switch yys3 { case "endpoints": if r.TryDecodeAsNil() { x.EndpointsName = "" } else { - x.EndpointsName = string(r.DecodeString()) + yyv4 := &x.EndpointsName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv6 := &x.Path + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv8 := &x.ReadOnly + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys636) - } // end switch yys636 - } // end for yyj636 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -10207,16 +11907,16 @@ func (x *GlusterfsVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj640 int - var yyb640 bool - var yyhl640 bool = l >= 0 - yyj640++ - if yyhl640 { - yyb640 = yyj640 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb640 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb640 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10224,15 +11924,21 @@ func (x *GlusterfsVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.EndpointsName = "" } else { - x.EndpointsName = string(r.DecodeString()) + yyv11 := &x.EndpointsName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj640++ - if yyhl640 { - yyb640 = yyj640 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb640 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb640 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10240,15 +11946,21 @@ func (x *GlusterfsVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv13 := &x.Path + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj640++ - if yyhl640 { - yyb640 = yyj640 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb640 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb640 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10256,20 +11968,26 @@ func (x *GlusterfsVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv15 := &x.ReadOnly + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } } for { - yyj640++ - if yyhl640 { - yyb640 = yyj640 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb640 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb640 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj640-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -10281,42 +11999,42 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym644 := z.EncBinary() - _ = yym644 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep645 := !z.EncBinary() - yy2arr645 := z.EncBasicHandle().StructToArray - var yyq645 [8]bool - _, _, _ = yysep645, yyq645, yy2arr645 - const yyr645 bool = false - yyq645[2] = x.FSType != "" - yyq645[3] = x.RBDPool != "" - yyq645[4] = x.RadosUser != "" - yyq645[5] = x.Keyring != "" - yyq645[6] = x.SecretRef != nil - yyq645[7] = x.ReadOnly != false - var yynn645 int - if yyr645 || yy2arr645 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.FSType != "" + yyq2[3] = x.RBDPool != "" + yyq2[4] = x.RadosUser != "" + yyq2[5] = x.Keyring != "" + yyq2[6] = x.SecretRef != nil + yyq2[7] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(8) } else { - yynn645 = 2 - for _, b := range yyq645 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn645++ + yynn2++ } } - r.EncodeMapStart(yynn645) - yynn645 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.CephMonitors == nil { r.EncodeNil() } else { - yym647 := z.EncBinary() - _ = yym647 + yym4 := z.EncBinary() + _ = yym4 if false { } else { z.F.EncSliceStringV(x.CephMonitors, false, e) @@ -10329,18 +12047,18 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x.CephMonitors == nil { r.EncodeNil() } else { - yym648 := z.EncBinary() - _ = yym648 + yym5 := z.EncBinary() + _ = yym5 if false { } else { z.F.EncSliceStringV(x.CephMonitors, false, e) } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym650 := z.EncBinary() - _ = yym650 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.RBDImage)) @@ -10349,18 +12067,18 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("image")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym651 := z.EncBinary() - _ = yym651 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.RBDImage)) } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq645[2] { - yym653 := z.EncBinary() - _ = yym653 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) @@ -10369,23 +12087,23 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq645[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsType")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym654 := z.EncBinary() - _ = yym654 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq645[3] { - yym656 := z.EncBinary() - _ = yym656 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool)) @@ -10394,23 +12112,23 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq645[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("pool")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym657 := z.EncBinary() - _ = yym657 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.RBDPool)) } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq645[4] { - yym659 := z.EncBinary() - _ = yym659 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser)) @@ -10419,23 +12137,23 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq645[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("user")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym660 := z.EncBinary() - _ = yym660 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.RadosUser)) } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq645[5] { - yym662 := z.EncBinary() - _ = yym662 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Keyring)) @@ -10444,21 +12162,21 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq645[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("keyring")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym663 := z.EncBinary() - _ = yym663 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Keyring)) } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq645[6] { + if yyq2[6] { if x.SecretRef == nil { r.EncodeNil() } else { @@ -10468,7 +12186,7 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq645[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secretRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -10479,11 +12197,11 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq645[7] { - yym666 := z.EncBinary() - _ = yym666 + if yyq2[7] { + yym25 := z.EncBinary() + _ = yym25 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -10492,19 +12210,19 @@ func (x *RBDVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq645[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym667 := z.EncBinary() - _ = yym667 + yym26 := z.EncBinary() + _ = yym26 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr645 || yy2arr645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -10517,25 +12235,25 @@ func (x *RBDVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym668 := z.DecBinary() - _ = yym668 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct669 := r.ContainerType() - if yyct669 == codecSelferValueTypeMap1234 { - yyl669 := r.ReadMapStart() - if yyl669 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl669, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct669 == codecSelferValueTypeArray1234 { - yyl669 := r.ReadArrayStart() - if yyl669 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl669, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -10547,12 +12265,12 @@ func (x *RBDVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys670Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys670Slc - var yyhl670 bool = l >= 0 - for yyj670 := 0; ; yyj670++ { - if yyhl670 { - if yyj670 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -10561,51 +12279,81 @@ func (x *RBDVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys670Slc = r.DecodeBytes(yys670Slc, true, true) - yys670 := string(yys670Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys670 { + switch yys3 { case "monitors": if r.TryDecodeAsNil() { x.CephMonitors = nil } else { - yyv671 := &x.CephMonitors - yym672 := z.DecBinary() - _ = yym672 + yyv4 := &x.CephMonitors + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv671, false, d) + z.F.DecSliceStringX(yyv4, false, d) } } case "image": if r.TryDecodeAsNil() { x.RBDImage = "" } else { - x.RBDImage = string(r.DecodeString()) + yyv6 := &x.RBDImage + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "fsType": if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv8 := &x.FSType + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "pool": if r.TryDecodeAsNil() { x.RBDPool = "" } else { - x.RBDPool = string(r.DecodeString()) + yyv10 := &x.RBDPool + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "user": if r.TryDecodeAsNil() { x.RadosUser = "" } else { - x.RadosUser = string(r.DecodeString()) + yyv12 := &x.RadosUser + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "keyring": if r.TryDecodeAsNil() { x.Keyring = "" } else { - x.Keyring = string(r.DecodeString()) + yyv14 := &x.Keyring + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "secretRef": if r.TryDecodeAsNil() { @@ -10622,12 +12370,18 @@ func (x *RBDVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv17 := &x.ReadOnly + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*bool)(yyv17)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys670) - } // end switch yys670 - } // end for yyj670 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -10635,16 +12389,16 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj680 int - var yyb680 bool - var yyhl680 bool = l >= 0 - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + var yyj19 int + var yyb19 bool + var yyhl19 bool = l >= 0 + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10652,21 +12406,21 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.CephMonitors = nil } else { - yyv681 := &x.CephMonitors - yym682 := z.DecBinary() - _ = yym682 + yyv20 := &x.CephMonitors + yym21 := z.DecBinary() + _ = yym21 if false { } else { - z.F.DecSliceStringX(yyv681, false, d) + z.F.DecSliceStringX(yyv20, false, d) } } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10674,15 +12428,21 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.RBDImage = "" } else { - x.RBDImage = string(r.DecodeString()) + yyv22 := &x.RBDImage + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10690,15 +12450,21 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv24 := &x.FSType + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10706,15 +12472,21 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.RBDPool = "" } else { - x.RBDPool = string(r.DecodeString()) + yyv26 := &x.RBDPool + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10722,15 +12494,21 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.RadosUser = "" } else { - x.RadosUser = string(r.DecodeString()) + yyv28 := &x.RadosUser + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10738,15 +12516,21 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Keyring = "" } else { - x.Keyring = string(r.DecodeString()) + yyv30 := &x.Keyring + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10761,13 +12545,13 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) } x.SecretRef.CodecDecodeSelf(d) } - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -10775,20 +12559,26 @@ func (x *RBDVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv33 := &x.ReadOnly + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*bool)(yyv33)) = r.DecodeBool() + } } for { - yyj680++ - if yyhl680 { - yyb680 = yyj680 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb680 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb680 { + if yyb19 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj680-1, "") + z.DecStructFieldNotFound(yyj19-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -10800,35 +12590,35 @@ func (x *CinderVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym690 := z.EncBinary() - _ = yym690 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep691 := !z.EncBinary() - yy2arr691 := z.EncBasicHandle().StructToArray - var yyq691 [3]bool - _, _, _ = yysep691, yyq691, yy2arr691 - const yyr691 bool = false - yyq691[1] = x.FSType != "" - yyq691[2] = x.ReadOnly != false - var yynn691 int - if yyr691 || yy2arr691 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + yyq2[2] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn691 = 1 - for _, b := range yyq691 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn691++ + yynn2++ } } - r.EncodeMapStart(yynn691) - yynn691 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr691 || yy2arr691 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym693 := z.EncBinary() - _ = yym693 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) @@ -10837,18 +12627,18 @@ func (x *CinderVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumeID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym694 := z.EncBinary() - _ = yym694 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) } } - if yyr691 || yy2arr691 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq691[1] { - yym696 := z.EncBinary() - _ = yym696 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) @@ -10857,23 +12647,23 @@ func (x *CinderVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq691[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsType")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym697 := z.EncBinary() - _ = yym697 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) } } } - if yyr691 || yy2arr691 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq691[2] { - yym699 := z.EncBinary() - _ = yym699 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -10882,19 +12672,19 @@ func (x *CinderVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq691[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym700 := z.EncBinary() - _ = yym700 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr691 || yy2arr691 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -10907,25 +12697,25 @@ func (x *CinderVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym701 := z.DecBinary() - _ = yym701 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct702 := r.ContainerType() - if yyct702 == codecSelferValueTypeMap1234 { - yyl702 := r.ReadMapStart() - if yyl702 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl702, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct702 == codecSelferValueTypeArray1234 { - yyl702 := r.ReadArrayStart() - if yyl702 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl702, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -10937,12 +12727,12 @@ func (x *CinderVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys703Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys703Slc - var yyhl703 bool = l >= 0 - for yyj703 := 0; ; yyj703++ { - if yyhl703 { - if yyj703 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -10951,32 +12741,50 @@ func (x *CinderVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys703Slc = r.DecodeBytes(yys703Slc, true, true) - yys703 := string(yys703Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys703 { + switch yys3 { case "volumeID": if r.TryDecodeAsNil() { x.VolumeID = "" } else { - x.VolumeID = string(r.DecodeString()) + yyv4 := &x.VolumeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "fsType": if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv8 := &x.ReadOnly + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys703) - } // end switch yys703 - } // end for yyj703 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -10984,16 +12792,16 @@ func (x *CinderVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj707 int - var yyb707 bool - var yyhl707 bool = l >= 0 - yyj707++ - if yyhl707 { - yyb707 = yyj707 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb707 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb707 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11001,15 +12809,21 @@ func (x *CinderVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.VolumeID = "" } else { - x.VolumeID = string(r.DecodeString()) + yyv11 := &x.VolumeID + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj707++ - if yyhl707 { - yyb707 = yyj707 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb707 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb707 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11017,15 +12831,21 @@ func (x *CinderVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv13 := &x.FSType + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj707++ - if yyhl707 { - yyb707 = yyj707 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb707 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb707 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11033,20 +12853,26 @@ func (x *CinderVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv15 := &x.ReadOnly + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } } for { - yyj707++ - if yyhl707 { - yyb707 = yyj707 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb707 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb707 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj707-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -11058,41 +12884,41 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym711 := z.EncBinary() - _ = yym711 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep712 := !z.EncBinary() - yy2arr712 := z.EncBasicHandle().StructToArray - var yyq712 [6]bool - _, _, _ = yysep712, yyq712, yy2arr712 - const yyr712 bool = false - yyq712[1] = x.Path != "" - yyq712[2] = x.User != "" - yyq712[3] = x.SecretFile != "" - yyq712[4] = x.SecretRef != nil - yyq712[5] = x.ReadOnly != false - var yynn712 int - if yyr712 || yy2arr712 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Path != "" + yyq2[2] = x.User != "" + yyq2[3] = x.SecretFile != "" + yyq2[4] = x.SecretRef != nil + yyq2[5] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn712 = 1 - for _, b := range yyq712 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn712++ + yynn2++ } } - r.EncodeMapStart(yynn712) - yynn712 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Monitors == nil { r.EncodeNil() } else { - yym714 := z.EncBinary() - _ = yym714 + yym4 := z.EncBinary() + _ = yym4 if false { } else { z.F.EncSliceStringV(x.Monitors, false, e) @@ -11105,19 +12931,19 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x.Monitors == nil { r.EncodeNil() } else { - yym715 := z.EncBinary() - _ = yym715 + yym5 := z.EncBinary() + _ = yym5 if false { } else { z.F.EncSliceStringV(x.Monitors, false, e) } } } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq712[1] { - yym717 := z.EncBinary() - _ = yym717 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -11126,23 +12952,23 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq712[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym718 := z.EncBinary() - _ = yym718 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq712[2] { - yym720 := z.EncBinary() - _ = yym720 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) @@ -11151,23 +12977,23 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq712[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("user")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym721 := z.EncBinary() - _ = yym721 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) } } } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq712[3] { - yym723 := z.EncBinary() - _ = yym723 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile)) @@ -11176,21 +13002,21 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq712[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secretFile")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym724 := z.EncBinary() - _ = yym724 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SecretFile)) } } } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq712[4] { + if yyq2[4] { if x.SecretRef == nil { r.EncodeNil() } else { @@ -11200,7 +13026,7 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq712[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secretRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -11211,11 +13037,11 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq712[5] { - yym727 := z.EncBinary() - _ = yym727 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -11224,19 +13050,19 @@ func (x *CephFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq712[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym728 := z.EncBinary() - _ = yym728 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr712 || yy2arr712 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -11249,25 +13075,25 @@ func (x *CephFSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym729 := z.DecBinary() - _ = yym729 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct730 := r.ContainerType() - if yyct730 == codecSelferValueTypeMap1234 { - yyl730 := r.ReadMapStart() - if yyl730 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl730, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct730 == codecSelferValueTypeArray1234 { - yyl730 := r.ReadArrayStart() - if yyl730 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl730, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -11279,12 +13105,12 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys731Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys731Slc - var yyhl731 bool = l >= 0 - for yyj731 := 0; ; yyj731++ { - if yyhl731 { - if yyj731 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -11293,39 +13119,57 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys731Slc = r.DecodeBytes(yys731Slc, true, true) - yys731 := string(yys731Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys731 { + switch yys3 { case "monitors": if r.TryDecodeAsNil() { x.Monitors = nil } else { - yyv732 := &x.Monitors - yym733 := z.DecBinary() - _ = yym733 + yyv4 := &x.Monitors + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv732, false, d) + z.F.DecSliceStringX(yyv4, false, d) } } case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv6 := &x.Path + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "user": if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv8 := &x.User + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "secretFile": if r.TryDecodeAsNil() { x.SecretFile = "" } else { - x.SecretFile = string(r.DecodeString()) + yyv10 := &x.SecretFile + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "secretRef": if r.TryDecodeAsNil() { @@ -11342,12 +13186,18 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv13 := &x.ReadOnly + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*bool)(yyv13)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys731) - } // end switch yys731 - } // end for yyj731 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -11355,16 +13205,16 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj739 int - var yyb739 bool - var yyhl739 bool = l >= 0 - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11372,21 +13222,21 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Monitors = nil } else { - yyv740 := &x.Monitors - yym741 := z.DecBinary() - _ = yym741 + yyv16 := &x.Monitors + yym17 := z.DecBinary() + _ = yym17 if false { } else { - z.F.DecSliceStringX(yyv740, false, d) + z.F.DecSliceStringX(yyv16, false, d) } } - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11394,15 +13244,21 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv18 := &x.Path + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } } - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11410,15 +13266,21 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv20 := &x.User + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } } - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11426,15 +13288,21 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.SecretFile = "" } else { - x.SecretFile = string(r.DecodeString()) + yyv22 := &x.SecretFile + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } } - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11449,13 +13317,13 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode } x.SecretRef.CodecDecodeSelf(d) } - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11463,20 +13331,26 @@ func (x *CephFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv25 := &x.ReadOnly + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*bool)(yyv25)) = r.DecodeBool() + } } for { - yyj739++ - if yyhl739 { - yyb739 = yyj739 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb739 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb739 { + if yyb15 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj739-1, "") + z.DecStructFieldNotFound(yyj15-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -11488,36 +13362,36 @@ func (x *FlockerVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym747 := z.EncBinary() - _ = yym747 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep748 := !z.EncBinary() - yy2arr748 := z.EncBasicHandle().StructToArray - var yyq748 [2]bool - _, _, _ = yysep748, yyq748, yy2arr748 - const yyr748 bool = false - yyq748[0] = x.DatasetName != "" - yyq748[1] = x.DatasetUUID != "" - var yynn748 int - if yyr748 || yy2arr748 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.DatasetName != "" + yyq2[1] = x.DatasetUUID != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn748 = 0 - for _, b := range yyq748 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn748++ + yynn2++ } } - r.EncodeMapStart(yynn748) - yynn748 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr748 || yy2arr748 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq748[0] { - yym750 := z.EncBinary() - _ = yym750 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName)) @@ -11526,23 +13400,23 @@ func (x *FlockerVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq748[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("datasetName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym751 := z.EncBinary() - _ = yym751 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DatasetName)) } } } - if yyr748 || yy2arr748 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq748[1] { - yym753 := z.EncBinary() - _ = yym753 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DatasetUUID)) @@ -11551,19 +13425,19 @@ func (x *FlockerVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq748[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("datasetUUID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym754 := z.EncBinary() - _ = yym754 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DatasetUUID)) } } } - if yyr748 || yy2arr748 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -11576,25 +13450,25 @@ func (x *FlockerVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym755 := z.DecBinary() - _ = yym755 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct756 := r.ContainerType() - if yyct756 == codecSelferValueTypeMap1234 { - yyl756 := r.ReadMapStart() - if yyl756 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl756, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct756 == codecSelferValueTypeArray1234 { - yyl756 := r.ReadArrayStart() - if yyl756 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl756, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -11606,12 +13480,12 @@ func (x *FlockerVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys757Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys757Slc - var yyhl757 bool = l >= 0 - for yyj757 := 0; ; yyj757++ { - if yyhl757 { - if yyj757 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -11620,26 +13494,38 @@ func (x *FlockerVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys757Slc = r.DecodeBytes(yys757Slc, true, true) - yys757 := string(yys757Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys757 { + switch yys3 { case "datasetName": if r.TryDecodeAsNil() { x.DatasetName = "" } else { - x.DatasetName = string(r.DecodeString()) + yyv4 := &x.DatasetName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "datasetUUID": if r.TryDecodeAsNil() { x.DatasetUUID = "" } else { - x.DatasetUUID = string(r.DecodeString()) + yyv6 := &x.DatasetUUID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys757) - } // end switch yys757 - } // end for yyj757 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -11647,16 +13533,16 @@ func (x *FlockerVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj760 int - var yyb760 bool - var yyhl760 bool = l >= 0 - yyj760++ - if yyhl760 { - yyb760 = yyj760 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb760 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb760 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11664,15 +13550,21 @@ func (x *FlockerVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.DatasetName = "" } else { - x.DatasetName = string(r.DecodeString()) + yyv9 := &x.DatasetName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj760++ - if yyhl760 { - yyb760 = yyj760 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb760 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb760 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11680,20 +13572,26 @@ func (x *FlockerVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.DatasetUUID = "" } else { - x.DatasetUUID = string(r.DecodeString()) + yyv11 := &x.DatasetUUID + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj760++ - if yyhl760 { - yyb760 = yyj760 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb760 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb760 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj760-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -11702,8 +13600,8 @@ func (x StorageMedium) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym763 := z.EncBinary() - _ = yym763 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -11715,8 +13613,8 @@ func (x *StorageMedium) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym764 := z.DecBinary() - _ = yym764 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -11728,8 +13626,8 @@ func (x Protocol) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym765 := z.EncBinary() - _ = yym765 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -11741,8 +13639,8 @@ func (x *Protocol) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym766 := z.DecBinary() - _ = yym766 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -11757,36 +13655,36 @@ func (x *GCEPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym767 := z.EncBinary() - _ = yym767 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep768 := !z.EncBinary() - yy2arr768 := z.EncBasicHandle().StructToArray - var yyq768 [4]bool - _, _, _ = yysep768, yyq768, yy2arr768 - const yyr768 bool = false - yyq768[1] = x.FSType != "" - yyq768[2] = x.Partition != 0 - yyq768[3] = x.ReadOnly != false - var yynn768 int - if yyr768 || yy2arr768 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + yyq2[2] = x.Partition != 0 + yyq2[3] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn768 = 1 - for _, b := range yyq768 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn768++ + yynn2++ } } - r.EncodeMapStart(yynn768) - yynn768 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr768 || yy2arr768 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym770 := z.EncBinary() - _ = yym770 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.PDName)) @@ -11795,18 +13693,18 @@ func (x *GCEPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("pdName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym771 := z.EncBinary() - _ = yym771 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.PDName)) } } - if yyr768 || yy2arr768 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq768[1] { - yym773 := z.EncBinary() - _ = yym773 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) @@ -11815,23 +13713,23 @@ func (x *GCEPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq768[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsType")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym774 := z.EncBinary() - _ = yym774 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) } } } - if yyr768 || yy2arr768 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq768[2] { - yym776 := z.EncBinary() - _ = yym776 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.Partition)) @@ -11840,23 +13738,23 @@ func (x *GCEPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq768[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("partition")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym777 := z.EncBinary() - _ = yym777 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeInt(int64(x.Partition)) } } } - if yyr768 || yy2arr768 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq768[3] { - yym779 := z.EncBinary() - _ = yym779 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -11865,19 +13763,19 @@ func (x *GCEPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq768[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym780 := z.EncBinary() - _ = yym780 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr768 || yy2arr768 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -11890,25 +13788,25 @@ func (x *GCEPersistentDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym781 := z.DecBinary() - _ = yym781 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct782 := r.ContainerType() - if yyct782 == codecSelferValueTypeMap1234 { - yyl782 := r.ReadMapStart() - if yyl782 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl782, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct782 == codecSelferValueTypeArray1234 { - yyl782 := r.ReadArrayStart() - if yyl782 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl782, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -11920,12 +13818,12 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys783Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys783Slc - var yyhl783 bool = l >= 0 - for yyj783 := 0; ; yyj783++ { - if yyhl783 { - if yyj783 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -11934,38 +13832,62 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec19 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys783Slc = r.DecodeBytes(yys783Slc, true, true) - yys783 := string(yys783Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys783 { + switch yys3 { case "pdName": if r.TryDecodeAsNil() { x.PDName = "" } else { - x.PDName = string(r.DecodeString()) + yyv4 := &x.PDName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "fsType": if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "partition": if r.TryDecodeAsNil() { x.Partition = 0 } else { - x.Partition = int32(r.DecodeInt(32)) + yyv8 := &x.Partition + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv10 := &x.ReadOnly + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys783) - } // end switch yys783 - } // end for yyj783 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -11973,16 +13895,16 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj788 int - var yyb788 bool - var yyhl788 bool = l >= 0 - yyj788++ - if yyhl788 { - yyb788 = yyj788 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb788 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb788 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -11990,15 +13912,21 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec if r.TryDecodeAsNil() { x.PDName = "" } else { - x.PDName = string(r.DecodeString()) + yyv13 := &x.PDName + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj788++ - if yyhl788 { - yyb788 = yyj788 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb788 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb788 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12006,15 +13934,21 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv15 := &x.FSType + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj788++ - if yyhl788 { - yyb788 = yyj788 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb788 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb788 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12022,15 +13956,21 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec if r.TryDecodeAsNil() { x.Partition = 0 } else { - x.Partition = int32(r.DecodeInt(32)) + yyv17 := &x.Partition + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(yyv17)) = int32(r.DecodeInt(32)) + } } - yyj788++ - if yyhl788 { - yyb788 = yyj788 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb788 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb788 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12038,20 +13978,26 @@ func (x *GCEPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv19 := &x.ReadOnly + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } } for { - yyj788++ - if yyhl788 { - yyb788 = yyj788 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb788 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb788 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj788-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -12063,36 +14009,36 @@ func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym793 := z.EncBinary() - _ = yym793 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep794 := !z.EncBinary() - yy2arr794 := z.EncBasicHandle().StructToArray - var yyq794 [5]bool - _, _, _ = yysep794, yyq794, yy2arr794 - const yyr794 bool = false - yyq794[2] = x.ReadOnly != false - yyq794[3] = x.User != "" - yyq794[4] = x.Group != "" - var yynn794 int - if yyr794 || yy2arr794 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.ReadOnly != false + yyq2[3] = x.User != "" + yyq2[4] = x.Group != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn794 = 2 - for _, b := range yyq794 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn794++ + yynn2++ } } - r.EncodeMapStart(yynn794) - yynn794 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr794 || yy2arr794 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym796 := z.EncBinary() - _ = yym796 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Registry)) @@ -12101,17 +14047,17 @@ func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("registry")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym797 := z.EncBinary() - _ = yym797 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Registry)) } } - if yyr794 || yy2arr794 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym799 := z.EncBinary() - _ = yym799 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Volume)) @@ -12120,18 +14066,18 @@ func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volume")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym800 := z.EncBinary() - _ = yym800 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Volume)) } } - if yyr794 || yy2arr794 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq794[2] { - yym802 := z.EncBinary() - _ = yym802 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -12140,23 +14086,23 @@ func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq794[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym803 := z.EncBinary() - _ = yym803 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr794 || yy2arr794 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq794[3] { - yym805 := z.EncBinary() - _ = yym805 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) @@ -12165,23 +14111,23 @@ func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq794[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("user")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym806 := z.EncBinary() - _ = yym806 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) } } } - if yyr794 || yy2arr794 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq794[4] { - yym808 := z.EncBinary() - _ = yym808 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Group)) @@ -12190,19 +14136,19 @@ func (x *QuobyteVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq794[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("group")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym809 := z.EncBinary() - _ = yym809 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Group)) } } } - if yyr794 || yy2arr794 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -12215,25 +14161,25 @@ func (x *QuobyteVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym810 := z.DecBinary() - _ = yym810 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct811 := r.ContainerType() - if yyct811 == codecSelferValueTypeMap1234 { - yyl811 := r.ReadMapStart() - if yyl811 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl811, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct811 == codecSelferValueTypeArray1234 { - yyl811 := r.ReadArrayStart() - if yyl811 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl811, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -12245,12 +14191,12 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys812Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys812Slc - var yyhl812 bool = l >= 0 - for yyj812 := 0; ; yyj812++ { - if yyhl812 { - if yyj812 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -12259,44 +14205,74 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys812Slc = r.DecodeBytes(yys812Slc, true, true) - yys812 := string(yys812Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys812 { + switch yys3 { case "registry": if r.TryDecodeAsNil() { x.Registry = "" } else { - x.Registry = string(r.DecodeString()) + yyv4 := &x.Registry + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "volume": if r.TryDecodeAsNil() { x.Volume = "" } else { - x.Volume = string(r.DecodeString()) + yyv6 := &x.Volume + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv8 := &x.ReadOnly + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } } case "user": if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv10 := &x.User + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "group": if r.TryDecodeAsNil() { x.Group = "" } else { - x.Group = string(r.DecodeString()) + yyv12 := &x.Group + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys812) - } // end switch yys812 - } // end for yyj812 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -12304,16 +14280,16 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj818 int - var yyb818 bool - var yyhl818 bool = l >= 0 - yyj818++ - if yyhl818 { - yyb818 = yyj818 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb818 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb818 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12321,15 +14297,21 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Registry = "" } else { - x.Registry = string(r.DecodeString()) + yyv15 := &x.Registry + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj818++ - if yyhl818 { - yyb818 = yyj818 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb818 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb818 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12337,15 +14319,21 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Volume = "" } else { - x.Volume = string(r.DecodeString()) + yyv17 := &x.Volume + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj818++ - if yyhl818 { - yyb818 = yyj818 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb818 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb818 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12353,15 +14341,21 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv19 := &x.ReadOnly + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } } - yyj818++ - if yyhl818 { - yyb818 = yyj818 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb818 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb818 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12369,15 +14363,21 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv21 := &x.User + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj818++ - if yyhl818 { - yyb818 = yyj818 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb818 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb818 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12385,20 +14385,26 @@ func (x *QuobyteVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Group = "" } else { - x.Group = string(r.DecodeString()) + yyv23 := &x.Group + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } for { - yyj818++ - if yyhl818 { - yyb818 = yyj818 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb818 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb818 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj818-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -12410,37 +14416,37 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym824 := z.EncBinary() - _ = yym824 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep825 := !z.EncBinary() - yy2arr825 := z.EncBasicHandle().StructToArray - var yyq825 [5]bool - _, _, _ = yysep825, yyq825, yy2arr825 - const yyr825 bool = false - yyq825[1] = x.FSType != "" - yyq825[2] = x.SecretRef != nil - yyq825[3] = x.ReadOnly != false - yyq825[4] = len(x.Options) != 0 - var yynn825 int - if yyr825 || yy2arr825 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + yyq2[2] = x.SecretRef != nil + yyq2[3] = x.ReadOnly != false + yyq2[4] = len(x.Options) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn825 = 1 - for _, b := range yyq825 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn825++ + yynn2++ } } - r.EncodeMapStart(yynn825) - yynn825 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr825 || yy2arr825 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym827 := z.EncBinary() - _ = yym827 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Driver)) @@ -12449,18 +14455,18 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("driver")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym828 := z.EncBinary() - _ = yym828 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Driver)) } } - if yyr825 || yy2arr825 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq825[1] { - yym830 := z.EncBinary() - _ = yym830 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) @@ -12469,21 +14475,21 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq825[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsType")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym831 := z.EncBinary() - _ = yym831 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) } } } - if yyr825 || yy2arr825 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq825[2] { + if yyq2[2] { if x.SecretRef == nil { r.EncodeNil() } else { @@ -12493,7 +14499,7 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq825[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secretRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -12504,11 +14510,11 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr825 || yy2arr825 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq825[3] { - yym834 := z.EncBinary() - _ = yym834 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -12517,26 +14523,26 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq825[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym835 := z.EncBinary() - _ = yym835 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr825 || yy2arr825 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq825[4] { + if yyq2[4] { if x.Options == nil { r.EncodeNil() } else { - yym837 := z.EncBinary() - _ = yym837 + yym16 := z.EncBinary() + _ = yym16 if false { } else { z.F.EncMapStringStringV(x.Options, false, e) @@ -12546,15 +14552,15 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq825[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("options")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Options == nil { r.EncodeNil() } else { - yym838 := z.EncBinary() - _ = yym838 + yym17 := z.EncBinary() + _ = yym17 if false { } else { z.F.EncMapStringStringV(x.Options, false, e) @@ -12562,7 +14568,7 @@ func (x *FlexVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr825 || yy2arr825 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -12575,25 +14581,25 @@ func (x *FlexVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym839 := z.DecBinary() - _ = yym839 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct840 := r.ContainerType() - if yyct840 == codecSelferValueTypeMap1234 { - yyl840 := r.ReadMapStart() - if yyl840 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl840, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct840 == codecSelferValueTypeArray1234 { - yyl840 := r.ReadArrayStart() - if yyl840 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl840, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -12605,12 +14611,12 @@ func (x *FlexVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys841Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys841Slc - var yyhl841 bool = l >= 0 - for yyj841 := 0; ; yyj841++ { - if yyhl841 { - if yyj841 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -12619,21 +14625,33 @@ func (x *FlexVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys841Slc = r.DecodeBytes(yys841Slc, true, true) - yys841 := string(yys841Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys841 { + switch yys3 { case "driver": if r.TryDecodeAsNil() { x.Driver = "" } else { - x.Driver = string(r.DecodeString()) + yyv4 := &x.Driver + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "fsType": if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "secretRef": if r.TryDecodeAsNil() { @@ -12650,24 +14668,30 @@ func (x *FlexVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv9 := &x.ReadOnly + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } } case "options": if r.TryDecodeAsNil() { x.Options = nil } else { - yyv846 := &x.Options - yym847 := z.DecBinary() - _ = yym847 + yyv11 := &x.Options + yym12 := z.DecBinary() + _ = yym12 if false { } else { - z.F.DecMapStringStringX(yyv846, false, d) + z.F.DecMapStringStringX(yyv11, false, d) } } default: - z.DecStructFieldNotFound(-1, yys841) - } // end switch yys841 - } // end for yyj841 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -12675,16 +14699,16 @@ func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj848 int - var yyb848 bool - var yyhl848 bool = l >= 0 - yyj848++ - if yyhl848 { - yyb848 = yyj848 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb848 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb848 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12692,15 +14716,21 @@ func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Driver = "" } else { - x.Driver = string(r.DecodeString()) + yyv14 := &x.Driver + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj848++ - if yyhl848 { - yyb848 = yyj848 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb848 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb848 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12708,15 +14738,21 @@ func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv16 := &x.FSType + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } - yyj848++ - if yyhl848 { - yyb848 = yyj848 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb848 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb848 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12731,13 +14767,13 @@ func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) } x.SecretRef.CodecDecodeSelf(d) } - yyj848++ - if yyhl848 { - yyb848 = yyj848 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb848 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb848 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12745,15 +14781,21 @@ func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv19 := &x.ReadOnly + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } } - yyj848++ - if yyhl848 { - yyb848 = yyj848 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb848 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb848 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12761,26 +14803,26 @@ func (x *FlexVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Options = nil } else { - yyv853 := &x.Options - yym854 := z.DecBinary() - _ = yym854 + yyv21 := &x.Options + yym22 := z.DecBinary() + _ = yym22 if false { } else { - z.F.DecMapStringStringX(yyv853, false, d) + z.F.DecMapStringStringX(yyv21, false, d) } } for { - yyj848++ - if yyhl848 { - yyb848 = yyj848 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb848 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb848 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj848-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -12792,36 +14834,36 @@ func (x *AWSElasticBlockStoreVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) if x == nil { r.EncodeNil() } else { - yym855 := z.EncBinary() - _ = yym855 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep856 := !z.EncBinary() - yy2arr856 := z.EncBasicHandle().StructToArray - var yyq856 [4]bool - _, _, _ = yysep856, yyq856, yy2arr856 - const yyr856 bool = false - yyq856[1] = x.FSType != "" - yyq856[2] = x.Partition != 0 - yyq856[3] = x.ReadOnly != false - var yynn856 int - if yyr856 || yy2arr856 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + yyq2[2] = x.Partition != 0 + yyq2[3] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn856 = 1 - for _, b := range yyq856 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn856++ + yynn2++ } } - r.EncodeMapStart(yynn856) - yynn856 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr856 || yy2arr856 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym858 := z.EncBinary() - _ = yym858 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) @@ -12830,18 +14872,18 @@ func (x *AWSElasticBlockStoreVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumeID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym859 := z.EncBinary() - _ = yym859 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) } } - if yyr856 || yy2arr856 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq856[1] { - yym861 := z.EncBinary() - _ = yym861 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) @@ -12850,23 +14892,23 @@ func (x *AWSElasticBlockStoreVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq856[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsType")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym862 := z.EncBinary() - _ = yym862 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) } } } - if yyr856 || yy2arr856 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq856[2] { - yym864 := z.EncBinary() - _ = yym864 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.Partition)) @@ -12875,23 +14917,23 @@ func (x *AWSElasticBlockStoreVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) r.EncodeInt(0) } } else { - if yyq856[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("partition")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym865 := z.EncBinary() - _ = yym865 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeInt(int64(x.Partition)) } } } - if yyr856 || yy2arr856 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq856[3] { - yym867 := z.EncBinary() - _ = yym867 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -12900,19 +14942,19 @@ func (x *AWSElasticBlockStoreVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) r.EncodeBool(false) } } else { - if yyq856[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym868 := z.EncBinary() - _ = yym868 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr856 || yy2arr856 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -12925,25 +14967,25 @@ func (x *AWSElasticBlockStoreVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym869 := z.DecBinary() - _ = yym869 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct870 := r.ContainerType() - if yyct870 == codecSelferValueTypeMap1234 { - yyl870 := r.ReadMapStart() - if yyl870 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl870, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct870 == codecSelferValueTypeArray1234 { - yyl870 := r.ReadArrayStart() - if yyl870 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl870, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -12955,12 +14997,12 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromMap(l int, d *code var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys871Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys871Slc - var yyhl871 bool = l >= 0 - for yyj871 := 0; ; yyj871++ { - if yyhl871 { - if yyj871 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -12969,38 +15011,62 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromMap(l int, d *code } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys871Slc = r.DecodeBytes(yys871Slc, true, true) - yys871 := string(yys871Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys871 { + switch yys3 { case "volumeID": if r.TryDecodeAsNil() { x.VolumeID = "" } else { - x.VolumeID = string(r.DecodeString()) + yyv4 := &x.VolumeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "fsType": if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "partition": if r.TryDecodeAsNil() { x.Partition = 0 } else { - x.Partition = int32(r.DecodeInt(32)) + yyv8 := &x.Partition + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv10 := &x.ReadOnly + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys871) - } // end switch yys871 - } // end for yyj871 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13008,16 +15074,16 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromArray(l int, d *co var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj876 int - var yyb876 bool - var yyhl876 bool = l >= 0 - yyj876++ - if yyhl876 { - yyb876 = yyj876 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb876 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb876 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13025,15 +15091,21 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromArray(l int, d *co if r.TryDecodeAsNil() { x.VolumeID = "" } else { - x.VolumeID = string(r.DecodeString()) + yyv13 := &x.VolumeID + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj876++ - if yyhl876 { - yyb876 = yyj876 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb876 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb876 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13041,15 +15113,21 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromArray(l int, d *co if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv15 := &x.FSType + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj876++ - if yyhl876 { - yyb876 = yyj876 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb876 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb876 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13057,15 +15135,21 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromArray(l int, d *co if r.TryDecodeAsNil() { x.Partition = 0 } else { - x.Partition = int32(r.DecodeInt(32)) + yyv17 := &x.Partition + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(yyv17)) = int32(r.DecodeInt(32)) + } } - yyj876++ - if yyhl876 { - yyb876 = yyj876 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb876 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb876 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13073,20 +15157,26 @@ func (x *AWSElasticBlockStoreVolumeSource) codecDecodeSelfFromArray(l int, d *co if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv19 := &x.ReadOnly + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } } for { - yyj876++ - if yyhl876 { - yyb876 = yyj876 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb876 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb876 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj876-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -13098,35 +15188,35 @@ func (x *GitRepoVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym881 := z.EncBinary() - _ = yym881 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep882 := !z.EncBinary() - yy2arr882 := z.EncBasicHandle().StructToArray - var yyq882 [3]bool - _, _, _ = yysep882, yyq882, yy2arr882 - const yyr882 bool = false - yyq882[1] = x.Revision != "" - yyq882[2] = x.Directory != "" - var yynn882 int - if yyr882 || yy2arr882 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Revision != "" + yyq2[2] = x.Directory != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn882 = 1 - for _, b := range yyq882 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn882++ + yynn2++ } } - r.EncodeMapStart(yynn882) - yynn882 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr882 || yy2arr882 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym884 := z.EncBinary() - _ = yym884 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Repository)) @@ -13135,18 +15225,18 @@ func (x *GitRepoVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("repository")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym885 := z.EncBinary() - _ = yym885 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Repository)) } } - if yyr882 || yy2arr882 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq882[1] { - yym887 := z.EncBinary() - _ = yym887 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Revision)) @@ -13155,23 +15245,23 @@ func (x *GitRepoVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq882[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("revision")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym888 := z.EncBinary() - _ = yym888 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Revision)) } } } - if yyr882 || yy2arr882 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq882[2] { - yym890 := z.EncBinary() - _ = yym890 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Directory)) @@ -13180,19 +15270,19 @@ func (x *GitRepoVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq882[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("directory")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym891 := z.EncBinary() - _ = yym891 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Directory)) } } } - if yyr882 || yy2arr882 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13205,25 +15295,25 @@ func (x *GitRepoVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym892 := z.DecBinary() - _ = yym892 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct893 := r.ContainerType() - if yyct893 == codecSelferValueTypeMap1234 { - yyl893 := r.ReadMapStart() - if yyl893 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl893, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct893 == codecSelferValueTypeArray1234 { - yyl893 := r.ReadArrayStart() - if yyl893 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl893, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13235,12 +15325,12 @@ func (x *GitRepoVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys894Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys894Slc - var yyhl894 bool = l >= 0 - for yyj894 := 0; ; yyj894++ { - if yyhl894 { - if yyj894 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13249,32 +15339,50 @@ func (x *GitRepoVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys894Slc = r.DecodeBytes(yys894Slc, true, true) - yys894 := string(yys894Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys894 { + switch yys3 { case "repository": if r.TryDecodeAsNil() { x.Repository = "" } else { - x.Repository = string(r.DecodeString()) + yyv4 := &x.Repository + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "revision": if r.TryDecodeAsNil() { x.Revision = "" } else { - x.Revision = string(r.DecodeString()) + yyv6 := &x.Revision + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "directory": if r.TryDecodeAsNil() { x.Directory = "" } else { - x.Directory = string(r.DecodeString()) + yyv8 := &x.Directory + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys894) - } // end switch yys894 - } // end for yyj894 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13282,16 +15390,16 @@ func (x *GitRepoVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj898 int - var yyb898 bool - var yyhl898 bool = l >= 0 - yyj898++ - if yyhl898 { - yyb898 = yyj898 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb898 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb898 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13299,15 +15407,21 @@ func (x *GitRepoVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Repository = "" } else { - x.Repository = string(r.DecodeString()) + yyv11 := &x.Repository + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj898++ - if yyhl898 { - yyb898 = yyj898 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb898 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb898 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13315,15 +15429,21 @@ func (x *GitRepoVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Revision = "" } else { - x.Revision = string(r.DecodeString()) + yyv13 := &x.Revision + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj898++ - if yyhl898 { - yyb898 = yyj898 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb898 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb898 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13331,20 +15451,26 @@ func (x *GitRepoVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Directory = "" } else { - x.Directory = string(r.DecodeString()) + yyv15 := &x.Directory + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj898++ - if yyhl898 { - yyb898 = yyj898 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb898 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb898 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj898-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -13356,37 +15482,38 @@ func (x *SecretVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym902 := z.EncBinary() - _ = yym902 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep903 := !z.EncBinary() - yy2arr903 := z.EncBasicHandle().StructToArray - var yyq903 [3]bool - _, _, _ = yysep903, yyq903, yy2arr903 - const yyr903 bool = false - yyq903[0] = x.SecretName != "" - yyq903[1] = len(x.Items) != 0 - yyq903[2] = x.DefaultMode != nil - var yynn903 int - if yyr903 || yy2arr903 { - r.EncodeArrayStart(3) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.SecretName != "" + yyq2[1] = len(x.Items) != 0 + yyq2[2] = x.DefaultMode != nil + yyq2[3] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn903 = 0 - for _, b := range yyq903 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn903++ + yynn2++ } } - r.EncodeMapStart(yynn903) - yynn903 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr903 || yy2arr903 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq903[0] { - yym905 := z.EncBinary() - _ = yym905 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) @@ -13395,26 +15522,26 @@ func (x *SecretVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq903[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secretName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym906 := z.EncBinary() - _ = yym906 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) } } } - if yyr903 || yy2arr903 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq903[1] { + if yyq2[1] { if x.Items == nil { r.EncodeNil() } else { - yym908 := z.EncBinary() - _ = yym908 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) @@ -13424,15 +15551,15 @@ func (x *SecretVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq903[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("items")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Items == nil { r.EncodeNil() } else { - yym909 := z.EncBinary() - _ = yym909 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) @@ -13440,42 +15567,77 @@ func (x *SecretVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr903 || yy2arr903 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq903[2] { + if yyq2[2] { if x.DefaultMode == nil { r.EncodeNil() } else { - yy911 := *x.DefaultMode - yym912 := z.EncBinary() - _ = yym912 + yy10 := *x.DefaultMode + yym11 := z.EncBinary() + _ = yym11 if false { } else { - r.EncodeInt(int64(yy911)) + r.EncodeInt(int64(yy10)) } } } else { r.EncodeNil() } } else { - if yyq903[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.DefaultMode == nil { r.EncodeNil() } else { - yy913 := *x.DefaultMode - yym914 := z.EncBinary() - _ = yym914 + yy12 := *x.DefaultMode + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(yy12)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Optional == nil { + r.EncodeNil() + } else { + yy15 := *x.Optional + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(yy15)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("optional")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Optional == nil { + r.EncodeNil() + } else { + yy17 := *x.Optional + yym18 := z.EncBinary() + _ = yym18 if false { } else { - r.EncodeInt(int64(yy913)) + r.EncodeBool(bool(yy17)) } } } } - if yyr903 || yy2arr903 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13488,25 +15650,25 @@ func (x *SecretVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym915 := z.DecBinary() - _ = yym915 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct916 := r.ContainerType() - if yyct916 == codecSelferValueTypeMap1234 { - yyl916 := r.ReadMapStart() - if yyl916 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl916, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct916 == codecSelferValueTypeArray1234 { - yyl916 := r.ReadArrayStart() - if yyl916 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl916, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13518,12 +15680,12 @@ func (x *SecretVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys917Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys917Slc - var yyhl917 bool = l >= 0 - for yyj917 := 0; ; yyj917++ { - if yyhl917 { - if yyj917 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13532,26 +15694,32 @@ func (x *SecretVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys917Slc = r.DecodeBytes(yys917Slc, true, true) - yys917 := string(yys917Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys917 { + switch yys3 { case "secretName": if r.TryDecodeAsNil() { x.SecretName = "" } else { - x.SecretName = string(r.DecodeString()) + yyv4 := &x.SecretName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv919 := &x.Items - yym920 := z.DecBinary() - _ = yym920 + yyv6 := &x.Items + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv919), d) + h.decSliceKeyToPath((*[]KeyToPath)(yyv6), d) } } case "defaultMode": @@ -13563,17 +15731,33 @@ func (x *SecretVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if x.DefaultMode == nil { x.DefaultMode = new(int32) } - yym922 := z.DecBinary() - _ = yym922 + yym9 := z.DecBinary() + _ = yym9 if false { } else { *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) } } + case "optional": + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } + } else { + if x.Optional == nil { + x.Optional = new(bool) + } + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } + } default: - z.DecStructFieldNotFound(-1, yys917) - } // end switch yys917 - } // end for yyj917 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13581,16 +15765,16 @@ func (x *SecretVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj923 int - var yyb923 bool - var yyhl923 bool = l >= 0 - yyj923++ - if yyhl923 { - yyb923 = yyj923 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb923 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb923 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13598,15 +15782,21 @@ func (x *SecretVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.SecretName = "" } else { - x.SecretName = string(r.DecodeString()) + yyv13 := &x.SecretName + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj923++ - if yyhl923 { - yyb923 = yyj923 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb923 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb923 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13614,21 +15804,21 @@ func (x *SecretVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Items = nil } else { - yyv925 := &x.Items - yym926 := z.DecBinary() - _ = yym926 + yyv15 := &x.Items + yym16 := z.DecBinary() + _ = yym16 if false { } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv925), d) + h.decSliceKeyToPath((*[]KeyToPath)(yyv15), d) } } - yyj923++ - if yyhl923 { - yyb923 = yyj923 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb923 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb923 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13641,124 +15831,182 @@ func (x *SecretVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if x.DefaultMode == nil { x.DefaultMode = new(int32) } - yym928 := z.DecBinary() - _ = yym928 + yym18 := z.DecBinary() + _ = yym18 if false { } else { *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) } } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } + } else { + if x.Optional == nil { + x.Optional = new(bool) + } + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } + } for { - yyj923++ - if yyhl923 { - yyb923 = yyj923 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb923 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb923 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj923-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *NFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *SecretProjection) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym929 := z.EncBinary() - _ = yym929 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep930 := !z.EncBinary() - yy2arr930 := z.EncBasicHandle().StructToArray - var yyq930 [3]bool - _, _, _ = yysep930, yyq930, yy2arr930 - const yyr930 bool = false - yyq930[2] = x.ReadOnly != false - var yynn930 int - if yyr930 || yy2arr930 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = len(x.Items) != 0 + yyq2[2] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn930 = 2 - for _, b := range yyq930 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn930++ + yynn2++ } } - r.EncodeMapStart(yynn930) - yynn930 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr930 || yy2arr930 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym932 := z.EncBinary() - _ = yym932 - if false { + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Server)) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("server")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym933 := z.EncBinary() - _ = yym933 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Server)) + 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 yyr930 || yy2arr930 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym935 := z.EncBinary() - _ = yym935 - if false { + if yyq2[1] { + if x.Items == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) + } + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym936 := z.EncBinary() - _ = yym936 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) + } + } } } - if yyr930 || yy2arr930 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq930[2] { - yym938 := z.EncBinary() - _ = yym938 - if false { + if yyq2[2] { + if x.Optional == nil { + r.EncodeNil() } else { - r.EncodeBool(bool(x.ReadOnly)) + yy10 := *x.Optional + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(yy10)) + } } } else { - r.EncodeBool(false) + r.EncodeNil() } } else { - if yyq930[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + r.EncodeString(codecSelferC_UTF81234, string("optional")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym939 := z.EncBinary() - _ = yym939 - if false { + if x.Optional == nil { + r.EncodeNil() } else { - r.EncodeBool(bool(x.ReadOnly)) + yy12 := *x.Optional + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(yy12)) + } } } } - if yyr930 || yy2arr930 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13767,29 +16015,29 @@ func (x *NFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *NFSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *SecretProjection) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym940 := z.DecBinary() - _ = yym940 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct941 := r.ContainerType() - if yyct941 == codecSelferValueTypeMap1234 { - yyl941 := r.ReadMapStart() - if yyl941 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl941, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct941 == codecSelferValueTypeArray1234 { - yyl941 := r.ReadArrayStart() - if yyl941 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl941, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13797,16 +16045,16 @@ func (x *NFSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *NFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *SecretProjection) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys942Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys942Slc - var yyhl942 bool = l >= 0 - for yyj942 := 0; ; yyj942++ { - if yyhl942 { - if yyj942 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13815,251 +16063,224 @@ func (x *NFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys942Slc = r.DecodeBytes(yys942Slc, true, true) - yys942 := string(yys942Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys942 { - case "server": + switch yys3 { + case "name": if r.TryDecodeAsNil() { - x.Server = "" + x.Name = "" } else { - x.Server = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "path": + case "items": if r.TryDecodeAsNil() { - x.Path = "" + x.Items = nil } else { - x.Path = string(r.DecodeString()) + yyv6 := &x.Items + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceKeyToPath((*[]KeyToPath)(yyv6), d) + } } - case "readOnly": + case "optional": if r.TryDecodeAsNil() { - x.ReadOnly = false + if x.Optional != nil { + x.Optional = nil + } } else { - x.ReadOnly = bool(r.DecodeBool()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys942) - } // end switch yys942 - } // end for yyj942 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *NFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *SecretProjection) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj946 int - var yyb946 bool - var yyhl946 bool = l >= 0 - yyj946++ - if yyhl946 { - yyb946 = yyj946 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb946 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb946 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Server = "" + x.Name = "" } else { - x.Server = string(r.DecodeString()) + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj946++ - if yyhl946 { - yyb946 = yyj946 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb946 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb946 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Path = "" + x.Items = nil } else { - x.Path = string(r.DecodeString()) + yyv13 := &x.Items + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSliceKeyToPath((*[]KeyToPath)(yyv13), d) + } } - yyj946++ - if yyhl946 { - yyb946 = yyj946 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb946 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb946 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ReadOnly = false + if x.Optional != nil { + x.Optional = nil + } } else { - x.ReadOnly = bool(r.DecodeBool()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } for { - yyj946++ - if yyhl946 { - yyb946 = yyj946 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb946 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb946 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj946-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ISCSIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *NFSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym950 := z.EncBinary() - _ = yym950 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep951 := !z.EncBinary() - yy2arr951 := z.EncBasicHandle().StructToArray - var yyq951 [6]bool - _, _, _ = yysep951, yyq951, yy2arr951 - const yyr951 bool = false - yyq951[3] = x.ISCSIInterface != "" - yyq951[4] = x.FSType != "" - yyq951[5] = x.ReadOnly != false - var yynn951 int - if yyr951 || yy2arr951 { - r.EncodeArrayStart(6) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) } else { - yynn951 = 3 - for _, b := range yyq951 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn951++ + yynn2++ } } - r.EncodeMapStart(yynn951) - yynn951 = 0 - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym953 := z.EncBinary() - _ = yym953 - 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) - yym954 := z.EncBinary() - _ = yym954 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal)) - } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr951 || yy2arr951 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym956 := z.EncBinary() - _ = yym956 + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) + r.EncodeString(codecSelferC_UTF81234, string(x.Server)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iqn")) + r.EncodeString(codecSelferC_UTF81234, string("server")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym957 := z.EncBinary() - _ = yym957 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) + r.EncodeString(codecSelferC_UTF81234, string(x.Server)) } } - if yyr951 || yy2arr951 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym959 := z.EncBinary() - _ = yym959 + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeInt(int64(x.Lun)) + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lun")) + r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym960 := z.EncBinary() - _ = yym960 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeInt(int64(x.Lun)) - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[3] { - yym962 := z.EncBinary() - _ = yym962 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq951[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("iscsiInterface")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym963 := z.EncBinary() - _ = yym963 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) - } - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[4] { - yym965 := z.EncBinary() - _ = yym965 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq951[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym966 := z.EncBinary() - _ = yym966 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } - if yyr951 || yy2arr951 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[5] { - yym968 := z.EncBinary() - _ = yym968 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -14068,19 +16289,19 @@ func (x *ISCSIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq951[5] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym969 := z.EncBinary() - _ = yym969 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr951 || yy2arr951 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14089,29 +16310,29 @@ func (x *ISCSIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ISCSIVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *NFSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym970 := z.DecBinary() - _ = yym970 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct971 := r.ContainerType() - if yyct971 == codecSelferValueTypeMap1234 { - yyl971 := r.ReadMapStart() - if yyl971 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl971, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct971 == codecSelferValueTypeArray1234 { - yyl971 := r.ReadArrayStart() - if yyl971 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl971, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -14119,16 +16340,16 @@ func (x *ISCSIVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ISCSIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *NFSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys972Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys972Slc - var yyhl972 bool = l >= 0 - for yyj972 := 0; ; yyj972++ { - if yyhl972 { - if yyj972 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -14137,50 +16358,601 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys972Slc = r.DecodeBytes(yys972Slc, true, true) - yys972 := string(yys972Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys972 { - case "targetPortal": + switch yys3 { + case "server": if r.TryDecodeAsNil() { - x.TargetPortal = "" + x.Server = "" } else { - x.TargetPortal = string(r.DecodeString()) + yyv4 := &x.Server + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "iqn": + case "path": if r.TryDecodeAsNil() { - x.IQN = "" + x.Path = "" } else { - x.IQN = string(r.DecodeString()) + yyv6 := &x.Path + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - case "lun": + case "readOnly": if r.TryDecodeAsNil() { - x.Lun = 0 + x.ReadOnly = false } else { - x.Lun = int32(r.DecodeInt(32)) - } - case "iscsiInterface": + yyv8 := &x.ReadOnly + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NFSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Server = "" + } else { + yyv11 := &x.Server + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Path = "" + } else { + yyv13 := &x.Path + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv15 := &x.ReadOnly + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ISCSIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[3] = x.ISCSIInterface != "" + yyq2[4] = x.FSType != "" + yyq2[5] = x.ReadOnly != false + yyq2[6] = len(x.Portals) != 0 + yyq2[7] = x.DiscoveryCHAPAuth != false + yyq2[8] = x.SessionCHAPAuth != false + yyq2[9] = x.SecretRef != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetPortal")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.TargetPortal)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("iqn")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.IQN)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.Lun)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("lun")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.Lun)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("iscsiInterface")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ISCSIInterface)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + if x.Portals == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + z.F.EncSliceStringV(x.Portals, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("portals")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Portals == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + z.F.EncSliceStringV(x.Portals, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeBool(bool(x.DiscoveryCHAPAuth)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("chapAuthDiscovery")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeBool(bool(x.DiscoveryCHAPAuth)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[8] { + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeBool(bool(x.SessionCHAPAuth)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[8] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("chapAuthSession")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeBool(bool(x.SessionCHAPAuth)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[9] { + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[9] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("secretRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ISCSIVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ISCSIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "targetPortal": + if r.TryDecodeAsNil() { + x.TargetPortal = "" + } else { + yyv4 := &x.TargetPortal + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "iqn": + if r.TryDecodeAsNil() { + x.IQN = "" + } else { + yyv6 := &x.IQN + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "lun": + if r.TryDecodeAsNil() { + x.Lun = 0 + } else { + yyv8 := &x.Lun + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } + } + case "iscsiInterface": if r.TryDecodeAsNil() { x.ISCSIInterface = "" } else { - x.ISCSIInterface = string(r.DecodeString()) + yyv10 := &x.ISCSIInterface + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "fsType": if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv12 := &x.FSType + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv14 := &x.ReadOnly + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "portals": + if r.TryDecodeAsNil() { + x.Portals = nil + } else { + yyv16 := &x.Portals + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + z.F.DecSliceStringX(yyv16, false, d) + } + } + case "chapAuthDiscovery": + if r.TryDecodeAsNil() { + x.DiscoveryCHAPAuth = false + } else { + yyv18 := &x.DiscoveryCHAPAuth + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*bool)(yyv18)) = r.DecodeBool() + } + } + case "chapAuthSession": + if r.TryDecodeAsNil() { + x.SessionCHAPAuth = false + } else { + yyv20 := &x.SessionCHAPAuth + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } + } + 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) } default: - z.DecStructFieldNotFound(-1, yys972) - } // end switch yys972 - } // end for yyj972 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -14188,16 +16960,16 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj979 int - var yyb979 bool - var yyhl979 bool = l >= 0 - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + var yyj23 int + var yyb23 bool + var yyhl23 bool = l >= 0 + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14205,15 +16977,21 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.TargetPortal = "" } else { - x.TargetPortal = string(r.DecodeString()) + yyv24 := &x.TargetPortal + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } } - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14221,15 +16999,21 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.IQN = "" } else { - x.IQN = string(r.DecodeString()) + yyv26 := &x.IQN + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } } - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14237,15 +17021,21 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Lun = 0 } else { - x.Lun = int32(r.DecodeInt(32)) + yyv28 := &x.Lun + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*int32)(yyv28)) = int32(r.DecodeInt(32)) + } } - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14253,15 +17043,21 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.ISCSIInterface = "" } else { - x.ISCSIInterface = string(r.DecodeString()) + yyv30 := &x.ISCSIInterface + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } } - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14269,15 +17065,21 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv32 := &x.FSType + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*string)(yyv32)) = r.DecodeString() + } } - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14285,20 +17087,113 @@ func (x *ISCSIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv34 := &x.ReadOnly + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*bool)(yyv34)) = r.DecodeBool() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Portals = nil + } else { + yyv36 := &x.Portals + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + z.F.DecSliceStringX(yyv36, false, d) + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.DiscoveryCHAPAuth = false + } else { + yyv38 := &x.DiscoveryCHAPAuth + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*bool)(yyv38)) = r.DecodeBool() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SessionCHAPAuth = false + } else { + yyv40 := &x.SessionCHAPAuth + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*bool)(yyv40)) = r.DecodeBool() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.SecretRef != nil { + x.SecretRef = nil + } + } else { + if x.SecretRef == nil { + x.SecretRef = new(LocalObjectReference) + } + x.SecretRef.CodecDecodeSelf(d) } for { - yyj979++ - if yyhl979 { - yyb979 = yyj979 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb979 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb979 { + if yyb23 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj979-1, "") + z.DecStructFieldNotFound(yyj23-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -14310,38 +17205,38 @@ func (x *FCVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym986 := z.EncBinary() - _ = yym986 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep987 := !z.EncBinary() - yy2arr987 := z.EncBasicHandle().StructToArray - var yyq987 [4]bool - _, _, _ = yysep987, yyq987, yy2arr987 - const yyr987 bool = false - yyq987[2] = x.FSType != "" - yyq987[3] = x.ReadOnly != false - var yynn987 int - if yyr987 || yy2arr987 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.FSType != "" + yyq2[3] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn987 = 2 - for _, b := range yyq987 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn987++ + yynn2++ } } - r.EncodeMapStart(yynn987) - yynn987 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr987 || yy2arr987 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.TargetWWNs == nil { r.EncodeNil() } else { - yym989 := z.EncBinary() - _ = yym989 + yym4 := z.EncBinary() + _ = yym4 if false { } else { z.F.EncSliceStringV(x.TargetWWNs, false, e) @@ -14354,25 +17249,25 @@ func (x *FCVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x.TargetWWNs == nil { r.EncodeNil() } else { - yym990 := z.EncBinary() - _ = yym990 + yym5 := z.EncBinary() + _ = yym5 if false { } else { z.F.EncSliceStringV(x.TargetWWNs, false, e) } } } - if yyr987 || yy2arr987 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Lun == nil { r.EncodeNil() } else { - yy992 := *x.Lun - yym993 := z.EncBinary() - _ = yym993 + yy7 := *x.Lun + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeInt(int64(yy992)) + r.EncodeInt(int64(yy7)) } } } else { @@ -14382,20 +17277,20 @@ func (x *FCVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x.Lun == nil { r.EncodeNil() } else { - yy994 := *x.Lun - yym995 := z.EncBinary() - _ = yym995 + yy9 := *x.Lun + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeInt(int64(yy994)) + r.EncodeInt(int64(yy9)) } } } - if yyr987 || yy2arr987 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq987[2] { - yym997 := z.EncBinary() - _ = yym997 + if yyq2[2] { + yym12 := z.EncBinary() + _ = yym12 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) @@ -14404,23 +17299,23 @@ func (x *FCVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq987[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsType")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym998 := z.EncBinary() - _ = yym998 + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) } } } - if yyr987 || yy2arr987 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq987[3] { - yym1000 := z.EncBinary() - _ = yym1000 + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeBool(bool(x.ReadOnly)) @@ -14429,19 +17324,19 @@ func (x *FCVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq987[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1001 := z.EncBinary() - _ = yym1001 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr987 || yy2arr987 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14454,25 +17349,25 @@ func (x *FCVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1002 := z.DecBinary() - _ = yym1002 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1003 := r.ContainerType() - if yyct1003 == codecSelferValueTypeMap1234 { - yyl1003 := r.ReadMapStart() - if yyl1003 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1003, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1003 == codecSelferValueTypeArray1234 { - yyl1003 := r.ReadArrayStart() - if yyl1003 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1003, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -14484,12 +17379,12 @@ func (x *FCVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1004Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1004Slc - var yyhl1004 bool = l >= 0 - for yyj1004 := 0; ; yyj1004++ { - if yyhl1004 { - if yyj1004 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -14498,20 +17393,20 @@ func (x *FCVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1004Slc = r.DecodeBytes(yys1004Slc, true, true) - yys1004 := string(yys1004Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1004 { + switch yys3 { case "targetWWNs": if r.TryDecodeAsNil() { x.TargetWWNs = nil } else { - yyv1005 := &x.TargetWWNs - yym1006 := z.DecBinary() - _ = yym1006 + yyv4 := &x.TargetWWNs + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv1005, false, d) + z.F.DecSliceStringX(yyv4, false, d) } } case "lun": @@ -14523,8 +17418,8 @@ func (x *FCVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Lun == nil { x.Lun = new(int32) } - yym1008 := z.DecBinary() - _ = yym1008 + yym7 := z.DecBinary() + _ = yym7 if false { } else { *((*int32)(x.Lun)) = int32(r.DecodeInt(32)) @@ -14534,18 +17429,30 @@ func (x *FCVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv8 := &x.FSType + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "readOnly": if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv10 := &x.ReadOnly + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys1004) - } // end switch yys1004 - } // end for yyj1004 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -14553,16 +17460,16 @@ func (x *FCVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1011 int - var yyb1011 bool - var yyhl1011 bool = l >= 0 - yyj1011++ - if yyhl1011 { - yyb1011 = yyj1011 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1011 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1011 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14570,21 +17477,21 @@ func (x *FCVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TargetWWNs = nil } else { - yyv1012 := &x.TargetWWNs - yym1013 := z.DecBinary() - _ = yym1013 + yyv13 := &x.TargetWWNs + yym14 := z.DecBinary() + _ = yym14 if false { } else { - z.F.DecSliceStringX(yyv1012, false, d) + z.F.DecSliceStringX(yyv13, false, d) } } - yyj1011++ - if yyhl1011 { - yyb1011 = yyj1011 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1011 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1011 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14597,20 +17504,20 @@ func (x *FCVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Lun == nil { x.Lun = new(int32) } - yym1015 := z.DecBinary() - _ = yym1015 + yym16 := z.DecBinary() + _ = yym16 if false { } else { *((*int32)(x.Lun)) = int32(r.DecodeInt(32)) } } - yyj1011++ - if yyhl1011 { - yyb1011 = yyj1011 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1011 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1011 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14618,15 +17525,21 @@ func (x *FCVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.FSType = "" } else { - x.FSType = string(r.DecodeString()) + yyv17 := &x.FSType + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj1011++ - if yyhl1011 { - yyb1011 = yyj1011 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1011 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1011 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14634,20 +17547,26 @@ func (x *FCVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ReadOnly = false } else { - x.ReadOnly = bool(r.DecodeBool()) + yyv19 := &x.ReadOnly + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(yyv19)) = r.DecodeBool() + } } for { - yyj1011++ - if yyhl1011 { - yyb1011 = yyj1011 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1011 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1011 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1011-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -14659,94 +17578,4344 @@ func (x *AzureFileVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1018 := z.EncBinary() - _ = yym1018 + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("secretName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ShareName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("shareName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ShareName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *AzureFileVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *AzureFileVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "secretName": + if r.TryDecodeAsNil() { + x.SecretName = "" + } else { + yyv4 := &x.SecretName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "shareName": + if r.TryDecodeAsNil() { + x.ShareName = "" + } else { + yyv6 := &x.ShareName + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "readOnly": + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv8 := &x.ReadOnly + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *AzureFileVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SecretName = "" + } else { + yyv11 := &x.SecretName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ShareName = "" + } else { + yyv13 := &x.ShareName + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv15 := &x.ReadOnly + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *VsphereVirtualDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + yyq2[2] = x.StoragePolicyName != "" + yyq2[3] = x.StoragePolicyID != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumePath")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StoragePolicyName)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storagePolicyName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StoragePolicyName)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StoragePolicyID)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storagePolicyID")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StoragePolicyID)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *VsphereVirtualDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "volumePath": + if r.TryDecodeAsNil() { + x.VolumePath = "" + } else { + yyv4 := &x.VolumePath + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "fsType": + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "storagePolicyName": + if r.TryDecodeAsNil() { + x.StoragePolicyName = "" + } else { + yyv8 := &x.StoragePolicyName + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "storagePolicyID": + if r.TryDecodeAsNil() { + x.StoragePolicyID = "" + } else { + yyv10 := &x.StoragePolicyID + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumePath = "" + } else { + yyv13 := &x.VolumePath + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv15 := &x.FSType + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.StoragePolicyName = "" + } else { + yyv17 := &x.StoragePolicyName + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.StoragePolicyID = "" + } else { + yyv19 := &x.StoragePolicyID + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PhotonPersistentDiskVolumeSource) 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 { - yysep1019 := !z.EncBinary() - yy2arr1019 := z.EncBasicHandle().StructToArray - var yyq1019 [3]bool - _, _, _ = yysep1019, yyq1019, yy2arr1019 - const yyr1019 bool = false - yyq1019[2] = x.ReadOnly != false - var yynn1019 int - if yyr1019 || yy2arr1019 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.PdID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("pdID")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.PdID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PhotonPersistentDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "pdID": + if r.TryDecodeAsNil() { + x.PdID = "" + } else { + yyv4 := &x.PdID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "fsType": + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.PdID = "" + } else { + yyv9 := &x.PdID + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv11 := &x.FSType + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x AzureDataDiskCachingMode) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *AzureDataDiskCachingMode) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x AzureDataDiskKind) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *AzureDataDiskKind) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *AzureDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.CachingMode != nil + yyq2[3] = x.FSType != nil + yyq2[4] = x.ReadOnly != nil + yyq2[5] = x.Kind != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + 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) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.DiskName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + 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) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.DataDiskURI)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.CachingMode == nil { + r.EncodeNil() + } else { + yy10 := *x.CachingMode + yy10.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("cachingMode")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CachingMode == nil { + r.EncodeNil() + } else { + yy12 := *x.CachingMode + yy12.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.FSType == nil { + r.EncodeNil() + } else { + yy15 := *x.FSType + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yy15)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FSType == nil { + r.EncodeNil() + } else { + yy17 := *x.FSType + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yy17)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.ReadOnly == nil { + r.EncodeNil() + } else { + yy20 := *x.ReadOnly + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeBool(bool(yy20)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ReadOnly == nil { + r.EncodeNil() + } else { + yy22 := *x.ReadOnly + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeBool(bool(yy22)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + if x.Kind == nil { + r.EncodeNil() + } else { + yy25 := *x.Kind + yy25.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Kind == nil { + r.EncodeNil() + } else { + yy27 := *x.Kind + yy27.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + 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 + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *AzureDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "diskName": + if r.TryDecodeAsNil() { + x.DiskName = "" + } else { + yyv4 := &x.DiskName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "diskURI": + if r.TryDecodeAsNil() { + x.DataDiskURI = "" + } else { + yyv6 := &x.DataDiskURI + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = 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) + } + yym10 := z.DecBinary() + _ = yym10 + 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) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(x.ReadOnly)) = r.DecodeBool() + } + } + case "kind": + if r.TryDecodeAsNil() { + if x.Kind != nil { + x.Kind = nil + } + } else { + if x.Kind == nil { + x.Kind = new(AzureDataDiskKind) + } + x.Kind.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + 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 yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.DiskName = "" + } else { + yyv15 := &x.DiskName + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.DataDiskURI = "" + } else { + yyv17 := &x.DataDiskURI + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.CachingMode != nil { + x.CachingMode = nil + } + } else { + if x.CachingMode == nil { + x.CachingMode = new(AzureDataDiskCachingMode) + } + x.CachingMode.CodecDecodeSelf(d) + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FSType != nil { + x.FSType = nil + } + } else { + if x.FSType == nil { + x.FSType = new(string) + } + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(x.FSType)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ReadOnly != nil { + x.ReadOnly = nil + } + } else { + if x.ReadOnly == nil { + x.ReadOnly = new(bool) + } + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*bool)(x.ReadOnly)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Kind != nil { + x.Kind = nil + } + } else { + if x.Kind == nil { + x.Kind = new(AzureDataDiskKind) + } + x.Kind.CodecDecodeSelf(d) + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PortworxVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FSType != "" + yyq2[2] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeID")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeID)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PortworxVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PortworxVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "volumeID": + if r.TryDecodeAsNil() { + x.VolumeID = "" + } else { + yyv4 := &x.VolumeID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "fsType": + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv6 := &x.FSType + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "readOnly": + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv8 := &x.ReadOnly + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PortworxVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeID = "" + } else { + yyv11 := &x.VolumeID + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv13 := &x.FSType + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv15 := &x.ReadOnly + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(yyv15)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ScaleIOVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[3] = x.SSLEnabled != false + yyq2[4] = x.ProtectionDomain != "" + yyq2[5] = x.StoragePool != "" + yyq2[6] = x.StorageMode != "" + yyq2[7] = x.VolumeName != "" + yyq2[8] = x.FSType != "" + yyq2[9] = x.ReadOnly != false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Gateway)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("gateway")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Gateway)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.System)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("system")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.System)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("secretRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.SSLEnabled)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("sslEnabled")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.SSLEnabled)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ProtectionDomain)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("protectionDomain")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ProtectionDomain)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StoragePool)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storagePool")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StoragePool)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StorageMode)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("storageMode")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.StorageMode)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[8] { + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[8] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[9] { + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[9] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ScaleIOVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ScaleIOVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "gateway": + if r.TryDecodeAsNil() { + x.Gateway = "" + } else { + yyv4 := &x.Gateway + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "system": + if r.TryDecodeAsNil() { + x.System = "" + } else { + yyv6 := &x.System + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = 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 "sslEnabled": + if r.TryDecodeAsNil() { + x.SSLEnabled = false + } else { + yyv9 := &x.SSLEnabled + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*bool)(yyv9)) = r.DecodeBool() + } + } + case "protectionDomain": + if r.TryDecodeAsNil() { + x.ProtectionDomain = "" + } else { + yyv11 := &x.ProtectionDomain + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + case "storagePool": + if r.TryDecodeAsNil() { + x.StoragePool = "" + } else { + yyv13 := &x.StoragePool + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + case "storageMode": + if r.TryDecodeAsNil() { + x.StorageMode = "" + } else { + yyv15 := &x.StorageMode + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + case "volumeName": + if r.TryDecodeAsNil() { + x.VolumeName = "" + } else { + yyv17 := &x.VolumeName + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + case "fsType": + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv19 := &x.FSType + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + case "readOnly": + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv21 := &x.ReadOnly + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ScaleIOVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj23 int + var yyb23 bool + var yyhl23 bool = l >= 0 + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Gateway = "" + } else { + yyv24 := &x.Gateway + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.System = "" + } else { + yyv26 := &x.System + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.SecretRef != nil { + x.SecretRef = nil + } + } else { + if x.SecretRef == nil { + x.SecretRef = new(LocalObjectReference) + } + x.SecretRef.CodecDecodeSelf(d) + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SSLEnabled = false + } else { + yyv29 := &x.SSLEnabled + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*bool)(yyv29)) = r.DecodeBool() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ProtectionDomain = "" + } else { + yyv31 := &x.ProtectionDomain + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.StoragePool = "" + } else { + yyv33 := &x.StoragePool + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.StorageMode = "" + } else { + yyv35 := &x.StorageMode + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeName = "" + } else { + yyv37 := &x.VolumeName + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv39 := &x.FSType + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv41 := &x.ReadOnly + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*bool)(yyv41)) = r.DecodeBool() + } + } + for { + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj23-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *StorageOSVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.VolumeName != "" + yyq2[1] = x.VolumeNamespace != "" + yyq2[2] = x.FSType != "" + yyq2[3] = x.ReadOnly != false + yyq2[4] = x.SecretRef != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeNamespace)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeNamespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeNamespace)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("secretRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StorageOSVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StorageOSVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "volumeName": + if r.TryDecodeAsNil() { + x.VolumeName = "" + } else { + yyv4 := &x.VolumeName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "volumeNamespace": + if r.TryDecodeAsNil() { + x.VolumeNamespace = "" + } else { + yyv6 := &x.VolumeNamespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "fsType": + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv8 := &x.FSType + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "readOnly": + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv10 := &x.ReadOnly + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + 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) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StorageOSVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeName = "" + } else { + yyv14 := &x.VolumeName + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeNamespace = "" + } else { + yyv16 := &x.VolumeNamespace + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv18 := &x.FSType + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv20 := &x.ReadOnly + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.SecretRef != nil { + x.SecretRef = nil + } + } else { + if x.SecretRef == nil { + x.SecretRef = new(LocalObjectReference) + } + x.SecretRef.CodecDecodeSelf(d) + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *StorageOSPersistentVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.VolumeName != "" + yyq2[1] = x.VolumeNamespace != "" + yyq2[2] = x.FSType != "" + yyq2[3] = x.ReadOnly != false + yyq2[4] = x.SecretRef != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeName)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeNamespace)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeNamespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.VolumeNamespace)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("fsType")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeBool(bool(x.ReadOnly)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("secretRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.SecretRef == nil { + r.EncodeNil() + } else { + x.SecretRef.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StorageOSPersistentVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StorageOSPersistentVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "volumeName": + if r.TryDecodeAsNil() { + x.VolumeName = "" + } else { + yyv4 := &x.VolumeName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "volumeNamespace": + if r.TryDecodeAsNil() { + x.VolumeNamespace = "" + } else { + yyv6 := &x.VolumeNamespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "fsType": + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv8 := &x.FSType + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "readOnly": + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv10 := &x.ReadOnly + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + case "secretRef": + if r.TryDecodeAsNil() { + if x.SecretRef != nil { + x.SecretRef = nil + } + } else { + if x.SecretRef == nil { + x.SecretRef = new(ObjectReference) + } + x.SecretRef.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StorageOSPersistentVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeName = "" + } else { + yyv14 := &x.VolumeName + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeNamespace = "" + } else { + yyv16 := &x.VolumeNamespace + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.FSType = "" + } else { + yyv18 := &x.FSType + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadOnly = false + } else { + yyv20 := &x.ReadOnly + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.SecretRef != nil { + x.SecretRef = nil + } + } else { + if x.SecretRef == nil { + x.SecretRef = new(ObjectReference) + } + x.SecretRef.CodecDecodeSelf(d) + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ConfigMapVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = len(x.Items) != 0 + yyq2[2] = x.DefaultMode != nil + yyq2[3] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + 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] { + if x.Items == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.DefaultMode == nil { + r.EncodeNil() + } else { + yy10 := *x.DefaultMode + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(yy10)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.DefaultMode == nil { + r.EncodeNil() + } else { + yy12 := *x.DefaultMode + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(yy12)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Optional == nil { + r.EncodeNil() + } else { + yy15 := *x.Optional + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(yy15)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("optional")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Optional == nil { + r.EncodeNil() + } else { + yy17 := *x.Optional + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeBool(bool(yy17)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ConfigMapVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ConfigMapVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv6 := &x.Items + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceKeyToPath((*[]KeyToPath)(yyv6), d) + } + } + case "defaultMode": + if r.TryDecodeAsNil() { + if x.DefaultMode != nil { + x.DefaultMode = nil + } + } else { + if x.DefaultMode == nil { + x.DefaultMode = new(int32) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) + } + } + case "optional": + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } + } else { + if x.Optional == nil { + x.Optional = new(bool) + } + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ConfigMapVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv13 := &x.Name + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv15 := &x.Items + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + h.decSliceKeyToPath((*[]KeyToPath)(yyv15), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.DefaultMode != nil { + x.DefaultMode = nil + } + } else { + if x.DefaultMode == nil { + x.DefaultMode = new(int32) + } + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } + } else { + if x.Optional == nil { + x.Optional = new(bool) + } + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ConfigMapProjection) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = len(x.Items) != 0 + yyq2[2] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + 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] { + if x.Items == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Optional == nil { + r.EncodeNil() + } else { + yy10 := *x.Optional + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(yy10)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("optional")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Optional == nil { + r.EncodeNil() + } else { + yy12 := *x.Optional + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(yy12)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ConfigMapProjection) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ConfigMapProjection) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv6 := &x.Items + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceKeyToPath((*[]KeyToPath)(yyv6), d) + } + } + case "optional": + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } + } else { + if x.Optional == nil { + x.Optional = new(bool) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ConfigMapProjection) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv13 := &x.Items + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSliceKeyToPath((*[]KeyToPath)(yyv13), d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } + } else { + if x.Optional == nil { + x.Optional = new(bool) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ProjectedVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.DefaultMode != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Sources == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceVolumeProjection(([]VolumeProjection)(x.Sources), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("sources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Sources == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceVolumeProjection(([]VolumeProjection)(x.Sources), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.DefaultMode == nil { + r.EncodeNil() + } else { + yy7 := *x.DefaultMode + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(yy7)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.DefaultMode == nil { + r.EncodeNil() + } else { + yy9 := *x.DefaultMode + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(yy9)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ProjectedVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ProjectedVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "sources": + if r.TryDecodeAsNil() { + x.Sources = nil + } else { + yyv4 := &x.Sources + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceVolumeProjection((*[]VolumeProjection)(yyv4), d) + } + } + case "defaultMode": + if r.TryDecodeAsNil() { + if x.DefaultMode != nil { + x.DefaultMode = nil + } + } else { + if x.DefaultMode == nil { + x.DefaultMode = new(int32) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ProjectedVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Sources = nil + } else { + yyv9 := &x.Sources + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSliceVolumeProjection((*[]VolumeProjection)(yyv9), d) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.DefaultMode != nil { + x.DefaultMode = nil + } + } else { + if x.DefaultMode == nil { + x.DefaultMode = new(int32) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *VolumeProjection) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Secret != nil + yyq2[1] = x.DownwardAPI != nil + yyq2[2] = x.ConfigMap != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1019 = 2 - for _, b := range yyq1019 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1019++ + yynn2++ } } - r.EncodeMapStart(yynn1019) - yynn1019 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1019 || yy2arr1019 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1021 := z.EncBinary() - _ = yym1021 - if false { + if yyq2[0] { + if x.Secret == nil { + r.EncodeNil() + } else { + x.Secret.CodecEncodeSelf(e) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1022 := z.EncBinary() - _ = yym1022 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) + if yyq2[0] { + 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 yyr1019 || yy2arr1019 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1024 := z.EncBinary() - _ = yym1024 - if false { + if yyq2[1] { + if x.DownwardAPI == nil { + r.EncodeNil() + } else { + x.DownwardAPI.CodecEncodeSelf(e) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ShareName)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("shareName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1025 := z.EncBinary() - _ = yym1025 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ShareName)) + if yyq2[1] { + 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 yyr1019 || yy2arr1019 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1019[2] { - yym1027 := z.EncBinary() - _ = yym1027 - if false { + if yyq2[2] { + if x.ConfigMap == nil { + r.EncodeNil() } else { - r.EncodeBool(bool(x.ReadOnly)) + x.ConfigMap.CodecEncodeSelf(e) } } else { - r.EncodeBool(false) + r.EncodeNil() } } else { - if yyq1019[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + r.EncodeString(codecSelferC_UTF81234, string("configMap")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1028 := z.EncBinary() - _ = yym1028 - if false { + if x.ConfigMap == nil { + r.EncodeNil() } else { - r.EncodeBool(bool(x.ReadOnly)) + x.ConfigMap.CodecEncodeSelf(e) } } } - if yyr1019 || yy2arr1019 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14755,29 +21924,29 @@ func (x *AzureFileVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *AzureFileVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *VolumeProjection) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1029 := z.DecBinary() - _ = yym1029 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1030 := r.ContainerType() - if yyct1030 == codecSelferValueTypeMap1234 { - yyl1030 := r.ReadMapStart() - if yyl1030 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1030, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1030 == codecSelferValueTypeArray1234 { - yyl1030 := r.ReadArrayStart() - if yyl1030 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1030, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -14785,16 +21954,16 @@ func (x *AzureFileVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *AzureFileVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *VolumeProjection) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1031Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1031Slc - var yyhl1031 bool = l >= 0 - for yyj1031 := 0; ; yyj1031++ { - if yyhl1031 { - if yyj1031 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -14803,182 +21972,241 @@ func (x *AzureFileVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1031Slc = r.DecodeBytes(yys1031Slc, true, true) - yys1031 := string(yys1031Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1031 { - case "secretName": + switch yys3 { + case "secret": if r.TryDecodeAsNil() { - x.SecretName = "" + if x.Secret != nil { + x.Secret = nil + } } else { - x.SecretName = string(r.DecodeString()) + if x.Secret == nil { + x.Secret = new(SecretProjection) + } + x.Secret.CodecDecodeSelf(d) } - case "shareName": + case "downwardAPI": if r.TryDecodeAsNil() { - x.ShareName = "" + if x.DownwardAPI != nil { + x.DownwardAPI = nil + } } else { - x.ShareName = string(r.DecodeString()) + if x.DownwardAPI == nil { + x.DownwardAPI = new(DownwardAPIProjection) + } + x.DownwardAPI.CodecDecodeSelf(d) } - case "readOnly": + case "configMap": if r.TryDecodeAsNil() { - x.ReadOnly = false + if x.ConfigMap != nil { + x.ConfigMap = nil + } } else { - x.ReadOnly = bool(r.DecodeBool()) + if x.ConfigMap == nil { + x.ConfigMap = new(ConfigMapProjection) + } + x.ConfigMap.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1031) - } // end switch yys1031 - } // end for yyj1031 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *AzureFileVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *VolumeProjection) 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 + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1035 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1035 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.SecretName = "" + if x.Secret != nil { + x.Secret = nil + } } else { - x.SecretName = string(r.DecodeString()) + if x.Secret == nil { + x.Secret = new(SecretProjection) + } + x.Secret.CodecDecodeSelf(d) } - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1035 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1035 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ShareName = "" + if x.DownwardAPI != nil { + x.DownwardAPI = nil + } } else { - x.ShareName = string(r.DecodeString()) + if x.DownwardAPI == nil { + x.DownwardAPI = new(DownwardAPIProjection) + } + x.DownwardAPI.CodecDecodeSelf(d) } - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1035 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1035 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ReadOnly = false + if x.ConfigMap != nil { + x.ConfigMap = nil + } } else { - x.ReadOnly = bool(r.DecodeBool()) + if x.ConfigMap == nil { + x.ConfigMap = new(ConfigMapProjection) + } + x.ConfigMap.CodecDecodeSelf(d) } for { - yyj1035++ - if yyhl1035 { - yyb1035 = yyj1035 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1035 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1035 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1035-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *VsphereVirtualDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *KeyToPath) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1039 := z.EncBinary() - _ = yym1039 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1040 := !z.EncBinary() - yy2arr1040 := z.EncBasicHandle().StructToArray - var yyq1040 [2]bool - _, _, _ = yysep1040, yyq1040, yy2arr1040 - const yyr1040 bool = false - yyq1040[1] = x.FSType != "" - var yynn1040 int - if yyr1040 || yy2arr1040 { - r.EncodeArrayStart(2) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.Mode != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) } else { - yynn1040 = 1 - for _, b := range yyq1040 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1040++ + yynn2++ } } - r.EncodeMapStart(yynn1040) - yynn1040 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1040 || yy2arr1040 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1042 := z.EncBinary() - _ = yym1042 + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath)) + r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumePath")) + r.EncodeString(codecSelferC_UTF81234, string("key")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1043 := z.EncBinary() - _ = yym1043 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.VolumePath)) + r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } - if yyr1040 || yy2arr1040 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1040[1] { - yym1045 := z.EncBinary() - _ = yym1045 - if false { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("path")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Mode == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + yy10 := *x.Mode + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(yy10)) + } } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq1040[1] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) + r.EncodeString(codecSelferC_UTF81234, string("mode")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1046 := z.EncBinary() - _ = yym1046 - if false { + if x.Mode == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) + yy12 := *x.Mode + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(yy12)) + } } } } - if yyr1040 || yy2arr1040 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14987,29 +22215,29 @@ func (x *VsphereVirtualDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *VsphereVirtualDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *KeyToPath) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1047 := z.DecBinary() - _ = yym1047 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1048 := r.ContainerType() - if yyct1048 == codecSelferValueTypeMap1234 { - yyl1048 := r.ReadMapStart() - if yyl1048 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1048, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1048 == codecSelferValueTypeArray1234 { - yyl1048 := r.ReadArrayStart() - if yyl1048 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1048, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15017,16 +22245,16 @@ func (x *VsphereVirtualDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *KeyToPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1049Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1049Slc - var yyhl1049 bool = l >= 0 - for yyj1049 := 0; ; yyj1049++ { - if yyhl1049 { - if yyj1049 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15035,160 +22263,200 @@ func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1049Slc = r.DecodeBytes(yys1049Slc, true, true) - yys1049 := string(yys1049Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1049 { - case "volumePath": + switch yys3 { + case "key": if r.TryDecodeAsNil() { - x.VolumePath = "" + x.Key = "" } else { - x.VolumePath = string(r.DecodeString()) + yyv4 := &x.Key + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "fsType": + case "path": if r.TryDecodeAsNil() { - x.FSType = "" + x.Path = "" + } else { + yyv6 := &x.Path + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "mode": + if r.TryDecodeAsNil() { + if x.Mode != nil { + x.Mode = nil + } } else { - x.FSType = string(r.DecodeString()) + if x.Mode == nil { + x.Mode = new(int32) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys1049) - } // end switch yys1049 - } // end for yyj1049 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *VsphereVirtualDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *KeyToPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1052 int - var yyb1052 bool - var yyhl1052 bool = l >= 0 - yyj1052++ - if yyhl1052 { - yyb1052 = yyj1052 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1052 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1052 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.VolumePath = "" + x.Key = "" + } else { + yyv11 := &x.Key + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Path = "" } else { - x.VolumePath = string(r.DecodeString()) + yyv13 := &x.Path + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1052++ - if yyhl1052 { - yyb1052 = yyj1052 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1052 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1052 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.FSType = "" + if x.Mode != nil { + x.Mode = nil + } } else { - x.FSType = string(r.DecodeString()) + if x.Mode == nil { + x.Mode = new(int32) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + } } for { - yyj1052++ - if yyhl1052 { - yyb1052 = yyj1052 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1052 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1052 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1052-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *PhotonPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *LocalVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1055 := z.EncBinary() - _ = yym1055 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1056 := !z.EncBinary() - yy2arr1056 := z.EncBasicHandle().StructToArray - var yyq1056 [2]bool - _, _, _ = yysep1056, yyq1056, yy2arr1056 - const yyr1056 bool = false - yyq1056[1] = x.FSType != "" - var yynn1056 int - if yyr1056 || yy2arr1056 { - r.EncodeArrayStart(2) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) } else { - yynn1056 = 1 - for _, b := range yyq1056 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1056++ + yynn2++ } } - r.EncodeMapStart(yynn1056) - yynn1056 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1056 || yy2arr1056 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1058 := z.EncBinary() - _ = yym1058 + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PdID)) + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("pdID")) + r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1059 := z.EncBinary() - _ = yym1059 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.PdID)) - } - } - if yyr1056 || yy2arr1056 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1056[1] { - yym1061 := z.EncBinary() - _ = yym1061 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1056[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1062 := z.EncBinary() - _ = yym1062 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FSType)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } - if yyr1056 || yy2arr1056 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -15197,29 +22465,29 @@ func (x *PhotonPersistentDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) } } -func (x *PhotonPersistentDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *LocalVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1063 := z.DecBinary() - _ = yym1063 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1064 := r.ContainerType() - if yyct1064 == codecSelferValueTypeMap1234 { - yyl1064 := r.ReadMapStart() - if yyl1064 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1064, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1064 == codecSelferValueTypeArray1234 { - yyl1064 := r.ReadArrayStart() - if yyl1064 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1064, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15227,16 +22495,16 @@ func (x *PhotonPersistentDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) } } -func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *LocalVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1065Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1065Slc - var yyhl1065 bool = l >= 0 - for yyj1065 := 0; ; yyj1065++ { - if yyhl1065 { - if yyj1065 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15245,277 +22513,218 @@ func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromMap(l int, d *code } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1065Slc = r.DecodeBytes(yys1065Slc, true, true) - yys1065 := string(yys1065Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1065 { - case "pdID": - if r.TryDecodeAsNil() { - x.PdID = "" - } else { - x.PdID = string(r.DecodeString()) - } - case "fsType": + switch yys3 { + case "path": if r.TryDecodeAsNil() { - x.FSType = "" + x.Path = "" } else { - x.FSType = string(r.DecodeString()) + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1065) - } // end switch yys1065 - } // end for yyj1065 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *PhotonPersistentDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *LocalVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1068 int - var yyb1068 bool - var yyhl1068 bool = l >= 0 - yyj1068++ - if yyhl1068 { - yyb1068 = yyj1068 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1068 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1068 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.PdID = "" - } else { - x.PdID = string(r.DecodeString()) - } - yyj1068++ - if yyhl1068 { - yyb1068 = yyj1068 > l - } else { - yyb1068 = r.CheckBreak() - } - if yyb1068 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSType = "" + x.Path = "" } else { - x.FSType = string(r.DecodeString()) + yyv7 := &x.Path + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } for { - yyj1068++ - if yyhl1068 { - yyb1068 = yyj1068 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1068 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1068 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1068-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x AzureDataDiskCachingMode) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1071 := z.EncBinary() - _ = yym1071 - 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 - yym1072 := z.DecBinary() - _ = yym1072 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *AzureDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ContainerPort) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1073 := z.EncBinary() - _ = yym1073 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1074 := !z.EncBinary() - yy2arr1074 := z.EncBasicHandle().StructToArray - var yyq1074 [5]bool - _, _, _ = yysep1074, yyq1074, yy2arr1074 - const yyr1074 bool = false - yyq1074[2] = x.CachingMode != nil - yyq1074[3] = x.FSType != nil - yyq1074[4] = x.ReadOnly != nil - var yynn1074 int - if yyr1074 || yy2arr1074 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = x.HostPort != 0 + yyq2[3] = x.Protocol != "" + yyq2[4] = x.HostIP != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn1074 = 2 - for _, b := range yyq1074 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1074++ + yynn2++ } } - r.EncodeMapStart(yynn1074) - yynn1074 = 0 - } - if yyr1074 || yy2arr1074 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1076 := z.EncBinary() - _ = yym1076 - 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) - yym1077 := z.EncBinary() - _ = yym1077 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DiskName)) - } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1074 || yy2arr1074 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1079 := z.EncBinary() - _ = yym1079 - if false { + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DataDiskURI)) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("diskURI")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1080 := z.EncBinary() - _ = yym1080 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.DataDiskURI)) + 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 yyr1074 || yy2arr1074 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1074[2] { - if x.CachingMode == nil { - r.EncodeNil() + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { } else { - yy1082 := *x.CachingMode - yy1082.CodecEncodeSelf(e) + r.EncodeInt(int64(x.HostPort)) } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq1074[2] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cachingMode")) + r.EncodeString(codecSelferC_UTF81234, string("hostPort")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CachingMode == nil { - r.EncodeNil() + yym8 := z.EncBinary() + _ = yym8 + if false { } else { - yy1083 := *x.CachingMode - yy1083.CodecEncodeSelf(e) + r.EncodeInt(int64(x.HostPort)) } } } - if yyr1074 || yy2arr1074 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1074[3] { - if x.FSType == nil { - r.EncodeNil() - } else { - yy1085 := *x.FSType - yym1086 := z.EncBinary() - _ = yym1086 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1085)) - } - } + yym10 := z.EncBinary() + _ = yym10 + if false { } else { - r.EncodeNil() + r.EncodeInt(int64(x.ContainerPort)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("containerPort")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.ContainerPort)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + x.Protocol.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1074[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsType")) + r.EncodeString(codecSelferC_UTF81234, string("protocol")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FSType == nil { - r.EncodeNil() - } else { - yy1087 := *x.FSType - yym1088 := z.EncBinary() - _ = yym1088 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1087)) - } - } + x.Protocol.CodecEncodeSelf(e) } } - if yyr1074 || yy2arr1074 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1074[4] { - if x.ReadOnly == nil { - r.EncodeNil() + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { } else { - yy1090 := *x.ReadOnly - yym1091 := z.EncBinary() - _ = yym1091 - if false { - } else { - r.EncodeBool(bool(yy1090)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1074[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + r.EncodeString(codecSelferC_UTF81234, string("hostIP")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ReadOnly == nil { - r.EncodeNil() + yym17 := z.EncBinary() + _ = yym17 + if false { } else { - yy1092 := *x.ReadOnly - yym1093 := z.EncBinary() - _ = yym1093 - if false { - } else { - r.EncodeBool(bool(yy1092)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) } } } - if yyr1074 || yy2arr1074 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -15524,29 +22733,29 @@ func (x *AzureDiskVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *AzureDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ContainerPort) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1094 := z.DecBinary() - _ = yym1094 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1095 := r.ContainerType() - if yyct1095 == codecSelferValueTypeMap1234 { - yyl1095 := r.ReadMapStart() - if yyl1095 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1095, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1095 == codecSelferValueTypeArray1234 { - yyl1095 := r.ReadArrayStart() - if yyl1095 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1095, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15554,16 +22763,16 @@ func (x *AzureDiskVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *AzureDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ContainerPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1096Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1096Slc - var yyhl1096 bool = l >= 0 - for yyj1096 := 0; ; yyj1096++ { - if yyhl1096 { - if yyj1096 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15572,327 +22781,321 @@ func (x *AzureDiskVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1096Slc = r.DecodeBytes(yys1096Slc, true, true) - yys1096 := string(yys1096Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1096 { - case "diskName": - if r.TryDecodeAsNil() { - x.DiskName = "" - } else { - x.DiskName = string(r.DecodeString()) - } - case "diskURI": + switch yys3 { + case "name": if r.TryDecodeAsNil() { - x.DataDiskURI = "" + x.Name = "" } else { - x.DataDiskURI = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "cachingMode": + case "hostPort": if r.TryDecodeAsNil() { - if x.CachingMode != nil { - x.CachingMode = nil - } + x.HostPort = 0 } else { - if x.CachingMode == nil { - x.CachingMode = new(AzureDataDiskCachingMode) + yyv6 := &x.HostPort + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) } - x.CachingMode.CodecDecodeSelf(d) } - case "fsType": + case "containerPort": if r.TryDecodeAsNil() { - if x.FSType != nil { - x.FSType = nil - } + x.ContainerPort = 0 } else { - if x.FSType == nil { - x.FSType = new(string) - } - yym1101 := z.DecBinary() - _ = yym1101 + yyv8 := &x.ContainerPort + yym9 := z.DecBinary() + _ = yym9 if false { } else { - *((*string)(x.FSType)) = r.DecodeString() + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) } } - case "readOnly": + case "protocol": if r.TryDecodeAsNil() { - if x.ReadOnly != nil { - x.ReadOnly = nil - } + x.Protocol = "" } else { - if x.ReadOnly == nil { - x.ReadOnly = new(bool) - } - yym1103 := z.DecBinary() - _ = yym1103 + yyv10 := &x.Protocol + yyv10.CodecDecodeSelf(d) + } + case "hostIP": + if r.TryDecodeAsNil() { + x.HostIP = "" + } else { + yyv11 := &x.HostIP + yym12 := z.DecBinary() + _ = yym12 if false { } else { - *((*bool)(x.ReadOnly)) = r.DecodeBool() + *((*string)(yyv11)) = r.DecodeString() } } default: - z.DecStructFieldNotFound(-1, yys1096) - } // end switch yys1096 - } // end for yyj1096 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *AzureDiskVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ContainerPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1104 int - var yyb1104 bool - var yyhl1104 bool = l >= 0 - yyj1104++ - if yyhl1104 { - yyb1104 = yyj1104 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1104 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1104 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DiskName = "" + x.Name = "" } else { - x.DiskName = string(r.DecodeString()) + yyv14 := &x.Name + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj1104++ - if yyhl1104 { - yyb1104 = yyj1104 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1104 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1104 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DataDiskURI = "" + x.HostPort = 0 } else { - x.DataDiskURI = string(r.DecodeString()) + yyv16 := &x.HostPort + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*int32)(yyv16)) = int32(r.DecodeInt(32)) + } } - yyj1104++ - if yyhl1104 { - yyb1104 = yyj1104 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1104 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1104 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.CachingMode != nil { - x.CachingMode = nil - } + x.ContainerPort = 0 } else { - if x.CachingMode == nil { - x.CachingMode = new(AzureDataDiskCachingMode) + yyv18 := &x.ContainerPort + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int32)(yyv18)) = int32(r.DecodeInt(32)) } - x.CachingMode.CodecDecodeSelf(d) } - yyj1104++ - if yyhl1104 { - yyb1104 = yyj1104 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1104 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1104 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.FSType != nil { - x.FSType = nil - } + x.Protocol = "" } else { - if x.FSType == nil { - x.FSType = new(string) - } - yym1109 := z.DecBinary() - _ = yym1109 - if false { - } else { - *((*string)(x.FSType)) = r.DecodeString() - } + yyv20 := &x.Protocol + yyv20.CodecDecodeSelf(d) } - yyj1104++ - if yyhl1104 { - yyb1104 = yyj1104 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1104 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1104 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ReadOnly != nil { - x.ReadOnly = nil - } + x.HostIP = "" } else { - if x.ReadOnly == nil { - x.ReadOnly = new(bool) - } - yym1111 := z.DecBinary() - _ = yym1111 + yyv21 := &x.HostIP + yym22 := z.DecBinary() + _ = yym22 if false { } else { - *((*bool)(x.ReadOnly)) = r.DecodeBool() + *((*string)(yyv21)) = r.DecodeString() } } for { - yyj1104++ - if yyhl1104 { - yyb1104 = yyj1104 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1104 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1104 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1104-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ConfigMapVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *VolumeMount) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1112 := z.EncBinary() - _ = yym1112 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1113 := !z.EncBinary() - yy2arr1113 := z.EncBasicHandle().StructToArray - var yyq1113 [3]bool - _, _, _ = yysep1113, yyq1113, yy2arr1113 - const yyr1113 bool = false - yyq1113[0] = x.Name != "" - yyq1113[1] = len(x.Items) != 0 - yyq1113[2] = x.DefaultMode != nil - var yynn1113 int - if yyr1113 || yy2arr1113 { - r.EncodeArrayStart(3) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.ReadOnly != false + yyq2[3] = x.SubPath != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn1113 = 0 - for _, b := range yyq1113 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1113++ + yynn2++ } } - r.EncodeMapStart(yynn1113) - yynn1113 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1113[0] { - yym1115 := z.EncBinary() - _ = yym1115 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + r.EncodeBool(bool(x.ReadOnly)) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeBool(false) } } else { - if yyq1113[0] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) + r.EncodeString(codecSelferC_UTF81234, string("readOnly")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1116 := z.EncBinary() - _ = yym1116 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + r.EncodeBool(bool(x.ReadOnly)) } } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1113[1] { - if x.Items == nil { - r.EncodeNil() - } else { - yym1118 := z.EncBinary() - _ = yym1118 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } + yym10 := z.EncBinary() + _ = yym10 + if false { } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, string(x.MountPath)) } } else { - if yyq1113[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1119 := z.EncBinary() - _ = yym1119 - if false { - } else { - h.encSliceKeyToPath(([]KeyToPath)(x.Items), e) - } - } + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("mountPath")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MountPath)) } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1113[2] { - if x.DefaultMode == nil { - r.EncodeNil() + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { } else { - yy1121 := *x.DefaultMode - yym1122 := z.EncBinary() - _ = yym1122 - if false { - } else { - r.EncodeInt(int64(yy1121)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1113[2] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) + r.EncodeString(codecSelferC_UTF81234, string("subPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultMode == nil { - r.EncodeNil() + yym14 := z.EncBinary() + _ = yym14 + if false { } else { - yy1123 := *x.DefaultMode - yym1124 := z.EncBinary() - _ = yym1124 - if false { - } else { - r.EncodeInt(int64(yy1123)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) } } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -15901,29 +23104,29 @@ func (x *ConfigMapVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ConfigMapVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *VolumeMount) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1125 := z.DecBinary() - _ = yym1125 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1126 := r.ContainerType() - if yyct1126 == codecSelferValueTypeMap1234 { - yyl1126 := r.ReadMapStart() - if yyl1126 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1126, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1126 == codecSelferValueTypeArray1234 { - yyl1126 := r.ReadArrayStart() - if yyl1126 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1126, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15931,16 +23134,16 @@ func (x *ConfigMapVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ConfigMapVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *VolumeMount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1127Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1127Slc - var yyhl1127 bool = l >= 0 - for yyj1127 := 0; ; yyj1127++ { - if yyhl1127 { - if yyj1127 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15949,65 +23152,79 @@ func (x *ConfigMapVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1127Slc = r.DecodeBytes(yys1127Slc, true, true) - yys1127 := string(yys1127Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1127 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "items": + case "readOnly": if r.TryDecodeAsNil() { - x.Items = nil + x.ReadOnly = false } else { - yyv1129 := &x.Items - yym1130 := z.DecBinary() - _ = yym1130 + yyv6 := &x.ReadOnly + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv1129), d) + *((*bool)(yyv6)) = r.DecodeBool() } } - case "defaultMode": + case "mountPath": if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } + x.MountPath = "" } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) + yyv8 := &x.MountPath + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() } - yym1132 := z.DecBinary() - _ = yym1132 + } + case "subPath": + if r.TryDecodeAsNil() { + x.SubPath = "" + } else { + yyv10 := &x.SubPath + yym11 := z.DecBinary() + _ = yym11 if false { } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) + *((*string)(yyv10)) = r.DecodeString() } } default: - z.DecStructFieldNotFound(-1, yys1127) - } // end switch yys1127 - } // end for yyj1127 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ConfigMapVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *VolumeMount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1133 int - var yyb1133 bool - var yyhl1133 bool = l >= 0 - yyj1133++ - if yyhl1133 { - yyb1133 = yyj1133 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1133 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1133 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16015,177 +23232,196 @@ func (x *ConfigMapVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv13 := &x.Name + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1133++ - if yyhl1133 { - yyb1133 = yyj1133 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1133 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1133 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Items = nil + x.ReadOnly = false } else { - yyv1135 := &x.Items - yym1136 := z.DecBinary() - _ = yym1136 + yyv15 := &x.ReadOnly + yym16 := z.DecBinary() + _ = yym16 if false { } else { - h.decSliceKeyToPath((*[]KeyToPath)(yyv1135), d) + *((*bool)(yyv15)) = r.DecodeBool() } } - yyj1133++ - if yyhl1133 { - yyb1133 = yyj1133 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1133 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1133 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.DefaultMode != nil { - x.DefaultMode = nil - } + x.MountPath = "" } else { - if x.DefaultMode == nil { - x.DefaultMode = new(int32) + yyv17 := &x.MountPath + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() } - yym1138 := z.DecBinary() - _ = yym1138 + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.SubPath = "" + } else { + yyv19 := &x.SubPath + yym20 := z.DecBinary() + _ = yym20 if false { } else { - *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) + *((*string)(yyv19)) = r.DecodeString() } } for { - yyj1133++ - if yyhl1133 { - yyb1133 = yyj1133 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1133 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1133 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1133-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *KeyToPath) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *EnvVar) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1139 := z.EncBinary() - _ = yym1139 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1140 := !z.EncBinary() - yy2arr1140 := z.EncBasicHandle().StructToArray - var yyq1140 [3]bool - _, _, _ = yysep1140, yyq1140, yy2arr1140 - const yyr1140 bool = false - yyq1140[2] = x.Mode != nil - var yynn1140 int - if yyr1140 || yy2arr1140 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Value != "" + yyq2[2] = x.ValueFrom != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1140 = 2 - for _, b := range yyq1140 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1140++ + yynn2++ } } - r.EncodeMapStart(yynn1140) - yynn1140 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1140 || yy2arr1140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1142 := z.EncBinary() - _ = yym1142 + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("key")) + r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1143 := z.EncBinary() - _ = yym1143 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr1140 || yy2arr1140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1145 := z.EncBinary() - _ = yym1145 - if false { + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Value)) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1146 := z.EncBinary() - _ = yym1146 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("value")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Value)) + } } } - if yyr1140 || yy2arr1140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1140[2] { - if x.Mode == nil { + if yyq2[2] { + if x.ValueFrom == nil { r.EncodeNil() } else { - yy1148 := *x.Mode - yym1149 := z.EncBinary() - _ = yym1149 - if false { - } else { - r.EncodeInt(int64(yy1148)) - } + x.ValueFrom.CodecEncodeSelf(e) } } else { r.EncodeNil() } } else { - if yyq1140[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("mode")) + r.EncodeString(codecSelferC_UTF81234, string("valueFrom")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Mode == nil { + if x.ValueFrom == nil { r.EncodeNil() } else { - yy1150 := *x.Mode - yym1151 := z.EncBinary() - _ = yym1151 - if false { - } else { - r.EncodeInt(int64(yy1150)) - } + x.ValueFrom.CodecEncodeSelf(e) } } } - if yyr1140 || yy2arr1140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -16194,29 +23430,29 @@ func (x *KeyToPath) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *KeyToPath) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *EnvVar) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1152 := z.DecBinary() - _ = yym1152 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1153 := r.ContainerType() - if yyct1153 == codecSelferValueTypeMap1234 { - yyl1153 := r.ReadMapStart() - if yyl1153 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1153, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1153 == codecSelferValueTypeArray1234 { - yyl1153 := r.ReadArrayStart() - if yyl1153 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1153, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -16224,16 +23460,16 @@ func (x *KeyToPath) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *KeyToPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *EnvVar) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1154Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1154Slc - var yyhl1154 bool = l >= 0 - for yyj1154 := 0; ; yyj1154++ { - if yyhl1154 { - if yyj1154 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -16242,270 +23478,267 @@ func (x *KeyToPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1154Slc = r.DecodeBytes(yys1154Slc, true, true) - yys1154 := string(yys1154Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1154 { - case "key": + switch yys3 { + case "name": if r.TryDecodeAsNil() { - x.Key = "" + x.Name = "" } else { - x.Key = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "path": + case "value": if r.TryDecodeAsNil() { - x.Path = "" + x.Value = "" } else { - x.Path = string(r.DecodeString()) + yyv6 := &x.Value + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - case "mode": + case "valueFrom": if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil + if x.ValueFrom != nil { + x.ValueFrom = nil } } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym1158 := z.DecBinary() - _ = yym1158 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + if x.ValueFrom == nil { + x.ValueFrom = new(EnvVarSource) } + x.ValueFrom.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1154) - } // end switch yys1154 - } // end for yyj1154 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *KeyToPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *EnvVar) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1159 int - var yyb1159 bool - var yyhl1159 bool = l >= 0 - yyj1159++ - if yyhl1159 { - yyb1159 = yyj1159 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1159 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1159 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Key = "" + x.Name = "" } else { - x.Key = string(r.DecodeString()) + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } - yyj1159++ - if yyhl1159 { - yyb1159 = yyj1159 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1159 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1159 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Path = "" + x.Value = "" } else { - x.Path = string(r.DecodeString()) + yyv12 := &x.Value + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj1159++ - if yyhl1159 { - yyb1159 = yyj1159 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1159 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1159 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil + if x.ValueFrom != nil { + x.ValueFrom = nil } } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym1163 := z.DecBinary() - _ = yym1163 - if false { - } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + if x.ValueFrom == nil { + x.ValueFrom = new(EnvVarSource) } + x.ValueFrom.CodecDecodeSelf(d) } for { - yyj1159++ - if yyhl1159 { - yyb1159 = yyj1159 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1159 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1159 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1159-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ContainerPort) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *EnvVarSource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1164 := z.EncBinary() - _ = yym1164 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1165 := !z.EncBinary() - yy2arr1165 := z.EncBasicHandle().StructToArray - var yyq1165 [5]bool - _, _, _ = yysep1165, yyq1165, yy2arr1165 - const yyr1165 bool = false - yyq1165[0] = x.Name != "" - yyq1165[1] = x.HostPort != 0 - yyq1165[3] = x.Protocol != "" - yyq1165[4] = x.HostIP != "" - var yynn1165 int - if yyr1165 || yy2arr1165 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.FieldRef != nil + yyq2[1] = x.ResourceFieldRef != nil + yyq2[2] = x.ConfigMapKeyRef != nil + yyq2[3] = x.SecretKeyRef != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn1165 = 1 - for _, b := range yyq1165 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1165++ + yynn2++ } } - r.EncodeMapStart(yynn1165) - yynn1165 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1165[0] { - yym1167 := z.EncBinary() - _ = yym1167 - if false { + if yyq2[0] { + if x.FieldRef == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + x.FieldRef.CodecEncodeSelf(e) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq1165[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) + r.EncodeString(codecSelferC_UTF81234, string("fieldRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1168 := z.EncBinary() - _ = yym1168 - if false { + if x.FieldRef == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + x.FieldRef.CodecEncodeSelf(e) } } } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1165[1] { - yym1170 := z.EncBinary() - _ = yym1170 - if false { + if yyq2[1] { + if x.ResourceFieldRef == nil { + r.EncodeNil() } else { - r.EncodeInt(int64(x.HostPort)) + x.ResourceFieldRef.CodecEncodeSelf(e) } } else { - r.EncodeInt(0) + r.EncodeNil() } } else { - if yyq1165[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPort")) + r.EncodeString(codecSelferC_UTF81234, string("resourceFieldRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1171 := z.EncBinary() - _ = yym1171 - if false { + if x.ResourceFieldRef == nil { + r.EncodeNil() } else { - r.EncodeInt(int64(x.HostPort)) + x.ResourceFieldRef.CodecEncodeSelf(e) } } } - if yyr1165 || yy2arr1165 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1173 := z.EncBinary() - _ = yym1173 - if false { - } else { - r.EncodeInt(int64(x.ContainerPort)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerPort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1174 := z.EncBinary() - _ = yym1174 - if false { - } else { - r.EncodeInt(int64(x.ContainerPort)) - } - } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1165[3] { - x.Protocol.CodecEncodeSelf(e) + if yyq2[2] { + if x.ConfigMapKeyRef == nil { + r.EncodeNil() + } else { + x.ConfigMapKeyRef.CodecEncodeSelf(e) + } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq1165[3] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) + r.EncodeString(codecSelferC_UTF81234, string("configMapKeyRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Protocol.CodecEncodeSelf(e) + if x.ConfigMapKeyRef == nil { + r.EncodeNil() + } else { + x.ConfigMapKeyRef.CodecEncodeSelf(e) + } } } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1165[4] { - yym1177 := z.EncBinary() - _ = yym1177 - if false { + if yyq2[3] { + if x.SecretKeyRef == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) + x.SecretKeyRef.CodecEncodeSelf(e) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq1165[4] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIP")) + r.EncodeString(codecSelferC_UTF81234, string("secretKeyRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1178 := z.EncBinary() - _ = yym1178 - if false { + if x.SecretKeyRef == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) + x.SecretKeyRef.CodecEncodeSelf(e) } } } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -16514,29 +23747,29 @@ func (x *ContainerPort) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ContainerPort) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *EnvVarSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1179 := z.DecBinary() - _ = yym1179 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1180 := r.ContainerType() - if yyct1180 == codecSelferValueTypeMap1234 { - yyl1180 := r.ReadMapStart() - if yyl1180 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1180, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1180 == codecSelferValueTypeArray1234 { - yyl1180 := r.ReadArrayStart() - if yyl1180 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1180, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -16544,16 +23777,16 @@ func (x *ContainerPort) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ContainerPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *EnvVarSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1181Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1181Slc - var yyhl1181 bool = l >= 0 - for yyj1181 := 0; ; yyj1181++ { - if yyhl1181 { - if yyj1181 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -16562,271 +23795,244 @@ func (x *ContainerPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1181Slc = r.DecodeBytes(yys1181Slc, true, true) - yys1181 := string(yys1181Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1181 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "hostPort": + switch yys3 { + case "fieldRef": if r.TryDecodeAsNil() { - x.HostPort = 0 + if x.FieldRef != nil { + x.FieldRef = nil + } } else { - x.HostPort = int32(r.DecodeInt(32)) + if x.FieldRef == nil { + x.FieldRef = new(ObjectFieldSelector) + } + x.FieldRef.CodecDecodeSelf(d) } - case "containerPort": + case "resourceFieldRef": if r.TryDecodeAsNil() { - x.ContainerPort = 0 + if x.ResourceFieldRef != nil { + x.ResourceFieldRef = nil + } } else { - x.ContainerPort = int32(r.DecodeInt(32)) + if x.ResourceFieldRef == nil { + x.ResourceFieldRef = new(ResourceFieldSelector) + } + x.ResourceFieldRef.CodecDecodeSelf(d) } - case "protocol": + case "configMapKeyRef": if r.TryDecodeAsNil() { - x.Protocol = "" + if x.ConfigMapKeyRef != nil { + x.ConfigMapKeyRef = nil + } } else { - x.Protocol = Protocol(r.DecodeString()) + if x.ConfigMapKeyRef == nil { + x.ConfigMapKeyRef = new(ConfigMapKeySelector) + } + x.ConfigMapKeyRef.CodecDecodeSelf(d) } - case "hostIP": + case "secretKeyRef": if r.TryDecodeAsNil() { - x.HostIP = "" + if x.SecretKeyRef != nil { + x.SecretKeyRef = nil + } } else { - x.HostIP = string(r.DecodeString()) + if x.SecretKeyRef == nil { + x.SecretKeyRef = new(SecretKeySelector) + } + x.SecretKeyRef.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1181) - } // end switch yys1181 - } // end for yyj1181 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ContainerPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *EnvVarSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1187 int - var yyb1187 bool - var yyhl1187 bool = l >= 0 - yyj1187++ - if yyhl1187 { - yyb1187 = yyj1187 > l - } else { - yyb1187 = r.CheckBreak() - } - if yyb1187 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1187++ - if yyhl1187 { - yyb1187 = yyj1187 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1187 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1187 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.HostPort = 0 + if x.FieldRef != nil { + x.FieldRef = nil + } } else { - x.HostPort = int32(r.DecodeInt(32)) + if x.FieldRef == nil { + x.FieldRef = new(ObjectFieldSelector) + } + x.FieldRef.CodecDecodeSelf(d) } - yyj1187++ - if yyhl1187 { - yyb1187 = yyj1187 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1187 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1187 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ContainerPort = 0 + if x.ResourceFieldRef != nil { + x.ResourceFieldRef = nil + } } else { - x.ContainerPort = int32(r.DecodeInt(32)) + if x.ResourceFieldRef == nil { + x.ResourceFieldRef = new(ResourceFieldSelector) + } + x.ResourceFieldRef.CodecDecodeSelf(d) } - yyj1187++ - if yyhl1187 { - yyb1187 = yyj1187 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1187 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1187 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Protocol = "" + if x.ConfigMapKeyRef != nil { + x.ConfigMapKeyRef = nil + } } else { - x.Protocol = Protocol(r.DecodeString()) + if x.ConfigMapKeyRef == nil { + x.ConfigMapKeyRef = new(ConfigMapKeySelector) + } + x.ConfigMapKeyRef.CodecDecodeSelf(d) } - yyj1187++ - if yyhl1187 { - yyb1187 = yyj1187 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1187 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1187 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.HostIP = "" + if x.SecretKeyRef != nil { + x.SecretKeyRef = nil + } } else { - x.HostIP = string(r.DecodeString()) + if x.SecretKeyRef == nil { + x.SecretKeyRef = new(SecretKeySelector) + } + x.SecretKeyRef.CodecDecodeSelf(d) } for { - yyj1187++ - if yyhl1187 { - yyb1187 = yyj1187 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1187 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1187 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1187-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *VolumeMount) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ObjectFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1193 := z.EncBinary() - _ = yym1193 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1194 := !z.EncBinary() - yy2arr1194 := z.EncBasicHandle().StructToArray - var yyq1194 [4]bool - _, _, _ = yysep1194, yyq1194, yy2arr1194 - const yyr1194 bool = false - yyq1194[1] = x.ReadOnly != false - yyq1194[3] = x.SubPath != "" - var yynn1194 int - if yyr1194 || yy2arr1194 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.APIVersion != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn1194 = 2 - for _, b := range yyq1194 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1194++ + yynn2++ } } - r.EncodeMapStart(yynn1194) - yynn1194 = 0 - } - if yyr1194 || yy2arr1194 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1196 := z.EncBinary() - _ = yym1196 - 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) - yym1197 := z.EncBinary() - _ = yym1197 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1194 || yy2arr1194 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1194[1] { - yym1199 := z.EncBinary() - _ = yym1199 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeBool(bool(x.ReadOnly)) + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } else { - r.EncodeBool(false) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1194[1] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnly")) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1200 := z.EncBinary() - _ = yym1200 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeBool(bool(x.ReadOnly)) + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1194 || yy2arr1194 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1202 := z.EncBinary() - _ = yym1202 + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.MountPath)) + r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("mountPath")) + r.EncodeString(codecSelferC_UTF81234, string("fieldPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1203 := z.EncBinary() - _ = yym1203 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.MountPath)) - } - } - if yyr1194 || yy2arr1194 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1194[3] { - yym1205 := z.EncBinary() - _ = yym1205 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1194[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("subPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1206 := z.EncBinary() - _ = yym1206 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SubPath)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) } } - if yyr1194 || yy2arr1194 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -16835,29 +24041,29 @@ func (x *VolumeMount) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *VolumeMount) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ObjectFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1207 := z.DecBinary() - _ = yym1207 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1208 := r.ContainerType() - if yyct1208 == codecSelferValueTypeMap1234 { - yyl1208 := r.ReadMapStart() - if yyl1208 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1208, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1208 == codecSelferValueTypeArray1234 { - yyl1208 := r.ReadArrayStart() - if yyl1208 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1208, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -16865,16 +24071,16 @@ func (x *VolumeMount) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *VolumeMount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ObjectFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1209Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1209Slc - var yyhl1209 bool = l >= 0 - for yyj1209 := 0; ; yyj1209++ { - if yyhl1209 { - if yyj1209 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -16883,228 +24089,218 @@ func (x *VolumeMount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1209Slc = r.DecodeBytes(yys1209Slc, true, true) - yys1209 := string(yys1209Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1209 { - 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": + switch yys3 { + case "apiVersion": if r.TryDecodeAsNil() { - x.MountPath = "" + x.APIVersion = "" } else { - x.MountPath = string(r.DecodeString()) + yyv4 := &x.APIVersion + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "subPath": + case "fieldPath": if r.TryDecodeAsNil() { - x.SubPath = "" + x.FieldPath = "" } else { - x.SubPath = string(r.DecodeString()) + yyv6 := &x.FieldPath + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1209) - } // end switch yys1209 - } // end for yyj1209 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *VolumeMount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ObjectFieldSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1214 int - var yyb1214 bool - var yyhl1214 bool = l >= 0 - yyj1214++ - if yyhl1214 { - yyb1214 = yyj1214 > l - } else { - yyb1214 = r.CheckBreak() - } - if yyb1214 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj1214++ - if yyhl1214 { - yyb1214 = yyj1214 > l - } else { - yyb1214 = r.CheckBreak() - } - if yyb1214 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnly = false + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - x.ReadOnly = bool(r.DecodeBool()) + yyb8 = r.CheckBreak() } - yyj1214++ - if yyhl1214 { - yyb1214 = yyj1214 > l - } else { - yyb1214 = r.CheckBreak() - } - if yyb1214 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.MountPath = "" + x.APIVersion = "" } else { - x.MountPath = string(r.DecodeString()) + yyv9 := &x.APIVersion + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1214++ - if yyhl1214 { - yyb1214 = yyj1214 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1214 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1214 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.SubPath = "" + x.FieldPath = "" } else { - x.SubPath = string(r.DecodeString()) + yyv11 := &x.FieldPath + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj1214++ - if yyhl1214 { - yyb1214 = yyj1214 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1214 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1214 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1214-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *EnvVar) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ResourceFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1219 := z.EncBinary() - _ = yym1219 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1220 := !z.EncBinary() - yy2arr1220 := z.EncBasicHandle().StructToArray - var yyq1220 [3]bool - _, _, _ = yysep1220, yyq1220, yy2arr1220 - const yyr1220 bool = false - yyq1220[1] = x.Value != "" - yyq1220[2] = x.ValueFrom != nil - var yynn1220 int - if yyr1220 || yy2arr1220 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ContainerName != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1220 = 1 - for _, b := range yyq1220 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1220++ + yynn2++ } } - r.EncodeMapStart(yynn1220) - yynn1220 = 0 - } - if yyr1220 || yy2arr1220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1222 := z.EncBinary() - _ = yym1222 - 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) - yym1223 := z.EncBinary() - _ = yym1223 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1220 || yy2arr1220 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1220[1] { - yym1225 := z.EncBinary() - _ = yym1225 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) + r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) } } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1220[1] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) + r.EncodeString(codecSelferC_UTF81234, string("containerName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1226 := z.EncBinary() - _ = yym1226 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Value)) + r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) } } } - if yyr1220 || yy2arr1220 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1220[2] { - if x.ValueFrom == nil { - r.EncodeNil() + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.Divisor + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - x.ValueFrom.CodecEncodeSelf(e) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1220[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("valueFrom")) + r.EncodeString(codecSelferC_UTF81234, string("divisor")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ValueFrom == nil { - r.EncodeNil() + yy12 := &x.Divisor + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - x.ValueFrom.CodecEncodeSelf(e) + z.EncFallback(yy12) } } } - if yyr1220 || yy2arr1220 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -17113,29 +24309,29 @@ func (x *EnvVar) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *EnvVar) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ResourceFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1228 := z.DecBinary() - _ = yym1228 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1229 := r.ContainerType() - if yyct1229 == codecSelferValueTypeMap1234 { - yyl1229 := r.ReadMapStart() - if yyl1229 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1229, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1229 == codecSelferValueTypeArray1234 { - yyl1229 := r.ReadArrayStart() - if yyl1229 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1229, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -17143,16 +24339,16 @@ func (x *EnvVar) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *EnvVar) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ResourceFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1230Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1230Slc - var yyhl1230 bool = l >= 0 - for yyj1230 := 0; ; yyj1230++ { - if yyhl1230 { - if yyj1230 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -17161,243 +24357,260 @@ func (x *EnvVar) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1230Slc = r.DecodeBytes(yys1230Slc, true, true) - yys1230 := string(yys1230Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1230 { - case "name": + switch yys3 { + case "containerName": if r.TryDecodeAsNil() { - x.Name = "" + x.ContainerName = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.ContainerName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "value": + case "resource": if r.TryDecodeAsNil() { - x.Value = "" + x.Resource = "" } else { - x.Value = string(r.DecodeString()) + yyv6 := &x.Resource + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - case "valueFrom": + case "divisor": if r.TryDecodeAsNil() { - if x.ValueFrom != nil { - x.ValueFrom = nil - } + x.Divisor = pkg3_resource.Quantity{} } else { - if x.ValueFrom == nil { - x.ValueFrom = new(EnvVarSource) + yyv8 := &x.Divisor + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) + } else { + z.DecFallback(yyv8, false) } - x.ValueFrom.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1230) - } // end switch yys1230 - } // end for yyj1230 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *EnvVar) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ResourceFieldSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1234 int - var yyb1234 bool - var yyhl1234 bool = l >= 0 - yyj1234++ - if yyhl1234 { - yyb1234 = yyj1234 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1234 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1234 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Name = "" + x.ContainerName = "" } else { - x.Name = string(r.DecodeString()) + yyv11 := &x.ContainerName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj1234++ - if yyhl1234 { - yyb1234 = yyj1234 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1234 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1234 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Value = "" + x.Resource = "" } else { - x.Value = string(r.DecodeString()) + yyv13 := &x.Resource + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1234++ - if yyhl1234 { - yyb1234 = yyj1234 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1234 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1234 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ValueFrom != nil { - x.ValueFrom = nil - } + x.Divisor = pkg3_resource.Quantity{} } else { - if x.ValueFrom == nil { - x.ValueFrom = new(EnvVarSource) + yyv15 := &x.Divisor + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else if !yym16 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv15) + } else { + z.DecFallback(yyv15, false) } - x.ValueFrom.CodecDecodeSelf(d) } for { - yyj1234++ - if yyhl1234 { - yyb1234 = yyj1234 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1234 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1234 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1234-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *EnvVarSource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ConfigMapKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1238 := z.EncBinary() - _ = yym1238 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1239 := !z.EncBinary() - yy2arr1239 := z.EncBasicHandle().StructToArray - var yyq1239 [4]bool - _, _, _ = yysep1239, yyq1239, yy2arr1239 - const yyr1239 bool = false - yyq1239[0] = x.FieldRef != nil - yyq1239[1] = x.ResourceFieldRef != nil - yyq1239[2] = x.ConfigMapKeyRef != nil - yyq1239[3] = x.SecretKeyRef != nil - var yynn1239 int - if yyr1239 || yy2arr1239 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[2] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) } else { - yynn1239 = 0 - for _, b := range yyq1239 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1239++ + yynn2++ } } - r.EncodeMapStart(yynn1239) - yynn1239 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1239 || yy2arr1239 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1239[0] { - if x.FieldRef == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - x.FieldRef.CodecEncodeSelf(e) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1239[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fieldRef")) + r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.FieldRef == nil { - r.EncodeNil() + yym5 := z.EncBinary() + _ = yym5 + if false { } else { - x.FieldRef.CodecEncodeSelf(e) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr1239 || yy2arr1239 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1239[1] { - if x.ResourceFieldRef == nil { - r.EncodeNil() - } else { - x.ResourceFieldRef.CodecEncodeSelf(e) - } + yym7 := z.EncBinary() + _ = yym7 + if false { } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } else { - if yyq1239[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 yyr1239 || yy2arr1239 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1239[2] { - if x.ConfigMapKeyRef == nil { - r.EncodeNil() - } else { - x.ConfigMapKeyRef.CodecEncodeSelf(e) - } + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("key")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { } else { - r.EncodeNil() - } - } else { - if yyq1239[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) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } - if yyr1239 || yy2arr1239 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1239[3] { - if x.SecretKeyRef == nil { + if yyq2[2] { + if x.Optional == nil { r.EncodeNil() } else { - x.SecretKeyRef.CodecEncodeSelf(e) + yy10 := *x.Optional + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(yy10)) + } } } else { r.EncodeNil() } } else { - if yyq1239[3] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretKeyRef")) + r.EncodeString(codecSelferC_UTF81234, string("optional")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.SecretKeyRef == nil { + if x.Optional == nil { r.EncodeNil() } else { - x.SecretKeyRef.CodecEncodeSelf(e) + yy12 := *x.Optional + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(yy12)) + } } } } - if yyr1239 || yy2arr1239 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -17406,29 +24619,29 @@ func (x *EnvVarSource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *EnvVarSource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ConfigMapKeySelector) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1244 := z.DecBinary() - _ = yym1244 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1245 := r.ContainerType() - if yyct1245 == codecSelferValueTypeMap1234 { - yyl1245 := r.ReadMapStart() - if yyl1245 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1245, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1245 == codecSelferValueTypeArray1234 { - yyl1245 := r.ReadArrayStart() - if yyl1245 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1245, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -17436,16 +24649,16 @@ func (x *EnvVarSource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *EnvVarSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ConfigMapKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1246Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1246Slc - var yyhl1246 bool = l >= 0 - for yyj1246 := 0; ; yyj1246++ { - if yyhl1246 { - if yyj1246 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -17454,244 +24667,262 @@ func (x *EnvVarSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1246Slc = r.DecodeBytes(yys1246Slc, true, true) - yys1246 := string(yys1246Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1246 { - case "fieldRef": + switch yys3 { + case "name": if r.TryDecodeAsNil() { - if x.FieldRef != nil { - x.FieldRef = nil - } + x.Name = "" } else { - if x.FieldRef == nil { - x.FieldRef = new(ObjectFieldSelector) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() } - x.FieldRef.CodecDecodeSelf(d) } - case "resourceFieldRef": + case "key": if r.TryDecodeAsNil() { - if x.ResourceFieldRef != nil { - x.ResourceFieldRef = nil - } + x.Key = "" } else { - if x.ResourceFieldRef == nil { - x.ResourceFieldRef = new(ResourceFieldSelector) + yyv6 := &x.Key + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() } - x.ResourceFieldRef.CodecDecodeSelf(d) } - case "configMapKeyRef": + case "optional": if r.TryDecodeAsNil() { - if x.ConfigMapKeyRef != nil { - x.ConfigMapKeyRef = nil + if x.Optional != nil { + x.Optional = 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 + if x.Optional == nil { + x.Optional = new(bool) } - } else { - if x.SecretKeyRef == nil { - x.SecretKeyRef = new(SecretKeySelector) + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() } - x.SecretKeyRef.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1246) - } // end switch yys1246 - } // end for yyj1246 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *EnvVarSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ConfigMapKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1251 int - var yyb1251 bool - var yyhl1251 bool = l >= 0 - yyj1251++ - if yyhl1251 { - yyb1251 = yyj1251 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1251 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1251 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.FieldRef != nil { - x.FieldRef = nil - } + x.Name = "" } else { - if x.FieldRef == nil { - x.FieldRef = new(ObjectFieldSelector) + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() } - x.FieldRef.CodecDecodeSelf(d) } - yyj1251++ - if yyhl1251 { - yyb1251 = yyj1251 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1251 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1251 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ResourceFieldRef != nil { - x.ResourceFieldRef = nil - } + x.Key = "" } else { - if x.ResourceFieldRef == nil { - x.ResourceFieldRef = new(ResourceFieldSelector) + yyv13 := &x.Key + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() } - x.ResourceFieldRef.CodecDecodeSelf(d) } - yyj1251++ - if yyhl1251 { - yyb1251 = yyj1251 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1251 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1251 { + if yyb10 { 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) + if x.Optional != nil { + x.Optional = nil } - x.ConfigMapKeyRef.CodecDecodeSelf(d) - } - yyj1251++ - if yyhl1251 { - yyb1251 = yyj1251 > l } else { - yyb1251 = r.CheckBreak() - } - if yyb1251 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.SecretKeyRef != nil { - x.SecretKeyRef = nil + if x.Optional == nil { + x.Optional = new(bool) } - } else { - if x.SecretKeyRef == nil { - x.SecretKeyRef = new(SecretKeySelector) + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() } - x.SecretKeyRef.CodecDecodeSelf(d) } for { - yyj1251++ - if yyhl1251 { - yyb1251 = yyj1251 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1251 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1251 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1251-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ObjectFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *SecretKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1256 := z.EncBinary() - _ = yym1256 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1257 := !z.EncBinary() - yy2arr1257 := z.EncBasicHandle().StructToArray - var yyq1257 [2]bool - _, _, _ = yysep1257, yyq1257, yy2arr1257 - const yyr1257 bool = false - yyq1257[0] = x.APIVersion != "" - var yynn1257 int - if yyr1257 || yy2arr1257 { - r.EncodeArrayStart(2) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[2] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) } else { - yynn1257 = 1 - for _, b := range yyq1257 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1257++ + yynn2++ } } - r.EncodeMapStart(yynn1257) - yynn1257 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1257 || yy2arr1257 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1257[0] { - yym1259 := z.EncBinary() - _ = yym1259 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1257[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1260 := z.EncBinary() - _ = yym1260 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("key")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Optional == nil { + r.EncodeNil() + } else { + yy10 := *x.Optional + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeBool(bool(yy10)) + } } - } - } - if yyr1257 || yy2arr1257 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1262 := z.EncBinary() - _ = yym1262 - if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fieldPath")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1263 := z.EncBinary() - _ = yym1263 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("optional")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Optional == nil { + r.EncodeNil() + } else { + yy12 := *x.Optional + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeBool(bool(yy12)) + } + } } } - if yyr1257 || yy2arr1257 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -17700,29 +24931,29 @@ func (x *ObjectFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ObjectFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *SecretKeySelector) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1264 := z.DecBinary() - _ = yym1264 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1265 := r.ContainerType() - if yyct1265 == codecSelferValueTypeMap1234 { - yyl1265 := r.ReadMapStart() - if yyl1265 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1265, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1265 == codecSelferValueTypeArray1234 { - yyl1265 := r.ReadArrayStart() - if yyl1265 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1265, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -17730,16 +24961,16 @@ func (x *ObjectFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ObjectFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *SecretKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1266Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1266Slc - var yyhl1266 bool = l >= 0 - for yyj1266 := 0; ; yyj1266++ { - if yyhl1266 { - if yyj1266 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -17748,194 +24979,255 @@ func (x *ObjectFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1266Slc = r.DecodeBytes(yys1266Slc, true, true) - yys1266 := string(yys1266Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1266 { - case "apiVersion": + switch yys3 { + case "name": if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "key": + if r.TryDecodeAsNil() { + x.Key = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.Key + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - case "fieldPath": + case "optional": if r.TryDecodeAsNil() { - x.FieldPath = "" + if x.Optional != nil { + x.Optional = nil + } } else { - x.FieldPath = string(r.DecodeString()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys1266) - } // end switch yys1266 - } // end for yyj1266 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ObjectFieldSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *SecretKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1269 int - var yyb1269 bool - var yyhl1269 bool = l >= 0 - yyj1269++ - if yyhl1269 { - yyb1269 = yyj1269 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1269 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1269 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Name = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj1269++ - if yyhl1269 { - yyb1269 = yyj1269 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1269 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1269 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.FieldPath = "" + x.Key = "" + } else { + yyv13 := &x.Key + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Optional != nil { + x.Optional = nil + } } else { - x.FieldPath = string(r.DecodeString()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } for { - yyj1269++ - if yyhl1269 { - yyb1269 = yyj1269 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1269 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1269 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1269-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ResourceFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *EnvFromSource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1272 := z.EncBinary() - _ = yym1272 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1273 := !z.EncBinary() - yy2arr1273 := z.EncBasicHandle().StructToArray - var yyq1273 [3]bool - _, _, _ = yysep1273, yyq1273, yy2arr1273 - const yyr1273 bool = false - yyq1273[0] = x.ContainerName != "" - yyq1273[2] = true - var yynn1273 int - if yyr1273 || yy2arr1273 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Prefix != "" + yyq2[1] = x.ConfigMapRef != nil + yyq2[2] = x.SecretRef != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1273 = 1 - for _, b := range yyq1273 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1273++ + yynn2++ } } - r.EncodeMapStart(yynn1273) - yynn1273 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1273 || yy2arr1273 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1273[0] { - yym1275 := z.EncBinary() - _ = yym1275 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) + r.EncodeString(codecSelferC_UTF81234, string(x.Prefix)) } } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1273[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("containerName")) + r.EncodeString(codecSelferC_UTF81234, string("prefix")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1276 := z.EncBinary() - _ = yym1276 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ContainerName)) + r.EncodeString(codecSelferC_UTF81234, string(x.Prefix)) } } } - if yyr1273 || yy2arr1273 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1278 := z.EncBinary() - _ = yym1278 - if false { + if yyq2[1] { + if x.ConfigMapRef == nil { + r.EncodeNil() + } else { + x.ConfigMapRef.CodecEncodeSelf(e) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resource")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1279 := z.EncBinary() - _ = yym1279 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("configMapRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ConfigMapRef == nil { + r.EncodeNil() + } else { + x.ConfigMapRef.CodecEncodeSelf(e) + } } } - if yyr1273 || yy2arr1273 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1273[2] { - yy1281 := &x.Divisor - yym1282 := z.EncBinary() - _ = yym1282 - if false { - } else if z.HasExtensions() && z.EncExt(yy1281) { - } else if !yym1282 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1281) + if yyq2[2] { + if x.SecretRef == nil { + r.EncodeNil() } else { - z.EncFallback(yy1281) + x.SecretRef.CodecEncodeSelf(e) } } else { r.EncodeNil() } } else { - if yyq1273[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("divisor")) + r.EncodeString(codecSelferC_UTF81234, string("secretRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1283 := &x.Divisor - yym1284 := z.EncBinary() - _ = yym1284 - if false { - } else if z.HasExtensions() && z.EncExt(yy1283) { - } else if !yym1284 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1283) + if x.SecretRef == nil { + r.EncodeNil() } else { - z.EncFallback(yy1283) + x.SecretRef.CodecEncodeSelf(e) } } } - if yyr1273 || yy2arr1273 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -17944,29 +25236,29 @@ func (x *ResourceFieldSelector) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ResourceFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *EnvFromSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1285 := z.DecBinary() - _ = yym1285 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1286 := r.ContainerType() - if yyct1286 == codecSelferValueTypeMap1234 { - yyl1286 := r.ReadMapStart() - if yyl1286 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1286, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1286 == codecSelferValueTypeArray1234 { - yyl1286 := r.ReadArrayStart() - if yyl1286 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1286, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -17974,16 +25266,16 @@ func (x *ResourceFieldSelector) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ResourceFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *EnvFromSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1287Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1287Slc - var yyhl1287 bool = l >= 0 - for yyj1287 := 0; ; yyj1287++ { - if yyhl1287 { - if yyj1287 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -17992,160 +25284,175 @@ func (x *ResourceFieldSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1287Slc = r.DecodeBytes(yys1287Slc, true, true) - yys1287 := string(yys1287Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1287 { - case "containerName": + switch yys3 { + case "prefix": if r.TryDecodeAsNil() { - x.ContainerName = "" + x.Prefix = "" } else { - x.ContainerName = string(r.DecodeString()) + yyv4 := &x.Prefix + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "resource": + case "configMapRef": if r.TryDecodeAsNil() { - x.Resource = "" + if x.ConfigMapRef != nil { + x.ConfigMapRef = nil + } } else { - x.Resource = string(r.DecodeString()) + if x.ConfigMapRef == nil { + x.ConfigMapRef = new(ConfigMapEnvSource) + } + x.ConfigMapRef.CodecDecodeSelf(d) } - case "divisor": + case "secretRef": if r.TryDecodeAsNil() { - x.Divisor = pkg3_resource.Quantity{} + if x.SecretRef != nil { + x.SecretRef = nil + } } else { - yyv1290 := &x.Divisor - yym1291 := z.DecBinary() - _ = yym1291 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1290) { - } else if !yym1291 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1290) - } else { - z.DecFallback(yyv1290, false) + if x.SecretRef == nil { + x.SecretRef = new(SecretEnvSource) } + x.SecretRef.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1287) - } // end switch yys1287 - } // end for yyj1287 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ResourceFieldSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *EnvFromSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1292 int - var yyb1292 bool - var yyhl1292 bool = l >= 0 - yyj1292++ - if yyhl1292 { - yyb1292 = yyj1292 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1292 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1292 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ContainerName = "" + x.Prefix = "" } else { - x.ContainerName = string(r.DecodeString()) + yyv9 := &x.Prefix + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1292++ - if yyhl1292 { - yyb1292 = yyj1292 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1292 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1292 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Resource = "" + if x.ConfigMapRef != nil { + x.ConfigMapRef = nil + } } else { - x.Resource = string(r.DecodeString()) + if x.ConfigMapRef == nil { + x.ConfigMapRef = new(ConfigMapEnvSource) + } + x.ConfigMapRef.CodecDecodeSelf(d) } - yyj1292++ - if yyhl1292 { - yyb1292 = yyj1292 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1292 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1292 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Divisor = pkg3_resource.Quantity{} + if x.SecretRef != nil { + x.SecretRef = nil + } } else { - yyv1295 := &x.Divisor - yym1296 := z.DecBinary() - _ = yym1296 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1295) { - } else if !yym1296 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1295) - } else { - z.DecFallback(yyv1295, false) + if x.SecretRef == nil { + x.SecretRef = new(SecretEnvSource) } + x.SecretRef.CodecDecodeSelf(d) } for { - yyj1292++ - if yyhl1292 { - yyb1292 = yyj1292 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1292 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1292 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1292-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ConfigMapKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ConfigMapEnvSource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1297 := z.EncBinary() - _ = yym1297 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1298 := !z.EncBinary() - yy2arr1298 := z.EncBasicHandle().StructToArray - var yyq1298 [2]bool - _, _, _ = yysep1298, yyq1298, yy2arr1298 - const yyr1298 bool = false - yyq1298[0] = x.Name != "" - var yynn1298 int - if yyr1298 || yy2arr1298 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1298 = 1 - for _, b := range yyq1298 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1298++ + yynn2++ } } - r.EncodeMapStart(yynn1298) - yynn1298 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1298 || yy2arr1298 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1298[0] { - yym1300 := z.EncBinary() - _ = yym1300 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -18154,38 +25461,54 @@ func (x *ConfigMapKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1298[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1301 := z.EncBinary() - _ = yym1301 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr1298 || yy2arr1298 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1303 := z.EncBinary() - _ = yym1303 - if false { + if yyq2[1] { + if x.Optional == nil { + r.EncodeNil() + } else { + yy7 := *x.Optional + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(yy7)) + } + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("key")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1304 := z.EncBinary() - _ = yym1304 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("optional")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Optional == nil { + r.EncodeNil() + } else { + yy9 := *x.Optional + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(yy9)) + } + } } } - if yyr1298 || yy2arr1298 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18194,29 +25517,29 @@ func (x *ConfigMapKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ConfigMapKeySelector) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ConfigMapEnvSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1305 := z.DecBinary() - _ = yym1305 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1306 := r.ContainerType() - if yyct1306 == codecSelferValueTypeMap1234 { - yyl1306 := r.ReadMapStart() - if yyl1306 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1306, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1306 == codecSelferValueTypeArray1234 { - yyl1306 := r.ReadArrayStart() - if yyl1306 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1306, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18224,16 +25547,16 @@ func (x *ConfigMapKeySelector) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ConfigMapKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ConfigMapEnvSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1307Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1307Slc - var yyhl1307 bool = l >= 0 - for yyj1307 := 0; ; yyj1307++ { - if yyhl1307 { - if yyj1307 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18242,43 +25565,59 @@ func (x *ConfigMapKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1307Slc = r.DecodeBytes(yys1307Slc, true, true) - yys1307 := string(yys1307Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1307 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "key": + case "optional": if r.TryDecodeAsNil() { - x.Key = "" + if x.Optional != nil { + x.Optional = nil + } } else { - x.Key = string(r.DecodeString()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys1307) - } // end switch yys1307 - } // end for yyj1307 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ConfigMapKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ConfigMapEnvSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1310 int - var yyb1310 bool - var yyhl1310 bool = l >= 0 - yyj1310++ - if yyhl1310 { - yyb1310 = yyj1310 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1310 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1310 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18286,76 +25625,93 @@ func (x *ConfigMapKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv9 := &x.Name + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1310++ - if yyhl1310 { - yyb1310 = yyj1310 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1310 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1310 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Key = "" + if x.Optional != nil { + x.Optional = nil + } } else { - x.Key = string(r.DecodeString()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } for { - yyj1310++ - if yyhl1310 { - yyb1310 = yyj1310 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1310 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1310 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1310-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *SecretKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *SecretEnvSource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1313 := z.EncBinary() - _ = yym1313 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1314 := !z.EncBinary() - yy2arr1314 := z.EncBasicHandle().StructToArray - var yyq1314 [2]bool - _, _, _ = yysep1314, yyq1314, yy2arr1314 - const yyr1314 bool = false - yyq1314[0] = x.Name != "" - var yynn1314 int - if yyr1314 || yy2arr1314 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = x.Optional != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1314 = 1 - for _, b := range yyq1314 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1314++ + yynn2++ } } - r.EncodeMapStart(yynn1314) - yynn1314 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1314 || yy2arr1314 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1314[0] { - yym1316 := z.EncBinary() - _ = yym1316 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -18364,38 +25720,54 @@ func (x *SecretKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1314[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1317 := z.EncBinary() - _ = yym1317 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr1314 || yy2arr1314 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1319 := z.EncBinary() - _ = yym1319 - if false { + if yyq2[1] { + if x.Optional == nil { + r.EncodeNil() + } else { + yy7 := *x.Optional + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeBool(bool(yy7)) + } + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("key")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1320 := z.EncBinary() - _ = yym1320 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Key)) + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("optional")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Optional == nil { + r.EncodeNil() + } else { + yy9 := *x.Optional + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeBool(bool(yy9)) + } + } } } - if yyr1314 || yy2arr1314 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18404,29 +25776,29 @@ func (x *SecretKeySelector) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *SecretKeySelector) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *SecretEnvSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1321 := z.DecBinary() - _ = yym1321 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1322 := r.ContainerType() - if yyct1322 == codecSelferValueTypeMap1234 { - yyl1322 := r.ReadMapStart() - if yyl1322 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1322, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1322 == codecSelferValueTypeArray1234 { - yyl1322 := r.ReadArrayStart() - if yyl1322 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1322, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18434,16 +25806,16 @@ func (x *SecretKeySelector) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *SecretKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *SecretEnvSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1323Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1323Slc - var yyhl1323 bool = l >= 0 - for yyj1323 := 0; ; yyj1323++ { - if yyhl1323 { - if yyj1323 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18452,43 +25824,59 @@ func (x *SecretKeySelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1323Slc = r.DecodeBytes(yys1323Slc, true, true) - yys1323 := string(yys1323Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1323 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "key": + case "optional": if r.TryDecodeAsNil() { - x.Key = "" + if x.Optional != nil { + x.Optional = nil + } } else { - x.Key = string(r.DecodeString()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys1323) - } // end switch yys1323 - } // end for yyj1323 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *SecretKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *SecretEnvSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1326 int - var yyb1326 bool - var yyhl1326 bool = l >= 0 - yyj1326++ - if yyhl1326 { - yyb1326 = yyj1326 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1326 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1326 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18496,36 +25884,52 @@ func (x *SecretKeySelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv9 := &x.Name + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1326++ - if yyhl1326 { - yyb1326 = yyj1326 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1326 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1326 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Key = "" + if x.Optional != nil { + x.Optional = nil + } } else { - x.Key = string(r.DecodeString()) + if x.Optional == nil { + x.Optional = new(bool) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(x.Optional)) = r.DecodeBool() + } } for { - yyj1326++ - if yyhl1326 { - yyb1326 = yyj1326 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1326 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1326 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1326-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18537,33 +25941,33 @@ func (x *HTTPHeader) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1329 := z.EncBinary() - _ = yym1329 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1330 := !z.EncBinary() - yy2arr1330 := z.EncBasicHandle().StructToArray - var yyq1330 [2]bool - _, _, _ = yysep1330, yyq1330, yy2arr1330 - const yyr1330 bool = false - var yynn1330 int - if yyr1330 || yy2arr1330 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1330 = 2 - for _, b := range yyq1330 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1330++ + yynn2++ } } - r.EncodeMapStart(yynn1330) - yynn1330 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1330 || yy2arr1330 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1332 := z.EncBinary() - _ = yym1332 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -18572,17 +25976,17 @@ func (x *HTTPHeader) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1333 := z.EncBinary() - _ = yym1333 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr1330 || yy2arr1330 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1335 := z.EncBinary() - _ = yym1335 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Value)) @@ -18591,14 +25995,14 @@ func (x *HTTPHeader) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("value")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1336 := z.EncBinary() - _ = yym1336 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Value)) } } - if yyr1330 || yy2arr1330 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18611,25 +26015,25 @@ func (x *HTTPHeader) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1337 := z.DecBinary() - _ = yym1337 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1338 := r.ContainerType() - if yyct1338 == codecSelferValueTypeMap1234 { - yyl1338 := r.ReadMapStart() - if yyl1338 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1338, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1338 == codecSelferValueTypeArray1234 { - yyl1338 := r.ReadArrayStart() - if yyl1338 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1338, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18641,12 +26045,12 @@ func (x *HTTPHeader) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1339Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1339Slc - var yyhl1339 bool = l >= 0 - for yyj1339 := 0; ; yyj1339++ { - if yyhl1339 { - if yyj1339 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18655,26 +26059,38 @@ func (x *HTTPHeader) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1339Slc = r.DecodeBytes(yys1339Slc, true, true) - yys1339 := string(yys1339Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1339 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "value": if r.TryDecodeAsNil() { x.Value = "" } else { - x.Value = string(r.DecodeString()) + yyv6 := &x.Value + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1339) - } // end switch yys1339 - } // end for yyj1339 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -18682,16 +26098,16 @@ func (x *HTTPHeader) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1342 int - var yyb1342 bool - var yyhl1342 bool = l >= 0 - yyj1342++ - if yyhl1342 { - yyb1342 = yyj1342 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1342 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1342 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18699,15 +26115,21 @@ func (x *HTTPHeader) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv9 := &x.Name + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1342++ - if yyhl1342 { - yyb1342 = yyj1342 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1342 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1342 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18715,20 +26137,26 @@ func (x *HTTPHeader) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Value = "" } else { - x.Value = string(r.DecodeString()) + yyv11 := &x.Value + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj1342++ - if yyhl1342 { - yyb1342 = yyj1342 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1342 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1342 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1342-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18740,38 +26168,38 @@ func (x *HTTPGetAction) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1345 := z.EncBinary() - _ = yym1345 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1346 := !z.EncBinary() - yy2arr1346 := z.EncBasicHandle().StructToArray - var yyq1346 [5]bool - _, _, _ = yysep1346, yyq1346, yy2arr1346 - const yyr1346 bool = false - yyq1346[0] = x.Path != "" - yyq1346[2] = x.Host != "" - yyq1346[3] = x.Scheme != "" - yyq1346[4] = len(x.HTTPHeaders) != 0 - var yynn1346 int - if yyr1346 || yy2arr1346 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Path != "" + yyq2[2] = x.Host != "" + yyq2[3] = x.Scheme != "" + yyq2[4] = len(x.HTTPHeaders) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn1346 = 1 - for _, b := range yyq1346 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1346++ + yynn2++ } } - r.EncodeMapStart(yynn1346) - yynn1346 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1346 || yy2arr1346 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1346[0] { - yym1348 := z.EncBinary() - _ = yym1348 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -18780,50 +26208,50 @@ func (x *HTTPGetAction) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1346[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1349 := z.EncBinary() - _ = yym1349 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr1346 || yy2arr1346 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1351 := &x.Port - yym1352 := z.EncBinary() - _ = yym1352 + yy7 := &x.Port + yym8 := z.EncBinary() + _ = yym8 if false { - } else if z.HasExtensions() && z.EncExt(yy1351) { - } else if !yym1352 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1351) + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) } else { - z.EncFallback(yy1351) + z.EncFallback(yy7) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("port")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1353 := &x.Port - yym1354 := z.EncBinary() - _ = yym1354 + yy9 := &x.Port + yym10 := z.EncBinary() + _ = yym10 if false { - } else if z.HasExtensions() && z.EncExt(yy1353) { - } else if !yym1354 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1353) + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) } else { - z.EncFallback(yy1353) + z.EncFallback(yy9) } } - if yyr1346 || yy2arr1346 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1346[2] { - yym1356 := z.EncBinary() - _ = yym1356 + if yyq2[2] { + yym12 := z.EncBinary() + _ = yym12 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Host)) @@ -18832,41 +26260,41 @@ func (x *HTTPGetAction) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1346[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("host")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1357 := z.EncBinary() - _ = yym1357 + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Host)) } } } - if yyr1346 || yy2arr1346 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1346[3] { + if yyq2[3] { x.Scheme.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1346[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("scheme")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Scheme.CodecEncodeSelf(e) } } - if yyr1346 || yy2arr1346 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1346[4] { + if yyq2[4] { if x.HTTPHeaders == nil { r.EncodeNil() } else { - yym1360 := z.EncBinary() - _ = yym1360 + yym18 := z.EncBinary() + _ = yym18 if false { } else { h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e) @@ -18876,15 +26304,15 @@ func (x *HTTPGetAction) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1346[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("httpHeaders")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.HTTPHeaders == nil { r.EncodeNil() } else { - yym1361 := z.EncBinary() - _ = yym1361 + yym19 := z.EncBinary() + _ = yym19 if false { } else { h.encSliceHTTPHeader(([]HTTPHeader)(x.HTTPHeaders), e) @@ -18892,7 +26320,7 @@ func (x *HTTPGetAction) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1346 || yy2arr1346 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18905,25 +26333,25 @@ func (x *HTTPGetAction) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1362 := z.DecBinary() - _ = yym1362 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1363 := r.ContainerType() - if yyct1363 == codecSelferValueTypeMap1234 { - yyl1363 := r.ReadMapStart() - if yyl1363 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1363, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1363 == codecSelferValueTypeArray1234 { - yyl1363 := r.ReadArrayStart() - if yyl1363 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1363, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18935,12 +26363,12 @@ func (x *HTTPGetAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1364Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1364Slc - var yyhl1364 bool = l >= 0 - for yyj1364 := 0; ; yyj1364++ { - if yyhl1364 { - if yyj1364 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18949,59 +26377,72 @@ func (x *HTTPGetAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1364Slc = r.DecodeBytes(yys1364Slc, true, true) - yys1364 := string(yys1364Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1364 { + switch yys3 { case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "port": if r.TryDecodeAsNil() { x.Port = pkg4_intstr.IntOrString{} } else { - yyv1366 := &x.Port - yym1367 := z.DecBinary() - _ = yym1367 + yyv6 := &x.Port + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv1366) { - } else if !yym1367 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1366) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv1366, false) + z.DecFallback(yyv6, false) } } case "host": if r.TryDecodeAsNil() { x.Host = "" } else { - x.Host = string(r.DecodeString()) + yyv8 := &x.Host + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "scheme": if r.TryDecodeAsNil() { x.Scheme = "" } else { - x.Scheme = URIScheme(r.DecodeString()) + yyv10 := &x.Scheme + yyv10.CodecDecodeSelf(d) } case "httpHeaders": if r.TryDecodeAsNil() { x.HTTPHeaders = nil } else { - yyv1370 := &x.HTTPHeaders - yym1371 := z.DecBinary() - _ = yym1371 + yyv11 := &x.HTTPHeaders + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceHTTPHeader((*[]HTTPHeader)(yyv1370), d) + h.decSliceHTTPHeader((*[]HTTPHeader)(yyv11), d) } } default: - z.DecStructFieldNotFound(-1, yys1364) - } // end switch yys1364 - } // end for yyj1364 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19009,16 +26450,16 @@ func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1372 int - var yyb1372 bool - var yyhl1372 bool = l >= 0 - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1372 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1372 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19026,15 +26467,21 @@ func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv14 := &x.Path + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1372 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1372 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19042,24 +26489,24 @@ func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Port = pkg4_intstr.IntOrString{} } else { - yyv1374 := &x.Port - yym1375 := z.DecBinary() - _ = yym1375 + yyv16 := &x.Port + yym17 := z.DecBinary() + _ = yym17 if false { - } else if z.HasExtensions() && z.DecExt(yyv1374) { - } else if !yym1375 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1374) + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else if !yym17 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv16) } else { - z.DecFallback(yyv1374, false) + z.DecFallback(yyv16, false) } } - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1372 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1372 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19067,15 +26514,21 @@ func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Host = "" } else { - x.Host = string(r.DecodeString()) + yyv18 := &x.Host + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } } - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1372 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1372 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19083,15 +26536,16 @@ func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Scheme = "" } else { - x.Scheme = URIScheme(r.DecodeString()) + yyv20 := &x.Scheme + yyv20.CodecDecodeSelf(d) } - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1372 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1372 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19099,26 +26553,26 @@ func (x *HTTPGetAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.HTTPHeaders = nil } else { - yyv1378 := &x.HTTPHeaders - yym1379 := z.DecBinary() - _ = yym1379 + yyv21 := &x.HTTPHeaders + yym22 := z.DecBinary() + _ = yym22 if false { } else { - h.decSliceHTTPHeader((*[]HTTPHeader)(yyv1378), d) + h.decSliceHTTPHeader((*[]HTTPHeader)(yyv21), d) } } for { - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb1372 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb1372 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1372-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -19127,8 +26581,8 @@ func (x URIScheme) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1380 := z.EncBinary() - _ = yym1380 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -19140,8 +26594,8 @@ func (x *URIScheme) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1381 := z.DecBinary() - _ = yym1381 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -19156,57 +26610,83 @@ func (x *TCPSocketAction) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1382 := z.EncBinary() - _ = yym1382 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1383 := !z.EncBinary() - yy2arr1383 := z.EncBasicHandle().StructToArray - var yyq1383 [1]bool - _, _, _ = yysep1383, yyq1383, yy2arr1383 - const yyr1383 bool = false - var yynn1383 int - if yyr1383 || yy2arr1383 { - r.EncodeArrayStart(1) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Host != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn1383 = 1 - for _, b := range yyq1383 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1383++ + yynn2++ } } - r.EncodeMapStart(yynn1383) - yynn1383 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1383 || yy2arr1383 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1385 := &x.Port - yym1386 := z.EncBinary() - _ = yym1386 + yy4 := &x.Port + yym5 := z.EncBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.EncExt(yy1385) { - } else if !yym1386 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1385) + } else if z.HasExtensions() && z.EncExt(yy4) { + } else if !yym5 && z.IsJSONHandle() { + z.EncJSONMarshal(yy4) } else { - z.EncFallback(yy1385) + z.EncFallback(yy4) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("port")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1387 := &x.Port - yym1388 := z.EncBinary() - _ = yym1388 + yy6 := &x.Port + yym7 := z.EncBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.EncExt(yy1387) { - } else if !yym1388 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1387) + } else if z.HasExtensions() && z.EncExt(yy6) { + } else if !yym7 && z.IsJSONHandle() { + z.EncJSONMarshal(yy6) + } else { + z.EncFallback(yy6) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Host)) + } } else { - z.EncFallback(yy1387) + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("host")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Host)) + } } } - if yyr1383 || yy2arr1383 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -19219,25 +26699,25 @@ func (x *TCPSocketAction) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1389 := z.DecBinary() - _ = yym1389 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1390 := r.ContainerType() - if yyct1390 == codecSelferValueTypeMap1234 { - yyl1390 := r.ReadMapStart() - if yyl1390 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1390, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1390 == codecSelferValueTypeArray1234 { - yyl1390 := r.ReadArrayStart() - if yyl1390 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1390, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -19249,12 +26729,12 @@ func (x *TCPSocketAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1391Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1391Slc - var yyhl1391 bool = l >= 0 - for yyj1391 := 0; ; yyj1391++ { - if yyhl1391 { - if yyj1391 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -19263,29 +26743,41 @@ func (x *TCPSocketAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1391Slc = r.DecodeBytes(yys1391Slc, true, true) - yys1391 := string(yys1391Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1391 { + switch yys3 { case "port": if r.TryDecodeAsNil() { x.Port = pkg4_intstr.IntOrString{} } else { - yyv1392 := &x.Port - yym1393 := z.DecBinary() - _ = yym1393 + yyv4 := &x.Port + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv4) + } else { + z.DecFallback(yyv4, false) + } + } + case "host": + if r.TryDecodeAsNil() { + x.Host = "" + } else { + yyv6 := &x.Host + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv1392) { - } else if !yym1393 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1392) } else { - z.DecFallback(yyv1392, false) + *((*string)(yyv6)) = r.DecodeString() } } default: - z.DecStructFieldNotFound(-1, yys1391) - } // end switch yys1391 - } // end for yyj1391 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19293,16 +26785,16 @@ func (x *TCPSocketAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1394 int - var yyb1394 bool - var yyhl1394 bool = l >= 0 - yyj1394++ - if yyhl1394 { - yyb1394 = yyj1394 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1394 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1394 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19310,29 +26802,51 @@ func (x *TCPSocketAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Port = pkg4_intstr.IntOrString{} } else { - yyv1395 := &x.Port - yym1396 := z.DecBinary() - _ = yym1396 + yyv9 := &x.Port + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) + } else { + z.DecFallback(yyv9, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Host = "" + } else { + yyv11 := &x.Host + yym12 := z.DecBinary() + _ = yym12 if false { - } else if z.HasExtensions() && z.DecExt(yyv1395) { - } else if !yym1396 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1395) } else { - z.DecFallback(yyv1395, false) + *((*string)(yyv11)) = r.DecodeString() } } for { - yyj1394++ - if yyhl1394 { - yyb1394 = yyj1394 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1394 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1394 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1394-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -19344,38 +26858,38 @@ func (x *ExecAction) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1397 := z.EncBinary() - _ = yym1397 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1398 := !z.EncBinary() - yy2arr1398 := z.EncBasicHandle().StructToArray - var yyq1398 [1]bool - _, _, _ = yysep1398, yyq1398, yy2arr1398 - const yyr1398 bool = false - yyq1398[0] = len(x.Command) != 0 - var yynn1398 int - if yyr1398 || yy2arr1398 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Command) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1398 = 0 - for _, b := range yyq1398 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1398++ + yynn2++ } } - r.EncodeMapStart(yynn1398) - yynn1398 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1398[0] { + if yyq2[0] { if x.Command == nil { r.EncodeNil() } else { - yym1400 := z.EncBinary() - _ = yym1400 + yym4 := z.EncBinary() + _ = yym4 if false { } else { z.F.EncSliceStringV(x.Command, false, e) @@ -19385,15 +26899,15 @@ func (x *ExecAction) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1398[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("command")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Command == nil { r.EncodeNil() } else { - yym1401 := z.EncBinary() - _ = yym1401 + yym5 := z.EncBinary() + _ = yym5 if false { } else { z.F.EncSliceStringV(x.Command, false, e) @@ -19401,7 +26915,7 @@ func (x *ExecAction) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -19414,25 +26928,25 @@ func (x *ExecAction) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1402 := z.DecBinary() - _ = yym1402 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1403 := r.ContainerType() - if yyct1403 == codecSelferValueTypeMap1234 { - yyl1403 := r.ReadMapStart() - if yyl1403 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1403, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1403 == codecSelferValueTypeArray1234 { - yyl1403 := r.ReadArrayStart() - if yyl1403 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1403, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -19444,12 +26958,12 @@ func (x *ExecAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1404Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1404Slc - var yyhl1404 bool = l >= 0 - for yyj1404 := 0; ; yyj1404++ { - if yyhl1404 { - if yyj1404 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -19458,26 +26972,26 @@ func (x *ExecAction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1404Slc = r.DecodeBytes(yys1404Slc, true, true) - yys1404 := string(yys1404Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1404 { + switch yys3 { case "command": if r.TryDecodeAsNil() { x.Command = nil } else { - yyv1405 := &x.Command - yym1406 := z.DecBinary() - _ = yym1406 + yyv4 := &x.Command + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv1405, false, d) + z.F.DecSliceStringX(yyv4, false, d) } } default: - z.DecStructFieldNotFound(-1, yys1404) - } // end switch yys1404 - } // end for yyj1404 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19485,16 +26999,16 @@ func (x *ExecAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1407 int - var yyb1407 bool - var yyhl1407 bool = l >= 0 - yyj1407++ - if yyhl1407 { - yyb1407 = yyj1407 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1407 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1407 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19502,26 +27016,26 @@ func (x *ExecAction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Command = nil } else { - yyv1408 := &x.Command - yym1409 := z.DecBinary() - _ = yym1409 + yyv7 := &x.Command + yym8 := z.DecBinary() + _ = yym8 if false { } else { - z.F.DecSliceStringX(yyv1408, false, d) + z.F.DecSliceStringX(yyv7, false, d) } } for { - yyj1407++ - if yyhl1407 { - yyb1407 = yyj1407 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1407 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1407 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1407-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -19533,49 +27047,49 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1410 := z.EncBinary() - _ = yym1410 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1411 := !z.EncBinary() - yy2arr1411 := z.EncBasicHandle().StructToArray - var yyq1411 [8]bool - _, _, _ = yysep1411, yyq1411, yy2arr1411 - const yyr1411 bool = false - yyq1411[0] = x.Handler.Exec != nil && x.Exec != nil - yyq1411[1] = x.Handler.HTTPGet != nil && x.HTTPGet != nil - yyq1411[2] = x.Handler.TCPSocket != nil && x.TCPSocket != nil - yyq1411[3] = x.InitialDelaySeconds != 0 - yyq1411[4] = x.TimeoutSeconds != 0 - yyq1411[5] = x.PeriodSeconds != 0 - yyq1411[6] = x.SuccessThreshold != 0 - yyq1411[7] = x.FailureThreshold != 0 - var yynn1411 int - if yyr1411 || yy2arr1411 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Handler.Exec != nil && x.Exec != nil + yyq2[1] = x.Handler.HTTPGet != nil && x.HTTPGet != nil + yyq2[2] = x.Handler.TCPSocket != nil && x.TCPSocket != nil + yyq2[3] = x.InitialDelaySeconds != 0 + yyq2[4] = x.TimeoutSeconds != 0 + yyq2[5] = x.PeriodSeconds != 0 + yyq2[6] = x.SuccessThreshold != 0 + yyq2[7] = x.FailureThreshold != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(8) } else { - yynn1411 = 0 - for _, b := range yyq1411 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1411++ + yynn2++ } } - r.EncodeMapStart(yynn1411) - yynn1411 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - var yyn1412 bool + var yyn3 bool if x.Handler.Exec == nil { - yyn1412 = true - goto LABEL1412 + yyn3 = true + goto LABEL3 } - LABEL1412: - if yyr1411 || yy2arr1411 { - if yyn1412 { + LABEL3: + if yyr2 || yy2arr2 { + if yyn3 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[0] { + if yyq2[0] { if x.Exec == nil { r.EncodeNil() } else { @@ -19586,11 +27100,11 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq1411[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("exec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1412 { + if yyn3 { r.EncodeNil() } else { if x.Exec == nil { @@ -19601,18 +27115,18 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn1413 bool + var yyn6 bool if x.Handler.HTTPGet == nil { - yyn1413 = true - goto LABEL1413 + yyn6 = true + goto LABEL6 } - LABEL1413: - if yyr1411 || yy2arr1411 { - if yyn1413 { + LABEL6: + if yyr2 || yy2arr2 { + if yyn6 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[1] { + if yyq2[1] { if x.HTTPGet == nil { r.EncodeNil() } else { @@ -19623,11 +27137,11 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq1411[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("httpGet")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1413 { + if yyn6 { r.EncodeNil() } else { if x.HTTPGet == nil { @@ -19638,18 +27152,18 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { } } } - var yyn1414 bool + var yyn9 bool if x.Handler.TCPSocket == nil { - yyn1414 = true - goto LABEL1414 + yyn9 = true + goto LABEL9 } - LABEL1414: - if yyr1411 || yy2arr1411 { - if yyn1414 { + LABEL9: + if yyr2 || yy2arr2 { + if yyn9 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[2] { + if yyq2[2] { if x.TCPSocket == nil { r.EncodeNil() } else { @@ -19660,11 +27174,11 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq1411[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tcpSocket")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1414 { + if yyn9 { r.EncodeNil() } else { if x.TCPSocket == nil { @@ -19675,11 +27189,11 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1411 || yy2arr1411 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[3] { - yym1416 := z.EncBinary() - _ = yym1416 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeInt(int64(x.InitialDelaySeconds)) @@ -19688,23 +27202,23 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1411[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("initialDelaySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1417 := z.EncBinary() - _ = yym1417 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeInt(int64(x.InitialDelaySeconds)) } } } - if yyr1411 || yy2arr1411 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[4] { - yym1419 := z.EncBinary() - _ = yym1419 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeInt(int64(x.TimeoutSeconds)) @@ -19713,23 +27227,23 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1411[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1420 := z.EncBinary() - _ = yym1420 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeInt(int64(x.TimeoutSeconds)) } } } - if yyr1411 || yy2arr1411 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[5] { - yym1422 := z.EncBinary() - _ = yym1422 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeInt(int64(x.PeriodSeconds)) @@ -19738,23 +27252,23 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1411[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("periodSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1423 := z.EncBinary() - _ = yym1423 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeInt(int64(x.PeriodSeconds)) } } } - if yyr1411 || yy2arr1411 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[6] { - yym1425 := z.EncBinary() - _ = yym1425 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeInt(int64(x.SuccessThreshold)) @@ -19763,23 +27277,23 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1411[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("successThreshold")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1426 := z.EncBinary() - _ = yym1426 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeInt(int64(x.SuccessThreshold)) } } } - if yyr1411 || yy2arr1411 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1411[7] { - yym1428 := z.EncBinary() - _ = yym1428 + if yyq2[7] { + yym25 := z.EncBinary() + _ = yym25 if false { } else { r.EncodeInt(int64(x.FailureThreshold)) @@ -19788,19 +27302,19 @@ func (x *Probe) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1411[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("failureThreshold")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1429 := z.EncBinary() - _ = yym1429 + yym26 := z.EncBinary() + _ = yym26 if false { } else { r.EncodeInt(int64(x.FailureThreshold)) } } } - if yyr1411 || yy2arr1411 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -19813,25 +27327,25 @@ func (x *Probe) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1430 := z.DecBinary() - _ = yym1430 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1431 := r.ContainerType() - if yyct1431 == codecSelferValueTypeMap1234 { - yyl1431 := r.ReadMapStart() - if yyl1431 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1431, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1431 == codecSelferValueTypeArray1234 { - yyl1431 := r.ReadArrayStart() - if yyl1431 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1431, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -19843,12 +27357,12 @@ func (x *Probe) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1432Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1432Slc - var yyhl1432 bool = l >= 0 - for yyj1432 := 0; ; yyj1432++ { - if yyhl1432 { - if yyj1432 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -19857,10 +27371,10 @@ func (x *Probe) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1432Slc = r.DecodeBytes(yys1432Slc, true, true) - yys1432 := string(yys1432Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1432 { + switch yys3 { case "exec": if x.Handler.Exec == nil { x.Handler.Exec = new(ExecAction) @@ -19907,36 +27421,66 @@ func (x *Probe) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.InitialDelaySeconds = 0 } else { - x.InitialDelaySeconds = int32(r.DecodeInt(32)) + yyv7 := &x.InitialDelaySeconds + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } } case "timeoutSeconds": if r.TryDecodeAsNil() { x.TimeoutSeconds = 0 } else { - x.TimeoutSeconds = int32(r.DecodeInt(32)) + yyv9 := &x.TimeoutSeconds + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*int32)(yyv9)) = int32(r.DecodeInt(32)) + } } case "periodSeconds": if r.TryDecodeAsNil() { x.PeriodSeconds = 0 } else { - x.PeriodSeconds = int32(r.DecodeInt(32)) + yyv11 := &x.PeriodSeconds + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(yyv11)) = int32(r.DecodeInt(32)) + } } case "successThreshold": if r.TryDecodeAsNil() { x.SuccessThreshold = 0 } else { - x.SuccessThreshold = int32(r.DecodeInt(32)) + yyv13 := &x.SuccessThreshold + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*int32)(yyv13)) = int32(r.DecodeInt(32)) + } } case "failureThreshold": if r.TryDecodeAsNil() { x.FailureThreshold = 0 } else { - x.FailureThreshold = int32(r.DecodeInt(32)) + yyv15 := &x.FailureThreshold + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(yyv15)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys1432) - } // end switch yys1432 - } // end for yyj1432 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19944,19 +27488,19 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1441 int - var yyb1441 bool - var yyhl1441 bool = l >= 0 + var yyj17 int + var yyb17 bool + var yyhl17 bool = l >= 0 if x.Handler.Exec == nil { x.Handler.Exec = new(ExecAction) } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19974,13 +27518,13 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Handler.HTTPGet == nil { x.Handler.HTTPGet = new(HTTPGetAction) } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19998,13 +27542,13 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Handler.TCPSocket == nil { x.Handler.TCPSocket = new(TCPSocketAction) } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20019,13 +27563,13 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.TCPSocket.CodecDecodeSelf(d) } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20033,15 +27577,21 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.InitialDelaySeconds = 0 } else { - x.InitialDelaySeconds = int32(r.DecodeInt(32)) + yyv21 := &x.InitialDelaySeconds + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20049,15 +27599,21 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TimeoutSeconds = 0 } else { - x.TimeoutSeconds = int32(r.DecodeInt(32)) + yyv23 := &x.TimeoutSeconds + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20065,15 +27621,21 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PeriodSeconds = 0 } else { - x.PeriodSeconds = int32(r.DecodeInt(32)) + yyv25 := &x.PeriodSeconds + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20081,15 +27643,21 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.SuccessThreshold = 0 } else { - x.SuccessThreshold = int32(r.DecodeInt(32)) + yyv27 := &x.SuccessThreshold + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) + } } - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20097,20 +27665,26 @@ func (x *Probe) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.FailureThreshold = 0 } else { - x.FailureThreshold = int32(r.DecodeInt(32)) + yyv29 := &x.FailureThreshold + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int32)(yyv29)) = int32(r.DecodeInt(32)) + } } for { - yyj1441++ - if yyhl1441 { - yyb1441 = yyj1441 > l + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l } else { - yyb1441 = r.CheckBreak() + yyb17 = r.CheckBreak() } - if yyb1441 { + if yyb17 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1441-1, "") + z.DecStructFieldNotFound(yyj17-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20119,8 +27693,8 @@ func (x PullPolicy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1450 := z.EncBinary() - _ = yym1450 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -20132,8 +27706,34 @@ func (x *PullPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1451 := z.DecBinary() - _ = yym1451 + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x TerminationMessagePolicy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *TerminationMessagePolicy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -20145,8 +27745,8 @@ func (x Capability) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1452 := z.EncBinary() - _ = yym1452 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -20158,8 +27758,8 @@ func (x *Capability) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1453 := z.DecBinary() - _ = yym1453 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -20174,39 +27774,39 @@ func (x *Capabilities) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1454 := z.EncBinary() - _ = yym1454 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1455 := !z.EncBinary() - yy2arr1455 := z.EncBasicHandle().StructToArray - var yyq1455 [2]bool - _, _, _ = yysep1455, yyq1455, yy2arr1455 - const yyr1455 bool = false - yyq1455[0] = len(x.Add) != 0 - yyq1455[1] = len(x.Drop) != 0 - var yynn1455 int - if yyr1455 || yy2arr1455 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Add) != 0 + yyq2[1] = len(x.Drop) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1455 = 0 - for _, b := range yyq1455 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1455++ + yynn2++ } } - r.EncodeMapStart(yynn1455) - yynn1455 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1455 || yy2arr1455 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1455[0] { + if yyq2[0] { if x.Add == nil { r.EncodeNil() } else { - yym1457 := z.EncBinary() - _ = yym1457 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceCapability(([]Capability)(x.Add), e) @@ -20216,15 +27816,15 @@ func (x *Capabilities) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1455[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("add")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Add == nil { r.EncodeNil() } else { - yym1458 := z.EncBinary() - _ = yym1458 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceCapability(([]Capability)(x.Add), e) @@ -20232,14 +27832,14 @@ func (x *Capabilities) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1455 || yy2arr1455 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1455[1] { + if yyq2[1] { if x.Drop == nil { r.EncodeNil() } else { - yym1460 := z.EncBinary() - _ = yym1460 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceCapability(([]Capability)(x.Drop), e) @@ -20249,15 +27849,15 @@ func (x *Capabilities) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1455[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("drop")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Drop == nil { r.EncodeNil() } else { - yym1461 := z.EncBinary() - _ = yym1461 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceCapability(([]Capability)(x.Drop), e) @@ -20265,7 +27865,7 @@ func (x *Capabilities) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1455 || yy2arr1455 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -20278,25 +27878,25 @@ func (x *Capabilities) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1462 := z.DecBinary() - _ = yym1462 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1463 := r.ContainerType() - if yyct1463 == codecSelferValueTypeMap1234 { - yyl1463 := r.ReadMapStart() - if yyl1463 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1463, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1463 == codecSelferValueTypeArray1234 { - yyl1463 := r.ReadArrayStart() - if yyl1463 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1463, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -20308,12 +27908,12 @@ func (x *Capabilities) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1464Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1464Slc - var yyhl1464 bool = l >= 0 - for yyj1464 := 0; ; yyj1464++ { - if yyhl1464 { - if yyj1464 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -20322,38 +27922,38 @@ func (x *Capabilities) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1464Slc = r.DecodeBytes(yys1464Slc, true, true) - yys1464 := string(yys1464Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1464 { + switch yys3 { case "add": if r.TryDecodeAsNil() { x.Add = nil } else { - yyv1465 := &x.Add - yym1466 := z.DecBinary() - _ = yym1466 + yyv4 := &x.Add + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceCapability((*[]Capability)(yyv1465), d) + h.decSliceCapability((*[]Capability)(yyv4), d) } } case "drop": if r.TryDecodeAsNil() { x.Drop = nil } else { - yyv1467 := &x.Drop - yym1468 := z.DecBinary() - _ = yym1468 + yyv6 := &x.Drop + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceCapability((*[]Capability)(yyv1467), d) + h.decSliceCapability((*[]Capability)(yyv6), d) } } default: - z.DecStructFieldNotFound(-1, yys1464) - } // end switch yys1464 - } // end for yyj1464 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -20361,16 +27961,16 @@ func (x *Capabilities) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1469 int - var yyb1469 bool - var yyhl1469 bool = l >= 0 - yyj1469++ - if yyhl1469 { - yyb1469 = yyj1469 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1469 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1469 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20378,21 +27978,21 @@ func (x *Capabilities) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Add = nil } else { - yyv1470 := &x.Add - yym1471 := z.DecBinary() - _ = yym1471 + yyv9 := &x.Add + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceCapability((*[]Capability)(yyv1470), d) + h.decSliceCapability((*[]Capability)(yyv9), d) } } - yyj1469++ - if yyhl1469 { - yyb1469 = yyj1469 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1469 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1469 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20400,26 +28000,26 @@ func (x *Capabilities) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Drop = nil } else { - yyv1472 := &x.Drop - yym1473 := z.DecBinary() - _ = yym1473 + yyv11 := &x.Drop + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceCapability((*[]Capability)(yyv1472), d) + h.decSliceCapability((*[]Capability)(yyv11), d) } } for { - yyj1469++ - if yyhl1469 { - yyb1469 = yyj1469 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1469 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1469 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1469-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20431,34 +28031,34 @@ func (x *ResourceRequirements) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1474 := z.EncBinary() - _ = yym1474 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1475 := !z.EncBinary() - yy2arr1475 := z.EncBasicHandle().StructToArray - var yyq1475 [2]bool - _, _, _ = yysep1475, yyq1475, yy2arr1475 - const yyr1475 bool = false - yyq1475[0] = len(x.Limits) != 0 - yyq1475[1] = len(x.Requests) != 0 - var yynn1475 int - if yyr1475 || yy2arr1475 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Limits) != 0 + yyq2[1] = len(x.Requests) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1475 = 0 - for _, b := range yyq1475 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1475++ + yynn2++ } } - r.EncodeMapStart(yynn1475) - yynn1475 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1475 || yy2arr1475 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1475[0] { + if yyq2[0] { if x.Limits == nil { r.EncodeNil() } else { @@ -20468,7 +28068,7 @@ func (x *ResourceRequirements) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1475[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("limits")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -20479,9 +28079,9 @@ func (x *ResourceRequirements) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1475 || yy2arr1475 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1475[1] { + if yyq2[1] { if x.Requests == nil { r.EncodeNil() } else { @@ -20491,7 +28091,7 @@ func (x *ResourceRequirements) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1475[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("requests")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -20502,7 +28102,7 @@ func (x *ResourceRequirements) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1475 || yy2arr1475 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -20515,25 +28115,25 @@ func (x *ResourceRequirements) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1478 := z.DecBinary() - _ = yym1478 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1479 := r.ContainerType() - if yyct1479 == codecSelferValueTypeMap1234 { - yyl1479 := r.ReadMapStart() - if yyl1479 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1479, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1479 == codecSelferValueTypeArray1234 { - yyl1479 := r.ReadArrayStart() - if yyl1479 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1479, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -20545,12 +28145,12 @@ func (x *ResourceRequirements) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1480Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1480Slc - var yyhl1480 bool = l >= 0 - for yyj1480 := 0; ; yyj1480++ { - if yyhl1480 { - if yyj1480 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -20559,28 +28159,28 @@ func (x *ResourceRequirements) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1480Slc = r.DecodeBytes(yys1480Slc, true, true) - yys1480 := string(yys1480Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1480 { + switch yys3 { case "limits": if r.TryDecodeAsNil() { x.Limits = nil } else { - yyv1481 := &x.Limits - yyv1481.CodecDecodeSelf(d) + yyv4 := &x.Limits + yyv4.CodecDecodeSelf(d) } case "requests": if r.TryDecodeAsNil() { x.Requests = nil } else { - yyv1482 := &x.Requests - yyv1482.CodecDecodeSelf(d) + yyv5 := &x.Requests + yyv5.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1480) - } // end switch yys1480 - } // end for yyj1480 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -20588,16 +28188,16 @@ func (x *ResourceRequirements) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1483 int - var yyb1483 bool - var yyhl1483 bool = l >= 0 - yyj1483++ - if yyhl1483 { - yyb1483 = yyj1483 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1483 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1483 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20605,16 +28205,16 @@ func (x *ResourceRequirements) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Limits = nil } else { - yyv1484 := &x.Limits - yyv1484.CodecDecodeSelf(d) + yyv7 := &x.Limits + yyv7.CodecDecodeSelf(d) } - yyj1483++ - if yyhl1483 { - yyb1483 = yyj1483 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1483 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1483 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20622,21 +28222,21 @@ func (x *ResourceRequirements) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Requests = nil } else { - yyv1485 := &x.Requests - yyv1485.CodecDecodeSelf(d) + yyv8 := &x.Requests + yyv8.CodecDecodeSelf(d) } for { - yyj1483++ - if yyhl1483 { - yyb1483 = yyj1483 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1483 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1483 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1483-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20648,50 +28248,51 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1486 := z.EncBinary() - _ = yym1486 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1487 := !z.EncBinary() - yy2arr1487 := z.EncBasicHandle().StructToArray - var yyq1487 [18]bool - _, _, _ = yysep1487, yyq1487, yy2arr1487 - const yyr1487 bool = false - yyq1487[1] = x.Image != "" - yyq1487[2] = len(x.Command) != 0 - yyq1487[3] = len(x.Args) != 0 - yyq1487[4] = x.WorkingDir != "" - yyq1487[5] = len(x.Ports) != 0 - yyq1487[6] = len(x.Env) != 0 - yyq1487[7] = true - yyq1487[8] = len(x.VolumeMounts) != 0 - yyq1487[9] = x.LivenessProbe != nil - yyq1487[10] = x.ReadinessProbe != nil - yyq1487[11] = x.Lifecycle != nil - yyq1487[12] = x.TerminationMessagePath != "" - yyq1487[13] = x.ImagePullPolicy != "" - yyq1487[14] = x.SecurityContext != nil - yyq1487[15] = x.Stdin != false - yyq1487[16] = x.StdinOnce != false - yyq1487[17] = x.TTY != false - var yynn1487 int - if yyr1487 || yy2arr1487 { - r.EncodeArrayStart(18) - } else { - yynn1487 = 1 - for _, b := range yyq1487 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [20]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = len(x.Command) != 0 + yyq2[3] = len(x.Args) != 0 + yyq2[4] = x.WorkingDir != "" + yyq2[5] = len(x.Ports) != 0 + yyq2[6] = len(x.EnvFrom) != 0 + yyq2[7] = len(x.Env) != 0 + yyq2[8] = true + yyq2[9] = len(x.VolumeMounts) != 0 + yyq2[10] = x.LivenessProbe != nil + yyq2[11] = x.ReadinessProbe != nil + yyq2[12] = x.Lifecycle != nil + yyq2[13] = x.TerminationMessagePath != "" + yyq2[14] = x.TerminationMessagePolicy != "" + yyq2[15] = x.ImagePullPolicy != "" + yyq2[16] = x.SecurityContext != nil + yyq2[17] = x.Stdin != false + yyq2[18] = x.StdinOnce != false + yyq2[19] = x.TTY != false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(20) + } else { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1487++ + yynn2++ } } - r.EncodeMapStart(yynn1487) - yynn1487 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1489 := z.EncBinary() - _ = yym1489 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -20700,46 +28301,40 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1490 := z.EncBinary() - _ = yym1490 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[1] { - yym1492 := z.EncBinary() - _ = yym1492 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } + yym7 := z.EncBinary() + _ = yym7 + if false { } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeString(codecSelferC_UTF81234, string(x.Image)) } } else { - if yyq1487[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("image")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1493 := z.EncBinary() - _ = yym1493 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Image)) - } + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("image")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Image)) } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[2] { + if yyq2[2] { if x.Command == nil { r.EncodeNil() } else { - yym1495 := z.EncBinary() - _ = yym1495 + yym10 := z.EncBinary() + _ = yym10 if false { } else { z.F.EncSliceStringV(x.Command, false, e) @@ -20749,15 +28344,15 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("command")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Command == nil { r.EncodeNil() } else { - yym1496 := z.EncBinary() - _ = yym1496 + yym11 := z.EncBinary() + _ = yym11 if false { } else { z.F.EncSliceStringV(x.Command, false, e) @@ -20765,14 +28360,14 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[3] { + if yyq2[3] { if x.Args == nil { r.EncodeNil() } else { - yym1498 := z.EncBinary() - _ = yym1498 + yym13 := z.EncBinary() + _ = yym13 if false { } else { z.F.EncSliceStringV(x.Args, false, e) @@ -20782,15 +28377,15 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("args")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Args == nil { r.EncodeNil() } else { - yym1499 := z.EncBinary() - _ = yym1499 + yym14 := z.EncBinary() + _ = yym14 if false { } else { z.F.EncSliceStringV(x.Args, false, e) @@ -20798,11 +28393,11 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[4] { - yym1501 := z.EncBinary() - _ = yym1501 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir)) @@ -20811,26 +28406,26 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1487[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("workingDir")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1502 := z.EncBinary() - _ = yym1502 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.WorkingDir)) } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[5] { + if yyq2[5] { if x.Ports == nil { r.EncodeNil() } else { - yym1504 := z.EncBinary() - _ = yym1504 + yym19 := z.EncBinary() + _ = yym19 if false { } else { h.encSliceContainerPort(([]ContainerPort)(x.Ports), e) @@ -20840,15 +28435,15 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ports")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ports == nil { r.EncodeNil() } else { - yym1505 := z.EncBinary() - _ = yym1505 + yym20 := z.EncBinary() + _ = yym20 if false { } else { h.encSliceContainerPort(([]ContainerPort)(x.Ports), e) @@ -20856,14 +28451,47 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + if x.EnvFrom == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encSliceEnvFromSource(([]EnvFromSource)(x.EnvFrom), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("envFrom")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.EnvFrom == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encSliceEnvFromSource(([]EnvFromSource)(x.EnvFrom), e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[6] { + if yyq2[7] { if x.Env == nil { r.EncodeNil() } else { - yym1507 := z.EncBinary() - _ = yym1507 + yym25 := z.EncBinary() + _ = yym25 if false { } else { h.encSliceEnvVar(([]EnvVar)(x.Env), e) @@ -20873,15 +28501,15 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[6] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("env")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Env == nil { r.EncodeNil() } else { - yym1508 := z.EncBinary() - _ = yym1508 + yym26 := z.EncBinary() + _ = yym26 if false { } else { h.encSliceEnvVar(([]EnvVar)(x.Env), e) @@ -20889,31 +28517,31 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[7] { - yy1510 := &x.Resources - yy1510.CodecEncodeSelf(e) + if yyq2[8] { + yy28 := &x.Resources + yy28.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1487[7] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resources")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1511 := &x.Resources - yy1511.CodecEncodeSelf(e) + yy30 := &x.Resources + yy30.CodecEncodeSelf(e) } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[8] { + if yyq2[9] { if x.VolumeMounts == nil { r.EncodeNil() } else { - yym1513 := z.EncBinary() - _ = yym1513 + yym33 := z.EncBinary() + _ = yym33 if false { } else { h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e) @@ -20923,15 +28551,15 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[8] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumeMounts")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.VolumeMounts == nil { r.EncodeNil() } else { - yym1514 := z.EncBinary() - _ = yym1514 + yym34 := z.EncBinary() + _ = yym34 if false { } else { h.encSliceVolumeMount(([]VolumeMount)(x.VolumeMounts), e) @@ -20939,9 +28567,9 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[9] { + if yyq2[10] { if x.LivenessProbe == nil { r.EncodeNil() } else { @@ -20951,7 +28579,7 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[9] { + if yyq2[10] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("livenessProbe")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -20962,9 +28590,9 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[10] { + if yyq2[11] { if x.ReadinessProbe == nil { r.EncodeNil() } else { @@ -20974,7 +28602,7 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[10] { + if yyq2[11] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readinessProbe")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -20985,9 +28613,9 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[11] { + if yyq2[12] { if x.Lifecycle == nil { r.EncodeNil() } else { @@ -20997,7 +28625,7 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[11] { + if yyq2[12] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lifecycle")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -21008,11 +28636,11 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[12] { - yym1519 := z.EncBinary() - _ = yym1519 + if yyq2[13] { + yym45 := z.EncBinary() + _ = yym45 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath)) @@ -21021,36 +28649,51 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1487[12] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("terminationMessagePath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1520 := z.EncBinary() - _ = yym1520 + yym46 := z.EncBinary() + _ = yym46 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.TerminationMessagePath)) } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[14] { + x.TerminationMessagePolicy.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[14] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("terminationMessagePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.TerminationMessagePolicy.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[13] { + if yyq2[15] { x.ImagePullPolicy.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1487[13] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("imagePullPolicy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.ImagePullPolicy.CodecEncodeSelf(e) } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[14] { + if yyq2[16] { if x.SecurityContext == nil { r.EncodeNil() } else { @@ -21060,7 +28703,7 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1487[14] { + if yyq2[16] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("securityContext")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -21071,11 +28714,11 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[15] { - yym1524 := z.EncBinary() - _ = yym1524 + if yyq2[17] { + yym57 := z.EncBinary() + _ = yym57 if false { } else { r.EncodeBool(bool(x.Stdin)) @@ -21084,23 +28727,23 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1487[15] { + if yyq2[17] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stdin")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1525 := z.EncBinary() - _ = yym1525 + yym58 := z.EncBinary() + _ = yym58 if false { } else { r.EncodeBool(bool(x.Stdin)) } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[16] { - yym1527 := z.EncBinary() - _ = yym1527 + if yyq2[18] { + yym60 := z.EncBinary() + _ = yym60 if false { } else { r.EncodeBool(bool(x.StdinOnce)) @@ -21109,23 +28752,23 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1487[16] { + if yyq2[18] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stdinOnce")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1528 := z.EncBinary() - _ = yym1528 + yym61 := z.EncBinary() + _ = yym61 if false { } else { r.EncodeBool(bool(x.StdinOnce)) } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1487[17] { - yym1530 := z.EncBinary() - _ = yym1530 + if yyq2[19] { + yym63 := z.EncBinary() + _ = yym63 if false { } else { r.EncodeBool(bool(x.TTY)) @@ -21134,19 +28777,19 @@ func (x *Container) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1487[17] { + if yyq2[19] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tty")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1531 := z.EncBinary() - _ = yym1531 + yym64 := z.EncBinary() + _ = yym64 if false { } else { r.EncodeBool(bool(x.TTY)) } } } - if yyr1487 || yy2arr1487 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -21159,25 +28802,25 @@ func (x *Container) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1532 := z.DecBinary() - _ = yym1532 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1533 := r.ContainerType() - if yyct1533 == codecSelferValueTypeMap1234 { - yyl1533 := r.ReadMapStart() - if yyl1533 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1533, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1533 == codecSelferValueTypeArray1234 { - yyl1533 := r.ReadArrayStart() - if yyl1533 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1533, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -21189,12 +28832,12 @@ func (x *Container) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1534Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1534Slc - var yyhl1534 bool = l >= 0 - for yyj1534 := 0; ; yyj1534++ { - if yyhl1534 { - if yyj1534 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -21203,93 +28846,123 @@ func (x *Container) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1534Slc = r.DecodeBytes(yys1534Slc, true, true) - yys1534 := string(yys1534Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1534 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "image": if r.TryDecodeAsNil() { x.Image = "" } else { - x.Image = string(r.DecodeString()) + yyv6 := &x.Image + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "command": if r.TryDecodeAsNil() { x.Command = nil } else { - yyv1537 := &x.Command - yym1538 := z.DecBinary() - _ = yym1538 + yyv8 := &x.Command + yym9 := z.DecBinary() + _ = yym9 if false { } else { - z.F.DecSliceStringX(yyv1537, false, d) + z.F.DecSliceStringX(yyv8, false, d) } } case "args": if r.TryDecodeAsNil() { x.Args = nil } else { - yyv1539 := &x.Args - yym1540 := z.DecBinary() - _ = yym1540 + yyv10 := &x.Args + yym11 := z.DecBinary() + _ = yym11 if false { } else { - z.F.DecSliceStringX(yyv1539, false, d) + z.F.DecSliceStringX(yyv10, false, d) } } case "workingDir": if r.TryDecodeAsNil() { x.WorkingDir = "" } else { - x.WorkingDir = string(r.DecodeString()) + yyv12 := &x.WorkingDir + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "ports": if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv1542 := &x.Ports - yym1543 := z.DecBinary() - _ = yym1543 + yyv14 := &x.Ports + yym15 := z.DecBinary() + _ = yym15 if false { } else { - h.decSliceContainerPort((*[]ContainerPort)(yyv1542), d) + h.decSliceContainerPort((*[]ContainerPort)(yyv14), d) + } + } + case "envFrom": + if r.TryDecodeAsNil() { + x.EnvFrom = nil + } else { + yyv16 := &x.EnvFrom + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + h.decSliceEnvFromSource((*[]EnvFromSource)(yyv16), d) } } case "env": if r.TryDecodeAsNil() { x.Env = nil } else { - yyv1544 := &x.Env - yym1545 := z.DecBinary() - _ = yym1545 + yyv18 := &x.Env + yym19 := z.DecBinary() + _ = yym19 if false { } else { - h.decSliceEnvVar((*[]EnvVar)(yyv1544), d) + h.decSliceEnvVar((*[]EnvVar)(yyv18), d) } } case "resources": if r.TryDecodeAsNil() { x.Resources = ResourceRequirements{} } else { - yyv1546 := &x.Resources - yyv1546.CodecDecodeSelf(d) + yyv20 := &x.Resources + yyv20.CodecDecodeSelf(d) } case "volumeMounts": if r.TryDecodeAsNil() { x.VolumeMounts = nil } else { - yyv1547 := &x.VolumeMounts - yym1548 := z.DecBinary() - _ = yym1548 + yyv21 := &x.VolumeMounts + yym22 := z.DecBinary() + _ = yym22 if false { } else { - h.decSliceVolumeMount((*[]VolumeMount)(yyv1547), d) + h.decSliceVolumeMount((*[]VolumeMount)(yyv21), d) } } case "livenessProbe": @@ -21329,13 +29002,27 @@ func (x *Container) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TerminationMessagePath = "" } else { - x.TerminationMessagePath = string(r.DecodeString()) + yyv26 := &x.TerminationMessagePath + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } + } + case "terminationMessagePolicy": + if r.TryDecodeAsNil() { + x.TerminationMessagePolicy = "" + } else { + yyv28 := &x.TerminationMessagePolicy + yyv28.CodecDecodeSelf(d) } case "imagePullPolicy": if r.TryDecodeAsNil() { x.ImagePullPolicy = "" } else { - x.ImagePullPolicy = PullPolicy(r.DecodeString()) + yyv29 := &x.ImagePullPolicy + yyv29.CodecDecodeSelf(d) } case "securityContext": if r.TryDecodeAsNil() { @@ -21352,24 +29039,42 @@ func (x *Container) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Stdin = false } else { - x.Stdin = bool(r.DecodeBool()) + yyv31 := &x.Stdin + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } } case "stdinOnce": if r.TryDecodeAsNil() { x.StdinOnce = false } else { - x.StdinOnce = bool(r.DecodeBool()) + yyv33 := &x.StdinOnce + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*bool)(yyv33)) = r.DecodeBool() + } } case "tty": if r.TryDecodeAsNil() { x.TTY = false } else { - x.TTY = bool(r.DecodeBool()) + yyv35 := &x.TTY + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*bool)(yyv35)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys1534) - } // end switch yys1534 - } // end for yyj1534 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -21377,16 +29082,16 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1558 int - var yyb1558 bool - var yyhl1558 bool = l >= 0 - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + var yyj37 int + var yyb37 bool + var yyhl37 bool = l >= 0 + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21394,15 +29099,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv38 := &x.Name + yym39 := z.DecBinary() + _ = yym39 + if false { + } else { + *((*string)(yyv38)) = r.DecodeString() + } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21410,15 +29121,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Image = "" } else { - x.Image = string(r.DecodeString()) + yyv40 := &x.Image + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*string)(yyv40)) = r.DecodeString() + } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21426,21 +29143,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Command = nil } else { - yyv1561 := &x.Command - yym1562 := z.DecBinary() - _ = yym1562 + yyv42 := &x.Command + yym43 := z.DecBinary() + _ = yym43 if false { } else { - z.F.DecSliceStringX(yyv1561, false, d) + z.F.DecSliceStringX(yyv42, false, d) } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21448,21 +29165,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Args = nil } else { - yyv1563 := &x.Args - yym1564 := z.DecBinary() - _ = yym1564 + yyv44 := &x.Args + yym45 := z.DecBinary() + _ = yym45 if false { } else { - z.F.DecSliceStringX(yyv1563, false, d) + z.F.DecSliceStringX(yyv44, false, d) } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21470,15 +29187,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.WorkingDir = "" } else { - x.WorkingDir = string(r.DecodeString()) + yyv46 := &x.WorkingDir + yym47 := z.DecBinary() + _ = yym47 + if false { + } else { + *((*string)(yyv46)) = r.DecodeString() + } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21486,21 +29209,43 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv1566 := &x.Ports - yym1567 := z.DecBinary() - _ = yym1567 + yyv48 := &x.Ports + yym49 := z.DecBinary() + _ = yym49 if false { } else { - h.decSliceContainerPort((*[]ContainerPort)(yyv1566), d) + h.decSliceContainerPort((*[]ContainerPort)(yyv48), d) } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.EnvFrom = nil + } else { + yyv50 := &x.EnvFrom + yym51 := z.DecBinary() + _ = yym51 + if false { + } else { + h.decSliceEnvFromSource((*[]EnvFromSource)(yyv50), d) + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21508,21 +29253,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Env = nil } else { - yyv1568 := &x.Env - yym1569 := z.DecBinary() - _ = yym1569 + yyv52 := &x.Env + yym53 := z.DecBinary() + _ = yym53 if false { } else { - h.decSliceEnvVar((*[]EnvVar)(yyv1568), d) + h.decSliceEnvVar((*[]EnvVar)(yyv52), d) } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21530,16 +29275,16 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Resources = ResourceRequirements{} } else { - yyv1570 := &x.Resources - yyv1570.CodecDecodeSelf(d) + yyv54 := &x.Resources + yyv54.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21547,21 +29292,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.VolumeMounts = nil } else { - yyv1571 := &x.VolumeMounts - yym1572 := z.DecBinary() - _ = yym1572 + yyv55 := &x.VolumeMounts + yym56 := z.DecBinary() + _ = yym56 if false { } else { - h.decSliceVolumeMount((*[]VolumeMount)(yyv1571), d) + h.decSliceVolumeMount((*[]VolumeMount)(yyv55), d) } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21576,13 +29321,13 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.LivenessProbe.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21597,13 +29342,13 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.ReadinessProbe.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21618,13 +29363,13 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Lifecycle.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21632,15 +29377,38 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TerminationMessagePath = "" } else { - x.TerminationMessagePath = string(r.DecodeString()) + yyv60 := &x.TerminationMessagePath + yym61 := z.DecBinary() + _ = yym61 + if false { + } else { + *((*string)(yyv60)) = r.DecodeString() + } + } + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l + } else { + yyb37 = r.CheckBreak() + } + if yyb37 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TerminationMessagePolicy = "" + } else { + yyv62 := &x.TerminationMessagePolicy + yyv62.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21648,15 +29416,16 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ImagePullPolicy = "" } else { - x.ImagePullPolicy = PullPolicy(r.DecodeString()) + yyv63 := &x.ImagePullPolicy + yyv63.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21671,13 +29440,13 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.SecurityContext.CodecDecodeSelf(d) } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21685,15 +29454,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Stdin = false } else { - x.Stdin = bool(r.DecodeBool()) + yyv65 := &x.Stdin + yym66 := z.DecBinary() + _ = yym66 + if false { + } else { + *((*bool)(yyv65)) = r.DecodeBool() + } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21701,15 +29476,21 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.StdinOnce = false } else { - x.StdinOnce = bool(r.DecodeBool()) + yyv67 := &x.StdinOnce + yym68 := z.DecBinary() + _ = yym68 + if false { + } else { + *((*bool)(yyv67)) = r.DecodeBool() + } } - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21717,20 +29498,26 @@ func (x *Container) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TTY = false } else { - x.TTY = bool(r.DecodeBool()) + yyv69 := &x.TTY + yym70 := z.DecBinary() + _ = yym70 + if false { + } else { + *((*bool)(yyv69)) = r.DecodeBool() + } } for { - yyj1558++ - if yyhl1558 { - yyb1558 = yyj1558 > l + yyj37++ + if yyhl37 { + yyb37 = yyj37 > l } else { - yyb1558 = r.CheckBreak() + yyb37 = r.CheckBreak() } - if yyb1558 { + if yyb37 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1558-1, "") + z.DecStructFieldNotFound(yyj37-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21742,35 +29529,35 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1582 := z.EncBinary() - _ = yym1582 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1583 := !z.EncBinary() - yy2arr1583 := z.EncBasicHandle().StructToArray - var yyq1583 [3]bool - _, _, _ = yysep1583, yyq1583, yy2arr1583 - const yyr1583 bool = false - yyq1583[0] = x.Exec != nil - yyq1583[1] = x.HTTPGet != nil - yyq1583[2] = x.TCPSocket != nil - var yynn1583 int - if yyr1583 || yy2arr1583 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Exec != nil + yyq2[1] = x.HTTPGet != nil + yyq2[2] = x.TCPSocket != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1583 = 0 - for _, b := range yyq1583 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1583++ + yynn2++ } } - r.EncodeMapStart(yynn1583) - yynn1583 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1583 || yy2arr1583 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1583[0] { + if yyq2[0] { if x.Exec == nil { r.EncodeNil() } else { @@ -21780,7 +29567,7 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1583[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("exec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -21791,9 +29578,9 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1583 || yy2arr1583 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1583[1] { + if yyq2[1] { if x.HTTPGet == nil { r.EncodeNil() } else { @@ -21803,7 +29590,7 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1583[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("httpGet")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -21814,9 +29601,9 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1583 || yy2arr1583 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1583[2] { + if yyq2[2] { if x.TCPSocket == nil { r.EncodeNil() } else { @@ -21826,7 +29613,7 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1583[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tcpSocket")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -21837,7 +29624,7 @@ func (x *Handler) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1583 || yy2arr1583 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -21850,25 +29637,25 @@ func (x *Handler) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1587 := z.DecBinary() - _ = yym1587 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1588 := r.ContainerType() - if yyct1588 == codecSelferValueTypeMap1234 { - yyl1588 := r.ReadMapStart() - if yyl1588 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1588, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1588 == codecSelferValueTypeArray1234 { - yyl1588 := r.ReadArrayStart() - if yyl1588 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1588, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -21880,12 +29667,12 @@ func (x *Handler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1589Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1589Slc - var yyhl1589 bool = l >= 0 - for yyj1589 := 0; ; yyj1589++ { - if yyhl1589 { - if yyj1589 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -21894,10 +29681,10 @@ func (x *Handler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1589Slc = r.DecodeBytes(yys1589Slc, true, true) - yys1589 := string(yys1589Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1589 { + switch yys3 { case "exec": if r.TryDecodeAsNil() { if x.Exec != nil { @@ -21932,9 +29719,9 @@ func (x *Handler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.TCPSocket.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1589) - } // end switch yys1589 - } // end for yyj1589 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -21942,16 +29729,16 @@ func (x *Handler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1593 int - var yyb1593 bool - var yyhl1593 bool = l >= 0 - yyj1593++ - if yyhl1593 { - yyb1593 = yyj1593 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1593 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1593 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21966,13 +29753,13 @@ func (x *Handler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Exec.CodecDecodeSelf(d) } - yyj1593++ - if yyhl1593 { - yyb1593 = yyj1593 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1593 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1593 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21987,13 +29774,13 @@ func (x *Handler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.HTTPGet.CodecDecodeSelf(d) } - yyj1593++ - if yyhl1593 { - yyb1593 = yyj1593 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1593 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1593 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -22009,17 +29796,17 @@ func (x *Handler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.TCPSocket.CodecDecodeSelf(d) } for { - yyj1593++ - if yyhl1593 { - yyb1593 = yyj1593 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1593 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1593 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1593-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22031,34 +29818,34 @@ func (x *Lifecycle) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1597 := z.EncBinary() - _ = yym1597 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1598 := !z.EncBinary() - yy2arr1598 := z.EncBasicHandle().StructToArray - var yyq1598 [2]bool - _, _, _ = yysep1598, yyq1598, yy2arr1598 - const yyr1598 bool = false - yyq1598[0] = x.PostStart != nil - yyq1598[1] = x.PreStop != nil - var yynn1598 int - if yyr1598 || yy2arr1598 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PostStart != nil + yyq2[1] = x.PreStop != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1598 = 0 - for _, b := range yyq1598 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1598++ + yynn2++ } } - r.EncodeMapStart(yynn1598) - yynn1598 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1598 || yy2arr1598 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1598[0] { + if yyq2[0] { if x.PostStart == nil { r.EncodeNil() } else { @@ -22068,7 +29855,7 @@ func (x *Lifecycle) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1598[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("postStart")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -22079,9 +29866,9 @@ func (x *Lifecycle) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1598 || yy2arr1598 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1598[1] { + if yyq2[1] { if x.PreStop == nil { r.EncodeNil() } else { @@ -22091,7 +29878,7 @@ func (x *Lifecycle) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1598[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preStop")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -22102,7 +29889,7 @@ func (x *Lifecycle) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1598 || yy2arr1598 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -22115,25 +29902,25 @@ func (x *Lifecycle) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1601 := z.DecBinary() - _ = yym1601 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1602 := r.ContainerType() - if yyct1602 == codecSelferValueTypeMap1234 { - yyl1602 := r.ReadMapStart() - if yyl1602 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1602, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1602 == codecSelferValueTypeArray1234 { - yyl1602 := r.ReadArrayStart() - if yyl1602 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1602, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -22145,12 +29932,12 @@ func (x *Lifecycle) 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 { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -22159,10 +29946,10 @@ func (x *Lifecycle) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1603Slc = r.DecodeBytes(yys1603Slc, true, true) - yys1603 := string(yys1603Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1603 { + switch yys3 { case "postStart": if r.TryDecodeAsNil() { if x.PostStart != nil { @@ -22186,9 +29973,9 @@ func (x *Lifecycle) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.PreStop.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1603) - } // end switch yys1603 - } // end for yyj1603 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -22196,16 +29983,16 @@ func (x *Lifecycle) 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 + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1606 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1606 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -22220,13 +30007,13 @@ func (x *Lifecycle) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.PostStart.CodecDecodeSelf(d) } - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1606 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1606 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -22242,17 +30029,17 @@ func (x *Lifecycle) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.PreStop.CodecDecodeSelf(d) } for { - yyj1606++ - if yyhl1606 { - yyb1606 = yyj1606 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1606 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1606 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1606-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22261,8 +30048,8 @@ func (x ConditionStatus) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1609 := z.EncBinary() - _ = yym1609 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -22274,8 +30061,8 @@ func (x *ConditionStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1610 := z.DecBinary() - _ = yym1610 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -22290,36 +30077,36 @@ func (x *ContainerStateWaiting) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1611 := z.EncBinary() - _ = yym1611 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1612 := !z.EncBinary() - yy2arr1612 := z.EncBasicHandle().StructToArray - var yyq1612 [2]bool - _, _, _ = yysep1612, yyq1612, yy2arr1612 - const yyr1612 bool = false - yyq1612[0] = x.Reason != "" - yyq1612[1] = x.Message != "" - var yynn1612 int - if yyr1612 || yy2arr1612 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Reason != "" + yyq2[1] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1612 = 0 - for _, b := range yyq1612 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1612++ + yynn2++ } } - r.EncodeMapStart(yynn1612) - yynn1612 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1612 || yy2arr1612 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1612[0] { - yym1614 := z.EncBinary() - _ = yym1614 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -22328,23 +30115,23 @@ func (x *ContainerStateWaiting) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1612[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1615 := z.EncBinary() - _ = yym1615 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr1612 || yy2arr1612 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1612[1] { - yym1617 := z.EncBinary() - _ = yym1617 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -22353,19 +30140,19 @@ func (x *ContainerStateWaiting) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1612[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1618 := z.EncBinary() - _ = yym1618 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr1612 || yy2arr1612 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -22378,25 +30165,25 @@ func (x *ContainerStateWaiting) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1619 := z.DecBinary() - _ = yym1619 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1620 := r.ContainerType() - if yyct1620 == codecSelferValueTypeMap1234 { - yyl1620 := r.ReadMapStart() - if yyl1620 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1620, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1620 == codecSelferValueTypeArray1234 { - yyl1620 := r.ReadArrayStart() - if yyl1620 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1620, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -22408,12 +30195,12 @@ func (x *ContainerStateWaiting) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1621Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1621Slc - var yyhl1621 bool = l >= 0 - for yyj1621 := 0; ; yyj1621++ { - if yyhl1621 { - if yyj1621 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -22422,26 +30209,38 @@ func (x *ContainerStateWaiting) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1621Slc = r.DecodeBytes(yys1621Slc, true, true) - yys1621 := string(yys1621Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1621 { + switch yys3 { case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv4 := &x.Reason + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv6 := &x.Message + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1621) - } // end switch yys1621 - } // end for yyj1621 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -22449,16 +30248,16 @@ func (x *ContainerStateWaiting) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1624 int - var yyb1624 bool - var yyhl1624 bool = l >= 0 - yyj1624++ - if yyhl1624 { - yyb1624 = yyj1624 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1624 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1624 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -22466,15 +30265,21 @@ func (x *ContainerStateWaiting) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv9 := &x.Reason + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1624++ - if yyhl1624 { - yyb1624 = yyj1624 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1624 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1624 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -22482,20 +30287,26 @@ func (x *ContainerStateWaiting) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv11 := &x.Message + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj1624++ - if yyhl1624 { - yyb1624 = yyj1624 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1624 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1624 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1624-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22507,68 +30318,68 @@ func (x *ContainerStateRunning) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1627 := z.EncBinary() - _ = yym1627 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1628 := !z.EncBinary() - yy2arr1628 := z.EncBasicHandle().StructToArray - var yyq1628 [1]bool - _, _, _ = yysep1628, yyq1628, yy2arr1628 - const yyr1628 bool = false - yyq1628[0] = true - var yynn1628 int - if yyr1628 || yy2arr1628 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1628 = 0 - for _, b := range yyq1628 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1628++ + yynn2++ } } - r.EncodeMapStart(yynn1628) - yynn1628 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1628 || yy2arr1628 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1628[0] { - yy1630 := &x.StartedAt - yym1631 := z.EncBinary() - _ = yym1631 + if yyq2[0] { + yy4 := &x.StartedAt + yym5 := z.EncBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.EncExt(yy1630) { - } else if yym1631 { - z.EncBinaryMarshal(yy1630) - } else if !yym1631 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1630) + } else if z.HasExtensions() && z.EncExt(yy4) { + } else if yym5 { + z.EncBinaryMarshal(yy4) + } else if !yym5 && z.IsJSONHandle() { + z.EncJSONMarshal(yy4) } else { - z.EncFallback(yy1630) + z.EncFallback(yy4) } } else { r.EncodeNil() } } else { - if yyq1628[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("startedAt")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1632 := &x.StartedAt - yym1633 := z.EncBinary() - _ = yym1633 + yy6 := &x.StartedAt + yym7 := z.EncBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.EncExt(yy1632) { - } else if yym1633 { - z.EncBinaryMarshal(yy1632) - } else if !yym1633 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1632) + } else if z.HasExtensions() && z.EncExt(yy6) { + } else if yym7 { + z.EncBinaryMarshal(yy6) + } else if !yym7 && z.IsJSONHandle() { + z.EncJSONMarshal(yy6) } else { - z.EncFallback(yy1632) + z.EncFallback(yy6) } } } - if yyr1628 || yy2arr1628 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -22581,25 +30392,25 @@ func (x *ContainerStateRunning) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1634 := z.DecBinary() - _ = yym1634 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1635 := r.ContainerType() - if yyct1635 == codecSelferValueTypeMap1234 { - yyl1635 := r.ReadMapStart() - if yyl1635 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1635, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1635 == codecSelferValueTypeArray1234 { - yyl1635 := r.ReadArrayStart() - if yyl1635 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1635, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -22611,12 +30422,12 @@ func (x *ContainerStateRunning) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1636Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1636Slc - var yyhl1636 bool = l >= 0 - for yyj1636 := 0; ; yyj1636++ { - if yyhl1636 { - if yyj1636 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -22625,31 +30436,31 @@ func (x *ContainerStateRunning) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1636Slc = r.DecodeBytes(yys1636Slc, true, true) - yys1636 := string(yys1636Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1636 { + switch yys3 { case "startedAt": if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} + x.StartedAt = pkg2_v1.Time{} } else { - yyv1637 := &x.StartedAt - yym1638 := z.DecBinary() - _ = yym1638 + yyv4 := &x.StartedAt + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv1637) { - } else if yym1638 { - z.DecBinaryUnmarshal(yyv1637) - } else if !yym1638 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1637) + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else if yym5 { + z.DecBinaryUnmarshal(yyv4) + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv4) } else { - z.DecFallback(yyv1637, false) + z.DecFallback(yyv4, false) } } default: - z.DecStructFieldNotFound(-1, yys1636) - } // end switch yys1636 - } // end for yyj1636 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -22657,48 +30468,48 @@ func (x *ContainerStateRunning) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1639 int - var yyb1639 bool - var yyhl1639 bool = l >= 0 - yyj1639++ - if yyhl1639 { - yyb1639 = yyj1639 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1639 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1639 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} + x.StartedAt = pkg2_v1.Time{} } else { - yyv1640 := &x.StartedAt - yym1641 := z.DecBinary() - _ = yym1641 + yyv7 := &x.StartedAt + yym8 := z.DecBinary() + _ = yym8 if false { - } else if z.HasExtensions() && z.DecExt(yyv1640) { - } else if yym1641 { - z.DecBinaryUnmarshal(yyv1640) - } else if !yym1641 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1640) + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if yym8 { + z.DecBinaryUnmarshal(yyv7) + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) } else { - z.DecFallback(yyv1640, false) + z.DecFallback(yyv7, false) } } for { - yyj1639++ - if yyhl1639 { - yyb1639 = yyj1639 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1639 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1639 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1639-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22710,39 +30521,39 @@ func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1642 := z.EncBinary() - _ = yym1642 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1643 := !z.EncBinary() - yy2arr1643 := z.EncBasicHandle().StructToArray - var yyq1643 [7]bool - _, _, _ = yysep1643, yyq1643, yy2arr1643 - const yyr1643 bool = false - yyq1643[1] = x.Signal != 0 - yyq1643[2] = x.Reason != "" - yyq1643[3] = x.Message != "" - yyq1643[4] = true - yyq1643[5] = true - yyq1643[6] = x.ContainerID != "" - var yynn1643 int - if yyr1643 || yy2arr1643 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Signal != 0 + yyq2[2] = x.Reason != "" + yyq2[3] = x.Message != "" + yyq2[4] = true + yyq2[5] = true + yyq2[6] = x.ContainerID != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(7) } else { - yynn1643 = 1 - for _, b := range yyq1643 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1643++ + yynn2++ } } - r.EncodeMapStart(yynn1643) - yynn1643 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1645 := z.EncBinary() - _ = yym1645 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.ExitCode)) @@ -22751,18 +30562,18 @@ func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("exitCode")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1646 := z.EncBinary() - _ = yym1646 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.ExitCode)) } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1643[1] { - yym1648 := z.EncBinary() - _ = yym1648 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.Signal)) @@ -22771,23 +30582,23 @@ func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1643[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("signal")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1649 := z.EncBinary() - _ = yym1649 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.Signal)) } } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1643[2] { - yym1651 := z.EncBinary() - _ = yym1651 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -22796,23 +30607,23 @@ func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1643[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1652 := z.EncBinary() - _ = yym1652 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1643[3] { - yym1654 := z.EncBinary() - _ = yym1654 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -22821,97 +30632,97 @@ func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1643[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1655 := z.EncBinary() - _ = yym1655 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1643[4] { - yy1657 := &x.StartedAt - yym1658 := z.EncBinary() - _ = yym1658 + if yyq2[4] { + yy16 := &x.StartedAt + yym17 := z.EncBinary() + _ = yym17 if false { - } else if z.HasExtensions() && z.EncExt(yy1657) { - } else if yym1658 { - z.EncBinaryMarshal(yy1657) - } else if !yym1658 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1657) + } else if z.HasExtensions() && z.EncExt(yy16) { + } else if yym17 { + z.EncBinaryMarshal(yy16) + } else if !yym17 && z.IsJSONHandle() { + z.EncJSONMarshal(yy16) } else { - z.EncFallback(yy1657) + z.EncFallback(yy16) } } else { r.EncodeNil() } } else { - if yyq1643[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("startedAt")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1659 := &x.StartedAt - yym1660 := z.EncBinary() - _ = yym1660 + yy18 := &x.StartedAt + yym19 := z.EncBinary() + _ = yym19 if false { - } else if z.HasExtensions() && z.EncExt(yy1659) { - } else if yym1660 { - z.EncBinaryMarshal(yy1659) - } else if !yym1660 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1659) + } else if z.HasExtensions() && z.EncExt(yy18) { + } else if yym19 { + z.EncBinaryMarshal(yy18) + } else if !yym19 && z.IsJSONHandle() { + z.EncJSONMarshal(yy18) } else { - z.EncFallback(yy1659) + z.EncFallback(yy18) } } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1643[5] { - yy1662 := &x.FinishedAt - yym1663 := z.EncBinary() - _ = yym1663 + if yyq2[5] { + yy21 := &x.FinishedAt + yym22 := z.EncBinary() + _ = yym22 if false { - } else if z.HasExtensions() && z.EncExt(yy1662) { - } else if yym1663 { - z.EncBinaryMarshal(yy1662) - } else if !yym1663 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1662) + } else if z.HasExtensions() && z.EncExt(yy21) { + } else if yym22 { + z.EncBinaryMarshal(yy21) + } else if !yym22 && z.IsJSONHandle() { + z.EncJSONMarshal(yy21) } else { - z.EncFallback(yy1662) + z.EncFallback(yy21) } } else { r.EncodeNil() } } else { - if yyq1643[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("finishedAt")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1664 := &x.FinishedAt - yym1665 := z.EncBinary() - _ = yym1665 + yy23 := &x.FinishedAt + yym24 := z.EncBinary() + _ = yym24 if false { - } else if z.HasExtensions() && z.EncExt(yy1664) { - } else if yym1665 { - z.EncBinaryMarshal(yy1664) - } else if !yym1665 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1664) + } else if z.HasExtensions() && z.EncExt(yy23) { + } else if yym24 { + z.EncBinaryMarshal(yy23) + } else if !yym24 && z.IsJSONHandle() { + z.EncJSONMarshal(yy23) } else { - z.EncFallback(yy1664) + z.EncFallback(yy23) } } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1643[6] { - yym1667 := z.EncBinary() - _ = yym1667 + if yyq2[6] { + yym26 := z.EncBinary() + _ = yym26 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) @@ -22920,19 +30731,19 @@ func (x *ContainerStateTerminated) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1643[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("containerID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1668 := z.EncBinary() - _ = yym1668 + yym27 := z.EncBinary() + _ = yym27 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) } } } - if yyr1643 || yy2arr1643 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -22945,25 +30756,25 @@ func (x *ContainerStateTerminated) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1669 := z.DecBinary() - _ = yym1669 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1670 := r.ContainerType() - if yyct1670 == codecSelferValueTypeMap1234 { - yyl1670 := r.ReadMapStart() - if yyl1670 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1670, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1670 == codecSelferValueTypeArray1234 { - yyl1670 := r.ReadArrayStart() - if yyl1670 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1670, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -22975,12 +30786,12 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromMap(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1671Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1671Slc - var yyhl1671 bool = l >= 0 - for yyj1671 := 0; ; yyj1671++ { - if yyhl1671 { - if yyj1671 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -22989,78 +30800,108 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromMap(l int, d *codec1978.De } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1671Slc = r.DecodeBytes(yys1671Slc, true, true) - yys1671 := string(yys1671Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1671 { + switch yys3 { case "exitCode": if r.TryDecodeAsNil() { x.ExitCode = 0 } else { - x.ExitCode = int32(r.DecodeInt(32)) + yyv4 := &x.ExitCode + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "signal": if r.TryDecodeAsNil() { x.Signal = 0 } else { - x.Signal = int32(r.DecodeInt(32)) + yyv6 := &x.Signal + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv8 := &x.Reason + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv10 := &x.Message + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "startedAt": if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} + x.StartedAt = pkg2_v1.Time{} } else { - yyv1676 := &x.StartedAt - yym1677 := z.DecBinary() - _ = yym1677 + yyv12 := &x.StartedAt + yym13 := z.DecBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.DecExt(yyv1676) { - } else if yym1677 { - z.DecBinaryUnmarshal(yyv1676) - } else if !yym1677 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1676) + } else if z.HasExtensions() && z.DecExt(yyv12) { + } else if yym13 { + z.DecBinaryUnmarshal(yyv12) + } else if !yym13 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv12) } else { - z.DecFallback(yyv1676, false) + z.DecFallback(yyv12, false) } } case "finishedAt": if r.TryDecodeAsNil() { - x.FinishedAt = pkg2_unversioned.Time{} + x.FinishedAt = pkg2_v1.Time{} } else { - yyv1678 := &x.FinishedAt - yym1679 := z.DecBinary() - _ = yym1679 + yyv14 := &x.FinishedAt + yym15 := z.DecBinary() + _ = yym15 if false { - } else if z.HasExtensions() && z.DecExt(yyv1678) { - } else if yym1679 { - z.DecBinaryUnmarshal(yyv1678) - } else if !yym1679 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1678) + } else if z.HasExtensions() && z.DecExt(yyv14) { + } else if yym15 { + z.DecBinaryUnmarshal(yyv14) + } else if !yym15 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv14) } else { - z.DecFallback(yyv1678, false) + z.DecFallback(yyv14, false) } } case "containerID": if r.TryDecodeAsNil() { x.ContainerID = "" } else { - x.ContainerID = string(r.DecodeString()) + yyv16 := &x.ContainerID + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1671) - } // end switch yys1671 - } // end for yyj1671 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -23068,16 +30909,16 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978. var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1681 int - var yyb1681 bool - var yyhl1681 bool = l >= 0 - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23085,15 +30926,21 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.ExitCode = 0 } else { - x.ExitCode = int32(r.DecodeInt(32)) + yyv19 := &x.ExitCode + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int32)(yyv19)) = int32(r.DecodeInt(32)) + } } - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23101,15 +30948,21 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Signal = 0 } else { - x.Signal = int32(r.DecodeInt(32)) + yyv21 := &x.Signal + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23117,15 +30970,21 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv23 := &x.Reason + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23133,69 +30992,75 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv25 := &x.Message + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.StartedAt = pkg2_unversioned.Time{} + x.StartedAt = pkg2_v1.Time{} } else { - yyv1686 := &x.StartedAt - yym1687 := z.DecBinary() - _ = yym1687 + yyv27 := &x.StartedAt + yym28 := z.DecBinary() + _ = yym28 if false { - } else if z.HasExtensions() && z.DecExt(yyv1686) { - } else if yym1687 { - z.DecBinaryUnmarshal(yyv1686) - } else if !yym1687 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1686) + } else if z.HasExtensions() && z.DecExt(yyv27) { + } else if yym28 { + z.DecBinaryUnmarshal(yyv27) + } else if !yym28 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv27) } else { - z.DecFallback(yyv1686, false) + z.DecFallback(yyv27, false) } } - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.FinishedAt = pkg2_unversioned.Time{} + x.FinishedAt = pkg2_v1.Time{} } else { - yyv1688 := &x.FinishedAt - yym1689 := z.DecBinary() - _ = yym1689 + yyv29 := &x.FinishedAt + yym30 := z.DecBinary() + _ = yym30 if false { - } else if z.HasExtensions() && z.DecExt(yyv1688) { - } else if yym1689 { - z.DecBinaryUnmarshal(yyv1688) - } else if !yym1689 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1688) + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else if yym30 { + z.DecBinaryUnmarshal(yyv29) + } else if !yym30 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv29) } else { - z.DecFallback(yyv1688, false) + z.DecFallback(yyv29, false) } } - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23203,20 +31068,26 @@ func (x *ContainerStateTerminated) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.ContainerID = "" } else { - x.ContainerID = string(r.DecodeString()) + yyv31 := &x.ContainerID + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } } for { - yyj1681++ - if yyhl1681 { - yyb1681 = yyj1681 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1681 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1681 { + if yyb18 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1681-1, "") + z.DecStructFieldNotFound(yyj18-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23228,35 +31099,35 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1691 := z.EncBinary() - _ = yym1691 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1692 := !z.EncBinary() - yy2arr1692 := z.EncBasicHandle().StructToArray - var yyq1692 [3]bool - _, _, _ = yysep1692, yyq1692, yy2arr1692 - const yyr1692 bool = false - yyq1692[0] = x.Waiting != nil - yyq1692[1] = x.Running != nil - yyq1692[2] = x.Terminated != nil - var yynn1692 int - if yyr1692 || yy2arr1692 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Waiting != nil + yyq2[1] = x.Running != nil + yyq2[2] = x.Terminated != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1692 = 0 - for _, b := range yyq1692 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1692++ + yynn2++ } } - r.EncodeMapStart(yynn1692) - yynn1692 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1692 || yy2arr1692 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1692[0] { + if yyq2[0] { if x.Waiting == nil { r.EncodeNil() } else { @@ -23266,7 +31137,7 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1692[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("waiting")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -23277,9 +31148,9 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1692 || yy2arr1692 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1692[1] { + if yyq2[1] { if x.Running == nil { r.EncodeNil() } else { @@ -23289,7 +31160,7 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1692[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("running")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -23300,9 +31171,9 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1692 || yy2arr1692 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1692[2] { + if yyq2[2] { if x.Terminated == nil { r.EncodeNil() } else { @@ -23312,7 +31183,7 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1692[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("terminated")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -23323,7 +31194,7 @@ func (x *ContainerState) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1692 || yy2arr1692 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -23336,25 +31207,25 @@ func (x *ContainerState) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1696 := z.DecBinary() - _ = yym1696 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1697 := r.ContainerType() - if yyct1697 == codecSelferValueTypeMap1234 { - yyl1697 := r.ReadMapStart() - if yyl1697 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1697, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1697 == codecSelferValueTypeArray1234 { - yyl1697 := r.ReadArrayStart() - if yyl1697 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1697, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -23366,12 +31237,12 @@ func (x *ContainerState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1698Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1698Slc - var yyhl1698 bool = l >= 0 - for yyj1698 := 0; ; yyj1698++ { - if yyhl1698 { - if yyj1698 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -23380,10 +31251,10 @@ func (x *ContainerState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1698Slc = r.DecodeBytes(yys1698Slc, true, true) - yys1698 := string(yys1698Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1698 { + switch yys3 { case "waiting": if r.TryDecodeAsNil() { if x.Waiting != nil { @@ -23418,9 +31289,9 @@ func (x *ContainerState) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.Terminated.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1698) - } // end switch yys1698 - } // end for yyj1698 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -23428,16 +31299,16 @@ func (x *ContainerState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1702 int - var yyb1702 bool - var yyhl1702 bool = l >= 0 - yyj1702++ - if yyhl1702 { - yyb1702 = yyj1702 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1702 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1702 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23452,13 +31323,13 @@ func (x *ContainerState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Waiting.CodecDecodeSelf(d) } - yyj1702++ - if yyhl1702 { - yyb1702 = yyj1702 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1702 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1702 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23473,13 +31344,13 @@ func (x *ContainerState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Running.CodecDecodeSelf(d) } - yyj1702++ - if yyhl1702 { - yyb1702 = yyj1702 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1702 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1702 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23495,17 +31366,17 @@ func (x *ContainerState) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.Terminated.CodecDecodeSelf(d) } for { - yyj1702++ - if yyhl1702 { - yyb1702 = yyj1702 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1702 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1702 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1702-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23517,36 +31388,36 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1706 := z.EncBinary() - _ = yym1706 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1707 := !z.EncBinary() - yy2arr1707 := z.EncBasicHandle().StructToArray - var yyq1707 [8]bool - _, _, _ = yysep1707, yyq1707, yy2arr1707 - const yyr1707 bool = false - yyq1707[1] = true - yyq1707[2] = true - yyq1707[7] = x.ContainerID != "" - var yynn1707 int - if yyr1707 || yy2arr1707 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = true + yyq2[2] = true + yyq2[7] = x.ContainerID != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(8) } else { - yynn1707 = 5 - for _, b := range yyq1707 { + yynn2 = 5 + for _, b := range yyq2 { if b { - yynn1707++ + yynn2++ } } - r.EncodeMapStart(yynn1707) - yynn1707 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1709 := z.EncBinary() - _ = yym1709 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -23555,51 +31426,51 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1710 := z.EncBinary() - _ = yym1710 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1707[1] { - yy1712 := &x.State - yy1712.CodecEncodeSelf(e) + if yyq2[1] { + yy7 := &x.State + yy7.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1707[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("state")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1713 := &x.State - yy1713.CodecEncodeSelf(e) + yy9 := &x.State + yy9.CodecEncodeSelf(e) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1707[2] { - yy1715 := &x.LastTerminationState - yy1715.CodecEncodeSelf(e) + if yyq2[2] { + yy12 := &x.LastTerminationState + yy12.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1707[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastState")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1716 := &x.LastTerminationState - yy1716.CodecEncodeSelf(e) + yy14 := &x.LastTerminationState + yy14.CodecEncodeSelf(e) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1718 := z.EncBinary() - _ = yym1718 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeBool(bool(x.Ready)) @@ -23608,17 +31479,17 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ready")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1719 := z.EncBinary() - _ = yym1719 + yym18 := z.EncBinary() + _ = yym18 if false { } else { r.EncodeBool(bool(x.Ready)) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1721 := z.EncBinary() - _ = yym1721 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeInt(int64(x.RestartCount)) @@ -23627,17 +31498,17 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("restartCount")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1722 := z.EncBinary() - _ = yym1722 + yym21 := z.EncBinary() + _ = yym21 if false { } else { r.EncodeInt(int64(x.RestartCount)) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1724 := z.EncBinary() - _ = yym1724 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Image)) @@ -23646,17 +31517,17 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("image")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1725 := z.EncBinary() - _ = yym1725 + yym24 := z.EncBinary() + _ = yym24 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Image)) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1727 := z.EncBinary() - _ = yym1727 + yym26 := z.EncBinary() + _ = yym26 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ImageID)) @@ -23665,18 +31536,18 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("imageID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1728 := z.EncBinary() - _ = yym1728 + yym27 := z.EncBinary() + _ = yym27 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ImageID)) } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1707[7] { - yym1730 := z.EncBinary() - _ = yym1730 + if yyq2[7] { + yym29 := z.EncBinary() + _ = yym29 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) @@ -23685,19 +31556,19 @@ func (x *ContainerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1707[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("containerID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1731 := z.EncBinary() - _ = yym1731 + yym30 := z.EncBinary() + _ = yym30 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ContainerID)) } } } - if yyr1707 || yy2arr1707 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -23710,25 +31581,25 @@ func (x *ContainerStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1732 := z.DecBinary() - _ = yym1732 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1733 := r.ContainerType() - if yyct1733 == codecSelferValueTypeMap1234 { - yyl1733 := r.ReadMapStart() - if yyl1733 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1733, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1733 == codecSelferValueTypeArray1234 { - yyl1733 := r.ReadArrayStart() - if yyl1733 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1733, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -23740,12 +31611,12 @@ func (x *ContainerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1734Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1734Slc - var yyhl1734 bool = l >= 0 - for yyj1734 := 0; ; yyj1734++ { - if yyhl1734 { - if yyj1734 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -23754,64 +31625,100 @@ func (x *ContainerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1734Slc = r.DecodeBytes(yys1734Slc, true, true) - yys1734 := string(yys1734Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1734 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "state": if r.TryDecodeAsNil() { x.State = ContainerState{} } else { - yyv1736 := &x.State - yyv1736.CodecDecodeSelf(d) + yyv6 := &x.State + yyv6.CodecDecodeSelf(d) } case "lastState": if r.TryDecodeAsNil() { x.LastTerminationState = ContainerState{} } else { - yyv1737 := &x.LastTerminationState - yyv1737.CodecDecodeSelf(d) + yyv7 := &x.LastTerminationState + yyv7.CodecDecodeSelf(d) } case "ready": if r.TryDecodeAsNil() { x.Ready = false } else { - x.Ready = bool(r.DecodeBool()) + yyv8 := &x.Ready + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } } case "restartCount": if r.TryDecodeAsNil() { x.RestartCount = 0 } else { - x.RestartCount = int32(r.DecodeInt(32)) + yyv10 := &x.RestartCount + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } } case "image": if r.TryDecodeAsNil() { x.Image = "" } else { - x.Image = string(r.DecodeString()) + yyv12 := &x.Image + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "imageID": if r.TryDecodeAsNil() { x.ImageID = "" } else { - x.ImageID = string(r.DecodeString()) + yyv14 := &x.ImageID + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "containerID": if r.TryDecodeAsNil() { x.ContainerID = "" } else { - x.ContainerID = string(r.DecodeString()) + yyv16 := &x.ContainerID + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1734) - } // end switch yys1734 - } // end for yyj1734 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -23819,16 +31726,16 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1743 int - var yyb1743 bool - var yyhl1743 bool = l >= 0 - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23836,15 +31743,21 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv19 := &x.Name + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23852,16 +31765,16 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.State = ContainerState{} } else { - yyv1745 := &x.State - yyv1745.CodecDecodeSelf(d) + yyv21 := &x.State + yyv21.CodecDecodeSelf(d) } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23869,16 +31782,16 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.LastTerminationState = ContainerState{} } else { - yyv1746 := &x.LastTerminationState - yyv1746.CodecDecodeSelf(d) + yyv22 := &x.LastTerminationState + yyv22.CodecDecodeSelf(d) } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23886,15 +31799,21 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Ready = false } else { - x.Ready = bool(r.DecodeBool()) + yyv23 := &x.Ready + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23902,15 +31821,21 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.RestartCount = 0 } else { - x.RestartCount = int32(r.DecodeInt(32)) + yyv25 := &x.RestartCount + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23918,15 +31843,21 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Image = "" } else { - x.Image = string(r.DecodeString()) + yyv27 := &x.Image + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23934,15 +31865,21 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ImageID = "" } else { - x.ImageID = string(r.DecodeString()) + yyv29 := &x.ImageID + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } } - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -23950,20 +31887,26 @@ func (x *ContainerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ContainerID = "" } else { - x.ContainerID = string(r.DecodeString()) + yyv31 := &x.ContainerID + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } } for { - yyj1743++ - if yyhl1743 { - yyb1743 = yyj1743 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb1743 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb1743 { + if yyb18 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1743-1, "") + z.DecStructFieldNotFound(yyj18-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23972,8 +31915,8 @@ func (x PodPhase) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1752 := z.EncBinary() - _ = yym1752 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -23985,8 +31928,8 @@ func (x *PodPhase) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1753 := z.DecBinary() - _ = yym1753 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -23998,8 +31941,8 @@ func (x PodConditionType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1754 := z.EncBinary() - _ = yym1754 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -24011,8 +31954,8 @@ func (x *PodConditionType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1755 := z.DecBinary() - _ = yym1755 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -24027,34 +31970,34 @@ func (x *PodCondition) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1756 := z.EncBinary() - _ = yym1756 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1757 := !z.EncBinary() - yy2arr1757 := z.EncBasicHandle().StructToArray - var yyq1757 [6]bool - _, _, _ = yysep1757, yyq1757, yy2arr1757 - const yyr1757 bool = false - yyq1757[2] = true - yyq1757[3] = true - yyq1757[4] = x.Reason != "" - yyq1757[5] = x.Message != "" - var yynn1757 int - if yyr1757 || yy2arr1757 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = true + yyq2[4] = x.Reason != "" + yyq2[5] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn1757 = 2 - for _, b := range yyq1757 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1757++ + yynn2++ } } - r.EncodeMapStart(yynn1757) - yynn1757 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -24063,7 +32006,7 @@ func (x *PodCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Status.CodecEncodeSelf(e) } else { @@ -24072,85 +32015,85 @@ func (x *PodCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Status.CodecEncodeSelf(e) } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1757[2] { - yy1761 := &x.LastProbeTime - yym1762 := z.EncBinary() - _ = yym1762 + if yyq2[2] { + yy10 := &x.LastProbeTime + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy1761) { - } else if yym1762 { - z.EncBinaryMarshal(yy1761) - } else if !yym1762 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1761) + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - z.EncFallback(yy1761) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1757[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1763 := &x.LastProbeTime - yym1764 := z.EncBinary() - _ = yym1764 + yy12 := &x.LastProbeTime + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy1763) { - } else if yym1764 { - z.EncBinaryMarshal(yy1763) - } else if !yym1764 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1763) + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - z.EncFallback(yy1763) + z.EncFallback(yy12) } } } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1757[3] { - yy1766 := &x.LastTransitionTime - yym1767 := z.EncBinary() - _ = yym1767 + if yyq2[3] { + yy15 := &x.LastTransitionTime + yym16 := z.EncBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.EncExt(yy1766) { - } else if yym1767 { - z.EncBinaryMarshal(yy1766) - } else if !yym1767 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1766) + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) } else { - z.EncFallback(yy1766) + z.EncFallback(yy15) } } else { r.EncodeNil() } } else { - if yyq1757[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1768 := &x.LastTransitionTime - yym1769 := z.EncBinary() - _ = yym1769 + yy17 := &x.LastTransitionTime + yym18 := z.EncBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.EncExt(yy1768) { - } else if yym1769 { - z.EncBinaryMarshal(yy1768) - } else if !yym1769 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1768) + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if yym18 { + z.EncBinaryMarshal(yy17) + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) } else { - z.EncFallback(yy1768) + z.EncFallback(yy17) } } } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1757[4] { - yym1771 := z.EncBinary() - _ = yym1771 + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -24159,23 +32102,23 @@ func (x *PodCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1757[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1772 := z.EncBinary() - _ = yym1772 + yym21 := z.EncBinary() + _ = yym21 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1757[5] { - yym1774 := z.EncBinary() - _ = yym1774 + if yyq2[5] { + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -24184,19 +32127,19 @@ func (x *PodCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1757[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1775 := z.EncBinary() - _ = yym1775 + yym24 := z.EncBinary() + _ = yym24 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr1757 || yy2arr1757 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -24209,25 +32152,25 @@ func (x *PodCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1776 := z.DecBinary() - _ = yym1776 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1777 := r.ContainerType() - if yyct1777 == codecSelferValueTypeMap1234 { - yyl1777 := r.ReadMapStart() - if yyl1777 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1777, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1777 == codecSelferValueTypeArray1234 { - yyl1777 := r.ReadArrayStart() - if yyl1777 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1777, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -24239,12 +32182,12 @@ func (x *PodCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1778Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1778Slc - var yyhl1778 bool = l >= 0 - for yyj1778 := 0; ; yyj1778++ { - if yyhl1778 { - if yyj1778 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -24253,72 +32196,86 @@ func (x *PodCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1778Slc = r.DecodeBytes(yys1778Slc, true, true) - yys1778 := string(yys1778Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1778 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = PodConditionType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } case "lastProbeTime": if r.TryDecodeAsNil() { - x.LastProbeTime = pkg2_unversioned.Time{} + x.LastProbeTime = pkg2_v1.Time{} } else { - yyv1781 := &x.LastProbeTime - yym1782 := z.DecBinary() - _ = yym1782 + yyv6 := &x.LastProbeTime + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv1781) { - } else if yym1782 { - z.DecBinaryUnmarshal(yyv1781) - } else if !yym1782 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1781) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv1781, false) + z.DecFallback(yyv6, false) } } case "lastTransitionTime": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} + x.LastTransitionTime = pkg2_v1.Time{} } else { - yyv1783 := &x.LastTransitionTime - yym1784 := z.DecBinary() - _ = yym1784 + yyv8 := &x.LastTransitionTime + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv1783) { - } else if yym1784 { - z.DecBinaryUnmarshal(yyv1783) - } else if !yym1784 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1783) + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) } else { - z.DecFallback(yyv1783, false) + z.DecFallback(yyv8, false) } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv10 := &x.Reason + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv12 := &x.Message + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1778) - } // end switch yys1778 - } // end for yyj1778 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -24326,16 +32283,16 @@ func (x *PodCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1787 int - var yyb1787 bool - var yyhl1787 bool = l >= 0 - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -24343,15 +32300,16 @@ func (x *PodCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = PodConditionType(r.DecodeString()) + yyv15 := &x.Type + yyv15.CodecDecodeSelf(d) } - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -24359,69 +32317,70 @@ func (x *PodCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv16 := &x.Status + yyv16.CodecDecodeSelf(d) } - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastProbeTime = pkg2_unversioned.Time{} + x.LastProbeTime = pkg2_v1.Time{} } else { - yyv1790 := &x.LastProbeTime - yym1791 := z.DecBinary() - _ = yym1791 + yyv17 := &x.LastProbeTime + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv1790) { - } else if yym1791 { - z.DecBinaryUnmarshal(yyv1790) - } else if !yym1791 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1790) + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) } else { - z.DecFallback(yyv1790, false) + z.DecFallback(yyv17, false) } } - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} + x.LastTransitionTime = pkg2_v1.Time{} } else { - yyv1792 := &x.LastTransitionTime - yym1793 := z.DecBinary() - _ = yym1793 + yyv19 := &x.LastTransitionTime + yym20 := z.DecBinary() + _ = yym20 if false { - } else if z.HasExtensions() && z.DecExt(yyv1792) { - } else if yym1793 { - z.DecBinaryUnmarshal(yyv1792) - } else if !yym1793 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1792) + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else if yym20 { + z.DecBinaryUnmarshal(yyv19) + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv19) } else { - z.DecFallback(yyv1792, false) + z.DecFallback(yyv19, false) } } - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -24429,15 +32388,21 @@ func (x *PodCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv21 := &x.Reason + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -24445,20 +32410,26 @@ func (x *PodCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv23 := &x.Message + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } for { - yyj1787++ - if yyhl1787 { - yyb1787 = yyj1787 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb1787 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb1787 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1787-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -24467,8 +32438,8 @@ func (x RestartPolicy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1796 := z.EncBinary() - _ = yym1796 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -24480,8 +32451,8 @@ func (x *RestartPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1797 := z.DecBinary() - _ = yym1797 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -24493,8 +32464,8 @@ func (x DNSPolicy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1798 := z.EncBinary() - _ = yym1798 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -24506,8 +32477,8 @@ func (x *DNSPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1799 := z.DecBinary() - _ = yym1799 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -24522,36 +32493,36 @@ func (x *NodeSelector) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1800 := z.EncBinary() - _ = yym1800 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1801 := !z.EncBinary() - yy2arr1801 := z.EncBasicHandle().StructToArray - var yyq1801 [1]bool - _, _, _ = yysep1801, yyq1801, yy2arr1801 - const yyr1801 bool = false - var yynn1801 int - if yyr1801 || yy2arr1801 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1801 = 1 - for _, b := range yyq1801 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1801++ + yynn2++ } } - r.EncodeMapStart(yynn1801) - yynn1801 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1801 || yy2arr1801 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.NodeSelectorTerms == nil { r.EncodeNil() } else { - yym1803 := z.EncBinary() - _ = yym1803 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceNodeSelectorTerm(([]NodeSelectorTerm)(x.NodeSelectorTerms), e) @@ -24564,15 +32535,15 @@ func (x *NodeSelector) CodecEncodeSelf(e *codec1978.Encoder) { if x.NodeSelectorTerms == nil { r.EncodeNil() } else { - yym1804 := z.EncBinary() - _ = yym1804 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceNodeSelectorTerm(([]NodeSelectorTerm)(x.NodeSelectorTerms), e) } } } - if yyr1801 || yy2arr1801 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -24585,25 +32556,25 @@ func (x *NodeSelector) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1805 := z.DecBinary() - _ = yym1805 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1806 := r.ContainerType() - if yyct1806 == codecSelferValueTypeMap1234 { - yyl1806 := r.ReadMapStart() - if yyl1806 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1806, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1806 == codecSelferValueTypeArray1234 { - yyl1806 := r.ReadArrayStart() - if yyl1806 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1806, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -24615,12 +32586,12 @@ func (x *NodeSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1807Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1807Slc - var yyhl1807 bool = l >= 0 - for yyj1807 := 0; ; yyj1807++ { - if yyhl1807 { - if yyj1807 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -24629,26 +32600,26 @@ func (x *NodeSelector) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1807Slc = r.DecodeBytes(yys1807Slc, true, true) - yys1807 := string(yys1807Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1807 { + switch yys3 { case "nodeSelectorTerms": if r.TryDecodeAsNil() { x.NodeSelectorTerms = nil } else { - yyv1808 := &x.NodeSelectorTerms - yym1809 := z.DecBinary() - _ = yym1809 + yyv4 := &x.NodeSelectorTerms + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv1808), d) + h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys1807) - } // end switch yys1807 - } // end for yyj1807 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -24656,16 +32627,16 @@ func (x *NodeSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1810 int - var yyb1810 bool - var yyhl1810 bool = l >= 0 - yyj1810++ - if yyhl1810 { - yyb1810 = yyj1810 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1810 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1810 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -24673,26 +32644,26 @@ func (x *NodeSelector) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.NodeSelectorTerms = nil } else { - yyv1811 := &x.NodeSelectorTerms - yym1812 := z.DecBinary() - _ = yym1812 + yyv7 := &x.NodeSelectorTerms + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv1811), d) + h.decSliceNodeSelectorTerm((*[]NodeSelectorTerm)(yyv7), d) } } for { - yyj1810++ - if yyhl1810 { - yyb1810 = yyj1810 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1810 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1810 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1810-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -24704,36 +32675,36 @@ func (x *NodeSelectorTerm) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1813 := z.EncBinary() - _ = yym1813 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1814 := !z.EncBinary() - yy2arr1814 := z.EncBasicHandle().StructToArray - var yyq1814 [1]bool - _, _, _ = yysep1814, yyq1814, yy2arr1814 - const yyr1814 bool = false - var yynn1814 int - if yyr1814 || yy2arr1814 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1814 = 1 - for _, b := range yyq1814 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1814++ + yynn2++ } } - r.EncodeMapStart(yynn1814) - yynn1814 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1814 || yy2arr1814 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.MatchExpressions == nil { r.EncodeNil() } else { - yym1816 := z.EncBinary() - _ = yym1816 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceNodeSelectorRequirement(([]NodeSelectorRequirement)(x.MatchExpressions), e) @@ -24746,15 +32717,15 @@ func (x *NodeSelectorTerm) CodecEncodeSelf(e *codec1978.Encoder) { if x.MatchExpressions == nil { r.EncodeNil() } else { - yym1817 := z.EncBinary() - _ = yym1817 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceNodeSelectorRequirement(([]NodeSelectorRequirement)(x.MatchExpressions), e) } } } - if yyr1814 || yy2arr1814 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -24767,25 +32738,25 @@ func (x *NodeSelectorTerm) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1818 := z.DecBinary() - _ = yym1818 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1819 := r.ContainerType() - if yyct1819 == codecSelferValueTypeMap1234 { - yyl1819 := r.ReadMapStart() - if yyl1819 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1819, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1819 == codecSelferValueTypeArray1234 { - yyl1819 := r.ReadArrayStart() - if yyl1819 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1819, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -24797,12 +32768,12 @@ func (x *NodeSelectorTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1820Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1820Slc - var yyhl1820 bool = l >= 0 - for yyj1820 := 0; ; yyj1820++ { - if yyhl1820 { - if yyj1820 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -24811,26 +32782,26 @@ func (x *NodeSelectorTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1820Slc = r.DecodeBytes(yys1820Slc, true, true) - yys1820 := string(yys1820Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1820 { + switch yys3 { case "matchExpressions": if r.TryDecodeAsNil() { x.MatchExpressions = nil } else { - yyv1821 := &x.MatchExpressions - yym1822 := z.DecBinary() - _ = yym1822 + yyv4 := &x.MatchExpressions + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv1821), d) + h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys1820) - } // end switch yys1820 - } // end for yyj1820 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -24838,16 +32809,16 @@ func (x *NodeSelectorTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1823 int - var yyb1823 bool - var yyhl1823 bool = l >= 0 - yyj1823++ - if yyhl1823 { - yyb1823 = yyj1823 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1823 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1823 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -24855,26 +32826,26 @@ func (x *NodeSelectorTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.MatchExpressions = nil } else { - yyv1824 := &x.MatchExpressions - yym1825 := z.DecBinary() - _ = yym1825 + yyv7 := &x.MatchExpressions + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv1824), d) + h.decSliceNodeSelectorRequirement((*[]NodeSelectorRequirement)(yyv7), d) } } for { - yyj1823++ - if yyhl1823 { - yyb1823 = yyj1823 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1823 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1823 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1823-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -24886,34 +32857,34 @@ func (x *NodeSelectorRequirement) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1826 := z.EncBinary() - _ = yym1826 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1827 := !z.EncBinary() - yy2arr1827 := z.EncBasicHandle().StructToArray - var yyq1827 [3]bool - _, _, _ = yysep1827, yyq1827, yy2arr1827 - const yyr1827 bool = false - yyq1827[2] = len(x.Values) != 0 - var yynn1827 int - if yyr1827 || yy2arr1827 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = len(x.Values) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1827 = 2 - for _, b := range yyq1827 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1827++ + yynn2++ } } - r.EncodeMapStart(yynn1827) - yynn1827 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1827 || yy2arr1827 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1829 := z.EncBinary() - _ = yym1829 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Key)) @@ -24922,14 +32893,14 @@ func (x *NodeSelectorRequirement) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("key")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1830 := z.EncBinary() - _ = yym1830 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } - if yyr1827 || yy2arr1827 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Operator.CodecEncodeSelf(e) } else { @@ -24938,14 +32909,14 @@ func (x *NodeSelectorRequirement) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Operator.CodecEncodeSelf(e) } - if yyr1827 || yy2arr1827 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1827[2] { + if yyq2[2] { if x.Values == nil { r.EncodeNil() } else { - yym1833 := z.EncBinary() - _ = yym1833 + yym10 := z.EncBinary() + _ = yym10 if false { } else { z.F.EncSliceStringV(x.Values, false, e) @@ -24955,15 +32926,15 @@ func (x *NodeSelectorRequirement) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1827[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("values")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Values == nil { r.EncodeNil() } else { - yym1834 := z.EncBinary() - _ = yym1834 + yym11 := z.EncBinary() + _ = yym11 if false { } else { z.F.EncSliceStringV(x.Values, false, e) @@ -24971,7 +32942,7 @@ func (x *NodeSelectorRequirement) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1827 || yy2arr1827 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -24984,25 +32955,25 @@ func (x *NodeSelectorRequirement) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1835 := z.DecBinary() - _ = yym1835 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1836 := r.ContainerType() - if yyct1836 == codecSelferValueTypeMap1234 { - yyl1836 := r.ReadMapStart() - if yyl1836 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1836, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1836 == codecSelferValueTypeArray1234 { - yyl1836 := r.ReadArrayStart() - if yyl1836 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1836, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -25014,12 +32985,12 @@ func (x *NodeSelectorRequirement) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1837Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1837Slc - var yyhl1837 bool = l >= 0 - for yyj1837 := 0; ; yyj1837++ { - if yyhl1837 { - if yyj1837 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -25028,38 +32999,45 @@ func (x *NodeSelectorRequirement) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1837Slc = r.DecodeBytes(yys1837Slc, true, true) - yys1837 := string(yys1837Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1837 { + switch yys3 { case "key": if r.TryDecodeAsNil() { x.Key = "" } else { - x.Key = string(r.DecodeString()) + yyv4 := &x.Key + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "operator": if r.TryDecodeAsNil() { x.Operator = "" } else { - x.Operator = NodeSelectorOperator(r.DecodeString()) + yyv6 := &x.Operator + yyv6.CodecDecodeSelf(d) } case "values": if r.TryDecodeAsNil() { x.Values = nil } else { - yyv1840 := &x.Values - yym1841 := z.DecBinary() - _ = yym1841 + yyv7 := &x.Values + yym8 := z.DecBinary() + _ = yym8 if false { } else { - z.F.DecSliceStringX(yyv1840, false, d) + z.F.DecSliceStringX(yyv7, false, d) } } default: - z.DecStructFieldNotFound(-1, yys1837) - } // end switch yys1837 - } // end for yyj1837 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -25067,16 +33045,16 @@ func (x *NodeSelectorRequirement) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1842 int - var yyb1842 bool - var yyhl1842 bool = l >= 0 - yyj1842++ - if yyhl1842 { - yyb1842 = yyj1842 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1842 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1842 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25084,15 +33062,21 @@ func (x *NodeSelectorRequirement) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Key = "" } else { - x.Key = string(r.DecodeString()) + yyv10 := &x.Key + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } - yyj1842++ - if yyhl1842 { - yyb1842 = yyj1842 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1842 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1842 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25100,15 +33084,16 @@ func (x *NodeSelectorRequirement) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Operator = "" } else { - x.Operator = NodeSelectorOperator(r.DecodeString()) + yyv12 := &x.Operator + yyv12.CodecDecodeSelf(d) } - yyj1842++ - if yyhl1842 { - yyb1842 = yyj1842 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1842 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1842 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25116,26 +33101,26 @@ func (x *NodeSelectorRequirement) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Values = nil } else { - yyv1845 := &x.Values - yym1846 := z.DecBinary() - _ = yym1846 + yyv13 := &x.Values + yym14 := z.DecBinary() + _ = yym14 if false { } else { - z.F.DecSliceStringX(yyv1845, false, d) + z.F.DecSliceStringX(yyv13, false, d) } } for { - yyj1842++ - if yyhl1842 { - yyb1842 = yyj1842 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1842 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1842 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1842-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -25144,8 +33129,8 @@ func (x NodeSelectorOperator) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1847 := z.EncBinary() - _ = yym1847 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -25157,8 +33142,8 @@ func (x *NodeSelectorOperator) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1848 := z.DecBinary() - _ = yym1848 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -25173,35 +33158,35 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1849 := z.EncBinary() - _ = yym1849 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1850 := !z.EncBinary() - yy2arr1850 := z.EncBasicHandle().StructToArray - var yyq1850 [3]bool - _, _, _ = yysep1850, yyq1850, yy2arr1850 - const yyr1850 bool = false - yyq1850[0] = x.NodeAffinity != nil - yyq1850[1] = x.PodAffinity != nil - yyq1850[2] = x.PodAntiAffinity != nil - var yynn1850 int - if yyr1850 || yy2arr1850 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.NodeAffinity != nil + yyq2[1] = x.PodAffinity != nil + yyq2[2] = x.PodAntiAffinity != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1850 = 0 - for _, b := range yyq1850 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1850++ + yynn2++ } } - r.EncodeMapStart(yynn1850) - yynn1850 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1850 || yy2arr1850 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1850[0] { + if yyq2[0] { if x.NodeAffinity == nil { r.EncodeNil() } else { @@ -25211,7 +33196,7 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1850[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nodeAffinity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -25222,9 +33207,9 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1850 || yy2arr1850 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1850[1] { + if yyq2[1] { if x.PodAffinity == nil { r.EncodeNil() } else { @@ -25234,7 +33219,7 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1850[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podAffinity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -25245,9 +33230,9 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1850 || yy2arr1850 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1850[2] { + if yyq2[2] { if x.PodAntiAffinity == nil { r.EncodeNil() } else { @@ -25257,7 +33242,7 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1850[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podAntiAffinity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -25268,7 +33253,7 @@ func (x *Affinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1850 || yy2arr1850 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -25281,25 +33266,25 @@ func (x *Affinity) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1854 := z.DecBinary() - _ = yym1854 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1855 := r.ContainerType() - if yyct1855 == codecSelferValueTypeMap1234 { - yyl1855 := r.ReadMapStart() - if yyl1855 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1855, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1855 == codecSelferValueTypeArray1234 { - yyl1855 := r.ReadArrayStart() - if yyl1855 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1855, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -25311,12 +33296,12 @@ func (x *Affinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1856Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1856Slc - var yyhl1856 bool = l >= 0 - for yyj1856 := 0; ; yyj1856++ { - if yyhl1856 { - if yyj1856 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -25325,10 +33310,10 @@ func (x *Affinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1856Slc = r.DecodeBytes(yys1856Slc, true, true) - yys1856 := string(yys1856Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1856 { + switch yys3 { case "nodeAffinity": if r.TryDecodeAsNil() { if x.NodeAffinity != nil { @@ -25363,9 +33348,9 @@ func (x *Affinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.PodAntiAffinity.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1856) - } // end switch yys1856 - } // end for yyj1856 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -25373,16 +33358,16 @@ func (x *Affinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1860 int - var yyb1860 bool - var yyhl1860 bool = l >= 0 - yyj1860++ - if yyhl1860 { - yyb1860 = yyj1860 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1860 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1860 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25397,13 +33382,13 @@ func (x *Affinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.NodeAffinity.CodecDecodeSelf(d) } - yyj1860++ - if yyhl1860 { - yyb1860 = yyj1860 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1860 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1860 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25418,13 +33403,13 @@ func (x *Affinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.PodAffinity.CodecDecodeSelf(d) } - yyj1860++ - if yyhl1860 { - yyb1860 = yyj1860 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1860 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1860 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25440,17 +33425,17 @@ func (x *Affinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.PodAntiAffinity.CodecDecodeSelf(d) } for { - yyj1860++ - if yyhl1860 { - yyb1860 = yyj1860 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1860 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1860 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1860-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -25462,39 +33447,39 @@ func (x *PodAffinity) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1864 := z.EncBinary() - _ = yym1864 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1865 := !z.EncBinary() - yy2arr1865 := z.EncBasicHandle().StructToArray - var yyq1865 [2]bool - _, _, _ = yysep1865, yyq1865, yy2arr1865 - const yyr1865 bool = false - yyq1865[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 - yyq1865[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1865 int - if yyr1865 || yy2arr1865 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 + yyq2[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1865 = 0 - for _, b := range yyq1865 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1865++ + yynn2++ } } - r.EncodeMapStart(yynn1865) - yynn1865 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1865 || yy2arr1865 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1865[0] { + if yyq2[0] { if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1867 := z.EncBinary() - _ = yym1867 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) @@ -25504,15 +33489,15 @@ func (x *PodAffinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1865[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1868 := z.EncBinary() - _ = yym1868 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) @@ -25520,14 +33505,14 @@ func (x *PodAffinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1865 || yy2arr1865 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1865[1] { + if yyq2[1] { if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1870 := z.EncBinary() - _ = yym1870 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) @@ -25537,15 +33522,15 @@ func (x *PodAffinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1865[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1871 := z.EncBinary() - _ = yym1871 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) @@ -25553,7 +33538,7 @@ func (x *PodAffinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1865 || yy2arr1865 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -25566,25 +33551,25 @@ func (x *PodAffinity) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1872 := z.DecBinary() - _ = yym1872 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1873 := r.ContainerType() - if yyct1873 == codecSelferValueTypeMap1234 { - yyl1873 := r.ReadMapStart() - if yyl1873 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1873, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1873 == codecSelferValueTypeArray1234 { - yyl1873 := r.ReadArrayStart() - if yyl1873 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1873, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -25596,12 +33581,12 @@ func (x *PodAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1874Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1874Slc - var yyhl1874 bool = l >= 0 - for yyj1874 := 0; ; yyj1874++ { - if yyhl1874 { - if yyj1874 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -25610,38 +33595,38 @@ func (x *PodAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1874Slc = r.DecodeBytes(yys1874Slc, true, true) - yys1874 := string(yys1874Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1874 { + switch yys3 { case "requiredDuringSchedulingIgnoredDuringExecution": if r.TryDecodeAsNil() { x.RequiredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1875 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1876 := z.DecBinary() - _ = yym1876 + yyv4 := &x.RequiredDuringSchedulingIgnoredDuringExecution + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1875), d) + h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv4), d) } } case "preferredDuringSchedulingIgnoredDuringExecution": if r.TryDecodeAsNil() { x.PreferredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1877 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1878 := z.DecBinary() - _ = yym1878 + yyv6 := &x.PreferredDuringSchedulingIgnoredDuringExecution + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1877), d) + h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv6), d) } } default: - z.DecStructFieldNotFound(-1, yys1874) - } // end switch yys1874 - } // end for yyj1874 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -25649,16 +33634,16 @@ func (x *PodAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1879 int - var yyb1879 bool - var yyhl1879 bool = l >= 0 - yyj1879++ - if yyhl1879 { - yyb1879 = yyj1879 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1879 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1879 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25666,21 +33651,21 @@ func (x *PodAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.RequiredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1880 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1881 := z.DecBinary() - _ = yym1881 + yyv9 := &x.RequiredDuringSchedulingIgnoredDuringExecution + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1880), d) + h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv9), d) } } - yyj1879++ - if yyhl1879 { - yyb1879 = yyj1879 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1879 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1879 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25688,26 +33673,26 @@ func (x *PodAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PreferredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1882 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1883 := z.DecBinary() - _ = yym1883 + yyv11 := &x.PreferredDuringSchedulingIgnoredDuringExecution + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1882), d) + h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv11), d) } } for { - yyj1879++ - if yyhl1879 { - yyb1879 = yyj1879 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1879 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1879 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1879-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -25719,39 +33704,39 @@ func (x *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1884 := z.EncBinary() - _ = yym1884 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1885 := !z.EncBinary() - yy2arr1885 := z.EncBasicHandle().StructToArray - var yyq1885 [2]bool - _, _, _ = yysep1885, yyq1885, yy2arr1885 - const yyr1885 bool = false - yyq1885[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 - yyq1885[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1885 int - if yyr1885 || yy2arr1885 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.RequiredDuringSchedulingIgnoredDuringExecution) != 0 + yyq2[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1885 = 0 - for _, b := range yyq1885 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1885++ + yynn2++ } } - r.EncodeMapStart(yynn1885) - yynn1885 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1885 || yy2arr1885 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1885[0] { + if yyq2[0] { if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1887 := z.EncBinary() - _ = yym1887 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) @@ -25761,15 +33746,15 @@ func (x *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1885[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1888 := z.EncBinary() - _ = yym1888 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSlicePodAffinityTerm(([]PodAffinityTerm)(x.RequiredDuringSchedulingIgnoredDuringExecution), e) @@ -25777,14 +33762,14 @@ func (x *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1885 || yy2arr1885 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1885[1] { + if yyq2[1] { if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1890 := z.EncBinary() - _ = yym1890 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) @@ -25794,15 +33779,15 @@ func (x *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1885[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1891 := z.EncBinary() - _ = yym1891 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceWeightedPodAffinityTerm(([]WeightedPodAffinityTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) @@ -25810,7 +33795,7 @@ func (x *PodAntiAffinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1885 || yy2arr1885 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -25823,25 +33808,25 @@ func (x *PodAntiAffinity) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1892 := z.DecBinary() - _ = yym1892 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1893 := r.ContainerType() - if yyct1893 == codecSelferValueTypeMap1234 { - yyl1893 := r.ReadMapStart() - if yyl1893 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1893, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1893 == codecSelferValueTypeArray1234 { - yyl1893 := r.ReadArrayStart() - if yyl1893 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1893, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -25853,12 +33838,12 @@ func (x *PodAntiAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1894Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1894Slc - var yyhl1894 bool = l >= 0 - for yyj1894 := 0; ; yyj1894++ { - if yyhl1894 { - if yyj1894 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -25867,38 +33852,38 @@ func (x *PodAntiAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1894Slc = r.DecodeBytes(yys1894Slc, true, true) - yys1894 := string(yys1894Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1894 { + switch yys3 { case "requiredDuringSchedulingIgnoredDuringExecution": if r.TryDecodeAsNil() { x.RequiredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1895 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1896 := z.DecBinary() - _ = yym1896 + yyv4 := &x.RequiredDuringSchedulingIgnoredDuringExecution + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1895), d) + h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv4), d) } } case "preferredDuringSchedulingIgnoredDuringExecution": if r.TryDecodeAsNil() { x.PreferredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1897 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1898 := z.DecBinary() - _ = yym1898 + yyv6 := &x.PreferredDuringSchedulingIgnoredDuringExecution + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1897), d) + h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv6), d) } } default: - z.DecStructFieldNotFound(-1, yys1894) - } // end switch yys1894 - } // end for yyj1894 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -25906,16 +33891,16 @@ func (x *PodAntiAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1899 int - var yyb1899 bool - var yyhl1899 bool = l >= 0 - yyj1899++ - if yyhl1899 { - yyb1899 = yyj1899 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1899 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1899 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25923,21 +33908,21 @@ func (x *PodAntiAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.RequiredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1900 := &x.RequiredDuringSchedulingIgnoredDuringExecution - yym1901 := z.DecBinary() - _ = yym1901 + yyv9 := &x.RequiredDuringSchedulingIgnoredDuringExecution + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv1900), d) + h.decSlicePodAffinityTerm((*[]PodAffinityTerm)(yyv9), d) } } - yyj1899++ - if yyhl1899 { - yyb1899 = yyj1899 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1899 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1899 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -25945,26 +33930,26 @@ func (x *PodAntiAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.PreferredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1902 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1903 := z.DecBinary() - _ = yym1903 + yyv11 := &x.PreferredDuringSchedulingIgnoredDuringExecution + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv1902), d) + h.decSliceWeightedPodAffinityTerm((*[]WeightedPodAffinityTerm)(yyv11), d) } } for { - yyj1899++ - if yyhl1899 { - yyb1899 = yyj1899 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1899 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1899 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1899-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -25976,33 +33961,33 @@ func (x *WeightedPodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1904 := z.EncBinary() - _ = yym1904 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1905 := !z.EncBinary() - yy2arr1905 := z.EncBasicHandle().StructToArray - var yyq1905 [2]bool - _, _, _ = yysep1905, yyq1905, yy2arr1905 - const yyr1905 bool = false - var yynn1905 int - if yyr1905 || yy2arr1905 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1905 = 2 - for _, b := range yyq1905 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1905++ + yynn2++ } } - r.EncodeMapStart(yynn1905) - yynn1905 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1905 || yy2arr1905 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1907 := z.EncBinary() - _ = yym1907 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Weight)) @@ -26011,25 +33996,25 @@ func (x *WeightedPodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("weight")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1908 := z.EncBinary() - _ = yym1908 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Weight)) } } - if yyr1905 || yy2arr1905 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1910 := &x.PodAffinityTerm - yy1910.CodecEncodeSelf(e) + yy7 := &x.PodAffinityTerm + yy7.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podAffinityTerm")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1911 := &x.PodAffinityTerm - yy1911.CodecEncodeSelf(e) + yy9 := &x.PodAffinityTerm + yy9.CodecEncodeSelf(e) } - if yyr1905 || yy2arr1905 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -26042,25 +34027,25 @@ func (x *WeightedPodAffinityTerm) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1912 := z.DecBinary() - _ = yym1912 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1913 := r.ContainerType() - if yyct1913 == codecSelferValueTypeMap1234 { - yyl1913 := r.ReadMapStart() - if yyl1913 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1913, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1913 == codecSelferValueTypeArray1234 { - yyl1913 := r.ReadArrayStart() - if yyl1913 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1913, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -26072,12 +34057,12 @@ func (x *WeightedPodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1914Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1914Slc - var yyhl1914 bool = l >= 0 - for yyj1914 := 0; ; yyj1914++ { - if yyhl1914 { - if yyj1914 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -26086,27 +34071,33 @@ func (x *WeightedPodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1914Slc = r.DecodeBytes(yys1914Slc, true, true) - yys1914 := string(yys1914Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1914 { + switch yys3 { case "weight": if r.TryDecodeAsNil() { x.Weight = 0 } else { - x.Weight = int32(r.DecodeInt(32)) + yyv4 := &x.Weight + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "podAffinityTerm": if r.TryDecodeAsNil() { x.PodAffinityTerm = PodAffinityTerm{} } else { - yyv1916 := &x.PodAffinityTerm - yyv1916.CodecDecodeSelf(d) + yyv6 := &x.PodAffinityTerm + yyv6.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1914) - } // end switch yys1914 - } // end for yyj1914 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -26114,16 +34105,16 @@ func (x *WeightedPodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1917 int - var yyb1917 bool - var yyhl1917 bool = l >= 0 - yyj1917++ - if yyhl1917 { - yyb1917 = yyj1917 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1917 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1917 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26131,15 +34122,21 @@ func (x *WeightedPodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Weight = 0 } else { - x.Weight = int32(r.DecodeInt(32)) + yyv8 := &x.Weight + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } - yyj1917++ - if yyhl1917 { - yyb1917 = yyj1917 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1917 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1917 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26147,21 +34144,21 @@ func (x *WeightedPodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.PodAffinityTerm = PodAffinityTerm{} } else { - yyv1919 := &x.PodAffinityTerm - yyv1919.CodecDecodeSelf(d) + yyv10 := &x.PodAffinityTerm + yyv10.CodecDecodeSelf(d) } for { - yyj1917++ - if yyhl1917 { - yyb1917 = yyj1917 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1917 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1917 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1917-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -26173,39 +34170,40 @@ func (x *PodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1920 := z.EncBinary() - _ = yym1920 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1921 := !z.EncBinary() - yy2arr1921 := z.EncBasicHandle().StructToArray - var yyq1921 [3]bool - _, _, _ = yysep1921, yyq1921, yy2arr1921 - const yyr1921 bool = false - yyq1921[0] = x.LabelSelector != nil - yyq1921[2] = x.TopologyKey != "" - var yynn1921 int - if yyr1921 || yy2arr1921 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.LabelSelector != nil + yyq2[1] = len(x.Namespaces) != 0 + yyq2[2] = x.TopologyKey != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1921 = 1 - for _, b := range yyq1921 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1921++ + yynn2++ } } - r.EncodeMapStart(yynn1921) - yynn1921 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1921 || yy2arr1921 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1921[0] { + if yyq2[0] { if x.LabelSelector == nil { r.EncodeNil() } else { - yym1923 := z.EncBinary() - _ = yym1923 + yym4 := z.EncBinary() + _ = yym4 if false { } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { } else { @@ -26216,15 +34214,15 @@ func (x *PodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1921[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("labelSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.LabelSelector == nil { r.EncodeNil() } else { - yym1924 := z.EncBinary() - _ = yym1924 + yym5 := z.EncBinary() + _ = yym5 if false { } else if z.HasExtensions() && z.EncExt(x.LabelSelector) { } else { @@ -26233,38 +34231,44 @@ func (x *PodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1921 || yy2arr1921 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Namespaces == nil { - r.EncodeNil() - } else { - yym1926 := z.EncBinary() - _ = yym1926 - if false { + if yyq2[1] { + if x.Namespaces == nil { + r.EncodeNil() } else { - z.F.EncSliceStringV(x.Namespaces, false, e) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.Namespaces, false, e) + } } + } else { + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespaces")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Namespaces == nil { - r.EncodeNil() - } else { - yym1927 := z.EncBinary() - _ = yym1927 - if false { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespaces")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Namespaces == nil { + r.EncodeNil() } else { - z.F.EncSliceStringV(x.Namespaces, false, e) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.Namespaces, false, e) + } } } } - if yyr1921 || yy2arr1921 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1921[2] { - yym1929 := z.EncBinary() - _ = yym1929 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey)) @@ -26273,19 +34277,19 @@ func (x *PodAffinityTerm) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1921[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("topologyKey")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1930 := z.EncBinary() - _ = yym1930 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.TopologyKey)) } } } - if yyr1921 || yy2arr1921 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -26298,25 +34302,25 @@ func (x *PodAffinityTerm) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1931 := z.DecBinary() - _ = yym1931 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1932 := r.ContainerType() - if yyct1932 == codecSelferValueTypeMap1234 { - yyl1932 := r.ReadMapStart() - if yyl1932 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1932, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1932 == codecSelferValueTypeArray1234 { - yyl1932 := r.ReadArrayStart() - if yyl1932 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1932, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -26328,12 +34332,12 @@ func (x *PodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1933Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1933Slc - var yyhl1933 bool = l >= 0 - for yyj1933 := 0; ; yyj1933++ { - if yyhl1933 { - if yyj1933 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -26342,10 +34346,10 @@ func (x *PodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1933Slc = r.DecodeBytes(yys1933Slc, true, true) - yys1933 := string(yys1933Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1933 { + switch yys3 { case "labelSelector": if r.TryDecodeAsNil() { if x.LabelSelector != nil { @@ -26353,10 +34357,10 @@ func (x *PodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.LabelSelector == nil { - x.LabelSelector = new(pkg2_unversioned.LabelSelector) + x.LabelSelector = new(pkg2_v1.LabelSelector) } - yym1935 := z.DecBinary() - _ = yym1935 + yym5 := z.DecBinary() + _ = yym5 if false { } else if z.HasExtensions() && z.DecExt(x.LabelSelector) { } else { @@ -26367,24 +34371,30 @@ func (x *PodAffinityTerm) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Namespaces = nil } else { - yyv1936 := &x.Namespaces - yym1937 := z.DecBinary() - _ = yym1937 + yyv6 := &x.Namespaces + yym7 := z.DecBinary() + _ = yym7 if false { } else { - z.F.DecSliceStringX(yyv1936, false, d) + z.F.DecSliceStringX(yyv6, false, d) } } case "topologyKey": if r.TryDecodeAsNil() { x.TopologyKey = "" } else { - x.TopologyKey = string(r.DecodeString()) + yyv8 := &x.TopologyKey + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1933) - } // end switch yys1933 - } // end for yyj1933 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -26392,16 +34402,16 @@ func (x *PodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1939 int - var yyb1939 bool - var yyhl1939 bool = l >= 0 - yyj1939++ - if yyhl1939 { - yyb1939 = yyj1939 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1939 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1939 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26412,23 +34422,23 @@ func (x *PodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) } } else { if x.LabelSelector == nil { - x.LabelSelector = new(pkg2_unversioned.LabelSelector) + x.LabelSelector = new(pkg2_v1.LabelSelector) } - yym1941 := z.DecBinary() - _ = yym1941 + yym12 := z.DecBinary() + _ = yym12 if false { } else if z.HasExtensions() && z.DecExt(x.LabelSelector) { } else { z.DecFallback(x.LabelSelector, false) } } - yyj1939++ - if yyhl1939 { - yyb1939 = yyj1939 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1939 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1939 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26436,21 +34446,21 @@ func (x *PodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Namespaces = nil } else { - yyv1942 := &x.Namespaces - yym1943 := z.DecBinary() - _ = yym1943 + yyv13 := &x.Namespaces + yym14 := z.DecBinary() + _ = yym14 if false { } else { - z.F.DecSliceStringX(yyv1942, false, d) + z.F.DecSliceStringX(yyv13, false, d) } } - yyj1939++ - if yyhl1939 { - yyb1939 = yyj1939 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1939 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1939 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26458,20 +34468,26 @@ func (x *PodAffinityTerm) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.TopologyKey = "" } else { - x.TopologyKey = string(r.DecodeString()) + yyv15 := &x.TopologyKey + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj1939++ - if yyhl1939 { - yyb1939 = yyj1939 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb1939 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb1939 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1939-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -26483,34 +34499,34 @@ func (x *NodeAffinity) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1945 := z.EncBinary() - _ = yym1945 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1946 := !z.EncBinary() - yy2arr1946 := z.EncBasicHandle().StructToArray - var yyq1946 [2]bool - _, _, _ = yysep1946, yyq1946, yy2arr1946 - const yyr1946 bool = false - yyq1946[0] = x.RequiredDuringSchedulingIgnoredDuringExecution != nil - yyq1946[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 - var yynn1946 int - if yyr1946 || yy2arr1946 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.RequiredDuringSchedulingIgnoredDuringExecution != nil + yyq2[1] = len(x.PreferredDuringSchedulingIgnoredDuringExecution) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1946 = 0 - for _, b := range yyq1946 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1946++ + yynn2++ } } - r.EncodeMapStart(yynn1946) - yynn1946 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1946 || yy2arr1946 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1946[0] { + if yyq2[0] { if x.RequiredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { @@ -26520,7 +34536,7 @@ func (x *NodeAffinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1946[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("requiredDuringSchedulingIgnoredDuringExecution")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -26531,14 +34547,14 @@ func (x *NodeAffinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1946 || yy2arr1946 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1946[1] { + if yyq2[1] { if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1949 := z.EncBinary() - _ = yym1949 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) @@ -26548,15 +34564,15 @@ func (x *NodeAffinity) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1946[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preferredDuringSchedulingIgnoredDuringExecution")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.PreferredDuringSchedulingIgnoredDuringExecution == nil { r.EncodeNil() } else { - yym1950 := z.EncBinary() - _ = yym1950 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSlicePreferredSchedulingTerm(([]PreferredSchedulingTerm)(x.PreferredDuringSchedulingIgnoredDuringExecution), e) @@ -26564,7 +34580,7 @@ func (x *NodeAffinity) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1946 || yy2arr1946 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -26577,25 +34593,25 @@ func (x *NodeAffinity) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1951 := z.DecBinary() - _ = yym1951 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1952 := r.ContainerType() - if yyct1952 == codecSelferValueTypeMap1234 { - yyl1952 := r.ReadMapStart() - if yyl1952 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1952, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1952 == codecSelferValueTypeArray1234 { - yyl1952 := r.ReadArrayStart() - if yyl1952 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1952, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -26607,12 +34623,12 @@ func (x *NodeAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1953Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1953Slc - var yyhl1953 bool = l >= 0 - for yyj1953 := 0; ; yyj1953++ { - if yyhl1953 { - if yyj1953 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -26621,10 +34637,10 @@ func (x *NodeAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1953Slc = r.DecodeBytes(yys1953Slc, true, true) - yys1953 := string(yys1953Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1953 { + switch yys3 { case "requiredDuringSchedulingIgnoredDuringExecution": if r.TryDecodeAsNil() { if x.RequiredDuringSchedulingIgnoredDuringExecution != nil { @@ -26640,18 +34656,18 @@ func (x *NodeAffinity) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PreferredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1955 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1956 := z.DecBinary() - _ = yym1956 + yyv5 := &x.PreferredDuringSchedulingIgnoredDuringExecution + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv1955), d) + h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv5), d) } } default: - z.DecStructFieldNotFound(-1, yys1953) - } // end switch yys1953 - } // end for yyj1953 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -26659,16 +34675,16 @@ func (x *NodeAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1957 int - var yyb1957 bool - var yyhl1957 bool = l >= 0 - yyj1957++ - if yyhl1957 { - yyb1957 = yyj1957 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1957 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1957 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26683,13 +34699,13 @@ func (x *NodeAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.RequiredDuringSchedulingIgnoredDuringExecution.CodecDecodeSelf(d) } - yyj1957++ - if yyhl1957 { - yyb1957 = yyj1957 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1957 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1957 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26697,26 +34713,26 @@ func (x *NodeAffinity) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PreferredDuringSchedulingIgnoredDuringExecution = nil } else { - yyv1959 := &x.PreferredDuringSchedulingIgnoredDuringExecution - yym1960 := z.DecBinary() - _ = yym1960 + yyv9 := &x.PreferredDuringSchedulingIgnoredDuringExecution + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv1959), d) + h.decSlicePreferredSchedulingTerm((*[]PreferredSchedulingTerm)(yyv9), d) } } for { - yyj1957++ - if yyhl1957 { - yyb1957 = yyj1957 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1957 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1957 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1957-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -26728,33 +34744,33 @@ func (x *PreferredSchedulingTerm) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1961 := z.EncBinary() - _ = yym1961 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1962 := !z.EncBinary() - yy2arr1962 := z.EncBasicHandle().StructToArray - var yyq1962 [2]bool - _, _, _ = yysep1962, yyq1962, yy2arr1962 - const yyr1962 bool = false - var yynn1962 int - if yyr1962 || yy2arr1962 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1962 = 2 - for _, b := range yyq1962 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1962++ + yynn2++ } } - r.EncodeMapStart(yynn1962) - yynn1962 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1962 || yy2arr1962 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1964 := z.EncBinary() - _ = yym1964 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Weight)) @@ -26763,25 +34779,25 @@ func (x *PreferredSchedulingTerm) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("weight")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1965 := z.EncBinary() - _ = yym1965 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Weight)) } } - if yyr1962 || yy2arr1962 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1967 := &x.Preference - yy1967.CodecEncodeSelf(e) + yy7 := &x.Preference + yy7.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preference")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1968 := &x.Preference - yy1968.CodecEncodeSelf(e) + yy9 := &x.Preference + yy9.CodecEncodeSelf(e) } - if yyr1962 || yy2arr1962 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -26794,25 +34810,25 @@ func (x *PreferredSchedulingTerm) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1969 := z.DecBinary() - _ = yym1969 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1970 := r.ContainerType() - if yyct1970 == codecSelferValueTypeMap1234 { - yyl1970 := r.ReadMapStart() - if yyl1970 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1970, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1970 == codecSelferValueTypeArray1234 { - yyl1970 := r.ReadArrayStart() - if yyl1970 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1970, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -26824,12 +34840,12 @@ func (x *PreferredSchedulingTerm) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1971Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1971Slc - var yyhl1971 bool = l >= 0 - for yyj1971 := 0; ; yyj1971++ { - if yyhl1971 { - if yyj1971 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -26838,27 +34854,33 @@ func (x *PreferredSchedulingTerm) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1971Slc = r.DecodeBytes(yys1971Slc, true, true) - yys1971 := string(yys1971Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1971 { + switch yys3 { case "weight": if r.TryDecodeAsNil() { x.Weight = 0 } else { - x.Weight = int32(r.DecodeInt(32)) + yyv4 := &x.Weight + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "preference": if r.TryDecodeAsNil() { x.Preference = NodeSelectorTerm{} } else { - yyv1973 := &x.Preference - yyv1973.CodecDecodeSelf(d) + yyv6 := &x.Preference + yyv6.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1971) - } // end switch yys1971 - } // end for yyj1971 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -26866,16 +34888,16 @@ func (x *PreferredSchedulingTerm) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1974 int - var yyb1974 bool - var yyhl1974 bool = l >= 0 - yyj1974++ - if yyhl1974 { - yyb1974 = yyj1974 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1974 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1974 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26883,15 +34905,21 @@ func (x *PreferredSchedulingTerm) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Weight = 0 } else { - x.Weight = int32(r.DecodeInt(32)) + yyv8 := &x.Weight + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } - yyj1974++ - if yyhl1974 { - yyb1974 = yyj1974 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1974 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1974 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -26899,21 +34927,21 @@ func (x *PreferredSchedulingTerm) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Preference = NodeSelectorTerm{} } else { - yyv1976 := &x.Preference - yyv1976.CodecDecodeSelf(d) + yyv10 := &x.Preference + yyv10.CodecDecodeSelf(d) } for { - yyj1974++ - if yyhl1974 { - yyb1974 = yyj1974 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1974 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1974 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1974-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -26925,34 +34953,35 @@ func (x *Taint) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1977 := z.EncBinary() - _ = yym1977 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1978 := !z.EncBinary() - yy2arr1978 := z.EncBasicHandle().StructToArray - var yyq1978 [3]bool - _, _, _ = yysep1978, yyq1978, yy2arr1978 - const yyr1978 bool = false - yyq1978[1] = x.Value != "" - var yynn1978 int - if yyr1978 || yy2arr1978 { - r.EncodeArrayStart(3) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Value != "" + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn1978 = 2 - for _, b := range yyq1978 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1978++ + yynn2++ } } - r.EncodeMapStart(yynn1978) - yynn1978 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1978 || yy2arr1978 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1980 := z.EncBinary() - _ = yym1980 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Key)) @@ -26961,18 +34990,18 @@ func (x *Taint) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("key")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1981 := z.EncBinary() - _ = yym1981 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } - if yyr1978 || yy2arr1978 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1978[1] { - yym1983 := z.EncBinary() - _ = yym1983 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Value)) @@ -26981,19 +35010,19 @@ func (x *Taint) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1978[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("value")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1984 := z.EncBinary() - _ = yym1984 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Value)) } } } - if yyr1978 || yy2arr1978 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Effect.CodecEncodeSelf(e) } else { @@ -27002,7 +35031,44 @@ func (x *Taint) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Effect.CodecEncodeSelf(e) } - if yyr1978 || yy2arr1978 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy13 := &x.TimeAdded + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(yy13) { + } else if yym14 { + z.EncBinaryMarshal(yy13) + } else if !yym14 && z.IsJSONHandle() { + z.EncJSONMarshal(yy13) + } else { + z.EncFallback(yy13) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("timeAdded")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy15 := &x.TimeAdded + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) + } else { + z.EncFallback(yy15) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -27015,25 +35081,25 @@ func (x *Taint) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1986 := z.DecBinary() - _ = yym1986 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1987 := r.ContainerType() - if yyct1987 == codecSelferValueTypeMap1234 { - yyl1987 := r.ReadMapStart() - if yyl1987 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1987, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1987 == codecSelferValueTypeArray1234 { - yyl1987 := r.ReadArrayStart() - if yyl1987 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1987, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -27045,12 +35111,12 @@ func (x *Taint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1988Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1988Slc - var yyhl1988 bool = l >= 0 - for yyj1988 := 0; ; yyj1988++ { - if yyhl1988 { - if yyj1988 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -27059,32 +35125,62 @@ func (x *Taint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1988Slc = r.DecodeBytes(yys1988Slc, true, true) - yys1988 := string(yys1988Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1988 { + switch yys3 { case "key": if r.TryDecodeAsNil() { x.Key = "" } else { - x.Key = string(r.DecodeString()) + yyv4 := &x.Key + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "value": if r.TryDecodeAsNil() { x.Value = "" } else { - x.Value = string(r.DecodeString()) + yyv6 := &x.Value + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "effect": if r.TryDecodeAsNil() { x.Effect = "" } else { - x.Effect = TaintEffect(r.DecodeString()) + yyv8 := &x.Effect + yyv8.CodecDecodeSelf(d) + } + case "timeAdded": + if r.TryDecodeAsNil() { + x.TimeAdded = pkg2_v1.Time{} + } else { + yyv9 := &x.TimeAdded + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if yym10 { + z.DecBinaryUnmarshal(yyv9) + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) + } else { + z.DecFallback(yyv9, false) + } } default: - z.DecStructFieldNotFound(-1, yys1988) - } // end switch yys1988 - } // end for yyj1988 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -27092,16 +35188,16 @@ func (x *Taint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1992 int - var yyb1992 bool - var yyhl1992 bool = l >= 0 - yyj1992++ - if yyhl1992 { - yyb1992 = yyj1992 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1992 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1992 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27109,15 +35205,21 @@ func (x *Taint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Key = "" } else { - x.Key = string(r.DecodeString()) + yyv12 := &x.Key + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj1992++ - if yyhl1992 { - yyb1992 = yyj1992 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1992 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1992 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27125,15 +35227,21 @@ func (x *Taint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Value = "" } else { - x.Value = string(r.DecodeString()) + yyv14 := &x.Value + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj1992++ - if yyhl1992 { - yyb1992 = yyj1992 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1992 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1992 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27141,20 +35249,48 @@ func (x *Taint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Effect = "" } else { - x.Effect = TaintEffect(r.DecodeString()) + yyv16 := &x.Effect + yyv16.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TimeAdded = pkg2_v1.Time{} + } else { + yyv17 := &x.TimeAdded + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) + } else { + z.DecFallback(yyv17, false) + } } for { - yyj1992++ - if yyhl1992 { - yyb1992 = yyj1992 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1992 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1992 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1992-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -27163,8 +35299,8 @@ func (x TaintEffect) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1996 := z.EncBinary() - _ = yym1996 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -27176,8 +35312,8 @@ func (x *TaintEffect) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1997 := z.DecBinary() - _ = yym1997 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -27192,38 +35328,39 @@ func (x *Toleration) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1998 := z.EncBinary() - _ = yym1998 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1999 := !z.EncBinary() - yy2arr1999 := z.EncBasicHandle().StructToArray - var yyq1999 [4]bool - _, _, _ = yysep1999, yyq1999, yy2arr1999 - const yyr1999 bool = false - yyq1999[0] = x.Key != "" - yyq1999[1] = x.Operator != "" - yyq1999[2] = x.Value != "" - yyq1999[3] = x.Effect != "" - var yynn1999 int - if yyr1999 || yy2arr1999 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Key != "" + yyq2[1] = x.Operator != "" + yyq2[2] = x.Value != "" + yyq2[3] = x.Effect != "" + yyq2[4] = x.TolerationSeconds != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) } else { - yynn1999 = 0 - for _, b := range yyq1999 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1999++ + yynn2++ } } - r.EncodeMapStart(yynn1999) - yynn1999 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1999 || yy2arr1999 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1999[0] { - yym2001 := z.EncBinary() - _ = yym2001 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Key)) @@ -27232,38 +35369,38 @@ func (x *Toleration) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1999[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("key")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2002 := z.EncBinary() - _ = yym2002 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Key)) } } } - if yyr1999 || yy2arr1999 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1999[1] { + if yyq2[1] { x.Operator.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1999[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("operator")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Operator.CodecEncodeSelf(e) } } - if yyr1999 || yy2arr1999 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1999[2] { - yym2005 := z.EncBinary() - _ = yym2005 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Value)) @@ -27272,34 +35409,69 @@ func (x *Toleration) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1999[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("value")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2006 := z.EncBinary() - _ = yym2006 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Value)) } } } - if yyr1999 || yy2arr1999 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1999[3] { + if yyq2[3] { x.Effect.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1999[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("effect")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Effect.CodecEncodeSelf(e) } } - if yyr1999 || yy2arr1999 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.TolerationSeconds == nil { + r.EncodeNil() + } else { + yy16 := *x.TolerationSeconds + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(yy16)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("tolerationSeconds")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.TolerationSeconds == nil { + r.EncodeNil() + } else { + yy18 := *x.TolerationSeconds + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(yy18)) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -27312,25 +35484,25 @@ func (x *Toleration) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2008 := z.DecBinary() - _ = yym2008 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2009 := r.ContainerType() - if yyct2009 == codecSelferValueTypeMap1234 { - yyl2009 := r.ReadMapStart() - if yyl2009 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2009, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2009 == codecSelferValueTypeArray1234 { - yyl2009 := r.ReadArrayStart() - if yyl2009 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2009, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -27342,12 +35514,12 @@ func (x *Toleration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2010Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2010Slc - var yyhl2010 bool = l >= 0 - for yyj2010 := 0; ; yyj2010++ { - if yyhl2010 { - if yyj2010 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -27356,38 +35528,68 @@ func (x *Toleration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2010Slc = r.DecodeBytes(yys2010Slc, true, true) - yys2010 := string(yys2010Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2010 { + switch yys3 { case "key": if r.TryDecodeAsNil() { x.Key = "" } else { - x.Key = string(r.DecodeString()) + yyv4 := &x.Key + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "operator": if r.TryDecodeAsNil() { x.Operator = "" } else { - x.Operator = TolerationOperator(r.DecodeString()) + yyv6 := &x.Operator + yyv6.CodecDecodeSelf(d) } case "value": if r.TryDecodeAsNil() { x.Value = "" } else { - x.Value = string(r.DecodeString()) + yyv7 := &x.Value + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } case "effect": if r.TryDecodeAsNil() { x.Effect = "" } else { - x.Effect = TaintEffect(r.DecodeString()) + yyv9 := &x.Effect + yyv9.CodecDecodeSelf(d) + } + case "tolerationSeconds": + if r.TryDecodeAsNil() { + if x.TolerationSeconds != nil { + x.TolerationSeconds = nil + } + } else { + if x.TolerationSeconds == nil { + x.TolerationSeconds = new(int64) + } + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int64)(x.TolerationSeconds)) = int64(r.DecodeInt(64)) + } } default: - z.DecStructFieldNotFound(-1, yys2010) - } // end switch yys2010 - } // end for yyj2010 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -27395,16 +35597,16 @@ func (x *Toleration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2015 int - var yyb2015 bool - var yyhl2015 bool = l >= 0 - yyj2015++ - if yyhl2015 { - yyb2015 = yyj2015 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2015 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2015 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27412,15 +35614,21 @@ func (x *Toleration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Key = "" } else { - x.Key = string(r.DecodeString()) + yyv13 := &x.Key + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2015++ - if yyhl2015 { - yyb2015 = yyj2015 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2015 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2015 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27428,15 +35636,16 @@ func (x *Toleration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Operator = "" } else { - x.Operator = TolerationOperator(r.DecodeString()) + yyv15 := &x.Operator + yyv15.CodecDecodeSelf(d) } - yyj2015++ - if yyhl2015 { - yyb2015 = yyj2015 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2015 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2015 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27444,15 +35653,21 @@ func (x *Toleration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Value = "" } else { - x.Value = string(r.DecodeString()) + yyv16 := &x.Value + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } - yyj2015++ - if yyhl2015 { - yyb2015 = yyj2015 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2015 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2015 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -27460,20 +35675,47 @@ func (x *Toleration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Effect = "" } else { - x.Effect = TaintEffect(r.DecodeString()) + yyv18 := &x.Effect + yyv18.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.TolerationSeconds != nil { + x.TolerationSeconds = nil + } + } else { + if x.TolerationSeconds == nil { + x.TolerationSeconds = new(int64) + } + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int64)(x.TolerationSeconds)) = int64(r.DecodeInt(64)) + } } for { - yyj2015++ - if yyhl2015 { - yyb2015 = yyj2015 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2015 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2015 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2015-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -27482,8 +35724,8 @@ func (x TolerationOperator) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym2020 := z.EncBinary() - _ = yym2020 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -27495,8 +35737,8 @@ func (x *TolerationOperator) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2021 := z.DecBinary() - _ = yym2021 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -27511,53 +35753,59 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2022 := z.EncBinary() - _ = yym2022 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2023 := !z.EncBinary() - yy2arr2023 := z.EncBasicHandle().StructToArray - var yyq2023 [17]bool - _, _, _ = yysep2023, yyq2023, yy2arr2023 - const yyr2023 bool = false - yyq2023[0] = len(x.Volumes) != 0 - yyq2023[2] = x.RestartPolicy != "" - yyq2023[3] = x.TerminationGracePeriodSeconds != nil - yyq2023[4] = x.ActiveDeadlineSeconds != nil - yyq2023[5] = x.DNSPolicy != "" - yyq2023[6] = len(x.NodeSelector) != 0 - yyq2023[7] = x.ServiceAccountName != "" - yyq2023[8] = x.DeprecatedServiceAccount != "" - yyq2023[9] = x.NodeName != "" - yyq2023[10] = x.HostNetwork != false - yyq2023[11] = x.HostPID != false - yyq2023[12] = x.HostIPC != false - yyq2023[13] = x.SecurityContext != nil - yyq2023[14] = len(x.ImagePullSecrets) != 0 - yyq2023[15] = x.Hostname != "" - yyq2023[16] = x.Subdomain != "" - var yynn2023 int - if yyr2023 || yy2arr2023 { - r.EncodeArrayStart(17) - } else { - yynn2023 = 1 - for _, b := range yyq2023 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [23]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Volumes) != 0 + yyq2[1] = len(x.InitContainers) != 0 + yyq2[3] = x.RestartPolicy != "" + yyq2[4] = x.TerminationGracePeriodSeconds != nil + yyq2[5] = x.ActiveDeadlineSeconds != nil + yyq2[6] = x.DNSPolicy != "" + yyq2[7] = len(x.NodeSelector) != 0 + yyq2[8] = x.ServiceAccountName != "" + yyq2[9] = x.DeprecatedServiceAccount != "" + yyq2[10] = x.AutomountServiceAccountToken != nil + yyq2[11] = x.NodeName != "" + yyq2[12] = x.HostNetwork != false + yyq2[13] = x.HostPID != false + yyq2[14] = x.HostIPC != false + yyq2[15] = x.SecurityContext != nil + yyq2[16] = len(x.ImagePullSecrets) != 0 + yyq2[17] = x.Hostname != "" + yyq2[18] = x.Subdomain != "" + yyq2[19] = x.Affinity != nil + yyq2[20] = x.SchedulerName != "" + yyq2[21] = len(x.Tolerations) != 0 + yyq2[22] = len(x.HostAliases) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(23) + } else { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2023++ + yynn2++ } } - r.EncodeMapStart(yynn2023) - yynn2023 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[0] { + if yyq2[0] { if x.Volumes == nil { r.EncodeNil() } else { - yym2025 := z.EncBinary() - _ = yym2025 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceVolume(([]Volume)(x.Volumes), e) @@ -27567,15 +35815,15 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2023[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Volumes == nil { r.EncodeNil() } else { - yym2026 := z.EncBinary() - _ = yym2026 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceVolume(([]Volume)(x.Volumes), e) @@ -27583,13 +35831,46 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.InitContainers == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceContainer(([]Container)(x.InitContainers), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("initContainers")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.InitContainers == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceContainer(([]Container)(x.InitContainers), e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Containers == nil { r.EncodeNil() } else { - yym2028 := z.EncBinary() - _ = yym2028 + yym10 := z.EncBinary() + _ = yym10 if false { } else { h.encSliceContainer(([]Container)(x.Containers), e) @@ -27602,122 +35883,122 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x.Containers == nil { r.EncodeNil() } else { - yym2029 := z.EncBinary() - _ = yym2029 + yym11 := z.EncBinary() + _ = yym11 if false { } else { h.encSliceContainer(([]Container)(x.Containers), e) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[2] { + if yyq2[3] { x.RestartPolicy.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[2] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("restartPolicy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.RestartPolicy.CodecEncodeSelf(e) } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[3] { + if yyq2[4] { if x.TerminationGracePeriodSeconds == nil { r.EncodeNil() } else { - yy2032 := *x.TerminationGracePeriodSeconds - yym2033 := z.EncBinary() - _ = yym2033 + yy16 := *x.TerminationGracePeriodSeconds + yym17 := z.EncBinary() + _ = yym17 if false { } else { - r.EncodeInt(int64(yy2032)) + r.EncodeInt(int64(yy16)) } } } else { r.EncodeNil() } } else { - if yyq2023[3] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("terminationGracePeriodSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.TerminationGracePeriodSeconds == nil { r.EncodeNil() } else { - yy2034 := *x.TerminationGracePeriodSeconds - yym2035 := z.EncBinary() - _ = yym2035 + yy18 := *x.TerminationGracePeriodSeconds + yym19 := z.EncBinary() + _ = yym19 if false { } else { - r.EncodeInt(int64(yy2034)) + r.EncodeInt(int64(yy18)) } } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[4] { + if yyq2[5] { if x.ActiveDeadlineSeconds == nil { r.EncodeNil() } else { - yy2037 := *x.ActiveDeadlineSeconds - yym2038 := z.EncBinary() - _ = yym2038 + yy21 := *x.ActiveDeadlineSeconds + yym22 := z.EncBinary() + _ = yym22 if false { } else { - r.EncodeInt(int64(yy2037)) + r.EncodeInt(int64(yy21)) } } } else { r.EncodeNil() } } else { - if yyq2023[4] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ActiveDeadlineSeconds == nil { r.EncodeNil() } else { - yy2039 := *x.ActiveDeadlineSeconds - yym2040 := z.EncBinary() - _ = yym2040 + yy23 := *x.ActiveDeadlineSeconds + yym24 := z.EncBinary() + _ = yym24 if false { } else { - r.EncodeInt(int64(yy2039)) + r.EncodeInt(int64(yy23)) } } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[5] { + if yyq2[6] { x.DNSPolicy.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[5] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("dnsPolicy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.DNSPolicy.CodecEncodeSelf(e) } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[6] { + if yyq2[7] { if x.NodeSelector == nil { r.EncodeNil() } else { - yym2043 := z.EncBinary() - _ = yym2043 + yym29 := z.EncBinary() + _ = yym29 if false { } else { z.F.EncMapStringStringV(x.NodeSelector, false, e) @@ -27727,15 +36008,15 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2023[6] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nodeSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.NodeSelector == nil { r.EncodeNil() } else { - yym2044 := z.EncBinary() - _ = yym2044 + yym30 := z.EncBinary() + _ = yym30 if false { } else { z.F.EncMapStringStringV(x.NodeSelector, false, e) @@ -27743,11 +36024,11 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[7] { - yym2046 := z.EncBinary() - _ = yym2046 + if yyq2[8] { + yym32 := z.EncBinary() + _ = yym32 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName)) @@ -27756,23 +36037,23 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[7] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("serviceAccountName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2047 := z.EncBinary() - _ = yym2047 + yym33 := z.EncBinary() + _ = yym33 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ServiceAccountName)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[8] { - yym2049 := z.EncBinary() - _ = yym2049 + if yyq2[9] { + yym35 := z.EncBinary() + _ = yym35 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DeprecatedServiceAccount)) @@ -27781,23 +36062,58 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[8] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("serviceAccount")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2050 := z.EncBinary() - _ = yym2050 + yym36 := z.EncBinary() + _ = yym36 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DeprecatedServiceAccount)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[10] { + if x.AutomountServiceAccountToken == nil { + r.EncodeNil() + } else { + yy38 := *x.AutomountServiceAccountToken + yym39 := z.EncBinary() + _ = yym39 + if false { + } else { + r.EncodeBool(bool(yy38)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[10] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("automountServiceAccountToken")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.AutomountServiceAccountToken == nil { + r.EncodeNil() + } else { + yy40 := *x.AutomountServiceAccountToken + yym41 := z.EncBinary() + _ = yym41 + if false { + } else { + r.EncodeBool(bool(yy40)) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[9] { - yym2052 := z.EncBinary() - _ = yym2052 + if yyq2[11] { + yym43 := z.EncBinary() + _ = yym43 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.NodeName)) @@ -27806,23 +36122,23 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[9] { + if yyq2[11] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nodeName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2053 := z.EncBinary() - _ = yym2053 + yym44 := z.EncBinary() + _ = yym44 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.NodeName)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[10] { - yym2055 := z.EncBinary() - _ = yym2055 + if yyq2[12] { + yym46 := z.EncBinary() + _ = yym46 if false { } else { r.EncodeBool(bool(x.HostNetwork)) @@ -27831,23 +36147,23 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq2023[10] { + if yyq2[12] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostNetwork")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2056 := z.EncBinary() - _ = yym2056 + yym47 := z.EncBinary() + _ = yym47 if false { } else { r.EncodeBool(bool(x.HostNetwork)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[11] { - yym2058 := z.EncBinary() - _ = yym2058 + if yyq2[13] { + yym49 := z.EncBinary() + _ = yym49 if false { } else { r.EncodeBool(bool(x.HostPID)) @@ -27856,23 +36172,23 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq2023[11] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2059 := z.EncBinary() - _ = yym2059 + yym50 := z.EncBinary() + _ = yym50 if false { } else { r.EncodeBool(bool(x.HostPID)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[12] { - yym2061 := z.EncBinary() - _ = yym2061 + if yyq2[14] { + yym52 := z.EncBinary() + _ = yym52 if false { } else { r.EncodeBool(bool(x.HostIPC)) @@ -27881,21 +36197,21 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq2023[12] { + if yyq2[14] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostIPC")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2062 := z.EncBinary() - _ = yym2062 + yym53 := z.EncBinary() + _ = yym53 if false { } else { r.EncodeBool(bool(x.HostIPC)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[13] { + if yyq2[15] { if x.SecurityContext == nil { r.EncodeNil() } else { @@ -27905,7 +36221,7 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2023[13] { + if yyq2[15] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("securityContext")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -27916,14 +36232,14 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[14] { + if yyq2[16] { if x.ImagePullSecrets == nil { r.EncodeNil() } else { - yym2065 := z.EncBinary() - _ = yym2065 + yym58 := z.EncBinary() + _ = yym58 if false { } else { h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) @@ -27933,15 +36249,15 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2023[14] { + if yyq2[16] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ImagePullSecrets == nil { r.EncodeNil() } else { - yym2066 := z.EncBinary() - _ = yym2066 + yym59 := z.EncBinary() + _ = yym59 if false { } else { h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) @@ -27949,11 +36265,11 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[15] { - yym2068 := z.EncBinary() - _ = yym2068 + if yyq2[17] { + yym61 := z.EncBinary() + _ = yym61 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) @@ -27962,23 +36278,23 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[15] { + if yyq2[17] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostname")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2069 := z.EncBinary() - _ = yym2069 + yym62 := z.EncBinary() + _ = yym62 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2023[16] { - yym2071 := z.EncBinary() - _ = yym2071 + if yyq2[18] { + yym64 := z.EncBinary() + _ = yym64 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain)) @@ -27987,19 +36303,133 @@ func (x *PodSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2023[16] { + if yyq2[18] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("subdomain")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2072 := z.EncBinary() - _ = yym2072 + yym65 := z.EncBinary() + _ = yym65 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Subdomain)) } } } - if yyr2023 || yy2arr2023 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[19] { + if x.Affinity == nil { + r.EncodeNil() + } else { + x.Affinity.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[19] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("affinity")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Affinity == nil { + r.EncodeNil() + } else { + x.Affinity.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[20] { + yym70 := z.EncBinary() + _ = yym70 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.SchedulerName)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[20] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("schedulerName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym71 := z.EncBinary() + _ = yym71 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.SchedulerName)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[21] { + if x.Tolerations == nil { + r.EncodeNil() + } else { + yym73 := z.EncBinary() + _ = yym73 + if false { + } else { + h.encSliceToleration(([]Toleration)(x.Tolerations), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[21] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("tolerations")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Tolerations == nil { + r.EncodeNil() + } else { + yym74 := z.EncBinary() + _ = yym74 + if false { + } else { + h.encSliceToleration(([]Toleration)(x.Tolerations), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[22] { + if x.HostAliases == nil { + r.EncodeNil() + } else { + yym76 := z.EncBinary() + _ = yym76 + if false { + } else { + h.encSliceHostAlias(([]HostAlias)(x.HostAliases), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[22] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("hostAliases")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.HostAliases == nil { + r.EncodeNil() + } else { + yym77 := z.EncBinary() + _ = yym77 + if false { + } else { + h.encSliceHostAlias(([]HostAlias)(x.HostAliases), e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -28012,25 +36442,25 @@ func (x *PodSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2073 := z.DecBinary() - _ = yym2073 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2074 := r.ContainerType() - if yyct2074 == codecSelferValueTypeMap1234 { - yyl2074 := r.ReadMapStart() - if yyl2074 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2074, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2074 == codecSelferValueTypeArray1234 { - yyl2074 := r.ReadArrayStart() - if yyl2074 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2074, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -28042,12 +36472,12 @@ func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2075Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2075Slc - var yyhl2075 bool = l >= 0 - for yyj2075 := 0; ; yyj2075++ { - if yyhl2075 { - if yyj2075 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -28056,39 +36486,52 @@ func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2075Slc = r.DecodeBytes(yys2075Slc, true, true) - yys2075 := string(yys2075Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2075 { + switch yys3 { case "volumes": if r.TryDecodeAsNil() { x.Volumes = nil } else { - yyv2076 := &x.Volumes - yym2077 := z.DecBinary() - _ = yym2077 + yyv4 := &x.Volumes + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceVolume((*[]Volume)(yyv4), d) + } + } + case "initContainers": + if r.TryDecodeAsNil() { + x.InitContainers = nil + } else { + yyv6 := &x.InitContainers + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceVolume((*[]Volume)(yyv2076), d) + h.decSliceContainer((*[]Container)(yyv6), d) } } case "containers": if r.TryDecodeAsNil() { x.Containers = nil } else { - yyv2078 := &x.Containers - yym2079 := z.DecBinary() - _ = yym2079 + yyv8 := &x.Containers + yym9 := z.DecBinary() + _ = yym9 if false { } else { - h.decSliceContainer((*[]Container)(yyv2078), d) + h.decSliceContainer((*[]Container)(yyv8), d) } } case "restartPolicy": if r.TryDecodeAsNil() { x.RestartPolicy = "" } else { - x.RestartPolicy = RestartPolicy(r.DecodeString()) + yyv10 := &x.RestartPolicy + yyv10.CodecDecodeSelf(d) } case "terminationGracePeriodSeconds": if r.TryDecodeAsNil() { @@ -28099,8 +36542,8 @@ func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.TerminationGracePeriodSeconds == nil { x.TerminationGracePeriodSeconds = new(int64) } - yym2082 := z.DecBinary() - _ = yym2082 + yym12 := z.DecBinary() + _ = yym12 if false { } else { *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64)) @@ -28115,8 +36558,8 @@ func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.ActiveDeadlineSeconds == nil { x.ActiveDeadlineSeconds = new(int64) } - yym2084 := z.DecBinary() - _ = yym2084 + yym14 := z.DecBinary() + _ = yym14 if false { } else { *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) @@ -28126,55 +36569,108 @@ func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.DNSPolicy = "" } else { - x.DNSPolicy = DNSPolicy(r.DecodeString()) + yyv15 := &x.DNSPolicy + yyv15.CodecDecodeSelf(d) } case "nodeSelector": if r.TryDecodeAsNil() { x.NodeSelector = nil } else { - yyv2086 := &x.NodeSelector - yym2087 := z.DecBinary() - _ = yym2087 + yyv16 := &x.NodeSelector + yym17 := z.DecBinary() + _ = yym17 if false { } else { - z.F.DecMapStringStringX(yyv2086, false, d) + z.F.DecMapStringStringX(yyv16, false, d) } } case "serviceAccountName": if r.TryDecodeAsNil() { x.ServiceAccountName = "" } else { - x.ServiceAccountName = string(r.DecodeString()) + yyv18 := &x.ServiceAccountName + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } } case "serviceAccount": if r.TryDecodeAsNil() { x.DeprecatedServiceAccount = "" } else { - x.DeprecatedServiceAccount = string(r.DecodeString()) + yyv20 := &x.DeprecatedServiceAccount + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } + } + case "automountServiceAccountToken": + if r.TryDecodeAsNil() { + if x.AutomountServiceAccountToken != nil { + x.AutomountServiceAccountToken = nil + } + } else { + if x.AutomountServiceAccountToken == nil { + x.AutomountServiceAccountToken = new(bool) + } + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*bool)(x.AutomountServiceAccountToken)) = r.DecodeBool() + } } case "nodeName": if r.TryDecodeAsNil() { x.NodeName = "" } else { - x.NodeName = string(r.DecodeString()) + yyv24 := &x.NodeName + yym25 := z.DecBinary() + _ = yym25 + if false { + } else { + *((*string)(yyv24)) = r.DecodeString() + } } case "hostNetwork": if r.TryDecodeAsNil() { x.HostNetwork = false } else { - x.HostNetwork = bool(r.DecodeBool()) + yyv26 := &x.HostNetwork + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*bool)(yyv26)) = r.DecodeBool() + } } case "hostPID": if r.TryDecodeAsNil() { x.HostPID = false } else { - x.HostPID = bool(r.DecodeBool()) + yyv28 := &x.HostPID + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*bool)(yyv28)) = r.DecodeBool() + } } case "hostIPC": if r.TryDecodeAsNil() { x.HostIPC = false } else { - x.HostIPC = bool(r.DecodeBool()) + yyv30 := &x.HostIPC + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*bool)(yyv30)) = r.DecodeBool() + } } case "securityContext": if r.TryDecodeAsNil() { @@ -28191,30 +36687,89 @@ func (x *PodSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ImagePullSecrets = nil } else { - yyv2095 := &x.ImagePullSecrets - yym2096 := z.DecBinary() - _ = yym2096 + yyv33 := &x.ImagePullSecrets + yym34 := z.DecBinary() + _ = yym34 if false { } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2095), d) + h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv33), d) } } case "hostname": if r.TryDecodeAsNil() { x.Hostname = "" } else { - x.Hostname = string(r.DecodeString()) + yyv35 := &x.Hostname + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } } case "subdomain": if r.TryDecodeAsNil() { x.Subdomain = "" } else { - x.Subdomain = string(r.DecodeString()) + yyv37 := &x.Subdomain + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } + } + case "affinity": + if r.TryDecodeAsNil() { + if x.Affinity != nil { + x.Affinity = nil + } + } else { + if x.Affinity == nil { + x.Affinity = new(Affinity) + } + x.Affinity.CodecDecodeSelf(d) + } + case "schedulerName": + if r.TryDecodeAsNil() { + x.SchedulerName = "" + } else { + yyv40 := &x.SchedulerName + yym41 := z.DecBinary() + _ = yym41 + if false { + } else { + *((*string)(yyv40)) = r.DecodeString() + } + } + case "tolerations": + if r.TryDecodeAsNil() { + x.Tolerations = nil + } else { + yyv42 := &x.Tolerations + yym43 := z.DecBinary() + _ = yym43 + if false { + } else { + h.decSliceToleration((*[]Toleration)(yyv42), d) + } + } + case "hostAliases": + if r.TryDecodeAsNil() { + x.HostAliases = nil + } else { + yyv44 := &x.HostAliases + yym45 := z.DecBinary() + _ = yym45 + if false { + } else { + h.decSliceHostAlias((*[]HostAlias)(yyv44), d) + } } default: - z.DecStructFieldNotFound(-1, yys2075) - } // end switch yys2075 - } // end for yyj2075 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -28222,342 +36777,776 @@ func (x *PodSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2099 int - var yyb2099 bool - var yyhl2099 bool = l >= 0 - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + var yyj46 int + var yyb46 bool + var yyhl46 bool = l >= 0 + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Volumes = nil + } else { + yyv47 := &x.Volumes + yym48 := z.DecBinary() + _ = yym48 + if false { + } else { + h.decSliceVolume((*[]Volume)(yyv47), d) + } + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.InitContainers = nil + } else { + yyv49 := &x.InitContainers + yym50 := z.DecBinary() + _ = yym50 + if false { + } else { + h.decSliceContainer((*[]Container)(yyv49), d) + } + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Containers = nil + } else { + yyv51 := &x.Containers + yym52 := z.DecBinary() + _ = yym52 + if false { + } else { + h.decSliceContainer((*[]Container)(yyv51), d) + } + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.RestartPolicy = "" + } else { + yyv53 := &x.RestartPolicy + yyv53.CodecDecodeSelf(d) + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + 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) + } + yym55 := z.DecBinary() + _ = yym55 + if false { + } else { + *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64)) + } + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + 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) + } + yym57 := z.DecBinary() + _ = yym57 + if false { + } else { + *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) + } + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Volumes = nil + x.DNSPolicy = "" + } else { + yyv58 := &x.DNSPolicy + yyv58.CodecDecodeSelf(d) + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.NodeSelector = nil } else { - yyv2100 := &x.Volumes - yym2101 := z.DecBinary() - _ = yym2101 + yyv59 := &x.NodeSelector + yym60 := z.DecBinary() + _ = yym60 if false { } else { - h.decSliceVolume((*[]Volume)(yyv2100), d) + z.F.DecMapStringStringX(yyv59, false, d) } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Containers = nil + x.ServiceAccountName = "" } else { - yyv2102 := &x.Containers - yym2103 := z.DecBinary() - _ = yym2103 + yyv61 := &x.ServiceAccountName + yym62 := z.DecBinary() + _ = yym62 if false { } else { - h.decSliceContainer((*[]Container)(yyv2102), d) + *((*string)(yyv61)) = r.DecodeString() } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.RestartPolicy = "" + x.DeprecatedServiceAccount = "" } else { - x.RestartPolicy = RestartPolicy(r.DecodeString()) + yyv63 := &x.DeprecatedServiceAccount + yym64 := z.DecBinary() + _ = yym64 + if false { + } else { + *((*string)(yyv63)) = r.DecodeString() + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.TerminationGracePeriodSeconds != nil { - x.TerminationGracePeriodSeconds = nil + if x.AutomountServiceAccountToken != nil { + x.AutomountServiceAccountToken = nil } } else { - if x.TerminationGracePeriodSeconds == nil { - x.TerminationGracePeriodSeconds = new(int64) + if x.AutomountServiceAccountToken == nil { + x.AutomountServiceAccountToken = new(bool) } - yym2106 := z.DecBinary() - _ = yym2106 + yym66 := z.DecBinary() + _ = yym66 if false { } else { - *((*int64)(x.TerminationGracePeriodSeconds)) = int64(r.DecodeInt(64)) + *((*bool)(x.AutomountServiceAccountToken)) = r.DecodeBool() } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ActiveDeadlineSeconds != nil { - x.ActiveDeadlineSeconds = nil - } + x.NodeName = "" } else { - if x.ActiveDeadlineSeconds == nil { - x.ActiveDeadlineSeconds = new(int64) - } - yym2108 := z.DecBinary() - _ = yym2108 + yyv67 := &x.NodeName + yym68 := z.DecBinary() + _ = yym68 if false { } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) + *((*string)(yyv67)) = r.DecodeString() } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DNSPolicy = "" + x.HostNetwork = false } else { - x.DNSPolicy = DNSPolicy(r.DecodeString()) + yyv69 := &x.HostNetwork + yym70 := z.DecBinary() + _ = yym70 + if false { + } else { + *((*bool)(yyv69)) = r.DecodeBool() + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.NodeSelector = nil + x.HostPID = false } else { - yyv2110 := &x.NodeSelector - yym2111 := z.DecBinary() - _ = yym2111 + yyv71 := &x.HostPID + yym72 := z.DecBinary() + _ = yym72 if false { } else { - z.F.DecMapStringStringX(yyv2110, false, d) + *((*bool)(yyv71)) = r.DecodeBool() } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ServiceAccountName = "" + x.HostIPC = false } else { - x.ServiceAccountName = string(r.DecodeString()) + yyv73 := &x.HostIPC + yym74 := z.DecBinary() + _ = yym74 + if false { + } else { + *((*bool)(yyv73)) = r.DecodeBool() + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DeprecatedServiceAccount = "" + if x.SecurityContext != nil { + x.SecurityContext = nil + } } else { - x.DeprecatedServiceAccount = string(r.DecodeString()) + if x.SecurityContext == nil { + x.SecurityContext = new(PodSecurityContext) + } + x.SecurityContext.CodecDecodeSelf(d) } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.NodeName = "" + x.ImagePullSecrets = nil } else { - x.NodeName = string(r.DecodeString()) + yyv76 := &x.ImagePullSecrets + yym77 := z.DecBinary() + _ = yym77 + if false { + } else { + h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv76), d) + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.HostNetwork = false + x.Hostname = "" } else { - x.HostNetwork = bool(r.DecodeBool()) + yyv78 := &x.Hostname + yym79 := z.DecBinary() + _ = yym79 + if false { + } else { + *((*string)(yyv78)) = r.DecodeString() + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.HostPID = false + x.Subdomain = "" } else { - x.HostPID = bool(r.DecodeBool()) + yyv80 := &x.Subdomain + yym81 := z.DecBinary() + _ = yym81 + if false { + } else { + *((*string)(yyv80)) = r.DecodeString() + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.HostIPC = false + if x.Affinity != nil { + x.Affinity = nil + } } else { - x.HostIPC = bool(r.DecodeBool()) + if x.Affinity == nil { + x.Affinity = new(Affinity) + } + x.Affinity.CodecDecodeSelf(d) } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.SecurityContext != nil { - x.SecurityContext = nil + x.SchedulerName = "" + } else { + yyv83 := &x.SchedulerName + yym84 := z.DecBinary() + _ = yym84 + if false { + } else { + *((*string)(yyv83)) = r.DecodeString() } + } + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - if x.SecurityContext == nil { - x.SecurityContext = new(PodSecurityContext) + yyb46 = r.CheckBreak() + } + if yyb46 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Tolerations = nil + } else { + yyv85 := &x.Tolerations + yym86 := z.DecBinary() + _ = yym86 + if false { + } else { + h.decSliceToleration((*[]Toleration)(yyv85), d) } - x.SecurityContext.CodecDecodeSelf(d) } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l } else { - yyb2099 = r.CheckBreak() + yyb46 = r.CheckBreak() } - if yyb2099 { + if yyb46 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ImagePullSecrets = nil + x.HostAliases = nil + } else { + yyv87 := &x.HostAliases + yym88 := z.DecBinary() + _ = yym88 + if false { + } else { + h.decSliceHostAlias((*[]HostAlias)(yyv87), d) + } + } + for { + yyj46++ + if yyhl46 { + yyb46 = yyj46 > l + } else { + yyb46 = r.CheckBreak() + } + if yyb46 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj46-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *HostAlias) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() } else { - yyv2119 := &x.ImagePullSecrets - yym2120 := z.DecBinary() - _ = yym2120 + yym1 := z.EncBinary() + _ = yym1 if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.IP != "" + yyq2[1] = len(x.Hostnames) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.IP)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ip")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.IP)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Hostnames == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.Hostnames, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("hostnames")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Hostnames == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.Hostnames, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HostAlias) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2119), d) + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l +} + +func (x *HostAlias) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "ip": + if r.TryDecodeAsNil() { + x.IP = "" + } else { + yyv4 := &x.IP + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "hostnames": + if r.TryDecodeAsNil() { + x.Hostnames = nil + } else { + yyv6 := &x.Hostnames + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HostAlias) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb2099 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb2099 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Hostname = "" + x.IP = "" } else { - x.Hostname = string(r.DecodeString()) + yyv9 := &x.IP + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb2099 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb2099 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Subdomain = "" + x.Hostnames = nil } else { - x.Subdomain = string(r.DecodeString()) + yyv11 := &x.Hostnames + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + z.F.DecSliceStringX(yyv11, false, d) + } } for { - yyj2099++ - if yyhl2099 { - yyb2099 = yyj2099 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb2099 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb2099 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2099-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -28569,37 +37558,37 @@ func (x *PodSecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2123 := z.EncBinary() - _ = yym2123 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2124 := !z.EncBinary() - yy2arr2124 := z.EncBasicHandle().StructToArray - var yyq2124 [5]bool - _, _, _ = yysep2124, yyq2124, yy2arr2124 - const yyr2124 bool = false - yyq2124[0] = x.SELinuxOptions != nil - yyq2124[1] = x.RunAsUser != nil - yyq2124[2] = x.RunAsNonRoot != nil - yyq2124[3] = len(x.SupplementalGroups) != 0 - yyq2124[4] = x.FSGroup != nil - var yynn2124 int - if yyr2124 || yy2arr2124 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.SELinuxOptions != nil + yyq2[1] = x.RunAsUser != nil + yyq2[2] = x.RunAsNonRoot != nil + yyq2[3] = len(x.SupplementalGroups) != 0 + yyq2[4] = x.FSGroup != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn2124 = 0 - for _, b := range yyq2124 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2124++ + yynn2++ } } - r.EncodeMapStart(yynn2124) - yynn2124 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2124 || yy2arr2124 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2124[0] { + if yyq2[0] { if x.SELinuxOptions == nil { r.EncodeNil() } else { @@ -28609,7 +37598,7 @@ func (x *PodSecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2124[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("seLinuxOptions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -28620,84 +37609,84 @@ func (x *PodSecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2124 || yy2arr2124 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2124[1] { + if yyq2[1] { if x.RunAsUser == nil { r.EncodeNil() } else { - yy2127 := *x.RunAsUser - yym2128 := z.EncBinary() - _ = yym2128 + yy7 := *x.RunAsUser + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeInt(int64(yy2127)) + r.EncodeInt(int64(yy7)) } } } else { r.EncodeNil() } } else { - if yyq2124[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RunAsUser == nil { r.EncodeNil() } else { - yy2129 := *x.RunAsUser - yym2130 := z.EncBinary() - _ = yym2130 + yy9 := *x.RunAsUser + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeInt(int64(yy2129)) + r.EncodeInt(int64(yy9)) } } } } - if yyr2124 || yy2arr2124 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2124[2] { + if yyq2[2] { if x.RunAsNonRoot == nil { r.EncodeNil() } else { - yy2132 := *x.RunAsNonRoot - yym2133 := z.EncBinary() - _ = yym2133 + yy12 := *x.RunAsNonRoot + yym13 := z.EncBinary() + _ = yym13 if false { } else { - r.EncodeBool(bool(yy2132)) + r.EncodeBool(bool(yy12)) } } } else { r.EncodeNil() } } else { - if yyq2124[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RunAsNonRoot == nil { r.EncodeNil() } else { - yy2134 := *x.RunAsNonRoot - yym2135 := z.EncBinary() - _ = yym2135 + yy14 := *x.RunAsNonRoot + yym15 := z.EncBinary() + _ = yym15 if false { } else { - r.EncodeBool(bool(yy2134)) + r.EncodeBool(bool(yy14)) } } } } - if yyr2124 || yy2arr2124 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2124[3] { + if yyq2[3] { if x.SupplementalGroups == nil { r.EncodeNil() } else { - yym2137 := z.EncBinary() - _ = yym2137 + yym17 := z.EncBinary() + _ = yym17 if false { } else { z.F.EncSliceInt64V(x.SupplementalGroups, false, e) @@ -28707,15 +37696,15 @@ func (x *PodSecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2124[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("supplementalGroups")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.SupplementalGroups == nil { r.EncodeNil() } else { - yym2138 := z.EncBinary() - _ = yym2138 + yym18 := z.EncBinary() + _ = yym18 if false { } else { z.F.EncSliceInt64V(x.SupplementalGroups, false, e) @@ -28723,42 +37712,42 @@ func (x *PodSecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2124 || yy2arr2124 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2124[4] { + if yyq2[4] { if x.FSGroup == nil { r.EncodeNil() } else { - yy2140 := *x.FSGroup - yym2141 := z.EncBinary() - _ = yym2141 + yy20 := *x.FSGroup + yym21 := z.EncBinary() + _ = yym21 if false { } else { - r.EncodeInt(int64(yy2140)) + r.EncodeInt(int64(yy20)) } } } else { r.EncodeNil() } } else { - if yyq2124[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsGroup")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.FSGroup == nil { r.EncodeNil() } else { - yy2142 := *x.FSGroup - yym2143 := z.EncBinary() - _ = yym2143 + yy22 := *x.FSGroup + yym23 := z.EncBinary() + _ = yym23 if false { } else { - r.EncodeInt(int64(yy2142)) + r.EncodeInt(int64(yy22)) } } } } - if yyr2124 || yy2arr2124 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -28771,25 +37760,25 @@ func (x *PodSecurityContext) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2144 := z.DecBinary() - _ = yym2144 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2145 := r.ContainerType() - if yyct2145 == codecSelferValueTypeMap1234 { - yyl2145 := r.ReadMapStart() - if yyl2145 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2145, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2145 == codecSelferValueTypeArray1234 { - yyl2145 := r.ReadArrayStart() - if yyl2145 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2145, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -28801,12 +37790,12 @@ func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2146Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2146Slc - var yyhl2146 bool = l >= 0 - for yyj2146 := 0; ; yyj2146++ { - if yyhl2146 { - if yyj2146 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -28815,10 +37804,10 @@ func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2146Slc = r.DecodeBytes(yys2146Slc, true, true) - yys2146 := string(yys2146Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2146 { + switch yys3 { case "seLinuxOptions": if r.TryDecodeAsNil() { if x.SELinuxOptions != nil { @@ -28839,8 +37828,8 @@ func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if x.RunAsUser == nil { x.RunAsUser = new(int64) } - yym2149 := z.DecBinary() - _ = yym2149 + yym6 := z.DecBinary() + _ = yym6 if false { } else { *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) @@ -28855,8 +37844,8 @@ func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if x.RunAsNonRoot == nil { x.RunAsNonRoot = new(bool) } - yym2151 := z.DecBinary() - _ = yym2151 + yym8 := z.DecBinary() + _ = yym8 if false { } else { *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() @@ -28866,12 +37855,12 @@ func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.SupplementalGroups = nil } else { - yyv2152 := &x.SupplementalGroups - yym2153 := z.DecBinary() - _ = yym2153 + yyv9 := &x.SupplementalGroups + yym10 := z.DecBinary() + _ = yym10 if false { } else { - z.F.DecSliceInt64X(yyv2152, false, d) + z.F.DecSliceInt64X(yyv9, false, d) } } case "fsGroup": @@ -28883,17 +37872,17 @@ func (x *PodSecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if x.FSGroup == nil { x.FSGroup = new(int64) } - yym2155 := z.DecBinary() - _ = yym2155 + yym12 := z.DecBinary() + _ = yym12 if false { } else { *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64)) } } default: - z.DecStructFieldNotFound(-1, yys2146) - } // end switch yys2146 - } // end for yyj2146 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -28901,16 +37890,16 @@ func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2156 int - var yyb2156 bool - var yyhl2156 bool = l >= 0 - yyj2156++ - if yyhl2156 { - yyb2156 = yyj2156 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2156 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2156 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -28925,13 +37914,13 @@ func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decode } x.SELinuxOptions.CodecDecodeSelf(d) } - yyj2156++ - if yyhl2156 { - yyb2156 = yyj2156 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2156 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2156 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -28944,20 +37933,20 @@ func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decode if x.RunAsUser == nil { x.RunAsUser = new(int64) } - yym2159 := z.DecBinary() - _ = yym2159 + yym16 := z.DecBinary() + _ = yym16 if false { } else { *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) } } - yyj2156++ - if yyhl2156 { - yyb2156 = yyj2156 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2156 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2156 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -28970,20 +37959,20 @@ func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decode if x.RunAsNonRoot == nil { x.RunAsNonRoot = new(bool) } - yym2161 := z.DecBinary() - _ = yym2161 + yym18 := z.DecBinary() + _ = yym18 if false { } else { *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() } } - yyj2156++ - if yyhl2156 { - yyb2156 = yyj2156 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2156 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2156 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -28991,21 +37980,21 @@ func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.SupplementalGroups = nil } else { - yyv2162 := &x.SupplementalGroups - yym2163 := z.DecBinary() - _ = yym2163 + yyv19 := &x.SupplementalGroups + yym20 := z.DecBinary() + _ = yym20 if false { } else { - z.F.DecSliceInt64X(yyv2162, false, d) + z.F.DecSliceInt64X(yyv19, false, d) } } - yyj2156++ - if yyhl2156 { - yyb2156 = yyj2156 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2156 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2156 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29018,29 +38007,55 @@ func (x *PodSecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decode if x.FSGroup == nil { x.FSGroup = new(int64) } - yym2165 := z.DecBinary() - _ = yym2165 + yym22 := z.DecBinary() + _ = yym22 if false { } else { *((*int64)(x.FSGroup)) = int64(r.DecodeInt(64)) } } for { - yyj2156++ - if yyhl2156 { - yyb2156 = yyj2156 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2156 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2156 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2156-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } +func (x PodQOSClass) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *PodQOSClass) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) @@ -29048,60 +38063,62 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2166 := z.EncBinary() - _ = yym2166 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2167 := !z.EncBinary() - yy2arr2167 := z.EncBasicHandle().StructToArray - var yyq2167 [8]bool - _, _, _ = yysep2167, yyq2167, yy2arr2167 - const yyr2167 bool = false - yyq2167[0] = x.Phase != "" - yyq2167[1] = len(x.Conditions) != 0 - yyq2167[2] = x.Message != "" - yyq2167[3] = x.Reason != "" - yyq2167[4] = x.HostIP != "" - yyq2167[5] = x.PodIP != "" - yyq2167[6] = x.StartTime != nil - yyq2167[7] = len(x.ContainerStatuses) != 0 - var yynn2167 int - if yyr2167 || yy2arr2167 { - r.EncodeArrayStart(8) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Phase != "" + yyq2[1] = len(x.Conditions) != 0 + yyq2[2] = x.Message != "" + yyq2[3] = x.Reason != "" + yyq2[4] = x.HostIP != "" + yyq2[5] = x.PodIP != "" + yyq2[6] = x.StartTime != nil + yyq2[7] = len(x.InitContainerStatuses) != 0 + yyq2[8] = len(x.ContainerStatuses) != 0 + yyq2[9] = x.QOSClass != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(10) } else { - yynn2167 = 0 - for _, b := range yyq2167 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2167++ + yynn2++ } } - r.EncodeMapStart(yynn2167) - yynn2167 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[0] { + if yyq2[0] { x.Phase.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2167[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("phase")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Phase.CodecEncodeSelf(e) } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[1] { + if yyq2[1] { if x.Conditions == nil { r.EncodeNil() } else { - yym2170 := z.EncBinary() - _ = yym2170 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSlicePodCondition(([]PodCondition)(x.Conditions), e) @@ -29111,15 +38128,15 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2167[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Conditions == nil { r.EncodeNil() } else { - yym2171 := z.EncBinary() - _ = yym2171 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSlicePodCondition(([]PodCondition)(x.Conditions), e) @@ -29127,11 +38144,11 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[2] { - yym2173 := z.EncBinary() - _ = yym2173 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -29140,23 +38157,23 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2167[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2174 := z.EncBinary() - _ = yym2174 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[3] { - yym2176 := z.EncBinary() - _ = yym2176 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -29165,23 +38182,23 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2167[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2177 := z.EncBinary() - _ = yym2177 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[4] { - yym2179 := z.EncBinary() - _ = yym2179 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) @@ -29190,23 +38207,23 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2167[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostIP")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2180 := z.EncBinary() - _ = yym2180 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.HostIP)) } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[5] { - yym2182 := z.EncBinary() - _ = yym2182 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.PodIP)) @@ -29215,31 +38232,31 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2167[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podIP")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2183 := z.EncBinary() - _ = yym2183 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.PodIP)) } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[6] { + if yyq2[6] { if x.StartTime == nil { r.EncodeNil() } else { - yym2185 := z.EncBinary() - _ = yym2185 + yym22 := z.EncBinary() + _ = yym22 if false { } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym2185 { + } else if yym22 { z.EncBinaryMarshal(x.StartTime) - } else if !yym2185 && z.IsJSONHandle() { + } else if !yym22 && z.IsJSONHandle() { z.EncJSONMarshal(x.StartTime) } else { z.EncFallback(x.StartTime) @@ -29249,20 +38266,20 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2167[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("startTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.StartTime == nil { r.EncodeNil() } else { - yym2186 := z.EncBinary() - _ = yym2186 + yym23 := z.EncBinary() + _ = yym23 if false { } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym2186 { + } else if yym23 { z.EncBinaryMarshal(x.StartTime) - } else if !yym2186 && z.IsJSONHandle() { + } else if !yym23 && z.IsJSONHandle() { z.EncJSONMarshal(x.StartTime) } else { z.EncFallback(x.StartTime) @@ -29270,14 +38287,47 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + if x.InitContainerStatuses == nil { + r.EncodeNil() + } else { + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + h.encSliceContainerStatus(([]ContainerStatus)(x.InitContainerStatuses), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("initContainerStatuses")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.InitContainerStatuses == nil { + r.EncodeNil() + } else { + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + h.encSliceContainerStatus(([]ContainerStatus)(x.InitContainerStatuses), e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2167[7] { + if yyq2[8] { if x.ContainerStatuses == nil { r.EncodeNil() } else { - yym2188 := z.EncBinary() - _ = yym2188 + yym28 := z.EncBinary() + _ = yym28 if false { } else { h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e) @@ -29287,15 +38337,15 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2167[7] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("containerStatuses")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ContainerStatuses == nil { r.EncodeNil() } else { - yym2189 := z.EncBinary() - _ = yym2189 + yym29 := z.EncBinary() + _ = yym29 if false { } else { h.encSliceContainerStatus(([]ContainerStatus)(x.ContainerStatuses), e) @@ -29303,7 +38353,22 @@ func (x *PodStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2167 || yy2arr2167 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[9] { + x.QOSClass.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[9] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("qosClass")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.QOSClass.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -29316,25 +38381,25 @@ func (x *PodStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2190 := z.DecBinary() - _ = yym2190 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2191 := r.ContainerType() - if yyct2191 == codecSelferValueTypeMap1234 { - yyl2191 := r.ReadMapStart() - if yyl2191 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2191, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2191 == codecSelferValueTypeArray1234 { - yyl2191 := r.ReadArrayStart() - if yyl2191 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2191, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -29346,12 +38411,12 @@ func (x *PodStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2192Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2192Slc - var yyhl2192 bool = l >= 0 - for yyj2192 := 0; ; yyj2192++ { - if yyhl2192 { - if yyj2192 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -29360,51 +38425,76 @@ func (x *PodStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2192Slc = r.DecodeBytes(yys2192Slc, true, true) - yys2192 := string(yys2192Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2192 { + switch yys3 { case "phase": if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = PodPhase(r.DecodeString()) + yyv4 := &x.Phase + yyv4.CodecDecodeSelf(d) } case "conditions": if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv2194 := &x.Conditions - yym2195 := z.DecBinary() - _ = yym2195 + yyv5 := &x.Conditions + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSlicePodCondition((*[]PodCondition)(yyv2194), d) + h.decSlicePodCondition((*[]PodCondition)(yyv5), d) } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv7 := &x.Message + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv9 := &x.Reason + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } case "hostIP": if r.TryDecodeAsNil() { x.HostIP = "" } else { - x.HostIP = string(r.DecodeString()) + yyv11 := &x.HostIP + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } case "podIP": if r.TryDecodeAsNil() { x.PodIP = "" } else { - x.PodIP = string(r.DecodeString()) + yyv13 := &x.PodIP + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } case "startTime": if r.TryDecodeAsNil() { @@ -29413,36 +38503,55 @@ func (x *PodStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.StartTime == nil { - x.StartTime = new(pkg2_unversioned.Time) + x.StartTime = new(pkg2_v1.Time) } - yym2201 := z.DecBinary() - _ = yym2201 + yym16 := z.DecBinary() + _ = yym16 if false { } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym2201 { + } else if yym16 { z.DecBinaryUnmarshal(x.StartTime) - } else if !yym2201 && z.IsJSONHandle() { + } else if !yym16 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.StartTime) } else { z.DecFallback(x.StartTime, false) } } + case "initContainerStatuses": + if r.TryDecodeAsNil() { + x.InitContainerStatuses = nil + } else { + yyv17 := &x.InitContainerStatuses + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + h.decSliceContainerStatus((*[]ContainerStatus)(yyv17), d) + } + } case "containerStatuses": if r.TryDecodeAsNil() { x.ContainerStatuses = nil } else { - yyv2202 := &x.ContainerStatuses - yym2203 := z.DecBinary() - _ = yym2203 + yyv19 := &x.ContainerStatuses + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceContainerStatus((*[]ContainerStatus)(yyv2202), d) + h.decSliceContainerStatus((*[]ContainerStatus)(yyv19), d) } } + case "qosClass": + if r.TryDecodeAsNil() { + x.QOSClass = "" + } else { + yyv21 := &x.QOSClass + yyv21.CodecDecodeSelf(d) + } default: - z.DecStructFieldNotFound(-1, yys2192) - } // end switch yys2192 - } // end for yyj2192 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -29450,16 +38559,16 @@ func (x *PodStatus) 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 + var yyj22 int + var yyb22 bool + var yyhl22 bool = l >= 0 + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29467,15 +38576,16 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = PodPhase(r.DecodeString()) + yyv23 := &x.Phase + yyv23.CodecDecodeSelf(d) } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29483,21 +38593,21 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv2206 := &x.Conditions - yym2207 := z.DecBinary() - _ = yym2207 + yyv24 := &x.Conditions + yym25 := z.DecBinary() + _ = yym25 if false { } else { - h.decSlicePodCondition((*[]PodCondition)(yyv2206), d) + h.decSlicePodCondition((*[]PodCondition)(yyv24), d) } } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29505,15 +38615,21 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv26 := &x.Message + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*string)(yyv26)) = r.DecodeString() + } } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29521,15 +38637,21 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv28 := &x.Reason + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29537,15 +38659,21 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.HostIP = "" } else { - x.HostIP = string(r.DecodeString()) + yyv30 := &x.HostIP + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*string)(yyv30)) = r.DecodeString() + } } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29553,15 +38681,21 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PodIP = "" } else { - x.PodIP = string(r.DecodeString()) + yyv32 := &x.PodIP + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*string)(yyv32)) = r.DecodeString() + } } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29572,27 +38706,49 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.StartTime == nil { - x.StartTime = new(pkg2_unversioned.Time) + x.StartTime = new(pkg2_v1.Time) } - yym2213 := z.DecBinary() - _ = yym2213 + yym35 := z.DecBinary() + _ = yym35 if false { } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym2213 { + } else if yym35 { z.DecBinaryUnmarshal(x.StartTime) - } else if !yym2213 && z.IsJSONHandle() { + } else if !yym35 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.StartTime) } else { z.DecFallback(x.StartTime, false) } } - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.InitContainerStatuses = nil + } else { + yyv36 := &x.InitContainerStatuses + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + h.decSliceContainerStatus((*[]ContainerStatus)(yyv36), d) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29600,26 +38756,43 @@ func (x *PodStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ContainerStatuses = nil } else { - yyv2214 := &x.ContainerStatuses - yym2215 := z.DecBinary() - _ = yym2215 + yyv38 := &x.ContainerStatuses + yym39 := z.DecBinary() + _ = yym39 if false { } else { - h.decSliceContainerStatus((*[]ContainerStatus)(yyv2214), d) + h.decSliceContainerStatus((*[]ContainerStatus)(yyv38), d) } } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.QOSClass = "" + } else { + yyv40 := &x.QOSClass + yyv40.CodecDecodeSelf(d) + } for { - yyj2204++ - if yyhl2204 { - yyb2204 = yyj2204 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb2204 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb2204 { + if yyb22 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2204-1, "") + z.DecStructFieldNotFound(yyj22-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -29631,38 +38804,38 @@ func (x *PodStatusResult) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2216 := z.EncBinary() - _ = yym2216 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2217 := !z.EncBinary() - yy2arr2217 := z.EncBasicHandle().StructToArray - var yyq2217 [4]bool - _, _, _ = yysep2217, yyq2217, yy2arr2217 - const yyr2217 bool = false - yyq2217[0] = x.Kind != "" - yyq2217[1] = x.APIVersion != "" - yyq2217[2] = true - yyq2217[3] = true - var yynn2217 int - if yyr2217 || yy2arr2217 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2217 = 0 - for _, b := range yyq2217 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2217++ + yynn2++ } } - r.EncodeMapStart(yynn2217) - yynn2217 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2217 || yy2arr2217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2217[0] { - yym2219 := z.EncBinary() - _ = yym2219 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -29671,23 +38844,23 @@ func (x *PodStatusResult) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2217[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2220 := z.EncBinary() - _ = yym2220 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2217 || yy2arr2217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2217[1] { - yym2222 := z.EncBinary() - _ = yym2222 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -29696,53 +38869,65 @@ func (x *PodStatusResult) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2217[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2223 := z.EncBinary() - _ = yym2223 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2217 || yy2arr2217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2217[2] { - yy2225 := &x.ObjectMeta - yy2225.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2217[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2226 := &x.ObjectMeta - yy2226.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2217 || yy2arr2217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2217[3] { - yy2228 := &x.Status - yy2228.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Status + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2217[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2229 := &x.Status - yy2229.CodecEncodeSelf(e) + yy17 := &x.Status + yy17.CodecEncodeSelf(e) } } - if yyr2217 || yy2arr2217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -29755,25 +38940,25 @@ func (x *PodStatusResult) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2230 := z.DecBinary() - _ = yym2230 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2231 := r.ContainerType() - if yyct2231 == codecSelferValueTypeMap1234 { - yyl2231 := r.ReadMapStart() - if yyl2231 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2231, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2231 == codecSelferValueTypeArray1234 { - yyl2231 := r.ReadArrayStart() - if yyl2231 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2231, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -29785,12 +38970,12 @@ func (x *PodStatusResult) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2232Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2232Slc - var yyhl2232 bool = l >= 0 - for yyj2232 := 0; ; yyj2232++ { - if yyhl2232 { - if yyj2232 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -29799,40 +38984,58 @@ func (x *PodStatusResult) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2232Slc = r.DecodeBytes(yys2232Slc, true, true) - yys2232 := string(yys2232Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2232 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2235 := &x.ObjectMeta - yyv2235.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "status": if r.TryDecodeAsNil() { x.Status = PodStatus{} } else { - yyv2236 := &x.Status - yyv2236.CodecDecodeSelf(d) + yyv10 := &x.Status + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2232) - } // end switch yys2232 - } // end for yyj2232 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -29840,16 +39043,16 @@ func (x *PodStatusResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2237 int - var yyb2237 bool - var yyhl2237 bool = l >= 0 - yyj2237++ - if yyhl2237 { - yyb2237 = yyj2237 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2237 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2237 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29857,15 +39060,21 @@ func (x *PodStatusResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj2237++ - if yyhl2237 { - yyb2237 = yyj2237 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2237 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2237 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29873,32 +39082,44 @@ func (x *PodStatusResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj2237++ - if yyhl2237 { - yyb2237 = yyj2237 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2237 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2237 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2240 := &x.ObjectMeta - yyv2240.CodecDecodeSelf(d) + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } } - yyj2237++ - if yyhl2237 { - yyb2237 = yyj2237 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2237 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2237 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -29906,21 +39127,21 @@ func (x *PodStatusResult) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Status = PodStatus{} } else { - yyv2241 := &x.Status - yyv2241.CodecDecodeSelf(d) + yyv18 := &x.Status + yyv18.CodecDecodeSelf(d) } for { - yyj2237++ - if yyhl2237 { - yyb2237 = yyj2237 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2237 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2237 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2237-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -29932,39 +39153,39 @@ func (x *Pod) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2242 := z.EncBinary() - _ = yym2242 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2243 := !z.EncBinary() - yy2arr2243 := z.EncBasicHandle().StructToArray - var yyq2243 [5]bool - _, _, _ = yysep2243, yyq2243, yy2arr2243 - const yyr2243 bool = false - yyq2243[0] = x.Kind != "" - yyq2243[1] = x.APIVersion != "" - yyq2243[2] = true - yyq2243[3] = true - yyq2243[4] = true - var yynn2243 int - if yyr2243 || yy2arr2243 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn2243 = 0 - for _, b := range yyq2243 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2243++ + yynn2++ } } - r.EncodeMapStart(yynn2243) - yynn2243 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2243 || yy2arr2243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2243[0] { - yym2245 := z.EncBinary() - _ = yym2245 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -29973,23 +39194,23 @@ func (x *Pod) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2243[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2246 := z.EncBinary() - _ = yym2246 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2243 || yy2arr2243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2243[1] { - yym2248 := z.EncBinary() - _ = yym2248 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -29998,70 +39219,82 @@ func (x *Pod) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2243[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2249 := z.EncBinary() - _ = yym2249 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2243 || yy2arr2243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2243[2] { - yy2251 := &x.ObjectMeta - yy2251.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2243[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2252 := &x.ObjectMeta - yy2252.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2243 || yy2arr2243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2243[3] { - yy2254 := &x.Spec - yy2254.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2243[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2255 := &x.Spec - yy2255.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr2243 || yy2arr2243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2243[4] { - yy2257 := &x.Status - yy2257.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2243[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2258 := &x.Status - yy2258.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr2243 || yy2arr2243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -30074,25 +39307,25 @@ func (x *Pod) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2259 := z.DecBinary() - _ = yym2259 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2260 := r.ContainerType() - if yyct2260 == codecSelferValueTypeMap1234 { - yyl2260 := r.ReadMapStart() - if yyl2260 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2260, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2260 == codecSelferValueTypeArray1234 { - yyl2260 := r.ReadArrayStart() - if yyl2260 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2260, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -30104,12 +39337,12 @@ func (x *Pod) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2261Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2261Slc - var yyhl2261 bool = l >= 0 - for yyj2261 := 0; ; yyj2261++ { - if yyhl2261 { - if yyj2261 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -30118,47 +39351,65 @@ func (x *Pod) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2261Slc = r.DecodeBytes(yys2261Slc, true, true) - yys2261 := string(yys2261Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2261 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2264 := &x.ObjectMeta - yyv2264.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = PodSpec{} } else { - yyv2265 := &x.Spec - yyv2265.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = PodStatus{} } else { - yyv2266 := &x.Status - yyv2266.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2261) - } // end switch yys2261 - } // end for yyj2261 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -30166,16 +39417,16 @@ func (x *Pod) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2267 int - var yyb2267 bool - var yyhl2267 bool = l >= 0 - yyj2267++ - if yyhl2267 { - yyb2267 = yyj2267 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2267 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2267 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30183,15 +39434,21 @@ func (x *Pod) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2267++ - if yyhl2267 { - yyb2267 = yyj2267 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2267 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2267 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30199,32 +39456,44 @@ func (x *Pod) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2267++ - if yyhl2267 { - yyb2267 = yyj2267 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2267 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2267 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2270 := &x.ObjectMeta - yyv2270.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj2267++ - if yyhl2267 { - yyb2267 = yyj2267 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2267 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2267 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30232,16 +39501,16 @@ func (x *Pod) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = PodSpec{} } else { - yyv2271 := &x.Spec - yyv2271.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj2267++ - if yyhl2267 { - yyb2267 = yyj2267 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2267 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2267 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30249,21 +39518,21 @@ func (x *Pod) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = PodStatus{} } else { - yyv2272 := &x.Status - yyv2272.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj2267++ - if yyhl2267 { - yyb2267 = yyj2267 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2267 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2267 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2267-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -30275,37 +39544,37 @@ func (x *PodList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2273 := z.EncBinary() - _ = yym2273 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2274 := !z.EncBinary() - yy2arr2274 := z.EncBasicHandle().StructToArray - var yyq2274 [4]bool - _, _, _ = yysep2274, yyq2274, yy2arr2274 - const yyr2274 bool = false - yyq2274[0] = x.Kind != "" - yyq2274[1] = x.APIVersion != "" - yyq2274[2] = true - var yynn2274 int - if yyr2274 || yy2arr2274 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2274 = 1 - for _, b := range yyq2274 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2274++ + yynn2++ } } - r.EncodeMapStart(yynn2274) - yynn2274 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2274 || yy2arr2274 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2274[0] { - yym2276 := z.EncBinary() - _ = yym2276 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -30314,23 +39583,23 @@ func (x *PodList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2274[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2277 := z.EncBinary() - _ = yym2277 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2274 || yy2arr2274 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2274[1] { - yym2279 := z.EncBinary() - _ = yym2279 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -30339,54 +39608,54 @@ func (x *PodList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2274[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2280 := z.EncBinary() - _ = yym2280 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2274 || yy2arr2274 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2274[2] { - yy2282 := &x.ListMeta - yym2283 := z.EncBinary() - _ = yym2283 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2282) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy2282) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2274[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2284 := &x.ListMeta - yym2285 := z.EncBinary() - _ = yym2285 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2284) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy2284) + z.EncFallback(yy12) } } } - if yyr2274 || yy2arr2274 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym2287 := z.EncBinary() - _ = yym2287 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePod(([]Pod)(x.Items), e) @@ -30399,15 +39668,15 @@ func (x *PodList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym2288 := z.EncBinary() - _ = yym2288 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePod(([]Pod)(x.Items), e) } } } - if yyr2274 || yy2arr2274 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -30420,25 +39689,25 @@ func (x *PodList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2289 := z.DecBinary() - _ = yym2289 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2290 := r.ContainerType() - if yyct2290 == codecSelferValueTypeMap1234 { - yyl2290 := r.ReadMapStart() - if yyl2290 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2290, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2290 == codecSelferValueTypeArray1234 { - yyl2290 := r.ReadArrayStart() - if yyl2290 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2290, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -30450,12 +39719,12 @@ func (x *PodList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2291Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2291Slc - var yyhl2291 bool = l >= 0 - for yyj2291 := 0; ; yyj2291++ { - if yyhl2291 { - if yyj2291 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -30464,51 +39733,63 @@ func (x *PodList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2291Slc = r.DecodeBytes(yys2291Slc, true, true) - yys2291 := string(yys2291Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2291 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2294 := &x.ListMeta - yym2295 := z.DecBinary() - _ = yym2295 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv2294) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv2294, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2296 := &x.Items - yym2297 := z.DecBinary() - _ = yym2297 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePod((*[]Pod)(yyv2296), d) + h.decSlicePod((*[]Pod)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2291) - } // end switch yys2291 - } // end for yyj2291 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -30516,16 +39797,16 @@ func (x *PodList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2298 int - var yyb2298 bool - var yyhl2298 bool = l >= 0 - yyj2298++ - if yyhl2298 { - yyb2298 = yyj2298 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2298 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2298 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30533,15 +39814,21 @@ func (x *PodList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2298++ - if yyhl2298 { - yyb2298 = yyj2298 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2298 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2298 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30549,38 +39836,44 @@ func (x *PodList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2298++ - if yyhl2298 { - yyb2298 = yyj2298 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2298 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2298 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2301 := &x.ListMeta - yym2302 := z.DecBinary() - _ = yym2302 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv2301) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv2301, false) + z.DecFallback(yyv17, false) } } - yyj2298++ - if yyhl2298 { - yyb2298 = yyj2298 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2298 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2298 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30588,26 +39881,26 @@ func (x *PodList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2303 := &x.Items - yym2304 := z.DecBinary() - _ = yym2304 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePod((*[]Pod)(yyv2303), d) + h.decSlicePod((*[]Pod)(yyv19), d) } } for { - yyj2298++ - if yyhl2298 { - yyb2298 = yyj2298 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2298 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2298 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2298-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -30619,66 +39912,78 @@ func (x *PodTemplateSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2305 := z.EncBinary() - _ = yym2305 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2306 := !z.EncBinary() - yy2arr2306 := z.EncBasicHandle().StructToArray - var yyq2306 [2]bool - _, _, _ = yysep2306, yyq2306, yy2arr2306 - const yyr2306 bool = false - yyq2306[0] = true - yyq2306[1] = true - var yynn2306 int - if yyr2306 || yy2arr2306 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = true + yyq2[1] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn2306 = 0 - for _, b := range yyq2306 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2306++ + yynn2++ } } - r.EncodeMapStart(yynn2306) - yynn2306 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2306 || yy2arr2306 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2306[0] { - yy2308 := &x.ObjectMeta - yy2308.CodecEncodeSelf(e) + if yyq2[0] { + yy4 := &x.ObjectMeta + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(yy4) { + } else { + z.EncFallback(yy4) + } } else { r.EncodeNil() } } else { - if yyq2306[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2309 := &x.ObjectMeta - yy2309.CodecEncodeSelf(e) + yy6 := &x.ObjectMeta + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(yy6) { + } else { + z.EncFallback(yy6) + } } } - if yyr2306 || yy2arr2306 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2306[1] { - yy2311 := &x.Spec - yy2311.CodecEncodeSelf(e) + if yyq2[1] { + yy9 := &x.Spec + yy9.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2306[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2312 := &x.Spec - yy2312.CodecEncodeSelf(e) + yy11 := &x.Spec + yy11.CodecEncodeSelf(e) } } - if yyr2306 || yy2arr2306 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -30691,25 +39996,25 @@ func (x *PodTemplateSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2313 := z.DecBinary() - _ = yym2313 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2314 := r.ContainerType() - if yyct2314 == codecSelferValueTypeMap1234 { - yyl2314 := r.ReadMapStart() - if yyl2314 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2314, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2314 == codecSelferValueTypeArray1234 { - yyl2314 := r.ReadArrayStart() - if yyl2314 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2314, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -30721,12 +40026,12 @@ func (x *PodTemplateSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2315Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2315Slc - var yyhl2315 bool = l >= 0 - for yyj2315 := 0; ; yyj2315++ { - if yyhl2315 { - if yyj2315 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -30735,28 +40040,34 @@ func (x *PodTemplateSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2315Slc = r.DecodeBytes(yys2315Slc, true, true) - yys2315 := string(yys2315Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2315 { + switch yys3 { case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2316 := &x.ObjectMeta - yyv2316.CodecDecodeSelf(d) + yyv4 := &x.ObjectMeta + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + z.DecFallback(yyv4, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = PodSpec{} } else { - yyv2317 := &x.Spec - yyv2317.CodecDecodeSelf(d) + yyv6 := &x.Spec + yyv6.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2315) - } // end switch yys2315 - } // end for yyj2315 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -30764,33 +40075,39 @@ func (x *PodTemplateSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2318 int - var yyb2318 bool - var yyhl2318 bool = l >= 0 - yyj2318++ - if yyhl2318 { - yyb2318 = yyj2318 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb2318 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb2318 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2319 := &x.ObjectMeta - yyv2319.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } - yyj2318++ - if yyhl2318 { - yyb2318 = yyj2318 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb2318 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb2318 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -30798,21 +40115,21 @@ func (x *PodTemplateSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Spec = PodSpec{} } else { - yyv2320 := &x.Spec - yyv2320.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } for { - yyj2318++ - if yyhl2318 { - yyb2318 = yyj2318 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb2318 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb2318 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2318-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -30824,38 +40141,38 @@ func (x *PodTemplate) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2321 := z.EncBinary() - _ = yym2321 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2322 := !z.EncBinary() - yy2arr2322 := z.EncBasicHandle().StructToArray - var yyq2322 [4]bool - _, _, _ = yysep2322, yyq2322, yy2arr2322 - const yyr2322 bool = false - yyq2322[0] = x.Kind != "" - yyq2322[1] = x.APIVersion != "" - yyq2322[2] = true - yyq2322[3] = true - var yynn2322 int - if yyr2322 || yy2arr2322 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2322 = 0 - for _, b := range yyq2322 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2322++ + yynn2++ } } - r.EncodeMapStart(yynn2322) - yynn2322 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2322 || yy2arr2322 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2322[0] { - yym2324 := z.EncBinary() - _ = yym2324 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -30864,23 +40181,23 @@ func (x *PodTemplate) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2322[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2325 := z.EncBinary() - _ = yym2325 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2322 || yy2arr2322 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2322[1] { - yym2327 := z.EncBinary() - _ = yym2327 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -30889,53 +40206,65 @@ func (x *PodTemplate) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2322[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2328 := z.EncBinary() - _ = yym2328 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2322 || yy2arr2322 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2322[2] { - yy2330 := &x.ObjectMeta - yy2330.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2322[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2331 := &x.ObjectMeta - yy2331.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2322 || yy2arr2322 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2322[3] { - yy2333 := &x.Template - yy2333.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Template + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2322[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("template")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2334 := &x.Template - yy2334.CodecEncodeSelf(e) + yy17 := &x.Template + yy17.CodecEncodeSelf(e) } } - if yyr2322 || yy2arr2322 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -30948,25 +40277,25 @@ func (x *PodTemplate) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2335 := z.DecBinary() - _ = yym2335 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2336 := r.ContainerType() - if yyct2336 == codecSelferValueTypeMap1234 { - yyl2336 := r.ReadMapStart() - if yyl2336 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2336, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2336 == codecSelferValueTypeArray1234 { - yyl2336 := r.ReadArrayStart() - if yyl2336 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2336, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -30978,12 +40307,12 @@ func (x *PodTemplate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2337Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2337Slc - var yyhl2337 bool = l >= 0 - for yyj2337 := 0; ; yyj2337++ { - if yyhl2337 { - if yyj2337 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -30992,40 +40321,58 @@ func (x *PodTemplate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2337Slc = r.DecodeBytes(yys2337Slc, true, true) - yys2337 := string(yys2337Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2337 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2340 := &x.ObjectMeta - yyv2340.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "template": if r.TryDecodeAsNil() { x.Template = PodTemplateSpec{} } else { - yyv2341 := &x.Template - yyv2341.CodecDecodeSelf(d) + yyv10 := &x.Template + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2337) - } // end switch yys2337 - } // end for yyj2337 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -31033,16 +40380,16 @@ func (x *PodTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2342 int - var yyb2342 bool - var yyhl2342 bool = l >= 0 - yyj2342++ - if yyhl2342 { - yyb2342 = yyj2342 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2342 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2342 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31050,15 +40397,21 @@ func (x *PodTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj2342++ - if yyhl2342 { - yyb2342 = yyj2342 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2342 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2342 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31066,32 +40419,44 @@ func (x *PodTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj2342++ - if yyhl2342 { - yyb2342 = yyj2342 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2342 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2342 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2345 := &x.ObjectMeta - yyv2345.CodecDecodeSelf(d) + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } } - yyj2342++ - if yyhl2342 { - yyb2342 = yyj2342 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2342 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2342 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31099,21 +40464,21 @@ func (x *PodTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Template = PodTemplateSpec{} } else { - yyv2346 := &x.Template - yyv2346.CodecDecodeSelf(d) + yyv18 := &x.Template + yyv18.CodecDecodeSelf(d) } for { - yyj2342++ - if yyhl2342 { - yyb2342 = yyj2342 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2342 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2342 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2342-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -31125,37 +40490,37 @@ func (x *PodTemplateList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2347 := z.EncBinary() - _ = yym2347 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2348 := !z.EncBinary() - yy2arr2348 := z.EncBasicHandle().StructToArray - var yyq2348 [4]bool - _, _, _ = yysep2348, yyq2348, yy2arr2348 - const yyr2348 bool = false - yyq2348[0] = x.Kind != "" - yyq2348[1] = x.APIVersion != "" - yyq2348[2] = true - var yynn2348 int - if yyr2348 || yy2arr2348 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2348 = 1 - for _, b := range yyq2348 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2348++ + yynn2++ } } - r.EncodeMapStart(yynn2348) - yynn2348 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2348 || yy2arr2348 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2348[0] { - yym2350 := z.EncBinary() - _ = yym2350 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -31164,23 +40529,23 @@ func (x *PodTemplateList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2348[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2351 := z.EncBinary() - _ = yym2351 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2348 || yy2arr2348 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2348[1] { - yym2353 := z.EncBinary() - _ = yym2353 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -31189,54 +40554,54 @@ func (x *PodTemplateList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2348[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2354 := z.EncBinary() - _ = yym2354 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2348 || yy2arr2348 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2348[2] { - yy2356 := &x.ListMeta - yym2357 := z.EncBinary() - _ = yym2357 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2356) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy2356) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2348[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2358 := &x.ListMeta - yym2359 := z.EncBinary() - _ = yym2359 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2358) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy2358) + z.EncFallback(yy12) } } } - if yyr2348 || yy2arr2348 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym2361 := z.EncBinary() - _ = yym2361 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePodTemplate(([]PodTemplate)(x.Items), e) @@ -31249,15 +40614,15 @@ func (x *PodTemplateList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym2362 := z.EncBinary() - _ = yym2362 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePodTemplate(([]PodTemplate)(x.Items), e) } } } - if yyr2348 || yy2arr2348 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -31270,25 +40635,25 @@ func (x *PodTemplateList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2363 := z.DecBinary() - _ = yym2363 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2364 := r.ContainerType() - if yyct2364 == codecSelferValueTypeMap1234 { - yyl2364 := r.ReadMapStart() - if yyl2364 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2364, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2364 == codecSelferValueTypeArray1234 { - yyl2364 := r.ReadArrayStart() - if yyl2364 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2364, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -31300,12 +40665,12 @@ func (x *PodTemplateList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2365Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2365Slc - var yyhl2365 bool = l >= 0 - for yyj2365 := 0; ; yyj2365++ { - if yyhl2365 { - if yyj2365 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -31314,51 +40679,63 @@ func (x *PodTemplateList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2365Slc = r.DecodeBytes(yys2365Slc, true, true) - yys2365 := string(yys2365Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2365 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2368 := &x.ListMeta - yym2369 := z.DecBinary() - _ = yym2369 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv2368) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv2368, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2370 := &x.Items - yym2371 := z.DecBinary() - _ = yym2371 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePodTemplate((*[]PodTemplate)(yyv2370), d) + h.decSlicePodTemplate((*[]PodTemplate)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2365) - } // end switch yys2365 - } // end for yyj2365 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -31366,16 +40743,16 @@ func (x *PodTemplateList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2372 int - var yyb2372 bool - var yyhl2372 bool = l >= 0 - yyj2372++ - if yyhl2372 { - yyb2372 = yyj2372 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2372 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2372 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31383,15 +40760,21 @@ func (x *PodTemplateList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2372++ - if yyhl2372 { - yyb2372 = yyj2372 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2372 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2372 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31399,38 +40782,44 @@ func (x *PodTemplateList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2372++ - if yyhl2372 { - yyb2372 = yyj2372 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2372 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2372 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2375 := &x.ListMeta - yym2376 := z.DecBinary() - _ = yym2376 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv2375) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv2375, false) + z.DecFallback(yyv17, false) } } - yyj2372++ - if yyhl2372 { - yyb2372 = yyj2372 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2372 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2372 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31438,26 +40827,26 @@ func (x *PodTemplateList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2377 := &x.Items - yym2378 := z.DecBinary() - _ = yym2378 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePodTemplate((*[]PodTemplate)(yyv2377), d) + h.decSlicePodTemplate((*[]PodTemplate)(yyv19), d) } } for { - yyj2372++ - if yyhl2372 { - yyb2372 = yyj2372 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2372 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2372 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2372-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -31469,73 +40858,73 @@ func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2379 := z.EncBinary() - _ = yym2379 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2380 := !z.EncBinary() - yy2arr2380 := z.EncBasicHandle().StructToArray - var yyq2380 [4]bool - _, _, _ = yysep2380, yyq2380, yy2arr2380 - const yyr2380 bool = false - yyq2380[0] = x.Replicas != nil - yyq2380[1] = x.MinReadySeconds != 0 - yyq2380[2] = len(x.Selector) != 0 - yyq2380[3] = x.Template != nil - var yynn2380 int - if yyr2380 || yy2arr2380 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != nil + yyq2[1] = x.MinReadySeconds != 0 + yyq2[2] = len(x.Selector) != 0 + yyq2[3] = x.Template != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2380 = 0 - for _, b := range yyq2380 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2380++ + yynn2++ } } - r.EncodeMapStart(yynn2380) - yynn2380 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2380 || yy2arr2380 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2380[0] { + if yyq2[0] { if x.Replicas == nil { r.EncodeNil() } else { - yy2382 := *x.Replicas - yym2383 := z.EncBinary() - _ = yym2383 + yy4 := *x.Replicas + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeInt(int64(yy2382)) + r.EncodeInt(int64(yy4)) } } } else { r.EncodeNil() } } else { - if yyq2380[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Replicas == nil { r.EncodeNil() } else { - yy2384 := *x.Replicas - yym2385 := z.EncBinary() - _ = yym2385 + yy6 := *x.Replicas + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeInt(int64(yy2384)) + r.EncodeInt(int64(yy6)) } } } } - if yyr2380 || yy2arr2380 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2380[1] { - yym2387 := z.EncBinary() - _ = yym2387 + if yyq2[1] { + yym9 := z.EncBinary() + _ = yym9 if false { } else { r.EncodeInt(int64(x.MinReadySeconds)) @@ -31544,26 +40933,26 @@ func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq2380[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2388 := z.EncBinary() - _ = yym2388 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.MinReadySeconds)) } } } - if yyr2380 || yy2arr2380 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2380[2] { + if yyq2[2] { if x.Selector == nil { r.EncodeNil() } else { - yym2390 := z.EncBinary() - _ = yym2390 + yym12 := z.EncBinary() + _ = yym12 if false { } else { z.F.EncMapStringStringV(x.Selector, false, e) @@ -31573,15 +40962,15 @@ func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2380[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Selector == nil { r.EncodeNil() } else { - yym2391 := z.EncBinary() - _ = yym2391 + yym13 := z.EncBinary() + _ = yym13 if false { } else { z.F.EncMapStringStringV(x.Selector, false, e) @@ -31589,9 +40978,9 @@ func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2380 || yy2arr2380 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2380[3] { + if yyq2[3] { if x.Template == nil { r.EncodeNil() } else { @@ -31601,7 +40990,7 @@ func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2380[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("template")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -31612,7 +41001,7 @@ func (x *ReplicationControllerSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2380 || yy2arr2380 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -31625,25 +41014,25 @@ func (x *ReplicationControllerSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2393 := z.DecBinary() - _ = yym2393 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2394 := r.ContainerType() - if yyct2394 == codecSelferValueTypeMap1234 { - yyl2394 := r.ReadMapStart() - if yyl2394 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2394, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2394 == codecSelferValueTypeArray1234 { - yyl2394 := r.ReadArrayStart() - if yyl2394 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2394, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -31655,12 +41044,12 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromMap(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2395Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2395Slc - var yyhl2395 bool = l >= 0 - for yyj2395 := 0; ; yyj2395++ { - if yyhl2395 { - if yyj2395 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -31669,10 +41058,10 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2395Slc = r.DecodeBytes(yys2395Slc, true, true) - yys2395 := string(yys2395Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2395 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { if x.Replicas != nil { @@ -31682,8 +41071,8 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromMap(l int, d *codec1978.D if x.Replicas == nil { x.Replicas = new(int32) } - yym2397 := z.DecBinary() - _ = yym2397 + yym5 := z.DecBinary() + _ = yym5 if false { } else { *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) @@ -31693,18 +41082,24 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromMap(l int, d *codec1978.D if r.TryDecodeAsNil() { x.MinReadySeconds = 0 } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) + yyv6 := &x.MinReadySeconds + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } case "selector": if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv2399 := &x.Selector - yym2400 := z.DecBinary() - _ = yym2400 + yyv8 := &x.Selector + yym9 := z.DecBinary() + _ = yym9 if false { } else { - z.F.DecMapStringStringX(yyv2399, false, d) + z.F.DecMapStringStringX(yyv8, false, d) } } case "template": @@ -31719,9 +41114,9 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromMap(l int, d *codec1978.D x.Template.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2395) - } // end switch yys2395 - } // end for yyj2395 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -31729,16 +41124,16 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromArray(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2402 int - var yyb2402 bool - var yyhl2402 bool = l >= 0 - yyj2402++ - if yyhl2402 { - yyb2402 = yyj2402 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2402 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2402 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31751,20 +41146,20 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromArray(l int, d *codec1978 if x.Replicas == nil { x.Replicas = new(int32) } - yym2404 := z.DecBinary() - _ = yym2404 + yym13 := z.DecBinary() + _ = yym13 if false { } else { *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) } } - yyj2402++ - if yyhl2402 { - yyb2402 = yyj2402 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2402 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2402 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31772,15 +41167,21 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.MinReadySeconds = 0 } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) + yyv14 := &x.MinReadySeconds + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } } - yyj2402++ - if yyhl2402 { - yyb2402 = yyj2402 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2402 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2402 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31788,21 +41189,21 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv2406 := &x.Selector - yym2407 := z.DecBinary() - _ = yym2407 + yyv16 := &x.Selector + yym17 := z.DecBinary() + _ = yym17 if false { } else { - z.F.DecMapStringStringX(yyv2406, false, d) + z.F.DecMapStringStringX(yyv16, false, d) } } - yyj2402++ - if yyhl2402 { - yyb2402 = yyj2402 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2402 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2402 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -31818,17 +41219,17 @@ func (x *ReplicationControllerSpec) codecDecodeSelfFromArray(l int, d *codec1978 x.Template.CodecDecodeSelf(d) } for { - yyj2402++ - if yyhl2402 { - yyb2402 = yyj2402 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2402 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2402 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2402-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -31840,38 +41241,38 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2409 := z.EncBinary() - _ = yym2409 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2410 := !z.EncBinary() - yy2arr2410 := z.EncBasicHandle().StructToArray - var yyq2410 [6]bool - _, _, _ = yysep2410, yyq2410, yy2arr2410 - const yyr2410 bool = false - yyq2410[1] = x.FullyLabeledReplicas != 0 - yyq2410[2] = x.ReadyReplicas != 0 - yyq2410[3] = x.AvailableReplicas != 0 - yyq2410[4] = x.ObservedGeneration != 0 - yyq2410[5] = len(x.Conditions) != 0 - var yynn2410 int - if yyr2410 || yy2arr2410 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FullyLabeledReplicas != 0 + yyq2[2] = x.ReadyReplicas != 0 + yyq2[3] = x.AvailableReplicas != 0 + yyq2[4] = x.ObservedGeneration != 0 + yyq2[5] = len(x.Conditions) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn2410 = 1 - for _, b := range yyq2410 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2410++ + yynn2++ } } - r.EncodeMapStart(yynn2410) - yynn2410 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2412 := z.EncBinary() - _ = yym2412 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Replicas)) @@ -31880,18 +41281,18 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2413 := z.EncBinary() - _ = yym2413 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Replicas)) } } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2410[1] { - yym2415 := z.EncBinary() - _ = yym2415 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.FullyLabeledReplicas)) @@ -31900,23 +41301,23 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq2410[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fullyLabeledReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2416 := z.EncBinary() - _ = yym2416 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.FullyLabeledReplicas)) } } } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2410[2] { - yym2418 := z.EncBinary() - _ = yym2418 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.ReadyReplicas)) @@ -31925,23 +41326,23 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq2410[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2419 := z.EncBinary() - _ = yym2419 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeInt(int64(x.ReadyReplicas)) } } } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2410[3] { - yym2421 := z.EncBinary() - _ = yym2421 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeInt(int64(x.AvailableReplicas)) @@ -31950,23 +41351,23 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq2410[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2422 := z.EncBinary() - _ = yym2422 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeInt(int64(x.AvailableReplicas)) } } } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2410[4] { - yym2424 := z.EncBinary() - _ = yym2424 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeInt(int64(x.ObservedGeneration)) @@ -31975,26 +41376,26 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq2410[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2425 := z.EncBinary() - _ = yym2425 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeInt(int64(x.ObservedGeneration)) } } } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2410[5] { + if yyq2[5] { if x.Conditions == nil { r.EncodeNil() } else { - yym2427 := z.EncBinary() - _ = yym2427 + yym19 := z.EncBinary() + _ = yym19 if false { } else { h.encSliceReplicationControllerCondition(([]ReplicationControllerCondition)(x.Conditions), e) @@ -32004,15 +41405,15 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2410[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Conditions == nil { r.EncodeNil() } else { - yym2428 := z.EncBinary() - _ = yym2428 + yym20 := z.EncBinary() + _ = yym20 if false { } else { h.encSliceReplicationControllerCondition(([]ReplicationControllerCondition)(x.Conditions), e) @@ -32020,7 +41421,7 @@ func (x *ReplicationControllerStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2410 || yy2arr2410 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -32033,25 +41434,25 @@ func (x *ReplicationControllerStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2429 := z.DecBinary() - _ = yym2429 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2430 := r.ContainerType() - if yyct2430 == codecSelferValueTypeMap1234 { - yyl2430 := r.ReadMapStart() - if yyl2430 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2430, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2430 == codecSelferValueTypeArray1234 { - yyl2430 := r.ReadArrayStart() - if yyl2430 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2430, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -32063,12 +41464,12 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromMap(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2431Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2431Slc - var yyhl2431 bool = l >= 0 - for yyj2431 := 0; ; yyj2431++ { - if yyhl2431 { - if yyj2431 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -32077,56 +41478,86 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2431Slc = r.DecodeBytes(yys2431Slc, true, true) - yys2431 := string(yys2431Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2431 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "fullyLabeledReplicas": if r.TryDecodeAsNil() { x.FullyLabeledReplicas = 0 } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) + yyv6 := &x.FullyLabeledReplicas + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } case "readyReplicas": if r.TryDecodeAsNil() { x.ReadyReplicas = 0 } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) + yyv8 := &x.ReadyReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } case "availableReplicas": if r.TryDecodeAsNil() { x.AvailableReplicas = 0 } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) + yyv10 := &x.AvailableReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } } case "observedGeneration": if r.TryDecodeAsNil() { x.ObservedGeneration = 0 } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) + yyv12 := &x.ObservedGeneration + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } } case "conditions": if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv2437 := &x.Conditions - yym2438 := z.DecBinary() - _ = yym2438 + yyv14 := &x.Conditions + yym15 := z.DecBinary() + _ = yym15 if false { } else { - h.decSliceReplicationControllerCondition((*[]ReplicationControllerCondition)(yyv2437), d) + h.decSliceReplicationControllerCondition((*[]ReplicationControllerCondition)(yyv14), d) } } default: - z.DecStructFieldNotFound(-1, yys2431) - } // end switch yys2431 - } // end for yyj2431 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -32134,16 +41565,16 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2439 int - var yyb2439 bool - var yyhl2439 bool = l >= 0 - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32151,15 +41582,21 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv17 := &x.Replicas + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(yyv17)) = int32(r.DecodeInt(32)) + } } - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32167,15 +41604,21 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.FullyLabeledReplicas = 0 } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) + yyv19 := &x.FullyLabeledReplicas + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int32)(yyv19)) = int32(r.DecodeInt(32)) + } } - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32183,15 +41626,21 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.ReadyReplicas = 0 } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) + yyv21 := &x.ReadyReplicas + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32199,15 +41648,21 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.AvailableReplicas = 0 } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) + yyv23 := &x.AvailableReplicas + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } } - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32215,15 +41670,21 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.ObservedGeneration = 0 } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) + yyv25 := &x.ObservedGeneration + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } } - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32231,26 +41692,26 @@ func (x *ReplicationControllerStatus) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv2445 := &x.Conditions - yym2446 := z.DecBinary() - _ = yym2446 + yyv27 := &x.Conditions + yym28 := z.DecBinary() + _ = yym28 if false { } else { - h.decSliceReplicationControllerCondition((*[]ReplicationControllerCondition)(yyv2445), d) + h.decSliceReplicationControllerCondition((*[]ReplicationControllerCondition)(yyv27), d) } } for { - yyj2439++ - if yyhl2439 { - yyb2439 = yyj2439 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2439 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2439 { + if yyb16 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2439-1, "") + z.DecStructFieldNotFound(yyj16-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -32259,8 +41720,8 @@ func (x ReplicationControllerConditionType) CodecEncodeSelf(e *codec1978.Encoder var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym2447 := z.EncBinary() - _ = yym2447 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -32272,8 +41733,8 @@ func (x *ReplicationControllerConditionType) CodecDecodeSelf(d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2448 := z.DecBinary() - _ = yym2448 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -32288,33 +41749,33 @@ func (x *ReplicationControllerCondition) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2449 := z.EncBinary() - _ = yym2449 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2450 := !z.EncBinary() - yy2arr2450 := z.EncBasicHandle().StructToArray - var yyq2450 [5]bool - _, _, _ = yysep2450, yyq2450, yy2arr2450 - const yyr2450 bool = false - yyq2450[2] = true - yyq2450[3] = x.Reason != "" - yyq2450[4] = x.Message != "" - var yynn2450 int - if yyr2450 || yy2arr2450 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = x.Reason != "" + yyq2[4] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn2450 = 2 - for _, b := range yyq2450 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn2450++ + yynn2++ } } - r.EncodeMapStart(yynn2450) - yynn2450 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2450 || yy2arr2450 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -32323,7 +41784,7 @@ func (x *ReplicationControllerCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr2450 || yy2arr2450 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Status.CodecEncodeSelf(e) } else { @@ -32332,48 +41793,48 @@ func (x *ReplicationControllerCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Status.CodecEncodeSelf(e) } - if yyr2450 || yy2arr2450 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2450[2] { - yy2454 := &x.LastTransitionTime - yym2455 := z.EncBinary() - _ = yym2455 + if yyq2[2] { + yy10 := &x.LastTransitionTime + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2454) { - } else if yym2455 { - z.EncBinaryMarshal(yy2454) - } else if !yym2455 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2454) + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - z.EncFallback(yy2454) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2450[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2456 := &x.LastTransitionTime - yym2457 := z.EncBinary() - _ = yym2457 + yy12 := &x.LastTransitionTime + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2456) { - } else if yym2457 { - z.EncBinaryMarshal(yy2456) - } else if !yym2457 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2456) + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - z.EncFallback(yy2456) + z.EncFallback(yy12) } } } - if yyr2450 || yy2arr2450 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2450[3] { - yym2459 := z.EncBinary() - _ = yym2459 + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -32382,23 +41843,23 @@ func (x *ReplicationControllerCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2450[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2460 := z.EncBinary() - _ = yym2460 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr2450 || yy2arr2450 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2450[4] { - yym2462 := z.EncBinary() - _ = yym2462 + if yyq2[4] { + yym18 := z.EncBinary() + _ = yym18 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -32407,19 +41868,19 @@ func (x *ReplicationControllerCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2450[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2463 := z.EncBinary() - _ = yym2463 + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr2450 || yy2arr2450 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -32432,25 +41893,25 @@ func (x *ReplicationControllerCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2464 := z.DecBinary() - _ = yym2464 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2465 := r.ContainerType() - if yyct2465 == codecSelferValueTypeMap1234 { - yyl2465 := r.ReadMapStart() - if yyl2465 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2465, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2465 == codecSelferValueTypeArray1234 { - yyl2465 := r.ReadArrayStart() - if yyl2465 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2465, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -32462,12 +41923,12 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromMap(l int, d *codec1 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2466Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2466Slc - var yyhl2466 bool = l >= 0 - for yyj2466 := 0; ; yyj2466++ { - if yyhl2466 { - if yyj2466 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -32476,55 +41937,69 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromMap(l int, d *codec1 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2466Slc = r.DecodeBytes(yys2466Slc, true, true) - yys2466 := string(yys2466Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2466 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ReplicationControllerConditionType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } case "lastTransitionTime": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} + x.LastTransitionTime = pkg2_v1.Time{} } else { - yyv2469 := &x.LastTransitionTime - yym2470 := z.DecBinary() - _ = yym2470 + yyv6 := &x.LastTransitionTime + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv2469) { - } else if yym2470 { - z.DecBinaryUnmarshal(yyv2469) - } else if !yym2470 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2469) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv2469, false) + z.DecFallback(yyv6, false) } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv8 := &x.Reason + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv10 := &x.Message + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys2466) - } // end switch yys2466 - } // end for yyj2466 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -32532,16 +42007,16 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromArray(l int, d *code 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 + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2473 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2473 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32549,15 +42024,16 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromArray(l int, d *code if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ReplicationControllerConditionType(r.DecodeString()) + yyv13 := &x.Type + yyv13.CodecDecodeSelf(d) } - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2473 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2473 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32565,42 +42041,43 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromArray(l int, d *code if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv14 := &x.Status + yyv14.CodecDecodeSelf(d) } - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2473 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2473 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} + x.LastTransitionTime = pkg2_v1.Time{} } else { - yyv2476 := &x.LastTransitionTime - yym2477 := z.DecBinary() - _ = yym2477 + yyv15 := &x.LastTransitionTime + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(yyv2476) { - } else if yym2477 { - z.DecBinaryUnmarshal(yyv2476) - } else if !yym2477 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2476) + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else if yym16 { + z.DecBinaryUnmarshal(yyv15) + } else if !yym16 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv15) } else { - z.DecFallback(yyv2476, false) + z.DecFallback(yyv15, false) } } - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2473 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2473 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32608,15 +42085,21 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromArray(l int, d *code if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv17 := &x.Reason + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2473 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2473 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32624,20 +42107,26 @@ func (x *ReplicationControllerCondition) codecDecodeSelfFromArray(l int, d *code if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv19 := &x.Message + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } for { - yyj2473++ - if yyhl2473 { - yyb2473 = yyj2473 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2473 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2473 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2473-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -32649,39 +42138,39 @@ func (x *ReplicationController) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2480 := z.EncBinary() - _ = yym2480 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2481 := !z.EncBinary() - yy2arr2481 := z.EncBasicHandle().StructToArray - var yyq2481 [5]bool - _, _, _ = yysep2481, yyq2481, yy2arr2481 - const yyr2481 bool = false - yyq2481[0] = x.Kind != "" - yyq2481[1] = x.APIVersion != "" - yyq2481[2] = true - yyq2481[3] = true - yyq2481[4] = true - var yynn2481 int - if yyr2481 || yy2arr2481 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn2481 = 0 - for _, b := range yyq2481 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2481++ + yynn2++ } } - r.EncodeMapStart(yynn2481) - yynn2481 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2481 || yy2arr2481 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2481[0] { - yym2483 := z.EncBinary() - _ = yym2483 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -32690,23 +42179,23 @@ func (x *ReplicationController) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2481[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2484 := z.EncBinary() - _ = yym2484 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2481 || yy2arr2481 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2481[1] { - yym2486 := z.EncBinary() - _ = yym2486 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -32715,70 +42204,82 @@ func (x *ReplicationController) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2481[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2487 := z.EncBinary() - _ = yym2487 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2481 || yy2arr2481 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2481[2] { - yy2489 := &x.ObjectMeta - yy2489.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2481[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2490 := &x.ObjectMeta - yy2490.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2481 || yy2arr2481 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2481[3] { - yy2492 := &x.Spec - yy2492.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2481[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2493 := &x.Spec - yy2493.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr2481 || yy2arr2481 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2481[4] { - yy2495 := &x.Status - yy2495.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2481[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2496 := &x.Status - yy2496.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr2481 || yy2arr2481 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -32791,25 +42292,25 @@ func (x *ReplicationController) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2497 := z.DecBinary() - _ = yym2497 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2498 := r.ContainerType() - if yyct2498 == codecSelferValueTypeMap1234 { - yyl2498 := r.ReadMapStart() - if yyl2498 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2498, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2498 == codecSelferValueTypeArray1234 { - yyl2498 := r.ReadArrayStart() - if yyl2498 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2498, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -32821,12 +42322,12 @@ func (x *ReplicationController) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2499Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2499Slc - var yyhl2499 bool = l >= 0 - for yyj2499 := 0; ; yyj2499++ { - if yyhl2499 { - if yyj2499 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -32835,47 +42336,65 @@ func (x *ReplicationController) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2499Slc = r.DecodeBytes(yys2499Slc, true, true) - yys2499 := string(yys2499Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2499 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2502 := &x.ObjectMeta - yyv2502.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = ReplicationControllerSpec{} } else { - yyv2503 := &x.Spec - yyv2503.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = ReplicationControllerStatus{} } else { - yyv2504 := &x.Status - yyv2504.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2499) - } // end switch yys2499 - } // end for yyj2499 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -32883,16 +42402,16 @@ func (x *ReplicationController) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2505 int - var yyb2505 bool - var yyhl2505 bool = l >= 0 - yyj2505++ - if yyhl2505 { - yyb2505 = yyj2505 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2505 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2505 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32900,15 +42419,21 @@ func (x *ReplicationController) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2505++ - if yyhl2505 { - yyb2505 = yyj2505 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2505 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2505 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32916,32 +42441,44 @@ func (x *ReplicationController) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2505++ - if yyhl2505 { - yyb2505 = yyj2505 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2505 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2505 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2508 := &x.ObjectMeta - yyv2508.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj2505++ - if yyhl2505 { - yyb2505 = yyj2505 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2505 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2505 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32949,16 +42486,16 @@ func (x *ReplicationController) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Spec = ReplicationControllerSpec{} } else { - yyv2509 := &x.Spec - yyv2509.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj2505++ - if yyhl2505 { - yyb2505 = yyj2505 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2505 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2505 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -32966,21 +42503,21 @@ func (x *ReplicationController) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Status = ReplicationControllerStatus{} } else { - yyv2510 := &x.Status - yyv2510.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj2505++ - if yyhl2505 { - yyb2505 = yyj2505 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2505 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2505 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2505-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -32992,37 +42529,37 @@ func (x *ReplicationControllerList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2511 := z.EncBinary() - _ = yym2511 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2512 := !z.EncBinary() - yy2arr2512 := z.EncBasicHandle().StructToArray - var yyq2512 [4]bool - _, _, _ = yysep2512, yyq2512, yy2arr2512 - const yyr2512 bool = false - yyq2512[0] = x.Kind != "" - yyq2512[1] = x.APIVersion != "" - yyq2512[2] = true - var yynn2512 int - if yyr2512 || yy2arr2512 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2512 = 1 - for _, b := range yyq2512 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2512++ + yynn2++ } } - r.EncodeMapStart(yynn2512) - yynn2512 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2512 || yy2arr2512 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2512[0] { - yym2514 := z.EncBinary() - _ = yym2514 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -33031,23 +42568,23 @@ func (x *ReplicationControllerList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2512[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2515 := z.EncBinary() - _ = yym2515 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2512 || yy2arr2512 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2512[1] { - yym2517 := z.EncBinary() - _ = yym2517 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -33056,54 +42593,54 @@ func (x *ReplicationControllerList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2512[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2518 := z.EncBinary() - _ = yym2518 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2512 || yy2arr2512 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2512[2] { - yy2520 := &x.ListMeta - yym2521 := z.EncBinary() - _ = yym2521 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2520) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy2520) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2512[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2522 := &x.ListMeta - yym2523 := z.EncBinary() - _ = yym2523 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2522) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy2522) + z.EncFallback(yy12) } } } - if yyr2512 || yy2arr2512 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym2525 := z.EncBinary() - _ = yym2525 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceReplicationController(([]ReplicationController)(x.Items), e) @@ -33116,15 +42653,15 @@ func (x *ReplicationControllerList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym2526 := z.EncBinary() - _ = yym2526 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceReplicationController(([]ReplicationController)(x.Items), e) } } } - if yyr2512 || yy2arr2512 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -33137,25 +42674,25 @@ func (x *ReplicationControllerList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2527 := z.DecBinary() - _ = yym2527 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2528 := r.ContainerType() - if yyct2528 == codecSelferValueTypeMap1234 { - yyl2528 := r.ReadMapStart() - if yyl2528 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2528, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2528 == codecSelferValueTypeArray1234 { - yyl2528 := r.ReadArrayStart() - if yyl2528 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2528, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -33167,12 +42704,12 @@ func (x *ReplicationControllerList) codecDecodeSelfFromMap(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2529Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2529Slc - var yyhl2529 bool = l >= 0 - for yyj2529 := 0; ; yyj2529++ { - if yyhl2529 { - if yyj2529 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -33181,51 +42718,63 @@ func (x *ReplicationControllerList) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2529Slc = r.DecodeBytes(yys2529Slc, true, true) - yys2529 := string(yys2529Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2529 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2532 := &x.ListMeta - yym2533 := z.DecBinary() - _ = yym2533 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv2532) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv2532, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2534 := &x.Items - yym2535 := z.DecBinary() - _ = yym2535 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceReplicationController((*[]ReplicationController)(yyv2534), d) + h.decSliceReplicationController((*[]ReplicationController)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2529) - } // end switch yys2529 - } // end for yyj2529 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -33233,16 +42782,16 @@ func (x *ReplicationControllerList) codecDecodeSelfFromArray(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2536 int - var yyb2536 bool - var yyhl2536 bool = l >= 0 - yyj2536++ - if yyhl2536 { - yyb2536 = yyj2536 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2536 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2536 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33250,15 +42799,21 @@ func (x *ReplicationControllerList) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2536++ - if yyhl2536 { - yyb2536 = yyj2536 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2536 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2536 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33266,38 +42821,44 @@ func (x *ReplicationControllerList) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2536++ - if yyhl2536 { - yyb2536 = yyj2536 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2536 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2536 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2539 := &x.ListMeta - yym2540 := z.DecBinary() - _ = yym2540 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv2539) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv2539, false) + z.DecFallback(yyv17, false) } } - yyj2536++ - if yyhl2536 { - yyb2536 = yyj2536 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2536 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2536 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33305,26 +42866,26 @@ func (x *ReplicationControllerList) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2541 := &x.Items - yym2542 := z.DecBinary() - _ = yym2542 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceReplicationController((*[]ReplicationController)(yyv2541), d) + h.decSliceReplicationController((*[]ReplicationController)(yyv19), d) } } for { - yyj2536++ - if yyhl2536 { - yyb2536 = yyj2536 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2536 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2536 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2536-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -33333,8 +42894,8 @@ func (x ServiceAffinity) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym2543 := z.EncBinary() - _ = yym2543 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -33346,8 +42907,8 @@ func (x *ServiceAffinity) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2544 := z.DecBinary() - _ = yym2544 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -33359,8 +42920,8 @@ func (x ServiceType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym2545 := z.EncBinary() - _ = yym2545 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -33372,8 +42933,34 @@ func (x *ServiceType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2546 := z.DecBinary() - _ = yym2546 + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x ServiceExternalTrafficPolicyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *ServiceExternalTrafficPolicyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -33388,48 +42975,48 @@ func (x *ServiceStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2547 := z.EncBinary() - _ = yym2547 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2548 := !z.EncBinary() - yy2arr2548 := z.EncBasicHandle().StructToArray - var yyq2548 [1]bool - _, _, _ = yysep2548, yyq2548, yy2arr2548 - const yyr2548 bool = false - yyq2548[0] = true - var yynn2548 int - if yyr2548 || yy2arr2548 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn2548 = 0 - for _, b := range yyq2548 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2548++ + yynn2++ } } - r.EncodeMapStart(yynn2548) - yynn2548 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2548 || yy2arr2548 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2548[0] { - yy2550 := &x.LoadBalancer - yy2550.CodecEncodeSelf(e) + if yyq2[0] { + yy4 := &x.LoadBalancer + yy4.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2548[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("loadBalancer")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2551 := &x.LoadBalancer - yy2551.CodecEncodeSelf(e) + yy6 := &x.LoadBalancer + yy6.CodecEncodeSelf(e) } } - if yyr2548 || yy2arr2548 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -33442,25 +43029,25 @@ func (x *ServiceStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2552 := z.DecBinary() - _ = yym2552 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2553 := r.ContainerType() - if yyct2553 == codecSelferValueTypeMap1234 { - yyl2553 := r.ReadMapStart() - if yyl2553 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2553, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2553 == codecSelferValueTypeArray1234 { - yyl2553 := r.ReadArrayStart() - if yyl2553 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2553, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -33472,12 +43059,12 @@ func (x *ServiceStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2554Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2554Slc - var yyhl2554 bool = l >= 0 - for yyj2554 := 0; ; yyj2554++ { - if yyhl2554 { - if yyj2554 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -33486,21 +43073,21 @@ func (x *ServiceStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2554Slc = r.DecodeBytes(yys2554Slc, true, true) - yys2554 := string(yys2554Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2554 { + switch yys3 { case "loadBalancer": if r.TryDecodeAsNil() { x.LoadBalancer = LoadBalancerStatus{} } else { - yyv2555 := &x.LoadBalancer - yyv2555.CodecDecodeSelf(d) + yyv4 := &x.LoadBalancer + yyv4.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2554) - } // end switch yys2554 - } // end for yyj2554 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -33508,16 +43095,16 @@ func (x *ServiceStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2556 int - var yyb2556 bool - var yyhl2556 bool = l >= 0 - yyj2556++ - if yyhl2556 { - yyb2556 = yyj2556 > l + var yyj5 int + var yyb5 bool + var yyhl5 bool = l >= 0 + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb2556 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb2556 { + if yyb5 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33525,21 +43112,21 @@ func (x *ServiceStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.LoadBalancer = LoadBalancerStatus{} } else { - yyv2557 := &x.LoadBalancer - yyv2557.CodecDecodeSelf(d) + yyv6 := &x.LoadBalancer + yyv6.CodecDecodeSelf(d) } for { - yyj2556++ - if yyhl2556 { - yyb2556 = yyj2556 > l + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb2556 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb2556 { + if yyb5 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2556-1, "") + z.DecStructFieldNotFound(yyj5-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -33551,38 +43138,38 @@ func (x *LoadBalancerStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2558 := z.EncBinary() - _ = yym2558 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2559 := !z.EncBinary() - yy2arr2559 := z.EncBasicHandle().StructToArray - var yyq2559 [1]bool - _, _, _ = yysep2559, yyq2559, yy2arr2559 - const yyr2559 bool = false - yyq2559[0] = len(x.Ingress) != 0 - var yynn2559 int - if yyr2559 || yy2arr2559 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Ingress) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn2559 = 0 - for _, b := range yyq2559 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2559++ + yynn2++ } } - r.EncodeMapStart(yynn2559) - yynn2559 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2559 || yy2arr2559 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2559[0] { + if yyq2[0] { if x.Ingress == nil { r.EncodeNil() } else { - yym2561 := z.EncBinary() - _ = yym2561 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e) @@ -33592,15 +43179,15 @@ func (x *LoadBalancerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2559[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ingress")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ingress == nil { r.EncodeNil() } else { - yym2562 := z.EncBinary() - _ = yym2562 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceLoadBalancerIngress(([]LoadBalancerIngress)(x.Ingress), e) @@ -33608,7 +43195,7 @@ func (x *LoadBalancerStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2559 || yy2arr2559 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -33621,25 +43208,25 @@ func (x *LoadBalancerStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2563 := z.DecBinary() - _ = yym2563 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2564 := r.ContainerType() - if yyct2564 == codecSelferValueTypeMap1234 { - yyl2564 := r.ReadMapStart() - if yyl2564 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2564, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2564 == codecSelferValueTypeArray1234 { - yyl2564 := r.ReadArrayStart() - if yyl2564 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2564, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -33651,12 +43238,12 @@ func (x *LoadBalancerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2565Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2565Slc - var yyhl2565 bool = l >= 0 - for yyj2565 := 0; ; yyj2565++ { - if yyhl2565 { - if yyj2565 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -33665,26 +43252,26 @@ func (x *LoadBalancerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2565Slc = r.DecodeBytes(yys2565Slc, true, true) - yys2565 := string(yys2565Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2565 { + switch yys3 { case "ingress": if r.TryDecodeAsNil() { x.Ingress = nil } else { - yyv2566 := &x.Ingress - yym2567 := z.DecBinary() - _ = yym2567 + yyv4 := &x.Ingress + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv2566), d) + h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys2565) - } // end switch yys2565 - } // end for yyj2565 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -33692,16 +43279,16 @@ func (x *LoadBalancerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2568 int - var yyb2568 bool - var yyhl2568 bool = l >= 0 - yyj2568++ - if yyhl2568 { - yyb2568 = yyj2568 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb2568 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb2568 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33709,26 +43296,26 @@ func (x *LoadBalancerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Ingress = nil } else { - yyv2569 := &x.Ingress - yym2570 := z.DecBinary() - _ = yym2570 + yyv7 := &x.Ingress + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv2569), d) + h.decSliceLoadBalancerIngress((*[]LoadBalancerIngress)(yyv7), d) } } for { - yyj2568++ - if yyhl2568 { - yyb2568 = yyj2568 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb2568 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb2568 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2568-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -33740,36 +43327,36 @@ func (x *LoadBalancerIngress) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2571 := z.EncBinary() - _ = yym2571 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2572 := !z.EncBinary() - yy2arr2572 := z.EncBasicHandle().StructToArray - var yyq2572 [2]bool - _, _, _ = yysep2572, yyq2572, yy2arr2572 - const yyr2572 bool = false - yyq2572[0] = x.IP != "" - yyq2572[1] = x.Hostname != "" - var yynn2572 int - if yyr2572 || yy2arr2572 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.IP != "" + yyq2[1] = x.Hostname != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn2572 = 0 - for _, b := range yyq2572 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2572++ + yynn2++ } } - r.EncodeMapStart(yynn2572) - yynn2572 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2572 || yy2arr2572 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2572[0] { - yym2574 := z.EncBinary() - _ = yym2574 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.IP)) @@ -33778,23 +43365,23 @@ func (x *LoadBalancerIngress) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2572[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ip")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2575 := z.EncBinary() - _ = yym2575 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.IP)) } } } - if yyr2572 || yy2arr2572 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2572[1] { - yym2577 := z.EncBinary() - _ = yym2577 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) @@ -33803,19 +43390,19 @@ func (x *LoadBalancerIngress) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2572[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostname")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2578 := z.EncBinary() - _ = yym2578 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) } } } - if yyr2572 || yy2arr2572 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -33828,25 +43415,25 @@ func (x *LoadBalancerIngress) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2579 := z.DecBinary() - _ = yym2579 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2580 := r.ContainerType() - if yyct2580 == codecSelferValueTypeMap1234 { - yyl2580 := r.ReadMapStart() - if yyl2580 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2580, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2580 == codecSelferValueTypeArray1234 { - yyl2580 := r.ReadArrayStart() - if yyl2580 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2580, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -33858,12 +43445,12 @@ func (x *LoadBalancerIngress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2581Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2581Slc - var yyhl2581 bool = l >= 0 - for yyj2581 := 0; ; yyj2581++ { - if yyhl2581 { - if yyj2581 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -33872,26 +43459,38 @@ func (x *LoadBalancerIngress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2581Slc = r.DecodeBytes(yys2581Slc, true, true) - yys2581 := string(yys2581Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2581 { + switch yys3 { case "ip": if r.TryDecodeAsNil() { x.IP = "" } else { - x.IP = string(r.DecodeString()) + yyv4 := &x.IP + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "hostname": if r.TryDecodeAsNil() { x.Hostname = "" } else { - x.Hostname = string(r.DecodeString()) + yyv6 := &x.Hostname + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys2581) - } // end switch yys2581 - } // end for yyj2581 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -33899,16 +43498,16 @@ func (x *LoadBalancerIngress) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2584 int - var yyb2584 bool - var yyhl2584 bool = l >= 0 - yyj2584++ - if yyhl2584 { - yyb2584 = yyj2584 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb2584 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb2584 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33916,15 +43515,21 @@ func (x *LoadBalancerIngress) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.IP = "" } else { - x.IP = string(r.DecodeString()) + yyv9 := &x.IP + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj2584++ - if yyhl2584 { - yyb2584 = yyj2584 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb2584 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb2584 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -33932,20 +43537,26 @@ func (x *LoadBalancerIngress) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Hostname = "" } else { - x.Hostname = string(r.DecodeString()) + yyv11 := &x.Hostname + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj2584++ - if yyhl2584 { - yyb2584 = yyj2584 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb2584 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb2584 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2584-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -33957,73 +43568,81 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2587 := z.EncBinary() - _ = yym2587 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2588 := !z.EncBinary() - yy2arr2588 := z.EncBasicHandle().StructToArray - var yyq2588 [10]bool - _, _, _ = yysep2588, yyq2588, yy2arr2588 - const yyr2588 bool = false - yyq2588[1] = len(x.Selector) != 0 - yyq2588[2] = x.ClusterIP != "" - yyq2588[3] = x.Type != "" - yyq2588[4] = len(x.ExternalIPs) != 0 - yyq2588[5] = len(x.DeprecatedPublicIPs) != 0 - yyq2588[6] = x.SessionAffinity != "" - yyq2588[7] = x.LoadBalancerIP != "" - yyq2588[8] = len(x.LoadBalancerSourceRanges) != 0 - yyq2588[9] = x.ExternalName != "" - var yynn2588 int - if yyr2588 || yy2arr2588 { - r.EncodeArrayStart(10) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [11]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Ports) != 0 + yyq2[1] = len(x.Selector) != 0 + yyq2[2] = x.ClusterIP != "" + yyq2[3] = x.Type != "" + yyq2[4] = len(x.ExternalIPs) != 0 + yyq2[5] = x.SessionAffinity != "" + yyq2[6] = x.LoadBalancerIP != "" + yyq2[7] = len(x.LoadBalancerSourceRanges) != 0 + yyq2[8] = x.ExternalName != "" + yyq2[9] = x.ExternalTrafficPolicy != "" + yyq2[10] = x.HealthCheckNodePort != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(11) } else { - yynn2588 = 1 - for _, b := range yyq2588 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2588++ + yynn2++ } } - r.EncodeMapStart(yynn2588) - yynn2588 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym2590 := z.EncBinary() - _ = yym2590 - if false { + if yyq2[0] { + if x.Ports == nil { + r.EncodeNil() } else { - h.encSliceServicePort(([]ServicePort)(x.Ports), e) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceServicePort(([]ServicePort)(x.Ports), e) + } } + } else { + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ports")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym2591 := z.EncBinary() - _ = yym2591 - if false { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ports")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ports == nil { + r.EncodeNil() } else { - h.encSliceServicePort(([]ServicePort)(x.Ports), e) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceServicePort(([]ServicePort)(x.Ports), e) + } } } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[1] { + if yyq2[1] { if x.Selector == nil { r.EncodeNil() } else { - yym2593 := z.EncBinary() - _ = yym2593 + yym7 := z.EncBinary() + _ = yym7 if false { } else { z.F.EncMapStringStringV(x.Selector, false, e) @@ -34033,15 +43652,15 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2588[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Selector == nil { r.EncodeNil() } else { - yym2594 := z.EncBinary() - _ = yym2594 + yym8 := z.EncBinary() + _ = yym8 if false { } else { z.F.EncMapStringStringV(x.Selector, false, e) @@ -34049,11 +43668,11 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[2] { - yym2596 := z.EncBinary() - _ = yym2596 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP)) @@ -34062,41 +43681,41 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2588[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("clusterIP")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2597 := z.EncBinary() - _ = yym2597 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ClusterIP)) } } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[3] { + if yyq2[3] { x.Type.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2588[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[4] { + if yyq2[4] { if x.ExternalIPs == nil { r.EncodeNil() } else { - yym2600 := z.EncBinary() - _ = yym2600 + yym16 := z.EncBinary() + _ = yym16 if false { } else { z.F.EncSliceStringV(x.ExternalIPs, false, e) @@ -34106,15 +43725,15 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2588[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("externalIPs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ExternalIPs == nil { r.EncodeNil() } else { - yym2601 := z.EncBinary() - _ = yym2601 + yym17 := z.EncBinary() + _ = yym17 if false { } else { z.F.EncSliceStringV(x.ExternalIPs, false, e) @@ -34122,59 +43741,26 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2588 || yy2arr2588 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[5] { - if x.DeprecatedPublicIPs == nil { - r.EncodeNil() - } else { - yym2603 := z.EncBinary() - _ = yym2603 - if false { - } else { - z.F.EncSliceStringV(x.DeprecatedPublicIPs, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2588[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deprecatedPublicIPs")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DeprecatedPublicIPs == nil { - r.EncodeNil() - } else { - yym2604 := z.EncBinary() - _ = yym2604 - if false { - } else { - z.F.EncSliceStringV(x.DeprecatedPublicIPs, false, e) - } - } - } - } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[6] { + if yyq2[5] { x.SessionAffinity.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2588[6] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("sessionAffinity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.SessionAffinity.CodecEncodeSelf(e) } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[7] { - yym2607 := z.EncBinary() - _ = yym2607 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP)) @@ -34183,26 +43769,26 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2588[7] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("loadBalancerIP")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2608 := z.EncBinary() - _ = yym2608 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.LoadBalancerIP)) } } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[8] { + if yyq2[7] { if x.LoadBalancerSourceRanges == nil { r.EncodeNil() } else { - yym2610 := z.EncBinary() - _ = yym2610 + yym25 := z.EncBinary() + _ = yym25 if false { } else { z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e) @@ -34212,15 +43798,15 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2588[8] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("loadBalancerSourceRanges")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.LoadBalancerSourceRanges == nil { r.EncodeNil() } else { - yym2611 := z.EncBinary() - _ = yym2611 + yym26 := z.EncBinary() + _ = yym26 if false { } else { z.F.EncSliceStringV(x.LoadBalancerSourceRanges, false, e) @@ -34228,11 +43814,11 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2588[9] { - yym2613 := z.EncBinary() - _ = yym2613 + if yyq2[8] { + yym28 := z.EncBinary() + _ = yym28 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ExternalName)) @@ -34241,19 +43827,59 @@ func (x *ServiceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2588[9] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("externalName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2614 := z.EncBinary() - _ = yym2614 + yym29 := z.EncBinary() + _ = yym29 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ExternalName)) } } } - if yyr2588 || yy2arr2588 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[9] { + x.ExternalTrafficPolicy.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[9] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("externalTrafficPolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.ExternalTrafficPolicy.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[10] { + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeInt(int64(x.HealthCheckNodePort)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[10] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("healthCheckNodePort")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym35 := z.EncBinary() + _ = yym35 + if false { + } else { + r.EncodeInt(int64(x.HealthCheckNodePort)) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -34266,25 +43892,25 @@ func (x *ServiceSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2615 := z.DecBinary() - _ = yym2615 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2616 := r.ContainerType() - if yyct2616 == codecSelferValueTypeMap1234 { - yyl2616 := r.ReadMapStart() - if yyl2616 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2616, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2616 == codecSelferValueTypeArray1234 { - yyl2616 := r.ReadArrayStart() - if yyl2616 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2616, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -34296,12 +43922,12 @@ func (x *ServiceSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2617Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2617Slc - var yyhl2617 bool = l >= 0 - for yyj2617 := 0; ; yyj2617++ { - if yyhl2617 { - if yyj2617 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -34310,104 +43936,131 @@ func (x *ServiceSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2617Slc = r.DecodeBytes(yys2617Slc, true, true) - yys2617 := string(yys2617Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2617 { + switch yys3 { case "ports": if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv2618 := &x.Ports - yym2619 := z.DecBinary() - _ = yym2619 + yyv4 := &x.Ports + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceServicePort((*[]ServicePort)(yyv2618), d) + h.decSliceServicePort((*[]ServicePort)(yyv4), d) } } case "selector": if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv2620 := &x.Selector - yym2621 := z.DecBinary() - _ = yym2621 + yyv6 := &x.Selector + yym7 := z.DecBinary() + _ = yym7 if false { } else { - z.F.DecMapStringStringX(yyv2620, false, d) + z.F.DecMapStringStringX(yyv6, false, d) } } case "clusterIP": if r.TryDecodeAsNil() { x.ClusterIP = "" } else { - x.ClusterIP = string(r.DecodeString()) + yyv8 := &x.ClusterIP + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ServiceType(r.DecodeString()) + yyv10 := &x.Type + yyv10.CodecDecodeSelf(d) } case "externalIPs": if r.TryDecodeAsNil() { x.ExternalIPs = nil } else { - yyv2624 := &x.ExternalIPs - yym2625 := z.DecBinary() - _ = yym2625 + yyv11 := &x.ExternalIPs + yym12 := z.DecBinary() + _ = yym12 if false { } else { - z.F.DecSliceStringX(yyv2624, false, d) - } - } - case "deprecatedPublicIPs": - if r.TryDecodeAsNil() { - x.DeprecatedPublicIPs = nil - } else { - yyv2626 := &x.DeprecatedPublicIPs - yym2627 := z.DecBinary() - _ = yym2627 - if false { - } else { - z.F.DecSliceStringX(yyv2626, false, d) + z.F.DecSliceStringX(yyv11, false, d) } } case "sessionAffinity": if r.TryDecodeAsNil() { x.SessionAffinity = "" } else { - x.SessionAffinity = ServiceAffinity(r.DecodeString()) + yyv13 := &x.SessionAffinity + yyv13.CodecDecodeSelf(d) } case "loadBalancerIP": if r.TryDecodeAsNil() { x.LoadBalancerIP = "" } else { - x.LoadBalancerIP = string(r.DecodeString()) + yyv14 := &x.LoadBalancerIP + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "loadBalancerSourceRanges": if r.TryDecodeAsNil() { x.LoadBalancerSourceRanges = nil } else { - yyv2630 := &x.LoadBalancerSourceRanges - yym2631 := z.DecBinary() - _ = yym2631 + yyv16 := &x.LoadBalancerSourceRanges + yym17 := z.DecBinary() + _ = yym17 if false { } else { - z.F.DecSliceStringX(yyv2630, false, d) + z.F.DecSliceStringX(yyv16, false, d) } } case "externalName": if r.TryDecodeAsNil() { x.ExternalName = "" } else { - x.ExternalName = string(r.DecodeString()) + yyv18 := &x.ExternalName + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + case "externalTrafficPolicy": + if r.TryDecodeAsNil() { + x.ExternalTrafficPolicy = "" + } else { + yyv20 := &x.ExternalTrafficPolicy + yyv20.CodecDecodeSelf(d) + } + case "healthCheckNodePort": + if r.TryDecodeAsNil() { + x.HealthCheckNodePort = 0 + } else { + yyv21 := &x.HealthCheckNodePort + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys2617) - } // end switch yys2617 - } // end for yyj2617 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -34415,16 +44068,16 @@ func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2633 int - var yyb2633 bool - var yyhl2633 bool = l >= 0 - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + var yyj23 int + var yyb23 bool + var yyhl23 bool = l >= 0 + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34432,21 +44085,21 @@ func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv2634 := &x.Ports - yym2635 := z.DecBinary() - _ = yym2635 + yyv24 := &x.Ports + yym25 := z.DecBinary() + _ = yym25 if false { } else { - h.decSliceServicePort((*[]ServicePort)(yyv2634), d) + h.decSliceServicePort((*[]ServicePort)(yyv24), d) } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34454,21 +44107,21 @@ func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv2636 := &x.Selector - yym2637 := z.DecBinary() - _ = yym2637 + yyv26 := &x.Selector + yym27 := z.DecBinary() + _ = yym27 if false { } else { - z.F.DecMapStringStringX(yyv2636, false, d) + z.F.DecMapStringStringX(yyv26, false, d) } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34476,15 +44129,21 @@ func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ClusterIP = "" } else { - x.ClusterIP = string(r.DecodeString()) + yyv28 := &x.ClusterIP + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*string)(yyv28)) = r.DecodeString() + } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34492,15 +44151,16 @@ func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ServiceType(r.DecodeString()) + yyv30 := &x.Type + yyv30.CodecDecodeSelf(d) } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34508,118 +44168,148 @@ func (x *ServiceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ExternalIPs = nil } else { - yyv2640 := &x.ExternalIPs - yym2641 := z.DecBinary() - _ = yym2641 + yyv31 := &x.ExternalIPs + yym32 := z.DecBinary() + _ = yym32 if false { } else { - z.F.DecSliceStringX(yyv2640, false, d) + z.F.DecSliceStringX(yyv31, false, d) } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DeprecatedPublicIPs = nil + x.SessionAffinity = "" } else { - yyv2642 := &x.DeprecatedPublicIPs - yym2643 := z.DecBinary() - _ = yym2643 - if false { - } else { - z.F.DecSliceStringX(yyv2642, false, d) - } + yyv33 := &x.SessionAffinity + yyv33.CodecDecodeSelf(d) } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.SessionAffinity = "" + x.LoadBalancerIP = "" } else { - x.SessionAffinity = ServiceAffinity(r.DecodeString()) + yyv34 := &x.LoadBalancerIP + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LoadBalancerIP = "" + x.LoadBalancerSourceRanges = nil } else { - x.LoadBalancerIP = string(r.DecodeString()) + yyv36 := &x.LoadBalancerSourceRanges + yym37 := z.DecBinary() + _ = yym37 + if false { + } else { + z.F.DecSliceStringX(yyv36, false, d) + } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LoadBalancerSourceRanges = nil + x.ExternalName = "" } else { - yyv2646 := &x.LoadBalancerSourceRanges - yym2647 := z.DecBinary() - _ = yym2647 + yyv38 := &x.ExternalName + yym39 := z.DecBinary() + _ = yym39 if false { } else { - z.F.DecSliceStringX(yyv2646, false, d) + *((*string)(yyv38)) = r.DecodeString() } } - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ExternalName = "" + x.ExternalTrafficPolicy = "" } else { - x.ExternalName = string(r.DecodeString()) + yyv40 := &x.ExternalTrafficPolicy + yyv40.CodecDecodeSelf(d) + } + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l + } else { + yyb23 = r.CheckBreak() + } + if yyb23 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.HealthCheckNodePort = 0 + } else { + yyv41 := &x.HealthCheckNodePort + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*int32)(yyv41)) = int32(r.DecodeInt(32)) + } } for { - yyj2633++ - if yyhl2633 { - yyb2633 = yyj2633 > l + yyj23++ + if yyhl23 { + yyb23 = yyj23 > l } else { - yyb2633 = r.CheckBreak() + yyb23 = r.CheckBreak() } - if yyb2633 { + if yyb23 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2633-1, "") + z.DecStructFieldNotFound(yyj23-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -34631,38 +44321,38 @@ func (x *ServicePort) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2649 := z.EncBinary() - _ = yym2649 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2650 := !z.EncBinary() - yy2arr2650 := z.EncBasicHandle().StructToArray - var yyq2650 [5]bool - _, _, _ = yysep2650, yyq2650, yy2arr2650 - const yyr2650 bool = false - yyq2650[0] = x.Name != "" - yyq2650[1] = x.Protocol != "" - yyq2650[3] = true - yyq2650[4] = x.NodePort != 0 - var yynn2650 int - if yyr2650 || yy2arr2650 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[1] = x.Protocol != "" + yyq2[3] = true + yyq2[4] = x.NodePort != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn2650 = 1 - for _, b := range yyq2650 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2650++ + yynn2++ } } - r.EncodeMapStart(yynn2650) - yynn2650 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2650 || yy2arr2650 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2650[0] { - yym2652 := z.EncBinary() - _ = yym2652 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -34671,37 +44361,37 @@ func (x *ServicePort) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2650[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2653 := z.EncBinary() - _ = yym2653 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr2650 || yy2arr2650 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2650[1] { + if yyq2[1] { x.Protocol.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2650[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("protocol")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Protocol.CodecEncodeSelf(e) } } - if yyr2650 || yy2arr2650 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2656 := z.EncBinary() - _ = yym2656 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.Port)) @@ -34710,51 +44400,51 @@ func (x *ServicePort) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("port")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2657 := z.EncBinary() - _ = yym2657 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeInt(int64(x.Port)) } } - if yyr2650 || yy2arr2650 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2650[3] { - yy2659 := &x.TargetPort - yym2660 := z.EncBinary() - _ = yym2660 + if yyq2[3] { + yy13 := &x.TargetPort + yym14 := z.EncBinary() + _ = yym14 if false { - } else if z.HasExtensions() && z.EncExt(yy2659) { - } else if !yym2660 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2659) + } else if z.HasExtensions() && z.EncExt(yy13) { + } else if !yym14 && z.IsJSONHandle() { + z.EncJSONMarshal(yy13) } else { - z.EncFallback(yy2659) + z.EncFallback(yy13) } } else { r.EncodeNil() } } else { - if yyq2650[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("targetPort")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2661 := &x.TargetPort - yym2662 := z.EncBinary() - _ = yym2662 + yy15 := &x.TargetPort + yym16 := z.EncBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.EncExt(yy2661) { - } else if !yym2662 && z.IsJSONHandle() { - z.EncJSONMarshal(yy2661) + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) } else { - z.EncFallback(yy2661) + z.EncFallback(yy15) } } } - if yyr2650 || yy2arr2650 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2650[4] { - yym2664 := z.EncBinary() - _ = yym2664 + if yyq2[4] { + yym18 := z.EncBinary() + _ = yym18 if false { } else { r.EncodeInt(int64(x.NodePort)) @@ -34763,19 +44453,19 @@ func (x *ServicePort) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq2650[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nodePort")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2665 := z.EncBinary() - _ = yym2665 + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeInt(int64(x.NodePort)) } } } - if yyr2650 || yy2arr2650 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -34788,25 +44478,25 @@ func (x *ServicePort) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2666 := z.DecBinary() - _ = yym2666 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2667 := r.ContainerType() - if yyct2667 == codecSelferValueTypeMap1234 { - yyl2667 := r.ReadMapStart() - if yyl2667 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2667, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2667 == codecSelferValueTypeArray1234 { - yyl2667 := r.ReadArrayStart() - if yyl2667 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2667, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -34818,12 +44508,12 @@ func (x *ServicePort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2668Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2668Slc - var yyhl2668 bool = l >= 0 - for yyj2668 := 0; ; yyj2668++ { - if yyhl2668 { - if yyj2668 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -34832,53 +44522,72 @@ func (x *ServicePort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2668Slc = r.DecodeBytes(yys2668Slc, true, true) - yys2668 := string(yys2668Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2668 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "protocol": if r.TryDecodeAsNil() { x.Protocol = "" } else { - x.Protocol = Protocol(r.DecodeString()) + yyv6 := &x.Protocol + yyv6.CodecDecodeSelf(d) } case "port": if r.TryDecodeAsNil() { x.Port = 0 } else { - x.Port = int32(r.DecodeInt(32)) + yyv7 := &x.Port + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } } case "targetPort": if r.TryDecodeAsNil() { x.TargetPort = pkg4_intstr.IntOrString{} } else { - yyv2672 := &x.TargetPort - yym2673 := z.DecBinary() - _ = yym2673 + yyv9 := &x.TargetPort + yym10 := z.DecBinary() + _ = yym10 if false { - } else if z.HasExtensions() && z.DecExt(yyv2672) { - } else if !yym2673 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2672) + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) } else { - z.DecFallback(yyv2672, false) + z.DecFallback(yyv9, false) } } case "nodePort": if r.TryDecodeAsNil() { x.NodePort = 0 } else { - x.NodePort = int32(r.DecodeInt(32)) + yyv11 := &x.NodePort + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(yyv11)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys2668) - } // end switch yys2668 - } // end for yyj2668 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -34886,16 +44595,16 @@ func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2675 int - var yyb2675 bool - var yyhl2675 bool = l >= 0 - yyj2675++ - if yyhl2675 { - yyb2675 = yyj2675 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2675 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2675 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34903,15 +44612,21 @@ func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv14 := &x.Name + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj2675++ - if yyhl2675 { - yyb2675 = yyj2675 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2675 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2675 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34919,15 +44634,16 @@ func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Protocol = "" } else { - x.Protocol = Protocol(r.DecodeString()) + yyv16 := &x.Protocol + yyv16.CodecDecodeSelf(d) } - yyj2675++ - if yyhl2675 { - yyb2675 = yyj2675 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2675 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2675 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34935,15 +44651,21 @@ func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Port = 0 } else { - x.Port = int32(r.DecodeInt(32)) + yyv17 := &x.Port + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(yyv17)) = int32(r.DecodeInt(32)) + } } - yyj2675++ - if yyhl2675 { - yyb2675 = yyj2675 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2675 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2675 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34951,24 +44673,24 @@ func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TargetPort = pkg4_intstr.IntOrString{} } else { - yyv2679 := &x.TargetPort - yym2680 := z.DecBinary() - _ = yym2680 + yyv19 := &x.TargetPort + yym20 := z.DecBinary() + _ = yym20 if false { - } else if z.HasExtensions() && z.DecExt(yyv2679) { - } else if !yym2680 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv2679) + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv19) } else { - z.DecFallback(yyv2679, false) + z.DecFallback(yyv19, false) } } - yyj2675++ - if yyhl2675 { - yyb2675 = yyj2675 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2675 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2675 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -34976,20 +44698,26 @@ func (x *ServicePort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.NodePort = 0 } else { - x.NodePort = int32(r.DecodeInt(32)) + yyv21 := &x.NodePort + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } for { - yyj2675++ - if yyhl2675 { - yyb2675 = yyj2675 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb2675 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb2675 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2675-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -35001,39 +44729,39 @@ func (x *Service) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2682 := z.EncBinary() - _ = yym2682 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2683 := !z.EncBinary() - yy2arr2683 := z.EncBasicHandle().StructToArray - var yyq2683 [5]bool - _, _, _ = yysep2683, yyq2683, yy2arr2683 - const yyr2683 bool = false - yyq2683[0] = x.Kind != "" - yyq2683[1] = x.APIVersion != "" - yyq2683[2] = true - yyq2683[3] = true - yyq2683[4] = true - var yynn2683 int - if yyr2683 || yy2arr2683 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn2683 = 0 - for _, b := range yyq2683 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2683++ + yynn2++ } } - r.EncodeMapStart(yynn2683) - yynn2683 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2683 || yy2arr2683 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2683[0] { - yym2685 := z.EncBinary() - _ = yym2685 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -35042,23 +44770,23 @@ func (x *Service) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2683[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2686 := z.EncBinary() - _ = yym2686 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2683 || yy2arr2683 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2683[1] { - yym2688 := z.EncBinary() - _ = yym2688 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -35067,70 +44795,82 @@ func (x *Service) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2683[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2689 := z.EncBinary() - _ = yym2689 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2683 || yy2arr2683 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2683[2] { - yy2691 := &x.ObjectMeta - yy2691.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2683[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2692 := &x.ObjectMeta - yy2692.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2683 || yy2arr2683 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2683[3] { - yy2694 := &x.Spec - yy2694.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2683[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2695 := &x.Spec - yy2695.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr2683 || yy2arr2683 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2683[4] { - yy2697 := &x.Status - yy2697.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2683[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2698 := &x.Status - yy2698.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr2683 || yy2arr2683 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -35143,25 +44883,25 @@ func (x *Service) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2699 := z.DecBinary() - _ = yym2699 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2700 := r.ContainerType() - if yyct2700 == codecSelferValueTypeMap1234 { - yyl2700 := r.ReadMapStart() - if yyl2700 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2700, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2700 == codecSelferValueTypeArray1234 { - yyl2700 := r.ReadArrayStart() - if yyl2700 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2700, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -35173,12 +44913,12 @@ func (x *Service) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2701Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2701Slc - var yyhl2701 bool = l >= 0 - for yyj2701 := 0; ; yyj2701++ { - if yyhl2701 { - if yyj2701 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -35187,47 +44927,65 @@ func (x *Service) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2701Slc = r.DecodeBytes(yys2701Slc, true, true) - yys2701 := string(yys2701Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2701 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2704 := &x.ObjectMeta - yyv2704.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = ServiceSpec{} } else { - yyv2705 := &x.Spec - yyv2705.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = ServiceStatus{} } else { - yyv2706 := &x.Status - yyv2706.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2701) - } // end switch yys2701 - } // end for yyj2701 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -35235,16 +44993,16 @@ func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2707 int - var yyb2707 bool - var yyhl2707 bool = l >= 0 - yyj2707++ - if yyhl2707 { - yyb2707 = yyj2707 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2707 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2707 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35252,15 +45010,21 @@ func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2707++ - if yyhl2707 { - yyb2707 = yyj2707 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2707 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2707 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35268,32 +45032,44 @@ func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2707++ - if yyhl2707 { - yyb2707 = yyj2707 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2707 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2707 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2710 := &x.ObjectMeta - yyv2710.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj2707++ - if yyhl2707 { - yyb2707 = yyj2707 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2707 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2707 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35301,16 +45077,16 @@ func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = ServiceSpec{} } else { - yyv2711 := &x.Spec - yyv2711.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj2707++ - if yyhl2707 { - yyb2707 = yyj2707 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2707 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2707 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35318,21 +45094,21 @@ func (x *Service) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = ServiceStatus{} } else { - yyv2712 := &x.Status - yyv2712.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj2707++ - if yyhl2707 { - yyb2707 = yyj2707 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2707 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2707 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2707-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -35344,37 +45120,37 @@ func (x *ServiceList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2713 := z.EncBinary() - _ = yym2713 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2714 := !z.EncBinary() - yy2arr2714 := z.EncBasicHandle().StructToArray - var yyq2714 [4]bool - _, _, _ = yysep2714, yyq2714, yy2arr2714 - const yyr2714 bool = false - yyq2714[0] = x.Kind != "" - yyq2714[1] = x.APIVersion != "" - yyq2714[2] = true - var yynn2714 int - if yyr2714 || yy2arr2714 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2714 = 1 - for _, b := range yyq2714 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2714++ + yynn2++ } } - r.EncodeMapStart(yynn2714) - yynn2714 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2714 || yy2arr2714 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2714[0] { - yym2716 := z.EncBinary() - _ = yym2716 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -35383,23 +45159,23 @@ func (x *ServiceList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2714[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2717 := z.EncBinary() - _ = yym2717 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2714 || yy2arr2714 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2714[1] { - yym2719 := z.EncBinary() - _ = yym2719 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -35408,54 +45184,54 @@ func (x *ServiceList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2714[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2720 := z.EncBinary() - _ = yym2720 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2714 || yy2arr2714 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2714[2] { - yy2722 := &x.ListMeta - yym2723 := z.EncBinary() - _ = yym2723 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2722) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy2722) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2714[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2724 := &x.ListMeta - yym2725 := z.EncBinary() - _ = yym2725 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2724) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy2724) + z.EncFallback(yy12) } } } - if yyr2714 || yy2arr2714 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym2727 := z.EncBinary() - _ = yym2727 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceService(([]Service)(x.Items), e) @@ -35468,15 +45244,15 @@ func (x *ServiceList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym2728 := z.EncBinary() - _ = yym2728 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceService(([]Service)(x.Items), e) } } } - if yyr2714 || yy2arr2714 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -35489,25 +45265,25 @@ func (x *ServiceList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2729 := z.DecBinary() - _ = yym2729 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2730 := r.ContainerType() - if yyct2730 == codecSelferValueTypeMap1234 { - yyl2730 := r.ReadMapStart() - if yyl2730 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2730, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2730 == codecSelferValueTypeArray1234 { - yyl2730 := r.ReadArrayStart() - if yyl2730 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2730, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -35519,12 +45295,12 @@ func (x *ServiceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2731Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2731Slc - var yyhl2731 bool = l >= 0 - for yyj2731 := 0; ; yyj2731++ { - if yyhl2731 { - if yyj2731 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -35533,51 +45309,63 @@ func (x *ServiceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2731Slc = r.DecodeBytes(yys2731Slc, true, true) - yys2731 := string(yys2731Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2731 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2734 := &x.ListMeta - yym2735 := z.DecBinary() - _ = yym2735 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv2734) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv2734, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2736 := &x.Items - yym2737 := z.DecBinary() - _ = yym2737 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceService((*[]Service)(yyv2736), d) + h.decSliceService((*[]Service)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2731) - } // end switch yys2731 - } // end for yyj2731 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -35585,16 +45373,16 @@ func (x *ServiceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2738 int - var yyb2738 bool - var yyhl2738 bool = l >= 0 - yyj2738++ - if yyhl2738 { - yyb2738 = yyj2738 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2738 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2738 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35602,15 +45390,21 @@ func (x *ServiceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2738++ - if yyhl2738 { - yyb2738 = yyj2738 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2738 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2738 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35618,38 +45412,44 @@ func (x *ServiceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2738++ - if yyhl2738 { - yyb2738 = yyj2738 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2738 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2738 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2741 := &x.ListMeta - yym2742 := z.DecBinary() - _ = yym2742 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv2741) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv2741, false) + z.DecFallback(yyv17, false) } } - yyj2738++ - if yyhl2738 { - yyb2738 = yyj2738 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2738 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2738 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35657,26 +45457,26 @@ func (x *ServiceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2743 := &x.Items - yym2744 := z.DecBinary() - _ = yym2744 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceService((*[]Service)(yyv2743), d) + h.decSliceService((*[]Service)(yyv19), d) } } for { - yyj2738++ - if yyhl2738 { - yyb2738 = yyj2738 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2738 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2738 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2738-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -35688,39 +45488,40 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2745 := z.EncBinary() - _ = yym2745 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2746 := !z.EncBinary() - yy2arr2746 := z.EncBasicHandle().StructToArray - var yyq2746 [5]bool - _, _, _ = yysep2746, yyq2746, yy2arr2746 - const yyr2746 bool = false - yyq2746[0] = x.Kind != "" - yyq2746[1] = x.APIVersion != "" - yyq2746[2] = true - yyq2746[3] = len(x.Secrets) != 0 - yyq2746[4] = len(x.ImagePullSecrets) != 0 - var yynn2746 int - if yyr2746 || yy2arr2746 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Secrets) != 0 + yyq2[4] = len(x.ImagePullSecrets) != 0 + yyq2[5] = x.AutomountServiceAccountToken != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) } else { - yynn2746 = 0 - for _, b := range yyq2746 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2746++ + yynn2++ } } - r.EncodeMapStart(yynn2746) - yynn2746 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2746 || yy2arr2746 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2746[0] { - yym2748 := z.EncBinary() - _ = yym2748 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -35729,23 +45530,23 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2746[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2749 := z.EncBinary() - _ = yym2749 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2746 || yy2arr2746 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2746[1] { - yym2751 := z.EncBinary() - _ = yym2751 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -35754,43 +45555,55 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2746[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2752 := z.EncBinary() - _ = yym2752 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2746 || yy2arr2746 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2746[2] { - yy2754 := &x.ObjectMeta - yy2754.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2746[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2755 := &x.ObjectMeta - yy2755.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2746 || yy2arr2746 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2746[3] { + if yyq2[3] { if x.Secrets == nil { r.EncodeNil() } else { - yym2757 := z.EncBinary() - _ = yym2757 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e) @@ -35800,15 +45613,15 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2746[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secrets")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Secrets == nil { r.EncodeNil() } else { - yym2758 := z.EncBinary() - _ = yym2758 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceObjectReference(([]ObjectReference)(x.Secrets), e) @@ -35816,14 +45629,14 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2746 || yy2arr2746 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2746[4] { + if yyq2[4] { if x.ImagePullSecrets == nil { r.EncodeNil() } else { - yym2760 := z.EncBinary() - _ = yym2760 + yym18 := z.EncBinary() + _ = yym18 if false { } else { h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) @@ -35833,15 +45646,15 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2746[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("imagePullSecrets")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ImagePullSecrets == nil { r.EncodeNil() } else { - yym2761 := z.EncBinary() - _ = yym2761 + yym19 := z.EncBinary() + _ = yym19 if false { } else { h.encSliceLocalObjectReference(([]LocalObjectReference)(x.ImagePullSecrets), e) @@ -35849,7 +45662,42 @@ func (x *ServiceAccount) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2746 || yy2arr2746 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + if x.AutomountServiceAccountToken == nil { + r.EncodeNil() + } else { + yy21 := *x.AutomountServiceAccountToken + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeBool(bool(yy21)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("automountServiceAccountToken")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.AutomountServiceAccountToken == nil { + r.EncodeNil() + } else { + yy23 := *x.AutomountServiceAccountToken + yym24 := z.EncBinary() + _ = yym24 + if false { + } else { + r.EncodeBool(bool(yy23)) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -35862,25 +45710,25 @@ func (x *ServiceAccount) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2762 := z.DecBinary() - _ = yym2762 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2763 := r.ContainerType() - if yyct2763 == codecSelferValueTypeMap1234 { - yyl2763 := r.ReadMapStart() - if yyl2763 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2763, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2763 == codecSelferValueTypeArray1234 { - yyl2763 := r.ReadArrayStart() - if yyl2763 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2763, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -35892,12 +45740,12 @@ func (x *ServiceAccount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2764Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2764Slc - var yyhl2764 bool = l >= 0 - for yyj2764 := 0; ; yyj2764++ { - if yyhl2764 { - if yyj2764 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -35906,57 +45754,91 @@ func (x *ServiceAccount) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2764Slc = r.DecodeBytes(yys2764Slc, true, true) - yys2764 := string(yys2764Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2764 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2767 := &x.ObjectMeta - yyv2767.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "secrets": if r.TryDecodeAsNil() { x.Secrets = nil } else { - yyv2768 := &x.Secrets - yym2769 := z.DecBinary() - _ = yym2769 + yyv10 := &x.Secrets + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceObjectReference((*[]ObjectReference)(yyv2768), d) + h.decSliceObjectReference((*[]ObjectReference)(yyv10), d) } } case "imagePullSecrets": if r.TryDecodeAsNil() { x.ImagePullSecrets = nil } else { - yyv2770 := &x.ImagePullSecrets - yym2771 := z.DecBinary() - _ = yym2771 + yyv12 := &x.ImagePullSecrets + yym13 := z.DecBinary() + _ = yym13 if false { } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2770), d) + h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv12), d) + } + } + case "automountServiceAccountToken": + if r.TryDecodeAsNil() { + if x.AutomountServiceAccountToken != nil { + x.AutomountServiceAccountToken = nil + } + } else { + if x.AutomountServiceAccountToken == nil { + x.AutomountServiceAccountToken = new(bool) + } + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(x.AutomountServiceAccountToken)) = r.DecodeBool() } } default: - z.DecStructFieldNotFound(-1, yys2764) - } // end switch yys2764 - } // end for yyj2764 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -35964,16 +45846,16 @@ func (x *ServiceAccount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2772 int - var yyb2772 bool - var yyhl2772 bool = l >= 0 - yyj2772++ - if yyhl2772 { - yyb2772 = yyj2772 > l + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2772 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2772 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35981,15 +45863,21 @@ func (x *ServiceAccount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv17 := &x.Kind + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj2772++ - if yyhl2772 { - yyb2772 = yyj2772 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2772 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2772 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -35997,32 +45885,44 @@ func (x *ServiceAccount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv19 := &x.APIVersion + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } - yyj2772++ - if yyhl2772 { - yyb2772 = yyj2772 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2772 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2772 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2775 := &x.ObjectMeta - yyv2775.CodecDecodeSelf(d) + yyv21 := &x.ObjectMeta + yym22 := z.DecBinary() + _ = yym22 + if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else { + z.DecFallback(yyv21, false) + } } - yyj2772++ - if yyhl2772 { - yyb2772 = yyj2772 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2772 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2772 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36030,21 +45930,21 @@ func (x *ServiceAccount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Secrets = nil } else { - yyv2776 := &x.Secrets - yym2777 := z.DecBinary() - _ = yym2777 + yyv23 := &x.Secrets + yym24 := z.DecBinary() + _ = yym24 if false { } else { - h.decSliceObjectReference((*[]ObjectReference)(yyv2776), d) + h.decSliceObjectReference((*[]ObjectReference)(yyv23), d) } } - yyj2772++ - if yyhl2772 { - yyb2772 = yyj2772 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2772 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2772 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36052,26 +45952,52 @@ func (x *ServiceAccount) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ImagePullSecrets = nil } else { - yyv2778 := &x.ImagePullSecrets - yym2779 := z.DecBinary() - _ = yym2779 + yyv25 := &x.ImagePullSecrets + yym26 := z.DecBinary() + _ = yym26 if false { } else { - h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv2778), d) + h.decSliceLocalObjectReference((*[]LocalObjectReference)(yyv25), d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.AutomountServiceAccountToken != nil { + x.AutomountServiceAccountToken = nil + } + } else { + if x.AutomountServiceAccountToken == nil { + x.AutomountServiceAccountToken = new(bool) + } + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(x.AutomountServiceAccountToken)) = r.DecodeBool() } } for { - yyj2772++ - if yyhl2772 { - yyb2772 = yyj2772 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb2772 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb2772 { + if yyb16 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2772-1, "") + z.DecStructFieldNotFound(yyj16-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -36083,37 +46009,37 @@ func (x *ServiceAccountList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2780 := z.EncBinary() - _ = yym2780 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2781 := !z.EncBinary() - yy2arr2781 := z.EncBasicHandle().StructToArray - var yyq2781 [4]bool - _, _, _ = yysep2781, yyq2781, yy2arr2781 - const yyr2781 bool = false - yyq2781[0] = x.Kind != "" - yyq2781[1] = x.APIVersion != "" - yyq2781[2] = true - var yynn2781 int - if yyr2781 || yy2arr2781 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2781 = 1 - for _, b := range yyq2781 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2781++ + yynn2++ } } - r.EncodeMapStart(yynn2781) - yynn2781 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2781 || yy2arr2781 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2781[0] { - yym2783 := z.EncBinary() - _ = yym2783 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -36122,23 +46048,23 @@ func (x *ServiceAccountList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2781[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2784 := z.EncBinary() - _ = yym2784 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2781 || yy2arr2781 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2781[1] { - yym2786 := z.EncBinary() - _ = yym2786 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -36147,54 +46073,54 @@ func (x *ServiceAccountList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2781[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2787 := z.EncBinary() - _ = yym2787 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2781 || yy2arr2781 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2781[2] { - yy2789 := &x.ListMeta - yym2790 := z.EncBinary() - _ = yym2790 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2789) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy2789) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2781[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2791 := &x.ListMeta - yym2792 := z.EncBinary() - _ = yym2792 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2791) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy2791) + z.EncFallback(yy12) } } } - if yyr2781 || yy2arr2781 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym2794 := z.EncBinary() - _ = yym2794 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceServiceAccount(([]ServiceAccount)(x.Items), e) @@ -36207,15 +46133,15 @@ func (x *ServiceAccountList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym2795 := z.EncBinary() - _ = yym2795 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceServiceAccount(([]ServiceAccount)(x.Items), e) } } } - if yyr2781 || yy2arr2781 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -36228,25 +46154,25 @@ func (x *ServiceAccountList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2796 := z.DecBinary() - _ = yym2796 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2797 := r.ContainerType() - if yyct2797 == codecSelferValueTypeMap1234 { - yyl2797 := r.ReadMapStart() - if yyl2797 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2797, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2797 == codecSelferValueTypeArray1234 { - yyl2797 := r.ReadArrayStart() - if yyl2797 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2797, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -36258,12 +46184,12 @@ func (x *ServiceAccountList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2798Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2798Slc - var yyhl2798 bool = l >= 0 - for yyj2798 := 0; ; yyj2798++ { - if yyhl2798 { - if yyj2798 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -36272,51 +46198,63 @@ func (x *ServiceAccountList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2798Slc = r.DecodeBytes(yys2798Slc, true, true) - yys2798 := string(yys2798Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2798 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2801 := &x.ListMeta - yym2802 := z.DecBinary() - _ = yym2802 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv2801) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv2801, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2803 := &x.Items - yym2804 := z.DecBinary() - _ = yym2804 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceServiceAccount((*[]ServiceAccount)(yyv2803), d) + h.decSliceServiceAccount((*[]ServiceAccount)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2798) - } // end switch yys2798 - } // end for yyj2798 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -36324,16 +46262,16 @@ func (x *ServiceAccountList) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2805 int - var yyb2805 bool - var yyhl2805 bool = l >= 0 - yyj2805++ - if yyhl2805 { - yyb2805 = yyj2805 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2805 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2805 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36341,15 +46279,21 @@ func (x *ServiceAccountList) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2805++ - if yyhl2805 { - yyb2805 = yyj2805 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2805 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2805 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36357,38 +46301,44 @@ func (x *ServiceAccountList) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2805++ - if yyhl2805 { - yyb2805 = yyj2805 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2805 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2805 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2808 := &x.ListMeta - yym2809 := z.DecBinary() - _ = yym2809 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv2808) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv2808, false) + z.DecFallback(yyv17, false) } } - yyj2805++ - if yyhl2805 { - yyb2805 = yyj2805 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2805 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2805 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36396,26 +46346,26 @@ func (x *ServiceAccountList) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2810 := &x.Items - yym2811 := z.DecBinary() - _ = yym2811 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceServiceAccount((*[]ServiceAccount)(yyv2810), d) + h.decSliceServiceAccount((*[]ServiceAccount)(yyv19), d) } } for { - yyj2805++ - if yyhl2805 { - yyb2805 = yyj2805 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2805 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2805 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2805-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -36427,37 +46377,37 @@ func (x *Endpoints) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2812 := z.EncBinary() - _ = yym2812 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2813 := !z.EncBinary() - yy2arr2813 := z.EncBasicHandle().StructToArray - var yyq2813 [4]bool - _, _, _ = yysep2813, yyq2813, yy2arr2813 - const yyr2813 bool = false - yyq2813[0] = x.Kind != "" - yyq2813[1] = x.APIVersion != "" - yyq2813[2] = true - var yynn2813 int - if yyr2813 || yy2arr2813 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2813 = 1 - for _, b := range yyq2813 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2813++ + yynn2++ } } - r.EncodeMapStart(yynn2813) - yynn2813 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2813 || yy2arr2813 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2813[0] { - yym2815 := z.EncBinary() - _ = yym2815 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -36466,23 +46416,23 @@ func (x *Endpoints) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2813[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2816 := z.EncBinary() - _ = yym2816 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2813 || yy2arr2813 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2813[1] { - yym2818 := z.EncBinary() - _ = yym2818 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -36491,42 +46441,54 @@ func (x *Endpoints) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2813[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2819 := z.EncBinary() - _ = yym2819 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2813 || yy2arr2813 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2813[2] { - yy2821 := &x.ObjectMeta - yy2821.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq2813[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2822 := &x.ObjectMeta - yy2822.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr2813 || yy2arr2813 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Subsets == nil { r.EncodeNil() } else { - yym2824 := z.EncBinary() - _ = yym2824 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceEndpointSubset(([]EndpointSubset)(x.Subsets), e) @@ -36539,15 +46501,15 @@ func (x *Endpoints) CodecEncodeSelf(e *codec1978.Encoder) { if x.Subsets == nil { r.EncodeNil() } else { - yym2825 := z.EncBinary() - _ = yym2825 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceEndpointSubset(([]EndpointSubset)(x.Subsets), e) } } } - if yyr2813 || yy2arr2813 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -36560,25 +46522,25 @@ func (x *Endpoints) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2826 := z.DecBinary() - _ = yym2826 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2827 := r.ContainerType() - if yyct2827 == codecSelferValueTypeMap1234 { - yyl2827 := r.ReadMapStart() - if yyl2827 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2827, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2827 == codecSelferValueTypeArray1234 { - yyl2827 := r.ReadArrayStart() - if yyl2827 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2827, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -36590,12 +46552,12 @@ func (x *Endpoints) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2828Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2828Slc - var yyhl2828 bool = l >= 0 - for yyj2828 := 0; ; yyj2828++ { - if yyhl2828 { - if yyj2828 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -36604,45 +46566,63 @@ func (x *Endpoints) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2828Slc = r.DecodeBytes(yys2828Slc, true, true) - yys2828 := string(yys2828Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2828 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2831 := &x.ObjectMeta - yyv2831.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "subsets": if r.TryDecodeAsNil() { x.Subsets = nil } else { - yyv2832 := &x.Subsets - yym2833 := z.DecBinary() - _ = yym2833 + yyv10 := &x.Subsets + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceEndpointSubset((*[]EndpointSubset)(yyv2832), d) + h.decSliceEndpointSubset((*[]EndpointSubset)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2828) - } // end switch yys2828 - } // end for yyj2828 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -36650,16 +46630,16 @@ func (x *Endpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2834 int - var yyb2834 bool - var yyhl2834 bool = l >= 0 - yyj2834++ - if yyhl2834 { - yyb2834 = yyj2834 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2834 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2834 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36667,15 +46647,21 @@ func (x *Endpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2834++ - if yyhl2834 { - yyb2834 = yyj2834 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2834 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2834 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36683,32 +46669,44 @@ func (x *Endpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2834++ - if yyhl2834 { - yyb2834 = yyj2834 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2834 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2834 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv2837 := &x.ObjectMeta - yyv2837.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj2834++ - if yyhl2834 { - yyb2834 = yyj2834 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2834 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2834 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36716,26 +46714,26 @@ func (x *Endpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Subsets = nil } else { - yyv2838 := &x.Subsets - yym2839 := z.DecBinary() - _ = yym2839 + yyv19 := &x.Subsets + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceEndpointSubset((*[]EndpointSubset)(yyv2838), d) + h.decSliceEndpointSubset((*[]EndpointSubset)(yyv19), d) } } for { - yyj2834++ - if yyhl2834 { - yyb2834 = yyj2834 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2834 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2834 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2834-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -36747,40 +46745,40 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2840 := z.EncBinary() - _ = yym2840 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2841 := !z.EncBinary() - yy2arr2841 := z.EncBasicHandle().StructToArray - var yyq2841 [3]bool - _, _, _ = yysep2841, yyq2841, yy2arr2841 - const yyr2841 bool = false - yyq2841[0] = len(x.Addresses) != 0 - yyq2841[1] = len(x.NotReadyAddresses) != 0 - yyq2841[2] = len(x.Ports) != 0 - var yynn2841 int - if yyr2841 || yy2arr2841 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Addresses) != 0 + yyq2[1] = len(x.NotReadyAddresses) != 0 + yyq2[2] = len(x.Ports) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn2841 = 0 - for _, b := range yyq2841 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2841++ + yynn2++ } } - r.EncodeMapStart(yynn2841) - yynn2841 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2841 || yy2arr2841 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2841[0] { + if yyq2[0] { if x.Addresses == nil { r.EncodeNil() } else { - yym2843 := z.EncBinary() - _ = yym2843 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e) @@ -36790,15 +46788,15 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2841[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("addresses")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Addresses == nil { r.EncodeNil() } else { - yym2844 := z.EncBinary() - _ = yym2844 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceEndpointAddress(([]EndpointAddress)(x.Addresses), e) @@ -36806,14 +46804,14 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2841 || yy2arr2841 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2841[1] { + if yyq2[1] { if x.NotReadyAddresses == nil { r.EncodeNil() } else { - yym2846 := z.EncBinary() - _ = yym2846 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e) @@ -36823,15 +46821,15 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2841[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("notReadyAddresses")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.NotReadyAddresses == nil { r.EncodeNil() } else { - yym2847 := z.EncBinary() - _ = yym2847 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceEndpointAddress(([]EndpointAddress)(x.NotReadyAddresses), e) @@ -36839,14 +46837,14 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2841 || yy2arr2841 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2841[2] { + if yyq2[2] { if x.Ports == nil { r.EncodeNil() } else { - yym2849 := z.EncBinary() - _ = yym2849 + yym10 := z.EncBinary() + _ = yym10 if false { } else { h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e) @@ -36856,15 +46854,15 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2841[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ports")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ports == nil { r.EncodeNil() } else { - yym2850 := z.EncBinary() - _ = yym2850 + yym11 := z.EncBinary() + _ = yym11 if false { } else { h.encSliceEndpointPort(([]EndpointPort)(x.Ports), e) @@ -36872,7 +46870,7 @@ func (x *EndpointSubset) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2841 || yy2arr2841 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -36885,25 +46883,25 @@ func (x *EndpointSubset) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2851 := z.DecBinary() - _ = yym2851 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2852 := r.ContainerType() - if yyct2852 == codecSelferValueTypeMap1234 { - yyl2852 := r.ReadMapStart() - if yyl2852 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2852, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2852 == codecSelferValueTypeArray1234 { - yyl2852 := r.ReadArrayStart() - if yyl2852 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2852, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -36915,12 +46913,12 @@ func (x *EndpointSubset) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2853Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2853Slc - var yyhl2853 bool = l >= 0 - for yyj2853 := 0; ; yyj2853++ { - if yyhl2853 { - if yyj2853 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -36929,50 +46927,50 @@ func (x *EndpointSubset) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2853Slc = r.DecodeBytes(yys2853Slc, true, true) - yys2853 := string(yys2853Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2853 { + switch yys3 { case "addresses": if r.TryDecodeAsNil() { x.Addresses = nil } else { - yyv2854 := &x.Addresses - yym2855 := z.DecBinary() - _ = yym2855 + yyv4 := &x.Addresses + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2854), d) + h.decSliceEndpointAddress((*[]EndpointAddress)(yyv4), d) } } case "notReadyAddresses": if r.TryDecodeAsNil() { x.NotReadyAddresses = nil } else { - yyv2856 := &x.NotReadyAddresses - yym2857 := z.DecBinary() - _ = yym2857 + yyv6 := &x.NotReadyAddresses + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2856), d) + h.decSliceEndpointAddress((*[]EndpointAddress)(yyv6), d) } } case "ports": if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv2858 := &x.Ports - yym2859 := z.DecBinary() - _ = yym2859 + yyv8 := &x.Ports + yym9 := z.DecBinary() + _ = yym9 if false { } else { - h.decSliceEndpointPort((*[]EndpointPort)(yyv2858), d) + h.decSliceEndpointPort((*[]EndpointPort)(yyv8), d) } } default: - z.DecStructFieldNotFound(-1, yys2853) - } // end switch yys2853 - } // end for yyj2853 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -36980,16 +46978,16 @@ func (x *EndpointSubset) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2860 int - var yyb2860 bool - var yyhl2860 bool = l >= 0 - yyj2860++ - if yyhl2860 { - yyb2860 = yyj2860 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb2860 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb2860 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -36997,21 +46995,21 @@ func (x *EndpointSubset) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Addresses = nil } else { - yyv2861 := &x.Addresses - yym2862 := z.DecBinary() - _ = yym2862 + yyv11 := &x.Addresses + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2861), d) + h.decSliceEndpointAddress((*[]EndpointAddress)(yyv11), d) } } - yyj2860++ - if yyhl2860 { - yyb2860 = yyj2860 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb2860 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb2860 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37019,21 +47017,21 @@ func (x *EndpointSubset) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.NotReadyAddresses = nil } else { - yyv2863 := &x.NotReadyAddresses - yym2864 := z.DecBinary() - _ = yym2864 + yyv13 := &x.NotReadyAddresses + yym14 := z.DecBinary() + _ = yym14 if false { } else { - h.decSliceEndpointAddress((*[]EndpointAddress)(yyv2863), d) + h.decSliceEndpointAddress((*[]EndpointAddress)(yyv13), d) } } - yyj2860++ - if yyhl2860 { - yyb2860 = yyj2860 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb2860 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb2860 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37041,26 +47039,26 @@ func (x *EndpointSubset) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv2865 := &x.Ports - yym2866 := z.DecBinary() - _ = yym2866 + yyv15 := &x.Ports + yym16 := z.DecBinary() + _ = yym16 if false { } else { - h.decSliceEndpointPort((*[]EndpointPort)(yyv2865), d) + h.decSliceEndpointPort((*[]EndpointPort)(yyv15), d) } } for { - yyj2860++ - if yyhl2860 { - yyb2860 = yyj2860 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb2860 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb2860 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2860-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -37072,36 +47070,36 @@ func (x *EndpointAddress) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2867 := z.EncBinary() - _ = yym2867 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2868 := !z.EncBinary() - yy2arr2868 := z.EncBasicHandle().StructToArray - var yyq2868 [4]bool - _, _, _ = yysep2868, yyq2868, yy2arr2868 - const yyr2868 bool = false - yyq2868[1] = x.Hostname != "" - yyq2868[2] = x.NodeName != nil - yyq2868[3] = x.TargetRef != nil - var yynn2868 int - if yyr2868 || yy2arr2868 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Hostname != "" + yyq2[2] = x.NodeName != nil + yyq2[3] = x.TargetRef != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2868 = 1 - for _, b := range yyq2868 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2868++ + yynn2++ } } - r.EncodeMapStart(yynn2868) - yynn2868 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2868 || yy2arr2868 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2870 := z.EncBinary() - _ = yym2870 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.IP)) @@ -37110,18 +47108,18 @@ func (x *EndpointAddress) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ip")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2871 := z.EncBinary() - _ = yym2871 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.IP)) } } - if yyr2868 || yy2arr2868 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2868[1] { - yym2873 := z.EncBinary() - _ = yym2873 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) @@ -37130,56 +47128,56 @@ func (x *EndpointAddress) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2868[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostname")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2874 := z.EncBinary() - _ = yym2874 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Hostname)) } } } - if yyr2868 || yy2arr2868 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2868[2] { + if yyq2[2] { if x.NodeName == nil { r.EncodeNil() } else { - yy2876 := *x.NodeName - yym2877 := z.EncBinary() - _ = yym2877 + yy10 := *x.NodeName + yym11 := z.EncBinary() + _ = yym11 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yy2876)) + r.EncodeString(codecSelferC_UTF81234, string(yy10)) } } } else { r.EncodeNil() } } else { - if yyq2868[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nodeName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.NodeName == nil { r.EncodeNil() } else { - yy2878 := *x.NodeName - yym2879 := z.EncBinary() - _ = yym2879 + yy12 := *x.NodeName + yym13 := z.EncBinary() + _ = yym13 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yy2878)) + r.EncodeString(codecSelferC_UTF81234, string(yy12)) } } } } - if yyr2868 || yy2arr2868 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2868[3] { + if yyq2[3] { if x.TargetRef == nil { r.EncodeNil() } else { @@ -37189,7 +47187,7 @@ func (x *EndpointAddress) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2868[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("targetRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -37200,7 +47198,7 @@ func (x *EndpointAddress) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr2868 || yy2arr2868 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -37213,25 +47211,25 @@ func (x *EndpointAddress) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2881 := z.DecBinary() - _ = yym2881 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2882 := r.ContainerType() - if yyct2882 == codecSelferValueTypeMap1234 { - yyl2882 := r.ReadMapStart() - if yyl2882 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2882, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2882 == codecSelferValueTypeArray1234 { - yyl2882 := r.ReadArrayStart() - if yyl2882 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2882, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -37243,12 +47241,12 @@ func (x *EndpointAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2883Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2883Slc - var yyhl2883 bool = l >= 0 - for yyj2883 := 0; ; yyj2883++ { - if yyhl2883 { - if yyj2883 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -37257,21 +47255,33 @@ func (x *EndpointAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2883Slc = r.DecodeBytes(yys2883Slc, true, true) - yys2883 := string(yys2883Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2883 { + switch yys3 { case "ip": if r.TryDecodeAsNil() { x.IP = "" } else { - x.IP = string(r.DecodeString()) + yyv4 := &x.IP + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "hostname": if r.TryDecodeAsNil() { x.Hostname = "" } else { - x.Hostname = string(r.DecodeString()) + yyv6 := &x.Hostname + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "nodeName": if r.TryDecodeAsNil() { @@ -37282,8 +47292,8 @@ func (x *EndpointAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.NodeName == nil { x.NodeName = new(string) } - yym2887 := z.DecBinary() - _ = yym2887 + yym9 := z.DecBinary() + _ = yym9 if false { } else { *((*string)(x.NodeName)) = r.DecodeString() @@ -37301,9 +47311,9 @@ func (x *EndpointAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.TargetRef.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2883) - } // end switch yys2883 - } // end for yyj2883 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -37311,16 +47321,16 @@ func (x *EndpointAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2889 int - var yyb2889 bool - var yyhl2889 bool = l >= 0 - yyj2889++ - if yyhl2889 { - yyb2889 = yyj2889 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2889 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2889 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37328,15 +47338,21 @@ func (x *EndpointAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.IP = "" } else { - x.IP = string(r.DecodeString()) + yyv12 := &x.IP + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj2889++ - if yyhl2889 { - yyb2889 = yyj2889 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2889 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2889 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37344,15 +47360,21 @@ func (x *EndpointAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Hostname = "" } else { - x.Hostname = string(r.DecodeString()) + yyv14 := &x.Hostname + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj2889++ - if yyhl2889 { - yyb2889 = yyj2889 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2889 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2889 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37365,20 +47387,20 @@ func (x *EndpointAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if x.NodeName == nil { x.NodeName = new(string) } - yym2893 := z.DecBinary() - _ = yym2893 + yym17 := z.DecBinary() + _ = yym17 if false { } else { *((*string)(x.NodeName)) = r.DecodeString() } } - yyj2889++ - if yyhl2889 { - yyb2889 = yyj2889 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2889 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2889 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37394,17 +47416,17 @@ func (x *EndpointAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) x.TargetRef.CodecDecodeSelf(d) } for { - yyj2889++ - if yyhl2889 { - yyb2889 = yyj2889 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb2889 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb2889 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2889-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -37416,36 +47438,36 @@ func (x *EndpointPort) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2895 := z.EncBinary() - _ = yym2895 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2896 := !z.EncBinary() - yy2arr2896 := z.EncBasicHandle().StructToArray - var yyq2896 [3]bool - _, _, _ = yysep2896, yyq2896, yy2arr2896 - const yyr2896 bool = false - yyq2896[0] = x.Name != "" - yyq2896[2] = x.Protocol != "" - var yynn2896 int - if yyr2896 || yy2arr2896 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + yyq2[2] = x.Protocol != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn2896 = 1 - for _, b := range yyq2896 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2896++ + yynn2++ } } - r.EncodeMapStart(yynn2896) - yynn2896 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2896 || yy2arr2896 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2896[0] { - yym2898 := z.EncBinary() - _ = yym2898 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -37454,22 +47476,22 @@ func (x *EndpointPort) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2896[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2899 := z.EncBinary() - _ = yym2899 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr2896 || yy2arr2896 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2901 := z.EncBinary() - _ = yym2901 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.Port)) @@ -37478,29 +47500,29 @@ func (x *EndpointPort) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("port")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2902 := z.EncBinary() - _ = yym2902 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.Port)) } } - if yyr2896 || yy2arr2896 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2896[2] { + if yyq2[2] { x.Protocol.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2896[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("protocol")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Protocol.CodecEncodeSelf(e) } } - if yyr2896 || yy2arr2896 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -37513,25 +47535,25 @@ func (x *EndpointPort) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2904 := z.DecBinary() - _ = yym2904 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2905 := r.ContainerType() - if yyct2905 == codecSelferValueTypeMap1234 { - yyl2905 := r.ReadMapStart() - if yyl2905 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2905, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2905 == codecSelferValueTypeArray1234 { - yyl2905 := r.ReadArrayStart() - if yyl2905 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2905, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -37543,12 +47565,12 @@ func (x *EndpointPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2906Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2906Slc - var yyhl2906 bool = l >= 0 - for yyj2906 := 0; ; yyj2906++ { - if yyhl2906 { - if yyj2906 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -37557,32 +47579,45 @@ func (x *EndpointPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2906Slc = r.DecodeBytes(yys2906Slc, true, true) - yys2906 := string(yys2906Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2906 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "port": if r.TryDecodeAsNil() { x.Port = 0 } else { - x.Port = int32(r.DecodeInt(32)) + yyv6 := &x.Port + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } case "protocol": if r.TryDecodeAsNil() { x.Protocol = "" } else { - x.Protocol = Protocol(r.DecodeString()) + yyv8 := &x.Protocol + yyv8.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2906) - } // end switch yys2906 - } // end for yyj2906 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -37590,16 +47625,16 @@ func (x *EndpointPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2910 int - var yyb2910 bool - var yyhl2910 bool = l >= 0 - yyj2910++ - if yyhl2910 { - yyb2910 = yyj2910 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb2910 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb2910 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37607,15 +47642,21 @@ func (x *EndpointPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } - yyj2910++ - if yyhl2910 { - yyb2910 = yyj2910 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb2910 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb2910 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37623,15 +47664,21 @@ func (x *EndpointPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Port = 0 } else { - x.Port = int32(r.DecodeInt(32)) + yyv12 := &x.Port + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(yyv12)) = int32(r.DecodeInt(32)) + } } - yyj2910++ - if yyhl2910 { - yyb2910 = yyj2910 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb2910 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb2910 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37639,20 +47686,21 @@ func (x *EndpointPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Protocol = "" } else { - x.Protocol = Protocol(r.DecodeString()) + yyv14 := &x.Protocol + yyv14.CodecDecodeSelf(d) } for { - yyj2910++ - if yyhl2910 { - yyb2910 = yyj2910 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb2910 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb2910 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2910-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -37664,37 +47712,37 @@ func (x *EndpointsList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2914 := z.EncBinary() - _ = yym2914 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2915 := !z.EncBinary() - yy2arr2915 := z.EncBasicHandle().StructToArray - var yyq2915 [4]bool - _, _, _ = yysep2915, yyq2915, yy2arr2915 - const yyr2915 bool = false - yyq2915[0] = x.Kind != "" - yyq2915[1] = x.APIVersion != "" - yyq2915[2] = true - var yynn2915 int - if yyr2915 || yy2arr2915 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn2915 = 1 - for _, b := range yyq2915 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2915++ + yynn2++ } } - r.EncodeMapStart(yynn2915) - yynn2915 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2915 || yy2arr2915 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2915[0] { - yym2917 := z.EncBinary() - _ = yym2917 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -37703,23 +47751,23 @@ func (x *EndpointsList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2915[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2918 := z.EncBinary() - _ = yym2918 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr2915 || yy2arr2915 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2915[1] { - yym2920 := z.EncBinary() - _ = yym2920 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -37728,54 +47776,54 @@ func (x *EndpointsList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2915[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2921 := z.EncBinary() - _ = yym2921 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr2915 || yy2arr2915 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2915[2] { - yy2923 := &x.ListMeta - yym2924 := z.EncBinary() - _ = yym2924 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy2923) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy2923) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq2915[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2925 := &x.ListMeta - yym2926 := z.EncBinary() - _ = yym2926 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy2925) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy2925) + z.EncFallback(yy12) } } } - if yyr2915 || yy2arr2915 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym2928 := z.EncBinary() - _ = yym2928 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceEndpoints(([]Endpoints)(x.Items), e) @@ -37788,15 +47836,15 @@ func (x *EndpointsList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym2929 := z.EncBinary() - _ = yym2929 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceEndpoints(([]Endpoints)(x.Items), e) } } } - if yyr2915 || yy2arr2915 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -37809,25 +47857,25 @@ func (x *EndpointsList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2930 := z.DecBinary() - _ = yym2930 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2931 := r.ContainerType() - if yyct2931 == codecSelferValueTypeMap1234 { - yyl2931 := r.ReadMapStart() - if yyl2931 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2931, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2931 == codecSelferValueTypeArray1234 { - yyl2931 := r.ReadArrayStart() - if yyl2931 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2931, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -37839,12 +47887,12 @@ func (x *EndpointsList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2932Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2932Slc - var yyhl2932 bool = l >= 0 - for yyj2932 := 0; ; yyj2932++ { - if yyhl2932 { - if yyj2932 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -37853,51 +47901,63 @@ func (x *EndpointsList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2932Slc = r.DecodeBytes(yys2932Slc, true, true) - yys2932 := string(yys2932Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2932 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2935 := &x.ListMeta - yym2936 := z.DecBinary() - _ = yym2936 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv2935) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv2935, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2937 := &x.Items - yym2938 := z.DecBinary() - _ = yym2938 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceEndpoints((*[]Endpoints)(yyv2937), d) + h.decSliceEndpoints((*[]Endpoints)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys2932) - } // end switch yys2932 - } // end for yyj2932 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -37905,16 +47965,16 @@ func (x *EndpointsList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2939 int - var yyb2939 bool - var yyhl2939 bool = l >= 0 - yyj2939++ - if yyhl2939 { - yyb2939 = yyj2939 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2939 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2939 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37922,15 +47982,21 @@ func (x *EndpointsList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj2939++ - if yyhl2939 { - yyb2939 = yyj2939 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2939 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2939 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37938,38 +48004,44 @@ func (x *EndpointsList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2939++ - if yyhl2939 { - yyb2939 = yyj2939 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2939 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2939 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv2942 := &x.ListMeta - yym2943 := z.DecBinary() - _ = yym2943 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv2942) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv2942, false) + z.DecFallback(yyv17, false) } } - yyj2939++ - if yyhl2939 { - yyb2939 = yyj2939 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2939 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2939 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -37977,26 +48049,26 @@ func (x *EndpointsList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv2944 := &x.Items - yym2945 := z.DecBinary() - _ = yym2945 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceEndpoints((*[]Endpoints)(yyv2944), d) + h.decSliceEndpoints((*[]Endpoints)(yyv19), d) } } for { - yyj2939++ - if yyhl2939 { - yyb2939 = yyj2939 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb2939 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb2939 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2939-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -38008,38 +48080,39 @@ func (x *NodeSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2946 := z.EncBinary() - _ = yym2946 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2947 := !z.EncBinary() - yy2arr2947 := z.EncBasicHandle().StructToArray - var yyq2947 [4]bool - _, _, _ = yysep2947, yyq2947, yy2arr2947 - const yyr2947 bool = false - yyq2947[0] = x.PodCIDR != "" - yyq2947[1] = x.ExternalID != "" - yyq2947[2] = x.ProviderID != "" - yyq2947[3] = x.Unschedulable != false - var yynn2947 int - if yyr2947 || yy2arr2947 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PodCIDR != "" + yyq2[1] = x.ExternalID != "" + yyq2[2] = x.ProviderID != "" + yyq2[3] = x.Unschedulable != false + yyq2[4] = len(x.Taints) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) } else { - yynn2947 = 0 - for _, b := range yyq2947 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2947++ + yynn2++ } } - r.EncodeMapStart(yynn2947) - yynn2947 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2947 || yy2arr2947 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2947[0] { - yym2949 := z.EncBinary() - _ = yym2949 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR)) @@ -38048,23 +48121,23 @@ func (x *NodeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2947[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podCIDR")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2950 := z.EncBinary() - _ = yym2950 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.PodCIDR)) } } } - if yyr2947 || yy2arr2947 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2947[1] { - yym2952 := z.EncBinary() - _ = yym2952 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID)) @@ -38073,23 +48146,23 @@ func (x *NodeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2947[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("externalID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2953 := z.EncBinary() - _ = yym2953 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ExternalID)) } } } - if yyr2947 || yy2arr2947 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2947[2] { - yym2955 := z.EncBinary() - _ = yym2955 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID)) @@ -38098,23 +48171,23 @@ func (x *NodeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2947[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("providerID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2956 := z.EncBinary() - _ = yym2956 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ProviderID)) } } } - if yyr2947 || yy2arr2947 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2947[3] { - yym2958 := z.EncBinary() - _ = yym2958 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.Unschedulable)) @@ -38123,19 +48196,52 @@ func (x *NodeSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq2947[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("unschedulable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2959 := z.EncBinary() - _ = yym2959 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.Unschedulable)) } } } - if yyr2947 || yy2arr2947 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.Taints == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceTaint(([]Taint)(x.Taints), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("taints")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Taints == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + h.encSliceTaint(([]Taint)(x.Taints), e) + } + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -38148,25 +48254,25 @@ func (x *NodeSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2960 := z.DecBinary() - _ = yym2960 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2961 := r.ContainerType() - if yyct2961 == codecSelferValueTypeMap1234 { - yyl2961 := r.ReadMapStart() - if yyl2961 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2961, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2961 == codecSelferValueTypeArray1234 { - yyl2961 := r.ReadArrayStart() - if yyl2961 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2961, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -38178,12 +48284,12 @@ func (x *NodeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2962Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2962Slc - var yyhl2962 bool = l >= 0 - for yyj2962 := 0; ; yyj2962++ { - if yyhl2962 { - if yyj2962 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -38192,38 +48298,74 @@ func (x *NodeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2962Slc = r.DecodeBytes(yys2962Slc, true, true) - yys2962 := string(yys2962Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2962 { + switch yys3 { case "podCIDR": if r.TryDecodeAsNil() { x.PodCIDR = "" } else { - x.PodCIDR = string(r.DecodeString()) + yyv4 := &x.PodCIDR + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "externalID": if r.TryDecodeAsNil() { x.ExternalID = "" } else { - x.ExternalID = string(r.DecodeString()) + yyv6 := &x.ExternalID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "providerID": if r.TryDecodeAsNil() { x.ProviderID = "" } else { - x.ProviderID = string(r.DecodeString()) + yyv8 := &x.ProviderID + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "unschedulable": if r.TryDecodeAsNil() { x.Unschedulable = false } else { - x.Unschedulable = bool(r.DecodeBool()) + yyv10 := &x.Unschedulable + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } + } + case "taints": + if r.TryDecodeAsNil() { + x.Taints = nil + } else { + yyv12 := &x.Taints + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSliceTaint((*[]Taint)(yyv12), d) + } } default: - z.DecStructFieldNotFound(-1, yys2962) - } // end switch yys2962 - } // end for yyj2962 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -38231,16 +48373,16 @@ func (x *NodeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2967 int - var yyb2967 bool - var yyhl2967 bool = l >= 0 - yyj2967++ - if yyhl2967 { - yyb2967 = yyj2967 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb2967 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb2967 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -38248,15 +48390,21 @@ func (x *NodeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PodCIDR = "" } else { - x.PodCIDR = string(r.DecodeString()) + yyv15 := &x.PodCIDR + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj2967++ - if yyhl2967 { - yyb2967 = yyj2967 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb2967 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb2967 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -38264,15 +48412,21 @@ func (x *NodeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ExternalID = "" } else { - x.ExternalID = string(r.DecodeString()) + yyv17 := &x.ExternalID + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj2967++ - if yyhl2967 { - yyb2967 = yyj2967 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb2967 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb2967 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -38280,15 +48434,21 @@ func (x *NodeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ProviderID = "" } else { - x.ProviderID = string(r.DecodeString()) + yyv19 := &x.ProviderID + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } - yyj2967++ - if yyhl2967 { - yyb2967 = yyj2967 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb2967 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb2967 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -38296,20 +48456,48 @@ func (x *NodeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Unschedulable = false } else { - x.Unschedulable = bool(r.DecodeBool()) + yyv21 := &x.Unschedulable + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*bool)(yyv21)) = r.DecodeBool() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Taints = nil + } else { + yyv23 := &x.Taints + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + h.decSliceTaint((*[]Taint)(yyv23), d) + } } for { - yyj2967++ - if yyhl2967 { - yyb2967 = yyj2967 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb2967 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb2967 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2967-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -38321,33 +48509,33 @@ func (x *DaemonEndpoint) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2972 := z.EncBinary() - _ = yym2972 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2973 := !z.EncBinary() - yy2arr2973 := z.EncBasicHandle().StructToArray - var yyq2973 [1]bool - _, _, _ = yysep2973, yyq2973, yy2arr2973 - const yyr2973 bool = false - var yynn2973 int - if yyr2973 || yy2arr2973 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn2973 = 1 - for _, b := range yyq2973 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn2973++ + yynn2++ } } - r.EncodeMapStart(yynn2973) - yynn2973 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2973 || yy2arr2973 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2975 := z.EncBinary() - _ = yym2975 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Port)) @@ -38356,14 +48544,14 @@ func (x *DaemonEndpoint) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("Port")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2976 := z.EncBinary() - _ = yym2976 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Port)) } } - if yyr2973 || yy2arr2973 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -38376,25 +48564,25 @@ func (x *DaemonEndpoint) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2977 := z.DecBinary() - _ = yym2977 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2978 := r.ContainerType() - if yyct2978 == codecSelferValueTypeMap1234 { - yyl2978 := r.ReadMapStart() - if yyl2978 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2978, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2978 == codecSelferValueTypeArray1234 { - yyl2978 := r.ReadArrayStart() - if yyl2978 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2978, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -38406,12 +48594,12 @@ func (x *DaemonEndpoint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2979Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2979Slc - var yyhl2979 bool = l >= 0 - for yyj2979 := 0; ; yyj2979++ { - if yyhl2979 { - if yyj2979 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -38420,20 +48608,26 @@ func (x *DaemonEndpoint) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2979Slc = r.DecodeBytes(yys2979Slc, true, true) - yys2979 := string(yys2979Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2979 { + switch yys3 { case "Port": if r.TryDecodeAsNil() { x.Port = 0 } else { - x.Port = int32(r.DecodeInt(32)) + yyv4 := &x.Port + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys2979) - } // end switch yys2979 - } // end for yyj2979 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -38441,16 +48635,16 @@ func (x *DaemonEndpoint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2981 int - var yyb2981 bool - var yyhl2981 bool = l >= 0 - yyj2981++ - if yyhl2981 { - yyb2981 = yyj2981 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb2981 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb2981 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -38458,20 +48652,26 @@ func (x *DaemonEndpoint) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Port = 0 } else { - x.Port = int32(r.DecodeInt(32)) + yyv7 := &x.Port + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } } for { - yyj2981++ - if yyhl2981 { - yyb2981 = yyj2981 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb2981 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb2981 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2981-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -38483,48 +48683,48 @@ func (x *NodeDaemonEndpoints) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2983 := z.EncBinary() - _ = yym2983 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2984 := !z.EncBinary() - yy2arr2984 := z.EncBasicHandle().StructToArray - var yyq2984 [1]bool - _, _, _ = yysep2984, yyq2984, yy2arr2984 - const yyr2984 bool = false - yyq2984[0] = true - var yynn2984 int - if yyr2984 || yy2arr2984 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn2984 = 0 - for _, b := range yyq2984 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn2984++ + yynn2++ } } - r.EncodeMapStart(yynn2984) - yynn2984 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2984 || yy2arr2984 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2984[0] { - yy2986 := &x.KubeletEndpoint - yy2986.CodecEncodeSelf(e) + if yyq2[0] { + yy4 := &x.KubeletEndpoint + yy4.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq2984[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kubeletEndpoint")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy2987 := &x.KubeletEndpoint - yy2987.CodecEncodeSelf(e) + yy6 := &x.KubeletEndpoint + yy6.CodecEncodeSelf(e) } } - if yyr2984 || yy2arr2984 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -38537,25 +48737,25 @@ func (x *NodeDaemonEndpoints) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym2988 := z.DecBinary() - _ = yym2988 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct2989 := r.ContainerType() - if yyct2989 == codecSelferValueTypeMap1234 { - yyl2989 := r.ReadMapStart() - if yyl2989 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl2989, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct2989 == codecSelferValueTypeArray1234 { - yyl2989 := r.ReadArrayStart() - if yyl2989 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl2989, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -38567,12 +48767,12 @@ func (x *NodeDaemonEndpoints) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys2990Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys2990Slc - var yyhl2990 bool = l >= 0 - for yyj2990 := 0; ; yyj2990++ { - if yyhl2990 { - if yyj2990 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -38581,21 +48781,21 @@ func (x *NodeDaemonEndpoints) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys2990Slc = r.DecodeBytes(yys2990Slc, true, true) - yys2990 := string(yys2990Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys2990 { + switch yys3 { case "kubeletEndpoint": if r.TryDecodeAsNil() { x.KubeletEndpoint = DaemonEndpoint{} } else { - yyv2991 := &x.KubeletEndpoint - yyv2991.CodecDecodeSelf(d) + yyv4 := &x.KubeletEndpoint + yyv4.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys2990) - } // end switch yys2990 - } // end for yyj2990 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -38603,16 +48803,16 @@ func (x *NodeDaemonEndpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj2992 int - var yyb2992 bool - var yyhl2992 bool = l >= 0 - yyj2992++ - if yyhl2992 { - yyb2992 = yyj2992 > l + var yyj5 int + var yyb5 bool + var yyhl5 bool = l >= 0 + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb2992 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb2992 { + if yyb5 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -38620,21 +48820,21 @@ func (x *NodeDaemonEndpoints) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.KubeletEndpoint = DaemonEndpoint{} } else { - yyv2993 := &x.KubeletEndpoint - yyv2993.CodecDecodeSelf(d) + yyv6 := &x.KubeletEndpoint + yyv6.CodecDecodeSelf(d) } for { - yyj2992++ - if yyhl2992 { - yyb2992 = yyj2992 > l + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb2992 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb2992 { + if yyb5 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj2992-1, "") + z.DecStructFieldNotFound(yyj5-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -38646,33 +48846,33 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym2994 := z.EncBinary() - _ = yym2994 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep2995 := !z.EncBinary() - yy2arr2995 := z.EncBasicHandle().StructToArray - var yyq2995 [10]bool - _, _, _ = yysep2995, yyq2995, yy2arr2995 - const yyr2995 bool = false - var yynn2995 int - if yyr2995 || yy2arr2995 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(10) } else { - yynn2995 = 10 - for _, b := range yyq2995 { + yynn2 = 10 + for _, b := range yyq2 { if b { - yynn2995++ + yynn2++ } } - r.EncodeMapStart(yynn2995) - yynn2995 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym2997 := z.EncBinary() - _ = yym2997 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.MachineID)) @@ -38681,17 +48881,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("machineID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym2998 := z.EncBinary() - _ = yym2998 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.MachineID)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3000 := z.EncBinary() - _ = yym3000 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SystemUUID)) @@ -38700,17 +48900,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("systemUUID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3001 := z.EncBinary() - _ = yym3001 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SystemUUID)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3003 := z.EncBinary() - _ = yym3003 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.BootID)) @@ -38719,17 +48919,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("bootID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3004 := z.EncBinary() - _ = yym3004 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.BootID)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3006 := z.EncBinary() - _ = yym3006 + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.KernelVersion)) @@ -38738,17 +48938,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kernelVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3007 := z.EncBinary() - _ = yym3007 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.KernelVersion)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3009 := z.EncBinary() - _ = yym3009 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.OSImage)) @@ -38757,17 +48957,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("osImage")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3010 := z.EncBinary() - _ = yym3010 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.OSImage)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3012 := z.EncBinary() - _ = yym3012 + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ContainerRuntimeVersion)) @@ -38776,17 +48976,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("containerRuntimeVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3013 := z.EncBinary() - _ = yym3013 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ContainerRuntimeVersion)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3015 := z.EncBinary() - _ = yym3015 + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.KubeletVersion)) @@ -38795,17 +48995,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kubeletVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3016 := z.EncBinary() - _ = yym3016 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.KubeletVersion)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3018 := z.EncBinary() - _ = yym3018 + yym25 := z.EncBinary() + _ = yym25 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.KubeProxyVersion)) @@ -38814,17 +49014,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kubeProxyVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3019 := z.EncBinary() - _ = yym3019 + yym26 := z.EncBinary() + _ = yym26 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.KubeProxyVersion)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3021 := z.EncBinary() - _ = yym3021 + yym28 := z.EncBinary() + _ = yym28 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.OperatingSystem)) @@ -38833,17 +49033,17 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("operatingSystem")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3022 := z.EncBinary() - _ = yym3022 + yym29 := z.EncBinary() + _ = yym29 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.OperatingSystem)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3024 := z.EncBinary() - _ = yym3024 + yym31 := z.EncBinary() + _ = yym31 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Architecture)) @@ -38852,14 +49052,14 @@ func (x *NodeSystemInfo) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("architecture")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3025 := z.EncBinary() - _ = yym3025 + yym32 := z.EncBinary() + _ = yym32 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Architecture)) } } - if yyr2995 || yy2arr2995 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -38872,25 +49072,25 @@ func (x *NodeSystemInfo) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3026 := z.DecBinary() - _ = yym3026 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3027 := r.ContainerType() - if yyct3027 == codecSelferValueTypeMap1234 { - yyl3027 := r.ReadMapStart() - if yyl3027 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3027, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3027 == codecSelferValueTypeArray1234 { - yyl3027 := r.ReadArrayStart() - if yyl3027 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3027, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -38902,12 +49102,12 @@ func (x *NodeSystemInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3028Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3028Slc - var yyhl3028 bool = l >= 0 - for yyj3028 := 0; ; yyj3028++ { - if yyhl3028 { - if yyj3028 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -38916,74 +49116,134 @@ func (x *NodeSystemInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3028Slc = r.DecodeBytes(yys3028Slc, true, true) - yys3028 := string(yys3028Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3028 { + switch yys3 { case "machineID": if r.TryDecodeAsNil() { x.MachineID = "" } else { - x.MachineID = string(r.DecodeString()) + yyv4 := &x.MachineID + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "systemUUID": if r.TryDecodeAsNil() { x.SystemUUID = "" } else { - x.SystemUUID = string(r.DecodeString()) + yyv6 := &x.SystemUUID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "bootID": if r.TryDecodeAsNil() { x.BootID = "" } else { - x.BootID = string(r.DecodeString()) + yyv8 := &x.BootID + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "kernelVersion": if r.TryDecodeAsNil() { x.KernelVersion = "" } else { - x.KernelVersion = string(r.DecodeString()) + yyv10 := &x.KernelVersion + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "osImage": if r.TryDecodeAsNil() { x.OSImage = "" } else { - x.OSImage = string(r.DecodeString()) + yyv12 := &x.OSImage + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "containerRuntimeVersion": if r.TryDecodeAsNil() { x.ContainerRuntimeVersion = "" } else { - x.ContainerRuntimeVersion = string(r.DecodeString()) + yyv14 := &x.ContainerRuntimeVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "kubeletVersion": if r.TryDecodeAsNil() { x.KubeletVersion = "" } else { - x.KubeletVersion = string(r.DecodeString()) + yyv16 := &x.KubeletVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } case "kubeProxyVersion": if r.TryDecodeAsNil() { x.KubeProxyVersion = "" } else { - x.KubeProxyVersion = string(r.DecodeString()) + yyv18 := &x.KubeProxyVersion + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } } case "operatingSystem": if r.TryDecodeAsNil() { x.OperatingSystem = "" } else { - x.OperatingSystem = string(r.DecodeString()) + yyv20 := &x.OperatingSystem + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*string)(yyv20)) = r.DecodeString() + } } case "architecture": if r.TryDecodeAsNil() { x.Architecture = "" } else { - x.Architecture = string(r.DecodeString()) + yyv22 := &x.Architecture + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3028) - } // end switch yys3028 - } // end for yyj3028 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -38991,16 +49251,16 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3039 int - var yyb3039 bool - var yyhl3039 bool = l >= 0 - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + var yyj24 int + var yyb24 bool + var yyhl24 bool = l >= 0 + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39008,15 +49268,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.MachineID = "" } else { - x.MachineID = string(r.DecodeString()) + yyv25 := &x.MachineID + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39024,15 +49290,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.SystemUUID = "" } else { - x.SystemUUID = string(r.DecodeString()) + yyv27 := &x.SystemUUID + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39040,15 +49312,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.BootID = "" } else { - x.BootID = string(r.DecodeString()) + yyv29 := &x.BootID + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39056,15 +49334,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.KernelVersion = "" } else { - x.KernelVersion = string(r.DecodeString()) + yyv31 := &x.KernelVersion + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39072,15 +49356,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.OSImage = "" } else { - x.OSImage = string(r.DecodeString()) + yyv33 := &x.OSImage + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39088,15 +49378,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ContainerRuntimeVersion = "" } else { - x.ContainerRuntimeVersion = string(r.DecodeString()) + yyv35 := &x.ContainerRuntimeVersion + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*string)(yyv35)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39104,15 +49400,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.KubeletVersion = "" } else { - x.KubeletVersion = string(r.DecodeString()) + yyv37 := &x.KubeletVersion + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*string)(yyv37)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39120,15 +49422,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.KubeProxyVersion = "" } else { - x.KubeProxyVersion = string(r.DecodeString()) + yyv39 := &x.KubeProxyVersion + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*string)(yyv39)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39136,15 +49444,21 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.OperatingSystem = "" } else { - x.OperatingSystem = string(r.DecodeString()) + yyv41 := &x.OperatingSystem + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*string)(yyv41)) = r.DecodeString() + } } - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39152,20 +49466,26 @@ func (x *NodeSystemInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Architecture = "" } else { - x.Architecture = string(r.DecodeString()) + yyv43 := &x.Architecture + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*string)(yyv43)) = r.DecodeString() + } } for { - yyj3039++ - if yyhl3039 { - yyb3039 = yyj3039 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3039 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3039 { + if yyb24 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3039-1, "") + z.DecStructFieldNotFound(yyj24-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -39177,42 +49497,42 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3050 := z.EncBinary() - _ = yym3050 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3051 := !z.EncBinary() - yy2arr3051 := z.EncBasicHandle().StructToArray - var yyq3051 [10]bool - _, _, _ = yysep3051, yyq3051, yy2arr3051 - const yyr3051 bool = false - yyq3051[0] = len(x.Capacity) != 0 - yyq3051[1] = len(x.Allocatable) != 0 - yyq3051[2] = x.Phase != "" - yyq3051[3] = len(x.Conditions) != 0 - yyq3051[4] = len(x.Addresses) != 0 - yyq3051[5] = true - yyq3051[6] = true - yyq3051[7] = len(x.Images) != 0 - yyq3051[8] = len(x.VolumesInUse) != 0 - yyq3051[9] = len(x.VolumesAttached) != 0 - var yynn3051 int - if yyr3051 || yy2arr3051 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Capacity) != 0 + yyq2[1] = len(x.Allocatable) != 0 + yyq2[2] = x.Phase != "" + yyq2[3] = len(x.Conditions) != 0 + yyq2[4] = len(x.Addresses) != 0 + yyq2[5] = true + yyq2[6] = true + yyq2[7] = len(x.Images) != 0 + yyq2[8] = len(x.VolumesInUse) != 0 + yyq2[9] = len(x.VolumesAttached) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(10) } else { - yynn3051 = 0 - for _, b := range yyq3051 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3051++ + yynn2++ } } - r.EncodeMapStart(yynn3051) - yynn3051 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[0] { + if yyq2[0] { if x.Capacity == nil { r.EncodeNil() } else { @@ -39222,7 +49542,7 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("capacity")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -39233,9 +49553,9 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[1] { + if yyq2[1] { if x.Allocatable == nil { r.EncodeNil() } else { @@ -39245,7 +49565,7 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("allocatable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -39256,29 +49576,29 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[2] { + if yyq2[2] { x.Phase.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3051[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("phase")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Phase.CodecEncodeSelf(e) } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[3] { + if yyq2[3] { if x.Conditions == nil { r.EncodeNil() } else { - yym3056 := z.EncBinary() - _ = yym3056 + yym13 := z.EncBinary() + _ = yym13 if false { } else { h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e) @@ -39288,15 +49608,15 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Conditions == nil { r.EncodeNil() } else { - yym3057 := z.EncBinary() - _ = yym3057 + yym14 := z.EncBinary() + _ = yym14 if false { } else { h.encSliceNodeCondition(([]NodeCondition)(x.Conditions), e) @@ -39304,14 +49624,14 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[4] { + if yyq2[4] { if x.Addresses == nil { r.EncodeNil() } else { - yym3059 := z.EncBinary() - _ = yym3059 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e) @@ -39321,15 +49641,15 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("addresses")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Addresses == nil { r.EncodeNil() } else { - yym3060 := z.EncBinary() - _ = yym3060 + yym17 := z.EncBinary() + _ = yym17 if false { } else { h.encSliceNodeAddress(([]NodeAddress)(x.Addresses), e) @@ -39337,48 +49657,48 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[5] { - yy3062 := &x.DaemonEndpoints - yy3062.CodecEncodeSelf(e) + if yyq2[5] { + yy19 := &x.DaemonEndpoints + yy19.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3051[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("daemonEndpoints")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3063 := &x.DaemonEndpoints - yy3063.CodecEncodeSelf(e) + yy21 := &x.DaemonEndpoints + yy21.CodecEncodeSelf(e) } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[6] { - yy3065 := &x.NodeInfo - yy3065.CodecEncodeSelf(e) + if yyq2[6] { + yy24 := &x.NodeInfo + yy24.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3051[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nodeInfo")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3066 := &x.NodeInfo - yy3066.CodecEncodeSelf(e) + yy26 := &x.NodeInfo + yy26.CodecEncodeSelf(e) } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[7] { + if yyq2[7] { if x.Images == nil { r.EncodeNil() } else { - yym3068 := z.EncBinary() - _ = yym3068 + yym29 := z.EncBinary() + _ = yym29 if false { } else { h.encSliceContainerImage(([]ContainerImage)(x.Images), e) @@ -39388,15 +49708,15 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("images")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Images == nil { r.EncodeNil() } else { - yym3069 := z.EncBinary() - _ = yym3069 + yym30 := z.EncBinary() + _ = yym30 if false { } else { h.encSliceContainerImage(([]ContainerImage)(x.Images), e) @@ -39404,14 +49724,14 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[8] { + if yyq2[8] { if x.VolumesInUse == nil { r.EncodeNil() } else { - yym3071 := z.EncBinary() - _ = yym3071 + yym32 := z.EncBinary() + _ = yym32 if false { } else { h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e) @@ -39421,15 +49741,15 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumesInUse")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.VolumesInUse == nil { r.EncodeNil() } else { - yym3072 := z.EncBinary() - _ = yym3072 + yym33 := z.EncBinary() + _ = yym33 if false { } else { h.encSliceUniqueVolumeName(([]UniqueVolumeName)(x.VolumesInUse), e) @@ -39437,14 +49757,14 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3051[9] { + if yyq2[9] { if x.VolumesAttached == nil { r.EncodeNil() } else { - yym3074 := z.EncBinary() - _ = yym3074 + yym35 := z.EncBinary() + _ = yym35 if false { } else { h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e) @@ -39454,15 +49774,15 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3051[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumesAttached")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.VolumesAttached == nil { r.EncodeNil() } else { - yym3075 := z.EncBinary() - _ = yym3075 + yym36 := z.EncBinary() + _ = yym36 if false { } else { h.encSliceAttachedVolume(([]AttachedVolume)(x.VolumesAttached), e) @@ -39470,7 +49790,7 @@ func (x *NodeStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3051 || yy2arr3051 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -39483,25 +49803,25 @@ func (x *NodeStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3076 := z.DecBinary() - _ = yym3076 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3077 := r.ContainerType() - if yyct3077 == codecSelferValueTypeMap1234 { - yyl3077 := r.ReadMapStart() - if yyl3077 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3077, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3077 == codecSelferValueTypeArray1234 { - yyl3077 := r.ReadArrayStart() - if yyl3077 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3077, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -39513,12 +49833,12 @@ func (x *NodeStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3078Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3078Slc - var yyhl3078 bool = l >= 0 - for yyj3078 := 0; ; yyj3078++ { - if yyhl3078 { - if yyj3078 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -39527,108 +49847,109 @@ func (x *NodeStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3078Slc = r.DecodeBytes(yys3078Slc, true, true) - yys3078 := string(yys3078Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3078 { + switch yys3 { case "capacity": if r.TryDecodeAsNil() { x.Capacity = nil } else { - yyv3079 := &x.Capacity - yyv3079.CodecDecodeSelf(d) + yyv4 := &x.Capacity + yyv4.CodecDecodeSelf(d) } case "allocatable": if r.TryDecodeAsNil() { x.Allocatable = nil } else { - yyv3080 := &x.Allocatable - yyv3080.CodecDecodeSelf(d) + yyv5 := &x.Allocatable + yyv5.CodecDecodeSelf(d) } case "phase": if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = NodePhase(r.DecodeString()) + yyv6 := &x.Phase + yyv6.CodecDecodeSelf(d) } case "conditions": if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv3082 := &x.Conditions - yym3083 := z.DecBinary() - _ = yym3083 + yyv7 := &x.Conditions + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceNodeCondition((*[]NodeCondition)(yyv3082), d) + h.decSliceNodeCondition((*[]NodeCondition)(yyv7), d) } } case "addresses": if r.TryDecodeAsNil() { x.Addresses = nil } else { - yyv3084 := &x.Addresses - yym3085 := z.DecBinary() - _ = yym3085 + yyv9 := &x.Addresses + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceNodeAddress((*[]NodeAddress)(yyv3084), d) + h.decSliceNodeAddress((*[]NodeAddress)(yyv9), d) } } case "daemonEndpoints": if r.TryDecodeAsNil() { x.DaemonEndpoints = NodeDaemonEndpoints{} } else { - yyv3086 := &x.DaemonEndpoints - yyv3086.CodecDecodeSelf(d) + yyv11 := &x.DaemonEndpoints + yyv11.CodecDecodeSelf(d) } case "nodeInfo": if r.TryDecodeAsNil() { x.NodeInfo = NodeSystemInfo{} } else { - yyv3087 := &x.NodeInfo - yyv3087.CodecDecodeSelf(d) + yyv12 := &x.NodeInfo + yyv12.CodecDecodeSelf(d) } case "images": if r.TryDecodeAsNil() { x.Images = nil } else { - yyv3088 := &x.Images - yym3089 := z.DecBinary() - _ = yym3089 + yyv13 := &x.Images + yym14 := z.DecBinary() + _ = yym14 if false { } else { - h.decSliceContainerImage((*[]ContainerImage)(yyv3088), d) + h.decSliceContainerImage((*[]ContainerImage)(yyv13), d) } } case "volumesInUse": if r.TryDecodeAsNil() { x.VolumesInUse = nil } else { - yyv3090 := &x.VolumesInUse - yym3091 := z.DecBinary() - _ = yym3091 + yyv15 := &x.VolumesInUse + yym16 := z.DecBinary() + _ = yym16 if false { } else { - h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv3090), d) + h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv15), d) } } case "volumesAttached": if r.TryDecodeAsNil() { x.VolumesAttached = nil } else { - yyv3092 := &x.VolumesAttached - yym3093 := z.DecBinary() - _ = yym3093 + yyv17 := &x.VolumesAttached + yym18 := z.DecBinary() + _ = yym18 if false { } else { - h.decSliceAttachedVolume((*[]AttachedVolume)(yyv3092), d) + h.decSliceAttachedVolume((*[]AttachedVolume)(yyv17), d) } } default: - z.DecStructFieldNotFound(-1, yys3078) - } // end switch yys3078 - } // end for yyj3078 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -39636,16 +49957,16 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3094 int - var yyb3094 bool - var yyhl3094 bool = l >= 0 - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + var yyj19 int + var yyb19 bool + var yyhl19 bool = l >= 0 + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39653,16 +49974,16 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Capacity = nil } else { - yyv3095 := &x.Capacity - yyv3095.CodecDecodeSelf(d) + yyv20 := &x.Capacity + yyv20.CodecDecodeSelf(d) } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39670,16 +49991,16 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Allocatable = nil } else { - yyv3096 := &x.Allocatable - yyv3096.CodecDecodeSelf(d) + yyv21 := &x.Allocatable + yyv21.CodecDecodeSelf(d) } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39687,15 +50008,16 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = NodePhase(r.DecodeString()) + yyv22 := &x.Phase + yyv22.CodecDecodeSelf(d) } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39703,21 +50025,21 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv3098 := &x.Conditions - yym3099 := z.DecBinary() - _ = yym3099 + yyv23 := &x.Conditions + yym24 := z.DecBinary() + _ = yym24 if false { } else { - h.decSliceNodeCondition((*[]NodeCondition)(yyv3098), d) + h.decSliceNodeCondition((*[]NodeCondition)(yyv23), d) } } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39725,21 +50047,21 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Addresses = nil } else { - yyv3100 := &x.Addresses - yym3101 := z.DecBinary() - _ = yym3101 + yyv25 := &x.Addresses + yym26 := z.DecBinary() + _ = yym26 if false { } else { - h.decSliceNodeAddress((*[]NodeAddress)(yyv3100), d) + h.decSliceNodeAddress((*[]NodeAddress)(yyv25), d) } } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39747,16 +50069,16 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.DaemonEndpoints = NodeDaemonEndpoints{} } else { - yyv3102 := &x.DaemonEndpoints - yyv3102.CodecDecodeSelf(d) + yyv27 := &x.DaemonEndpoints + yyv27.CodecDecodeSelf(d) } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39764,16 +50086,16 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.NodeInfo = NodeSystemInfo{} } else { - yyv3103 := &x.NodeInfo - yyv3103.CodecDecodeSelf(d) + yyv28 := &x.NodeInfo + yyv28.CodecDecodeSelf(d) } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39781,21 +50103,21 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Images = nil } else { - yyv3104 := &x.Images - yym3105 := z.DecBinary() - _ = yym3105 + yyv29 := &x.Images + yym30 := z.DecBinary() + _ = yym30 if false { } else { - h.decSliceContainerImage((*[]ContainerImage)(yyv3104), d) + h.decSliceContainerImage((*[]ContainerImage)(yyv29), d) } } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39803,21 +50125,21 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.VolumesInUse = nil } else { - yyv3106 := &x.VolumesInUse - yym3107 := z.DecBinary() - _ = yym3107 + yyv31 := &x.VolumesInUse + yym32 := z.DecBinary() + _ = yym32 if false { } else { - h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv3106), d) + h.decSliceUniqueVolumeName((*[]UniqueVolumeName)(yyv31), d) } } - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -39825,26 +50147,26 @@ func (x *NodeStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.VolumesAttached = nil } else { - yyv3108 := &x.VolumesAttached - yym3109 := z.DecBinary() - _ = yym3109 + yyv33 := &x.VolumesAttached + yym34 := z.DecBinary() + _ = yym34 if false { } else { - h.decSliceAttachedVolume((*[]AttachedVolume)(yyv3108), d) + h.decSliceAttachedVolume((*[]AttachedVolume)(yyv33), d) } } for { - yyj3094++ - if yyhl3094 { - yyb3094 = yyj3094 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb3094 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb3094 { + if yyb19 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3094-1, "") + z.DecStructFieldNotFound(yyj19-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -39853,8 +50175,8 @@ func (x UniqueVolumeName) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3110 := z.EncBinary() - _ = yym3110 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -39866,8 +50188,8 @@ func (x *UniqueVolumeName) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3111 := z.DecBinary() - _ = yym3111 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -39882,30 +50204,30 @@ func (x *AttachedVolume) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3112 := z.EncBinary() - _ = yym3112 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3113 := !z.EncBinary() - yy2arr3113 := z.EncBasicHandle().StructToArray - var yyq3113 [2]bool - _, _, _ = yysep3113, yyq3113, yy2arr3113 - const yyr3113 bool = false - var yynn3113 int - if yyr3113 || yy2arr3113 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn3113 = 2 - for _, b := range yyq3113 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn3113++ + yynn2++ } } - r.EncodeMapStart(yynn3113) - yynn3113 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3113 || yy2arr3113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Name.CodecEncodeSelf(e) } else { @@ -39914,10 +50236,10 @@ func (x *AttachedVolume) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Name.CodecEncodeSelf(e) } - if yyr3113 || yy2arr3113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3116 := z.EncBinary() - _ = yym3116 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DevicePath)) @@ -39926,14 +50248,14 @@ func (x *AttachedVolume) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("devicePath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3117 := z.EncBinary() - _ = yym3117 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.DevicePath)) } } - if yyr3113 || yy2arr3113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -39946,25 +50268,25 @@ func (x *AttachedVolume) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3118 := z.DecBinary() - _ = yym3118 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3119 := r.ContainerType() - if yyct3119 == codecSelferValueTypeMap1234 { - yyl3119 := r.ReadMapStart() - if yyl3119 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3119, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3119 == codecSelferValueTypeArray1234 { - yyl3119 := r.ReadArrayStart() - if yyl3119 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3119, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -39976,12 +50298,12 @@ func (x *AttachedVolume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3120Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3120Slc - var yyhl3120 bool = l >= 0 - for yyj3120 := 0; ; yyj3120++ { - if yyhl3120 { - if yyj3120 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -39990,26 +50312,33 @@ func (x *AttachedVolume) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3120Slc = r.DecodeBytes(yys3120Slc, true, true) - yys3120 := string(yys3120Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3120 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = UniqueVolumeName(r.DecodeString()) + yyv4 := &x.Name + yyv4.CodecDecodeSelf(d) } case "devicePath": if r.TryDecodeAsNil() { x.DevicePath = "" } else { - x.DevicePath = string(r.DecodeString()) + yyv5 := &x.DevicePath + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3120) - } // end switch yys3120 - } // end for yyj3120 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -40017,16 +50346,16 @@ func (x *AttachedVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3123 int - var yyb3123 bool - var yyhl3123 bool = l >= 0 - yyj3123++ - if yyhl3123 { - yyb3123 = yyj3123 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb3123 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb3123 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40034,15 +50363,16 @@ func (x *AttachedVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = UniqueVolumeName(r.DecodeString()) + yyv8 := &x.Name + yyv8.CodecDecodeSelf(d) } - yyj3123++ - if yyhl3123 { - yyb3123 = yyj3123 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb3123 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb3123 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40050,20 +50380,26 @@ func (x *AttachedVolume) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.DevicePath = "" } else { - x.DevicePath = string(r.DecodeString()) + yyv9 := &x.DevicePath + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } for { - yyj3123++ - if yyhl3123 { - yyb3123 = yyj3123 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb3123 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb3123 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3123-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -40075,38 +50411,38 @@ func (x *AvoidPods) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3126 := z.EncBinary() - _ = yym3126 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3127 := !z.EncBinary() - yy2arr3127 := z.EncBasicHandle().StructToArray - var yyq3127 [1]bool - _, _, _ = yysep3127, yyq3127, yy2arr3127 - const yyr3127 bool = false - yyq3127[0] = len(x.PreferAvoidPods) != 0 - var yynn3127 int - if yyr3127 || yy2arr3127 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.PreferAvoidPods) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn3127 = 0 - for _, b := range yyq3127 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3127++ + yynn2++ } } - r.EncodeMapStart(yynn3127) - yynn3127 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3127 || yy2arr3127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3127[0] { + if yyq2[0] { if x.PreferAvoidPods == nil { r.EncodeNil() } else { - yym3129 := z.EncBinary() - _ = yym3129 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSlicePreferAvoidPodsEntry(([]PreferAvoidPodsEntry)(x.PreferAvoidPods), e) @@ -40116,15 +50452,15 @@ func (x *AvoidPods) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3127[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preferAvoidPods")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.PreferAvoidPods == nil { r.EncodeNil() } else { - yym3130 := z.EncBinary() - _ = yym3130 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSlicePreferAvoidPodsEntry(([]PreferAvoidPodsEntry)(x.PreferAvoidPods), e) @@ -40132,7 +50468,7 @@ func (x *AvoidPods) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3127 || yy2arr3127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -40145,25 +50481,25 @@ func (x *AvoidPods) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3131 := z.DecBinary() - _ = yym3131 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3132 := r.ContainerType() - if yyct3132 == codecSelferValueTypeMap1234 { - yyl3132 := r.ReadMapStart() - if yyl3132 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3132, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3132 == codecSelferValueTypeArray1234 { - yyl3132 := r.ReadArrayStart() - if yyl3132 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3132, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -40175,12 +50511,12 @@ func (x *AvoidPods) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3133Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3133Slc - var yyhl3133 bool = l >= 0 - for yyj3133 := 0; ; yyj3133++ { - if yyhl3133 { - if yyj3133 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -40189,26 +50525,26 @@ func (x *AvoidPods) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3133Slc = r.DecodeBytes(yys3133Slc, true, true) - yys3133 := string(yys3133Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3133 { + switch yys3 { case "preferAvoidPods": if r.TryDecodeAsNil() { x.PreferAvoidPods = nil } else { - yyv3134 := &x.PreferAvoidPods - yym3135 := z.DecBinary() - _ = yym3135 + yyv4 := &x.PreferAvoidPods + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv3134), d) + h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys3133) - } // end switch yys3133 - } // end for yyj3133 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -40216,16 +50552,16 @@ func (x *AvoidPods) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3136 int - var yyb3136 bool - var yyhl3136 bool = l >= 0 - yyj3136++ - if yyhl3136 { - yyb3136 = yyj3136 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3136 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3136 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40233,26 +50569,26 @@ func (x *AvoidPods) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.PreferAvoidPods = nil } else { - yyv3137 := &x.PreferAvoidPods - yym3138 := z.DecBinary() - _ = yym3138 + yyv7 := &x.PreferAvoidPods + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv3137), d) + h.decSlicePreferAvoidPodsEntry((*[]PreferAvoidPodsEntry)(yyv7), d) } } for { - yyj3136++ - if yyhl3136 { - yyb3136 = yyj3136 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3136 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3136 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3136-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -40264,85 +50600,85 @@ func (x *PreferAvoidPodsEntry) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3139 := z.EncBinary() - _ = yym3139 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3140 := !z.EncBinary() - yy2arr3140 := z.EncBasicHandle().StructToArray - var yyq3140 [4]bool - _, _, _ = yysep3140, yyq3140, yy2arr3140 - const yyr3140 bool = false - yyq3140[1] = true - yyq3140[2] = x.Reason != "" - yyq3140[3] = x.Message != "" - var yynn3140 int - if yyr3140 || yy2arr3140 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = true + yyq2[2] = x.Reason != "" + yyq2[3] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn3140 = 1 - for _, b := range yyq3140 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3140++ + yynn2++ } } - r.EncodeMapStart(yynn3140) - yynn3140 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3140 || yy2arr3140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3142 := &x.PodSignature - yy3142.CodecEncodeSelf(e) + yy4 := &x.PodSignature + yy4.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podSignature")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3143 := &x.PodSignature - yy3143.CodecEncodeSelf(e) + yy6 := &x.PodSignature + yy6.CodecEncodeSelf(e) } - if yyr3140 || yy2arr3140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3140[1] { - yy3145 := &x.EvictionTime - yym3146 := z.EncBinary() - _ = yym3146 + if yyq2[1] { + yy9 := &x.EvictionTime + yym10 := z.EncBinary() + _ = yym10 if false { - } else if z.HasExtensions() && z.EncExt(yy3145) { - } else if yym3146 { - z.EncBinaryMarshal(yy3145) - } else if !yym3146 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3145) + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if yym10 { + z.EncBinaryMarshal(yy9) + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) } else { - z.EncFallback(yy3145) + z.EncFallback(yy9) } } else { r.EncodeNil() } } else { - if yyq3140[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("evictionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3147 := &x.EvictionTime - yym3148 := z.EncBinary() - _ = yym3148 + yy11 := &x.EvictionTime + yym12 := z.EncBinary() + _ = yym12 if false { - } else if z.HasExtensions() && z.EncExt(yy3147) { - } else if yym3148 { - z.EncBinaryMarshal(yy3147) - } else if !yym3148 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3147) + } else if z.HasExtensions() && z.EncExt(yy11) { + } else if yym12 { + z.EncBinaryMarshal(yy11) + } else if !yym12 && z.IsJSONHandle() { + z.EncJSONMarshal(yy11) } else { - z.EncFallback(yy3147) + z.EncFallback(yy11) } } } - if yyr3140 || yy2arr3140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3140[2] { - yym3150 := z.EncBinary() - _ = yym3150 + if yyq2[2] { + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -40351,23 +50687,23 @@ func (x *PreferAvoidPodsEntry) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3140[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3151 := z.EncBinary() - _ = yym3151 + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr3140 || yy2arr3140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3140[3] { - yym3153 := z.EncBinary() - _ = yym3153 + if yyq2[3] { + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -40376,19 +50712,19 @@ func (x *PreferAvoidPodsEntry) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3140[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3154 := z.EncBinary() - _ = yym3154 + yym18 := z.EncBinary() + _ = yym18 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr3140 || yy2arr3140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -40401,25 +50737,25 @@ func (x *PreferAvoidPodsEntry) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3155 := z.DecBinary() - _ = yym3155 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3156 := r.ContainerType() - if yyct3156 == codecSelferValueTypeMap1234 { - yyl3156 := r.ReadMapStart() - if yyl3156 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3156, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3156 == codecSelferValueTypeArray1234 { - yyl3156 := r.ReadArrayStart() - if yyl3156 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3156, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -40431,12 +50767,12 @@ func (x *PreferAvoidPodsEntry) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3157Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3157Slc - var yyhl3157 bool = l >= 0 - for yyj3157 := 0; ; yyj3157++ { - if yyhl3157 { - if yyj3157 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -40445,50 +50781,62 @@ func (x *PreferAvoidPodsEntry) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3157Slc = r.DecodeBytes(yys3157Slc, true, true) - yys3157 := string(yys3157Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3157 { + switch yys3 { case "podSignature": if r.TryDecodeAsNil() { x.PodSignature = PodSignature{} } else { - yyv3158 := &x.PodSignature - yyv3158.CodecDecodeSelf(d) + yyv4 := &x.PodSignature + yyv4.CodecDecodeSelf(d) } case "evictionTime": if r.TryDecodeAsNil() { - x.EvictionTime = pkg2_unversioned.Time{} + x.EvictionTime = pkg2_v1.Time{} } else { - yyv3159 := &x.EvictionTime - yym3160 := z.DecBinary() - _ = yym3160 + yyv5 := &x.EvictionTime + yym6 := z.DecBinary() + _ = yym6 if false { - } else if z.HasExtensions() && z.DecExt(yyv3159) { - } else if yym3160 { - z.DecBinaryUnmarshal(yyv3159) - } else if !yym3160 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3159) + } else if z.HasExtensions() && z.DecExt(yyv5) { + } else if yym6 { + z.DecBinaryUnmarshal(yyv5) + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv5) } else { - z.DecFallback(yyv3159, false) + z.DecFallback(yyv5, false) } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv7 := &x.Reason + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv9 := &x.Message + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3157) - } // end switch yys3157 - } // end for yyj3157 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -40496,16 +50844,16 @@ func (x *PreferAvoidPodsEntry) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3163 int - var yyb3163 bool - var yyhl3163 bool = l >= 0 - yyj3163++ - if yyhl3163 { - yyb3163 = yyj3163 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3163 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3163 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40513,43 +50861,43 @@ func (x *PreferAvoidPodsEntry) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.PodSignature = PodSignature{} } else { - yyv3164 := &x.PodSignature - yyv3164.CodecDecodeSelf(d) + yyv12 := &x.PodSignature + yyv12.CodecDecodeSelf(d) } - yyj3163++ - if yyhl3163 { - yyb3163 = yyj3163 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3163 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3163 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.EvictionTime = pkg2_unversioned.Time{} + x.EvictionTime = pkg2_v1.Time{} } else { - yyv3165 := &x.EvictionTime - yym3166 := z.DecBinary() - _ = yym3166 + yyv13 := &x.EvictionTime + yym14 := z.DecBinary() + _ = yym14 if false { - } else if z.HasExtensions() && z.DecExt(yyv3165) { - } else if yym3166 { - z.DecBinaryUnmarshal(yyv3165) - } else if !yym3166 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3165) + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if yym14 { + z.DecBinaryUnmarshal(yyv13) + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) } else { - z.DecFallback(yyv3165, false) + z.DecFallback(yyv13, false) } } - yyj3163++ - if yyhl3163 { - yyb3163 = yyj3163 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3163 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3163 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40557,15 +50905,21 @@ func (x *PreferAvoidPodsEntry) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv15 := &x.Reason + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj3163++ - if yyhl3163 { - yyb3163 = yyj3163 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3163 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3163 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40573,20 +50927,26 @@ func (x *PreferAvoidPodsEntry) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv17 := &x.Message + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } for { - yyj3163++ - if yyhl3163 { - yyb3163 = yyj3163 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3163 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3163 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3163-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -40598,54 +50958,66 @@ func (x *PodSignature) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3169 := z.EncBinary() - _ = yym3169 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3170 := !z.EncBinary() - yy2arr3170 := z.EncBasicHandle().StructToArray - var yyq3170 [1]bool - _, _, _ = yysep3170, yyq3170, yy2arr3170 - const yyr3170 bool = false - yyq3170[0] = x.PodController != nil - var yynn3170 int - if yyr3170 || yy2arr3170 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PodController != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn3170 = 0 - for _, b := range yyq3170 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3170++ + yynn2++ } } - r.EncodeMapStart(yynn3170) - yynn3170 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3170 || yy2arr3170 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3170[0] { + if yyq2[0] { if x.PodController == nil { r.EncodeNil() } else { - x.PodController.CodecEncodeSelf(e) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodController) { + } else { + z.EncFallback(x.PodController) + } } } else { r.EncodeNil() } } else { - if yyq3170[0] { + if yyq2[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) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodController) { + } else { + z.EncFallback(x.PodController) + } } } } - if yyr3170 || yy2arr3170 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -40658,25 +51030,25 @@ func (x *PodSignature) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3172 := z.DecBinary() - _ = yym3172 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3173 := r.ContainerType() - if yyct3173 == codecSelferValueTypeMap1234 { - yyl3173 := r.ReadMapStart() - if yyl3173 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3173, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3173 == codecSelferValueTypeArray1234 { - yyl3173 := r.ReadArrayStart() - if yyl3173 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3173, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -40688,12 +51060,12 @@ func (x *PodSignature) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3174Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3174Slc - var yyhl3174 bool = l >= 0 - for yyj3174 := 0; ; yyj3174++ { - if yyhl3174 { - if yyj3174 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -40702,10 +51074,10 @@ func (x *PodSignature) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3174Slc = r.DecodeBytes(yys3174Slc, true, true) - yys3174 := string(yys3174Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3174 { + switch yys3 { case "podController": if r.TryDecodeAsNil() { if x.PodController != nil { @@ -40713,14 +51085,20 @@ func (x *PodSignature) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.PodController == nil { - x.PodController = new(OwnerReference) + x.PodController = new(pkg2_v1.OwnerReference) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodController) { + } else { + z.DecFallback(x.PodController, false) } - x.PodController.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys3174) - } // end switch yys3174 - } // end for yyj3174 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -40728,16 +51106,16 @@ func (x *PodSignature) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3176 int - var yyb3176 bool - var yyhl3176 bool = l >= 0 - yyj3176++ - if yyhl3176 { - yyb3176 = yyj3176 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3176 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3176 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40748,22 +51126,28 @@ func (x *PodSignature) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.PodController == nil { - x.PodController = new(OwnerReference) + x.PodController = new(pkg2_v1.OwnerReference) + } + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodController) { + } else { + z.DecFallback(x.PodController, false) } - x.PodController.CodecDecodeSelf(d) } for { - yyj3176++ - if yyhl3176 { - yyb3176 = yyj3176 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3176 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3176 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3176-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -40775,37 +51159,37 @@ func (x *ContainerImage) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3178 := z.EncBinary() - _ = yym3178 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3179 := !z.EncBinary() - yy2arr3179 := z.EncBasicHandle().StructToArray - var yyq3179 [2]bool - _, _, _ = yysep3179, yyq3179, yy2arr3179 - const yyr3179 bool = false - yyq3179[1] = x.SizeBytes != 0 - var yynn3179 int - if yyr3179 || yy2arr3179 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.SizeBytes != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn3179 = 1 - for _, b := range yyq3179 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3179++ + yynn2++ } } - r.EncodeMapStart(yynn3179) - yynn3179 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3179 || yy2arr3179 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Names == nil { r.EncodeNil() } else { - yym3181 := z.EncBinary() - _ = yym3181 + yym4 := z.EncBinary() + _ = yym4 if false { } else { z.F.EncSliceStringV(x.Names, false, e) @@ -40818,19 +51202,19 @@ func (x *ContainerImage) CodecEncodeSelf(e *codec1978.Encoder) { if x.Names == nil { r.EncodeNil() } else { - yym3182 := z.EncBinary() - _ = yym3182 + yym5 := z.EncBinary() + _ = yym5 if false { } else { z.F.EncSliceStringV(x.Names, false, e) } } } - if yyr3179 || yy2arr3179 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3179[1] { - yym3184 := z.EncBinary() - _ = yym3184 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.SizeBytes)) @@ -40839,19 +51223,19 @@ func (x *ContainerImage) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq3179[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("sizeBytes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3185 := z.EncBinary() - _ = yym3185 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.SizeBytes)) } } } - if yyr3179 || yy2arr3179 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -40864,25 +51248,25 @@ func (x *ContainerImage) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3186 := z.DecBinary() - _ = yym3186 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3187 := r.ContainerType() - if yyct3187 == codecSelferValueTypeMap1234 { - yyl3187 := r.ReadMapStart() - if yyl3187 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3187, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3187 == codecSelferValueTypeArray1234 { - yyl3187 := r.ReadArrayStart() - if yyl3187 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3187, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -40894,12 +51278,12 @@ func (x *ContainerImage) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3188Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3188Slc - var yyhl3188 bool = l >= 0 - for yyj3188 := 0; ; yyj3188++ { - if yyhl3188 { - if yyj3188 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -40908,32 +51292,38 @@ func (x *ContainerImage) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3188Slc = r.DecodeBytes(yys3188Slc, true, true) - yys3188 := string(yys3188Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3188 { + switch yys3 { case "names": if r.TryDecodeAsNil() { x.Names = nil } else { - yyv3189 := &x.Names - yym3190 := z.DecBinary() - _ = yym3190 + yyv4 := &x.Names + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv3189, false, d) + z.F.DecSliceStringX(yyv4, false, d) } } case "sizeBytes": if r.TryDecodeAsNil() { x.SizeBytes = 0 } else { - x.SizeBytes = int64(r.DecodeInt(64)) + yyv6 := &x.SizeBytes + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } } default: - z.DecStructFieldNotFound(-1, yys3188) - } // end switch yys3188 - } // end for yyj3188 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -40941,16 +51331,16 @@ func (x *ContainerImage) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3192 int - var yyb3192 bool - var yyhl3192 bool = l >= 0 - yyj3192++ - if yyhl3192 { - yyb3192 = yyj3192 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb3192 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb3192 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40958,21 +51348,21 @@ func (x *ContainerImage) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Names = nil } else { - yyv3193 := &x.Names - yym3194 := z.DecBinary() - _ = yym3194 + yyv9 := &x.Names + yym10 := z.DecBinary() + _ = yym10 if false { } else { - z.F.DecSliceStringX(yyv3193, false, d) + z.F.DecSliceStringX(yyv9, false, d) } } - yyj3192++ - if yyhl3192 { - yyb3192 = yyj3192 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb3192 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb3192 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -40980,20 +51370,26 @@ func (x *ContainerImage) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.SizeBytes = 0 } else { - x.SizeBytes = int64(r.DecodeInt(64)) + yyv11 := &x.SizeBytes + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int64)(yyv11)) = int64(r.DecodeInt(64)) + } } for { - yyj3192++ - if yyhl3192 { - yyb3192 = yyj3192 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb3192 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb3192 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3192-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -41002,8 +51398,8 @@ func (x NodePhase) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3196 := z.EncBinary() - _ = yym3196 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -41015,8 +51411,8 @@ func (x *NodePhase) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3197 := z.DecBinary() - _ = yym3197 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -41028,8 +51424,8 @@ func (x NodeConditionType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3198 := z.EncBinary() - _ = yym3198 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -41041,8 +51437,8 @@ func (x *NodeConditionType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3199 := z.DecBinary() - _ = yym3199 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -41057,34 +51453,34 @@ func (x *NodeCondition) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3200 := z.EncBinary() - _ = yym3200 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3201 := !z.EncBinary() - yy2arr3201 := z.EncBasicHandle().StructToArray - var yyq3201 [6]bool - _, _, _ = yysep3201, yyq3201, yy2arr3201 - const yyr3201 bool = false - yyq3201[2] = true - yyq3201[3] = true - yyq3201[4] = x.Reason != "" - yyq3201[5] = x.Message != "" - var yynn3201 int - if yyr3201 || yy2arr3201 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = true + yyq2[4] = x.Reason != "" + yyq2[5] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn3201 = 2 - for _, b := range yyq3201 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn3201++ + yynn2++ } } - r.EncodeMapStart(yynn3201) - yynn3201 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -41093,7 +51489,7 @@ func (x *NodeCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Status.CodecEncodeSelf(e) } else { @@ -41102,85 +51498,85 @@ func (x *NodeCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Status.CodecEncodeSelf(e) } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3201[2] { - yy3205 := &x.LastHeartbeatTime - yym3206 := z.EncBinary() - _ = yym3206 + if yyq2[2] { + yy10 := &x.LastHeartbeatTime + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy3205) { - } else if yym3206 { - z.EncBinaryMarshal(yy3205) - } else if !yym3206 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3205) + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - z.EncFallback(yy3205) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq3201[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastHeartbeatTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3207 := &x.LastHeartbeatTime - yym3208 := z.EncBinary() - _ = yym3208 + yy12 := &x.LastHeartbeatTime + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy3207) { - } else if yym3208 { - z.EncBinaryMarshal(yy3207) - } else if !yym3208 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3207) + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - z.EncFallback(yy3207) + z.EncFallback(yy12) } } } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3201[3] { - yy3210 := &x.LastTransitionTime - yym3211 := z.EncBinary() - _ = yym3211 + if yyq2[3] { + yy15 := &x.LastTransitionTime + yym16 := z.EncBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.EncExt(yy3210) { - } else if yym3211 { - z.EncBinaryMarshal(yy3210) - } else if !yym3211 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3210) + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) } else { - z.EncFallback(yy3210) + z.EncFallback(yy15) } } else { r.EncodeNil() } } else { - if yyq3201[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3212 := &x.LastTransitionTime - yym3213 := z.EncBinary() - _ = yym3213 + yy17 := &x.LastTransitionTime + yym18 := z.EncBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.EncExt(yy3212) { - } else if yym3213 { - z.EncBinaryMarshal(yy3212) - } else if !yym3213 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3212) + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if yym18 { + z.EncBinaryMarshal(yy17) + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) } else { - z.EncFallback(yy3212) + z.EncFallback(yy17) } } } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3201[4] { - yym3215 := z.EncBinary() - _ = yym3215 + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -41189,23 +51585,23 @@ func (x *NodeCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3201[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3216 := z.EncBinary() - _ = yym3216 + yym21 := z.EncBinary() + _ = yym21 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3201[5] { - yym3218 := z.EncBinary() - _ = yym3218 + if yyq2[5] { + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -41214,19 +51610,19 @@ func (x *NodeCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3201[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3219 := z.EncBinary() - _ = yym3219 + yym24 := z.EncBinary() + _ = yym24 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr3201 || yy2arr3201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -41239,25 +51635,25 @@ func (x *NodeCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3220 := z.DecBinary() - _ = yym3220 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3221 := r.ContainerType() - if yyct3221 == codecSelferValueTypeMap1234 { - yyl3221 := r.ReadMapStart() - if yyl3221 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3221, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3221 == codecSelferValueTypeArray1234 { - yyl3221 := r.ReadArrayStart() - if yyl3221 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3221, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -41269,12 +51665,12 @@ func (x *NodeCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3222Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3222Slc - var yyhl3222 bool = l >= 0 - for yyj3222 := 0; ; yyj3222++ { - if yyhl3222 { - if yyj3222 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -41283,72 +51679,86 @@ func (x *NodeCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3222Slc = r.DecodeBytes(yys3222Slc, true, true) - yys3222 := string(yys3222Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3222 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = NodeConditionType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } case "lastHeartbeatTime": if r.TryDecodeAsNil() { - x.LastHeartbeatTime = pkg2_unversioned.Time{} + x.LastHeartbeatTime = pkg2_v1.Time{} } else { - yyv3225 := &x.LastHeartbeatTime - yym3226 := z.DecBinary() - _ = yym3226 + yyv6 := &x.LastHeartbeatTime + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv3225) { - } else if yym3226 { - z.DecBinaryUnmarshal(yyv3225) - } else if !yym3226 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3225) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv3225, false) + z.DecFallback(yyv6, false) } } case "lastTransitionTime": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} + x.LastTransitionTime = pkg2_v1.Time{} } else { - yyv3227 := &x.LastTransitionTime - yym3228 := z.DecBinary() - _ = yym3228 + yyv8 := &x.LastTransitionTime + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv3227) { - } else if yym3228 { - z.DecBinaryUnmarshal(yyv3227) - } else if !yym3228 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3227) + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) } else { - z.DecFallback(yyv3227, false) + z.DecFallback(yyv8, false) } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv10 := &x.Reason + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv12 := &x.Message + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3222) - } // end switch yys3222 - } // end for yyj3222 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -41356,16 +51766,16 @@ func (x *NodeCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3231 int - var yyb3231 bool - var yyhl3231 bool = l >= 0 - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -41373,15 +51783,16 @@ func (x *NodeCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = NodeConditionType(r.DecodeString()) + yyv15 := &x.Type + yyv15.CodecDecodeSelf(d) } - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -41389,69 +51800,70 @@ func (x *NodeCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv16 := &x.Status + yyv16.CodecDecodeSelf(d) } - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastHeartbeatTime = pkg2_unversioned.Time{} + x.LastHeartbeatTime = pkg2_v1.Time{} } else { - yyv3234 := &x.LastHeartbeatTime - yym3235 := z.DecBinary() - _ = yym3235 + yyv17 := &x.LastHeartbeatTime + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv3234) { - } else if yym3235 { - z.DecBinaryUnmarshal(yyv3234) - } else if !yym3235 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3234) + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) } else { - z.DecFallback(yyv3234, false) + z.DecFallback(yyv17, false) } } - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg2_unversioned.Time{} + x.LastTransitionTime = pkg2_v1.Time{} } else { - yyv3236 := &x.LastTransitionTime - yym3237 := z.DecBinary() - _ = yym3237 + yyv19 := &x.LastTransitionTime + yym20 := z.DecBinary() + _ = yym20 if false { - } else if z.HasExtensions() && z.DecExt(yyv3236) { - } else if yym3237 { - z.DecBinaryUnmarshal(yyv3236) - } else if !yym3237 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3236) + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else if yym20 { + z.DecBinaryUnmarshal(yyv19) + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv19) } else { - z.DecFallback(yyv3236, false) + z.DecFallback(yyv19, false) } } - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -41459,15 +51871,21 @@ func (x *NodeCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv21 := &x.Reason + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -41475,20 +51893,26 @@ func (x *NodeCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv23 := &x.Message + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } for { - yyj3231++ - if yyhl3231 { - yyb3231 = yyj3231 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3231 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3231 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3231-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -41497,8 +51921,8 @@ func (x NodeAddressType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3240 := z.EncBinary() - _ = yym3240 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -41510,8 +51934,8 @@ func (x *NodeAddressType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3241 := z.DecBinary() - _ = yym3241 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -41526,30 +51950,30 @@ func (x *NodeAddress) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3242 := z.EncBinary() - _ = yym3242 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3243 := !z.EncBinary() - yy2arr3243 := z.EncBasicHandle().StructToArray - var yyq3243 [2]bool - _, _, _ = yysep3243, yyq3243, yy2arr3243 - const yyr3243 bool = false - var yynn3243 int - if yyr3243 || yy2arr3243 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn3243 = 2 - for _, b := range yyq3243 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn3243++ + yynn2++ } } - r.EncodeMapStart(yynn3243) - yynn3243 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3243 || yy2arr3243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -41558,10 +51982,10 @@ func (x *NodeAddress) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr3243 || yy2arr3243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3246 := z.EncBinary() - _ = yym3246 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Address)) @@ -41570,14 +51994,14 @@ func (x *NodeAddress) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("address")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3247 := z.EncBinary() - _ = yym3247 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Address)) } } - if yyr3243 || yy2arr3243 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -41590,25 +52014,25 @@ func (x *NodeAddress) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3248 := z.DecBinary() - _ = yym3248 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3249 := r.ContainerType() - if yyct3249 == codecSelferValueTypeMap1234 { - yyl3249 := r.ReadMapStart() - if yyl3249 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3249, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3249 == codecSelferValueTypeArray1234 { - yyl3249 := r.ReadArrayStart() - if yyl3249 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3249, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -41620,12 +52044,12 @@ func (x *NodeAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3250Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3250Slc - var yyhl3250 bool = l >= 0 - for yyj3250 := 0; ; yyj3250++ { - if yyhl3250 { - if yyj3250 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -41634,26 +52058,33 @@ func (x *NodeAddress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3250Slc = r.DecodeBytes(yys3250Slc, true, true) - yys3250 := string(yys3250Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3250 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = NodeAddressType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "address": if r.TryDecodeAsNil() { x.Address = "" } else { - x.Address = string(r.DecodeString()) + yyv5 := &x.Address + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3250) - } // end switch yys3250 - } // end for yyj3250 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -41661,16 +52092,16 @@ func (x *NodeAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3253 int - var yyb3253 bool - var yyhl3253 bool = l >= 0 - yyj3253++ - if yyhl3253 { - yyb3253 = yyj3253 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb3253 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb3253 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -41678,15 +52109,16 @@ func (x *NodeAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = NodeAddressType(r.DecodeString()) + yyv8 := &x.Type + yyv8.CodecDecodeSelf(d) } - yyj3253++ - if yyhl3253 { - yyb3253 = yyj3253 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb3253 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb3253 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -41694,20 +52126,26 @@ func (x *NodeAddress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Address = "" } else { - x.Address = string(r.DecodeString()) + yyv9 := &x.Address + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } for { - yyj3253++ - if yyhl3253 { - yyb3253 = yyj3253 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb3253 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb3253 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3253-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -41716,8 +52154,8 @@ func (x ResourceName) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3256 := z.EncBinary() - _ = yym3256 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -41729,8 +52167,8 @@ func (x *ResourceName) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3257 := z.DecBinary() - _ = yym3257 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -41745,8 +52183,8 @@ func (x ResourceList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3258 := z.EncBinary() - _ = yym3258 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -41759,8 +52197,8 @@ func (x *ResourceList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3259 := z.DecBinary() - _ = yym3259 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -41775,39 +52213,39 @@ func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3260 := z.EncBinary() - _ = yym3260 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3261 := !z.EncBinary() - yy2arr3261 := z.EncBasicHandle().StructToArray - var yyq3261 [5]bool - _, _, _ = yysep3261, yyq3261, yy2arr3261 - const yyr3261 bool = false - yyq3261[0] = x.Kind != "" - yyq3261[1] = x.APIVersion != "" - yyq3261[2] = true - yyq3261[3] = true - yyq3261[4] = true - var yynn3261 int - if yyr3261 || yy2arr3261 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn3261 = 0 - for _, b := range yyq3261 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3261++ + yynn2++ } } - r.EncodeMapStart(yynn3261) - yynn3261 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3261 || yy2arr3261 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3261[0] { - yym3263 := z.EncBinary() - _ = yym3263 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -41816,23 +52254,23 @@ func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3261[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3264 := z.EncBinary() - _ = yym3264 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3261 || yy2arr3261 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3261[1] { - yym3266 := z.EncBinary() - _ = yym3266 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -41841,70 +52279,82 @@ func (x *Node) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3261[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3267 := z.EncBinary() - _ = yym3267 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3261 || yy2arr3261 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3261[2] { - yy3269 := &x.ObjectMeta - yy3269.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq3261[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3270 := &x.ObjectMeta - yy3270.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr3261 || yy2arr3261 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3261[3] { - yy3272 := &x.Spec - yy3272.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3261[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3273 := &x.Spec - yy3273.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr3261 || yy2arr3261 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3261[4] { - yy3275 := &x.Status - yy3275.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3261[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3276 := &x.Status - yy3276.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr3261 || yy2arr3261 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -41917,25 +52367,25 @@ func (x *Node) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3277 := z.DecBinary() - _ = yym3277 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3278 := r.ContainerType() - if yyct3278 == codecSelferValueTypeMap1234 { - yyl3278 := r.ReadMapStart() - if yyl3278 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3278, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3278 == codecSelferValueTypeArray1234 { - yyl3278 := r.ReadArrayStart() - if yyl3278 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3278, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -41947,12 +52397,12 @@ func (x *Node) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3279Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3279Slc - var yyhl3279 bool = l >= 0 - for yyj3279 := 0; ; yyj3279++ { - if yyhl3279 { - if yyj3279 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -41961,47 +52411,65 @@ func (x *Node) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3279Slc = r.DecodeBytes(yys3279Slc, true, true) - yys3279 := string(yys3279Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3279 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3282 := &x.ObjectMeta - yyv3282.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = NodeSpec{} } else { - yyv3283 := &x.Spec - yyv3283.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = NodeStatus{} } else { - yyv3284 := &x.Status - yyv3284.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys3279) - } // end switch yys3279 - } // end for yyj3279 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -42009,16 +52477,16 @@ func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3285 int - var yyb3285 bool - var yyhl3285 bool = l >= 0 - yyj3285++ - if yyhl3285 { - yyb3285 = yyj3285 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3285 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3285 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42026,15 +52494,21 @@ func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3285++ - if yyhl3285 { - yyb3285 = yyj3285 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3285 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3285 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42042,32 +52516,44 @@ func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj3285++ - if yyhl3285 { - yyb3285 = yyj3285 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3285 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3285 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3288 := &x.ObjectMeta - yyv3288.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj3285++ - if yyhl3285 { - yyb3285 = yyj3285 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3285 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3285 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42075,16 +52561,16 @@ func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = NodeSpec{} } else { - yyv3289 := &x.Spec - yyv3289.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj3285++ - if yyhl3285 { - yyb3285 = yyj3285 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3285 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3285 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42092,21 +52578,21 @@ func (x *Node) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = NodeStatus{} } else { - yyv3290 := &x.Status - yyv3290.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj3285++ - if yyhl3285 { - yyb3285 = yyj3285 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3285 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3285 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3285-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -42118,37 +52604,37 @@ func (x *NodeList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3291 := z.EncBinary() - _ = yym3291 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3292 := !z.EncBinary() - yy2arr3292 := z.EncBasicHandle().StructToArray - var yyq3292 [4]bool - _, _, _ = yysep3292, yyq3292, yy2arr3292 - const yyr3292 bool = false - yyq3292[0] = x.Kind != "" - yyq3292[1] = x.APIVersion != "" - yyq3292[2] = true - var yynn3292 int - if yyr3292 || yy2arr3292 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn3292 = 1 - for _, b := range yyq3292 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3292++ + yynn2++ } } - r.EncodeMapStart(yynn3292) - yynn3292 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3292 || yy2arr3292 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3292[0] { - yym3294 := z.EncBinary() - _ = yym3294 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -42157,23 +52643,23 @@ func (x *NodeList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3292[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3295 := z.EncBinary() - _ = yym3295 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3292 || yy2arr3292 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3292[1] { - yym3297 := z.EncBinary() - _ = yym3297 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -42182,54 +52668,54 @@ func (x *NodeList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3292[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3298 := z.EncBinary() - _ = yym3298 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3292 || yy2arr3292 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3292[2] { - yy3300 := &x.ListMeta - yym3301 := z.EncBinary() - _ = yym3301 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy3300) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy3300) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq3292[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3302 := &x.ListMeta - yym3303 := z.EncBinary() - _ = yym3303 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy3302) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy3302) + z.EncFallback(yy12) } } } - if yyr3292 || yy2arr3292 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym3305 := z.EncBinary() - _ = yym3305 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceNode(([]Node)(x.Items), e) @@ -42242,15 +52728,15 @@ func (x *NodeList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym3306 := z.EncBinary() - _ = yym3306 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceNode(([]Node)(x.Items), e) } } } - if yyr3292 || yy2arr3292 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -42263,25 +52749,25 @@ func (x *NodeList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3307 := z.DecBinary() - _ = yym3307 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3308 := r.ContainerType() - if yyct3308 == codecSelferValueTypeMap1234 { - yyl3308 := r.ReadMapStart() - if yyl3308 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3308, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3308 == codecSelferValueTypeArray1234 { - yyl3308 := r.ReadArrayStart() - if yyl3308 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3308, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -42293,12 +52779,12 @@ func (x *NodeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3309Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3309Slc - var yyhl3309 bool = l >= 0 - for yyj3309 := 0; ; yyj3309++ { - if yyhl3309 { - if yyj3309 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -42307,51 +52793,63 @@ func (x *NodeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3309Slc = r.DecodeBytes(yys3309Slc, true, true) - yys3309 := string(yys3309Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3309 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv3312 := &x.ListMeta - yym3313 := z.DecBinary() - _ = yym3313 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv3312) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv3312, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv3314 := &x.Items - yym3315 := z.DecBinary() - _ = yym3315 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceNode((*[]Node)(yyv3314), d) + h.decSliceNode((*[]Node)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys3309) - } // end switch yys3309 - } // end for yyj3309 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -42359,16 +52857,16 @@ func (x *NodeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3316 int - var yyb3316 bool - var yyhl3316 bool = l >= 0 - yyj3316++ - if yyhl3316 { - yyb3316 = yyj3316 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3316 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3316 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42376,15 +52874,21 @@ func (x *NodeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3316++ - if yyhl3316 { - yyb3316 = yyj3316 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3316 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3316 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42392,38 +52896,44 @@ func (x *NodeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj3316++ - if yyhl3316 { - yyb3316 = yyj3316 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3316 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3316 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv3319 := &x.ListMeta - yym3320 := z.DecBinary() - _ = yym3320 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv3319) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv3319, false) + z.DecFallback(yyv17, false) } } - yyj3316++ - if yyhl3316 { - yyb3316 = yyj3316 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3316 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3316 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42431,26 +52941,26 @@ func (x *NodeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv3321 := &x.Items - yym3322 := z.DecBinary() - _ = yym3322 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceNode((*[]Node)(yyv3321), d) + h.decSliceNode((*[]Node)(yyv19), d) } } for { - yyj3316++ - if yyhl3316 { - yyb3316 = yyj3316 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3316 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3316 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3316-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -42459,8 +52969,8 @@ func (x FinalizerName) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3323 := z.EncBinary() - _ = yym3323 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -42472,8 +52982,8 @@ func (x *FinalizerName) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3324 := z.DecBinary() - _ = yym3324 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -42488,38 +52998,38 @@ func (x *NamespaceSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3325 := z.EncBinary() - _ = yym3325 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3326 := !z.EncBinary() - yy2arr3326 := z.EncBasicHandle().StructToArray - var yyq3326 [1]bool - _, _, _ = yysep3326, yyq3326, yy2arr3326 - const yyr3326 bool = false - yyq3326[0] = len(x.Finalizers) != 0 - var yynn3326 int - if yyr3326 || yy2arr3326 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Finalizers) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn3326 = 0 - for _, b := range yyq3326 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3326++ + yynn2++ } } - r.EncodeMapStart(yynn3326) - yynn3326 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3326 || yy2arr3326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3326[0] { + if yyq2[0] { if x.Finalizers == nil { r.EncodeNil() } else { - yym3328 := z.EncBinary() - _ = yym3328 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e) @@ -42529,15 +53039,15 @@ func (x *NamespaceSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3326[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("finalizers")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Finalizers == nil { r.EncodeNil() } else { - yym3329 := z.EncBinary() - _ = yym3329 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceFinalizerName(([]FinalizerName)(x.Finalizers), e) @@ -42545,7 +53055,7 @@ func (x *NamespaceSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3326 || yy2arr3326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -42558,25 +53068,25 @@ func (x *NamespaceSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3330 := z.DecBinary() - _ = yym3330 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3331 := r.ContainerType() - if yyct3331 == codecSelferValueTypeMap1234 { - yyl3331 := r.ReadMapStart() - if yyl3331 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3331, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3331 == codecSelferValueTypeArray1234 { - yyl3331 := r.ReadArrayStart() - if yyl3331 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3331, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -42588,12 +53098,12 @@ func (x *NamespaceSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3332Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3332Slc - var yyhl3332 bool = l >= 0 - for yyj3332 := 0; ; yyj3332++ { - if yyhl3332 { - if yyj3332 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -42602,26 +53112,26 @@ func (x *NamespaceSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3332Slc = r.DecodeBytes(yys3332Slc, true, true) - yys3332 := string(yys3332Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3332 { + switch yys3 { case "finalizers": if r.TryDecodeAsNil() { x.Finalizers = nil } else { - yyv3333 := &x.Finalizers - yym3334 := z.DecBinary() - _ = yym3334 + yyv4 := &x.Finalizers + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceFinalizerName((*[]FinalizerName)(yyv3333), d) + h.decSliceFinalizerName((*[]FinalizerName)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys3332) - } // end switch yys3332 - } // end for yyj3332 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -42629,16 +53139,16 @@ func (x *NamespaceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3335 int - var yyb3335 bool - var yyhl3335 bool = l >= 0 - yyj3335++ - if yyhl3335 { - yyb3335 = yyj3335 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3335 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3335 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42646,26 +53156,26 @@ func (x *NamespaceSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Finalizers = nil } else { - yyv3336 := &x.Finalizers - yym3337 := z.DecBinary() - _ = yym3337 + yyv7 := &x.Finalizers + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceFinalizerName((*[]FinalizerName)(yyv3336), d) + h.decSliceFinalizerName((*[]FinalizerName)(yyv7), d) } } for { - yyj3335++ - if yyhl3335 { - yyb3335 = yyj3335 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3335 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3335 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3335-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -42677,46 +53187,46 @@ func (x *NamespaceStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3338 := z.EncBinary() - _ = yym3338 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3339 := !z.EncBinary() - yy2arr3339 := z.EncBasicHandle().StructToArray - var yyq3339 [1]bool - _, _, _ = yysep3339, yyq3339, yy2arr3339 - const yyr3339 bool = false - yyq3339[0] = x.Phase != "" - var yynn3339 int - if yyr3339 || yy2arr3339 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Phase != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn3339 = 0 - for _, b := range yyq3339 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3339++ + yynn2++ } } - r.EncodeMapStart(yynn3339) - yynn3339 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3339 || yy2arr3339 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3339[0] { + if yyq2[0] { x.Phase.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3339[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("phase")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Phase.CodecEncodeSelf(e) } } - if yyr3339 || yy2arr3339 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -42729,25 +53239,25 @@ func (x *NamespaceStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3341 := z.DecBinary() - _ = yym3341 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3342 := r.ContainerType() - if yyct3342 == codecSelferValueTypeMap1234 { - yyl3342 := r.ReadMapStart() - if yyl3342 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3342, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3342 == codecSelferValueTypeArray1234 { - yyl3342 := r.ReadArrayStart() - if yyl3342 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3342, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -42759,12 +53269,12 @@ func (x *NamespaceStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3343Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3343Slc - var yyhl3343 bool = l >= 0 - for yyj3343 := 0; ; yyj3343++ { - if yyhl3343 { - if yyj3343 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -42773,20 +53283,21 @@ func (x *NamespaceStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3343Slc = r.DecodeBytes(yys3343Slc, true, true) - yys3343 := string(yys3343Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3343 { + switch yys3 { case "phase": if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = NamespacePhase(r.DecodeString()) + yyv4 := &x.Phase + yyv4.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys3343) - } // end switch yys3343 - } // end for yyj3343 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -42794,16 +53305,16 @@ func (x *NamespaceStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3345 int - var yyb3345 bool - var yyhl3345 bool = l >= 0 - yyj3345++ - if yyhl3345 { - yyb3345 = yyj3345 > l + var yyj5 int + var yyb5 bool + var yyhl5 bool = l >= 0 + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb3345 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb3345 { + if yyb5 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -42811,20 +53322,21 @@ func (x *NamespaceStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Phase = "" } else { - x.Phase = NamespacePhase(r.DecodeString()) + yyv6 := &x.Phase + yyv6.CodecDecodeSelf(d) } for { - yyj3345++ - if yyhl3345 { - yyb3345 = yyj3345 > l + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb3345 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb3345 { + if yyb5 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3345-1, "") + z.DecStructFieldNotFound(yyj5-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -42833,8 +53345,8 @@ func (x NamespacePhase) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym3347 := z.EncBinary() - _ = yym3347 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -42846,8 +53358,8 @@ func (x *NamespacePhase) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3348 := z.DecBinary() - _ = yym3348 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -42862,39 +53374,39 @@ func (x *Namespace) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3349 := z.EncBinary() - _ = yym3349 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3350 := !z.EncBinary() - yy2arr3350 := z.EncBasicHandle().StructToArray - var yyq3350 [5]bool - _, _, _ = yysep3350, yyq3350, yy2arr3350 - const yyr3350 bool = false - yyq3350[0] = x.Kind != "" - yyq3350[1] = x.APIVersion != "" - yyq3350[2] = true - yyq3350[3] = true - yyq3350[4] = true - var yynn3350 int - if yyr3350 || yy2arr3350 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn3350 = 0 - for _, b := range yyq3350 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3350++ + yynn2++ } } - r.EncodeMapStart(yynn3350) - yynn3350 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3350 || yy2arr3350 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3350[0] { - yym3352 := z.EncBinary() - _ = yym3352 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -42903,23 +53415,23 @@ func (x *Namespace) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3350[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3353 := z.EncBinary() - _ = yym3353 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3350 || yy2arr3350 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3350[1] { - yym3355 := z.EncBinary() - _ = yym3355 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -42928,70 +53440,82 @@ func (x *Namespace) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3350[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3356 := z.EncBinary() - _ = yym3356 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3350 || yy2arr3350 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3350[2] { - yy3358 := &x.ObjectMeta - yy3358.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq3350[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3359 := &x.ObjectMeta - yy3359.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr3350 || yy2arr3350 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3350[3] { - yy3361 := &x.Spec - yy3361.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3350[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3362 := &x.Spec - yy3362.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr3350 || yy2arr3350 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3350[4] { - yy3364 := &x.Status - yy3364.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3350[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3365 := &x.Status - yy3365.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr3350 || yy2arr3350 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -43004,25 +53528,25 @@ func (x *Namespace) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3366 := z.DecBinary() - _ = yym3366 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3367 := r.ContainerType() - if yyct3367 == codecSelferValueTypeMap1234 { - yyl3367 := r.ReadMapStart() - if yyl3367 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3367, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3367 == codecSelferValueTypeArray1234 { - yyl3367 := r.ReadArrayStart() - if yyl3367 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3367, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -43034,12 +53558,12 @@ func (x *Namespace) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3368Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3368Slc - var yyhl3368 bool = l >= 0 - for yyj3368 := 0; ; yyj3368++ { - if yyhl3368 { - if yyj3368 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -43048,47 +53572,65 @@ func (x *Namespace) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3368Slc = r.DecodeBytes(yys3368Slc, true, true) - yys3368 := string(yys3368Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3368 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3371 := &x.ObjectMeta - yyv3371.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = NamespaceSpec{} } else { - yyv3372 := &x.Spec - yyv3372.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = NamespaceStatus{} } else { - yyv3373 := &x.Status - yyv3373.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys3368) - } // end switch yys3368 - } // end for yyj3368 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -43096,16 +53638,16 @@ func (x *Namespace) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3374 int - var yyb3374 bool - var yyhl3374 bool = l >= 0 - yyj3374++ - if yyhl3374 { - yyb3374 = yyj3374 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3374 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3374 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43113,15 +53655,21 @@ func (x *Namespace) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3374++ - if yyhl3374 { - yyb3374 = yyj3374 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3374 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3374 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43129,32 +53677,44 @@ func (x *Namespace) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj3374++ - if yyhl3374 { - yyb3374 = yyj3374 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3374 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3374 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3377 := &x.ObjectMeta - yyv3377.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj3374++ - if yyhl3374 { - yyb3374 = yyj3374 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3374 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3374 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43162,16 +53722,16 @@ func (x *Namespace) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = NamespaceSpec{} } else { - yyv3378 := &x.Spec - yyv3378.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj3374++ - if yyhl3374 { - yyb3374 = yyj3374 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3374 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3374 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43179,21 +53739,21 @@ func (x *Namespace) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = NamespaceStatus{} } else { - yyv3379 := &x.Status - yyv3379.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj3374++ - if yyhl3374 { - yyb3374 = yyj3374 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3374 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3374 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3374-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -43205,37 +53765,37 @@ func (x *NamespaceList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3380 := z.EncBinary() - _ = yym3380 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3381 := !z.EncBinary() - yy2arr3381 := z.EncBasicHandle().StructToArray - var yyq3381 [4]bool - _, _, _ = yysep3381, yyq3381, yy2arr3381 - const yyr3381 bool = false - yyq3381[0] = x.Kind != "" - yyq3381[1] = x.APIVersion != "" - yyq3381[2] = true - var yynn3381 int - if yyr3381 || yy2arr3381 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn3381 = 1 - for _, b := range yyq3381 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3381++ + yynn2++ } } - r.EncodeMapStart(yynn3381) - yynn3381 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3381 || yy2arr3381 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3381[0] { - yym3383 := z.EncBinary() - _ = yym3383 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -43244,23 +53804,23 @@ func (x *NamespaceList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3381[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3384 := z.EncBinary() - _ = yym3384 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3381 || yy2arr3381 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3381[1] { - yym3386 := z.EncBinary() - _ = yym3386 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -43269,54 +53829,54 @@ func (x *NamespaceList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3381[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3387 := z.EncBinary() - _ = yym3387 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3381 || yy2arr3381 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3381[2] { - yy3389 := &x.ListMeta - yym3390 := z.EncBinary() - _ = yym3390 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy3389) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy3389) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq3381[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3391 := &x.ListMeta - yym3392 := z.EncBinary() - _ = yym3392 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy3391) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy3391) + z.EncFallback(yy12) } } } - if yyr3381 || yy2arr3381 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym3394 := z.EncBinary() - _ = yym3394 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceNamespace(([]Namespace)(x.Items), e) @@ -43329,15 +53889,15 @@ func (x *NamespaceList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym3395 := z.EncBinary() - _ = yym3395 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceNamespace(([]Namespace)(x.Items), e) } } } - if yyr3381 || yy2arr3381 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -43350,25 +53910,25 @@ func (x *NamespaceList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3396 := z.DecBinary() - _ = yym3396 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3397 := r.ContainerType() - if yyct3397 == codecSelferValueTypeMap1234 { - yyl3397 := r.ReadMapStart() - if yyl3397 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3397, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3397 == codecSelferValueTypeArray1234 { - yyl3397 := r.ReadArrayStart() - if yyl3397 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3397, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -43380,12 +53940,12 @@ func (x *NamespaceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3398Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3398Slc - var yyhl3398 bool = l >= 0 - for yyj3398 := 0; ; yyj3398++ { - if yyhl3398 { - if yyj3398 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -43394,51 +53954,63 @@ func (x *NamespaceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3398Slc = r.DecodeBytes(yys3398Slc, true, true) - yys3398 := string(yys3398Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3398 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv3401 := &x.ListMeta - yym3402 := z.DecBinary() - _ = yym3402 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv3401) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv3401, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv3403 := &x.Items - yym3404 := z.DecBinary() - _ = yym3404 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceNamespace((*[]Namespace)(yyv3403), d) + h.decSliceNamespace((*[]Namespace)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys3398) - } // end switch yys3398 - } // end for yyj3398 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -43446,16 +54018,16 @@ func (x *NamespaceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3405 int - var yyb3405 bool - var yyhl3405 bool = l >= 0 - yyj3405++ - if yyhl3405 { - yyb3405 = yyj3405 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3405 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3405 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43463,15 +54035,21 @@ func (x *NamespaceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3405++ - if yyhl3405 { - yyb3405 = yyj3405 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3405 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3405 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43479,38 +54057,44 @@ func (x *NamespaceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj3405++ - if yyhl3405 { - yyb3405 = yyj3405 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3405 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3405 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv3408 := &x.ListMeta - yym3409 := z.DecBinary() - _ = yym3409 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv3408) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv3408, false) + z.DecFallback(yyv17, false) } } - yyj3405++ - if yyhl3405 { - yyb3405 = yyj3405 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3405 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3405 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43518,26 +54102,26 @@ func (x *NamespaceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv3410 := &x.Items - yym3411 := z.DecBinary() - _ = yym3411 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceNamespace((*[]Namespace)(yyv3410), d) + h.decSliceNamespace((*[]Namespace)(yyv19), d) } } for { - yyj3405++ - if yyhl3405 { - yyb3405 = yyj3405 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb3405 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb3405 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3405-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -43549,37 +54133,37 @@ func (x *Binding) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3412 := z.EncBinary() - _ = yym3412 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3413 := !z.EncBinary() - yy2arr3413 := z.EncBasicHandle().StructToArray - var yyq3413 [4]bool - _, _, _ = yysep3413, yyq3413, yy2arr3413 - const yyr3413 bool = false - yyq3413[0] = x.Kind != "" - yyq3413[1] = x.APIVersion != "" - yyq3413[2] = true - var yynn3413 int - if yyr3413 || yy2arr3413 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn3413 = 1 - for _, b := range yyq3413 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3413++ + yynn2++ } } - r.EncodeMapStart(yynn3413) - yynn3413 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3413 || yy2arr3413 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3413[0] { - yym3415 := z.EncBinary() - _ = yym3415 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -43588,23 +54172,23 @@ func (x *Binding) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3413[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3416 := z.EncBinary() - _ = yym3416 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3413 || yy2arr3413 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3413[1] { - yym3418 := z.EncBinary() - _ = yym3418 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -43613,47 +54197,59 @@ func (x *Binding) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3413[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3419 := z.EncBinary() - _ = yym3419 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3413 || yy2arr3413 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3413[2] { - yy3421 := &x.ObjectMeta - yy3421.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq3413[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3422 := &x.ObjectMeta - yy3422.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr3413 || yy2arr3413 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3424 := &x.Target - yy3424.CodecEncodeSelf(e) + yy15 := &x.Target + yy15.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("target")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3425 := &x.Target - yy3425.CodecEncodeSelf(e) + yy17 := &x.Target + yy17.CodecEncodeSelf(e) } - if yyr3413 || yy2arr3413 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -43666,25 +54262,25 @@ func (x *Binding) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3426 := z.DecBinary() - _ = yym3426 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3427 := r.ContainerType() - if yyct3427 == codecSelferValueTypeMap1234 { - yyl3427 := r.ReadMapStart() - if yyl3427 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3427, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3427 == codecSelferValueTypeArray1234 { - yyl3427 := r.ReadArrayStart() - if yyl3427 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3427, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -43696,12 +54292,12 @@ func (x *Binding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3428Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3428Slc - var yyhl3428 bool = l >= 0 - for yyj3428 := 0; ; yyj3428++ { - if yyhl3428 { - if yyj3428 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -43710,40 +54306,58 @@ func (x *Binding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3428Slc = r.DecodeBytes(yys3428Slc, true, true) - yys3428 := string(yys3428Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3428 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3431 := &x.ObjectMeta - yyv3431.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "target": if r.TryDecodeAsNil() { x.Target = ObjectReference{} } else { - yyv3432 := &x.Target - yyv3432.CodecDecodeSelf(d) + yyv10 := &x.Target + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys3428) - } // end switch yys3428 - } // end for yyj3428 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -43751,16 +54365,16 @@ func (x *Binding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3433 int - var yyb3433 bool - var yyhl3433 bool = l >= 0 - yyj3433++ - if yyhl3433 { - yyb3433 = yyj3433 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3433 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3433 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43768,15 +54382,21 @@ func (x *Binding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj3433++ - if yyhl3433 { - yyb3433 = yyj3433 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3433 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3433 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43784,32 +54404,44 @@ func (x *Binding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj3433++ - if yyhl3433 { - yyb3433 = yyj3433 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3433 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3433 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3436 := &x.ObjectMeta - yyv3436.CodecDecodeSelf(d) + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } } - yyj3433++ - if yyhl3433 { - yyb3433 = yyj3433 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3433 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3433 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -43817,21 +54449,21 @@ func (x *Binding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Target = ObjectReference{} } else { - yyv3437 := &x.Target - yyv3437.CodecDecodeSelf(d) + yyv18 := &x.Target + yyv18.CodecDecodeSelf(d) } for { - yyj3433++ - if yyhl3433 { - yyb3433 = yyj3433 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb3433 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb3433 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3433-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -43843,68 +54475,68 @@ func (x *Preconditions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3438 := z.EncBinary() - _ = yym3438 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3439 := !z.EncBinary() - yy2arr3439 := z.EncBasicHandle().StructToArray - var yyq3439 [1]bool - _, _, _ = yysep3439, yyq3439, yy2arr3439 - const yyr3439 bool = false - yyq3439[0] = x.UID != nil - var yynn3439 int - if yyr3439 || yy2arr3439 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.UID != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn3439 = 0 - for _, b := range yyq3439 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3439++ + yynn2++ } } - r.EncodeMapStart(yynn3439) - yynn3439 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3439 || yy2arr3439 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3439[0] { + if yyq2[0] { if x.UID == nil { r.EncodeNil() } else { - yy3441 := *x.UID - yym3442 := z.EncBinary() - _ = yym3442 + yy4 := *x.UID + yym5 := z.EncBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.EncExt(yy3441) { + } else if z.HasExtensions() && z.EncExt(yy4) { } else { - r.EncodeString(codecSelferC_UTF81234, string(yy3441)) + r.EncodeString(codecSelferC_UTF81234, string(yy4)) } } } else { r.EncodeNil() } } else { - if yyq3439[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("uid")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.UID == nil { r.EncodeNil() } else { - yy3443 := *x.UID - yym3444 := z.EncBinary() - _ = yym3444 + yy6 := *x.UID + yym7 := z.EncBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.EncExt(yy3443) { + } else if z.HasExtensions() && z.EncExt(yy6) { } else { - r.EncodeString(codecSelferC_UTF81234, string(yy3443)) + r.EncodeString(codecSelferC_UTF81234, string(yy6)) } } } } - if yyr3439 || yy2arr3439 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -43917,25 +54549,25 @@ func (x *Preconditions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3445 := z.DecBinary() - _ = yym3445 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3446 := r.ContainerType() - if yyct3446 == codecSelferValueTypeMap1234 { - yyl3446 := r.ReadMapStart() - if yyl3446 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3446, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3446 == codecSelferValueTypeArray1234 { - yyl3446 := r.ReadArrayStart() - if yyl3446 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3446, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -43947,12 +54579,12 @@ func (x *Preconditions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3447Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3447Slc - var yyhl3447 bool = l >= 0 - for yyj3447 := 0; ; yyj3447++ { - if yyhl3447 { - if yyj3447 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -43961,10 +54593,10 @@ func (x *Preconditions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3447Slc = r.DecodeBytes(yys3447Slc, true, true) - yys3447 := string(yys3447Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3447 { + switch yys3 { case "uid": if r.TryDecodeAsNil() { if x.UID != nil { @@ -43974,8 +54606,8 @@ func (x *Preconditions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.UID == nil { x.UID = new(pkg1_types.UID) } - yym3449 := z.DecBinary() - _ = yym3449 + yym5 := z.DecBinary() + _ = yym5 if false { } else if z.HasExtensions() && z.DecExt(x.UID) { } else { @@ -43983,9 +54615,9 @@ func (x *Preconditions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } default: - z.DecStructFieldNotFound(-1, yys3447) - } // end switch yys3447 - } // end for yyj3447 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -43993,16 +54625,16 @@ func (x *Preconditions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3450 int - var yyb3450 bool - var yyhl3450 bool = l >= 0 - yyj3450++ - if yyhl3450 { - yyb3450 = yyj3450 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3450 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3450 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -44015,8 +54647,8 @@ func (x *Preconditions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.UID == nil { x.UID = new(pkg1_types.UID) } - yym3452 := z.DecBinary() - _ = yym3452 + yym8 := z.DecBinary() + _ = yym8 if false { } else if z.HasExtensions() && z.DecExt(x.UID) { } else { @@ -44024,21 +54656,47 @@ func (x *Preconditions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } for { - yyj3450++ - if yyhl3450 { - yyb3450 = yyj3450 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3450 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3450 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3450-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } +func (x DeletionPropagation) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *DeletionPropagation) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) @@ -44046,39 +54704,39 @@ func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3453 := z.EncBinary() - _ = yym3453 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3454 := !z.EncBinary() - yy2arr3454 := z.EncBasicHandle().StructToArray - var yyq3454 [5]bool - _, _, _ = yysep3454, yyq3454, yy2arr3454 - const yyr3454 bool = false - yyq3454[0] = x.Kind != "" - yyq3454[1] = x.APIVersion != "" - yyq3454[2] = x.GracePeriodSeconds != nil - yyq3454[3] = x.Preconditions != nil - yyq3454[4] = x.OrphanDependents != nil - var yynn3454 int - if yyr3454 || yy2arr3454 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.GracePeriodSeconds != nil + yyq2[3] = x.Preconditions != nil + yyq2[4] = x.OrphanDependents != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) } else { - yynn3454 = 0 - for _, b := range yyq3454 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3454++ + yynn2++ } } - r.EncodeMapStart(yynn3454) - yynn3454 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3454 || yy2arr3454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3454[0] { - yym3456 := z.EncBinary() - _ = yym3456 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -44087,23 +54745,23 @@ func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3454[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3457 := z.EncBinary() - _ = yym3457 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3454 || yy2arr3454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3454[1] { - yym3459 := z.EncBinary() - _ = yym3459 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -44112,56 +54770,56 @@ func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3454[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3460 := z.EncBinary() - _ = yym3460 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3454 || yy2arr3454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3454[2] { + if yyq2[2] { if x.GracePeriodSeconds == nil { r.EncodeNil() } else { - yy3462 := *x.GracePeriodSeconds - yym3463 := z.EncBinary() - _ = yym3463 + yy10 := *x.GracePeriodSeconds + yym11 := z.EncBinary() + _ = yym11 if false { } else { - r.EncodeInt(int64(yy3462)) + r.EncodeInt(int64(yy10)) } } } else { r.EncodeNil() } } else { - if yyq3454[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("gracePeriodSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.GracePeriodSeconds == nil { r.EncodeNil() } else { - yy3464 := *x.GracePeriodSeconds - yym3465 := z.EncBinary() - _ = yym3465 + yy12 := *x.GracePeriodSeconds + yym13 := z.EncBinary() + _ = yym13 if false { } else { - r.EncodeInt(int64(yy3464)) + r.EncodeInt(int64(yy12)) } } } } - if yyr3454 || yy2arr3454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3454[3] { + if yyq2[3] { if x.Preconditions == nil { r.EncodeNil() } else { @@ -44171,7 +54829,7 @@ func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3454[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("preconditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -44182,42 +54840,61 @@ func (x *DeleteOptions) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3454 || yy2arr3454 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3454[4] { + if yyq2[4] { if x.OrphanDependents == nil { r.EncodeNil() } else { - yy3468 := *x.OrphanDependents - yym3469 := z.EncBinary() - _ = yym3469 + yy18 := *x.OrphanDependents + yym19 := z.EncBinary() + _ = yym19 if false { } else { - r.EncodeBool(bool(yy3468)) + r.EncodeBool(bool(yy18)) } } } else { r.EncodeNil() } } else { - if yyq3454[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("orphanDependents")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.OrphanDependents == nil { r.EncodeNil() } else { - yy3470 := *x.OrphanDependents - yym3471 := z.EncBinary() - _ = yym3471 + yy20 := *x.OrphanDependents + yym21 := z.EncBinary() + _ = yym21 if false { } else { - r.EncodeBool(bool(yy3470)) + r.EncodeBool(bool(yy20)) } } } } - if yyr3454 || yy2arr3454 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.PropagationPolicy == nil { + r.EncodeNil() + } else { + yy23 := *x.PropagationPolicy + yy23.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("PropagationPolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.PropagationPolicy == nil { + r.EncodeNil() + } else { + yy25 := *x.PropagationPolicy + yy25.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -44230,25 +54907,25 @@ func (x *DeleteOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3472 := z.DecBinary() - _ = yym3472 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3473 := r.ContainerType() - if yyct3473 == codecSelferValueTypeMap1234 { - yyl3473 := r.ReadMapStart() - if yyl3473 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3473, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3473 == codecSelferValueTypeArray1234 { - yyl3473 := r.ReadArrayStart() - if yyl3473 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3473, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -44260,12 +54937,12 @@ func (x *DeleteOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3474Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3474Slc - var yyhl3474 bool = l >= 0 - for yyj3474 := 0; ; yyj3474++ { - if yyhl3474 { - if yyj3474 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -44274,21 +54951,33 @@ func (x *DeleteOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3474Slc = r.DecodeBytes(yys3474Slc, true, true) - yys3474 := string(yys3474Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3474 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "gracePeriodSeconds": if r.TryDecodeAsNil() { @@ -44299,8 +54988,8 @@ func (x *DeleteOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.GracePeriodSeconds == nil { x.GracePeriodSeconds = new(int64) } - yym3478 := z.DecBinary() - _ = yym3478 + yym9 := z.DecBinary() + _ = yym9 if false { } else { *((*int64)(x.GracePeriodSeconds)) = int64(r.DecodeInt(64)) @@ -44326,17 +55015,28 @@ func (x *DeleteOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.OrphanDependents == nil { x.OrphanDependents = new(bool) } - yym3481 := z.DecBinary() - _ = yym3481 + yym12 := z.DecBinary() + _ = yym12 if false { } else { *((*bool)(x.OrphanDependents)) = r.DecodeBool() } } + case "PropagationPolicy": + if r.TryDecodeAsNil() { + if x.PropagationPolicy != nil { + x.PropagationPolicy = nil + } + } else { + if x.PropagationPolicy == nil { + x.PropagationPolicy = new(DeletionPropagation) + } + x.PropagationPolicy.CodecDecodeSelf(d) + } default: - z.DecStructFieldNotFound(-1, yys3474) - } // end switch yys3474 - } // end for yyj3474 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -44344,16 +55044,16 @@ func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3482 int - var yyb3482 bool - var yyhl3482 bool = l >= 0 - yyj3482++ - if yyhl3482 { - yyb3482 = yyj3482 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3482 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3482 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -44361,15 +55061,21 @@ func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj3482++ - if yyhl3482 { - yyb3482 = yyj3482 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3482 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3482 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -44377,15 +55083,21 @@ func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj3482++ - if yyhl3482 { - yyb3482 = yyj3482 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3482 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3482 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -44398,20 +55110,20 @@ func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.GracePeriodSeconds == nil { x.GracePeriodSeconds = new(int64) } - yym3486 := z.DecBinary() - _ = yym3486 + yym20 := z.DecBinary() + _ = yym20 if false { } else { *((*int64)(x.GracePeriodSeconds)) = int64(r.DecodeInt(64)) } } - yyj3482++ - if yyhl3482 { - yyb3482 = yyj3482 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3482 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3482 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -44426,13 +55138,13 @@ func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Preconditions.CodecDecodeSelf(d) } - yyj3482++ - if yyhl3482 { - yyb3482 = yyj3482 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3482 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3482 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -44445,324 +55157,46 @@ func (x *DeleteOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.OrphanDependents == nil { x.OrphanDependents = new(bool) } - yym3489 := z.DecBinary() - _ = yym3489 + yym23 := z.DecBinary() + _ = yym23 if false { } else { *((*bool)(x.OrphanDependents)) = r.DecodeBool() } } - for { - yyj3482++ - if yyhl3482 { - yyb3482 = yyj3482 > l - } else { - yyb3482 = r.CheckBreak() - } - if yyb3482 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3482-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 { - yym3490 := z.EncBinary() - _ = yym3490 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep3491 := !z.EncBinary() - yy2arr3491 := z.EncBasicHandle().StructToArray - var yyq3491 [4]bool - _, _, _ = yysep3491, yyq3491, yy2arr3491 - const yyr3491 bool = false - yyq3491[0] = x.Kind != "" - yyq3491[1] = x.APIVersion != "" - var yynn3491 int - if yyr3491 || yy2arr3491 { - r.EncodeArrayStart(4) - } else { - yynn3491 = 2 - for _, b := range yyq3491 { - if b { - yynn3491++ - } - } - r.EncodeMapStart(yynn3491) - yynn3491 = 0 - } - if yyr3491 || yy2arr3491 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3491[0] { - yym3493 := z.EncBinary() - _ = yym3493 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3491[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3494 := z.EncBinary() - _ = yym3494 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr3491 || yy2arr3491 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3491[1] { - yym3496 := z.EncBinary() - _ = yym3496 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq3491[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3497 := z.EncBinary() - _ = yym3497 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr3491 || yy2arr3491 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3499 := z.EncBinary() - _ = yym3499 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("export")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3500 := z.EncBinary() - _ = yym3500 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } - if yyr3491 || yy2arr3491 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3502 := z.EncBinary() - _ = yym3502 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exact")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3503 := z.EncBinary() - _ = yym3503 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } - if yyr3491 || yy2arr3491 { - 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 - yym3504 := z.DecBinary() - _ = yym3504 - if false { - } else if z.HasExtensions() && z.DecExt(x) { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyct3505 := r.ContainerType() - if yyct3505 == codecSelferValueTypeMap1234 { - yyl3505 := r.ReadMapStart() - if yyl3505 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3505, d) - } - } else if yyct3505 == codecSelferValueTypeArray1234 { - yyl3505 := r.ReadArrayStart() - if yyl3505 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3505, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } + yyb14 = r.CheckBreak() } -} - -func (x *ExportOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3506Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3506Slc - var yyhl3506 bool = l >= 0 - for yyj3506 := 0; ; yyj3506++ { - if yyhl3506 { - if yyj3506 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3506Slc = r.DecodeBytes(yys3506Slc, true, true) - yys3506 := string(yys3506Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3506 { - 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, yys3506) - } // end switch yys3506 - } // end for yyj3506 - 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 yyj3511 int - var yyb3511 bool - var yyhl3511 bool = l >= 0 - yyj3511++ - if yyhl3511 { - yyb3511 = yyj3511 > l - } else { - yyb3511 = r.CheckBreak() - } - if yyb3511 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3511++ - if yyhl3511 { - yyb3511 = yyj3511 > l - } else { - yyb3511 = r.CheckBreak() - } - if yyb3511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3511++ - if yyhl3511 { - yyb3511 = yyj3511 > l - } else { - yyb3511 = r.CheckBreak() - } - if yyb3511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Export = false - } else { - x.Export = bool(r.DecodeBool()) - } - yyj3511++ - if yyhl3511 { - yyb3511 = yyj3511 > l - } else { - yyb3511 = r.CheckBreak() - } - if yyb3511 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Exact = false + if x.PropagationPolicy != nil { + x.PropagationPolicy = nil + } } else { - x.Exact = bool(r.DecodeBool()) + if x.PropagationPolicy == nil { + x.PropagationPolicy = new(DeletionPropagation) + } + x.PropagationPolicy.CodecDecodeSelf(d) } for { - yyj3511++ - if yyhl3511 { - yyb3511 = yyj3511 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb3511 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb3511 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3511-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -44774,41 +55208,42 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3516 := z.EncBinary() - _ = yym3516 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3517 := !z.EncBinary() - yy2arr3517 := z.EncBasicHandle().StructToArray - var yyq3517 [7]bool - _, _, _ = yysep3517, yyq3517, yy2arr3517 - const yyr3517 bool = false - yyq3517[0] = x.Kind != "" - yyq3517[1] = x.APIVersion != "" - yyq3517[2] = x.LabelSelector != "" - yyq3517[3] = x.FieldSelector != "" - yyq3517[4] = x.Watch != false - yyq3517[5] = x.ResourceVersion != "" - yyq3517[6] = x.TimeoutSeconds != nil - var yynn3517 int - if yyr3517 || yy2arr3517 { - r.EncodeArrayStart(7) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.LabelSelector != "" + yyq2[3] = x.FieldSelector != "" + yyq2[4] = x.IncludeUninitialized != false + yyq2[5] = x.Watch != false + yyq2[6] = x.ResourceVersion != "" + yyq2[7] = x.TimeoutSeconds != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) } else { - yynn3517 = 0 - for _, b := range yyq3517 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3517++ + yynn2++ } } - r.EncodeMapStart(yynn3517) - yynn3517 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[0] { - yym3519 := z.EncBinary() - _ = yym3519 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -44817,23 +55252,23 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3517[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3520 := z.EncBinary() - _ = yym3520 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[1] { - yym3522 := z.EncBinary() - _ = yym3522 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -44842,23 +55277,23 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3517[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3523 := z.EncBinary() - _ = yym3523 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[2] { - yym3525 := z.EncBinary() - _ = yym3525 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.LabelSelector)) @@ -44867,23 +55302,23 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3517[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("labelSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3526 := z.EncBinary() - _ = yym3526 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.LabelSelector)) } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[3] { - yym3528 := z.EncBinary() - _ = yym3528 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FieldSelector)) @@ -44892,23 +55327,48 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3517[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fieldSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3529 := z.EncBinary() - _ = yym3529 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FieldSelector)) } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeBool(bool(x.IncludeUninitialized)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("includeUninitialized")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeBool(bool(x.IncludeUninitialized)) + } + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[4] { - yym3531 := z.EncBinary() - _ = yym3531 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeBool(bool(x.Watch)) @@ -44917,23 +55377,23 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3517[4] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("watch")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3532 := z.EncBinary() - _ = yym3532 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeBool(bool(x.Watch)) } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[5] { - yym3534 := z.EncBinary() - _ = yym3534 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) @@ -44942,54 +55402,54 @@ func (x *ListOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3517[5] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3535 := z.EncBinary() - _ = yym3535 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3517[6] { + if yyq2[7] { if x.TimeoutSeconds == nil { r.EncodeNil() } else { - yy3537 := *x.TimeoutSeconds - yym3538 := z.EncBinary() - _ = yym3538 + yy25 := *x.TimeoutSeconds + yym26 := z.EncBinary() + _ = yym26 if false { } else { - r.EncodeInt(int64(yy3537)) + r.EncodeInt(int64(yy25)) } } } else { r.EncodeNil() } } else { - if yyq3517[6] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("timeoutSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.TimeoutSeconds == nil { r.EncodeNil() } else { - yy3539 := *x.TimeoutSeconds - yym3540 := z.EncBinary() - _ = yym3540 + yy27 := *x.TimeoutSeconds + yym28 := z.EncBinary() + _ = yym28 if false { } else { - r.EncodeInt(int64(yy3539)) + r.EncodeInt(int64(yy27)) } } } } - if yyr3517 || yy2arr3517 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -45002,25 +55462,25 @@ func (x *ListOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3541 := z.DecBinary() - _ = yym3541 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3542 := r.ContainerType() - if yyct3542 == codecSelferValueTypeMap1234 { - yyl3542 := r.ReadMapStart() - if yyl3542 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3542, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3542 == codecSelferValueTypeArray1234 { - yyl3542 := r.ReadArrayStart() - if yyl3542 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3542, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -45032,12 +55492,12 @@ func (x *ListOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3543Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3543Slc - var yyhl3543 bool = l >= 0 - for yyj3543 := 0; ; yyj3543++ { - if yyhl3543 { - if yyj3543 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -45046,45 +55506,93 @@ func (x *ListOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3543Slc = r.DecodeBytes(yys3543Slc, true, true) - yys3543 := string(yys3543Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3543 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "labelSelector": if r.TryDecodeAsNil() { x.LabelSelector = "" } else { - x.LabelSelector = string(r.DecodeString()) + yyv8 := &x.LabelSelector + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "fieldSelector": if r.TryDecodeAsNil() { x.FieldSelector = "" } else { - x.FieldSelector = string(r.DecodeString()) + yyv10 := &x.FieldSelector + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "includeUninitialized": + if r.TryDecodeAsNil() { + x.IncludeUninitialized = false + } else { + yyv12 := &x.IncludeUninitialized + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } } case "watch": if r.TryDecodeAsNil() { x.Watch = false } else { - x.Watch = bool(r.DecodeBool()) + yyv14 := &x.Watch + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } } case "resourceVersion": if r.TryDecodeAsNil() { x.ResourceVersion = "" } else { - x.ResourceVersion = string(r.DecodeString()) + yyv16 := &x.ResourceVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } case "timeoutSeconds": if r.TryDecodeAsNil() { @@ -45095,17 +55603,17 @@ func (x *ListOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.TimeoutSeconds == nil { x.TimeoutSeconds = new(int64) } - yym3551 := z.DecBinary() - _ = yym3551 + yym19 := z.DecBinary() + _ = yym19 if false { } else { *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64)) } } default: - z.DecStructFieldNotFound(-1, yys3543) - } // end switch yys3543 - } // end for yyj3543 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -45113,16 +55621,16 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3552 int - var yyb3552 bool - var yyhl3552 bool = l >= 0 - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45130,15 +55638,21 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv21 := &x.Kind + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45146,15 +55660,21 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv23 := &x.APIVersion + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45162,15 +55682,21 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.LabelSelector = "" } else { - x.LabelSelector = string(r.DecodeString()) + yyv25 := &x.LabelSelector + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45178,15 +55704,43 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.FieldSelector = "" } else { - x.FieldSelector = string(r.DecodeString()) + yyv27 := &x.FieldSelector + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.IncludeUninitialized = false + } else { + yyv29 := &x.IncludeUninitialized + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*bool)(yyv29)) = r.DecodeBool() + } } - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45194,15 +55748,21 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Watch = false } else { - x.Watch = bool(r.DecodeBool()) + yyv31 := &x.Watch + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } } - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45210,15 +55770,21 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ResourceVersion = "" } else { - x.ResourceVersion = string(r.DecodeString()) + yyv33 := &x.ResourceVersion + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } } - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45231,25 +55797,25 @@ func (x *ListOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.TimeoutSeconds == nil { x.TimeoutSeconds = new(int64) } - yym3560 := z.DecBinary() - _ = yym3560 + yym36 := z.DecBinary() + _ = yym36 if false { } else { *((*int64)(x.TimeoutSeconds)) = int64(r.DecodeInt(64)) } } for { - yyj3552++ - if yyhl3552 { - yyb3552 = yyj3552 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3552 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3552 { + if yyb20 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3552-1, "") + z.DecStructFieldNotFound(yyj20-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -45261,44 +55827,44 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3561 := z.EncBinary() - _ = yym3561 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3562 := !z.EncBinary() - yy2arr3562 := z.EncBasicHandle().StructToArray - var yyq3562 [10]bool - _, _, _ = yysep3562, yyq3562, yy2arr3562 - const yyr3562 bool = false - yyq3562[0] = x.Kind != "" - yyq3562[1] = x.APIVersion != "" - yyq3562[2] = x.Container != "" - yyq3562[3] = x.Follow != false - yyq3562[4] = x.Previous != false - yyq3562[5] = x.SinceSeconds != nil - yyq3562[6] = x.SinceTime != nil - yyq3562[7] = x.Timestamps != false - yyq3562[8] = x.TailLines != nil - yyq3562[9] = x.LimitBytes != nil - var yynn3562 int - if yyr3562 || yy2arr3562 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [10]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.Container != "" + yyq2[3] = x.Follow != false + yyq2[4] = x.Previous != false + yyq2[5] = x.SinceSeconds != nil + yyq2[6] = x.SinceTime != nil + yyq2[7] = x.Timestamps != false + yyq2[8] = x.TailLines != nil + yyq2[9] = x.LimitBytes != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(10) } else { - yynn3562 = 0 - for _, b := range yyq3562 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3562++ + yynn2++ } } - r.EncodeMapStart(yynn3562) - yynn3562 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[0] { - yym3564 := z.EncBinary() - _ = yym3564 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -45307,23 +55873,23 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3562[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3565 := z.EncBinary() - _ = yym3565 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[1] { - yym3567 := z.EncBinary() - _ = yym3567 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -45332,23 +55898,23 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3562[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3568 := z.EncBinary() - _ = yym3568 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[2] { - yym3570 := z.EncBinary() - _ = yym3570 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Container)) @@ -45357,23 +55923,23 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3562[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("container")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3571 := z.EncBinary() - _ = yym3571 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Container)) } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[3] { - yym3573 := z.EncBinary() - _ = yym3573 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.Follow)) @@ -45382,23 +55948,23 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3562[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("follow")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3574 := z.EncBinary() - _ = yym3574 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.Follow)) } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[4] { - yym3576 := z.EncBinary() - _ = yym3576 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeBool(bool(x.Previous)) @@ -45407,66 +55973,66 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3562[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("previous")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3577 := z.EncBinary() - _ = yym3577 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeBool(bool(x.Previous)) } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[5] { + if yyq2[5] { if x.SinceSeconds == nil { r.EncodeNil() } else { - yy3579 := *x.SinceSeconds - yym3580 := z.EncBinary() - _ = yym3580 + yy19 := *x.SinceSeconds + yym20 := z.EncBinary() + _ = yym20 if false { } else { - r.EncodeInt(int64(yy3579)) + r.EncodeInt(int64(yy19)) } } } else { r.EncodeNil() } } else { - if yyq3562[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("sinceSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.SinceSeconds == nil { r.EncodeNil() } else { - yy3581 := *x.SinceSeconds - yym3582 := z.EncBinary() - _ = yym3582 + yy21 := *x.SinceSeconds + yym22 := z.EncBinary() + _ = yym22 if false { } else { - r.EncodeInt(int64(yy3581)) + r.EncodeInt(int64(yy21)) } } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[6] { + if yyq2[6] { if x.SinceTime == nil { r.EncodeNil() } else { - yym3584 := z.EncBinary() - _ = yym3584 + yym24 := z.EncBinary() + _ = yym24 if false { } else if z.HasExtensions() && z.EncExt(x.SinceTime) { - } else if yym3584 { + } else if yym24 { z.EncBinaryMarshal(x.SinceTime) - } else if !yym3584 && z.IsJSONHandle() { + } else if !yym24 && z.IsJSONHandle() { z.EncJSONMarshal(x.SinceTime) } else { z.EncFallback(x.SinceTime) @@ -45476,20 +56042,20 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq3562[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("sinceTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.SinceTime == nil { r.EncodeNil() } else { - yym3585 := z.EncBinary() - _ = yym3585 + yym25 := z.EncBinary() + _ = yym25 if false { } else if z.HasExtensions() && z.EncExt(x.SinceTime) { - } else if yym3585 { + } else if yym25 { z.EncBinaryMarshal(x.SinceTime) - } else if !yym3585 && z.IsJSONHandle() { + } else if !yym25 && z.IsJSONHandle() { z.EncJSONMarshal(x.SinceTime) } else { z.EncFallback(x.SinceTime) @@ -45497,11 +56063,11 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[7] { - yym3587 := z.EncBinary() - _ = yym3587 + if yyq2[7] { + yym27 := z.EncBinary() + _ = yym27 if false { } else { r.EncodeBool(bool(x.Timestamps)) @@ -45510,89 +56076,89 @@ func (x *PodLogOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3562[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("timestamps")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3588 := z.EncBinary() - _ = yym3588 + yym28 := z.EncBinary() + _ = yym28 if false { } else { r.EncodeBool(bool(x.Timestamps)) } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[8] { + if yyq2[8] { if x.TailLines == nil { r.EncodeNil() } else { - yy3590 := *x.TailLines - yym3591 := z.EncBinary() - _ = yym3591 + yy30 := *x.TailLines + yym31 := z.EncBinary() + _ = yym31 if false { } else { - r.EncodeInt(int64(yy3590)) + r.EncodeInt(int64(yy30)) } } } else { r.EncodeNil() } } else { - if yyq3562[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tailLines")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.TailLines == nil { r.EncodeNil() } else { - yy3592 := *x.TailLines - yym3593 := z.EncBinary() - _ = yym3593 + yy32 := *x.TailLines + yym33 := z.EncBinary() + _ = yym33 if false { } else { - r.EncodeInt(int64(yy3592)) + r.EncodeInt(int64(yy32)) } } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3562[9] { + if yyq2[9] { if x.LimitBytes == nil { r.EncodeNil() } else { - yy3595 := *x.LimitBytes - yym3596 := z.EncBinary() - _ = yym3596 + yy35 := *x.LimitBytes + yym36 := z.EncBinary() + _ = yym36 if false { } else { - r.EncodeInt(int64(yy3595)) + r.EncodeInt(int64(yy35)) } } } else { r.EncodeNil() } } else { - if yyq3562[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("limitBytes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.LimitBytes == nil { r.EncodeNil() } else { - yy3597 := *x.LimitBytes - yym3598 := z.EncBinary() - _ = yym3598 + yy37 := *x.LimitBytes + yym38 := z.EncBinary() + _ = yym38 if false { } else { - r.EncodeInt(int64(yy3597)) + r.EncodeInt(int64(yy37)) } } } } - if yyr3562 || yy2arr3562 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -45605,25 +56171,25 @@ func (x *PodLogOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3599 := z.DecBinary() - _ = yym3599 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3600 := r.ContainerType() - if yyct3600 == codecSelferValueTypeMap1234 { - yyl3600 := r.ReadMapStart() - if yyl3600 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3600, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3600 == codecSelferValueTypeArray1234 { - yyl3600 := r.ReadArrayStart() - if yyl3600 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3600, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -45635,12 +56201,12 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3601Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3601Slc - var yyhl3601 bool = l >= 0 - for yyj3601 := 0; ; yyj3601++ { - if yyhl3601 { - if yyj3601 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -45649,39 +56215,69 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3601Slc = r.DecodeBytes(yys3601Slc, true, true) - yys3601 := string(yys3601Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3601 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "container": if r.TryDecodeAsNil() { x.Container = "" } else { - x.Container = string(r.DecodeString()) + yyv8 := &x.Container + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "follow": if r.TryDecodeAsNil() { x.Follow = false } else { - x.Follow = bool(r.DecodeBool()) + yyv10 := &x.Follow + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } case "previous": if r.TryDecodeAsNil() { x.Previous = false } else { - x.Previous = bool(r.DecodeBool()) + yyv12 := &x.Previous + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } } case "sinceSeconds": if r.TryDecodeAsNil() { @@ -45692,8 +56288,8 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.SinceSeconds == nil { x.SinceSeconds = new(int64) } - yym3608 := z.DecBinary() - _ = yym3608 + yym15 := z.DecBinary() + _ = yym15 if false { } else { *((*int64)(x.SinceSeconds)) = int64(r.DecodeInt(64)) @@ -45706,15 +56302,15 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.SinceTime == nil { - x.SinceTime = new(pkg2_unversioned.Time) + x.SinceTime = new(pkg2_v1.Time) } - yym3610 := z.DecBinary() - _ = yym3610 + yym17 := z.DecBinary() + _ = yym17 if false { } else if z.HasExtensions() && z.DecExt(x.SinceTime) { - } else if yym3610 { + } else if yym17 { z.DecBinaryUnmarshal(x.SinceTime) - } else if !yym3610 && z.IsJSONHandle() { + } else if !yym17 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.SinceTime) } else { z.DecFallback(x.SinceTime, false) @@ -45724,7 +56320,13 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Timestamps = false } else { - x.Timestamps = bool(r.DecodeBool()) + yyv18 := &x.Timestamps + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*bool)(yyv18)) = r.DecodeBool() + } } case "tailLines": if r.TryDecodeAsNil() { @@ -45735,8 +56337,8 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.TailLines == nil { x.TailLines = new(int64) } - yym3613 := z.DecBinary() - _ = yym3613 + yym21 := z.DecBinary() + _ = yym21 if false { } else { *((*int64)(x.TailLines)) = int64(r.DecodeInt(64)) @@ -45751,17 +56353,17 @@ func (x *PodLogOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.LimitBytes == nil { x.LimitBytes = new(int64) } - yym3615 := z.DecBinary() - _ = yym3615 + yym23 := z.DecBinary() + _ = yym23 if false { } else { *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64)) } } default: - z.DecStructFieldNotFound(-1, yys3601) - } // end switch yys3601 - } // end for yyj3601 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -45769,16 +56371,16 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3616 int - var yyb3616 bool - var yyhl3616 bool = l >= 0 - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + var yyj24 int + var yyb24 bool + var yyhl24 bool = l >= 0 + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45786,15 +56388,21 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv25 := &x.Kind + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45802,15 +56410,21 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv27 := &x.APIVersion + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45818,15 +56432,21 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Container = "" } else { - x.Container = string(r.DecodeString()) + yyv29 := &x.Container + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45834,15 +56454,21 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Follow = false } else { - x.Follow = bool(r.DecodeBool()) + yyv31 := &x.Follow + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45850,15 +56476,21 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Previous = false } else { - x.Previous = bool(r.DecodeBool()) + yyv33 := &x.Previous + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*bool)(yyv33)) = r.DecodeBool() + } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45871,20 +56503,20 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.SinceSeconds == nil { x.SinceSeconds = new(int64) } - yym3623 := z.DecBinary() - _ = yym3623 + yym36 := z.DecBinary() + _ = yym36 if false { } else { *((*int64)(x.SinceSeconds)) = int64(r.DecodeInt(64)) } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45895,27 +56527,27 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.SinceTime == nil { - x.SinceTime = new(pkg2_unversioned.Time) + x.SinceTime = new(pkg2_v1.Time) } - yym3625 := z.DecBinary() - _ = yym3625 + yym38 := z.DecBinary() + _ = yym38 if false { } else if z.HasExtensions() && z.DecExt(x.SinceTime) { - } else if yym3625 { + } else if yym38 { z.DecBinaryUnmarshal(x.SinceTime) - } else if !yym3625 && z.IsJSONHandle() { + } else if !yym38 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.SinceTime) } else { z.DecFallback(x.SinceTime, false) } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45923,15 +56555,21 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Timestamps = false } else { - x.Timestamps = bool(r.DecodeBool()) + yyv39 := &x.Timestamps + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*bool)(yyv39)) = r.DecodeBool() + } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45944,20 +56582,20 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.TailLines == nil { x.TailLines = new(int64) } - yym3628 := z.DecBinary() - _ = yym3628 + yym42 := z.DecBinary() + _ = yym42 if false { } else { *((*int64)(x.TailLines)) = int64(r.DecodeInt(64)) } } - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -45970,25 +56608,25 @@ func (x *PodLogOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.LimitBytes == nil { x.LimitBytes = new(int64) } - yym3630 := z.DecBinary() - _ = yym3630 + yym44 := z.DecBinary() + _ = yym44 if false { } else { *((*int64)(x.LimitBytes)) = int64(r.DecodeInt(64)) } } for { - yyj3616++ - if yyhl3616 { - yyb3616 = yyj3616 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3616 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3616 { + if yyb24 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3616-1, "") + z.DecStructFieldNotFound(yyj24-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -46000,41 +56638,41 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3631 := z.EncBinary() - _ = yym3631 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3632 := !z.EncBinary() - yy2arr3632 := z.EncBasicHandle().StructToArray - var yyq3632 [7]bool - _, _, _ = yysep3632, yyq3632, yy2arr3632 - const yyr3632 bool = false - yyq3632[0] = x.Kind != "" - yyq3632[1] = x.APIVersion != "" - yyq3632[2] = x.Stdin != false - yyq3632[3] = x.Stdout != false - yyq3632[4] = x.Stderr != false - yyq3632[5] = x.TTY != false - yyq3632[6] = x.Container != "" - var yynn3632 int - if yyr3632 || yy2arr3632 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.Stdin != false + yyq2[3] = x.Stdout != false + yyq2[4] = x.Stderr != false + yyq2[5] = x.TTY != false + yyq2[6] = x.Container != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(7) } else { - yynn3632 = 0 - for _, b := range yyq3632 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3632++ + yynn2++ } } - r.EncodeMapStart(yynn3632) - yynn3632 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[0] { - yym3634 := z.EncBinary() - _ = yym3634 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -46043,23 +56681,23 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3632[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3635 := z.EncBinary() - _ = yym3635 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[1] { - yym3637 := z.EncBinary() - _ = yym3637 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -46068,23 +56706,23 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3632[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3638 := z.EncBinary() - _ = yym3638 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[2] { - yym3640 := z.EncBinary() - _ = yym3640 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeBool(bool(x.Stdin)) @@ -46093,23 +56731,23 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3632[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stdin")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3641 := z.EncBinary() - _ = yym3641 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeBool(bool(x.Stdin)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[3] { - yym3643 := z.EncBinary() - _ = yym3643 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.Stdout)) @@ -46118,23 +56756,23 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3632[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stdout")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3644 := z.EncBinary() - _ = yym3644 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.Stdout)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[4] { - yym3646 := z.EncBinary() - _ = yym3646 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeBool(bool(x.Stderr)) @@ -46143,23 +56781,23 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3632[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stderr")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3647 := z.EncBinary() - _ = yym3647 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeBool(bool(x.Stderr)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[5] { - yym3649 := z.EncBinary() - _ = yym3649 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeBool(bool(x.TTY)) @@ -46168,23 +56806,23 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3632[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tty")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3650 := z.EncBinary() - _ = yym3650 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeBool(bool(x.TTY)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3632[6] { - yym3652 := z.EncBinary() - _ = yym3652 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Container)) @@ -46193,19 +56831,19 @@ func (x *PodAttachOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3632[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("container")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3653 := z.EncBinary() - _ = yym3653 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Container)) } } } - if yyr3632 || yy2arr3632 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -46218,25 +56856,25 @@ func (x *PodAttachOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3654 := z.DecBinary() - _ = yym3654 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3655 := r.ContainerType() - if yyct3655 == codecSelferValueTypeMap1234 { - yyl3655 := r.ReadMapStart() - if yyl3655 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3655, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3655 == codecSelferValueTypeArray1234 { - yyl3655 := r.ReadArrayStart() - if yyl3655 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3655, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -46248,12 +56886,12 @@ func (x *PodAttachOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3656Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3656Slc - var yyhl3656 bool = l >= 0 - for yyj3656 := 0; ; yyj3656++ { - if yyhl3656 { - if yyj3656 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -46262,56 +56900,98 @@ func (x *PodAttachOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3656Slc = r.DecodeBytes(yys3656Slc, true, true) - yys3656 := string(yys3656Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3656 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "stdin": if r.TryDecodeAsNil() { x.Stdin = false } else { - x.Stdin = bool(r.DecodeBool()) + yyv8 := &x.Stdin + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } } case "stdout": if r.TryDecodeAsNil() { x.Stdout = false } else { - x.Stdout = bool(r.DecodeBool()) + yyv10 := &x.Stdout + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } case "stderr": if r.TryDecodeAsNil() { x.Stderr = false } else { - x.Stderr = bool(r.DecodeBool()) + yyv12 := &x.Stderr + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } } case "tty": if r.TryDecodeAsNil() { x.TTY = false } else { - x.TTY = bool(r.DecodeBool()) + yyv14 := &x.TTY + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } } case "container": if r.TryDecodeAsNil() { x.Container = "" } else { - x.Container = string(r.DecodeString()) + yyv16 := &x.Container + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3656) - } // end switch yys3656 - } // end for yyj3656 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -46319,16 +56999,16 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3664 int - var yyb3664 bool - var yyhl3664 bool = l >= 0 - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46336,15 +57016,21 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv19 := &x.Kind + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46352,15 +57038,21 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv21 := &x.APIVersion + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46368,15 +57060,21 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Stdin = false } else { - x.Stdin = bool(r.DecodeBool()) + yyv23 := &x.Stdin + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*bool)(yyv23)) = r.DecodeBool() + } } - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46384,15 +57082,21 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Stdout = false } else { - x.Stdout = bool(r.DecodeBool()) + yyv25 := &x.Stdout + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*bool)(yyv25)) = r.DecodeBool() + } } - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46400,15 +57104,21 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Stderr = false } else { - x.Stderr = bool(r.DecodeBool()) + yyv27 := &x.Stderr + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } } - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46416,15 +57126,21 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.TTY = false } else { - x.TTY = bool(r.DecodeBool()) + yyv29 := &x.TTY + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*bool)(yyv29)) = r.DecodeBool() + } } - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46432,20 +57148,26 @@ func (x *PodAttachOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Container = "" } else { - x.Container = string(r.DecodeString()) + yyv31 := &x.Container + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } } for { - yyj3664++ - if yyhl3664 { - yyb3664 = yyj3664 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3664 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3664 { + if yyb18 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3664-1, "") + z.DecStructFieldNotFound(yyj18-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -46457,41 +57179,41 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3672 := z.EncBinary() - _ = yym3672 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3673 := !z.EncBinary() - yy2arr3673 := z.EncBasicHandle().StructToArray - var yyq3673 [8]bool - _, _, _ = yysep3673, yyq3673, yy2arr3673 - const yyr3673 bool = false - yyq3673[0] = x.Kind != "" - yyq3673[1] = x.APIVersion != "" - yyq3673[2] = x.Stdin != false - yyq3673[3] = x.Stdout != false - yyq3673[4] = x.Stderr != false - yyq3673[5] = x.TTY != false - yyq3673[6] = x.Container != "" - var yynn3673 int - if yyr3673 || yy2arr3673 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.Stdin != false + yyq2[3] = x.Stdout != false + yyq2[4] = x.Stderr != false + yyq2[5] = x.TTY != false + yyq2[6] = x.Container != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(8) } else { - yynn3673 = 1 - for _, b := range yyq3673 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3673++ + yynn2++ } } - r.EncodeMapStart(yynn3673) - yynn3673 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[0] { - yym3675 := z.EncBinary() - _ = yym3675 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -46500,23 +57222,23 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3673[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3676 := z.EncBinary() - _ = yym3676 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[1] { - yym3678 := z.EncBinary() - _ = yym3678 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -46525,23 +57247,23 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3673[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3679 := z.EncBinary() - _ = yym3679 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[2] { - yym3681 := z.EncBinary() - _ = yym3681 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeBool(bool(x.Stdin)) @@ -46550,23 +57272,23 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3673[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stdin")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3682 := z.EncBinary() - _ = yym3682 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeBool(bool(x.Stdin)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[3] { - yym3684 := z.EncBinary() - _ = yym3684 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeBool(bool(x.Stdout)) @@ -46575,23 +57297,23 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3673[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stdout")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3685 := z.EncBinary() - _ = yym3685 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeBool(bool(x.Stdout)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[4] { - yym3687 := z.EncBinary() - _ = yym3687 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeBool(bool(x.Stderr)) @@ -46600,23 +57322,23 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3673[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stderr")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3688 := z.EncBinary() - _ = yym3688 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeBool(bool(x.Stderr)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[5] { - yym3690 := z.EncBinary() - _ = yym3690 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeBool(bool(x.TTY)) @@ -46625,23 +57347,23 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq3673[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tty")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3691 := z.EncBinary() - _ = yym3691 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeBool(bool(x.TTY)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3673[6] { - yym3693 := z.EncBinary() - _ = yym3693 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Container)) @@ -46650,25 +57372,25 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3673[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("container")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3694 := z.EncBinary() - _ = yym3694 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Container)) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Command == nil { r.EncodeNil() } else { - yym3696 := z.EncBinary() - _ = yym3696 + yym25 := z.EncBinary() + _ = yym25 if false { } else { z.F.EncSliceStringV(x.Command, false, e) @@ -46681,15 +57403,15 @@ func (x *PodExecOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x.Command == nil { r.EncodeNil() } else { - yym3697 := z.EncBinary() - _ = yym3697 + yym26 := z.EncBinary() + _ = yym26 if false { } else { z.F.EncSliceStringV(x.Command, false, e) } } } - if yyr3673 || yy2arr3673 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -46702,25 +57424,25 @@ func (x *PodExecOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3698 := z.DecBinary() - _ = yym3698 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3699 := r.ContainerType() - if yyct3699 == codecSelferValueTypeMap1234 { - yyl3699 := r.ReadMapStart() - if yyl3699 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3699, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3699 == codecSelferValueTypeArray1234 { - yyl3699 := r.ReadArrayStart() - if yyl3699 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3699, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -46732,12 +57454,12 @@ func (x *PodExecOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3700Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3700Slc - var yyhl3700 bool = l >= 0 - for yyj3700 := 0; ; yyj3700++ { - if yyhl3700 { - if yyj3700 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -46746,68 +57468,110 @@ func (x *PodExecOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3700Slc = r.DecodeBytes(yys3700Slc, true, true) - yys3700 := string(yys3700Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3700 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "stdin": if r.TryDecodeAsNil() { x.Stdin = false } else { - x.Stdin = bool(r.DecodeBool()) + yyv8 := &x.Stdin + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*bool)(yyv8)) = r.DecodeBool() + } } case "stdout": if r.TryDecodeAsNil() { x.Stdout = false } else { - x.Stdout = bool(r.DecodeBool()) + yyv10 := &x.Stdout + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } case "stderr": if r.TryDecodeAsNil() { x.Stderr = false } else { - x.Stderr = bool(r.DecodeBool()) + yyv12 := &x.Stderr + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*bool)(yyv12)) = r.DecodeBool() + } } case "tty": if r.TryDecodeAsNil() { x.TTY = false } else { - x.TTY = bool(r.DecodeBool()) + yyv14 := &x.TTY + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } } case "container": if r.TryDecodeAsNil() { x.Container = "" } else { - x.Container = string(r.DecodeString()) + yyv16 := &x.Container + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } case "command": if r.TryDecodeAsNil() { x.Command = nil } else { - yyv3708 := &x.Command - yym3709 := z.DecBinary() - _ = yym3709 + yyv18 := &x.Command + yym19 := z.DecBinary() + _ = yym19 if false { } else { - z.F.DecSliceStringX(yyv3708, false, d) + z.F.DecSliceStringX(yyv18, false, d) } } default: - z.DecStructFieldNotFound(-1, yys3700) - } // end switch yys3700 - } // end for yyj3700 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -46815,16 +57579,16 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3710 int - var yyb3710 bool - var yyhl3710 bool = l >= 0 - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46832,15 +57596,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv21 := &x.Kind + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46848,15 +57618,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv23 := &x.APIVersion + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46864,15 +57640,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Stdin = false } else { - x.Stdin = bool(r.DecodeBool()) + yyv25 := &x.Stdin + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*bool)(yyv25)) = r.DecodeBool() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46880,15 +57662,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Stdout = false } else { - x.Stdout = bool(r.DecodeBool()) + yyv27 := &x.Stdout + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*bool)(yyv27)) = r.DecodeBool() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46896,15 +57684,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Stderr = false } else { - x.Stderr = bool(r.DecodeBool()) + yyv29 := &x.Stderr + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*bool)(yyv29)) = r.DecodeBool() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46912,15 +57706,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TTY = false } else { - x.TTY = bool(r.DecodeBool()) + yyv31 := &x.TTY + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*bool)(yyv31)) = r.DecodeBool() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46928,15 +57728,21 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Container = "" } else { - x.Container = string(r.DecodeString()) + yyv33 := &x.Container + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*string)(yyv33)) = r.DecodeString() + } } - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb3710 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb3710 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -46944,26 +57750,335 @@ func (x *PodExecOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Command = nil } else { - yyv3718 := &x.Command - yym3719 := z.DecBinary() - _ = yym3719 + yyv35 := &x.Command + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + z.F.DecSliceStringX(yyv35, false, d) + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PodPortForwardOptions) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = len(x.Ports) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Ports == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceInt32V(x.Ports, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ports")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ports == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceInt32V(x.Ports, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PodPortForwardOptions) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PodPortForwardOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "ports": + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv8 := &x.Ports + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceInt32X(yyv8, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PodPortForwardOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv11 := &x.Kind + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv13 := &x.APIVersion + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv15 := &x.Ports + yym16 := z.DecBinary() + _ = yym16 if false { } else { - z.F.DecSliceStringX(yyv3718, false, d) + z.F.DecSliceInt32X(yyv15, false, d) } } for { - yyj3710++ - if yyhl3710 { - yyb3710 = yyj3710 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3710 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3710 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3710-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -46975,37 +58090,37 @@ func (x *PodProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3720 := z.EncBinary() - _ = yym3720 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3721 := !z.EncBinary() - yy2arr3721 := z.EncBasicHandle().StructToArray - var yyq3721 [3]bool - _, _, _ = yysep3721, yyq3721, yy2arr3721 - const yyr3721 bool = false - yyq3721[0] = x.Kind != "" - yyq3721[1] = x.APIVersion != "" - yyq3721[2] = x.Path != "" - var yynn3721 int - if yyr3721 || yy2arr3721 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.Path != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn3721 = 0 - for _, b := range yyq3721 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3721++ + yynn2++ } } - r.EncodeMapStart(yynn3721) - yynn3721 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3721 || yy2arr3721 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3721[0] { - yym3723 := z.EncBinary() - _ = yym3723 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -47014,23 +58129,23 @@ func (x *PodProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3721[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3724 := z.EncBinary() - _ = yym3724 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3721 || yy2arr3721 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3721[1] { - yym3726 := z.EncBinary() - _ = yym3726 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -47039,23 +58154,23 @@ func (x *PodProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3721[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3727 := z.EncBinary() - _ = yym3727 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3721 || yy2arr3721 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3721[2] { - yym3729 := z.EncBinary() - _ = yym3729 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -47064,19 +58179,19 @@ func (x *PodProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3721[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3730 := z.EncBinary() - _ = yym3730 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr3721 || yy2arr3721 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -47089,25 +58204,25 @@ func (x *PodProxyOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3731 := z.DecBinary() - _ = yym3731 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3732 := r.ContainerType() - if yyct3732 == codecSelferValueTypeMap1234 { - yyl3732 := r.ReadMapStart() - if yyl3732 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3732, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3732 == codecSelferValueTypeArray1234 { - yyl3732 := r.ReadArrayStart() - if yyl3732 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3732, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -47119,12 +58234,12 @@ func (x *PodProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3733Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3733Slc - var yyhl3733 bool = l >= 0 - for yyj3733 := 0; ; yyj3733++ { - if yyhl3733 { - if yyj3733 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -47133,32 +58248,50 @@ func (x *PodProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3733Slc = r.DecodeBytes(yys3733Slc, true, true) - yys3733 := string(yys3733Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3733 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv8 := &x.Path + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3733) - } // end switch yys3733 - } // end for yyj3733 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -47166,16 +58299,16 @@ func (x *PodProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3737 int - var yyb3737 bool - var yyhl3737 bool = l >= 0 - yyj3737++ - if yyhl3737 { - yyb3737 = yyj3737 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3737 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3737 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47183,15 +58316,21 @@ func (x *PodProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv11 := &x.Kind + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj3737++ - if yyhl3737 { - yyb3737 = yyj3737 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3737 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3737 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47199,15 +58338,21 @@ func (x *PodProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv13 := &x.APIVersion + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3737++ - if yyhl3737 { - yyb3737 = yyj3737 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3737 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3737 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47215,20 +58360,26 @@ func (x *PodProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv15 := &x.Path + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj3737++ - if yyhl3737 { - yyb3737 = yyj3737 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3737 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3737 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3737-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -47240,37 +58391,37 @@ func (x *NodeProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3741 := z.EncBinary() - _ = yym3741 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3742 := !z.EncBinary() - yy2arr3742 := z.EncBasicHandle().StructToArray - var yyq3742 [3]bool - _, _, _ = yysep3742, yyq3742, yy2arr3742 - const yyr3742 bool = false - yyq3742[0] = x.Kind != "" - yyq3742[1] = x.APIVersion != "" - yyq3742[2] = x.Path != "" - var yynn3742 int - if yyr3742 || yy2arr3742 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.Path != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn3742 = 0 - for _, b := range yyq3742 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3742++ + yynn2++ } } - r.EncodeMapStart(yynn3742) - yynn3742 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3742 || yy2arr3742 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3742[0] { - yym3744 := z.EncBinary() - _ = yym3744 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -47279,23 +58430,23 @@ func (x *NodeProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3742[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3745 := z.EncBinary() - _ = yym3745 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3742 || yy2arr3742 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3742[1] { - yym3747 := z.EncBinary() - _ = yym3747 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -47304,23 +58455,23 @@ func (x *NodeProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3742[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3748 := z.EncBinary() - _ = yym3748 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3742 || yy2arr3742 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3742[2] { - yym3750 := z.EncBinary() - _ = yym3750 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -47329,19 +58480,19 @@ func (x *NodeProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3742[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3751 := z.EncBinary() - _ = yym3751 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr3742 || yy2arr3742 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -47354,25 +58505,25 @@ func (x *NodeProxyOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3752 := z.DecBinary() - _ = yym3752 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3753 := r.ContainerType() - if yyct3753 == codecSelferValueTypeMap1234 { - yyl3753 := r.ReadMapStart() - if yyl3753 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3753, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3753 == codecSelferValueTypeArray1234 { - yyl3753 := r.ReadArrayStart() - if yyl3753 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3753, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -47384,12 +58535,12 @@ func (x *NodeProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3754Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3754Slc - var yyhl3754 bool = l >= 0 - for yyj3754 := 0; ; yyj3754++ { - if yyhl3754 { - if yyj3754 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -47398,32 +58549,50 @@ func (x *NodeProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3754Slc = r.DecodeBytes(yys3754Slc, true, true) - yys3754 := string(yys3754Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3754 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv8 := &x.Path + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3754) - } // end switch yys3754 - } // end for yyj3754 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -47431,16 +58600,16 @@ func (x *NodeProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3758 int - var yyb3758 bool - var yyhl3758 bool = l >= 0 - yyj3758++ - if yyhl3758 { - yyb3758 = yyj3758 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3758 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3758 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47448,15 +58617,21 @@ func (x *NodeProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv11 := &x.Kind + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj3758++ - if yyhl3758 { - yyb3758 = yyj3758 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3758 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3758 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47464,15 +58639,21 @@ func (x *NodeProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv13 := &x.APIVersion + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3758++ - if yyhl3758 { - yyb3758 = yyj3758 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3758 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3758 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47480,20 +58661,26 @@ func (x *NodeProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv15 := &x.Path + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj3758++ - if yyhl3758 { - yyb3758 = yyj3758 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3758 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3758 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3758-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -47505,37 +58692,37 @@ func (x *ServiceProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3762 := z.EncBinary() - _ = yym3762 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3763 := !z.EncBinary() - yy2arr3763 := z.EncBasicHandle().StructToArray - var yyq3763 [3]bool - _, _, _ = yysep3763, yyq3763, yy2arr3763 - const yyr3763 bool = false - yyq3763[0] = x.Kind != "" - yyq3763[1] = x.APIVersion != "" - yyq3763[2] = x.Path != "" - var yynn3763 int - if yyr3763 || yy2arr3763 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = x.Path != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn3763 = 0 - for _, b := range yyq3763 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3763++ + yynn2++ } } - r.EncodeMapStart(yynn3763) - yynn3763 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3763 || yy2arr3763 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3763[0] { - yym3765 := z.EncBinary() - _ = yym3765 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -47544,23 +58731,23 @@ func (x *ServiceProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3763[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3766 := z.EncBinary() - _ = yym3766 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3763 || yy2arr3763 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3763[1] { - yym3768 := z.EncBinary() - _ = yym3768 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -47569,23 +58756,23 @@ func (x *ServiceProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3763[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3769 := z.EncBinary() - _ = yym3769 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3763 || yy2arr3763 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3763[2] { - yym3771 := z.EncBinary() - _ = yym3771 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -47594,19 +58781,19 @@ func (x *ServiceProxyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3763[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3772 := z.EncBinary() - _ = yym3772 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr3763 || yy2arr3763 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -47619,25 +58806,25 @@ func (x *ServiceProxyOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3773 := z.DecBinary() - _ = yym3773 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3774 := r.ContainerType() - if yyct3774 == codecSelferValueTypeMap1234 { - yyl3774 := r.ReadMapStart() - if yyl3774 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3774, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3774 == codecSelferValueTypeArray1234 { - yyl3774 := r.ReadArrayStart() - if yyl3774 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3774, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -47649,12 +58836,12 @@ func (x *ServiceProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3775Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3775Slc - var yyhl3775 bool = l >= 0 - for yyj3775 := 0; ; yyj3775++ { - if yyhl3775 { - if yyj3775 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -47663,32 +58850,50 @@ func (x *ServiceProxyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3775Slc = r.DecodeBytes(yys3775Slc, true, true) - yys3775 := string(yys3775Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3775 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv8 := &x.Path + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3775) - } // end switch yys3775 - } // end for yyj3775 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -47696,16 +58901,16 @@ func (x *ServiceProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3779 int - var yyb3779 bool - var yyhl3779 bool = l >= 0 - yyj3779++ - if yyhl3779 { - yyb3779 = yyj3779 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3779 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3779 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -47713,322 +58918,21 @@ func (x *ServiceProxyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) - } - yyj3779++ - if yyhl3779 { - yyb3779 = yyj3779 > l - } else { - yyb3779 = r.CheckBreak() - } - if yyb3779 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3779++ - if yyhl3779 { - yyb3779 = yyj3779 > l - } else { - yyb3779 = r.CheckBreak() - } - if yyb3779 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - for { - yyj3779++ - if yyhl3779 { - yyb3779 = yyj3779 > l - } else { - yyb3779 = r.CheckBreak() - } - if yyb3779 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3779-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 { - yym3783 := z.EncBinary() - _ = yym3783 + yyv11 := &x.Kind + yym12 := z.DecBinary() + _ = yym12 if false { - } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3784 := !z.EncBinary() - yy2arr3784 := z.EncBasicHandle().StructToArray - var yyq3784 [5]bool - _, _, _ = yysep3784, yyq3784, yy2arr3784 - const yyr3784 bool = false - yyq3784[4] = x.Controller != nil - var yynn3784 int - if yyr3784 || yy2arr3784 { - r.EncodeArrayStart(5) - } else { - yynn3784 = 4 - for _, b := range yyq3784 { - if b { - yynn3784++ - } - } - r.EncodeMapStart(yynn3784) - yynn3784 = 0 - } - if yyr3784 || yy2arr3784 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3786 := z.EncBinary() - _ = yym3786 - 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) - yym3787 := z.EncBinary() - _ = yym3787 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - if yyr3784 || yy2arr3784 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3789 := z.EncBinary() - _ = yym3789 - 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) - yym3790 := z.EncBinary() - _ = yym3790 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - if yyr3784 || yy2arr3784 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3792 := z.EncBinary() - _ = yym3792 - 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) - yym3793 := z.EncBinary() - _ = yym3793 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr3784 || yy2arr3784 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym3795 := z.EncBinary() - _ = yym3795 - 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) - yym3796 := z.EncBinary() - _ = yym3796 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - if yyr3784 || yy2arr3784 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3784[4] { - if x.Controller == nil { - r.EncodeNil() - } else { - yy3798 := *x.Controller - yym3799 := z.EncBinary() - _ = yym3799 - if false { - } else { - r.EncodeBool(bool(yy3798)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq3784[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("controller")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Controller == nil { - r.EncodeNil() - } else { - yy3800 := *x.Controller - yym3801 := z.EncBinary() - _ = yym3801 - if false { - } else { - r.EncodeBool(bool(yy3800)) - } - } - } - } - if yyr3784 || yy2arr3784 { - 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 - yym3802 := z.DecBinary() - _ = yym3802 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct3803 := r.ContainerType() - if yyct3803 == codecSelferValueTypeMap1234 { - yyl3803 := r.ReadMapStart() - if yyl3803 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl3803, d) - } - } else if yyct3803 == codecSelferValueTypeArray1234 { - yyl3803 := r.ReadArrayStart() - if yyl3803 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl3803, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + *((*string)(yyv11)) = r.DecodeString() } } -} - -func (x *OwnerReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys3804Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3804Slc - var yyhl3804 bool = l >= 0 - for yyj3804 := 0; ; yyj3804++ { - if yyhl3804 { - if yyj3804 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3804Slc = r.DecodeBytes(yys3804Slc, true, true) - yys3804 := string(yys3804Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3804 { - 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) - } - yym3810 := z.DecBinary() - _ = yym3810 - if false { - } else { - *((*bool)(x.Controller)) = r.DecodeBool() - } - } - default: - z.DecStructFieldNotFound(-1, yys3804) - } // end switch yys3804 - } // end for yyj3804 - 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 yyj3811 int - var yyb3811 bool - var yyhl3811 bool = l >= 0 - yyj3811++ - if yyhl3811 { - yyb3811 = yyj3811 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3811 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3811 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48036,94 +58940,48 @@ func (x *OwnerReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) - } - yyj3811++ - if yyhl3811 { - yyb3811 = yyj3811 > l - } else { - yyb3811 = r.CheckBreak() - } - if yyb3811 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj3811++ - if yyhl3811 { - yyb3811 = yyj3811 > l - } else { - yyb3811 = r.CheckBreak() - } - if yyb3811 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj3811++ - if yyhl3811 { - yyb3811 = yyj3811 > l - } else { - yyb3811 = r.CheckBreak() - } - if yyb3811 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg1_types.UID(r.DecodeString()) + yyv13 := &x.APIVersion + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj3811++ - if yyhl3811 { - yyb3811 = yyj3811 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3811 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3811 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Controller != nil { - x.Controller = nil - } + x.Path = "" } else { - if x.Controller == nil { - x.Controller = new(bool) - } - yym3817 := z.DecBinary() - _ = yym3817 + yyv15 := &x.Path + yym16 := z.DecBinary() + _ = yym16 if false { } else { - *((*bool)(x.Controller)) = r.DecodeBool() + *((*string)(yyv15)) = r.DecodeString() } } for { - yyj3811++ - if yyhl3811 { - yyb3811 = yyj3811 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb3811 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb3811 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3811-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -48135,41 +58993,41 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3818 := z.EncBinary() - _ = yym3818 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3819 := !z.EncBinary() - yy2arr3819 := z.EncBasicHandle().StructToArray - var yyq3819 [7]bool - _, _, _ = yysep3819, yyq3819, yy2arr3819 - const yyr3819 bool = false - yyq3819[0] = x.Kind != "" - yyq3819[1] = x.Namespace != "" - yyq3819[2] = x.Name != "" - yyq3819[3] = x.UID != "" - yyq3819[4] = x.APIVersion != "" - yyq3819[5] = x.ResourceVersion != "" - yyq3819[6] = x.FieldPath != "" - var yynn3819 int - if yyr3819 || yy2arr3819 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.Namespace != "" + yyq2[2] = x.Name != "" + yyq2[3] = x.UID != "" + yyq2[4] = x.APIVersion != "" + yyq2[5] = x.ResourceVersion != "" + yyq2[6] = x.FieldPath != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(7) } else { - yynn3819 = 0 - for _, b := range yyq3819 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3819++ + yynn2++ } } - r.EncodeMapStart(yynn3819) - yynn3819 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[0] { - yym3821 := z.EncBinary() - _ = yym3821 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -48178,23 +59036,23 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3822 := z.EncBinary() - _ = yym3822 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[1] { - yym3824 := z.EncBinary() - _ = yym3824 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) @@ -48203,23 +59061,23 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("namespace")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3825 := z.EncBinary() - _ = yym3825 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[2] { - yym3827 := z.EncBinary() - _ = yym3827 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -48228,23 +59086,23 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3828 := z.EncBinary() - _ = yym3828 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[3] { - yym3830 := z.EncBinary() - _ = yym3830 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else if z.HasExtensions() && z.EncExt(x.UID) { } else { @@ -48254,12 +59112,12 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("uid")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3831 := z.EncBinary() - _ = yym3831 + yym14 := z.EncBinary() + _ = yym14 if false { } else if z.HasExtensions() && z.EncExt(x.UID) { } else { @@ -48267,11 +59125,11 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[4] { - yym3833 := z.EncBinary() - _ = yym3833 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -48280,23 +59138,23 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3834 := z.EncBinary() - _ = yym3834 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[5] { - yym3836 := z.EncBinary() - _ = yym3836 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) @@ -48305,23 +59163,23 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3837 := z.EncBinary() - _ = yym3837 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3819[6] { - yym3839 := z.EncBinary() - _ = yym3839 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) @@ -48330,19 +59188,19 @@ func (x *ObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3819[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fieldPath")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3840 := z.EncBinary() - _ = yym3840 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.FieldPath)) } } } - if yyr3819 || yy2arr3819 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -48355,25 +59213,25 @@ func (x *ObjectReference) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3841 := z.DecBinary() - _ = yym3841 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3842 := r.ContainerType() - if yyct3842 == codecSelferValueTypeMap1234 { - yyl3842 := r.ReadMapStart() - if yyl3842 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3842, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3842 == codecSelferValueTypeArray1234 { - yyl3842 := r.ReadArrayStart() - if yyl3842 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3842, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -48385,12 +59243,12 @@ func (x *ObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3843Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3843Slc - var yyhl3843 bool = l >= 0 - for yyj3843 := 0; ; yyj3843++ { - if yyhl3843 { - if yyj3843 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -48399,56 +59257,99 @@ func (x *ObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3843Slc = r.DecodeBytes(yys3843Slc, true, true) - yys3843 := string(yys3843Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3843 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "namespace": if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv6 := &x.Namespace + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "uid": if r.TryDecodeAsNil() { x.UID = "" } else { - x.UID = pkg1_types.UID(r.DecodeString()) + yyv10 := &x.UID + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv12 := &x.APIVersion + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "resourceVersion": if r.TryDecodeAsNil() { x.ResourceVersion = "" } else { - x.ResourceVersion = string(r.DecodeString()) + yyv14 := &x.ResourceVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "fieldPath": if r.TryDecodeAsNil() { x.FieldPath = "" } else { - x.FieldPath = string(r.DecodeString()) + yyv16 := &x.FieldPath + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3843) - } // end switch yys3843 - } // end for yyj3843 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -48456,16 +59357,16 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3851 int - var yyb3851 bool - var yyhl3851 bool = l >= 0 - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48473,15 +59374,21 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv19 := &x.Kind + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48489,15 +59396,21 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv21 := &x.Namespace + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48505,15 +59418,21 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv23 := &x.Name + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48521,15 +59440,22 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.UID = "" } else { - x.UID = pkg1_types.UID(r.DecodeString()) + yyv25 := &x.UID + yym26 := z.DecBinary() + _ = yym26 + if false { + } else if z.HasExtensions() && z.DecExt(yyv25) { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48537,15 +59463,21 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv27 := &x.APIVersion + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } } - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48553,15 +59485,21 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ResourceVersion = "" } else { - x.ResourceVersion = string(r.DecodeString()) + yyv29 := &x.ResourceVersion + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } } - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48569,20 +59507,26 @@ func (x *ObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.FieldPath = "" } else { - x.FieldPath = string(r.DecodeString()) + yyv31 := &x.FieldPath + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } } for { - yyj3851++ - if yyhl3851 { - yyb3851 = yyj3851 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb3851 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb3851 { + if yyb18 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3851-1, "") + z.DecStructFieldNotFound(yyj18-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -48594,35 +59538,35 @@ func (x *LocalObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3859 := z.EncBinary() - _ = yym3859 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3860 := !z.EncBinary() - yy2arr3860 := z.EncBasicHandle().StructToArray - var yyq3860 [1]bool - _, _, _ = yysep3860, yyq3860, yy2arr3860 - const yyr3860 bool = false - yyq3860[0] = x.Name != "" - var yynn3860 int - if yyr3860 || yy2arr3860 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn3860 = 0 - for _, b := range yyq3860 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3860++ + yynn2++ } } - r.EncodeMapStart(yynn3860) - yynn3860 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3860 || yy2arr3860 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3860[0] { - yym3862 := z.EncBinary() - _ = yym3862 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -48631,19 +59575,19 @@ func (x *LocalObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3860[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3863 := z.EncBinary() - _ = yym3863 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr3860 || yy2arr3860 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -48656,25 +59600,25 @@ func (x *LocalObjectReference) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3864 := z.DecBinary() - _ = yym3864 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3865 := r.ContainerType() - if yyct3865 == codecSelferValueTypeMap1234 { - yyl3865 := r.ReadMapStart() - if yyl3865 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3865, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3865 == codecSelferValueTypeArray1234 { - yyl3865 := r.ReadArrayStart() - if yyl3865 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3865, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -48686,12 +59630,12 @@ func (x *LocalObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3866Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3866Slc - var yyhl3866 bool = l >= 0 - for yyj3866 := 0; ; yyj3866++ { - if yyhl3866 { - if yyj3866 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -48700,20 +59644,26 @@ func (x *LocalObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3866Slc = r.DecodeBytes(yys3866Slc, true, true) - yys3866 := string(yys3866Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3866 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3866) - } // end switch yys3866 - } // end for yyj3866 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -48721,16 +59671,16 @@ func (x *LocalObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3868 int - var yyb3868 bool - var yyhl3868 bool = l >= 0 - yyj3868++ - if yyhl3868 { - yyb3868 = yyj3868 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3868 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3868 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48738,20 +59688,26 @@ func (x *LocalObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv7 := &x.Name + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } for { - yyj3868++ - if yyhl3868 { - yyb3868 = yyj3868 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb3868 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb3868 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3868-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -48763,37 +59719,37 @@ func (x *SerializedReference) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3870 := z.EncBinary() - _ = yym3870 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3871 := !z.EncBinary() - yy2arr3871 := z.EncBasicHandle().StructToArray - var yyq3871 [3]bool - _, _, _ = yysep3871, yyq3871, yy2arr3871 - const yyr3871 bool = false - yyq3871[0] = x.Kind != "" - yyq3871[1] = x.APIVersion != "" - yyq3871[2] = true - var yynn3871 int - if yyr3871 || yy2arr3871 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn3871 = 0 - for _, b := range yyq3871 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3871++ + yynn2++ } } - r.EncodeMapStart(yynn3871) - yynn3871 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3871 || yy2arr3871 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3871[0] { - yym3873 := z.EncBinary() - _ = yym3873 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -48802,23 +59758,23 @@ func (x *SerializedReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3871[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3874 := z.EncBinary() - _ = yym3874 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3871 || yy2arr3871 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3871[1] { - yym3876 := z.EncBinary() - _ = yym3876 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -48827,36 +59783,36 @@ func (x *SerializedReference) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3871[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3877 := z.EncBinary() - _ = yym3877 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3871 || yy2arr3871 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3871[2] { - yy3879 := &x.Reference - yy3879.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.Reference + yy10.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3871[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reference")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3880 := &x.Reference - yy3880.CodecEncodeSelf(e) + yy12 := &x.Reference + yy12.CodecEncodeSelf(e) } } - if yyr3871 || yy2arr3871 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -48869,25 +59825,25 @@ func (x *SerializedReference) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3881 := z.DecBinary() - _ = yym3881 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3882 := r.ContainerType() - if yyct3882 == codecSelferValueTypeMap1234 { - yyl3882 := r.ReadMapStart() - if yyl3882 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3882, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3882 == codecSelferValueTypeArray1234 { - yyl3882 := r.ReadArrayStart() - if yyl3882 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3882, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -48899,12 +59855,12 @@ func (x *SerializedReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3883Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3883Slc - var yyhl3883 bool = l >= 0 - for yyj3883 := 0; ; yyj3883++ { - if yyhl3883 { - if yyj3883 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -48913,33 +59869,45 @@ func (x *SerializedReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3883Slc = r.DecodeBytes(yys3883Slc, true, true) - yys3883 := string(yys3883Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3883 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "reference": if r.TryDecodeAsNil() { x.Reference = ObjectReference{} } else { - yyv3886 := &x.Reference - yyv3886.CodecDecodeSelf(d) + yyv8 := &x.Reference + yyv8.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys3883) - } // end switch yys3883 - } // end for yyj3883 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -48947,16 +59915,16 @@ func (x *SerializedReference) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3887 int - var yyb3887 bool - var yyhl3887 bool = l >= 0 - yyj3887++ - if yyhl3887 { - yyb3887 = yyj3887 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb3887 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb3887 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48964,15 +59932,21 @@ func (x *SerializedReference) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv10 := &x.Kind + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } - yyj3887++ - if yyhl3887 { - yyb3887 = yyj3887 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb3887 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb3887 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48980,15 +59954,21 @@ func (x *SerializedReference) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv12 := &x.APIVersion + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj3887++ - if yyhl3887 { - yyb3887 = yyj3887 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb3887 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb3887 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -48996,21 +59976,21 @@ func (x *SerializedReference) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Reference = ObjectReference{} } else { - yyv3890 := &x.Reference - yyv3890.CodecDecodeSelf(d) + yyv14 := &x.Reference + yyv14.CodecDecodeSelf(d) } for { - yyj3887++ - if yyhl3887 { - yyb3887 = yyj3887 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb3887 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb3887 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3887-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -49022,36 +60002,36 @@ func (x *EventSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3891 := z.EncBinary() - _ = yym3891 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3892 := !z.EncBinary() - yy2arr3892 := z.EncBasicHandle().StructToArray - var yyq3892 [2]bool - _, _, _ = yysep3892, yyq3892, yy2arr3892 - const yyr3892 bool = false - yyq3892[0] = x.Component != "" - yyq3892[1] = x.Host != "" - var yynn3892 int - if yyr3892 || yy2arr3892 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Component != "" + yyq2[1] = x.Host != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn3892 = 0 - for _, b := range yyq3892 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn3892++ + yynn2++ } } - r.EncodeMapStart(yynn3892) - yynn3892 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3892 || yy2arr3892 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3892[0] { - yym3894 := z.EncBinary() - _ = yym3894 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Component)) @@ -49060,23 +60040,23 @@ func (x *EventSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3892[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("component")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3895 := z.EncBinary() - _ = yym3895 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Component)) } } } - if yyr3892 || yy2arr3892 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3892[1] { - yym3897 := z.EncBinary() - _ = yym3897 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Host)) @@ -49085,19 +60065,19 @@ func (x *EventSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3892[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("host")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3898 := z.EncBinary() - _ = yym3898 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Host)) } } } - if yyr3892 || yy2arr3892 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -49110,25 +60090,25 @@ func (x *EventSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3899 := z.DecBinary() - _ = yym3899 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3900 := r.ContainerType() - if yyct3900 == codecSelferValueTypeMap1234 { - yyl3900 := r.ReadMapStart() - if yyl3900 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3900, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3900 == codecSelferValueTypeArray1234 { - yyl3900 := r.ReadArrayStart() - if yyl3900 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3900, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -49140,12 +60120,12 @@ func (x *EventSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3901Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3901Slc - var yyhl3901 bool = l >= 0 - for yyj3901 := 0; ; yyj3901++ { - if yyhl3901 { - if yyj3901 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -49154,26 +60134,38 @@ func (x *EventSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3901Slc = r.DecodeBytes(yys3901Slc, true, true) - yys3901 := string(yys3901Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3901 { + switch yys3 { case "component": if r.TryDecodeAsNil() { x.Component = "" } else { - x.Component = string(r.DecodeString()) + yyv4 := &x.Component + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "host": if r.TryDecodeAsNil() { x.Host = "" } else { - x.Host = string(r.DecodeString()) + yyv6 := &x.Host + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3901) - } // end switch yys3901 - } // end for yyj3901 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -49181,16 +60173,16 @@ func (x *EventSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3904 int - var yyb3904 bool - var yyhl3904 bool = l >= 0 - yyj3904++ - if yyhl3904 { - yyb3904 = yyj3904 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb3904 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb3904 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49198,15 +60190,21 @@ func (x *EventSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Component = "" } else { - x.Component = string(r.DecodeString()) + yyv9 := &x.Component + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj3904++ - if yyhl3904 { - yyb3904 = yyj3904 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb3904 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb3904 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49214,20 +60212,26 @@ func (x *EventSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Host = "" } else { - x.Host = string(r.DecodeString()) + yyv11 := &x.Host + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj3904++ - if yyhl3904 { - yyb3904 = yyj3904 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb3904 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb3904 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3904-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -49239,43 +60243,43 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3907 := z.EncBinary() - _ = yym3907 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3908 := !z.EncBinary() - yy2arr3908 := z.EncBasicHandle().StructToArray - var yyq3908 [11]bool - _, _, _ = yysep3908, yyq3908, yy2arr3908 - const yyr3908 bool = false - yyq3908[0] = x.Kind != "" - yyq3908[1] = x.APIVersion != "" - yyq3908[4] = x.Reason != "" - yyq3908[5] = x.Message != "" - yyq3908[6] = true - yyq3908[7] = true - yyq3908[8] = true - yyq3908[9] = x.Count != 0 - yyq3908[10] = x.Type != "" - var yynn3908 int - if yyr3908 || yy2arr3908 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [11]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[4] = x.Reason != "" + yyq2[5] = x.Message != "" + yyq2[6] = true + yyq2[7] = true + yyq2[8] = true + yyq2[9] = x.Count != 0 + yyq2[10] = x.Type != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(11) } else { - yynn3908 = 2 - for _, b := range yyq3908 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn3908++ + yynn2++ } } - r.EncodeMapStart(yynn3908) - yynn3908 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[0] { - yym3910 := z.EncBinary() - _ = yym3910 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -49284,23 +60288,23 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3908[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3911 := z.EncBinary() - _ = yym3911 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[1] { - yym3913 := z.EncBinary() - _ = yym3913 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -49309,45 +60313,57 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3908[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3914 := z.EncBinary() - _ = yym3914 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3916 := &x.ObjectMeta - yy3916.CodecEncodeSelf(e) + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3917 := &x.ObjectMeta - yy3917.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy3919 := &x.InvolvedObject - yy3919.CodecEncodeSelf(e) + yy15 := &x.InvolvedObject + yy15.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("involvedObject")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3920 := &x.InvolvedObject - yy3920.CodecEncodeSelf(e) + yy17 := &x.InvolvedObject + yy17.CodecEncodeSelf(e) } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[4] { - yym3922 := z.EncBinary() - _ = yym3922 + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -49356,23 +60372,23 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3908[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3923 := z.EncBinary() - _ = yym3923 + yym21 := z.EncBinary() + _ = yym21 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[5] { - yym3925 := z.EncBinary() - _ = yym3925 + if yyq2[5] { + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -49381,114 +60397,114 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3908[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3926 := z.EncBinary() - _ = yym3926 + yym24 := z.EncBinary() + _ = yym24 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[6] { - yy3928 := &x.Source - yy3928.CodecEncodeSelf(e) + if yyq2[6] { + yy26 := &x.Source + yy26.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq3908[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("source")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3929 := &x.Source - yy3929.CodecEncodeSelf(e) + yy28 := &x.Source + yy28.CodecEncodeSelf(e) } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[7] { - yy3931 := &x.FirstTimestamp - yym3932 := z.EncBinary() - _ = yym3932 + if yyq2[7] { + yy31 := &x.FirstTimestamp + yym32 := z.EncBinary() + _ = yym32 if false { - } else if z.HasExtensions() && z.EncExt(yy3931) { - } else if yym3932 { - z.EncBinaryMarshal(yy3931) - } else if !yym3932 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3931) + } else if z.HasExtensions() && z.EncExt(yy31) { + } else if yym32 { + z.EncBinaryMarshal(yy31) + } else if !yym32 && z.IsJSONHandle() { + z.EncJSONMarshal(yy31) } else { - z.EncFallback(yy3931) + z.EncFallback(yy31) } } else { r.EncodeNil() } } else { - if yyq3908[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("firstTimestamp")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3933 := &x.FirstTimestamp - yym3934 := z.EncBinary() - _ = yym3934 + yy33 := &x.FirstTimestamp + yym34 := z.EncBinary() + _ = yym34 if false { - } else if z.HasExtensions() && z.EncExt(yy3933) { - } else if yym3934 { - z.EncBinaryMarshal(yy3933) - } else if !yym3934 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3933) + } else if z.HasExtensions() && z.EncExt(yy33) { + } else if yym34 { + z.EncBinaryMarshal(yy33) + } else if !yym34 && z.IsJSONHandle() { + z.EncJSONMarshal(yy33) } else { - z.EncFallback(yy3933) + z.EncFallback(yy33) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[8] { - yy3936 := &x.LastTimestamp - yym3937 := z.EncBinary() - _ = yym3937 + if yyq2[8] { + yy36 := &x.LastTimestamp + yym37 := z.EncBinary() + _ = yym37 if false { - } else if z.HasExtensions() && z.EncExt(yy3936) { - } else if yym3937 { - z.EncBinaryMarshal(yy3936) - } else if !yym3937 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3936) + } else if z.HasExtensions() && z.EncExt(yy36) { + } else if yym37 { + z.EncBinaryMarshal(yy36) + } else if !yym37 && z.IsJSONHandle() { + z.EncJSONMarshal(yy36) } else { - z.EncFallback(yy3936) + z.EncFallback(yy36) } } else { r.EncodeNil() } } else { - if yyq3908[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastTimestamp")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3938 := &x.LastTimestamp - yym3939 := z.EncBinary() - _ = yym3939 + yy38 := &x.LastTimestamp + yym39 := z.EncBinary() + _ = yym39 if false { - } else if z.HasExtensions() && z.EncExt(yy3938) { - } else if yym3939 { - z.EncBinaryMarshal(yy3938) - } else if !yym3939 && z.IsJSONHandle() { - z.EncJSONMarshal(yy3938) + } else if z.HasExtensions() && z.EncExt(yy38) { + } else if yym39 { + z.EncBinaryMarshal(yy38) + } else if !yym39 && z.IsJSONHandle() { + z.EncJSONMarshal(yy38) } else { - z.EncFallback(yy3938) + z.EncFallback(yy38) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[9] { - yym3941 := z.EncBinary() - _ = yym3941 + if yyq2[9] { + yym41 := z.EncBinary() + _ = yym41 if false { } else { r.EncodeInt(int64(x.Count)) @@ -49497,23 +60513,23 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq3908[9] { + if yyq2[9] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("count")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3942 := z.EncBinary() - _ = yym3942 + yym42 := z.EncBinary() + _ = yym42 if false { } else { r.EncodeInt(int64(x.Count)) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3908[10] { - yym3944 := z.EncBinary() - _ = yym3944 + if yyq2[10] { + yym44 := z.EncBinary() + _ = yym44 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Type)) @@ -49522,19 +60538,19 @@ func (x *Event) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3908[10] { + if yyq2[10] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3945 := z.EncBinary() - _ = yym3945 + yym45 := z.EncBinary() + _ = yym45 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Type)) } } } - if yyr3908 || yy2arr3908 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -49547,25 +60563,25 @@ func (x *Event) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3946 := z.DecBinary() - _ = yym3946 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3947 := r.ContainerType() - if yyct3947 == codecSelferValueTypeMap1234 { - yyl3947 := r.ReadMapStart() - if yyl3947 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3947, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3947 == codecSelferValueTypeArray1234 { - yyl3947 := r.ReadArrayStart() - if yyl3947 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3947, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -49577,12 +60593,12 @@ func (x *Event) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3948Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3948Slc - var yyhl3948 bool = l >= 0 - for yyj3948 := 0; ; yyj3948++ { - if yyhl3948 { - if yyj3948 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -49591,105 +60607,147 @@ func (x *Event) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3948Slc = r.DecodeBytes(yys3948Slc, true, true) - yys3948 := string(yys3948Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3948 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3951 := &x.ObjectMeta - yyv3951.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "involvedObject": if r.TryDecodeAsNil() { x.InvolvedObject = ObjectReference{} } else { - yyv3952 := &x.InvolvedObject - yyv3952.CodecDecodeSelf(d) + yyv10 := &x.InvolvedObject + yyv10.CodecDecodeSelf(d) } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv11 := &x.Reason + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv13 := &x.Message + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } case "source": if r.TryDecodeAsNil() { x.Source = EventSource{} } else { - yyv3955 := &x.Source - yyv3955.CodecDecodeSelf(d) + yyv15 := &x.Source + yyv15.CodecDecodeSelf(d) } case "firstTimestamp": if r.TryDecodeAsNil() { - x.FirstTimestamp = pkg2_unversioned.Time{} + x.FirstTimestamp = pkg2_v1.Time{} } else { - yyv3956 := &x.FirstTimestamp - yym3957 := z.DecBinary() - _ = yym3957 + yyv16 := &x.FirstTimestamp + yym17 := z.DecBinary() + _ = yym17 if false { - } else if z.HasExtensions() && z.DecExt(yyv3956) { - } else if yym3957 { - z.DecBinaryUnmarshal(yyv3956) - } else if !yym3957 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3956) + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else if yym17 { + z.DecBinaryUnmarshal(yyv16) + } else if !yym17 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv16) } else { - z.DecFallback(yyv3956, false) + z.DecFallback(yyv16, false) } } case "lastTimestamp": if r.TryDecodeAsNil() { - x.LastTimestamp = pkg2_unversioned.Time{} + x.LastTimestamp = pkg2_v1.Time{} } else { - yyv3958 := &x.LastTimestamp - yym3959 := z.DecBinary() - _ = yym3959 + yyv18 := &x.LastTimestamp + yym19 := z.DecBinary() + _ = yym19 if false { - } else if z.HasExtensions() && z.DecExt(yyv3958) { - } else if yym3959 { - z.DecBinaryUnmarshal(yyv3958) - } else if !yym3959 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3958) + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else if yym19 { + z.DecBinaryUnmarshal(yyv18) + } else if !yym19 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv18) } else { - z.DecFallback(yyv3958, false) + z.DecFallback(yyv18, false) } } case "count": if r.TryDecodeAsNil() { x.Count = 0 } else { - x.Count = int32(r.DecodeInt(32)) + yyv20 := &x.Count + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*int32)(yyv20)) = int32(r.DecodeInt(32)) + } } case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = string(r.DecodeString()) + yyv22 := &x.Type + yym23 := z.DecBinary() + _ = yym23 + if false { + } else { + *((*string)(yyv22)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys3948) - } // end switch yys3948 - } // end for yyj3948 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -49697,16 +60755,16 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj3962 int - var yyb3962 bool - var yyhl3962 bool = l >= 0 - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + var yyj24 int + var yyb24 bool + var yyhl24 bool = l >= 0 + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49714,15 +60772,21 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv25 := &x.Kind + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49730,32 +60794,44 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv27 := &x.APIVersion + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv3965 := &x.ObjectMeta - yyv3965.CodecDecodeSelf(d) + yyv29 := &x.ObjectMeta + yym30 := z.DecBinary() + _ = yym30 + if false { + } else if z.HasExtensions() && z.DecExt(yyv29) { + } else { + z.DecFallback(yyv29, false) + } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49763,16 +60839,16 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.InvolvedObject = ObjectReference{} } else { - yyv3966 := &x.InvolvedObject - yyv3966.CodecDecodeSelf(d) + yyv31 := &x.InvolvedObject + yyv31.CodecDecodeSelf(d) } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49780,15 +60856,21 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv32 := &x.Reason + yym33 := z.DecBinary() + _ = yym33 + if false { + } else { + *((*string)(yyv32)) = r.DecodeString() + } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49796,15 +60878,21 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv34 := &x.Message + yym35 := z.DecBinary() + _ = yym35 + if false { + } else { + *((*string)(yyv34)) = r.DecodeString() + } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49812,70 +60900,70 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Source = EventSource{} } else { - yyv3969 := &x.Source - yyv3969.CodecDecodeSelf(d) + yyv36 := &x.Source + yyv36.CodecDecodeSelf(d) } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.FirstTimestamp = pkg2_unversioned.Time{} + x.FirstTimestamp = pkg2_v1.Time{} } else { - yyv3970 := &x.FirstTimestamp - yym3971 := z.DecBinary() - _ = yym3971 + yyv37 := &x.FirstTimestamp + yym38 := z.DecBinary() + _ = yym38 if false { - } else if z.HasExtensions() && z.DecExt(yyv3970) { - } else if yym3971 { - z.DecBinaryUnmarshal(yyv3970) - } else if !yym3971 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3970) + } else if z.HasExtensions() && z.DecExt(yyv37) { + } else if yym38 { + z.DecBinaryUnmarshal(yyv37) + } else if !yym38 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv37) } else { - z.DecFallback(yyv3970, false) + z.DecFallback(yyv37, false) } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTimestamp = pkg2_unversioned.Time{} + x.LastTimestamp = pkg2_v1.Time{} } else { - yyv3972 := &x.LastTimestamp - yym3973 := z.DecBinary() - _ = yym3973 + yyv39 := &x.LastTimestamp + yym40 := z.DecBinary() + _ = yym40 if false { - } else if z.HasExtensions() && z.DecExt(yyv3972) { - } else if yym3973 { - z.DecBinaryUnmarshal(yyv3972) - } else if !yym3973 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv3972) + } else if z.HasExtensions() && z.DecExt(yyv39) { + } else if yym40 { + z.DecBinaryUnmarshal(yyv39) + } else if !yym40 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv39) } else { - z.DecFallback(yyv3972, false) + z.DecFallback(yyv39, false) } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49883,15 +60971,21 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Count = 0 } else { - x.Count = int32(r.DecodeInt(32)) + yyv41 := &x.Count + yym42 := z.DecBinary() + _ = yym42 + if false { + } else { + *((*int32)(yyv41)) = int32(r.DecodeInt(32)) + } } - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -49899,20 +60993,26 @@ func (x *Event) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = string(r.DecodeString()) + yyv43 := &x.Type + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*string)(yyv43)) = r.DecodeString() + } } for { - yyj3962++ - if yyhl3962 { - yyb3962 = yyj3962 > l + yyj24++ + if yyhl24 { + yyb24 = yyj24 > l } else { - yyb3962 = r.CheckBreak() + yyb24 = r.CheckBreak() } - if yyb3962 { + if yyb24 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj3962-1, "") + z.DecStructFieldNotFound(yyj24-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -49924,37 +61024,37 @@ func (x *EventList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym3976 := z.EncBinary() - _ = yym3976 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep3977 := !z.EncBinary() - yy2arr3977 := z.EncBasicHandle().StructToArray - var yyq3977 [4]bool - _, _, _ = yysep3977, yyq3977, yy2arr3977 - const yyr3977 bool = false - yyq3977[0] = x.Kind != "" - yyq3977[1] = x.APIVersion != "" - yyq3977[2] = true - var yynn3977 int - if yyr3977 || yy2arr3977 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn3977 = 1 - for _, b := range yyq3977 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn3977++ + yynn2++ } } - r.EncodeMapStart(yynn3977) - yynn3977 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr3977 || yy2arr3977 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3977[0] { - yym3979 := z.EncBinary() - _ = yym3979 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -49963,23 +61063,23 @@ func (x *EventList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3977[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3980 := z.EncBinary() - _ = yym3980 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr3977 || yy2arr3977 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3977[1] { - yym3982 := z.EncBinary() - _ = yym3982 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -49988,54 +61088,54 @@ func (x *EventList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq3977[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym3983 := z.EncBinary() - _ = yym3983 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr3977 || yy2arr3977 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq3977[2] { - yy3985 := &x.ListMeta - yym3986 := z.EncBinary() - _ = yym3986 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy3985) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy3985) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq3977[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy3987 := &x.ListMeta - yym3988 := z.EncBinary() - _ = yym3988 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy3987) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy3987) + z.EncFallback(yy12) } } } - if yyr3977 || yy2arr3977 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym3990 := z.EncBinary() - _ = yym3990 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceEvent(([]Event)(x.Items), e) @@ -50048,15 +61148,15 @@ func (x *EventList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym3991 := z.EncBinary() - _ = yym3991 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceEvent(([]Event)(x.Items), e) } } } - if yyr3977 || yy2arr3977 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -50069,25 +61169,25 @@ func (x *EventList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym3992 := z.DecBinary() - _ = yym3992 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct3993 := r.ContainerType() - if yyct3993 == codecSelferValueTypeMap1234 { - yyl3993 := r.ReadMapStart() - if yyl3993 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl3993, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct3993 == codecSelferValueTypeArray1234 { - yyl3993 := r.ReadArrayStart() - if yyl3993 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl3993, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -50099,12 +61199,12 @@ func (x *EventList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys3994Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys3994Slc - var yyhl3994 bool = l >= 0 - for yyj3994 := 0; ; yyj3994++ { - if yyhl3994 { - if yyj3994 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -50113,51 +61213,63 @@ func (x *EventList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys3994Slc = r.DecodeBytes(yys3994Slc, true, true) - yys3994 := string(yys3994Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys3994 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv3997 := &x.ListMeta - yym3998 := z.DecBinary() - _ = yym3998 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv3997) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv3997, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv3999 := &x.Items - yym4000 := z.DecBinary() - _ = yym4000 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceEvent((*[]Event)(yyv3999), d) + h.decSliceEvent((*[]Event)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys3994) - } // end switch yys3994 - } // end for yyj3994 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -50165,16 +61277,16 @@ func (x *EventList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4001 int - var yyb4001 bool - var yyhl4001 bool = l >= 0 - yyj4001++ - if yyhl4001 { - yyb4001 = yyj4001 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4001 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4001 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50182,15 +61294,21 @@ func (x *EventList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4001++ - if yyhl4001 { - yyb4001 = yyj4001 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4001 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4001 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50198,38 +61316,44 @@ func (x *EventList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4001++ - if yyhl4001 { - yyb4001 = yyj4001 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4001 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4001 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4004 := &x.ListMeta - yym4005 := z.DecBinary() - _ = yym4005 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4004) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4004, false) + z.DecFallback(yyv17, false) } } - yyj4001++ - if yyhl4001 { - yyb4001 = yyj4001 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4001 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4001 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50237,26 +61361,26 @@ func (x *EventList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4006 := &x.Items - yym4007 := z.DecBinary() - _ = yym4007 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceEvent((*[]Event)(yyv4006), d) + h.decSliceEvent((*[]Event)(yyv19), d) } } for { - yyj4001++ - if yyhl4001 { - yyb4001 = yyj4001 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4001 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4001 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4001-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -50268,37 +61392,37 @@ func (x *List) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4008 := z.EncBinary() - _ = yym4008 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4009 := !z.EncBinary() - yy2arr4009 := z.EncBasicHandle().StructToArray - var yyq4009 [4]bool - _, _, _ = yysep4009, yyq4009, yy2arr4009 - const yyr4009 bool = false - yyq4009[0] = x.Kind != "" - yyq4009[1] = x.APIVersion != "" - yyq4009[2] = true - var yynn4009 int - if yyr4009 || yy2arr4009 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4009 = 1 - for _, b := range yyq4009 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4009++ + yynn2++ } } - r.EncodeMapStart(yynn4009) - yynn4009 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4009 || yy2arr4009 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4009[0] { - yym4011 := z.EncBinary() - _ = yym4011 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -50307,23 +61431,23 @@ func (x *List) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4009[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4012 := z.EncBinary() - _ = yym4012 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4009 || yy2arr4009 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4009[1] { - yym4014 := z.EncBinary() - _ = yym4014 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -50332,54 +61456,54 @@ func (x *List) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4009[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4015 := z.EncBinary() - _ = yym4015 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4009 || yy2arr4009 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4009[2] { - yy4017 := &x.ListMeta - yym4018 := z.EncBinary() - _ = yym4018 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy4017) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy4017) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq4009[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4019 := &x.ListMeta - yym4020 := z.EncBinary() - _ = yym4020 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy4019) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy4019) + z.EncFallback(yy12) } } } - if yyr4009 || yy2arr4009 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym4022 := z.EncBinary() - _ = yym4022 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceruntime_RawExtension(([]pkg5_runtime.RawExtension)(x.Items), e) @@ -50392,15 +61516,15 @@ func (x *List) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym4023 := z.EncBinary() - _ = yym4023 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceruntime_RawExtension(([]pkg5_runtime.RawExtension)(x.Items), e) } } } - if yyr4009 || yy2arr4009 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -50413,25 +61537,25 @@ func (x *List) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4024 := z.DecBinary() - _ = yym4024 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4025 := r.ContainerType() - if yyct4025 == codecSelferValueTypeMap1234 { - yyl4025 := r.ReadMapStart() - if yyl4025 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4025, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4025 == codecSelferValueTypeArray1234 { - yyl4025 := r.ReadArrayStart() - if yyl4025 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4025, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -50443,12 +61567,12 @@ func (x *List) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4026Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4026Slc - var yyhl4026 bool = l >= 0 - for yyj4026 := 0; ; yyj4026++ { - if yyhl4026 { - if yyj4026 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -50457,51 +61581,63 @@ func (x *List) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4026Slc = r.DecodeBytes(yys4026Slc, true, true) - yys4026 := string(yys4026Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4026 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4029 := &x.ListMeta - yym4030 := z.DecBinary() - _ = yym4030 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv4029) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv4029, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4031 := &x.Items - yym4032 := z.DecBinary() - _ = yym4032 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv4031), d) + h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4026) - } // end switch yys4026 - } // end for yyj4026 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -50509,16 +61645,16 @@ func (x *List) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4033 int - var yyb4033 bool - var yyhl4033 bool = l >= 0 - yyj4033++ - if yyhl4033 { - yyb4033 = yyj4033 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4033 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4033 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50526,15 +61662,21 @@ func (x *List) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4033++ - if yyhl4033 { - yyb4033 = yyj4033 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4033 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4033 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50542,38 +61684,44 @@ func (x *List) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4033++ - if yyhl4033 { - yyb4033 = yyj4033 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4033 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4033 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4036 := &x.ListMeta - yym4037 := z.DecBinary() - _ = yym4037 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4036) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4036, false) + z.DecFallback(yyv17, false) } } - yyj4033++ - if yyhl4033 { - yyb4033 = yyj4033 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4033 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4033 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50581,26 +61729,26 @@ func (x *List) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4038 := &x.Items - yym4039 := z.DecBinary() - _ = yym4039 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv4038), d) + h.decSliceruntime_RawExtension((*[]pkg5_runtime.RawExtension)(yyv19), d) } } for { - yyj4033++ - if yyhl4033 { - yyb4033 = yyj4033 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4033 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4033 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4033-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -50609,8 +61757,8 @@ func (x LimitType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym4040 := z.EncBinary() - _ = yym4040 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -50622,8 +61770,8 @@ func (x *LimitType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4041 := z.DecBinary() - _ = yym4041 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -50638,53 +61786,53 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4042 := z.EncBinary() - _ = yym4042 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4043 := !z.EncBinary() - yy2arr4043 := z.EncBasicHandle().StructToArray - var yyq4043 [6]bool - _, _, _ = yysep4043, yyq4043, yy2arr4043 - const yyr4043 bool = false - yyq4043[0] = x.Type != "" - yyq4043[1] = len(x.Max) != 0 - yyq4043[2] = len(x.Min) != 0 - yyq4043[3] = len(x.Default) != 0 - yyq4043[4] = len(x.DefaultRequest) != 0 - yyq4043[5] = len(x.MaxLimitRequestRatio) != 0 - var yynn4043 int - if yyr4043 || yy2arr4043 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Type != "" + yyq2[1] = len(x.Max) != 0 + yyq2[2] = len(x.Min) != 0 + yyq2[3] = len(x.Default) != 0 + yyq2[4] = len(x.DefaultRequest) != 0 + yyq2[5] = len(x.MaxLimitRequestRatio) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn4043 = 0 - for _, b := range yyq4043 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4043++ + yynn2++ } } - r.EncodeMapStart(yynn4043) - yynn4043 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4043[0] { + if yyq2[0] { x.Type.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4043[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4043[1] { + if yyq2[1] { if x.Max == nil { r.EncodeNil() } else { @@ -50694,7 +61842,7 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4043[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("max")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -50705,9 +61853,9 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4043[2] { + if yyq2[2] { if x.Min == nil { r.EncodeNil() } else { @@ -50717,7 +61865,7 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4043[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("min")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -50728,9 +61876,9 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4043[3] { + if yyq2[3] { if x.Default == nil { r.EncodeNil() } else { @@ -50740,7 +61888,7 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4043[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("default")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -50751,9 +61899,9 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4043[4] { + if yyq2[4] { if x.DefaultRequest == nil { r.EncodeNil() } else { @@ -50763,7 +61911,7 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4043[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("defaultRequest")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -50774,9 +61922,9 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4043[5] { + if yyq2[5] { if x.MaxLimitRequestRatio == nil { r.EncodeNil() } else { @@ -50786,7 +61934,7 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4043[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("maxLimitRequestRatio")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -50797,7 +61945,7 @@ func (x *LimitRangeItem) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4043 || yy2arr4043 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -50810,25 +61958,25 @@ func (x *LimitRangeItem) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4050 := z.DecBinary() - _ = yym4050 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4051 := r.ContainerType() - if yyct4051 == codecSelferValueTypeMap1234 { - yyl4051 := r.ReadMapStart() - if yyl4051 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4051, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4051 == codecSelferValueTypeArray1234 { - yyl4051 := r.ReadArrayStart() - if yyl4051 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4051, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -50840,12 +61988,12 @@ func (x *LimitRangeItem) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4052Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4052Slc - var yyhl4052 bool = l >= 0 - for yyj4052 := 0; ; yyj4052++ { - if yyhl4052 { - if yyj4052 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -50854,55 +62002,56 @@ func (x *LimitRangeItem) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4052Slc = r.DecodeBytes(yys4052Slc, true, true) - yys4052 := string(yys4052Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4052 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = LimitType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "max": if r.TryDecodeAsNil() { x.Max = nil } else { - yyv4054 := &x.Max - yyv4054.CodecDecodeSelf(d) + yyv5 := &x.Max + yyv5.CodecDecodeSelf(d) } case "min": if r.TryDecodeAsNil() { x.Min = nil } else { - yyv4055 := &x.Min - yyv4055.CodecDecodeSelf(d) + yyv6 := &x.Min + yyv6.CodecDecodeSelf(d) } case "default": if r.TryDecodeAsNil() { x.Default = nil } else { - yyv4056 := &x.Default - yyv4056.CodecDecodeSelf(d) + yyv7 := &x.Default + yyv7.CodecDecodeSelf(d) } case "defaultRequest": if r.TryDecodeAsNil() { x.DefaultRequest = nil } else { - yyv4057 := &x.DefaultRequest - yyv4057.CodecDecodeSelf(d) + yyv8 := &x.DefaultRequest + yyv8.CodecDecodeSelf(d) } case "maxLimitRequestRatio": if r.TryDecodeAsNil() { x.MaxLimitRequestRatio = nil } else { - yyv4058 := &x.MaxLimitRequestRatio - yyv4058.CodecDecodeSelf(d) + yyv9 := &x.MaxLimitRequestRatio + yyv9.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys4052) - } // end switch yys4052 - } // end for yyj4052 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -50910,16 +62059,16 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4059 int - var yyb4059 bool - var yyhl4059 bool = l >= 0 - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50927,15 +62076,16 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = LimitType(r.DecodeString()) + yyv11 := &x.Type + yyv11.CodecDecodeSelf(d) } - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50943,16 +62093,16 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Max = nil } else { - yyv4061 := &x.Max - yyv4061.CodecDecodeSelf(d) + yyv12 := &x.Max + yyv12.CodecDecodeSelf(d) } - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50960,16 +62110,16 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Min = nil } else { - yyv4062 := &x.Min - yyv4062.CodecDecodeSelf(d) + yyv13 := &x.Min + yyv13.CodecDecodeSelf(d) } - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50977,16 +62127,16 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Default = nil } else { - yyv4063 := &x.Default - yyv4063.CodecDecodeSelf(d) + yyv14 := &x.Default + yyv14.CodecDecodeSelf(d) } - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -50994,16 +62144,16 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.DefaultRequest = nil } else { - yyv4064 := &x.DefaultRequest - yyv4064.CodecDecodeSelf(d) + yyv15 := &x.DefaultRequest + yyv15.CodecDecodeSelf(d) } - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51011,21 +62161,21 @@ func (x *LimitRangeItem) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.MaxLimitRequestRatio = nil } else { - yyv4065 := &x.MaxLimitRequestRatio - yyv4065.CodecDecodeSelf(d) + yyv16 := &x.MaxLimitRequestRatio + yyv16.CodecDecodeSelf(d) } for { - yyj4059++ - if yyhl4059 { - yyb4059 = yyj4059 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4059 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4059 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4059-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -51037,36 +62187,36 @@ func (x *LimitRangeSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4066 := z.EncBinary() - _ = yym4066 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4067 := !z.EncBinary() - yy2arr4067 := z.EncBasicHandle().StructToArray - var yyq4067 [1]bool - _, _, _ = yysep4067, yyq4067, yy2arr4067 - const yyr4067 bool = false - var yynn4067 int - if yyr4067 || yy2arr4067 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn4067 = 1 - for _, b := range yyq4067 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4067++ + yynn2++ } } - r.EncodeMapStart(yynn4067) - yynn4067 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4067 || yy2arr4067 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Limits == nil { r.EncodeNil() } else { - yym4069 := z.EncBinary() - _ = yym4069 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceLimitRangeItem(([]LimitRangeItem)(x.Limits), e) @@ -51079,15 +62229,15 @@ func (x *LimitRangeSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x.Limits == nil { r.EncodeNil() } else { - yym4070 := z.EncBinary() - _ = yym4070 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceLimitRangeItem(([]LimitRangeItem)(x.Limits), e) } } } - if yyr4067 || yy2arr4067 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -51100,25 +62250,25 @@ func (x *LimitRangeSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4071 := z.DecBinary() - _ = yym4071 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4072 := r.ContainerType() - if yyct4072 == codecSelferValueTypeMap1234 { - yyl4072 := r.ReadMapStart() - if yyl4072 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4072, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4072 == codecSelferValueTypeArray1234 { - yyl4072 := r.ReadArrayStart() - if yyl4072 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4072, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -51130,12 +62280,12 @@ func (x *LimitRangeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4073Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4073Slc - var yyhl4073 bool = l >= 0 - for yyj4073 := 0; ; yyj4073++ { - if yyhl4073 { - if yyj4073 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -51144,26 +62294,26 @@ func (x *LimitRangeSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4073Slc = r.DecodeBytes(yys4073Slc, true, true) - yys4073 := string(yys4073Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4073 { + switch yys3 { case "limits": if r.TryDecodeAsNil() { x.Limits = nil } else { - yyv4074 := &x.Limits - yym4075 := z.DecBinary() - _ = yym4075 + yyv4 := &x.Limits + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv4074), d) + h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys4073) - } // end switch yys4073 - } // end for yyj4073 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -51171,16 +62321,16 @@ func (x *LimitRangeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4076 int - var yyb4076 bool - var yyhl4076 bool = l >= 0 - yyj4076++ - if yyhl4076 { - yyb4076 = yyj4076 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4076 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4076 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51188,26 +62338,26 @@ func (x *LimitRangeSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Limits = nil } else { - yyv4077 := &x.Limits - yym4078 := z.DecBinary() - _ = yym4078 + yyv7 := &x.Limits + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv4077), d) + h.decSliceLimitRangeItem((*[]LimitRangeItem)(yyv7), d) } } for { - yyj4076++ - if yyhl4076 { - yyb4076 = yyj4076 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4076 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4076 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4076-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -51219,38 +62369,38 @@ func (x *LimitRange) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4079 := z.EncBinary() - _ = yym4079 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4080 := !z.EncBinary() - yy2arr4080 := z.EncBasicHandle().StructToArray - var yyq4080 [4]bool - _, _, _ = yysep4080, yyq4080, yy2arr4080 - const yyr4080 bool = false - yyq4080[0] = x.Kind != "" - yyq4080[1] = x.APIVersion != "" - yyq4080[2] = true - yyq4080[3] = true - var yynn4080 int - if yyr4080 || yy2arr4080 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4080 = 0 - for _, b := range yyq4080 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4080++ + yynn2++ } } - r.EncodeMapStart(yynn4080) - yynn4080 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4080 || yy2arr4080 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4080[0] { - yym4082 := z.EncBinary() - _ = yym4082 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -51259,23 +62409,23 @@ func (x *LimitRange) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4080[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4083 := z.EncBinary() - _ = yym4083 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4080 || yy2arr4080 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4080[1] { - yym4085 := z.EncBinary() - _ = yym4085 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -51284,53 +62434,65 @@ func (x *LimitRange) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4080[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4086 := z.EncBinary() - _ = yym4086 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4080 || yy2arr4080 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4080[2] { - yy4088 := &x.ObjectMeta - yy4088.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq4080[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4089 := &x.ObjectMeta - yy4089.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr4080 || yy2arr4080 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4080[3] { - yy4091 := &x.Spec - yy4091.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq4080[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4092 := &x.Spec - yy4092.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr4080 || yy2arr4080 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -51343,25 +62505,25 @@ func (x *LimitRange) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4093 := z.DecBinary() - _ = yym4093 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4094 := r.ContainerType() - if yyct4094 == codecSelferValueTypeMap1234 { - yyl4094 := r.ReadMapStart() - if yyl4094 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4094, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4094 == codecSelferValueTypeArray1234 { - yyl4094 := r.ReadArrayStart() - if yyl4094 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4094, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -51373,12 +62535,12 @@ func (x *LimitRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4095Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4095Slc - var yyhl4095 bool = l >= 0 - for yyj4095 := 0; ; yyj4095++ { - if yyhl4095 { - if yyj4095 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -51387,40 +62549,58 @@ func (x *LimitRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4095Slc = r.DecodeBytes(yys4095Slc, true, true) - yys4095 := string(yys4095Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4095 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4098 := &x.ObjectMeta - yyv4098.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = LimitRangeSpec{} } else { - yyv4099 := &x.Spec - yyv4099.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys4095) - } // end switch yys4095 - } // end for yyj4095 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -51428,16 +62608,16 @@ func (x *LimitRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4100 int - var yyb4100 bool - var yyhl4100 bool = l >= 0 - yyj4100++ - if yyhl4100 { - yyb4100 = yyj4100 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb4100 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb4100 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51445,15 +62625,21 @@ func (x *LimitRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj4100++ - if yyhl4100 { - yyb4100 = yyj4100 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb4100 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb4100 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51461,32 +62647,44 @@ func (x *LimitRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj4100++ - if yyhl4100 { - yyb4100 = yyj4100 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb4100 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb4100 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4103 := &x.ObjectMeta - yyv4103.CodecDecodeSelf(d) + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } } - yyj4100++ - if yyhl4100 { - yyb4100 = yyj4100 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb4100 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb4100 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51494,21 +62692,21 @@ func (x *LimitRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = LimitRangeSpec{} } else { - yyv4104 := &x.Spec - yyv4104.CodecDecodeSelf(d) + yyv18 := &x.Spec + yyv18.CodecDecodeSelf(d) } for { - yyj4100++ - if yyhl4100 { - yyb4100 = yyj4100 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb4100 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb4100 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4100-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -51520,37 +62718,37 @@ func (x *LimitRangeList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4105 := z.EncBinary() - _ = yym4105 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4106 := !z.EncBinary() - yy2arr4106 := z.EncBasicHandle().StructToArray - var yyq4106 [4]bool - _, _, _ = yysep4106, yyq4106, yy2arr4106 - const yyr4106 bool = false - yyq4106[0] = x.Kind != "" - yyq4106[1] = x.APIVersion != "" - yyq4106[2] = true - var yynn4106 int - if yyr4106 || yy2arr4106 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4106 = 1 - for _, b := range yyq4106 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4106++ + yynn2++ } } - r.EncodeMapStart(yynn4106) - yynn4106 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4106 || yy2arr4106 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4106[0] { - yym4108 := z.EncBinary() - _ = yym4108 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -51559,23 +62757,23 @@ func (x *LimitRangeList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4106[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4109 := z.EncBinary() - _ = yym4109 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4106 || yy2arr4106 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4106[1] { - yym4111 := z.EncBinary() - _ = yym4111 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -51584,54 +62782,54 @@ func (x *LimitRangeList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4106[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4112 := z.EncBinary() - _ = yym4112 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4106 || yy2arr4106 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4106[2] { - yy4114 := &x.ListMeta - yym4115 := z.EncBinary() - _ = yym4115 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy4114) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy4114) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq4106[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4116 := &x.ListMeta - yym4117 := z.EncBinary() - _ = yym4117 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy4116) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy4116) + z.EncFallback(yy12) } } } - if yyr4106 || yy2arr4106 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym4119 := z.EncBinary() - _ = yym4119 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceLimitRange(([]LimitRange)(x.Items), e) @@ -51644,15 +62842,15 @@ func (x *LimitRangeList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym4120 := z.EncBinary() - _ = yym4120 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceLimitRange(([]LimitRange)(x.Items), e) } } } - if yyr4106 || yy2arr4106 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -51665,25 +62863,25 @@ func (x *LimitRangeList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4121 := z.DecBinary() - _ = yym4121 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4122 := r.ContainerType() - if yyct4122 == codecSelferValueTypeMap1234 { - yyl4122 := r.ReadMapStart() - if yyl4122 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4122, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4122 == codecSelferValueTypeArray1234 { - yyl4122 := r.ReadArrayStart() - if yyl4122 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4122, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -51695,12 +62893,12 @@ func (x *LimitRangeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4123Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4123Slc - var yyhl4123 bool = l >= 0 - for yyj4123 := 0; ; yyj4123++ { - if yyhl4123 { - if yyj4123 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -51709,51 +62907,63 @@ func (x *LimitRangeList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4123Slc = r.DecodeBytes(yys4123Slc, true, true) - yys4123 := string(yys4123Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4123 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4126 := &x.ListMeta - yym4127 := z.DecBinary() - _ = yym4127 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv4126) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv4126, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4128 := &x.Items - yym4129 := z.DecBinary() - _ = yym4129 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceLimitRange((*[]LimitRange)(yyv4128), d) + h.decSliceLimitRange((*[]LimitRange)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4123) - } // end switch yys4123 - } // end for yyj4123 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -51761,16 +62971,16 @@ func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4130 int - var yyb4130 bool - var yyhl4130 bool = l >= 0 - yyj4130++ - if yyhl4130 { - yyb4130 = yyj4130 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4130 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4130 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51778,15 +62988,21 @@ func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4130++ - if yyhl4130 { - yyb4130 = yyj4130 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4130 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4130 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51794,38 +63010,44 @@ func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4130++ - if yyhl4130 { - yyb4130 = yyj4130 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4130 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4130 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4133 := &x.ListMeta - yym4134 := z.DecBinary() - _ = yym4134 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4133) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4133, false) + z.DecFallback(yyv17, false) } } - yyj4130++ - if yyhl4130 { - yyb4130 = yyj4130 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4130 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4130 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -51833,26 +63055,26 @@ func (x *LimitRangeList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4135 := &x.Items - yym4136 := z.DecBinary() - _ = yym4136 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceLimitRange((*[]LimitRange)(yyv4135), d) + h.decSliceLimitRange((*[]LimitRange)(yyv19), d) } } for { - yyj4130++ - if yyhl4130 { - yyb4130 = yyj4130 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4130 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4130 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4130-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -51861,8 +63083,8 @@ func (x ResourceQuotaScope) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym4137 := z.EncBinary() - _ = yym4137 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -51874,8 +63096,8 @@ func (x *ResourceQuotaScope) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4138 := z.DecBinary() - _ = yym4138 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -51890,34 +63112,34 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4139 := z.EncBinary() - _ = yym4139 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4140 := !z.EncBinary() - yy2arr4140 := z.EncBasicHandle().StructToArray - var yyq4140 [2]bool - _, _, _ = yysep4140, yyq4140, yy2arr4140 - const yyr4140 bool = false - yyq4140[0] = len(x.Hard) != 0 - yyq4140[1] = len(x.Scopes) != 0 - var yynn4140 int - if yyr4140 || yy2arr4140 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Hard) != 0 + yyq2[1] = len(x.Scopes) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn4140 = 0 - for _, b := range yyq4140 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4140++ + yynn2++ } } - r.EncodeMapStart(yynn4140) - yynn4140 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4140 || yy2arr4140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4140[0] { + if yyq2[0] { if x.Hard == nil { r.EncodeNil() } else { @@ -51927,7 +63149,7 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4140[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hard")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -51938,14 +63160,14 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4140 || yy2arr4140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4140[1] { + if yyq2[1] { if x.Scopes == nil { r.EncodeNil() } else { - yym4143 := z.EncBinary() - _ = yym4143 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e) @@ -51955,15 +63177,15 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4140[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("scopes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Scopes == nil { r.EncodeNil() } else { - yym4144 := z.EncBinary() - _ = yym4144 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceResourceQuotaScope(([]ResourceQuotaScope)(x.Scopes), e) @@ -51971,7 +63193,7 @@ func (x *ResourceQuotaSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4140 || yy2arr4140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -51984,25 +63206,25 @@ func (x *ResourceQuotaSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4145 := z.DecBinary() - _ = yym4145 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4146 := r.ContainerType() - if yyct4146 == codecSelferValueTypeMap1234 { - yyl4146 := r.ReadMapStart() - if yyl4146 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4146, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4146 == codecSelferValueTypeArray1234 { - yyl4146 := r.ReadArrayStart() - if yyl4146 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4146, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -52014,12 +63236,12 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4147Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4147Slc - var yyhl4147 bool = l >= 0 - for yyj4147 := 0; ; yyj4147++ { - if yyhl4147 { - if yyj4147 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -52028,33 +63250,33 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4147Slc = r.DecodeBytes(yys4147Slc, true, true) - yys4147 := string(yys4147Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4147 { + switch yys3 { case "hard": if r.TryDecodeAsNil() { x.Hard = nil } else { - yyv4148 := &x.Hard - yyv4148.CodecDecodeSelf(d) + yyv4 := &x.Hard + yyv4.CodecDecodeSelf(d) } case "scopes": if r.TryDecodeAsNil() { x.Scopes = nil } else { - yyv4149 := &x.Scopes - yym4150 := z.DecBinary() - _ = yym4150 + yyv5 := &x.Scopes + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv4149), d) + h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv5), d) } } default: - z.DecStructFieldNotFound(-1, yys4147) - } // end switch yys4147 - } // end for yyj4147 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -52062,16 +63284,16 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4151 int - var yyb4151 bool - var yyhl4151 bool = l >= 0 - yyj4151++ - if yyhl4151 { - yyb4151 = yyj4151 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb4151 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb4151 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52079,16 +63301,16 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Hard = nil } else { - yyv4152 := &x.Hard - yyv4152.CodecDecodeSelf(d) + yyv8 := &x.Hard + yyv8.CodecDecodeSelf(d) } - yyj4151++ - if yyhl4151 { - yyb4151 = yyj4151 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb4151 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb4151 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52096,26 +63318,26 @@ func (x *ResourceQuotaSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Scopes = nil } else { - yyv4153 := &x.Scopes - yym4154 := z.DecBinary() - _ = yym4154 + yyv9 := &x.Scopes + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv4153), d) + h.decSliceResourceQuotaScope((*[]ResourceQuotaScope)(yyv9), d) } } for { - yyj4151++ - if yyhl4151 { - yyb4151 = yyj4151 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb4151 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb4151 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4151-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -52127,34 +63349,34 @@ func (x *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4155 := z.EncBinary() - _ = yym4155 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4156 := !z.EncBinary() - yy2arr4156 := z.EncBasicHandle().StructToArray - var yyq4156 [2]bool - _, _, _ = yysep4156, yyq4156, yy2arr4156 - const yyr4156 bool = false - yyq4156[0] = len(x.Hard) != 0 - yyq4156[1] = len(x.Used) != 0 - var yynn4156 int - if yyr4156 || yy2arr4156 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Hard) != 0 + yyq2[1] = len(x.Used) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn4156 = 0 - for _, b := range yyq4156 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4156++ + yynn2++ } } - r.EncodeMapStart(yynn4156) - yynn4156 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4156 || yy2arr4156 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4156[0] { + if yyq2[0] { if x.Hard == nil { r.EncodeNil() } else { @@ -52164,7 +63386,7 @@ func (x *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4156[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hard")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -52175,9 +63397,9 @@ func (x *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4156 || yy2arr4156 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4156[1] { + if yyq2[1] { if x.Used == nil { r.EncodeNil() } else { @@ -52187,7 +63409,7 @@ func (x *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4156[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("used")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -52198,7 +63420,7 @@ func (x *ResourceQuotaStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4156 || yy2arr4156 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -52211,25 +63433,25 @@ func (x *ResourceQuotaStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4159 := z.DecBinary() - _ = yym4159 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4160 := r.ContainerType() - if yyct4160 == codecSelferValueTypeMap1234 { - yyl4160 := r.ReadMapStart() - if yyl4160 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4160, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4160 == codecSelferValueTypeArray1234 { - yyl4160 := r.ReadArrayStart() - if yyl4160 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4160, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -52241,12 +63463,12 @@ func (x *ResourceQuotaStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4161Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4161Slc - var yyhl4161 bool = l >= 0 - for yyj4161 := 0; ; yyj4161++ { - if yyhl4161 { - if yyj4161 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -52255,28 +63477,28 @@ func (x *ResourceQuotaStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4161Slc = r.DecodeBytes(yys4161Slc, true, true) - yys4161 := string(yys4161Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4161 { + switch yys3 { case "hard": if r.TryDecodeAsNil() { x.Hard = nil } else { - yyv4162 := &x.Hard - yyv4162.CodecDecodeSelf(d) + yyv4 := &x.Hard + yyv4.CodecDecodeSelf(d) } case "used": if r.TryDecodeAsNil() { x.Used = nil } else { - yyv4163 := &x.Used - yyv4163.CodecDecodeSelf(d) + yyv5 := &x.Used + yyv5.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys4161) - } // end switch yys4161 - } // end for yyj4161 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -52284,16 +63506,16 @@ func (x *ResourceQuotaStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4164 int - var yyb4164 bool - var yyhl4164 bool = l >= 0 - yyj4164++ - if yyhl4164 { - yyb4164 = yyj4164 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4164 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4164 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52301,16 +63523,16 @@ func (x *ResourceQuotaStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Hard = nil } else { - yyv4165 := &x.Hard - yyv4165.CodecDecodeSelf(d) + yyv7 := &x.Hard + yyv7.CodecDecodeSelf(d) } - yyj4164++ - if yyhl4164 { - yyb4164 = yyj4164 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4164 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4164 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52318,21 +63540,21 @@ func (x *ResourceQuotaStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Used = nil } else { - yyv4166 := &x.Used - yyv4166.CodecDecodeSelf(d) + yyv8 := &x.Used + yyv8.CodecDecodeSelf(d) } for { - yyj4164++ - if yyhl4164 { - yyb4164 = yyj4164 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4164 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4164 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4164-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -52344,39 +63566,39 @@ func (x *ResourceQuota) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4167 := z.EncBinary() - _ = yym4167 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4168 := !z.EncBinary() - yy2arr4168 := z.EncBasicHandle().StructToArray - var yyq4168 [5]bool - _, _, _ = yysep4168, yyq4168, yy2arr4168 - const yyr4168 bool = false - yyq4168[0] = x.Kind != "" - yyq4168[1] = x.APIVersion != "" - yyq4168[2] = true - yyq4168[3] = true - yyq4168[4] = true - var yynn4168 int - if yyr4168 || yy2arr4168 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn4168 = 0 - for _, b := range yyq4168 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4168++ + yynn2++ } } - r.EncodeMapStart(yynn4168) - yynn4168 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4168 || yy2arr4168 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4168[0] { - yym4170 := z.EncBinary() - _ = yym4170 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -52385,23 +63607,23 @@ func (x *ResourceQuota) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4168[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4171 := z.EncBinary() - _ = yym4171 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4168 || yy2arr4168 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4168[1] { - yym4173 := z.EncBinary() - _ = yym4173 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -52410,70 +63632,82 @@ func (x *ResourceQuota) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4168[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4174 := z.EncBinary() - _ = yym4174 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4168 || yy2arr4168 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4168[2] { - yy4176 := &x.ObjectMeta - yy4176.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq4168[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4177 := &x.ObjectMeta - yy4177.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr4168 || yy2arr4168 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4168[3] { - yy4179 := &x.Spec - yy4179.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq4168[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4180 := &x.Spec - yy4180.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr4168 || yy2arr4168 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4168[4] { - yy4182 := &x.Status - yy4182.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq4168[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4183 := &x.Status - yy4183.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr4168 || yy2arr4168 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -52486,25 +63720,25 @@ func (x *ResourceQuota) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4184 := z.DecBinary() - _ = yym4184 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4185 := r.ContainerType() - if yyct4185 == codecSelferValueTypeMap1234 { - yyl4185 := r.ReadMapStart() - if yyl4185 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4185, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4185 == codecSelferValueTypeArray1234 { - yyl4185 := r.ReadArrayStart() - if yyl4185 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4185, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -52516,12 +63750,12 @@ func (x *ResourceQuota) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4186Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4186Slc - var yyhl4186 bool = l >= 0 - for yyj4186 := 0; ; yyj4186++ { - if yyhl4186 { - if yyj4186 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -52530,47 +63764,65 @@ func (x *ResourceQuota) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4186Slc = r.DecodeBytes(yys4186Slc, true, true) - yys4186 := string(yys4186Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4186 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4189 := &x.ObjectMeta - yyv4189.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = ResourceQuotaSpec{} } else { - yyv4190 := &x.Spec - yyv4190.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = ResourceQuotaStatus{} } else { - yyv4191 := &x.Status - yyv4191.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys4186) - } // end switch yys4186 - } // end for yyj4186 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -52578,16 +63830,16 @@ func (x *ResourceQuota) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4192 int - var yyb4192 bool - var yyhl4192 bool = l >= 0 - yyj4192++ - if yyhl4192 { - yyb4192 = yyj4192 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4192 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4192 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52595,15 +63847,21 @@ func (x *ResourceQuota) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4192++ - if yyhl4192 { - yyb4192 = yyj4192 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4192 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4192 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52611,32 +63869,44 @@ func (x *ResourceQuota) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4192++ - if yyhl4192 { - yyb4192 = yyj4192 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4192 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4192 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4195 := &x.ObjectMeta - yyv4195.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj4192++ - if yyhl4192 { - yyb4192 = yyj4192 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4192 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4192 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52644,16 +63914,16 @@ func (x *ResourceQuota) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = ResourceQuotaSpec{} } else { - yyv4196 := &x.Spec - yyv4196.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj4192++ - if yyhl4192 { - yyb4192 = yyj4192 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4192 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4192 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52661,21 +63931,21 @@ func (x *ResourceQuota) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = ResourceQuotaStatus{} } else { - yyv4197 := &x.Status - yyv4197.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj4192++ - if yyhl4192 { - yyb4192 = yyj4192 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4192 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4192 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4192-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -52687,37 +63957,37 @@ func (x *ResourceQuotaList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4198 := z.EncBinary() - _ = yym4198 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4199 := !z.EncBinary() - yy2arr4199 := z.EncBasicHandle().StructToArray - var yyq4199 [4]bool - _, _, _ = yysep4199, yyq4199, yy2arr4199 - const yyr4199 bool = false - yyq4199[0] = x.Kind != "" - yyq4199[1] = x.APIVersion != "" - yyq4199[2] = true - var yynn4199 int - if yyr4199 || yy2arr4199 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4199 = 1 - for _, b := range yyq4199 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4199++ + yynn2++ } } - r.EncodeMapStart(yynn4199) - yynn4199 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4199 || yy2arr4199 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4199[0] { - yym4201 := z.EncBinary() - _ = yym4201 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -52726,23 +63996,23 @@ func (x *ResourceQuotaList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4199[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4202 := z.EncBinary() - _ = yym4202 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4199 || yy2arr4199 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4199[1] { - yym4204 := z.EncBinary() - _ = yym4204 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -52751,54 +64021,54 @@ func (x *ResourceQuotaList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4199[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4205 := z.EncBinary() - _ = yym4205 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4199 || yy2arr4199 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4199[2] { - yy4207 := &x.ListMeta - yym4208 := z.EncBinary() - _ = yym4208 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy4207) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy4207) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq4199[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4209 := &x.ListMeta - yym4210 := z.EncBinary() - _ = yym4210 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy4209) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy4209) + z.EncFallback(yy12) } } } - if yyr4199 || yy2arr4199 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym4212 := z.EncBinary() - _ = yym4212 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceResourceQuota(([]ResourceQuota)(x.Items), e) @@ -52811,15 +64081,15 @@ func (x *ResourceQuotaList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym4213 := z.EncBinary() - _ = yym4213 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceResourceQuota(([]ResourceQuota)(x.Items), e) } } } - if yyr4199 || yy2arr4199 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -52832,25 +64102,25 @@ func (x *ResourceQuotaList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4214 := z.DecBinary() - _ = yym4214 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4215 := r.ContainerType() - if yyct4215 == codecSelferValueTypeMap1234 { - yyl4215 := r.ReadMapStart() - if yyl4215 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4215, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4215 == codecSelferValueTypeArray1234 { - yyl4215 := r.ReadArrayStart() - if yyl4215 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4215, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -52862,12 +64132,12 @@ func (x *ResourceQuotaList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4216Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4216Slc - var yyhl4216 bool = l >= 0 - for yyj4216 := 0; ; yyj4216++ { - if yyhl4216 { - if yyj4216 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -52876,51 +64146,63 @@ func (x *ResourceQuotaList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4216Slc = r.DecodeBytes(yys4216Slc, true, true) - yys4216 := string(yys4216Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4216 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4219 := &x.ListMeta - yym4220 := z.DecBinary() - _ = yym4220 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv4219) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv4219, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4221 := &x.Items - yym4222 := z.DecBinary() - _ = yym4222 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceResourceQuota((*[]ResourceQuota)(yyv4221), d) + h.decSliceResourceQuota((*[]ResourceQuota)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4216) - } // end switch yys4216 - } // end for yyj4216 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -52928,16 +64210,16 @@ func (x *ResourceQuotaList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4223 int - var yyb4223 bool - var yyhl4223 bool = l >= 0 - yyj4223++ - if yyhl4223 { - yyb4223 = yyj4223 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4223 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4223 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52945,15 +64227,21 @@ func (x *ResourceQuotaList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4223++ - if yyhl4223 { - yyb4223 = yyj4223 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4223 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4223 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -52961,38 +64249,44 @@ func (x *ResourceQuotaList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4223++ - if yyhl4223 { - yyb4223 = yyj4223 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4223 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4223 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4226 := &x.ListMeta - yym4227 := z.DecBinary() - _ = yym4227 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4226) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4226, false) + z.DecFallback(yyv17, false) } } - yyj4223++ - if yyhl4223 { - yyb4223 = yyj4223 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4223 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4223 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53000,26 +64294,26 @@ func (x *ResourceQuotaList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4228 := &x.Items - yym4229 := z.DecBinary() - _ = yym4229 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceResourceQuota((*[]ResourceQuota)(yyv4228), d) + h.decSliceResourceQuota((*[]ResourceQuota)(yyv19), d) } } for { - yyj4223++ - if yyhl4223 { - yyb4223 = yyj4223 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4223 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4223 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4223-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -53031,40 +64325,40 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4230 := z.EncBinary() - _ = yym4230 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4231 := !z.EncBinary() - yy2arr4231 := z.EncBasicHandle().StructToArray - var yyq4231 [6]bool - _, _, _ = yysep4231, yyq4231, yy2arr4231 - const yyr4231 bool = false - yyq4231[0] = x.Kind != "" - yyq4231[1] = x.APIVersion != "" - yyq4231[2] = true - yyq4231[3] = len(x.Data) != 0 - yyq4231[4] = len(x.StringData) != 0 - yyq4231[5] = x.Type != "" - var yynn4231 int - if yyr4231 || yy2arr4231 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Data) != 0 + yyq2[4] = len(x.StringData) != 0 + yyq2[5] = x.Type != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn4231 = 0 - for _, b := range yyq4231 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4231++ + yynn2++ } } - r.EncodeMapStart(yynn4231) - yynn4231 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4231[0] { - yym4233 := z.EncBinary() - _ = yym4233 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -53073,23 +64367,23 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4231[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4234 := z.EncBinary() - _ = yym4234 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4231[1] { - yym4236 := z.EncBinary() - _ = yym4236 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -53098,43 +64392,55 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4231[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4237 := z.EncBinary() - _ = yym4237 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4231[2] { - yy4239 := &x.ObjectMeta - yy4239.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq4231[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4240 := &x.ObjectMeta - yy4240.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4231[3] { + if yyq2[3] { if x.Data == nil { r.EncodeNil() } else { - yym4242 := z.EncBinary() - _ = yym4242 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e) @@ -53144,15 +64450,15 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4231[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("data")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Data == nil { r.EncodeNil() } else { - yym4243 := z.EncBinary() - _ = yym4243 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encMapstringSliceuint8((map[string][]uint8)(x.Data), e) @@ -53160,14 +64466,14 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4231[4] { + if yyq2[4] { if x.StringData == nil { r.EncodeNil() } else { - yym4245 := z.EncBinary() - _ = yym4245 + yym18 := z.EncBinary() + _ = yym18 if false { } else { z.F.EncMapStringStringV(x.StringData, false, e) @@ -53177,15 +64483,15 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4231[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("stringData")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.StringData == nil { r.EncodeNil() } else { - yym4246 := z.EncBinary() - _ = yym4246 + yym19 := z.EncBinary() + _ = yym19 if false { } else { z.F.EncMapStringStringV(x.StringData, false, e) @@ -53193,22 +64499,22 @@ func (x *Secret) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4231[5] { + if yyq2[5] { x.Type.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4231[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } } - if yyr4231 || yy2arr4231 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -53221,25 +64527,25 @@ func (x *Secret) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4248 := z.DecBinary() - _ = yym4248 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4249 := r.ContainerType() - if yyct4249 == codecSelferValueTypeMap1234 { - yyl4249 := r.ReadMapStart() - if yyl4249 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4249, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4249 == codecSelferValueTypeArray1234 { - yyl4249 := r.ReadArrayStart() - if yyl4249 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4249, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -53251,12 +64557,12 @@ func (x *Secret) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4250Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4250Slc - var yyhl4250 bool = l >= 0 - for yyj4250 := 0; ; yyj4250++ { - if yyhl4250 { - if yyj4250 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -53265,63 +64571,82 @@ func (x *Secret) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4250Slc = r.DecodeBytes(yys4250Slc, true, true) - yys4250 := string(yys4250Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4250 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4253 := &x.ObjectMeta - yyv4253.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "data": if r.TryDecodeAsNil() { x.Data = nil } else { - yyv4254 := &x.Data - yym4255 := z.DecBinary() - _ = yym4255 + yyv10 := &x.Data + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decMapstringSliceuint8((*map[string][]uint8)(yyv4254), d) + h.decMapstringSliceuint8((*map[string][]uint8)(yyv10), d) } } case "stringData": if r.TryDecodeAsNil() { x.StringData = nil } else { - yyv4256 := &x.StringData - yym4257 := z.DecBinary() - _ = yym4257 + yyv12 := &x.StringData + yym13 := z.DecBinary() + _ = yym13 if false { } else { - z.F.DecMapStringStringX(yyv4256, false, d) + z.F.DecMapStringStringX(yyv12, false, d) } } case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = SecretType(r.DecodeString()) + yyv14 := &x.Type + yyv14.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys4250) - } // end switch yys4250 - } // end for yyj4250 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -53329,16 +64654,16 @@ func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4259 int - var yyb4259 bool - var yyhl4259 bool = l >= 0 - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53346,15 +64671,21 @@ func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv16 := &x.Kind + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53362,32 +64693,44 @@ func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv18 := &x.APIVersion + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } } - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4262 := &x.ObjectMeta - yyv4262.CodecDecodeSelf(d) + yyv20 := &x.ObjectMeta + yym21 := z.DecBinary() + _ = yym21 + if false { + } else if z.HasExtensions() && z.DecExt(yyv20) { + } else { + z.DecFallback(yyv20, false) + } } - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53395,21 +64738,21 @@ func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Data = nil } else { - yyv4263 := &x.Data - yym4264 := z.DecBinary() - _ = yym4264 + yyv22 := &x.Data + yym23 := z.DecBinary() + _ = yym23 if false { } else { - h.decMapstringSliceuint8((*map[string][]uint8)(yyv4263), d) + h.decMapstringSliceuint8((*map[string][]uint8)(yyv22), d) } } - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53417,21 +64760,21 @@ func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.StringData = nil } else { - yyv4265 := &x.StringData - yym4266 := z.DecBinary() - _ = yym4266 + yyv24 := &x.StringData + yym25 := z.DecBinary() + _ = yym25 if false { } else { - z.F.DecMapStringStringX(yyv4265, false, d) + z.F.DecMapStringStringX(yyv24, false, d) } } - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53439,20 +64782,21 @@ func (x *Secret) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = SecretType(r.DecodeString()) + yyv26 := &x.Type + yyv26.CodecDecodeSelf(d) } for { - yyj4259++ - if yyhl4259 { - yyb4259 = yyj4259 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb4259 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb4259 { + if yyb15 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4259-1, "") + z.DecStructFieldNotFound(yyj15-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -53461,8 +64805,8 @@ func (x SecretType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym4268 := z.EncBinary() - _ = yym4268 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -53474,8 +64818,8 @@ func (x *SecretType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4269 := z.DecBinary() - _ = yym4269 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -53490,37 +64834,37 @@ func (x *SecretList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4270 := z.EncBinary() - _ = yym4270 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4271 := !z.EncBinary() - yy2arr4271 := z.EncBasicHandle().StructToArray - var yyq4271 [4]bool - _, _, _ = yysep4271, yyq4271, yy2arr4271 - const yyr4271 bool = false - yyq4271[0] = x.Kind != "" - yyq4271[1] = x.APIVersion != "" - yyq4271[2] = true - var yynn4271 int - if yyr4271 || yy2arr4271 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4271 = 1 - for _, b := range yyq4271 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4271++ + yynn2++ } } - r.EncodeMapStart(yynn4271) - yynn4271 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4271 || yy2arr4271 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4271[0] { - yym4273 := z.EncBinary() - _ = yym4273 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -53529,23 +64873,23 @@ func (x *SecretList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4271[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4274 := z.EncBinary() - _ = yym4274 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4271 || yy2arr4271 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4271[1] { - yym4276 := z.EncBinary() - _ = yym4276 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -53554,54 +64898,54 @@ func (x *SecretList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4271[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4277 := z.EncBinary() - _ = yym4277 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4271 || yy2arr4271 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4271[2] { - yy4279 := &x.ListMeta - yym4280 := z.EncBinary() - _ = yym4280 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy4279) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy4279) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq4271[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4281 := &x.ListMeta - yym4282 := z.EncBinary() - _ = yym4282 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy4281) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy4281) + z.EncFallback(yy12) } } } - if yyr4271 || yy2arr4271 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym4284 := z.EncBinary() - _ = yym4284 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceSecret(([]Secret)(x.Items), e) @@ -53614,15 +64958,15 @@ func (x *SecretList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym4285 := z.EncBinary() - _ = yym4285 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceSecret(([]Secret)(x.Items), e) } } } - if yyr4271 || yy2arr4271 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -53635,25 +64979,25 @@ func (x *SecretList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4286 := z.DecBinary() - _ = yym4286 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4287 := r.ContainerType() - if yyct4287 == codecSelferValueTypeMap1234 { - yyl4287 := r.ReadMapStart() - if yyl4287 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4287, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4287 == codecSelferValueTypeArray1234 { - yyl4287 := r.ReadArrayStart() - if yyl4287 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4287, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -53665,12 +65009,12 @@ func (x *SecretList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4288Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4288Slc - var yyhl4288 bool = l >= 0 - for yyj4288 := 0; ; yyj4288++ { - if yyhl4288 { - if yyj4288 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -53679,51 +65023,63 @@ func (x *SecretList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4288Slc = r.DecodeBytes(yys4288Slc, true, true) - yys4288 := string(yys4288Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4288 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4291 := &x.ListMeta - yym4292 := z.DecBinary() - _ = yym4292 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv4291) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv4291, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4293 := &x.Items - yym4294 := z.DecBinary() - _ = yym4294 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceSecret((*[]Secret)(yyv4293), d) + h.decSliceSecret((*[]Secret)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4288) - } // end switch yys4288 - } // end for yyj4288 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -53731,16 +65087,16 @@ func (x *SecretList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4295 int - var yyb4295 bool - var yyhl4295 bool = l >= 0 - yyj4295++ - if yyhl4295 { - yyb4295 = yyj4295 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4295 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4295 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53748,15 +65104,21 @@ func (x *SecretList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4295++ - if yyhl4295 { - yyb4295 = yyj4295 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4295 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4295 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53764,38 +65126,44 @@ func (x *SecretList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4295++ - if yyhl4295 { - yyb4295 = yyj4295 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4295 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4295 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4298 := &x.ListMeta - yym4299 := z.DecBinary() - _ = yym4299 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4298) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4298, false) + z.DecFallback(yyv17, false) } } - yyj4295++ - if yyhl4295 { - yyb4295 = yyj4295 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4295 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4295 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -53803,26 +65171,26 @@ func (x *SecretList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4300 := &x.Items - yym4301 := z.DecBinary() - _ = yym4301 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceSecret((*[]Secret)(yyv4300), d) + h.decSliceSecret((*[]Secret)(yyv19), d) } } for { - yyj4295++ - if yyhl4295 { - yyb4295 = yyj4295 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4295 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4295 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4295-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -53834,38 +65202,38 @@ func (x *ConfigMap) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4302 := z.EncBinary() - _ = yym4302 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4303 := !z.EncBinary() - yy2arr4303 := z.EncBasicHandle().StructToArray - var yyq4303 [4]bool - _, _, _ = yysep4303, yyq4303, yy2arr4303 - const yyr4303 bool = false - yyq4303[0] = x.Kind != "" - yyq4303[1] = x.APIVersion != "" - yyq4303[2] = true - yyq4303[3] = len(x.Data) != 0 - var yynn4303 int - if yyr4303 || yy2arr4303 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Data) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4303 = 0 - for _, b := range yyq4303 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4303++ + yynn2++ } } - r.EncodeMapStart(yynn4303) - yynn4303 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4303 || yy2arr4303 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4303[0] { - yym4305 := z.EncBinary() - _ = yym4305 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -53874,23 +65242,23 @@ func (x *ConfigMap) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4303[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4306 := z.EncBinary() - _ = yym4306 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4303 || yy2arr4303 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4303[1] { - yym4308 := z.EncBinary() - _ = yym4308 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -53899,43 +65267,55 @@ func (x *ConfigMap) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4303[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4309 := z.EncBinary() - _ = yym4309 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4303 || yy2arr4303 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4303[2] { - yy4311 := &x.ObjectMeta - yy4311.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq4303[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4312 := &x.ObjectMeta - yy4312.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr4303 || yy2arr4303 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4303[3] { + if yyq2[3] { if x.Data == nil { r.EncodeNil() } else { - yym4314 := z.EncBinary() - _ = yym4314 + yym15 := z.EncBinary() + _ = yym15 if false { } else { z.F.EncMapStringStringV(x.Data, false, e) @@ -53945,15 +65325,15 @@ func (x *ConfigMap) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4303[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("data")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Data == nil { r.EncodeNil() } else { - yym4315 := z.EncBinary() - _ = yym4315 + yym16 := z.EncBinary() + _ = yym16 if false { } else { z.F.EncMapStringStringV(x.Data, false, e) @@ -53961,7 +65341,7 @@ func (x *ConfigMap) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4303 || yy2arr4303 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -53974,25 +65354,25 @@ func (x *ConfigMap) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4316 := z.DecBinary() - _ = yym4316 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4317 := r.ContainerType() - if yyct4317 == codecSelferValueTypeMap1234 { - yyl4317 := r.ReadMapStart() - if yyl4317 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4317, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4317 == codecSelferValueTypeArray1234 { - yyl4317 := r.ReadArrayStart() - if yyl4317 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4317, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -54004,12 +65384,12 @@ func (x *ConfigMap) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4318Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4318Slc - var yyhl4318 bool = l >= 0 - for yyj4318 := 0; ; yyj4318++ { - if yyhl4318 { - if yyj4318 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -54018,45 +65398,63 @@ func (x *ConfigMap) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4318Slc = r.DecodeBytes(yys4318Slc, true, true) - yys4318 := string(yys4318Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4318 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4321 := &x.ObjectMeta - yyv4321.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "data": if r.TryDecodeAsNil() { x.Data = nil } else { - yyv4322 := &x.Data - yym4323 := z.DecBinary() - _ = yym4323 + yyv10 := &x.Data + yym11 := z.DecBinary() + _ = yym11 if false { } else { - z.F.DecMapStringStringX(yyv4322, false, d) + z.F.DecMapStringStringX(yyv10, false, d) } } default: - z.DecStructFieldNotFound(-1, yys4318) - } // end switch yys4318 - } // end for yyj4318 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -54064,16 +65462,16 @@ func (x *ConfigMap) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4324 int - var yyb4324 bool - var yyhl4324 bool = l >= 0 - yyj4324++ - if yyhl4324 { - yyb4324 = yyj4324 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4324 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4324 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54081,15 +65479,21 @@ func (x *ConfigMap) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4324++ - if yyhl4324 { - yyb4324 = yyj4324 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4324 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4324 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54097,32 +65501,44 @@ func (x *ConfigMap) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4324++ - if yyhl4324 { - yyb4324 = yyj4324 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4324 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4324 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4327 := &x.ObjectMeta - yyv4327.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj4324++ - if yyhl4324 { - yyb4324 = yyj4324 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4324 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4324 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54130,26 +65546,26 @@ func (x *ConfigMap) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Data = nil } else { - yyv4328 := &x.Data - yym4329 := z.DecBinary() - _ = yym4329 + yyv19 := &x.Data + yym20 := z.DecBinary() + _ = yym20 if false { } else { - z.F.DecMapStringStringX(yyv4328, false, d) + z.F.DecMapStringStringX(yyv19, false, d) } } for { - yyj4324++ - if yyhl4324 { - yyb4324 = yyj4324 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4324 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4324 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4324-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -54161,37 +65577,37 @@ func (x *ConfigMapList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4330 := z.EncBinary() - _ = yym4330 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4331 := !z.EncBinary() - yy2arr4331 := z.EncBasicHandle().StructToArray - var yyq4331 [4]bool - _, _, _ = yysep4331, yyq4331, yy2arr4331 - const yyr4331 bool = false - yyq4331[0] = x.Kind != "" - yyq4331[1] = x.APIVersion != "" - yyq4331[2] = true - var yynn4331 int - if yyr4331 || yy2arr4331 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4331 = 1 - for _, b := range yyq4331 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4331++ + yynn2++ } } - r.EncodeMapStart(yynn4331) - yynn4331 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4331 || yy2arr4331 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4331[0] { - yym4333 := z.EncBinary() - _ = yym4333 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -54200,23 +65616,23 @@ func (x *ConfigMapList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4331[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4334 := z.EncBinary() - _ = yym4334 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4331 || yy2arr4331 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4331[1] { - yym4336 := z.EncBinary() - _ = yym4336 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -54225,54 +65641,54 @@ func (x *ConfigMapList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4331[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4337 := z.EncBinary() - _ = yym4337 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4331 || yy2arr4331 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4331[2] { - yy4339 := &x.ListMeta - yym4340 := z.EncBinary() - _ = yym4340 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy4339) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy4339) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq4331[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4341 := &x.ListMeta - yym4342 := z.EncBinary() - _ = yym4342 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy4341) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy4341) + z.EncFallback(yy12) } } } - if yyr4331 || yy2arr4331 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym4344 := z.EncBinary() - _ = yym4344 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceConfigMap(([]ConfigMap)(x.Items), e) @@ -54285,15 +65701,15 @@ func (x *ConfigMapList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym4345 := z.EncBinary() - _ = yym4345 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceConfigMap(([]ConfigMap)(x.Items), e) } } } - if yyr4331 || yy2arr4331 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -54306,25 +65722,25 @@ func (x *ConfigMapList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4346 := z.DecBinary() - _ = yym4346 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4347 := r.ContainerType() - if yyct4347 == codecSelferValueTypeMap1234 { - yyl4347 := r.ReadMapStart() - if yyl4347 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4347, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4347 == codecSelferValueTypeArray1234 { - yyl4347 := r.ReadArrayStart() - if yyl4347 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4347, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -54336,12 +65752,12 @@ func (x *ConfigMapList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4348Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4348Slc - var yyhl4348 bool = l >= 0 - for yyj4348 := 0; ; yyj4348++ { - if yyhl4348 { - if yyj4348 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -54350,51 +65766,63 @@ func (x *ConfigMapList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4348Slc = r.DecodeBytes(yys4348Slc, true, true) - yys4348 := string(yys4348Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4348 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4351 := &x.ListMeta - yym4352 := z.DecBinary() - _ = yym4352 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv4351) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv4351, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4353 := &x.Items - yym4354 := z.DecBinary() - _ = yym4354 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceConfigMap((*[]ConfigMap)(yyv4353), d) + h.decSliceConfigMap((*[]ConfigMap)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4348) - } // end switch yys4348 - } // end for yyj4348 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -54402,16 +65830,16 @@ func (x *ConfigMapList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4355 int - var yyb4355 bool - var yyhl4355 bool = l >= 0 - yyj4355++ - if yyhl4355 { - yyb4355 = yyj4355 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4355 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4355 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54419,15 +65847,21 @@ func (x *ConfigMapList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4355++ - if yyhl4355 { - yyb4355 = yyj4355 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4355 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4355 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54435,38 +65869,44 @@ func (x *ConfigMapList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4355++ - if yyhl4355 { - yyb4355 = yyj4355 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4355 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4355 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4358 := &x.ListMeta - yym4359 := z.DecBinary() - _ = yym4359 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4358) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4358, false) + z.DecFallback(yyv17, false) } } - yyj4355++ - if yyhl4355 { - yyb4355 = yyj4355 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4355 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4355 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54474,26 +65914,26 @@ func (x *ConfigMapList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4360 := &x.Items - yym4361 := z.DecBinary() - _ = yym4361 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceConfigMap((*[]ConfigMap)(yyv4360), d) + h.decSliceConfigMap((*[]ConfigMap)(yyv19), d) } } for { - yyj4355++ - if yyhl4355 { - yyb4355 = yyj4355 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4355 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4355 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4355-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -54502,8 +65942,8 @@ func (x ComponentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym4362 := z.EncBinary() - _ = yym4362 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -54515,8 +65955,8 @@ func (x *ComponentConditionType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4363 := z.DecBinary() - _ = yym4363 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -54531,32 +65971,32 @@ func (x *ComponentCondition) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4364 := z.EncBinary() - _ = yym4364 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4365 := !z.EncBinary() - yy2arr4365 := z.EncBasicHandle().StructToArray - var yyq4365 [4]bool - _, _, _ = yysep4365, yyq4365, yy2arr4365 - const yyr4365 bool = false - yyq4365[2] = x.Message != "" - yyq4365[3] = x.Error != "" - var yynn4365 int - if yyr4365 || yy2arr4365 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.Message != "" + yyq2[3] = x.Error != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4365 = 2 - for _, b := range yyq4365 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn4365++ + yynn2++ } } - r.EncodeMapStart(yynn4365) - yynn4365 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4365 || yy2arr4365 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -54565,7 +66005,7 @@ func (x *ComponentCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr4365 || yy2arr4365 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Status.CodecEncodeSelf(e) } else { @@ -54574,11 +66014,11 @@ func (x *ComponentCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Status.CodecEncodeSelf(e) } - if yyr4365 || yy2arr4365 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4365[2] { - yym4369 := z.EncBinary() - _ = yym4369 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -54587,23 +66027,23 @@ func (x *ComponentCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4365[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4370 := z.EncBinary() - _ = yym4370 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr4365 || yy2arr4365 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4365[3] { - yym4372 := z.EncBinary() - _ = yym4372 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Error)) @@ -54612,19 +66052,19 @@ func (x *ComponentCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4365[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("error")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4373 := z.EncBinary() - _ = yym4373 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Error)) } } } - if yyr4365 || yy2arr4365 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -54637,25 +66077,25 @@ func (x *ComponentCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4374 := z.DecBinary() - _ = yym4374 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4375 := r.ContainerType() - if yyct4375 == codecSelferValueTypeMap1234 { - yyl4375 := r.ReadMapStart() - if yyl4375 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4375, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4375 == codecSelferValueTypeArray1234 { - yyl4375 := r.ReadArrayStart() - if yyl4375 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4375, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -54667,12 +66107,12 @@ func (x *ComponentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4376Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4376Slc - var yyhl4376 bool = l >= 0 - for yyj4376 := 0; ; yyj4376++ { - if yyhl4376 { - if yyj4376 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -54681,38 +66121,52 @@ func (x *ComponentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4376Slc = r.DecodeBytes(yys4376Slc, true, true) - yys4376 := string(yys4376Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4376 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ComponentConditionType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv6 := &x.Message + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "error": if r.TryDecodeAsNil() { x.Error = "" } else { - x.Error = string(r.DecodeString()) + yyv8 := &x.Error + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys4376) - } // end switch yys4376 - } // end for yyj4376 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -54720,16 +66174,16 @@ func (x *ComponentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4381 int - var yyb4381 bool - var yyhl4381 bool = l >= 0 - yyj4381++ - if yyhl4381 { - yyb4381 = yyj4381 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4381 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4381 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54737,15 +66191,16 @@ func (x *ComponentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ComponentConditionType(r.DecodeString()) + yyv11 := &x.Type + yyv11.CodecDecodeSelf(d) } - yyj4381++ - if yyhl4381 { - yyb4381 = yyj4381 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4381 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4381 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54753,15 +66208,16 @@ func (x *ComponentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = ConditionStatus(r.DecodeString()) + yyv12 := &x.Status + yyv12.CodecDecodeSelf(d) } - yyj4381++ - if yyhl4381 { - yyb4381 = yyj4381 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4381 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4381 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54769,15 +66225,21 @@ func (x *ComponentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv13 := &x.Message + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4381++ - if yyhl4381 { - yyb4381 = yyj4381 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4381 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4381 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -54785,20 +66247,26 @@ func (x *ComponentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Error = "" } else { - x.Error = string(r.DecodeString()) + yyv15 := &x.Error + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj4381++ - if yyhl4381 { - yyb4381 = yyj4381 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb4381 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb4381 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4381-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -54810,38 +66278,38 @@ func (x *ComponentStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4386 := z.EncBinary() - _ = yym4386 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4387 := !z.EncBinary() - yy2arr4387 := z.EncBasicHandle().StructToArray - var yyq4387 [4]bool - _, _, _ = yysep4387, yyq4387, yy2arr4387 - const yyr4387 bool = false - yyq4387[0] = x.Kind != "" - yyq4387[1] = x.APIVersion != "" - yyq4387[2] = true - yyq4387[3] = len(x.Conditions) != 0 - var yynn4387 int - if yyr4387 || yy2arr4387 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Conditions) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4387 = 0 - for _, b := range yyq4387 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4387++ + yynn2++ } } - r.EncodeMapStart(yynn4387) - yynn4387 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4387 || yy2arr4387 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4387[0] { - yym4389 := z.EncBinary() - _ = yym4389 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -54850,23 +66318,23 @@ func (x *ComponentStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4387[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4390 := z.EncBinary() - _ = yym4390 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4387 || yy2arr4387 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4387[1] { - yym4392 := z.EncBinary() - _ = yym4392 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -54875,43 +66343,55 @@ func (x *ComponentStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4387[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4393 := z.EncBinary() - _ = yym4393 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4387 || yy2arr4387 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4387[2] { - yy4395 := &x.ObjectMeta - yy4395.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq4387[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4396 := &x.ObjectMeta - yy4396.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr4387 || yy2arr4387 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4387[3] { + if yyq2[3] { if x.Conditions == nil { r.EncodeNil() } else { - yym4398 := z.EncBinary() - _ = yym4398 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e) @@ -54921,15 +66401,15 @@ func (x *ComponentStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4387[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Conditions == nil { r.EncodeNil() } else { - yym4399 := z.EncBinary() - _ = yym4399 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceComponentCondition(([]ComponentCondition)(x.Conditions), e) @@ -54937,7 +66417,7 @@ func (x *ComponentStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4387 || yy2arr4387 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -54950,25 +66430,25 @@ func (x *ComponentStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4400 := z.DecBinary() - _ = yym4400 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4401 := r.ContainerType() - if yyct4401 == codecSelferValueTypeMap1234 { - yyl4401 := r.ReadMapStart() - if yyl4401 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4401, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4401 == codecSelferValueTypeArray1234 { - yyl4401 := r.ReadArrayStart() - if yyl4401 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4401, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -54980,12 +66460,12 @@ func (x *ComponentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4402Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4402Slc - var yyhl4402 bool = l >= 0 - for yyj4402 := 0; ; yyj4402++ { - if yyhl4402 { - if yyj4402 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -54994,45 +66474,63 @@ func (x *ComponentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4402Slc = r.DecodeBytes(yys4402Slc, true, true) - yys4402 := string(yys4402Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4402 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4405 := &x.ObjectMeta - yyv4405.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "conditions": if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv4406 := &x.Conditions - yym4407 := z.DecBinary() - _ = yym4407 + yyv10 := &x.Conditions + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceComponentCondition((*[]ComponentCondition)(yyv4406), d) + h.decSliceComponentCondition((*[]ComponentCondition)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4402) - } // end switch yys4402 - } // end for yyj4402 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -55040,16 +66538,16 @@ func (x *ComponentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4408 int - var yyb4408 bool - var yyhl4408 bool = l >= 0 - yyj4408++ - if yyhl4408 { - yyb4408 = yyj4408 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4408 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4408 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55057,15 +66555,21 @@ func (x *ComponentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4408++ - if yyhl4408 { - yyb4408 = yyj4408 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4408 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4408 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55073,32 +66577,44 @@ func (x *ComponentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4408++ - if yyhl4408 { - yyb4408 = yyj4408 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4408 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4408 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4411 := &x.ObjectMeta - yyv4411.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj4408++ - if yyhl4408 { - yyb4408 = yyj4408 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4408 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4408 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55106,26 +66622,26 @@ func (x *ComponentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv4412 := &x.Conditions - yym4413 := z.DecBinary() - _ = yym4413 + yyv19 := &x.Conditions + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceComponentCondition((*[]ComponentCondition)(yyv4412), d) + h.decSliceComponentCondition((*[]ComponentCondition)(yyv19), d) } } for { - yyj4408++ - if yyhl4408 { - yyb4408 = yyj4408 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4408 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4408 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4408-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -55137,37 +66653,37 @@ func (x *ComponentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4414 := z.EncBinary() - _ = yym4414 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4415 := !z.EncBinary() - yy2arr4415 := z.EncBasicHandle().StructToArray - var yyq4415 [4]bool - _, _, _ = yysep4415, yyq4415, yy2arr4415 - const yyr4415 bool = false - yyq4415[0] = x.Kind != "" - yyq4415[1] = x.APIVersion != "" - yyq4415[2] = true - var yynn4415 int - if yyr4415 || yy2arr4415 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4415 = 1 - for _, b := range yyq4415 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4415++ + yynn2++ } } - r.EncodeMapStart(yynn4415) - yynn4415 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4415 || yy2arr4415 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4415[0] { - yym4417 := z.EncBinary() - _ = yym4417 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -55176,23 +66692,23 @@ func (x *ComponentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4415[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4418 := z.EncBinary() - _ = yym4418 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4415 || yy2arr4415 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4415[1] { - yym4420 := z.EncBinary() - _ = yym4420 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -55201,54 +66717,54 @@ func (x *ComponentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4415[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4421 := z.EncBinary() - _ = yym4421 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4415 || yy2arr4415 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4415[2] { - yy4423 := &x.ListMeta - yym4424 := z.EncBinary() - _ = yym4424 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy4423) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy4423) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq4415[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4425 := &x.ListMeta - yym4426 := z.EncBinary() - _ = yym4426 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy4425) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy4425) + z.EncFallback(yy12) } } } - if yyr4415 || yy2arr4415 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym4428 := z.EncBinary() - _ = yym4428 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceComponentStatus(([]ComponentStatus)(x.Items), e) @@ -55261,15 +66777,15 @@ func (x *ComponentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym4429 := z.EncBinary() - _ = yym4429 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceComponentStatus(([]ComponentStatus)(x.Items), e) } } } - if yyr4415 || yy2arr4415 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -55282,25 +66798,25 @@ func (x *ComponentStatusList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4430 := z.DecBinary() - _ = yym4430 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4431 := r.ContainerType() - if yyct4431 == codecSelferValueTypeMap1234 { - yyl4431 := r.ReadMapStart() - if yyl4431 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4431, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4431 == codecSelferValueTypeArray1234 { - yyl4431 := r.ReadArrayStart() - if yyl4431 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4431, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -55312,12 +66828,12 @@ func (x *ComponentStatusList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4432Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4432Slc - var yyhl4432 bool = l >= 0 - for yyj4432 := 0; ; yyj4432++ { - if yyhl4432 { - if yyj4432 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -55326,51 +66842,63 @@ func (x *ComponentStatusList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4432Slc = r.DecodeBytes(yys4432Slc, true, true) - yys4432 := string(yys4432Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4432 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4435 := &x.ListMeta - yym4436 := z.DecBinary() - _ = yym4436 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv4435) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv4435, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4437 := &x.Items - yym4438 := z.DecBinary() - _ = yym4438 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceComponentStatus((*[]ComponentStatus)(yyv4437), d) + h.decSliceComponentStatus((*[]ComponentStatus)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys4432) - } // end switch yys4432 - } // end for yyj4432 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -55378,16 +66906,16 @@ func (x *ComponentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4439 int - var yyb4439 bool - var yyhl4439 bool = l >= 0 - yyj4439++ - if yyhl4439 { - yyb4439 = yyj4439 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4439 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4439 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55395,15 +66923,21 @@ func (x *ComponentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4439++ - if yyhl4439 { - yyb4439 = yyj4439 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4439 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4439 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55411,38 +66945,44 @@ func (x *ComponentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4439++ - if yyhl4439 { - yyb4439 = yyj4439 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4439 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4439 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv4442 := &x.ListMeta - yym4443 := z.DecBinary() - _ = yym4443 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv4442) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv4442, false) + z.DecFallback(yyv17, false) } } - yyj4439++ - if yyhl4439 { - yyb4439 = yyj4439 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4439 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4439 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55450,26 +66990,26 @@ func (x *ComponentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4444 := &x.Items - yym4445 := z.DecBinary() - _ = yym4445 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceComponentStatus((*[]ComponentStatus)(yyv4444), d) + h.decSliceComponentStatus((*[]ComponentStatus)(yyv19), d) } } for { - yyj4439++ - if yyhl4439 { - yyb4439 = yyj4439 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4439 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4439 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4439-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -55481,39 +67021,39 @@ func (x *DownwardAPIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4446 := z.EncBinary() - _ = yym4446 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4447 := !z.EncBinary() - yy2arr4447 := z.EncBasicHandle().StructToArray - var yyq4447 [2]bool - _, _, _ = yysep4447, yyq4447, yy2arr4447 - const yyr4447 bool = false - yyq4447[0] = len(x.Items) != 0 - yyq4447[1] = x.DefaultMode != nil - var yynn4447 int - if yyr4447 || yy2arr4447 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Items) != 0 + yyq2[1] = x.DefaultMode != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn4447 = 0 - for _, b := range yyq4447 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4447++ + yynn2++ } } - r.EncodeMapStart(yynn4447) - yynn4447 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4447 || yy2arr4447 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4447[0] { + if yyq2[0] { if x.Items == nil { r.EncodeNil() } else { - yym4449 := z.EncBinary() - _ = yym4449 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) @@ -55523,15 +67063,15 @@ func (x *DownwardAPIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4447[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("items")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Items == nil { r.EncodeNil() } else { - yym4450 := z.EncBinary() - _ = yym4450 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) @@ -55539,42 +67079,42 @@ func (x *DownwardAPIVolumeSource) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4447 || yy2arr4447 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4447[1] { + if yyq2[1] { if x.DefaultMode == nil { r.EncodeNil() } else { - yy4452 := *x.DefaultMode - yym4453 := z.EncBinary() - _ = yym4453 + yy7 := *x.DefaultMode + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeInt(int64(yy4452)) + r.EncodeInt(int64(yy7)) } } } else { r.EncodeNil() } } else { - if yyq4447[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("defaultMode")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.DefaultMode == nil { r.EncodeNil() } else { - yy4454 := *x.DefaultMode - yym4455 := z.EncBinary() - _ = yym4455 + yy9 := *x.DefaultMode + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeInt(int64(yy4454)) + r.EncodeInt(int64(yy9)) } } } } - if yyr4447 || yy2arr4447 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -55587,25 +67127,25 @@ func (x *DownwardAPIVolumeSource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4456 := z.DecBinary() - _ = yym4456 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4457 := r.ContainerType() - if yyct4457 == codecSelferValueTypeMap1234 { - yyl4457 := r.ReadMapStart() - if yyl4457 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4457, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4457 == codecSelferValueTypeArray1234 { - yyl4457 := r.ReadArrayStart() - if yyl4457 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4457, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -55617,12 +67157,12 @@ func (x *DownwardAPIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4458Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4458Slc - var yyhl4458 bool = l >= 0 - for yyj4458 := 0; ; yyj4458++ { - if yyhl4458 { - if yyj4458 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -55631,20 +67171,20 @@ func (x *DownwardAPIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4458Slc = r.DecodeBytes(yys4458Slc, true, true) - yys4458 := string(yys4458Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4458 { + switch yys3 { case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4459 := &x.Items - yym4460 := z.DecBinary() - _ = yym4460 + yyv4 := &x.Items + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4459), d) + h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4), d) } } case "defaultMode": @@ -55656,17 +67196,17 @@ func (x *DownwardAPIVolumeSource) codecDecodeSelfFromMap(l int, d *codec1978.Dec if x.DefaultMode == nil { x.DefaultMode = new(int32) } - yym4462 := z.DecBinary() - _ = yym4462 + yym7 := z.DecBinary() + _ = yym7 if false { } else { *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) } } default: - z.DecStructFieldNotFound(-1, yys4458) - } // end switch yys4458 - } // end for yyj4458 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -55674,16 +67214,16 @@ func (x *DownwardAPIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4463 int - var yyb4463 bool - var yyhl4463 bool = l >= 0 - yyj4463++ - if yyhl4463 { - yyb4463 = yyj4463 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb4463 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb4463 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55691,21 +67231,21 @@ func (x *DownwardAPIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Items = nil } else { - yyv4464 := &x.Items - yym4465 := z.DecBinary() - _ = yym4465 + yyv9 := &x.Items + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4464), d) + h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv9), d) } } - yyj4463++ - if yyhl4463 { - yyb4463 = yyj4463 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb4463 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb4463 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -55718,25 +67258,25 @@ func (x *DownwardAPIVolumeSource) codecDecodeSelfFromArray(l int, d *codec1978.D if x.DefaultMode == nil { x.DefaultMode = new(int32) } - yym4467 := z.DecBinary() - _ = yym4467 + yym12 := z.DecBinary() + _ = yym12 if false { } else { *((*int32)(x.DefaultMode)) = int32(r.DecodeInt(32)) } } for { - yyj4463++ - if yyhl4463 { - yyb4463 = yyj4463 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb4463 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb4463 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4463-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -55748,36 +67288,36 @@ func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4468 := z.EncBinary() - _ = yym4468 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4469 := !z.EncBinary() - yy2arr4469 := z.EncBasicHandle().StructToArray - var yyq4469 [4]bool - _, _, _ = yysep4469, yyq4469, yy2arr4469 - const yyr4469 bool = false - yyq4469[1] = x.FieldRef != nil - yyq4469[2] = x.ResourceFieldRef != nil - yyq4469[3] = x.Mode != nil - var yynn4469 int - if yyr4469 || yy2arr4469 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FieldRef != nil + yyq2[2] = x.ResourceFieldRef != nil + yyq2[3] = x.Mode != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4469 = 1 - for _, b := range yyq4469 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn4469++ + yynn2++ } } - r.EncodeMapStart(yynn4469) - yynn4469 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4469 || yy2arr4469 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym4471 := z.EncBinary() - _ = yym4471 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -55786,16 +67326,16 @@ func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4472 := z.EncBinary() - _ = yym4472 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } - if yyr4469 || yy2arr4469 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4469[1] { + if yyq2[1] { if x.FieldRef == nil { r.EncodeNil() } else { @@ -55805,7 +67345,7 @@ func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4469[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fieldRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -55816,9 +67356,9 @@ func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4469 || yy2arr4469 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4469[2] { + if yyq2[2] { if x.ResourceFieldRef == nil { r.EncodeNil() } else { @@ -55828,7 +67368,7 @@ func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4469[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resourceFieldRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -55839,42 +67379,42 @@ func (x *DownwardAPIVolumeFile) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4469 || yy2arr4469 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4469[3] { + if yyq2[3] { if x.Mode == nil { r.EncodeNil() } else { - yy4476 := *x.Mode - yym4477 := z.EncBinary() - _ = yym4477 + yy13 := *x.Mode + yym14 := z.EncBinary() + _ = yym14 if false { } else { - r.EncodeInt(int64(yy4476)) + r.EncodeInt(int64(yy13)) } } } else { r.EncodeNil() } } else { - if yyq4469[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("mode")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Mode == nil { r.EncodeNil() } else { - yy4478 := *x.Mode - yym4479 := z.EncBinary() - _ = yym4479 + yy15 := *x.Mode + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeInt(int64(yy4478)) + r.EncodeInt(int64(yy15)) } } } } - if yyr4469 || yy2arr4469 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -55887,25 +67427,25 @@ func (x *DownwardAPIVolumeFile) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4480 := z.DecBinary() - _ = yym4480 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4481 := r.ContainerType() - if yyct4481 == codecSelferValueTypeMap1234 { - yyl4481 := r.ReadMapStart() - if yyl4481 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4481, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4481 == codecSelferValueTypeArray1234 { - yyl4481 := r.ReadArrayStart() - if yyl4481 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4481, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -55917,12 +67457,12 @@ func (x *DownwardAPIVolumeFile) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4482Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4482Slc - var yyhl4482 bool = l >= 0 - for yyj4482 := 0; ; yyj4482++ { - if yyhl4482 { - if yyj4482 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -55931,15 +67471,21 @@ func (x *DownwardAPIVolumeFile) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4482Slc = r.DecodeBytes(yys4482Slc, true, true) - yys4482 := string(yys4482Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4482 { + switch yys3 { case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "fieldRef": if r.TryDecodeAsNil() { @@ -55963,132 +67509,327 @@ func (x *DownwardAPIVolumeFile) codecDecodeSelfFromMap(l int, d *codec1978.Decod } x.ResourceFieldRef.CodecDecodeSelf(d) } - case "mode": + case "mode": + if r.TryDecodeAsNil() { + if x.Mode != nil { + x.Mode = nil + } + } else { + if x.Mode == nil { + x.Mode = new(int32) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *DownwardAPIVolumeFile) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Path = "" + } else { + yyv11 := &x.Path + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FieldRef != nil { + x.FieldRef = nil + } + } else { + if x.FieldRef == nil { + x.FieldRef = new(ObjectFieldSelector) + } + x.FieldRef.CodecDecodeSelf(d) + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ResourceFieldRef != nil { + x.ResourceFieldRef = nil + } + } else { + if x.ResourceFieldRef == nil { + x.ResourceFieldRef = new(ResourceFieldSelector) + } + x.ResourceFieldRef.CodecDecodeSelf(d) + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Mode != nil { + x.Mode = nil + } + } else { + if x.Mode == nil { + x.Mode = new(int32) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *DownwardAPIProjection) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Items) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Items == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceDownwardAPIVolumeFile(([]DownwardAPIVolumeFile)(x.Items), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DownwardAPIProjection) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *DownwardAPIProjection) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "items": if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil - } + x.Items = nil } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym4487 := z.DecBinary() - _ = yym4487 + yyv4 := &x.Items + yym5 := z.DecBinary() + _ = yym5 if false { } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys4482) - } // end switch yys4482 - } // end for yyj4482 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *DownwardAPIVolumeFile) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DownwardAPIProjection) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4488 int - var yyb4488 bool - var yyhl4488 bool = l >= 0 - yyj4488++ - if yyhl4488 { - yyb4488 = yyj4488 > l - } else { - yyb4488 = r.CheckBreak() - } - if yyb4488 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj4488++ - if yyhl4488 { - yyb4488 = yyj4488 > l - } else { - yyb4488 = r.CheckBreak() - } - if yyb4488 { - 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) - } - yyj4488++ - if yyhl4488 { - yyb4488 = yyj4488 > l - } else { - yyb4488 = r.CheckBreak() - } - if yyb4488 { - 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) - } - yyj4488++ - if yyhl4488 { - yyb4488 = yyj4488 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4488 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4488 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Mode != nil { - x.Mode = nil - } + x.Items = nil } else { - if x.Mode == nil { - x.Mode = new(int32) - } - yym4493 := z.DecBinary() - _ = yym4493 + yyv7 := &x.Items + yym8 := z.DecBinary() + _ = yym8 if false { } else { - *((*int32)(x.Mode)) = int32(r.DecodeInt(32)) + h.decSliceDownwardAPIVolumeFile((*[]DownwardAPIVolumeFile)(yyv7), d) } } for { - yyj4488++ - if yyhl4488 { - yyb4488 = yyj4488 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb4488 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb4488 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4488-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -56100,38 +67841,38 @@ func (x *SecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4494 := z.EncBinary() - _ = yym4494 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4495 := !z.EncBinary() - yy2arr4495 := z.EncBasicHandle().StructToArray - var yyq4495 [6]bool - _, _, _ = yysep4495, yyq4495, yy2arr4495 - const yyr4495 bool = false - yyq4495[0] = x.Capabilities != nil - yyq4495[1] = x.Privileged != nil - yyq4495[2] = x.SELinuxOptions != nil - yyq4495[3] = x.RunAsUser != nil - yyq4495[4] = x.RunAsNonRoot != nil - yyq4495[5] = x.ReadOnlyRootFilesystem != nil - var yynn4495 int - if yyr4495 || yy2arr4495 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Capabilities != nil + yyq2[1] = x.Privileged != nil + yyq2[2] = x.SELinuxOptions != nil + yyq2[3] = x.RunAsUser != nil + yyq2[4] = x.RunAsNonRoot != nil + yyq2[5] = x.ReadOnlyRootFilesystem != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn4495 = 0 - for _, b := range yyq4495 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4495++ + yynn2++ } } - r.EncodeMapStart(yynn4495) - yynn4495 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4495[0] { + if yyq2[0] { if x.Capabilities == nil { r.EncodeNil() } else { @@ -56141,7 +67882,7 @@ func (x *SecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4495[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("capabilities")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -56152,44 +67893,44 @@ func (x *SecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4495[1] { + if yyq2[1] { if x.Privileged == nil { r.EncodeNil() } else { - yy4498 := *x.Privileged - yym4499 := z.EncBinary() - _ = yym4499 + yy7 := *x.Privileged + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeBool(bool(yy4498)) + r.EncodeBool(bool(yy7)) } } } else { r.EncodeNil() } } else { - if yyq4495[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("privileged")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Privileged == nil { r.EncodeNil() } else { - yy4500 := *x.Privileged - yym4501 := z.EncBinary() - _ = yym4501 + yy9 := *x.Privileged + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeBool(bool(yy4500)) + r.EncodeBool(bool(yy9)) } } } } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4495[2] { + if yyq2[2] { if x.SELinuxOptions == nil { r.EncodeNil() } else { @@ -56199,7 +67940,7 @@ func (x *SecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq4495[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("seLinuxOptions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -56210,112 +67951,112 @@ func (x *SecurityContext) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4495[3] { + if yyq2[3] { if x.RunAsUser == nil { r.EncodeNil() } else { - yy4504 := *x.RunAsUser - yym4505 := z.EncBinary() - _ = yym4505 + yy15 := *x.RunAsUser + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeInt(int64(yy4504)) + r.EncodeInt(int64(yy15)) } } } else { r.EncodeNil() } } else { - if yyq4495[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RunAsUser == nil { r.EncodeNil() } else { - yy4506 := *x.RunAsUser - yym4507 := z.EncBinary() - _ = yym4507 + yy17 := *x.RunAsUser + yym18 := z.EncBinary() + _ = yym18 if false { } else { - r.EncodeInt(int64(yy4506)) + r.EncodeInt(int64(yy17)) } } } } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4495[4] { + if yyq2[4] { if x.RunAsNonRoot == nil { r.EncodeNil() } else { - yy4509 := *x.RunAsNonRoot - yym4510 := z.EncBinary() - _ = yym4510 + yy20 := *x.RunAsNonRoot + yym21 := z.EncBinary() + _ = yym21 if false { } else { - r.EncodeBool(bool(yy4509)) + r.EncodeBool(bool(yy20)) } } } else { r.EncodeNil() } } else { - if yyq4495[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("runAsNonRoot")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RunAsNonRoot == nil { r.EncodeNil() } else { - yy4511 := *x.RunAsNonRoot - yym4512 := z.EncBinary() - _ = yym4512 + yy22 := *x.RunAsNonRoot + yym23 := z.EncBinary() + _ = yym23 if false { } else { - r.EncodeBool(bool(yy4511)) + r.EncodeBool(bool(yy22)) } } } } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4495[5] { + if yyq2[5] { if x.ReadOnlyRootFilesystem == nil { r.EncodeNil() } else { - yy4514 := *x.ReadOnlyRootFilesystem - yym4515 := z.EncBinary() - _ = yym4515 + yy25 := *x.ReadOnlyRootFilesystem + yym26 := z.EncBinary() + _ = yym26 if false { } else { - r.EncodeBool(bool(yy4514)) + r.EncodeBool(bool(yy25)) } } } else { r.EncodeNil() } } else { - if yyq4495[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnlyRootFilesystem")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ReadOnlyRootFilesystem == nil { r.EncodeNil() } else { - yy4516 := *x.ReadOnlyRootFilesystem - yym4517 := z.EncBinary() - _ = yym4517 + yy27 := *x.ReadOnlyRootFilesystem + yym28 := z.EncBinary() + _ = yym28 if false { } else { - r.EncodeBool(bool(yy4516)) + r.EncodeBool(bool(yy27)) } } } } - if yyr4495 || yy2arr4495 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -56328,25 +68069,25 @@ func (x *SecurityContext) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4518 := z.DecBinary() - _ = yym4518 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4519 := r.ContainerType() - if yyct4519 == codecSelferValueTypeMap1234 { - yyl4519 := r.ReadMapStart() - if yyl4519 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4519, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4519 == codecSelferValueTypeArray1234 { - yyl4519 := r.ReadArrayStart() - if yyl4519 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4519, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -56358,12 +68099,12 @@ func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4520Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4520Slc - var yyhl4520 bool = l >= 0 - for yyj4520 := 0; ; yyj4520++ { - if yyhl4520 { - if yyj4520 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -56372,10 +68113,10 @@ func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4520Slc = r.DecodeBytes(yys4520Slc, true, true) - yys4520 := string(yys4520Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4520 { + switch yys3 { case "capabilities": if r.TryDecodeAsNil() { if x.Capabilities != nil { @@ -56396,8 +68137,8 @@ func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Privileged == nil { x.Privileged = new(bool) } - yym4523 := z.DecBinary() - _ = yym4523 + yym6 := z.DecBinary() + _ = yym6 if false { } else { *((*bool)(x.Privileged)) = r.DecodeBool() @@ -56423,8 +68164,8 @@ func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.RunAsUser == nil { x.RunAsUser = new(int64) } - yym4526 := z.DecBinary() - _ = yym4526 + yym9 := z.DecBinary() + _ = yym9 if false { } else { *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) @@ -56439,8 +68180,8 @@ func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.RunAsNonRoot == nil { x.RunAsNonRoot = new(bool) } - yym4528 := z.DecBinary() - _ = yym4528 + yym11 := z.DecBinary() + _ = yym11 if false { } else { *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() @@ -56455,17 +68196,17 @@ func (x *SecurityContext) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.ReadOnlyRootFilesystem == nil { x.ReadOnlyRootFilesystem = new(bool) } - yym4530 := z.DecBinary() - _ = yym4530 + yym13 := z.DecBinary() + _ = yym13 if false { } else { *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool() } } default: - z.DecStructFieldNotFound(-1, yys4520) - } // end switch yys4520 - } // end for yyj4520 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -56473,16 +68214,16 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4531 int - var yyb4531 bool - var yyhl4531 bool = l >= 0 - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56497,13 +68238,13 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) } x.Capabilities.CodecDecodeSelf(d) } - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56516,20 +68257,20 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if x.Privileged == nil { x.Privileged = new(bool) } - yym4534 := z.DecBinary() - _ = yym4534 + yym17 := z.DecBinary() + _ = yym17 if false { } else { *((*bool)(x.Privileged)) = r.DecodeBool() } } - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56544,13 +68285,13 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) } x.SELinuxOptions.CodecDecodeSelf(d) } - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56563,20 +68304,20 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if x.RunAsUser == nil { x.RunAsUser = new(int64) } - yym4537 := z.DecBinary() - _ = yym4537 + yym20 := z.DecBinary() + _ = yym20 if false { } else { *((*int64)(x.RunAsUser)) = int64(r.DecodeInt(64)) } } - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56589,20 +68330,20 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if x.RunAsNonRoot == nil { x.RunAsNonRoot = new(bool) } - yym4539 := z.DecBinary() - _ = yym4539 + yym22 := z.DecBinary() + _ = yym22 if false { } else { *((*bool)(x.RunAsNonRoot)) = r.DecodeBool() } } - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56615,25 +68356,25 @@ func (x *SecurityContext) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if x.ReadOnlyRootFilesystem == nil { x.ReadOnlyRootFilesystem = new(bool) } - yym4541 := z.DecBinary() - _ = yym4541 + yym24 := z.DecBinary() + _ = yym24 if false { } else { *((*bool)(x.ReadOnlyRootFilesystem)) = r.DecodeBool() } } for { - yyj4531++ - if yyhl4531 { - yyb4531 = yyj4531 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4531 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4531 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4531-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -56645,38 +68386,38 @@ func (x *SELinuxOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4542 := z.EncBinary() - _ = yym4542 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4543 := !z.EncBinary() - yy2arr4543 := z.EncBasicHandle().StructToArray - var yyq4543 [4]bool - _, _, _ = yysep4543, yyq4543, yy2arr4543 - const yyr4543 bool = false - yyq4543[0] = x.User != "" - yyq4543[1] = x.Role != "" - yyq4543[2] = x.Type != "" - yyq4543[3] = x.Level != "" - var yynn4543 int - if yyr4543 || yy2arr4543 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.User != "" + yyq2[1] = x.Role != "" + yyq2[2] = x.Type != "" + yyq2[3] = x.Level != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn4543 = 0 - for _, b := range yyq4543 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn4543++ + yynn2++ } } - r.EncodeMapStart(yynn4543) - yynn4543 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4543 || yy2arr4543 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4543[0] { - yym4545 := z.EncBinary() - _ = yym4545 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) @@ -56685,23 +68426,23 @@ func (x *SELinuxOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4543[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("user")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4546 := z.EncBinary() - _ = yym4546 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) } } } - if yyr4543 || yy2arr4543 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4543[1] { - yym4548 := z.EncBinary() - _ = yym4548 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Role)) @@ -56710,23 +68451,23 @@ func (x *SELinuxOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4543[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("role")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4549 := z.EncBinary() - _ = yym4549 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Role)) } } } - if yyr4543 || yy2arr4543 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4543[2] { - yym4551 := z.EncBinary() - _ = yym4551 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Type)) @@ -56735,23 +68476,23 @@ func (x *SELinuxOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4543[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4552 := z.EncBinary() - _ = yym4552 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Type)) } } } - if yyr4543 || yy2arr4543 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4543[3] { - yym4554 := z.EncBinary() - _ = yym4554 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Level)) @@ -56760,19 +68501,19 @@ func (x *SELinuxOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4543[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("level")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4555 := z.EncBinary() - _ = yym4555 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Level)) } } } - if yyr4543 || yy2arr4543 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -56785,25 +68526,25 @@ func (x *SELinuxOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4556 := z.DecBinary() - _ = yym4556 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4557 := r.ContainerType() - if yyct4557 == codecSelferValueTypeMap1234 { - yyl4557 := r.ReadMapStart() - if yyl4557 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4557, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4557 == codecSelferValueTypeArray1234 { - yyl4557 := r.ReadArrayStart() - if yyl4557 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4557, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -56815,12 +68556,12 @@ func (x *SELinuxOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4558Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4558Slc - var yyhl4558 bool = l >= 0 - for yyj4558 := 0; ; yyj4558++ { - if yyhl4558 { - if yyj4558 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -56829,38 +68570,62 @@ func (x *SELinuxOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4558Slc = r.DecodeBytes(yys4558Slc, true, true) - yys4558 := string(yys4558Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4558 { + switch yys3 { case "user": if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv4 := &x.User + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "role": if r.TryDecodeAsNil() { x.Role = "" } else { - x.Role = string(r.DecodeString()) + yyv6 := &x.Role + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = string(r.DecodeString()) + yyv8 := &x.Type + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "level": if r.TryDecodeAsNil() { x.Level = "" } else { - x.Level = string(r.DecodeString()) + yyv10 := &x.Level + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys4558) - } // end switch yys4558 - } // end for yyj4558 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -56868,16 +68633,16 @@ func (x *SELinuxOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4563 int - var yyb4563 bool - var yyhl4563 bool = l >= 0 - yyj4563++ - if yyhl4563 { - yyb4563 = yyj4563 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4563 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4563 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56885,15 +68650,21 @@ func (x *SELinuxOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv13 := &x.User + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj4563++ - if yyhl4563 { - yyb4563 = yyj4563 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4563 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4563 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56901,15 +68672,21 @@ func (x *SELinuxOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Role = "" } else { - x.Role = string(r.DecodeString()) + yyv15 := &x.Role + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4563++ - if yyhl4563 { - yyb4563 = yyj4563 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4563 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4563 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56917,15 +68694,21 @@ func (x *SELinuxOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = string(r.DecodeString()) + yyv17 := &x.Type + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj4563++ - if yyhl4563 { - yyb4563 = yyj4563 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4563 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4563 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -56933,20 +68716,26 @@ func (x *SELinuxOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Level = "" } else { - x.Level = string(r.DecodeString()) + yyv19 := &x.Level + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } for { - yyj4563++ - if yyhl4563 { - yyb4563 = yyj4563 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb4563 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb4563 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4563-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -56958,37 +68747,37 @@ func (x *RangeAllocation) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym4568 := z.EncBinary() - _ = yym4568 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep4569 := !z.EncBinary() - yy2arr4569 := z.EncBasicHandle().StructToArray - var yyq4569 [5]bool - _, _, _ = yysep4569, yyq4569, yy2arr4569 - const yyr4569 bool = false - yyq4569[0] = x.Kind != "" - yyq4569[1] = x.APIVersion != "" - yyq4569[2] = true - var yynn4569 int - if yyr4569 || yy2arr4569 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn4569 = 2 - for _, b := range yyq4569 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn4569++ + yynn2++ } } - r.EncodeMapStart(yynn4569) - yynn4569 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr4569 || yy2arr4569 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4569[0] { - yym4571 := z.EncBinary() - _ = yym4571 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -56997,23 +68786,23 @@ func (x *RangeAllocation) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4569[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4572 := z.EncBinary() - _ = yym4572 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr4569 || yy2arr4569 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4569[1] { - yym4574 := z.EncBinary() - _ = yym4574 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -57022,39 +68811,51 @@ func (x *RangeAllocation) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq4569[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4575 := z.EncBinary() - _ = yym4575 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr4569 || yy2arr4569 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq4569[2] { - yy4577 := &x.ObjectMeta - yy4577.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq4569[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4578 := &x.ObjectMeta - yy4578.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr4569 || yy2arr4569 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym4580 := z.EncBinary() - _ = yym4580 + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Range)) @@ -57063,20 +68864,20 @@ func (x *RangeAllocation) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("range")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym4581 := z.EncBinary() - _ = yym4581 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Range)) } } - if yyr4569 || yy2arr4569 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Data == nil { r.EncodeNil() } else { - yym4583 := z.EncBinary() - _ = yym4583 + yym18 := z.EncBinary() + _ = yym18 if false { } else { r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) @@ -57089,15 +68890,15 @@ func (x *RangeAllocation) CodecEncodeSelf(e *codec1978.Encoder) { if x.Data == nil { r.EncodeNil() } else { - yym4584 := z.EncBinary() - _ = yym4584 + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) } } } - if yyr4569 || yy2arr4569 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -57110,25 +68911,25 @@ func (x *RangeAllocation) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym4585 := z.DecBinary() - _ = yym4585 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct4586 := r.ContainerType() - if yyct4586 == codecSelferValueTypeMap1234 { - yyl4586 := r.ReadMapStart() - if yyl4586 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl4586, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct4586 == codecSelferValueTypeArray1234 { - yyl4586 := r.ReadArrayStart() - if yyl4586 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl4586, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -57140,12 +68941,12 @@ func (x *RangeAllocation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys4587Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys4587Slc - var yyhl4587 bool = l >= 0 - for yyj4587 := 0; ; yyj4587++ { - if yyhl4587 { - if yyj4587 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -57154,51 +68955,75 @@ func (x *RangeAllocation) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys4587Slc = r.DecodeBytes(yys4587Slc, true, true) - yys4587 := string(yys4587Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys4587 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4590 := &x.ObjectMeta - yyv4590.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "range": if r.TryDecodeAsNil() { x.Range = "" } else { - x.Range = string(r.DecodeString()) + yyv10 := &x.Range + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "data": if r.TryDecodeAsNil() { x.Data = nil } else { - yyv4592 := &x.Data - yym4593 := z.DecBinary() - _ = yym4593 + yyv12 := &x.Data + yym13 := z.DecBinary() + _ = yym13 if false { } else { - *yyv4592 = r.DecodeBytes(*(*[]byte)(yyv4592), false, false) + *yyv12 = r.DecodeBytes(*(*[]byte)(yyv12), false, false) } } default: - z.DecStructFieldNotFound(-1, yys4587) - } // end switch yys4587 - } // end for yyj4587 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -57206,16 +69031,16 @@ func (x *RangeAllocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj4594 int - var yyb4594 bool - var yyhl4594 bool = l >= 0 - yyj4594++ - if yyhl4594 { - yyb4594 = yyj4594 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4594 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4594 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -57223,15 +69048,21 @@ func (x *RangeAllocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj4594++ - if yyhl4594 { - yyb4594 = yyj4594 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4594 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4594 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -57239,32 +69070,44 @@ func (x *RangeAllocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj4594++ - if yyhl4594 { - yyb4594 = yyj4594 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4594 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4594 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv4597 := &x.ObjectMeta - yyv4597.CodecDecodeSelf(d) + yyv19 := &x.ObjectMeta + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + z.DecFallback(yyv19, false) + } } - yyj4594++ - if yyhl4594 { - yyb4594 = yyj4594 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4594 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4594 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -57272,15 +69115,21 @@ func (x *RangeAllocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Range = "" } else { - x.Range = string(r.DecodeString()) + yyv21 := &x.Range + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj4594++ - if yyhl4594 { - yyb4594 = yyj4594 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb4594 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb4594 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -57288,125 +69137,541 @@ func (x *RangeAllocation) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Data = nil } else { - yyv4599 := &x.Data - yym4600 := z.DecBinary() - _ = yym4600 + yyv23 := &x.Data + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *yyv23 = r.DecodeBytes(*(*[]byte)(yyv23), false, false) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Sysctl) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("Name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Value)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("Value")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Value)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Sysctl) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Sysctl) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "Name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "Value": + if r.TryDecodeAsNil() { + x.Value = "" + } else { + yyv6 := &x.Value + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Sysctl) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv9 := &x.Name + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Value = "" + } else { + yyv11 := &x.Value + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NodeResources) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Capacity == nil { + r.EncodeNil() + } else { + x.Capacity.CodecEncodeSelf(e) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("Capacity")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Capacity == nil { + r.EncodeNil() + } else { + x.Capacity.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NodeResources) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NodeResources) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } } else { - *yyv4599 = r.DecodeBytes(*(*[]byte)(yyv4599), false, false) + if r.CheckBreak() { + break + } } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "Capacity": + if r.TryDecodeAsNil() { + x.Capacity = nil + } else { + yyv4 := &x.Capacity + yyv4.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NodeResources) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj5 int + var yyb5 bool + var yyhl5 bool = l >= 0 + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l + } else { + yyb5 = r.CheckBreak() + } + if yyb5 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Capacity = nil + } else { + yyv6 := &x.Capacity + yyv6.CodecDecodeSelf(d) } for { - yyj4594++ - if yyhl4594 { - yyb4594 = yyj4594 > l + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb4594 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb4594 { + if yyb5 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj4594-1, "") + z.DecStructFieldNotFound(yyj5-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) encSliceOwnerReference(v []OwnerReference, e *codec1978.Encoder) { +func (x codecSelfer1234) encSlicev1_OwnerReference(v []pkg2_v1.OwnerReference, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4601 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4602 := &yyv4601 - yy4602.CodecEncodeSelf(e) + yy2 := &yyv1 + yym3 := z.EncBinary() + _ = yym3 + if false { + } else if z.HasExtensions() && z.EncExt(yy2) { + } else { + z.EncFallback(yy2) + } } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) decSliceOwnerReference(v *[]OwnerReference, d *codec1978.Decoder) { +func (x codecSelfer1234) decSlicev1_OwnerReference(v *[]pkg2_v1.OwnerReference, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4603 := *v - yyh4603, yyl4603 := z.DecSliceHelperStart() - var yyc4603 bool - if yyl4603 == 0 { - if yyv4603 == nil { - yyv4603 = []OwnerReference{} - yyc4603 = true - } else if len(yyv4603) != 0 { - yyv4603 = yyv4603[:0] - yyc4603 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []pkg2_v1.OwnerReference{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4603 > 0 { - var yyrr4603, yyrl4603 int - var yyrt4603 bool - if yyl4603 > cap(yyv4603) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4603 := len(yyv4603) > 0 - yyv24603 := yyv4603 - yyrl4603, yyrt4603 = z.DecInferLen(yyl4603, z.DecBasicHandle().MaxInitLen, 72) - if yyrt4603 { - if yyrl4603 <= cap(yyv4603) { - yyv4603 = yyv4603[:yyrl4603] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 80) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4603 = make([]OwnerReference, yyrl4603) + yyv1 = make([]pkg2_v1.OwnerReference, yyrl1) } } else { - yyv4603 = make([]OwnerReference, yyrl4603) + yyv1 = make([]pkg2_v1.OwnerReference, yyrl1) } - yyc4603 = true - yyrr4603 = len(yyv4603) - if yyrg4603 { - copy(yyv4603, yyv24603) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4603 != len(yyv4603) { - yyv4603 = yyv4603[:yyl4603] - yyc4603 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4603 := 0 - for ; yyj4603 < yyrr4603; yyj4603++ { - yyh4603.ElemContainerState(yyj4603) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4603[yyj4603] = OwnerReference{} + yyv1[yyj1] = pkg2_v1.OwnerReference{} } else { - yyv4604 := &yyv4603[yyj4603] - yyv4604.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else if z.HasExtensions() && z.DecExt(yyv2) { + } else { + z.DecFallback(yyv2, false) + } } } - if yyrt4603 { - for ; yyj4603 < yyl4603; yyj4603++ { - yyv4603 = append(yyv4603, OwnerReference{}) - yyh4603.ElemContainerState(yyj4603) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, pkg2_v1.OwnerReference{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4603[yyj4603] = OwnerReference{} + yyv1[yyj1] = pkg2_v1.OwnerReference{} } else { - yyv4605 := &yyv4603[yyj4603] - yyv4605.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + z.DecFallback(yyv4, false) + } } } } } else { - yyj4603 := 0 - for ; !r.CheckBreak(); yyj4603++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4603 >= len(yyv4603) { - yyv4603 = append(yyv4603, OwnerReference{}) // var yyz4603 OwnerReference - yyc4603 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, pkg2_v1.OwnerReference{}) // var yyz1 pkg2_v1.OwnerReference + yyc1 = true } - yyh4603.ElemContainerState(yyj4603) - if yyj4603 < len(yyv4603) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4603[yyj4603] = OwnerReference{} + yyv1[yyj1] = pkg2_v1.OwnerReference{} } else { - yyv4606 := &yyv4603[yyj4603] - yyv4606.CodecDecodeSelf(d) + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else { + z.DecFallback(yyv6, false) + } } } else { @@ -57414,17 +69679,17 @@ func (x codecSelfer1234) decSliceOwnerReference(v *[]OwnerReference, d *codec197 } } - if yyj4603 < len(yyv4603) { - yyv4603 = yyv4603[:yyj4603] - yyc4603 = true - } else if yyj4603 == 0 && yyv4603 == nil { - yyv4603 = []OwnerReference{} - yyc4603 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []pkg2_v1.OwnerReference{} + yyc1 = true } } - yyh4603.End() - if yyc4603 { - *v = yyv4603 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -57433,9 +69698,9 @@ func (x codecSelfer1234) encSlicePersistentVolumeAccessMode(v []PersistentVolume z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4607 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4607.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -57445,75 +69710,81 @@ func (x codecSelfer1234) decSlicePersistentVolumeAccessMode(v *[]PersistentVolum z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4608 := *v - yyh4608, yyl4608 := z.DecSliceHelperStart() - var yyc4608 bool - if yyl4608 == 0 { - if yyv4608 == nil { - yyv4608 = []PersistentVolumeAccessMode{} - yyc4608 = true - } else if len(yyv4608) != 0 { - yyv4608 = yyv4608[:0] - yyc4608 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PersistentVolumeAccessMode{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4608 > 0 { - var yyrr4608, yyrl4608 int - var yyrt4608 bool - if yyl4608 > cap(yyv4608) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl4608, yyrt4608 = z.DecInferLen(yyl4608, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4608 { - if yyrl4608 <= cap(yyv4608) { - yyv4608 = yyv4608[:yyrl4608] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4608 = make([]PersistentVolumeAccessMode, yyrl4608) + yyv1 = make([]PersistentVolumeAccessMode, yyrl1) } } else { - yyv4608 = make([]PersistentVolumeAccessMode, yyrl4608) + yyv1 = make([]PersistentVolumeAccessMode, yyrl1) } - yyc4608 = true - yyrr4608 = len(yyv4608) - } else if yyl4608 != len(yyv4608) { - yyv4608 = yyv4608[:yyl4608] - yyc4608 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4608 := 0 - for ; yyj4608 < yyrr4608; yyj4608++ { - yyh4608.ElemContainerState(yyj4608) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4608[yyj4608] = "" + yyv1[yyj1] = "" } else { - yyv4608[yyj4608] = PersistentVolumeAccessMode(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4608 { - for ; yyj4608 < yyl4608; yyj4608++ { - yyv4608 = append(yyv4608, "") - yyh4608.ElemContainerState(yyj4608) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4608[yyj4608] = "" + yyv1[yyj1] = "" } else { - yyv4608[yyj4608] = PersistentVolumeAccessMode(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4608 := 0 - for ; !r.CheckBreak(); yyj4608++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4608 >= len(yyv4608) { - yyv4608 = append(yyv4608, "") // var yyz4608 PersistentVolumeAccessMode - yyc4608 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 PersistentVolumeAccessMode + yyc1 = true } - yyh4608.ElemContainerState(yyj4608) - if yyj4608 < len(yyv4608) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4608[yyj4608] = "" + yyv1[yyj1] = "" } else { - yyv4608[yyj4608] = PersistentVolumeAccessMode(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -57521,17 +69792,17 @@ func (x codecSelfer1234) decSlicePersistentVolumeAccessMode(v *[]PersistentVolum } } - if yyj4608 < len(yyv4608) { - yyv4608 = yyv4608[:yyj4608] - yyc4608 = true - } else if yyj4608 == 0 && yyv4608 == nil { - yyv4608 = []PersistentVolumeAccessMode{} - yyc4608 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PersistentVolumeAccessMode{} + yyc1 = true } } - yyh4608.End() - if yyc4608 { - *v = yyv4608 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -57540,10 +69811,10 @@ func (x codecSelfer1234) encSlicePersistentVolume(v []PersistentVolume, e *codec z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4612 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4613 := &yyv4612 - yy4613.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -57553,83 +69824,86 @@ func (x codecSelfer1234) decSlicePersistentVolume(v *[]PersistentVolume, d *code z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4614 := *v - yyh4614, yyl4614 := z.DecSliceHelperStart() - var yyc4614 bool - if yyl4614 == 0 { - if yyv4614 == nil { - yyv4614 = []PersistentVolume{} - yyc4614 = true - } else if len(yyv4614) != 0 { - yyv4614 = yyv4614[:0] - yyc4614 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PersistentVolume{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4614 > 0 { - var yyrr4614, yyrl4614 int - var yyrt4614 bool - if yyl4614 > cap(yyv4614) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4614 := len(yyv4614) > 0 - yyv24614 := yyv4614 - yyrl4614, yyrt4614 = z.DecInferLen(yyl4614, z.DecBasicHandle().MaxInitLen, 496) - if yyrt4614 { - if yyrl4614 <= cap(yyv4614) { - yyv4614 = yyv4614[:yyrl4614] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 552) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4614 = make([]PersistentVolume, yyrl4614) + yyv1 = make([]PersistentVolume, yyrl1) } } else { - yyv4614 = make([]PersistentVolume, yyrl4614) + yyv1 = make([]PersistentVolume, yyrl1) } - yyc4614 = true - yyrr4614 = len(yyv4614) - if yyrg4614 { - copy(yyv4614, yyv24614) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4614 != len(yyv4614) { - yyv4614 = yyv4614[:yyl4614] - yyc4614 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4614 := 0 - for ; yyj4614 < yyrr4614; yyj4614++ { - yyh4614.ElemContainerState(yyj4614) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4614[yyj4614] = PersistentVolume{} + yyv1[yyj1] = PersistentVolume{} } else { - yyv4615 := &yyv4614[yyj4614] - yyv4615.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4614 { - for ; yyj4614 < yyl4614; yyj4614++ { - yyv4614 = append(yyv4614, PersistentVolume{}) - yyh4614.ElemContainerState(yyj4614) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PersistentVolume{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4614[yyj4614] = PersistentVolume{} + yyv1[yyj1] = PersistentVolume{} } else { - yyv4616 := &yyv4614[yyj4614] - yyv4616.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4614 := 0 - for ; !r.CheckBreak(); yyj4614++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4614 >= len(yyv4614) { - yyv4614 = append(yyv4614, PersistentVolume{}) // var yyz4614 PersistentVolume - yyc4614 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PersistentVolume{}) // var yyz1 PersistentVolume + yyc1 = true } - yyh4614.ElemContainerState(yyj4614) - if yyj4614 < len(yyv4614) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4614[yyj4614] = PersistentVolume{} + yyv1[yyj1] = PersistentVolume{} } else { - yyv4617 := &yyv4614[yyj4614] - yyv4617.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -57637,17 +69911,17 @@ func (x codecSelfer1234) decSlicePersistentVolume(v *[]PersistentVolume, d *code } } - if yyj4614 < len(yyv4614) { - yyv4614 = yyv4614[:yyj4614] - yyc4614 = true - } else if yyj4614 == 0 && yyv4614 == nil { - yyv4614 = []PersistentVolume{} - yyc4614 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PersistentVolume{} + yyc1 = true } } - yyh4614.End() - if yyc4614 { - *v = yyv4614 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -57656,10 +69930,10 @@ func (x codecSelfer1234) encSlicePersistentVolumeClaim(v []PersistentVolumeClaim z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4618 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4619 := &yyv4618 - yy4619.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -57669,83 +69943,86 @@ func (x codecSelfer1234) decSlicePersistentVolumeClaim(v *[]PersistentVolumeClai z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4620 := *v - yyh4620, yyl4620 := z.DecSliceHelperStart() - var yyc4620 bool - if yyl4620 == 0 { - if yyv4620 == nil { - yyv4620 = []PersistentVolumeClaim{} - yyc4620 = true - } else if len(yyv4620) != 0 { - yyv4620 = yyv4620[:0] - yyc4620 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PersistentVolumeClaim{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4620 > 0 { - var yyrr4620, yyrl4620 int - var yyrt4620 bool - if yyl4620 > cap(yyv4620) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4620 := len(yyv4620) > 0 - yyv24620 := yyv4620 - yyrl4620, yyrt4620 = z.DecInferLen(yyl4620, z.DecBasicHandle().MaxInitLen, 368) - if yyrt4620 { - if yyrl4620 <= cap(yyv4620) { - yyv4620 = yyv4620[:yyrl4620] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 384) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4620 = make([]PersistentVolumeClaim, yyrl4620) + yyv1 = make([]PersistentVolumeClaim, yyrl1) } } else { - yyv4620 = make([]PersistentVolumeClaim, yyrl4620) + yyv1 = make([]PersistentVolumeClaim, yyrl1) } - yyc4620 = true - yyrr4620 = len(yyv4620) - if yyrg4620 { - copy(yyv4620, yyv24620) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4620 != len(yyv4620) { - yyv4620 = yyv4620[:yyl4620] - yyc4620 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4620 := 0 - for ; yyj4620 < yyrr4620; yyj4620++ { - yyh4620.ElemContainerState(yyj4620) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4620[yyj4620] = PersistentVolumeClaim{} + yyv1[yyj1] = PersistentVolumeClaim{} } else { - yyv4621 := &yyv4620[yyj4620] - yyv4621.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4620 { - for ; yyj4620 < yyl4620; yyj4620++ { - yyv4620 = append(yyv4620, PersistentVolumeClaim{}) - yyh4620.ElemContainerState(yyj4620) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PersistentVolumeClaim{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4620[yyj4620] = PersistentVolumeClaim{} + yyv1[yyj1] = PersistentVolumeClaim{} } else { - yyv4622 := &yyv4620[yyj4620] - yyv4622.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4620 := 0 - for ; !r.CheckBreak(); yyj4620++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4620 >= len(yyv4620) { - yyv4620 = append(yyv4620, PersistentVolumeClaim{}) // var yyz4620 PersistentVolumeClaim - yyc4620 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PersistentVolumeClaim{}) // var yyz1 PersistentVolumeClaim + yyc1 = true } - yyh4620.ElemContainerState(yyj4620) - if yyj4620 < len(yyv4620) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4620[yyj4620] = PersistentVolumeClaim{} + yyv1[yyj1] = PersistentVolumeClaim{} } else { - yyv4623 := &yyv4620[yyj4620] - yyv4623.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -57753,17 +70030,17 @@ func (x codecSelfer1234) decSlicePersistentVolumeClaim(v *[]PersistentVolumeClai } } - if yyj4620 < len(yyv4620) { - yyv4620 = yyv4620[:yyj4620] - yyc4620 = true - } else if yyj4620 == 0 && yyv4620 == nil { - yyv4620 = []PersistentVolumeClaim{} - yyc4620 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PersistentVolumeClaim{} + yyc1 = true } } - yyh4620.End() - if yyc4620 { - *v = yyv4620 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -57772,10 +70049,10 @@ func (x codecSelfer1234) encSliceKeyToPath(v []KeyToPath, e *codec1978.Encoder) z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4624 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4625 := &yyv4624 - yy4625.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -57785,83 +70062,86 @@ func (x codecSelfer1234) decSliceKeyToPath(v *[]KeyToPath, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4626 := *v - yyh4626, yyl4626 := z.DecSliceHelperStart() - var yyc4626 bool - if yyl4626 == 0 { - if yyv4626 == nil { - yyv4626 = []KeyToPath{} - yyc4626 = true - } else if len(yyv4626) != 0 { - yyv4626 = yyv4626[:0] - yyc4626 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []KeyToPath{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4626 > 0 { - var yyrr4626, yyrl4626 int - var yyrt4626 bool - if yyl4626 > cap(yyv4626) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4626 := len(yyv4626) > 0 - yyv24626 := yyv4626 - yyrl4626, yyrt4626 = z.DecInferLen(yyl4626, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4626 { - if yyrl4626 <= cap(yyv4626) { - yyv4626 = yyv4626[:yyrl4626] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4626 = make([]KeyToPath, yyrl4626) + yyv1 = make([]KeyToPath, yyrl1) } } else { - yyv4626 = make([]KeyToPath, yyrl4626) + yyv1 = make([]KeyToPath, yyrl1) } - yyc4626 = true - yyrr4626 = len(yyv4626) - if yyrg4626 { - copy(yyv4626, yyv24626) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4626 != len(yyv4626) { - yyv4626 = yyv4626[:yyl4626] - yyc4626 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4626 := 0 - for ; yyj4626 < yyrr4626; yyj4626++ { - yyh4626.ElemContainerState(yyj4626) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4626[yyj4626] = KeyToPath{} + yyv1[yyj1] = KeyToPath{} } else { - yyv4627 := &yyv4626[yyj4626] - yyv4627.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4626 { - for ; yyj4626 < yyl4626; yyj4626++ { - yyv4626 = append(yyv4626, KeyToPath{}) - yyh4626.ElemContainerState(yyj4626) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, KeyToPath{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4626[yyj4626] = KeyToPath{} + yyv1[yyj1] = KeyToPath{} } else { - yyv4628 := &yyv4626[yyj4626] - yyv4628.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4626 := 0 - for ; !r.CheckBreak(); yyj4626++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4626 >= len(yyv4626) { - yyv4626 = append(yyv4626, KeyToPath{}) // var yyz4626 KeyToPath - yyc4626 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, KeyToPath{}) // var yyz1 KeyToPath + yyc1 = true } - yyh4626.ElemContainerState(yyj4626) - if yyj4626 < len(yyv4626) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4626[yyj4626] = KeyToPath{} + yyv1[yyj1] = KeyToPath{} } else { - yyv4629 := &yyv4626[yyj4626] - yyv4629.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -57869,17 +70149,136 @@ func (x codecSelfer1234) decSliceKeyToPath(v *[]KeyToPath, d *codec1978.Decoder) } } - if yyj4626 < len(yyv4626) { - yyv4626 = yyv4626[:yyj4626] - yyc4626 = true - } else if yyj4626 == 0 && yyv4626 == nil { - yyv4626 = []KeyToPath{} - yyc4626 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []KeyToPath{} + yyc1 = true } } - yyh4626.End() - if yyc4626 { - *v = yyv4626 + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceVolumeProjection(v []VolumeProjection, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceVolumeProjection(v *[]VolumeProjection, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []VolumeProjection{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 24) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]VolumeProjection, yyrl1) + } + } else { + yyv1 = make([]VolumeProjection, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = VolumeProjection{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, VolumeProjection{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = VolumeProjection{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, VolumeProjection{}) // var yyz1 VolumeProjection + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = VolumeProjection{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []VolumeProjection{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -57888,10 +70287,10 @@ func (x codecSelfer1234) encSliceHTTPHeader(v []HTTPHeader, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4630 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4631 := &yyv4630 - yy4631.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -57901,83 +70300,86 @@ func (x codecSelfer1234) decSliceHTTPHeader(v *[]HTTPHeader, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4632 := *v - yyh4632, yyl4632 := z.DecSliceHelperStart() - var yyc4632 bool - if yyl4632 == 0 { - if yyv4632 == nil { - yyv4632 = []HTTPHeader{} - yyc4632 = true - } else if len(yyv4632) != 0 { - yyv4632 = yyv4632[:0] - yyc4632 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HTTPHeader{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4632 > 0 { - var yyrr4632, yyrl4632 int - var yyrt4632 bool - if yyl4632 > cap(yyv4632) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4632 := len(yyv4632) > 0 - yyv24632 := yyv4632 - yyrl4632, yyrt4632 = z.DecInferLen(yyl4632, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4632 { - if yyrl4632 <= cap(yyv4632) { - yyv4632 = yyv4632[:yyrl4632] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4632 = make([]HTTPHeader, yyrl4632) + yyv1 = make([]HTTPHeader, yyrl1) } } else { - yyv4632 = make([]HTTPHeader, yyrl4632) + yyv1 = make([]HTTPHeader, yyrl1) } - yyc4632 = true - yyrr4632 = len(yyv4632) - if yyrg4632 { - copy(yyv4632, yyv24632) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4632 != len(yyv4632) { - yyv4632 = yyv4632[:yyl4632] - yyc4632 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4632 := 0 - for ; yyj4632 < yyrr4632; yyj4632++ { - yyh4632.ElemContainerState(yyj4632) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4632[yyj4632] = HTTPHeader{} + yyv1[yyj1] = HTTPHeader{} } else { - yyv4633 := &yyv4632[yyj4632] - yyv4633.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4632 { - for ; yyj4632 < yyl4632; yyj4632++ { - yyv4632 = append(yyv4632, HTTPHeader{}) - yyh4632.ElemContainerState(yyj4632) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HTTPHeader{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4632[yyj4632] = HTTPHeader{} + yyv1[yyj1] = HTTPHeader{} } else { - yyv4634 := &yyv4632[yyj4632] - yyv4634.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4632 := 0 - for ; !r.CheckBreak(); yyj4632++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4632 >= len(yyv4632) { - yyv4632 = append(yyv4632, HTTPHeader{}) // var yyz4632 HTTPHeader - yyc4632 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HTTPHeader{}) // var yyz1 HTTPHeader + yyc1 = true } - yyh4632.ElemContainerState(yyj4632) - if yyj4632 < len(yyv4632) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4632[yyj4632] = HTTPHeader{} + yyv1[yyj1] = HTTPHeader{} } else { - yyv4635 := &yyv4632[yyj4632] - yyv4635.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -57985,17 +70387,17 @@ func (x codecSelfer1234) decSliceHTTPHeader(v *[]HTTPHeader, d *codec1978.Decode } } - if yyj4632 < len(yyv4632) { - yyv4632 = yyv4632[:yyj4632] - yyc4632 = true - } else if yyj4632 == 0 && yyv4632 == nil { - yyv4632 = []HTTPHeader{} - yyc4632 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HTTPHeader{} + yyc1 = true } } - yyh4632.End() - if yyc4632 { - *v = yyv4632 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58004,9 +70406,9 @@ func (x codecSelfer1234) encSliceCapability(v []Capability, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4636 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4636.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58016,75 +70418,81 @@ func (x codecSelfer1234) decSliceCapability(v *[]Capability, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4637 := *v - yyh4637, yyl4637 := z.DecSliceHelperStart() - var yyc4637 bool - if yyl4637 == 0 { - if yyv4637 == nil { - yyv4637 = []Capability{} - yyc4637 = true - } else if len(yyv4637) != 0 { - yyv4637 = yyv4637[:0] - yyc4637 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Capability{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4637 > 0 { - var yyrr4637, yyrl4637 int - var yyrt4637 bool - if yyl4637 > cap(yyv4637) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl4637, yyrt4637 = z.DecInferLen(yyl4637, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4637 { - if yyrl4637 <= cap(yyv4637) { - yyv4637 = yyv4637[:yyrl4637] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4637 = make([]Capability, yyrl4637) + yyv1 = make([]Capability, yyrl1) } } else { - yyv4637 = make([]Capability, yyrl4637) + yyv1 = make([]Capability, yyrl1) } - yyc4637 = true - yyrr4637 = len(yyv4637) - } else if yyl4637 != len(yyv4637) { - yyv4637 = yyv4637[:yyl4637] - yyc4637 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4637 := 0 - for ; yyj4637 < yyrr4637; yyj4637++ { - yyh4637.ElemContainerState(yyj4637) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4637[yyj4637] = "" + yyv1[yyj1] = "" } else { - yyv4637[yyj4637] = Capability(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4637 { - for ; yyj4637 < yyl4637; yyj4637++ { - yyv4637 = append(yyv4637, "") - yyh4637.ElemContainerState(yyj4637) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4637[yyj4637] = "" + yyv1[yyj1] = "" } else { - yyv4637[yyj4637] = Capability(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4637 := 0 - for ; !r.CheckBreak(); yyj4637++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4637 >= len(yyv4637) { - yyv4637 = append(yyv4637, "") // var yyz4637 Capability - yyc4637 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 Capability + yyc1 = true } - yyh4637.ElemContainerState(yyj4637) - if yyj4637 < len(yyv4637) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4637[yyj4637] = "" + yyv1[yyj1] = "" } else { - yyv4637[yyj4637] = Capability(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58092,17 +70500,17 @@ func (x codecSelfer1234) decSliceCapability(v *[]Capability, d *codec1978.Decode } } - if yyj4637 < len(yyv4637) { - yyv4637 = yyv4637[:yyj4637] - yyc4637 = true - } else if yyj4637 == 0 && yyv4637 == nil { - yyv4637 = []Capability{} - yyc4637 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Capability{} + yyc1 = true } } - yyh4637.End() - if yyc4637 { - *v = yyv4637 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58111,10 +70519,10 @@ func (x codecSelfer1234) encSliceContainerPort(v []ContainerPort, e *codec1978.E z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4641 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4642 := &yyv4641 - yy4642.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58124,83 +70532,205 @@ func (x codecSelfer1234) decSliceContainerPort(v *[]ContainerPort, d *codec1978. z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4643 := *v - yyh4643, yyl4643 := z.DecSliceHelperStart() - var yyc4643 bool - if yyl4643 == 0 { - if yyv4643 == nil { - yyv4643 = []ContainerPort{} - yyc4643 = true - } else if len(yyv4643) != 0 { - yyv4643 = yyv4643[:0] - yyc4643 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ContainerPort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ContainerPort, yyrl1) + } + } else { + yyv1 = make([]ContainerPort, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ContainerPort{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ContainerPort{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ContainerPort{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ContainerPort{}) // var yyz1 ContainerPort + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ContainerPort{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ContainerPort{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceEnvFromSource(v []EnvFromSource, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceEnvFromSource(v *[]EnvFromSource, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []EnvFromSource{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4643 > 0 { - var yyrr4643, yyrl4643 int - var yyrt4643 bool - if yyl4643 > cap(yyv4643) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4643 := len(yyv4643) > 0 - yyv24643 := yyv4643 - yyrl4643, yyrt4643 = z.DecInferLen(yyl4643, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4643 { - if yyrl4643 <= cap(yyv4643) { - yyv4643 = yyv4643[:yyrl4643] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4643 = make([]ContainerPort, yyrl4643) + yyv1 = make([]EnvFromSource, yyrl1) } } else { - yyv4643 = make([]ContainerPort, yyrl4643) + yyv1 = make([]EnvFromSource, yyrl1) } - yyc4643 = true - yyrr4643 = len(yyv4643) - if yyrg4643 { - copy(yyv4643, yyv24643) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4643 != len(yyv4643) { - yyv4643 = yyv4643[:yyl4643] - yyc4643 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4643 := 0 - for ; yyj4643 < yyrr4643; yyj4643++ { - yyh4643.ElemContainerState(yyj4643) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4643[yyj4643] = ContainerPort{} + yyv1[yyj1] = EnvFromSource{} } else { - yyv4644 := &yyv4643[yyj4643] - yyv4644.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4643 { - for ; yyj4643 < yyl4643; yyj4643++ { - yyv4643 = append(yyv4643, ContainerPort{}) - yyh4643.ElemContainerState(yyj4643) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, EnvFromSource{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4643[yyj4643] = ContainerPort{} + yyv1[yyj1] = EnvFromSource{} } else { - yyv4645 := &yyv4643[yyj4643] - yyv4645.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4643 := 0 - for ; !r.CheckBreak(); yyj4643++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4643 >= len(yyv4643) { - yyv4643 = append(yyv4643, ContainerPort{}) // var yyz4643 ContainerPort - yyc4643 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, EnvFromSource{}) // var yyz1 EnvFromSource + yyc1 = true } - yyh4643.ElemContainerState(yyj4643) - if yyj4643 < len(yyv4643) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4643[yyj4643] = ContainerPort{} + yyv1[yyj1] = EnvFromSource{} } else { - yyv4646 := &yyv4643[yyj4643] - yyv4646.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58208,17 +70738,17 @@ func (x codecSelfer1234) decSliceContainerPort(v *[]ContainerPort, d *codec1978. } } - if yyj4643 < len(yyv4643) { - yyv4643 = yyv4643[:yyj4643] - yyc4643 = true - } else if yyj4643 == 0 && yyv4643 == nil { - yyv4643 = []ContainerPort{} - yyc4643 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []EnvFromSource{} + yyc1 = true } } - yyh4643.End() - if yyc4643 { - *v = yyv4643 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58227,10 +70757,10 @@ func (x codecSelfer1234) encSliceEnvVar(v []EnvVar, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4647 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4648 := &yyv4647 - yy4648.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58240,83 +70770,86 @@ func (x codecSelfer1234) decSliceEnvVar(v *[]EnvVar, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4649 := *v - yyh4649, yyl4649 := z.DecSliceHelperStart() - var yyc4649 bool - if yyl4649 == 0 { - if yyv4649 == nil { - yyv4649 = []EnvVar{} - yyc4649 = true - } else if len(yyv4649) != 0 { - yyv4649 = yyv4649[:0] - yyc4649 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []EnvVar{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4649 > 0 { - var yyrr4649, yyrl4649 int - var yyrt4649 bool - if yyl4649 > cap(yyv4649) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4649 := len(yyv4649) > 0 - yyv24649 := yyv4649 - yyrl4649, yyrt4649 = z.DecInferLen(yyl4649, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4649 { - if yyrl4649 <= cap(yyv4649) { - yyv4649 = yyv4649[:yyrl4649] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4649 = make([]EnvVar, yyrl4649) + yyv1 = make([]EnvVar, yyrl1) } } else { - yyv4649 = make([]EnvVar, yyrl4649) + yyv1 = make([]EnvVar, yyrl1) } - yyc4649 = true - yyrr4649 = len(yyv4649) - if yyrg4649 { - copy(yyv4649, yyv24649) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4649 != len(yyv4649) { - yyv4649 = yyv4649[:yyl4649] - yyc4649 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4649 := 0 - for ; yyj4649 < yyrr4649; yyj4649++ { - yyh4649.ElemContainerState(yyj4649) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4649[yyj4649] = EnvVar{} + yyv1[yyj1] = EnvVar{} } else { - yyv4650 := &yyv4649[yyj4649] - yyv4650.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4649 { - for ; yyj4649 < yyl4649; yyj4649++ { - yyv4649 = append(yyv4649, EnvVar{}) - yyh4649.ElemContainerState(yyj4649) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, EnvVar{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4649[yyj4649] = EnvVar{} + yyv1[yyj1] = EnvVar{} } else { - yyv4651 := &yyv4649[yyj4649] - yyv4651.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4649 := 0 - for ; !r.CheckBreak(); yyj4649++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4649 >= len(yyv4649) { - yyv4649 = append(yyv4649, EnvVar{}) // var yyz4649 EnvVar - yyc4649 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, EnvVar{}) // var yyz1 EnvVar + yyc1 = true } - yyh4649.ElemContainerState(yyj4649) - if yyj4649 < len(yyv4649) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4649[yyj4649] = EnvVar{} + yyv1[yyj1] = EnvVar{} } else { - yyv4652 := &yyv4649[yyj4649] - yyv4652.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58324,17 +70857,17 @@ func (x codecSelfer1234) decSliceEnvVar(v *[]EnvVar, d *codec1978.Decoder) { } } - if yyj4649 < len(yyv4649) { - yyv4649 = yyv4649[:yyj4649] - yyc4649 = true - } else if yyj4649 == 0 && yyv4649 == nil { - yyv4649 = []EnvVar{} - yyc4649 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []EnvVar{} + yyc1 = true } } - yyh4649.End() - if yyc4649 { - *v = yyv4649 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58343,10 +70876,10 @@ func (x codecSelfer1234) encSliceVolumeMount(v []VolumeMount, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4653 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4654 := &yyv4653 - yy4654.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58356,83 +70889,86 @@ func (x codecSelfer1234) decSliceVolumeMount(v *[]VolumeMount, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4655 := *v - yyh4655, yyl4655 := z.DecSliceHelperStart() - var yyc4655 bool - if yyl4655 == 0 { - if yyv4655 == nil { - yyv4655 = []VolumeMount{} - yyc4655 = true - } else if len(yyv4655) != 0 { - yyv4655 = yyv4655[:0] - yyc4655 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []VolumeMount{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4655 > 0 { - var yyrr4655, yyrl4655 int - var yyrt4655 bool - if yyl4655 > cap(yyv4655) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4655 := len(yyv4655) > 0 - yyv24655 := yyv4655 - yyrl4655, yyrt4655 = z.DecInferLen(yyl4655, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4655 { - if yyrl4655 <= cap(yyv4655) { - yyv4655 = yyv4655[:yyrl4655] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4655 = make([]VolumeMount, yyrl4655) + yyv1 = make([]VolumeMount, yyrl1) } } else { - yyv4655 = make([]VolumeMount, yyrl4655) + yyv1 = make([]VolumeMount, yyrl1) } - yyc4655 = true - yyrr4655 = len(yyv4655) - if yyrg4655 { - copy(yyv4655, yyv24655) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4655 != len(yyv4655) { - yyv4655 = yyv4655[:yyl4655] - yyc4655 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4655 := 0 - for ; yyj4655 < yyrr4655; yyj4655++ { - yyh4655.ElemContainerState(yyj4655) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4655[yyj4655] = VolumeMount{} + yyv1[yyj1] = VolumeMount{} } else { - yyv4656 := &yyv4655[yyj4655] - yyv4656.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4655 { - for ; yyj4655 < yyl4655; yyj4655++ { - yyv4655 = append(yyv4655, VolumeMount{}) - yyh4655.ElemContainerState(yyj4655) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, VolumeMount{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4655[yyj4655] = VolumeMount{} + yyv1[yyj1] = VolumeMount{} } else { - yyv4657 := &yyv4655[yyj4655] - yyv4657.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4655 := 0 - for ; !r.CheckBreak(); yyj4655++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4655 >= len(yyv4655) { - yyv4655 = append(yyv4655, VolumeMount{}) // var yyz4655 VolumeMount - yyc4655 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, VolumeMount{}) // var yyz1 VolumeMount + yyc1 = true } - yyh4655.ElemContainerState(yyj4655) - if yyj4655 < len(yyv4655) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4655[yyj4655] = VolumeMount{} + yyv1[yyj1] = VolumeMount{} } else { - yyv4658 := &yyv4655[yyj4655] - yyv4658.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58440,17 +70976,17 @@ func (x codecSelfer1234) decSliceVolumeMount(v *[]VolumeMount, d *codec1978.Deco } } - if yyj4655 < len(yyv4655) { - yyv4655 = yyv4655[:yyj4655] - yyc4655 = true - } else if yyj4655 == 0 && yyv4655 == nil { - yyv4655 = []VolumeMount{} - yyc4655 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []VolumeMount{} + yyc1 = true } } - yyh4655.End() - if yyc4655 { - *v = yyv4655 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58459,10 +70995,10 @@ func (x codecSelfer1234) encSliceNodeSelectorTerm(v []NodeSelectorTerm, e *codec z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4659 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4660 := &yyv4659 - yy4660.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58472,83 +71008,86 @@ func (x codecSelfer1234) decSliceNodeSelectorTerm(v *[]NodeSelectorTerm, d *code z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4661 := *v - yyh4661, yyl4661 := z.DecSliceHelperStart() - var yyc4661 bool - if yyl4661 == 0 { - if yyv4661 == nil { - yyv4661 = []NodeSelectorTerm{} - yyc4661 = true - } else if len(yyv4661) != 0 { - yyv4661 = yyv4661[:0] - yyc4661 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NodeSelectorTerm{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4661 > 0 { - var yyrr4661, yyrl4661 int - var yyrt4661 bool - if yyl4661 > cap(yyv4661) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4661 := len(yyv4661) > 0 - yyv24661 := yyv4661 - yyrl4661, yyrt4661 = z.DecInferLen(yyl4661, z.DecBasicHandle().MaxInitLen, 24) - if yyrt4661 { - if yyrl4661 <= cap(yyv4661) { - yyv4661 = yyv4661[:yyrl4661] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 24) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4661 = make([]NodeSelectorTerm, yyrl4661) + yyv1 = make([]NodeSelectorTerm, yyrl1) } } else { - yyv4661 = make([]NodeSelectorTerm, yyrl4661) + yyv1 = make([]NodeSelectorTerm, yyrl1) } - yyc4661 = true - yyrr4661 = len(yyv4661) - if yyrg4661 { - copy(yyv4661, yyv24661) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4661 != len(yyv4661) { - yyv4661 = yyv4661[:yyl4661] - yyc4661 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4661 := 0 - for ; yyj4661 < yyrr4661; yyj4661++ { - yyh4661.ElemContainerState(yyj4661) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4661[yyj4661] = NodeSelectorTerm{} + yyv1[yyj1] = NodeSelectorTerm{} } else { - yyv4662 := &yyv4661[yyj4661] - yyv4662.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4661 { - for ; yyj4661 < yyl4661; yyj4661++ { - yyv4661 = append(yyv4661, NodeSelectorTerm{}) - yyh4661.ElemContainerState(yyj4661) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NodeSelectorTerm{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4661[yyj4661] = NodeSelectorTerm{} + yyv1[yyj1] = NodeSelectorTerm{} } else { - yyv4663 := &yyv4661[yyj4661] - yyv4663.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4661 := 0 - for ; !r.CheckBreak(); yyj4661++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4661 >= len(yyv4661) { - yyv4661 = append(yyv4661, NodeSelectorTerm{}) // var yyz4661 NodeSelectorTerm - yyc4661 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NodeSelectorTerm{}) // var yyz1 NodeSelectorTerm + yyc1 = true } - yyh4661.ElemContainerState(yyj4661) - if yyj4661 < len(yyv4661) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4661[yyj4661] = NodeSelectorTerm{} + yyv1[yyj1] = NodeSelectorTerm{} } else { - yyv4664 := &yyv4661[yyj4661] - yyv4664.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58556,17 +71095,17 @@ func (x codecSelfer1234) decSliceNodeSelectorTerm(v *[]NodeSelectorTerm, d *code } } - if yyj4661 < len(yyv4661) { - yyv4661 = yyv4661[:yyj4661] - yyc4661 = true - } else if yyj4661 == 0 && yyv4661 == nil { - yyv4661 = []NodeSelectorTerm{} - yyc4661 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NodeSelectorTerm{} + yyc1 = true } } - yyh4661.End() - if yyc4661 { - *v = yyv4661 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58575,10 +71114,10 @@ func (x codecSelfer1234) encSliceNodeSelectorRequirement(v []NodeSelectorRequire z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4665 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4666 := &yyv4665 - yy4666.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58588,83 +71127,86 @@ func (x codecSelfer1234) decSliceNodeSelectorRequirement(v *[]NodeSelectorRequir z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4667 := *v - yyh4667, yyl4667 := z.DecSliceHelperStart() - var yyc4667 bool - if yyl4667 == 0 { - if yyv4667 == nil { - yyv4667 = []NodeSelectorRequirement{} - yyc4667 = true - } else if len(yyv4667) != 0 { - yyv4667 = yyv4667[:0] - yyc4667 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NodeSelectorRequirement{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4667 > 0 { - var yyrr4667, yyrl4667 int - var yyrt4667 bool - if yyl4667 > cap(yyv4667) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4667 := len(yyv4667) > 0 - yyv24667 := yyv4667 - yyrl4667, yyrt4667 = z.DecInferLen(yyl4667, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4667 { - if yyrl4667 <= cap(yyv4667) { - yyv4667 = yyv4667[:yyrl4667] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4667 = make([]NodeSelectorRequirement, yyrl4667) + yyv1 = make([]NodeSelectorRequirement, yyrl1) } } else { - yyv4667 = make([]NodeSelectorRequirement, yyrl4667) + yyv1 = make([]NodeSelectorRequirement, yyrl1) } - yyc4667 = true - yyrr4667 = len(yyv4667) - if yyrg4667 { - copy(yyv4667, yyv24667) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4667 != len(yyv4667) { - yyv4667 = yyv4667[:yyl4667] - yyc4667 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4667 := 0 - for ; yyj4667 < yyrr4667; yyj4667++ { - yyh4667.ElemContainerState(yyj4667) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4667[yyj4667] = NodeSelectorRequirement{} + yyv1[yyj1] = NodeSelectorRequirement{} } else { - yyv4668 := &yyv4667[yyj4667] - yyv4668.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4667 { - for ; yyj4667 < yyl4667; yyj4667++ { - yyv4667 = append(yyv4667, NodeSelectorRequirement{}) - yyh4667.ElemContainerState(yyj4667) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NodeSelectorRequirement{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4667[yyj4667] = NodeSelectorRequirement{} + yyv1[yyj1] = NodeSelectorRequirement{} } else { - yyv4669 := &yyv4667[yyj4667] - yyv4669.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4667 := 0 - for ; !r.CheckBreak(); yyj4667++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4667 >= len(yyv4667) { - yyv4667 = append(yyv4667, NodeSelectorRequirement{}) // var yyz4667 NodeSelectorRequirement - yyc4667 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NodeSelectorRequirement{}) // var yyz1 NodeSelectorRequirement + yyc1 = true } - yyh4667.ElemContainerState(yyj4667) - if yyj4667 < len(yyv4667) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4667[yyj4667] = NodeSelectorRequirement{} + yyv1[yyj1] = NodeSelectorRequirement{} } else { - yyv4670 := &yyv4667[yyj4667] - yyv4670.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58672,17 +71214,17 @@ func (x codecSelfer1234) decSliceNodeSelectorRequirement(v *[]NodeSelectorRequir } } - if yyj4667 < len(yyv4667) { - yyv4667 = yyv4667[:yyj4667] - yyc4667 = true - } else if yyj4667 == 0 && yyv4667 == nil { - yyv4667 = []NodeSelectorRequirement{} - yyc4667 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NodeSelectorRequirement{} + yyc1 = true } } - yyh4667.End() - if yyc4667 { - *v = yyv4667 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58691,10 +71233,10 @@ func (x codecSelfer1234) encSlicePodAffinityTerm(v []PodAffinityTerm, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4671 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4672 := &yyv4671 - yy4672.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58704,83 +71246,86 @@ func (x codecSelfer1234) decSlicePodAffinityTerm(v *[]PodAffinityTerm, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4673 := *v - yyh4673, yyl4673 := z.DecSliceHelperStart() - var yyc4673 bool - if yyl4673 == 0 { - if yyv4673 == nil { - yyv4673 = []PodAffinityTerm{} - yyc4673 = true - } else if len(yyv4673) != 0 { - yyv4673 = yyv4673[:0] - yyc4673 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PodAffinityTerm{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4673 > 0 { - var yyrr4673, yyrl4673 int - var yyrt4673 bool - if yyl4673 > cap(yyv4673) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4673 := len(yyv4673) > 0 - yyv24673 := yyv4673 - yyrl4673, yyrt4673 = z.DecInferLen(yyl4673, z.DecBasicHandle().MaxInitLen, 48) - if yyrt4673 { - if yyrl4673 <= cap(yyv4673) { - yyv4673 = yyv4673[:yyrl4673] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4673 = make([]PodAffinityTerm, yyrl4673) + yyv1 = make([]PodAffinityTerm, yyrl1) } } else { - yyv4673 = make([]PodAffinityTerm, yyrl4673) + yyv1 = make([]PodAffinityTerm, yyrl1) } - yyc4673 = true - yyrr4673 = len(yyv4673) - if yyrg4673 { - copy(yyv4673, yyv24673) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4673 != len(yyv4673) { - yyv4673 = yyv4673[:yyl4673] - yyc4673 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4673 := 0 - for ; yyj4673 < yyrr4673; yyj4673++ { - yyh4673.ElemContainerState(yyj4673) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4673[yyj4673] = PodAffinityTerm{} + yyv1[yyj1] = PodAffinityTerm{} } else { - yyv4674 := &yyv4673[yyj4673] - yyv4674.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4673 { - for ; yyj4673 < yyl4673; yyj4673++ { - yyv4673 = append(yyv4673, PodAffinityTerm{}) - yyh4673.ElemContainerState(yyj4673) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PodAffinityTerm{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4673[yyj4673] = PodAffinityTerm{} + yyv1[yyj1] = PodAffinityTerm{} } else { - yyv4675 := &yyv4673[yyj4673] - yyv4675.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4673 := 0 - for ; !r.CheckBreak(); yyj4673++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4673 >= len(yyv4673) { - yyv4673 = append(yyv4673, PodAffinityTerm{}) // var yyz4673 PodAffinityTerm - yyc4673 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PodAffinityTerm{}) // var yyz1 PodAffinityTerm + yyc1 = true } - yyh4673.ElemContainerState(yyj4673) - if yyj4673 < len(yyv4673) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4673[yyj4673] = PodAffinityTerm{} + yyv1[yyj1] = PodAffinityTerm{} } else { - yyv4676 := &yyv4673[yyj4673] - yyv4676.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58788,17 +71333,17 @@ func (x codecSelfer1234) decSlicePodAffinityTerm(v *[]PodAffinityTerm, d *codec1 } } - if yyj4673 < len(yyv4673) { - yyv4673 = yyv4673[:yyj4673] - yyc4673 = true - } else if yyj4673 == 0 && yyv4673 == nil { - yyv4673 = []PodAffinityTerm{} - yyc4673 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PodAffinityTerm{} + yyc1 = true } } - yyh4673.End() - if yyc4673 { - *v = yyv4673 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58807,10 +71352,10 @@ func (x codecSelfer1234) encSliceWeightedPodAffinityTerm(v []WeightedPodAffinity z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4677 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4678 := &yyv4677 - yy4678.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58820,83 +71365,86 @@ func (x codecSelfer1234) decSliceWeightedPodAffinityTerm(v *[]WeightedPodAffinit z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4679 := *v - yyh4679, yyl4679 := z.DecSliceHelperStart() - var yyc4679 bool - if yyl4679 == 0 { - if yyv4679 == nil { - yyv4679 = []WeightedPodAffinityTerm{} - yyc4679 = true - } else if len(yyv4679) != 0 { - yyv4679 = yyv4679[:0] - yyc4679 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []WeightedPodAffinityTerm{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4679 > 0 { - var yyrr4679, yyrl4679 int - var yyrt4679 bool - if yyl4679 > cap(yyv4679) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4679 := len(yyv4679) > 0 - yyv24679 := yyv4679 - yyrl4679, yyrt4679 = z.DecInferLen(yyl4679, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4679 { - if yyrl4679 <= cap(yyv4679) { - yyv4679 = yyv4679[:yyrl4679] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4679 = make([]WeightedPodAffinityTerm, yyrl4679) + yyv1 = make([]WeightedPodAffinityTerm, yyrl1) } } else { - yyv4679 = make([]WeightedPodAffinityTerm, yyrl4679) + yyv1 = make([]WeightedPodAffinityTerm, yyrl1) } - yyc4679 = true - yyrr4679 = len(yyv4679) - if yyrg4679 { - copy(yyv4679, yyv24679) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4679 != len(yyv4679) { - yyv4679 = yyv4679[:yyl4679] - yyc4679 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4679 := 0 - for ; yyj4679 < yyrr4679; yyj4679++ { - yyh4679.ElemContainerState(yyj4679) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4679[yyj4679] = WeightedPodAffinityTerm{} + yyv1[yyj1] = WeightedPodAffinityTerm{} } else { - yyv4680 := &yyv4679[yyj4679] - yyv4680.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4679 { - for ; yyj4679 < yyl4679; yyj4679++ { - yyv4679 = append(yyv4679, WeightedPodAffinityTerm{}) - yyh4679.ElemContainerState(yyj4679) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, WeightedPodAffinityTerm{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4679[yyj4679] = WeightedPodAffinityTerm{} + yyv1[yyj1] = WeightedPodAffinityTerm{} } else { - yyv4681 := &yyv4679[yyj4679] - yyv4681.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4679 := 0 - for ; !r.CheckBreak(); yyj4679++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4679 >= len(yyv4679) { - yyv4679 = append(yyv4679, WeightedPodAffinityTerm{}) // var yyz4679 WeightedPodAffinityTerm - yyc4679 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, WeightedPodAffinityTerm{}) // var yyz1 WeightedPodAffinityTerm + yyc1 = true } - yyh4679.ElemContainerState(yyj4679) - if yyj4679 < len(yyv4679) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4679[yyj4679] = WeightedPodAffinityTerm{} + yyv1[yyj1] = WeightedPodAffinityTerm{} } else { - yyv4682 := &yyv4679[yyj4679] - yyv4682.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -58904,17 +71452,17 @@ func (x codecSelfer1234) decSliceWeightedPodAffinityTerm(v *[]WeightedPodAffinit } } - if yyj4679 < len(yyv4679) { - yyv4679 = yyv4679[:yyj4679] - yyc4679 = true - } else if yyj4679 == 0 && yyv4679 == nil { - yyv4679 = []WeightedPodAffinityTerm{} - yyc4679 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []WeightedPodAffinityTerm{} + yyc1 = true } } - yyh4679.End() - if yyc4679 { - *v = yyv4679 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -58923,10 +71471,10 @@ func (x codecSelfer1234) encSlicePreferredSchedulingTerm(v []PreferredScheduling z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4683 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4684 := &yyv4683 - yy4684.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -58936,83 +71484,86 @@ func (x codecSelfer1234) decSlicePreferredSchedulingTerm(v *[]PreferredSchedulin z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4685 := *v - yyh4685, yyl4685 := z.DecSliceHelperStart() - var yyc4685 bool - if yyl4685 == 0 { - if yyv4685 == nil { - yyv4685 = []PreferredSchedulingTerm{} - yyc4685 = true - } else if len(yyv4685) != 0 { - yyv4685 = yyv4685[:0] - yyc4685 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PreferredSchedulingTerm{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4685 > 0 { - var yyrr4685, yyrl4685 int - var yyrt4685 bool - if yyl4685 > cap(yyv4685) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4685 := len(yyv4685) > 0 - yyv24685 := yyv4685 - yyrl4685, yyrt4685 = z.DecInferLen(yyl4685, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4685 { - if yyrl4685 <= cap(yyv4685) { - yyv4685 = yyv4685[:yyrl4685] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4685 = make([]PreferredSchedulingTerm, yyrl4685) + yyv1 = make([]PreferredSchedulingTerm, yyrl1) } } else { - yyv4685 = make([]PreferredSchedulingTerm, yyrl4685) + yyv1 = make([]PreferredSchedulingTerm, yyrl1) } - yyc4685 = true - yyrr4685 = len(yyv4685) - if yyrg4685 { - copy(yyv4685, yyv24685) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4685 != len(yyv4685) { - yyv4685 = yyv4685[:yyl4685] - yyc4685 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4685 := 0 - for ; yyj4685 < yyrr4685; yyj4685++ { - yyh4685.ElemContainerState(yyj4685) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4685[yyj4685] = PreferredSchedulingTerm{} + yyv1[yyj1] = PreferredSchedulingTerm{} } else { - yyv4686 := &yyv4685[yyj4685] - yyv4686.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4685 { - for ; yyj4685 < yyl4685; yyj4685++ { - yyv4685 = append(yyv4685, PreferredSchedulingTerm{}) - yyh4685.ElemContainerState(yyj4685) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PreferredSchedulingTerm{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4685[yyj4685] = PreferredSchedulingTerm{} + yyv1[yyj1] = PreferredSchedulingTerm{} } else { - yyv4687 := &yyv4685[yyj4685] - yyv4687.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4685 := 0 - for ; !r.CheckBreak(); yyj4685++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4685 >= len(yyv4685) { - yyv4685 = append(yyv4685, PreferredSchedulingTerm{}) // var yyz4685 PreferredSchedulingTerm - yyc4685 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PreferredSchedulingTerm{}) // var yyz1 PreferredSchedulingTerm + yyc1 = true } - yyh4685.ElemContainerState(yyj4685) - if yyj4685 < len(yyv4685) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4685[yyj4685] = PreferredSchedulingTerm{} + yyv1[yyj1] = PreferredSchedulingTerm{} } else { - yyv4688 := &yyv4685[yyj4685] - yyv4688.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59020,17 +71571,17 @@ func (x codecSelfer1234) decSlicePreferredSchedulingTerm(v *[]PreferredSchedulin } } - if yyj4685 < len(yyv4685) { - yyv4685 = yyv4685[:yyj4685] - yyc4685 = true - } else if yyj4685 == 0 && yyv4685 == nil { - yyv4685 = []PreferredSchedulingTerm{} - yyc4685 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PreferredSchedulingTerm{} + yyc1 = true } } - yyh4685.End() - if yyc4685 { - *v = yyv4685 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59039,10 +71590,10 @@ func (x codecSelfer1234) encSliceVolume(v []Volume, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4689 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4690 := &yyv4689 - yy4690.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59052,83 +71603,86 @@ func (x codecSelfer1234) decSliceVolume(v *[]Volume, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4691 := *v - yyh4691, yyl4691 := z.DecSliceHelperStart() - var yyc4691 bool - if yyl4691 == 0 { - if yyv4691 == nil { - yyv4691 = []Volume{} - yyc4691 = true - } else if len(yyv4691) != 0 { - yyv4691 = yyv4691[:0] - yyc4691 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Volume{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4691 > 0 { - var yyrr4691, yyrl4691 int - var yyrt4691 bool - if yyl4691 > cap(yyv4691) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4691 := len(yyv4691) > 0 - yyv24691 := yyv4691 - yyrl4691, yyrt4691 = z.DecInferLen(yyl4691, z.DecBasicHandle().MaxInitLen, 200) - if yyrt4691 { - if yyrl4691 <= cap(yyv4691) { - yyv4691 = yyv4691[:yyrl4691] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 232) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4691 = make([]Volume, yyrl4691) + yyv1 = make([]Volume, yyrl1) } } else { - yyv4691 = make([]Volume, yyrl4691) + yyv1 = make([]Volume, yyrl1) } - yyc4691 = true - yyrr4691 = len(yyv4691) - if yyrg4691 { - copy(yyv4691, yyv24691) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4691 != len(yyv4691) { - yyv4691 = yyv4691[:yyl4691] - yyc4691 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4691 := 0 - for ; yyj4691 < yyrr4691; yyj4691++ { - yyh4691.ElemContainerState(yyj4691) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4691[yyj4691] = Volume{} + yyv1[yyj1] = Volume{} } else { - yyv4692 := &yyv4691[yyj4691] - yyv4692.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4691 { - for ; yyj4691 < yyl4691; yyj4691++ { - yyv4691 = append(yyv4691, Volume{}) - yyh4691.ElemContainerState(yyj4691) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Volume{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4691[yyj4691] = Volume{} + yyv1[yyj1] = Volume{} } else { - yyv4693 := &yyv4691[yyj4691] - yyv4693.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4691 := 0 - for ; !r.CheckBreak(); yyj4691++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4691 >= len(yyv4691) { - yyv4691 = append(yyv4691, Volume{}) // var yyz4691 Volume - yyc4691 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Volume{}) // var yyz1 Volume + yyc1 = true } - yyh4691.ElemContainerState(yyj4691) - if yyj4691 < len(yyv4691) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4691[yyj4691] = Volume{} + yyv1[yyj1] = Volume{} } else { - yyv4694 := &yyv4691[yyj4691] - yyv4694.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59136,17 +71690,17 @@ func (x codecSelfer1234) decSliceVolume(v *[]Volume, d *codec1978.Decoder) { } } - if yyj4691 < len(yyv4691) { - yyv4691 = yyv4691[:yyj4691] - yyc4691 = true - } else if yyj4691 == 0 && yyv4691 == nil { - yyv4691 = []Volume{} - yyc4691 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Volume{} + yyc1 = true } } - yyh4691.End() - if yyc4691 { - *v = yyv4691 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59155,10 +71709,10 @@ func (x codecSelfer1234) encSliceContainer(v []Container, e *codec1978.Encoder) z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4695 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4696 := &yyv4695 - yy4696.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59168,83 +71722,86 @@ func (x codecSelfer1234) decSliceContainer(v *[]Container, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4697 := *v - yyh4697, yyl4697 := z.DecSliceHelperStart() - var yyc4697 bool - if yyl4697 == 0 { - if yyv4697 == nil { - yyv4697 = []Container{} - yyc4697 = true - } else if len(yyv4697) != 0 { - yyv4697 = yyv4697[:0] - yyc4697 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Container{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4697 > 0 { - var yyrr4697, yyrl4697 int - var yyrt4697 bool - if yyl4697 > cap(yyv4697) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4697 := len(yyv4697) > 0 - yyv24697 := yyv4697 - yyrl4697, yyrt4697 = z.DecInferLen(yyl4697, z.DecBasicHandle().MaxInitLen, 256) - if yyrt4697 { - if yyrl4697 <= cap(yyv4697) { - yyv4697 = yyv4697[:yyrl4697] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 296) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4697 = make([]Container, yyrl4697) + yyv1 = make([]Container, yyrl1) } } else { - yyv4697 = make([]Container, yyrl4697) + yyv1 = make([]Container, yyrl1) } - yyc4697 = true - yyrr4697 = len(yyv4697) - if yyrg4697 { - copy(yyv4697, yyv24697) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4697 != len(yyv4697) { - yyv4697 = yyv4697[:yyl4697] - yyc4697 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4697 := 0 - for ; yyj4697 < yyrr4697; yyj4697++ { - yyh4697.ElemContainerState(yyj4697) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4697[yyj4697] = Container{} + yyv1[yyj1] = Container{} } else { - yyv4698 := &yyv4697[yyj4697] - yyv4698.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4697 { - for ; yyj4697 < yyl4697; yyj4697++ { - yyv4697 = append(yyv4697, Container{}) - yyh4697.ElemContainerState(yyj4697) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Container{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4697[yyj4697] = Container{} + yyv1[yyj1] = Container{} } else { - yyv4699 := &yyv4697[yyj4697] - yyv4699.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4697 := 0 - for ; !r.CheckBreak(); yyj4697++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4697 >= len(yyv4697) { - yyv4697 = append(yyv4697, Container{}) // var yyz4697 Container - yyc4697 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Container{}) // var yyz1 Container + yyc1 = true } - yyh4697.ElemContainerState(yyj4697) - if yyj4697 < len(yyv4697) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4697[yyj4697] = Container{} + yyv1[yyj1] = Container{} } else { - yyv4700 := &yyv4697[yyj4697] - yyv4700.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59252,17 +71809,17 @@ func (x codecSelfer1234) decSliceContainer(v *[]Container, d *codec1978.Decoder) } } - if yyj4697 < len(yyv4697) { - yyv4697 = yyv4697[:yyj4697] - yyc4697 = true - } else if yyj4697 == 0 && yyv4697 == nil { - yyv4697 = []Container{} - yyc4697 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Container{} + yyc1 = true } } - yyh4697.End() - if yyc4697 { - *v = yyv4697 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59271,10 +71828,10 @@ func (x codecSelfer1234) encSliceLocalObjectReference(v []LocalObjectReference, z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4701 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4702 := &yyv4701 - yy4702.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59284,83 +71841,205 @@ func (x codecSelfer1234) decSliceLocalObjectReference(v *[]LocalObjectReference, z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4703 := *v - yyh4703, yyl4703 := z.DecSliceHelperStart() - var yyc4703 bool - if yyl4703 == 0 { - if yyv4703 == nil { - yyv4703 = []LocalObjectReference{} - yyc4703 = true - } else if len(yyv4703) != 0 { - yyv4703 = yyv4703[:0] - yyc4703 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []LocalObjectReference{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]LocalObjectReference, yyrl1) + } + } else { + yyv1 = make([]LocalObjectReference, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = LocalObjectReference{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, LocalObjectReference{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = LocalObjectReference{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, LocalObjectReference{}) // var yyz1 LocalObjectReference + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = LocalObjectReference{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []LocalObjectReference{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceToleration(v []Toleration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceToleration(v *[]Toleration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Toleration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4703 > 0 { - var yyrr4703, yyrl4703 int - var yyrt4703 bool - if yyl4703 > cap(yyv4703) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4703 := len(yyv4703) > 0 - yyv24703 := yyv4703 - yyrl4703, yyrt4703 = z.DecInferLen(yyl4703, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4703 { - if yyrl4703 <= cap(yyv4703) { - yyv4703 = yyv4703[:yyrl4703] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4703 = make([]LocalObjectReference, yyrl4703) + yyv1 = make([]Toleration, yyrl1) } } else { - yyv4703 = make([]LocalObjectReference, yyrl4703) + yyv1 = make([]Toleration, yyrl1) } - yyc4703 = true - yyrr4703 = len(yyv4703) - if yyrg4703 { - copy(yyv4703, yyv24703) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4703 != len(yyv4703) { - yyv4703 = yyv4703[:yyl4703] - yyc4703 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4703 := 0 - for ; yyj4703 < yyrr4703; yyj4703++ { - yyh4703.ElemContainerState(yyj4703) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4703[yyj4703] = LocalObjectReference{} + yyv1[yyj1] = Toleration{} } else { - yyv4704 := &yyv4703[yyj4703] - yyv4704.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4703 { - for ; yyj4703 < yyl4703; yyj4703++ { - yyv4703 = append(yyv4703, LocalObjectReference{}) - yyh4703.ElemContainerState(yyj4703) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Toleration{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4703[yyj4703] = LocalObjectReference{} + yyv1[yyj1] = Toleration{} } else { - yyv4705 := &yyv4703[yyj4703] - yyv4705.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4703 := 0 - for ; !r.CheckBreak(); yyj4703++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4703 >= len(yyv4703) { - yyv4703 = append(yyv4703, LocalObjectReference{}) // var yyz4703 LocalObjectReference - yyc4703 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Toleration{}) // var yyz1 Toleration + yyc1 = true } - yyh4703.ElemContainerState(yyj4703) - if yyj4703 < len(yyv4703) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4703[yyj4703] = LocalObjectReference{} + yyv1[yyj1] = Toleration{} } else { - yyv4706 := &yyv4703[yyj4703] - yyv4706.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59368,17 +72047,136 @@ func (x codecSelfer1234) decSliceLocalObjectReference(v *[]LocalObjectReference, } } - if yyj4703 < len(yyv4703) { - yyv4703 = yyv4703[:yyj4703] - yyc4703 = true - } else if yyj4703 == 0 && yyv4703 == nil { - yyv4703 = []LocalObjectReference{} - yyc4703 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Toleration{} + yyc1 = true } } - yyh4703.End() - if yyc4703 { - *v = yyv4703 + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceHostAlias(v []HostAlias, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceHostAlias(v *[]HostAlias, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HostAlias{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]HostAlias, yyrl1) + } + } else { + yyv1 = make([]HostAlias, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = HostAlias{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HostAlias{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = HostAlias{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HostAlias{}) // var yyz1 HostAlias + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = HostAlias{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HostAlias{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59387,10 +72185,10 @@ func (x codecSelfer1234) encSlicePodCondition(v []PodCondition, e *codec1978.Enc z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4707 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4708 := &yyv4707 - yy4708.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59400,83 +72198,86 @@ func (x codecSelfer1234) decSlicePodCondition(v *[]PodCondition, d *codec1978.De z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4709 := *v - yyh4709, yyl4709 := z.DecSliceHelperStart() - var yyc4709 bool - if yyl4709 == 0 { - if yyv4709 == nil { - yyv4709 = []PodCondition{} - yyc4709 = true - } else if len(yyv4709) != 0 { - yyv4709 = yyv4709[:0] - yyc4709 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PodCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4709 > 0 { - var yyrr4709, yyrl4709 int - var yyrt4709 bool - if yyl4709 > cap(yyv4709) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4709 := len(yyv4709) > 0 - yyv24709 := yyv4709 - yyrl4709, yyrt4709 = z.DecInferLen(yyl4709, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4709 { - if yyrl4709 <= cap(yyv4709) { - yyv4709 = yyv4709[:yyrl4709] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4709 = make([]PodCondition, yyrl4709) + yyv1 = make([]PodCondition, yyrl1) } } else { - yyv4709 = make([]PodCondition, yyrl4709) + yyv1 = make([]PodCondition, yyrl1) } - yyc4709 = true - yyrr4709 = len(yyv4709) - if yyrg4709 { - copy(yyv4709, yyv24709) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4709 != len(yyv4709) { - yyv4709 = yyv4709[:yyl4709] - yyc4709 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4709 := 0 - for ; yyj4709 < yyrr4709; yyj4709++ { - yyh4709.ElemContainerState(yyj4709) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4709[yyj4709] = PodCondition{} + yyv1[yyj1] = PodCondition{} } else { - yyv4710 := &yyv4709[yyj4709] - yyv4710.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4709 { - for ; yyj4709 < yyl4709; yyj4709++ { - yyv4709 = append(yyv4709, PodCondition{}) - yyh4709.ElemContainerState(yyj4709) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PodCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4709[yyj4709] = PodCondition{} + yyv1[yyj1] = PodCondition{} } else { - yyv4711 := &yyv4709[yyj4709] - yyv4711.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4709 := 0 - for ; !r.CheckBreak(); yyj4709++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4709 >= len(yyv4709) { - yyv4709 = append(yyv4709, PodCondition{}) // var yyz4709 PodCondition - yyc4709 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PodCondition{}) // var yyz1 PodCondition + yyc1 = true } - yyh4709.ElemContainerState(yyj4709) - if yyj4709 < len(yyv4709) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4709[yyj4709] = PodCondition{} + yyv1[yyj1] = PodCondition{} } else { - yyv4712 := &yyv4709[yyj4709] - yyv4712.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59484,17 +72285,17 @@ func (x codecSelfer1234) decSlicePodCondition(v *[]PodCondition, d *codec1978.De } } - if yyj4709 < len(yyv4709) { - yyv4709 = yyv4709[:yyj4709] - yyc4709 = true - } else if yyj4709 == 0 && yyv4709 == nil { - yyv4709 = []PodCondition{} - yyc4709 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PodCondition{} + yyc1 = true } } - yyh4709.End() - if yyc4709 { - *v = yyv4709 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59503,10 +72304,10 @@ func (x codecSelfer1234) encSliceContainerStatus(v []ContainerStatus, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4713 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4714 := &yyv4713 - yy4714.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59516,83 +72317,86 @@ func (x codecSelfer1234) decSliceContainerStatus(v *[]ContainerStatus, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4715 := *v - yyh4715, yyl4715 := z.DecSliceHelperStart() - var yyc4715 bool - if yyl4715 == 0 { - if yyv4715 == nil { - yyv4715 = []ContainerStatus{} - yyc4715 = true - } else if len(yyv4715) != 0 { - yyv4715 = yyv4715[:0] - yyc4715 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ContainerStatus{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4715 > 0 { - var yyrr4715, yyrl4715 int - var yyrt4715 bool - if yyl4715 > cap(yyv4715) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4715 := len(yyv4715) > 0 - yyv24715 := yyv4715 - yyrl4715, yyrt4715 = z.DecInferLen(yyl4715, z.DecBasicHandle().MaxInitLen, 120) - if yyrt4715 { - if yyrl4715 <= cap(yyv4715) { - yyv4715 = yyv4715[:yyrl4715] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 120) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4715 = make([]ContainerStatus, yyrl4715) + yyv1 = make([]ContainerStatus, yyrl1) } } else { - yyv4715 = make([]ContainerStatus, yyrl4715) + yyv1 = make([]ContainerStatus, yyrl1) } - yyc4715 = true - yyrr4715 = len(yyv4715) - if yyrg4715 { - copy(yyv4715, yyv24715) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4715 != len(yyv4715) { - yyv4715 = yyv4715[:yyl4715] - yyc4715 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4715 := 0 - for ; yyj4715 < yyrr4715; yyj4715++ { - yyh4715.ElemContainerState(yyj4715) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4715[yyj4715] = ContainerStatus{} + yyv1[yyj1] = ContainerStatus{} } else { - yyv4716 := &yyv4715[yyj4715] - yyv4716.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4715 { - for ; yyj4715 < yyl4715; yyj4715++ { - yyv4715 = append(yyv4715, ContainerStatus{}) - yyh4715.ElemContainerState(yyj4715) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ContainerStatus{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4715[yyj4715] = ContainerStatus{} + yyv1[yyj1] = ContainerStatus{} } else { - yyv4717 := &yyv4715[yyj4715] - yyv4717.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4715 := 0 - for ; !r.CheckBreak(); yyj4715++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4715 >= len(yyv4715) { - yyv4715 = append(yyv4715, ContainerStatus{}) // var yyz4715 ContainerStatus - yyc4715 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ContainerStatus{}) // var yyz1 ContainerStatus + yyc1 = true } - yyh4715.ElemContainerState(yyj4715) - if yyj4715 < len(yyv4715) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4715[yyj4715] = ContainerStatus{} + yyv1[yyj1] = ContainerStatus{} } else { - yyv4718 := &yyv4715[yyj4715] - yyv4718.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59600,17 +72404,17 @@ func (x codecSelfer1234) decSliceContainerStatus(v *[]ContainerStatus, d *codec1 } } - if yyj4715 < len(yyv4715) { - yyv4715 = yyv4715[:yyj4715] - yyc4715 = true - } else if yyj4715 == 0 && yyv4715 == nil { - yyv4715 = []ContainerStatus{} - yyc4715 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ContainerStatus{} + yyc1 = true } } - yyh4715.End() - if yyc4715 { - *v = yyv4715 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59619,10 +72423,10 @@ func (x codecSelfer1234) encSlicePod(v []Pod, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4719 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4720 := &yyv4719 - yy4720.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59632,83 +72436,86 @@ func (x codecSelfer1234) decSlicePod(v *[]Pod, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4721 := *v - yyh4721, yyl4721 := z.DecSliceHelperStart() - var yyc4721 bool - if yyl4721 == 0 { - if yyv4721 == nil { - yyv4721 = []Pod{} - yyc4721 = true - } else if len(yyv4721) != 0 { - yyv4721 = yyv4721[:0] - yyc4721 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Pod{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4721 > 0 { - var yyrr4721, yyrl4721 int - var yyrt4721 bool - if yyl4721 > cap(yyv4721) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4721 := len(yyv4721) > 0 - yyv24721 := yyv4721 - yyrl4721, yyrt4721 = z.DecInferLen(yyl4721, z.DecBasicHandle().MaxInitLen, 664) - if yyrt4721 { - if yyrl4721 <= cap(yyv4721) { - yyv4721 = yyv4721[:yyrl4721] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 768) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4721 = make([]Pod, yyrl4721) + yyv1 = make([]Pod, yyrl1) } } else { - yyv4721 = make([]Pod, yyrl4721) + yyv1 = make([]Pod, yyrl1) } - yyc4721 = true - yyrr4721 = len(yyv4721) - if yyrg4721 { - copy(yyv4721, yyv24721) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4721 != len(yyv4721) { - yyv4721 = yyv4721[:yyl4721] - yyc4721 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4721 := 0 - for ; yyj4721 < yyrr4721; yyj4721++ { - yyh4721.ElemContainerState(yyj4721) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4721[yyj4721] = Pod{} + yyv1[yyj1] = Pod{} } else { - yyv4722 := &yyv4721[yyj4721] - yyv4722.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4721 { - for ; yyj4721 < yyl4721; yyj4721++ { - yyv4721 = append(yyv4721, Pod{}) - yyh4721.ElemContainerState(yyj4721) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Pod{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4721[yyj4721] = Pod{} + yyv1[yyj1] = Pod{} } else { - yyv4723 := &yyv4721[yyj4721] - yyv4723.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4721 := 0 - for ; !r.CheckBreak(); yyj4721++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4721 >= len(yyv4721) { - yyv4721 = append(yyv4721, Pod{}) // var yyz4721 Pod - yyc4721 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Pod{}) // var yyz1 Pod + yyc1 = true } - yyh4721.ElemContainerState(yyj4721) - if yyj4721 < len(yyv4721) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4721[yyj4721] = Pod{} + yyv1[yyj1] = Pod{} } else { - yyv4724 := &yyv4721[yyj4721] - yyv4724.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59716,17 +72523,17 @@ func (x codecSelfer1234) decSlicePod(v *[]Pod, d *codec1978.Decoder) { } } - if yyj4721 < len(yyv4721) { - yyv4721 = yyv4721[:yyj4721] - yyc4721 = true - } else if yyj4721 == 0 && yyv4721 == nil { - yyv4721 = []Pod{} - yyc4721 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Pod{} + yyc1 = true } } - yyh4721.End() - if yyc4721 { - *v = yyv4721 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59735,10 +72542,10 @@ func (x codecSelfer1234) encSlicePodTemplate(v []PodTemplate, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4725 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4726 := &yyv4725 - yy4726.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59748,83 +72555,86 @@ func (x codecSelfer1234) decSlicePodTemplate(v *[]PodTemplate, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4727 := *v - yyh4727, yyl4727 := z.DecSliceHelperStart() - var yyc4727 bool - if yyl4727 == 0 { - if yyv4727 == nil { - yyv4727 = []PodTemplate{} - yyc4727 = true - } else if len(yyv4727) != 0 { - yyv4727 = yyv4727[:0] - yyc4727 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PodTemplate{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4727 > 0 { - var yyrr4727, yyrl4727 int - var yyrt4727 bool - if yyl4727 > cap(yyv4727) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4727 := len(yyv4727) > 0 - yyv24727 := yyv4727 - yyrl4727, yyrt4727 = z.DecInferLen(yyl4727, z.DecBasicHandle().MaxInitLen, 728) - if yyrt4727 { - if yyrl4727 <= cap(yyv4727) { - yyv4727 = yyv4727[:yyrl4727] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 824) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4727 = make([]PodTemplate, yyrl4727) + yyv1 = make([]PodTemplate, yyrl1) } } else { - yyv4727 = make([]PodTemplate, yyrl4727) + yyv1 = make([]PodTemplate, yyrl1) } - yyc4727 = true - yyrr4727 = len(yyv4727) - if yyrg4727 { - copy(yyv4727, yyv24727) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4727 != len(yyv4727) { - yyv4727 = yyv4727[:yyl4727] - yyc4727 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4727 := 0 - for ; yyj4727 < yyrr4727; yyj4727++ { - yyh4727.ElemContainerState(yyj4727) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4727[yyj4727] = PodTemplate{} + yyv1[yyj1] = PodTemplate{} } else { - yyv4728 := &yyv4727[yyj4727] - yyv4728.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4727 { - for ; yyj4727 < yyl4727; yyj4727++ { - yyv4727 = append(yyv4727, PodTemplate{}) - yyh4727.ElemContainerState(yyj4727) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PodTemplate{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4727[yyj4727] = PodTemplate{} + yyv1[yyj1] = PodTemplate{} } else { - yyv4729 := &yyv4727[yyj4727] - yyv4729.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4727 := 0 - for ; !r.CheckBreak(); yyj4727++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4727 >= len(yyv4727) { - yyv4727 = append(yyv4727, PodTemplate{}) // var yyz4727 PodTemplate - yyc4727 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PodTemplate{}) // var yyz1 PodTemplate + yyc1 = true } - yyh4727.ElemContainerState(yyj4727) - if yyj4727 < len(yyv4727) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4727[yyj4727] = PodTemplate{} + yyv1[yyj1] = PodTemplate{} } else { - yyv4730 := &yyv4727[yyj4727] - yyv4730.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59832,17 +72642,17 @@ func (x codecSelfer1234) decSlicePodTemplate(v *[]PodTemplate, d *codec1978.Deco } } - if yyj4727 < len(yyv4727) { - yyv4727 = yyv4727[:yyj4727] - yyc4727 = true - } else if yyj4727 == 0 && yyv4727 == nil { - yyv4727 = []PodTemplate{} - yyc4727 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PodTemplate{} + yyc1 = true } } - yyh4727.End() - if yyc4727 { - *v = yyv4727 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59851,10 +72661,10 @@ func (x codecSelfer1234) encSliceReplicationControllerCondition(v []ReplicationC z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4731 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4732 := &yyv4731 - yy4732.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59864,83 +72674,86 @@ func (x codecSelfer1234) decSliceReplicationControllerCondition(v *[]Replication z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4733 := *v - yyh4733, yyl4733 := z.DecSliceHelperStart() - var yyc4733 bool - if yyl4733 == 0 { - if yyv4733 == nil { - yyv4733 = []ReplicationControllerCondition{} - yyc4733 = true - } else if len(yyv4733) != 0 { - yyv4733 = yyv4733[:0] - yyc4733 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ReplicationControllerCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4733 > 0 { - var yyrr4733, yyrl4733 int - var yyrt4733 bool - if yyl4733 > cap(yyv4733) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4733 := len(yyv4733) > 0 - yyv24733 := yyv4733 - yyrl4733, yyrt4733 = z.DecInferLen(yyl4733, z.DecBasicHandle().MaxInitLen, 88) - if yyrt4733 { - if yyrl4733 <= cap(yyv4733) { - yyv4733 = yyv4733[:yyrl4733] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 88) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4733 = make([]ReplicationControllerCondition, yyrl4733) + yyv1 = make([]ReplicationControllerCondition, yyrl1) } } else { - yyv4733 = make([]ReplicationControllerCondition, yyrl4733) + yyv1 = make([]ReplicationControllerCondition, yyrl1) } - yyc4733 = true - yyrr4733 = len(yyv4733) - if yyrg4733 { - copy(yyv4733, yyv24733) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4733 != len(yyv4733) { - yyv4733 = yyv4733[:yyl4733] - yyc4733 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4733 := 0 - for ; yyj4733 < yyrr4733; yyj4733++ { - yyh4733.ElemContainerState(yyj4733) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4733[yyj4733] = ReplicationControllerCondition{} + yyv1[yyj1] = ReplicationControllerCondition{} } else { - yyv4734 := &yyv4733[yyj4733] - yyv4734.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4733 { - for ; yyj4733 < yyl4733; yyj4733++ { - yyv4733 = append(yyv4733, ReplicationControllerCondition{}) - yyh4733.ElemContainerState(yyj4733) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ReplicationControllerCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4733[yyj4733] = ReplicationControllerCondition{} + yyv1[yyj1] = ReplicationControllerCondition{} } else { - yyv4735 := &yyv4733[yyj4733] - yyv4735.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4733 := 0 - for ; !r.CheckBreak(); yyj4733++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4733 >= len(yyv4733) { - yyv4733 = append(yyv4733, ReplicationControllerCondition{}) // var yyz4733 ReplicationControllerCondition - yyc4733 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ReplicationControllerCondition{}) // var yyz1 ReplicationControllerCondition + yyc1 = true } - yyh4733.ElemContainerState(yyj4733) - if yyj4733 < len(yyv4733) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4733[yyj4733] = ReplicationControllerCondition{} + yyv1[yyj1] = ReplicationControllerCondition{} } else { - yyv4736 := &yyv4733[yyj4733] - yyv4736.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -59948,17 +72761,17 @@ func (x codecSelfer1234) decSliceReplicationControllerCondition(v *[]Replication } } - if yyj4733 < len(yyv4733) { - yyv4733 = yyv4733[:yyj4733] - yyc4733 = true - } else if yyj4733 == 0 && yyv4733 == nil { - yyv4733 = []ReplicationControllerCondition{} - yyc4733 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ReplicationControllerCondition{} + yyc1 = true } } - yyh4733.End() - if yyc4733 { - *v = yyv4733 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -59967,10 +72780,10 @@ func (x codecSelfer1234) encSliceReplicationController(v []ReplicationController z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4737 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4738 := &yyv4737 - yy4738.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -59980,83 +72793,86 @@ func (x codecSelfer1234) decSliceReplicationController(v *[]ReplicationControlle z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4739 := *v - yyh4739, yyl4739 := z.DecSliceHelperStart() - var yyc4739 bool - if yyl4739 == 0 { - if yyv4739 == nil { - yyv4739 = []ReplicationController{} - yyc4739 = true - } else if len(yyv4739) != 0 { - yyv4739 = yyv4739[:0] - yyc4739 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ReplicationController{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4739 > 0 { - var yyrr4739, yyrl4739 int - var yyrt4739 bool - if yyl4739 > cap(yyv4739) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4739 := len(yyv4739) > 0 - yyv24739 := yyv4739 - yyrl4739, yyrt4739 = z.DecInferLen(yyl4739, z.DecBasicHandle().MaxInitLen, 336) - if yyrt4739 { - if yyrl4739 <= cap(yyv4739) { - yyv4739 = yyv4739[:yyrl4739] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 344) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4739 = make([]ReplicationController, yyrl4739) + yyv1 = make([]ReplicationController, yyrl1) } } else { - yyv4739 = make([]ReplicationController, yyrl4739) + yyv1 = make([]ReplicationController, yyrl1) } - yyc4739 = true - yyrr4739 = len(yyv4739) - if yyrg4739 { - copy(yyv4739, yyv24739) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4739 != len(yyv4739) { - yyv4739 = yyv4739[:yyl4739] - yyc4739 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4739 := 0 - for ; yyj4739 < yyrr4739; yyj4739++ { - yyh4739.ElemContainerState(yyj4739) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4739[yyj4739] = ReplicationController{} + yyv1[yyj1] = ReplicationController{} } else { - yyv4740 := &yyv4739[yyj4739] - yyv4740.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4739 { - for ; yyj4739 < yyl4739; yyj4739++ { - yyv4739 = append(yyv4739, ReplicationController{}) - yyh4739.ElemContainerState(yyj4739) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ReplicationController{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4739[yyj4739] = ReplicationController{} + yyv1[yyj1] = ReplicationController{} } else { - yyv4741 := &yyv4739[yyj4739] - yyv4741.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4739 := 0 - for ; !r.CheckBreak(); yyj4739++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4739 >= len(yyv4739) { - yyv4739 = append(yyv4739, ReplicationController{}) // var yyz4739 ReplicationController - yyc4739 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ReplicationController{}) // var yyz1 ReplicationController + yyc1 = true } - yyh4739.ElemContainerState(yyj4739) - if yyj4739 < len(yyv4739) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4739[yyj4739] = ReplicationController{} + yyv1[yyj1] = ReplicationController{} } else { - yyv4742 := &yyv4739[yyj4739] - yyv4742.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60064,17 +72880,17 @@ func (x codecSelfer1234) decSliceReplicationController(v *[]ReplicationControlle } } - if yyj4739 < len(yyv4739) { - yyv4739 = yyv4739[:yyj4739] - yyc4739 = true - } else if yyj4739 == 0 && yyv4739 == nil { - yyv4739 = []ReplicationController{} - yyc4739 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ReplicationController{} + yyc1 = true } } - yyh4739.End() - if yyc4739 { - *v = yyv4739 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60083,10 +72899,10 @@ func (x codecSelfer1234) encSliceLoadBalancerIngress(v []LoadBalancerIngress, e z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4743 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4744 := &yyv4743 - yy4744.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60096,83 +72912,86 @@ func (x codecSelfer1234) decSliceLoadBalancerIngress(v *[]LoadBalancerIngress, d z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4745 := *v - yyh4745, yyl4745 := z.DecSliceHelperStart() - var yyc4745 bool - if yyl4745 == 0 { - if yyv4745 == nil { - yyv4745 = []LoadBalancerIngress{} - yyc4745 = true - } else if len(yyv4745) != 0 { - yyv4745 = yyv4745[:0] - yyc4745 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []LoadBalancerIngress{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4745 > 0 { - var yyrr4745, yyrl4745 int - var yyrt4745 bool - if yyl4745 > cap(yyv4745) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4745 := len(yyv4745) > 0 - yyv24745 := yyv4745 - yyrl4745, yyrt4745 = z.DecInferLen(yyl4745, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4745 { - if yyrl4745 <= cap(yyv4745) { - yyv4745 = yyv4745[:yyrl4745] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4745 = make([]LoadBalancerIngress, yyrl4745) + yyv1 = make([]LoadBalancerIngress, yyrl1) } } else { - yyv4745 = make([]LoadBalancerIngress, yyrl4745) + yyv1 = make([]LoadBalancerIngress, yyrl1) } - yyc4745 = true - yyrr4745 = len(yyv4745) - if yyrg4745 { - copy(yyv4745, yyv24745) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4745 != len(yyv4745) { - yyv4745 = yyv4745[:yyl4745] - yyc4745 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4745 := 0 - for ; yyj4745 < yyrr4745; yyj4745++ { - yyh4745.ElemContainerState(yyj4745) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4745[yyj4745] = LoadBalancerIngress{} + yyv1[yyj1] = LoadBalancerIngress{} } else { - yyv4746 := &yyv4745[yyj4745] - yyv4746.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4745 { - for ; yyj4745 < yyl4745; yyj4745++ { - yyv4745 = append(yyv4745, LoadBalancerIngress{}) - yyh4745.ElemContainerState(yyj4745) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, LoadBalancerIngress{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4745[yyj4745] = LoadBalancerIngress{} + yyv1[yyj1] = LoadBalancerIngress{} } else { - yyv4747 := &yyv4745[yyj4745] - yyv4747.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4745 := 0 - for ; !r.CheckBreak(); yyj4745++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4745 >= len(yyv4745) { - yyv4745 = append(yyv4745, LoadBalancerIngress{}) // var yyz4745 LoadBalancerIngress - yyc4745 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, LoadBalancerIngress{}) // var yyz1 LoadBalancerIngress + yyc1 = true } - yyh4745.ElemContainerState(yyj4745) - if yyj4745 < len(yyv4745) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4745[yyj4745] = LoadBalancerIngress{} + yyv1[yyj1] = LoadBalancerIngress{} } else { - yyv4748 := &yyv4745[yyj4745] - yyv4748.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60180,17 +72999,17 @@ func (x codecSelfer1234) decSliceLoadBalancerIngress(v *[]LoadBalancerIngress, d } } - if yyj4745 < len(yyv4745) { - yyv4745 = yyv4745[:yyj4745] - yyc4745 = true - } else if yyj4745 == 0 && yyv4745 == nil { - yyv4745 = []LoadBalancerIngress{} - yyc4745 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []LoadBalancerIngress{} + yyc1 = true } } - yyh4745.End() - if yyc4745 { - *v = yyv4745 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60199,10 +73018,10 @@ func (x codecSelfer1234) encSliceServicePort(v []ServicePort, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4749 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4750 := &yyv4749 - yy4750.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60212,83 +73031,86 @@ func (x codecSelfer1234) decSliceServicePort(v *[]ServicePort, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4751 := *v - yyh4751, yyl4751 := z.DecSliceHelperStart() - var yyc4751 bool - if yyl4751 == 0 { - if yyv4751 == nil { - yyv4751 = []ServicePort{} - yyc4751 = true - } else if len(yyv4751) != 0 { - yyv4751 = yyv4751[:0] - yyc4751 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ServicePort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4751 > 0 { - var yyrr4751, yyrl4751 int - var yyrt4751 bool - if yyl4751 > cap(yyv4751) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4751 := len(yyv4751) > 0 - yyv24751 := yyv4751 - yyrl4751, yyrt4751 = z.DecInferLen(yyl4751, z.DecBasicHandle().MaxInitLen, 80) - if yyrt4751 { - if yyrl4751 <= cap(yyv4751) { - yyv4751 = yyv4751[:yyrl4751] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 80) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4751 = make([]ServicePort, yyrl4751) + yyv1 = make([]ServicePort, yyrl1) } } else { - yyv4751 = make([]ServicePort, yyrl4751) + yyv1 = make([]ServicePort, yyrl1) } - yyc4751 = true - yyrr4751 = len(yyv4751) - if yyrg4751 { - copy(yyv4751, yyv24751) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4751 != len(yyv4751) { - yyv4751 = yyv4751[:yyl4751] - yyc4751 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4751 := 0 - for ; yyj4751 < yyrr4751; yyj4751++ { - yyh4751.ElemContainerState(yyj4751) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4751[yyj4751] = ServicePort{} + yyv1[yyj1] = ServicePort{} } else { - yyv4752 := &yyv4751[yyj4751] - yyv4752.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4751 { - for ; yyj4751 < yyl4751; yyj4751++ { - yyv4751 = append(yyv4751, ServicePort{}) - yyh4751.ElemContainerState(yyj4751) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ServicePort{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4751[yyj4751] = ServicePort{} + yyv1[yyj1] = ServicePort{} } else { - yyv4753 := &yyv4751[yyj4751] - yyv4753.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4751 := 0 - for ; !r.CheckBreak(); yyj4751++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4751 >= len(yyv4751) { - yyv4751 = append(yyv4751, ServicePort{}) // var yyz4751 ServicePort - yyc4751 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ServicePort{}) // var yyz1 ServicePort + yyc1 = true } - yyh4751.ElemContainerState(yyj4751) - if yyj4751 < len(yyv4751) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4751[yyj4751] = ServicePort{} + yyv1[yyj1] = ServicePort{} } else { - yyv4754 := &yyv4751[yyj4751] - yyv4754.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60296,17 +73118,17 @@ func (x codecSelfer1234) decSliceServicePort(v *[]ServicePort, d *codec1978.Deco } } - if yyj4751 < len(yyv4751) { - yyv4751 = yyv4751[:yyj4751] - yyc4751 = true - } else if yyj4751 == 0 && yyv4751 == nil { - yyv4751 = []ServicePort{} - yyc4751 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ServicePort{} + yyc1 = true } } - yyh4751.End() - if yyc4751 { - *v = yyv4751 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60315,10 +73137,10 @@ func (x codecSelfer1234) encSliceService(v []Service, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4755 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4756 := &yyv4755 - yy4756.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60328,83 +73150,86 @@ func (x codecSelfer1234) decSliceService(v *[]Service, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4757 := *v - yyh4757, yyl4757 := z.DecSliceHelperStart() - var yyc4757 bool - if yyl4757 == 0 { - if yyv4757 == nil { - yyv4757 = []Service{} - yyc4757 = true - } else if len(yyv4757) != 0 { - yyv4757 = yyv4757[:0] - yyc4757 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Service{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4757 > 0 { - var yyrr4757, yyrl4757 int - var yyrt4757 bool - if yyl4757 > cap(yyv4757) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4757 := len(yyv4757) > 0 - yyv24757 := yyv4757 - yyrl4757, yyrt4757 = z.DecInferLen(yyl4757, z.DecBasicHandle().MaxInitLen, 464) - if yyrt4757 { - if yyrl4757 <= cap(yyv4757) { - yyv4757 = yyv4757[:yyrl4757] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 472) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4757 = make([]Service, yyrl4757) + yyv1 = make([]Service, yyrl1) } } else { - yyv4757 = make([]Service, yyrl4757) + yyv1 = make([]Service, yyrl1) } - yyc4757 = true - yyrr4757 = len(yyv4757) - if yyrg4757 { - copy(yyv4757, yyv24757) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4757 != len(yyv4757) { - yyv4757 = yyv4757[:yyl4757] - yyc4757 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4757 := 0 - for ; yyj4757 < yyrr4757; yyj4757++ { - yyh4757.ElemContainerState(yyj4757) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4757[yyj4757] = Service{} + yyv1[yyj1] = Service{} } else { - yyv4758 := &yyv4757[yyj4757] - yyv4758.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4757 { - for ; yyj4757 < yyl4757; yyj4757++ { - yyv4757 = append(yyv4757, Service{}) - yyh4757.ElemContainerState(yyj4757) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Service{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4757[yyj4757] = Service{} + yyv1[yyj1] = Service{} } else { - yyv4759 := &yyv4757[yyj4757] - yyv4759.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4757 := 0 - for ; !r.CheckBreak(); yyj4757++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4757 >= len(yyv4757) { - yyv4757 = append(yyv4757, Service{}) // var yyz4757 Service - yyc4757 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Service{}) // var yyz1 Service + yyc1 = true } - yyh4757.ElemContainerState(yyj4757) - if yyj4757 < len(yyv4757) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4757[yyj4757] = Service{} + yyv1[yyj1] = Service{} } else { - yyv4760 := &yyv4757[yyj4757] - yyv4760.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60412,17 +73237,17 @@ func (x codecSelfer1234) decSliceService(v *[]Service, d *codec1978.Decoder) { } } - if yyj4757 < len(yyv4757) { - yyv4757 = yyv4757[:yyj4757] - yyc4757 = true - } else if yyj4757 == 0 && yyv4757 == nil { - yyv4757 = []Service{} - yyc4757 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Service{} + yyc1 = true } } - yyh4757.End() - if yyc4757 { - *v = yyv4757 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60431,10 +73256,10 @@ func (x codecSelfer1234) encSliceObjectReference(v []ObjectReference, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4761 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4762 := &yyv4761 - yy4762.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60444,83 +73269,86 @@ func (x codecSelfer1234) decSliceObjectReference(v *[]ObjectReference, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4763 := *v - yyh4763, yyl4763 := z.DecSliceHelperStart() - var yyc4763 bool - if yyl4763 == 0 { - if yyv4763 == nil { - yyv4763 = []ObjectReference{} - yyc4763 = true - } else if len(yyv4763) != 0 { - yyv4763 = yyv4763[:0] - yyc4763 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ObjectReference{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4763 > 0 { - var yyrr4763, yyrl4763 int - var yyrt4763 bool - if yyl4763 > cap(yyv4763) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4763 := len(yyv4763) > 0 - yyv24763 := yyv4763 - yyrl4763, yyrt4763 = z.DecInferLen(yyl4763, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4763 { - if yyrl4763 <= cap(yyv4763) { - yyv4763 = yyv4763[:yyrl4763] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4763 = make([]ObjectReference, yyrl4763) + yyv1 = make([]ObjectReference, yyrl1) } } else { - yyv4763 = make([]ObjectReference, yyrl4763) + yyv1 = make([]ObjectReference, yyrl1) } - yyc4763 = true - yyrr4763 = len(yyv4763) - if yyrg4763 { - copy(yyv4763, yyv24763) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4763 != len(yyv4763) { - yyv4763 = yyv4763[:yyl4763] - yyc4763 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4763 := 0 - for ; yyj4763 < yyrr4763; yyj4763++ { - yyh4763.ElemContainerState(yyj4763) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4763[yyj4763] = ObjectReference{} + yyv1[yyj1] = ObjectReference{} } else { - yyv4764 := &yyv4763[yyj4763] - yyv4764.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4763 { - for ; yyj4763 < yyl4763; yyj4763++ { - yyv4763 = append(yyv4763, ObjectReference{}) - yyh4763.ElemContainerState(yyj4763) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ObjectReference{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4763[yyj4763] = ObjectReference{} + yyv1[yyj1] = ObjectReference{} } else { - yyv4765 := &yyv4763[yyj4763] - yyv4765.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4763 := 0 - for ; !r.CheckBreak(); yyj4763++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4763 >= len(yyv4763) { - yyv4763 = append(yyv4763, ObjectReference{}) // var yyz4763 ObjectReference - yyc4763 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ObjectReference{}) // var yyz1 ObjectReference + yyc1 = true } - yyh4763.ElemContainerState(yyj4763) - if yyj4763 < len(yyv4763) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4763[yyj4763] = ObjectReference{} + yyv1[yyj1] = ObjectReference{} } else { - yyv4766 := &yyv4763[yyj4763] - yyv4766.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60528,17 +73356,17 @@ func (x codecSelfer1234) decSliceObjectReference(v *[]ObjectReference, d *codec1 } } - if yyj4763 < len(yyv4763) { - yyv4763 = yyv4763[:yyj4763] - yyc4763 = true - } else if yyj4763 == 0 && yyv4763 == nil { - yyv4763 = []ObjectReference{} - yyc4763 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ObjectReference{} + yyc1 = true } } - yyh4763.End() - if yyc4763 { - *v = yyv4763 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60547,10 +73375,10 @@ func (x codecSelfer1234) encSliceServiceAccount(v []ServiceAccount, e *codec1978 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4767 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4768 := &yyv4767 - yy4768.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60560,83 +73388,86 @@ func (x codecSelfer1234) decSliceServiceAccount(v *[]ServiceAccount, d *codec197 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4769 := *v - yyh4769, yyl4769 := z.DecSliceHelperStart() - var yyc4769 bool - if yyl4769 == 0 { - if yyv4769 == nil { - yyv4769 = []ServiceAccount{} - yyc4769 = true - } else if len(yyv4769) != 0 { - yyv4769 = yyv4769[:0] - yyc4769 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ServiceAccount{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4769 > 0 { - var yyrr4769, yyrl4769 int - var yyrt4769 bool - if yyl4769 > cap(yyv4769) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4769 := len(yyv4769) > 0 - yyv24769 := yyv4769 - yyrl4769, yyrt4769 = z.DecInferLen(yyl4769, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4769 { - if yyrl4769 <= cap(yyv4769) { - yyv4769 = yyv4769[:yyrl4769] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 320) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4769 = make([]ServiceAccount, yyrl4769) + yyv1 = make([]ServiceAccount, yyrl1) } } else { - yyv4769 = make([]ServiceAccount, yyrl4769) + yyv1 = make([]ServiceAccount, yyrl1) } - yyc4769 = true - yyrr4769 = len(yyv4769) - if yyrg4769 { - copy(yyv4769, yyv24769) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4769 != len(yyv4769) { - yyv4769 = yyv4769[:yyl4769] - yyc4769 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4769 := 0 - for ; yyj4769 < yyrr4769; yyj4769++ { - yyh4769.ElemContainerState(yyj4769) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4769[yyj4769] = ServiceAccount{} + yyv1[yyj1] = ServiceAccount{} } else { - yyv4770 := &yyv4769[yyj4769] - yyv4770.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4769 { - for ; yyj4769 < yyl4769; yyj4769++ { - yyv4769 = append(yyv4769, ServiceAccount{}) - yyh4769.ElemContainerState(yyj4769) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ServiceAccount{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4769[yyj4769] = ServiceAccount{} + yyv1[yyj1] = ServiceAccount{} } else { - yyv4771 := &yyv4769[yyj4769] - yyv4771.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4769 := 0 - for ; !r.CheckBreak(); yyj4769++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4769 >= len(yyv4769) { - yyv4769 = append(yyv4769, ServiceAccount{}) // var yyz4769 ServiceAccount - yyc4769 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ServiceAccount{}) // var yyz1 ServiceAccount + yyc1 = true } - yyh4769.ElemContainerState(yyj4769) - if yyj4769 < len(yyv4769) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4769[yyj4769] = ServiceAccount{} + yyv1[yyj1] = ServiceAccount{} } else { - yyv4772 := &yyv4769[yyj4769] - yyv4772.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60644,17 +73475,17 @@ func (x codecSelfer1234) decSliceServiceAccount(v *[]ServiceAccount, d *codec197 } } - if yyj4769 < len(yyv4769) { - yyv4769 = yyv4769[:yyj4769] - yyc4769 = true - } else if yyj4769 == 0 && yyv4769 == nil { - yyv4769 = []ServiceAccount{} - yyc4769 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ServiceAccount{} + yyc1 = true } } - yyh4769.End() - if yyc4769 { - *v = yyv4769 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60663,10 +73494,10 @@ func (x codecSelfer1234) encSliceEndpointSubset(v []EndpointSubset, e *codec1978 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4773 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4774 := &yyv4773 - yy4774.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60676,83 +73507,86 @@ func (x codecSelfer1234) decSliceEndpointSubset(v *[]EndpointSubset, d *codec197 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4775 := *v - yyh4775, yyl4775 := z.DecSliceHelperStart() - var yyc4775 bool - if yyl4775 == 0 { - if yyv4775 == nil { - yyv4775 = []EndpointSubset{} - yyc4775 = true - } else if len(yyv4775) != 0 { - yyv4775 = yyv4775[:0] - yyc4775 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []EndpointSubset{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4775 > 0 { - var yyrr4775, yyrl4775 int - var yyrt4775 bool - if yyl4775 > cap(yyv4775) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4775 := len(yyv4775) > 0 - yyv24775 := yyv4775 - yyrl4775, yyrt4775 = z.DecInferLen(yyl4775, z.DecBasicHandle().MaxInitLen, 72) - if yyrt4775 { - if yyrl4775 <= cap(yyv4775) { - yyv4775 = yyv4775[:yyrl4775] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4775 = make([]EndpointSubset, yyrl4775) + yyv1 = make([]EndpointSubset, yyrl1) } } else { - yyv4775 = make([]EndpointSubset, yyrl4775) + yyv1 = make([]EndpointSubset, yyrl1) } - yyc4775 = true - yyrr4775 = len(yyv4775) - if yyrg4775 { - copy(yyv4775, yyv24775) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4775 != len(yyv4775) { - yyv4775 = yyv4775[:yyl4775] - yyc4775 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4775 := 0 - for ; yyj4775 < yyrr4775; yyj4775++ { - yyh4775.ElemContainerState(yyj4775) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4775[yyj4775] = EndpointSubset{} + yyv1[yyj1] = EndpointSubset{} } else { - yyv4776 := &yyv4775[yyj4775] - yyv4776.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4775 { - for ; yyj4775 < yyl4775; yyj4775++ { - yyv4775 = append(yyv4775, EndpointSubset{}) - yyh4775.ElemContainerState(yyj4775) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, EndpointSubset{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4775[yyj4775] = EndpointSubset{} + yyv1[yyj1] = EndpointSubset{} } else { - yyv4777 := &yyv4775[yyj4775] - yyv4777.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4775 := 0 - for ; !r.CheckBreak(); yyj4775++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4775 >= len(yyv4775) { - yyv4775 = append(yyv4775, EndpointSubset{}) // var yyz4775 EndpointSubset - yyc4775 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, EndpointSubset{}) // var yyz1 EndpointSubset + yyc1 = true } - yyh4775.ElemContainerState(yyj4775) - if yyj4775 < len(yyv4775) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4775[yyj4775] = EndpointSubset{} + yyv1[yyj1] = EndpointSubset{} } else { - yyv4778 := &yyv4775[yyj4775] - yyv4778.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60760,17 +73594,17 @@ func (x codecSelfer1234) decSliceEndpointSubset(v *[]EndpointSubset, d *codec197 } } - if yyj4775 < len(yyv4775) { - yyv4775 = yyv4775[:yyj4775] - yyc4775 = true - } else if yyj4775 == 0 && yyv4775 == nil { - yyv4775 = []EndpointSubset{} - yyc4775 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []EndpointSubset{} + yyc1 = true } } - yyh4775.End() - if yyc4775 { - *v = yyv4775 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60779,10 +73613,10 @@ func (x codecSelfer1234) encSliceEndpointAddress(v []EndpointAddress, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4779 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4780 := &yyv4779 - yy4780.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60792,83 +73626,86 @@ func (x codecSelfer1234) decSliceEndpointAddress(v *[]EndpointAddress, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4781 := *v - yyh4781, yyl4781 := z.DecSliceHelperStart() - var yyc4781 bool - if yyl4781 == 0 { - if yyv4781 == nil { - yyv4781 = []EndpointAddress{} - yyc4781 = true - } else if len(yyv4781) != 0 { - yyv4781 = yyv4781[:0] - yyc4781 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []EndpointAddress{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4781 > 0 { - var yyrr4781, yyrl4781 int - var yyrt4781 bool - if yyl4781 > cap(yyv4781) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4781 := len(yyv4781) > 0 - yyv24781 := yyv4781 - yyrl4781, yyrt4781 = z.DecInferLen(yyl4781, z.DecBasicHandle().MaxInitLen, 48) - if yyrt4781 { - if yyrl4781 <= cap(yyv4781) { - yyv4781 = yyv4781[:yyrl4781] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4781 = make([]EndpointAddress, yyrl4781) + yyv1 = make([]EndpointAddress, yyrl1) } } else { - yyv4781 = make([]EndpointAddress, yyrl4781) + yyv1 = make([]EndpointAddress, yyrl1) } - yyc4781 = true - yyrr4781 = len(yyv4781) - if yyrg4781 { - copy(yyv4781, yyv24781) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4781 != len(yyv4781) { - yyv4781 = yyv4781[:yyl4781] - yyc4781 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4781 := 0 - for ; yyj4781 < yyrr4781; yyj4781++ { - yyh4781.ElemContainerState(yyj4781) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4781[yyj4781] = EndpointAddress{} + yyv1[yyj1] = EndpointAddress{} } else { - yyv4782 := &yyv4781[yyj4781] - yyv4782.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4781 { - for ; yyj4781 < yyl4781; yyj4781++ { - yyv4781 = append(yyv4781, EndpointAddress{}) - yyh4781.ElemContainerState(yyj4781) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, EndpointAddress{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4781[yyj4781] = EndpointAddress{} + yyv1[yyj1] = EndpointAddress{} } else { - yyv4783 := &yyv4781[yyj4781] - yyv4783.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4781 := 0 - for ; !r.CheckBreak(); yyj4781++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4781 >= len(yyv4781) { - yyv4781 = append(yyv4781, EndpointAddress{}) // var yyz4781 EndpointAddress - yyc4781 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, EndpointAddress{}) // var yyz1 EndpointAddress + yyc1 = true } - yyh4781.ElemContainerState(yyj4781) - if yyj4781 < len(yyv4781) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4781[yyj4781] = EndpointAddress{} + yyv1[yyj1] = EndpointAddress{} } else { - yyv4784 := &yyv4781[yyj4781] - yyv4784.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60876,17 +73713,17 @@ func (x codecSelfer1234) decSliceEndpointAddress(v *[]EndpointAddress, d *codec1 } } - if yyj4781 < len(yyv4781) { - yyv4781 = yyv4781[:yyj4781] - yyc4781 = true - } else if yyj4781 == 0 && yyv4781 == nil { - yyv4781 = []EndpointAddress{} - yyc4781 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []EndpointAddress{} + yyc1 = true } } - yyh4781.End() - if yyc4781 { - *v = yyv4781 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -60895,10 +73732,10 @@ func (x codecSelfer1234) encSliceEndpointPort(v []EndpointPort, e *codec1978.Enc z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4785 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4786 := &yyv4785 - yy4786.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -60908,83 +73745,86 @@ func (x codecSelfer1234) decSliceEndpointPort(v *[]EndpointPort, d *codec1978.De z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4787 := *v - yyh4787, yyl4787 := z.DecSliceHelperStart() - var yyc4787 bool - if yyl4787 == 0 { - if yyv4787 == nil { - yyv4787 = []EndpointPort{} - yyc4787 = true - } else if len(yyv4787) != 0 { - yyv4787 = yyv4787[:0] - yyc4787 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []EndpointPort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4787 > 0 { - var yyrr4787, yyrl4787 int - var yyrt4787 bool - if yyl4787 > cap(yyv4787) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4787 := len(yyv4787) > 0 - yyv24787 := yyv4787 - yyrl4787, yyrt4787 = z.DecInferLen(yyl4787, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4787 { - if yyrl4787 <= cap(yyv4787) { - yyv4787 = yyv4787[:yyrl4787] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4787 = make([]EndpointPort, yyrl4787) + yyv1 = make([]EndpointPort, yyrl1) } } else { - yyv4787 = make([]EndpointPort, yyrl4787) + yyv1 = make([]EndpointPort, yyrl1) } - yyc4787 = true - yyrr4787 = len(yyv4787) - if yyrg4787 { - copy(yyv4787, yyv24787) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4787 != len(yyv4787) { - yyv4787 = yyv4787[:yyl4787] - yyc4787 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4787 := 0 - for ; yyj4787 < yyrr4787; yyj4787++ { - yyh4787.ElemContainerState(yyj4787) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4787[yyj4787] = EndpointPort{} + yyv1[yyj1] = EndpointPort{} } else { - yyv4788 := &yyv4787[yyj4787] - yyv4788.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4787 { - for ; yyj4787 < yyl4787; yyj4787++ { - yyv4787 = append(yyv4787, EndpointPort{}) - yyh4787.ElemContainerState(yyj4787) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, EndpointPort{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4787[yyj4787] = EndpointPort{} + yyv1[yyj1] = EndpointPort{} } else { - yyv4789 := &yyv4787[yyj4787] - yyv4789.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4787 := 0 - for ; !r.CheckBreak(); yyj4787++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4787 >= len(yyv4787) { - yyv4787 = append(yyv4787, EndpointPort{}) // var yyz4787 EndpointPort - yyc4787 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, EndpointPort{}) // var yyz1 EndpointPort + yyc1 = true } - yyh4787.ElemContainerState(yyj4787) - if yyj4787 < len(yyv4787) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4787[yyj4787] = EndpointPort{} + yyv1[yyj1] = EndpointPort{} } else { - yyv4790 := &yyv4787[yyj4787] - yyv4790.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -60992,17 +73832,17 @@ func (x codecSelfer1234) decSliceEndpointPort(v *[]EndpointPort, d *codec1978.De } } - if yyj4787 < len(yyv4787) { - yyv4787 = yyv4787[:yyj4787] - yyc4787 = true - } else if yyj4787 == 0 && yyv4787 == nil { - yyv4787 = []EndpointPort{} - yyc4787 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []EndpointPort{} + yyc1 = true } } - yyh4787.End() - if yyc4787 { - *v = yyv4787 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61011,10 +73851,10 @@ func (x codecSelfer1234) encSliceEndpoints(v []Endpoints, e *codec1978.Encoder) z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4791 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4792 := &yyv4791 - yy4792.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61024,83 +73864,205 @@ func (x codecSelfer1234) decSliceEndpoints(v *[]Endpoints, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4793 := *v - yyh4793, yyl4793 := z.DecSliceHelperStart() - var yyc4793 bool - if yyl4793 == 0 { - if yyv4793 == nil { - yyv4793 = []Endpoints{} - yyc4793 = true - } else if len(yyv4793) != 0 { - yyv4793 = yyv4793[:0] - yyc4793 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Endpoints{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Endpoints, yyrl1) + } + } else { + yyv1 = make([]Endpoints, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Endpoints{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Endpoints{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Endpoints{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Endpoints{}) // var yyz1 Endpoints + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Endpoints{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Endpoints{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceTaint(v []Taint, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceTaint(v *[]Taint, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Taint{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4793 > 0 { - var yyrr4793, yyrl4793 int - var yyrt4793 bool - if yyl4793 > cap(yyv4793) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4793 := len(yyv4793) > 0 - yyv24793 := yyv4793 - yyrl4793, yyrt4793 = z.DecInferLen(yyl4793, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4793 { - if yyrl4793 <= cap(yyv4793) { - yyv4793 = yyv4793[:yyrl4793] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4793 = make([]Endpoints, yyrl4793) + yyv1 = make([]Taint, yyrl1) } } else { - yyv4793 = make([]Endpoints, yyrl4793) + yyv1 = make([]Taint, yyrl1) } - yyc4793 = true - yyrr4793 = len(yyv4793) - if yyrg4793 { - copy(yyv4793, yyv24793) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4793 != len(yyv4793) { - yyv4793 = yyv4793[:yyl4793] - yyc4793 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4793 := 0 - for ; yyj4793 < yyrr4793; yyj4793++ { - yyh4793.ElemContainerState(yyj4793) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4793[yyj4793] = Endpoints{} + yyv1[yyj1] = Taint{} } else { - yyv4794 := &yyv4793[yyj4793] - yyv4794.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4793 { - for ; yyj4793 < yyl4793; yyj4793++ { - yyv4793 = append(yyv4793, Endpoints{}) - yyh4793.ElemContainerState(yyj4793) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Taint{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4793[yyj4793] = Endpoints{} + yyv1[yyj1] = Taint{} } else { - yyv4795 := &yyv4793[yyj4793] - yyv4795.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4793 := 0 - for ; !r.CheckBreak(); yyj4793++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4793 >= len(yyv4793) { - yyv4793 = append(yyv4793, Endpoints{}) // var yyz4793 Endpoints - yyc4793 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Taint{}) // var yyz1 Taint + yyc1 = true } - yyh4793.ElemContainerState(yyj4793) - if yyj4793 < len(yyv4793) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4793[yyj4793] = Endpoints{} + yyv1[yyj1] = Taint{} } else { - yyv4796 := &yyv4793[yyj4793] - yyv4796.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61108,17 +74070,17 @@ func (x codecSelfer1234) decSliceEndpoints(v *[]Endpoints, d *codec1978.Decoder) } } - if yyj4793 < len(yyv4793) { - yyv4793 = yyv4793[:yyj4793] - yyc4793 = true - } else if yyj4793 == 0 && yyv4793 == nil { - yyv4793 = []Endpoints{} - yyc4793 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Taint{} + yyc1 = true } } - yyh4793.End() - if yyc4793 { - *v = yyv4793 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61127,10 +74089,10 @@ func (x codecSelfer1234) encSliceNodeCondition(v []NodeCondition, e *codec1978.E z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4797 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4798 := &yyv4797 - yy4798.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61140,83 +74102,86 @@ func (x codecSelfer1234) decSliceNodeCondition(v *[]NodeCondition, d *codec1978. z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4799 := *v - yyh4799, yyl4799 := z.DecSliceHelperStart() - var yyc4799 bool - if yyl4799 == 0 { - if yyv4799 == nil { - yyv4799 = []NodeCondition{} - yyc4799 = true - } else if len(yyv4799) != 0 { - yyv4799 = yyv4799[:0] - yyc4799 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NodeCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4799 > 0 { - var yyrr4799, yyrl4799 int - var yyrt4799 bool - if yyl4799 > cap(yyv4799) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4799 := len(yyv4799) > 0 - yyv24799 := yyv4799 - yyrl4799, yyrt4799 = z.DecInferLen(yyl4799, z.DecBasicHandle().MaxInitLen, 112) - if yyrt4799 { - if yyrl4799 <= cap(yyv4799) { - yyv4799 = yyv4799[:yyrl4799] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4799 = make([]NodeCondition, yyrl4799) + yyv1 = make([]NodeCondition, yyrl1) } } else { - yyv4799 = make([]NodeCondition, yyrl4799) + yyv1 = make([]NodeCondition, yyrl1) } - yyc4799 = true - yyrr4799 = len(yyv4799) - if yyrg4799 { - copy(yyv4799, yyv24799) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4799 != len(yyv4799) { - yyv4799 = yyv4799[:yyl4799] - yyc4799 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4799 := 0 - for ; yyj4799 < yyrr4799; yyj4799++ { - yyh4799.ElemContainerState(yyj4799) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4799[yyj4799] = NodeCondition{} + yyv1[yyj1] = NodeCondition{} } else { - yyv4800 := &yyv4799[yyj4799] - yyv4800.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4799 { - for ; yyj4799 < yyl4799; yyj4799++ { - yyv4799 = append(yyv4799, NodeCondition{}) - yyh4799.ElemContainerState(yyj4799) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NodeCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4799[yyj4799] = NodeCondition{} + yyv1[yyj1] = NodeCondition{} } else { - yyv4801 := &yyv4799[yyj4799] - yyv4801.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4799 := 0 - for ; !r.CheckBreak(); yyj4799++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4799 >= len(yyv4799) { - yyv4799 = append(yyv4799, NodeCondition{}) // var yyz4799 NodeCondition - yyc4799 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NodeCondition{}) // var yyz1 NodeCondition + yyc1 = true } - yyh4799.ElemContainerState(yyj4799) - if yyj4799 < len(yyv4799) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4799[yyj4799] = NodeCondition{} + yyv1[yyj1] = NodeCondition{} } else { - yyv4802 := &yyv4799[yyj4799] - yyv4802.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61224,17 +74189,17 @@ func (x codecSelfer1234) decSliceNodeCondition(v *[]NodeCondition, d *codec1978. } } - if yyj4799 < len(yyv4799) { - yyv4799 = yyv4799[:yyj4799] - yyc4799 = true - } else if yyj4799 == 0 && yyv4799 == nil { - yyv4799 = []NodeCondition{} - yyc4799 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NodeCondition{} + yyc1 = true } } - yyh4799.End() - if yyc4799 { - *v = yyv4799 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61243,10 +74208,10 @@ func (x codecSelfer1234) encSliceNodeAddress(v []NodeAddress, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4803 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4804 := &yyv4803 - yy4804.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61256,83 +74221,86 @@ func (x codecSelfer1234) decSliceNodeAddress(v *[]NodeAddress, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4805 := *v - yyh4805, yyl4805 := z.DecSliceHelperStart() - var yyc4805 bool - if yyl4805 == 0 { - if yyv4805 == nil { - yyv4805 = []NodeAddress{} - yyc4805 = true - } else if len(yyv4805) != 0 { - yyv4805 = yyv4805[:0] - yyc4805 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NodeAddress{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4805 > 0 { - var yyrr4805, yyrl4805 int - var yyrt4805 bool - if yyl4805 > cap(yyv4805) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4805 := len(yyv4805) > 0 - yyv24805 := yyv4805 - yyrl4805, yyrt4805 = z.DecInferLen(yyl4805, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4805 { - if yyrl4805 <= cap(yyv4805) { - yyv4805 = yyv4805[:yyrl4805] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4805 = make([]NodeAddress, yyrl4805) + yyv1 = make([]NodeAddress, yyrl1) } } else { - yyv4805 = make([]NodeAddress, yyrl4805) + yyv1 = make([]NodeAddress, yyrl1) } - yyc4805 = true - yyrr4805 = len(yyv4805) - if yyrg4805 { - copy(yyv4805, yyv24805) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4805 != len(yyv4805) { - yyv4805 = yyv4805[:yyl4805] - yyc4805 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4805 := 0 - for ; yyj4805 < yyrr4805; yyj4805++ { - yyh4805.ElemContainerState(yyj4805) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4805[yyj4805] = NodeAddress{} + yyv1[yyj1] = NodeAddress{} } else { - yyv4806 := &yyv4805[yyj4805] - yyv4806.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4805 { - for ; yyj4805 < yyl4805; yyj4805++ { - yyv4805 = append(yyv4805, NodeAddress{}) - yyh4805.ElemContainerState(yyj4805) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NodeAddress{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4805[yyj4805] = NodeAddress{} + yyv1[yyj1] = NodeAddress{} } else { - yyv4807 := &yyv4805[yyj4805] - yyv4807.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4805 := 0 - for ; !r.CheckBreak(); yyj4805++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4805 >= len(yyv4805) { - yyv4805 = append(yyv4805, NodeAddress{}) // var yyz4805 NodeAddress - yyc4805 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NodeAddress{}) // var yyz1 NodeAddress + yyc1 = true } - yyh4805.ElemContainerState(yyj4805) - if yyj4805 < len(yyv4805) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4805[yyj4805] = NodeAddress{} + yyv1[yyj1] = NodeAddress{} } else { - yyv4808 := &yyv4805[yyj4805] - yyv4808.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61340,17 +74308,17 @@ func (x codecSelfer1234) decSliceNodeAddress(v *[]NodeAddress, d *codec1978.Deco } } - if yyj4805 < len(yyv4805) { - yyv4805 = yyv4805[:yyj4805] - yyc4805 = true - } else if yyj4805 == 0 && yyv4805 == nil { - yyv4805 = []NodeAddress{} - yyc4805 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NodeAddress{} + yyc1 = true } } - yyh4805.End() - if yyc4805 { - *v = yyv4805 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61359,10 +74327,10 @@ func (x codecSelfer1234) encSliceContainerImage(v []ContainerImage, e *codec1978 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4809 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4810 := &yyv4809 - yy4810.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61372,83 +74340,86 @@ func (x codecSelfer1234) decSliceContainerImage(v *[]ContainerImage, d *codec197 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4811 := *v - yyh4811, yyl4811 := z.DecSliceHelperStart() - var yyc4811 bool - if yyl4811 == 0 { - if yyv4811 == nil { - yyv4811 = []ContainerImage{} - yyc4811 = true - } else if len(yyv4811) != 0 { - yyv4811 = yyv4811[:0] - yyc4811 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ContainerImage{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4811 > 0 { - var yyrr4811, yyrl4811 int - var yyrt4811 bool - if yyl4811 > cap(yyv4811) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4811 := len(yyv4811) > 0 - yyv24811 := yyv4811 - yyrl4811, yyrt4811 = z.DecInferLen(yyl4811, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4811 { - if yyrl4811 <= cap(yyv4811) { - yyv4811 = yyv4811[:yyrl4811] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4811 = make([]ContainerImage, yyrl4811) + yyv1 = make([]ContainerImage, yyrl1) } } else { - yyv4811 = make([]ContainerImage, yyrl4811) + yyv1 = make([]ContainerImage, yyrl1) } - yyc4811 = true - yyrr4811 = len(yyv4811) - if yyrg4811 { - copy(yyv4811, yyv24811) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4811 != len(yyv4811) { - yyv4811 = yyv4811[:yyl4811] - yyc4811 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4811 := 0 - for ; yyj4811 < yyrr4811; yyj4811++ { - yyh4811.ElemContainerState(yyj4811) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4811[yyj4811] = ContainerImage{} + yyv1[yyj1] = ContainerImage{} } else { - yyv4812 := &yyv4811[yyj4811] - yyv4812.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4811 { - for ; yyj4811 < yyl4811; yyj4811++ { - yyv4811 = append(yyv4811, ContainerImage{}) - yyh4811.ElemContainerState(yyj4811) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ContainerImage{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4811[yyj4811] = ContainerImage{} + yyv1[yyj1] = ContainerImage{} } else { - yyv4813 := &yyv4811[yyj4811] - yyv4813.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4811 := 0 - for ; !r.CheckBreak(); yyj4811++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4811 >= len(yyv4811) { - yyv4811 = append(yyv4811, ContainerImage{}) // var yyz4811 ContainerImage - yyc4811 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ContainerImage{}) // var yyz1 ContainerImage + yyc1 = true } - yyh4811.ElemContainerState(yyj4811) - if yyj4811 < len(yyv4811) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4811[yyj4811] = ContainerImage{} + yyv1[yyj1] = ContainerImage{} } else { - yyv4814 := &yyv4811[yyj4811] - yyv4814.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61456,17 +74427,17 @@ func (x codecSelfer1234) decSliceContainerImage(v *[]ContainerImage, d *codec197 } } - if yyj4811 < len(yyv4811) { - yyv4811 = yyv4811[:yyj4811] - yyc4811 = true - } else if yyj4811 == 0 && yyv4811 == nil { - yyv4811 = []ContainerImage{} - yyc4811 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ContainerImage{} + yyc1 = true } } - yyh4811.End() - if yyc4811 { - *v = yyv4811 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61475,9 +74446,9 @@ func (x codecSelfer1234) encSliceUniqueVolumeName(v []UniqueVolumeName, e *codec z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4815 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4815.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61487,75 +74458,81 @@ func (x codecSelfer1234) decSliceUniqueVolumeName(v *[]UniqueVolumeName, d *code z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4816 := *v - yyh4816, yyl4816 := z.DecSliceHelperStart() - var yyc4816 bool - if yyl4816 == 0 { - if yyv4816 == nil { - yyv4816 = []UniqueVolumeName{} - yyc4816 = true - } else if len(yyv4816) != 0 { - yyv4816 = yyv4816[:0] - yyc4816 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []UniqueVolumeName{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4816 > 0 { - var yyrr4816, yyrl4816 int - var yyrt4816 bool - if yyl4816 > cap(yyv4816) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl4816, yyrt4816 = z.DecInferLen(yyl4816, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4816 { - if yyrl4816 <= cap(yyv4816) { - yyv4816 = yyv4816[:yyrl4816] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4816 = make([]UniqueVolumeName, yyrl4816) + yyv1 = make([]UniqueVolumeName, yyrl1) } } else { - yyv4816 = make([]UniqueVolumeName, yyrl4816) + yyv1 = make([]UniqueVolumeName, yyrl1) } - yyc4816 = true - yyrr4816 = len(yyv4816) - } else if yyl4816 != len(yyv4816) { - yyv4816 = yyv4816[:yyl4816] - yyc4816 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4816 := 0 - for ; yyj4816 < yyrr4816; yyj4816++ { - yyh4816.ElemContainerState(yyj4816) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4816[yyj4816] = "" + yyv1[yyj1] = "" } else { - yyv4816[yyj4816] = UniqueVolumeName(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4816 { - for ; yyj4816 < yyl4816; yyj4816++ { - yyv4816 = append(yyv4816, "") - yyh4816.ElemContainerState(yyj4816) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4816[yyj4816] = "" + yyv1[yyj1] = "" } else { - yyv4816[yyj4816] = UniqueVolumeName(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4816 := 0 - for ; !r.CheckBreak(); yyj4816++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4816 >= len(yyv4816) { - yyv4816 = append(yyv4816, "") // var yyz4816 UniqueVolumeName - yyc4816 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 UniqueVolumeName + yyc1 = true } - yyh4816.ElemContainerState(yyj4816) - if yyj4816 < len(yyv4816) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4816[yyj4816] = "" + yyv1[yyj1] = "" } else { - yyv4816[yyj4816] = UniqueVolumeName(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61563,17 +74540,17 @@ func (x codecSelfer1234) decSliceUniqueVolumeName(v *[]UniqueVolumeName, d *code } } - if yyj4816 < len(yyv4816) { - yyv4816 = yyv4816[:yyj4816] - yyc4816 = true - } else if yyj4816 == 0 && yyv4816 == nil { - yyv4816 = []UniqueVolumeName{} - yyc4816 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []UniqueVolumeName{} + yyc1 = true } } - yyh4816.End() - if yyc4816 { - *v = yyv4816 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61582,10 +74559,10 @@ func (x codecSelfer1234) encSliceAttachedVolume(v []AttachedVolume, e *codec1978 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4820 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4821 := &yyv4820 - yy4821.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61595,83 +74572,86 @@ func (x codecSelfer1234) decSliceAttachedVolume(v *[]AttachedVolume, d *codec197 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4822 := *v - yyh4822, yyl4822 := z.DecSliceHelperStart() - var yyc4822 bool - if yyl4822 == 0 { - if yyv4822 == nil { - yyv4822 = []AttachedVolume{} - yyc4822 = true - } else if len(yyv4822) != 0 { - yyv4822 = yyv4822[:0] - yyc4822 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []AttachedVolume{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4822 > 0 { - var yyrr4822, yyrl4822 int - var yyrt4822 bool - if yyl4822 > cap(yyv4822) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4822 := len(yyv4822) > 0 - yyv24822 := yyv4822 - yyrl4822, yyrt4822 = z.DecInferLen(yyl4822, z.DecBasicHandle().MaxInitLen, 32) - if yyrt4822 { - if yyrl4822 <= cap(yyv4822) { - yyv4822 = yyv4822[:yyrl4822] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 32) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4822 = make([]AttachedVolume, yyrl4822) + yyv1 = make([]AttachedVolume, yyrl1) } } else { - yyv4822 = make([]AttachedVolume, yyrl4822) + yyv1 = make([]AttachedVolume, yyrl1) } - yyc4822 = true - yyrr4822 = len(yyv4822) - if yyrg4822 { - copy(yyv4822, yyv24822) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4822 != len(yyv4822) { - yyv4822 = yyv4822[:yyl4822] - yyc4822 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4822 := 0 - for ; yyj4822 < yyrr4822; yyj4822++ { - yyh4822.ElemContainerState(yyj4822) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4822[yyj4822] = AttachedVolume{} + yyv1[yyj1] = AttachedVolume{} } else { - yyv4823 := &yyv4822[yyj4822] - yyv4823.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4822 { - for ; yyj4822 < yyl4822; yyj4822++ { - yyv4822 = append(yyv4822, AttachedVolume{}) - yyh4822.ElemContainerState(yyj4822) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, AttachedVolume{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4822[yyj4822] = AttachedVolume{} + yyv1[yyj1] = AttachedVolume{} } else { - yyv4824 := &yyv4822[yyj4822] - yyv4824.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4822 := 0 - for ; !r.CheckBreak(); yyj4822++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4822 >= len(yyv4822) { - yyv4822 = append(yyv4822, AttachedVolume{}) // var yyz4822 AttachedVolume - yyc4822 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, AttachedVolume{}) // var yyz1 AttachedVolume + yyc1 = true } - yyh4822.ElemContainerState(yyj4822) - if yyj4822 < len(yyv4822) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4822[yyj4822] = AttachedVolume{} + yyv1[yyj1] = AttachedVolume{} } else { - yyv4825 := &yyv4822[yyj4822] - yyv4825.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61679,17 +74659,17 @@ func (x codecSelfer1234) decSliceAttachedVolume(v *[]AttachedVolume, d *codec197 } } - if yyj4822 < len(yyv4822) { - yyv4822 = yyv4822[:yyj4822] - yyc4822 = true - } else if yyj4822 == 0 && yyv4822 == nil { - yyv4822 = []AttachedVolume{} - yyc4822 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []AttachedVolume{} + yyc1 = true } } - yyh4822.End() - if yyc4822 { - *v = yyv4822 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61698,10 +74678,10 @@ func (x codecSelfer1234) encSlicePreferAvoidPodsEntry(v []PreferAvoidPodsEntry, z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4826 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4827 := &yyv4826 - yy4827.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61711,83 +74691,86 @@ func (x codecSelfer1234) decSlicePreferAvoidPodsEntry(v *[]PreferAvoidPodsEntry, z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4828 := *v - yyh4828, yyl4828 := z.DecSliceHelperStart() - var yyc4828 bool - if yyl4828 == 0 { - if yyv4828 == nil { - yyv4828 = []PreferAvoidPodsEntry{} - yyc4828 = true - } else if len(yyv4828) != 0 { - yyv4828 = yyv4828[:0] - yyc4828 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PreferAvoidPodsEntry{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4828 > 0 { - var yyrr4828, yyrl4828 int - var yyrt4828 bool - if yyl4828 > cap(yyv4828) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4828 := len(yyv4828) > 0 - yyv24828 := yyv4828 - yyrl4828, yyrt4828 = z.DecInferLen(yyl4828, z.DecBasicHandle().MaxInitLen, 64) - if yyrt4828 { - if yyrl4828 <= cap(yyv4828) { - yyv4828 = yyv4828[:yyrl4828] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 64) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4828 = make([]PreferAvoidPodsEntry, yyrl4828) + yyv1 = make([]PreferAvoidPodsEntry, yyrl1) } } else { - yyv4828 = make([]PreferAvoidPodsEntry, yyrl4828) + yyv1 = make([]PreferAvoidPodsEntry, yyrl1) } - yyc4828 = true - yyrr4828 = len(yyv4828) - if yyrg4828 { - copy(yyv4828, yyv24828) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4828 != len(yyv4828) { - yyv4828 = yyv4828[:yyl4828] - yyc4828 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4828 := 0 - for ; yyj4828 < yyrr4828; yyj4828++ { - yyh4828.ElemContainerState(yyj4828) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4828[yyj4828] = PreferAvoidPodsEntry{} + yyv1[yyj1] = PreferAvoidPodsEntry{} } else { - yyv4829 := &yyv4828[yyj4828] - yyv4829.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4828 { - for ; yyj4828 < yyl4828; yyj4828++ { - yyv4828 = append(yyv4828, PreferAvoidPodsEntry{}) - yyh4828.ElemContainerState(yyj4828) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PreferAvoidPodsEntry{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4828[yyj4828] = PreferAvoidPodsEntry{} + yyv1[yyj1] = PreferAvoidPodsEntry{} } else { - yyv4830 := &yyv4828[yyj4828] - yyv4830.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4828 := 0 - for ; !r.CheckBreak(); yyj4828++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4828 >= len(yyv4828) { - yyv4828 = append(yyv4828, PreferAvoidPodsEntry{}) // var yyz4828 PreferAvoidPodsEntry - yyc4828 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PreferAvoidPodsEntry{}) // var yyz1 PreferAvoidPodsEntry + yyc1 = true } - yyh4828.ElemContainerState(yyj4828) - if yyj4828 < len(yyv4828) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4828[yyj4828] = PreferAvoidPodsEntry{} + yyv1[yyj1] = PreferAvoidPodsEntry{} } else { - yyv4831 := &yyv4828[yyj4828] - yyv4831.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -61795,17 +74778,17 @@ func (x codecSelfer1234) decSlicePreferAvoidPodsEntry(v *[]PreferAvoidPodsEntry, } } - if yyj4828 < len(yyv4828) { - yyv4828 = yyv4828[:yyj4828] - yyc4828 = true - } else if yyj4828 == 0 && yyv4828 == nil { - yyv4828 = []PreferAvoidPodsEntry{} - yyc4828 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PreferAvoidPodsEntry{} + yyc1 = true } } - yyh4828.End() - if yyc4828 { - *v = yyv4828 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -61814,19 +74797,19 @@ func (x codecSelfer1234) encResourceList(v ResourceList, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeMapStart(len(v)) - for yyk4832, yyv4832 := range v { + for yyk1, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerMapKey1234) - yyk4832.CodecEncodeSelf(e) + yyk1.CodecEncodeSelf(e) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy4833 := &yyv4832 - yym4834 := z.EncBinary() - _ = yym4834 + yy3 := &yyv1 + yym4 := z.EncBinary() + _ = yym4 if false { - } else if z.HasExtensions() && z.EncExt(yy4833) { - } else if !yym4834 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4833) + } else if z.HasExtensions() && z.EncExt(yy3) { + } else if !yym4 && z.IsJSONHandle() { + z.EncJSONMarshal(yy3) } else { - z.EncFallback(yy4833) + z.EncFallback(yy3) } } z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -61837,86 +74820,88 @@ func (x codecSelfer1234) decResourceList(v *ResourceList, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4835 := *v - yyl4835 := r.ReadMapStart() - yybh4835 := z.DecBasicHandle() - if yyv4835 == nil { - yyrl4835, _ := z.DecInferLen(yyl4835, yybh4835.MaxInitLen, 72) - yyv4835 = make(map[ResourceName]pkg3_resource.Quantity, yyrl4835) - *v = yyv4835 + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 72) + yyv1 = make(map[ResourceName]pkg3_resource.Quantity, yyrl1) + *v = yyv1 } - var yymk4835 ResourceName - var yymv4835 pkg3_resource.Quantity - var yymg4835 bool - if yybh4835.MapValueReset { - yymg4835 = true + var yymk1 ResourceName + var yymv1 pkg3_resource.Quantity + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true } - if yyl4835 > 0 { - for yyj4835 := 0; yyj4835 < yyl4835; yyj4835++ { + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk4835 = "" + yymk1 = "" } else { - yymk4835 = ResourceName(r.DecodeString()) + yyv2 := &yymk1 + yyv2.CodecDecodeSelf(d) } - if yymg4835 { - yymv4835 = yyv4835[yymk4835] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv4835 = pkg3_resource.Quantity{} + yymv1 = pkg3_resource.Quantity{} } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv4835 = pkg3_resource.Quantity{} + yymv1 = pkg3_resource.Quantity{} } else { - yyv4837 := &yymv4835 - yym4838 := z.DecBinary() - _ = yym4838 + yyv3 := &yymv1 + yym4 := z.DecBinary() + _ = yym4 if false { - } else if z.HasExtensions() && z.DecExt(yyv4837) { - } else if !yym4838 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4837) + } else if z.HasExtensions() && z.DecExt(yyv3) { + } else if !yym4 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv3) } else { - z.DecFallback(yyv4837, false) + z.DecFallback(yyv3, false) } } - if yyv4835 != nil { - yyv4835[yymk4835] = yymv4835 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } - } else if yyl4835 < 0 { - for yyj4835 := 0; !r.CheckBreak(); yyj4835++ { + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk4835 = "" + yymk1 = "" } else { - yymk4835 = ResourceName(r.DecodeString()) + yyv5 := &yymk1 + yyv5.CodecDecodeSelf(d) } - if yymg4835 { - yymv4835 = yyv4835[yymk4835] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv4835 = pkg3_resource.Quantity{} + yymv1 = pkg3_resource.Quantity{} } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv4835 = pkg3_resource.Quantity{} + yymv1 = pkg3_resource.Quantity{} } else { - yyv4840 := &yymv4835 - yym4841 := z.DecBinary() - _ = yym4841 + yyv6 := &yymv1 + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv4840) { - } else if !yym4841 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4840) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv4840, false) + z.DecFallback(yyv6, false) } } - if yyv4835 != nil { - yyv4835[yymk4835] = yymv4835 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } } // else len==0: TODO: Should we clear map entries? @@ -61928,10 +74913,10 @@ func (x codecSelfer1234) encSliceNode(v []Node, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4842 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4843 := &yyv4842 - yy4843.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -61941,83 +74926,86 @@ func (x codecSelfer1234) decSliceNode(v *[]Node, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4844 := *v - yyh4844, yyl4844 := z.DecSliceHelperStart() - var yyc4844 bool - if yyl4844 == 0 { - if yyv4844 == nil { - yyv4844 = []Node{} - yyc4844 = true - } else if len(yyv4844) != 0 { - yyv4844 = yyv4844[:0] - yyc4844 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Node{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4844 > 0 { - var yyrr4844, yyrl4844 int - var yyrt4844 bool - if yyl4844 > cap(yyv4844) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4844 := len(yyv4844) > 0 - yyv24844 := yyv4844 - yyrl4844, yyrt4844 = z.DecInferLen(yyl4844, z.DecBasicHandle().MaxInitLen, 632) - if yyrt4844 { - if yyrl4844 <= cap(yyv4844) { - yyv4844 = yyv4844[:yyrl4844] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 664) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4844 = make([]Node, yyrl4844) + yyv1 = make([]Node, yyrl1) } } else { - yyv4844 = make([]Node, yyrl4844) + yyv1 = make([]Node, yyrl1) } - yyc4844 = true - yyrr4844 = len(yyv4844) - if yyrg4844 { - copy(yyv4844, yyv24844) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4844 != len(yyv4844) { - yyv4844 = yyv4844[:yyl4844] - yyc4844 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4844 := 0 - for ; yyj4844 < yyrr4844; yyj4844++ { - yyh4844.ElemContainerState(yyj4844) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4844[yyj4844] = Node{} + yyv1[yyj1] = Node{} } else { - yyv4845 := &yyv4844[yyj4844] - yyv4845.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4844 { - for ; yyj4844 < yyl4844; yyj4844++ { - yyv4844 = append(yyv4844, Node{}) - yyh4844.ElemContainerState(yyj4844) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Node{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4844[yyj4844] = Node{} + yyv1[yyj1] = Node{} } else { - yyv4846 := &yyv4844[yyj4844] - yyv4846.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4844 := 0 - for ; !r.CheckBreak(); yyj4844++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4844 >= len(yyv4844) { - yyv4844 = append(yyv4844, Node{}) // var yyz4844 Node - yyc4844 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Node{}) // var yyz1 Node + yyc1 = true } - yyh4844.ElemContainerState(yyj4844) - if yyj4844 < len(yyv4844) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4844[yyj4844] = Node{} + yyv1[yyj1] = Node{} } else { - yyv4847 := &yyv4844[yyj4844] - yyv4847.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62025,17 +75013,17 @@ func (x codecSelfer1234) decSliceNode(v *[]Node, d *codec1978.Decoder) { } } - if yyj4844 < len(yyv4844) { - yyv4844 = yyv4844[:yyj4844] - yyc4844 = true - } else if yyj4844 == 0 && yyv4844 == nil { - yyv4844 = []Node{} - yyc4844 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Node{} + yyc1 = true } } - yyh4844.End() - if yyc4844 { - *v = yyv4844 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62044,9 +75032,9 @@ func (x codecSelfer1234) encSliceFinalizerName(v []FinalizerName, e *codec1978.E z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4848 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4848.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62056,75 +75044,81 @@ func (x codecSelfer1234) decSliceFinalizerName(v *[]FinalizerName, d *codec1978. z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4849 := *v - yyh4849, yyl4849 := z.DecSliceHelperStart() - var yyc4849 bool - if yyl4849 == 0 { - if yyv4849 == nil { - yyv4849 = []FinalizerName{} - yyc4849 = true - } else if len(yyv4849) != 0 { - yyv4849 = yyv4849[:0] - yyc4849 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []FinalizerName{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4849 > 0 { - var yyrr4849, yyrl4849 int - var yyrt4849 bool - if yyl4849 > cap(yyv4849) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl4849, yyrt4849 = z.DecInferLen(yyl4849, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4849 { - if yyrl4849 <= cap(yyv4849) { - yyv4849 = yyv4849[:yyrl4849] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4849 = make([]FinalizerName, yyrl4849) + yyv1 = make([]FinalizerName, yyrl1) } } else { - yyv4849 = make([]FinalizerName, yyrl4849) + yyv1 = make([]FinalizerName, yyrl1) } - yyc4849 = true - yyrr4849 = len(yyv4849) - } else if yyl4849 != len(yyv4849) { - yyv4849 = yyv4849[:yyl4849] - yyc4849 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4849 := 0 - for ; yyj4849 < yyrr4849; yyj4849++ { - yyh4849.ElemContainerState(yyj4849) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4849[yyj4849] = "" + yyv1[yyj1] = "" } else { - yyv4849[yyj4849] = FinalizerName(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4849 { - for ; yyj4849 < yyl4849; yyj4849++ { - yyv4849 = append(yyv4849, "") - yyh4849.ElemContainerState(yyj4849) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4849[yyj4849] = "" + yyv1[yyj1] = "" } else { - yyv4849[yyj4849] = FinalizerName(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4849 := 0 - for ; !r.CheckBreak(); yyj4849++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4849 >= len(yyv4849) { - yyv4849 = append(yyv4849, "") // var yyz4849 FinalizerName - yyc4849 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 FinalizerName + yyc1 = true } - yyh4849.ElemContainerState(yyj4849) - if yyj4849 < len(yyv4849) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4849[yyj4849] = "" + yyv1[yyj1] = "" } else { - yyv4849[yyj4849] = FinalizerName(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62132,17 +75126,17 @@ func (x codecSelfer1234) decSliceFinalizerName(v *[]FinalizerName, d *codec1978. } } - if yyj4849 < len(yyv4849) { - yyv4849 = yyv4849[:yyj4849] - yyc4849 = true - } else if yyj4849 == 0 && yyv4849 == nil { - yyv4849 = []FinalizerName{} - yyc4849 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []FinalizerName{} + yyc1 = true } } - yyh4849.End() - if yyc4849 { - *v = yyv4849 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62151,10 +75145,10 @@ func (x codecSelfer1234) encSliceNamespace(v []Namespace, e *codec1978.Encoder) z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4853 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4854 := &yyv4853 - yy4854.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62164,83 +75158,86 @@ func (x codecSelfer1234) decSliceNamespace(v *[]Namespace, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4855 := *v - yyh4855, yyl4855 := z.DecSliceHelperStart() - var yyc4855 bool - if yyl4855 == 0 { - if yyv4855 == nil { - yyv4855 = []Namespace{} - yyc4855 = true - } else if len(yyv4855) != 0 { - yyv4855 = yyv4855[:0] - yyc4855 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Namespace{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4855 > 0 { - var yyrr4855, yyrl4855 int - var yyrt4855 bool - if yyl4855 > cap(yyv4855) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4855 := len(yyv4855) > 0 - yyv24855 := yyv4855 - yyrl4855, yyrt4855 = z.DecInferLen(yyl4855, z.DecBasicHandle().MaxInitLen, 296) - if yyrt4855 { - if yyrl4855 <= cap(yyv4855) { - yyv4855 = yyv4855[:yyrl4855] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 304) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4855 = make([]Namespace, yyrl4855) + yyv1 = make([]Namespace, yyrl1) } } else { - yyv4855 = make([]Namespace, yyrl4855) + yyv1 = make([]Namespace, yyrl1) } - yyc4855 = true - yyrr4855 = len(yyv4855) - if yyrg4855 { - copy(yyv4855, yyv24855) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4855 != len(yyv4855) { - yyv4855 = yyv4855[:yyl4855] - yyc4855 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4855 := 0 - for ; yyj4855 < yyrr4855; yyj4855++ { - yyh4855.ElemContainerState(yyj4855) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4855[yyj4855] = Namespace{} + yyv1[yyj1] = Namespace{} } else { - yyv4856 := &yyv4855[yyj4855] - yyv4856.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4855 { - for ; yyj4855 < yyl4855; yyj4855++ { - yyv4855 = append(yyv4855, Namespace{}) - yyh4855.ElemContainerState(yyj4855) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Namespace{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4855[yyj4855] = Namespace{} + yyv1[yyj1] = Namespace{} } else { - yyv4857 := &yyv4855[yyj4855] - yyv4857.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4855 := 0 - for ; !r.CheckBreak(); yyj4855++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4855 >= len(yyv4855) { - yyv4855 = append(yyv4855, Namespace{}) // var yyz4855 Namespace - yyc4855 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Namespace{}) // var yyz1 Namespace + yyc1 = true } - yyh4855.ElemContainerState(yyj4855) - if yyj4855 < len(yyv4855) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4855[yyj4855] = Namespace{} + yyv1[yyj1] = Namespace{} } else { - yyv4858 := &yyv4855[yyj4855] - yyv4858.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62248,17 +75245,17 @@ func (x codecSelfer1234) decSliceNamespace(v *[]Namespace, d *codec1978.Decoder) } } - if yyj4855 < len(yyv4855) { - yyv4855 = yyv4855[:yyj4855] - yyc4855 = true - } else if yyj4855 == 0 && yyv4855 == nil { - yyv4855 = []Namespace{} - yyc4855 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Namespace{} + yyc1 = true } } - yyh4855.End() - if yyc4855 { - *v = yyv4855 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62267,10 +75264,10 @@ func (x codecSelfer1234) encSliceEvent(v []Event, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4859 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4860 := &yyv4859 - yy4860.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62280,83 +75277,86 @@ func (x codecSelfer1234) decSliceEvent(v *[]Event, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4861 := *v - yyh4861, yyl4861 := z.DecSliceHelperStart() - var yyc4861 bool - if yyl4861 == 0 { - if yyv4861 == nil { - yyv4861 = []Event{} - yyc4861 = true - } else if len(yyv4861) != 0 { - yyv4861 = yyv4861[:0] - yyc4861 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Event{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4861 > 0 { - var yyrr4861, yyrl4861 int - var yyrt4861 bool - if yyl4861 > cap(yyv4861) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4861 := len(yyv4861) > 0 - yyv24861 := yyv4861 - yyrl4861, yyrt4861 = z.DecInferLen(yyl4861, z.DecBasicHandle().MaxInitLen, 504) - if yyrt4861 { - if yyrl4861 <= cap(yyv4861) { - yyv4861 = yyv4861[:yyrl4861] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 512) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4861 = make([]Event, yyrl4861) + yyv1 = make([]Event, yyrl1) } } else { - yyv4861 = make([]Event, yyrl4861) + yyv1 = make([]Event, yyrl1) } - yyc4861 = true - yyrr4861 = len(yyv4861) - if yyrg4861 { - copy(yyv4861, yyv24861) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4861 != len(yyv4861) { - yyv4861 = yyv4861[:yyl4861] - yyc4861 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4861 := 0 - for ; yyj4861 < yyrr4861; yyj4861++ { - yyh4861.ElemContainerState(yyj4861) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4861[yyj4861] = Event{} + yyv1[yyj1] = Event{} } else { - yyv4862 := &yyv4861[yyj4861] - yyv4862.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4861 { - for ; yyj4861 < yyl4861; yyj4861++ { - yyv4861 = append(yyv4861, Event{}) - yyh4861.ElemContainerState(yyj4861) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Event{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4861[yyj4861] = Event{} + yyv1[yyj1] = Event{} } else { - yyv4863 := &yyv4861[yyj4861] - yyv4863.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4861 := 0 - for ; !r.CheckBreak(); yyj4861++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4861 >= len(yyv4861) { - yyv4861 = append(yyv4861, Event{}) // var yyz4861 Event - yyc4861 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Event{}) // var yyz1 Event + yyc1 = true } - yyh4861.ElemContainerState(yyj4861) - if yyj4861 < len(yyv4861) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4861[yyj4861] = Event{} + yyv1[yyj1] = Event{} } else { - yyv4864 := &yyv4861[yyj4861] - yyv4864.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62364,17 +75364,17 @@ func (x codecSelfer1234) decSliceEvent(v *[]Event, d *codec1978.Decoder) { } } - if yyj4861 < len(yyv4861) { - yyv4861 = yyv4861[:yyj4861] - yyc4861 = true - } else if yyj4861 == 0 && yyv4861 == nil { - yyv4861 = []Event{} - yyc4861 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Event{} + yyc1 = true } } - yyh4861.End() - if yyc4861 { - *v = yyv4861 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62383,17 +75383,17 @@ func (x codecSelfer1234) encSliceruntime_RawExtension(v []pkg5_runtime.RawExtens z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4865 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4866 := &yyv4865 - yym4867 := z.EncBinary() - _ = yym4867 + yy2 := &yyv1 + yym3 := z.EncBinary() + _ = yym3 if false { - } else if z.HasExtensions() && z.EncExt(yy4866) { - } else if !yym4867 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4866) + } else if z.HasExtensions() && z.EncExt(yy2) { + } else if !yym3 && z.IsJSONHandle() { + z.EncJSONMarshal(yy2) } else { - z.EncFallback(yy4866) + z.EncFallback(yy2) } } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) @@ -62404,78 +75404,81 @@ func (x codecSelfer1234) decSliceruntime_RawExtension(v *[]pkg5_runtime.RawExten z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4868 := *v - yyh4868, yyl4868 := z.DecSliceHelperStart() - var yyc4868 bool - if yyl4868 == 0 { - if yyv4868 == nil { - yyv4868 = []pkg5_runtime.RawExtension{} - yyc4868 = true - } else if len(yyv4868) != 0 { - yyv4868 = yyv4868[:0] - yyc4868 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []pkg5_runtime.RawExtension{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4868 > 0 { - var yyrr4868, yyrl4868 int - var yyrt4868 bool - if yyl4868 > cap(yyv4868) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4868 := len(yyv4868) > 0 - yyv24868 := yyv4868 - yyrl4868, yyrt4868 = z.DecInferLen(yyl4868, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4868 { - if yyrl4868 <= cap(yyv4868) { - yyv4868 = yyv4868[:yyrl4868] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4868 = make([]pkg5_runtime.RawExtension, yyrl4868) + yyv1 = make([]pkg5_runtime.RawExtension, yyrl1) } } else { - yyv4868 = make([]pkg5_runtime.RawExtension, yyrl4868) + yyv1 = make([]pkg5_runtime.RawExtension, yyrl1) } - yyc4868 = true - yyrr4868 = len(yyv4868) - if yyrg4868 { - copy(yyv4868, yyv24868) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4868 != len(yyv4868) { - yyv4868 = yyv4868[:yyl4868] - yyc4868 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4868 := 0 - for ; yyj4868 < yyrr4868; yyj4868++ { - yyh4868.ElemContainerState(yyj4868) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4868[yyj4868] = pkg5_runtime.RawExtension{} + yyv1[yyj1] = pkg5_runtime.RawExtension{} } else { - yyv4869 := &yyv4868[yyj4868] - yym4870 := z.DecBinary() - _ = yym4870 + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 if false { - } else if z.HasExtensions() && z.DecExt(yyv4869) { - } else if !yym4870 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4869) + } else if z.HasExtensions() && z.DecExt(yyv2) { + } else if !yym3 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv2) } else { - z.DecFallback(yyv4869, false) + z.DecFallback(yyv2, false) } } } - if yyrt4868 { - for ; yyj4868 < yyl4868; yyj4868++ { - yyv4868 = append(yyv4868, pkg5_runtime.RawExtension{}) - yyh4868.ElemContainerState(yyj4868) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, pkg5_runtime.RawExtension{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4868[yyj4868] = pkg5_runtime.RawExtension{} + yyv1[yyj1] = pkg5_runtime.RawExtension{} } else { - yyv4871 := &yyv4868[yyj4868] - yym4872 := z.DecBinary() - _ = yym4872 + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv4871) { - } else if !yym4872 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4871) + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv4) } else { - z.DecFallback(yyv4871, false) + z.DecFallback(yyv4, false) } } @@ -62483,27 +75486,27 @@ func (x codecSelfer1234) decSliceruntime_RawExtension(v *[]pkg5_runtime.RawExten } } else { - yyj4868 := 0 - for ; !r.CheckBreak(); yyj4868++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4868 >= len(yyv4868) { - yyv4868 = append(yyv4868, pkg5_runtime.RawExtension{}) // var yyz4868 pkg5_runtime.RawExtension - yyc4868 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, pkg5_runtime.RawExtension{}) // var yyz1 pkg5_runtime.RawExtension + yyc1 = true } - yyh4868.ElemContainerState(yyj4868) - if yyj4868 < len(yyv4868) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4868[yyj4868] = pkg5_runtime.RawExtension{} + yyv1[yyj1] = pkg5_runtime.RawExtension{} } else { - yyv4873 := &yyv4868[yyj4868] - yym4874 := z.DecBinary() - _ = yym4874 + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv4873) { - } else if !yym4874 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv4873) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv4873, false) + z.DecFallback(yyv6, false) } } @@ -62512,17 +75515,17 @@ func (x codecSelfer1234) decSliceruntime_RawExtension(v *[]pkg5_runtime.RawExten } } - if yyj4868 < len(yyv4868) { - yyv4868 = yyv4868[:yyj4868] - yyc4868 = true - } else if yyj4868 == 0 && yyv4868 == nil { - yyv4868 = []pkg5_runtime.RawExtension{} - yyc4868 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []pkg5_runtime.RawExtension{} + yyc1 = true } } - yyh4868.End() - if yyc4868 { - *v = yyv4868 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62531,10 +75534,10 @@ func (x codecSelfer1234) encSliceLimitRangeItem(v []LimitRangeItem, e *codec1978 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4875 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4876 := &yyv4875 - yy4876.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62544,83 +75547,86 @@ func (x codecSelfer1234) decSliceLimitRangeItem(v *[]LimitRangeItem, d *codec197 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4877 := *v - yyh4877, yyl4877 := z.DecSliceHelperStart() - var yyc4877 bool - if yyl4877 == 0 { - if yyv4877 == nil { - yyv4877 = []LimitRangeItem{} - yyc4877 = true - } else if len(yyv4877) != 0 { - yyv4877 = yyv4877[:0] - yyc4877 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []LimitRangeItem{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4877 > 0 { - var yyrr4877, yyrl4877 int - var yyrt4877 bool - if yyl4877 > cap(yyv4877) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4877 := len(yyv4877) > 0 - yyv24877 := yyv4877 - yyrl4877, yyrt4877 = z.DecInferLen(yyl4877, z.DecBasicHandle().MaxInitLen, 56) - if yyrt4877 { - if yyrl4877 <= cap(yyv4877) { - yyv4877 = yyv4877[:yyrl4877] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 56) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4877 = make([]LimitRangeItem, yyrl4877) + yyv1 = make([]LimitRangeItem, yyrl1) } } else { - yyv4877 = make([]LimitRangeItem, yyrl4877) + yyv1 = make([]LimitRangeItem, yyrl1) } - yyc4877 = true - yyrr4877 = len(yyv4877) - if yyrg4877 { - copy(yyv4877, yyv24877) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4877 != len(yyv4877) { - yyv4877 = yyv4877[:yyl4877] - yyc4877 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4877 := 0 - for ; yyj4877 < yyrr4877; yyj4877++ { - yyh4877.ElemContainerState(yyj4877) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4877[yyj4877] = LimitRangeItem{} + yyv1[yyj1] = LimitRangeItem{} } else { - yyv4878 := &yyv4877[yyj4877] - yyv4878.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4877 { - for ; yyj4877 < yyl4877; yyj4877++ { - yyv4877 = append(yyv4877, LimitRangeItem{}) - yyh4877.ElemContainerState(yyj4877) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, LimitRangeItem{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4877[yyj4877] = LimitRangeItem{} + yyv1[yyj1] = LimitRangeItem{} } else { - yyv4879 := &yyv4877[yyj4877] - yyv4879.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4877 := 0 - for ; !r.CheckBreak(); yyj4877++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4877 >= len(yyv4877) { - yyv4877 = append(yyv4877, LimitRangeItem{}) // var yyz4877 LimitRangeItem - yyc4877 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, LimitRangeItem{}) // var yyz1 LimitRangeItem + yyc1 = true } - yyh4877.ElemContainerState(yyj4877) - if yyj4877 < len(yyv4877) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4877[yyj4877] = LimitRangeItem{} + yyv1[yyj1] = LimitRangeItem{} } else { - yyv4880 := &yyv4877[yyj4877] - yyv4880.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62628,17 +75634,17 @@ func (x codecSelfer1234) decSliceLimitRangeItem(v *[]LimitRangeItem, d *codec197 } } - if yyj4877 < len(yyv4877) { - yyv4877 = yyv4877[:yyj4877] - yyc4877 = true - } else if yyj4877 == 0 && yyv4877 == nil { - yyv4877 = []LimitRangeItem{} - yyc4877 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []LimitRangeItem{} + yyc1 = true } } - yyh4877.End() - if yyc4877 { - *v = yyv4877 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62647,10 +75653,10 @@ func (x codecSelfer1234) encSliceLimitRange(v []LimitRange, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4881 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4882 := &yyv4881 - yy4882.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62660,83 +75666,86 @@ func (x codecSelfer1234) decSliceLimitRange(v *[]LimitRange, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4883 := *v - yyh4883, yyl4883 := z.DecSliceHelperStart() - var yyc4883 bool - if yyl4883 == 0 { - if yyv4883 == nil { - yyv4883 = []LimitRange{} - yyc4883 = true - } else if len(yyv4883) != 0 { - yyv4883 = yyv4883[:0] - yyc4883 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []LimitRange{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4883 > 0 { - var yyrr4883, yyrl4883 int - var yyrt4883 bool - if yyl4883 > cap(yyv4883) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4883 := len(yyv4883) > 0 - yyv24883 := yyv4883 - yyrl4883, yyrt4883 = z.DecInferLen(yyl4883, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4883 { - if yyrl4883 <= cap(yyv4883) { - yyv4883 = yyv4883[:yyrl4883] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4883 = make([]LimitRange, yyrl4883) + yyv1 = make([]LimitRange, yyrl1) } } else { - yyv4883 = make([]LimitRange, yyrl4883) + yyv1 = make([]LimitRange, yyrl1) } - yyc4883 = true - yyrr4883 = len(yyv4883) - if yyrg4883 { - copy(yyv4883, yyv24883) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4883 != len(yyv4883) { - yyv4883 = yyv4883[:yyl4883] - yyc4883 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4883 := 0 - for ; yyj4883 < yyrr4883; yyj4883++ { - yyh4883.ElemContainerState(yyj4883) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4883[yyj4883] = LimitRange{} + yyv1[yyj1] = LimitRange{} } else { - yyv4884 := &yyv4883[yyj4883] - yyv4884.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4883 { - for ; yyj4883 < yyl4883; yyj4883++ { - yyv4883 = append(yyv4883, LimitRange{}) - yyh4883.ElemContainerState(yyj4883) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, LimitRange{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4883[yyj4883] = LimitRange{} + yyv1[yyj1] = LimitRange{} } else { - yyv4885 := &yyv4883[yyj4883] - yyv4885.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4883 := 0 - for ; !r.CheckBreak(); yyj4883++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4883 >= len(yyv4883) { - yyv4883 = append(yyv4883, LimitRange{}) // var yyz4883 LimitRange - yyc4883 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, LimitRange{}) // var yyz1 LimitRange + yyc1 = true } - yyh4883.ElemContainerState(yyj4883) - if yyj4883 < len(yyv4883) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4883[yyj4883] = LimitRange{} + yyv1[yyj1] = LimitRange{} } else { - yyv4886 := &yyv4883[yyj4883] - yyv4886.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62744,17 +75753,17 @@ func (x codecSelfer1234) decSliceLimitRange(v *[]LimitRange, d *codec1978.Decode } } - if yyj4883 < len(yyv4883) { - yyv4883 = yyv4883[:yyj4883] - yyc4883 = true - } else if yyj4883 == 0 && yyv4883 == nil { - yyv4883 = []LimitRange{} - yyc4883 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []LimitRange{} + yyc1 = true } } - yyh4883.End() - if yyc4883 { - *v = yyv4883 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62763,9 +75772,9 @@ func (x codecSelfer1234) encSliceResourceQuotaScope(v []ResourceQuotaScope, e *c z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4887 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv4887.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62775,75 +75784,81 @@ func (x codecSelfer1234) decSliceResourceQuotaScope(v *[]ResourceQuotaScope, d * z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4888 := *v - yyh4888, yyl4888 := z.DecSliceHelperStart() - var yyc4888 bool - if yyl4888 == 0 { - if yyv4888 == nil { - yyv4888 = []ResourceQuotaScope{} - yyc4888 = true - } else if len(yyv4888) != 0 { - yyv4888 = yyv4888[:0] - yyc4888 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ResourceQuotaScope{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4888 > 0 { - var yyrr4888, yyrl4888 int - var yyrt4888 bool - if yyl4888 > cap(yyv4888) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl4888, yyrt4888 = z.DecInferLen(yyl4888, z.DecBasicHandle().MaxInitLen, 16) - if yyrt4888 { - if yyrl4888 <= cap(yyv4888) { - yyv4888 = yyv4888[:yyrl4888] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4888 = make([]ResourceQuotaScope, yyrl4888) + yyv1 = make([]ResourceQuotaScope, yyrl1) } } else { - yyv4888 = make([]ResourceQuotaScope, yyrl4888) + yyv1 = make([]ResourceQuotaScope, yyrl1) } - yyc4888 = true - yyrr4888 = len(yyv4888) - } else if yyl4888 != len(yyv4888) { - yyv4888 = yyv4888[:yyl4888] - yyc4888 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4888 := 0 - for ; yyj4888 < yyrr4888; yyj4888++ { - yyh4888.ElemContainerState(yyj4888) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4888[yyj4888] = "" + yyv1[yyj1] = "" } else { - yyv4888[yyj4888] = ResourceQuotaScope(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4888 { - for ; yyj4888 < yyl4888; yyj4888++ { - yyv4888 = append(yyv4888, "") - yyh4888.ElemContainerState(yyj4888) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4888[yyj4888] = "" + yyv1[yyj1] = "" } else { - yyv4888[yyj4888] = ResourceQuotaScope(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4888 := 0 - for ; !r.CheckBreak(); yyj4888++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4888 >= len(yyv4888) { - yyv4888 = append(yyv4888, "") // var yyz4888 ResourceQuotaScope - yyc4888 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 ResourceQuotaScope + yyc1 = true } - yyh4888.ElemContainerState(yyj4888) - if yyj4888 < len(yyv4888) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4888[yyj4888] = "" + yyv1[yyj1] = "" } else { - yyv4888[yyj4888] = ResourceQuotaScope(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62851,17 +75866,17 @@ func (x codecSelfer1234) decSliceResourceQuotaScope(v *[]ResourceQuotaScope, d * } } - if yyj4888 < len(yyv4888) { - yyv4888 = yyv4888[:yyj4888] - yyc4888 = true - } else if yyj4888 == 0 && yyv4888 == nil { - yyv4888 = []ResourceQuotaScope{} - yyc4888 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ResourceQuotaScope{} + yyc1 = true } } - yyh4888.End() - if yyc4888 { - *v = yyv4888 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62870,10 +75885,10 @@ func (x codecSelfer1234) encSliceResourceQuota(v []ResourceQuota, e *codec1978.E z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4892 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4893 := &yyv4892 - yy4893.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -62883,83 +75898,86 @@ func (x codecSelfer1234) decSliceResourceQuota(v *[]ResourceQuota, d *codec1978. z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4894 := *v - yyh4894, yyl4894 := z.DecSliceHelperStart() - var yyc4894 bool - if yyl4894 == 0 { - if yyv4894 == nil { - yyv4894 = []ResourceQuota{} - yyc4894 = true - } else if len(yyv4894) != 0 { - yyv4894 = yyv4894[:0] - yyc4894 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ResourceQuota{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4894 > 0 { - var yyrr4894, yyrl4894 int - var yyrt4894 bool - if yyl4894 > cap(yyv4894) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4894 := len(yyv4894) > 0 - yyv24894 := yyv4894 - yyrl4894, yyrt4894 = z.DecInferLen(yyl4894, z.DecBasicHandle().MaxInitLen, 304) - if yyrt4894 { - if yyrl4894 <= cap(yyv4894) { - yyv4894 = yyv4894[:yyrl4894] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 312) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4894 = make([]ResourceQuota, yyrl4894) + yyv1 = make([]ResourceQuota, yyrl1) } } else { - yyv4894 = make([]ResourceQuota, yyrl4894) + yyv1 = make([]ResourceQuota, yyrl1) } - yyc4894 = true - yyrr4894 = len(yyv4894) - if yyrg4894 { - copy(yyv4894, yyv24894) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4894 != len(yyv4894) { - yyv4894 = yyv4894[:yyl4894] - yyc4894 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4894 := 0 - for ; yyj4894 < yyrr4894; yyj4894++ { - yyh4894.ElemContainerState(yyj4894) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4894[yyj4894] = ResourceQuota{} + yyv1[yyj1] = ResourceQuota{} } else { - yyv4895 := &yyv4894[yyj4894] - yyv4895.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4894 { - for ; yyj4894 < yyl4894; yyj4894++ { - yyv4894 = append(yyv4894, ResourceQuota{}) - yyh4894.ElemContainerState(yyj4894) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ResourceQuota{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4894[yyj4894] = ResourceQuota{} + yyv1[yyj1] = ResourceQuota{} } else { - yyv4896 := &yyv4894[yyj4894] - yyv4896.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4894 := 0 - for ; !r.CheckBreak(); yyj4894++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4894 >= len(yyv4894) { - yyv4894 = append(yyv4894, ResourceQuota{}) // var yyz4894 ResourceQuota - yyc4894 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ResourceQuota{}) // var yyz1 ResourceQuota + yyc1 = true } - yyh4894.ElemContainerState(yyj4894) - if yyj4894 < len(yyv4894) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4894[yyj4894] = ResourceQuota{} + yyv1[yyj1] = ResourceQuota{} } else { - yyv4897 := &yyv4894[yyj4894] - yyv4897.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -62967,17 +75985,17 @@ func (x codecSelfer1234) decSliceResourceQuota(v *[]ResourceQuota, d *codec1978. } } - if yyj4894 < len(yyv4894) { - yyv4894 = yyv4894[:yyj4894] - yyc4894 = true - } else if yyj4894 == 0 && yyv4894 == nil { - yyv4894 = []ResourceQuota{} - yyc4894 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ResourceQuota{} + yyc1 = true } } - yyh4894.End() - if yyc4894 { - *v = yyv4894 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -62986,23 +76004,23 @@ func (x codecSelfer1234) encMapstringSliceuint8(v map[string][]uint8, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeMapStart(len(v)) - for yyk4898, yyv4898 := range v { + for yyk1, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym4899 := z.EncBinary() - _ = yym4899 + yym2 := z.EncBinary() + _ = yym2 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk4898)) + r.EncodeString(codecSelferC_UTF81234, string(yyk1)) } z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv4898 == nil { + if yyv1 == nil { r.EncodeNil() } else { - yym4900 := z.EncBinary() - _ = yym4900 + yym3 := z.EncBinary() + _ = yym3 if false { } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(yyv4898)) + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(yyv1)) } } } @@ -63014,95 +76032,121 @@ func (x codecSelfer1234) decMapstringSliceuint8(v *map[string][]uint8, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4901 := *v - yyl4901 := r.ReadMapStart() - yybh4901 := z.DecBasicHandle() - if yyv4901 == nil { - yyrl4901, _ := z.DecInferLen(yyl4901, yybh4901.MaxInitLen, 40) - yyv4901 = make(map[string][]uint8, yyrl4901) - *v = yyv4901 + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string][]uint8, yyrl1) + *v = yyv1 } - var yymk4901 string - var yymv4901 []uint8 - var yymg4901 bool - if yybh4901.MapValueReset { - yymg4901 = true + var yymk1 string + var yymv1 []uint8 + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true } - if yyl4901 > 0 { - for yyj4901 := 0; yyj4901 < yyl4901; yyj4901++ { + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk4901 = "" + yymk1 = "" } else { - yymk4901 = string(r.DecodeString()) + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } } - if yymg4901 { - yymv4901 = yyv4901[yymk4901] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv4901 = nil + yymv1 = nil } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv4901 = nil + yymv1 = nil } else { - yyv4903 := &yymv4901 - yym4904 := z.DecBinary() - _ = yym4904 + yyv4 := &yymv1 + yym5 := z.DecBinary() + _ = yym5 if false { } else { - *yyv4903 = r.DecodeBytes(*(*[]byte)(yyv4903), false, false) + *yyv4 = r.DecodeBytes(*(*[]byte)(yyv4), false, false) } } - if yyv4901 != nil { - yyv4901[yymk4901] = yymv4901 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } - } else if yyl4901 < 0 { - for yyj4901 := 0; !r.CheckBreak(); yyj4901++ { + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk4901 = "" + yymk1 = "" } else { - yymk4901 = string(r.DecodeString()) + yyv6 := &yymk1 + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - if yymg4901 { - yymv4901 = yyv4901[yymk4901] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv4901 = nil + yymv1 = nil } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv4901 = nil + yymv1 = nil } else { - yyv4906 := &yymv4901 - yym4907 := z.DecBinary() - _ = yym4907 + yyv8 := &yymv1 + yym9 := z.DecBinary() + _ = yym9 if false { } else { - *yyv4906 = r.DecodeBytes(*(*[]byte)(yyv4906), false, false) + *yyv8 = r.DecodeBytes(*(*[]byte)(yyv8), false, false) } } - if yyv4901 != nil { - yyv4901[yymk4901] = yymv4901 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } } // else len==0: TODO: Should we clear map entries? z.DecSendContainerState(codecSelfer_containerMapEnd1234) } +func (x codecSelfer1234) encSliceuint8(v []uint8, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(v)) +} + +func (x codecSelfer1234) decSliceuint8(v *[]uint8, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + *v = r.DecodeBytes(*((*[]byte)(v)), false, false) +} + 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 _, yyv4908 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4909 := &yyv4908 - yy4909.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -63112,83 +76156,86 @@ func (x codecSelfer1234) decSliceSecret(v *[]Secret, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4910 := *v - yyh4910, yyl4910 := z.DecSliceHelperStart() - var yyc4910 bool - if yyl4910 == 0 { - if yyv4910 == nil { - yyv4910 = []Secret{} - yyc4910 = true - } else if len(yyv4910) != 0 { - yyv4910 = yyv4910[:0] - yyc4910 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Secret{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4910 > 0 { - var yyrr4910, yyrl4910 int - var yyrt4910 bool - if yyl4910 > cap(yyv4910) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4910 := len(yyv4910) > 0 - yyv24910 := yyv4910 - yyrl4910, yyrt4910 = z.DecInferLen(yyl4910, z.DecBasicHandle().MaxInitLen, 288) - if yyrt4910 { - if yyrl4910 <= cap(yyv4910) { - yyv4910 = yyv4910[:yyrl4910] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 296) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4910 = make([]Secret, yyrl4910) + yyv1 = make([]Secret, yyrl1) } } else { - yyv4910 = make([]Secret, yyrl4910) + yyv1 = make([]Secret, yyrl1) } - yyc4910 = true - yyrr4910 = len(yyv4910) - if yyrg4910 { - copy(yyv4910, yyv24910) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4910 != len(yyv4910) { - yyv4910 = yyv4910[:yyl4910] - yyc4910 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4910 := 0 - for ; yyj4910 < yyrr4910; yyj4910++ { - yyh4910.ElemContainerState(yyj4910) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4910[yyj4910] = Secret{} + yyv1[yyj1] = Secret{} } else { - yyv4911 := &yyv4910[yyj4910] - yyv4911.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4910 { - for ; yyj4910 < yyl4910; yyj4910++ { - yyv4910 = append(yyv4910, Secret{}) - yyh4910.ElemContainerState(yyj4910) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Secret{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4910[yyj4910] = Secret{} + yyv1[yyj1] = Secret{} } else { - yyv4912 := &yyv4910[yyj4910] - yyv4912.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4910 := 0 - for ; !r.CheckBreak(); yyj4910++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4910 >= len(yyv4910) { - yyv4910 = append(yyv4910, Secret{}) // var yyz4910 Secret - yyc4910 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Secret{}) // var yyz1 Secret + yyc1 = true } - yyh4910.ElemContainerState(yyj4910) - if yyj4910 < len(yyv4910) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4910[yyj4910] = Secret{} + yyv1[yyj1] = Secret{} } else { - yyv4913 := &yyv4910[yyj4910] - yyv4913.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -63196,17 +76243,17 @@ func (x codecSelfer1234) decSliceSecret(v *[]Secret, d *codec1978.Decoder) { } } - if yyj4910 < len(yyv4910) { - yyv4910 = yyv4910[:yyj4910] - yyc4910 = true - } else if yyj4910 == 0 && yyv4910 == nil { - yyv4910 = []Secret{} - yyc4910 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Secret{} + yyc1 = true } } - yyh4910.End() - if yyc4910 { - *v = yyv4910 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -63215,10 +76262,10 @@ func (x codecSelfer1234) encSliceConfigMap(v []ConfigMap, e *codec1978.Encoder) z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4914 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4915 := &yyv4914 - yy4915.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -63228,83 +76275,86 @@ func (x codecSelfer1234) decSliceConfigMap(v *[]ConfigMap, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4916 := *v - yyh4916, yyl4916 := z.DecSliceHelperStart() - var yyc4916 bool - if yyl4916 == 0 { - if yyv4916 == nil { - yyv4916 = []ConfigMap{} - yyc4916 = true - } else if len(yyv4916) != 0 { - yyv4916 = yyv4916[:0] - yyc4916 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ConfigMap{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4916 > 0 { - var yyrr4916, yyrl4916 int - var yyrt4916 bool - if yyl4916 > cap(yyv4916) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4916 := len(yyv4916) > 0 - yyv24916 := yyv4916 - yyrl4916, yyrt4916 = z.DecInferLen(yyl4916, z.DecBasicHandle().MaxInitLen, 264) - if yyrt4916 { - if yyrl4916 <= cap(yyv4916) { - yyv4916 = yyv4916[:yyrl4916] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 272) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4916 = make([]ConfigMap, yyrl4916) + yyv1 = make([]ConfigMap, yyrl1) } } else { - yyv4916 = make([]ConfigMap, yyrl4916) + yyv1 = make([]ConfigMap, yyrl1) } - yyc4916 = true - yyrr4916 = len(yyv4916) - if yyrg4916 { - copy(yyv4916, yyv24916) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4916 != len(yyv4916) { - yyv4916 = yyv4916[:yyl4916] - yyc4916 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4916 := 0 - for ; yyj4916 < yyrr4916; yyj4916++ { - yyh4916.ElemContainerState(yyj4916) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4916[yyj4916] = ConfigMap{} + yyv1[yyj1] = ConfigMap{} } else { - yyv4917 := &yyv4916[yyj4916] - yyv4917.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4916 { - for ; yyj4916 < yyl4916; yyj4916++ { - yyv4916 = append(yyv4916, ConfigMap{}) - yyh4916.ElemContainerState(yyj4916) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ConfigMap{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4916[yyj4916] = ConfigMap{} + yyv1[yyj1] = ConfigMap{} } else { - yyv4918 := &yyv4916[yyj4916] - yyv4918.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4916 := 0 - for ; !r.CheckBreak(); yyj4916++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4916 >= len(yyv4916) { - yyv4916 = append(yyv4916, ConfigMap{}) // var yyz4916 ConfigMap - yyc4916 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ConfigMap{}) // var yyz1 ConfigMap + yyc1 = true } - yyh4916.ElemContainerState(yyj4916) - if yyj4916 < len(yyv4916) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4916[yyj4916] = ConfigMap{} + yyv1[yyj1] = ConfigMap{} } else { - yyv4919 := &yyv4916[yyj4916] - yyv4919.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -63312,17 +76362,17 @@ func (x codecSelfer1234) decSliceConfigMap(v *[]ConfigMap, d *codec1978.Decoder) } } - if yyj4916 < len(yyv4916) { - yyv4916 = yyv4916[:yyj4916] - yyc4916 = true - } else if yyj4916 == 0 && yyv4916 == nil { - yyv4916 = []ConfigMap{} - yyc4916 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ConfigMap{} + yyc1 = true } } - yyh4916.End() - if yyc4916 { - *v = yyv4916 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -63331,10 +76381,10 @@ func (x codecSelfer1234) encSliceComponentCondition(v []ComponentCondition, e *c z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4920 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4921 := &yyv4920 - yy4921.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -63344,83 +76394,86 @@ func (x codecSelfer1234) decSliceComponentCondition(v *[]ComponentCondition, d * z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4922 := *v - yyh4922, yyl4922 := z.DecSliceHelperStart() - var yyc4922 bool - if yyl4922 == 0 { - if yyv4922 == nil { - yyv4922 = []ComponentCondition{} - yyc4922 = true - } else if len(yyv4922) != 0 { - yyv4922 = yyv4922[:0] - yyc4922 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ComponentCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4922 > 0 { - var yyrr4922, yyrl4922 int - var yyrt4922 bool - if yyl4922 > cap(yyv4922) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4922 := len(yyv4922) > 0 - yyv24922 := yyv4922 - yyrl4922, yyrt4922 = z.DecInferLen(yyl4922, z.DecBasicHandle().MaxInitLen, 64) - if yyrt4922 { - if yyrl4922 <= cap(yyv4922) { - yyv4922 = yyv4922[:yyrl4922] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 64) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4922 = make([]ComponentCondition, yyrl4922) + yyv1 = make([]ComponentCondition, yyrl1) } } else { - yyv4922 = make([]ComponentCondition, yyrl4922) + yyv1 = make([]ComponentCondition, yyrl1) } - yyc4922 = true - yyrr4922 = len(yyv4922) - if yyrg4922 { - copy(yyv4922, yyv24922) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4922 != len(yyv4922) { - yyv4922 = yyv4922[:yyl4922] - yyc4922 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4922 := 0 - for ; yyj4922 < yyrr4922; yyj4922++ { - yyh4922.ElemContainerState(yyj4922) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4922[yyj4922] = ComponentCondition{} + yyv1[yyj1] = ComponentCondition{} } else { - yyv4923 := &yyv4922[yyj4922] - yyv4923.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4922 { - for ; yyj4922 < yyl4922; yyj4922++ { - yyv4922 = append(yyv4922, ComponentCondition{}) - yyh4922.ElemContainerState(yyj4922) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ComponentCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4922[yyj4922] = ComponentCondition{} + yyv1[yyj1] = ComponentCondition{} } else { - yyv4924 := &yyv4922[yyj4922] - yyv4924.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4922 := 0 - for ; !r.CheckBreak(); yyj4922++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4922 >= len(yyv4922) { - yyv4922 = append(yyv4922, ComponentCondition{}) // var yyz4922 ComponentCondition - yyc4922 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ComponentCondition{}) // var yyz1 ComponentCondition + yyc1 = true } - yyh4922.ElemContainerState(yyj4922) - if yyj4922 < len(yyv4922) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4922[yyj4922] = ComponentCondition{} + yyv1[yyj1] = ComponentCondition{} } else { - yyv4925 := &yyv4922[yyj4922] - yyv4925.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -63428,17 +76481,17 @@ func (x codecSelfer1234) decSliceComponentCondition(v *[]ComponentCondition, d * } } - if yyj4922 < len(yyv4922) { - yyv4922 = yyv4922[:yyj4922] - yyc4922 = true - } else if yyj4922 == 0 && yyv4922 == nil { - yyv4922 = []ComponentCondition{} - yyc4922 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ComponentCondition{} + yyc1 = true } } - yyh4922.End() - if yyc4922 { - *v = yyv4922 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -63447,10 +76500,10 @@ func (x codecSelfer1234) encSliceComponentStatus(v []ComponentStatus, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4926 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4927 := &yyv4926 - yy4927.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -63460,83 +76513,86 @@ func (x codecSelfer1234) decSliceComponentStatus(v *[]ComponentStatus, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4928 := *v - yyh4928, yyl4928 := z.DecSliceHelperStart() - var yyc4928 bool - if yyl4928 == 0 { - if yyv4928 == nil { - yyv4928 = []ComponentStatus{} - yyc4928 = true - } else if len(yyv4928) != 0 { - yyv4928 = yyv4928[:0] - yyc4928 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ComponentStatus{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4928 > 0 { - var yyrr4928, yyrl4928 int - var yyrt4928 bool - if yyl4928 > cap(yyv4928) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4928 := len(yyv4928) > 0 - yyv24928 := yyv4928 - yyrl4928, yyrt4928 = z.DecInferLen(yyl4928, z.DecBasicHandle().MaxInitLen, 280) - if yyrt4928 { - if yyrl4928 <= cap(yyv4928) { - yyv4928 = yyv4928[:yyrl4928] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4928 = make([]ComponentStatus, yyrl4928) + yyv1 = make([]ComponentStatus, yyrl1) } } else { - yyv4928 = make([]ComponentStatus, yyrl4928) + yyv1 = make([]ComponentStatus, yyrl1) } - yyc4928 = true - yyrr4928 = len(yyv4928) - if yyrg4928 { - copy(yyv4928, yyv24928) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4928 != len(yyv4928) { - yyv4928 = yyv4928[:yyl4928] - yyc4928 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4928 := 0 - for ; yyj4928 < yyrr4928; yyj4928++ { - yyh4928.ElemContainerState(yyj4928) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4928[yyj4928] = ComponentStatus{} + yyv1[yyj1] = ComponentStatus{} } else { - yyv4929 := &yyv4928[yyj4928] - yyv4929.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4928 { - for ; yyj4928 < yyl4928; yyj4928++ { - yyv4928 = append(yyv4928, ComponentStatus{}) - yyh4928.ElemContainerState(yyj4928) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ComponentStatus{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4928[yyj4928] = ComponentStatus{} + yyv1[yyj1] = ComponentStatus{} } else { - yyv4930 := &yyv4928[yyj4928] - yyv4930.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4928 := 0 - for ; !r.CheckBreak(); yyj4928++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4928 >= len(yyv4928) { - yyv4928 = append(yyv4928, ComponentStatus{}) // var yyz4928 ComponentStatus - yyc4928 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ComponentStatus{}) // var yyz1 ComponentStatus + yyc1 = true } - yyh4928.ElemContainerState(yyj4928) - if yyj4928 < len(yyv4928) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4928[yyj4928] = ComponentStatus{} + yyv1[yyj1] = ComponentStatus{} } else { - yyv4931 := &yyv4928[yyj4928] - yyv4931.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -63544,17 +76600,17 @@ func (x codecSelfer1234) decSliceComponentStatus(v *[]ComponentStatus, d *codec1 } } - if yyj4928 < len(yyv4928) { - yyv4928 = yyv4928[:yyj4928] - yyc4928 = true - } else if yyj4928 == 0 && yyv4928 == nil { - yyv4928 = []ComponentStatus{} - yyc4928 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ComponentStatus{} + yyc1 = true } } - yyh4928.End() - if yyc4928 { - *v = yyv4928 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -63563,10 +76619,10 @@ func (x codecSelfer1234) encSliceDownwardAPIVolumeFile(v []DownwardAPIVolumeFile z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv4932 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy4933 := &yyv4932 - yy4933.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -63576,83 +76632,86 @@ func (x codecSelfer1234) decSliceDownwardAPIVolumeFile(v *[]DownwardAPIVolumeFil z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv4934 := *v - yyh4934, yyl4934 := z.DecSliceHelperStart() - var yyc4934 bool - if yyl4934 == 0 { - if yyv4934 == nil { - yyv4934 = []DownwardAPIVolumeFile{} - yyc4934 = true - } else if len(yyv4934) != 0 { - yyv4934 = yyv4934[:0] - yyc4934 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []DownwardAPIVolumeFile{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl4934 > 0 { - var yyrr4934, yyrl4934 int - var yyrt4934 bool - if yyl4934 > cap(yyv4934) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg4934 := len(yyv4934) > 0 - yyv24934 := yyv4934 - yyrl4934, yyrt4934 = z.DecInferLen(yyl4934, z.DecBasicHandle().MaxInitLen, 40) - if yyrt4934 { - if yyrl4934 <= cap(yyv4934) { - yyv4934 = yyv4934[:yyrl4934] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv4934 = make([]DownwardAPIVolumeFile, yyrl4934) + yyv1 = make([]DownwardAPIVolumeFile, yyrl1) } } else { - yyv4934 = make([]DownwardAPIVolumeFile, yyrl4934) + yyv1 = make([]DownwardAPIVolumeFile, yyrl1) } - yyc4934 = true - yyrr4934 = len(yyv4934) - if yyrg4934 { - copy(yyv4934, yyv24934) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl4934 != len(yyv4934) { - yyv4934 = yyv4934[:yyl4934] - yyc4934 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj4934 := 0 - for ; yyj4934 < yyrr4934; yyj4934++ { - yyh4934.ElemContainerState(yyj4934) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4934[yyj4934] = DownwardAPIVolumeFile{} + yyv1[yyj1] = DownwardAPIVolumeFile{} } else { - yyv4935 := &yyv4934[yyj4934] - yyv4935.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt4934 { - for ; yyj4934 < yyl4934; yyj4934++ { - yyv4934 = append(yyv4934, DownwardAPIVolumeFile{}) - yyh4934.ElemContainerState(yyj4934) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, DownwardAPIVolumeFile{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv4934[yyj4934] = DownwardAPIVolumeFile{} + yyv1[yyj1] = DownwardAPIVolumeFile{} } else { - yyv4936 := &yyv4934[yyj4934] - yyv4936.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj4934 := 0 - for ; !r.CheckBreak(); yyj4934++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj4934 >= len(yyv4934) { - yyv4934 = append(yyv4934, DownwardAPIVolumeFile{}) // var yyz4934 DownwardAPIVolumeFile - yyc4934 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, DownwardAPIVolumeFile{}) // var yyz1 DownwardAPIVolumeFile + yyc1 = true } - yyh4934.ElemContainerState(yyj4934) - if yyj4934 < len(yyv4934) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv4934[yyj4934] = DownwardAPIVolumeFile{} + yyv1[yyj1] = DownwardAPIVolumeFile{} } else { - yyv4937 := &yyv4934[yyj4934] - yyv4937.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -63660,16 +76719,16 @@ func (x codecSelfer1234) decSliceDownwardAPIVolumeFile(v *[]DownwardAPIVolumeFil } } - if yyj4934 < len(yyv4934) { - yyv4934 = yyv4934[:yyj4934] - yyc4934 = true - } else if yyj4934 == 0 && yyv4934 == nil { - yyv4934 = []DownwardAPIVolumeFile{} - yyc4934 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []DownwardAPIVolumeFile{} + yyc1 = true } } - yyh4934.End() - if yyc4934 { - *v = yyv4934 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/types.go b/vendor/k8s.io/client-go/pkg/api/v1/types.go index ea543a8133..cdb0088c46 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/types.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/types.go @@ -17,11 +17,11 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/types" - "k8s.io/client-go/pkg/util/intstr" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/types" + "k8s.io/apimachinery/pkg/util/intstr" ) // The comments for the structs and fields can be used from go-restful to @@ -65,13 +65,15 @@ import ( // ObjectMeta is metadata that all persisted resources must have, which includes all objects // users must create. +// DEPRECATED: Use k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta instead - this type will be removed soon. +// +k8s:openapi-gen=false type ObjectMeta struct { // Name must be unique within a namespace. Is required when creating resources, although // some resources may allow a client to request the generation of an appropriate name // automatically. Name is primarily intended for creation idempotence and configuration // definition. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names // +optional Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"` @@ -89,7 +91,7 @@ type ObjectMeta struct { // should retry (optionally after the time indicated in the Retry-After header). // // Applied only if Name is not specified. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency // +optional GenerateName string `json:"generateName,omitempty" protobuf:"bytes,2,opt,name=generateName"` @@ -100,7 +102,7 @@ type ObjectMeta struct { // // Must be a DNS_LABEL. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/namespaces + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ // +optional Namespace string `json:"namespace,omitempty" protobuf:"bytes,3,opt,name=namespace"` @@ -116,9 +118,9 @@ type ObjectMeta struct { // // Populated by the system. // Read-only. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids // +optional - UID types.UID `json:"uid,omitempty" protobuf:"bytes,5,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"` + UID types.UID `json:"uid,omitempty" protobuf:"bytes,5,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"` // An opaque value that represents the internal version of this object that can // be used by clients to determine when objects have changed. May be used for optimistic @@ -129,7 +131,7 @@ type ObjectMeta struct { // Populated by the system. // Read-only. // Value must be treated as opaque by clients and . - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency // +optional ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,6,opt,name=resourceVersion"` @@ -145,9 +147,9 @@ type ObjectMeta struct { // Populated by the system. // Read-only. // Null for lists. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - CreationTimestamp unversioned.Time `json:"creationTimestamp,omitempty" protobuf:"bytes,8,opt,name=creationTimestamp"` + CreationTimestamp metav1.Time `json:"creationTimestamp,omitempty" protobuf:"bytes,8,opt,name=creationTimestamp"` // DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This // field is set by the server when a graceful deletion is requested by the user, and is not @@ -165,9 +167,9 @@ type ObjectMeta struct { // // Populated by the system when a graceful deletion is requested. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - DeletionTimestamp *unversioned.Time `json:"deletionTimestamp,omitempty" protobuf:"bytes,9,opt,name=deletionTimestamp"` + DeletionTimestamp *metav1.Time `json:"deletionTimestamp,omitempty" protobuf:"bytes,9,opt,name=deletionTimestamp"` // Number of seconds allowed for this object to gracefully terminate before // it will be removed from the system. Only set when deletionTimestamp is also set. @@ -179,14 +181,14 @@ type ObjectMeta struct { // Map of string keys and values that can be used to organize and categorize // (scope and select) objects. May match selectors of replication controllers // and services. - // More info: http://kubernetes.io/docs/user-guide/labels + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ // +optional Labels map[string]string `json:"labels,omitempty" protobuf:"bytes,11,rep,name=labels"` // Annotations is an unstructured key value map stored with a resource that may be // set by external tools to store and retrieve arbitrary metadata. They are not // queryable and should be preserved when modifying objects. - // More info: http://kubernetes.io/docs/user-guide/annotations + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ // +optional Annotations map[string]string `json:"annotations,omitempty" protobuf:"bytes,12,rep,name=annotations"` @@ -195,13 +197,27 @@ type ObjectMeta struct { // then an entry in this list will point to this controller, with the controller field set to true. // There cannot be more than one managing controller. // +optional - OwnerReferences []OwnerReference `json:"ownerReferences,omitempty" patchStrategy:"merge" patchMergeKey:"uid" protobuf:"bytes,13,rep,name=ownerReferences"` + // +patchMergeKey=uid + // +patchStrategy=merge + OwnerReferences []metav1.OwnerReference `json:"ownerReferences,omitempty" patchStrategy:"merge" patchMergeKey:"uid" protobuf:"bytes,13,rep,name=ownerReferences"` + + // An initializer is a controller which enforces some system invariant at object creation time. + // This field is a list of initializers that have not yet acted on this object. If nil or empty, + // this object has been completely initialized. Otherwise, the object is considered uninitialized + // and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to + // observe uninitialized objects. + // + // When an object is created, the system will populate this list with the current set of initializers. + // Only privileged users may set or modify this list. Once it is empty, it may not be modified further + // by any user. + Initializers *metav1.Initializers `json:"initializers,omitempty" patchStrategy:"merge" protobuf:"bytes,16,rep,name=initializers"` // Must be empty before the object is deleted from the registry. Each entry // is an identifier for the responsible component that will remove the entry // from the list. If the deletionTimestamp of the object is non-nil, entries // in this list can only be removed. // +optional + // +patchStrategy=merge Finalizers []string `json:"finalizers,omitempty" patchStrategy:"merge" protobuf:"bytes,14,rep,name=finalizers"` // The name of the cluster which the object belongs to. @@ -222,7 +238,7 @@ const ( type Volume struct { // Volume's name. // Must be a DNS_LABEL and unique within the pod. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names Name string `json:"name" protobuf:"bytes,1,opt,name=name"` // VolumeSource represents the location and type of the mounted volume. // If not specified, the Volume is implied to be an EmptyDir. @@ -237,53 +253,53 @@ type VolumeSource struct { // machine that is directly exposed to the container. This is generally // used for system agents or other privileged things that are allowed // to see the host machine. Most containers will NOT need this. - // More info: http://kubernetes.io/docs/user-guide/volumes#hostpath + // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath // --- // TODO(jonesdl) We need to restrict who can use host directory mounts and who can/can not // mount host directories as read/write. // +optional HostPath *HostPathVolumeSource `json:"hostPath,omitempty" protobuf:"bytes,1,opt,name=hostPath"` // EmptyDir represents a temporary directory that shares a pod's lifetime. - // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional EmptyDir *EmptyDirVolumeSource `json:"emptyDir,omitempty" protobuf:"bytes,2,opt,name=emptyDir"` // GCEPersistentDisk represents a GCE Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional GCEPersistentDisk *GCEPersistentDiskVolumeSource `json:"gcePersistentDisk,omitempty" protobuf:"bytes,3,opt,name=gcePersistentDisk"` // AWSElasticBlockStore represents an AWS Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // +optional AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource `json:"awsElasticBlockStore,omitempty" protobuf:"bytes,4,opt,name=awsElasticBlockStore"` // GitRepo represents a git repository at a particular revision. // +optional GitRepo *GitRepoVolumeSource `json:"gitRepo,omitempty" protobuf:"bytes,5,opt,name=gitRepo"` // Secret represents a secret that should populate this volume. - // More info: http://kubernetes.io/docs/user-guide/volumes#secrets + // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret // +optional Secret *SecretVolumeSource `json:"secret,omitempty" protobuf:"bytes,6,opt,name=secret"` // NFS represents an NFS mount on the host that shares a pod's lifetime - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs // +optional NFS *NFSVolumeSource `json:"nfs,omitempty" protobuf:"bytes,7,opt,name=nfs"` // ISCSI represents an ISCSI Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md // +optional ISCSI *ISCSIVolumeSource `json:"iscsi,omitempty" protobuf:"bytes,8,opt,name=iscsi"` // Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md // +optional Glusterfs *GlusterfsVolumeSource `json:"glusterfs,omitempty" protobuf:"bytes,9,opt,name=glusterfs"` // PersistentVolumeClaimVolumeSource represents a reference to a // PersistentVolumeClaim in the same namespace. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims // +optional PersistentVolumeClaim *PersistentVolumeClaimVolumeSource `json:"persistentVolumeClaim,omitempty" protobuf:"bytes,10,opt,name=persistentVolumeClaim"` // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md // +optional RBD *RBDVolumeSource `json:"rbd,omitempty" protobuf:"bytes,11,opt,name=rbd"` // FlexVolume represents a generic volume resource that is @@ -292,7 +308,7 @@ type VolumeSource struct { // +optional FlexVolume *FlexVolumeSource `json:"flexVolume,omitempty" protobuf:"bytes,12,opt,name=flexVolume"` // Cinder represents a cinder volume attached and mounted on kubelets host machine - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional Cinder *CinderVolumeSource `json:"cinder,omitempty" protobuf:"bytes,13,opt,name=cinder"` // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime @@ -324,6 +340,17 @@ type VolumeSource struct { AzureDisk *AzureDiskVolumeSource `json:"azureDisk,omitempty" protobuf:"bytes,22,opt,name=azureDisk"` // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine PhotonPersistentDisk *PhotonPersistentDiskVolumeSource `json:"photonPersistentDisk,omitempty" protobuf:"bytes,23,opt,name=photonPersistentDisk"` + // Items for all in one resources secrets, configmaps, and downward API + Projected *ProjectedVolumeSource `json:"projected,omitempty" protobuf:"bytes,26,opt,name=projected"` + // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine + // +optional + PortworxVolume *PortworxVolumeSource `json:"portworxVolume,omitempty" protobuf:"bytes,24,opt,name=portworxVolume"` + // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. + // +optional + ScaleIO *ScaleIOVolumeSource `json:"scaleIO,omitempty" protobuf:"bytes,25,opt,name=scaleIO"` + // StorageOS represents a StorageOS volume attached and mounted on Kubernetes nodes. + // +optional + StorageOS *StorageOSVolumeSource `json:"storageos,omitempty" protobuf:"bytes,27,opt,name=storageos"` } // PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. @@ -332,7 +359,7 @@ type VolumeSource struct { // type of volume that is owned by someone else (the system). type PersistentVolumeClaimVolumeSource struct { // ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims ClaimName string `json:"claimName" protobuf:"bytes,1,opt,name=claimName"` // Will force the ReadOnly setting in VolumeMounts. // Default false. @@ -345,32 +372,32 @@ type PersistentVolumeClaimVolumeSource struct { type PersistentVolumeSource struct { // GCEPersistentDisk represents a GCE Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. Provisioned by an admin. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional GCEPersistentDisk *GCEPersistentDiskVolumeSource `json:"gcePersistentDisk,omitempty" protobuf:"bytes,1,opt,name=gcePersistentDisk"` // AWSElasticBlockStore represents an AWS Disk resource that is attached to a // kubelet's host machine and then exposed to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // +optional AWSElasticBlockStore *AWSElasticBlockStoreVolumeSource `json:"awsElasticBlockStore,omitempty" protobuf:"bytes,2,opt,name=awsElasticBlockStore"` // HostPath represents a directory on the host. // Provisioned by a developer or tester. // This is useful for single-node development and testing only! // On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. - // More info: http://kubernetes.io/docs/user-guide/volumes#hostpath + // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath // +optional HostPath *HostPathVolumeSource `json:"hostPath,omitempty" protobuf:"bytes,3,opt,name=hostPath"` // Glusterfs represents a Glusterfs volume that is attached to a host and // exposed to the pod. Provisioned by an admin. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md // +optional Glusterfs *GlusterfsVolumeSource `json:"glusterfs,omitempty" protobuf:"bytes,4,opt,name=glusterfs"` // NFS represents an NFS mount on the host. Provisioned by an admin. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs // +optional NFS *NFSVolumeSource `json:"nfs,omitempty" protobuf:"bytes,5,opt,name=nfs"` // RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md // +optional RBD *RBDVolumeSource `json:"rbd,omitempty" protobuf:"bytes,6,opt,name=rbd"` // ISCSI represents an ISCSI Disk resource that is attached to a @@ -378,7 +405,7 @@ type PersistentVolumeSource struct { // +optional ISCSI *ISCSIVolumeSource `json:"iscsi,omitempty" protobuf:"bytes,7,opt,name=iscsi"` // Cinder represents a cinder volume attached and mounted on kubelets host machine - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional Cinder *CinderVolumeSource `json:"cinder,omitempty" protobuf:"bytes,8,opt,name=cinder"` // CephFS represents a Ceph FS mount on the host that shares a pod's lifetime @@ -409,31 +436,57 @@ type PersistentVolumeSource struct { AzureDisk *AzureDiskVolumeSource `json:"azureDisk,omitempty" protobuf:"bytes,16,opt,name=azureDisk"` // PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine PhotonPersistentDisk *PhotonPersistentDiskVolumeSource `json:"photonPersistentDisk,omitempty" protobuf:"bytes,17,opt,name=photonPersistentDisk"` + // PortworxVolume represents a portworx volume attached and mounted on kubelets host machine + // +optional + PortworxVolume *PortworxVolumeSource `json:"portworxVolume,omitempty" protobuf:"bytes,18,opt,name=portworxVolume"` + // ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes. + // +optional + ScaleIO *ScaleIOVolumeSource `json:"scaleIO,omitempty" protobuf:"bytes,19,opt,name=scaleIO"` + // Local represents directly-attached storage with node affinity + // +optional + Local *LocalVolumeSource `json:"local,omitempty" protobuf:"bytes,20,opt,name=local"` + // StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md + // +optional + StorageOS *StorageOSPersistentVolumeSource `json:"storageos,omitempty" protobuf:"bytes,21,opt,name=storageos"` } +const ( + // BetaStorageClassAnnotation represents the beta/previous StorageClass annotation. + // It's currently still used and will be held for backwards compatibility + BetaStorageClassAnnotation = "volume.beta.kubernetes.io/storage-class" + + // MountOptionAnnotation defines mount option annotation used in PVs + MountOptionAnnotation = "volume.beta.kubernetes.io/mount-options" + + // AlphaStorageNodeAffinityAnnotation defines node affinity policies for a PersistentVolume. + // Value is a string of the json representation of type NodeAffinity + AlphaStorageNodeAffinityAnnotation = "volume.alpha.kubernetes.io/node-affinity" +) + // +genclient=true // +nonNamespaced=true // PersistentVolume (PV) is a storage resource provisioned by an administrator. // It is analogous to a node. -// More info: http://kubernetes.io/docs/user-guide/persistent-volumes +// More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes type PersistentVolume struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines a specification of a persistent volume owned by the cluster. // Provisioned by an administrator. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistent-volumes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes // +optional Spec PersistentVolumeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Status represents the current information/status for the persistent volume. // Populated by the system. // Read-only. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistent-volumes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes // +optional Status PersistentVolumeStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } @@ -441,27 +494,31 @@ type PersistentVolume struct { // PersistentVolumeSpec is the specification of a persistent volume. type PersistentVolumeSpec struct { // A description of the persistent volume's resources and capacity. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#capacity + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity // +optional Capacity ResourceList `json:"capacity,omitempty" protobuf:"bytes,1,rep,name=capacity,casttype=ResourceList,castkey=ResourceName"` // The actual volume backing the persistent volume. PersistentVolumeSource `json:",inline" protobuf:"bytes,2,opt,name=persistentVolumeSource"` // AccessModes contains all ways the volume can be mounted. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes // +optional AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty" protobuf:"bytes,3,rep,name=accessModes,casttype=PersistentVolumeAccessMode"` // ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. // Expected to be non-nil when bound. // claim.VolumeName is the authoritative bind between PV and PVC. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#binding + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding // +optional ClaimRef *ObjectReference `json:"claimRef,omitempty" protobuf:"bytes,4,opt,name=claimRef"` // What happens to a persistent volume when released from its claim. // Valid options are Retain (default) and Recycle. // Recycling must be supported by the volume plugin underlying this persistent volume. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#recycling-policy + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming // +optional PersistentVolumeReclaimPolicy PersistentVolumeReclaimPolicy `json:"persistentVolumeReclaimPolicy,omitempty" protobuf:"bytes,5,opt,name=persistentVolumeReclaimPolicy,casttype=PersistentVolumeReclaimPolicy"` + // Name of StorageClass to which this persistent volume belongs. Empty value + // means that this volume does not belong to any StorageClass. + // +optional + StorageClassName string `json:"storageClassName,omitempty" protobuf:"bytes,6,opt,name=storageClassName"` } // PersistentVolumeReclaimPolicy describes a policy for end-of-life maintenance of persistent volumes. @@ -482,7 +539,7 @@ const ( // PersistentVolumeStatus is the current status of a persistent volume. type PersistentVolumeStatus struct { // Phase indicates if a volume is available, bound to a claim, or released by a claim. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#phase + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase // +optional Phase PersistentVolumePhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=PersistentVolumePhase"` // A human-readable message indicating details about why the volume is in this state. @@ -496,13 +553,13 @@ type PersistentVolumeStatus struct { // PersistentVolumeList is a list of PersistentVolume items. type PersistentVolumeList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of persistent volumes. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes Items []PersistentVolume `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -510,33 +567,33 @@ type PersistentVolumeList struct { // PersistentVolumeClaim is a user's request for and claim to a persistent volume type PersistentVolumeClaim struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the desired characteristics of a volume requested by a pod author. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims // +optional Spec PersistentVolumeClaimSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Status represents the current information/status of a persistent volume claim. // Read-only. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims // +optional Status PersistentVolumeClaimStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // PersistentVolumeClaimList is a list of PersistentVolumeClaim items. type PersistentVolumeClaimList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // A list of persistent volume claims. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims Items []PersistentVolumeClaim `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -544,19 +601,23 @@ type PersistentVolumeClaimList struct { // and allows a Source for provider-specific attributes type PersistentVolumeClaimSpec struct { // AccessModes contains the desired access modes the volume should have. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes-1 + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 // +optional AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty" protobuf:"bytes,1,rep,name=accessModes,casttype=PersistentVolumeAccessMode"` // A label query over volumes to consider for binding. // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"` // Resources represents the minimum resources the volume should have. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#resources + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources // +optional Resources ResourceRequirements `json:"resources,omitempty" protobuf:"bytes,2,opt,name=resources"` // VolumeName is the binding reference to the PersistentVolume backing this claim. // +optional VolumeName string `json:"volumeName,omitempty" protobuf:"bytes,3,opt,name=volumeName"` + // Name of the StorageClass required by the claim. + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1 + // +optional + StorageClassName *string `json:"storageClassName,omitempty" protobuf:"bytes,5,opt,name=storageClassName"` } // PersistentVolumeClaimStatus is the current status of a persistent volume claim. @@ -565,7 +626,7 @@ type PersistentVolumeClaimStatus struct { // +optional Phase PersistentVolumeClaimPhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=PersistentVolumeClaimPhase"` // AccessModes contains the actual access modes the volume backing the PVC has. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes-1 + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1 // +optional AccessModes []PersistentVolumeAccessMode `json:"accessModes,omitempty" protobuf:"bytes,2,rep,name=accessModes,casttype=PersistentVolumeAccessMode"` // Represents the actual resources of the underlying volume. @@ -619,7 +680,7 @@ const ( // Host path volumes do not support ownership management or SELinux relabeling. type HostPathVolumeSource struct { // Path of the directory on the host. - // More info: http://kubernetes.io/docs/user-guide/volumes#hostpath + // More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath Path string `json:"path" protobuf:"bytes,1,opt,name=path"` } @@ -629,25 +690,33 @@ type EmptyDirVolumeSource struct { // What type of storage medium should back this directory. // The default is "" which means to use the node's default medium. // Must be an empty string (default) or Memory. - // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir // +optional Medium StorageMedium `json:"medium,omitempty" protobuf:"bytes,1,opt,name=medium,casttype=StorageMedium"` + // Total amount of local storage required for this EmptyDir volume. + // The size limit is also applicable for memory medium. + // The maximum usage on memory medium EmptyDir would be the minimum value between + // the SizeLimit specified here and the sum of memory limits of all containers in a pod. + // The default is nil which means that the limit is undefined. + // More info: http://kubernetes.io/docs/user-guide/volumes#emptydir + // +optional + SizeLimit resource.Quantity `json:"sizeLimit,omitempty" protobuf:"bytes,2,opt,name=sizeLimit"` } // Represents a Glusterfs mount that lasts the lifetime of a pod. // Glusterfs volumes do not support ownership management or SELinux relabeling. type GlusterfsVolumeSource struct { // EndpointsName is the endpoint name that details Glusterfs topology. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod EndpointsName string `json:"endpoints" protobuf:"bytes,1,opt,name=endpoints"` // Path is the Glusterfs volume path. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod Path string `json:"path" protobuf:"bytes,2,opt,name=path"` // ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. // Defaults to false. - // More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod + // More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"` } @@ -656,42 +725,42 @@ type GlusterfsVolumeSource struct { // RBD volumes support ownership management and SELinux relabeling. type RBDVolumeSource struct { // A collection of Ceph monitors. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it CephMonitors []string `json:"monitors" protobuf:"bytes,1,rep,name=monitors"` // The rados image name. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it RBDImage string `json:"image" protobuf:"bytes,2,opt,name=image"` // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#rbd + // More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional FSType string `json:"fsType,omitempty" protobuf:"bytes,3,opt,name=fsType"` // The rados pool name. // Default is rbd. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it. + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional RBDPool string `json:"pool,omitempty" protobuf:"bytes,4,opt,name=pool"` // The rados user name. // Default is admin. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional RadosUser string `json:"user,omitempty" protobuf:"bytes,5,opt,name=user"` // Keyring is the path to key ring for RBDUser. // Default is /etc/ceph/keyring. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional Keyring string `json:"keyring,omitempty" protobuf:"bytes,6,opt,name=keyring"` // SecretRef is name of the authentication secret for RBDUser. If provided // overrides keyring. // Default is nil. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,7,opt,name=secretRef"` // ReadOnly here will force the ReadOnly setting in VolumeMounts. // Defaults to false. - // More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,8,opt,name=readOnly"` } @@ -702,17 +771,17 @@ type RBDVolumeSource struct { // Cinder volumes support ownership management and SELinux relabeling. type CinderVolumeSource struct { // volume id used to identify the volume in cinder - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md VolumeID string `json:"volumeID" protobuf:"bytes,1,opt,name=volumeID"` // Filesystem type to mount. // Must be a filesystem type supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"` // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. - // More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md + // More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"` } @@ -721,26 +790,26 @@ type CinderVolumeSource struct { // Cephfs volumes do not support ownership management or SELinux relabeling. type CephFSVolumeSource struct { // Required: Monitors is a collection of Ceph monitors - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it Monitors []string `json:"monitors" protobuf:"bytes,1,rep,name=monitors"` // Optional: Used as the mounted root, rather than the full Ceph tree, default is / // +optional Path string `json:"path,omitempty" protobuf:"bytes,2,opt,name=path"` // Optional: User is the rados user name, default is admin - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional User string `json:"user,omitempty" protobuf:"bytes,3,opt,name=user"` // Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional SecretFile string `json:"secretFile,omitempty" protobuf:"bytes,4,opt,name=secretFile"` // Optional: SecretRef is reference to the authentication secret for User, default is empty. - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,5,opt,name=secretRef"` // Optional: Defaults to false (read/write). ReadOnly here will force // the ReadOnly setting in VolumeMounts. - // More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it + // More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,6,opt,name=readOnly"` } @@ -784,12 +853,12 @@ const ( // PDs support ownership management and SELinux relabeling. type GCEPersistentDiskVolumeSource struct { // Unique name of the PD resource in GCE. Used to identify the disk in GCE. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk PDName string `json:"pdName" protobuf:"bytes,1,opt,name=pdName"` // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"` @@ -797,12 +866,12 @@ type GCEPersistentDiskVolumeSource struct { // If omitted, the default is to mount by volume name. // Examples: For volume /dev/sda1, you specify the partition as "1". // Similarly, the volume partition for /dev/sda is "0" (or you can leave the property empty). - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional Partition int32 `json:"partition,omitempty" protobuf:"varint,3,opt,name=partition"` // ReadOnly here will force the ReadOnly setting in VolumeMounts. // Defaults to false. - // More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk + // More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"` } @@ -868,12 +937,12 @@ type FlexVolumeSource struct { // ownership management and SELinux relabeling. type AWSElasticBlockStoreVolumeSource struct { // Unique ID of the persistent disk resource in AWS (Amazon EBS volume). - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore VolumeID string `json:"volumeID" protobuf:"bytes,1,opt,name=volumeID"` // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"` @@ -885,7 +954,7 @@ type AWSElasticBlockStoreVolumeSource struct { Partition int32 `json:"partition,omitempty" protobuf:"varint,3,opt,name=partition"` // Specify "true" to force and set the ReadOnly property in VolumeMounts to "true". // If omitted, the default is "false". - // More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore + // More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"` } @@ -914,7 +983,7 @@ type GitRepoVolumeSource struct { // Secret volumes support ownership management and SELinux relabeling. type SecretVolumeSource struct { // Name of the secret in the pod's namespace to use. - // More info: http://kubernetes.io/docs/user-guide/volumes#secrets + // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret // +optional SecretName string `json:"secretName,omitempty" protobuf:"bytes,1,opt,name=secretName"` // If unspecified, each key-value pair in the Data field of the referenced @@ -922,8 +991,8 @@ type SecretVolumeSource struct { // key and content is the value. If specified, the listed keys will be // projected into the specified paths, and unlisted keys will not be // present. If a key is specified which is not present in the Secret, - // the volume setup will error. Paths must be relative and may not contain - // the '..' path or start with '..'. + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. // +optional Items []KeyToPath `json:"items,omitempty" protobuf:"bytes,2,rep,name=items"` // Optional: mode bits to use on created files by default. Must be a @@ -933,27 +1002,52 @@ type SecretVolumeSource struct { // mode, like fsGroup, and the result can be other mode bits set. // +optional DefaultMode *int32 `json:"defaultMode,omitempty" protobuf:"bytes,3,opt,name=defaultMode"` + // Specify whether the Secret or it's keys must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,4,opt,name=optional"` } const ( SecretVolumeSourceDefaultMode int32 = 0644 ) +// Adapts a secret into a projected volume. +// +// The contents of the target Secret's Data field will be presented in a +// projected volume as files using the keys in the Data field as the file names. +// Note that this is identical to a secret volume source without the default +// mode. +type SecretProjection struct { + LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"` + // If unspecified, each key-value pair in the Data field of the referenced + // Secret will be projected into the volume as a file whose name is the + // key and content is the value. If specified, the listed keys will be + // projected into the specified paths, and unlisted keys will not be + // present. If a key is specified which is not present in the Secret, + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. + // +optional + Items []KeyToPath `json:"items,omitempty" protobuf:"bytes,2,rep,name=items"` + // Specify whether the Secret or its key must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,4,opt,name=optional"` +} + // Represents an NFS mount that lasts the lifetime of a pod. // NFS volumes do not support ownership management or SELinux relabeling. type NFSVolumeSource struct { // Server is the hostname or IP address of the NFS server. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs Server string `json:"server" protobuf:"bytes,1,opt,name=server"` // Path that is exported by the NFS server. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs Path string `json:"path" protobuf:"bytes,2,opt,name=path"` // ReadOnly here will force // the NFS export to be mounted with read-only permissions. // Defaults to false. - // More info: http://kubernetes.io/docs/user-guide/volumes#nfs + // More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"` } @@ -975,7 +1069,7 @@ type ISCSIVolumeSource struct { // Filesystem type of the volume that you want to mount. // Tip: Ensure that the filesystem type is supported by the host operating system. // Examples: "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. - // More info: http://kubernetes.io/docs/user-guide/volumes#iscsi + // More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi // TODO: how do we prevent errors in the filesystem from compromising the machine // +optional FSType string `json:"fsType,omitempty" protobuf:"bytes,5,opt,name=fsType"` @@ -983,6 +1077,19 @@ type ISCSIVolumeSource struct { // Defaults to false. // +optional ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,6,opt,name=readOnly"` + // iSCSI target portal List. The portal is either an IP or ip_addr:port if the port + // is other than default (typically TCP ports 860 and 3260). + // +optional + Portals []string `json:"portals,omitempty" protobuf:"bytes,7,opt,name=portals"` + // whether support iSCSI Discovery CHAP authentication + // +optional + DiscoveryCHAPAuth bool `json:"chapAuthDiscovery,omitempty" protobuf:"varint,8,opt,name=chapAuthDiscovery"` + // whether support iSCSI Session CHAP authentication + // +optional + SessionCHAPAuth bool `json:"chapAuthSession,omitempty" protobuf:"varint,11,opt,name=chapAuthSession"` + // CHAP secret for iSCSI target and initiator authentication + // +optional + SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,10,opt,name=secretRef"` } // Represents a Fibre Channel volume. @@ -1026,6 +1133,12 @@ type VsphereVirtualDiskVolumeSource struct { // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. // +optional FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"` + // Storage Policy Based Management (SPBM) profile name. + // +optional + StoragePolicyName string `json:"storagePolicyName,omitempty" protobuf:"bytes,3,opt,name=storagePolicyName"` + // Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName. + // +optional + StoragePolicyID string `json:"storagePolicyID,omitempty" protobuf:"bytes,4,opt,name=storagePolicyID"` } // Represents a Photon Controller persistent disk resource. @@ -1039,11 +1152,16 @@ type PhotonPersistentDiskVolumeSource struct { } type AzureDataDiskCachingMode string +type AzureDataDiskKind string const ( AzureDataDiskCachingNone AzureDataDiskCachingMode = "None" AzureDataDiskCachingReadOnly AzureDataDiskCachingMode = "ReadOnly" AzureDataDiskCachingReadWrite AzureDataDiskCachingMode = "ReadWrite" + + AzureSharedBlobDisk AzureDataDiskKind = "Shared" + AzureDedicatedBlobDisk AzureDataDiskKind = "Dedicated" + AzureManagedDisk AzureDataDiskKind = "Managed" ) // AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod. @@ -1064,6 +1182,113 @@ type AzureDiskVolumeSource struct { // the ReadOnly setting in VolumeMounts. // +optional ReadOnly *bool `json:"readOnly,omitempty" protobuf:"varint,5,opt,name=readOnly"` + // Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared + Kind *AzureDataDiskKind `json:"kind,omitempty" protobuf:"bytes,6,opt,name=kind,casttype=AzureDataDiskKind"` +} + +// PortworxVolumeSource represents a Portworx volume resource. +type PortworxVolumeSource struct { + // VolumeID uniquely identifies a Portworx volume + VolumeID string `json:"volumeID" protobuf:"bytes,1,opt,name=volumeID"` + // FSType represents the filesystem type to mount + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs". Implicitly inferred to be "ext4" if unspecified. + FSType string `json:"fsType,omitempty" protobuf:"bytes,2,opt,name=fsType"` + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,3,opt,name=readOnly"` +} + +// ScaleIOVolumeSource represents a persistent ScaleIO volume +type ScaleIOVolumeSource struct { + // The host address of the ScaleIO API Gateway. + Gateway string `json:"gateway" protobuf:"bytes,1,opt,name=gateway"` + // The name of the storage system as configured in ScaleIO. + System string `json:"system" protobuf:"bytes,2,opt,name=system"` + // SecretRef references to the secret for ScaleIO user and other + // sensitive information. If this is not provided, Login operation will fail. + SecretRef *LocalObjectReference `json:"secretRef" protobuf:"bytes,3,opt,name=secretRef"` + // Flag to enable/disable SSL communication with Gateway, default false + // +optional + SSLEnabled bool `json:"sslEnabled,omitempty" protobuf:"varint,4,opt,name=sslEnabled"` + // The name of the Protection Domain for the configured storage (defaults to "default"). + // +optional + ProtectionDomain string `json:"protectionDomain,omitempty" protobuf:"bytes,5,opt,name=protectionDomain"` + // The Storage Pool associated with the protection domain (defaults to "default"). + // +optional + StoragePool string `json:"storagePool,omitempty" protobuf:"bytes,6,opt,name=storagePool"` + // Indicates whether the storage for a volume should be thick or thin (defaults to "thin"). + // +optional + StorageMode string `json:"storageMode,omitempty" protobuf:"bytes,7,opt,name=storageMode"` + // The name of a volume already created in the ScaleIO system + // that is associated with this volume source. + VolumeName string `json:"volumeName,omitempty" protobuf:"bytes,8,opt,name=volumeName"` + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType string `json:"fsType,omitempty" protobuf:"bytes,9,opt,name=fsType"` + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,10,opt,name=readOnly"` +} + +// Represents a StorageOS persistent volume resource. +type StorageOSVolumeSource struct { + // VolumeName is the human-readable name of the StorageOS volume. Volume + // names are only unique within a namespace. + VolumeName string `json:"volumeName,omitempty" protobuf:"bytes,1,opt,name=volumeName"` + // VolumeNamespace specifies the scope of the volume within StorageOS. If no + // namespace is specified then the Pod's namespace will be used. This allows the + // Kubernetes name scoping to be mirrored within StorageOS for tighter integration. + // Set VolumeName to any name to override the default behaviour. + // Set to "default" if you are not using namespaces within StorageOS. + // Namespaces that do not pre-exist within StorageOS will be created. + // +optional + VolumeNamespace string `json:"volumeNamespace,omitempty" protobuf:"bytes,2,opt,name=volumeNamespace"` + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType string `json:"fsType,omitempty" protobuf:"bytes,3,opt,name=fsType"` + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"` + // SecretRef specifies the secret to use for obtaining the StorageOS API + // credentials. If not specified, default values will be attempted. + // +optional + SecretRef *LocalObjectReference `json:"secretRef,omitempty" protobuf:"bytes,5,opt,name=secretRef"` +} + +// Represents a StorageOS persistent volume resource. +type StorageOSPersistentVolumeSource struct { + // VolumeName is the human-readable name of the StorageOS volume. Volume + // names are only unique within a namespace. + VolumeName string `json:"volumeName,omitempty" protobuf:"bytes,1,opt,name=volumeName"` + // VolumeNamespace specifies the scope of the volume within StorageOS. If no + // namespace is specified then the Pod's namespace will be used. This allows the + // Kubernetes name scoping to be mirrored within StorageOS for tighter integration. + // Set VolumeName to any name to override the default behaviour. + // Set to "default" if you are not using namespaces within StorageOS. + // Namespaces that do not pre-exist within StorageOS will be created. + // +optional + VolumeNamespace string `json:"volumeNamespace,omitempty" protobuf:"bytes,2,opt,name=volumeNamespace"` + // Filesystem type to mount. + // Must be a filesystem type supported by the host operating system. + // Ex. "ext4", "xfs", "ntfs". Implicitly inferred to be "ext4" if unspecified. + // +optional + FSType string `json:"fsType,omitempty" protobuf:"bytes,3,opt,name=fsType"` + // Defaults to false (read/write). ReadOnly here will force + // the ReadOnly setting in VolumeMounts. + // +optional + ReadOnly bool `json:"readOnly,omitempty" protobuf:"varint,4,opt,name=readOnly"` + // SecretRef specifies the secret to use for obtaining the StorageOS API + // credentials. If not specified, default values will be attempted. + // +optional + SecretRef *ObjectReference `json:"secretRef,omitempty" protobuf:"bytes,5,opt,name=secretRef"` } // Adapts a ConfigMap into a volume. @@ -1079,8 +1304,8 @@ type ConfigMapVolumeSource struct { // key and content is the value. If specified, the listed keys will be // projected into the specified paths, and unlisted keys will not be // present. If a key is specified which is not present in the ConfigMap, - // the volume setup will error. Paths must be relative and may not contain - // the '..' path or start with '..'. + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. // +optional Items []KeyToPath `json:"items,omitempty" protobuf:"bytes,2,rep,name=items"` // Optional: mode bits to use on created files by default. Must be a @@ -1090,12 +1315,67 @@ type ConfigMapVolumeSource struct { // mode, like fsGroup, and the result can be other mode bits set. // +optional DefaultMode *int32 `json:"defaultMode,omitempty" protobuf:"varint,3,opt,name=defaultMode"` + // Specify whether the ConfigMap or it's keys must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,4,opt,name=optional"` } const ( ConfigMapVolumeSourceDefaultMode int32 = 0644 ) +// Adapts a ConfigMap into a projected volume. +// +// The contents of the target ConfigMap's Data field will be presented in a +// projected volume as files using the keys in the Data field as the file names, +// unless the items element is populated with specific mappings of keys to paths. +// Note that this is identical to a configmap volume source without the default +// mode. +type ConfigMapProjection struct { + LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"` + // If unspecified, each key-value pair in the Data field of the referenced + // ConfigMap will be projected into the volume as a file whose name is the + // key and content is the value. If specified, the listed keys will be + // projected into the specified paths, and unlisted keys will not be + // present. If a key is specified which is not present in the ConfigMap, + // the volume setup will error unless it is marked optional. Paths must be + // relative and may not contain the '..' path or start with '..'. + // +optional + Items []KeyToPath `json:"items,omitempty" protobuf:"bytes,2,rep,name=items"` + // Specify whether the ConfigMap or it's keys must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,4,opt,name=optional"` +} + +// Represents a projected volume source +type ProjectedVolumeSource struct { + // list of volume projections + Sources []VolumeProjection `json:"sources" protobuf:"bytes,1,rep,name=sources"` + // Mode bits to use on created files by default. Must be a value between + // 0 and 0777. + // Directories within the path are not affected by this setting. + // This might be in conflict with other options that affect the file + // mode, like fsGroup, and the result can be other mode bits set. + // +optional + DefaultMode *int32 `json:"defaultMode,omitempty" protobuf:"varint,2,opt,name=defaultMode"` +} + +// Projection that may be projected along with other supported volume types +type VolumeProjection struct { + // all types below are the supported types for projection into the same volume + + // information about the secret data to project + Secret *SecretProjection `json:"secret,omitempty" protobuf:"bytes,1,opt,name=secret"` + // information about the downwardAPI data to project + DownwardAPI *DownwardAPIProjection `json:"downwardAPI,omitempty" protobuf:"bytes,2,opt,name=downwardAPI"` + // information about the configMap data to project + ConfigMap *ConfigMapProjection `json:"configMap,omitempty" protobuf:"bytes,3,opt,name=configMap"` +} + +const ( + ProjectedVolumeSourceDefaultMode int32 = 0644 +) + // Maps a string key to a path within a volume. type KeyToPath struct { // The key to project. @@ -1114,6 +1394,14 @@ type KeyToPath struct { Mode *int32 `json:"mode,omitempty" protobuf:"varint,3,opt,name=mode"` } +// Local represents directly-attached storage with node affinity +type LocalVolumeSource struct { + // The full path to the volume on the node + // For alpha, this path must be a directory + // Once block as a source is supported, then this path can point to a block device + Path string `json:"path" protobuf:"bytes,1,opt,name=path"` +} + // ContainerPort represents a network port in a single container. type ContainerPort struct { // If specified, this must be an IANA_SVC_NAME and unique within the pod. Each @@ -1181,7 +1469,7 @@ type EnvVar struct { // EnvVarSource represents a source for the value of an EnvVar. type EnvVarSource struct { // Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, - // spec.nodeName, spec.serviceAccountName, status.podIP. + // spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP. // +optional FieldRef *ObjectFieldSelector `json:"fieldRef,omitempty" protobuf:"bytes,1,opt,name=fieldRef"` // Selects a resource of the container: only resources limits and requests @@ -1223,6 +1511,9 @@ type ConfigMapKeySelector struct { LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"` // The key to select. Key string `json:"key" protobuf:"bytes,2,opt,name=key"` + // Specify whether the ConfigMap or it's key must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,3,opt,name=optional"` } // SecretKeySelector selects a key of a Secret. @@ -1231,6 +1522,48 @@ type SecretKeySelector struct { LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"` // The key of the secret to select from. Must be a valid secret key. Key string `json:"key" protobuf:"bytes,2,opt,name=key"` + // Specify whether the Secret or it's key must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,3,opt,name=optional"` +} + +// EnvFromSource represents the source of a set of ConfigMaps +type EnvFromSource struct { + // An optional identifer to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER. + // +optional + Prefix string `json:"prefix,omitempty" protobuf:"bytes,1,opt,name=prefix"` + // The ConfigMap to select from + // +optional + ConfigMapRef *ConfigMapEnvSource `json:"configMapRef,omitempty" protobuf:"bytes,2,opt,name=configMapRef"` + // The Secret to select from + // +optional + SecretRef *SecretEnvSource `json:"secretRef,omitempty" protobuf:"bytes,3,opt,name=secretRef"` +} + +// ConfigMapEnvSource selects a ConfigMap to populate the environment +// variables with. +// +// The contents of the target ConfigMap's Data field will represent the +// key-value pairs as environment variables. +type ConfigMapEnvSource struct { + // The ConfigMap to select from. + LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"` + // Specify whether the ConfigMap must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,2,opt,name=optional"` +} + +// SecretEnvSource selects a Secret to populate the environment +// variables with. +// +// The contents of the target Secret's Data field will represent the +// key-value pairs as environment variables. +type SecretEnvSource struct { + // The Secret to select from. + LocalObjectReference `json:",inline" protobuf:"bytes,1,opt,name=localObjectReference"` + // Specify whether the Secret must be defined + // +optional + Optional *bool `json:"optional,omitempty" protobuf:"varint,2,opt,name=optional"` } // HTTPHeader describes a custom header to be used in HTTP probes @@ -1279,6 +1612,9 @@ type TCPSocketAction struct { // Number must be in the range 1 to 65535. // Name must be an IANA_SVC_NAME. Port intstr.IntOrString `json:"port" protobuf:"bytes,1,opt,name=port"` + // Optional: Host name to connect to, defaults to the pod IP. + // +optional + Host string `json:"host,omitempty" protobuf:"bytes,2,opt,name=host"` } // ExecAction describes a "run in container" action. @@ -1298,12 +1634,12 @@ type Probe struct { // The action taken to determine the health of a container Handler `json:",inline" protobuf:"bytes,1,opt,name=handler"` // Number of seconds after the container has started before liveness probes are initiated. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional InitialDelaySeconds int32 `json:"initialDelaySeconds,omitempty" protobuf:"varint,2,opt,name=initialDelaySeconds"` // Number of seconds after which the probe times out. // Defaults to 1 second. Minimum value is 1. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional TimeoutSeconds int32 `json:"timeoutSeconds,omitempty" protobuf:"varint,3,opt,name=timeoutSeconds"` // How often (in seconds) to perform the probe. @@ -1332,6 +1668,19 @@ const ( PullIfNotPresent PullPolicy = "IfNotPresent" ) +// TerminationMessagePolicy describes how termination messages are retrieved from a container. +type TerminationMessagePolicy string + +const ( + // TerminationMessageReadFile is the default behavior and will set the container status message to + // the contents of the container's terminationMessagePath when the container exits. + TerminationMessageReadFile TerminationMessagePolicy = "File" + // TerminationMessageFallbackToLogsOnError will read the most recent contents of the container logs + // for the container status message when the container exits with an error and the + // terminationMessagePath has no contents. + TerminationMessageFallbackToLogsOnError TerminationMessagePolicy = "FallbackToLogsOnError" +) + // Capability represent POSIX capabilities type type Capability string @@ -1348,13 +1697,13 @@ type Capabilities struct { // ResourceRequirements describes the compute resource requirements. type ResourceRequirements struct { // Limits describes the maximum amount of compute resources allowed. - // More info: http://kubernetes.io/docs/user-guide/compute-resources/ + // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional Limits ResourceList `json:"limits,omitempty" protobuf:"bytes,1,rep,name=limits,casttype=ResourceList,castkey=ResourceName"` // Requests describes the minimum amount of compute resources required. // If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, // otherwise to an implementation-defined value. - // More info: http://kubernetes.io/docs/user-guide/compute-resources/ + // More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ // +optional Requests ResourceList `json:"requests,omitempty" protobuf:"bytes,2,rep,name=requests,casttype=ResourceList,castkey=ResourceName"` } @@ -1371,9 +1720,8 @@ type Container struct { // Cannot be updated. Name string `json:"name" protobuf:"bytes,1,opt,name=name"` // Docker image name. - // More info: http://kubernetes.io/docs/user-guide/images - // +optional - Image string `json:"image,omitempty" protobuf:"bytes,2,opt,name=image"` + // More info: https://kubernetes.io/docs/concepts/containers/images + Image string `json:"image" protobuf:"bytes,2,opt,name=image"` // Entrypoint array. Not executed within a shell. // The docker image's ENTRYPOINT is used if this is not provided. // Variable references $(VAR_NAME) are expanded using the container's environment. If a variable @@ -1381,7 +1729,7 @@ type Container struct { // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, // regardless of whether the variable exists or not. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers#containers-and-commands + // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell // +optional Command []string `json:"command,omitempty" protobuf:"bytes,3,rep,name=command"` // Arguments to the entrypoint. @@ -1391,7 +1739,7 @@ type Container struct { // can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, // regardless of whether the variable exists or not. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers#containers-and-commands + // More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell // +optional Args []string `json:"args,omitempty" protobuf:"bytes,4,rep,name=args"` // Container's working directory. @@ -1408,30 +1756,44 @@ type Container struct { // accessible from the network. // Cannot be updated. // +optional + // +patchMergeKey=containerPort + // +patchStrategy=merge Ports []ContainerPort `json:"ports,omitempty" patchStrategy:"merge" patchMergeKey:"containerPort" protobuf:"bytes,6,rep,name=ports"` + // List of sources to populate environment variables in the container. + // The keys defined within a source must be a C_IDENTIFIER. All invalid keys + // will be reported as an event when the container is starting. When a key exists in multiple + // sources, the value associated with the last source will take precedence. + // Values defined by an Env with a duplicate key will take precedence. + // Cannot be updated. + // +optional + EnvFrom []EnvFromSource `json:"envFrom,omitempty" protobuf:"bytes,19,rep,name=envFrom"` // List of environment variables to set in the container. // Cannot be updated. // +optional + // +patchMergeKey=name + // +patchStrategy=merge Env []EnvVar `json:"env,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,7,rep,name=env"` // Compute Resources required by this container. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#resources + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources // +optional Resources ResourceRequirements `json:"resources,omitempty" protobuf:"bytes,8,opt,name=resources"` // Pod volumes to mount into the container's filesystem. // Cannot be updated. // +optional + // +patchMergeKey=mountPath + // +patchStrategy=merge VolumeMounts []VolumeMount `json:"volumeMounts,omitempty" patchStrategy:"merge" patchMergeKey:"mountPath" protobuf:"bytes,9,rep,name=volumeMounts"` // Periodic probe of container liveness. // Container will be restarted if the probe fails. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional LivenessProbe *Probe `json:"livenessProbe,omitempty" protobuf:"bytes,10,opt,name=livenessProbe"` // Periodic probe of container service readiness. // Container will be removed from service endpoints if the probe fails. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes // +optional ReadinessProbe *Probe `json:"readinessProbe,omitempty" protobuf:"bytes,11,opt,name=readinessProbe"` // Actions that the management system should take in response to container lifecycle events. @@ -1441,19 +1803,31 @@ type Container struct { // Optional: Path at which the file to which the container's termination message // will be written is mounted into the container's filesystem. // Message written is intended to be brief final status, such as an assertion failure message. + // Will be truncated by the node if greater than 4096 bytes. The total message length across + // all containers will be limited to 12kb. // Defaults to /dev/termination-log. // Cannot be updated. // +optional TerminationMessagePath string `json:"terminationMessagePath,omitempty" protobuf:"bytes,13,opt,name=terminationMessagePath"` + // Indicate how the termination message should be populated. File will use the contents of + // terminationMessagePath to populate the container status message on both success and failure. + // FallbackToLogsOnError will use the last chunk of container log output if the termination + // message file is empty and the container exited with an error. + // The log output is limited to 2048 bytes or 80 lines, whichever is smaller. + // Defaults to File. + // Cannot be updated. + // +optional + TerminationMessagePolicy TerminationMessagePolicy `json:"terminationMessagePolicy,omitempty" protobuf:"bytes,20,opt,name=terminationMessagePolicy,casttype=TerminationMessagePolicy"` // Image pull policy. // One of Always, Never, IfNotPresent. // Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/images#updating-images + // More info: https://kubernetes.io/docs/concepts/containers/images#updating-images // +optional ImagePullPolicy PullPolicy `json:"imagePullPolicy,omitempty" protobuf:"bytes,14,opt,name=imagePullPolicy,casttype=PullPolicy"` // Security options the pod should run with. - // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md + // More info: https://kubernetes.io/docs/concepts/policy/security-context/ + // More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md // +optional SecurityContext *SecurityContext `json:"securityContext,omitempty" protobuf:"bytes,15,opt,name=securityContext"` @@ -1504,7 +1878,7 @@ type Lifecycle struct { // PostStart is called immediately after a container is created. If the handler fails, // the container is terminated and restarted according to its restart policy. // Other management of the container blocks until the hook completes. - // More info: http://kubernetes.io/docs/user-guide/container-environment#hook-details + // More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks // +optional PostStart *Handler `json:"postStart,omitempty" protobuf:"bytes,1,opt,name=postStart"` // PreStop is called immediately before a container is terminated. @@ -1512,7 +1886,7 @@ type Lifecycle struct { // The reason for termination is passed to the handler. // Regardless of the outcome of the handler, the container is eventually terminated. // Other management of the container blocks until the hook completes. - // More info: http://kubernetes.io/docs/user-guide/container-environment#hook-details + // More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks // +optional PreStop *Handler `json:"preStop,omitempty" protobuf:"bytes,2,opt,name=preStop"` } @@ -1543,7 +1917,7 @@ type ContainerStateWaiting struct { type ContainerStateRunning struct { // Time at which the container was last (re-)started // +optional - StartedAt unversioned.Time `json:"startedAt,omitempty" protobuf:"bytes,1,opt,name=startedAt"` + StartedAt metav1.Time `json:"startedAt,omitempty" protobuf:"bytes,1,opt,name=startedAt"` } // ContainerStateTerminated is a terminated state of a container. @@ -1561,10 +1935,10 @@ type ContainerStateTerminated struct { Message string `json:"message,omitempty" protobuf:"bytes,4,opt,name=message"` // Time at which previous execution of the container started // +optional - StartedAt unversioned.Time `json:"startedAt,omitempty" protobuf:"bytes,5,opt,name=startedAt"` + StartedAt metav1.Time `json:"startedAt,omitempty" protobuf:"bytes,5,opt,name=startedAt"` // Time at which the container last terminated // +optional - FinishedAt unversioned.Time `json:"finishedAt,omitempty" protobuf:"bytes,6,opt,name=finishedAt"` + FinishedAt metav1.Time `json:"finishedAt,omitempty" protobuf:"bytes,6,opt,name=finishedAt"` // Container's ID in the format 'docker://' // +optional ContainerID string `json:"containerID,omitempty" protobuf:"bytes,7,opt,name=containerID"` @@ -1604,13 +1978,12 @@ type ContainerStatus struct { // garbage collection. This value will get capped at 5 by GC. RestartCount int32 `json:"restartCount" protobuf:"varint,5,opt,name=restartCount"` // The image the container is running. - // More info: http://kubernetes.io/docs/user-guide/images + // More info: https://kubernetes.io/docs/concepts/containers/images // TODO(dchen1107): Which image the container is running with? Image string `json:"image" protobuf:"bytes,6,opt,name=image"` // ImageID of the container's image. ImageID string `json:"imageID" protobuf:"bytes,7,opt,name=imageID"` // Container's ID in the format 'docker://'. - // More info: http://kubernetes.io/docs/user-guide/container-environment#container-information // +optional ContainerID string `json:"containerID,omitempty" protobuf:"bytes,8,opt,name=containerID"` } @@ -1659,18 +2032,18 @@ const ( type PodCondition struct { // Type is the type of the condition. // Currently only Ready. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions Type PodConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=PodConditionType"` // Status is the status of the condition. // Can be True, False, Unknown. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions Status ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=ConditionStatus"` // Last time we probed the condition. // +optional - LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"` + LastProbeTime metav1.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"` // Last time the condition transitioned from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` // Unique, one-word, CamelCase reason for the condition's last transition. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"` @@ -1695,9 +2068,14 @@ const ( type DNSPolicy string const ( + // DNSClusterFirstWithHostNet indicates that the pod should use cluster DNS + // first, if it is available, then fall back on the default + // (as determined by kubelet) DNS settings. + DNSClusterFirstWithHostNet DNSPolicy = "ClusterFirstWithHostNet" + // DNSClusterFirst indicates that the pod should use cluster DNS - // first, if it is available, then fall back on the default (as - // determined by kubelet) DNS settings. + // first unless hostNetwork is true, if it is available, then + // fall back on the default (as determined by kubelet) DNS settings. DNSClusterFirst DNSPolicy = "ClusterFirst" // DNSDefault indicates that the pod should use the default (as @@ -1725,6 +2103,8 @@ type NodeSelectorTerm struct { // that relates the key and values. type NodeSelectorRequirement struct { // The label key that the selector applies to. + // +patchMergeKey=key + // +patchStrategy=merge Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"` // Represents a key's relationship to a set of values. // Valid operators are In, NotIn, Exists, DoesNotExist. Gt, and Lt. @@ -1850,12 +2230,10 @@ type WeightedPodAffinityTerm struct { type PodAffinityTerm struct { // A label query over a set of resources, in this case pods. // +optional - LabelSelector *unversioned.LabelSelector `json:"labelSelector,omitempty" protobuf:"bytes,1,opt,name=labelSelector"` + LabelSelector *metav1.LabelSelector `json:"labelSelector,omitempty" protobuf:"bytes,1,opt,name=labelSelector"` // namespaces specifies which namespaces the labelSelector applies to (matches against); - // nil list means "this pod's namespace," empty list means "all namespaces" - // The json tag here is not "omitempty" since we need to distinguish nil and empty. - // See https://golang.org/pkg/encoding/json/#Marshal for more details. - Namespaces []string `json:"namespaces" protobuf:"bytes,2,rep,name=namespaces"` + // null or empty list means "this pod's namespace" + Namespaces []string `json:"namespaces,omitempty" protobuf:"bytes,2,rep,name=namespaces"` // This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching // the labelSelector in the specified namespaces, where co-located is defined as running on a node // whose value of the label with key topologyKey matches that of any node on which any of the @@ -1911,14 +2289,20 @@ type PreferredSchedulingTerm struct { // any pod that that does not tolerate the Taint. type Taint struct { // Required. The taint key to be applied to a node. + // +patchMergeKey=key + // +patchStrategy=merge Key string `json:"key" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"` // Required. The taint value corresponding to the taint key. // +optional Value string `json:"value,omitempty" protobuf:"bytes,2,opt,name=value"` // Required. The effect of the taint on pods // that do not tolerate the taint. - // Valid effects are NoSchedule and PreferNoSchedule. + // Valid effects are NoSchedule, PreferNoSchedule and NoExecute. Effect TaintEffect `json:"effect" protobuf:"bytes,3,opt,name=effect,casttype=TaintEffect"` + // TimeAdded represents the time at which the taint was added. + // It is only written for NoExecute taints. + // +optional + TimeAdded metav1.Time `json:"timeAdded,omitempty" protobuf:"bytes,4,opt,name=timeAdded"` } type TaintEffect string @@ -1934,26 +2318,25 @@ const ( // onto the node entirely. Enforced by the scheduler. TaintEffectPreferNoSchedule TaintEffect = "PreferNoSchedule" // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. - // Do not allow new pods to schedule onto the node unless they tolerate the taint, - // do not allow pods to start on Kubelet unless they tolerate the taint, - // but allow all already-running pods to continue running. - // Enforced by the scheduler and Kubelet. + // Like TaintEffectNoSchedule, but additionally do not allow pods submitted to + // Kubelet without going through the scheduler to start. + // Enforced by Kubelet and the scheduler. // TaintEffectNoScheduleNoAdmit TaintEffect = "NoScheduleNoAdmit" - // NOT YET IMPLEMENTED. TODO: Uncomment field once it is implemented. - // Do not allow new pods to schedule onto the node unless they tolerate the taint, - // do not allow pods to start on Kubelet unless they tolerate the taint, - // and evict any already-running pods that do not tolerate the taint. - // Enforced by the scheduler and Kubelet. - // TaintEffectNoScheduleNoAdmitNoExecute = "NoScheduleNoAdmitNoExecute" + // Evict any already-running pods that do not tolerate the taint. + // Currently enforced by NodeController. + TaintEffectNoExecute TaintEffect = "NoExecute" ) // The pod this Toleration is attached to tolerates any taint that matches // the triple using the matching operator . type Toleration struct { - // Required. Key is the taint key that the toleration applies to. + // Key is the taint key that the toleration applies to. Empty means match all taint keys. + // If the key is empty, operator must be Exists; this combination means to match all values and all keys. // +optional + // +patchMergeKey=key + // +patchStrategy=merge Key string `json:"key,omitempty" patchStrategy:"merge" patchMergeKey:"key" protobuf:"bytes,1,opt,name=key"` - // operator represents a key's relationship to the value. + // Operator represents a key's relationship to the value. // Valid operators are Exists and Equal. Defaults to Equal. // Exists is equivalent to wildcard for value, so that a pod can // tolerate all taints of a particular category. @@ -1964,11 +2347,15 @@ type Toleration struct { // +optional Value string `json:"value,omitempty" protobuf:"bytes,3,opt,name=value"` // Effect indicates the taint effect to match. Empty means match all taint effects. - // When specified, allowed values are NoSchedule and PreferNoSchedule. + // When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute. // +optional Effect TaintEffect `json:"effect,omitempty" protobuf:"bytes,4,opt,name=effect,casttype=TaintEffect"` - // TODO: For forgiveness (#1574), we'd eventually add at least a grace period - // here, and possibly an occurrence threshold and period. + // TolerationSeconds represents the period of time the toleration (which must be + // of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, + // it is not set, which means tolerate the taint forever (do not evict). Zero and + // negative values will be treated as 0 (evict immediately) by the system. + // +optional + TolerationSeconds *int64 `json:"tolerationSeconds,omitempty" protobuf:"varint,5,opt,name=tolerationSeconds"` } // A toleration operator is the set of operators that can be used in a toleration. @@ -2003,8 +2390,10 @@ const ( // PodSpec is a description of a pod. type PodSpec struct { // List of volumes that can be mounted by containers belonging to the pod. - // More info: http://kubernetes.io/docs/user-guide/volumes + // More info: https://kubernetes.io/docs/concepts/storage/volumes // +optional + // +patchMergeKey=name + // +patchStrategy=merge Volumes []Volume `json:"volumes,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,1,rep,name=volumes"` // List of initialization containers belonging to the pod. // Init containers are executed in order prior to containers being started. If any @@ -2017,20 +2406,22 @@ type PodSpec struct { // of that value or the sum of the normal containers. Limits are applied to init containers // in a similar fashion. // Init containers cannot currently be added or removed. - // Init containers are in alpha state and may change without notice. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers - InitContainers []Container `json:"-" patchStrategy:"merge" patchMergeKey:"name"` + // More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/ + // +patchMergeKey=name + // +patchStrategy=merge + InitContainers []Container `json:"initContainers,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,20,rep,name=initContainers"` // List of containers belonging to the pod. // Containers cannot currently be added or removed. // There must be at least one container in a Pod. // Cannot be updated. - // More info: http://kubernetes.io/docs/user-guide/containers + // +patchMergeKey=name + // +patchStrategy=merge Containers []Container `json:"containers" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=containers"` // Restart policy for all containers within the pod. // One of Always, OnFailure, Never. // Default to Always. - // More info: http://kubernetes.io/docs/user-guide/pod-states#restartpolicy + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy // +optional RestartPolicy RestartPolicy `json:"restartPolicy,omitempty" protobuf:"bytes,3,opt,name=restartPolicy,casttype=RestartPolicy"` // Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. @@ -2048,18 +2439,19 @@ type PodSpec struct { // +optional ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,5,opt,name=activeDeadlineSeconds"` // Set DNS policy for containers within the pod. - // One of 'ClusterFirst' or 'Default'. + // One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. // Defaults to "ClusterFirst". + // To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'. // +optional DNSPolicy DNSPolicy `json:"dnsPolicy,omitempty" protobuf:"bytes,6,opt,name=dnsPolicy,casttype=DNSPolicy"` // NodeSelector is a selector which must be true for the pod to fit on a node. // Selector which must match a node's labels for the pod to be scheduled on that node. - // More info: http://kubernetes.io/docs/user-guide/node-selection/README + // More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/ // +optional NodeSelector map[string]string `json:"nodeSelector,omitempty" protobuf:"bytes,7,rep,name=nodeSelector"` // ServiceAccountName is the name of the ServiceAccount to use to run this pod. - // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md + // More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ // +optional ServiceAccountName string `json:"serviceAccountName,omitempty" protobuf:"bytes,8,opt,name=serviceAccountName"` // DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. @@ -2067,6 +2459,9 @@ type PodSpec struct { // +k8s:conversion-gen=false // +optional DeprecatedServiceAccount string `json:"serviceAccount,omitempty" protobuf:"bytes,9,opt,name=serviceAccount"` + // AutomountServiceAccountToken indicates whether a service account token should be automatically mounted. + // +optional + AutomountServiceAccountToken *bool `json:"automountServiceAccountToken,omitempty" protobuf:"varint,21,opt,name=automountServiceAccountToken"` // NodeName is a request to schedule this pod onto a specific node. If it is non-empty, // the scheduler simply schedules this pod onto that node, assuming that it fits resource @@ -2096,8 +2491,10 @@ type PodSpec struct { // ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. // If specified, these secrets will be passed to individual puller implementations for them to use. For example, // in the case of docker, only DockerConfig type secrets are honored. - // More info: http://kubernetes.io/docs/user-guide/images#specifying-imagepullsecrets-on-a-pod + // More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod // +optional + // +patchMergeKey=name + // +patchStrategy=merge ImagePullSecrets []LocalObjectReference `json:"imagePullSecrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,15,rep,name=imagePullSecrets"` // Specifies the hostname of the Pod // If not specified, the pod's hostname will be set to a system-defined value. @@ -2107,6 +2504,31 @@ type PodSpec struct { // If not specified, the pod will not have a domainname at all. // +optional Subdomain string `json:"subdomain,omitempty" protobuf:"bytes,17,opt,name=subdomain"` + // If specified, the pod's scheduling constraints + // +optional + Affinity *Affinity `json:"affinity,omitempty" protobuf:"bytes,18,opt,name=affinity"` + // If specified, the pod will be dispatched by specified scheduler. + // If not specified, the pod will be dispatched by default scheduler. + // +optional + SchedulerName string `json:"schedulerName,omitempty" protobuf:"bytes,19,opt,name=schedulerName"` + // If specified, the pod's tolerations. + // +optional + Tolerations []Toleration `json:"tolerations,omitempty" protobuf:"bytes,22,opt,name=tolerations"` + // HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts + // file if specified. This is only valid for non-hostNetwork pods. + // +optional + // +patchMergeKey=ip + // +patchStrategy=merge + HostAliases []HostAlias `json:"hostAliases,omitempty" patchStrategy:"merge" patchMergeKey:"ip" protobuf:"bytes,23,rep,name=hostAliases"` +} + +// HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the +// pod's hosts file. +type HostAlias struct { + // IP address of the host file entry. + IP string `json:"ip,omitempty" protobuf:"bytes,1,opt,name=ip"` + // Hostnames for the above IP address. + Hostnames []string `json:"hostnames,omitempty" protobuf:"bytes,2,rep,name=hostnames"` } // PodSecurityContext holds pod-level security attributes and common container settings. @@ -2153,16 +2575,30 @@ type PodSecurityContext struct { FSGroup *int64 `json:"fsGroup,omitempty" protobuf:"varint,5,opt,name=fsGroup"` } +// PodQOSClass defines the supported qos classes of Pods. +type PodQOSClass string + +const ( + // PodQOSGuaranteed is the Guaranteed qos class. + PodQOSGuaranteed PodQOSClass = "Guaranteed" + // PodQOSBurstable is the Burstable qos class. + PodQOSBurstable PodQOSClass = "Burstable" + // PodQOSBestEffort is the BestEffort qos class. + PodQOSBestEffort PodQOSClass = "BestEffort" +) + // PodStatus represents information about the status of a pod. Status may trail the actual // state of a system. type PodStatus struct { // Current condition of the pod. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-phase + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase // +optional Phase PodPhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=PodPhase"` // Current service state of pod. - // More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions // +optional + // +patchMergeKey=type + // +patchStrategy=merge Conditions []PodCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,2,rep,name=conditions"` // A human readable message indicating details about why the pod is in this condition. // +optional @@ -2183,33 +2619,38 @@ type PodStatus struct { // RFC 3339 date and time at which the object was acknowledged by the Kubelet. // This is before the Kubelet pulled the container image(s) for the pod. // +optional - StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,7,opt,name=startTime"` + StartTime *metav1.Time `json:"startTime,omitempty" protobuf:"bytes,7,opt,name=startTime"` // The list has one entry per init container in the manifest. The most recent successful // init container will have ready = true, the most recently started container will have // startTime set. - // Init containers are in alpha state and may change without notice. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-statuses - InitContainerStatuses []ContainerStatus `json:"-"` + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status + InitContainerStatuses []ContainerStatus `json:"initContainerStatuses,omitempty" protobuf:"bytes,10,rep,name=initContainerStatuses"` + // The list has one entry per container in the manifest. Each entry is currently the output // of `docker inspect`. - // More info: http://kubernetes.io/docs/user-guide/pod-states#container-statuses + // More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status // +optional ContainerStatuses []ContainerStatus `json:"containerStatuses,omitempty" protobuf:"bytes,8,rep,name=containerStatuses"` + // The Quality of Service (QOS) classification assigned to the pod based on resource requirements + // See PodQOSClass type for available QOS classes + // More info: https://github.com/kubernetes/kubernetes/blob/master/docs/design/resource-qos.md + // +optional + QOSClass PodQOSClass `json:"qosClass,omitempty" protobuf:"bytes,9,rep,name=qosClass"` } // PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded type PodStatusResult struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Most recently observed status of the pod. // This data may not be up to date. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status PodStatus `json:"status,omitempty" protobuf:"bytes,2,opt,name=status"` } @@ -2219,14 +2660,14 @@ type PodStatusResult struct { // Pod is a collection of containers that can run on a host. This resource is created // by clients and scheduled onto hosts. type Pod struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Specification of the desired behavior of the pod. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec PodSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` @@ -2234,33 +2675,33 @@ type Pod struct { // This data may not be up to date. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status PodStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // PodList is a list of Pods. type PodList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of pods. - // More info: http://kubernetes.io/docs/user-guide/pods + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md Items []Pod `json:"items" protobuf:"bytes,2,rep,name=items"` } // PodTemplateSpec describes the data a pod should have when created from a template type PodTemplateSpec struct { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Specification of the desired behavior of the pod. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec PodSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` } @@ -2269,25 +2710,25 @@ type PodTemplateSpec struct { // PodTemplate describes a template for creating copies of a predefined pod. type PodTemplate struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Template defines the pods that will be created from this pod template. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Template PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,2,opt,name=template"` } // PodTemplateList is a list of PodTemplates. type PodTemplateList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of pod templates Items []PodTemplate `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -2298,7 +2739,7 @@ type ReplicationControllerSpec struct { // Replicas is the number of desired replicas. // This is a pointer to distinguish between explicit zero and unspecified. // Defaults to 1. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller // +optional Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"` @@ -2312,7 +2753,7 @@ type ReplicationControllerSpec struct { // If Selector is empty, it is defaulted to the labels present on the Pod template. // Label keys and values that must match in order to be controlled by this replication // controller, if empty defaulted to labels on Pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional Selector map[string]string `json:"selector,omitempty" protobuf:"bytes,2,rep,name=selector"` @@ -2324,7 +2765,7 @@ type ReplicationControllerSpec struct { // Template is the object that describes the pod that will be created if // insufficient replicas are detected. This takes precedence over a TemplateRef. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template // +optional Template *PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,3,opt,name=template"` } @@ -2333,7 +2774,7 @@ type ReplicationControllerSpec struct { // controller. type ReplicationControllerStatus struct { // Replicas is the most recently oberved number of replicas. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"` // The number of pods that have labels matching the labels of the pod template of the replication controller. @@ -2354,6 +2795,8 @@ type ReplicationControllerStatus struct { // Represents the latest available observations of a replication controller's current state. // +optional + // +patchMergeKey=type + // +patchStrategy=merge Conditions []ReplicationControllerCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,6,rep,name=conditions"` } @@ -2375,7 +2818,7 @@ type ReplicationControllerCondition struct { Status ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=ConditionStatus"` // The last time the condition transitioned from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,3,opt,name=lastTransitionTime"` + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,3,opt,name=lastTransitionTime"` // The reason for the condition's last transition. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` @@ -2388,16 +2831,16 @@ type ReplicationControllerCondition struct { // ReplicationController represents the configuration of a replication controller. type ReplicationController struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // If the Labels of a ReplicationController are empty, they are defaulted to // be the same as the Pod(s) that the replication controller manages. - // Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the specification of the desired behavior of the replication controller. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec ReplicationControllerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` @@ -2405,21 +2848,21 @@ type ReplicationController struct { // This data may be out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status ReplicationControllerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // ReplicationControllerList is a collection of replication controllers. type ReplicationControllerList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of replication controllers. - // More info: http://kubernetes.io/docs/user-guide/replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller Items []ReplicationController `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -2457,6 +2900,16 @@ const ( ServiceTypeExternalName ServiceType = "ExternalName" ) +// Service External Traffic Policy Type string +type ServiceExternalTrafficPolicyType string + +const ( + // ServiceExternalTrafficPolicyTypeLocal specifies node-local endpoints behavior. + ServiceExternalTrafficPolicyTypeLocal ServiceExternalTrafficPolicyType = "Local" + // ServiceExternalTrafficPolicyTypeCluster specifies node-global (legacy) behavior. + ServiceExternalTrafficPolicyTypeCluster ServiceExternalTrafficPolicyType = "Cluster" +) + // ServiceStatus represents the current status of a service. type ServiceStatus struct { // LoadBalancer contains the current status of the load-balancer, @@ -2490,15 +2943,17 @@ type LoadBalancerIngress struct { // ServiceSpec describes the attributes that a user creates on a service. type ServiceSpec struct { // The list of ports that are exposed by this service. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies - Ports []ServicePort `json:"ports" patchStrategy:"merge" patchMergeKey:"port" protobuf:"bytes,1,rep,name=ports"` + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies + // +patchMergeKey=port + // +patchStrategy=merge + Ports []ServicePort `json:"ports,omitempty" patchStrategy:"merge" patchMergeKey:"port" protobuf:"bytes,1,rep,name=ports"` // Route service traffic to pods with label keys and values matching this // selector. If empty or not present, the service is assumed to have an // external process managing its endpoints, which Kubernetes will not // modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. // Ignored if type is ExternalName. - // More info: http://kubernetes.io/docs/user-guide/services#overview + // More info: https://kubernetes.io/docs/concepts/services-networking/service/ // +optional Selector map[string]string `json:"selector,omitempty" protobuf:"bytes,2,rep,name=selector"` @@ -2510,7 +2965,7 @@ type ServiceSpec struct { // can be specified for headless services when proxying is not required. // Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if // type is ExternalName. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies // +optional ClusterIP string `json:"clusterIP,omitempty" protobuf:"bytes,3,opt,name=clusterIP"` @@ -2527,7 +2982,7 @@ type ServiceSpec struct { // "LoadBalancer" builds on NodePort and creates an // external load-balancer (if supported in the current cloud) which routes // to the clusterIP. - // More info: http://kubernetes.io/docs/user-guide/services#overview + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services---service-types // +optional Type ServiceType `json:"type,omitempty" protobuf:"bytes,4,opt,name=type,casttype=ServiceType"` @@ -2535,26 +2990,15 @@ type ServiceSpec struct { // will also accept traffic for this service. These IPs are not managed by // Kubernetes. The user is responsible for ensuring that traffic arrives // at a node with this IP. A common example is external load-balancers - // that are not part of the Kubernetes system. A previous form of this - // functionality exists as the deprecatedPublicIPs field. When using this - // field, callers should also clear the deprecatedPublicIPs field. + // that are not part of the Kubernetes system. // +optional ExternalIPs []string `json:"externalIPs,omitempty" protobuf:"bytes,5,rep,name=externalIPs"` - // deprecatedPublicIPs is deprecated and replaced by the externalIPs field - // with almost the exact same semantics. This field is retained in the v1 - // API for compatibility until at least 8/20/2016. It will be removed from - // any new API revisions. If both deprecatedPublicIPs *and* externalIPs are - // set, deprecatedPublicIPs is used. - // +k8s:conversion-gen=false - // +optional - DeprecatedPublicIPs []string `json:"deprecatedPublicIPs,omitempty" protobuf:"bytes,6,rep,name=deprecatedPublicIPs"` - // Supports "ClientIP" and "None". Used to maintain session affinity. // Enable client IP based session affinity. // Must be ClientIP or None. // Defaults to None. - // More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies // +optional SessionAffinity ServiceAffinity `json:"sessionAffinity,omitempty" protobuf:"bytes,7,opt,name=sessionAffinity,casttype=ServiceAffinity"` @@ -2569,7 +3013,7 @@ type ServiceSpec struct { // If specified and supported by the platform, this will restrict traffic through the cloud-provider // load-balancer will be restricted to the specified client IPs. This field will be ignored if the // cloud-provider does not support the feature." - // More info: http://kubernetes.io/docs/user-guide/services-firewalls + // More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/ // +optional LoadBalancerSourceRanges []string `json:"loadBalancerSourceRanges,omitempty" protobuf:"bytes,9,opt,name=loadBalancerSourceRanges"` @@ -2578,6 +3022,23 @@ type ServiceSpec struct { // Must be a valid DNS name and requires Type to be ExternalName. // +optional ExternalName string `json:"externalName,omitempty" protobuf:"bytes,10,opt,name=externalName"` + + // externalTrafficPolicy denotes if this Service desires to route external + // traffic to node-local or cluster-wide endpoints. "Local" preserves the + // client source IP and avoids a second hop for LoadBalancer and Nodeport + // type services, but risks potentially imbalanced traffic spreading. + // "Cluster" obscures the client source IP and may cause a second hop to + // another node, but should have good overall load-spreading. + // +optional + ExternalTrafficPolicy ServiceExternalTrafficPolicyType `json:"externalTrafficPolicy,omitempty" protobuf:"bytes,11,opt,name=externalTrafficPolicy"` + + // healthCheckNodePort specifies the healthcheck nodePort for the service. + // If not specified, HealthCheckNodePort is created by the service api + // backend with the allocated nodePort. Will use user-specified nodePort value + // if specified by the client. Only effects when Type is set to LoadBalancer + // and ExternalTrafficPolicy is set to Local. + // +optional + HealthCheckNodePort int32 `json:"healthCheckNodePort,omitempty" protobuf:"bytes,12,opt,name=healthCheckNodePort"` } // ServicePort contains information on service's port. @@ -2604,7 +3065,7 @@ type ServicePort struct { // of the 'port' field is used (an identity map). // This field is ignored for services with clusterIP=None, and should be // omitted or set equal to the 'port' field. - // More info: http://kubernetes.io/docs/user-guide/services#defining-a-service + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service // +optional TargetPort intstr.IntOrString `json:"targetPort,omitempty" protobuf:"bytes,4,opt,name=targetPort"` @@ -2612,7 +3073,7 @@ type ServicePort struct { // Usually assigned by the system. If specified, it will be allocated to the service // if unused or else creation of the service will fail. // Default is to auto-allocate a port if the ServiceType of this Service requires one. - // More info: http://kubernetes.io/docs/user-guide/services#type--nodeport + // More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport // +optional NodePort int32 `json:"nodePort,omitempty" protobuf:"varint,5,opt,name=nodePort"` } @@ -2623,21 +3084,21 @@ type ServicePort struct { // (for example 3306) that the proxy listens on, and the selector that determines which pods // will answer requests sent through the proxy. type Service struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the behavior of a service. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec ServiceSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Most recently observed status of the service. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status ServiceStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } @@ -2650,11 +3111,11 @@ const ( // ServiceList holds a list of services. type ServiceList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of services Items []Service `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -2667,35 +3128,42 @@ type ServiceList struct { // * a principal that can be authenticated and authorized // * a set of secrets type ServiceAccount struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount. - // More info: http://kubernetes.io/docs/user-guide/secrets + // More info: https://kubernetes.io/docs/concepts/configuration/secret // +optional + // +patchMergeKey=name + // +patchStrategy=merge Secrets []ObjectReference `json:"secrets,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=secrets"` // ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images // in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets // can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. - // More info: http://kubernetes.io/docs/user-guide/secrets#manually-specifying-an-imagepullsecret + // More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod // +optional ImagePullSecrets []LocalObjectReference `json:"imagePullSecrets,omitempty" protobuf:"bytes,3,rep,name=imagePullSecrets"` + + // AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. + // Can be overridden at the pod level. + // +optional + AutomountServiceAccountToken *bool `json:"automountServiceAccountToken,omitempty" protobuf:"varint,4,opt,name=automountServiceAccountToken"` } // ServiceAccountList is a list of ServiceAccount objects type ServiceAccountList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of ServiceAccounts. - // More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md#service-accounts + // More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/ Items []ServiceAccount `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -2714,11 +3182,11 @@ type ServiceAccountList struct { // }, // ] type Endpoints struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // The set of all endpoints is the union of all subsets. Addresses are placed into // subsets according to the IPs they share. A single address with multiple ports, @@ -2795,11 +3263,11 @@ type EndpointPort struct { // EndpointsList is a list of endpoints. type EndpointsList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of endpoints. Items []Endpoints `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -2818,9 +3286,12 @@ type NodeSpec struct { // +optional ProviderID string `json:"providerID,omitempty" protobuf:"bytes,3,opt,name=providerID"` // Unschedulable controls node schedulability of new pods. By default, node is schedulable. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#manual-node-administration"` + // More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration // +optional Unschedulable bool `json:"unschedulable,omitempty" protobuf:"varint,4,opt,name=unschedulable"` + // If specified, the node's taints. + // +optional + Taints []Taint `json:"taints,omitempty" protobuf:"bytes,5,opt,name=taints"` } // DaemonEndpoint contains information about a single Daemon endpoint. @@ -2845,11 +3316,11 @@ type NodeDaemonEndpoints struct { // NodeSystemInfo is a set of ids/uuids to uniquely identify the node. type NodeSystemInfo struct { // MachineID reported by the node. For unique machine identification - // in the cluster this field is prefered. Learn more from man(5) + // in the cluster this field is preferred. Learn more from man(5) // machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html MachineID string `json:"machineID" protobuf:"bytes,1,opt,name=machineID"` // SystemUUID reported by the node. For unique machine identification - // MachineID is prefered. This field is specific to Red Hat hosts + // MachineID is preferred. This field is specific to Red Hat hosts // https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html SystemUUID string `json:"systemUUID" protobuf:"bytes,2,opt,name=systemUUID"` // Boot ID reported by the node. @@ -2873,7 +3344,7 @@ type NodeSystemInfo struct { // NodeStatus is information about the current status of a node. type NodeStatus struct { // Capacity represents the total resources of a node. - // More info: http://kubernetes.io/docs/user-guide/persistent-volumes#capacity for more details. + // More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity // +optional Capacity ResourceList `json:"capacity,omitempty" protobuf:"bytes,1,rep,name=capacity,casttype=ResourceList,castkey=ResourceName"` // Allocatable represents the resources of a node that are available for scheduling. @@ -2881,24 +3352,28 @@ type NodeStatus struct { // +optional Allocatable ResourceList `json:"allocatable,omitempty" protobuf:"bytes,2,rep,name=allocatable,casttype=ResourceList,castkey=ResourceName"` // NodePhase is the recently observed lifecycle phase of the node. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-phase + // More info: https://kubernetes.io/docs/concepts/nodes/node/#phase // The field is never populated, and now is deprecated. // +optional Phase NodePhase `json:"phase,omitempty" protobuf:"bytes,3,opt,name=phase,casttype=NodePhase"` // Conditions is an array of current observed node conditions. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-condition + // More info: https://kubernetes.io/docs/concepts/nodes/node/#condition // +optional + // +patchMergeKey=type + // +patchStrategy=merge Conditions []NodeCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,4,rep,name=conditions"` // List of addresses reachable to the node. // Queried from cloud provider, if available. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-addresses + // More info: https://kubernetes.io/docs/concepts/nodes/node/#addresses // +optional + // +patchMergeKey=type + // +patchStrategy=merge Addresses []NodeAddress `json:"addresses,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,5,rep,name=addresses"` // Endpoints of daemons running on the Node. // +optional DaemonEndpoints NodeDaemonEndpoints `json:"daemonEndpoints,omitempty" protobuf:"bytes,6,opt,name=daemonEndpoints"` // Set of ids/uuids to uniquely identify the node. - // More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-info + // More info: https://kubernetes.io/docs/concepts/nodes/node/#info // +optional NodeInfo NodeSystemInfo `json:"nodeInfo,omitempty" protobuf:"bytes,7,opt,name=nodeInfo"` // List of container images on this node @@ -2939,7 +3414,7 @@ type PreferAvoidPodsEntry struct { PodSignature PodSignature `json:"podSignature" protobuf:"bytes,1,opt,name=podSignature"` // Time at which this entry was added to the list. // +optional - EvictionTime unversioned.Time `json:"evictionTime,omitempty" protobuf:"bytes,2,opt,name=evictionTime"` + EvictionTime metav1.Time `json:"evictionTime,omitempty" protobuf:"bytes,2,opt,name=evictionTime"` // (brief) reason why this entry was added to the list. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,3,opt,name=reason"` @@ -2953,7 +3428,7 @@ type PreferAvoidPodsEntry struct { type PodSignature struct { // Reference to controller whose pods should avoid this node. // +optional - PodController *OwnerReference `json:"podController,omitempty" protobuf:"bytes,1,opt,name=podController"` + PodController *metav1.OwnerReference `json:"podController,omitempty" protobuf:"bytes,1,opt,name=podController"` } // Describe a container image @@ -2995,6 +3470,8 @@ const ( NodeDiskPressure NodeConditionType = "DiskPressure" // NodeNetworkUnavailable means that network for the node is not correctly configured. NodeNetworkUnavailable NodeConditionType = "NetworkUnavailable" + // NodeInodePressure means the kubelet is under pressure due to insufficient available inodes. + NodeInodePressure NodeConditionType = "InodePressure" ) // NodeCondition contains condition information for a node. @@ -3005,10 +3482,10 @@ type NodeCondition struct { Status ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=ConditionStatus"` // Last time we got an update on a given condition. // +optional - LastHeartbeatTime unversioned.Time `json:"lastHeartbeatTime,omitempty" protobuf:"bytes,3,opt,name=lastHeartbeatTime"` + LastHeartbeatTime metav1.Time `json:"lastHeartbeatTime,omitempty" protobuf:"bytes,3,opt,name=lastHeartbeatTime"` // Last time the condition transit from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` // (brief) reason for the condition's last transition. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"` @@ -3021,11 +3498,11 @@ type NodeAddressType string // These are valid address type of node. const ( - // Deprecated: NodeLegacyHostIP will be removed in 1.7. - NodeLegacyHostIP NodeAddressType = "LegacyHostIP" - NodeHostName NodeAddressType = "Hostname" - NodeExternalIP NodeAddressType = "ExternalIP" - NodeInternalIP NodeAddressType = "InternalIP" + NodeHostName NodeAddressType = "Hostname" + NodeExternalIP NodeAddressType = "ExternalIP" + NodeInternalIP NodeAddressType = "InternalIP" + NodeExternalDNS NodeAddressType = "ExternalDNS" + NodeInternalDNS NodeAddressType = "InternalDNS" ) // NodeAddress contains information for the node's address. @@ -3051,11 +3528,22 @@ const ( ResourceMemory ResourceName = "memory" // Volume size, in bytes (e,g. 5Gi = 5GiB = 5 * 1024 * 1024 * 1024) ResourceStorage ResourceName = "storage" + // Local Storage for container overlay filesystem, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageOverlay is alpha and it can change across releases. + ResourceStorageOverlay ResourceName = "storage.kubernetes.io/overlay" + // Local Storage for scratch space, in bytes. (500Gi = 500GiB = 500 * 1024 * 1024 * 1024) + // The resource name for ResourceStorageScratch is alpha and it can change across releases. + ResourceStorageScratch ResourceName = "storage.kubernetes.io/scratch" // NVIDIA GPU, in devices. Alpha, might change: although fractional and allowing values >1, only one whole device per node is assigned. ResourceNvidiaGPU ResourceName = "alpha.kubernetes.io/nvidia-gpu" // Number of Pods that may be running on this Node: see ResourcePods ) +const ( + // Namespace prefix for opaque counted resources (alpha). + ResourceOpaqueIntPrefix = "pod.alpha.kubernetes.io/opaque-int-resource-" +) + // ResourceList is a set of (resource name, quantity) pairs. type ResourceList map[ResourceName]resource.Quantity @@ -3065,49 +3553,50 @@ type ResourceList map[ResourceName]resource.Quantity // Node is a worker node in Kubernetes. // Each node will have a unique identifier in the cache (i.e. in etcd). type Node struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the behavior of a node. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec NodeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Most recently observed status of the node. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status NodeStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // NodeList is the whole list of all Nodes which have been registered with master. type NodeList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of nodes Items []Node `json:"items" protobuf:"bytes,2,rep,name=items"` } +// FinalizerName is the name identifying a finalizer during namespace lifecycle. type FinalizerName string -// These are internal finalizer values to Kubernetes, must be qualified name unless defined here +// These are internal finalizer values to Kubernetes, must be qualified name unless defined here or +// in metav1. const ( FinalizerKubernetes FinalizerName = "kubernetes" - FinalizerOrphan string = "orphan" ) // NamespaceSpec describes the attributes on a Namespace. type NamespaceSpec struct { // Finalizers is an opaque list of values that must be empty to permanently remove object from storage. - // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#finalizers + // More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#finalizers // +optional Finalizers []FinalizerName `json:"finalizers,omitempty" protobuf:"bytes,1,rep,name=finalizers,casttype=FinalizerName"` } @@ -3115,7 +3604,7 @@ type NamespaceSpec struct { // NamespaceStatus is information about the current status of a Namespace. type NamespaceStatus struct { // Phase is the current lifecycle phase of the namespace. - // More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#phases + // More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#phases // +optional Phase NamespacePhase `json:"phase,omitempty" protobuf:"bytes,1,opt,name=phase,casttype=NamespacePhase"` } @@ -3136,59 +3625,76 @@ const ( // Namespace provides a scope for Names. // Use of multiple namespaces is optional. type Namespace struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the behavior of the Namespace. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec NamespaceSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Status describes the current status of a Namespace. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status NamespaceStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // NamespaceList is a list of Namespaces. type NamespaceList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of Namespace objects in the list. - // More info: http://kubernetes.io/docs/user-guide/namespaces + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ Items []Namespace `json:"items" protobuf:"bytes,2,rep,name=items"` } -// Binding ties one object to another. -// For example, a pod is bound to a node by a scheduler. +// Binding ties one object to another; for example, a pod is bound to a node by a scheduler. +// Deprecated in 1.7, please use the bindings subresource of pods instead. type Binding struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // The target object that you want to bind to the standard object. Target ObjectReference `json:"target" protobuf:"bytes,2,opt,name=target"` } // Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out. +// +k8s:openapi-gen=false type Preconditions struct { // Specifies the target UID. // +optional - UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"` + UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"` } +// DeletionPropagation decides if a deletion will propagate to the dependents of the object, and how the garbage collector will handle the propagation. +type DeletionPropagation string + +const ( + // Orphans the dependents. + DeletePropagationOrphan DeletionPropagation = "Orphan" + // Deletes the object from the key-value store, the garbage collector will delete the dependents in the background. + DeletePropagationBackground DeletionPropagation = "Background" + // The object exists in the key-value store until the garbage collector deletes all the dependents whose ownerReference.blockOwnerDeletion=true from the key-value store. + // API sever will put the "DeletingDependents" finalizer on the object, and sets its deletionTimestamp. + // This policy is cascading, i.e., the dependents will be deleted with Foreground. + DeletePropagationForeground DeletionPropagation = "Foreground" +) + // DeleteOptions may be provided when deleting an API object +// DEPRECATED: This type has been moved to meta/v1 and will be removed soon. +// +k8s:openapi-gen=false type DeleteOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // The duration in seconds before the object should be deleted. Value must be non-negative integer. // The value zero indicates delete immediately. If this value is nil, the default grace period for the @@ -3202,25 +3708,26 @@ type DeleteOptions struct { // +optional Preconditions *Preconditions `json:"preconditions,omitempty" protobuf:"bytes,2,opt,name=preconditions"` + // Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. // Should the dependent objects be orphaned. If true/false, the "orphan" // finalizer will be added to/removed from the object's finalizers list. + // Either this field or PropagationPolicy may be set, but not both. // +optional OrphanDependents *bool `json:"orphanDependents,omitempty" protobuf:"varint,3,opt,name=orphanDependents"` -} -// ExportOptions is the query options to the standard REST get call. -type ExportOptions struct { - unversioned.TypeMeta `json:",inline"` - - // Should this value be exported. Export strips fields that a user can not specify. - Export bool `json:"export" protobuf:"varint,1,opt,name=export"` - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' - Exact bool `json:"exact" protobuf:"varint,2,opt,name=exact"` + // Whether and how garbage collection will be performed. + // Either this field or OrphanDependents may be set, but not both. + // The default policy is decided by the existing finalizer set in the + // metadata.finalizers and the resource-specific default policy. + // +optional + PropagationPolicy *DeletionPropagation `protobuf:"bytes,4,opt,name=propagationPolicy,casttype=DeletionPropagation"` } // ListOptions is the query options to a standard REST list call. +// DEPRECATED: This type has been moved to meta/v1 and will be removed soon. +// +k8s:openapi-gen=false type ListOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // A selector to restrict the list of returned objects by their labels. // Defaults to everything. @@ -3230,12 +3737,19 @@ type ListOptions struct { // Defaults to everything. // +optional FieldSelector string `json:"fieldSelector,omitempty" protobuf:"bytes,2,opt,name=fieldSelector"` + // If true, partially initialized resources are included in the response. + // +optional + IncludeUninitialized bool `json:"includeUninitialized,omitempty" protobuf:"varint,6,opt,name=includeUninitialized"` // Watch for changes to the described resources and return them as a stream of // add, update, and remove notifications. Specify resourceVersion. // +optional Watch bool `json:"watch,omitempty" protobuf:"varint,3,opt,name=watch"` // When specified with a watch call, shows changes that occur after that particular version of a resource. // Defaults to changes from the beginning of history. + // When specified for list: + // - if unset, then the result is returned from remote storage based on quorum-read flag; + // - if it's 0, then we simply return what we currently have in cache, no guarantee; + // - if set to non zero, then the result is at least as fresh as given rv. // +optional ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,4,opt,name=resourceVersion"` // Timeout for the list/watch call. @@ -3245,7 +3759,7 @@ type ListOptions struct { // PodLogOptions is the query options for a Pod's logs REST call. type PodLogOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // The container for which to stream logs. Defaults to only container if there is one container in the pod. // +optional @@ -3267,7 +3781,7 @@ type PodLogOptions struct { // If this value is in the future, no logs will be returned. // Only one of sinceSeconds or sinceTime may be specified. // +optional - SinceTime *unversioned.Time `json:"sinceTime,omitempty" protobuf:"bytes,5,opt,name=sinceTime"` + SinceTime *metav1.Time `json:"sinceTime,omitempty" protobuf:"bytes,5,opt,name=sinceTime"` // If true, add an RFC3339 or RFC3339Nano timestamp at the beginning of every line // of log output. Defaults to false. // +optional @@ -3288,7 +3802,7 @@ type PodLogOptions struct { // TODO: merge w/ PodExecOptions below for stdin, stdout, etc // and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY type PodAttachOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Stdin if true, redirects the standard input stream of the pod for this call. // Defaults to false. @@ -3323,7 +3837,7 @@ type PodAttachOptions struct { // TODO: This is largely identical to PodAttachOptions above, make sure they stay in sync and see about merging // and also when we cut V2, we should export a "StreamOptions" or somesuch that contains Stdin, Stdout, Stder and TTY type PodExecOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Redirect the standard input stream of the pod for this call. // Defaults to false. @@ -3354,9 +3868,24 @@ type PodExecOptions struct { Command []string `json:"command" protobuf:"bytes,6,rep,name=command"` } +// PodPortForwardOptions is the query options to a Pod's port forward call +// when using WebSockets. +// The `port` query parameter must specify the port or +// ports (comma separated) to forward over. +// Port forwarding over SPDY does not use these options. It requires the port +// to be passed in the `port` header as part of request. +type PodPortForwardOptions struct { + metav1.TypeMeta `json:",inline"` + + // List of ports to forward + // Required when using WebSockets + // +optional + Ports []int32 `json:"ports,omitempty" protobuf:"varint,1,rep,name=ports"` +} + // PodProxyOptions is the query options to a Pod's proxy call. type PodProxyOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Path is the URL path to use for the current proxy request to pod. // +optional @@ -3365,7 +3894,7 @@ type PodProxyOptions struct { // NodeProxyOptions is the query options to a Node's proxy call. type NodeProxyOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Path is the URL path to use for the current proxy request to node. // +optional @@ -3374,7 +3903,7 @@ type NodeProxyOptions struct { // ServiceProxyOptions is the query options to a Service's proxy call. type ServiceProxyOptions struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Path is the part of URLs that include service endpoints, suffixes, // and parameters to use for the current proxy request to service. @@ -3385,49 +3914,29 @@ type ServiceProxyOptions struct { Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"` } -// OwnerReference contains enough information to let you identify an owning -// object. Currently, an owning object must be in the same namespace, so there -// is no namespace field. -type OwnerReference struct { - // API version of the referent. - APIVersion string `json:"apiVersion" protobuf:"bytes,5,opt,name=apiVersion"` - // Kind of the referent. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` - // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names - Name string `json:"name" protobuf:"bytes,3,opt,name=name"` - // UID of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids - UID types.UID `json:"uid" protobuf:"bytes,4,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"` - // If true, this reference points to the managing controller. - // +optional - Controller *bool `json:"controller,omitempty" protobuf:"varint,6,opt,name=controller"` -} - // ObjectReference contains enough information to let you inspect or modify the referred object. type ObjectReference struct { // Kind of the referent. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"` // Namespace of the referent. - // More info: http://kubernetes.io/docs/user-guide/namespaces + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/ // +optional Namespace string `json:"namespace,omitempty" protobuf:"bytes,2,opt,name=namespace"` // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names // +optional Name string `json:"name,omitempty" protobuf:"bytes,3,opt,name=name"` // UID of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#uids + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids // +optional - UID types.UID `json:"uid,omitempty" protobuf:"bytes,4,opt,name=uid,casttype=k8s.io/kubernetes/pkg/types.UID"` + UID types.UID `json:"uid,omitempty" protobuf:"bytes,4,opt,name=uid,casttype=k8s.io/apimachinery/pkg/types.UID"` // API version of the referent. // +optional APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,5,opt,name=apiVersion"` // Specific resourceVersion to which this reference is made, if any. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency // +optional ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,6,opt,name=resourceVersion"` @@ -3447,7 +3956,7 @@ type ObjectReference struct { // referenced object inside the same namespace. type LocalObjectReference struct { // Name of the referent. - // More info: http://kubernetes.io/docs/user-guide/identifiers#names + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names // TODO: Add other useful fields. apiVersion, kind, uid? // +optional Name string `json:"name,omitempty" protobuf:"bytes,1,opt,name=name"` @@ -3455,7 +3964,7 @@ type LocalObjectReference struct { // SerializedReference is a reference to serialized object. type SerializedReference struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // The reference to an object in the system. // +optional Reference ObjectReference `json:"reference,omitempty" protobuf:"bytes,1,opt,name=reference"` @@ -3484,10 +3993,10 @@ const ( // Event is a report of an event somewhere in the cluster. // TODO: Decide whether to store these separately or with the object they apply to. type Event struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - ObjectMeta `json:"metadata" protobuf:"bytes,1,opt,name=metadata"` + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + metav1.ObjectMeta `json:"metadata" protobuf:"bytes,1,opt,name=metadata"` // The object that this event is about. InvolvedObject ObjectReference `json:"involvedObject" protobuf:"bytes,2,opt,name=involvedObject"` @@ -3509,11 +4018,11 @@ type Event struct { // The time at which the event was first recorded. (Time of server receipt is in TypeMeta.) // +optional - FirstTimestamp unversioned.Time `json:"firstTimestamp,omitempty" protobuf:"bytes,6,opt,name=firstTimestamp"` + FirstTimestamp metav1.Time `json:"firstTimestamp,omitempty" protobuf:"bytes,6,opt,name=firstTimestamp"` // The time at which the most recent occurrence of this event was recorded. // +optional - LastTimestamp unversioned.Time `json:"lastTimestamp,omitempty" protobuf:"bytes,7,opt,name=lastTimestamp"` + LastTimestamp metav1.Time `json:"lastTimestamp,omitempty" protobuf:"bytes,7,opt,name=lastTimestamp"` // The number of times this event has occurred. // +optional @@ -3526,11 +4035,11 @@ type Event struct { // EventList is a list of events. type EventList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of events Items []Event `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -3538,11 +4047,11 @@ type EventList struct { // List holds a list of objects, which may not be known by the server. type List struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of objects Items []runtime.RawExtension `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -3592,28 +4101,28 @@ type LimitRangeSpec struct { // LimitRange sets resource usage limits for each kind of resource in a Namespace. type LimitRange struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the limits enforced. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec LimitRangeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` } // LimitRangeList is a list of LimitRange items. type LimitRangeList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of LimitRange objects. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_limit_range.md + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_limit_range.md Items []LimitRange `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -3666,7 +4175,7 @@ const ( // ResourceQuotaSpec defines the desired hard limits to enforce for Quota. type ResourceQuotaSpec struct { // Hard is the set of desired hard limits for each named resource. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md // +optional Hard ResourceList `json:"hard,omitempty" protobuf:"bytes,1,rep,name=hard,casttype=ResourceList,castkey=ResourceName"` // A collection of filters that must match each object tracked by a quota. @@ -3678,7 +4187,7 @@ type ResourceQuotaSpec struct { // ResourceQuotaStatus defines the enforced hard limits and observed use. type ResourceQuotaStatus struct { // Hard is the set of enforced hard limits for each named resource. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md // +optional Hard ResourceList `json:"hard,omitempty" protobuf:"bytes,1,rep,name=hard,casttype=ResourceList,castkey=ResourceName"` // Used is the current observed total usage of the resource in the namespace. @@ -3690,33 +4199,33 @@ type ResourceQuotaStatus struct { // ResourceQuota sets aggregate quota restrictions enforced per namespace type ResourceQuota struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the desired quota. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec ResourceQuotaSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Status defines the actual enforced quota and its current usage. - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status ResourceQuotaStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // ResourceQuotaList is a list of ResourceQuota items. type ResourceQuotaList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of ResourceQuota objects. - // More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota + // More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md Items []ResourceQuota `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -3725,17 +4234,16 @@ type ResourceQuotaList struct { // Secret holds secret data of a certain type. The total bytes of the values in // the Data field must be less than MaxSecretSize bytes. type Secret struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN - // or leading dot followed by valid DNS_SUBDOMAIN. - // The serialized form of the secret data is a base64 encoded string, - // representing the arbitrary (possibly non-string) data value here. - // Described in https://tools.ietf.org/html/rfc4648#section-4 + // Data contains the secret data. Each key must consist of alphanumeric + // characters, '-', '_' or '.'. The serialized form of the secret data is a + // base64 encoded string, representing the arbitrary (possibly non-string) + // data value here. Described in https://tools.ietf.org/html/rfc4648#section-4 // +optional Data map[string][]byte `json:"data,omitempty" protobuf:"bytes,2,rep,name=data"` @@ -3790,6 +4298,35 @@ const ( // DockerConfigKey is the key of the required data for SecretTypeDockercfg secrets DockerConfigKey = ".dockercfg" + // SecretTypeDockerConfigJson contains a dockercfg file that follows the same format rules as ~/.docker/config.json + // + // Required fields: + // - Secret.Data[".dockerconfigjson"] - a serialized ~/.docker/config.json file + SecretTypeDockerConfigJson SecretType = "kubernetes.io/dockerconfigjson" + + // DockerConfigJsonKey is the key of the required data for SecretTypeDockerConfigJson secrets + DockerConfigJsonKey = ".dockerconfigjson" + + // SecretTypeBasicAuth contains data needed for basic authentication. + // + // Required at least one of fields: + // - Secret.Data["username"] - username used for authentication + // - Secret.Data["password"] - password or token needed for authentication + SecretTypeBasicAuth SecretType = "kubernetes.io/basic-auth" + + // BasicAuthUsernameKey is the key of the username for SecretTypeBasicAuth secrets + BasicAuthUsernameKey = "username" + // BasicAuthPasswordKey is the key of the password or token for SecretTypeBasicAuth secrets + BasicAuthPasswordKey = "password" + + // SecretTypeSSHAuth contains data needed for SSH authetication. + // + // Required field: + // - Secret.Data["ssh-privatekey"] - private SSH key needed for authentication + SecretTypeSSHAuth SecretType = "kubernetes.io/ssh-auth" + + // SSHAuthPrivateKey is the key of the required SSH private key for SecretTypeSSHAuth secrets + SSHAuthPrivateKey = "ssh-privatekey" // SecretTypeTLS contains information about a TLS client or server secret. It // is primarily used with TLS termination of the Ingress resource, but may be // used in other types. @@ -3808,14 +4345,14 @@ const ( // SecretList is a list of Secret. type SecretList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of secret objects. - // More info: http://kubernetes.io/docs/user-guide/secrets + // More info: https://kubernetes.io/docs/concepts/configuration/secret Items []Secret `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -3823,25 +4360,25 @@ type SecretList struct { // ConfigMap holds configuration data for pods to consume. type ConfigMap struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Data contains the configuration data. - // Each key must be a valid DNS_SUBDOMAIN with an optional leading dot. + // Each key must consist of alphanumeric characters, '-', '_' or '.'. // +optional Data map[string]string `json:"data,omitempty" protobuf:"bytes,2,rep,name=data"` } // ConfigMapList is a resource containing a list of ConfigMap objects. type ConfigMapList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of ConfigMaps. Items []ConfigMap `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -3878,24 +4415,26 @@ type ComponentCondition struct { // ComponentStatus (and ComponentStatusList) holds the cluster validation info. type ComponentStatus struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of component conditions observed // +optional + // +patchMergeKey=type + // +patchStrategy=merge Conditions []ComponentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,2,rep,name=conditions"` } // Status of all the conditions for the component as a list of ComponentStatus objects. type ComponentStatusList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of ComponentStatus objects. Items []ComponentStatus `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -3939,6 +4478,15 @@ type DownwardAPIVolumeFile struct { Mode *int32 `json:"mode,omitempty" protobuf:"varint,4,opt,name=mode"` } +// Represents downward API info for projecting into a projected volume. +// Note that this is identical to a downwardAPI volume source without the default +// mode. +type DownwardAPIProjection struct { + // Items is a list of DownwardAPIVolume file + // +optional + Items []DownwardAPIVolumeFile `json:"items,omitempty" protobuf:"bytes,1,rep,name=items"` +} + // SecurityContext holds security configuration that will be applied to a container. // Some fields are present in both SecurityContext and PodSecurityContext. When both // are set, the values in SecurityContext take precedence. @@ -3996,11 +4544,11 @@ type SELinuxOptions struct { // RangeAllocation is not a public type. type RangeAllocation struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Range is string that identifies the range represented by 'data'. Range string `json:"range" protobuf:"bytes,2,opt,name=range"` @@ -4011,4 +4559,59 @@ type RangeAllocation struct { const ( // "default-scheduler" is the name of default scheduler. DefaultSchedulerName = "default-scheduler" + + // RequiredDuringScheduling affinity is not symmetric, but there is an implicit PreferredDuringScheduling affinity rule + // corresponding to every RequiredDuringScheduling affinity rule. + // When the --hard-pod-affinity-weight scheduler flag is not specified, + // DefaultHardPodAffinityWeight defines the weight of the implicit PreferredDuringScheduling affinity rule. + DefaultHardPodAffinitySymmetricWeight int = 1 +) + +// Sysctl defines a kernel parameter to be set +type Sysctl struct { + // Name of a property to set + Name string `protobuf:"bytes,1,opt,name=name"` + // Value of a property to set + Value string `protobuf:"bytes,2,opt,name=value"` +} + +// NodeResources is an object for conveying resource information about a node. +// see http://releases.k8s.io/HEAD/docs/design/resources.md for more details. +type NodeResources struct { + // Capacity represents the available resources of a node + Capacity ResourceList `protobuf:"bytes,1,rep,name=capacity,casttype=ResourceList,castkey=ResourceName"` +} + +const ( + // Enable stdin for remote command execution + ExecStdinParam = "input" + // Enable stdout for remote command execution + ExecStdoutParam = "output" + // Enable stderr for remote command execution + ExecStderrParam = "error" + // Enable TTY for remote command execution + ExecTTYParam = "tty" + // Command to run for remote command execution + ExecCommandParamm = "command" + + // Name of header that specifies stream type + StreamType = "streamType" + // Value for streamType header for stdin stream + StreamTypeStdin = "stdin" + // Value for streamType header for stdout stream + StreamTypeStdout = "stdout" + // Value for streamType header for stderr stream + StreamTypeStderr = "stderr" + // Value for streamType header for data stream + StreamTypeData = "data" + // Value for streamType header for error stream + StreamTypeError = "error" + // Value for streamType header for terminal resize stream + StreamTypeResize = "resize" + + // Name of header that specifies the port being forwarded + PortHeader = "port" + // Name of header that specifies a request ID used to associate the error + // and data streams for a single forwarded connection + PortForwardRequestIDHeader = "requestID" ) diff --git a/vendor/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go index 5620489b30..f78b693071 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/types_swagger_doc_generated.go @@ -29,10 +29,10 @@ package v1 // AUTO-GENERATED FUNCTIONS START HERE var map_AWSElasticBlockStoreVolumeSource = map[string]string{ "": "Represents a Persistent Disk resource in AWS.\n\nAn AWS EBS disk must exist before mounting to a container. The disk must also be in the same AWS zone as the kubelet. An AWS EBS disk can only be mounted as read/write once. AWS EBS volumes support ownership management and SELinux relabeling.", - "volumeID": "Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore", - "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore", + "volumeID": "Unique ID of the persistent disk resource in AWS (Amazon EBS volume). More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", "partition": "The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty).", - "readOnly": "Specify \"true\" to force and set the ReadOnly property in VolumeMounts to \"true\". If omitted, the default is \"false\". More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore", + "readOnly": "Specify \"true\" to force and set the ReadOnly property in VolumeMounts to \"true\". If omitted, the default is \"false\". More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", } func (AWSElasticBlockStoreVolumeSource) SwaggerDoc() map[string]string { @@ -76,6 +76,7 @@ var map_AzureDiskVolumeSource = map[string]string{ "cachingMode": "Host Caching mode: None, Read Only, Read Write.", "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", "readOnly": "Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + "kind": "Expected values Shared: mulitple blob disks per storage account Dedicated: single blob disk per storage account Managed: azure managed data disk (only in managed availability set). defaults to shared", } func (AzureDiskVolumeSource) SwaggerDoc() map[string]string { @@ -94,8 +95,8 @@ func (AzureFileVolumeSource) SwaggerDoc() map[string]string { } var map_Binding = map[string]string{ - "": "Binding ties one object to another. For example, a pod is bound to a node by a scheduler.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "": "Binding ties one object to another; for example, a pod is bound to a node by a scheduler. Deprecated in 1.7, please use the bindings subresource of pods instead.", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "target": "The target object that you want to bind to the standard object.", } @@ -115,12 +116,12 @@ func (Capabilities) SwaggerDoc() map[string]string { var map_CephFSVolumeSource = map[string]string{ "": "Represents a Ceph Filesystem mount that lasts the lifetime of a pod Cephfs volumes do not support ownership management or SELinux relabeling.", - "monitors": "Required: Monitors is a collection of Ceph monitors More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", + "monitors": "Required: Monitors is a collection of Ceph monitors More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", "path": "Optional: Used as the mounted root, rather than the full Ceph tree, default is /", - "user": "Optional: User is the rados user name, default is admin More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", - "secretFile": "Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", - "secretRef": "Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", - "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: http://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", + "user": "Optional: User is the rados user name, default is admin More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", + "secretFile": "Optional: SecretFile is the path to key ring for User, default is /etc/ceph/user.secret More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", + "secretRef": "Optional: SecretRef is reference to the authentication secret for User, default is empty. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", + "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/volumes/cephfs/README.md#how-to-use-it", } func (CephFSVolumeSource) SwaggerDoc() map[string]string { @@ -129,9 +130,9 @@ func (CephFSVolumeSource) SwaggerDoc() map[string]string { var map_CinderVolumeSource = map[string]string{ "": "Represents a cinder volume resource in Openstack. A Cinder volume must exist before mounting to a container. The volume must also be in the same region as the kubelet. Cinder volumes support ownership management and SELinux relabeling.", - "volumeID": "volume id used to identify the volume in cinder More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", - "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", - "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", + "volumeID": "volume id used to identify the volume in cinder More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", + "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", + "readOnly": "Optional: Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts. More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", } func (CinderVolumeSource) SwaggerDoc() map[string]string { @@ -152,7 +153,7 @@ func (ComponentCondition) SwaggerDoc() map[string]string { var map_ComponentStatus = map[string]string{ "": "ComponentStatus (and ComponentStatusList) holds the cluster validation info.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "conditions": "List of component conditions observed", } @@ -162,7 +163,7 @@ func (ComponentStatus) SwaggerDoc() map[string]string { var map_ComponentStatusList = map[string]string{ "": "Status of all the conditions for the component as a list of ComponentStatus objects.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of ComponentStatus objects.", } @@ -172,17 +173,27 @@ func (ComponentStatusList) SwaggerDoc() map[string]string { var map_ConfigMap = map[string]string{ "": "ConfigMap holds configuration data for pods to consume.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "data": "Data contains the configuration data. Each key must be a valid DNS_SUBDOMAIN with an optional leading dot.", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "data": "Data contains the configuration data. Each key must consist of alphanumeric characters, '-', '_' or '.'.", } func (ConfigMap) SwaggerDoc() map[string]string { return map_ConfigMap } +var map_ConfigMapEnvSource = map[string]string{ + "": "ConfigMapEnvSource selects a ConfigMap to populate the environment variables with.\n\nThe contents of the target ConfigMap's Data field will represent the key-value pairs as environment variables.", + "optional": "Specify whether the ConfigMap must be defined", +} + +func (ConfigMapEnvSource) SwaggerDoc() map[string]string { + return map_ConfigMapEnvSource +} + var map_ConfigMapKeySelector = map[string]string{ - "": "Selects a key from a ConfigMap.", - "key": "The key to select.", + "": "Selects a key from a ConfigMap.", + "key": "The key to select.", + "optional": "Specify whether the ConfigMap or it's key must be defined", } func (ConfigMapKeySelector) SwaggerDoc() map[string]string { @@ -191,7 +202,7 @@ func (ConfigMapKeySelector) SwaggerDoc() map[string]string { var map_ConfigMapList = map[string]string{ "": "ConfigMapList is a resource containing a list of ConfigMap objects.", - "metadata": "More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "items": "Items is the list of ConfigMaps.", } @@ -199,10 +210,21 @@ func (ConfigMapList) SwaggerDoc() map[string]string { return map_ConfigMapList } +var map_ConfigMapProjection = map[string]string{ + "": "Adapts a ConfigMap into a projected volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a projected volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. Note that this is identical to a configmap volume source without the default mode.", + "items": "If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", + "optional": "Specify whether the ConfigMap or it's keys must be defined", +} + +func (ConfigMapProjection) SwaggerDoc() map[string]string { + return map_ConfigMapProjection +} + var map_ConfigMapVolumeSource = map[string]string{ "": "Adapts a ConfigMap into a volume.\n\nThe contents of the target ConfigMap's Data field will be presented in a volume as files using the keys in the Data field as the file names, unless the items element is populated with specific mappings of keys to paths. ConfigMap volumes support ownership management and SELinux relabeling.", - "items": "If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error. Paths must be relative and may not contain the '..' path or start with '..'.", + "items": "If unspecified, each key-value pair in the Data field of the referenced ConfigMap will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the ConfigMap, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", "defaultMode": "Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + "optional": "Specify whether the ConfigMap or it's keys must be defined", } func (ConfigMapVolumeSource) SwaggerDoc() map[string]string { @@ -210,25 +232,27 @@ func (ConfigMapVolumeSource) SwaggerDoc() map[string]string { } var map_Container = map[string]string{ - "": "A single application container that you want to run within a pod.", - "name": "Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated.", - "image": "Docker image name. More info: http://kubernetes.io/docs/user-guide/images", - "command": "Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/containers#containers-and-commands", - "args": "Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/containers#containers-and-commands", - "workingDir": "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", - "ports": "List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default \"0.0.0.0\" address inside a container will be accessible from the network. Cannot be updated.", - "env": "List of environment variables to set in the container. Cannot be updated.", - "resources": "Compute Resources required by this container. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#resources", - "volumeMounts": "Pod volumes to mount into the container's filesystem. Cannot be updated.", - "livenessProbe": "Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes", - "readinessProbe": "Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes", - "lifecycle": "Actions that the management system should take in response to container lifecycle events. Cannot be updated.", - "terminationMessagePath": "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Defaults to /dev/termination-log. Cannot be updated.", - "imagePullPolicy": "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/images#updating-images", - "securityContext": "Security options the pod should run with. More info: http://releases.k8s.io/HEAD/docs/design/security_context.md", - "stdin": "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", - "stdinOnce": "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", - "tty": "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", + "": "A single application container that you want to run within a pod.", + "name": "Name of the container specified as a DNS_LABEL. Each container in a pod must have a unique name (DNS_LABEL). Cannot be updated.", + "image": "Docker image name. More info: https://kubernetes.io/docs/concepts/containers/images", + "command": "Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + "args": "Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Cannot be updated. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + "workingDir": "Container's working directory. If not specified, the container runtime's default will be used, which might be configured in the container image. Cannot be updated.", + "ports": "List of ports to expose from the container. Exposing a port here gives the system additional information about the network connections a container uses, but is primarily informational. Not specifying a port here DOES NOT prevent that port from being exposed. Any port which is listening on the default \"0.0.0.0\" address inside a container will be accessible from the network. Cannot be updated.", + "envFrom": "List of sources to populate environment variables in the container. The keys defined within a source must be a C_IDENTIFIER. All invalid keys will be reported as an event when the container is starting. When a key exists in multiple sources, the value associated with the last source will take precedence. Values defined by an Env with a duplicate key will take precedence. Cannot be updated.", + "env": "List of environment variables to set in the container. Cannot be updated.", + "resources": "Compute Resources required by this container. Cannot be updated. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", + "volumeMounts": "Pod volumes to mount into the container's filesystem. Cannot be updated.", + "livenessProbe": "Periodic probe of container liveness. Container will be restarted if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + "readinessProbe": "Periodic probe of container service readiness. Container will be removed from service endpoints if the probe fails. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + "lifecycle": "Actions that the management system should take in response to container lifecycle events. Cannot be updated.", + "terminationMessagePath": "Optional: Path at which the file to which the container's termination message will be written is mounted into the container's filesystem. Message written is intended to be brief final status, such as an assertion failure message. Will be truncated by the node if greater than 4096 bytes. The total message length across all containers will be limited to 12kb. Defaults to /dev/termination-log. Cannot be updated.", + "terminationMessagePolicy": "Indicate how the termination message should be populated. File will use the contents of terminationMessagePath to populate the container status message on both success and failure. FallbackToLogsOnError will use the last chunk of container log output if the termination message file is empty and the container exited with an error. The log output is limited to 2048 bytes or 80 lines, whichever is smaller. Defaults to File. Cannot be updated.", + "imagePullPolicy": "Image pull policy. One of Always, Never, IfNotPresent. Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. Cannot be updated. More info: https://kubernetes.io/docs/concepts/containers/images#updating-images", + "securityContext": "Security options the pod should run with. More info: https://kubernetes.io/docs/concepts/policy/security-context/ More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md", + "stdin": "Whether this container should allocate a buffer for stdin in the container runtime. If this is not set, reads from stdin in the container will always result in EOF. Default is false.", + "stdinOnce": "Whether the container runtime should close the stdin channel after it has been opened by a single attach. When stdin is true the stdin stream will remain open across multiple attach sessions. If stdinOnce is set to true, stdin is opened on container start, is empty until the first client attaches to stdin, and then remains open and accepts data until the client disconnects, at which time stdin is closed and remains closed until the container is restarted. If this flag is false, a container processes that reads from stdin will never receive an EOF. Default is false", + "tty": "Whether this container should allocate a TTY for itself, also requires 'stdin' to be true. Default is false.", } func (Container) SwaggerDoc() map[string]string { @@ -310,9 +334,9 @@ var map_ContainerStatus = map[string]string{ "lastState": "Details about the container's last termination condition.", "ready": "Specifies whether the container has passed its readiness probe.", "restartCount": "The number of times the container has been restarted, currently based on the number of dead containers that have not yet been removed. Note that this is calculated from dead containers. But those containers are subject to garbage collection. This value will get capped at 5 by GC.", - "image": "The image the container is running. More info: http://kubernetes.io/docs/user-guide/images", + "image": "The image the container is running. More info: https://kubernetes.io/docs/concepts/containers/images", "imageID": "ImageID of the container's image.", - "containerID": "Container's ID in the format 'docker://'. More info: http://kubernetes.io/docs/user-guide/container-environment#container-information", + "containerID": "Container's ID in the format 'docker://'.", } func (ContainerStatus) SwaggerDoc() map[string]string { @@ -329,16 +353,26 @@ func (DaemonEndpoint) SwaggerDoc() map[string]string { } var map_DeleteOptions = map[string]string{ - "": "DeleteOptions may be provided when deleting an API object", + "": "DeleteOptions may be provided when deleting an API object DEPRECATED: This type has been moved to meta/v1 and will be removed soon.", "gracePeriodSeconds": "The duration in seconds before the object should be deleted. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period for the specified type will be used. Defaults to a per object value if not specified. zero means delete immediately.", "preconditions": "Must be fulfilled before a deletion is carried out. If not possible, a 409 Conflict status will be returned.", - "orphanDependents": "Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list.", + "orphanDependents": "Deprecated: please use the PropagationPolicy, this field will be deprecated in 1.7. Should the dependent objects be orphaned. If true/false, the \"orphan\" finalizer will be added to/removed from the object's finalizers list. Either this field or PropagationPolicy may be set, but not both.", + "PropagationPolicy": "Whether and how garbage collection will be performed. Either this field or OrphanDependents may be set, but not both. The default policy is decided by the existing finalizer set in the metadata.finalizers and the resource-specific default policy.", } func (DeleteOptions) SwaggerDoc() map[string]string { return map_DeleteOptions } +var map_DownwardAPIProjection = map[string]string{ + "": "Represents downward API info for projecting into a projected volume. Note that this is identical to a downwardAPI volume source without the default mode.", + "items": "Items is a list of DownwardAPIVolume file", +} + +func (DownwardAPIProjection) SwaggerDoc() map[string]string { + return map_DownwardAPIProjection +} + var map_DownwardAPIVolumeFile = map[string]string{ "": "DownwardAPIVolumeFile represents information to create the file containing the pod field", "path": "Required: Path is the relative path name of the file to be created. Must not be absolute or contain the '..' path. Must be utf-8 encoded. The first item of the relative path must not start with '..'", @@ -362,8 +396,9 @@ func (DownwardAPIVolumeSource) SwaggerDoc() map[string]string { } var map_EmptyDirVolumeSource = map[string]string{ - "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", - "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", + "": "Represents an empty directory for a pod. Empty directory volumes support ownership management and SELinux relabeling.", + "medium": "What type of storage medium should back this directory. The default is \"\" which means to use the node's default medium. Must be an empty string (default) or Memory. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + "sizeLimit": "Total amount of local storage required for this EmptyDir volume. The size limit is also applicable for memory medium. The maximum usage on memory medium EmptyDir would be the minimum value between the SizeLimit specified here and the sum of memory limits of all containers in a pod. The default is nil which means that the limit is undefined. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", } func (EmptyDirVolumeSource) SwaggerDoc() map[string]string { @@ -406,7 +441,7 @@ func (EndpointSubset) SwaggerDoc() map[string]string { var map_Endpoints = map[string]string{ "": "Endpoints is a collection of endpoints that implement the actual service. Example:\n Name: \"mysvc\",\n Subsets: [\n {\n Addresses: [{\"ip\": \"10.10.1.1\"}, {\"ip\": \"10.10.2.2\"}],\n Ports: [{\"name\": \"a\", \"port\": 8675}, {\"name\": \"b\", \"port\": 309}]\n },\n {\n Addresses: [{\"ip\": \"10.10.3.3\"}],\n Ports: [{\"name\": \"a\", \"port\": 93}, {\"name\": \"b\", \"port\": 76}]\n },\n ]", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "subsets": "The set of all endpoints is the union of all subsets. Addresses are placed into subsets according to the IPs they share. A single address with multiple ports, some of which are ready and some of which are not (because they come from different containers) will result in the address being displayed in different subsets for the different ports. No address will appear in both Addresses and NotReadyAddresses in the same subset. Sets of addresses and ports that comprise a service.", } @@ -416,7 +451,7 @@ func (Endpoints) SwaggerDoc() map[string]string { var map_EndpointsList = map[string]string{ "": "EndpointsList is a list of endpoints.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of endpoints.", } @@ -424,6 +459,17 @@ func (EndpointsList) SwaggerDoc() map[string]string { return map_EndpointsList } +var map_EnvFromSource = map[string]string{ + "": "EnvFromSource represents the source of a set of ConfigMaps", + "prefix": "An optional identifer to prepend to each key in the ConfigMap. Must be a C_IDENTIFIER.", + "configMapRef": "The ConfigMap to select from", + "secretRef": "The Secret to select from", +} + +func (EnvFromSource) SwaggerDoc() map[string]string { + return map_EnvFromSource +} + var map_EnvVar = map[string]string{ "": "EnvVar represents an environment variable present in a Container.", "name": "Name of the environment variable. Must be a C_IDENTIFIER.", @@ -437,7 +483,7 @@ func (EnvVar) SwaggerDoc() map[string]string { var map_EnvVarSource = map[string]string{ "": "EnvVarSource represents a source for the value of an EnvVar.", - "fieldRef": "Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, spec.nodeName, spec.serviceAccountName, status.podIP.", + "fieldRef": "Selects a field of the pod: supports metadata.name, metadata.namespace, metadata.labels, metadata.annotations, spec.nodeName, spec.serviceAccountName, status.hostIP, status.podIP.", "resourceFieldRef": "Selects a resource of the container: only resources limits and requests (limits.cpu, limits.memory, requests.cpu and requests.memory) are currently supported.", "configMapKeyRef": "Selects a key of a ConfigMap.", "secretKeyRef": "Selects a key of a secret in the pod's namespace", @@ -449,7 +495,7 @@ func (EnvVarSource) SwaggerDoc() map[string]string { var map_Event = map[string]string{ "": "Event is a report of an event somewhere in the cluster.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "involvedObject": "The object that this event is about.", "reason": "This should be a short, machine understandable string that gives the reason for the transition into the object's current status.", "message": "A human-readable description of the status of this operation.", @@ -466,7 +512,7 @@ func (Event) SwaggerDoc() map[string]string { var map_EventList = map[string]string{ "": "EventList is a list of events.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of events", } @@ -493,16 +539,6 @@ func (ExecAction) SwaggerDoc() map[string]string { return map_ExecAction } -var map_ExportOptions = map[string]string{ - "": "ExportOptions is the query options to the standard REST get call.", - "export": "Should this value be exported. Export strips fields that a user can not specify.", - "exact": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'", -} - -func (ExportOptions) SwaggerDoc() map[string]string { - return map_ExportOptions -} - var map_FCVolumeSource = map[string]string{ "": "Represents a Fibre Channel volume. Fibre Channel volumes can only be mounted as read/write once. Fibre Channel volumes support ownership management and SELinux relabeling.", "targetWWNs": "Required: FC target worldwide names (WWNs)", @@ -540,10 +576,10 @@ func (FlockerVolumeSource) SwaggerDoc() map[string]string { var map_GCEPersistentDiskVolumeSource = map[string]string{ "": "Represents a Persistent Disk resource in Google Compute Engine.\n\nA GCE PD must exist before mounting to a container. The disk must also be in the same GCE project and zone as the kubelet. A GCE PD can only be mounted as read/write once or read-only many times. GCE PDs support ownership management and SELinux relabeling.", - "pdName": "Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk", - "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk", - "partition": "The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty). More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk", - "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk", + "pdName": "Unique name of the PD resource in GCE. Used to identify the disk in GCE. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + "partition": "The partition in the volume that you want to mount. If omitted, the default is to mount by volume name. Examples: For volume /dev/sda1, you specify the partition as \"1\". Similarly, the volume partition for /dev/sda is \"0\" (or you can leave the property empty). More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", } func (GCEPersistentDiskVolumeSource) SwaggerDoc() map[string]string { @@ -563,9 +599,9 @@ func (GitRepoVolumeSource) SwaggerDoc() map[string]string { var map_GlusterfsVolumeSource = map[string]string{ "": "Represents a Glusterfs mount that lasts the lifetime of a pod. Glusterfs volumes do not support ownership management or SELinux relabeling.", - "endpoints": "EndpointsName is the endpoint name that details Glusterfs topology. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod", - "path": "Path is the Glusterfs volume path. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod", - "readOnly": "ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod", + "endpoints": "EndpointsName is the endpoint name that details Glusterfs topology. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod", + "path": "Path is the Glusterfs volume path. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod", + "readOnly": "ReadOnly here will force the Glusterfs volume to be mounted with read-only permissions. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md#create-a-pod", } func (GlusterfsVolumeSource) SwaggerDoc() map[string]string { @@ -606,9 +642,19 @@ func (Handler) SwaggerDoc() map[string]string { return map_Handler } +var map_HostAlias = map[string]string{ + "": "HostAlias holds the mapping between IP and hostnames that will be injected as an entry in the pod's hosts file.", + "ip": "IP address of the host file entry.", + "hostnames": "Hostnames for the above IP address.", +} + +func (HostAlias) SwaggerDoc() map[string]string { + return map_HostAlias +} + var map_HostPathVolumeSource = map[string]string{ "": "Represents a host path mapped into a pod. Host path volumes do not support ownership management or SELinux relabeling.", - "path": "Path of the directory on the host. More info: http://kubernetes.io/docs/user-guide/volumes#hostpath", + "path": "Path of the directory on the host. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", } func (HostPathVolumeSource) SwaggerDoc() map[string]string { @@ -616,13 +662,17 @@ func (HostPathVolumeSource) SwaggerDoc() map[string]string { } var map_ISCSIVolumeSource = map[string]string{ - "": "Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.", - "targetPortal": "iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", - "iqn": "Target iSCSI Qualified Name.", - "lun": "iSCSI target lun number.", - "iscsiInterface": "Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport.", - "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://kubernetes.io/docs/user-guide/volumes#iscsi", - "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.", + "": "Represents an ISCSI disk. ISCSI volumes can only be mounted as read/write once. ISCSI volumes support ownership management and SELinux relabeling.", + "targetPortal": "iSCSI target portal. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", + "iqn": "Target iSCSI Qualified Name.", + "lun": "iSCSI target lun number.", + "iscsiInterface": "Optional: Defaults to 'default' (tcp). iSCSI interface name that uses an iSCSI transport.", + "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#iscsi", + "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false.", + "portals": "iSCSI target portal List. The portal is either an IP or ip_addr:port if the port is other than default (typically TCP ports 860 and 3260).", + "chapAuthDiscovery": "whether support iSCSI Discovery CHAP authentication", + "chapAuthSession": "whether support iSCSI Session CHAP authentication", + "secretRef": "CHAP secret for iSCSI target and initiator authentication", } func (ISCSIVolumeSource) SwaggerDoc() map[string]string { @@ -642,8 +692,8 @@ func (KeyToPath) SwaggerDoc() map[string]string { var map_Lifecycle = map[string]string{ "": "Lifecycle describes actions that the management system should take in response to container lifecycle events. For the PostStart and PreStop lifecycle handlers, management of the container blocks until the action is complete, unless the container process fails, in which case the handler is aborted.", - "postStart": "PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: http://kubernetes.io/docs/user-guide/container-environment#hook-details", - "preStop": "PreStop is called immediately before a container is terminated. The container is terminated after the handler completes. The reason for termination is passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. Other management of the container blocks until the hook completes. More info: http://kubernetes.io/docs/user-guide/container-environment#hook-details", + "postStart": "PostStart is called immediately after a container is created. If the handler fails, the container is terminated and restarted according to its restart policy. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", + "preStop": "PreStop is called immediately before a container is terminated. The container is terminated after the handler completes. The reason for termination is passed to the handler. Regardless of the outcome of the handler, the container is eventually terminated. Other management of the container blocks until the hook completes. More info: https://kubernetes.io/docs/concepts/containers/container-lifecycle-hooks/#container-hooks", } func (Lifecycle) SwaggerDoc() map[string]string { @@ -652,8 +702,8 @@ func (Lifecycle) SwaggerDoc() map[string]string { var map_LimitRange = map[string]string{ "": "LimitRange sets resource usage limits for each kind of resource in a Namespace.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the limits enforced. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the limits enforced. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (LimitRange) SwaggerDoc() map[string]string { @@ -676,8 +726,8 @@ func (LimitRangeItem) SwaggerDoc() map[string]string { var map_LimitRangeList = map[string]string{ "": "LimitRangeList is a list of LimitRange items.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "Items is a list of LimitRange objects. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_limit_range.md", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "Items is a list of LimitRange objects. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_limit_range.md", } func (LimitRangeList) SwaggerDoc() map[string]string { @@ -695,7 +745,7 @@ func (LimitRangeSpec) SwaggerDoc() map[string]string { var map_List = map[string]string{ "": "List holds a list of objects, which may not be known by the server.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of objects", } @@ -704,12 +754,13 @@ func (List) SwaggerDoc() map[string]string { } var map_ListOptions = map[string]string{ - "": "ListOptions is the query options to a standard REST list call.", - "labelSelector": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", - "fieldSelector": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", - "watch": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", - "resourceVersion": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history.", - "timeoutSeconds": "Timeout for the list/watch call.", + "": "ListOptions is the query options to a standard REST list call. DEPRECATED: This type has been moved to meta/v1 and will be removed soon.", + "labelSelector": "A selector to restrict the list of returned objects by their labels. Defaults to everything.", + "fieldSelector": "A selector to restrict the list of returned objects by their fields. Defaults to everything.", + "includeUninitialized": "If true, partially initialized resources are included in the response.", + "watch": "Watch for changes to the described resources and return them as a stream of add, update, and remove notifications. Specify resourceVersion.", + "resourceVersion": "When specified with a watch call, shows changes that occur after that particular version of a resource. Defaults to changes from the beginning of history. When specified for list: - if unset, then the result is returned from remote storage based on quorum-read flag; - if it's 0, then we simply return what we currently have in cache, no guarantee; - if set to non zero, then the result is at least as fresh as given rv.", + "timeoutSeconds": "Timeout for the list/watch call.", } func (ListOptions) SwaggerDoc() map[string]string { @@ -737,18 +788,27 @@ func (LoadBalancerStatus) SwaggerDoc() map[string]string { var map_LocalObjectReference = map[string]string{ "": "LocalObjectReference contains enough information to let you locate the referenced object inside the same namespace.", - "name": "Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names", + "name": "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", } func (LocalObjectReference) SwaggerDoc() map[string]string { return map_LocalObjectReference } +var map_LocalVolumeSource = map[string]string{ + "": "Local represents directly-attached storage with node affinity", + "path": "The full path to the volume on the node For alpha, this path must be a directory Once block as a source is supported, then this path can point to a block device", +} + +func (LocalVolumeSource) SwaggerDoc() map[string]string { + return map_LocalVolumeSource +} + var map_NFSVolumeSource = map[string]string{ "": "Represents an NFS mount that lasts the lifetime of a pod. NFS volumes do not support ownership management or SELinux relabeling.", - "server": "Server is the hostname or IP address of the NFS server. More info: http://kubernetes.io/docs/user-guide/volumes#nfs", - "path": "Path that is exported by the NFS server. More info: http://kubernetes.io/docs/user-guide/volumes#nfs", - "readOnly": "ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: http://kubernetes.io/docs/user-guide/volumes#nfs", + "server": "Server is the hostname or IP address of the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + "path": "Path that is exported by the NFS server. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + "readOnly": "ReadOnly here will force the NFS export to be mounted with read-only permissions. Defaults to false. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", } func (NFSVolumeSource) SwaggerDoc() map[string]string { @@ -757,9 +817,9 @@ func (NFSVolumeSource) SwaggerDoc() map[string]string { var map_Namespace = map[string]string{ "": "Namespace provides a scope for Names. Use of multiple namespaces is optional.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the behavior of the Namespace. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status describes the current status of a Namespace. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the behavior of the Namespace. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Status describes the current status of a Namespace. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (Namespace) SwaggerDoc() map[string]string { @@ -768,8 +828,8 @@ func (Namespace) SwaggerDoc() map[string]string { var map_NamespaceList = map[string]string{ "": "NamespaceList is a list of Namespaces.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "Items is the list of Namespace objects in the list. More info: http://kubernetes.io/docs/user-guide/namespaces", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "Items is the list of Namespace objects in the list. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", } func (NamespaceList) SwaggerDoc() map[string]string { @@ -778,7 +838,7 @@ func (NamespaceList) SwaggerDoc() map[string]string { var map_NamespaceSpec = map[string]string{ "": "NamespaceSpec describes the attributes on a Namespace.", - "finalizers": "Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#finalizers", + "finalizers": "Finalizers is an opaque list of values that must be empty to permanently remove object from storage. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#finalizers", } func (NamespaceSpec) SwaggerDoc() map[string]string { @@ -787,7 +847,7 @@ func (NamespaceSpec) SwaggerDoc() map[string]string { var map_NamespaceStatus = map[string]string{ "": "NamespaceStatus is information about the current status of a Namespace.", - "phase": "Phase is the current lifecycle phase of the namespace. More info: http://releases.k8s.io/HEAD/docs/design/namespaces.md#phases", + "phase": "Phase is the current lifecycle phase of the namespace. More info: https://git.k8s.io/community/contributors/design-proposals/namespaces.md#phases", } func (NamespaceStatus) SwaggerDoc() map[string]string { @@ -796,9 +856,9 @@ func (NamespaceStatus) SwaggerDoc() map[string]string { var map_Node = map[string]string{ "": "Node is a worker node in Kubernetes. Each node will have a unique identifier in the cache (i.e. in etcd).", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the behavior of a node. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Most recently observed status of the node. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the behavior of a node. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Most recently observed status of the node. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (Node) SwaggerDoc() map[string]string { @@ -850,7 +910,7 @@ func (NodeDaemonEndpoints) SwaggerDoc() map[string]string { var map_NodeList = map[string]string{ "": "NodeList is the whole list of all Nodes which have been registered with master.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of nodes", } @@ -867,6 +927,15 @@ func (NodeProxyOptions) SwaggerDoc() map[string]string { return map_NodeProxyOptions } +var map_NodeResources = map[string]string{ + "": "NodeResources is an object for conveying resource information about a node. see http://releases.k8s.io/HEAD/docs/design/resources.md for more details.", + "Capacity": "Capacity represents the available resources of a node", +} + +func (NodeResources) SwaggerDoc() map[string]string { + return map_NodeResources +} + var map_NodeSelector = map[string]string{ "": "A node selector represents the union of the results of one or more label queries over a set of nodes; that is, it represents the OR of the selectors represented by the node selector terms.", "nodeSelectorTerms": "Required. A list of node selector terms. The terms are ORed.", @@ -901,7 +970,8 @@ var map_NodeSpec = map[string]string{ "podCIDR": "PodCIDR represents the pod IP range assigned to the node.", "externalID": "External ID of the node assigned by some machine database (e.g. a cloud provider). Deprecated.", "providerID": "ID of the node assigned by the cloud provider in the format: ://", - "unschedulable": "Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#manual-node-administration\"`", + "unschedulable": "Unschedulable controls node schedulability of new pods. By default, node is schedulable. More info: https://kubernetes.io/docs/concepts/nodes/node/#manual-node-administration", + "taints": "If specified, the node's taints.", } func (NodeSpec) SwaggerDoc() map[string]string { @@ -910,13 +980,13 @@ func (NodeSpec) SwaggerDoc() map[string]string { var map_NodeStatus = map[string]string{ "": "NodeStatus is information about the current status of a node.", - "capacity": "Capacity represents the total resources of a node. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#capacity for more details.", + "capacity": "Capacity represents the total resources of a node. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity", "allocatable": "Allocatable represents the resources of a node that are available for scheduling. Defaults to Capacity.", - "phase": "NodePhase is the recently observed lifecycle phase of the node. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-phase The field is never populated, and now is deprecated.", - "conditions": "Conditions is an array of current observed node conditions. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-condition", - "addresses": "List of addresses reachable to the node. Queried from cloud provider, if available. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-addresses", + "phase": "NodePhase is the recently observed lifecycle phase of the node. More info: https://kubernetes.io/docs/concepts/nodes/node/#phase The field is never populated, and now is deprecated.", + "conditions": "Conditions is an array of current observed node conditions. More info: https://kubernetes.io/docs/concepts/nodes/node/#condition", + "addresses": "List of addresses reachable to the node. Queried from cloud provider, if available. More info: https://kubernetes.io/docs/concepts/nodes/node/#addresses", "daemonEndpoints": "Endpoints of daemons running on the Node.", - "nodeInfo": "Set of ids/uuids to uniquely identify the node. More info: http://releases.k8s.io/HEAD/docs/admin/node.md#node-info", + "nodeInfo": "Set of ids/uuids to uniquely identify the node. More info: https://kubernetes.io/docs/concepts/nodes/node/#info", "images": "List of container images on this node", "volumesInUse": "List of attachable volumes in use (mounted) by the node.", "volumesAttached": "List of volumes that are attached to the node.", @@ -928,8 +998,8 @@ func (NodeStatus) SwaggerDoc() map[string]string { var map_NodeSystemInfo = map[string]string{ "": "NodeSystemInfo is a set of ids/uuids to uniquely identify the node.", - "machineID": "MachineID reported by the node. For unique machine identification in the cluster this field is prefered. Learn more from man(5) machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html", - "systemUUID": "SystemUUID reported by the node. For unique machine identification MachineID is prefered. This field is specific to Red Hat hosts https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html", + "machineID": "MachineID reported by the node. For unique machine identification in the cluster this field is preferred. Learn more from man(5) machine-id: http://man7.org/linux/man-pages/man5/machine-id.5.html", + "systemUUID": "SystemUUID reported by the node. For unique machine identification MachineID is preferred. This field is specific to Red Hat hosts https://access.redhat.com/documentation/en-US/Red_Hat_Subscription_Management/1/html/RHSM/getting-system-uuid.html", "bootID": "Boot ID reported by the node.", "kernelVersion": "Kernel Version reported by the node from 'uname -r' (e.g. 3.16.0-0.bpo.4-amd64).", "osImage": "OS Image reported by the node from /etc/os-release (e.g. Debian GNU/Linux 7 (wheezy)).", @@ -955,20 +1025,21 @@ func (ObjectFieldSelector) SwaggerDoc() map[string]string { } var map_ObjectMeta = map[string]string{ - "": "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create.", - "name": "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/identifiers#names", - "generateName": "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#idempotency", - "namespace": "Namespace defines the space within each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/namespaces", + "": "ObjectMeta is metadata that all persisted resources must have, which includes all objects users must create. DEPRECATED: Use k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta instead - this type will be removed soon.", + "name": "Name must be unique within a namespace. Is required when creating resources, although some resources may allow a client to request the generation of an appropriate name automatically. Name is primarily intended for creation idempotence and configuration definition. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + "generateName": "GenerateName is an optional prefix, used by the server, to generate a unique name ONLY IF the Name field has not been provided. If this field is used, the name returned to the client will be different than the name passed. This value will also be combined with a unique suffix. The provided value has the same validation rules as the Name field, and may be truncated by the length of the suffix required to make the value unique on the server.\n\nIf this field is specified and the generated name exists, the server will NOT return a 409 - instead, it will either return 201 Created or 500 with Reason ServerTimeout indicating a unique name could not be found in the time allotted, and the client should retry (optionally after the time indicated in the Retry-After header).\n\nApplied only if Name is not specified. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#idempotency", + "namespace": "Namespace defines the space within each name must be unique. An empty namespace is equivalent to the \"default\" namespace, but \"default\" is the canonical representation. Not all objects are required to be scoped to a namespace - the value of this field for those objects will be empty.\n\nMust be a DNS_LABEL. Cannot be updated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", "selfLink": "SelfLink is a URL representing this object. Populated by the system. Read-only.", - "uid": "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/identifiers#uids", - "resourceVersion": "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency", + "uid": "UID is the unique in time and space value for this object. It is typically generated by the server on successful creation of a resource and is not allowed to change on PUT operations.\n\nPopulated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids", + "resourceVersion": "An opaque value that represents the internal version of this object that can be used by clients to determine when objects have changed. May be used for optimistic concurrency, change detection, and the watch operation on a resource or set of resources. Clients must treat these values as opaque and passed unmodified back to the server. They may only be valid for a particular resource or set of resources.\n\nPopulated by the system. Read-only. Value must be treated as opaque by clients and . More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency", "generation": "A sequence number representing a specific generation of the desired state. Populated by the system. Read-only.", - "creationTimestamp": "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "deletionTimestamp": "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "creationTimestamp": "CreationTimestamp is a timestamp representing the server time when this object was created. It is not guaranteed to be set in happens-before order across separate operations. Clients may not set this value. It is represented in RFC3339 form and is in UTC.\n\nPopulated by the system. Read-only. Null for lists. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "deletionTimestamp": "DeletionTimestamp is RFC 3339 date and time at which this resource will be deleted. This field is set by the server when a graceful deletion is requested by the user, and is not directly settable by a client. The resource is expected to be deleted (no longer visible from resource lists, and not reachable by name) after the time in this field. Once set, this value may not be unset or be set further into the future, although it may be shortened or the resource may be deleted prior to this time. For example, a user may request that a pod is deleted in 30 seconds. The Kubelet will react by sending a graceful termination signal to the containers in the pod. After that 30 seconds, the Kubelet will send a hard termination signal (SIGKILL) to the container and after cleanup, remove the pod from the API. In the presence of network partitions, this object may still exist after this timestamp, until an administrator or automated process can determine the resource is fully terminated. If not set, graceful deletion of the object has not been requested.\n\nPopulated by the system when a graceful deletion is requested. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "deletionGracePeriodSeconds": "Number of seconds allowed for this object to gracefully terminate before it will be removed from the system. Only set when deletionTimestamp is also set. May only be shortened. Read-only.", - "labels": "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: http://kubernetes.io/docs/user-guide/labels", - "annotations": "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: http://kubernetes.io/docs/user-guide/annotations", + "labels": "Map of string keys and values that can be used to organize and categorize (scope and select) objects. May match selectors of replication controllers and services. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/", + "annotations": "Annotations is an unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/", "ownerReferences": "List of objects depended by this object. If ALL objects in the list have been deleted, this object will be garbage collected. If this object is managed by a controller, then an entry in this list will point to this controller, with the controller field set to true. There cannot be more than one managing controller.", + "initializers": "An initializer is a controller which enforces some system invariant at object creation time. This field is a list of initializers that have not yet acted on this object. If nil or empty, this object has been completely initialized. Otherwise, the object is considered uninitialized and is hidden (in list/watch and get calls) from clients that haven't explicitly asked to observe uninitialized objects.\n\nWhen an object is created, the system will populate this list with the current set of initializers. Only privileged users may set or modify this list. Once it is empty, it may not be modified further by any user.", "finalizers": "Must be empty before the object is deleted from the registry. Each entry is an identifier for the responsible component that will remove the entry from the list. If the deletionTimestamp of the object is non-nil, entries in this list can only be removed.", "clusterName": "The name of the cluster which the object belongs to. This is used to distinguish resources with same name and namespace in different clusters. This field is not set anywhere right now and apiserver is going to ignore it if set in create or update request.", } @@ -979,12 +1050,12 @@ func (ObjectMeta) SwaggerDoc() map[string]string { var map_ObjectReference = map[string]string{ "": "ObjectReference contains enough information to let you inspect or modify the referred object.", - "kind": "Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "namespace": "Namespace of the referent. More info: http://kubernetes.io/docs/user-guide/namespaces", - "name": "Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names", - "uid": "UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids", + "kind": "Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "namespace": "Namespace of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/", + "name": "Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", + "uid": "UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids", "apiVersion": "API version of the referent.", - "resourceVersion": "Specific resourceVersion to which this reference is made, if any. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#concurrency-control-and-consistency", + "resourceVersion": "Specific resourceVersion to which this reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency", "fieldPath": "If referring to a piece of an object instead of an entire object, this string should contain a valid JSON/Go field access statement, such as desiredState.manifest.containers[2]. For example, if the object reference is to a container within a pod, this would take on a value like: \"spec.containers{name}\" (where \"name\" refers to the name of the container that triggered the event) or if no container name is specified \"spec.containers[2]\" (container with index 2 in this pod). This syntax is chosen only to have some well-defined way of referencing a part of an object.", } @@ -992,24 +1063,11 @@ func (ObjectReference) SwaggerDoc() map[string]string { return map_ObjectReference } -var map_OwnerReference = map[string]string{ - "": "OwnerReference contains enough information to let you identify an owning object. Currently, an owning object must be in the same namespace, so there is no namespace field.", - "apiVersion": "API version of the referent.", - "kind": "Kind of the referent. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "name": "Name of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#names", - "uid": "UID of the referent. More info: http://kubernetes.io/docs/user-guide/identifiers#uids", - "controller": "If true, this reference points to the managing controller.", -} - -func (OwnerReference) SwaggerDoc() map[string]string { - return map_OwnerReference -} - var map_PersistentVolume = map[string]string{ - "": "PersistentVolume (PV) is a storage resource provisioned by an administrator. It is analogous to a node. More info: http://kubernetes.io/docs/user-guide/persistent-volumes", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistent-volumes", - "status": "Status represents the current information/status for the persistent volume. Populated by the system. Read-only. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistent-volumes", + "": "PersistentVolume (PV) is a storage resource provisioned by an administrator. It is analogous to a node. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines a specification of a persistent volume owned by the cluster. Provisioned by an administrator. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", + "status": "Status represents the current information/status for the persistent volume. Populated by the system. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistent-volumes", } func (PersistentVolume) SwaggerDoc() map[string]string { @@ -1018,9 +1076,9 @@ func (PersistentVolume) SwaggerDoc() map[string]string { var map_PersistentVolumeClaim = map[string]string{ "": "PersistentVolumeClaim is a user's request for and claim to a persistent volume", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the desired characteristics of a volume requested by a pod author. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims", - "status": "Status represents the current information/status of a persistent volume claim. Read-only. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the desired characteristics of a volume requested by a pod author. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + "status": "Status represents the current information/status of a persistent volume claim. Read-only. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", } func (PersistentVolumeClaim) SwaggerDoc() map[string]string { @@ -1029,8 +1087,8 @@ func (PersistentVolumeClaim) SwaggerDoc() map[string]string { var map_PersistentVolumeClaimList = map[string]string{ "": "PersistentVolumeClaimList is a list of PersistentVolumeClaim items.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "A list of persistent volume claims. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "A list of persistent volume claims. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", } func (PersistentVolumeClaimList) SwaggerDoc() map[string]string { @@ -1038,11 +1096,12 @@ func (PersistentVolumeClaimList) SwaggerDoc() map[string]string { } var map_PersistentVolumeClaimSpec = map[string]string{ - "": "PersistentVolumeClaimSpec describes the common attributes of storage devices and allows a Source for provider-specific attributes", - "accessModes": "AccessModes contains the desired access modes the volume should have. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes-1", - "selector": "A label query over volumes to consider for binding.", - "resources": "Resources represents the minimum resources the volume should have. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#resources", - "volumeName": "VolumeName is the binding reference to the PersistentVolume backing this claim.", + "": "PersistentVolumeClaimSpec describes the common attributes of storage devices and allows a Source for provider-specific attributes", + "accessModes": "AccessModes contains the desired access modes the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1", + "selector": "A label query over volumes to consider for binding.", + "resources": "Resources represents the minimum resources the volume should have. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources", + "volumeName": "VolumeName is the binding reference to the PersistentVolume backing this claim.", + "storageClassName": "Name of the StorageClass required by the claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#class-1", } func (PersistentVolumeClaimSpec) SwaggerDoc() map[string]string { @@ -1052,7 +1111,7 @@ func (PersistentVolumeClaimSpec) SwaggerDoc() map[string]string { var map_PersistentVolumeClaimStatus = map[string]string{ "": "PersistentVolumeClaimStatus is the current status of a persistent volume claim.", "phase": "Phase represents the current phase of PersistentVolumeClaim.", - "accessModes": "AccessModes contains the actual access modes the volume backing the PVC has. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes-1", + "accessModes": "AccessModes contains the actual access modes the volume backing the PVC has. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes-1", "capacity": "Represents the actual resources of the underlying volume.", } @@ -1062,7 +1121,7 @@ func (PersistentVolumeClaimStatus) SwaggerDoc() map[string]string { var map_PersistentVolumeClaimVolumeSource = map[string]string{ "": "PersistentVolumeClaimVolumeSource references the user's PVC in the same namespace. This volume finds the bound PV and mounts that volume for the pod. A PersistentVolumeClaimVolumeSource is, essentially, a wrapper around another type of volume that is owned by someone else (the system).", - "claimName": "ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims", + "claimName": "ClaimName is the name of a PersistentVolumeClaim in the same namespace as the pod using this volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", "readOnly": "Will force the ReadOnly setting in VolumeMounts. Default false.", } @@ -1072,8 +1131,8 @@ func (PersistentVolumeClaimVolumeSource) SwaggerDoc() map[string]string { var map_PersistentVolumeList = map[string]string{ "": "PersistentVolumeList is a list of PersistentVolume items.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "List of persistent volumes. More info: http://kubernetes.io/docs/user-guide/persistent-volumes", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of persistent volumes. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes", } func (PersistentVolumeList) SwaggerDoc() map[string]string { @@ -1082,14 +1141,14 @@ func (PersistentVolumeList) SwaggerDoc() map[string]string { var map_PersistentVolumeSource = map[string]string{ "": "PersistentVolumeSource is similar to VolumeSource but meant for the administrator who creates PVs. Exactly one of its members must be set.", - "gcePersistentDisk": "GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk", - "awsElasticBlockStore": "AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore", - "hostPath": "HostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: http://kubernetes.io/docs/user-guide/volumes#hostpath", - "glusterfs": "Glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md", - "nfs": "NFS represents an NFS mount on the host. Provisioned by an admin. More info: http://kubernetes.io/docs/user-guide/volumes#nfs", - "rbd": "RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md", + "gcePersistentDisk": "GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + "awsElasticBlockStore": "AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", + "hostPath": "HostPath represents a directory on the host. Provisioned by a developer or tester. This is useful for single-node development and testing only! On-host storage is not supported in any way and WILL NOT WORK in a multi-node cluster. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + "glusterfs": "Glusterfs represents a Glusterfs volume that is attached to a host and exposed to the pod. Provisioned by an admin. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md", + "nfs": "NFS represents an NFS mount on the host. Provisioned by an admin. More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + "rbd": "RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md", "iscsi": "ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. Provisioned by an admin.", - "cinder": "Cinder represents a cinder volume attached and mounted on kubelets host machine More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", + "cinder": "Cinder represents a cinder volume attached and mounted on kubelets host machine More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", "cephfs": "CephFS represents a Ceph FS mount on the host that shares a pod's lifetime", "fc": "FC represents a Fibre Channel resource that is attached to a kubelet's host machine and then exposed to the pod.", "flocker": "Flocker represents a Flocker volume attached to a kubelet's host machine and exposed to the pod for its usage. This depends on the Flocker control service being running", @@ -1099,6 +1158,10 @@ var map_PersistentVolumeSource = map[string]string{ "quobyte": "Quobyte represents a Quobyte mount on the host that shares a pod's lifetime", "azureDisk": "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.", "photonPersistentDisk": "PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine", + "portworxVolume": "PortworxVolume represents a portworx volume attached and mounted on kubelets host machine", + "scaleIO": "ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes.", + "local": "Local represents directly-attached storage with node affinity", + "storageos": "StorageOS represents a StorageOS volume that is attached to the kubelet's host machine and mounted into the pod More info: https://releases.k8s.io/HEAD/examples/volumes/storageos/README.md", } func (PersistentVolumeSource) SwaggerDoc() map[string]string { @@ -1107,10 +1170,11 @@ func (PersistentVolumeSource) SwaggerDoc() map[string]string { var map_PersistentVolumeSpec = map[string]string{ "": "PersistentVolumeSpec is the specification of a persistent volume.", - "capacity": "A description of the persistent volume's resources and capacity. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#capacity", - "accessModes": "AccessModes contains all ways the volume can be mounted. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#access-modes", - "claimRef": "ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#binding", - "persistentVolumeReclaimPolicy": "What happens to a persistent volume when released from its claim. Valid options are Retain (default) and Recycle. Recycling must be supported by the volume plugin underlying this persistent volume. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#recycling-policy", + "capacity": "A description of the persistent volume's resources and capacity. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#capacity", + "accessModes": "AccessModes contains all ways the volume can be mounted. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#access-modes", + "claimRef": "ClaimRef is part of a bi-directional binding between PersistentVolume and PersistentVolumeClaim. Expected to be non-nil when bound. claim.VolumeName is the authoritative bind between PV and PVC. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#binding", + "persistentVolumeReclaimPolicy": "What happens to a persistent volume when released from its claim. Valid options are Retain (default) and Recycle. Recycling must be supported by the volume plugin underlying this persistent volume. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#reclaiming", + "storageClassName": "Name of StorageClass to which this persistent volume belongs. Empty value means that this volume does not belong to any StorageClass.", } func (PersistentVolumeSpec) SwaggerDoc() map[string]string { @@ -1119,7 +1183,7 @@ func (PersistentVolumeSpec) SwaggerDoc() map[string]string { var map_PersistentVolumeStatus = map[string]string{ "": "PersistentVolumeStatus is the current status of a persistent volume.", - "phase": "Phase indicates if a volume is available, bound to a claim, or released by a claim. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#phase", + "phase": "Phase indicates if a volume is available, bound to a claim, or released by a claim. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#phase", "message": "A human-readable message indicating details about why the volume is in this state.", "reason": "Reason is a brief CamelCase string that describes any failure and is meant for machine parsing and tidy display in the CLI.", } @@ -1140,9 +1204,9 @@ func (PhotonPersistentDiskVolumeSource) SwaggerDoc() map[string]string { var map_Pod = map[string]string{ "": "Pod is a collection of containers that can run on a host. This resource is created by clients and scheduled onto hosts.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Specification of the desired behavior of the pod. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (Pod) SwaggerDoc() map[string]string { @@ -1162,7 +1226,7 @@ func (PodAffinity) SwaggerDoc() map[string]string { var map_PodAffinityTerm = map[string]string{ "": "Defines a set of pods (namely those matching the labelSelector relative to the given namespace(s)) that this pod should be co-located (affinity) or not co-located (anti-affinity) with, where co-located is defined as running on a node whose value of the label with key tches that of any node on which a pod of the set of pods is running", "labelSelector": "A label query over a set of resources, in this case pods.", - "namespaces": "namespaces specifies which namespaces the labelSelector applies to (matches against); nil list means \"this pod's namespace,\" empty list means \"all namespaces\" The json tag here is not \"omitempty\" since we need to distinguish nil and empty. See https://golang.org/pkg/encoding/json/#Marshal for more details.", + "namespaces": "namespaces specifies which namespaces the labelSelector applies to (matches against); null or empty list means \"this pod's namespace\"", "topologyKey": "This pod should be co-located (affinity) or not co-located (anti-affinity) with the pods matching the labelSelector in the specified namespaces, where co-located is defined as running on a node whose value of the label with key topologyKey matches that of any node on which any of the selected pods is running. For PreferredDuringScheduling pod anti-affinity, empty topologyKey is interpreted as \"all topologies\" (\"all topologies\" here means all the topologyKeys indicated by scheduler command-line argument --failure-domains); for affinity and for RequiredDuringScheduling pod anti-affinity, empty topologyKey is not allowed.", } @@ -1195,8 +1259,8 @@ func (PodAttachOptions) SwaggerDoc() map[string]string { var map_PodCondition = map[string]string{ "": "PodCondition contains details for the current condition of this pod.", - "type": "Type is the type of the condition. Currently only Ready. More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions", - "status": "Status is the status of the condition. Can be True, False, Unknown. More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions", + "type": "Type is the type of the condition. Currently only Ready. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", + "status": "Status is the status of the condition. Can be True, False, Unknown. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", "lastProbeTime": "Last time we probed the condition.", "lastTransitionTime": "Last time the condition transitioned from one status to another.", "reason": "Unique, one-word, CamelCase reason for the condition's last transition.", @@ -1223,8 +1287,8 @@ func (PodExecOptions) SwaggerDoc() map[string]string { var map_PodList = map[string]string{ "": "PodList is a list of Pods.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "List of pods. More info: http://kubernetes.io/docs/user-guide/pods", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of pods. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md", } func (PodList) SwaggerDoc() map[string]string { @@ -1247,6 +1311,15 @@ func (PodLogOptions) SwaggerDoc() map[string]string { return map_PodLogOptions } +var map_PodPortForwardOptions = map[string]string{ + "": "PodPortForwardOptions is the query options to a Pod's port forward call when using WebSockets. The `port` query parameter must specify the port or ports (comma separated) to forward over. Port forwarding over SPDY does not use these options. It requires the port to be passed in the `port` header as part of request.", + "ports": "List of ports to forward Required when using WebSockets", +} + +func (PodPortForwardOptions) SwaggerDoc() map[string]string { + return map_PodPortForwardOptions +} + var map_PodProxyOptions = map[string]string{ "": "PodProxyOptions is the query options to a Pod's proxy call.", "path": "Path is the URL path to use for the current proxy request to pod.", @@ -1280,23 +1353,29 @@ func (PodSignature) SwaggerDoc() map[string]string { var map_PodSpec = map[string]string{ "": "PodSpec is a description of a pod.", - "volumes": "List of volumes that can be mounted by containers belonging to the pod. More info: http://kubernetes.io/docs/user-guide/volumes", - "containers": "List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated. More info: http://kubernetes.io/docs/user-guide/containers", - "restartPolicy": "Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: http://kubernetes.io/docs/user-guide/pod-states#restartpolicy", + "volumes": "List of volumes that can be mounted by containers belonging to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes", + "initContainers": "List of initialization containers belonging to the pod. Init containers are executed in order prior to containers being started. If any init container fails, the pod is considered to have failed and is handled according to its restartPolicy. The name for an init container or normal container must be unique among all containers. Init containers may not have Lifecycle actions, Readiness probes, or Liveness probes. The resourceRequirements of an init container are taken into account during scheduling by finding the highest request/limit for each resource type, and then using the max of of that value or the sum of the normal containers. Limits are applied to init containers in a similar fashion. Init containers cannot currently be added or removed. Cannot be updated. More info: https://kubernetes.io/docs/concepts/workloads/pods/init-containers/", + "containers": "List of containers belonging to the pod. Containers cannot currently be added or removed. There must be at least one container in a Pod. Cannot be updated.", + "restartPolicy": "Restart policy for all containers within the pod. One of Always, OnFailure, Never. Default to Always. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle/#restart-policy", "terminationGracePeriodSeconds": "Optional duration in seconds the pod needs to terminate gracefully. May be decreased in delete request. Value must be non-negative integer. The value zero indicates delete immediately. If this value is nil, the default grace period will be used instead. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Defaults to 30 seconds.", "activeDeadlineSeconds": "Optional duration in seconds the pod may be active on the node relative to StartTime before the system will actively try to mark it failed and kill associated containers. Value must be a positive integer.", - "dnsPolicy": "Set DNS policy for containers within the pod. One of 'ClusterFirst' or 'Default'. Defaults to \"ClusterFirst\".", - "nodeSelector": "NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: http://kubernetes.io/docs/user-guide/node-selection/README", - "serviceAccountName": "ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md", + "dnsPolicy": "Set DNS policy for containers within the pod. One of 'ClusterFirstWithHostNet', 'ClusterFirst' or 'Default'. Defaults to \"ClusterFirst\". To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'.", + "nodeSelector": "NodeSelector is a selector which must be true for the pod to fit on a node. Selector which must match a node's labels for the pod to be scheduled on that node. More info: https://kubernetes.io/docs/concepts/configuration/assign-pod-node/", + "serviceAccountName": "ServiceAccountName is the name of the ServiceAccount to use to run this pod. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/", "serviceAccount": "DeprecatedServiceAccount is a depreciated alias for ServiceAccountName. Deprecated: Use serviceAccountName instead.", + "automountServiceAccountToken": "AutomountServiceAccountToken indicates whether a service account token should be automatically mounted.", "nodeName": "NodeName is a request to schedule this pod onto a specific node. If it is non-empty, the scheduler simply schedules this pod onto that node, assuming that it fits resource requirements.", "hostNetwork": "Host networking requested for this pod. Use the host's network namespace. If this option is set, the ports that will be used must be specified. Default to false.", "hostPID": "Use the host's pid namespace. Optional: Default to false.", "hostIPC": "Use the host's ipc namespace. Optional: Default to false.", "securityContext": "SecurityContext holds pod-level security attributes and common container settings. Optional: Defaults to empty. See type description for default values of each field.", - "imagePullSecrets": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: http://kubernetes.io/docs/user-guide/images#specifying-imagepullsecrets-on-a-pod", + "imagePullSecrets": "ImagePullSecrets is an optional list of references to secrets in the same namespace to use for pulling any of the images used by this PodSpec. If specified, these secrets will be passed to individual puller implementations for them to use. For example, in the case of docker, only DockerConfig type secrets are honored. More info: https://kubernetes.io/docs/concepts/containers/images#specifying-imagepullsecrets-on-a-pod", "hostname": "Specifies the hostname of the Pod If not specified, the pod's hostname will be set to a system-defined value.", "subdomain": "If specified, the fully qualified Pod hostname will be \"...svc.\". If not specified, the pod will not have a domainname at all.", + "affinity": "If specified, the pod's scheduling constraints", + "schedulerName": "If specified, the pod will be dispatched by specified scheduler. If not specified, the pod will be dispatched by default scheduler.", + "tolerations": "If specified, the pod's tolerations.", + "hostAliases": "HostAliases is an optional list of hosts and IPs that will be injected into the pod's hosts file if specified. This is only valid for non-hostNetwork pods.", } func (PodSpec) SwaggerDoc() map[string]string { @@ -1304,15 +1383,17 @@ func (PodSpec) SwaggerDoc() map[string]string { } var map_PodStatus = map[string]string{ - "": "PodStatus represents information about the status of a pod. Status may trail the actual state of a system.", - "phase": "Current condition of the pod. More info: http://kubernetes.io/docs/user-guide/pod-states#pod-phase", - "conditions": "Current service state of pod. More info: http://kubernetes.io/docs/user-guide/pod-states#pod-conditions", - "message": "A human readable message indicating details about why the pod is in this condition.", - "reason": "A brief CamelCase message indicating details about why the pod is in this state. e.g. 'OutOfDisk'", - "hostIP": "IP address of the host to which the pod is assigned. Empty if not yet scheduled.", - "podIP": "IP address allocated to the pod. Routable at least within the cluster. Empty if not yet allocated.", - "startTime": "RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod.", - "containerStatuses": "The list has one entry per container in the manifest. Each entry is currently the output of `docker inspect`. More info: http://kubernetes.io/docs/user-guide/pod-states#container-statuses", + "": "PodStatus represents information about the status of a pod. Status may trail the actual state of a system.", + "phase": "Current condition of the pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-phase", + "conditions": "Current service state of pod. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-conditions", + "message": "A human readable message indicating details about why the pod is in this condition.", + "reason": "A brief CamelCase message indicating details about why the pod is in this state. e.g. 'OutOfDisk'", + "hostIP": "IP address of the host to which the pod is assigned. Empty if not yet scheduled.", + "podIP": "IP address allocated to the pod. Routable at least within the cluster. Empty if not yet allocated.", + "startTime": "RFC 3339 date and time at which the object was acknowledged by the Kubelet. This is before the Kubelet pulled the container image(s) for the pod.", + "initContainerStatuses": "The list has one entry per init container in the manifest. The most recent successful init container will have ready = true, the most recently started container will have startTime set. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status", + "containerStatuses": "The list has one entry per container in the manifest. Each entry is currently the output of `docker inspect`. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#pod-and-container-status", + "qosClass": "The Quality of Service (QOS) classification assigned to the pod based on resource requirements See PodQOSClass type for available QOS classes More info: https://github.com/kubernetes/kubernetes/blob/master/docs/design/resource-qos.md", } func (PodStatus) SwaggerDoc() map[string]string { @@ -1321,8 +1402,8 @@ func (PodStatus) SwaggerDoc() map[string]string { var map_PodStatusResult = map[string]string{ "": "PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "status": "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "status": "Most recently observed status of the pod. This data may not be up to date. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (PodStatusResult) SwaggerDoc() map[string]string { @@ -1331,8 +1412,8 @@ func (PodStatusResult) SwaggerDoc() map[string]string { var map_PodTemplate = map[string]string{ "": "PodTemplate describes a template for creating copies of a predefined pod.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "template": "Template defines the pods that will be created from this pod template. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "template": "Template defines the pods that will be created from this pod template. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (PodTemplate) SwaggerDoc() map[string]string { @@ -1341,7 +1422,7 @@ func (PodTemplate) SwaggerDoc() map[string]string { var map_PodTemplateList = map[string]string{ "": "PodTemplateList is a list of PodTemplates.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of pod templates", } @@ -1351,14 +1432,25 @@ func (PodTemplateList) SwaggerDoc() map[string]string { var map_PodTemplateSpec = map[string]string{ "": "PodTemplateSpec describes the data a pod should have when created from a template", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Specification of the desired behavior of the pod. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior of the pod. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (PodTemplateSpec) SwaggerDoc() map[string]string { return map_PodTemplateSpec } +var map_PortworxVolumeSource = map[string]string{ + "": "PortworxVolumeSource represents a Portworx volume resource.", + "volumeID": "VolumeID uniquely identifies a Portworx volume", + "fsType": "FSType represents the filesystem type to mount Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\". Implicitly inferred to be \"ext4\" if unspecified.", + "readOnly": "Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", +} + +func (PortworxVolumeSource) SwaggerDoc() map[string]string { + return map_PortworxVolumeSource +} + var map_Preconditions = map[string]string{ "": "Preconditions must be fulfilled before an operation (update, delete, etc.) is carried out.", "uid": "Specifies the target UID.", @@ -1392,8 +1484,8 @@ func (PreferredSchedulingTerm) SwaggerDoc() map[string]string { var map_Probe = map[string]string{ "": "Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic.", - "initialDelaySeconds": "Number of seconds after the container has started before liveness probes are initiated. More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes", - "timeoutSeconds": "Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: http://kubernetes.io/docs/user-guide/pod-states#container-probes", + "initialDelaySeconds": "Number of seconds after the container has started before liveness probes are initiated. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", + "timeoutSeconds": "Number of seconds after which the probe times out. Defaults to 1 second. Minimum value is 1. More info: https://kubernetes.io/docs/concepts/workloads/pods/pod-lifecycle#container-probes", "periodSeconds": "How often (in seconds) to perform the probe. Default to 10 seconds. Minimum value is 1.", "successThreshold": "Minimum consecutive successes for the probe to be considered successful after having failed. Defaults to 1. Must be 1 for liveness. Minimum value is 1.", "failureThreshold": "Minimum consecutive failures for the probe to be considered failed after having succeeded. Defaults to 3. Minimum value is 1.", @@ -1403,6 +1495,16 @@ func (Probe) SwaggerDoc() map[string]string { return map_Probe } +var map_ProjectedVolumeSource = map[string]string{ + "": "Represents a projected volume source", + "sources": "list of volume projections", + "defaultMode": "Mode bits to use on created files by default. Must be a value between 0 and 0777. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", +} + +func (ProjectedVolumeSource) SwaggerDoc() map[string]string { + return map_ProjectedVolumeSource +} + var map_QuobyteVolumeSource = map[string]string{ "": "Represents a Quobyte mount that lasts the lifetime of a pod. Quobyte volumes do not support ownership management or SELinux relabeling.", "registry": "Registry represents a single or multiple Quobyte Registry services specified as a string as host:port pair (multiple entries are separated with commas) which acts as the central registry for volumes", @@ -1418,14 +1520,14 @@ func (QuobyteVolumeSource) SwaggerDoc() map[string]string { var map_RBDVolumeSource = map[string]string{ "": "Represents a Rados Block Device mount that lasts the lifetime of a pod. RBD volumes support ownership management and SELinux relabeling.", - "monitors": "A collection of Ceph monitors. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", - "image": "The rados image name. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", - "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: http://kubernetes.io/docs/user-guide/volumes#rbd", - "pool": "The rados pool name. Default is rbd. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it.", - "user": "The rados user name. Default is admin. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", - "keyring": "Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", - "secretRef": "SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", - "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "monitors": "A collection of Ceph monitors. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "image": "The rados image name. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "fsType": "Filesystem type of the volume that you want to mount. Tip: Ensure that the filesystem type is supported by the host operating system. Examples: \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified. More info: https://kubernetes.io/docs/concepts/storage/volumes#rbd", + "pool": "The rados pool name. Default is rbd. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "user": "The rados user name. Default is admin. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "keyring": "Keyring is the path to key ring for RBDUser. Default is /etc/ceph/keyring. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "secretRef": "SecretRef is name of the authentication secret for RBDUser. If provided overrides keyring. Default is nil. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", + "readOnly": "ReadOnly here will force the ReadOnly setting in VolumeMounts. Defaults to false. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md#how-to-use-it", } func (RBDVolumeSource) SwaggerDoc() map[string]string { @@ -1434,7 +1536,7 @@ func (RBDVolumeSource) SwaggerDoc() map[string]string { var map_RangeAllocation = map[string]string{ "": "RangeAllocation is not a public type.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "range": "Range is string that identifies the range represented by 'data'.", "data": "Data is a bit array containing all allocated addresses in the previous segment.", } @@ -1445,9 +1547,9 @@ func (RangeAllocation) SwaggerDoc() map[string]string { var map_ReplicationController = map[string]string{ "": "ReplicationController represents the configuration of a replication controller.", - "metadata": "If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the specification of the desired behavior of the replication controller. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is the most recently observed status of the replication controller. This data may be out of date by some window of time. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "If the Labels of a ReplicationController are empty, they are defaulted to be the same as the Pod(s) that the replication controller manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the specification of the desired behavior of the replication controller. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Status is the most recently observed status of the replication controller. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (ReplicationController) SwaggerDoc() map[string]string { @@ -1469,8 +1571,8 @@ func (ReplicationControllerCondition) SwaggerDoc() map[string]string { var map_ReplicationControllerList = map[string]string{ "": "ReplicationControllerList is a collection of replication controllers.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "List of replication controllers. More info: http://kubernetes.io/docs/user-guide/replication-controller", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of replication controllers. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller", } func (ReplicationControllerList) SwaggerDoc() map[string]string { @@ -1479,10 +1581,10 @@ func (ReplicationControllerList) SwaggerDoc() map[string]string { var map_ReplicationControllerSpec = map[string]string{ "": "ReplicationControllerSpec is the specification of a replication controller.", - "replicas": "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller", + "replicas": "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller", "minReadySeconds": "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", - "selector": "Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "template": "Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template", + "selector": "Selector is a label query over pods that should match the Replicas count. If Selector is empty, it is defaulted to the labels present on the Pod template. Label keys and values that must match in order to be controlled by this replication controller, if empty defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", + "template": "Template is the object that describes the pod that will be created if insufficient replicas are detected. This takes precedence over a TemplateRef. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template", } func (ReplicationControllerSpec) SwaggerDoc() map[string]string { @@ -1491,7 +1593,7 @@ func (ReplicationControllerSpec) SwaggerDoc() map[string]string { var map_ReplicationControllerStatus = map[string]string{ "": "ReplicationControllerStatus represents the current status of a replication controller.", - "replicas": "Replicas is the most recently oberved number of replicas. More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller", + "replicas": "Replicas is the most recently oberved number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#what-is-a-replicationcontroller", "fullyLabeledReplicas": "The number of pods that have labels matching the labels of the pod template of the replication controller.", "readyReplicas": "The number of ready replicas for this replication controller.", "availableReplicas": "The number of available replicas (ready for at least minReadySeconds) for this replication controller.", @@ -1516,9 +1618,9 @@ func (ResourceFieldSelector) SwaggerDoc() map[string]string { var map_ResourceQuota = map[string]string{ "": "ResourceQuota sets aggregate quota restrictions enforced per namespace", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the desired quota. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status defines the actual enforced quota and its current usage. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the desired quota. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Status defines the actual enforced quota and its current usage. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (ResourceQuota) SwaggerDoc() map[string]string { @@ -1527,8 +1629,8 @@ func (ResourceQuota) SwaggerDoc() map[string]string { var map_ResourceQuotaList = map[string]string{ "": "ResourceQuotaList is a list of ResourceQuota items.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "Items is a list of ResourceQuota objects. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "Items is a list of ResourceQuota objects. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md", } func (ResourceQuotaList) SwaggerDoc() map[string]string { @@ -1537,7 +1639,7 @@ func (ResourceQuotaList) SwaggerDoc() map[string]string { var map_ResourceQuotaSpec = map[string]string{ "": "ResourceQuotaSpec defines the desired hard limits to enforce for Quota.", - "hard": "Hard is the set of desired hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota", + "hard": "Hard is the set of desired hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md", "scopes": "A collection of filters that must match each object tracked by a quota. If not specified, the quota matches all objects.", } @@ -1547,7 +1649,7 @@ func (ResourceQuotaSpec) SwaggerDoc() map[string]string { var map_ResourceQuotaStatus = map[string]string{ "": "ResourceQuotaStatus defines the enforced hard limits and observed use.", - "hard": "Hard is the set of enforced hard limits for each named resource. More info: http://releases.k8s.io/HEAD/docs/design/admission_control_resource_quota.md#admissioncontrol-plugin-resourcequota", + "hard": "Hard is the set of enforced hard limits for each named resource. More info: https://git.k8s.io/community/contributors/design-proposals/admission_control_resource_quota.md", "used": "Used is the current observed total usage of the resource in the namespace.", } @@ -1557,8 +1659,8 @@ func (ResourceQuotaStatus) SwaggerDoc() map[string]string { var map_ResourceRequirements = map[string]string{ "": "ResourceRequirements describes the compute resource requirements.", - "limits": "Limits describes the maximum amount of compute resources allowed. More info: http://kubernetes.io/docs/user-guide/compute-resources/", - "requests": "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: http://kubernetes.io/docs/user-guide/compute-resources/", + "limits": "Limits describes the maximum amount of compute resources allowed. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/", + "requests": "Requests describes the minimum amount of compute resources required. If Requests is omitted for a container, it defaults to Limits if that is explicitly specified, otherwise to an implementation-defined value. More info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/", } func (ResourceRequirements) SwaggerDoc() map[string]string { @@ -1577,10 +1679,28 @@ func (SELinuxOptions) SwaggerDoc() map[string]string { return map_SELinuxOptions } +var map_ScaleIOVolumeSource = map[string]string{ + "": "ScaleIOVolumeSource represents a persistent ScaleIO volume", + "gateway": "The host address of the ScaleIO API Gateway.", + "system": "The name of the storage system as configured in ScaleIO.", + "secretRef": "SecretRef references to the secret for ScaleIO user and other sensitive information. If this is not provided, Login operation will fail.", + "sslEnabled": "Flag to enable/disable SSL communication with Gateway, default false", + "protectionDomain": "The name of the Protection Domain for the configured storage (defaults to \"default\").", + "storagePool": "The Storage Pool associated with the protection domain (defaults to \"default\").", + "storageMode": "Indicates whether the storage for a volume should be thick or thin (defaults to \"thin\").", + "volumeName": "The name of a volume already created in the ScaleIO system that is associated with this volume source.", + "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + "readOnly": "Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", +} + +func (ScaleIOVolumeSource) SwaggerDoc() map[string]string { + return map_ScaleIOVolumeSource +} + var map_Secret = map[string]string{ "": "Secret holds secret data of a certain type. The total bytes of the values in the Data field must be less than MaxSecretSize bytes.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "data": "Data contains the secret data. Each key must be a valid DNS_SUBDOMAIN or leading dot followed by valid DNS_SUBDOMAIN. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "data": "Data contains the secret data. Each key must consist of alphanumeric characters, '-', '_' or '.'. The serialized form of the secret data is a base64 encoded string, representing the arbitrary (possibly non-string) data value here. Described in https://tools.ietf.org/html/rfc4648#section-4", "stringData": "stringData allows specifying non-binary secret data in string form. It is provided as a write-only convenience method. All keys and values are merged into the data field on write, overwriting any existing values. It is never output when reading from the API.", "type": "Used to facilitate programmatic handling of secret data.", } @@ -1589,9 +1709,19 @@ func (Secret) SwaggerDoc() map[string]string { return map_Secret } +var map_SecretEnvSource = map[string]string{ + "": "SecretEnvSource selects a Secret to populate the environment variables with.\n\nThe contents of the target Secret's Data field will represent the key-value pairs as environment variables.", + "optional": "Specify whether the Secret must be defined", +} + +func (SecretEnvSource) SwaggerDoc() map[string]string { + return map_SecretEnvSource +} + var map_SecretKeySelector = map[string]string{ - "": "SecretKeySelector selects a key of a Secret.", - "key": "The key of the secret to select from. Must be a valid secret key.", + "": "SecretKeySelector selects a key of a Secret.", + "key": "The key of the secret to select from. Must be a valid secret key.", + "optional": "Specify whether the Secret or it's key must be defined", } func (SecretKeySelector) SwaggerDoc() map[string]string { @@ -1600,19 +1730,30 @@ func (SecretKeySelector) SwaggerDoc() map[string]string { var map_SecretList = map[string]string{ "": "SecretList is a list of Secret.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "Items is a list of secret objects. More info: http://kubernetes.io/docs/user-guide/secrets", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "Items is a list of secret objects. More info: https://kubernetes.io/docs/concepts/configuration/secret", } func (SecretList) SwaggerDoc() map[string]string { return map_SecretList } +var map_SecretProjection = map[string]string{ + "": "Adapts a secret into a projected volume.\n\nThe contents of the target Secret's Data field will be presented in a projected volume as files using the keys in the Data field as the file names. Note that this is identical to a secret volume source without the default mode.", + "items": "If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", + "optional": "Specify whether the Secret or its key must be defined", +} + +func (SecretProjection) SwaggerDoc() map[string]string { + return map_SecretProjection +} + var map_SecretVolumeSource = map[string]string{ "": "Adapts a Secret into a volume.\n\nThe contents of the target Secret's Data field will be presented in a volume as files using the keys in the Data field as the file names. Secret volumes support ownership management and SELinux relabeling.", - "secretName": "Name of the secret in the pod's namespace to use. More info: http://kubernetes.io/docs/user-guide/volumes#secrets", - "items": "If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error. Paths must be relative and may not contain the '..' path or start with '..'.", + "secretName": "Name of the secret in the pod's namespace to use. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", + "items": "If unspecified, each key-value pair in the Data field of the referenced Secret will be projected into the volume as a file whose name is the key and content is the value. If specified, the listed keys will be projected into the specified paths, and unlisted keys will not be present. If a key is specified which is not present in the Secret, the volume setup will error unless it is marked optional. Paths must be relative and may not contain the '..' path or start with '..'.", "defaultMode": "Optional: mode bits to use on created files by default. Must be a value between 0 and 0777. Defaults to 0644. Directories within the path are not affected by this setting. This might be in conflict with other options that affect the file mode, like fsGroup, and the result can be other mode bits set.", + "optional": "Specify whether the Secret or it's keys must be defined", } func (SecretVolumeSource) SwaggerDoc() map[string]string { @@ -1644,9 +1785,9 @@ func (SerializedReference) SwaggerDoc() map[string]string { var map_Service = map[string]string{ "": "Service is a named abstraction of software service (for example, mysql) consisting of local port (for example 3306) that the proxy listens on, and the selector that determines which pods will answer requests sent through the proxy.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the behavior of a service. http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Most recently observed status of the service. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the behavior of a service. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Most recently observed status of the service. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (Service) SwaggerDoc() map[string]string { @@ -1654,10 +1795,11 @@ func (Service) SwaggerDoc() map[string]string { } var map_ServiceAccount = map[string]string{ - "": "ServiceAccount binds together: * a name, understood by users, and perhaps by peripheral systems, for an identity * a principal that can be authenticated and authorized * a set of secrets", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "secrets": "Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount. More info: http://kubernetes.io/docs/user-guide/secrets", - "imagePullSecrets": "ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. More info: http://kubernetes.io/docs/user-guide/secrets#manually-specifying-an-imagepullsecret", + "": "ServiceAccount binds together: * a name, understood by users, and perhaps by peripheral systems, for an identity * a principal that can be authenticated and authorized * a set of secrets", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "secrets": "Secrets is the list of secrets allowed to be used by pods running using this ServiceAccount. More info: https://kubernetes.io/docs/concepts/configuration/secret", + "imagePullSecrets": "ImagePullSecrets is a list of references to secrets in the same namespace to use for pulling any images in pods that reference this ServiceAccount. ImagePullSecrets are distinct from Secrets because Secrets can be mounted in the pod, but ImagePullSecrets are only accessed by the kubelet. More info: https://kubernetes.io/docs/concepts/containers/images/#specifying-imagepullsecrets-on-a-pod", + "automountServiceAccountToken": "AutomountServiceAccountToken indicates whether pods running as this service account should have an API token automatically mounted. Can be overridden at the pod level.", } func (ServiceAccount) SwaggerDoc() map[string]string { @@ -1666,8 +1808,8 @@ func (ServiceAccount) SwaggerDoc() map[string]string { var map_ServiceAccountList = map[string]string{ "": "ServiceAccountList is a list of ServiceAccount objects", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "List of ServiceAccounts. More info: http://releases.k8s.io/HEAD/docs/design/service_accounts.md#service-accounts", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of ServiceAccounts. More info: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/", } func (ServiceAccountList) SwaggerDoc() map[string]string { @@ -1676,7 +1818,7 @@ func (ServiceAccountList) SwaggerDoc() map[string]string { var map_ServiceList = map[string]string{ "": "ServiceList holds a list of services.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", "items": "List of services", } @@ -1689,8 +1831,8 @@ var map_ServicePort = map[string]string{ "name": "The name of this port within the service. This must be a DNS_LABEL. All ports within a ServiceSpec must have unique names. This maps to the 'Name' field in EndpointPort objects. Optional if only one ServicePort is defined on this service.", "protocol": "The IP protocol for this port. Supports \"TCP\" and \"UDP\". Default is TCP.", "port": "The port that will be exposed by this service.", - "targetPort": "Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: http://kubernetes.io/docs/user-guide/services#defining-a-service", - "nodePort": "The port on each node on which this service is exposed when type=NodePort or LoadBalancer. Usually assigned by the system. If specified, it will be allocated to the service if unused or else creation of the service will fail. Default is to auto-allocate a port if the ServiceType of this Service requires one. More info: http://kubernetes.io/docs/user-guide/services#type--nodeport", + "targetPort": "Number or name of the port to access on the pods targeted by the service. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME. If this is a string, it will be looked up as a named port in the target Pod's container ports. If this is not specified, the value of the 'port' field is used (an identity map). This field is ignored for services with clusterIP=None, and should be omitted or set equal to the 'port' field. More info: https://kubernetes.io/docs/concepts/services-networking/service/#defining-a-service", + "nodePort": "The port on each node on which this service is exposed when type=NodePort or LoadBalancer. Usually assigned by the system. If specified, it will be allocated to the service if unused or else creation of the service will fail. Default is to auto-allocate a port if the ServiceType of this Service requires one. More info: https://kubernetes.io/docs/concepts/services-networking/service/#type-nodeport", } func (ServicePort) SwaggerDoc() map[string]string { @@ -1708,16 +1850,17 @@ func (ServiceProxyOptions) SwaggerDoc() map[string]string { var map_ServiceSpec = map[string]string{ "": "ServiceSpec describes the attributes that a user creates on a service.", - "ports": "The list of ports that are exposed by this service. More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies", - "selector": "Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: http://kubernetes.io/docs/user-guide/services#overview", - "clusterIP": "clusterIP is the IP address of the service and is usually assigned randomly by the master. If an address is specified manually and is not in use by others, it will be allocated to the service; otherwise, creation of the service will fail. This field can not be changed through updates. Valid values are \"None\", empty string (\"\"), or a valid IP address. \"None\" can be specified for headless services when proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies", - "type": "type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. \"ExternalName\" maps to the specified externalName. \"ClusterIP\" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object. If clusterIP is \"None\", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a stable IP. \"NodePort\" builds on ClusterIP and allocates a port on every node which routes to the clusterIP. \"LoadBalancer\" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the clusterIP. More info: http://kubernetes.io/docs/user-guide/services#overview", - "externalIPs": "externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system. A previous form of this functionality exists as the deprecatedPublicIPs field. When using this field, callers should also clear the deprecatedPublicIPs field.", - "deprecatedPublicIPs": "deprecatedPublicIPs is deprecated and replaced by the externalIPs field with almost the exact same semantics. This field is retained in the v1 API for compatibility until at least 8/20/2016. It will be removed from any new API revisions. If both deprecatedPublicIPs *and* externalIPs are set, deprecatedPublicIPs is used.", - "sessionAffinity": "Supports \"ClientIP\" and \"None\". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: http://kubernetes.io/docs/user-guide/services#virtual-ips-and-service-proxies", + "ports": "The list of ports that are exposed by this service. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", + "selector": "Route service traffic to pods with label keys and values matching this selector. If empty or not present, the service is assumed to have an external process managing its endpoints, which Kubernetes will not modify. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/", + "clusterIP": "clusterIP is the IP address of the service and is usually assigned randomly by the master. If an address is specified manually and is not in use by others, it will be allocated to the service; otherwise, creation of the service will fail. This field can not be changed through updates. Valid values are \"None\", empty string (\"\"), or a valid IP address. \"None\" can be specified for headless services when proxying is not required. Only applies to types ClusterIP, NodePort, and LoadBalancer. Ignored if type is ExternalName. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", + "type": "type determines how the Service is exposed. Defaults to ClusterIP. Valid options are ExternalName, ClusterIP, NodePort, and LoadBalancer. \"ExternalName\" maps to the specified externalName. \"ClusterIP\" allocates a cluster-internal IP address for load-balancing to endpoints. Endpoints are determined by the selector or if that is not specified, by manual construction of an Endpoints object. If clusterIP is \"None\", no virtual IP is allocated and the endpoints are published as a set of endpoints rather than a stable IP. \"NodePort\" builds on ClusterIP and allocates a port on every node which routes to the clusterIP. \"LoadBalancer\" builds on NodePort and creates an external load-balancer (if supported in the current cloud) which routes to the clusterIP. More info: https://kubernetes.io/docs/concepts/services-networking/service/#publishing-services ", + "externalIPs": "externalIPs is a list of IP addresses for which nodes in the cluster will also accept traffic for this service. These IPs are not managed by Kubernetes. The user is responsible for ensuring that traffic arrives at a node with this IP. A common example is external load-balancers that are not part of the Kubernetes system.", + "sessionAffinity": "Supports \"ClientIP\" and \"None\". Used to maintain session affinity. Enable client IP based session affinity. Must be ClientIP or None. Defaults to None. More info: https://kubernetes.io/docs/concepts/services-networking/service/#virtual-ips-and-service-proxies", "loadBalancerIP": "Only applies to Service Type: LoadBalancer LoadBalancer will get created with the IP specified in this field. This feature depends on whether the underlying cloud-provider supports specifying the loadBalancerIP when a load balancer is created. This field will be ignored if the cloud-provider does not support the feature.", - "loadBalancerSourceRanges": "If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature.\" More info: http://kubernetes.io/docs/user-guide/services-firewalls", + "loadBalancerSourceRanges": "If specified and supported by the platform, this will restrict traffic through the cloud-provider load-balancer will be restricted to the specified client IPs. This field will be ignored if the cloud-provider does not support the feature.\" More info: https://kubernetes.io/docs/tasks/access-application-cluster/configure-cloud-provider-firewall/", "externalName": "externalName is the external reference that kubedns or equivalent will return as a CNAME record for this service. No proxying will be involved. Must be a valid DNS name and requires Type to be ExternalName.", + "externalTrafficPolicy": "externalTrafficPolicy denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints. \"Local\" preserves the client source IP and avoids a second hop for LoadBalancer and Nodeport type services, but risks potentially imbalanced traffic spreading. \"Cluster\" obscures the client source IP and may cause a second hop to another node, but should have good overall load-spreading.", + "healthCheckNodePort": "healthCheckNodePort specifies the healthcheck nodePort for the service. If not specified, HealthCheckNodePort is created by the service api backend with the allocated nodePort. Will use user-specified nodePort value if specified by the client. Only effects when Type is set to LoadBalancer and ExternalTrafficPolicy is set to Local.", } func (ServiceSpec) SwaggerDoc() map[string]string { @@ -1733,9 +1876,46 @@ func (ServiceStatus) SwaggerDoc() map[string]string { return map_ServiceStatus } +var map_StorageOSPersistentVolumeSource = map[string]string{ + "": "Represents a StorageOS persistent volume resource.", + "volumeName": "VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.", + "volumeNamespace": "VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to \"default\" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created.", + "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + "readOnly": "Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + "secretRef": "SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", +} + +func (StorageOSPersistentVolumeSource) SwaggerDoc() map[string]string { + return map_StorageOSPersistentVolumeSource +} + +var map_StorageOSVolumeSource = map[string]string{ + "": "Represents a StorageOS persistent volume resource.", + "volumeName": "VolumeName is the human-readable name of the StorageOS volume. Volume names are only unique within a namespace.", + "volumeNamespace": "VolumeNamespace specifies the scope of the volume within StorageOS. If no namespace is specified then the Pod's namespace will be used. This allows the Kubernetes name scoping to be mirrored within StorageOS for tighter integration. Set VolumeName to any name to override the default behaviour. Set to \"default\" if you are not using namespaces within StorageOS. Namespaces that do not pre-exist within StorageOS will be created.", + "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + "readOnly": "Defaults to false (read/write). ReadOnly here will force the ReadOnly setting in VolumeMounts.", + "secretRef": "SecretRef specifies the secret to use for obtaining the StorageOS API credentials. If not specified, default values will be attempted.", +} + +func (StorageOSVolumeSource) SwaggerDoc() map[string]string { + return map_StorageOSVolumeSource +} + +var map_Sysctl = map[string]string{ + "": "Sysctl defines a kernel parameter to be set", + "Name": "Name of a property to set", + "Value": "Value of a property to set", +} + +func (Sysctl) SwaggerDoc() map[string]string { + return map_Sysctl +} + var map_TCPSocketAction = map[string]string{ "": "TCPSocketAction describes an action based on opening a socket", "port": "Number or name of the port to access on the container. Number must be in the range 1 to 65535. Name must be an IANA_SVC_NAME.", + "host": "Optional: Host name to connect to, defaults to the pod IP.", } func (TCPSocketAction) SwaggerDoc() map[string]string { @@ -1743,10 +1923,11 @@ func (TCPSocketAction) SwaggerDoc() map[string]string { } var map_Taint = map[string]string{ - "": "The node this Taint is attached to has the effect \"effect\" on any pod that that does not tolerate the Taint.", - "key": "Required. The taint key to be applied to a node.", - "value": "Required. The taint value corresponding to the taint key.", - "effect": "Required. The effect of the taint on pods that do not tolerate the taint. Valid effects are NoSchedule and PreferNoSchedule.", + "": "The node this Taint is attached to has the effect \"effect\" on any pod that that does not tolerate the Taint.", + "key": "Required. The taint key to be applied to a node.", + "value": "Required. The taint value corresponding to the taint key.", + "effect": "Required. The effect of the taint on pods that do not tolerate the taint. Valid effects are NoSchedule, PreferNoSchedule and NoExecute.", + "timeAdded": "TimeAdded represents the time at which the taint was added. It is only written for NoExecute taints.", } func (Taint) SwaggerDoc() map[string]string { @@ -1754,11 +1935,12 @@ func (Taint) SwaggerDoc() map[string]string { } var map_Toleration = map[string]string{ - "": "The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator .", - "key": "Required. Key is the taint key that the toleration applies to.", - "operator": "operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category.", - "value": "Value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string.", - "effect": "Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule and PreferNoSchedule.", + "": "The pod this Toleration is attached to tolerates any taint that matches the triple using the matching operator .", + "key": "Key is the taint key that the toleration applies to. Empty means match all taint keys. If the key is empty, operator must be Exists; this combination means to match all values and all keys.", + "operator": "Operator represents a key's relationship to the value. Valid operators are Exists and Equal. Defaults to Equal. Exists is equivalent to wildcard for value, so that a pod can tolerate all taints of a particular category.", + "value": "Value is the taint value the toleration matches to. If the operator is Exists, the value should be empty, otherwise just a regular string.", + "effect": "Effect indicates the taint effect to match. Empty means match all taint effects. When specified, allowed values are NoSchedule, PreferNoSchedule and NoExecute.", + "tolerationSeconds": "TolerationSeconds represents the period of time the toleration (which must be of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default, it is not set, which means tolerate the taint forever (do not evict). Zero and negative values will be treated as 0 (evict immediately) by the system.", } func (Toleration) SwaggerDoc() map[string]string { @@ -1767,7 +1949,7 @@ func (Toleration) SwaggerDoc() map[string]string { var map_Volume = map[string]string{ "": "Volume represents a named volume in a pod that may be accessed by any container in the pod.", - "name": "Volume's name. Must be a DNS_LABEL and unique within the pod. More info: http://kubernetes.io/docs/user-guide/identifiers#names", + "name": "Volume's name. Must be a DNS_LABEL and unique within the pod. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names", } func (Volume) SwaggerDoc() map[string]string { @@ -1786,21 +1968,32 @@ func (VolumeMount) SwaggerDoc() map[string]string { return map_VolumeMount } +var map_VolumeProjection = map[string]string{ + "": "Projection that may be projected along with other supported volume types", + "secret": "information about the secret data to project", + "downwardAPI": "information about the downwardAPI data to project", + "configMap": "information about the configMap data to project", +} + +func (VolumeProjection) SwaggerDoc() map[string]string { + return map_VolumeProjection +} + var map_VolumeSource = map[string]string{ "": "Represents the source of a volume to mount. Only one of its members may be specified.", - "hostPath": "HostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: http://kubernetes.io/docs/user-guide/volumes#hostpath", - "emptyDir": "EmptyDir represents a temporary directory that shares a pod's lifetime. More info: http://kubernetes.io/docs/user-guide/volumes#emptydir", - "gcePersistentDisk": "GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://kubernetes.io/docs/user-guide/volumes#gcepersistentdisk", - "awsElasticBlockStore": "AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://kubernetes.io/docs/user-guide/volumes#awselasticblockstore", + "hostPath": "HostPath represents a pre-existing file or directory on the host machine that is directly exposed to the container. This is generally used for system agents or other privileged things that are allowed to see the host machine. Most containers will NOT need this. More info: https://kubernetes.io/docs/concepts/storage/volumes#hostpath", + "emptyDir": "EmptyDir represents a temporary directory that shares a pod's lifetime. More info: https://kubernetes.io/docs/concepts/storage/volumes#emptydir", + "gcePersistentDisk": "GCEPersistentDisk represents a GCE Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#gcepersistentdisk", + "awsElasticBlockStore": "AWSElasticBlockStore represents an AWS Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://kubernetes.io/docs/concepts/storage/volumes#awselasticblockstore", "gitRepo": "GitRepo represents a git repository at a particular revision.", - "secret": "Secret represents a secret that should populate this volume. More info: http://kubernetes.io/docs/user-guide/volumes#secrets", - "nfs": "NFS represents an NFS mount on the host that shares a pod's lifetime More info: http://kubernetes.io/docs/user-guide/volumes#nfs", - "iscsi": "ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: http://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md", - "glusterfs": "Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md", - "persistentVolumeClaim": "PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: http://kubernetes.io/docs/user-guide/persistent-volumes#persistentvolumeclaims", - "rbd": "RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: http://releases.k8s.io/HEAD/examples/volumes/rbd/README.md", + "secret": "Secret represents a secret that should populate this volume. More info: https://kubernetes.io/docs/concepts/storage/volumes#secret", + "nfs": "NFS represents an NFS mount on the host that shares a pod's lifetime More info: https://kubernetes.io/docs/concepts/storage/volumes#nfs", + "iscsi": "ISCSI represents an ISCSI Disk resource that is attached to a kubelet's host machine and then exposed to the pod. More info: https://releases.k8s.io/HEAD/examples/volumes/iscsi/README.md", + "glusterfs": "Glusterfs represents a Glusterfs mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/glusterfs/README.md", + "persistentVolumeClaim": "PersistentVolumeClaimVolumeSource represents a reference to a PersistentVolumeClaim in the same namespace. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#persistentvolumeclaims", + "rbd": "RBD represents a Rados Block Device mount on the host that shares a pod's lifetime. More info: https://releases.k8s.io/HEAD/examples/volumes/rbd/README.md", "flexVolume": "FlexVolume represents a generic volume resource that is provisioned/attached using an exec based plugin. This is an alpha feature and may change in future.", - "cinder": "Cinder represents a cinder volume attached and mounted on kubelets host machine More info: http://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", + "cinder": "Cinder represents a cinder volume attached and mounted on kubelets host machine More info: https://releases.k8s.io/HEAD/examples/mysql-cinder-pd/README.md", "cephfs": "CephFS represents a Ceph FS mount on the host that shares a pod's lifetime", "flocker": "Flocker represents a Flocker volume attached to a kubelet's host machine. This depends on the Flocker control service being running", "downwardAPI": "DownwardAPI represents downward API about the pod that should populate this volume", @@ -1811,6 +2004,10 @@ var map_VolumeSource = map[string]string{ "quobyte": "Quobyte represents a Quobyte mount on the host that shares a pod's lifetime", "azureDisk": "AzureDisk represents an Azure Data Disk mount on the host and bind mount to the pod.", "photonPersistentDisk": "PhotonPersistentDisk represents a PhotonController persistent disk attached and mounted on kubelets host machine", + "projected": "Items for all in one resources secrets, configmaps, and downward API", + "portworxVolume": "PortworxVolume represents a portworx volume attached and mounted on kubelets host machine", + "scaleIO": "ScaleIO represents a ScaleIO persistent volume attached and mounted on Kubernetes nodes.", + "storageos": "StorageOS represents a StorageOS volume attached and mounted on Kubernetes nodes.", } func (VolumeSource) SwaggerDoc() map[string]string { @@ -1818,9 +2015,11 @@ func (VolumeSource) SwaggerDoc() map[string]string { } var map_VsphereVirtualDiskVolumeSource = map[string]string{ - "": "Represents a vSphere volume resource.", - "volumePath": "Path that identifies vSphere volume vmdk", - "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + "": "Represents a vSphere volume resource.", + "volumePath": "Path that identifies vSphere volume vmdk", + "fsType": "Filesystem type to mount. Must be a filesystem type supported by the host operating system. Ex. \"ext4\", \"xfs\", \"ntfs\". Implicitly inferred to be \"ext4\" if unspecified.", + "storagePolicyName": "Storage Policy Based Management (SPBM) profile name.", + "storagePolicyID": "Storage Policy Based Management (SPBM) profile ID associated with the StoragePolicyName.", } func (VsphereVirtualDiskVolumeSource) SwaggerDoc() map[string]string { diff --git a/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go index 35fe2e2c27..1832c432bc 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,11 +21,11 @@ limitations under the License. package v1 import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + types "k8s.io/apimachinery/pkg/types" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - types "k8s.io/client-go/pkg/types" unsafe "unsafe" ) @@ -65,10 +65,14 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_ComponentStatusList_To_v1_ComponentStatusList, Convert_v1_ConfigMap_To_api_ConfigMap, Convert_api_ConfigMap_To_v1_ConfigMap, + Convert_v1_ConfigMapEnvSource_To_api_ConfigMapEnvSource, + Convert_api_ConfigMapEnvSource_To_v1_ConfigMapEnvSource, Convert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector, Convert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector, Convert_v1_ConfigMapList_To_api_ConfigMapList, Convert_api_ConfigMapList_To_v1_ConfigMapList, + Convert_v1_ConfigMapProjection_To_api_ConfigMapProjection, + Convert_api_ConfigMapProjection_To_v1_ConfigMapProjection, Convert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource, Convert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource, Convert_v1_Container_To_api_Container, @@ -91,6 +95,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_DaemonEndpoint_To_v1_DaemonEndpoint, Convert_v1_DeleteOptions_To_api_DeleteOptions, Convert_api_DeleteOptions_To_v1_DeleteOptions, + Convert_v1_DownwardAPIProjection_To_api_DownwardAPIProjection, + Convert_api_DownwardAPIProjection_To_v1_DownwardAPIProjection, Convert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile, Convert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile, Convert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource, @@ -107,6 +113,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_Endpoints_To_v1_Endpoints, Convert_v1_EndpointsList_To_api_EndpointsList, Convert_api_EndpointsList_To_v1_EndpointsList, + Convert_v1_EnvFromSource_To_api_EnvFromSource, + Convert_api_EnvFromSource_To_v1_EnvFromSource, Convert_v1_EnvVar_To_api_EnvVar, Convert_api_EnvVar_To_v1_EnvVar, Convert_v1_EnvVarSource_To_api_EnvVarSource, @@ -119,8 +127,6 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_EventSource_To_v1_EventSource, Convert_v1_ExecAction_To_api_ExecAction, Convert_api_ExecAction_To_v1_ExecAction, - Convert_v1_ExportOptions_To_api_ExportOptions, - Convert_api_ExportOptions_To_v1_ExportOptions, Convert_v1_FCVolumeSource_To_api_FCVolumeSource, Convert_api_FCVolumeSource_To_v1_FCVolumeSource, Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource, @@ -139,6 +145,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_HTTPHeader_To_v1_HTTPHeader, Convert_v1_Handler_To_api_Handler, Convert_api_Handler_To_v1_Handler, + Convert_v1_HostAlias_To_api_HostAlias, + Convert_api_HostAlias_To_v1_HostAlias, Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource, Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource, Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource, @@ -165,6 +173,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus, Convert_v1_LocalObjectReference_To_api_LocalObjectReference, Convert_api_LocalObjectReference_To_v1_LocalObjectReference, + Convert_v1_LocalVolumeSource_To_api_LocalVolumeSource, + Convert_api_LocalVolumeSource_To_v1_LocalVolumeSource, Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource, Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource, Convert_v1_Namespace_To_api_Namespace, @@ -189,6 +199,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_NodeList_To_v1_NodeList, Convert_v1_NodeProxyOptions_To_api_NodeProxyOptions, Convert_api_NodeProxyOptions_To_v1_NodeProxyOptions, + Convert_v1_NodeResources_To_api_NodeResources, + Convert_api_NodeResources_To_v1_NodeResources, Convert_v1_NodeSelector_To_api_NodeSelector, Convert_api_NodeSelector_To_v1_NodeSelector, Convert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement, @@ -207,8 +219,6 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_ObjectMeta_To_v1_ObjectMeta, Convert_v1_ObjectReference_To_api_ObjectReference, Convert_api_ObjectReference_To_v1_ObjectReference, - Convert_v1_OwnerReference_To_api_OwnerReference, - Convert_api_OwnerReference_To_v1_OwnerReference, Convert_v1_PersistentVolume_To_api_PersistentVolume, Convert_api_PersistentVolume_To_v1_PersistentVolume, Convert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim, @@ -249,6 +259,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_PodList_To_v1_PodList, Convert_v1_PodLogOptions_To_api_PodLogOptions, Convert_api_PodLogOptions_To_v1_PodLogOptions, + Convert_v1_PodPortForwardOptions_To_api_PodPortForwardOptions, + Convert_api_PodPortForwardOptions_To_v1_PodPortForwardOptions, Convert_v1_PodProxyOptions_To_api_PodProxyOptions, Convert_api_PodProxyOptions_To_v1_PodProxyOptions, Convert_v1_PodSecurityContext_To_api_PodSecurityContext, @@ -267,6 +279,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_PodTemplateList_To_v1_PodTemplateList, Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec, Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec, + Convert_v1_PortworxVolumeSource_To_api_PortworxVolumeSource, + Convert_api_PortworxVolumeSource_To_v1_PortworxVolumeSource, Convert_v1_Preconditions_To_api_Preconditions, Convert_api_Preconditions_To_v1_Preconditions, Convert_v1_PreferAvoidPodsEntry_To_api_PreferAvoidPodsEntry, @@ -275,6 +289,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm, Convert_v1_Probe_To_api_Probe, Convert_api_Probe_To_v1_Probe, + Convert_v1_ProjectedVolumeSource_To_api_ProjectedVolumeSource, + Convert_api_ProjectedVolumeSource_To_v1_ProjectedVolumeSource, Convert_v1_QuobyteVolumeSource_To_api_QuobyteVolumeSource, Convert_api_QuobyteVolumeSource_To_v1_QuobyteVolumeSource, Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource, @@ -305,12 +321,18 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_ResourceRequirements_To_v1_ResourceRequirements, Convert_v1_SELinuxOptions_To_api_SELinuxOptions, Convert_api_SELinuxOptions_To_v1_SELinuxOptions, + Convert_v1_ScaleIOVolumeSource_To_api_ScaleIOVolumeSource, + Convert_api_ScaleIOVolumeSource_To_v1_ScaleIOVolumeSource, Convert_v1_Secret_To_api_Secret, Convert_api_Secret_To_v1_Secret, + Convert_v1_SecretEnvSource_To_api_SecretEnvSource, + Convert_api_SecretEnvSource_To_v1_SecretEnvSource, Convert_v1_SecretKeySelector_To_api_SecretKeySelector, Convert_api_SecretKeySelector_To_v1_SecretKeySelector, Convert_v1_SecretList_To_api_SecretList, Convert_api_SecretList_To_v1_SecretList, + Convert_v1_SecretProjection_To_api_SecretProjection, + Convert_api_SecretProjection_To_v1_SecretProjection, Convert_v1_SecretVolumeSource_To_api_SecretVolumeSource, Convert_api_SecretVolumeSource_To_v1_SecretVolumeSource, Convert_v1_SecurityContext_To_api_SecurityContext, @@ -333,6 +355,12 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_ServiceSpec_To_v1_ServiceSpec, Convert_v1_ServiceStatus_To_api_ServiceStatus, Convert_api_ServiceStatus_To_v1_ServiceStatus, + Convert_v1_StorageOSPersistentVolumeSource_To_api_StorageOSPersistentVolumeSource, + Convert_api_StorageOSPersistentVolumeSource_To_v1_StorageOSPersistentVolumeSource, + Convert_v1_StorageOSVolumeSource_To_api_StorageOSVolumeSource, + Convert_api_StorageOSVolumeSource_To_v1_StorageOSVolumeSource, + Convert_v1_Sysctl_To_api_Sysctl, + Convert_api_Sysctl_To_v1_Sysctl, Convert_v1_TCPSocketAction_To_api_TCPSocketAction, Convert_api_TCPSocketAction_To_v1_TCPSocketAction, Convert_v1_Taint_To_api_Taint, @@ -343,6 +371,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_api_Volume_To_v1_Volume, Convert_v1_VolumeMount_To_api_VolumeMount, Convert_api_VolumeMount_To_v1_VolumeMount, + Convert_v1_VolumeProjection_To_api_VolumeProjection, + Convert_api_VolumeProjection_To_v1_VolumeProjection, Convert_v1_VolumeSource_To_api_VolumeSource, Convert_api_VolumeSource_To_v1_VolumeSource, Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource, @@ -360,6 +390,7 @@ func autoConvert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStore return nil } +// Convert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource is an autogenerated conversion function. func Convert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(in *AWSElasticBlockStoreVolumeSource, out *api.AWSElasticBlockStoreVolumeSource, s conversion.Scope) error { return autoConvert_v1_AWSElasticBlockStoreVolumeSource_To_api_AWSElasticBlockStoreVolumeSource(in, out, s) } @@ -372,6 +403,7 @@ func autoConvert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStore return nil } +// Convert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource is an autogenerated conversion function. func Convert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(in *api.AWSElasticBlockStoreVolumeSource, out *AWSElasticBlockStoreVolumeSource, s conversion.Scope) error { return autoConvert_api_AWSElasticBlockStoreVolumeSource_To_v1_AWSElasticBlockStoreVolumeSource(in, out, s) } @@ -383,6 +415,7 @@ func autoConvert_v1_Affinity_To_api_Affinity(in *Affinity, out *api.Affinity, s return nil } +// Convert_v1_Affinity_To_api_Affinity is an autogenerated conversion function. func Convert_v1_Affinity_To_api_Affinity(in *Affinity, out *api.Affinity, s conversion.Scope) error { return autoConvert_v1_Affinity_To_api_Affinity(in, out, s) } @@ -394,6 +427,7 @@ func autoConvert_api_Affinity_To_v1_Affinity(in *api.Affinity, out *Affinity, s return nil } +// Convert_api_Affinity_To_v1_Affinity is an autogenerated conversion function. func Convert_api_Affinity_To_v1_Affinity(in *api.Affinity, out *Affinity, s conversion.Scope) error { return autoConvert_api_Affinity_To_v1_Affinity(in, out, s) } @@ -404,6 +438,7 @@ func autoConvert_v1_AttachedVolume_To_api_AttachedVolume(in *AttachedVolume, out return nil } +// Convert_v1_AttachedVolume_To_api_AttachedVolume is an autogenerated conversion function. func Convert_v1_AttachedVolume_To_api_AttachedVolume(in *AttachedVolume, out *api.AttachedVolume, s conversion.Scope) error { return autoConvert_v1_AttachedVolume_To_api_AttachedVolume(in, out, s) } @@ -414,6 +449,7 @@ func autoConvert_api_AttachedVolume_To_v1_AttachedVolume(in *api.AttachedVolume, return nil } +// Convert_api_AttachedVolume_To_v1_AttachedVolume is an autogenerated conversion function. func Convert_api_AttachedVolume_To_v1_AttachedVolume(in *api.AttachedVolume, out *AttachedVolume, s conversion.Scope) error { return autoConvert_api_AttachedVolume_To_v1_AttachedVolume(in, out, s) } @@ -423,6 +459,7 @@ func autoConvert_v1_AvoidPods_To_api_AvoidPods(in *AvoidPods, out *api.AvoidPods return nil } +// Convert_v1_AvoidPods_To_api_AvoidPods is an autogenerated conversion function. func Convert_v1_AvoidPods_To_api_AvoidPods(in *AvoidPods, out *api.AvoidPods, s conversion.Scope) error { return autoConvert_v1_AvoidPods_To_api_AvoidPods(in, out, s) } @@ -432,6 +469,7 @@ func autoConvert_api_AvoidPods_To_v1_AvoidPods(in *api.AvoidPods, out *AvoidPods return nil } +// Convert_api_AvoidPods_To_v1_AvoidPods is an autogenerated conversion function. func Convert_api_AvoidPods_To_v1_AvoidPods(in *api.AvoidPods, out *AvoidPods, s conversion.Scope) error { return autoConvert_api_AvoidPods_To_v1_AvoidPods(in, out, s) } @@ -442,9 +480,11 @@ func autoConvert_v1_AzureDiskVolumeSource_To_api_AzureDiskVolumeSource(in *Azure out.CachingMode = (*api.AzureDataDiskCachingMode)(unsafe.Pointer(in.CachingMode)) out.FSType = (*string)(unsafe.Pointer(in.FSType)) out.ReadOnly = (*bool)(unsafe.Pointer(in.ReadOnly)) + out.Kind = (*api.AzureDataDiskKind)(unsafe.Pointer(in.Kind)) return nil } +// Convert_v1_AzureDiskVolumeSource_To_api_AzureDiskVolumeSource is an autogenerated conversion function. func Convert_v1_AzureDiskVolumeSource_To_api_AzureDiskVolumeSource(in *AzureDiskVolumeSource, out *api.AzureDiskVolumeSource, s conversion.Scope) error { return autoConvert_v1_AzureDiskVolumeSource_To_api_AzureDiskVolumeSource(in, out, s) } @@ -455,9 +495,11 @@ func autoConvert_api_AzureDiskVolumeSource_To_v1_AzureDiskVolumeSource(in *api.A out.CachingMode = (*AzureDataDiskCachingMode)(unsafe.Pointer(in.CachingMode)) out.FSType = (*string)(unsafe.Pointer(in.FSType)) out.ReadOnly = (*bool)(unsafe.Pointer(in.ReadOnly)) + out.Kind = (*AzureDataDiskKind)(unsafe.Pointer(in.Kind)) return nil } +// Convert_api_AzureDiskVolumeSource_To_v1_AzureDiskVolumeSource is an autogenerated conversion function. func Convert_api_AzureDiskVolumeSource_To_v1_AzureDiskVolumeSource(in *api.AzureDiskVolumeSource, out *AzureDiskVolumeSource, s conversion.Scope) error { return autoConvert_api_AzureDiskVolumeSource_To_v1_AzureDiskVolumeSource(in, out, s) } @@ -469,6 +511,7 @@ func autoConvert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(in *Azure return nil } +// Convert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource is an autogenerated conversion function. func Convert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(in *AzureFileVolumeSource, out *api.AzureFileVolumeSource, s conversion.Scope) error { return autoConvert_v1_AzureFileVolumeSource_To_api_AzureFileVolumeSource(in, out, s) } @@ -480,34 +523,33 @@ func autoConvert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(in *api.A return nil } +// Convert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource is an autogenerated conversion function. func Convert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(in *api.AzureFileVolumeSource, out *AzureFileVolumeSource, s conversion.Scope) error { return autoConvert_api_AzureFileVolumeSource_To_v1_AzureFileVolumeSource(in, out, s) } func autoConvert_v1_Binding_To_api_Binding(in *Binding, out *api.Binding, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ObjectReference_To_api_ObjectReference(&in.Target, &out.Target, s); err != nil { return err } return nil } +// Convert_v1_Binding_To_api_Binding is an autogenerated conversion function. func Convert_v1_Binding_To_api_Binding(in *Binding, out *api.Binding, s conversion.Scope) error { return autoConvert_v1_Binding_To_api_Binding(in, out, s) } func autoConvert_api_Binding_To_v1_Binding(in *api.Binding, out *Binding, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_ObjectReference_To_v1_ObjectReference(&in.Target, &out.Target, s); err != nil { return err } return nil } +// Convert_api_Binding_To_v1_Binding is an autogenerated conversion function. func Convert_api_Binding_To_v1_Binding(in *api.Binding, out *Binding, s conversion.Scope) error { return autoConvert_api_Binding_To_v1_Binding(in, out, s) } @@ -518,6 +560,7 @@ func autoConvert_v1_Capabilities_To_api_Capabilities(in *Capabilities, out *api. return nil } +// Convert_v1_Capabilities_To_api_Capabilities is an autogenerated conversion function. func Convert_v1_Capabilities_To_api_Capabilities(in *Capabilities, out *api.Capabilities, s conversion.Scope) error { return autoConvert_v1_Capabilities_To_api_Capabilities(in, out, s) } @@ -528,6 +571,7 @@ func autoConvert_api_Capabilities_To_v1_Capabilities(in *api.Capabilities, out * return nil } +// Convert_api_Capabilities_To_v1_Capabilities is an autogenerated conversion function. func Convert_api_Capabilities_To_v1_Capabilities(in *api.Capabilities, out *Capabilities, s conversion.Scope) error { return autoConvert_api_Capabilities_To_v1_Capabilities(in, out, s) } @@ -542,12 +586,17 @@ func autoConvert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(in *CephFSVolum return nil } +// Convert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource is an autogenerated conversion function. func Convert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(in *CephFSVolumeSource, out *api.CephFSVolumeSource, s conversion.Scope) error { return autoConvert_v1_CephFSVolumeSource_To_api_CephFSVolumeSource(in, out, s) } func autoConvert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in *api.CephFSVolumeSource, out *CephFSVolumeSource, s conversion.Scope) error { - out.Monitors = *(*[]string)(unsafe.Pointer(&in.Monitors)) + if in.Monitors == nil { + out.Monitors = make([]string, 0) + } else { + out.Monitors = *(*[]string)(unsafe.Pointer(&in.Monitors)) + } out.Path = in.Path out.User = in.User out.SecretFile = in.SecretFile @@ -556,6 +605,7 @@ func autoConvert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in *api.CephFSV return nil } +// Convert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource is an autogenerated conversion function. func Convert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in *api.CephFSVolumeSource, out *CephFSVolumeSource, s conversion.Scope) error { return autoConvert_api_CephFSVolumeSource_To_v1_CephFSVolumeSource(in, out, s) } @@ -567,6 +617,7 @@ func autoConvert_v1_CinderVolumeSource_To_api_CinderVolumeSource(in *CinderVolum return nil } +// Convert_v1_CinderVolumeSource_To_api_CinderVolumeSource is an autogenerated conversion function. func Convert_v1_CinderVolumeSource_To_api_CinderVolumeSource(in *CinderVolumeSource, out *api.CinderVolumeSource, s conversion.Scope) error { return autoConvert_v1_CinderVolumeSource_To_api_CinderVolumeSource(in, out, s) } @@ -578,6 +629,7 @@ func autoConvert_api_CinderVolumeSource_To_v1_CinderVolumeSource(in *api.CinderV return nil } +// Convert_api_CinderVolumeSource_To_v1_CinderVolumeSource is an autogenerated conversion function. func Convert_api_CinderVolumeSource_To_v1_CinderVolumeSource(in *api.CinderVolumeSource, out *CinderVolumeSource, s conversion.Scope) error { return autoConvert_api_CinderVolumeSource_To_v1_CinderVolumeSource(in, out, s) } @@ -590,6 +642,7 @@ func autoConvert_v1_ComponentCondition_To_api_ComponentCondition(in *ComponentCo return nil } +// Convert_v1_ComponentCondition_To_api_ComponentCondition is an autogenerated conversion function. func Convert_v1_ComponentCondition_To_api_ComponentCondition(in *ComponentCondition, out *api.ComponentCondition, s conversion.Scope) error { return autoConvert_v1_ComponentCondition_To_api_ComponentCondition(in, out, s) } @@ -602,30 +655,29 @@ func autoConvert_api_ComponentCondition_To_v1_ComponentCondition(in *api.Compone return nil } +// Convert_api_ComponentCondition_To_v1_ComponentCondition is an autogenerated conversion function. func Convert_api_ComponentCondition_To_v1_ComponentCondition(in *api.ComponentCondition, out *ComponentCondition, s conversion.Scope) error { return autoConvert_api_ComponentCondition_To_v1_ComponentCondition(in, out, s) } func autoConvert_v1_ComponentStatus_To_api_ComponentStatus(in *ComponentStatus, out *api.ComponentStatus, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Conditions = *(*[]api.ComponentCondition)(unsafe.Pointer(&in.Conditions)) return nil } +// Convert_v1_ComponentStatus_To_api_ComponentStatus is an autogenerated conversion function. func Convert_v1_ComponentStatus_To_api_ComponentStatus(in *ComponentStatus, out *api.ComponentStatus, s conversion.Scope) error { return autoConvert_v1_ComponentStatus_To_api_ComponentStatus(in, out, s) } func autoConvert_api_ComponentStatus_To_v1_ComponentStatus(in *api.ComponentStatus, out *ComponentStatus, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Conditions = *(*[]ComponentCondition)(unsafe.Pointer(&in.Conditions)) return nil } +// Convert_api_ComponentStatus_To_v1_ComponentStatus is an autogenerated conversion function. func Convert_api_ComponentStatus_To_v1_ComponentStatus(in *api.ComponentStatus, out *ComponentStatus, s conversion.Scope) error { return autoConvert_api_ComponentStatus_To_v1_ComponentStatus(in, out, s) } @@ -636,52 +688,84 @@ func autoConvert_v1_ComponentStatusList_To_api_ComponentStatusList(in *Component return nil } +// Convert_v1_ComponentStatusList_To_api_ComponentStatusList is an autogenerated conversion function. func Convert_v1_ComponentStatusList_To_api_ComponentStatusList(in *ComponentStatusList, out *api.ComponentStatusList, s conversion.Scope) error { return autoConvert_v1_ComponentStatusList_To_api_ComponentStatusList(in, out, s) } func autoConvert_api_ComponentStatusList_To_v1_ComponentStatusList(in *api.ComponentStatusList, out *ComponentStatusList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]ComponentStatus)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]ComponentStatus, 0) + } else { + out.Items = *(*[]ComponentStatus)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_ComponentStatusList_To_v1_ComponentStatusList is an autogenerated conversion function. func Convert_api_ComponentStatusList_To_v1_ComponentStatusList(in *api.ComponentStatusList, out *ComponentStatusList, s conversion.Scope) error { return autoConvert_api_ComponentStatusList_To_v1_ComponentStatusList(in, out, s) } func autoConvert_v1_ConfigMap_To_api_ConfigMap(in *ConfigMap, out *api.ConfigMap, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Data = *(*map[string]string)(unsafe.Pointer(&in.Data)) return nil } +// Convert_v1_ConfigMap_To_api_ConfigMap is an autogenerated conversion function. func Convert_v1_ConfigMap_To_api_ConfigMap(in *ConfigMap, out *api.ConfigMap, s conversion.Scope) error { return autoConvert_v1_ConfigMap_To_api_ConfigMap(in, out, s) } func autoConvert_api_ConfigMap_To_v1_ConfigMap(in *api.ConfigMap, out *ConfigMap, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Data = *(*map[string]string)(unsafe.Pointer(&in.Data)) return nil } +// Convert_api_ConfigMap_To_v1_ConfigMap is an autogenerated conversion function. func Convert_api_ConfigMap_To_v1_ConfigMap(in *api.ConfigMap, out *ConfigMap, s conversion.Scope) error { return autoConvert_api_ConfigMap_To_v1_ConfigMap(in, out, s) } +func autoConvert_v1_ConfigMapEnvSource_To_api_ConfigMapEnvSource(in *ConfigMapEnvSource, out *api.ConfigMapEnvSource, s conversion.Scope) error { + if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_v1_ConfigMapEnvSource_To_api_ConfigMapEnvSource is an autogenerated conversion function. +func Convert_v1_ConfigMapEnvSource_To_api_ConfigMapEnvSource(in *ConfigMapEnvSource, out *api.ConfigMapEnvSource, s conversion.Scope) error { + return autoConvert_v1_ConfigMapEnvSource_To_api_ConfigMapEnvSource(in, out, s) +} + +func autoConvert_api_ConfigMapEnvSource_To_v1_ConfigMapEnvSource(in *api.ConfigMapEnvSource, out *ConfigMapEnvSource, s conversion.Scope) error { + if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_api_ConfigMapEnvSource_To_v1_ConfigMapEnvSource is an autogenerated conversion function. +func Convert_api_ConfigMapEnvSource_To_v1_ConfigMapEnvSource(in *api.ConfigMapEnvSource, out *ConfigMapEnvSource, s conversion.Scope) error { + return autoConvert_api_ConfigMapEnvSource_To_v1_ConfigMapEnvSource(in, out, s) +} + func autoConvert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(in *ConfigMapKeySelector, out *api.ConfigMapKeySelector, s conversion.Scope) error { if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { return err } out.Key = in.Key + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector is an autogenerated conversion function. func Convert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(in *ConfigMapKeySelector, out *api.ConfigMapKeySelector, s conversion.Scope) error { return autoConvert_v1_ConfigMapKeySelector_To_api_ConfigMapKeySelector(in, out, s) } @@ -691,9 +775,11 @@ func autoConvert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(in *api.Con return err } out.Key = in.Key + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector is an autogenerated conversion function. func Convert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(in *api.ConfigMapKeySelector, out *ConfigMapKeySelector, s conversion.Scope) error { return autoConvert_api_ConfigMapKeySelector_To_v1_ConfigMapKeySelector(in, out, s) } @@ -704,29 +790,65 @@ func autoConvert_v1_ConfigMapList_To_api_ConfigMapList(in *ConfigMapList, out *a return nil } +// Convert_v1_ConfigMapList_To_api_ConfigMapList is an autogenerated conversion function. func Convert_v1_ConfigMapList_To_api_ConfigMapList(in *ConfigMapList, out *api.ConfigMapList, s conversion.Scope) error { return autoConvert_v1_ConfigMapList_To_api_ConfigMapList(in, out, s) } func autoConvert_api_ConfigMapList_To_v1_ConfigMapList(in *api.ConfigMapList, out *ConfigMapList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]ConfigMap)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]ConfigMap, 0) + } else { + out.Items = *(*[]ConfigMap)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_ConfigMapList_To_v1_ConfigMapList is an autogenerated conversion function. func Convert_api_ConfigMapList_To_v1_ConfigMapList(in *api.ConfigMapList, out *ConfigMapList, s conversion.Scope) error { return autoConvert_api_ConfigMapList_To_v1_ConfigMapList(in, out, s) } +func autoConvert_v1_ConfigMapProjection_To_api_ConfigMapProjection(in *ConfigMapProjection, out *api.ConfigMapProjection, s conversion.Scope) error { + if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Items = *(*[]api.KeyToPath)(unsafe.Pointer(&in.Items)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_v1_ConfigMapProjection_To_api_ConfigMapProjection is an autogenerated conversion function. +func Convert_v1_ConfigMapProjection_To_api_ConfigMapProjection(in *ConfigMapProjection, out *api.ConfigMapProjection, s conversion.Scope) error { + return autoConvert_v1_ConfigMapProjection_To_api_ConfigMapProjection(in, out, s) +} + +func autoConvert_api_ConfigMapProjection_To_v1_ConfigMapProjection(in *api.ConfigMapProjection, out *ConfigMapProjection, s conversion.Scope) error { + if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Items = *(*[]KeyToPath)(unsafe.Pointer(&in.Items)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_api_ConfigMapProjection_To_v1_ConfigMapProjection is an autogenerated conversion function. +func Convert_api_ConfigMapProjection_To_v1_ConfigMapProjection(in *api.ConfigMapProjection, out *ConfigMapProjection, s conversion.Scope) error { + return autoConvert_api_ConfigMapProjection_To_v1_ConfigMapProjection(in, out, s) +} + func autoConvert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(in *ConfigMapVolumeSource, out *api.ConfigMapVolumeSource, s conversion.Scope) error { if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { return err } out.Items = *(*[]api.KeyToPath)(unsafe.Pointer(&in.Items)) out.DefaultMode = (*int32)(unsafe.Pointer(in.DefaultMode)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource is an autogenerated conversion function. func Convert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(in *ConfigMapVolumeSource, out *api.ConfigMapVolumeSource, s conversion.Scope) error { return autoConvert_v1_ConfigMapVolumeSource_To_api_ConfigMapVolumeSource(in, out, s) } @@ -737,9 +859,11 @@ func autoConvert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(in *api.C } out.Items = *(*[]KeyToPath)(unsafe.Pointer(&in.Items)) out.DefaultMode = (*int32)(unsafe.Pointer(in.DefaultMode)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource is an autogenerated conversion function. func Convert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(in *api.ConfigMapVolumeSource, out *ConfigMapVolumeSource, s conversion.Scope) error { return autoConvert_api_ConfigMapVolumeSource_To_v1_ConfigMapVolumeSource(in, out, s) } @@ -751,6 +875,7 @@ func autoConvert_v1_Container_To_api_Container(in *Container, out *api.Container out.Args = *(*[]string)(unsafe.Pointer(&in.Args)) out.WorkingDir = in.WorkingDir out.Ports = *(*[]api.ContainerPort)(unsafe.Pointer(&in.Ports)) + out.EnvFrom = *(*[]api.EnvFromSource)(unsafe.Pointer(&in.EnvFrom)) out.Env = *(*[]api.EnvVar)(unsafe.Pointer(&in.Env)) if err := Convert_v1_ResourceRequirements_To_api_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil { return err @@ -760,6 +885,7 @@ func autoConvert_v1_Container_To_api_Container(in *Container, out *api.Container out.ReadinessProbe = (*api.Probe)(unsafe.Pointer(in.ReadinessProbe)) out.Lifecycle = (*api.Lifecycle)(unsafe.Pointer(in.Lifecycle)) out.TerminationMessagePath = in.TerminationMessagePath + out.TerminationMessagePolicy = api.TerminationMessagePolicy(in.TerminationMessagePolicy) out.ImagePullPolicy = api.PullPolicy(in.ImagePullPolicy) out.SecurityContext = (*api.SecurityContext)(unsafe.Pointer(in.SecurityContext)) out.Stdin = in.Stdin @@ -768,6 +894,7 @@ func autoConvert_v1_Container_To_api_Container(in *Container, out *api.Container return nil } +// Convert_v1_Container_To_api_Container is an autogenerated conversion function. func Convert_v1_Container_To_api_Container(in *Container, out *api.Container, s conversion.Scope) error { return autoConvert_v1_Container_To_api_Container(in, out, s) } @@ -779,6 +906,7 @@ func autoConvert_api_Container_To_v1_Container(in *api.Container, out *Container out.Args = *(*[]string)(unsafe.Pointer(&in.Args)) out.WorkingDir = in.WorkingDir out.Ports = *(*[]ContainerPort)(unsafe.Pointer(&in.Ports)) + out.EnvFrom = *(*[]EnvFromSource)(unsafe.Pointer(&in.EnvFrom)) out.Env = *(*[]EnvVar)(unsafe.Pointer(&in.Env)) if err := Convert_api_ResourceRequirements_To_v1_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil { return err @@ -788,6 +916,7 @@ func autoConvert_api_Container_To_v1_Container(in *api.Container, out *Container out.ReadinessProbe = (*Probe)(unsafe.Pointer(in.ReadinessProbe)) out.Lifecycle = (*Lifecycle)(unsafe.Pointer(in.Lifecycle)) out.TerminationMessagePath = in.TerminationMessagePath + out.TerminationMessagePolicy = TerminationMessagePolicy(in.TerminationMessagePolicy) out.ImagePullPolicy = PullPolicy(in.ImagePullPolicy) out.SecurityContext = (*SecurityContext)(unsafe.Pointer(in.SecurityContext)) out.Stdin = in.Stdin @@ -796,6 +925,7 @@ func autoConvert_api_Container_To_v1_Container(in *api.Container, out *Container return nil } +// Convert_api_Container_To_v1_Container is an autogenerated conversion function. func Convert_api_Container_To_v1_Container(in *api.Container, out *Container, s conversion.Scope) error { return autoConvert_api_Container_To_v1_Container(in, out, s) } @@ -806,16 +936,22 @@ func autoConvert_v1_ContainerImage_To_api_ContainerImage(in *ContainerImage, out return nil } +// Convert_v1_ContainerImage_To_api_ContainerImage is an autogenerated conversion function. func Convert_v1_ContainerImage_To_api_ContainerImage(in *ContainerImage, out *api.ContainerImage, s conversion.Scope) error { return autoConvert_v1_ContainerImage_To_api_ContainerImage(in, out, s) } func autoConvert_api_ContainerImage_To_v1_ContainerImage(in *api.ContainerImage, out *ContainerImage, s conversion.Scope) error { - out.Names = *(*[]string)(unsafe.Pointer(&in.Names)) + if in.Names == nil { + out.Names = make([]string, 0) + } else { + out.Names = *(*[]string)(unsafe.Pointer(&in.Names)) + } out.SizeBytes = in.SizeBytes return nil } +// Convert_api_ContainerImage_To_v1_ContainerImage is an autogenerated conversion function. func Convert_api_ContainerImage_To_v1_ContainerImage(in *api.ContainerImage, out *ContainerImage, s conversion.Scope) error { return autoConvert_api_ContainerImage_To_v1_ContainerImage(in, out, s) } @@ -829,6 +965,7 @@ func autoConvert_v1_ContainerPort_To_api_ContainerPort(in *ContainerPort, out *a return nil } +// Convert_v1_ContainerPort_To_api_ContainerPort is an autogenerated conversion function. func Convert_v1_ContainerPort_To_api_ContainerPort(in *ContainerPort, out *api.ContainerPort, s conversion.Scope) error { return autoConvert_v1_ContainerPort_To_api_ContainerPort(in, out, s) } @@ -842,6 +979,7 @@ func autoConvert_api_ContainerPort_To_v1_ContainerPort(in *api.ContainerPort, ou return nil } +// Convert_api_ContainerPort_To_v1_ContainerPort is an autogenerated conversion function. func Convert_api_ContainerPort_To_v1_ContainerPort(in *api.ContainerPort, out *ContainerPort, s conversion.Scope) error { return autoConvert_api_ContainerPort_To_v1_ContainerPort(in, out, s) } @@ -853,6 +991,7 @@ func autoConvert_v1_ContainerState_To_api_ContainerState(in *ContainerState, out return nil } +// Convert_v1_ContainerState_To_api_ContainerState is an autogenerated conversion function. func Convert_v1_ContainerState_To_api_ContainerState(in *ContainerState, out *api.ContainerState, s conversion.Scope) error { return autoConvert_v1_ContainerState_To_api_ContainerState(in, out, s) } @@ -864,6 +1003,7 @@ func autoConvert_api_ContainerState_To_v1_ContainerState(in *api.ContainerState, return nil } +// Convert_api_ContainerState_To_v1_ContainerState is an autogenerated conversion function. func Convert_api_ContainerState_To_v1_ContainerState(in *api.ContainerState, out *ContainerState, s conversion.Scope) error { return autoConvert_api_ContainerState_To_v1_ContainerState(in, out, s) } @@ -873,6 +1013,7 @@ func autoConvert_v1_ContainerStateRunning_To_api_ContainerStateRunning(in *Conta return nil } +// Convert_v1_ContainerStateRunning_To_api_ContainerStateRunning is an autogenerated conversion function. func Convert_v1_ContainerStateRunning_To_api_ContainerStateRunning(in *ContainerStateRunning, out *api.ContainerStateRunning, s conversion.Scope) error { return autoConvert_v1_ContainerStateRunning_To_api_ContainerStateRunning(in, out, s) } @@ -882,6 +1023,7 @@ func autoConvert_api_ContainerStateRunning_To_v1_ContainerStateRunning(in *api.C return nil } +// Convert_api_ContainerStateRunning_To_v1_ContainerStateRunning is an autogenerated conversion function. func Convert_api_ContainerStateRunning_To_v1_ContainerStateRunning(in *api.ContainerStateRunning, out *ContainerStateRunning, s conversion.Scope) error { return autoConvert_api_ContainerStateRunning_To_v1_ContainerStateRunning(in, out, s) } @@ -897,6 +1039,7 @@ func autoConvert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(in return nil } +// Convert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated is an autogenerated conversion function. func Convert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(in *ContainerStateTerminated, out *api.ContainerStateTerminated, s conversion.Scope) error { return autoConvert_v1_ContainerStateTerminated_To_api_ContainerStateTerminated(in, out, s) } @@ -912,6 +1055,7 @@ func autoConvert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(in return nil } +// Convert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated is an autogenerated conversion function. func Convert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(in *api.ContainerStateTerminated, out *ContainerStateTerminated, s conversion.Scope) error { return autoConvert_api_ContainerStateTerminated_To_v1_ContainerStateTerminated(in, out, s) } @@ -922,6 +1066,7 @@ func autoConvert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(in *Conta return nil } +// Convert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting is an autogenerated conversion function. func Convert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(in *ContainerStateWaiting, out *api.ContainerStateWaiting, s conversion.Scope) error { return autoConvert_v1_ContainerStateWaiting_To_api_ContainerStateWaiting(in, out, s) } @@ -932,6 +1077,7 @@ func autoConvert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(in *api.C return nil } +// Convert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting is an autogenerated conversion function. func Convert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(in *api.ContainerStateWaiting, out *ContainerStateWaiting, s conversion.Scope) error { return autoConvert_api_ContainerStateWaiting_To_v1_ContainerStateWaiting(in, out, s) } @@ -952,6 +1098,7 @@ func autoConvert_v1_ContainerStatus_To_api_ContainerStatus(in *ContainerStatus, return nil } +// Convert_v1_ContainerStatus_To_api_ContainerStatus is an autogenerated conversion function. func Convert_v1_ContainerStatus_To_api_ContainerStatus(in *ContainerStatus, out *api.ContainerStatus, s conversion.Scope) error { return autoConvert_v1_ContainerStatus_To_api_ContainerStatus(in, out, s) } @@ -972,6 +1119,7 @@ func autoConvert_api_ContainerStatus_To_v1_ContainerStatus(in *api.ContainerStat return nil } +// Convert_api_ContainerStatus_To_v1_ContainerStatus is an autogenerated conversion function. func Convert_api_ContainerStatus_To_v1_ContainerStatus(in *api.ContainerStatus, out *ContainerStatus, s conversion.Scope) error { return autoConvert_api_ContainerStatus_To_v1_ContainerStatus(in, out, s) } @@ -981,6 +1129,7 @@ func autoConvert_v1_DaemonEndpoint_To_api_DaemonEndpoint(in *DaemonEndpoint, out return nil } +// Convert_v1_DaemonEndpoint_To_api_DaemonEndpoint is an autogenerated conversion function. func Convert_v1_DaemonEndpoint_To_api_DaemonEndpoint(in *DaemonEndpoint, out *api.DaemonEndpoint, s conversion.Scope) error { return autoConvert_v1_DaemonEndpoint_To_api_DaemonEndpoint(in, out, s) } @@ -990,6 +1139,7 @@ func autoConvert_api_DaemonEndpoint_To_v1_DaemonEndpoint(in *api.DaemonEndpoint, return nil } +// Convert_api_DaemonEndpoint_To_v1_DaemonEndpoint is an autogenerated conversion function. func Convert_api_DaemonEndpoint_To_v1_DaemonEndpoint(in *api.DaemonEndpoint, out *DaemonEndpoint, s conversion.Scope) error { return autoConvert_api_DaemonEndpoint_To_v1_DaemonEndpoint(in, out, s) } @@ -998,9 +1148,11 @@ func autoConvert_v1_DeleteOptions_To_api_DeleteOptions(in *DeleteOptions, out *a out.GracePeriodSeconds = (*int64)(unsafe.Pointer(in.GracePeriodSeconds)) out.Preconditions = (*api.Preconditions)(unsafe.Pointer(in.Preconditions)) out.OrphanDependents = (*bool)(unsafe.Pointer(in.OrphanDependents)) + out.PropagationPolicy = (*api.DeletionPropagation)(unsafe.Pointer(in.PropagationPolicy)) return nil } +// Convert_v1_DeleteOptions_To_api_DeleteOptions is an autogenerated conversion function. func Convert_v1_DeleteOptions_To_api_DeleteOptions(in *DeleteOptions, out *api.DeleteOptions, s conversion.Scope) error { return autoConvert_v1_DeleteOptions_To_api_DeleteOptions(in, out, s) } @@ -1009,13 +1161,35 @@ func autoConvert_api_DeleteOptions_To_v1_DeleteOptions(in *api.DeleteOptions, ou out.GracePeriodSeconds = (*int64)(unsafe.Pointer(in.GracePeriodSeconds)) out.Preconditions = (*Preconditions)(unsafe.Pointer(in.Preconditions)) out.OrphanDependents = (*bool)(unsafe.Pointer(in.OrphanDependents)) + out.PropagationPolicy = (*DeletionPropagation)(unsafe.Pointer(in.PropagationPolicy)) return nil } +// Convert_api_DeleteOptions_To_v1_DeleteOptions is an autogenerated conversion function. func Convert_api_DeleteOptions_To_v1_DeleteOptions(in *api.DeleteOptions, out *DeleteOptions, s conversion.Scope) error { return autoConvert_api_DeleteOptions_To_v1_DeleteOptions(in, out, s) } +func autoConvert_v1_DownwardAPIProjection_To_api_DownwardAPIProjection(in *DownwardAPIProjection, out *api.DownwardAPIProjection, s conversion.Scope) error { + out.Items = *(*[]api.DownwardAPIVolumeFile)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1_DownwardAPIProjection_To_api_DownwardAPIProjection is an autogenerated conversion function. +func Convert_v1_DownwardAPIProjection_To_api_DownwardAPIProjection(in *DownwardAPIProjection, out *api.DownwardAPIProjection, s conversion.Scope) error { + return autoConvert_v1_DownwardAPIProjection_To_api_DownwardAPIProjection(in, out, s) +} + +func autoConvert_api_DownwardAPIProjection_To_v1_DownwardAPIProjection(in *api.DownwardAPIProjection, out *DownwardAPIProjection, s conversion.Scope) error { + out.Items = *(*[]DownwardAPIVolumeFile)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_api_DownwardAPIProjection_To_v1_DownwardAPIProjection is an autogenerated conversion function. +func Convert_api_DownwardAPIProjection_To_v1_DownwardAPIProjection(in *api.DownwardAPIProjection, out *DownwardAPIProjection, s conversion.Scope) error { + return autoConvert_api_DownwardAPIProjection_To_v1_DownwardAPIProjection(in, out, s) +} + func autoConvert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in *DownwardAPIVolumeFile, out *api.DownwardAPIVolumeFile, s conversion.Scope) error { out.Path = in.Path out.FieldRef = (*api.ObjectFieldSelector)(unsafe.Pointer(in.FieldRef)) @@ -1024,6 +1198,7 @@ func autoConvert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in *Downw return nil } +// Convert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile is an autogenerated conversion function. func Convert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in *DownwardAPIVolumeFile, out *api.DownwardAPIVolumeFile, s conversion.Scope) error { return autoConvert_v1_DownwardAPIVolumeFile_To_api_DownwardAPIVolumeFile(in, out, s) } @@ -1036,6 +1211,7 @@ func autoConvert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(in *api.D return nil } +// Convert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile is an autogenerated conversion function. func Convert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(in *api.DownwardAPIVolumeFile, out *DownwardAPIVolumeFile, s conversion.Scope) error { return autoConvert_api_DownwardAPIVolumeFile_To_v1_DownwardAPIVolumeFile(in, out, s) } @@ -1046,6 +1222,7 @@ func autoConvert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(in *D return nil } +// Convert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource is an autogenerated conversion function. func Convert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(in *DownwardAPIVolumeSource, out *api.DownwardAPIVolumeSource, s conversion.Scope) error { return autoConvert_v1_DownwardAPIVolumeSource_To_api_DownwardAPIVolumeSource(in, out, s) } @@ -1056,24 +1233,29 @@ func autoConvert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in *a return nil } +// Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource is an autogenerated conversion function. func Convert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in *api.DownwardAPIVolumeSource, out *DownwardAPIVolumeSource, s conversion.Scope) error { return autoConvert_api_DownwardAPIVolumeSource_To_v1_DownwardAPIVolumeSource(in, out, s) } func autoConvert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVolumeSource, out *api.EmptyDirVolumeSource, s conversion.Scope) error { out.Medium = api.StorageMedium(in.Medium) + out.SizeLimit = in.SizeLimit return nil } +// Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource is an autogenerated conversion function. func Convert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in *EmptyDirVolumeSource, out *api.EmptyDirVolumeSource, s conversion.Scope) error { return autoConvert_v1_EmptyDirVolumeSource_To_api_EmptyDirVolumeSource(in, out, s) } func autoConvert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in *api.EmptyDirVolumeSource, out *EmptyDirVolumeSource, s conversion.Scope) error { out.Medium = StorageMedium(in.Medium) + out.SizeLimit = in.SizeLimit return nil } +// Convert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource is an autogenerated conversion function. func Convert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in *api.EmptyDirVolumeSource, out *EmptyDirVolumeSource, s conversion.Scope) error { return autoConvert_api_EmptyDirVolumeSource_To_v1_EmptyDirVolumeSource(in, out, s) } @@ -1086,6 +1268,7 @@ func autoConvert_v1_EndpointAddress_To_api_EndpointAddress(in *EndpointAddress, return nil } +// Convert_v1_EndpointAddress_To_api_EndpointAddress is an autogenerated conversion function. func Convert_v1_EndpointAddress_To_api_EndpointAddress(in *EndpointAddress, out *api.EndpointAddress, s conversion.Scope) error { return autoConvert_v1_EndpointAddress_To_api_EndpointAddress(in, out, s) } @@ -1098,6 +1281,7 @@ func autoConvert_api_EndpointAddress_To_v1_EndpointAddress(in *api.EndpointAddre return nil } +// Convert_api_EndpointAddress_To_v1_EndpointAddress is an autogenerated conversion function. func Convert_api_EndpointAddress_To_v1_EndpointAddress(in *api.EndpointAddress, out *EndpointAddress, s conversion.Scope) error { return autoConvert_api_EndpointAddress_To_v1_EndpointAddress(in, out, s) } @@ -1109,6 +1293,7 @@ func autoConvert_v1_EndpointPort_To_api_EndpointPort(in *EndpointPort, out *api. return nil } +// Convert_v1_EndpointPort_To_api_EndpointPort is an autogenerated conversion function. func Convert_v1_EndpointPort_To_api_EndpointPort(in *EndpointPort, out *api.EndpointPort, s conversion.Scope) error { return autoConvert_v1_EndpointPort_To_api_EndpointPort(in, out, s) } @@ -1120,6 +1305,7 @@ func autoConvert_api_EndpointPort_To_v1_EndpointPort(in *api.EndpointPort, out * return nil } +// Convert_api_EndpointPort_To_v1_EndpointPort is an autogenerated conversion function. func Convert_api_EndpointPort_To_v1_EndpointPort(in *api.EndpointPort, out *EndpointPort, s conversion.Scope) error { return autoConvert_api_EndpointPort_To_v1_EndpointPort(in, out, s) } @@ -1131,6 +1317,7 @@ func autoConvert_v1_EndpointSubset_To_api_EndpointSubset(in *EndpointSubset, out return nil } +// Convert_v1_EndpointSubset_To_api_EndpointSubset is an autogenerated conversion function. func Convert_v1_EndpointSubset_To_api_EndpointSubset(in *EndpointSubset, out *api.EndpointSubset, s conversion.Scope) error { return autoConvert_v1_EndpointSubset_To_api_EndpointSubset(in, out, s) } @@ -1142,30 +1329,33 @@ func autoConvert_api_EndpointSubset_To_v1_EndpointSubset(in *api.EndpointSubset, return nil } +// Convert_api_EndpointSubset_To_v1_EndpointSubset is an autogenerated conversion function. func Convert_api_EndpointSubset_To_v1_EndpointSubset(in *api.EndpointSubset, out *EndpointSubset, s conversion.Scope) error { return autoConvert_api_EndpointSubset_To_v1_EndpointSubset(in, out, s) } func autoConvert_v1_Endpoints_To_api_Endpoints(in *Endpoints, out *api.Endpoints, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Subsets = *(*[]api.EndpointSubset)(unsafe.Pointer(&in.Subsets)) return nil } +// Convert_v1_Endpoints_To_api_Endpoints is an autogenerated conversion function. func Convert_v1_Endpoints_To_api_Endpoints(in *Endpoints, out *api.Endpoints, s conversion.Scope) error { return autoConvert_v1_Endpoints_To_api_Endpoints(in, out, s) } func autoConvert_api_Endpoints_To_v1_Endpoints(in *api.Endpoints, out *Endpoints, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err + out.ObjectMeta = in.ObjectMeta + if in.Subsets == nil { + out.Subsets = make([]EndpointSubset, 0) + } else { + out.Subsets = *(*[]EndpointSubset)(unsafe.Pointer(&in.Subsets)) } - out.Subsets = *(*[]EndpointSubset)(unsafe.Pointer(&in.Subsets)) return nil } +// Convert_api_Endpoints_To_v1_Endpoints is an autogenerated conversion function. func Convert_api_Endpoints_To_v1_Endpoints(in *api.Endpoints, out *Endpoints, s conversion.Scope) error { return autoConvert_api_Endpoints_To_v1_Endpoints(in, out, s) } @@ -1176,20 +1366,50 @@ func autoConvert_v1_EndpointsList_To_api_EndpointsList(in *EndpointsList, out *a return nil } +// Convert_v1_EndpointsList_To_api_EndpointsList is an autogenerated conversion function. func Convert_v1_EndpointsList_To_api_EndpointsList(in *EndpointsList, out *api.EndpointsList, s conversion.Scope) error { return autoConvert_v1_EndpointsList_To_api_EndpointsList(in, out, s) } func autoConvert_api_EndpointsList_To_v1_EndpointsList(in *api.EndpointsList, out *EndpointsList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]Endpoints)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]Endpoints, 0) + } else { + out.Items = *(*[]Endpoints)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_EndpointsList_To_v1_EndpointsList is an autogenerated conversion function. func Convert_api_EndpointsList_To_v1_EndpointsList(in *api.EndpointsList, out *EndpointsList, s conversion.Scope) error { return autoConvert_api_EndpointsList_To_v1_EndpointsList(in, out, s) } +func autoConvert_v1_EnvFromSource_To_api_EnvFromSource(in *EnvFromSource, out *api.EnvFromSource, s conversion.Scope) error { + out.Prefix = in.Prefix + out.ConfigMapRef = (*api.ConfigMapEnvSource)(unsafe.Pointer(in.ConfigMapRef)) + out.SecretRef = (*api.SecretEnvSource)(unsafe.Pointer(in.SecretRef)) + return nil +} + +// Convert_v1_EnvFromSource_To_api_EnvFromSource is an autogenerated conversion function. +func Convert_v1_EnvFromSource_To_api_EnvFromSource(in *EnvFromSource, out *api.EnvFromSource, s conversion.Scope) error { + return autoConvert_v1_EnvFromSource_To_api_EnvFromSource(in, out, s) +} + +func autoConvert_api_EnvFromSource_To_v1_EnvFromSource(in *api.EnvFromSource, out *EnvFromSource, s conversion.Scope) error { + out.Prefix = in.Prefix + out.ConfigMapRef = (*ConfigMapEnvSource)(unsafe.Pointer(in.ConfigMapRef)) + out.SecretRef = (*SecretEnvSource)(unsafe.Pointer(in.SecretRef)) + return nil +} + +// Convert_api_EnvFromSource_To_v1_EnvFromSource is an autogenerated conversion function. +func Convert_api_EnvFromSource_To_v1_EnvFromSource(in *api.EnvFromSource, out *EnvFromSource, s conversion.Scope) error { + return autoConvert_api_EnvFromSource_To_v1_EnvFromSource(in, out, s) +} + func autoConvert_v1_EnvVar_To_api_EnvVar(in *EnvVar, out *api.EnvVar, s conversion.Scope) error { out.Name = in.Name out.Value = in.Value @@ -1197,6 +1417,7 @@ func autoConvert_v1_EnvVar_To_api_EnvVar(in *EnvVar, out *api.EnvVar, s conversi return nil } +// Convert_v1_EnvVar_To_api_EnvVar is an autogenerated conversion function. func Convert_v1_EnvVar_To_api_EnvVar(in *EnvVar, out *api.EnvVar, s conversion.Scope) error { return autoConvert_v1_EnvVar_To_api_EnvVar(in, out, s) } @@ -1208,6 +1429,7 @@ func autoConvert_api_EnvVar_To_v1_EnvVar(in *api.EnvVar, out *EnvVar, s conversi return nil } +// Convert_api_EnvVar_To_v1_EnvVar is an autogenerated conversion function. func Convert_api_EnvVar_To_v1_EnvVar(in *api.EnvVar, out *EnvVar, s conversion.Scope) error { return autoConvert_api_EnvVar_To_v1_EnvVar(in, out, s) } @@ -1220,6 +1442,7 @@ func autoConvert_v1_EnvVarSource_To_api_EnvVarSource(in *EnvVarSource, out *api. return nil } +// Convert_v1_EnvVarSource_To_api_EnvVarSource is an autogenerated conversion function. func Convert_v1_EnvVarSource_To_api_EnvVarSource(in *EnvVarSource, out *api.EnvVarSource, s conversion.Scope) error { return autoConvert_v1_EnvVarSource_To_api_EnvVarSource(in, out, s) } @@ -1232,14 +1455,13 @@ func autoConvert_api_EnvVarSource_To_v1_EnvVarSource(in *api.EnvVarSource, out * return nil } +// Convert_api_EnvVarSource_To_v1_EnvVarSource is an autogenerated conversion function. func Convert_api_EnvVarSource_To_v1_EnvVarSource(in *api.EnvVarSource, out *EnvVarSource, s conversion.Scope) error { return autoConvert_api_EnvVarSource_To_v1_EnvVarSource(in, out, s) } func autoConvert_v1_Event_To_api_Event(in *Event, out *api.Event, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ObjectReference_To_api_ObjectReference(&in.InvolvedObject, &out.InvolvedObject, s); err != nil { return err } @@ -1255,14 +1477,13 @@ func autoConvert_v1_Event_To_api_Event(in *Event, out *api.Event, s conversion.S return nil } +// Convert_v1_Event_To_api_Event is an autogenerated conversion function. func Convert_v1_Event_To_api_Event(in *Event, out *api.Event, s conversion.Scope) error { return autoConvert_v1_Event_To_api_Event(in, out, s) } func autoConvert_api_Event_To_v1_Event(in *api.Event, out *Event, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_ObjectReference_To_v1_ObjectReference(&in.InvolvedObject, &out.InvolvedObject, s); err != nil { return err } @@ -1278,6 +1499,7 @@ func autoConvert_api_Event_To_v1_Event(in *api.Event, out *Event, s conversion.S return nil } +// Convert_api_Event_To_v1_Event is an autogenerated conversion function. func Convert_api_Event_To_v1_Event(in *api.Event, out *Event, s conversion.Scope) error { return autoConvert_api_Event_To_v1_Event(in, out, s) } @@ -1288,16 +1510,22 @@ func autoConvert_v1_EventList_To_api_EventList(in *EventList, out *api.EventList return nil } +// Convert_v1_EventList_To_api_EventList is an autogenerated conversion function. func Convert_v1_EventList_To_api_EventList(in *EventList, out *api.EventList, s conversion.Scope) error { return autoConvert_v1_EventList_To_api_EventList(in, out, s) } func autoConvert_api_EventList_To_v1_EventList(in *api.EventList, out *EventList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]Event)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]Event, 0) + } else { + out.Items = *(*[]Event)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_EventList_To_v1_EventList is an autogenerated conversion function. func Convert_api_EventList_To_v1_EventList(in *api.EventList, out *EventList, s conversion.Scope) error { return autoConvert_api_EventList_To_v1_EventList(in, out, s) } @@ -1308,6 +1536,7 @@ func autoConvert_v1_EventSource_To_api_EventSource(in *EventSource, out *api.Eve return nil } +// Convert_v1_EventSource_To_api_EventSource is an autogenerated conversion function. func Convert_v1_EventSource_To_api_EventSource(in *EventSource, out *api.EventSource, s conversion.Scope) error { return autoConvert_v1_EventSource_To_api_EventSource(in, out, s) } @@ -1318,6 +1547,7 @@ func autoConvert_api_EventSource_To_v1_EventSource(in *api.EventSource, out *Eve return nil } +// Convert_api_EventSource_To_v1_EventSource is an autogenerated conversion function. func Convert_api_EventSource_To_v1_EventSource(in *api.EventSource, out *EventSource, s conversion.Scope) error { return autoConvert_api_EventSource_To_v1_EventSource(in, out, s) } @@ -1327,6 +1557,7 @@ func autoConvert_v1_ExecAction_To_api_ExecAction(in *ExecAction, out *api.ExecAc return nil } +// Convert_v1_ExecAction_To_api_ExecAction is an autogenerated conversion function. func Convert_v1_ExecAction_To_api_ExecAction(in *ExecAction, out *api.ExecAction, s conversion.Scope) error { return autoConvert_v1_ExecAction_To_api_ExecAction(in, out, s) } @@ -1336,30 +1567,11 @@ func autoConvert_api_ExecAction_To_v1_ExecAction(in *api.ExecAction, out *ExecAc return nil } +// Convert_api_ExecAction_To_v1_ExecAction is an autogenerated conversion function. func Convert_api_ExecAction_To_v1_ExecAction(in *api.ExecAction, out *ExecAction, s conversion.Scope) error { return autoConvert_api_ExecAction_To_v1_ExecAction(in, out, s) } -func autoConvert_v1_ExportOptions_To_api_ExportOptions(in *ExportOptions, out *api.ExportOptions, s conversion.Scope) error { - out.Export = in.Export - out.Exact = in.Exact - return nil -} - -func Convert_v1_ExportOptions_To_api_ExportOptions(in *ExportOptions, out *api.ExportOptions, s conversion.Scope) error { - return autoConvert_v1_ExportOptions_To_api_ExportOptions(in, out, s) -} - -func autoConvert_api_ExportOptions_To_v1_ExportOptions(in *api.ExportOptions, out *ExportOptions, s conversion.Scope) error { - out.Export = in.Export - out.Exact = in.Exact - return nil -} - -func Convert_api_ExportOptions_To_v1_ExportOptions(in *api.ExportOptions, out *ExportOptions, s conversion.Scope) error { - return autoConvert_api_ExportOptions_To_v1_ExportOptions(in, out, s) -} - func autoConvert_v1_FCVolumeSource_To_api_FCVolumeSource(in *FCVolumeSource, out *api.FCVolumeSource, s conversion.Scope) error { out.TargetWWNs = *(*[]string)(unsafe.Pointer(&in.TargetWWNs)) out.Lun = (*int32)(unsafe.Pointer(in.Lun)) @@ -1368,18 +1580,24 @@ func autoConvert_v1_FCVolumeSource_To_api_FCVolumeSource(in *FCVolumeSource, out return nil } +// Convert_v1_FCVolumeSource_To_api_FCVolumeSource is an autogenerated conversion function. func Convert_v1_FCVolumeSource_To_api_FCVolumeSource(in *FCVolumeSource, out *api.FCVolumeSource, s conversion.Scope) error { return autoConvert_v1_FCVolumeSource_To_api_FCVolumeSource(in, out, s) } func autoConvert_api_FCVolumeSource_To_v1_FCVolumeSource(in *api.FCVolumeSource, out *FCVolumeSource, s conversion.Scope) error { - out.TargetWWNs = *(*[]string)(unsafe.Pointer(&in.TargetWWNs)) + if in.TargetWWNs == nil { + out.TargetWWNs = make([]string, 0) + } else { + out.TargetWWNs = *(*[]string)(unsafe.Pointer(&in.TargetWWNs)) + } out.Lun = (*int32)(unsafe.Pointer(in.Lun)) out.FSType = in.FSType out.ReadOnly = in.ReadOnly return nil } +// Convert_api_FCVolumeSource_To_v1_FCVolumeSource is an autogenerated conversion function. func Convert_api_FCVolumeSource_To_v1_FCVolumeSource(in *api.FCVolumeSource, out *FCVolumeSource, s conversion.Scope) error { return autoConvert_api_FCVolumeSource_To_v1_FCVolumeSource(in, out, s) } @@ -1393,6 +1611,7 @@ func autoConvert_v1_FlexVolumeSource_To_api_FlexVolumeSource(in *FlexVolumeSourc return nil } +// Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource is an autogenerated conversion function. func Convert_v1_FlexVolumeSource_To_api_FlexVolumeSource(in *FlexVolumeSource, out *api.FlexVolumeSource, s conversion.Scope) error { return autoConvert_v1_FlexVolumeSource_To_api_FlexVolumeSource(in, out, s) } @@ -1406,6 +1625,7 @@ func autoConvert_api_FlexVolumeSource_To_v1_FlexVolumeSource(in *api.FlexVolumeS return nil } +// Convert_api_FlexVolumeSource_To_v1_FlexVolumeSource is an autogenerated conversion function. func Convert_api_FlexVolumeSource_To_v1_FlexVolumeSource(in *api.FlexVolumeSource, out *FlexVolumeSource, s conversion.Scope) error { return autoConvert_api_FlexVolumeSource_To_v1_FlexVolumeSource(in, out, s) } @@ -1416,6 +1636,7 @@ func autoConvert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(in *FlockerVo return nil } +// Convert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource is an autogenerated conversion function. func Convert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(in *FlockerVolumeSource, out *api.FlockerVolumeSource, s conversion.Scope) error { return autoConvert_v1_FlockerVolumeSource_To_api_FlockerVolumeSource(in, out, s) } @@ -1426,6 +1647,7 @@ func autoConvert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(in *api.Flock return nil } +// Convert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource is an autogenerated conversion function. func Convert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(in *api.FlockerVolumeSource, out *FlockerVolumeSource, s conversion.Scope) error { return autoConvert_api_FlockerVolumeSource_To_v1_FlockerVolumeSource(in, out, s) } @@ -1438,6 +1660,7 @@ func autoConvert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolume return nil } +// Convert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource is an autogenerated conversion function. func Convert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(in *GCEPersistentDiskVolumeSource, out *api.GCEPersistentDiskVolumeSource, s conversion.Scope) error { return autoConvert_v1_GCEPersistentDiskVolumeSource_To_api_GCEPersistentDiskVolumeSource(in, out, s) } @@ -1450,6 +1673,7 @@ func autoConvert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolume return nil } +// Convert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource is an autogenerated conversion function. func Convert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(in *api.GCEPersistentDiskVolumeSource, out *GCEPersistentDiskVolumeSource, s conversion.Scope) error { return autoConvert_api_GCEPersistentDiskVolumeSource_To_v1_GCEPersistentDiskVolumeSource(in, out, s) } @@ -1461,6 +1685,7 @@ func autoConvert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(in *GitRepoVo return nil } +// Convert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource is an autogenerated conversion function. func Convert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(in *GitRepoVolumeSource, out *api.GitRepoVolumeSource, s conversion.Scope) error { return autoConvert_v1_GitRepoVolumeSource_To_api_GitRepoVolumeSource(in, out, s) } @@ -1472,6 +1697,7 @@ func autoConvert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(in *api.GitRe return nil } +// Convert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource is an autogenerated conversion function. func Convert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(in *api.GitRepoVolumeSource, out *GitRepoVolumeSource, s conversion.Scope) error { return autoConvert_api_GitRepoVolumeSource_To_v1_GitRepoVolumeSource(in, out, s) } @@ -1483,6 +1709,7 @@ func autoConvert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(in *Glust return nil } +// Convert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource is an autogenerated conversion function. func Convert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(in *GlusterfsVolumeSource, out *api.GlusterfsVolumeSource, s conversion.Scope) error { return autoConvert_v1_GlusterfsVolumeSource_To_api_GlusterfsVolumeSource(in, out, s) } @@ -1494,6 +1721,7 @@ func autoConvert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(in *api.G return nil } +// Convert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource is an autogenerated conversion function. func Convert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(in *api.GlusterfsVolumeSource, out *GlusterfsVolumeSource, s conversion.Scope) error { return autoConvert_api_GlusterfsVolumeSource_To_v1_GlusterfsVolumeSource(in, out, s) } @@ -1507,6 +1735,7 @@ func autoConvert_v1_HTTPGetAction_To_api_HTTPGetAction(in *HTTPGetAction, out *a return nil } +// Convert_v1_HTTPGetAction_To_api_HTTPGetAction is an autogenerated conversion function. func Convert_v1_HTTPGetAction_To_api_HTTPGetAction(in *HTTPGetAction, out *api.HTTPGetAction, s conversion.Scope) error { return autoConvert_v1_HTTPGetAction_To_api_HTTPGetAction(in, out, s) } @@ -1520,6 +1749,7 @@ func autoConvert_api_HTTPGetAction_To_v1_HTTPGetAction(in *api.HTTPGetAction, ou return nil } +// Convert_api_HTTPGetAction_To_v1_HTTPGetAction is an autogenerated conversion function. func Convert_api_HTTPGetAction_To_v1_HTTPGetAction(in *api.HTTPGetAction, out *HTTPGetAction, s conversion.Scope) error { return autoConvert_api_HTTPGetAction_To_v1_HTTPGetAction(in, out, s) } @@ -1530,6 +1760,7 @@ func autoConvert_v1_HTTPHeader_To_api_HTTPHeader(in *HTTPHeader, out *api.HTTPHe return nil } +// Convert_v1_HTTPHeader_To_api_HTTPHeader is an autogenerated conversion function. func Convert_v1_HTTPHeader_To_api_HTTPHeader(in *HTTPHeader, out *api.HTTPHeader, s conversion.Scope) error { return autoConvert_v1_HTTPHeader_To_api_HTTPHeader(in, out, s) } @@ -1540,6 +1771,7 @@ func autoConvert_api_HTTPHeader_To_v1_HTTPHeader(in *api.HTTPHeader, out *HTTPHe return nil } +// Convert_api_HTTPHeader_To_v1_HTTPHeader is an autogenerated conversion function. func Convert_api_HTTPHeader_To_v1_HTTPHeader(in *api.HTTPHeader, out *HTTPHeader, s conversion.Scope) error { return autoConvert_api_HTTPHeader_To_v1_HTTPHeader(in, out, s) } @@ -1551,6 +1783,7 @@ func autoConvert_v1_Handler_To_api_Handler(in *Handler, out *api.Handler, s conv return nil } +// Convert_v1_Handler_To_api_Handler is an autogenerated conversion function. func Convert_v1_Handler_To_api_Handler(in *Handler, out *api.Handler, s conversion.Scope) error { return autoConvert_v1_Handler_To_api_Handler(in, out, s) } @@ -1562,15 +1795,39 @@ func autoConvert_api_Handler_To_v1_Handler(in *api.Handler, out *Handler, s conv return nil } +// Convert_api_Handler_To_v1_Handler is an autogenerated conversion function. func Convert_api_Handler_To_v1_Handler(in *api.Handler, out *Handler, s conversion.Scope) error { return autoConvert_api_Handler_To_v1_Handler(in, out, s) } +func autoConvert_v1_HostAlias_To_api_HostAlias(in *HostAlias, out *api.HostAlias, s conversion.Scope) error { + out.IP = in.IP + out.Hostnames = *(*[]string)(unsafe.Pointer(&in.Hostnames)) + return nil +} + +// Convert_v1_HostAlias_To_api_HostAlias is an autogenerated conversion function. +func Convert_v1_HostAlias_To_api_HostAlias(in *HostAlias, out *api.HostAlias, s conversion.Scope) error { + return autoConvert_v1_HostAlias_To_api_HostAlias(in, out, s) +} + +func autoConvert_api_HostAlias_To_v1_HostAlias(in *api.HostAlias, out *HostAlias, s conversion.Scope) error { + out.IP = in.IP + out.Hostnames = *(*[]string)(unsafe.Pointer(&in.Hostnames)) + return nil +} + +// Convert_api_HostAlias_To_v1_HostAlias is an autogenerated conversion function. +func Convert_api_HostAlias_To_v1_HostAlias(in *api.HostAlias, out *HostAlias, s conversion.Scope) error { + return autoConvert_api_HostAlias_To_v1_HostAlias(in, out, s) +} + func autoConvert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(in *HostPathVolumeSource, out *api.HostPathVolumeSource, s conversion.Scope) error { out.Path = in.Path return nil } +// Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource is an autogenerated conversion function. func Convert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(in *HostPathVolumeSource, out *api.HostPathVolumeSource, s conversion.Scope) error { return autoConvert_v1_HostPathVolumeSource_To_api_HostPathVolumeSource(in, out, s) } @@ -1580,6 +1837,7 @@ func autoConvert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(in *api.Hos return nil } +// Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource is an autogenerated conversion function. func Convert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(in *api.HostPathVolumeSource, out *HostPathVolumeSource, s conversion.Scope) error { return autoConvert_api_HostPathVolumeSource_To_v1_HostPathVolumeSource(in, out, s) } @@ -1591,9 +1849,14 @@ func autoConvert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(in *ISCSIVolumeSo out.ISCSIInterface = in.ISCSIInterface out.FSType = in.FSType out.ReadOnly = in.ReadOnly + out.Portals = *(*[]string)(unsafe.Pointer(&in.Portals)) + out.DiscoveryCHAPAuth = in.DiscoveryCHAPAuth + out.SessionCHAPAuth = in.SessionCHAPAuth + out.SecretRef = (*api.LocalObjectReference)(unsafe.Pointer(in.SecretRef)) return nil } +// Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource is an autogenerated conversion function. func Convert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(in *ISCSIVolumeSource, out *api.ISCSIVolumeSource, s conversion.Scope) error { return autoConvert_v1_ISCSIVolumeSource_To_api_ISCSIVolumeSource(in, out, s) } @@ -1605,9 +1868,14 @@ func autoConvert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(in *api.ISCSIVolu out.ISCSIInterface = in.ISCSIInterface out.FSType = in.FSType out.ReadOnly = in.ReadOnly + out.Portals = *(*[]string)(unsafe.Pointer(&in.Portals)) + out.DiscoveryCHAPAuth = in.DiscoveryCHAPAuth + out.SessionCHAPAuth = in.SessionCHAPAuth + out.SecretRef = (*LocalObjectReference)(unsafe.Pointer(in.SecretRef)) return nil } +// Convert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource is an autogenerated conversion function. func Convert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(in *api.ISCSIVolumeSource, out *ISCSIVolumeSource, s conversion.Scope) error { return autoConvert_api_ISCSIVolumeSource_To_v1_ISCSIVolumeSource(in, out, s) } @@ -1619,6 +1887,7 @@ func autoConvert_v1_KeyToPath_To_api_KeyToPath(in *KeyToPath, out *api.KeyToPath return nil } +// Convert_v1_KeyToPath_To_api_KeyToPath is an autogenerated conversion function. func Convert_v1_KeyToPath_To_api_KeyToPath(in *KeyToPath, out *api.KeyToPath, s conversion.Scope) error { return autoConvert_v1_KeyToPath_To_api_KeyToPath(in, out, s) } @@ -1630,6 +1899,7 @@ func autoConvert_api_KeyToPath_To_v1_KeyToPath(in *api.KeyToPath, out *KeyToPath return nil } +// Convert_api_KeyToPath_To_v1_KeyToPath is an autogenerated conversion function. func Convert_api_KeyToPath_To_v1_KeyToPath(in *api.KeyToPath, out *KeyToPath, s conversion.Scope) error { return autoConvert_api_KeyToPath_To_v1_KeyToPath(in, out, s) } @@ -1640,6 +1910,7 @@ func autoConvert_v1_Lifecycle_To_api_Lifecycle(in *Lifecycle, out *api.Lifecycle return nil } +// Convert_v1_Lifecycle_To_api_Lifecycle is an autogenerated conversion function. func Convert_v1_Lifecycle_To_api_Lifecycle(in *Lifecycle, out *api.Lifecycle, s conversion.Scope) error { return autoConvert_v1_Lifecycle_To_api_Lifecycle(in, out, s) } @@ -1650,34 +1921,33 @@ func autoConvert_api_Lifecycle_To_v1_Lifecycle(in *api.Lifecycle, out *Lifecycle return nil } +// Convert_api_Lifecycle_To_v1_Lifecycle is an autogenerated conversion function. func Convert_api_Lifecycle_To_v1_Lifecycle(in *api.Lifecycle, out *Lifecycle, s conversion.Scope) error { return autoConvert_api_Lifecycle_To_v1_Lifecycle(in, out, s) } func autoConvert_v1_LimitRange_To_api_LimitRange(in *LimitRange, out *api.LimitRange, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_LimitRangeSpec_To_api_LimitRangeSpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_v1_LimitRange_To_api_LimitRange is an autogenerated conversion function. func Convert_v1_LimitRange_To_api_LimitRange(in *LimitRange, out *api.LimitRange, s conversion.Scope) error { return autoConvert_v1_LimitRange_To_api_LimitRange(in, out, s) } func autoConvert_api_LimitRange_To_v1_LimitRange(in *api.LimitRange, out *LimitRange, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_LimitRangeSpec_To_v1_LimitRangeSpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_api_LimitRange_To_v1_LimitRange is an autogenerated conversion function. func Convert_api_LimitRange_To_v1_LimitRange(in *api.LimitRange, out *LimitRange, s conversion.Scope) error { return autoConvert_api_LimitRange_To_v1_LimitRange(in, out, s) } @@ -1692,6 +1962,7 @@ func autoConvert_v1_LimitRangeItem_To_api_LimitRangeItem(in *LimitRangeItem, out return nil } +// Convert_v1_LimitRangeItem_To_api_LimitRangeItem is an autogenerated conversion function. func Convert_v1_LimitRangeItem_To_api_LimitRangeItem(in *LimitRangeItem, out *api.LimitRangeItem, s conversion.Scope) error { return autoConvert_v1_LimitRangeItem_To_api_LimitRangeItem(in, out, s) } @@ -1706,6 +1977,7 @@ func autoConvert_api_LimitRangeItem_To_v1_LimitRangeItem(in *api.LimitRangeItem, return nil } +// Convert_api_LimitRangeItem_To_v1_LimitRangeItem is an autogenerated conversion function. func Convert_api_LimitRangeItem_To_v1_LimitRangeItem(in *api.LimitRangeItem, out *LimitRangeItem, s conversion.Scope) error { return autoConvert_api_LimitRangeItem_To_v1_LimitRangeItem(in, out, s) } @@ -1716,16 +1988,22 @@ func autoConvert_v1_LimitRangeList_To_api_LimitRangeList(in *LimitRangeList, out return nil } +// Convert_v1_LimitRangeList_To_api_LimitRangeList is an autogenerated conversion function. func Convert_v1_LimitRangeList_To_api_LimitRangeList(in *LimitRangeList, out *api.LimitRangeList, s conversion.Scope) error { return autoConvert_v1_LimitRangeList_To_api_LimitRangeList(in, out, s) } func autoConvert_api_LimitRangeList_To_v1_LimitRangeList(in *api.LimitRangeList, out *LimitRangeList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]LimitRange)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]LimitRange, 0) + } else { + out.Items = *(*[]LimitRange)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_LimitRangeList_To_v1_LimitRangeList is an autogenerated conversion function. func Convert_api_LimitRangeList_To_v1_LimitRangeList(in *api.LimitRangeList, out *LimitRangeList, s conversion.Scope) error { return autoConvert_api_LimitRangeList_To_v1_LimitRangeList(in, out, s) } @@ -1735,15 +2013,21 @@ func autoConvert_v1_LimitRangeSpec_To_api_LimitRangeSpec(in *LimitRangeSpec, out return nil } +// Convert_v1_LimitRangeSpec_To_api_LimitRangeSpec is an autogenerated conversion function. func Convert_v1_LimitRangeSpec_To_api_LimitRangeSpec(in *LimitRangeSpec, out *api.LimitRangeSpec, s conversion.Scope) error { return autoConvert_v1_LimitRangeSpec_To_api_LimitRangeSpec(in, out, s) } func autoConvert_api_LimitRangeSpec_To_v1_LimitRangeSpec(in *api.LimitRangeSpec, out *LimitRangeSpec, s conversion.Scope) error { - out.Limits = *(*[]LimitRangeItem)(unsafe.Pointer(&in.Limits)) + if in.Limits == nil { + out.Limits = make([]LimitRangeItem, 0) + } else { + out.Limits = *(*[]LimitRangeItem)(unsafe.Pointer(&in.Limits)) + } return nil } +// Convert_api_LimitRangeSpec_To_v1_LimitRangeSpec is an autogenerated conversion function. func Convert_api_LimitRangeSpec_To_v1_LimitRangeSpec(in *api.LimitRangeSpec, out *LimitRangeSpec, s conversion.Scope) error { return autoConvert_api_LimitRangeSpec_To_v1_LimitRangeSpec(in, out, s) } @@ -1764,6 +2048,7 @@ func autoConvert_v1_List_To_api_List(in *List, out *api.List, s conversion.Scope return nil } +// Convert_v1_List_To_api_List is an autogenerated conversion function. func Convert_v1_List_To_api_List(in *List, out *api.List, s conversion.Scope) error { return autoConvert_v1_List_To_api_List(in, out, s) } @@ -1779,45 +2064,50 @@ func autoConvert_api_List_To_v1_List(in *api.List, out *List, s conversion.Scope } } } else { - out.Items = nil + out.Items = make([]runtime.RawExtension, 0) } return nil } +// Convert_api_List_To_v1_List is an autogenerated conversion function. func Convert_api_List_To_v1_List(in *api.List, out *List, s conversion.Scope) error { return autoConvert_api_List_To_v1_List(in, out, s) } func autoConvert_v1_ListOptions_To_api_ListOptions(in *ListOptions, out *api.ListOptions, s conversion.Scope) error { - if err := api.Convert_string_To_labels_Selector(&in.LabelSelector, &out.LabelSelector, s); err != nil { + if err := meta_v1.Convert_string_To_labels_Selector(&in.LabelSelector, &out.LabelSelector, s); err != nil { return err } - if err := api.Convert_string_To_fields_Selector(&in.FieldSelector, &out.FieldSelector, s); err != nil { + if err := meta_v1.Convert_string_To_fields_Selector(&in.FieldSelector, &out.FieldSelector, s); err != nil { return err } + out.IncludeUninitialized = in.IncludeUninitialized out.Watch = in.Watch out.ResourceVersion = in.ResourceVersion out.TimeoutSeconds = (*int64)(unsafe.Pointer(in.TimeoutSeconds)) return nil } +// Convert_v1_ListOptions_To_api_ListOptions is an autogenerated conversion function. func Convert_v1_ListOptions_To_api_ListOptions(in *ListOptions, out *api.ListOptions, s conversion.Scope) error { return autoConvert_v1_ListOptions_To_api_ListOptions(in, out, s) } func autoConvert_api_ListOptions_To_v1_ListOptions(in *api.ListOptions, out *ListOptions, s conversion.Scope) error { - if err := api.Convert_labels_Selector_To_string(&in.LabelSelector, &out.LabelSelector, s); err != nil { + if err := meta_v1.Convert_labels_Selector_To_string(&in.LabelSelector, &out.LabelSelector, s); err != nil { return err } - if err := api.Convert_fields_Selector_To_string(&in.FieldSelector, &out.FieldSelector, s); err != nil { + if err := meta_v1.Convert_fields_Selector_To_string(&in.FieldSelector, &out.FieldSelector, s); err != nil { return err } + out.IncludeUninitialized = in.IncludeUninitialized out.Watch = in.Watch out.ResourceVersion = in.ResourceVersion out.TimeoutSeconds = (*int64)(unsafe.Pointer(in.TimeoutSeconds)) return nil } +// Convert_api_ListOptions_To_v1_ListOptions is an autogenerated conversion function. func Convert_api_ListOptions_To_v1_ListOptions(in *api.ListOptions, out *ListOptions, s conversion.Scope) error { return autoConvert_api_ListOptions_To_v1_ListOptions(in, out, s) } @@ -1828,6 +2118,7 @@ func autoConvert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(in *LoadBalan return nil } +// Convert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress is an autogenerated conversion function. func Convert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(in *LoadBalancerIngress, out *api.LoadBalancerIngress, s conversion.Scope) error { return autoConvert_v1_LoadBalancerIngress_To_api_LoadBalancerIngress(in, out, s) } @@ -1838,6 +2129,7 @@ func autoConvert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(in *api.LoadB return nil } +// Convert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress is an autogenerated conversion function. func Convert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(in *api.LoadBalancerIngress, out *LoadBalancerIngress, s conversion.Scope) error { return autoConvert_api_LoadBalancerIngress_To_v1_LoadBalancerIngress(in, out, s) } @@ -1847,6 +2139,7 @@ func autoConvert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(in *LoadBalance return nil } +// Convert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus is an autogenerated conversion function. func Convert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(in *LoadBalancerStatus, out *api.LoadBalancerStatus, s conversion.Scope) error { return autoConvert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(in, out, s) } @@ -1856,6 +2149,7 @@ func autoConvert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(in *api.LoadBal return nil } +// Convert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus is an autogenerated conversion function. func Convert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(in *api.LoadBalancerStatus, out *LoadBalancerStatus, s conversion.Scope) error { return autoConvert_api_LoadBalancerStatus_To_v1_LoadBalancerStatus(in, out, s) } @@ -1865,6 +2159,7 @@ func autoConvert_v1_LocalObjectReference_To_api_LocalObjectReference(in *LocalOb return nil } +// Convert_v1_LocalObjectReference_To_api_LocalObjectReference is an autogenerated conversion function. func Convert_v1_LocalObjectReference_To_api_LocalObjectReference(in *LocalObjectReference, out *api.LocalObjectReference, s conversion.Scope) error { return autoConvert_v1_LocalObjectReference_To_api_LocalObjectReference(in, out, s) } @@ -1874,10 +2169,31 @@ func autoConvert_api_LocalObjectReference_To_v1_LocalObjectReference(in *api.Loc return nil } +// Convert_api_LocalObjectReference_To_v1_LocalObjectReference is an autogenerated conversion function. func Convert_api_LocalObjectReference_To_v1_LocalObjectReference(in *api.LocalObjectReference, out *LocalObjectReference, s conversion.Scope) error { return autoConvert_api_LocalObjectReference_To_v1_LocalObjectReference(in, out, s) } +func autoConvert_v1_LocalVolumeSource_To_api_LocalVolumeSource(in *LocalVolumeSource, out *api.LocalVolumeSource, s conversion.Scope) error { + out.Path = in.Path + return nil +} + +// Convert_v1_LocalVolumeSource_To_api_LocalVolumeSource is an autogenerated conversion function. +func Convert_v1_LocalVolumeSource_To_api_LocalVolumeSource(in *LocalVolumeSource, out *api.LocalVolumeSource, s conversion.Scope) error { + return autoConvert_v1_LocalVolumeSource_To_api_LocalVolumeSource(in, out, s) +} + +func autoConvert_api_LocalVolumeSource_To_v1_LocalVolumeSource(in *api.LocalVolumeSource, out *LocalVolumeSource, s conversion.Scope) error { + out.Path = in.Path + return nil +} + +// Convert_api_LocalVolumeSource_To_v1_LocalVolumeSource is an autogenerated conversion function. +func Convert_api_LocalVolumeSource_To_v1_LocalVolumeSource(in *api.LocalVolumeSource, out *LocalVolumeSource, s conversion.Scope) error { + return autoConvert_api_LocalVolumeSource_To_v1_LocalVolumeSource(in, out, s) +} + func autoConvert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in *NFSVolumeSource, out *api.NFSVolumeSource, s conversion.Scope) error { out.Server = in.Server out.Path = in.Path @@ -1885,6 +2201,7 @@ func autoConvert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in *NFSVolumeSource, return nil } +// Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource is an autogenerated conversion function. func Convert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in *NFSVolumeSource, out *api.NFSVolumeSource, s conversion.Scope) error { return autoConvert_v1_NFSVolumeSource_To_api_NFSVolumeSource(in, out, s) } @@ -1896,14 +2213,13 @@ func autoConvert_api_NFSVolumeSource_To_v1_NFSVolumeSource(in *api.NFSVolumeSour return nil } +// Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource is an autogenerated conversion function. func Convert_api_NFSVolumeSource_To_v1_NFSVolumeSource(in *api.NFSVolumeSource, out *NFSVolumeSource, s conversion.Scope) error { return autoConvert_api_NFSVolumeSource_To_v1_NFSVolumeSource(in, out, s) } func autoConvert_v1_Namespace_To_api_Namespace(in *Namespace, out *api.Namespace, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_NamespaceSpec_To_api_NamespaceSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -1913,14 +2229,13 @@ func autoConvert_v1_Namespace_To_api_Namespace(in *Namespace, out *api.Namespace return nil } +// Convert_v1_Namespace_To_api_Namespace is an autogenerated conversion function. func Convert_v1_Namespace_To_api_Namespace(in *Namespace, out *api.Namespace, s conversion.Scope) error { return autoConvert_v1_Namespace_To_api_Namespace(in, out, s) } func autoConvert_api_Namespace_To_v1_Namespace(in *api.Namespace, out *Namespace, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_NamespaceSpec_To_v1_NamespaceSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -1930,6 +2245,7 @@ func autoConvert_api_Namespace_To_v1_Namespace(in *api.Namespace, out *Namespace return nil } +// Convert_api_Namespace_To_v1_Namespace is an autogenerated conversion function. func Convert_api_Namespace_To_v1_Namespace(in *api.Namespace, out *Namespace, s conversion.Scope) error { return autoConvert_api_Namespace_To_v1_Namespace(in, out, s) } @@ -1940,16 +2256,22 @@ func autoConvert_v1_NamespaceList_To_api_NamespaceList(in *NamespaceList, out *a return nil } +// Convert_v1_NamespaceList_To_api_NamespaceList is an autogenerated conversion function. func Convert_v1_NamespaceList_To_api_NamespaceList(in *NamespaceList, out *api.NamespaceList, s conversion.Scope) error { return autoConvert_v1_NamespaceList_To_api_NamespaceList(in, out, s) } func autoConvert_api_NamespaceList_To_v1_NamespaceList(in *api.NamespaceList, out *NamespaceList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]Namespace)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]Namespace, 0) + } else { + out.Items = *(*[]Namespace)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_NamespaceList_To_v1_NamespaceList is an autogenerated conversion function. func Convert_api_NamespaceList_To_v1_NamespaceList(in *api.NamespaceList, out *NamespaceList, s conversion.Scope) error { return autoConvert_api_NamespaceList_To_v1_NamespaceList(in, out, s) } @@ -1959,6 +2281,7 @@ func autoConvert_v1_NamespaceSpec_To_api_NamespaceSpec(in *NamespaceSpec, out *a return nil } +// Convert_v1_NamespaceSpec_To_api_NamespaceSpec is an autogenerated conversion function. func Convert_v1_NamespaceSpec_To_api_NamespaceSpec(in *NamespaceSpec, out *api.NamespaceSpec, s conversion.Scope) error { return autoConvert_v1_NamespaceSpec_To_api_NamespaceSpec(in, out, s) } @@ -1968,6 +2291,7 @@ func autoConvert_api_NamespaceSpec_To_v1_NamespaceSpec(in *api.NamespaceSpec, ou return nil } +// Convert_api_NamespaceSpec_To_v1_NamespaceSpec is an autogenerated conversion function. func Convert_api_NamespaceSpec_To_v1_NamespaceSpec(in *api.NamespaceSpec, out *NamespaceSpec, s conversion.Scope) error { return autoConvert_api_NamespaceSpec_To_v1_NamespaceSpec(in, out, s) } @@ -1977,6 +2301,7 @@ func autoConvert_v1_NamespaceStatus_To_api_NamespaceStatus(in *NamespaceStatus, return nil } +// Convert_v1_NamespaceStatus_To_api_NamespaceStatus is an autogenerated conversion function. func Convert_v1_NamespaceStatus_To_api_NamespaceStatus(in *NamespaceStatus, out *api.NamespaceStatus, s conversion.Scope) error { return autoConvert_v1_NamespaceStatus_To_api_NamespaceStatus(in, out, s) } @@ -1986,14 +2311,13 @@ func autoConvert_api_NamespaceStatus_To_v1_NamespaceStatus(in *api.NamespaceStat return nil } +// Convert_api_NamespaceStatus_To_v1_NamespaceStatus is an autogenerated conversion function. func Convert_api_NamespaceStatus_To_v1_NamespaceStatus(in *api.NamespaceStatus, out *NamespaceStatus, s conversion.Scope) error { return autoConvert_api_NamespaceStatus_To_v1_NamespaceStatus(in, out, s) } func autoConvert_v1_Node_To_api_Node(in *Node, out *api.Node, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_NodeSpec_To_api_NodeSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2003,14 +2327,13 @@ func autoConvert_v1_Node_To_api_Node(in *Node, out *api.Node, s conversion.Scope return nil } +// Convert_v1_Node_To_api_Node is an autogenerated conversion function. func Convert_v1_Node_To_api_Node(in *Node, out *api.Node, s conversion.Scope) error { return autoConvert_v1_Node_To_api_Node(in, out, s) } func autoConvert_api_Node_To_v1_Node(in *api.Node, out *Node, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_NodeSpec_To_v1_NodeSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2020,6 +2343,7 @@ func autoConvert_api_Node_To_v1_Node(in *api.Node, out *Node, s conversion.Scope return nil } +// Convert_api_Node_To_v1_Node is an autogenerated conversion function. func Convert_api_Node_To_v1_Node(in *api.Node, out *Node, s conversion.Scope) error { return autoConvert_api_Node_To_v1_Node(in, out, s) } @@ -2030,6 +2354,7 @@ func autoConvert_v1_NodeAddress_To_api_NodeAddress(in *NodeAddress, out *api.Nod return nil } +// Convert_v1_NodeAddress_To_api_NodeAddress is an autogenerated conversion function. func Convert_v1_NodeAddress_To_api_NodeAddress(in *NodeAddress, out *api.NodeAddress, s conversion.Scope) error { return autoConvert_v1_NodeAddress_To_api_NodeAddress(in, out, s) } @@ -2040,6 +2365,7 @@ func autoConvert_api_NodeAddress_To_v1_NodeAddress(in *api.NodeAddress, out *Nod return nil } +// Convert_api_NodeAddress_To_v1_NodeAddress is an autogenerated conversion function. func Convert_api_NodeAddress_To_v1_NodeAddress(in *api.NodeAddress, out *NodeAddress, s conversion.Scope) error { return autoConvert_api_NodeAddress_To_v1_NodeAddress(in, out, s) } @@ -2050,6 +2376,7 @@ func autoConvert_v1_NodeAffinity_To_api_NodeAffinity(in *NodeAffinity, out *api. return nil } +// Convert_v1_NodeAffinity_To_api_NodeAffinity is an autogenerated conversion function. func Convert_v1_NodeAffinity_To_api_NodeAffinity(in *NodeAffinity, out *api.NodeAffinity, s conversion.Scope) error { return autoConvert_v1_NodeAffinity_To_api_NodeAffinity(in, out, s) } @@ -2060,6 +2387,7 @@ func autoConvert_api_NodeAffinity_To_v1_NodeAffinity(in *api.NodeAffinity, out * return nil } +// Convert_api_NodeAffinity_To_v1_NodeAffinity is an autogenerated conversion function. func Convert_api_NodeAffinity_To_v1_NodeAffinity(in *api.NodeAffinity, out *NodeAffinity, s conversion.Scope) error { return autoConvert_api_NodeAffinity_To_v1_NodeAffinity(in, out, s) } @@ -2074,6 +2402,7 @@ func autoConvert_v1_NodeCondition_To_api_NodeCondition(in *NodeCondition, out *a return nil } +// Convert_v1_NodeCondition_To_api_NodeCondition is an autogenerated conversion function. func Convert_v1_NodeCondition_To_api_NodeCondition(in *NodeCondition, out *api.NodeCondition, s conversion.Scope) error { return autoConvert_v1_NodeCondition_To_api_NodeCondition(in, out, s) } @@ -2088,6 +2417,7 @@ func autoConvert_api_NodeCondition_To_v1_NodeCondition(in *api.NodeCondition, ou return nil } +// Convert_api_NodeCondition_To_v1_NodeCondition is an autogenerated conversion function. func Convert_api_NodeCondition_To_v1_NodeCondition(in *api.NodeCondition, out *NodeCondition, s conversion.Scope) error { return autoConvert_api_NodeCondition_To_v1_NodeCondition(in, out, s) } @@ -2099,6 +2429,7 @@ func autoConvert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(in *NodeDaemo return nil } +// Convert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints is an autogenerated conversion function. func Convert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(in *NodeDaemonEndpoints, out *api.NodeDaemonEndpoints, s conversion.Scope) error { return autoConvert_v1_NodeDaemonEndpoints_To_api_NodeDaemonEndpoints(in, out, s) } @@ -2110,6 +2441,7 @@ func autoConvert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(in *api.NodeD return nil } +// Convert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints is an autogenerated conversion function. func Convert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(in *api.NodeDaemonEndpoints, out *NodeDaemonEndpoints, s conversion.Scope) error { return autoConvert_api_NodeDaemonEndpoints_To_v1_NodeDaemonEndpoints(in, out, s) } @@ -2120,16 +2452,22 @@ func autoConvert_v1_NodeList_To_api_NodeList(in *NodeList, out *api.NodeList, s return nil } +// Convert_v1_NodeList_To_api_NodeList is an autogenerated conversion function. func Convert_v1_NodeList_To_api_NodeList(in *NodeList, out *api.NodeList, s conversion.Scope) error { return autoConvert_v1_NodeList_To_api_NodeList(in, out, s) } func autoConvert_api_NodeList_To_v1_NodeList(in *api.NodeList, out *NodeList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]Node)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]Node, 0) + } else { + out.Items = *(*[]Node)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_NodeList_To_v1_NodeList is an autogenerated conversion function. func Convert_api_NodeList_To_v1_NodeList(in *api.NodeList, out *NodeList, s conversion.Scope) error { return autoConvert_api_NodeList_To_v1_NodeList(in, out, s) } @@ -2139,6 +2477,7 @@ func autoConvert_v1_NodeProxyOptions_To_api_NodeProxyOptions(in *NodeProxyOption return nil } +// Convert_v1_NodeProxyOptions_To_api_NodeProxyOptions is an autogenerated conversion function. func Convert_v1_NodeProxyOptions_To_api_NodeProxyOptions(in *NodeProxyOptions, out *api.NodeProxyOptions, s conversion.Scope) error { return autoConvert_v1_NodeProxyOptions_To_api_NodeProxyOptions(in, out, s) } @@ -2148,24 +2487,51 @@ func autoConvert_api_NodeProxyOptions_To_v1_NodeProxyOptions(in *api.NodeProxyOp return nil } +// Convert_api_NodeProxyOptions_To_v1_NodeProxyOptions is an autogenerated conversion function. func Convert_api_NodeProxyOptions_To_v1_NodeProxyOptions(in *api.NodeProxyOptions, out *NodeProxyOptions, s conversion.Scope) error { return autoConvert_api_NodeProxyOptions_To_v1_NodeProxyOptions(in, out, s) } +func autoConvert_v1_NodeResources_To_api_NodeResources(in *NodeResources, out *api.NodeResources, s conversion.Scope) error { + out.Capacity = *(*api.ResourceList)(unsafe.Pointer(&in.Capacity)) + return nil +} + +// Convert_v1_NodeResources_To_api_NodeResources is an autogenerated conversion function. +func Convert_v1_NodeResources_To_api_NodeResources(in *NodeResources, out *api.NodeResources, s conversion.Scope) error { + return autoConvert_v1_NodeResources_To_api_NodeResources(in, out, s) +} + +func autoConvert_api_NodeResources_To_v1_NodeResources(in *api.NodeResources, out *NodeResources, s conversion.Scope) error { + out.Capacity = *(*ResourceList)(unsafe.Pointer(&in.Capacity)) + return nil +} + +// Convert_api_NodeResources_To_v1_NodeResources is an autogenerated conversion function. +func Convert_api_NodeResources_To_v1_NodeResources(in *api.NodeResources, out *NodeResources, s conversion.Scope) error { + return autoConvert_api_NodeResources_To_v1_NodeResources(in, out, s) +} + func autoConvert_v1_NodeSelector_To_api_NodeSelector(in *NodeSelector, out *api.NodeSelector, s conversion.Scope) error { out.NodeSelectorTerms = *(*[]api.NodeSelectorTerm)(unsafe.Pointer(&in.NodeSelectorTerms)) return nil } +// Convert_v1_NodeSelector_To_api_NodeSelector is an autogenerated conversion function. func Convert_v1_NodeSelector_To_api_NodeSelector(in *NodeSelector, out *api.NodeSelector, s conversion.Scope) error { return autoConvert_v1_NodeSelector_To_api_NodeSelector(in, out, s) } func autoConvert_api_NodeSelector_To_v1_NodeSelector(in *api.NodeSelector, out *NodeSelector, s conversion.Scope) error { - out.NodeSelectorTerms = *(*[]NodeSelectorTerm)(unsafe.Pointer(&in.NodeSelectorTerms)) + if in.NodeSelectorTerms == nil { + out.NodeSelectorTerms = make([]NodeSelectorTerm, 0) + } else { + out.NodeSelectorTerms = *(*[]NodeSelectorTerm)(unsafe.Pointer(&in.NodeSelectorTerms)) + } return nil } +// Convert_api_NodeSelector_To_v1_NodeSelector is an autogenerated conversion function. func Convert_api_NodeSelector_To_v1_NodeSelector(in *api.NodeSelector, out *NodeSelector, s conversion.Scope) error { return autoConvert_api_NodeSelector_To_v1_NodeSelector(in, out, s) } @@ -2177,6 +2543,7 @@ func autoConvert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(in *N return nil } +// Convert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement is an autogenerated conversion function. func Convert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(in *NodeSelectorRequirement, out *api.NodeSelectorRequirement, s conversion.Scope) error { return autoConvert_v1_NodeSelectorRequirement_To_api_NodeSelectorRequirement(in, out, s) } @@ -2188,6 +2555,7 @@ func autoConvert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(in *a return nil } +// Convert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement is an autogenerated conversion function. func Convert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(in *api.NodeSelectorRequirement, out *NodeSelectorRequirement, s conversion.Scope) error { return autoConvert_api_NodeSelectorRequirement_To_v1_NodeSelectorRequirement(in, out, s) } @@ -2197,15 +2565,21 @@ func autoConvert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(in *NodeSelectorTer return nil } +// Convert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm is an autogenerated conversion function. func Convert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(in *NodeSelectorTerm, out *api.NodeSelectorTerm, s conversion.Scope) error { return autoConvert_v1_NodeSelectorTerm_To_api_NodeSelectorTerm(in, out, s) } func autoConvert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(in *api.NodeSelectorTerm, out *NodeSelectorTerm, s conversion.Scope) error { - out.MatchExpressions = *(*[]NodeSelectorRequirement)(unsafe.Pointer(&in.MatchExpressions)) + if in.MatchExpressions == nil { + out.MatchExpressions = make([]NodeSelectorRequirement, 0) + } else { + out.MatchExpressions = *(*[]NodeSelectorRequirement)(unsafe.Pointer(&in.MatchExpressions)) + } return nil } +// Convert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm is an autogenerated conversion function. func Convert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(in *api.NodeSelectorTerm, out *NodeSelectorTerm, s conversion.Scope) error { return autoConvert_api_NodeSelectorTerm_To_v1_NodeSelectorTerm(in, out, s) } @@ -2215,9 +2589,11 @@ func autoConvert_v1_NodeSpec_To_api_NodeSpec(in *NodeSpec, out *api.NodeSpec, s out.ExternalID = in.ExternalID out.ProviderID = in.ProviderID out.Unschedulable = in.Unschedulable + out.Taints = *(*[]api.Taint)(unsafe.Pointer(&in.Taints)) return nil } +// Convert_v1_NodeSpec_To_api_NodeSpec is an autogenerated conversion function. func Convert_v1_NodeSpec_To_api_NodeSpec(in *NodeSpec, out *api.NodeSpec, s conversion.Scope) error { return autoConvert_v1_NodeSpec_To_api_NodeSpec(in, out, s) } @@ -2227,9 +2603,11 @@ func autoConvert_api_NodeSpec_To_v1_NodeSpec(in *api.NodeSpec, out *NodeSpec, s out.ExternalID = in.ExternalID out.ProviderID = in.ProviderID out.Unschedulable = in.Unschedulable + out.Taints = *(*[]Taint)(unsafe.Pointer(&in.Taints)) return nil } +// Convert_api_NodeSpec_To_v1_NodeSpec is an autogenerated conversion function. func Convert_api_NodeSpec_To_v1_NodeSpec(in *api.NodeSpec, out *NodeSpec, s conversion.Scope) error { return autoConvert_api_NodeSpec_To_v1_NodeSpec(in, out, s) } @@ -2252,6 +2630,7 @@ func autoConvert_v1_NodeStatus_To_api_NodeStatus(in *NodeStatus, out *api.NodeSt return nil } +// Convert_v1_NodeStatus_To_api_NodeStatus is an autogenerated conversion function. func Convert_v1_NodeStatus_To_api_NodeStatus(in *NodeStatus, out *api.NodeStatus, s conversion.Scope) error { return autoConvert_v1_NodeStatus_To_api_NodeStatus(in, out, s) } @@ -2274,6 +2653,7 @@ func autoConvert_api_NodeStatus_To_v1_NodeStatus(in *api.NodeStatus, out *NodeSt return nil } +// Convert_api_NodeStatus_To_v1_NodeStatus is an autogenerated conversion function. func Convert_api_NodeStatus_To_v1_NodeStatus(in *api.NodeStatus, out *NodeStatus, s conversion.Scope) error { return autoConvert_api_NodeStatus_To_v1_NodeStatus(in, out, s) } @@ -2292,6 +2672,7 @@ func autoConvert_v1_NodeSystemInfo_To_api_NodeSystemInfo(in *NodeSystemInfo, out return nil } +// Convert_v1_NodeSystemInfo_To_api_NodeSystemInfo is an autogenerated conversion function. func Convert_v1_NodeSystemInfo_To_api_NodeSystemInfo(in *NodeSystemInfo, out *api.NodeSystemInfo, s conversion.Scope) error { return autoConvert_v1_NodeSystemInfo_To_api_NodeSystemInfo(in, out, s) } @@ -2310,6 +2691,7 @@ func autoConvert_api_NodeSystemInfo_To_v1_NodeSystemInfo(in *api.NodeSystemInfo, return nil } +// Convert_api_NodeSystemInfo_To_v1_NodeSystemInfo is an autogenerated conversion function. func Convert_api_NodeSystemInfo_To_v1_NodeSystemInfo(in *api.NodeSystemInfo, out *NodeSystemInfo, s conversion.Scope) error { return autoConvert_api_NodeSystemInfo_To_v1_NodeSystemInfo(in, out, s) } @@ -2320,6 +2702,7 @@ func autoConvert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(in *ObjectFie return nil } +// Convert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector is an autogenerated conversion function. func Convert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(in *ObjectFieldSelector, out *api.ObjectFieldSelector, s conversion.Scope) error { return autoConvert_v1_ObjectFieldSelector_To_api_ObjectFieldSelector(in, out, s) } @@ -2330,6 +2713,7 @@ func autoConvert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(in *api.Objec return nil } +// Convert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector is an autogenerated conversion function. func Convert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(in *api.ObjectFieldSelector, out *ObjectFieldSelector, s conversion.Scope) error { return autoConvert_api_ObjectFieldSelector_To_v1_ObjectFieldSelector(in, out, s) } @@ -2343,16 +2727,18 @@ func autoConvert_v1_ObjectMeta_To_api_ObjectMeta(in *ObjectMeta, out *api.Object out.ResourceVersion = in.ResourceVersion out.Generation = in.Generation out.CreationTimestamp = in.CreationTimestamp - out.DeletionTimestamp = (*unversioned.Time)(unsafe.Pointer(in.DeletionTimestamp)) + out.DeletionTimestamp = (*meta_v1.Time)(unsafe.Pointer(in.DeletionTimestamp)) out.DeletionGracePeriodSeconds = (*int64)(unsafe.Pointer(in.DeletionGracePeriodSeconds)) out.Labels = *(*map[string]string)(unsafe.Pointer(&in.Labels)) out.Annotations = *(*map[string]string)(unsafe.Pointer(&in.Annotations)) - out.OwnerReferences = *(*[]api.OwnerReference)(unsafe.Pointer(&in.OwnerReferences)) + out.OwnerReferences = *(*[]meta_v1.OwnerReference)(unsafe.Pointer(&in.OwnerReferences)) + out.Initializers = (*meta_v1.Initializers)(unsafe.Pointer(in.Initializers)) out.Finalizers = *(*[]string)(unsafe.Pointer(&in.Finalizers)) out.ClusterName = in.ClusterName return nil } +// Convert_v1_ObjectMeta_To_api_ObjectMeta is an autogenerated conversion function. func Convert_v1_ObjectMeta_To_api_ObjectMeta(in *ObjectMeta, out *api.ObjectMeta, s conversion.Scope) error { return autoConvert_v1_ObjectMeta_To_api_ObjectMeta(in, out, s) } @@ -2366,16 +2752,18 @@ func autoConvert_api_ObjectMeta_To_v1_ObjectMeta(in *api.ObjectMeta, out *Object out.ResourceVersion = in.ResourceVersion out.Generation = in.Generation out.CreationTimestamp = in.CreationTimestamp - out.DeletionTimestamp = (*unversioned.Time)(unsafe.Pointer(in.DeletionTimestamp)) + out.DeletionTimestamp = (*meta_v1.Time)(unsafe.Pointer(in.DeletionTimestamp)) out.DeletionGracePeriodSeconds = (*int64)(unsafe.Pointer(in.DeletionGracePeriodSeconds)) out.Labels = *(*map[string]string)(unsafe.Pointer(&in.Labels)) out.Annotations = *(*map[string]string)(unsafe.Pointer(&in.Annotations)) - out.OwnerReferences = *(*[]OwnerReference)(unsafe.Pointer(&in.OwnerReferences)) + out.OwnerReferences = *(*[]meta_v1.OwnerReference)(unsafe.Pointer(&in.OwnerReferences)) + out.Initializers = (*meta_v1.Initializers)(unsafe.Pointer(in.Initializers)) out.Finalizers = *(*[]string)(unsafe.Pointer(&in.Finalizers)) out.ClusterName = in.ClusterName return nil } +// Convert_api_ObjectMeta_To_v1_ObjectMeta is an autogenerated conversion function. func Convert_api_ObjectMeta_To_v1_ObjectMeta(in *api.ObjectMeta, out *ObjectMeta, s conversion.Scope) error { return autoConvert_api_ObjectMeta_To_v1_ObjectMeta(in, out, s) } @@ -2391,6 +2779,7 @@ func autoConvert_v1_ObjectReference_To_api_ObjectReference(in *ObjectReference, return nil } +// Convert_v1_ObjectReference_To_api_ObjectReference is an autogenerated conversion function. func Convert_v1_ObjectReference_To_api_ObjectReference(in *ObjectReference, out *api.ObjectReference, s conversion.Scope) error { return autoConvert_v1_ObjectReference_To_api_ObjectReference(in, out, s) } @@ -2406,40 +2795,13 @@ func autoConvert_api_ObjectReference_To_v1_ObjectReference(in *api.ObjectReferen return nil } +// Convert_api_ObjectReference_To_v1_ObjectReference is an autogenerated conversion function. func Convert_api_ObjectReference_To_v1_ObjectReference(in *api.ObjectReference, out *ObjectReference, s conversion.Scope) error { return autoConvert_api_ObjectReference_To_v1_ObjectReference(in, out, s) } -func autoConvert_v1_OwnerReference_To_api_OwnerReference(in *OwnerReference, out *api.OwnerReference, s conversion.Scope) error { - out.APIVersion = in.APIVersion - out.Kind = in.Kind - out.Name = in.Name - out.UID = types.UID(in.UID) - out.Controller = (*bool)(unsafe.Pointer(in.Controller)) - return nil -} - -func Convert_v1_OwnerReference_To_api_OwnerReference(in *OwnerReference, out *api.OwnerReference, s conversion.Scope) error { - return autoConvert_v1_OwnerReference_To_api_OwnerReference(in, out, s) -} - -func autoConvert_api_OwnerReference_To_v1_OwnerReference(in *api.OwnerReference, out *OwnerReference, s conversion.Scope) error { - out.APIVersion = in.APIVersion - out.Kind = in.Kind - out.Name = in.Name - out.UID = types.UID(in.UID) - out.Controller = (*bool)(unsafe.Pointer(in.Controller)) - return nil -} - -func Convert_api_OwnerReference_To_v1_OwnerReference(in *api.OwnerReference, out *OwnerReference, s conversion.Scope) error { - return autoConvert_api_OwnerReference_To_v1_OwnerReference(in, out, s) -} - func autoConvert_v1_PersistentVolume_To_api_PersistentVolume(in *PersistentVolume, out *api.PersistentVolume, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2449,14 +2811,13 @@ func autoConvert_v1_PersistentVolume_To_api_PersistentVolume(in *PersistentVolum return nil } +// Convert_v1_PersistentVolume_To_api_PersistentVolume is an autogenerated conversion function. func Convert_v1_PersistentVolume_To_api_PersistentVolume(in *PersistentVolume, out *api.PersistentVolume, s conversion.Scope) error { return autoConvert_v1_PersistentVolume_To_api_PersistentVolume(in, out, s) } func autoConvert_api_PersistentVolume_To_v1_PersistentVolume(in *api.PersistentVolume, out *PersistentVolume, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2466,14 +2827,13 @@ func autoConvert_api_PersistentVolume_To_v1_PersistentVolume(in *api.PersistentV return nil } +// Convert_api_PersistentVolume_To_v1_PersistentVolume is an autogenerated conversion function. func Convert_api_PersistentVolume_To_v1_PersistentVolume(in *api.PersistentVolume, out *PersistentVolume, s conversion.Scope) error { return autoConvert_api_PersistentVolume_To_v1_PersistentVolume(in, out, s) } func autoConvert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in *PersistentVolumeClaim, out *api.PersistentVolumeClaim, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2483,14 +2843,13 @@ func autoConvert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in *Persi return nil } +// Convert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim is an autogenerated conversion function. func Convert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in *PersistentVolumeClaim, out *api.PersistentVolumeClaim, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeClaim_To_api_PersistentVolumeClaim(in, out, s) } func autoConvert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in *api.PersistentVolumeClaim, out *PersistentVolumeClaim, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2500,6 +2859,7 @@ func autoConvert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in *api.P return nil } +// Convert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim is an autogenerated conversion function. func Convert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in *api.PersistentVolumeClaim, out *PersistentVolumeClaim, s conversion.Scope) error { return autoConvert_api_PersistentVolumeClaim_To_v1_PersistentVolumeClaim(in, out, s) } @@ -2510,44 +2870,54 @@ func autoConvert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList(i return nil } +// Convert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList is an autogenerated conversion function. func Convert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList(in *PersistentVolumeClaimList, out *api.PersistentVolumeClaimList, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeClaimList_To_api_PersistentVolumeClaimList(in, out, s) } func autoConvert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList(in *api.PersistentVolumeClaimList, out *PersistentVolumeClaimList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]PersistentVolumeClaim)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]PersistentVolumeClaim, 0) + } else { + out.Items = *(*[]PersistentVolumeClaim)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList is an autogenerated conversion function. func Convert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList(in *api.PersistentVolumeClaimList, out *PersistentVolumeClaimList, s conversion.Scope) error { return autoConvert_api_PersistentVolumeClaimList_To_v1_PersistentVolumeClaimList(in, out, s) } func autoConvert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(in *PersistentVolumeClaimSpec, out *api.PersistentVolumeClaimSpec, s conversion.Scope) error { out.AccessModes = *(*[]api.PersistentVolumeAccessMode)(unsafe.Pointer(&in.AccessModes)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) + out.Selector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.Selector)) if err := Convert_v1_ResourceRequirements_To_api_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil { return err } out.VolumeName = in.VolumeName + out.StorageClassName = (*string)(unsafe.Pointer(in.StorageClassName)) return nil } +// Convert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec is an autogenerated conversion function. func Convert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(in *PersistentVolumeClaimSpec, out *api.PersistentVolumeClaimSpec, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeClaimSpec_To_api_PersistentVolumeClaimSpec(in, out, s) } func autoConvert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(in *api.PersistentVolumeClaimSpec, out *PersistentVolumeClaimSpec, s conversion.Scope) error { out.AccessModes = *(*[]PersistentVolumeAccessMode)(unsafe.Pointer(&in.AccessModes)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) + out.Selector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.Selector)) if err := Convert_api_ResourceRequirements_To_v1_ResourceRequirements(&in.Resources, &out.Resources, s); err != nil { return err } out.VolumeName = in.VolumeName + out.StorageClassName = (*string)(unsafe.Pointer(in.StorageClassName)) return nil } +// Convert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec is an autogenerated conversion function. func Convert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(in *api.PersistentVolumeClaimSpec, out *PersistentVolumeClaimSpec, s conversion.Scope) error { return autoConvert_api_PersistentVolumeClaimSpec_To_v1_PersistentVolumeClaimSpec(in, out, s) } @@ -2559,6 +2929,7 @@ func autoConvert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStat return nil } +// Convert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus is an autogenerated conversion function. func Convert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus(in *PersistentVolumeClaimStatus, out *api.PersistentVolumeClaimStatus, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeClaimStatus_To_api_PersistentVolumeClaimStatus(in, out, s) } @@ -2570,6 +2941,7 @@ func autoConvert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStat return nil } +// Convert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus is an autogenerated conversion function. func Convert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus(in *api.PersistentVolumeClaimStatus, out *PersistentVolumeClaimStatus, s conversion.Scope) error { return autoConvert_api_PersistentVolumeClaimStatus_To_v1_PersistentVolumeClaimStatus(in, out, s) } @@ -2580,6 +2952,7 @@ func autoConvert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeCla return nil } +// Convert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource is an autogenerated conversion function. func Convert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource(in *PersistentVolumeClaimVolumeSource, out *api.PersistentVolumeClaimVolumeSource, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeClaimVolumeSource_To_api_PersistentVolumeClaimVolumeSource(in, out, s) } @@ -2590,6 +2963,7 @@ func autoConvert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeCla return nil } +// Convert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource is an autogenerated conversion function. func Convert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource(in *api.PersistentVolumeClaimVolumeSource, out *PersistentVolumeClaimVolumeSource, s conversion.Scope) error { return autoConvert_api_PersistentVolumeClaimVolumeSource_To_v1_PersistentVolumeClaimVolumeSource(in, out, s) } @@ -2610,6 +2984,7 @@ func autoConvert_v1_PersistentVolumeList_To_api_PersistentVolumeList(in *Persist return nil } +// Convert_v1_PersistentVolumeList_To_api_PersistentVolumeList is an autogenerated conversion function. func Convert_v1_PersistentVolumeList_To_api_PersistentVolumeList(in *PersistentVolumeList, out *api.PersistentVolumeList, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeList_To_api_PersistentVolumeList(in, out, s) } @@ -2625,11 +3000,12 @@ func autoConvert_api_PersistentVolumeList_To_v1_PersistentVolumeList(in *api.Per } } } else { - out.Items = nil + out.Items = make([]PersistentVolume, 0) } return nil } +// Convert_api_PersistentVolumeList_To_v1_PersistentVolumeList is an autogenerated conversion function. func Convert_api_PersistentVolumeList_To_v1_PersistentVolumeList(in *api.PersistentVolumeList, out *PersistentVolumeList, s conversion.Scope) error { return autoConvert_api_PersistentVolumeList_To_v1_PersistentVolumeList(in, out, s) } @@ -2652,9 +3028,14 @@ func autoConvert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(in *Per out.Quobyte = (*api.QuobyteVolumeSource)(unsafe.Pointer(in.Quobyte)) out.AzureDisk = (*api.AzureDiskVolumeSource)(unsafe.Pointer(in.AzureDisk)) out.PhotonPersistentDisk = (*api.PhotonPersistentDiskVolumeSource)(unsafe.Pointer(in.PhotonPersistentDisk)) + out.PortworxVolume = (*api.PortworxVolumeSource)(unsafe.Pointer(in.PortworxVolume)) + out.ScaleIO = (*api.ScaleIOVolumeSource)(unsafe.Pointer(in.ScaleIO)) + out.Local = (*api.LocalVolumeSource)(unsafe.Pointer(in.Local)) + out.StorageOS = (*api.StorageOSPersistentVolumeSource)(unsafe.Pointer(in.StorageOS)) return nil } +// Convert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource is an autogenerated conversion function. func Convert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(in *PersistentVolumeSource, out *api.PersistentVolumeSource, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeSource_To_api_PersistentVolumeSource(in, out, s) } @@ -2677,9 +3058,14 @@ func autoConvert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(in *api out.VsphereVolume = (*VsphereVirtualDiskVolumeSource)(unsafe.Pointer(in.VsphereVolume)) out.AzureDisk = (*AzureDiskVolumeSource)(unsafe.Pointer(in.AzureDisk)) out.PhotonPersistentDisk = (*PhotonPersistentDiskVolumeSource)(unsafe.Pointer(in.PhotonPersistentDisk)) + out.PortworxVolume = (*PortworxVolumeSource)(unsafe.Pointer(in.PortworxVolume)) + out.ScaleIO = (*ScaleIOVolumeSource)(unsafe.Pointer(in.ScaleIO)) + out.Local = (*LocalVolumeSource)(unsafe.Pointer(in.Local)) + out.StorageOS = (*StorageOSPersistentVolumeSource)(unsafe.Pointer(in.StorageOS)) return nil } +// Convert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource is an autogenerated conversion function. func Convert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(in *api.PersistentVolumeSource, out *PersistentVolumeSource, s conversion.Scope) error { return autoConvert_api_PersistentVolumeSource_To_v1_PersistentVolumeSource(in, out, s) } @@ -2692,9 +3078,11 @@ func autoConvert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(in *Persist out.AccessModes = *(*[]api.PersistentVolumeAccessMode)(unsafe.Pointer(&in.AccessModes)) out.ClaimRef = (*api.ObjectReference)(unsafe.Pointer(in.ClaimRef)) out.PersistentVolumeReclaimPolicy = api.PersistentVolumeReclaimPolicy(in.PersistentVolumeReclaimPolicy) + out.StorageClassName = in.StorageClassName return nil } +// Convert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec is an autogenerated conversion function. func Convert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(in *PersistentVolumeSpec, out *api.PersistentVolumeSpec, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeSpec_To_api_PersistentVolumeSpec(in, out, s) } @@ -2707,9 +3095,11 @@ func autoConvert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(in *api.Per out.AccessModes = *(*[]PersistentVolumeAccessMode)(unsafe.Pointer(&in.AccessModes)) out.ClaimRef = (*ObjectReference)(unsafe.Pointer(in.ClaimRef)) out.PersistentVolumeReclaimPolicy = PersistentVolumeReclaimPolicy(in.PersistentVolumeReclaimPolicy) + out.StorageClassName = in.StorageClassName return nil } +// Convert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec is an autogenerated conversion function. func Convert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(in *api.PersistentVolumeSpec, out *PersistentVolumeSpec, s conversion.Scope) error { return autoConvert_api_PersistentVolumeSpec_To_v1_PersistentVolumeSpec(in, out, s) } @@ -2721,6 +3111,7 @@ func autoConvert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(in *Per return nil } +// Convert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus is an autogenerated conversion function. func Convert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(in *PersistentVolumeStatus, out *api.PersistentVolumeStatus, s conversion.Scope) error { return autoConvert_v1_PersistentVolumeStatus_To_api_PersistentVolumeStatus(in, out, s) } @@ -2732,6 +3123,7 @@ func autoConvert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(in *api return nil } +// Convert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus is an autogenerated conversion function. func Convert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(in *api.PersistentVolumeStatus, out *PersistentVolumeStatus, s conversion.Scope) error { return autoConvert_api_PersistentVolumeStatus_To_v1_PersistentVolumeStatus(in, out, s) } @@ -2742,6 +3134,7 @@ func autoConvert_v1_PhotonPersistentDiskVolumeSource_To_api_PhotonPersistentDisk return nil } +// Convert_v1_PhotonPersistentDiskVolumeSource_To_api_PhotonPersistentDiskVolumeSource is an autogenerated conversion function. func Convert_v1_PhotonPersistentDiskVolumeSource_To_api_PhotonPersistentDiskVolumeSource(in *PhotonPersistentDiskVolumeSource, out *api.PhotonPersistentDiskVolumeSource, s conversion.Scope) error { return autoConvert_v1_PhotonPersistentDiskVolumeSource_To_api_PhotonPersistentDiskVolumeSource(in, out, s) } @@ -2752,14 +3145,13 @@ func autoConvert_api_PhotonPersistentDiskVolumeSource_To_v1_PhotonPersistentDisk return nil } +// Convert_api_PhotonPersistentDiskVolumeSource_To_v1_PhotonPersistentDiskVolumeSource is an autogenerated conversion function. func Convert_api_PhotonPersistentDiskVolumeSource_To_v1_PhotonPersistentDiskVolumeSource(in *api.PhotonPersistentDiskVolumeSource, out *PhotonPersistentDiskVolumeSource, s conversion.Scope) error { return autoConvert_api_PhotonPersistentDiskVolumeSource_To_v1_PhotonPersistentDiskVolumeSource(in, out, s) } func autoConvert_v1_Pod_To_api_Pod(in *Pod, out *api.Pod, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_PodSpec_To_api_PodSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2770,9 +3162,7 @@ func autoConvert_v1_Pod_To_api_Pod(in *Pod, out *api.Pod, s conversion.Scope) er } func autoConvert_api_Pod_To_v1_Pod(in *api.Pod, out *Pod, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_PodSpec_To_v1_PodSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -2788,6 +3178,7 @@ func autoConvert_v1_PodAffinity_To_api_PodAffinity(in *PodAffinity, out *api.Pod return nil } +// Convert_v1_PodAffinity_To_api_PodAffinity is an autogenerated conversion function. func Convert_v1_PodAffinity_To_api_PodAffinity(in *PodAffinity, out *api.PodAffinity, s conversion.Scope) error { return autoConvert_v1_PodAffinity_To_api_PodAffinity(in, out, s) } @@ -2798,28 +3189,31 @@ func autoConvert_api_PodAffinity_To_v1_PodAffinity(in *api.PodAffinity, out *Pod return nil } +// Convert_api_PodAffinity_To_v1_PodAffinity is an autogenerated conversion function. func Convert_api_PodAffinity_To_v1_PodAffinity(in *api.PodAffinity, out *PodAffinity, s conversion.Scope) error { return autoConvert_api_PodAffinity_To_v1_PodAffinity(in, out, s) } func autoConvert_v1_PodAffinityTerm_To_api_PodAffinityTerm(in *PodAffinityTerm, out *api.PodAffinityTerm, s conversion.Scope) error { - out.LabelSelector = (*unversioned.LabelSelector)(unsafe.Pointer(in.LabelSelector)) + out.LabelSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.LabelSelector)) out.Namespaces = *(*[]string)(unsafe.Pointer(&in.Namespaces)) out.TopologyKey = in.TopologyKey return nil } +// Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm is an autogenerated conversion function. func Convert_v1_PodAffinityTerm_To_api_PodAffinityTerm(in *PodAffinityTerm, out *api.PodAffinityTerm, s conversion.Scope) error { return autoConvert_v1_PodAffinityTerm_To_api_PodAffinityTerm(in, out, s) } func autoConvert_api_PodAffinityTerm_To_v1_PodAffinityTerm(in *api.PodAffinityTerm, out *PodAffinityTerm, s conversion.Scope) error { - out.LabelSelector = (*unversioned.LabelSelector)(unsafe.Pointer(in.LabelSelector)) + out.LabelSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.LabelSelector)) out.Namespaces = *(*[]string)(unsafe.Pointer(&in.Namespaces)) out.TopologyKey = in.TopologyKey return nil } +// Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm is an autogenerated conversion function. func Convert_api_PodAffinityTerm_To_v1_PodAffinityTerm(in *api.PodAffinityTerm, out *PodAffinityTerm, s conversion.Scope) error { return autoConvert_api_PodAffinityTerm_To_v1_PodAffinityTerm(in, out, s) } @@ -2830,6 +3224,7 @@ func autoConvert_v1_PodAntiAffinity_To_api_PodAntiAffinity(in *PodAntiAffinity, return nil } +// Convert_v1_PodAntiAffinity_To_api_PodAntiAffinity is an autogenerated conversion function. func Convert_v1_PodAntiAffinity_To_api_PodAntiAffinity(in *PodAntiAffinity, out *api.PodAntiAffinity, s conversion.Scope) error { return autoConvert_v1_PodAntiAffinity_To_api_PodAntiAffinity(in, out, s) } @@ -2840,6 +3235,7 @@ func autoConvert_api_PodAntiAffinity_To_v1_PodAntiAffinity(in *api.PodAntiAffini return nil } +// Convert_api_PodAntiAffinity_To_v1_PodAntiAffinity is an autogenerated conversion function. func Convert_api_PodAntiAffinity_To_v1_PodAntiAffinity(in *api.PodAntiAffinity, out *PodAntiAffinity, s conversion.Scope) error { return autoConvert_api_PodAntiAffinity_To_v1_PodAntiAffinity(in, out, s) } @@ -2853,6 +3249,7 @@ func autoConvert_v1_PodAttachOptions_To_api_PodAttachOptions(in *PodAttachOption return nil } +// Convert_v1_PodAttachOptions_To_api_PodAttachOptions is an autogenerated conversion function. func Convert_v1_PodAttachOptions_To_api_PodAttachOptions(in *PodAttachOptions, out *api.PodAttachOptions, s conversion.Scope) error { return autoConvert_v1_PodAttachOptions_To_api_PodAttachOptions(in, out, s) } @@ -2866,6 +3263,7 @@ func autoConvert_api_PodAttachOptions_To_v1_PodAttachOptions(in *api.PodAttachOp return nil } +// Convert_api_PodAttachOptions_To_v1_PodAttachOptions is an autogenerated conversion function. func Convert_api_PodAttachOptions_To_v1_PodAttachOptions(in *api.PodAttachOptions, out *PodAttachOptions, s conversion.Scope) error { return autoConvert_api_PodAttachOptions_To_v1_PodAttachOptions(in, out, s) } @@ -2880,6 +3278,7 @@ func autoConvert_v1_PodCondition_To_api_PodCondition(in *PodCondition, out *api. return nil } +// Convert_v1_PodCondition_To_api_PodCondition is an autogenerated conversion function. func Convert_v1_PodCondition_To_api_PodCondition(in *PodCondition, out *api.PodCondition, s conversion.Scope) error { return autoConvert_v1_PodCondition_To_api_PodCondition(in, out, s) } @@ -2894,6 +3293,7 @@ func autoConvert_api_PodCondition_To_v1_PodCondition(in *api.PodCondition, out * return nil } +// Convert_api_PodCondition_To_v1_PodCondition is an autogenerated conversion function. func Convert_api_PodCondition_To_v1_PodCondition(in *api.PodCondition, out *PodCondition, s conversion.Scope) error { return autoConvert_api_PodCondition_To_v1_PodCondition(in, out, s) } @@ -2908,6 +3308,7 @@ func autoConvert_v1_PodExecOptions_To_api_PodExecOptions(in *PodExecOptions, out return nil } +// Convert_v1_PodExecOptions_To_api_PodExecOptions is an autogenerated conversion function. func Convert_v1_PodExecOptions_To_api_PodExecOptions(in *PodExecOptions, out *api.PodExecOptions, s conversion.Scope) error { return autoConvert_v1_PodExecOptions_To_api_PodExecOptions(in, out, s) } @@ -2918,10 +3319,15 @@ func autoConvert_api_PodExecOptions_To_v1_PodExecOptions(in *api.PodExecOptions, out.Stderr = in.Stderr out.TTY = in.TTY out.Container = in.Container - out.Command = *(*[]string)(unsafe.Pointer(&in.Command)) + if in.Command == nil { + out.Command = make([]string, 0) + } else { + out.Command = *(*[]string)(unsafe.Pointer(&in.Command)) + } return nil } +// Convert_api_PodExecOptions_To_v1_PodExecOptions is an autogenerated conversion function. func Convert_api_PodExecOptions_To_v1_PodExecOptions(in *api.PodExecOptions, out *PodExecOptions, s conversion.Scope) error { return autoConvert_api_PodExecOptions_To_v1_PodExecOptions(in, out, s) } @@ -2942,6 +3348,7 @@ func autoConvert_v1_PodList_To_api_PodList(in *PodList, out *api.PodList, s conv return nil } +// Convert_v1_PodList_To_api_PodList is an autogenerated conversion function. func Convert_v1_PodList_To_api_PodList(in *PodList, out *api.PodList, s conversion.Scope) error { return autoConvert_v1_PodList_To_api_PodList(in, out, s) } @@ -2957,11 +3364,12 @@ func autoConvert_api_PodList_To_v1_PodList(in *api.PodList, out *PodList, s conv } } } else { - out.Items = nil + out.Items = make([]Pod, 0) } return nil } +// Convert_api_PodList_To_v1_PodList is an autogenerated conversion function. func Convert_api_PodList_To_v1_PodList(in *api.PodList, out *PodList, s conversion.Scope) error { return autoConvert_api_PodList_To_v1_PodList(in, out, s) } @@ -2971,13 +3379,14 @@ func autoConvert_v1_PodLogOptions_To_api_PodLogOptions(in *PodLogOptions, out *a out.Follow = in.Follow out.Previous = in.Previous out.SinceSeconds = (*int64)(unsafe.Pointer(in.SinceSeconds)) - out.SinceTime = (*unversioned.Time)(unsafe.Pointer(in.SinceTime)) + out.SinceTime = (*meta_v1.Time)(unsafe.Pointer(in.SinceTime)) out.Timestamps = in.Timestamps out.TailLines = (*int64)(unsafe.Pointer(in.TailLines)) out.LimitBytes = (*int64)(unsafe.Pointer(in.LimitBytes)) return nil } +// Convert_v1_PodLogOptions_To_api_PodLogOptions is an autogenerated conversion function. func Convert_v1_PodLogOptions_To_api_PodLogOptions(in *PodLogOptions, out *api.PodLogOptions, s conversion.Scope) error { return autoConvert_v1_PodLogOptions_To_api_PodLogOptions(in, out, s) } @@ -2987,22 +3396,44 @@ func autoConvert_api_PodLogOptions_To_v1_PodLogOptions(in *api.PodLogOptions, ou out.Follow = in.Follow out.Previous = in.Previous out.SinceSeconds = (*int64)(unsafe.Pointer(in.SinceSeconds)) - out.SinceTime = (*unversioned.Time)(unsafe.Pointer(in.SinceTime)) + out.SinceTime = (*meta_v1.Time)(unsafe.Pointer(in.SinceTime)) out.Timestamps = in.Timestamps out.TailLines = (*int64)(unsafe.Pointer(in.TailLines)) out.LimitBytes = (*int64)(unsafe.Pointer(in.LimitBytes)) return nil } +// Convert_api_PodLogOptions_To_v1_PodLogOptions is an autogenerated conversion function. func Convert_api_PodLogOptions_To_v1_PodLogOptions(in *api.PodLogOptions, out *PodLogOptions, s conversion.Scope) error { return autoConvert_api_PodLogOptions_To_v1_PodLogOptions(in, out, s) } +func autoConvert_v1_PodPortForwardOptions_To_api_PodPortForwardOptions(in *PodPortForwardOptions, out *api.PodPortForwardOptions, s conversion.Scope) error { + out.Ports = *(*[]int32)(unsafe.Pointer(&in.Ports)) + return nil +} + +// Convert_v1_PodPortForwardOptions_To_api_PodPortForwardOptions is an autogenerated conversion function. +func Convert_v1_PodPortForwardOptions_To_api_PodPortForwardOptions(in *PodPortForwardOptions, out *api.PodPortForwardOptions, s conversion.Scope) error { + return autoConvert_v1_PodPortForwardOptions_To_api_PodPortForwardOptions(in, out, s) +} + +func autoConvert_api_PodPortForwardOptions_To_v1_PodPortForwardOptions(in *api.PodPortForwardOptions, out *PodPortForwardOptions, s conversion.Scope) error { + out.Ports = *(*[]int32)(unsafe.Pointer(&in.Ports)) + return nil +} + +// Convert_api_PodPortForwardOptions_To_v1_PodPortForwardOptions is an autogenerated conversion function. +func Convert_api_PodPortForwardOptions_To_v1_PodPortForwardOptions(in *api.PodPortForwardOptions, out *PodPortForwardOptions, s conversion.Scope) error { + return autoConvert_api_PodPortForwardOptions_To_v1_PodPortForwardOptions(in, out, s) +} + func autoConvert_v1_PodProxyOptions_To_api_PodProxyOptions(in *PodProxyOptions, out *api.PodProxyOptions, s conversion.Scope) error { out.Path = in.Path return nil } +// Convert_v1_PodProxyOptions_To_api_PodProxyOptions is an autogenerated conversion function. func Convert_v1_PodProxyOptions_To_api_PodProxyOptions(in *PodProxyOptions, out *api.PodProxyOptions, s conversion.Scope) error { return autoConvert_v1_PodProxyOptions_To_api_PodProxyOptions(in, out, s) } @@ -3012,6 +3443,7 @@ func autoConvert_api_PodProxyOptions_To_v1_PodProxyOptions(in *api.PodProxyOptio return nil } +// Convert_api_PodProxyOptions_To_v1_PodProxyOptions is an autogenerated conversion function. func Convert_api_PodProxyOptions_To_v1_PodProxyOptions(in *api.PodProxyOptions, out *PodProxyOptions, s conversion.Scope) error { return autoConvert_api_PodProxyOptions_To_v1_PodProxyOptions(in, out, s) } @@ -3038,19 +3470,21 @@ func autoConvert_api_PodSecurityContext_To_v1_PodSecurityContext(in *api.PodSecu } func autoConvert_v1_PodSignature_To_api_PodSignature(in *PodSignature, out *api.PodSignature, s conversion.Scope) error { - out.PodController = (*api.OwnerReference)(unsafe.Pointer(in.PodController)) + out.PodController = (*meta_v1.OwnerReference)(unsafe.Pointer(in.PodController)) return nil } +// Convert_v1_PodSignature_To_api_PodSignature is an autogenerated conversion function. func Convert_v1_PodSignature_To_api_PodSignature(in *PodSignature, out *api.PodSignature, s conversion.Scope) error { return autoConvert_v1_PodSignature_To_api_PodSignature(in, out, s) } func autoConvert_api_PodSignature_To_v1_PodSignature(in *api.PodSignature, out *PodSignature, s conversion.Scope) error { - out.PodController = (*OwnerReference)(unsafe.Pointer(in.PodController)) + out.PodController = (*meta_v1.OwnerReference)(unsafe.Pointer(in.PodController)) return nil } +// Convert_api_PodSignature_To_v1_PodSignature is an autogenerated conversion function. func Convert_api_PodSignature_To_v1_PodSignature(in *api.PodSignature, out *PodSignature, s conversion.Scope) error { return autoConvert_api_PodSignature_To_v1_PodSignature(in, out, s) } @@ -3076,6 +3510,7 @@ func autoConvert_v1_PodSpec_To_api_PodSpec(in *PodSpec, out *api.PodSpec, s conv out.NodeSelector = *(*map[string]string)(unsafe.Pointer(&in.NodeSelector)) out.ServiceAccountName = in.ServiceAccountName // INFO: in.DeprecatedServiceAccount opted out of conversion generation + out.AutomountServiceAccountToken = (*bool)(unsafe.Pointer(in.AutomountServiceAccountToken)) out.NodeName = in.NodeName // INFO: in.HostNetwork opted out of conversion generation // INFO: in.HostPID opted out of conversion generation @@ -3092,6 +3527,10 @@ func autoConvert_v1_PodSpec_To_api_PodSpec(in *PodSpec, out *api.PodSpec, s conv out.ImagePullSecrets = *(*[]api.LocalObjectReference)(unsafe.Pointer(&in.ImagePullSecrets)) out.Hostname = in.Hostname out.Subdomain = in.Subdomain + out.Affinity = (*api.Affinity)(unsafe.Pointer(in.Affinity)) + out.SchedulerName = in.SchedulerName + out.Tolerations = *(*[]api.Toleration)(unsafe.Pointer(&in.Tolerations)) + out.HostAliases = *(*[]api.HostAlias)(unsafe.Pointer(&in.HostAliases)) return nil } @@ -3108,13 +3547,18 @@ func autoConvert_api_PodSpec_To_v1_PodSpec(in *api.PodSpec, out *PodSpec, s conv out.Volumes = nil } out.InitContainers = *(*[]Container)(unsafe.Pointer(&in.InitContainers)) - out.Containers = *(*[]Container)(unsafe.Pointer(&in.Containers)) + if in.Containers == nil { + out.Containers = make([]Container, 0) + } else { + out.Containers = *(*[]Container)(unsafe.Pointer(&in.Containers)) + } out.RestartPolicy = RestartPolicy(in.RestartPolicy) out.TerminationGracePeriodSeconds = (*int64)(unsafe.Pointer(in.TerminationGracePeriodSeconds)) out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) out.DNSPolicy = DNSPolicy(in.DNSPolicy) out.NodeSelector = *(*map[string]string)(unsafe.Pointer(&in.NodeSelector)) out.ServiceAccountName = in.ServiceAccountName + out.AutomountServiceAccountToken = (*bool)(unsafe.Pointer(in.AutomountServiceAccountToken)) out.NodeName = in.NodeName if in.SecurityContext != nil { in, out := &in.SecurityContext, &out.SecurityContext @@ -3128,6 +3572,10 @@ func autoConvert_api_PodSpec_To_v1_PodSpec(in *api.PodSpec, out *PodSpec, s conv out.ImagePullSecrets = *(*[]LocalObjectReference)(unsafe.Pointer(&in.ImagePullSecrets)) out.Hostname = in.Hostname out.Subdomain = in.Subdomain + out.Affinity = (*Affinity)(unsafe.Pointer(in.Affinity)) + out.SchedulerName = in.SchedulerName + out.Tolerations = *(*[]Toleration)(unsafe.Pointer(&in.Tolerations)) + out.HostAliases = *(*[]HostAlias)(unsafe.Pointer(&in.HostAliases)) return nil } @@ -3138,12 +3586,14 @@ func autoConvert_v1_PodStatus_To_api_PodStatus(in *PodStatus, out *api.PodStatus out.Reason = in.Reason out.HostIP = in.HostIP out.PodIP = in.PodIP - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) + out.StartTime = (*meta_v1.Time)(unsafe.Pointer(in.StartTime)) out.InitContainerStatuses = *(*[]api.ContainerStatus)(unsafe.Pointer(&in.InitContainerStatuses)) out.ContainerStatuses = *(*[]api.ContainerStatus)(unsafe.Pointer(&in.ContainerStatuses)) + out.QOSClass = api.PodQOSClass(in.QOSClass) return nil } +// Convert_v1_PodStatus_To_api_PodStatus is an autogenerated conversion function. func Convert_v1_PodStatus_To_api_PodStatus(in *PodStatus, out *api.PodStatus, s conversion.Scope) error { return autoConvert_v1_PodStatus_To_api_PodStatus(in, out, s) } @@ -3155,20 +3605,20 @@ func autoConvert_api_PodStatus_To_v1_PodStatus(in *api.PodStatus, out *PodStatus out.Reason = in.Reason out.HostIP = in.HostIP out.PodIP = in.PodIP - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) + out.StartTime = (*meta_v1.Time)(unsafe.Pointer(in.StartTime)) + out.QOSClass = PodQOSClass(in.QOSClass) out.InitContainerStatuses = *(*[]ContainerStatus)(unsafe.Pointer(&in.InitContainerStatuses)) out.ContainerStatuses = *(*[]ContainerStatus)(unsafe.Pointer(&in.ContainerStatuses)) return nil } +// Convert_api_PodStatus_To_v1_PodStatus is an autogenerated conversion function. func Convert_api_PodStatus_To_v1_PodStatus(in *api.PodStatus, out *PodStatus, s conversion.Scope) error { return autoConvert_api_PodStatus_To_v1_PodStatus(in, out, s) } func autoConvert_v1_PodStatusResult_To_api_PodStatusResult(in *PodStatusResult, out *api.PodStatusResult, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_PodStatus_To_api_PodStatus(&in.Status, &out.Status, s); err != nil { return err } @@ -3176,9 +3626,7 @@ func autoConvert_v1_PodStatusResult_To_api_PodStatusResult(in *PodStatusResult, } func autoConvert_api_PodStatusResult_To_v1_PodStatusResult(in *api.PodStatusResult, out *PodStatusResult, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_PodStatus_To_v1_PodStatus(&in.Status, &out.Status, s); err != nil { return err } @@ -3186,29 +3634,27 @@ func autoConvert_api_PodStatusResult_To_v1_PodStatusResult(in *api.PodStatusResu } func autoConvert_v1_PodTemplate_To_api_PodTemplate(in *PodTemplate, out *api.PodTemplate, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } return nil } +// Convert_v1_PodTemplate_To_api_PodTemplate is an autogenerated conversion function. func Convert_v1_PodTemplate_To_api_PodTemplate(in *PodTemplate, out *api.PodTemplate, s conversion.Scope) error { return autoConvert_v1_PodTemplate_To_api_PodTemplate(in, out, s) } func autoConvert_api_PodTemplate_To_v1_PodTemplate(in *api.PodTemplate, out *PodTemplate, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } return nil } +// Convert_api_PodTemplate_To_v1_PodTemplate is an autogenerated conversion function. func Convert_api_PodTemplate_To_v1_PodTemplate(in *api.PodTemplate, out *PodTemplate, s conversion.Scope) error { return autoConvert_api_PodTemplate_To_v1_PodTemplate(in, out, s) } @@ -3229,6 +3675,7 @@ func autoConvert_v1_PodTemplateList_To_api_PodTemplateList(in *PodTemplateList, return nil } +// Convert_v1_PodTemplateList_To_api_PodTemplateList is an autogenerated conversion function. func Convert_v1_PodTemplateList_To_api_PodTemplateList(in *PodTemplateList, out *api.PodTemplateList, s conversion.Scope) error { return autoConvert_v1_PodTemplateList_To_api_PodTemplateList(in, out, s) } @@ -3244,19 +3691,18 @@ func autoConvert_api_PodTemplateList_To_v1_PodTemplateList(in *api.PodTemplateLi } } } else { - out.Items = nil + out.Items = make([]PodTemplate, 0) } return nil } +// Convert_api_PodTemplateList_To_v1_PodTemplateList is an autogenerated conversion function. func Convert_api_PodTemplateList_To_v1_PodTemplateList(in *api.PodTemplateList, out *PodTemplateList, s conversion.Scope) error { return autoConvert_api_PodTemplateList_To_v1_PodTemplateList(in, out, s) } func autoConvert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in *PodTemplateSpec, out *api.PodTemplateSpec, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_PodSpec_To_api_PodSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3264,20 +3710,43 @@ func autoConvert_v1_PodTemplateSpec_To_api_PodTemplateSpec(in *PodTemplateSpec, } func autoConvert_api_PodTemplateSpec_To_v1_PodTemplateSpec(in *api.PodTemplateSpec, out *PodTemplateSpec, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_PodSpec_To_v1_PodSpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +func autoConvert_v1_PortworxVolumeSource_To_api_PortworxVolumeSource(in *PortworxVolumeSource, out *api.PortworxVolumeSource, s conversion.Scope) error { + out.VolumeID = in.VolumeID + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + return nil +} + +// Convert_v1_PortworxVolumeSource_To_api_PortworxVolumeSource is an autogenerated conversion function. +func Convert_v1_PortworxVolumeSource_To_api_PortworxVolumeSource(in *PortworxVolumeSource, out *api.PortworxVolumeSource, s conversion.Scope) error { + return autoConvert_v1_PortworxVolumeSource_To_api_PortworxVolumeSource(in, out, s) +} + +func autoConvert_api_PortworxVolumeSource_To_v1_PortworxVolumeSource(in *api.PortworxVolumeSource, out *PortworxVolumeSource, s conversion.Scope) error { + out.VolumeID = in.VolumeID + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + return nil +} + +// Convert_api_PortworxVolumeSource_To_v1_PortworxVolumeSource is an autogenerated conversion function. +func Convert_api_PortworxVolumeSource_To_v1_PortworxVolumeSource(in *api.PortworxVolumeSource, out *PortworxVolumeSource, s conversion.Scope) error { + return autoConvert_api_PortworxVolumeSource_To_v1_PortworxVolumeSource(in, out, s) +} + func autoConvert_v1_Preconditions_To_api_Preconditions(in *Preconditions, out *api.Preconditions, s conversion.Scope) error { out.UID = (*types.UID)(unsafe.Pointer(in.UID)) return nil } +// Convert_v1_Preconditions_To_api_Preconditions is an autogenerated conversion function. func Convert_v1_Preconditions_To_api_Preconditions(in *Preconditions, out *api.Preconditions, s conversion.Scope) error { return autoConvert_v1_Preconditions_To_api_Preconditions(in, out, s) } @@ -3287,6 +3756,7 @@ func autoConvert_api_Preconditions_To_v1_Preconditions(in *api.Preconditions, ou return nil } +// Convert_api_Preconditions_To_v1_Preconditions is an autogenerated conversion function. func Convert_api_Preconditions_To_v1_Preconditions(in *api.Preconditions, out *Preconditions, s conversion.Scope) error { return autoConvert_api_Preconditions_To_v1_Preconditions(in, out, s) } @@ -3301,6 +3771,7 @@ func autoConvert_v1_PreferAvoidPodsEntry_To_api_PreferAvoidPodsEntry(in *PreferA return nil } +// Convert_v1_PreferAvoidPodsEntry_To_api_PreferAvoidPodsEntry is an autogenerated conversion function. func Convert_v1_PreferAvoidPodsEntry_To_api_PreferAvoidPodsEntry(in *PreferAvoidPodsEntry, out *api.PreferAvoidPodsEntry, s conversion.Scope) error { return autoConvert_v1_PreferAvoidPodsEntry_To_api_PreferAvoidPodsEntry(in, out, s) } @@ -3315,6 +3786,7 @@ func autoConvert_api_PreferAvoidPodsEntry_To_v1_PreferAvoidPodsEntry(in *api.Pre return nil } +// Convert_api_PreferAvoidPodsEntry_To_v1_PreferAvoidPodsEntry is an autogenerated conversion function. func Convert_api_PreferAvoidPodsEntry_To_v1_PreferAvoidPodsEntry(in *api.PreferAvoidPodsEntry, out *PreferAvoidPodsEntry, s conversion.Scope) error { return autoConvert_api_PreferAvoidPodsEntry_To_v1_PreferAvoidPodsEntry(in, out, s) } @@ -3327,6 +3799,7 @@ func autoConvert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(in *P return nil } +// Convert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm is an autogenerated conversion function. func Convert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(in *PreferredSchedulingTerm, out *api.PreferredSchedulingTerm, s conversion.Scope) error { return autoConvert_v1_PreferredSchedulingTerm_To_api_PreferredSchedulingTerm(in, out, s) } @@ -3339,6 +3812,7 @@ func autoConvert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(in *a return nil } +// Convert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm is an autogenerated conversion function. func Convert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(in *api.PreferredSchedulingTerm, out *PreferredSchedulingTerm, s conversion.Scope) error { return autoConvert_api_PreferredSchedulingTerm_To_v1_PreferredSchedulingTerm(in, out, s) } @@ -3355,6 +3829,7 @@ func autoConvert_v1_Probe_To_api_Probe(in *Probe, out *api.Probe, s conversion.S return nil } +// Convert_v1_Probe_To_api_Probe is an autogenerated conversion function. func Convert_v1_Probe_To_api_Probe(in *Probe, out *api.Probe, s conversion.Scope) error { return autoConvert_v1_Probe_To_api_Probe(in, out, s) } @@ -3371,10 +3846,37 @@ func autoConvert_api_Probe_To_v1_Probe(in *api.Probe, out *Probe, s conversion.S return nil } +// Convert_api_Probe_To_v1_Probe is an autogenerated conversion function. func Convert_api_Probe_To_v1_Probe(in *api.Probe, out *Probe, s conversion.Scope) error { return autoConvert_api_Probe_To_v1_Probe(in, out, s) } +func autoConvert_v1_ProjectedVolumeSource_To_api_ProjectedVolumeSource(in *ProjectedVolumeSource, out *api.ProjectedVolumeSource, s conversion.Scope) error { + out.Sources = *(*[]api.VolumeProjection)(unsafe.Pointer(&in.Sources)) + out.DefaultMode = (*int32)(unsafe.Pointer(in.DefaultMode)) + return nil +} + +// Convert_v1_ProjectedVolumeSource_To_api_ProjectedVolumeSource is an autogenerated conversion function. +func Convert_v1_ProjectedVolumeSource_To_api_ProjectedVolumeSource(in *ProjectedVolumeSource, out *api.ProjectedVolumeSource, s conversion.Scope) error { + return autoConvert_v1_ProjectedVolumeSource_To_api_ProjectedVolumeSource(in, out, s) +} + +func autoConvert_api_ProjectedVolumeSource_To_v1_ProjectedVolumeSource(in *api.ProjectedVolumeSource, out *ProjectedVolumeSource, s conversion.Scope) error { + if in.Sources == nil { + out.Sources = make([]VolumeProjection, 0) + } else { + out.Sources = *(*[]VolumeProjection)(unsafe.Pointer(&in.Sources)) + } + out.DefaultMode = (*int32)(unsafe.Pointer(in.DefaultMode)) + return nil +} + +// Convert_api_ProjectedVolumeSource_To_v1_ProjectedVolumeSource is an autogenerated conversion function. +func Convert_api_ProjectedVolumeSource_To_v1_ProjectedVolumeSource(in *api.ProjectedVolumeSource, out *ProjectedVolumeSource, s conversion.Scope) error { + return autoConvert_api_ProjectedVolumeSource_To_v1_ProjectedVolumeSource(in, out, s) +} + func autoConvert_v1_QuobyteVolumeSource_To_api_QuobyteVolumeSource(in *QuobyteVolumeSource, out *api.QuobyteVolumeSource, s conversion.Scope) error { out.Registry = in.Registry out.Volume = in.Volume @@ -3384,6 +3886,7 @@ func autoConvert_v1_QuobyteVolumeSource_To_api_QuobyteVolumeSource(in *QuobyteVo return nil } +// Convert_v1_QuobyteVolumeSource_To_api_QuobyteVolumeSource is an autogenerated conversion function. func Convert_v1_QuobyteVolumeSource_To_api_QuobyteVolumeSource(in *QuobyteVolumeSource, out *api.QuobyteVolumeSource, s conversion.Scope) error { return autoConvert_v1_QuobyteVolumeSource_To_api_QuobyteVolumeSource(in, out, s) } @@ -3397,6 +3900,7 @@ func autoConvert_api_QuobyteVolumeSource_To_v1_QuobyteVolumeSource(in *api.Quoby return nil } +// Convert_api_QuobyteVolumeSource_To_v1_QuobyteVolumeSource is an autogenerated conversion function. func Convert_api_QuobyteVolumeSource_To_v1_QuobyteVolumeSource(in *api.QuobyteVolumeSource, out *QuobyteVolumeSource, s conversion.Scope) error { return autoConvert_api_QuobyteVolumeSource_To_v1_QuobyteVolumeSource(in, out, s) } @@ -3413,12 +3917,17 @@ func autoConvert_v1_RBDVolumeSource_To_api_RBDVolumeSource(in *RBDVolumeSource, return nil } +// Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource is an autogenerated conversion function. func Convert_v1_RBDVolumeSource_To_api_RBDVolumeSource(in *RBDVolumeSource, out *api.RBDVolumeSource, s conversion.Scope) error { return autoConvert_v1_RBDVolumeSource_To_api_RBDVolumeSource(in, out, s) } func autoConvert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in *api.RBDVolumeSource, out *RBDVolumeSource, s conversion.Scope) error { - out.CephMonitors = *(*[]string)(unsafe.Pointer(&in.CephMonitors)) + if in.CephMonitors == nil { + out.CephMonitors = make([]string, 0) + } else { + out.CephMonitors = *(*[]string)(unsafe.Pointer(&in.CephMonitors)) + } out.RBDImage = in.RBDImage out.FSType = in.FSType out.RBDPool = in.RBDPool @@ -3429,40 +3938,41 @@ func autoConvert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in *api.RBDVolumeSour return nil } +// Convert_api_RBDVolumeSource_To_v1_RBDVolumeSource is an autogenerated conversion function. func Convert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in *api.RBDVolumeSource, out *RBDVolumeSource, s conversion.Scope) error { return autoConvert_api_RBDVolumeSource_To_v1_RBDVolumeSource(in, out, s) } func autoConvert_v1_RangeAllocation_To_api_RangeAllocation(in *RangeAllocation, out *api.RangeAllocation, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Range = in.Range out.Data = *(*[]byte)(unsafe.Pointer(&in.Data)) return nil } +// Convert_v1_RangeAllocation_To_api_RangeAllocation is an autogenerated conversion function. func Convert_v1_RangeAllocation_To_api_RangeAllocation(in *RangeAllocation, out *api.RangeAllocation, s conversion.Scope) error { return autoConvert_v1_RangeAllocation_To_api_RangeAllocation(in, out, s) } func autoConvert_api_RangeAllocation_To_v1_RangeAllocation(in *api.RangeAllocation, out *RangeAllocation, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Range = in.Range - out.Data = *(*[]byte)(unsafe.Pointer(&in.Data)) + if in.Data == nil { + out.Data = make([]byte, 0) + } else { + out.Data = *(*[]byte)(unsafe.Pointer(&in.Data)) + } return nil } +// Convert_api_RangeAllocation_To_v1_RangeAllocation is an autogenerated conversion function. func Convert_api_RangeAllocation_To_v1_RangeAllocation(in *api.RangeAllocation, out *RangeAllocation, s conversion.Scope) error { return autoConvert_api_RangeAllocation_To_v1_RangeAllocation(in, out, s) } func autoConvert_v1_ReplicationController_To_api_ReplicationController(in *ReplicationController, out *api.ReplicationController, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3472,14 +3982,13 @@ func autoConvert_v1_ReplicationController_To_api_ReplicationController(in *Repli return nil } +// Convert_v1_ReplicationController_To_api_ReplicationController is an autogenerated conversion function. func Convert_v1_ReplicationController_To_api_ReplicationController(in *ReplicationController, out *api.ReplicationController, s conversion.Scope) error { return autoConvert_v1_ReplicationController_To_api_ReplicationController(in, out, s) } func autoConvert_api_ReplicationController_To_v1_ReplicationController(in *api.ReplicationController, out *ReplicationController, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_ReplicationControllerSpec_To_v1_ReplicationControllerSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3489,6 +3998,7 @@ func autoConvert_api_ReplicationController_To_v1_ReplicationController(in *api.R return nil } +// Convert_api_ReplicationController_To_v1_ReplicationController is an autogenerated conversion function. func Convert_api_ReplicationController_To_v1_ReplicationController(in *api.ReplicationController, out *ReplicationController, s conversion.Scope) error { return autoConvert_api_ReplicationController_To_v1_ReplicationController(in, out, s) } @@ -3502,6 +4012,7 @@ func autoConvert_v1_ReplicationControllerCondition_To_api_ReplicationControllerC return nil } +// Convert_v1_ReplicationControllerCondition_To_api_ReplicationControllerCondition is an autogenerated conversion function. func Convert_v1_ReplicationControllerCondition_To_api_ReplicationControllerCondition(in *ReplicationControllerCondition, out *api.ReplicationControllerCondition, s conversion.Scope) error { return autoConvert_v1_ReplicationControllerCondition_To_api_ReplicationControllerCondition(in, out, s) } @@ -3515,6 +4026,7 @@ func autoConvert_api_ReplicationControllerCondition_To_v1_ReplicationControllerC return nil } +// Convert_api_ReplicationControllerCondition_To_v1_ReplicationControllerCondition is an autogenerated conversion function. func Convert_api_ReplicationControllerCondition_To_v1_ReplicationControllerCondition(in *api.ReplicationControllerCondition, out *ReplicationControllerCondition, s conversion.Scope) error { return autoConvert_api_ReplicationControllerCondition_To_v1_ReplicationControllerCondition(in, out, s) } @@ -3535,6 +4047,7 @@ func autoConvert_v1_ReplicationControllerList_To_api_ReplicationControllerList(i return nil } +// Convert_v1_ReplicationControllerList_To_api_ReplicationControllerList is an autogenerated conversion function. func Convert_v1_ReplicationControllerList_To_api_ReplicationControllerList(in *ReplicationControllerList, out *api.ReplicationControllerList, s conversion.Scope) error { return autoConvert_v1_ReplicationControllerList_To_api_ReplicationControllerList(in, out, s) } @@ -3550,17 +4063,18 @@ func autoConvert_api_ReplicationControllerList_To_v1_ReplicationControllerList(i } } } else { - out.Items = nil + out.Items = make([]ReplicationController, 0) } return nil } +// Convert_api_ReplicationControllerList_To_v1_ReplicationControllerList is an autogenerated conversion function. func Convert_api_ReplicationControllerList_To_v1_ReplicationControllerList(in *api.ReplicationControllerList, out *ReplicationControllerList, s conversion.Scope) error { return autoConvert_api_ReplicationControllerList_To_v1_ReplicationControllerList(in, out, s) } func autoConvert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec(in *ReplicationControllerSpec, out *api.ReplicationControllerSpec, s conversion.Scope) error { - if err := api.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := meta_v1.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } out.MinReadySeconds = in.MinReadySeconds @@ -3578,7 +4092,7 @@ func autoConvert_v1_ReplicationControllerSpec_To_api_ReplicationControllerSpec(i } func autoConvert_api_ReplicationControllerSpec_To_v1_ReplicationControllerSpec(in *api.ReplicationControllerSpec, out *ReplicationControllerSpec, s conversion.Scope) error { - if err := api.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := meta_v1.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } out.MinReadySeconds = in.MinReadySeconds @@ -3605,6 +4119,7 @@ func autoConvert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStat return nil } +// Convert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus is an autogenerated conversion function. func Convert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus(in *ReplicationControllerStatus, out *api.ReplicationControllerStatus, s conversion.Scope) error { return autoConvert_v1_ReplicationControllerStatus_To_api_ReplicationControllerStatus(in, out, s) } @@ -3619,6 +4134,7 @@ func autoConvert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStat return nil } +// Convert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus is an autogenerated conversion function. func Convert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus(in *api.ReplicationControllerStatus, out *ReplicationControllerStatus, s conversion.Scope) error { return autoConvert_api_ReplicationControllerStatus_To_v1_ReplicationControllerStatus(in, out, s) } @@ -3630,6 +4146,7 @@ func autoConvert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(in *Resou return nil } +// Convert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector is an autogenerated conversion function. func Convert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(in *ResourceFieldSelector, out *api.ResourceFieldSelector, s conversion.Scope) error { return autoConvert_v1_ResourceFieldSelector_To_api_ResourceFieldSelector(in, out, s) } @@ -3641,14 +4158,13 @@ func autoConvert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(in *api.R return nil } +// Convert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector is an autogenerated conversion function. func Convert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(in *api.ResourceFieldSelector, out *ResourceFieldSelector, s conversion.Scope) error { return autoConvert_api_ResourceFieldSelector_To_v1_ResourceFieldSelector(in, out, s) } func autoConvert_v1_ResourceQuota_To_api_ResourceQuota(in *ResourceQuota, out *api.ResourceQuota, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3658,14 +4174,13 @@ func autoConvert_v1_ResourceQuota_To_api_ResourceQuota(in *ResourceQuota, out *a return nil } +// Convert_v1_ResourceQuota_To_api_ResourceQuota is an autogenerated conversion function. func Convert_v1_ResourceQuota_To_api_ResourceQuota(in *ResourceQuota, out *api.ResourceQuota, s conversion.Scope) error { return autoConvert_v1_ResourceQuota_To_api_ResourceQuota(in, out, s) } func autoConvert_api_ResourceQuota_To_v1_ResourceQuota(in *api.ResourceQuota, out *ResourceQuota, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3675,6 +4190,7 @@ func autoConvert_api_ResourceQuota_To_v1_ResourceQuota(in *api.ResourceQuota, ou return nil } +// Convert_api_ResourceQuota_To_v1_ResourceQuota is an autogenerated conversion function. func Convert_api_ResourceQuota_To_v1_ResourceQuota(in *api.ResourceQuota, out *ResourceQuota, s conversion.Scope) error { return autoConvert_api_ResourceQuota_To_v1_ResourceQuota(in, out, s) } @@ -3685,16 +4201,22 @@ func autoConvert_v1_ResourceQuotaList_To_api_ResourceQuotaList(in *ResourceQuota return nil } +// Convert_v1_ResourceQuotaList_To_api_ResourceQuotaList is an autogenerated conversion function. func Convert_v1_ResourceQuotaList_To_api_ResourceQuotaList(in *ResourceQuotaList, out *api.ResourceQuotaList, s conversion.Scope) error { return autoConvert_v1_ResourceQuotaList_To_api_ResourceQuotaList(in, out, s) } func autoConvert_api_ResourceQuotaList_To_v1_ResourceQuotaList(in *api.ResourceQuotaList, out *ResourceQuotaList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]ResourceQuota)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]ResourceQuota, 0) + } else { + out.Items = *(*[]ResourceQuota)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_ResourceQuotaList_To_v1_ResourceQuotaList is an autogenerated conversion function. func Convert_api_ResourceQuotaList_To_v1_ResourceQuotaList(in *api.ResourceQuotaList, out *ResourceQuotaList, s conversion.Scope) error { return autoConvert_api_ResourceQuotaList_To_v1_ResourceQuotaList(in, out, s) } @@ -3705,6 +4227,7 @@ func autoConvert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in *ResourceQuota return nil } +// Convert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec is an autogenerated conversion function. func Convert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in *ResourceQuotaSpec, out *api.ResourceQuotaSpec, s conversion.Scope) error { return autoConvert_v1_ResourceQuotaSpec_To_api_ResourceQuotaSpec(in, out, s) } @@ -3715,6 +4238,7 @@ func autoConvert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in *api.ResourceQ return nil } +// Convert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec is an autogenerated conversion function. func Convert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in *api.ResourceQuotaSpec, out *ResourceQuotaSpec, s conversion.Scope) error { return autoConvert_api_ResourceQuotaSpec_To_v1_ResourceQuotaSpec(in, out, s) } @@ -3725,6 +4249,7 @@ func autoConvert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(in *ResourceQ return nil } +// Convert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus is an autogenerated conversion function. func Convert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(in *ResourceQuotaStatus, out *api.ResourceQuotaStatus, s conversion.Scope) error { return autoConvert_v1_ResourceQuotaStatus_To_api_ResourceQuotaStatus(in, out, s) } @@ -3735,6 +4260,7 @@ func autoConvert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(in *api.Resou return nil } +// Convert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus is an autogenerated conversion function. func Convert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(in *api.ResourceQuotaStatus, out *ResourceQuotaStatus, s conversion.Scope) error { return autoConvert_api_ResourceQuotaStatus_To_v1_ResourceQuotaStatus(in, out, s) } @@ -3745,6 +4271,7 @@ func autoConvert_v1_ResourceRequirements_To_api_ResourceRequirements(in *Resourc return nil } +// Convert_v1_ResourceRequirements_To_api_ResourceRequirements is an autogenerated conversion function. func Convert_v1_ResourceRequirements_To_api_ResourceRequirements(in *ResourceRequirements, out *api.ResourceRequirements, s conversion.Scope) error { return autoConvert_v1_ResourceRequirements_To_api_ResourceRequirements(in, out, s) } @@ -3755,6 +4282,7 @@ func autoConvert_api_ResourceRequirements_To_v1_ResourceRequirements(in *api.Res return nil } +// Convert_api_ResourceRequirements_To_v1_ResourceRequirements is an autogenerated conversion function. func Convert_api_ResourceRequirements_To_v1_ResourceRequirements(in *api.ResourceRequirements, out *ResourceRequirements, s conversion.Scope) error { return autoConvert_api_ResourceRequirements_To_v1_ResourceRequirements(in, out, s) } @@ -3767,6 +4295,7 @@ func autoConvert_v1_SELinuxOptions_To_api_SELinuxOptions(in *SELinuxOptions, out return nil } +// Convert_v1_SELinuxOptions_To_api_SELinuxOptions is an autogenerated conversion function. func Convert_v1_SELinuxOptions_To_api_SELinuxOptions(in *SELinuxOptions, out *api.SELinuxOptions, s conversion.Scope) error { return autoConvert_v1_SELinuxOptions_To_api_SELinuxOptions(in, out, s) } @@ -3779,14 +4308,51 @@ func autoConvert_api_SELinuxOptions_To_v1_SELinuxOptions(in *api.SELinuxOptions, return nil } +// Convert_api_SELinuxOptions_To_v1_SELinuxOptions is an autogenerated conversion function. func Convert_api_SELinuxOptions_To_v1_SELinuxOptions(in *api.SELinuxOptions, out *SELinuxOptions, s conversion.Scope) error { return autoConvert_api_SELinuxOptions_To_v1_SELinuxOptions(in, out, s) } +func autoConvert_v1_ScaleIOVolumeSource_To_api_ScaleIOVolumeSource(in *ScaleIOVolumeSource, out *api.ScaleIOVolumeSource, s conversion.Scope) error { + out.Gateway = in.Gateway + out.System = in.System + out.SecretRef = (*api.LocalObjectReference)(unsafe.Pointer(in.SecretRef)) + out.SSLEnabled = in.SSLEnabled + out.ProtectionDomain = in.ProtectionDomain + out.StoragePool = in.StoragePool + out.StorageMode = in.StorageMode + out.VolumeName = in.VolumeName + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + return nil +} + +// Convert_v1_ScaleIOVolumeSource_To_api_ScaleIOVolumeSource is an autogenerated conversion function. +func Convert_v1_ScaleIOVolumeSource_To_api_ScaleIOVolumeSource(in *ScaleIOVolumeSource, out *api.ScaleIOVolumeSource, s conversion.Scope) error { + return autoConvert_v1_ScaleIOVolumeSource_To_api_ScaleIOVolumeSource(in, out, s) +} + +func autoConvert_api_ScaleIOVolumeSource_To_v1_ScaleIOVolumeSource(in *api.ScaleIOVolumeSource, out *ScaleIOVolumeSource, s conversion.Scope) error { + out.Gateway = in.Gateway + out.System = in.System + out.SecretRef = (*LocalObjectReference)(unsafe.Pointer(in.SecretRef)) + out.SSLEnabled = in.SSLEnabled + out.ProtectionDomain = in.ProtectionDomain + out.StoragePool = in.StoragePool + out.StorageMode = in.StorageMode + out.VolumeName = in.VolumeName + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + return nil +} + +// Convert_api_ScaleIOVolumeSource_To_v1_ScaleIOVolumeSource is an autogenerated conversion function. +func Convert_api_ScaleIOVolumeSource_To_v1_ScaleIOVolumeSource(in *api.ScaleIOVolumeSource, out *ScaleIOVolumeSource, s conversion.Scope) error { + return autoConvert_api_ScaleIOVolumeSource_To_v1_ScaleIOVolumeSource(in, out, s) +} + func autoConvert_v1_Secret_To_api_Secret(in *Secret, out *api.Secret, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Data = *(*map[string][]byte)(unsafe.Pointer(&in.Data)) // INFO: in.StringData opted out of conversion generation out.Type = api.SecretType(in.Type) @@ -3794,26 +4360,53 @@ func autoConvert_v1_Secret_To_api_Secret(in *Secret, out *api.Secret, s conversi } func autoConvert_api_Secret_To_v1_Secret(in *api.Secret, out *Secret, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Data = *(*map[string][]byte)(unsafe.Pointer(&in.Data)) out.Type = SecretType(in.Type) return nil } +// Convert_api_Secret_To_v1_Secret is an autogenerated conversion function. func Convert_api_Secret_To_v1_Secret(in *api.Secret, out *Secret, s conversion.Scope) error { return autoConvert_api_Secret_To_v1_Secret(in, out, s) } +func autoConvert_v1_SecretEnvSource_To_api_SecretEnvSource(in *SecretEnvSource, out *api.SecretEnvSource, s conversion.Scope) error { + if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_v1_SecretEnvSource_To_api_SecretEnvSource is an autogenerated conversion function. +func Convert_v1_SecretEnvSource_To_api_SecretEnvSource(in *SecretEnvSource, out *api.SecretEnvSource, s conversion.Scope) error { + return autoConvert_v1_SecretEnvSource_To_api_SecretEnvSource(in, out, s) +} + +func autoConvert_api_SecretEnvSource_To_v1_SecretEnvSource(in *api.SecretEnvSource, out *SecretEnvSource, s conversion.Scope) error { + if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_api_SecretEnvSource_To_v1_SecretEnvSource is an autogenerated conversion function. +func Convert_api_SecretEnvSource_To_v1_SecretEnvSource(in *api.SecretEnvSource, out *SecretEnvSource, s conversion.Scope) error { + return autoConvert_api_SecretEnvSource_To_v1_SecretEnvSource(in, out, s) +} + func autoConvert_v1_SecretKeySelector_To_api_SecretKeySelector(in *SecretKeySelector, out *api.SecretKeySelector, s conversion.Scope) error { if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { return err } out.Key = in.Key + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_v1_SecretKeySelector_To_api_SecretKeySelector is an autogenerated conversion function. func Convert_v1_SecretKeySelector_To_api_SecretKeySelector(in *SecretKeySelector, out *api.SecretKeySelector, s conversion.Scope) error { return autoConvert_v1_SecretKeySelector_To_api_SecretKeySelector(in, out, s) } @@ -3823,9 +4416,11 @@ func autoConvert_api_SecretKeySelector_To_v1_SecretKeySelector(in *api.SecretKey return err } out.Key = in.Key + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_api_SecretKeySelector_To_v1_SecretKeySelector is an autogenerated conversion function. func Convert_api_SecretKeySelector_To_v1_SecretKeySelector(in *api.SecretKeySelector, out *SecretKeySelector, s conversion.Scope) error { return autoConvert_api_SecretKeySelector_To_v1_SecretKeySelector(in, out, s) } @@ -3846,6 +4441,7 @@ func autoConvert_v1_SecretList_To_api_SecretList(in *SecretList, out *api.Secret return nil } +// Convert_v1_SecretList_To_api_SecretList is an autogenerated conversion function. func Convert_v1_SecretList_To_api_SecretList(in *SecretList, out *api.SecretList, s conversion.Scope) error { return autoConvert_v1_SecretList_To_api_SecretList(in, out, s) } @@ -3861,22 +4457,53 @@ func autoConvert_api_SecretList_To_v1_SecretList(in *api.SecretList, out *Secret } } } else { - out.Items = nil + out.Items = make([]Secret, 0) } return nil } +// Convert_api_SecretList_To_v1_SecretList is an autogenerated conversion function. func Convert_api_SecretList_To_v1_SecretList(in *api.SecretList, out *SecretList, s conversion.Scope) error { return autoConvert_api_SecretList_To_v1_SecretList(in, out, s) } +func autoConvert_v1_SecretProjection_To_api_SecretProjection(in *SecretProjection, out *api.SecretProjection, s conversion.Scope) error { + if err := Convert_v1_LocalObjectReference_To_api_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Items = *(*[]api.KeyToPath)(unsafe.Pointer(&in.Items)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_v1_SecretProjection_To_api_SecretProjection is an autogenerated conversion function. +func Convert_v1_SecretProjection_To_api_SecretProjection(in *SecretProjection, out *api.SecretProjection, s conversion.Scope) error { + return autoConvert_v1_SecretProjection_To_api_SecretProjection(in, out, s) +} + +func autoConvert_api_SecretProjection_To_v1_SecretProjection(in *api.SecretProjection, out *SecretProjection, s conversion.Scope) error { + if err := Convert_api_LocalObjectReference_To_v1_LocalObjectReference(&in.LocalObjectReference, &out.LocalObjectReference, s); err != nil { + return err + } + out.Items = *(*[]KeyToPath)(unsafe.Pointer(&in.Items)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) + return nil +} + +// Convert_api_SecretProjection_To_v1_SecretProjection is an autogenerated conversion function. +func Convert_api_SecretProjection_To_v1_SecretProjection(in *api.SecretProjection, out *SecretProjection, s conversion.Scope) error { + return autoConvert_api_SecretProjection_To_v1_SecretProjection(in, out, s) +} + func autoConvert_v1_SecretVolumeSource_To_api_SecretVolumeSource(in *SecretVolumeSource, out *api.SecretVolumeSource, s conversion.Scope) error { out.SecretName = in.SecretName out.Items = *(*[]api.KeyToPath)(unsafe.Pointer(&in.Items)) out.DefaultMode = (*int32)(unsafe.Pointer(in.DefaultMode)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_v1_SecretVolumeSource_To_api_SecretVolumeSource is an autogenerated conversion function. func Convert_v1_SecretVolumeSource_To_api_SecretVolumeSource(in *SecretVolumeSource, out *api.SecretVolumeSource, s conversion.Scope) error { return autoConvert_v1_SecretVolumeSource_To_api_SecretVolumeSource(in, out, s) } @@ -3885,9 +4512,11 @@ func autoConvert_api_SecretVolumeSource_To_v1_SecretVolumeSource(in *api.SecretV out.SecretName = in.SecretName out.Items = *(*[]KeyToPath)(unsafe.Pointer(&in.Items)) out.DefaultMode = (*int32)(unsafe.Pointer(in.DefaultMode)) + out.Optional = (*bool)(unsafe.Pointer(in.Optional)) return nil } +// Convert_api_SecretVolumeSource_To_v1_SecretVolumeSource is an autogenerated conversion function. func Convert_api_SecretVolumeSource_To_v1_SecretVolumeSource(in *api.SecretVolumeSource, out *SecretVolumeSource, s conversion.Scope) error { return autoConvert_api_SecretVolumeSource_To_v1_SecretVolumeSource(in, out, s) } @@ -3902,6 +4531,7 @@ func autoConvert_v1_SecurityContext_To_api_SecurityContext(in *SecurityContext, return nil } +// Convert_v1_SecurityContext_To_api_SecurityContext is an autogenerated conversion function. func Convert_v1_SecurityContext_To_api_SecurityContext(in *SecurityContext, out *api.SecurityContext, s conversion.Scope) error { return autoConvert_v1_SecurityContext_To_api_SecurityContext(in, out, s) } @@ -3916,6 +4546,7 @@ func autoConvert_api_SecurityContext_To_v1_SecurityContext(in *api.SecurityConte return nil } +// Convert_api_SecurityContext_To_v1_SecurityContext is an autogenerated conversion function. func Convert_api_SecurityContext_To_v1_SecurityContext(in *api.SecurityContext, out *SecurityContext, s conversion.Scope) error { return autoConvert_api_SecurityContext_To_v1_SecurityContext(in, out, s) } @@ -3927,6 +4558,7 @@ func autoConvert_v1_SerializedReference_To_api_SerializedReference(in *Serialize return nil } +// Convert_v1_SerializedReference_To_api_SerializedReference is an autogenerated conversion function. func Convert_v1_SerializedReference_To_api_SerializedReference(in *SerializedReference, out *api.SerializedReference, s conversion.Scope) error { return autoConvert_v1_SerializedReference_To_api_SerializedReference(in, out, s) } @@ -3938,14 +4570,13 @@ func autoConvert_api_SerializedReference_To_v1_SerializedReference(in *api.Seria return nil } +// Convert_api_SerializedReference_To_v1_SerializedReference is an autogenerated conversion function. func Convert_api_SerializedReference_To_v1_SerializedReference(in *api.SerializedReference, out *SerializedReference, s conversion.Scope) error { return autoConvert_api_SerializedReference_To_v1_SerializedReference(in, out, s) } func autoConvert_v1_Service_To_api_Service(in *Service, out *api.Service, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ServiceSpec_To_api_ServiceSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3955,14 +4586,13 @@ func autoConvert_v1_Service_To_api_Service(in *Service, out *api.Service, s conv return nil } +// Convert_v1_Service_To_api_Service is an autogenerated conversion function. func Convert_v1_Service_To_api_Service(in *Service, out *api.Service, s conversion.Scope) error { return autoConvert_v1_Service_To_api_Service(in, out, s) } func autoConvert_api_Service_To_v1_Service(in *api.Service, out *Service, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_api_ServiceSpec_To_v1_ServiceSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -3972,32 +4602,33 @@ func autoConvert_api_Service_To_v1_Service(in *api.Service, out *Service, s conv return nil } +// Convert_api_Service_To_v1_Service is an autogenerated conversion function. func Convert_api_Service_To_v1_Service(in *api.Service, out *Service, s conversion.Scope) error { return autoConvert_api_Service_To_v1_Service(in, out, s) } func autoConvert_v1_ServiceAccount_To_api_ServiceAccount(in *ServiceAccount, out *api.ServiceAccount, s conversion.Scope) error { - if err := Convert_v1_ObjectMeta_To_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Secrets = *(*[]api.ObjectReference)(unsafe.Pointer(&in.Secrets)) out.ImagePullSecrets = *(*[]api.LocalObjectReference)(unsafe.Pointer(&in.ImagePullSecrets)) + out.AutomountServiceAccountToken = (*bool)(unsafe.Pointer(in.AutomountServiceAccountToken)) return nil } +// Convert_v1_ServiceAccount_To_api_ServiceAccount is an autogenerated conversion function. func Convert_v1_ServiceAccount_To_api_ServiceAccount(in *ServiceAccount, out *api.ServiceAccount, s conversion.Scope) error { return autoConvert_v1_ServiceAccount_To_api_ServiceAccount(in, out, s) } func autoConvert_api_ServiceAccount_To_v1_ServiceAccount(in *api.ServiceAccount, out *ServiceAccount, s conversion.Scope) error { - if err := Convert_api_ObjectMeta_To_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, s); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Secrets = *(*[]ObjectReference)(unsafe.Pointer(&in.Secrets)) out.ImagePullSecrets = *(*[]LocalObjectReference)(unsafe.Pointer(&in.ImagePullSecrets)) + out.AutomountServiceAccountToken = (*bool)(unsafe.Pointer(in.AutomountServiceAccountToken)) return nil } +// Convert_api_ServiceAccount_To_v1_ServiceAccount is an autogenerated conversion function. func Convert_api_ServiceAccount_To_v1_ServiceAccount(in *api.ServiceAccount, out *ServiceAccount, s conversion.Scope) error { return autoConvert_api_ServiceAccount_To_v1_ServiceAccount(in, out, s) } @@ -4008,16 +4639,22 @@ func autoConvert_v1_ServiceAccountList_To_api_ServiceAccountList(in *ServiceAcco return nil } +// Convert_v1_ServiceAccountList_To_api_ServiceAccountList is an autogenerated conversion function. func Convert_v1_ServiceAccountList_To_api_ServiceAccountList(in *ServiceAccountList, out *api.ServiceAccountList, s conversion.Scope) error { return autoConvert_v1_ServiceAccountList_To_api_ServiceAccountList(in, out, s) } func autoConvert_api_ServiceAccountList_To_v1_ServiceAccountList(in *api.ServiceAccountList, out *ServiceAccountList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]ServiceAccount)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]ServiceAccount, 0) + } else { + out.Items = *(*[]ServiceAccount)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_api_ServiceAccountList_To_v1_ServiceAccountList is an autogenerated conversion function. func Convert_api_ServiceAccountList_To_v1_ServiceAccountList(in *api.ServiceAccountList, out *ServiceAccountList, s conversion.Scope) error { return autoConvert_api_ServiceAccountList_To_v1_ServiceAccountList(in, out, s) } @@ -4038,6 +4675,7 @@ func autoConvert_v1_ServiceList_To_api_ServiceList(in *ServiceList, out *api.Ser return nil } +// Convert_v1_ServiceList_To_api_ServiceList is an autogenerated conversion function. func Convert_v1_ServiceList_To_api_ServiceList(in *ServiceList, out *api.ServiceList, s conversion.Scope) error { return autoConvert_v1_ServiceList_To_api_ServiceList(in, out, s) } @@ -4053,11 +4691,12 @@ func autoConvert_api_ServiceList_To_v1_ServiceList(in *api.ServiceList, out *Ser } } } else { - out.Items = nil + out.Items = make([]Service, 0) } return nil } +// Convert_api_ServiceList_To_v1_ServiceList is an autogenerated conversion function. func Convert_api_ServiceList_To_v1_ServiceList(in *api.ServiceList, out *ServiceList, s conversion.Scope) error { return autoConvert_api_ServiceList_To_v1_ServiceList(in, out, s) } @@ -4071,6 +4710,7 @@ func autoConvert_v1_ServicePort_To_api_ServicePort(in *ServicePort, out *api.Ser return nil } +// Convert_v1_ServicePort_To_api_ServicePort is an autogenerated conversion function. func Convert_v1_ServicePort_To_api_ServicePort(in *ServicePort, out *api.ServicePort, s conversion.Scope) error { return autoConvert_v1_ServicePort_To_api_ServicePort(in, out, s) } @@ -4084,6 +4724,7 @@ func autoConvert_api_ServicePort_To_v1_ServicePort(in *api.ServicePort, out *Ser return nil } +// Convert_api_ServicePort_To_v1_ServicePort is an autogenerated conversion function. func Convert_api_ServicePort_To_v1_ServicePort(in *api.ServicePort, out *ServicePort, s conversion.Scope) error { return autoConvert_api_ServicePort_To_v1_ServicePort(in, out, s) } @@ -4093,6 +4734,7 @@ func autoConvert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions(in *ServicePr return nil } +// Convert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions is an autogenerated conversion function. func Convert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions(in *ServiceProxyOptions, out *api.ServiceProxyOptions, s conversion.Scope) error { return autoConvert_v1_ServiceProxyOptions_To_api_ServiceProxyOptions(in, out, s) } @@ -4102,6 +4744,7 @@ func autoConvert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions(in *api.Servi return nil } +// Convert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions is an autogenerated conversion function. func Convert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions(in *api.ServiceProxyOptions, out *ServiceProxyOptions, s conversion.Scope) error { return autoConvert_api_ServiceProxyOptions_To_v1_ServiceProxyOptions(in, out, s) } @@ -4112,14 +4755,20 @@ func autoConvert_v1_ServiceSpec_To_api_ServiceSpec(in *ServiceSpec, out *api.Ser out.ClusterIP = in.ClusterIP out.Type = api.ServiceType(in.Type) out.ExternalIPs = *(*[]string)(unsafe.Pointer(&in.ExternalIPs)) - // INFO: in.DeprecatedPublicIPs opted out of conversion generation out.SessionAffinity = api.ServiceAffinity(in.SessionAffinity) out.LoadBalancerIP = in.LoadBalancerIP out.LoadBalancerSourceRanges = *(*[]string)(unsafe.Pointer(&in.LoadBalancerSourceRanges)) out.ExternalName = in.ExternalName + out.ExternalTrafficPolicy = api.ServiceExternalTrafficPolicyType(in.ExternalTrafficPolicy) + out.HealthCheckNodePort = in.HealthCheckNodePort return nil } +// Convert_v1_ServiceSpec_To_api_ServiceSpec is an autogenerated conversion function. +func Convert_v1_ServiceSpec_To_api_ServiceSpec(in *ServiceSpec, out *api.ServiceSpec, s conversion.Scope) error { + return autoConvert_v1_ServiceSpec_To_api_ServiceSpec(in, out, s) +} + func autoConvert_api_ServiceSpec_To_v1_ServiceSpec(in *api.ServiceSpec, out *ServiceSpec, s conversion.Scope) error { out.Type = ServiceType(in.Type) out.Ports = *(*[]ServicePort)(unsafe.Pointer(&in.Ports)) @@ -4130,9 +4779,16 @@ func autoConvert_api_ServiceSpec_To_v1_ServiceSpec(in *api.ServiceSpec, out *Ser out.LoadBalancerIP = in.LoadBalancerIP out.SessionAffinity = ServiceAffinity(in.SessionAffinity) out.LoadBalancerSourceRanges = *(*[]string)(unsafe.Pointer(&in.LoadBalancerSourceRanges)) + out.ExternalTrafficPolicy = ServiceExternalTrafficPolicyType(in.ExternalTrafficPolicy) + out.HealthCheckNodePort = in.HealthCheckNodePort return nil } +// Convert_api_ServiceSpec_To_v1_ServiceSpec is an autogenerated conversion function. +func Convert_api_ServiceSpec_To_v1_ServiceSpec(in *api.ServiceSpec, out *ServiceSpec, s conversion.Scope) error { + return autoConvert_api_ServiceSpec_To_v1_ServiceSpec(in, out, s) +} + func autoConvert_v1_ServiceStatus_To_api_ServiceStatus(in *ServiceStatus, out *api.ServiceStatus, s conversion.Scope) error { if err := Convert_v1_LoadBalancerStatus_To_api_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, s); err != nil { return err @@ -4140,6 +4796,7 @@ func autoConvert_v1_ServiceStatus_To_api_ServiceStatus(in *ServiceStatus, out *a return nil } +// Convert_v1_ServiceStatus_To_api_ServiceStatus is an autogenerated conversion function. func Convert_v1_ServiceStatus_To_api_ServiceStatus(in *ServiceStatus, out *api.ServiceStatus, s conversion.Scope) error { return autoConvert_v1_ServiceStatus_To_api_ServiceStatus(in, out, s) } @@ -4151,24 +4808,107 @@ func autoConvert_api_ServiceStatus_To_v1_ServiceStatus(in *api.ServiceStatus, ou return nil } +// Convert_api_ServiceStatus_To_v1_ServiceStatus is an autogenerated conversion function. func Convert_api_ServiceStatus_To_v1_ServiceStatus(in *api.ServiceStatus, out *ServiceStatus, s conversion.Scope) error { return autoConvert_api_ServiceStatus_To_v1_ServiceStatus(in, out, s) } +func autoConvert_v1_StorageOSPersistentVolumeSource_To_api_StorageOSPersistentVolumeSource(in *StorageOSPersistentVolumeSource, out *api.StorageOSPersistentVolumeSource, s conversion.Scope) error { + out.VolumeName = in.VolumeName + out.VolumeNamespace = in.VolumeNamespace + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + out.SecretRef = (*api.ObjectReference)(unsafe.Pointer(in.SecretRef)) + return nil +} + +// Convert_v1_StorageOSPersistentVolumeSource_To_api_StorageOSPersistentVolumeSource is an autogenerated conversion function. +func Convert_v1_StorageOSPersistentVolumeSource_To_api_StorageOSPersistentVolumeSource(in *StorageOSPersistentVolumeSource, out *api.StorageOSPersistentVolumeSource, s conversion.Scope) error { + return autoConvert_v1_StorageOSPersistentVolumeSource_To_api_StorageOSPersistentVolumeSource(in, out, s) +} + +func autoConvert_api_StorageOSPersistentVolumeSource_To_v1_StorageOSPersistentVolumeSource(in *api.StorageOSPersistentVolumeSource, out *StorageOSPersistentVolumeSource, s conversion.Scope) error { + out.VolumeName = in.VolumeName + out.VolumeNamespace = in.VolumeNamespace + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + out.SecretRef = (*ObjectReference)(unsafe.Pointer(in.SecretRef)) + return nil +} + +// Convert_api_StorageOSPersistentVolumeSource_To_v1_StorageOSPersistentVolumeSource is an autogenerated conversion function. +func Convert_api_StorageOSPersistentVolumeSource_To_v1_StorageOSPersistentVolumeSource(in *api.StorageOSPersistentVolumeSource, out *StorageOSPersistentVolumeSource, s conversion.Scope) error { + return autoConvert_api_StorageOSPersistentVolumeSource_To_v1_StorageOSPersistentVolumeSource(in, out, s) +} + +func autoConvert_v1_StorageOSVolumeSource_To_api_StorageOSVolumeSource(in *StorageOSVolumeSource, out *api.StorageOSVolumeSource, s conversion.Scope) error { + out.VolumeName = in.VolumeName + out.VolumeNamespace = in.VolumeNamespace + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + out.SecretRef = (*api.LocalObjectReference)(unsafe.Pointer(in.SecretRef)) + return nil +} + +// Convert_v1_StorageOSVolumeSource_To_api_StorageOSVolumeSource is an autogenerated conversion function. +func Convert_v1_StorageOSVolumeSource_To_api_StorageOSVolumeSource(in *StorageOSVolumeSource, out *api.StorageOSVolumeSource, s conversion.Scope) error { + return autoConvert_v1_StorageOSVolumeSource_To_api_StorageOSVolumeSource(in, out, s) +} + +func autoConvert_api_StorageOSVolumeSource_To_v1_StorageOSVolumeSource(in *api.StorageOSVolumeSource, out *StorageOSVolumeSource, s conversion.Scope) error { + out.VolumeName = in.VolumeName + out.VolumeNamespace = in.VolumeNamespace + out.FSType = in.FSType + out.ReadOnly = in.ReadOnly + out.SecretRef = (*LocalObjectReference)(unsafe.Pointer(in.SecretRef)) + return nil +} + +// Convert_api_StorageOSVolumeSource_To_v1_StorageOSVolumeSource is an autogenerated conversion function. +func Convert_api_StorageOSVolumeSource_To_v1_StorageOSVolumeSource(in *api.StorageOSVolumeSource, out *StorageOSVolumeSource, s conversion.Scope) error { + return autoConvert_api_StorageOSVolumeSource_To_v1_StorageOSVolumeSource(in, out, s) +} + +func autoConvert_v1_Sysctl_To_api_Sysctl(in *Sysctl, out *api.Sysctl, s conversion.Scope) error { + out.Name = in.Name + out.Value = in.Value + return nil +} + +// Convert_v1_Sysctl_To_api_Sysctl is an autogenerated conversion function. +func Convert_v1_Sysctl_To_api_Sysctl(in *Sysctl, out *api.Sysctl, s conversion.Scope) error { + return autoConvert_v1_Sysctl_To_api_Sysctl(in, out, s) +} + +func autoConvert_api_Sysctl_To_v1_Sysctl(in *api.Sysctl, out *Sysctl, s conversion.Scope) error { + out.Name = in.Name + out.Value = in.Value + return nil +} + +// Convert_api_Sysctl_To_v1_Sysctl is an autogenerated conversion function. +func Convert_api_Sysctl_To_v1_Sysctl(in *api.Sysctl, out *Sysctl, s conversion.Scope) error { + return autoConvert_api_Sysctl_To_v1_Sysctl(in, out, s) +} + func autoConvert_v1_TCPSocketAction_To_api_TCPSocketAction(in *TCPSocketAction, out *api.TCPSocketAction, s conversion.Scope) error { out.Port = in.Port + out.Host = in.Host return nil } +// Convert_v1_TCPSocketAction_To_api_TCPSocketAction is an autogenerated conversion function. func Convert_v1_TCPSocketAction_To_api_TCPSocketAction(in *TCPSocketAction, out *api.TCPSocketAction, s conversion.Scope) error { return autoConvert_v1_TCPSocketAction_To_api_TCPSocketAction(in, out, s) } func autoConvert_api_TCPSocketAction_To_v1_TCPSocketAction(in *api.TCPSocketAction, out *TCPSocketAction, s conversion.Scope) error { out.Port = in.Port + out.Host = in.Host return nil } +// Convert_api_TCPSocketAction_To_v1_TCPSocketAction is an autogenerated conversion function. func Convert_api_TCPSocketAction_To_v1_TCPSocketAction(in *api.TCPSocketAction, out *TCPSocketAction, s conversion.Scope) error { return autoConvert_api_TCPSocketAction_To_v1_TCPSocketAction(in, out, s) } @@ -4177,9 +4917,11 @@ func autoConvert_v1_Taint_To_api_Taint(in *Taint, out *api.Taint, s conversion.S out.Key = in.Key out.Value = in.Value out.Effect = api.TaintEffect(in.Effect) + out.TimeAdded = in.TimeAdded return nil } +// Convert_v1_Taint_To_api_Taint is an autogenerated conversion function. func Convert_v1_Taint_To_api_Taint(in *Taint, out *api.Taint, s conversion.Scope) error { return autoConvert_v1_Taint_To_api_Taint(in, out, s) } @@ -4188,9 +4930,11 @@ func autoConvert_api_Taint_To_v1_Taint(in *api.Taint, out *Taint, s conversion.S out.Key = in.Key out.Value = in.Value out.Effect = TaintEffect(in.Effect) + out.TimeAdded = in.TimeAdded return nil } +// Convert_api_Taint_To_v1_Taint is an autogenerated conversion function. func Convert_api_Taint_To_v1_Taint(in *api.Taint, out *Taint, s conversion.Scope) error { return autoConvert_api_Taint_To_v1_Taint(in, out, s) } @@ -4200,9 +4944,11 @@ func autoConvert_v1_Toleration_To_api_Toleration(in *Toleration, out *api.Tolera out.Operator = api.TolerationOperator(in.Operator) out.Value = in.Value out.Effect = api.TaintEffect(in.Effect) + out.TolerationSeconds = (*int64)(unsafe.Pointer(in.TolerationSeconds)) return nil } +// Convert_v1_Toleration_To_api_Toleration is an autogenerated conversion function. func Convert_v1_Toleration_To_api_Toleration(in *Toleration, out *api.Toleration, s conversion.Scope) error { return autoConvert_v1_Toleration_To_api_Toleration(in, out, s) } @@ -4212,9 +4958,11 @@ func autoConvert_api_Toleration_To_v1_Toleration(in *api.Toleration, out *Tolera out.Operator = TolerationOperator(in.Operator) out.Value = in.Value out.Effect = TaintEffect(in.Effect) + out.TolerationSeconds = (*int64)(unsafe.Pointer(in.TolerationSeconds)) return nil } +// Convert_api_Toleration_To_v1_Toleration is an autogenerated conversion function. func Convert_api_Toleration_To_v1_Toleration(in *api.Toleration, out *Toleration, s conversion.Scope) error { return autoConvert_api_Toleration_To_v1_Toleration(in, out, s) } @@ -4227,6 +4975,7 @@ func autoConvert_v1_Volume_To_api_Volume(in *Volume, out *api.Volume, s conversi return nil } +// Convert_v1_Volume_To_api_Volume is an autogenerated conversion function. func Convert_v1_Volume_To_api_Volume(in *Volume, out *api.Volume, s conversion.Scope) error { return autoConvert_v1_Volume_To_api_Volume(in, out, s) } @@ -4239,6 +4988,7 @@ func autoConvert_api_Volume_To_v1_Volume(in *api.Volume, out *Volume, s conversi return nil } +// Convert_api_Volume_To_v1_Volume is an autogenerated conversion function. func Convert_api_Volume_To_v1_Volume(in *api.Volume, out *Volume, s conversion.Scope) error { return autoConvert_api_Volume_To_v1_Volume(in, out, s) } @@ -4251,6 +5001,7 @@ func autoConvert_v1_VolumeMount_To_api_VolumeMount(in *VolumeMount, out *api.Vol return nil } +// Convert_v1_VolumeMount_To_api_VolumeMount is an autogenerated conversion function. func Convert_v1_VolumeMount_To_api_VolumeMount(in *VolumeMount, out *api.VolumeMount, s conversion.Scope) error { return autoConvert_v1_VolumeMount_To_api_VolumeMount(in, out, s) } @@ -4263,10 +5014,35 @@ func autoConvert_api_VolumeMount_To_v1_VolumeMount(in *api.VolumeMount, out *Vol return nil } +// Convert_api_VolumeMount_To_v1_VolumeMount is an autogenerated conversion function. func Convert_api_VolumeMount_To_v1_VolumeMount(in *api.VolumeMount, out *VolumeMount, s conversion.Scope) error { return autoConvert_api_VolumeMount_To_v1_VolumeMount(in, out, s) } +func autoConvert_v1_VolumeProjection_To_api_VolumeProjection(in *VolumeProjection, out *api.VolumeProjection, s conversion.Scope) error { + out.Secret = (*api.SecretProjection)(unsafe.Pointer(in.Secret)) + out.DownwardAPI = (*api.DownwardAPIProjection)(unsafe.Pointer(in.DownwardAPI)) + out.ConfigMap = (*api.ConfigMapProjection)(unsafe.Pointer(in.ConfigMap)) + return nil +} + +// Convert_v1_VolumeProjection_To_api_VolumeProjection is an autogenerated conversion function. +func Convert_v1_VolumeProjection_To_api_VolumeProjection(in *VolumeProjection, out *api.VolumeProjection, s conversion.Scope) error { + return autoConvert_v1_VolumeProjection_To_api_VolumeProjection(in, out, s) +} + +func autoConvert_api_VolumeProjection_To_v1_VolumeProjection(in *api.VolumeProjection, out *VolumeProjection, s conversion.Scope) error { + out.Secret = (*SecretProjection)(unsafe.Pointer(in.Secret)) + out.DownwardAPI = (*DownwardAPIProjection)(unsafe.Pointer(in.DownwardAPI)) + out.ConfigMap = (*ConfigMapProjection)(unsafe.Pointer(in.ConfigMap)) + return nil +} + +// Convert_api_VolumeProjection_To_v1_VolumeProjection is an autogenerated conversion function. +func Convert_api_VolumeProjection_To_v1_VolumeProjection(in *api.VolumeProjection, out *VolumeProjection, s conversion.Scope) error { + return autoConvert_api_VolumeProjection_To_v1_VolumeProjection(in, out, s) +} + func autoConvert_v1_VolumeSource_To_api_VolumeSource(in *VolumeSource, out *api.VolumeSource, s conversion.Scope) error { out.HostPath = (*api.HostPathVolumeSource)(unsafe.Pointer(in.HostPath)) out.EmptyDir = (*api.EmptyDirVolumeSource)(unsafe.Pointer(in.EmptyDir)) @@ -4291,9 +5067,14 @@ func autoConvert_v1_VolumeSource_To_api_VolumeSource(in *VolumeSource, out *api. out.Quobyte = (*api.QuobyteVolumeSource)(unsafe.Pointer(in.Quobyte)) out.AzureDisk = (*api.AzureDiskVolumeSource)(unsafe.Pointer(in.AzureDisk)) out.PhotonPersistentDisk = (*api.PhotonPersistentDiskVolumeSource)(unsafe.Pointer(in.PhotonPersistentDisk)) + out.Projected = (*api.ProjectedVolumeSource)(unsafe.Pointer(in.Projected)) + out.PortworxVolume = (*api.PortworxVolumeSource)(unsafe.Pointer(in.PortworxVolume)) + out.ScaleIO = (*api.ScaleIOVolumeSource)(unsafe.Pointer(in.ScaleIO)) + out.StorageOS = (*api.StorageOSVolumeSource)(unsafe.Pointer(in.StorageOS)) return nil } +// Convert_v1_VolumeSource_To_api_VolumeSource is an autogenerated conversion function. func Convert_v1_VolumeSource_To_api_VolumeSource(in *VolumeSource, out *api.VolumeSource, s conversion.Scope) error { return autoConvert_v1_VolumeSource_To_api_VolumeSource(in, out, s) } @@ -4322,9 +5103,14 @@ func autoConvert_api_VolumeSource_To_v1_VolumeSource(in *api.VolumeSource, out * out.VsphereVolume = (*VsphereVirtualDiskVolumeSource)(unsafe.Pointer(in.VsphereVolume)) out.AzureDisk = (*AzureDiskVolumeSource)(unsafe.Pointer(in.AzureDisk)) out.PhotonPersistentDisk = (*PhotonPersistentDiskVolumeSource)(unsafe.Pointer(in.PhotonPersistentDisk)) + out.Projected = (*ProjectedVolumeSource)(unsafe.Pointer(in.Projected)) + out.PortworxVolume = (*PortworxVolumeSource)(unsafe.Pointer(in.PortworxVolume)) + out.ScaleIO = (*ScaleIOVolumeSource)(unsafe.Pointer(in.ScaleIO)) + out.StorageOS = (*StorageOSVolumeSource)(unsafe.Pointer(in.StorageOS)) return nil } +// Convert_api_VolumeSource_To_v1_VolumeSource is an autogenerated conversion function. func Convert_api_VolumeSource_To_v1_VolumeSource(in *api.VolumeSource, out *VolumeSource, s conversion.Scope) error { return autoConvert_api_VolumeSource_To_v1_VolumeSource(in, out, s) } @@ -4332,9 +5118,12 @@ func Convert_api_VolumeSource_To_v1_VolumeSource(in *api.VolumeSource, out *Volu func autoConvert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(in *VsphereVirtualDiskVolumeSource, out *api.VsphereVirtualDiskVolumeSource, s conversion.Scope) error { out.VolumePath = in.VolumePath out.FSType = in.FSType + out.StoragePolicyName = in.StoragePolicyName + out.StoragePolicyID = in.StoragePolicyID return nil } +// Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource is an autogenerated conversion function. func Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(in *VsphereVirtualDiskVolumeSource, out *api.VsphereVirtualDiskVolumeSource, s conversion.Scope) error { return autoConvert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSource(in, out, s) } @@ -4342,9 +5131,12 @@ func Convert_v1_VsphereVirtualDiskVolumeSource_To_api_VsphereVirtualDiskVolumeSo func autoConvert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(in *api.VsphereVirtualDiskVolumeSource, out *VsphereVirtualDiskVolumeSource, s conversion.Scope) error { out.VolumePath = in.VolumePath out.FSType = in.FSType + out.StoragePolicyName = in.StoragePolicyName + out.StoragePolicyID = in.StoragePolicyID return nil } +// Convert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource is an autogenerated conversion function. func Convert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(in *api.VsphereVirtualDiskVolumeSource, out *VsphereVirtualDiskVolumeSource, s conversion.Scope) error { return autoConvert_api_VsphereVirtualDiskVolumeSource_To_v1_VsphereVirtualDiskVolumeSource(in, out, s) } @@ -4357,6 +5149,7 @@ func autoConvert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(in *W return nil } +// Convert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm is an autogenerated conversion function. func Convert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(in *WeightedPodAffinityTerm, out *api.WeightedPodAffinityTerm, s conversion.Scope) error { return autoConvert_v1_WeightedPodAffinityTerm_To_api_WeightedPodAffinityTerm(in, out, s) } @@ -4369,6 +5162,7 @@ func autoConvert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(in *a return nil } +// Convert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm is an autogenerated conversion function. func Convert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(in *api.WeightedPodAffinityTerm, out *WeightedPodAffinityTerm, s conversion.Scope) error { return autoConvert_api_WeightedPodAffinityTerm_To_v1_WeightedPodAffinityTerm(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go index 3a79f13832..b909d9b332 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package v1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - types "k8s.io/client-go/pkg/types" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + types "k8s.io/apimachinery/pkg/types" reflect "reflect" ) @@ -50,8 +50,10 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ComponentStatus, InType: reflect.TypeOf(&ComponentStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ComponentStatusList, InType: reflect.TypeOf(&ComponentStatusList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ConfigMap, InType: reflect.TypeOf(&ConfigMap{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ConfigMapEnvSource, InType: reflect.TypeOf(&ConfigMapEnvSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ConfigMapKeySelector, InType: reflect.TypeOf(&ConfigMapKeySelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ConfigMapList, InType: reflect.TypeOf(&ConfigMapList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ConfigMapProjection, InType: reflect.TypeOf(&ConfigMapProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ConfigMapVolumeSource, InType: reflect.TypeOf(&ConfigMapVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Container, InType: reflect.TypeOf(&Container{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ContainerImage, InType: reflect.TypeOf(&ContainerImage{})}, @@ -63,6 +65,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ContainerStatus, InType: reflect.TypeOf(&ContainerStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_DaemonEndpoint, InType: reflect.TypeOf(&DaemonEndpoint{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_DeleteOptions, InType: reflect.TypeOf(&DeleteOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_DownwardAPIProjection, InType: reflect.TypeOf(&DownwardAPIProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_DownwardAPIVolumeFile, InType: reflect.TypeOf(&DownwardAPIVolumeFile{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_DownwardAPIVolumeSource, InType: reflect.TypeOf(&DownwardAPIVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EmptyDirVolumeSource, InType: reflect.TypeOf(&EmptyDirVolumeSource{})}, @@ -71,13 +74,13 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EndpointSubset, InType: reflect.TypeOf(&EndpointSubset{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Endpoints, InType: reflect.TypeOf(&Endpoints{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EndpointsList, InType: reflect.TypeOf(&EndpointsList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EnvFromSource, InType: reflect.TypeOf(&EnvFromSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EnvVar, InType: reflect.TypeOf(&EnvVar{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EnvVarSource, InType: reflect.TypeOf(&EnvVarSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Event, InType: reflect.TypeOf(&Event{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EventList, InType: reflect.TypeOf(&EventList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_EventSource, InType: reflect.TypeOf(&EventSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ExecAction, InType: reflect.TypeOf(&ExecAction{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ExportOptions, InType: reflect.TypeOf(&ExportOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_FCVolumeSource, InType: reflect.TypeOf(&FCVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_FlexVolumeSource, InType: reflect.TypeOf(&FlexVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_FlockerVolumeSource, InType: reflect.TypeOf(&FlockerVolumeSource{})}, @@ -87,6 +90,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HTTPGetAction, InType: reflect.TypeOf(&HTTPGetAction{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HTTPHeader, InType: reflect.TypeOf(&HTTPHeader{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Handler, InType: reflect.TypeOf(&Handler{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HostAlias, InType: reflect.TypeOf(&HostAlias{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HostPathVolumeSource, InType: reflect.TypeOf(&HostPathVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ISCSIVolumeSource, InType: reflect.TypeOf(&ISCSIVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_KeyToPath, InType: reflect.TypeOf(&KeyToPath{})}, @@ -100,6 +104,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_LoadBalancerIngress, InType: reflect.TypeOf(&LoadBalancerIngress{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_LoadBalancerStatus, InType: reflect.TypeOf(&LoadBalancerStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_LocalObjectReference, InType: reflect.TypeOf(&LocalObjectReference{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_LocalVolumeSource, InType: reflect.TypeOf(&LocalVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NFSVolumeSource, InType: reflect.TypeOf(&NFSVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Namespace, InType: reflect.TypeOf(&Namespace{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NamespaceList, InType: reflect.TypeOf(&NamespaceList{})}, @@ -112,6 +117,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeDaemonEndpoints, InType: reflect.TypeOf(&NodeDaemonEndpoints{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeList, InType: reflect.TypeOf(&NodeList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeProxyOptions, InType: reflect.TypeOf(&NodeProxyOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeResources, InType: reflect.TypeOf(&NodeResources{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeSelector, InType: reflect.TypeOf(&NodeSelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeSelectorRequirement, InType: reflect.TypeOf(&NodeSelectorRequirement{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NodeSelectorTerm, InType: reflect.TypeOf(&NodeSelectorTerm{})}, @@ -121,7 +127,6 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ObjectFieldSelector, InType: reflect.TypeOf(&ObjectFieldSelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ObjectMeta, InType: reflect.TypeOf(&ObjectMeta{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ObjectReference, InType: reflect.TypeOf(&ObjectReference{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_OwnerReference, InType: reflect.TypeOf(&OwnerReference{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PersistentVolume, InType: reflect.TypeOf(&PersistentVolume{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PersistentVolumeClaim, InType: reflect.TypeOf(&PersistentVolumeClaim{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PersistentVolumeClaimList, InType: reflect.TypeOf(&PersistentVolumeClaimList{})}, @@ -142,6 +147,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodExecOptions, InType: reflect.TypeOf(&PodExecOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodList, InType: reflect.TypeOf(&PodList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodLogOptions, InType: reflect.TypeOf(&PodLogOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodPortForwardOptions, InType: reflect.TypeOf(&PodPortForwardOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodProxyOptions, InType: reflect.TypeOf(&PodProxyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodSecurityContext, InType: reflect.TypeOf(&PodSecurityContext{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodSignature, InType: reflect.TypeOf(&PodSignature{})}, @@ -151,10 +157,12 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodTemplate, InType: reflect.TypeOf(&PodTemplate{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodTemplateList, InType: reflect.TypeOf(&PodTemplateList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodTemplateSpec, InType: reflect.TypeOf(&PodTemplateSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PortworxVolumeSource, InType: reflect.TypeOf(&PortworxVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Preconditions, InType: reflect.TypeOf(&Preconditions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PreferAvoidPodsEntry, InType: reflect.TypeOf(&PreferAvoidPodsEntry{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PreferredSchedulingTerm, InType: reflect.TypeOf(&PreferredSchedulingTerm{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Probe, InType: reflect.TypeOf(&Probe{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ProjectedVolumeSource, InType: reflect.TypeOf(&ProjectedVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_QuobyteVolumeSource, InType: reflect.TypeOf(&QuobyteVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_RBDVolumeSource, InType: reflect.TypeOf(&RBDVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_RangeAllocation, InType: reflect.TypeOf(&RangeAllocation{})}, @@ -170,9 +178,12 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ResourceQuotaStatus, InType: reflect.TypeOf(&ResourceQuotaStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ResourceRequirements, InType: reflect.TypeOf(&ResourceRequirements{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SELinuxOptions, InType: reflect.TypeOf(&SELinuxOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ScaleIOVolumeSource, InType: reflect.TypeOf(&ScaleIOVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Secret, InType: reflect.TypeOf(&Secret{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SecretEnvSource, InType: reflect.TypeOf(&SecretEnvSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SecretKeySelector, InType: reflect.TypeOf(&SecretKeySelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SecretList, InType: reflect.TypeOf(&SecretList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SecretProjection, InType: reflect.TypeOf(&SecretProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SecretVolumeSource, InType: reflect.TypeOf(&SecretVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SecurityContext, InType: reflect.TypeOf(&SecurityContext{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SerializedReference, InType: reflect.TypeOf(&SerializedReference{})}, @@ -184,41 +195,43 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ServiceProxyOptions, InType: reflect.TypeOf(&ServiceProxyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ServiceSpec, InType: reflect.TypeOf(&ServiceSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ServiceStatus, InType: reflect.TypeOf(&ServiceStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_StorageOSPersistentVolumeSource, InType: reflect.TypeOf(&StorageOSPersistentVolumeSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_StorageOSVolumeSource, InType: reflect.TypeOf(&StorageOSVolumeSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Sysctl, InType: reflect.TypeOf(&Sysctl{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_TCPSocketAction, InType: reflect.TypeOf(&TCPSocketAction{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Taint, InType: reflect.TypeOf(&Taint{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Toleration, InType: reflect.TypeOf(&Toleration{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Volume, InType: reflect.TypeOf(&Volume{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_VolumeMount, InType: reflect.TypeOf(&VolumeMount{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_VolumeProjection, InType: reflect.TypeOf(&VolumeProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_VolumeSource, InType: reflect.TypeOf(&VolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_VsphereVirtualDiskVolumeSource, InType: reflect.TypeOf(&VsphereVirtualDiskVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_WeightedPodAffinityTerm, InType: reflect.TypeOf(&WeightedPodAffinityTerm{})}, ) } +// DeepCopy_v1_AWSElasticBlockStoreVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_AWSElasticBlockStoreVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AWSElasticBlockStoreVolumeSource) out := out.(*AWSElasticBlockStoreVolumeSource) - out.VolumeID = in.VolumeID - out.FSType = in.FSType - out.Partition = in.Partition - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_Affinity is an autogenerated deepcopy function. func DeepCopy_v1_Affinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Affinity) out := out.(*Affinity) + *out = *in if in.NodeAffinity != nil { in, out := &in.NodeAffinity, &out.NodeAffinity *out = new(NodeAffinity) if err := DeepCopy_v1_NodeAffinity(*in, *out, c); err != nil { return err } - } else { - out.NodeAffinity = nil } if in.PodAffinity != nil { in, out := &in.PodAffinity, &out.PodAffinity @@ -226,8 +239,6 @@ func DeepCopy_v1_Affinity(in interface{}, out interface{}, c *conversion.Cloner) if err := DeepCopy_v1_PodAffinity(*in, *out, c); err != nil { return err } - } else { - out.PodAffinity = nil } if in.PodAntiAffinity != nil { in, out := &in.PodAntiAffinity, &out.PodAntiAffinity @@ -235,27 +246,27 @@ func DeepCopy_v1_Affinity(in interface{}, out interface{}, c *conversion.Cloner) if err := DeepCopy_v1_PodAntiAffinity(*in, *out, c); err != nil { return err } - } else { - out.PodAntiAffinity = nil } return nil } } +// DeepCopy_v1_AttachedVolume is an autogenerated deepcopy function. func DeepCopy_v1_AttachedVolume(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AttachedVolume) out := out.(*AttachedVolume) - out.Name = in.Name - out.DevicePath = in.DevicePath + *out = *in return nil } } +// DeepCopy_v1_AvoidPods is an autogenerated deepcopy function. func DeepCopy_v1_AvoidPods(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AvoidPods) out := out.(*AvoidPods) + *out = *in if in.PreferAvoidPods != nil { in, out := &in.PreferAvoidPods, &out.PreferAvoidPods *out = make([]PreferAvoidPodsEntry, len(*in)) @@ -264,170 +275,152 @@ func DeepCopy_v1_AvoidPods(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.PreferAvoidPods = nil } return nil } } +// DeepCopy_v1_AzureDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_AzureDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AzureDiskVolumeSource) out := out.(*AzureDiskVolumeSource) - out.DiskName = in.DiskName - out.DataDiskURI = in.DataDiskURI + *out = *in if in.CachingMode != nil { in, out := &in.CachingMode, &out.CachingMode *out = new(AzureDataDiskCachingMode) **out = **in - } else { - out.CachingMode = nil } if in.FSType != nil { in, out := &in.FSType, &out.FSType *out = new(string) **out = **in - } else { - out.FSType = nil } if in.ReadOnly != nil { in, out := &in.ReadOnly, &out.ReadOnly *out = new(bool) **out = **in - } else { - out.ReadOnly = nil + } + if in.Kind != nil { + in, out := &in.Kind, &out.Kind + *out = new(AzureDataDiskKind) + **out = **in } return nil } } +// DeepCopy_v1_AzureFileVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_AzureFileVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AzureFileVolumeSource) out := out.(*AzureFileVolumeSource) - out.SecretName = in.SecretName - out.ShareName = in.ShareName - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_Binding is an autogenerated deepcopy function. func DeepCopy_v1_Binding(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Binding) out := out.(*Binding) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } - out.Target = in.Target return nil } } +// DeepCopy_v1_Capabilities is an autogenerated deepcopy function. func DeepCopy_v1_Capabilities(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Capabilities) out := out.(*Capabilities) + *out = *in if in.Add != nil { in, out := &in.Add, &out.Add *out = make([]Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Add = nil + copy(*out, *in) } if in.Drop != nil { in, out := &in.Drop, &out.Drop *out = make([]Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Drop = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_CephFSVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_CephFSVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CephFSVolumeSource) out := out.(*CephFSVolumeSource) + *out = *in if in.Monitors != nil { in, out := &in.Monitors, &out.Monitors *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Monitors = nil } - out.Path = in.Path - out.User = in.User - out.SecretFile = in.SecretFile if in.SecretRef != nil { in, out := &in.SecretRef, &out.SecretRef *out = new(LocalObjectReference) **out = **in - } else { - out.SecretRef = nil } - out.ReadOnly = in.ReadOnly return nil } } +// DeepCopy_v1_CinderVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_CinderVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CinderVolumeSource) out := out.(*CinderVolumeSource) - out.VolumeID = in.VolumeID - out.FSType = in.FSType - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_ComponentCondition is an autogenerated deepcopy function. func DeepCopy_v1_ComponentCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ComponentCondition) out := out.(*ComponentCondition) - out.Type = in.Type - out.Status = in.Status - out.Message = in.Message - out.Error = in.Error + *out = *in return nil } } +// DeepCopy_v1_ComponentStatus is an autogenerated deepcopy function. func DeepCopy_v1_ComponentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ComponentStatus) out := out.(*ComponentStatus) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]ComponentCondition, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Conditions = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_ComponentStatusList is an autogenerated deepcopy function. func DeepCopy_v1_ComponentStatusList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ComponentStatusList) out := out.(*ComponentStatusList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ComponentStatus, len(*in)) @@ -436,20 +429,21 @@ func DeepCopy_v1_ComponentStatusList(in interface{}, out interface{}, c *convers return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ConfigMap is an autogenerated deepcopy function. func DeepCopy_v1_ConfigMap(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMap) out := out.(*ConfigMap) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if in.Data != nil { in, out := &in.Data, &out.Data @@ -457,29 +451,47 @@ func DeepCopy_v1_ConfigMap(in interface{}, out interface{}, c *conversion.Cloner for key, val := range *in { (*out)[key] = val } - } else { - out.Data = nil } return nil } } +// DeepCopy_v1_ConfigMapEnvSource is an autogenerated deepcopy function. +func DeepCopy_v1_ConfigMapEnvSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ConfigMapEnvSource) + out := out.(*ConfigMapEnvSource) + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_ConfigMapKeySelector is an autogenerated deepcopy function. func DeepCopy_v1_ConfigMapKeySelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMapKeySelector) out := out.(*ConfigMapKeySelector) - out.LocalObjectReference = in.LocalObjectReference - out.Key = in.Key + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } return nil } } +// DeepCopy_v1_ConfigMapList is an autogenerated deepcopy function. func DeepCopy_v1_ConfigMapList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMapList) out := out.(*ConfigMapList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ConfigMap, len(*in)) @@ -488,18 +500,41 @@ func DeepCopy_v1_ConfigMapList(in interface{}, out interface{}, c *conversion.Cl return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ConfigMapProjection is an autogenerated deepcopy function. +func DeepCopy_v1_ConfigMapProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ConfigMapProjection) + out := out.(*ConfigMapProjection) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]KeyToPath, len(*in)) + for i := range *in { + if err := DeepCopy_v1_KeyToPath(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_ConfigMapVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_ConfigMapVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMapVolumeSource) out := out.(*ConfigMapVolumeSource) - out.LocalObjectReference = in.LocalObjectReference + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]KeyToPath, len(*in)) @@ -508,49 +543,50 @@ func DeepCopy_v1_ConfigMapVolumeSource(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } if in.DefaultMode != nil { in, out := &in.DefaultMode, &out.DefaultMode *out = new(int32) **out = **in - } else { - out.DefaultMode = nil + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in } return nil } } +// DeepCopy_v1_Container is an autogenerated deepcopy function. func DeepCopy_v1_Container(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Container) out := out.(*Container) - out.Name = in.Name - out.Image = in.Image + *out = *in if in.Command != nil { in, out := &in.Command, &out.Command *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Command = nil } if in.Args != nil { in, out := &in.Args, &out.Args *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Args = nil } - out.WorkingDir = in.WorkingDir if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]ContainerPort, len(*in)) + copy(*out, *in) + } + if in.EnvFrom != nil { + in, out := &in.EnvFrom, &out.EnvFrom + *out = make([]EnvFromSource, len(*in)) for i := range *in { - (*out)[i] = (*in)[i] + if err := DeepCopy_v1_EnvFromSource(&(*in)[i], &(*out)[i], c); err != nil { + return err + } } - } else { - out.Ports = nil } if in.Env != nil { in, out := &in.Env, &out.Env @@ -560,8 +596,6 @@ func DeepCopy_v1_Container(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.Env = nil } if err := DeepCopy_v1_ResourceRequirements(&in.Resources, &out.Resources, c); err != nil { return err @@ -569,11 +603,7 @@ func DeepCopy_v1_Container(in interface{}, out interface{}, c *conversion.Cloner if in.VolumeMounts != nil { in, out := &in.VolumeMounts, &out.VolumeMounts *out = make([]VolumeMount, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.VolumeMounts = nil + copy(*out, *in) } if in.LivenessProbe != nil { in, out := &in.LivenessProbe, &out.LivenessProbe @@ -581,8 +611,6 @@ func DeepCopy_v1_Container(in interface{}, out interface{}, c *conversion.Cloner if err := DeepCopy_v1_Probe(*in, *out, c); err != nil { return err } - } else { - out.LivenessProbe = nil } if in.ReadinessProbe != nil { in, out := &in.ReadinessProbe, &out.ReadinessProbe @@ -590,8 +618,6 @@ func DeepCopy_v1_Container(in interface{}, out interface{}, c *conversion.Cloner if err := DeepCopy_v1_Probe(*in, *out, c); err != nil { return err } - } else { - out.ReadinessProbe = nil } if in.Lifecycle != nil { in, out := &in.Lifecycle, &out.Lifecycle @@ -599,66 +625,53 @@ func DeepCopy_v1_Container(in interface{}, out interface{}, c *conversion.Cloner if err := DeepCopy_v1_Lifecycle(*in, *out, c); err != nil { return err } - } else { - out.Lifecycle = nil } - out.TerminationMessagePath = in.TerminationMessagePath - out.ImagePullPolicy = in.ImagePullPolicy if in.SecurityContext != nil { in, out := &in.SecurityContext, &out.SecurityContext *out = new(SecurityContext) if err := DeepCopy_v1_SecurityContext(*in, *out, c); err != nil { return err } - } else { - out.SecurityContext = nil } - out.Stdin = in.Stdin - out.StdinOnce = in.StdinOnce - out.TTY = in.TTY return nil } } +// DeepCopy_v1_ContainerImage is an autogenerated deepcopy function. func DeepCopy_v1_ContainerImage(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerImage) out := out.(*ContainerImage) + *out = *in if in.Names != nil { in, out := &in.Names, &out.Names *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Names = nil } - out.SizeBytes = in.SizeBytes return nil } } +// DeepCopy_v1_ContainerPort is an autogenerated deepcopy function. func DeepCopy_v1_ContainerPort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerPort) out := out.(*ContainerPort) - out.Name = in.Name - out.HostPort = in.HostPort - out.ContainerPort = in.ContainerPort - out.Protocol = in.Protocol - out.HostIP = in.HostIP + *out = *in return nil } } +// DeepCopy_v1_ContainerState is an autogenerated deepcopy function. func DeepCopy_v1_ContainerState(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerState) out := out.(*ContainerState) + *out = *in if in.Waiting != nil { in, out := &in.Waiting, &out.Waiting *out = new(ContainerStateWaiting) **out = **in - } else { - out.Waiting = nil } if in.Running != nil { in, out := &in.Running, &out.Running @@ -666,8 +679,6 @@ func DeepCopy_v1_ContainerState(in interface{}, out interface{}, c *conversion.C if err := DeepCopy_v1_ContainerStateRunning(*in, *out, c); err != nil { return err } - } else { - out.Running = nil } if in.Terminated != nil { in, out := &in.Terminated, &out.Terminated @@ -675,87 +686,80 @@ func DeepCopy_v1_ContainerState(in interface{}, out interface{}, c *conversion.C if err := DeepCopy_v1_ContainerStateTerminated(*in, *out, c); err != nil { return err } - } else { - out.Terminated = nil } return nil } } +// DeepCopy_v1_ContainerStateRunning is an autogenerated deepcopy function. func DeepCopy_v1_ContainerStateRunning(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStateRunning) out := out.(*ContainerStateRunning) + *out = *in out.StartedAt = in.StartedAt.DeepCopy() return nil } } +// DeepCopy_v1_ContainerStateTerminated is an autogenerated deepcopy function. func DeepCopy_v1_ContainerStateTerminated(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStateTerminated) out := out.(*ContainerStateTerminated) - out.ExitCode = in.ExitCode - out.Signal = in.Signal - out.Reason = in.Reason - out.Message = in.Message + *out = *in out.StartedAt = in.StartedAt.DeepCopy() out.FinishedAt = in.FinishedAt.DeepCopy() - out.ContainerID = in.ContainerID return nil } } +// DeepCopy_v1_ContainerStateWaiting is an autogenerated deepcopy function. func DeepCopy_v1_ContainerStateWaiting(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStateWaiting) out := out.(*ContainerStateWaiting) - out.Reason = in.Reason - out.Message = in.Message + *out = *in return nil } } +// DeepCopy_v1_ContainerStatus is an autogenerated deepcopy function. func DeepCopy_v1_ContainerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStatus) out := out.(*ContainerStatus) - out.Name = in.Name + *out = *in if err := DeepCopy_v1_ContainerState(&in.State, &out.State, c); err != nil { return err } if err := DeepCopy_v1_ContainerState(&in.LastTerminationState, &out.LastTerminationState, c); err != nil { return err } - out.Ready = in.Ready - out.RestartCount = in.RestartCount - out.Image = in.Image - out.ImageID = in.ImageID - out.ContainerID = in.ContainerID return nil } } +// DeepCopy_v1_DaemonEndpoint is an autogenerated deepcopy function. func DeepCopy_v1_DaemonEndpoint(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonEndpoint) out := out.(*DaemonEndpoint) - out.Port = in.Port + *out = *in return nil } } +// DeepCopy_v1_DeleteOptions is an autogenerated deepcopy function. func DeepCopy_v1_DeleteOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeleteOptions) out := out.(*DeleteOptions) - out.TypeMeta = in.TypeMeta + *out = *in if in.GracePeriodSeconds != nil { in, out := &in.GracePeriodSeconds, &out.GracePeriodSeconds *out = new(int64) **out = **in - } else { - out.GracePeriodSeconds = nil } if in.Preconditions != nil { in, out := &in.Preconditions, &out.Preconditions @@ -763,31 +767,50 @@ func DeepCopy_v1_DeleteOptions(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_v1_Preconditions(*in, *out, c); err != nil { return err } - } else { - out.Preconditions = nil } if in.OrphanDependents != nil { in, out := &in.OrphanDependents, &out.OrphanDependents *out = new(bool) **out = **in - } else { - out.OrphanDependents = nil + } + if in.PropagationPolicy != nil { + in, out := &in.PropagationPolicy, &out.PropagationPolicy + *out = new(DeletionPropagation) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_DownwardAPIProjection is an autogenerated deepcopy function. +func DeepCopy_v1_DownwardAPIProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DownwardAPIProjection) + out := out.(*DownwardAPIProjection) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]DownwardAPIVolumeFile, len(*in)) + for i := range *in { + if err := DeepCopy_v1_DownwardAPIVolumeFile(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } } return nil } } +// DeepCopy_v1_DownwardAPIVolumeFile is an autogenerated deepcopy function. func DeepCopy_v1_DownwardAPIVolumeFile(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DownwardAPIVolumeFile) out := out.(*DownwardAPIVolumeFile) - out.Path = in.Path + *out = *in if in.FieldRef != nil { in, out := &in.FieldRef, &out.FieldRef *out = new(ObjectFieldSelector) **out = **in - } else { - out.FieldRef = nil } if in.ResourceFieldRef != nil { in, out := &in.ResourceFieldRef, &out.ResourceFieldRef @@ -795,24 +818,22 @@ func DeepCopy_v1_DownwardAPIVolumeFile(in interface{}, out interface{}, c *conve if err := DeepCopy_v1_ResourceFieldSelector(*in, *out, c); err != nil { return err } - } else { - out.ResourceFieldRef = nil } if in.Mode != nil { in, out := &in.Mode, &out.Mode *out = new(int32) **out = **in - } else { - out.Mode = nil } return nil } } +// DeepCopy_v1_DownwardAPIVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_DownwardAPIVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DownwardAPIVolumeSource) out := out.(*DownwardAPIVolumeSource) + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]DownwardAPIVolumeFile, len(*in)) @@ -821,68 +842,63 @@ func DeepCopy_v1_DownwardAPIVolumeSource(in interface{}, out interface{}, c *con return err } } - } else { - out.Items = nil } if in.DefaultMode != nil { in, out := &in.DefaultMode, &out.DefaultMode *out = new(int32) **out = **in - } else { - out.DefaultMode = nil } return nil } } +// DeepCopy_v1_EmptyDirVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_EmptyDirVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EmptyDirVolumeSource) out := out.(*EmptyDirVolumeSource) - out.Medium = in.Medium + *out = *in + out.SizeLimit = in.SizeLimit.DeepCopy() return nil } } +// DeepCopy_v1_EndpointAddress is an autogenerated deepcopy function. func DeepCopy_v1_EndpointAddress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointAddress) out := out.(*EndpointAddress) - out.IP = in.IP - out.Hostname = in.Hostname + *out = *in if in.NodeName != nil { in, out := &in.NodeName, &out.NodeName *out = new(string) **out = **in - } else { - out.NodeName = nil } if in.TargetRef != nil { in, out := &in.TargetRef, &out.TargetRef *out = new(ObjectReference) **out = **in - } else { - out.TargetRef = nil } return nil } } +// DeepCopy_v1_EndpointPort is an autogenerated deepcopy function. func DeepCopy_v1_EndpointPort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointPort) out := out.(*EndpointPort) - out.Name = in.Name - out.Port = in.Port - out.Protocol = in.Protocol + *out = *in return nil } } +// DeepCopy_v1_EndpointSubset is an autogenerated deepcopy function. func DeepCopy_v1_EndpointSubset(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointSubset) out := out.(*EndpointSubset) + *out = *in if in.Addresses != nil { in, out := &in.Addresses, &out.Addresses *out = make([]EndpointAddress, len(*in)) @@ -891,8 +907,6 @@ func DeepCopy_v1_EndpointSubset(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Addresses = nil } if in.NotReadyAddresses != nil { in, out := &in.NotReadyAddresses, &out.NotReadyAddresses @@ -902,29 +916,26 @@ func DeepCopy_v1_EndpointSubset(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.NotReadyAddresses = nil } if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]EndpointPort, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ports = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_Endpoints is an autogenerated deepcopy function. func DeepCopy_v1_Endpoints(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Endpoints) out := out.(*Endpoints) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if in.Subsets != nil { in, out := &in.Subsets, &out.Subsets @@ -934,19 +945,17 @@ func DeepCopy_v1_Endpoints(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.Subsets = nil } return nil } } +// DeepCopy_v1_EndpointsList is an autogenerated deepcopy function. func DeepCopy_v1_EndpointsList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointsList) out := out.(*EndpointsList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Endpoints, len(*in)) @@ -955,42 +964,62 @@ func DeepCopy_v1_EndpointsList(in interface{}, out interface{}, c *conversion.Cl return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_EnvFromSource is an autogenerated deepcopy function. +func DeepCopy_v1_EnvFromSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*EnvFromSource) + out := out.(*EnvFromSource) + *out = *in + if in.ConfigMapRef != nil { + in, out := &in.ConfigMapRef, &out.ConfigMapRef + *out = new(ConfigMapEnvSource) + if err := DeepCopy_v1_ConfigMapEnvSource(*in, *out, c); err != nil { + return err + } + } + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(SecretEnvSource) + if err := DeepCopy_v1_SecretEnvSource(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v1_EnvVar is an autogenerated deepcopy function. func DeepCopy_v1_EnvVar(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EnvVar) out := out.(*EnvVar) - out.Name = in.Name - out.Value = in.Value + *out = *in if in.ValueFrom != nil { in, out := &in.ValueFrom, &out.ValueFrom *out = new(EnvVarSource) if err := DeepCopy_v1_EnvVarSource(*in, *out, c); err != nil { return err } - } else { - out.ValueFrom = nil } return nil } } +// DeepCopy_v1_EnvVarSource is an autogenerated deepcopy function. func DeepCopy_v1_EnvVarSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EnvVarSource) out := out.(*EnvVarSource) + *out = *in if in.FieldRef != nil { in, out := &in.FieldRef, &out.FieldRef *out = new(ObjectFieldSelector) **out = **in - } else { - out.FieldRef = nil } if in.ResourceFieldRef != nil { in, out := &in.ResourceFieldRef, &out.ResourceFieldRef @@ -998,53 +1027,48 @@ func DeepCopy_v1_EnvVarSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_ResourceFieldSelector(*in, *out, c); err != nil { return err } - } else { - out.ResourceFieldRef = nil } if in.ConfigMapKeyRef != nil { in, out := &in.ConfigMapKeyRef, &out.ConfigMapKeyRef *out = new(ConfigMapKeySelector) - **out = **in - } else { - out.ConfigMapKeyRef = nil + if err := DeepCopy_v1_ConfigMapKeySelector(*in, *out, c); err != nil { + return err + } } if in.SecretKeyRef != nil { in, out := &in.SecretKeyRef, &out.SecretKeyRef *out = new(SecretKeySelector) - **out = **in - } else { - out.SecretKeyRef = nil + if err := DeepCopy_v1_SecretKeySelector(*in, *out, c); err != nil { + return err + } } return nil } } +// DeepCopy_v1_Event is an autogenerated deepcopy function. func DeepCopy_v1_Event(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Event) out := out.(*Event) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } - out.InvolvedObject = in.InvolvedObject - out.Reason = in.Reason - out.Message = in.Message - out.Source = in.Source out.FirstTimestamp = in.FirstTimestamp.DeepCopy() out.LastTimestamp = in.LastTimestamp.DeepCopy() - out.Count = in.Count - out.Type = in.Type return nil } } +// DeepCopy_v1_EventList is an autogenerated deepcopy function. func DeepCopy_v1_EventList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EventList) out := out.(*EventList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Event, len(*in)) @@ -1053,187 +1077,155 @@ func DeepCopy_v1_EventList(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_EventSource is an autogenerated deepcopy function. func DeepCopy_v1_EventSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EventSource) out := out.(*EventSource) - out.Component = in.Component - out.Host = in.Host + *out = *in return nil } } +// DeepCopy_v1_ExecAction is an autogenerated deepcopy function. func DeepCopy_v1_ExecAction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ExecAction) out := out.(*ExecAction) + *out = *in if in.Command != nil { in, out := &in.Command, &out.Command *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Command = nil } return nil } } -func DeepCopy_v1_ExportOptions(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ExportOptions) - out := out.(*ExportOptions) - out.TypeMeta = in.TypeMeta - out.Export = in.Export - out.Exact = in.Exact - return nil - } -} - +// DeepCopy_v1_FCVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_FCVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FCVolumeSource) out := out.(*FCVolumeSource) + *out = *in if in.TargetWWNs != nil { in, out := &in.TargetWWNs, &out.TargetWWNs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.TargetWWNs = nil } if in.Lun != nil { in, out := &in.Lun, &out.Lun *out = new(int32) **out = **in - } else { - out.Lun = nil } - out.FSType = in.FSType - out.ReadOnly = in.ReadOnly return nil } } +// DeepCopy_v1_FlexVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_FlexVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FlexVolumeSource) out := out.(*FlexVolumeSource) - out.Driver = in.Driver - out.FSType = in.FSType + *out = *in if in.SecretRef != nil { in, out := &in.SecretRef, &out.SecretRef *out = new(LocalObjectReference) **out = **in - } else { - out.SecretRef = nil } - out.ReadOnly = in.ReadOnly if in.Options != nil { in, out := &in.Options, &out.Options *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Options = nil } return nil } } +// DeepCopy_v1_FlockerVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_FlockerVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FlockerVolumeSource) out := out.(*FlockerVolumeSource) - out.DatasetName = in.DatasetName - out.DatasetUUID = in.DatasetUUID + *out = *in return nil } } +// DeepCopy_v1_GCEPersistentDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_GCEPersistentDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*GCEPersistentDiskVolumeSource) out := out.(*GCEPersistentDiskVolumeSource) - out.PDName = in.PDName - out.FSType = in.FSType - out.Partition = in.Partition - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_GitRepoVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_GitRepoVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*GitRepoVolumeSource) out := out.(*GitRepoVolumeSource) - out.Repository = in.Repository - out.Revision = in.Revision - out.Directory = in.Directory + *out = *in return nil } } +// DeepCopy_v1_GlusterfsVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_GlusterfsVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*GlusterfsVolumeSource) out := out.(*GlusterfsVolumeSource) - out.EndpointsName = in.EndpointsName - out.Path = in.Path - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_HTTPGetAction is an autogenerated deepcopy function. func DeepCopy_v1_HTTPGetAction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPGetAction) out := out.(*HTTPGetAction) - out.Path = in.Path - out.Port = in.Port - out.Host = in.Host - out.Scheme = in.Scheme + *out = *in if in.HTTPHeaders != nil { in, out := &in.HTTPHeaders, &out.HTTPHeaders *out = make([]HTTPHeader, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.HTTPHeaders = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_HTTPHeader is an autogenerated deepcopy function. func DeepCopy_v1_HTTPHeader(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPHeader) out := out.(*HTTPHeader) - out.Name = in.Name - out.Value = in.Value + *out = *in return nil } } +// DeepCopy_v1_Handler is an autogenerated deepcopy function. func DeepCopy_v1_Handler(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Handler) out := out.(*Handler) + *out = *in if in.Exec != nil { in, out := &in.Exec, &out.Exec *out = new(ExecAction) if err := DeepCopy_v1_ExecAction(*in, *out, c); err != nil { return err } - } else { - out.Exec = nil } if in.HTTPGet != nil { in, out := &in.HTTPGet, &out.HTTPGet @@ -1241,72 +1233,88 @@ func DeepCopy_v1_Handler(in interface{}, out interface{}, c *conversion.Cloner) if err := DeepCopy_v1_HTTPGetAction(*in, *out, c); err != nil { return err } - } else { - out.HTTPGet = nil } if in.TCPSocket != nil { in, out := &in.TCPSocket, &out.TCPSocket *out = new(TCPSocketAction) **out = **in - } else { - out.TCPSocket = nil } return nil } } +// DeepCopy_v1_HostAlias is an autogenerated deepcopy function. +func DeepCopy_v1_HostAlias(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HostAlias) + out := out.(*HostAlias) + *out = *in + if in.Hostnames != nil { + in, out := &in.Hostnames, &out.Hostnames + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_HostPathVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_HostPathVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HostPathVolumeSource) out := out.(*HostPathVolumeSource) - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_v1_ISCSIVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_ISCSIVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ISCSIVolumeSource) out := out.(*ISCSIVolumeSource) - out.TargetPortal = in.TargetPortal - out.IQN = in.IQN - out.Lun = in.Lun - out.ISCSIInterface = in.ISCSIInterface - out.FSType = in.FSType - out.ReadOnly = in.ReadOnly + *out = *in + if in.Portals != nil { + in, out := &in.Portals, &out.Portals + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(LocalObjectReference) + **out = **in + } return nil } } +// DeepCopy_v1_KeyToPath is an autogenerated deepcopy function. func DeepCopy_v1_KeyToPath(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*KeyToPath) out := out.(*KeyToPath) - out.Key = in.Key - out.Path = in.Path + *out = *in if in.Mode != nil { in, out := &in.Mode, &out.Mode *out = new(int32) **out = **in - } else { - out.Mode = nil } return nil } } +// DeepCopy_v1_Lifecycle is an autogenerated deepcopy function. func DeepCopy_v1_Lifecycle(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Lifecycle) out := out.(*Lifecycle) + *out = *in if in.PostStart != nil { in, out := &in.PostStart, &out.PostStart *out = new(Handler) if err := DeepCopy_v1_Handler(*in, *out, c); err != nil { return err } - } else { - out.PostStart = nil } if in.PreStop != nil { in, out := &in.PreStop, &out.PreStop @@ -1314,20 +1322,21 @@ func DeepCopy_v1_Lifecycle(in interface{}, out interface{}, c *conversion.Cloner if err := DeepCopy_v1_Handler(*in, *out, c); err != nil { return err } - } else { - out.PreStop = nil } return nil } } +// DeepCopy_v1_LimitRange is an autogenerated deepcopy function. func DeepCopy_v1_LimitRange(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRange) out := out.(*LimitRange) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_LimitRangeSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -1336,19 +1345,18 @@ func DeepCopy_v1_LimitRange(in interface{}, out interface{}, c *conversion.Clone } } +// DeepCopy_v1_LimitRangeItem is an autogenerated deepcopy function. func DeepCopy_v1_LimitRangeItem(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRangeItem) out := out.(*LimitRangeItem) - out.Type = in.Type + *out = *in if in.Max != nil { in, out := &in.Max, &out.Max *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Max = nil } if in.Min != nil { in, out := &in.Min, &out.Min @@ -1356,8 +1364,6 @@ func DeepCopy_v1_LimitRangeItem(in interface{}, out interface{}, c *conversion.C for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Min = nil } if in.Default != nil { in, out := &in.Default, &out.Default @@ -1365,8 +1371,6 @@ func DeepCopy_v1_LimitRangeItem(in interface{}, out interface{}, c *conversion.C for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Default = nil } if in.DefaultRequest != nil { in, out := &in.DefaultRequest, &out.DefaultRequest @@ -1374,8 +1378,6 @@ func DeepCopy_v1_LimitRangeItem(in interface{}, out interface{}, c *conversion.C for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.DefaultRequest = nil } if in.MaxLimitRequestRatio != nil { in, out := &in.MaxLimitRequestRatio, &out.MaxLimitRequestRatio @@ -1383,19 +1385,17 @@ func DeepCopy_v1_LimitRangeItem(in interface{}, out interface{}, c *conversion.C for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.MaxLimitRequestRatio = nil } return nil } } +// DeepCopy_v1_LimitRangeList is an autogenerated deepcopy function. func DeepCopy_v1_LimitRangeList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRangeList) out := out.(*LimitRangeList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]LimitRange, len(*in)) @@ -1404,17 +1404,17 @@ func DeepCopy_v1_LimitRangeList(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_LimitRangeSpec is an autogenerated deepcopy function. func DeepCopy_v1_LimitRangeSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRangeSpec) out := out.(*LimitRangeSpec) + *out = *in if in.Limits != nil { in, out := &in.Limits, &out.Limits *out = make([]LimitRangeItem, len(*in)) @@ -1423,123 +1423,126 @@ func DeepCopy_v1_LimitRangeSpec(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Limits = nil } return nil } } +// DeepCopy_v1_List is an autogenerated deepcopy function. func DeepCopy_v1_List(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*List) out := out.(*List) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]runtime.RawExtension, len(*in)) for i := range *in { - if err := runtime.DeepCopy_runtime_RawExtension(&(*in)[i], &(*out)[i], c); err != nil { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { return err + } else { + (*out)[i] = *newVal.(*runtime.RawExtension) } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ListOptions is an autogenerated deepcopy function. func DeepCopy_v1_ListOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ListOptions) out := out.(*ListOptions) - out.TypeMeta = in.TypeMeta - out.LabelSelector = in.LabelSelector - out.FieldSelector = in.FieldSelector - out.Watch = in.Watch - out.ResourceVersion = in.ResourceVersion + *out = *in if in.TimeoutSeconds != nil { in, out := &in.TimeoutSeconds, &out.TimeoutSeconds *out = new(int64) **out = **in - } else { - out.TimeoutSeconds = nil } return nil } } +// DeepCopy_v1_LoadBalancerIngress is an autogenerated deepcopy function. func DeepCopy_v1_LoadBalancerIngress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LoadBalancerIngress) out := out.(*LoadBalancerIngress) - out.IP = in.IP - out.Hostname = in.Hostname + *out = *in return nil } } +// DeepCopy_v1_LoadBalancerStatus is an autogenerated deepcopy function. func DeepCopy_v1_LoadBalancerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LoadBalancerStatus) out := out.(*LoadBalancerStatus) + *out = *in if in.Ingress != nil { in, out := &in.Ingress, &out.Ingress *out = make([]LoadBalancerIngress, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ingress = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_LocalObjectReference is an autogenerated deepcopy function. func DeepCopy_v1_LocalObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LocalObjectReference) out := out.(*LocalObjectReference) - out.Name = in.Name + *out = *in + return nil + } +} + +// DeepCopy_v1_LocalVolumeSource is an autogenerated deepcopy function. +func DeepCopy_v1_LocalVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*LocalVolumeSource) + out := out.(*LocalVolumeSource) + *out = *in return nil } } +// DeepCopy_v1_NFSVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_NFSVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NFSVolumeSource) out := out.(*NFSVolumeSource) - out.Server = in.Server - out.Path = in.Path - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_Namespace is an autogenerated deepcopy function. func DeepCopy_v1_Namespace(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Namespace) out := out.(*Namespace) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_NamespaceSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_v1_NamespaceList is an autogenerated deepcopy function. func DeepCopy_v1_NamespaceList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NamespaceList) out := out.(*NamespaceList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Namespace, len(*in)) @@ -1548,48 +1551,50 @@ func DeepCopy_v1_NamespaceList(in interface{}, out interface{}, c *conversion.Cl return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_NamespaceSpec is an autogenerated deepcopy function. func DeepCopy_v1_NamespaceSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NamespaceSpec) out := out.(*NamespaceSpec) + *out = *in if in.Finalizers != nil { in, out := &in.Finalizers, &out.Finalizers *out = make([]FinalizerName, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Finalizers = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_NamespaceStatus is an autogenerated deepcopy function. func DeepCopy_v1_NamespaceStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NamespaceStatus) out := out.(*NamespaceStatus) - out.Phase = in.Phase + *out = *in return nil } } +// DeepCopy_v1_Node is an autogenerated deepcopy function. func DeepCopy_v1_Node(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Node) out := out.(*Node) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_NodeSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Spec = in.Spec if err := DeepCopy_v1_NodeStatus(&in.Status, &out.Status, c); err != nil { return err } @@ -1597,28 +1602,28 @@ func DeepCopy_v1_Node(in interface{}, out interface{}, c *conversion.Cloner) err } } +// DeepCopy_v1_NodeAddress is an autogenerated deepcopy function. func DeepCopy_v1_NodeAddress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeAddress) out := out.(*NodeAddress) - out.Type = in.Type - out.Address = in.Address + *out = *in return nil } } +// DeepCopy_v1_NodeAffinity is an autogenerated deepcopy function. func DeepCopy_v1_NodeAffinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeAffinity) out := out.(*NodeAffinity) + *out = *in if in.RequiredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution *out = new(NodeSelector) if err := DeepCopy_v1_NodeSelector(*in, *out, c); err != nil { return err } - } else { - out.RequiredDuringSchedulingIgnoredDuringExecution = nil } if in.PreferredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution @@ -1628,42 +1633,39 @@ func DeepCopy_v1_NodeAffinity(in interface{}, out interface{}, c *conversion.Clo return err } } - } else { - out.PreferredDuringSchedulingIgnoredDuringExecution = nil } return nil } } +// DeepCopy_v1_NodeCondition is an autogenerated deepcopy function. func DeepCopy_v1_NodeCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeCondition) out := out.(*NodeCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastHeartbeatTime = in.LastHeartbeatTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1_NodeDaemonEndpoints is an autogenerated deepcopy function. func DeepCopy_v1_NodeDaemonEndpoints(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeDaemonEndpoints) out := out.(*NodeDaemonEndpoints) - out.KubeletEndpoint = in.KubeletEndpoint + *out = *in return nil } } +// DeepCopy_v1_NodeList is an autogenerated deepcopy function. func DeepCopy_v1_NodeList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeList) out := out.(*NodeList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Node, len(*in)) @@ -1672,27 +1674,44 @@ func DeepCopy_v1_NodeList(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_NodeProxyOptions is an autogenerated deepcopy function. func DeepCopy_v1_NodeProxyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeProxyOptions) out := out.(*NodeProxyOptions) - out.TypeMeta = in.TypeMeta - out.Path = in.Path + *out = *in + return nil + } +} + +// DeepCopy_v1_NodeResources is an autogenerated deepcopy function. +func DeepCopy_v1_NodeResources(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NodeResources) + out := out.(*NodeResources) + *out = *in + if in.Capacity != nil { + in, out := &in.Capacity, &out.Capacity + *out = make(ResourceList) + for key, val := range *in { + (*out)[key] = val.DeepCopy() + } + } return nil } } +// DeepCopy_v1_NodeSelector is an autogenerated deepcopy function. func DeepCopy_v1_NodeSelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSelector) out := out.(*NodeSelector) + *out = *in if in.NodeSelectorTerms != nil { in, out := &in.NodeSelectorTerms, &out.NodeSelectorTerms *out = make([]NodeSelectorTerm, len(*in)) @@ -1701,34 +1720,32 @@ func DeepCopy_v1_NodeSelector(in interface{}, out interface{}, c *conversion.Clo return err } } - } else { - out.NodeSelectorTerms = nil } return nil } } +// DeepCopy_v1_NodeSelectorRequirement is an autogenerated deepcopy function. func DeepCopy_v1_NodeSelectorRequirement(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSelectorRequirement) out := out.(*NodeSelectorRequirement) - out.Key = in.Key - out.Operator = in.Operator + *out = *in if in.Values != nil { in, out := &in.Values, &out.Values *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Values = nil } return nil } } +// DeepCopy_v1_NodeSelectorTerm is an autogenerated deepcopy function. func DeepCopy_v1_NodeSelectorTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSelectorTerm) out := out.(*NodeSelectorTerm) + *out = *in if in.MatchExpressions != nil { in, out := &in.MatchExpressions, &out.MatchExpressions *out = make([]NodeSelectorRequirement, len(*in)) @@ -1737,37 +1754,42 @@ func DeepCopy_v1_NodeSelectorTerm(in interface{}, out interface{}, c *conversion return err } } - } else { - out.MatchExpressions = nil } return nil } } +// DeepCopy_v1_NodeSpec is an autogenerated deepcopy function. func DeepCopy_v1_NodeSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSpec) out := out.(*NodeSpec) - out.PodCIDR = in.PodCIDR - out.ExternalID = in.ExternalID - out.ProviderID = in.ProviderID - out.Unschedulable = in.Unschedulable + *out = *in + if in.Taints != nil { + in, out := &in.Taints, &out.Taints + *out = make([]Taint, len(*in)) + for i := range *in { + if err := DeepCopy_v1_Taint(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } return nil } } +// DeepCopy_v1_NodeStatus is an autogenerated deepcopy function. func DeepCopy_v1_NodeStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeStatus) out := out.(*NodeStatus) + *out = *in if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } if in.Allocatable != nil { in, out := &in.Allocatable, &out.Allocatable @@ -1775,10 +1797,7 @@ func DeepCopy_v1_NodeStatus(in interface{}, out interface{}, c *conversion.Clone for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Allocatable = nil } - out.Phase = in.Phase if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]NodeCondition, len(*in)) @@ -1787,20 +1806,12 @@ func DeepCopy_v1_NodeStatus(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Conditions = nil } if in.Addresses != nil { in, out := &in.Addresses, &out.Addresses *out = make([]NodeAddress, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Addresses = nil + copy(*out, *in) } - out.DaemonEndpoints = in.DaemonEndpoints - out.NodeInfo = in.NodeInfo if in.Images != nil { in, out := &in.Images, &out.Images *out = make([]ContainerImage, len(*in)) @@ -1809,84 +1820,57 @@ func DeepCopy_v1_NodeStatus(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Images = nil } if in.VolumesInUse != nil { in, out := &in.VolumesInUse, &out.VolumesInUse *out = make([]UniqueVolumeName, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.VolumesInUse = nil + copy(*out, *in) } if in.VolumesAttached != nil { in, out := &in.VolumesAttached, &out.VolumesAttached *out = make([]AttachedVolume, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.VolumesAttached = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_NodeSystemInfo is an autogenerated deepcopy function. func DeepCopy_v1_NodeSystemInfo(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSystemInfo) out := out.(*NodeSystemInfo) - out.MachineID = in.MachineID - out.SystemUUID = in.SystemUUID - out.BootID = in.BootID - out.KernelVersion = in.KernelVersion - out.OSImage = in.OSImage - out.ContainerRuntimeVersion = in.ContainerRuntimeVersion - out.KubeletVersion = in.KubeletVersion - out.KubeProxyVersion = in.KubeProxyVersion - out.OperatingSystem = in.OperatingSystem - out.Architecture = in.Architecture + *out = *in return nil } } +// DeepCopy_v1_ObjectFieldSelector is an autogenerated deepcopy function. func DeepCopy_v1_ObjectFieldSelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ObjectFieldSelector) out := out.(*ObjectFieldSelector) - out.APIVersion = in.APIVersion - out.FieldPath = in.FieldPath + *out = *in return nil } } +// DeepCopy_v1_ObjectMeta is an autogenerated deepcopy function. func DeepCopy_v1_ObjectMeta(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ObjectMeta) out := out.(*ObjectMeta) - out.Name = in.Name - out.GenerateName = in.GenerateName - out.Namespace = in.Namespace - out.SelfLink = in.SelfLink - out.UID = in.UID - out.ResourceVersion = in.ResourceVersion - out.Generation = in.Generation + *out = *in out.CreationTimestamp = in.CreationTimestamp.DeepCopy() if in.DeletionTimestamp != nil { in, out := &in.DeletionTimestamp, &out.DeletionTimestamp - *out = new(unversioned.Time) + *out = new(meta_v1.Time) **out = (*in).DeepCopy() - } else { - out.DeletionTimestamp = nil } if in.DeletionGracePeriodSeconds != nil { in, out := &in.DeletionGracePeriodSeconds, &out.DeletionGracePeriodSeconds *out = new(int64) **out = **in - } else { - out.DeletionGracePeriodSeconds = nil } if in.Labels != nil { in, out := &in.Labels, &out.Labels @@ -1894,8 +1878,6 @@ func DeepCopy_v1_ObjectMeta(in interface{}, out interface{}, c *conversion.Clone for key, val := range *in { (*out)[key] = val } - } else { - out.Labels = nil } if in.Annotations != nil { in, out := &in.Annotations, &out.Annotations @@ -1903,89 +1885,73 @@ func DeepCopy_v1_ObjectMeta(in interface{}, out interface{}, c *conversion.Clone for key, val := range *in { (*out)[key] = val } - } else { - out.Annotations = nil } if in.OwnerReferences != nil { in, out := &in.OwnerReferences, &out.OwnerReferences - *out = make([]OwnerReference, len(*in)) + *out = make([]meta_v1.OwnerReference, len(*in)) for i := range *in { - if err := DeepCopy_v1_OwnerReference(&(*in)[i], &(*out)[i], c); err != nil { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { return err + } else { + (*out)[i] = *newVal.(*meta_v1.OwnerReference) } } - } else { - out.OwnerReferences = nil + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.Initializers) + } } if in.Finalizers != nil { in, out := &in.Finalizers, &out.Finalizers *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Finalizers = nil } - out.ClusterName = in.ClusterName return nil } } +// DeepCopy_v1_ObjectReference is an autogenerated deepcopy function. func DeepCopy_v1_ObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ObjectReference) out := out.(*ObjectReference) - out.Kind = in.Kind - out.Namespace = in.Namespace - out.Name = in.Name - out.UID = in.UID - out.APIVersion = in.APIVersion - out.ResourceVersion = in.ResourceVersion - out.FieldPath = in.FieldPath - return nil - } -} - -func DeepCopy_v1_OwnerReference(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*OwnerReference) - out := out.(*OwnerReference) - out.APIVersion = in.APIVersion - out.Kind = in.Kind - out.Name = in.Name - out.UID = in.UID - if in.Controller != nil { - in, out := &in.Controller, &out.Controller - *out = new(bool) - **out = **in - } else { - out.Controller = nil - } + *out = *in return nil } } +// DeepCopy_v1_PersistentVolume is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolume(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolume) out := out.(*PersistentVolume) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_PersistentVolumeSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_v1_PersistentVolumeClaim is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeClaim(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaim) out := out.(*PersistentVolumeClaim) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_PersistentVolumeClaimSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -1997,12 +1963,12 @@ func DeepCopy_v1_PersistentVolumeClaim(in interface{}, out interface{}, c *conve } } +// DeepCopy_v1_PersistentVolumeClaimList is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeClaimList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimList) out := out.(*PersistentVolumeClaimList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PersistentVolumeClaim, len(*in)) @@ -2011,56 +1977,52 @@ func DeepCopy_v1_PersistentVolumeClaimList(in interface{}, out interface{}, c *c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_PersistentVolumeClaimSpec is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeClaimSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimSpec) out := out.(*PersistentVolumeClaimSpec) + *out = *in if in.AccessModes != nil { in, out := &in.AccessModes, &out.AccessModes *out = make([]PersistentVolumeAccessMode, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AccessModes = nil + copy(*out, *in) } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*meta_v1.LabelSelector) } - } else { - out.Selector = nil } if err := DeepCopy_v1_ResourceRequirements(&in.Resources, &out.Resources, c); err != nil { return err } - out.VolumeName = in.VolumeName + if in.StorageClassName != nil { + in, out := &in.StorageClassName, &out.StorageClassName + *out = new(string) + **out = **in + } return nil } } +// DeepCopy_v1_PersistentVolumeClaimStatus is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeClaimStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimStatus) out := out.(*PersistentVolumeClaimStatus) - out.Phase = in.Phase + *out = *in if in.AccessModes != nil { in, out := &in.AccessModes, &out.AccessModes *out = make([]PersistentVolumeAccessMode, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AccessModes = nil + copy(*out, *in) } if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity @@ -2068,29 +2030,27 @@ func DeepCopy_v1_PersistentVolumeClaimStatus(in interface{}, out interface{}, c for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } return nil } } +// DeepCopy_v1_PersistentVolumeClaimVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeClaimVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimVolumeSource) out := out.(*PersistentVolumeClaimVolumeSource) - out.ClaimName = in.ClaimName - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_v1_PersistentVolumeList is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeList) out := out.(*PersistentVolumeList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PersistentVolume, len(*in)) @@ -2099,51 +2059,41 @@ func DeepCopy_v1_PersistentVolumeList(in interface{}, out interface{}, c *conver return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_PersistentVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeSource) out := out.(*PersistentVolumeSource) + *out = *in if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk *out = new(GCEPersistentDiskVolumeSource) **out = **in - } else { - out.GCEPersistentDisk = nil } if in.AWSElasticBlockStore != nil { in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore *out = new(AWSElasticBlockStoreVolumeSource) **out = **in - } else { - out.AWSElasticBlockStore = nil } if in.HostPath != nil { in, out := &in.HostPath, &out.HostPath *out = new(HostPathVolumeSource) **out = **in - } else { - out.HostPath = nil } if in.Glusterfs != nil { in, out := &in.Glusterfs, &out.Glusterfs *out = new(GlusterfsVolumeSource) **out = **in - } else { - out.Glusterfs = nil } if in.NFS != nil { in, out := &in.NFS, &out.NFS *out = new(NFSVolumeSource) **out = **in - } else { - out.NFS = nil } if in.RBD != nil { in, out := &in.RBD, &out.RBD @@ -2151,22 +2101,18 @@ func DeepCopy_v1_PersistentVolumeSource(in interface{}, out interface{}, c *conv if err := DeepCopy_v1_RBDVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.RBD = nil } if in.ISCSI != nil { in, out := &in.ISCSI, &out.ISCSI *out = new(ISCSIVolumeSource) - **out = **in - } else { - out.ISCSI = nil + if err := DeepCopy_v1_ISCSIVolumeSource(*in, *out, c); err != nil { + return err + } } if in.Cinder != nil { in, out := &in.Cinder, &out.Cinder *out = new(CinderVolumeSource) **out = **in - } else { - out.Cinder = nil } if in.CephFS != nil { in, out := &in.CephFS, &out.CephFS @@ -2174,8 +2120,6 @@ func DeepCopy_v1_PersistentVolumeSource(in interface{}, out interface{}, c *conv if err := DeepCopy_v1_CephFSVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.CephFS = nil } if in.FC != nil { in, out := &in.FC, &out.FC @@ -2183,15 +2127,11 @@ func DeepCopy_v1_PersistentVolumeSource(in interface{}, out interface{}, c *conv if err := DeepCopy_v1_FCVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FC = nil } if in.Flocker != nil { in, out := &in.Flocker, &out.Flocker *out = new(FlockerVolumeSource) **out = **in - } else { - out.Flocker = nil } if in.FlexVolume != nil { in, out := &in.FlexVolume, &out.FlexVolume @@ -2199,29 +2139,21 @@ func DeepCopy_v1_PersistentVolumeSource(in interface{}, out interface{}, c *conv if err := DeepCopy_v1_FlexVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FlexVolume = nil } if in.AzureFile != nil { in, out := &in.AzureFile, &out.AzureFile *out = new(AzureFileVolumeSource) **out = **in - } else { - out.AzureFile = nil } if in.VsphereVolume != nil { in, out := &in.VsphereVolume, &out.VsphereVolume *out = new(VsphereVirtualDiskVolumeSource) **out = **in - } else { - out.VsphereVolume = nil } if in.Quobyte != nil { in, out := &in.Quobyte, &out.Quobyte *out = new(QuobyteVolumeSource) **out = **in - } else { - out.Quobyte = nil } if in.AzureDisk != nil { in, out := &in.AzureDisk, &out.AzureDisk @@ -2229,32 +2161,52 @@ func DeepCopy_v1_PersistentVolumeSource(in interface{}, out interface{}, c *conv if err := DeepCopy_v1_AzureDiskVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.AzureDisk = nil } if in.PhotonPersistentDisk != nil { in, out := &in.PhotonPersistentDisk, &out.PhotonPersistentDisk *out = new(PhotonPersistentDiskVolumeSource) **out = **in - } else { - out.PhotonPersistentDisk = nil + } + if in.PortworxVolume != nil { + in, out := &in.PortworxVolume, &out.PortworxVolume + *out = new(PortworxVolumeSource) + **out = **in + } + if in.ScaleIO != nil { + in, out := &in.ScaleIO, &out.ScaleIO + *out = new(ScaleIOVolumeSource) + if err := DeepCopy_v1_ScaleIOVolumeSource(*in, *out, c); err != nil { + return err + } + } + if in.Local != nil { + in, out := &in.Local, &out.Local + *out = new(LocalVolumeSource) + **out = **in + } + if in.StorageOS != nil { + in, out := &in.StorageOS, &out.StorageOS + *out = new(StorageOSPersistentVolumeSource) + if err := DeepCopy_v1_StorageOSPersistentVolumeSource(*in, *out, c); err != nil { + return err + } } return nil } } +// DeepCopy_v1_PersistentVolumeSpec is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeSpec) out := out.(*PersistentVolumeSpec) + *out = *in if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } if err := DeepCopy_v1_PersistentVolumeSource(&in.PersistentVolumeSource, &out.PersistentVolumeSource, c); err != nil { return err @@ -2262,52 +2214,47 @@ func DeepCopy_v1_PersistentVolumeSpec(in interface{}, out interface{}, c *conver if in.AccessModes != nil { in, out := &in.AccessModes, &out.AccessModes *out = make([]PersistentVolumeAccessMode, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AccessModes = nil + copy(*out, *in) } if in.ClaimRef != nil { in, out := &in.ClaimRef, &out.ClaimRef *out = new(ObjectReference) **out = **in - } else { - out.ClaimRef = nil } - out.PersistentVolumeReclaimPolicy = in.PersistentVolumeReclaimPolicy return nil } } +// DeepCopy_v1_PersistentVolumeStatus is an autogenerated deepcopy function. func DeepCopy_v1_PersistentVolumeStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeStatus) out := out.(*PersistentVolumeStatus) - out.Phase = in.Phase - out.Message = in.Message - out.Reason = in.Reason + *out = *in return nil } } +// DeepCopy_v1_PhotonPersistentDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_PhotonPersistentDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PhotonPersistentDiskVolumeSource) out := out.(*PhotonPersistentDiskVolumeSource) - out.PdID = in.PdID - out.FSType = in.FSType + *out = *in return nil } } +// DeepCopy_v1_Pod is an autogenerated deepcopy function. func DeepCopy_v1_Pod(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Pod) out := out.(*Pod) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_PodSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2319,10 +2266,12 @@ func DeepCopy_v1_Pod(in interface{}, out interface{}, c *conversion.Cloner) erro } } +// DeepCopy_v1_PodAffinity is an autogenerated deepcopy function. func DeepCopy_v1_PodAffinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAffinity) out := out.(*PodAffinity) + *out = *in if in.RequiredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution *out = make([]PodAffinityTerm, len(*in)) @@ -2331,8 +2280,6 @@ func DeepCopy_v1_PodAffinity(in interface{}, out interface{}, c *conversion.Clon return err } } - } else { - out.RequiredDuringSchedulingIgnoredDuringExecution = nil } if in.PreferredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution @@ -2342,42 +2289,40 @@ func DeepCopy_v1_PodAffinity(in interface{}, out interface{}, c *conversion.Clon return err } } - } else { - out.PreferredDuringSchedulingIgnoredDuringExecution = nil } return nil } } +// DeepCopy_v1_PodAffinityTerm is an autogenerated deepcopy function. func DeepCopy_v1_PodAffinityTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAffinityTerm) out := out.(*PodAffinityTerm) + *out = *in if in.LabelSelector != nil { in, out := &in.LabelSelector, &out.LabelSelector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*meta_v1.LabelSelector) } - } else { - out.LabelSelector = nil } if in.Namespaces != nil { in, out := &in.Namespaces, &out.Namespaces *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Namespaces = nil } - out.TopologyKey = in.TopologyKey return nil } } +// DeepCopy_v1_PodAntiAffinity is an autogenerated deepcopy function. func DeepCopy_v1_PodAntiAffinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAntiAffinity) out := out.(*PodAntiAffinity) + *out = *in if in.RequiredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution *out = make([]PodAffinityTerm, len(*in)) @@ -2386,8 +2331,6 @@ func DeepCopy_v1_PodAntiAffinity(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.RequiredDuringSchedulingIgnoredDuringExecution = nil } if in.PreferredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution @@ -2397,68 +2340,54 @@ func DeepCopy_v1_PodAntiAffinity(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.PreferredDuringSchedulingIgnoredDuringExecution = nil } return nil } } +// DeepCopy_v1_PodAttachOptions is an autogenerated deepcopy function. func DeepCopy_v1_PodAttachOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAttachOptions) out := out.(*PodAttachOptions) - out.TypeMeta = in.TypeMeta - out.Stdin = in.Stdin - out.Stdout = in.Stdout - out.Stderr = in.Stderr - out.TTY = in.TTY - out.Container = in.Container + *out = *in return nil } } +// DeepCopy_v1_PodCondition is an autogenerated deepcopy function. func DeepCopy_v1_PodCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodCondition) out := out.(*PodCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastProbeTime = in.LastProbeTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1_PodExecOptions is an autogenerated deepcopy function. func DeepCopy_v1_PodExecOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodExecOptions) out := out.(*PodExecOptions) - out.TypeMeta = in.TypeMeta - out.Stdin = in.Stdin - out.Stdout = in.Stdout - out.Stderr = in.Stderr - out.TTY = in.TTY - out.Container = in.Container + *out = *in if in.Command != nil { in, out := &in.Command, &out.Command *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Command = nil } return nil } } +// DeepCopy_v1_PodList is an autogenerated deepcopy function. func DeepCopy_v1_PodList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodList) out := out.(*PodList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Pod, len(*in)) @@ -2467,128 +2396,125 @@ func DeepCopy_v1_PodList(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_PodLogOptions is an autogenerated deepcopy function. func DeepCopy_v1_PodLogOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodLogOptions) out := out.(*PodLogOptions) - out.TypeMeta = in.TypeMeta - out.Container = in.Container - out.Follow = in.Follow - out.Previous = in.Previous + *out = *in if in.SinceSeconds != nil { in, out := &in.SinceSeconds, &out.SinceSeconds *out = new(int64) **out = **in - } else { - out.SinceSeconds = nil } if in.SinceTime != nil { in, out := &in.SinceTime, &out.SinceTime - *out = new(unversioned.Time) + *out = new(meta_v1.Time) **out = (*in).DeepCopy() - } else { - out.SinceTime = nil } - out.Timestamps = in.Timestamps if in.TailLines != nil { in, out := &in.TailLines, &out.TailLines *out = new(int64) **out = **in - } else { - out.TailLines = nil } if in.LimitBytes != nil { in, out := &in.LimitBytes, &out.LimitBytes *out = new(int64) **out = **in - } else { - out.LimitBytes = nil } return nil } } +// DeepCopy_v1_PodPortForwardOptions is an autogenerated deepcopy function. +func DeepCopy_v1_PodPortForwardOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPortForwardOptions) + out := out.(*PodPortForwardOptions) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]int32, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1_PodProxyOptions is an autogenerated deepcopy function. func DeepCopy_v1_PodProxyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodProxyOptions) out := out.(*PodProxyOptions) - out.TypeMeta = in.TypeMeta - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_v1_PodSecurityContext is an autogenerated deepcopy function. func DeepCopy_v1_PodSecurityContext(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityContext) out := out.(*PodSecurityContext) + *out = *in if in.SELinuxOptions != nil { in, out := &in.SELinuxOptions, &out.SELinuxOptions *out = new(SELinuxOptions) **out = **in - } else { - out.SELinuxOptions = nil } if in.RunAsUser != nil { in, out := &in.RunAsUser, &out.RunAsUser *out = new(int64) **out = **in - } else { - out.RunAsUser = nil } if in.RunAsNonRoot != nil { in, out := &in.RunAsNonRoot, &out.RunAsNonRoot *out = new(bool) **out = **in - } else { - out.RunAsNonRoot = nil } if in.SupplementalGroups != nil { in, out := &in.SupplementalGroups, &out.SupplementalGroups *out = make([]int64, len(*in)) copy(*out, *in) - } else { - out.SupplementalGroups = nil } if in.FSGroup != nil { in, out := &in.FSGroup, &out.FSGroup *out = new(int64) **out = **in - } else { - out.FSGroup = nil } return nil } } +// DeepCopy_v1_PodSignature is an autogenerated deepcopy function. func DeepCopy_v1_PodSignature(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSignature) out := out.(*PodSignature) + *out = *in if in.PodController != nil { in, out := &in.PodController, &out.PodController - *out = new(OwnerReference) - if err := DeepCopy_v1_OwnerReference(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*meta_v1.OwnerReference) } - } else { - out.PodController = nil } return nil } } +// DeepCopy_v1_PodSpec is an autogenerated deepcopy function. func DeepCopy_v1_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSpec) out := out.(*PodSpec) + *out = *in if in.Volumes != nil { in, out := &in.Volumes, &out.Volumes *out = make([]Volume, len(*in)) @@ -2597,8 +2523,6 @@ func DeepCopy_v1_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Volumes = nil } if in.InitContainers != nil { in, out := &in.InitContainers, &out.InitContainers @@ -2608,8 +2532,6 @@ func DeepCopy_v1_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.InitContainers = nil } if in.Containers != nil { in, out := &in.Containers, &out.Containers @@ -2619,69 +2541,76 @@ func DeepCopy_v1_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Containers = nil } - out.RestartPolicy = in.RestartPolicy if in.TerminationGracePeriodSeconds != nil { in, out := &in.TerminationGracePeriodSeconds, &out.TerminationGracePeriodSeconds *out = new(int64) **out = **in - } else { - out.TerminationGracePeriodSeconds = nil } if in.ActiveDeadlineSeconds != nil { in, out := &in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds *out = new(int64) **out = **in - } else { - out.ActiveDeadlineSeconds = nil } - out.DNSPolicy = in.DNSPolicy if in.NodeSelector != nil { in, out := &in.NodeSelector, &out.NodeSelector *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.NodeSelector = nil - } - out.ServiceAccountName = in.ServiceAccountName - out.DeprecatedServiceAccount = in.DeprecatedServiceAccount - out.NodeName = in.NodeName - out.HostNetwork = in.HostNetwork - out.HostPID = in.HostPID - out.HostIPC = in.HostIPC + } + if in.AutomountServiceAccountToken != nil { + in, out := &in.AutomountServiceAccountToken, &out.AutomountServiceAccountToken + *out = new(bool) + **out = **in + } if in.SecurityContext != nil { in, out := &in.SecurityContext, &out.SecurityContext *out = new(PodSecurityContext) if err := DeepCopy_v1_PodSecurityContext(*in, *out, c); err != nil { return err } - } else { - out.SecurityContext = nil } if in.ImagePullSecrets != nil { in, out := &in.ImagePullSecrets, &out.ImagePullSecrets *out = make([]LocalObjectReference, len(*in)) + copy(*out, *in) + } + if in.Affinity != nil { + in, out := &in.Affinity, &out.Affinity + *out = new(Affinity) + if err := DeepCopy_v1_Affinity(*in, *out, c); err != nil { + return err + } + } + if in.Tolerations != nil { + in, out := &in.Tolerations, &out.Tolerations + *out = make([]Toleration, len(*in)) for i := range *in { - (*out)[i] = (*in)[i] + if err := DeepCopy_v1_Toleration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.HostAliases != nil { + in, out := &in.HostAliases, &out.HostAliases + *out = make([]HostAlias, len(*in)) + for i := range *in { + if err := DeepCopy_v1_HostAlias(&(*in)[i], &(*out)[i], c); err != nil { + return err + } } - } else { - out.ImagePullSecrets = nil } - out.Hostname = in.Hostname - out.Subdomain = in.Subdomain return nil } } +// DeepCopy_v1_PodStatus is an autogenerated deepcopy function. func DeepCopy_v1_PodStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodStatus) out := out.(*PodStatus) - out.Phase = in.Phase + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]PodCondition, len(*in)) @@ -2690,19 +2619,11 @@ func DeepCopy_v1_PodStatus(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.Conditions = nil } - out.Message = in.Message - out.Reason = in.Reason - out.HostIP = in.HostIP - out.PodIP = in.PodIP if in.StartTime != nil { in, out := &in.StartTime, &out.StartTime - *out = new(unversioned.Time) + *out = new(meta_v1.Time) **out = (*in).DeepCopy() - } else { - out.StartTime = nil } if in.InitContainerStatuses != nil { in, out := &in.InitContainerStatuses, &out.InitContainerStatuses @@ -2712,8 +2633,6 @@ func DeepCopy_v1_PodStatus(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.InitContainerStatuses = nil } if in.ContainerStatuses != nil { in, out := &in.ContainerStatuses, &out.ContainerStatuses @@ -2723,20 +2642,21 @@ func DeepCopy_v1_PodStatus(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.ContainerStatuses = nil } return nil } } +// DeepCopy_v1_PodStatusResult is an autogenerated deepcopy function. func DeepCopy_v1_PodStatusResult(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodStatusResult) out := out.(*PodStatusResult) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_PodStatus(&in.Status, &out.Status, c); err != nil { return err @@ -2745,13 +2665,16 @@ func DeepCopy_v1_PodStatusResult(in interface{}, out interface{}, c *conversion. } } +// DeepCopy_v1_PodTemplate is an autogenerated deepcopy function. func DeepCopy_v1_PodTemplate(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodTemplate) out := out.(*PodTemplate) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -2760,12 +2683,12 @@ func DeepCopy_v1_PodTemplate(in interface{}, out interface{}, c *conversion.Clon } } +// DeepCopy_v1_PodTemplateList is an autogenerated deepcopy function. func DeepCopy_v1_PodTemplateList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodTemplateList) out := out.(*PodTemplateList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PodTemplate, len(*in)) @@ -2774,19 +2697,21 @@ func DeepCopy_v1_PodTemplateList(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_PodTemplateSpec is an autogenerated deepcopy function. func DeepCopy_v1_PodTemplateSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodTemplateSpec) out := out.(*PodTemplateSpec) - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_PodSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2795,40 +2720,51 @@ func DeepCopy_v1_PodTemplateSpec(in interface{}, out interface{}, c *conversion. } } +// DeepCopy_v1_PortworxVolumeSource is an autogenerated deepcopy function. +func DeepCopy_v1_PortworxVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PortworxVolumeSource) + out := out.(*PortworxVolumeSource) + *out = *in + return nil + } +} + +// DeepCopy_v1_Preconditions is an autogenerated deepcopy function. func DeepCopy_v1_Preconditions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Preconditions) out := out.(*Preconditions) + *out = *in if in.UID != nil { in, out := &in.UID, &out.UID *out = new(types.UID) **out = **in - } else { - out.UID = nil } return nil } } +// DeepCopy_v1_PreferAvoidPodsEntry is an autogenerated deepcopy function. func DeepCopy_v1_PreferAvoidPodsEntry(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PreferAvoidPodsEntry) out := out.(*PreferAvoidPodsEntry) + *out = *in if err := DeepCopy_v1_PodSignature(&in.PodSignature, &out.PodSignature, c); err != nil { return err } out.EvictionTime = in.EvictionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1_PreferredSchedulingTerm is an autogenerated deepcopy function. func DeepCopy_v1_PreferredSchedulingTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PreferredSchedulingTerm) out := out.(*PreferredSchedulingTerm) - out.Weight = in.Weight + *out = *in if err := DeepCopy_v1_NodeSelectorTerm(&in.Preference, &out.Preference, c); err != nil { return err } @@ -2836,90 +2772,103 @@ func DeepCopy_v1_PreferredSchedulingTerm(in interface{}, out interface{}, c *con } } +// DeepCopy_v1_Probe is an autogenerated deepcopy function. func DeepCopy_v1_Probe(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Probe) out := out.(*Probe) + *out = *in if err := DeepCopy_v1_Handler(&in.Handler, &out.Handler, c); err != nil { return err } - out.InitialDelaySeconds = in.InitialDelaySeconds - out.TimeoutSeconds = in.TimeoutSeconds - out.PeriodSeconds = in.PeriodSeconds - out.SuccessThreshold = in.SuccessThreshold - out.FailureThreshold = in.FailureThreshold return nil } } +// DeepCopy_v1_ProjectedVolumeSource is an autogenerated deepcopy function. +func DeepCopy_v1_ProjectedVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ProjectedVolumeSource) + out := out.(*ProjectedVolumeSource) + *out = *in + if in.Sources != nil { + in, out := &in.Sources, &out.Sources + *out = make([]VolumeProjection, len(*in)) + for i := range *in { + if err := DeepCopy_v1_VolumeProjection(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.DefaultMode != nil { + in, out := &in.DefaultMode, &out.DefaultMode + *out = new(int32) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_QuobyteVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_QuobyteVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*QuobyteVolumeSource) out := out.(*QuobyteVolumeSource) - out.Registry = in.Registry - out.Volume = in.Volume - out.ReadOnly = in.ReadOnly - out.User = in.User - out.Group = in.Group + *out = *in return nil } } +// DeepCopy_v1_RBDVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_RBDVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RBDVolumeSource) out := out.(*RBDVolumeSource) + *out = *in if in.CephMonitors != nil { in, out := &in.CephMonitors, &out.CephMonitors *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.CephMonitors = nil } - out.RBDImage = in.RBDImage - out.FSType = in.FSType - out.RBDPool = in.RBDPool - out.RadosUser = in.RadosUser - out.Keyring = in.Keyring if in.SecretRef != nil { in, out := &in.SecretRef, &out.SecretRef *out = new(LocalObjectReference) **out = **in - } else { - out.SecretRef = nil } - out.ReadOnly = in.ReadOnly return nil } } +// DeepCopy_v1_RangeAllocation is an autogenerated deepcopy function. func DeepCopy_v1_RangeAllocation(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RangeAllocation) out := out.(*RangeAllocation) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } - out.Range = in.Range if in.Data != nil { in, out := &in.Data, &out.Data *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Data = nil } return nil } } +// DeepCopy_v1_ReplicationController is an autogenerated deepcopy function. func DeepCopy_v1_ReplicationController(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationController) out := out.(*ReplicationController) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_ReplicationControllerSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2931,25 +2880,23 @@ func DeepCopy_v1_ReplicationController(in interface{}, out interface{}, c *conve } } +// DeepCopy_v1_ReplicationControllerCondition is an autogenerated deepcopy function. func DeepCopy_v1_ReplicationControllerCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerCondition) out := out.(*ReplicationControllerCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1_ReplicationControllerList is an autogenerated deepcopy function. func DeepCopy_v1_ReplicationControllerList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerList) out := out.(*ReplicationControllerList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ReplicationController, len(*in)) @@ -2958,33 +2905,28 @@ func DeepCopy_v1_ReplicationControllerList(in interface{}, out interface{}, c *c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ReplicationControllerSpec is an autogenerated deepcopy function. func DeepCopy_v1_ReplicationControllerSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerSpec) out := out.(*ReplicationControllerSpec) + *out = *in if in.Replicas != nil { in, out := &in.Replicas, &out.Replicas *out = new(int32) **out = **in - } else { - out.Replicas = nil } - out.MinReadySeconds = in.MinReadySeconds if in.Selector != nil { in, out := &in.Selector, &out.Selector *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Selector = nil } if in.Template != nil { in, out := &in.Template, &out.Template @@ -2992,22 +2934,17 @@ func DeepCopy_v1_ReplicationControllerSpec(in interface{}, out interface{}, c *c if err := DeepCopy_v1_PodTemplateSpec(*in, *out, c); err != nil { return err } - } else { - out.Template = nil } return nil } } +// DeepCopy_v1_ReplicationControllerStatus is an autogenerated deepcopy function. func DeepCopy_v1_ReplicationControllerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerStatus) out := out.(*ReplicationControllerStatus) - out.Replicas = in.Replicas - out.FullyLabeledReplicas = in.FullyLabeledReplicas - out.ReadyReplicas = in.ReadyReplicas - out.AvailableReplicas = in.AvailableReplicas - out.ObservedGeneration = in.ObservedGeneration + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]ReplicationControllerCondition, len(*in)) @@ -3016,31 +2953,32 @@ func DeepCopy_v1_ReplicationControllerStatus(in interface{}, out interface{}, c return err } } - } else { - out.Conditions = nil } return nil } } +// DeepCopy_v1_ResourceFieldSelector is an autogenerated deepcopy function. func DeepCopy_v1_ResourceFieldSelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceFieldSelector) out := out.(*ResourceFieldSelector) - out.ContainerName = in.ContainerName - out.Resource = in.Resource + *out = *in out.Divisor = in.Divisor.DeepCopy() return nil } } +// DeepCopy_v1_ResourceQuota is an autogenerated deepcopy function. func DeepCopy_v1_ResourceQuota(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuota) out := out.(*ResourceQuota) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_ResourceQuotaSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -3052,12 +2990,12 @@ func DeepCopy_v1_ResourceQuota(in interface{}, out interface{}, c *conversion.Cl } } +// DeepCopy_v1_ResourceQuotaList is an autogenerated deepcopy function. func DeepCopy_v1_ResourceQuotaList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuotaList) out := out.(*ResourceQuotaList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ResourceQuota, len(*in)) @@ -3066,51 +3004,45 @@ func DeepCopy_v1_ResourceQuotaList(in interface{}, out interface{}, c *conversio return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ResourceQuotaSpec is an autogenerated deepcopy function. func DeepCopy_v1_ResourceQuotaSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuotaSpec) out := out.(*ResourceQuotaSpec) + *out = *in if in.Hard != nil { in, out := &in.Hard, &out.Hard *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Hard = nil } if in.Scopes != nil { in, out := &in.Scopes, &out.Scopes *out = make([]ResourceQuotaScope, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Scopes = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1_ResourceQuotaStatus is an autogenerated deepcopy function. func DeepCopy_v1_ResourceQuotaStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuotaStatus) out := out.(*ResourceQuotaStatus) + *out = *in if in.Hard != nil { in, out := &in.Hard, &out.Hard *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Hard = nil } if in.Used != nil { in, out := &in.Used, &out.Used @@ -3118,25 +3050,23 @@ func DeepCopy_v1_ResourceQuotaStatus(in interface{}, out interface{}, c *convers for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Used = nil } return nil } } +// DeepCopy_v1_ResourceRequirements is an autogenerated deepcopy function. func DeepCopy_v1_ResourceRequirements(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceRequirements) out := out.(*ResourceRequirements) + *out = *in if in.Limits != nil { in, out := &in.Limits, &out.Limits *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Limits = nil } if in.Requests != nil { in, out := &in.Requests, &out.Requests @@ -3144,32 +3074,46 @@ func DeepCopy_v1_ResourceRequirements(in interface{}, out interface{}, c *conver for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Requests = nil } return nil } } +// DeepCopy_v1_SELinuxOptions is an autogenerated deepcopy function. func DeepCopy_v1_SELinuxOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SELinuxOptions) out := out.(*SELinuxOptions) - out.User = in.User - out.Role = in.Role - out.Type = in.Type - out.Level = in.Level + *out = *in + return nil + } +} + +// DeepCopy_v1_ScaleIOVolumeSource is an autogenerated deepcopy function. +func DeepCopy_v1_ScaleIOVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ScaleIOVolumeSource) + out := out.(*ScaleIOVolumeSource) + *out = *in + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(LocalObjectReference) + **out = **in + } return nil } } +// DeepCopy_v1_Secret is an autogenerated deepcopy function. func DeepCopy_v1_Secret(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Secret) out := out.(*Secret) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if in.Data != nil { in, out := &in.Data, &out.Data @@ -3181,8 +3125,6 @@ func DeepCopy_v1_Secret(in interface{}, out interface{}, c *conversion.Cloner) e (*out)[key] = *newVal.(*[]byte) } } - } else { - out.Data = nil } if in.StringData != nil { in, out := &in.StringData, &out.StringData @@ -3190,30 +3132,47 @@ func DeepCopy_v1_Secret(in interface{}, out interface{}, c *conversion.Cloner) e for key, val := range *in { (*out)[key] = val } - } else { - out.StringData = nil } - out.Type = in.Type return nil } } +// DeepCopy_v1_SecretEnvSource is an autogenerated deepcopy function. +func DeepCopy_v1_SecretEnvSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SecretEnvSource) + out := out.(*SecretEnvSource) + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_SecretKeySelector is an autogenerated deepcopy function. func DeepCopy_v1_SecretKeySelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecretKeySelector) out := out.(*SecretKeySelector) - out.LocalObjectReference = in.LocalObjectReference - out.Key = in.Key + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } return nil } } +// DeepCopy_v1_SecretList is an autogenerated deepcopy function. func DeepCopy_v1_SecretList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecretList) out := out.(*SecretList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Secret, len(*in)) @@ -3222,18 +3181,41 @@ func DeepCopy_v1_SecretList(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_SecretProjection is an autogenerated deepcopy function. +func DeepCopy_v1_SecretProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SecretProjection) + out := out.(*SecretProjection) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]KeyToPath, len(*in)) + for i := range *in { + if err := DeepCopy_v1_KeyToPath(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_SecretVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_SecretVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecretVolumeSource) out := out.(*SecretVolumeSource) - out.SecretName = in.SecretName + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]KeyToPath, len(*in)) @@ -3242,89 +3224,83 @@ func DeepCopy_v1_SecretVolumeSource(in interface{}, out interface{}, c *conversi return err } } - } else { - out.Items = nil } if in.DefaultMode != nil { in, out := &in.DefaultMode, &out.DefaultMode *out = new(int32) **out = **in - } else { - out.DefaultMode = nil + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in } return nil } } +// DeepCopy_v1_SecurityContext is an autogenerated deepcopy function. func DeepCopy_v1_SecurityContext(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecurityContext) out := out.(*SecurityContext) + *out = *in if in.Capabilities != nil { in, out := &in.Capabilities, &out.Capabilities *out = new(Capabilities) if err := DeepCopy_v1_Capabilities(*in, *out, c); err != nil { return err } - } else { - out.Capabilities = nil } if in.Privileged != nil { in, out := &in.Privileged, &out.Privileged *out = new(bool) **out = **in - } else { - out.Privileged = nil } if in.SELinuxOptions != nil { in, out := &in.SELinuxOptions, &out.SELinuxOptions *out = new(SELinuxOptions) **out = **in - } else { - out.SELinuxOptions = nil } if in.RunAsUser != nil { in, out := &in.RunAsUser, &out.RunAsUser *out = new(int64) **out = **in - } else { - out.RunAsUser = nil } if in.RunAsNonRoot != nil { in, out := &in.RunAsNonRoot, &out.RunAsNonRoot *out = new(bool) **out = **in - } else { - out.RunAsNonRoot = nil } if in.ReadOnlyRootFilesystem != nil { in, out := &in.ReadOnlyRootFilesystem, &out.ReadOnlyRootFilesystem *out = new(bool) **out = **in - } else { - out.ReadOnlyRootFilesystem = nil } return nil } } +// DeepCopy_v1_SerializedReference is an autogenerated deepcopy function. func DeepCopy_v1_SerializedReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SerializedReference) out := out.(*SerializedReference) - out.TypeMeta = in.TypeMeta - out.Reference = in.Reference + *out = *in return nil } } +// DeepCopy_v1_Service is an autogenerated deepcopy function. func DeepCopy_v1_Service(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Service) out := out.(*Service) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_ServiceSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -3336,42 +3312,42 @@ func DeepCopy_v1_Service(in interface{}, out interface{}, c *conversion.Cloner) } } +// DeepCopy_v1_ServiceAccount is an autogenerated deepcopy function. func DeepCopy_v1_ServiceAccount(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceAccount) out := out.(*ServiceAccount) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if in.Secrets != nil { in, out := &in.Secrets, &out.Secrets *out = make([]ObjectReference, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Secrets = nil + copy(*out, *in) } if in.ImagePullSecrets != nil { in, out := &in.ImagePullSecrets, &out.ImagePullSecrets *out = make([]LocalObjectReference, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.ImagePullSecrets = nil + copy(*out, *in) + } + if in.AutomountServiceAccountToken != nil { + in, out := &in.AutomountServiceAccountToken, &out.AutomountServiceAccountToken + *out = new(bool) + **out = **in } return nil } } +// DeepCopy_v1_ServiceAccountList is an autogenerated deepcopy function. func DeepCopy_v1_ServiceAccountList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceAccountList) out := out.(*ServiceAccountList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ServiceAccount, len(*in)) @@ -3380,19 +3356,17 @@ func DeepCopy_v1_ServiceAccountList(in interface{}, out interface{}, c *conversi return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ServiceList is an autogenerated deepcopy function. func DeepCopy_v1_ServiceList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceList) out := out.(*ServiceList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Service, len(*in)) @@ -3401,48 +3375,41 @@ func DeepCopy_v1_ServiceList(in interface{}, out interface{}, c *conversion.Clon return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_ServicePort is an autogenerated deepcopy function. func DeepCopy_v1_ServicePort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServicePort) out := out.(*ServicePort) - out.Name = in.Name - out.Protocol = in.Protocol - out.Port = in.Port - out.TargetPort = in.TargetPort - out.NodePort = in.NodePort + *out = *in return nil } } +// DeepCopy_v1_ServiceProxyOptions is an autogenerated deepcopy function. func DeepCopy_v1_ServiceProxyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceProxyOptions) out := out.(*ServiceProxyOptions) - out.TypeMeta = in.TypeMeta - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_v1_ServiceSpec is an autogenerated deepcopy function. func DeepCopy_v1_ServiceSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceSpec) out := out.(*ServiceSpec) + *out = *in if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]ServicePort, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ports = nil + copy(*out, *in) } if in.Selector != nil { in, out := &in.Selector, &out.Selector @@ -3450,43 +3417,27 @@ func DeepCopy_v1_ServiceSpec(in interface{}, out interface{}, c *conversion.Clon for key, val := range *in { (*out)[key] = val } - } else { - out.Selector = nil } - out.ClusterIP = in.ClusterIP - out.Type = in.Type if in.ExternalIPs != nil { in, out := &in.ExternalIPs, &out.ExternalIPs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.ExternalIPs = nil - } - if in.DeprecatedPublicIPs != nil { - in, out := &in.DeprecatedPublicIPs, &out.DeprecatedPublicIPs - *out = make([]string, len(*in)) - copy(*out, *in) - } else { - out.DeprecatedPublicIPs = nil } - out.SessionAffinity = in.SessionAffinity - out.LoadBalancerIP = in.LoadBalancerIP if in.LoadBalancerSourceRanges != nil { in, out := &in.LoadBalancerSourceRanges, &out.LoadBalancerSourceRanges *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.LoadBalancerSourceRanges = nil } - out.ExternalName = in.ExternalName return nil } } +// DeepCopy_v1_ServiceStatus is an autogenerated deepcopy function. func DeepCopy_v1_ServiceStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceStatus) out := out.(*ServiceStatus) + *out = *in if err := DeepCopy_v1_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, c); err != nil { return err } @@ -3494,43 +3445,88 @@ func DeepCopy_v1_ServiceStatus(in interface{}, out interface{}, c *conversion.Cl } } +// DeepCopy_v1_StorageOSPersistentVolumeSource is an autogenerated deepcopy function. +func DeepCopy_v1_StorageOSPersistentVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StorageOSPersistentVolumeSource) + out := out.(*StorageOSPersistentVolumeSource) + *out = *in + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(ObjectReference) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_StorageOSVolumeSource is an autogenerated deepcopy function. +func DeepCopy_v1_StorageOSVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StorageOSVolumeSource) + out := out.(*StorageOSVolumeSource) + *out = *in + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(LocalObjectReference) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_Sysctl is an autogenerated deepcopy function. +func DeepCopy_v1_Sysctl(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Sysctl) + out := out.(*Sysctl) + *out = *in + return nil + } +} + +// DeepCopy_v1_TCPSocketAction is an autogenerated deepcopy function. func DeepCopy_v1_TCPSocketAction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TCPSocketAction) out := out.(*TCPSocketAction) - out.Port = in.Port + *out = *in return nil } } +// DeepCopy_v1_Taint is an autogenerated deepcopy function. func DeepCopy_v1_Taint(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Taint) out := out.(*Taint) - out.Key = in.Key - out.Value = in.Value - out.Effect = in.Effect + *out = *in + out.TimeAdded = in.TimeAdded.DeepCopy() return nil } } +// DeepCopy_v1_Toleration is an autogenerated deepcopy function. func DeepCopy_v1_Toleration(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Toleration) out := out.(*Toleration) - out.Key = in.Key - out.Operator = in.Operator - out.Value = in.Value - out.Effect = in.Effect + *out = *in + if in.TolerationSeconds != nil { + in, out := &in.TolerationSeconds, &out.TolerationSeconds + *out = new(int64) + **out = **in + } return nil } } +// DeepCopy_v1_Volume is an autogenerated deepcopy function. func DeepCopy_v1_Volume(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Volume) out := out.(*Volume) - out.Name = in.Name + *out = *in if err := DeepCopy_v1_VolumeSource(&in.VolumeSource, &out.VolumeSource, c); err != nil { return err } @@ -3538,56 +3534,79 @@ func DeepCopy_v1_Volume(in interface{}, out interface{}, c *conversion.Cloner) e } } +// DeepCopy_v1_VolumeMount is an autogenerated deepcopy function. func DeepCopy_v1_VolumeMount(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*VolumeMount) out := out.(*VolumeMount) - out.Name = in.Name - out.ReadOnly = in.ReadOnly - out.MountPath = in.MountPath - out.SubPath = in.SubPath + *out = *in return nil } } +// DeepCopy_v1_VolumeProjection is an autogenerated deepcopy function. +func DeepCopy_v1_VolumeProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*VolumeProjection) + out := out.(*VolumeProjection) + *out = *in + if in.Secret != nil { + in, out := &in.Secret, &out.Secret + *out = new(SecretProjection) + if err := DeepCopy_v1_SecretProjection(*in, *out, c); err != nil { + return err + } + } + if in.DownwardAPI != nil { + in, out := &in.DownwardAPI, &out.DownwardAPI + *out = new(DownwardAPIProjection) + if err := DeepCopy_v1_DownwardAPIProjection(*in, *out, c); err != nil { + return err + } + } + if in.ConfigMap != nil { + in, out := &in.ConfigMap, &out.ConfigMap + *out = new(ConfigMapProjection) + if err := DeepCopy_v1_ConfigMapProjection(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v1_VolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*VolumeSource) out := out.(*VolumeSource) + *out = *in if in.HostPath != nil { in, out := &in.HostPath, &out.HostPath *out = new(HostPathVolumeSource) **out = **in - } else { - out.HostPath = nil } if in.EmptyDir != nil { in, out := &in.EmptyDir, &out.EmptyDir *out = new(EmptyDirVolumeSource) - **out = **in - } else { - out.EmptyDir = nil + if err := DeepCopy_v1_EmptyDirVolumeSource(*in, *out, c); err != nil { + return err + } } if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk *out = new(GCEPersistentDiskVolumeSource) **out = **in - } else { - out.GCEPersistentDisk = nil } if in.AWSElasticBlockStore != nil { in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore *out = new(AWSElasticBlockStoreVolumeSource) **out = **in - } else { - out.AWSElasticBlockStore = nil } if in.GitRepo != nil { in, out := &in.GitRepo, &out.GitRepo *out = new(GitRepoVolumeSource) **out = **in - } else { - out.GitRepo = nil } if in.Secret != nil { in, out := &in.Secret, &out.Secret @@ -3595,36 +3614,28 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_SecretVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.Secret = nil } if in.NFS != nil { in, out := &in.NFS, &out.NFS *out = new(NFSVolumeSource) **out = **in - } else { - out.NFS = nil } if in.ISCSI != nil { in, out := &in.ISCSI, &out.ISCSI *out = new(ISCSIVolumeSource) - **out = **in - } else { - out.ISCSI = nil + if err := DeepCopy_v1_ISCSIVolumeSource(*in, *out, c); err != nil { + return err + } } if in.Glusterfs != nil { in, out := &in.Glusterfs, &out.Glusterfs *out = new(GlusterfsVolumeSource) **out = **in - } else { - out.Glusterfs = nil } if in.PersistentVolumeClaim != nil { in, out := &in.PersistentVolumeClaim, &out.PersistentVolumeClaim *out = new(PersistentVolumeClaimVolumeSource) **out = **in - } else { - out.PersistentVolumeClaim = nil } if in.RBD != nil { in, out := &in.RBD, &out.RBD @@ -3632,8 +3643,6 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_RBDVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.RBD = nil } if in.FlexVolume != nil { in, out := &in.FlexVolume, &out.FlexVolume @@ -3641,15 +3650,11 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_FlexVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FlexVolume = nil } if in.Cinder != nil { in, out := &in.Cinder, &out.Cinder *out = new(CinderVolumeSource) **out = **in - } else { - out.Cinder = nil } if in.CephFS != nil { in, out := &in.CephFS, &out.CephFS @@ -3657,15 +3662,11 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_CephFSVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.CephFS = nil } if in.Flocker != nil { in, out := &in.Flocker, &out.Flocker *out = new(FlockerVolumeSource) **out = **in - } else { - out.Flocker = nil } if in.DownwardAPI != nil { in, out := &in.DownwardAPI, &out.DownwardAPI @@ -3673,8 +3674,6 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_DownwardAPIVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.DownwardAPI = nil } if in.FC != nil { in, out := &in.FC, &out.FC @@ -3682,15 +3681,11 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_FCVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FC = nil } if in.AzureFile != nil { in, out := &in.AzureFile, &out.AzureFile *out = new(AzureFileVolumeSource) **out = **in - } else { - out.AzureFile = nil } if in.ConfigMap != nil { in, out := &in.ConfigMap, &out.ConfigMap @@ -3698,22 +3693,16 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_ConfigMapVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.ConfigMap = nil } if in.VsphereVolume != nil { in, out := &in.VsphereVolume, &out.VsphereVolume *out = new(VsphereVirtualDiskVolumeSource) **out = **in - } else { - out.VsphereVolume = nil } if in.Quobyte != nil { in, out := &in.Quobyte, &out.Quobyte *out = new(QuobyteVolumeSource) **out = **in - } else { - out.Quobyte = nil } if in.AzureDisk != nil { in, out := &in.AzureDisk, &out.AzureDisk @@ -3721,35 +3710,58 @@ func DeepCopy_v1_VolumeSource(in interface{}, out interface{}, c *conversion.Clo if err := DeepCopy_v1_AzureDiskVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.AzureDisk = nil } if in.PhotonPersistentDisk != nil { in, out := &in.PhotonPersistentDisk, &out.PhotonPersistentDisk *out = new(PhotonPersistentDiskVolumeSource) **out = **in - } else { - out.PhotonPersistentDisk = nil + } + if in.Projected != nil { + in, out := &in.Projected, &out.Projected + *out = new(ProjectedVolumeSource) + if err := DeepCopy_v1_ProjectedVolumeSource(*in, *out, c); err != nil { + return err + } + } + if in.PortworxVolume != nil { + in, out := &in.PortworxVolume, &out.PortworxVolume + *out = new(PortworxVolumeSource) + **out = **in + } + if in.ScaleIO != nil { + in, out := &in.ScaleIO, &out.ScaleIO + *out = new(ScaleIOVolumeSource) + if err := DeepCopy_v1_ScaleIOVolumeSource(*in, *out, c); err != nil { + return err + } + } + if in.StorageOS != nil { + in, out := &in.StorageOS, &out.StorageOS + *out = new(StorageOSVolumeSource) + if err := DeepCopy_v1_StorageOSVolumeSource(*in, *out, c); err != nil { + return err + } } return nil } } +// DeepCopy_v1_VsphereVirtualDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_v1_VsphereVirtualDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*VsphereVirtualDiskVolumeSource) out := out.(*VsphereVirtualDiskVolumeSource) - out.VolumePath = in.VolumePath - out.FSType = in.FSType + *out = *in return nil } } +// DeepCopy_v1_WeightedPodAffinityTerm is an autogenerated deepcopy function. func DeepCopy_v1_WeightedPodAffinityTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*WeightedPodAffinityTerm) out := out.(*WeightedPodAffinityTerm) - out.Weight = in.Weight + *out = *in if err := DeepCopy_v1_PodAffinityTerm(&in.PodAffinityTerm, &out.PodAffinityTerm, c); err != nil { return err } diff --git a/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.defaults.go index 3b28e6755b..31e7950669 100644 --- a/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/api/v1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,7 +21,7 @@ limitations under the License. package v1 import ( - runtime "k8s.io/client-go/pkg/runtime" + runtime "k8s.io/apimachinery/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. @@ -137,6 +137,9 @@ func SetObjectDefaults_PersistentVolume(in *PersistentVolume) { if in.Spec.PersistentVolumeSource.AzureDisk != nil { SetDefaults_AzureDiskVolumeSource(in.Spec.PersistentVolumeSource.AzureDisk) } + if in.Spec.PersistentVolumeSource.ScaleIO != nil { + SetDefaults_ScaleIOVolumeSource(in.Spec.PersistentVolumeSource.ScaleIO) + } } func SetObjectDefaults_PersistentVolumeClaim(in *PersistentVolumeClaim) { @@ -190,6 +193,23 @@ func SetObjectDefaults_Pod(in *Pod) { if a.VolumeSource.AzureDisk != nil { SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.InitContainers { a := &in.Spec.InitContainers[i] @@ -321,6 +341,23 @@ func SetObjectDefaults_PodTemplate(in *PodTemplate) { if a.VolumeSource.AzureDisk != nil { SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Template.Spec.InitContainers { a := &in.Template.Spec.InitContainers[i] @@ -446,6 +483,23 @@ func SetObjectDefaults_ReplicationController(in *ReplicationController) { if a.VolumeSource.AzureDisk != nil { SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.Template.Spec.InitContainers { a := &in.Spec.Template.Spec.InitContainers[i] @@ -566,7 +620,7 @@ func SetObjectDefaults_SecretList(in *SecretList) { } func SetObjectDefaults_Service(in *Service) { - SetDefaults_ServiceSpec(&in.Spec) + SetDefaults_Service(in) } func SetObjectDefaults_ServiceList(in *ServiceList) { diff --git a/vendor/k8s.io/client-go/pkg/api/validation/path/name.go b/vendor/k8s.io/client-go/pkg/api/validation/path/name.go deleted file mode 100644 index 981d9bb465..0000000000 --- a/vendor/k8s.io/client-go/pkg/api/validation/path/name.go +++ /dev/null @@ -1,66 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package path - -import ( - "fmt" - "strings" -) - -// NameMayNotBe specifies strings that cannot be used as names specified as path segments (like the REST API or etcd store) -var NameMayNotBe = []string{".", ".."} - -// NameMayNotContain specifies substrings that cannot be used in names specified as path segments (like the REST API or etcd store) -var NameMayNotContain = []string{"/", "%"} - -// IsValidPathSegmentName validates the name can be safely encoded as a path segment -func IsValidPathSegmentName(name string) []string { - for _, illegalName := range NameMayNotBe { - if name == illegalName { - return []string{fmt.Sprintf(`may not be '%s'`, illegalName)} - } - } - - for _, illegalContent := range NameMayNotContain { - if strings.Contains(name, illegalContent) { - return []string{fmt.Sprintf(`may not contain '%s'`, illegalContent)} - } - } - - return nil -} - -// IsValidPathSegmentPrefix validates the name can be used as a prefix for a name which will be encoded as a path segment -// It does not check for exact matches with disallowed names, since an arbitrary suffix might make the name valid -func IsValidPathSegmentPrefix(name string) []string { - for _, illegalContent := range NameMayNotContain { - if strings.Contains(name, illegalContent) { - return []string{fmt.Sprintf(`may not contain '%s'`, illegalContent)} - } - } - - return nil -} - -// ValidatePathSegmentName validates the name can be safely encoded as a path segment -func ValidatePathSegmentName(name string, prefix bool) []string { - if prefix { - return IsValidPathSegmentPrefix(name) - } else { - return IsValidPathSegmentName(name) - } -} diff --git a/vendor/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go index 3731358095..cc111561b7 100644 --- a/vendor/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/api/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,12 +21,12 @@ limitations under the License. package api import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - fields "k8s.io/client-go/pkg/fields" - labels "k8s.io/client-go/pkg/labels" - runtime "k8s.io/client-go/pkg/runtime" - types "k8s.io/client-go/pkg/types" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + fields "k8s.io/apimachinery/pkg/fields" + labels "k8s.io/apimachinery/pkg/labels" + runtime "k8s.io/apimachinery/pkg/runtime" + types "k8s.io/apimachinery/pkg/types" reflect "reflect" ) @@ -52,8 +52,10 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ComponentStatus, InType: reflect.TypeOf(&ComponentStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ComponentStatusList, InType: reflect.TypeOf(&ComponentStatusList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConfigMap, InType: reflect.TypeOf(&ConfigMap{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConfigMapEnvSource, InType: reflect.TypeOf(&ConfigMapEnvSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConfigMapKeySelector, InType: reflect.TypeOf(&ConfigMapKeySelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConfigMapList, InType: reflect.TypeOf(&ConfigMapList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConfigMapProjection, InType: reflect.TypeOf(&ConfigMapProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConfigMapVolumeSource, InType: reflect.TypeOf(&ConfigMapVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Container, InType: reflect.TypeOf(&Container{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ContainerImage, InType: reflect.TypeOf(&ContainerImage{})}, @@ -63,9 +65,9 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ContainerStateTerminated, InType: reflect.TypeOf(&ContainerStateTerminated{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ContainerStateWaiting, InType: reflect.TypeOf(&ContainerStateWaiting{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ContainerStatus, InType: reflect.TypeOf(&ContainerStatus{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ConversionError, InType: reflect.TypeOf(&ConversionError{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_DaemonEndpoint, InType: reflect.TypeOf(&DaemonEndpoint{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_DeleteOptions, InType: reflect.TypeOf(&DeleteOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_DownwardAPIProjection, InType: reflect.TypeOf(&DownwardAPIProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_DownwardAPIVolumeFile, InType: reflect.TypeOf(&DownwardAPIVolumeFile{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_DownwardAPIVolumeSource, InType: reflect.TypeOf(&DownwardAPIVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EmptyDirVolumeSource, InType: reflect.TypeOf(&EmptyDirVolumeSource{})}, @@ -74,13 +76,13 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EndpointSubset, InType: reflect.TypeOf(&EndpointSubset{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Endpoints, InType: reflect.TypeOf(&Endpoints{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EndpointsList, InType: reflect.TypeOf(&EndpointsList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EnvFromSource, InType: reflect.TypeOf(&EnvFromSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EnvVar, InType: reflect.TypeOf(&EnvVar{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EnvVarSource, InType: reflect.TypeOf(&EnvVarSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Event, InType: reflect.TypeOf(&Event{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EventList, InType: reflect.TypeOf(&EventList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_EventSource, InType: reflect.TypeOf(&EventSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ExecAction, InType: reflect.TypeOf(&ExecAction{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ExportOptions, InType: reflect.TypeOf(&ExportOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_FCVolumeSource, InType: reflect.TypeOf(&FCVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_FlexVolumeSource, InType: reflect.TypeOf(&FlexVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_FlockerVolumeSource, InType: reflect.TypeOf(&FlockerVolumeSource{})}, @@ -90,6 +92,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_HTTPGetAction, InType: reflect.TypeOf(&HTTPGetAction{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_HTTPHeader, InType: reflect.TypeOf(&HTTPHeader{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Handler, InType: reflect.TypeOf(&Handler{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_HostAlias, InType: reflect.TypeOf(&HostAlias{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_HostPathVolumeSource, InType: reflect.TypeOf(&HostPathVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ISCSIVolumeSource, InType: reflect.TypeOf(&ISCSIVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_KeyToPath, InType: reflect.TypeOf(&KeyToPath{})}, @@ -103,6 +106,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_LoadBalancerIngress, InType: reflect.TypeOf(&LoadBalancerIngress{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_LoadBalancerStatus, InType: reflect.TypeOf(&LoadBalancerStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_LocalObjectReference, InType: reflect.TypeOf(&LocalObjectReference{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_LocalVolumeSource, InType: reflect.TypeOf(&LocalVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_NFSVolumeSource, InType: reflect.TypeOf(&NFSVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Namespace, InType: reflect.TypeOf(&Namespace{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_NamespaceList, InType: reflect.TypeOf(&NamespaceList{})}, @@ -125,7 +129,6 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ObjectFieldSelector, InType: reflect.TypeOf(&ObjectFieldSelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ObjectMeta, InType: reflect.TypeOf(&ObjectMeta{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ObjectReference, InType: reflect.TypeOf(&ObjectReference{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_OwnerReference, InType: reflect.TypeOf(&OwnerReference{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PersistentVolume, InType: reflect.TypeOf(&PersistentVolume{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PersistentVolumeClaim, InType: reflect.TypeOf(&PersistentVolumeClaim{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PersistentVolumeClaimList, InType: reflect.TypeOf(&PersistentVolumeClaimList{})}, @@ -146,6 +149,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodExecOptions, InType: reflect.TypeOf(&PodExecOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodList, InType: reflect.TypeOf(&PodList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodLogOptions, InType: reflect.TypeOf(&PodLogOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodPortForwardOptions, InType: reflect.TypeOf(&PodPortForwardOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodProxyOptions, InType: reflect.TypeOf(&PodProxyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodSecurityContext, InType: reflect.TypeOf(&PodSecurityContext{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodSignature, InType: reflect.TypeOf(&PodSignature{})}, @@ -155,10 +159,12 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodTemplate, InType: reflect.TypeOf(&PodTemplate{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodTemplateList, InType: reflect.TypeOf(&PodTemplateList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PodTemplateSpec, InType: reflect.TypeOf(&PodTemplateSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PortworxVolumeSource, InType: reflect.TypeOf(&PortworxVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Preconditions, InType: reflect.TypeOf(&Preconditions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PreferAvoidPodsEntry, InType: reflect.TypeOf(&PreferAvoidPodsEntry{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_PreferredSchedulingTerm, InType: reflect.TypeOf(&PreferredSchedulingTerm{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Probe, InType: reflect.TypeOf(&Probe{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ProjectedVolumeSource, InType: reflect.TypeOf(&ProjectedVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_QuobyteVolumeSource, InType: reflect.TypeOf(&QuobyteVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_RBDVolumeSource, InType: reflect.TypeOf(&RBDVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_RangeAllocation, InType: reflect.TypeOf(&RangeAllocation{})}, @@ -174,9 +180,12 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ResourceQuotaStatus, InType: reflect.TypeOf(&ResourceQuotaStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ResourceRequirements, InType: reflect.TypeOf(&ResourceRequirements{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SELinuxOptions, InType: reflect.TypeOf(&SELinuxOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ScaleIOVolumeSource, InType: reflect.TypeOf(&ScaleIOVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Secret, InType: reflect.TypeOf(&Secret{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SecretEnvSource, InType: reflect.TypeOf(&SecretEnvSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SecretKeySelector, InType: reflect.TypeOf(&SecretKeySelector{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SecretList, InType: reflect.TypeOf(&SecretList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SecretProjection, InType: reflect.TypeOf(&SecretProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SecretVolumeSource, InType: reflect.TypeOf(&SecretVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SecurityContext, InType: reflect.TypeOf(&SecurityContext{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_SerializedReference, InType: reflect.TypeOf(&SerializedReference{})}, @@ -188,42 +197,43 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ServiceProxyOptions, InType: reflect.TypeOf(&ServiceProxyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ServiceSpec, InType: reflect.TypeOf(&ServiceSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_ServiceStatus, InType: reflect.TypeOf(&ServiceStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_StorageOSPersistentVolumeSource, InType: reflect.TypeOf(&StorageOSPersistentVolumeSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_StorageOSVolumeSource, InType: reflect.TypeOf(&StorageOSVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Sysctl, InType: reflect.TypeOf(&Sysctl{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_TCPSocketAction, InType: reflect.TypeOf(&TCPSocketAction{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Taint, InType: reflect.TypeOf(&Taint{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Toleration, InType: reflect.TypeOf(&Toleration{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_Volume, InType: reflect.TypeOf(&Volume{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_VolumeMount, InType: reflect.TypeOf(&VolumeMount{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_VolumeProjection, InType: reflect.TypeOf(&VolumeProjection{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_VolumeSource, InType: reflect.TypeOf(&VolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_VsphereVirtualDiskVolumeSource, InType: reflect.TypeOf(&VsphereVirtualDiskVolumeSource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_api_WeightedPodAffinityTerm, InType: reflect.TypeOf(&WeightedPodAffinityTerm{})}, ) } +// DeepCopy_api_AWSElasticBlockStoreVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_AWSElasticBlockStoreVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AWSElasticBlockStoreVolumeSource) out := out.(*AWSElasticBlockStoreVolumeSource) - out.VolumeID = in.VolumeID - out.FSType = in.FSType - out.Partition = in.Partition - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_Affinity is an autogenerated deepcopy function. func DeepCopy_api_Affinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Affinity) out := out.(*Affinity) + *out = *in if in.NodeAffinity != nil { in, out := &in.NodeAffinity, &out.NodeAffinity *out = new(NodeAffinity) if err := DeepCopy_api_NodeAffinity(*in, *out, c); err != nil { return err } - } else { - out.NodeAffinity = nil } if in.PodAffinity != nil { in, out := &in.PodAffinity, &out.PodAffinity @@ -231,8 +241,6 @@ func DeepCopy_api_Affinity(in interface{}, out interface{}, c *conversion.Cloner if err := DeepCopy_api_PodAffinity(*in, *out, c); err != nil { return err } - } else { - out.PodAffinity = nil } if in.PodAntiAffinity != nil { in, out := &in.PodAntiAffinity, &out.PodAntiAffinity @@ -240,27 +248,27 @@ func DeepCopy_api_Affinity(in interface{}, out interface{}, c *conversion.Cloner if err := DeepCopy_api_PodAntiAffinity(*in, *out, c); err != nil { return err } - } else { - out.PodAntiAffinity = nil } return nil } } +// DeepCopy_api_AttachedVolume is an autogenerated deepcopy function. func DeepCopy_api_AttachedVolume(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AttachedVolume) out := out.(*AttachedVolume) - out.Name = in.Name - out.DevicePath = in.DevicePath + *out = *in return nil } } +// DeepCopy_api_AvoidPods is an autogenerated deepcopy function. func DeepCopy_api_AvoidPods(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AvoidPods) out := out.(*AvoidPods) + *out = *in if in.PreferAvoidPods != nil { in, out := &in.PreferAvoidPods, &out.PreferAvoidPods *out = make([]PreferAvoidPodsEntry, len(*in)) @@ -269,170 +277,152 @@ func DeepCopy_api_AvoidPods(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.PreferAvoidPods = nil } return nil } } +// DeepCopy_api_AzureDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_AzureDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AzureDiskVolumeSource) out := out.(*AzureDiskVolumeSource) - out.DiskName = in.DiskName - out.DataDiskURI = in.DataDiskURI + *out = *in if in.CachingMode != nil { in, out := &in.CachingMode, &out.CachingMode *out = new(AzureDataDiskCachingMode) **out = **in - } else { - out.CachingMode = nil } if in.FSType != nil { in, out := &in.FSType, &out.FSType *out = new(string) **out = **in - } else { - out.FSType = nil } if in.ReadOnly != nil { in, out := &in.ReadOnly, &out.ReadOnly *out = new(bool) **out = **in - } else { - out.ReadOnly = nil + } + if in.Kind != nil { + in, out := &in.Kind, &out.Kind + *out = new(AzureDataDiskKind) + **out = **in } return nil } } +// DeepCopy_api_AzureFileVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_AzureFileVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*AzureFileVolumeSource) out := out.(*AzureFileVolumeSource) - out.SecretName = in.SecretName - out.ShareName = in.ShareName - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_Binding is an autogenerated deepcopy function. func DeepCopy_api_Binding(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Binding) out := out.(*Binding) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Target = in.Target return nil } } +// DeepCopy_api_Capabilities is an autogenerated deepcopy function. func DeepCopy_api_Capabilities(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Capabilities) out := out.(*Capabilities) + *out = *in if in.Add != nil { in, out := &in.Add, &out.Add *out = make([]Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Add = nil + copy(*out, *in) } if in.Drop != nil { in, out := &in.Drop, &out.Drop *out = make([]Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Drop = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_CephFSVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_CephFSVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CephFSVolumeSource) out := out.(*CephFSVolumeSource) + *out = *in if in.Monitors != nil { in, out := &in.Monitors, &out.Monitors *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Monitors = nil } - out.Path = in.Path - out.User = in.User - out.SecretFile = in.SecretFile if in.SecretRef != nil { in, out := &in.SecretRef, &out.SecretRef *out = new(LocalObjectReference) **out = **in - } else { - out.SecretRef = nil } - out.ReadOnly = in.ReadOnly return nil } } +// DeepCopy_api_CinderVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_CinderVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CinderVolumeSource) out := out.(*CinderVolumeSource) - out.VolumeID = in.VolumeID - out.FSType = in.FSType - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_ComponentCondition is an autogenerated deepcopy function. func DeepCopy_api_ComponentCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ComponentCondition) out := out.(*ComponentCondition) - out.Type = in.Type - out.Status = in.Status - out.Message = in.Message - out.Error = in.Error + *out = *in return nil } } +// DeepCopy_api_ComponentStatus is an autogenerated deepcopy function. func DeepCopy_api_ComponentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ComponentStatus) out := out.(*ComponentStatus) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]ComponentCondition, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Conditions = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_ComponentStatusList is an autogenerated deepcopy function. func DeepCopy_api_ComponentStatusList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ComponentStatusList) out := out.(*ComponentStatusList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ComponentStatus, len(*in)) @@ -441,20 +431,21 @@ func DeepCopy_api_ComponentStatusList(in interface{}, out interface{}, c *conver return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ConfigMap is an autogenerated deepcopy function. func DeepCopy_api_ConfigMap(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMap) out := out.(*ConfigMap) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Data != nil { in, out := &in.Data, &out.Data @@ -462,29 +453,47 @@ func DeepCopy_api_ConfigMap(in interface{}, out interface{}, c *conversion.Clone for key, val := range *in { (*out)[key] = val } - } else { - out.Data = nil } return nil } } +// DeepCopy_api_ConfigMapEnvSource is an autogenerated deepcopy function. +func DeepCopy_api_ConfigMapEnvSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ConfigMapEnvSource) + out := out.(*ConfigMapEnvSource) + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_api_ConfigMapKeySelector is an autogenerated deepcopy function. func DeepCopy_api_ConfigMapKeySelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMapKeySelector) out := out.(*ConfigMapKeySelector) - out.LocalObjectReference = in.LocalObjectReference - out.Key = in.Key + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } return nil } } +// DeepCopy_api_ConfigMapList is an autogenerated deepcopy function. func DeepCopy_api_ConfigMapList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMapList) out := out.(*ConfigMapList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ConfigMap, len(*in)) @@ -493,18 +502,41 @@ func DeepCopy_api_ConfigMapList(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ConfigMapProjection is an autogenerated deepcopy function. +func DeepCopy_api_ConfigMapProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ConfigMapProjection) + out := out.(*ConfigMapProjection) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]KeyToPath, len(*in)) + for i := range *in { + if err := DeepCopy_api_KeyToPath(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_api_ConfigMapVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_ConfigMapVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ConfigMapVolumeSource) out := out.(*ConfigMapVolumeSource) - out.LocalObjectReference = in.LocalObjectReference + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]KeyToPath, len(*in)) @@ -513,49 +545,50 @@ func DeepCopy_api_ConfigMapVolumeSource(in interface{}, out interface{}, c *conv return err } } - } else { - out.Items = nil } if in.DefaultMode != nil { in, out := &in.DefaultMode, &out.DefaultMode *out = new(int32) **out = **in - } else { - out.DefaultMode = nil + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in } return nil } } +// DeepCopy_api_Container is an autogenerated deepcopy function. func DeepCopy_api_Container(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Container) out := out.(*Container) - out.Name = in.Name - out.Image = in.Image + *out = *in if in.Command != nil { in, out := &in.Command, &out.Command *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Command = nil } if in.Args != nil { in, out := &in.Args, &out.Args *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Args = nil } - out.WorkingDir = in.WorkingDir if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]ContainerPort, len(*in)) + copy(*out, *in) + } + if in.EnvFrom != nil { + in, out := &in.EnvFrom, &out.EnvFrom + *out = make([]EnvFromSource, len(*in)) for i := range *in { - (*out)[i] = (*in)[i] + if err := DeepCopy_api_EnvFromSource(&(*in)[i], &(*out)[i], c); err != nil { + return err + } } - } else { - out.Ports = nil } if in.Env != nil { in, out := &in.Env, &out.Env @@ -565,8 +598,6 @@ func DeepCopy_api_Container(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Env = nil } if err := DeepCopy_api_ResourceRequirements(&in.Resources, &out.Resources, c); err != nil { return err @@ -574,11 +605,7 @@ func DeepCopy_api_Container(in interface{}, out interface{}, c *conversion.Clone if in.VolumeMounts != nil { in, out := &in.VolumeMounts, &out.VolumeMounts *out = make([]VolumeMount, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.VolumeMounts = nil + copy(*out, *in) } if in.LivenessProbe != nil { in, out := &in.LivenessProbe, &out.LivenessProbe @@ -586,8 +613,6 @@ func DeepCopy_api_Container(in interface{}, out interface{}, c *conversion.Clone if err := DeepCopy_api_Probe(*in, *out, c); err != nil { return err } - } else { - out.LivenessProbe = nil } if in.ReadinessProbe != nil { in, out := &in.ReadinessProbe, &out.ReadinessProbe @@ -595,8 +620,6 @@ func DeepCopy_api_Container(in interface{}, out interface{}, c *conversion.Clone if err := DeepCopy_api_Probe(*in, *out, c); err != nil { return err } - } else { - out.ReadinessProbe = nil } if in.Lifecycle != nil { in, out := &in.Lifecycle, &out.Lifecycle @@ -604,66 +627,53 @@ func DeepCopy_api_Container(in interface{}, out interface{}, c *conversion.Clone if err := DeepCopy_api_Lifecycle(*in, *out, c); err != nil { return err } - } else { - out.Lifecycle = nil } - out.TerminationMessagePath = in.TerminationMessagePath - out.ImagePullPolicy = in.ImagePullPolicy if in.SecurityContext != nil { in, out := &in.SecurityContext, &out.SecurityContext *out = new(SecurityContext) if err := DeepCopy_api_SecurityContext(*in, *out, c); err != nil { return err } - } else { - out.SecurityContext = nil } - out.Stdin = in.Stdin - out.StdinOnce = in.StdinOnce - out.TTY = in.TTY return nil } } +// DeepCopy_api_ContainerImage is an autogenerated deepcopy function. func DeepCopy_api_ContainerImage(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerImage) out := out.(*ContainerImage) + *out = *in if in.Names != nil { in, out := &in.Names, &out.Names *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Names = nil } - out.SizeBytes = in.SizeBytes return nil } } +// DeepCopy_api_ContainerPort is an autogenerated deepcopy function. func DeepCopy_api_ContainerPort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerPort) out := out.(*ContainerPort) - out.Name = in.Name - out.HostPort = in.HostPort - out.ContainerPort = in.ContainerPort - out.Protocol = in.Protocol - out.HostIP = in.HostIP + *out = *in return nil } } +// DeepCopy_api_ContainerState is an autogenerated deepcopy function. func DeepCopy_api_ContainerState(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerState) out := out.(*ContainerState) + *out = *in if in.Waiting != nil { in, out := &in.Waiting, &out.Waiting *out = new(ContainerStateWaiting) **out = **in - } else { - out.Waiting = nil } if in.Running != nil { in, out := &in.Running, &out.Running @@ -671,8 +681,6 @@ func DeepCopy_api_ContainerState(in interface{}, out interface{}, c *conversion. if err := DeepCopy_api_ContainerStateRunning(*in, *out, c); err != nil { return err } - } else { - out.Running = nil } if in.Terminated != nil { in, out := &in.Terminated, &out.Terminated @@ -680,110 +688,80 @@ func DeepCopy_api_ContainerState(in interface{}, out interface{}, c *conversion. if err := DeepCopy_api_ContainerStateTerminated(*in, *out, c); err != nil { return err } - } else { - out.Terminated = nil } return nil } } +// DeepCopy_api_ContainerStateRunning is an autogenerated deepcopy function. func DeepCopy_api_ContainerStateRunning(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStateRunning) out := out.(*ContainerStateRunning) + *out = *in out.StartedAt = in.StartedAt.DeepCopy() return nil } } +// DeepCopy_api_ContainerStateTerminated is an autogenerated deepcopy function. func DeepCopy_api_ContainerStateTerminated(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStateTerminated) out := out.(*ContainerStateTerminated) - out.ExitCode = in.ExitCode - out.Signal = in.Signal - out.Reason = in.Reason - out.Message = in.Message + *out = *in out.StartedAt = in.StartedAt.DeepCopy() out.FinishedAt = in.FinishedAt.DeepCopy() - out.ContainerID = in.ContainerID return nil } } +// DeepCopy_api_ContainerStateWaiting is an autogenerated deepcopy function. func DeepCopy_api_ContainerStateWaiting(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStateWaiting) out := out.(*ContainerStateWaiting) - out.Reason = in.Reason - out.Message = in.Message + *out = *in return nil } } +// DeepCopy_api_ContainerStatus is an autogenerated deepcopy function. func DeepCopy_api_ContainerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ContainerStatus) out := out.(*ContainerStatus) - out.Name = in.Name + *out = *in if err := DeepCopy_api_ContainerState(&in.State, &out.State, c); err != nil { return err } if err := DeepCopy_api_ContainerState(&in.LastTerminationState, &out.LastTerminationState, c); err != nil { return err } - out.Ready = in.Ready - out.RestartCount = in.RestartCount - out.Image = in.Image - out.ImageID = in.ImageID - out.ContainerID = in.ContainerID - return nil - } -} - -func DeepCopy_api_ConversionError(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ConversionError) - out := out.(*ConversionError) - if in.In == nil { - out.In = nil - } else if newVal, err := c.DeepCopy(&in.In); err != nil { - return err - } else { - out.In = *newVal.(*interface{}) - } - if in.Out == nil { - out.Out = nil - } else if newVal, err := c.DeepCopy(&in.Out); err != nil { - return err - } else { - out.Out = *newVal.(*interface{}) - } - out.Message = in.Message return nil } } +// DeepCopy_api_DaemonEndpoint is an autogenerated deepcopy function. func DeepCopy_api_DaemonEndpoint(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonEndpoint) out := out.(*DaemonEndpoint) - out.Port = in.Port + *out = *in return nil } } +// DeepCopy_api_DeleteOptions is an autogenerated deepcopy function. func DeepCopy_api_DeleteOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeleteOptions) out := out.(*DeleteOptions) - out.TypeMeta = in.TypeMeta + *out = *in if in.GracePeriodSeconds != nil { in, out := &in.GracePeriodSeconds, &out.GracePeriodSeconds *out = new(int64) **out = **in - } else { - out.GracePeriodSeconds = nil } if in.Preconditions != nil { in, out := &in.Preconditions, &out.Preconditions @@ -791,31 +769,50 @@ func DeepCopy_api_DeleteOptions(in interface{}, out interface{}, c *conversion.C if err := DeepCopy_api_Preconditions(*in, *out, c); err != nil { return err } - } else { - out.Preconditions = nil } if in.OrphanDependents != nil { in, out := &in.OrphanDependents, &out.OrphanDependents *out = new(bool) **out = **in - } else { - out.OrphanDependents = nil + } + if in.PropagationPolicy != nil { + in, out := &in.PropagationPolicy, &out.PropagationPolicy + *out = new(DeletionPropagation) + **out = **in + } + return nil + } +} + +// DeepCopy_api_DownwardAPIProjection is an autogenerated deepcopy function. +func DeepCopy_api_DownwardAPIProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DownwardAPIProjection) + out := out.(*DownwardAPIProjection) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]DownwardAPIVolumeFile, len(*in)) + for i := range *in { + if err := DeepCopy_api_DownwardAPIVolumeFile(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } } return nil } } +// DeepCopy_api_DownwardAPIVolumeFile is an autogenerated deepcopy function. func DeepCopy_api_DownwardAPIVolumeFile(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DownwardAPIVolumeFile) out := out.(*DownwardAPIVolumeFile) - out.Path = in.Path + *out = *in if in.FieldRef != nil { in, out := &in.FieldRef, &out.FieldRef *out = new(ObjectFieldSelector) **out = **in - } else { - out.FieldRef = nil } if in.ResourceFieldRef != nil { in, out := &in.ResourceFieldRef, &out.ResourceFieldRef @@ -823,24 +820,22 @@ func DeepCopy_api_DownwardAPIVolumeFile(in interface{}, out interface{}, c *conv if err := DeepCopy_api_ResourceFieldSelector(*in, *out, c); err != nil { return err } - } else { - out.ResourceFieldRef = nil } if in.Mode != nil { in, out := &in.Mode, &out.Mode *out = new(int32) **out = **in - } else { - out.Mode = nil } return nil } } +// DeepCopy_api_DownwardAPIVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_DownwardAPIVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DownwardAPIVolumeSource) out := out.(*DownwardAPIVolumeSource) + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]DownwardAPIVolumeFile, len(*in)) @@ -849,68 +844,63 @@ func DeepCopy_api_DownwardAPIVolumeSource(in interface{}, out interface{}, c *co return err } } - } else { - out.Items = nil } if in.DefaultMode != nil { in, out := &in.DefaultMode, &out.DefaultMode *out = new(int32) **out = **in - } else { - out.DefaultMode = nil } return nil } } +// DeepCopy_api_EmptyDirVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_EmptyDirVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EmptyDirVolumeSource) out := out.(*EmptyDirVolumeSource) - out.Medium = in.Medium + *out = *in + out.SizeLimit = in.SizeLimit.DeepCopy() return nil } } +// DeepCopy_api_EndpointAddress is an autogenerated deepcopy function. func DeepCopy_api_EndpointAddress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointAddress) out := out.(*EndpointAddress) - out.IP = in.IP - out.Hostname = in.Hostname + *out = *in if in.NodeName != nil { in, out := &in.NodeName, &out.NodeName *out = new(string) **out = **in - } else { - out.NodeName = nil } if in.TargetRef != nil { in, out := &in.TargetRef, &out.TargetRef *out = new(ObjectReference) **out = **in - } else { - out.TargetRef = nil } return nil } } +// DeepCopy_api_EndpointPort is an autogenerated deepcopy function. func DeepCopy_api_EndpointPort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointPort) out := out.(*EndpointPort) - out.Name = in.Name - out.Port = in.Port - out.Protocol = in.Protocol + *out = *in return nil } } +// DeepCopy_api_EndpointSubset is an autogenerated deepcopy function. func DeepCopy_api_EndpointSubset(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointSubset) out := out.(*EndpointSubset) + *out = *in if in.Addresses != nil { in, out := &in.Addresses, &out.Addresses *out = make([]EndpointAddress, len(*in)) @@ -919,8 +909,6 @@ func DeepCopy_api_EndpointSubset(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.Addresses = nil } if in.NotReadyAddresses != nil { in, out := &in.NotReadyAddresses, &out.NotReadyAddresses @@ -930,29 +918,26 @@ func DeepCopy_api_EndpointSubset(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.NotReadyAddresses = nil } if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]EndpointPort, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ports = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_Endpoints is an autogenerated deepcopy function. func DeepCopy_api_Endpoints(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Endpoints) out := out.(*Endpoints) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Subsets != nil { in, out := &in.Subsets, &out.Subsets @@ -962,19 +947,17 @@ func DeepCopy_api_Endpoints(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Subsets = nil } return nil } } +// DeepCopy_api_EndpointsList is an autogenerated deepcopy function. func DeepCopy_api_EndpointsList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EndpointsList) out := out.(*EndpointsList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Endpoints, len(*in)) @@ -983,42 +966,62 @@ func DeepCopy_api_EndpointsList(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_EnvFromSource is an autogenerated deepcopy function. +func DeepCopy_api_EnvFromSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*EnvFromSource) + out := out.(*EnvFromSource) + *out = *in + if in.ConfigMapRef != nil { + in, out := &in.ConfigMapRef, &out.ConfigMapRef + *out = new(ConfigMapEnvSource) + if err := DeepCopy_api_ConfigMapEnvSource(*in, *out, c); err != nil { + return err + } + } + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(SecretEnvSource) + if err := DeepCopy_api_SecretEnvSource(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_api_EnvVar is an autogenerated deepcopy function. func DeepCopy_api_EnvVar(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EnvVar) out := out.(*EnvVar) - out.Name = in.Name - out.Value = in.Value + *out = *in if in.ValueFrom != nil { in, out := &in.ValueFrom, &out.ValueFrom *out = new(EnvVarSource) if err := DeepCopy_api_EnvVarSource(*in, *out, c); err != nil { return err } - } else { - out.ValueFrom = nil } return nil } } +// DeepCopy_api_EnvVarSource is an autogenerated deepcopy function. func DeepCopy_api_EnvVarSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EnvVarSource) out := out.(*EnvVarSource) + *out = *in if in.FieldRef != nil { in, out := &in.FieldRef, &out.FieldRef *out = new(ObjectFieldSelector) **out = **in - } else { - out.FieldRef = nil } if in.ResourceFieldRef != nil { in, out := &in.ResourceFieldRef, &out.ResourceFieldRef @@ -1026,53 +1029,48 @@ func DeepCopy_api_EnvVarSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_ResourceFieldSelector(*in, *out, c); err != nil { return err } - } else { - out.ResourceFieldRef = nil } if in.ConfigMapKeyRef != nil { in, out := &in.ConfigMapKeyRef, &out.ConfigMapKeyRef *out = new(ConfigMapKeySelector) - **out = **in - } else { - out.ConfigMapKeyRef = nil + if err := DeepCopy_api_ConfigMapKeySelector(*in, *out, c); err != nil { + return err + } } if in.SecretKeyRef != nil { in, out := &in.SecretKeyRef, &out.SecretKeyRef *out = new(SecretKeySelector) - **out = **in - } else { - out.SecretKeyRef = nil + if err := DeepCopy_api_SecretKeySelector(*in, *out, c); err != nil { + return err + } } return nil } } +// DeepCopy_api_Event is an autogenerated deepcopy function. func DeepCopy_api_Event(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Event) out := out.(*Event) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.InvolvedObject = in.InvolvedObject - out.Reason = in.Reason - out.Message = in.Message - out.Source = in.Source out.FirstTimestamp = in.FirstTimestamp.DeepCopy() out.LastTimestamp = in.LastTimestamp.DeepCopy() - out.Count = in.Count - out.Type = in.Type return nil } } +// DeepCopy_api_EventList is an autogenerated deepcopy function. func DeepCopy_api_EventList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EventList) out := out.(*EventList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Event, len(*in)) @@ -1081,187 +1079,155 @@ func DeepCopy_api_EventList(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_EventSource is an autogenerated deepcopy function. func DeepCopy_api_EventSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*EventSource) out := out.(*EventSource) - out.Component = in.Component - out.Host = in.Host + *out = *in return nil } } +// DeepCopy_api_ExecAction is an autogenerated deepcopy function. func DeepCopy_api_ExecAction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ExecAction) out := out.(*ExecAction) + *out = *in if in.Command != nil { in, out := &in.Command, &out.Command *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Command = nil } return nil } } -func DeepCopy_api_ExportOptions(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ExportOptions) - out := out.(*ExportOptions) - out.TypeMeta = in.TypeMeta - out.Export = in.Export - out.Exact = in.Exact - return nil - } -} - +// DeepCopy_api_FCVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_FCVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FCVolumeSource) out := out.(*FCVolumeSource) + *out = *in if in.TargetWWNs != nil { in, out := &in.TargetWWNs, &out.TargetWWNs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.TargetWWNs = nil } if in.Lun != nil { in, out := &in.Lun, &out.Lun *out = new(int32) **out = **in - } else { - out.Lun = nil } - out.FSType = in.FSType - out.ReadOnly = in.ReadOnly return nil } } +// DeepCopy_api_FlexVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_FlexVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FlexVolumeSource) out := out.(*FlexVolumeSource) - out.Driver = in.Driver - out.FSType = in.FSType + *out = *in if in.SecretRef != nil { in, out := &in.SecretRef, &out.SecretRef *out = new(LocalObjectReference) **out = **in - } else { - out.SecretRef = nil } - out.ReadOnly = in.ReadOnly if in.Options != nil { in, out := &in.Options, &out.Options *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Options = nil } return nil } } +// DeepCopy_api_FlockerVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_FlockerVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FlockerVolumeSource) out := out.(*FlockerVolumeSource) - out.DatasetName = in.DatasetName - out.DatasetUUID = in.DatasetUUID + *out = *in return nil } } +// DeepCopy_api_GCEPersistentDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_GCEPersistentDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*GCEPersistentDiskVolumeSource) out := out.(*GCEPersistentDiskVolumeSource) - out.PDName = in.PDName - out.FSType = in.FSType - out.Partition = in.Partition - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_GitRepoVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_GitRepoVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*GitRepoVolumeSource) out := out.(*GitRepoVolumeSource) - out.Repository = in.Repository - out.Revision = in.Revision - out.Directory = in.Directory + *out = *in return nil } } +// DeepCopy_api_GlusterfsVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_GlusterfsVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*GlusterfsVolumeSource) out := out.(*GlusterfsVolumeSource) - out.EndpointsName = in.EndpointsName - out.Path = in.Path - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_HTTPGetAction is an autogenerated deepcopy function. func DeepCopy_api_HTTPGetAction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPGetAction) out := out.(*HTTPGetAction) - out.Path = in.Path - out.Port = in.Port - out.Host = in.Host - out.Scheme = in.Scheme + *out = *in if in.HTTPHeaders != nil { in, out := &in.HTTPHeaders, &out.HTTPHeaders *out = make([]HTTPHeader, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.HTTPHeaders = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_HTTPHeader is an autogenerated deepcopy function. func DeepCopy_api_HTTPHeader(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPHeader) out := out.(*HTTPHeader) - out.Name = in.Name - out.Value = in.Value + *out = *in return nil } } +// DeepCopy_api_Handler is an autogenerated deepcopy function. func DeepCopy_api_Handler(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Handler) out := out.(*Handler) + *out = *in if in.Exec != nil { in, out := &in.Exec, &out.Exec *out = new(ExecAction) if err := DeepCopy_api_ExecAction(*in, *out, c); err != nil { return err } - } else { - out.Exec = nil } if in.HTTPGet != nil { in, out := &in.HTTPGet, &out.HTTPGet @@ -1269,72 +1235,88 @@ func DeepCopy_api_Handler(in interface{}, out interface{}, c *conversion.Cloner) if err := DeepCopy_api_HTTPGetAction(*in, *out, c); err != nil { return err } - } else { - out.HTTPGet = nil } if in.TCPSocket != nil { in, out := &in.TCPSocket, &out.TCPSocket *out = new(TCPSocketAction) **out = **in - } else { - out.TCPSocket = nil } return nil } } +// DeepCopy_api_HostAlias is an autogenerated deepcopy function. +func DeepCopy_api_HostAlias(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HostAlias) + out := out.(*HostAlias) + *out = *in + if in.Hostnames != nil { + in, out := &in.Hostnames, &out.Hostnames + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_api_HostPathVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_HostPathVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HostPathVolumeSource) out := out.(*HostPathVolumeSource) - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_api_ISCSIVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_ISCSIVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ISCSIVolumeSource) out := out.(*ISCSIVolumeSource) - out.TargetPortal = in.TargetPortal - out.IQN = in.IQN - out.Lun = in.Lun - out.ISCSIInterface = in.ISCSIInterface - out.FSType = in.FSType - out.ReadOnly = in.ReadOnly + *out = *in + if in.Portals != nil { + in, out := &in.Portals, &out.Portals + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(LocalObjectReference) + **out = **in + } return nil } } +// DeepCopy_api_KeyToPath is an autogenerated deepcopy function. func DeepCopy_api_KeyToPath(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*KeyToPath) out := out.(*KeyToPath) - out.Key = in.Key - out.Path = in.Path + *out = *in if in.Mode != nil { in, out := &in.Mode, &out.Mode *out = new(int32) **out = **in - } else { - out.Mode = nil } return nil } } +// DeepCopy_api_Lifecycle is an autogenerated deepcopy function. func DeepCopy_api_Lifecycle(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Lifecycle) out := out.(*Lifecycle) + *out = *in if in.PostStart != nil { in, out := &in.PostStart, &out.PostStart *out = new(Handler) if err := DeepCopy_api_Handler(*in, *out, c); err != nil { return err } - } else { - out.PostStart = nil } if in.PreStop != nil { in, out := &in.PreStop, &out.PreStop @@ -1342,20 +1324,21 @@ func DeepCopy_api_Lifecycle(in interface{}, out interface{}, c *conversion.Clone if err := DeepCopy_api_Handler(*in, *out, c); err != nil { return err } - } else { - out.PreStop = nil } return nil } } +// DeepCopy_api_LimitRange is an autogenerated deepcopy function. func DeepCopy_api_LimitRange(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRange) out := out.(*LimitRange) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_LimitRangeSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -1364,19 +1347,18 @@ func DeepCopy_api_LimitRange(in interface{}, out interface{}, c *conversion.Clon } } +// DeepCopy_api_LimitRangeItem is an autogenerated deepcopy function. func DeepCopy_api_LimitRangeItem(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRangeItem) out := out.(*LimitRangeItem) - out.Type = in.Type + *out = *in if in.Max != nil { in, out := &in.Max, &out.Max *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Max = nil } if in.Min != nil { in, out := &in.Min, &out.Min @@ -1384,8 +1366,6 @@ func DeepCopy_api_LimitRangeItem(in interface{}, out interface{}, c *conversion. for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Min = nil } if in.Default != nil { in, out := &in.Default, &out.Default @@ -1393,8 +1373,6 @@ func DeepCopy_api_LimitRangeItem(in interface{}, out interface{}, c *conversion. for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Default = nil } if in.DefaultRequest != nil { in, out := &in.DefaultRequest, &out.DefaultRequest @@ -1402,8 +1380,6 @@ func DeepCopy_api_LimitRangeItem(in interface{}, out interface{}, c *conversion. for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.DefaultRequest = nil } if in.MaxLimitRequestRatio != nil { in, out := &in.MaxLimitRequestRatio, &out.MaxLimitRequestRatio @@ -1411,19 +1387,17 @@ func DeepCopy_api_LimitRangeItem(in interface{}, out interface{}, c *conversion. for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.MaxLimitRequestRatio = nil } return nil } } +// DeepCopy_api_LimitRangeList is an autogenerated deepcopy function. func DeepCopy_api_LimitRangeList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRangeList) out := out.(*LimitRangeList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]LimitRange, len(*in)) @@ -1432,17 +1406,17 @@ func DeepCopy_api_LimitRangeList(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_LimitRangeSpec is an autogenerated deepcopy function. func DeepCopy_api_LimitRangeSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LimitRangeSpec) out := out.(*LimitRangeSpec) + *out = *in if in.Limits != nil { in, out := &in.Limits, &out.Limits *out = make([]LimitRangeItem, len(*in)) @@ -1451,19 +1425,17 @@ func DeepCopy_api_LimitRangeSpec(in interface{}, out interface{}, c *conversion. return err } } - } else { - out.Limits = nil } return nil } } +// DeepCopy_api_List is an autogenerated deepcopy function. func DeepCopy_api_List(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*List) out := out.(*List) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]runtime.Object, len(*in)) @@ -1474,114 +1446,121 @@ func DeepCopy_api_List(in interface{}, out interface{}, c *conversion.Cloner) er (*out)[i] = *newVal.(*runtime.Object) } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ListOptions is an autogenerated deepcopy function. func DeepCopy_api_ListOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ListOptions) out := out.(*ListOptions) - out.TypeMeta = in.TypeMeta - if in.LabelSelector == nil { - out.LabelSelector = nil - } else if newVal, err := c.DeepCopy(&in.LabelSelector); err != nil { - return err - } else { - out.LabelSelector = *newVal.(*labels.Selector) + *out = *in + // in.LabelSelector is kind 'Interface' + if in.LabelSelector != nil { + if newVal, err := c.DeepCopy(&in.LabelSelector); err != nil { + return err + } else { + out.LabelSelector = *newVal.(*labels.Selector) + } } - if in.FieldSelector == nil { - out.FieldSelector = nil - } else if newVal, err := c.DeepCopy(&in.FieldSelector); err != nil { - return err - } else { - out.FieldSelector = *newVal.(*fields.Selector) + // in.FieldSelector is kind 'Interface' + if in.FieldSelector != nil { + if newVal, err := c.DeepCopy(&in.FieldSelector); err != nil { + return err + } else { + out.FieldSelector = *newVal.(*fields.Selector) + } } - out.Watch = in.Watch - out.ResourceVersion = in.ResourceVersion if in.TimeoutSeconds != nil { in, out := &in.TimeoutSeconds, &out.TimeoutSeconds *out = new(int64) **out = **in - } else { - out.TimeoutSeconds = nil } return nil } } +// DeepCopy_api_LoadBalancerIngress is an autogenerated deepcopy function. func DeepCopy_api_LoadBalancerIngress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LoadBalancerIngress) out := out.(*LoadBalancerIngress) - out.IP = in.IP - out.Hostname = in.Hostname + *out = *in return nil } } +// DeepCopy_api_LoadBalancerStatus is an autogenerated deepcopy function. func DeepCopy_api_LoadBalancerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LoadBalancerStatus) out := out.(*LoadBalancerStatus) + *out = *in if in.Ingress != nil { in, out := &in.Ingress, &out.Ingress *out = make([]LoadBalancerIngress, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ingress = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_LocalObjectReference is an autogenerated deepcopy function. func DeepCopy_api_LocalObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LocalObjectReference) out := out.(*LocalObjectReference) - out.Name = in.Name + *out = *in + return nil + } +} + +// DeepCopy_api_LocalVolumeSource is an autogenerated deepcopy function. +func DeepCopy_api_LocalVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*LocalVolumeSource) + out := out.(*LocalVolumeSource) + *out = *in return nil } } +// DeepCopy_api_NFSVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_NFSVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NFSVolumeSource) out := out.(*NFSVolumeSource) - out.Server = in.Server - out.Path = in.Path - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_Namespace is an autogenerated deepcopy function. func DeepCopy_api_Namespace(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Namespace) out := out.(*Namespace) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_NamespaceSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_api_NamespaceList is an autogenerated deepcopy function. func DeepCopy_api_NamespaceList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NamespaceList) out := out.(*NamespaceList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Namespace, len(*in)) @@ -1590,48 +1569,50 @@ func DeepCopy_api_NamespaceList(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_NamespaceSpec is an autogenerated deepcopy function. func DeepCopy_api_NamespaceSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NamespaceSpec) out := out.(*NamespaceSpec) + *out = *in if in.Finalizers != nil { in, out := &in.Finalizers, &out.Finalizers *out = make([]FinalizerName, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Finalizers = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_NamespaceStatus is an autogenerated deepcopy function. func DeepCopy_api_NamespaceStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NamespaceStatus) out := out.(*NamespaceStatus) - out.Phase = in.Phase + *out = *in return nil } } +// DeepCopy_api_Node is an autogenerated deepcopy function. func DeepCopy_api_Node(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Node) out := out.(*Node) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_api_NodeSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Spec = in.Spec if err := DeepCopy_api_NodeStatus(&in.Status, &out.Status, c); err != nil { return err } @@ -1639,28 +1620,28 @@ func DeepCopy_api_Node(in interface{}, out interface{}, c *conversion.Cloner) er } } +// DeepCopy_api_NodeAddress is an autogenerated deepcopy function. func DeepCopy_api_NodeAddress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeAddress) out := out.(*NodeAddress) - out.Type = in.Type - out.Address = in.Address + *out = *in return nil } } +// DeepCopy_api_NodeAffinity is an autogenerated deepcopy function. func DeepCopy_api_NodeAffinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeAffinity) out := out.(*NodeAffinity) + *out = *in if in.RequiredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution *out = new(NodeSelector) if err := DeepCopy_api_NodeSelector(*in, *out, c); err != nil { return err } - } else { - out.RequiredDuringSchedulingIgnoredDuringExecution = nil } if in.PreferredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution @@ -1670,42 +1651,39 @@ func DeepCopy_api_NodeAffinity(in interface{}, out interface{}, c *conversion.Cl return err } } - } else { - out.PreferredDuringSchedulingIgnoredDuringExecution = nil } return nil } } +// DeepCopy_api_NodeCondition is an autogenerated deepcopy function. func DeepCopy_api_NodeCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeCondition) out := out.(*NodeCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastHeartbeatTime = in.LastHeartbeatTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_api_NodeDaemonEndpoints is an autogenerated deepcopy function. func DeepCopy_api_NodeDaemonEndpoints(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeDaemonEndpoints) out := out.(*NodeDaemonEndpoints) - out.KubeletEndpoint = in.KubeletEndpoint + *out = *in return nil } } +// DeepCopy_api_NodeList is an autogenerated deepcopy function. func DeepCopy_api_NodeList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeList) out := out.(*NodeList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Node, len(*in)) @@ -1714,44 +1692,44 @@ func DeepCopy_api_NodeList(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_NodeProxyOptions is an autogenerated deepcopy function. func DeepCopy_api_NodeProxyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeProxyOptions) out := out.(*NodeProxyOptions) - out.TypeMeta = in.TypeMeta - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_api_NodeResources is an autogenerated deepcopy function. func DeepCopy_api_NodeResources(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeResources) out := out.(*NodeResources) + *out = *in if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } return nil } } +// DeepCopy_api_NodeSelector is an autogenerated deepcopy function. func DeepCopy_api_NodeSelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSelector) out := out.(*NodeSelector) + *out = *in if in.NodeSelectorTerms != nil { in, out := &in.NodeSelectorTerms, &out.NodeSelectorTerms *out = make([]NodeSelectorTerm, len(*in)) @@ -1760,34 +1738,32 @@ func DeepCopy_api_NodeSelector(in interface{}, out interface{}, c *conversion.Cl return err } } - } else { - out.NodeSelectorTerms = nil } return nil } } +// DeepCopy_api_NodeSelectorRequirement is an autogenerated deepcopy function. func DeepCopy_api_NodeSelectorRequirement(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSelectorRequirement) out := out.(*NodeSelectorRequirement) - out.Key = in.Key - out.Operator = in.Operator + *out = *in if in.Values != nil { in, out := &in.Values, &out.Values *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Values = nil } return nil } } +// DeepCopy_api_NodeSelectorTerm is an autogenerated deepcopy function. func DeepCopy_api_NodeSelectorTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSelectorTerm) out := out.(*NodeSelectorTerm) + *out = *in if in.MatchExpressions != nil { in, out := &in.MatchExpressions, &out.MatchExpressions *out = make([]NodeSelectorRequirement, len(*in)) @@ -1796,37 +1772,42 @@ func DeepCopy_api_NodeSelectorTerm(in interface{}, out interface{}, c *conversio return err } } - } else { - out.MatchExpressions = nil } return nil } } +// DeepCopy_api_NodeSpec is an autogenerated deepcopy function. func DeepCopy_api_NodeSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSpec) out := out.(*NodeSpec) - out.PodCIDR = in.PodCIDR - out.ExternalID = in.ExternalID - out.ProviderID = in.ProviderID - out.Unschedulable = in.Unschedulable + *out = *in + if in.Taints != nil { + in, out := &in.Taints, &out.Taints + *out = make([]Taint, len(*in)) + for i := range *in { + if err := DeepCopy_api_Taint(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } return nil } } +// DeepCopy_api_NodeStatus is an autogenerated deepcopy function. func DeepCopy_api_NodeStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeStatus) out := out.(*NodeStatus) + *out = *in if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } if in.Allocatable != nil { in, out := &in.Allocatable, &out.Allocatable @@ -1834,10 +1815,7 @@ func DeepCopy_api_NodeStatus(in interface{}, out interface{}, c *conversion.Clon for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Allocatable = nil } - out.Phase = in.Phase if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]NodeCondition, len(*in)) @@ -1846,20 +1824,12 @@ func DeepCopy_api_NodeStatus(in interface{}, out interface{}, c *conversion.Clon return err } } - } else { - out.Conditions = nil } if in.Addresses != nil { in, out := &in.Addresses, &out.Addresses *out = make([]NodeAddress, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Addresses = nil + copy(*out, *in) } - out.DaemonEndpoints = in.DaemonEndpoints - out.NodeInfo = in.NodeInfo if in.Images != nil { in, out := &in.Images, &out.Images *out = make([]ContainerImage, len(*in)) @@ -1868,84 +1838,57 @@ func DeepCopy_api_NodeStatus(in interface{}, out interface{}, c *conversion.Clon return err } } - } else { - out.Images = nil } if in.VolumesInUse != nil { in, out := &in.VolumesInUse, &out.VolumesInUse *out = make([]UniqueVolumeName, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.VolumesInUse = nil + copy(*out, *in) } if in.VolumesAttached != nil { in, out := &in.VolumesAttached, &out.VolumesAttached *out = make([]AttachedVolume, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.VolumesAttached = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_NodeSystemInfo is an autogenerated deepcopy function. func DeepCopy_api_NodeSystemInfo(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NodeSystemInfo) out := out.(*NodeSystemInfo) - out.MachineID = in.MachineID - out.SystemUUID = in.SystemUUID - out.BootID = in.BootID - out.KernelVersion = in.KernelVersion - out.OSImage = in.OSImage - out.ContainerRuntimeVersion = in.ContainerRuntimeVersion - out.KubeletVersion = in.KubeletVersion - out.KubeProxyVersion = in.KubeProxyVersion - out.OperatingSystem = in.OperatingSystem - out.Architecture = in.Architecture + *out = *in return nil } } +// DeepCopy_api_ObjectFieldSelector is an autogenerated deepcopy function. func DeepCopy_api_ObjectFieldSelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ObjectFieldSelector) out := out.(*ObjectFieldSelector) - out.APIVersion = in.APIVersion - out.FieldPath = in.FieldPath + *out = *in return nil } } +// DeepCopy_api_ObjectMeta is an autogenerated deepcopy function. func DeepCopy_api_ObjectMeta(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ObjectMeta) out := out.(*ObjectMeta) - out.Name = in.Name - out.GenerateName = in.GenerateName - out.Namespace = in.Namespace - out.SelfLink = in.SelfLink - out.UID = in.UID - out.ResourceVersion = in.ResourceVersion - out.Generation = in.Generation + *out = *in out.CreationTimestamp = in.CreationTimestamp.DeepCopy() if in.DeletionTimestamp != nil { in, out := &in.DeletionTimestamp, &out.DeletionTimestamp - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.DeletionTimestamp = nil } if in.DeletionGracePeriodSeconds != nil { in, out := &in.DeletionGracePeriodSeconds, &out.DeletionGracePeriodSeconds *out = new(int64) **out = **in - } else { - out.DeletionGracePeriodSeconds = nil } if in.Labels != nil { in, out := &in.Labels, &out.Labels @@ -1953,8 +1896,6 @@ func DeepCopy_api_ObjectMeta(in interface{}, out interface{}, c *conversion.Clon for key, val := range *in { (*out)[key] = val } - } else { - out.Labels = nil } if in.Annotations != nil { in, out := &in.Annotations, &out.Annotations @@ -1962,89 +1903,73 @@ func DeepCopy_api_ObjectMeta(in interface{}, out interface{}, c *conversion.Clon for key, val := range *in { (*out)[key] = val } - } else { - out.Annotations = nil } if in.OwnerReferences != nil { in, out := &in.OwnerReferences, &out.OwnerReferences - *out = make([]OwnerReference, len(*in)) + *out = make([]v1.OwnerReference, len(*in)) for i := range *in { - if err := DeepCopy_api_OwnerReference(&(*in)[i], &(*out)[i], c); err != nil { + if newVal, err := c.DeepCopy(&(*in)[i]); err != nil { return err + } else { + (*out)[i] = *newVal.(*v1.OwnerReference) } } - } else { - out.OwnerReferences = nil + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.Initializers) + } } if in.Finalizers != nil { in, out := &in.Finalizers, &out.Finalizers *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Finalizers = nil } - out.ClusterName = in.ClusterName return nil } } +// DeepCopy_api_ObjectReference is an autogenerated deepcopy function. func DeepCopy_api_ObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ObjectReference) out := out.(*ObjectReference) - out.Kind = in.Kind - out.Namespace = in.Namespace - out.Name = in.Name - out.UID = in.UID - out.APIVersion = in.APIVersion - out.ResourceVersion = in.ResourceVersion - out.FieldPath = in.FieldPath - return nil - } -} - -func DeepCopy_api_OwnerReference(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*OwnerReference) - out := out.(*OwnerReference) - out.APIVersion = in.APIVersion - out.Kind = in.Kind - out.Name = in.Name - out.UID = in.UID - if in.Controller != nil { - in, out := &in.Controller, &out.Controller - *out = new(bool) - **out = **in - } else { - out.Controller = nil - } + *out = *in return nil } } +// DeepCopy_api_PersistentVolume is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolume(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolume) out := out.(*PersistentVolume) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_PersistentVolumeSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_api_PersistentVolumeClaim is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeClaim(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaim) out := out.(*PersistentVolumeClaim) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_PersistentVolumeClaimSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2056,12 +1981,12 @@ func DeepCopy_api_PersistentVolumeClaim(in interface{}, out interface{}, c *conv } } +// DeepCopy_api_PersistentVolumeClaimList is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeClaimList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimList) out := out.(*PersistentVolumeClaimList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PersistentVolumeClaim, len(*in)) @@ -2070,56 +1995,52 @@ func DeepCopy_api_PersistentVolumeClaimList(in interface{}, out interface{}, c * return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_PersistentVolumeClaimSpec is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeClaimSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimSpec) out := out.(*PersistentVolumeClaimSpec) + *out = *in if in.AccessModes != nil { in, out := &in.AccessModes, &out.AccessModes *out = make([]PersistentVolumeAccessMode, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AccessModes = nil + copy(*out, *in) } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } if err := DeepCopy_api_ResourceRequirements(&in.Resources, &out.Resources, c); err != nil { return err } - out.VolumeName = in.VolumeName + if in.StorageClassName != nil { + in, out := &in.StorageClassName, &out.StorageClassName + *out = new(string) + **out = **in + } return nil } } +// DeepCopy_api_PersistentVolumeClaimStatus is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeClaimStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimStatus) out := out.(*PersistentVolumeClaimStatus) - out.Phase = in.Phase + *out = *in if in.AccessModes != nil { in, out := &in.AccessModes, &out.AccessModes *out = make([]PersistentVolumeAccessMode, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AccessModes = nil + copy(*out, *in) } if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity @@ -2127,29 +2048,27 @@ func DeepCopy_api_PersistentVolumeClaimStatus(in interface{}, out interface{}, c for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } return nil } } +// DeepCopy_api_PersistentVolumeClaimVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeClaimVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeClaimVolumeSource) out := out.(*PersistentVolumeClaimVolumeSource) - out.ClaimName = in.ClaimName - out.ReadOnly = in.ReadOnly + *out = *in return nil } } +// DeepCopy_api_PersistentVolumeList is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeList) out := out.(*PersistentVolumeList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PersistentVolume, len(*in)) @@ -2158,51 +2077,41 @@ func DeepCopy_api_PersistentVolumeList(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_PersistentVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeSource) out := out.(*PersistentVolumeSource) + *out = *in if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk *out = new(GCEPersistentDiskVolumeSource) **out = **in - } else { - out.GCEPersistentDisk = nil } if in.AWSElasticBlockStore != nil { in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore *out = new(AWSElasticBlockStoreVolumeSource) **out = **in - } else { - out.AWSElasticBlockStore = nil } if in.HostPath != nil { in, out := &in.HostPath, &out.HostPath *out = new(HostPathVolumeSource) **out = **in - } else { - out.HostPath = nil } if in.Glusterfs != nil { in, out := &in.Glusterfs, &out.Glusterfs *out = new(GlusterfsVolumeSource) **out = **in - } else { - out.Glusterfs = nil } if in.NFS != nil { in, out := &in.NFS, &out.NFS *out = new(NFSVolumeSource) **out = **in - } else { - out.NFS = nil } if in.RBD != nil { in, out := &in.RBD, &out.RBD @@ -2210,22 +2119,18 @@ func DeepCopy_api_PersistentVolumeSource(in interface{}, out interface{}, c *con if err := DeepCopy_api_RBDVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.RBD = nil } if in.Quobyte != nil { in, out := &in.Quobyte, &out.Quobyte *out = new(QuobyteVolumeSource) **out = **in - } else { - out.Quobyte = nil } if in.ISCSI != nil { in, out := &in.ISCSI, &out.ISCSI *out = new(ISCSIVolumeSource) - **out = **in - } else { - out.ISCSI = nil + if err := DeepCopy_api_ISCSIVolumeSource(*in, *out, c); err != nil { + return err + } } if in.FlexVolume != nil { in, out := &in.FlexVolume, &out.FlexVolume @@ -2233,15 +2138,11 @@ func DeepCopy_api_PersistentVolumeSource(in interface{}, out interface{}, c *con if err := DeepCopy_api_FlexVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FlexVolume = nil } if in.Cinder != nil { in, out := &in.Cinder, &out.Cinder *out = new(CinderVolumeSource) **out = **in - } else { - out.Cinder = nil } if in.CephFS != nil { in, out := &in.CephFS, &out.CephFS @@ -2249,8 +2150,6 @@ func DeepCopy_api_PersistentVolumeSource(in interface{}, out interface{}, c *con if err := DeepCopy_api_CephFSVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.CephFS = nil } if in.FC != nil { in, out := &in.FC, &out.FC @@ -2258,29 +2157,21 @@ func DeepCopy_api_PersistentVolumeSource(in interface{}, out interface{}, c *con if err := DeepCopy_api_FCVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FC = nil } if in.Flocker != nil { in, out := &in.Flocker, &out.Flocker *out = new(FlockerVolumeSource) **out = **in - } else { - out.Flocker = nil } if in.AzureFile != nil { in, out := &in.AzureFile, &out.AzureFile *out = new(AzureFileVolumeSource) **out = **in - } else { - out.AzureFile = nil } if in.VsphereVolume != nil { in, out := &in.VsphereVolume, &out.VsphereVolume *out = new(VsphereVirtualDiskVolumeSource) **out = **in - } else { - out.VsphereVolume = nil } if in.AzureDisk != nil { in, out := &in.AzureDisk, &out.AzureDisk @@ -2288,32 +2179,52 @@ func DeepCopy_api_PersistentVolumeSource(in interface{}, out interface{}, c *con if err := DeepCopy_api_AzureDiskVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.AzureDisk = nil } if in.PhotonPersistentDisk != nil { in, out := &in.PhotonPersistentDisk, &out.PhotonPersistentDisk *out = new(PhotonPersistentDiskVolumeSource) **out = **in - } else { - out.PhotonPersistentDisk = nil + } + if in.PortworxVolume != nil { + in, out := &in.PortworxVolume, &out.PortworxVolume + *out = new(PortworxVolumeSource) + **out = **in + } + if in.ScaleIO != nil { + in, out := &in.ScaleIO, &out.ScaleIO + *out = new(ScaleIOVolumeSource) + if err := DeepCopy_api_ScaleIOVolumeSource(*in, *out, c); err != nil { + return err + } + } + if in.Local != nil { + in, out := &in.Local, &out.Local + *out = new(LocalVolumeSource) + **out = **in + } + if in.StorageOS != nil { + in, out := &in.StorageOS, &out.StorageOS + *out = new(StorageOSPersistentVolumeSource) + if err := DeepCopy_api_StorageOSPersistentVolumeSource(*in, *out, c); err != nil { + return err + } } return nil } } +// DeepCopy_api_PersistentVolumeSpec is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeSpec) out := out.(*PersistentVolumeSpec) + *out = *in if in.Capacity != nil { in, out := &in.Capacity, &out.Capacity *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Capacity = nil } if err := DeepCopy_api_PersistentVolumeSource(&in.PersistentVolumeSource, &out.PersistentVolumeSource, c); err != nil { return err @@ -2321,52 +2232,47 @@ func DeepCopy_api_PersistentVolumeSpec(in interface{}, out interface{}, c *conve if in.AccessModes != nil { in, out := &in.AccessModes, &out.AccessModes *out = make([]PersistentVolumeAccessMode, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AccessModes = nil + copy(*out, *in) } if in.ClaimRef != nil { in, out := &in.ClaimRef, &out.ClaimRef *out = new(ObjectReference) **out = **in - } else { - out.ClaimRef = nil } - out.PersistentVolumeReclaimPolicy = in.PersistentVolumeReclaimPolicy return nil } } +// DeepCopy_api_PersistentVolumeStatus is an autogenerated deepcopy function. func DeepCopy_api_PersistentVolumeStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PersistentVolumeStatus) out := out.(*PersistentVolumeStatus) - out.Phase = in.Phase - out.Message = in.Message - out.Reason = in.Reason + *out = *in return nil } } +// DeepCopy_api_PhotonPersistentDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_PhotonPersistentDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PhotonPersistentDiskVolumeSource) out := out.(*PhotonPersistentDiskVolumeSource) - out.PdID = in.PdID - out.FSType = in.FSType + *out = *in return nil } } +// DeepCopy_api_Pod is an autogenerated deepcopy function. func DeepCopy_api_Pod(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Pod) out := out.(*Pod) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_PodSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2378,10 +2284,12 @@ func DeepCopy_api_Pod(in interface{}, out interface{}, c *conversion.Cloner) err } } +// DeepCopy_api_PodAffinity is an autogenerated deepcopy function. func DeepCopy_api_PodAffinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAffinity) out := out.(*PodAffinity) + *out = *in if in.RequiredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution *out = make([]PodAffinityTerm, len(*in)) @@ -2390,8 +2298,6 @@ func DeepCopy_api_PodAffinity(in interface{}, out interface{}, c *conversion.Clo return err } } - } else { - out.RequiredDuringSchedulingIgnoredDuringExecution = nil } if in.PreferredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution @@ -2401,42 +2307,40 @@ func DeepCopy_api_PodAffinity(in interface{}, out interface{}, c *conversion.Clo return err } } - } else { - out.PreferredDuringSchedulingIgnoredDuringExecution = nil } return nil } } +// DeepCopy_api_PodAffinityTerm is an autogenerated deepcopy function. func DeepCopy_api_PodAffinityTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAffinityTerm) out := out.(*PodAffinityTerm) + *out = *in if in.LabelSelector != nil { in, out := &in.LabelSelector, &out.LabelSelector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.LabelSelector = nil } if in.Namespaces != nil { in, out := &in.Namespaces, &out.Namespaces *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Namespaces = nil } - out.TopologyKey = in.TopologyKey return nil } } +// DeepCopy_api_PodAntiAffinity is an autogenerated deepcopy function. func DeepCopy_api_PodAntiAffinity(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAntiAffinity) out := out.(*PodAntiAffinity) + *out = *in if in.RequiredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.RequiredDuringSchedulingIgnoredDuringExecution, &out.RequiredDuringSchedulingIgnoredDuringExecution *out = make([]PodAffinityTerm, len(*in)) @@ -2445,8 +2349,6 @@ func DeepCopy_api_PodAntiAffinity(in interface{}, out interface{}, c *conversion return err } } - } else { - out.RequiredDuringSchedulingIgnoredDuringExecution = nil } if in.PreferredDuringSchedulingIgnoredDuringExecution != nil { in, out := &in.PreferredDuringSchedulingIgnoredDuringExecution, &out.PreferredDuringSchedulingIgnoredDuringExecution @@ -2456,68 +2358,54 @@ func DeepCopy_api_PodAntiAffinity(in interface{}, out interface{}, c *conversion return err } } - } else { - out.PreferredDuringSchedulingIgnoredDuringExecution = nil } return nil } } +// DeepCopy_api_PodAttachOptions is an autogenerated deepcopy function. func DeepCopy_api_PodAttachOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodAttachOptions) out := out.(*PodAttachOptions) - out.TypeMeta = in.TypeMeta - out.Stdin = in.Stdin - out.Stdout = in.Stdout - out.Stderr = in.Stderr - out.TTY = in.TTY - out.Container = in.Container + *out = *in return nil } } +// DeepCopy_api_PodCondition is an autogenerated deepcopy function. func DeepCopy_api_PodCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodCondition) out := out.(*PodCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastProbeTime = in.LastProbeTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_api_PodExecOptions is an autogenerated deepcopy function. func DeepCopy_api_PodExecOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodExecOptions) out := out.(*PodExecOptions) - out.TypeMeta = in.TypeMeta - out.Stdin = in.Stdin - out.Stdout = in.Stdout - out.Stderr = in.Stderr - out.TTY = in.TTY - out.Container = in.Container + *out = *in if in.Command != nil { in, out := &in.Command, &out.Command *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Command = nil } return nil } } +// DeepCopy_api_PodList is an autogenerated deepcopy function. func DeepCopy_api_PodList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodList) out := out.(*PodList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Pod, len(*in)) @@ -2526,131 +2414,125 @@ func DeepCopy_api_PodList(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_PodLogOptions is an autogenerated deepcopy function. func DeepCopy_api_PodLogOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodLogOptions) out := out.(*PodLogOptions) - out.TypeMeta = in.TypeMeta - out.Container = in.Container - out.Follow = in.Follow - out.Previous = in.Previous + *out = *in if in.SinceSeconds != nil { in, out := &in.SinceSeconds, &out.SinceSeconds *out = new(int64) **out = **in - } else { - out.SinceSeconds = nil } if in.SinceTime != nil { in, out := &in.SinceTime, &out.SinceTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.SinceTime = nil } - out.Timestamps = in.Timestamps if in.TailLines != nil { in, out := &in.TailLines, &out.TailLines *out = new(int64) **out = **in - } else { - out.TailLines = nil } if in.LimitBytes != nil { in, out := &in.LimitBytes, &out.LimitBytes *out = new(int64) **out = **in - } else { - out.LimitBytes = nil } return nil } } +// DeepCopy_api_PodPortForwardOptions is an autogenerated deepcopy function. +func DeepCopy_api_PodPortForwardOptions(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPortForwardOptions) + out := out.(*PodPortForwardOptions) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]int32, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_api_PodProxyOptions is an autogenerated deepcopy function. func DeepCopy_api_PodProxyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodProxyOptions) out := out.(*PodProxyOptions) - out.TypeMeta = in.TypeMeta - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_api_PodSecurityContext is an autogenerated deepcopy function. func DeepCopy_api_PodSecurityContext(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityContext) out := out.(*PodSecurityContext) - out.HostNetwork = in.HostNetwork - out.HostPID = in.HostPID - out.HostIPC = in.HostIPC + *out = *in if in.SELinuxOptions != nil { in, out := &in.SELinuxOptions, &out.SELinuxOptions *out = new(SELinuxOptions) **out = **in - } else { - out.SELinuxOptions = nil } if in.RunAsUser != nil { in, out := &in.RunAsUser, &out.RunAsUser *out = new(int64) **out = **in - } else { - out.RunAsUser = nil } if in.RunAsNonRoot != nil { in, out := &in.RunAsNonRoot, &out.RunAsNonRoot *out = new(bool) **out = **in - } else { - out.RunAsNonRoot = nil } if in.SupplementalGroups != nil { in, out := &in.SupplementalGroups, &out.SupplementalGroups *out = make([]int64, len(*in)) copy(*out, *in) - } else { - out.SupplementalGroups = nil } if in.FSGroup != nil { in, out := &in.FSGroup, &out.FSGroup *out = new(int64) **out = **in - } else { - out.FSGroup = nil } return nil } } +// DeepCopy_api_PodSignature is an autogenerated deepcopy function. func DeepCopy_api_PodSignature(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSignature) out := out.(*PodSignature) + *out = *in if in.PodController != nil { in, out := &in.PodController, &out.PodController - *out = new(OwnerReference) - if err := DeepCopy_api_OwnerReference(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.OwnerReference) } - } else { - out.PodController = nil } return nil } } +// DeepCopy_api_PodSpec is an autogenerated deepcopy function. func DeepCopy_api_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSpec) out := out.(*PodSpec) + *out = *in if in.Volumes != nil { in, out := &in.Volumes, &out.Volumes *out = make([]Volume, len(*in)) @@ -2659,8 +2541,6 @@ func DeepCopy_api_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Volumes = nil } if in.InitContainers != nil { in, out := &in.InitContainers, &out.InitContainers @@ -2670,8 +2550,6 @@ func DeepCopy_api_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.InitContainers = nil } if in.Containers != nil { in, out := &in.Containers, &out.Containers @@ -2681,65 +2559,76 @@ func DeepCopy_api_PodSpec(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Containers = nil } - out.RestartPolicy = in.RestartPolicy if in.TerminationGracePeriodSeconds != nil { in, out := &in.TerminationGracePeriodSeconds, &out.TerminationGracePeriodSeconds *out = new(int64) **out = **in - } else { - out.TerminationGracePeriodSeconds = nil } if in.ActiveDeadlineSeconds != nil { in, out := &in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds *out = new(int64) **out = **in - } else { - out.ActiveDeadlineSeconds = nil } - out.DNSPolicy = in.DNSPolicy if in.NodeSelector != nil { in, out := &in.NodeSelector, &out.NodeSelector *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.NodeSelector = nil } - out.ServiceAccountName = in.ServiceAccountName - out.NodeName = in.NodeName + if in.AutomountServiceAccountToken != nil { + in, out := &in.AutomountServiceAccountToken, &out.AutomountServiceAccountToken + *out = new(bool) + **out = **in + } if in.SecurityContext != nil { in, out := &in.SecurityContext, &out.SecurityContext *out = new(PodSecurityContext) if err := DeepCopy_api_PodSecurityContext(*in, *out, c); err != nil { return err } - } else { - out.SecurityContext = nil } if in.ImagePullSecrets != nil { in, out := &in.ImagePullSecrets, &out.ImagePullSecrets *out = make([]LocalObjectReference, len(*in)) + copy(*out, *in) + } + if in.Affinity != nil { + in, out := &in.Affinity, &out.Affinity + *out = new(Affinity) + if err := DeepCopy_api_Affinity(*in, *out, c); err != nil { + return err + } + } + if in.Tolerations != nil { + in, out := &in.Tolerations, &out.Tolerations + *out = make([]Toleration, len(*in)) for i := range *in { - (*out)[i] = (*in)[i] + if err := DeepCopy_api_Toleration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.HostAliases != nil { + in, out := &in.HostAliases, &out.HostAliases + *out = make([]HostAlias, len(*in)) + for i := range *in { + if err := DeepCopy_api_HostAlias(&(*in)[i], &(*out)[i], c); err != nil { + return err + } } - } else { - out.ImagePullSecrets = nil } - out.Hostname = in.Hostname - out.Subdomain = in.Subdomain return nil } } +// DeepCopy_api_PodStatus is an autogenerated deepcopy function. func DeepCopy_api_PodStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodStatus) out := out.(*PodStatus) - out.Phase = in.Phase + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]PodCondition, len(*in)) @@ -2748,19 +2637,11 @@ func DeepCopy_api_PodStatus(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Conditions = nil } - out.Message = in.Message - out.Reason = in.Reason - out.HostIP = in.HostIP - out.PodIP = in.PodIP if in.StartTime != nil { in, out := &in.StartTime, &out.StartTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.StartTime = nil } if in.InitContainerStatuses != nil { in, out := &in.InitContainerStatuses, &out.InitContainerStatuses @@ -2770,8 +2651,6 @@ func DeepCopy_api_PodStatus(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.InitContainerStatuses = nil } if in.ContainerStatuses != nil { in, out := &in.ContainerStatuses, &out.ContainerStatuses @@ -2781,20 +2660,21 @@ func DeepCopy_api_PodStatus(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.ContainerStatuses = nil } return nil } } +// DeepCopy_api_PodStatusResult is an autogenerated deepcopy function. func DeepCopy_api_PodStatusResult(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodStatusResult) out := out.(*PodStatusResult) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_PodStatus(&in.Status, &out.Status, c); err != nil { return err @@ -2803,13 +2683,16 @@ func DeepCopy_api_PodStatusResult(in interface{}, out interface{}, c *conversion } } +// DeepCopy_api_PodTemplate is an autogenerated deepcopy function. func DeepCopy_api_PodTemplate(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodTemplate) out := out.(*PodTemplate) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -2818,12 +2701,12 @@ func DeepCopy_api_PodTemplate(in interface{}, out interface{}, c *conversion.Clo } } +// DeepCopy_api_PodTemplateList is an autogenerated deepcopy function. func DeepCopy_api_PodTemplateList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodTemplateList) out := out.(*PodTemplateList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PodTemplate, len(*in)) @@ -2832,19 +2715,21 @@ func DeepCopy_api_PodTemplateList(in interface{}, out interface{}, c *conversion return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_PodTemplateSpec is an autogenerated deepcopy function. func DeepCopy_api_PodTemplateSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodTemplateSpec) out := out.(*PodTemplateSpec) - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_PodSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2853,40 +2738,51 @@ func DeepCopy_api_PodTemplateSpec(in interface{}, out interface{}, c *conversion } } +// DeepCopy_api_PortworxVolumeSource is an autogenerated deepcopy function. +func DeepCopy_api_PortworxVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PortworxVolumeSource) + out := out.(*PortworxVolumeSource) + *out = *in + return nil + } +} + +// DeepCopy_api_Preconditions is an autogenerated deepcopy function. func DeepCopy_api_Preconditions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Preconditions) out := out.(*Preconditions) + *out = *in if in.UID != nil { in, out := &in.UID, &out.UID *out = new(types.UID) **out = **in - } else { - out.UID = nil } return nil } } +// DeepCopy_api_PreferAvoidPodsEntry is an autogenerated deepcopy function. func DeepCopy_api_PreferAvoidPodsEntry(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PreferAvoidPodsEntry) out := out.(*PreferAvoidPodsEntry) + *out = *in if err := DeepCopy_api_PodSignature(&in.PodSignature, &out.PodSignature, c); err != nil { return err } out.EvictionTime = in.EvictionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_api_PreferredSchedulingTerm is an autogenerated deepcopy function. func DeepCopy_api_PreferredSchedulingTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PreferredSchedulingTerm) out := out.(*PreferredSchedulingTerm) - out.Weight = in.Weight + *out = *in if err := DeepCopy_api_NodeSelectorTerm(&in.Preference, &out.Preference, c); err != nil { return err } @@ -2894,90 +2790,103 @@ func DeepCopy_api_PreferredSchedulingTerm(in interface{}, out interface{}, c *co } } +// DeepCopy_api_Probe is an autogenerated deepcopy function. func DeepCopy_api_Probe(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Probe) out := out.(*Probe) + *out = *in if err := DeepCopy_api_Handler(&in.Handler, &out.Handler, c); err != nil { return err } - out.InitialDelaySeconds = in.InitialDelaySeconds - out.TimeoutSeconds = in.TimeoutSeconds - out.PeriodSeconds = in.PeriodSeconds - out.SuccessThreshold = in.SuccessThreshold - out.FailureThreshold = in.FailureThreshold return nil } } +// DeepCopy_api_ProjectedVolumeSource is an autogenerated deepcopy function. +func DeepCopy_api_ProjectedVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ProjectedVolumeSource) + out := out.(*ProjectedVolumeSource) + *out = *in + if in.Sources != nil { + in, out := &in.Sources, &out.Sources + *out = make([]VolumeProjection, len(*in)) + for i := range *in { + if err := DeepCopy_api_VolumeProjection(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.DefaultMode != nil { + in, out := &in.DefaultMode, &out.DefaultMode + *out = new(int32) + **out = **in + } + return nil + } +} + +// DeepCopy_api_QuobyteVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_QuobyteVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*QuobyteVolumeSource) out := out.(*QuobyteVolumeSource) - out.Registry = in.Registry - out.Volume = in.Volume - out.ReadOnly = in.ReadOnly - out.User = in.User - out.Group = in.Group + *out = *in return nil } } +// DeepCopy_api_RBDVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_RBDVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RBDVolumeSource) out := out.(*RBDVolumeSource) + *out = *in if in.CephMonitors != nil { in, out := &in.CephMonitors, &out.CephMonitors *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.CephMonitors = nil } - out.RBDImage = in.RBDImage - out.FSType = in.FSType - out.RBDPool = in.RBDPool - out.RadosUser = in.RadosUser - out.Keyring = in.Keyring if in.SecretRef != nil { in, out := &in.SecretRef, &out.SecretRef *out = new(LocalObjectReference) **out = **in - } else { - out.SecretRef = nil } - out.ReadOnly = in.ReadOnly return nil } } +// DeepCopy_api_RangeAllocation is an autogenerated deepcopy function. func DeepCopy_api_RangeAllocation(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RangeAllocation) out := out.(*RangeAllocation) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Range = in.Range if in.Data != nil { in, out := &in.Data, &out.Data *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Data = nil } return nil } } +// DeepCopy_api_ReplicationController is an autogenerated deepcopy function. func DeepCopy_api_ReplicationController(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationController) out := out.(*ReplicationController) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_ReplicationControllerSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -2989,25 +2898,23 @@ func DeepCopy_api_ReplicationController(in interface{}, out interface{}, c *conv } } +// DeepCopy_api_ReplicationControllerCondition is an autogenerated deepcopy function. func DeepCopy_api_ReplicationControllerCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerCondition) out := out.(*ReplicationControllerCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_api_ReplicationControllerList is an autogenerated deepcopy function. func DeepCopy_api_ReplicationControllerList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerList) out := out.(*ReplicationControllerList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ReplicationController, len(*in)) @@ -3016,27 +2923,23 @@ func DeepCopy_api_ReplicationControllerList(in interface{}, out interface{}, c * return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ReplicationControllerSpec is an autogenerated deepcopy function. func DeepCopy_api_ReplicationControllerSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerSpec) out := out.(*ReplicationControllerSpec) - out.Replicas = in.Replicas - out.MinReadySeconds = in.MinReadySeconds + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Selector = nil } if in.Template != nil { in, out := &in.Template, &out.Template @@ -3044,22 +2947,17 @@ func DeepCopy_api_ReplicationControllerSpec(in interface{}, out interface{}, c * if err := DeepCopy_api_PodTemplateSpec(*in, *out, c); err != nil { return err } - } else { - out.Template = nil } return nil } } +// DeepCopy_api_ReplicationControllerStatus is an autogenerated deepcopy function. func DeepCopy_api_ReplicationControllerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerStatus) out := out.(*ReplicationControllerStatus) - out.Replicas = in.Replicas - out.FullyLabeledReplicas = in.FullyLabeledReplicas - out.ReadyReplicas = in.ReadyReplicas - out.AvailableReplicas = in.AvailableReplicas - out.ObservedGeneration = in.ObservedGeneration + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]ReplicationControllerCondition, len(*in)) @@ -3068,31 +2966,32 @@ func DeepCopy_api_ReplicationControllerStatus(in interface{}, out interface{}, c return err } } - } else { - out.Conditions = nil } return nil } } +// DeepCopy_api_ResourceFieldSelector is an autogenerated deepcopy function. func DeepCopy_api_ResourceFieldSelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceFieldSelector) out := out.(*ResourceFieldSelector) - out.ContainerName = in.ContainerName - out.Resource = in.Resource + *out = *in out.Divisor = in.Divisor.DeepCopy() return nil } } +// DeepCopy_api_ResourceQuota is an autogenerated deepcopy function. func DeepCopy_api_ResourceQuota(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuota) out := out.(*ResourceQuota) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_ResourceQuotaSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -3104,12 +3003,12 @@ func DeepCopy_api_ResourceQuota(in interface{}, out interface{}, c *conversion.C } } +// DeepCopy_api_ResourceQuotaList is an autogenerated deepcopy function. func DeepCopy_api_ResourceQuotaList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuotaList) out := out.(*ResourceQuotaList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ResourceQuota, len(*in)) @@ -3118,51 +3017,45 @@ func DeepCopy_api_ResourceQuotaList(in interface{}, out interface{}, c *conversi return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ResourceQuotaSpec is an autogenerated deepcopy function. func DeepCopy_api_ResourceQuotaSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuotaSpec) out := out.(*ResourceQuotaSpec) + *out = *in if in.Hard != nil { in, out := &in.Hard, &out.Hard *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Hard = nil } if in.Scopes != nil { in, out := &in.Scopes, &out.Scopes *out = make([]ResourceQuotaScope, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Scopes = nil + copy(*out, *in) } return nil } } +// DeepCopy_api_ResourceQuotaStatus is an autogenerated deepcopy function. func DeepCopy_api_ResourceQuotaStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceQuotaStatus) out := out.(*ResourceQuotaStatus) + *out = *in if in.Hard != nil { in, out := &in.Hard, &out.Hard *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Hard = nil } if in.Used != nil { in, out := &in.Used, &out.Used @@ -3170,25 +3063,23 @@ func DeepCopy_api_ResourceQuotaStatus(in interface{}, out interface{}, c *conver for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Used = nil } return nil } } +// DeepCopy_api_ResourceRequirements is an autogenerated deepcopy function. func DeepCopy_api_ResourceRequirements(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceRequirements) out := out.(*ResourceRequirements) + *out = *in if in.Limits != nil { in, out := &in.Limits, &out.Limits *out = make(ResourceList) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Limits = nil } if in.Requests != nil { in, out := &in.Requests, &out.Requests @@ -3196,32 +3087,46 @@ func DeepCopy_api_ResourceRequirements(in interface{}, out interface{}, c *conve for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.Requests = nil } return nil } } +// DeepCopy_api_SELinuxOptions is an autogenerated deepcopy function. func DeepCopy_api_SELinuxOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SELinuxOptions) out := out.(*SELinuxOptions) - out.User = in.User - out.Role = in.Role - out.Type = in.Type - out.Level = in.Level + *out = *in return nil } } +// DeepCopy_api_ScaleIOVolumeSource is an autogenerated deepcopy function. +func DeepCopy_api_ScaleIOVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ScaleIOVolumeSource) + out := out.(*ScaleIOVolumeSource) + *out = *in + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(LocalObjectReference) + **out = **in + } + return nil + } +} + +// DeepCopy_api_Secret is an autogenerated deepcopy function. func DeepCopy_api_Secret(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Secret) out := out.(*Secret) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Data != nil { in, out := &in.Data, &out.Data @@ -3233,30 +3138,47 @@ func DeepCopy_api_Secret(in interface{}, out interface{}, c *conversion.Cloner) (*out)[key] = *newVal.(*[]byte) } } - } else { - out.Data = nil } - out.Type = in.Type return nil } } +// DeepCopy_api_SecretEnvSource is an autogenerated deepcopy function. +func DeepCopy_api_SecretEnvSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SecretEnvSource) + out := out.(*SecretEnvSource) + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_api_SecretKeySelector is an autogenerated deepcopy function. func DeepCopy_api_SecretKeySelector(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecretKeySelector) out := out.(*SecretKeySelector) - out.LocalObjectReference = in.LocalObjectReference - out.Key = in.Key + *out = *in + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } return nil } } +// DeepCopy_api_SecretList is an autogenerated deepcopy function. func DeepCopy_api_SecretList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecretList) out := out.(*SecretList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Secret, len(*in)) @@ -3265,18 +3187,41 @@ func DeepCopy_api_SecretList(in interface{}, out interface{}, c *conversion.Clon return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_SecretProjection is an autogenerated deepcopy function. +func DeepCopy_api_SecretProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SecretProjection) + out := out.(*SecretProjection) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]KeyToPath, len(*in)) + for i := range *in { + if err := DeepCopy_api_KeyToPath(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in + } + return nil + } +} + +// DeepCopy_api_SecretVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_SecretVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecretVolumeSource) out := out.(*SecretVolumeSource) - out.SecretName = in.SecretName + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]KeyToPath, len(*in)) @@ -3285,89 +3230,83 @@ func DeepCopy_api_SecretVolumeSource(in interface{}, out interface{}, c *convers return err } } - } else { - out.Items = nil } if in.DefaultMode != nil { in, out := &in.DefaultMode, &out.DefaultMode *out = new(int32) **out = **in - } else { - out.DefaultMode = nil + } + if in.Optional != nil { + in, out := &in.Optional, &out.Optional + *out = new(bool) + **out = **in } return nil } } +// DeepCopy_api_SecurityContext is an autogenerated deepcopy function. func DeepCopy_api_SecurityContext(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SecurityContext) out := out.(*SecurityContext) + *out = *in if in.Capabilities != nil { in, out := &in.Capabilities, &out.Capabilities *out = new(Capabilities) if err := DeepCopy_api_Capabilities(*in, *out, c); err != nil { return err } - } else { - out.Capabilities = nil } if in.Privileged != nil { in, out := &in.Privileged, &out.Privileged *out = new(bool) **out = **in - } else { - out.Privileged = nil } if in.SELinuxOptions != nil { in, out := &in.SELinuxOptions, &out.SELinuxOptions *out = new(SELinuxOptions) **out = **in - } else { - out.SELinuxOptions = nil } if in.RunAsUser != nil { in, out := &in.RunAsUser, &out.RunAsUser *out = new(int64) **out = **in - } else { - out.RunAsUser = nil } if in.RunAsNonRoot != nil { in, out := &in.RunAsNonRoot, &out.RunAsNonRoot *out = new(bool) **out = **in - } else { - out.RunAsNonRoot = nil } if in.ReadOnlyRootFilesystem != nil { in, out := &in.ReadOnlyRootFilesystem, &out.ReadOnlyRootFilesystem *out = new(bool) **out = **in - } else { - out.ReadOnlyRootFilesystem = nil } return nil } } +// DeepCopy_api_SerializedReference is an autogenerated deepcopy function. func DeepCopy_api_SerializedReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SerializedReference) out := out.(*SerializedReference) - out.TypeMeta = in.TypeMeta - out.Reference = in.Reference + *out = *in return nil } } +// DeepCopy_api_Service is an autogenerated deepcopy function. func DeepCopy_api_Service(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Service) out := out.(*Service) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_api_ServiceSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -3379,42 +3318,42 @@ func DeepCopy_api_Service(in interface{}, out interface{}, c *conversion.Cloner) } } +// DeepCopy_api_ServiceAccount is an autogenerated deepcopy function. func DeepCopy_api_ServiceAccount(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceAccount) out := out.(*ServiceAccount) - out.TypeMeta = in.TypeMeta - if err := DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Secrets != nil { in, out := &in.Secrets, &out.Secrets *out = make([]ObjectReference, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Secrets = nil + copy(*out, *in) } if in.ImagePullSecrets != nil { in, out := &in.ImagePullSecrets, &out.ImagePullSecrets *out = make([]LocalObjectReference, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.ImagePullSecrets = nil + copy(*out, *in) + } + if in.AutomountServiceAccountToken != nil { + in, out := &in.AutomountServiceAccountToken, &out.AutomountServiceAccountToken + *out = new(bool) + **out = **in } return nil } } +// DeepCopy_api_ServiceAccountList is an autogenerated deepcopy function. func DeepCopy_api_ServiceAccountList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceAccountList) out := out.(*ServiceAccountList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ServiceAccount, len(*in)) @@ -3423,19 +3362,17 @@ func DeepCopy_api_ServiceAccountList(in interface{}, out interface{}, c *convers return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ServiceList is an autogenerated deepcopy function. func DeepCopy_api_ServiceList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceList) out := out.(*ServiceList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Service, len(*in)) @@ -3444,49 +3381,41 @@ func DeepCopy_api_ServiceList(in interface{}, out interface{}, c *conversion.Clo return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_api_ServicePort is an autogenerated deepcopy function. func DeepCopy_api_ServicePort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServicePort) out := out.(*ServicePort) - out.Name = in.Name - out.Protocol = in.Protocol - out.Port = in.Port - out.TargetPort = in.TargetPort - out.NodePort = in.NodePort + *out = *in return nil } } +// DeepCopy_api_ServiceProxyOptions is an autogenerated deepcopy function. func DeepCopy_api_ServiceProxyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceProxyOptions) out := out.(*ServiceProxyOptions) - out.TypeMeta = in.TypeMeta - out.Path = in.Path + *out = *in return nil } } +// DeepCopy_api_ServiceSpec is an autogenerated deepcopy function. func DeepCopy_api_ServiceSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceSpec) out := out.(*ServiceSpec) - out.Type = in.Type + *out = *in if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]ServicePort, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ports = nil + copy(*out, *in) } if in.Selector != nil { in, out := &in.Selector, &out.Selector @@ -3494,35 +3423,27 @@ func DeepCopy_api_ServiceSpec(in interface{}, out interface{}, c *conversion.Clo for key, val := range *in { (*out)[key] = val } - } else { - out.Selector = nil } - out.ClusterIP = in.ClusterIP - out.ExternalName = in.ExternalName if in.ExternalIPs != nil { in, out := &in.ExternalIPs, &out.ExternalIPs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.ExternalIPs = nil } - out.LoadBalancerIP = in.LoadBalancerIP - out.SessionAffinity = in.SessionAffinity if in.LoadBalancerSourceRanges != nil { in, out := &in.LoadBalancerSourceRanges, &out.LoadBalancerSourceRanges *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.LoadBalancerSourceRanges = nil } return nil } } +// DeepCopy_api_ServiceStatus is an autogenerated deepcopy function. func DeepCopy_api_ServiceStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ServiceStatus) out := out.(*ServiceStatus) + *out = *in if err := DeepCopy_api_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, c); err != nil { return err } @@ -3530,53 +3451,88 @@ func DeepCopy_api_ServiceStatus(in interface{}, out interface{}, c *conversion.C } } +// DeepCopy_api_StorageOSPersistentVolumeSource is an autogenerated deepcopy function. +func DeepCopy_api_StorageOSPersistentVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StorageOSPersistentVolumeSource) + out := out.(*StorageOSPersistentVolumeSource) + *out = *in + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(ObjectReference) + **out = **in + } + return nil + } +} + +// DeepCopy_api_StorageOSVolumeSource is an autogenerated deepcopy function. +func DeepCopy_api_StorageOSVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StorageOSVolumeSource) + out := out.(*StorageOSVolumeSource) + *out = *in + if in.SecretRef != nil { + in, out := &in.SecretRef, &out.SecretRef + *out = new(LocalObjectReference) + **out = **in + } + return nil + } +} + +// DeepCopy_api_Sysctl is an autogenerated deepcopy function. func DeepCopy_api_Sysctl(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Sysctl) out := out.(*Sysctl) - out.Name = in.Name - out.Value = in.Value + *out = *in return nil } } +// DeepCopy_api_TCPSocketAction is an autogenerated deepcopy function. func DeepCopy_api_TCPSocketAction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TCPSocketAction) out := out.(*TCPSocketAction) - out.Port = in.Port + *out = *in return nil } } +// DeepCopy_api_Taint is an autogenerated deepcopy function. func DeepCopy_api_Taint(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Taint) out := out.(*Taint) - out.Key = in.Key - out.Value = in.Value - out.Effect = in.Effect + *out = *in + out.TimeAdded = in.TimeAdded.DeepCopy() return nil } } +// DeepCopy_api_Toleration is an autogenerated deepcopy function. func DeepCopy_api_Toleration(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Toleration) out := out.(*Toleration) - out.Key = in.Key - out.Operator = in.Operator - out.Value = in.Value - out.Effect = in.Effect + *out = *in + if in.TolerationSeconds != nil { + in, out := &in.TolerationSeconds, &out.TolerationSeconds + *out = new(int64) + **out = **in + } return nil } } +// DeepCopy_api_Volume is an autogenerated deepcopy function. func DeepCopy_api_Volume(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Volume) out := out.(*Volume) - out.Name = in.Name + *out = *in if err := DeepCopy_api_VolumeSource(&in.VolumeSource, &out.VolumeSource, c); err != nil { return err } @@ -3584,56 +3540,79 @@ func DeepCopy_api_Volume(in interface{}, out interface{}, c *conversion.Cloner) } } +// DeepCopy_api_VolumeMount is an autogenerated deepcopy function. func DeepCopy_api_VolumeMount(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*VolumeMount) out := out.(*VolumeMount) - out.Name = in.Name - out.ReadOnly = in.ReadOnly - out.MountPath = in.MountPath - out.SubPath = in.SubPath + *out = *in + return nil + } +} + +// DeepCopy_api_VolumeProjection is an autogenerated deepcopy function. +func DeepCopy_api_VolumeProjection(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*VolumeProjection) + out := out.(*VolumeProjection) + *out = *in + if in.Secret != nil { + in, out := &in.Secret, &out.Secret + *out = new(SecretProjection) + if err := DeepCopy_api_SecretProjection(*in, *out, c); err != nil { + return err + } + } + if in.DownwardAPI != nil { + in, out := &in.DownwardAPI, &out.DownwardAPI + *out = new(DownwardAPIProjection) + if err := DeepCopy_api_DownwardAPIProjection(*in, *out, c); err != nil { + return err + } + } + if in.ConfigMap != nil { + in, out := &in.ConfigMap, &out.ConfigMap + *out = new(ConfigMapProjection) + if err := DeepCopy_api_ConfigMapProjection(*in, *out, c); err != nil { + return err + } + } return nil } } +// DeepCopy_api_VolumeSource is an autogenerated deepcopy function. func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*VolumeSource) out := out.(*VolumeSource) + *out = *in if in.HostPath != nil { in, out := &in.HostPath, &out.HostPath *out = new(HostPathVolumeSource) **out = **in - } else { - out.HostPath = nil } if in.EmptyDir != nil { in, out := &in.EmptyDir, &out.EmptyDir *out = new(EmptyDirVolumeSource) - **out = **in - } else { - out.EmptyDir = nil + if err := DeepCopy_api_EmptyDirVolumeSource(*in, *out, c); err != nil { + return err + } } if in.GCEPersistentDisk != nil { in, out := &in.GCEPersistentDisk, &out.GCEPersistentDisk *out = new(GCEPersistentDiskVolumeSource) **out = **in - } else { - out.GCEPersistentDisk = nil } if in.AWSElasticBlockStore != nil { in, out := &in.AWSElasticBlockStore, &out.AWSElasticBlockStore *out = new(AWSElasticBlockStoreVolumeSource) **out = **in - } else { - out.AWSElasticBlockStore = nil } if in.GitRepo != nil { in, out := &in.GitRepo, &out.GitRepo *out = new(GitRepoVolumeSource) **out = **in - } else { - out.GitRepo = nil } if in.Secret != nil { in, out := &in.Secret, &out.Secret @@ -3641,36 +3620,28 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_SecretVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.Secret = nil } if in.NFS != nil { in, out := &in.NFS, &out.NFS *out = new(NFSVolumeSource) **out = **in - } else { - out.NFS = nil } if in.ISCSI != nil { in, out := &in.ISCSI, &out.ISCSI *out = new(ISCSIVolumeSource) - **out = **in - } else { - out.ISCSI = nil + if err := DeepCopy_api_ISCSIVolumeSource(*in, *out, c); err != nil { + return err + } } if in.Glusterfs != nil { in, out := &in.Glusterfs, &out.Glusterfs *out = new(GlusterfsVolumeSource) **out = **in - } else { - out.Glusterfs = nil } if in.PersistentVolumeClaim != nil { in, out := &in.PersistentVolumeClaim, &out.PersistentVolumeClaim *out = new(PersistentVolumeClaimVolumeSource) **out = **in - } else { - out.PersistentVolumeClaim = nil } if in.RBD != nil { in, out := &in.RBD, &out.RBD @@ -3678,15 +3649,11 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_RBDVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.RBD = nil } if in.Quobyte != nil { in, out := &in.Quobyte, &out.Quobyte *out = new(QuobyteVolumeSource) **out = **in - } else { - out.Quobyte = nil } if in.FlexVolume != nil { in, out := &in.FlexVolume, &out.FlexVolume @@ -3694,15 +3661,11 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_FlexVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FlexVolume = nil } if in.Cinder != nil { in, out := &in.Cinder, &out.Cinder *out = new(CinderVolumeSource) **out = **in - } else { - out.Cinder = nil } if in.CephFS != nil { in, out := &in.CephFS, &out.CephFS @@ -3710,15 +3673,11 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_CephFSVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.CephFS = nil } if in.Flocker != nil { in, out := &in.Flocker, &out.Flocker *out = new(FlockerVolumeSource) **out = **in - } else { - out.Flocker = nil } if in.DownwardAPI != nil { in, out := &in.DownwardAPI, &out.DownwardAPI @@ -3726,8 +3685,6 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_DownwardAPIVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.DownwardAPI = nil } if in.FC != nil { in, out := &in.FC, &out.FC @@ -3735,15 +3692,11 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_FCVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.FC = nil } if in.AzureFile != nil { in, out := &in.AzureFile, &out.AzureFile *out = new(AzureFileVolumeSource) **out = **in - } else { - out.AzureFile = nil } if in.ConfigMap != nil { in, out := &in.ConfigMap, &out.ConfigMap @@ -3751,15 +3704,11 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_ConfigMapVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.ConfigMap = nil } if in.VsphereVolume != nil { in, out := &in.VsphereVolume, &out.VsphereVolume *out = new(VsphereVirtualDiskVolumeSource) **out = **in - } else { - out.VsphereVolume = nil } if in.AzureDisk != nil { in, out := &in.AzureDisk, &out.AzureDisk @@ -3767,35 +3716,58 @@ func DeepCopy_api_VolumeSource(in interface{}, out interface{}, c *conversion.Cl if err := DeepCopy_api_AzureDiskVolumeSource(*in, *out, c); err != nil { return err } - } else { - out.AzureDisk = nil } if in.PhotonPersistentDisk != nil { in, out := &in.PhotonPersistentDisk, &out.PhotonPersistentDisk *out = new(PhotonPersistentDiskVolumeSource) **out = **in - } else { - out.PhotonPersistentDisk = nil + } + if in.Projected != nil { + in, out := &in.Projected, &out.Projected + *out = new(ProjectedVolumeSource) + if err := DeepCopy_api_ProjectedVolumeSource(*in, *out, c); err != nil { + return err + } + } + if in.PortworxVolume != nil { + in, out := &in.PortworxVolume, &out.PortworxVolume + *out = new(PortworxVolumeSource) + **out = **in + } + if in.ScaleIO != nil { + in, out := &in.ScaleIO, &out.ScaleIO + *out = new(ScaleIOVolumeSource) + if err := DeepCopy_api_ScaleIOVolumeSource(*in, *out, c); err != nil { + return err + } + } + if in.StorageOS != nil { + in, out := &in.StorageOS, &out.StorageOS + *out = new(StorageOSVolumeSource) + if err := DeepCopy_api_StorageOSVolumeSource(*in, *out, c); err != nil { + return err + } } return nil } } +// DeepCopy_api_VsphereVirtualDiskVolumeSource is an autogenerated deepcopy function. func DeepCopy_api_VsphereVirtualDiskVolumeSource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*VsphereVirtualDiskVolumeSource) out := out.(*VsphereVirtualDiskVolumeSource) - out.VolumePath = in.VolumePath - out.FSType = in.FSType + *out = *in return nil } } +// DeepCopy_api_WeightedPodAffinityTerm is an autogenerated deepcopy function. func DeepCopy_api_WeightedPodAffinityTerm(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*WeightedPodAffinityTerm) out := out.(*WeightedPodAffinityTerm) - out.Weight = in.Weight + *out = *in if err := DeepCopy_api_PodAffinityTerm(&in.PodAffinityTerm, &out.PodAffinityTerm, c); err != nil { return err } diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/BUILD b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/BUILD new file mode 100644 index 0000000000..6e2604388a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/doc.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/doc.go similarity index 56% rename from vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/doc.go rename to vendor/k8s.io/client-go/pkg/apis/admissionregistration/doc.go index bc5df818d9..492dad7b54 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,9 @@ See the License for the specific language governing permissions and limitations under the License. */ -// This package is generated by client-gen with arguments: --clientset-name=release_1_5 --input=[api/v1,apps/v1beta1,authentication/v1beta1,authorization/v1beta1,autoscaling/v1,batch/v1,batch/v2alpha1,certificates/v1alpha1,extensions/v1beta1,policy/v1alpha1,rbac/v1alpha1,storage/v1beta1] - -// This package has the automatically generated typed clients. -package v1alpha1 +// Package admissionregistration is the internal version of the API. +// AdmissionConfiguration and AdmissionPluginConfiguration are legacy static admission plugin configuration +// InitializerConfiguration and ExternalAdmissionHookConfiguration is for the +// new dynamic admission controller configuration. +// +groupName=admissionregistration.k8s.io +package admissionregistration diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/register.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/register.go new file mode 100644 index 0000000000..1fe291a8f2 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/register.go @@ -0,0 +1,53 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package admissionregistration + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "admissionregistration.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns back a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns back a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + AddToScheme = SchemeBuilder.AddToScheme +) + +// Adds the list of known types to scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &InitializerConfiguration{}, + &InitializerConfigurationList{}, + &ExternalAdmissionHookConfiguration{}, + &ExternalAdmissionHookConfigurationList{}, + ) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/types.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/types.go new file mode 100644 index 0000000000..27b7207291 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/types.go @@ -0,0 +1,216 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package admissionregistration + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true +// +nonNamespaced=true + +// InitializerConfiguration describes the configuration of initializers. +type InitializerConfiguration struct { + metav1.TypeMeta + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +optional + Initializers []Initializer +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +type InitializerConfigurationList struct { + metav1.TypeMeta + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta + + // List of InitializerConfiguration. + Items []InitializerConfiguration +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +type Initializer struct { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + Name string + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + // Rule.Resources must not include subresources. + Rules []Rule + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + FailurePolicy *FailurePolicyType +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +type Rule struct { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + APIGroups []string + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + APIVersions []string + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If wildcard is present, the validation rule will ensure resources do not + // overlap with each other. + // + // Depending on the enclosing object, subresources might not be allowed. + // Required. + Resources []string +} + +type FailurePolicyType string + +const ( + // Ignore means the initilizer is removed from the initializers list of an + // object if the initializer is timed out. + Ignore FailurePolicyType = "Ignore" + // For 1.7, only "Ignore" is allowed. "Fail" will be allowed when the + // extensible admission feature is beta. + Fail FailurePolicyType = "Fail" +) + +// +genclient=true +// +nonNamespaced=true + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +type ExternalAdmissionHookConfiguration struct { + metav1.TypeMeta + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + ExternalAdmissionHooks []ExternalAdmissionHook +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +type ExternalAdmissionHookConfigurationList struct { + metav1.TypeMeta + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta + // List of ExternalAdmissionHookConfiguration. + Items []ExternalAdmissionHookConfiguration +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +type ExternalAdmissionHook struct { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + Name string + + // ClientConfig defines how to communicate with the hook. + // Required + ClientConfig AdmissionHookClientConfig + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + Rules []RuleWithOperations + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + FailurePolicy *FailurePolicyType +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +type RuleWithOperations struct { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + Operations []OperationType + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + Rule +} + +type OperationType string + +// The constants should be kept in sync with those defined in k8s.io/kubernetes/pkg/admission/interface.go. +const ( + OperationAll OperationType = "*" + Create OperationType = "CREATE" + Update OperationType = "UPDATE" + Delete OperationType = "DELETE" + Connect OperationType = "CONNECT" +) + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +type AdmissionHookClientConfig struct { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + Service ServiceReference + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + CABundle []byte +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +type ServiceReference struct { + // Namespace is the namespace of the service + // Required + Namespace string + // Name is the name of the service + // Required + Name string +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD new file mode 100644 index 0000000000..2af11423b5 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/admissionregistration:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go new file mode 100644 index 0000000000..5aed8f1d78 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/defaults.go @@ -0,0 +1,39 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_Initializer(obj *Initializer) { + if obj.FailurePolicy == nil { + policy := Ignore + obj.FailurePolicy = &policy + } +} + +func SetDefaults_ExternalAdmissionHook(obj *ExternalAdmissionHook) { + if obj.FailurePolicy == nil { + policy := Ignore + obj.FailurePolicy = &policy + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/doc.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/doc.go similarity index 59% rename from vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/doc.go rename to vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/doc.go index 65d58233ee..a848f3e928 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/doc.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,7 +14,9 @@ See the License for the specific language governing permissions and limitations under the License. */ -// Package policy is for any kind of policy object. Suitable examples, even if -// they aren't all here, are PodDisruptionBudget, PodSecurityPolicy, -// NetworkPolicy, etc. +// Package v1alpha1 is the v1alpha1 version of the API. +// AdmissionConfiguration and AdmissionPluginConfiguration are legacy static admission plugin configuration +// InitializerConfiguration and ExternalAdmissionHookConfiguration is for the +// new dynamic admission controller configuration. +// +groupName=admissionregistration.k8s.io package v1alpha1 diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go new file mode 100644 index 0000000000..58abc1d2f3 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.pb.go @@ -0,0 +1,2228 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto +// DO NOT EDIT! + +/* + Package v1alpha1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/admissionregistration/v1alpha1/generated.proto + + It has these top-level messages: + AdmissionHookClientConfig + ExternalAdmissionHook + ExternalAdmissionHookConfiguration + ExternalAdmissionHookConfigurationList + Initializer + InitializerConfiguration + InitializerConfigurationList + Rule + RuleWithOperations + ServiceReference +*/ +package v1alpha1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *AdmissionHookClientConfig) Reset() { *m = AdmissionHookClientConfig{} } +func (*AdmissionHookClientConfig) ProtoMessage() {} +func (*AdmissionHookClientConfig) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{0} +} + +func (m *ExternalAdmissionHook) Reset() { *m = ExternalAdmissionHook{} } +func (*ExternalAdmissionHook) ProtoMessage() {} +func (*ExternalAdmissionHook) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *ExternalAdmissionHookConfiguration) Reset() { *m = ExternalAdmissionHookConfiguration{} } +func (*ExternalAdmissionHookConfiguration) ProtoMessage() {} +func (*ExternalAdmissionHookConfiguration) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + +func (m *ExternalAdmissionHookConfigurationList) Reset() { + *m = ExternalAdmissionHookConfigurationList{} +} +func (*ExternalAdmissionHookConfigurationList) ProtoMessage() {} +func (*ExternalAdmissionHookConfigurationList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{3} +} + +func (m *Initializer) Reset() { *m = Initializer{} } +func (*Initializer) ProtoMessage() {} +func (*Initializer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *InitializerConfiguration) Reset() { *m = InitializerConfiguration{} } +func (*InitializerConfiguration) ProtoMessage() {} +func (*InitializerConfiguration) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{5} +} + +func (m *InitializerConfigurationList) Reset() { *m = InitializerConfigurationList{} } +func (*InitializerConfigurationList) ProtoMessage() {} +func (*InitializerConfigurationList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{6} +} + +func (m *Rule) Reset() { *m = Rule{} } +func (*Rule) ProtoMessage() {} +func (*Rule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *RuleWithOperations) Reset() { *m = RuleWithOperations{} } +func (*RuleWithOperations) ProtoMessage() {} +func (*RuleWithOperations) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *ServiceReference) Reset() { *m = ServiceReference{} } +func (*ServiceReference) ProtoMessage() {} +func (*ServiceReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func init() { + proto.RegisterType((*AdmissionHookClientConfig)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.AdmissionHookClientConfig") + proto.RegisterType((*ExternalAdmissionHook)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHook") + proto.RegisterType((*ExternalAdmissionHookConfiguration)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfiguration") + proto.RegisterType((*ExternalAdmissionHookConfigurationList)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ExternalAdmissionHookConfigurationList") + proto.RegisterType((*Initializer)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.Initializer") + proto.RegisterType((*InitializerConfiguration)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.InitializerConfiguration") + proto.RegisterType((*InitializerConfigurationList)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.InitializerConfigurationList") + proto.RegisterType((*Rule)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.Rule") + proto.RegisterType((*RuleWithOperations)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.RuleWithOperations") + proto.RegisterType((*ServiceReference)(nil), "k8s.io.client-go.pkg.apis.admissionregistration.v1alpha1.ServiceReference") +} +func (m *AdmissionHookClientConfig) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *AdmissionHookClientConfig) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Service.Size())) + n1, err := m.Service.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + if m.CABundle != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.CABundle))) + i += copy(dAtA[i:], m.CABundle) + } + return i, nil +} + +func (m *ExternalAdmissionHook) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHook) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ClientConfig.Size())) + n2, err := m.ClientConfig.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.FailurePolicy != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FailurePolicy))) + i += copy(dAtA[i:], *m.FailurePolicy) + } + return i, nil +} + +func (m *ExternalAdmissionHookConfiguration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHookConfiguration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n3, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.ExternalAdmissionHooks) > 0 { + for _, msg := range m.ExternalAdmissionHooks { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *ExternalAdmissionHookConfigurationList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ExternalAdmissionHookConfigurationList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n4, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Initializer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Initializer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if m.FailurePolicy != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.FailurePolicy))) + i += copy(dAtA[i:], *m.FailurePolicy) + } + return i, nil +} + +func (m *InitializerConfiguration) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *InitializerConfiguration) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n5, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + if len(m.Initializers) > 0 { + for _, msg := range m.Initializers { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *InitializerConfigurationList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *InitializerConfigurationList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *Rule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Rule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.APIVersions) > 0 { + for _, s := range m.APIVersions { + dAtA[i] = 0x12 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + dAtA[i] = 0x1a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *RuleWithOperations) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RuleWithOperations) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Operations) > 0 { + for _, s := range m.Operations { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Rule.Size())) + n7, err := m.Rule.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + return i, nil +} + +func (m *ServiceReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ServiceReference) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *AdmissionHookClientConfig) Size() (n int) { + var l int + _ = l + l = m.Service.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.CABundle != nil { + l = len(m.CABundle) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ExternalAdmissionHook) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = m.ClientConfig.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.FailurePolicy != nil { + l = len(*m.FailurePolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ExternalAdmissionHookConfiguration) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.ExternalAdmissionHooks) > 0 { + for _, e := range m.ExternalAdmissionHooks { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ExternalAdmissionHookConfigurationList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Initializer) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if m.FailurePolicy != nil { + l = len(*m.FailurePolicy) + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *InitializerConfiguration) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Initializers) > 0 { + for _, e := range m.Initializers { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *InitializerConfigurationList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Rule) Size() (n int) { + var l int + _ = l + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.APIVersions) > 0 { + for _, s := range m.APIVersions { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *RuleWithOperations) Size() (n int) { + var l int + _ = l + if len(m.Operations) > 0 { + for _, s := range m.Operations { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.Rule.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ServiceReference) Size() (n int) { + var l int + _ = l + l = len(m.Namespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *AdmissionHookClientConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&AdmissionHookClientConfig{`, + `Service:` + strings.Replace(strings.Replace(this.Service.String(), "ServiceReference", "ServiceReference", 1), `&`, ``, 1) + `,`, + `CABundle:` + valueToStringGenerated(this.CABundle) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHook) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHook{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `ClientConfig:` + strings.Replace(strings.Replace(this.ClientConfig.String(), "AdmissionHookClientConfig", "AdmissionHookClientConfig", 1), `&`, ``, 1) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "RuleWithOperations", "RuleWithOperations", 1), `&`, ``, 1) + `,`, + `FailurePolicy:` + valueToStringGenerated(this.FailurePolicy) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHookConfiguration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHookConfiguration{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ExternalAdmissionHooks:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.ExternalAdmissionHooks), "ExternalAdmissionHook", "ExternalAdmissionHook", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ExternalAdmissionHookConfigurationList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ExternalAdmissionHookConfigurationList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ExternalAdmissionHookConfiguration", "ExternalAdmissionHookConfiguration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Initializer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Initializer{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "Rule", "Rule", 1), `&`, ``, 1) + `,`, + `FailurePolicy:` + valueToStringGenerated(this.FailurePolicy) + `,`, + `}`, + }, "") + return s +} +func (this *InitializerConfiguration) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&InitializerConfiguration{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Initializers:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Initializers), "Initializer", "Initializer", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *InitializerConfigurationList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&InitializerConfigurationList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "InitializerConfiguration", "InitializerConfiguration", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Rule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Rule{`, + `APIGroups:` + fmt.Sprintf("%v", this.APIGroups) + `,`, + `APIVersions:` + fmt.Sprintf("%v", this.APIVersions) + `,`, + `Resources:` + fmt.Sprintf("%v", this.Resources) + `,`, + `}`, + }, "") + return s +} +func (this *RuleWithOperations) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RuleWithOperations{`, + `Operations:` + fmt.Sprintf("%v", this.Operations) + `,`, + `Rule:` + strings.Replace(strings.Replace(this.Rule.String(), "Rule", "Rule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ServiceReference) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ServiceReference{`, + `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *AdmissionHookClientConfig) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: AdmissionHookClientConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AdmissionHookClientConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Service", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Service.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CABundle", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + byteLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.CABundle = append(m.CABundle[:0], dAtA[iNdEx:postIndex]...) + if m.CABundle == nil { + m.CABundle = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHook) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHook: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHook: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClientConfig", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ClientConfig.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, RuleWithOperations{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailurePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := FailurePolicyType(dAtA[iNdEx:postIndex]) + m.FailurePolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHookConfiguration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHookConfiguration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHookConfiguration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ExternalAdmissionHooks", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ExternalAdmissionHooks = append(m.ExternalAdmissionHooks, ExternalAdmissionHook{}) + if err := m.ExternalAdmissionHooks[len(m.ExternalAdmissionHooks)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ExternalAdmissionHookConfigurationList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExternalAdmissionHookConfigurationList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExternalAdmissionHookConfigurationList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ExternalAdmissionHookConfiguration{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Initializer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Initializer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Initializer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, Rule{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FailurePolicy", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := FailurePolicyType(dAtA[iNdEx:postIndex]) + m.FailurePolicy = &s + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *InitializerConfiguration) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: InitializerConfiguration: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: InitializerConfiguration: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Initializers", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Initializers = append(m.Initializers, Initializer{}) + if err := m.Initializers[len(m.Initializers)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *InitializerConfigurationList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: InitializerConfigurationList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: InitializerConfigurationList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, InitializerConfiguration{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Rule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Rule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Rule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIGroups = append(m.APIGroups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersions", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersions = append(m.APIVersions, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resources = append(m.Resources, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RuleWithOperations) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RuleWithOperations: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RuleWithOperations: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Operations", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Operations = append(m.Operations, OperationType(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rule", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Rule.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ServiceReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ServiceReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ServiceReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 877 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x56, 0xcf, 0x6f, 0x1b, 0x45, + 0x14, 0xce, 0xd8, 0x8e, 0x6a, 0x8f, 0x6d, 0xb5, 0x1d, 0x41, 0x65, 0x22, 0xb4, 0x6b, 0xed, 0xa1, + 0xb2, 0x84, 0xd8, 0x25, 0x01, 0x21, 0x38, 0x55, 0xd9, 0x88, 0x82, 0x45, 0x7f, 0x44, 0xd3, 0x0a, + 0x24, 0x04, 0x12, 0x93, 0xf5, 0x8b, 0x3d, 0x78, 0x7f, 0x69, 0x66, 0xd6, 0x6a, 0x38, 0x55, 0x5c, + 0x41, 0x08, 0x89, 0x7f, 0x82, 0x2b, 0x37, 0x2e, 0xdc, 0x73, 0xec, 0xb1, 0x27, 0x8b, 0x6c, 0xff, + 0x07, 0x0e, 0xbd, 0x80, 0xf6, 0x97, 0x77, 0x5d, 0xdb, 0x6a, 0x54, 0x57, 0xbd, 0x65, 0xde, 0xdb, + 0xf7, 0xbd, 0xef, 0xfb, 0xf2, 0xde, 0x8c, 0xf1, 0x70, 0xfa, 0x89, 0x34, 0x79, 0x60, 0x4d, 0xa3, + 0x13, 0x10, 0x3e, 0x28, 0x90, 0x56, 0x38, 0x1d, 0x5b, 0x2c, 0xe4, 0xd2, 0x62, 0x23, 0x8f, 0x4b, + 0xc9, 0x03, 0x5f, 0xc0, 0x98, 0x4b, 0x25, 0x98, 0xe2, 0x81, 0x6f, 0xcd, 0xf6, 0x99, 0x1b, 0x4e, + 0xd8, 0xbe, 0x35, 0x06, 0x1f, 0x04, 0x53, 0x30, 0x32, 0x43, 0x11, 0xa8, 0x80, 0x7c, 0x9a, 0x41, + 0x99, 0x25, 0x94, 0x19, 0x4e, 0xc7, 0x66, 0x02, 0x65, 0xae, 0x85, 0x32, 0x0b, 0xa8, 0xbd, 0xf7, + 0xc7, 0x5c, 0x4d, 0xa2, 0x13, 0xd3, 0x09, 0x3c, 0x6b, 0x1c, 0x8c, 0x03, 0x2b, 0x45, 0x3c, 0x89, + 0x4e, 0xd3, 0x53, 0x7a, 0x48, 0xff, 0xca, 0x3a, 0xed, 0x7d, 0x94, 0x93, 0x66, 0x21, 0xf7, 0x98, + 0x33, 0xe1, 0x3e, 0x88, 0xb3, 0x92, 0xb6, 0x07, 0x8a, 0x59, 0xb3, 0x15, 0x7e, 0x7b, 0xd6, 0xa6, + 0x2a, 0x11, 0xf9, 0x8a, 0x7b, 0xb0, 0x52, 0xf0, 0xf1, 0xcb, 0x0a, 0xa4, 0x33, 0x01, 0x8f, 0xad, + 0xd4, 0x7d, 0xb8, 0xa9, 0x2e, 0x52, 0xdc, 0xb5, 0xb8, 0xaf, 0xa4, 0x12, 0x2f, 0x16, 0x19, 0x7f, + 0x23, 0xfc, 0xce, 0x61, 0xe1, 0xd2, 0x17, 0x41, 0x30, 0x3d, 0x72, 0x39, 0xf8, 0xea, 0x28, 0xf0, + 0x4f, 0xf9, 0x98, 0xcc, 0xf0, 0x15, 0x09, 0x62, 0xc6, 0x1d, 0xe8, 0xa1, 0x3e, 0x1a, 0xb4, 0x0f, + 0xbe, 0x34, 0x5f, 0xd9, 0x6d, 0xf3, 0x41, 0x86, 0x44, 0xe1, 0x14, 0x04, 0xf8, 0x0e, 0xd8, 0x57, + 0xcf, 0xe7, 0xfa, 0x4e, 0x3c, 0xd7, 0xaf, 0x14, 0x99, 0xa2, 0x19, 0x19, 0xe0, 0xa6, 0xc3, 0xec, + 0xc8, 0x1f, 0xb9, 0xd0, 0xab, 0xf5, 0xd1, 0xa0, 0x63, 0x77, 0xe2, 0xb9, 0xde, 0x3c, 0x3a, 0xcc, + 0x62, 0x74, 0x91, 0x35, 0x7e, 0xa9, 0xe3, 0xb7, 0x3f, 0x7b, 0xa4, 0x40, 0xf8, 0xcc, 0x5d, 0xd2, + 0x41, 0xfa, 0xb8, 0xe1, 0x33, 0x2f, 0x23, 0xde, 0xb2, 0x3b, 0x79, 0xaf, 0xc6, 0x3d, 0xe6, 0x01, + 0x4d, 0x33, 0xe4, 0x57, 0x84, 0x3b, 0x4e, 0x45, 0x6e, 0xda, 0xaa, 0x7d, 0xf0, 0x70, 0x0b, 0x8d, + 0x1b, 0xad, 0xb4, 0xdf, 0xca, 0x09, 0x74, 0xaa, 0x51, 0xba, 0xd4, 0x9f, 0x08, 0xbc, 0x2b, 0x22, + 0x17, 0x64, 0xaf, 0xde, 0xaf, 0x0f, 0xda, 0x07, 0x77, 0xb7, 0x20, 0x42, 0x23, 0x17, 0xbe, 0xe6, + 0x6a, 0x72, 0x3f, 0x84, 0x2c, 0x25, 0xed, 0x6e, 0xce, 0x60, 0x37, 0xc9, 0x49, 0x9a, 0xb5, 0x22, + 0x77, 0x70, 0xf7, 0x94, 0x71, 0x37, 0x12, 0x70, 0x1c, 0xb8, 0xdc, 0x39, 0xeb, 0x35, 0x52, 0xbf, + 0x6e, 0xc6, 0x73, 0xbd, 0x7b, 0xbb, 0x9a, 0x78, 0x3e, 0xd7, 0xaf, 0x2f, 0x05, 0x1e, 0x9e, 0x85, + 0x40, 0x97, 0x8b, 0x8d, 0x3f, 0x6b, 0xd8, 0x58, 0xfb, 0xef, 0xc8, 0x14, 0x46, 0x19, 0x17, 0xf2, + 0x3d, 0x6e, 0x26, 0xeb, 0x32, 0x62, 0x8a, 0xe5, 0x83, 0xf5, 0x41, 0xa1, 0xb5, 0x3a, 0xbd, 0xa5, + 0xda, 0xe4, 0x6b, 0x73, 0xb6, 0x6f, 0xde, 0x3f, 0xf9, 0x01, 0x1c, 0x75, 0x17, 0x14, 0xb3, 0x49, + 0x2e, 0x07, 0x97, 0x31, 0xba, 0x40, 0x25, 0x7f, 0x20, 0x7c, 0x03, 0xd6, 0x11, 0x91, 0xbd, 0x5a, + 0x6a, 0xee, 0xf1, 0x16, 0xe6, 0xae, 0x55, 0x68, 0x6b, 0x39, 0xa1, 0x1b, 0x6b, 0xd3, 0x92, 0x6e, + 0xe0, 0x63, 0xfc, 0x5c, 0xc3, 0x37, 0x5f, 0xee, 0xd9, 0x1d, 0x2e, 0x15, 0xf9, 0x76, 0xc5, 0x37, + 0xf3, 0x72, 0xbe, 0x25, 0xd5, 0xa9, 0x6b, 0xd7, 0x72, 0x92, 0xcd, 0x22, 0x52, 0xf1, 0xec, 0x27, + 0x84, 0x77, 0xb9, 0x02, 0xaf, 0xb0, 0xe8, 0xbb, 0xd7, 0x6d, 0xd1, 0x92, 0xa0, 0x72, 0x1e, 0x87, + 0x49, 0x4f, 0x9a, 0xb5, 0x36, 0x9e, 0x21, 0xdc, 0x1e, 0xfa, 0x5c, 0x71, 0xe6, 0xf2, 0x1f, 0x41, + 0x5c, 0x62, 0x8d, 0x47, 0xc5, 0xd6, 0x64, 0xac, 0x6f, 0x6d, 0xb9, 0x35, 0x97, 0xdd, 0x93, 0xfa, + 0x36, 0x7b, 0xf2, 0x1f, 0xc2, 0xbd, 0x8a, 0xca, 0x37, 0xbd, 0x1d, 0x8f, 0x11, 0xee, 0xf0, 0xb2, + 0x7d, 0x61, 0xdd, 0xed, 0x2d, 0xac, 0xab, 0xa8, 0x29, 0xef, 0xba, 0x4a, 0x50, 0xd2, 0xa5, 0x8e, + 0xc6, 0xbf, 0x08, 0xbf, 0xbb, 0xc9, 0x81, 0x37, 0x30, 0xeb, 0x8f, 0x96, 0x47, 0xfd, 0xc1, 0xeb, + 0x51, 0x7e, 0x99, 0x01, 0xff, 0x1d, 0xe1, 0x46, 0x32, 0x59, 0xe4, 0x3d, 0xdc, 0x62, 0x21, 0xff, + 0x5c, 0x04, 0x51, 0x28, 0x7b, 0xa8, 0x5f, 0x1f, 0xb4, 0xec, 0x6e, 0x3c, 0xd7, 0x5b, 0x87, 0xc7, + 0xc3, 0x2c, 0x48, 0xcb, 0x3c, 0xd9, 0xc7, 0x6d, 0x16, 0xf2, 0xaf, 0x40, 0x24, 0x3c, 0x32, 0xd6, + 0x2d, 0xfb, 0x6a, 0x3c, 0xd7, 0xdb, 0x87, 0xc7, 0xc3, 0x22, 0x4c, 0xab, 0xdf, 0x24, 0xf8, 0x02, + 0x64, 0x10, 0x09, 0x27, 0x7f, 0x51, 0x72, 0x7c, 0x5a, 0x04, 0x69, 0x99, 0x37, 0xfe, 0x42, 0x98, + 0xac, 0xbe, 0x19, 0xe4, 0x16, 0xc6, 0xc1, 0xe2, 0x94, 0x93, 0xd4, 0xd3, 0xb1, 0x5a, 0x44, 0x9f, + 0xcf, 0xf5, 0xee, 0xe2, 0x94, 0xce, 0x7a, 0xa5, 0x84, 0x30, 0xdc, 0x48, 0xf6, 0x27, 0x7f, 0x5a, + 0xb7, 0xde, 0xcd, 0xc5, 0xfe, 0x27, 0x27, 0x9a, 0x42, 0x1b, 0x80, 0xaf, 0xbd, 0xf8, 0xd3, 0x82, + 0x58, 0xb8, 0x95, 0xdc, 0x0d, 0x32, 0x64, 0x4e, 0x71, 0x75, 0x5c, 0xcf, 0x4b, 0x5b, 0xf7, 0x8a, + 0x04, 0x2d, 0xbf, 0x59, 0x5c, 0x33, 0xb5, 0x4d, 0xd7, 0x8c, 0x6d, 0x9e, 0x5f, 0x68, 0x3b, 0x4f, + 0x2e, 0xb4, 0x9d, 0xa7, 0x17, 0xda, 0xce, 0xe3, 0x58, 0x43, 0xe7, 0xb1, 0x86, 0x9e, 0xc4, 0x1a, + 0x7a, 0x1a, 0x6b, 0xe8, 0x9f, 0x58, 0x43, 0xbf, 0x3d, 0xd3, 0x76, 0xbe, 0x69, 0x16, 0x7c, 0xff, + 0x0f, 0x00, 0x00, 0xff, 0xff, 0x2c, 0x2c, 0x38, 0x31, 0xe3, 0x0a, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto new file mode 100644 index 0000000000..44ae98f6f5 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/generated.proto @@ -0,0 +1,203 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.admissionregistration.v1alpha1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1alpha1"; + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +message AdmissionHookClientConfig { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + optional ServiceReference service = 1; + + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + optional bytes caBundle = 2; +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +message ExternalAdmissionHook { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + optional string name = 1; + + // ClientConfig defines how to communicate with the hook. + // Required + optional AdmissionHookClientConfig clientConfig = 2; + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + repeated RuleWithOperations rules = 3; + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + optional string failurePolicy = 4; +} + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +message ExternalAdmissionHookConfiguration { + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + // +patchMergeKey=name + // +patchStrategy=merge + repeated ExternalAdmissionHook externalAdmissionHooks = 2; +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +message ExternalAdmissionHookConfigurationList { + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // List of ExternalAdmissionHookConfiguration. + repeated ExternalAdmissionHookConfiguration items = 2; +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +message Initializer { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + optional string name = 1; + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + // Rule.Resources must not include subresources. + repeated Rule rules = 2; + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + optional string failurePolicy = 3; +} + +// InitializerConfiguration describes the configuration of initializers. +message InitializerConfiguration { + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +patchMergeKey=name + // +patchStrategy=merge + // +optional + repeated Initializer initializers = 2; +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +message InitializerConfigurationList { + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // List of InitializerConfiguration. + repeated InitializerConfiguration items = 2; +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +message Rule { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string apiGroups = 1; + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string apiVersions = 2; + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If wildcard is present, the validation rule will ensure resources do not + // overlap with each other. + // + // Depending on the enclosing object, subresources might not be allowed. + // Required. + repeated string resources = 3; +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +message RuleWithOperations { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + repeated string operations = 1; + + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + optional Rule rule = 2; +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +message ServiceReference { + // Namespace is the namespace of the service + // Required + optional string namespace = 1; + + // Name is the name of the service + // Required + optional string name = 2; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go new file mode 100644 index 0000000000..10fa4a161b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/register.go @@ -0,0 +1,60 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "admissionregistration.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs) +} + +// Adds the list of known types to scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &InitializerConfiguration{}, + &InitializerConfigurationList{}, + &ExternalAdmissionHookConfiguration{}, + &ExternalAdmissionHookConfigurationList{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go new file mode 100644 index 0000000000..8a6563730b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.generated.go @@ -0,0 +1,4232 @@ +/* +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 v1alpha1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + "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 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 + } +} + +func (x *InitializerConfiguration) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Initializers) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Initializers == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceInitializer(([]Initializer)(x.Initializers), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("initializers")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Initializers == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceInitializer(([]Initializer)(x.Initializers), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *InitializerConfiguration) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *InitializerConfiguration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "initializers": + if r.TryDecodeAsNil() { + x.Initializers = nil + } else { + yyv10 := &x.Initializers + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceInitializer((*[]Initializer)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *InitializerConfiguration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Initializers = nil + } else { + yyv19 := &x.Initializers + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceInitializer((*[]Initializer)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *InitializerConfigurationList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceInitializerConfiguration(([]InitializerConfiguration)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceInitializerConfiguration(([]InitializerConfiguration)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *InitializerConfigurationList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *InitializerConfigurationList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceInitializerConfiguration((*[]InitializerConfiguration)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *InitializerConfigurationList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceInitializerConfiguration((*[]InitializerConfiguration)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Initializer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Rules) != 0 + yyq2[2] = x.FailurePolicy != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Rules == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceRule(([]Rule)(x.Rules), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceRule(([]Rule)(x.Rules), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy10 := *x.FailurePolicy + yy10.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failurePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy12 := *x.FailurePolicy + yy12.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Initializer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Initializer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv6 := &x.Rules + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceRule((*[]Rule)(yyv6), d) + } + } + case "failurePolicy": + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Initializer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv12 := &x.Rules + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSliceRule((*[]Rule)(yyv12), d) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Rule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.APIGroups) != 0 + yyq2[1] = len(x.APIVersions) != 0 + yyq2[2] = len(x.Resources) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Rule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Rule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv4 := &x.APIGroups + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "apiVersions": + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv6 := &x.APIVersions + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv8 := &x.Resources + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Rule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv11 := &x.APIGroups + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + z.F.DecSliceStringX(yyv11, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv13 := &x.APIVersions + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecSliceStringX(yyv13, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv15 := &x.Resources + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x FailurePolicyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *FailurePolicyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *ExternalAdmissionHookConfiguration) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.ExternalAdmissionHooks) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.ExternalAdmissionHooks == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceExternalAdmissionHook(([]ExternalAdmissionHook)(x.ExternalAdmissionHooks), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("externalAdmissionHooks")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ExternalAdmissionHooks == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceExternalAdmissionHook(([]ExternalAdmissionHook)(x.ExternalAdmissionHooks), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHookConfiguration) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHookConfiguration) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "externalAdmissionHooks": + if r.TryDecodeAsNil() { + x.ExternalAdmissionHooks = nil + } else { + yyv10 := &x.ExternalAdmissionHooks + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceExternalAdmissionHook((*[]ExternalAdmissionHook)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHookConfiguration) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ExternalAdmissionHooks = nil + } else { + yyv19 := &x.ExternalAdmissionHooks + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceExternalAdmissionHook((*[]ExternalAdmissionHook)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ExternalAdmissionHookConfigurationList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceExternalAdmissionHookConfiguration(([]ExternalAdmissionHookConfiguration)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceExternalAdmissionHookConfiguration(([]ExternalAdmissionHookConfiguration)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHookConfigurationList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHookConfigurationList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceExternalAdmissionHookConfiguration((*[]ExternalAdmissionHookConfiguration)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHookConfigurationList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceExternalAdmissionHookConfiguration((*[]ExternalAdmissionHookConfiguration)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ExternalAdmissionHook) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = len(x.Rules) != 0 + yyq2[3] = x.FailurePolicy != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.ClientConfig + yy7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("clientConfig")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.ClientConfig + yy9.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Rules == nil { + r.EncodeNil() + } else { + yym12 := z.EncBinary() + _ = yym12 + if false { + } else { + h.encSliceRuleWithOperations(([]RuleWithOperations)(x.Rules), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + h.encSliceRuleWithOperations(([]RuleWithOperations)(x.Rules), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy15 := *x.FailurePolicy + yy15.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failurePolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailurePolicy == nil { + r.EncodeNil() + } else { + yy17 := *x.FailurePolicy + yy17.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ExternalAdmissionHook) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ExternalAdmissionHook) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "clientConfig": + if r.TryDecodeAsNil() { + x.ClientConfig = AdmissionHookClientConfig{} + } else { + yyv6 := &x.ClientConfig + yyv6.CodecDecodeSelf(d) + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv7 := &x.Rules + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + h.decSliceRuleWithOperations((*[]RuleWithOperations)(yyv7), d) + } + } + case "failurePolicy": + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ExternalAdmissionHook) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ClientConfig = AdmissionHookClientConfig{} + } else { + yyv13 := &x.ClientConfig + yyv13.CodecDecodeSelf(d) + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv14 := &x.Rules + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSliceRuleWithOperations((*[]RuleWithOperations)(yyv14), d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailurePolicy != nil { + x.FailurePolicy = nil + } + } else { + if x.FailurePolicy == nil { + x.FailurePolicy = new(FailurePolicyType) + } + x.FailurePolicy.CodecDecodeSelf(d) + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RuleWithOperations) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Operations) != 0 + yyq2[1] = len(x.APIGroups) != 0 + yyq2[2] = len(x.APIVersions) != 0 + yyq2[3] = len(x.Resources) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Operations == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceOperationType(([]OperationType)(x.Operations), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("operations")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Operations == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceOperationType(([]OperationType)(x.Operations), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIVersions == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.APIVersions, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RuleWithOperations) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RuleWithOperations) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "operations": + if r.TryDecodeAsNil() { + x.Operations = nil + } else { + yyv4 := &x.Operations + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceOperationType((*[]OperationType)(yyv4), d) + } + } + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv6 := &x.APIGroups + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "apiVersions": + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv8 := &x.APIVersions + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv10 := &x.Resources + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RuleWithOperations) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Operations = nil + } else { + yyv13 := &x.Operations + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + h.decSliceOperationType((*[]OperationType)(yyv13), d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv15 := &x.APIGroups + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersions = nil + } else { + yyv17 := &x.APIVersions + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv19 := &x.Resources + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + z.F.DecSliceStringX(yyv19, false, d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x OperationType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *OperationType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *AdmissionHookClientConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Service + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("service")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Service + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.CABundle == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.CABundle)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("caBundle")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CABundle == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.CABundle)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *AdmissionHookClientConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *AdmissionHookClientConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "service": + if r.TryDecodeAsNil() { + x.Service = ServiceReference{} + } else { + yyv4 := &x.Service + yyv4.CodecDecodeSelf(d) + } + case "caBundle": + if r.TryDecodeAsNil() { + x.CABundle = nil + } else { + yyv5 := &x.CABundle + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *yyv5 = r.DecodeBytes(*(*[]byte)(yyv5), false, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *AdmissionHookClientConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Service = ServiceReference{} + } else { + yyv8 := &x.Service + yyv8.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CABundle = nil + } else { + yyv9 := &x.CABundle + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *yyv9 = r.DecodeBytes(*(*[]byte)(yyv9), false, false) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ServiceReference) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + 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) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ServiceReference) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ServiceReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv4 := &x.Namespace + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv6 := &x.Name + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ServiceReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv9 := &x.Namespace + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv11 := &x.Name + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceInitializer(v []Initializer, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceInitializer(v *[]Initializer, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Initializer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Initializer, yyrl1) + } + } else { + yyv1 = make([]Initializer, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Initializer{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Initializer{}) // var yyz1 Initializer + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Initializer{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Initializer{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceInitializerConfiguration(v []InitializerConfiguration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceInitializerConfiguration(v *[]InitializerConfiguration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []InitializerConfiguration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]InitializerConfiguration, yyrl1) + } + } else { + yyv1 = make([]InitializerConfiguration, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, InitializerConfiguration{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, InitializerConfiguration{}) // var yyz1 InitializerConfiguration + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = InitializerConfiguration{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []InitializerConfiguration{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRule(v []Rule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRule(v *[]Rule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Rule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Rule, yyrl1) + } + } else { + yyv1 = make([]Rule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Rule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Rule{}) // var yyz1 Rule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Rule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Rule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceExternalAdmissionHook(v []ExternalAdmissionHook, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceExternalAdmissionHook(v *[]ExternalAdmissionHook, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ExternalAdmissionHook{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 104) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ExternalAdmissionHook, yyrl1) + } + } else { + yyv1 = make([]ExternalAdmissionHook, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ExternalAdmissionHook{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ExternalAdmissionHook{}) // var yyz1 ExternalAdmissionHook + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHook{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ExternalAdmissionHook{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceExternalAdmissionHookConfiguration(v []ExternalAdmissionHookConfiguration, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceExternalAdmissionHookConfiguration(v *[]ExternalAdmissionHookConfiguration, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ExternalAdmissionHookConfiguration{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ExternalAdmissionHookConfiguration, yyrl1) + } + } else { + yyv1 = make([]ExternalAdmissionHookConfiguration, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ExternalAdmissionHookConfiguration{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ExternalAdmissionHookConfiguration{}) // var yyz1 ExternalAdmissionHookConfiguration + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ExternalAdmissionHookConfiguration{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ExternalAdmissionHookConfiguration{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRuleWithOperations(v []RuleWithOperations, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRuleWithOperations(v *[]RuleWithOperations, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []RuleWithOperations{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 96) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]RuleWithOperations, yyrl1) + } + } else { + yyv1 = make([]RuleWithOperations, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, RuleWithOperations{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, RuleWithOperations{}) // var yyz1 RuleWithOperations + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = RuleWithOperations{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []RuleWithOperations{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceOperationType(v []OperationType, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yyv1.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceOperationType(v *[]OperationType, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []OperationType{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]OperationType, yyrl1) + } + } else { + yyv1 = make([]OperationType, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 OperationType + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []OperationType{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go new file mode 100644 index 0000000000..0d878095c8 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types.go @@ -0,0 +1,220 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true +// +nonNamespaced=true + +// InitializerConfiguration describes the configuration of initializers. +type InitializerConfiguration struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Initializers is a list of resources and their default initializers + // Order-sensitive. + // When merging multiple InitializerConfigurations, we sort the initializers + // from different InitializerConfigurations by the name of the + // InitializerConfigurations; the order of the initializers from the same + // InitializerConfiguration is preserved. + // +patchMergeKey=name + // +patchStrategy=merge + // +optional + Initializers []Initializer `json:"initializers,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=initializers"` +} + +// InitializerConfigurationList is a list of InitializerConfiguration. +type InitializerConfigurationList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // List of InitializerConfiguration. + Items []InitializerConfiguration `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// Initializer describes the name and the failure policy of an initializer, and +// what resources it applies to. +type Initializer struct { + // Name is the identifier of the initializer. It will be added to the + // object that needs to be initialized. + // Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where + // "alwayspullimages" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + + // Rules describes what resources/subresources the initializer cares about. + // The initializer cares about an operation if it matches _any_ Rule. + // Rule.Resources must not include subresources. + Rules []Rule `json:"rules,omitempty" protobuf:"bytes,2,rep,name=rules"` + + // FailurePolicy defines what happens if the responsible initializer controller + // fails to takes action. Allowed values are Ignore, or Fail. If "Ignore" is + // set, initializer is removed from the initializers list of an object if + // the timeout is reached; If "Fail" is set, admissionregistration returns timeout error + // if the timeout is reached. + FailurePolicy *FailurePolicyType `json:"failurePolicy,omitempty" protobuf:"bytes,3,opt,name=failurePolicy,casttype=FailurePolicyType"` +} + +// Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended +// to make sure that all the tuple expansions are valid. +type Rule struct { + // APIGroups is the API groups the resources belong to. '*' is all groups. + // If '*' is present, the length of the slice must be one. + // Required. + APIGroups []string `json:"apiGroups,omitempty" protobuf:"bytes,1,rep,name=apiGroups"` + + // APIVersions is the API versions the resources belong to. '*' is all versions. + // If '*' is present, the length of the slice must be one. + // Required. + APIVersions []string `json:"apiVersions,omitempty" protobuf:"bytes,2,rep,name=apiVersions"` + + // Resources is a list of resources this rule applies to. + // + // For example: + // 'pods' means pods. + // 'pods/log' means the log subresource of pods. + // '*' means all resources, but not subresources. + // 'pods/*' means all subresources of pods. + // '*/scale' means all scale subresources. + // '*/*' means all resources and their subresources. + // + // If wildcard is present, the validation rule will ensure resources do not + // overlap with each other. + // + // Depending on the enclosing object, subresources might not be allowed. + // Required. + Resources []string `json:"resources,omitempty" protobuf:"bytes,3,rep,name=resources"` +} + +type FailurePolicyType string + +const ( + // Ignore means the initilizer is removed from the initializers list of an + // object if the initializer is timed out. + Ignore FailurePolicyType = "Ignore" + // For 1.7, only "Ignore" is allowed. "Fail" will be allowed when the + // extensible admission feature is beta. + Fail FailurePolicyType = "Fail" +) + +// +genclient=true +// +nonNamespaced=true + +// ExternalAdmissionHookConfiguration describes the configuration of initializers. +type ExternalAdmissionHookConfiguration struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + // ExternalAdmissionHooks is a list of external admission webhooks and the + // affected resources and operations. + // +optional + // +patchMergeKey=name + // +patchStrategy=merge + ExternalAdmissionHooks []ExternalAdmissionHook `json:"externalAdmissionHooks,omitempty" patchStrategy:"merge" patchMergeKey:"name" protobuf:"bytes,2,rep,name=externalAdmissionHooks"` +} + +// ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration. +type ExternalAdmissionHookConfigurationList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + // List of ExternalAdmissionHookConfiguration. + Items []ExternalAdmissionHookConfiguration `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// ExternalAdmissionHook describes an external admission webhook and the +// resources and operations it applies to. +type ExternalAdmissionHook struct { + // The name of the external admission webhook. + // Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where + // "imagepolicy" is the name of the webhook, and kubernetes.io is the name + // of the organization. + // Required. + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + + // ClientConfig defines how to communicate with the hook. + // Required + ClientConfig AdmissionHookClientConfig `json:"clientConfig" protobuf:"bytes,2,opt,name=clientConfig"` + + // Rules describes what operations on what resources/subresources the webhook cares about. + // The webhook cares about an operation if it matches _any_ Rule. + Rules []RuleWithOperations `json:"rules,omitempty" protobuf:"bytes,3,rep,name=rules"` + + // FailurePolicy defines how unrecognized errors from the admission endpoint are handled - + // allowed values are Ignore or Fail. Defaults to Ignore. + // +optional + FailurePolicy *FailurePolicyType `json:"failurePolicy,omitempty" protobuf:"bytes,4,opt,name=failurePolicy,casttype=FailurePolicyType"` +} + +// RuleWithOperations is a tuple of Operations and Resources. It is recommended to make +// sure that all the tuple expansions are valid. +type RuleWithOperations struct { + // Operations is the operations the admission hook cares about - CREATE, UPDATE, or * + // for all operations. + // If '*' is present, the length of the slice must be one. + // Required. + Operations []OperationType `json:"operations,omitempty" protobuf:"bytes,1,rep,name=operations,casttype=OperationType"` + // Rule is embedded, it describes other criteria of the rule, like + // APIGroups, APIVersions, Resources, etc. + Rule `json:",inline" protobuf:"bytes,2,opt,name=rule"` +} + +type OperationType string + +// The constants should be kept in sync with those defined in k8s.io/kubernetes/pkg/admission/interface.go. +const ( + OperationAll OperationType = "*" + Create OperationType = "CREATE" + Update OperationType = "UPDATE" + Delete OperationType = "DELETE" + Connect OperationType = "CONNECT" +) + +// AdmissionHookClientConfig contains the information to make a TLS +// connection with the webhook +type AdmissionHookClientConfig struct { + // Service is a reference to the service for this webhook. If there is only + // one port open for the service, that port will be used. If there are multiple + // ports open, port 443 will be used if it is open, otherwise it is an error. + // Required + Service ServiceReference `json:"service" protobuf:"bytes,1,opt,name=service"` + // CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. + // Required + CABundle []byte `json:"caBundle" protobuf:"bytes,2,opt,name=caBundle"` +} + +// ServiceReference holds a reference to Service.legacy.k8s.io +type ServiceReference struct { + // Namespace is the namespace of the service + // Required + Namespace string `json:"namespace" protobuf:"bytes,1,opt,name=namespace"` + // Name is the name of the service + // Required + Name string `json:"name" protobuf:"bytes,2,opt,name=name"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..9597deb59d --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/types_swagger_doc_generated.go @@ -0,0 +1,133 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_AdmissionHookClientConfig = map[string]string{ + "": "AdmissionHookClientConfig contains the information to make a TLS connection with the webhook", + "service": "Service is a reference to the service for this webhook. If there is only one port open for the service, that port will be used. If there are multiple ports open, port 443 will be used if it is open, otherwise it is an error. Required", + "caBundle": "CABundle is a PEM encoded CA bundle which will be used to validate webhook's server certificate. Required", +} + +func (AdmissionHookClientConfig) SwaggerDoc() map[string]string { + return map_AdmissionHookClientConfig +} + +var map_ExternalAdmissionHook = map[string]string{ + "": "ExternalAdmissionHook describes an external admission webhook and the resources and operations it applies to.", + "name": "The name of the external admission webhook. Name should be fully qualified, e.g., imagepolicy.kubernetes.io, where \"imagepolicy\" is the name of the webhook, and kubernetes.io is the name of the organization. Required.", + "clientConfig": "ClientConfig defines how to communicate with the hook. Required", + "rules": "Rules describes what operations on what resources/subresources the webhook cares about. The webhook cares about an operation if it matches _any_ Rule.", + "failurePolicy": "FailurePolicy defines how unrecognized errors from the admission endpoint are handled - allowed values are Ignore or Fail. Defaults to Ignore.", +} + +func (ExternalAdmissionHook) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHook +} + +var map_ExternalAdmissionHookConfiguration = map[string]string{ + "": "ExternalAdmissionHookConfiguration describes the configuration of initializers.", + "metadata": "Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata.", + "externalAdmissionHooks": "ExternalAdmissionHooks is a list of external admission webhooks and the affected resources and operations.", +} + +func (ExternalAdmissionHookConfiguration) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHookConfiguration +} + +var map_ExternalAdmissionHookConfigurationList = map[string]string{ + "": "ExternalAdmissionHookConfigurationList is a list of ExternalAdmissionHookConfiguration.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of ExternalAdmissionHookConfiguration.", +} + +func (ExternalAdmissionHookConfigurationList) SwaggerDoc() map[string]string { + return map_ExternalAdmissionHookConfigurationList +} + +var map_Initializer = map[string]string{ + "": "Initializer describes the name and the failure policy of an initializer, and what resources it applies to.", + "name": "Name is the identifier of the initializer. It will be added to the object that needs to be initialized. Name should be fully qualified, e.g., alwayspullimages.kubernetes.io, where \"alwayspullimages\" is the name of the webhook, and kubernetes.io is the name of the organization. Required", + "rules": "Rules describes what resources/subresources the initializer cares about. The initializer cares about an operation if it matches _any_ Rule. Rule.Resources must not include subresources.", + "failurePolicy": "FailurePolicy defines what happens if the responsible initializer controller fails to takes action. Allowed values are Ignore, or Fail. If \"Ignore\" is set, initializer is removed from the initializers list of an object if the timeout is reached; If \"Fail\" is set, admissionregistration returns timeout error if the timeout is reached.", +} + +func (Initializer) SwaggerDoc() map[string]string { + return map_Initializer +} + +var map_InitializerConfiguration = map[string]string{ + "": "InitializerConfiguration describes the configuration of initializers.", + "metadata": "Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata.", + "initializers": "Initializers is a list of resources and their default initializers Order-sensitive. When merging multiple InitializerConfigurations, we sort the initializers from different InitializerConfigurations by the name of the InitializerConfigurations; the order of the initializers from the same InitializerConfiguration is preserved.", +} + +func (InitializerConfiguration) SwaggerDoc() map[string]string { + return map_InitializerConfiguration +} + +var map_InitializerConfigurationList = map[string]string{ + "": "InitializerConfigurationList is a list of InitializerConfiguration.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of InitializerConfiguration.", +} + +func (InitializerConfigurationList) SwaggerDoc() map[string]string { + return map_InitializerConfigurationList +} + +var map_Rule = map[string]string{ + "": "Rule is a tuple of APIGroups, APIVersion, and Resources.It is recommended to make sure that all the tuple expansions are valid.", + "apiGroups": "APIGroups is the API groups the resources belong to. '*' is all groups. If '*' is present, the length of the slice must be one. Required.", + "apiVersions": "APIVersions is the API versions the resources belong to. '*' is all versions. If '*' is present, the length of the slice must be one. Required.", + "resources": "Resources is a list of resources this rule applies to.\n\nFor example: 'pods' means pods. 'pods/log' means the log subresource of pods. '*' means all resources, but not subresources. 'pods/*' means all subresources of pods. '*/scale' means all scale subresources. '*/*' means all resources and their subresources.\n\nIf wildcard is present, the validation rule will ensure resources do not overlap with each other.\n\nDepending on the enclosing object, subresources might not be allowed. Required.", +} + +func (Rule) SwaggerDoc() map[string]string { + return map_Rule +} + +var map_RuleWithOperations = map[string]string{ + "": "RuleWithOperations is a tuple of Operations and Resources. It is recommended to make sure that all the tuple expansions are valid.", + "operations": "Operations is the operations the admission hook cares about - CREATE, UPDATE, or * for all operations. If '*' is present, the length of the slice must be one. Required.", +} + +func (RuleWithOperations) SwaggerDoc() map[string]string { + return map_RuleWithOperations +} + +var map_ServiceReference = map[string]string{ + "": "ServiceReference holds a reference to Service.legacy.k8s.io", + "namespace": "Namespace is the namespace of the service Required", + "name": "Name is the name of the service Required", +} + +func (ServiceReference) SwaggerDoc() map[string]string { + return map_ServiceReference +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go new file mode 100644 index 0000000000..34c645df47 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.conversion.go @@ -0,0 +1,311 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1alpha1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + admissionregistration "k8s.io/client-go/pkg/apis/admissionregistration" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig, + Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig, + Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook, + Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook, + Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration, + Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration, + Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList, + Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList, + Convert_v1alpha1_Initializer_To_admissionregistration_Initializer, + Convert_admissionregistration_Initializer_To_v1alpha1_Initializer, + Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration, + Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration, + Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList, + Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList, + Convert_v1alpha1_Rule_To_admissionregistration_Rule, + Convert_admissionregistration_Rule_To_v1alpha1_Rule, + Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations, + Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations, + Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference, + Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference, + ) +} + +func autoConvert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in *AdmissionHookClientConfig, out *admissionregistration.AdmissionHookClientConfig, s conversion.Scope) error { + if err := Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(&in.Service, &out.Service, s); err != nil { + return err + } + out.CABundle = *(*[]byte)(unsafe.Pointer(&in.CABundle)) + return nil +} + +// Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig is an autogenerated conversion function. +func Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in *AdmissionHookClientConfig, out *admissionregistration.AdmissionHookClientConfig, s conversion.Scope) error { + return autoConvert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(in, out, s) +} + +func autoConvert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in *admissionregistration.AdmissionHookClientConfig, out *AdmissionHookClientConfig, s conversion.Scope) error { + if err := Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(&in.Service, &out.Service, s); err != nil { + return err + } + if in.CABundle == nil { + out.CABundle = make([]byte, 0) + } else { + out.CABundle = *(*[]byte)(unsafe.Pointer(&in.CABundle)) + } + return nil +} + +// Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig is an autogenerated conversion function. +func Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in *admissionregistration.AdmissionHookClientConfig, out *AdmissionHookClientConfig, s conversion.Scope) error { + return autoConvert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in *ExternalAdmissionHook, out *admissionregistration.ExternalAdmissionHook, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_v1alpha1_AdmissionHookClientConfig_To_admissionregistration_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, s); err != nil { + return err + } + out.Rules = *(*[]admissionregistration.RuleWithOperations)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*admissionregistration.FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in *ExternalAdmissionHook, out *admissionregistration.ExternalAdmissionHook, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHook_To_admissionregistration_ExternalAdmissionHook(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in *admissionregistration.ExternalAdmissionHook, out *ExternalAdmissionHook, s conversion.Scope) error { + out.Name = in.Name + if err := Convert_admissionregistration_AdmissionHookClientConfig_To_v1alpha1_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, s); err != nil { + return err + } + out.Rules = *(*[]RuleWithOperations)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in *admissionregistration.ExternalAdmissionHook, out *ExternalAdmissionHook, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHook_To_v1alpha1_ExternalAdmissionHook(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration, out *admissionregistration.ExternalAdmissionHookConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.ExternalAdmissionHooks = *(*[]admissionregistration.ExternalAdmissionHook)(unsafe.Pointer(&in.ExternalAdmissionHooks)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration, out *admissionregistration.ExternalAdmissionHookConfiguration, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHookConfiguration_To_admissionregistration_ExternalAdmissionHookConfiguration(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in *admissionregistration.ExternalAdmissionHookConfiguration, out *ExternalAdmissionHookConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.ExternalAdmissionHooks = *(*[]ExternalAdmissionHook)(unsafe.Pointer(&in.ExternalAdmissionHooks)) + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in *admissionregistration.ExternalAdmissionHookConfiguration, out *ExternalAdmissionHookConfiguration, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHookConfiguration_To_v1alpha1_ExternalAdmissionHookConfiguration(in, out, s) +} + +func autoConvert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList, out *admissionregistration.ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]admissionregistration.ExternalAdmissionHookConfiguration)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList is an autogenerated conversion function. +func Convert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList, out *admissionregistration.ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + return autoConvert_v1alpha1_ExternalAdmissionHookConfigurationList_To_admissionregistration_ExternalAdmissionHookConfigurationList(in, out, s) +} + +func autoConvert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in *admissionregistration.ExternalAdmissionHookConfigurationList, out *ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]ExternalAdmissionHookConfiguration, 0) + } else { + out.Items = *(*[]ExternalAdmissionHookConfiguration)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList is an autogenerated conversion function. +func Convert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in *admissionregistration.ExternalAdmissionHookConfigurationList, out *ExternalAdmissionHookConfigurationList, s conversion.Scope) error { + return autoConvert_admissionregistration_ExternalAdmissionHookConfigurationList_To_v1alpha1_ExternalAdmissionHookConfigurationList(in, out, s) +} + +func autoConvert_v1alpha1_Initializer_To_admissionregistration_Initializer(in *Initializer, out *admissionregistration.Initializer, s conversion.Scope) error { + out.Name = in.Name + out.Rules = *(*[]admissionregistration.Rule)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*admissionregistration.FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_v1alpha1_Initializer_To_admissionregistration_Initializer is an autogenerated conversion function. +func Convert_v1alpha1_Initializer_To_admissionregistration_Initializer(in *Initializer, out *admissionregistration.Initializer, s conversion.Scope) error { + return autoConvert_v1alpha1_Initializer_To_admissionregistration_Initializer(in, out, s) +} + +func autoConvert_admissionregistration_Initializer_To_v1alpha1_Initializer(in *admissionregistration.Initializer, out *Initializer, s conversion.Scope) error { + out.Name = in.Name + out.Rules = *(*[]Rule)(unsafe.Pointer(&in.Rules)) + out.FailurePolicy = (*FailurePolicyType)(unsafe.Pointer(in.FailurePolicy)) + return nil +} + +// Convert_admissionregistration_Initializer_To_v1alpha1_Initializer is an autogenerated conversion function. +func Convert_admissionregistration_Initializer_To_v1alpha1_Initializer(in *admissionregistration.Initializer, out *Initializer, s conversion.Scope) error { + return autoConvert_admissionregistration_Initializer_To_v1alpha1_Initializer(in, out, s) +} + +func autoConvert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in *InitializerConfiguration, out *admissionregistration.InitializerConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Initializers = *(*[]admissionregistration.Initializer)(unsafe.Pointer(&in.Initializers)) + return nil +} + +// Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration is an autogenerated conversion function. +func Convert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in *InitializerConfiguration, out *admissionregistration.InitializerConfiguration, s conversion.Scope) error { + return autoConvert_v1alpha1_InitializerConfiguration_To_admissionregistration_InitializerConfiguration(in, out, s) +} + +func autoConvert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in *admissionregistration.InitializerConfiguration, out *InitializerConfiguration, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Initializers = *(*[]Initializer)(unsafe.Pointer(&in.Initializers)) + return nil +} + +// Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration is an autogenerated conversion function. +func Convert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in *admissionregistration.InitializerConfiguration, out *InitializerConfiguration, s conversion.Scope) error { + return autoConvert_admissionregistration_InitializerConfiguration_To_v1alpha1_InitializerConfiguration(in, out, s) +} + +func autoConvert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in *InitializerConfigurationList, out *admissionregistration.InitializerConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]admissionregistration.InitializerConfiguration)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList is an autogenerated conversion function. +func Convert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in *InitializerConfigurationList, out *admissionregistration.InitializerConfigurationList, s conversion.Scope) error { + return autoConvert_v1alpha1_InitializerConfigurationList_To_admissionregistration_InitializerConfigurationList(in, out, s) +} + +func autoConvert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in *admissionregistration.InitializerConfigurationList, out *InitializerConfigurationList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]InitializerConfiguration, 0) + } else { + out.Items = *(*[]InitializerConfiguration)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList is an autogenerated conversion function. +func Convert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in *admissionregistration.InitializerConfigurationList, out *InitializerConfigurationList, s conversion.Scope) error { + return autoConvert_admissionregistration_InitializerConfigurationList_To_v1alpha1_InitializerConfigurationList(in, out, s) +} + +func autoConvert_v1alpha1_Rule_To_admissionregistration_Rule(in *Rule, out *admissionregistration.Rule, s conversion.Scope) error { + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.APIVersions = *(*[]string)(unsafe.Pointer(&in.APIVersions)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + return nil +} + +// Convert_v1alpha1_Rule_To_admissionregistration_Rule is an autogenerated conversion function. +func Convert_v1alpha1_Rule_To_admissionregistration_Rule(in *Rule, out *admissionregistration.Rule, s conversion.Scope) error { + return autoConvert_v1alpha1_Rule_To_admissionregistration_Rule(in, out, s) +} + +func autoConvert_admissionregistration_Rule_To_v1alpha1_Rule(in *admissionregistration.Rule, out *Rule, s conversion.Scope) error { + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.APIVersions = *(*[]string)(unsafe.Pointer(&in.APIVersions)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + return nil +} + +// Convert_admissionregistration_Rule_To_v1alpha1_Rule is an autogenerated conversion function. +func Convert_admissionregistration_Rule_To_v1alpha1_Rule(in *admissionregistration.Rule, out *Rule, s conversion.Scope) error { + return autoConvert_admissionregistration_Rule_To_v1alpha1_Rule(in, out, s) +} + +func autoConvert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in *RuleWithOperations, out *admissionregistration.RuleWithOperations, s conversion.Scope) error { + out.Operations = *(*[]admissionregistration.OperationType)(unsafe.Pointer(&in.Operations)) + if err := Convert_v1alpha1_Rule_To_admissionregistration_Rule(&in.Rule, &out.Rule, s); err != nil { + return err + } + return nil +} + +// Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations is an autogenerated conversion function. +func Convert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in *RuleWithOperations, out *admissionregistration.RuleWithOperations, s conversion.Scope) error { + return autoConvert_v1alpha1_RuleWithOperations_To_admissionregistration_RuleWithOperations(in, out, s) +} + +func autoConvert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in *admissionregistration.RuleWithOperations, out *RuleWithOperations, s conversion.Scope) error { + out.Operations = *(*[]OperationType)(unsafe.Pointer(&in.Operations)) + if err := Convert_admissionregistration_Rule_To_v1alpha1_Rule(&in.Rule, &out.Rule, s); err != nil { + return err + } + return nil +} + +// Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations is an autogenerated conversion function. +func Convert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in *admissionregistration.RuleWithOperations, out *RuleWithOperations, s conversion.Scope) error { + return autoConvert_admissionregistration_RuleWithOperations_To_v1alpha1_RuleWithOperations(in, out, s) +} + +func autoConvert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in *ServiceReference, out *admissionregistration.ServiceReference, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Name = in.Name + return nil +} + +// Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference is an autogenerated conversion function. +func Convert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in *ServiceReference, out *admissionregistration.ServiceReference, s conversion.Scope) error { + return autoConvert_v1alpha1_ServiceReference_To_admissionregistration_ServiceReference(in, out, s) +} + +func autoConvert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in *admissionregistration.ServiceReference, out *ServiceReference, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Name = in.Name + return nil +} + +// Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference is an autogenerated conversion function. +func Convert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in *admissionregistration.ServiceReference, out *ServiceReference, s conversion.Scope) error { + return autoConvert_admissionregistration_ServiceReference_To_v1alpha1_ServiceReference(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..526dbe3a22 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.deepcopy.go @@ -0,0 +1,254 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_AdmissionHookClientConfig, InType: reflect.TypeOf(&AdmissionHookClientConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHook, InType: reflect.TypeOf(&ExternalAdmissionHook{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration, InType: reflect.TypeOf(&ExternalAdmissionHookConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList, InType: reflect.TypeOf(&ExternalAdmissionHookConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_Initializer, InType: reflect.TypeOf(&Initializer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_InitializerConfiguration, InType: reflect.TypeOf(&InitializerConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_InitializerConfigurationList, InType: reflect.TypeOf(&InitializerConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_Rule, InType: reflect.TypeOf(&Rule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_RuleWithOperations, InType: reflect.TypeOf(&RuleWithOperations{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_ServiceReference, InType: reflect.TypeOf(&ServiceReference{})}, + ) +} + +// DeepCopy_v1alpha1_AdmissionHookClientConfig is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_AdmissionHookClientConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*AdmissionHookClientConfig) + out := out.(*AdmissionHookClientConfig) + *out = *in + if in.CABundle != nil { + in, out := &in.CABundle, &out.CABundle + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHook is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHook(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHook) + out := out.(*ExternalAdmissionHook) + *out = *in + if err := DeepCopy_v1alpha1_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, c); err != nil { + return err + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]RuleWithOperations, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_RuleWithOperations(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfiguration) + out := out.(*ExternalAdmissionHookConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.ExternalAdmissionHooks != nil { + in, out := &in.ExternalAdmissionHooks, &out.ExternalAdmissionHooks + *out = make([]ExternalAdmissionHook, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_ExternalAdmissionHook(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ExternalAdmissionHookConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfigurationList) + out := out.(*ExternalAdmissionHookConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ExternalAdmissionHookConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_ExternalAdmissionHookConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Initializer is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]Rule, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_Rule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_v1alpha1_InitializerConfiguration is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_InitializerConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfiguration) + out := out.(*InitializerConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + *out = make([]Initializer, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_Initializer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_InitializerConfigurationList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_InitializerConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfigurationList) + out := out.(*InitializerConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]InitializerConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_InitializerConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_Rule is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_Rule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Rule) + out := out.(*Rule) + *out = *in + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIVersions != nil { + in, out := &in.APIVersions, &out.APIVersions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1alpha1_RuleWithOperations is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_RuleWithOperations(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RuleWithOperations) + out := out.(*RuleWithOperations) + *out = *in + if in.Operations != nil { + in, out := &in.Operations, &out.Operations + *out = make([]OperationType, len(*in)) + copy(*out, *in) + } + if err := DeepCopy_v1alpha1_Rule(&in.Rule, &out.Rule, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1alpha1_ServiceReference is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_ServiceReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServiceReference) + out := out.(*ServiceReference) + *out = *in + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go new file mode 100644 index 0000000000..74fea7f418 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/v1alpha1/zz_generated.defaults.go @@ -0,0 +1,70 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&ExternalAdmissionHookConfiguration{}, func(obj interface{}) { + SetObjectDefaults_ExternalAdmissionHookConfiguration(obj.(*ExternalAdmissionHookConfiguration)) + }) + scheme.AddTypeDefaultingFunc(&ExternalAdmissionHookConfigurationList{}, func(obj interface{}) { + SetObjectDefaults_ExternalAdmissionHookConfigurationList(obj.(*ExternalAdmissionHookConfigurationList)) + }) + scheme.AddTypeDefaultingFunc(&InitializerConfiguration{}, func(obj interface{}) { SetObjectDefaults_InitializerConfiguration(obj.(*InitializerConfiguration)) }) + scheme.AddTypeDefaultingFunc(&InitializerConfigurationList{}, func(obj interface{}) { + SetObjectDefaults_InitializerConfigurationList(obj.(*InitializerConfigurationList)) + }) + return nil +} + +func SetObjectDefaults_ExternalAdmissionHookConfiguration(in *ExternalAdmissionHookConfiguration) { + for i := range in.ExternalAdmissionHooks { + a := &in.ExternalAdmissionHooks[i] + SetDefaults_ExternalAdmissionHook(a) + } +} + +func SetObjectDefaults_ExternalAdmissionHookConfigurationList(in *ExternalAdmissionHookConfigurationList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_ExternalAdmissionHookConfiguration(a) + } +} + +func SetObjectDefaults_InitializerConfiguration(in *InitializerConfiguration) { + for i := range in.Initializers { + a := &in.Initializers[i] + SetDefaults_Initializer(a) + } +} + +func SetObjectDefaults_InitializerConfigurationList(in *InitializerConfigurationList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_InitializerConfiguration(a) + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go new file mode 100644 index 0000000000..e41f28efa1 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/admissionregistration/zz_generated.deepcopy.go @@ -0,0 +1,254 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package admissionregistration + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_AdmissionHookClientConfig, InType: reflect.TypeOf(&AdmissionHookClientConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHook, InType: reflect.TypeOf(&ExternalAdmissionHook{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration, InType: reflect.TypeOf(&ExternalAdmissionHookConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList, InType: reflect.TypeOf(&ExternalAdmissionHookConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_Initializer, InType: reflect.TypeOf(&Initializer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_InitializerConfiguration, InType: reflect.TypeOf(&InitializerConfiguration{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_InitializerConfigurationList, InType: reflect.TypeOf(&InitializerConfigurationList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_Rule, InType: reflect.TypeOf(&Rule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_RuleWithOperations, InType: reflect.TypeOf(&RuleWithOperations{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_admissionregistration_ServiceReference, InType: reflect.TypeOf(&ServiceReference{})}, + ) +} + +// DeepCopy_admissionregistration_AdmissionHookClientConfig is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_AdmissionHookClientConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*AdmissionHookClientConfig) + out := out.(*AdmissionHookClientConfig) + *out = *in + if in.CABundle != nil { + in, out := &in.CABundle, &out.CABundle + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHook is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHook(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHook) + out := out.(*ExternalAdmissionHook) + *out = *in + if err := DeepCopy_admissionregistration_AdmissionHookClientConfig(&in.ClientConfig, &out.ClientConfig, c); err != nil { + return err + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]RuleWithOperations, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_RuleWithOperations(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfiguration) + out := out.(*ExternalAdmissionHookConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.ExternalAdmissionHooks != nil { + in, out := &in.ExternalAdmissionHooks, &out.ExternalAdmissionHooks + *out = make([]ExternalAdmissionHook, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_ExternalAdmissionHook(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ExternalAdmissionHookConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ExternalAdmissionHookConfigurationList) + out := out.(*ExternalAdmissionHookConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ExternalAdmissionHookConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_ExternalAdmissionHookConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_Initializer is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_Initializer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Initializer) + out := out.(*Initializer) + *out = *in + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]Rule, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_Rule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.FailurePolicy != nil { + in, out := &in.FailurePolicy, &out.FailurePolicy + *out = new(FailurePolicyType) + **out = **in + } + return nil + } +} + +// DeepCopy_admissionregistration_InitializerConfiguration is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_InitializerConfiguration(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfiguration) + out := out.(*InitializerConfiguration) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Initializers != nil { + in, out := &in.Initializers, &out.Initializers + *out = make([]Initializer, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_Initializer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_InitializerConfigurationList is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_InitializerConfigurationList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*InitializerConfigurationList) + out := out.(*InitializerConfigurationList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]InitializerConfiguration, len(*in)) + for i := range *in { + if err := DeepCopy_admissionregistration_InitializerConfiguration(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_admissionregistration_Rule is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_Rule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Rule) + out := out.(*Rule) + *out = *in + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIVersions != nil { + in, out := &in.APIVersions, &out.APIVersions + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_admissionregistration_RuleWithOperations is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_RuleWithOperations(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RuleWithOperations) + out := out.(*RuleWithOperations) + *out = *in + if in.Operations != nil { + in, out := &in.Operations, &out.Operations + *out = make([]OperationType, len(*in)) + copy(*out, *in) + } + if err := DeepCopy_admissionregistration_Rule(&in.Rule, &out.Rule, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_admissionregistration_ServiceReference is an autogenerated deepcopy function. +func DeepCopy_admissionregistration_ServiceReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ServiceReference) + out := out.(*ServiceReference) + *out = *in + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/BUILD b/vendor/k8s.io/client-go/pkg/apis/apps/BUILD new file mode 100644 index 0000000000..0e23b5a0e6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/apps/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/OWNERS b/vendor/k8s.io/client-go/pkg/apis/apps/OWNERS new file mode 100755 index 0000000000..1cdc56eec0 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/apps/OWNERS @@ -0,0 +1,21 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- deads2k +- caesarxuchao +- bprashanth +- pmorie +- sttts +- saad-ali +- ncdc +- timstclair +- timothysc +- dims +- errordeveloper +- mml +- m1093782566 +- mbohlool +- david-mcmahon +- kevin-wangzefeng +- jianhuiz diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/doc.go b/vendor/k8s.io/client-go/pkg/apis/apps/doc.go index 2f123702e3..d27cee51c2 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/doc.go @@ -14,8 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true -// +groupName=apps.k8s.io - package apps diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/install/install.go b/vendor/k8s.io/client-go/pkg/apis/apps/install/install.go deleted file mode 100644 index 3a9263d607..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/apps/install/install.go +++ /dev/null @@ -1,41 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the apps API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/apps" - "k8s.io/client-go/pkg/apis/apps/v1beta1" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: apps.GroupName, - VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/apps", - AddInternalObjectsToScheme: apps.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/register.go b/vendor/k8s.io/client-go/pkg/apis/apps/register.go index f791022298..1098ce0a3e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/register.go @@ -17,9 +17,9 @@ limitations under the License. package apps import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/client-go/pkg/apis/extensions" ) var ( @@ -31,15 +31,15 @@ var ( const GroupName = "apps" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -47,10 +47,14 @@ func Resource(resource string) unversioned.GroupResource { func addKnownTypes(scheme *runtime.Scheme) error { // TODO this will get cleaned up with the scheme types are fixed scheme.AddKnownTypes(SchemeGroupVersion, + &extensions.Deployment{}, + &extensions.DeploymentList{}, + &extensions.DeploymentRollback{}, + &extensions.Scale{}, &StatefulSet{}, &StatefulSetList{}, - &api.ListOptions{}, - &api.DeleteOptions{}, + &ControllerRevision{}, + &ControllerRevisionList{}, ) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/apps/types.generated.go deleted file mode 100644 index 391d2345b3..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/apps/types.generated.go +++ /dev/null @@ -1,1628 +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 apps - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/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 pkg2_api.ObjectMeta - var v1 pkg4_resource.Quantity - var v2 pkg1_unversioned.TypeMeta - var v3 pkg3_types.UID - var v4 pkg5_intstr.IntOrString - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 - } -} - -func (x *StatefulSet) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = true - yyq2[3] = true - yyq2[4] = true - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *StatefulSet) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl19, d) - } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl19, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *StatefulSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = StatefulSetSpec{} - } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = StatefulSetStatus{} - } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *StatefulSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = StatefulSetSpec{} - } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = StatefulSetStatus{} - } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *StatefulSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [5]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Replicas != 0 - yyq33[1] = x.Selector != nil - yyq33[3] = len(x.VolumeClaimTemplates) != 0 - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(5) - } else { - yynn33 = 2 - for _, b := range yyq33 { - if b { - yynn33++ - } - } - r.EncodeMapStart(yynn33) - yynn33 = 0 - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq33[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq33[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym39 := z.EncBinary() - _ = yym39 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy41 := &x.Template - yy41.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy42 := &x.Template - yy42.CodecEncodeSelf(e) - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[3] { - if x.VolumeClaimTemplates == nil { - r.EncodeNil() - } else { - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - h.encSliceapi_PersistentVolumeClaim(([]pkg2_api.PersistentVolumeClaim)(x.VolumeClaimTemplates), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq33[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumeClaimTemplates")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumeClaimTemplates == nil { - r.EncodeNil() - } else { - yym45 := z.EncBinary() - _ = yym45 - if false { - } else { - h.encSliceapi_PersistentVolumeClaim(([]pkg2_api.PersistentVolumeClaim)(x.VolumeClaimTemplates), e) - } - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("serviceName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym48 := z.EncBinary() - _ = yym48 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *StatefulSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym49 := z.DecBinary() - _ = yym49 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct50 := r.ContainerType() - if yyct50 == codecSelferValueTypeMap1234 { - yyl50 := r.ReadMapStart() - if yyl50 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl50, d) - } - } else if yyct50 == codecSelferValueTypeArray1234 { - yyl50 := r.ReadArrayStart() - if yyl50 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl50, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *StatefulSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys51Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys51Slc - var yyhl51 bool = l >= 0 - for yyj51 := 0; ; yyj51++ { - if yyhl51 { - if yyj51 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys51Slc = r.DecodeBytes(yys51Slc, true, true) - yys51 := string(yys51Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys51 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym54 := z.DecBinary() - _ = yym54 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv55 := &x.Template - yyv55.CodecDecodeSelf(d) - } - case "volumeClaimTemplates": - if r.TryDecodeAsNil() { - x.VolumeClaimTemplates = nil - } else { - yyv56 := &x.VolumeClaimTemplates - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - h.decSliceapi_PersistentVolumeClaim((*[]pkg2_api.PersistentVolumeClaim)(yyv56), d) - } - } - case "serviceName": - if r.TryDecodeAsNil() { - x.ServiceName = "" - } else { - x.ServiceName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys51) - } // end switch yys51 - } // end for yyj51 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *StatefulSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj59 int - var yyb59 bool - var yyhl59 bool = l >= 0 - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - 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(pkg1_unversioned.LabelSelector) - } - yym62 := z.DecBinary() - _ = yym62 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv63 := &x.Template - yyv63.CodecDecodeSelf(d) - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.VolumeClaimTemplates = nil - } else { - yyv64 := &x.VolumeClaimTemplates - yym65 := z.DecBinary() - _ = yym65 - if false { - } else { - h.decSliceapi_PersistentVolumeClaim((*[]pkg2_api.PersistentVolumeClaim)(yyv64), d) - } - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ServiceName = "" - } else { - x.ServiceName = string(r.DecodeString()) - } - for { - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj59-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *StatefulSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym67 := z.EncBinary() - _ = yym67 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep68 := !z.EncBinary() - yy2arr68 := z.EncBasicHandle().StructToArray - var yyq68 [2]bool - _, _, _ = yysep68, yyq68, yy2arr68 - const yyr68 bool = false - yyq68[0] = x.ObservedGeneration != nil - var yynn68 int - if yyr68 || yy2arr68 { - r.EncodeArrayStart(2) - } else { - yynn68 = 1 - for _, b := range yyq68 { - if b { - yynn68++ - } - } - r.EncodeMapStart(yynn68) - yynn68 = 0 - } - if yyr68 || yy2arr68 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq68[0] { - if x.ObservedGeneration == nil { - r.EncodeNil() - } else { - yy70 := *x.ObservedGeneration - yym71 := z.EncBinary() - _ = yym71 - if false { - } else { - r.EncodeInt(int64(yy70)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq68[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ObservedGeneration == nil { - r.EncodeNil() - } else { - yy72 := *x.ObservedGeneration - yym73 := z.EncBinary() - _ = yym73 - if false { - } else { - r.EncodeInt(int64(yy72)) - } - } - } - } - if yyr68 || yy2arr68 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym75 := z.EncBinary() - _ = yym75 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym76 := z.EncBinary() - _ = yym76 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr68 || yy2arr68 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *StatefulSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym77 := z.DecBinary() - _ = yym77 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct78 := r.ContainerType() - if yyct78 == codecSelferValueTypeMap1234 { - yyl78 := r.ReadMapStart() - if yyl78 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl78, d) - } - } else if yyct78 == codecSelferValueTypeArray1234 { - yyl78 := r.ReadArrayStart() - if yyl78 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl78, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *StatefulSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys79Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys79Slc - var yyhl79 bool = l >= 0 - for yyj79 := 0; ; yyj79++ { - if yyhl79 { - if yyj79 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys79Slc = r.DecodeBytes(yys79Slc, true, true) - yys79 := string(yys79Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys79 { - case "observedGeneration": - if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil - } - } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) - } - yym81 := z.DecBinary() - _ = yym81 - if false { - } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) - } - } - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys79) - } // end switch yys79 - } // end for yyj79 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *StatefulSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj83 int - var yyb83 bool - var yyhl83 bool = l >= 0 - yyj83++ - if yyhl83 { - yyb83 = yyj83 > l - } else { - yyb83 = r.CheckBreak() - } - if yyb83 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil - } - } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) - } - yym85 := z.DecBinary() - _ = yym85 - if false { - } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) - } - } - yyj83++ - if yyhl83 { - yyb83 = yyj83 > l - } else { - yyb83 = r.CheckBreak() - } - if yyb83 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - for { - yyj83++ - if yyhl83 { - yyb83 = yyj83 > l - } else { - yyb83 = r.CheckBreak() - } - if yyb83 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj83-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym87 := z.EncBinary() - _ = yym87 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep88 := !z.EncBinary() - yy2arr88 := z.EncBasicHandle().StructToArray - var yyq88 [4]bool - _, _, _ = yysep88, yyq88, yy2arr88 - const yyr88 bool = false - yyq88[0] = x.Kind != "" - yyq88[1] = x.APIVersion != "" - yyq88[2] = true - var yynn88 int - if yyr88 || yy2arr88 { - r.EncodeArrayStart(4) - } else { - yynn88 = 1 - for _, b := range yyq88 { - if b { - yynn88++ - } - } - r.EncodeMapStart(yynn88) - yynn88 = 0 - } - if yyr88 || yy2arr88 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq88[0] { - yym90 := z.EncBinary() - _ = yym90 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq88[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym91 := z.EncBinary() - _ = yym91 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr88 || yy2arr88 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq88[1] { - yym93 := z.EncBinary() - _ = yym93 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq88[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym94 := z.EncBinary() - _ = yym94 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr88 || yy2arr88 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq88[2] { - yy96 := &x.ListMeta - yym97 := z.EncBinary() - _ = yym97 - if false { - } else if z.HasExtensions() && z.EncExt(yy96) { - } else { - z.EncFallback(yy96) - } - } else { - r.EncodeNil() - } - } else { - if yyq88[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy98 := &x.ListMeta - yym99 := z.EncBinary() - _ = yym99 - if false { - } else if z.HasExtensions() && z.EncExt(yy98) { - } else { - z.EncFallback(yy98) - } - } - } - if yyr88 || yy2arr88 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym101 := z.EncBinary() - _ = yym101 - if false { - } else { - h.encSliceStatefulSet(([]StatefulSet)(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 { - yym102 := z.EncBinary() - _ = yym102 - if false { - } else { - h.encSliceStatefulSet(([]StatefulSet)(x.Items), e) - } - } - } - if yyr88 || yy2arr88 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *StatefulSetList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym103 := z.DecBinary() - _ = yym103 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct104 := r.ContainerType() - if yyct104 == codecSelferValueTypeMap1234 { - yyl104 := r.ReadMapStart() - if yyl104 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl104, d) - } - } else if yyct104 == codecSelferValueTypeArray1234 { - yyl104 := r.ReadArrayStart() - if yyl104 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl104, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *StatefulSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys105Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys105Slc - var yyhl105 bool = l >= 0 - for yyj105 := 0; ; yyj105++ { - if yyhl105 { - if yyj105 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys105Slc = r.DecodeBytes(yys105Slc, true, true) - yys105 := string(yys105Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys105 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv108 := &x.ListMeta - yym109 := z.DecBinary() - _ = yym109 - if false { - } else if z.HasExtensions() && z.DecExt(yyv108) { - } else { - z.DecFallback(yyv108, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv110 := &x.Items - yym111 := z.DecBinary() - _ = yym111 - if false { - } else { - h.decSliceStatefulSet((*[]StatefulSet)(yyv110), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys105) - } // end switch yys105 - } // end for yyj105 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *StatefulSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj112 int - var yyb112 bool - var yyhl112 bool = l >= 0 - yyj112++ - if yyhl112 { - yyb112 = yyj112 > l - } else { - yyb112 = r.CheckBreak() - } - if yyb112 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj112++ - if yyhl112 { - yyb112 = yyj112 > l - } else { - yyb112 = r.CheckBreak() - } - if yyb112 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj112++ - if yyhl112 { - yyb112 = yyj112 > l - } else { - yyb112 = r.CheckBreak() - } - if yyb112 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv115 := &x.ListMeta - yym116 := z.DecBinary() - _ = yym116 - if false { - } else if z.HasExtensions() && z.DecExt(yyv115) { - } else { - z.DecFallback(yyv115, false) - } - } - yyj112++ - if yyhl112 { - yyb112 = yyj112 > l - } else { - yyb112 = r.CheckBreak() - } - if yyb112 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv117 := &x.Items - yym118 := z.DecBinary() - _ = yym118 - if false { - } else { - h.decSliceStatefulSet((*[]StatefulSet)(yyv117), d) - } - } - for { - yyj112++ - if yyhl112 { - yyb112 = yyj112 > l - } else { - yyb112 = r.CheckBreak() - } - if yyb112 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj112-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceapi_PersistentVolumeClaim(v []pkg2_api.PersistentVolumeClaim, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv119 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy120 := &yyv119 - yy120.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceapi_PersistentVolumeClaim(v *[]pkg2_api.PersistentVolumeClaim, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv121 := *v - yyh121, yyl121 := z.DecSliceHelperStart() - var yyc121 bool - if yyl121 == 0 { - if yyv121 == nil { - yyv121 = []pkg2_api.PersistentVolumeClaim{} - yyc121 = true - } else if len(yyv121) != 0 { - yyv121 = yyv121[:0] - yyc121 = true - } - } else if yyl121 > 0 { - var yyrr121, yyrl121 int - var yyrt121 bool - if yyl121 > cap(yyv121) { - - yyrg121 := len(yyv121) > 0 - yyv2121 := yyv121 - yyrl121, yyrt121 = z.DecInferLen(yyl121, z.DecBasicHandle().MaxInitLen, 368) - if yyrt121 { - if yyrl121 <= cap(yyv121) { - yyv121 = yyv121[:yyrl121] - } else { - yyv121 = make([]pkg2_api.PersistentVolumeClaim, yyrl121) - } - } else { - yyv121 = make([]pkg2_api.PersistentVolumeClaim, yyrl121) - } - yyc121 = true - yyrr121 = len(yyv121) - if yyrg121 { - copy(yyv121, yyv2121) - } - } else if yyl121 != len(yyv121) { - yyv121 = yyv121[:yyl121] - yyc121 = true - } - yyj121 := 0 - for ; yyj121 < yyrr121; yyj121++ { - yyh121.ElemContainerState(yyj121) - if r.TryDecodeAsNil() { - yyv121[yyj121] = pkg2_api.PersistentVolumeClaim{} - } else { - yyv122 := &yyv121[yyj121] - yyv122.CodecDecodeSelf(d) - } - - } - if yyrt121 { - for ; yyj121 < yyl121; yyj121++ { - yyv121 = append(yyv121, pkg2_api.PersistentVolumeClaim{}) - yyh121.ElemContainerState(yyj121) - if r.TryDecodeAsNil() { - yyv121[yyj121] = pkg2_api.PersistentVolumeClaim{} - } else { - yyv123 := &yyv121[yyj121] - yyv123.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj121 := 0 - for ; !r.CheckBreak(); yyj121++ { - - if yyj121 >= len(yyv121) { - yyv121 = append(yyv121, pkg2_api.PersistentVolumeClaim{}) // var yyz121 pkg2_api.PersistentVolumeClaim - yyc121 = true - } - yyh121.ElemContainerState(yyj121) - if yyj121 < len(yyv121) { - if r.TryDecodeAsNil() { - yyv121[yyj121] = pkg2_api.PersistentVolumeClaim{} - } else { - yyv124 := &yyv121[yyj121] - yyv124.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj121 < len(yyv121) { - yyv121 = yyv121[:yyj121] - yyc121 = true - } else if yyj121 == 0 && yyv121 == nil { - yyv121 = []pkg2_api.PersistentVolumeClaim{} - yyc121 = true - } - } - yyh121.End() - if yyc121 { - *v = yyv121 - } -} - -func (x codecSelfer1234) encSliceStatefulSet(v []StatefulSet, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv125 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy126 := &yyv125 - yy126.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceStatefulSet(v *[]StatefulSet, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv127 := *v - yyh127, yyl127 := z.DecSliceHelperStart() - var yyc127 bool - if yyl127 == 0 { - if yyv127 == nil { - yyv127 = []StatefulSet{} - yyc127 = true - } else if len(yyv127) != 0 { - yyv127 = yyv127[:0] - yyc127 = true - } - } else if yyl127 > 0 { - var yyrr127, yyrl127 int - var yyrt127 bool - if yyl127 > cap(yyv127) { - - yyrg127 := len(yyv127) > 0 - yyv2127 := yyv127 - yyrl127, yyrt127 = z.DecInferLen(yyl127, z.DecBasicHandle().MaxInitLen, 776) - if yyrt127 { - if yyrl127 <= cap(yyv127) { - yyv127 = yyv127[:yyrl127] - } else { - yyv127 = make([]StatefulSet, yyrl127) - } - } else { - yyv127 = make([]StatefulSet, yyrl127) - } - yyc127 = true - yyrr127 = len(yyv127) - if yyrg127 { - copy(yyv127, yyv2127) - } - } else if yyl127 != len(yyv127) { - yyv127 = yyv127[:yyl127] - yyc127 = true - } - yyj127 := 0 - for ; yyj127 < yyrr127; yyj127++ { - yyh127.ElemContainerState(yyj127) - if r.TryDecodeAsNil() { - yyv127[yyj127] = StatefulSet{} - } else { - yyv128 := &yyv127[yyj127] - yyv128.CodecDecodeSelf(d) - } - - } - if yyrt127 { - for ; yyj127 < yyl127; yyj127++ { - yyv127 = append(yyv127, StatefulSet{}) - yyh127.ElemContainerState(yyj127) - if r.TryDecodeAsNil() { - yyv127[yyj127] = StatefulSet{} - } else { - yyv129 := &yyv127[yyj127] - yyv129.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj127 := 0 - for ; !r.CheckBreak(); yyj127++ { - - if yyj127 >= len(yyv127) { - yyv127 = append(yyv127, StatefulSet{}) // var yyz127 StatefulSet - yyc127 = true - } - yyh127.ElemContainerState(yyj127) - if yyj127 < len(yyv127) { - if r.TryDecodeAsNil() { - yyv127[yyj127] = StatefulSet{} - } else { - yyv130 := &yyv127[yyj127] - yyv130.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj127 < len(yyv127) { - yyv127 = yyv127[:yyj127] - yyc127 = true - } else if yyj127 == 0 && yyv127 == nil { - yyv127 = []StatefulSet{} - yyc127 = true - } - } - yyh127.End() - if yyc127 { - *v = yyv127 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/types.go b/vendor/k8s.io/client-go/pkg/apis/apps/types.go index 14b129fe4f..9691120eac 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/types.go @@ -17,8 +17,9 @@ limitations under the License. package apps import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" ) // +genclient=true @@ -30,18 +31,69 @@ import ( // The StatefulSet guarantees that a given network identity will always // map to the same storage identity. type StatefulSet struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the desired identities of pods in this set. // +optional - Spec StatefulSetSpec `json:"spec,omitempty"` + Spec StatefulSetSpec // Status is the current status of Pods in this StatefulSet. This data // may be out of date by some window of time. // +optional - Status StatefulSetStatus `json:"status,omitempty"` + Status StatefulSetStatus +} + +// PodManagementPolicyType defines the policy for creating pods under a stateful set. +type PodManagementPolicyType string + +const ( + // OrderedReadyPodManagement will create pods in strictly increasing order on + // scale up and strictly decreasing order on scale down, progressing only when + // the previous pod is ready or terminated. At most one pod will be changed + // at any time. + OrderedReadyPodManagement PodManagementPolicyType = "OrderedReady" + // ParallelPodManagement will create and delete pods as soon as the stateful set + // replica count is changed, and will not wait for pods to be ready or complete + // termination. + ParallelPodManagement = "Parallel" +) + +// StatefulSetUpdateStrategy indicates the strategy that the StatefulSet +// controller will use to perform updates. It includes any additional parameters +// necessary to perform the update for the indicated strategy. +type StatefulSetUpdateStrategy struct { + // Type indicates the type of the StatefulSetUpdateStrategy. + Type StatefulSetUpdateStrategyType + // RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. + RollingUpdate *RollingUpdateStatefulSetStrategy +} + +// StatefulSetUpdateStrategyType is a string enumeration type that enumerates +// all possible update strategies for the StatefulSet controller. +type StatefulSetUpdateStrategyType string + +const ( + // RollingUpdateStatefulSetStrategyType indicates that update will be + // applied to all Pods in the StatefulSet with respect to the StatefulSet + // ordering constraints. When a scale operation is performed with this + // strategy, new Pods will be created from the specification version indicated + // by the StatefulSet's updateRevision. + RollingUpdateStatefulSetStrategyType = "RollingUpdate" + // OnDeleteStatefulSetStrategyType triggers the legacy behavior. Version + // tracking and ordered rolling restarts are disabled. Pods are recreated + // from the StatefulSetSpec when they are manually deleted. When a scale + // operation is performed with this strategy,specification version indicated + // by the StatefulSet's currentRevision. + OnDeleteStatefulSetStrategyType = "OnDelete" +) + +// RollingUpdateStatefulSetStrategy is used to communicate parameter for RollingUpdateStatefulSetStrategyType. +type RollingUpdateStatefulSetStrategy struct { + // Partition indicates the ordinal at which the StatefulSet should be + // partitioned. + Partition int32 } // A StatefulSetSpec is the specification of a StatefulSet. @@ -52,19 +104,19 @@ type StatefulSetSpec struct { // If unspecified, defaults to 1. // TODO: Consider a rename of this field. // +optional - Replicas int32 `json:"replicas,omitempty"` + Replicas int32 // Selector is a label query over pods that should match the replica count. // If empty, defaulted to labels on the pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector // Template is the object that describes the pod that will be created if // insufficient replicas are detected. Each pod stamped out by the StatefulSet // will fulfill this Template, but have a unique identity from the rest // of the StatefulSet. - Template api.PodTemplateSpec `json:"template"` + Template api.PodTemplateSpec // VolumeClaimTemplates is a list of claims that pods are allowed to reference. // The StatefulSet controller is responsible for mapping network identities to @@ -74,30 +126,104 @@ type StatefulSetSpec struct { // any volumes in the template, with the same name. // TODO: Define the behavior if a claim already exists with the same name. // +optional - VolumeClaimTemplates []api.PersistentVolumeClaim `json:"volumeClaimTemplates,omitempty"` + VolumeClaimTemplates []api.PersistentVolumeClaim // ServiceName is the name of the service that governs this StatefulSet. // This service must exist before the StatefulSet, and is responsible for // the network identity of the set. Pods get DNS/hostnames that follow the // pattern: pod-specific-string.serviceName.default.svc.cluster.local // where "pod-specific-string" is managed by the StatefulSet controller. - ServiceName string `json:"serviceName"` + ServiceName string + + // PodManagementPolicy controls how pods are created during initial scale up, + // when replacing pods on nodes, or when scaling down. The default policy is + // `OrderedReady`, where pods are created in increasing order (pod-0, then + // pod-1, etc) and the controller will wait until each pod is ready before + // continuing. When scaling down, the pods are removed in the opposite order. + // The alternative policy is `Parallel` which will create pods in parallel + // to match the desired scale without waiting, and on scale down will delete + // all pods at once. + // +optional + PodManagementPolicy PodManagementPolicyType + + // updateStrategy indicates the StatefulSetUpdateStrategy that will be + // employed to update Pods in the StatefulSet when a revision is made to + // Template. + UpdateStrategy StatefulSetUpdateStrategy + + // revisionHistoryLimit is the maximum number of revisions that will + // be maintained in the StatefulSet's revision history. The revision history + // consists of all revisions not represented by a currently applied + // StatefulSetSpec version. The default value is 10. + RevisionHistoryLimit *int32 } // StatefulSetStatus represents the current state of a StatefulSet. type StatefulSetStatus struct { - // most recent generation observed by this autoscaler. + // observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the + // StatefulSet's generation, which is updated on mutation by the API Server. // +optional - ObservedGeneration *int64 `json:"observedGeneration,omitempty"` + ObservedGeneration *int64 + + // replicas is the number of Pods created by the StatefulSet controller. + Replicas int32 + + // readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition. + ReadyReplicas int32 + + // currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version + // indicated by currentRevision. + CurrentReplicas int32 + + // updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version + // indicated by updateRevision. + UpdatedReplicas int32 - // Replicas is the number of actual replicas. - Replicas int32 `json:"replicas"` + // currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the + // sequence [0,currentReplicas). + CurrentRevision string + + // updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence + // [replicas-updatedReplicas,replicas) + UpdateRevision string } // StatefulSetList is a collection of StatefulSets. type StatefulSetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta + // +optional + metav1.ListMeta + Items []StatefulSet +} + +// +genclient=true + +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. +type ControllerRevision struct { + metav1.TypeMeta + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` - Items []StatefulSet `json:"items"` + metav1.ObjectMeta + + // Data is the Object representing the state. + Data runtime.Object + + // Revision indicates the revision of the state represented by Data. + Revision int64 +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +type ControllerRevisionList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + // Items is the list of ControllerRevision objects. + Items []ControllerRevision } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/BUILD new file mode 100644 index 0000000000..80660ab3e7 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/BUILD @@ -0,0 +1,42 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/apps:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/conversion.go index caef334f17..66badd15fb 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/conversion.go @@ -19,12 +19,14 @@ package v1beta1 import ( "fmt" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" + "k8s.io/client-go/pkg/api/v1" "k8s.io/client-go/pkg/apis/apps" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" + "k8s.io/client-go/pkg/apis/extensions" ) func addConversionFuncs(scheme *runtime.Scheme) error { @@ -35,21 +37,51 @@ func addConversionFuncs(scheme *runtime.Scheme) error { err := scheme.AddConversionFuncs( Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec, Convert_apps_StatefulSetSpec_To_v1beta1_StatefulSetSpec, + Convert_v1beta1_StatefulSetUpdateStrategy_To_apps_StatefulSetUpdateStrategy, + Convert_apps_StatefulSetUpdateStrategy_To_v1beta1_StatefulSetUpdateStrategy, + // extensions + // TODO: below conversions should be dropped in favor of auto-generated + // ones, see https://github.com/kubernetes/kubernetextensionsssues/39865 + Convert_v1beta1_ScaleStatus_To_extensions_ScaleStatus, + Convert_extensions_ScaleStatus_To_v1beta1_ScaleStatus, + Convert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec, + Convert_extensions_DeploymentSpec_To_v1beta1_DeploymentSpec, + Convert_v1beta1_DeploymentStrategy_To_extensions_DeploymentStrategy, + Convert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy, + Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployment, + Convert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployment, ) if err != nil { return err } - return api.Scheme.AddFieldLabelConversionFunc("apps/v1beta1", "StatefulSet", + // Add field label conversions for kinds having selectable nothing but ObjectMeta fields. + err = scheme.AddFieldLabelConversionFunc("apps/v1beta1", "StatefulSet", func(label, value string) (string, string, error) { switch label { case "metadata.name", "metadata.namespace", "status.successful": return label, value, nil default: - return "", "", fmt.Errorf("field label not supported: %s", label) + return "", "", fmt.Errorf("field label not supported for StatefulSet: %s", label) } - }, - ) + }) + if err != nil { + return err + } + err = scheme.AddFieldLabelConversionFunc("apps/v1beta1", "Deployment", + func(label, value string) (string, string, error) { + switch label { + case "metadata.name", "metadata.namespace": + return label, value, nil + default: + return "", "", fmt.Errorf("field label %q not supported for Deployment", label) + } + }) + if err != nil { + return err + } + + return nil } func Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(in *StatefulSetSpec, out *apps.StatefulSetSpec, s conversion.Scope) error { @@ -58,7 +90,7 @@ func Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(in *StatefulSetSpec } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) + *out = new(metav1.LabelSelector) if err := s.Convert(*in, *out, 0); err != nil { return err } @@ -79,7 +111,17 @@ func Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(in *StatefulSetSpec } else { out.VolumeClaimTemplates = nil } + if err := Convert_v1beta1_StatefulSetUpdateStrategy_To_apps_StatefulSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, s); err != nil { + return err + } + if in.RevisionHistoryLimit != nil { + out.RevisionHistoryLimit = new(int32) + *out.RevisionHistoryLimit = *in.RevisionHistoryLimit + } else { + out.RevisionHistoryLimit = nil + } out.ServiceName = in.ServiceName + out.PodManagementPolicy = apps.PodManagementPolicyType(in.PodManagementPolicy) return nil } @@ -88,7 +130,7 @@ func Convert_apps_StatefulSetSpec_To_v1beta1_StatefulSetSpec(in *apps.StatefulSe *out.Replicas = in.Replicas if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) + *out = new(metav1.LabelSelector) if err := s.Convert(*in, *out, 0); err != nil { return err } @@ -109,6 +151,192 @@ func Convert_apps_StatefulSetSpec_To_v1beta1_StatefulSetSpec(in *apps.StatefulSe } else { out.VolumeClaimTemplates = nil } + if in.RevisionHistoryLimit != nil { + out.RevisionHistoryLimit = new(int32) + *out.RevisionHistoryLimit = *in.RevisionHistoryLimit + } else { + out.RevisionHistoryLimit = nil + } out.ServiceName = in.ServiceName + out.PodManagementPolicy = PodManagementPolicyType(in.PodManagementPolicy) + if err := Convert_apps_StatefulSetUpdateStrategy_To_v1beta1_StatefulSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, s); err != nil { + return err + } + return nil +} + +func Convert_v1beta1_StatefulSetUpdateStrategy_To_apps_StatefulSetUpdateStrategy(in *StatefulSetUpdateStrategy, out *apps.StatefulSetUpdateStrategy, s conversion.Scope) error { + out.Type = apps.StatefulSetUpdateStrategyType(in.Type) + if in.RollingUpdate != nil { + out.RollingUpdate = new(apps.RollingUpdateStatefulSetStrategy) + out.RollingUpdate.Partition = *in.RollingUpdate.Partition + } else { + out.RollingUpdate = nil + } + return nil +} + +func Convert_apps_StatefulSetUpdateStrategy_To_v1beta1_StatefulSetUpdateStrategy(in *apps.StatefulSetUpdateStrategy, out *StatefulSetUpdateStrategy, s conversion.Scope) error { + out.Type = StatefulSetUpdateStrategyType(in.Type) + if in.RollingUpdate != nil { + out.RollingUpdate = new(RollingUpdateStatefulSetStrategy) + out.RollingUpdate.Partition = new(int32) + *out.RollingUpdate.Partition = in.RollingUpdate.Partition + } else { + out.RollingUpdate = nil + } + return nil +} + +func Convert_extensions_ScaleStatus_To_v1beta1_ScaleStatus(in *extensions.ScaleStatus, out *ScaleStatus, s conversion.Scope) error { + out.Replicas = int32(in.Replicas) + + out.Selector = nil + out.TargetSelector = "" + if in.Selector != nil { + if in.Selector.MatchExpressions == nil || len(in.Selector.MatchExpressions) == 0 { + out.Selector = in.Selector.MatchLabels + } + + selector, err := metav1.LabelSelectorAsSelector(in.Selector) + if err != nil { + return fmt.Errorf("invalid label selector: %v", err) + } + out.TargetSelector = selector.String() + } + return nil +} + +func Convert_v1beta1_ScaleStatus_To_extensions_ScaleStatus(in *ScaleStatus, out *extensions.ScaleStatus, s conversion.Scope) error { + out.Replicas = in.Replicas + + // Normally when 2 fields map to the same internal value we favor the old field, since + // old clients can't be expected to know about new fields but clients that know about the + // new field can be expected to know about the old field (though that's not quite true, due + // to kubectl apply). However, these fields are readonly, so any non-nil value should work. + if in.TargetSelector != "" { + labelSelector, err := metav1.ParseToLabelSelector(in.TargetSelector) + if err != nil { + out.Selector = nil + return fmt.Errorf("failed to parse target selector: %v", err) + } + out.Selector = labelSelector + } else if in.Selector != nil { + out.Selector = new(metav1.LabelSelector) + selector := make(map[string]string) + for key, val := range in.Selector { + selector[key] = val + } + out.Selector.MatchLabels = selector + } else { + out.Selector = nil + } + return nil +} + +func Convert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec(in *DeploymentSpec, out *extensions.DeploymentSpec, s conversion.Scope) error { + if in.Replicas != nil { + out.Replicas = *in.Replicas + } + out.Selector = in.Selector + if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + return err + } + if err := Convert_v1beta1_DeploymentStrategy_To_extensions_DeploymentStrategy(&in.Strategy, &out.Strategy, s); err != nil { + return err + } + out.RevisionHistoryLimit = in.RevisionHistoryLimit + out.MinReadySeconds = in.MinReadySeconds + out.Paused = in.Paused + if in.RollbackTo != nil { + out.RollbackTo = new(extensions.RollbackConfig) + out.RollbackTo.Revision = in.RollbackTo.Revision + } else { + out.RollbackTo = nil + } + if in.ProgressDeadlineSeconds != nil { + out.ProgressDeadlineSeconds = new(int32) + *out.ProgressDeadlineSeconds = *in.ProgressDeadlineSeconds + } + return nil +} + +func Convert_extensions_DeploymentSpec_To_v1beta1_DeploymentSpec(in *extensions.DeploymentSpec, out *DeploymentSpec, s conversion.Scope) error { + out.Replicas = &in.Replicas + out.Selector = in.Selector + if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + return err + } + if err := Convert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy(&in.Strategy, &out.Strategy, s); err != nil { + return err + } + if in.RevisionHistoryLimit != nil { + out.RevisionHistoryLimit = new(int32) + *out.RevisionHistoryLimit = int32(*in.RevisionHistoryLimit) + } + out.MinReadySeconds = int32(in.MinReadySeconds) + out.Paused = in.Paused + if in.RollbackTo != nil { + out.RollbackTo = new(RollbackConfig) + out.RollbackTo.Revision = int64(in.RollbackTo.Revision) + } else { + out.RollbackTo = nil + } + if in.ProgressDeadlineSeconds != nil { + out.ProgressDeadlineSeconds = new(int32) + *out.ProgressDeadlineSeconds = *in.ProgressDeadlineSeconds + } + return nil +} + +func Convert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy(in *extensions.DeploymentStrategy, out *DeploymentStrategy, s conversion.Scope) error { + out.Type = DeploymentStrategyType(in.Type) + if in.RollingUpdate != nil { + out.RollingUpdate = new(RollingUpdateDeployment) + if err := Convert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployment(in.RollingUpdate, out.RollingUpdate, s); err != nil { + return err + } + } else { + out.RollingUpdate = nil + } + return nil +} + +func Convert_v1beta1_DeploymentStrategy_To_extensions_DeploymentStrategy(in *DeploymentStrategy, out *extensions.DeploymentStrategy, s conversion.Scope) error { + out.Type = extensions.DeploymentStrategyType(in.Type) + if in.RollingUpdate != nil { + out.RollingUpdate = new(extensions.RollingUpdateDeployment) + if err := Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployment(in.RollingUpdate, out.RollingUpdate, s); err != nil { + return err + } + } else { + out.RollingUpdate = nil + } + return nil +} + +func Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployment(in *RollingUpdateDeployment, out *extensions.RollingUpdateDeployment, s conversion.Scope) error { + if err := s.Convert(in.MaxUnavailable, &out.MaxUnavailable, 0); err != nil { + return err + } + if err := s.Convert(in.MaxSurge, &out.MaxSurge, 0); err != nil { + return err + } + return nil +} + +func Convert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployment(in *extensions.RollingUpdateDeployment, out *RollingUpdateDeployment, s conversion.Scope) error { + if out.MaxUnavailable == nil { + out.MaxUnavailable = &intstr.IntOrString{} + } + if err := s.Convert(&in.MaxUnavailable, out.MaxUnavailable, 0); err != nil { + return err + } + if out.MaxSurge == nil { + out.MaxSurge = &intstr.IntOrString{} + } + if err := s.Convert(&in.MaxSurge, out.MaxSurge, 0); err != nil { + return err + } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/defaults.go index cfe7fed0dc..af133d25fd 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/defaults.go @@ -17,22 +17,27 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_StatefulSet, - ) + return RegisterDefaults(scheme) } func SetDefaults_StatefulSet(obj *StatefulSet) { + if len(obj.Spec.PodManagementPolicy) == 0 { + obj.Spec.PodManagementPolicy = OrderedReadyPodManagement + } + + if obj.Spec.UpdateStrategy.Type == "" { + obj.Spec.UpdateStrategy.Type = OnDeleteStatefulSetStrategyType + } labels := obj.Spec.Template.Labels if labels != nil { if obj.Spec.Selector == nil { - obj.Spec.Selector = &unversioned.LabelSelector{ + obj.Spec.Selector = &metav1.LabelSelector{ MatchLabels: labels, } } @@ -44,4 +49,69 @@ func SetDefaults_StatefulSet(obj *StatefulSet) { obj.Spec.Replicas = new(int32) *obj.Spec.Replicas = 1 } + if obj.Spec.RevisionHistoryLimit == nil { + obj.Spec.RevisionHistoryLimit = new(int32) + *obj.Spec.RevisionHistoryLimit = 10 + } + if obj.Spec.UpdateStrategy.Type == RollingUpdateStatefulSetStrategyType && + obj.Spec.UpdateStrategy.RollingUpdate != nil && + obj.Spec.UpdateStrategy.RollingUpdate.Partition == nil { + obj.Spec.UpdateStrategy.RollingUpdate.Partition = new(int32) + *obj.Spec.UpdateStrategy.RollingUpdate.Partition = 0 + } + +} + +// SetDefaults_Deployment sets additional defaults compared to its counterpart +// in extensions. These addons are: +// - MaxUnavailable during rolling update set to 25% (1 in extensions) +// - MaxSurge value during rolling update set to 25% (1 in extensions) +// - RevisionHistoryLimit set to 2 (not set in extensions) +// - ProgressDeadlineSeconds set to 600s (not set in extensions) +func SetDefaults_Deployment(obj *Deployment) { + // Default labels and selector to labels from pod template spec. + labels := obj.Spec.Template.Labels + + if labels != nil { + if obj.Spec.Selector == nil { + obj.Spec.Selector = &metav1.LabelSelector{MatchLabels: labels} + } + if len(obj.Labels) == 0 { + obj.Labels = labels + } + } + // Set DeploymentSpec.Replicas to 1 if it is not set. + if obj.Spec.Replicas == nil { + obj.Spec.Replicas = new(int32) + *obj.Spec.Replicas = 1 + } + strategy := &obj.Spec.Strategy + // Set default DeploymentStrategyType as RollingUpdate. + if strategy.Type == "" { + strategy.Type = RollingUpdateDeploymentStrategyType + } + if strategy.Type == RollingUpdateDeploymentStrategyType { + if strategy.RollingUpdate == nil { + rollingUpdate := RollingUpdateDeployment{} + strategy.RollingUpdate = &rollingUpdate + } + if strategy.RollingUpdate.MaxUnavailable == nil { + // Set default MaxUnavailable as 25% by default. + maxUnavailable := intstr.FromString("25%") + strategy.RollingUpdate.MaxUnavailable = &maxUnavailable + } + if strategy.RollingUpdate.MaxSurge == nil { + // Set default MaxSurge as 25% by default. + maxSurge := intstr.FromString("25%") + strategy.RollingUpdate.MaxSurge = &maxSurge + } + } + if obj.Spec.RevisionHistoryLimit == nil { + obj.Spec.RevisionHistoryLimit = new(int32) + *obj.Spec.RevisionHistoryLimit = 2 + } + if obj.Spec.ProgressDeadlineSeconds == nil { + obj.Spec.ProgressDeadlineSeconds = new(int32) + *obj.Spec.ProgressDeadlineSeconds = 600 + } } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/doc.go index 6e3d417615..a397b30e92 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/doc.go @@ -14,10 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/apps -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta -// +groupName=apps.k8s.io - package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go index a495ee6343..9f7395c8f9 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -25,10 +25,26 @@ limitations under the License. k8s.io/kubernetes/pkg/apis/apps/v1beta1/generated.proto It has these top-level messages: + ControllerRevision + ControllerRevisionList + Deployment + DeploymentCondition + DeploymentList + DeploymentRollback + DeploymentSpec + DeploymentStatus + DeploymentStrategy + RollbackConfig + RollingUpdateDeployment + RollingUpdateStatefulSetStrategy + Scale + ScaleSpec + ScaleStatus StatefulSet StatefulSetList StatefulSetSpec StatefulSetStatus + StatefulSetUpdateStrategy */ package v1beta1 @@ -36,9 +52,13 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + import strings "strings" import reflect "reflect" @@ -51,101 +71,314 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *ControllerRevision) Reset() { *m = ControllerRevision{} } +func (*ControllerRevision) ProtoMessage() {} +func (*ControllerRevision) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *ControllerRevisionList) Reset() { *m = ControllerRevisionList{} } +func (*ControllerRevisionList) ProtoMessage() {} +func (*ControllerRevisionList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *Deployment) Reset() { *m = Deployment{} } +func (*Deployment) ProtoMessage() {} +func (*Deployment) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *DeploymentCondition) Reset() { *m = DeploymentCondition{} } +func (*DeploymentCondition) ProtoMessage() {} +func (*DeploymentCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *DeploymentList) Reset() { *m = DeploymentList{} } +func (*DeploymentList) ProtoMessage() {} +func (*DeploymentList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *DeploymentRollback) Reset() { *m = DeploymentRollback{} } +func (*DeploymentRollback) ProtoMessage() {} +func (*DeploymentRollback) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func (m *DeploymentSpec) Reset() { *m = DeploymentSpec{} } +func (*DeploymentSpec) ProtoMessage() {} +func (*DeploymentSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } + +func (m *DeploymentStatus) Reset() { *m = DeploymentStatus{} } +func (*DeploymentStatus) ProtoMessage() {} +func (*DeploymentStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *DeploymentStrategy) Reset() { *m = DeploymentStrategy{} } +func (*DeploymentStrategy) ProtoMessage() {} +func (*DeploymentStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *RollbackConfig) Reset() { *m = RollbackConfig{} } +func (*RollbackConfig) ProtoMessage() {} +func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func (m *RollingUpdateDeployment) Reset() { *m = RollingUpdateDeployment{} } +func (*RollingUpdateDeployment) ProtoMessage() {} +func (*RollingUpdateDeployment) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{10} +} + +func (m *RollingUpdateStatefulSetStrategy) Reset() { *m = RollingUpdateStatefulSetStrategy{} } +func (*RollingUpdateStatefulSetStrategy) ProtoMessage() {} +func (*RollingUpdateStatefulSetStrategy) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{11} +} + +func (m *Scale) Reset() { *m = Scale{} } +func (*Scale) ProtoMessage() {} +func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } + +func (m *ScaleSpec) Reset() { *m = ScaleSpec{} } +func (*ScaleSpec) ProtoMessage() {} +func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } + +func (m *ScaleStatus) Reset() { *m = ScaleStatus{} } +func (*ScaleStatus) ProtoMessage() {} +func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } func (m *StatefulSet) Reset() { *m = StatefulSet{} } func (*StatefulSet) ProtoMessage() {} -func (*StatefulSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } +func (*StatefulSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } func (m *StatefulSetList) Reset() { *m = StatefulSetList{} } func (*StatefulSetList) ProtoMessage() {} -func (*StatefulSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } +func (*StatefulSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } func (m *StatefulSetSpec) Reset() { *m = StatefulSetSpec{} } func (*StatefulSetSpec) ProtoMessage() {} -func (*StatefulSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } +func (*StatefulSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } func (m *StatefulSetStatus) Reset() { *m = StatefulSetStatus{} } func (*StatefulSetStatus) ProtoMessage() {} -func (*StatefulSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } +func (*StatefulSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} } + +func (m *StatefulSetUpdateStrategy) Reset() { *m = StatefulSetUpdateStrategy{} } +func (*StatefulSetUpdateStrategy) ProtoMessage() {} +func (*StatefulSetUpdateStrategy) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{19} +} func init() { + proto.RegisterType((*ControllerRevision)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.ControllerRevision") + proto.RegisterType((*ControllerRevisionList)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.ControllerRevisionList") + proto.RegisterType((*Deployment)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.Deployment") + proto.RegisterType((*DeploymentCondition)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentCondition") + proto.RegisterType((*DeploymentList)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentList") + proto.RegisterType((*DeploymentRollback)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentRollback") + proto.RegisterType((*DeploymentSpec)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentSpec") + proto.RegisterType((*DeploymentStatus)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentStatus") + proto.RegisterType((*DeploymentStrategy)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.DeploymentStrategy") + proto.RegisterType((*RollbackConfig)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.RollbackConfig") + proto.RegisterType((*RollingUpdateDeployment)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.RollingUpdateDeployment") + proto.RegisterType((*RollingUpdateStatefulSetStrategy)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.RollingUpdateStatefulSetStrategy") + proto.RegisterType((*Scale)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.Scale") + proto.RegisterType((*ScaleSpec)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.ScaleSpec") + proto.RegisterType((*ScaleStatus)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.ScaleStatus") proto.RegisterType((*StatefulSet)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSet") proto.RegisterType((*StatefulSetList)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSetList") proto.RegisterType((*StatefulSetSpec)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSetSpec") proto.RegisterType((*StatefulSetStatus)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSetStatus") + proto.RegisterType((*StatefulSetUpdateStrategy)(nil), "k8s.io.client-go.pkg.apis.apps.v1beta1.StatefulSetUpdateStrategy") } -func (m *StatefulSet) Marshal() (data []byte, err error) { +func (m *ControllerRevision) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *StatefulSet) MarshalTo(data []byte) (int, error) { +func (m *ControllerRevision) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Data.Size())) + n2, err := m.Data.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Revision)) + return i, nil +} + +func (m *ControllerRevisionList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ControllerRevisionList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } return i, nil } -func (m *StatefulSetList) Marshal() (data []byte, err error) { +func (m *Deployment) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *StatefulSetList) MarshalTo(data []byte) (int, error) { +func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n4, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n5, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n6, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + return i, nil +} + +func (m *DeploymentCondition) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DeploymentCondition) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LastUpdateTime.Size())) + n7, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + dAtA[i] = 0x3a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n8, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 + return i, nil +} + +func (m *DeploymentList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DeploymentList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n9, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -155,246 +388,3738 @@ func (m *StatefulSetList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *StatefulSetSpec) Marshal() (data []byte, err error) { +func (m *DeploymentRollback) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DeploymentRollback) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if len(m.UpdatedAnnotations) > 0 { + keysForUpdatedAnnotations := make([]string, 0, len(m.UpdatedAnnotations)) + for k := range m.UpdatedAnnotations { + keysForUpdatedAnnotations = append(keysForUpdatedAnnotations, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForUpdatedAnnotations) + for _, k := range keysForUpdatedAnnotations { + dAtA[i] = 0x12 + i++ + v := m.UpdatedAnnotations[string(k)] + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) + n10, err := m.RollbackTo.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + return i, nil +} + +func (m *DeploymentSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *StatefulSetSpec) MarshalTo(data []byte) (int, error) { +func (m *DeploymentSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Replicas != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Replicas)) } if m.Selector != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n5, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n11, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n5 + i += n11 } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n6, err := m.Template.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n12, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n6 - if len(m.VolumeClaimTemplates) > 0 { - for _, msg := range m.VolumeClaimTemplates { - data[i] = 0x22 + i += n12 + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Strategy.Size())) + n13, err := m.Strategy.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n13 + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) + if m.RevisionHistoryLimit != nil { + dAtA[i] = 0x30 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.RevisionHistoryLimit)) + } + dAtA[i] = 0x38 + i++ + if m.Paused { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + if m.RollbackTo != nil { + dAtA[i] = 0x42 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) + n14, err := m.RollbackTo.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n14 + } + if m.ProgressDeadlineSeconds != nil { + dAtA[i] = 0x48 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.ProgressDeadlineSeconds)) + } + return i, nil +} + +func (m *DeploymentStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DeploymentStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObservedGeneration)) + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.UpdatedReplicas)) + dAtA[i] = 0x20 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.AvailableReplicas)) + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.UnavailableReplicas)) + if len(m.Conditions) > 0 { + for _, msg := range m.Conditions { + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x2a + dAtA[i] = 0x38 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ServiceName))) - i += copy(data[i:], m.ServiceName) + i = encodeVarintGenerated(dAtA, i, uint64(m.ReadyReplicas)) + if m.CollisionCount != nil { + dAtA[i] = 0x40 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.CollisionCount)) + } return i, nil } -func (m *StatefulSetStatus) Marshal() (data []byte, err error) { +func (m *DeploymentStrategy) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *StatefulSetStatus) MarshalTo(data []byte) (int, error) { +func (m *DeploymentStrategy) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - if m.ObservedGeneration != nil { - data[i] = 0x8 + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.RollingUpdate != nil { + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(*m.ObservedGeneration)) + i = encodeVarintGenerated(dAtA, i, uint64(m.RollingUpdate.Size())) + n15, err := m.RollingUpdate.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n15 } - data[i] = 0x10 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) - return offset + 8 -} -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - return offset + 4 -} -func encodeVarintGenerated(data []byte, offset int, v uint64) int { - for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ +func (m *RollbackConfig) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - data[offset] = uint8(v) - return offset + 1 + return dAtA[:n], nil } -func (m *StatefulSet) Size() (n int) { + +func (m *RollbackConfig) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Revision)) + return i, nil } -func (m *StatefulSetList) Size() (n int) { - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } +func (m *RollingUpdateDeployment) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func (m *StatefulSetSpec) Size() (n int) { +func (m *RollingUpdateDeployment) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - if m.Replicas != nil { - n += 1 + sovGenerated(uint64(*m.Replicas)) - } - if m.Selector != nil { - l = m.Selector.Size() - n += 1 + l + sovGenerated(uint64(l)) + if m.MaxUnavailable != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxUnavailable.Size())) + n16, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n16 } - l = m.Template.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.VolumeClaimTemplates) > 0 { - for _, e := range m.VolumeClaimTemplates { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) + if m.MaxSurge != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxSurge.Size())) + n17, err := m.MaxSurge.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n17 } - l = len(m.ServiceName) - n += 1 + l + sovGenerated(uint64(l)) - return n + return i, nil } -func (m *StatefulSetStatus) Size() (n int) { +func (m *RollingUpdateStatefulSetStrategy) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RollingUpdateStatefulSetStrategy) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i var l int _ = l - if m.ObservedGeneration != nil { - n += 1 + sovGenerated(uint64(*m.ObservedGeneration)) + if m.Partition != nil { + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.Partition)) } - n += 1 + sovGenerated(uint64(m.Replicas)) - return n + return i, nil } -func sovGenerated(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } +func (m *Scale) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - return n + return dAtA[:n], nil } -func sozGenerated(x uint64) (n int) { - return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) + +func (m *Scale) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n18, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n18 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n19, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n19 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n20, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n20 + return i, nil } -func (this *StatefulSet) String() string { - if this == nil { - return "nil" + +func (m *ScaleSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - s := strings.Join([]string{`&StatefulSet{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "StatefulSetSpec", "StatefulSetSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "StatefulSetStatus", "StatefulSetStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + return dAtA[:n], nil } -func (this *StatefulSetList) String() string { - if this == nil { - return "nil" + +func (m *ScaleSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + return i, nil +} + +func (m *ScaleStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err } - s := strings.Join([]string{`&StatefulSetList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "StatefulSet", "StatefulSet", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s + return dAtA[:n], nil } -func (this *StatefulSetSpec) String() string { - if this == nil { - return "nil" + +func (m *ScaleStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + if len(m.Selector) > 0 { + keysForSelector := make([]string, 0, len(m.Selector)) + for k := range m.Selector { + keysForSelector = append(keysForSelector, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForSelector) + for _, k := range keysForSelector { + dAtA[i] = 0x12 + i++ + v := m.Selector[string(k)] + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TargetSelector))) + i += copy(dAtA[i:], m.TargetSelector) + return i, nil +} + +func (m *StatefulSet) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatefulSet) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n21, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n21 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n22, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n22 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n23, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n23 + return i, nil +} + +func (m *StatefulSetList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatefulSetList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n24, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n24 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *StatefulSetSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatefulSetSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.Replicas != nil { + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.Replicas)) + } + if m.Selector != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n25, err := m.Selector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n25 + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n26, err := m.Template.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n26 + if len(m.VolumeClaimTemplates) > 0 { + for _, msg := range m.VolumeClaimTemplates { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ServiceName))) + i += copy(dAtA[i:], m.ServiceName) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.PodManagementPolicy))) + i += copy(dAtA[i:], m.PodManagementPolicy) + dAtA[i] = 0x3a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.UpdateStrategy.Size())) + n27, err := m.UpdateStrategy.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n27 + if m.RevisionHistoryLimit != nil { + dAtA[i] = 0x40 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.RevisionHistoryLimit)) + } + return i, nil +} + +func (m *StatefulSetStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatefulSetStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.ObservedGeneration != nil { + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.ObservedGeneration)) + } + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ReadyReplicas)) + dAtA[i] = 0x20 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentReplicas)) + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.UpdatedReplicas)) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.CurrentRevision))) + i += copy(dAtA[i:], m.CurrentRevision) + dAtA[i] = 0x3a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UpdateRevision))) + i += copy(dAtA[i:], m.UpdateRevision) + return i, nil +} + +func (m *StatefulSetUpdateStrategy) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StatefulSetUpdateStrategy) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.RollingUpdate != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RollingUpdate.Size())) + n28, err := m.RollingUpdate.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n28 + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *ControllerRevision) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Data.Size() + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.Revision)) + return n +} + +func (m *ControllerRevisionList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *Deployment) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *DeploymentCondition) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Status) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Reason) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Message) + n += 1 + l + sovGenerated(uint64(l)) + l = m.LastUpdateTime.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.LastTransitionTime.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *DeploymentList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *DeploymentRollback) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.UpdatedAnnotations) > 0 { + for k, v := range m.UpdatedAnnotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + l = m.RollbackTo.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *DeploymentSpec) Size() (n int) { + var l int + _ = l + if m.Replicas != nil { + n += 1 + sovGenerated(uint64(*m.Replicas)) + } + if m.Selector != nil { + l = m.Selector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + l = m.Template.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Strategy.Size() + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.MinReadySeconds)) + if m.RevisionHistoryLimit != nil { + n += 1 + sovGenerated(uint64(*m.RevisionHistoryLimit)) + } + n += 2 + if m.RollbackTo != nil { + l = m.RollbackTo.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.ProgressDeadlineSeconds != nil { + n += 1 + sovGenerated(uint64(*m.ProgressDeadlineSeconds)) + } + return n +} + +func (m *DeploymentStatus) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.ObservedGeneration)) + n += 1 + sovGenerated(uint64(m.Replicas)) + n += 1 + sovGenerated(uint64(m.UpdatedReplicas)) + n += 1 + sovGenerated(uint64(m.AvailableReplicas)) + n += 1 + sovGenerated(uint64(m.UnavailableReplicas)) + if len(m.Conditions) > 0 { + for _, e := range m.Conditions { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + n += 1 + sovGenerated(uint64(m.ReadyReplicas)) + if m.CollisionCount != nil { + n += 1 + sovGenerated(uint64(*m.CollisionCount)) + } + return n +} + +func (m *DeploymentStrategy) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + if m.RollingUpdate != nil { + l = m.RollingUpdate.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *RollbackConfig) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Revision)) + return n +} + +func (m *RollingUpdateDeployment) Size() (n int) { + var l int + _ = l + if m.MaxUnavailable != nil { + l = m.MaxUnavailable.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.MaxSurge != nil { + l = m.MaxSurge.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *RollingUpdateStatefulSetStrategy) Size() (n int) { + var l int + _ = l + if m.Partition != nil { + n += 1 + sovGenerated(uint64(*m.Partition)) + } + return n +} + +func (m *Scale) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ScaleSpec) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Replicas)) + return n +} + +func (m *ScaleStatus) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Replicas)) + if len(m.Selector) > 0 { + for k, v := range m.Selector { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + l = len(m.TargetSelector) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *StatefulSet) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *StatefulSetList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *StatefulSetSpec) Size() (n int) { + var l int + _ = l + if m.Replicas != nil { + n += 1 + sovGenerated(uint64(*m.Replicas)) + } + if m.Selector != nil { + l = m.Selector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + l = m.Template.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.VolumeClaimTemplates) > 0 { + for _, e := range m.VolumeClaimTemplates { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = len(m.ServiceName) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.PodManagementPolicy) + n += 1 + l + sovGenerated(uint64(l)) + l = m.UpdateStrategy.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.RevisionHistoryLimit != nil { + n += 1 + sovGenerated(uint64(*m.RevisionHistoryLimit)) + } + return n +} + +func (m *StatefulSetStatus) Size() (n int) { + var l int + _ = l + if m.ObservedGeneration != nil { + n += 1 + sovGenerated(uint64(*m.ObservedGeneration)) + } + n += 1 + sovGenerated(uint64(m.Replicas)) + n += 1 + sovGenerated(uint64(m.ReadyReplicas)) + n += 1 + sovGenerated(uint64(m.CurrentReplicas)) + n += 1 + sovGenerated(uint64(m.UpdatedReplicas)) + l = len(m.CurrentRevision) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.UpdateRevision) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *StatefulSetUpdateStrategy) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + if m.RollingUpdate != nil { + l = m.RollingUpdate.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *ControllerRevision) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ControllerRevision{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Data:` + strings.Replace(strings.Replace(this.Data.String(), "RawExtension", "k8s_io_apimachinery_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, + `Revision:` + fmt.Sprintf("%v", this.Revision) + `,`, + `}`, + }, "") + return s +} +func (this *ControllerRevisionList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ControllerRevisionList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ControllerRevision", "ControllerRevision", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Deployment) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Deployment{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DeploymentSpec", "DeploymentSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DeploymentStatus", "DeploymentStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DeploymentCondition) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeploymentCondition{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Status:` + fmt.Sprintf("%v", this.Status) + `,`, + `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, + `Message:` + fmt.Sprintf("%v", this.Message) + `,`, + `LastUpdateTime:` + strings.Replace(strings.Replace(this.LastUpdateTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DeploymentList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeploymentList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Deployment", "Deployment", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DeploymentRollback) String() string { + if this == nil { + return "nil" + } + keysForUpdatedAnnotations := make([]string, 0, len(this.UpdatedAnnotations)) + for k := range this.UpdatedAnnotations { + keysForUpdatedAnnotations = append(keysForUpdatedAnnotations, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForUpdatedAnnotations) + mapStringForUpdatedAnnotations := "map[string]string{" + for _, k := range keysForUpdatedAnnotations { + mapStringForUpdatedAnnotations += fmt.Sprintf("%v: %v,", k, this.UpdatedAnnotations[k]) + } + mapStringForUpdatedAnnotations += "}" + s := strings.Join([]string{`&DeploymentRollback{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `UpdatedAnnotations:` + mapStringForUpdatedAnnotations + `,`, + `RollbackTo:` + strings.Replace(strings.Replace(this.RollbackTo.String(), "RollbackConfig", "RollbackConfig", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *DeploymentSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeploymentSpec{`, + `Replicas:` + valueToStringGenerated(this.Replicas) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, + `Strategy:` + strings.Replace(strings.Replace(this.Strategy.String(), "DeploymentStrategy", "DeploymentStrategy", 1), `&`, ``, 1) + `,`, + `MinReadySeconds:` + fmt.Sprintf("%v", this.MinReadySeconds) + `,`, + `RevisionHistoryLimit:` + valueToStringGenerated(this.RevisionHistoryLimit) + `,`, + `Paused:` + fmt.Sprintf("%v", this.Paused) + `,`, + `RollbackTo:` + strings.Replace(fmt.Sprintf("%v", this.RollbackTo), "RollbackConfig", "RollbackConfig", 1) + `,`, + `ProgressDeadlineSeconds:` + valueToStringGenerated(this.ProgressDeadlineSeconds) + `,`, + `}`, + }, "") + return s +} +func (this *DeploymentStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeploymentStatus{`, + `ObservedGeneration:` + fmt.Sprintf("%v", this.ObservedGeneration) + `,`, + `Replicas:` + fmt.Sprintf("%v", this.Replicas) + `,`, + `UpdatedReplicas:` + fmt.Sprintf("%v", this.UpdatedReplicas) + `,`, + `AvailableReplicas:` + fmt.Sprintf("%v", this.AvailableReplicas) + `,`, + `UnavailableReplicas:` + fmt.Sprintf("%v", this.UnavailableReplicas) + `,`, + `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "DeploymentCondition", "DeploymentCondition", 1), `&`, ``, 1) + `,`, + `ReadyReplicas:` + fmt.Sprintf("%v", this.ReadyReplicas) + `,`, + `CollisionCount:` + valueToStringGenerated(this.CollisionCount) + `,`, + `}`, + }, "") + return s +} +func (this *DeploymentStrategy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DeploymentStrategy{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `RollingUpdate:` + strings.Replace(fmt.Sprintf("%v", this.RollingUpdate), "RollingUpdateDeployment", "RollingUpdateDeployment", 1) + `,`, + `}`, + }, "") + return s +} +func (this *RollbackConfig) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RollbackConfig{`, + `Revision:` + fmt.Sprintf("%v", this.Revision) + `,`, + `}`, + }, "") + return s +} +func (this *RollingUpdateDeployment) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RollingUpdateDeployment{`, + `MaxUnavailable:` + strings.Replace(fmt.Sprintf("%v", this.MaxUnavailable), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `MaxSurge:` + strings.Replace(fmt.Sprintf("%v", this.MaxSurge), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `}`, + }, "") + return s +} +func (this *RollingUpdateStatefulSetStrategy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RollingUpdateStatefulSetStrategy{`, + `Partition:` + valueToStringGenerated(this.Partition) + `,`, + `}`, + }, "") + return s +} +func (this *Scale) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Scale{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ScaleSpec", "ScaleSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ScaleStatus", "ScaleStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ScaleSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ScaleSpec{`, + `Replicas:` + fmt.Sprintf("%v", this.Replicas) + `,`, + `}`, + }, "") + return s +} +func (this *ScaleStatus) String() string { + if this == nil { + return "nil" + } + keysForSelector := make([]string, 0, len(this.Selector)) + for k := range this.Selector { + keysForSelector = append(keysForSelector, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForSelector) + mapStringForSelector := "map[string]string{" + for _, k := range keysForSelector { + mapStringForSelector += fmt.Sprintf("%v: %v,", k, this.Selector[k]) + } + mapStringForSelector += "}" + s := strings.Join([]string{`&ScaleStatus{`, + `Replicas:` + fmt.Sprintf("%v", this.Replicas) + `,`, + `Selector:` + mapStringForSelector + `,`, + `TargetSelector:` + fmt.Sprintf("%v", this.TargetSelector) + `,`, + `}`, + }, "") + return s +} +func (this *StatefulSet) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatefulSet{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "StatefulSetSpec", "StatefulSetSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "StatefulSetStatus", "StatefulSetStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *StatefulSetList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatefulSetList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "StatefulSet", "StatefulSet", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *StatefulSetSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatefulSetSpec{`, + `Replicas:` + valueToStringGenerated(this.Replicas) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, + `VolumeClaimTemplates:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.VolumeClaimTemplates), "PersistentVolumeClaim", "k8s_io_kubernetes_pkg_api_v1.PersistentVolumeClaim", 1), `&`, ``, 1) + `,`, + `ServiceName:` + fmt.Sprintf("%v", this.ServiceName) + `,`, + `PodManagementPolicy:` + fmt.Sprintf("%v", this.PodManagementPolicy) + `,`, + `UpdateStrategy:` + strings.Replace(strings.Replace(this.UpdateStrategy.String(), "StatefulSetUpdateStrategy", "StatefulSetUpdateStrategy", 1), `&`, ``, 1) + `,`, + `RevisionHistoryLimit:` + valueToStringGenerated(this.RevisionHistoryLimit) + `,`, + `}`, + }, "") + return s +} +func (this *StatefulSetStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatefulSetStatus{`, + `ObservedGeneration:` + valueToStringGenerated(this.ObservedGeneration) + `,`, + `Replicas:` + fmt.Sprintf("%v", this.Replicas) + `,`, + `ReadyReplicas:` + fmt.Sprintf("%v", this.ReadyReplicas) + `,`, + `CurrentReplicas:` + fmt.Sprintf("%v", this.CurrentReplicas) + `,`, + `UpdatedReplicas:` + fmt.Sprintf("%v", this.UpdatedReplicas) + `,`, + `CurrentRevision:` + fmt.Sprintf("%v", this.CurrentRevision) + `,`, + `UpdateRevision:` + fmt.Sprintf("%v", this.UpdateRevision) + `,`, + `}`, + }, "") + return s +} +func (this *StatefulSetUpdateStrategy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StatefulSetUpdateStrategy{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `RollingUpdate:` + strings.Replace(fmt.Sprintf("%v", this.RollingUpdate), "RollingUpdateStatefulSetStrategy", "RollingUpdateStatefulSetStrategy", 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *ControllerRevision) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ControllerRevision: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ControllerRevision: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Data.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType) + } + m.Revision = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Revision |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ControllerRevisionList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ControllerRevisionList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ControllerRevisionList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ControllerRevision{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Deployment) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Deployment: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Deployment: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeploymentCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeploymentCondition: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeploymentCondition: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = DeploymentConditionType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastUpdateTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LastUpdateTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeploymentList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeploymentList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeploymentList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, Deployment{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeploymentRollback) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeploymentRollback: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeploymentRollback: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UpdatedAnnotations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.UpdatedAnnotations == nil { + m.UpdatedAnnotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.UpdatedAnnotations[mapkey] = mapvalue + } else { + var mapvalue string + m.UpdatedAnnotations[mapkey] = mapvalue + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RollbackTo", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.RollbackTo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeploymentSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeploymentSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeploymentSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Replicas = &v + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Selector == nil { + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Strategy", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Strategy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MinReadySeconds", wireType) + } + m.MinReadySeconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.MinReadySeconds |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field RevisionHistoryLimit", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.RevisionHistoryLimit = &v + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Paused", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Paused = bool(v != 0) + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RollbackTo", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.RollbackTo == nil { + m.RollbackTo = &RollbackConfig{} + } + if err := m.RollbackTo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 9: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ProgressDeadlineSeconds", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ProgressDeadlineSeconds = &v + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeploymentStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeploymentStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeploymentStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + } + m.ObservedGeneration = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ObservedGeneration |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + } + m.Replicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Replicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field UpdatedReplicas", wireType) + } + m.UpdatedReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.UpdatedReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field AvailableReplicas", wireType) + } + m.AvailableReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.AvailableReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field UnavailableReplicas", wireType) + } + m.UnavailableReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.UnavailableReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Conditions = append(m.Conditions, DeploymentCondition{}) + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadyReplicas", wireType) + } + m.ReadyReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ReadyReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CollisionCount", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.CollisionCount = &v + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *DeploymentStrategy) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: DeploymentStrategy: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: DeploymentStrategy: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = DeploymentStrategyType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RollingUpdate", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.RollingUpdate == nil { + m.RollingUpdate = &RollingUpdateDeployment{} + } + if err := m.RollingUpdate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RollbackConfig) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RollbackConfig: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RollbackConfig: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType) + } + m.Revision = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Revision |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RollingUpdateDeployment) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RollingUpdateDeployment: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RollingUpdateDeployment: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MaxUnavailable", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.MaxUnavailable == nil { + m.MaxUnavailable = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.MaxUnavailable.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MaxSurge", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.MaxSurge == nil { + m.MaxSurge = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.MaxSurge.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RollingUpdateStatefulSetStrategy) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RollingUpdateStatefulSetStrategy: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RollingUpdateStatefulSetStrategy: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Partition", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Partition = &v + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Scale) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Scale: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Scale: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ScaleSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ScaleSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ScaleSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + } + m.Replicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Replicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ScaleStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ScaleStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ScaleStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + } + m.Replicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Replicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Selector == nil { + m.Selector = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Selector[mapkey] = mapvalue + } else { + var mapvalue string + m.Selector[mapkey] = mapvalue + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.TargetSelector = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF } - s := strings.Join([]string{`&StatefulSetSpec{`, - `Replicas:` + valueToStringGenerated(this.Replicas) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, - `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, - `VolumeClaimTemplates:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.VolumeClaimTemplates), "PersistentVolumeClaim", "k8s_io_kubernetes_pkg_api_v1.PersistentVolumeClaim", 1), `&`, ``, 1) + `,`, - `ServiceName:` + fmt.Sprintf("%v", this.ServiceName) + `,`, - `}`, - }, "") - return s + return nil } -func (this *StatefulSetStatus) String() string { - if this == nil { - return "nil" +func (m *StatefulSet) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StatefulSet: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StatefulSet: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } } - s := strings.Join([]string{`&StatefulSetStatus{`, - `ObservedGeneration:` + valueToStringGenerated(this.ObservedGeneration) + `,`, - `Replicas:` + fmt.Sprintf("%v", this.Replicas) + `,`, - `}`, - }, "") - return s + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil } -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" +func (m *StatefulSetList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StatefulSetList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StatefulSetList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, StatefulSet{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil } -func (m *StatefulSet) Unmarshal(data []byte) error { - l := len(data) +func (m *StatefulSetSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -406,7 +4131,7 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -416,15 +4141,35 @@ func (m *StatefulSet) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StatefulSet: wiretype end group for non-group") + return fmt.Errorf("proto: StatefulSetSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StatefulSet: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StatefulSetSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Replicas = &v + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -434,7 +4179,7 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -448,13 +4193,16 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.Selector == nil { + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -464,7 +4212,7 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -478,13 +4226,13 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field VolumeClaimTemplates", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -494,7 +4242,7 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -508,65 +4256,45 @@ func (m *StatefulSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.VolumeClaimTemplates = append(m.VolumeClaimTemplates, k8s_io_kubernetes_pkg_api_v1.PersistentVolumeClaim{}) + if err := m.VolumeClaimTemplates[len(m.VolumeClaimTemplates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ServiceName", wireType) } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *StatefulSetList) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postIndex := iNdEx + intStringLen + if postIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: StatefulSetList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: StatefulSetList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + m.ServiceName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PodManagementPolicy", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -574,27 +4302,26 @@ func (m *StatefulSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.PodManagementPolicy = PodManagementPolicyType(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 2: + case 7: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field UpdateStrategy", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -604,7 +4331,7 @@ func (m *StatefulSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -618,14 +4345,33 @@ func (m *StatefulSetList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, StatefulSet{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.UpdateStrategy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field RevisionHistoryLimit", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.RevisionHistoryLimit = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -644,8 +4390,8 @@ func (m *StatefulSetList) Unmarshal(data []byte) error { } return nil } -func (m *StatefulSetSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *StatefulSetStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -657,7 +4403,7 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -667,17 +4413,17 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StatefulSetSpec: wiretype end group for non-group") + return fmt.Errorf("proto: StatefulSetStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StatefulSetSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StatefulSetStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) } - var v int32 + var v int64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -685,19 +4431,19 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int32(b) & 0x7F) << shift + v |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Replicas = &v + m.ObservedGeneration = &v case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) } - var msglen int + m.Replicas = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -705,32 +4451,18 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} - } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadyReplicas", wireType) } - var msglen int + m.ReadyReplicas = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -738,29 +4470,56 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.ReadyReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthGenerated + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentReplicas", wireType) } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF + m.CurrentReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CurrentReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field UpdatedReplicas", wireType) } - iNdEx = postIndex - case 4: + m.UpdatedReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.UpdatedReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field VolumeClaimTemplates", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field CurrentRevision", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -768,28 +4527,26 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - m.VolumeClaimTemplates = append(m.VolumeClaimTemplates, k8s_io_kubernetes_pkg_api_v1.PersistentVolumeClaim{}) - if err := m.VolumeClaimTemplates[len(m.VolumeClaimTemplates)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.CurrentRevision = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex - case 5: + case 7: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServiceName", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field UpdateRevision", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -799,7 +4556,7 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -814,11 +4571,11 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ServiceName = string(data[iNdEx:postIndex]) + m.UpdateRevision = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -837,8 +4594,8 @@ func (m *StatefulSetSpec) Unmarshal(data []byte) error { } return nil } -func (m *StatefulSetStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *StatefulSetUpdateStrategy) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -850,7 +4607,7 @@ func (m *StatefulSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -860,17 +4617,17 @@ func (m *StatefulSetStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: StatefulSetStatus: wiretype end group for non-group") + return fmt.Errorf("proto: StatefulSetUpdateStrategy: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: StatefulSetStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: StatefulSetUpdateStrategy: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) } - var v int64 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -878,19 +4635,28 @@ func (m *StatefulSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.ObservedGeneration = &v + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = StatefulSetUpdateStrategyType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Replicas", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RollingUpdate", wireType) } - m.Replicas = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -898,16 +4664,30 @@ func (m *StatefulSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.Replicas |= (int32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.RollingUpdate == nil { + m.RollingUpdate = &RollingUpdateStatefulSetStrategy{} + } + if err := m.RollingUpdate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -926,8 +4706,8 @@ func (m *StatefulSetStatus) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -938,7 +4718,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -956,7 +4736,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -973,7 +4753,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -996,7 +4776,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1007,7 +4787,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1031,46 +4811,124 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 627 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x9c, 0x93, 0xcd, 0x6e, 0xd3, 0x40, - 0x10, 0xc7, 0xe3, 0xa4, 0x29, 0x61, 0x53, 0xbe, 0x96, 0x0a, 0x45, 0x11, 0x72, 0xab, 0x5c, 0x08, - 0x52, 0xbb, 0x56, 0x4a, 0x2b, 0x2a, 0x8e, 0x46, 0x02, 0x21, 0x01, 0x45, 0x0e, 0xaa, 0xa0, 0x08, - 0xa4, 0xb5, 0x33, 0x0d, 0x4b, 0x6c, 0xaf, 0xe5, 0x1d, 0xe7, 0xcc, 0x85, 0x03, 0x37, 0xde, 0x82, - 0x47, 0xe0, 0x15, 0x2a, 0x71, 0xe9, 0x91, 0x53, 0x45, 0xc3, 0x8b, 0x20, 0x6f, 0x36, 0x1f, 0x34, - 0x49, 0xa9, 0x7a, 0xf3, 0xec, 0xce, 0xff, 0x37, 0x33, 0xff, 0x1d, 0x93, 0x87, 0xbd, 0x5d, 0xc5, - 0x84, 0x74, 0x7a, 0x99, 0x0f, 0x69, 0x0c, 0x08, 0xca, 0x49, 0x7a, 0x5d, 0x87, 0x27, 0x42, 0x39, - 0x3c, 0x49, 0x94, 0xd3, 0x6f, 0xf9, 0x80, 0xbc, 0xe5, 0x74, 0x21, 0x86, 0x94, 0x23, 0x74, 0x58, - 0x92, 0x4a, 0x94, 0xf4, 0xde, 0x50, 0xc8, 0x26, 0x42, 0x96, 0xf4, 0xba, 0x2c, 0x17, 0xb2, 0x5c, - 0xc8, 0x8c, 0xb0, 0xbe, 0xd9, 0x15, 0xf8, 0x31, 0xf3, 0x59, 0x20, 0x23, 0xa7, 0x2b, 0xbb, 0xd2, - 0xd1, 0x7a, 0x3f, 0x3b, 0xd4, 0x91, 0x0e, 0xf4, 0xd7, 0x90, 0x5b, 0xdf, 0x5a, 0xd8, 0x90, 0x93, - 0x82, 0x92, 0x59, 0x1a, 0xc0, 0xd9, 0x5e, 0xea, 0x3b, 0x8b, 0x35, 0x59, 0xdc, 0x87, 0x54, 0x09, - 0x19, 0x43, 0x67, 0x46, 0xb6, 0xb1, 0x58, 0xd6, 0x9f, 0x19, 0xb8, 0xbe, 0x39, 0x3f, 0x3b, 0xcd, - 0x62, 0x14, 0xd1, 0x6c, 0x4f, 0xad, 0xf9, 0xe9, 0x19, 0x8a, 0xd0, 0x11, 0x31, 0x2a, 0x4c, 0xcf, - 0x4a, 0x1a, 0xdf, 0x8b, 0xa4, 0xda, 0x46, 0x8e, 0x70, 0x98, 0x85, 0x6d, 0x40, 0xfa, 0x86, 0x54, - 0x22, 0x40, 0xde, 0xe1, 0xc8, 0x6b, 0xd6, 0xba, 0xd5, 0xac, 0x6e, 0x35, 0xd9, 0x42, 0xd7, 0x59, - 0xbf, 0xc5, 0xf6, 0xfc, 0x4f, 0x10, 0xe0, 0x0b, 0x40, 0xee, 0xd2, 0xa3, 0x93, 0xb5, 0xc2, 0xe0, - 0x64, 0x8d, 0x4c, 0xce, 0xbc, 0x31, 0x8d, 0x1e, 0x90, 0x25, 0x95, 0x40, 0x50, 0x2b, 0x6a, 0xea, - 0x2e, 0xbb, 0xe0, 0x5b, 0xb2, 0xa9, 0xee, 0xda, 0x09, 0x04, 0xee, 0x8a, 0xa9, 0xb2, 0x94, 0x47, - 0x9e, 0x66, 0x52, 0x9f, 0x2c, 0x2b, 0xe4, 0x98, 0xa9, 0x5a, 0x49, 0xd3, 0x1f, 0x5d, 0x8a, 0xae, - 0x09, 0xee, 0x75, 0xc3, 0x5f, 0x1e, 0xc6, 0x9e, 0x21, 0x37, 0x7e, 0x5a, 0xe4, 0xc6, 0x54, 0xf6, - 0x73, 0xa1, 0x90, 0xbe, 0x9f, 0x71, 0xcb, 0x39, 0xc7, 0xad, 0xa9, 0xbd, 0x60, 0xb9, 0x5c, 0x9b, - 0x76, 0xd3, 0x94, 0xab, 0x8c, 0x4e, 0xa6, 0x2c, 0x7b, 0x4b, 0xca, 0x02, 0x21, 0x52, 0xb5, 0xe2, - 0x7a, 0xa9, 0x59, 0xdd, 0xda, 0xbe, 0xcc, 0x54, 0xee, 0x35, 0x53, 0xa0, 0xfc, 0x2c, 0x47, 0x79, - 0x43, 0x62, 0xe3, 0x47, 0xe9, 0x9f, 0x69, 0x72, 0x2f, 0x69, 0x93, 0x54, 0x52, 0x48, 0x42, 0x11, - 0x70, 0xa5, 0xa7, 0x29, 0xbb, 0x2b, 0x79, 0x63, 0x9e, 0x39, 0xf3, 0xc6, 0xb7, 0xf4, 0x03, 0xa9, - 0x28, 0x08, 0x21, 0x40, 0x99, 0x9a, 0xf7, 0xdc, 0xbe, 0xe8, 0xdc, 0xdc, 0x87, 0xb0, 0x6d, 0xb4, - 0x43, 0xfe, 0x28, 0xf2, 0xc6, 0x4c, 0xfa, 0x8e, 0x54, 0x10, 0xa2, 0x24, 0xe4, 0x08, 0xe6, 0x45, - 0x37, 0xcf, 0xdf, 0xc2, 0x57, 0xb2, 0xf3, 0xda, 0x08, 0xf4, 0x92, 0x8c, 0x5d, 0x1d, 0x9d, 0x7a, - 0x63, 0x20, 0xfd, 0x62, 0x91, 0xd5, 0xbe, 0x0c, 0xb3, 0x08, 0x1e, 0x87, 0x5c, 0x44, 0xa3, 0x0c, - 0x55, 0x5b, 0xd2, 0x2e, 0x3f, 0xf8, 0x4f, 0xa5, 0x7c, 0x14, 0x85, 0x10, 0xe3, 0xfe, 0x84, 0xe1, - 0xde, 0x35, 0xf5, 0x56, 0xf7, 0xe7, 0x80, 0xbd, 0xb9, 0xe5, 0xe8, 0x0e, 0xa9, 0x2a, 0x48, 0xfb, - 0x22, 0x80, 0x97, 0x3c, 0x82, 0x5a, 0x79, 0xdd, 0x6a, 0x5e, 0x75, 0x6f, 0x1b, 0x50, 0xb5, 0x3d, - 0xb9, 0xf2, 0xa6, 0xf3, 0x1a, 0x5f, 0x2d, 0x72, 0x6b, 0x66, 0x6b, 0xe9, 0x13, 0x42, 0xa5, 0x9f, - 0xa7, 0x41, 0xe7, 0xe9, 0xf0, 0x17, 0x17, 0x32, 0xd6, 0xaf, 0x58, 0x72, 0xef, 0x0c, 0x4e, 0xd6, - 0xe8, 0xde, 0xcc, 0xad, 0x37, 0x47, 0x41, 0x37, 0xa6, 0x76, 0xa0, 0xa8, 0x77, 0x60, 0x6c, 0xe5, - 0xec, 0x1e, 0xb8, 0xf7, 0x8f, 0x4e, 0xed, 0xc2, 0xf1, 0xa9, 0x5d, 0xf8, 0x75, 0x6a, 0x17, 0x3e, - 0x0f, 0x6c, 0xeb, 0x68, 0x60, 0x5b, 0xc7, 0x03, 0xdb, 0xfa, 0x3d, 0xb0, 0xad, 0x6f, 0x7f, 0xec, - 0xc2, 0xc1, 0x15, 0xb3, 0x92, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x28, 0x58, 0x61, 0xec, 0xf5, - 0x05, 0x00, 0x00, + // 1812 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x58, 0x4f, 0x6f, 0x23, 0x49, + 0x15, 0x4f, 0xfb, 0x4f, 0xe2, 0x54, 0x36, 0xce, 0x4c, 0x25, 0x4c, 0xbc, 0x59, 0x70, 0x22, 0x1f, + 0x76, 0x03, 0x6c, 0xda, 0x4c, 0x66, 0xd8, 0x9d, 0x49, 0xd0, 0x88, 0x74, 0x66, 0x58, 0x06, 0x25, + 0x24, 0x2a, 0x27, 0x23, 0x76, 0x58, 0xa4, 0x2d, 0xb7, 0x6b, 0x3a, 0xbd, 0xe9, 0x7f, 0xea, 0xae, + 0x36, 0xe3, 0x1b, 0x5a, 0x89, 0x1b, 0x07, 0xbe, 0x00, 0xe2, 0x8e, 0x90, 0xf8, 0x1a, 0x11, 0x1c, + 0x58, 0x71, 0x1a, 0x71, 0x88, 0x88, 0xf7, 0x23, 0x20, 0x2e, 0x73, 0x42, 0x55, 0x5d, 0xfd, 0xdf, + 0x9d, 0xd8, 0x46, 0xe4, 0xb2, 0x37, 0x77, 0xbd, 0xf7, 0x7e, 0xef, 0x55, 0xd5, 0x7b, 0xaf, 0x7e, + 0xcf, 0xe0, 0xe3, 0xf3, 0x47, 0x9e, 0xac, 0xdb, 0xed, 0x73, 0xbf, 0x4b, 0x5c, 0x8b, 0x50, 0xe2, + 0xb5, 0x9d, 0x73, 0xad, 0x8d, 0x1d, 0xdd, 0x6b, 0x63, 0xc7, 0xf1, 0xda, 0xfd, 0xfb, 0x5d, 0x42, + 0xf1, 0xfd, 0xb6, 0x46, 0x2c, 0xe2, 0x62, 0x4a, 0x7a, 0xb2, 0xe3, 0xda, 0xd4, 0x86, 0x1f, 0x04, + 0x86, 0x72, 0x6c, 0x28, 0x3b, 0xe7, 0x9a, 0xcc, 0x0c, 0x65, 0x66, 0x28, 0x0b, 0xc3, 0xb5, 0x2d, + 0x4d, 0xa7, 0x67, 0x7e, 0x57, 0x56, 0x6d, 0xb3, 0xad, 0xd9, 0x9a, 0xdd, 0xe6, 0xf6, 0x5d, 0xff, + 0x15, 0xff, 0xe2, 0x1f, 0xfc, 0x57, 0x80, 0xbb, 0xf6, 0x50, 0x04, 0x84, 0x1d, 0xdd, 0xc4, 0xea, + 0x99, 0x6e, 0x11, 0x77, 0x10, 0x87, 0x64, 0x12, 0x8a, 0xdb, 0xfd, 0x5c, 0x34, 0x6b, 0xed, 0x22, + 0x2b, 0xd7, 0xb7, 0xa8, 0x6e, 0x92, 0x9c, 0xc1, 0x47, 0x37, 0x19, 0x78, 0xea, 0x19, 0x31, 0x71, + 0xce, 0xee, 0x41, 0x91, 0x9d, 0x4f, 0x75, 0xa3, 0xad, 0x5b, 0xd4, 0xa3, 0x6e, 0xce, 0xe8, 0xc3, + 0xc2, 0x43, 0x1e, 0xb5, 0x97, 0xc7, 0xd7, 0x5c, 0x89, 0x63, 0x1b, 0xba, 0x3a, 0x28, 0xba, 0x94, + 0xd6, 0x7f, 0x24, 0x00, 0xf7, 0x6d, 0x8b, 0xba, 0xb6, 0x61, 0x10, 0x17, 0x91, 0xbe, 0xee, 0xe9, + 0xb6, 0x05, 0x3f, 0x07, 0x35, 0x76, 0x70, 0x3d, 0x4c, 0x71, 0x43, 0xda, 0x90, 0x36, 0x17, 0xb6, + 0x7f, 0x20, 0x8b, 0xeb, 0x4b, 0xee, 0x23, 0xbe, 0x40, 0xa6, 0x2d, 0xf7, 0xef, 0xcb, 0x47, 0xdd, + 0x2f, 0x88, 0x4a, 0x0f, 0x09, 0xc5, 0x0a, 0xbc, 0xb8, 0x5c, 0x9f, 0x19, 0x5e, 0xae, 0x83, 0x78, + 0x0d, 0x45, 0xa8, 0xf0, 0x08, 0x54, 0x38, 0x7a, 0x89, 0xa3, 0x6f, 0x15, 0xa2, 0x8b, 0xd3, 0x95, + 0x11, 0xfe, 0xf5, 0xb3, 0xd7, 0x94, 0x58, 0x2c, 0x3c, 0xe5, 0x1d, 0x01, 0x5d, 0x79, 0x8a, 0x29, + 0x46, 0x1c, 0x08, 0x7e, 0x08, 0x6a, 0xae, 0x08, 0xbf, 0x51, 0xde, 0x90, 0x36, 0xcb, 0xca, 0x1d, + 0xa1, 0x55, 0x0b, 0xb7, 0x85, 0x22, 0x8d, 0xd6, 0x1b, 0x09, 0xdc, 0xcb, 0xef, 0xfb, 0x40, 0xf7, + 0x28, 0xfc, 0x2c, 0xb7, 0x77, 0x79, 0xbc, 0xbd, 0x33, 0x6b, 0xbe, 0xf3, 0xc8, 0x71, 0xb8, 0x92, + 0xd8, 0xf7, 0xe7, 0xa0, 0xaa, 0x53, 0x62, 0x7a, 0x8d, 0xd2, 0x46, 0x79, 0x73, 0x61, 0x7b, 0x57, + 0x1e, 0xb3, 0x2a, 0xe4, 0x7c, 0xb4, 0xca, 0xa2, 0xf0, 0x53, 0x7d, 0xce, 0x10, 0x51, 0x00, 0xdc, + 0xfa, 0x73, 0x09, 0x80, 0xa7, 0xc4, 0x31, 0xec, 0x81, 0x49, 0x2c, 0x7a, 0x0b, 0x57, 0xf9, 0x29, + 0xa8, 0x78, 0x0e, 0x51, 0xc5, 0x55, 0x7e, 0x3c, 0xf6, 0x8e, 0xe2, 0x20, 0x3b, 0x0e, 0x51, 0xe3, + 0x4b, 0x65, 0x5f, 0x88, 0x43, 0x42, 0x0c, 0x66, 0x3d, 0x8a, 0xa9, 0xef, 0xf1, 0x2b, 0x5d, 0xd8, + 0x7e, 0x3c, 0x0d, 0x38, 0x07, 0x50, 0xea, 0x02, 0x7e, 0x36, 0xf8, 0x46, 0x02, 0xb8, 0x75, 0x55, + 0x06, 0xcb, 0xb1, 0xf2, 0xbe, 0x6d, 0xf5, 0x74, 0xca, 0x4a, 0x60, 0x17, 0x54, 0xe8, 0xc0, 0x21, + 0xfc, 0xcc, 0xe6, 0x95, 0x0f, 0xc2, 0xe0, 0x4e, 0x06, 0x0e, 0x79, 0x7b, 0xb9, 0xbe, 0x3a, 0xc2, + 0x84, 0x89, 0x10, 0x37, 0x82, 0x2f, 0xa2, 0xb8, 0x4b, 0xdc, 0xfc, 0x49, 0xda, 0xf9, 0xdb, 0xcb, + 0xf5, 0x6b, 0x2b, 0x5c, 0x8e, 0x30, 0xd3, 0xc1, 0xc2, 0xf7, 0xc1, 0xac, 0x4b, 0xb0, 0x67, 0x5b, + 0x8d, 0x0a, 0xc7, 0x8d, 0x36, 0x85, 0xf8, 0x2a, 0x12, 0x52, 0xf8, 0x5d, 0x30, 0x67, 0x12, 0xcf, + 0xc3, 0x1a, 0x69, 0x54, 0xb9, 0xe2, 0x92, 0x50, 0x9c, 0x3b, 0x0c, 0x96, 0x51, 0x28, 0x87, 0x5f, + 0x80, 0xba, 0x81, 0x3d, 0x7a, 0xea, 0xf4, 0x30, 0x25, 0x27, 0xba, 0x49, 0x1a, 0xb3, 0xfc, 0xa8, + 0xbf, 0x37, 0x5e, 0x96, 0x30, 0x0b, 0xe5, 0x9e, 0x40, 0xaf, 0x1f, 0xa4, 0x90, 0x50, 0x06, 0x19, + 0xf6, 0x01, 0x64, 0x2b, 0x27, 0x2e, 0xb6, 0xbc, 0xe0, 0xc8, 0x98, 0xbf, 0xb9, 0x89, 0xfd, 0xad, + 0x09, 0x7f, 0xf0, 0x20, 0x87, 0x86, 0x46, 0x78, 0x68, 0x5d, 0x48, 0xa0, 0x1e, 0x5f, 0xd8, 0x2d, + 0x54, 0xf9, 0x2f, 0xd2, 0x55, 0xfe, 0x60, 0x8a, 0xb4, 0x2d, 0xa8, 0xee, 0xdf, 0x95, 0x01, 0x8c, + 0x95, 0x90, 0x6d, 0x18, 0x5d, 0xac, 0x9e, 0xc3, 0x0d, 0x50, 0xb1, 0xb0, 0x19, 0x66, 0x6b, 0x54, + 0x4a, 0x3f, 0xc7, 0x26, 0x41, 0x5c, 0x02, 0xff, 0x28, 0x01, 0xe8, 0xf3, 0xab, 0xe8, 0xed, 0x59, + 0x96, 0x4d, 0x31, 0x3b, 0x9d, 0x30, 0xc0, 0xce, 0x14, 0x01, 0x86, 0xbe, 0xe5, 0xd3, 0x1c, 0xea, + 0x33, 0x8b, 0xba, 0x83, 0xf8, 0x96, 0xf2, 0x0a, 0x68, 0x44, 0x28, 0xf0, 0x1c, 0x00, 0x57, 0x60, + 0x9e, 0xd8, 0xa2, 0xe0, 0xc7, 0xef, 0x26, 0x61, 0x38, 0xfb, 0xb6, 0xf5, 0x4a, 0xd7, 0xe2, 0x96, + 0x85, 0x22, 0x48, 0x94, 0x80, 0x5f, 0x7b, 0x06, 0x56, 0x0b, 0xe2, 0x86, 0x77, 0x40, 0xf9, 0x9c, + 0x0c, 0x82, 0xa3, 0x44, 0xec, 0x27, 0x5c, 0x01, 0xd5, 0x3e, 0x36, 0x7c, 0x12, 0x54, 0x33, 0x0a, + 0x3e, 0x76, 0x4a, 0x8f, 0xa4, 0xd6, 0x3f, 0xab, 0xc9, 0xcc, 0x62, 0x9d, 0x0b, 0x6e, 0xb2, 0x87, + 0xc8, 0x31, 0x74, 0x15, 0x7b, 0x1c, 0xa3, 0xaa, 0xbc, 0x13, 0x3c, 0x42, 0xc1, 0x1a, 0x8a, 0xa4, + 0xf0, 0x57, 0xa0, 0xe6, 0x11, 0x83, 0xa8, 0xd4, 0x76, 0x45, 0xf3, 0x7c, 0x30, 0x66, 0x0e, 0xe2, + 0x2e, 0x31, 0x3a, 0xc2, 0x34, 0x80, 0x0f, 0xbf, 0x50, 0x04, 0x09, 0x7f, 0x09, 0x6a, 0x94, 0x98, + 0x8e, 0x81, 0x29, 0x11, 0xa7, 0xb9, 0x55, 0x7c, 0x9a, 0x0c, 0xf6, 0xd8, 0xee, 0x9d, 0x08, 0x03, + 0xde, 0x91, 0xa3, 0x0c, 0x0f, 0x57, 0x51, 0x04, 0x08, 0x75, 0x50, 0xf3, 0x28, 0x63, 0x12, 0xda, + 0x80, 0xf7, 0xa2, 0x49, 0x9e, 0xb2, 0x64, 0x6f, 0x0e, 0x20, 0x62, 0x57, 0xe1, 0x0a, 0x8a, 0xe0, + 0xe1, 0x1e, 0x58, 0x32, 0x75, 0x0b, 0x11, 0xdc, 0x1b, 0x74, 0x88, 0x6a, 0x5b, 0x3d, 0x8f, 0x37, + 0xb5, 0xaa, 0xb2, 0x2a, 0x8c, 0x96, 0x0e, 0xd3, 0x62, 0x94, 0xd5, 0x87, 0x07, 0x60, 0x25, 0x7c, + 0xfa, 0x7f, 0xaa, 0x7b, 0xd4, 0x76, 0x07, 0x07, 0xba, 0xa9, 0x53, 0xde, 0xea, 0xaa, 0x4a, 0x63, + 0x78, 0xb9, 0xbe, 0x82, 0x46, 0xc8, 0xd1, 0x48, 0x2b, 0xd6, 0x85, 0x1d, 0xec, 0x7b, 0xa4, 0xc7, + 0x5b, 0x57, 0x2d, 0xee, 0xc2, 0xc7, 0x7c, 0x15, 0x09, 0x29, 0xd4, 0x52, 0x09, 0x5d, 0xfb, 0xdf, + 0x12, 0xba, 0x5e, 0x9c, 0xcc, 0xf0, 0x14, 0xac, 0x3a, 0xae, 0xad, 0xb9, 0xc4, 0xf3, 0x9e, 0x12, + 0xdc, 0x33, 0x74, 0x8b, 0x84, 0x27, 0x35, 0xcf, 0x77, 0xf8, 0xde, 0xf0, 0x72, 0x7d, 0xf5, 0x78, + 0xb4, 0x0a, 0x2a, 0xb2, 0x6d, 0xfd, 0xa3, 0x02, 0xee, 0x64, 0xdf, 0x51, 0xf8, 0x33, 0x00, 0xed, + 0xae, 0x47, 0xdc, 0x3e, 0xe9, 0x7d, 0x12, 0x90, 0x49, 0xc6, 0xb8, 0x24, 0xce, 0xb8, 0xa2, 0x8a, + 0x3f, 0xca, 0x69, 0xa0, 0x11, 0x56, 0x01, 0x67, 0x13, 0xa5, 0x52, 0xe2, 0x81, 0x26, 0x38, 0x5b, + 0xae, 0x5c, 0xf6, 0xc0, 0x92, 0xe8, 0x1a, 0xa1, 0x90, 0xa7, 0x75, 0x22, 0x0f, 0x4e, 0xd3, 0x62, + 0x94, 0xd5, 0x87, 0x9f, 0x80, 0xbb, 0xb8, 0x8f, 0x75, 0x03, 0x77, 0x0d, 0x12, 0x81, 0x54, 0x38, + 0xc8, 0xbb, 0x02, 0xe4, 0xee, 0x5e, 0x56, 0x01, 0xe5, 0x6d, 0xe0, 0x21, 0x58, 0xf6, 0xad, 0x3c, + 0x54, 0x90, 0x97, 0xef, 0x09, 0xa8, 0xe5, 0xd3, 0xbc, 0x0a, 0x1a, 0x65, 0x07, 0x1d, 0x00, 0xd4, + 0xf0, 0xc9, 0xf7, 0x1a, 0xb3, 0xbc, 0x27, 0xff, 0x68, 0x8a, 0x7a, 0x8a, 0x78, 0x43, 0xdc, 0xff, + 0xa2, 0x25, 0x0f, 0x25, 0x7c, 0xc0, 0x5d, 0xb0, 0xe8, 0xb2, 0x0a, 0x89, 0x42, 0x9f, 0xe3, 0xa1, + 0x7f, 0x4b, 0x98, 0x2d, 0xa2, 0xa4, 0x10, 0xa5, 0x75, 0xe1, 0x0e, 0xa8, 0xab, 0xb6, 0x61, 0xf0, + 0xca, 0xd8, 0xb7, 0x7d, 0x8b, 0xf2, 0xe4, 0x2e, 0x2b, 0x90, 0x71, 0x80, 0xfd, 0x94, 0x04, 0x65, + 0x34, 0x5b, 0x7f, 0x93, 0x92, 0x0f, 0x58, 0x58, 0xee, 0x70, 0x27, 0x45, 0xb7, 0xde, 0xcf, 0xd0, + 0xad, 0x7b, 0x79, 0x8b, 0x04, 0xdb, 0x1a, 0x80, 0x45, 0x56, 0x0c, 0xba, 0xa5, 0x05, 0x09, 0x20, + 0x9a, 0xe9, 0x8f, 0x27, 0x2a, 0xb5, 0xc8, 0x3a, 0xf1, 0x04, 0xdf, 0xe5, 0x27, 0x91, 0x14, 0xa2, + 0xb4, 0xa7, 0xd6, 0x13, 0x50, 0x4f, 0xd7, 0x69, 0x6a, 0x0e, 0x91, 0x6e, 0x9c, 0x43, 0xbe, 0x96, + 0xc0, 0x6a, 0x81, 0x77, 0x68, 0x80, 0xba, 0x89, 0x5f, 0x27, 0x72, 0xe8, 0x46, 0xfe, 0xce, 0x46, + 0x4a, 0x39, 0x18, 0x29, 0xe5, 0xe7, 0x16, 0x3d, 0x72, 0x3b, 0xd4, 0xd5, 0x2d, 0x2d, 0xb8, 0x97, + 0xc3, 0x14, 0x16, 0xca, 0x60, 0xc3, 0x97, 0xa0, 0x66, 0xe2, 0xd7, 0x1d, 0xdf, 0xd5, 0xc2, 0xf3, + 0x9b, 0xdc, 0x0f, 0x7f, 0x89, 0x0e, 0x05, 0x0a, 0x8a, 0xf0, 0x5a, 0x47, 0x60, 0x23, 0xb5, 0x49, + 0xd6, 0x4a, 0xc8, 0x2b, 0xdf, 0xe8, 0x90, 0x38, 0x01, 0xbe, 0x0f, 0xe6, 0x1d, 0xec, 0x52, 0x3d, + 0x6a, 0x27, 0x55, 0x65, 0x71, 0x78, 0xb9, 0x3e, 0x7f, 0x1c, 0x2e, 0xa2, 0x58, 0xde, 0xfa, 0x43, + 0x09, 0x54, 0x3b, 0x2a, 0x36, 0xc8, 0x2d, 0x8c, 0x37, 0x27, 0xa9, 0xf1, 0x66, 0x7b, 0xec, 0xa4, + 0xe2, 0xf1, 0x15, 0x4e, 0x36, 0x9f, 0x65, 0x26, 0x9b, 0x87, 0x13, 0xe2, 0x5e, 0x3f, 0xd4, 0x3c, + 0x06, 0xf3, 0x91, 0xfb, 0x54, 0x97, 0x95, 0x6e, 0xea, 0xb2, 0xad, 0x3f, 0x95, 0xc0, 0x42, 0xc2, + 0xc5, 0x64, 0xd6, 0xd0, 0x49, 0x51, 0x1a, 0xd6, 0xc6, 0x94, 0x69, 0x36, 0x26, 0x87, 0x74, 0x26, + 0x60, 0x92, 0x31, 0x3b, 0xc8, 0xb3, 0x9c, 0x27, 0xa0, 0x4e, 0xb1, 0xab, 0x11, 0x1a, 0xca, 0xf8, + 0x81, 0xce, 0xc7, 0x33, 0xc9, 0x49, 0x4a, 0x8a, 0x32, 0xda, 0x6b, 0xbb, 0x60, 0x31, 0xe5, 0x6c, + 0x22, 0xfa, 0xf7, 0x17, 0x76, 0x58, 0x71, 0x32, 0xdf, 0x42, 0x36, 0xbe, 0x4c, 0x65, 0xe3, 0xa3, + 0xf1, 0x0f, 0x37, 0x51, 0x72, 0x45, 0x39, 0xd9, 0xcd, 0xe4, 0xe4, 0xce, 0x54, 0xe8, 0xd7, 0x67, + 0xe6, 0x5f, 0x25, 0xb0, 0x94, 0xd0, 0xbe, 0x85, 0x59, 0xec, 0xd3, 0xf4, 0x2c, 0xf6, 0x70, 0x9a, + 0x4d, 0x15, 0x0c, 0x63, 0xff, 0xae, 0xa6, 0x36, 0xf3, 0x0d, 0xa2, 0xff, 0xbf, 0x95, 0xc0, 0x4a, + 0xdf, 0x36, 0x7c, 0x93, 0xec, 0x1b, 0x58, 0x37, 0x43, 0x0d, 0x46, 0xa6, 0x6e, 0x18, 0x78, 0xb9, + 0x27, 0xe2, 0x7a, 0xba, 0x47, 0x89, 0x45, 0x5f, 0xc4, 0x18, 0xca, 0xb7, 0x85, 0xbf, 0x95, 0x17, + 0x23, 0x80, 0xd1, 0x48, 0x77, 0xf0, 0x87, 0x60, 0x81, 0xb1, 0x4a, 0x5d, 0x25, 0x6c, 0xd4, 0x15, + 0x7f, 0x76, 0x2c, 0x0b, 0xa0, 0x85, 0x4e, 0x2c, 0x42, 0x49, 0x3d, 0x78, 0x06, 0x96, 0x1d, 0xbb, + 0x77, 0x88, 0x2d, 0xac, 0x11, 0xf6, 0xd6, 0x1e, 0xf3, 0x7f, 0x49, 0xf9, 0x38, 0x30, 0xaf, 0x7c, + 0x14, 0xd2, 0xb7, 0xe3, 0xbc, 0xca, 0x5b, 0xc6, 0xa3, 0xf3, 0xcb, 0x9c, 0x8c, 0x8c, 0x82, 0x84, + 0x5f, 0x4a, 0xa0, 0xee, 0x8b, 0x47, 0x4f, 0x8c, 0x4b, 0xc1, 0xff, 0x1d, 0xca, 0x34, 0x79, 0x78, + 0x9a, 0x42, 0x8a, 0x7b, 0x5c, 0x7a, 0x1d, 0x65, 0x3c, 0x16, 0x8e, 0x3f, 0xb5, 0x69, 0xc6, 0x9f, + 0xd6, 0xdf, 0xcb, 0xe0, 0x6e, 0xae, 0xe0, 0xe1, 0x4f, 0xae, 0x99, 0x0b, 0xee, 0xfd, 0xdf, 0x66, + 0x82, 0x1c, 0x8d, 0x2d, 0x4f, 0x40, 0x63, 0xf7, 0xc0, 0x92, 0xea, 0xbb, 0x2e, 0xb1, 0x68, 0x66, + 0x16, 0x88, 0x06, 0x8a, 0xfd, 0xb4, 0x18, 0x65, 0xf5, 0x47, 0xcd, 0x24, 0xd5, 0x09, 0x67, 0x92, + 0x64, 0x14, 0x82, 0x37, 0x06, 0x79, 0x98, 0x8f, 0x42, 0xd0, 0xc7, 0xac, 0x3e, 0x7b, 0x03, 0x03, + 0xd4, 0x08, 0x61, 0x2e, 0xfd, 0x06, 0x9e, 0xa6, 0xa4, 0x28, 0xa3, 0xcd, 0x58, 0xe8, 0xbb, 0x85, + 0x59, 0x06, 0xf7, 0x52, 0xd4, 0x7c, 0x2b, 0x43, 0xcd, 0xbf, 0x53, 0x68, 0x98, 0x60, 0xe8, 0x5f, + 0x4a, 0xa3, 0x29, 0xfa, 0xf3, 0xe9, 0x28, 0xfa, 0x08, 0xfe, 0x78, 0x33, 0x57, 0x57, 0xb6, 0x2e, + 0xae, 0x9a, 0x33, 0x5f, 0x5d, 0x35, 0x67, 0xde, 0x5c, 0x35, 0x67, 0x7e, 0x33, 0x6c, 0x4a, 0x17, + 0xc3, 0xa6, 0xf4, 0xd5, 0xb0, 0x29, 0xbd, 0x19, 0x36, 0xa5, 0x7f, 0x0d, 0x9b, 0xd2, 0xef, 0xbf, + 0x6e, 0xce, 0xbc, 0x9c, 0x13, 0x1e, 0xff, 0x1b, 0x00, 0x00, 0xff, 0xff, 0x97, 0x69, 0x29, 0x49, + 0xe9, 0x1a, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto index 4d4b054b33..807fa3c512 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,17 +19,295 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.apps.v1beta1; +package k8s.io.client_go.pkg.apis.apps.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both +// the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, +// it may be subject to name and representation changes in future releases, and clients should not +// depend on its stability. It is primarily for internal use by controllers. +message ControllerRevision { + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Data is the serialized representation of the state. + optional k8s.io.apimachinery.pkg.runtime.RawExtension data = 2; + + // Revision indicates the revision of the state represented by Data. + optional int64 revision = 3; +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +message ControllerRevisionList { + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is the list of ControllerRevisions + repeated ControllerRevision items = 2; +} + +// Deployment enables declarative updates for Pods and ReplicaSets. +message Deployment { + // Standard object metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Specification of the desired behavior of the Deployment. + // +optional + optional DeploymentSpec spec = 2; + + // Most recently observed status of the Deployment. + // +optional + optional DeploymentStatus status = 3; +} + +// DeploymentCondition describes the state of a deployment at a certain point. +message DeploymentCondition { + // Type of deployment condition. + optional string type = 1; + + // Status of the condition, one of True, False, Unknown. + optional string status = 2; + + // The last time this condition was updated. + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastUpdateTime = 6; + + // Last time the condition transitioned from one status to another. + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 7; + + // The reason for the condition's last transition. + optional string reason = 4; + + // A human readable message indicating details about the transition. + optional string message = 5; +} + +// DeploymentList is a list of Deployments. +message DeploymentList { + // Standard list metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is the list of Deployments. + repeated Deployment items = 2; +} + +// DeploymentRollback stores the information required to rollback a deployment. +message DeploymentRollback { + // Required: This must match the Name of a deployment. + optional string name = 1; + + // The annotations to be updated to a deployment + // +optional + map updatedAnnotations = 2; + + // The config of this deployment rollback. + optional RollbackConfig rollbackTo = 3; +} + +// DeploymentSpec is the specification of the desired behavior of the Deployment. +message DeploymentSpec { + // Number of desired pods. This is a pointer to distinguish between explicit + // zero and not specified. Defaults to 1. + // +optional + optional int32 replicas = 1; + + // Label selector for pods. Existing ReplicaSets whose pods are + // selected by this will be the ones affected by this deployment. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; + + // Template describes the pods that will be created. + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; + + // The deployment strategy to use to replace existing pods with new ones. + // +optional + optional DeploymentStrategy strategy = 4; + + // Minimum number of seconds for which a newly created pod should be ready + // without any of its container crashing, for it to be considered available. + // Defaults to 0 (pod will be considered available as soon as it is ready) + // +optional + optional int32 minReadySeconds = 5; + + // The number of old ReplicaSets to retain to allow rollback. + // This is a pointer to distinguish between explicit zero and not specified. + // Defaults to 2. + // +optional + optional int32 revisionHistoryLimit = 6; + + // Indicates that the deployment is paused. + // +optional + optional bool paused = 7; + + // The config this deployment is rolling back to. Will be cleared after rollback is done. + // +optional + optional RollbackConfig rollbackTo = 8; + + // The maximum time in seconds for a deployment to make progress before it + // is considered to be failed. The deployment controller will continue to + // process failed deployments and a condition with a ProgressDeadlineExceeded + // reason will be surfaced in the deployment status. Once autoRollback is + // implemented, the deployment controller will automatically rollback failed + // deployments. Note that progress will not be estimated during the time a + // deployment is paused. Defaults to 600s. + optional int32 progressDeadlineSeconds = 9; +} + +// DeploymentStatus is the most recently observed status of the Deployment. +message DeploymentStatus { + // The generation observed by the deployment controller. + // +optional + optional int64 observedGeneration = 1; + + // Total number of non-terminated pods targeted by this deployment (their labels match the selector). + // +optional + optional int32 replicas = 2; + + // Total number of non-terminated pods targeted by this deployment that have the desired template spec. + // +optional + optional int32 updatedReplicas = 3; + + // Total number of ready pods targeted by this deployment. + // +optional + optional int32 readyReplicas = 7; + + // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. + // +optional + optional int32 availableReplicas = 4; + + // Total number of unavailable pods targeted by this deployment. + // +optional + optional int32 unavailableReplicas = 5; + + // Represents the latest available observations of a deployment's current state. + // +patchMergeKey=type + // +patchStrategy=merge + repeated DeploymentCondition conditions = 6; + + // Count of hash collisions for the Deployment. The Deployment controller uses this + // field as a collision avoidance mechanism when it needs to create the name for the + // newest ReplicaSet. + // +optional + optional int64 collisionCount = 8; +} + +// DeploymentStrategy describes how to replace existing pods with new ones. +message DeploymentStrategy { + // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. + // +optional + optional string type = 1; + + // Rolling update config params. Present only if DeploymentStrategyType = + // RollingUpdate. + // --- + // TODO: Update this to follow our convention for oneOf, whatever we decide it + // to be. + // +optional + optional RollingUpdateDeployment rollingUpdate = 2; +} + +message RollbackConfig { + // The revision to rollback to. If set to 0, rollback to the last revision. + // +optional + optional int64 revision = 1; +} + +// Spec to control the desired behavior of rolling update. +message RollingUpdateDeployment { + // The maximum number of pods that can be unavailable during the update. + // Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). + // Absolute number is calculated from percentage by rounding down. + // This can not be 0 if MaxSurge is 0. + // Defaults to 25%. + // Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods + // immediately when the rolling update starts. Once new pods are ready, old RC + // can be scaled down further, followed by scaling up the new RC, ensuring + // that the total number of pods available at all times during the update is at + // least 70% of desired pods. + // +optional + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString maxUnavailable = 1; + + // The maximum number of pods that can be scheduled above the desired number of + // pods. + // Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). + // This can not be 0 if MaxUnavailable is 0. + // Absolute number is calculated from percentage by rounding up. + // Defaults to 25%. + // Example: when this is set to 30%, the new RC can be scaled up immediately when + // the rolling update starts, such that the total number of old and new pods do not exceed + // 130% of desired pods. Once old pods have been killed, + // new RC can be scaled up further, ensuring that total number of pods running + // at any time during the update is atmost 130% of desired pods. + // +optional + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString maxSurge = 2; +} + +// RollingUpdateStatefulSetStrategy is used to communicate parameter for RollingUpdateStatefulSetStrategyType. +message RollingUpdateStatefulSetStrategy { + // Partition indicates the ordinal at which the StatefulSet should be + // partitioned. + optional int32 partition = 1; +} + +// Scale represents a scaling request for a resource. +message Scale { + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + // +optional + optional ScaleSpec spec = 2; + + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. + // +optional + optional ScaleStatus status = 3; +} + +// ScaleSpec describes the attributes of a scale subresource +message ScaleSpec { + // desired number of instances for the scaled object. + // +optional + optional int32 replicas = 1; +} + +// ScaleStatus represents the current status of a scale subresource. +message ScaleStatus { + // actual number of observed instances of the scaled object. + optional int32 replicas = 1; + + // label query over pods that should match the replicas count. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // +optional + map selector = 2; + + // label selector for pods that should match the replicas count. This is a serializated + // version of both map-based and more expressive set-based selectors. This is done to + // avoid introspection in the clients. The string will be in the same format as the + // query-param syntax. If the target type only supports map-based selectors, both this + // field and map-based selector field are populated. + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + // +optional + optional string targetSelector = 3; +} + // StatefulSet represents a set of pods with consistent identities. // Identities are defined as: // - Network: A single stable DNS and hostname. @@ -38,7 +316,7 @@ option go_package = "v1beta1"; // map to the same storage identity. message StatefulSet { // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the desired identities of pods in this set. // +optional @@ -53,14 +331,14 @@ message StatefulSet { // StatefulSetList is a collection of StatefulSets. message StatefulSetList { // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; repeated StatefulSet items = 2; } // A StatefulSetSpec is the specification of a StatefulSet. message StatefulSetSpec { - // Replicas is the desired number of replicas of the given Template. + // replicas is the desired number of replicas of the given Template. // These are replicas in the sense that they are instantiations of the // same Template, but individual replicas also have a consistent identity. // If unspecified, defaults to 1. @@ -68,19 +346,19 @@ message StatefulSetSpec { // +optional optional int32 replicas = 1; - // Selector is a label query over pods that should match the replica count. + // selector is a label query over pods that should match the replica count. // If empty, defaulted to labels on the pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; - // Template is the object that describes the pod that will be created if + // template is the object that describes the pod that will be created if // insufficient replicas are detected. Each pod stamped out by the StatefulSet // will fulfill this Template, but have a unique identity from the rest // of the StatefulSet. - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; - // VolumeClaimTemplates is a list of claims that pods are allowed to reference. + // volumeClaimTemplates is a list of claims that pods are allowed to reference. // The StatefulSet controller is responsible for mapping network identities to // claims in a way that maintains the identity of a pod. Every claim in // this list must have at least one matching (by name) volumeMount in one @@ -88,23 +366,76 @@ message StatefulSetSpec { // any volumes in the template, with the same name. // TODO: Define the behavior if a claim already exists with the same name. // +optional - repeated k8s.io.kubernetes.pkg.api.v1.PersistentVolumeClaim volumeClaimTemplates = 4; + repeated k8s.io.client_go.pkg.api.v1.PersistentVolumeClaim volumeClaimTemplates = 4; - // ServiceName is the name of the service that governs this StatefulSet. + // serviceName is the name of the service that governs this StatefulSet. // This service must exist before the StatefulSet, and is responsible for // the network identity of the set. Pods get DNS/hostnames that follow the // pattern: pod-specific-string.serviceName.default.svc.cluster.local // where "pod-specific-string" is managed by the StatefulSet controller. optional string serviceName = 5; + + // podManagementPolicy controls how pods are created during initial scale up, + // when replacing pods on nodes, or when scaling down. The default policy is + // `OrderedReady`, where pods are created in increasing order (pod-0, then + // pod-1, etc) and the controller will wait until each pod is ready before + // continuing. When scaling down, the pods are removed in the opposite order. + // The alternative policy is `Parallel` which will create pods in parallel + // to match the desired scale without waiting, and on scale down will delete + // all pods at once. + // +optional + optional string podManagementPolicy = 6; + + // updateStrategy indicates the StatefulSetUpdateStrategy that will be + // employed to update Pods in the StatefulSet when a revision is made to + // Template. + optional StatefulSetUpdateStrategy updateStrategy = 7; + + // revisionHistoryLimit is the maximum number of revisions that will + // be maintained in the StatefulSet's revision history. The revision history + // consists of all revisions not represented by a currently applied + // StatefulSetSpec version. The default value is 10. + optional int32 revisionHistoryLimit = 8; } // StatefulSetStatus represents the current state of a StatefulSet. message StatefulSetStatus { - // most recent generation observed by this autoscaler. + // observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the + // StatefulSet's generation, which is updated on mutation by the API Server. // +optional optional int64 observedGeneration = 1; - // Replicas is the number of actual replicas. + // replicas is the number of Pods created by the StatefulSet controller. optional int32 replicas = 2; + + // readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition. + optional int32 readyReplicas = 3; + + // currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version + // indicated by currentRevision. + optional int32 currentReplicas = 4; + + // updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version + // indicated by updateRevision. + optional int32 updatedReplicas = 5; + + // currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the + // sequence [0,currentReplicas). + optional string currentRevision = 6; + + // updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence + // [replicas-updatedReplicas,replicas) + optional string updateRevision = 7; +} + +// StatefulSetUpdateStrategy indicates the strategy that the StatefulSet +// controller will use to perform updates. It includes any additional parameters +// necessary to perform the update for the indicated strategy. +message StatefulSetUpdateStrategy { + // Type indicates the type of the StatefulSetUpdateStrategy. + optional string type = 1; + + // RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. + optional RollingUpdateStatefulSetStrategy rollingUpdate = 2; } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go index 3ab76cf6ae..5a4fd5bc3b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/register.go @@ -17,35 +17,49 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "apps" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1beta1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, + &Deployment{}, + &DeploymentList{}, + &DeploymentRollback{}, + &Scale{}, &StatefulSet{}, &StatefulSetList{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, + &ControllerRevision{}, + &ControllerRevisionList{}, ) - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } - -func (obj *StatefulSet) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } -func (obj *StatefulSetList) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go index 6436d90a8d..a6c0bfb296 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.generated.go @@ -25,11 +25,12 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/pkg/util/intstr" + pkg4_resource "k8s.io/apimachinery/pkg/api/resource" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg6_runtime "k8s.io/apimachinery/pkg/runtime" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg5_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg3_v1 "k8s.io/client-go/pkg/api/v1" "reflect" "runtime" time "time" @@ -66,15 +67,890 @@ func init() { } if false { // reference the types, but skip this branch at build/run time var v0 pkg4_resource.Quantity - var v1 pkg1_unversioned.TypeMeta - var v2 pkg2_v1.ObjectMeta - var v3 pkg3_types.UID + var v1 pkg1_v1.TypeMeta + var v2 pkg6_runtime.RawExtension + var v3 pkg2_types.UID var v4 pkg5_intstr.IntOrString - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 + var v5 pkg3_v1.PodTemplateSpec + var v6 time.Time + _, _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5, v6 } } +func (x *ScaleSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ScaleSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "replicas": + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv7 := &x.Replicas + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Selector) != 0 + yyq2[2] = x.TargetSelector != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Selector == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncMapStringStringV(x.Selector, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("selector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Selector == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncMapStringStringV(x.Selector, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.TargetSelector)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.TargetSelector)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ScaleStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "replicas": + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } + } + case "selector": + if r.TryDecodeAsNil() { + x.Selector = nil + } else { + yyv6 := &x.Selector + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecMapStringStringX(yyv6, false, d) + } + } + case "targetSelector": + if r.TryDecodeAsNil() { + x.TargetSelector = "" + } else { + yyv8 := &x.TargetSelector + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv11 := &x.Replicas + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(yyv11)) = int32(r.DecodeInt(32)) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Selector = nil + } else { + yyv13 := &x.Selector + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + z.F.DecMapStringStringX(yyv13, false, d) + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TargetSelector = "" + } else { + yyv15 := &x.TargetSelector + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Scale) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Scale) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = ScaleSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = ScaleStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = ScaleSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = ScaleStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + func (x *StatefulSet) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) @@ -89,19 +965,5242 @@ func (x *StatefulSet) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StatefulSet) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StatefulSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = StatefulSetSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = StatefulSetStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StatefulSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = StatefulSetSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = StatefulSetStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x PodManagementPolicyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *PodManagementPolicyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *StatefulSetUpdateStrategy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Type != "" + yyq2[1] = x.RollingUpdate != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + x.Type.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.RollingUpdate == nil { + r.EncodeNil() + } else { + x.RollingUpdate.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RollingUpdate == nil { + r.EncodeNil() + } else { + x.RollingUpdate.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StatefulSetUpdateStrategy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StatefulSetUpdateStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "rollingUpdate": + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } + } else { + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateStatefulSetStrategy) + } + x.RollingUpdate.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StatefulSetUpdateStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv7 := &x.Type + yyv7.CodecDecodeSelf(d) + } + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } + } else { + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateStatefulSetStrategy) + } + x.RollingUpdate.CodecDecodeSelf(d) + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x StatefulSetUpdateStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *StatefulSetUpdateStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *RollingUpdateStatefulSetStrategy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Partition != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Partition == nil { + r.EncodeNil() + } else { + yy4 := *x.Partition + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(yy4)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("partition")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Partition == nil { + r.EncodeNil() + } else { + yy6 := *x.Partition + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(yy6)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RollingUpdateStatefulSetStrategy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RollingUpdateStatefulSetStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "partition": + if r.TryDecodeAsNil() { + if x.Partition != nil { + x.Partition = nil + } + } else { + if x.Partition == nil { + x.Partition = new(int32) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(x.Partition)) = int32(r.DecodeInt(32)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RollingUpdateStatefulSetStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Partition != nil { + x.Partition = nil + } + } else { + if x.Partition == nil { + x.Partition = new(int32) + } + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(x.Partition)) = int32(r.DecodeInt(32)) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *StatefulSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != nil + yyq2[1] = x.Selector != nil + yyq2[3] = len(x.VolumeClaimTemplates) != 0 + yyq2[5] = x.PodManagementPolicy != "" + yyq2[6] = true + yyq2[7] = x.RevisionHistoryLimit != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Replicas == nil { + r.EncodeNil() + } else { + yy4 := *x.Replicas + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(yy4)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Replicas == nil { + r.EncodeNil() + } else { + yy6 := *x.Replicas + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(yy6)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Selector == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("selector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Selector == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.Template + yy12.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("template")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.Template + yy14.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.VolumeClaimTemplates == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + h.encSlicev1_PersistentVolumeClaim(([]pkg3_v1.PersistentVolumeClaim)(x.VolumeClaimTemplates), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("volumeClaimTemplates")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.VolumeClaimTemplates == nil { + r.EncodeNil() + } else { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + h.encSlicev1_PersistentVolumeClaim(([]pkg3_v1.PersistentVolumeClaim)(x.VolumeClaimTemplates), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("serviceName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + x.PodManagementPolicy.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podManagementPolicy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.PodManagementPolicy.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + yy26 := &x.UpdateStrategy + yy26.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("updateStrategy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy28 := &x.UpdateStrategy + yy28.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy31 := *x.RevisionHistoryLimit + yym32 := z.EncBinary() + _ = yym32 + if false { + } else { + r.EncodeInt(int64(yy31)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy33 := *x.RevisionHistoryLimit + yym34 := z.EncBinary() + _ = yym34 + if false { + } else { + r.EncodeInt(int64(yy33)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StatefulSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StatefulSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "replicas": + if r.TryDecodeAsNil() { + if x.Replicas != nil { + x.Replicas = nil + } + } else { + if x.Replicas == nil { + x.Replicas = new(int32) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + } + } + case "selector": + if r.TryDecodeAsNil() { + if x.Selector != nil { + x.Selector = nil + } + } else { + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + case "template": + if r.TryDecodeAsNil() { + x.Template = pkg3_v1.PodTemplateSpec{} + } else { + yyv8 := &x.Template + yyv8.CodecDecodeSelf(d) + } + case "volumeClaimTemplates": + if r.TryDecodeAsNil() { + x.VolumeClaimTemplates = nil + } else { + yyv9 := &x.VolumeClaimTemplates + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSlicev1_PersistentVolumeClaim((*[]pkg3_v1.PersistentVolumeClaim)(yyv9), d) + } + } + case "serviceName": + if r.TryDecodeAsNil() { + x.ServiceName = "" + } else { + yyv11 := &x.ServiceName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + case "podManagementPolicy": + if r.TryDecodeAsNil() { + x.PodManagementPolicy = "" + } else { + yyv13 := &x.PodManagementPolicy + yyv13.CodecDecodeSelf(d) + } + case "updateStrategy": + if r.TryDecodeAsNil() { + x.UpdateStrategy = StatefulSetUpdateStrategy{} + } else { + yyv14 := &x.UpdateStrategy + yyv14.CodecDecodeSelf(d) + } + case "revisionHistoryLimit": + if r.TryDecodeAsNil() { + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } + } else { + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StatefulSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj17 int + var yyb17 bool + var yyhl17 bool = l >= 0 + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Replicas != nil { + x.Replicas = nil + } + } else { + if x.Replicas == nil { + x.Replicas = new(int32) + } + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Selector != nil { + x.Selector = nil + } + } else { + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym21 := z.DecBinary() + _ = yym21 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Template = pkg3_v1.PodTemplateSpec{} + } else { + yyv22 := &x.Template + yyv22.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.VolumeClaimTemplates = nil + } else { + yyv23 := &x.VolumeClaimTemplates + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + h.decSlicev1_PersistentVolumeClaim((*[]pkg3_v1.PersistentVolumeClaim)(yyv23), d) + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ServiceName = "" + } else { + yyv25 := &x.ServiceName + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.PodManagementPolicy = "" + } else { + yyv27 := &x.PodManagementPolicy + yyv27.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UpdateStrategy = StatefulSetUpdateStrategy{} + } else { + yyv28 := &x.UpdateStrategy + yyv28.CodecDecodeSelf(d) + } + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } + } else { + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + for { + yyj17++ + if yyhl17 { + yyb17 = yyj17 > l + } else { + yyb17 = r.CheckBreak() + } + if yyb17 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj17-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *StatefulSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ObservedGeneration != nil + yyq2[2] = x.ReadyReplicas != 0 + yyq2[3] = x.CurrentReplicas != 0 + yyq2[4] = x.UpdatedReplicas != 0 + yyq2[5] = x.CurrentRevision != "" + yyq2[6] = x.UpdateRevision != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.ObservedGeneration == nil { + r.EncodeNil() + } else { + yy4 := *x.ObservedGeneration + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(yy4)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ObservedGeneration == nil { + r.EncodeNil() + } else { + yy6 := *x.ObservedGeneration + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(yy6)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym12 := z.EncBinary() + _ = yym12 + if false { + } else { + r.EncodeInt(int64(x.ReadyReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.ReadyReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeInt(int64(x.CurrentReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.CurrentReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeInt(int64(x.UpdatedReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("updatedReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.UpdatedReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.CurrentRevision)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentRevision")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.CurrentRevision)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + yym24 := z.EncBinary() + _ = yym24 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.UpdateRevision)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("updateRevision")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym25 := z.EncBinary() + _ = yym25 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.UpdateRevision)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StatefulSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StatefulSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "observedGeneration": + if r.TryDecodeAsNil() { + if x.ObservedGeneration != nil { + x.ObservedGeneration = nil + } + } else { + if x.ObservedGeneration == nil { + x.ObservedGeneration = new(int64) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + } + } + case "replicas": + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv6 := &x.Replicas + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } + } + case "readyReplicas": + if r.TryDecodeAsNil() { + x.ReadyReplicas = 0 + } else { + yyv8 := &x.ReadyReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } + } + case "currentReplicas": + if r.TryDecodeAsNil() { + x.CurrentReplicas = 0 + } else { + yyv10 := &x.CurrentReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } + } + case "updatedReplicas": + if r.TryDecodeAsNil() { + x.UpdatedReplicas = 0 + } else { + yyv12 := &x.UpdatedReplicas + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(yyv12)) = int32(r.DecodeInt(32)) + } + } + case "currentRevision": + if r.TryDecodeAsNil() { + x.CurrentRevision = "" + } else { + yyv14 := &x.CurrentRevision + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "updateRevision": + if r.TryDecodeAsNil() { + x.UpdateRevision = "" + } else { + yyv16 := &x.UpdateRevision + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StatefulSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ObservedGeneration != nil { + x.ObservedGeneration = nil + } + } else { + if x.ObservedGeneration == nil { + x.ObservedGeneration = new(int64) + } + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv21 := &x.Replicas + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadyReplicas = 0 + } else { + yyv23 := &x.ReadyReplicas + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentReplicas = 0 + } else { + yyv25 := &x.CurrentReplicas + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UpdatedReplicas = 0 + } else { + yyv27 := &x.UpdatedReplicas + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentRevision = "" + } else { + yyv29 := &x.CurrentRevision + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UpdateRevision = "" + } else { + yyv31 := &x.UpdateRevision + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceStatefulSet(([]StatefulSet)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceStatefulSet(([]StatefulSet)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *StatefulSetList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *StatefulSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceStatefulSet((*[]StatefulSet)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *StatefulSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceStatefulSet((*[]StatefulSet)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = DeploymentSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = DeploymentStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Deployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = DeploymentSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = DeploymentStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != nil + yyq2[1] = x.Selector != nil + yyq2[3] = true + yyq2[4] = x.MinReadySeconds != 0 + yyq2[5] = x.RevisionHistoryLimit != nil + yyq2[6] = x.Paused != false + yyq2[7] = x.RollbackTo != nil + yyq2[8] = x.ProgressDeadlineSeconds != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Replicas == nil { + r.EncodeNil() + } else { + yy4 := *x.Replicas + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(yy4)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Replicas == nil { + r.EncodeNil() + } else { + yy6 := *x.Replicas + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(yy6)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Selector == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("selector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Selector == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.Template + yy12.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("template")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.Template + yy14.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy17 := &x.Strategy + yy17.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("strategy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy19 := &x.Strategy + yy19.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeInt(int64(x.MinReadySeconds)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeInt(int64(x.MinReadySeconds)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy25 := *x.RevisionHistoryLimit + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(yy25)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy27 := *x.RevisionHistoryLimit + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeInt(int64(yy27)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + yym30 := z.EncBinary() + _ = yym30 + if false { + } else { + r.EncodeBool(bool(x.Paused)) + } + } else { + r.EncodeBool(false) + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("paused")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeBool(bool(x.Paused)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + if x.RollbackTo == nil { + r.EncodeNil() + } else { + x.RollbackTo.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RollbackTo == nil { + r.EncodeNil() + } else { + x.RollbackTo.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[8] { + if x.ProgressDeadlineSeconds == nil { + r.EncodeNil() + } else { + yy36 := *x.ProgressDeadlineSeconds + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeInt(int64(yy36)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[8] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("progressDeadlineSeconds")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ProgressDeadlineSeconds == nil { + r.EncodeNil() + } else { + yy38 := *x.ProgressDeadlineSeconds + yym39 := z.EncBinary() + _ = yym39 + if false { + } else { + r.EncodeInt(int64(yy38)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DeploymentSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "replicas": + if r.TryDecodeAsNil() { + if x.Replicas != nil { + x.Replicas = nil + } + } else { + if x.Replicas == nil { + x.Replicas = new(int32) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + } + } + case "selector": + if r.TryDecodeAsNil() { + if x.Selector != nil { + x.Selector = nil + } + } else { + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + case "template": + if r.TryDecodeAsNil() { + x.Template = pkg3_v1.PodTemplateSpec{} + } else { + yyv8 := &x.Template + yyv8.CodecDecodeSelf(d) + } + case "strategy": + if r.TryDecodeAsNil() { + x.Strategy = DeploymentStrategy{} + } else { + yyv9 := &x.Strategy + yyv9.CodecDecodeSelf(d) + } + case "minReadySeconds": + if r.TryDecodeAsNil() { + x.MinReadySeconds = 0 + } else { + yyv10 := &x.MinReadySeconds + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } + } + case "revisionHistoryLimit": + if r.TryDecodeAsNil() { + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } + } else { + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + case "paused": + if r.TryDecodeAsNil() { + x.Paused = false + } else { + yyv14 := &x.Paused + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "rollbackTo": + if r.TryDecodeAsNil() { + if x.RollbackTo != nil { + x.RollbackTo = nil + } + } else { + if x.RollbackTo == nil { + x.RollbackTo = new(RollbackConfig) + } + x.RollbackTo.CodecDecodeSelf(d) + } + case "progressDeadlineSeconds": + if r.TryDecodeAsNil() { + if x.ProgressDeadlineSeconds != nil { + x.ProgressDeadlineSeconds = nil + } + } else { + if x.ProgressDeadlineSeconds == nil { + x.ProgressDeadlineSeconds = new(int32) + } + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj19 int + var yyb19 bool + var yyhl19 bool = l >= 0 + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Replicas != nil { + x.Replicas = nil + } + } else { + if x.Replicas == nil { + x.Replicas = new(int32) + } + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + 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(pkg1_v1.LabelSelector) + } + yym23 := z.DecBinary() + _ = yym23 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Template = pkg3_v1.PodTemplateSpec{} + } else { + yyv24 := &x.Template + yyv24.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Strategy = DeploymentStrategy{} + } else { + yyv25 := &x.Strategy + yyv25.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MinReadySeconds = 0 + } else { + yyv26 := &x.MinReadySeconds + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*int32)(yyv26)) = int32(r.DecodeInt(32)) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } + } else { + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Paused = false + } else { + yyv30 := &x.Paused + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*bool)(yyv30)) = r.DecodeBool() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RollbackTo != nil { + x.RollbackTo = nil + } + } else { + if x.RollbackTo == nil { + x.RollbackTo = new(RollbackConfig) + } + x.RollbackTo.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ProgressDeadlineSeconds != nil { + x.ProgressDeadlineSeconds = nil + } + } else { + if x.ProgressDeadlineSeconds == nil { + x.ProgressDeadlineSeconds = new(int32) + } + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) + } + } + for { + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj19-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[3] = len(x.UpdatedAnnotations) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.UpdatedAnnotations == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("updatedAnnotations")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.UpdatedAnnotations == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy16 := &x.RollbackTo + yy16.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy18 := &x.RollbackTo + yy18.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DeploymentRollback) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "updatedAnnotations": + if r.TryDecodeAsNil() { + x.UpdatedAnnotations = nil + } else { + yyv10 := &x.UpdatedAnnotations + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecMapStringStringX(yyv10, false, d) + } + } + case "rollbackTo": + if r.TryDecodeAsNil() { + x.RollbackTo = RollbackConfig{} + } else { + yyv12 := &x.RollbackTo + yyv12.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv14 := &x.Kind + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv16 := &x.APIVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv18 := &x.Name + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UpdatedAnnotations = nil + } else { + yyv20 := &x.UpdatedAnnotations + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + z.F.DecMapStringStringX(yyv20, false, d) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.RollbackTo = RollbackConfig{} + } else { + yyv22 := &x.RollbackTo + yyv22.CodecDecodeSelf(d) + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Revision != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.Revision)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("revision")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.Revision)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RollbackConfig) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "revision": + if r.TryDecodeAsNil() { + x.Revision = 0 + } else { + yyv4 := &x.Revision + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Revision = 0 + } else { + yyv7 := &x.Revision + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) + } + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Type != "" + yyq2[1] = x.RollingUpdate != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + x.Type.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.RollingUpdate == nil { + r.EncodeNil() + } else { + x.RollingUpdate.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RollingUpdate == nil { + r.EncodeNil() + } else { + x.RollingUpdate.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DeploymentStrategy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "rollingUpdate": + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } + } else { + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateDeployment) + } + x.RollingUpdate.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv7 := &x.Type + yyv7.CodecDecodeSelf(d) + } + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } + } else { + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateDeployment) + } + x.RollingUpdate.CodecDecodeSelf(d) + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x DeploymentStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *DeploymentStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.MaxUnavailable != nil + yyq2[1] = x.MaxSurge != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.MaxUnavailable == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym4 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.MaxUnavailable == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym5 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.MaxSurge == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { + } else if !yym7 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxSurge) + } else { + z.EncFallback(x.MaxSurge) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.MaxSurge == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxSurge) + } else { + z.EncFallback(x.MaxSurge) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RollingUpdateDeployment) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "maxUnavailable": + if r.TryDecodeAsNil() { + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil + } + } else { + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg5_intstr.IntOrString) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) + } else { + z.DecFallback(x.MaxUnavailable, false) + } + } + case "maxSurge": + if r.TryDecodeAsNil() { + if x.MaxSurge != nil { + x.MaxSurge = nil + } + } else { + if x.MaxSurge == nil { + x.MaxSurge = new(pkg5_intstr.IntOrString) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxSurge) + } else { + z.DecFallback(x.MaxSurge, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil + } + } else { + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg5_intstr.IntOrString) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) + } else { + z.DecFallback(x.MaxUnavailable, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.MaxSurge != nil { + x.MaxSurge = nil + } + } else { + if x.MaxSurge == nil { + x.MaxSurge = new(pkg5_intstr.IntOrString) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxSurge) + } else { + z.DecFallback(x.MaxSurge, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *DeploymentStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ObservedGeneration != 0 + yyq2[1] = x.Replicas != 0 + yyq2[2] = x.UpdatedReplicas != 0 + yyq2[3] = x.ReadyReplicas != 0 + yyq2[4] = x.AvailableReplicas != 0 + yyq2[5] = x.UnavailableReplicas != 0 + yyq2[6] = len(x.Conditions) != 0 + yyq2[7] = x.CollisionCount != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.ObservedGeneration)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.ObservedGeneration)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.Replicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.UpdatedReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("updatedReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.UpdatedReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.ReadyReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.ReadyReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.AvailableReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.AvailableReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.UnavailableReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("unavailableReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.UnavailableReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + if x.Conditions == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("conditions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Conditions == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + if x.CollisionCount == nil { + r.EncodeNil() + } else { + yy25 := *x.CollisionCount + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(yy25)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("collisionCount")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CollisionCount == nil { + r.EncodeNil() + } else { + yy27 := *x.CollisionCount + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeInt(int64(yy27)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DeploymentStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *DeploymentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "observedGeneration": + if r.TryDecodeAsNil() { + x.ObservedGeneration = 0 + } else { + yyv4 := &x.ObservedGeneration + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } + } + case "replicas": + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv6 := &x.Replicas + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } + } + case "updatedReplicas": + if r.TryDecodeAsNil() { + x.UpdatedReplicas = 0 + } else { + yyv8 := &x.UpdatedReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } + } + case "readyReplicas": + if r.TryDecodeAsNil() { + x.ReadyReplicas = 0 + } else { + yyv10 := &x.ReadyReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } + } + case "availableReplicas": + if r.TryDecodeAsNil() { + x.AvailableReplicas = 0 + } else { + yyv12 := &x.AvailableReplicas + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(yyv12)) = int32(r.DecodeInt(32)) + } + } + case "unavailableReplicas": + if r.TryDecodeAsNil() { + x.UnavailableReplicas = 0 + } else { + yyv14 := &x.UnavailableReplicas + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } + } + case "conditions": + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv16 := &x.Conditions + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv16), d) + } + } + case "collisionCount": + if r.TryDecodeAsNil() { + if x.CollisionCount != nil { + x.CollisionCount = nil + } + } else { + if x.CollisionCount == nil { + x.CollisionCount = new(int64) + } + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int64)(x.CollisionCount)) = int64(r.DecodeInt(64)) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *DeploymentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObservedGeneration = 0 + } else { + yyv21 := &x.ObservedGeneration + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Replicas = 0 + } else { + yyv23 := &x.Replicas + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UpdatedReplicas = 0 + } else { + yyv25 := &x.UpdatedReplicas + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadyReplicas = 0 + } else { + yyv27 := &x.ReadyReplicas + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.AvailableReplicas = 0 + } else { + yyv29 := &x.AvailableReplicas + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int32)(yyv29)) = int32(r.DecodeInt(32)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UnavailableReplicas = 0 + } else { + yyv31 := &x.UnavailableReplicas + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int32)(yyv31)) = int32(r.DecodeInt(32)) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv33 := &x.Conditions + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv33), d) + } + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.CollisionCount != nil { + x.CollisionCount = nil + } + } else { + if x.CollisionCount == nil { + x.CollisionCount = new(int64) + } + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*int64)(x.CollisionCount)) = int64(r.DecodeInt(64)) + } + } + for { + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l + } else { + yyb20 = r.CheckBreak() + } + if yyb20 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj20-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x DeploymentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *DeploymentConditionType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *DeploymentCondition) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" yyq2[2] = true yyq2[3] = true - yyq2[4] = true + yyq2[4] = x.Reason != "" + yyq2[5] = x.Message != "" var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) + r.EncodeArrayStart(6) } else { - yynn2 = 0 + yynn2 = 2 for _, b := range yyq2 { if b { yynn2++ @@ -112,103 +6211,146 @@ func (x *StatefulSet) CodecEncodeSelf(e *codec1978.Encoder) { } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf7 := &x.Status + yysf7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf8 := &x.Status + yysf8.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.LastUpdateTime + yym11 := z.EncBinary() + _ = yym11 if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + z.EncFallback(yy10) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq2[0] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 + yy12 := &x.LastUpdateTime + yym13 := z.EncBinary() + _ = yym13 if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + z.EncFallback(yy12) } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 + if yyq2[3] { + yy15 := &x.LastTransitionTime + yym16 := z.EncBinary() + _ = yym16 if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + z.EncFallback(yy15) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq2[1] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 + yy17 := &x.LastTransitionTime + yym18 := z.EncBinary() + _ = yym18 if false { + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if yym18 { + z.EncBinaryMarshal(yy17) + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + z.EncFallback(yy17) } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2[3] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) + r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) + if yyq2[5] { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq2[4] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) + r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) + yym24 := z.EncBinary() + _ = yym24 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } } } if yyr2 || yy2arr2 { @@ -220,29 +6362,29 @@ func (x *StatefulSet) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *StatefulSet) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl19, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl19, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -250,16 +6392,16 @@ func (x *StatefulSet) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *StatefulSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -268,323 +6410,384 @@ func (x *StatefulSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - case "kind": + switch yys3 { + case "type": if r.TryDecodeAsNil() { - x.Kind = "" + x.Type = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } - case "apiVersion": + case "status": if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Status = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } - case "metadata": + case "lastUpdateTime": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.LastUpdateTime = pkg1_v1.Time{} } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) + yyv6 := &x.LastUpdateTime + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } } - case "spec": + case "lastTransitionTime": if r.TryDecodeAsNil() { - x.Spec = StatefulSetSpec{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) + yyv8 := &x.LastTransitionTime + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) + } else { + z.DecFallback(yyv8, false) + } } - case "status": + case "reason": if r.TryDecodeAsNil() { - x.Status = StatefulSetStatus{} + x.Reason = "" + } else { + yyv10 := &x.Reason + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "message": + if r.TryDecodeAsNil() { + x.Message = "" } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) + yyv12 := &x.Message + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *StatefulSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb26 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb26 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" + x.Type = "" } else { - x.Kind = string(r.DecodeString()) + yyv15 := &x.Type + yyv15.CodecDecodeSelf(d) } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb26 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb26 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Status = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv16 := &x.Status + yyv16.CodecDecodeSelf(d) } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb26 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb26 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.LastUpdateTime = pkg1_v1.Time{} } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) + yyv17 := &x.LastUpdateTime + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) + } else { + z.DecFallback(yyv17, false) + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb26 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb26 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Spec = StatefulSetSpec{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) + yyv19 := &x.LastTransitionTime + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else if yym20 { + z.DecBinaryUnmarshal(yyv19) + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv19) + } else { + z.DecFallback(yyv19, false) + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb26 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb26 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Status = StatefulSetStatus{} + x.Reason = "" } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) + yyv21 := &x.Reason + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv23 := &x.Message + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb26 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb26 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *StatefulSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DeploymentList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym32 := z.EncBinary() - _ = yym32 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [5]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Replicas != nil - yyq33[1] = x.Selector != nil - yyq33[3] = len(x.VolumeClaimTemplates) != 0 - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn33 = 2 - for _, b := range yyq33 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn33++ + yynn2++ } } - r.EncodeMapStart(yynn33) - yynn33 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - if x.Replicas == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - yy35 := *x.Replicas - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeInt(int64(yy35)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) + r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Replicas == nil { - r.EncodeNil() + yym5 := z.EncBinary() + _ = yym5 + if false { } else { - yy37 := *x.Replicas - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeInt(int64(yy37)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - if x.Selector == nil { - r.EncodeNil() + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { } else { - yym40 := z.EncBinary() - _ = yym40 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { } else { - yym41 := z.EncBinary() - _ = yym41 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy43 := &x.Template - yy43.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy44 := &x.Template - yy44.CodecEncodeSelf(e) - } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[3] { - if x.VolumeClaimTemplates == nil { - r.EncodeNil() + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - h.encSlicev1_PersistentVolumeClaim(([]pkg2_v1.PersistentVolumeClaim)(x.VolumeClaimTemplates), e) - } + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq33[3] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumeClaimTemplates")) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.VolumeClaimTemplates == nil { - r.EncodeNil() + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - h.encSlicev1_PersistentVolumeClaim(([]pkg2_v1.PersistentVolumeClaim)(x.VolumeClaimTemplates), e) - } + z.EncFallback(yy12) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym49 := z.EncBinary() - _ = yym49 - if false { + if x.Items == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceDeployment(([]Deployment)(x.Items), e) + } } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("serviceName")) + r.EncodeString(codecSelferC_UTF81234, string("items")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym50 := z.EncBinary() - _ = yym50 - if false { + if x.Items == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceDeployment(([]Deployment)(x.Items), e) + } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -593,29 +6796,29 @@ func (x *StatefulSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *StatefulSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym51 := z.DecBinary() - _ = yym51 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct52 := r.ContainerType() - if yyct52 == codecSelferValueTypeMap1234 { - yyl52 := r.ReadMapStart() - if yyl52 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl52, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct52 == codecSelferValueTypeArray1234 { - yyl52 := r.ReadArrayStart() - if yyl52 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl52, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -623,16 +6826,16 @@ func (x *StatefulSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *StatefulSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys53Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys53Slc - var yyhl53 bool = l >= 0 - for yyj53 := 0; ; yyj53++ { - if yyhl53 { - if yyj53 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -641,292 +6844,344 @@ func (x *StatefulSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys53Slc = r.DecodeBytes(yys53Slc, true, true) - yys53 := string(yys53Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys53 { - case "replicas": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - if x.Replicas != nil { - x.Replicas = nil - } + x.Kind = "" } else { - if x.Replicas == nil { - x.Replicas = new(int32) - } - yym55 := z.DecBinary() - _ = yym55 + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 if false { } else { - *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + *((*string)(yyv4)) = r.DecodeString() } } - case "selector": + case "apiVersion": if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } + x.APIVersion = "" } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym57 := z.DecBinary() - _ = yym57 + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { - z.DecFallback(x.Selector, false) + *((*string)(yyv6)) = r.DecodeString() } } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv58 := &x.Template - yyv58.CodecDecodeSelf(d) - } - case "volumeClaimTemplates": + case "metadata": if r.TryDecodeAsNil() { - x.VolumeClaimTemplates = nil + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv59 := &x.VolumeClaimTemplates - yym60 := z.DecBinary() - _ = yym60 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - h.decSlicev1_PersistentVolumeClaim((*[]pkg2_v1.PersistentVolumeClaim)(yyv59), d) + z.DecFallback(yyv8, false) } } - case "serviceName": + case "items": if r.TryDecodeAsNil() { - x.ServiceName = "" + x.Items = nil } else { - x.ServiceName = string(r.DecodeString()) + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceDeployment((*[]Deployment)(yyv10), d) + } } default: - z.DecStructFieldNotFound(-1, yys53) - } // end switch yys53 - } // end for yyj53 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *StatefulSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj62 int - var yyb62 bool - var yyhl62 bool = l >= 0 - yyj62++ - if yyhl62 { - yyb62 = yyj62 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb62 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb62 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Replicas != nil { - x.Replicas = nil - } + x.Kind = "" } else { - if x.Replicas == nil { - x.Replicas = new(int32) - } - yym64 := z.DecBinary() - _ = yym64 + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 if false { } else { - *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + *((*string)(yyv13)) = r.DecodeString() } } - yyj62++ - if yyhl62 { - yyb62 = yyj62 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb62 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb62 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } + x.APIVersion = "" } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym66 := z.DecBinary() - _ = yym66 + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { - z.DecFallback(x.Selector, false) + *((*string)(yyv15)) = r.DecodeString() } } - yyj62++ - if yyhl62 { - yyb62 = yyj62 > l - } else { - yyb62 = r.CheckBreak() - } - if yyb62 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv67 := &x.Template - yyv67.CodecDecodeSelf(d) - } - yyj62++ - if yyhl62 { - yyb62 = yyj62 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb62 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb62 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.VolumeClaimTemplates = nil + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv68 := &x.VolumeClaimTemplates - yym69 := z.DecBinary() - _ = yym69 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - h.decSlicev1_PersistentVolumeClaim((*[]pkg2_v1.PersistentVolumeClaim)(yyv68), d) + z.DecFallback(yyv17, false) } } - yyj62++ - if yyhl62 { - yyb62 = yyj62 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb62 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb62 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ServiceName = "" + x.Items = nil } else { - x.ServiceName = string(r.DecodeString()) + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceDeployment((*[]Deployment)(yyv19), d) + } } for { - yyj62++ - if yyhl62 { - yyb62 = yyj62 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb62 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb62 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj62-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *StatefulSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ControllerRevision) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym71 := z.EncBinary() - _ = yym71 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep72 := !z.EncBinary() - yy2arr72 := z.EncBasicHandle().StructToArray - var yyq72 [2]bool - _, _, _ = yysep72, yyq72, yy2arr72 - const yyr72 bool = false - yyq72[0] = x.ObservedGeneration != nil - var yynn72 int - if yyr72 || yy2arr72 { - r.EncodeArrayStart(2) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) } else { - yynn72 = 1 - for _, b := range yyq72 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn72++ + yynn2++ } } - r.EncodeMapStart(yynn72) - yynn72 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr72 || yy2arr72 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq72[0] { - if x.ObservedGeneration == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - yy74 := *x.ObservedGeneration - yym75 := z.EncBinary() - _ = yym75 - if false { - } else { - r.EncodeInt(int64(yy74)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq72[0] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ObservedGeneration == nil { - r.EncodeNil() + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - yy76 := *x.ObservedGeneration - yym77 := z.EncBinary() - _ = yym77 - if false { - } else { - r.EncodeInt(int64(yy76)) - } + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Data + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) + } else { + z.EncFallback(yy15) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("data")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Data + yym18 := z.EncBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) + } else { + z.EncFallback(yy17) } } } - if yyr72 || yy2arr72 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym79 := z.EncBinary() - _ = yym79 + yym20 := z.EncBinary() + _ = yym20 if false { } else { - r.EncodeInt(int64(x.Replicas)) + r.EncodeInt(int64(x.Revision)) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) + r.EncodeString(codecSelferC_UTF81234, string("revision")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym80 := z.EncBinary() - _ = yym80 + yym21 := z.EncBinary() + _ = yym21 if false { } else { - r.EncodeInt(int64(x.Replicas)) + r.EncodeInt(int64(x.Revision)) } } - if yyr72 || yy2arr72 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -935,29 +7190,29 @@ func (x *StatefulSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *StatefulSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ControllerRevision) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym81 := z.DecBinary() - _ = yym81 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct82 := r.ContainerType() - if yyct82 == codecSelferValueTypeMap1234 { - yyl82 := r.ReadMapStart() - if yyl82 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl82, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct82 == codecSelferValueTypeArray1234 { - yyl82 := r.ReadArrayStart() - if yyl82 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl82, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -965,16 +7220,16 @@ func (x *StatefulSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *StatefulSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ControllerRevision) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys83Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys83Slc - var yyhl83 bool = l >= 0 - for yyj83 := 0; ; yyj83++ { - if yyhl83 { - if yyj83 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -983,142 +7238,256 @@ func (x *StatefulSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys83Slc = r.DecodeBytes(yys83Slc, true, true) - yys83 := string(yys83Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys83 { - case "observedGeneration": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() } - yym85 := z.DecBinary() - _ = yym85 + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "data": + if r.TryDecodeAsNil() { + x.Data = pkg6_runtime.RawExtension{} + } else { + yyv10 := &x.Data + yym11 := z.DecBinary() + _ = yym11 if false { + } else if z.HasExtensions() && z.DecExt(yyv10) { + } else if !yym11 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv10) } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + z.DecFallback(yyv10, false) } } - case "replicas": + case "revision": if r.TryDecodeAsNil() { - x.Replicas = 0 + x.Revision = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv12 := &x.Revision + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } } default: - z.DecStructFieldNotFound(-1, yys83) - } // end switch yys83 - } // end for yyj83 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *StatefulSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ControllerRevision) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj87 int - var yyb87 bool - var yyhl87 bool = l >= 0 - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb87 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb87 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil + x.Kind = "" + } else { + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv19 := &x.ObjectMeta + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + z.DecFallback(yyv19, false) } - yym89 := z.DecBinary() - _ = yym89 + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Data = pkg6_runtime.RawExtension{} + } else { + yyv21 := &x.Data + yym22 := z.DecBinary() + _ = yym22 if false { + } else if z.HasExtensions() && z.DecExt(yyv21) { + } else if !yym22 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv21) } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + z.DecFallback(yyv21, false) } } - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb87 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb87 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Replicas = 0 + x.Revision = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv23 := &x.Revision + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int64)(yyv23)) = int64(r.DecodeInt(64)) + } } for { - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb87 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb87 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj87-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ControllerRevisionList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym91 := z.EncBinary() - _ = yym91 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep92 := !z.EncBinary() - yy2arr92 := z.EncBasicHandle().StructToArray - var yyq92 [4]bool - _, _, _ = yysep92, yyq92, yy2arr92 - const yyr92 bool = false - yyq92[0] = x.Kind != "" - yyq92[1] = x.APIVersion != "" - yyq92[2] = true - var yynn92 int - if yyr92 || yy2arr92 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn92 = 1 - for _, b := range yyq92 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn92++ + yynn2++ } } - r.EncodeMapStart(yynn92) - yynn92 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr92 || yy2arr92 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq92[0] { - yym94 := z.EncBinary() - _ = yym94 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1127,23 +7496,23 @@ func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq92[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym95 := z.EncBinary() - _ = yym95 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr92 || yy2arr92 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq92[1] { - yym97 := z.EncBinary() - _ = yym97 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1152,57 +7521,57 @@ func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq92[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym98 := z.EncBinary() - _ = yym98 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr92 || yy2arr92 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq92[2] { - yy100 := &x.ListMeta - yym101 := z.EncBinary() - _ = yym101 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy100) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy100) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq92[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy102 := &x.ListMeta - yym103 := z.EncBinary() - _ = yym103 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy102) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy102) + z.EncFallback(yy12) } } } - if yyr92 || yy2arr92 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym105 := z.EncBinary() - _ = yym105 + yym15 := z.EncBinary() + _ = yym15 if false { } else { - h.encSliceStatefulSet(([]StatefulSet)(x.Items), e) + h.encSliceControllerRevision(([]ControllerRevision)(x.Items), e) } } } else { @@ -1212,15 +7581,15 @@ func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym106 := z.EncBinary() - _ = yym106 + yym16 := z.EncBinary() + _ = yym16 if false { } else { - h.encSliceStatefulSet(([]StatefulSet)(x.Items), e) + h.encSliceControllerRevision(([]ControllerRevision)(x.Items), e) } } } - if yyr92 || yy2arr92 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1229,29 +7598,29 @@ func (x *StatefulSetList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *StatefulSetList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ControllerRevisionList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym107 := z.DecBinary() - _ = yym107 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct108 := r.ContainerType() - if yyct108 == codecSelferValueTypeMap1234 { - yyl108 := r.ReadMapStart() - if yyl108 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl108, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct108 == codecSelferValueTypeArray1234 { - yyl108 := r.ReadArrayStart() - if yyl108 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl108, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1259,16 +7628,16 @@ func (x *StatefulSetList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *StatefulSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ControllerRevisionList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys109Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys109Slc - var yyhl109 bool = l >= 0 - for yyj109 := 0; ; yyj109++ { - if yyhl109 { - if yyj109 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1277,68 +7646,80 @@ func (x *StatefulSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys109Slc = r.DecodeBytes(yys109Slc, true, true) - yys109 := string(yys109Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys109 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv112 := &x.ListMeta - yym113 := z.DecBinary() - _ = yym113 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv112) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv112, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv114 := &x.Items - yym115 := z.DecBinary() - _ = yym115 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceStatefulSet((*[]StatefulSet)(yyv114), d) + h.decSliceControllerRevision((*[]ControllerRevision)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys109) - } // end switch yys109 - } // end for yyj109 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *StatefulSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ControllerRevisionList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj116 int - var yyb116 bool - var yyhl116 bool = l >= 0 - yyj116++ - if yyhl116 { - yyb116 = yyj116 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb116 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb116 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1346,15 +7727,21 @@ func (x *StatefulSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj116++ - if yyhl116 { - yyb116 = yyj116 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb116 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb116 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1362,38 +7749,44 @@ func (x *StatefulSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj116++ - if yyhl116 { - yyb116 = yyj116 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb116 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb116 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv119 := &x.ListMeta - yym120 := z.DecBinary() - _ = yym120 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv119) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv119, false) + z.DecFallback(yyv17, false) } } - yyj116++ - if yyhl116 { - yyb116 = yyj116 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb116 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb116 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1401,125 +7794,128 @@ func (x *StatefulSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Items = nil } else { - yyv121 := &x.Items - yym122 := z.DecBinary() - _ = yym122 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceStatefulSet((*[]StatefulSet)(yyv121), d) + h.decSliceControllerRevision((*[]ControllerRevision)(yyv19), d) } } for { - yyj116++ - if yyhl116 { - yyb116 = yyj116 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb116 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb116 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj116-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) encSlicev1_PersistentVolumeClaim(v []pkg2_v1.PersistentVolumeClaim, e *codec1978.Encoder) { +func (x codecSelfer1234) encSlicev1_PersistentVolumeClaim(v []pkg3_v1.PersistentVolumeClaim, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv123 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy124 := &yyv123 - yy124.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) decSlicev1_PersistentVolumeClaim(v *[]pkg2_v1.PersistentVolumeClaim, d *codec1978.Decoder) { +func (x codecSelfer1234) decSlicev1_PersistentVolumeClaim(v *[]pkg3_v1.PersistentVolumeClaim, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv125 := *v - yyh125, yyl125 := z.DecSliceHelperStart() - var yyc125 bool - if yyl125 == 0 { - if yyv125 == nil { - yyv125 = []pkg2_v1.PersistentVolumeClaim{} - yyc125 = true - } else if len(yyv125) != 0 { - yyv125 = yyv125[:0] - yyc125 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []pkg3_v1.PersistentVolumeClaim{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl125 > 0 { - var yyrr125, yyrl125 int - var yyrt125 bool - if yyl125 > cap(yyv125) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg125 := len(yyv125) > 0 - yyv2125 := yyv125 - yyrl125, yyrt125 = z.DecInferLen(yyl125, z.DecBasicHandle().MaxInitLen, 368) - if yyrt125 { - if yyrl125 <= cap(yyv125) { - yyv125 = yyv125[:yyrl125] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 384) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv125 = make([]pkg2_v1.PersistentVolumeClaim, yyrl125) + yyv1 = make([]pkg3_v1.PersistentVolumeClaim, yyrl1) } } else { - yyv125 = make([]pkg2_v1.PersistentVolumeClaim, yyrl125) + yyv1 = make([]pkg3_v1.PersistentVolumeClaim, yyrl1) } - yyc125 = true - yyrr125 = len(yyv125) - if yyrg125 { - copy(yyv125, yyv2125) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl125 != len(yyv125) { - yyv125 = yyv125[:yyl125] - yyc125 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj125 := 0 - for ; yyj125 < yyrr125; yyj125++ { - yyh125.ElemContainerState(yyj125) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv125[yyj125] = pkg2_v1.PersistentVolumeClaim{} + yyv1[yyj1] = pkg3_v1.PersistentVolumeClaim{} } else { - yyv126 := &yyv125[yyj125] - yyv126.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt125 { - for ; yyj125 < yyl125; yyj125++ { - yyv125 = append(yyv125, pkg2_v1.PersistentVolumeClaim{}) - yyh125.ElemContainerState(yyj125) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, pkg3_v1.PersistentVolumeClaim{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv125[yyj125] = pkg2_v1.PersistentVolumeClaim{} + yyv1[yyj1] = pkg3_v1.PersistentVolumeClaim{} } else { - yyv127 := &yyv125[yyj125] - yyv127.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj125 := 0 - for ; !r.CheckBreak(); yyj125++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj125 >= len(yyv125) { - yyv125 = append(yyv125, pkg2_v1.PersistentVolumeClaim{}) // var yyz125 pkg2_v1.PersistentVolumeClaim - yyc125 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, pkg3_v1.PersistentVolumeClaim{}) // var yyz1 pkg3_v1.PersistentVolumeClaim + yyc1 = true } - yyh125.ElemContainerState(yyj125) - if yyj125 < len(yyv125) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv125[yyj125] = pkg2_v1.PersistentVolumeClaim{} + yyv1[yyj1] = pkg3_v1.PersistentVolumeClaim{} } else { - yyv128 := &yyv125[yyj125] - yyv128.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -1527,17 +7923,17 @@ func (x codecSelfer1234) decSlicev1_PersistentVolumeClaim(v *[]pkg2_v1.Persisten } } - if yyj125 < len(yyv125) { - yyv125 = yyv125[:yyj125] - yyc125 = true - } else if yyj125 == 0 && yyv125 == nil { - yyv125 = []pkg2_v1.PersistentVolumeClaim{} - yyc125 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []pkg3_v1.PersistentVolumeClaim{} + yyc1 = true } } - yyh125.End() - if yyc125 { - *v = yyv125 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -1546,10 +7942,10 @@ func (x codecSelfer1234) encSliceStatefulSet(v []StatefulSet, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv129 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy130 := &yyv129 - yy130.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1559,83 +7955,443 @@ func (x codecSelfer1234) decSliceStatefulSet(v *[]StatefulSet, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv131 := *v - yyh131, yyl131 := z.DecSliceHelperStart() - var yyc131 bool - if yyl131 == 0 { - if yyv131 == nil { - yyv131 = []StatefulSet{} - yyc131 = true - } else if len(yyv131) != 0 { - yyv131 = yyv131[:0] - yyc131 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []StatefulSet{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 984) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]StatefulSet, yyrl1) + } + } else { + yyv1 = make([]StatefulSet, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = StatefulSet{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, StatefulSet{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = StatefulSet{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, StatefulSet{}) // var yyz1 StatefulSet + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = StatefulSet{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []StatefulSet{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceDeploymentCondition(v []DeploymentCondition, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceDeploymentCondition(v *[]DeploymentCondition, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []DeploymentCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]DeploymentCondition, yyrl1) + } + } else { + yyv1 = make([]DeploymentCondition, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = DeploymentCondition{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, DeploymentCondition{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = DeploymentCondition{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, DeploymentCondition{}) // var yyz1 DeploymentCondition + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = DeploymentCondition{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []DeploymentCondition{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceDeployment(v []Deployment, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Deployment{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 968) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Deployment, yyrl1) + } + } else { + yyv1 = make([]Deployment, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Deployment{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Deployment{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Deployment{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Deployment{}) // var yyz1 Deployment + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Deployment{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Deployment{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceControllerRevision(v []ControllerRevision, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceControllerRevision(v *[]ControllerRevision, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ControllerRevision{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl131 > 0 { - var yyrr131, yyrl131 int - var yyrt131 bool - if yyl131 > cap(yyv131) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg131 := len(yyv131) > 0 - yyv2131 := yyv131 - yyrl131, yyrt131 = z.DecInferLen(yyl131, z.DecBasicHandle().MaxInitLen, 800) - if yyrt131 { - if yyrl131 <= cap(yyv131) { - yyv131 = yyv131[:yyrl131] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 312) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv131 = make([]StatefulSet, yyrl131) + yyv1 = make([]ControllerRevision, yyrl1) } } else { - yyv131 = make([]StatefulSet, yyrl131) + yyv1 = make([]ControllerRevision, yyrl1) } - yyc131 = true - yyrr131 = len(yyv131) - if yyrg131 { - copy(yyv131, yyv2131) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl131 != len(yyv131) { - yyv131 = yyv131[:yyl131] - yyc131 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj131 := 0 - for ; yyj131 < yyrr131; yyj131++ { - yyh131.ElemContainerState(yyj131) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv131[yyj131] = StatefulSet{} + yyv1[yyj1] = ControllerRevision{} } else { - yyv132 := &yyv131[yyj131] - yyv132.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt131 { - for ; yyj131 < yyl131; yyj131++ { - yyv131 = append(yyv131, StatefulSet{}) - yyh131.ElemContainerState(yyj131) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ControllerRevision{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv131[yyj131] = StatefulSet{} + yyv1[yyj1] = ControllerRevision{} } else { - yyv133 := &yyv131[yyj131] - yyv133.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj131 := 0 - for ; !r.CheckBreak(); yyj131++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj131 >= len(yyv131) { - yyv131 = append(yyv131, StatefulSet{}) // var yyz131 StatefulSet - yyc131 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ControllerRevision{}) // var yyz1 ControllerRevision + yyc1 = true } - yyh131.ElemContainerState(yyj131) - if yyj131 < len(yyv131) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv131[yyj131] = StatefulSet{} + yyv1[yyj1] = ControllerRevision{} } else { - yyv134 := &yyv131[yyj131] - yyv134.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -1643,16 +8399,16 @@ func (x codecSelfer1234) decSliceStatefulSet(v *[]StatefulSet, d *codec1978.Deco } } - if yyj131 < len(yyv131) { - yyv131 = yyv131[:yyj131] - yyc131 = true - } else if yyj131 == 0 && yyv131 == nil { - yyv131 = []StatefulSet{} - yyc131 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ControllerRevision{} + yyc1 = true } } - yyh131.End() - if yyc131 { - *v = yyv131 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go index 0db244eccf..adfd83854a 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types.go @@ -17,10 +17,64 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api/v1" ) +const ( + // StatefulSetInitAnnotation if present, and set to false, indicates that a Pod's readiness should be ignored. + StatefulSetInitAnnotation = "pod.alpha.kubernetes.io/initialized" + ControllerRevisionHashLabelKey = "controller-revision-hash" + StatefulSetRevisionLabel = ControllerRevisionHashLabelKey +) + +// ScaleSpec describes the attributes of a scale subresource +type ScaleSpec struct { + // desired number of instances for the scaled object. + // +optional + Replicas int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"` +} + +// ScaleStatus represents the current status of a scale subresource. +type ScaleStatus struct { + // actual number of observed instances of the scaled object. + Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"` + + // label query over pods that should match the replicas count. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // +optional + Selector map[string]string `json:"selector,omitempty" protobuf:"bytes,2,rep,name=selector"` + + // label selector for pods that should match the replicas count. This is a serializated + // version of both map-based and more expressive set-based selectors. This is done to + // avoid introspection in the clients. The string will be in the same format as the + // query-param syntax. If the target type only supports map-based selectors, both this + // field and map-based selector field are populated. + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors + // +optional + TargetSelector string `json:"targetSelector,omitempty" protobuf:"bytes,3,opt,name=targetSelector"` +} + +// +genclient=true +// +noMethods=true + +// Scale represents a scaling request for a resource. +type Scale struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + // +optional + Spec ScaleSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. + // +optional + Status ScaleStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + // +genclient=true // StatefulSet represents a set of pods with consistent identities. @@ -30,9 +84,9 @@ import ( // The StatefulSet guarantees that a given network identity will always // map to the same storage identity. type StatefulSet struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the desired identities of pods in this set. // +optional @@ -44,9 +98,60 @@ type StatefulSet struct { Status StatefulSetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } +// PodManagementPolicyType defines the policy for creating pods under a stateful set. +type PodManagementPolicyType string + +const ( + // OrderedReadyPodManagement will create pods in strictly increasing order on + // scale up and strictly decreasing order on scale down, progressing only when + // the previous pod is ready or terminated. At most one pod will be changed + // at any time. + OrderedReadyPodManagement PodManagementPolicyType = "OrderedReady" + // ParallelPodManagement will create and delete pods as soon as the stateful set + // replica count is changed, and will not wait for pods to be ready or complete + // termination. + ParallelPodManagement = "Parallel" +) + +// StatefulSetUpdateStrategy indicates the strategy that the StatefulSet +// controller will use to perform updates. It includes any additional parameters +// necessary to perform the update for the indicated strategy. +type StatefulSetUpdateStrategy struct { + // Type indicates the type of the StatefulSetUpdateStrategy. + Type StatefulSetUpdateStrategyType `json:"type,omitempty" protobuf:"bytes,1,opt,name=type,casttype=StatefulSetStrategyType"` + // RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType. + RollingUpdate *RollingUpdateStatefulSetStrategy `json:"rollingUpdate,omitempty" protobuf:"bytes,2,opt,name=rollingUpdate"` +} + +// StatefulSetUpdateStrategyType is a string enumeration type that enumerates +// all possible update strategies for the StatefulSet controller. +type StatefulSetUpdateStrategyType string + +const ( + // RollingUpdateStatefulSetStrategyType indicates that update will be + // applied to all Pods in the StatefulSet with respect to the StatefulSet + // ordering constraints. When a scale operation is performed with this + // strategy, new Pods will be created from the specification version indicated + // by the StatefulSet's updateRevision. + RollingUpdateStatefulSetStrategyType = "RollingUpdate" + // OnDeleteStatefulSetStrategyType triggers the legacy behavior. Version + // tracking and ordered rolling restarts are disabled. Pods are recreated + // from the StatefulSetSpec when they are manually deleted. When a scale + // operation is performed with this strategy,specification version indicated + // by the StatefulSet's currentRevision. + OnDeleteStatefulSetStrategyType = "OnDelete" +) + +// RollingUpdateStatefulSetStrategy is used to communicate parameter for RollingUpdateStatefulSetStrategyType. +type RollingUpdateStatefulSetStrategy struct { + // Partition indicates the ordinal at which the StatefulSet should be + // partitioned. + Partition *int32 `json:"partition,omitempty" protobuf:"varint,1,opt,name=partition"` +} + // A StatefulSetSpec is the specification of a StatefulSet. type StatefulSetSpec struct { - // Replicas is the desired number of replicas of the given Template. + // replicas is the desired number of replicas of the given Template. // These are replicas in the sense that they are instantiations of the // same Template, but individual replicas also have a consistent identity. // If unspecified, defaults to 1. @@ -54,19 +159,19 @@ type StatefulSetSpec struct { // +optional Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"` - // Selector is a label query over pods that should match the replica count. + // selector is a label query over pods that should match the replica count. // If empty, defaulted to labels on the pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` - // Template is the object that describes the pod that will be created if + // template is the object that describes the pod that will be created if // insufficient replicas are detected. Each pod stamped out by the StatefulSet // will fulfill this Template, but have a unique identity from the rest // of the StatefulSet. Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,3,opt,name=template"` - // VolumeClaimTemplates is a list of claims that pods are allowed to reference. + // volumeClaimTemplates is a list of claims that pods are allowed to reference. // The StatefulSet controller is responsible for mapping network identities to // claims in a way that maintains the identity of a pod. Every claim in // this list must have at least one matching (by name) volumeMount in one @@ -76,28 +181,336 @@ type StatefulSetSpec struct { // +optional VolumeClaimTemplates []v1.PersistentVolumeClaim `json:"volumeClaimTemplates,omitempty" protobuf:"bytes,4,rep,name=volumeClaimTemplates"` - // ServiceName is the name of the service that governs this StatefulSet. + // serviceName is the name of the service that governs this StatefulSet. // This service must exist before the StatefulSet, and is responsible for // the network identity of the set. Pods get DNS/hostnames that follow the // pattern: pod-specific-string.serviceName.default.svc.cluster.local // where "pod-specific-string" is managed by the StatefulSet controller. ServiceName string `json:"serviceName" protobuf:"bytes,5,opt,name=serviceName"` + + // podManagementPolicy controls how pods are created during initial scale up, + // when replacing pods on nodes, or when scaling down. The default policy is + // `OrderedReady`, where pods are created in increasing order (pod-0, then + // pod-1, etc) and the controller will wait until each pod is ready before + // continuing. When scaling down, the pods are removed in the opposite order. + // The alternative policy is `Parallel` which will create pods in parallel + // to match the desired scale without waiting, and on scale down will delete + // all pods at once. + // +optional + PodManagementPolicy PodManagementPolicyType `json:"podManagementPolicy,omitempty" protobuf:"bytes,6,opt,name=podManagementPolicy,casttype=PodManagementPolicyType"` + + // updateStrategy indicates the StatefulSetUpdateStrategy that will be + // employed to update Pods in the StatefulSet when a revision is made to + // Template. + UpdateStrategy StatefulSetUpdateStrategy `json:"updateStrategy,omitempty" protobuf:"bytes,7,opt,name=updateStrategy"` + + // revisionHistoryLimit is the maximum number of revisions that will + // be maintained in the StatefulSet's revision history. The revision history + // consists of all revisions not represented by a currently applied + // StatefulSetSpec version. The default value is 10. + RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty" protobuf:"varint,8,opt,name=revisionHistoryLimit"` } // StatefulSetStatus represents the current state of a StatefulSet. type StatefulSetStatus struct { - // most recent generation observed by this autoscaler. + // observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the + // StatefulSet's generation, which is updated on mutation by the API Server. // +optional ObservedGeneration *int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"` - // Replicas is the number of actual replicas. + // replicas is the number of Pods created by the StatefulSet controller. Replicas int32 `json:"replicas" protobuf:"varint,2,opt,name=replicas"` + + // readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition. + ReadyReplicas int32 `json:"readyReplicas,omitempty" protobuf:"varint,3,opt,name=readyReplicas"` + + // currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version + // indicated by currentRevision. + CurrentReplicas int32 `json:"currentReplicas,omitempty" protobuf:"varint,4,opt,name=currentReplicas"` + + // updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version + // indicated by updateRevision. + UpdatedReplicas int32 `json:"updatedReplicas,omitempty" protobuf:"varint,5,opt,name=updatedReplicas"` + + // currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the + // sequence [0,currentReplicas). + CurrentRevision string `json:"currentRevision,omitempty" protobuf:"bytes,6,opt,name=currentRevision"` + + // updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence + // [replicas-updatedReplicas,replicas) + UpdateRevision string `json:"updateRevision,omitempty" protobuf:"bytes,7,opt,name=updateRevision"` } // StatefulSetList is a collection of StatefulSets. type StatefulSetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []StatefulSet `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// +genclient=true + +// Deployment enables declarative updates for Pods and ReplicaSets. +type Deployment struct { + metav1.TypeMeta `json:",inline"` + // Standard object metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Specification of the desired behavior of the Deployment. + // +optional + Spec DeploymentSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + + // Most recently observed status of the Deployment. + // +optional + Status DeploymentStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// DeploymentSpec is the specification of the desired behavior of the Deployment. +type DeploymentSpec struct { + // Number of desired pods. This is a pointer to distinguish between explicit + // zero and not specified. Defaults to 1. + // +optional + Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"` + + // Label selector for pods. Existing ReplicaSets whose pods are + // selected by this will be the ones affected by this deployment. + // +optional + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` + + // Template describes the pods that will be created. + Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,3,opt,name=template"` + + // The deployment strategy to use to replace existing pods with new ones. + // +optional + Strategy DeploymentStrategy `json:"strategy,omitempty" protobuf:"bytes,4,opt,name=strategy"` + + // Minimum number of seconds for which a newly created pod should be ready + // without any of its container crashing, for it to be considered available. + // Defaults to 0 (pod will be considered available as soon as it is ready) + // +optional + MinReadySeconds int32 `json:"minReadySeconds,omitempty" protobuf:"varint,5,opt,name=minReadySeconds"` + + // The number of old ReplicaSets to retain to allow rollback. + // This is a pointer to distinguish between explicit zero and not specified. + // Defaults to 2. + // +optional + RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty" protobuf:"varint,6,opt,name=revisionHistoryLimit"` + + // Indicates that the deployment is paused. + // +optional + Paused bool `json:"paused,omitempty" protobuf:"varint,7,opt,name=paused"` + + // The config this deployment is rolling back to. Will be cleared after rollback is done. + // +optional + RollbackTo *RollbackConfig `json:"rollbackTo,omitempty" protobuf:"bytes,8,opt,name=rollbackTo"` + + // The maximum time in seconds for a deployment to make progress before it + // is considered to be failed. The deployment controller will continue to + // process failed deployments and a condition with a ProgressDeadlineExceeded + // reason will be surfaced in the deployment status. Once autoRollback is + // implemented, the deployment controller will automatically rollback failed + // deployments. Note that progress will not be estimated during the time a + // deployment is paused. Defaults to 600s. + ProgressDeadlineSeconds *int32 `json:"progressDeadlineSeconds,omitempty" protobuf:"varint,9,opt,name=progressDeadlineSeconds"` +} + +// DeploymentRollback stores the information required to rollback a deployment. +type DeploymentRollback struct { + metav1.TypeMeta `json:",inline"` + // Required: This must match the Name of a deployment. + Name string `json:"name" protobuf:"bytes,1,opt,name=name"` + // The annotations to be updated to a deployment + // +optional + UpdatedAnnotations map[string]string `json:"updatedAnnotations,omitempty" protobuf:"bytes,2,rep,name=updatedAnnotations"` + // The config of this deployment rollback. + RollbackTo RollbackConfig `json:"rollbackTo" protobuf:"bytes,3,opt,name=rollbackTo"` +} + +type RollbackConfig struct { + // The revision to rollback to. If set to 0, rollback to the last revision. + // +optional + Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"` +} + +const ( + // DefaultDeploymentUniqueLabelKey is the default key of the selector that is added + // to existing RCs (and label key that is added to its pods) to prevent the existing RCs + // to select new pods (and old pods being select by new RC). + DefaultDeploymentUniqueLabelKey string = "pod-template-hash" +) + +// DeploymentStrategy describes how to replace existing pods with new ones. +type DeploymentStrategy struct { + // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. + // +optional + Type DeploymentStrategyType `json:"type,omitempty" protobuf:"bytes,1,opt,name=type,casttype=DeploymentStrategyType"` + + // Rolling update config params. Present only if DeploymentStrategyType = + // RollingUpdate. + //--- + // TODO: Update this to follow our convention for oneOf, whatever we decide it + // to be. + // +optional + RollingUpdate *RollingUpdateDeployment `json:"rollingUpdate,omitempty" protobuf:"bytes,2,opt,name=rollingUpdate"` +} + +type DeploymentStrategyType string + +const ( + // Kill all existing pods before creating new ones. + RecreateDeploymentStrategyType DeploymentStrategyType = "Recreate" + + // Replace the old RCs by new one using rolling update i.e gradually scale down the old RCs and scale up the new one. + RollingUpdateDeploymentStrategyType DeploymentStrategyType = "RollingUpdate" +) + +// Spec to control the desired behavior of rolling update. +type RollingUpdateDeployment struct { + // The maximum number of pods that can be unavailable during the update. + // Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). + // Absolute number is calculated from percentage by rounding down. + // This can not be 0 if MaxSurge is 0. + // Defaults to 25%. + // Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods + // immediately when the rolling update starts. Once new pods are ready, old RC + // can be scaled down further, followed by scaling up the new RC, ensuring + // that the total number of pods available at all times during the update is at + // least 70% of desired pods. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []StatefulSet `json:"items" protobuf:"bytes,2,rep,name=items"` + MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty" protobuf:"bytes,1,opt,name=maxUnavailable"` + + // The maximum number of pods that can be scheduled above the desired number of + // pods. + // Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). + // This can not be 0 if MaxUnavailable is 0. + // Absolute number is calculated from percentage by rounding up. + // Defaults to 25%. + // Example: when this is set to 30%, the new RC can be scaled up immediately when + // the rolling update starts, such that the total number of old and new pods do not exceed + // 130% of desired pods. Once old pods have been killed, + // new RC can be scaled up further, ensuring that total number of pods running + // at any time during the update is atmost 130% of desired pods. + // +optional + MaxSurge *intstr.IntOrString `json:"maxSurge,omitempty" protobuf:"bytes,2,opt,name=maxSurge"` +} + +// DeploymentStatus is the most recently observed status of the Deployment. +type DeploymentStatus struct { + // The generation observed by the deployment controller. + // +optional + ObservedGeneration int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"` + + // Total number of non-terminated pods targeted by this deployment (their labels match the selector). + // +optional + Replicas int32 `json:"replicas,omitempty" protobuf:"varint,2,opt,name=replicas"` + + // Total number of non-terminated pods targeted by this deployment that have the desired template spec. + // +optional + UpdatedReplicas int32 `json:"updatedReplicas,omitempty" protobuf:"varint,3,opt,name=updatedReplicas"` + + // Total number of ready pods targeted by this deployment. + // +optional + ReadyReplicas int32 `json:"readyReplicas,omitempty" protobuf:"varint,7,opt,name=readyReplicas"` + + // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. + // +optional + AvailableReplicas int32 `json:"availableReplicas,omitempty" protobuf:"varint,4,opt,name=availableReplicas"` + + // Total number of unavailable pods targeted by this deployment. + // +optional + UnavailableReplicas int32 `json:"unavailableReplicas,omitempty" protobuf:"varint,5,opt,name=unavailableReplicas"` + + // Represents the latest available observations of a deployment's current state. + // +patchMergeKey=type + // +patchStrategy=merge + Conditions []DeploymentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,6,rep,name=conditions"` + + // Count of hash collisions for the Deployment. The Deployment controller uses this + // field as a collision avoidance mechanism when it needs to create the name for the + // newest ReplicaSet. + // +optional + CollisionCount *int64 `json:"collisionCount,omitempty" protobuf:"varint,8,opt,name=collisionCount"` +} + +type DeploymentConditionType string + +// These are valid conditions of a deployment. +const ( + // Available means the deployment is available, ie. at least the minimum available + // replicas required are up and running for at least minReadySeconds. + DeploymentAvailable DeploymentConditionType = "Available" + // Progressing means the deployment is progressing. Progress for a deployment is + // considered when a new replica set is created or adopted, and when new pods scale + // up or old pods scale down. Progress is not estimated for paused deployments or + // when progressDeadlineSeconds is not specified. + DeploymentProgressing DeploymentConditionType = "Progressing" + // ReplicaFailure is added in a deployment when one of its pods fails to be created + // or deleted. + DeploymentReplicaFailure DeploymentConditionType = "ReplicaFailure" +) + +// DeploymentCondition describes the state of a deployment at a certain point. +type DeploymentCondition struct { + // Type of deployment condition. + Type DeploymentConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=DeploymentConditionType"` + // Status of the condition, one of True, False, Unknown. + Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"` + // The last time this condition was updated. + LastUpdateTime metav1.Time `json:"lastUpdateTime,omitempty" protobuf:"bytes,6,opt,name=lastUpdateTime"` + // Last time the condition transitioned from one status to another. + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,7,opt,name=lastTransitionTime"` + // The reason for the condition's last transition. + Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` + // A human readable message indicating details about the transition. + Message string `json:"message,omitempty" protobuf:"bytes,5,opt,name=message"` +} + +// DeploymentList is a list of Deployments. +type DeploymentList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is the list of Deployments. + Items []Deployment `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// +genclient=true + +// ControllerRevision implements an immutable snapshot of state data. Clients +// are responsible for serializing and deserializing the objects that contain +// their internal state. +// Once a ControllerRevision has been successfully created, it can not be updated. +// The API Server will fail validation of all requests that attempt to mutate +// the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both +// the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, +// it may be subject to name and representation changes in future releases, and clients should not +// depend on its stability. It is primarily for internal use by controllers. +type ControllerRevision struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Data is the serialized representation of the state. + Data runtime.RawExtension `json:"data,omitempty" protobuf:"bytes,2,opt,name=data"` + + // Revision indicates the revision of the state represented by Data. + Revision int64 `json:"revision" protobuf:"varint,3,opt,name=revision"` +} + +// ControllerRevisionList is a resource containing a list of ControllerRevision objects. +type ControllerRevisionList struct { + metav1.TypeMeta `json:",inline"` + + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is the list of ControllerRevisions + Items []ControllerRevision `json:"items" protobuf:"bytes,2,rep,name=items"` } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go index 837181c1c0..00d1a617fc 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/types_swagger_doc_generated.go @@ -27,6 +27,174 @@ package v1beta1 // Those methods can be generated by using hack/update-generated-swagger-docs.sh // AUTO-GENERATED FUNCTIONS START HERE +var map_ControllerRevision = map[string]string{ + "": "ControllerRevision implements an immutable snapshot of state data. Clients are responsible for serializing and deserializing the objects that contain their internal state. Once a ControllerRevision has been successfully created, it can not be updated. The API Server will fail validation of all requests that attempt to mutate the Data field. ControllerRevisions may, however, be deleted. Note that, due to its use by both the DaemonSet and StatefulSet controllers for update and rollback, this object is beta. However, it may be subject to name and representation changes in future releases, and clients should not depend on its stability. It is primarily for internal use by controllers.", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "data": "Data is the serialized representation of the state.", + "revision": "Revision indicates the revision of the state represented by Data.", +} + +func (ControllerRevision) SwaggerDoc() map[string]string { + return map_ControllerRevision +} + +var map_ControllerRevisionList = map[string]string{ + "": "ControllerRevisionList is a resource containing a list of ControllerRevision objects.", + "metadata": "More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "Items is the list of ControllerRevisions", +} + +func (ControllerRevisionList) SwaggerDoc() map[string]string { + return map_ControllerRevisionList +} + +var map_Deployment = map[string]string{ + "": "Deployment enables declarative updates for Pods and ReplicaSets.", + "metadata": "Standard object metadata.", + "spec": "Specification of the desired behavior of the Deployment.", + "status": "Most recently observed status of the Deployment.", +} + +func (Deployment) SwaggerDoc() map[string]string { + return map_Deployment +} + +var map_DeploymentCondition = map[string]string{ + "": "DeploymentCondition describes the state of a deployment at a certain point.", + "type": "Type of deployment condition.", + "status": "Status of the condition, one of True, False, Unknown.", + "lastUpdateTime": "The last time this condition was updated.", + "lastTransitionTime": "Last time the condition transitioned from one status to another.", + "reason": "The reason for the condition's last transition.", + "message": "A human readable message indicating details about the transition.", +} + +func (DeploymentCondition) SwaggerDoc() map[string]string { + return map_DeploymentCondition +} + +var map_DeploymentList = map[string]string{ + "": "DeploymentList is a list of Deployments.", + "metadata": "Standard list metadata.", + "items": "Items is the list of Deployments.", +} + +func (DeploymentList) SwaggerDoc() map[string]string { + return map_DeploymentList +} + +var map_DeploymentRollback = map[string]string{ + "": "DeploymentRollback stores the information required to rollback a deployment.", + "name": "Required: This must match the Name of a deployment.", + "updatedAnnotations": "The annotations to be updated to a deployment", + "rollbackTo": "The config of this deployment rollback.", +} + +func (DeploymentRollback) SwaggerDoc() map[string]string { + return map_DeploymentRollback +} + +var map_DeploymentSpec = map[string]string{ + "": "DeploymentSpec is the specification of the desired behavior of the Deployment.", + "replicas": "Number of desired pods. This is a pointer to distinguish between explicit zero and not specified. Defaults to 1.", + "selector": "Label selector for pods. Existing ReplicaSets whose pods are selected by this will be the ones affected by this deployment.", + "template": "Template describes the pods that will be created.", + "strategy": "The deployment strategy to use to replace existing pods with new ones.", + "minReadySeconds": "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", + "revisionHistoryLimit": "The number of old ReplicaSets to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 2.", + "paused": "Indicates that the deployment is paused.", + "rollbackTo": "The config this deployment is rolling back to. Will be cleared after rollback is done.", + "progressDeadlineSeconds": "The maximum time in seconds for a deployment to make progress before it is considered to be failed. The deployment controller will continue to process failed deployments and a condition with a ProgressDeadlineExceeded reason will be surfaced in the deployment status. Once autoRollback is implemented, the deployment controller will automatically rollback failed deployments. Note that progress will not be estimated during the time a deployment is paused. Defaults to 600s.", +} + +func (DeploymentSpec) SwaggerDoc() map[string]string { + return map_DeploymentSpec +} + +var map_DeploymentStatus = map[string]string{ + "": "DeploymentStatus is the most recently observed status of the Deployment.", + "observedGeneration": "The generation observed by the deployment controller.", + "replicas": "Total number of non-terminated pods targeted by this deployment (their labels match the selector).", + "updatedReplicas": "Total number of non-terminated pods targeted by this deployment that have the desired template spec.", + "readyReplicas": "Total number of ready pods targeted by this deployment.", + "availableReplicas": "Total number of available pods (ready for at least minReadySeconds) targeted by this deployment.", + "unavailableReplicas": "Total number of unavailable pods targeted by this deployment.", + "conditions": "Represents the latest available observations of a deployment's current state.", + "collisionCount": "Count of hash collisions for the Deployment. The Deployment controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ReplicaSet.", +} + +func (DeploymentStatus) SwaggerDoc() map[string]string { + return map_DeploymentStatus +} + +var map_DeploymentStrategy = map[string]string{ + "": "DeploymentStrategy describes how to replace existing pods with new ones.", + "type": "Type of deployment. Can be \"Recreate\" or \"RollingUpdate\". Default is RollingUpdate.", + "rollingUpdate": "Rolling update config params. Present only if DeploymentStrategyType = RollingUpdate.", +} + +func (DeploymentStrategy) SwaggerDoc() map[string]string { + return map_DeploymentStrategy +} + +var map_RollbackConfig = map[string]string{ + "revision": "The revision to rollback to. If set to 0, rollback to the last revision.", +} + +func (RollbackConfig) SwaggerDoc() map[string]string { + return map_RollbackConfig +} + +var map_RollingUpdateDeployment = map[string]string{ + "": "Spec to control the desired behavior of rolling update.", + "maxUnavailable": "The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. Defaults to 25%. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods.", + "maxSurge": "The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. Defaults to 25%. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods.", +} + +func (RollingUpdateDeployment) SwaggerDoc() map[string]string { + return map_RollingUpdateDeployment +} + +var map_RollingUpdateStatefulSetStrategy = map[string]string{ + "": "RollingUpdateStatefulSetStrategy is used to communicate parameter for RollingUpdateStatefulSetStrategyType.", + "partition": "Partition indicates the ordinal at which the StatefulSet should be partitioned.", +} + +func (RollingUpdateStatefulSetStrategy) SwaggerDoc() map[string]string { + return map_RollingUpdateStatefulSetStrategy +} + +var map_Scale = map[string]string{ + "": "Scale represents a scaling request for a resource.", + "metadata": "Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata.", + "spec": "defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + "status": "current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only.", +} + +func (Scale) SwaggerDoc() map[string]string { + return map_Scale +} + +var map_ScaleSpec = map[string]string{ + "": "ScaleSpec describes the attributes of a scale subresource", + "replicas": "desired number of instances for the scaled object.", +} + +func (ScaleSpec) SwaggerDoc() map[string]string { + return map_ScaleSpec +} + +var map_ScaleStatus = map[string]string{ + "": "ScaleStatus represents the current status of a scale subresource.", + "replicas": "actual number of observed instances of the scaled object.", + "selector": "label query over pods that should match the replicas count. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", + "targetSelector": "label selector for pods that should match the replicas count. This is a serializated version of both map-based and more expressive set-based selectors. This is done to avoid introspection in the clients. The string will be in the same format as the query-param syntax. If the target type only supports map-based selectors, both this field and map-based selector field are populated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", +} + +func (ScaleStatus) SwaggerDoc() map[string]string { + return map_ScaleStatus +} + var map_StatefulSet = map[string]string{ "": "StatefulSet represents a set of pods with consistent identities. Identities are defined as:\n - Network: A single stable DNS and hostname.\n - Storage: As many VolumeClaims as requested.\nThe StatefulSet guarantees that a given network identity will always map to the same storage identity.", "spec": "Spec defines the desired identities of pods in this set.", @@ -47,11 +215,14 @@ func (StatefulSetList) SwaggerDoc() map[string]string { var map_StatefulSetSpec = map[string]string{ "": "A StatefulSetSpec is the specification of a StatefulSet.", - "replicas": "Replicas is the desired number of replicas of the given Template. These are replicas in the sense that they are instantiations of the same Template, but individual replicas also have a consistent identity. If unspecified, defaults to 1.", - "selector": "Selector is a label query over pods that should match the replica count. If empty, defaulted to labels on the pod template. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "template": "Template is the object that describes the pod that will be created if insufficient replicas are detected. Each pod stamped out by the StatefulSet will fulfill this Template, but have a unique identity from the rest of the StatefulSet.", - "volumeClaimTemplates": "VolumeClaimTemplates is a list of claims that pods are allowed to reference. The StatefulSet controller is responsible for mapping network identities to claims in a way that maintains the identity of a pod. Every claim in this list must have at least one matching (by name) volumeMount in one container in the template. A claim in this list takes precedence over any volumes in the template, with the same name.", - "serviceName": "ServiceName is the name of the service that governs this StatefulSet. This service must exist before the StatefulSet, and is responsible for the network identity of the set. Pods get DNS/hostnames that follow the pattern: pod-specific-string.serviceName.default.svc.cluster.local where \"pod-specific-string\" is managed by the StatefulSet controller.", + "replicas": "replicas is the desired number of replicas of the given Template. These are replicas in the sense that they are instantiations of the same Template, but individual replicas also have a consistent identity. If unspecified, defaults to 1.", + "selector": "selector is a label query over pods that should match the replica count. If empty, defaulted to labels on the pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", + "template": "template is the object that describes the pod that will be created if insufficient replicas are detected. Each pod stamped out by the StatefulSet will fulfill this Template, but have a unique identity from the rest of the StatefulSet.", + "volumeClaimTemplates": "volumeClaimTemplates is a list of claims that pods are allowed to reference. The StatefulSet controller is responsible for mapping network identities to claims in a way that maintains the identity of a pod. Every claim in this list must have at least one matching (by name) volumeMount in one container in the template. A claim in this list takes precedence over any volumes in the template, with the same name.", + "serviceName": "serviceName is the name of the service that governs this StatefulSet. This service must exist before the StatefulSet, and is responsible for the network identity of the set. Pods get DNS/hostnames that follow the pattern: pod-specific-string.serviceName.default.svc.cluster.local where \"pod-specific-string\" is managed by the StatefulSet controller.", + "podManagementPolicy": "podManagementPolicy controls how pods are created during initial scale up, when replacing pods on nodes, or when scaling down. The default policy is `OrderedReady`, where pods are created in increasing order (pod-0, then pod-1, etc) and the controller will wait until each pod is ready before continuing. When scaling down, the pods are removed in the opposite order. The alternative policy is `Parallel` which will create pods in parallel to match the desired scale without waiting, and on scale down will delete all pods at once.", + "updateStrategy": "updateStrategy indicates the StatefulSetUpdateStrategy that will be employed to update Pods in the StatefulSet when a revision is made to Template.", + "revisionHistoryLimit": "revisionHistoryLimit is the maximum number of revisions that will be maintained in the StatefulSet's revision history. The revision history consists of all revisions not represented by a currently applied StatefulSetSpec version. The default value is 10.", } func (StatefulSetSpec) SwaggerDoc() map[string]string { @@ -60,12 +231,27 @@ func (StatefulSetSpec) SwaggerDoc() map[string]string { var map_StatefulSetStatus = map[string]string{ "": "StatefulSetStatus represents the current state of a StatefulSet.", - "observedGeneration": "most recent generation observed by this autoscaler.", - "replicas": "Replicas is the number of actual replicas.", + "observedGeneration": "observedGeneration is the most recent generation observed for this StatefulSet. It corresponds to the StatefulSet's generation, which is updated on mutation by the API Server.", + "replicas": "replicas is the number of Pods created by the StatefulSet controller.", + "readyReplicas": "readyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition.", + "currentReplicas": "currentReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by currentRevision.", + "updatedReplicas": "updatedReplicas is the number of Pods created by the StatefulSet controller from the StatefulSet version indicated by updateRevision.", + "currentRevision": "currentRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [0,currentReplicas).", + "updateRevision": "updateRevision, if not empty, indicates the version of the StatefulSet used to generate Pods in the sequence [replicas-updatedReplicas,replicas)", } func (StatefulSetStatus) SwaggerDoc() map[string]string { return map_StatefulSetStatus } +var map_StatefulSetUpdateStrategy = map[string]string{ + "": "StatefulSetUpdateStrategy indicates the strategy that the StatefulSet controller will use to perform updates. It includes any additional parameters necessary to perform the update for the indicated strategy.", + "type": "Type indicates the type of the StatefulSetUpdateStrategy.", + "rollingUpdate": "RollingUpdate is used to communicate parameters when Type is RollingUpdateStatefulSetStrategyType.", +} + +func (StatefulSetUpdateStrategy) SwaggerDoc() map[string]string { + return map_StatefulSetUpdateStrategy +} + // AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go index 0f2f051927..c2c25db82e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,12 +21,12 @@ limitations under the License. package v1beta1 import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" + api_v1 "k8s.io/client-go/pkg/api/v1" apps "k8s.io/client-go/pkg/apis/apps" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -38,6 +38,12 @@ func init() { // Public to allow building arbitrary schemes. func RegisterConversions(scheme *runtime.Scheme) error { return scheme.AddGeneratedConversionFuncs( + Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision, + Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision, + Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList, + Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList, + Convert_v1beta1_RollingUpdateStatefulSetStrategy_To_apps_RollingUpdateStatefulSetStrategy, + Convert_apps_RollingUpdateStatefulSetStrategy_To_v1beta1_RollingUpdateStatefulSetStrategy, Convert_v1beta1_StatefulSet_To_apps_StatefulSet, Convert_apps_StatefulSet_To_v1beta1_StatefulSet, Convert_v1beta1_StatefulSetList_To_apps_StatefulSetList, @@ -46,14 +52,107 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_apps_StatefulSetSpec_To_v1beta1_StatefulSetSpec, Convert_v1beta1_StatefulSetStatus_To_apps_StatefulSetStatus, Convert_apps_StatefulSetStatus_To_v1beta1_StatefulSetStatus, + Convert_v1beta1_StatefulSetUpdateStrategy_To_apps_StatefulSetUpdateStrategy, + Convert_apps_StatefulSetUpdateStrategy_To_v1beta1_StatefulSetUpdateStrategy, ) } -func autoConvert_v1beta1_StatefulSet_To_apps_StatefulSet(in *StatefulSet, out *apps.StatefulSet, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { +func autoConvert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in *ControllerRevision, out *apps.ControllerRevision, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := runtime.Convert_runtime_RawExtension_To_runtime_Object(&in.Data, &out.Data, s); err != nil { + return err + } + out.Revision = in.Revision + return nil +} + +// Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision is an autogenerated conversion function. +func Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in *ControllerRevision, out *apps.ControllerRevision, s conversion.Scope) error { + return autoConvert_v1beta1_ControllerRevision_To_apps_ControllerRevision(in, out, s) +} + +func autoConvert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in *apps.ControllerRevision, out *ControllerRevision, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := runtime.Convert_runtime_Object_To_runtime_RawExtension(&in.Data, &out.Data, s); err != nil { + return err + } + out.Revision = in.Revision + return nil +} + +// Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision is an autogenerated conversion function. +func Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in *apps.ControllerRevision, out *ControllerRevision, s conversion.Scope) error { + return autoConvert_apps_ControllerRevision_To_v1beta1_ControllerRevision(in, out, s) +} + +func autoConvert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in *ControllerRevisionList, out *apps.ControllerRevisionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]apps.ControllerRevision, len(*in)) + for i := range *in { + if err := Convert_v1beta1_ControllerRevision_To_apps_ControllerRevision(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } + return nil +} + +// Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList is an autogenerated conversion function. +func Convert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in *ControllerRevisionList, out *apps.ControllerRevisionList, s conversion.Scope) error { + return autoConvert_v1beta1_ControllerRevisionList_To_apps_ControllerRevisionList(in, out, s) +} + +func autoConvert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in *apps.ControllerRevisionList, out *ControllerRevisionList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := Convert_apps_ControllerRevision_To_v1beta1_ControllerRevision(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = make([]ControllerRevision, 0) + } + return nil +} + +// Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList is an autogenerated conversion function. +func Convert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in *apps.ControllerRevisionList, out *ControllerRevisionList, s conversion.Scope) error { + return autoConvert_apps_ControllerRevisionList_To_v1beta1_ControllerRevisionList(in, out, s) +} + +func autoConvert_v1beta1_RollingUpdateStatefulSetStrategy_To_apps_RollingUpdateStatefulSetStrategy(in *RollingUpdateStatefulSetStrategy, out *apps.RollingUpdateStatefulSetStrategy, s conversion.Scope) error { + if err := v1.Convert_Pointer_int32_To_int32(&in.Partition, &out.Partition, s); err != nil { return err } + return nil +} + +// Convert_v1beta1_RollingUpdateStatefulSetStrategy_To_apps_RollingUpdateStatefulSetStrategy is an autogenerated conversion function. +func Convert_v1beta1_RollingUpdateStatefulSetStrategy_To_apps_RollingUpdateStatefulSetStrategy(in *RollingUpdateStatefulSetStrategy, out *apps.RollingUpdateStatefulSetStrategy, s conversion.Scope) error { + return autoConvert_v1beta1_RollingUpdateStatefulSetStrategy_To_apps_RollingUpdateStatefulSetStrategy(in, out, s) +} + +func autoConvert_apps_RollingUpdateStatefulSetStrategy_To_v1beta1_RollingUpdateStatefulSetStrategy(in *apps.RollingUpdateStatefulSetStrategy, out *RollingUpdateStatefulSetStrategy, s conversion.Scope) error { + if err := v1.Convert_int32_To_Pointer_int32(&in.Partition, &out.Partition, s); err != nil { + return err + } + return nil +} + +// Convert_apps_RollingUpdateStatefulSetStrategy_To_v1beta1_RollingUpdateStatefulSetStrategy is an autogenerated conversion function. +func Convert_apps_RollingUpdateStatefulSetStrategy_To_v1beta1_RollingUpdateStatefulSetStrategy(in *apps.RollingUpdateStatefulSetStrategy, out *RollingUpdateStatefulSetStrategy, s conversion.Scope) error { + return autoConvert_apps_RollingUpdateStatefulSetStrategy_To_v1beta1_RollingUpdateStatefulSetStrategy(in, out, s) +} + +func autoConvert_v1beta1_StatefulSet_To_apps_StatefulSet(in *StatefulSet, out *apps.StatefulSet, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -63,15 +162,13 @@ func autoConvert_v1beta1_StatefulSet_To_apps_StatefulSet(in *StatefulSet, out *a return nil } +// Convert_v1beta1_StatefulSet_To_apps_StatefulSet is an autogenerated conversion function. func Convert_v1beta1_StatefulSet_To_apps_StatefulSet(in *StatefulSet, out *apps.StatefulSet, s conversion.Scope) error { return autoConvert_v1beta1_StatefulSet_To_apps_StatefulSet(in, out, s) } func autoConvert_apps_StatefulSet_To_v1beta1_StatefulSet(in *apps.StatefulSet, out *StatefulSet, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_apps_StatefulSetSpec_To_v1beta1_StatefulSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -81,6 +178,7 @@ func autoConvert_apps_StatefulSet_To_v1beta1_StatefulSet(in *apps.StatefulSet, o return nil } +// Convert_apps_StatefulSet_To_v1beta1_StatefulSet is an autogenerated conversion function. func Convert_apps_StatefulSet_To_v1beta1_StatefulSet(in *apps.StatefulSet, out *StatefulSet, s conversion.Scope) error { return autoConvert_apps_StatefulSet_To_v1beta1_StatefulSet(in, out, s) } @@ -101,6 +199,7 @@ func autoConvert_v1beta1_StatefulSetList_To_apps_StatefulSetList(in *StatefulSet return nil } +// Convert_v1beta1_StatefulSetList_To_apps_StatefulSetList is an autogenerated conversion function. func Convert_v1beta1_StatefulSetList_To_apps_StatefulSetList(in *StatefulSetList, out *apps.StatefulSetList, s conversion.Scope) error { return autoConvert_v1beta1_StatefulSetList_To_apps_StatefulSetList(in, out, s) } @@ -116,47 +215,64 @@ func autoConvert_apps_StatefulSetList_To_v1beta1_StatefulSetList(in *apps.Statef } } } else { - out.Items = nil + out.Items = make([]StatefulSet, 0) } return nil } +// Convert_apps_StatefulSetList_To_v1beta1_StatefulSetList is an autogenerated conversion function. func Convert_apps_StatefulSetList_To_v1beta1_StatefulSetList(in *apps.StatefulSetList, out *StatefulSetList, s conversion.Scope) error { return autoConvert_apps_StatefulSetList_To_v1beta1_StatefulSetList(in, out, s) } func autoConvert_v1beta1_StatefulSetSpec_To_apps_StatefulSetSpec(in *StatefulSetSpec, out *apps.StatefulSetSpec, s conversion.Scope) error { - if err := api.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := v1.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } out.VolumeClaimTemplates = *(*[]api.PersistentVolumeClaim)(unsafe.Pointer(&in.VolumeClaimTemplates)) out.ServiceName = in.ServiceName + out.PodManagementPolicy = apps.PodManagementPolicyType(in.PodManagementPolicy) + if err := Convert_v1beta1_StatefulSetUpdateStrategy_To_apps_StatefulSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, s); err != nil { + return err + } + out.RevisionHistoryLimit = (*int32)(unsafe.Pointer(in.RevisionHistoryLimit)) return nil } func autoConvert_apps_StatefulSetSpec_To_v1beta1_StatefulSetSpec(in *apps.StatefulSetSpec, out *StatefulSetSpec, s conversion.Scope) error { - if err := api.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := v1.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } - out.VolumeClaimTemplates = *(*[]v1.PersistentVolumeClaim)(unsafe.Pointer(&in.VolumeClaimTemplates)) + out.VolumeClaimTemplates = *(*[]api_v1.PersistentVolumeClaim)(unsafe.Pointer(&in.VolumeClaimTemplates)) out.ServiceName = in.ServiceName + out.PodManagementPolicy = PodManagementPolicyType(in.PodManagementPolicy) + if err := Convert_apps_StatefulSetUpdateStrategy_To_v1beta1_StatefulSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, s); err != nil { + return err + } + out.RevisionHistoryLimit = (*int32)(unsafe.Pointer(in.RevisionHistoryLimit)) return nil } func autoConvert_v1beta1_StatefulSetStatus_To_apps_StatefulSetStatus(in *StatefulSetStatus, out *apps.StatefulSetStatus, s conversion.Scope) error { out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) out.Replicas = in.Replicas + out.ReadyReplicas = in.ReadyReplicas + out.CurrentReplicas = in.CurrentReplicas + out.UpdatedReplicas = in.UpdatedReplicas + out.CurrentRevision = in.CurrentRevision + out.UpdateRevision = in.UpdateRevision return nil } +// Convert_v1beta1_StatefulSetStatus_To_apps_StatefulSetStatus is an autogenerated conversion function. func Convert_v1beta1_StatefulSetStatus_To_apps_StatefulSetStatus(in *StatefulSetStatus, out *apps.StatefulSetStatus, s conversion.Scope) error { return autoConvert_v1beta1_StatefulSetStatus_To_apps_StatefulSetStatus(in, out, s) } @@ -164,9 +280,43 @@ func Convert_v1beta1_StatefulSetStatus_To_apps_StatefulSetStatus(in *StatefulSet func autoConvert_apps_StatefulSetStatus_To_v1beta1_StatefulSetStatus(in *apps.StatefulSetStatus, out *StatefulSetStatus, s conversion.Scope) error { out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) out.Replicas = in.Replicas + out.ReadyReplicas = in.ReadyReplicas + out.CurrentReplicas = in.CurrentReplicas + out.UpdatedReplicas = in.UpdatedReplicas + out.CurrentRevision = in.CurrentRevision + out.UpdateRevision = in.UpdateRevision return nil } +// Convert_apps_StatefulSetStatus_To_v1beta1_StatefulSetStatus is an autogenerated conversion function. func Convert_apps_StatefulSetStatus_To_v1beta1_StatefulSetStatus(in *apps.StatefulSetStatus, out *StatefulSetStatus, s conversion.Scope) error { return autoConvert_apps_StatefulSetStatus_To_v1beta1_StatefulSetStatus(in, out, s) } + +func autoConvert_v1beta1_StatefulSetUpdateStrategy_To_apps_StatefulSetUpdateStrategy(in *StatefulSetUpdateStrategy, out *apps.StatefulSetUpdateStrategy, s conversion.Scope) error { + out.Type = apps.StatefulSetUpdateStrategyType(in.Type) + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(apps.RollingUpdateStatefulSetStrategy) + if err := Convert_v1beta1_RollingUpdateStatefulSetStrategy_To_apps_RollingUpdateStatefulSetStrategy(*in, *out, s); err != nil { + return err + } + } else { + out.RollingUpdate = nil + } + return nil +} + +func autoConvert_apps_StatefulSetUpdateStrategy_To_v1beta1_StatefulSetUpdateStrategy(in *apps.StatefulSetUpdateStrategy, out *StatefulSetUpdateStrategy, s conversion.Scope) error { + out.Type = StatefulSetUpdateStrategyType(in.Type) + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateStatefulSetStrategy) + if err := Convert_apps_RollingUpdateStatefulSetStrategy_To_v1beta1_RollingUpdateStatefulSetStrategy(*in, *out, s); err != nil { + return err + } + } else { + out.RollingUpdate = nil + } + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go index 83191c0f71..5be3439812 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,11 @@ limitations under the License. package v1beta1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api_v1 "k8s.io/client-go/pkg/api/v1" reflect "reflect" ) @@ -36,20 +37,322 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ControllerRevision, InType: reflect.TypeOf(&ControllerRevision{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ControllerRevisionList, InType: reflect.TypeOf(&ControllerRevisionList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Deployment, InType: reflect.TypeOf(&Deployment{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentCondition, InType: reflect.TypeOf(&DeploymentCondition{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentList, InType: reflect.TypeOf(&DeploymentList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentRollback, InType: reflect.TypeOf(&DeploymentRollback{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentSpec, InType: reflect.TypeOf(&DeploymentSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentStatus, InType: reflect.TypeOf(&DeploymentStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentStrategy, InType: reflect.TypeOf(&DeploymentStrategy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RollbackConfig, InType: reflect.TypeOf(&RollbackConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RollingUpdateDeployment, InType: reflect.TypeOf(&RollingUpdateDeployment{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RollingUpdateStatefulSetStrategy, InType: reflect.TypeOf(&RollingUpdateStatefulSetStrategy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Scale, InType: reflect.TypeOf(&Scale{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ScaleSpec, InType: reflect.TypeOf(&ScaleSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ScaleStatus, InType: reflect.TypeOf(&ScaleStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_StatefulSet, InType: reflect.TypeOf(&StatefulSet{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_StatefulSetList, InType: reflect.TypeOf(&StatefulSetList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_StatefulSetSpec, InType: reflect.TypeOf(&StatefulSetSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_StatefulSetStatus, InType: reflect.TypeOf(&StatefulSetStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_StatefulSetUpdateStrategy, InType: reflect.TypeOf(&StatefulSetUpdateStrategy{})}, ) } +// DeepCopy_v1beta1_ControllerRevision is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ControllerRevision(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevision) + out := out.(*ControllerRevision) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if newVal, err := c.DeepCopy(&in.Data); err != nil { + return err + } else { + out.Data = *newVal.(*runtime.RawExtension) + } + return nil + } +} + +// DeepCopy_v1beta1_ControllerRevisionList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ControllerRevisionList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevisionList) + out := out.(*ControllerRevisionList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_ControllerRevision(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_Deployment is an autogenerated deepcopy function. +func DeepCopy_v1beta1_Deployment(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Deployment) + out := out.(*Deployment) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_v1beta1_DeploymentSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + if err := DeepCopy_v1beta1_DeploymentStatus(&in.Status, &out.Status, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1beta1_DeploymentCondition is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DeploymentCondition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeploymentCondition) + out := out.(*DeploymentCondition) + *out = *in + out.LastUpdateTime = in.LastUpdateTime.DeepCopy() + out.LastTransitionTime = in.LastTransitionTime.DeepCopy() + return nil + } +} + +// DeepCopy_v1beta1_DeploymentList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DeploymentList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeploymentList) + out := out.(*DeploymentList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Deployment, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_Deployment(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_DeploymentRollback is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DeploymentRollback(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeploymentRollback) + out := out.(*DeploymentRollback) + *out = *in + if in.UpdatedAnnotations != nil { + in, out := &in.UpdatedAnnotations, &out.UpdatedAnnotations + *out = make(map[string]string) + for key, val := range *in { + (*out)[key] = val + } + } + return nil + } +} + +// DeepCopy_v1beta1_DeploymentSpec is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DeploymentSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeploymentSpec) + out := out.(*DeploymentSpec) + *out = *in + if in.Replicas != nil { + in, out := &in.Replicas, &out.Replicas + *out = new(int32) + **out = **in + } + if in.Selector != nil { + in, out := &in.Selector, &out.Selector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + if err := api_v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { + return err + } + if err := DeepCopy_v1beta1_DeploymentStrategy(&in.Strategy, &out.Strategy, c); err != nil { + return err + } + if in.RevisionHistoryLimit != nil { + in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit + *out = new(int32) + **out = **in + } + if in.RollbackTo != nil { + in, out := &in.RollbackTo, &out.RollbackTo + *out = new(RollbackConfig) + **out = **in + } + if in.ProgressDeadlineSeconds != nil { + in, out := &in.ProgressDeadlineSeconds, &out.ProgressDeadlineSeconds + *out = new(int32) + **out = **in + } + return nil + } +} + +// DeepCopy_v1beta1_DeploymentStatus is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DeploymentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeploymentStatus) + out := out.(*DeploymentStatus) + *out = *in + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]DeploymentCondition, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_DeploymentCondition(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.CollisionCount != nil { + in, out := &in.CollisionCount, &out.CollisionCount + *out = new(int64) + **out = **in + } + return nil + } +} + +// DeepCopy_v1beta1_DeploymentStrategy is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DeploymentStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DeploymentStrategy) + out := out.(*DeploymentStrategy) + *out = *in + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateDeployment) + if err := DeepCopy_v1beta1_RollingUpdateDeployment(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v1beta1_RollbackConfig is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RollbackConfig(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RollbackConfig) + out := out.(*RollbackConfig) + *out = *in + return nil + } +} + +// DeepCopy_v1beta1_RollingUpdateDeployment is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RollingUpdateDeployment(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RollingUpdateDeployment) + out := out.(*RollingUpdateDeployment) + *out = *in + if in.MaxUnavailable != nil { + in, out := &in.MaxUnavailable, &out.MaxUnavailable + *out = new(intstr.IntOrString) + **out = **in + } + if in.MaxSurge != nil { + in, out := &in.MaxSurge, &out.MaxSurge + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_v1beta1_RollingUpdateStatefulSetStrategy is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RollingUpdateStatefulSetStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RollingUpdateStatefulSetStrategy) + out := out.(*RollingUpdateStatefulSetStrategy) + *out = *in + if in.Partition != nil { + in, out := &in.Partition, &out.Partition + *out = new(int32) + **out = **in + } + return nil + } +} + +// DeepCopy_v1beta1_Scale is an autogenerated deepcopy function. +func DeepCopy_v1beta1_Scale(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Scale) + out := out.(*Scale) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_v1beta1_ScaleStatus(&in.Status, &out.Status, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1beta1_ScaleSpec is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ScaleSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ScaleSpec) + out := out.(*ScaleSpec) + *out = *in + return nil + } +} + +// DeepCopy_v1beta1_ScaleStatus is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ScaleStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ScaleStatus) + out := out.(*ScaleStatus) + *out = *in + if in.Selector != nil { + in, out := &in.Selector, &out.Selector + *out = make(map[string]string) + for key, val := range *in { + (*out)[key] = val + } + } + return nil + } +} + +// DeepCopy_v1beta1_StatefulSet is an autogenerated deepcopy function. func DeepCopy_v1beta1_StatefulSet(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSet) out := out.(*StatefulSet) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_StatefulSetSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -61,12 +364,12 @@ func DeepCopy_v1beta1_StatefulSet(in interface{}, out interface{}, c *conversion } } +// DeepCopy_v1beta1_StatefulSetList is an autogenerated deepcopy function. func DeepCopy_v1beta1_StatefulSetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSetList) out := out.(*StatefulSetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]StatefulSet, len(*in)) @@ -75,64 +378,82 @@ func DeepCopy_v1beta1_StatefulSetList(in interface{}, out interface{}, c *conver return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_StatefulSetSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_StatefulSetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSetSpec) out := out.(*StatefulSetSpec) + *out = *in if in.Replicas != nil { in, out := &in.Replicas, &out.Replicas *out = new(int32) **out = **in - } else { - out.Replicas = nil } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } - if err := v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { + if err := api_v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err } if in.VolumeClaimTemplates != nil { in, out := &in.VolumeClaimTemplates, &out.VolumeClaimTemplates - *out = make([]v1.PersistentVolumeClaim, len(*in)) + *out = make([]api_v1.PersistentVolumeClaim, len(*in)) for i := range *in { - if err := v1.DeepCopy_v1_PersistentVolumeClaim(&(*in)[i], &(*out)[i], c); err != nil { + if err := api_v1.DeepCopy_v1_PersistentVolumeClaim(&(*in)[i], &(*out)[i], c); err != nil { return err } } - } else { - out.VolumeClaimTemplates = nil } - out.ServiceName = in.ServiceName + if err := DeepCopy_v1beta1_StatefulSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, c); err != nil { + return err + } + if in.RevisionHistoryLimit != nil { + in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit + *out = new(int32) + **out = **in + } return nil } } +// DeepCopy_v1beta1_StatefulSetStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_StatefulSetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSetStatus) out := out.(*StatefulSetStatus) + *out = *in if in.ObservedGeneration != nil { in, out := &in.ObservedGeneration, &out.ObservedGeneration *out = new(int64) **out = **in - } else { - out.ObservedGeneration = nil } - out.Replicas = in.Replicas + return nil + } +} + +// DeepCopy_v1beta1_StatefulSetUpdateStrategy is an autogenerated deepcopy function. +func DeepCopy_v1beta1_StatefulSetUpdateStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StatefulSetUpdateStrategy) + out := out.(*StatefulSetUpdateStrategy) + *out = *in + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateStatefulSetStrategy) + if err := DeepCopy_v1beta1_RollingUpdateStatefulSetStrategy(*in, *out, c); err != nil { + return err + } + } return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.defaults.go index 7f9a19c1e2..9b822c84cb 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/v1beta1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,19 +21,162 @@ limitations under the License. package v1beta1 import ( + runtime "k8s.io/apimachinery/pkg/runtime" v1 "k8s.io/client-go/pkg/api/v1" - runtime "k8s.io/client-go/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. // Public to allow building arbitrary schemes. // All generated defaulters are covering - they call all nested defaulters. func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&Deployment{}, func(obj interface{}) { SetObjectDefaults_Deployment(obj.(*Deployment)) }) + scheme.AddTypeDefaultingFunc(&DeploymentList{}, func(obj interface{}) { SetObjectDefaults_DeploymentList(obj.(*DeploymentList)) }) scheme.AddTypeDefaultingFunc(&StatefulSet{}, func(obj interface{}) { SetObjectDefaults_StatefulSet(obj.(*StatefulSet)) }) scheme.AddTypeDefaultingFunc(&StatefulSetList{}, func(obj interface{}) { SetObjectDefaults_StatefulSetList(obj.(*StatefulSetList)) }) return nil } +func SetObjectDefaults_Deployment(in *Deployment) { + SetDefaults_Deployment(in) + v1.SetDefaults_PodSpec(&in.Spec.Template.Spec) + for i := range in.Spec.Template.Spec.Volumes { + a := &in.Spec.Template.Spec.Volumes[i] + v1.SetDefaults_Volume(a) + if a.VolumeSource.Secret != nil { + v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret) + } + if a.VolumeSource.ISCSI != nil { + v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI) + } + if a.VolumeSource.RBD != nil { + v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD) + } + if a.VolumeSource.DownwardAPI != nil { + v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI) + for j := range a.VolumeSource.DownwardAPI.Items { + b := &a.VolumeSource.DownwardAPI.Items[j] + if b.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(b.FieldRef) + } + } + } + if a.VolumeSource.ConfigMap != nil { + v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap) + } + if a.VolumeSource.AzureDisk != nil { + v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) + } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } + } + for i := range in.Spec.Template.Spec.InitContainers { + a := &in.Spec.Template.Spec.InitContainers[i] + v1.SetDefaults_Container(a) + for j := range a.Ports { + b := &a.Ports[j] + v1.SetDefaults_ContainerPort(b) + } + for j := range a.Env { + b := &a.Env[j] + if b.ValueFrom != nil { + if b.ValueFrom.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef) + } + } + } + v1.SetDefaults_ResourceList(&a.Resources.Limits) + v1.SetDefaults_ResourceList(&a.Resources.Requests) + if a.LivenessProbe != nil { + v1.SetDefaults_Probe(a.LivenessProbe) + if a.LivenessProbe.Handler.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.LivenessProbe.Handler.HTTPGet) + } + } + if a.ReadinessProbe != nil { + v1.SetDefaults_Probe(a.ReadinessProbe) + if a.ReadinessProbe.Handler.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.Handler.HTTPGet) + } + } + if a.Lifecycle != nil { + if a.Lifecycle.PostStart != nil { + if a.Lifecycle.PostStart.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet) + } + } + if a.Lifecycle.PreStop != nil { + if a.Lifecycle.PreStop.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet) + } + } + } + } + for i := range in.Spec.Template.Spec.Containers { + a := &in.Spec.Template.Spec.Containers[i] + v1.SetDefaults_Container(a) + for j := range a.Ports { + b := &a.Ports[j] + v1.SetDefaults_ContainerPort(b) + } + for j := range a.Env { + b := &a.Env[j] + if b.ValueFrom != nil { + if b.ValueFrom.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef) + } + } + } + v1.SetDefaults_ResourceList(&a.Resources.Limits) + v1.SetDefaults_ResourceList(&a.Resources.Requests) + if a.LivenessProbe != nil { + v1.SetDefaults_Probe(a.LivenessProbe) + if a.LivenessProbe.Handler.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.LivenessProbe.Handler.HTTPGet) + } + } + if a.ReadinessProbe != nil { + v1.SetDefaults_Probe(a.ReadinessProbe) + if a.ReadinessProbe.Handler.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.Handler.HTTPGet) + } + } + if a.Lifecycle != nil { + if a.Lifecycle.PostStart != nil { + if a.Lifecycle.PostStart.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet) + } + } + if a.Lifecycle.PreStop != nil { + if a.Lifecycle.PreStop.HTTPGet != nil { + v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet) + } + } + } + } +} + +func SetObjectDefaults_DeploymentList(in *DeploymentList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_Deployment(a) + } +} + func SetObjectDefaults_StatefulSet(in *StatefulSet) { SetDefaults_StatefulSet(in) v1.SetDefaults_PodSpec(&in.Spec.Template.Spec) @@ -64,6 +207,23 @@ func SetObjectDefaults_StatefulSet(in *StatefulSet) { if a.VolumeSource.AzureDisk != nil { v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.Template.Spec.InitContainers { a := &in.Spec.Template.Spec.InitContainers[i] diff --git a/vendor/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go index 4452972dfd..ff37ef9bc3 100644 --- a/vendor/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/apps/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package apps import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" reflect "reflect" ) @@ -36,20 +36,79 @@ func init() { // to allow building arbitrary schemes. func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_ControllerRevision, InType: reflect.TypeOf(&ControllerRevision{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_ControllerRevisionList, InType: reflect.TypeOf(&ControllerRevisionList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_RollingUpdateStatefulSetStrategy, InType: reflect.TypeOf(&RollingUpdateStatefulSetStrategy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSet, InType: reflect.TypeOf(&StatefulSet{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetList, InType: reflect.TypeOf(&StatefulSetList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetSpec, InType: reflect.TypeOf(&StatefulSetSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetStatus, InType: reflect.TypeOf(&StatefulSetStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_apps_StatefulSetUpdateStrategy, InType: reflect.TypeOf(&StatefulSetUpdateStrategy{})}, ) } +// DeepCopy_apps_ControllerRevision is an autogenerated deepcopy function. +func DeepCopy_apps_ControllerRevision(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevision) + out := out.(*ControllerRevision) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + // in.Data is kind 'Interface' + if in.Data != nil { + if newVal, err := c.DeepCopy(&in.Data); err != nil { + return err + } else { + out.Data = *newVal.(*runtime.Object) + } + } + return nil + } +} + +// DeepCopy_apps_ControllerRevisionList is an autogenerated deepcopy function. +func DeepCopy_apps_ControllerRevisionList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ControllerRevisionList) + out := out.(*ControllerRevisionList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ControllerRevision, len(*in)) + for i := range *in { + if err := DeepCopy_apps_ControllerRevision(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_apps_RollingUpdateStatefulSetStrategy is an autogenerated deepcopy function. +func DeepCopy_apps_RollingUpdateStatefulSetStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RollingUpdateStatefulSetStrategy) + out := out.(*RollingUpdateStatefulSetStrategy) + *out = *in + return nil + } +} + +// DeepCopy_apps_StatefulSet is an autogenerated deepcopy function. func DeepCopy_apps_StatefulSet(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSet) out := out.(*StatefulSet) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_apps_StatefulSetSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -61,12 +120,12 @@ func DeepCopy_apps_StatefulSet(in interface{}, out interface{}, c *conversion.Cl } } +// DeepCopy_apps_StatefulSetList is an autogenerated deepcopy function. func DeepCopy_apps_StatefulSetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSetList) out := out.(*StatefulSetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]StatefulSet, len(*in)) @@ -75,26 +134,24 @@ func DeepCopy_apps_StatefulSetList(in interface{}, out interface{}, c *conversio return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_apps_StatefulSetSpec is an autogenerated deepcopy function. func DeepCopy_apps_StatefulSetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSetSpec) out := out.(*StatefulSetSpec) - out.Replicas = in.Replicas + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } if err := api.DeepCopy_api_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -107,26 +164,45 @@ func DeepCopy_apps_StatefulSetSpec(in interface{}, out interface{}, c *conversio return err } } - } else { - out.VolumeClaimTemplates = nil } - out.ServiceName = in.ServiceName + if err := DeepCopy_apps_StatefulSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, c); err != nil { + return err + } + if in.RevisionHistoryLimit != nil { + in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit + *out = new(int32) + **out = **in + } return nil } } +// DeepCopy_apps_StatefulSetStatus is an autogenerated deepcopy function. func DeepCopy_apps_StatefulSetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StatefulSetStatus) out := out.(*StatefulSetStatus) + *out = *in if in.ObservedGeneration != nil { in, out := &in.ObservedGeneration, &out.ObservedGeneration *out = new(int64) **out = **in - } else { - out.ObservedGeneration = nil } - out.Replicas = in.Replicas + return nil + } +} + +// DeepCopy_apps_StatefulSetUpdateStrategy is an autogenerated deepcopy function. +func DeepCopy_apps_StatefulSetUpdateStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StatefulSetUpdateStrategy) + out := out.(*StatefulSetUpdateStrategy) + *out = *in + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateStatefulSetStrategy) + **out = **in + } return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/BUILD b/vendor/k8s.io/client-go/pkg/apis/authentication/BUILD new file mode 100644 index 0000000000..6e2604388a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/OWNERS b/vendor/k8s.io/client-go/pkg/apis/authentication/OWNERS new file mode 100755 index 0000000000..4135522b21 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/OWNERS @@ -0,0 +1,9 @@ +reviewers: +- liggitt +- lavalamp +- wojtek-t +- deads2k +- sttts +- timothysc +- mbohlool +- jianhuiz diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/doc.go b/vendor/k8s.io/client-go/pkg/apis/authentication/doc.go index 35cb18de8b..194de434d8 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/doc.go @@ -14,7 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register // +groupName=authentication.k8s.io -// +k8s:openapi-gen=true package authentication diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/install/install.go b/vendor/k8s.io/client-go/pkg/apis/authentication/install/install.go deleted file mode 100644 index c045d7c588..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the experimental API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/authentication" - "k8s.io/client-go/pkg/apis/authentication/v1beta1" - "k8s.io/client-go/pkg/util/sets" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: authentication.GroupName, - VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/authentication", - RootScopedKinds: sets.NewString("TokenReview"), - AddInternalObjectsToScheme: authentication.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/register.go b/vendor/k8s.io/client-go/pkg/apis/authentication/register.go index 4759c011b9..b0ac3c28bf 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/register.go @@ -17,24 +17,23 @@ limitations under the License. package authentication import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "authentication.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -45,10 +44,6 @@ var ( func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &api.ListOptions{}, - &api.DeleteOptions{}, - &api.ExportOptions{}, - &TokenReview{}, ) return nil diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/authentication/types.generated.go deleted file mode 100644 index b2c9ceb6d7..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/types.generated.go +++ /dev/null @@ -1,2394 +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 authentication - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - "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 pkg2_api.ObjectMeta - var v1 pkg1_unversioned.TypeMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 - } -} - -func (x *TokenReview) 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 [19]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = x.Name != "" - yyq2[3] = x.GenerateName != "" - yyq2[4] = x.Namespace != "" - yyq2[5] = x.SelfLink != "" - yyq2[6] = x.UID != "" - yyq2[7] = x.ResourceVersion != "" - yyq2[8] = x.Generation != 0 - yyq2[9] = true - yyq2[10] = x.ObjectMeta.DeletionTimestamp != nil && x.DeletionTimestamp != nil - yyq2[11] = x.ObjectMeta.DeletionGracePeriodSeconds != nil && x.DeletionGracePeriodSeconds != nil - yyq2[12] = len(x.Labels) != 0 - yyq2[13] = len(x.Annotations) != 0 - yyq2[14] = len(x.OwnerReferences) != 0 - yyq2[15] = len(x.Finalizers) != 0 - yyq2[16] = x.ClusterName != "" - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(19) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generateName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[5] { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selfLink")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[6] { - yym22 := z.EncBinary() - _ = yym22 - 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[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym23 := z.EncBinary() - _ = yym23 - 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[7] { - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[8] { - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generation")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[9] { - yy31 := &x.CreationTimestamp - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(yy31) { - } else if yym32 { - z.EncBinaryMarshal(yy31) - } else if !yym32 && z.IsJSONHandle() { - z.EncJSONMarshal(yy31) - } else { - z.EncFallback(yy31) - } - } else { - r.EncodeNil() - } - } else { - if yyq2[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("creationTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy33 := &x.CreationTimestamp - yym34 := z.EncBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.EncExt(yy33) { - } else if yym34 { - z.EncBinaryMarshal(yy33) - } else if !yym34 && z.IsJSONHandle() { - z.EncJSONMarshal(yy33) - } else { - z.EncFallback(yy33) - } - } - } - var yyn35 bool - if x.ObjectMeta.DeletionTimestamp == nil { - yyn35 = true - goto LABEL35 - } - LABEL35: - if yyr2 || yy2arr2 { - if yyn35 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[10] { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym36 := z.EncBinary() - _ = yym36 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym36 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym36 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq2[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn35 { - r.EncodeNil() - } else { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym37 := z.EncBinary() - _ = yym37 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym37 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym37 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } - } - } - var yyn38 bool - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - yyn38 = true - goto LABEL38 - } - LABEL38: - if yyr2 || yy2arr2 { - if yyn38 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[11] { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy39 := *x.DeletionGracePeriodSeconds - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeInt(int64(yy39)) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq2[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionGracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn38 { - r.EncodeNil() - } else { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy41 := *x.DeletionGracePeriodSeconds - yym42 := z.EncBinary() - _ = yym42 - if false { - } else { - r.EncodeInt(int64(yy41)) - } - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[12] { - if x.Labels == nil { - r.EncodeNil() - } else { - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labels")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Labels == nil { - r.EncodeNil() - } else { - yym45 := z.EncBinary() - _ = yym45 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[13] { - if x.Annotations == nil { - r.EncodeNil() - } else { - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("annotations")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Annotations == nil { - r.EncodeNil() - } else { - yym48 := z.EncBinary() - _ = yym48 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[14] { - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ownerReferences")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym51 := z.EncBinary() - _ = yym51 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[15] { - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finalizers")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym54 := z.EncBinary() - _ = yym54 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[16] { - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym57 := z.EncBinary() - _ = yym57 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy59 := &x.Spec - yy59.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy60 := &x.Spec - yy60.CodecEncodeSelf(e) - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy62 := &x.Status - yy62.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy63 := &x.Status - yy63.CodecEncodeSelf(e) - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *TokenReview) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym64 := z.DecBinary() - _ = yym64 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct65 := r.ContainerType() - if yyct65 == codecSelferValueTypeMap1234 { - yyl65 := r.ReadMapStart() - if yyl65 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl65, d) - } - } else if yyct65 == codecSelferValueTypeArray1234 { - yyl65 := r.ReadArrayStart() - if yyl65 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl65, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *TokenReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys66Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys66Slc - var yyhl66 bool = l >= 0 - for yyj66 := 0; ; yyj66++ { - if yyhl66 { - if yyj66 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys66Slc = r.DecodeBytes(yys66Slc, true, true) - yys66 := string(yys66Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys66 { - 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 "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 = pkg3_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 = pkg1_unversioned.Time{} - } else { - yyv76 := &x.CreationTimestamp - yym77 := z.DecBinary() - _ = yym77 - if false { - } else if z.HasExtensions() && z.DecExt(yyv76) { - } else if yym77 { - z.DecBinaryUnmarshal(yyv76) - } else if !yym77 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv76) - } else { - z.DecFallback(yyv76, false) - } - } - case "deletionTimestamp": - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - if r.TryDecodeAsNil() { - if x.DeletionTimestamp != nil { - x.DeletionTimestamp = nil - } - } else { - if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yym79 := z.DecBinary() - _ = yym79 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym79 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym79 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - case "deletionGracePeriodSeconds": - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - if r.TryDecodeAsNil() { - if x.DeletionGracePeriodSeconds != nil { - x.DeletionGracePeriodSeconds = nil - } - } else { - if x.DeletionGracePeriodSeconds == nil { - x.DeletionGracePeriodSeconds = new(int64) - } - yym81 := z.DecBinary() - _ = yym81 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - case "labels": - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv82 := &x.Labels - yym83 := z.DecBinary() - _ = yym83 - if false { - } else { - z.F.DecMapStringStringX(yyv82, false, d) - } - } - case "annotations": - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv84 := &x.Annotations - yym85 := z.DecBinary() - _ = yym85 - if false { - } else { - z.F.DecMapStringStringX(yyv84, false, d) - } - } - case "ownerReferences": - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv86 := &x.OwnerReferences - yym87 := z.DecBinary() - _ = yym87 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv86), d) - } - } - case "finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv88 := &x.Finalizers - yym89 := z.DecBinary() - _ = yym89 - if false { - } else { - z.F.DecSliceStringX(yyv88, false, d) - } - } - case "clusterName": - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - case "Spec": - if r.TryDecodeAsNil() { - x.Spec = TokenReviewSpec{} - } else { - yyv91 := &x.Spec - yyv91.CodecDecodeSelf(d) - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = TokenReviewStatus{} - } else { - yyv92 := &x.Status - yyv92.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys66) - } // end switch yys66 - } // end for yyj66 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *TokenReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj93 int - var yyb93 bool - var yyhl93 bool = l >= 0 - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.GenerateName = "" - } else { - x.GenerateName = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SelfLink = "" - } else { - x.SelfLink = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg3_types.UID(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Generation = 0 - } else { - x.Generation = int64(r.DecodeInt(64)) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg1_unversioned.Time{} - } else { - yyv103 := &x.CreationTimestamp - yym104 := z.DecBinary() - _ = yym104 - if false { - } else if z.HasExtensions() && z.DecExt(yyv103) { - } else if yym104 { - z.DecBinaryUnmarshal(yyv103) - } else if !yym104 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv103) - } else { - z.DecFallback(yyv103, false) - } - } - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - 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(pkg1_unversioned.Time) - } - yym106 := z.DecBinary() - _ = yym106 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym106 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym106 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - 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) - } - yym108 := z.DecBinary() - _ = yym108 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv109 := &x.Labels - yym110 := z.DecBinary() - _ = yym110 - if false { - } else { - z.F.DecMapStringStringX(yyv109, false, d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv111 := &x.Annotations - yym112 := z.DecBinary() - _ = yym112 - if false { - } else { - z.F.DecMapStringStringX(yyv111, false, d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv113 := &x.OwnerReferences - yym114 := z.DecBinary() - _ = yym114 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv113), d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv115 := &x.Finalizers - yym116 := z.DecBinary() - _ = yym116 - if false { - } else { - z.F.DecSliceStringX(yyv115, false, d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = TokenReviewSpec{} - } else { - yyv118 := &x.Spec - yyv118.CodecDecodeSelf(d) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = TokenReviewStatus{} - } else { - yyv119 := &x.Status - yyv119.CodecDecodeSelf(d) - } - for { - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj93-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *TokenReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym120 := z.EncBinary() - _ = yym120 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep121 := !z.EncBinary() - yy2arr121 := z.EncBasicHandle().StructToArray - var yyq121 [1]bool - _, _, _ = yysep121, yyq121, yy2arr121 - const yyr121 bool = false - var yynn121 int - if yyr121 || yy2arr121 { - r.EncodeArrayStart(1) - } else { - yynn121 = 1 - for _, b := range yyq121 { - if b { - yynn121++ - } - } - r.EncodeMapStart(yynn121) - yynn121 = 0 - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym123 := z.EncBinary() - _ = yym123 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Token)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Token")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym124 := z.EncBinary() - _ = yym124 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Token)) - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *TokenReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym125 := z.DecBinary() - _ = yym125 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct126 := r.ContainerType() - if yyct126 == codecSelferValueTypeMap1234 { - yyl126 := r.ReadMapStart() - if yyl126 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl126, d) - } - } else if yyct126 == codecSelferValueTypeArray1234 { - yyl126 := r.ReadArrayStart() - if yyl126 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl126, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *TokenReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys127Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys127Slc - var yyhl127 bool = l >= 0 - for yyj127 := 0; ; yyj127++ { - if yyhl127 { - if yyj127 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys127Slc = r.DecodeBytes(yys127Slc, true, true) - yys127 := string(yys127Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys127 { - case "Token": - if r.TryDecodeAsNil() { - x.Token = "" - } else { - x.Token = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys127) - } // end switch yys127 - } // end for yyj127 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *TokenReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj129 int - var yyb129 bool - var yyhl129 bool = l >= 0 - yyj129++ - if yyhl129 { - yyb129 = yyj129 > l - } else { - yyb129 = r.CheckBreak() - } - if yyb129 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Token = "" - } else { - x.Token = string(r.DecodeString()) - } - for { - yyj129++ - if yyhl129 { - yyb129 = yyj129 > l - } else { - yyb129 = r.CheckBreak() - } - if yyb129 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj129-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *TokenReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym131 := z.EncBinary() - _ = yym131 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep132 := !z.EncBinary() - yy2arr132 := z.EncBasicHandle().StructToArray - var yyq132 [3]bool - _, _, _ = yysep132, yyq132, yy2arr132 - const yyr132 bool = false - var yynn132 int - if yyr132 || yy2arr132 { - r.EncodeArrayStart(3) - } else { - yynn132 = 3 - for _, b := range yyq132 { - if b { - yynn132++ - } - } - r.EncodeMapStart(yynn132) - yynn132 = 0 - } - if yyr132 || yy2arr132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym134 := z.EncBinary() - _ = yym134 - if false { - } else { - r.EncodeBool(bool(x.Authenticated)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Authenticated")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym135 := z.EncBinary() - _ = yym135 - if false { - } else { - r.EncodeBool(bool(x.Authenticated)) - } - } - if yyr132 || yy2arr132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy137 := &x.User - yy137.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("User")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy138 := &x.User - yy138.CodecEncodeSelf(e) - } - if yyr132 || yy2arr132 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym140 := z.EncBinary() - _ = yym140 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Error)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Error")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym141 := z.EncBinary() - _ = yym141 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Error)) - } - } - if yyr132 || yy2arr132 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *TokenReviewStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym142 := z.DecBinary() - _ = yym142 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct143 := r.ContainerType() - if yyct143 == codecSelferValueTypeMap1234 { - yyl143 := r.ReadMapStart() - if yyl143 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl143, d) - } - } else if yyct143 == codecSelferValueTypeArray1234 { - yyl143 := r.ReadArrayStart() - if yyl143 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl143, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *TokenReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys144Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys144Slc - var yyhl144 bool = l >= 0 - for yyj144 := 0; ; yyj144++ { - if yyhl144 { - if yyj144 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys144Slc = r.DecodeBytes(yys144Slc, true, true) - yys144 := string(yys144Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys144 { - case "Authenticated": - if r.TryDecodeAsNil() { - x.Authenticated = false - } else { - x.Authenticated = bool(r.DecodeBool()) - } - case "User": - if r.TryDecodeAsNil() { - x.User = UserInfo{} - } else { - yyv146 := &x.User - yyv146.CodecDecodeSelf(d) - } - case "Error": - if r.TryDecodeAsNil() { - x.Error = "" - } else { - x.Error = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys144) - } // end switch yys144 - } // end for yyj144 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *TokenReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj148 int - var yyb148 bool - var yyhl148 bool = l >= 0 - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Authenticated = false - } else { - x.Authenticated = bool(r.DecodeBool()) - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = UserInfo{} - } else { - yyv150 := &x.User - yyv150.CodecDecodeSelf(d) - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Error = "" - } else { - x.Error = string(r.DecodeString()) - } - for { - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj148-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym152 := z.EncBinary() - _ = yym152 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep153 := !z.EncBinary() - yy2arr153 := z.EncBasicHandle().StructToArray - var yyq153 [4]bool - _, _, _ = yysep153, yyq153, yy2arr153 - const yyr153 bool = false - var yynn153 int - if yyr153 || yy2arr153 { - r.EncodeArrayStart(4) - } else { - yynn153 = 4 - for _, b := range yyq153 { - if b { - yynn153++ - } - } - r.EncodeMapStart(yynn153) - yynn153 = 0 - } - if yyr153 || yy2arr153 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym155 := z.EncBinary() - _ = yym155 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Username)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Username")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym156 := z.EncBinary() - _ = yym156 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Username)) - } - } - if yyr153 || yy2arr153 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym158 := z.EncBinary() - _ = yym158 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("UID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym159 := z.EncBinary() - _ = yym159 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - if yyr153 || yy2arr153 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Groups == nil { - r.EncodeNil() - } else { - yym161 := z.EncBinary() - _ = yym161 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Groups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Groups == nil { - r.EncodeNil() - } else { - yym162 := z.EncBinary() - _ = yym162 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } - if yyr153 || yy2arr153 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Extra == nil { - r.EncodeNil() - } else { - yym164 := z.EncBinary() - _ = yym164 - if false { - } else { - h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Extra")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Extra == nil { - r.EncodeNil() - } else { - yym165 := z.EncBinary() - _ = yym165 - if false { - } else { - h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) - } - } - } - if yyr153 || yy2arr153 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *UserInfo) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym166 := z.DecBinary() - _ = yym166 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct167 := r.ContainerType() - if yyct167 == codecSelferValueTypeMap1234 { - yyl167 := r.ReadMapStart() - if yyl167 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl167, d) - } - } else if yyct167 == codecSelferValueTypeArray1234 { - yyl167 := r.ReadArrayStart() - if yyl167 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl167, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *UserInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys168Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys168Slc - var yyhl168 bool = l >= 0 - for yyj168 := 0; ; yyj168++ { - if yyhl168 { - if yyj168 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys168Slc = r.DecodeBytes(yys168Slc, true, true) - yys168 := string(yys168Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys168 { - case "Username": - if r.TryDecodeAsNil() { - x.Username = "" - } else { - x.Username = string(r.DecodeString()) - } - case "UID": - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = string(r.DecodeString()) - } - case "Groups": - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv171 := &x.Groups - yym172 := z.DecBinary() - _ = yym172 - if false { - } else { - z.F.DecSliceStringX(yyv171, false, d) - } - } - case "Extra": - if r.TryDecodeAsNil() { - x.Extra = nil - } else { - yyv173 := &x.Extra - yym174 := z.DecBinary() - _ = yym174 - if false { - } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv173), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys168) - } // end switch yys168 - } // end for yyj168 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *UserInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj175 int - var yyb175 bool - var yyhl175 bool = l >= 0 - yyj175++ - if yyhl175 { - yyb175 = yyj175 > l - } else { - yyb175 = r.CheckBreak() - } - if yyb175 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Username = "" - } else { - x.Username = string(r.DecodeString()) - } - yyj175++ - if yyhl175 { - yyb175 = yyj175 > l - } else { - yyb175 = r.CheckBreak() - } - if yyb175 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = string(r.DecodeString()) - } - yyj175++ - if yyhl175 { - yyb175 = yyj175 > l - } else { - yyb175 = r.CheckBreak() - } - if yyb175 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv178 := &x.Groups - yym179 := z.DecBinary() - _ = yym179 - if false { - } else { - z.F.DecSliceStringX(yyv178, false, d) - } - } - yyj175++ - if yyhl175 { - yyb175 = yyj175 > l - } else { - yyb175 = r.CheckBreak() - } - if yyb175 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Extra = nil - } else { - yyv180 := &x.Extra - yym181 := z.DecBinary() - _ = yym181 - if false { - } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv180), d) - } - } - for { - yyj175++ - if yyhl175 { - yyb175 = yyj175 > l - } else { - yyb175 = r.CheckBreak() - } - if yyb175 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj175-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ExtraValue) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym182 := z.EncBinary() - _ = yym182 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - h.encExtraValue((ExtraValue)(x), e) - } - } -} - -func (x *ExtraValue) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym183 := z.DecBinary() - _ = yym183 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - h.decExtraValue((*ExtraValue)(x), d) - } -} - -func (x codecSelfer1234) encSliceapi_OwnerReference(v []pkg2_api.OwnerReference, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv184 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy185 := &yyv184 - yy185.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceapi_OwnerReference(v *[]pkg2_api.OwnerReference, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv186 := *v - yyh186, yyl186 := z.DecSliceHelperStart() - var yyc186 bool - if yyl186 == 0 { - if yyv186 == nil { - yyv186 = []pkg2_api.OwnerReference{} - yyc186 = true - } else if len(yyv186) != 0 { - yyv186 = yyv186[:0] - yyc186 = true - } - } else if yyl186 > 0 { - var yyrr186, yyrl186 int - var yyrt186 bool - if yyl186 > cap(yyv186) { - - yyrg186 := len(yyv186) > 0 - yyv2186 := yyv186 - yyrl186, yyrt186 = z.DecInferLen(yyl186, z.DecBasicHandle().MaxInitLen, 72) - if yyrt186 { - if yyrl186 <= cap(yyv186) { - yyv186 = yyv186[:yyrl186] - } else { - yyv186 = make([]pkg2_api.OwnerReference, yyrl186) - } - } else { - yyv186 = make([]pkg2_api.OwnerReference, yyrl186) - } - yyc186 = true - yyrr186 = len(yyv186) - if yyrg186 { - copy(yyv186, yyv2186) - } - } else if yyl186 != len(yyv186) { - yyv186 = yyv186[:yyl186] - yyc186 = true - } - yyj186 := 0 - for ; yyj186 < yyrr186; yyj186++ { - yyh186.ElemContainerState(yyj186) - if r.TryDecodeAsNil() { - yyv186[yyj186] = pkg2_api.OwnerReference{} - } else { - yyv187 := &yyv186[yyj186] - yyv187.CodecDecodeSelf(d) - } - - } - if yyrt186 { - for ; yyj186 < yyl186; yyj186++ { - yyv186 = append(yyv186, pkg2_api.OwnerReference{}) - yyh186.ElemContainerState(yyj186) - if r.TryDecodeAsNil() { - yyv186[yyj186] = pkg2_api.OwnerReference{} - } else { - yyv188 := &yyv186[yyj186] - yyv188.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj186 := 0 - for ; !r.CheckBreak(); yyj186++ { - - if yyj186 >= len(yyv186) { - yyv186 = append(yyv186, pkg2_api.OwnerReference{}) // var yyz186 pkg2_api.OwnerReference - yyc186 = true - } - yyh186.ElemContainerState(yyj186) - if yyj186 < len(yyv186) { - if r.TryDecodeAsNil() { - yyv186[yyj186] = pkg2_api.OwnerReference{} - } else { - yyv189 := &yyv186[yyj186] - yyv189.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj186 < len(yyv186) { - yyv186 = yyv186[:yyj186] - yyc186 = true - } else if yyj186 == 0 && yyv186 == nil { - yyv186 = []pkg2_api.OwnerReference{} - yyc186 = true - } - } - yyh186.End() - if yyc186 { - *v = yyv186 - } -} - -func (x codecSelfer1234) encMapstringExtraValue(v map[string]ExtraValue, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk190, yyv190 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym191 := z.EncBinary() - _ = yym191 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk190)) - } - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv190 == nil { - r.EncodeNil() - } else { - yyv190.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) decMapstringExtraValue(v *map[string]ExtraValue, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv192 := *v - yyl192 := r.ReadMapStart() - yybh192 := z.DecBasicHandle() - if yyv192 == nil { - yyrl192, _ := z.DecInferLen(yyl192, yybh192.MaxInitLen, 40) - yyv192 = make(map[string]ExtraValue, yyrl192) - *v = yyv192 - } - var yymk192 string - var yymv192 ExtraValue - var yymg192 bool - if yybh192.MapValueReset { - yymg192 = true - } - if yyl192 > 0 { - for yyj192 := 0; yyj192 < yyl192; yyj192++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk192 = "" - } else { - yymk192 = string(r.DecodeString()) - } - - if yymg192 { - yymv192 = yyv192[yymk192] - } else { - yymv192 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv192 = nil - } else { - yyv194 := &yymv192 - yyv194.CodecDecodeSelf(d) - } - - if yyv192 != nil { - yyv192[yymk192] = yymv192 - } - } - } else if yyl192 < 0 { - for yyj192 := 0; !r.CheckBreak(); yyj192++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk192 = "" - } else { - yymk192 = string(r.DecodeString()) - } - - if yymg192 { - yymv192 = yyv192[yymk192] - } else { - yymv192 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv192 = nil - } else { - yyv196 := &yymv192 - yyv196.CodecDecodeSelf(d) - } - - if yyv192 != nil { - yyv192[yymk192] = yymv192 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) encExtraValue(v ExtraValue, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv197 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym198 := z.EncBinary() - _ = yym198 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyv197)) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv199 := *v - yyh199, yyl199 := z.DecSliceHelperStart() - var yyc199 bool - if yyl199 == 0 { - if yyv199 == nil { - yyv199 = []string{} - yyc199 = true - } else if len(yyv199) != 0 { - yyv199 = yyv199[:0] - yyc199 = true - } - } else if yyl199 > 0 { - var yyrr199, yyrl199 int - var yyrt199 bool - if yyl199 > cap(yyv199) { - - yyrl199, yyrt199 = z.DecInferLen(yyl199, z.DecBasicHandle().MaxInitLen, 16) - if yyrt199 { - if yyrl199 <= cap(yyv199) { - yyv199 = yyv199[:yyrl199] - } else { - yyv199 = make([]string, yyrl199) - } - } else { - yyv199 = make([]string, yyrl199) - } - yyc199 = true - yyrr199 = len(yyv199) - } else if yyl199 != len(yyv199) { - yyv199 = yyv199[:yyl199] - yyc199 = true - } - yyj199 := 0 - for ; yyj199 < yyrr199; yyj199++ { - yyh199.ElemContainerState(yyj199) - if r.TryDecodeAsNil() { - yyv199[yyj199] = "" - } else { - yyv199[yyj199] = string(r.DecodeString()) - } - - } - if yyrt199 { - for ; yyj199 < yyl199; yyj199++ { - yyv199 = append(yyv199, "") - yyh199.ElemContainerState(yyj199) - if r.TryDecodeAsNil() { - yyv199[yyj199] = "" - } else { - yyv199[yyj199] = string(r.DecodeString()) - } - - } - } - - } else { - yyj199 := 0 - for ; !r.CheckBreak(); yyj199++ { - - if yyj199 >= len(yyv199) { - yyv199 = append(yyv199, "") // var yyz199 string - yyc199 = true - } - yyh199.ElemContainerState(yyj199) - if yyj199 < len(yyv199) { - if r.TryDecodeAsNil() { - yyv199[yyj199] = "" - } else { - yyv199[yyj199] = string(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj199 < len(yyv199) { - yyv199 = yyv199[:yyj199] - yyc199 = true - } else if yyj199 == 0 && yyv199 == nil { - yyv199 = []string{} - yyc199 = true - } - } - yyh199.End() - if yyc199 { - *v = yyv199 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/types.go b/vendor/k8s.io/client-go/pkg/apis/authentication/types.go index 84edf83d95..9c1e66b7bb 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/types.go @@ -17,8 +17,7 @@ limitations under the License. package authentication import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) const ( @@ -42,10 +41,10 @@ const ( // TokenReview attempts to authenticate a token to a known user. type TokenReview struct { - unversioned.TypeMeta - // ObjectMeta fulfills the meta.ObjectMetaAccessor interface so that the stock + metav1.TypeMeta + // ObjectMeta fulfills the metav1.ObjectMetaAccessor interface so that the stock // REST handler paths work - api.ObjectMeta + metav1.ObjectMeta // Spec holds information about the request being evaluated Spec TokenReviewSpec diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/BUILD b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/BUILD new file mode 100644 index 0000000000..10ead221ba --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authentication:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/types/unix_user_id.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/conversion.go similarity index 69% rename from vendor/k8s.io/client-go/pkg/types/unix_user_id.go rename to vendor/k8s.io/client-go/pkg/apis/authentication/v1/conversion.go index dc770c11e2..2ff5732d6d 100644 --- a/vendor/k8s.io/client-go/pkg/types/unix_user_id.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/conversion.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,10 +14,13 @@ See the License for the specific language governing permissions and limitations under the License. */ -package types +package v1 -// int64 is used as a safe bet against wrap-around (uid's are general -// int32) and to support uid_t -1, and -2. +import ( + "k8s.io/apimachinery/pkg/runtime" +) -type UnixUserID int64 -type UnixGroupID int64 +func addConversionFuncs(scheme *runtime.Scheme) error { + // Add non-generated conversion functions + return scheme.AddConversionFuncs() +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/defaults.go new file mode 100644 index 0000000000..074e15baed --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/defaults.go @@ -0,0 +1,25 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/doc.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/doc.go new file mode 100644 index 0000000000..8140e47c59 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=authentication.k8s.io +package v1 diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go new file mode 100644 index 0000000000..e264811365 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.pb.go @@ -0,0 +1,1301 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/authentication/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/authentication/v1/generated.proto + + It has these top-level messages: + ExtraValue + TokenReview + TokenReviewSpec + TokenReviewStatus + UserInfo +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *ExtraValue) Reset() { *m = ExtraValue{} } +func (*ExtraValue) ProtoMessage() {} +func (*ExtraValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *TokenReview) Reset() { *m = TokenReview{} } +func (*TokenReview) ProtoMessage() {} +func (*TokenReview) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *TokenReviewSpec) Reset() { *m = TokenReviewSpec{} } +func (*TokenReviewSpec) ProtoMessage() {} +func (*TokenReviewSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *TokenReviewStatus) Reset() { *m = TokenReviewStatus{} } +func (*TokenReviewStatus) ProtoMessage() {} +func (*TokenReviewStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *UserInfo) Reset() { *m = UserInfo{} } +func (*UserInfo) ProtoMessage() {} +func (*UserInfo) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func init() { + proto.RegisterType((*ExtraValue)(nil), "k8s.io.client-go.pkg.apis.authentication.v1.ExtraValue") + proto.RegisterType((*TokenReview)(nil), "k8s.io.client-go.pkg.apis.authentication.v1.TokenReview") + proto.RegisterType((*TokenReviewSpec)(nil), "k8s.io.client-go.pkg.apis.authentication.v1.TokenReviewSpec") + proto.RegisterType((*TokenReviewStatus)(nil), "k8s.io.client-go.pkg.apis.authentication.v1.TokenReviewStatus") + proto.RegisterType((*UserInfo)(nil), "k8s.io.client-go.pkg.apis.authentication.v1.UserInfo") +} +func (m ExtraValue) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m ExtraValue) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *TokenReview) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TokenReview) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + return i, nil +} + +func (m *TokenReviewSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TokenReviewSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Token))) + i += copy(dAtA[i:], m.Token) + return i, nil +} + +func (m *TokenReviewStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *TokenReviewStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + if m.Authenticated { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.User.Size())) + n4, err := m.User.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Error))) + i += copy(dAtA[i:], m.Error) + return i, nil +} + +func (m *UserInfo) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *UserInfo) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Username))) + i += copy(dAtA[i:], m.Username) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) + if len(m.Groups) > 0 { + for _, s := range m.Groups { + dAtA[i] = 0x1a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Extra) > 0 { + keysForExtra := make([]string, 0, len(m.Extra)) + for k := range m.Extra { + keysForExtra = append(keysForExtra, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + for _, k := range keysForExtra { + dAtA[i] = 0x22 + i++ + v := m.Extra[string(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n5, err := (&v).MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + } + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m ExtraValue) Size() (n int) { + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *TokenReview) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *TokenReviewSpec) Size() (n int) { + var l int + _ = l + l = len(m.Token) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *TokenReviewStatus) Size() (n int) { + var l int + _ = l + n += 2 + l = m.User.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Error) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *UserInfo) Size() (n int) { + var l int + _ = l + l = len(m.Username) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.UID) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Groups) > 0 { + for _, s := range m.Groups { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Extra) > 0 { + for k, v := range m.Extra { + _ = k + _ = v + l = v.Size() + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l)) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *TokenReview) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TokenReview{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TokenReviewSpec", "TokenReviewSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "TokenReviewStatus", "TokenReviewStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *TokenReviewSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TokenReviewSpec{`, + `Token:` + fmt.Sprintf("%v", this.Token) + `,`, + `}`, + }, "") + return s +} +func (this *TokenReviewStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&TokenReviewStatus{`, + `Authenticated:` + fmt.Sprintf("%v", this.Authenticated) + `,`, + `User:` + strings.Replace(strings.Replace(this.User.String(), "UserInfo", "UserInfo", 1), `&`, ``, 1) + `,`, + `Error:` + fmt.Sprintf("%v", this.Error) + `,`, + `}`, + }, "") + return s +} +func (this *UserInfo) String() string { + if this == nil { + return "nil" + } + keysForExtra := make([]string, 0, len(this.Extra)) + for k := range this.Extra { + keysForExtra = append(keysForExtra, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + mapStringForExtra := "map[string]ExtraValue{" + for _, k := range keysForExtra { + mapStringForExtra += fmt.Sprintf("%v: %v,", k, this.Extra[k]) + } + mapStringForExtra += "}" + s := strings.Join([]string{`&UserInfo{`, + `Username:` + fmt.Sprintf("%v", this.Username) + `,`, + `UID:` + fmt.Sprintf("%v", this.UID) + `,`, + `Groups:` + fmt.Sprintf("%v", this.Groups) + `,`, + `Extra:` + mapStringForExtra + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *ExtraValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExtraValue: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExtraValue: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + *m = append(*m, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TokenReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: TokenReview: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TokenReview: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TokenReviewSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: TokenReviewSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TokenReviewSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Token", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Token = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *TokenReviewStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: TokenReviewStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: TokenReviewStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Authenticated", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Authenticated = bool(v != 0) + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field User", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.User.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Error = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *UserInfo) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: UserInfo: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: UserInfo: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Username", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Username = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UID", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.UID = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Groups", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Groups = append(m.Groups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Extra", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Extra == nil { + m.Extra = make(map[string]ExtraValue) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &ExtraValue{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Extra[mapkey] = *mapvalue + } else { + var mapvalue ExtraValue + m.Extra[mapkey] = mapvalue + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/authentication/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 640 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x53, 0xcd, 0x6e, 0xd3, 0x40, + 0x10, 0xb6, 0xf3, 0x53, 0x25, 0x1b, 0x0a, 0x65, 0x25, 0xa4, 0x28, 0x12, 0x4e, 0x14, 0x2e, 0x39, + 0x94, 0x35, 0x29, 0xa8, 0x54, 0x05, 0x84, 0x6a, 0x51, 0xa1, 0x1e, 0x00, 0x69, 0xa1, 0x08, 0x71, + 0x81, 0x8d, 0x33, 0x75, 0x96, 0xd4, 0x3f, 0x5a, 0xaf, 0x03, 0xbd, 0xf5, 0x11, 0x38, 0x72, 0xe4, + 0x35, 0x78, 0x83, 0xde, 0xe8, 0x8d, 0x1e, 0x50, 0x45, 0xcd, 0x8b, 0xa0, 0x5d, 0x2f, 0x4d, 0xda, + 0x52, 0xa1, 0xf6, 0xe6, 0xfd, 0x66, 0xbe, 0x6f, 0xbe, 0x99, 0xf1, 0xa0, 0x87, 0xe3, 0x95, 0x94, + 0xf0, 0xd8, 0x1d, 0x67, 0x03, 0x10, 0x11, 0x48, 0x48, 0xdd, 0x64, 0x1c, 0xb8, 0x2c, 0xe1, 0xa9, + 0xcb, 0x32, 0x39, 0x82, 0x48, 0x72, 0x9f, 0x49, 0x1e, 0x47, 0xee, 0xa4, 0xef, 0x06, 0x10, 0x81, + 0x60, 0x12, 0x86, 0x24, 0x11, 0xb1, 0x8c, 0xf1, 0x62, 0xc1, 0x26, 0x53, 0x36, 0x49, 0xc6, 0x01, + 0x51, 0x6c, 0x72, 0x92, 0x4d, 0x26, 0xfd, 0xd6, 0xed, 0x80, 0xcb, 0x51, 0x36, 0x20, 0x7e, 0x1c, + 0xba, 0x41, 0x1c, 0xc4, 0xae, 0x16, 0x19, 0x64, 0x5b, 0xfa, 0xa5, 0x1f, 0xfa, 0xab, 0x10, 0x6f, + 0xdd, 0x33, 0xd6, 0x58, 0xc2, 0x43, 0xe6, 0x8f, 0x78, 0x04, 0x62, 0x67, 0x6a, 0x2e, 0x04, 0xc9, + 0xfe, 0x61, 0xa9, 0xe5, 0x9e, 0xc7, 0x12, 0x59, 0x24, 0x79, 0x08, 0x67, 0x08, 0xcb, 0xff, 0x23, + 0xa4, 0xfe, 0x08, 0x42, 0x76, 0x86, 0x77, 0xf7, 0x3c, 0x5e, 0x26, 0xf9, 0xb6, 0xcb, 0x23, 0x99, + 0x4a, 0x71, 0x9a, 0xd4, 0xbd, 0x8f, 0xd0, 0xfa, 0x27, 0x29, 0xd8, 0x6b, 0xb6, 0x9d, 0x01, 0x6e, + 0xa3, 0x2a, 0x97, 0x10, 0xa6, 0x4d, 0xbb, 0x53, 0xee, 0xd5, 0xbd, 0x7a, 0x7e, 0xd8, 0xae, 0x6e, + 0x28, 0x80, 0x16, 0xf8, 0x6a, 0xed, 0xcb, 0xd7, 0xb6, 0xb5, 0xfb, 0xb3, 0x63, 0x75, 0xbf, 0x95, + 0x50, 0xe3, 0x55, 0x3c, 0x86, 0x88, 0xc2, 0x84, 0xc3, 0x47, 0xfc, 0x1e, 0xd5, 0xd4, 0x04, 0x86, + 0x4c, 0xb2, 0xa6, 0xdd, 0xb1, 0x7b, 0x8d, 0xa5, 0x3b, 0xc4, 0x2c, 0x63, 0xd6, 0xd0, 0x74, 0x1d, + 0x2a, 0x9b, 0x4c, 0xfa, 0xe4, 0xc5, 0xe0, 0x03, 0xf8, 0xf2, 0x19, 0x48, 0xe6, 0xe1, 0xbd, 0xc3, + 0xb6, 0x95, 0x1f, 0xb6, 0xd1, 0x14, 0xa3, 0xc7, 0xaa, 0xf8, 0x1d, 0xaa, 0xa4, 0x09, 0xf8, 0xcd, + 0x92, 0x56, 0x7f, 0x44, 0x2e, 0xb2, 0x6a, 0x32, 0x63, 0xf5, 0x65, 0x02, 0xbe, 0x77, 0xc5, 0x94, + 0xaa, 0xa8, 0x17, 0xd5, 0xc2, 0x38, 0x40, 0x73, 0xa9, 0x64, 0x32, 0x4b, 0x9b, 0x65, 0x5d, 0xe2, + 0xf1, 0xe5, 0x4b, 0x68, 0x19, 0xef, 0xaa, 0x29, 0x32, 0x57, 0xbc, 0xa9, 0x91, 0xef, 0x2e, 0xa3, + 0x6b, 0xa7, 0xfc, 0xe0, 0x5b, 0xa8, 0x2a, 0x15, 0xa4, 0x67, 0x57, 0xf7, 0xe6, 0x0d, 0xb3, 0x5a, + 0xe4, 0x15, 0xb1, 0xee, 0x77, 0x1b, 0x5d, 0x3f, 0x53, 0x05, 0x3f, 0x40, 0xf3, 0x33, 0x66, 0x60, + 0xa8, 0x25, 0x6a, 0xde, 0x0d, 0x23, 0x31, 0xbf, 0x36, 0x1b, 0xa4, 0x27, 0x73, 0xf1, 0x1b, 0x54, + 0xc9, 0x52, 0x10, 0x66, 0xa8, 0xcb, 0x17, 0xeb, 0x78, 0x33, 0x05, 0xb1, 0x11, 0x6d, 0xc5, 0xd3, + 0x69, 0x2a, 0x84, 0x6a, 0x45, 0xd5, 0x11, 0x08, 0x11, 0x0b, 0x3d, 0xcc, 0x99, 0x8e, 0xd6, 0x15, + 0x48, 0x8b, 0x58, 0xf7, 0x47, 0x09, 0xd5, 0xfe, 0xaa, 0xe0, 0x45, 0x54, 0x53, 0xcc, 0x88, 0x85, + 0x60, 0xc6, 0xb0, 0x60, 0x48, 0x3a, 0x47, 0xe1, 0xf4, 0x38, 0x03, 0xdf, 0x44, 0xe5, 0x8c, 0x0f, + 0xb5, 0xf1, 0xba, 0xd7, 0x30, 0x89, 0xe5, 0xcd, 0x8d, 0x27, 0x54, 0xe1, 0xb8, 0x8b, 0xe6, 0x02, + 0x11, 0x67, 0x89, 0x5a, 0xa6, 0xfa, 0x97, 0x91, 0xda, 0xc3, 0x53, 0x8d, 0x50, 0x13, 0xc1, 0x5b, + 0xa8, 0x0a, 0xea, 0xe7, 0x6f, 0x56, 0x3a, 0xe5, 0x5e, 0x63, 0x69, 0xed, 0x72, 0xdd, 0x13, 0x7d, + 0x40, 0xeb, 0x91, 0x14, 0x3b, 0x33, 0x5d, 0x2a, 0x8c, 0x16, 0xf2, 0x2d, 0x61, 0x8e, 0x4c, 0xe7, + 0xe0, 0x05, 0x54, 0x1e, 0xc3, 0x4e, 0xd1, 0x21, 0x55, 0x9f, 0xf8, 0x39, 0xaa, 0x4e, 0xd4, 0xfd, + 0x99, 0x2d, 0xac, 0x5c, 0xcc, 0xc7, 0xf4, 0x7e, 0x69, 0x21, 0xb3, 0x5a, 0x5a, 0xb1, 0xbd, 0xde, + 0xde, 0x91, 0x63, 0xed, 0x1f, 0x39, 0xd6, 0xc1, 0x91, 0x63, 0xed, 0xe6, 0x8e, 0xbd, 0x97, 0x3b, + 0xf6, 0x7e, 0xee, 0xd8, 0x07, 0xb9, 0x63, 0xff, 0xca, 0x1d, 0xfb, 0xf3, 0x6f, 0xc7, 0x7a, 0x5b, + 0x9a, 0xf4, 0xff, 0x04, 0x00, 0x00, 0xff, 0xff, 0x01, 0xcb, 0xf3, 0xc9, 0x72, 0x05, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto new file mode 100644 index 0000000000..411065848a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/generated.proto @@ -0,0 +1,99 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.authentication.v1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// ExtraValue masks the value so protobuf can generate +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +message ExtraValue { + // items, if empty, will result in an empty slice + + repeated string items = 1; +} + +// TokenReview attempts to authenticate a token to a known user. +// Note: TokenReview requests may be cached by the webhook token authenticator +// plugin in the kube-apiserver. +message TokenReview { + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Spec holds information about the request being evaluated + optional TokenReviewSpec spec = 2; + + // Status is filled in by the server and indicates whether the request can be authenticated. + // +optional + optional TokenReviewStatus status = 3; +} + +// TokenReviewSpec is a description of the token authentication request. +message TokenReviewSpec { + // Token is the opaque bearer token. + // +optional + optional string token = 1; +} + +// TokenReviewStatus is the result of the token authentication request. +message TokenReviewStatus { + // Authenticated indicates that the token was associated with a known user. + // +optional + optional bool authenticated = 1; + + // User is the UserInfo associated with the provided token. + // +optional + optional UserInfo user = 2; + + // Error indicates that the token couldn't be checked + // +optional + optional string error = 3; +} + +// UserInfo holds the information about the user needed to implement the +// user.Info interface. +message UserInfo { + // The name that uniquely identifies this user among all active users. + // +optional + optional string username = 1; + + // A unique value that identifies this user across time. If this user is + // deleted and another user by the same name is added, they will have + // different UIDs. + // +optional + optional string uid = 2; + + // The names of groups this user is a part of. + // +optional + repeated string groups = 3; + + // Any additional information provided by the authenticator. + // +optional + map extra = 4; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/register.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/register.go new file mode 100644 index 0000000000..b4ab6519c0 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/register.go @@ -0,0 +1,58 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "authentication.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &TokenReview{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/types.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/types.go new file mode 100644 index 0000000000..21051f137b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/types.go @@ -0,0 +1,106 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "fmt" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +const ( + // ImpersonateUserHeader is used to impersonate a particular user during an API server request + ImpersonateUserHeader = "Impersonate-User" + + // ImpersonateGroupHeader is used to impersonate a particular group during an API server request. + // It can be repeated multiplied times for multiple groups. + ImpersonateGroupHeader = "Impersonate-Group" + + // ImpersonateUserExtraHeaderPrefix is a prefix for any header used to impersonate an entry in the + // extra map[string][]string for user.Info. The key will be every after the prefix. + // It can be repeated multiplied times for multiple map keys and the same key can be repeated multiple + // times to have multiple elements in the slice under a single key + ImpersonateUserExtraHeaderPrefix = "Impersonate-Extra-" +) + +// +genclient=true +// +nonNamespaced=true +// +noMethods=true + +// TokenReview attempts to authenticate a token to a known user. +// Note: TokenReview requests may be cached by the webhook token authenticator +// plugin in the kube-apiserver. +type TokenReview struct { + metav1.TypeMeta `json:",inline"` + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Spec holds information about the request being evaluated + Spec TokenReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` + + // Status is filled in by the server and indicates whether the request can be authenticated. + // +optional + Status TokenReviewStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// TokenReviewSpec is a description of the token authentication request. +type TokenReviewSpec struct { + // Token is the opaque bearer token. + // +optional + Token string `json:"token,omitempty" protobuf:"bytes,1,opt,name=token"` +} + +// TokenReviewStatus is the result of the token authentication request. +type TokenReviewStatus struct { + // Authenticated indicates that the token was associated with a known user. + // +optional + Authenticated bool `json:"authenticated,omitempty" protobuf:"varint,1,opt,name=authenticated"` + // User is the UserInfo associated with the provided token. + // +optional + User UserInfo `json:"user,omitempty" protobuf:"bytes,2,opt,name=user"` + // Error indicates that the token couldn't be checked + // +optional + Error string `json:"error,omitempty" protobuf:"bytes,3,opt,name=error"` +} + +// UserInfo holds the information about the user needed to implement the +// user.Info interface. +type UserInfo struct { + // The name that uniquely identifies this user among all active users. + // +optional + Username string `json:"username,omitempty" protobuf:"bytes,1,opt,name=username"` + // A unique value that identifies this user across time. If this user is + // deleted and another user by the same name is added, they will have + // different UIDs. + // +optional + UID string `json:"uid,omitempty" protobuf:"bytes,2,opt,name=uid"` + // The names of groups this user is a part of. + // +optional + Groups []string `json:"groups,omitempty" protobuf:"bytes,3,rep,name=groups"` + // Any additional information provided by the authenticator. + // +optional + Extra map[string]ExtraValue `json:"extra,omitempty" protobuf:"bytes,4,rep,name=extra"` +} + +// ExtraValue masks the value so protobuf can generate +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +type ExtraValue []string + +func (t ExtraValue) String() string { + return fmt.Sprintf("%v", []string(t)) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..bb235e4eaa --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/types_swagger_doc_generated.go @@ -0,0 +1,72 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_TokenReview = map[string]string{ + "": "TokenReview attempts to authenticate a token to a known user. Note: TokenReview requests may be cached by the webhook token authenticator plugin in the kube-apiserver.", + "spec": "Spec holds information about the request being evaluated", + "status": "Status is filled in by the server and indicates whether the request can be authenticated.", +} + +func (TokenReview) SwaggerDoc() map[string]string { + return map_TokenReview +} + +var map_TokenReviewSpec = map[string]string{ + "": "TokenReviewSpec is a description of the token authentication request.", + "token": "Token is the opaque bearer token.", +} + +func (TokenReviewSpec) SwaggerDoc() map[string]string { + return map_TokenReviewSpec +} + +var map_TokenReviewStatus = map[string]string{ + "": "TokenReviewStatus is the result of the token authentication request.", + "authenticated": "Authenticated indicates that the token was associated with a known user.", + "user": "User is the UserInfo associated with the provided token.", + "error": "Error indicates that the token couldn't be checked", +} + +func (TokenReviewStatus) SwaggerDoc() map[string]string { + return map_TokenReviewStatus +} + +var map_UserInfo = map[string]string{ + "": "UserInfo holds the information about the user needed to implement the user.Info interface.", + "username": "The name that uniquely identifies this user among all active users.", + "uid": "A unique value that identifies this user across time. If this user is deleted and another user by the same name is added, they will have different UIDs.", + "groups": "The names of groups this user is a part of.", + "extra": "Any additional information provided by the authenticator.", +} + +func (UserInfo) SwaggerDoc() map[string]string { + return map_UserInfo +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.conversion.go new file mode 100644 index 0000000000..3a4923cc20 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.conversion.go @@ -0,0 +1,153 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + authentication "k8s.io/client-go/pkg/apis/authentication" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1_TokenReview_To_authentication_TokenReview, + Convert_authentication_TokenReview_To_v1_TokenReview, + Convert_v1_TokenReviewSpec_To_authentication_TokenReviewSpec, + Convert_authentication_TokenReviewSpec_To_v1_TokenReviewSpec, + Convert_v1_TokenReviewStatus_To_authentication_TokenReviewStatus, + Convert_authentication_TokenReviewStatus_To_v1_TokenReviewStatus, + Convert_v1_UserInfo_To_authentication_UserInfo, + Convert_authentication_UserInfo_To_v1_UserInfo, + ) +} + +func autoConvert_v1_TokenReview_To_authentication_TokenReview(in *TokenReview, out *authentication.TokenReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_TokenReviewSpec_To_authentication_TokenReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1_TokenReviewStatus_To_authentication_TokenReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1_TokenReview_To_authentication_TokenReview is an autogenerated conversion function. +func Convert_v1_TokenReview_To_authentication_TokenReview(in *TokenReview, out *authentication.TokenReview, s conversion.Scope) error { + return autoConvert_v1_TokenReview_To_authentication_TokenReview(in, out, s) +} + +func autoConvert_authentication_TokenReview_To_v1_TokenReview(in *authentication.TokenReview, out *TokenReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_authentication_TokenReviewSpec_To_v1_TokenReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_authentication_TokenReviewStatus_To_v1_TokenReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_authentication_TokenReview_To_v1_TokenReview is an autogenerated conversion function. +func Convert_authentication_TokenReview_To_v1_TokenReview(in *authentication.TokenReview, out *TokenReview, s conversion.Scope) error { + return autoConvert_authentication_TokenReview_To_v1_TokenReview(in, out, s) +} + +func autoConvert_v1_TokenReviewSpec_To_authentication_TokenReviewSpec(in *TokenReviewSpec, out *authentication.TokenReviewSpec, s conversion.Scope) error { + out.Token = in.Token + return nil +} + +// Convert_v1_TokenReviewSpec_To_authentication_TokenReviewSpec is an autogenerated conversion function. +func Convert_v1_TokenReviewSpec_To_authentication_TokenReviewSpec(in *TokenReviewSpec, out *authentication.TokenReviewSpec, s conversion.Scope) error { + return autoConvert_v1_TokenReviewSpec_To_authentication_TokenReviewSpec(in, out, s) +} + +func autoConvert_authentication_TokenReviewSpec_To_v1_TokenReviewSpec(in *authentication.TokenReviewSpec, out *TokenReviewSpec, s conversion.Scope) error { + out.Token = in.Token + return nil +} + +// Convert_authentication_TokenReviewSpec_To_v1_TokenReviewSpec is an autogenerated conversion function. +func Convert_authentication_TokenReviewSpec_To_v1_TokenReviewSpec(in *authentication.TokenReviewSpec, out *TokenReviewSpec, s conversion.Scope) error { + return autoConvert_authentication_TokenReviewSpec_To_v1_TokenReviewSpec(in, out, s) +} + +func autoConvert_v1_TokenReviewStatus_To_authentication_TokenReviewStatus(in *TokenReviewStatus, out *authentication.TokenReviewStatus, s conversion.Scope) error { + out.Authenticated = in.Authenticated + if err := Convert_v1_UserInfo_To_authentication_UserInfo(&in.User, &out.User, s); err != nil { + return err + } + out.Error = in.Error + return nil +} + +// Convert_v1_TokenReviewStatus_To_authentication_TokenReviewStatus is an autogenerated conversion function. +func Convert_v1_TokenReviewStatus_To_authentication_TokenReviewStatus(in *TokenReviewStatus, out *authentication.TokenReviewStatus, s conversion.Scope) error { + return autoConvert_v1_TokenReviewStatus_To_authentication_TokenReviewStatus(in, out, s) +} + +func autoConvert_authentication_TokenReviewStatus_To_v1_TokenReviewStatus(in *authentication.TokenReviewStatus, out *TokenReviewStatus, s conversion.Scope) error { + out.Authenticated = in.Authenticated + if err := Convert_authentication_UserInfo_To_v1_UserInfo(&in.User, &out.User, s); err != nil { + return err + } + out.Error = in.Error + return nil +} + +// Convert_authentication_TokenReviewStatus_To_v1_TokenReviewStatus is an autogenerated conversion function. +func Convert_authentication_TokenReviewStatus_To_v1_TokenReviewStatus(in *authentication.TokenReviewStatus, out *TokenReviewStatus, s conversion.Scope) error { + return autoConvert_authentication_TokenReviewStatus_To_v1_TokenReviewStatus(in, out, s) +} + +func autoConvert_v1_UserInfo_To_authentication_UserInfo(in *UserInfo, out *authentication.UserInfo, s conversion.Scope) error { + out.Username = in.Username + out.UID = in.UID + out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) + out.Extra = *(*map[string]authentication.ExtraValue)(unsafe.Pointer(&in.Extra)) + return nil +} + +// Convert_v1_UserInfo_To_authentication_UserInfo is an autogenerated conversion function. +func Convert_v1_UserInfo_To_authentication_UserInfo(in *UserInfo, out *authentication.UserInfo, s conversion.Scope) error { + return autoConvert_v1_UserInfo_To_authentication_UserInfo(in, out, s) +} + +func autoConvert_authentication_UserInfo_To_v1_UserInfo(in *authentication.UserInfo, out *UserInfo, s conversion.Scope) error { + out.Username = in.Username + out.UID = in.UID + out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) + out.Extra = *(*map[string]ExtraValue)(unsafe.Pointer(&in.Extra)) + return nil +} + +// Convert_authentication_UserInfo_To_v1_UserInfo is an autogenerated conversion function. +func Convert_authentication_UserInfo_To_v1_UserInfo(in *authentication.UserInfo, out *UserInfo, s conversion.Scope) error { + return autoConvert_authentication_UserInfo_To_v1_UserInfo(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..929c85fcab --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.deepcopy.go @@ -0,0 +1,110 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_TokenReview, InType: reflect.TypeOf(&TokenReview{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_TokenReviewSpec, InType: reflect.TypeOf(&TokenReviewSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_TokenReviewStatus, InType: reflect.TypeOf(&TokenReviewStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_UserInfo, InType: reflect.TypeOf(&UserInfo{})}, + ) +} + +// DeepCopy_v1_TokenReview is an autogenerated deepcopy function. +func DeepCopy_v1_TokenReview(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TokenReview) + out := out.(*TokenReview) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_TokenReviewStatus(&in.Status, &out.Status, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_TokenReviewSpec is an autogenerated deepcopy function. +func DeepCopy_v1_TokenReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TokenReviewSpec) + out := out.(*TokenReviewSpec) + *out = *in + return nil + } +} + +// DeepCopy_v1_TokenReviewStatus is an autogenerated deepcopy function. +func DeepCopy_v1_TokenReviewStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*TokenReviewStatus) + out := out.(*TokenReviewStatus) + *out = *in + if err := DeepCopy_v1_UserInfo(&in.User, &out.User, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_UserInfo is an autogenerated deepcopy function. +func DeepCopy_v1_UserInfo(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*UserInfo) + out := out.(*UserInfo) + *out = *in + if in.Groups != nil { + in, out := &in.Groups, &out.Groups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Extra != nil { + in, out := &in.Extra, &out.Extra + *out = make(map[string]ExtraValue) + for key, val := range *in { + if newVal, err := c.DeepCopy(&val); err != nil { + return err + } else { + (*out)[key] = *newVal.(*ExtraValue) + } + } + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.defaults.go new file mode 100644 index 0000000000..6df448eb9f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/BUILD new file mode 100644 index 0000000000..4b0104a202 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authentication:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/conversion.go index 93cccc5bc2..51f3adfc71 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/conversion.go @@ -17,7 +17,7 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addConversionFuncs(scheme *runtime.Scheme) error { diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/defaults.go index f3b22e9560..37abb53bd2 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/defaults.go @@ -17,9 +17,9 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - return scheme.AddDefaultingFuncs() + return RegisterDefaults(scheme) } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/doc.go index 528723cfb5..342f201268 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/doc.go @@ -14,9 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/authentication // +groupName=authentication.k8s.io -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go index f95573135f..9917cdc6db 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -37,9 +37,10 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + import strings "strings" import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import io "io" @@ -50,7 +51,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *ExtraValue) Reset() { *m = ExtraValue{} } func (*ExtraValue) ProtoMessage() {} @@ -79,74 +82,74 @@ func init() { proto.RegisterType((*TokenReviewStatus)(nil), "k8s.io.client-go.pkg.apis.authentication.v1beta1.TokenReviewStatus") proto.RegisterType((*UserInfo)(nil), "k8s.io.client-go.pkg.apis.authentication.v1beta1.UserInfo") } -func (m ExtraValue) Marshal() (data []byte, err error) { +func (m ExtraValue) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m ExtraValue) MarshalTo(data []byte) (int, error) { +func (m ExtraValue) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m) > 0 { for _, s := range m { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *TokenReview) Marshal() (data []byte, err error) { +func (m *TokenReview) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *TokenReview) MarshalTo(data []byte) (int, error) { +func (m *TokenReview) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -154,120 +157,129 @@ func (m *TokenReview) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *TokenReviewSpec) Marshal() (data []byte, err error) { +func (m *TokenReviewSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *TokenReviewSpec) MarshalTo(data []byte) (int, error) { +func (m *TokenReviewSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Token))) - i += copy(data[i:], m.Token) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Token))) + i += copy(dAtA[i:], m.Token) return i, nil } -func (m *TokenReviewStatus) Marshal() (data []byte, err error) { +func (m *TokenReviewStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *TokenReviewStatus) MarshalTo(data []byte) (int, error) { +func (m *TokenReviewStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ if m.Authenticated { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.User.Size())) - n4, err := m.User.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.User.Size())) + n4, err := m.User.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Error))) - i += copy(data[i:], m.Error) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Error))) + i += copy(dAtA[i:], m.Error) return i, nil } -func (m *UserInfo) Marshal() (data []byte, err error) { +func (m *UserInfo) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *UserInfo) MarshalTo(data []byte) (int, error) { +func (m *UserInfo) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Username))) - i += copy(data[i:], m.Username) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Username))) + i += copy(dAtA[i:], m.Username) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.UID))) - i += copy(data[i:], m.UID) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) if len(m.Groups) > 0 { for _, s := range m.Groups { - data[i] = 0x1a + dAtA[i] = 0x1a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Extra) > 0 { + keysForExtra := make([]string, 0, len(m.Extra)) for k := range m.Extra { - data[i] = 0x22 + keysForExtra = append(keysForExtra, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + for _, k := range keysForExtra { + dAtA[i] = 0x22 i++ - v := m.Extra[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Extra[string(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n5, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n5, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -277,31 +289,31 @@ func (m *UserInfo) MarshalTo(data []byte) (int, error) { return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m ExtraValue) Size() (n int) { @@ -390,7 +402,7 @@ func (this *TokenReview) String() string { return "nil" } s := strings.Join([]string{`&TokenReview{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "TokenReviewSpec", "TokenReviewSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "TokenReviewStatus", "TokenReviewStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -450,8 +462,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *ExtraValue) Unmarshal(data []byte) error { - l := len(data) +func (m *ExtraValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -463,7 +475,7 @@ func (m *ExtraValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -491,7 +503,7 @@ func (m *ExtraValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -506,11 +518,11 @@ func (m *ExtraValue) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - *m = append(*m, string(data[iNdEx:postIndex])) + *m = append(*m, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -529,8 +541,8 @@ func (m *ExtraValue) Unmarshal(data []byte) error { } return nil } -func (m *TokenReview) Unmarshal(data []byte) error { - l := len(data) +func (m *TokenReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -542,7 +554,7 @@ func (m *TokenReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -570,7 +582,7 @@ func (m *TokenReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -584,7 +596,7 @@ func (m *TokenReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -600,7 +612,7 @@ func (m *TokenReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -614,7 +626,7 @@ func (m *TokenReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -630,7 +642,7 @@ func (m *TokenReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -644,13 +656,13 @@ func (m *TokenReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -669,8 +681,8 @@ func (m *TokenReview) Unmarshal(data []byte) error { } return nil } -func (m *TokenReviewSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *TokenReviewSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -682,7 +694,7 @@ func (m *TokenReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -710,7 +722,7 @@ func (m *TokenReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -725,11 +737,11 @@ func (m *TokenReviewSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Token = string(data[iNdEx:postIndex]) + m.Token = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -748,8 +760,8 @@ func (m *TokenReviewSpec) Unmarshal(data []byte) error { } return nil } -func (m *TokenReviewStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *TokenReviewStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -761,7 +773,7 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -789,7 +801,7 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -809,7 +821,7 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -823,7 +835,7 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.User.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.User.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -839,7 +851,7 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -854,11 +866,11 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Error = string(data[iNdEx:postIndex]) + m.Error = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -877,8 +889,8 @@ func (m *TokenReviewStatus) Unmarshal(data []byte) error { } return nil } -func (m *UserInfo) Unmarshal(data []byte) error { - l := len(data) +func (m *UserInfo) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -890,7 +902,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -918,7 +930,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -933,7 +945,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Username = string(data[iNdEx:postIndex]) + m.Username = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -947,7 +959,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -962,7 +974,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.UID = string(data[iNdEx:postIndex]) + m.UID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -976,7 +988,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -991,7 +1003,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Groups = append(m.Groups, string(data[iNdEx:postIndex])) + m.Groups = append(m.Groups, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 4: if wireType != 2 { @@ -1005,7 +1017,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1027,7 +1039,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1042,7 +1054,7 @@ func (m *UserInfo) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1057,61 +1069,66 @@ func (m *UserInfo) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Extra == nil { + m.Extra = make(map[string]ExtraValue) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &ExtraValue{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Extra[mapkey] = *mapvalue + } else { + var mapvalue ExtraValue + m.Extra[mapkey] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &ExtraValue{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Extra == nil { - m.Extra = make(map[string]ExtraValue) - } - m.Extra[mapkey] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1130,8 +1147,8 @@ func (m *UserInfo) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -1142,7 +1159,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1160,7 +1177,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -1177,7 +1194,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1200,7 +1217,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1211,7 +1228,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1235,47 +1252,51 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 642 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xa4, 0x93, 0xcf, 0x6e, 0x13, 0x31, - 0x10, 0xc6, 0xb3, 0xf9, 0x53, 0x12, 0x87, 0x42, 0xb1, 0x84, 0x14, 0x45, 0x62, 0x13, 0x85, 0x4b, - 0x90, 0x5a, 0xaf, 0x52, 0x09, 0xa8, 0x5a, 0x71, 0xe8, 0xaa, 0x05, 0xf5, 0x80, 0x90, 0x5c, 0x8a, - 0x10, 0x12, 0x07, 0x27, 0x99, 0x6e, 0x97, 0x6d, 0xd6, 0x2b, 0xaf, 0x9d, 0xd2, 0x5b, 0x1f, 0x81, - 0x23, 0x47, 0xde, 0x83, 0x17, 0xe8, 0xb1, 0x07, 0x0e, 0x1c, 0x50, 0x45, 0xc2, 0x8b, 0x20, 0x7b, - 0x4d, 0x93, 0x36, 0xcd, 0x81, 0xf6, 0xb6, 0xfe, 0x3c, 0xf3, 0x9b, 0x6f, 0xc6, 0x3b, 0x68, 0x33, - 0x5a, 0x4b, 0x49, 0xc8, 0xbd, 0x48, 0x75, 0x41, 0xc4, 0x20, 0x21, 0xf5, 0x92, 0x28, 0xf0, 0x58, - 0x12, 0xa6, 0x1e, 0x53, 0xf2, 0x00, 0x62, 0x19, 0xf6, 0x98, 0x0c, 0x79, 0xec, 0x0d, 0x3b, 0x5d, - 0x90, 0xac, 0xe3, 0x05, 0x10, 0x83, 0x60, 0x12, 0xfa, 0x24, 0x11, 0x5c, 0x72, 0xdc, 0xc9, 0x10, - 0x64, 0x82, 0x20, 0x49, 0x14, 0x10, 0x8d, 0x20, 0x97, 0x11, 0xc4, 0x22, 0xea, 0x2b, 0x41, 0x28, - 0x0f, 0x54, 0x97, 0xf4, 0xf8, 0xc0, 0x0b, 0x78, 0xc0, 0x3d, 0x43, 0xea, 0xaa, 0x7d, 0x73, 0x32, - 0x07, 0xf3, 0x95, 0x55, 0xa8, 0xaf, 0xce, 0x35, 0xe9, 0x09, 0x48, 0xb9, 0x12, 0x3d, 0xb8, 0xea, - 0xaa, 0xfe, 0x74, 0x7e, 0x8e, 0x8a, 0x87, 0x20, 0xd2, 0x90, 0xc7, 0xd0, 0x9f, 0x49, 0x5b, 0x9e, - 0x9f, 0x36, 0x9c, 0x69, 0xbd, 0xbe, 0x72, 0x7d, 0xb4, 0x50, 0xb1, 0x0c, 0x07, 0xb3, 0x9e, 0x3a, - 0xd7, 0x87, 0x2b, 0x19, 0x1e, 0x7a, 0x61, 0x2c, 0x53, 0x29, 0xae, 0xa6, 0xb4, 0x9e, 0x23, 0xb4, - 0xfd, 0x59, 0x0a, 0xf6, 0x8e, 0x1d, 0x2a, 0xc0, 0x0d, 0x54, 0x0a, 0x25, 0x0c, 0xd2, 0x9a, 0xd3, - 0x2c, 0xb4, 0x2b, 0x7e, 0x65, 0x7c, 0xde, 0x28, 0xed, 0x68, 0x81, 0x66, 0xfa, 0x7a, 0xf9, 0xeb, - 0xb7, 0x46, 0xee, 0xe4, 0x57, 0x33, 0xd7, 0xfa, 0x9e, 0x47, 0xd5, 0xb7, 0x3c, 0x82, 0x98, 0xc2, - 0x30, 0x84, 0x23, 0xfc, 0x1e, 0x95, 0x07, 0x20, 0x59, 0x9f, 0x49, 0x56, 0x73, 0x9a, 0x4e, 0xbb, - 0xba, 0xda, 0x26, 0x73, 0x1f, 0x8e, 0x0c, 0x3b, 0xe4, 0x4d, 0xf7, 0x13, 0xf4, 0xe4, 0x6b, 0x90, - 0xcc, 0xc7, 0xa7, 0xe7, 0x8d, 0xdc, 0xf8, 0xbc, 0x81, 0x26, 0x1a, 0xbd, 0xa0, 0xe1, 0x3e, 0x2a, - 0xa6, 0x09, 0xf4, 0x6a, 0x79, 0x43, 0xf5, 0xc9, 0x7f, 0xff, 0x0e, 0x64, 0xca, 0xe7, 0x6e, 0x02, - 0x3d, 0xff, 0xae, 0xad, 0x57, 0xd4, 0x27, 0x6a, 0xe8, 0xf8, 0x10, 0x2d, 0xa4, 0x92, 0x49, 0x95, - 0xd6, 0x0a, 0xa6, 0xce, 0xd6, 0x2d, 0xeb, 0x18, 0x96, 0x7f, 0xcf, 0x56, 0x5a, 0xc8, 0xce, 0xd4, - 0xd6, 0x68, 0x3d, 0x43, 0xf7, 0xaf, 0x98, 0xc2, 0x8f, 0x51, 0x49, 0x6a, 0xc9, 0x4c, 0xaf, 0xe2, - 0x2f, 0xda, 0xcc, 0x52, 0x16, 0x97, 0xdd, 0xb5, 0x7e, 0x38, 0xe8, 0xc1, 0x4c, 0x15, 0xbc, 0x81, - 0x16, 0xa7, 0x1c, 0x41, 0xdf, 0x20, 0xca, 0xfe, 0x43, 0x8b, 0x58, 0xdc, 0x9c, 0xbe, 0xa4, 0x97, - 0x63, 0xf1, 0x47, 0x54, 0x54, 0x29, 0x08, 0x3b, 0xde, 0x8d, 0x1b, 0xb4, 0xbd, 0x97, 0x82, 0xd8, - 0x89, 0xf7, 0xf9, 0x64, 0xae, 0x5a, 0xa1, 0x06, 0xab, 0xdb, 0x02, 0x21, 0xb8, 0x30, 0x63, 0x9d, - 0x6a, 0x6b, 0x5b, 0x8b, 0x34, 0xbb, 0x6b, 0x8d, 0xf2, 0xa8, 0xfc, 0x8f, 0x82, 0x97, 0x51, 0x59, - 0x67, 0xc6, 0x6c, 0x00, 0x76, 0x16, 0x4b, 0x36, 0xc9, 0xc4, 0x68, 0x9d, 0x5e, 0x44, 0xe0, 0x47, - 0xa8, 0xa0, 0xc2, 0xbe, 0x71, 0x5f, 0xf1, 0xab, 0x36, 0xb0, 0xb0, 0xb7, 0xb3, 0x45, 0xb5, 0x8e, - 0x5b, 0x68, 0x21, 0x10, 0x5c, 0x25, 0xfa, 0x59, 0xf5, 0x2f, 0x8d, 0xf4, 0x63, 0xbc, 0x32, 0x0a, - 0xb5, 0x37, 0x38, 0x42, 0x25, 0xd0, 0x3b, 0x50, 0x2b, 0x36, 0x0b, 0xed, 0xea, 0xea, 0xcb, 0x5b, - 0x8c, 0x80, 0x98, 0x65, 0xda, 0x8e, 0xa5, 0x38, 0x9e, 0x6a, 0x55, 0x6b, 0x34, 0xab, 0x51, 0x3f, - 0xb2, 0x0b, 0x67, 0x62, 0xf0, 0x12, 0x2a, 0x44, 0x70, 0x9c, 0xb5, 0x49, 0xf5, 0x27, 0xde, 0x45, - 0xa5, 0xa1, 0xde, 0x45, 0xfb, 0x1e, 0x2f, 0x6e, 0x60, 0x66, 0xb2, 0xd0, 0x34, 0x63, 0xad, 0xe7, - 0xd7, 0x1c, 0xff, 0xc9, 0xe9, 0xc8, 0xcd, 0x9d, 0x8d, 0xdc, 0xdc, 0xcf, 0x91, 0x9b, 0x3b, 0x19, - 0xbb, 0xce, 0xe9, 0xd8, 0x75, 0xce, 0xc6, 0xae, 0xf3, 0x7b, 0xec, 0x3a, 0x5f, 0xfe, 0xb8, 0xb9, - 0x0f, 0x77, 0x2c, 0xe0, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xca, 0xd0, 0x35, 0x8c, 0xb5, 0x05, - 0x00, 0x00, + // 647 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x53, 0x4f, 0x6f, 0xd3, 0x4e, + 0x10, 0xb5, 0xf3, 0xa7, 0xbf, 0x64, 0xf3, 0x2b, 0x94, 0x95, 0x90, 0xa2, 0x48, 0x38, 0x51, 0xb8, + 0xf4, 0x40, 0xd7, 0xa4, 0xa0, 0x52, 0xb5, 0xe2, 0x50, 0xab, 0x05, 0xf5, 0x80, 0x90, 0xb6, 0x94, + 0x03, 0x12, 0x12, 0x1b, 0x67, 0xea, 0x18, 0xd7, 0x7f, 0xb4, 0x5e, 0xa7, 0xf4, 0xd6, 0x8f, 0xc0, + 0x91, 0x23, 0xdf, 0x85, 0x4b, 0x8f, 0x3d, 0x70, 0xe8, 0x01, 0x45, 0xc4, 0x7c, 0x11, 0xb4, 0xeb, + 0xa5, 0x49, 0x1b, 0x55, 0x88, 0xf6, 0xe6, 0x7d, 0x33, 0xef, 0xcd, 0x9b, 0x19, 0x0f, 0xda, 0x0a, + 0xd6, 0x53, 0xe2, 0xc7, 0x76, 0x90, 0xf5, 0x81, 0x47, 0x20, 0x20, 0xb5, 0x93, 0xc0, 0xb3, 0x59, + 0xe2, 0xa7, 0x36, 0xcb, 0xc4, 0x10, 0x22, 0xe1, 0xbb, 0x4c, 0xf8, 0x71, 0x64, 0x8f, 0x7a, 0x7d, + 0x10, 0xac, 0x67, 0x7b, 0x10, 0x01, 0x67, 0x02, 0x06, 0x24, 0xe1, 0xb1, 0x88, 0x71, 0xaf, 0x90, + 0x20, 0x53, 0x09, 0x92, 0x04, 0x1e, 0x91, 0x12, 0xe4, 0xb2, 0x04, 0xd1, 0x12, 0xad, 0x15, 0xcf, + 0x17, 0xc3, 0xac, 0x4f, 0xdc, 0x38, 0xb4, 0xbd, 0xd8, 0x8b, 0x6d, 0xa5, 0xd4, 0xcf, 0x0e, 0xd4, + 0x4b, 0x3d, 0xd4, 0x57, 0x51, 0xa1, 0xf5, 0x54, 0x9b, 0x64, 0x89, 0x1f, 0x32, 0x77, 0xe8, 0x47, + 0xc0, 0x8f, 0xa7, 0x36, 0x43, 0x10, 0xcc, 0x1e, 0xcd, 0xf9, 0x6a, 0xd9, 0xd7, 0xb1, 0x78, 0x16, + 0x09, 0x3f, 0x84, 0x39, 0xc2, 0xda, 0xdf, 0x08, 0xa9, 0x3b, 0x84, 0x90, 0xcd, 0xf1, 0x9e, 0x5c, + 0xc7, 0xcb, 0x84, 0x7f, 0x68, 0xfb, 0x91, 0x48, 0x05, 0xbf, 0x4a, 0xea, 0x3e, 0x43, 0x68, 0xe7, + 0x93, 0xe0, 0xec, 0x2d, 0x3b, 0xcc, 0x00, 0xb7, 0x51, 0xd5, 0x17, 0x10, 0xa6, 0x4d, 0xb3, 0x53, + 0x5e, 0xae, 0x3b, 0xf5, 0x7c, 0xdc, 0xae, 0xee, 0x4a, 0x80, 0x16, 0xf8, 0x46, 0xed, 0xcb, 0xd7, + 0xb6, 0x71, 0xf2, 0xa3, 0x63, 0x74, 0xbf, 0x95, 0x50, 0xe3, 0x4d, 0x1c, 0x40, 0x44, 0x61, 0xe4, + 0xc3, 0x11, 0xfe, 0x80, 0x6a, 0x72, 0x02, 0x03, 0x26, 0x58, 0xd3, 0xec, 0x98, 0xcb, 0x8d, 0xd5, + 0xc7, 0x44, 0x6f, 0x64, 0xd6, 0xd0, 0x74, 0x27, 0x32, 0x9b, 0x8c, 0x7a, 0xe4, 0x75, 0xff, 0x23, + 0xb8, 0xe2, 0x15, 0x08, 0xe6, 0xe0, 0xd3, 0x71, 0xdb, 0xc8, 0xc7, 0x6d, 0x34, 0xc5, 0xe8, 0x85, + 0x2a, 0x1e, 0xa0, 0x4a, 0x9a, 0x80, 0xdb, 0x2c, 0x29, 0x75, 0x87, 0xfc, 0xf3, 0xbe, 0xc9, 0x8c, + 0xdf, 0xbd, 0x04, 0x5c, 0xe7, 0x7f, 0x5d, 0xaf, 0x22, 0x5f, 0x54, 0xa9, 0xe3, 0x43, 0xb4, 0x90, + 0x0a, 0x26, 0xb2, 0xb4, 0x59, 0x56, 0x75, 0xb6, 0x6f, 0x59, 0x47, 0x69, 0x39, 0x77, 0x74, 0xa5, + 0x85, 0xe2, 0x4d, 0x75, 0x8d, 0xee, 0x1a, 0xba, 0x7b, 0xc5, 0x14, 0x7e, 0x88, 0xaa, 0x42, 0x42, + 0x6a, 0x8a, 0x75, 0x67, 0x51, 0x33, 0xab, 0x45, 0x5e, 0x11, 0xeb, 0x7e, 0x37, 0xd1, 0xbd, 0xb9, + 0x2a, 0x78, 0x13, 0x2d, 0xce, 0x38, 0x82, 0x81, 0x92, 0xa8, 0x39, 0xf7, 0xb5, 0xc4, 0xe2, 0xd6, + 0x6c, 0x90, 0x5e, 0xce, 0xc5, 0xef, 0x51, 0x25, 0x4b, 0x81, 0xeb, 0xf1, 0x6e, 0xde, 0xa0, 0xed, + 0xfd, 0x14, 0xf8, 0x6e, 0x74, 0x10, 0x4f, 0xe7, 0x2a, 0x11, 0xaa, 0x64, 0x65, 0x5b, 0xc0, 0x79, + 0xcc, 0xd5, 0x58, 0x67, 0xda, 0xda, 0x91, 0x20, 0x2d, 0x62, 0xdd, 0x49, 0x09, 0xd5, 0xfe, 0xa8, + 0xe0, 0x47, 0xa8, 0x26, 0x99, 0x11, 0x0b, 0x41, 0xcf, 0x62, 0x49, 0x93, 0x54, 0x8e, 0xc4, 0xe9, + 0x45, 0x06, 0x7e, 0x80, 0xca, 0x99, 0x3f, 0x50, 0xee, 0xeb, 0x4e, 0x43, 0x27, 0x96, 0xf7, 0x77, + 0xb7, 0xa9, 0xc4, 0x71, 0x17, 0x2d, 0x78, 0x3c, 0xce, 0x12, 0xb9, 0x56, 0xf9, 0x6b, 0x23, 0xb9, + 0x8c, 0x97, 0x0a, 0xa1, 0x3a, 0x82, 0x03, 0x54, 0x05, 0x79, 0x0b, 0xcd, 0x4a, 0xa7, 0xbc, 0xdc, + 0x58, 0x7d, 0x71, 0x8b, 0x11, 0x10, 0x75, 0x54, 0x3b, 0x91, 0xe0, 0xc7, 0x33, 0xad, 0x4a, 0x8c, + 0x16, 0x35, 0x5a, 0x47, 0xfa, 0xf0, 0x54, 0x0e, 0x5e, 0x42, 0xe5, 0x00, 0x8e, 0x8b, 0x36, 0xa9, + 0xfc, 0xc4, 0x7b, 0xa8, 0x3a, 0x92, 0x37, 0xa9, 0xf7, 0xf1, 0xfc, 0x06, 0x66, 0xa6, 0x87, 0x4d, + 0x0b, 0xad, 0x8d, 0xd2, 0xba, 0xe9, 0xac, 0x9c, 0x4e, 0x2c, 0xe3, 0x6c, 0x62, 0x19, 0xe7, 0x13, + 0xcb, 0x38, 0xc9, 0x2d, 0xf3, 0x34, 0xb7, 0xcc, 0xb3, 0xdc, 0x32, 0xcf, 0x73, 0xcb, 0xfc, 0x99, + 0x5b, 0xe6, 0xe7, 0x5f, 0x96, 0xf1, 0xee, 0x3f, 0x2d, 0xf2, 0x3b, 0x00, 0x00, 0xff, 0xff, 0x35, + 0x3c, 0x74, 0xb0, 0x9a, 0x05, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto index f36e28161b..316a62e8e5 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.authentication.v1beta1; +package k8s.io.client_go.pkg.apis.authentication.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; -import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; @@ -44,7 +43,7 @@ message ExtraValue { // plugin in the kube-apiserver. message TokenReview { // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec holds information about the request being evaluated optional TokenReviewSpec spec = 2; diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/register.go index 472e53d1ea..d3ae1e4bc9 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/register.go @@ -17,30 +17,42 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "authentication.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1beta1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, - &TokenReview{}, ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.generated.go index 32f15d31bf..b8990af180 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.generated.go @@ -25,9 +25,8 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" "reflect" "runtime" time "time" @@ -63,11 +62,10 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg1_unversioned.TypeMeta - var v1 pkg2_v1.ObjectMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 } } @@ -159,7 +157,13 @@ func (x *TokenReview) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[2] { yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } @@ -168,26 +172,32 @@ func (x *TokenReview) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } @@ -196,8 +206,8 @@ func (x *TokenReview) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } if yyr2 || yy2arr2 { @@ -213,25 +223,25 @@ func (x *TokenReview) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl19, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl19, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -243,12 +253,12 @@ func (x *TokenReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -257,47 +267,65 @@ func (x *TokenReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = TokenReviewSpec{} } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = TokenReviewStatus{} } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -305,16 +333,16 @@ func (x *TokenReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -322,15 +350,21 @@ func (x *TokenReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -338,32 +372,44 @@ func (x *TokenReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -371,16 +417,16 @@ func (x *TokenReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = TokenReviewSpec{} } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -388,21 +434,21 @@ func (x *TokenReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = TokenReviewStatus{} } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -414,35 +460,35 @@ func (x *TokenReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym32 := z.EncBinary() - _ = yym32 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [1]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Token != "" - var yynn33 int - if yyr33 || yy2arr33 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Token != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn33 = 0 - for _, b := range yyq33 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn33++ + yynn2++ } } - r.EncodeMapStart(yynn33) - yynn33 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Token)) @@ -451,19 +497,19 @@ func (x *TokenReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("token")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Token)) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -476,25 +522,25 @@ func (x *TokenReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym37 := z.DecBinary() - _ = yym37 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct38 := r.ContainerType() - if yyct38 == codecSelferValueTypeMap1234 { - yyl38 := r.ReadMapStart() - if yyl38 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl38, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct38 == codecSelferValueTypeArray1234 { - yyl38 := r.ReadArrayStart() - if yyl38 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl38, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -506,12 +552,12 @@ func (x *TokenReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys39Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys39Slc - var yyhl39 bool = l >= 0 - for yyj39 := 0; ; yyj39++ { - if yyhl39 { - if yyj39 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -520,20 +566,26 @@ func (x *TokenReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys39Slc = r.DecodeBytes(yys39Slc, true, true) - yys39 := string(yys39Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys39 { + switch yys3 { case "token": if r.TryDecodeAsNil() { x.Token = "" } else { - x.Token = string(r.DecodeString()) + yyv4 := &x.Token + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys39) - } // end switch yys39 - } // end for yyj39 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -541,16 +593,16 @@ func (x *TokenReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj41 int - var yyb41 bool - var yyhl41 bool = l >= 0 - yyj41++ - if yyhl41 { - yyb41 = yyj41 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb41 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb41 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -558,20 +610,26 @@ func (x *TokenReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Token = "" } else { - x.Token = string(r.DecodeString()) + yyv7 := &x.Token + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } for { - yyj41++ - if yyhl41 { - yyb41 = yyj41 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb41 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb41 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj41-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -583,37 +641,37 @@ func (x *TokenReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym43 := z.EncBinary() - _ = yym43 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep44 := !z.EncBinary() - yy2arr44 := z.EncBasicHandle().StructToArray - var yyq44 [3]bool - _, _, _ = yysep44, yyq44, yy2arr44 - const yyr44 bool = false - yyq44[0] = x.Authenticated != false - yyq44[1] = true - yyq44[2] = x.Error != "" - var yynn44 int - if yyr44 || yy2arr44 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Authenticated != false + yyq2[1] = true + yyq2[2] = x.Error != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn44 = 0 - for _, b := range yyq44 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn44++ + yynn2++ } } - r.EncodeMapStart(yynn44) - yynn44 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr44 || yy2arr44 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq44[0] { - yym46 := z.EncBinary() - _ = yym46 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeBool(bool(x.Authenticated)) @@ -622,40 +680,40 @@ func (x *TokenReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq44[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("authenticated")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym47 := z.EncBinary() - _ = yym47 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeBool(bool(x.Authenticated)) } } } - if yyr44 || yy2arr44 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq44[1] { - yy49 := &x.User - yy49.CodecEncodeSelf(e) + if yyq2[1] { + yy7 := &x.User + yy7.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq44[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("user")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy50 := &x.User - yy50.CodecEncodeSelf(e) + yy9 := &x.User + yy9.CodecEncodeSelf(e) } } - if yyr44 || yy2arr44 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq44[2] { - yym52 := z.EncBinary() - _ = yym52 + if yyq2[2] { + yym12 := z.EncBinary() + _ = yym12 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Error)) @@ -664,19 +722,19 @@ func (x *TokenReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq44[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("error")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym53 := z.EncBinary() - _ = yym53 + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Error)) } } } - if yyr44 || yy2arr44 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -689,25 +747,25 @@ func (x *TokenReviewStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym54 := z.DecBinary() - _ = yym54 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct55 := r.ContainerType() - if yyct55 == codecSelferValueTypeMap1234 { - yyl55 := r.ReadMapStart() - if yyl55 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl55, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct55 == codecSelferValueTypeArray1234 { - yyl55 := r.ReadArrayStart() - if yyl55 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl55, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -719,12 +777,12 @@ func (x *TokenReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys56Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys56Slc - var yyhl56 bool = l >= 0 - for yyj56 := 0; ; yyj56++ { - if yyhl56 { - if yyj56 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -733,33 +791,45 @@ func (x *TokenReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys56Slc = r.DecodeBytes(yys56Slc, true, true) - yys56 := string(yys56Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys56 { + switch yys3 { case "authenticated": if r.TryDecodeAsNil() { x.Authenticated = false } else { - x.Authenticated = bool(r.DecodeBool()) + yyv4 := &x.Authenticated + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } } case "user": if r.TryDecodeAsNil() { x.User = UserInfo{} } else { - yyv58 := &x.User - yyv58.CodecDecodeSelf(d) + yyv6 := &x.User + yyv6.CodecDecodeSelf(d) } case "error": if r.TryDecodeAsNil() { x.Error = "" } else { - x.Error = string(r.DecodeString()) + yyv7 := &x.Error + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys56) - } // end switch yys56 - } // end for yyj56 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -767,16 +837,16 @@ func (x *TokenReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj60 int - var yyb60 bool - var yyhl60 bool = l >= 0 - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb60 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb60 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -784,15 +854,21 @@ func (x *TokenReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Authenticated = false } else { - x.Authenticated = bool(r.DecodeBool()) + yyv10 := &x.Authenticated + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*bool)(yyv10)) = r.DecodeBool() + } } - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb60 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb60 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -800,16 +876,16 @@ func (x *TokenReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.User = UserInfo{} } else { - yyv62 := &x.User - yyv62.CodecDecodeSelf(d) + yyv12 := &x.User + yyv12.CodecDecodeSelf(d) } - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb60 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb60 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -817,20 +893,26 @@ func (x *TokenReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Error = "" } else { - x.Error = string(r.DecodeString()) + yyv13 := &x.Error + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } for { - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb60 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb60 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj60-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -842,38 +924,38 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym64 := z.EncBinary() - _ = yym64 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep65 := !z.EncBinary() - yy2arr65 := z.EncBasicHandle().StructToArray - var yyq65 [4]bool - _, _, _ = yysep65, yyq65, yy2arr65 - const yyr65 bool = false - yyq65[0] = x.Username != "" - yyq65[1] = x.UID != "" - yyq65[2] = len(x.Groups) != 0 - yyq65[3] = len(x.Extra) != 0 - var yynn65 int - if yyr65 || yy2arr65 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Username != "" + yyq2[1] = x.UID != "" + yyq2[2] = len(x.Groups) != 0 + yyq2[3] = len(x.Extra) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn65 = 0 - for _, b := range yyq65 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn65++ + yynn2++ } } - r.EncodeMapStart(yynn65) - yynn65 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[0] { - yym67 := z.EncBinary() - _ = yym67 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Username)) @@ -882,23 +964,23 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq65[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("username")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Username)) } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[1] { - yym70 := z.EncBinary() - _ = yym70 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.UID)) @@ -907,26 +989,26 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq65[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("uid")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym71 := z.EncBinary() - _ = yym71 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.UID)) } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[2] { + if yyq2[2] { if x.Groups == nil { r.EncodeNil() } else { - yym73 := z.EncBinary() - _ = yym73 + yym10 := z.EncBinary() + _ = yym10 if false { } else { z.F.EncSliceStringV(x.Groups, false, e) @@ -936,15 +1018,15 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq65[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("groups")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Groups == nil { r.EncodeNil() } else { - yym74 := z.EncBinary() - _ = yym74 + yym11 := z.EncBinary() + _ = yym11 if false { } else { z.F.EncSliceStringV(x.Groups, false, e) @@ -952,14 +1034,14 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[3] { + if yyq2[3] { if x.Extra == nil { r.EncodeNil() } else { - yym76 := z.EncBinary() - _ = yym76 + yym13 := z.EncBinary() + _ = yym13 if false { } else { h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) @@ -969,15 +1051,15 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq65[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("extra")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Extra == nil { r.EncodeNil() } else { - yym77 := z.EncBinary() - _ = yym77 + yym14 := z.EncBinary() + _ = yym14 if false { } else { h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) @@ -985,7 +1067,7 @@ func (x *UserInfo) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -998,25 +1080,25 @@ func (x *UserInfo) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym78 := z.DecBinary() - _ = yym78 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct79 := r.ContainerType() - if yyct79 == codecSelferValueTypeMap1234 { - yyl79 := r.ReadMapStart() - if yyl79 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl79, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct79 == codecSelferValueTypeArray1234 { - yyl79 := r.ReadArrayStart() - if yyl79 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl79, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1028,12 +1110,12 @@ func (x *UserInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys80Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys80Slc - var yyhl80 bool = l >= 0 - for yyj80 := 0; ; yyj80++ { - if yyhl80 { - if yyj80 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1042,50 +1124,62 @@ func (x *UserInfo) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys80Slc = r.DecodeBytes(yys80Slc, true, true) - yys80 := string(yys80Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys80 { + switch yys3 { case "username": if r.TryDecodeAsNil() { x.Username = "" } else { - x.Username = string(r.DecodeString()) + yyv4 := &x.Username + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "uid": if r.TryDecodeAsNil() { x.UID = "" } else { - x.UID = string(r.DecodeString()) + yyv6 := &x.UID + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "groups": if r.TryDecodeAsNil() { x.Groups = nil } else { - yyv83 := &x.Groups - yym84 := z.DecBinary() - _ = yym84 + yyv8 := &x.Groups + yym9 := z.DecBinary() + _ = yym9 if false { } else { - z.F.DecSliceStringX(yyv83, false, d) + z.F.DecSliceStringX(yyv8, false, d) } } case "extra": if r.TryDecodeAsNil() { x.Extra = nil } else { - yyv85 := &x.Extra - yym86 := z.DecBinary() - _ = yym86 + yyv10 := &x.Extra + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv85), d) + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys80) - } // end switch yys80 - } // end for yyj80 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1093,16 +1187,16 @@ func (x *UserInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj87 int - var yyb87 bool - var yyhl87 bool = l >= 0 - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb87 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb87 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1110,15 +1204,21 @@ func (x *UserInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Username = "" } else { - x.Username = string(r.DecodeString()) + yyv13 := &x.Username + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb87 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb87 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1126,15 +1226,21 @@ func (x *UserInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.UID = "" } else { - x.UID = string(r.DecodeString()) + yyv15 := &x.UID + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb87 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb87 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1142,21 +1248,21 @@ func (x *UserInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Groups = nil } else { - yyv90 := &x.Groups - yym91 := z.DecBinary() - _ = yym91 + yyv17 := &x.Groups + yym18 := z.DecBinary() + _ = yym18 if false { } else { - z.F.DecSliceStringX(yyv90, false, d) + z.F.DecSliceStringX(yyv17, false, d) } } - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb87 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb87 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1164,26 +1270,26 @@ func (x *UserInfo) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Extra = nil } else { - yyv92 := &x.Extra - yym93 := z.DecBinary() - _ = yym93 + yyv19 := &x.Extra + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv92), d) + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv19), d) } } for { - yyj87++ - if yyhl87 { - yyb87 = yyj87 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb87 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb87 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj87-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1195,8 +1301,8 @@ func (x ExtraValue) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym94 := z.EncBinary() - _ = yym94 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -1209,8 +1315,8 @@ func (x *ExtraValue) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym95 := z.DecBinary() - _ = yym95 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -1223,19 +1329,19 @@ func (x codecSelfer1234) encMapstringExtraValue(v map[string]ExtraValue, e *code z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeMapStart(len(v)) - for yyk96, yyv96 := range v { + for yyk1, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym97 := z.EncBinary() - _ = yym97 + yym2 := z.EncBinary() + _ = yym2 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk96)) + r.EncodeString(codecSelferC_UTF81234, string(yyk1)) } z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv96 == nil { + if yyv1 == nil { r.EncodeNil() } else { - yyv96.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } } z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1246,70 +1352,82 @@ func (x codecSelfer1234) decMapstringExtraValue(v *map[string]ExtraValue, d *cod z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv98 := *v - yyl98 := r.ReadMapStart() - yybh98 := z.DecBasicHandle() - if yyv98 == nil { - yyrl98, _ := z.DecInferLen(yyl98, yybh98.MaxInitLen, 40) - yyv98 = make(map[string]ExtraValue, yyrl98) - *v = yyv98 + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string]ExtraValue, yyrl1) + *v = yyv1 } - var yymk98 string - var yymv98 ExtraValue - var yymg98 bool - if yybh98.MapValueReset { - yymg98 = true + var yymk1 string + var yymv1 ExtraValue + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true } - if yyl98 > 0 { - for yyj98 := 0; yyj98 < yyl98; yyj98++ { + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk98 = "" + yymk1 = "" } else { - yymk98 = string(r.DecodeString()) + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } } - if yymg98 { - yymv98 = yyv98[yymk98] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv98 = nil + yymv1 = nil } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv98 = nil + yymv1 = nil } else { - yyv100 := &yymv98 - yyv100.CodecDecodeSelf(d) + yyv4 := &yymv1 + yyv4.CodecDecodeSelf(d) } - if yyv98 != nil { - yyv98[yymk98] = yymv98 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } - } else if yyl98 < 0 { - for yyj98 := 0; !r.CheckBreak(); yyj98++ { + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk98 = "" + yymk1 = "" } else { - yymk98 = string(r.DecodeString()) + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } } - if yymg98 { - yymv98 = yyv98[yymk98] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv98 = nil + yymv1 = nil } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv98 = nil + yymv1 = nil } else { - yyv102 := &yymv98 - yyv102.CodecDecodeSelf(d) + yyv7 := &yymv1 + yyv7.CodecDecodeSelf(d) } - if yyv98 != nil { - yyv98[yymk98] = yymv98 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } } // else len==0: TODO: Should we clear map entries? @@ -1321,13 +1439,13 @@ func (x codecSelfer1234) encExtraValue(v ExtraValue, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv103 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym104 := z.EncBinary() - _ = yym104 + yym2 := z.EncBinary() + _ = yym2 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yyv103)) + r.EncodeString(codecSelferC_UTF81234, string(yyv1)) } } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) @@ -1338,75 +1456,96 @@ func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv105 := *v - yyh105, yyl105 := z.DecSliceHelperStart() - var yyc105 bool - if yyl105 == 0 { - if yyv105 == nil { - yyv105 = []string{} - yyc105 = true - } else if len(yyv105) != 0 { - yyv105 = yyv105[:0] - yyc105 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl105 > 0 { - var yyrr105, yyrl105 int - var yyrt105 bool - if yyl105 > cap(yyv105) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl105, yyrt105 = z.DecInferLen(yyl105, z.DecBasicHandle().MaxInitLen, 16) - if yyrt105 { - if yyrl105 <= cap(yyv105) { - yyv105 = yyv105[:yyrl105] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv105 = make([]string, yyrl105) + yyv1 = make([]string, yyrl1) } } else { - yyv105 = make([]string, yyrl105) + yyv1 = make([]string, yyrl1) } - yyc105 = true - yyrr105 = len(yyv105) - } else if yyl105 != len(yyv105) { - yyv105 = yyv105[:yyl105] - yyc105 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj105 := 0 - for ; yyj105 < yyrr105; yyj105++ { - yyh105.ElemContainerState(yyj105) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv105[yyj105] = "" + yyv1[yyj1] = "" } else { - yyv105[yyj105] = string(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } } } - if yyrt105 { - for ; yyj105 < yyl105; yyj105++ { - yyv105 = append(yyv105, "") - yyh105.ElemContainerState(yyj105) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv105[yyj105] = "" + yyv1[yyj1] = "" } else { - yyv105[yyj105] = string(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } } } } else { - yyj105 := 0 - for ; !r.CheckBreak(); yyj105++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj105 >= len(yyv105) { - yyv105 = append(yyv105, "") // var yyz105 string - yyc105 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 string + yyc1 = true } - yyh105.ElemContainerState(yyj105) - if yyj105 < len(yyv105) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv105[yyj105] = "" + yyv1[yyj1] = "" } else { - yyv105[yyj105] = string(r.DecodeString()) + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } } else { @@ -1414,16 +1553,16 @@ func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { } } - if yyj105 < len(yyv105) { - yyv105 = yyv105[:yyj105] - yyc105 = true - } else if yyj105 == 0 && yyv105 == nil { - yyv105 = []string{} - yyc105 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []string{} + yyc1 = true } } - yyh105.End() - if yyc105 { - *v = yyv105 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.go index 0338902064..57c96e3bc4 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/types.go @@ -19,8 +19,7 @@ package v1beta1 import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // +genclient=true @@ -31,9 +30,9 @@ import ( // Note: TokenReview requests may be cached by the webhook token authenticator // plugin in the kube-apiserver. type TokenReview struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec holds information about the request being evaluated Spec TokenReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.conversion.go index 8e5a1d2011..39a61ae613 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1beta1 import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" authentication "k8s.io/client-go/pkg/apis/authentication" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -47,10 +47,7 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v1beta1_TokenReview_To_authentication_TokenReview(in *TokenReview, out *authentication.TokenReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_TokenReviewSpec_To_authentication_TokenReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -60,15 +57,13 @@ func autoConvert_v1beta1_TokenReview_To_authentication_TokenReview(in *TokenRevi return nil } +// Convert_v1beta1_TokenReview_To_authentication_TokenReview is an autogenerated conversion function. func Convert_v1beta1_TokenReview_To_authentication_TokenReview(in *TokenReview, out *authentication.TokenReview, s conversion.Scope) error { return autoConvert_v1beta1_TokenReview_To_authentication_TokenReview(in, out, s) } func autoConvert_authentication_TokenReview_To_v1beta1_TokenReview(in *authentication.TokenReview, out *TokenReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_authentication_TokenReviewSpec_To_v1beta1_TokenReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -78,6 +73,7 @@ func autoConvert_authentication_TokenReview_To_v1beta1_TokenReview(in *authentic return nil } +// Convert_authentication_TokenReview_To_v1beta1_TokenReview is an autogenerated conversion function. func Convert_authentication_TokenReview_To_v1beta1_TokenReview(in *authentication.TokenReview, out *TokenReview, s conversion.Scope) error { return autoConvert_authentication_TokenReview_To_v1beta1_TokenReview(in, out, s) } @@ -87,6 +83,7 @@ func autoConvert_v1beta1_TokenReviewSpec_To_authentication_TokenReviewSpec(in *T return nil } +// Convert_v1beta1_TokenReviewSpec_To_authentication_TokenReviewSpec is an autogenerated conversion function. func Convert_v1beta1_TokenReviewSpec_To_authentication_TokenReviewSpec(in *TokenReviewSpec, out *authentication.TokenReviewSpec, s conversion.Scope) error { return autoConvert_v1beta1_TokenReviewSpec_To_authentication_TokenReviewSpec(in, out, s) } @@ -96,6 +93,7 @@ func autoConvert_authentication_TokenReviewSpec_To_v1beta1_TokenReviewSpec(in *a return nil } +// Convert_authentication_TokenReviewSpec_To_v1beta1_TokenReviewSpec is an autogenerated conversion function. func Convert_authentication_TokenReviewSpec_To_v1beta1_TokenReviewSpec(in *authentication.TokenReviewSpec, out *TokenReviewSpec, s conversion.Scope) error { return autoConvert_authentication_TokenReviewSpec_To_v1beta1_TokenReviewSpec(in, out, s) } @@ -109,6 +107,7 @@ func autoConvert_v1beta1_TokenReviewStatus_To_authentication_TokenReviewStatus(i return nil } +// Convert_v1beta1_TokenReviewStatus_To_authentication_TokenReviewStatus is an autogenerated conversion function. func Convert_v1beta1_TokenReviewStatus_To_authentication_TokenReviewStatus(in *TokenReviewStatus, out *authentication.TokenReviewStatus, s conversion.Scope) error { return autoConvert_v1beta1_TokenReviewStatus_To_authentication_TokenReviewStatus(in, out, s) } @@ -122,6 +121,7 @@ func autoConvert_authentication_TokenReviewStatus_To_v1beta1_TokenReviewStatus(i return nil } +// Convert_authentication_TokenReviewStatus_To_v1beta1_TokenReviewStatus is an autogenerated conversion function. func Convert_authentication_TokenReviewStatus_To_v1beta1_TokenReviewStatus(in *authentication.TokenReviewStatus, out *TokenReviewStatus, s conversion.Scope) error { return autoConvert_authentication_TokenReviewStatus_To_v1beta1_TokenReviewStatus(in, out, s) } @@ -134,6 +134,7 @@ func autoConvert_v1beta1_UserInfo_To_authentication_UserInfo(in *UserInfo, out * return nil } +// Convert_v1beta1_UserInfo_To_authentication_UserInfo is an autogenerated conversion function. func Convert_v1beta1_UserInfo_To_authentication_UserInfo(in *UserInfo, out *authentication.UserInfo, s conversion.Scope) error { return autoConvert_v1beta1_UserInfo_To_authentication_UserInfo(in, out, s) } @@ -146,6 +147,7 @@ func autoConvert_authentication_UserInfo_To_v1beta1_UserInfo(in *authentication. return nil } +// Convert_authentication_UserInfo_To_v1beta1_UserInfo is an autogenerated conversion function. func Convert_authentication_UserInfo_To_v1beta1_UserInfo(in *authentication.UserInfo, out *UserInfo, s conversion.Scope) error { return autoConvert_authentication_UserInfo_To_v1beta1_UserInfo(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.deepcopy.go index 2d461d2603..0615678b43 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1beta1 import ( - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -42,15 +42,17 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_TokenReview is an autogenerated deepcopy function. func DeepCopy_v1beta1_TokenReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TokenReview) out := out.(*TokenReview) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Spec = in.Spec if err := DeepCopy_v1beta1_TokenReviewStatus(&in.Status, &out.Status, c); err != nil { return err } @@ -58,40 +60,39 @@ func DeepCopy_v1beta1_TokenReview(in interface{}, out interface{}, c *conversion } } +// DeepCopy_v1beta1_TokenReviewSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_TokenReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TokenReviewSpec) out := out.(*TokenReviewSpec) - out.Token = in.Token + *out = *in return nil } } +// DeepCopy_v1beta1_TokenReviewStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_TokenReviewStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TokenReviewStatus) out := out.(*TokenReviewStatus) - out.Authenticated = in.Authenticated + *out = *in if err := DeepCopy_v1beta1_UserInfo(&in.User, &out.User, c); err != nil { return err } - out.Error = in.Error return nil } } +// DeepCopy_v1beta1_UserInfo is an autogenerated deepcopy function. func DeepCopy_v1beta1_UserInfo(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*UserInfo) out := out.(*UserInfo) - out.Username = in.Username - out.UID = in.UID + *out = *in if in.Groups != nil { in, out := &in.Groups, &out.Groups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Groups = nil } if in.Extra != nil { in, out := &in.Extra, &out.Extra @@ -103,8 +104,6 @@ func DeepCopy_v1beta1_UserInfo(in interface{}, out interface{}, c *conversion.Cl (*out)[key] = *newVal.(*ExtraValue) } } - } else { - out.Extra = nil } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.defaults.go new file mode 100644 index 0000000000..e24e70be38 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/v1beta1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1beta1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authentication/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/authentication/zz_generated.deepcopy.go index b86631cacf..f3b47e8402 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authentication/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/authentication/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package authentication import ( - api "k8s.io/client-go/pkg/api" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -42,15 +42,17 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_authentication_TokenReview is an autogenerated deepcopy function. func DeepCopy_authentication_TokenReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TokenReview) out := out.(*TokenReview) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Spec = in.Spec if err := DeepCopy_authentication_TokenReviewStatus(&in.Status, &out.Status, c); err != nil { return err } @@ -58,40 +60,39 @@ func DeepCopy_authentication_TokenReview(in interface{}, out interface{}, c *con } } +// DeepCopy_authentication_TokenReviewSpec is an autogenerated deepcopy function. func DeepCopy_authentication_TokenReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TokenReviewSpec) out := out.(*TokenReviewSpec) - out.Token = in.Token + *out = *in return nil } } +// DeepCopy_authentication_TokenReviewStatus is an autogenerated deepcopy function. func DeepCopy_authentication_TokenReviewStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*TokenReviewStatus) out := out.(*TokenReviewStatus) - out.Authenticated = in.Authenticated + *out = *in if err := DeepCopy_authentication_UserInfo(&in.User, &out.User, c); err != nil { return err } - out.Error = in.Error return nil } } +// DeepCopy_authentication_UserInfo is an autogenerated deepcopy function. func DeepCopy_authentication_UserInfo(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*UserInfo) out := out.(*UserInfo) - out.Username = in.Username - out.UID = in.UID + *out = *in if in.Groups != nil { in, out := &in.Groups, &out.Groups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Groups = nil } if in.Extra != nil { in, out := &in.Extra, &out.Extra @@ -103,8 +104,6 @@ func DeepCopy_authentication_UserInfo(in interface{}, out interface{}, c *conver (*out)[key] = *newVal.(*ExtraValue) } } - } else { - out.Extra = nil } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/BUILD b/vendor/k8s.io/client-go/pkg/apis/authorization/BUILD new file mode 100644 index 0000000000..6e2604388a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/OWNERS b/vendor/k8s.io/client-go/pkg/apis/authorization/OWNERS new file mode 100755 index 0000000000..2fef50443b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/OWNERS @@ -0,0 +1,17 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- liggitt +- nikhiljindal +- erictune +- sttts +- ncdc +- timothysc +- dims +- mml +- mbohlool +- david-mcmahon +- jianhuiz diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/doc.go b/vendor/k8s.io/client-go/pkg/apis/authorization/doc.go index 4e2deb516e..91344f6746 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/doc.go @@ -14,8 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - // +groupName=authorization.k8s.io package authorization diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/install/install.go b/vendor/k8s.io/client-go/pkg/apis/authorization/install/install.go deleted file mode 100644 index b758df5720..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the experimental API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/authorization" - "k8s.io/client-go/pkg/apis/authorization/v1beta1" - "k8s.io/client-go/pkg/util/sets" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: authorization.GroupName, - VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/authorization", - RootScopedKinds: sets.NewString("SubjectAccessReview", "SelfSubjectAccessReview"), - AddInternalObjectsToScheme: authorization.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/register.go b/vendor/k8s.io/client-go/pkg/apis/authorization/register.go index 55ae357d32..5693885e4e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/register.go @@ -17,23 +17,23 @@ limitations under the License. package authorization import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "authorization.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/authorization/types.generated.go deleted file mode 100644 index 49bd9cfecb..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/types.generated.go +++ /dev/null @@ -1,5607 +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 authorization - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - "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 pkg2_api.ObjectMeta - var v1 pkg1_unversioned.TypeMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 - } -} - -func (x *SubjectAccessReview) 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 [19]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = x.Name != "" - yyq2[3] = x.GenerateName != "" - yyq2[4] = x.Namespace != "" - yyq2[5] = x.SelfLink != "" - yyq2[6] = x.UID != "" - yyq2[7] = x.ResourceVersion != "" - yyq2[8] = x.Generation != 0 - yyq2[9] = true - yyq2[10] = x.ObjectMeta.DeletionTimestamp != nil && x.DeletionTimestamp != nil - yyq2[11] = x.ObjectMeta.DeletionGracePeriodSeconds != nil && x.DeletionGracePeriodSeconds != nil - yyq2[12] = len(x.Labels) != 0 - yyq2[13] = len(x.Annotations) != 0 - yyq2[14] = len(x.OwnerReferences) != 0 - yyq2[15] = len(x.Finalizers) != 0 - yyq2[16] = x.ClusterName != "" - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(19) - } else { - yynn2 = 2 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym11 := z.EncBinary() - _ = yym11 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generateName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[5] { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selfLink")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym20 := z.EncBinary() - _ = yym20 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[6] { - yym22 := z.EncBinary() - _ = yym22 - 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[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym23 := z.EncBinary() - _ = yym23 - 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[7] { - yym25 := z.EncBinary() - _ = yym25 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[8] { - yym28 := z.EncBinary() - _ = yym28 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generation")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[9] { - yy31 := &x.CreationTimestamp - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(yy31) { - } else if yym32 { - z.EncBinaryMarshal(yy31) - } else if !yym32 && z.IsJSONHandle() { - z.EncJSONMarshal(yy31) - } else { - z.EncFallback(yy31) - } - } else { - r.EncodeNil() - } - } else { - if yyq2[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("creationTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy33 := &x.CreationTimestamp - yym34 := z.EncBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.EncExt(yy33) { - } else if yym34 { - z.EncBinaryMarshal(yy33) - } else if !yym34 && z.IsJSONHandle() { - z.EncJSONMarshal(yy33) - } else { - z.EncFallback(yy33) - } - } - } - var yyn35 bool - if x.ObjectMeta.DeletionTimestamp == nil { - yyn35 = true - goto LABEL35 - } - LABEL35: - if yyr2 || yy2arr2 { - if yyn35 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[10] { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym36 := z.EncBinary() - _ = yym36 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym36 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym36 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq2[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn35 { - r.EncodeNil() - } else { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym37 := z.EncBinary() - _ = yym37 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym37 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym37 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } - } - } - var yyn38 bool - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - yyn38 = true - goto LABEL38 - } - LABEL38: - if yyr2 || yy2arr2 { - if yyn38 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[11] { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy39 := *x.DeletionGracePeriodSeconds - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeInt(int64(yy39)) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq2[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionGracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn38 { - r.EncodeNil() - } else { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy41 := *x.DeletionGracePeriodSeconds - yym42 := z.EncBinary() - _ = yym42 - if false { - } else { - r.EncodeInt(int64(yy41)) - } - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[12] { - if x.Labels == nil { - r.EncodeNil() - } else { - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labels")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Labels == nil { - r.EncodeNil() - } else { - yym45 := z.EncBinary() - _ = yym45 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[13] { - if x.Annotations == nil { - r.EncodeNil() - } else { - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("annotations")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Annotations == nil { - r.EncodeNil() - } else { - yym48 := z.EncBinary() - _ = yym48 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[14] { - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ownerReferences")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym51 := z.EncBinary() - _ = yym51 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[15] { - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym53 := z.EncBinary() - _ = yym53 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finalizers")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym54 := z.EncBinary() - _ = yym54 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[16] { - yym56 := z.EncBinary() - _ = yym56 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym57 := z.EncBinary() - _ = yym57 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy59 := &x.Spec - yy59.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy60 := &x.Spec - yy60.CodecEncodeSelf(e) - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy62 := &x.Status - yy62.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy63 := &x.Status - yy63.CodecEncodeSelf(e) - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym64 := z.DecBinary() - _ = yym64 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct65 := r.ContainerType() - if yyct65 == codecSelferValueTypeMap1234 { - yyl65 := r.ReadMapStart() - if yyl65 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl65, d) - } - } else if yyct65 == codecSelferValueTypeArray1234 { - yyl65 := r.ReadArrayStart() - if yyl65 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl65, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys66Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys66Slc - var yyhl66 bool = l >= 0 - for yyj66 := 0; ; yyj66++ { - if yyhl66 { - if yyj66 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys66Slc = r.DecodeBytes(yys66Slc, true, true) - yys66 := string(yys66Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys66 { - 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 "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 = pkg3_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 = pkg1_unversioned.Time{} - } else { - yyv76 := &x.CreationTimestamp - yym77 := z.DecBinary() - _ = yym77 - if false { - } else if z.HasExtensions() && z.DecExt(yyv76) { - } else if yym77 { - z.DecBinaryUnmarshal(yyv76) - } else if !yym77 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv76) - } else { - z.DecFallback(yyv76, false) - } - } - case "deletionTimestamp": - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - if r.TryDecodeAsNil() { - if x.DeletionTimestamp != nil { - x.DeletionTimestamp = nil - } - } else { - if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yym79 := z.DecBinary() - _ = yym79 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym79 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym79 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - case "deletionGracePeriodSeconds": - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - if r.TryDecodeAsNil() { - if x.DeletionGracePeriodSeconds != nil { - x.DeletionGracePeriodSeconds = nil - } - } else { - if x.DeletionGracePeriodSeconds == nil { - x.DeletionGracePeriodSeconds = new(int64) - } - yym81 := z.DecBinary() - _ = yym81 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - case "labels": - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv82 := &x.Labels - yym83 := z.DecBinary() - _ = yym83 - if false { - } else { - z.F.DecMapStringStringX(yyv82, false, d) - } - } - case "annotations": - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv84 := &x.Annotations - yym85 := z.DecBinary() - _ = yym85 - if false { - } else { - z.F.DecMapStringStringX(yyv84, false, d) - } - } - case "ownerReferences": - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv86 := &x.OwnerReferences - yym87 := z.DecBinary() - _ = yym87 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv86), d) - } - } - case "finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv88 := &x.Finalizers - yym89 := z.DecBinary() - _ = yym89 - if false { - } else { - z.F.DecSliceStringX(yyv88, false, d) - } - } - case "clusterName": - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - case "Spec": - if r.TryDecodeAsNil() { - x.Spec = SubjectAccessReviewSpec{} - } else { - yyv91 := &x.Spec - yyv91.CodecDecodeSelf(d) - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = SubjectAccessReviewStatus{} - } else { - yyv92 := &x.Status - yyv92.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys66) - } // end switch yys66 - } // end for yyj66 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj93 int - var yyb93 bool - var yyhl93 bool = l >= 0 - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.GenerateName = "" - } else { - x.GenerateName = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SelfLink = "" - } else { - x.SelfLink = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg3_types.UID(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Generation = 0 - } else { - x.Generation = int64(r.DecodeInt(64)) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg1_unversioned.Time{} - } else { - yyv103 := &x.CreationTimestamp - yym104 := z.DecBinary() - _ = yym104 - if false { - } else if z.HasExtensions() && z.DecExt(yyv103) { - } else if yym104 { - z.DecBinaryUnmarshal(yyv103) - } else if !yym104 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv103) - } else { - z.DecFallback(yyv103, false) - } - } - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - 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(pkg1_unversioned.Time) - } - yym106 := z.DecBinary() - _ = yym106 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym106 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym106 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - 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) - } - yym108 := z.DecBinary() - _ = yym108 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv109 := &x.Labels - yym110 := z.DecBinary() - _ = yym110 - if false { - } else { - z.F.DecMapStringStringX(yyv109, false, d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv111 := &x.Annotations - yym112 := z.DecBinary() - _ = yym112 - if false { - } else { - z.F.DecMapStringStringX(yyv111, false, d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv113 := &x.OwnerReferences - yym114 := z.DecBinary() - _ = yym114 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv113), d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv115 := &x.Finalizers - yym116 := z.DecBinary() - _ = yym116 - if false { - } else { - z.F.DecSliceStringX(yyv115, false, d) - } - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = SubjectAccessReviewSpec{} - } else { - yyv118 := &x.Spec - yyv118.CodecDecodeSelf(d) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = SubjectAccessReviewStatus{} - } else { - yyv119 := &x.Status - yyv119.CodecDecodeSelf(d) - } - for { - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj93-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *SelfSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym120 := z.EncBinary() - _ = yym120 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep121 := !z.EncBinary() - yy2arr121 := z.EncBasicHandle().StructToArray - var yyq121 [19]bool - _, _, _ = yysep121, yyq121, yy2arr121 - const yyr121 bool = false - yyq121[0] = x.Kind != "" - yyq121[1] = x.APIVersion != "" - yyq121[2] = x.Name != "" - yyq121[3] = x.GenerateName != "" - yyq121[4] = x.Namespace != "" - yyq121[5] = x.SelfLink != "" - yyq121[6] = x.UID != "" - yyq121[7] = x.ResourceVersion != "" - yyq121[8] = x.Generation != 0 - yyq121[9] = true - yyq121[10] = x.ObjectMeta.DeletionTimestamp != nil && x.DeletionTimestamp != nil - yyq121[11] = x.ObjectMeta.DeletionGracePeriodSeconds != nil && x.DeletionGracePeriodSeconds != nil - yyq121[12] = len(x.Labels) != 0 - yyq121[13] = len(x.Annotations) != 0 - yyq121[14] = len(x.OwnerReferences) != 0 - yyq121[15] = len(x.Finalizers) != 0 - yyq121[16] = x.ClusterName != "" - var yynn121 int - if yyr121 || yy2arr121 { - r.EncodeArrayStart(19) - } else { - yynn121 = 2 - for _, b := range yyq121 { - if b { - yynn121++ - } - } - r.EncodeMapStart(yynn121) - yynn121 = 0 - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[0] { - yym123 := z.EncBinary() - _ = yym123 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym124 := z.EncBinary() - _ = yym124 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[1] { - yym126 := z.EncBinary() - _ = yym126 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym127 := z.EncBinary() - _ = yym127 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[2] { - yym129 := z.EncBinary() - _ = yym129 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym130 := z.EncBinary() - _ = yym130 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[3] { - yym132 := z.EncBinary() - _ = yym132 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generateName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym133 := z.EncBinary() - _ = yym133 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[4] { - yym135 := z.EncBinary() - _ = yym135 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym136 := z.EncBinary() - _ = yym136 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[5] { - yym138 := z.EncBinary() - _ = yym138 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selfLink")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym139 := z.EncBinary() - _ = yym139 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[6] { - yym141 := z.EncBinary() - _ = yym141 - 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 yyq121[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym142 := z.EncBinary() - _ = yym142 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[7] { - yym144 := z.EncBinary() - _ = yym144 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym145 := z.EncBinary() - _ = yym145 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[8] { - yym147 := z.EncBinary() - _ = yym147 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq121[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generation")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym148 := z.EncBinary() - _ = yym148 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[9] { - yy150 := &x.CreationTimestamp - yym151 := z.EncBinary() - _ = yym151 - if false { - } else if z.HasExtensions() && z.EncExt(yy150) { - } else if yym151 { - z.EncBinaryMarshal(yy150) - } else if !yym151 && z.IsJSONHandle() { - z.EncJSONMarshal(yy150) - } else { - z.EncFallback(yy150) - } - } else { - r.EncodeNil() - } - } else { - if yyq121[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("creationTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy152 := &x.CreationTimestamp - yym153 := z.EncBinary() - _ = yym153 - if false { - } else if z.HasExtensions() && z.EncExt(yy152) { - } else if yym153 { - z.EncBinaryMarshal(yy152) - } else if !yym153 && z.IsJSONHandle() { - z.EncJSONMarshal(yy152) - } else { - z.EncFallback(yy152) - } - } - } - var yyn154 bool - if x.ObjectMeta.DeletionTimestamp == nil { - yyn154 = true - goto LABEL154 - } - LABEL154: - if yyr121 || yy2arr121 { - if yyn154 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[10] { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym155 := z.EncBinary() - _ = yym155 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym155 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym155 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq121[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn154 { - r.EncodeNil() - } else { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym156 := z.EncBinary() - _ = yym156 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym156 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym156 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } - } - } - var yyn157 bool - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - yyn157 = true - goto LABEL157 - } - LABEL157: - if yyr121 || yy2arr121 { - if yyn157 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[11] { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy158 := *x.DeletionGracePeriodSeconds - yym159 := z.EncBinary() - _ = yym159 - if false { - } else { - r.EncodeInt(int64(yy158)) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq121[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionGracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn157 { - r.EncodeNil() - } else { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy160 := *x.DeletionGracePeriodSeconds - yym161 := z.EncBinary() - _ = yym161 - if false { - } else { - r.EncodeInt(int64(yy160)) - } - } - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[12] { - if x.Labels == nil { - r.EncodeNil() - } else { - yym163 := z.EncBinary() - _ = yym163 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq121[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labels")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Labels == nil { - r.EncodeNil() - } else { - yym164 := z.EncBinary() - _ = yym164 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[13] { - if x.Annotations == nil { - r.EncodeNil() - } else { - yym166 := z.EncBinary() - _ = yym166 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq121[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("annotations")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Annotations == nil { - r.EncodeNil() - } else { - yym167 := z.EncBinary() - _ = yym167 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[14] { - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym169 := z.EncBinary() - _ = yym169 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq121[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ownerReferences")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym170 := z.EncBinary() - _ = yym170 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[15] { - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym172 := z.EncBinary() - _ = yym172 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq121[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finalizers")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym173 := z.EncBinary() - _ = yym173 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq121[16] { - yym175 := z.EncBinary() - _ = yym175 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq121[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym176 := z.EncBinary() - _ = yym176 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy178 := &x.Spec - yy178.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy179 := &x.Spec - yy179.CodecEncodeSelf(e) - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy181 := &x.Status - yy181.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy182 := &x.Status - yy182.CodecEncodeSelf(e) - } - if yyr121 || yy2arr121 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SelfSubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym183 := z.DecBinary() - _ = yym183 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct184 := r.ContainerType() - if yyct184 == codecSelferValueTypeMap1234 { - yyl184 := r.ReadMapStart() - if yyl184 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl184, d) - } - } else if yyct184 == codecSelferValueTypeArray1234 { - yyl184 := r.ReadArrayStart() - if yyl184 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl184, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SelfSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys185Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys185Slc - var yyhl185 bool = l >= 0 - for yyj185 := 0; ; yyj185++ { - if yyhl185 { - if yyj185 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys185Slc = r.DecodeBytes(yys185Slc, true, true) - yys185 := string(yys185Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys185 { - 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 "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 = pkg3_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 = pkg1_unversioned.Time{} - } else { - yyv195 := &x.CreationTimestamp - yym196 := z.DecBinary() - _ = yym196 - if false { - } else if z.HasExtensions() && z.DecExt(yyv195) { - } else if yym196 { - z.DecBinaryUnmarshal(yyv195) - } else if !yym196 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv195) - } else { - z.DecFallback(yyv195, false) - } - } - case "deletionTimestamp": - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - if r.TryDecodeAsNil() { - if x.DeletionTimestamp != nil { - x.DeletionTimestamp = nil - } - } else { - if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yym198 := z.DecBinary() - _ = yym198 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym198 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym198 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - case "deletionGracePeriodSeconds": - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - if r.TryDecodeAsNil() { - if x.DeletionGracePeriodSeconds != nil { - x.DeletionGracePeriodSeconds = nil - } - } else { - if x.DeletionGracePeriodSeconds == nil { - x.DeletionGracePeriodSeconds = new(int64) - } - yym200 := z.DecBinary() - _ = yym200 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - case "labels": - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv201 := &x.Labels - yym202 := z.DecBinary() - _ = yym202 - if false { - } else { - z.F.DecMapStringStringX(yyv201, false, d) - } - } - case "annotations": - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv203 := &x.Annotations - yym204 := z.DecBinary() - _ = yym204 - if false { - } else { - z.F.DecMapStringStringX(yyv203, false, d) - } - } - case "ownerReferences": - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv205 := &x.OwnerReferences - yym206 := z.DecBinary() - _ = yym206 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv205), d) - } - } - case "finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv207 := &x.Finalizers - yym208 := z.DecBinary() - _ = yym208 - if false { - } else { - z.F.DecSliceStringX(yyv207, false, d) - } - } - case "clusterName": - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - case "Spec": - if r.TryDecodeAsNil() { - x.Spec = SelfSubjectAccessReviewSpec{} - } else { - yyv210 := &x.Spec - yyv210.CodecDecodeSelf(d) - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = SubjectAccessReviewStatus{} - } else { - yyv211 := &x.Status - yyv211.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys185) - } // end switch yys185 - } // end for yyj185 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj212 int - var yyb212 bool - var yyhl212 bool = l >= 0 - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.GenerateName = "" - } else { - x.GenerateName = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SelfLink = "" - } else { - x.SelfLink = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg3_types.UID(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Generation = 0 - } else { - x.Generation = int64(r.DecodeInt(64)) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg1_unversioned.Time{} - } else { - yyv222 := &x.CreationTimestamp - yym223 := z.DecBinary() - _ = yym223 - if false { - } else if z.HasExtensions() && z.DecExt(yyv222) { - } else if yym223 { - z.DecBinaryUnmarshal(yyv222) - } else if !yym223 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv222) - } else { - z.DecFallback(yyv222, false) - } - } - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - 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(pkg1_unversioned.Time) - } - yym225 := z.DecBinary() - _ = yym225 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym225 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym225 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - 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) - } - yym227 := z.DecBinary() - _ = yym227 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv228 := &x.Labels - yym229 := z.DecBinary() - _ = yym229 - if false { - } else { - z.F.DecMapStringStringX(yyv228, false, d) - } - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv230 := &x.Annotations - yym231 := z.DecBinary() - _ = yym231 - if false { - } else { - z.F.DecMapStringStringX(yyv230, false, d) - } - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv232 := &x.OwnerReferences - yym233 := z.DecBinary() - _ = yym233 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv232), d) - } - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv234 := &x.Finalizers - yym235 := z.DecBinary() - _ = yym235 - if false { - } else { - z.F.DecSliceStringX(yyv234, false, d) - } - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = SelfSubjectAccessReviewSpec{} - } else { - yyv237 := &x.Spec - yyv237.CodecDecodeSelf(d) - } - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = SubjectAccessReviewStatus{} - } else { - yyv238 := &x.Status - yyv238.CodecDecodeSelf(d) - } - for { - yyj212++ - if yyhl212 { - yyb212 = yyj212 > l - } else { - yyb212 = r.CheckBreak() - } - if yyb212 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj212-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *LocalSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym239 := z.EncBinary() - _ = yym239 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep240 := !z.EncBinary() - yy2arr240 := z.EncBasicHandle().StructToArray - var yyq240 [19]bool - _, _, _ = yysep240, yyq240, yy2arr240 - const yyr240 bool = false - yyq240[0] = x.Kind != "" - yyq240[1] = x.APIVersion != "" - yyq240[2] = x.Name != "" - yyq240[3] = x.GenerateName != "" - yyq240[4] = x.Namespace != "" - yyq240[5] = x.SelfLink != "" - yyq240[6] = x.UID != "" - yyq240[7] = x.ResourceVersion != "" - yyq240[8] = x.Generation != 0 - yyq240[9] = true - yyq240[10] = x.ObjectMeta.DeletionTimestamp != nil && x.DeletionTimestamp != nil - yyq240[11] = x.ObjectMeta.DeletionGracePeriodSeconds != nil && x.DeletionGracePeriodSeconds != nil - yyq240[12] = len(x.Labels) != 0 - yyq240[13] = len(x.Annotations) != 0 - yyq240[14] = len(x.OwnerReferences) != 0 - yyq240[15] = len(x.Finalizers) != 0 - yyq240[16] = x.ClusterName != "" - var yynn240 int - if yyr240 || yy2arr240 { - r.EncodeArrayStart(19) - } else { - yynn240 = 2 - for _, b := range yyq240 { - if b { - yynn240++ - } - } - r.EncodeMapStart(yynn240) - yynn240 = 0 - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[0] { - yym242 := z.EncBinary() - _ = yym242 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym243 := z.EncBinary() - _ = yym243 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[1] { - yym245 := z.EncBinary() - _ = yym245 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym246 := z.EncBinary() - _ = yym246 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[2] { - yym248 := z.EncBinary() - _ = yym248 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym249 := z.EncBinary() - _ = yym249 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[3] { - yym251 := z.EncBinary() - _ = yym251 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generateName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym252 := z.EncBinary() - _ = yym252 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.GenerateName)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[4] { - yym254 := z.EncBinary() - _ = yym254 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym255 := z.EncBinary() - _ = yym255 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[5] { - yym257 := z.EncBinary() - _ = yym257 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selfLink")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym258 := z.EncBinary() - _ = yym258 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SelfLink)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[6] { - yym260 := z.EncBinary() - _ = yym260 - 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 yyq240[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym261 := z.EncBinary() - _ = yym261 - if false { - } else if z.HasExtensions() && z.EncExt(x.UID) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[7] { - yym263 := z.EncBinary() - _ = yym263 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("resourceVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym264 := z.EncBinary() - _ = yym264 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ResourceVersion)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[8] { - yym266 := z.EncBinary() - _ = yym266 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq240[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("generation")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym267 := z.EncBinary() - _ = yym267 - if false { - } else { - r.EncodeInt(int64(x.Generation)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[9] { - yy269 := &x.CreationTimestamp - yym270 := z.EncBinary() - _ = yym270 - if false { - } else if z.HasExtensions() && z.EncExt(yy269) { - } else if yym270 { - z.EncBinaryMarshal(yy269) - } else if !yym270 && z.IsJSONHandle() { - z.EncJSONMarshal(yy269) - } else { - z.EncFallback(yy269) - } - } else { - r.EncodeNil() - } - } else { - if yyq240[9] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("creationTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy271 := &x.CreationTimestamp - yym272 := z.EncBinary() - _ = yym272 - if false { - } else if z.HasExtensions() && z.EncExt(yy271) { - } else if yym272 { - z.EncBinaryMarshal(yy271) - } else if !yym272 && z.IsJSONHandle() { - z.EncJSONMarshal(yy271) - } else { - z.EncFallback(yy271) - } - } - } - var yyn273 bool - if x.ObjectMeta.DeletionTimestamp == nil { - yyn273 = true - goto LABEL273 - } - LABEL273: - if yyr240 || yy2arr240 { - if yyn273 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[10] { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym274 := z.EncBinary() - _ = yym274 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym274 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym274 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq240[10] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionTimestamp")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn273 { - r.EncodeNil() - } else { - if x.DeletionTimestamp == nil { - r.EncodeNil() - } else { - yym275 := z.EncBinary() - _ = yym275 - if false { - } else if z.HasExtensions() && z.EncExt(x.DeletionTimestamp) { - } else if yym275 { - z.EncBinaryMarshal(x.DeletionTimestamp) - } else if !yym275 && z.IsJSONHandle() { - z.EncJSONMarshal(x.DeletionTimestamp) - } else { - z.EncFallback(x.DeletionTimestamp) - } - } - } - } - } - var yyn276 bool - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - yyn276 = true - goto LABEL276 - } - LABEL276: - if yyr240 || yy2arr240 { - if yyn276 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[11] { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy277 := *x.DeletionGracePeriodSeconds - yym278 := z.EncBinary() - _ = yym278 - if false { - } else { - r.EncodeInt(int64(yy277)) - } - } - } else { - r.EncodeNil() - } - } - } else { - if yyq240[11] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deletionGracePeriodSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn276 { - r.EncodeNil() - } else { - if x.DeletionGracePeriodSeconds == nil { - r.EncodeNil() - } else { - yy279 := *x.DeletionGracePeriodSeconds - yym280 := z.EncBinary() - _ = yym280 - if false { - } else { - r.EncodeInt(int64(yy279)) - } - } - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[12] { - if x.Labels == nil { - r.EncodeNil() - } else { - yym282 := z.EncBinary() - _ = yym282 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq240[12] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("labels")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Labels == nil { - r.EncodeNil() - } else { - yym283 := z.EncBinary() - _ = yym283 - if false { - } else { - z.F.EncMapStringStringV(x.Labels, false, e) - } - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[13] { - if x.Annotations == nil { - r.EncodeNil() - } else { - yym285 := z.EncBinary() - _ = yym285 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq240[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("annotations")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Annotations == nil { - r.EncodeNil() - } else { - yym286 := z.EncBinary() - _ = yym286 - if false { - } else { - z.F.EncMapStringStringV(x.Annotations, false, e) - } - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[14] { - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym288 := z.EncBinary() - _ = yym288 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq240[14] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ownerReferences")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.OwnerReferences == nil { - r.EncodeNil() - } else { - yym289 := z.EncBinary() - _ = yym289 - if false { - } else { - h.encSliceapi_OwnerReference(([]pkg2_api.OwnerReference)(x.OwnerReferences), e) - } - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[15] { - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym291 := z.EncBinary() - _ = yym291 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq240[15] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("finalizers")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Finalizers == nil { - r.EncodeNil() - } else { - yym292 := z.EncBinary() - _ = yym292 - if false { - } else { - z.F.EncSliceStringV(x.Finalizers, false, e) - } - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq240[16] { - yym294 := z.EncBinary() - _ = yym294 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq240[16] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("clusterName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym295 := z.EncBinary() - _ = yym295 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ClusterName)) - } - } - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy297 := &x.Spec - yy297.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy298 := &x.Spec - yy298.CodecEncodeSelf(e) - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy300 := &x.Status - yy300.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy301 := &x.Status - yy301.CodecEncodeSelf(e) - } - if yyr240 || yy2arr240 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *LocalSubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym302 := z.DecBinary() - _ = yym302 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct303 := r.ContainerType() - if yyct303 == codecSelferValueTypeMap1234 { - yyl303 := r.ReadMapStart() - if yyl303 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl303, d) - } - } else if yyct303 == codecSelferValueTypeArray1234 { - yyl303 := r.ReadArrayStart() - if yyl303 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl303, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *LocalSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys304Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys304Slc - var yyhl304 bool = l >= 0 - for yyj304 := 0; ; yyj304++ { - if yyhl304 { - if yyj304 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys304Slc = r.DecodeBytes(yys304Slc, true, true) - yys304 := string(yys304Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys304 { - 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 "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 = pkg3_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 = pkg1_unversioned.Time{} - } else { - yyv314 := &x.CreationTimestamp - yym315 := z.DecBinary() - _ = yym315 - if false { - } else if z.HasExtensions() && z.DecExt(yyv314) { - } else if yym315 { - z.DecBinaryUnmarshal(yyv314) - } else if !yym315 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv314) - } else { - z.DecFallback(yyv314, false) - } - } - case "deletionTimestamp": - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - if r.TryDecodeAsNil() { - if x.DeletionTimestamp != nil { - x.DeletionTimestamp = nil - } - } else { - if x.DeletionTimestamp == nil { - x.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yym317 := z.DecBinary() - _ = yym317 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym317 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym317 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - case "deletionGracePeriodSeconds": - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - if r.TryDecodeAsNil() { - if x.DeletionGracePeriodSeconds != nil { - x.DeletionGracePeriodSeconds = nil - } - } else { - if x.DeletionGracePeriodSeconds == nil { - x.DeletionGracePeriodSeconds = new(int64) - } - yym319 := z.DecBinary() - _ = yym319 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - case "labels": - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv320 := &x.Labels - yym321 := z.DecBinary() - _ = yym321 - if false { - } else { - z.F.DecMapStringStringX(yyv320, false, d) - } - } - case "annotations": - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv322 := &x.Annotations - yym323 := z.DecBinary() - _ = yym323 - if false { - } else { - z.F.DecMapStringStringX(yyv322, false, d) - } - } - case "ownerReferences": - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv324 := &x.OwnerReferences - yym325 := z.DecBinary() - _ = yym325 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv324), d) - } - } - case "finalizers": - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv326 := &x.Finalizers - yym327 := z.DecBinary() - _ = yym327 - if false { - } else { - z.F.DecSliceStringX(yyv326, false, d) - } - } - case "clusterName": - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - case "Spec": - if r.TryDecodeAsNil() { - x.Spec = SubjectAccessReviewSpec{} - } else { - yyv329 := &x.Spec - yyv329.CodecDecodeSelf(d) - } - case "Status": - if r.TryDecodeAsNil() { - x.Status = SubjectAccessReviewStatus{} - } else { - yyv330 := &x.Status - yyv330.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys304) - } // end switch yys304 - } // end for yyj304 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj331 int - var yyb331 bool - var yyhl331 bool = l >= 0 - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.GenerateName = "" - } else { - x.GenerateName = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SelfLink = "" - } else { - x.SelfLink = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = pkg3_types.UID(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ResourceVersion = "" - } else { - x.ResourceVersion = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Generation = 0 - } else { - x.Generation = int64(r.DecodeInt(64)) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CreationTimestamp = pkg1_unversioned.Time{} - } else { - yyv341 := &x.CreationTimestamp - yym342 := z.DecBinary() - _ = yym342 - if false { - } else if z.HasExtensions() && z.DecExt(yyv341) { - } else if yym342 { - z.DecBinaryUnmarshal(yyv341) - } else if !yym342 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv341) - } else { - z.DecFallback(yyv341, false) - } - } - if x.ObjectMeta.DeletionTimestamp == nil { - x.ObjectMeta.DeletionTimestamp = new(pkg1_unversioned.Time) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - 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(pkg1_unversioned.Time) - } - yym344 := z.DecBinary() - _ = yym344 - if false { - } else if z.HasExtensions() && z.DecExt(x.DeletionTimestamp) { - } else if yym344 { - z.DecBinaryUnmarshal(x.DeletionTimestamp) - } else if !yym344 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.DeletionTimestamp) - } else { - z.DecFallback(x.DeletionTimestamp, false) - } - } - if x.ObjectMeta.DeletionGracePeriodSeconds == nil { - x.ObjectMeta.DeletionGracePeriodSeconds = new(int64) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - 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) - } - yym346 := z.DecBinary() - _ = yym346 - if false { - } else { - *((*int64)(x.DeletionGracePeriodSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Labels = nil - } else { - yyv347 := &x.Labels - yym348 := z.DecBinary() - _ = yym348 - if false { - } else { - z.F.DecMapStringStringX(yyv347, false, d) - } - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Annotations = nil - } else { - yyv349 := &x.Annotations - yym350 := z.DecBinary() - _ = yym350 - if false { - } else { - z.F.DecMapStringStringX(yyv349, false, d) - } - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.OwnerReferences = nil - } else { - yyv351 := &x.OwnerReferences - yym352 := z.DecBinary() - _ = yym352 - if false { - } else { - h.decSliceapi_OwnerReference((*[]pkg2_api.OwnerReference)(yyv351), d) - } - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Finalizers = nil - } else { - yyv353 := &x.Finalizers - yym354 := z.DecBinary() - _ = yym354 - if false { - } else { - z.F.DecSliceStringX(yyv353, false, d) - } - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ClusterName = "" - } else { - x.ClusterName = string(r.DecodeString()) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = SubjectAccessReviewSpec{} - } else { - yyv356 := &x.Spec - yyv356.CodecDecodeSelf(d) - } - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = SubjectAccessReviewStatus{} - } else { - yyv357 := &x.Status - yyv357.CodecDecodeSelf(d) - } - for { - yyj331++ - if yyhl331 { - yyb331 = yyj331 > l - } else { - yyb331 = r.CheckBreak() - } - if yyb331 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj331-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym358 := z.EncBinary() - _ = yym358 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep359 := !z.EncBinary() - yy2arr359 := z.EncBasicHandle().StructToArray - var yyq359 [7]bool - _, _, _ = yysep359, yyq359, yy2arr359 - const yyr359 bool = false - var yynn359 int - if yyr359 || yy2arr359 { - r.EncodeArrayStart(7) - } else { - yynn359 = 7 - for _, b := range yyq359 { - if b { - yynn359++ - } - } - r.EncodeMapStart(yynn359) - yynn359 = 0 - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym361 := z.EncBinary() - _ = yym361 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Namespace")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym362 := z.EncBinary() - _ = yym362 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym364 := z.EncBinary() - _ = yym364 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Verb")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym365 := z.EncBinary() - _ = yym365 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym367 := z.EncBinary() - _ = yym367 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Group)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Group")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym368 := z.EncBinary() - _ = yym368 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Group)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym370 := z.EncBinary() - _ = yym370 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Version)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Version")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym371 := z.EncBinary() - _ = yym371 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Version)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym373 := z.EncBinary() - _ = yym373 - 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) - yym374 := z.EncBinary() - _ = yym374 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym376 := z.EncBinary() - _ = yym376 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Subresource")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym377 := z.EncBinary() - _ = yym377 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym379 := z.EncBinary() - _ = yym379 - 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) - yym380 := z.EncBinary() - _ = yym380 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr359 || yy2arr359 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ResourceAttributes) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym381 := z.DecBinary() - _ = yym381 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct382 := r.ContainerType() - if yyct382 == codecSelferValueTypeMap1234 { - yyl382 := r.ReadMapStart() - if yyl382 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl382, d) - } - } else if yyct382 == codecSelferValueTypeArray1234 { - yyl382 := r.ReadArrayStart() - if yyl382 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl382, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys383Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys383Slc - var yyhl383 bool = l >= 0 - for yyj383 := 0; ; yyj383++ { - if yyhl383 { - if yyj383 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys383Slc = r.DecodeBytes(yys383Slc, true, true) - yys383 := string(yys383Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys383 { - case "Namespace": - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - case "Verb": - if r.TryDecodeAsNil() { - x.Verb = "" - } else { - x.Verb = string(r.DecodeString()) - } - case "Group": - if r.TryDecodeAsNil() { - x.Group = "" - } else { - x.Group = string(r.DecodeString()) - } - case "Version": - if r.TryDecodeAsNil() { - x.Version = "" - } else { - x.Version = string(r.DecodeString()) - } - case "Resource": - if r.TryDecodeAsNil() { - x.Resource = "" - } else { - x.Resource = string(r.DecodeString()) - } - case "Subresource": - if r.TryDecodeAsNil() { - x.Subresource = "" - } else { - x.Subresource = string(r.DecodeString()) - } - case "Name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys383) - } // end switch yys383 - } // end for yyj383 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj391 int - var yyb391 bool - var yyhl391 bool = l >= 0 - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Namespace = "" - } else { - x.Namespace = string(r.DecodeString()) - } - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Verb = "" - } else { - x.Verb = string(r.DecodeString()) - } - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Group = "" - } else { - x.Group = string(r.DecodeString()) - } - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Version = "" - } else { - x.Version = string(r.DecodeString()) - } - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Resource = "" - } else { - x.Resource = string(r.DecodeString()) - } - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Subresource = "" - } else { - x.Subresource = string(r.DecodeString()) - } - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - for { - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l - } else { - yyb391 = r.CheckBreak() - } - if yyb391 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj391-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NonResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym399 := z.EncBinary() - _ = yym399 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep400 := !z.EncBinary() - yy2arr400 := z.EncBasicHandle().StructToArray - var yyq400 [2]bool - _, _, _ = yysep400, yyq400, yy2arr400 - const yyr400 bool = false - var yynn400 int - if yyr400 || yy2arr400 { - r.EncodeArrayStart(2) - } else { - yynn400 = 2 - for _, b := range yyq400 { - if b { - yynn400++ - } - } - r.EncodeMapStart(yynn400) - yynn400 = 0 - } - if yyr400 || yy2arr400 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym402 := z.EncBinary() - _ = yym402 - 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) - yym403 := z.EncBinary() - _ = yym403 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - if yyr400 || yy2arr400 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym405 := z.EncBinary() - _ = yym405 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Verb")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym406 := z.EncBinary() - _ = yym406 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) - } - } - if yyr400 || yy2arr400 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NonResourceAttributes) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym407 := z.DecBinary() - _ = yym407 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct408 := r.ContainerType() - if yyct408 == codecSelferValueTypeMap1234 { - yyl408 := r.ReadMapStart() - if yyl408 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl408, d) - } - } else if yyct408 == codecSelferValueTypeArray1234 { - yyl408 := r.ReadArrayStart() - if yyl408 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl408, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NonResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys409Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys409Slc - var yyhl409 bool = l >= 0 - for yyj409 := 0; ; yyj409++ { - if yyhl409 { - if yyj409 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys409Slc = r.DecodeBytes(yys409Slc, true, true) - yys409 := string(yys409Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys409 { - case "Path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - case "Verb": - if r.TryDecodeAsNil() { - x.Verb = "" - } else { - x.Verb = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys409) - } // end switch yys409 - } // end for yyj409 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NonResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj412 int - var yyb412 bool - var yyhl412 bool = l >= 0 - yyj412++ - if yyhl412 { - yyb412 = yyj412 > l - } else { - yyb412 = r.CheckBreak() - } - if yyb412 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj412++ - if yyhl412 { - yyb412 = yyj412 > l - } else { - yyb412 = r.CheckBreak() - } - if yyb412 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Verb = "" - } else { - x.Verb = string(r.DecodeString()) - } - for { - yyj412++ - if yyhl412 { - yyb412 = yyj412 > l - } else { - yyb412 = r.CheckBreak() - } - if yyb412 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj412-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym415 := z.EncBinary() - _ = yym415 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep416 := !z.EncBinary() - yy2arr416 := z.EncBasicHandle().StructToArray - var yyq416 [5]bool - _, _, _ = yysep416, yyq416, yy2arr416 - const yyr416 bool = false - var yynn416 int - if yyr416 || yy2arr416 { - r.EncodeArrayStart(5) - } else { - yynn416 = 5 - for _, b := range yyq416 { - if b { - yynn416++ - } - } - r.EncodeMapStart(yynn416) - yynn416 = 0 - } - if yyr416 || yy2arr416 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.ResourceAttributes == nil { - r.EncodeNil() - } else { - x.ResourceAttributes.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ResourceAttributes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ResourceAttributes == nil { - r.EncodeNil() - } else { - x.ResourceAttributes.CodecEncodeSelf(e) - } - } - if yyr416 || yy2arr416 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.NonResourceAttributes == nil { - r.EncodeNil() - } else { - x.NonResourceAttributes.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("NonResourceAttributes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NonResourceAttributes == nil { - r.EncodeNil() - } else { - x.NonResourceAttributes.CodecEncodeSelf(e) - } - } - if yyr416 || yy2arr416 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym420 := z.EncBinary() - _ = yym420 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("User")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym421 := z.EncBinary() - _ = yym421 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.User)) - } - } - if yyr416 || yy2arr416 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Groups == nil { - r.EncodeNil() - } else { - yym423 := z.EncBinary() - _ = yym423 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Groups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Groups == nil { - r.EncodeNil() - } else { - yym424 := z.EncBinary() - _ = yym424 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } - if yyr416 || yy2arr416 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Extra == nil { - r.EncodeNil() - } else { - yym426 := z.EncBinary() - _ = yym426 - if false { - } else { - h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Extra")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Extra == nil { - r.EncodeNil() - } else { - yym427 := z.EncBinary() - _ = yym427 - if false { - } else { - h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) - } - } - } - if yyr416 || yy2arr416 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SubjectAccessReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym428 := z.DecBinary() - _ = yym428 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct429 := r.ContainerType() - if yyct429 == codecSelferValueTypeMap1234 { - yyl429 := r.ReadMapStart() - if yyl429 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl429, d) - } - } else if yyct429 == codecSelferValueTypeArray1234 { - yyl429 := r.ReadArrayStart() - if yyl429 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl429, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys430Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys430Slc - var yyhl430 bool = l >= 0 - for yyj430 := 0; ; yyj430++ { - if yyhl430 { - if yyj430 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys430Slc = r.DecodeBytes(yys430Slc, true, true) - yys430 := string(yys430Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys430 { - case "ResourceAttributes": - if r.TryDecodeAsNil() { - if x.ResourceAttributes != nil { - x.ResourceAttributes = nil - } - } else { - if x.ResourceAttributes == nil { - x.ResourceAttributes = new(ResourceAttributes) - } - x.ResourceAttributes.CodecDecodeSelf(d) - } - case "NonResourceAttributes": - if r.TryDecodeAsNil() { - if x.NonResourceAttributes != nil { - x.NonResourceAttributes = nil - } - } else { - if x.NonResourceAttributes == nil { - x.NonResourceAttributes = new(NonResourceAttributes) - } - x.NonResourceAttributes.CodecDecodeSelf(d) - } - case "User": - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - case "Groups": - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv434 := &x.Groups - yym435 := z.DecBinary() - _ = yym435 - if false { - } else { - z.F.DecSliceStringX(yyv434, false, d) - } - } - case "Extra": - if r.TryDecodeAsNil() { - x.Extra = nil - } else { - yyv436 := &x.Extra - yym437 := z.DecBinary() - _ = yym437 - if false { - } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv436), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys430) - } // end switch yys430 - } // end for yyj430 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj438 int - var yyb438 bool - var yyhl438 bool = l >= 0 - yyj438++ - if yyhl438 { - yyb438 = yyj438 > l - } else { - yyb438 = r.CheckBreak() - } - if yyb438 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ResourceAttributes != nil { - x.ResourceAttributes = nil - } - } else { - if x.ResourceAttributes == nil { - x.ResourceAttributes = new(ResourceAttributes) - } - x.ResourceAttributes.CodecDecodeSelf(d) - } - yyj438++ - if yyhl438 { - yyb438 = yyj438 > l - } else { - yyb438 = r.CheckBreak() - } - if yyb438 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.NonResourceAttributes != nil { - x.NonResourceAttributes = nil - } - } else { - if x.NonResourceAttributes == nil { - x.NonResourceAttributes = new(NonResourceAttributes) - } - x.NonResourceAttributes.CodecDecodeSelf(d) - } - yyj438++ - if yyhl438 { - yyb438 = yyj438 > l - } else { - yyb438 = r.CheckBreak() - } - if yyb438 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.User = "" - } else { - x.User = string(r.DecodeString()) - } - yyj438++ - if yyhl438 { - yyb438 = yyj438 > l - } else { - yyb438 = r.CheckBreak() - } - if yyb438 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv442 := &x.Groups - yym443 := z.DecBinary() - _ = yym443 - if false { - } else { - z.F.DecSliceStringX(yyv442, false, d) - } - } - yyj438++ - if yyhl438 { - yyb438 = yyj438 > l - } else { - yyb438 = r.CheckBreak() - } - if yyb438 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Extra = nil - } else { - yyv444 := &x.Extra - yym445 := z.DecBinary() - _ = yym445 - if false { - } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv444), d) - } - } - for { - yyj438++ - if yyhl438 { - yyb438 = yyj438 > l - } else { - yyb438 = r.CheckBreak() - } - if yyb438 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj438-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ExtraValue) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym446 := z.EncBinary() - _ = yym446 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - h.encExtraValue((ExtraValue)(x), e) - } - } -} - -func (x *ExtraValue) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym447 := z.DecBinary() - _ = yym447 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - h.decExtraValue((*ExtraValue)(x), d) - } -} - -func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym448 := z.EncBinary() - _ = yym448 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep449 := !z.EncBinary() - yy2arr449 := z.EncBasicHandle().StructToArray - var yyq449 [2]bool - _, _, _ = yysep449, yyq449, yy2arr449 - const yyr449 bool = false - var yynn449 int - if yyr449 || yy2arr449 { - r.EncodeArrayStart(2) - } else { - yynn449 = 2 - for _, b := range yyq449 { - if b { - yynn449++ - } - } - r.EncodeMapStart(yynn449) - yynn449 = 0 - } - if yyr449 || yy2arr449 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.ResourceAttributes == nil { - r.EncodeNil() - } else { - x.ResourceAttributes.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ResourceAttributes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ResourceAttributes == nil { - r.EncodeNil() - } else { - x.ResourceAttributes.CodecEncodeSelf(e) - } - } - if yyr449 || yy2arr449 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.NonResourceAttributes == nil { - r.EncodeNil() - } else { - x.NonResourceAttributes.CodecEncodeSelf(e) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("NonResourceAttributes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NonResourceAttributes == nil { - r.EncodeNil() - } else { - x.NonResourceAttributes.CodecEncodeSelf(e) - } - } - if yyr449 || yy2arr449 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SelfSubjectAccessReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym452 := z.DecBinary() - _ = yym452 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct453 := r.ContainerType() - if yyct453 == codecSelferValueTypeMap1234 { - yyl453 := r.ReadMapStart() - if yyl453 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl453, d) - } - } else if yyct453 == codecSelferValueTypeArray1234 { - yyl453 := r.ReadArrayStart() - if yyl453 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl453, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys454Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys454Slc - var yyhl454 bool = l >= 0 - for yyj454 := 0; ; yyj454++ { - if yyhl454 { - if yyj454 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys454Slc = r.DecodeBytes(yys454Slc, true, true) - yys454 := string(yys454Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys454 { - case "ResourceAttributes": - if r.TryDecodeAsNil() { - if x.ResourceAttributes != nil { - x.ResourceAttributes = nil - } - } else { - if x.ResourceAttributes == nil { - x.ResourceAttributes = new(ResourceAttributes) - } - x.ResourceAttributes.CodecDecodeSelf(d) - } - case "NonResourceAttributes": - if r.TryDecodeAsNil() { - if x.NonResourceAttributes != nil { - x.NonResourceAttributes = nil - } - } else { - if x.NonResourceAttributes == nil { - x.NonResourceAttributes = new(NonResourceAttributes) - } - x.NonResourceAttributes.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys454) - } // end switch yys454 - } // end for yyj454 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj457 int - var yyb457 bool - var yyhl457 bool = l >= 0 - yyj457++ - if yyhl457 { - yyb457 = yyj457 > l - } else { - yyb457 = r.CheckBreak() - } - if yyb457 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ResourceAttributes != nil { - x.ResourceAttributes = nil - } - } else { - if x.ResourceAttributes == nil { - x.ResourceAttributes = new(ResourceAttributes) - } - x.ResourceAttributes.CodecDecodeSelf(d) - } - yyj457++ - if yyhl457 { - yyb457 = yyj457 > l - } else { - yyb457 = r.CheckBreak() - } - if yyb457 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.NonResourceAttributes != nil { - x.NonResourceAttributes = nil - } - } else { - if x.NonResourceAttributes == nil { - x.NonResourceAttributes = new(NonResourceAttributes) - } - x.NonResourceAttributes.CodecDecodeSelf(d) - } - for { - yyj457++ - if yyhl457 { - yyb457 = yyj457 > l - } else { - yyb457 = r.CheckBreak() - } - if yyb457 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj457-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *SubjectAccessReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym460 := z.EncBinary() - _ = yym460 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep461 := !z.EncBinary() - yy2arr461 := z.EncBasicHandle().StructToArray - var yyq461 [3]bool - _, _, _ = yysep461, yyq461, yy2arr461 - const yyr461 bool = false - var yynn461 int - if yyr461 || yy2arr461 { - r.EncodeArrayStart(3) - } else { - yynn461 = 3 - for _, b := range yyq461 { - if b { - yynn461++ - } - } - r.EncodeMapStart(yynn461) - yynn461 = 0 - } - if yyr461 || yy2arr461 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym463 := z.EncBinary() - _ = yym463 - if false { - } else { - r.EncodeBool(bool(x.Allowed)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Allowed")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym464 := z.EncBinary() - _ = yym464 - if false { - } else { - r.EncodeBool(bool(x.Allowed)) - } - } - if yyr461 || yy2arr461 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym466 := z.EncBinary() - _ = yym466 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("Reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym467 := z.EncBinary() - _ = yym467 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - if yyr461 || yy2arr461 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym469 := z.EncBinary() - _ = yym469 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.EvaluationError)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("EvaluationError")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym470 := z.EncBinary() - _ = yym470 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.EvaluationError)) - } - } - if yyr461 || yy2arr461 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SubjectAccessReviewStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym471 := z.DecBinary() - _ = yym471 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct472 := r.ContainerType() - if yyct472 == codecSelferValueTypeMap1234 { - yyl472 := r.ReadMapStart() - if yyl472 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl472, d) - } - } else if yyct472 == codecSelferValueTypeArray1234 { - yyl472 := r.ReadArrayStart() - if yyl472 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl472, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SubjectAccessReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys473Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys473Slc - var yyhl473 bool = l >= 0 - for yyj473 := 0; ; yyj473++ { - if yyhl473 { - if yyj473 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys473Slc = r.DecodeBytes(yys473Slc, true, true) - yys473 := string(yys473Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys473 { - case "Allowed": - if r.TryDecodeAsNil() { - x.Allowed = false - } else { - x.Allowed = bool(r.DecodeBool()) - } - case "Reason": - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - case "EvaluationError": - if r.TryDecodeAsNil() { - x.EvaluationError = "" - } else { - x.EvaluationError = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys473) - } // end switch yys473 - } // end for yyj473 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SubjectAccessReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj477 int - var yyb477 bool - var yyhl477 bool = l >= 0 - yyj477++ - if yyhl477 { - yyb477 = yyj477 > l - } else { - yyb477 = r.CheckBreak() - } - if yyb477 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Allowed = false - } else { - x.Allowed = bool(r.DecodeBool()) - } - yyj477++ - if yyhl477 { - yyb477 = yyj477 > l - } else { - yyb477 = r.CheckBreak() - } - if yyb477 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj477++ - if yyhl477 { - yyb477 = yyj477 > l - } else { - yyb477 = r.CheckBreak() - } - if yyb477 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.EvaluationError = "" - } else { - x.EvaluationError = string(r.DecodeString()) - } - for { - yyj477++ - if yyhl477 { - yyb477 = yyj477 > l - } else { - yyb477 = r.CheckBreak() - } - if yyb477 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj477-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceapi_OwnerReference(v []pkg2_api.OwnerReference, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv481 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy482 := &yyv481 - yy482.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceapi_OwnerReference(v *[]pkg2_api.OwnerReference, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv483 := *v - yyh483, yyl483 := z.DecSliceHelperStart() - var yyc483 bool - if yyl483 == 0 { - if yyv483 == nil { - yyv483 = []pkg2_api.OwnerReference{} - yyc483 = true - } else if len(yyv483) != 0 { - yyv483 = yyv483[:0] - yyc483 = true - } - } else if yyl483 > 0 { - var yyrr483, yyrl483 int - var yyrt483 bool - if yyl483 > cap(yyv483) { - - yyrg483 := len(yyv483) > 0 - yyv2483 := yyv483 - yyrl483, yyrt483 = z.DecInferLen(yyl483, z.DecBasicHandle().MaxInitLen, 72) - if yyrt483 { - if yyrl483 <= cap(yyv483) { - yyv483 = yyv483[:yyrl483] - } else { - yyv483 = make([]pkg2_api.OwnerReference, yyrl483) - } - } else { - yyv483 = make([]pkg2_api.OwnerReference, yyrl483) - } - yyc483 = true - yyrr483 = len(yyv483) - if yyrg483 { - copy(yyv483, yyv2483) - } - } else if yyl483 != len(yyv483) { - yyv483 = yyv483[:yyl483] - yyc483 = true - } - yyj483 := 0 - for ; yyj483 < yyrr483; yyj483++ { - yyh483.ElemContainerState(yyj483) - if r.TryDecodeAsNil() { - yyv483[yyj483] = pkg2_api.OwnerReference{} - } else { - yyv484 := &yyv483[yyj483] - yyv484.CodecDecodeSelf(d) - } - - } - if yyrt483 { - for ; yyj483 < yyl483; yyj483++ { - yyv483 = append(yyv483, pkg2_api.OwnerReference{}) - yyh483.ElemContainerState(yyj483) - if r.TryDecodeAsNil() { - yyv483[yyj483] = pkg2_api.OwnerReference{} - } else { - yyv485 := &yyv483[yyj483] - yyv485.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj483 := 0 - for ; !r.CheckBreak(); yyj483++ { - - if yyj483 >= len(yyv483) { - yyv483 = append(yyv483, pkg2_api.OwnerReference{}) // var yyz483 pkg2_api.OwnerReference - yyc483 = true - } - yyh483.ElemContainerState(yyj483) - if yyj483 < len(yyv483) { - if r.TryDecodeAsNil() { - yyv483[yyj483] = pkg2_api.OwnerReference{} - } else { - yyv486 := &yyv483[yyj483] - yyv486.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj483 < len(yyv483) { - yyv483 = yyv483[:yyj483] - yyc483 = true - } else if yyj483 == 0 && yyv483 == nil { - yyv483 = []pkg2_api.OwnerReference{} - yyc483 = true - } - } - yyh483.End() - if yyc483 { - *v = yyv483 - } -} - -func (x codecSelfer1234) encMapstringExtraValue(v map[string]ExtraValue, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk487, yyv487 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym488 := z.EncBinary() - _ = yym488 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk487)) - } - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv487 == nil { - r.EncodeNil() - } else { - yyv487.CodecEncodeSelf(e) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) decMapstringExtraValue(v *map[string]ExtraValue, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv489 := *v - yyl489 := r.ReadMapStart() - yybh489 := z.DecBasicHandle() - if yyv489 == nil { - yyrl489, _ := z.DecInferLen(yyl489, yybh489.MaxInitLen, 40) - yyv489 = make(map[string]ExtraValue, yyrl489) - *v = yyv489 - } - var yymk489 string - var yymv489 ExtraValue - var yymg489 bool - if yybh489.MapValueReset { - yymg489 = true - } - if yyl489 > 0 { - for yyj489 := 0; yyj489 < yyl489; yyj489++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk489 = "" - } else { - yymk489 = string(r.DecodeString()) - } - - if yymg489 { - yymv489 = yyv489[yymk489] - } else { - yymv489 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv489 = nil - } else { - yyv491 := &yymv489 - yyv491.CodecDecodeSelf(d) - } - - if yyv489 != nil { - yyv489[yymk489] = yymv489 - } - } - } else if yyl489 < 0 { - for yyj489 := 0; !r.CheckBreak(); yyj489++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk489 = "" - } else { - yymk489 = string(r.DecodeString()) - } - - if yymg489 { - yymv489 = yyv489[yymk489] - } else { - yymv489 = nil - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv489 = nil - } else { - yyv493 := &yymv489 - yyv493.CodecDecodeSelf(d) - } - - if yyv489 != nil { - yyv489[yymk489] = yymv489 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) encExtraValue(v ExtraValue, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv494 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym495 := z.EncBinary() - _ = yym495 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyv494)) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv496 := *v - yyh496, yyl496 := z.DecSliceHelperStart() - var yyc496 bool - if yyl496 == 0 { - if yyv496 == nil { - yyv496 = []string{} - yyc496 = true - } else if len(yyv496) != 0 { - yyv496 = yyv496[:0] - yyc496 = true - } - } else if yyl496 > 0 { - var yyrr496, yyrl496 int - var yyrt496 bool - if yyl496 > cap(yyv496) { - - yyrl496, yyrt496 = z.DecInferLen(yyl496, z.DecBasicHandle().MaxInitLen, 16) - if yyrt496 { - if yyrl496 <= cap(yyv496) { - yyv496 = yyv496[:yyrl496] - } else { - yyv496 = make([]string, yyrl496) - } - } else { - yyv496 = make([]string, yyrl496) - } - yyc496 = true - yyrr496 = len(yyv496) - } else if yyl496 != len(yyv496) { - yyv496 = yyv496[:yyl496] - yyc496 = true - } - yyj496 := 0 - for ; yyj496 < yyrr496; yyj496++ { - yyh496.ElemContainerState(yyj496) - if r.TryDecodeAsNil() { - yyv496[yyj496] = "" - } else { - yyv496[yyj496] = string(r.DecodeString()) - } - - } - if yyrt496 { - for ; yyj496 < yyl496; yyj496++ { - yyv496 = append(yyv496, "") - yyh496.ElemContainerState(yyj496) - if r.TryDecodeAsNil() { - yyv496[yyj496] = "" - } else { - yyv496[yyj496] = string(r.DecodeString()) - } - - } - } - - } else { - yyj496 := 0 - for ; !r.CheckBreak(); yyj496++ { - - if yyj496 >= len(yyv496) { - yyv496 = append(yyv496, "") // var yyz496 string - yyc496 = true - } - yyh496.ElemContainerState(yyj496) - if yyj496 < len(yyv496) { - if r.TryDecodeAsNil() { - yyv496[yyj496] = "" - } else { - yyv496[yyj496] = string(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj496 < len(yyv496) { - yyv496 = yyv496[:yyj496] - yyc496 = true - } else if yyj496 == 0 && yyv496 == nil { - yyv496 = []string{} - yyc496 = true - } - } - yyh496.End() - if yyc496 { - *v = yyv496 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/types.go b/vendor/k8s.io/client-go/pkg/apis/authorization/types.go index 2ac05589d0..d8ccfaf358 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/types.go @@ -17,8 +17,7 @@ limitations under the License. package authorization import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // +genclient=true @@ -28,8 +27,8 @@ import ( // SubjectAccessReview checks whether or not a user or group can perform an action. Not filling in a // spec.namespace means "in all namespaces". type SubjectAccessReview struct { - unversioned.TypeMeta - api.ObjectMeta + metav1.TypeMeta + metav1.ObjectMeta // Spec holds information about the request being evaluated Spec SubjectAccessReviewSpec @@ -46,8 +45,8 @@ type SubjectAccessReview struct { // spec.namespace means "in all namespaces". Self is a special case, because users should always be able // to check whether they can perform an action type SelfSubjectAccessReview struct { - unversioned.TypeMeta - api.ObjectMeta + metav1.TypeMeta + metav1.ObjectMeta // Spec holds information about the request being evaluated. Spec SelfSubjectAccessReviewSpec @@ -63,8 +62,8 @@ type SelfSubjectAccessReview struct { // Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions // checking. type LocalSubjectAccessReview struct { - unversioned.TypeMeta - api.ObjectMeta + metav1.TypeMeta + metav1.ObjectMeta // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace // you made the request against. If empty, it is defaulted. diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/BUILD b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/BUILD new file mode 100644 index 0000000000..d2185f6dc6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authorization:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/conversion.go new file mode 100644 index 0000000000..2ff5732d6d --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/conversion.go @@ -0,0 +1,26 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addConversionFuncs(scheme *runtime.Scheme) error { + // Add non-generated conversion functions + return scheme.AddConversionFuncs() +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/defaults.go new file mode 100644 index 0000000000..074e15baed --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/defaults.go @@ -0,0 +1,25 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/doc.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/doc.go new file mode 100644 index 0000000000..41741dd537 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=authorization.k8s.io +package v1 diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go new file mode 100644 index 0000000000..0204e88dbb --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.pb.go @@ -0,0 +1,2364 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/authorization/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/authorization/v1/generated.proto + + It has these top-level messages: + ExtraValue + LocalSubjectAccessReview + NonResourceAttributes + ResourceAttributes + SelfSubjectAccessReview + SelfSubjectAccessReviewSpec + SubjectAccessReview + SubjectAccessReviewSpec + SubjectAccessReviewStatus +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *ExtraValue) Reset() { *m = ExtraValue{} } +func (*ExtraValue) ProtoMessage() {} +func (*ExtraValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *LocalSubjectAccessReview) Reset() { *m = LocalSubjectAccessReview{} } +func (*LocalSubjectAccessReview) ProtoMessage() {} +func (*LocalSubjectAccessReview) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{1} +} + +func (m *NonResourceAttributes) Reset() { *m = NonResourceAttributes{} } +func (*NonResourceAttributes) ProtoMessage() {} +func (*NonResourceAttributes) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *ResourceAttributes) Reset() { *m = ResourceAttributes{} } +func (*ResourceAttributes) ProtoMessage() {} +func (*ResourceAttributes) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *SelfSubjectAccessReview) Reset() { *m = SelfSubjectAccessReview{} } +func (*SelfSubjectAccessReview) ProtoMessage() {} +func (*SelfSubjectAccessReview) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *SelfSubjectAccessReviewSpec) Reset() { *m = SelfSubjectAccessReviewSpec{} } +func (*SelfSubjectAccessReviewSpec) ProtoMessage() {} +func (*SelfSubjectAccessReviewSpec) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{5} +} + +func (m *SubjectAccessReview) Reset() { *m = SubjectAccessReview{} } +func (*SubjectAccessReview) ProtoMessage() {} +func (*SubjectAccessReview) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } + +func (m *SubjectAccessReviewSpec) Reset() { *m = SubjectAccessReviewSpec{} } +func (*SubjectAccessReviewSpec) ProtoMessage() {} +func (*SubjectAccessReviewSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *SubjectAccessReviewStatus) Reset() { *m = SubjectAccessReviewStatus{} } +func (*SubjectAccessReviewStatus) ProtoMessage() {} +func (*SubjectAccessReviewStatus) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{8} +} + +func init() { + proto.RegisterType((*ExtraValue)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.ExtraValue") + proto.RegisterType((*LocalSubjectAccessReview)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.LocalSubjectAccessReview") + proto.RegisterType((*NonResourceAttributes)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.NonResourceAttributes") + proto.RegisterType((*ResourceAttributes)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.ResourceAttributes") + proto.RegisterType((*SelfSubjectAccessReview)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.SelfSubjectAccessReview") + proto.RegisterType((*SelfSubjectAccessReviewSpec)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.SelfSubjectAccessReviewSpec") + proto.RegisterType((*SubjectAccessReview)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.SubjectAccessReview") + proto.RegisterType((*SubjectAccessReviewSpec)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.SubjectAccessReviewSpec") + proto.RegisterType((*SubjectAccessReviewStatus)(nil), "k8s.io.client-go.pkg.apis.authorization.v1.SubjectAccessReviewStatus") +} +func (m ExtraValue) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m ExtraValue) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *LocalSubjectAccessReview) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *LocalSubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + return i, nil +} + +func (m *NonResourceAttributes) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NonResourceAttributes) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Verb))) + i += copy(dAtA[i:], m.Verb) + return i, nil +} + +func (m *ResourceAttributes) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ResourceAttributes) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Verb))) + i += copy(dAtA[i:], m.Verb) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i += copy(dAtA[i:], m.Version) + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Resource))) + i += copy(dAtA[i:], m.Resource) + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Subresource))) + i += copy(dAtA[i:], m.Subresource) + dAtA[i] = 0x3a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func (m *SelfSubjectAccessReview) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SelfSubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n5, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n6, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + return i, nil +} + +func (m *SelfSubjectAccessReviewSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SelfSubjectAccessReviewSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.ResourceAttributes != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceAttributes.Size())) + n7, err := m.ResourceAttributes.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + } + if m.NonResourceAttributes != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NonResourceAttributes.Size())) + n8, err := m.NonResourceAttributes.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 + } + return i, nil +} + +func (m *SubjectAccessReview) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n10, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n11, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n11 + return i, nil +} + +func (m *SubjectAccessReviewSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SubjectAccessReviewSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.ResourceAttributes != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceAttributes.Size())) + n12, err := m.ResourceAttributes.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n12 + } + if m.NonResourceAttributes != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NonResourceAttributes.Size())) + n13, err := m.NonResourceAttributes.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n13 + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.User))) + i += copy(dAtA[i:], m.User) + if len(m.Groups) > 0 { + for _, s := range m.Groups { + dAtA[i] = 0x22 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Extra) > 0 { + keysForExtra := make([]string, 0, len(m.Extra)) + for k := range m.Extra { + keysForExtra = append(keysForExtra, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + for _, k := range keysForExtra { + dAtA[i] = 0x2a + i++ + v := m.Extra[string(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n14, err := (&v).MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n14 + } + } + return i, nil +} + +func (m *SubjectAccessReviewStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SubjectAccessReviewStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0x8 + i++ + if m.Allowed { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i++ + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.EvaluationError))) + i += copy(dAtA[i:], m.EvaluationError) + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m ExtraValue) Size() (n int) { + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *LocalSubjectAccessReview) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *NonResourceAttributes) Size() (n int) { + var l int + _ = l + l = len(m.Path) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Verb) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ResourceAttributes) Size() (n int) { + var l int + _ = l + l = len(m.Namespace) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Verb) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Group) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Version) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Resource) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Subresource) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *SelfSubjectAccessReview) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *SelfSubjectAccessReviewSpec) Size() (n int) { + var l int + _ = l + if m.ResourceAttributes != nil { + l = m.ResourceAttributes.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.NonResourceAttributes != nil { + l = m.NonResourceAttributes.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *SubjectAccessReview) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *SubjectAccessReviewSpec) Size() (n int) { + var l int + _ = l + if m.ResourceAttributes != nil { + l = m.ResourceAttributes.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.NonResourceAttributes != nil { + l = m.NonResourceAttributes.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + l = len(m.User) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Groups) > 0 { + for _, s := range m.Groups { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Extra) > 0 { + for k, v := range m.Extra { + _ = k + _ = v + l = v.Size() + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l)) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + return n +} + +func (m *SubjectAccessReviewStatus) Size() (n int) { + var l int + _ = l + n += 2 + l = len(m.Reason) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.EvaluationError) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *LocalSubjectAccessReview) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&LocalSubjectAccessReview{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubjectAccessReviewSpec", "SubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NonResourceAttributes) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NonResourceAttributes{`, + `Path:` + fmt.Sprintf("%v", this.Path) + `,`, + `Verb:` + fmt.Sprintf("%v", this.Verb) + `,`, + `}`, + }, "") + return s +} +func (this *ResourceAttributes) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ResourceAttributes{`, + `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, + `Verb:` + fmt.Sprintf("%v", this.Verb) + `,`, + `Group:` + fmt.Sprintf("%v", this.Group) + `,`, + `Version:` + fmt.Sprintf("%v", this.Version) + `,`, + `Resource:` + fmt.Sprintf("%v", this.Resource) + `,`, + `Subresource:` + fmt.Sprintf("%v", this.Subresource) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func (this *SelfSubjectAccessReview) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SelfSubjectAccessReview{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SelfSubjectAccessReviewSpec", "SelfSubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SelfSubjectAccessReviewSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SelfSubjectAccessReviewSpec{`, + `ResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.ResourceAttributes), "ResourceAttributes", "ResourceAttributes", 1) + `,`, + `NonResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.NonResourceAttributes), "NonResourceAttributes", "NonResourceAttributes", 1) + `,`, + `}`, + }, "") + return s +} +func (this *SubjectAccessReview) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SubjectAccessReview{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubjectAccessReviewSpec", "SubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *SubjectAccessReviewSpec) String() string { + if this == nil { + return "nil" + } + keysForExtra := make([]string, 0, len(this.Extra)) + for k := range this.Extra { + keysForExtra = append(keysForExtra, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + mapStringForExtra := "map[string]ExtraValue{" + for _, k := range keysForExtra { + mapStringForExtra += fmt.Sprintf("%v: %v,", k, this.Extra[k]) + } + mapStringForExtra += "}" + s := strings.Join([]string{`&SubjectAccessReviewSpec{`, + `ResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.ResourceAttributes), "ResourceAttributes", "ResourceAttributes", 1) + `,`, + `NonResourceAttributes:` + strings.Replace(fmt.Sprintf("%v", this.NonResourceAttributes), "NonResourceAttributes", "NonResourceAttributes", 1) + `,`, + `User:` + fmt.Sprintf("%v", this.User) + `,`, + `Groups:` + fmt.Sprintf("%v", this.Groups) + `,`, + `Extra:` + mapStringForExtra + `,`, + `}`, + }, "") + return s +} +func (this *SubjectAccessReviewStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&SubjectAccessReviewStatus{`, + `Allowed:` + fmt.Sprintf("%v", this.Allowed) + `,`, + `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, + `EvaluationError:` + fmt.Sprintf("%v", this.EvaluationError) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *ExtraValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExtraValue: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExtraValue: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + *m = append(*m, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *LocalSubjectAccessReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: LocalSubjectAccessReview: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: LocalSubjectAccessReview: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NonResourceAttributes) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NonResourceAttributes: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NonResourceAttributes: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Path = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Verb", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Verb = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ResourceAttributes) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ResourceAttributes: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ResourceAttributes: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Verb", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Verb = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Group", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Group = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Version = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resource = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Subresource", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Subresource = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SelfSubjectAccessReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SelfSubjectAccessReview: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SelfSubjectAccessReview: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SelfSubjectAccessReviewSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SelfSubjectAccessReviewSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SelfSubjectAccessReviewSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceAttributes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ResourceAttributes == nil { + m.ResourceAttributes = &ResourceAttributes{} + } + if err := m.ResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NonResourceAttributes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.NonResourceAttributes == nil { + m.NonResourceAttributes = &NonResourceAttributes{} + } + if err := m.NonResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SubjectAccessReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SubjectAccessReview: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SubjectAccessReview: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SubjectAccessReviewSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SubjectAccessReviewSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SubjectAccessReviewSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceAttributes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ResourceAttributes == nil { + m.ResourceAttributes = &ResourceAttributes{} + } + if err := m.ResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NonResourceAttributes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.NonResourceAttributes == nil { + m.NonResourceAttributes = &NonResourceAttributes{} + } + if err := m.NonResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field User", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.User = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Groups", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Groups = append(m.Groups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Extra", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Extra == nil { + m.Extra = make(map[string]ExtraValue) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &ExtraValue{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Extra[mapkey] = *mapvalue + } else { + var mapvalue ExtraValue + m.Extra[mapkey] = mapvalue + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SubjectAccessReviewStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SubjectAccessReviewStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SubjectAccessReviewStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Allowed", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.Allowed = bool(v != 0) + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EvaluationError", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.EvaluationError = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/authorization/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 885 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xdc, 0x44, + 0x14, 0x5f, 0xef, 0xbf, 0xec, 0x4e, 0x80, 0x94, 0xa9, 0x4a, 0xdc, 0x20, 0x79, 0x57, 0x8b, 0x84, + 0x82, 0x00, 0x9b, 0x94, 0x3f, 0xad, 0xca, 0x01, 0xc5, 0x22, 0xfc, 0x91, 0x68, 0x8b, 0x26, 0x22, + 0x07, 0xb8, 0x30, 0x76, 0x5e, 0x76, 0xdd, 0xdd, 0xf5, 0x98, 0x99, 0xb1, 0x4b, 0x38, 0xf5, 0xc6, + 0x15, 0x89, 0x0b, 0x47, 0xbe, 0x02, 0x1f, 0x00, 0xce, 0xb9, 0xd1, 0x03, 0x12, 0x3d, 0xa0, 0x15, + 0x31, 0x17, 0x3e, 0x06, 0x9a, 0xf1, 0x64, 0x9d, 0x6d, 0x1c, 0xaa, 0x85, 0x4a, 0x70, 0xc8, 0xcd, + 0xf3, 0xde, 0xef, 0xf7, 0xde, 0x6f, 0xde, 0xbc, 0xf1, 0x1b, 0xf4, 0xf6, 0xf8, 0x86, 0x70, 0x23, + 0xe6, 0x8d, 0xd3, 0x00, 0x78, 0x0c, 0x12, 0x84, 0x97, 0x8c, 0x87, 0x1e, 0x4d, 0x22, 0xe1, 0xd1, + 0x54, 0x8e, 0x18, 0x8f, 0xbe, 0xa2, 0x32, 0x62, 0xb1, 0x97, 0x6d, 0x79, 0x43, 0x88, 0x81, 0x53, + 0x09, 0xfb, 0x6e, 0xc2, 0x99, 0x64, 0xf8, 0xe5, 0x82, 0xec, 0x96, 0x64, 0x37, 0x19, 0x0f, 0x5d, + 0x45, 0x76, 0x17, 0xc8, 0x6e, 0xb6, 0xb5, 0xf1, 0xea, 0x30, 0x92, 0xa3, 0x34, 0x70, 0x43, 0x36, + 0xf5, 0x86, 0x6c, 0xc8, 0x3c, 0x1d, 0x23, 0x48, 0x0f, 0xf4, 0x4a, 0x2f, 0xf4, 0x57, 0x11, 0x7b, + 0xe3, 0x0d, 0x23, 0x8c, 0x26, 0xd1, 0x94, 0x86, 0xa3, 0x28, 0x06, 0x7e, 0x58, 0x4a, 0x9b, 0x82, + 0xa4, 0x15, 0x8a, 0x36, 0xbc, 0xf3, 0x58, 0x3c, 0x8d, 0x65, 0x34, 0x85, 0x33, 0x84, 0xb7, 0x1e, + 0x47, 0x10, 0xe1, 0x08, 0xa6, 0xf4, 0x0c, 0xef, 0xf5, 0xf3, 0x78, 0xa9, 0x8c, 0x26, 0x5e, 0x14, + 0x4b, 0x21, 0xf9, 0xa3, 0xa4, 0xc1, 0x75, 0x84, 0x76, 0xbe, 0x94, 0x9c, 0xee, 0xd1, 0x49, 0x0a, + 0xb8, 0x87, 0x5a, 0x91, 0x84, 0xa9, 0xb0, 0xad, 0x7e, 0x63, 0xb3, 0xeb, 0x77, 0xf3, 0x59, 0xaf, + 0xf5, 0xa1, 0x32, 0x90, 0xc2, 0x7e, 0xb3, 0xf3, 0xdd, 0xf7, 0xbd, 0xda, 0xfd, 0xdf, 0xfa, 0xb5, + 0xc1, 0x2f, 0x75, 0x64, 0x7f, 0xc4, 0x42, 0x3a, 0xd9, 0x4d, 0x83, 0xbb, 0x10, 0xca, 0xed, 0x30, + 0x04, 0x21, 0x08, 0x64, 0x11, 0xdc, 0xc3, 0x9f, 0xa3, 0x8e, 0x2a, 0xc7, 0x3e, 0x95, 0xd4, 0xb6, + 0xfa, 0xd6, 0xe6, 0xea, 0xb5, 0xd7, 0x5c, 0x73, 0x30, 0xa7, 0xd5, 0x95, 0x47, 0xa3, 0xd0, 0x6e, + 0xb6, 0xe5, 0xde, 0xd1, 0xb1, 0x6e, 0x81, 0xa4, 0x3e, 0x3e, 0x9a, 0xf5, 0x6a, 0xf9, 0xac, 0x87, + 0x4a, 0x1b, 0x99, 0x47, 0xc5, 0x07, 0xa8, 0x29, 0x12, 0x08, 0xed, 0xba, 0x8e, 0xfe, 0xae, 0xbb, + 0xc4, 0xb1, 0xbb, 0x15, 0x8a, 0x77, 0x13, 0x08, 0xfd, 0xa7, 0x4c, 0xc6, 0xa6, 0x5a, 0x11, 0x1d, + 0x1f, 0xc7, 0xa8, 0x2d, 0x24, 0x95, 0xa9, 0xb0, 0x1b, 0x3a, 0xd3, 0x7b, 0xff, 0x3a, 0x93, 0x8e, + 0xe6, 0x3f, 0x63, 0x72, 0xb5, 0x8b, 0x35, 0x31, 0x59, 0x06, 0x9f, 0xa1, 0x2b, 0xb7, 0x59, 0x4c, + 0x40, 0xb0, 0x94, 0x87, 0xb0, 0x2d, 0x25, 0x8f, 0x82, 0x54, 0x82, 0xc0, 0x7d, 0xd4, 0x4c, 0xa8, + 0x1c, 0xe9, 0x72, 0x76, 0x4b, 0xa9, 0x1f, 0x53, 0x39, 0x22, 0xda, 0xa3, 0x10, 0x19, 0xf0, 0x40, + 0x97, 0xe4, 0x14, 0x62, 0x0f, 0x78, 0x40, 0xb4, 0x67, 0xf0, 0x53, 0x1d, 0xe1, 0x8a, 0xd0, 0x1e, + 0xea, 0xc6, 0x74, 0x0a, 0x22, 0xa1, 0x21, 0x98, 0xf8, 0xcf, 0x1a, 0x76, 0xf7, 0xf6, 0x89, 0x83, + 0x94, 0x98, 0xc7, 0x67, 0xc2, 0x2f, 0xa0, 0xd6, 0x90, 0xb3, 0x34, 0xd1, 0x55, 0xeb, 0xfa, 0x4f, + 0x1b, 0x48, 0xeb, 0x7d, 0x65, 0x24, 0x85, 0x0f, 0xbf, 0x84, 0x56, 0x32, 0xe0, 0x22, 0x62, 0xb1, + 0xdd, 0xd4, 0xb0, 0x35, 0x03, 0x5b, 0xd9, 0x2b, 0xcc, 0xe4, 0xc4, 0x8f, 0x5f, 0x41, 0x1d, 0x6e, + 0x84, 0xdb, 0x2d, 0x8d, 0xbd, 0x64, 0xb0, 0x9d, 0x93, 0x0d, 0x91, 0x39, 0x02, 0xbf, 0x89, 0x56, + 0x45, 0x1a, 0xcc, 0x09, 0x6d, 0x4d, 0xb8, 0x6c, 0x08, 0xab, 0xbb, 0xa5, 0x8b, 0x9c, 0xc6, 0xa9, + 0x6d, 0xa9, 0x3d, 0xda, 0x2b, 0x8b, 0xdb, 0x52, 0x25, 0x20, 0xda, 0x33, 0xf8, 0xb5, 0x8e, 0xd6, + 0x77, 0x61, 0x72, 0xf0, 0xdf, 0xf4, 0xfc, 0xdd, 0x85, 0x9e, 0xff, 0x60, 0xb9, 0x4e, 0xac, 0x56, + 0xfd, 0xbf, 0xe9, 0xfb, 0x1f, 0xeb, 0xe8, 0xf9, 0xbf, 0xd1, 0x88, 0xbf, 0xb6, 0x10, 0xe6, 0x67, + 0x5a, 0xd7, 0x14, 0xfa, 0x9d, 0xa5, 0xc4, 0x9d, 0xbd, 0x01, 0xfe, 0x73, 0xf9, 0xac, 0x57, 0x71, + 0x33, 0x48, 0x45, 0x4a, 0xfc, 0xad, 0x85, 0xae, 0xc4, 0x55, 0x57, 0xd4, 0x9c, 0x8b, 0xbf, 0x94, + 0x98, 0xca, 0xcb, 0xee, 0x5f, 0xcd, 0x67, 0xbd, 0xea, 0xff, 0x00, 0xa9, 0xce, 0x3d, 0xf8, 0xb9, + 0x8e, 0x2e, 0x5f, 0xfc, 0x89, 0x9f, 0x64, 0x47, 0xfe, 0xd9, 0x44, 0xeb, 0x17, 0xdd, 0xf8, 0x8f, + 0xba, 0x71, 0x3e, 0x20, 0x1a, 0x8b, 0x7f, 0xd2, 0x4f, 0x04, 0x70, 0x33, 0x20, 0x06, 0xa8, 0xad, + 0x87, 0x80, 0xb0, 0x9b, 0xfa, 0xa9, 0x81, 0xd4, 0x09, 0xe8, 0xe9, 0x20, 0x88, 0xf1, 0x60, 0x89, + 0x5a, 0xa0, 0xde, 0x26, 0x76, 0xab, 0xdf, 0xd8, 0x5c, 0xbd, 0x76, 0xe7, 0x49, 0xb4, 0x96, 0xab, + 0x5f, 0x3b, 0x3b, 0xb1, 0xe4, 0x87, 0xe5, 0x54, 0xd2, 0x36, 0x52, 0x24, 0xdb, 0xf8, 0xc2, 0xbc, + 0x88, 0x34, 0x06, 0x5f, 0x42, 0x8d, 0x31, 0x1c, 0x16, 0x53, 0x91, 0xa8, 0x4f, 0x7c, 0x0b, 0xb5, + 0x32, 0xf5, 0x58, 0x32, 0x05, 0xbe, 0xbe, 0x94, 0xaa, 0xf2, 0xad, 0x45, 0x8a, 0x28, 0x37, 0xeb, + 0x37, 0xac, 0xc1, 0x0f, 0x16, 0xba, 0x7a, 0x6e, 0x83, 0xaa, 0x31, 0x49, 0x27, 0x13, 0x76, 0x0f, + 0xf6, 0xb5, 0x8c, 0x4e, 0x39, 0x26, 0xb7, 0x0b, 0x33, 0x39, 0xf1, 0xe3, 0x17, 0x51, 0x9b, 0x03, + 0x15, 0x2c, 0x36, 0xa3, 0x79, 0xde, 0xdb, 0x44, 0x5b, 0x89, 0xf1, 0xe2, 0x6d, 0xb4, 0x06, 0x2a, + 0xbd, 0xd6, 0xb5, 0xc3, 0x39, 0xe3, 0xe6, 0xa8, 0xd6, 0x0d, 0x61, 0x6d, 0x67, 0xd1, 0x4d, 0x1e, + 0xc5, 0xfb, 0x9b, 0x47, 0xc7, 0x4e, 0xed, 0xc1, 0xb1, 0x53, 0x7b, 0x78, 0xec, 0xd4, 0xee, 0xe7, + 0x8e, 0x75, 0x94, 0x3b, 0xd6, 0x83, 0xdc, 0xb1, 0x1e, 0xe6, 0x8e, 0xf5, 0x7b, 0xee, 0x58, 0xdf, + 0xfc, 0xe1, 0xd4, 0x3e, 0xad, 0x67, 0x5b, 0x7f, 0x05, 0x00, 0x00, 0xff, 0xff, 0x38, 0xb6, 0x9a, + 0xe3, 0xd0, 0x0b, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto new file mode 100644 index 0000000000..9048e4fa40 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/generated.proto @@ -0,0 +1,183 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.authorization.v1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// ExtraValue masks the value so protobuf can generate +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +message ExtraValue { + // items, if empty, will result in an empty slice + + repeated string items = 1; +} + +// LocalSubjectAccessReview checks whether or not a user or group can perform an action in a given namespace. +// Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions +// checking. +message LocalSubjectAccessReview { + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace + // you made the request against. If empty, it is defaulted. + optional SubjectAccessReviewSpec spec = 2; + + // Status is filled in by the server and indicates whether the request is allowed or not + // +optional + optional SubjectAccessReviewStatus status = 3; +} + +// NonResourceAttributes includes the authorization attributes available for non-resource requests to the Authorizer interface +message NonResourceAttributes { + // Path is the URL path of the request + // +optional + optional string path = 1; + + // Verb is the standard HTTP verb + // +optional + optional string verb = 2; +} + +// ResourceAttributes includes the authorization attributes available for resource requests to the Authorizer interface +message ResourceAttributes { + // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces + // "" (empty) is defaulted for LocalSubjectAccessReviews + // "" (empty) is empty for cluster-scoped resources + // "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview + // +optional + optional string namespace = 1; + + // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. + // +optional + optional string verb = 2; + + // Group is the API Group of the Resource. "*" means all. + // +optional + optional string group = 3; + + // Version is the API Version of the Resource. "*" means all. + // +optional + optional string version = 4; + + // Resource is one of the existing resource types. "*" means all. + // +optional + optional string resource = 5; + + // Subresource is one of the existing resource types. "" means none. + // +optional + optional string subresource = 6; + + // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. + // +optional + optional string name = 7; +} + +// SelfSubjectAccessReview checks whether or the current user can perform an action. Not filling in a +// spec.namespace means "in all namespaces". Self is a special case, because users should always be able +// to check whether they can perform an action +message SelfSubjectAccessReview { + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Spec holds information about the request being evaluated. user and groups must be empty + optional SelfSubjectAccessReviewSpec spec = 2; + + // Status is filled in by the server and indicates whether the request is allowed or not + // +optional + optional SubjectAccessReviewStatus status = 3; +} + +// SelfSubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes +// and NonResourceAuthorizationAttributes must be set +message SelfSubjectAccessReviewSpec { + // ResourceAuthorizationAttributes describes information for a resource access request + // +optional + optional ResourceAttributes resourceAttributes = 1; + + // NonResourceAttributes describes information for a non-resource access request + // +optional + optional NonResourceAttributes nonResourceAttributes = 2; +} + +// SubjectAccessReview checks whether or not a user or group can perform an action. +message SubjectAccessReview { + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Spec holds information about the request being evaluated + optional SubjectAccessReviewSpec spec = 2; + + // Status is filled in by the server and indicates whether the request is allowed or not + // +optional + optional SubjectAccessReviewStatus status = 3; +} + +// SubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes +// and NonResourceAuthorizationAttributes must be set +message SubjectAccessReviewSpec { + // ResourceAuthorizationAttributes describes information for a resource access request + // +optional + optional ResourceAttributes resourceAttributes = 1; + + // NonResourceAttributes describes information for a non-resource access request + // +optional + optional NonResourceAttributes nonResourceAttributes = 2; + + // User is the user you're testing for. + // If you specify "User" but not "Groups", then is it interpreted as "What if User were not a member of any groups + // +optional + optional string verb = 3; + + // Groups is the groups you're testing for. + // +optional + repeated string groups = 4; + + // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer + // it needs a reflection here. + // +optional + map extra = 5; +} + +// SubjectAccessReviewStatus +message SubjectAccessReviewStatus { + // Allowed is required. True if the action would be allowed, false otherwise. + optional bool allowed = 1; + + // Reason is optional. It indicates why a request was allowed or denied. + // +optional + optional string reason = 2; + + // EvaluationError is an indication that some error occurred during the authorization check. + // It is entirely possible to get an error and be able to continue determine authorization status in spite of it. + // For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request. + // +optional + optional string evaluationError = 3; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/register.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/register.go new file mode 100644 index 0000000000..5defdff675 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/register.go @@ -0,0 +1,61 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "authorization.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &SelfSubjectAccessReview{}, + &SubjectAccessReview{}, + &LocalSubjectAccessReview{}, + ) + + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.generated.go new file mode 100644 index 0000000000..2528afa8e8 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.generated.go @@ -0,0 +1,3233 @@ +/* +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" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + "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 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 + } +} + +func (x *SubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *SubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *SubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = SubjectAccessReviewSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = SubjectAccessReviewStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = SubjectAccessReviewSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = SubjectAccessReviewStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *SelfSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *SelfSubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *SelfSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = SelfSubjectAccessReviewSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = SubjectAccessReviewStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = SelfSubjectAccessReviewSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = SubjectAccessReviewStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *LocalSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *LocalSubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *LocalSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = SubjectAccessReviewSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = SubjectAccessReviewStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = SubjectAccessReviewSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = SubjectAccessReviewStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Namespace != "" + yyq2[1] = x.Verb != "" + yyq2[2] = x.Group != "" + yyq2[3] = x.Version != "" + yyq2[4] = x.Resource != "" + yyq2[5] = x.Subresource != "" + yyq2[6] = x.Name != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("verb")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Group)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("group")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Group)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Version)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("version")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Version)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("subresource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ResourceAttributes) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv4 := &x.Namespace + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "verb": + if r.TryDecodeAsNil() { + x.Verb = "" + } else { + yyv6 := &x.Verb + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "group": + if r.TryDecodeAsNil() { + x.Group = "" + } else { + yyv8 := &x.Group + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "version": + if r.TryDecodeAsNil() { + x.Version = "" + } else { + yyv10 := &x.Version + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "resource": + if r.TryDecodeAsNil() { + x.Resource = "" + } else { + yyv12 := &x.Resource + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + case "subresource": + if r.TryDecodeAsNil() { + x.Subresource = "" + } else { + yyv14 := &x.Subresource + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv16 := &x.Name + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv19 := &x.Namespace + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Verb = "" + } else { + yyv21 := &x.Verb + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Group = "" + } else { + yyv23 := &x.Group + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Version = "" + } else { + yyv25 := &x.Version + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resource = "" + } else { + yyv27 := &x.Resource + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Subresource = "" + } else { + yyv29 := &x.Subresource + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } + } + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv31 := &x.Name + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } + } + for { + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l + } else { + yyb18 = r.CheckBreak() + } + if yyb18 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj18-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NonResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Path != "" + yyq2[1] = x.Verb != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("path")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Path)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("verb")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NonResourceAttributes) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NonResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "path": + if r.TryDecodeAsNil() { + x.Path = "" + } else { + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "verb": + if r.TryDecodeAsNil() { + x.Verb = "" + } else { + yyv6 := &x.Verb + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NonResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Path = "" + } else { + yyv9 := &x.Path + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Verb = "" + } else { + yyv11 := &x.Verb + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ResourceAttributes != nil + yyq2[1] = x.NonResourceAttributes != nil + yyq2[2] = x.User != "" + yyq2[3] = len(x.Groups) != 0 + yyq2[4] = len(x.Extra) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.ResourceAttributes == nil { + r.EncodeNil() + } else { + x.ResourceAttributes.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resourceAttributes")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ResourceAttributes == nil { + r.EncodeNil() + } else { + x.ResourceAttributes.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.NonResourceAttributes == nil { + r.EncodeNil() + } else { + x.NonResourceAttributes.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("nonResourceAttributes")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.NonResourceAttributes == nil { + r.EncodeNil() + } else { + x.NonResourceAttributes.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.User)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("user")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.User)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Groups == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("groups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Groups == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.Extra == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("extra")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Extra == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *SubjectAccessReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *SubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "resourceAttributes": + if r.TryDecodeAsNil() { + if x.ResourceAttributes != nil { + x.ResourceAttributes = nil + } + } else { + if x.ResourceAttributes == nil { + x.ResourceAttributes = new(ResourceAttributes) + } + x.ResourceAttributes.CodecDecodeSelf(d) + } + case "nonResourceAttributes": + if r.TryDecodeAsNil() { + if x.NonResourceAttributes != nil { + x.NonResourceAttributes = nil + } + } else { + if x.NonResourceAttributes == nil { + x.NonResourceAttributes = new(NonResourceAttributes) + } + x.NonResourceAttributes.CodecDecodeSelf(d) + } + case "user": + if r.TryDecodeAsNil() { + x.User = "" + } else { + yyv6 := &x.User + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "groups": + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv8 := &x.Groups + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "extra": + if r.TryDecodeAsNil() { + x.Extra = nil + } else { + yyv10 := &x.Extra + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ResourceAttributes != nil { + x.ResourceAttributes = nil + } + } else { + if x.ResourceAttributes == nil { + x.ResourceAttributes = new(ResourceAttributes) + } + x.ResourceAttributes.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.NonResourceAttributes != nil { + x.NonResourceAttributes = nil + } + } else { + if x.NonResourceAttributes == nil { + x.NonResourceAttributes = new(NonResourceAttributes) + } + x.NonResourceAttributes.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.User = "" + } else { + yyv15 := &x.User + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv17 := &x.Groups + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Extra = nil + } else { + yyv19 := &x.Extra + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x ExtraValue) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + h.encExtraValue((ExtraValue)(x), e) + } + } +} + +func (x *ExtraValue) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + h.decExtraValue((*ExtraValue)(x), d) + } +} + +func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ResourceAttributes != nil + yyq2[1] = x.NonResourceAttributes != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.ResourceAttributes == nil { + r.EncodeNil() + } else { + x.ResourceAttributes.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resourceAttributes")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ResourceAttributes == nil { + r.EncodeNil() + } else { + x.ResourceAttributes.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.NonResourceAttributes == nil { + r.EncodeNil() + } else { + x.NonResourceAttributes.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("nonResourceAttributes")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.NonResourceAttributes == nil { + r.EncodeNil() + } else { + x.NonResourceAttributes.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *SelfSubjectAccessReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "resourceAttributes": + if r.TryDecodeAsNil() { + if x.ResourceAttributes != nil { + x.ResourceAttributes = nil + } + } else { + if x.ResourceAttributes == nil { + x.ResourceAttributes = new(ResourceAttributes) + } + x.ResourceAttributes.CodecDecodeSelf(d) + } + case "nonResourceAttributes": + if r.TryDecodeAsNil() { + if x.NonResourceAttributes != nil { + x.NonResourceAttributes = nil + } + } else { + if x.NonResourceAttributes == nil { + x.NonResourceAttributes = new(NonResourceAttributes) + } + x.NonResourceAttributes.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ResourceAttributes != nil { + x.ResourceAttributes = nil + } + } else { + if x.ResourceAttributes == nil { + x.ResourceAttributes = new(ResourceAttributes) + } + x.ResourceAttributes.CodecDecodeSelf(d) + } + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.NonResourceAttributes != nil { + x.NonResourceAttributes = nil + } + } else { + if x.NonResourceAttributes == nil { + x.NonResourceAttributes = new(NonResourceAttributes) + } + x.NonResourceAttributes.CodecDecodeSelf(d) + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *SubjectAccessReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Reason != "" + yyq2[2] = x.EvaluationError != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeBool(bool(x.Allowed)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("allowed")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeBool(bool(x.Allowed)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("reason")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.EvaluationError)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("evaluationError")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.EvaluationError)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *SubjectAccessReviewStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *SubjectAccessReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "allowed": + if r.TryDecodeAsNil() { + x.Allowed = false + } else { + yyv4 := &x.Allowed + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } + } + case "reason": + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv6 := &x.Reason + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "evaluationError": + if r.TryDecodeAsNil() { + x.EvaluationError = "" + } else { + yyv8 := &x.EvaluationError + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *SubjectAccessReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Allowed = false + } else { + yyv11 := &x.Allowed + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(yyv11)) = r.DecodeBool() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv13 := &x.Reason + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.EvaluationError = "" + } else { + yyv15 := &x.EvaluationError + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encMapstringExtraValue(v map[string]ExtraValue, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x codecSelfer1234) decMapstringExtraValue(v *map[string]ExtraValue, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string]ExtraValue, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 ExtraValue + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey1234) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue1234) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv4 := &yymv1 + yyv4.CodecDecodeSelf(d) + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey1234) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue1234) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv7 := &yymv1 + yyv7.CodecDecodeSelf(d) + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x codecSelfer1234) encExtraValue(v ExtraValue, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yyv1)) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]string, yyrl1) + } + } else { + yyv1 = make([]string, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 string + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.go new file mode 100644 index 0000000000..38c314ffcf --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types.go @@ -0,0 +1,176 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "fmt" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true +// +nonNamespaced=true +// +noMethods=true + +// SubjectAccessReview checks whether or not a user or group can perform an action. +type SubjectAccessReview struct { + metav1.TypeMeta `json:",inline"` + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Spec holds information about the request being evaluated + Spec SubjectAccessReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` + + // Status is filled in by the server and indicates whether the request is allowed or not + // +optional + Status SubjectAccessReviewStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// +genclient=true +// +nonNamespaced=true +// +noMethods=true + +// SelfSubjectAccessReview checks whether or the current user can perform an action. Not filling in a +// spec.namespace means "in all namespaces". Self is a special case, because users should always be able +// to check whether they can perform an action +type SelfSubjectAccessReview struct { + metav1.TypeMeta `json:",inline"` + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Spec holds information about the request being evaluated. user and groups must be empty + Spec SelfSubjectAccessReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` + + // Status is filled in by the server and indicates whether the request is allowed or not + // +optional + Status SubjectAccessReviewStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// +genclient=true +// +noMethods=true + +// LocalSubjectAccessReview checks whether or not a user or group can perform an action in a given namespace. +// Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions +// checking. +type LocalSubjectAccessReview struct { + metav1.TypeMeta `json:",inline"` + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace + // you made the request against. If empty, it is defaulted. + Spec SubjectAccessReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` + + // Status is filled in by the server and indicates whether the request is allowed or not + // +optional + Status SubjectAccessReviewStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// ResourceAttributes includes the authorization attributes available for resource requests to the Authorizer interface +type ResourceAttributes struct { + // Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces + // "" (empty) is defaulted for LocalSubjectAccessReviews + // "" (empty) is empty for cluster-scoped resources + // "" (empty) means "all" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview + // +optional + Namespace string `json:"namespace,omitempty" protobuf:"bytes,1,opt,name=namespace"` + // Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. "*" means all. + // +optional + Verb string `json:"verb,omitempty" protobuf:"bytes,2,opt,name=verb"` + // Group is the API Group of the Resource. "*" means all. + // +optional + Group string `json:"group,omitempty" protobuf:"bytes,3,opt,name=group"` + // Version is the API Version of the Resource. "*" means all. + // +optional + Version string `json:"version,omitempty" protobuf:"bytes,4,opt,name=version"` + // Resource is one of the existing resource types. "*" means all. + // +optional + Resource string `json:"resource,omitempty" protobuf:"bytes,5,opt,name=resource"` + // Subresource is one of the existing resource types. "" means none. + // +optional + Subresource string `json:"subresource,omitempty" protobuf:"bytes,6,opt,name=subresource"` + // Name is the name of the resource being requested for a "get" or deleted for a "delete". "" (empty) means all. + // +optional + Name string `json:"name,omitempty" protobuf:"bytes,7,opt,name=name"` +} + +// NonResourceAttributes includes the authorization attributes available for non-resource requests to the Authorizer interface +type NonResourceAttributes struct { + // Path is the URL path of the request + // +optional + Path string `json:"path,omitempty" protobuf:"bytes,1,opt,name=path"` + // Verb is the standard HTTP verb + // +optional + Verb string `json:"verb,omitempty" protobuf:"bytes,2,opt,name=verb"` +} + +// SubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes +// and NonResourceAuthorizationAttributes must be set +type SubjectAccessReviewSpec struct { + // ResourceAuthorizationAttributes describes information for a resource access request + // +optional + ResourceAttributes *ResourceAttributes `json:"resourceAttributes,omitempty" protobuf:"bytes,1,opt,name=resourceAttributes"` + // NonResourceAttributes describes information for a non-resource access request + // +optional + NonResourceAttributes *NonResourceAttributes `json:"nonResourceAttributes,omitempty" protobuf:"bytes,2,opt,name=nonResourceAttributes"` + + // User is the user you're testing for. + // If you specify "User" but not "Groups", then is it interpreted as "What if User were not a member of any groups + // +optional + User string `json:"user,omitempty" protobuf:"bytes,3,opt,name=verb"` + // Groups is the groups you're testing for. + // +optional + Groups []string `json:"groups,omitempty" protobuf:"bytes,4,rep,name=groups"` + // Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer + // it needs a reflection here. + // +optional + Extra map[string]ExtraValue `json:"extra,omitempty" protobuf:"bytes,5,rep,name=extra"` +} + +// ExtraValue masks the value so protobuf can generate +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +type ExtraValue []string + +func (t ExtraValue) String() string { + return fmt.Sprintf("%v", []string(t)) +} + +// SelfSubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes +// and NonResourceAuthorizationAttributes must be set +type SelfSubjectAccessReviewSpec struct { + // ResourceAuthorizationAttributes describes information for a resource access request + // +optional + ResourceAttributes *ResourceAttributes `json:"resourceAttributes,omitempty" protobuf:"bytes,1,opt,name=resourceAttributes"` + // NonResourceAttributes describes information for a non-resource access request + // +optional + NonResourceAttributes *NonResourceAttributes `json:"nonResourceAttributes,omitempty" protobuf:"bytes,2,opt,name=nonResourceAttributes"` +} + +// SubjectAccessReviewStatus +type SubjectAccessReviewStatus struct { + // Allowed is required. True if the action would be allowed, false otherwise. + Allowed bool `json:"allowed" protobuf:"varint,1,opt,name=allowed"` + // Reason is optional. It indicates why a request was allowed or denied. + // +optional + Reason string `json:"reason,omitempty" protobuf:"bytes,2,opt,name=reason"` + // EvaluationError is an indication that some error occurred during the authorization check. + // It is entirely possible to get an error and be able to continue determine authorization status in spite of it. + // For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request. + // +optional + EvaluationError string `json:"evaluationError,omitempty" protobuf:"bytes,3,opt,name=evaluationError"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..33c0035b48 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/types_swagger_doc_generated.go @@ -0,0 +1,119 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_LocalSubjectAccessReview = map[string]string{ + "": "LocalSubjectAccessReview checks whether or not a user or group can perform an action in a given namespace. Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions checking.", + "spec": "Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace you made the request against. If empty, it is defaulted.", + "status": "Status is filled in by the server and indicates whether the request is allowed or not", +} + +func (LocalSubjectAccessReview) SwaggerDoc() map[string]string { + return map_LocalSubjectAccessReview +} + +var map_NonResourceAttributes = map[string]string{ + "": "NonResourceAttributes includes the authorization attributes available for non-resource requests to the Authorizer interface", + "path": "Path is the URL path of the request", + "verb": "Verb is the standard HTTP verb", +} + +func (NonResourceAttributes) SwaggerDoc() map[string]string { + return map_NonResourceAttributes +} + +var map_ResourceAttributes = map[string]string{ + "": "ResourceAttributes includes the authorization attributes available for resource requests to the Authorizer interface", + "namespace": "Namespace is the namespace of the action being requested. Currently, there is no distinction between no namespace and all namespaces \"\" (empty) is defaulted for LocalSubjectAccessReviews \"\" (empty) is empty for cluster-scoped resources \"\" (empty) means \"all\" for namespace scoped resources from a SubjectAccessReview or SelfSubjectAccessReview", + "verb": "Verb is a kubernetes resource API verb, like: get, list, watch, create, update, delete, proxy. \"*\" means all.", + "group": "Group is the API Group of the Resource. \"*\" means all.", + "version": "Version is the API Version of the Resource. \"*\" means all.", + "resource": "Resource is one of the existing resource types. \"*\" means all.", + "subresource": "Subresource is one of the existing resource types. \"\" means none.", + "name": "Name is the name of the resource being requested for a \"get\" or deleted for a \"delete\". \"\" (empty) means all.", +} + +func (ResourceAttributes) SwaggerDoc() map[string]string { + return map_ResourceAttributes +} + +var map_SelfSubjectAccessReview = map[string]string{ + "": "SelfSubjectAccessReview checks whether or the current user can perform an action. Not filling in a spec.namespace means \"in all namespaces\". Self is a special case, because users should always be able to check whether they can perform an action", + "spec": "Spec holds information about the request being evaluated. user and groups must be empty", + "status": "Status is filled in by the server and indicates whether the request is allowed or not", +} + +func (SelfSubjectAccessReview) SwaggerDoc() map[string]string { + return map_SelfSubjectAccessReview +} + +var map_SelfSubjectAccessReviewSpec = map[string]string{ + "": "SelfSubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes and NonResourceAuthorizationAttributes must be set", + "resourceAttributes": "ResourceAuthorizationAttributes describes information for a resource access request", + "nonResourceAttributes": "NonResourceAttributes describes information for a non-resource access request", +} + +func (SelfSubjectAccessReviewSpec) SwaggerDoc() map[string]string { + return map_SelfSubjectAccessReviewSpec +} + +var map_SubjectAccessReview = map[string]string{ + "": "SubjectAccessReview checks whether or not a user or group can perform an action.", + "spec": "Spec holds information about the request being evaluated", + "status": "Status is filled in by the server and indicates whether the request is allowed or not", +} + +func (SubjectAccessReview) SwaggerDoc() map[string]string { + return map_SubjectAccessReview +} + +var map_SubjectAccessReviewSpec = map[string]string{ + "": "SubjectAccessReviewSpec is a description of the access request. Exactly one of ResourceAuthorizationAttributes and NonResourceAuthorizationAttributes must be set", + "resourceAttributes": "ResourceAuthorizationAttributes describes information for a resource access request", + "nonResourceAttributes": "NonResourceAttributes describes information for a non-resource access request", + "user": "User is the user you're testing for. If you specify \"User\" but not \"Groups\", then is it interpreted as \"What if User were not a member of any groups", + "groups": "Groups is the groups you're testing for.", + "extra": "Extra corresponds to the user.Info.GetExtra() method from the authenticator. Since that is input to the authorizer it needs a reflection here.", +} + +func (SubjectAccessReviewSpec) SwaggerDoc() map[string]string { + return map_SubjectAccessReviewSpec +} + +var map_SubjectAccessReviewStatus = map[string]string{ + "": "SubjectAccessReviewStatus", + "allowed": "Allowed is required. True if the action would be allowed, false otherwise.", + "reason": "Reason is optional. It indicates why a request was allowed or denied.", + "evaluationError": "EvaluationError is an indication that some error occurred during the authorization check. It is entirely possible to get an error and be able to continue determine authorization status in spite of it. For instance, RBAC can be missing a role, but enough roles are still present and bound to reason about the request.", +} + +func (SubjectAccessReviewStatus) SwaggerDoc() map[string]string { + return map_SubjectAccessReviewStatus +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.conversion.go new file mode 100644 index 0000000000..97ebf559a6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.conversion.go @@ -0,0 +1,279 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + authorization "k8s.io/client-go/pkg/apis/authorization" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview, + Convert_authorization_LocalSubjectAccessReview_To_v1_LocalSubjectAccessReview, + Convert_v1_NonResourceAttributes_To_authorization_NonResourceAttributes, + Convert_authorization_NonResourceAttributes_To_v1_NonResourceAttributes, + Convert_v1_ResourceAttributes_To_authorization_ResourceAttributes, + Convert_authorization_ResourceAttributes_To_v1_ResourceAttributes, + Convert_v1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview, + Convert_authorization_SelfSubjectAccessReview_To_v1_SelfSubjectAccessReview, + Convert_v1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec, + Convert_authorization_SelfSubjectAccessReviewSpec_To_v1_SelfSubjectAccessReviewSpec, + Convert_v1_SubjectAccessReview_To_authorization_SubjectAccessReview, + Convert_authorization_SubjectAccessReview_To_v1_SubjectAccessReview, + Convert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec, + Convert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec, + Convert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus, + Convert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus, + ) +} + +func autoConvert_v1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview(in *LocalSubjectAccessReview, out *authorization.LocalSubjectAccessReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview is an autogenerated conversion function. +func Convert_v1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview(in *LocalSubjectAccessReview, out *authorization.LocalSubjectAccessReview, s conversion.Scope) error { + return autoConvert_v1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview(in, out, s) +} + +func autoConvert_authorization_LocalSubjectAccessReview_To_v1_LocalSubjectAccessReview(in *authorization.LocalSubjectAccessReview, out *LocalSubjectAccessReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_authorization_LocalSubjectAccessReview_To_v1_LocalSubjectAccessReview is an autogenerated conversion function. +func Convert_authorization_LocalSubjectAccessReview_To_v1_LocalSubjectAccessReview(in *authorization.LocalSubjectAccessReview, out *LocalSubjectAccessReview, s conversion.Scope) error { + return autoConvert_authorization_LocalSubjectAccessReview_To_v1_LocalSubjectAccessReview(in, out, s) +} + +func autoConvert_v1_NonResourceAttributes_To_authorization_NonResourceAttributes(in *NonResourceAttributes, out *authorization.NonResourceAttributes, s conversion.Scope) error { + out.Path = in.Path + out.Verb = in.Verb + return nil +} + +// Convert_v1_NonResourceAttributes_To_authorization_NonResourceAttributes is an autogenerated conversion function. +func Convert_v1_NonResourceAttributes_To_authorization_NonResourceAttributes(in *NonResourceAttributes, out *authorization.NonResourceAttributes, s conversion.Scope) error { + return autoConvert_v1_NonResourceAttributes_To_authorization_NonResourceAttributes(in, out, s) +} + +func autoConvert_authorization_NonResourceAttributes_To_v1_NonResourceAttributes(in *authorization.NonResourceAttributes, out *NonResourceAttributes, s conversion.Scope) error { + out.Path = in.Path + out.Verb = in.Verb + return nil +} + +// Convert_authorization_NonResourceAttributes_To_v1_NonResourceAttributes is an autogenerated conversion function. +func Convert_authorization_NonResourceAttributes_To_v1_NonResourceAttributes(in *authorization.NonResourceAttributes, out *NonResourceAttributes, s conversion.Scope) error { + return autoConvert_authorization_NonResourceAttributes_To_v1_NonResourceAttributes(in, out, s) +} + +func autoConvert_v1_ResourceAttributes_To_authorization_ResourceAttributes(in *ResourceAttributes, out *authorization.ResourceAttributes, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Verb = in.Verb + out.Group = in.Group + out.Version = in.Version + out.Resource = in.Resource + out.Subresource = in.Subresource + out.Name = in.Name + return nil +} + +// Convert_v1_ResourceAttributes_To_authorization_ResourceAttributes is an autogenerated conversion function. +func Convert_v1_ResourceAttributes_To_authorization_ResourceAttributes(in *ResourceAttributes, out *authorization.ResourceAttributes, s conversion.Scope) error { + return autoConvert_v1_ResourceAttributes_To_authorization_ResourceAttributes(in, out, s) +} + +func autoConvert_authorization_ResourceAttributes_To_v1_ResourceAttributes(in *authorization.ResourceAttributes, out *ResourceAttributes, s conversion.Scope) error { + out.Namespace = in.Namespace + out.Verb = in.Verb + out.Group = in.Group + out.Version = in.Version + out.Resource = in.Resource + out.Subresource = in.Subresource + out.Name = in.Name + return nil +} + +// Convert_authorization_ResourceAttributes_To_v1_ResourceAttributes is an autogenerated conversion function. +func Convert_authorization_ResourceAttributes_To_v1_ResourceAttributes(in *authorization.ResourceAttributes, out *ResourceAttributes, s conversion.Scope) error { + return autoConvert_authorization_ResourceAttributes_To_v1_ResourceAttributes(in, out, s) +} + +func autoConvert_v1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview(in *SelfSubjectAccessReview, out *authorization.SelfSubjectAccessReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview is an autogenerated conversion function. +func Convert_v1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview(in *SelfSubjectAccessReview, out *authorization.SelfSubjectAccessReview, s conversion.Scope) error { + return autoConvert_v1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview(in, out, s) +} + +func autoConvert_authorization_SelfSubjectAccessReview_To_v1_SelfSubjectAccessReview(in *authorization.SelfSubjectAccessReview, out *SelfSubjectAccessReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_authorization_SelfSubjectAccessReviewSpec_To_v1_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_authorization_SelfSubjectAccessReview_To_v1_SelfSubjectAccessReview is an autogenerated conversion function. +func Convert_authorization_SelfSubjectAccessReview_To_v1_SelfSubjectAccessReview(in *authorization.SelfSubjectAccessReview, out *SelfSubjectAccessReview, s conversion.Scope) error { + return autoConvert_authorization_SelfSubjectAccessReview_To_v1_SelfSubjectAccessReview(in, out, s) +} + +func autoConvert_v1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(in *SelfSubjectAccessReviewSpec, out *authorization.SelfSubjectAccessReviewSpec, s conversion.Scope) error { + out.ResourceAttributes = (*authorization.ResourceAttributes)(unsafe.Pointer(in.ResourceAttributes)) + out.NonResourceAttributes = (*authorization.NonResourceAttributes)(unsafe.Pointer(in.NonResourceAttributes)) + return nil +} + +// Convert_v1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec is an autogenerated conversion function. +func Convert_v1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(in *SelfSubjectAccessReviewSpec, out *authorization.SelfSubjectAccessReviewSpec, s conversion.Scope) error { + return autoConvert_v1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(in, out, s) +} + +func autoConvert_authorization_SelfSubjectAccessReviewSpec_To_v1_SelfSubjectAccessReviewSpec(in *authorization.SelfSubjectAccessReviewSpec, out *SelfSubjectAccessReviewSpec, s conversion.Scope) error { + out.ResourceAttributes = (*ResourceAttributes)(unsafe.Pointer(in.ResourceAttributes)) + out.NonResourceAttributes = (*NonResourceAttributes)(unsafe.Pointer(in.NonResourceAttributes)) + return nil +} + +// Convert_authorization_SelfSubjectAccessReviewSpec_To_v1_SelfSubjectAccessReviewSpec is an autogenerated conversion function. +func Convert_authorization_SelfSubjectAccessReviewSpec_To_v1_SelfSubjectAccessReviewSpec(in *authorization.SelfSubjectAccessReviewSpec, out *SelfSubjectAccessReviewSpec, s conversion.Scope) error { + return autoConvert_authorization_SelfSubjectAccessReviewSpec_To_v1_SelfSubjectAccessReviewSpec(in, out, s) +} + +func autoConvert_v1_SubjectAccessReview_To_authorization_SubjectAccessReview(in *SubjectAccessReview, out *authorization.SubjectAccessReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1_SubjectAccessReview_To_authorization_SubjectAccessReview is an autogenerated conversion function. +func Convert_v1_SubjectAccessReview_To_authorization_SubjectAccessReview(in *SubjectAccessReview, out *authorization.SubjectAccessReview, s conversion.Scope) error { + return autoConvert_v1_SubjectAccessReview_To_authorization_SubjectAccessReview(in, out, s) +} + +func autoConvert_authorization_SubjectAccessReview_To_v1_SubjectAccessReview(in *authorization.SubjectAccessReview, out *SubjectAccessReview, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_authorization_SubjectAccessReview_To_v1_SubjectAccessReview is an autogenerated conversion function. +func Convert_authorization_SubjectAccessReview_To_v1_SubjectAccessReview(in *authorization.SubjectAccessReview, out *SubjectAccessReview, s conversion.Scope) error { + return autoConvert_authorization_SubjectAccessReview_To_v1_SubjectAccessReview(in, out, s) +} + +func autoConvert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(in *SubjectAccessReviewSpec, out *authorization.SubjectAccessReviewSpec, s conversion.Scope) error { + out.ResourceAttributes = (*authorization.ResourceAttributes)(unsafe.Pointer(in.ResourceAttributes)) + out.NonResourceAttributes = (*authorization.NonResourceAttributes)(unsafe.Pointer(in.NonResourceAttributes)) + out.User = in.User + out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) + out.Extra = *(*map[string]authorization.ExtraValue)(unsafe.Pointer(&in.Extra)) + return nil +} + +// Convert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec is an autogenerated conversion function. +func Convert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(in *SubjectAccessReviewSpec, out *authorization.SubjectAccessReviewSpec, s conversion.Scope) error { + return autoConvert_v1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(in, out, s) +} + +func autoConvert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec(in *authorization.SubjectAccessReviewSpec, out *SubjectAccessReviewSpec, s conversion.Scope) error { + out.ResourceAttributes = (*ResourceAttributes)(unsafe.Pointer(in.ResourceAttributes)) + out.NonResourceAttributes = (*NonResourceAttributes)(unsafe.Pointer(in.NonResourceAttributes)) + out.User = in.User + out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) + out.Extra = *(*map[string]ExtraValue)(unsafe.Pointer(&in.Extra)) + return nil +} + +// Convert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec is an autogenerated conversion function. +func Convert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec(in *authorization.SubjectAccessReviewSpec, out *SubjectAccessReviewSpec, s conversion.Scope) error { + return autoConvert_authorization_SubjectAccessReviewSpec_To_v1_SubjectAccessReviewSpec(in, out, s) +} + +func autoConvert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(in *SubjectAccessReviewStatus, out *authorization.SubjectAccessReviewStatus, s conversion.Scope) error { + out.Allowed = in.Allowed + out.Reason = in.Reason + out.EvaluationError = in.EvaluationError + return nil +} + +// Convert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus is an autogenerated conversion function. +func Convert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(in *SubjectAccessReviewStatus, out *authorization.SubjectAccessReviewStatus, s conversion.Scope) error { + return autoConvert_v1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(in, out, s) +} + +func autoConvert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus(in *authorization.SubjectAccessReviewStatus, out *SubjectAccessReviewStatus, s conversion.Scope) error { + out.Allowed = in.Allowed + out.Reason = in.Reason + out.EvaluationError = in.EvaluationError + return nil +} + +// Convert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus is an autogenerated conversion function. +func Convert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus(in *authorization.SubjectAccessReviewStatus, out *SubjectAccessReviewStatus, s conversion.Scope) error { + return autoConvert_authorization_SubjectAccessReviewStatus_To_v1_SubjectAccessReviewStatus(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..bc04bed4dd --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.deepcopy.go @@ -0,0 +1,187 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_LocalSubjectAccessReview, InType: reflect.TypeOf(&LocalSubjectAccessReview{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NonResourceAttributes, InType: reflect.TypeOf(&NonResourceAttributes{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ResourceAttributes, InType: reflect.TypeOf(&ResourceAttributes{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SelfSubjectAccessReview, InType: reflect.TypeOf(&SelfSubjectAccessReview{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SelfSubjectAccessReviewSpec, InType: reflect.TypeOf(&SelfSubjectAccessReviewSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SubjectAccessReview, InType: reflect.TypeOf(&SubjectAccessReview{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SubjectAccessReviewSpec, InType: reflect.TypeOf(&SubjectAccessReviewSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_SubjectAccessReviewStatus, InType: reflect.TypeOf(&SubjectAccessReviewStatus{})}, + ) +} + +// DeepCopy_v1_LocalSubjectAccessReview is an autogenerated deepcopy function. +func DeepCopy_v1_LocalSubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*LocalSubjectAccessReview) + out := out.(*LocalSubjectAccessReview) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_NonResourceAttributes is an autogenerated deepcopy function. +func DeepCopy_v1_NonResourceAttributes(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NonResourceAttributes) + out := out.(*NonResourceAttributes) + *out = *in + return nil + } +} + +// DeepCopy_v1_ResourceAttributes is an autogenerated deepcopy function. +func DeepCopy_v1_ResourceAttributes(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceAttributes) + out := out.(*ResourceAttributes) + *out = *in + return nil + } +} + +// DeepCopy_v1_SelfSubjectAccessReview is an autogenerated deepcopy function. +func DeepCopy_v1_SelfSubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SelfSubjectAccessReview) + out := out.(*SelfSubjectAccessReview) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_SelfSubjectAccessReviewSpec is an autogenerated deepcopy function. +func DeepCopy_v1_SelfSubjectAccessReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SelfSubjectAccessReviewSpec) + out := out.(*SelfSubjectAccessReviewSpec) + *out = *in + if in.ResourceAttributes != nil { + in, out := &in.ResourceAttributes, &out.ResourceAttributes + *out = new(ResourceAttributes) + **out = **in + } + if in.NonResourceAttributes != nil { + in, out := &in.NonResourceAttributes, &out.NonResourceAttributes + *out = new(NonResourceAttributes) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_SubjectAccessReview is an autogenerated deepcopy function. +func DeepCopy_v1_SubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SubjectAccessReview) + out := out.(*SubjectAccessReview) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_SubjectAccessReviewSpec is an autogenerated deepcopy function. +func DeepCopy_v1_SubjectAccessReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SubjectAccessReviewSpec) + out := out.(*SubjectAccessReviewSpec) + *out = *in + if in.ResourceAttributes != nil { + in, out := &in.ResourceAttributes, &out.ResourceAttributes + *out = new(ResourceAttributes) + **out = **in + } + if in.NonResourceAttributes != nil { + in, out := &in.NonResourceAttributes, &out.NonResourceAttributes + *out = new(NonResourceAttributes) + **out = **in + } + if in.Groups != nil { + in, out := &in.Groups, &out.Groups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Extra != nil { + in, out := &in.Extra, &out.Extra + *out = make(map[string]ExtraValue) + for key, val := range *in { + if newVal, err := c.DeepCopy(&val); err != nil { + return err + } else { + (*out)[key] = *newVal.(*ExtraValue) + } + } + } + return nil + } +} + +// DeepCopy_v1_SubjectAccessReviewStatus is an autogenerated deepcopy function. +func DeepCopy_v1_SubjectAccessReviewStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*SubjectAccessReviewStatus) + out := out.(*SubjectAccessReviewStatus) + *out = *in + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.defaults.go new file mode 100644 index 0000000000..6df448eb9f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/BUILD new file mode 100644 index 0000000000..d2185f6dc6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/authorization:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/conversion.go index 090160a560..c401383656 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/conversion.go @@ -17,7 +17,7 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addConversionFuncs(scheme *runtime.Scheme) error { diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/defaults.go index bcbcbfaf33..7d689a4cc8 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/defaults.go @@ -17,9 +17,9 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - return scheme.AddDefaultingFuncs() + return RegisterDefaults(scheme) } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/doc.go index e11cea1c4a..738b0b6d29 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/doc.go @@ -14,10 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/authorization -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - // +groupName=authorization.k8s.io package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go index 875a98aa64..b2e66e6199 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -41,9 +41,10 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + import strings "strings" import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import io "io" @@ -54,7 +55,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *ExtraValue) Reset() { *m = ExtraValue{} } func (*ExtraValue) ProtoMessage() {} @@ -109,74 +112,74 @@ func init() { proto.RegisterType((*SubjectAccessReviewSpec)(nil), "k8s.io.client-go.pkg.apis.authorization.v1beta1.SubjectAccessReviewSpec") proto.RegisterType((*SubjectAccessReviewStatus)(nil), "k8s.io.client-go.pkg.apis.authorization.v1beta1.SubjectAccessReviewStatus") } -func (m ExtraValue) Marshal() (data []byte, err error) { +func (m ExtraValue) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m ExtraValue) MarshalTo(data []byte) (int, error) { +func (m ExtraValue) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m) > 0 { for _, s := range m { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *LocalSubjectAccessReview) Marshal() (data []byte, err error) { +func (m *LocalSubjectAccessReview) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *LocalSubjectAccessReview) MarshalTo(data []byte) (int, error) { +func (m *LocalSubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -184,113 +187,113 @@ func (m *LocalSubjectAccessReview) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NonResourceAttributes) Marshal() (data []byte, err error) { +func (m *NonResourceAttributes) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NonResourceAttributes) MarshalTo(data []byte) (int, error) { +func (m *NonResourceAttributes) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Verb))) - i += copy(data[i:], m.Verb) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Verb))) + i += copy(dAtA[i:], m.Verb) return i, nil } -func (m *ResourceAttributes) Marshal() (data []byte, err error) { +func (m *ResourceAttributes) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ResourceAttributes) MarshalTo(data []byte) (int, error) { +func (m *ResourceAttributes) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Namespace))) - i += copy(data[i:], m.Namespace) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Verb))) - i += copy(data[i:], m.Verb) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Verb))) + i += copy(dAtA[i:], m.Verb) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Group))) - i += copy(data[i:], m.Group) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Group))) + i += copy(dAtA[i:], m.Group) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Version))) - i += copy(data[i:], m.Version) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Version))) + i += copy(dAtA[i:], m.Version) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Resource))) - i += copy(data[i:], m.Resource) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Resource))) + i += copy(dAtA[i:], m.Resource) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Subresource))) - i += copy(data[i:], m.Subresource) - data[i] = 0x3a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Subresource))) + i += copy(dAtA[i:], m.Subresource) + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) return i, nil } -func (m *SelfSubjectAccessReview) Marshal() (data []byte, err error) { +func (m *SelfSubjectAccessReview) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SelfSubjectAccessReview) MarshalTo(data []byte) (int, error) { +func (m *SelfSubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n4, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n4, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n5, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n5, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n5 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n6, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n6, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -298,36 +301,36 @@ func (m *SelfSubjectAccessReview) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *SelfSubjectAccessReviewSpec) Marshal() (data []byte, err error) { +func (m *SelfSubjectAccessReviewSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SelfSubjectAccessReviewSpec) MarshalTo(data []byte) (int, error) { +func (m *SelfSubjectAccessReviewSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.ResourceAttributes != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ResourceAttributes.Size())) - n7, err := m.ResourceAttributes.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceAttributes.Size())) + n7, err := m.ResourceAttributes.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 } if m.NonResourceAttributes != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.NonResourceAttributes.Size())) - n8, err := m.NonResourceAttributes.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NonResourceAttributes.Size())) + n8, err := m.NonResourceAttributes.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -336,41 +339,41 @@ func (m *SelfSubjectAccessReviewSpec) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *SubjectAccessReview) Marshal() (data []byte, err error) { +func (m *SubjectAccessReview) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SubjectAccessReview) MarshalTo(data []byte) (int, error) { +func (m *SubjectAccessReview) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n9, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n9 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n10, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n10, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n10 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n11, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n11, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -378,76 +381,85 @@ func (m *SubjectAccessReview) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *SubjectAccessReviewSpec) Marshal() (data []byte, err error) { +func (m *SubjectAccessReviewSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SubjectAccessReviewSpec) MarshalTo(data []byte) (int, error) { +func (m *SubjectAccessReviewSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.ResourceAttributes != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ResourceAttributes.Size())) - n12, err := m.ResourceAttributes.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ResourceAttributes.Size())) + n12, err := m.ResourceAttributes.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n12 } if m.NonResourceAttributes != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.NonResourceAttributes.Size())) - n13, err := m.NonResourceAttributes.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NonResourceAttributes.Size())) + n13, err := m.NonResourceAttributes.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n13 } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.User))) - i += copy(data[i:], m.User) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.User))) + i += copy(dAtA[i:], m.User) if len(m.Groups) > 0 { for _, s := range m.Groups { - data[i] = 0x22 + dAtA[i] = 0x22 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Extra) > 0 { + keysForExtra := make([]string, 0, len(m.Extra)) for k := range m.Extra { - data[i] = 0x2a + keysForExtra = append(keysForExtra, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + for _, k := range keysForExtra { + dAtA[i] = 0x2a i++ - v := m.Extra[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.Extra[string(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n14, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n14, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -457,65 +469,65 @@ func (m *SubjectAccessReviewSpec) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *SubjectAccessReviewStatus) Marshal() (data []byte, err error) { +func (m *SubjectAccessReviewStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SubjectAccessReviewStatus) MarshalTo(data []byte) (int, error) { +func (m *SubjectAccessReviewStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ if m.Allowed { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.EvaluationError))) - i += copy(data[i:], m.EvaluationError) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.EvaluationError))) + i += copy(dAtA[i:], m.EvaluationError) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m ExtraValue) Size() (n int) { @@ -670,7 +682,7 @@ func (this *LocalSubjectAccessReview) String() string { return "nil" } s := strings.Join([]string{`&LocalSubjectAccessReview{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubjectAccessReviewSpec", "SubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -709,7 +721,7 @@ func (this *SelfSubjectAccessReview) String() string { return "nil" } s := strings.Join([]string{`&SelfSubjectAccessReview{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SelfSubjectAccessReviewSpec", "SelfSubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -732,7 +744,7 @@ func (this *SubjectAccessReview) String() string { return "nil" } s := strings.Join([]string{`&SubjectAccessReview{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "SubjectAccessReviewSpec", "SubjectAccessReviewSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "SubjectAccessReviewStatus", "SubjectAccessReviewStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -783,8 +795,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *ExtraValue) Unmarshal(data []byte) error { - l := len(data) +func (m *ExtraValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -796,7 +808,7 @@ func (m *ExtraValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -824,7 +836,7 @@ func (m *ExtraValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -839,11 +851,11 @@ func (m *ExtraValue) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - *m = append(*m, string(data[iNdEx:postIndex])) + *m = append(*m, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -862,8 +874,8 @@ func (m *ExtraValue) Unmarshal(data []byte) error { } return nil } -func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { - l := len(data) +func (m *LocalSubjectAccessReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -875,7 +887,7 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -903,7 +915,7 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -917,7 +929,7 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -933,7 +945,7 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -947,7 +959,7 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -963,7 +975,7 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -977,13 +989,13 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1002,8 +1014,8 @@ func (m *LocalSubjectAccessReview) Unmarshal(data []byte) error { } return nil } -func (m *NonResourceAttributes) Unmarshal(data []byte) error { - l := len(data) +func (m *NonResourceAttributes) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1015,7 +1027,7 @@ func (m *NonResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1043,7 +1055,7 @@ func (m *NonResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1058,7 +1070,7 @@ func (m *NonResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -1072,7 +1084,7 @@ func (m *NonResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1087,11 +1099,11 @@ func (m *NonResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Verb = string(data[iNdEx:postIndex]) + m.Verb = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1110,8 +1122,8 @@ func (m *NonResourceAttributes) Unmarshal(data []byte) error { } return nil } -func (m *ResourceAttributes) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceAttributes) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1123,7 +1135,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1151,7 +1163,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1166,7 +1178,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Namespace = string(data[iNdEx:postIndex]) + m.Namespace = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -1180,7 +1192,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1195,7 +1207,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Verb = string(data[iNdEx:postIndex]) + m.Verb = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -1209,7 +1221,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1224,7 +1236,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Group = string(data[iNdEx:postIndex]) + m.Group = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -1238,7 +1250,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1253,7 +1265,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Version = string(data[iNdEx:postIndex]) + m.Version = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -1267,7 +1279,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1282,7 +1294,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Resource = string(data[iNdEx:postIndex]) + m.Resource = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -1296,7 +1308,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1311,7 +1323,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Subresource = string(data[iNdEx:postIndex]) + m.Subresource = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 7: if wireType != 2 { @@ -1325,7 +1337,7 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1340,11 +1352,11 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1363,8 +1375,8 @@ func (m *ResourceAttributes) Unmarshal(data []byte) error { } return nil } -func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { - l := len(data) +func (m *SelfSubjectAccessReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1376,7 +1388,7 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1404,7 +1416,7 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1418,7 +1430,7 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1434,7 +1446,7 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1448,7 +1460,7 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1464,7 +1476,7 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1478,13 +1490,13 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1503,8 +1515,8 @@ func (m *SelfSubjectAccessReview) Unmarshal(data []byte) error { } return nil } -func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *SelfSubjectAccessReviewSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1516,7 +1528,7 @@ func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1544,7 +1556,7 @@ func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1561,7 +1573,7 @@ func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { if m.ResourceAttributes == nil { m.ResourceAttributes = &ResourceAttributes{} } - if err := m.ResourceAttributes.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1577,7 +1589,7 @@ func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1594,13 +1606,13 @@ func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { if m.NonResourceAttributes == nil { m.NonResourceAttributes = &NonResourceAttributes{} } - if err := m.NonResourceAttributes.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NonResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1619,8 +1631,8 @@ func (m *SelfSubjectAccessReviewSpec) Unmarshal(data []byte) error { } return nil } -func (m *SubjectAccessReview) Unmarshal(data []byte) error { - l := len(data) +func (m *SubjectAccessReview) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1632,7 +1644,7 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1660,7 +1672,7 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1674,7 +1686,7 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1690,7 +1702,7 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1704,7 +1716,7 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1720,7 +1732,7 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1734,13 +1746,13 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1759,8 +1771,8 @@ func (m *SubjectAccessReview) Unmarshal(data []byte) error { } return nil } -func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *SubjectAccessReviewSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1772,7 +1784,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1800,7 +1812,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1817,7 +1829,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if m.ResourceAttributes == nil { m.ResourceAttributes = &ResourceAttributes{} } - if err := m.ResourceAttributes.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1833,7 +1845,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1850,7 +1862,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if m.NonResourceAttributes == nil { m.NonResourceAttributes = &NonResourceAttributes{} } - if err := m.NonResourceAttributes.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NonResourceAttributes.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1866,7 +1878,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1881,7 +1893,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.User = string(data[iNdEx:postIndex]) + m.User = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -1895,7 +1907,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1910,7 +1922,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Groups = append(m.Groups, string(data[iNdEx:postIndex])) + m.Groups = append(m.Groups, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 5: if wireType != 2 { @@ -1924,7 +1936,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1946,7 +1958,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1961,7 +1973,7 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1976,61 +1988,66 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.Extra == nil { + m.Extra = make(map[string]ExtraValue) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &ExtraValue{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.Extra[mapkey] = *mapvalue + } else { + var mapvalue ExtraValue + m.Extra[mapkey] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &ExtraValue{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.Extra == nil { - m.Extra = make(map[string]ExtraValue) - } - m.Extra[mapkey] = *mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2049,8 +2066,8 @@ func (m *SubjectAccessReviewSpec) Unmarshal(data []byte) error { } return nil } -func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *SubjectAccessReviewStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2062,7 +2079,7 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2090,7 +2107,7 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2110,7 +2127,7 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2125,7 +2142,7 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -2139,7 +2156,7 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2154,11 +2171,11 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.EvaluationError = string(data[iNdEx:postIndex]) + m.EvaluationError = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2177,8 +2194,8 @@ func (m *SubjectAccessReviewStatus) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -2189,7 +2206,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2207,7 +2224,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -2224,7 +2241,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2247,7 +2264,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2258,7 +2275,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -2282,61 +2299,66 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 874 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xec, 0x56, 0x41, 0x8f, 0xdb, 0x44, - 0x14, 0x8e, 0x93, 0x78, 0x37, 0x99, 0x05, 0xb6, 0x4c, 0x55, 0xd6, 0x0d, 0x92, 0x13, 0x05, 0x09, - 0x6d, 0xa5, 0xd6, 0x66, 0x57, 0xaa, 0xa8, 0x2a, 0x0e, 0xac, 0xc5, 0xaa, 0xaa, 0xa0, 0x05, 0xcd, - 0xc2, 0x0a, 0xc1, 0x69, 0xec, 0x7d, 0x4d, 0x4c, 0x12, 0x8f, 0x35, 0x33, 0x76, 0x59, 0x4e, 0xfd, - 0x01, 0x1c, 0x38, 0xf6, 0xc8, 0x5f, 0xe0, 0x0f, 0x70, 0x65, 0x8f, 0xe5, 0x82, 0x40, 0x42, 0x11, - 0x6b, 0xfe, 0x05, 0x27, 0xe4, 0xf1, 0x24, 0x6e, 0x36, 0x0e, 0x28, 0xb0, 0x42, 0x1c, 0x7a, 0xf3, - 0xbc, 0xf7, 0xbd, 0xf7, 0xbe, 0x99, 0xf9, 0xc6, 0xef, 0xa1, 0x77, 0x47, 0x77, 0x84, 0x13, 0x32, - 0x77, 0x94, 0xf8, 0xc0, 0x23, 0x90, 0x20, 0xdc, 0x78, 0x34, 0x70, 0x69, 0x1c, 0x0a, 0x97, 0x26, - 0x72, 0xc8, 0x78, 0xf8, 0x15, 0x95, 0x21, 0x8b, 0xdc, 0x74, 0xcf, 0x07, 0x49, 0xf7, 0xdc, 0x01, - 0x44, 0xc0, 0xa9, 0x84, 0x13, 0x27, 0xe6, 0x4c, 0x32, 0xfc, 0x56, 0x91, 0xc1, 0x29, 0x33, 0x38, - 0xf1, 0x68, 0xe0, 0xe4, 0x19, 0x9c, 0x85, 0x0c, 0x8e, 0xce, 0xd0, 0xb9, 0x35, 0x08, 0xe5, 0x30, - 0xf1, 0x9d, 0x80, 0x4d, 0xdc, 0x01, 0x1b, 0x30, 0x57, 0x25, 0xf2, 0x93, 0x47, 0x6a, 0xa5, 0x16, - 0xea, 0xab, 0x28, 0xd0, 0xd9, 0x5f, 0x49, 0xd1, 0xe5, 0x20, 0x58, 0xc2, 0x03, 0xb8, 0x48, 0xaa, - 0x73, 0x7b, 0x75, 0x4c, 0x12, 0xa5, 0xc0, 0x45, 0xc8, 0x22, 0x38, 0x59, 0x0a, 0xbb, 0xb9, 0x3a, - 0x2c, 0x5d, 0xda, 0x79, 0xe7, 0x56, 0x35, 0x9a, 0x27, 0x91, 0x0c, 0x27, 0xcb, 0x9c, 0xf6, 0xaa, - 0xe1, 0x89, 0x0c, 0xc7, 0x6e, 0x18, 0x49, 0x21, 0xf9, 0xc5, 0x90, 0xfe, 0xdb, 0x08, 0x1d, 0x7e, - 0x29, 0x39, 0x3d, 0xa6, 0xe3, 0x04, 0x70, 0x17, 0x99, 0xa1, 0x84, 0x89, 0xb0, 0x8c, 0x5e, 0x63, - 0xb7, 0xed, 0xb5, 0xb3, 0x69, 0xd7, 0xbc, 0x9f, 0x1b, 0x48, 0x61, 0xbf, 0xdb, 0x7a, 0xfa, 0x6d, - 0xb7, 0xf6, 0xe4, 0xd7, 0x5e, 0xad, 0xff, 0x53, 0x1d, 0x59, 0x1f, 0xb0, 0x80, 0x8e, 0x8f, 0x12, - 0xff, 0x0b, 0x08, 0xe4, 0x41, 0x10, 0x80, 0x10, 0x04, 0xd2, 0x10, 0x1e, 0xe3, 0x4f, 0x51, 0x6b, - 0x02, 0x92, 0x9e, 0x50, 0x49, 0x2d, 0xa3, 0x67, 0xec, 0x6e, 0xed, 0xef, 0x3a, 0x2b, 0x2f, 0xd1, - 0x49, 0xf7, 0x9c, 0x0f, 0x55, 0x8e, 0x07, 0x20, 0xa9, 0x87, 0xcf, 0xa6, 0xdd, 0x5a, 0x36, 0xed, - 0xa2, 0xd2, 0x46, 0xe6, 0xd9, 0xf0, 0x08, 0x35, 0x45, 0x0c, 0x81, 0x55, 0x57, 0x59, 0xef, 0x3b, - 0xeb, 0x4a, 0xc3, 0xa9, 0xa0, 0x7b, 0x14, 0x43, 0xe0, 0xbd, 0xa4, 0xcb, 0x36, 0xf3, 0x15, 0x51, - 0x45, 0xb0, 0x40, 0x1b, 0x42, 0x52, 0x99, 0x08, 0xab, 0xa1, 0xca, 0xbd, 0x7f, 0x39, 0xe5, 0x54, - 0x4a, 0xef, 0x15, 0x5d, 0x70, 0xa3, 0x58, 0x13, 0x5d, 0xaa, 0xff, 0x39, 0xba, 0xf6, 0x90, 0x45, - 0x44, 0xeb, 0xee, 0x40, 0x4a, 0x1e, 0xfa, 0x89, 0x04, 0x81, 0x7b, 0xa8, 0x19, 0x53, 0x39, 0x54, - 0x07, 0xda, 0x2e, 0xf9, 0x7e, 0x44, 0xe5, 0x90, 0x28, 0x4f, 0x8e, 0x48, 0x81, 0xfb, 0xea, 0x70, - 0x9e, 0x43, 0x1c, 0x03, 0xf7, 0x89, 0xf2, 0xf4, 0xbf, 0xaf, 0x23, 0x5c, 0x91, 0xda, 0x45, 0xed, - 0x88, 0x4e, 0x40, 0xc4, 0x34, 0x00, 0x9d, 0xff, 0x55, 0x1d, 0xdd, 0x7e, 0x38, 0x73, 0x90, 0x12, - 0xf3, 0xf7, 0x95, 0xf0, 0x1b, 0xc8, 0x1c, 0x70, 0x96, 0xc4, 0xea, 0xe8, 0xda, 0xde, 0xcb, 0x1a, - 0x62, 0xde, 0xcb, 0x8d, 0xa4, 0xf0, 0xe1, 0x1b, 0x68, 0x53, 0x3f, 0x15, 0xab, 0xa9, 0x60, 0xdb, - 0x1a, 0xb6, 0x79, 0x5c, 0x98, 0xc9, 0xcc, 0x8f, 0x6f, 0xa2, 0xd6, 0xec, 0x2d, 0x5a, 0xa6, 0xc2, - 0x5e, 0xd1, 0xd8, 0xd6, 0x6c, 0x43, 0x64, 0x8e, 0xc0, 0xb7, 0xd1, 0x96, 0x48, 0xfc, 0x79, 0xc0, - 0x86, 0x0a, 0xb8, 0xaa, 0x03, 0xb6, 0x8e, 0x4a, 0x17, 0x79, 0x1e, 0x97, 0x6f, 0x2b, 0xdf, 0xa3, - 0xb5, 0xb9, 0xb8, 0xad, 0xfc, 0x08, 0x88, 0xf2, 0xf4, 0x7f, 0xa9, 0xa3, 0x9d, 0x23, 0x18, 0x3f, - 0xfa, 0x6f, 0x55, 0xcf, 0x16, 0x54, 0xff, 0xe0, 0x1f, 0xc8, 0xb0, 0x9a, 0xf2, 0xff, 0x4b, 0xf9, - 0x3f, 0xd4, 0xd1, 0xeb, 0x7f, 0x41, 0x14, 0x7f, 0x6d, 0x20, 0xcc, 0x97, 0xc4, 0xab, 0x8f, 0xfa, - 0xbd, 0xf5, 0x19, 0x2e, 0x3f, 0x04, 0xef, 0xb5, 0x6c, 0xda, 0xad, 0x78, 0x20, 0xa4, 0xa2, 0x2e, - 0x7e, 0x6a, 0xa0, 0x6b, 0x51, 0xd5, 0x4b, 0xd5, 0xd7, 0x74, 0x6f, 0x7d, 0x46, 0x95, 0x0f, 0xdf, - 0xbb, 0x9e, 0x4d, 0xbb, 0xd5, 0xff, 0x04, 0x52, 0x4d, 0xa0, 0xff, 0x63, 0x1d, 0x5d, 0x7d, 0xf1, - 0x5f, 0xbe, 0x5c, 0x75, 0xfe, 0xd1, 0x44, 0x3b, 0x2f, 0x94, 0xf9, 0x2f, 0x95, 0x39, 0x6f, 0x1c, - 0x8d, 0xc5, 0x3f, 0xec, 0x27, 0x02, 0xb8, 0x6e, 0x1c, 0xbd, 0x59, 0xe3, 0x68, 0xaa, 0x19, 0x04, - 0xe5, 0x57, 0xa1, 0x9a, 0x86, 0x98, 0x75, 0x8d, 0x53, 0x64, 0x42, 0x3e, 0xb3, 0x58, 0x66, 0xaf, - 0xb1, 0xbb, 0xb5, 0xff, 0xf1, 0xa5, 0x89, 0xcd, 0x51, 0xa3, 0xd0, 0x61, 0x24, 0xf9, 0x69, 0xd9, - 0xb0, 0x94, 0x8d, 0x14, 0x15, 0x3b, 0xa9, 0x1e, 0x97, 0x14, 0x06, 0x5f, 0x41, 0x8d, 0x11, 0x9c, - 0x16, 0x0d, 0x93, 0xe4, 0x9f, 0x98, 0x20, 0x33, 0xcd, 0x27, 0x29, 0x7d, 0xd0, 0xef, 0xac, 0x4f, - 0xad, 0x9c, 0xc6, 0x48, 0x91, 0xea, 0x6e, 0xfd, 0x8e, 0xd1, 0xff, 0xce, 0x40, 0xd7, 0x57, 0x4a, - 0x36, 0x6f, 0xa3, 0x74, 0x3c, 0x66, 0x8f, 0xe1, 0x44, 0x71, 0x69, 0x95, 0x6d, 0xf4, 0xa0, 0x30, - 0x93, 0x99, 0x1f, 0xbf, 0x89, 0x36, 0x38, 0x50, 0xc1, 0x22, 0xdd, 0xba, 0xe7, 0x6a, 0x27, 0xca, - 0x4a, 0xb4, 0x17, 0x1f, 0xa0, 0x6d, 0xc8, 0xcb, 0x2b, 0x72, 0x87, 0x9c, 0x33, 0xae, 0xaf, 0x6c, - 0x47, 0x07, 0x6c, 0x1f, 0x2e, 0xba, 0xc9, 0x45, 0xbc, 0x77, 0xe3, 0xec, 0xdc, 0xae, 0x3d, 0x3b, - 0xb7, 0x6b, 0x3f, 0x9f, 0xdb, 0xb5, 0x27, 0x99, 0x6d, 0x9c, 0x65, 0xb6, 0xf1, 0x2c, 0xb3, 0x8d, - 0xdf, 0x32, 0xdb, 0xf8, 0xe6, 0x77, 0xbb, 0xf6, 0xd9, 0xa6, 0xde, 0xf4, 0x9f, 0x01, 0x00, 0x00, - 0xff, 0xff, 0x0c, 0xa4, 0x8c, 0xef, 0x24, 0x0c, 0x00, 0x00, + // 886 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x56, 0x4f, 0x6f, 0xdc, 0x44, + 0x14, 0x5f, 0xef, 0x9f, 0x64, 0x77, 0x02, 0xa4, 0x4c, 0x55, 0xe2, 0x06, 0xc9, 0xbb, 0x5a, 0x24, + 0x14, 0x24, 0x6a, 0x37, 0xe5, 0x5f, 0x55, 0x71, 0x20, 0x16, 0x51, 0x55, 0x41, 0x0b, 0x9a, 0x40, + 0x0e, 0x70, 0x61, 0xec, 0xbc, 0xee, 0x9a, 0xdd, 0xf5, 0x58, 0x33, 0x63, 0x97, 0x70, 0xea, 0x07, + 0xe0, 0xc0, 0xb1, 0x47, 0xbe, 0x02, 0x5f, 0x80, 0x2b, 0x39, 0xf6, 0x58, 0x24, 0xb4, 0x22, 0xe6, + 0x5b, 0x70, 0x42, 0x33, 0x9e, 0x5d, 0x67, 0xbb, 0x0e, 0xd5, 0x42, 0x11, 0x1c, 0x72, 0xb3, 0xdf, + 0xfb, 0xbd, 0xdf, 0xfb, 0xcd, 0x9b, 0x37, 0xf3, 0x06, 0x7d, 0x30, 0xba, 0x29, 0xdc, 0x88, 0x79, + 0xa3, 0x34, 0x00, 0x1e, 0x83, 0x04, 0xe1, 0x25, 0xa3, 0x81, 0x47, 0x93, 0x48, 0x78, 0x34, 0x95, + 0x43, 0xc6, 0xa3, 0x6f, 0xa9, 0x8c, 0x58, 0xec, 0x65, 0xbb, 0x01, 0x48, 0xba, 0xeb, 0x0d, 0x20, + 0x06, 0x4e, 0x25, 0x1c, 0xb9, 0x09, 0x67, 0x92, 0xe1, 0xeb, 0x05, 0x83, 0x5b, 0x32, 0xb8, 0xc9, + 0x68, 0xe0, 0x2a, 0x06, 0x77, 0x81, 0xc1, 0x35, 0x0c, 0xdb, 0xd7, 0x06, 0x91, 0x1c, 0xa6, 0x81, + 0x1b, 0xb2, 0x89, 0x37, 0x60, 0x03, 0xe6, 0x69, 0xa2, 0x20, 0xbd, 0xaf, 0xff, 0xf4, 0x8f, 0xfe, + 0x2a, 0x12, 0x6c, 0xbf, 0x6d, 0x24, 0xd2, 0x24, 0x9a, 0xd0, 0x70, 0x18, 0xc5, 0xc0, 0x8f, 0x4b, + 0x91, 0x13, 0x90, 0xd4, 0xcb, 0x96, 0x64, 0x6d, 0x7b, 0xe7, 0x45, 0xf1, 0x34, 0x96, 0xd1, 0x04, + 0x96, 0x02, 0xde, 0x7d, 0x56, 0x80, 0x08, 0x87, 0x30, 0xa1, 0x4b, 0x71, 0x6f, 0x9d, 0x17, 0x97, + 0xca, 0x68, 0xec, 0x45, 0xb1, 0x14, 0x92, 0x3f, 0x1d, 0xd4, 0x7f, 0x0f, 0xa1, 0xfd, 0x6f, 0x24, + 0xa7, 0x87, 0x74, 0x9c, 0x02, 0xee, 0xa2, 0x56, 0x24, 0x61, 0x22, 0x6c, 0xab, 0xd7, 0xd8, 0xe9, + 0xf8, 0x9d, 0x7c, 0xda, 0x6d, 0xdd, 0x51, 0x06, 0x52, 0xd8, 0x6f, 0xb5, 0x1f, 0xfd, 0xd0, 0xad, + 0x3d, 0xfc, 0xb5, 0x57, 0xeb, 0x4f, 0xeb, 0xc8, 0xfe, 0x98, 0x85, 0x74, 0x7c, 0x90, 0x06, 0x5f, + 0x43, 0x28, 0xf7, 0xc2, 0x10, 0x84, 0x20, 0x90, 0x45, 0xf0, 0x00, 0x7f, 0x85, 0xda, 0xaa, 0x1c, + 0x47, 0x54, 0x52, 0xdb, 0xea, 0x59, 0x3b, 0x1b, 0x37, 0xae, 0xbb, 0x66, 0x77, 0xce, 0xaa, 0x2b, + 0xf7, 0x47, 0xa1, 0xdd, 0x6c, 0xd7, 0xfd, 0x44, 0x73, 0xdd, 0x05, 0x49, 0x7d, 0x7c, 0x32, 0xed, + 0xd6, 0xf2, 0x69, 0x17, 0x95, 0x36, 0x32, 0x67, 0xc5, 0x23, 0xd4, 0x14, 0x09, 0x84, 0x76, 0x5d, + 0xb3, 0xdf, 0x71, 0x57, 0xdd, 0x7b, 0xb7, 0x42, 0xf6, 0x41, 0x02, 0xa1, 0xff, 0x82, 0x49, 0xdb, + 0x54, 0x7f, 0x44, 0x27, 0xc1, 0x02, 0xad, 0x09, 0x49, 0x65, 0x2a, 0xec, 0x86, 0x4e, 0xf7, 0xd1, + 0xf3, 0x49, 0xa7, 0x29, 0xfd, 0x97, 0x4c, 0xc2, 0xb5, 0xe2, 0x9f, 0x98, 0x54, 0xfd, 0x2f, 0xd1, + 0x95, 0x7b, 0x2c, 0x26, 0x20, 0x58, 0xca, 0x43, 0xd8, 0x93, 0x92, 0x47, 0x41, 0x2a, 0x41, 0xe0, + 0x1e, 0x6a, 0x26, 0x54, 0x0e, 0x75, 0x61, 0x3b, 0xa5, 0xde, 0x4f, 0xa9, 0x1c, 0x12, 0xed, 0x51, + 0x88, 0x0c, 0x78, 0xa0, 0x8b, 0x73, 0x06, 0x71, 0x08, 0x3c, 0x20, 0xda, 0xd3, 0xff, 0xa9, 0x8e, + 0x70, 0x05, 0xb5, 0x87, 0x3a, 0x31, 0x9d, 0x80, 0x48, 0x68, 0x08, 0x86, 0xff, 0x65, 0x13, 0xdd, + 0xb9, 0x37, 0x73, 0x90, 0x12, 0xf3, 0xec, 0x4c, 0xf8, 0x35, 0xd4, 0x1a, 0x70, 0x96, 0x26, 0xba, + 0x74, 0x1d, 0xff, 0x45, 0x03, 0x69, 0xdd, 0x56, 0x46, 0x52, 0xf8, 0xf0, 0x1b, 0x68, 0x3d, 0x03, + 0x2e, 0x22, 0x16, 0xdb, 0x4d, 0x0d, 0xdb, 0x34, 0xb0, 0xf5, 0xc3, 0xc2, 0x4c, 0x66, 0x7e, 0xfc, + 0x26, 0x6a, 0x73, 0x23, 0xdc, 0x6e, 0x69, 0xec, 0x25, 0x83, 0x6d, 0xcf, 0x16, 0x44, 0xe6, 0x08, + 0xfc, 0x0e, 0xda, 0x10, 0x69, 0x30, 0x0f, 0x58, 0xd3, 0x01, 0x97, 0x4d, 0xc0, 0xc6, 0x41, 0xe9, + 0x22, 0x67, 0x71, 0x6a, 0x59, 0x6a, 0x8d, 0xf6, 0xfa, 0xe2, 0xb2, 0x54, 0x09, 0x88, 0xf6, 0xf4, + 0x4f, 0xeb, 0x68, 0xeb, 0x00, 0xc6, 0xf7, 0xff, 0x9b, 0xee, 0x67, 0x0b, 0xdd, 0x7f, 0xf7, 0x6f, + 0xb4, 0x63, 0xb5, 0xf4, 0xff, 0xd7, 0x09, 0xf8, 0xb9, 0x8e, 0x5e, 0xfd, 0x0b, 0xa1, 0xf8, 0x3b, + 0x0b, 0x61, 0xbe, 0xd4, 0xc4, 0xa6, 0xe4, 0x1f, 0xae, 0xae, 0x70, 0xf9, 0x40, 0xf8, 0xaf, 0xe4, + 0xd3, 0x6e, 0xc5, 0x41, 0x21, 0x15, 0x79, 0xf1, 0x23, 0x0b, 0x5d, 0x89, 0xab, 0x4e, 0xac, 0xd9, + 0xa6, 0xdb, 0xab, 0x2b, 0xaa, 0xbc, 0x00, 0xfc, 0xab, 0xf9, 0xb4, 0x5b, 0x7d, 0x37, 0x90, 0x6a, + 0x01, 0xfd, 0x5f, 0xea, 0xe8, 0xf2, 0xc5, 0x3d, 0xfd, 0xef, 0x74, 0xe9, 0x1f, 0x4d, 0xb4, 0x75, + 0xd1, 0xa1, 0xff, 0xb0, 0x43, 0xe7, 0x83, 0xa4, 0xb1, 0x78, 0xe3, 0x7e, 0x2e, 0x80, 0x9b, 0x41, + 0xd2, 0x9b, 0x0d, 0x92, 0xa6, 0x7e, 0x9b, 0x20, 0xb5, 0x15, 0x7a, 0x88, 0x88, 0xd9, 0x14, 0x39, + 0x46, 0x2d, 0x50, 0x6f, 0x19, 0xbb, 0xd5, 0x6b, 0xec, 0x6c, 0xdc, 0xf8, 0xec, 0xb9, 0x35, 0x9b, + 0xab, 0x9f, 0x48, 0xfb, 0xb1, 0xe4, 0xc7, 0xe5, 0x00, 0xd3, 0x36, 0x52, 0x64, 0xdc, 0xce, 0xcc, + 0x33, 0x4a, 0x63, 0xf0, 0x25, 0xd4, 0x18, 0xc1, 0x71, 0x31, 0x40, 0x89, 0xfa, 0xc4, 0x04, 0xb5, + 0x32, 0xf5, 0xc2, 0x32, 0x85, 0x7e, 0x7f, 0x75, 0x69, 0xe5, 0x2b, 0x8d, 0x14, 0x54, 0xb7, 0xea, + 0x37, 0xad, 0xfe, 0x8f, 0x16, 0xba, 0x7a, 0x6e, 0xcb, 0xaa, 0xb1, 0x4a, 0xc7, 0x63, 0xf6, 0x00, + 0x8e, 0xb4, 0x96, 0x76, 0x39, 0x56, 0xf7, 0x0a, 0x33, 0x99, 0xf9, 0xf1, 0xeb, 0x68, 0x8d, 0x03, + 0x15, 0x2c, 0x36, 0xa3, 0x7c, 0xde, 0xed, 0x44, 0x5b, 0x89, 0xf1, 0xe2, 0x3d, 0xb4, 0x09, 0x2a, + 0xbd, 0x16, 0xb7, 0xcf, 0x39, 0xe3, 0x66, 0xcb, 0xb6, 0x4c, 0xc0, 0xe6, 0xfe, 0xa2, 0x9b, 0x3c, + 0x8d, 0xf7, 0xaf, 0x9d, 0x9c, 0x3a, 0xb5, 0xc7, 0xa7, 0x4e, 0xed, 0xc9, 0xa9, 0x53, 0x7b, 0x98, + 0x3b, 0xd6, 0x49, 0xee, 0x58, 0x8f, 0x73, 0xc7, 0x7a, 0x92, 0x3b, 0xd6, 0x6f, 0xb9, 0x63, 0x7d, + 0xff, 0xbb, 0x53, 0xfb, 0x62, 0xdd, 0x2c, 0xfc, 0xcf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x24, 0x8e, + 0x13, 0x84, 0x19, 0x0c, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto index b3df897785..104e3573c9 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.authorization.v1beta1; +package k8s.io.client_go.pkg.apis.authorization.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; -import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; @@ -44,7 +43,7 @@ message ExtraValue { // checking. message LocalSubjectAccessReview { // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace // you made the request against. If empty, it is defaulted. @@ -105,7 +104,7 @@ message ResourceAttributes { // to check whether they can perform an action message SelfSubjectAccessReview { // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec holds information about the request being evaluated. user and groups must be empty optional SelfSubjectAccessReviewSpec spec = 2; @@ -130,7 +129,7 @@ message SelfSubjectAccessReviewSpec { // SubjectAccessReview checks whether or not a user or group can perform an action. message SubjectAccessReview { // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec holds information about the request being evaluated optional SubjectAccessReviewSpec spec = 2; diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/register.go index 6ae38ec85c..599501cd06 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/register.go @@ -17,39 +17,45 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "authorization.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1beta1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, - &SelfSubjectAccessReview{}, &SubjectAccessReview{}, &LocalSubjectAccessReview{}, ) - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } - -func (obj *LocalSubjectAccessReview) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } -func (obj *SubjectAccessReview) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } -func (obj *SelfSubjectAccessReview) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.generated.go index 011c08fca7..939603c58a 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.generated.go @@ -25,9 +25,8 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" "reflect" "runtime" time "time" @@ -63,11 +62,10 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg1_unversioned.TypeMeta - var v1 pkg2_v1.ObjectMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 } } @@ -159,7 +157,13 @@ func (x *SubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[2] { yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } @@ -168,26 +172,32 @@ func (x *SubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } @@ -196,8 +206,8 @@ func (x *SubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } if yyr2 || yy2arr2 { @@ -213,25 +223,25 @@ func (x *SubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl19, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl19, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -243,12 +253,12 @@ func (x *SubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -257,47 +267,65 @@ func (x *SubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = SubjectAccessReviewSpec{} } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = SubjectAccessReviewStatus{} } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -305,16 +333,16 @@ func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -322,15 +350,21 @@ func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -338,32 +372,44 @@ func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -371,16 +417,16 @@ func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Spec = SubjectAccessReviewSpec{} } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -388,21 +434,21 @@ func (x *SubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Status = SubjectAccessReviewStatus{} } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -414,38 +460,38 @@ func (x *SelfSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym32 := z.EncBinary() - _ = yym32 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [5]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Kind != "" - yyq33[1] = x.APIVersion != "" - yyq33[2] = true - yyq33[4] = true - var yynn33 int - if yyr33 || yy2arr33 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn33 = 1 - for _, b := range yyq33 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn33++ + yynn2++ } } - r.EncodeMapStart(yynn33) - yynn33 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -454,23 +500,23 @@ func (x *SelfSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - yym38 := z.EncBinary() - _ = yym38 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -479,64 +525,76 @@ func (x *SelfSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[2] { - yy41 := &x.ObjectMeta - yy41.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq33[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy42 := &x.ObjectMeta - yy42.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy44 := &x.Spec - yy44.CodecEncodeSelf(e) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy45 := &x.Spec - yy45.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[4] { - yy47 := &x.Status - yy47.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq33[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy48 := &x.Status - yy48.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -549,25 +607,25 @@ func (x *SelfSubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym49 := z.DecBinary() - _ = yym49 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct50 := r.ContainerType() - if yyct50 == codecSelferValueTypeMap1234 { - yyl50 := r.ReadMapStart() - if yyl50 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl50, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct50 == codecSelferValueTypeArray1234 { - yyl50 := r.ReadArrayStart() - if yyl50 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl50, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -579,12 +637,12 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys51Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys51Slc - var yyhl51 bool = l >= 0 - for yyj51 := 0; ; yyj51++ { - if yyhl51 { - if yyj51 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -593,47 +651,65 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys51Slc = r.DecodeBytes(yys51Slc, true, true) - yys51 := string(yys51Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys51 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv54 := &x.ObjectMeta - yyv54.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = SelfSubjectAccessReviewSpec{} } else { - yyv55 := &x.Spec - yyv55.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = SubjectAccessReviewStatus{} } else { - yyv56 := &x.Status - yyv56.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys51) - } // end switch yys51 - } // end for yyj51 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -641,16 +717,16 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj57 int - var yyb57 bool - var yyhl57 bool = l >= 0 - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -658,15 +734,21 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -674,32 +756,44 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv60 := &x.ObjectMeta - yyv60.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -707,16 +801,16 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Spec = SelfSubjectAccessReviewSpec{} } else { - yyv61 := &x.Spec - yyv61.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -724,21 +818,21 @@ func (x *SelfSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Status = SubjectAccessReviewStatus{} } else { - yyv62 := &x.Status - yyv62.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj57-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -750,38 +844,38 @@ func (x *LocalSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym63 := z.EncBinary() - _ = yym63 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep64 := !z.EncBinary() - yy2arr64 := z.EncBasicHandle().StructToArray - var yyq64 [5]bool - _, _, _ = yysep64, yyq64, yy2arr64 - const yyr64 bool = false - yyq64[0] = x.Kind != "" - yyq64[1] = x.APIVersion != "" - yyq64[2] = true - yyq64[4] = true - var yynn64 int - if yyr64 || yy2arr64 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn64 = 1 - for _, b := range yyq64 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn64++ + yynn2++ } } - r.EncodeMapStart(yynn64) - yynn64 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr64 || yy2arr64 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq64[0] { - yym66 := z.EncBinary() - _ = yym66 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -790,23 +884,23 @@ func (x *LocalSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq64[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym67 := z.EncBinary() - _ = yym67 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr64 || yy2arr64 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq64[1] { - yym69 := z.EncBinary() - _ = yym69 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -815,64 +909,76 @@ func (x *LocalSubjectAccessReview) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq64[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym70 := z.EncBinary() - _ = yym70 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr64 || yy2arr64 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq64[2] { - yy72 := &x.ObjectMeta - yy72.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq64[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy73 := &x.ObjectMeta - yy73.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr64 || yy2arr64 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy75 := &x.Spec - yy75.CodecEncodeSelf(e) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy76 := &x.Spec - yy76.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } - if yyr64 || yy2arr64 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq64[4] { - yy78 := &x.Status - yy78.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq64[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy79 := &x.Status - yy79.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr64 || yy2arr64 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -885,25 +991,25 @@ func (x *LocalSubjectAccessReview) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym80 := z.DecBinary() - _ = yym80 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct81 := r.ContainerType() - if yyct81 == codecSelferValueTypeMap1234 { - yyl81 := r.ReadMapStart() - if yyl81 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl81, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct81 == codecSelferValueTypeArray1234 { - yyl81 := r.ReadArrayStart() - if yyl81 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl81, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -915,12 +1021,12 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys82Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys82Slc - var yyhl82 bool = l >= 0 - for yyj82 := 0; ; yyj82++ { - if yyhl82 { - if yyj82 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -929,47 +1035,65 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromMap(l int, d *codec1978.De } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys82Slc = r.DecodeBytes(yys82Slc, true, true) - yys82 := string(yys82Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys82 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv85 := &x.ObjectMeta - yyv85.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = SubjectAccessReviewSpec{} } else { - yyv86 := &x.Spec - yyv86.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = SubjectAccessReviewStatus{} } else { - yyv87 := &x.Status - yyv87.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys82) - } // end switch yys82 - } // end for yyj82 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -977,16 +1101,16 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978. var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj88 int - var yyb88 bool - var yyhl88 bool = l >= 0 - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb88 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb88 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -994,15 +1118,21 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb88 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb88 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1010,32 +1140,44 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb88 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb88 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv91 := &x.ObjectMeta - yyv91.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb88 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb88 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1043,16 +1185,16 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Spec = SubjectAccessReviewSpec{} } else { - yyv92 := &x.Spec - yyv92.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb88 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb88 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1060,21 +1202,21 @@ func (x *LocalSubjectAccessReview) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Status = SubjectAccessReviewStatus{} } else { - yyv93 := &x.Status - yyv93.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb88 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb88 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj88-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1086,41 +1228,41 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym94 := z.EncBinary() - _ = yym94 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep95 := !z.EncBinary() - yy2arr95 := z.EncBasicHandle().StructToArray - var yyq95 [7]bool - _, _, _ = yysep95, yyq95, yy2arr95 - const yyr95 bool = false - yyq95[0] = x.Namespace != "" - yyq95[1] = x.Verb != "" - yyq95[2] = x.Group != "" - yyq95[3] = x.Version != "" - yyq95[4] = x.Resource != "" - yyq95[5] = x.Subresource != "" - yyq95[6] = x.Name != "" - var yynn95 int - if yyr95 || yy2arr95 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Namespace != "" + yyq2[1] = x.Verb != "" + yyq2[2] = x.Group != "" + yyq2[3] = x.Version != "" + yyq2[4] = x.Resource != "" + yyq2[5] = x.Subresource != "" + yyq2[6] = x.Name != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(7) } else { - yynn95 = 0 - for _, b := range yyq95 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn95++ + yynn2++ } } - r.EncodeMapStart(yynn95) - yynn95 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[0] { - yym97 := z.EncBinary() - _ = yym97 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) @@ -1129,23 +1271,23 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("namespace")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym98 := z.EncBinary() - _ = yym98 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[1] { - yym100 := z.EncBinary() - _ = yym100 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) @@ -1154,23 +1296,23 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("verb")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym101 := z.EncBinary() - _ = yym101 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[2] { - yym103 := z.EncBinary() - _ = yym103 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Group)) @@ -1179,23 +1321,23 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("group")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym104 := z.EncBinary() - _ = yym104 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Group)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[3] { - yym106 := z.EncBinary() - _ = yym106 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Version)) @@ -1204,23 +1346,23 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("version")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym107 := z.EncBinary() - _ = yym107 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Version)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[4] { - yym109 := z.EncBinary() - _ = yym109 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) @@ -1229,23 +1371,23 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resource")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym110 := z.EncBinary() - _ = yym110 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Resource)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[5] { - yym112 := z.EncBinary() - _ = yym112 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) @@ -1254,23 +1396,23 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("subresource")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym113 := z.EncBinary() - _ = yym113 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq95[6] { - yym115 := z.EncBinary() - _ = yym115 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -1279,19 +1421,19 @@ func (x *ResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq95[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym116 := z.EncBinary() - _ = yym116 + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr95 || yy2arr95 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1304,25 +1446,25 @@ func (x *ResourceAttributes) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym117 := z.DecBinary() - _ = yym117 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct118 := r.ContainerType() - if yyct118 == codecSelferValueTypeMap1234 { - yyl118 := r.ReadMapStart() - if yyl118 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl118, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct118 == codecSelferValueTypeArray1234 { - yyl118 := r.ReadArrayStart() - if yyl118 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl118, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1334,12 +1476,12 @@ func (x *ResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys119Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys119Slc - var yyhl119 bool = l >= 0 - for yyj119 := 0; ; yyj119++ { - if yyhl119 { - if yyj119 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1348,56 +1490,98 @@ func (x *ResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys119Slc = r.DecodeBytes(yys119Slc, true, true) - yys119 := string(yys119Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys119 { + switch yys3 { case "namespace": if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv4 := &x.Namespace + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "verb": if r.TryDecodeAsNil() { x.Verb = "" } else { - x.Verb = string(r.DecodeString()) + yyv6 := &x.Verb + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "group": if r.TryDecodeAsNil() { x.Group = "" } else { - x.Group = string(r.DecodeString()) + yyv8 := &x.Group + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "version": if r.TryDecodeAsNil() { x.Version = "" } else { - x.Version = string(r.DecodeString()) + yyv10 := &x.Version + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "resource": if r.TryDecodeAsNil() { x.Resource = "" } else { - x.Resource = string(r.DecodeString()) + yyv12 := &x.Resource + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } case "subresource": if r.TryDecodeAsNil() { x.Subresource = "" } else { - x.Subresource = string(r.DecodeString()) + yyv14 := &x.Subresource + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv16 := &x.Name + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys119) - } // end switch yys119 - } // end for yyj119 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1405,16 +1589,16 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj127 int - var yyb127 bool - var yyhl127 bool = l >= 0 - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + var yyj18 int + var yyb18 bool + var yyhl18 bool = l >= 0 + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1422,15 +1606,21 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv19 := &x.Namespace + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1438,15 +1628,21 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Verb = "" } else { - x.Verb = string(r.DecodeString()) + yyv21 := &x.Verb + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1454,15 +1650,21 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Group = "" } else { - x.Group = string(r.DecodeString()) + yyv23 := &x.Group + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1470,15 +1672,21 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Version = "" } else { - x.Version = string(r.DecodeString()) + yyv25 := &x.Version + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*string)(yyv25)) = r.DecodeString() + } } - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1486,15 +1694,21 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Resource = "" } else { - x.Resource = string(r.DecodeString()) + yyv27 := &x.Resource + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*string)(yyv27)) = r.DecodeString() + } } - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1502,15 +1716,21 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Subresource = "" } else { - x.Subresource = string(r.DecodeString()) + yyv29 := &x.Subresource + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*string)(yyv29)) = r.DecodeString() + } } - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1518,20 +1738,26 @@ func (x *ResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv31 := &x.Name + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*string)(yyv31)) = r.DecodeString() + } } for { - yyj127++ - if yyhl127 { - yyb127 = yyj127 > l + yyj18++ + if yyhl18 { + yyb18 = yyj18 > l } else { - yyb127 = r.CheckBreak() + yyb18 = r.CheckBreak() } - if yyb127 { + if yyb18 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj127-1, "") + z.DecStructFieldNotFound(yyj18-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1543,36 +1769,36 @@ func (x *NonResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym135 := z.EncBinary() - _ = yym135 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep136 := !z.EncBinary() - yy2arr136 := z.EncBasicHandle().StructToArray - var yyq136 [2]bool - _, _, _ = yysep136, yyq136, yy2arr136 - const yyr136 bool = false - yyq136[0] = x.Path != "" - yyq136[1] = x.Verb != "" - var yynn136 int - if yyr136 || yy2arr136 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Path != "" + yyq2[1] = x.Verb != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn136 = 0 - for _, b := range yyq136 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn136++ + yynn2++ } } - r.EncodeMapStart(yynn136) - yynn136 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr136 || yy2arr136 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq136[0] { - yym138 := z.EncBinary() - _ = yym138 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -1581,23 +1807,23 @@ func (x *NonResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq136[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym139 := z.EncBinary() - _ = yym139 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr136 || yy2arr136 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq136[1] { - yym141 := z.EncBinary() - _ = yym141 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) @@ -1606,19 +1832,19 @@ func (x *NonResourceAttributes) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq136[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("verb")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym142 := z.EncBinary() - _ = yym142 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Verb)) } } } - if yyr136 || yy2arr136 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1631,25 +1857,25 @@ func (x *NonResourceAttributes) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym143 := z.DecBinary() - _ = yym143 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct144 := r.ContainerType() - if yyct144 == codecSelferValueTypeMap1234 { - yyl144 := r.ReadMapStart() - if yyl144 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl144, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct144 == codecSelferValueTypeArray1234 { - yyl144 := r.ReadArrayStart() - if yyl144 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl144, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1661,12 +1887,12 @@ func (x *NonResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys145Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys145Slc - var yyhl145 bool = l >= 0 - for yyj145 := 0; ; yyj145++ { - if yyhl145 { - if yyj145 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1675,26 +1901,38 @@ func (x *NonResourceAttributes) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys145Slc = r.DecodeBytes(yys145Slc, true, true) - yys145 := string(yys145Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys145 { + switch yys3 { case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "verb": if r.TryDecodeAsNil() { x.Verb = "" } else { - x.Verb = string(r.DecodeString()) + yyv6 := &x.Verb + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys145) - } // end switch yys145 - } // end for yyj145 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1702,16 +1940,16 @@ func (x *NonResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj148 int - var yyb148 bool - var yyhl148 bool = l >= 0 - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb148 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb148 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1719,15 +1957,21 @@ func (x *NonResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv9 := &x.Path + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb148 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb148 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1735,20 +1979,26 @@ func (x *NonResourceAttributes) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Verb = "" } else { - x.Verb = string(r.DecodeString()) + yyv11 := &x.Verb + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb148 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb148 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj148-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1760,37 +2010,37 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym151 := z.EncBinary() - _ = yym151 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep152 := !z.EncBinary() - yy2arr152 := z.EncBasicHandle().StructToArray - var yyq152 [5]bool - _, _, _ = yysep152, yyq152, yy2arr152 - const yyr152 bool = false - yyq152[0] = x.ResourceAttributes != nil - yyq152[1] = x.NonResourceAttributes != nil - yyq152[2] = x.User != "" - yyq152[3] = len(x.Groups) != 0 - yyq152[4] = len(x.Extra) != 0 - var yynn152 int - if yyr152 || yy2arr152 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ResourceAttributes != nil + yyq2[1] = x.NonResourceAttributes != nil + yyq2[2] = x.User != "" + yyq2[3] = len(x.Groups) != 0 + yyq2[4] = len(x.Extra) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn152 = 0 - for _, b := range yyq152 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn152++ + yynn2++ } } - r.EncodeMapStart(yynn152) - yynn152 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr152 || yy2arr152 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq152[0] { + if yyq2[0] { if x.ResourceAttributes == nil { r.EncodeNil() } else { @@ -1800,7 +2050,7 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq152[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resourceAttributes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -1811,9 +2061,9 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr152 || yy2arr152 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq152[1] { + if yyq2[1] { if x.NonResourceAttributes == nil { r.EncodeNil() } else { @@ -1823,7 +2073,7 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq152[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nonResourceAttributes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -1834,11 +2084,11 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr152 || yy2arr152 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq152[2] { - yym156 := z.EncBinary() - _ = yym156 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) @@ -1847,26 +2097,26 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq152[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("user")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym157 := z.EncBinary() - _ = yym157 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.User)) } } } - if yyr152 || yy2arr152 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq152[3] { + if yyq2[3] { if x.Groups == nil { r.EncodeNil() } else { - yym159 := z.EncBinary() - _ = yym159 + yym13 := z.EncBinary() + _ = yym13 if false { } else { z.F.EncSliceStringV(x.Groups, false, e) @@ -1876,15 +2126,15 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq152[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("group")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Groups == nil { r.EncodeNil() } else { - yym160 := z.EncBinary() - _ = yym160 + yym14 := z.EncBinary() + _ = yym14 if false { } else { z.F.EncSliceStringV(x.Groups, false, e) @@ -1892,14 +2142,14 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr152 || yy2arr152 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq152[4] { + if yyq2[4] { if x.Extra == nil { r.EncodeNil() } else { - yym162 := z.EncBinary() - _ = yym162 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) @@ -1909,15 +2159,15 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq152[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("extra")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Extra == nil { r.EncodeNil() } else { - yym163 := z.EncBinary() - _ = yym163 + yym17 := z.EncBinary() + _ = yym17 if false { } else { h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) @@ -1925,7 +2175,7 @@ func (x *SubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr152 || yy2arr152 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1938,25 +2188,25 @@ func (x *SubjectAccessReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym164 := z.DecBinary() - _ = yym164 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct165 := r.ContainerType() - if yyct165 == codecSelferValueTypeMap1234 { - yyl165 := r.ReadMapStart() - if yyl165 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl165, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct165 == codecSelferValueTypeArray1234 { - yyl165 := r.ReadArrayStart() - if yyl165 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl165, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1968,12 +2218,12 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys166Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys166Slc - var yyhl166 bool = l >= 0 - for yyj166 := 0; ; yyj166++ { - if yyhl166 { - if yyj166 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1982,10 +2232,10 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys166Slc = r.DecodeBytes(yys166Slc, true, true) - yys166 := string(yys166Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys166 { + switch yys3 { case "resourceAttributes": if r.TryDecodeAsNil() { if x.ResourceAttributes != nil { @@ -2012,36 +2262,42 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv6 := &x.User + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "group": if r.TryDecodeAsNil() { x.Groups = nil } else { - yyv170 := &x.Groups - yym171 := z.DecBinary() - _ = yym171 + yyv8 := &x.Groups + yym9 := z.DecBinary() + _ = yym9 if false { } else { - z.F.DecSliceStringX(yyv170, false, d) + z.F.DecSliceStringX(yyv8, false, d) } } case "extra": if r.TryDecodeAsNil() { x.Extra = nil } else { - yyv172 := &x.Extra - yym173 := z.DecBinary() - _ = yym173 + yyv10 := &x.Extra + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv172), d) + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys166) - } // end switch yys166 - } // end for yyj166 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2049,16 +2305,16 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj174 int - var yyb174 bool - var yyhl174 bool = l >= 0 - yyj174++ - if yyhl174 { - yyb174 = yyj174 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb174 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb174 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2073,13 +2329,13 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.D } x.ResourceAttributes.CodecDecodeSelf(d) } - yyj174++ - if yyhl174 { - yyb174 = yyj174 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb174 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb174 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2094,13 +2350,13 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.D } x.NonResourceAttributes.CodecDecodeSelf(d) } - yyj174++ - if yyhl174 { - yyb174 = yyj174 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb174 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb174 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2108,15 +2364,21 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.User = "" } else { - x.User = string(r.DecodeString()) + yyv15 := &x.User + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj174++ - if yyhl174 { - yyb174 = yyj174 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb174 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb174 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2124,21 +2386,21 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Groups = nil } else { - yyv178 := &x.Groups - yym179 := z.DecBinary() - _ = yym179 + yyv17 := &x.Groups + yym18 := z.DecBinary() + _ = yym18 if false { } else { - z.F.DecSliceStringX(yyv178, false, d) + z.F.DecSliceStringX(yyv17, false, d) } } - yyj174++ - if yyhl174 { - yyb174 = yyj174 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb174 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb174 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2146,26 +2408,26 @@ func (x *SubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Extra = nil } else { - yyv180 := &x.Extra - yym181 := z.DecBinary() - _ = yym181 + yyv19 := &x.Extra + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decMapstringExtraValue((*map[string]ExtraValue)(yyv180), d) + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv19), d) } } for { - yyj174++ - if yyhl174 { - yyb174 = yyj174 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb174 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb174 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj174-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2177,8 +2439,8 @@ func (x ExtraValue) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym182 := z.EncBinary() - _ = yym182 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -2191,8 +2453,8 @@ func (x *ExtraValue) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym183 := z.DecBinary() - _ = yym183 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -2207,34 +2469,34 @@ func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym184 := z.EncBinary() - _ = yym184 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep185 := !z.EncBinary() - yy2arr185 := z.EncBasicHandle().StructToArray - var yyq185 [2]bool - _, _, _ = yysep185, yyq185, yy2arr185 - const yyr185 bool = false - yyq185[0] = x.ResourceAttributes != nil - yyq185[1] = x.NonResourceAttributes != nil - var yynn185 int - if yyr185 || yy2arr185 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ResourceAttributes != nil + yyq2[1] = x.NonResourceAttributes != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn185 = 0 - for _, b := range yyq185 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn185++ + yynn2++ } } - r.EncodeMapStart(yynn185) - yynn185 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr185 || yy2arr185 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq185[0] { + if yyq2[0] { if x.ResourceAttributes == nil { r.EncodeNil() } else { @@ -2244,7 +2506,7 @@ func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq185[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resourceAttributes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -2255,9 +2517,9 @@ func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr185 || yy2arr185 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq185[1] { + if yyq2[1] { if x.NonResourceAttributes == nil { r.EncodeNil() } else { @@ -2267,7 +2529,7 @@ func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq185[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nonResourceAttributes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -2278,7 +2540,7 @@ func (x *SelfSubjectAccessReviewSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr185 || yy2arr185 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2291,25 +2553,25 @@ func (x *SelfSubjectAccessReviewSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym188 := z.DecBinary() - _ = yym188 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct189 := r.ContainerType() - if yyct189 == codecSelferValueTypeMap1234 { - yyl189 := r.ReadMapStart() - if yyl189 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl189, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct189 == codecSelferValueTypeArray1234 { - yyl189 := r.ReadArrayStart() - if yyl189 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl189, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2321,12 +2583,12 @@ func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys190Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys190Slc - var yyhl190 bool = l >= 0 - for yyj190 := 0; ; yyj190++ { - if yyhl190 { - if yyj190 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2335,10 +2597,10 @@ func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys190Slc = r.DecodeBytes(yys190Slc, true, true) - yys190 := string(yys190Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys190 { + switch yys3 { case "resourceAttributes": if r.TryDecodeAsNil() { if x.ResourceAttributes != nil { @@ -2362,9 +2624,9 @@ func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromMap(l int, d *codec1978 x.NonResourceAttributes.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys190) - } // end switch yys190 - } // end for yyj190 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2372,16 +2634,16 @@ func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj193 int - var yyb193 bool - var yyhl193 bool = l >= 0 - yyj193++ - if yyhl193 { - yyb193 = yyj193 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb193 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb193 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2396,13 +2658,13 @@ func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec19 } x.ResourceAttributes.CodecDecodeSelf(d) } - yyj193++ - if yyhl193 { - yyb193 = yyj193 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb193 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb193 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2418,17 +2680,17 @@ func (x *SelfSubjectAccessReviewSpec) codecDecodeSelfFromArray(l int, d *codec19 x.NonResourceAttributes.CodecDecodeSelf(d) } for { - yyj193++ - if yyhl193 { - yyb193 = yyj193 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb193 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb193 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj193-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2440,35 +2702,35 @@ func (x *SubjectAccessReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym196 := z.EncBinary() - _ = yym196 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep197 := !z.EncBinary() - yy2arr197 := z.EncBasicHandle().StructToArray - var yyq197 [3]bool - _, _, _ = yysep197, yyq197, yy2arr197 - const yyr197 bool = false - yyq197[1] = x.Reason != "" - yyq197[2] = x.EvaluationError != "" - var yynn197 int - if yyr197 || yy2arr197 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Reason != "" + yyq2[2] = x.EvaluationError != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn197 = 1 - for _, b := range yyq197 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn197++ + yynn2++ } } - r.EncodeMapStart(yynn197) - yynn197 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr197 || yy2arr197 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym199 := z.EncBinary() - _ = yym199 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeBool(bool(x.Allowed)) @@ -2477,18 +2739,18 @@ func (x *SubjectAccessReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("allowed")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym200 := z.EncBinary() - _ = yym200 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeBool(bool(x.Allowed)) } } - if yyr197 || yy2arr197 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq197[1] { - yym202 := z.EncBinary() - _ = yym202 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -2497,23 +2759,23 @@ func (x *SubjectAccessReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq197[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym203 := z.EncBinary() - _ = yym203 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr197 || yy2arr197 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq197[2] { - yym205 := z.EncBinary() - _ = yym205 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.EvaluationError)) @@ -2522,19 +2784,19 @@ func (x *SubjectAccessReviewStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq197[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("evaluationError")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym206 := z.EncBinary() - _ = yym206 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.EvaluationError)) } } } - if yyr197 || yy2arr197 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2547,25 +2809,25 @@ func (x *SubjectAccessReviewStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym207 := z.DecBinary() - _ = yym207 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct208 := r.ContainerType() - if yyct208 == codecSelferValueTypeMap1234 { - yyl208 := r.ReadMapStart() - if yyl208 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl208, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct208 == codecSelferValueTypeArray1234 { - yyl208 := r.ReadArrayStart() - if yyl208 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl208, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2577,12 +2839,12 @@ func (x *SubjectAccessReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys209Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys209Slc - var yyhl209 bool = l >= 0 - for yyj209 := 0; ; yyj209++ { - if yyhl209 { - if yyj209 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2591,32 +2853,50 @@ func (x *SubjectAccessReviewStatus) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys209Slc = r.DecodeBytes(yys209Slc, true, true) - yys209 := string(yys209Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys209 { + switch yys3 { case "allowed": if r.TryDecodeAsNil() { x.Allowed = false } else { - x.Allowed = bool(r.DecodeBool()) + yyv4 := &x.Allowed + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv6 := &x.Reason + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "evaluationError": if r.TryDecodeAsNil() { x.EvaluationError = "" } else { - x.EvaluationError = string(r.DecodeString()) + yyv8 := &x.EvaluationError + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys209) - } // end switch yys209 - } // end for yyj209 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2624,16 +2904,16 @@ func (x *SubjectAccessReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj213 int - var yyb213 bool - var yyhl213 bool = l >= 0 - yyj213++ - if yyhl213 { - yyb213 = yyj213 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb213 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb213 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2641,15 +2921,21 @@ func (x *SubjectAccessReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Allowed = false } else { - x.Allowed = bool(r.DecodeBool()) + yyv11 := &x.Allowed + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*bool)(yyv11)) = r.DecodeBool() + } } - yyj213++ - if yyhl213 { - yyb213 = yyj213 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb213 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb213 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2657,15 +2943,21 @@ func (x *SubjectAccessReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv13 := &x.Reason + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj213++ - if yyhl213 { - yyb213 = yyj213 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb213 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb213 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2673,20 +2965,26 @@ func (x *SubjectAccessReviewStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.EvaluationError = "" } else { - x.EvaluationError = string(r.DecodeString()) + yyv15 := &x.EvaluationError + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj213++ - if yyhl213 { - yyb213 = yyj213 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb213 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb213 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj213-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2696,19 +2994,19 @@ func (x codecSelfer1234) encMapstringExtraValue(v map[string]ExtraValue, e *code z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeMapStart(len(v)) - for yyk217, yyv217 := range v { + for yyk1, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym218 := z.EncBinary() - _ = yym218 + yym2 := z.EncBinary() + _ = yym2 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk217)) + r.EncodeString(codecSelferC_UTF81234, string(yyk1)) } z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyv217 == nil { + if yyv1 == nil { r.EncodeNil() } else { - yyv217.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } } z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2719,70 +3017,82 @@ func (x codecSelfer1234) decMapstringExtraValue(v *map[string]ExtraValue, d *cod z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv219 := *v - yyl219 := r.ReadMapStart() - yybh219 := z.DecBasicHandle() - if yyv219 == nil { - yyrl219, _ := z.DecInferLen(yyl219, yybh219.MaxInitLen, 40) - yyv219 = make(map[string]ExtraValue, yyrl219) - *v = yyv219 - } - var yymk219 string - var yymv219 ExtraValue - var yymg219 bool - if yybh219.MapValueReset { - yymg219 = true - } - if yyl219 > 0 { - for yyj219 := 0; yyj219 < yyl219; yyj219++ { + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string]ExtraValue, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 ExtraValue + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk219 = "" + yymk1 = "" } else { - yymk219 = string(r.DecodeString()) + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } } - if yymg219 { - yymv219 = yyv219[yymk219] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv219 = nil + yymv1 = nil } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv219 = nil + yymv1 = nil } else { - yyv221 := &yymv219 - yyv221.CodecDecodeSelf(d) + yyv4 := &yymv1 + yyv4.CodecDecodeSelf(d) } - if yyv219 != nil { - yyv219[yymk219] = yymv219 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } - } else if yyl219 < 0 { - for yyj219 := 0; !r.CheckBreak(); yyj219++ { + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk219 = "" + yymk1 = "" } else { - yymk219 = string(r.DecodeString()) + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } } - if yymg219 { - yymv219 = yyv219[yymk219] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv219 = nil + yymv1 = nil } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv219 = nil + yymv1 = nil } else { - yyv223 := &yymv219 - yyv223.CodecDecodeSelf(d) + yyv7 := &yymv1 + yyv7.CodecDecodeSelf(d) } - if yyv219 != nil { - yyv219[yymk219] = yymv219 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } } // else len==0: TODO: Should we clear map entries? @@ -2794,13 +3104,13 @@ func (x codecSelfer1234) encExtraValue(v ExtraValue, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv224 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym225 := z.EncBinary() - _ = yym225 + yym2 := z.EncBinary() + _ = yym2 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yyv224)) + r.EncodeString(codecSelferC_UTF81234, string(yyv1)) } } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) @@ -2811,75 +3121,96 @@ func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv226 := *v - yyh226, yyl226 := z.DecSliceHelperStart() - var yyc226 bool - if yyl226 == 0 { - if yyv226 == nil { - yyv226 = []string{} - yyc226 = true - } else if len(yyv226) != 0 { - yyv226 = yyv226[:0] - yyc226 = true - } - } else if yyl226 > 0 { - var yyrr226, yyrl226 int - var yyrt226 bool - if yyl226 > cap(yyv226) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl226, yyrt226 = z.DecInferLen(yyl226, z.DecBasicHandle().MaxInitLen, 16) - if yyrt226 { - if yyrl226 <= cap(yyv226) { - yyv226 = yyv226[:yyrl226] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv226 = make([]string, yyrl226) + yyv1 = make([]string, yyrl1) } } else { - yyv226 = make([]string, yyrl226) + yyv1 = make([]string, yyrl1) } - yyc226 = true - yyrr226 = len(yyv226) - } else if yyl226 != len(yyv226) { - yyv226 = yyv226[:yyl226] - yyc226 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj226 := 0 - for ; yyj226 < yyrr226; yyj226++ { - yyh226.ElemContainerState(yyj226) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv226[yyj226] = "" + yyv1[yyj1] = "" } else { - yyv226[yyj226] = string(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } } } - if yyrt226 { - for ; yyj226 < yyl226; yyj226++ { - yyv226 = append(yyv226, "") - yyh226.ElemContainerState(yyj226) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv226[yyj226] = "" + yyv1[yyj1] = "" } else { - yyv226[yyj226] = string(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } } } } else { - yyj226 := 0 - for ; !r.CheckBreak(); yyj226++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj226 >= len(yyv226) { - yyv226 = append(yyv226, "") // var yyz226 string - yyc226 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 string + yyc1 = true } - yyh226.ElemContainerState(yyj226) - if yyj226 < len(yyv226) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv226[yyj226] = "" + yyv1[yyj1] = "" } else { - yyv226[yyj226] = string(r.DecodeString()) + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } } else { @@ -2887,16 +3218,16 @@ func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { } } - if yyj226 < len(yyv226) { - yyv226 = yyv226[:yyj226] - yyc226 = true - } else if yyj226 == 0 && yyv226 == nil { - yyv226 = []string{} - yyc226 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []string{} + yyc1 = true } } - yyh226.End() - if yyc226 { - *v = yyv226 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.go index b254b3b02c..8a1727423b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/types.go @@ -19,8 +19,7 @@ package v1beta1 import ( "fmt" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // +genclient=true @@ -29,9 +28,9 @@ import ( // SubjectAccessReview checks whether or not a user or group can perform an action. type SubjectAccessReview struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec holds information about the request being evaluated Spec SubjectAccessReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` @@ -49,9 +48,9 @@ type SubjectAccessReview struct { // spec.namespace means "in all namespaces". Self is a special case, because users should always be able // to check whether they can perform an action type SelfSubjectAccessReview struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec holds information about the request being evaluated. user and groups must be empty Spec SelfSubjectAccessReviewSpec `json:"spec" protobuf:"bytes,2,opt,name=spec"` @@ -68,9 +67,9 @@ type SelfSubjectAccessReview struct { // Having a namespace scoped resource makes it much easier to grant namespace scoped policy that includes permissions // checking. type LocalSubjectAccessReview struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec holds information about the request being evaluated. spec.namespace must be equal to the namespace // you made the request against. If empty, it is defaulted. diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.conversion.go index 28fed4a7b5..dc74214f1e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1beta1 import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" authorization "k8s.io/client-go/pkg/apis/authorization" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -55,10 +55,7 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v1beta1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview(in *LocalSubjectAccessReview, out *authorization.LocalSubjectAccessReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -68,15 +65,13 @@ func autoConvert_v1beta1_LocalSubjectAccessReview_To_authorization_LocalSubjectA return nil } +// Convert_v1beta1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview is an autogenerated conversion function. func Convert_v1beta1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview(in *LocalSubjectAccessReview, out *authorization.LocalSubjectAccessReview, s conversion.Scope) error { return autoConvert_v1beta1_LocalSubjectAccessReview_To_authorization_LocalSubjectAccessReview(in, out, s) } func autoConvert_authorization_LocalSubjectAccessReview_To_v1beta1_LocalSubjectAccessReview(in *authorization.LocalSubjectAccessReview, out *LocalSubjectAccessReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_authorization_SubjectAccessReviewSpec_To_v1beta1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -86,6 +81,7 @@ func autoConvert_authorization_LocalSubjectAccessReview_To_v1beta1_LocalSubjectA return nil } +// Convert_authorization_LocalSubjectAccessReview_To_v1beta1_LocalSubjectAccessReview is an autogenerated conversion function. func Convert_authorization_LocalSubjectAccessReview_To_v1beta1_LocalSubjectAccessReview(in *authorization.LocalSubjectAccessReview, out *LocalSubjectAccessReview, s conversion.Scope) error { return autoConvert_authorization_LocalSubjectAccessReview_To_v1beta1_LocalSubjectAccessReview(in, out, s) } @@ -96,6 +92,7 @@ func autoConvert_v1beta1_NonResourceAttributes_To_authorization_NonResourceAttri return nil } +// Convert_v1beta1_NonResourceAttributes_To_authorization_NonResourceAttributes is an autogenerated conversion function. func Convert_v1beta1_NonResourceAttributes_To_authorization_NonResourceAttributes(in *NonResourceAttributes, out *authorization.NonResourceAttributes, s conversion.Scope) error { return autoConvert_v1beta1_NonResourceAttributes_To_authorization_NonResourceAttributes(in, out, s) } @@ -106,6 +103,7 @@ func autoConvert_authorization_NonResourceAttributes_To_v1beta1_NonResourceAttri return nil } +// Convert_authorization_NonResourceAttributes_To_v1beta1_NonResourceAttributes is an autogenerated conversion function. func Convert_authorization_NonResourceAttributes_To_v1beta1_NonResourceAttributes(in *authorization.NonResourceAttributes, out *NonResourceAttributes, s conversion.Scope) error { return autoConvert_authorization_NonResourceAttributes_To_v1beta1_NonResourceAttributes(in, out, s) } @@ -121,6 +119,7 @@ func autoConvert_v1beta1_ResourceAttributes_To_authorization_ResourceAttributes( return nil } +// Convert_v1beta1_ResourceAttributes_To_authorization_ResourceAttributes is an autogenerated conversion function. func Convert_v1beta1_ResourceAttributes_To_authorization_ResourceAttributes(in *ResourceAttributes, out *authorization.ResourceAttributes, s conversion.Scope) error { return autoConvert_v1beta1_ResourceAttributes_To_authorization_ResourceAttributes(in, out, s) } @@ -136,15 +135,13 @@ func autoConvert_authorization_ResourceAttributes_To_v1beta1_ResourceAttributes( return nil } +// Convert_authorization_ResourceAttributes_To_v1beta1_ResourceAttributes is an autogenerated conversion function. func Convert_authorization_ResourceAttributes_To_v1beta1_ResourceAttributes(in *authorization.ResourceAttributes, out *ResourceAttributes, s conversion.Scope) error { return autoConvert_authorization_ResourceAttributes_To_v1beta1_ResourceAttributes(in, out, s) } func autoConvert_v1beta1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview(in *SelfSubjectAccessReview, out *authorization.SelfSubjectAccessReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -154,15 +151,13 @@ func autoConvert_v1beta1_SelfSubjectAccessReview_To_authorization_SelfSubjectAcc return nil } +// Convert_v1beta1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview is an autogenerated conversion function. func Convert_v1beta1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview(in *SelfSubjectAccessReview, out *authorization.SelfSubjectAccessReview, s conversion.Scope) error { return autoConvert_v1beta1_SelfSubjectAccessReview_To_authorization_SelfSubjectAccessReview(in, out, s) } func autoConvert_authorization_SelfSubjectAccessReview_To_v1beta1_SelfSubjectAccessReview(in *authorization.SelfSubjectAccessReview, out *SelfSubjectAccessReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_authorization_SelfSubjectAccessReviewSpec_To_v1beta1_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -172,6 +167,7 @@ func autoConvert_authorization_SelfSubjectAccessReview_To_v1beta1_SelfSubjectAcc return nil } +// Convert_authorization_SelfSubjectAccessReview_To_v1beta1_SelfSubjectAccessReview is an autogenerated conversion function. func Convert_authorization_SelfSubjectAccessReview_To_v1beta1_SelfSubjectAccessReview(in *authorization.SelfSubjectAccessReview, out *SelfSubjectAccessReview, s conversion.Scope) error { return autoConvert_authorization_SelfSubjectAccessReview_To_v1beta1_SelfSubjectAccessReview(in, out, s) } @@ -182,6 +178,7 @@ func autoConvert_v1beta1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjec return nil } +// Convert_v1beta1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec is an autogenerated conversion function. func Convert_v1beta1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(in *SelfSubjectAccessReviewSpec, out *authorization.SelfSubjectAccessReviewSpec, s conversion.Scope) error { return autoConvert_v1beta1_SelfSubjectAccessReviewSpec_To_authorization_SelfSubjectAccessReviewSpec(in, out, s) } @@ -192,15 +189,13 @@ func autoConvert_authorization_SelfSubjectAccessReviewSpec_To_v1beta1_SelfSubjec return nil } +// Convert_authorization_SelfSubjectAccessReviewSpec_To_v1beta1_SelfSubjectAccessReviewSpec is an autogenerated conversion function. func Convert_authorization_SelfSubjectAccessReviewSpec_To_v1beta1_SelfSubjectAccessReviewSpec(in *authorization.SelfSubjectAccessReviewSpec, out *SelfSubjectAccessReviewSpec, s conversion.Scope) error { return autoConvert_authorization_SelfSubjectAccessReviewSpec_To_v1beta1_SelfSubjectAccessReviewSpec(in, out, s) } func autoConvert_v1beta1_SubjectAccessReview_To_authorization_SubjectAccessReview(in *SubjectAccessReview, out *authorization.SubjectAccessReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -210,15 +205,13 @@ func autoConvert_v1beta1_SubjectAccessReview_To_authorization_SubjectAccessRevie return nil } +// Convert_v1beta1_SubjectAccessReview_To_authorization_SubjectAccessReview is an autogenerated conversion function. func Convert_v1beta1_SubjectAccessReview_To_authorization_SubjectAccessReview(in *SubjectAccessReview, out *authorization.SubjectAccessReview, s conversion.Scope) error { return autoConvert_v1beta1_SubjectAccessReview_To_authorization_SubjectAccessReview(in, out, s) } func autoConvert_authorization_SubjectAccessReview_To_v1beta1_SubjectAccessReview(in *authorization.SubjectAccessReview, out *SubjectAccessReview, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_authorization_SubjectAccessReviewSpec_To_v1beta1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -228,6 +221,7 @@ func autoConvert_authorization_SubjectAccessReview_To_v1beta1_SubjectAccessRevie return nil } +// Convert_authorization_SubjectAccessReview_To_v1beta1_SubjectAccessReview is an autogenerated conversion function. func Convert_authorization_SubjectAccessReview_To_v1beta1_SubjectAccessReview(in *authorization.SubjectAccessReview, out *SubjectAccessReview, s conversion.Scope) error { return autoConvert_authorization_SubjectAccessReview_To_v1beta1_SubjectAccessReview(in, out, s) } @@ -241,6 +235,7 @@ func autoConvert_v1beta1_SubjectAccessReviewSpec_To_authorization_SubjectAccessR return nil } +// Convert_v1beta1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec is an autogenerated conversion function. func Convert_v1beta1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(in *SubjectAccessReviewSpec, out *authorization.SubjectAccessReviewSpec, s conversion.Scope) error { return autoConvert_v1beta1_SubjectAccessReviewSpec_To_authorization_SubjectAccessReviewSpec(in, out, s) } @@ -254,6 +249,7 @@ func autoConvert_authorization_SubjectAccessReviewSpec_To_v1beta1_SubjectAccessR return nil } +// Convert_authorization_SubjectAccessReviewSpec_To_v1beta1_SubjectAccessReviewSpec is an autogenerated conversion function. func Convert_authorization_SubjectAccessReviewSpec_To_v1beta1_SubjectAccessReviewSpec(in *authorization.SubjectAccessReviewSpec, out *SubjectAccessReviewSpec, s conversion.Scope) error { return autoConvert_authorization_SubjectAccessReviewSpec_To_v1beta1_SubjectAccessReviewSpec(in, out, s) } @@ -265,6 +261,7 @@ func autoConvert_v1beta1_SubjectAccessReviewStatus_To_authorization_SubjectAcces return nil } +// Convert_v1beta1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus is an autogenerated conversion function. func Convert_v1beta1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(in *SubjectAccessReviewStatus, out *authorization.SubjectAccessReviewStatus, s conversion.Scope) error { return autoConvert_v1beta1_SubjectAccessReviewStatus_To_authorization_SubjectAccessReviewStatus(in, out, s) } @@ -276,6 +273,7 @@ func autoConvert_authorization_SubjectAccessReviewStatus_To_v1beta1_SubjectAcces return nil } +// Convert_authorization_SubjectAccessReviewStatus_To_v1beta1_SubjectAccessReviewStatus is an autogenerated conversion function. func Convert_authorization_SubjectAccessReviewStatus_To_v1beta1_SubjectAccessReviewStatus(in *authorization.SubjectAccessReviewStatus, out *SubjectAccessReviewStatus, s conversion.Scope) error { return autoConvert_authorization_SubjectAccessReviewStatus_To_v1beta1_SubjectAccessReviewStatus(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.deepcopy.go index 373c279ec2..fe99f28448 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1beta1 import ( - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -46,126 +46,120 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_LocalSubjectAccessReview is an autogenerated deepcopy function. func DeepCopy_v1beta1_LocalSubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LocalSubjectAccessReview) out := out.(*LocalSubjectAccessReview) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_v1beta1_NonResourceAttributes is an autogenerated deepcopy function. func DeepCopy_v1beta1_NonResourceAttributes(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NonResourceAttributes) out := out.(*NonResourceAttributes) - out.Path = in.Path - out.Verb = in.Verb + *out = *in return nil } } +// DeepCopy_v1beta1_ResourceAttributes is an autogenerated deepcopy function. func DeepCopy_v1beta1_ResourceAttributes(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceAttributes) out := out.(*ResourceAttributes) - out.Namespace = in.Namespace - out.Verb = in.Verb - out.Group = in.Group - out.Version = in.Version - out.Resource = in.Resource - out.Subresource = in.Subresource - out.Name = in.Name + *out = *in return nil } } +// DeepCopy_v1beta1_SelfSubjectAccessReview is an autogenerated deepcopy function. func DeepCopy_v1beta1_SelfSubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SelfSubjectAccessReview) out := out.(*SelfSubjectAccessReview) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_v1beta1_SelfSubjectAccessReviewSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_SelfSubjectAccessReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SelfSubjectAccessReviewSpec) out := out.(*SelfSubjectAccessReviewSpec) + *out = *in if in.ResourceAttributes != nil { in, out := &in.ResourceAttributes, &out.ResourceAttributes *out = new(ResourceAttributes) **out = **in - } else { - out.ResourceAttributes = nil } if in.NonResourceAttributes != nil { in, out := &in.NonResourceAttributes, &out.NonResourceAttributes *out = new(NonResourceAttributes) **out = **in - } else { - out.NonResourceAttributes = nil } return nil } } +// DeepCopy_v1beta1_SubjectAccessReview is an autogenerated deepcopy function. func DeepCopy_v1beta1_SubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SubjectAccessReview) out := out.(*SubjectAccessReview) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_SubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_v1beta1_SubjectAccessReviewSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_SubjectAccessReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SubjectAccessReviewSpec) out := out.(*SubjectAccessReviewSpec) + *out = *in if in.ResourceAttributes != nil { in, out := &in.ResourceAttributes, &out.ResourceAttributes *out = new(ResourceAttributes) **out = **in - } else { - out.ResourceAttributes = nil } if in.NonResourceAttributes != nil { in, out := &in.NonResourceAttributes, &out.NonResourceAttributes *out = new(NonResourceAttributes) **out = **in - } else { - out.NonResourceAttributes = nil } - out.User = in.User if in.Groups != nil { in, out := &in.Groups, &out.Groups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Groups = nil } if in.Extra != nil { in, out := &in.Extra, &out.Extra @@ -177,20 +171,17 @@ func DeepCopy_v1beta1_SubjectAccessReviewSpec(in interface{}, out interface{}, c (*out)[key] = *newVal.(*ExtraValue) } } - } else { - out.Extra = nil } return nil } } +// DeepCopy_v1beta1_SubjectAccessReviewStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_SubjectAccessReviewStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SubjectAccessReviewStatus) out := out.(*SubjectAccessReviewStatus) - out.Allowed = in.Allowed - out.Reason = in.Reason - out.EvaluationError = in.EvaluationError + *out = *in return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.defaults.go new file mode 100644 index 0000000000..e24e70be38 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/v1beta1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1beta1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/authorization/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/authorization/zz_generated.deepcopy.go index ce703736f5..74c83c56a7 100644 --- a/vendor/k8s.io/client-go/pkg/apis/authorization/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/authorization/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package authorization import ( - api "k8s.io/client-go/pkg/api" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -46,126 +46,120 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_authorization_LocalSubjectAccessReview is an autogenerated deepcopy function. func DeepCopy_authorization_LocalSubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*LocalSubjectAccessReview) out := out.(*LocalSubjectAccessReview) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_authorization_SubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_authorization_NonResourceAttributes is an autogenerated deepcopy function. func DeepCopy_authorization_NonResourceAttributes(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NonResourceAttributes) out := out.(*NonResourceAttributes) - out.Path = in.Path - out.Verb = in.Verb + *out = *in return nil } } +// DeepCopy_authorization_ResourceAttributes is an autogenerated deepcopy function. func DeepCopy_authorization_ResourceAttributes(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ResourceAttributes) out := out.(*ResourceAttributes) - out.Namespace = in.Namespace - out.Verb = in.Verb - out.Group = in.Group - out.Version = in.Version - out.Resource = in.Resource - out.Subresource = in.Subresource - out.Name = in.Name + *out = *in return nil } } +// DeepCopy_authorization_SelfSubjectAccessReview is an autogenerated deepcopy function. func DeepCopy_authorization_SelfSubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SelfSubjectAccessReview) out := out.(*SelfSubjectAccessReview) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_authorization_SelfSubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_authorization_SelfSubjectAccessReviewSpec is an autogenerated deepcopy function. func DeepCopy_authorization_SelfSubjectAccessReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SelfSubjectAccessReviewSpec) out := out.(*SelfSubjectAccessReviewSpec) + *out = *in if in.ResourceAttributes != nil { in, out := &in.ResourceAttributes, &out.ResourceAttributes *out = new(ResourceAttributes) **out = **in - } else { - out.ResourceAttributes = nil } if in.NonResourceAttributes != nil { in, out := &in.NonResourceAttributes, &out.NonResourceAttributes *out = new(NonResourceAttributes) **out = **in - } else { - out.NonResourceAttributes = nil } return nil } } +// DeepCopy_authorization_SubjectAccessReview is an autogenerated deepcopy function. func DeepCopy_authorization_SubjectAccessReview(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SubjectAccessReview) out := out.(*SubjectAccessReview) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_authorization_SubjectAccessReviewSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status return nil } } +// DeepCopy_authorization_SubjectAccessReviewSpec is an autogenerated deepcopy function. func DeepCopy_authorization_SubjectAccessReviewSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SubjectAccessReviewSpec) out := out.(*SubjectAccessReviewSpec) + *out = *in if in.ResourceAttributes != nil { in, out := &in.ResourceAttributes, &out.ResourceAttributes *out = new(ResourceAttributes) **out = **in - } else { - out.ResourceAttributes = nil } if in.NonResourceAttributes != nil { in, out := &in.NonResourceAttributes, &out.NonResourceAttributes *out = new(NonResourceAttributes) **out = **in - } else { - out.NonResourceAttributes = nil } - out.User = in.User if in.Groups != nil { in, out := &in.Groups, &out.Groups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Groups = nil } if in.Extra != nil { in, out := &in.Extra, &out.Extra @@ -177,20 +171,17 @@ func DeepCopy_authorization_SubjectAccessReviewSpec(in interface{}, out interfac (*out)[key] = *newVal.(*ExtraValue) } } - } else { - out.Extra = nil } return nil } } +// DeepCopy_authorization_SubjectAccessReviewStatus is an autogenerated deepcopy function. func DeepCopy_authorization_SubjectAccessReviewStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SubjectAccessReviewStatus) out := out.(*SubjectAccessReviewStatus) - out.Allowed = in.Allowed - out.Reason = in.Reason - out.EvaluationError = in.EvaluationError + *out = *in return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/BUILD b/vendor/k8s.io/client-go/pkg/apis/autoscaling/BUILD new file mode 100644 index 0000000000..f2d4141e70 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/BUILD @@ -0,0 +1,28 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "annotations.go", + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/OWNERS b/vendor/k8s.io/client-go/pkg/apis/autoscaling/OWNERS new file mode 100755 index 0000000000..76dffecebd --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/OWNERS @@ -0,0 +1,20 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- caesarxuchao +- erictune +- sttts +- ncdc +- timothysc +- piosz +- dims +- errordeveloper +- madhusudancs +- mml +- mbohlool +- david-mcmahon +- jianhuiz +- directxman12 diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/annotations.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/annotations.go new file mode 100644 index 0000000000..c6586ea706 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/annotations.go @@ -0,0 +1,34 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package autoscaling + +// MetricSpecsAnnotation is the annotation which holds non-CPU-utilization HPA metric +// specs when converting the `Metrics` field from autoscaling/v2alpha1 +const MetricSpecsAnnotation = "autoscaling.alpha.kubernetes.io/metrics" + +// MetricStatusesAnnotation is the annotation which holds non-CPU-utilization HPA metric +// statuses when converting the `CurrentMetrics` field from autoscaling/v2alpha1 +const MetricStatusesAnnotation = "autoscaling.alpha.kubernetes.io/current-metrics" + +// HorizontalPodAutoscalerConditionsAnnotation is the annotation which holds the conditions +// of an HPA when converting the `Conditions` field from autoscaling/v2alpha1 +const HorizontalPodAutoscalerConditionsAnnotation = "autoscaling.alpha.kubernetes.io/conditions" + +// DefaultCPUUtilization is the default value for CPU utilization, provided no other +// metrics are present. This is here because it's used by both the v2alpha1 defaulting +// logic, and the pseudo-defaulting done in v1 conversion. +const DefaultCPUUtilization = 80 diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/doc.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/doc.go index 7550f9d2b2..83ac827674 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/doc.go @@ -14,7 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - package autoscaling diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/install/install.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/install/install.go deleted file mode 100644 index 060aa07747..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/install/install.go +++ /dev/null @@ -1,41 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the experimental API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/autoscaling" - "k8s.io/client-go/pkg/apis/autoscaling/v1" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: autoscaling.GroupName, - VersionPreferenceOrder: []string{v1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/autoscaling", - AddInternalObjectsToScheme: autoscaling.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1.SchemeGroupVersion.Version: v1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/register.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/register.go index d4aa8ee018..2bcea84b9b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/register.go @@ -17,24 +17,23 @@ limitations under the License. package autoscaling import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "autoscaling" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -49,7 +48,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { &Scale{}, &HorizontalPodAutoscaler{}, &HorizontalPodAutoscalerList{}, - &api.ListOptions{}, ) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.generated.go deleted file mode 100644 index 89e5ff87e4..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.generated.go +++ /dev/null @@ -1,2656 +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 autoscaling - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - "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 pkg2_api.ObjectMeta - var v1 pkg1_unversioned.TypeMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 - } -} - -func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = true - yyq2[3] = true - yyq2[4] = true - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Scale) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl19, d) - } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl19, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *Scale) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ScaleSpec{} - } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ScaleStatus{} - } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ScaleSpec{} - } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ScaleStatus{} - } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ScaleSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [1]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Replicas != 0 - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(1) - } else { - yynn33 = 0 - for _, b := range yyq33 { - if b { - yynn33++ - } - } - r.EncodeMapStart(yynn33) - yynn33 = 0 - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq33[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ScaleSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym37 := z.DecBinary() - _ = yym37 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct38 := r.ContainerType() - if yyct38 == codecSelferValueTypeMap1234 { - yyl38 := r.ReadMapStart() - if yyl38 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl38, d) - } - } else if yyct38 == codecSelferValueTypeArray1234 { - yyl38 := r.ReadArrayStart() - if yyl38 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl38, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys39Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys39Slc - var yyhl39 bool = l >= 0 - for yyj39 := 0; ; yyj39++ { - if yyhl39 { - if yyj39 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys39Slc = r.DecodeBytes(yys39Slc, true, true) - yys39 := string(yys39Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys39 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys39) - } // end switch yys39 - } // end for yyj39 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj41 int - var yyb41 bool - var yyhl41 bool = l >= 0 - yyj41++ - if yyhl41 { - yyb41 = yyj41 > l - } else { - yyb41 = r.CheckBreak() - } - if yyb41 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - for { - yyj41++ - if yyhl41 { - yyb41 = yyj41 > l - } else { - yyb41 = r.CheckBreak() - } - if yyb41 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj41-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym43 := z.EncBinary() - _ = yym43 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep44 := !z.EncBinary() - yy2arr44 := z.EncBasicHandle().StructToArray - var yyq44 [2]bool - _, _, _ = yysep44, yyq44, yy2arr44 - const yyr44 bool = false - yyq44[1] = x.Selector != "" - var yynn44 int - if yyr44 || yy2arr44 { - r.EncodeArrayStart(2) - } else { - yynn44 = 1 - for _, b := range yyq44 { - if b { - yynn44++ - } - } - r.EncodeMapStart(yynn44) - yynn44 = 0 - } - if yyr44 || yy2arr44 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr44 || yy2arr44 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq44[1] { - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Selector)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq44[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym50 := z.EncBinary() - _ = yym50 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Selector)) - } - } - } - if yyr44 || yy2arr44 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ScaleStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym51 := z.DecBinary() - _ = yym51 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct52 := r.ContainerType() - if yyct52 == codecSelferValueTypeMap1234 { - yyl52 := r.ReadMapStart() - if yyl52 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl52, d) - } - } else if yyct52 == codecSelferValueTypeArray1234 { - yyl52 := r.ReadArrayStart() - if yyl52 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl52, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys53Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys53Slc - var yyhl53 bool = l >= 0 - for yyj53 := 0; ; yyj53++ { - if yyhl53 { - if yyj53 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys53Slc = r.DecodeBytes(yys53Slc, true, true) - yys53 := string(yys53Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys53 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "selector": - if r.TryDecodeAsNil() { - x.Selector = "" - } else { - x.Selector = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys53) - } // end switch yys53 - } // end for yyj53 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj56 int - var yyb56 bool - var yyhl56 bool = l >= 0 - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Selector = "" - } else { - x.Selector = string(r.DecodeString()) - } - for { - yyj56++ - if yyhl56 { - yyb56 = yyj56 > l - } else { - yyb56 = r.CheckBreak() - } - if yyb56 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj56-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CrossVersionObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym59 := z.EncBinary() - _ = yym59 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep60 := !z.EncBinary() - yy2arr60 := z.EncBasicHandle().StructToArray - var yyq60 [3]bool - _, _, _ = yysep60, yyq60, yy2arr60 - const yyr60 bool = false - yyq60[2] = x.APIVersion != "" - var yynn60 int - if yyr60 || yy2arr60 { - r.EncodeArrayStart(3) - } else { - yynn60 = 2 - for _, b := range yyq60 { - if b { - yynn60++ - } - } - r.EncodeMapStart(yynn60) - yynn60 = 0 - } - if yyr60 || yy2arr60 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym62 := z.EncBinary() - _ = yym62 - 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) - yym63 := z.EncBinary() - _ = yym63 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - if yyr60 || yy2arr60 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym65 := z.EncBinary() - _ = yym65 - 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) - yym66 := z.EncBinary() - _ = yym66 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr60 || yy2arr60 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq60[2] { - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq60[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym69 := z.EncBinary() - _ = yym69 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr60 || yy2arr60 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CrossVersionObjectReference) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym70 := z.DecBinary() - _ = yym70 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct71 := r.ContainerType() - if yyct71 == codecSelferValueTypeMap1234 { - yyl71 := r.ReadMapStart() - if yyl71 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl71, d) - } - } else if yyct71 == codecSelferValueTypeArray1234 { - yyl71 := r.ReadArrayStart() - if yyl71 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl71, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CrossVersionObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys72Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys72Slc - var yyhl72 bool = l >= 0 - for yyj72 := 0; ; yyj72++ { - if yyhl72 { - if yyj72 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys72Slc = r.DecodeBytes(yys72Slc, true, true) - yys72 := string(yys72Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys72 { - 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 "apiVersion": - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys72) - } // end switch yys72 - } // end for yyj72 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CrossVersionObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj76 int - var yyb76 bool - var yyhl76 bool = l >= 0 - yyj76++ - if yyhl76 { - yyb76 = yyj76 > l - } else { - yyb76 = r.CheckBreak() - } - if yyb76 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj76++ - if yyhl76 { - yyb76 = yyj76 > l - } else { - yyb76 = r.CheckBreak() - } - if yyb76 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj76++ - if yyhl76 { - yyb76 = yyj76 > l - } else { - yyb76 = r.CheckBreak() - } - if yyb76 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - for { - yyj76++ - if yyhl76 { - yyb76 = yyj76 > l - } else { - yyb76 = r.CheckBreak() - } - if yyb76 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj76-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HorizontalPodAutoscalerSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym80 := z.EncBinary() - _ = yym80 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep81 := !z.EncBinary() - yy2arr81 := z.EncBasicHandle().StructToArray - var yyq81 [4]bool - _, _, _ = yysep81, yyq81, yy2arr81 - const yyr81 bool = false - yyq81[1] = x.MinReplicas != nil - yyq81[3] = x.TargetCPUUtilizationPercentage != nil - var yynn81 int - if yyr81 || yy2arr81 { - r.EncodeArrayStart(4) - } else { - yynn81 = 2 - for _, b := range yyq81 { - if b { - yynn81++ - } - } - r.EncodeMapStart(yynn81) - yynn81 = 0 - } - if yyr81 || yy2arr81 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy83 := &x.ScaleTargetRef - yy83.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("scaleTargetRef")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy84 := &x.ScaleTargetRef - yy84.CodecEncodeSelf(e) - } - if yyr81 || yy2arr81 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq81[1] { - if x.MinReplicas == nil { - r.EncodeNil() - } else { - yy86 := *x.MinReplicas - yym87 := z.EncBinary() - _ = yym87 - if false { - } else { - r.EncodeInt(int64(yy86)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq81[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.MinReplicas == nil { - r.EncodeNil() - } else { - yy88 := *x.MinReplicas - yym89 := z.EncBinary() - _ = yym89 - if false { - } else { - r.EncodeInt(int64(yy88)) - } - } - } - } - if yyr81 || yy2arr81 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym91 := z.EncBinary() - _ = yym91 - if false { - } else { - r.EncodeInt(int64(x.MaxReplicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym92 := z.EncBinary() - _ = yym92 - if false { - } else { - r.EncodeInt(int64(x.MaxReplicas)) - } - } - if yyr81 || yy2arr81 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq81[3] { - if x.TargetCPUUtilizationPercentage == nil { - r.EncodeNil() - } else { - yy94 := *x.TargetCPUUtilizationPercentage - yym95 := z.EncBinary() - _ = yym95 - if false { - } else { - r.EncodeInt(int64(yy94)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq81[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("targetCPUUtilizationPercentage")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TargetCPUUtilizationPercentage == nil { - r.EncodeNil() - } else { - yy96 := *x.TargetCPUUtilizationPercentage - yym97 := z.EncBinary() - _ = yym97 - if false { - } else { - r.EncodeInt(int64(yy96)) - } - } - } - } - if yyr81 || yy2arr81 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HorizontalPodAutoscalerSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym98 := z.DecBinary() - _ = yym98 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct99 := r.ContainerType() - if yyct99 == codecSelferValueTypeMap1234 { - yyl99 := r.ReadMapStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl99, d) - } - } else if yyct99 == codecSelferValueTypeArray1234 { - yyl99 := r.ReadArrayStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl99, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys100Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys100Slc - var yyhl100 bool = l >= 0 - for yyj100 := 0; ; yyj100++ { - if yyhl100 { - if yyj100 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys100Slc = r.DecodeBytes(yys100Slc, true, true) - yys100 := string(yys100Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys100 { - case "scaleTargetRef": - if r.TryDecodeAsNil() { - x.ScaleTargetRef = CrossVersionObjectReference{} - } else { - yyv101 := &x.ScaleTargetRef - yyv101.CodecDecodeSelf(d) - } - case "minReplicas": - if r.TryDecodeAsNil() { - if x.MinReplicas != nil { - x.MinReplicas = nil - } - } else { - if x.MinReplicas == nil { - x.MinReplicas = new(int32) - } - yym103 := z.DecBinary() - _ = yym103 - if false { - } else { - *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) - } - } - case "maxReplicas": - if r.TryDecodeAsNil() { - x.MaxReplicas = 0 - } else { - x.MaxReplicas = int32(r.DecodeInt(32)) - } - case "targetCPUUtilizationPercentage": - if r.TryDecodeAsNil() { - if x.TargetCPUUtilizationPercentage != nil { - x.TargetCPUUtilizationPercentage = nil - } - } else { - if x.TargetCPUUtilizationPercentage == nil { - x.TargetCPUUtilizationPercentage = new(int32) - } - yym106 := z.DecBinary() - _ = yym106 - if false { - } else { - *((*int32)(x.TargetCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys100) - } // end switch yys100 - } // end for yyj100 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj107 int - var yyb107 bool - var yyhl107 bool = l >= 0 - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ScaleTargetRef = CrossVersionObjectReference{} - } else { - yyv108 := &x.ScaleTargetRef - yyv108.CodecDecodeSelf(d) - } - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.MinReplicas != nil { - x.MinReplicas = nil - } - } else { - if x.MinReplicas == nil { - x.MinReplicas = new(int32) - } - yym110 := z.DecBinary() - _ = yym110 - if false { - } else { - *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) - } - } - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MaxReplicas = 0 - } else { - x.MaxReplicas = int32(r.DecodeInt(32)) - } - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.TargetCPUUtilizationPercentage != nil { - x.TargetCPUUtilizationPercentage = nil - } - } else { - if x.TargetCPUUtilizationPercentage == nil { - x.TargetCPUUtilizationPercentage = new(int32) - } - yym113 := z.DecBinary() - _ = yym113 - if false { - } else { - *((*int32)(x.TargetCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) - } - } - for { - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj107-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym114 := z.EncBinary() - _ = yym114 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep115 := !z.EncBinary() - yy2arr115 := z.EncBasicHandle().StructToArray - var yyq115 [5]bool - _, _, _ = yysep115, yyq115, yy2arr115 - const yyr115 bool = false - yyq115[0] = x.ObservedGeneration != nil - yyq115[1] = x.LastScaleTime != nil - yyq115[4] = x.CurrentCPUUtilizationPercentage != nil - var yynn115 int - if yyr115 || yy2arr115 { - r.EncodeArrayStart(5) - } else { - yynn115 = 2 - for _, b := range yyq115 { - if b { - yynn115++ - } - } - r.EncodeMapStart(yynn115) - yynn115 = 0 - } - if yyr115 || yy2arr115 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq115[0] { - if x.ObservedGeneration == nil { - r.EncodeNil() - } else { - yy117 := *x.ObservedGeneration - yym118 := z.EncBinary() - _ = yym118 - if false { - } else { - r.EncodeInt(int64(yy117)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq115[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ObservedGeneration == nil { - r.EncodeNil() - } else { - yy119 := *x.ObservedGeneration - yym120 := z.EncBinary() - _ = yym120 - if false { - } else { - r.EncodeInt(int64(yy119)) - } - } - } - } - if yyr115 || yy2arr115 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq115[1] { - if x.LastScaleTime == nil { - r.EncodeNil() - } else { - yym122 := z.EncBinary() - _ = yym122 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { - } else if yym122 { - z.EncBinaryMarshal(x.LastScaleTime) - } else if !yym122 && z.IsJSONHandle() { - z.EncJSONMarshal(x.LastScaleTime) - } else { - z.EncFallback(x.LastScaleTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq115[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastScaleTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LastScaleTime == nil { - r.EncodeNil() - } else { - yym123 := z.EncBinary() - _ = yym123 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { - } else if yym123 { - z.EncBinaryMarshal(x.LastScaleTime) - } else if !yym123 && z.IsJSONHandle() { - z.EncJSONMarshal(x.LastScaleTime) - } else { - z.EncFallback(x.LastScaleTime) - } - } - } - } - if yyr115 || yy2arr115 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym125 := z.EncBinary() - _ = yym125 - if false { - } else { - r.EncodeInt(int64(x.CurrentReplicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym126 := z.EncBinary() - _ = yym126 - if false { - } else { - r.EncodeInt(int64(x.CurrentReplicas)) - } - } - if yyr115 || yy2arr115 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym128 := z.EncBinary() - _ = yym128 - if false { - } else { - r.EncodeInt(int64(x.DesiredReplicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("desiredReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym129 := z.EncBinary() - _ = yym129 - if false { - } else { - r.EncodeInt(int64(x.DesiredReplicas)) - } - } - if yyr115 || yy2arr115 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq115[4] { - if x.CurrentCPUUtilizationPercentage == nil { - r.EncodeNil() - } else { - yy131 := *x.CurrentCPUUtilizationPercentage - yym132 := z.EncBinary() - _ = yym132 - if false { - } else { - r.EncodeInt(int64(yy131)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq115[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentCPUUtilizationPercentage")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CurrentCPUUtilizationPercentage == nil { - r.EncodeNil() - } else { - yy133 := *x.CurrentCPUUtilizationPercentage - yym134 := z.EncBinary() - _ = yym134 - if false { - } else { - r.EncodeInt(int64(yy133)) - } - } - } - } - if yyr115 || yy2arr115 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HorizontalPodAutoscalerStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym135 := z.DecBinary() - _ = yym135 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct136 := r.ContainerType() - if yyct136 == codecSelferValueTypeMap1234 { - yyl136 := r.ReadMapStart() - if yyl136 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl136, d) - } - } else if yyct136 == codecSelferValueTypeArray1234 { - yyl136 := r.ReadArrayStart() - if yyl136 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl136, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys137Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys137Slc - var yyhl137 bool = l >= 0 - for yyj137 := 0; ; yyj137++ { - if yyhl137 { - if yyj137 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys137Slc = r.DecodeBytes(yys137Slc, true, true) - yys137 := string(yys137Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys137 { - case "observedGeneration": - if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil - } - } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) - } - yym139 := z.DecBinary() - _ = yym139 - if false { - } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) - } - } - case "lastScaleTime": - if r.TryDecodeAsNil() { - if x.LastScaleTime != nil { - x.LastScaleTime = nil - } - } else { - if x.LastScaleTime == nil { - x.LastScaleTime = new(pkg1_unversioned.Time) - } - yym141 := z.DecBinary() - _ = yym141 - if false { - } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { - } else if yym141 { - z.DecBinaryUnmarshal(x.LastScaleTime) - } else if !yym141 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.LastScaleTime) - } else { - z.DecFallback(x.LastScaleTime, false) - } - } - case "currentReplicas": - if r.TryDecodeAsNil() { - x.CurrentReplicas = 0 - } else { - x.CurrentReplicas = int32(r.DecodeInt(32)) - } - case "desiredReplicas": - if r.TryDecodeAsNil() { - x.DesiredReplicas = 0 - } else { - x.DesiredReplicas = int32(r.DecodeInt(32)) - } - case "currentCPUUtilizationPercentage": - if r.TryDecodeAsNil() { - if x.CurrentCPUUtilizationPercentage != nil { - x.CurrentCPUUtilizationPercentage = nil - } - } else { - if x.CurrentCPUUtilizationPercentage == nil { - x.CurrentCPUUtilizationPercentage = new(int32) - } - yym145 := z.DecBinary() - _ = yym145 - if false { - } else { - *((*int32)(x.CurrentCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys137) - } // end switch yys137 - } // end for yyj137 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj146 int - var yyb146 bool - var yyhl146 bool = l >= 0 - yyj146++ - if yyhl146 { - yyb146 = yyj146 > l - } else { - yyb146 = r.CheckBreak() - } - if yyb146 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil - } - } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) - } - yym148 := z.DecBinary() - _ = yym148 - if false { - } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) - } - } - yyj146++ - if yyhl146 { - yyb146 = yyj146 > l - } else { - yyb146 = r.CheckBreak() - } - if yyb146 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.LastScaleTime != nil { - x.LastScaleTime = nil - } - } else { - if x.LastScaleTime == nil { - x.LastScaleTime = new(pkg1_unversioned.Time) - } - yym150 := z.DecBinary() - _ = yym150 - if false { - } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { - } else if yym150 { - z.DecBinaryUnmarshal(x.LastScaleTime) - } else if !yym150 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.LastScaleTime) - } else { - z.DecFallback(x.LastScaleTime, false) - } - } - yyj146++ - if yyhl146 { - yyb146 = yyj146 > l - } else { - yyb146 = r.CheckBreak() - } - if yyb146 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CurrentReplicas = 0 - } else { - x.CurrentReplicas = int32(r.DecodeInt(32)) - } - yyj146++ - if yyhl146 { - yyb146 = yyj146 > l - } else { - yyb146 = r.CheckBreak() - } - if yyb146 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DesiredReplicas = 0 - } else { - x.DesiredReplicas = int32(r.DecodeInt(32)) - } - yyj146++ - if yyhl146 { - yyb146 = yyj146 > l - } else { - yyb146 = r.CheckBreak() - } - if yyb146 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.CurrentCPUUtilizationPercentage != nil { - x.CurrentCPUUtilizationPercentage = nil - } - } else { - if x.CurrentCPUUtilizationPercentage == nil { - x.CurrentCPUUtilizationPercentage = new(int32) - } - yym154 := z.DecBinary() - _ = yym154 - if false { - } else { - *((*int32)(x.CurrentCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) - } - } - for { - yyj146++ - if yyhl146 { - yyb146 = yyj146 > l - } else { - yyb146 = r.CheckBreak() - } - if yyb146 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj146-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym155 := z.EncBinary() - _ = yym155 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep156 := !z.EncBinary() - yy2arr156 := z.EncBasicHandle().StructToArray - var yyq156 [5]bool - _, _, _ = yysep156, yyq156, yy2arr156 - const yyr156 bool = false - yyq156[0] = x.Kind != "" - yyq156[1] = x.APIVersion != "" - yyq156[2] = true - yyq156[3] = true - yyq156[4] = true - var yynn156 int - if yyr156 || yy2arr156 { - r.EncodeArrayStart(5) - } else { - yynn156 = 0 - for _, b := range yyq156 { - if b { - yynn156++ - } - } - r.EncodeMapStart(yynn156) - yynn156 = 0 - } - if yyr156 || yy2arr156 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq156[0] { - yym158 := z.EncBinary() - _ = yym158 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq156[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym159 := z.EncBinary() - _ = yym159 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr156 || yy2arr156 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq156[1] { - yym161 := z.EncBinary() - _ = yym161 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq156[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym162 := z.EncBinary() - _ = yym162 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr156 || yy2arr156 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq156[2] { - yy164 := &x.ObjectMeta - yy164.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq156[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy165 := &x.ObjectMeta - yy165.CodecEncodeSelf(e) - } - } - if yyr156 || yy2arr156 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq156[3] { - yy167 := &x.Spec - yy167.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq156[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy168 := &x.Spec - yy168.CodecEncodeSelf(e) - } - } - if yyr156 || yy2arr156 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq156[4] { - yy170 := &x.Status - yy170.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq156[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy171 := &x.Status - yy171.CodecEncodeSelf(e) - } - } - if yyr156 || yy2arr156 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HorizontalPodAutoscaler) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym172 := z.DecBinary() - _ = yym172 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct173 := r.ContainerType() - if yyct173 == codecSelferValueTypeMap1234 { - yyl173 := r.ReadMapStart() - if yyl173 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl173, d) - } - } else if yyct173 == codecSelferValueTypeArray1234 { - yyl173 := r.ReadArrayStart() - if yyl173 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl173, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HorizontalPodAutoscaler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys174Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys174Slc - var yyhl174 bool = l >= 0 - for yyj174 := 0; ; yyj174++ { - if yyhl174 { - if yyj174 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys174Slc = r.DecodeBytes(yys174Slc, true, true) - yys174 := string(yys174Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys174 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv177 := &x.ObjectMeta - yyv177.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = HorizontalPodAutoscalerSpec{} - } else { - yyv178 := &x.Spec - yyv178.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = HorizontalPodAutoscalerStatus{} - } else { - yyv179 := &x.Status - yyv179.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys174) - } // end switch yys174 - } // end for yyj174 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj180 int - var yyb180 bool - var yyhl180 bool = l >= 0 - yyj180++ - if yyhl180 { - yyb180 = yyj180 > l - } else { - yyb180 = r.CheckBreak() - } - if yyb180 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj180++ - if yyhl180 { - yyb180 = yyj180 > l - } else { - yyb180 = r.CheckBreak() - } - if yyb180 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj180++ - if yyhl180 { - yyb180 = yyj180 > l - } else { - yyb180 = r.CheckBreak() - } - if yyb180 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv183 := &x.ObjectMeta - yyv183.CodecDecodeSelf(d) - } - yyj180++ - if yyhl180 { - yyb180 = yyj180 > l - } else { - yyb180 = r.CheckBreak() - } - if yyb180 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = HorizontalPodAutoscalerSpec{} - } else { - yyv184 := &x.Spec - yyv184.CodecDecodeSelf(d) - } - yyj180++ - if yyhl180 { - yyb180 = yyj180 > l - } else { - yyb180 = r.CheckBreak() - } - if yyb180 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = HorizontalPodAutoscalerStatus{} - } else { - yyv185 := &x.Status - yyv185.CodecDecodeSelf(d) - } - for { - yyj180++ - if yyhl180 { - yyb180 = yyj180 > l - } else { - yyb180 = r.CheckBreak() - } - if yyb180 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj180-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym186 := z.EncBinary() - _ = yym186 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep187 := !z.EncBinary() - yy2arr187 := z.EncBasicHandle().StructToArray - var yyq187 [4]bool - _, _, _ = yysep187, yyq187, yy2arr187 - const yyr187 bool = false - yyq187[0] = x.Kind != "" - yyq187[1] = x.APIVersion != "" - yyq187[2] = true - var yynn187 int - if yyr187 || yy2arr187 { - r.EncodeArrayStart(4) - } else { - yynn187 = 1 - for _, b := range yyq187 { - if b { - yynn187++ - } - } - r.EncodeMapStart(yynn187) - yynn187 = 0 - } - if yyr187 || yy2arr187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq187[0] { - yym189 := z.EncBinary() - _ = yym189 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq187[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym190 := z.EncBinary() - _ = yym190 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr187 || yy2arr187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq187[1] { - yym192 := z.EncBinary() - _ = yym192 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq187[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym193 := z.EncBinary() - _ = yym193 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr187 || yy2arr187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq187[2] { - yy195 := &x.ListMeta - yym196 := z.EncBinary() - _ = yym196 - if false { - } else if z.HasExtensions() && z.EncExt(yy195) { - } else { - z.EncFallback(yy195) - } - } else { - r.EncodeNil() - } - } else { - if yyq187[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy197 := &x.ListMeta - yym198 := z.EncBinary() - _ = yym198 - if false { - } else if z.HasExtensions() && z.EncExt(yy197) { - } else { - z.EncFallback(yy197) - } - } - } - if yyr187 || yy2arr187 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym200 := z.EncBinary() - _ = yym200 - if false { - } else { - h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(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 { - yym201 := z.EncBinary() - _ = yym201 - if false { - } else { - h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(x.Items), e) - } - } - } - if yyr187 || yy2arr187 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HorizontalPodAutoscalerList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym202 := z.DecBinary() - _ = yym202 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct203 := r.ContainerType() - if yyct203 == codecSelferValueTypeMap1234 { - yyl203 := r.ReadMapStart() - if yyl203 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl203, d) - } - } else if yyct203 == codecSelferValueTypeArray1234 { - yyl203 := r.ReadArrayStart() - if yyl203 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl203, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys204Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys204Slc - var yyhl204 bool = l >= 0 - for yyj204 := 0; ; yyj204++ { - if yyhl204 { - if yyj204 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys204Slc = r.DecodeBytes(yys204Slc, true, true) - yys204 := string(yys204Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys204 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv207 := &x.ListMeta - yym208 := z.DecBinary() - _ = yym208 - if false { - } else if z.HasExtensions() && z.DecExt(yyv207) { - } else { - z.DecFallback(yyv207, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv209 := &x.Items - yym210 := z.DecBinary() - _ = yym210 - if false { - } else { - h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv209), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys204) - } // end switch yys204 - } // end for yyj204 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj211 int - var yyb211 bool - var yyhl211 bool = l >= 0 - yyj211++ - if yyhl211 { - yyb211 = yyj211 > l - } else { - yyb211 = r.CheckBreak() - } - if yyb211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj211++ - if yyhl211 { - yyb211 = yyj211 > l - } else { - yyb211 = r.CheckBreak() - } - if yyb211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj211++ - if yyhl211 { - yyb211 = yyj211 > l - } else { - yyb211 = r.CheckBreak() - } - if yyb211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv214 := &x.ListMeta - yym215 := z.DecBinary() - _ = yym215 - if false { - } else if z.HasExtensions() && z.DecExt(yyv214) { - } else { - z.DecFallback(yyv214, false) - } - } - yyj211++ - if yyhl211 { - yyb211 = yyj211 > l - } else { - yyb211 = r.CheckBreak() - } - if yyb211 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv216 := &x.Items - yym217 := z.DecBinary() - _ = yym217 - if false { - } else { - h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv216), d) - } - } - for { - yyj211++ - if yyhl211 { - yyb211 = yyj211 > l - } else { - yyb211 = r.CheckBreak() - } - if yyb211 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj211-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceHorizontalPodAutoscaler(v []HorizontalPodAutoscaler, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv218 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy219 := &yyv218 - yy219.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceHorizontalPodAutoscaler(v *[]HorizontalPodAutoscaler, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv220 := *v - yyh220, yyl220 := z.DecSliceHelperStart() - var yyc220 bool - if yyl220 == 0 { - if yyv220 == nil { - yyv220 = []HorizontalPodAutoscaler{} - yyc220 = true - } else if len(yyv220) != 0 { - yyv220 = yyv220[:0] - yyc220 = true - } - } else if yyl220 > 0 { - var yyrr220, yyrl220 int - var yyrt220 bool - if yyl220 > cap(yyv220) { - - yyrg220 := len(yyv220) > 0 - yyv2220 := yyv220 - yyrl220, yyrt220 = z.DecInferLen(yyl220, z.DecBasicHandle().MaxInitLen, 360) - if yyrt220 { - if yyrl220 <= cap(yyv220) { - yyv220 = yyv220[:yyrl220] - } else { - yyv220 = make([]HorizontalPodAutoscaler, yyrl220) - } - } else { - yyv220 = make([]HorizontalPodAutoscaler, yyrl220) - } - yyc220 = true - yyrr220 = len(yyv220) - if yyrg220 { - copy(yyv220, yyv2220) - } - } else if yyl220 != len(yyv220) { - yyv220 = yyv220[:yyl220] - yyc220 = true - } - yyj220 := 0 - for ; yyj220 < yyrr220; yyj220++ { - yyh220.ElemContainerState(yyj220) - if r.TryDecodeAsNil() { - yyv220[yyj220] = HorizontalPodAutoscaler{} - } else { - yyv221 := &yyv220[yyj220] - yyv221.CodecDecodeSelf(d) - } - - } - if yyrt220 { - for ; yyj220 < yyl220; yyj220++ { - yyv220 = append(yyv220, HorizontalPodAutoscaler{}) - yyh220.ElemContainerState(yyj220) - if r.TryDecodeAsNil() { - yyv220[yyj220] = HorizontalPodAutoscaler{} - } else { - yyv222 := &yyv220[yyj220] - yyv222.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj220 := 0 - for ; !r.CheckBreak(); yyj220++ { - - if yyj220 >= len(yyv220) { - yyv220 = append(yyv220, HorizontalPodAutoscaler{}) // var yyz220 HorizontalPodAutoscaler - yyc220 = true - } - yyh220.ElemContainerState(yyj220) - if yyj220 < len(yyv220) { - if r.TryDecodeAsNil() { - yyv220[yyj220] = HorizontalPodAutoscaler{} - } else { - yyv223 := &yyv220[yyj220] - yyv223.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj220 < len(yyv220) { - yyv220 = yyv220[:yyj220] - yyc220 = true - } else if yyj220 == 0 && yyv220 == nil { - yyv220 = []HorizontalPodAutoscaler{} - yyc220 = true - } - } - yyh220.End() - if yyc220 { - *v = yyv220 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.go index 438d82b425..19fdc8a4f5 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/types.go @@ -17,119 +17,342 @@ limitations under the License. package autoscaling import ( + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" ) // Scale represents a scaling request for a resource. type Scale struct { - unversioned.TypeMeta `json:",inline"` - // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + metav1.TypeMeta + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional - Spec ScaleSpec `json:"spec,omitempty"` + Spec ScaleSpec - // current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only. + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. // +optional - Status ScaleStatus `json:"status,omitempty"` + Status ScaleStatus } // ScaleSpec describes the attributes of a scale subresource. type ScaleSpec struct { // desired number of instances for the scaled object. // +optional - Replicas int32 `json:"replicas,omitempty"` + Replicas int32 } // ScaleStatus represents the current status of a scale subresource. type ScaleStatus struct { // actual number of observed instances of the scaled object. - Replicas int32 `json:"replicas"` + Replicas int32 // label query over pods that should match the replicas count. This is same // as the label selector but in the string format to avoid introspection // by clients. The string will be in the same format as the query-param syntax. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector string `json:"selector,omitempty"` + Selector string } // CrossVersionObjectReference contains enough information to let you identify the referred resource. type CrossVersionObjectReference struct { - // Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" - Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` + // Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds" + Kind string // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names - Name string `json:"name" protobuf:"bytes,2,opt,name=name"` + Name string // API version of the referent // +optional - APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,3,opt,name=apiVersion"` + APIVersion string } -// specification of a horizontal pod autoscaler. +// HorizontalPodAutoscalerSpec describes the desired functionality of the HorizontalPodAutoscaler. type HorizontalPodAutoscalerSpec struct { - // reference to scaled resource; horizontal pod autoscaler will learn the current resource consumption - // and will set the desired number of pods by using its Scale subresource. - ScaleTargetRef CrossVersionObjectReference `json:"scaleTargetRef"` - // lower limit for the number of pods that can be set by the autoscaler, default 1. + // ScaleTargetRef points to the target resource to scale, and is used to the pods for which metrics + // should be collected, as well as to actually change the replica count. + ScaleTargetRef CrossVersionObjectReference + // MinReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. + // It defaults to 1 pod. // +optional - MinReplicas *int32 `json:"minReplicas,omitempty"` - // upper limit for the number of pods that can be set by the autoscaler. It cannot be smaller than MinReplicas. - MaxReplicas int32 `json:"maxReplicas"` - // target average CPU utilization (represented as a percentage of requested CPU) over all the pods; - // if not specified the default autoscaling policy will be used. + MinReplicas *int32 + // MaxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. + // It cannot be less that minReplicas. + MaxReplicas int32 + // Metrics contains the specifications for which to use to calculate the + // desired replica count (the maximum replica count across all metrics will + // be used). The desired replica count is calculated multiplying the + // ratio between the target value and the current value by the current + // number of pods. Ergo, metrics used must decrease as the pod count is + // increased, and vice-versa. See the individual metric source types for + // more information about how each type of metric must respond. // +optional - TargetCPUUtilizationPercentage *int32 `json:"targetCPUUtilizationPercentage,omitempty"` + Metrics []MetricSpec } -// current status of a horizontal pod autoscaler +// MetricSourceType indicates the type of metric. +type MetricSourceType string + +var ( + // ObjectMetricSourceType is a metric describing a kubernetes object + // (for example, hits-per-second on an Ingress object). + ObjectMetricSourceType MetricSourceType = "Object" + // PodsMetricSourceType is a metric describing each pod in the current scale + // target (for example, transactions-processed-per-second). The values + // will be averaged together before being compared to the target value. + PodsMetricSourceType MetricSourceType = "Pods" + // ResourceMetricSourceType is a resource metric known to Kubernetes, as + // specified in requests and limits, describing each pod in the current + // scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics (the "pods" source). + ResourceMetricSourceType MetricSourceType = "Resource" +) + +// MetricSpec specifies how to scale based on a single metric +// (only `type` and one other matching field should be set at once). +type MetricSpec struct { + // Type is the type of metric source. It should match one of the fields below. + Type MetricSourceType + + // Object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + Object *ObjectMetricSource + // Pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + Pods *PodsMetricSource + // Resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + Resource *ResourceMetricSource +} + +// ObjectMetricSource indicates how to scale on a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +type ObjectMetricSource struct { + // Target is the described Kubernetes object. + Target CrossVersionObjectReference + + // MetricName is the name of the metric in question. + MetricName string + // TargetValue is the target value of the metric (as a quantity). + TargetValue resource.Quantity +} + +// PodsMetricSource indicates how to scale on a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +// The values will be averaged together before being compared to the target +// value. +type PodsMetricSource struct { + // MetricName is the name of the metric in question + MetricName string + // TargetAverageValue is the target value of the average of the + // metric across all relevant pods (as a quantity) + TargetAverageValue resource.Quantity +} + +// ResourceMetricSource indicates how to scale on a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). The values will be averaged +// together before being compared to the target. Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. Only one "target" type +// should be set. +type ResourceMetricSource struct { + // Name is the name of the resource in question. + Name api.ResourceName + // TargetAverageUtilization is the target value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. + // +optional + TargetAverageUtilization *int32 + // TargetAverageValue is the target value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // +optional + TargetAverageValue *resource.Quantity +} + +// HorizontalPodAutoscalerStatus describes the current status of a horizontal pod autoscaler. type HorizontalPodAutoscalerStatus struct { - // most recent generation observed by this autoscaler. + // ObservedGeneration is the most recent generation observed by this autoscaler. // +optional - ObservedGeneration *int64 `json:"observedGeneration,omitempty"` + ObservedGeneration *int64 - // last time the HorizontalPodAutoscaler scaled the number of pods; + // LastScaleTime is the last time the HorizontalPodAutoscaler scaled the number of pods, // used by the autoscaler to control how often the number of pods is changed. // +optional - LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty"` + LastScaleTime *metav1.Time + + // CurrentReplicas is current number of replicas of pods managed by this autoscaler, + // as last seen by the autoscaler. + CurrentReplicas int32 + + // DesiredReplicas is the desired number of replicas of pods managed by this autoscaler, + // as last calculated by the autoscaler. + DesiredReplicas int32 - // current number of replicas of pods managed by this autoscaler. - CurrentReplicas int32 `json:"currentReplicas"` + // CurrentMetrics is the last read state of the metrics used by this autoscaler. + CurrentMetrics []MetricStatus + + // Conditions is the set of conditions required for this autoscaler to scale its target, + // and indicates whether or not those conditions are met. + Conditions []HorizontalPodAutoscalerCondition +} - // desired number of replicas of pods managed by this autoscaler. - DesiredReplicas int32 `json:"desiredReplicas"` +// ConditionStatus indicates the status of a condition (true, false, or unknown). +type ConditionStatus string + +// These are valid condition statuses. "ConditionTrue" means a resource is in the condition; +// "ConditionFalse" means a resource is not in the condition; "ConditionUnknown" means kubernetes +// can't decide if a resource is in the condition or not. In the future, we could add other +// intermediate conditions, e.g. ConditionDegraded. +const ( + ConditionTrue ConditionStatus = "True" + ConditionFalse ConditionStatus = "False" + ConditionUnknown ConditionStatus = "Unknown" +) + +// HorizontalPodAutoscalerConditionType are the valid conditions of +// a HorizontalPodAutoscaler. +type HorizontalPodAutoscalerConditionType string + +var ( + // ScalingActive indicates that the HPA controller is able to scale if necessary: + // it's correctly configured, can fetch the desired metrics, and isn't disabled. + ScalingActive HorizontalPodAutoscalerConditionType = "ScalingActive" + // AbleToScale indicates a lack of transient issues which prevent scaling from occuring, + // such as being in a backoff window, or being unable to access/update the target scale. + AbleToScale HorizontalPodAutoscalerConditionType = "AbleToScale" + // ScalingLimited indicates that the calculated scale based on metrics would be above or + // below the range for the HPA, and has thus been capped. + ScalingLimited HorizontalPodAutoscalerConditionType = "ScalingLimited" +) + +// HorizontalPodAutoscalerCondition describes the state of +// a HorizontalPodAutoscaler at a certain point. +type HorizontalPodAutoscalerCondition struct { + // Type describes the current condition + Type HorizontalPodAutoscalerConditionType + // Status is the status of the condition (True, False, Unknown) + Status ConditionStatus + // LastTransitionTime is the last time the condition transitioned from + // one status to another + // +optional + LastTransitionTime metav1.Time + // Reason is the reason for the condition's last transition. + // +optional + Reason string + // Message is a human-readable explanation containing details about + // the transition + // +optional + Message string +} + +// MetricStatus describes the last-read state of a single metric. +type MetricStatus struct { + // Type is the type of metric source. It will match one of the fields below. + Type MetricSourceType + + // Object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + Object *ObjectMetricStatus + // Pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + Pods *PodsMetricStatus + // Resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + Resource *ResourceMetricStatus +} + +// ObjectMetricStatus indicates the current value of a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +type ObjectMetricStatus struct { + // Target is the described Kubernetes object. + Target CrossVersionObjectReference + + // MetricName is the name of the metric in question. + MetricName string + // CurrentValue is the current value of the metric (as a quantity). + CurrentValue resource.Quantity +} + +// PodsMetricStatus indicates the current value of a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +type PodsMetricStatus struct { + // MetricName is the name of the metric in question + MetricName string + // CurrentAverageValue is the current value of the average of the + // metric across all relevant pods (as a quantity) + CurrentAverageValue resource.Quantity +} - // current average CPU utilization over all pods, represented as a percentage of requested CPU, - // e.g. 70 means that an average pod is using now 70% of its requested CPU. +// ResourceMetricStatus indicates the current value of a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. +type ResourceMetricStatus struct { + // Name is the name of the resource in question. + Name api.ResourceName + // CurrentAverageUtilization is the current value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. It will only be + // present if `targetAverageValue` was set in the corresponding metric + // specification. // +optional - CurrentCPUUtilizationPercentage *int32 `json:"currentCPUUtilizationPercentage,omitempty"` + CurrentAverageUtilization *int32 + // CurrentAverageValue is the current value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // It will always be set, regardless of the corresponding metric specification. + CurrentAverageValue resource.Quantity } // +genclient=true -// configuration of a horizontal pod autoscaler. +// HorizontalPodAutoscaler is the configuration for a horizontal pod +// autoscaler, which automatically manages the replica count of any resource +// implementing the scale subresource based on the metrics specified. type HorizontalPodAutoscaler struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta + // Metadata is the standard object metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // Spec is the specification for the behaviour of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional - Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty"` + Spec HorizontalPodAutoscalerSpec - // current information about the autoscaler. + // Status is the current information about the autoscaler. // +optional - Status HorizontalPodAutoscalerStatus `json:"status,omitempty"` + Status HorizontalPodAutoscalerStatus } -// list of horizontal pod autoscaler objects. +// HorizontalPodAutoscaler is a list of horizontal pod autoscaler objects. type HorizontalPodAutoscalerList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta + // Metadata is the standard list metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - // list of horizontal pod autoscaler objects. - Items []HorizontalPodAutoscaler `json:"items"` + // Items is the list of horizontal pod autoscaler objects. + Items []HorizontalPodAutoscaler } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/BUILD b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/BUILD new file mode 100644 index 0000000000..fb17b5df40 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/BUILD @@ -0,0 +1,39 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/autoscaling:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/conversion.go new file mode 100644 index 0000000000..3e6a320a2c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/conversion.go @@ -0,0 +1,275 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + "encoding/json" + + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api" + "k8s.io/client-go/pkg/apis/autoscaling" +) + +func addConversionFuncs(scheme *runtime.Scheme) error { + // Add non-generated conversion functions + err := scheme.AddConversionFuncs( + Convert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler, + Convert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler, + Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec, + Convert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec, + Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1_HorizontalPodAutoscalerStatus, + Convert_v1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus, + ) + if err != nil { + return err + } + + return nil +} + +func Convert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { + if err := autoConvert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler(in, out, s); err != nil { + return err + } + + otherMetrics := make([]MetricSpec, 0, len(in.Spec.Metrics)) + for _, metric := range in.Spec.Metrics { + if metric.Type == autoscaling.ResourceMetricSourceType && metric.Resource != nil && metric.Resource.Name == api.ResourceCPU && metric.Resource.TargetAverageUtilization != nil { + continue + } + + convMetric := MetricSpec{} + if err := Convert_autoscaling_MetricSpec_To_v1_MetricSpec(&metric, &convMetric, s); err != nil { + return err + } + otherMetrics = append(otherMetrics, convMetric) + } + + // NB: we need to save the status even if it maps to a CPU utilization status in order to save the raw value as well + currentMetrics := make([]MetricStatus, len(in.Status.CurrentMetrics)) + for i, currentMetric := range in.Status.CurrentMetrics { + if err := Convert_autoscaling_MetricStatus_To_v1_MetricStatus(¤tMetric, ¤tMetrics[i], s); err != nil { + return err + } + } + + // store HPA conditions in an annotation + currentConditions := make([]HorizontalPodAutoscalerCondition, len(in.Status.Conditions)) + for i, currentCondition := range in.Status.Conditions { + if err := Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v1_HorizontalPodAutoscalerCondition(¤tCondition, ¤tConditions[i], s); err != nil { + return err + } + } + + if len(otherMetrics) > 0 || len(in.Status.CurrentMetrics) > 0 || len(currentConditions) > 0 { + old := out.Annotations + out.Annotations = make(map[string]string, len(old)+3) + if old != nil { + for k, v := range old { + out.Annotations[k] = v + } + } + } + + if len(otherMetrics) > 0 { + otherMetricsEnc, err := json.Marshal(otherMetrics) + if err != nil { + return err + } + out.Annotations[autoscaling.MetricSpecsAnnotation] = string(otherMetricsEnc) + } + + if len(in.Status.CurrentMetrics) > 0 { + currentMetricsEnc, err := json.Marshal(currentMetrics) + if err != nil { + return err + } + out.Annotations[autoscaling.MetricStatusesAnnotation] = string(currentMetricsEnc) + } + + if len(in.Status.Conditions) > 0 { + currentConditionsEnc, err := json.Marshal(currentConditions) + if err != nil { + return err + } + out.Annotations[autoscaling.HorizontalPodAutoscalerConditionsAnnotation] = string(currentConditionsEnc) + } + + return nil +} + +func Convert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { + if err := autoConvert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in, out, s); err != nil { + return err + } + + if otherMetricsEnc, hasOtherMetrics := out.Annotations[autoscaling.MetricSpecsAnnotation]; hasOtherMetrics { + var otherMetrics []MetricSpec + if err := json.Unmarshal([]byte(otherMetricsEnc), &otherMetrics); err != nil { + return err + } + + // the normal Spec conversion could have populated out.Spec.Metrics with a single element, so deal with that + outMetrics := make([]autoscaling.MetricSpec, len(otherMetrics)+len(out.Spec.Metrics)) + for i, metric := range otherMetrics { + if err := Convert_v1_MetricSpec_To_autoscaling_MetricSpec(&metric, &outMetrics[i], s); err != nil { + return err + } + } + if out.Spec.Metrics != nil { + outMetrics[len(otherMetrics)] = out.Spec.Metrics[0] + } + out.Spec.Metrics = outMetrics + delete(out.Annotations, autoscaling.MetricSpecsAnnotation) + } + + if currentMetricsEnc, hasCurrentMetrics := out.Annotations[autoscaling.MetricStatusesAnnotation]; hasCurrentMetrics { + // ignore any existing status values -- the ones here have more information + var currentMetrics []MetricStatus + if err := json.Unmarshal([]byte(currentMetricsEnc), ¤tMetrics); err != nil { + return err + } + + out.Status.CurrentMetrics = make([]autoscaling.MetricStatus, len(currentMetrics)) + for i, currentMetric := range currentMetrics { + if err := Convert_v1_MetricStatus_To_autoscaling_MetricStatus(¤tMetric, &out.Status.CurrentMetrics[i], s); err != nil { + return err + } + } + delete(out.Annotations, autoscaling.MetricStatusesAnnotation) + } + + // autoscaling/v1 formerly had an implicit default applied in the controller. In v2alpha1, we apply it explicitly. + // We apply it here, explicitly, since we have access to the full set of metrics from the annotation. + if len(out.Spec.Metrics) == 0 { + // no other metrics, no explicit CPU value set + out.Spec.Metrics = []autoscaling.MetricSpec{ + { + Type: autoscaling.ResourceMetricSourceType, + Resource: &autoscaling.ResourceMetricSource{ + Name: api.ResourceCPU, + }, + }, + } + out.Spec.Metrics[0].Resource.TargetAverageUtilization = new(int32) + *out.Spec.Metrics[0].Resource.TargetAverageUtilization = autoscaling.DefaultCPUUtilization + } + + if currentConditionsEnc, hasCurrentConditions := out.Annotations[autoscaling.HorizontalPodAutoscalerConditionsAnnotation]; hasCurrentConditions { + var currentConditions []HorizontalPodAutoscalerCondition + if err := json.Unmarshal([]byte(currentConditionsEnc), ¤tConditions); err != nil { + return err + } + + out.Status.Conditions = make([]autoscaling.HorizontalPodAutoscalerCondition, len(currentConditions)) + for i, currentCondition := range currentConditions { + if err := Convert_v1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(¤tCondition, &out.Status.Conditions[i], s); err != nil { + return err + } + } + delete(out.Annotations, autoscaling.HorizontalPodAutoscalerConditionsAnnotation) + } + + return nil +} + +func Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { + if err := Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference(&in.ScaleTargetRef, &out.ScaleTargetRef, s); err != nil { + return err + } + + out.MinReplicas = in.MinReplicas + out.MaxReplicas = in.MaxReplicas + + for _, metric := range in.Metrics { + if metric.Type == autoscaling.ResourceMetricSourceType && metric.Resource != nil && metric.Resource.Name == api.ResourceCPU { + if metric.Resource.TargetAverageUtilization != nil { + out.TargetCPUUtilizationPercentage = new(int32) + *out.TargetCPUUtilizationPercentage = *metric.Resource.TargetAverageUtilization + } + break + } + } + + return nil +} + +func Convert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in *HorizontalPodAutoscalerSpec, out *autoscaling.HorizontalPodAutoscalerSpec, s conversion.Scope) error { + if err := Convert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(&in.ScaleTargetRef, &out.ScaleTargetRef, s); err != nil { + return err + } + + out.MinReplicas = in.MinReplicas + out.MaxReplicas = in.MaxReplicas + + if in.TargetCPUUtilizationPercentage != nil { + out.Metrics = []autoscaling.MetricSpec{ + { + Type: autoscaling.ResourceMetricSourceType, + Resource: &autoscaling.ResourceMetricSource{ + Name: api.ResourceCPU, + }, + }, + } + out.Metrics[0].Resource.TargetAverageUtilization = new(int32) + *out.Metrics[0].Resource.TargetAverageUtilization = *in.TargetCPUUtilizationPercentage + } + + return nil +} + +func Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { + out.ObservedGeneration = in.ObservedGeneration + out.LastScaleTime = in.LastScaleTime + + out.CurrentReplicas = in.CurrentReplicas + out.DesiredReplicas = in.DesiredReplicas + + for _, metric := range in.CurrentMetrics { + if metric.Type == autoscaling.ResourceMetricSourceType && metric.Resource != nil && metric.Resource.Name == api.ResourceCPU { + if metric.Resource.CurrentAverageUtilization != nil { + + out.CurrentCPUUtilizationPercentage = new(int32) + *out.CurrentCPUUtilizationPercentage = *metric.Resource.CurrentAverageUtilization + } + } + } + return nil +} + +func Convert_v1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { + out.ObservedGeneration = in.ObservedGeneration + out.LastScaleTime = in.LastScaleTime + + out.CurrentReplicas = in.CurrentReplicas + out.DesiredReplicas = in.DesiredReplicas + + if in.CurrentCPUUtilizationPercentage != nil { + out.CurrentMetrics = []autoscaling.MetricStatus{ + { + Type: autoscaling.ResourceMetricSourceType, + Resource: &autoscaling.ResourceMetricStatus{ + Name: api.ResourceCPU, + }, + }, + } + out.CurrentMetrics[0].Resource.CurrentAverageUtilization = new(int32) + *out.CurrentMetrics[0].Resource.CurrentAverageUtilization = *in.CurrentCPUUtilizationPercentage + } + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/defaults.go index dc0c90c2e4..aeece5b81b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/defaults.go @@ -17,14 +17,11 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_HorizontalPodAutoscaler, - ) + return RegisterDefaults(scheme) } func SetDefaults_HorizontalPodAutoscaler(obj *HorizontalPodAutoscaler) { @@ -32,4 +29,7 @@ func SetDefaults_HorizontalPodAutoscaler(obj *HorizontalPodAutoscaler) { minReplicas := int32(1) obj.Spec.MinReplicas = &minReplicas } + + // NB: we apply a default for CPU utilization in conversion because + // we need access to the annotations to properly apply the default. } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/doc.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/doc.go index 105a57aceb..c7be42d5a1 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/doc.go @@ -14,9 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/autoscaling -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - package v1 diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go index 2c7c484009..552c980ada 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -27,9 +27,18 @@ limitations under the License. It has these top-level messages: CrossVersionObjectReference HorizontalPodAutoscaler + HorizontalPodAutoscalerCondition HorizontalPodAutoscalerList HorizontalPodAutoscalerSpec HorizontalPodAutoscalerStatus + MetricSpec + MetricStatus + ObjectMetricSource + ObjectMetricStatus + PodsMetricSource + PodsMetricStatus + ResourceMetricSource + ResourceMetricStatus Scale ScaleSpec ScaleStatus @@ -40,7 +49,10 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" +import k8s_io_apimachinery_pkg_api_resource "k8s.io/apimachinery/pkg/api/resource" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" import strings "strings" import reflect "reflect" @@ -54,7 +66,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *CrossVersionObjectReference) Reset() { *m = CrossVersionObjectReference{} } func (*CrossVersionObjectReference) ProtoMessage() {} @@ -66,111 +80,158 @@ func (m *HorizontalPodAutoscaler) Reset() { *m = HorizontalPo func (*HorizontalPodAutoscaler) ProtoMessage() {} func (*HorizontalPodAutoscaler) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } +func (m *HorizontalPodAutoscalerCondition) Reset() { *m = HorizontalPodAutoscalerCondition{} } +func (*HorizontalPodAutoscalerCondition) ProtoMessage() {} +func (*HorizontalPodAutoscalerCondition) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + func (m *HorizontalPodAutoscalerList) Reset() { *m = HorizontalPodAutoscalerList{} } func (*HorizontalPodAutoscalerList) ProtoMessage() {} func (*HorizontalPodAutoscalerList) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{2} + return fileDescriptorGenerated, []int{3} } func (m *HorizontalPodAutoscalerSpec) Reset() { *m = HorizontalPodAutoscalerSpec{} } func (*HorizontalPodAutoscalerSpec) ProtoMessage() {} func (*HorizontalPodAutoscalerSpec) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{3} + return fileDescriptorGenerated, []int{4} } func (m *HorizontalPodAutoscalerStatus) Reset() { *m = HorizontalPodAutoscalerStatus{} } func (*HorizontalPodAutoscalerStatus) ProtoMessage() {} func (*HorizontalPodAutoscalerStatus) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{4} + return fileDescriptorGenerated, []int{5} } +func (m *MetricSpec) Reset() { *m = MetricSpec{} } +func (*MetricSpec) ProtoMessage() {} +func (*MetricSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } + +func (m *MetricStatus) Reset() { *m = MetricStatus{} } +func (*MetricStatus) ProtoMessage() {} +func (*MetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *ObjectMetricSource) Reset() { *m = ObjectMetricSource{} } +func (*ObjectMetricSource) ProtoMessage() {} +func (*ObjectMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *ObjectMetricStatus) Reset() { *m = ObjectMetricStatus{} } +func (*ObjectMetricStatus) ProtoMessage() {} +func (*ObjectMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func (m *PodsMetricSource) Reset() { *m = PodsMetricSource{} } +func (*PodsMetricSource) ProtoMessage() {} +func (*PodsMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } + +func (m *PodsMetricStatus) Reset() { *m = PodsMetricStatus{} } +func (*PodsMetricStatus) ProtoMessage() {} +func (*PodsMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } + +func (m *ResourceMetricSource) Reset() { *m = ResourceMetricSource{} } +func (*ResourceMetricSource) ProtoMessage() {} +func (*ResourceMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } + +func (m *ResourceMetricStatus) Reset() { *m = ResourceMetricStatus{} } +func (*ResourceMetricStatus) ProtoMessage() {} +func (*ResourceMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } + func (m *Scale) Reset() { *m = Scale{} } func (*Scale) ProtoMessage() {} -func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } +func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{14} } func (m *ScaleSpec) Reset() { *m = ScaleSpec{} } func (*ScaleSpec) ProtoMessage() {} -func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } +func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{15} } func (m *ScaleStatus) Reset() { *m = ScaleStatus{} } func (*ScaleStatus) ProtoMessage() {} -func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } +func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } func init() { proto.RegisterType((*CrossVersionObjectReference)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.CrossVersionObjectReference") proto.RegisterType((*HorizontalPodAutoscaler)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.HorizontalPodAutoscaler") + proto.RegisterType((*HorizontalPodAutoscalerCondition)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.HorizontalPodAutoscalerCondition") proto.RegisterType((*HorizontalPodAutoscalerList)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.HorizontalPodAutoscalerList") proto.RegisterType((*HorizontalPodAutoscalerSpec)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.HorizontalPodAutoscalerSpec") proto.RegisterType((*HorizontalPodAutoscalerStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.HorizontalPodAutoscalerStatus") + proto.RegisterType((*MetricSpec)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.MetricSpec") + proto.RegisterType((*MetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.MetricStatus") + proto.RegisterType((*ObjectMetricSource)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.ObjectMetricSource") + proto.RegisterType((*ObjectMetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.ObjectMetricStatus") + proto.RegisterType((*PodsMetricSource)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.PodsMetricSource") + proto.RegisterType((*PodsMetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.PodsMetricStatus") + proto.RegisterType((*ResourceMetricSource)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.ResourceMetricSource") + proto.RegisterType((*ResourceMetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.ResourceMetricStatus") proto.RegisterType((*Scale)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.Scale") proto.RegisterType((*ScaleSpec)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.ScaleSpec") proto.RegisterType((*ScaleStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v1.ScaleStatus") } -func (m *CrossVersionObjectReference) Marshal() (data []byte, err error) { +func (m *CrossVersionObjectReference) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CrossVersionObjectReference) MarshalTo(data []byte) (int, error) { +func (m *CrossVersionObjectReference) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) return i, nil } -func (m *HorizontalPodAutoscaler) Marshal() (data []byte, err error) { +func (m *HorizontalPodAutoscaler) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HorizontalPodAutoscaler) MarshalTo(data []byte) (int, error) { +func (m *HorizontalPodAutoscaler) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -178,35 +239,77 @@ func (m *HorizontalPodAutoscaler) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *HorizontalPodAutoscalerList) Marshal() (data []byte, err error) { +func (m *HorizontalPodAutoscalerCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HorizontalPodAutoscalerList) MarshalTo(data []byte) (int, error) { +func (m *HorizontalPodAutoscalerCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n4, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n4, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + return i, nil +} + +func (m *HorizontalPodAutoscalerList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HorizontalPodAutoscalerList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n5, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -216,202 +319,514 @@ func (m *HorizontalPodAutoscalerList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *HorizontalPodAutoscalerSpec) Marshal() (data []byte, err error) { +func (m *HorizontalPodAutoscalerSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HorizontalPodAutoscalerSpec) MarshalTo(data []byte) (int, error) { +func (m *HorizontalPodAutoscalerSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ScaleTargetRef.Size())) - n5, err := m.ScaleTargetRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleTargetRef.Size())) + n6, err := m.ScaleTargetRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n5 + i += n6 if m.MinReplicas != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.MinReplicas)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.MinReplicas)) } - data[i] = 0x18 + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.MaxReplicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxReplicas)) if m.TargetCPUUtilizationPercentage != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(*m.TargetCPUUtilizationPercentage)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.TargetCPUUtilizationPercentage)) } return i, nil } -func (m *HorizontalPodAutoscalerStatus) Marshal() (data []byte, err error) { +func (m *HorizontalPodAutoscalerStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HorizontalPodAutoscalerStatus) MarshalTo(data []byte) (int, error) { +func (m *HorizontalPodAutoscalerStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.ObservedGeneration != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.ObservedGeneration)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.ObservedGeneration)) } if m.LastScaleTime != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastScaleTime.Size())) - n6, err := m.LastScaleTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastScaleTime.Size())) + n7, err := m.LastScaleTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n6 + i += n7 } - data[i] = 0x18 + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.CurrentReplicas)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentReplicas)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.DesiredReplicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.DesiredReplicas)) if m.CurrentCPUUtilizationPercentage != nil { - data[i] = 0x28 + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.CurrentCPUUtilizationPercentage)) + } + return i, nil +} + +func (m *MetricSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MetricSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.Object != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size())) + n8, err := m.Object.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 + } + if m.Pods != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Pods.Size())) + n9, err := m.Pods.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + } + if m.Resource != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Resource.Size())) + n10, err := m.Resource.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + } + return i, nil +} + +func (m *MetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.Object != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size())) + n11, err := m.Object.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n11 + } + if m.Pods != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Pods.Size())) + n12, err := m.Pods.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n12 + } + if m.Resource != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Resource.Size())) + n13, err := m.Resource.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n13 + } + return i, nil +} + +func (m *ObjectMetricSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ObjectMetricSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size())) + n14, err := m.Target.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n14 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetValue.Size())) + n15, err := m.TargetValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n15 + return i, nil +} + +func (m *ObjectMetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ObjectMetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size())) + n16, err := m.Target.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n16 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentValue.Size())) + n17, err := m.CurrentValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n17 + return i, nil +} + +func (m *PodsMetricSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodsMetricSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetAverageValue.Size())) + n18, err := m.TargetAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n18 + return i, nil +} + +func (m *PodsMetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodsMetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentAverageValue.Size())) + n19, err := m.CurrentAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n19 + return i, nil +} + +func (m *ResourceMetricSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ResourceMetricSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if m.TargetAverageUtilization != nil { + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.TargetAverageUtilization)) + } + if m.TargetAverageValue != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetAverageValue.Size())) + n20, err := m.TargetAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n20 + } + return i, nil +} + +func (m *ResourceMetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ResourceMetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if m.CurrentAverageUtilization != nil { + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.CurrentCPUUtilizationPercentage)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.CurrentAverageUtilization)) + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentAverageValue.Size())) + n21, err := m.CurrentAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err } + i += n21 return i, nil } -func (m *Scale) Marshal() (data []byte, err error) { +func (m *Scale) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Scale) MarshalTo(data []byte) (int, error) { +func (m *Scale) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n7, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n22, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n7 - data[i] = 0x12 + i += n22 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n8, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n23, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n8 - data[i] = 0x1a + i += n23 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n9, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n24, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n9 + i += n24 return i, nil } -func (m *ScaleSpec) Marshal() (data []byte, err error) { +func (m *ScaleSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ScaleSpec) MarshalTo(data []byte) (int, error) { +func (m *ScaleSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) return i, nil } -func (m *ScaleStatus) Marshal() (data []byte, err error) { +func (m *ScaleStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ScaleStatus) MarshalTo(data []byte) (int, error) { +func (m *ScaleStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Selector))) - i += copy(data[i:], m.Selector) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Selector))) + i += copy(dAtA[i:], m.Selector) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *CrossVersionObjectReference) Size() (n int) { @@ -438,6 +853,22 @@ func (m *HorizontalPodAutoscaler) Size() (n int) { return n } +func (m *HorizontalPodAutoscalerCondition) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Status) + n += 1 + l + sovGenerated(uint64(l)) + l = m.LastTransitionTime.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Reason) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Message) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + func (m *HorizontalPodAutoscalerList) Size() (n int) { var l int _ = l @@ -485,35 +916,147 @@ func (m *HorizontalPodAutoscalerStatus) Size() (n int) { return n } -func (m *Scale) Size() (n int) { +func (m *MetricSpec) Size() (n int) { var l int _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() + l = len(m.Type) n += 1 + l + sovGenerated(uint64(l)) + if m.Object != nil { + l = m.Object.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Pods != nil { + l = m.Pods.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Resource != nil { + l = m.Resource.Size() + n += 1 + l + sovGenerated(uint64(l)) + } return n } -func (m *ScaleSpec) Size() (n int) { +func (m *MetricStatus) Size() (n int) { var l int _ = l - n += 1 + sovGenerated(uint64(m.Replicas)) + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + if m.Object != nil { + l = m.Object.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Pods != nil { + l = m.Pods.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Resource != nil { + l = m.Resource.Size() + n += 1 + l + sovGenerated(uint64(l)) + } return n } -func (m *ScaleStatus) Size() (n int) { +func (m *ObjectMetricSource) Size() (n int) { var l int _ = l - n += 1 + sovGenerated(uint64(m.Replicas)) - l = len(m.Selector) + l = m.Target.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.TargetValue.Size() n += 1 + l + sovGenerated(uint64(l)) return n } -func sovGenerated(x uint64) (n int) { +func (m *ObjectMetricStatus) Size() (n int) { + var l int + _ = l + l = m.Target.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.CurrentValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *PodsMetricSource) Size() (n int) { + var l int + _ = l + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.TargetAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *PodsMetricStatus) Size() (n int) { + var l int + _ = l + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.CurrentAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ResourceMetricSource) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if m.TargetAverageUtilization != nil { + n += 1 + sovGenerated(uint64(*m.TargetAverageUtilization)) + } + if m.TargetAverageValue != nil { + l = m.TargetAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ResourceMetricStatus) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if m.CurrentAverageUtilization != nil { + n += 1 + sovGenerated(uint64(*m.CurrentAverageUtilization)) + } + l = m.CurrentAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Scale) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ScaleSpec) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Replicas)) + return n +} + +func (m *ScaleStatus) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Replicas)) + l = len(m.Selector) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { for { n++ x >>= 7 @@ -543,19 +1086,33 @@ func (this *HorizontalPodAutoscaler) String() string { return "nil" } s := strings.Join([]string{`&HorizontalPodAutoscaler{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "HorizontalPodAutoscalerSpec", "HorizontalPodAutoscalerSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "HorizontalPodAutoscalerStatus", "HorizontalPodAutoscalerStatus", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } +func (this *HorizontalPodAutoscalerCondition) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HorizontalPodAutoscalerCondition{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Status:` + fmt.Sprintf("%v", this.Status) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, + `Message:` + fmt.Sprintf("%v", this.Message) + `,`, + `}`, + }, "") + return s +} func (this *HorizontalPodAutoscalerList) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&HorizontalPodAutoscalerList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "HorizontalPodAutoscaler", "HorizontalPodAutoscaler", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -580,7 +1137,7 @@ func (this *HorizontalPodAutoscalerStatus) String() string { } s := strings.Join([]string{`&HorizontalPodAutoscalerStatus{`, `ObservedGeneration:` + valueToStringGenerated(this.ObservedGeneration) + `,`, - `LastScaleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScaleTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, + `LastScaleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScaleTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, `CurrentReplicas:` + fmt.Sprintf("%v", this.CurrentReplicas) + `,`, `DesiredReplicas:` + fmt.Sprintf("%v", this.DesiredReplicas) + `,`, `CurrentCPUUtilizationPercentage:` + valueToStringGenerated(this.CurrentCPUUtilizationPercentage) + `,`, @@ -588,12 +1145,108 @@ func (this *HorizontalPodAutoscalerStatus) String() string { }, "") return s } +func (this *MetricSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&MetricSpec{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Object:` + strings.Replace(fmt.Sprintf("%v", this.Object), "ObjectMetricSource", "ObjectMetricSource", 1) + `,`, + `Pods:` + strings.Replace(fmt.Sprintf("%v", this.Pods), "PodsMetricSource", "PodsMetricSource", 1) + `,`, + `Resource:` + strings.Replace(fmt.Sprintf("%v", this.Resource), "ResourceMetricSource", "ResourceMetricSource", 1) + `,`, + `}`, + }, "") + return s +} +func (this *MetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&MetricStatus{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Object:` + strings.Replace(fmt.Sprintf("%v", this.Object), "ObjectMetricStatus", "ObjectMetricStatus", 1) + `,`, + `Pods:` + strings.Replace(fmt.Sprintf("%v", this.Pods), "PodsMetricStatus", "PodsMetricStatus", 1) + `,`, + `Resource:` + strings.Replace(fmt.Sprintf("%v", this.Resource), "ResourceMetricStatus", "ResourceMetricStatus", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ObjectMetricSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ObjectMetricSource{`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `TargetValue:` + strings.Replace(strings.Replace(this.TargetValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ObjectMetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ObjectMetricStatus{`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `CurrentValue:` + strings.Replace(strings.Replace(this.CurrentValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PodsMetricSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodsMetricSource{`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `TargetAverageValue:` + strings.Replace(strings.Replace(this.TargetAverageValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PodsMetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodsMetricStatus{`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `CurrentAverageValue:` + strings.Replace(strings.Replace(this.CurrentAverageValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ResourceMetricSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ResourceMetricSource{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `TargetAverageUtilization:` + valueToStringGenerated(this.TargetAverageUtilization) + `,`, + `TargetAverageValue:` + strings.Replace(fmt.Sprintf("%v", this.TargetAverageValue), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ResourceMetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ResourceMetricStatus{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `CurrentAverageUtilization:` + valueToStringGenerated(this.CurrentAverageUtilization) + `,`, + `CurrentAverageValue:` + strings.Replace(strings.Replace(this.CurrentAverageValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} func (this *Scale) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&Scale{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ScaleSpec", "ScaleSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ScaleStatus", "ScaleStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -629,8 +1282,1248 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { - l := len(data) +func (m *CrossVersionObjectReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: CrossVersionObjectReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: CrossVersionObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscaler) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscaler: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscaler: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerCondition: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerCondition: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = HorizontalPodAutoscalerConditionType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, HorizontalPodAutoscaler{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ScaleTargetRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ScaleTargetRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MinReplicas", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.MinReplicas = &v + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MaxReplicas", wireType) + } + m.MaxReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.MaxReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetCPUUtilizationPercentage", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.TargetCPUUtilizationPercentage = &v + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ObservedGeneration = &v + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastScaleTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.LastScaleTime == nil { + m.LastScaleTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} + } + if err := m.LastScaleTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentReplicas", wireType) + } + m.CurrentReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CurrentReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DesiredReplicas", wireType) + } + m.DesiredReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.DesiredReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentCPUUtilizationPercentage", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.CurrentCPUUtilizationPercentage = &v + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MetricSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MetricSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MetricSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = MetricSourceType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Object == nil { + m.Object = &ObjectMetricSource{} + } + if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pods", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Pods == nil { + m.Pods = &PodsMetricSource{} + } + if err := m.Pods.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Resource == nil { + m.Resource = &ResourceMetricSource{} + } + if err := m.Resource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MetricStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = MetricSourceType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Object == nil { + m.Object = &ObjectMetricStatus{} + } + if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pods", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Pods == nil { + m.Pods = &PodsMetricStatus{} + } + if err := m.Pods.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Resource == nil { + m.Resource = &ResourceMetricStatus{} + } + if err := m.Resource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ObjectMetricSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -642,7 +2535,7 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -652,17 +2545,17 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: CrossVersionObjectReference: wiretype end group for non-group") + return fmt.Errorf("proto: ObjectMetricSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: CrossVersionObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ObjectMetricSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -670,26 +2563,27 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = string(data[iNdEx:postIndex]) + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -699,7 +2593,7 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -714,13 +2608,13 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.MetricName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetValue", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -728,26 +2622,27 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.APIVersion = string(data[iNdEx:postIndex]) + if err := m.TargetValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -766,8 +2661,8 @@ func (m *CrossVersionObjectReference) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { - l := len(data) +func (m *ObjectMetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -779,7 +2674,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -789,15 +2684,15 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscaler: wiretype end group for non-group") + return fmt.Errorf("proto: ObjectMetricStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscaler: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ObjectMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -807,7 +2702,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -821,15 +2716,15 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -837,27 +2732,26 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.MetricName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field CurrentValue", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -867,7 +2761,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -881,13 +2775,13 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.CurrentValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -906,8 +2800,8 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { - l := len(data) +func (m *PodsMetricSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -919,7 +2813,7 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -929,17 +2823,17 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscalerList: wiretype end group for non-group") + return fmt.Errorf("proto: PodsMetricSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscalerList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodsMetricSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -947,27 +2841,26 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.MetricName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetAverageValue", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -977,7 +2870,7 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -991,14 +2884,13 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, HorizontalPodAutoscaler{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TargetAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1017,8 +2909,8 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *PodsMetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1030,7 +2922,7 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1040,17 +2932,17 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: wiretype end group for non-group") + return fmt.Errorf("proto: PodsMetricStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: PodsMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ScaleTargetRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1058,29 +2950,28 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ScaleTargetRef.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.MetricName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field MinReplicas", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentAverageValue", wireType) } - var v int32 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1088,56 +2979,27 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.MinReplicas = &v - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field MaxReplicas", wireType) - } - m.MaxReplicas = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.MaxReplicas |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } + if msglen < 0 { + return ErrInvalidLengthGenerated } - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetCPUUtilizationPercentage", wireType) + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF } - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.CurrentAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.TargetCPUUtilizationPercentage = &v + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1156,8 +3018,8 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ResourceMetricSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1169,7 +3031,7 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1179,17 +3041,17 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: wiretype end group for non-group") + return fmt.Errorf("proto: ResourceMetricSource: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: ResourceMetricSource: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) } - var v int64 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1197,17 +3059,46 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.ObservedGeneration = &v + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = k8s_io_kubernetes_pkg_api_v1.ResourceName(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetAverageUtilization", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.TargetAverageUtilization = &v + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastScaleTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetAverageValue", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -1217,7 +3108,7 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1231,18 +3122,68 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.LastScaleTime == nil { - m.LastScaleTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + if m.TargetAverageValue == nil { + m.TargetAverageValue = &k8s_io_apimachinery_pkg_api_resource.Quantity{} } - if err := m.LastScaleTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TargetAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CurrentReplicas", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - m.CurrentReplicas = 0 + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ResourceMetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ResourceMetricStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ResourceMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1250,18 +3191,28 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.CurrentReplicas |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - case 4: + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = k8s_io_kubernetes_pkg_api_v1.ResourceName(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DesiredReplicas", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field CurrentAverageUtilization", wireType) } - m.DesiredReplicas = 0 + var v int32 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1269,18 +3220,19 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.DesiredReplicas |= (int32(b) & 0x7F) << shift + v |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CurrentCPUUtilizationPercentage", wireType) + m.CurrentAverageUtilization = &v + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentAverageValue", wireType) } - var v int32 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1288,17 +3240,27 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.CurrentCPUUtilizationPercentage = &v + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.CurrentAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1317,8 +3279,8 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { } return nil } -func (m *Scale) Unmarshal(data []byte) error { - l := len(data) +func (m *Scale) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1330,7 +3292,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1358,7 +3320,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1372,7 +3334,7 @@ func (m *Scale) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1388,7 +3350,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1402,7 +3364,7 @@ func (m *Scale) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1418,7 +3380,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1432,13 +3394,13 @@ func (m *Scale) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1457,8 +3419,8 @@ func (m *Scale) Unmarshal(data []byte) error { } return nil } -func (m *ScaleSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *ScaleSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1470,7 +3432,7 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1498,7 +3460,7 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1507,7 +3469,7 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1526,8 +3488,8 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { } return nil } -func (m *ScaleStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ScaleStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1539,7 +3501,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1567,7 +3529,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1586,7 +3548,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1601,11 +3563,11 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Selector = string(data[iNdEx:postIndex]) + m.Selector = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1624,8 +3586,8 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -1636,7 +3598,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1654,7 +3616,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -1671,7 +3633,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1694,7 +3656,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1705,7 +3667,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1729,59 +3691,97 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 835 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x55, 0xcd, 0x6f, 0xdc, 0x44, - 0x14, 0x5f, 0xef, 0x47, 0x95, 0x8e, 0x49, 0x02, 0x83, 0xd4, 0xae, 0x52, 0x61, 0x47, 0x0b, 0x87, - 0x20, 0x5a, 0x5b, 0xbb, 0xa2, 0x88, 0x1e, 0xe3, 0xa0, 0xd2, 0x8a, 0x86, 0x46, 0x93, 0xb6, 0x42, - 0x48, 0x20, 0xcd, 0xda, 0xaf, 0xee, 0x74, 0xd7, 0x1e, 0x6b, 0x66, 0xbc, 0x42, 0x3d, 0x71, 0xe2, - 0xcc, 0x85, 0x03, 0xff, 0x0e, 0xa7, 0xdc, 0xe8, 0x91, 0xd3, 0x8a, 0x18, 0xf1, 0x5f, 0x70, 0x40, - 0x9e, 0x9d, 0x7a, 0xbf, 0xe2, 0x6d, 0x23, 0xe8, 0x6d, 0x67, 0xde, 0xef, 0xe3, 0xcd, 0x7b, 0xcf, - 0x6f, 0xd1, 0x9d, 0xd1, 0xe7, 0xd2, 0x63, 0xdc, 0x1f, 0xe5, 0x43, 0x10, 0x29, 0x28, 0x90, 0x7e, - 0x36, 0x8a, 0x7d, 0x9a, 0x31, 0xe9, 0xd3, 0x5c, 0x71, 0x19, 0xd2, 0x31, 0x4b, 0x63, 0x7f, 0xd2, - 0xf7, 0x63, 0x48, 0x41, 0x50, 0x05, 0x91, 0x97, 0x09, 0xae, 0x38, 0xfe, 0x78, 0x46, 0xf5, 0xe6, - 0x54, 0x2f, 0x1b, 0xc5, 0x5e, 0x49, 0xf5, 0x16, 0xa8, 0xde, 0xa4, 0xbf, 0x77, 0x2b, 0x66, 0xea, - 0x59, 0x3e, 0xf4, 0x42, 0x9e, 0xf8, 0x31, 0x8f, 0xb9, 0xaf, 0x15, 0x86, 0xf9, 0x53, 0x7d, 0xd2, - 0x07, 0xfd, 0x6b, 0xa6, 0xbc, 0x37, 0xa8, 0x4d, 0xca, 0x17, 0x20, 0x79, 0x2e, 0x42, 0x58, 0xcd, - 0x66, 0xef, 0x76, 0x3d, 0x27, 0x4f, 0x27, 0x20, 0x24, 0xe3, 0x29, 0x44, 0x6b, 0xb4, 0x9b, 0xf5, - 0xb4, 0xf5, 0x27, 0xef, 0xdd, 0xba, 0x18, 0x2d, 0xf2, 0x54, 0xb1, 0x64, 0x3d, 0xa7, 0xfe, 0xc5, - 0xf0, 0x5c, 0xb1, 0xb1, 0xcf, 0x52, 0x25, 0x95, 0x58, 0xa5, 0xf4, 0x7e, 0xb1, 0xd0, 0x8d, 0x23, - 0xc1, 0xa5, 0x7c, 0x32, 0x4b, 0xf9, 0xe1, 0xf0, 0x39, 0x84, 0x8a, 0xc0, 0x53, 0x10, 0x90, 0x86, - 0x80, 0xf7, 0x51, 0x7b, 0xc4, 0xd2, 0xa8, 0x6b, 0xed, 0x5b, 0x07, 0x57, 0x83, 0x77, 0xce, 0xa6, - 0x6e, 0xa3, 0x98, 0xba, 0xed, 0xaf, 0x58, 0x1a, 0x11, 0x1d, 0x29, 0x11, 0x29, 0x4d, 0xa0, 0xdb, - 0x5c, 0x46, 0x7c, 0x4d, 0x13, 0x20, 0x3a, 0x82, 0x07, 0x08, 0xd1, 0x8c, 0x19, 0x83, 0x6e, 0x4b, - 0xe3, 0xb0, 0xc1, 0xa1, 0xc3, 0x93, 0xfb, 0x26, 0x42, 0x16, 0x50, 0xbd, 0xdf, 0x9b, 0xe8, 0xfa, - 0x3d, 0x2e, 0xd8, 0x0b, 0x9e, 0x2a, 0x3a, 0x3e, 0xe1, 0xd1, 0xa1, 0xe9, 0x30, 0x08, 0xfc, 0x0d, - 0xda, 0x4a, 0x40, 0xd1, 0x88, 0x2a, 0xaa, 0xf3, 0xb2, 0x07, 0x07, 0x5e, 0xed, 0x6c, 0x78, 0x93, - 0xbe, 0x37, 0x7b, 0xd4, 0x31, 0x28, 0x3a, 0xf7, 0x9d, 0xdf, 0x91, 0x4a, 0x0d, 0x3f, 0x43, 0x6d, - 0x99, 0x41, 0xa8, 0xdf, 0x62, 0x0f, 0xee, 0x7a, 0x6f, 0x3c, 0x71, 0x5e, 0x4d, 0xae, 0xa7, 0x19, - 0x84, 0xf3, 0x9a, 0x94, 0x27, 0xa2, 0x1d, 0x70, 0x86, 0xae, 0x48, 0x45, 0x55, 0x2e, 0x75, 0x3d, - 0xec, 0xc1, 0xbd, 0xff, 0xc1, 0x4b, 0xeb, 0x05, 0x3b, 0xc6, 0xed, 0xca, 0xec, 0x4c, 0x8c, 0x4f, - 0xef, 0x6f, 0x0b, 0xdd, 0xa8, 0x61, 0x3e, 0x60, 0x52, 0xe1, 0xef, 0xd6, 0xaa, 0xea, 0x6f, 0xa8, - 0xea, 0xc2, 0x8c, 0x7b, 0x25, 0x5d, 0x17, 0xf7, 0x5d, 0x63, 0xbd, 0xf5, 0xea, 0x66, 0xa1, 0xb4, - 0x31, 0xea, 0x30, 0x05, 0x89, 0xec, 0x36, 0xf7, 0x5b, 0x07, 0xf6, 0x20, 0xf8, 0xef, 0xef, 0x0d, - 0xb6, 0x8d, 0x5d, 0xe7, 0x7e, 0x29, 0x4c, 0x66, 0xfa, 0xbd, 0x7f, 0x9a, 0xb5, 0xef, 0x2c, 0xeb, - 0x8f, 0x7f, 0xb2, 0xd0, 0x8e, 0x3e, 0x3e, 0xa2, 0x22, 0x86, 0x72, 0xd4, 0xcd, 0x73, 0x2f, 0xd3, - 0xee, 0x0d, 0x9f, 0x4c, 0x70, 0xcd, 0xa4, 0xb5, 0x73, 0xba, 0xe4, 0x42, 0x56, 0x5c, 0x71, 0x1f, - 0xd9, 0x09, 0x4b, 0x09, 0x64, 0x63, 0x16, 0x52, 0xa9, 0x67, 0xae, 0x13, 0xec, 0x16, 0x53, 0xd7, - 0x3e, 0x9e, 0x5f, 0x93, 0x45, 0x0c, 0xbe, 0x8d, 0xec, 0x84, 0xfe, 0x50, 0x51, 0x5a, 0x9a, 0xf2, - 0xbe, 0xf1, 0xb3, 0x8f, 0xe7, 0x21, 0xb2, 0x88, 0xc3, 0xcf, 0x91, 0xa3, 0xb4, 0xed, 0xd1, 0xc9, - 0xe3, 0xc7, 0x8a, 0x8d, 0xd9, 0x0b, 0xaa, 0x18, 0x4f, 0x4f, 0x40, 0x84, 0x90, 0x2a, 0x1a, 0x43, - 0xb7, 0xad, 0x95, 0x7a, 0xc5, 0xd4, 0x75, 0x1e, 0x6d, 0x44, 0x92, 0xd7, 0x28, 0xf5, 0x7e, 0x6b, - 0xa1, 0x0f, 0x36, 0x0e, 0x28, 0xbe, 0x8b, 0x30, 0x1f, 0x4a, 0x10, 0x13, 0x88, 0xbe, 0x9c, 0x6d, - 0xa3, 0x72, 0x2d, 0x94, 0x3d, 0x68, 0x05, 0xd7, 0x8a, 0xa9, 0x8b, 0x1f, 0xae, 0x45, 0xc9, 0x05, - 0x0c, 0x1c, 0xa1, 0xed, 0x31, 0x95, 0x6a, 0x56, 0x65, 0x66, 0x36, 0x90, 0x3d, 0xf8, 0xe4, 0x0d, - 0xa7, 0xb6, 0xa4, 0x04, 0xef, 0x15, 0x53, 0x77, 0xfb, 0xc1, 0xa2, 0x0a, 0x59, 0x16, 0xc5, 0x87, - 0x68, 0x37, 0xcc, 0x85, 0x80, 0x54, 0xad, 0x94, 0xfd, 0xba, 0x29, 0xfb, 0xee, 0xd1, 0x72, 0x98, - 0xac, 0xe2, 0x4b, 0x89, 0x08, 0x24, 0x13, 0x10, 0x55, 0x12, 0xed, 0x65, 0x89, 0x2f, 0x96, 0xc3, - 0x64, 0x15, 0x8f, 0x13, 0xe4, 0x1a, 0xd5, 0xda, 0x16, 0x76, 0xb4, 0xe4, 0x87, 0xc5, 0xd4, 0x75, - 0x8f, 0x36, 0x43, 0xc9, 0xeb, 0xb4, 0x7a, 0xbf, 0x36, 0x51, 0x47, 0x97, 0xe0, 0x2d, 0xee, 0xda, - 0x27, 0x4b, 0xbb, 0xf6, 0xd3, 0x4b, 0x7c, 0x7c, 0x3a, 0xb3, 0xda, 0xcd, 0xfa, 0xfd, 0xca, 0x66, - 0xfd, 0xec, 0xd2, 0xca, 0x9b, 0xf7, 0xe8, 0x1d, 0x74, 0xb5, 0x4a, 0x00, 0xdf, 0x44, 0x5b, 0xe2, - 0x55, 0x4f, 0x2d, 0xdd, 0x80, 0x6a, 0x07, 0x56, 0xcd, 0xac, 0x10, 0x3d, 0x86, 0xec, 0x05, 0x87, - 0xcb, 0x91, 0x4b, 0xb4, 0x84, 0x31, 0x84, 0x8a, 0x0b, 0xf3, 0x5f, 0x5b, 0xa1, 0x4f, 0xcd, 0x3d, - 0xa9, 0x10, 0xc1, 0x47, 0x67, 0xe7, 0x4e, 0xe3, 0xe5, 0xb9, 0xd3, 0xf8, 0xe3, 0xdc, 0x69, 0xfc, - 0x58, 0x38, 0xd6, 0x59, 0xe1, 0x58, 0x2f, 0x0b, 0xc7, 0xfa, 0xb3, 0x70, 0xac, 0x9f, 0xff, 0x72, - 0x1a, 0xdf, 0x36, 0x27, 0xfd, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, 0x45, 0xec, 0x9a, 0x15, 0x8e, - 0x09, 0x00, 0x00, + // 1381 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x58, 0xcf, 0x6f, 0x1b, 0xc5, + 0x17, 0xcf, 0xda, 0x4e, 0x9a, 0x8e, 0xd3, 0xa6, 0xdf, 0x69, 0xd5, 0xba, 0xe9, 0xb7, 0xde, 0x68, + 0x41, 0xa8, 0x45, 0x65, 0x4d, 0x42, 0xa8, 0xa8, 0x10, 0xa0, 0xd8, 0xa8, 0xb4, 0xa2, 0x6e, 0xc3, + 0xd4, 0x8d, 0xf8, 0x25, 0xc4, 0x64, 0x3d, 0x75, 0xa6, 0xf1, 0xfe, 0xd0, 0xcc, 0xd8, 0x22, 0x95, + 0x90, 0x38, 0x71, 0x85, 0x0b, 0x67, 0x04, 0xff, 0x04, 0xe7, 0x22, 0x21, 0xf5, 0xd8, 0x1b, 0x3d, + 0x59, 0x74, 0xe1, 0x86, 0xf8, 0x07, 0x2a, 0x0e, 0x68, 0x66, 0xc7, 0xeb, 0x5d, 0xdb, 0xeb, 0xc4, + 0x6d, 0x5a, 0xc4, 0xcd, 0x9e, 0xf9, 0xbc, 0xcf, 0xe7, 0xbd, 0x37, 0x6f, 0xde, 0xcc, 0x2c, 0xb8, + 0xb4, 0xf3, 0x06, 0xb7, 0xa9, 0x5f, 0xd9, 0xe9, 0x6c, 0x11, 0xe6, 0x11, 0x41, 0x78, 0x25, 0xd8, + 0x69, 0x55, 0x70, 0x40, 0x79, 0x05, 0x77, 0x84, 0xcf, 0x1d, 0xdc, 0xa6, 0x5e, 0xab, 0xd2, 0x5d, + 0xa9, 0xb4, 0x88, 0x47, 0x18, 0x16, 0xa4, 0x69, 0x07, 0xcc, 0x17, 0x3e, 0x3c, 0x1f, 0x99, 0xda, + 0x03, 0x53, 0x3b, 0xd8, 0x69, 0xd9, 0xd2, 0xd4, 0x4e, 0x98, 0xda, 0xdd, 0x95, 0xa5, 0x57, 0x5a, + 0x54, 0x6c, 0x77, 0xb6, 0x6c, 0xc7, 0x77, 0x2b, 0x2d, 0xbf, 0xe5, 0x57, 0x14, 0xc3, 0x56, 0xe7, + 0xb6, 0xfa, 0xa7, 0xfe, 0xa8, 0x5f, 0x11, 0xf3, 0xd2, 0x9a, 0x76, 0x0a, 0x07, 0xd4, 0xc5, 0xce, + 0x36, 0xf5, 0x08, 0xdb, 0xed, 0xbb, 0x55, 0x61, 0x84, 0xfb, 0x1d, 0xe6, 0x90, 0x61, 0x7f, 0x26, + 0x5a, 0xf1, 0x8a, 0x4b, 0x04, 0x1e, 0x13, 0xc5, 0x52, 0x25, 0xcb, 0x8a, 0x75, 0x3c, 0x41, 0xdd, + 0x51, 0x99, 0x8b, 0x7b, 0x19, 0x70, 0x67, 0x9b, 0xb8, 0x78, 0xc4, 0xee, 0xb5, 0x2c, 0xbb, 0x8e, + 0xa0, 0xed, 0x0a, 0xf5, 0x04, 0x17, 0x6c, 0xc4, 0xe8, 0x42, 0xe6, 0xf2, 0x8c, 0x89, 0xc5, 0xfa, + 0xce, 0x00, 0x67, 0x6a, 0xcc, 0xe7, 0x7c, 0x93, 0x30, 0x4e, 0x7d, 0xef, 0xc6, 0xd6, 0x1d, 0xe2, + 0x08, 0x44, 0x6e, 0x13, 0x46, 0x3c, 0x87, 0xc0, 0x65, 0x50, 0xd8, 0xa1, 0x5e, 0xb3, 0x64, 0x2c, + 0x1b, 0xe7, 0x0e, 0x57, 0x17, 0xee, 0xf7, 0xcc, 0x99, 0xb0, 0x67, 0x16, 0xde, 0xa7, 0x5e, 0x13, + 0xa9, 0x19, 0x89, 0xf0, 0xb0, 0x4b, 0x4a, 0xb9, 0x34, 0xe2, 0x3a, 0x76, 0x09, 0x52, 0x33, 0x70, + 0x15, 0x00, 0x1c, 0x50, 0x2d, 0x50, 0xca, 0x2b, 0x1c, 0xd4, 0x38, 0xb0, 0xbe, 0x71, 0x55, 0xcf, + 0xa0, 0x04, 0xca, 0xfa, 0x35, 0x07, 0x4e, 0x5d, 0xf1, 0x19, 0xbd, 0xeb, 0x7b, 0x02, 0xb7, 0x37, + 0xfc, 0xe6, 0xba, 0x2e, 0x0f, 0xc2, 0xe0, 0xe7, 0x60, 0x5e, 0x2e, 0x4d, 0x13, 0x0b, 0xac, 0xfc, + 0x2a, 0xae, 0xbe, 0x6a, 0xeb, 0xc2, 0x4a, 0x66, 0x6a, 0x50, 0x5a, 0x12, 0x6d, 0x77, 0x57, 0xec, + 0x28, 0xb8, 0x3a, 0x11, 0x78, 0xa0, 0x3f, 0x18, 0x43, 0x31, 0x2b, 0xdc, 0x06, 0x05, 0x1e, 0x10, + 0x47, 0xc5, 0x54, 0x5c, 0xbd, 0x6c, 0xef, 0xbb, 0x6c, 0xed, 0x0c, 0x9f, 0x6f, 0x06, 0xc4, 0x19, + 0xe4, 0x46, 0xfe, 0x43, 0x4a, 0x01, 0x06, 0x60, 0x8e, 0x0b, 0x2c, 0x3a, 0x5c, 0xe5, 0xa5, 0xb8, + 0x7a, 0xe5, 0x00, 0xb4, 0x14, 0x5f, 0xf5, 0xa8, 0x56, 0x9b, 0x8b, 0xfe, 0x23, 0xad, 0x63, 0x7d, + 0x93, 0x07, 0xcb, 0x19, 0x96, 0x35, 0xdf, 0x6b, 0x52, 0x41, 0x7d, 0x0f, 0x5e, 0x01, 0x05, 0xb1, + 0x1b, 0x10, 0xbd, 0xec, 0x6b, 0x7d, 0xc7, 0x1b, 0xbb, 0x01, 0x79, 0xdc, 0x33, 0x5f, 0xdc, 0xcb, + 0x5e, 0xe2, 0x90, 0x62, 0x80, 0x9b, 0x71, 0x80, 0x51, 0x81, 0xbc, 0x9d, 0x76, 0xeb, 0x71, 0xcf, + 0x9c, 0x58, 0xb0, 0x76, 0xcc, 0x99, 0x0e, 0x03, 0x76, 0x01, 0x6c, 0x63, 0x2e, 0x1a, 0x0c, 0x7b, + 0x3c, 0xd2, 0xa4, 0x2e, 0xd1, 0x49, 0x7c, 0x79, 0x7f, 0xe5, 0x20, 0x2d, 0xaa, 0x4b, 0xda, 0x1f, + 0x78, 0x6d, 0x84, 0x0d, 0x8d, 0x51, 0x80, 0x2f, 0x81, 0x39, 0x46, 0x30, 0xf7, 0xbd, 0x52, 0x41, + 0xc5, 0x13, 0xa7, 0x19, 0xa9, 0x51, 0xa4, 0x67, 0xe1, 0x79, 0x70, 0xc8, 0x25, 0x9c, 0xe3, 0x16, + 0x29, 0xcd, 0x2a, 0xe0, 0xa2, 0x06, 0x1e, 0xaa, 0x47, 0xc3, 0xa8, 0x3f, 0x6f, 0xfd, 0x61, 0x80, + 0x33, 0x19, 0x19, 0xbd, 0x46, 0xb9, 0x80, 0x9f, 0x8e, 0xd4, 0xbb, 0xbd, 0xbf, 0x00, 0xa5, 0xb5, + 0xaa, 0xf6, 0x63, 0x5a, 0x7b, 0xbe, 0x3f, 0x92, 0xa8, 0xf5, 0x16, 0x98, 0xa5, 0x82, 0xb8, 0x72, + 0x7d, 0xf2, 0xe7, 0x8a, 0xab, 0xd5, 0xa7, 0x2f, 0xc0, 0xea, 0x11, 0x2d, 0x37, 0x7b, 0x55, 0x12, + 0xa3, 0x88, 0xdf, 0xfa, 0x3b, 0x97, 0x19, 0xa6, 0xdc, 0x10, 0xf0, 0x6b, 0x03, 0x1c, 0x55, 0x7f, + 0x1b, 0x98, 0xb5, 0x88, 0xec, 0x41, 0x3a, 0xda, 0x69, 0xf6, 0xdf, 0x84, 0x5e, 0x56, 0x3d, 0xa9, + 0xdd, 0x3a, 0x7a, 0x33, 0xa5, 0x82, 0x86, 0x54, 0xe1, 0x0a, 0x28, 0xba, 0xd4, 0x43, 0x24, 0x68, + 0x53, 0x07, 0x47, 0x75, 0x3b, 0x5b, 0x5d, 0x0c, 0x7b, 0x66, 0xb1, 0x3e, 0x18, 0x46, 0x49, 0x0c, + 0x7c, 0x1d, 0x14, 0x5d, 0xfc, 0x45, 0x6c, 0x92, 0x57, 0x26, 0xc7, 0xb5, 0x5e, 0xb1, 0x3e, 0x98, + 0x42, 0x49, 0x1c, 0xbc, 0x03, 0xca, 0x42, 0xc9, 0xd6, 0x36, 0x6e, 0xdd, 0x12, 0xb4, 0x4d, 0xef, + 0x62, 0x59, 0x68, 0x1b, 0x84, 0x39, 0xc4, 0x13, 0xb2, 0x76, 0x0a, 0x8a, 0xc9, 0x0a, 0x7b, 0x66, + 0xb9, 0x31, 0x11, 0x89, 0xf6, 0x60, 0xb2, 0xee, 0xe5, 0xc1, 0xd9, 0x89, 0x1d, 0x03, 0x5e, 0x06, + 0xd0, 0xdf, 0xe2, 0x84, 0x75, 0x49, 0xf3, 0xbd, 0xe8, 0x98, 0x90, 0xfd, 0x5a, 0xae, 0x41, 0xbe, + 0x7a, 0x52, 0x6e, 0x91, 0x1b, 0x23, 0xb3, 0x68, 0x8c, 0x05, 0x74, 0xc0, 0x11, 0xb9, 0x71, 0xa2, + 0x2c, 0x53, 0x7d, 0x34, 0x4c, 0xb7, 0x2b, 0xff, 0x17, 0xf6, 0xcc, 0x23, 0xd7, 0x92, 0x24, 0x28, + 0xcd, 0x09, 0xd7, 0xc1, 0xa2, 0xd3, 0x61, 0x8c, 0x78, 0x62, 0x28, 0xeb, 0xa7, 0x74, 0xd6, 0x17, + 0x6b, 0xe9, 0x69, 0x34, 0x8c, 0x97, 0x14, 0x4d, 0xc2, 0x29, 0x23, 0xcd, 0x98, 0xa2, 0x90, 0xa6, + 0x78, 0x37, 0x3d, 0x8d, 0x86, 0xf1, 0xd0, 0x05, 0xa6, 0x66, 0xcd, 0x5c, 0xc1, 0x59, 0x45, 0xf9, + 0x42, 0xd8, 0x33, 0xcd, 0xda, 0x64, 0x28, 0xda, 0x8b, 0xcb, 0xfa, 0x33, 0x07, 0x40, 0x9d, 0x08, + 0x46, 0x1d, 0xb5, 0x63, 0xd6, 0x52, 0x5d, 0x7a, 0x79, 0xa8, 0x4b, 0x1f, 0xd3, 0x48, 0x75, 0xf5, + 0x49, 0x74, 0x64, 0x0c, 0xe6, 0x7c, 0xb5, 0x33, 0xf4, 0xba, 0xbc, 0x35, 0xc5, 0xf6, 0x8a, 0x4f, + 0xcb, 0x98, 0xb8, 0x0a, 0x64, 0xf3, 0xd3, 0x5b, 0x4d, 0x13, 0xc3, 0x8f, 0x40, 0x21, 0xf0, 0x9b, + 0xfd, 0x33, 0xed, 0xcd, 0x29, 0x04, 0x36, 0xfc, 0x26, 0x4f, 0xd1, 0xcf, 0xcb, 0x88, 0xe4, 0x28, + 0x52, 0x94, 0x90, 0x82, 0xf9, 0xfe, 0x75, 0x4e, 0xad, 0x56, 0x71, 0xf5, 0x9d, 0x29, 0xe8, 0x91, + 0x36, 0x4d, 0x49, 0x2c, 0xc8, 0xce, 0xd8, 0x9f, 0x41, 0x31, 0xbd, 0xf5, 0x57, 0x0e, 0x2c, 0x68, + 0x60, 0xb4, 0x41, 0xfe, 0xe5, 0x7c, 0x47, 0xe7, 0xfa, 0x33, 0xcb, 0x77, 0x44, 0xff, 0x4c, 0xf3, + 0x1d, 0x49, 0x64, 0xe5, 0xfb, 0xfb, 0x1c, 0x80, 0xa3, 0x05, 0x06, 0x3d, 0x30, 0x17, 0xb5, 0xb6, + 0x03, 0x3e, 0x0e, 0xe2, 0x93, 0x5b, 0x77, 0x7e, 0xad, 0x22, 0xaf, 0xab, 0xae, 0xd2, 0xbf, 0x3e, + 0xb8, 0xd6, 0xc6, 0xd7, 0xc5, 0x7a, 0x3c, 0x83, 0x12, 0x28, 0x48, 0x40, 0x31, 0xb2, 0xde, 0xc4, + 0xed, 0x4e, 0xff, 0x1a, 0x32, 0xf1, 0x94, 0xb6, 0xfb, 0x61, 0xdb, 0x1f, 0x74, 0xb0, 0x27, 0xa8, + 0xd8, 0x1d, 0x9c, 0x17, 0x8d, 0x01, 0x15, 0x4a, 0xf2, 0x5a, 0x3f, 0x0e, 0x67, 0x28, 0xaa, 0xcb, + 0xff, 0x42, 0x86, 0xb6, 0xc1, 0x82, 0xee, 0x6e, 0x4f, 0x93, 0xa2, 0x13, 0x5a, 0x65, 0xa1, 0x96, + 0xe0, 0x42, 0x29, 0x66, 0xeb, 0x67, 0x03, 0x1c, 0x1b, 0x6e, 0x23, 0x43, 0x2e, 0x1b, 0xfb, 0x72, + 0xf9, 0x2e, 0x80, 0x51, 0xc0, 0xeb, 0x5d, 0xc2, 0x70, 0x8b, 0x44, 0x8e, 0xe7, 0x9e, 0xc8, 0xf1, + 0xf8, 0x9a, 0xd9, 0x18, 0x61, 0x44, 0x63, 0x54, 0xac, 0x5f, 0xd2, 0x41, 0x44, 0xeb, 0xfc, 0x24, + 0x41, 0x7c, 0x09, 0x8e, 0xeb, 0xec, 0x1c, 0x40, 0x14, 0x67, 0xb4, 0xd8, 0xf1, 0xda, 0x28, 0x25, + 0x1a, 0xa7, 0x63, 0xfd, 0x94, 0x03, 0x27, 0xc6, 0x35, 0x5d, 0x58, 0xd7, 0xcf, 0xc6, 0x28, 0x8a, + 0x4b, 0xc9, 0x67, 0xe3, 0xe3, 0x9e, 0x79, 0x7e, 0xe2, 0x9b, 0xa0, 0x4f, 0x98, 0x78, 0x63, 0x7e, + 0x08, 0x4a, 0xa9, 0x2c, 0x26, 0xce, 0x4f, 0x7d, 0x81, 0xfb, 0x7f, 0xd8, 0x33, 0x4b, 0x8d, 0x0c, + 0x0c, 0xca, 0xb4, 0x96, 0x0f, 0x8d, 0x31, 0x55, 0xf0, 0x64, 0xe5, 0x7b, 0x72, 0x8a, 0x0a, 0xb8, + 0x37, 0x9a, 0xb9, 0xa8, 0x0a, 0x0e, 0x38, 0x73, 0x9f, 0x80, 0xd3, 0xe9, 0x85, 0x1b, 0x4d, 0xdd, + 0xd9, 0xb0, 0x67, 0x9e, 0xae, 0x65, 0x81, 0x50, 0xb6, 0x7d, 0x56, 0xf5, 0xe5, 0x9f, 0x53, 0xf5, + 0xfd, 0x90, 0x03, 0xb3, 0xea, 0xca, 0xf8, 0x1c, 0xbe, 0x19, 0x6c, 0xa6, 0xbe, 0x19, 0xac, 0x4d, + 0xd1, 0x82, 0x95, 0x87, 0x99, 0x5f, 0x08, 0x3e, 0x1b, 0xfa, 0x42, 0x70, 0x71, 0x6a, 0xe6, 0xc9, + 0xdf, 0x03, 0x2e, 0x81, 0xc3, 0xb1, 0x03, 0xf0, 0x82, 0x3c, 0xed, 0xf5, 0x5d, 0xd8, 0x50, 0x6b, + 0x1f, 0x3f, 0x1d, 0xe3, 0x4b, 0x70, 0x8c, 0xb0, 0x28, 0x28, 0x26, 0x14, 0xa6, 0x33, 0x96, 0x68, + 0x4e, 0xda, 0xc4, 0x11, 0x3e, 0xd3, 0x47, 0x48, 0x8c, 0xbe, 0xa9, 0xc7, 0x51, 0x8c, 0xa8, 0x9e, + 0xbb, 0xff, 0xa8, 0x3c, 0xf3, 0xe0, 0x51, 0x79, 0xe6, 0xe1, 0xa3, 0xf2, 0xcc, 0x57, 0x61, 0xd9, + 0xb8, 0x1f, 0x96, 0x8d, 0x07, 0x61, 0xd9, 0x78, 0x18, 0x96, 0x8d, 0xdf, 0xc2, 0xb2, 0xf1, 0xed, + 0xef, 0xe5, 0x99, 0x8f, 0x73, 0xdd, 0x95, 0x7f, 0x02, 0x00, 0x00, 0xff, 0xff, 0x5d, 0x20, 0x64, + 0x54, 0x9f, 0x14, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto index 56d19a9cc9..c2cc6c2ed4 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,20 +19,21 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.autoscaling.v1; +package k8s.io.client_go.pkg.apis.autoscaling.v1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; +import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; // CrossVersionObjectReference contains enough information to let you identify the referred resource. message CrossVersionObjectReference { - // Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + // Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds" optional string kind = 1; // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names @@ -45,11 +46,11 @@ message CrossVersionObjectReference { // configuration of a horizontal pod autoscaler. message HorizontalPodAutoscaler { - // Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // behaviour of autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional optional HorizontalPodAutoscalerSpec spec = 2; @@ -58,11 +59,35 @@ message HorizontalPodAutoscaler { optional HorizontalPodAutoscalerStatus status = 3; } +// HorizontalPodAutoscalerCondition describes the state of +// a HorizontalPodAutoscaler at a certain point. +message HorizontalPodAutoscalerCondition { + // type describes the current condition + optional string type = 1; + + // status is the status of the condition (True, False, Unknown) + optional string status = 2; + + // lastTransitionTime is the last time the condition transitioned from + // one status to another + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 3; + + // reason is the reason for the condition's last transition. + // +optional + optional string reason = 4; + + // message is a human-readable explanation containing details about + // the transition + // +optional + optional string message = 5; +} + // list of horizontal pod autoscaler objects. message HorizontalPodAutoscalerList { // Standard list metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // list of horizontal pod autoscaler objects. repeated HorizontalPodAutoscaler items = 2; @@ -96,7 +121,7 @@ message HorizontalPodAutoscalerStatus { // last time the HorizontalPodAutoscaler scaled the number of pods; // used by the autoscaler to control how often the number of pods is changed. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastScaleTime = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastScaleTime = 2; // current number of replicas of pods managed by this autoscaler. optional int32 currentReplicas = 3; @@ -110,17 +135,166 @@ message HorizontalPodAutoscalerStatus { optional int32 currentCPUUtilizationPercentage = 5; } +// MetricSpec specifies how to scale based on a single metric +// (only `type` and one other matching field should be set at once). +message MetricSpec { + // type is the type of metric source. It should match one of the fields below. + optional string type = 1; + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + optional ObjectMetricSource object = 2; + + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + optional PodsMetricSource pods = 3; + + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + optional ResourceMetricSource resource = 4; +} + +// MetricStatus describes the last-read state of a single metric. +message MetricStatus { + // type is the type of metric source. It will match one of the fields below. + optional string type = 1; + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + optional ObjectMetricStatus object = 2; + + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + optional PodsMetricStatus pods = 3; + + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + optional ResourceMetricStatus resource = 4; +} + +// ObjectMetricSource indicates how to scale on a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +message ObjectMetricSource { + // target is the described Kubernetes object. + optional CrossVersionObjectReference target = 1; + + // metricName is the name of the metric in question. + optional string metricName = 2; + + // targetValue is the target value of the metric (as a quantity). + optional k8s.io.apimachinery.pkg.api.resource.Quantity targetValue = 3; +} + +// ObjectMetricStatus indicates the current value of a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +message ObjectMetricStatus { + // target is the described Kubernetes object. + optional CrossVersionObjectReference target = 1; + + // metricName is the name of the metric in question. + optional string metricName = 2; + + // currentValue is the current value of the metric (as a quantity). + optional k8s.io.apimachinery.pkg.api.resource.Quantity currentValue = 3; +} + +// PodsMetricSource indicates how to scale on a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +// The values will be averaged together before being compared to the target +// value. +message PodsMetricSource { + // metricName is the name of the metric in question + optional string metricName = 1; + + // targetAverageValue is the target value of the average of the + // metric across all relevant pods (as a quantity) + optional k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 2; +} + +// PodsMetricStatus indicates the current value of a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +message PodsMetricStatus { + // metricName is the name of the metric in question + optional string metricName = 1; + + // currentAverageValue is the current value of the average of the + // metric across all relevant pods (as a quantity) + optional k8s.io.apimachinery.pkg.api.resource.Quantity currentAverageValue = 2; +} + +// ResourceMetricSource indicates how to scale on a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). The values will be averaged +// together before being compared to the target. Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. Only one "target" type +// should be set. +message ResourceMetricSource { + // name is the name of the resource in question. + optional string name = 1; + + // targetAverageUtilization is the target value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. + // +optional + optional int32 targetAverageUtilization = 2; + + // targetAverageValue is the target value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // +optional + optional k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3; +} + +// ResourceMetricStatus indicates the current value of a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. +message ResourceMetricStatus { + // name is the name of the resource in question. + optional string name = 1; + + // currentAverageUtilization is the current value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. It will only be + // present if `targetAverageValue` was set in the corresponding metric + // specification. + // +optional + optional int32 currentAverageUtilization = 2; + + // currentAverageValue is the current value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // It will always be set, regardless of the corresponding metric specification. + optional k8s.io.apimachinery.pkg.api.resource.Quantity currentAverageValue = 3; +} + // Scale represents a scaling request for a resource. message Scale { - // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional optional ScaleSpec spec = 2; - // current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only. + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. // +optional optional ScaleStatus status = 3; } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/register.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/register.go index c0f83dedda..20c9db5f77 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/register.go @@ -17,33 +17,44 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "autoscaling" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &HorizontalPodAutoscaler{}, &HorizontalPodAutoscalerList{}, &Scale{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, ) - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.generated.go index 9ffaf6b65d..fc01e4d953 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.generated.go @@ -25,9 +25,10 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" + pkg3_resource "k8s.io/apimachinery/pkg/api/resource" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg4_v1 "k8s.io/client-go/pkg/api/v1" "reflect" "runtime" time "time" @@ -63,11 +64,12 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg1_unversioned.Time - var v1 pkg2_v1.ObjectMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 + var v0 pkg3_resource.Quantity + var v1 pkg1_v1.Time + var v2 pkg2_types.UID + var v3 pkg4_v1.ResourceName + var v4 time.Time + _, _, _, _, _ = v0, v1, v2, v3, v4 } } @@ -178,25 +180,25 @@ func (x *CrossVersionObjectReference) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym12 := z.DecBinary() - _ = yym12 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct13 := r.ContainerType() - if yyct13 == codecSelferValueTypeMap1234 { - yyl13 := r.ReadMapStart() - if yyl13 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl13, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct13 == codecSelferValueTypeArray1234 { - yyl13 := r.ReadArrayStart() - if yyl13 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl13, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -208,12 +210,12 @@ func (x *CrossVersionObjectReference) codecDecodeSelfFromMap(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys14Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys14Slc - var yyhl14 bool = l >= 0 - for yyj14 := 0; ; yyj14++ { - if yyhl14 { - if yyj14 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -222,32 +224,50 @@ func (x *CrossVersionObjectReference) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys14Slc = r.DecodeBytes(yys14Slc, true, true) - yys14 := string(yys14Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys14 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv6 := &x.Name + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv8 := &x.APIVersion + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys14) - } // end switch yys14 - } // end for yyj14 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -255,16 +275,16 @@ func (x *CrossVersionObjectReference) codecDecodeSelfFromArray(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -272,15 +292,21 @@ func (x *CrossVersionObjectReference) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv11 := &x.Kind + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -288,15 +314,21 @@ func (x *CrossVersionObjectReference) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv13 := &x.Name + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -304,20 +336,26 @@ func (x *CrossVersionObjectReference) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj18-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -329,81 +367,81 @@ func (x *HorizontalPodAutoscalerSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym22 := z.EncBinary() - _ = yym22 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep23 := !z.EncBinary() - yy2arr23 := z.EncBasicHandle().StructToArray - var yyq23 [4]bool - _, _, _ = yysep23, yyq23, yy2arr23 - const yyr23 bool = false - yyq23[1] = x.MinReplicas != nil - yyq23[3] = x.TargetCPUUtilizationPercentage != nil - var yynn23 int - if yyr23 || yy2arr23 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.MinReplicas != nil + yyq2[3] = x.TargetCPUUtilizationPercentage != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn23 = 2 - for _, b := range yyq23 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn23++ + yynn2++ } } - r.EncodeMapStart(yynn23) - yynn23 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr23 || yy2arr23 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy25 := &x.ScaleTargetRef - yy25.CodecEncodeSelf(e) + yy4 := &x.ScaleTargetRef + yy4.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("scaleTargetRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy26 := &x.ScaleTargetRef - yy26.CodecEncodeSelf(e) + yy6 := &x.ScaleTargetRef + yy6.CodecEncodeSelf(e) } - if yyr23 || yy2arr23 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq23[1] { + if yyq2[1] { if x.MinReplicas == nil { r.EncodeNil() } else { - yy28 := *x.MinReplicas - yym29 := z.EncBinary() - _ = yym29 + yy9 := *x.MinReplicas + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeInt(int64(yy28)) + r.EncodeInt(int64(yy9)) } } } else { r.EncodeNil() } } else { - if yyq23[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("minReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.MinReplicas == nil { r.EncodeNil() } else { - yy30 := *x.MinReplicas - yym31 := z.EncBinary() - _ = yym31 + yy11 := *x.MinReplicas + yym12 := z.EncBinary() + _ = yym12 if false { } else { - r.EncodeInt(int64(yy30)) + r.EncodeInt(int64(yy11)) } } } } - if yyr23 || yy2arr23 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym33 := z.EncBinary() - _ = yym33 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeInt(int64(x.MaxReplicas)) @@ -412,49 +450,49 @@ func (x *HorizontalPodAutoscalerSpec) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("maxReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym34 := z.EncBinary() - _ = yym34 + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeInt(int64(x.MaxReplicas)) } } - if yyr23 || yy2arr23 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq23[3] { + if yyq2[3] { if x.TargetCPUUtilizationPercentage == nil { r.EncodeNil() } else { - yy36 := *x.TargetCPUUtilizationPercentage - yym37 := z.EncBinary() - _ = yym37 + yy17 := *x.TargetCPUUtilizationPercentage + yym18 := z.EncBinary() + _ = yym18 if false { } else { - r.EncodeInt(int64(yy36)) + r.EncodeInt(int64(yy17)) } } } else { r.EncodeNil() } } else { - if yyq23[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("targetCPUUtilizationPercentage")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.TargetCPUUtilizationPercentage == nil { r.EncodeNil() } else { - yy38 := *x.TargetCPUUtilizationPercentage - yym39 := z.EncBinary() - _ = yym39 + yy19 := *x.TargetCPUUtilizationPercentage + yym20 := z.EncBinary() + _ = yym20 if false { } else { - r.EncodeInt(int64(yy38)) + r.EncodeInt(int64(yy19)) } } } } - if yyr23 || yy2arr23 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -467,25 +505,25 @@ func (x *HorizontalPodAutoscalerSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym40 := z.DecBinary() - _ = yym40 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct41 := r.ContainerType() - if yyct41 == codecSelferValueTypeMap1234 { - yyl41 := r.ReadMapStart() - if yyl41 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl41, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct41 == codecSelferValueTypeArray1234 { - yyl41 := r.ReadArrayStart() - if yyl41 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl41, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -497,12 +535,12 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys42Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys42Slc - var yyhl42 bool = l >= 0 - for yyj42 := 0; ; yyj42++ { - if yyhl42 { - if yyj42 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -511,16 +549,16 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys42Slc = r.DecodeBytes(yys42Slc, true, true) - yys42 := string(yys42Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys42 { + switch yys3 { case "scaleTargetRef": if r.TryDecodeAsNil() { x.ScaleTargetRef = CrossVersionObjectReference{} } else { - yyv43 := &x.ScaleTargetRef - yyv43.CodecDecodeSelf(d) + yyv4 := &x.ScaleTargetRef + yyv4.CodecDecodeSelf(d) } case "minReplicas": if r.TryDecodeAsNil() { @@ -531,8 +569,8 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978 if x.MinReplicas == nil { x.MinReplicas = new(int32) } - yym45 := z.DecBinary() - _ = yym45 + yym6 := z.DecBinary() + _ = yym6 if false { } else { *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) @@ -542,7 +580,13 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978 if r.TryDecodeAsNil() { x.MaxReplicas = 0 } else { - x.MaxReplicas = int32(r.DecodeInt(32)) + yyv7 := &x.MaxReplicas + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } } case "targetCPUUtilizationPercentage": if r.TryDecodeAsNil() { @@ -553,17 +597,17 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978 if x.TargetCPUUtilizationPercentage == nil { x.TargetCPUUtilizationPercentage = new(int32) } - yym48 := z.DecBinary() - _ = yym48 + yym10 := z.DecBinary() + _ = yym10 if false { } else { *((*int32)(x.TargetCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) } } default: - z.DecStructFieldNotFound(-1, yys42) - } // end switch yys42 - } // end for yyj42 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -571,16 +615,16 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj49 int - var yyb49 bool - var yyhl49 bool = l >= 0 - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb49 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb49 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -588,16 +632,16 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.ScaleTargetRef = CrossVersionObjectReference{} } else { - yyv50 := &x.ScaleTargetRef - yyv50.CodecDecodeSelf(d) + yyv12 := &x.ScaleTargetRef + yyv12.CodecDecodeSelf(d) } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb49 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb49 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -610,20 +654,20 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec19 if x.MinReplicas == nil { x.MinReplicas = new(int32) } - yym52 := z.DecBinary() - _ = yym52 + yym14 := z.DecBinary() + _ = yym14 if false { } else { *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) } } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb49 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb49 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -631,15 +675,21 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.MaxReplicas = 0 } else { - x.MaxReplicas = int32(r.DecodeInt(32)) + yyv15 := &x.MaxReplicas + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(yyv15)) = int32(r.DecodeInt(32)) + } } - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb49 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb49 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -652,25 +702,25 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec19 if x.TargetCPUUtilizationPercentage == nil { x.TargetCPUUtilizationPercentage = new(int32) } - yym55 := z.DecBinary() - _ = yym55 + yym18 := z.DecBinary() + _ = yym18 if false { } else { *((*int32)(x.TargetCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) } } for { - yyj49++ - if yyhl49 { - yyb49 = yyj49 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb49 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb49 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj49-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -682,80 +732,80 @@ func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym56 := z.EncBinary() - _ = yym56 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep57 := !z.EncBinary() - yy2arr57 := z.EncBasicHandle().StructToArray - var yyq57 [5]bool - _, _, _ = yysep57, yyq57, yy2arr57 - const yyr57 bool = false - yyq57[0] = x.ObservedGeneration != nil - yyq57[1] = x.LastScaleTime != nil - yyq57[4] = x.CurrentCPUUtilizationPercentage != nil - var yynn57 int - if yyr57 || yy2arr57 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ObservedGeneration != nil + yyq2[1] = x.LastScaleTime != nil + yyq2[4] = x.CurrentCPUUtilizationPercentage != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn57 = 2 - for _, b := range yyq57 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn57++ + yynn2++ } } - r.EncodeMapStart(yynn57) - yynn57 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr57 || yy2arr57 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq57[0] { + if yyq2[0] { if x.ObservedGeneration == nil { r.EncodeNil() } else { - yy59 := *x.ObservedGeneration - yym60 := z.EncBinary() - _ = yym60 + yy4 := *x.ObservedGeneration + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeInt(int64(yy59)) + r.EncodeInt(int64(yy4)) } } } else { r.EncodeNil() } } else { - if yyq57[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ObservedGeneration == nil { r.EncodeNil() } else { - yy61 := *x.ObservedGeneration - yym62 := z.EncBinary() - _ = yym62 + yy6 := *x.ObservedGeneration + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeInt(int64(yy61)) + r.EncodeInt(int64(yy6)) } } } } - if yyr57 || yy2arr57 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq57[1] { + if yyq2[1] { if x.LastScaleTime == nil { r.EncodeNil() } else { - yym64 := z.EncBinary() - _ = yym64 + yym9 := z.EncBinary() + _ = yym9 if false { } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { - } else if yym64 { + } else if yym9 { z.EncBinaryMarshal(x.LastScaleTime) - } else if !yym64 && z.IsJSONHandle() { + } else if !yym9 && z.IsJSONHandle() { z.EncJSONMarshal(x.LastScaleTime) } else { z.EncFallback(x.LastScaleTime) @@ -765,20 +815,20 @@ func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq57[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastScaleTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.LastScaleTime == nil { r.EncodeNil() } else { - yym65 := z.EncBinary() - _ = yym65 + yym10 := z.EncBinary() + _ = yym10 if false { } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { - } else if yym65 { + } else if yym10 { z.EncBinaryMarshal(x.LastScaleTime) - } else if !yym65 && z.IsJSONHandle() { + } else if !yym10 && z.IsJSONHandle() { z.EncJSONMarshal(x.LastScaleTime) } else { z.EncFallback(x.LastScaleTime) @@ -786,10 +836,10 @@ func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr57 || yy2arr57 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym67 := z.EncBinary() - _ = yym67 + yym12 := z.EncBinary() + _ = yym12 if false { } else { r.EncodeInt(int64(x.CurrentReplicas)) @@ -798,17 +848,17 @@ func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("currentReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeInt(int64(x.CurrentReplicas)) } } - if yyr57 || yy2arr57 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym70 := z.EncBinary() - _ = yym70 + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeInt(int64(x.DesiredReplicas)) @@ -817,49 +867,49 @@ func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("desiredReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym71 := z.EncBinary() - _ = yym71 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeInt(int64(x.DesiredReplicas)) } } - if yyr57 || yy2arr57 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq57[4] { + if yyq2[4] { if x.CurrentCPUUtilizationPercentage == nil { r.EncodeNil() } else { - yy73 := *x.CurrentCPUUtilizationPercentage - yym74 := z.EncBinary() - _ = yym74 + yy18 := *x.CurrentCPUUtilizationPercentage + yym19 := z.EncBinary() + _ = yym19 if false { } else { - r.EncodeInt(int64(yy73)) + r.EncodeInt(int64(yy18)) } } } else { r.EncodeNil() } } else { - if yyq57[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("currentCPUUtilizationPercentage")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.CurrentCPUUtilizationPercentage == nil { r.EncodeNil() } else { - yy75 := *x.CurrentCPUUtilizationPercentage - yym76 := z.EncBinary() - _ = yym76 + yy20 := *x.CurrentCPUUtilizationPercentage + yym21 := z.EncBinary() + _ = yym21 if false { } else { - r.EncodeInt(int64(yy75)) + r.EncodeInt(int64(yy20)) } } } } - if yyr57 || yy2arr57 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -872,25 +922,25 @@ func (x *HorizontalPodAutoscalerStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym77 := z.DecBinary() - _ = yym77 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct78 := r.ContainerType() - if yyct78 == codecSelferValueTypeMap1234 { - yyl78 := r.ReadMapStart() - if yyl78 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl78, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct78 == codecSelferValueTypeArray1234 { - yyl78 := r.ReadArrayStart() - if yyl78 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl78, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -902,12 +952,12 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys79Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys79Slc - var yyhl79 bool = l >= 0 - for yyj79 := 0; ; yyj79++ { - if yyhl79 { - if yyj79 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -916,10 +966,10 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys79Slc = r.DecodeBytes(yys79Slc, true, true) - yys79 := string(yys79Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys79 { + switch yys3 { case "observedGeneration": if r.TryDecodeAsNil() { if x.ObservedGeneration != nil { @@ -929,8 +979,8 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 if x.ObservedGeneration == nil { x.ObservedGeneration = new(int64) } - yym81 := z.DecBinary() - _ = yym81 + yym5 := z.DecBinary() + _ = yym5 if false { } else { *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) @@ -943,15 +993,15 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 } } else { if x.LastScaleTime == nil { - x.LastScaleTime = new(pkg1_unversioned.Time) + x.LastScaleTime = new(pkg1_v1.Time) } - yym83 := z.DecBinary() - _ = yym83 + yym7 := z.DecBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { - } else if yym83 { + } else if yym7 { z.DecBinaryUnmarshal(x.LastScaleTime) - } else if !yym83 && z.IsJSONHandle() { + } else if !yym7 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.LastScaleTime) } else { z.DecFallback(x.LastScaleTime, false) @@ -961,13 +1011,25 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 if r.TryDecodeAsNil() { x.CurrentReplicas = 0 } else { - x.CurrentReplicas = int32(r.DecodeInt(32)) + yyv8 := &x.CurrentReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } case "desiredReplicas": if r.TryDecodeAsNil() { x.DesiredReplicas = 0 } else { - x.DesiredReplicas = int32(r.DecodeInt(32)) + yyv10 := &x.DesiredReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } } case "currentCPUUtilizationPercentage": if r.TryDecodeAsNil() { @@ -978,17 +1040,17 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 if x.CurrentCPUUtilizationPercentage == nil { x.CurrentCPUUtilizationPercentage = new(int32) } - yym87 := z.DecBinary() - _ = yym87 + yym13 := z.DecBinary() + _ = yym13 if false { } else { *((*int32)(x.CurrentCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) } } default: - z.DecStructFieldNotFound(-1, yys79) - } // end switch yys79 - } // end for yyj79 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -996,16 +1058,16 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj88 int - var yyb88 bool - var yyhl88 bool = l >= 0 - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb88 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb88 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1018,20 +1080,20 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec if x.ObservedGeneration == nil { x.ObservedGeneration = new(int64) } - yym90 := z.DecBinary() - _ = yym90 + yym16 := z.DecBinary() + _ = yym16 if false { } else { *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb88 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb88 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1042,27 +1104,27 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec } } else { if x.LastScaleTime == nil { - x.LastScaleTime = new(pkg1_unversioned.Time) + x.LastScaleTime = new(pkg1_v1.Time) } - yym92 := z.DecBinary() - _ = yym92 + yym18 := z.DecBinary() + _ = yym18 if false { } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { - } else if yym92 { + } else if yym18 { z.DecBinaryUnmarshal(x.LastScaleTime) - } else if !yym92 && z.IsJSONHandle() { + } else if !yym18 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.LastScaleTime) } else { z.DecFallback(x.LastScaleTime, false) } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb88 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb88 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1070,15 +1132,21 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec if r.TryDecodeAsNil() { x.CurrentReplicas = 0 } else { - x.CurrentReplicas = int32(r.DecodeInt(32)) + yyv19 := &x.CurrentReplicas + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int32)(yyv19)) = int32(r.DecodeInt(32)) + } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb88 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb88 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1086,15 +1154,21 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec if r.TryDecodeAsNil() { x.DesiredReplicas = 0 } else { - x.DesiredReplicas = int32(r.DecodeInt(32)) + yyv21 := &x.DesiredReplicas + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb88 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb88 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1107,25 +1181,25 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec if x.CurrentCPUUtilizationPercentage == nil { x.CurrentCPUUtilizationPercentage = new(int32) } - yym96 := z.DecBinary() - _ = yym96 + yym24 := z.DecBinary() + _ = yym24 if false { } else { *((*int32)(x.CurrentCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) } } for { - yyj88++ - if yyhl88 { - yyb88 = yyj88 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb88 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb88 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj88-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1137,39 +1211,39 @@ func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym97 := z.EncBinary() - _ = yym97 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep98 := !z.EncBinary() - yy2arr98 := z.EncBasicHandle().StructToArray - var yyq98 [5]bool - _, _, _ = yysep98, yyq98, yy2arr98 - const yyr98 bool = false - yyq98[0] = x.Kind != "" - yyq98[1] = x.APIVersion != "" - yyq98[2] = true - yyq98[3] = true - yyq98[4] = true - var yynn98 int - if yyr98 || yy2arr98 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn98 = 0 - for _, b := range yyq98 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn98++ + yynn2++ } } - r.EncodeMapStart(yynn98) - yynn98 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr98 || yy2arr98 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq98[0] { - yym100 := z.EncBinary() - _ = yym100 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1178,23 +1252,23 @@ func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq98[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym101 := z.EncBinary() - _ = yym101 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr98 || yy2arr98 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq98[1] { - yym103 := z.EncBinary() - _ = yym103 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1203,70 +1277,82 @@ func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq98[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym104 := z.EncBinary() - _ = yym104 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr98 || yy2arr98 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq98[2] { - yy106 := &x.ObjectMeta - yy106.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq98[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy107 := &x.ObjectMeta - yy107.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr98 || yy2arr98 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq98[3] { - yy109 := &x.Spec - yy109.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq98[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy110 := &x.Spec - yy110.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr98 || yy2arr98 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq98[4] { - yy112 := &x.Status - yy112.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq98[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy113 := &x.Status - yy113.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr98 || yy2arr98 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1279,25 +1365,25 @@ func (x *HorizontalPodAutoscaler) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym114 := z.DecBinary() - _ = yym114 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct115 := r.ContainerType() - if yyct115 == codecSelferValueTypeMap1234 { - yyl115 := r.ReadMapStart() - if yyl115 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl115, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct115 == codecSelferValueTypeArray1234 { - yyl115 := r.ReadArrayStart() - if yyl115 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl115, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1309,12 +1395,12 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys116Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys116Slc - var yyhl116 bool = l >= 0 - for yyj116 := 0; ; yyj116++ { - if yyhl116 { - if yyj116 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1323,47 +1409,65 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys116Slc = r.DecodeBytes(yys116Slc, true, true) - yys116 := string(yys116Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys116 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv119 := &x.ObjectMeta - yyv119.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = HorizontalPodAutoscalerSpec{} } else { - yyv120 := &x.Spec - yyv120.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = HorizontalPodAutoscalerStatus{} } else { - yyv121 := &x.Status - yyv121.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys116) - } // end switch yys116 - } // end for yyj116 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1371,16 +1475,16 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj122 int - var yyb122 bool - var yyhl122 bool = l >= 0 - yyj122++ - if yyhl122 { - yyb122 = yyj122 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb122 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb122 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1388,15 +1492,21 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj122++ - if yyhl122 { - yyb122 = yyj122 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb122 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb122 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1404,32 +1514,44 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj122++ - if yyhl122 { - yyb122 = yyj122 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb122 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb122 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv125 := &x.ObjectMeta - yyv125.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj122++ - if yyhl122 { - yyb122 = yyj122 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb122 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb122 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1437,16 +1559,16 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Spec = HorizontalPodAutoscalerSpec{} } else { - yyv126 := &x.Spec - yyv126.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj122++ - if yyhl122 { - yyb122 = yyj122 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb122 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb122 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1454,21 +1576,21 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Status = HorizontalPodAutoscalerStatus{} } else { - yyv127 := &x.Status - yyv127.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj122++ - if yyhl122 { - yyb122 = yyj122 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb122 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb122 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj122-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1480,37 +1602,37 @@ func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym128 := z.EncBinary() - _ = yym128 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep129 := !z.EncBinary() - yy2arr129 := z.EncBasicHandle().StructToArray - var yyq129 [4]bool - _, _, _ = yysep129, yyq129, yy2arr129 - const yyr129 bool = false - yyq129[0] = x.Kind != "" - yyq129[1] = x.APIVersion != "" - yyq129[2] = true - var yynn129 int - if yyr129 || yy2arr129 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn129 = 1 - for _, b := range yyq129 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn129++ + yynn2++ } } - r.EncodeMapStart(yynn129) - yynn129 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr129 || yy2arr129 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq129[0] { - yym131 := z.EncBinary() - _ = yym131 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1519,23 +1641,23 @@ func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq129[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym132 := z.EncBinary() - _ = yym132 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr129 || yy2arr129 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq129[1] { - yym134 := z.EncBinary() - _ = yym134 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1544,54 +1666,54 @@ func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq129[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym135 := z.EncBinary() - _ = yym135 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr129 || yy2arr129 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq129[2] { - yy137 := &x.ListMeta - yym138 := z.EncBinary() - _ = yym138 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy137) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy137) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq129[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy139 := &x.ListMeta - yym140 := z.EncBinary() - _ = yym140 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy139) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy139) + z.EncFallback(yy12) } } } - if yyr129 || yy2arr129 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym142 := z.EncBinary() - _ = yym142 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(x.Items), e) @@ -1604,15 +1726,15 @@ func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym143 := z.EncBinary() - _ = yym143 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(x.Items), e) } } } - if yyr129 || yy2arr129 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1625,25 +1747,25 @@ func (x *HorizontalPodAutoscalerList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym144 := z.DecBinary() - _ = yym144 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct145 := r.ContainerType() - if yyct145 == codecSelferValueTypeMap1234 { - yyl145 := r.ReadMapStart() - if yyl145 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl145, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct145 == codecSelferValueTypeArray1234 { - yyl145 := r.ReadArrayStart() - if yyl145 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl145, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1655,12 +1777,12 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromMap(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys146Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys146Slc - var yyhl146 bool = l >= 0 - for yyj146 := 0; ; yyj146++ { - if yyhl146 { - if yyj146 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1669,51 +1791,63 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys146Slc = r.DecodeBytes(yys146Slc, true, true) - yys146 := string(yys146Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys146 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv149 := &x.ListMeta - yym150 := z.DecBinary() - _ = yym150 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv149) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv149, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv151 := &x.Items - yym152 := z.DecBinary() - _ = yym152 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv151), d) + h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys146) - } // end switch yys146 - } // end for yyj146 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1721,16 +1855,16 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec19 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 + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb153 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb153 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1738,15 +1872,21 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb153 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb153 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1754,38 +1894,44 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb153 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb153 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv156 := &x.ListMeta - yym157 := z.DecBinary() - _ = yym157 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv156) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv156, false) + z.DecFallback(yyv17, false) } } - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb153 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb153 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1793,26 +1939,26 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec19 if r.TryDecodeAsNil() { x.Items = nil } else { - yyv158 := &x.Items - yym159 := z.DecBinary() - _ = yym159 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv158), d) + h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv19), d) } } for { - yyj153++ - if yyhl153 { - yyb153 = yyj153 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb153 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb153 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj153-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1824,39 +1970,39 @@ func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym160 := z.EncBinary() - _ = yym160 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep161 := !z.EncBinary() - yy2arr161 := z.EncBasicHandle().StructToArray - var yyq161 [5]bool - _, _, _ = yysep161, yyq161, yy2arr161 - const yyr161 bool = false - yyq161[0] = x.Kind != "" - yyq161[1] = x.APIVersion != "" - yyq161[2] = true - yyq161[3] = true - yyq161[4] = true - var yynn161 int - if yyr161 || yy2arr161 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn161 = 0 - for _, b := range yyq161 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn161++ + yynn2++ } } - r.EncodeMapStart(yynn161) - yynn161 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr161 || yy2arr161 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[0] { - yym163 := z.EncBinary() - _ = yym163 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1865,23 +2011,23 @@ func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq161[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym164 := z.EncBinary() - _ = yym164 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr161 || yy2arr161 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[1] { - yym166 := z.EncBinary() - _ = yym166 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1890,70 +2036,82 @@ func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq161[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym167 := z.EncBinary() - _ = yym167 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr161 || yy2arr161 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[2] { - yy169 := &x.ObjectMeta - yy169.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq161[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy170 := &x.ObjectMeta - yy170.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr161 || yy2arr161 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[3] { - yy172 := &x.Spec - yy172.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq161[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy173 := &x.Spec - yy173.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr161 || yy2arr161 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[4] { - yy175 := &x.Status - yy175.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq161[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy176 := &x.Status - yy176.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr161 || yy2arr161 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1966,25 +2124,25 @@ func (x *Scale) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym177 := z.DecBinary() - _ = yym177 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct178 := r.ContainerType() - if yyct178 == codecSelferValueTypeMap1234 { - yyl178 := r.ReadMapStart() - if yyl178 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl178, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct178 == codecSelferValueTypeArray1234 { - yyl178 := r.ReadArrayStart() - if yyl178 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl178, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1996,12 +2154,12 @@ func (x *Scale) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys179Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys179Slc - var yyhl179 bool = l >= 0 - for yyj179 := 0; ; yyj179++ { - if yyhl179 { - if yyj179 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2010,47 +2168,65 @@ func (x *Scale) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys179Slc = r.DecodeBytes(yys179Slc, true, true) - yys179 := string(yys179Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys179 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv182 := &x.ObjectMeta - yyv182.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = ScaleSpec{} } else { - yyv183 := &x.Spec - yyv183.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = ScaleStatus{} } else { - yyv184 := &x.Status - yyv184.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys179) - } // end switch yys179 - } // end for yyj179 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2058,16 +2234,16 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj185 int - var yyb185 bool - var yyhl185 bool = l >= 0 - yyj185++ - if yyhl185 { - yyb185 = yyj185 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb185 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb185 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2075,15 +2251,21 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj185++ - if yyhl185 { - yyb185 = yyj185 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb185 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb185 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2091,32 +2273,44 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj185++ - if yyhl185 { - yyb185 = yyj185 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb185 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb185 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv188 := &x.ObjectMeta - yyv188.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj185++ - if yyhl185 { - yyb185 = yyj185 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb185 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb185 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2124,16 +2318,16 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = ScaleSpec{} } else { - yyv189 := &x.Spec - yyv189.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj185++ - if yyhl185 { - yyb185 = yyj185 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb185 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb185 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2141,21 +2335,21 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = ScaleStatus{} } else { - yyv190 := &x.Status - yyv190.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj185++ - if yyhl185 { - yyb185 = yyj185 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb185 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb185 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj185-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2167,35 +2361,35 @@ func (x *ScaleSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym191 := z.EncBinary() - _ = yym191 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep192 := !z.EncBinary() - yy2arr192 := z.EncBasicHandle().StructToArray - var yyq192 [1]bool - _, _, _ = yysep192, yyq192, yy2arr192 - const yyr192 bool = false - yyq192[0] = x.Replicas != 0 - var yynn192 int - if yyr192 || yy2arr192 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn192 = 0 - for _, b := range yyq192 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn192++ + yynn2++ } } - r.EncodeMapStart(yynn192) - yynn192 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq192[0] { - yym194 := z.EncBinary() - _ = yym194 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Replicas)) @@ -2204,19 +2398,19 @@ func (x *ScaleSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq192[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym195 := z.EncBinary() - _ = yym195 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Replicas)) } } } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2229,25 +2423,25 @@ func (x *ScaleSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym196 := z.DecBinary() - _ = yym196 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct197 := r.ContainerType() - if yyct197 == codecSelferValueTypeMap1234 { - yyl197 := r.ReadMapStart() - if yyl197 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl197, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct197 == codecSelferValueTypeArray1234 { - yyl197 := r.ReadArrayStart() - if yyl197 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl197, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2259,12 +2453,12 @@ func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys198Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys198Slc - var yyhl198 bool = l >= 0 - for yyj198 := 0; ; yyj198++ { - if yyhl198 { - if yyj198 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2273,20 +2467,26 @@ func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys198Slc = r.DecodeBytes(yys198Slc, true, true) - yys198 := string(yys198Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys198 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys198) - } // end switch yys198 - } // end for yyj198 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2294,16 +2494,16 @@ func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj200 int - var yyb200 bool - var yyhl200 bool = l >= 0 - yyj200++ - if yyhl200 { - yyb200 = yyj200 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb200 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb200 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2311,20 +2511,26 @@ func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv7 := &x.Replicas + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } } for { - yyj200++ - if yyhl200 { - yyb200 = yyj200 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb200 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb200 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj200-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2336,34 +2542,34 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym202 := z.EncBinary() - _ = yym202 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep203 := !z.EncBinary() - yy2arr203 := z.EncBasicHandle().StructToArray - var yyq203 [2]bool - _, _, _ = yysep203, yyq203, yy2arr203 - const yyr203 bool = false - yyq203[1] = x.Selector != "" - var yynn203 int - if yyr203 || yy2arr203 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Selector != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn203 = 1 - for _, b := range yyq203 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn203++ + yynn2++ } } - r.EncodeMapStart(yynn203) - yynn203 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr203 || yy2arr203 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym205 := z.EncBinary() - _ = yym205 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Replicas)) @@ -2372,18 +2578,18 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym206 := z.EncBinary() - _ = yym206 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Replicas)) } } - if yyr203 || yy2arr203 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq203[1] { - yym208 := z.EncBinary() - _ = yym208 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Selector)) @@ -2392,19 +2598,19 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq203[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym209 := z.EncBinary() - _ = yym209 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Selector)) } } } - if yyr203 || yy2arr203 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2417,25 +2623,25 @@ func (x *ScaleStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym210 := z.DecBinary() - _ = yym210 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct211 := r.ContainerType() - if yyct211 == codecSelferValueTypeMap1234 { - yyl211 := r.ReadMapStart() - if yyl211 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl211, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct211 == codecSelferValueTypeArray1234 { - yyl211 := r.ReadArrayStart() - if yyl211 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl211, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2447,12 +2653,12 @@ func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys212Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys212Slc - var yyhl212 bool = l >= 0 - for yyj212 := 0; ; yyj212++ { - if yyhl212 { - if yyj212 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2461,26 +2667,38 @@ func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys212Slc = r.DecodeBytes(yys212Slc, true, true) - yys212 := string(yys212Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys212 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "selector": if r.TryDecodeAsNil() { x.Selector = "" } else { - x.Selector = string(r.DecodeString()) + yyv6 := &x.Selector + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys212) - } // end switch yys212 - } // end for yyj212 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2488,16 +2706,16 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj215 int - var yyb215 bool - var yyhl215 bool = l >= 0 - yyj215++ - if yyhl215 { - yyb215 = yyj215 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb215 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb215 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2505,15 +2723,21 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv9 := &x.Replicas + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*int32)(yyv9)) = int32(r.DecodeInt(32)) + } } - yyj215++ - if yyhl215 { - yyb215 = yyj215 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb215 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb215 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2521,20 +2745,2770 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = "" } else { - x.Selector = string(r.DecodeString()) + yyv11 := &x.Selector + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x MetricSourceType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *MetricSourceType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *MetricSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Object != nil + yyq2[2] = x.Pods != nil + yyq2[3] = x.Resource != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("object")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("pods")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *MetricSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *MetricSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "object": + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricSource) + } + x.Object.CodecDecodeSelf(d) + } + case "pods": + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricSource) + } + x.Pods.CodecDecodeSelf(d) + } + case "resource": + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricSource) + } + x.Resource.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *MetricSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv9 := &x.Type + yyv9.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricSource) + } + x.Object.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricSource) + } + x.Pods.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricSource) + } + x.Resource.CodecDecodeSelf(d) + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ObjectMetricSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Target + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("target")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Target + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.TargetValue + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.TargetValue + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(yy14) { + } else if !yym15 && z.IsJSONHandle() { + z.EncJSONMarshal(yy14) + } else { + z.EncFallback(yy14) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ObjectMetricSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ObjectMetricSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "target": + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv4 := &x.Target + yyv4.CodecDecodeSelf(d) + } + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv5 := &x.MetricName + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "targetValue": + if r.TryDecodeAsNil() { + x.TargetValue = pkg3_resource.Quantity{} + } else { + yyv7 := &x.TargetValue + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) + } else { + z.DecFallback(yyv7, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ObjectMetricSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv10 := &x.Target + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv11 := &x.MetricName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TargetValue = pkg3_resource.Quantity{} + } else { + yyv13 := &x.TargetValue + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PodsMetricSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.TargetAverageValue + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.TargetAverageValue + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PodsMetricSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PodsMetricSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv4 := &x.MetricName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "targetAverageValue": + if r.TryDecodeAsNil() { + x.TargetAverageValue = pkg3_resource.Quantity{} + } else { + yyv6 := &x.TargetAverageValue + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PodsMetricSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv9 := &x.MetricName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TargetAverageValue = pkg3_resource.Quantity{} + } else { + yyv11 := &x.TargetAverageValue + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) + } else { + z.DecFallback(yyv11, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ResourceMetricSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.TargetAverageUtilization != nil + yyq2[2] = x.TargetAverageValue != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf4 := &x.Name + yysf4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf5 := &x.Name + yysf5.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.TargetAverageUtilization == nil { + r.EncodeNil() + } else { + yy7 := *x.TargetAverageUtilization + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(yy7)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetAverageUtilization")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.TargetAverageUtilization == nil { + r.EncodeNil() + } else { + yy9 := *x.TargetAverageUtilization + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(yy9)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.TargetAverageValue == nil { + r.EncodeNil() + } else { + yym12 := z.EncBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.EncExt(x.TargetAverageValue) { + } else if !yym12 && z.IsJSONHandle() { + z.EncJSONMarshal(x.TargetAverageValue) + } else { + z.EncFallback(x.TargetAverageValue) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.TargetAverageValue == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.TargetAverageValue) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(x.TargetAverageValue) + } else { + z.EncFallback(x.TargetAverageValue) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ResourceMetricSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ResourceMetricSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yyv4.CodecDecodeSelf(d) + } + case "targetAverageUtilization": + if r.TryDecodeAsNil() { + if x.TargetAverageUtilization != nil { + x.TargetAverageUtilization = nil + } + } else { + if x.TargetAverageUtilization == nil { + x.TargetAverageUtilization = new(int32) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*int32)(x.TargetAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + case "targetAverageValue": + if r.TryDecodeAsNil() { + if x.TargetAverageValue != nil { + x.TargetAverageValue = nil + } + } else { + if x.TargetAverageValue == nil { + x.TargetAverageValue = new(pkg3_resource.Quantity) + } + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(x.TargetAverageValue) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.TargetAverageValue) + } else { + z.DecFallback(x.TargetAverageValue, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ResourceMetricSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.TargetAverageUtilization != nil { + x.TargetAverageUtilization = nil + } + } else { + if x.TargetAverageUtilization == nil { + x.TargetAverageUtilization = new(int32) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(x.TargetAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.TargetAverageValue != nil { + x.TargetAverageValue = nil + } + } else { + if x.TargetAverageValue == nil { + x.TargetAverageValue = new(pkg3_resource.Quantity) + } + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(x.TargetAverageValue) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.TargetAverageValue) + } else { + z.DecFallback(x.TargetAverageValue, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *MetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Object != nil + yyq2[2] = x.Pods != nil + yyq2[3] = x.Resource != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("object")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("pods")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *MetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *MetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "object": + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricStatus) + } + x.Object.CodecDecodeSelf(d) + } + case "pods": + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricStatus) + } + x.Pods.CodecDecodeSelf(d) + } + case "resource": + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricStatus) + } + x.Resource.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *MetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv9 := &x.Type + yyv9.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricStatus) + } + x.Object.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricStatus) + } + x.Pods.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricStatus) + } + x.Resource.CodecDecodeSelf(d) + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x HorizontalPodAutoscalerConditionType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *HorizontalPodAutoscalerConditionType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *HorizontalPodAutoscalerCondition) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = x.Reason != "" + yyq2[4] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf7 := &x.Status + yysf7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf8 := &x.Status + yysf8.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.LastTransitionTime + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.LastTransitionTime + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("reason")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("message")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HorizontalPodAutoscalerCondition) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *HorizontalPodAutoscalerCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) + } + case "lastTransitionTime": + if r.TryDecodeAsNil() { + x.LastTransitionTime = pkg1_v1.Time{} + } else { + yyv6 := &x.LastTransitionTime + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + case "reason": + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv8 := &x.Reason + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "message": + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv10 := &x.Message + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HorizontalPodAutoscalerCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv13 := &x.Type + yyv13.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv14 := &x.Status + yyv14.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.LastTransitionTime = pkg1_v1.Time{} + } else { + yyv15 := &x.LastTransitionTime + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else if yym16 { + z.DecBinaryUnmarshal(yyv15) + } else if !yym16 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv15) + } else { + z.DecFallback(yyv15, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv17 := &x.Reason + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv19 := &x.Message + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ObjectMetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Target + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("target")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Target + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.CurrentValue + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.CurrentValue + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(yy14) { + } else if !yym15 && z.IsJSONHandle() { + z.EncJSONMarshal(yy14) + } else { + z.EncFallback(yy14) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ObjectMetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ObjectMetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "target": + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv4 := &x.Target + yyv4.CodecDecodeSelf(d) + } + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv5 := &x.MetricName + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "currentValue": + if r.TryDecodeAsNil() { + x.CurrentValue = pkg3_resource.Quantity{} + } else { + yyv7 := &x.CurrentValue + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) + } else { + z.DecFallback(yyv7, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ObjectMetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv10 := &x.Target + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv11 := &x.MetricName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentValue = pkg3_resource.Quantity{} + } else { + yyv13 := &x.CurrentValue + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PodsMetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.CurrentAverageValue + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.CurrentAverageValue + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PodsMetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PodsMetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv4 := &x.MetricName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "currentAverageValue": + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg3_resource.Quantity{} + } else { + yyv6 := &x.CurrentAverageValue + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PodsMetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv9 := &x.MetricName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg3_resource.Quantity{} + } else { + yyv11 := &x.CurrentAverageValue + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) + } else { + z.DecFallback(yyv11, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ResourceMetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.CurrentAverageUtilization != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf4 := &x.Name + yysf4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf5 := &x.Name + yysf5.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.CurrentAverageUtilization == nil { + r.EncodeNil() + } else { + yy7 := *x.CurrentAverageUtilization + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(yy7)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentAverageUtilization")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CurrentAverageUtilization == nil { + r.EncodeNil() + } else { + yy9 := *x.CurrentAverageUtilization + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(yy9)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.CurrentAverageValue + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.CurrentAverageValue + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(yy14) { + } else if !yym15 && z.IsJSONHandle() { + z.EncJSONMarshal(yy14) + } else { + z.EncFallback(yy14) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ResourceMetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ResourceMetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yyv4.CodecDecodeSelf(d) + } + case "currentAverageUtilization": + if r.TryDecodeAsNil() { + if x.CurrentAverageUtilization != nil { + x.CurrentAverageUtilization = nil + } + } else { + if x.CurrentAverageUtilization == nil { + x.CurrentAverageUtilization = new(int32) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*int32)(x.CurrentAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + case "currentAverageValue": + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg3_resource.Quantity{} + } else { + yyv7 := &x.CurrentAverageValue + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) + } else { + z.DecFallback(yyv7, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ResourceMetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.CurrentAverageUtilization != nil { + x.CurrentAverageUtilization = nil + } + } else { + if x.CurrentAverageUtilization == nil { + x.CurrentAverageUtilization = new(int32) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(x.CurrentAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg3_resource.Quantity{} + } else { + yyv13 := &x.CurrentAverageValue + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } } for { - yyj215++ - if yyhl215 { - yyb215 = yyj215 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb215 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb215 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj215-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2544,10 +5518,10 @@ func (x codecSelfer1234) encSliceHorizontalPodAutoscaler(v []HorizontalPodAutosc z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv218 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy219 := &yyv218 - yy219.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2557,83 +5531,86 @@ func (x codecSelfer1234) decSliceHorizontalPodAutoscaler(v *[]HorizontalPodAutos z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv220 := *v - yyh220, yyl220 := z.DecSliceHelperStart() - var yyc220 bool - if yyl220 == 0 { - if yyv220 == nil { - yyv220 = []HorizontalPodAutoscaler{} - yyc220 = true - } else if len(yyv220) != 0 { - yyv220 = yyv220[:0] - yyc220 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HorizontalPodAutoscaler{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl220 > 0 { - var yyrr220, yyrl220 int - var yyrt220 bool - if yyl220 > cap(yyv220) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg220 := len(yyv220) > 0 - yyv2220 := yyv220 - yyrl220, yyrt220 = z.DecInferLen(yyl220, z.DecBasicHandle().MaxInitLen, 360) - if yyrt220 { - if yyrl220 <= cap(yyv220) { - yyv220 = yyv220[:yyrl220] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 368) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv220 = make([]HorizontalPodAutoscaler, yyrl220) + yyv1 = make([]HorizontalPodAutoscaler, yyrl1) } } else { - yyv220 = make([]HorizontalPodAutoscaler, yyrl220) + yyv1 = make([]HorizontalPodAutoscaler, yyrl1) } - yyc220 = true - yyrr220 = len(yyv220) - if yyrg220 { - copy(yyv220, yyv2220) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl220 != len(yyv220) { - yyv220 = yyv220[:yyl220] - yyc220 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj220 := 0 - for ; yyj220 < yyrr220; yyj220++ { - yyh220.ElemContainerState(yyj220) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv220[yyj220] = HorizontalPodAutoscaler{} + yyv1[yyj1] = HorizontalPodAutoscaler{} } else { - yyv221 := &yyv220[yyj220] - yyv221.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt220 { - for ; yyj220 < yyl220; yyj220++ { - yyv220 = append(yyv220, HorizontalPodAutoscaler{}) - yyh220.ElemContainerState(yyj220) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HorizontalPodAutoscaler{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv220[yyj220] = HorizontalPodAutoscaler{} + yyv1[yyj1] = HorizontalPodAutoscaler{} } else { - yyv222 := &yyv220[yyj220] - yyv222.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj220 := 0 - for ; !r.CheckBreak(); yyj220++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj220 >= len(yyv220) { - yyv220 = append(yyv220, HorizontalPodAutoscaler{}) // var yyz220 HorizontalPodAutoscaler - yyc220 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HorizontalPodAutoscaler{}) // var yyz1 HorizontalPodAutoscaler + yyc1 = true } - yyh220.ElemContainerState(yyj220) - if yyj220 < len(yyv220) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv220[yyj220] = HorizontalPodAutoscaler{} + yyv1[yyj1] = HorizontalPodAutoscaler{} } else { - yyv223 := &yyv220[yyj220] - yyv223.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -2641,16 +5618,16 @@ func (x codecSelfer1234) decSliceHorizontalPodAutoscaler(v *[]HorizontalPodAutos } } - if yyj220 < len(yyv220) { - yyv220 = yyv220[:yyj220] - yyc220 = true - } else if yyj220 == 0 && yyv220 == nil { - yyv220 = []HorizontalPodAutoscaler{} - yyc220 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HorizontalPodAutoscaler{} + yyc1 = true } } - yyh220.End() - if yyc220 { - *v = yyv220 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.go index 444124aeaa..4132f52911 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types.go @@ -17,13 +17,14 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) // CrossVersionObjectReference contains enough information to let you identify the referred resource. type CrossVersionObjectReference struct { - // Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds" + // Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds" Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names Name string `json:"name" protobuf:"bytes,2,opt,name=name"` @@ -57,7 +58,7 @@ type HorizontalPodAutoscalerStatus struct { // last time the HorizontalPodAutoscaler scaled the number of pods; // used by the autoscaler to control how often the number of pods is changed. // +optional - LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty" protobuf:"bytes,2,opt,name=lastScaleTime"` + LastScaleTime *metav1.Time `json:"lastScaleTime,omitempty" protobuf:"bytes,2,opt,name=lastScaleTime"` // current number of replicas of pods managed by this autoscaler. CurrentReplicas int32 `json:"currentReplicas" protobuf:"varint,3,opt,name=currentReplicas"` @@ -75,12 +76,12 @@ type HorizontalPodAutoscalerStatus struct { // configuration of a horizontal pod autoscaler. type HorizontalPodAutoscaler struct { - unversioned.TypeMeta `json:",inline"` - // Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + metav1.TypeMeta `json:",inline"` + // Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // behaviour of autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` @@ -91,10 +92,10 @@ type HorizontalPodAutoscaler struct { // list of horizontal pod autoscaler objects. type HorizontalPodAutoscalerList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // list of horizontal pod autoscaler objects. Items []HorizontalPodAutoscaler `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -102,16 +103,16 @@ type HorizontalPodAutoscalerList struct { // Scale represents a scaling request for a resource. type Scale struct { - unversioned.TypeMeta `json:",inline"` - // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional Spec ScaleSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - // current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only. + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. // +optional Status ScaleStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } @@ -135,3 +136,197 @@ type ScaleStatus struct { // +optional Selector string `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` } + +// the types below are used in the alpha metrics annotation + +// MetricSourceType indicates the type of metric. +type MetricSourceType string + +var ( + // ObjectMetricSourceType is a metric describing a kubernetes object + // (for example, hits-per-second on an Ingress object). + ObjectMetricSourceType MetricSourceType = "Object" + // PodsMetricSourceType is a metric describing each pod in the current scale + // target (for example, transactions-processed-per-second). The values + // will be averaged together before being compared to the target value. + PodsMetricSourceType MetricSourceType = "Pods" + // ResourceMetricSourceType is a resource metric known to Kubernetes, as + // specified in requests and limits, describing each pod in the current + // scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics (the "pods" source). + ResourceMetricSourceType MetricSourceType = "Resource" +) + +// MetricSpec specifies how to scale based on a single metric +// (only `type` and one other matching field should be set at once). +type MetricSpec struct { + // type is the type of metric source. It should match one of the fields below. + Type MetricSourceType `json:"type" protobuf:"bytes,1,name=type"` + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + Object *ObjectMetricSource `json:"object,omitempty" protobuf:"bytes,2,opt,name=object"` + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + Pods *PodsMetricSource `json:"pods,omitempty" protobuf:"bytes,3,opt,name=pods"` + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + Resource *ResourceMetricSource `json:"resource,omitempty" protobuf:"bytes,4,opt,name=resource"` +} + +// ObjectMetricSource indicates how to scale on a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +type ObjectMetricSource struct { + // target is the described Kubernetes object. + Target CrossVersionObjectReference `json:"target" protobuf:"bytes,1,name=target"` + + // metricName is the name of the metric in question. + MetricName string `json:"metricName" protobuf:"bytes,2,name=metricName"` + // targetValue is the target value of the metric (as a quantity). + TargetValue resource.Quantity `json:"targetValue" protobuf:"bytes,3,name=targetValue"` +} + +// PodsMetricSource indicates how to scale on a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +// The values will be averaged together before being compared to the target +// value. +type PodsMetricSource struct { + // metricName is the name of the metric in question + MetricName string `json:"metricName" protobuf:"bytes,1,name=metricName"` + // targetAverageValue is the target value of the average of the + // metric across all relevant pods (as a quantity) + TargetAverageValue resource.Quantity `json:"targetAverageValue" protobuf:"bytes,2,name=targetAverageValue"` +} + +// ResourceMetricSource indicates how to scale on a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). The values will be averaged +// together before being compared to the target. Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. Only one "target" type +// should be set. +type ResourceMetricSource struct { + // name is the name of the resource in question. + Name v1.ResourceName `json:"name" protobuf:"bytes,1,name=name"` + // targetAverageUtilization is the target value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. + // +optional + TargetAverageUtilization *int32 `json:"targetAverageUtilization,omitempty" protobuf:"varint,2,opt,name=targetAverageUtilization"` + // targetAverageValue is the target value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // +optional + TargetAverageValue *resource.Quantity `json:"targetAverageValue,omitempty" protobuf:"bytes,3,opt,name=targetAverageValue"` +} + +// MetricStatus describes the last-read state of a single metric. +type MetricStatus struct { + // type is the type of metric source. It will match one of the fields below. + Type MetricSourceType `json:"type" protobuf:"bytes,1,name=type"` + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + Object *ObjectMetricStatus `json:"object,omitempty" protobuf:"bytes,2,opt,name=object"` + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + Pods *PodsMetricStatus `json:"pods,omitempty" protobuf:"bytes,3,opt,name=pods"` + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + Resource *ResourceMetricStatus `json:"resource,omitempty" protobuf:"bytes,4,opt,name=resource"` +} + +// HorizontalPodAutoscalerConditionType are the valid conditions of +// a HorizontalPodAutoscaler. +type HorizontalPodAutoscalerConditionType string + +var ( + // ScalingActive indicates that the HPA controller is able to scale if necessary: + // it's correctly configured, can fetch the desired metrics, and isn't disabled. + ScalingActive HorizontalPodAutoscalerConditionType = "ScalingActive" + // AbleToScale indicates a lack of transient issues which prevent scaling from occuring, + // such as being in a backoff window, or being unable to access/update the target scale. + AbleToScale HorizontalPodAutoscalerConditionType = "AbleToScale" + // ScalingLimited indicates that the calculated scale based on metrics would be above or + // below the range for the HPA, and has thus been capped. + ScalingLimited HorizontalPodAutoscalerConditionType = "ScalingLimited" +) + +// HorizontalPodAutoscalerCondition describes the state of +// a HorizontalPodAutoscaler at a certain point. +type HorizontalPodAutoscalerCondition struct { + // type describes the current condition + Type HorizontalPodAutoscalerConditionType `json:"type" protobuf:"bytes,1,name=type"` + // status is the status of the condition (True, False, Unknown) + Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,name=status"` + // lastTransitionTime is the last time the condition transitioned from + // one status to another + // +optional + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,3,opt,name=lastTransitionTime"` + // reason is the reason for the condition's last transition. + // +optional + Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` + // message is a human-readable explanation containing details about + // the transition + // +optional + Message string `json:"message,omitempty" protobuf:"bytes,5,opt,name=message"` +} + +// ObjectMetricStatus indicates the current value of a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +type ObjectMetricStatus struct { + // target is the described Kubernetes object. + Target CrossVersionObjectReference `json:"target" protobuf:"bytes,1,name=target"` + + // metricName is the name of the metric in question. + MetricName string `json:"metricName" protobuf:"bytes,2,name=metricName"` + // currentValue is the current value of the metric (as a quantity). + CurrentValue resource.Quantity `json:"currentValue" protobuf:"bytes,3,name=currentValue"` +} + +// PodsMetricStatus indicates the current value of a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +type PodsMetricStatus struct { + // metricName is the name of the metric in question + MetricName string `json:"metricName" protobuf:"bytes,1,name=metricName"` + // currentAverageValue is the current value of the average of the + // metric across all relevant pods (as a quantity) + CurrentAverageValue resource.Quantity `json:"currentAverageValue" protobuf:"bytes,2,name=currentAverageValue"` +} + +// ResourceMetricStatus indicates the current value of a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. +type ResourceMetricStatus struct { + // name is the name of the resource in question. + Name v1.ResourceName `json:"name" protobuf:"bytes,1,name=name"` + // currentAverageUtilization is the current value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. It will only be + // present if `targetAverageValue` was set in the corresponding metric + // specification. + // +optional + CurrentAverageUtilization *int32 `json:"currentAverageUtilization,omitempty" protobuf:"bytes,2,opt,name=currentAverageUtilization"` + // currentAverageValue is the current value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // It will always be set, regardless of the corresponding metric specification. + CurrentAverageValue resource.Quantity `json:"currentAverageValue" protobuf:"bytes,3,name=currentAverageValue"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types_swagger_doc_generated.go index 91b3f041c2..7f84c2d934 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/types_swagger_doc_generated.go @@ -29,7 +29,7 @@ package v1 // AUTO-GENERATED FUNCTIONS START HERE var map_CrossVersionObjectReference = map[string]string{ "": "CrossVersionObjectReference contains enough information to let you identify the referred resource.", - "kind": "Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds\"", + "kind": "Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds\"", "name": "Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names", "apiVersion": "API version of the referent", } @@ -40,8 +40,8 @@ func (CrossVersionObjectReference) SwaggerDoc() map[string]string { var map_HorizontalPodAutoscaler = map[string]string{ "": "configuration of a horizontal pod autoscaler.", - "metadata": "Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.", + "metadata": "Standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "behaviour of autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", "status": "current information about the autoscaler.", } @@ -49,6 +49,19 @@ func (HorizontalPodAutoscaler) SwaggerDoc() map[string]string { return map_HorizontalPodAutoscaler } +var map_HorizontalPodAutoscalerCondition = map[string]string{ + "": "HorizontalPodAutoscalerCondition describes the state of a HorizontalPodAutoscaler at a certain point.", + "type": "type describes the current condition", + "status": "status is the status of the condition (True, False, Unknown)", + "lastTransitionTime": "lastTransitionTime is the last time the condition transitioned from one status to another", + "reason": "reason is the reason for the condition's last transition.", + "message": "message is a human-readable explanation containing details about the transition", +} + +func (HorizontalPodAutoscalerCondition) SwaggerDoc() map[string]string { + return map_HorizontalPodAutoscalerCondition +} + var map_HorizontalPodAutoscalerList = map[string]string{ "": "list of horizontal pod autoscaler objects.", "metadata": "Standard list metadata.", @@ -84,11 +97,99 @@ func (HorizontalPodAutoscalerStatus) SwaggerDoc() map[string]string { return map_HorizontalPodAutoscalerStatus } +var map_MetricSpec = map[string]string{ + "": "MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).", + "type": "type is the type of metric source. It should match one of the fields below.", + "object": "object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).", + "pods": "pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", + "resource": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", +} + +func (MetricSpec) SwaggerDoc() map[string]string { + return map_MetricSpec +} + +var map_MetricStatus = map[string]string{ + "": "MetricStatus describes the last-read state of a single metric.", + "type": "type is the type of metric source. It will match one of the fields below.", + "object": "object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).", + "pods": "pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", + "resource": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", +} + +func (MetricStatus) SwaggerDoc() map[string]string { + return map_MetricStatus +} + +var map_ObjectMetricSource = map[string]string{ + "": "ObjectMetricSource indicates how to scale on a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).", + "target": "target is the described Kubernetes object.", + "metricName": "metricName is the name of the metric in question.", + "targetValue": "targetValue is the target value of the metric (as a quantity).", +} + +func (ObjectMetricSource) SwaggerDoc() map[string]string { + return map_ObjectMetricSource +} + +var map_ObjectMetricStatus = map[string]string{ + "": "ObjectMetricStatus indicates the current value of a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).", + "target": "target is the described Kubernetes object.", + "metricName": "metricName is the name of the metric in question.", + "currentValue": "currentValue is the current value of the metric (as a quantity).", +} + +func (ObjectMetricStatus) SwaggerDoc() map[string]string { + return map_ObjectMetricStatus +} + +var map_PodsMetricSource = map[string]string{ + "": "PodsMetricSource indicates how to scale on a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", + "metricName": "metricName is the name of the metric in question", + "targetAverageValue": "targetAverageValue is the target value of the average of the metric across all relevant pods (as a quantity)", +} + +func (PodsMetricSource) SwaggerDoc() map[string]string { + return map_PodsMetricSource +} + +var map_PodsMetricStatus = map[string]string{ + "": "PodsMetricStatus indicates the current value of a metric describing each pod in the current scale target (for example, transactions-processed-per-second).", + "metricName": "metricName is the name of the metric in question", + "currentAverageValue": "currentAverageValue is the current value of the average of the metric across all relevant pods (as a quantity)", +} + +func (PodsMetricStatus) SwaggerDoc() map[string]string { + return map_PodsMetricStatus +} + +var map_ResourceMetricSource = map[string]string{ + "": "ResourceMetricSource indicates how to scale on a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). The values will be averaged together before being compared to the target. Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source. Only one \"target\" type should be set.", + "name": "name is the name of the resource in question.", + "targetAverageUtilization": "targetAverageUtilization is the target value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods.", + "targetAverageValue": "targetAverageValue is the target value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the \"pods\" metric source type.", +} + +func (ResourceMetricSource) SwaggerDoc() map[string]string { + return map_ResourceMetricSource +} + +var map_ResourceMetricStatus = map[string]string{ + "": "ResourceMetricStatus indicates the current value of a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", + "name": "name is the name of the resource in question.", + "currentAverageUtilization": "currentAverageUtilization is the current value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. It will only be present if `targetAverageValue` was set in the corresponding metric specification.", + "currentAverageValue": "currentAverageValue is the current value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the \"pods\" metric source type. It will always be set, regardless of the corresponding metric specification.", +} + +func (ResourceMetricStatus) SwaggerDoc() map[string]string { + return map_ResourceMetricStatus +} + var map_Scale = map[string]string{ "": "Scale represents a scaling request for a resource.", - "metadata": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", - "spec": "defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.", - "status": "current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.", + "metadata": "Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata.", + "spec": "defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + "status": "current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only.", } func (Scale) SwaggerDoc() map[string]string { diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.conversion.go index 070a291252..12c0648499 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,13 @@ limitations under the License. package v1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" + resource "k8s.io/apimachinery/pkg/api/resource" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + api "k8s.io/client-go/pkg/api" + api_v1 "k8s.io/client-go/pkg/api/v1" autoscaling "k8s.io/client-go/pkg/apis/autoscaling" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -40,12 +43,30 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference, Convert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler, Convert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler, + Convert_v1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition, + Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v1_HorizontalPodAutoscalerCondition, Convert_v1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList, Convert_autoscaling_HorizontalPodAutoscalerList_To_v1_HorizontalPodAutoscalerList, Convert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec, Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec, Convert_v1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus, Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1_HorizontalPodAutoscalerStatus, + Convert_v1_MetricSpec_To_autoscaling_MetricSpec, + Convert_autoscaling_MetricSpec_To_v1_MetricSpec, + Convert_v1_MetricStatus_To_autoscaling_MetricStatus, + Convert_autoscaling_MetricStatus_To_v1_MetricStatus, + Convert_v1_ObjectMetricSource_To_autoscaling_ObjectMetricSource, + Convert_autoscaling_ObjectMetricSource_To_v1_ObjectMetricSource, + Convert_v1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus, + Convert_autoscaling_ObjectMetricStatus_To_v1_ObjectMetricStatus, + Convert_v1_PodsMetricSource_To_autoscaling_PodsMetricSource, + Convert_autoscaling_PodsMetricSource_To_v1_PodsMetricSource, + Convert_v1_PodsMetricStatus_To_autoscaling_PodsMetricStatus, + Convert_autoscaling_PodsMetricStatus_To_v1_PodsMetricStatus, + Convert_v1_ResourceMetricSource_To_autoscaling_ResourceMetricSource, + Convert_autoscaling_ResourceMetricSource_To_v1_ResourceMetricSource, + Convert_v1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus, + Convert_autoscaling_ResourceMetricStatus_To_v1_ResourceMetricStatus, Convert_v1_Scale_To_autoscaling_Scale, Convert_autoscaling_Scale_To_v1_Scale, Convert_v1_ScaleSpec_To_autoscaling_ScaleSpec, @@ -62,6 +83,7 @@ func autoConvert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjec return nil } +// Convert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference is an autogenerated conversion function. func Convert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(in *CrossVersionObjectReference, out *autoscaling.CrossVersionObjectReference, s conversion.Scope) error { return autoConvert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(in, out, s) } @@ -73,15 +95,13 @@ func autoConvert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjec return nil } +// Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference is an autogenerated conversion function. func Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference(in *autoscaling.CrossVersionObjectReference, out *CrossVersionObjectReference, s conversion.Scope) error { return autoConvert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference(in, out, s) } func autoConvert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -91,15 +111,8 @@ func autoConvert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscal return nil } -func Convert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { - return autoConvert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in, out, s) -} - func autoConvert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -109,26 +122,72 @@ func autoConvert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscal return nil } -func Convert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { - return autoConvert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler(in, out, s) +func autoConvert_v1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(in *HorizontalPodAutoscalerCondition, out *autoscaling.HorizontalPodAutoscalerCondition, s conversion.Scope) error { + out.Type = autoscaling.HorizontalPodAutoscalerConditionType(in.Type) + out.Status = autoscaling.ConditionStatus(in.Status) + out.LastTransitionTime = in.LastTransitionTime + out.Reason = in.Reason + out.Message = in.Message + return nil +} + +// Convert_v1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition is an autogenerated conversion function. +func Convert_v1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(in *HorizontalPodAutoscalerCondition, out *autoscaling.HorizontalPodAutoscalerCondition, s conversion.Scope) error { + return autoConvert_v1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(in, out, s) +} + +func autoConvert_autoscaling_HorizontalPodAutoscalerCondition_To_v1_HorizontalPodAutoscalerCondition(in *autoscaling.HorizontalPodAutoscalerCondition, out *HorizontalPodAutoscalerCondition, s conversion.Scope) error { + out.Type = HorizontalPodAutoscalerConditionType(in.Type) + out.Status = api_v1.ConditionStatus(in.Status) + out.LastTransitionTime = in.LastTransitionTime + out.Reason = in.Reason + out.Message = in.Message + return nil +} + +// Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v1_HorizontalPodAutoscalerCondition is an autogenerated conversion function. +func Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v1_HorizontalPodAutoscalerCondition(in *autoscaling.HorizontalPodAutoscalerCondition, out *HorizontalPodAutoscalerCondition, s conversion.Scope) error { + return autoConvert_autoscaling_HorizontalPodAutoscalerCondition_To_v1_HorizontalPodAutoscalerCondition(in, out, s) } func autoConvert_v1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList, out *autoscaling.HorizontalPodAutoscalerList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]autoscaling.HorizontalPodAutoscaler)(unsafe.Pointer(&in.Items)) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]autoscaling.HorizontalPodAutoscaler, len(*in)) + for i := range *in { + if err := Convert_v1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } return nil } +// Convert_v1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList is an autogenerated conversion function. func Convert_v1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList, out *autoscaling.HorizontalPodAutoscalerList, s conversion.Scope) error { return autoConvert_v1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in, out, s) } func autoConvert_autoscaling_HorizontalPodAutoscalerList_To_v1_HorizontalPodAutoscalerList(in *autoscaling.HorizontalPodAutoscalerList, out *HorizontalPodAutoscalerList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]HorizontalPodAutoscaler)(unsafe.Pointer(&in.Items)) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]HorizontalPodAutoscaler, len(*in)) + for i := range *in { + if err := Convert_autoscaling_HorizontalPodAutoscaler_To_v1_HorizontalPodAutoscaler(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = make([]HorizontalPodAutoscaler, 0) + } return nil } +// Convert_autoscaling_HorizontalPodAutoscalerList_To_v1_HorizontalPodAutoscalerList is an autogenerated conversion function. func Convert_autoscaling_HorizontalPodAutoscalerList_To_v1_HorizontalPodAutoscalerList(in *autoscaling.HorizontalPodAutoscalerList, out *HorizontalPodAutoscalerList, s conversion.Scope) error { return autoConvert_autoscaling_HorizontalPodAutoscalerList_To_v1_HorizontalPodAutoscalerList(in, out, s) } @@ -139,59 +198,241 @@ func autoConvert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAuto } out.MinReplicas = (*int32)(unsafe.Pointer(in.MinReplicas)) out.MaxReplicas = in.MaxReplicas - out.TargetCPUUtilizationPercentage = (*int32)(unsafe.Pointer(in.TargetCPUUtilizationPercentage)) + // WARNING: in.TargetCPUUtilizationPercentage requires manual conversion: does not exist in peer-type return nil } -func Convert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in *HorizontalPodAutoscalerSpec, out *autoscaling.HorizontalPodAutoscalerSpec, s conversion.Scope) error { - return autoConvert_v1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in, out, s) -} - func autoConvert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { if err := Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference(&in.ScaleTargetRef, &out.ScaleTargetRef, s); err != nil { return err } out.MinReplicas = (*int32)(unsafe.Pointer(in.MinReplicas)) out.MaxReplicas = in.MaxReplicas - out.TargetCPUUtilizationPercentage = (*int32)(unsafe.Pointer(in.TargetCPUUtilizationPercentage)) + // WARNING: in.Metrics requires manual conversion: does not exist in peer-type return nil } -func Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { - return autoConvert_autoscaling_HorizontalPodAutoscalerSpec_To_v1_HorizontalPodAutoscalerSpec(in, out, s) -} - func autoConvert_v1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) - out.LastScaleTime = (*unversioned.Time)(unsafe.Pointer(in.LastScaleTime)) + out.LastScaleTime = (*meta_v1.Time)(unsafe.Pointer(in.LastScaleTime)) out.CurrentReplicas = in.CurrentReplicas out.DesiredReplicas = in.DesiredReplicas - out.CurrentCPUUtilizationPercentage = (*int32)(unsafe.Pointer(in.CurrentCPUUtilizationPercentage)) + // WARNING: in.CurrentCPUUtilizationPercentage requires manual conversion: does not exist in peer-type return nil } -func Convert_v1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { - return autoConvert_v1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in, out, s) -} - func autoConvert_autoscaling_HorizontalPodAutoscalerStatus_To_v1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) - out.LastScaleTime = (*unversioned.Time)(unsafe.Pointer(in.LastScaleTime)) + out.LastScaleTime = (*meta_v1.Time)(unsafe.Pointer(in.LastScaleTime)) out.CurrentReplicas = in.CurrentReplicas out.DesiredReplicas = in.DesiredReplicas - out.CurrentCPUUtilizationPercentage = (*int32)(unsafe.Pointer(in.CurrentCPUUtilizationPercentage)) + // WARNING: in.CurrentMetrics requires manual conversion: does not exist in peer-type + // WARNING: in.Conditions requires manual conversion: does not exist in peer-type return nil } -func Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { - return autoConvert_autoscaling_HorizontalPodAutoscalerStatus_To_v1_HorizontalPodAutoscalerStatus(in, out, s) +func autoConvert_v1_MetricSpec_To_autoscaling_MetricSpec(in *MetricSpec, out *autoscaling.MetricSpec, s conversion.Scope) error { + out.Type = autoscaling.MetricSourceType(in.Type) + out.Object = (*autoscaling.ObjectMetricSource)(unsafe.Pointer(in.Object)) + out.Pods = (*autoscaling.PodsMetricSource)(unsafe.Pointer(in.Pods)) + out.Resource = (*autoscaling.ResourceMetricSource)(unsafe.Pointer(in.Resource)) + return nil } -func autoConvert_v1_Scale_To_autoscaling_Scale(in *Scale, out *autoscaling.Scale, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { +// Convert_v1_MetricSpec_To_autoscaling_MetricSpec is an autogenerated conversion function. +func Convert_v1_MetricSpec_To_autoscaling_MetricSpec(in *MetricSpec, out *autoscaling.MetricSpec, s conversion.Scope) error { + return autoConvert_v1_MetricSpec_To_autoscaling_MetricSpec(in, out, s) +} + +func autoConvert_autoscaling_MetricSpec_To_v1_MetricSpec(in *autoscaling.MetricSpec, out *MetricSpec, s conversion.Scope) error { + out.Type = MetricSourceType(in.Type) + out.Object = (*ObjectMetricSource)(unsafe.Pointer(in.Object)) + out.Pods = (*PodsMetricSource)(unsafe.Pointer(in.Pods)) + out.Resource = (*ResourceMetricSource)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_autoscaling_MetricSpec_To_v1_MetricSpec is an autogenerated conversion function. +func Convert_autoscaling_MetricSpec_To_v1_MetricSpec(in *autoscaling.MetricSpec, out *MetricSpec, s conversion.Scope) error { + return autoConvert_autoscaling_MetricSpec_To_v1_MetricSpec(in, out, s) +} + +func autoConvert_v1_MetricStatus_To_autoscaling_MetricStatus(in *MetricStatus, out *autoscaling.MetricStatus, s conversion.Scope) error { + out.Type = autoscaling.MetricSourceType(in.Type) + out.Object = (*autoscaling.ObjectMetricStatus)(unsafe.Pointer(in.Object)) + out.Pods = (*autoscaling.PodsMetricStatus)(unsafe.Pointer(in.Pods)) + out.Resource = (*autoscaling.ResourceMetricStatus)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_v1_MetricStatus_To_autoscaling_MetricStatus is an autogenerated conversion function. +func Convert_v1_MetricStatus_To_autoscaling_MetricStatus(in *MetricStatus, out *autoscaling.MetricStatus, s conversion.Scope) error { + return autoConvert_v1_MetricStatus_To_autoscaling_MetricStatus(in, out, s) +} + +func autoConvert_autoscaling_MetricStatus_To_v1_MetricStatus(in *autoscaling.MetricStatus, out *MetricStatus, s conversion.Scope) error { + out.Type = MetricSourceType(in.Type) + out.Object = (*ObjectMetricStatus)(unsafe.Pointer(in.Object)) + out.Pods = (*PodsMetricStatus)(unsafe.Pointer(in.Pods)) + out.Resource = (*ResourceMetricStatus)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_autoscaling_MetricStatus_To_v1_MetricStatus is an autogenerated conversion function. +func Convert_autoscaling_MetricStatus_To_v1_MetricStatus(in *autoscaling.MetricStatus, out *MetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_MetricStatus_To_v1_MetricStatus(in, out, s) +} + +func autoConvert_v1_ObjectMetricSource_To_autoscaling_ObjectMetricSource(in *ObjectMetricSource, out *autoscaling.ObjectMetricSource, s conversion.Scope) error { + if err := Convert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.TargetValue = in.TargetValue + return nil +} + +// Convert_v1_ObjectMetricSource_To_autoscaling_ObjectMetricSource is an autogenerated conversion function. +func Convert_v1_ObjectMetricSource_To_autoscaling_ObjectMetricSource(in *ObjectMetricSource, out *autoscaling.ObjectMetricSource, s conversion.Scope) error { + return autoConvert_v1_ObjectMetricSource_To_autoscaling_ObjectMetricSource(in, out, s) +} + +func autoConvert_autoscaling_ObjectMetricSource_To_v1_ObjectMetricSource(in *autoscaling.ObjectMetricSource, out *ObjectMetricSource, s conversion.Scope) error { + if err := Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.TargetValue = in.TargetValue + return nil +} + +// Convert_autoscaling_ObjectMetricSource_To_v1_ObjectMetricSource is an autogenerated conversion function. +func Convert_autoscaling_ObjectMetricSource_To_v1_ObjectMetricSource(in *autoscaling.ObjectMetricSource, out *ObjectMetricSource, s conversion.Scope) error { + return autoConvert_autoscaling_ObjectMetricSource_To_v1_ObjectMetricSource(in, out, s) +} + +func autoConvert_v1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus(in *ObjectMetricStatus, out *autoscaling.ObjectMetricStatus, s conversion.Scope) error { + if err := Convert_v1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { return err } + out.MetricName = in.MetricName + out.CurrentValue = in.CurrentValue + return nil +} + +// Convert_v1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus is an autogenerated conversion function. +func Convert_v1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus(in *ObjectMetricStatus, out *autoscaling.ObjectMetricStatus, s conversion.Scope) error { + return autoConvert_v1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus(in, out, s) +} + +func autoConvert_autoscaling_ObjectMetricStatus_To_v1_ObjectMetricStatus(in *autoscaling.ObjectMetricStatus, out *ObjectMetricStatus, s conversion.Scope) error { + if err := Convert_autoscaling_CrossVersionObjectReference_To_v1_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.CurrentValue = in.CurrentValue + return nil +} + +// Convert_autoscaling_ObjectMetricStatus_To_v1_ObjectMetricStatus is an autogenerated conversion function. +func Convert_autoscaling_ObjectMetricStatus_To_v1_ObjectMetricStatus(in *autoscaling.ObjectMetricStatus, out *ObjectMetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_ObjectMetricStatus_To_v1_ObjectMetricStatus(in, out, s) +} + +func autoConvert_v1_PodsMetricSource_To_autoscaling_PodsMetricSource(in *PodsMetricSource, out *autoscaling.PodsMetricSource, s conversion.Scope) error { + out.MetricName = in.MetricName + out.TargetAverageValue = in.TargetAverageValue + return nil +} + +// Convert_v1_PodsMetricSource_To_autoscaling_PodsMetricSource is an autogenerated conversion function. +func Convert_v1_PodsMetricSource_To_autoscaling_PodsMetricSource(in *PodsMetricSource, out *autoscaling.PodsMetricSource, s conversion.Scope) error { + return autoConvert_v1_PodsMetricSource_To_autoscaling_PodsMetricSource(in, out, s) +} + +func autoConvert_autoscaling_PodsMetricSource_To_v1_PodsMetricSource(in *autoscaling.PodsMetricSource, out *PodsMetricSource, s conversion.Scope) error { + out.MetricName = in.MetricName + out.TargetAverageValue = in.TargetAverageValue + return nil +} + +// Convert_autoscaling_PodsMetricSource_To_v1_PodsMetricSource is an autogenerated conversion function. +func Convert_autoscaling_PodsMetricSource_To_v1_PodsMetricSource(in *autoscaling.PodsMetricSource, out *PodsMetricSource, s conversion.Scope) error { + return autoConvert_autoscaling_PodsMetricSource_To_v1_PodsMetricSource(in, out, s) +} + +func autoConvert_v1_PodsMetricStatus_To_autoscaling_PodsMetricStatus(in *PodsMetricStatus, out *autoscaling.PodsMetricStatus, s conversion.Scope) error { + out.MetricName = in.MetricName + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_v1_PodsMetricStatus_To_autoscaling_PodsMetricStatus is an autogenerated conversion function. +func Convert_v1_PodsMetricStatus_To_autoscaling_PodsMetricStatus(in *PodsMetricStatus, out *autoscaling.PodsMetricStatus, s conversion.Scope) error { + return autoConvert_v1_PodsMetricStatus_To_autoscaling_PodsMetricStatus(in, out, s) +} + +func autoConvert_autoscaling_PodsMetricStatus_To_v1_PodsMetricStatus(in *autoscaling.PodsMetricStatus, out *PodsMetricStatus, s conversion.Scope) error { + out.MetricName = in.MetricName + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_autoscaling_PodsMetricStatus_To_v1_PodsMetricStatus is an autogenerated conversion function. +func Convert_autoscaling_PodsMetricStatus_To_v1_PodsMetricStatus(in *autoscaling.PodsMetricStatus, out *PodsMetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_PodsMetricStatus_To_v1_PodsMetricStatus(in, out, s) +} + +func autoConvert_v1_ResourceMetricSource_To_autoscaling_ResourceMetricSource(in *ResourceMetricSource, out *autoscaling.ResourceMetricSource, s conversion.Scope) error { + out.Name = api.ResourceName(in.Name) + out.TargetAverageUtilization = (*int32)(unsafe.Pointer(in.TargetAverageUtilization)) + out.TargetAverageValue = (*resource.Quantity)(unsafe.Pointer(in.TargetAverageValue)) + return nil +} + +// Convert_v1_ResourceMetricSource_To_autoscaling_ResourceMetricSource is an autogenerated conversion function. +func Convert_v1_ResourceMetricSource_To_autoscaling_ResourceMetricSource(in *ResourceMetricSource, out *autoscaling.ResourceMetricSource, s conversion.Scope) error { + return autoConvert_v1_ResourceMetricSource_To_autoscaling_ResourceMetricSource(in, out, s) +} + +func autoConvert_autoscaling_ResourceMetricSource_To_v1_ResourceMetricSource(in *autoscaling.ResourceMetricSource, out *ResourceMetricSource, s conversion.Scope) error { + out.Name = api_v1.ResourceName(in.Name) + out.TargetAverageUtilization = (*int32)(unsafe.Pointer(in.TargetAverageUtilization)) + out.TargetAverageValue = (*resource.Quantity)(unsafe.Pointer(in.TargetAverageValue)) + return nil +} + +// Convert_autoscaling_ResourceMetricSource_To_v1_ResourceMetricSource is an autogenerated conversion function. +func Convert_autoscaling_ResourceMetricSource_To_v1_ResourceMetricSource(in *autoscaling.ResourceMetricSource, out *ResourceMetricSource, s conversion.Scope) error { + return autoConvert_autoscaling_ResourceMetricSource_To_v1_ResourceMetricSource(in, out, s) +} + +func autoConvert_v1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus(in *ResourceMetricStatus, out *autoscaling.ResourceMetricStatus, s conversion.Scope) error { + out.Name = api.ResourceName(in.Name) + out.CurrentAverageUtilization = (*int32)(unsafe.Pointer(in.CurrentAverageUtilization)) + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_v1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus is an autogenerated conversion function. +func Convert_v1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus(in *ResourceMetricStatus, out *autoscaling.ResourceMetricStatus, s conversion.Scope) error { + return autoConvert_v1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus(in, out, s) +} + +func autoConvert_autoscaling_ResourceMetricStatus_To_v1_ResourceMetricStatus(in *autoscaling.ResourceMetricStatus, out *ResourceMetricStatus, s conversion.Scope) error { + out.Name = api_v1.ResourceName(in.Name) + out.CurrentAverageUtilization = (*int32)(unsafe.Pointer(in.CurrentAverageUtilization)) + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_autoscaling_ResourceMetricStatus_To_v1_ResourceMetricStatus is an autogenerated conversion function. +func Convert_autoscaling_ResourceMetricStatus_To_v1_ResourceMetricStatus(in *autoscaling.ResourceMetricStatus, out *ResourceMetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_ResourceMetricStatus_To_v1_ResourceMetricStatus(in, out, s) +} + +func autoConvert_v1_Scale_To_autoscaling_Scale(in *Scale, out *autoscaling.Scale, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_ScaleSpec_To_autoscaling_ScaleSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -201,15 +442,13 @@ func autoConvert_v1_Scale_To_autoscaling_Scale(in *Scale, out *autoscaling.Scale return nil } +// Convert_v1_Scale_To_autoscaling_Scale is an autogenerated conversion function. func Convert_v1_Scale_To_autoscaling_Scale(in *Scale, out *autoscaling.Scale, s conversion.Scope) error { return autoConvert_v1_Scale_To_autoscaling_Scale(in, out, s) } func autoConvert_autoscaling_Scale_To_v1_Scale(in *autoscaling.Scale, out *Scale, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_autoscaling_ScaleSpec_To_v1_ScaleSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -219,6 +458,7 @@ func autoConvert_autoscaling_Scale_To_v1_Scale(in *autoscaling.Scale, out *Scale return nil } +// Convert_autoscaling_Scale_To_v1_Scale is an autogenerated conversion function. func Convert_autoscaling_Scale_To_v1_Scale(in *autoscaling.Scale, out *Scale, s conversion.Scope) error { return autoConvert_autoscaling_Scale_To_v1_Scale(in, out, s) } @@ -228,6 +468,7 @@ func autoConvert_v1_ScaleSpec_To_autoscaling_ScaleSpec(in *ScaleSpec, out *autos return nil } +// Convert_v1_ScaleSpec_To_autoscaling_ScaleSpec is an autogenerated conversion function. func Convert_v1_ScaleSpec_To_autoscaling_ScaleSpec(in *ScaleSpec, out *autoscaling.ScaleSpec, s conversion.Scope) error { return autoConvert_v1_ScaleSpec_To_autoscaling_ScaleSpec(in, out, s) } @@ -237,6 +478,7 @@ func autoConvert_autoscaling_ScaleSpec_To_v1_ScaleSpec(in *autoscaling.ScaleSpec return nil } +// Convert_autoscaling_ScaleSpec_To_v1_ScaleSpec is an autogenerated conversion function. func Convert_autoscaling_ScaleSpec_To_v1_ScaleSpec(in *autoscaling.ScaleSpec, out *ScaleSpec, s conversion.Scope) error { return autoConvert_autoscaling_ScaleSpec_To_v1_ScaleSpec(in, out, s) } @@ -247,6 +489,7 @@ func autoConvert_v1_ScaleStatus_To_autoscaling_ScaleStatus(in *ScaleStatus, out return nil } +// Convert_v1_ScaleStatus_To_autoscaling_ScaleStatus is an autogenerated conversion function. func Convert_v1_ScaleStatus_To_autoscaling_ScaleStatus(in *ScaleStatus, out *autoscaling.ScaleStatus, s conversion.Scope) error { return autoConvert_v1_ScaleStatus_To_autoscaling_ScaleStatus(in, out, s) } @@ -257,6 +500,7 @@ func autoConvert_autoscaling_ScaleStatus_To_v1_ScaleStatus(in *autoscaling.Scale return nil } +// Convert_autoscaling_ScaleStatus_To_v1_ScaleStatus is an autogenerated conversion function. func Convert_autoscaling_ScaleStatus_To_v1_ScaleStatus(in *autoscaling.ScaleStatus, out *ScaleStatus, s conversion.Scope) error { return autoConvert_autoscaling_ScaleStatus_To_v1_ScaleStatus(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.deepcopy.go index b4284f3dee..94fdc46d06 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package v1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - api_v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + resource "k8s.io/apimachinery/pkg/api/resource" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -38,33 +38,44 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_CrossVersionObjectReference, InType: reflect.TypeOf(&CrossVersionObjectReference{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HorizontalPodAutoscaler, InType: reflect.TypeOf(&HorizontalPodAutoscaler{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HorizontalPodAutoscalerCondition, InType: reflect.TypeOf(&HorizontalPodAutoscalerCondition{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HorizontalPodAutoscalerList, InType: reflect.TypeOf(&HorizontalPodAutoscalerList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HorizontalPodAutoscalerSpec, InType: reflect.TypeOf(&HorizontalPodAutoscalerSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_HorizontalPodAutoscalerStatus, InType: reflect.TypeOf(&HorizontalPodAutoscalerStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_MetricSpec, InType: reflect.TypeOf(&MetricSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_MetricStatus, InType: reflect.TypeOf(&MetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ObjectMetricSource, InType: reflect.TypeOf(&ObjectMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ObjectMetricStatus, InType: reflect.TypeOf(&ObjectMetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodsMetricSource, InType: reflect.TypeOf(&PodsMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_PodsMetricStatus, InType: reflect.TypeOf(&PodsMetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ResourceMetricSource, InType: reflect.TypeOf(&ResourceMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ResourceMetricStatus, InType: reflect.TypeOf(&ResourceMetricStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_Scale, InType: reflect.TypeOf(&Scale{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ScaleSpec, InType: reflect.TypeOf(&ScaleSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_ScaleStatus, InType: reflect.TypeOf(&ScaleStatus{})}, ) } +// DeepCopy_v1_CrossVersionObjectReference is an autogenerated deepcopy function. func DeepCopy_v1_CrossVersionObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CrossVersionObjectReference) out := out.(*CrossVersionObjectReference) - out.Kind = in.Kind - out.Name = in.Name - out.APIVersion = in.APIVersion + *out = *in return nil } } +// DeepCopy_v1_HorizontalPodAutoscaler is an autogenerated deepcopy function. func DeepCopy_v1_HorizontalPodAutoscaler(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscaler) out := out.(*HorizontalPodAutoscaler) - out.TypeMeta = in.TypeMeta - if err := api_v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -76,12 +87,23 @@ func DeepCopy_v1_HorizontalPodAutoscaler(in interface{}, out interface{}, c *con } } +// DeepCopy_v1_HorizontalPodAutoscalerCondition is an autogenerated deepcopy function. +func DeepCopy_v1_HorizontalPodAutoscalerCondition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscalerCondition) + out := out.(*HorizontalPodAutoscalerCondition) + *out = *in + out.LastTransitionTime = in.LastTransitionTime.DeepCopy() + return nil + } +} + +// DeepCopy_v1_HorizontalPodAutoscalerList is an autogenerated deepcopy function. func DeepCopy_v1_HorizontalPodAutoscalerList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscalerList) out := out.(*HorizontalPodAutoscalerList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]HorizontalPodAutoscaler, len(*in)) @@ -90,97 +112,229 @@ func DeepCopy_v1_HorizontalPodAutoscalerList(in interface{}, out interface{}, c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_HorizontalPodAutoscalerSpec is an autogenerated deepcopy function. func DeepCopy_v1_HorizontalPodAutoscalerSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscalerSpec) out := out.(*HorizontalPodAutoscalerSpec) - out.ScaleTargetRef = in.ScaleTargetRef + *out = *in if in.MinReplicas != nil { in, out := &in.MinReplicas, &out.MinReplicas *out = new(int32) **out = **in - } else { - out.MinReplicas = nil } - out.MaxReplicas = in.MaxReplicas if in.TargetCPUUtilizationPercentage != nil { in, out := &in.TargetCPUUtilizationPercentage, &out.TargetCPUUtilizationPercentage *out = new(int32) **out = **in - } else { - out.TargetCPUUtilizationPercentage = nil } return nil } } +// DeepCopy_v1_HorizontalPodAutoscalerStatus is an autogenerated deepcopy function. func DeepCopy_v1_HorizontalPodAutoscalerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscalerStatus) out := out.(*HorizontalPodAutoscalerStatus) + *out = *in if in.ObservedGeneration != nil { in, out := &in.ObservedGeneration, &out.ObservedGeneration *out = new(int64) **out = **in - } else { - out.ObservedGeneration = nil } if in.LastScaleTime != nil { in, out := &in.LastScaleTime, &out.LastScaleTime - *out = new(unversioned.Time) + *out = new(meta_v1.Time) **out = (*in).DeepCopy() - } else { - out.LastScaleTime = nil } - out.CurrentReplicas = in.CurrentReplicas - out.DesiredReplicas = in.DesiredReplicas if in.CurrentCPUUtilizationPercentage != nil { in, out := &in.CurrentCPUUtilizationPercentage, &out.CurrentCPUUtilizationPercentage *out = new(int32) **out = **in - } else { - out.CurrentCPUUtilizationPercentage = nil } return nil } } +// DeepCopy_v1_MetricSpec is an autogenerated deepcopy function. +func DeepCopy_v1_MetricSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MetricSpec) + out := out.(*MetricSpec) + *out = *in + if in.Object != nil { + in, out := &in.Object, &out.Object + *out = new(ObjectMetricSource) + if err := DeepCopy_v1_ObjectMetricSource(*in, *out, c); err != nil { + return err + } + } + if in.Pods != nil { + in, out := &in.Pods, &out.Pods + *out = new(PodsMetricSource) + if err := DeepCopy_v1_PodsMetricSource(*in, *out, c); err != nil { + return err + } + } + if in.Resource != nil { + in, out := &in.Resource, &out.Resource + *out = new(ResourceMetricSource) + if err := DeepCopy_v1_ResourceMetricSource(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v1_MetricStatus is an autogenerated deepcopy function. +func DeepCopy_v1_MetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MetricStatus) + out := out.(*MetricStatus) + *out = *in + if in.Object != nil { + in, out := &in.Object, &out.Object + *out = new(ObjectMetricStatus) + if err := DeepCopy_v1_ObjectMetricStatus(*in, *out, c); err != nil { + return err + } + } + if in.Pods != nil { + in, out := &in.Pods, &out.Pods + *out = new(PodsMetricStatus) + if err := DeepCopy_v1_PodsMetricStatus(*in, *out, c); err != nil { + return err + } + } + if in.Resource != nil { + in, out := &in.Resource, &out.Resource + *out = new(ResourceMetricStatus) + if err := DeepCopy_v1_ResourceMetricStatus(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v1_ObjectMetricSource is an autogenerated deepcopy function. +func DeepCopy_v1_ObjectMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMetricSource) + out := out.(*ObjectMetricSource) + *out = *in + out.TargetValue = in.TargetValue.DeepCopy() + return nil + } +} + +// DeepCopy_v1_ObjectMetricStatus is an autogenerated deepcopy function. +func DeepCopy_v1_ObjectMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMetricStatus) + out := out.(*ObjectMetricStatus) + *out = *in + out.CurrentValue = in.CurrentValue.DeepCopy() + return nil + } +} + +// DeepCopy_v1_PodsMetricSource is an autogenerated deepcopy function. +func DeepCopy_v1_PodsMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodsMetricSource) + out := out.(*PodsMetricSource) + *out = *in + out.TargetAverageValue = in.TargetAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_v1_PodsMetricStatus is an autogenerated deepcopy function. +func DeepCopy_v1_PodsMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodsMetricStatus) + out := out.(*PodsMetricStatus) + *out = *in + out.CurrentAverageValue = in.CurrentAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_v1_ResourceMetricSource is an autogenerated deepcopy function. +func DeepCopy_v1_ResourceMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceMetricSource) + out := out.(*ResourceMetricSource) + *out = *in + if in.TargetAverageUtilization != nil { + in, out := &in.TargetAverageUtilization, &out.TargetAverageUtilization + *out = new(int32) + **out = **in + } + if in.TargetAverageValue != nil { + in, out := &in.TargetAverageValue, &out.TargetAverageValue + *out = new(resource.Quantity) + **out = (*in).DeepCopy() + } + return nil + } +} + +// DeepCopy_v1_ResourceMetricStatus is an autogenerated deepcopy function. +func DeepCopy_v1_ResourceMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceMetricStatus) + out := out.(*ResourceMetricStatus) + *out = *in + if in.CurrentAverageUtilization != nil { + in, out := &in.CurrentAverageUtilization, &out.CurrentAverageUtilization + *out = new(int32) + **out = **in + } + out.CurrentAverageValue = in.CurrentAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_v1_Scale is an autogenerated deepcopy function. func DeepCopy_v1_Scale(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Scale) out := out.(*Scale) - out.TypeMeta = in.TypeMeta - if err := api_v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } - out.Spec = in.Spec - out.Status = in.Status return nil } } +// DeepCopy_v1_ScaleSpec is an autogenerated deepcopy function. func DeepCopy_v1_ScaleSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleSpec) out := out.(*ScaleSpec) - out.Replicas = in.Replicas + *out = *in return nil } } +// DeepCopy_v1_ScaleStatus is an autogenerated deepcopy function. func DeepCopy_v1_ScaleStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleStatus) out := out.(*ScaleStatus) - out.Replicas = in.Replicas - out.Selector = in.Selector + *out = *in return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.defaults.go index db483be852..af20e98849 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,7 +21,7 @@ limitations under the License. package v1 import ( - runtime "k8s.io/client-go/pkg/runtime" + runtime "k8s.io/apimachinery/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/BUILD b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/BUILD new file mode 100644 index 0000000000..bf8ea847b2 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/BUILD @@ -0,0 +1,38 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/autoscaling:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/defaults.go new file mode 100644 index 0000000000..7533cc4a36 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/defaults.go @@ -0,0 +1,47 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api/v1" + "k8s.io/client-go/pkg/apis/autoscaling" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_HorizontalPodAutoscaler(obj *HorizontalPodAutoscaler) { + if obj.Spec.MinReplicas == nil { + minReplicas := int32(1) + obj.Spec.MinReplicas = &minReplicas + } + + if len(obj.Spec.Metrics) == 0 { + utilizationDefaultVal := int32(autoscaling.DefaultCPUUtilization) + obj.Spec.Metrics = []MetricSpec{ + { + Type: ResourceMetricSourceType, + Resource: &ResourceMetricSource{ + Name: v1.ResourceCPU, + TargetAverageUtilization: &utilizationDefaultVal, + }, + }, + } + } +} diff --git a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/generated_expansion.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/doc.go similarity index 97% rename from vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/generated_expansion.go rename to vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/doc.go index 66e772d65c..a9fe60b1c7 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/certificates/v1alpha1/generated_expansion.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/doc.go @@ -14,4 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v2alpha1 diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go new file mode 100644 index 0000000000..47fb3d5f19 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.pb.go @@ -0,0 +1,3402 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/autoscaling/v2alpha1/generated.proto +// DO NOT EDIT! + +/* + Package v2alpha1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/autoscaling/v2alpha1/generated.proto + + It has these top-level messages: + CrossVersionObjectReference + HorizontalPodAutoscaler + HorizontalPodAutoscalerCondition + HorizontalPodAutoscalerList + HorizontalPodAutoscalerSpec + HorizontalPodAutoscalerStatus + MetricSpec + MetricStatus + ObjectMetricSource + ObjectMetricStatus + PodsMetricSource + PodsMetricStatus + ResourceMetricSource + ResourceMetricStatus +*/ +package v2alpha1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import k8s_io_apimachinery_pkg_api_resource "k8s.io/apimachinery/pkg/api/resource" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *CrossVersionObjectReference) Reset() { *m = CrossVersionObjectReference{} } +func (*CrossVersionObjectReference) ProtoMessage() {} +func (*CrossVersionObjectReference) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{0} +} + +func (m *HorizontalPodAutoscaler) Reset() { *m = HorizontalPodAutoscaler{} } +func (*HorizontalPodAutoscaler) ProtoMessage() {} +func (*HorizontalPodAutoscaler) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *HorizontalPodAutoscalerCondition) Reset() { *m = HorizontalPodAutoscalerCondition{} } +func (*HorizontalPodAutoscalerCondition) ProtoMessage() {} +func (*HorizontalPodAutoscalerCondition) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + +func (m *HorizontalPodAutoscalerList) Reset() { *m = HorizontalPodAutoscalerList{} } +func (*HorizontalPodAutoscalerList) ProtoMessage() {} +func (*HorizontalPodAutoscalerList) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{3} +} + +func (m *HorizontalPodAutoscalerSpec) Reset() { *m = HorizontalPodAutoscalerSpec{} } +func (*HorizontalPodAutoscalerSpec) ProtoMessage() {} +func (*HorizontalPodAutoscalerSpec) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{4} +} + +func (m *HorizontalPodAutoscalerStatus) Reset() { *m = HorizontalPodAutoscalerStatus{} } +func (*HorizontalPodAutoscalerStatus) ProtoMessage() {} +func (*HorizontalPodAutoscalerStatus) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{5} +} + +func (m *MetricSpec) Reset() { *m = MetricSpec{} } +func (*MetricSpec) ProtoMessage() {} +func (*MetricSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } + +func (m *MetricStatus) Reset() { *m = MetricStatus{} } +func (*MetricStatus) ProtoMessage() {} +func (*MetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *ObjectMetricSource) Reset() { *m = ObjectMetricSource{} } +func (*ObjectMetricSource) ProtoMessage() {} +func (*ObjectMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *ObjectMetricStatus) Reset() { *m = ObjectMetricStatus{} } +func (*ObjectMetricStatus) ProtoMessage() {} +func (*ObjectMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func (m *PodsMetricSource) Reset() { *m = PodsMetricSource{} } +func (*PodsMetricSource) ProtoMessage() {} +func (*PodsMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } + +func (m *PodsMetricStatus) Reset() { *m = PodsMetricStatus{} } +func (*PodsMetricStatus) ProtoMessage() {} +func (*PodsMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } + +func (m *ResourceMetricSource) Reset() { *m = ResourceMetricSource{} } +func (*ResourceMetricSource) ProtoMessage() {} +func (*ResourceMetricSource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } + +func (m *ResourceMetricStatus) Reset() { *m = ResourceMetricStatus{} } +func (*ResourceMetricStatus) ProtoMessage() {} +func (*ResourceMetricStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{13} } + +func init() { + proto.RegisterType((*CrossVersionObjectReference)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.CrossVersionObjectReference") + proto.RegisterType((*HorizontalPodAutoscaler)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.HorizontalPodAutoscaler") + proto.RegisterType((*HorizontalPodAutoscalerCondition)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.HorizontalPodAutoscalerCondition") + proto.RegisterType((*HorizontalPodAutoscalerList)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.HorizontalPodAutoscalerList") + proto.RegisterType((*HorizontalPodAutoscalerSpec)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.HorizontalPodAutoscalerSpec") + proto.RegisterType((*HorizontalPodAutoscalerStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.HorizontalPodAutoscalerStatus") + proto.RegisterType((*MetricSpec)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.MetricSpec") + proto.RegisterType((*MetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.MetricStatus") + proto.RegisterType((*ObjectMetricSource)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.ObjectMetricSource") + proto.RegisterType((*ObjectMetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.ObjectMetricStatus") + proto.RegisterType((*PodsMetricSource)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.PodsMetricSource") + proto.RegisterType((*PodsMetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.PodsMetricStatus") + proto.RegisterType((*ResourceMetricSource)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.ResourceMetricSource") + proto.RegisterType((*ResourceMetricStatus)(nil), "k8s.io.client-go.pkg.apis.autoscaling.v2alpha1.ResourceMetricStatus") +} +func (m *CrossVersionObjectReference) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *CrossVersionObjectReference) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + return i, nil +} + +func (m *HorizontalPodAutoscaler) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HorizontalPodAutoscaler) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + return i, nil +} + +func (m *HorizontalPodAutoscalerCondition) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HorizontalPodAutoscalerCondition) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n4, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + return i, nil +} + +func (m *HorizontalPodAutoscalerList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HorizontalPodAutoscalerList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n5, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *HorizontalPodAutoscalerSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HorizontalPodAutoscalerSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ScaleTargetRef.Size())) + n6, err := m.ScaleTargetRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + if m.MinReplicas != nil { + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.MinReplicas)) + } + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxReplicas)) + if len(m.Metrics) > 0 { + for _, msg := range m.Metrics { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *HorizontalPodAutoscalerStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HorizontalPodAutoscalerStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.ObservedGeneration != nil { + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.ObservedGeneration)) + } + if m.LastScaleTime != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.LastScaleTime.Size())) + n7, err := m.LastScaleTime.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + } + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentReplicas)) + dAtA[i] = 0x20 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.DesiredReplicas)) + if len(m.CurrentMetrics) > 0 { + for _, msg := range m.CurrentMetrics { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.Conditions) > 0 { + for _, msg := range m.Conditions { + dAtA[i] = 0x32 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *MetricSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MetricSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.Object != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size())) + n8, err := m.Object.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 + } + if m.Pods != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Pods.Size())) + n9, err := m.Pods.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + } + if m.Resource != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Resource.Size())) + n10, err := m.Resource.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + } + return i, nil +} + +func (m *MetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *MetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.Object != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Object.Size())) + n11, err := m.Object.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n11 + } + if m.Pods != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Pods.Size())) + n12, err := m.Pods.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n12 + } + if m.Resource != nil { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Resource.Size())) + n13, err := m.Resource.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n13 + } + return i, nil +} + +func (m *ObjectMetricSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ObjectMetricSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size())) + n14, err := m.Target.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n14 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetValue.Size())) + n15, err := m.TargetValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n15 + return i, nil +} + +func (m *ObjectMetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ObjectMetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Target.Size())) + n16, err := m.Target.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n16 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentValue.Size())) + n17, err := m.CurrentValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n17 + return i, nil +} + +func (m *PodsMetricSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodsMetricSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetAverageValue.Size())) + n18, err := m.TargetAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n18 + return i, nil +} + +func (m *PodsMetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodsMetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.MetricName))) + i += copy(dAtA[i:], m.MetricName) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentAverageValue.Size())) + n19, err := m.CurrentAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n19 + return i, nil +} + +func (m *ResourceMetricSource) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ResourceMetricSource) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if m.TargetAverageUtilization != nil { + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.TargetAverageUtilization)) + } + if m.TargetAverageValue != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetAverageValue.Size())) + n20, err := m.TargetAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n20 + } + return i, nil +} + +func (m *ResourceMetricStatus) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ResourceMetricStatus) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + if m.CurrentAverageUtilization != nil { + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.CurrentAverageUtilization)) + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentAverageValue.Size())) + n21, err := m.CurrentAverageValue.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n21 + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *CrossVersionObjectReference) Size() (n int) { + var l int + _ = l + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.APIVersion) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *HorizontalPodAutoscaler) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Status.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *HorizontalPodAutoscalerCondition) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Status) + n += 1 + l + sovGenerated(uint64(l)) + l = m.LastTransitionTime.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Reason) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Message) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *HorizontalPodAutoscalerList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *HorizontalPodAutoscalerSpec) Size() (n int) { + var l int + _ = l + l = m.ScaleTargetRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + if m.MinReplicas != nil { + n += 1 + sovGenerated(uint64(*m.MinReplicas)) + } + n += 1 + sovGenerated(uint64(m.MaxReplicas)) + if len(m.Metrics) > 0 { + for _, e := range m.Metrics { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *HorizontalPodAutoscalerStatus) Size() (n int) { + var l int + _ = l + if m.ObservedGeneration != nil { + n += 1 + sovGenerated(uint64(*m.ObservedGeneration)) + } + if m.LastScaleTime != nil { + l = m.LastScaleTime.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + n += 1 + sovGenerated(uint64(m.CurrentReplicas)) + n += 1 + sovGenerated(uint64(m.DesiredReplicas)) + if len(m.CurrentMetrics) > 0 { + for _, e := range m.CurrentMetrics { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Conditions) > 0 { + for _, e := range m.Conditions { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *MetricSpec) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + if m.Object != nil { + l = m.Object.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Pods != nil { + l = m.Pods.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Resource != nil { + l = m.Resource.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *MetricStatus) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + if m.Object != nil { + l = m.Object.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Pods != nil { + l = m.Pods.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Resource != nil { + l = m.Resource.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ObjectMetricSource) Size() (n int) { + var l int + _ = l + l = m.Target.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.TargetValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ObjectMetricStatus) Size() (n int) { + var l int + _ = l + l = m.Target.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.CurrentValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *PodsMetricSource) Size() (n int) { + var l int + _ = l + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.TargetAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *PodsMetricStatus) Size() (n int) { + var l int + _ = l + l = len(m.MetricName) + n += 1 + l + sovGenerated(uint64(l)) + l = m.CurrentAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ResourceMetricSource) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if m.TargetAverageUtilization != nil { + n += 1 + sovGenerated(uint64(*m.TargetAverageUtilization)) + } + if m.TargetAverageValue != nil { + l = m.TargetAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *ResourceMetricStatus) Size() (n int) { + var l int + _ = l + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + if m.CurrentAverageUtilization != nil { + n += 1 + sovGenerated(uint64(*m.CurrentAverageUtilization)) + } + l = m.CurrentAverageValue.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *CrossVersionObjectReference) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&CrossVersionObjectReference{`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`, + `}`, + }, "") + return s +} +func (this *HorizontalPodAutoscaler) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HorizontalPodAutoscaler{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "HorizontalPodAutoscalerSpec", "HorizontalPodAutoscalerSpec", 1), `&`, ``, 1) + `,`, + `Status:` + strings.Replace(strings.Replace(this.Status.String(), "HorizontalPodAutoscalerStatus", "HorizontalPodAutoscalerStatus", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *HorizontalPodAutoscalerCondition) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HorizontalPodAutoscalerCondition{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Status:` + fmt.Sprintf("%v", this.Status) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, + `Message:` + fmt.Sprintf("%v", this.Message) + `,`, + `}`, + }, "") + return s +} +func (this *HorizontalPodAutoscalerList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HorizontalPodAutoscalerList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "HorizontalPodAutoscaler", "HorizontalPodAutoscaler", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *HorizontalPodAutoscalerSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HorizontalPodAutoscalerSpec{`, + `ScaleTargetRef:` + strings.Replace(strings.Replace(this.ScaleTargetRef.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`, + `MinReplicas:` + valueToStringGenerated(this.MinReplicas) + `,`, + `MaxReplicas:` + fmt.Sprintf("%v", this.MaxReplicas) + `,`, + `Metrics:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Metrics), "MetricSpec", "MetricSpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *HorizontalPodAutoscalerStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&HorizontalPodAutoscalerStatus{`, + `ObservedGeneration:` + valueToStringGenerated(this.ObservedGeneration) + `,`, + `LastScaleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScaleTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, + `CurrentReplicas:` + fmt.Sprintf("%v", this.CurrentReplicas) + `,`, + `DesiredReplicas:` + fmt.Sprintf("%v", this.DesiredReplicas) + `,`, + `CurrentMetrics:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.CurrentMetrics), "MetricStatus", "MetricStatus", 1), `&`, ``, 1) + `,`, + `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "HorizontalPodAutoscalerCondition", "HorizontalPodAutoscalerCondition", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *MetricSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&MetricSpec{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Object:` + strings.Replace(fmt.Sprintf("%v", this.Object), "ObjectMetricSource", "ObjectMetricSource", 1) + `,`, + `Pods:` + strings.Replace(fmt.Sprintf("%v", this.Pods), "PodsMetricSource", "PodsMetricSource", 1) + `,`, + `Resource:` + strings.Replace(fmt.Sprintf("%v", this.Resource), "ResourceMetricSource", "ResourceMetricSource", 1) + `,`, + `}`, + }, "") + return s +} +func (this *MetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&MetricStatus{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `Object:` + strings.Replace(fmt.Sprintf("%v", this.Object), "ObjectMetricStatus", "ObjectMetricStatus", 1) + `,`, + `Pods:` + strings.Replace(fmt.Sprintf("%v", this.Pods), "PodsMetricStatus", "PodsMetricStatus", 1) + `,`, + `Resource:` + strings.Replace(fmt.Sprintf("%v", this.Resource), "ResourceMetricStatus", "ResourceMetricStatus", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ObjectMetricSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ObjectMetricSource{`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `TargetValue:` + strings.Replace(strings.Replace(this.TargetValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ObjectMetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ObjectMetricStatus{`, + `Target:` + strings.Replace(strings.Replace(this.Target.String(), "CrossVersionObjectReference", "CrossVersionObjectReference", 1), `&`, ``, 1) + `,`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `CurrentValue:` + strings.Replace(strings.Replace(this.CurrentValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PodsMetricSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodsMetricSource{`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `TargetAverageValue:` + strings.Replace(strings.Replace(this.TargetAverageValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PodsMetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodsMetricStatus{`, + `MetricName:` + fmt.Sprintf("%v", this.MetricName) + `,`, + `CurrentAverageValue:` + strings.Replace(strings.Replace(this.CurrentAverageValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ResourceMetricSource) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ResourceMetricSource{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `TargetAverageUtilization:` + valueToStringGenerated(this.TargetAverageUtilization) + `,`, + `TargetAverageValue:` + strings.Replace(fmt.Sprintf("%v", this.TargetAverageValue), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1) + `,`, + `}`, + }, "") + return s +} +func (this *ResourceMetricStatus) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ResourceMetricStatus{`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `CurrentAverageUtilization:` + valueToStringGenerated(this.CurrentAverageUtilization) + `,`, + `CurrentAverageValue:` + strings.Replace(strings.Replace(this.CurrentAverageValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *CrossVersionObjectReference) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: CrossVersionObjectReference: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: CrossVersionObjectReference: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIVersion = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscaler) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscaler: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscaler: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerCondition: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerCondition: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = HorizontalPodAutoscalerConditionType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Reason = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Message = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, HorizontalPodAutoscaler{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ScaleTargetRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ScaleTargetRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MinReplicas", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.MinReplicas = &v + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MaxReplicas", wireType) + } + m.MaxReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.MaxReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Metrics", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Metrics = append(m.Metrics, MetricSpec{}) + if err := m.Metrics[len(m.Metrics)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HorizontalPodAutoscalerStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.ObservedGeneration = &v + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field LastScaleTime", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.LastScaleTime == nil { + m.LastScaleTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} + } + if err := m.LastScaleTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentReplicas", wireType) + } + m.CurrentReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.CurrentReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field DesiredReplicas", wireType) + } + m.DesiredReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.DesiredReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentMetrics", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.CurrentMetrics = append(m.CurrentMetrics, MetricStatus{}) + if err := m.CurrentMetrics[len(m.CurrentMetrics)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Conditions = append(m.Conditions, HorizontalPodAutoscalerCondition{}) + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MetricSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MetricSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MetricSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = MetricSourceType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Object == nil { + m.Object = &ObjectMetricSource{} + } + if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pods", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Pods == nil { + m.Pods = &PodsMetricSource{} + } + if err := m.Pods.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Resource == nil { + m.Resource = &ResourceMetricSource{} + } + if err := m.Resource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *MetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: MetricStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: MetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Type = MetricSourceType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Object == nil { + m.Object = &ObjectMetricStatus{} + } + if err := m.Object.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Pods", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Pods == nil { + m.Pods = &PodsMetricStatus{} + } + if err := m.Pods.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resource", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Resource == nil { + m.Resource = &ResourceMetricStatus{} + } + if err := m.Resource.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ObjectMetricSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ObjectMetricSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ObjectMetricSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MetricName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetValue", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.TargetValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ObjectMetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ObjectMetricStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ObjectMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Target", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Target.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MetricName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentValue", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.CurrentValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodsMetricSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodsMetricSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodsMetricSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MetricName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetAverageValue", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.TargetAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodsMetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodsMetricStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodsMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MetricName", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MetricName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentAverageValue", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.CurrentAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ResourceMetricSource) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ResourceMetricSource: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ResourceMetricSource: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = k8s_io_kubernetes_pkg_api_v1.ResourceName(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetAverageUtilization", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.TargetAverageUtilization = &v + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TargetAverageValue", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.TargetAverageValue == nil { + m.TargetAverageValue = &k8s_io_apimachinery_pkg_api_resource.Quantity{} + } + if err := m.TargetAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ResourceMetricStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ResourceMetricStatus: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ResourceMetricStatus: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = k8s_io_kubernetes_pkg_api_v1.ResourceName(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentAverageUtilization", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.CurrentAverageUtilization = &v + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field CurrentAverageValue", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.CurrentAverageValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 1331 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x57, 0x5b, 0x6f, 0x1b, 0x45, + 0x1b, 0xce, 0x3a, 0x4e, 0x9a, 0x6f, 0x9c, 0x26, 0xfd, 0xa6, 0x55, 0xeb, 0xa6, 0xd4, 0x8e, 0x56, + 0x08, 0xb5, 0x08, 0x76, 0xa9, 0x29, 0x88, 0x0a, 0x01, 0x8a, 0xcd, 0xa1, 0x15, 0x71, 0x0f, 0xd3, + 0x50, 0x21, 0x40, 0x82, 0xc9, 0x7a, 0xea, 0x0c, 0xf1, 0x1e, 0xb4, 0x33, 0xb6, 0x48, 0xa5, 0x4a, + 0xdc, 0x70, 0x87, 0x04, 0x37, 0xfc, 0x04, 0x24, 0xfe, 0x01, 0xd7, 0x20, 0x21, 0xf5, 0xb2, 0x97, + 0xe5, 0xc6, 0xa2, 0xee, 0x1d, 0x3f, 0x21, 0x12, 0x07, 0xcd, 0x61, 0x4f, 0x5e, 0x6f, 0x1a, 0x87, + 0xb4, 0x82, 0x3b, 0x7b, 0xe6, 0x7d, 0x9f, 0xe7, 0x3d, 0x3c, 0xf3, 0xce, 0x2c, 0x78, 0x6b, 0xfb, + 0x35, 0x66, 0x51, 0xdf, 0xde, 0xee, 0x6f, 0x92, 0xd0, 0x23, 0x9c, 0x30, 0x3b, 0xd8, 0xee, 0xda, + 0x38, 0xa0, 0xcc, 0xc6, 0x7d, 0xee, 0x33, 0x07, 0xf7, 0xa8, 0xd7, 0xb5, 0x07, 0x0d, 0xdc, 0x0b, + 0xb6, 0xf0, 0x05, 0xbb, 0x4b, 0x3c, 0x12, 0x62, 0x4e, 0x3a, 0x56, 0x10, 0xfa, 0xdc, 0x87, 0xb6, + 0x02, 0xb0, 0x12, 0x00, 0x2b, 0xd8, 0xee, 0x5a, 0x02, 0xc0, 0x4a, 0x01, 0x58, 0x11, 0xc0, 0xca, + 0x8b, 0x5d, 0xca, 0xb7, 0xfa, 0x9b, 0x96, 0xe3, 0xbb, 0x76, 0xd7, 0xef, 0xfa, 0xb6, 0xc4, 0xd9, + 0xec, 0xdf, 0x96, 0xff, 0xe4, 0x1f, 0xf9, 0x4b, 0xe1, 0xaf, 0x5c, 0xd4, 0x01, 0xe2, 0x80, 0xba, + 0xd8, 0xd9, 0xa2, 0x1e, 0x09, 0x77, 0xa2, 0x10, 0xed, 0x90, 0x30, 0xbf, 0x1f, 0x3a, 0x64, 0x3c, + 0xaa, 0x3d, 0xbd, 0x98, 0xed, 0x12, 0x8e, 0xed, 0x41, 0x2e, 0x97, 0x15, 0xbb, 0xc8, 0x2b, 0xec, + 0x7b, 0x9c, 0xba, 0x79, 0x9a, 0x57, 0x1f, 0xe7, 0xc0, 0x9c, 0x2d, 0xe2, 0xe2, 0x9c, 0xdf, 0xcb, + 0x45, 0x7e, 0x7d, 0x4e, 0x7b, 0x36, 0xf5, 0x38, 0xe3, 0x61, 0xce, 0xe9, 0x85, 0xc2, 0x56, 0x4d, + 0xca, 0xe5, 0xd2, 0x7e, 0x1b, 0x9b, 0x73, 0x35, 0xbf, 0x33, 0xc0, 0x99, 0x56, 0xe8, 0x33, 0x76, + 0x8b, 0x84, 0x8c, 0xfa, 0xde, 0xb5, 0xcd, 0xcf, 0x89, 0xc3, 0x11, 0xb9, 0x4d, 0x42, 0xe2, 0x39, + 0x04, 0xae, 0x82, 0xf2, 0x36, 0xf5, 0x3a, 0x55, 0x63, 0xd5, 0x38, 0xf7, 0xbf, 0xe6, 0xe2, 0xbd, + 0x61, 0x7d, 0x66, 0x34, 0xac, 0x97, 0xdf, 0xa7, 0x5e, 0x07, 0xc9, 0x1d, 0x61, 0xe1, 0x61, 0x97, + 0x54, 0x4b, 0x59, 0x8b, 0xab, 0xd8, 0x25, 0x48, 0xee, 0xc0, 0x06, 0x00, 0x38, 0xa0, 0x9a, 0xa0, + 0x3a, 0x2b, 0xed, 0xa0, 0xb6, 0x03, 0x6b, 0xd7, 0xaf, 0xe8, 0x1d, 0x94, 0xb2, 0x32, 0x1f, 0x95, + 0xc0, 0xa9, 0xcb, 0x7e, 0x48, 0xef, 0xf8, 0x1e, 0xc7, 0xbd, 0xeb, 0x7e, 0x67, 0x4d, 0xe7, 0x41, + 0x42, 0xf8, 0x19, 0x58, 0x10, 0x5d, 0xed, 0x60, 0x8e, 0x65, 0x5c, 0x95, 0xc6, 0x4b, 0x96, 0x56, + 0x66, 0xba, 0xc8, 0x89, 0x36, 0x85, 0xb5, 0x35, 0xb8, 0x60, 0xa9, 0xe4, 0xda, 0x84, 0xe3, 0x84, + 0x3f, 0x59, 0x43, 0x31, 0x2a, 0xf4, 0x40, 0x99, 0x05, 0xc4, 0x91, 0x39, 0x55, 0x1a, 0xeb, 0xd6, + 0x94, 0xba, 0xb7, 0x0a, 0x22, 0xbf, 0x19, 0x10, 0x27, 0xa9, 0x90, 0xf8, 0x87, 0x24, 0x0f, 0x1c, + 0x80, 0x79, 0xc6, 0x31, 0xef, 0x33, 0x59, 0x9d, 0x4a, 0xe3, 0xea, 0xa1, 0x31, 0x4a, 0xd4, 0xe6, + 0x92, 0xe6, 0x9c, 0x57, 0xff, 0x91, 0x66, 0x33, 0xbf, 0x99, 0x05, 0xab, 0x05, 0x9e, 0x2d, 0xdf, + 0xeb, 0x50, 0x4e, 0x7d, 0x0f, 0x5e, 0x06, 0x65, 0xbe, 0x13, 0x10, 0x2d, 0x81, 0x8b, 0x51, 0xf8, + 0x1b, 0x3b, 0x01, 0xd9, 0x1d, 0xd6, 0x9f, 0x7d, 0x9c, 0xbf, 0xb0, 0x43, 0x12, 0x01, 0xde, 0x8a, + 0xd3, 0x54, 0x62, 0x79, 0x33, 0x1b, 0xd6, 0xee, 0xb0, 0xbe, 0xa7, 0xee, 0xad, 0x18, 0x33, 0x9b, + 0x06, 0x1c, 0x00, 0xd8, 0xc3, 0x8c, 0x6f, 0x84, 0xd8, 0x63, 0x8a, 0x93, 0xba, 0x44, 0x97, 0xf2, + 0xf9, 0xfd, 0x49, 0x43, 0x78, 0x34, 0x57, 0x74, 0x3c, 0x70, 0x3d, 0x87, 0x86, 0x26, 0x30, 0xc0, + 0xe7, 0xc0, 0x7c, 0x48, 0x30, 0xf3, 0xbd, 0x6a, 0x59, 0xe6, 0x13, 0x97, 0x19, 0xc9, 0x55, 0xa4, + 0x77, 0xe1, 0x79, 0x70, 0xc4, 0x25, 0x8c, 0xe1, 0x2e, 0xa9, 0xce, 0x49, 0xc3, 0x65, 0x6d, 0x78, + 0xa4, 0xad, 0x96, 0x51, 0xb4, 0x6f, 0xfe, 0x6e, 0x80, 0x33, 0x05, 0x15, 0x5d, 0xa7, 0x8c, 0xc3, + 0x4f, 0x72, 0xda, 0xb7, 0xf6, 0x97, 0xa0, 0xf0, 0x96, 0xca, 0x3f, 0xa6, 0xb9, 0x17, 0xa2, 0x95, + 0x94, 0xee, 0x5d, 0x30, 0x47, 0x39, 0x71, 0x45, 0x7f, 0x66, 0xcf, 0x55, 0x1a, 0x97, 0x0f, 0x4b, + 0x86, 0xcd, 0xa3, 0x9a, 0x74, 0xee, 0x8a, 0x80, 0x47, 0x8a, 0xc5, 0xfc, 0xb3, 0x54, 0x98, 0xac, + 0x38, 0x1c, 0xf0, 0x6b, 0x03, 0x2c, 0xc9, 0xbf, 0x1b, 0x38, 0xec, 0x12, 0x31, 0x95, 0x74, 0xce, + 0xd3, 0x9f, 0xc8, 0x3d, 0x66, 0x5c, 0xf3, 0xa4, 0x0e, 0x6e, 0xe9, 0x66, 0x86, 0x0b, 0x8d, 0x71, + 0xc3, 0x0b, 0xa0, 0xe2, 0x52, 0x0f, 0x91, 0xa0, 0x47, 0x1d, 0xac, 0x34, 0x3c, 0xd7, 0x5c, 0x1e, + 0x0d, 0xeb, 0x95, 0x76, 0xb2, 0x8c, 0xd2, 0x36, 0xf0, 0x15, 0x50, 0x71, 0xf1, 0x17, 0xb1, 0xcb, + 0xac, 0x74, 0x39, 0xae, 0xf9, 0x2a, 0xed, 0x64, 0x0b, 0xa5, 0xed, 0xe0, 0x6d, 0x21, 0x18, 0x1e, + 0x52, 0x87, 0x55, 0xcb, 0xb2, 0x13, 0xaf, 0x4f, 0x9d, 0x70, 0x5b, 0xfa, 0xcb, 0x89, 0x93, 0x52, + 0x9b, 0xc4, 0x44, 0x11, 0xb8, 0xf9, 0x6b, 0x19, 0x9c, 0xdd, 0x73, 0x72, 0xc0, 0x77, 0x01, 0xf4, + 0x37, 0x19, 0x09, 0x07, 0xa4, 0xf3, 0x9e, 0xba, 0x3a, 0xc4, 0x0c, 0x17, 0x5d, 0x98, 0x6d, 0x9e, + 0x14, 0x47, 0xe5, 0x5a, 0x6e, 0x17, 0x4d, 0xf0, 0x80, 0x0e, 0x38, 0x2a, 0x0e, 0x90, 0xaa, 0x30, + 0xd5, 0xd7, 0xc5, 0x74, 0xa7, 0xf3, 0xff, 0xa3, 0x61, 0xfd, 0xe8, 0x7a, 0x1a, 0x04, 0x65, 0x31, + 0xe1, 0x1a, 0x58, 0x76, 0xfa, 0x61, 0x48, 0x3c, 0x3e, 0x56, 0xf1, 0x53, 0xba, 0x02, 0xcb, 0xad, + 0xec, 0x36, 0x1a, 0xb7, 0x17, 0x10, 0x1d, 0xc2, 0x68, 0x48, 0x3a, 0x31, 0x44, 0x39, 0x0b, 0xf1, + 0x76, 0x76, 0x1b, 0x8d, 0xdb, 0xc3, 0xbb, 0x60, 0x49, 0xa3, 0xea, 0x7a, 0x57, 0xe7, 0x64, 0x0f, + 0xdf, 0x38, 0x68, 0x0f, 0xd5, 0x0c, 0x8f, 0x55, 0xda, 0xca, 0x80, 0xa3, 0x31, 0x32, 0xf8, 0x95, + 0x01, 0x80, 0x13, 0x0d, 0x4a, 0x56, 0x9d, 0x97, 0xdc, 0x37, 0x0e, 0xeb, 0x24, 0xc7, 0x23, 0x38, + 0xb9, 0x41, 0xe3, 0x25, 0x86, 0x52, 0xc4, 0xe6, 0x1f, 0x25, 0x00, 0x12, 0x11, 0xc2, 0x8b, 0x99, + 0x5b, 0x64, 0x75, 0xec, 0x16, 0x39, 0xa6, 0x2d, 0xe5, 0x0b, 0x2f, 0x75, 0x63, 0x74, 0xc1, 0xbc, + 0x2f, 0x4f, 0xab, 0xd6, 0x4b, 0x6b, 0xea, 0x3c, 0xe2, 0xfb, 0x3d, 0x86, 0x6f, 0x02, 0x31, 0xa2, + 0xf5, 0x10, 0xd0, 0xf0, 0xf0, 0x53, 0x50, 0x0e, 0xfc, 0x4e, 0x74, 0xff, 0xae, 0x4d, 0x4d, 0x73, + 0xdd, 0xef, 0xb0, 0x0c, 0xc9, 0x82, 0xc8, 0x4e, 0xac, 0x22, 0x09, 0x0c, 0x7d, 0xb0, 0x10, 0xbd, + 0x60, 0xa5, 0xa2, 0x2a, 0x8d, 0x77, 0xa6, 0x26, 0x41, 0x1a, 0x20, 0x43, 0xb4, 0x28, 0x66, 0x79, + 0xb4, 0x83, 0x62, 0x12, 0xf3, 0xaf, 0x12, 0x58, 0x4c, 0x0b, 0xe8, 0xdf, 0xd1, 0x01, 0xa5, 0xe5, + 0x27, 0xdc, 0x01, 0x45, 0xf2, 0x14, 0x3a, 0xa0, 0x88, 0x8a, 0x3a, 0xf0, 0x7d, 0x09, 0xc0, 0xbc, + 0xfc, 0x20, 0x07, 0xf3, 0x5c, 0xde, 0x29, 0x4f, 0xe4, 0x32, 0x8b, 0xdf, 0x20, 0xfa, 0xde, 0xd2, + 0x5c, 0xe2, 0x11, 0xae, 0xa6, 0xfe, 0xd5, 0xe4, 0xb1, 0x1e, 0x1f, 0xe1, 0x76, 0xbc, 0x83, 0x52, + 0x56, 0x90, 0x80, 0x8a, 0xf2, 0xbe, 0x85, 0x7b, 0xfd, 0xe8, 0x41, 0xb5, 0xe7, 0x7b, 0xc3, 0x8a, + 0x92, 0xb7, 0x6e, 0xf4, 0xb1, 0xc7, 0x29, 0xdf, 0x49, 0x6e, 0xbb, 0x8d, 0x04, 0x0a, 0xa5, 0x71, + 0xcd, 0x1f, 0xc6, 0xeb, 0xa4, 0xf4, 0xfa, 0xdf, 0xa9, 0xd3, 0x16, 0x58, 0xd4, 0x43, 0xf8, 0x9f, + 0x14, 0xea, 0x84, 0x66, 0x59, 0x6c, 0xa5, 0xb0, 0x50, 0x06, 0xd9, 0xfc, 0xd9, 0x00, 0xc7, 0xc6, + 0x47, 0xcd, 0x58, 0xc8, 0xc6, 0xbe, 0x42, 0xbe, 0x03, 0xa0, 0x4a, 0x78, 0x6d, 0x40, 0x42, 0xdc, + 0x25, 0x2a, 0xf0, 0xd2, 0x81, 0x02, 0x8f, 0x9f, 0xcd, 0x1b, 0x39, 0x44, 0x34, 0x81, 0xc5, 0xfc, + 0x25, 0x9b, 0x84, 0xea, 0xf6, 0x41, 0x92, 0xb8, 0x0b, 0x8e, 0xeb, 0xea, 0x1c, 0x42, 0x16, 0x67, + 0x34, 0xd9, 0xf1, 0x56, 0x1e, 0x12, 0x4d, 0xe2, 0x31, 0x7f, 0x2c, 0x81, 0x13, 0x93, 0x46, 0x32, + 0x6c, 0xeb, 0x4f, 0x62, 0x95, 0xc5, 0xa5, 0xf4, 0x27, 0xf1, 0xee, 0xb0, 0x7e, 0x7e, 0xcf, 0x6f, + 0x9c, 0x08, 0x30, 0xf5, 0xfd, 0xfc, 0x21, 0xa8, 0x66, 0xaa, 0xf8, 0x01, 0xa7, 0x3d, 0x7a, 0x47, + 0xbd, 0xc4, 0xd4, 0x23, 0xf4, 0x99, 0xd1, 0xb0, 0x5e, 0xdd, 0x28, 0xb0, 0x41, 0x85, 0xde, 0xe2, + 0xc3, 0x69, 0x82, 0x0a, 0x0e, 0x26, 0xdf, 0x93, 0x53, 0x28, 0xe0, 0xa7, 0x7c, 0xe5, 0x94, 0x0a, + 0x0e, 0xb9, 0x72, 0x1f, 0x83, 0xd3, 0xd9, 0xc6, 0xe5, 0x4b, 0x77, 0x76, 0x34, 0xac, 0x9f, 0x6e, + 0x15, 0x19, 0xa1, 0x62, 0xff, 0x22, 0xf5, 0xcd, 0x3e, 0x1d, 0xf5, 0x35, 0xad, 0x7b, 0x0f, 0x6b, + 0x33, 0xf7, 0x1f, 0xd6, 0x66, 0x1e, 0x3c, 0xac, 0xcd, 0x7c, 0x39, 0xaa, 0x19, 0xf7, 0x46, 0x35, + 0xe3, 0xfe, 0xa8, 0x66, 0x3c, 0x18, 0xd5, 0x8c, 0xdf, 0x46, 0x35, 0xe3, 0xdb, 0x47, 0xb5, 0x99, + 0x8f, 0x16, 0xa2, 0x61, 0xf8, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0x4c, 0xa9, 0x91, 0xe9, 0xfe, + 0x13, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto new file mode 100644 index 0000000000..21d9ea6f62 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/generated.proto @@ -0,0 +1,302 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.autoscaling.v2alpha1; + +import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/autoscaling/v1/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v2alpha1"; + +// CrossVersionObjectReference contains enough information to let you identify the referred resource. +message CrossVersionObjectReference { + // Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds" + optional string kind = 1; + + // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names + optional string name = 2; + + // API version of the referent + // +optional + optional string apiVersion = 3; +} + +// HorizontalPodAutoscaler is the configuration for a horizontal pod +// autoscaler, which automatically manages the replica count of any resource +// implementing the scale subresource based on the metrics specified. +message HorizontalPodAutoscaler { + // metadata is the standard object metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // spec is the specification for the behaviour of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + // +optional + optional HorizontalPodAutoscalerSpec spec = 2; + + // status is the current information about the autoscaler. + // +optional + optional HorizontalPodAutoscalerStatus status = 3; +} + +// HorizontalPodAutoscalerCondition describes the state of +// a HorizontalPodAutoscaler at a certain point. +message HorizontalPodAutoscalerCondition { + // type describes the current condition + optional string type = 1; + + // status is the status of the condition (True, False, Unknown) + optional string status = 2; + + // lastTransitionTime is the last time the condition transitioned from + // one status to another + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 3; + + // reason is the reason for the condition's last transition. + // +optional + optional string reason = 4; + + // message is a human-readable explanation containing details about + // the transition + // +optional + optional string message = 5; +} + +// HorizontalPodAutoscaler is a list of horizontal pod autoscaler objects. +message HorizontalPodAutoscalerList { + // metadata is the standard list metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // items is the list of horizontal pod autoscaler objects. + repeated HorizontalPodAutoscaler items = 2; +} + +// HorizontalPodAutoscalerSpec describes the desired functionality of the HorizontalPodAutoscaler. +message HorizontalPodAutoscalerSpec { + // scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics + // should be collected, as well as to actually change the replica count. + optional CrossVersionObjectReference scaleTargetRef = 1; + + // minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. + // It defaults to 1 pod. + // +optional + optional int32 minReplicas = 2; + + // maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. + // It cannot be less that minReplicas. + optional int32 maxReplicas = 3; + + // metrics contains the specifications for which to use to calculate the + // desired replica count (the maximum replica count across all metrics will + // be used). The desired replica count is calculated multiplying the + // ratio between the target value and the current value by the current + // number of pods. Ergo, metrics used must decrease as the pod count is + // increased, and vice-versa. See the individual metric source types for + // more information about how each type of metric must respond. + // +optional + repeated MetricSpec metrics = 4; +} + +// HorizontalPodAutoscalerStatus describes the current status of a horizontal pod autoscaler. +message HorizontalPodAutoscalerStatus { + // observedGeneration is the most recent generation observed by this autoscaler. + // +optional + optional int64 observedGeneration = 1; + + // lastScaleTime is the last time the HorizontalPodAutoscaler scaled the number of pods, + // used by the autoscaler to control how often the number of pods is changed. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastScaleTime = 2; + + // currentReplicas is current number of replicas of pods managed by this autoscaler, + // as last seen by the autoscaler. + optional int32 currentReplicas = 3; + + // desiredReplicas is the desired number of replicas of pods managed by this autoscaler, + // as last calculated by the autoscaler. + optional int32 desiredReplicas = 4; + + // currentMetrics is the last read state of the metrics used by this autoscaler. + repeated MetricStatus currentMetrics = 5; + + // conditions is the set of conditions required for this autoscaler to scale its target, + // and indicates whether or not those conditions are met. + repeated HorizontalPodAutoscalerCondition conditions = 6; +} + +// MetricSpec specifies how to scale based on a single metric +// (only `type` and one other matching field should be set at once). +message MetricSpec { + // type is the type of metric source. It should match one of the fields below. + optional string type = 1; + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + optional ObjectMetricSource object = 2; + + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + optional PodsMetricSource pods = 3; + + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + optional ResourceMetricSource resource = 4; +} + +// MetricStatus describes the last-read state of a single metric. +message MetricStatus { + // type is the type of metric source. It will match one of the fields below. + optional string type = 1; + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + optional ObjectMetricStatus object = 2; + + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + optional PodsMetricStatus pods = 3; + + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + optional ResourceMetricStatus resource = 4; +} + +// ObjectMetricSource indicates how to scale on a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +message ObjectMetricSource { + // target is the described Kubernetes object. + optional CrossVersionObjectReference target = 1; + + // metricName is the name of the metric in question. + optional string metricName = 2; + + // targetValue is the target value of the metric (as a quantity). + optional k8s.io.apimachinery.pkg.api.resource.Quantity targetValue = 3; +} + +// ObjectMetricStatus indicates the current value of a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +message ObjectMetricStatus { + // target is the described Kubernetes object. + optional CrossVersionObjectReference target = 1; + + // metricName is the name of the metric in question. + optional string metricName = 2; + + // currentValue is the current value of the metric (as a quantity). + optional k8s.io.apimachinery.pkg.api.resource.Quantity currentValue = 3; +} + +// PodsMetricSource indicates how to scale on a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +// The values will be averaged together before being compared to the target +// value. +message PodsMetricSource { + // metricName is the name of the metric in question + optional string metricName = 1; + + // targetAverageValue is the target value of the average of the + // metric across all relevant pods (as a quantity) + optional k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 2; +} + +// PodsMetricStatus indicates the current value of a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +message PodsMetricStatus { + // metricName is the name of the metric in question + optional string metricName = 1; + + // currentAverageValue is the current value of the average of the + // metric across all relevant pods (as a quantity) + optional k8s.io.apimachinery.pkg.api.resource.Quantity currentAverageValue = 2; +} + +// ResourceMetricSource indicates how to scale on a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). The values will be averaged +// together before being compared to the target. Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. Only one "target" type +// should be set. +message ResourceMetricSource { + // name is the name of the resource in question. + optional string name = 1; + + // targetAverageUtilization is the target value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. + // +optional + optional int32 targetAverageUtilization = 2; + + // targetAverageValue is the target value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // +optional + optional k8s.io.apimachinery.pkg.api.resource.Quantity targetAverageValue = 3; +} + +// ResourceMetricStatus indicates the current value of a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. +message ResourceMetricStatus { + // name is the name of the resource in question. + optional string name = 1; + + // currentAverageUtilization is the current value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. It will only be + // present if `targetAverageValue` was set in the corresponding metric + // specification. + // +optional + optional int32 currentAverageUtilization = 2; + + // currentAverageValue is the current value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // It will always be set, regardless of the corresponding metric specification. + optional k8s.io.apimachinery.pkg.api.resource.Quantity currentAverageValue = 3; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/register.go new file mode 100644 index 0000000000..e623be7e3f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/register.go @@ -0,0 +1,59 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "autoscaling" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v2alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs) +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &HorizontalPodAutoscaler{}, + &HorizontalPodAutoscalerList{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.generated.go new file mode 100644 index 0000000000..5f984e4f5c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.generated.go @@ -0,0 +1,5218 @@ +/* +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 v2alpha1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_resource "k8s.io/apimachinery/pkg/api/resource" + pkg3_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg4_types "k8s.io/apimachinery/pkg/types" + pkg2_v1 "k8s.io/client-go/pkg/api/v1" + "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 pkg1_resource.Quantity + var v1 pkg3_v1.Time + var v2 pkg4_types.UID + var v3 pkg2_v1.ResourceName + var v4 time.Time + _, _, _, _, _ = v0, v1, v2, v3, v4 + } +} + +func (x *CrossVersionObjectReference) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = x.APIVersion != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + 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) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *CrossVersionObjectReference) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *CrossVersionObjectReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv6 := &x.Name + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv8 := &x.APIVersion + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *CrossVersionObjectReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv11 := &x.Kind + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv13 := &x.Name + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *HorizontalPodAutoscalerSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.MinReplicas != nil + yyq2[3] = len(x.Metrics) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.ScaleTargetRef + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("scaleTargetRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.ScaleTargetRef + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.MinReplicas == nil { + r.EncodeNil() + } else { + yy9 := *x.MinReplicas + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(yy9)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("minReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.MinReplicas == nil { + r.EncodeNil() + } else { + yy11 := *x.MinReplicas + yym12 := z.EncBinary() + _ = yym12 + if false { + } else { + r.EncodeInt(int64(yy11)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.MaxReplicas)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("maxReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeInt(int64(x.MaxReplicas)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Metrics == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + h.encSliceMetricSpec(([]MetricSpec)(x.Metrics), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metrics")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Metrics == nil { + r.EncodeNil() + } else { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + h.encSliceMetricSpec(([]MetricSpec)(x.Metrics), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HorizontalPodAutoscalerSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "scaleTargetRef": + if r.TryDecodeAsNil() { + x.ScaleTargetRef = CrossVersionObjectReference{} + } else { + yyv4 := &x.ScaleTargetRef + yyv4.CodecDecodeSelf(d) + } + case "minReplicas": + if r.TryDecodeAsNil() { + if x.MinReplicas != nil { + x.MinReplicas = nil + } + } else { + if x.MinReplicas == nil { + x.MinReplicas = new(int32) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) + } + } + case "maxReplicas": + if r.TryDecodeAsNil() { + x.MaxReplicas = 0 + } else { + yyv7 := &x.MaxReplicas + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } + } + case "metrics": + if r.TryDecodeAsNil() { + x.Metrics = nil + } else { + yyv9 := &x.Metrics + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSliceMetricSpec((*[]MetricSpec)(yyv9), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ScaleTargetRef = CrossVersionObjectReference{} + } else { + yyv12 := &x.ScaleTargetRef + yyv12.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.MinReplicas != nil { + x.MinReplicas = nil + } + } else { + if x.MinReplicas == nil { + x.MinReplicas = new(int32) + } + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MaxReplicas = 0 + } else { + yyv15 := &x.MaxReplicas + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*int32)(yyv15)) = int32(r.DecodeInt(32)) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Metrics = nil + } else { + yyv17 := &x.Metrics + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + h.decSliceMetricSpec((*[]MetricSpec)(yyv17), d) + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x MetricSourceType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *MetricSourceType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *MetricSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Object != nil + yyq2[2] = x.Pods != nil + yyq2[3] = x.Resource != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("object")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("pods")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *MetricSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *MetricSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "object": + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricSource) + } + x.Object.CodecDecodeSelf(d) + } + case "pods": + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricSource) + } + x.Pods.CodecDecodeSelf(d) + } + case "resource": + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricSource) + } + x.Resource.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *MetricSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv9 := &x.Type + yyv9.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricSource) + } + x.Object.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricSource) + } + x.Pods.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricSource) + } + x.Resource.CodecDecodeSelf(d) + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ObjectMetricSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Target + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("target")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Target + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.TargetValue + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.TargetValue + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(yy14) { + } else if !yym15 && z.IsJSONHandle() { + z.EncJSONMarshal(yy14) + } else { + z.EncFallback(yy14) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ObjectMetricSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ObjectMetricSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "target": + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv4 := &x.Target + yyv4.CodecDecodeSelf(d) + } + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv5 := &x.MetricName + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "targetValue": + if r.TryDecodeAsNil() { + x.TargetValue = pkg1_resource.Quantity{} + } else { + yyv7 := &x.TargetValue + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) + } else { + z.DecFallback(yyv7, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ObjectMetricSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv10 := &x.Target + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv11 := &x.MetricName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TargetValue = pkg1_resource.Quantity{} + } else { + yyv13 := &x.TargetValue + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PodsMetricSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.TargetAverageValue + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.TargetAverageValue + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PodsMetricSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PodsMetricSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv4 := &x.MetricName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "targetAverageValue": + if r.TryDecodeAsNil() { + x.TargetAverageValue = pkg1_resource.Quantity{} + } else { + yyv6 := &x.TargetAverageValue + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PodsMetricSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv9 := &x.MetricName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.TargetAverageValue = pkg1_resource.Quantity{} + } else { + yyv11 := &x.TargetAverageValue + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) + } else { + z.DecFallback(yyv11, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ResourceMetricSource) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.TargetAverageUtilization != nil + yyq2[2] = x.TargetAverageValue != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf4 := &x.Name + yysf4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf5 := &x.Name + yysf5.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.TargetAverageUtilization == nil { + r.EncodeNil() + } else { + yy7 := *x.TargetAverageUtilization + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(yy7)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetAverageUtilization")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.TargetAverageUtilization == nil { + r.EncodeNil() + } else { + yy9 := *x.TargetAverageUtilization + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(yy9)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.TargetAverageValue == nil { + r.EncodeNil() + } else { + yym12 := z.EncBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.EncExt(x.TargetAverageValue) { + } else if !yym12 && z.IsJSONHandle() { + z.EncJSONMarshal(x.TargetAverageValue) + } else { + z.EncFallback(x.TargetAverageValue) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("targetAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.TargetAverageValue == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(x.TargetAverageValue) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(x.TargetAverageValue) + } else { + z.EncFallback(x.TargetAverageValue) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ResourceMetricSource) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ResourceMetricSource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yyv4.CodecDecodeSelf(d) + } + case "targetAverageUtilization": + if r.TryDecodeAsNil() { + if x.TargetAverageUtilization != nil { + x.TargetAverageUtilization = nil + } + } else { + if x.TargetAverageUtilization == nil { + x.TargetAverageUtilization = new(int32) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*int32)(x.TargetAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + case "targetAverageValue": + if r.TryDecodeAsNil() { + if x.TargetAverageValue != nil { + x.TargetAverageValue = nil + } + } else { + if x.TargetAverageValue == nil { + x.TargetAverageValue = new(pkg1_resource.Quantity) + } + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(x.TargetAverageValue) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.TargetAverageValue) + } else { + z.DecFallback(x.TargetAverageValue, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ResourceMetricSource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.TargetAverageUtilization != nil { + x.TargetAverageUtilization = nil + } + } else { + if x.TargetAverageUtilization == nil { + x.TargetAverageUtilization = new(int32) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(x.TargetAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.TargetAverageValue != nil { + x.TargetAverageValue = nil + } + } else { + if x.TargetAverageValue == nil { + x.TargetAverageValue = new(pkg1_resource.Quantity) + } + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(x.TargetAverageValue) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.TargetAverageValue) + } else { + z.DecFallback(x.TargetAverageValue, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ObservedGeneration != nil + yyq2[1] = x.LastScaleTime != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 4 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.ObservedGeneration == nil { + r.EncodeNil() + } else { + yy4 := *x.ObservedGeneration + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(yy4)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ObservedGeneration == nil { + r.EncodeNil() + } else { + yy6 := *x.ObservedGeneration + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(yy6)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.LastScaleTime == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { + } else if yym9 { + z.EncBinaryMarshal(x.LastScaleTime) + } else if !yym9 && z.IsJSONHandle() { + z.EncJSONMarshal(x.LastScaleTime) + } else { + z.EncFallback(x.LastScaleTime) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("lastScaleTime")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.LastScaleTime == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { + } else if yym10 { + z.EncBinaryMarshal(x.LastScaleTime) + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(x.LastScaleTime) + } else { + z.EncFallback(x.LastScaleTime) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym12 := z.EncBinary() + _ = yym12 + if false { + } else { + r.EncodeInt(int64(x.CurrentReplicas)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.CurrentReplicas)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeInt(int64(x.DesiredReplicas)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("desiredReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.DesiredReplicas)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.CurrentMetrics == nil { + r.EncodeNil() + } else { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + h.encSliceMetricStatus(([]MetricStatus)(x.CurrentMetrics), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentMetrics")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CurrentMetrics == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encSliceMetricStatus(([]MetricStatus)(x.CurrentMetrics), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Conditions == nil { + r.EncodeNil() + } else { + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + h.encSliceHorizontalPodAutoscalerCondition(([]HorizontalPodAutoscalerCondition)(x.Conditions), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("conditions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Conditions == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encSliceHorizontalPodAutoscalerCondition(([]HorizontalPodAutoscalerCondition)(x.Conditions), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HorizontalPodAutoscalerStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "observedGeneration": + if r.TryDecodeAsNil() { + if x.ObservedGeneration != nil { + x.ObservedGeneration = nil + } + } else { + if x.ObservedGeneration == nil { + x.ObservedGeneration = new(int64) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + } + } + case "lastScaleTime": + if r.TryDecodeAsNil() { + if x.LastScaleTime != nil { + x.LastScaleTime = nil + } + } else { + if x.LastScaleTime == nil { + x.LastScaleTime = new(pkg3_v1.Time) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { + } else if yym7 { + z.DecBinaryUnmarshal(x.LastScaleTime) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.LastScaleTime) + } else { + z.DecFallback(x.LastScaleTime, false) + } + } + case "currentReplicas": + if r.TryDecodeAsNil() { + x.CurrentReplicas = 0 + } else { + yyv8 := &x.CurrentReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } + } + case "desiredReplicas": + if r.TryDecodeAsNil() { + x.DesiredReplicas = 0 + } else { + yyv10 := &x.DesiredReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } + } + case "currentMetrics": + if r.TryDecodeAsNil() { + x.CurrentMetrics = nil + } else { + yyv12 := &x.CurrentMetrics + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + h.decSliceMetricStatus((*[]MetricStatus)(yyv12), d) + } + } + case "conditions": + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv14 := &x.Conditions + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decSliceHorizontalPodAutoscalerCondition((*[]HorizontalPodAutoscalerCondition)(yyv14), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ObservedGeneration != nil { + x.ObservedGeneration = nil + } + } else { + if x.ObservedGeneration == nil { + x.ObservedGeneration = new(int64) + } + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.LastScaleTime != nil { + x.LastScaleTime = nil + } + } else { + if x.LastScaleTime == nil { + x.LastScaleTime = new(pkg3_v1.Time) + } + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { + } else if yym20 { + z.DecBinaryUnmarshal(x.LastScaleTime) + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.LastScaleTime) + } else { + z.DecFallback(x.LastScaleTime, false) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentReplicas = 0 + } else { + yyv21 := &x.CurrentReplicas + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.DesiredReplicas = 0 + } else { + yyv23 := &x.DesiredReplicas + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentMetrics = nil + } else { + yyv25 := &x.CurrentMetrics + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + h.decSliceMetricStatus((*[]MetricStatus)(yyv25), d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv27 := &x.Conditions + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + h.decSliceHorizontalPodAutoscalerCondition((*[]HorizontalPodAutoscalerCondition)(yyv27), d) + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x HorizontalPodAutoscalerConditionType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *HorizontalPodAutoscalerConditionType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *HorizontalPodAutoscalerCondition) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = x.Reason != "" + yyq2[4] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf7 := &x.Status + yysf7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf8 := &x.Status + yysf8.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.LastTransitionTime + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.LastTransitionTime + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("reason")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("message")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HorizontalPodAutoscalerCondition) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *HorizontalPodAutoscalerCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) + } + case "lastTransitionTime": + if r.TryDecodeAsNil() { + x.LastTransitionTime = pkg3_v1.Time{} + } else { + yyv6 := &x.LastTransitionTime + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + case "reason": + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv8 := &x.Reason + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "message": + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv10 := &x.Message + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HorizontalPodAutoscalerCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv13 := &x.Type + yyv13.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = "" + } else { + yyv14 := &x.Status + yyv14.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.LastTransitionTime = pkg3_v1.Time{} + } else { + yyv15 := &x.LastTransitionTime + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else if yym16 { + z.DecBinaryUnmarshal(yyv15) + } else if !yym16 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv15) + } else { + z.DecFallback(yyv15, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv17 := &x.Reason + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv19 := &x.Message + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *MetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Object != nil + yyq2[2] = x.Pods != nil + yyq2[3] = x.Resource != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("object")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Object == nil { + r.EncodeNil() + } else { + x.Object.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("pods")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Pods == nil { + r.EncodeNil() + } else { + x.Pods.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resource")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resource == nil { + r.EncodeNil() + } else { + x.Resource.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *MetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *MetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "object": + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricStatus) + } + x.Object.CodecDecodeSelf(d) + } + case "pods": + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricStatus) + } + x.Pods.CodecDecodeSelf(d) + } + case "resource": + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricStatus) + } + x.Resource.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *MetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv9 := &x.Type + yyv9.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Object != nil { + x.Object = nil + } + } else { + if x.Object == nil { + x.Object = new(ObjectMetricStatus) + } + x.Object.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Pods != nil { + x.Pods = nil + } + } else { + if x.Pods == nil { + x.Pods = new(PodsMetricStatus) + } + x.Pods.CodecDecodeSelf(d) + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Resource != nil { + x.Resource = nil + } + } else { + if x.Resource == nil { + x.Resource = new(ResourceMetricStatus) + } + x.Resource.CodecDecodeSelf(d) + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ObjectMetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.Target + yy4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("target")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.Target + yy6.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.CurrentValue + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.CurrentValue + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(yy14) { + } else if !yym15 && z.IsJSONHandle() { + z.EncJSONMarshal(yy14) + } else { + z.EncFallback(yy14) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ObjectMetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ObjectMetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "target": + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv4 := &x.Target + yyv4.CodecDecodeSelf(d) + } + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv5 := &x.MetricName + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "currentValue": + if r.TryDecodeAsNil() { + x.CurrentValue = pkg1_resource.Quantity{} + } else { + yyv7 := &x.CurrentValue + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) + } else { + z.DecFallback(yyv7, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ObjectMetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Target = CrossVersionObjectReference{} + } else { + yyv10 := &x.Target + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv11 := &x.MetricName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentValue = pkg1_resource.Quantity{} + } else { + yyv13 := &x.CurrentValue + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *PodsMetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metricName")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.MetricName)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy7 := &x.CurrentAverageValue + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) + } else { + z.EncFallback(yy7) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.CurrentAverageValue + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) + } else { + z.EncFallback(yy9) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PodsMetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PodsMetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "metricName": + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv4 := &x.MetricName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "currentAverageValue": + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg1_resource.Quantity{} + } else { + yyv6 := &x.CurrentAverageValue + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PodsMetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.MetricName = "" + } else { + yyv9 := &x.MetricName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg1_resource.Quantity{} + } else { + yyv11 := &x.CurrentAverageValue + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) + } else { + z.DecFallback(yyv11, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ResourceMetricStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.CurrentAverageUtilization != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf4 := &x.Name + yysf4.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf5 := &x.Name + yysf5.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.CurrentAverageUtilization == nil { + r.EncodeNil() + } else { + yy7 := *x.CurrentAverageUtilization + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(yy7)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentAverageUtilization")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CurrentAverageUtilization == nil { + r.EncodeNil() + } else { + yy9 := *x.CurrentAverageUtilization + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(yy9)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.CurrentAverageValue + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) + } else { + z.EncFallback(yy12) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentAverageValue")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.CurrentAverageValue + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(yy14) { + } else if !yym15 && z.IsJSONHandle() { + z.EncJSONMarshal(yy14) + } else { + z.EncFallback(yy14) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ResourceMetricStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ResourceMetricStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv4 := &x.Name + yyv4.CodecDecodeSelf(d) + } + case "currentAverageUtilization": + if r.TryDecodeAsNil() { + if x.CurrentAverageUtilization != nil { + x.CurrentAverageUtilization = nil + } + } else { + if x.CurrentAverageUtilization == nil { + x.CurrentAverageUtilization = new(int32) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*int32)(x.CurrentAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + case "currentAverageValue": + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg1_resource.Quantity{} + } else { + yyv7 := &x.CurrentAverageValue + yym8 := z.DecBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.DecExt(yyv7) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv7) + } else { + z.DecFallback(yyv7, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ResourceMetricStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv10 := &x.Name + yyv10.CodecDecodeSelf(d) + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.CurrentAverageUtilization != nil { + x.CurrentAverageUtilization = nil + } + } else { + if x.CurrentAverageUtilization == nil { + x.CurrentAverageUtilization = new(int32) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(x.CurrentAverageUtilization)) = int32(r.DecodeInt(32)) + } + } + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentAverageValue = pkg1_resource.Quantity{} + } else { + yyv13 := &x.CurrentAverageValue + yym14 := z.DecBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.DecExt(yyv13) { + } else if !yym14 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv13) + } else { + z.DecFallback(yyv13, false) + } + } + for { + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l + } else { + yyb9 = r.CheckBreak() + } + if yyb9 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj9-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HorizontalPodAutoscaler) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *HorizontalPodAutoscaler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg3_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = HorizontalPodAutoscalerSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = HorizontalPodAutoscalerStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg3_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = HorizontalPodAutoscalerSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = HorizontalPodAutoscalerStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *HorizontalPodAutoscalerList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg3_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg3_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceMetricSpec(v []MetricSpec, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceMetricSpec(v *[]MetricSpec, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []MetricSpec{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]MetricSpec, yyrl1) + } + } else { + yyv1 = make([]MetricSpec, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = MetricSpec{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, MetricSpec{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = MetricSpec{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, MetricSpec{}) // var yyz1 MetricSpec + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = MetricSpec{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []MetricSpec{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceMetricStatus(v []MetricStatus, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceMetricStatus(v *[]MetricStatus, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []MetricStatus{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]MetricStatus, yyrl1) + } + } else { + yyv1 = make([]MetricStatus, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = MetricStatus{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, MetricStatus{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = MetricStatus{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, MetricStatus{}) // var yyz1 MetricStatus + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = MetricStatus{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []MetricStatus{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceHorizontalPodAutoscalerCondition(v []HorizontalPodAutoscalerCondition, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceHorizontalPodAutoscalerCondition(v *[]HorizontalPodAutoscalerCondition, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HorizontalPodAutoscalerCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 88) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]HorizontalPodAutoscalerCondition, yyrl1) + } + } else { + yyv1 = make([]HorizontalPodAutoscalerCondition, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = HorizontalPodAutoscalerCondition{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HorizontalPodAutoscalerCondition{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = HorizontalPodAutoscalerCondition{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HorizontalPodAutoscalerCondition{}) // var yyz1 HorizontalPodAutoscalerCondition + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = HorizontalPodAutoscalerCondition{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HorizontalPodAutoscalerCondition{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceHorizontalPodAutoscaler(v []HorizontalPodAutoscaler, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceHorizontalPodAutoscaler(v *[]HorizontalPodAutoscaler, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HorizontalPodAutoscaler{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 424) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]HorizontalPodAutoscaler, yyrl1) + } + } else { + yyv1 = make([]HorizontalPodAutoscaler, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = HorizontalPodAutoscaler{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HorizontalPodAutoscaler{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = HorizontalPodAutoscaler{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HorizontalPodAutoscaler{}) // var yyz1 HorizontalPodAutoscaler + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = HorizontalPodAutoscaler{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HorizontalPodAutoscaler{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.go new file mode 100644 index 0000000000..bbdf7b09bf --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types.go @@ -0,0 +1,309 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +import ( + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/pkg/api/v1" +) + +// CrossVersionObjectReference contains enough information to let you identify the referred resource. +type CrossVersionObjectReference struct { + // Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds" + Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` + // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names + Name string `json:"name" protobuf:"bytes,2,opt,name=name"` + // API version of the referent + // +optional + APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,3,opt,name=apiVersion"` +} + +// HorizontalPodAutoscalerSpec describes the desired functionality of the HorizontalPodAutoscaler. +type HorizontalPodAutoscalerSpec struct { + // scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics + // should be collected, as well as to actually change the replica count. + ScaleTargetRef CrossVersionObjectReference `json:"scaleTargetRef" protobuf:"bytes,1,opt,name=scaleTargetRef"` + // minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. + // It defaults to 1 pod. + // +optional + MinReplicas *int32 `json:"minReplicas,omitempty" protobuf:"varint,2,opt,name=minReplicas"` + // maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. + // It cannot be less that minReplicas. + MaxReplicas int32 `json:"maxReplicas" protobuf:"varint,3,opt,name=maxReplicas"` + // metrics contains the specifications for which to use to calculate the + // desired replica count (the maximum replica count across all metrics will + // be used). The desired replica count is calculated multiplying the + // ratio between the target value and the current value by the current + // number of pods. Ergo, metrics used must decrease as the pod count is + // increased, and vice-versa. See the individual metric source types for + // more information about how each type of metric must respond. + // +optional + Metrics []MetricSpec `json:"metrics,omitempty" protobuf:"bytes,4,rep,name=metrics"` +} + +// MetricSourceType indicates the type of metric. +type MetricSourceType string + +var ( + // ObjectMetricSourceType is a metric describing a kubernetes object + // (for example, hits-per-second on an Ingress object). + ObjectMetricSourceType MetricSourceType = "Object" + // PodsMetricSourceType is a metric describing each pod in the current scale + // target (for example, transactions-processed-per-second). The values + // will be averaged together before being compared to the target value. + PodsMetricSourceType MetricSourceType = "Pods" + // ResourceMetricSourceType is a resource metric known to Kubernetes, as + // specified in requests and limits, describing each pod in the current + // scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics (the "pods" source). + ResourceMetricSourceType MetricSourceType = "Resource" +) + +// MetricSpec specifies how to scale based on a single metric +// (only `type` and one other matching field should be set at once). +type MetricSpec struct { + // type is the type of metric source. It should match one of the fields below. + Type MetricSourceType `json:"type" protobuf:"bytes,1,name=type"` + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + Object *ObjectMetricSource `json:"object,omitempty" protobuf:"bytes,2,opt,name=object"` + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + Pods *PodsMetricSource `json:"pods,omitempty" protobuf:"bytes,3,opt,name=pods"` + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + Resource *ResourceMetricSource `json:"resource,omitempty" protobuf:"bytes,4,opt,name=resource"` +} + +// ObjectMetricSource indicates how to scale on a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +type ObjectMetricSource struct { + // target is the described Kubernetes object. + Target CrossVersionObjectReference `json:"target" protobuf:"bytes,1,name=target"` + + // metricName is the name of the metric in question. + MetricName string `json:"metricName" protobuf:"bytes,2,name=metricName"` + // targetValue is the target value of the metric (as a quantity). + TargetValue resource.Quantity `json:"targetValue" protobuf:"bytes,3,name=targetValue"` +} + +// PodsMetricSource indicates how to scale on a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +// The values will be averaged together before being compared to the target +// value. +type PodsMetricSource struct { + // metricName is the name of the metric in question + MetricName string `json:"metricName" protobuf:"bytes,1,name=metricName"` + // targetAverageValue is the target value of the average of the + // metric across all relevant pods (as a quantity) + TargetAverageValue resource.Quantity `json:"targetAverageValue" protobuf:"bytes,2,name=targetAverageValue"` +} + +// ResourceMetricSource indicates how to scale on a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). The values will be averaged +// together before being compared to the target. Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. Only one "target" type +// should be set. +type ResourceMetricSource struct { + // name is the name of the resource in question. + Name v1.ResourceName `json:"name" protobuf:"bytes,1,name=name"` + // targetAverageUtilization is the target value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. + // +optional + TargetAverageUtilization *int32 `json:"targetAverageUtilization,omitempty" protobuf:"varint,2,opt,name=targetAverageUtilization"` + // targetAverageValue is the target value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // +optional + TargetAverageValue *resource.Quantity `json:"targetAverageValue,omitempty" protobuf:"bytes,3,opt,name=targetAverageValue"` +} + +// HorizontalPodAutoscalerStatus describes the current status of a horizontal pod autoscaler. +type HorizontalPodAutoscalerStatus struct { + // observedGeneration is the most recent generation observed by this autoscaler. + // +optional + ObservedGeneration *int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"` + + // lastScaleTime is the last time the HorizontalPodAutoscaler scaled the number of pods, + // used by the autoscaler to control how often the number of pods is changed. + // +optional + LastScaleTime *metav1.Time `json:"lastScaleTime,omitempty" protobuf:"bytes,2,opt,name=lastScaleTime"` + + // currentReplicas is current number of replicas of pods managed by this autoscaler, + // as last seen by the autoscaler. + CurrentReplicas int32 `json:"currentReplicas" protobuf:"varint,3,opt,name=currentReplicas"` + + // desiredReplicas is the desired number of replicas of pods managed by this autoscaler, + // as last calculated by the autoscaler. + DesiredReplicas int32 `json:"desiredReplicas" protobuf:"varint,4,opt,name=desiredReplicas"` + + // currentMetrics is the last read state of the metrics used by this autoscaler. + CurrentMetrics []MetricStatus `json:"currentMetrics" protobuf:"bytes,5,rep,name=currentMetrics"` + + // conditions is the set of conditions required for this autoscaler to scale its target, + // and indicates whether or not those conditions are met. + Conditions []HorizontalPodAutoscalerCondition `json:"conditions" protobuf:"bytes,6,rep,name=conditions"` +} + +// HorizontalPodAutoscalerConditionType are the valid conditions of +// a HorizontalPodAutoscaler. +type HorizontalPodAutoscalerConditionType string + +var ( + // ScalingActive indicates that the HPA controller is able to scale if necessary: + // it's correctly configured, can fetch the desired metrics, and isn't disabled. + ScalingActive HorizontalPodAutoscalerConditionType = "ScalingActive" + // AbleToScale indicates a lack of transient issues which prevent scaling from occuring, + // such as being in a backoff window, or being unable to access/update the target scale. + AbleToScale HorizontalPodAutoscalerConditionType = "AbleToScale" + // ScalingLimited indicates that the calculated scale based on metrics would be above or + // below the range for the HPA, and has thus been capped. + ScalingLimited HorizontalPodAutoscalerConditionType = "ScalingLimited" +) + +// HorizontalPodAutoscalerCondition describes the state of +// a HorizontalPodAutoscaler at a certain point. +type HorizontalPodAutoscalerCondition struct { + // type describes the current condition + Type HorizontalPodAutoscalerConditionType `json:"type" protobuf:"bytes,1,name=type"` + // status is the status of the condition (True, False, Unknown) + Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,name=status"` + // lastTransitionTime is the last time the condition transitioned from + // one status to another + // +optional + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,3,opt,name=lastTransitionTime"` + // reason is the reason for the condition's last transition. + // +optional + Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` + // message is a human-readable explanation containing details about + // the transition + // +optional + Message string `json:"message,omitempty" protobuf:"bytes,5,opt,name=message"` +} + +// MetricStatus describes the last-read state of a single metric. +type MetricStatus struct { + // type is the type of metric source. It will match one of the fields below. + Type MetricSourceType `json:"type" protobuf:"bytes,1,name=type"` + + // object refers to a metric describing a single kubernetes object + // (for example, hits-per-second on an Ingress object). + // +optional + Object *ObjectMetricStatus `json:"object,omitempty" protobuf:"bytes,2,opt,name=object"` + // pods refers to a metric describing each pod in the current scale target + // (for example, transactions-processed-per-second). The values will be + // averaged together before being compared to the target value. + // +optional + Pods *PodsMetricStatus `json:"pods,omitempty" protobuf:"bytes,3,opt,name=pods"` + // resource refers to a resource metric (such as those specified in + // requests and limits) known to Kubernetes describing each pod in the + // current scale target (e.g. CPU or memory). Such metrics are built in to + // Kubernetes, and have special scaling options on top of those available + // to normal per-pod metrics using the "pods" source. + // +optional + Resource *ResourceMetricStatus `json:"resource,omitempty" protobuf:"bytes,4,opt,name=resource"` +} + +// ObjectMetricStatus indicates the current value of a metric describing a +// kubernetes object (for example, hits-per-second on an Ingress object). +type ObjectMetricStatus struct { + // target is the described Kubernetes object. + Target CrossVersionObjectReference `json:"target" protobuf:"bytes,1,name=target"` + + // metricName is the name of the metric in question. + MetricName string `json:"metricName" protobuf:"bytes,2,name=metricName"` + // currentValue is the current value of the metric (as a quantity). + CurrentValue resource.Quantity `json:"currentValue" protobuf:"bytes,3,name=currentValue"` +} + +// PodsMetricStatus indicates the current value of a metric describing each pod in +// the current scale target (for example, transactions-processed-per-second). +type PodsMetricStatus struct { + // metricName is the name of the metric in question + MetricName string `json:"metricName" protobuf:"bytes,1,name=metricName"` + // currentAverageValue is the current value of the average of the + // metric across all relevant pods (as a quantity) + CurrentAverageValue resource.Quantity `json:"currentAverageValue" protobuf:"bytes,2,name=currentAverageValue"` +} + +// ResourceMetricStatus indicates the current value of a resource metric known to +// Kubernetes, as specified in requests and limits, describing each pod in the +// current scale target (e.g. CPU or memory). Such metrics are built in to +// Kubernetes, and have special scaling options on top of those available to +// normal per-pod metrics using the "pods" source. +type ResourceMetricStatus struct { + // name is the name of the resource in question. + Name v1.ResourceName `json:"name" protobuf:"bytes,1,name=name"` + // currentAverageUtilization is the current value of the average of the + // resource metric across all relevant pods, represented as a percentage of + // the requested value of the resource for the pods. It will only be + // present if `targetAverageValue` was set in the corresponding metric + // specification. + // +optional + CurrentAverageUtilization *int32 `json:"currentAverageUtilization,omitempty" protobuf:"bytes,2,opt,name=currentAverageUtilization"` + // currentAverageValue is the current value of the average of the + // resource metric across all relevant pods, as a raw value (instead of as + // a percentage of the request), similar to the "pods" metric source type. + // It will always be set, regardless of the corresponding metric specification. + CurrentAverageValue resource.Quantity `json:"currentAverageValue" protobuf:"bytes,3,name=currentAverageValue"` +} + +// +genclient=true + +// HorizontalPodAutoscaler is the configuration for a horizontal pod +// autoscaler, which automatically manages the replica count of any resource +// implementing the scale subresource based on the metrics specified. +type HorizontalPodAutoscaler struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard object metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // spec is the specification for the behaviour of the autoscaler. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. + // +optional + Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` + + // status is the current information about the autoscaler. + // +optional + Status HorizontalPodAutoscalerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` +} + +// HorizontalPodAutoscaler is a list of horizontal pod autoscaler objects. +type HorizontalPodAutoscalerList struct { + metav1.TypeMeta `json:",inline"` + // metadata is the standard list metadata. + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // items is the list of horizontal pod autoscaler objects. + Items []HorizontalPodAutoscaler `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..b1c1407387 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/types_swagger_doc_generated.go @@ -0,0 +1,189 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v2alpha1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_CrossVersionObjectReference = map[string]string{ + "": "CrossVersionObjectReference contains enough information to let you identify the referred resource.", + "kind": "Kind of the referent; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds\"", + "name": "Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names", + "apiVersion": "API version of the referent", +} + +func (CrossVersionObjectReference) SwaggerDoc() map[string]string { + return map_CrossVersionObjectReference +} + +var map_HorizontalPodAutoscaler = map[string]string{ + "": "HorizontalPodAutoscaler is the configuration for a horizontal pod autoscaler, which automatically manages the replica count of any resource implementing the scale subresource based on the metrics specified.", + "metadata": "metadata is the standard object metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "spec is the specification for the behaviour of the autoscaler. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + "status": "status is the current information about the autoscaler.", +} + +func (HorizontalPodAutoscaler) SwaggerDoc() map[string]string { + return map_HorizontalPodAutoscaler +} + +var map_HorizontalPodAutoscalerCondition = map[string]string{ + "": "HorizontalPodAutoscalerCondition describes the state of a HorizontalPodAutoscaler at a certain point.", + "type": "type describes the current condition", + "status": "status is the status of the condition (True, False, Unknown)", + "lastTransitionTime": "lastTransitionTime is the last time the condition transitioned from one status to another", + "reason": "reason is the reason for the condition's last transition.", + "message": "message is a human-readable explanation containing details about the transition", +} + +func (HorizontalPodAutoscalerCondition) SwaggerDoc() map[string]string { + return map_HorizontalPodAutoscalerCondition +} + +var map_HorizontalPodAutoscalerList = map[string]string{ + "": "HorizontalPodAutoscaler is a list of horizontal pod autoscaler objects.", + "metadata": "metadata is the standard list metadata.", + "items": "items is the list of horizontal pod autoscaler objects.", +} + +func (HorizontalPodAutoscalerList) SwaggerDoc() map[string]string { + return map_HorizontalPodAutoscalerList +} + +var map_HorizontalPodAutoscalerSpec = map[string]string{ + "": "HorizontalPodAutoscalerSpec describes the desired functionality of the HorizontalPodAutoscaler.", + "scaleTargetRef": "scaleTargetRef points to the target resource to scale, and is used to the pods for which metrics should be collected, as well as to actually change the replica count.", + "minReplicas": "minReplicas is the lower limit for the number of replicas to which the autoscaler can scale down. It defaults to 1 pod.", + "maxReplicas": "maxReplicas is the upper limit for the number of replicas to which the autoscaler can scale up. It cannot be less that minReplicas.", + "metrics": "metrics contains the specifications for which to use to calculate the desired replica count (the maximum replica count across all metrics will be used). The desired replica count is calculated multiplying the ratio between the target value and the current value by the current number of pods. Ergo, metrics used must decrease as the pod count is increased, and vice-versa. See the individual metric source types for more information about how each type of metric must respond.", +} + +func (HorizontalPodAutoscalerSpec) SwaggerDoc() map[string]string { + return map_HorizontalPodAutoscalerSpec +} + +var map_HorizontalPodAutoscalerStatus = map[string]string{ + "": "HorizontalPodAutoscalerStatus describes the current status of a horizontal pod autoscaler.", + "observedGeneration": "observedGeneration is the most recent generation observed by this autoscaler.", + "lastScaleTime": "lastScaleTime is the last time the HorizontalPodAutoscaler scaled the number of pods, used by the autoscaler to control how often the number of pods is changed.", + "currentReplicas": "currentReplicas is current number of replicas of pods managed by this autoscaler, as last seen by the autoscaler.", + "desiredReplicas": "desiredReplicas is the desired number of replicas of pods managed by this autoscaler, as last calculated by the autoscaler.", + "currentMetrics": "currentMetrics is the last read state of the metrics used by this autoscaler.", + "conditions": "conditions is the set of conditions required for this autoscaler to scale its target, and indicates whether or not those conditions are met.", +} + +func (HorizontalPodAutoscalerStatus) SwaggerDoc() map[string]string { + return map_HorizontalPodAutoscalerStatus +} + +var map_MetricSpec = map[string]string{ + "": "MetricSpec specifies how to scale based on a single metric (only `type` and one other matching field should be set at once).", + "type": "type is the type of metric source. It should match one of the fields below.", + "object": "object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).", + "pods": "pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", + "resource": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", +} + +func (MetricSpec) SwaggerDoc() map[string]string { + return map_MetricSpec +} + +var map_MetricStatus = map[string]string{ + "": "MetricStatus describes the last-read state of a single metric.", + "type": "type is the type of metric source. It will match one of the fields below.", + "object": "object refers to a metric describing a single kubernetes object (for example, hits-per-second on an Ingress object).", + "pods": "pods refers to a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", + "resource": "resource refers to a resource metric (such as those specified in requests and limits) known to Kubernetes describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", +} + +func (MetricStatus) SwaggerDoc() map[string]string { + return map_MetricStatus +} + +var map_ObjectMetricSource = map[string]string{ + "": "ObjectMetricSource indicates how to scale on a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).", + "target": "target is the described Kubernetes object.", + "metricName": "metricName is the name of the metric in question.", + "targetValue": "targetValue is the target value of the metric (as a quantity).", +} + +func (ObjectMetricSource) SwaggerDoc() map[string]string { + return map_ObjectMetricSource +} + +var map_ObjectMetricStatus = map[string]string{ + "": "ObjectMetricStatus indicates the current value of a metric describing a kubernetes object (for example, hits-per-second on an Ingress object).", + "target": "target is the described Kubernetes object.", + "metricName": "metricName is the name of the metric in question.", + "currentValue": "currentValue is the current value of the metric (as a quantity).", +} + +func (ObjectMetricStatus) SwaggerDoc() map[string]string { + return map_ObjectMetricStatus +} + +var map_PodsMetricSource = map[string]string{ + "": "PodsMetricSource indicates how to scale on a metric describing each pod in the current scale target (for example, transactions-processed-per-second). The values will be averaged together before being compared to the target value.", + "metricName": "metricName is the name of the metric in question", + "targetAverageValue": "targetAverageValue is the target value of the average of the metric across all relevant pods (as a quantity)", +} + +func (PodsMetricSource) SwaggerDoc() map[string]string { + return map_PodsMetricSource +} + +var map_PodsMetricStatus = map[string]string{ + "": "PodsMetricStatus indicates the current value of a metric describing each pod in the current scale target (for example, transactions-processed-per-second).", + "metricName": "metricName is the name of the metric in question", + "currentAverageValue": "currentAverageValue is the current value of the average of the metric across all relevant pods (as a quantity)", +} + +func (PodsMetricStatus) SwaggerDoc() map[string]string { + return map_PodsMetricStatus +} + +var map_ResourceMetricSource = map[string]string{ + "": "ResourceMetricSource indicates how to scale on a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). The values will be averaged together before being compared to the target. Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source. Only one \"target\" type should be set.", + "name": "name is the name of the resource in question.", + "targetAverageUtilization": "targetAverageUtilization is the target value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods.", + "targetAverageValue": "targetAverageValue is the target value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the \"pods\" metric source type.", +} + +func (ResourceMetricSource) SwaggerDoc() map[string]string { + return map_ResourceMetricSource +} + +var map_ResourceMetricStatus = map[string]string{ + "": "ResourceMetricStatus indicates the current value of a resource metric known to Kubernetes, as specified in requests and limits, describing each pod in the current scale target (e.g. CPU or memory). Such metrics are built in to Kubernetes, and have special scaling options on top of those available to normal per-pod metrics using the \"pods\" source.", + "name": "name is the name of the resource in question.", + "currentAverageUtilization": "currentAverageUtilization is the current value of the average of the resource metric across all relevant pods, represented as a percentage of the requested value of the resource for the pods. It will only be present if `targetAverageValue` was set in the corresponding metric specification.", + "currentAverageValue": "currentAverageValue is the current value of the average of the resource metric across all relevant pods, as a raw value (instead of as a percentage of the request), similar to the \"pods\" metric source type. It will always be set, regardless of the corresponding metric specification.", +} + +func (ResourceMetricStatus) SwaggerDoc() map[string]string { + return map_ResourceMetricStatus +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.conversion.go new file mode 100644 index 0000000000..698ff6d1df --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.conversion.go @@ -0,0 +1,449 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v2alpha1 + +import ( + resource "k8s.io/apimachinery/pkg/api/resource" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + api "k8s.io/client-go/pkg/api" + v1 "k8s.io/client-go/pkg/api/v1" + autoscaling "k8s.io/client-go/pkg/apis/autoscaling" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference, + Convert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference, + Convert_v2alpha1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler, + Convert_autoscaling_HorizontalPodAutoscaler_To_v2alpha1_HorizontalPodAutoscaler, + Convert_v2alpha1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition, + Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v2alpha1_HorizontalPodAutoscalerCondition, + Convert_v2alpha1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList, + Convert_autoscaling_HorizontalPodAutoscalerList_To_v2alpha1_HorizontalPodAutoscalerList, + Convert_v2alpha1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec, + Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v2alpha1_HorizontalPodAutoscalerSpec, + Convert_v2alpha1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus, + Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v2alpha1_HorizontalPodAutoscalerStatus, + Convert_v2alpha1_MetricSpec_To_autoscaling_MetricSpec, + Convert_autoscaling_MetricSpec_To_v2alpha1_MetricSpec, + Convert_v2alpha1_MetricStatus_To_autoscaling_MetricStatus, + Convert_autoscaling_MetricStatus_To_v2alpha1_MetricStatus, + Convert_v2alpha1_ObjectMetricSource_To_autoscaling_ObjectMetricSource, + Convert_autoscaling_ObjectMetricSource_To_v2alpha1_ObjectMetricSource, + Convert_v2alpha1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus, + Convert_autoscaling_ObjectMetricStatus_To_v2alpha1_ObjectMetricStatus, + Convert_v2alpha1_PodsMetricSource_To_autoscaling_PodsMetricSource, + Convert_autoscaling_PodsMetricSource_To_v2alpha1_PodsMetricSource, + Convert_v2alpha1_PodsMetricStatus_To_autoscaling_PodsMetricStatus, + Convert_autoscaling_PodsMetricStatus_To_v2alpha1_PodsMetricStatus, + Convert_v2alpha1_ResourceMetricSource_To_autoscaling_ResourceMetricSource, + Convert_autoscaling_ResourceMetricSource_To_v2alpha1_ResourceMetricSource, + Convert_v2alpha1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus, + Convert_autoscaling_ResourceMetricStatus_To_v2alpha1_ResourceMetricStatus, + ) +} + +func autoConvert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(in *CrossVersionObjectReference, out *autoscaling.CrossVersionObjectReference, s conversion.Scope) error { + out.Kind = in.Kind + out.Name = in.Name + out.APIVersion = in.APIVersion + return nil +} + +// Convert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference is an autogenerated conversion function. +func Convert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(in *CrossVersionObjectReference, out *autoscaling.CrossVersionObjectReference, s conversion.Scope) error { + return autoConvert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(in, out, s) +} + +func autoConvert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference(in *autoscaling.CrossVersionObjectReference, out *CrossVersionObjectReference, s conversion.Scope) error { + out.Kind = in.Kind + out.Name = in.Name + out.APIVersion = in.APIVersion + return nil +} + +// Convert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference is an autogenerated conversion function. +func Convert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference(in *autoscaling.CrossVersionObjectReference, out *CrossVersionObjectReference, s conversion.Scope) error { + return autoConvert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference(in, out, s) +} + +func autoConvert_v2alpha1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v2alpha1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v2alpha1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v2alpha1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler is an autogenerated conversion function. +func Convert_v2alpha1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { + return autoConvert_v2alpha1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in, out, s) +} + +func autoConvert_autoscaling_HorizontalPodAutoscaler_To_v2alpha1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v2alpha1_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v2alpha1_HorizontalPodAutoscalerStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_autoscaling_HorizontalPodAutoscaler_To_v2alpha1_HorizontalPodAutoscaler is an autogenerated conversion function. +func Convert_autoscaling_HorizontalPodAutoscaler_To_v2alpha1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { + return autoConvert_autoscaling_HorizontalPodAutoscaler_To_v2alpha1_HorizontalPodAutoscaler(in, out, s) +} + +func autoConvert_v2alpha1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(in *HorizontalPodAutoscalerCondition, out *autoscaling.HorizontalPodAutoscalerCondition, s conversion.Scope) error { + out.Type = autoscaling.HorizontalPodAutoscalerConditionType(in.Type) + out.Status = autoscaling.ConditionStatus(in.Status) + out.LastTransitionTime = in.LastTransitionTime + out.Reason = in.Reason + out.Message = in.Message + return nil +} + +// Convert_v2alpha1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition is an autogenerated conversion function. +func Convert_v2alpha1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(in *HorizontalPodAutoscalerCondition, out *autoscaling.HorizontalPodAutoscalerCondition, s conversion.Scope) error { + return autoConvert_v2alpha1_HorizontalPodAutoscalerCondition_To_autoscaling_HorizontalPodAutoscalerCondition(in, out, s) +} + +func autoConvert_autoscaling_HorizontalPodAutoscalerCondition_To_v2alpha1_HorizontalPodAutoscalerCondition(in *autoscaling.HorizontalPodAutoscalerCondition, out *HorizontalPodAutoscalerCondition, s conversion.Scope) error { + out.Type = HorizontalPodAutoscalerConditionType(in.Type) + out.Status = v1.ConditionStatus(in.Status) + out.LastTransitionTime = in.LastTransitionTime + out.Reason = in.Reason + out.Message = in.Message + return nil +} + +// Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v2alpha1_HorizontalPodAutoscalerCondition is an autogenerated conversion function. +func Convert_autoscaling_HorizontalPodAutoscalerCondition_To_v2alpha1_HorizontalPodAutoscalerCondition(in *autoscaling.HorizontalPodAutoscalerCondition, out *HorizontalPodAutoscalerCondition, s conversion.Scope) error { + return autoConvert_autoscaling_HorizontalPodAutoscalerCondition_To_v2alpha1_HorizontalPodAutoscalerCondition(in, out, s) +} + +func autoConvert_v2alpha1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList, out *autoscaling.HorizontalPodAutoscalerList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]autoscaling.HorizontalPodAutoscaler)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v2alpha1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList is an autogenerated conversion function. +func Convert_v2alpha1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList, out *autoscaling.HorizontalPodAutoscalerList, s conversion.Scope) error { + return autoConvert_v2alpha1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in, out, s) +} + +func autoConvert_autoscaling_HorizontalPodAutoscalerList_To_v2alpha1_HorizontalPodAutoscalerList(in *autoscaling.HorizontalPodAutoscalerList, out *HorizontalPodAutoscalerList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]HorizontalPodAutoscaler, 0) + } else { + out.Items = *(*[]HorizontalPodAutoscaler)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_autoscaling_HorizontalPodAutoscalerList_To_v2alpha1_HorizontalPodAutoscalerList is an autogenerated conversion function. +func Convert_autoscaling_HorizontalPodAutoscalerList_To_v2alpha1_HorizontalPodAutoscalerList(in *autoscaling.HorizontalPodAutoscalerList, out *HorizontalPodAutoscalerList, s conversion.Scope) error { + return autoConvert_autoscaling_HorizontalPodAutoscalerList_To_v2alpha1_HorizontalPodAutoscalerList(in, out, s) +} + +func autoConvert_v2alpha1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in *HorizontalPodAutoscalerSpec, out *autoscaling.HorizontalPodAutoscalerSpec, s conversion.Scope) error { + if err := Convert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(&in.ScaleTargetRef, &out.ScaleTargetRef, s); err != nil { + return err + } + out.MinReplicas = (*int32)(unsafe.Pointer(in.MinReplicas)) + out.MaxReplicas = in.MaxReplicas + out.Metrics = *(*[]autoscaling.MetricSpec)(unsafe.Pointer(&in.Metrics)) + return nil +} + +// Convert_v2alpha1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec is an autogenerated conversion function. +func Convert_v2alpha1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in *HorizontalPodAutoscalerSpec, out *autoscaling.HorizontalPodAutoscalerSpec, s conversion.Scope) error { + return autoConvert_v2alpha1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in, out, s) +} + +func autoConvert_autoscaling_HorizontalPodAutoscalerSpec_To_v2alpha1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { + if err := Convert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference(&in.ScaleTargetRef, &out.ScaleTargetRef, s); err != nil { + return err + } + out.MinReplicas = (*int32)(unsafe.Pointer(in.MinReplicas)) + out.MaxReplicas = in.MaxReplicas + out.Metrics = *(*[]MetricSpec)(unsafe.Pointer(&in.Metrics)) + return nil +} + +// Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v2alpha1_HorizontalPodAutoscalerSpec is an autogenerated conversion function. +func Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v2alpha1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { + return autoConvert_autoscaling_HorizontalPodAutoscalerSpec_To_v2alpha1_HorizontalPodAutoscalerSpec(in, out, s) +} + +func autoConvert_v2alpha1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { + out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) + out.LastScaleTime = (*meta_v1.Time)(unsafe.Pointer(in.LastScaleTime)) + out.CurrentReplicas = in.CurrentReplicas + out.DesiredReplicas = in.DesiredReplicas + out.CurrentMetrics = *(*[]autoscaling.MetricStatus)(unsafe.Pointer(&in.CurrentMetrics)) + out.Conditions = *(*[]autoscaling.HorizontalPodAutoscalerCondition)(unsafe.Pointer(&in.Conditions)) + return nil +} + +// Convert_v2alpha1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus is an autogenerated conversion function. +func Convert_v2alpha1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { + return autoConvert_v2alpha1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in, out, s) +} + +func autoConvert_autoscaling_HorizontalPodAutoscalerStatus_To_v2alpha1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { + out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) + out.LastScaleTime = (*meta_v1.Time)(unsafe.Pointer(in.LastScaleTime)) + out.CurrentReplicas = in.CurrentReplicas + out.DesiredReplicas = in.DesiredReplicas + if in.CurrentMetrics == nil { + out.CurrentMetrics = make([]MetricStatus, 0) + } else { + out.CurrentMetrics = *(*[]MetricStatus)(unsafe.Pointer(&in.CurrentMetrics)) + } + if in.Conditions == nil { + out.Conditions = make([]HorizontalPodAutoscalerCondition, 0) + } else { + out.Conditions = *(*[]HorizontalPodAutoscalerCondition)(unsafe.Pointer(&in.Conditions)) + } + return nil +} + +// Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v2alpha1_HorizontalPodAutoscalerStatus is an autogenerated conversion function. +func Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v2alpha1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { + return autoConvert_autoscaling_HorizontalPodAutoscalerStatus_To_v2alpha1_HorizontalPodAutoscalerStatus(in, out, s) +} + +func autoConvert_v2alpha1_MetricSpec_To_autoscaling_MetricSpec(in *MetricSpec, out *autoscaling.MetricSpec, s conversion.Scope) error { + out.Type = autoscaling.MetricSourceType(in.Type) + out.Object = (*autoscaling.ObjectMetricSource)(unsafe.Pointer(in.Object)) + out.Pods = (*autoscaling.PodsMetricSource)(unsafe.Pointer(in.Pods)) + out.Resource = (*autoscaling.ResourceMetricSource)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_v2alpha1_MetricSpec_To_autoscaling_MetricSpec is an autogenerated conversion function. +func Convert_v2alpha1_MetricSpec_To_autoscaling_MetricSpec(in *MetricSpec, out *autoscaling.MetricSpec, s conversion.Scope) error { + return autoConvert_v2alpha1_MetricSpec_To_autoscaling_MetricSpec(in, out, s) +} + +func autoConvert_autoscaling_MetricSpec_To_v2alpha1_MetricSpec(in *autoscaling.MetricSpec, out *MetricSpec, s conversion.Scope) error { + out.Type = MetricSourceType(in.Type) + out.Object = (*ObjectMetricSource)(unsafe.Pointer(in.Object)) + out.Pods = (*PodsMetricSource)(unsafe.Pointer(in.Pods)) + out.Resource = (*ResourceMetricSource)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_autoscaling_MetricSpec_To_v2alpha1_MetricSpec is an autogenerated conversion function. +func Convert_autoscaling_MetricSpec_To_v2alpha1_MetricSpec(in *autoscaling.MetricSpec, out *MetricSpec, s conversion.Scope) error { + return autoConvert_autoscaling_MetricSpec_To_v2alpha1_MetricSpec(in, out, s) +} + +func autoConvert_v2alpha1_MetricStatus_To_autoscaling_MetricStatus(in *MetricStatus, out *autoscaling.MetricStatus, s conversion.Scope) error { + out.Type = autoscaling.MetricSourceType(in.Type) + out.Object = (*autoscaling.ObjectMetricStatus)(unsafe.Pointer(in.Object)) + out.Pods = (*autoscaling.PodsMetricStatus)(unsafe.Pointer(in.Pods)) + out.Resource = (*autoscaling.ResourceMetricStatus)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_v2alpha1_MetricStatus_To_autoscaling_MetricStatus is an autogenerated conversion function. +func Convert_v2alpha1_MetricStatus_To_autoscaling_MetricStatus(in *MetricStatus, out *autoscaling.MetricStatus, s conversion.Scope) error { + return autoConvert_v2alpha1_MetricStatus_To_autoscaling_MetricStatus(in, out, s) +} + +func autoConvert_autoscaling_MetricStatus_To_v2alpha1_MetricStatus(in *autoscaling.MetricStatus, out *MetricStatus, s conversion.Scope) error { + out.Type = MetricSourceType(in.Type) + out.Object = (*ObjectMetricStatus)(unsafe.Pointer(in.Object)) + out.Pods = (*PodsMetricStatus)(unsafe.Pointer(in.Pods)) + out.Resource = (*ResourceMetricStatus)(unsafe.Pointer(in.Resource)) + return nil +} + +// Convert_autoscaling_MetricStatus_To_v2alpha1_MetricStatus is an autogenerated conversion function. +func Convert_autoscaling_MetricStatus_To_v2alpha1_MetricStatus(in *autoscaling.MetricStatus, out *MetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_MetricStatus_To_v2alpha1_MetricStatus(in, out, s) +} + +func autoConvert_v2alpha1_ObjectMetricSource_To_autoscaling_ObjectMetricSource(in *ObjectMetricSource, out *autoscaling.ObjectMetricSource, s conversion.Scope) error { + if err := Convert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.TargetValue = in.TargetValue + return nil +} + +// Convert_v2alpha1_ObjectMetricSource_To_autoscaling_ObjectMetricSource is an autogenerated conversion function. +func Convert_v2alpha1_ObjectMetricSource_To_autoscaling_ObjectMetricSource(in *ObjectMetricSource, out *autoscaling.ObjectMetricSource, s conversion.Scope) error { + return autoConvert_v2alpha1_ObjectMetricSource_To_autoscaling_ObjectMetricSource(in, out, s) +} + +func autoConvert_autoscaling_ObjectMetricSource_To_v2alpha1_ObjectMetricSource(in *autoscaling.ObjectMetricSource, out *ObjectMetricSource, s conversion.Scope) error { + if err := Convert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.TargetValue = in.TargetValue + return nil +} + +// Convert_autoscaling_ObjectMetricSource_To_v2alpha1_ObjectMetricSource is an autogenerated conversion function. +func Convert_autoscaling_ObjectMetricSource_To_v2alpha1_ObjectMetricSource(in *autoscaling.ObjectMetricSource, out *ObjectMetricSource, s conversion.Scope) error { + return autoConvert_autoscaling_ObjectMetricSource_To_v2alpha1_ObjectMetricSource(in, out, s) +} + +func autoConvert_v2alpha1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus(in *ObjectMetricStatus, out *autoscaling.ObjectMetricStatus, s conversion.Scope) error { + if err := Convert_v2alpha1_CrossVersionObjectReference_To_autoscaling_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.CurrentValue = in.CurrentValue + return nil +} + +// Convert_v2alpha1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus is an autogenerated conversion function. +func Convert_v2alpha1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus(in *ObjectMetricStatus, out *autoscaling.ObjectMetricStatus, s conversion.Scope) error { + return autoConvert_v2alpha1_ObjectMetricStatus_To_autoscaling_ObjectMetricStatus(in, out, s) +} + +func autoConvert_autoscaling_ObjectMetricStatus_To_v2alpha1_ObjectMetricStatus(in *autoscaling.ObjectMetricStatus, out *ObjectMetricStatus, s conversion.Scope) error { + if err := Convert_autoscaling_CrossVersionObjectReference_To_v2alpha1_CrossVersionObjectReference(&in.Target, &out.Target, s); err != nil { + return err + } + out.MetricName = in.MetricName + out.CurrentValue = in.CurrentValue + return nil +} + +// Convert_autoscaling_ObjectMetricStatus_To_v2alpha1_ObjectMetricStatus is an autogenerated conversion function. +func Convert_autoscaling_ObjectMetricStatus_To_v2alpha1_ObjectMetricStatus(in *autoscaling.ObjectMetricStatus, out *ObjectMetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_ObjectMetricStatus_To_v2alpha1_ObjectMetricStatus(in, out, s) +} + +func autoConvert_v2alpha1_PodsMetricSource_To_autoscaling_PodsMetricSource(in *PodsMetricSource, out *autoscaling.PodsMetricSource, s conversion.Scope) error { + out.MetricName = in.MetricName + out.TargetAverageValue = in.TargetAverageValue + return nil +} + +// Convert_v2alpha1_PodsMetricSource_To_autoscaling_PodsMetricSource is an autogenerated conversion function. +func Convert_v2alpha1_PodsMetricSource_To_autoscaling_PodsMetricSource(in *PodsMetricSource, out *autoscaling.PodsMetricSource, s conversion.Scope) error { + return autoConvert_v2alpha1_PodsMetricSource_To_autoscaling_PodsMetricSource(in, out, s) +} + +func autoConvert_autoscaling_PodsMetricSource_To_v2alpha1_PodsMetricSource(in *autoscaling.PodsMetricSource, out *PodsMetricSource, s conversion.Scope) error { + out.MetricName = in.MetricName + out.TargetAverageValue = in.TargetAverageValue + return nil +} + +// Convert_autoscaling_PodsMetricSource_To_v2alpha1_PodsMetricSource is an autogenerated conversion function. +func Convert_autoscaling_PodsMetricSource_To_v2alpha1_PodsMetricSource(in *autoscaling.PodsMetricSource, out *PodsMetricSource, s conversion.Scope) error { + return autoConvert_autoscaling_PodsMetricSource_To_v2alpha1_PodsMetricSource(in, out, s) +} + +func autoConvert_v2alpha1_PodsMetricStatus_To_autoscaling_PodsMetricStatus(in *PodsMetricStatus, out *autoscaling.PodsMetricStatus, s conversion.Scope) error { + out.MetricName = in.MetricName + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_v2alpha1_PodsMetricStatus_To_autoscaling_PodsMetricStatus is an autogenerated conversion function. +func Convert_v2alpha1_PodsMetricStatus_To_autoscaling_PodsMetricStatus(in *PodsMetricStatus, out *autoscaling.PodsMetricStatus, s conversion.Scope) error { + return autoConvert_v2alpha1_PodsMetricStatus_To_autoscaling_PodsMetricStatus(in, out, s) +} + +func autoConvert_autoscaling_PodsMetricStatus_To_v2alpha1_PodsMetricStatus(in *autoscaling.PodsMetricStatus, out *PodsMetricStatus, s conversion.Scope) error { + out.MetricName = in.MetricName + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_autoscaling_PodsMetricStatus_To_v2alpha1_PodsMetricStatus is an autogenerated conversion function. +func Convert_autoscaling_PodsMetricStatus_To_v2alpha1_PodsMetricStatus(in *autoscaling.PodsMetricStatus, out *PodsMetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_PodsMetricStatus_To_v2alpha1_PodsMetricStatus(in, out, s) +} + +func autoConvert_v2alpha1_ResourceMetricSource_To_autoscaling_ResourceMetricSource(in *ResourceMetricSource, out *autoscaling.ResourceMetricSource, s conversion.Scope) error { + out.Name = api.ResourceName(in.Name) + out.TargetAverageUtilization = (*int32)(unsafe.Pointer(in.TargetAverageUtilization)) + out.TargetAverageValue = (*resource.Quantity)(unsafe.Pointer(in.TargetAverageValue)) + return nil +} + +// Convert_v2alpha1_ResourceMetricSource_To_autoscaling_ResourceMetricSource is an autogenerated conversion function. +func Convert_v2alpha1_ResourceMetricSource_To_autoscaling_ResourceMetricSource(in *ResourceMetricSource, out *autoscaling.ResourceMetricSource, s conversion.Scope) error { + return autoConvert_v2alpha1_ResourceMetricSource_To_autoscaling_ResourceMetricSource(in, out, s) +} + +func autoConvert_autoscaling_ResourceMetricSource_To_v2alpha1_ResourceMetricSource(in *autoscaling.ResourceMetricSource, out *ResourceMetricSource, s conversion.Scope) error { + out.Name = v1.ResourceName(in.Name) + out.TargetAverageUtilization = (*int32)(unsafe.Pointer(in.TargetAverageUtilization)) + out.TargetAverageValue = (*resource.Quantity)(unsafe.Pointer(in.TargetAverageValue)) + return nil +} + +// Convert_autoscaling_ResourceMetricSource_To_v2alpha1_ResourceMetricSource is an autogenerated conversion function. +func Convert_autoscaling_ResourceMetricSource_To_v2alpha1_ResourceMetricSource(in *autoscaling.ResourceMetricSource, out *ResourceMetricSource, s conversion.Scope) error { + return autoConvert_autoscaling_ResourceMetricSource_To_v2alpha1_ResourceMetricSource(in, out, s) +} + +func autoConvert_v2alpha1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus(in *ResourceMetricStatus, out *autoscaling.ResourceMetricStatus, s conversion.Scope) error { + out.Name = api.ResourceName(in.Name) + out.CurrentAverageUtilization = (*int32)(unsafe.Pointer(in.CurrentAverageUtilization)) + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_v2alpha1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus is an autogenerated conversion function. +func Convert_v2alpha1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus(in *ResourceMetricStatus, out *autoscaling.ResourceMetricStatus, s conversion.Scope) error { + return autoConvert_v2alpha1_ResourceMetricStatus_To_autoscaling_ResourceMetricStatus(in, out, s) +} + +func autoConvert_autoscaling_ResourceMetricStatus_To_v2alpha1_ResourceMetricStatus(in *autoscaling.ResourceMetricStatus, out *ResourceMetricStatus, s conversion.Scope) error { + out.Name = v1.ResourceName(in.Name) + out.CurrentAverageUtilization = (*int32)(unsafe.Pointer(in.CurrentAverageUtilization)) + out.CurrentAverageValue = in.CurrentAverageValue + return nil +} + +// Convert_autoscaling_ResourceMetricStatus_To_v2alpha1_ResourceMetricStatus is an autogenerated conversion function. +func Convert_autoscaling_ResourceMetricStatus_To_v2alpha1_ResourceMetricStatus(in *autoscaling.ResourceMetricStatus, out *ResourceMetricStatus, s conversion.Scope) error { + return autoConvert_autoscaling_ResourceMetricStatus_To_v2alpha1_ResourceMetricStatus(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..9a9dd690e8 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.deepcopy.go @@ -0,0 +1,319 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v2alpha1 + +import ( + resource "k8s.io/apimachinery/pkg/api/resource" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_CrossVersionObjectReference, InType: reflect.TypeOf(&CrossVersionObjectReference{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_HorizontalPodAutoscaler, InType: reflect.TypeOf(&HorizontalPodAutoscaler{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_HorizontalPodAutoscalerCondition, InType: reflect.TypeOf(&HorizontalPodAutoscalerCondition{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_HorizontalPodAutoscalerList, InType: reflect.TypeOf(&HorizontalPodAutoscalerList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_HorizontalPodAutoscalerSpec, InType: reflect.TypeOf(&HorizontalPodAutoscalerSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_HorizontalPodAutoscalerStatus, InType: reflect.TypeOf(&HorizontalPodAutoscalerStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_MetricSpec, InType: reflect.TypeOf(&MetricSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_MetricStatus, InType: reflect.TypeOf(&MetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_ObjectMetricSource, InType: reflect.TypeOf(&ObjectMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_ObjectMetricStatus, InType: reflect.TypeOf(&ObjectMetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_PodsMetricSource, InType: reflect.TypeOf(&PodsMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_PodsMetricStatus, InType: reflect.TypeOf(&PodsMetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_ResourceMetricSource, InType: reflect.TypeOf(&ResourceMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_ResourceMetricStatus, InType: reflect.TypeOf(&ResourceMetricStatus{})}, + ) +} + +// DeepCopy_v2alpha1_CrossVersionObjectReference is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_CrossVersionObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*CrossVersionObjectReference) + out := out.(*CrossVersionObjectReference) + *out = *in + return nil + } +} + +// DeepCopy_v2alpha1_HorizontalPodAutoscaler is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_HorizontalPodAutoscaler(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscaler) + out := out.(*HorizontalPodAutoscaler) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_v2alpha1_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + if err := DeepCopy_v2alpha1_HorizontalPodAutoscalerStatus(&in.Status, &out.Status, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v2alpha1_HorizontalPodAutoscalerCondition is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_HorizontalPodAutoscalerCondition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscalerCondition) + out := out.(*HorizontalPodAutoscalerCondition) + *out = *in + out.LastTransitionTime = in.LastTransitionTime.DeepCopy() + return nil + } +} + +// DeepCopy_v2alpha1_HorizontalPodAutoscalerList is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_HorizontalPodAutoscalerList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscalerList) + out := out.(*HorizontalPodAutoscalerList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]HorizontalPodAutoscaler, len(*in)) + for i := range *in { + if err := DeepCopy_v2alpha1_HorizontalPodAutoscaler(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v2alpha1_HorizontalPodAutoscalerSpec is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_HorizontalPodAutoscalerSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscalerSpec) + out := out.(*HorizontalPodAutoscalerSpec) + *out = *in + if in.MinReplicas != nil { + in, out := &in.MinReplicas, &out.MinReplicas + *out = new(int32) + **out = **in + } + if in.Metrics != nil { + in, out := &in.Metrics, &out.Metrics + *out = make([]MetricSpec, len(*in)) + for i := range *in { + if err := DeepCopy_v2alpha1_MetricSpec(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v2alpha1_HorizontalPodAutoscalerStatus is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_HorizontalPodAutoscalerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscalerStatus) + out := out.(*HorizontalPodAutoscalerStatus) + *out = *in + if in.ObservedGeneration != nil { + in, out := &in.ObservedGeneration, &out.ObservedGeneration + *out = new(int64) + **out = **in + } + if in.LastScaleTime != nil { + in, out := &in.LastScaleTime, &out.LastScaleTime + *out = new(v1.Time) + **out = (*in).DeepCopy() + } + if in.CurrentMetrics != nil { + in, out := &in.CurrentMetrics, &out.CurrentMetrics + *out = make([]MetricStatus, len(*in)) + for i := range *in { + if err := DeepCopy_v2alpha1_MetricStatus(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]HorizontalPodAutoscalerCondition, len(*in)) + for i := range *in { + if err := DeepCopy_v2alpha1_HorizontalPodAutoscalerCondition(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v2alpha1_MetricSpec is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_MetricSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MetricSpec) + out := out.(*MetricSpec) + *out = *in + if in.Object != nil { + in, out := &in.Object, &out.Object + *out = new(ObjectMetricSource) + if err := DeepCopy_v2alpha1_ObjectMetricSource(*in, *out, c); err != nil { + return err + } + } + if in.Pods != nil { + in, out := &in.Pods, &out.Pods + *out = new(PodsMetricSource) + if err := DeepCopy_v2alpha1_PodsMetricSource(*in, *out, c); err != nil { + return err + } + } + if in.Resource != nil { + in, out := &in.Resource, &out.Resource + *out = new(ResourceMetricSource) + if err := DeepCopy_v2alpha1_ResourceMetricSource(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v2alpha1_MetricStatus is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_MetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MetricStatus) + out := out.(*MetricStatus) + *out = *in + if in.Object != nil { + in, out := &in.Object, &out.Object + *out = new(ObjectMetricStatus) + if err := DeepCopy_v2alpha1_ObjectMetricStatus(*in, *out, c); err != nil { + return err + } + } + if in.Pods != nil { + in, out := &in.Pods, &out.Pods + *out = new(PodsMetricStatus) + if err := DeepCopy_v2alpha1_PodsMetricStatus(*in, *out, c); err != nil { + return err + } + } + if in.Resource != nil { + in, out := &in.Resource, &out.Resource + *out = new(ResourceMetricStatus) + if err := DeepCopy_v2alpha1_ResourceMetricStatus(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v2alpha1_ObjectMetricSource is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_ObjectMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMetricSource) + out := out.(*ObjectMetricSource) + *out = *in + out.TargetValue = in.TargetValue.DeepCopy() + return nil + } +} + +// DeepCopy_v2alpha1_ObjectMetricStatus is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_ObjectMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMetricStatus) + out := out.(*ObjectMetricStatus) + *out = *in + out.CurrentValue = in.CurrentValue.DeepCopy() + return nil + } +} + +// DeepCopy_v2alpha1_PodsMetricSource is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_PodsMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodsMetricSource) + out := out.(*PodsMetricSource) + *out = *in + out.TargetAverageValue = in.TargetAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_v2alpha1_PodsMetricStatus is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_PodsMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodsMetricStatus) + out := out.(*PodsMetricStatus) + *out = *in + out.CurrentAverageValue = in.CurrentAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_v2alpha1_ResourceMetricSource is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_ResourceMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceMetricSource) + out := out.(*ResourceMetricSource) + *out = *in + if in.TargetAverageUtilization != nil { + in, out := &in.TargetAverageUtilization, &out.TargetAverageUtilization + *out = new(int32) + **out = **in + } + if in.TargetAverageValue != nil { + in, out := &in.TargetAverageValue, &out.TargetAverageValue + *out = new(resource.Quantity) + **out = (*in).DeepCopy() + } + return nil + } +} + +// DeepCopy_v2alpha1_ResourceMetricStatus is an autogenerated deepcopy function. +func DeepCopy_v2alpha1_ResourceMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceMetricStatus) + out := out.(*ResourceMetricStatus) + *out = *in + if in.CurrentAverageUtilization != nil { + in, out := &in.CurrentAverageUtilization, &out.CurrentAverageUtilization + *out = new(int32) + **out = **in + } + out.CurrentAverageValue = in.CurrentAverageValue.DeepCopy() + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.defaults.go new file mode 100644 index 0000000000..eb20be97c7 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/v2alpha1/zz_generated.defaults.go @@ -0,0 +1,47 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v2alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&HorizontalPodAutoscaler{}, func(obj interface{}) { SetObjectDefaults_HorizontalPodAutoscaler(obj.(*HorizontalPodAutoscaler)) }) + scheme.AddTypeDefaultingFunc(&HorizontalPodAutoscalerList{}, func(obj interface{}) { + SetObjectDefaults_HorizontalPodAutoscalerList(obj.(*HorizontalPodAutoscalerList)) + }) + return nil +} + +func SetObjectDefaults_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler) { + SetDefaults_HorizontalPodAutoscaler(in) +} + +func SetObjectDefaults_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_HorizontalPodAutoscaler(a) + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/autoscaling/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/autoscaling/zz_generated.deepcopy.go index fd3adc42d9..a15d9b32ba 100644 --- a/vendor/k8s.io/client-go/pkg/apis/autoscaling/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/autoscaling/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package autoscaling import ( - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + resource "k8s.io/apimachinery/pkg/api/resource" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -38,33 +38,44 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_CrossVersionObjectReference, InType: reflect.TypeOf(&CrossVersionObjectReference{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_HorizontalPodAutoscaler, InType: reflect.TypeOf(&HorizontalPodAutoscaler{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_HorizontalPodAutoscalerCondition, InType: reflect.TypeOf(&HorizontalPodAutoscalerCondition{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_HorizontalPodAutoscalerList, InType: reflect.TypeOf(&HorizontalPodAutoscalerList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_HorizontalPodAutoscalerSpec, InType: reflect.TypeOf(&HorizontalPodAutoscalerSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_HorizontalPodAutoscalerStatus, InType: reflect.TypeOf(&HorizontalPodAutoscalerStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_MetricSpec, InType: reflect.TypeOf(&MetricSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_MetricStatus, InType: reflect.TypeOf(&MetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_ObjectMetricSource, InType: reflect.TypeOf(&ObjectMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_ObjectMetricStatus, InType: reflect.TypeOf(&ObjectMetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_PodsMetricSource, InType: reflect.TypeOf(&PodsMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_PodsMetricStatus, InType: reflect.TypeOf(&PodsMetricStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_ResourceMetricSource, InType: reflect.TypeOf(&ResourceMetricSource{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_ResourceMetricStatus, InType: reflect.TypeOf(&ResourceMetricStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_Scale, InType: reflect.TypeOf(&Scale{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_ScaleSpec, InType: reflect.TypeOf(&ScaleSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_autoscaling_ScaleStatus, InType: reflect.TypeOf(&ScaleStatus{})}, ) } +// DeepCopy_autoscaling_CrossVersionObjectReference is an autogenerated deepcopy function. func DeepCopy_autoscaling_CrossVersionObjectReference(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CrossVersionObjectReference) out := out.(*CrossVersionObjectReference) - out.Kind = in.Kind - out.Name = in.Name - out.APIVersion = in.APIVersion + *out = *in return nil } } +// DeepCopy_autoscaling_HorizontalPodAutoscaler is an autogenerated deepcopy function. func DeepCopy_autoscaling_HorizontalPodAutoscaler(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscaler) out := out.(*HorizontalPodAutoscaler) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_autoscaling_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -76,12 +87,23 @@ func DeepCopy_autoscaling_HorizontalPodAutoscaler(in interface{}, out interface{ } } +// DeepCopy_autoscaling_HorizontalPodAutoscalerCondition is an autogenerated deepcopy function. +func DeepCopy_autoscaling_HorizontalPodAutoscalerCondition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*HorizontalPodAutoscalerCondition) + out := out.(*HorizontalPodAutoscalerCondition) + *out = *in + out.LastTransitionTime = in.LastTransitionTime.DeepCopy() + return nil + } +} + +// DeepCopy_autoscaling_HorizontalPodAutoscalerList is an autogenerated deepcopy function. func DeepCopy_autoscaling_HorizontalPodAutoscalerList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscalerList) out := out.(*HorizontalPodAutoscalerList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]HorizontalPodAutoscaler, len(*in)) @@ -90,97 +112,246 @@ func DeepCopy_autoscaling_HorizontalPodAutoscalerList(in interface{}, out interf return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_autoscaling_HorizontalPodAutoscalerSpec is an autogenerated deepcopy function. func DeepCopy_autoscaling_HorizontalPodAutoscalerSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscalerSpec) out := out.(*HorizontalPodAutoscalerSpec) - out.ScaleTargetRef = in.ScaleTargetRef + *out = *in if in.MinReplicas != nil { in, out := &in.MinReplicas, &out.MinReplicas *out = new(int32) **out = **in - } else { - out.MinReplicas = nil } - out.MaxReplicas = in.MaxReplicas - if in.TargetCPUUtilizationPercentage != nil { - in, out := &in.TargetCPUUtilizationPercentage, &out.TargetCPUUtilizationPercentage - *out = new(int32) - **out = **in - } else { - out.TargetCPUUtilizationPercentage = nil + if in.Metrics != nil { + in, out := &in.Metrics, &out.Metrics + *out = make([]MetricSpec, len(*in)) + for i := range *in { + if err := DeepCopy_autoscaling_MetricSpec(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } } return nil } } +// DeepCopy_autoscaling_HorizontalPodAutoscalerStatus is an autogenerated deepcopy function. func DeepCopy_autoscaling_HorizontalPodAutoscalerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HorizontalPodAutoscalerStatus) out := out.(*HorizontalPodAutoscalerStatus) + *out = *in if in.ObservedGeneration != nil { in, out := &in.ObservedGeneration, &out.ObservedGeneration *out = new(int64) **out = **in - } else { - out.ObservedGeneration = nil } if in.LastScaleTime != nil { in, out := &in.LastScaleTime, &out.LastScaleTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.LastScaleTime = nil } - out.CurrentReplicas = in.CurrentReplicas - out.DesiredReplicas = in.DesiredReplicas - if in.CurrentCPUUtilizationPercentage != nil { - in, out := &in.CurrentCPUUtilizationPercentage, &out.CurrentCPUUtilizationPercentage + if in.CurrentMetrics != nil { + in, out := &in.CurrentMetrics, &out.CurrentMetrics + *out = make([]MetricStatus, len(*in)) + for i := range *in { + if err := DeepCopy_autoscaling_MetricStatus(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]HorizontalPodAutoscalerCondition, len(*in)) + for i := range *in { + if err := DeepCopy_autoscaling_HorizontalPodAutoscalerCondition(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_autoscaling_MetricSpec is an autogenerated deepcopy function. +func DeepCopy_autoscaling_MetricSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MetricSpec) + out := out.(*MetricSpec) + *out = *in + if in.Object != nil { + in, out := &in.Object, &out.Object + *out = new(ObjectMetricSource) + if err := DeepCopy_autoscaling_ObjectMetricSource(*in, *out, c); err != nil { + return err + } + } + if in.Pods != nil { + in, out := &in.Pods, &out.Pods + *out = new(PodsMetricSource) + if err := DeepCopy_autoscaling_PodsMetricSource(*in, *out, c); err != nil { + return err + } + } + if in.Resource != nil { + in, out := &in.Resource, &out.Resource + *out = new(ResourceMetricSource) + if err := DeepCopy_autoscaling_ResourceMetricSource(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_autoscaling_MetricStatus is an autogenerated deepcopy function. +func DeepCopy_autoscaling_MetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*MetricStatus) + out := out.(*MetricStatus) + *out = *in + if in.Object != nil { + in, out := &in.Object, &out.Object + *out = new(ObjectMetricStatus) + if err := DeepCopy_autoscaling_ObjectMetricStatus(*in, *out, c); err != nil { + return err + } + } + if in.Pods != nil { + in, out := &in.Pods, &out.Pods + *out = new(PodsMetricStatus) + if err := DeepCopy_autoscaling_PodsMetricStatus(*in, *out, c); err != nil { + return err + } + } + if in.Resource != nil { + in, out := &in.Resource, &out.Resource + *out = new(ResourceMetricStatus) + if err := DeepCopy_autoscaling_ResourceMetricStatus(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_autoscaling_ObjectMetricSource is an autogenerated deepcopy function. +func DeepCopy_autoscaling_ObjectMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMetricSource) + out := out.(*ObjectMetricSource) + *out = *in + out.TargetValue = in.TargetValue.DeepCopy() + return nil + } +} + +// DeepCopy_autoscaling_ObjectMetricStatus is an autogenerated deepcopy function. +func DeepCopy_autoscaling_ObjectMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ObjectMetricStatus) + out := out.(*ObjectMetricStatus) + *out = *in + out.CurrentValue = in.CurrentValue.DeepCopy() + return nil + } +} + +// DeepCopy_autoscaling_PodsMetricSource is an autogenerated deepcopy function. +func DeepCopy_autoscaling_PodsMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodsMetricSource) + out := out.(*PodsMetricSource) + *out = *in + out.TargetAverageValue = in.TargetAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_autoscaling_PodsMetricStatus is an autogenerated deepcopy function. +func DeepCopy_autoscaling_PodsMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodsMetricStatus) + out := out.(*PodsMetricStatus) + *out = *in + out.CurrentAverageValue = in.CurrentAverageValue.DeepCopy() + return nil + } +} + +// DeepCopy_autoscaling_ResourceMetricSource is an autogenerated deepcopy function. +func DeepCopy_autoscaling_ResourceMetricSource(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceMetricSource) + out := out.(*ResourceMetricSource) + *out = *in + if in.TargetAverageUtilization != nil { + in, out := &in.TargetAverageUtilization, &out.TargetAverageUtilization *out = new(int32) **out = **in - } else { - out.CurrentCPUUtilizationPercentage = nil } + if in.TargetAverageValue != nil { + in, out := &in.TargetAverageValue, &out.TargetAverageValue + *out = new(resource.Quantity) + **out = (*in).DeepCopy() + } + return nil + } +} + +// DeepCopy_autoscaling_ResourceMetricStatus is an autogenerated deepcopy function. +func DeepCopy_autoscaling_ResourceMetricStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ResourceMetricStatus) + out := out.(*ResourceMetricStatus) + *out = *in + if in.CurrentAverageUtilization != nil { + in, out := &in.CurrentAverageUtilization, &out.CurrentAverageUtilization + *out = new(int32) + **out = **in + } + out.CurrentAverageValue = in.CurrentAverageValue.DeepCopy() return nil } } +// DeepCopy_autoscaling_Scale is an autogenerated deepcopy function. func DeepCopy_autoscaling_Scale(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Scale) out := out.(*Scale) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Spec = in.Spec - out.Status = in.Status return nil } } +// DeepCopy_autoscaling_ScaleSpec is an autogenerated deepcopy function. func DeepCopy_autoscaling_ScaleSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleSpec) out := out.(*ScaleSpec) - out.Replicas = in.Replicas + *out = *in return nil } } +// DeepCopy_autoscaling_ScaleStatus is an autogenerated deepcopy function. func DeepCopy_autoscaling_ScaleStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleStatus) out := out.(*ScaleStatus) - out.Replicas = in.Replicas - out.Selector = in.Selector + *out = *in return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/BUILD b/vendor/k8s.io/client-go/pkg/apis/batch/BUILD new file mode 100644 index 0000000000..f0ff3f2ce1 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/batch/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/OWNERS b/vendor/k8s.io/client-go/pkg/apis/batch/OWNERS new file mode 100755 index 0000000000..502f907711 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/batch/OWNERS @@ -0,0 +1,19 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- caesarxuchao +- erictune +- sttts +- saad-ali +- ncdc +- timothysc +- soltysh +- dims +- errordeveloper +- mml +- mbohlool +- david-mcmahon +- jianhuiz diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/doc.go b/vendor/k8s.io/client-go/pkg/apis/batch/doc.go index f8774e80ad..6fe9522260 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/doc.go @@ -14,7 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - package batch diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/install/install.go b/vendor/k8s.io/client-go/pkg/apis/batch/install/install.go deleted file mode 100644 index 6d511f6d5e..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/batch/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the batch API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/batch" - "k8s.io/client-go/pkg/apis/batch/v1" - "k8s.io/client-go/pkg/apis/batch/v2alpha1" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: batch.GroupName, - VersionPreferenceOrder: []string{v1.SchemeGroupVersion.Version, v2alpha1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/batch", - AddInternalObjectsToScheme: batch.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1.SchemeGroupVersion.Version: v1.AddToScheme, - v2alpha1.SchemeGroupVersion.Version: v2alpha1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/register.go b/vendor/k8s.io/client-go/pkg/apis/batch/register.go index 792f057c3f..4601ca4ec1 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/register.go @@ -17,24 +17,23 @@ limitations under the License. package batch import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "batch" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -51,7 +50,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { &JobTemplate{}, &CronJob{}, &CronJobList{}, - &api.ListOptions{}, ) scheme.AddKnownTypeWithName(SchemeGroupVersion.WithKind("ScheduledJob"), &CronJob{}) scheme.AddKnownTypeWithName(SchemeGroupVersion.WithKind("ScheduledJobList"), &CronJobList{}) diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/batch/types.generated.go deleted file mode 100644 index 35a82920f5..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/batch/types.generated.go +++ /dev/null @@ -1,4676 +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 batch - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/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 pkg2_api.ObjectMeta - var v1 pkg4_resource.Quantity - var v2 pkg1_unversioned.TypeMeta - var v3 pkg3_types.UID - var v4 pkg5_intstr.IntOrString - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 - } -} - -func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = true - yyq2[3] = true - yyq2[4] = true - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl19, d) - } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl19, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = JobStatus{} - } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = JobStatus{} - } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [4]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Kind != "" - yyq33[1] = x.APIVersion != "" - yyq33[2] = true - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(4) - } else { - yynn33 = 1 - for _, b := range yyq33 { - if b { - yynn33++ - } - } - r.EncodeMapStart(yynn33) - yynn33 = 0 - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[2] { - yy41 := &x.ListMeta - yym42 := z.EncBinary() - _ = yym42 - if false { - } else if z.HasExtensions() && z.EncExt(yy41) { - } else { - z.EncFallback(yy41) - } - } else { - r.EncodeNil() - } - } else { - if yyq33[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy43 := &x.ListMeta - yym44 := z.EncBinary() - _ = yym44 - if false { - } else if z.HasExtensions() && z.EncExt(yy43) { - } else { - z.EncFallback(yy43) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - h.encSliceJob(([]Job)(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 { - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - h.encSliceJob(([]Job)(x.Items), e) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym48 := z.DecBinary() - _ = yym48 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct49 := r.ContainerType() - if yyct49 == codecSelferValueTypeMap1234 { - yyl49 := r.ReadMapStart() - if yyl49 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl49, d) - } - } else if yyct49 == codecSelferValueTypeArray1234 { - yyl49 := r.ReadArrayStart() - if yyl49 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl49, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys50Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys50Slc - var yyhl50 bool = l >= 0 - for yyj50 := 0; ; yyj50++ { - if yyhl50 { - if yyj50 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys50Slc = r.DecodeBytes(yys50Slc, true, true) - yys50 := string(yys50Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys50 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv53 := &x.ListMeta - yym54 := z.DecBinary() - _ = yym54 - if false { - } else if z.HasExtensions() && z.DecExt(yyv53) { - } else { - z.DecFallback(yyv53, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv55 := &x.Items - yym56 := z.DecBinary() - _ = yym56 - if false { - } else { - h.decSliceJob((*[]Job)(yyv55), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys50) - } // end switch yys50 - } // end for yyj50 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj57 int - var yyb57 bool - var yyhl57 bool = l >= 0 - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l - } else { - yyb57 = r.CheckBreak() - } - if yyb57 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l - } else { - yyb57 = r.CheckBreak() - } - if yyb57 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l - } else { - yyb57 = r.CheckBreak() - } - if yyb57 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv60 := &x.ListMeta - yym61 := z.DecBinary() - _ = yym61 - if false { - } else if z.HasExtensions() && z.DecExt(yyv60) { - } else { - z.DecFallback(yyv60, false) - } - } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l - } else { - yyb57 = r.CheckBreak() - } - if yyb57 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv62 := &x.Items - yym63 := z.DecBinary() - _ = yym63 - if false { - } else { - h.decSliceJob((*[]Job)(yyv62), d) - } - } - for { - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l - } else { - yyb57 = r.CheckBreak() - } - if yyb57 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj57-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobTemplate) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym64 := z.EncBinary() - _ = yym64 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep65 := !z.EncBinary() - yy2arr65 := z.EncBasicHandle().StructToArray - var yyq65 [4]bool - _, _, _ = yysep65, yyq65, yy2arr65 - const yyr65 bool = false - yyq65[0] = x.Kind != "" - yyq65[1] = x.APIVersion != "" - yyq65[2] = true - yyq65[3] = true - var yynn65 int - if yyr65 || yy2arr65 { - r.EncodeArrayStart(4) - } else { - yynn65 = 0 - for _, b := range yyq65 { - if b { - yynn65++ - } - } - r.EncodeMapStart(yynn65) - yynn65 = 0 - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[0] { - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq65[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[1] { - yym70 := z.EncBinary() - _ = yym70 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq65[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym71 := z.EncBinary() - _ = yym71 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[2] { - yy73 := &x.ObjectMeta - yy73.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq65[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy74 := &x.ObjectMeta - yy74.CodecEncodeSelf(e) - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[3] { - yy76 := &x.Template - yy76.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq65[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy77 := &x.Template - yy77.CodecEncodeSelf(e) - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobTemplate) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym78 := z.DecBinary() - _ = yym78 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct79 := r.ContainerType() - if yyct79 == codecSelferValueTypeMap1234 { - yyl79 := r.ReadMapStart() - if yyl79 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl79, d) - } - } else if yyct79 == codecSelferValueTypeArray1234 { - yyl79 := r.ReadArrayStart() - if yyl79 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl79, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobTemplate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys80Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys80Slc - var yyhl80 bool = l >= 0 - for yyj80 := 0; ; yyj80++ { - if yyhl80 { - if yyj80 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys80Slc = r.DecodeBytes(yys80Slc, true, true) - yys80 := string(yys80Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys80 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv83 := &x.ObjectMeta - yyv83.CodecDecodeSelf(d) - } - case "template": - if r.TryDecodeAsNil() { - x.Template = JobTemplateSpec{} - } else { - yyv84 := &x.Template - yyv84.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys80) - } // end switch yys80 - } // end for yyj80 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj85 int - var yyb85 bool - var yyhl85 bool = l >= 0 - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv88 := &x.ObjectMeta - yyv88.CodecDecodeSelf(d) - } - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = JobTemplateSpec{} - } else { - yyv89 := &x.Template - yyv89.CodecDecodeSelf(d) - } - for { - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj85-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobTemplateSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym90 := z.EncBinary() - _ = yym90 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep91 := !z.EncBinary() - yy2arr91 := z.EncBasicHandle().StructToArray - var yyq91 [2]bool - _, _, _ = yysep91, yyq91, yy2arr91 - const yyr91 bool = false - yyq91[0] = true - yyq91[1] = true - var yynn91 int - if yyr91 || yy2arr91 { - r.EncodeArrayStart(2) - } else { - yynn91 = 0 - for _, b := range yyq91 { - if b { - yynn91++ - } - } - r.EncodeMapStart(yynn91) - yynn91 = 0 - } - if yyr91 || yy2arr91 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq91[0] { - yy93 := &x.ObjectMeta - yy93.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq91[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy94 := &x.ObjectMeta - yy94.CodecEncodeSelf(e) - } - } - if yyr91 || yy2arr91 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq91[1] { - yy96 := &x.Spec - yy96.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq91[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy97 := &x.Spec - yy97.CodecEncodeSelf(e) - } - } - if yyr91 || yy2arr91 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobTemplateSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym98 := z.DecBinary() - _ = yym98 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct99 := r.ContainerType() - if yyct99 == codecSelferValueTypeMap1234 { - yyl99 := r.ReadMapStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl99, d) - } - } else if yyct99 == codecSelferValueTypeArray1234 { - yyl99 := r.ReadArrayStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl99, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobTemplateSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys100Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys100Slc - var yyhl100 bool = l >= 0 - for yyj100 := 0; ; yyj100++ { - if yyhl100 { - if yyj100 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys100Slc = r.DecodeBytes(yys100Slc, true, true) - yys100 := string(yys100Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys100 { - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv101 := &x.ObjectMeta - yyv101.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv102 := &x.Spec - yyv102.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys100) - } // end switch yys100 - } // end for yyj100 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobTemplateSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj103 int - var yyb103 bool - var yyhl103 bool = l >= 0 - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv104 := &x.ObjectMeta - yyv104.CodecDecodeSelf(d) - } - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv105 := &x.Spec - yyv105.CodecDecodeSelf(d) - } - for { - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj103-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym106 := z.EncBinary() - _ = yym106 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep107 := !z.EncBinary() - yy2arr107 := z.EncBasicHandle().StructToArray - var yyq107 [6]bool - _, _, _ = yysep107, yyq107, yy2arr107 - const yyr107 bool = false - yyq107[0] = x.Parallelism != nil - yyq107[1] = x.Completions != nil - yyq107[2] = x.ActiveDeadlineSeconds != nil - yyq107[3] = x.Selector != nil - yyq107[4] = x.ManualSelector != nil - var yynn107 int - if yyr107 || yy2arr107 { - r.EncodeArrayStart(6) - } else { - yynn107 = 1 - for _, b := range yyq107 { - if b { - yynn107++ - } - } - r.EncodeMapStart(yynn107) - yynn107 = 0 - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[0] { - if x.Parallelism == nil { - r.EncodeNil() - } else { - yy109 := *x.Parallelism - yym110 := z.EncBinary() - _ = yym110 - if false { - } else { - r.EncodeInt(int64(yy109)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("parallelism")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Parallelism == nil { - r.EncodeNil() - } else { - yy111 := *x.Parallelism - yym112 := z.EncBinary() - _ = yym112 - if false { - } else { - r.EncodeInt(int64(yy111)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[1] { - if x.Completions == nil { - r.EncodeNil() - } else { - yy114 := *x.Completions - yym115 := z.EncBinary() - _ = yym115 - if false { - } else { - r.EncodeInt(int64(yy114)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("completions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Completions == nil { - r.EncodeNil() - } else { - yy116 := *x.Completions - yym117 := z.EncBinary() - _ = yym117 - if false { - } else { - r.EncodeInt(int64(yy116)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[2] { - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy119 := *x.ActiveDeadlineSeconds - yym120 := z.EncBinary() - _ = yym120 - if false { - } else { - r.EncodeInt(int64(yy119)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy121 := *x.ActiveDeadlineSeconds - yym122 := z.EncBinary() - _ = yym122 - if false { - } else { - r.EncodeInt(int64(yy121)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[3] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym124 := z.EncBinary() - _ = yym124 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym125 := z.EncBinary() - _ = yym125 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[4] { - if x.ManualSelector == nil { - r.EncodeNil() - } else { - yy127 := *x.ManualSelector - yym128 := z.EncBinary() - _ = yym128 - if false { - } else { - r.EncodeBool(bool(yy127)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("manualSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ManualSelector == nil { - r.EncodeNil() - } else { - yy129 := *x.ManualSelector - yym130 := z.EncBinary() - _ = yym130 - if false { - } else { - r.EncodeBool(bool(yy129)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy132 := &x.Template - yy132.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy133 := &x.Template - yy133.CodecEncodeSelf(e) - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym134 := z.DecBinary() - _ = yym134 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct135 := r.ContainerType() - if yyct135 == codecSelferValueTypeMap1234 { - yyl135 := r.ReadMapStart() - if yyl135 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl135, d) - } - } else if yyct135 == codecSelferValueTypeArray1234 { - yyl135 := r.ReadArrayStart() - if yyl135 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl135, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys136Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys136Slc - var yyhl136 bool = l >= 0 - for yyj136 := 0; ; yyj136++ { - if yyhl136 { - if yyj136 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys136Slc = r.DecodeBytes(yys136Slc, true, true) - yys136 := string(yys136Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys136 { - case "parallelism": - if r.TryDecodeAsNil() { - if x.Parallelism != nil { - x.Parallelism = nil - } - } else { - if x.Parallelism == nil { - x.Parallelism = new(int32) - } - yym138 := z.DecBinary() - _ = yym138 - if false { - } else { - *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) - } - } - case "completions": - if r.TryDecodeAsNil() { - if x.Completions != nil { - x.Completions = nil - } - } else { - if x.Completions == nil { - x.Completions = new(int32) - } - yym140 := z.DecBinary() - _ = yym140 - if false { - } else { - *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) - } - } - case "activeDeadlineSeconds": - if r.TryDecodeAsNil() { - if x.ActiveDeadlineSeconds != nil { - x.ActiveDeadlineSeconds = nil - } - } else { - if x.ActiveDeadlineSeconds == nil { - x.ActiveDeadlineSeconds = new(int64) - } - yym142 := z.DecBinary() - _ = yym142 - if false { - } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym144 := z.DecBinary() - _ = yym144 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "manualSelector": - if r.TryDecodeAsNil() { - if x.ManualSelector != nil { - x.ManualSelector = nil - } - } else { - if x.ManualSelector == nil { - x.ManualSelector = new(bool) - } - yym146 := z.DecBinary() - _ = yym146 - if false { - } else { - *((*bool)(x.ManualSelector)) = r.DecodeBool() - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv147 := &x.Template - yyv147.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys136) - } // end switch yys136 - } // end for yyj136 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj148 int - var yyb148 bool - var yyhl148 bool = l >= 0 - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Parallelism != nil { - x.Parallelism = nil - } - } else { - if x.Parallelism == nil { - x.Parallelism = new(int32) - } - yym150 := z.DecBinary() - _ = yym150 - if false { - } else { - *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Completions != nil { - x.Completions = nil - } - } else { - if x.Completions == nil { - x.Completions = new(int32) - } - yym152 := z.DecBinary() - _ = yym152 - if false { - } else { - *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - 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) - } - yym154 := z.DecBinary() - _ = yym154 - if false { - } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - 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(pkg1_unversioned.LabelSelector) - } - yym156 := z.DecBinary() - _ = yym156 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ManualSelector != nil { - x.ManualSelector = nil - } - } else { - if x.ManualSelector == nil { - x.ManualSelector = new(bool) - } - yym158 := z.DecBinary() - _ = yym158 - if false { - } else { - *((*bool)(x.ManualSelector)) = r.DecodeBool() - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv159 := &x.Template - yyv159.CodecDecodeSelf(d) - } - for { - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj148-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym160 := z.EncBinary() - _ = yym160 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep161 := !z.EncBinary() - yy2arr161 := z.EncBasicHandle().StructToArray - var yyq161 [6]bool - _, _, _ = yysep161, yyq161, yy2arr161 - const yyr161 bool = false - yyq161[0] = len(x.Conditions) != 0 - yyq161[1] = x.StartTime != nil - yyq161[2] = x.CompletionTime != nil - yyq161[3] = x.Active != 0 - yyq161[4] = x.Succeeded != 0 - yyq161[5] = x.Failed != 0 - var yynn161 int - if yyr161 || yy2arr161 { - r.EncodeArrayStart(6) - } else { - yynn161 = 0 - for _, b := range yyq161 { - if b { - yynn161++ - } - } - r.EncodeMapStart(yynn161) - yynn161 = 0 - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[0] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym163 := z.EncBinary() - _ = yym163 - if false { - } else { - h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq161[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym164 := z.EncBinary() - _ = yym164 - if false { - } else { - h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) - } - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[1] { - if x.StartTime == nil { - r.EncodeNil() - } else { - yym166 := z.EncBinary() - _ = yym166 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym166 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym166 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq161[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StartTime == nil { - r.EncodeNil() - } else { - yym167 := z.EncBinary() - _ = yym167 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym167 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym167 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[2] { - if x.CompletionTime == nil { - r.EncodeNil() - } else { - yym169 := z.EncBinary() - _ = yym169 - if false { - } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym169 { - z.EncBinaryMarshal(x.CompletionTime) - } else if !yym169 && z.IsJSONHandle() { - z.EncJSONMarshal(x.CompletionTime) - } else { - z.EncFallback(x.CompletionTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq161[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("completionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CompletionTime == nil { - r.EncodeNil() - } else { - yym170 := z.EncBinary() - _ = yym170 - if false { - } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym170 { - z.EncBinaryMarshal(x.CompletionTime) - } else if !yym170 && z.IsJSONHandle() { - z.EncJSONMarshal(x.CompletionTime) - } else { - z.EncFallback(x.CompletionTime) - } - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[3] { - yym172 := z.EncBinary() - _ = yym172 - if false { - } else { - r.EncodeInt(int64(x.Active)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq161[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("active")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym173 := z.EncBinary() - _ = yym173 - if false { - } else { - r.EncodeInt(int64(x.Active)) - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[4] { - yym175 := z.EncBinary() - _ = yym175 - if false { - } else { - r.EncodeInt(int64(x.Succeeded)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq161[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("succeeded")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym176 := z.EncBinary() - _ = yym176 - if false { - } else { - r.EncodeInt(int64(x.Succeeded)) - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[5] { - yym178 := z.EncBinary() - _ = yym178 - if false { - } else { - r.EncodeInt(int64(x.Failed)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq161[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("failed")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym179 := z.EncBinary() - _ = yym179 - if false { - } else { - r.EncodeInt(int64(x.Failed)) - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym180 := z.DecBinary() - _ = yym180 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct181 := r.ContainerType() - if yyct181 == codecSelferValueTypeMap1234 { - yyl181 := r.ReadMapStart() - if yyl181 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl181, d) - } - } else if yyct181 == codecSelferValueTypeArray1234 { - yyl181 := r.ReadArrayStart() - if yyl181 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl181, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys182Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys182Slc - var yyhl182 bool = l >= 0 - for yyj182 := 0; ; yyj182++ { - if yyhl182 { - if yyj182 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys182Slc = r.DecodeBytes(yys182Slc, true, true) - yys182 := string(yys182Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys182 { - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv183 := &x.Conditions - yym184 := z.DecBinary() - _ = yym184 - if false { - } else { - h.decSliceJobCondition((*[]JobCondition)(yyv183), d) - } - } - case "startTime": - if r.TryDecodeAsNil() { - if x.StartTime != nil { - x.StartTime = nil - } - } else { - if x.StartTime == nil { - x.StartTime = new(pkg1_unversioned.Time) - } - yym186 := z.DecBinary() - _ = yym186 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym186 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym186 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - case "completionTime": - if r.TryDecodeAsNil() { - if x.CompletionTime != nil { - x.CompletionTime = nil - } - } else { - if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) - } - yym188 := z.DecBinary() - _ = yym188 - if false { - } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym188 { - z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym188 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.CompletionTime) - } else { - z.DecFallback(x.CompletionTime, false) - } - } - case "active": - if r.TryDecodeAsNil() { - x.Active = 0 - } else { - x.Active = int32(r.DecodeInt(32)) - } - case "succeeded": - if r.TryDecodeAsNil() { - x.Succeeded = 0 - } else { - x.Succeeded = int32(r.DecodeInt(32)) - } - case "failed": - if r.TryDecodeAsNil() { - x.Failed = 0 - } else { - x.Failed = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys182) - } // end switch yys182 - } // end for yyj182 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj192 int - var yyb192 bool - var yyhl192 bool = l >= 0 - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv193 := &x.Conditions - yym194 := z.DecBinary() - _ = yym194 - if false { - } else { - h.decSliceJobCondition((*[]JobCondition)(yyv193), d) - } - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - 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(pkg1_unversioned.Time) - } - yym196 := z.DecBinary() - _ = yym196 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym196 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym196 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.CompletionTime != nil { - x.CompletionTime = nil - } - } else { - if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) - } - yym198 := z.DecBinary() - _ = yym198 - if false { - } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym198 { - z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym198 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.CompletionTime) - } else { - z.DecFallback(x.CompletionTime, false) - } - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Active = 0 - } else { - x.Active = int32(r.DecodeInt(32)) - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Succeeded = 0 - } else { - x.Succeeded = int32(r.DecodeInt(32)) - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Failed = 0 - } else { - x.Failed = int32(r.DecodeInt(32)) - } - for { - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj192-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x JobConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym202 := z.EncBinary() - _ = yym202 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *JobConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym203 := z.DecBinary() - _ = yym203 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym204 := z.EncBinary() - _ = yym204 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep205 := !z.EncBinary() - yy2arr205 := z.EncBasicHandle().StructToArray - var yyq205 [6]bool - _, _, _ = yysep205, yyq205, yy2arr205 - const yyr205 bool = false - yyq205[2] = true - yyq205[3] = true - yyq205[4] = x.Reason != "" - yyq205[5] = x.Message != "" - var yynn205 int - if yyr205 || yy2arr205 { - r.EncodeArrayStart(6) - } else { - yynn205 = 2 - for _, b := range yyq205 { - if b { - yynn205++ - } - } - r.EncodeMapStart(yynn205) - yynn205 = 0 - } - if yyr205 || yy2arr205 { - 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 yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym208 := z.EncBinary() - _ = yym208 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym209 := z.EncBinary() - _ = yym209 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[2] { - yy211 := &x.LastProbeTime - yym212 := z.EncBinary() - _ = yym212 - if false { - } else if z.HasExtensions() && z.EncExt(yy211) { - } else if yym212 { - z.EncBinaryMarshal(yy211) - } else if !yym212 && z.IsJSONHandle() { - z.EncJSONMarshal(yy211) - } else { - z.EncFallback(yy211) - } - } else { - r.EncodeNil() - } - } else { - if yyq205[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy213 := &x.LastProbeTime - yym214 := z.EncBinary() - _ = yym214 - if false { - } else if z.HasExtensions() && z.EncExt(yy213) { - } else if yym214 { - z.EncBinaryMarshal(yy213) - } else if !yym214 && z.IsJSONHandle() { - z.EncJSONMarshal(yy213) - } else { - z.EncFallback(yy213) - } - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[3] { - yy216 := &x.LastTransitionTime - yym217 := z.EncBinary() - _ = yym217 - if false { - } else if z.HasExtensions() && z.EncExt(yy216) { - } else if yym217 { - z.EncBinaryMarshal(yy216) - } else if !yym217 && z.IsJSONHandle() { - z.EncJSONMarshal(yy216) - } else { - z.EncFallback(yy216) - } - } else { - r.EncodeNil() - } - } else { - if yyq205[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy218 := &x.LastTransitionTime - yym219 := z.EncBinary() - _ = yym219 - if false { - } else if z.HasExtensions() && z.EncExt(yy218) { - } else if yym219 { - z.EncBinaryMarshal(yy218) - } else if !yym219 && z.IsJSONHandle() { - z.EncJSONMarshal(yy218) - } else { - z.EncFallback(yy218) - } - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[4] { - yym221 := z.EncBinary() - _ = yym221 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq205[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym222 := z.EncBinary() - _ = yym222 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[5] { - yym224 := z.EncBinary() - _ = yym224 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq205[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym225 := z.EncBinary() - _ = yym225 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym226 := z.DecBinary() - _ = yym226 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct227 := r.ContainerType() - if yyct227 == codecSelferValueTypeMap1234 { - yyl227 := r.ReadMapStart() - if yyl227 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl227, d) - } - } else if yyct227 == codecSelferValueTypeArray1234 { - yyl227 := r.ReadArrayStart() - if yyl227 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl227, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys228Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys228Slc - var yyhl228 bool = l >= 0 - for yyj228 := 0; ; yyj228++ { - if yyhl228 { - if yyj228 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys228Slc = r.DecodeBytes(yys228Slc, true, true) - yys228 := string(yys228Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys228 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = JobConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_api.ConditionStatus(r.DecodeString()) - } - case "lastProbeTime": - if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} - } else { - yyv231 := &x.LastProbeTime - yym232 := z.DecBinary() - _ = yym232 - if false { - } else if z.HasExtensions() && z.DecExt(yyv231) { - } else if yym232 { - z.DecBinaryUnmarshal(yyv231) - } else if !yym232 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv231) - } else { - z.DecFallback(yyv231, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv233 := &x.LastTransitionTime - yym234 := z.DecBinary() - _ = yym234 - if false { - } else if z.HasExtensions() && z.DecExt(yyv233) { - } else if yym234 { - z.DecBinaryUnmarshal(yyv233) - } else if !yym234 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv233) - } else { - z.DecFallback(yyv233, 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, yys228) - } // end switch yys228 - } // end for yyj228 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj237 int - var yyb237 bool - var yyhl237 bool = l >= 0 - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = JobConditionType(r.DecodeString()) - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_api.ConditionStatus(r.DecodeString()) - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} - } else { - yyv240 := &x.LastProbeTime - yym241 := z.DecBinary() - _ = yym241 - if false { - } else if z.HasExtensions() && z.DecExt(yyv240) { - } else if yym241 { - z.DecBinaryUnmarshal(yyv240) - } else if !yym241 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv240) - } else { - z.DecFallback(yyv240, false) - } - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv242 := &x.LastTransitionTime - yym243 := z.DecBinary() - _ = yym243 - if false { - } else if z.HasExtensions() && z.DecExt(yyv242) { - } else if yym243 { - z.DecBinaryUnmarshal(yyv242) - } else if !yym243 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv242) - } else { - z.DecFallback(yyv242, false) - } - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj237-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CronJob) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym246 := z.EncBinary() - _ = yym246 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep247 := !z.EncBinary() - yy2arr247 := z.EncBasicHandle().StructToArray - var yyq247 [5]bool - _, _, _ = yysep247, yyq247, yy2arr247 - const yyr247 bool = false - yyq247[0] = x.Kind != "" - yyq247[1] = x.APIVersion != "" - yyq247[2] = true - yyq247[3] = true - yyq247[4] = true - var yynn247 int - if yyr247 || yy2arr247 { - r.EncodeArrayStart(5) - } else { - yynn247 = 0 - for _, b := range yyq247 { - if b { - yynn247++ - } - } - r.EncodeMapStart(yynn247) - yynn247 = 0 - } - if yyr247 || yy2arr247 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[0] { - yym249 := z.EncBinary() - _ = yym249 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq247[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym250 := z.EncBinary() - _ = yym250 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr247 || yy2arr247 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[1] { - yym252 := z.EncBinary() - _ = yym252 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq247[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym253 := z.EncBinary() - _ = yym253 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr247 || yy2arr247 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[2] { - yy255 := &x.ObjectMeta - yy255.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq247[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy256 := &x.ObjectMeta - yy256.CodecEncodeSelf(e) - } - } - if yyr247 || yy2arr247 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[3] { - yy258 := &x.Spec - yy258.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq247[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy259 := &x.Spec - yy259.CodecEncodeSelf(e) - } - } - if yyr247 || yy2arr247 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[4] { - yy261 := &x.Status - yy261.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq247[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy262 := &x.Status - yy262.CodecEncodeSelf(e) - } - } - if yyr247 || yy2arr247 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CronJob) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym263 := z.DecBinary() - _ = yym263 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct264 := r.ContainerType() - if yyct264 == codecSelferValueTypeMap1234 { - yyl264 := r.ReadMapStart() - if yyl264 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl264, d) - } - } else if yyct264 == codecSelferValueTypeArray1234 { - yyl264 := r.ReadArrayStart() - if yyl264 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl264, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CronJob) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys265Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys265Slc - var yyhl265 bool = l >= 0 - for yyj265 := 0; ; yyj265++ { - if yyhl265 { - if yyj265 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys265Slc = r.DecodeBytes(yys265Slc, true, true) - yys265 := string(yys265Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys265 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv268 := &x.ObjectMeta - yyv268.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = CronJobSpec{} - } else { - yyv269 := &x.Spec - yyv269.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = CronJobStatus{} - } else { - yyv270 := &x.Status - yyv270.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys265) - } // end switch yys265 - } // end for yyj265 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CronJob) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj271 int - var yyb271 bool - var yyhl271 bool = l >= 0 - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l - } else { - yyb271 = r.CheckBreak() - } - if yyb271 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l - } else { - yyb271 = r.CheckBreak() - } - if yyb271 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l - } else { - yyb271 = r.CheckBreak() - } - if yyb271 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv274 := &x.ObjectMeta - yyv274.CodecDecodeSelf(d) - } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l - } else { - yyb271 = r.CheckBreak() - } - if yyb271 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = CronJobSpec{} - } else { - yyv275 := &x.Spec - yyv275.CodecDecodeSelf(d) - } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l - } else { - yyb271 = r.CheckBreak() - } - if yyb271 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = CronJobStatus{} - } else { - yyv276 := &x.Status - yyv276.CodecDecodeSelf(d) - } - for { - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l - } else { - yyb271 = r.CheckBreak() - } - if yyb271 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj271-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CronJobList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym277 := z.EncBinary() - _ = yym277 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep278 := !z.EncBinary() - yy2arr278 := z.EncBasicHandle().StructToArray - var yyq278 [4]bool - _, _, _ = yysep278, yyq278, yy2arr278 - const yyr278 bool = false - yyq278[0] = x.Kind != "" - yyq278[1] = x.APIVersion != "" - yyq278[2] = true - var yynn278 int - if yyr278 || yy2arr278 { - r.EncodeArrayStart(4) - } else { - yynn278 = 1 - for _, b := range yyq278 { - if b { - yynn278++ - } - } - r.EncodeMapStart(yynn278) - yynn278 = 0 - } - if yyr278 || yy2arr278 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq278[0] { - yym280 := z.EncBinary() - _ = yym280 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq278[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym281 := z.EncBinary() - _ = yym281 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr278 || yy2arr278 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq278[1] { - yym283 := z.EncBinary() - _ = yym283 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq278[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym284 := z.EncBinary() - _ = yym284 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr278 || yy2arr278 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq278[2] { - yy286 := &x.ListMeta - yym287 := z.EncBinary() - _ = yym287 - if false { - } else if z.HasExtensions() && z.EncExt(yy286) { - } else { - z.EncFallback(yy286) - } - } else { - r.EncodeNil() - } - } else { - if yyq278[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy288 := &x.ListMeta - yym289 := z.EncBinary() - _ = yym289 - if false { - } else if z.HasExtensions() && z.EncExt(yy288) { - } else { - z.EncFallback(yy288) - } - } - } - if yyr278 || yy2arr278 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym291 := z.EncBinary() - _ = yym291 - if false { - } else { - h.encSliceCronJob(([]CronJob)(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 { - yym292 := z.EncBinary() - _ = yym292 - if false { - } else { - h.encSliceCronJob(([]CronJob)(x.Items), e) - } - } - } - if yyr278 || yy2arr278 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CronJobList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym293 := z.DecBinary() - _ = yym293 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct294 := r.ContainerType() - if yyct294 == codecSelferValueTypeMap1234 { - yyl294 := r.ReadMapStart() - if yyl294 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl294, d) - } - } else if yyct294 == codecSelferValueTypeArray1234 { - yyl294 := r.ReadArrayStart() - if yyl294 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl294, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CronJobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys295Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys295Slc - var yyhl295 bool = l >= 0 - for yyj295 := 0; ; yyj295++ { - if yyhl295 { - if yyj295 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys295Slc = r.DecodeBytes(yys295Slc, true, true) - yys295 := string(yys295Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys295 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv298 := &x.ListMeta - yym299 := z.DecBinary() - _ = yym299 - if false { - } else if z.HasExtensions() && z.DecExt(yyv298) { - } else { - z.DecFallback(yyv298, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv300 := &x.Items - yym301 := z.DecBinary() - _ = yym301 - if false { - } else { - h.decSliceCronJob((*[]CronJob)(yyv300), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys295) - } // end switch yys295 - } // end for yyj295 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CronJobList) 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() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv305 := &x.ListMeta - yym306 := z.DecBinary() - _ = yym306 - if false { - } else if z.HasExtensions() && z.DecExt(yyv305) { - } else { - z.DecFallback(yyv305, false) - } - } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l - } else { - yyb302 = r.CheckBreak() - } - if yyb302 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv307 := &x.Items - yym308 := z.DecBinary() - _ = yym308 - if false { - } else { - h.decSliceCronJob((*[]CronJob)(yyv307), 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 *CronJobSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym309 := z.EncBinary() - _ = yym309 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep310 := !z.EncBinary() - yy2arr310 := z.EncBasicHandle().StructToArray - var yyq310 [5]bool - _, _, _ = yysep310, yyq310, yy2arr310 - const yyr310 bool = false - yyq310[1] = x.StartingDeadlineSeconds != nil - yyq310[2] = x.ConcurrencyPolicy != "" - yyq310[3] = x.Suspend != nil - var yynn310 int - if yyr310 || yy2arr310 { - r.EncodeArrayStart(5) - } else { - yynn310 = 2 - for _, b := range yyq310 { - if b { - yynn310++ - } - } - r.EncodeMapStart(yynn310) - yynn310 = 0 - } - if yyr310 || yy2arr310 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym312 := z.EncBinary() - _ = yym312 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Schedule)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("schedule")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym313 := z.EncBinary() - _ = yym313 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Schedule)) - } - } - if yyr310 || yy2arr310 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq310[1] { - if x.StartingDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy315 := *x.StartingDeadlineSeconds - yym316 := z.EncBinary() - _ = yym316 - if false { - } else { - r.EncodeInt(int64(yy315)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq310[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startingDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StartingDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy317 := *x.StartingDeadlineSeconds - yym318 := z.EncBinary() - _ = yym318 - if false { - } else { - r.EncodeInt(int64(yy317)) - } - } - } - } - if yyr310 || yy2arr310 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq310[2] { - x.ConcurrencyPolicy.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq310[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("concurrencyPolicy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.ConcurrencyPolicy.CodecEncodeSelf(e) - } - } - if yyr310 || yy2arr310 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq310[3] { - if x.Suspend == nil { - r.EncodeNil() - } else { - yy321 := *x.Suspend - yym322 := z.EncBinary() - _ = yym322 - if false { - } else { - r.EncodeBool(bool(yy321)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq310[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("suspend")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Suspend == nil { - r.EncodeNil() - } else { - yy323 := *x.Suspend - yym324 := z.EncBinary() - _ = yym324 - if false { - } else { - r.EncodeBool(bool(yy323)) - } - } - } - } - if yyr310 || yy2arr310 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy326 := &x.JobTemplate - yy326.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("jobTemplate")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy327 := &x.JobTemplate - yy327.CodecEncodeSelf(e) - } - if yyr310 || yy2arr310 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CronJobSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym328 := z.DecBinary() - _ = yym328 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct329 := r.ContainerType() - if yyct329 == codecSelferValueTypeMap1234 { - yyl329 := r.ReadMapStart() - if yyl329 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl329, d) - } - } else if yyct329 == codecSelferValueTypeArray1234 { - yyl329 := r.ReadArrayStart() - if yyl329 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl329, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys330Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys330Slc - var yyhl330 bool = l >= 0 - for yyj330 := 0; ; yyj330++ { - if yyhl330 { - if yyj330 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys330Slc = r.DecodeBytes(yys330Slc, true, true) - yys330 := string(yys330Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys330 { - case "schedule": - if r.TryDecodeAsNil() { - x.Schedule = "" - } else { - x.Schedule = string(r.DecodeString()) - } - case "startingDeadlineSeconds": - if r.TryDecodeAsNil() { - if x.StartingDeadlineSeconds != nil { - x.StartingDeadlineSeconds = nil - } - } else { - if x.StartingDeadlineSeconds == nil { - x.StartingDeadlineSeconds = new(int64) - } - yym333 := z.DecBinary() - _ = yym333 - if false { - } else { - *((*int64)(x.StartingDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - case "concurrencyPolicy": - if r.TryDecodeAsNil() { - x.ConcurrencyPolicy = "" - } else { - x.ConcurrencyPolicy = ConcurrencyPolicy(r.DecodeString()) - } - case "suspend": - if r.TryDecodeAsNil() { - if x.Suspend != nil { - x.Suspend = nil - } - } else { - if x.Suspend == nil { - x.Suspend = new(bool) - } - yym336 := z.DecBinary() - _ = yym336 - if false { - } else { - *((*bool)(x.Suspend)) = r.DecodeBool() - } - } - case "jobTemplate": - if r.TryDecodeAsNil() { - x.JobTemplate = JobTemplateSpec{} - } else { - yyv337 := &x.JobTemplate - yyv337.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys330) - } // end switch yys330 - } // end for yyj330 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj338 int - var yyb338 bool - var yyhl338 bool = l >= 0 - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l - } else { - yyb338 = r.CheckBreak() - } - if yyb338 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Schedule = "" - } else { - x.Schedule = string(r.DecodeString()) - } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l - } else { - yyb338 = r.CheckBreak() - } - if yyb338 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.StartingDeadlineSeconds != nil { - x.StartingDeadlineSeconds = nil - } - } else { - if x.StartingDeadlineSeconds == nil { - x.StartingDeadlineSeconds = new(int64) - } - yym341 := z.DecBinary() - _ = yym341 - if false { - } else { - *((*int64)(x.StartingDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l - } else { - yyb338 = r.CheckBreak() - } - if yyb338 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ConcurrencyPolicy = "" - } else { - x.ConcurrencyPolicy = ConcurrencyPolicy(r.DecodeString()) - } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l - } else { - yyb338 = r.CheckBreak() - } - if yyb338 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Suspend != nil { - x.Suspend = nil - } - } else { - if x.Suspend == nil { - x.Suspend = new(bool) - } - yym344 := z.DecBinary() - _ = yym344 - if false { - } else { - *((*bool)(x.Suspend)) = r.DecodeBool() - } - } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l - } else { - yyb338 = r.CheckBreak() - } - if yyb338 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.JobTemplate = JobTemplateSpec{} - } else { - yyv345 := &x.JobTemplate - yyv345.CodecDecodeSelf(d) - } - for { - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l - } else { - yyb338 = r.CheckBreak() - } - if yyb338 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj338-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ConcurrencyPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym346 := z.EncBinary() - _ = yym346 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *ConcurrencyPolicy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym347 := z.DecBinary() - _ = yym347 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *CronJobStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym348 := z.EncBinary() - _ = yym348 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep349 := !z.EncBinary() - yy2arr349 := z.EncBasicHandle().StructToArray - var yyq349 [2]bool - _, _, _ = yysep349, yyq349, yy2arr349 - const yyr349 bool = false - yyq349[0] = len(x.Active) != 0 - yyq349[1] = x.LastScheduleTime != nil - var yynn349 int - if yyr349 || yy2arr349 { - r.EncodeArrayStart(2) - } else { - yynn349 = 0 - for _, b := range yyq349 { - if b { - yynn349++ - } - } - r.EncodeMapStart(yynn349) - yynn349 = 0 - } - if yyr349 || yy2arr349 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq349[0] { - if x.Active == nil { - r.EncodeNil() - } else { - yym351 := z.EncBinary() - _ = yym351 - if false { - } else { - h.encSliceapi_ObjectReference(([]pkg2_api.ObjectReference)(x.Active), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq349[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("active")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Active == nil { - r.EncodeNil() - } else { - yym352 := z.EncBinary() - _ = yym352 - if false { - } else { - h.encSliceapi_ObjectReference(([]pkg2_api.ObjectReference)(x.Active), e) - } - } - } - } - if yyr349 || yy2arr349 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq349[1] { - if x.LastScheduleTime == nil { - r.EncodeNil() - } else { - yym354 := z.EncBinary() - _ = yym354 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastScheduleTime) { - } else if yym354 { - z.EncBinaryMarshal(x.LastScheduleTime) - } else if !yym354 && z.IsJSONHandle() { - z.EncJSONMarshal(x.LastScheduleTime) - } else { - z.EncFallback(x.LastScheduleTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq349[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastScheduleTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LastScheduleTime == nil { - r.EncodeNil() - } else { - yym355 := z.EncBinary() - _ = yym355 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastScheduleTime) { - } else if yym355 { - z.EncBinaryMarshal(x.LastScheduleTime) - } else if !yym355 && z.IsJSONHandle() { - z.EncJSONMarshal(x.LastScheduleTime) - } else { - z.EncFallback(x.LastScheduleTime) - } - } - } - } - if yyr349 || yy2arr349 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CronJobStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym356 := z.DecBinary() - _ = yym356 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct357 := r.ContainerType() - if yyct357 == codecSelferValueTypeMap1234 { - yyl357 := r.ReadMapStart() - if yyl357 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl357, d) - } - } else if yyct357 == codecSelferValueTypeArray1234 { - yyl357 := r.ReadArrayStart() - if yyl357 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl357, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CronJobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys358Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys358Slc - var yyhl358 bool = l >= 0 - for yyj358 := 0; ; yyj358++ { - if yyhl358 { - if yyj358 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys358Slc = r.DecodeBytes(yys358Slc, true, true) - yys358 := string(yys358Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys358 { - case "active": - if r.TryDecodeAsNil() { - x.Active = nil - } else { - yyv359 := &x.Active - yym360 := z.DecBinary() - _ = yym360 - if false { - } else { - h.decSliceapi_ObjectReference((*[]pkg2_api.ObjectReference)(yyv359), d) - } - } - case "lastScheduleTime": - if r.TryDecodeAsNil() { - if x.LastScheduleTime != nil { - x.LastScheduleTime = nil - } - } else { - if x.LastScheduleTime == nil { - x.LastScheduleTime = new(pkg1_unversioned.Time) - } - yym362 := z.DecBinary() - _ = yym362 - if false { - } else if z.HasExtensions() && z.DecExt(x.LastScheduleTime) { - } else if yym362 { - z.DecBinaryUnmarshal(x.LastScheduleTime) - } else if !yym362 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.LastScheduleTime) - } else { - z.DecFallback(x.LastScheduleTime, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys358) - } // end switch yys358 - } // end for yyj358 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CronJobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj363 int - var yyb363 bool - var yyhl363 bool = l >= 0 - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Active = nil - } else { - yyv364 := &x.Active - yym365 := z.DecBinary() - _ = yym365 - if false { - } else { - h.decSliceapi_ObjectReference((*[]pkg2_api.ObjectReference)(yyv364), d) - } - } - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.LastScheduleTime != nil { - x.LastScheduleTime = nil - } - } else { - if x.LastScheduleTime == nil { - x.LastScheduleTime = new(pkg1_unversioned.Time) - } - yym367 := z.DecBinary() - _ = yym367 - if false { - } else if z.HasExtensions() && z.DecExt(x.LastScheduleTime) { - } else if yym367 { - z.DecBinaryUnmarshal(x.LastScheduleTime) - } else if !yym367 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.LastScheduleTime) - } else { - z.DecFallback(x.LastScheduleTime, false) - } - } - for { - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj363-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceJob(v []Job, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv368 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy369 := &yyv368 - yy369.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceJob(v *[]Job, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv370 := *v - yyh370, yyl370 := z.DecSliceHelperStart() - var yyc370 bool - if yyl370 == 0 { - if yyv370 == nil { - yyv370 = []Job{} - yyc370 = true - } else if len(yyv370) != 0 { - yyv370 = yyv370[:0] - yyc370 = true - } - } else if yyl370 > 0 { - var yyrr370, yyrl370 int - var yyrt370 bool - if yyl370 > cap(yyv370) { - - yyrg370 := len(yyv370) > 0 - yyv2370 := yyv370 - yyrl370, yyrt370 = z.DecInferLen(yyl370, z.DecBasicHandle().MaxInitLen, 800) - if yyrt370 { - if yyrl370 <= cap(yyv370) { - yyv370 = yyv370[:yyrl370] - } else { - yyv370 = make([]Job, yyrl370) - } - } else { - yyv370 = make([]Job, yyrl370) - } - yyc370 = true - yyrr370 = len(yyv370) - if yyrg370 { - copy(yyv370, yyv2370) - } - } else if yyl370 != len(yyv370) { - yyv370 = yyv370[:yyl370] - yyc370 = true - } - yyj370 := 0 - for ; yyj370 < yyrr370; yyj370++ { - yyh370.ElemContainerState(yyj370) - if r.TryDecodeAsNil() { - yyv370[yyj370] = Job{} - } else { - yyv371 := &yyv370[yyj370] - yyv371.CodecDecodeSelf(d) - } - - } - if yyrt370 { - for ; yyj370 < yyl370; yyj370++ { - yyv370 = append(yyv370, Job{}) - yyh370.ElemContainerState(yyj370) - if r.TryDecodeAsNil() { - yyv370[yyj370] = Job{} - } else { - yyv372 := &yyv370[yyj370] - yyv372.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj370 := 0 - for ; !r.CheckBreak(); yyj370++ { - - if yyj370 >= len(yyv370) { - yyv370 = append(yyv370, Job{}) // var yyz370 Job - yyc370 = true - } - yyh370.ElemContainerState(yyj370) - if yyj370 < len(yyv370) { - if r.TryDecodeAsNil() { - yyv370[yyj370] = Job{} - } else { - yyv373 := &yyv370[yyj370] - yyv373.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj370 < len(yyv370) { - yyv370 = yyv370[:yyj370] - yyc370 = true - } else if yyj370 == 0 && yyv370 == nil { - yyv370 = []Job{} - yyc370 = true - } - } - yyh370.End() - if yyc370 { - *v = yyv370 - } -} - -func (x codecSelfer1234) encSliceJobCondition(v []JobCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv374 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy375 := &yyv374 - yy375.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceJobCondition(v *[]JobCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv376 := *v - yyh376, yyl376 := z.DecSliceHelperStart() - var yyc376 bool - if yyl376 == 0 { - if yyv376 == nil { - yyv376 = []JobCondition{} - yyc376 = true - } else if len(yyv376) != 0 { - yyv376 = yyv376[:0] - yyc376 = true - } - } else if yyl376 > 0 { - var yyrr376, yyrl376 int - var yyrt376 bool - if yyl376 > cap(yyv376) { - - yyrg376 := len(yyv376) > 0 - yyv2376 := yyv376 - yyrl376, yyrt376 = z.DecInferLen(yyl376, z.DecBasicHandle().MaxInitLen, 112) - if yyrt376 { - if yyrl376 <= cap(yyv376) { - yyv376 = yyv376[:yyrl376] - } else { - yyv376 = make([]JobCondition, yyrl376) - } - } else { - yyv376 = make([]JobCondition, yyrl376) - } - yyc376 = true - yyrr376 = len(yyv376) - if yyrg376 { - copy(yyv376, yyv2376) - } - } else if yyl376 != len(yyv376) { - yyv376 = yyv376[:yyl376] - yyc376 = true - } - yyj376 := 0 - for ; yyj376 < yyrr376; yyj376++ { - yyh376.ElemContainerState(yyj376) - if r.TryDecodeAsNil() { - yyv376[yyj376] = JobCondition{} - } else { - yyv377 := &yyv376[yyj376] - yyv377.CodecDecodeSelf(d) - } - - } - if yyrt376 { - for ; yyj376 < yyl376; yyj376++ { - yyv376 = append(yyv376, JobCondition{}) - yyh376.ElemContainerState(yyj376) - if r.TryDecodeAsNil() { - yyv376[yyj376] = JobCondition{} - } else { - yyv378 := &yyv376[yyj376] - yyv378.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj376 := 0 - for ; !r.CheckBreak(); yyj376++ { - - if yyj376 >= len(yyv376) { - yyv376 = append(yyv376, JobCondition{}) // var yyz376 JobCondition - yyc376 = true - } - yyh376.ElemContainerState(yyj376) - if yyj376 < len(yyv376) { - if r.TryDecodeAsNil() { - yyv376[yyj376] = JobCondition{} - } else { - yyv379 := &yyv376[yyj376] - yyv379.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj376 < len(yyv376) { - yyv376 = yyv376[:yyj376] - yyc376 = true - } else if yyj376 == 0 && yyv376 == nil { - yyv376 = []JobCondition{} - yyc376 = true - } - } - yyh376.End() - if yyc376 { - *v = yyv376 - } -} - -func (x codecSelfer1234) encSliceCronJob(v []CronJob, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv380 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy381 := &yyv380 - yy381.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCronJob(v *[]CronJob, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv382 := *v - yyh382, yyl382 := z.DecSliceHelperStart() - var yyc382 bool - if yyl382 == 0 { - if yyv382 == nil { - yyv382 = []CronJob{} - yyc382 = true - } else if len(yyv382) != 0 { - yyv382 = yyv382[:0] - yyc382 = true - } - } else if yyl382 > 0 { - var yyrr382, yyrl382 int - var yyrt382 bool - if yyl382 > cap(yyv382) { - - yyrg382 := len(yyv382) > 0 - yyv2382 := yyv382 - yyrl382, yyrt382 = z.DecInferLen(yyl382, z.DecBasicHandle().MaxInitLen, 1048) - if yyrt382 { - if yyrl382 <= cap(yyv382) { - yyv382 = yyv382[:yyrl382] - } else { - yyv382 = make([]CronJob, yyrl382) - } - } else { - yyv382 = make([]CronJob, yyrl382) - } - yyc382 = true - yyrr382 = len(yyv382) - if yyrg382 { - copy(yyv382, yyv2382) - } - } else if yyl382 != len(yyv382) { - yyv382 = yyv382[:yyl382] - yyc382 = true - } - yyj382 := 0 - for ; yyj382 < yyrr382; yyj382++ { - yyh382.ElemContainerState(yyj382) - if r.TryDecodeAsNil() { - yyv382[yyj382] = CronJob{} - } else { - yyv383 := &yyv382[yyj382] - yyv383.CodecDecodeSelf(d) - } - - } - if yyrt382 { - for ; yyj382 < yyl382; yyj382++ { - yyv382 = append(yyv382, CronJob{}) - yyh382.ElemContainerState(yyj382) - if r.TryDecodeAsNil() { - yyv382[yyj382] = CronJob{} - } else { - yyv384 := &yyv382[yyj382] - yyv384.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj382 := 0 - for ; !r.CheckBreak(); yyj382++ { - - if yyj382 >= len(yyv382) { - yyv382 = append(yyv382, CronJob{}) // var yyz382 CronJob - yyc382 = true - } - yyh382.ElemContainerState(yyj382) - if yyj382 < len(yyv382) { - if r.TryDecodeAsNil() { - yyv382[yyj382] = CronJob{} - } else { - yyv385 := &yyv382[yyj382] - yyv385.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj382 < len(yyv382) { - yyv382 = yyv382[:yyj382] - yyc382 = true - } else if yyj382 == 0 && yyv382 == nil { - yyv382 = []CronJob{} - yyc382 = true - } - } - yyh382.End() - if yyc382 { - *v = yyv382 - } -} - -func (x codecSelfer1234) encSliceapi_ObjectReference(v []pkg2_api.ObjectReference, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv386 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy387 := &yyv386 - yy387.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceapi_ObjectReference(v *[]pkg2_api.ObjectReference, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv388 := *v - yyh388, yyl388 := z.DecSliceHelperStart() - var yyc388 bool - if yyl388 == 0 { - if yyv388 == nil { - yyv388 = []pkg2_api.ObjectReference{} - yyc388 = true - } else if len(yyv388) != 0 { - yyv388 = yyv388[:0] - yyc388 = true - } - } else if yyl388 > 0 { - var yyrr388, yyrl388 int - var yyrt388 bool - if yyl388 > cap(yyv388) { - - yyrg388 := len(yyv388) > 0 - yyv2388 := yyv388 - yyrl388, yyrt388 = z.DecInferLen(yyl388, z.DecBasicHandle().MaxInitLen, 112) - if yyrt388 { - if yyrl388 <= cap(yyv388) { - yyv388 = yyv388[:yyrl388] - } else { - yyv388 = make([]pkg2_api.ObjectReference, yyrl388) - } - } else { - yyv388 = make([]pkg2_api.ObjectReference, yyrl388) - } - yyc388 = true - yyrr388 = len(yyv388) - if yyrg388 { - copy(yyv388, yyv2388) - } - } else if yyl388 != len(yyv388) { - yyv388 = yyv388[:yyl388] - yyc388 = true - } - yyj388 := 0 - for ; yyj388 < yyrr388; yyj388++ { - yyh388.ElemContainerState(yyj388) - if r.TryDecodeAsNil() { - yyv388[yyj388] = pkg2_api.ObjectReference{} - } else { - yyv389 := &yyv388[yyj388] - yyv389.CodecDecodeSelf(d) - } - - } - if yyrt388 { - for ; yyj388 < yyl388; yyj388++ { - yyv388 = append(yyv388, pkg2_api.ObjectReference{}) - yyh388.ElemContainerState(yyj388) - if r.TryDecodeAsNil() { - yyv388[yyj388] = pkg2_api.ObjectReference{} - } else { - yyv390 := &yyv388[yyj388] - yyv390.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj388 := 0 - for ; !r.CheckBreak(); yyj388++ { - - if yyj388 >= len(yyv388) { - yyv388 = append(yyv388, pkg2_api.ObjectReference{}) // var yyz388 pkg2_api.ObjectReference - yyc388 = true - } - yyh388.ElemContainerState(yyj388) - if yyj388 < len(yyv388) { - if r.TryDecodeAsNil() { - yyv388[yyj388] = pkg2_api.ObjectReference{} - } else { - yyv391 := &yyv388[yyj388] - yyv391.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj388 < len(yyv388) { - yyv388 = yyv388[:yyj388] - yyc388 = true - } else if yyj388 == 0 && yyv388 == nil { - yyv388 = []pkg2_api.ObjectReference{} - yyc388 = true - } - } - yyh388.End() - if yyc388 { - *v = yyv388 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/types.go b/vendor/k8s.io/client-go/pkg/apis/batch/types.go index 6015361a57..d392074d47 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/types.go @@ -17,99 +17,99 @@ limitations under the License. package batch import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" ) // +genclient=true // Job represents the configuration of a single job. type Job struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Specification of the desired behavior of a job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Spec JobSpec `json:"spec,omitempty"` + Spec JobSpec - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Current status of a job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Status JobStatus `json:"status,omitempty"` + Status JobStatus } // JobList is a collection of jobs. type JobList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + metav1.TypeMeta + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - // Items is the list of Job. - Items []Job `json:"items"` + // items is the list of Jobs. + Items []Job } // JobTemplate describes a template for creating copies of a predefined pod. type JobTemplate struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // Template defines jobs that will be created from this template - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Defines jobs that will be created from this template. + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Template JobTemplateSpec `json:"template,omitempty"` + Template JobTemplateSpec } // JobTemplateSpec describes the data a Job should have when created from a template type JobTemplateSpec struct { // Standard object's metadata of the jobs created from this template. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Specification of the desired behavior of the job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Spec JobSpec `json:"spec,omitempty"` + Spec JobSpec } // JobSpec describes how the job execution will look like. type JobSpec struct { - // Parallelism specifies the maximum desired number of pods the job should + // Specifies the maximum desired number of pods the job should // run at any given time. The actual number of pods running in steady state will // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), // i.e. when the work left to do is less than max parallelism. // +optional - Parallelism *int32 `json:"parallelism,omitempty"` + Parallelism *int32 - // Completions specifies the desired number of successfully finished pods the + // Specifies the desired number of successfully finished pods the // job should be run with. Setting to nil means that the success of any // pod signals the success of all pods, and allows parallelism to have any positive // value. Setting to 1 means that parallelism is limited to 1 and the success of that // pod signals the success of the job. // +optional - Completions *int32 `json:"completions,omitempty"` + Completions *int32 // Optional duration in seconds relative to the startTime that the job may be active // before the system tries to terminate it; value must be positive integer // +optional - ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty"` + ActiveDeadlineSeconds *int64 - // Selector is a label query over pods that should match the pod count. + // A label query over pods that should match the pod count. // Normally, the system sets this field for you. // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector - // ManualSelector controls generation of pod labels and pod selectors. + // manualSelector controls generation of pod labels and pod selectors. // Leave `manualSelector` unset unless you are certain what you are doing. // When false or unset, the system pick labels unique to this job // and appends those labels to the pod template. When true, @@ -119,43 +119,42 @@ type JobSpec struct { // `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` // API. // +optional - ManualSelector *bool `json:"manualSelector,omitempty"` + ManualSelector *bool - // Template is the object that describes the pod that will be created when - // executing a job. - Template api.PodTemplateSpec `json:"template"` + // Describes the pod that will be created when executing a job. + Template api.PodTemplateSpec } // JobStatus represents the current state of a Job. type JobStatus struct { - // Conditions represent the latest available observations of an object's current state. + // The latest available observations of an object's current state. // +optional - Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` + Conditions []JobCondition - // StartTime represents time when the job was acknowledged by the Job Manager. + // Represents time when the job was acknowledged by the job controller. // It is not guaranteed to be set in happens-before order across separate operations. // It is represented in RFC3339 form and is in UTC. // +optional - StartTime *unversioned.Time `json:"startTime,omitempty"` + StartTime *metav1.Time - // CompletionTime represents time when the job was completed. It is not guaranteed to + // Represents time when the job was completed. It is not guaranteed to // be set in happens-before order across separate operations. // It is represented in RFC3339 form and is in UTC. // +optional - CompletionTime *unversioned.Time `json:"completionTime,omitempty"` + CompletionTime *metav1.Time - // Active is the number of actively running pods. + // The number of actively running pods. // +optional - Active int32 `json:"active,omitempty"` + Active int32 - // Succeeded is the number of pods which reached Phase Succeeded. + // The number of pods which reached phase Succeeded. // +optional - Succeeded int32 `json:"succeeded,omitempty"` + Succeeded int32 - // Failed is the number of pods which reached Phase Failed. + // The number of pods which reached phase Failed. // +optional - Failed int32 `json:"failed,omitempty"` + Failed int32 } type JobConditionType string @@ -171,79 +170,89 @@ const ( // JobCondition describes current state of a job. type JobCondition struct { // Type of job condition, Complete or Failed. - Type JobConditionType `json:"type"` + Type JobConditionType // Status of the condition, one of True, False, Unknown. - Status api.ConditionStatus `json:"status"` + Status api.ConditionStatus // Last time the condition was checked. // +optional - LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty"` + LastProbeTime metav1.Time // Last time the condition transit from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"` + LastTransitionTime metav1.Time // (brief) reason for the condition's last transition. // +optional - Reason string `json:"reason,omitempty"` + Reason string // Human readable message indicating details about last transition. // +optional - Message string `json:"message,omitempty"` + Message string } // +genclient=true // CronJob represents the configuration of a single cron job. type CronJob struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // Spec is a structure defining the expected behavior of a job, including the schedule. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Specification of the desired behavior of a cron job, including the schedule. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Spec CronJobSpec `json:"spec,omitempty"` + Spec CronJobSpec - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Current status of a cron job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Status CronJobStatus `json:"status,omitempty"` + Status CronJobStatus } // CronJobList is a collection of cron jobs. type CronJobList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + metav1.TypeMeta + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - // Items is the list of CronJob. - Items []CronJob `json:"items"` + // items is the list of CronJobs. + Items []CronJob } // CronJobSpec describes how the job execution will look like and when it will actually run. type CronJobSpec struct { - // Schedule contains the schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. - Schedule string `json:"schedule"` + // The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. + Schedule string // Optional deadline in seconds for starting the job if it misses scheduled // time for any reason. Missed jobs executions will be counted as failed ones. // +optional - StartingDeadlineSeconds *int64 `json:"startingDeadlineSeconds,omitempty"` + StartingDeadlineSeconds *int64 - // ConcurrencyPolicy specifies how to treat concurrent executions of a Job. + // Specifies how to treat concurrent executions of a Job. + // Defaults to Allow. // +optional - ConcurrencyPolicy ConcurrencyPolicy `json:"concurrencyPolicy,omitempty"` + ConcurrencyPolicy ConcurrencyPolicy - // Suspend flag tells the controller to suspend subsequent executions, it does + // This flag tells the controller to suspend subsequent executions, it does // not apply to already started executions. Defaults to false. // +optional - Suspend *bool `json:"suspend,omitempty"` + Suspend *bool - // JobTemplate is the object that describes the job that will be created when - // executing a CronJob. - JobTemplate JobTemplateSpec `json:"jobTemplate"` + // Specifies the job that will be created when executing a CronJob. + JobTemplate JobTemplateSpec + + // The number of successful finished jobs to retain. + // This is a pointer to distinguish between explicit zero and not specified. + // +optional + SuccessfulJobsHistoryLimit *int32 + + // The number of failed finished jobs to retain. + // This is a pointer to distinguish between explicit zero and not specified. + // +optional + FailedJobsHistoryLimit *int32 } // ConcurrencyPolicy describes how the job will be handled. @@ -266,11 +275,11 @@ const ( // CronJobStatus represents the current state of a cron job. type CronJobStatus struct { - // Active holds pointers to currently running jobs. + // A list of pointers to currently running jobs. // +optional - Active []api.ObjectReference `json:"active,omitempty"` + Active []api.ObjectReference - // LastScheduleTime keeps information of when was the last time the job was successfully scheduled. + // Information when was the last time the job was successfully scheduled. // +optional - LastScheduleTime *unversioned.Time `json:"lastScheduleTime,omitempty"` + LastScheduleTime *metav1.Time } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/BUILD b/vendor/k8s.io/client-go/pkg/apis/batch/v1/BUILD new file mode 100644 index 0000000000..6de7083417 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/conversion.go index 17024769d6..7f2bc9d157 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/conversion.go @@ -19,11 +19,10 @@ package v1 import ( "fmt" - "k8s.io/client-go/pkg/api" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" v1 "k8s.io/client-go/pkg/api/v1" "k8s.io/client-go/pkg/apis/batch" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" ) func addConversionFuncs(scheme *runtime.Scheme) error { @@ -36,13 +35,13 @@ func addConversionFuncs(scheme *runtime.Scheme) error { return err } - return api.Scheme.AddFieldLabelConversionFunc("batch/v1", "Job", + return scheme.AddFieldLabelConversionFunc("batch/v1", "Job", func(label, value string) (string, string, error) { switch label { case "metadata.name", "metadata.namespace", "status.successful": return label, value, nil default: - return "", "", fmt.Errorf("field label not supported: %s", label) + return "", "", fmt.Errorf("field label %q not supported for Job", label) } }, ) diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/defaults.go index 3fcb01b0c6..9c246a594c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/defaults.go @@ -17,14 +17,11 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_Job, - ) + return RegisterDefaults(scheme) } func SetDefaults_Job(obj *Job) { diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/doc.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/doc.go index 7ae7265b06..c7be42d5a1 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/doc.go @@ -14,9 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/batch -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - package v1 diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go index f062e52e6f..bcc6cd9ce1 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -37,7 +37,8 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" import strings "strings" @@ -52,7 +53,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *Job) Reset() { *m = Job{} } func (*Job) ProtoMessage() {} @@ -81,41 +84,41 @@ func init() { proto.RegisterType((*JobSpec)(nil), "k8s.io.client-go.pkg.apis.batch.v1.JobSpec") proto.RegisterType((*JobStatus)(nil), "k8s.io.client-go.pkg.apis.batch.v1.JobStatus") } -func (m *Job) Marshal() (data []byte, err error) { +func (m *Job) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Job) MarshalTo(data []byte) (int, error) { +func (m *Job) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -123,85 +126,85 @@ func (m *Job) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *JobCondition) Marshal() (data []byte, err error) { +func (m *JobCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *JobCondition) MarshalTo(data []byte) (int, error) { +func (m *JobCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastProbeTime.Size())) - n4, err := m.LastProbeTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastProbeTime.Size())) + n4, err := m.LastProbeTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n5, err := m.LastTransitionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n5, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n5 - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *JobList) Marshal() (data []byte, err error) { +func (m *JobList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *JobList) MarshalTo(data []byte) (int, error) { +func (m *JobList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n6, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n6 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -211,60 +214,60 @@ func (m *JobList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *JobSpec) Marshal() (data []byte, err error) { +func (m *JobSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *JobSpec) MarshalTo(data []byte) (int, error) { +func (m *JobSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Parallelism != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Parallelism)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Parallelism)) } if m.Completions != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Completions)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Completions)) } if m.ActiveDeadlineSeconds != nil { - data[i] = 0x18 + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(*m.ActiveDeadlineSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.ActiveDeadlineSeconds)) } if m.Selector != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n7, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n7, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 } if m.ManualSelector != nil { - data[i] = 0x28 + dAtA[i] = 0x28 i++ if *m.ManualSelector { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n8, err := m.Template.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n8, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -272,27 +275,27 @@ func (m *JobSpec) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *JobStatus) Marshal() (data []byte, err error) { +func (m *JobStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *JobStatus) MarshalTo(data []byte) (int, error) { +func (m *JobStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -300,62 +303,62 @@ func (m *JobStatus) MarshalTo(data []byte) (int, error) { } } if m.StartTime != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.StartTime.Size())) - n9, err := m.StartTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.StartTime.Size())) + n9, err := m.StartTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n9 } if m.CompletionTime != nil { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.CompletionTime.Size())) - n10, err := m.CompletionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.CompletionTime.Size())) + n10, err := m.CompletionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n10 } - data[i] = 0x20 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.Active)) - data[i] = 0x28 + i = encodeVarintGenerated(dAtA, i, uint64(m.Active)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.Succeeded)) - data[i] = 0x30 + i = encodeVarintGenerated(dAtA, i, uint64(m.Succeeded)) + dAtA[i] = 0x30 i++ - i = encodeVarintGenerated(data, i, uint64(m.Failed)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Failed)) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *Job) Size() (n int) { @@ -467,7 +470,7 @@ func (this *Job) String() string { return "nil" } s := strings.Join([]string{`&Job{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "JobSpec", "JobSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "JobStatus", "JobStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -481,8 +484,8 @@ func (this *JobCondition) String() string { s := strings.Join([]string{`&JobCondition{`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastProbeTime:` + strings.Replace(strings.Replace(this.LastProbeTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastProbeTime:` + strings.Replace(strings.Replace(this.LastProbeTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `}`, @@ -494,7 +497,7 @@ func (this *JobList) String() string { return "nil" } s := strings.Join([]string{`&JobList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Job", "Job", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -508,7 +511,7 @@ func (this *JobSpec) String() string { `Parallelism:` + valueToStringGenerated(this.Parallelism) + `,`, `Completions:` + valueToStringGenerated(this.Completions) + `,`, `ActiveDeadlineSeconds:` + valueToStringGenerated(this.ActiveDeadlineSeconds) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, `ManualSelector:` + valueToStringGenerated(this.ManualSelector) + `,`, `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, `}`, @@ -521,8 +524,8 @@ func (this *JobStatus) String() string { } s := strings.Join([]string{`&JobStatus{`, `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "JobCondition", "JobCondition", 1), `&`, ``, 1) + `,`, - `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `CompletionTime:` + strings.Replace(fmt.Sprintf("%v", this.CompletionTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, + `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, + `CompletionTime:` + strings.Replace(fmt.Sprintf("%v", this.CompletionTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, `Active:` + fmt.Sprintf("%v", this.Active) + `,`, `Succeeded:` + fmt.Sprintf("%v", this.Succeeded) + `,`, `Failed:` + fmt.Sprintf("%v", this.Failed) + `,`, @@ -538,8 +541,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *Job) Unmarshal(data []byte) error { - l := len(data) +func (m *Job) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -551,7 +554,7 @@ func (m *Job) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -579,7 +582,7 @@ func (m *Job) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -593,7 +596,7 @@ func (m *Job) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -609,7 +612,7 @@ func (m *Job) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -623,7 +626,7 @@ func (m *Job) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -639,7 +642,7 @@ func (m *Job) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -653,13 +656,13 @@ func (m *Job) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -678,8 +681,8 @@ func (m *Job) Unmarshal(data []byte) error { } return nil } -func (m *JobCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *JobCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -691,7 +694,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -719,7 +722,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -734,7 +737,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = JobConditionType(data[iNdEx:postIndex]) + m.Type = JobConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -748,7 +751,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -763,7 +766,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(data[iNdEx:postIndex]) + m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -777,7 +780,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -791,7 +794,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastProbeTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastProbeTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -807,7 +810,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -821,7 +824,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -837,7 +840,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -852,7 +855,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -866,7 +869,7 @@ func (m *JobCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -881,11 +884,11 @@ func (m *JobCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -904,8 +907,8 @@ func (m *JobCondition) Unmarshal(data []byte) error { } return nil } -func (m *JobList) Unmarshal(data []byte) error { - l := len(data) +func (m *JobList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -917,7 +920,7 @@ func (m *JobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -945,7 +948,7 @@ func (m *JobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -959,7 +962,7 @@ func (m *JobList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -975,7 +978,7 @@ func (m *JobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -990,13 +993,13 @@ func (m *JobList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Job{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1015,8 +1018,8 @@ func (m *JobList) Unmarshal(data []byte) error { } return nil } -func (m *JobSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *JobSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1028,7 +1031,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1056,7 +1059,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1076,7 +1079,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1096,7 +1099,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -1116,7 +1119,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1131,9 +1134,9 @@ func (m *JobSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1149,7 +1152,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1170,7 +1173,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1184,13 +1187,13 @@ func (m *JobSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1209,8 +1212,8 @@ func (m *JobSpec) Unmarshal(data []byte) error { } return nil } -func (m *JobStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *JobStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1222,7 +1225,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1250,7 +1253,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1265,7 +1268,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, JobCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1281,7 +1284,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1296,9 +1299,9 @@ func (m *JobStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.StartTime == nil { - m.StartTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + m.StartTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} } - if err := m.StartTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.StartTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1314,7 +1317,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1329,9 +1332,9 @@ func (m *JobStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.CompletionTime == nil { - m.CompletionTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + m.CompletionTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} } - if err := m.CompletionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.CompletionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1347,7 +1350,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Active |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1366,7 +1369,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Succeeded |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1385,7 +1388,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Failed |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1394,7 +1397,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1413,8 +1416,8 @@ func (m *JobStatus) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -1425,7 +1428,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1443,7 +1446,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -1460,7 +1463,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1483,7 +1486,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1494,7 +1497,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1518,60 +1521,65 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/batch/v1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 863 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x9c, 0x54, 0xcf, 0x6f, 0xe3, 0x44, - 0x14, 0xce, 0x8f, 0xa6, 0x4d, 0xa6, 0x3f, 0x76, 0x19, 0xa9, 0x52, 0xc8, 0x21, 0x59, 0x05, 0x84, - 0x16, 0xb1, 0x1d, 0x2b, 0x65, 0x91, 0x10, 0x07, 0x24, 0x5c, 0x84, 0x44, 0xd5, 0xb2, 0xd5, 0xa4, - 0x42, 0x2b, 0x10, 0x48, 0x63, 0xfb, 0x6d, 0x3a, 0xd4, 0xf6, 0x58, 0x9e, 0x71, 0xd0, 0xde, 0xb8, - 0x71, 0xe5, 0xaf, 0x01, 0xf1, 0x1f, 0xf4, 0xb8, 0xe2, 0xc4, 0x29, 0xa2, 0xe6, 0xbf, 0xd8, 0x13, - 0xf2, 0x78, 0x62, 0x3b, 0x4d, 0x1a, 0xa5, 0xdc, 0x3c, 0x6f, 0xbe, 0xef, 0x7b, 0xcf, 0xef, 0x7d, - 0xf3, 0xd0, 0xc7, 0xd7, 0x9f, 0x4a, 0xc2, 0x85, 0x75, 0x9d, 0x38, 0x10, 0x87, 0xa0, 0x40, 0x5a, - 0xd1, 0xf5, 0xc4, 0x62, 0x11, 0x97, 0x96, 0xc3, 0x94, 0x7b, 0x65, 0x4d, 0x47, 0xd6, 0x04, 0x42, - 0x88, 0x99, 0x02, 0x8f, 0x44, 0xb1, 0x50, 0x02, 0xbf, 0x97, 0x93, 0x48, 0x49, 0x22, 0xd1, 0xf5, - 0x84, 0x64, 0x24, 0xa2, 0x49, 0x64, 0x3a, 0xea, 0x1d, 0x4d, 0xb8, 0xba, 0x4a, 0x1c, 0xe2, 0x8a, - 0xc0, 0x9a, 0x88, 0x89, 0xb0, 0x34, 0xd7, 0x49, 0x5e, 0xe9, 0x93, 0x3e, 0xe8, 0xaf, 0x5c, 0xb3, - 0x77, 0x7c, 0x6f, 0x21, 0x56, 0x0c, 0x52, 0x24, 0xb1, 0x0b, 0x77, 0xeb, 0xe8, 0x7d, 0x72, 0x3f, - 0x27, 0x09, 0xa7, 0x10, 0x4b, 0x2e, 0x42, 0xf0, 0x96, 0x68, 0xcf, 0xee, 0xa7, 0x2d, 0xff, 0x6c, - 0xef, 0x68, 0x35, 0x3a, 0x4e, 0x42, 0xc5, 0x83, 0xe5, 0x9a, 0x46, 0xab, 0xe1, 0x89, 0xe2, 0xbe, - 0xc5, 0x43, 0x25, 0x55, 0x7c, 0x97, 0x32, 0xfc, 0xb5, 0x81, 0x9a, 0xa7, 0xc2, 0xc1, 0x2f, 0x51, - 0x3b, 0x00, 0xc5, 0x3c, 0xa6, 0x58, 0xb7, 0xfe, 0xa4, 0xfe, 0x74, 0xf7, 0xf8, 0x29, 0xb9, 0xb7, - 0xd3, 0x64, 0x3a, 0x22, 0x2f, 0x9c, 0x9f, 0xc0, 0x55, 0xe7, 0xa0, 0x98, 0x8d, 0x6f, 0x66, 0x83, - 0x5a, 0x3a, 0x1b, 0xa0, 0x32, 0x46, 0x0b, 0x35, 0xfc, 0x0d, 0xda, 0x92, 0x11, 0xb8, 0xdd, 0x86, - 0x56, 0x7d, 0x46, 0x36, 0x98, 0x1f, 0x39, 0x15, 0xce, 0x38, 0x02, 0xd7, 0xde, 0x33, 0xca, 0x5b, - 0xd9, 0x89, 0x6a, 0x1d, 0xfc, 0x2d, 0xda, 0x96, 0x8a, 0xa9, 0x44, 0x76, 0x9b, 0x5a, 0x91, 0x6c, - 0xac, 0xa8, 0x59, 0xf6, 0x81, 0xd1, 0xdc, 0xce, 0xcf, 0xd4, 0xa8, 0x0d, 0xff, 0x6a, 0xa2, 0xbd, - 0x53, 0xe1, 0x9c, 0x88, 0xd0, 0xe3, 0x8a, 0x8b, 0x10, 0x3f, 0x47, 0x5b, 0xea, 0x75, 0x04, 0xba, - 0x1d, 0x1d, 0xfb, 0xc9, 0xbc, 0x94, 0xcb, 0xd7, 0x11, 0xbc, 0x9d, 0x0d, 0x1e, 0x57, 0xb1, 0x59, - 0x8c, 0x6a, 0x74, 0xa5, 0xbc, 0x86, 0xe6, 0x7d, 0xbe, 0x98, 0xee, 0xed, 0x6c, 0xb0, 0xd6, 0x02, - 0xa4, 0xd0, 0x5c, 0x2c, 0x0f, 0x5f, 0xa1, 0x7d, 0x9f, 0x49, 0x75, 0x11, 0x0b, 0x07, 0x2e, 0x79, - 0x00, 0xe6, 0xef, 0x3f, 0x5a, 0x33, 0xa5, 0x8a, 0x0f, 0x49, 0x46, 0xb1, 0x0f, 0x4d, 0x2d, 0xfb, - 0x67, 0x55, 0x25, 0xba, 0x28, 0x8c, 0x7f, 0x46, 0x38, 0x0b, 0x5c, 0xc6, 0x2c, 0x94, 0xf9, 0xdf, - 0x65, 0xe9, 0xb6, 0x1e, 0x9e, 0xae, 0x67, 0xd2, 0xe1, 0xb3, 0x25, 0x39, 0xba, 0x22, 0x05, 0xfe, - 0x00, 0x6d, 0xc7, 0xc0, 0xa4, 0x08, 0xbb, 0x2d, 0xdd, 0xba, 0x62, 0x52, 0x54, 0x47, 0xa9, 0xb9, - 0xc5, 0x1f, 0xa2, 0x9d, 0x00, 0xa4, 0x64, 0x13, 0xe8, 0x6e, 0x6b, 0xe0, 0x23, 0x03, 0xdc, 0x39, - 0xcf, 0xc3, 0x74, 0x7e, 0x3f, 0xfc, 0xa3, 0x8e, 0x76, 0x4e, 0x85, 0x73, 0xc6, 0xa5, 0xc2, 0x3f, - 0x2c, 0x59, 0xdc, 0xda, 0xf0, 0x6f, 0x32, 0xba, 0x76, 0xfa, 0x63, 0x93, 0xa8, 0x3d, 0x8f, 0x54, - 0x7c, 0x7e, 0x8e, 0x5a, 0x5c, 0x41, 0x90, 0xcd, 0xbd, 0xb9, 0xfe, 0xf9, 0x2c, 0xda, 0xd2, 0xde, - 0x37, 0xa2, 0xad, 0xaf, 0x33, 0x3a, 0xcd, 0x55, 0x86, 0x7f, 0x36, 0x75, 0xe5, 0x99, 0xf1, 0xf1, - 0x08, 0xed, 0x46, 0x2c, 0x66, 0xbe, 0x0f, 0x3e, 0x97, 0x81, 0x2e, 0xbe, 0x65, 0x3f, 0x4a, 0x67, - 0x83, 0xdd, 0x8b, 0x32, 0x4c, 0xab, 0x98, 0x8c, 0xe2, 0x8a, 0x20, 0xf2, 0x21, 0xeb, 0x6e, 0xee, - 0x45, 0x43, 0x39, 0x29, 0xc3, 0xb4, 0x8a, 0xc1, 0x2f, 0xd0, 0x21, 0x73, 0x15, 0x9f, 0xc2, 0x97, - 0xc0, 0x3c, 0x9f, 0x87, 0x30, 0x06, 0x57, 0x84, 0x5e, 0xfe, 0xce, 0x9a, 0xf6, 0xbb, 0xe9, 0x6c, - 0x70, 0xf8, 0xc5, 0x2a, 0x00, 0x5d, 0xcd, 0xc3, 0x3f, 0xa2, 0xb6, 0x04, 0x1f, 0x5c, 0x25, 0x62, - 0x63, 0x9f, 0xe7, 0x9b, 0x36, 0x9c, 0x39, 0xe0, 0x8f, 0x0d, 0xd7, 0xde, 0xcb, 0x3a, 0x3e, 0x3f, - 0xd1, 0x42, 0x13, 0x7f, 0x86, 0x0e, 0x02, 0x16, 0x26, 0xac, 0x40, 0x6a, 0xdf, 0xb4, 0x6d, 0x9c, - 0xce, 0x06, 0x07, 0xe7, 0x0b, 0x37, 0xf4, 0x0e, 0x12, 0x7f, 0x8f, 0xda, 0x0a, 0x82, 0xc8, 0x67, - 0x2a, 0x37, 0xd1, 0xee, 0xf1, 0xd1, 0xfa, 0x7d, 0x77, 0x21, 0xbc, 0x4b, 0x43, 0xd0, 0xab, 0xa9, - 0xb0, 0xc2, 0x3c, 0x4a, 0x0b, 0xc1, 0xe1, 0xef, 0x4d, 0xd4, 0x29, 0x16, 0x0e, 0x06, 0x84, 0xdc, - 0xf9, 0xa3, 0x96, 0xdd, 0xba, 0x76, 0xc7, 0x68, 0x53, 0x77, 0x14, 0xeb, 0xa0, 0xdc, 0xb2, 0x45, - 0x48, 0xd2, 0x8a, 0x30, 0x7e, 0x89, 0x3a, 0x52, 0xb1, 0x58, 0xe9, 0xd7, 0xda, 0x78, 0xf8, 0x6b, - 0xdd, 0x4f, 0x67, 0x83, 0xce, 0x78, 0xae, 0x40, 0x4b, 0x31, 0x3c, 0x41, 0x07, 0xa5, 0x4f, 0xfe, - 0xef, 0xee, 0xd1, 0x43, 0x39, 0x59, 0x90, 0xa1, 0x77, 0x64, 0xb3, 0x05, 0x90, 0x3b, 0x49, 0xdb, - 0xa5, 0x55, 0x2e, 0x80, 0xdc, 0x76, 0xd4, 0xdc, 0x62, 0x0b, 0x75, 0x64, 0xe2, 0xba, 0x00, 0x1e, - 0x78, 0x7a, 0xe6, 0x2d, 0xfb, 0x1d, 0x03, 0xed, 0x8c, 0xe7, 0x17, 0xb4, 0xc4, 0x64, 0xc2, 0xaf, - 0x18, 0xf7, 0xc1, 0xd3, 0xb3, 0xae, 0x08, 0x7f, 0xa5, 0xa3, 0xd4, 0xdc, 0xda, 0xef, 0xdf, 0xdc, - 0xf6, 0x6b, 0x6f, 0x6e, 0xfb, 0xb5, 0xbf, 0x6f, 0xfb, 0xb5, 0x5f, 0xd2, 0x7e, 0xfd, 0x26, 0xed, - 0xd7, 0xdf, 0xa4, 0xfd, 0xfa, 0x3f, 0x69, 0xbf, 0xfe, 0xdb, 0xbf, 0xfd, 0xda, 0x77, 0x8d, 0xe9, - 0xe8, 0xbf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x9a, 0x45, 0x86, 0xd9, 0xb8, 0x08, 0x00, 0x00, + // 873 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x54, 0xdd, 0x6e, 0xe3, 0x44, + 0x14, 0xce, 0x4f, 0xd3, 0x26, 0x93, 0xb6, 0xbb, 0x8c, 0x54, 0x29, 0xf4, 0xc2, 0x59, 0x05, 0x09, + 0x15, 0xb4, 0x6b, 0x93, 0x76, 0x85, 0x10, 0x17, 0x48, 0xb8, 0x08, 0x89, 0xaa, 0x65, 0xab, 0x49, + 0x05, 0x12, 0x3f, 0x12, 0x63, 0xfb, 0x34, 0x1d, 0x6a, 0x7b, 0x2c, 0xcf, 0x24, 0x52, 0xef, 0x78, + 0x03, 0x78, 0x18, 0x84, 0x78, 0x84, 0x5e, 0xf6, 0x72, 0xaf, 0x22, 0x6a, 0xde, 0x62, 0xaf, 0xd0, + 0x8c, 0x27, 0xb6, 0xb3, 0x49, 0x21, 0xe5, 0xce, 0x3e, 0xf3, 0x7d, 0xdf, 0x39, 0x73, 0xce, 0x77, + 0x06, 0x1d, 0x5d, 0x7f, 0x22, 0x6c, 0xc6, 0x9d, 0xeb, 0x89, 0x07, 0x69, 0x0c, 0x12, 0x84, 0x93, + 0x5c, 0x8f, 0x1d, 0x9a, 0x30, 0xe1, 0x78, 0x54, 0xfa, 0x57, 0xce, 0x74, 0xe8, 0x8c, 0x21, 0x86, + 0x94, 0x4a, 0x08, 0xec, 0x24, 0xe5, 0x92, 0xe3, 0xf7, 0x72, 0x92, 0x5d, 0x92, 0xec, 0xe4, 0x7a, + 0x6c, 0x2b, 0x92, 0xad, 0x49, 0xf6, 0x74, 0xb8, 0xff, 0x62, 0xcc, 0xe4, 0xd5, 0xc4, 0xb3, 0x7d, + 0x1e, 0x39, 0x63, 0x3e, 0xe6, 0x8e, 0xe6, 0x7a, 0x93, 0x4b, 0xfd, 0xa7, 0x7f, 0xf4, 0x57, 0xae, + 0xb9, 0xff, 0xd2, 0x14, 0x42, 0x13, 0x16, 0x51, 0xff, 0x8a, 0xc5, 0x90, 0xde, 0x94, 0xa5, 0x44, + 0x20, 0xe9, 0x8a, 0x4a, 0xf6, 0x9d, 0x87, 0x58, 0xe9, 0x24, 0x96, 0x2c, 0x82, 0x25, 0xc2, 0xc7, + 0xff, 0x45, 0x10, 0xfe, 0x15, 0x44, 0x74, 0x89, 0x77, 0xf4, 0x10, 0x6f, 0x22, 0x59, 0xe8, 0xb0, + 0x58, 0x0a, 0x99, 0x2e, 0x91, 0x9e, 0x3f, 0xd8, 0xdc, 0x15, 0x77, 0x19, 0xfc, 0xda, 0x40, 0xcd, + 0x13, 0xee, 0xe1, 0x9f, 0x50, 0x5b, 0x5d, 0x37, 0xa0, 0x92, 0xf6, 0xea, 0xcf, 0xea, 0x07, 0xdd, + 0xc3, 0x8f, 0x6c, 0xd3, 0xf0, 0x6a, 0xf6, 0xb2, 0xe5, 0x0a, 0x6d, 0x4f, 0x87, 0xf6, 0x2b, 0xef, + 0x67, 0xf0, 0xe5, 0x19, 0x48, 0xea, 0xe2, 0xdb, 0x59, 0xbf, 0x96, 0xcd, 0xfa, 0xa8, 0x8c, 0x91, + 0x42, 0x15, 0x7f, 0x8d, 0x36, 0x44, 0x02, 0x7e, 0xaf, 0xa1, 0xd5, 0x9f, 0xdb, 0x6b, 0x8c, 0xd3, + 0x3e, 0xe1, 0xde, 0x28, 0x01, 0xdf, 0xdd, 0x36, 0xca, 0x1b, 0xea, 0x8f, 0x68, 0x1d, 0xfc, 0x0d, + 0xda, 0x14, 0x92, 0xca, 0x89, 0xe8, 0x35, 0xb5, 0xa2, 0xbd, 0xb6, 0xa2, 0x66, 0xb9, 0xbb, 0x46, + 0x73, 0x33, 0xff, 0x27, 0x46, 0x6d, 0x70, 0xd7, 0x44, 0xdb, 0x27, 0xdc, 0x3b, 0xe6, 0x71, 0xc0, + 0x24, 0xe3, 0x31, 0x7e, 0x89, 0x36, 0xe4, 0x4d, 0x02, 0xba, 0x2d, 0x1d, 0xf7, 0xd9, 0xbc, 0x94, + 0x8b, 0x9b, 0x04, 0xde, 0xcc, 0xfa, 0x4f, 0xab, 0x58, 0x15, 0x23, 0x1a, 0x5d, 0x29, 0xaf, 0xa1, + 0x79, 0x9f, 0x2d, 0xa6, 0x7b, 0x33, 0xeb, 0xff, 0xeb, 0xa0, 0xec, 0x42, 0x73, 0xb1, 0x3c, 0x3c, + 0x46, 0x3b, 0x21, 0x15, 0xf2, 0x3c, 0xe5, 0x1e, 0x5c, 0xb0, 0x08, 0xcc, 0xed, 0x3f, 0x5c, 0x6f, + 0x5a, 0x8a, 0xe1, 0xee, 0x99, 0x52, 0x76, 0x4e, 0xab, 0x42, 0x64, 0x51, 0x17, 0x4f, 0x11, 0x56, + 0x81, 0x8b, 0x94, 0xc6, 0x22, 0xbf, 0x9c, 0xca, 0xb6, 0xf1, 0xe8, 0x6c, 0xfb, 0x26, 0x1b, 0x3e, + 0x5d, 0x52, 0x23, 0x2b, 0x32, 0xe0, 0xf7, 0xd1, 0x66, 0x0a, 0x54, 0xf0, 0xb8, 0xd7, 0xd2, 0x8d, + 0x2b, 0xe6, 0x44, 0x74, 0x94, 0x98, 0x53, 0xfc, 0x01, 0xda, 0x8a, 0x40, 0x08, 0x3a, 0x86, 0xde, + 0xa6, 0x06, 0x3e, 0x31, 0xc0, 0xad, 0xb3, 0x3c, 0x4c, 0xe6, 0xe7, 0x83, 0x3f, 0xea, 0x68, 0xeb, + 0x84, 0x7b, 0xa7, 0x4c, 0x48, 0xfc, 0xc3, 0x92, 0xd1, 0xed, 0xf5, 0x2e, 0xa3, 0xd8, 0xda, 0xe6, + 0x4f, 0x4d, 0x9e, 0xf6, 0x3c, 0x52, 0x31, 0xf9, 0x19, 0x6a, 0x31, 0x09, 0x91, 0x1a, 0x7a, 0xf3, + 0xa0, 0x7b, 0x78, 0xb0, 0xae, 0x27, 0xdd, 0x1d, 0x23, 0xda, 0xfa, 0x4a, 0xd1, 0x49, 0xae, 0x32, + 0xf8, 0xb3, 0xa9, 0x0b, 0x57, 0xae, 0xc7, 0x43, 0xd4, 0x4d, 0x68, 0x4a, 0xc3, 0x10, 0x42, 0x26, + 0x22, 0x5d, 0x7b, 0xcb, 0x7d, 0x92, 0xcd, 0xfa, 0xdd, 0xf3, 0x32, 0x4c, 0xaa, 0x18, 0x45, 0xf1, + 0x79, 0x94, 0x84, 0xa0, 0x9a, 0x9b, 0x1b, 0xd1, 0x50, 0x8e, 0xcb, 0x30, 0xa9, 0x62, 0xf0, 0x2b, + 0xb4, 0x47, 0x7d, 0xc9, 0xa6, 0xf0, 0x05, 0xd0, 0x20, 0x64, 0x31, 0x8c, 0xc0, 0xe7, 0x71, 0x90, + 0x2f, 0x59, 0xd3, 0x7d, 0x37, 0x9b, 0xf5, 0xf7, 0x3e, 0x5f, 0x05, 0x20, 0xab, 0x79, 0xf8, 0x47, + 0xd4, 0x16, 0x10, 0x82, 0x2f, 0x79, 0x6a, 0xcc, 0x73, 0xb4, 0x66, 0xbf, 0xa9, 0x07, 0xe1, 0xc8, + 0x50, 0xdd, 0x6d, 0xd5, 0xf0, 0xf9, 0x1f, 0x29, 0x24, 0xf1, 0xa7, 0x68, 0x37, 0xa2, 0xf1, 0x84, + 0x16, 0x48, 0xed, 0x9a, 0xb6, 0x8b, 0xb3, 0x59, 0x7f, 0xf7, 0x6c, 0xe1, 0x84, 0xbc, 0x85, 0xc4, + 0xdf, 0xa3, 0xb6, 0x84, 0x28, 0x09, 0xa9, 0xcc, 0x2d, 0xd4, 0x3d, 0x7c, 0xf1, 0xf0, 0xbc, 0x54, + 0x49, 0xe7, 0x3c, 0xb8, 0x30, 0x04, 0xfd, 0x2c, 0x15, 0x4e, 0x98, 0x47, 0x49, 0x21, 0x38, 0xf8, + 0xbd, 0x89, 0x3a, 0xc5, 0x63, 0x83, 0x01, 0x21, 0x7f, 0xbe, 0xd0, 0xa2, 0x57, 0xd7, 0xe6, 0x18, + 0xae, 0x6b, 0x8e, 0xe2, 0x29, 0x28, 0x5f, 0xd8, 0x22, 0x24, 0x48, 0x45, 0x18, 0x7f, 0x8b, 0x3a, + 0x42, 0xd2, 0x54, 0xea, 0x55, 0x6d, 0x3c, 0x7a, 0x55, 0x77, 0xb2, 0x59, 0xbf, 0x33, 0x9a, 0x0b, + 0x90, 0x52, 0x0b, 0x5f, 0xa2, 0xdd, 0xd2, 0x25, 0xff, 0xf3, 0xd9, 0xd1, 0x23, 0x39, 0x5e, 0x50, + 0x21, 0x6f, 0xa9, 0xaa, 0xe5, 0xcf, 0x6d, 0xa4, 0xbd, 0xd2, 0x2a, 0x97, 0x3f, 0xf7, 0x1c, 0x31, + 0xa7, 0xd8, 0x41, 0x1d, 0x31, 0xf1, 0x7d, 0x80, 0x00, 0x02, 0x3d, 0xf1, 0x96, 0xfb, 0x8e, 0x81, + 0x76, 0x46, 0xf3, 0x03, 0x52, 0x62, 0x94, 0xf0, 0x25, 0x65, 0x21, 0x04, 0x7a, 0xd2, 0x15, 0xe1, + 0x2f, 0x75, 0x94, 0x98, 0x53, 0xf7, 0xe0, 0xf6, 0xde, 0xaa, 0xdd, 0xdd, 0x5b, 0xb5, 0xd7, 0xf7, + 0x56, 0xed, 0x97, 0xcc, 0xaa, 0xdf, 0x66, 0x56, 0xfd, 0x2e, 0xb3, 0xea, 0xaf, 0x33, 0xab, 0xfe, + 0x57, 0x66, 0xd5, 0x7f, 0xfb, 0xdb, 0xaa, 0x7d, 0xd7, 0x98, 0x0e, 0xff, 0x09, 0x00, 0x00, 0xff, + 0xff, 0xe1, 0x7e, 0xeb, 0x67, 0xc5, 0x08, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.proto index 17a6add05a..946988550c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.batch.v1; +package k8s.io.client_go.pkg.apis.batch.v1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1"; @@ -33,17 +33,17 @@ option go_package = "v1"; // Job represents the configuration of a single job. message Job { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Specification of the desired behavior of a job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional JobSpec spec = 2; - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Current status of a job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional JobStatus status = 3; } @@ -58,11 +58,11 @@ message JobCondition { // Last time the condition was checked. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastProbeTime = 3; // Last time the condition transit from one status to another. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 4; // (brief) reason for the condition's last transition. // +optional @@ -75,31 +75,31 @@ message JobCondition { // JobList is a collection of jobs. message JobList { - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; - // Items is the list of Job. + // items is the list of Jobs. repeated Job items = 2; } // JobSpec describes how the job execution will look like. message JobSpec { - // Parallelism specifies the maximum desired number of pods the job should + // Specifies the maximum desired number of pods the job should // run at any given time. The actual number of pods running in steady state will // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), // i.e. when the work left to do is less than max parallelism. - // More info: http://kubernetes.io/docs/user-guide/jobs + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ // +optional optional int32 parallelism = 1; - // Completions specifies the desired number of successfully finished pods the + // Specifies the desired number of successfully finished pods the // job should be run with. Setting to nil means that the success of any // pod signals the success of all pods, and allows parallelism to have any positive // value. Setting to 1 means that parallelism is limited to 1 and the success of that // pod signals the success of the job. - // More info: http://kubernetes.io/docs/user-guide/jobs + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ // +optional optional int32 completions = 2; @@ -108,13 +108,13 @@ message JobSpec { // +optional optional int64 activeDeadlineSeconds = 3; - // Selector is a label query over pods that should match the pod count. + // A label query over pods that should match the pod count. // Normally, the system sets this field for you. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 4; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 4; - // ManualSelector controls generation of pod labels and pod selectors. + // manualSelector controls generation of pod labels and pod selectors. // Leave `manualSelector` unset unless you are certain what you are doing. // When false or unset, the system pick labels unique to this job // and appends those labels to the pod template. When true, @@ -123,44 +123,45 @@ message JobSpec { // and other jobs to not function correctly. However, You may see // `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` // API. - // More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md + // More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md // +optional optional bool manualSelector = 5; - // Template is the object that describes the pod that will be created when - // executing a job. - // More info: http://kubernetes.io/docs/user-guide/jobs - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 6; + // Describes the pod that will be created when executing a job. + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 6; } // JobStatus represents the current state of a Job. message JobStatus { - // Conditions represent the latest available observations of an object's current state. - // More info: http://kubernetes.io/docs/user-guide/jobs + // The latest available observations of an object's current state. + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated JobCondition conditions = 1; - // StartTime represents time when the job was acknowledged by the Job Manager. + // Represents time when the job was acknowledged by the job controller. // It is not guaranteed to be set in happens-before order across separate operations. // It is represented in RFC3339 form and is in UTC. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time startTime = 2; - // CompletionTime represents time when the job was completed. It is not guaranteed to + // Represents time when the job was completed. It is not guaranteed to // be set in happens-before order across separate operations. // It is represented in RFC3339 form and is in UTC. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time completionTime = 3; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time completionTime = 3; - // Active is the number of actively running pods. + // The number of actively running pods. // +optional optional int32 active = 4; - // Succeeded is the number of pods which reached Phase Succeeded. + // The number of pods which reached phase Succeeded. // +optional optional int32 succeeded = 5; - // Failed is the number of pods which reached Phase Failed. + // The number of pods which reached phase Failed. // +optional optional int32 failed = 6; } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/register.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/register.go index 543bce11ab..9256e829a9 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/register.go @@ -17,32 +17,43 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "batch" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &Job{}, &JobList{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, ) - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.generated.go index b6c6658d64..a7693119ca 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.generated.go @@ -25,11 +25,11 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/pkg/util/intstr" + pkg4_resource "k8s.io/apimachinery/pkg/api/resource" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg5_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg3_v1 "k8s.io/client-go/pkg/api/v1" "reflect" "runtime" time "time" @@ -66,10 +66,10 @@ func init() { } if false { // reference the types, but skip this branch at build/run time var v0 pkg4_resource.Quantity - var v1 pkg1_unversioned.TypeMeta - var v2 pkg2_v1.ObjectMeta - var v3 pkg3_types.UID - var v4 pkg5_intstr.IntOrString + var v1 pkg1_v1.TypeMeta + var v2 pkg2_types.UID + var v3 pkg5_intstr.IntOrString + var v4 pkg3_v1.PodTemplateSpec var v5 time.Time _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 } @@ -164,7 +164,13 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[2] { yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } @@ -173,15 +179,21 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } @@ -190,15 +202,15 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } @@ -207,8 +219,8 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } if yyr2 || yy2arr2 { @@ -224,25 +236,25 @@ func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl19, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl19, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -254,12 +266,12 @@ func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -268,47 +280,65 @@ func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = JobSpec{} } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = JobStatus{} } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -316,16 +346,16 @@ func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -333,15 +363,21 @@ func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -349,32 +385,44 @@ func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -382,16 +430,16 @@ func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = JobSpec{} } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -399,21 +447,21 @@ func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = JobStatus{} } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb26 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb26 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -425,37 +473,37 @@ func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym32 := z.EncBinary() - _ = yym32 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [4]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Kind != "" - yyq33[1] = x.APIVersion != "" - yyq33[2] = true - var yynn33 int - if yyr33 || yy2arr33 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn33 = 1 - for _, b := range yyq33 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn33++ + yynn2++ } } - r.EncodeMapStart(yynn33) - yynn33 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -464,23 +512,23 @@ func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - yym38 := z.EncBinary() - _ = yym38 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -489,54 +537,54 @@ func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq33[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[2] { - yy41 := &x.ListMeta - yym42 := z.EncBinary() - _ = yym42 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy41) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy41) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq33[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy43 := &x.ListMeta - yym44 := z.EncBinary() - _ = yym44 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy43) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy43) + z.EncFallback(yy12) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym46 := z.EncBinary() - _ = yym46 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceJob(([]Job)(x.Items), e) @@ -549,15 +597,15 @@ func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym47 := z.EncBinary() - _ = yym47 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceJob(([]Job)(x.Items), e) } } } - if yyr33 || yy2arr33 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -570,25 +618,25 @@ func (x *JobList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym48 := z.DecBinary() - _ = yym48 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct49 := r.ContainerType() - if yyct49 == codecSelferValueTypeMap1234 { - yyl49 := r.ReadMapStart() - if yyl49 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl49, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct49 == codecSelferValueTypeArray1234 { - yyl49 := r.ReadArrayStart() - if yyl49 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl49, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -600,12 +648,12 @@ func (x *JobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys50Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys50Slc - var yyhl50 bool = l >= 0 - for yyj50 := 0; ; yyj50++ { - if yyhl50 { - if yyj50 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -614,51 +662,63 @@ func (x *JobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys50Slc = r.DecodeBytes(yys50Slc, true, true) - yys50 := string(yys50Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys50 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv53 := &x.ListMeta - yym54 := z.DecBinary() - _ = yym54 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv53) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv53, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv55 := &x.Items - yym56 := z.DecBinary() - _ = yym56 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceJob((*[]Job)(yyv55), d) + h.decSliceJob((*[]Job)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys50) - } // end switch yys50 - } // end for yyj50 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -666,16 +726,16 @@ func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj57 int - var yyb57 bool - var yyhl57 bool = l >= 0 - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -683,15 +743,21 @@ func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -699,38 +765,44 @@ func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv60 := &x.ListMeta - yym61 := z.DecBinary() - _ = yym61 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv60) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv60, false) + z.DecFallback(yyv17, false) } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -738,26 +810,26 @@ func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv62 := &x.Items - yym63 := z.DecBinary() - _ = yym63 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceJob((*[]Job)(yyv62), d) + h.decSliceJob((*[]Job)(yyv19), d) } } for { - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb57 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb57 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj57-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -769,147 +841,147 @@ func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym64 := z.EncBinary() - _ = yym64 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep65 := !z.EncBinary() - yy2arr65 := z.EncBasicHandle().StructToArray - var yyq65 [6]bool - _, _, _ = yysep65, yyq65, yy2arr65 - const yyr65 bool = false - yyq65[0] = x.Parallelism != nil - yyq65[1] = x.Completions != nil - yyq65[2] = x.ActiveDeadlineSeconds != nil - yyq65[3] = x.Selector != nil - yyq65[4] = x.ManualSelector != nil - var yynn65 int - if yyr65 || yy2arr65 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Parallelism != nil + yyq2[1] = x.Completions != nil + yyq2[2] = x.ActiveDeadlineSeconds != nil + yyq2[3] = x.Selector != nil + yyq2[4] = x.ManualSelector != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn65 = 1 - for _, b := range yyq65 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn65++ + yynn2++ } } - r.EncodeMapStart(yynn65) - yynn65 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[0] { + if yyq2[0] { if x.Parallelism == nil { r.EncodeNil() } else { - yy67 := *x.Parallelism - yym68 := z.EncBinary() - _ = yym68 + yy4 := *x.Parallelism + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeInt(int64(yy67)) + r.EncodeInt(int64(yy4)) } } } else { r.EncodeNil() } } else { - if yyq65[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("parallelism")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Parallelism == nil { r.EncodeNil() } else { - yy69 := *x.Parallelism - yym70 := z.EncBinary() - _ = yym70 + yy6 := *x.Parallelism + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeInt(int64(yy69)) + r.EncodeInt(int64(yy6)) } } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[1] { + if yyq2[1] { if x.Completions == nil { r.EncodeNil() } else { - yy72 := *x.Completions - yym73 := z.EncBinary() - _ = yym73 + yy9 := *x.Completions + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeInt(int64(yy72)) + r.EncodeInt(int64(yy9)) } } } else { r.EncodeNil() } } else { - if yyq65[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("completions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Completions == nil { r.EncodeNil() } else { - yy74 := *x.Completions - yym75 := z.EncBinary() - _ = yym75 + yy11 := *x.Completions + yym12 := z.EncBinary() + _ = yym12 if false { } else { - r.EncodeInt(int64(yy74)) + r.EncodeInt(int64(yy11)) } } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[2] { + if yyq2[2] { if x.ActiveDeadlineSeconds == nil { r.EncodeNil() } else { - yy77 := *x.ActiveDeadlineSeconds - yym78 := z.EncBinary() - _ = yym78 + yy14 := *x.ActiveDeadlineSeconds + yym15 := z.EncBinary() + _ = yym15 if false { } else { - r.EncodeInt(int64(yy77)) + r.EncodeInt(int64(yy14)) } } } else { r.EncodeNil() } } else { - if yyq65[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ActiveDeadlineSeconds == nil { r.EncodeNil() } else { - yy79 := *x.ActiveDeadlineSeconds - yym80 := z.EncBinary() - _ = yym80 + yy16 := *x.ActiveDeadlineSeconds + yym17 := z.EncBinary() + _ = yym17 if false { } else { - r.EncodeInt(int64(yy79)) + r.EncodeInt(int64(yy16)) } } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[3] { + if yyq2[3] { if x.Selector == nil { r.EncodeNil() } else { - yym82 := z.EncBinary() - _ = yym82 + yym19 := z.EncBinary() + _ = yym19 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -920,15 +992,15 @@ func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq65[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Selector == nil { r.EncodeNil() } else { - yym83 := z.EncBinary() - _ = yym83 + yym20 := z.EncBinary() + _ = yym20 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -937,53 +1009,53 @@ func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[4] { + if yyq2[4] { if x.ManualSelector == nil { r.EncodeNil() } else { - yy85 := *x.ManualSelector - yym86 := z.EncBinary() - _ = yym86 + yy22 := *x.ManualSelector + yym23 := z.EncBinary() + _ = yym23 if false { } else { - r.EncodeBool(bool(yy85)) + r.EncodeBool(bool(yy22)) } } } else { r.EncodeNil() } } else { - if yyq65[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("manualSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ManualSelector == nil { r.EncodeNil() } else { - yy87 := *x.ManualSelector - yym88 := z.EncBinary() - _ = yym88 + yy24 := *x.ManualSelector + yym25 := z.EncBinary() + _ = yym25 if false { } else { - r.EncodeBool(bool(yy87)) + r.EncodeBool(bool(yy24)) } } } } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy90 := &x.Template - yy90.CodecEncodeSelf(e) + yy27 := &x.Template + yy27.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("template")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy91 := &x.Template - yy91.CodecEncodeSelf(e) + yy29 := &x.Template + yy29.CodecEncodeSelf(e) } - if yyr65 || yy2arr65 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -996,25 +1068,25 @@ func (x *JobSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym92 := z.DecBinary() - _ = yym92 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct93 := r.ContainerType() - if yyct93 == codecSelferValueTypeMap1234 { - yyl93 := r.ReadMapStart() - if yyl93 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl93, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct93 == codecSelferValueTypeArray1234 { - yyl93 := r.ReadArrayStart() - if yyl93 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl93, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1026,12 +1098,12 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys94Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys94Slc - var yyhl94 bool = l >= 0 - for yyj94 := 0; ; yyj94++ { - if yyhl94 { - if yyj94 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1040,10 +1112,10 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys94Slc = r.DecodeBytes(yys94Slc, true, true) - yys94 := string(yys94Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys94 { + switch yys3 { case "parallelism": if r.TryDecodeAsNil() { if x.Parallelism != nil { @@ -1053,8 +1125,8 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Parallelism == nil { x.Parallelism = new(int32) } - yym96 := z.DecBinary() - _ = yym96 + yym5 := z.DecBinary() + _ = yym5 if false { } else { *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) @@ -1069,8 +1141,8 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Completions == nil { x.Completions = new(int32) } - yym98 := z.DecBinary() - _ = yym98 + yym7 := z.DecBinary() + _ = yym7 if false { } else { *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) @@ -1085,8 +1157,8 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.ActiveDeadlineSeconds == nil { x.ActiveDeadlineSeconds = new(int64) } - yym100 := z.DecBinary() - _ = yym100 + yym9 := z.DecBinary() + _ = yym9 if false { } else { *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) @@ -1099,10 +1171,10 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) + x.Selector = new(pkg1_v1.LabelSelector) } - yym102 := z.DecBinary() - _ = yym102 + yym11 := z.DecBinary() + _ = yym11 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { @@ -1118,8 +1190,8 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.ManualSelector == nil { x.ManualSelector = new(bool) } - yym104 := z.DecBinary() - _ = yym104 + yym13 := z.DecBinary() + _ = yym13 if false { } else { *((*bool)(x.ManualSelector)) = r.DecodeBool() @@ -1127,15 +1199,15 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } case "template": if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} + x.Template = pkg3_v1.PodTemplateSpec{} } else { - yyv105 := &x.Template - yyv105.CodecDecodeSelf(d) + yyv14 := &x.Template + yyv14.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys94) - } // end switch yys94 - } // end for yyj94 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1143,16 +1215,16 @@ func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj106 int - var yyb106 bool - var yyhl106 bool = l >= 0 - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + var yyj15 int + var yyb15 bool + var yyhl15 bool = l >= 0 + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1165,20 +1237,20 @@ func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Parallelism == nil { x.Parallelism = new(int32) } - yym108 := z.DecBinary() - _ = yym108 + yym17 := z.DecBinary() + _ = yym17 if false { } else { *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) } } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1191,20 +1263,20 @@ func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Completions == nil { x.Completions = new(int32) } - yym110 := z.DecBinary() - _ = yym110 + yym19 := z.DecBinary() + _ = yym19 if false { } else { *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) } } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1217,20 +1289,20 @@ func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.ActiveDeadlineSeconds == nil { x.ActiveDeadlineSeconds = new(int64) } - yym112 := z.DecBinary() - _ = yym112 + yym21 := z.DecBinary() + _ = yym21 if false { } else { *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) } } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1241,23 +1313,23 @@ func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) + x.Selector = new(pkg1_v1.LabelSelector) } - yym114 := z.DecBinary() - _ = yym114 + yym23 := z.DecBinary() + _ = yym23 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { z.DecFallback(x.Selector, false) } } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1270,42 +1342,42 @@ func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.ManualSelector == nil { x.ManualSelector = new(bool) } - yym116 := z.DecBinary() - _ = yym116 + yym25 := z.DecBinary() + _ = yym25 if false { } else { *((*bool)(x.ManualSelector)) = r.DecodeBool() } } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} + x.Template = pkg3_v1.PodTemplateSpec{} } else { - yyv117 := &x.Template - yyv117.CodecDecodeSelf(d) + yyv26 := &x.Template + yyv26.CodecDecodeSelf(d) } for { - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l + yyj15++ + if yyhl15 { + yyb15 = yyj15 > l } else { - yyb106 = r.CheckBreak() + yyb15 = r.CheckBreak() } - if yyb106 { + if yyb15 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj106-1, "") + z.DecStructFieldNotFound(yyj15-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1317,43 +1389,43 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym118 := z.EncBinary() - _ = yym118 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep119 := !z.EncBinary() - yy2arr119 := z.EncBasicHandle().StructToArray - var yyq119 [6]bool - _, _, _ = yysep119, yyq119, yy2arr119 - const yyr119 bool = false - yyq119[0] = len(x.Conditions) != 0 - yyq119[1] = x.StartTime != nil - yyq119[2] = x.CompletionTime != nil - yyq119[3] = x.Active != 0 - yyq119[4] = x.Succeeded != 0 - yyq119[5] = x.Failed != 0 - var yynn119 int - if yyr119 || yy2arr119 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Conditions) != 0 + yyq2[1] = x.StartTime != nil + yyq2[2] = x.CompletionTime != nil + yyq2[3] = x.Active != 0 + yyq2[4] = x.Succeeded != 0 + yyq2[5] = x.Failed != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn119 = 0 - for _, b := range yyq119 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn119++ + yynn2++ } } - r.EncodeMapStart(yynn119) - yynn119 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq119[0] { + if yyq2[0] { if x.Conditions == nil { r.EncodeNil() } else { - yym121 := z.EncBinary() - _ = yym121 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) @@ -1363,15 +1435,15 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq119[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Conditions == nil { r.EncodeNil() } else { - yym122 := z.EncBinary() - _ = yym122 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) @@ -1379,19 +1451,19 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq119[1] { + if yyq2[1] { if x.StartTime == nil { r.EncodeNil() } else { - yym124 := z.EncBinary() - _ = yym124 + yym7 := z.EncBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym124 { + } else if yym7 { z.EncBinaryMarshal(x.StartTime) - } else if !yym124 && z.IsJSONHandle() { + } else if !yym7 && z.IsJSONHandle() { z.EncJSONMarshal(x.StartTime) } else { z.EncFallback(x.StartTime) @@ -1401,20 +1473,20 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq119[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("startTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.StartTime == nil { r.EncodeNil() } else { - yym125 := z.EncBinary() - _ = yym125 + yym8 := z.EncBinary() + _ = yym8 if false { } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym125 { + } else if yym8 { z.EncBinaryMarshal(x.StartTime) - } else if !yym125 && z.IsJSONHandle() { + } else if !yym8 && z.IsJSONHandle() { z.EncJSONMarshal(x.StartTime) } else { z.EncFallback(x.StartTime) @@ -1422,19 +1494,19 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq119[2] { + if yyq2[2] { if x.CompletionTime == nil { r.EncodeNil() } else { - yym127 := z.EncBinary() - _ = yym127 + yym10 := z.EncBinary() + _ = yym10 if false { } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym127 { + } else if yym10 { z.EncBinaryMarshal(x.CompletionTime) - } else if !yym127 && z.IsJSONHandle() { + } else if !yym10 && z.IsJSONHandle() { z.EncJSONMarshal(x.CompletionTime) } else { z.EncFallback(x.CompletionTime) @@ -1444,20 +1516,20 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq119[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("completionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.CompletionTime == nil { r.EncodeNil() } else { - yym128 := z.EncBinary() - _ = yym128 + yym11 := z.EncBinary() + _ = yym11 if false { } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym128 { + } else if yym11 { z.EncBinaryMarshal(x.CompletionTime) - } else if !yym128 && z.IsJSONHandle() { + } else if !yym11 && z.IsJSONHandle() { z.EncJSONMarshal(x.CompletionTime) } else { z.EncFallback(x.CompletionTime) @@ -1465,11 +1537,11 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq119[3] { - yym130 := z.EncBinary() - _ = yym130 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeInt(int64(x.Active)) @@ -1478,23 +1550,23 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq119[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("active")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym131 := z.EncBinary() - _ = yym131 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeInt(int64(x.Active)) } } } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq119[4] { - yym133 := z.EncBinary() - _ = yym133 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeInt(int64(x.Succeeded)) @@ -1503,23 +1575,23 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq119[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("succeeded")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym134 := z.EncBinary() - _ = yym134 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeInt(int64(x.Succeeded)) } } } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq119[5] { - yym136 := z.EncBinary() - _ = yym136 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeInt(int64(x.Failed)) @@ -1528,19 +1600,19 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq119[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("failed")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym137 := z.EncBinary() - _ = yym137 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeInt(int64(x.Failed)) } } } - if yyr119 || yy2arr119 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1553,25 +1625,25 @@ func (x *JobStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym138 := z.DecBinary() - _ = yym138 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct139 := r.ContainerType() - if yyct139 == codecSelferValueTypeMap1234 { - yyl139 := r.ReadMapStart() - if yyl139 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl139, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct139 == codecSelferValueTypeArray1234 { - yyl139 := r.ReadArrayStart() - if yyl139 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl139, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1583,12 +1655,12 @@ func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys140Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys140Slc - var yyhl140 bool = l >= 0 - for yyj140 := 0; ; yyj140++ { - if yyhl140 { - if yyj140 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1597,20 +1669,20 @@ func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys140Slc = r.DecodeBytes(yys140Slc, true, true) - yys140 := string(yys140Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys140 { + switch yys3 { case "conditions": if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv141 := &x.Conditions - yym142 := z.DecBinary() - _ = yym142 + yyv4 := &x.Conditions + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceJobCondition((*[]JobCondition)(yyv141), d) + h.decSliceJobCondition((*[]JobCondition)(yyv4), d) } } case "startTime": @@ -1620,15 +1692,15 @@ func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.StartTime == nil { - x.StartTime = new(pkg1_unversioned.Time) + x.StartTime = new(pkg1_v1.Time) } - yym144 := z.DecBinary() - _ = yym144 + yym7 := z.DecBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym144 { + } else if yym7 { z.DecBinaryUnmarshal(x.StartTime) - } else if !yym144 && z.IsJSONHandle() { + } else if !yym7 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.StartTime) } else { z.DecFallback(x.StartTime, false) @@ -1641,15 +1713,15 @@ func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) + x.CompletionTime = new(pkg1_v1.Time) } - yym146 := z.DecBinary() - _ = yym146 + yym9 := z.DecBinary() + _ = yym9 if false { } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym146 { + } else if yym9 { z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym146 && z.IsJSONHandle() { + } else if !yym9 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.CompletionTime) } else { z.DecFallback(x.CompletionTime, false) @@ -1659,24 +1731,42 @@ func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Active = 0 } else { - x.Active = int32(r.DecodeInt(32)) + yyv10 := &x.Active + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } } case "succeeded": if r.TryDecodeAsNil() { x.Succeeded = 0 } else { - x.Succeeded = int32(r.DecodeInt(32)) + yyv12 := &x.Succeeded + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(yyv12)) = int32(r.DecodeInt(32)) + } } case "failed": if r.TryDecodeAsNil() { x.Failed = 0 } else { - x.Failed = int32(r.DecodeInt(32)) + yyv14 := &x.Failed + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys140) - } // end switch yys140 - } // end for yyj140 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1684,16 +1774,16 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj150 int - var yyb150 bool - var yyhl150 bool = l >= 0 - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1701,21 +1791,21 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv151 := &x.Conditions - yym152 := z.DecBinary() - _ = yym152 + yyv17 := &x.Conditions + yym18 := z.DecBinary() + _ = yym18 if false { } else { - h.decSliceJobCondition((*[]JobCondition)(yyv151), d) + h.decSliceJobCondition((*[]JobCondition)(yyv17), d) } } - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1726,27 +1816,27 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.StartTime == nil { - x.StartTime = new(pkg1_unversioned.Time) + x.StartTime = new(pkg1_v1.Time) } - yym154 := z.DecBinary() - _ = yym154 + yym20 := z.DecBinary() + _ = yym20 if false { } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym154 { + } else if yym20 { z.DecBinaryUnmarshal(x.StartTime) - } else if !yym154 && z.IsJSONHandle() { + } else if !yym20 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.StartTime) } else { z.DecFallback(x.StartTime, false) } } - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1757,27 +1847,27 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) + x.CompletionTime = new(pkg1_v1.Time) } - yym156 := z.DecBinary() - _ = yym156 + yym22 := z.DecBinary() + _ = yym22 if false { } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym156 { + } else if yym22 { z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym156 && z.IsJSONHandle() { + } else if !yym22 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.CompletionTime) } else { z.DecFallback(x.CompletionTime, false) } } - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1785,15 +1875,21 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Active = 0 } else { - x.Active = int32(r.DecodeInt(32)) + yyv23 := &x.Active + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } } - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1801,15 +1897,21 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Succeeded = 0 } else { - x.Succeeded = int32(r.DecodeInt(32)) + yyv25 := &x.Succeeded + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } } - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1817,20 +1919,26 @@ func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Failed = 0 } else { - x.Failed = int32(r.DecodeInt(32)) + yyv27 := &x.Failed + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) + } } for { - yyj150++ - if yyhl150 { - yyb150 = yyj150 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb150 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb150 { + if yyb16 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj150-1, "") + z.DecStructFieldNotFound(yyj16-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1839,8 +1947,8 @@ func (x JobConditionType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym160 := z.EncBinary() - _ = yym160 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -1852,8 +1960,8 @@ func (x *JobConditionType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym161 := z.DecBinary() - _ = yym161 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -1868,34 +1976,34 @@ func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym162 := z.EncBinary() - _ = yym162 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep163 := !z.EncBinary() - yy2arr163 := z.EncBasicHandle().StructToArray - var yyq163 [6]bool - _, _, _ = yysep163, yyq163, yy2arr163 - const yyr163 bool = false - yyq163[2] = true - yyq163[3] = true - yyq163[4] = x.Reason != "" - yyq163[5] = x.Message != "" - var yynn163 int - if yyr163 || yy2arr163 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = true + yyq2[4] = x.Reason != "" + yyq2[5] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn163 = 2 - for _, b := range yyq163 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn163++ + yynn2++ } } - r.EncodeMapStart(yynn163) - yynn163 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -1904,106 +2012,96 @@ func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym166 := z.EncBinary() - _ = yym166 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } + yysf7 := &x.Status + yysf7.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym167 := z.EncBinary() - _ = yym167 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } + yysf8 := &x.Status + yysf8.CodecEncodeSelf(e) } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq163[2] { - yy169 := &x.LastProbeTime - yym170 := z.EncBinary() - _ = yym170 + if yyq2[2] { + yy10 := &x.LastProbeTime + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy169) { - } else if yym170 { - z.EncBinaryMarshal(yy169) - } else if !yym170 && z.IsJSONHandle() { - z.EncJSONMarshal(yy169) + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - z.EncFallback(yy169) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq163[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy171 := &x.LastProbeTime - yym172 := z.EncBinary() - _ = yym172 + yy12 := &x.LastProbeTime + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy171) { - } else if yym172 { - z.EncBinaryMarshal(yy171) - } else if !yym172 && z.IsJSONHandle() { - z.EncJSONMarshal(yy171) + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - z.EncFallback(yy171) + z.EncFallback(yy12) } } } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq163[3] { - yy174 := &x.LastTransitionTime - yym175 := z.EncBinary() - _ = yym175 + if yyq2[3] { + yy15 := &x.LastTransitionTime + yym16 := z.EncBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.EncExt(yy174) { - } else if yym175 { - z.EncBinaryMarshal(yy174) - } else if !yym175 && z.IsJSONHandle() { - z.EncJSONMarshal(yy174) + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) } else { - z.EncFallback(yy174) + z.EncFallback(yy15) } } else { r.EncodeNil() } } else { - if yyq163[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy176 := &x.LastTransitionTime - yym177 := z.EncBinary() - _ = yym177 + yy17 := &x.LastTransitionTime + yym18 := z.EncBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.EncExt(yy176) { - } else if yym177 { - z.EncBinaryMarshal(yy176) - } else if !yym177 && z.IsJSONHandle() { - z.EncJSONMarshal(yy176) + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if yym18 { + z.EncBinaryMarshal(yy17) + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) } else { - z.EncFallback(yy176) + z.EncFallback(yy17) } } } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq163[4] { - yym179 := z.EncBinary() - _ = yym179 + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -2012,23 +2110,23 @@ func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq163[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym180 := z.EncBinary() - _ = yym180 + yym21 := z.EncBinary() + _ = yym21 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq163[5] { - yym182 := z.EncBinary() - _ = yym182 + if yyq2[5] { + yym23 := z.EncBinary() + _ = yym23 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -2037,19 +2135,19 @@ func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq163[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym183 := z.EncBinary() - _ = yym183 + yym24 := z.EncBinary() + _ = yym24 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr163 || yy2arr163 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2062,25 +2160,25 @@ func (x *JobCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym184 := z.DecBinary() - _ = yym184 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct185 := r.ContainerType() - if yyct185 == codecSelferValueTypeMap1234 { - yyl185 := r.ReadMapStart() - if yyl185 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl185, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct185 == codecSelferValueTypeArray1234 { - yyl185 := r.ReadArrayStart() - if yyl185 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl185, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2092,12 +2190,12 @@ func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys186Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys186Slc - var yyhl186 bool = l >= 0 - for yyj186 := 0; ; yyj186++ { - if yyhl186 { - if yyj186 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2106,72 +2204,86 @@ func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys186Slc = r.DecodeBytes(yys186Slc, true, true) - yys186 := string(yys186Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys186 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = JobConditionType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } case "lastProbeTime": if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} + x.LastProbeTime = pkg1_v1.Time{} } else { - yyv189 := &x.LastProbeTime - yym190 := z.DecBinary() - _ = yym190 + yyv6 := &x.LastProbeTime + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv189) { - } else if yym190 { - z.DecBinaryUnmarshal(yyv189) - } else if !yym190 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv189) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv189, false) + z.DecFallback(yyv6, false) } } case "lastTransitionTime": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv191 := &x.LastTransitionTime - yym192 := z.DecBinary() - _ = yym192 + yyv8 := &x.LastTransitionTime + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv191) { - } else if yym192 { - z.DecBinaryUnmarshal(yyv191) - } else if !yym192 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv191) + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) } else { - z.DecFallback(yyv191, false) + z.DecFallback(yyv8, false) } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv10 := &x.Reason + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv12 := &x.Message + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys186) - } // end switch yys186 - } // end for yyj186 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2179,16 +2291,16 @@ func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj195 int - var yyb195 bool - var yyhl195 bool = l >= 0 - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2196,15 +2308,16 @@ func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = JobConditionType(r.DecodeString()) + yyv15 := &x.Type + yyv15.CodecDecodeSelf(d) } - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2212,69 +2325,70 @@ func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) + yyv16 := &x.Status + yyv16.CodecDecodeSelf(d) } - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} + x.LastProbeTime = pkg1_v1.Time{} } else { - yyv198 := &x.LastProbeTime - yym199 := z.DecBinary() - _ = yym199 + yyv17 := &x.LastProbeTime + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv198) { - } else if yym199 { - z.DecBinaryUnmarshal(yyv198) - } else if !yym199 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv198) + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) } else { - z.DecFallback(yyv198, false) + z.DecFallback(yyv17, false) } } - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv200 := &x.LastTransitionTime - yym201 := z.DecBinary() - _ = yym201 + yyv19 := &x.LastTransitionTime + yym20 := z.DecBinary() + _ = yym20 if false { - } else if z.HasExtensions() && z.DecExt(yyv200) { - } else if yym201 { - z.DecBinaryUnmarshal(yyv200) - } else if !yym201 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv200) + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else if yym20 { + z.DecBinaryUnmarshal(yyv19) + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv19) } else { - z.DecFallback(yyv200, false) + z.DecFallback(yyv19, false) } } - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2282,15 +2396,21 @@ func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv21 := &x.Reason + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2298,20 +2418,26 @@ func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv23 := &x.Message + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } for { - yyj195++ - if yyhl195 { - yyb195 = yyj195 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb195 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb195 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj195-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2321,10 +2447,10 @@ func (x codecSelfer1234) encSliceJob(v []Job, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv204 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy205 := &yyv204 - yy205.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2334,83 +2460,86 @@ func (x codecSelfer1234) decSliceJob(v *[]Job, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv206 := *v - yyh206, yyl206 := z.DecSliceHelperStart() - var yyc206 bool - if yyl206 == 0 { - if yyv206 == nil { - yyv206 = []Job{} - yyc206 = true - } else if len(yyv206) != 0 { - yyv206 = yyv206[:0] - yyc206 = true - } - } else if yyl206 > 0 { - var yyrr206, yyrl206 int - var yyrt206 bool - if yyl206 > cap(yyv206) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Job{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg206 := len(yyv206) > 0 - yyv2206 := yyv206 - yyrl206, yyrt206 = z.DecInferLen(yyl206, z.DecBasicHandle().MaxInitLen, 824) - if yyrt206 { - if yyrl206 <= cap(yyv206) { - yyv206 = yyv206[:yyrl206] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 920) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv206 = make([]Job, yyrl206) + yyv1 = make([]Job, yyrl1) } } else { - yyv206 = make([]Job, yyrl206) + yyv1 = make([]Job, yyrl1) } - yyc206 = true - yyrr206 = len(yyv206) - if yyrg206 { - copy(yyv206, yyv2206) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl206 != len(yyv206) { - yyv206 = yyv206[:yyl206] - yyc206 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj206 := 0 - for ; yyj206 < yyrr206; yyj206++ { - yyh206.ElemContainerState(yyj206) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv206[yyj206] = Job{} + yyv1[yyj1] = Job{} } else { - yyv207 := &yyv206[yyj206] - yyv207.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt206 { - for ; yyj206 < yyl206; yyj206++ { - yyv206 = append(yyv206, Job{}) - yyh206.ElemContainerState(yyj206) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Job{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv206[yyj206] = Job{} + yyv1[yyj1] = Job{} } else { - yyv208 := &yyv206[yyj206] - yyv208.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj206 := 0 - for ; !r.CheckBreak(); yyj206++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj206 >= len(yyv206) { - yyv206 = append(yyv206, Job{}) // var yyz206 Job - yyc206 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Job{}) // var yyz1 Job + yyc1 = true } - yyh206.ElemContainerState(yyj206) - if yyj206 < len(yyv206) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv206[yyj206] = Job{} + yyv1[yyj1] = Job{} } else { - yyv209 := &yyv206[yyj206] - yyv209.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -2418,17 +2547,17 @@ func (x codecSelfer1234) decSliceJob(v *[]Job, d *codec1978.Decoder) { } } - if yyj206 < len(yyv206) { - yyv206 = yyv206[:yyj206] - yyc206 = true - } else if yyj206 == 0 && yyv206 == nil { - yyv206 = []Job{} - yyc206 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Job{} + yyc1 = true } } - yyh206.End() - if yyc206 { - *v = yyv206 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -2437,10 +2566,10 @@ func (x codecSelfer1234) encSliceJobCondition(v []JobCondition, e *codec1978.Enc z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv210 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy211 := &yyv210 - yy211.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2450,83 +2579,86 @@ func (x codecSelfer1234) decSliceJobCondition(v *[]JobCondition, d *codec1978.De z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv212 := *v - yyh212, yyl212 := z.DecSliceHelperStart() - var yyc212 bool - if yyl212 == 0 { - if yyv212 == nil { - yyv212 = []JobCondition{} - yyc212 = true - } else if len(yyv212) != 0 { - yyv212 = yyv212[:0] - yyc212 = true - } - } else if yyl212 > 0 { - var yyrr212, yyrl212 int - var yyrt212 bool - if yyl212 > cap(yyv212) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []JobCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg212 := len(yyv212) > 0 - yyv2212 := yyv212 - yyrl212, yyrt212 = z.DecInferLen(yyl212, z.DecBasicHandle().MaxInitLen, 112) - if yyrt212 { - if yyrl212 <= cap(yyv212) { - yyv212 = yyv212[:yyrl212] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv212 = make([]JobCondition, yyrl212) + yyv1 = make([]JobCondition, yyrl1) } } else { - yyv212 = make([]JobCondition, yyrl212) + yyv1 = make([]JobCondition, yyrl1) } - yyc212 = true - yyrr212 = len(yyv212) - if yyrg212 { - copy(yyv212, yyv2212) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl212 != len(yyv212) { - yyv212 = yyv212[:yyl212] - yyc212 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj212 := 0 - for ; yyj212 < yyrr212; yyj212++ { - yyh212.ElemContainerState(yyj212) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv212[yyj212] = JobCondition{} + yyv1[yyj1] = JobCondition{} } else { - yyv213 := &yyv212[yyj212] - yyv213.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt212 { - for ; yyj212 < yyl212; yyj212++ { - yyv212 = append(yyv212, JobCondition{}) - yyh212.ElemContainerState(yyj212) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, JobCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv212[yyj212] = JobCondition{} + yyv1[yyj1] = JobCondition{} } else { - yyv214 := &yyv212[yyj212] - yyv214.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj212 := 0 - for ; !r.CheckBreak(); yyj212++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj212 >= len(yyv212) { - yyv212 = append(yyv212, JobCondition{}) // var yyz212 JobCondition - yyc212 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, JobCondition{}) // var yyz1 JobCondition + yyc1 = true } - yyh212.ElemContainerState(yyj212) - if yyj212 < len(yyv212) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv212[yyj212] = JobCondition{} + yyv1[yyj1] = JobCondition{} } else { - yyv215 := &yyv212[yyj212] - yyv215.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -2534,16 +2666,16 @@ func (x codecSelfer1234) decSliceJobCondition(v *[]JobCondition, d *codec1978.De } } - if yyj212 < len(yyv212) { - yyv212 = yyv212[:yyj212] - yyc212 = true - } else if yyj212 == 0 && yyv212 == nil { - yyv212 = []JobCondition{} - yyc212 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []JobCondition{} + yyc1 = true } } - yyh212.End() - if yyc212 { - *v = yyv212 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.go index ec44c4e4b2..bcc8c20891 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/types.go @@ -17,7 +17,7 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" ) @@ -25,52 +25,52 @@ import ( // Job represents the configuration of a single job. type Job struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Specification of the desired behavior of a job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Current status of a job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status JobStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // JobList is a collection of jobs. type JobList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Items is the list of Job. + // items is the list of Jobs. Items []Job `json:"items" protobuf:"bytes,2,rep,name=items"` } // JobSpec describes how the job execution will look like. type JobSpec struct { - // Parallelism specifies the maximum desired number of pods the job should + // Specifies the maximum desired number of pods the job should // run at any given time. The actual number of pods running in steady state will // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), // i.e. when the work left to do is less than max parallelism. - // More info: http://kubernetes.io/docs/user-guide/jobs + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ // +optional Parallelism *int32 `json:"parallelism,omitempty" protobuf:"varint,1,opt,name=parallelism"` - // Completions specifies the desired number of successfully finished pods the + // Specifies the desired number of successfully finished pods the // job should be run with. Setting to nil means that the success of any // pod signals the success of all pods, and allows parallelism to have any positive // value. Setting to 1 means that parallelism is limited to 1 and the success of that // pod signals the success of the job. - // More info: http://kubernetes.io/docs/user-guide/jobs + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ // +optional Completions *int32 `json:"completions,omitempty" protobuf:"varint,2,opt,name=completions"` @@ -79,13 +79,13 @@ type JobSpec struct { // +optional ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,3,opt,name=activeDeadlineSeconds"` - // Selector is a label query over pods that should match the pod count. + // A label query over pods that should match the pod count. // Normally, the system sets this field for you. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"` - // ManualSelector controls generation of pod labels and pod selectors. + // manualSelector controls generation of pod labels and pod selectors. // Leave `manualSelector` unset unless you are certain what you are doing. // When false or unset, the system pick labels unique to this job // and appends those labels to the pod template. When true, @@ -94,45 +94,45 @@ type JobSpec struct { // and other jobs to not function correctly. However, You may see // `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` // API. - // More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md + // More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md // +optional ManualSelector *bool `json:"manualSelector,omitempty" protobuf:"varint,5,opt,name=manualSelector"` - // Template is the object that describes the pod that will be created when - // executing a job. - // More info: http://kubernetes.io/docs/user-guide/jobs + // Describes the pod that will be created when executing a job. + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,6,opt,name=template"` } // JobStatus represents the current state of a Job. type JobStatus struct { - - // Conditions represent the latest available observations of an object's current state. - // More info: http://kubernetes.io/docs/user-guide/jobs + // The latest available observations of an object's current state. + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ // +optional + // +patchMergeKey=type + // +patchStrategy=merge Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"` - // StartTime represents time when the job was acknowledged by the Job Manager. + // Represents time when the job was acknowledged by the job controller. // It is not guaranteed to be set in happens-before order across separate operations. // It is represented in RFC3339 form and is in UTC. // +optional - StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"` + StartTime *metav1.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"` - // CompletionTime represents time when the job was completed. It is not guaranteed to + // Represents time when the job was completed. It is not guaranteed to // be set in happens-before order across separate operations. // It is represented in RFC3339 form and is in UTC. // +optional - CompletionTime *unversioned.Time `json:"completionTime,omitempty" protobuf:"bytes,3,opt,name=completionTime"` + CompletionTime *metav1.Time `json:"completionTime,omitempty" protobuf:"bytes,3,opt,name=completionTime"` - // Active is the number of actively running pods. + // The number of actively running pods. // +optional Active int32 `json:"active,omitempty" protobuf:"varint,4,opt,name=active"` - // Succeeded is the number of pods which reached Phase Succeeded. + // The number of pods which reached phase Succeeded. // +optional Succeeded int32 `json:"succeeded,omitempty" protobuf:"varint,5,opt,name=succeeded"` - // Failed is the number of pods which reached Phase Failed. + // The number of pods which reached phase Failed. // +optional Failed int32 `json:"failed,omitempty" protobuf:"varint,6,opt,name=failed"` } @@ -155,10 +155,10 @@ type JobCondition struct { Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"` // Last time the condition was checked. // +optional - LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"` + LastProbeTime metav1.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"` // Last time the condition transit from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` // (brief) reason for the condition's last transition. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"` diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/types_swagger_doc_generated.go index 3d224e703a..da4985192c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/types_swagger_doc_generated.go @@ -29,9 +29,9 @@ package v1 // AUTO-GENERATED FUNCTIONS START HERE var map_Job = map[string]string{ "": "Job represents the configuration of a single job.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec is a structure defining the expected behavior of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is a structure describing current status of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior of a job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Current status of a job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (Job) SwaggerDoc() map[string]string { @@ -54,8 +54,8 @@ func (JobCondition) SwaggerDoc() map[string]string { var map_JobList = map[string]string{ "": "JobList is a collection of jobs.", - "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "items": "Items is the list of Job.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "items is the list of Jobs.", } func (JobList) SwaggerDoc() map[string]string { @@ -64,12 +64,12 @@ func (JobList) SwaggerDoc() map[string]string { var map_JobSpec = map[string]string{ "": "JobSpec describes how the job execution will look like.", - "parallelism": "Parallelism specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: http://kubernetes.io/docs/user-guide/jobs", - "completions": "Completions specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: http://kubernetes.io/docs/user-guide/jobs", + "parallelism": "Specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", + "completions": "Specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", "activeDeadlineSeconds": "Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer", - "selector": "Selector is a label query over pods that should match the pod count. Normally, the system sets this field for you. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "manualSelector": "ManualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md", - "template": "Template is the object that describes the pod that will be created when executing a job. More info: http://kubernetes.io/docs/user-guide/jobs", + "selector": "A label query over pods that should match the pod count. Normally, the system sets this field for you. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", + "manualSelector": "manualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: https://git.k8s.io/community/contributors/design-proposals/selector-generation.md", + "template": "Describes the pod that will be created when executing a job. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", } func (JobSpec) SwaggerDoc() map[string]string { @@ -78,12 +78,12 @@ func (JobSpec) SwaggerDoc() map[string]string { var map_JobStatus = map[string]string{ "": "JobStatus represents the current state of a Job.", - "conditions": "Conditions represent the latest available observations of an object's current state. More info: http://kubernetes.io/docs/user-guide/jobs", - "startTime": "StartTime represents time when the job was acknowledged by the Job Manager. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", - "completionTime": "CompletionTime represents time when the job was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", - "active": "Active is the number of actively running pods.", - "succeeded": "Succeeded is the number of pods which reached Phase Succeeded.", - "failed": "Failed is the number of pods which reached Phase Failed.", + "conditions": "The latest available observations of an object's current state. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", + "startTime": "Represents time when the job was acknowledged by the job controller. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", + "completionTime": "Represents time when the job was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", + "active": "The number of actively running pods.", + "succeeded": "The number of pods which reached phase Succeeded.", + "failed": "The number of pods which reached phase Failed.", } func (JobStatus) SwaggerDoc() map[string]string { diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.conversion.go index 4c3756ee1d..3e3e61dceb 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,12 +21,12 @@ limitations under the License. package v1 import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" api_v1 "k8s.io/client-go/pkg/api/v1" batch "k8s.io/client-go/pkg/apis/batch" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -52,10 +52,7 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1_JobSpec_To_batch_JobSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -65,15 +62,13 @@ func autoConvert_v1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope return nil } +// Convert_v1_Job_To_batch_Job is an autogenerated conversion function. func Convert_v1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope) error { return autoConvert_v1_Job_To_batch_Job(in, out, s) } func autoConvert_batch_Job_To_v1_Job(in *batch.Job, out *Job, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_batch_JobSpec_To_v1_JobSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -83,6 +78,7 @@ func autoConvert_batch_Job_To_v1_Job(in *batch.Job, out *Job, s conversion.Scope return nil } +// Convert_batch_Job_To_v1_Job is an autogenerated conversion function. func Convert_batch_Job_To_v1_Job(in *batch.Job, out *Job, s conversion.Scope) error { return autoConvert_batch_Job_To_v1_Job(in, out, s) } @@ -97,6 +93,7 @@ func autoConvert_v1_JobCondition_To_batch_JobCondition(in *JobCondition, out *ba return nil } +// Convert_v1_JobCondition_To_batch_JobCondition is an autogenerated conversion function. func Convert_v1_JobCondition_To_batch_JobCondition(in *JobCondition, out *batch.JobCondition, s conversion.Scope) error { return autoConvert_v1_JobCondition_To_batch_JobCondition(in, out, s) } @@ -111,6 +108,7 @@ func autoConvert_batch_JobCondition_To_v1_JobCondition(in *batch.JobCondition, o return nil } +// Convert_batch_JobCondition_To_v1_JobCondition is an autogenerated conversion function. func Convert_batch_JobCondition_To_v1_JobCondition(in *batch.JobCondition, out *JobCondition, s conversion.Scope) error { return autoConvert_batch_JobCondition_To_v1_JobCondition(in, out, s) } @@ -131,6 +129,7 @@ func autoConvert_v1_JobList_To_batch_JobList(in *JobList, out *batch.JobList, s return nil } +// Convert_v1_JobList_To_batch_JobList is an autogenerated conversion function. func Convert_v1_JobList_To_batch_JobList(in *JobList, out *batch.JobList, s conversion.Scope) error { return autoConvert_v1_JobList_To_batch_JobList(in, out, s) } @@ -146,11 +145,12 @@ func autoConvert_batch_JobList_To_v1_JobList(in *batch.JobList, out *JobList, s } } } else { - out.Items = nil + out.Items = make([]Job, 0) } return nil } +// Convert_batch_JobList_To_v1_JobList is an autogenerated conversion function. func Convert_batch_JobList_To_v1_JobList(in *batch.JobList, out *JobList, s conversion.Scope) error { return autoConvert_batch_JobList_To_v1_JobList(in, out, s) } @@ -159,7 +159,7 @@ func autoConvert_v1_JobSpec_To_batch_JobSpec(in *JobSpec, out *batch.JobSpec, s out.Parallelism = (*int32)(unsafe.Pointer(in.Parallelism)) out.Completions = (*int32)(unsafe.Pointer(in.Completions)) out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) + out.Selector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.Selector)) out.ManualSelector = (*bool)(unsafe.Pointer(in.ManualSelector)) if err := api_v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err @@ -171,7 +171,7 @@ func autoConvert_batch_JobSpec_To_v1_JobSpec(in *batch.JobSpec, out *JobSpec, s out.Parallelism = (*int32)(unsafe.Pointer(in.Parallelism)) out.Completions = (*int32)(unsafe.Pointer(in.Completions)) out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) + out.Selector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.Selector)) out.ManualSelector = (*bool)(unsafe.Pointer(in.ManualSelector)) if err := api_v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err @@ -181,28 +181,30 @@ func autoConvert_batch_JobSpec_To_v1_JobSpec(in *batch.JobSpec, out *JobSpec, s func autoConvert_v1_JobStatus_To_batch_JobStatus(in *JobStatus, out *batch.JobStatus, s conversion.Scope) error { out.Conditions = *(*[]batch.JobCondition)(unsafe.Pointer(&in.Conditions)) - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) - out.CompletionTime = (*unversioned.Time)(unsafe.Pointer(in.CompletionTime)) + out.StartTime = (*meta_v1.Time)(unsafe.Pointer(in.StartTime)) + out.CompletionTime = (*meta_v1.Time)(unsafe.Pointer(in.CompletionTime)) out.Active = in.Active out.Succeeded = in.Succeeded out.Failed = in.Failed return nil } +// Convert_v1_JobStatus_To_batch_JobStatus is an autogenerated conversion function. func Convert_v1_JobStatus_To_batch_JobStatus(in *JobStatus, out *batch.JobStatus, s conversion.Scope) error { return autoConvert_v1_JobStatus_To_batch_JobStatus(in, out, s) } func autoConvert_batch_JobStatus_To_v1_JobStatus(in *batch.JobStatus, out *JobStatus, s conversion.Scope) error { out.Conditions = *(*[]JobCondition)(unsafe.Pointer(&in.Conditions)) - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) - out.CompletionTime = (*unversioned.Time)(unsafe.Pointer(in.CompletionTime)) + out.StartTime = (*meta_v1.Time)(unsafe.Pointer(in.StartTime)) + out.CompletionTime = (*meta_v1.Time)(unsafe.Pointer(in.CompletionTime)) out.Active = in.Active out.Succeeded = in.Succeeded out.Failed = in.Failed return nil } +// Convert_batch_JobStatus_To_v1_JobStatus is an autogenerated conversion function. func Convert_batch_JobStatus_To_v1_JobStatus(in *batch.JobStatus, out *JobStatus, s conversion.Scope) error { return autoConvert_batch_JobStatus_To_v1_JobStatus(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.deepcopy.go index 8a9e4e8593..22bf945875 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package v1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" api_v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" reflect "reflect" ) @@ -44,13 +44,16 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1_Job is an autogenerated deepcopy function. func DeepCopy_v1_Job(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Job) out := out.(*Job) - out.TypeMeta = in.TypeMeta - if err := api_v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) } if err := DeepCopy_v1_JobSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -62,26 +65,24 @@ func DeepCopy_v1_Job(in interface{}, out interface{}, c *conversion.Cloner) erro } } +// DeepCopy_v1_JobCondition is an autogenerated deepcopy function. func DeepCopy_v1_JobCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobCondition) out := out.(*JobCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastProbeTime = in.LastProbeTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1_JobList is an autogenerated deepcopy function. func DeepCopy_v1_JobList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobList) out := out.(*JobList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Job, len(*in)) @@ -90,53 +91,44 @@ func DeepCopy_v1_JobList(in interface{}, out interface{}, c *conversion.Cloner) return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1_JobSpec is an autogenerated deepcopy function. func DeepCopy_v1_JobSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobSpec) out := out.(*JobSpec) + *out = *in if in.Parallelism != nil { in, out := &in.Parallelism, &out.Parallelism *out = new(int32) **out = **in - } else { - out.Parallelism = nil } if in.Completions != nil { in, out := &in.Completions, &out.Completions *out = new(int32) **out = **in - } else { - out.Completions = nil } if in.ActiveDeadlineSeconds != nil { in, out := &in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds *out = new(int64) **out = **in - } else { - out.ActiveDeadlineSeconds = nil } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*meta_v1.LabelSelector) } - } else { - out.Selector = nil } if in.ManualSelector != nil { in, out := &in.ManualSelector, &out.ManualSelector *out = new(bool) **out = **in - } else { - out.ManualSelector = nil } if err := api_v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -145,10 +137,12 @@ func DeepCopy_v1_JobSpec(in interface{}, out interface{}, c *conversion.Cloner) } } +// DeepCopy_v1_JobStatus is an autogenerated deepcopy function. func DeepCopy_v1_JobStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobStatus) out := out.(*JobStatus) + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]JobCondition, len(*in)) @@ -157,26 +151,17 @@ func DeepCopy_v1_JobStatus(in interface{}, out interface{}, c *conversion.Cloner return err } } - } else { - out.Conditions = nil } if in.StartTime != nil { in, out := &in.StartTime, &out.StartTime - *out = new(unversioned.Time) + *out = new(meta_v1.Time) **out = (*in).DeepCopy() - } else { - out.StartTime = nil } if in.CompletionTime != nil { in, out := &in.CompletionTime, &out.CompletionTime - *out = new(unversioned.Time) + *out = new(meta_v1.Time) **out = (*in).DeepCopy() - } else { - out.CompletionTime = nil } - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.defaults.go index ef8a8b0ebe..417024f62d 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,8 +21,8 @@ limitations under the License. package v1 import ( + runtime "k8s.io/apimachinery/pkg/runtime" api_v1 "k8s.io/client-go/pkg/api/v1" - runtime "k8s.io/client-go/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. @@ -64,6 +64,23 @@ func SetObjectDefaults_Job(in *Job) { if a.VolumeSource.AzureDisk != nil { api_v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + api_v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + api_v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + api_v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.Template.Spec.InitContainers { a := &in.Spec.Template.Spec.InitContainers[i] diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/BUILD b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/BUILD new file mode 100644 index 0000000000..aeff48f058 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/BUILD @@ -0,0 +1,41 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/batch/v1:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/conversion.go index e9a88b1173..2393fdca97 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/conversion.go @@ -19,32 +19,21 @@ package v2alpha1 import ( "fmt" - "k8s.io/client-go/pkg/api" - v1 "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/apis/batch" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addConversionFuncs(scheme *runtime.Scheme) error { - // Add non-generated conversion functions - err := scheme.AddConversionFuncs( - Convert_batch_JobSpec_To_v2alpha1_JobSpec, - Convert_v2alpha1_JobSpec_To_batch_JobSpec, - ) - if err != nil { - return err - } - + var err error // Add field label conversions for kinds having selectable nothing but ObjectMeta fields. - for _, kind := range []string{"Job", "JobTemplate", "CronJob"} { - err = api.Scheme.AddFieldLabelConversionFunc("batch/v2alpha1", kind, + for _, k := range []string{"Job", "JobTemplate", "CronJob"} { + kind := k // don't close over range variables + err = scheme.AddFieldLabelConversionFunc("batch/v2alpha1", kind, func(label, value string) (string, string, error) { switch label { case "metadata.name", "metadata.namespace", "status.successful": return label, value, nil default: - return "", "", fmt.Errorf("field label not supported: %s", label) + return "", "", fmt.Errorf("field label %q not supported for %q", label, kind) } }) if err != nil { @@ -53,39 +42,3 @@ func addConversionFuncs(scheme *runtime.Scheme) error { } return nil } - -func Convert_batch_JobSpec_To_v2alpha1_JobSpec(in *batch.JobSpec, out *JobSpec, s conversion.Scope) error { - out.Parallelism = in.Parallelism - out.Completions = in.Completions - out.ActiveDeadlineSeconds = in.ActiveDeadlineSeconds - out.Selector = in.Selector - if in.ManualSelector != nil { - out.ManualSelector = new(bool) - *out.ManualSelector = *in.ManualSelector - } else { - out.ManualSelector = nil - } - - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { - return err - } - return nil -} - -func Convert_v2alpha1_JobSpec_To_batch_JobSpec(in *JobSpec, out *batch.JobSpec, s conversion.Scope) error { - out.Parallelism = in.Parallelism - out.Completions = in.Completions - out.ActiveDeadlineSeconds = in.ActiveDeadlineSeconds - out.Selector = in.Selector - if in.ManualSelector != nil { - out.ManualSelector = new(bool) - *out.ManualSelector = *in.ManualSelector - } else { - out.ManualSelector = nil - } - - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { - return err - } - return nil -} diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/defaults.go index d0c1d634c1..292f8886e2 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/defaults.go @@ -17,34 +17,11 @@ limitations under the License. package v2alpha1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_Job, - SetDefaults_CronJob, - ) -} - -func SetDefaults_Job(obj *Job) { - // For a non-parallel job, you can leave both `.spec.completions` and - // `.spec.parallelism` unset. When both are unset, both are defaulted to 1. - if obj.Spec.Completions == nil && obj.Spec.Parallelism == nil { - obj.Spec.Completions = new(int32) - *obj.Spec.Completions = 1 - obj.Spec.Parallelism = new(int32) - *obj.Spec.Parallelism = 1 - } - if obj.Spec.Parallelism == nil { - obj.Spec.Parallelism = new(int32) - *obj.Spec.Parallelism = 1 - } - labels := obj.Spec.Template.Labels - if labels != nil && len(obj.Labels) == 0 { - obj.Labels = labels - } + return RegisterDefaults(scheme) } func SetDefaults_CronJob(obj *CronJob) { diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/doc.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/doc.go index 8fb2e2e62d..a9fe60b1c7 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/doc.go @@ -14,9 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/batch -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - package v2alpha1 diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go index 29bd921435..28df224b88 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -29,11 +29,6 @@ limitations under the License. CronJobList CronJobSpec CronJobStatus - Job - JobCondition - JobList - JobSpec - JobStatus JobTemplate JobTemplateSpec */ @@ -43,7 +38,8 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" import strings "strings" @@ -58,7 +54,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *CronJob) Reset() { *m = CronJob{} } func (*CronJob) ProtoMessage() {} @@ -76,82 +74,57 @@ func (m *CronJobStatus) Reset() { *m = CronJobStatus{} } func (*CronJobStatus) ProtoMessage() {} func (*CronJobStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } -func (m *Job) Reset() { *m = Job{} } -func (*Job) ProtoMessage() {} -func (*Job) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } - -func (m *JobCondition) Reset() { *m = JobCondition{} } -func (*JobCondition) ProtoMessage() {} -func (*JobCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } - -func (m *JobList) Reset() { *m = JobList{} } -func (*JobList) ProtoMessage() {} -func (*JobList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } - -func (m *JobSpec) Reset() { *m = JobSpec{} } -func (*JobSpec) ProtoMessage() {} -func (*JobSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } - -func (m *JobStatus) Reset() { *m = JobStatus{} } -func (*JobStatus) ProtoMessage() {} -func (*JobStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } - func (m *JobTemplate) Reset() { *m = JobTemplate{} } func (*JobTemplate) ProtoMessage() {} -func (*JobTemplate) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } +func (*JobTemplate) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } func (m *JobTemplateSpec) Reset() { *m = JobTemplateSpec{} } func (*JobTemplateSpec) ProtoMessage() {} -func (*JobTemplateSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } +func (*JobTemplateSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } func init() { proto.RegisterType((*CronJob)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.CronJob") proto.RegisterType((*CronJobList)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.CronJobList") proto.RegisterType((*CronJobSpec)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.CronJobSpec") proto.RegisterType((*CronJobStatus)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.CronJobStatus") - proto.RegisterType((*Job)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.Job") - proto.RegisterType((*JobCondition)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.JobCondition") - proto.RegisterType((*JobList)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.JobList") - proto.RegisterType((*JobSpec)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.JobSpec") - proto.RegisterType((*JobStatus)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.JobStatus") proto.RegisterType((*JobTemplate)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.JobTemplate") proto.RegisterType((*JobTemplateSpec)(nil), "k8s.io.client-go.pkg.apis.batch.v2alpha1.JobTemplateSpec") } -func (m *CronJob) Marshal() (data []byte, err error) { +func (m *CronJob) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CronJob) MarshalTo(data []byte) (int, error) { +func (m *CronJob) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -159,35 +132,35 @@ func (m *CronJob) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CronJobList) Marshal() (data []byte, err error) { +func (m *CronJobList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CronJobList) MarshalTo(data []byte) (int, error) { +func (m *CronJobList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n4, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n4, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -197,76 +170,86 @@ func (m *CronJobList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CronJobSpec) Marshal() (data []byte, err error) { +func (m *CronJobSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CronJobSpec) MarshalTo(data []byte) (int, error) { +func (m *CronJobSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Schedule))) - i += copy(data[i:], m.Schedule) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Schedule))) + i += copy(dAtA[i:], m.Schedule) if m.StartingDeadlineSeconds != nil { - data[i] = 0x10 + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(*m.StartingDeadlineSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.StartingDeadlineSeconds)) } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ConcurrencyPolicy))) - i += copy(data[i:], m.ConcurrencyPolicy) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ConcurrencyPolicy))) + i += copy(dAtA[i:], m.ConcurrencyPolicy) if m.Suspend != nil { - data[i] = 0x20 + dAtA[i] = 0x20 i++ if *m.Suspend { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ } - data[i] = 0x2a + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(m.JobTemplate.Size())) - n5, err := m.JobTemplate.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.JobTemplate.Size())) + n5, err := m.JobTemplate.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n5 + if m.SuccessfulJobsHistoryLimit != nil { + dAtA[i] = 0x30 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.SuccessfulJobsHistoryLimit)) + } + if m.FailedJobsHistoryLimit != nil { + dAtA[i] = 0x38 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.FailedJobsHistoryLimit)) + } return i, nil } -func (m *CronJobStatus) Marshal() (data []byte, err error) { +func (m *CronJobStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CronJobStatus) MarshalTo(data []byte) (int, error) { +func (m *CronJobStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Active) > 0 { for _, msg := range m.Active { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -274,10 +257,10 @@ func (m *CronJobStatus) MarshalTo(data []byte) (int, error) { } } if m.LastScheduleTime != nil { - data[i] = 0x22 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastScheduleTime.Size())) - n6, err := m.LastScheduleTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastScheduleTime.Size())) + n6, err := m.LastScheduleTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -286,349 +269,99 @@ func (m *CronJobStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *Job) Marshal() (data []byte, err error) { +func (m *JobTemplate) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Job) MarshalTo(data []byte) (int, error) { +func (m *JobTemplate) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n7, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n7, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n8, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n8, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n8 - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n9, err := m.Status.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n9 - return i, nil -} - -func (m *JobCondition) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobCondition) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.LastProbeTime.Size())) - n10, err := m.LastProbeTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n10 - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n11, err := m.LastTransitionTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n11 - data[i] = 0x2a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x32 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - return i, nil -} - -func (m *JobList) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobList) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n12, err := m.ListMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n12 - if len(m.Items) > 0 { - for _, msg := range m.Items { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *JobSpec) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobSpec) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if m.Parallelism != nil { - data[i] = 0x8 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.Parallelism)) - } - if m.Completions != nil { - data[i] = 0x10 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.Completions)) - } - if m.ActiveDeadlineSeconds != nil { - data[i] = 0x18 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.ActiveDeadlineSeconds)) - } - if m.Selector != nil { - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n13, err := m.Selector.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n13 - } - if m.ManualSelector != nil { - data[i] = 0x28 - i++ - if *m.ManualSelector { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - } - data[i] = 0x32 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n14, err := m.Template.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n14 - return i, nil -} - -func (m *JobStatus) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobStatus) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Conditions) > 0 { - for _, msg := range m.Conditions { - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - if m.StartTime != nil { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.StartTime.Size())) - n15, err := m.StartTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n15 - } - if m.CompletionTime != nil { - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.CompletionTime.Size())) - n16, err := m.CompletionTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n16 - } - data[i] = 0x20 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Active)) - data[i] = 0x28 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Succeeded)) - data[i] = 0x30 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Failed)) - return i, nil -} - -func (m *JobTemplate) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobTemplate) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n17, err := m.ObjectMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n17 - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n18, err := m.Template.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n18 return i, nil } -func (m *JobTemplateSpec) Marshal() (data []byte, err error) { +func (m *JobTemplateSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *JobTemplateSpec) MarshalTo(data []byte) (int, error) { +func (m *JobTemplateSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n19, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n19 - data[i] = 0x12 + i += n9 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n20, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n10, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n20 + i += n10 return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *CronJob) Size() (n int) { @@ -672,6 +405,12 @@ func (m *CronJobSpec) Size() (n int) { } l = m.JobTemplate.Size() n += 1 + l + sovGenerated(uint64(l)) + if m.SuccessfulJobsHistoryLimit != nil { + n += 1 + sovGenerated(uint64(*m.SuccessfulJobsHistoryLimit)) + } + if m.FailedJobsHistoryLimit != nil { + n += 1 + sovGenerated(uint64(*m.FailedJobsHistoryLimit)) + } return n } @@ -691,97 +430,6 @@ func (m *CronJobStatus) Size() (n int) { return n } -func (m *Job) Size() (n int) { - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *JobCondition) Size() (n int) { - var l int - _ = l - l = len(m.Type) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Status) - n += 1 + l + sovGenerated(uint64(l)) - l = m.LastProbeTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.LastTransitionTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Reason) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Message) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *JobList) Size() (n int) { - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *JobSpec) Size() (n int) { - var l int - _ = l - if m.Parallelism != nil { - n += 1 + sovGenerated(uint64(*m.Parallelism)) - } - if m.Completions != nil { - n += 1 + sovGenerated(uint64(*m.Completions)) - } - if m.ActiveDeadlineSeconds != nil { - n += 1 + sovGenerated(uint64(*m.ActiveDeadlineSeconds)) - } - if m.Selector != nil { - l = m.Selector.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - if m.ManualSelector != nil { - n += 2 - } - l = m.Template.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *JobStatus) Size() (n int) { - var l int - _ = l - if len(m.Conditions) > 0 { - for _, e := range m.Conditions { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - if m.StartTime != nil { - l = m.StartTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - if m.CompletionTime != nil { - l = m.CompletionTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - n += 1 + sovGenerated(uint64(m.Active)) - n += 1 + sovGenerated(uint64(m.Succeeded)) - n += 1 + sovGenerated(uint64(m.Failed)) - return n -} - func (m *JobTemplate) Size() (n int) { var l int _ = l @@ -820,7 +468,7 @@ func (this *CronJob) String() string { return "nil" } s := strings.Join([]string{`&CronJob{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "CronJobSpec", "CronJobSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "CronJobStatus", "CronJobStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -832,7 +480,7 @@ func (this *CronJobList) String() string { return "nil" } s := strings.Join([]string{`&CronJobList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "CronJob", "CronJob", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -848,6 +496,8 @@ func (this *CronJobSpec) String() string { `ConcurrencyPolicy:` + fmt.Sprintf("%v", this.ConcurrencyPolicy) + `,`, `Suspend:` + valueToStringGenerated(this.Suspend) + `,`, `JobTemplate:` + strings.Replace(strings.Replace(this.JobTemplate.String(), "JobTemplateSpec", "JobTemplateSpec", 1), `&`, ``, 1) + `,`, + `SuccessfulJobsHistoryLimit:` + valueToStringGenerated(this.SuccessfulJobsHistoryLimit) + `,`, + `FailedJobsHistoryLimit:` + valueToStringGenerated(this.FailedJobsHistoryLimit) + `,`, `}`, }, "") return s @@ -858,75 +508,7 @@ func (this *CronJobStatus) String() string { } s := strings.Join([]string{`&CronJobStatus{`, `Active:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Active), "ObjectReference", "k8s_io_kubernetes_pkg_api_v1.ObjectReference", 1), `&`, ``, 1) + `,`, - `LastScheduleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScheduleTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `}`, - }, "") - return s -} -func (this *Job) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Job{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "JobSpec", "JobSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "JobStatus", "JobStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *JobCondition) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobCondition{`, - `Type:` + fmt.Sprintf("%v", this.Type) + `,`, - `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastProbeTime:` + strings.Replace(strings.Replace(this.LastProbeTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, - `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `}`, - }, "") - return s -} -func (this *JobList) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Job", "Job", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *JobSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobSpec{`, - `Parallelism:` + valueToStringGenerated(this.Parallelism) + `,`, - `Completions:` + valueToStringGenerated(this.Completions) + `,`, - `ActiveDeadlineSeconds:` + valueToStringGenerated(this.ActiveDeadlineSeconds) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, - `ManualSelector:` + valueToStringGenerated(this.ManualSelector) + `,`, - `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *JobStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobStatus{`, - `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "JobCondition", "JobCondition", 1), `&`, ``, 1) + `,`, - `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `CompletionTime:` + strings.Replace(fmt.Sprintf("%v", this.CompletionTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `Active:` + fmt.Sprintf("%v", this.Active) + `,`, - `Succeeded:` + fmt.Sprintf("%v", this.Succeeded) + `,`, - `Failed:` + fmt.Sprintf("%v", this.Failed) + `,`, + `LastScheduleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScheduleTime), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1) + `,`, `}`, }, "") return s @@ -936,7 +518,7 @@ func (this *JobTemplate) String() string { return "nil" } s := strings.Join([]string{`&JobTemplate{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Template:` + strings.Replace(strings.Replace(this.Template.String(), "JobTemplateSpec", "JobTemplateSpec", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -947,8 +529,8 @@ func (this *JobTemplateSpec) String() string { return "nil" } s := strings.Join([]string{`&JobTemplateSpec{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "JobSpec", "JobSpec", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "JobSpec", "k8s_io_kubernetes_pkg_apis_batch_v1.JobSpec", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -961,8 +543,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *CronJob) Unmarshal(data []byte) error { - l := len(data) +func (m *CronJob) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -974,7 +556,7 @@ func (m *CronJob) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1002,7 +584,7 @@ func (m *CronJob) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1016,7 +598,7 @@ func (m *CronJob) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1032,7 +614,7 @@ func (m *CronJob) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1046,7 +628,7 @@ func (m *CronJob) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1062,7 +644,7 @@ func (m *CronJob) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1076,13 +658,13 @@ func (m *CronJob) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1101,8 +683,8 @@ func (m *CronJob) Unmarshal(data []byte) error { } return nil } -func (m *CronJobList) Unmarshal(data []byte) error { - l := len(data) +func (m *CronJobList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1114,7 +696,7 @@ func (m *CronJobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1142,7 +724,7 @@ func (m *CronJobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1156,7 +738,7 @@ func (m *CronJobList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1172,7 +754,7 @@ func (m *CronJobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1187,13 +769,13 @@ func (m *CronJobList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, CronJob{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1212,8 +794,8 @@ func (m *CronJobList) Unmarshal(data []byte) error { } return nil } -func (m *CronJobSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *CronJobSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1225,7 +807,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1253,7 +835,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1268,7 +850,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Schedule = string(data[iNdEx:postIndex]) + m.Schedule = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 0 { @@ -1282,7 +864,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -1302,7 +884,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1317,7 +899,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ConcurrencyPolicy = ConcurrencyPolicy(data[iNdEx:postIndex]) + m.ConcurrencyPolicy = ConcurrencyPolicy(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 0 { @@ -1331,7 +913,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1352,7 +934,7 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1366,654 +948,13 @@ func (m *CronJobSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.JobTemplate.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.JobTemplate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *CronJobStatus) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: CronJobStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: CronJobStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Active", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Active = append(m.Active, k8s_io_kubernetes_pkg_api_v1.ObjectReference{}) - if err := m.Active[len(m.Active)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastScheduleTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.LastScheduleTime == nil { - m.LastScheduleTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} - } - if err := m.LastScheduleTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Job) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Job: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Job: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *JobCondition) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: JobCondition: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: JobCondition: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Type = JobConditionType(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastProbeTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.LastProbeTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Reason = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *JobList) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: JobList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: JobList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Items = append(m.Items, Job{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *JobSpec) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: JobSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: JobSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: + case 6: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Parallelism", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field SuccessfulJobsHistoryLimit", wireType) } var v int32 for shift := uint(0); ; shift += 7 { @@ -2023,17 +964,17 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - m.Parallelism = &v - case 2: + m.SuccessfulJobsHistoryLimit = &v + case 7: if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Completions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field FailedJobsHistoryLimit", wireType) } var v int32 for shift := uint(0); ; shift += 7 { @@ -2043,121 +984,17 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - m.Completions = &v - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ActiveDeadlineSeconds", wireType) - } - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.ActiveDeadlineSeconds = &v - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} - } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ManualSelector", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - b := bool(v != 0) - m.ManualSelector = &b - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex + m.FailedJobsHistoryLimit = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2176,8 +1013,8 @@ func (m *JobSpec) Unmarshal(data []byte) error { } return nil } -func (m *JobStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *CronJobStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2189,7 +1026,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2199,46 +1036,15 @@ func (m *JobStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: JobStatus: wiretype end group for non-group") + return fmt.Errorf("proto: CronJobStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: JobStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: CronJobStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Conditions = append(m.Conditions, JobCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field StartTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Active", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -2248,7 +1054,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2262,16 +1068,14 @@ func (m *JobStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.StartTime == nil { - m.StartTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} - } - if err := m.StartTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Active = append(m.Active, k8s_io_kubernetes_pkg_api_v1.ObjectReference{}) + if err := m.Active[len(m.Active)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CompletionTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LastScheduleTime", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -2281,7 +1085,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2295,73 +1099,16 @@ func (m *JobStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.CompletionTime == nil { - m.CompletionTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + if m.LastScheduleTime == nil { + m.LastScheduleTime = &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} } - if err := m.CompletionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastScheduleTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Active", wireType) - } - m.Active = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Active |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Succeeded", wireType) - } - m.Succeeded = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Succeeded |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Failed", wireType) - } - m.Failed = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Failed |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2380,8 +1127,8 @@ func (m *JobStatus) Unmarshal(data []byte) error { } return nil } -func (m *JobTemplate) Unmarshal(data []byte) error { - l := len(data) +func (m *JobTemplate) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2393,7 +1140,7 @@ func (m *JobTemplate) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2421,7 +1168,7 @@ func (m *JobTemplate) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2435,7 +1182,7 @@ func (m *JobTemplate) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -2451,7 +1198,7 @@ func (m *JobTemplate) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2465,13 +1212,13 @@ func (m *JobTemplate) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2490,8 +1237,8 @@ func (m *JobTemplate) Unmarshal(data []byte) error { } return nil } -func (m *JobTemplateSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *JobTemplateSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2503,7 +1250,7 @@ func (m *JobTemplateSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2531,7 +1278,7 @@ func (m *JobTemplateSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2545,7 +1292,7 @@ func (m *JobTemplateSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -2561,7 +1308,7 @@ func (m *JobTemplateSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2575,13 +1322,13 @@ func (m *JobTemplateSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2600,8 +1347,8 @@ func (m *JobTemplateSpec) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -2612,7 +1359,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2630,7 +1377,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -2647,7 +1394,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2670,7 +1417,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2681,7 +1428,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -2705,78 +1452,60 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 1141 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xd4, 0x56, 0x4b, 0x6f, 0xe4, 0x44, - 0x10, 0x8e, 0x67, 0x92, 0x79, 0xf4, 0x6c, 0x5e, 0x0d, 0xd1, 0x0e, 0x41, 0x9a, 0x89, 0x46, 0x02, - 0x65, 0x61, 0x63, 0x2b, 0xa3, 0x00, 0xcb, 0x1e, 0x90, 0xd6, 0x41, 0x48, 0x44, 0x89, 0x36, 0xea, - 0xc9, 0x42, 0x04, 0x0b, 0xa2, 0xc7, 0xee, 0xcc, 0x78, 0x63, 0xbb, 0x8d, 0xbb, 0x1d, 0x94, 0x1b, - 0x67, 0x4e, 0x48, 0xfc, 0x00, 0x7e, 0x07, 0x12, 0x1c, 0x38, 0x20, 0xe5, 0xb8, 0x20, 0x21, 0x71, - 0x1a, 0x11, 0xf3, 0x2f, 0x72, 0x42, 0x6e, 0xb7, 0x1f, 0xf3, 0x0a, 0x99, 0xa0, 0x45, 0xe2, 0xe6, - 0xae, 0xae, 0xef, 0xeb, 0xea, 0xaa, 0xaf, 0xab, 0x0c, 0xde, 0x3d, 0x7d, 0xc0, 0x54, 0x8b, 0x6a, - 0xa7, 0x41, 0x97, 0xf8, 0x2e, 0xe1, 0x84, 0x69, 0xde, 0x69, 0x4f, 0xc3, 0x9e, 0xc5, 0xb4, 0x2e, - 0xe6, 0x46, 0x5f, 0x3b, 0x6b, 0x63, 0xdb, 0xeb, 0xe3, 0x6d, 0xad, 0x47, 0x5c, 0xe2, 0x63, 0x4e, - 0x4c, 0xd5, 0xf3, 0x29, 0xa7, 0xf0, 0x5e, 0x0c, 0x55, 0x33, 0xa8, 0xea, 0x9d, 0xf6, 0xd4, 0x08, - 0xaa, 0x0a, 0xa8, 0x9a, 0x40, 0xd7, 0xb7, 0x7a, 0x16, 0xef, 0x07, 0x5d, 0xd5, 0xa0, 0x8e, 0xd6, - 0xa3, 0x3d, 0xaa, 0x09, 0x86, 0x6e, 0x70, 0x22, 0x56, 0x62, 0x21, 0xbe, 0x62, 0xe6, 0xf5, 0xf6, - 0xd4, 0xa0, 0x34, 0x9f, 0x30, 0x1a, 0xf8, 0x06, 0x19, 0x8d, 0x66, 0xfd, 0xad, 0xe9, 0x98, 0xc0, - 0x3d, 0x23, 0x3e, 0xb3, 0xa8, 0x4b, 0xcc, 0x31, 0xd8, 0xfd, 0xe9, 0xb0, 0xb3, 0xb1, 0x2b, 0xaf, - 0x6f, 0x4d, 0xf6, 0xf6, 0x03, 0x97, 0x5b, 0xce, 0x78, 0x4c, 0xdb, 0x93, 0xdd, 0x03, 0x6e, 0xd9, - 0x9a, 0xe5, 0x72, 0xc6, 0xfd, 0x51, 0x48, 0xeb, 0xfb, 0x02, 0x28, 0xef, 0xfa, 0xd4, 0xdd, 0xa3, - 0x5d, 0x78, 0x0c, 0x2a, 0x0e, 0xe1, 0xd8, 0xc4, 0x1c, 0xd7, 0x95, 0x0d, 0x65, 0xb3, 0xd6, 0xde, - 0x54, 0xa7, 0xe6, 0x5c, 0x3d, 0xdb, 0x56, 0x1f, 0x77, 0x9f, 0x11, 0x83, 0x1f, 0x10, 0x8e, 0x75, - 0x78, 0x31, 0x68, 0xce, 0x85, 0x83, 0x26, 0xc8, 0x6c, 0x28, 0x65, 0x83, 0xc7, 0x60, 0x9e, 0x79, - 0xc4, 0xa8, 0x17, 0x04, 0xeb, 0xdb, 0xea, 0x8d, 0x2b, 0xa9, 0xca, 0xd8, 0x3a, 0x1e, 0x31, 0xf4, - 0x3b, 0xf2, 0x8c, 0xf9, 0x68, 0x85, 0x04, 0x23, 0xfc, 0x02, 0x94, 0x18, 0xc7, 0x3c, 0x60, 0xf5, - 0xa2, 0xe0, 0x7e, 0x70, 0x0b, 0x6e, 0x81, 0xd7, 0x97, 0x24, 0x7b, 0x29, 0x5e, 0x23, 0xc9, 0xdb, - 0xfa, 0x45, 0x01, 0x35, 0xe9, 0xb9, 0x6f, 0x31, 0x0e, 0x3f, 0x1b, 0xcb, 0x92, 0x76, 0x4d, 0x96, - 0x72, 0x5a, 0x50, 0x23, 0xb8, 0x48, 0xd6, 0x8a, 0x3c, 0xaa, 0x92, 0x58, 0x72, 0xa9, 0xfa, 0x18, - 0x2c, 0x58, 0x9c, 0x38, 0xac, 0x5e, 0xd8, 0x28, 0x6e, 0xd6, 0xda, 0xed, 0xd9, 0xef, 0xa3, 0x2f, - 0x4a, 0xfa, 0x85, 0x0f, 0x23, 0x22, 0x14, 0xf3, 0xb5, 0xbe, 0x29, 0xa6, 0xf7, 0x88, 0xf2, 0x07, - 0xef, 0x83, 0x0a, 0x33, 0xfa, 0xc4, 0x0c, 0x6c, 0x22, 0xee, 0x51, 0xcd, 0xc2, 0xea, 0x48, 0x3b, - 0x4a, 0x3d, 0xe0, 0x13, 0x70, 0x97, 0x71, 0xec, 0x73, 0xcb, 0xed, 0xbd, 0x4f, 0xb0, 0x69, 0x5b, - 0x2e, 0xe9, 0x10, 0x83, 0xba, 0x26, 0x13, 0x45, 0x2d, 0xea, 0xaf, 0x86, 0x83, 0xe6, 0xdd, 0xce, - 0x64, 0x17, 0x34, 0x0d, 0x0b, 0x9f, 0x82, 0x55, 0x83, 0xba, 0x46, 0xe0, 0xfb, 0xc4, 0x35, 0xce, - 0x0f, 0xa9, 0x6d, 0x19, 0xe7, 0xa2, 0x92, 0x55, 0x5d, 0x95, 0xd1, 0xac, 0xee, 0x8e, 0x3a, 0x5c, - 0x4d, 0x32, 0xa2, 0x71, 0x22, 0xf8, 0x1a, 0x28, 0xb3, 0x80, 0x79, 0xc4, 0x35, 0xeb, 0xf3, 0x1b, - 0xca, 0x66, 0x45, 0xaf, 0x85, 0x83, 0x66, 0xb9, 0x13, 0x9b, 0x50, 0xb2, 0x07, 0xbf, 0x04, 0xb5, - 0x67, 0xb4, 0x7b, 0x44, 0x1c, 0xcf, 0xc6, 0x9c, 0xd4, 0x17, 0x44, 0x51, 0x1f, 0xce, 0x90, 0xf8, - 0xbd, 0x0c, 0x2d, 0x84, 0xfa, 0x92, 0x0c, 0xbd, 0x96, 0xdb, 0x40, 0xf9, 0x33, 0x5a, 0xbf, 0x2b, - 0x60, 0x71, 0x48, 0x7e, 0xf0, 0x09, 0x28, 0x61, 0x83, 0x5b, 0x67, 0x51, 0x31, 0xa2, 0xc2, 0x6f, - 0xdd, 0xe4, 0xe9, 0x21, 0x72, 0x42, 0xa2, 0x0b, 0x93, 0x4c, 0xbd, 0x8f, 0x04, 0x09, 0x92, 0x64, - 0xd0, 0x01, 0x2b, 0x36, 0x66, 0x3c, 0xa9, 0xe8, 0x91, 0xe5, 0x10, 0x91, 0x8b, 0x5a, 0xfb, 0xcd, - 0x1b, 0xaa, 0x36, 0x82, 0xe8, 0x2f, 0x87, 0x83, 0xe6, 0xca, 0xfe, 0x08, 0x11, 0x1a, 0xa3, 0x6e, - 0x7d, 0x57, 0x00, 0xc5, 0x17, 0xdb, 0x4a, 0x8e, 0x86, 0x5a, 0x49, 0x7b, 0xb6, 0x2a, 0x4d, 0x6d, - 0x23, 0x4f, 0x47, 0xda, 0xc8, 0xce, 0x8c, 0xbc, 0xd7, 0xb7, 0x90, 0xdf, 0x8a, 0xe0, 0xce, 0x1e, - 0xed, 0xee, 0x52, 0xd7, 0xb4, 0xb8, 0x45, 0x5d, 0xb8, 0x03, 0xe6, 0xf9, 0xb9, 0x97, 0xbc, 0xbb, - 0x8d, 0x24, 0xa0, 0xa3, 0x73, 0x8f, 0x5c, 0x0d, 0x9a, 0x2b, 0x79, 0xdf, 0xc8, 0x86, 0x84, 0x37, - 0xfc, 0x28, 0x0d, 0xb2, 0x20, 0x70, 0xef, 0x0d, 0x1f, 0x77, 0x35, 0x68, 0x5e, 0x3b, 0x5d, 0xd4, - 0x94, 0x73, 0x38, 0x3c, 0xd8, 0x07, 0x8b, 0x51, 0x21, 0x0f, 0x7d, 0xda, 0x8d, 0x05, 0x52, 0x9c, - 0x5d, 0x20, 0x6b, 0x32, 0x96, 0xc5, 0xfd, 0x3c, 0x13, 0x1a, 0x26, 0x86, 0x5f, 0x01, 0x18, 0x19, - 0x8e, 0x7c, 0xec, 0xb2, 0xf8, 0x76, 0xb7, 0xd4, 0xe3, 0xba, 0x3c, 0x0e, 0xee, 0x8f, 0xd1, 0xa1, - 0x09, 0x47, 0xc0, 0xd7, 0x41, 0xc9, 0x27, 0x98, 0x51, 0x57, 0xbc, 0xee, 0x6a, 0x56, 0x29, 0x24, - 0xac, 0x48, 0xee, 0xc2, 0x7b, 0xa0, 0xec, 0x10, 0xc6, 0x70, 0x8f, 0xd4, 0x4b, 0xc2, 0x71, 0x59, - 0x3a, 0x96, 0x0f, 0x62, 0x33, 0x4a, 0xf6, 0x5b, 0x3f, 0x29, 0xa0, 0xfc, 0x1f, 0xcd, 0x84, 0xce, - 0xf0, 0x4c, 0x50, 0x67, 0x13, 0xe7, 0x94, 0x79, 0xf0, 0x43, 0x51, 0xc4, 0x2f, 0x66, 0xc1, 0x36, - 0xa8, 0x79, 0xd8, 0xc7, 0xb6, 0x4d, 0x6c, 0x8b, 0x39, 0xe2, 0x0a, 0x0b, 0xfa, 0x72, 0xd4, 0xc1, - 0x0e, 0x33, 0x33, 0xca, 0xfb, 0x44, 0x10, 0x83, 0x3a, 0x9e, 0x4d, 0xa2, 0x1c, 0xc7, 0x8a, 0x94, - 0x90, 0xdd, 0xcc, 0x8c, 0xf2, 0x3e, 0xf0, 0x31, 0x58, 0x8b, 0xbb, 0xd2, 0xe8, 0x04, 0x29, 0x8a, - 0x09, 0xf2, 0x4a, 0x38, 0x68, 0xae, 0x3d, 0x9a, 0xe4, 0x80, 0x26, 0xe3, 0xe0, 0xe7, 0xa0, 0xc2, - 0x88, 0x4d, 0x0c, 0x4e, 0x7d, 0x29, 0xa2, 0x9d, 0x9b, 0xa6, 0x1d, 0x77, 0x89, 0xdd, 0x91, 0x58, - 0xfd, 0x8e, 0x18, 0x7a, 0x72, 0x85, 0x52, 0x4e, 0xf8, 0x10, 0x2c, 0x39, 0xd8, 0x0d, 0x70, 0xea, - 0x29, 0xd4, 0x53, 0xd1, 0x61, 0x38, 0x68, 0x2e, 0x1d, 0x0c, 0xed, 0xa0, 0x11, 0x4f, 0xf8, 0x29, - 0xa8, 0xf0, 0x64, 0xa2, 0x94, 0x44, 0x6c, 0xff, 0xd0, 0xd1, 0x0f, 0xa9, 0x39, 0x34, 0x44, 0x52, - 0x41, 0xa4, 0x13, 0x24, 0x25, 0x6c, 0xfd, 0x58, 0x04, 0xd5, 0x6c, 0x74, 0x9c, 0x02, 0x60, 0x24, - 0x4f, 0x9b, 0xc9, 0xf1, 0xf1, 0xce, 0x6c, 0x1a, 0x49, 0x5b, 0x43, 0xd6, 0x7d, 0x53, 0x13, 0x43, - 0x39, 0x7a, 0x78, 0x0c, 0xaa, 0x62, 0x98, 0x8b, 0x97, 0x5b, 0x98, 0xfd, 0xe5, 0x2e, 0x86, 0x83, - 0x66, 0xb5, 0x93, 0x30, 0xa0, 0x8c, 0x0c, 0xf6, 0xc0, 0x52, 0xa6, 0x96, 0xdb, 0xf6, 0x21, 0x51, - 0x9a, 0xdd, 0x21, 0x1a, 0x34, 0x42, 0x1b, 0x35, 0x03, 0x39, 0x6a, 0xe7, 0x85, 0x6a, 0xa7, 0xcd, - 0x4e, 0x0d, 0x54, 0x59, 0x60, 0x18, 0x84, 0x98, 0xc4, 0x14, 0x95, 0x5f, 0xd0, 0x57, 0xa5, 0x6b, - 0xb5, 0x93, 0x6c, 0xa0, 0xcc, 0x27, 0x22, 0x3e, 0xc1, 0x96, 0x4d, 0x4c, 0x51, 0xf1, 0x1c, 0xf1, - 0x07, 0xc2, 0x8a, 0xe4, 0x6e, 0xeb, 0x57, 0x05, 0xe4, 0x7f, 0x0d, 0x5e, 0xe0, 0xb4, 0xec, 0xe7, - 0x54, 0x58, 0xf8, 0xd7, 0xff, 0x35, 0xd7, 0x49, 0xf2, 0x67, 0x05, 0x2c, 0x8f, 0xf8, 0xff, 0xdf, - 0xfe, 0x02, 0xf4, 0x37, 0x2e, 0x2e, 0x1b, 0x73, 0xcf, 0x2f, 0x1b, 0x73, 0x7f, 0x5c, 0x36, 0xe6, - 0xbe, 0x0e, 0x1b, 0xca, 0x45, 0xd8, 0x50, 0x9e, 0x87, 0x0d, 0xe5, 0xcf, 0xb0, 0xa1, 0x7c, 0xfb, - 0x57, 0x63, 0xee, 0x93, 0x4a, 0xc2, 0xf3, 0x77, 0x00, 0x00, 0x00, 0xff, 0xff, 0x63, 0x4c, 0xf3, - 0xee, 0xc9, 0x0e, 0x00, 0x00, + // 786 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x4d, 0x4f, 0xdb, 0x48, + 0x18, 0xc7, 0xe3, 0x90, 0x37, 0x26, 0xcb, 0x2e, 0x78, 0x57, 0x10, 0x65, 0x25, 0x27, 0x8a, 0xb4, + 0x52, 0x76, 0x05, 0xe3, 0x25, 0xac, 0x10, 0xdb, 0x5b, 0x4d, 0x55, 0xb5, 0x88, 0xbe, 0xc8, 0x01, + 0xb5, 0xaa, 0x50, 0xc5, 0xd8, 0x99, 0x24, 0x43, 0xfc, 0x56, 0xcf, 0x38, 0x52, 0x6e, 0xfd, 0x08, + 0xfd, 0x16, 0xfd, 0x16, 0xbd, 0xb4, 0x07, 0x8e, 0x1c, 0x7a, 0xa0, 0x97, 0xa8, 0xb8, 0xdf, 0xa2, + 0xa7, 0xca, 0x13, 0x27, 0x0e, 0x38, 0x2e, 0xa1, 0x95, 0xb8, 0x79, 0xc6, 0xcf, 0xff, 0x37, 0xcf, + 0xf3, 0x7f, 0x9e, 0x19, 0xf0, 0x7f, 0x6f, 0x87, 0x42, 0x62, 0xcb, 0x3d, 0x4f, 0xc3, 0xae, 0x85, + 0x19, 0xa6, 0xb2, 0xd3, 0xeb, 0xc8, 0xc8, 0x21, 0x54, 0xd6, 0x10, 0xd3, 0xbb, 0x72, 0xbf, 0x81, + 0x0c, 0xa7, 0x8b, 0x36, 0xe5, 0x0e, 0xb6, 0xb0, 0x8b, 0x18, 0x6e, 0x41, 0xc7, 0xb5, 0x99, 0x2d, + 0xfe, 0x3d, 0x92, 0xc2, 0x48, 0x0a, 0x9d, 0x5e, 0x07, 0x06, 0x52, 0xc8, 0xa5, 0x70, 0x2c, 0x2d, + 0x6f, 0x74, 0x08, 0xeb, 0x7a, 0x1a, 0xd4, 0x6d, 0x53, 0xee, 0xd8, 0x1d, 0x5b, 0xe6, 0x04, 0xcd, + 0x6b, 0xf3, 0x15, 0x5f, 0xf0, 0xaf, 0x11, 0xb9, 0xfc, 0x5f, 0x98, 0x14, 0x72, 0x88, 0x89, 0xf4, + 0x2e, 0xb1, 0xb0, 0x3b, 0x88, 0xd2, 0x32, 0x31, 0x43, 0x72, 0x3f, 0x96, 0x4f, 0x59, 0x4e, 0x52, + 0xb9, 0x9e, 0xc5, 0x88, 0x89, 0x63, 0x82, 0xed, 0xeb, 0x04, 0x54, 0xef, 0x62, 0x13, 0xc5, 0x74, + 0x5b, 0x49, 0x3a, 0x8f, 0x11, 0x43, 0x26, 0x16, 0xa3, 0xcc, 0x8d, 0x89, 0xd6, 0x13, 0x8d, 0x9e, + 0x55, 0xcb, 0xd6, 0xf5, 0x6d, 0x89, 0x89, 0x6a, 0x6f, 0xd3, 0x20, 0xbf, 0xeb, 0xda, 0xd6, 0x9e, + 0xad, 0x89, 0xc7, 0xa0, 0x10, 0xf8, 0xd4, 0x42, 0x0c, 0x95, 0x84, 0xaa, 0x50, 0x2f, 0x36, 0xfe, + 0x85, 0x61, 0xbf, 0xa6, 0xd3, 0x8e, 0x3a, 0x16, 0x44, 0xc3, 0xfe, 0x26, 0x7c, 0xa2, 0x9d, 0x60, + 0x9d, 0x3d, 0xc2, 0x0c, 0x29, 0xe2, 0xe9, 0xb0, 0x92, 0xf2, 0x87, 0x15, 0x10, 0xed, 0xa9, 0x13, + 0xaa, 0xf8, 0x1c, 0x64, 0xa8, 0x83, 0xf5, 0x52, 0x9a, 0xd3, 0xb7, 0xe1, 0xdc, 0xd3, 0x00, 0xc3, + 0x1c, 0x9b, 0x0e, 0xd6, 0x95, 0x5f, 0xc2, 0x33, 0x32, 0xc1, 0x4a, 0xe5, 0x44, 0xf1, 0x18, 0xe4, + 0x28, 0x43, 0xcc, 0xa3, 0xa5, 0x05, 0xce, 0xde, 0xf9, 0x01, 0x36, 0xd7, 0x2b, 0xbf, 0x86, 0xf4, + 0xdc, 0x68, 0xad, 0x86, 0xdc, 0xda, 0x07, 0x01, 0x14, 0xc3, 0xc8, 0x7d, 0x42, 0x99, 0x78, 0x14, + 0x73, 0x0b, 0xce, 0xe7, 0x56, 0xa0, 0xe6, 0x5e, 0x2d, 0x87, 0x27, 0x15, 0xc6, 0x3b, 0x53, 0x4e, + 0x3d, 0x03, 0x59, 0xc2, 0xb0, 0x49, 0x4b, 0xe9, 0xea, 0x42, 0xbd, 0xd8, 0x68, 0xdc, 0xbc, 0x1c, + 0x65, 0x29, 0xc4, 0x67, 0x1f, 0x06, 0x20, 0x75, 0xc4, 0xab, 0xbd, 0xcb, 0x4c, 0xca, 0x08, 0xec, + 0x13, 0xd7, 0x41, 0x21, 0x18, 0xd9, 0x96, 0x67, 0x60, 0x5e, 0xc6, 0x62, 0x94, 0x56, 0x33, 0xdc, + 0x57, 0x27, 0x11, 0xe2, 0x21, 0x58, 0xa3, 0x0c, 0xb9, 0x8c, 0x58, 0x9d, 0x7b, 0x18, 0xb5, 0x0c, + 0x62, 0xe1, 0x26, 0xd6, 0x6d, 0xab, 0x45, 0x79, 0x4f, 0x17, 0x94, 0x3f, 0xfd, 0x61, 0x65, 0xad, + 0x39, 0x3b, 0x44, 0x4d, 0xd2, 0x8a, 0x47, 0x60, 0x45, 0xb7, 0x2d, 0xdd, 0x73, 0x5d, 0x6c, 0xe9, + 0x83, 0xa7, 0xb6, 0x41, 0xf4, 0x01, 0x6f, 0xe4, 0xa2, 0x02, 0xc3, 0x6c, 0x56, 0x76, 0xaf, 0x06, + 0x7c, 0x9d, 0xb5, 0xa9, 0xc6, 0x41, 0xe2, 0x5f, 0x20, 0x4f, 0x3d, 0xea, 0x60, 0xab, 0x55, 0xca, + 0x54, 0x85, 0x7a, 0x41, 0x29, 0xfa, 0xc3, 0x4a, 0xbe, 0x39, 0xda, 0x52, 0xc7, 0xff, 0xc4, 0x57, + 0xa0, 0x78, 0x62, 0x6b, 0x07, 0xd8, 0x74, 0x0c, 0xc4, 0x70, 0x29, 0xcb, 0x7b, 0x7a, 0xe7, 0x06, + 0xc6, 0xef, 0x45, 0x6a, 0x3e, 0xa7, 0xbf, 0x87, 0xa9, 0x17, 0xa7, 0x7e, 0xa8, 0xd3, 0x67, 0x88, + 0x2f, 0x41, 0x99, 0x7a, 0xba, 0x8e, 0x29, 0x6d, 0x7b, 0xc6, 0x9e, 0xad, 0xd1, 0x07, 0x84, 0x32, + 0xdb, 0x1d, 0xec, 0x13, 0x93, 0xb0, 0x52, 0xae, 0x2a, 0xd4, 0xb3, 0x8a, 0xe4, 0x0f, 0x2b, 0xe5, + 0x66, 0x62, 0x94, 0xfa, 0x1d, 0x82, 0xa8, 0x82, 0xd5, 0x36, 0x22, 0x06, 0x6e, 0xc5, 0xd8, 0x79, + 0xce, 0x2e, 0xfb, 0xc3, 0xca, 0xea, 0xfd, 0x99, 0x11, 0x6a, 0x82, 0xb2, 0xf6, 0x51, 0x00, 0x4b, + 0x97, 0x6e, 0x8c, 0x78, 0x08, 0x72, 0x48, 0x67, 0xa4, 0x1f, 0x0c, 0x50, 0x30, 0xac, 0x1b, 0xc9, + 0x9e, 0x45, 0xaf, 0x85, 0x8a, 0xdb, 0x38, 0x68, 0x12, 0x8e, 0x2e, 0xdc, 0x5d, 0x0e, 0x51, 0x43, + 0x98, 0x68, 0x80, 0x65, 0x03, 0x51, 0x36, 0x9e, 0xc2, 0x03, 0x62, 0x62, 0xde, 0xbf, 0x62, 0xe3, + 0x9f, 0xf9, 0x2e, 0x5a, 0xa0, 0x50, 0xfe, 0xf0, 0x87, 0x95, 0xe5, 0xfd, 0x2b, 0x1c, 0x35, 0x46, + 0xae, 0x7d, 0x12, 0xc0, 0x74, 0x9f, 0x6e, 0xe1, 0x31, 0xec, 0x82, 0x02, 0x1b, 0x0f, 0x5b, 0xfa, + 0xa7, 0x87, 0x6d, 0x72, 0x6b, 0x27, 0x93, 0x36, 0xa1, 0xd7, 0xde, 0x0b, 0xe0, 0xb7, 0x2b, 0xf1, + 0xb7, 0x50, 0xdf, 0xe3, 0x4b, 0x8f, 0xfd, 0xfa, 0x1c, 0xb5, 0xf1, 0xaa, 0x92, 0x9e, 0x78, 0x05, + 0x9e, 0x5e, 0x48, 0xa9, 0xb3, 0x0b, 0x29, 0x75, 0x7e, 0x21, 0xa5, 0x5e, 0xfb, 0x92, 0x70, 0xea, + 0x4b, 0xc2, 0x99, 0x2f, 0x09, 0xe7, 0xbe, 0x24, 0x7c, 0xf6, 0x25, 0xe1, 0xcd, 0x17, 0x29, 0xf5, + 0xa2, 0x30, 0x76, 0xe8, 0x5b, 0x00, 0x00, 0x00, 0xff, 0xff, 0x88, 0x78, 0x12, 0x5b, 0xa7, 0x08, + 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto index 8f4995a5c7..48509d6f51 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,14 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.batch.v2alpha1; +package k8s.io.client_go.pkg.apis.batch.v2alpha1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/batch/v1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v2alpha1"; @@ -33,35 +34,35 @@ option go_package = "v2alpha1"; // CronJob represents the configuration of a single cron job. message CronJob { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // Spec is a structure defining the expected behavior of a job, including the schedule. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Specification of the desired behavior of a cron job, including the schedule. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional CronJobSpec spec = 2; - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Current status of a cron job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional CronJobStatus status = 3; } // CronJobList is a collection of cron jobs. message CronJobList { - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; - // Items is the list of CronJob. + // items is the list of CronJobs. repeated CronJob items = 2; } // CronJobSpec describes how the job execution will look like and when it will actually run. message CronJobSpec { - // Schedule contains the schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. + // The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. optional string schedule = 1; // Optional deadline in seconds for starting the job if it misses scheduled @@ -69,175 +70,50 @@ message CronJobSpec { // +optional optional int64 startingDeadlineSeconds = 2; - // ConcurrencyPolicy specifies how to treat concurrent executions of a Job. + // Specifies how to treat concurrent executions of a Job. + // Defaults to Allow. // +optional optional string concurrencyPolicy = 3; - // Suspend flag tells the controller to suspend subsequent executions, it does + // This flag tells the controller to suspend subsequent executions, it does // not apply to already started executions. Defaults to false. // +optional optional bool suspend = 4; - // JobTemplate is the object that describes the job that will be created when - // executing a CronJob. + // Specifies the job that will be created when executing a CronJob. optional JobTemplateSpec jobTemplate = 5; -} - -// CronJobStatus represents the current state of a cron job. -message CronJobStatus { - // Active holds pointers to currently running jobs. - // +optional - repeated k8s.io.kubernetes.pkg.api.v1.ObjectReference active = 1; - - // LastScheduleTime keeps information of when was the last time the job was successfully scheduled. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastScheduleTime = 4; -} - -// Job represents the configuration of a single job. -message Job { - // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; - - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - optional JobSpec spec = 2; - - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - optional JobStatus status = 3; -} - -// JobCondition describes current state of a job. -message JobCondition { - // Type of job condition, Complete or Failed. - optional string type = 1; - - // Status of the condition, one of True, False, Unknown. - optional string status = 2; - - // Last time the condition was checked. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3; - - // Last time the condition transit from one status to another. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4; - - // (brief) reason for the condition's last transition. - // +optional - optional string reason = 5; - // Human readable message indicating details about last transition. + // The number of successful finished jobs to retain. + // This is a pointer to distinguish between explicit zero and not specified. // +optional - optional string message = 6; -} - -// JobList is a collection of jobs. -message JobList { - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; - - // Items is the list of Job. - repeated Job items = 2; -} - -// JobSpec describes how the job execution will look like. -message JobSpec { - // Parallelism specifies the maximum desired number of pods the job should - // run at any given time. The actual number of pods running in steady state will - // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), - // i.e. when the work left to do is less than max parallelism. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - optional int32 parallelism = 1; - - // Completions specifies the desired number of successfully finished pods the - // job should be run with. Setting to nil means that the success of any - // pod signals the success of all pods, and allows parallelism to have any positive - // value. Setting to 1 means that parallelism is limited to 1 and the success of that - // pod signals the success of the job. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - optional int32 completions = 2; - - // Optional duration in seconds relative to the startTime that the job may be active - // before the system tries to terminate it; value must be positive integer - // +optional - optional int64 activeDeadlineSeconds = 3; - - // Selector is a label query over pods that should match the pod count. - // Normally, the system sets this field for you. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 4; + optional int32 successfulJobsHistoryLimit = 6; - // ManualSelector controls generation of pod labels and pod selectors. - // Leave `manualSelector` unset unless you are certain what you are doing. - // When false or unset, the system pick labels unique to this job - // and appends those labels to the pod template. When true, - // the user is responsible for picking unique labels and specifying - // the selector. Failure to pick a unique label may cause this - // and other jobs to not function correctly. However, You may see - // `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` - // API. - // More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md + // The number of failed finished jobs to retain. + // This is a pointer to distinguish between explicit zero and not specified. // +optional - optional bool manualSelector = 5; - - // Template is the object that describes the pod that will be created when - // executing a job. - // More info: http://kubernetes.io/docs/user-guide/jobs - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 6; + optional int32 failedJobsHistoryLimit = 7; } -// JobStatus represents the current state of a Job. -message JobStatus { - // Conditions represent the latest available observations of an object's current state. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - repeated JobCondition conditions = 1; - - // StartTime represents time when the job was acknowledged by the Job Manager. - // It is not guaranteed to be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 2; - - // CompletionTime represents time when the job was completed. It is not guaranteed to - // be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time completionTime = 3; - - // Active is the number of actively running pods. - // +optional - optional int32 active = 4; - - // Succeeded is the number of pods which reached Phase Succeeded. +// CronJobStatus represents the current state of a cron job. +message CronJobStatus { + // A list of pointers to currently running jobs. // +optional - optional int32 succeeded = 5; + repeated k8s.io.client_go.pkg.api.v1.ObjectReference active = 1; - // Failed is the number of pods which reached Phase Failed. + // Information when was the last time the job was successfully scheduled. // +optional - optional int32 failed = 6; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastScheduleTime = 4; } // JobTemplate describes a template for creating copies of a predefined pod. message JobTemplate { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // Template defines jobs that will be created from this template - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Defines jobs that will be created from this template. + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional JobTemplateSpec template = 2; } @@ -245,13 +121,13 @@ message JobTemplate { // JobTemplateSpec describes the data a Job should have when created from a template message JobTemplateSpec { // Standard object's metadata of the jobs created from this template. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Specification of the desired behavior of the job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - optional JobSpec spec = 2; + optional k8s.io.client_go.pkg.apis.batch.v1.JobSpec spec = 2; } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/register.go index 5bb82b5bbc..11a397820f 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/register.go @@ -17,36 +17,46 @@ limitations under the License. package v2alpha1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "batch" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v2alpha1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v2alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &Job{}, - &JobList{}, &JobTemplate{}, &CronJob{}, &CronJobList{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, ) scheme.AddKnownTypeWithName(SchemeGroupVersion.WithKind("ScheduledJob"), &CronJob{}) scheme.AddKnownTypeWithName(SchemeGroupVersion.WithKind("ScheduledJobList"), &CronJobList{}) - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.generated.go index f2fa2a6b51..9e72e7d22d 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.generated.go @@ -25,11 +25,12 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/pkg/util/intstr" + pkg5_resource "k8s.io/apimachinery/pkg/api/resource" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg6_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg4_v1 "k8s.io/client-go/pkg/api/v1" + pkg3_v1 "k8s.io/client-go/pkg/apis/batch/v1" "reflect" "runtime" time "time" @@ -65,17 +66,18 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg4_resource.Quantity - var v1 pkg1_unversioned.TypeMeta - var v2 pkg2_v1.ObjectMeta - var v3 pkg3_types.UID - var v4 pkg5_intstr.IntOrString - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 + var v0 pkg5_resource.Quantity + var v1 pkg1_v1.TypeMeta + var v2 pkg2_types.UID + var v3 pkg6_intstr.IntOrString + var v4 pkg4_v1.PodTemplateSpec + var v5 pkg3_v1.JobSpec + var v6 time.Time + _, _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5, v6 } } -func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *JobTemplate) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r @@ -89,17 +91,16 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool + var yyq2 [4]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false yyq2[0] = x.Kind != "" yyq2[1] = x.APIVersion != "" yyq2[2] = true yyq2[3] = true - yyq2[4] = true var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) + r.EncodeArrayStart(4) } else { yynn2 = 0 for _, b := range yyq2 { @@ -164,7 +165,13 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[2] { yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } @@ -173,41 +180,30 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) + yy15 := &x.Template + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) + r.EncodeString(codecSelferC_UTF81234, string("template")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status + yy17 := &x.Template yy17.CodecEncodeSelf(e) } } @@ -220,29 +216,29 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *JobTemplate) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl19, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl19, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -250,16 +246,16 @@ func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *JobTemplate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -268,414 +264,75 @@ func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { + switch yys3 { 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 = pkg2_v1.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = JobStatus{} - } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = JobStatus{} - } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [4]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[0] = x.Kind != "" - yyq33[1] = x.APIVersion != "" - yyq33[2] = true - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(4) - } else { - yynn33 = 1 - for _, b := range yyq33 { - if b { - yynn33++ - } - } - r.EncodeMapStart(yynn33) - yynn33 = 0 - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[0] { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[2] { - yy41 := &x.ListMeta - yym42 := z.EncBinary() - _ = yym42 - if false { - } else if z.HasExtensions() && z.EncExt(yy41) { - } else { - z.EncFallback(yy41) - } - } else { - r.EncodeNil() - } - } else { - if yyq33[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy43 := &x.ListMeta - yym44 := z.EncBinary() - _ = yym44 - if false { - } else if z.HasExtensions() && z.EncExt(yy43) { - } else { - z.EncFallback(yy43) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym46 := z.EncBinary() - _ = yym46 - if false { - } else { - h.encSliceJob(([]Job)(x.Items), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { } else { - yym47 := z.EncBinary() - _ = yym47 - if false { - } else { - h.encSliceJob(([]Job)(x.Items), e) - } + *((*string)(yyv4)) = r.DecodeString() } } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym48 := z.DecBinary() - _ = yym48 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct49 := r.ContainerType() - if yyct49 == codecSelferValueTypeMap1234 { - yyl49 := r.ReadMapStart() - if yyl49 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl49, d) - } - } else if yyct49 == codecSelferValueTypeArray1234 { - yyl49 := r.ReadArrayStart() - if yyl49 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl49, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys50Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys50Slc - var yyhl50 bool = l >= 0 - for yyj50 := 0; ; yyj50++ { - if yyhl50 { - if yyj50 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys50Slc = r.DecodeBytes(yys50Slc, true, true) - yys50 := string(yys50Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys50 { - 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()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv53 := &x.ListMeta - yym54 := z.DecBinary() - _ = yym54 + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv53) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv53, false) + z.DecFallback(yyv8, false) } } - case "items": + case "template": if r.TryDecodeAsNil() { - x.Items = nil + x.Template = JobTemplateSpec{} } else { - yyv55 := &x.Items - yym56 := z.DecBinary() - _ = yym56 - if false { - } else { - h.decSliceJob((*[]Job)(yyv55), d) - } + yyv10 := &x.Template + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys50) - } // end switch yys50 - } // end for yyj50 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *JobTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj57 int - var yyb57 bool - var yyhl57 bool = l >= 0 - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb57 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb57 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -683,15 +340,21 @@ func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb57 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb57 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -699,344 +362,44 @@ func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb57 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb57 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv60 := &x.ListMeta - yym61 := z.DecBinary() - _ = yym61 + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 if false { - } else if z.HasExtensions() && z.DecExt(yyv60) { + } else if z.HasExtensions() && z.DecExt(yyv16) { } else { - z.DecFallback(yyv60, false) + z.DecFallback(yyv16, false) } } - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb57 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb57 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv62 := &x.Items - yym63 := z.DecBinary() - _ = yym63 - if false { - } else { - h.decSliceJob((*[]Job)(yyv62), d) - } - } - for { - yyj57++ - if yyhl57 { - yyb57 = yyj57 > l - } else { - yyb57 = r.CheckBreak() - } - if yyb57 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj57-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobTemplate) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym64 := z.EncBinary() - _ = yym64 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep65 := !z.EncBinary() - yy2arr65 := z.EncBasicHandle().StructToArray - var yyq65 [4]bool - _, _, _ = yysep65, yyq65, yy2arr65 - const yyr65 bool = false - yyq65[0] = x.Kind != "" - yyq65[1] = x.APIVersion != "" - yyq65[2] = true - yyq65[3] = true - var yynn65 int - if yyr65 || yy2arr65 { - r.EncodeArrayStart(4) - } else { - yynn65 = 0 - for _, b := range yyq65 { - if b { - yynn65++ - } - } - r.EncodeMapStart(yynn65) - yynn65 = 0 - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[0] { - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq65[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[1] { - yym70 := z.EncBinary() - _ = yym70 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq65[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym71 := z.EncBinary() - _ = yym71 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[2] { - yy73 := &x.ObjectMeta - yy73.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq65[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy74 := &x.ObjectMeta - yy74.CodecEncodeSelf(e) - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq65[3] { - yy76 := &x.Template - yy76.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq65[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy77 := &x.Template - yy77.CodecEncodeSelf(e) - } - } - if yyr65 || yy2arr65 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobTemplate) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym78 := z.DecBinary() - _ = yym78 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct79 := r.ContainerType() - if yyct79 == codecSelferValueTypeMap1234 { - yyl79 := r.ReadMapStart() - if yyl79 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl79, d) - } - } else if yyct79 == codecSelferValueTypeArray1234 { - yyl79 := r.ReadArrayStart() - if yyl79 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl79, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobTemplate) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys80Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys80Slc - var yyhl80 bool = l >= 0 - for yyj80 := 0; ; yyj80++ { - if yyhl80 { - if yyj80 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys80Slc = r.DecodeBytes(yys80Slc, true, true) - yys80 := string(yys80Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys80 { - 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 = pkg2_v1.ObjectMeta{} - } else { - yyv83 := &x.ObjectMeta - yyv83.CodecDecodeSelf(d) - } - case "template": - if r.TryDecodeAsNil() { - x.Template = JobTemplateSpec{} - } else { - yyv84 := &x.Template - yyv84.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys80) - } // end switch yys80 - } // end for yyj80 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj85 int - var yyb85 bool - var yyhl85 bool = l >= 0 - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv88 := &x.ObjectMeta - yyv88.CodecDecodeSelf(d) - } - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l - } else { - yyb85 = r.CheckBreak() - } - if yyb85 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1044,1518 +407,104 @@ func (x *JobTemplate) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Template = JobTemplateSpec{} } else { - yyv89 := &x.Template - yyv89.CodecDecodeSelf(d) + yyv18 := &x.Template + yyv18.CodecDecodeSelf(d) } for { - yyj85++ - if yyhl85 { - yyb85 = yyj85 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb85 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb85 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj85-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobTemplateSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym90 := z.EncBinary() - _ = yym90 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep91 := !z.EncBinary() - yy2arr91 := z.EncBasicHandle().StructToArray - var yyq91 [2]bool - _, _, _ = yysep91, yyq91, yy2arr91 - const yyr91 bool = false - yyq91[0] = true - yyq91[1] = true - var yynn91 int - if yyr91 || yy2arr91 { - r.EncodeArrayStart(2) - } else { - yynn91 = 0 - for _, b := range yyq91 { - if b { - yynn91++ - } - } - r.EncodeMapStart(yynn91) - yynn91 = 0 - } - if yyr91 || yy2arr91 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq91[0] { - yy93 := &x.ObjectMeta - yy93.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq91[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy94 := &x.ObjectMeta - yy94.CodecEncodeSelf(e) - } - } - if yyr91 || yy2arr91 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq91[1] { - yy96 := &x.Spec - yy96.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq91[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy97 := &x.Spec - yy97.CodecEncodeSelf(e) - } - } - if yyr91 || yy2arr91 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobTemplateSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym98 := z.DecBinary() - _ = yym98 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct99 := r.ContainerType() - if yyct99 == codecSelferValueTypeMap1234 { - yyl99 := r.ReadMapStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl99, d) - } - } else if yyct99 == codecSelferValueTypeArray1234 { - yyl99 := r.ReadArrayStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl99, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobTemplateSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys100Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys100Slc - var yyhl100 bool = l >= 0 - for yyj100 := 0; ; yyj100++ { - if yyhl100 { - if yyj100 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys100Slc = r.DecodeBytes(yys100Slc, true, true) - yys100 := string(yys100Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys100 { - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv101 := &x.ObjectMeta - yyv101.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv102 := &x.Spec - yyv102.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys100) - } // end switch yys100 - } // end for yyj100 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobTemplateSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj103 int - var yyb103 bool - var yyhl103 bool = l >= 0 - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv104 := &x.ObjectMeta - yyv104.CodecDecodeSelf(d) - } - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = JobSpec{} - } else { - yyv105 := &x.Spec - yyv105.CodecDecodeSelf(d) - } - for { - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj103-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym106 := z.EncBinary() - _ = yym106 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep107 := !z.EncBinary() - yy2arr107 := z.EncBasicHandle().StructToArray - var yyq107 [6]bool - _, _, _ = yysep107, yyq107, yy2arr107 - const yyr107 bool = false - yyq107[0] = x.Parallelism != nil - yyq107[1] = x.Completions != nil - yyq107[2] = x.ActiveDeadlineSeconds != nil - yyq107[3] = x.Selector != nil - yyq107[4] = x.ManualSelector != nil - var yynn107 int - if yyr107 || yy2arr107 { - r.EncodeArrayStart(6) - } else { - yynn107 = 1 - for _, b := range yyq107 { - if b { - yynn107++ - } - } - r.EncodeMapStart(yynn107) - yynn107 = 0 - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[0] { - if x.Parallelism == nil { - r.EncodeNil() - } else { - yy109 := *x.Parallelism - yym110 := z.EncBinary() - _ = yym110 - if false { - } else { - r.EncodeInt(int64(yy109)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("parallelism")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Parallelism == nil { - r.EncodeNil() - } else { - yy111 := *x.Parallelism - yym112 := z.EncBinary() - _ = yym112 - if false { - } else { - r.EncodeInt(int64(yy111)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[1] { - if x.Completions == nil { - r.EncodeNil() - } else { - yy114 := *x.Completions - yym115 := z.EncBinary() - _ = yym115 - if false { - } else { - r.EncodeInt(int64(yy114)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("completions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Completions == nil { - r.EncodeNil() - } else { - yy116 := *x.Completions - yym117 := z.EncBinary() - _ = yym117 - if false { - } else { - r.EncodeInt(int64(yy116)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[2] { - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy119 := *x.ActiveDeadlineSeconds - yym120 := z.EncBinary() - _ = yym120 - if false { - } else { - r.EncodeInt(int64(yy119)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy121 := *x.ActiveDeadlineSeconds - yym122 := z.EncBinary() - _ = yym122 - if false { - } else { - r.EncodeInt(int64(yy121)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[3] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym124 := z.EncBinary() - _ = yym124 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym125 := z.EncBinary() - _ = yym125 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq107[4] { - if x.ManualSelector == nil { - r.EncodeNil() - } else { - yy127 := *x.ManualSelector - yym128 := z.EncBinary() - _ = yym128 - if false { - } else { - r.EncodeBool(bool(yy127)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq107[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("manualSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ManualSelector == nil { - r.EncodeNil() - } else { - yy129 := *x.ManualSelector - yym130 := z.EncBinary() - _ = yym130 - if false { - } else { - r.EncodeBool(bool(yy129)) - } - } - } - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy132 := &x.Template - yy132.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy133 := &x.Template - yy133.CodecEncodeSelf(e) - } - if yyr107 || yy2arr107 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym134 := z.DecBinary() - _ = yym134 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct135 := r.ContainerType() - if yyct135 == codecSelferValueTypeMap1234 { - yyl135 := r.ReadMapStart() - if yyl135 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl135, d) - } - } else if yyct135 == codecSelferValueTypeArray1234 { - yyl135 := r.ReadArrayStart() - if yyl135 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl135, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys136Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys136Slc - var yyhl136 bool = l >= 0 - for yyj136 := 0; ; yyj136++ { - if yyhl136 { - if yyj136 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys136Slc = r.DecodeBytes(yys136Slc, true, true) - yys136 := string(yys136Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys136 { - case "parallelism": - if r.TryDecodeAsNil() { - if x.Parallelism != nil { - x.Parallelism = nil - } - } else { - if x.Parallelism == nil { - x.Parallelism = new(int32) - } - yym138 := z.DecBinary() - _ = yym138 - if false { - } else { - *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) - } - } - case "completions": - if r.TryDecodeAsNil() { - if x.Completions != nil { - x.Completions = nil - } - } else { - if x.Completions == nil { - x.Completions = new(int32) - } - yym140 := z.DecBinary() - _ = yym140 - if false { - } else { - *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) - } - } - case "activeDeadlineSeconds": - if r.TryDecodeAsNil() { - if x.ActiveDeadlineSeconds != nil { - x.ActiveDeadlineSeconds = nil - } - } else { - if x.ActiveDeadlineSeconds == nil { - x.ActiveDeadlineSeconds = new(int64) - } - yym142 := z.DecBinary() - _ = yym142 - if false { - } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym144 := z.DecBinary() - _ = yym144 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "manualSelector": - if r.TryDecodeAsNil() { - if x.ManualSelector != nil { - x.ManualSelector = nil - } - } else { - if x.ManualSelector == nil { - x.ManualSelector = new(bool) - } - yym146 := z.DecBinary() - _ = yym146 - if false { - } else { - *((*bool)(x.ManualSelector)) = r.DecodeBool() - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv147 := &x.Template - yyv147.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys136) - } // end switch yys136 - } // end for yyj136 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj148 int - var yyb148 bool - var yyhl148 bool = l >= 0 - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Parallelism != nil { - x.Parallelism = nil - } - } else { - if x.Parallelism == nil { - x.Parallelism = new(int32) - } - yym150 := z.DecBinary() - _ = yym150 - if false { - } else { - *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Completions != nil { - x.Completions = nil - } - } else { - if x.Completions == nil { - x.Completions = new(int32) - } - yym152 := z.DecBinary() - _ = yym152 - if false { - } else { - *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - 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) - } - yym154 := z.DecBinary() - _ = yym154 - if false { - } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - 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(pkg1_unversioned.LabelSelector) - } - yym156 := z.DecBinary() - _ = yym156 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ManualSelector != nil { - x.ManualSelector = nil - } - } else { - if x.ManualSelector == nil { - x.ManualSelector = new(bool) - } - yym158 := z.DecBinary() - _ = yym158 - if false { - } else { - *((*bool)(x.ManualSelector)) = r.DecodeBool() - } - } - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv159 := &x.Template - yyv159.CodecDecodeSelf(d) - } - for { - yyj148++ - if yyhl148 { - yyb148 = yyj148 > l - } else { - yyb148 = r.CheckBreak() - } - if yyb148 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj148-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym160 := z.EncBinary() - _ = yym160 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep161 := !z.EncBinary() - yy2arr161 := z.EncBasicHandle().StructToArray - var yyq161 [6]bool - _, _, _ = yysep161, yyq161, yy2arr161 - const yyr161 bool = false - yyq161[0] = len(x.Conditions) != 0 - yyq161[1] = x.StartTime != nil - yyq161[2] = x.CompletionTime != nil - yyq161[3] = x.Active != 0 - yyq161[4] = x.Succeeded != 0 - yyq161[5] = x.Failed != 0 - var yynn161 int - if yyr161 || yy2arr161 { - r.EncodeArrayStart(6) - } else { - yynn161 = 0 - for _, b := range yyq161 { - if b { - yynn161++ - } - } - r.EncodeMapStart(yynn161) - yynn161 = 0 - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[0] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym163 := z.EncBinary() - _ = yym163 - if false { - } else { - h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq161[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym164 := z.EncBinary() - _ = yym164 - if false { - } else { - h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) - } - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[1] { - if x.StartTime == nil { - r.EncodeNil() - } else { - yym166 := z.EncBinary() - _ = yym166 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym166 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym166 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq161[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StartTime == nil { - r.EncodeNil() - } else { - yym167 := z.EncBinary() - _ = yym167 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym167 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym167 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[2] { - if x.CompletionTime == nil { - r.EncodeNil() - } else { - yym169 := z.EncBinary() - _ = yym169 - if false { - } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym169 { - z.EncBinaryMarshal(x.CompletionTime) - } else if !yym169 && z.IsJSONHandle() { - z.EncJSONMarshal(x.CompletionTime) - } else { - z.EncFallback(x.CompletionTime) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq161[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("completionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CompletionTime == nil { - r.EncodeNil() - } else { - yym170 := z.EncBinary() - _ = yym170 - if false { - } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym170 { - z.EncBinaryMarshal(x.CompletionTime) - } else if !yym170 && z.IsJSONHandle() { - z.EncJSONMarshal(x.CompletionTime) - } else { - z.EncFallback(x.CompletionTime) - } - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[3] { - yym172 := z.EncBinary() - _ = yym172 - if false { - } else { - r.EncodeInt(int64(x.Active)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq161[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("active")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym173 := z.EncBinary() - _ = yym173 - if false { - } else { - r.EncodeInt(int64(x.Active)) - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[4] { - yym175 := z.EncBinary() - _ = yym175 - if false { - } else { - r.EncodeInt(int64(x.Succeeded)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq161[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("succeeded")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym176 := z.EncBinary() - _ = yym176 - if false { - } else { - r.EncodeInt(int64(x.Succeeded)) - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq161[5] { - yym178 := z.EncBinary() - _ = yym178 - if false { - } else { - r.EncodeInt(int64(x.Failed)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq161[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("failed")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym179 := z.EncBinary() - _ = yym179 - if false { - } else { - r.EncodeInt(int64(x.Failed)) - } - } - } - if yyr161 || yy2arr161 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *JobStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym180 := z.DecBinary() - _ = yym180 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct181 := r.ContainerType() - if yyct181 == codecSelferValueTypeMap1234 { - yyl181 := r.ReadMapStart() - if yyl181 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl181, d) - } - } else if yyct181 == codecSelferValueTypeArray1234 { - yyl181 := r.ReadArrayStart() - if yyl181 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl181, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys182Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys182Slc - var yyhl182 bool = l >= 0 - for yyj182 := 0; ; yyj182++ { - if yyhl182 { - if yyj182 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys182Slc = r.DecodeBytes(yys182Slc, true, true) - yys182 := string(yys182Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys182 { - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv183 := &x.Conditions - yym184 := z.DecBinary() - _ = yym184 - if false { - } else { - h.decSliceJobCondition((*[]JobCondition)(yyv183), d) - } - } - case "startTime": - if r.TryDecodeAsNil() { - if x.StartTime != nil { - x.StartTime = nil - } - } else { - if x.StartTime == nil { - x.StartTime = new(pkg1_unversioned.Time) - } - yym186 := z.DecBinary() - _ = yym186 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym186 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym186 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - case "completionTime": - if r.TryDecodeAsNil() { - if x.CompletionTime != nil { - x.CompletionTime = nil - } - } else { - if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) - } - yym188 := z.DecBinary() - _ = yym188 - if false { - } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym188 { - z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym188 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.CompletionTime) - } else { - z.DecFallback(x.CompletionTime, false) - } - } - case "active": - if r.TryDecodeAsNil() { - x.Active = 0 - } else { - x.Active = int32(r.DecodeInt(32)) - } - case "succeeded": - if r.TryDecodeAsNil() { - x.Succeeded = 0 - } else { - x.Succeeded = int32(r.DecodeInt(32)) - } - case "failed": - if r.TryDecodeAsNil() { - x.Failed = 0 - } else { - x.Failed = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys182) - } // end switch yys182 - } // end for yyj182 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj192 int - var yyb192 bool - var yyhl192 bool = l >= 0 - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv193 := &x.Conditions - yym194 := z.DecBinary() - _ = yym194 - if false { - } else { - h.decSliceJobCondition((*[]JobCondition)(yyv193), d) - } - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - 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(pkg1_unversioned.Time) - } - yym196 := z.DecBinary() - _ = yym196 - if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym196 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym196 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) - } else { - z.DecFallback(x.StartTime, false) - } - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.CompletionTime != nil { - x.CompletionTime = nil - } - } else { - if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) - } - yym198 := z.DecBinary() - _ = yym198 - if false { - } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym198 { - z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym198 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.CompletionTime) - } else { - z.DecFallback(x.CompletionTime, false) - } - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Active = 0 - } else { - x.Active = int32(r.DecodeInt(32)) - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Succeeded = 0 - } else { - x.Succeeded = int32(r.DecodeInt(32)) - } - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Failed = 0 - } else { - x.Failed = int32(r.DecodeInt(32)) - } - for { - yyj192++ - if yyhl192 { - yyb192 = yyj192 > l - } else { - yyb192 = r.CheckBreak() - } - if yyb192 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj192-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x JobConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym202 := z.EncBinary() - _ = yym202 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *JobConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym203 := z.DecBinary() - _ = yym203 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() + z.DecStructFieldNotFound(yyj11-1, "") } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *JobTemplateSpec) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym204 := z.EncBinary() - _ = yym204 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep205 := !z.EncBinary() - yy2arr205 := z.EncBasicHandle().StructToArray - var yyq205 [6]bool - _, _, _ = yysep205, yyq205, yy2arr205 - const yyr205 bool = false - yyq205[2] = true - yyq205[3] = true - yyq205[4] = x.Reason != "" - yyq205[5] = x.Message != "" - var yynn205 int - if yyr205 || yy2arr205 { - r.EncodeArrayStart(6) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = true + yyq2[1] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn205 = 2 - for _, b := range yyq205 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn205++ + yynn2++ } } - r.EncodeMapStart(yynn205) - yynn205 = 0 - } - if yyr205 || yy2arr205 { - 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 yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym208 := z.EncBinary() - _ = yym208 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym209 := z.EncBinary() - _ = yym209 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr205 || yy2arr205 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[2] { - yy211 := &x.LastProbeTime - yym212 := z.EncBinary() - _ = yym212 + if yyq2[0] { + yy4 := &x.ObjectMeta + yym5 := z.EncBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.EncExt(yy211) { - } else if yym212 { - z.EncBinaryMarshal(yy211) - } else if !yym212 && z.IsJSONHandle() { - z.EncJSONMarshal(yy211) + } else if z.HasExtensions() && z.EncExt(yy4) { } else { - z.EncFallback(yy211) + z.EncFallback(yy4) } } else { r.EncodeNil() } } else { - if yyq205[2] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy213 := &x.LastProbeTime - yym214 := z.EncBinary() - _ = yym214 + yy6 := &x.ObjectMeta + yym7 := z.EncBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.EncExt(yy213) { - } else if yym214 { - z.EncBinaryMarshal(yy213) - } else if !yym214 && z.IsJSONHandle() { - z.EncJSONMarshal(yy213) + } else if z.HasExtensions() && z.EncExt(yy6) { } else { - z.EncFallback(yy213) + z.EncFallback(yy6) } } } - if yyr205 || yy2arr205 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[3] { - yy216 := &x.LastTransitionTime - yym217 := z.EncBinary() - _ = yym217 - if false { - } else if z.HasExtensions() && z.EncExt(yy216) { - } else if yym217 { - z.EncBinaryMarshal(yy216) - } else if !yym217 && z.IsJSONHandle() { - z.EncJSONMarshal(yy216) - } else { - z.EncFallback(yy216) - } + if yyq2[1] { + yy9 := &x.Spec + yy9.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq205[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy218 := &x.LastTransitionTime - yym219 := z.EncBinary() - _ = yym219 - if false { - } else if z.HasExtensions() && z.EncExt(yy218) { - } else if yym219 { - z.EncBinaryMarshal(yy218) - } else if !yym219 && z.IsJSONHandle() { - z.EncJSONMarshal(yy218) - } else { - z.EncFallback(yy218) - } - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[4] { - yym221 := z.EncBinary() - _ = yym221 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq205[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym222 := z.EncBinary() - _ = yym222 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr205 || yy2arr205 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq205[5] { - yym224 := z.EncBinary() - _ = yym224 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq205[5] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) + r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym225 := z.EncBinary() - _ = yym225 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } + yy11 := &x.Spec + yy11.CodecEncodeSelf(e) } } - if yyr205 || yy2arr205 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2564,29 +513,29 @@ func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *JobCondition) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *JobTemplateSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym226 := z.DecBinary() - _ = yym226 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct227 := r.ContainerType() - if yyct227 == codecSelferValueTypeMap1234 { - yyl227 := r.ReadMapStart() - if yyl227 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl227, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct227 == codecSelferValueTypeArray1234 { - yyl227 := r.ReadArrayStart() - if yyl227 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl227, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2594,16 +543,16 @@ func (x *JobCondition) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *JobTemplateSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys228Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys228Slc - var yyhl228 bool = l >= 0 - for yyj228 := 0; ; yyj228++ { - if yyhl228 { - if yyj228 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2612,212 +561,96 @@ func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys228Slc = r.DecodeBytes(yys228Slc, true, true) - yys228 := string(yys228Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys228 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = JobConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) - } - case "lastProbeTime": - if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} - } else { - yyv231 := &x.LastProbeTime - yym232 := z.DecBinary() - _ = yym232 - if false { - } else if z.HasExtensions() && z.DecExt(yyv231) { - } else if yym232 { - z.DecBinaryUnmarshal(yyv231) - } else if !yym232 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv231) - } else { - z.DecFallback(yyv231, false) - } - } - case "lastTransitionTime": + switch yys3 { + case "metadata": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv233 := &x.LastTransitionTime - yym234 := z.DecBinary() - _ = yym234 + yyv4 := &x.ObjectMeta + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv233) { - } else if yym234 { - z.DecBinaryUnmarshal(yyv233) - } else if !yym234 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv233) + } else if z.HasExtensions() && z.DecExt(yyv4) { } else { - z.DecFallback(yyv233, false) + z.DecFallback(yyv4, false) } } - case "reason": - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - case "message": + case "spec": if r.TryDecodeAsNil() { - x.Message = "" + x.Spec = pkg3_v1.JobSpec{} } else { - x.Message = string(r.DecodeString()) + yyv6 := &x.Spec + yyv6.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys228) - } // end switch yys228 - } // end for yyj228 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *JobTemplateSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj237 int - var yyb237 bool - var yyhl237 bool = l >= 0 - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = JobConditionType(r.DecodeString()) - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyv240 := &x.LastProbeTime - yym241 := z.DecBinary() - _ = yym241 - if false { - } else if z.HasExtensions() && z.DecExt(yyv240) { - } else if yym241 { - z.DecBinaryUnmarshal(yyv240) - } else if !yym241 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv240) - } else { - z.DecFallback(yyv240, false) - } - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb237 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv242 := &x.LastTransitionTime - yym243 := z.DecBinary() - _ = yym243 + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv242) { - } else if yym243 { - z.DecBinaryUnmarshal(yyv242) - } else if !yym243 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv242) + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv242, false) + z.DecFallback(yyv8, false) } } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l - } else { - yyb237 = r.CheckBreak() - } - if yyb237 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb237 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb237 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Message = "" + x.Spec = pkg3_v1.JobSpec{} } else { - x.Message = string(r.DecodeString()) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } for { - yyj237++ - if yyhl237 { - yyb237 = yyj237 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb237 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb237 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj237-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2829,39 +662,39 @@ func (x *CronJob) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym246 := z.EncBinary() - _ = yym246 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep247 := !z.EncBinary() - yy2arr247 := z.EncBasicHandle().StructToArray - var yyq247 [5]bool - _, _, _ = yysep247, yyq247, yy2arr247 - const yyr247 bool = false - yyq247[0] = x.Kind != "" - yyq247[1] = x.APIVersion != "" - yyq247[2] = true - yyq247[3] = true - yyq247[4] = true - var yynn247 int - if yyr247 || yy2arr247 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn247 = 0 - for _, b := range yyq247 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn247++ + yynn2++ } } - r.EncodeMapStart(yynn247) - yynn247 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr247 || yy2arr247 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[0] { - yym249 := z.EncBinary() - _ = yym249 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -2870,23 +703,23 @@ func (x *CronJob) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq247[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym250 := z.EncBinary() - _ = yym250 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr247 || yy2arr247 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[1] { - yym252 := z.EncBinary() - _ = yym252 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -2895,70 +728,82 @@ func (x *CronJob) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq247[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym253 := z.EncBinary() - _ = yym253 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr247 || yy2arr247 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[2] { - yy255 := &x.ObjectMeta - yy255.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq247[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy256 := &x.ObjectMeta - yy256.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr247 || yy2arr247 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[3] { - yy258 := &x.Spec - yy258.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq247[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy259 := &x.Spec - yy259.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr247 || yy2arr247 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq247[4] { - yy261 := &x.Status - yy261.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq247[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy262 := &x.Status - yy262.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr247 || yy2arr247 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2971,25 +816,25 @@ func (x *CronJob) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym263 := z.DecBinary() - _ = yym263 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct264 := r.ContainerType() - if yyct264 == codecSelferValueTypeMap1234 { - yyl264 := r.ReadMapStart() - if yyl264 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl264, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct264 == codecSelferValueTypeArray1234 { - yyl264 := r.ReadArrayStart() - if yyl264 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl264, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3001,12 +846,12 @@ func (x *CronJob) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys265Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys265Slc - var yyhl265 bool = l >= 0 - for yyj265 := 0; ; yyj265++ { - if yyhl265 { - if yyj265 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3015,47 +860,65 @@ func (x *CronJob) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys265Slc = r.DecodeBytes(yys265Slc, true, true) - yys265 := string(yys265Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys265 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv268 := &x.ObjectMeta - yyv268.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = CronJobSpec{} } else { - yyv269 := &x.Spec - yyv269.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = CronJobStatus{} } else { - yyv270 := &x.Status - yyv270.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys265) - } // end switch yys265 - } // end for yyj265 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3063,16 +926,16 @@ func (x *CronJob) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj271 int - var yyb271 bool - var yyhl271 bool = l >= 0 - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb271 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb271 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3080,15 +943,21 @@ func (x *CronJob) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb271 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb271 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3096,32 +965,44 @@ func (x *CronJob) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb271 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb271 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv274 := &x.ObjectMeta - yyv274.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb271 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb271 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3129,16 +1010,16 @@ func (x *CronJob) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = CronJobSpec{} } else { - yyv275 := &x.Spec - yyv275.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb271 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb271 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3146,21 +1027,21 @@ func (x *CronJob) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = CronJobStatus{} } else { - yyv276 := &x.Status - yyv276.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj271++ - if yyhl271 { - yyb271 = yyj271 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb271 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb271 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj271-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3172,37 +1053,37 @@ func (x *CronJobList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym277 := z.EncBinary() - _ = yym277 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep278 := !z.EncBinary() - yy2arr278 := z.EncBasicHandle().StructToArray - var yyq278 [4]bool - _, _, _ = yysep278, yyq278, yy2arr278 - const yyr278 bool = false - yyq278[0] = x.Kind != "" - yyq278[1] = x.APIVersion != "" - yyq278[2] = true - var yynn278 int - if yyr278 || yy2arr278 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn278 = 1 - for _, b := range yyq278 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn278++ + yynn2++ } } - r.EncodeMapStart(yynn278) - yynn278 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr278 || yy2arr278 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq278[0] { - yym280 := z.EncBinary() - _ = yym280 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -3211,23 +1092,23 @@ func (x *CronJobList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq278[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym281 := z.EncBinary() - _ = yym281 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr278 || yy2arr278 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq278[1] { - yym283 := z.EncBinary() - _ = yym283 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -3236,54 +1117,54 @@ func (x *CronJobList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq278[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym284 := z.EncBinary() - _ = yym284 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr278 || yy2arr278 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq278[2] { - yy286 := &x.ListMeta - yym287 := z.EncBinary() - _ = yym287 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy286) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy286) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq278[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy288 := &x.ListMeta - yym289 := z.EncBinary() - _ = yym289 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy288) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy288) + z.EncFallback(yy12) } } } - if yyr278 || yy2arr278 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym291 := z.EncBinary() - _ = yym291 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceCronJob(([]CronJob)(x.Items), e) @@ -3296,15 +1177,15 @@ func (x *CronJobList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym292 := z.EncBinary() - _ = yym292 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceCronJob(([]CronJob)(x.Items), e) } } } - if yyr278 || yy2arr278 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -3317,25 +1198,25 @@ func (x *CronJobList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym293 := z.DecBinary() - _ = yym293 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct294 := r.ContainerType() - if yyct294 == codecSelferValueTypeMap1234 { - yyl294 := r.ReadMapStart() - if yyl294 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl294, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct294 == codecSelferValueTypeArray1234 { - yyl294 := r.ReadArrayStart() - if yyl294 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl294, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3347,12 +1228,12 @@ func (x *CronJobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys295Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys295Slc - var yyhl295 bool = l >= 0 - for yyj295 := 0; ; yyj295++ { - if yyhl295 { - if yyj295 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3361,51 +1242,63 @@ func (x *CronJobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys295Slc = r.DecodeBytes(yys295Slc, true, true) - yys295 := string(yys295Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys295 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv298 := &x.ListMeta - yym299 := z.DecBinary() - _ = yym299 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv298) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv298, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv300 := &x.Items - yym301 := z.DecBinary() - _ = yym301 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceCronJob((*[]CronJob)(yyv300), d) + h.decSliceCronJob((*[]CronJob)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys295) - } // end switch yys295 - } // end for yyj295 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3413,16 +1306,16 @@ func (x *CronJobList) 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 + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb302 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb302 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3430,15 +1323,21 @@ func (x *CronJobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb302 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb302 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3446,38 +1345,44 @@ func (x *CronJobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb302 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb302 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv305 := &x.ListMeta - yym306 := z.DecBinary() - _ = yym306 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv305) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv305, false) + z.DecFallback(yyv17, false) } } - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb302 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb302 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3485,26 +1390,26 @@ func (x *CronJobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv307 := &x.Items - yym308 := z.DecBinary() - _ = yym308 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceCronJob((*[]CronJob)(yyv307), d) + h.decSliceCronJob((*[]CronJob)(yyv19), d) } } for { - yyj302++ - if yyhl302 { - yyb302 = yyj302 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb302 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb302 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj302-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3516,36 +1421,38 @@ func (x *CronJobSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym309 := z.EncBinary() - _ = yym309 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep310 := !z.EncBinary() - yy2arr310 := z.EncBasicHandle().StructToArray - var yyq310 [5]bool - _, _, _ = yysep310, yyq310, yy2arr310 - const yyr310 bool = false - yyq310[1] = x.StartingDeadlineSeconds != nil - yyq310[2] = x.ConcurrencyPolicy != "" - yyq310[3] = x.Suspend != nil - var yynn310 int - if yyr310 || yy2arr310 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [7]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.StartingDeadlineSeconds != nil + yyq2[2] = x.ConcurrencyPolicy != "" + yyq2[3] = x.Suspend != nil + yyq2[5] = x.SuccessfulJobsHistoryLimit != nil + yyq2[6] = x.FailedJobsHistoryLimit != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(7) } else { - yynn310 = 2 - for _, b := range yyq310 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn310++ + yynn2++ } } - r.EncodeMapStart(yynn310) - yynn310 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr310 || yy2arr310 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym312 := z.EncBinary() - _ = yym312 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Schedule)) @@ -3554,110 +1461,180 @@ func (x *CronJobSpec) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("schedule")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym313 := z.EncBinary() - _ = yym313 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Schedule)) } } - if yyr310 || yy2arr310 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq310[1] { + if yyq2[1] { if x.StartingDeadlineSeconds == nil { r.EncodeNil() } else { - yy315 := *x.StartingDeadlineSeconds - yym316 := z.EncBinary() - _ = yym316 + yy7 := *x.StartingDeadlineSeconds + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeInt(int64(yy315)) + r.EncodeInt(int64(yy7)) } } } else { r.EncodeNil() } } else { - if yyq310[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("startingDeadlineSeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.StartingDeadlineSeconds == nil { r.EncodeNil() } else { - yy317 := *x.StartingDeadlineSeconds - yym318 := z.EncBinary() - _ = yym318 + yy9 := *x.StartingDeadlineSeconds + yym10 := z.EncBinary() + _ = yym10 if false { } else { - r.EncodeInt(int64(yy317)) + r.EncodeInt(int64(yy9)) } } } } - if yyr310 || yy2arr310 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq310[2] { + if yyq2[2] { x.ConcurrencyPolicy.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq310[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("concurrencyPolicy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.ConcurrencyPolicy.CodecEncodeSelf(e) } } - if yyr310 || yy2arr310 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq310[3] { + if yyq2[3] { if x.Suspend == nil { r.EncodeNil() } else { - yy321 := *x.Suspend - yym322 := z.EncBinary() - _ = yym322 + yy15 := *x.Suspend + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeBool(bool(yy321)) + r.EncodeBool(bool(yy15)) } } } else { r.EncodeNil() } } else { - if yyq310[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("suspend")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Suspend == nil { r.EncodeNil() } else { - yy323 := *x.Suspend - yym324 := z.EncBinary() - _ = yym324 + yy17 := *x.Suspend + yym18 := z.EncBinary() + _ = yym18 if false { } else { - r.EncodeBool(bool(yy323)) + r.EncodeBool(bool(yy17)) } } } } - if yyr310 || yy2arr310 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy326 := &x.JobTemplate - yy326.CodecEncodeSelf(e) + yy20 := &x.JobTemplate + yy20.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("jobTemplate")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy327 := &x.JobTemplate - yy327.CodecEncodeSelf(e) + yy22 := &x.JobTemplate + yy22.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + if x.SuccessfulJobsHistoryLimit == nil { + r.EncodeNil() + } else { + yy25 := *x.SuccessfulJobsHistoryLimit + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(yy25)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("successfulJobsHistoryLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.SuccessfulJobsHistoryLimit == nil { + r.EncodeNil() + } else { + yy27 := *x.SuccessfulJobsHistoryLimit + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeInt(int64(yy27)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + if x.FailedJobsHistoryLimit == nil { + r.EncodeNil() + } else { + yy30 := *x.FailedJobsHistoryLimit + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeInt(int64(yy30)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("failedJobsHistoryLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.FailedJobsHistoryLimit == nil { + r.EncodeNil() + } else { + yy32 := *x.FailedJobsHistoryLimit + yym33 := z.EncBinary() + _ = yym33 + if false { + } else { + r.EncodeInt(int64(yy32)) + } + } + } } - if yyr310 || yy2arr310 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -3670,25 +1647,25 @@ func (x *CronJobSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym328 := z.DecBinary() - _ = yym328 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct329 := r.ContainerType() - if yyct329 == codecSelferValueTypeMap1234 { - yyl329 := r.ReadMapStart() - if yyl329 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl329, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct329 == codecSelferValueTypeArray1234 { - yyl329 := r.ReadArrayStart() - if yyl329 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl329, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3700,12 +1677,12 @@ func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys330Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys330Slc - var yyhl330 bool = l >= 0 - for yyj330 := 0; ; yyj330++ { - if yyhl330 { - if yyj330 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3714,15 +1691,21 @@ func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys330Slc = r.DecodeBytes(yys330Slc, true, true) - yys330 := string(yys330Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys330 { + switch yys3 { case "schedule": if r.TryDecodeAsNil() { x.Schedule = "" } else { - x.Schedule = string(r.DecodeString()) + yyv4 := &x.Schedule + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "startingDeadlineSeconds": if r.TryDecodeAsNil() { @@ -3733,8 +1716,8 @@ func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.StartingDeadlineSeconds == nil { x.StartingDeadlineSeconds = new(int64) } - yym333 := z.DecBinary() - _ = yym333 + yym7 := z.DecBinary() + _ = yym7 if false { } else { *((*int64)(x.StartingDeadlineSeconds)) = int64(r.DecodeInt(64)) @@ -3744,7 +1727,8 @@ func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ConcurrencyPolicy = "" } else { - x.ConcurrencyPolicy = ConcurrencyPolicy(r.DecodeString()) + yyv8 := &x.ConcurrencyPolicy + yyv8.CodecDecodeSelf(d) } case "suspend": if r.TryDecodeAsNil() { @@ -3755,8 +1739,8 @@ func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Suspend == nil { x.Suspend = new(bool) } - yym336 := z.DecBinary() - _ = yym336 + yym10 := z.DecBinary() + _ = yym10 if false { } else { *((*bool)(x.Suspend)) = r.DecodeBool() @@ -3766,13 +1750,45 @@ func (x *CronJobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.JobTemplate = JobTemplateSpec{} } else { - yyv337 := &x.JobTemplate - yyv337.CodecDecodeSelf(d) + yyv11 := &x.JobTemplate + yyv11.CodecDecodeSelf(d) + } + case "successfulJobsHistoryLimit": + if r.TryDecodeAsNil() { + if x.SuccessfulJobsHistoryLimit != nil { + x.SuccessfulJobsHistoryLimit = nil + } + } else { + if x.SuccessfulJobsHistoryLimit == nil { + x.SuccessfulJobsHistoryLimit = new(int32) + } + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(x.SuccessfulJobsHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + case "failedJobsHistoryLimit": + if r.TryDecodeAsNil() { + if x.FailedJobsHistoryLimit != nil { + x.FailedJobsHistoryLimit = nil + } + } else { + if x.FailedJobsHistoryLimit == nil { + x.FailedJobsHistoryLimit = new(int32) + } + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(x.FailedJobsHistoryLimit)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys330) - } // end switch yys330 - } // end for yyj330 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3780,16 +1796,16 @@ func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj338 int - var yyb338 bool - var yyhl338 bool = l >= 0 - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb338 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb338 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3797,15 +1813,21 @@ func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Schedule = "" } else { - x.Schedule = string(r.DecodeString()) + yyv17 := &x.Schedule + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb338 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb338 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3818,20 +1840,20 @@ func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.StartingDeadlineSeconds == nil { x.StartingDeadlineSeconds = new(int64) } - yym341 := z.DecBinary() - _ = yym341 + yym20 := z.DecBinary() + _ = yym20 if false { } else { *((*int64)(x.StartingDeadlineSeconds)) = int64(r.DecodeInt(64)) } } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb338 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb338 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3839,15 +1861,16 @@ func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ConcurrencyPolicy = "" } else { - x.ConcurrencyPolicy = ConcurrencyPolicy(r.DecodeString()) + yyv21 := &x.ConcurrencyPolicy + yyv21.CodecDecodeSelf(d) } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb338 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb338 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3860,20 +1883,20 @@ func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Suspend == nil { x.Suspend = new(bool) } - yym344 := z.DecBinary() - _ = yym344 + yym23 := z.DecBinary() + _ = yym23 if false { } else { *((*bool)(x.Suspend)) = r.DecodeBool() } } - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb338 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb338 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3881,21 +1904,73 @@ func (x *CronJobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.JobTemplate = JobTemplateSpec{} } else { - yyv345 := &x.JobTemplate - yyv345.CodecDecodeSelf(d) + yyv24 := &x.JobTemplate + yyv24.CodecDecodeSelf(d) + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.SuccessfulJobsHistoryLimit != nil { + x.SuccessfulJobsHistoryLimit = nil + } + } else { + if x.SuccessfulJobsHistoryLimit == nil { + x.SuccessfulJobsHistoryLimit = new(int32) + } + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(x.SuccessfulJobsHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.FailedJobsHistoryLimit != nil { + x.FailedJobsHistoryLimit = nil + } + } else { + if x.FailedJobsHistoryLimit == nil { + x.FailedJobsHistoryLimit = new(int32) + } + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(x.FailedJobsHistoryLimit)) = int32(r.DecodeInt(32)) + } } for { - yyj338++ - if yyhl338 { - yyb338 = yyj338 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb338 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb338 { + if yyb16 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj338-1, "") + z.DecStructFieldNotFound(yyj16-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3904,8 +1979,8 @@ func (x ConcurrencyPolicy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym346 := z.EncBinary() - _ = yym346 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -3917,8 +1992,8 @@ func (x *ConcurrencyPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym347 := z.DecBinary() - _ = yym347 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -3933,77 +2008,77 @@ func (x *CronJobStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym348 := z.EncBinary() - _ = yym348 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep349 := !z.EncBinary() - yy2arr349 := z.EncBasicHandle().StructToArray - var yyq349 [2]bool - _, _, _ = yysep349, yyq349, yy2arr349 - const yyr349 bool = false - yyq349[0] = len(x.Active) != 0 - yyq349[1] = x.LastScheduleTime != nil - var yynn349 int - if yyr349 || yy2arr349 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Active) != 0 + yyq2[1] = x.LastScheduleTime != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn349 = 0 - for _, b := range yyq349 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn349++ + yynn2++ } } - r.EncodeMapStart(yynn349) - yynn349 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr349 || yy2arr349 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq349[0] { + if yyq2[0] { if x.Active == nil { r.EncodeNil() } else { - yym351 := z.EncBinary() - _ = yym351 + yym4 := z.EncBinary() + _ = yym4 if false { } else { - h.encSlicev1_ObjectReference(([]pkg2_v1.ObjectReference)(x.Active), e) + h.encSlicev1_ObjectReference(([]pkg4_v1.ObjectReference)(x.Active), e) } } } else { r.EncodeNil() } } else { - if yyq349[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("active")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Active == nil { r.EncodeNil() } else { - yym352 := z.EncBinary() - _ = yym352 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - h.encSlicev1_ObjectReference(([]pkg2_v1.ObjectReference)(x.Active), e) + h.encSlicev1_ObjectReference(([]pkg4_v1.ObjectReference)(x.Active), e) } } } } - if yyr349 || yy2arr349 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq349[1] { + if yyq2[1] { if x.LastScheduleTime == nil { r.EncodeNil() } else { - yym354 := z.EncBinary() - _ = yym354 + yym7 := z.EncBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.EncExt(x.LastScheduleTime) { - } else if yym354 { + } else if yym7 { z.EncBinaryMarshal(x.LastScheduleTime) - } else if !yym354 && z.IsJSONHandle() { + } else if !yym7 && z.IsJSONHandle() { z.EncJSONMarshal(x.LastScheduleTime) } else { z.EncFallback(x.LastScheduleTime) @@ -4013,20 +2088,20 @@ func (x *CronJobStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq349[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastScheduleTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.LastScheduleTime == nil { r.EncodeNil() } else { - yym355 := z.EncBinary() - _ = yym355 + yym8 := z.EncBinary() + _ = yym8 if false { } else if z.HasExtensions() && z.EncExt(x.LastScheduleTime) { - } else if yym355 { + } else if yym8 { z.EncBinaryMarshal(x.LastScheduleTime) - } else if !yym355 && z.IsJSONHandle() { + } else if !yym8 && z.IsJSONHandle() { z.EncJSONMarshal(x.LastScheduleTime) } else { z.EncFallback(x.LastScheduleTime) @@ -4034,7 +2109,7 @@ func (x *CronJobStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr349 || yy2arr349 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -4047,25 +2122,25 @@ func (x *CronJobStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym356 := z.DecBinary() - _ = yym356 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct357 := r.ContainerType() - if yyct357 == codecSelferValueTypeMap1234 { - yyl357 := r.ReadMapStart() - if yyl357 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl357, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct357 == codecSelferValueTypeArray1234 { - yyl357 := r.ReadArrayStart() - if yyl357 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl357, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -4077,12 +2152,12 @@ func (x *CronJobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys358Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys358Slc - var yyhl358 bool = l >= 0 - for yyj358 := 0; ; yyj358++ { - if yyhl358 { - if yyj358 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -4091,20 +2166,20 @@ func (x *CronJobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys358Slc = r.DecodeBytes(yys358Slc, true, true) - yys358 := string(yys358Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys358 { + switch yys3 { case "active": if r.TryDecodeAsNil() { x.Active = nil } else { - yyv359 := &x.Active - yym360 := z.DecBinary() - _ = yym360 + yyv4 := &x.Active + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSlicev1_ObjectReference((*[]pkg2_v1.ObjectReference)(yyv359), d) + h.decSlicev1_ObjectReference((*[]pkg4_v1.ObjectReference)(yyv4), d) } } case "lastScheduleTime": @@ -4114,24 +2189,24 @@ func (x *CronJobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.LastScheduleTime == nil { - x.LastScheduleTime = new(pkg1_unversioned.Time) + x.LastScheduleTime = new(pkg1_v1.Time) } - yym362 := z.DecBinary() - _ = yym362 + yym7 := z.DecBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.DecExt(x.LastScheduleTime) { - } else if yym362 { + } else if yym7 { z.DecBinaryUnmarshal(x.LastScheduleTime) - } else if !yym362 && z.IsJSONHandle() { + } else if !yym7 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.LastScheduleTime) } else { z.DecFallback(x.LastScheduleTime, false) } } default: - z.DecStructFieldNotFound(-1, yys358) - } // end switch yys358 - } // end for yyj358 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -4139,16 +2214,16 @@ func (x *CronJobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj363 int - var yyb363 bool - var yyhl363 bool = l >= 0 - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb363 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb363 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4156,21 +2231,21 @@ func (x *CronJobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Active = nil } else { - yyv364 := &x.Active - yym365 := z.DecBinary() - _ = yym365 + yyv9 := &x.Active + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSlicev1_ObjectReference((*[]pkg2_v1.ObjectReference)(yyv364), d) + h.decSlicev1_ObjectReference((*[]pkg4_v1.ObjectReference)(yyv9), d) } } - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb363 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb363 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4181,277 +2256,45 @@ func (x *CronJobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.LastScheduleTime == nil { - x.LastScheduleTime = new(pkg1_unversioned.Time) + x.LastScheduleTime = new(pkg1_v1.Time) } - yym367 := z.DecBinary() - _ = yym367 + yym12 := z.DecBinary() + _ = yym12 if false { } else if z.HasExtensions() && z.DecExt(x.LastScheduleTime) { - } else if yym367 { + } else if yym12 { z.DecBinaryUnmarshal(x.LastScheduleTime) - } else if !yym367 && z.IsJSONHandle() { + } else if !yym12 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.LastScheduleTime) } else { z.DecFallback(x.LastScheduleTime, false) } } for { - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb363 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb363 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj363-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) encSliceJob(v []Job, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv368 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy369 := &yyv368 - yy369.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceJob(v *[]Job, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv370 := *v - yyh370, yyl370 := z.DecSliceHelperStart() - var yyc370 bool - if yyl370 == 0 { - if yyv370 == nil { - yyv370 = []Job{} - yyc370 = true - } else if len(yyv370) != 0 { - yyv370 = yyv370[:0] - yyc370 = true - } - } else if yyl370 > 0 { - var yyrr370, yyrl370 int - var yyrt370 bool - if yyl370 > cap(yyv370) { - - yyrg370 := len(yyv370) > 0 - yyv2370 := yyv370 - yyrl370, yyrt370 = z.DecInferLen(yyl370, z.DecBasicHandle().MaxInitLen, 824) - if yyrt370 { - if yyrl370 <= cap(yyv370) { - yyv370 = yyv370[:yyrl370] - } else { - yyv370 = make([]Job, yyrl370) - } - } else { - yyv370 = make([]Job, yyrl370) - } - yyc370 = true - yyrr370 = len(yyv370) - if yyrg370 { - copy(yyv370, yyv2370) - } - } else if yyl370 != len(yyv370) { - yyv370 = yyv370[:yyl370] - yyc370 = true - } - yyj370 := 0 - for ; yyj370 < yyrr370; yyj370++ { - yyh370.ElemContainerState(yyj370) - if r.TryDecodeAsNil() { - yyv370[yyj370] = Job{} - } else { - yyv371 := &yyv370[yyj370] - yyv371.CodecDecodeSelf(d) - } - - } - if yyrt370 { - for ; yyj370 < yyl370; yyj370++ { - yyv370 = append(yyv370, Job{}) - yyh370.ElemContainerState(yyj370) - if r.TryDecodeAsNil() { - yyv370[yyj370] = Job{} - } else { - yyv372 := &yyv370[yyj370] - yyv372.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj370 := 0 - for ; !r.CheckBreak(); yyj370++ { - - if yyj370 >= len(yyv370) { - yyv370 = append(yyv370, Job{}) // var yyz370 Job - yyc370 = true - } - yyh370.ElemContainerState(yyj370) - if yyj370 < len(yyv370) { - if r.TryDecodeAsNil() { - yyv370[yyj370] = Job{} - } else { - yyv373 := &yyv370[yyj370] - yyv373.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj370 < len(yyv370) { - yyv370 = yyv370[:yyj370] - yyc370 = true - } else if yyj370 == 0 && yyv370 == nil { - yyv370 = []Job{} - yyc370 = true - } - } - yyh370.End() - if yyc370 { - *v = yyv370 - } -} - -func (x codecSelfer1234) encSliceJobCondition(v []JobCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv374 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy375 := &yyv374 - yy375.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceJobCondition(v *[]JobCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv376 := *v - yyh376, yyl376 := z.DecSliceHelperStart() - var yyc376 bool - if yyl376 == 0 { - if yyv376 == nil { - yyv376 = []JobCondition{} - yyc376 = true - } else if len(yyv376) != 0 { - yyv376 = yyv376[:0] - yyc376 = true - } - } else if yyl376 > 0 { - var yyrr376, yyrl376 int - var yyrt376 bool - if yyl376 > cap(yyv376) { - - yyrg376 := len(yyv376) > 0 - yyv2376 := yyv376 - yyrl376, yyrt376 = z.DecInferLen(yyl376, z.DecBasicHandle().MaxInitLen, 112) - if yyrt376 { - if yyrl376 <= cap(yyv376) { - yyv376 = yyv376[:yyrl376] - } else { - yyv376 = make([]JobCondition, yyrl376) - } - } else { - yyv376 = make([]JobCondition, yyrl376) - } - yyc376 = true - yyrr376 = len(yyv376) - if yyrg376 { - copy(yyv376, yyv2376) - } - } else if yyl376 != len(yyv376) { - yyv376 = yyv376[:yyl376] - yyc376 = true - } - yyj376 := 0 - for ; yyj376 < yyrr376; yyj376++ { - yyh376.ElemContainerState(yyj376) - if r.TryDecodeAsNil() { - yyv376[yyj376] = JobCondition{} - } else { - yyv377 := &yyv376[yyj376] - yyv377.CodecDecodeSelf(d) - } - - } - if yyrt376 { - for ; yyj376 < yyl376; yyj376++ { - yyv376 = append(yyv376, JobCondition{}) - yyh376.ElemContainerState(yyj376) - if r.TryDecodeAsNil() { - yyv376[yyj376] = JobCondition{} - } else { - yyv378 := &yyv376[yyj376] - yyv378.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj376 := 0 - for ; !r.CheckBreak(); yyj376++ { - - if yyj376 >= len(yyv376) { - yyv376 = append(yyv376, JobCondition{}) // var yyz376 JobCondition - yyc376 = true - } - yyh376.ElemContainerState(yyj376) - if yyj376 < len(yyv376) { - if r.TryDecodeAsNil() { - yyv376[yyj376] = JobCondition{} - } else { - yyv379 := &yyv376[yyj376] - yyv379.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj376 < len(yyv376) { - yyv376 = yyv376[:yyj376] - yyc376 = true - } else if yyj376 == 0 && yyv376 == nil { - yyv376 = []JobCondition{} - yyc376 = true - } - } - yyh376.End() - if yyc376 { - *v = yyv376 - } -} - func (x codecSelfer1234) encSliceCronJob(v []CronJob, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv380 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy381 := &yyv380 - yy381.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4461,83 +2304,86 @@ func (x codecSelfer1234) decSliceCronJob(v *[]CronJob, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv382 := *v - yyh382, yyl382 := z.DecSliceHelperStart() - var yyc382 bool - if yyl382 == 0 { - if yyv382 == nil { - yyv382 = []CronJob{} - yyc382 = true - } else if len(yyv382) != 0 { - yyv382 = yyv382[:0] - yyc382 = true - } - } else if yyl382 > 0 { - var yyrr382, yyrl382 int - var yyrt382 bool - if yyl382 > cap(yyv382) { - - yyrg382 := len(yyv382) > 0 - yyv2382 := yyv382 - yyrl382, yyrt382 = z.DecInferLen(yyl382, z.DecBasicHandle().MaxInitLen, 1072) - if yyrt382 { - if yyrl382 <= cap(yyv382) { - yyv382 = yyv382[:yyrl382] - } else { - yyv382 = make([]CronJob, yyrl382) - } - } else { - yyv382 = make([]CronJob, yyrl382) - } - yyc382 = true - yyrr382 = len(yyv382) - if yyrg382 { - copy(yyv382, yyv2382) - } - } else if yyl382 != len(yyv382) { - yyv382 = yyv382[:yyl382] - yyc382 = true - } - yyj382 := 0 - for ; yyj382 < yyrr382; yyj382++ { - yyh382.ElemContainerState(yyj382) + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []CronJob{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 1192) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]CronJob, yyrl1) + } + } else { + yyv1 = make([]CronJob, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv382[yyj382] = CronJob{} + yyv1[yyj1] = CronJob{} } else { - yyv383 := &yyv382[yyj382] - yyv383.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt382 { - for ; yyj382 < yyl382; yyj382++ { - yyv382 = append(yyv382, CronJob{}) - yyh382.ElemContainerState(yyj382) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, CronJob{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv382[yyj382] = CronJob{} + yyv1[yyj1] = CronJob{} } else { - yyv384 := &yyv382[yyj382] - yyv384.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj382 := 0 - for ; !r.CheckBreak(); yyj382++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj382 >= len(yyv382) { - yyv382 = append(yyv382, CronJob{}) // var yyz382 CronJob - yyc382 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, CronJob{}) // var yyz1 CronJob + yyc1 = true } - yyh382.ElemContainerState(yyj382) - if yyj382 < len(yyv382) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv382[yyj382] = CronJob{} + yyv1[yyj1] = CronJob{} } else { - yyv385 := &yyv382[yyj382] - yyv385.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4545,115 +2391,118 @@ func (x codecSelfer1234) decSliceCronJob(v *[]CronJob, d *codec1978.Decoder) { } } - if yyj382 < len(yyv382) { - yyv382 = yyv382[:yyj382] - yyc382 = true - } else if yyj382 == 0 && yyv382 == nil { - yyv382 = []CronJob{} - yyc382 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []CronJob{} + yyc1 = true } } - yyh382.End() - if yyc382 { - *v = yyv382 + yyh1.End() + if yyc1 { + *v = yyv1 } } -func (x codecSelfer1234) encSlicev1_ObjectReference(v []pkg2_v1.ObjectReference, e *codec1978.Encoder) { +func (x codecSelfer1234) encSlicev1_ObjectReference(v []pkg4_v1.ObjectReference, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv386 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy387 := &yyv386 - yy387.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) decSlicev1_ObjectReference(v *[]pkg2_v1.ObjectReference, d *codec1978.Decoder) { +func (x codecSelfer1234) decSlicev1_ObjectReference(v *[]pkg4_v1.ObjectReference, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv388 := *v - yyh388, yyl388 := z.DecSliceHelperStart() - var yyc388 bool - if yyl388 == 0 { - if yyv388 == nil { - yyv388 = []pkg2_v1.ObjectReference{} - yyc388 = true - } else if len(yyv388) != 0 { - yyv388 = yyv388[:0] - yyc388 = true - } - } else if yyl388 > 0 { - var yyrr388, yyrl388 int - var yyrt388 bool - if yyl388 > cap(yyv388) { - - yyrg388 := len(yyv388) > 0 - yyv2388 := yyv388 - yyrl388, yyrt388 = z.DecInferLen(yyl388, z.DecBasicHandle().MaxInitLen, 112) - if yyrt388 { - if yyrl388 <= cap(yyv388) { - yyv388 = yyv388[:yyrl388] - } else { - yyv388 = make([]pkg2_v1.ObjectReference, yyrl388) - } - } else { - yyv388 = make([]pkg2_v1.ObjectReference, yyrl388) - } - yyc388 = true - yyrr388 = len(yyv388) - if yyrg388 { - copy(yyv388, yyv2388) - } - } else if yyl388 != len(yyv388) { - yyv388 = yyv388[:yyl388] - yyc388 = true - } - yyj388 := 0 - for ; yyj388 < yyrr388; yyj388++ { - yyh388.ElemContainerState(yyj388) + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []pkg4_v1.ObjectReference{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]pkg4_v1.ObjectReference, yyrl1) + } + } else { + yyv1 = make([]pkg4_v1.ObjectReference, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv388[yyj388] = pkg2_v1.ObjectReference{} + yyv1[yyj1] = pkg4_v1.ObjectReference{} } else { - yyv389 := &yyv388[yyj388] - yyv389.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt388 { - for ; yyj388 < yyl388; yyj388++ { - yyv388 = append(yyv388, pkg2_v1.ObjectReference{}) - yyh388.ElemContainerState(yyj388) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, pkg4_v1.ObjectReference{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv388[yyj388] = pkg2_v1.ObjectReference{} + yyv1[yyj1] = pkg4_v1.ObjectReference{} } else { - yyv390 := &yyv388[yyj388] - yyv390.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj388 := 0 - for ; !r.CheckBreak(); yyj388++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj388 >= len(yyv388) { - yyv388 = append(yyv388, pkg2_v1.ObjectReference{}) // var yyz388 pkg2_v1.ObjectReference - yyc388 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, pkg4_v1.ObjectReference{}) // var yyz1 pkg4_v1.ObjectReference + yyc1 = true } - yyh388.ElemContainerState(yyj388) - if yyj388 < len(yyv388) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv388[yyj388] = pkg2_v1.ObjectReference{} + yyv1[yyj1] = pkg4_v1.ObjectReference{} } else { - yyv391 := &yyv388[yyj388] - yyv391.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4661,16 +2510,16 @@ func (x codecSelfer1234) decSlicev1_ObjectReference(v *[]pkg2_v1.ObjectReference } } - if yyj388 < len(yyv388) { - yyv388 = yyv388[:yyj388] - yyc388 = true - } else if yyj388 == 0 && yyv388 == nil { - yyv388 = []pkg2_v1.ObjectReference{} - yyc388 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []pkg4_v1.ObjectReference{} + yyc1 = true } } - yyh388.End() - if yyc388 { - *v = yyv388 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.go index a610272e35..d5b3c487fd 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types.go @@ -17,53 +17,21 @@ limitations under the License. package v2alpha1 import ( - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" "k8s.io/client-go/pkg/api/v1" + batchv1 "k8s.io/client-go/pkg/apis/batch/v1" ) -// +genclient=true - -// Job represents the configuration of a single job. -type Job struct { - unversioned.TypeMeta `json:",inline"` - // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - Spec JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - Status JobStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` -} - -// JobList is a collection of jobs. -type JobList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Items is the list of Job. - Items []Job `json:"items" protobuf:"bytes,2,rep,name=items"` -} - // JobTemplate describes a template for creating copies of a predefined pod. type JobTemplate struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Template defines jobs that will be created from this template - // http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Defines jobs that will be created from this template. + // https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Template JobTemplateSpec `json:"template,omitempty" protobuf:"bytes,2,opt,name=template"` } @@ -71,166 +39,54 @@ type JobTemplate struct { // JobTemplateSpec describes the data a Job should have when created from a template type JobTemplateSpec struct { // Standard object's metadata of the jobs created from this template. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Specification of the desired behavior of the job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - Spec JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` -} - -// JobSpec describes how the job execution will look like. -type JobSpec struct { - - // Parallelism specifies the maximum desired number of pods the job should - // run at any given time. The actual number of pods running in steady state will - // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), - // i.e. when the work left to do is less than max parallelism. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - Parallelism *int32 `json:"parallelism,omitempty" protobuf:"varint,1,opt,name=parallelism"` - - // Completions specifies the desired number of successfully finished pods the - // job should be run with. Setting to nil means that the success of any - // pod signals the success of all pods, and allows parallelism to have any positive - // value. Setting to 1 means that parallelism is limited to 1 and the success of that - // pod signals the success of the job. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - Completions *int32 `json:"completions,omitempty" protobuf:"varint,2,opt,name=completions"` - - // Optional duration in seconds relative to the startTime that the job may be active - // before the system tries to terminate it; value must be positive integer - // +optional - ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,3,opt,name=activeDeadlineSeconds"` - - // Selector is a label query over pods that should match the pod count. - // Normally, the system sets this field for you. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors - // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"` - - // ManualSelector controls generation of pod labels and pod selectors. - // Leave `manualSelector` unset unless you are certain what you are doing. - // When false or unset, the system pick labels unique to this job - // and appends those labels to the pod template. When true, - // the user is responsible for picking unique labels and specifying - // the selector. Failure to pick a unique label may cause this - // and other jobs to not function correctly. However, You may see - // `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` - // API. - // More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md - // +optional - ManualSelector *bool `json:"manualSelector,omitempty" protobuf:"varint,5,opt,name=manualSelector"` - - // Template is the object that describes the pod that will be created when - // executing a job. - // More info: http://kubernetes.io/docs/user-guide/jobs - Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,6,opt,name=template"` -} - -// JobStatus represents the current state of a Job. -type JobStatus struct { - - // Conditions represent the latest available observations of an object's current state. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"` - - // StartTime represents time when the job was acknowledged by the Job Manager. - // It is not guaranteed to be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"` - - // CompletionTime represents time when the job was completed. It is not guaranteed to - // be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - CompletionTime *unversioned.Time `json:"completionTime,omitempty" protobuf:"bytes,3,opt,name=completionTime"` - - // Active is the number of actively running pods. - // +optional - Active int32 `json:"active,omitempty" protobuf:"varint,4,opt,name=active"` - - // Succeeded is the number of pods which reached Phase Succeeded. - // +optional - Succeeded int32 `json:"succeeded,omitempty" protobuf:"varint,5,opt,name=succeeded"` - - // Failed is the number of pods which reached Phase Failed. - // +optional - Failed int32 `json:"failed,omitempty" protobuf:"varint,6,opt,name=failed"` -} - -type JobConditionType string - -// These are valid conditions of a job. -const ( - // JobComplete means the job has completed its execution. - JobComplete JobConditionType = "Complete" - // JobFailed means the job has failed its execution. - JobFailed JobConditionType = "Failed" -) - -// JobCondition describes current state of a job. -type JobCondition struct { - // Type of job condition, Complete or Failed. - Type JobConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=JobConditionType"` - // Status of the condition, one of True, False, Unknown. - Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"` - // Last time the condition was checked. - // +optional - LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"` - // Last time the condition transit from one status to another. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` - // (brief) reason for the condition's last transition. - // +optional - Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"` - // Human readable message indicating details about last transition. - // +optional - Message string `json:"message,omitempty" protobuf:"bytes,6,opt,name=message"` + Spec batchv1.JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` } // +genclient=true // CronJob represents the configuration of a single cron job. type CronJob struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Spec is a structure defining the expected behavior of a job, including the schedule. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Specification of the desired behavior of a cron job, including the schedule. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec CronJobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // Current status of a cron job. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status CronJobStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // CronJobList is a collection of cron jobs. type CronJobList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + metav1.TypeMeta `json:",inline"` + + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Items is the list of CronJob. + // items is the list of CronJobs. Items []CronJob `json:"items" protobuf:"bytes,2,rep,name=items"` } // CronJobSpec describes how the job execution will look like and when it will actually run. type CronJobSpec struct { - // Schedule contains the schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. + // The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron. Schedule string `json:"schedule" protobuf:"bytes,1,opt,name=schedule"` // Optional deadline in seconds for starting the job if it misses scheduled @@ -238,18 +94,28 @@ type CronJobSpec struct { // +optional StartingDeadlineSeconds *int64 `json:"startingDeadlineSeconds,omitempty" protobuf:"varint,2,opt,name=startingDeadlineSeconds"` - // ConcurrencyPolicy specifies how to treat concurrent executions of a Job. + // Specifies how to treat concurrent executions of a Job. + // Defaults to Allow. // +optional ConcurrencyPolicy ConcurrencyPolicy `json:"concurrencyPolicy,omitempty" protobuf:"bytes,3,opt,name=concurrencyPolicy,casttype=ConcurrencyPolicy"` - // Suspend flag tells the controller to suspend subsequent executions, it does + // This flag tells the controller to suspend subsequent executions, it does // not apply to already started executions. Defaults to false. // +optional Suspend *bool `json:"suspend,omitempty" protobuf:"varint,4,opt,name=suspend"` - // JobTemplate is the object that describes the job that will be created when - // executing a CronJob. + // Specifies the job that will be created when executing a CronJob. JobTemplate JobTemplateSpec `json:"jobTemplate" protobuf:"bytes,5,opt,name=jobTemplate"` + + // The number of successful finished jobs to retain. + // This is a pointer to distinguish between explicit zero and not specified. + // +optional + SuccessfulJobsHistoryLimit *int32 `json:"successfulJobsHistoryLimit,omitempty" protobuf:"varint,6,opt,name=successfulJobsHistoryLimit"` + + // The number of failed finished jobs to retain. + // This is a pointer to distinguish between explicit zero and not specified. + // +optional + FailedJobsHistoryLimit *int32 `json:"failedJobsHistoryLimit,omitempty" protobuf:"varint,7,opt,name=failedJobsHistoryLimit"` } // ConcurrencyPolicy describes how the job will be handled. @@ -272,11 +138,11 @@ const ( // CronJobStatus represents the current state of a cron job. type CronJobStatus struct { - // Active holds pointers to currently running jobs. + // A list of pointers to currently running jobs. // +optional Active []v1.ObjectReference `json:"active,omitempty" protobuf:"bytes,1,rep,name=active"` - // LastScheduleTime keeps information of when was the last time the job was successfully scheduled. + // Information when was the last time the job was successfully scheduled. // +optional - LastScheduleTime *unversioned.Time `json:"lastScheduleTime,omitempty" protobuf:"bytes,4,opt,name=lastScheduleTime"` + LastScheduleTime *metav1.Time `json:"lastScheduleTime,omitempty" protobuf:"bytes,4,opt,name=lastScheduleTime"` } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types_swagger_doc_generated.go index 6e8c40a0fe..2b3ed4c560 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/types_swagger_doc_generated.go @@ -29,9 +29,9 @@ package v2alpha1 // AUTO-GENERATED FUNCTIONS START HERE var map_CronJob = map[string]string{ "": "CronJob represents the configuration of a single cron job.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec is a structure defining the expected behavior of a job, including the schedule. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is a structure describing current status of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior of a cron job, including the schedule. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Current status of a cron job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (CronJob) SwaggerDoc() map[string]string { @@ -40,8 +40,8 @@ func (CronJob) SwaggerDoc() map[string]string { var map_CronJobList = map[string]string{ "": "CronJobList is a collection of cron jobs.", - "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "items": "Items is the list of CronJob.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "items is the list of CronJobs.", } func (CronJobList) SwaggerDoc() map[string]string { @@ -49,12 +49,14 @@ func (CronJobList) SwaggerDoc() map[string]string { } var map_CronJobSpec = map[string]string{ - "": "CronJobSpec describes how the job execution will look like and when it will actually run.", - "schedule": "Schedule contains the schedule in Cron format, see https://en.wikipedia.org/wiki/Cron.", - "startingDeadlineSeconds": "Optional deadline in seconds for starting the job if it misses scheduled time for any reason. Missed jobs executions will be counted as failed ones.", - "concurrencyPolicy": "ConcurrencyPolicy specifies how to treat concurrent executions of a Job.", - "suspend": "Suspend flag tells the controller to suspend subsequent executions, it does not apply to already started executions. Defaults to false.", - "jobTemplate": "JobTemplate is the object that describes the job that will be created when executing a CronJob.", + "": "CronJobSpec describes how the job execution will look like and when it will actually run.", + "schedule": "The schedule in Cron format, see https://en.wikipedia.org/wiki/Cron.", + "startingDeadlineSeconds": "Optional deadline in seconds for starting the job if it misses scheduled time for any reason. Missed jobs executions will be counted as failed ones.", + "concurrencyPolicy": "Specifies how to treat concurrent executions of a Job. Defaults to Allow.", + "suspend": "This flag tells the controller to suspend subsequent executions, it does not apply to already started executions. Defaults to false.", + "jobTemplate": "Specifies the job that will be created when executing a CronJob.", + "successfulJobsHistoryLimit": "The number of successful finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified.", + "failedJobsHistoryLimit": "The number of failed finished jobs to retain. This is a pointer to distinguish between explicit zero and not specified.", } func (CronJobSpec) SwaggerDoc() map[string]string { @@ -63,81 +65,18 @@ func (CronJobSpec) SwaggerDoc() map[string]string { var map_CronJobStatus = map[string]string{ "": "CronJobStatus represents the current state of a cron job.", - "active": "Active holds pointers to currently running jobs.", - "lastScheduleTime": "LastScheduleTime keeps information of when was the last time the job was successfully scheduled.", + "active": "A list of pointers to currently running jobs.", + "lastScheduleTime": "Information when was the last time the job was successfully scheduled.", } func (CronJobStatus) SwaggerDoc() map[string]string { return map_CronJobStatus } -var map_Job = map[string]string{ - "": "Job represents the configuration of a single job.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec is a structure defining the expected behavior of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is a structure describing current status of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", -} - -func (Job) SwaggerDoc() map[string]string { - return map_Job -} - -var map_JobCondition = map[string]string{ - "": "JobCondition describes current state of a job.", - "type": "Type of job condition, Complete or Failed.", - "status": "Status of the condition, one of True, False, Unknown.", - "lastProbeTime": "Last time the condition was checked.", - "lastTransitionTime": "Last time the condition transit from one status to another.", - "reason": "(brief) reason for the condition's last transition.", - "message": "Human readable message indicating details about last transition.", -} - -func (JobCondition) SwaggerDoc() map[string]string { - return map_JobCondition -} - -var map_JobList = map[string]string{ - "": "JobList is a collection of jobs.", - "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "items": "Items is the list of Job.", -} - -func (JobList) SwaggerDoc() map[string]string { - return map_JobList -} - -var map_JobSpec = map[string]string{ - "": "JobSpec describes how the job execution will look like.", - "parallelism": "Parallelism specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: http://kubernetes.io/docs/user-guide/jobs", - "completions": "Completions specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: http://kubernetes.io/docs/user-guide/jobs", - "activeDeadlineSeconds": "Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer", - "selector": "Selector is a label query over pods that should match the pod count. Normally, the system sets this field for you. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "manualSelector": "ManualSelector controls generation of pod labels and pod selectors. Leave `manualSelector` unset unless you are certain what you are doing. When false or unset, the system pick labels unique to this job and appends those labels to the pod template. When true, the user is responsible for picking unique labels and specifying the selector. Failure to pick a unique label may cause this and other jobs to not function correctly. However, You may see `manualSelector=true` in jobs that were created with the old `extensions/v1beta1` API. More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md", - "template": "Template is the object that describes the pod that will be created when executing a job. More info: http://kubernetes.io/docs/user-guide/jobs", -} - -func (JobSpec) SwaggerDoc() map[string]string { - return map_JobSpec -} - -var map_JobStatus = map[string]string{ - "": "JobStatus represents the current state of a Job.", - "conditions": "Conditions represent the latest available observations of an object's current state. More info: http://kubernetes.io/docs/user-guide/jobs", - "startTime": "StartTime represents time when the job was acknowledged by the Job Manager. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", - "completionTime": "CompletionTime represents time when the job was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", - "active": "Active is the number of actively running pods.", - "succeeded": "Succeeded is the number of pods which reached Phase Succeeded.", - "failed": "Failed is the number of pods which reached Phase Failed.", -} - -func (JobStatus) SwaggerDoc() map[string]string { - return map_JobStatus -} - var map_JobTemplate = map[string]string{ "": "JobTemplate describes a template for creating copies of a predefined pod.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "template": "Template defines jobs that will be created from this template http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "template": "Defines jobs that will be created from this template. https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (JobTemplate) SwaggerDoc() map[string]string { @@ -146,8 +85,8 @@ func (JobTemplate) SwaggerDoc() map[string]string { var map_JobTemplateSpec = map[string]string{ "": "JobTemplateSpec describes the data a Job should have when created from a template", - "metadata": "Standard object's metadata of the jobs created from this template. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Specification of the desired behavior of the job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata of the jobs created from this template. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior of the job. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (JobTemplateSpec) SwaggerDoc() map[string]string { diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.conversion.go index 431e0b4675..b422c46582 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,12 +21,13 @@ limitations under the License. package v2alpha1 import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" + api_v1 "k8s.io/client-go/pkg/api/v1" batch "k8s.io/client-go/pkg/apis/batch" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + batch_v1 "k8s.io/client-go/pkg/apis/batch/v1" unsafe "unsafe" ) @@ -46,16 +47,6 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_batch_CronJobSpec_To_v2alpha1_CronJobSpec, Convert_v2alpha1_CronJobStatus_To_batch_CronJobStatus, Convert_batch_CronJobStatus_To_v2alpha1_CronJobStatus, - Convert_v2alpha1_Job_To_batch_Job, - Convert_batch_Job_To_v2alpha1_Job, - Convert_v2alpha1_JobCondition_To_batch_JobCondition, - Convert_batch_JobCondition_To_v2alpha1_JobCondition, - Convert_v2alpha1_JobList_To_batch_JobList, - Convert_batch_JobList_To_v2alpha1_JobList, - Convert_v2alpha1_JobSpec_To_batch_JobSpec, - Convert_batch_JobSpec_To_v2alpha1_JobSpec, - Convert_v2alpha1_JobStatus_To_batch_JobStatus, - Convert_batch_JobStatus_To_v2alpha1_JobStatus, Convert_v2alpha1_JobTemplate_To_batch_JobTemplate, Convert_batch_JobTemplate_To_v2alpha1_JobTemplate, Convert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec, @@ -64,10 +55,7 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v2alpha1_CronJob_To_batch_CronJob(in *CronJob, out *batch.CronJob, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v2alpha1_CronJobSpec_To_batch_CronJobSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -77,15 +65,13 @@ func autoConvert_v2alpha1_CronJob_To_batch_CronJob(in *CronJob, out *batch.CronJ return nil } +// Convert_v2alpha1_CronJob_To_batch_CronJob is an autogenerated conversion function. func Convert_v2alpha1_CronJob_To_batch_CronJob(in *CronJob, out *batch.CronJob, s conversion.Scope) error { return autoConvert_v2alpha1_CronJob_To_batch_CronJob(in, out, s) } func autoConvert_batch_CronJob_To_v2alpha1_CronJob(in *batch.CronJob, out *CronJob, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_batch_CronJobSpec_To_v2alpha1_CronJobSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -95,6 +81,7 @@ func autoConvert_batch_CronJob_To_v2alpha1_CronJob(in *batch.CronJob, out *CronJ return nil } +// Convert_batch_CronJob_To_v2alpha1_CronJob is an autogenerated conversion function. func Convert_batch_CronJob_To_v2alpha1_CronJob(in *batch.CronJob, out *CronJob, s conversion.Scope) error { return autoConvert_batch_CronJob_To_v2alpha1_CronJob(in, out, s) } @@ -115,6 +102,7 @@ func autoConvert_v2alpha1_CronJobList_To_batch_CronJobList(in *CronJobList, out return nil } +// Convert_v2alpha1_CronJobList_To_batch_CronJobList is an autogenerated conversion function. func Convert_v2alpha1_CronJobList_To_batch_CronJobList(in *CronJobList, out *batch.CronJobList, s conversion.Scope) error { return autoConvert_v2alpha1_CronJobList_To_batch_CronJobList(in, out, s) } @@ -130,11 +118,12 @@ func autoConvert_batch_CronJobList_To_v2alpha1_CronJobList(in *batch.CronJobList } } } else { - out.Items = nil + out.Items = make([]CronJob, 0) } return nil } +// Convert_batch_CronJobList_To_v2alpha1_CronJobList is an autogenerated conversion function. func Convert_batch_CronJobList_To_v2alpha1_CronJobList(in *batch.CronJobList, out *CronJobList, s conversion.Scope) error { return autoConvert_batch_CronJobList_To_v2alpha1_CronJobList(in, out, s) } @@ -147,9 +136,12 @@ func autoConvert_v2alpha1_CronJobSpec_To_batch_CronJobSpec(in *CronJobSpec, out if err := Convert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec(&in.JobTemplate, &out.JobTemplate, s); err != nil { return err } + out.SuccessfulJobsHistoryLimit = (*int32)(unsafe.Pointer(in.SuccessfulJobsHistoryLimit)) + out.FailedJobsHistoryLimit = (*int32)(unsafe.Pointer(in.FailedJobsHistoryLimit)) return nil } +// Convert_v2alpha1_CronJobSpec_To_batch_CronJobSpec is an autogenerated conversion function. func Convert_v2alpha1_CronJobSpec_To_batch_CronJobSpec(in *CronJobSpec, out *batch.CronJobSpec, s conversion.Scope) error { return autoConvert_v2alpha1_CronJobSpec_To_batch_CronJobSpec(in, out, s) } @@ -162,245 +154,86 @@ func autoConvert_batch_CronJobSpec_To_v2alpha1_CronJobSpec(in *batch.CronJobSpec if err := Convert_batch_JobTemplateSpec_To_v2alpha1_JobTemplateSpec(&in.JobTemplate, &out.JobTemplate, s); err != nil { return err } + out.SuccessfulJobsHistoryLimit = (*int32)(unsafe.Pointer(in.SuccessfulJobsHistoryLimit)) + out.FailedJobsHistoryLimit = (*int32)(unsafe.Pointer(in.FailedJobsHistoryLimit)) return nil } +// Convert_batch_CronJobSpec_To_v2alpha1_CronJobSpec is an autogenerated conversion function. func Convert_batch_CronJobSpec_To_v2alpha1_CronJobSpec(in *batch.CronJobSpec, out *CronJobSpec, s conversion.Scope) error { return autoConvert_batch_CronJobSpec_To_v2alpha1_CronJobSpec(in, out, s) } func autoConvert_v2alpha1_CronJobStatus_To_batch_CronJobStatus(in *CronJobStatus, out *batch.CronJobStatus, s conversion.Scope) error { out.Active = *(*[]api.ObjectReference)(unsafe.Pointer(&in.Active)) - out.LastScheduleTime = (*unversioned.Time)(unsafe.Pointer(in.LastScheduleTime)) + out.LastScheduleTime = (*v1.Time)(unsafe.Pointer(in.LastScheduleTime)) return nil } +// Convert_v2alpha1_CronJobStatus_To_batch_CronJobStatus is an autogenerated conversion function. func Convert_v2alpha1_CronJobStatus_To_batch_CronJobStatus(in *CronJobStatus, out *batch.CronJobStatus, s conversion.Scope) error { return autoConvert_v2alpha1_CronJobStatus_To_batch_CronJobStatus(in, out, s) } func autoConvert_batch_CronJobStatus_To_v2alpha1_CronJobStatus(in *batch.CronJobStatus, out *CronJobStatus, s conversion.Scope) error { - out.Active = *(*[]v1.ObjectReference)(unsafe.Pointer(&in.Active)) - out.LastScheduleTime = (*unversioned.Time)(unsafe.Pointer(in.LastScheduleTime)) + out.Active = *(*[]api_v1.ObjectReference)(unsafe.Pointer(&in.Active)) + out.LastScheduleTime = (*v1.Time)(unsafe.Pointer(in.LastScheduleTime)) return nil } +// Convert_batch_CronJobStatus_To_v2alpha1_CronJobStatus is an autogenerated conversion function. func Convert_batch_CronJobStatus_To_v2alpha1_CronJobStatus(in *batch.CronJobStatus, out *CronJobStatus, s conversion.Scope) error { return autoConvert_batch_CronJobStatus_To_v2alpha1_CronJobStatus(in, out, s) } -func autoConvert_v2alpha1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_v2alpha1_JobSpec_To_batch_JobSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_v2alpha1_JobStatus_To_batch_JobStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_v2alpha1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope) error { - return autoConvert_v2alpha1_Job_To_batch_Job(in, out, s) -} - -func autoConvert_batch_Job_To_v2alpha1_Job(in *batch.Job, out *Job, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_batch_JobSpec_To_v2alpha1_JobSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_batch_JobStatus_To_v2alpha1_JobStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_batch_Job_To_v2alpha1_Job(in *batch.Job, out *Job, s conversion.Scope) error { - return autoConvert_batch_Job_To_v2alpha1_Job(in, out, s) -} - -func autoConvert_v2alpha1_JobCondition_To_batch_JobCondition(in *JobCondition, out *batch.JobCondition, s conversion.Scope) error { - out.Type = batch.JobConditionType(in.Type) - out.Status = api.ConditionStatus(in.Status) - out.LastProbeTime = in.LastProbeTime - out.LastTransitionTime = in.LastTransitionTime - out.Reason = in.Reason - out.Message = in.Message - return nil -} - -func Convert_v2alpha1_JobCondition_To_batch_JobCondition(in *JobCondition, out *batch.JobCondition, s conversion.Scope) error { - return autoConvert_v2alpha1_JobCondition_To_batch_JobCondition(in, out, s) -} - -func autoConvert_batch_JobCondition_To_v2alpha1_JobCondition(in *batch.JobCondition, out *JobCondition, s conversion.Scope) error { - out.Type = JobConditionType(in.Type) - out.Status = v1.ConditionStatus(in.Status) - out.LastProbeTime = in.LastProbeTime - out.LastTransitionTime = in.LastTransitionTime - out.Reason = in.Reason - out.Message = in.Message - return nil -} - -func Convert_batch_JobCondition_To_v2alpha1_JobCondition(in *batch.JobCondition, out *JobCondition, s conversion.Scope) error { - return autoConvert_batch_JobCondition_To_v2alpha1_JobCondition(in, out, s) -} - -func autoConvert_v2alpha1_JobList_To_batch_JobList(in *JobList, out *batch.JobList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]batch.Job, len(*in)) - for i := range *in { - if err := Convert_v2alpha1_Job_To_batch_Job(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil -} - -func Convert_v2alpha1_JobList_To_batch_JobList(in *JobList, out *batch.JobList, s conversion.Scope) error { - return autoConvert_v2alpha1_JobList_To_batch_JobList(in, out, s) -} - -func autoConvert_batch_JobList_To_v2alpha1_JobList(in *batch.JobList, out *JobList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Job, len(*in)) - for i := range *in { - if err := Convert_batch_Job_To_v2alpha1_Job(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil -} - -func Convert_batch_JobList_To_v2alpha1_JobList(in *batch.JobList, out *JobList, s conversion.Scope) error { - return autoConvert_batch_JobList_To_v2alpha1_JobList(in, out, s) -} - -func autoConvert_v2alpha1_JobSpec_To_batch_JobSpec(in *JobSpec, out *batch.JobSpec, s conversion.Scope) error { - out.Parallelism = (*int32)(unsafe.Pointer(in.Parallelism)) - out.Completions = (*int32)(unsafe.Pointer(in.Completions)) - out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - out.ManualSelector = (*bool)(unsafe.Pointer(in.ManualSelector)) - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { - return err - } - return nil -} - -func autoConvert_batch_JobSpec_To_v2alpha1_JobSpec(in *batch.JobSpec, out *JobSpec, s conversion.Scope) error { - out.Parallelism = (*int32)(unsafe.Pointer(in.Parallelism)) - out.Completions = (*int32)(unsafe.Pointer(in.Completions)) - out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - out.ManualSelector = (*bool)(unsafe.Pointer(in.ManualSelector)) - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { - return err - } - return nil -} - -func autoConvert_v2alpha1_JobStatus_To_batch_JobStatus(in *JobStatus, out *batch.JobStatus, s conversion.Scope) error { - out.Conditions = *(*[]batch.JobCondition)(unsafe.Pointer(&in.Conditions)) - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) - out.CompletionTime = (*unversioned.Time)(unsafe.Pointer(in.CompletionTime)) - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed - return nil -} - -func Convert_v2alpha1_JobStatus_To_batch_JobStatus(in *JobStatus, out *batch.JobStatus, s conversion.Scope) error { - return autoConvert_v2alpha1_JobStatus_To_batch_JobStatus(in, out, s) -} - -func autoConvert_batch_JobStatus_To_v2alpha1_JobStatus(in *batch.JobStatus, out *JobStatus, s conversion.Scope) error { - out.Conditions = *(*[]JobCondition)(unsafe.Pointer(&in.Conditions)) - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) - out.CompletionTime = (*unversioned.Time)(unsafe.Pointer(in.CompletionTime)) - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed - return nil -} - -func Convert_batch_JobStatus_To_v2alpha1_JobStatus(in *batch.JobStatus, out *JobStatus, s conversion.Scope) error { - return autoConvert_batch_JobStatus_To_v2alpha1_JobStatus(in, out, s) -} - func autoConvert_v2alpha1_JobTemplate_To_batch_JobTemplate(in *JobTemplate, out *batch.JobTemplate, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } return nil } +// Convert_v2alpha1_JobTemplate_To_batch_JobTemplate is an autogenerated conversion function. func Convert_v2alpha1_JobTemplate_To_batch_JobTemplate(in *JobTemplate, out *batch.JobTemplate, s conversion.Scope) error { return autoConvert_v2alpha1_JobTemplate_To_batch_JobTemplate(in, out, s) } func autoConvert_batch_JobTemplate_To_v2alpha1_JobTemplate(in *batch.JobTemplate, out *JobTemplate, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_batch_JobTemplateSpec_To_v2alpha1_JobTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } return nil } +// Convert_batch_JobTemplate_To_v2alpha1_JobTemplate is an autogenerated conversion function. func Convert_batch_JobTemplate_To_v2alpha1_JobTemplate(in *batch.JobTemplate, out *JobTemplate, s conversion.Scope) error { return autoConvert_batch_JobTemplate_To_v2alpha1_JobTemplate(in, out, s) } func autoConvert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec(in *JobTemplateSpec, out *batch.JobTemplateSpec, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_v2alpha1_JobSpec_To_batch_JobSpec(&in.Spec, &out.Spec, s); err != nil { + out.ObjectMeta = in.ObjectMeta + if err := batch_v1.Convert_v1_JobSpec_To_batch_JobSpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec is an autogenerated conversion function. func Convert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec(in *JobTemplateSpec, out *batch.JobTemplateSpec, s conversion.Scope) error { return autoConvert_v2alpha1_JobTemplateSpec_To_batch_JobTemplateSpec(in, out, s) } func autoConvert_batch_JobTemplateSpec_To_v2alpha1_JobTemplateSpec(in *batch.JobTemplateSpec, out *JobTemplateSpec, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_batch_JobSpec_To_v2alpha1_JobSpec(&in.Spec, &out.Spec, s); err != nil { + out.ObjectMeta = in.ObjectMeta + if err := batch_v1.Convert_batch_JobSpec_To_v1_JobSpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_batch_JobTemplateSpec_To_v2alpha1_JobTemplateSpec is an autogenerated conversion function. func Convert_batch_JobTemplateSpec_To_v2alpha1_JobTemplateSpec(in *batch.JobTemplateSpec, out *JobTemplateSpec, s conversion.Scope) error { return autoConvert_batch_JobTemplateSpec_To_v2alpha1_JobTemplateSpec(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.deepcopy.go index 572c2cd260..9442a216d8 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,11 @@ limitations under the License. package v2alpha1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + api_v1 "k8s.io/client-go/pkg/api/v1" + batch_v1 "k8s.io/client-go/pkg/apis/batch/v1" reflect "reflect" ) @@ -40,23 +41,21 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_CronJobList, InType: reflect.TypeOf(&CronJobList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_CronJobSpec, InType: reflect.TypeOf(&CronJobSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_CronJobStatus, InType: reflect.TypeOf(&CronJobStatus{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_Job, InType: reflect.TypeOf(&Job{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_JobCondition, InType: reflect.TypeOf(&JobCondition{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_JobList, InType: reflect.TypeOf(&JobList{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_JobSpec, InType: reflect.TypeOf(&JobSpec{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_JobStatus, InType: reflect.TypeOf(&JobStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_JobTemplate, InType: reflect.TypeOf(&JobTemplate{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v2alpha1_JobTemplateSpec, InType: reflect.TypeOf(&JobTemplateSpec{})}, ) } +// DeepCopy_v2alpha1_CronJob is an autogenerated deepcopy function. func DeepCopy_v2alpha1_CronJob(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJob) out := out.(*CronJob) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v2alpha1_CronJobSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -68,12 +67,12 @@ func DeepCopy_v2alpha1_CronJob(in interface{}, out interface{}, c *conversion.Cl } } +// DeepCopy_v2alpha1_CronJobList is an autogenerated deepcopy function. func DeepCopy_v2alpha1_CronJobList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJobList) out := out.(*CronJobList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CronJob, len(*in)) @@ -82,208 +81,74 @@ func DeepCopy_v2alpha1_CronJobList(in interface{}, out interface{}, c *conversio return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v2alpha1_CronJobSpec is an autogenerated deepcopy function. func DeepCopy_v2alpha1_CronJobSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJobSpec) out := out.(*CronJobSpec) - out.Schedule = in.Schedule + *out = *in if in.StartingDeadlineSeconds != nil { in, out := &in.StartingDeadlineSeconds, &out.StartingDeadlineSeconds *out = new(int64) **out = **in - } else { - out.StartingDeadlineSeconds = nil } - out.ConcurrencyPolicy = in.ConcurrencyPolicy if in.Suspend != nil { in, out := &in.Suspend, &out.Suspend *out = new(bool) **out = **in - } else { - out.Suspend = nil } if err := DeepCopy_v2alpha1_JobTemplateSpec(&in.JobTemplate, &out.JobTemplate, c); err != nil { return err } + if in.SuccessfulJobsHistoryLimit != nil { + in, out := &in.SuccessfulJobsHistoryLimit, &out.SuccessfulJobsHistoryLimit + *out = new(int32) + **out = **in + } + if in.FailedJobsHistoryLimit != nil { + in, out := &in.FailedJobsHistoryLimit, &out.FailedJobsHistoryLimit + *out = new(int32) + **out = **in + } return nil } } +// DeepCopy_v2alpha1_CronJobStatus is an autogenerated deepcopy function. func DeepCopy_v2alpha1_CronJobStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJobStatus) out := out.(*CronJobStatus) + *out = *in if in.Active != nil { in, out := &in.Active, &out.Active - *out = make([]v1.ObjectReference, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Active = nil + *out = make([]api_v1.ObjectReference, len(*in)) + copy(*out, *in) } if in.LastScheduleTime != nil { in, out := &in.LastScheduleTime, &out.LastScheduleTime - *out = new(unversioned.Time) - **out = (*in).DeepCopy() - } else { - out.LastScheduleTime = nil - } - return nil - } -} - -func DeepCopy_v2alpha1_Job(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Job) - out := out.(*Job) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { - return err - } - if err := DeepCopy_v2alpha1_JobSpec(&in.Spec, &out.Spec, c); err != nil { - return err - } - if err := DeepCopy_v2alpha1_JobStatus(&in.Status, &out.Status, c); err != nil { - return err - } - return nil - } -} - -func DeepCopy_v2alpha1_JobCondition(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobCondition) - out := out.(*JobCondition) - out.Type = in.Type - out.Status = in.Status - out.LastProbeTime = in.LastProbeTime.DeepCopy() - out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message - return nil - } -} - -func DeepCopy_v2alpha1_JobList(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobList) - out := out.(*JobList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Job, len(*in)) - for i := range *in { - if err := DeepCopy_v2alpha1_Job(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil - } -} - -func DeepCopy_v2alpha1_JobSpec(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobSpec) - out := out.(*JobSpec) - if in.Parallelism != nil { - in, out := &in.Parallelism, &out.Parallelism - *out = new(int32) - **out = **in - } else { - out.Parallelism = nil - } - if in.Completions != nil { - in, out := &in.Completions, &out.Completions - *out = new(int32) - **out = **in - } else { - out.Completions = nil - } - if in.ActiveDeadlineSeconds != nil { - in, out := &in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds - *out = new(int64) - **out = **in - } else { - out.ActiveDeadlineSeconds = nil - } - if in.Selector != nil { - in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { - return err - } - } else { - out.Selector = nil - } - if in.ManualSelector != nil { - in, out := &in.ManualSelector, &out.ManualSelector - *out = new(bool) - **out = **in - } else { - out.ManualSelector = nil - } - if err := v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { - return err - } - return nil - } -} - -func DeepCopy_v2alpha1_JobStatus(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobStatus) - out := out.(*JobStatus) - if in.Conditions != nil { - in, out := &in.Conditions, &out.Conditions - *out = make([]JobCondition, len(*in)) - for i := range *in { - if err := DeepCopy_v2alpha1_JobCondition(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Conditions = nil - } - if in.StartTime != nil { - in, out := &in.StartTime, &out.StartTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.StartTime = nil } - if in.CompletionTime != nil { - in, out := &in.CompletionTime, &out.CompletionTime - *out = new(unversioned.Time) - **out = (*in).DeepCopy() - } else { - out.CompletionTime = nil - } - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed return nil } } +// DeepCopy_v2alpha1_JobTemplate is an autogenerated deepcopy function. func DeepCopy_v2alpha1_JobTemplate(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobTemplate) out := out.(*JobTemplate) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v2alpha1_JobTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -292,14 +157,18 @@ func DeepCopy_v2alpha1_JobTemplate(in interface{}, out interface{}, c *conversio } } +// DeepCopy_v2alpha1_JobTemplateSpec is an autogenerated deepcopy function. func DeepCopy_v2alpha1_JobTemplateSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobTemplateSpec) out := out.(*JobTemplateSpec) - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - if err := DeepCopy_v2alpha1_JobSpec(&in.Spec, &out.Spec, c); err != nil { + if err := batch_v1.DeepCopy_v1_JobSpec(&in.Spec, &out.Spec, c); err != nil { return err } return nil diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.defaults.go index 27f6d93886..1c0bd0ee0a 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/v2alpha1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,8 +21,8 @@ limitations under the License. package v2alpha1 import ( + runtime "k8s.io/apimachinery/pkg/runtime" v1 "k8s.io/client-go/pkg/api/v1" - runtime "k8s.io/client-go/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. @@ -31,8 +31,6 @@ import ( func RegisterDefaults(scheme *runtime.Scheme) error { scheme.AddTypeDefaultingFunc(&CronJob{}, func(obj interface{}) { SetObjectDefaults_CronJob(obj.(*CronJob)) }) scheme.AddTypeDefaultingFunc(&CronJobList{}, func(obj interface{}) { SetObjectDefaults_CronJobList(obj.(*CronJobList)) }) - scheme.AddTypeDefaultingFunc(&Job{}, func(obj interface{}) { SetObjectDefaults_Job(obj.(*Job)) }) - scheme.AddTypeDefaultingFunc(&JobList{}, func(obj interface{}) { SetObjectDefaults_JobList(obj.(*JobList)) }) scheme.AddTypeDefaultingFunc(&JobTemplate{}, func(obj interface{}) { SetObjectDefaults_JobTemplate(obj.(*JobTemplate)) }) return nil } @@ -67,6 +65,23 @@ func SetObjectDefaults_CronJob(in *CronJob) { if a.VolumeSource.AzureDisk != nil { v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.JobTemplate.Spec.Template.Spec.InitContainers { a := &in.Spec.JobTemplate.Spec.Template.Spec.InitContainers[i] @@ -161,130 +176,6 @@ func SetObjectDefaults_CronJobList(in *CronJobList) { } } -func SetObjectDefaults_Job(in *Job) { - SetDefaults_Job(in) - v1.SetDefaults_PodSpec(&in.Spec.Template.Spec) - for i := range in.Spec.Template.Spec.Volumes { - a := &in.Spec.Template.Spec.Volumes[i] - v1.SetDefaults_Volume(a) - if a.VolumeSource.Secret != nil { - v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret) - } - if a.VolumeSource.ISCSI != nil { - v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI) - } - if a.VolumeSource.RBD != nil { - v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD) - } - if a.VolumeSource.DownwardAPI != nil { - v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI) - for j := range a.VolumeSource.DownwardAPI.Items { - b := &a.VolumeSource.DownwardAPI.Items[j] - if b.FieldRef != nil { - v1.SetDefaults_ObjectFieldSelector(b.FieldRef) - } - } - } - if a.VolumeSource.ConfigMap != nil { - v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap) - } - if a.VolumeSource.AzureDisk != nil { - v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) - } - } - for i := range in.Spec.Template.Spec.InitContainers { - a := &in.Spec.Template.Spec.InitContainers[i] - v1.SetDefaults_Container(a) - for j := range a.Ports { - b := &a.Ports[j] - v1.SetDefaults_ContainerPort(b) - } - for j := range a.Env { - b := &a.Env[j] - if b.ValueFrom != nil { - if b.ValueFrom.FieldRef != nil { - v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef) - } - } - } - v1.SetDefaults_ResourceList(&a.Resources.Limits) - v1.SetDefaults_ResourceList(&a.Resources.Requests) - if a.LivenessProbe != nil { - v1.SetDefaults_Probe(a.LivenessProbe) - if a.LivenessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.LivenessProbe.Handler.HTTPGet) - } - } - if a.ReadinessProbe != nil { - v1.SetDefaults_Probe(a.ReadinessProbe) - if a.ReadinessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.Handler.HTTPGet) - } - } - if a.Lifecycle != nil { - if a.Lifecycle.PostStart != nil { - if a.Lifecycle.PostStart.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet) - } - } - if a.Lifecycle.PreStop != nil { - if a.Lifecycle.PreStop.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet) - } - } - } - } - for i := range in.Spec.Template.Spec.Containers { - a := &in.Spec.Template.Spec.Containers[i] - v1.SetDefaults_Container(a) - for j := range a.Ports { - b := &a.Ports[j] - v1.SetDefaults_ContainerPort(b) - } - for j := range a.Env { - b := &a.Env[j] - if b.ValueFrom != nil { - if b.ValueFrom.FieldRef != nil { - v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef) - } - } - } - v1.SetDefaults_ResourceList(&a.Resources.Limits) - v1.SetDefaults_ResourceList(&a.Resources.Requests) - if a.LivenessProbe != nil { - v1.SetDefaults_Probe(a.LivenessProbe) - if a.LivenessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.LivenessProbe.Handler.HTTPGet) - } - } - if a.ReadinessProbe != nil { - v1.SetDefaults_Probe(a.ReadinessProbe) - if a.ReadinessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.Handler.HTTPGet) - } - } - if a.Lifecycle != nil { - if a.Lifecycle.PostStart != nil { - if a.Lifecycle.PostStart.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet) - } - } - if a.Lifecycle.PreStop != nil { - if a.Lifecycle.PreStop.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet) - } - } - } - } -} - -func SetObjectDefaults_JobList(in *JobList) { - for i := range in.Items { - a := &in.Items[i] - SetObjectDefaults_Job(a) - } -} - func SetObjectDefaults_JobTemplate(in *JobTemplate) { v1.SetDefaults_PodSpec(&in.Template.Spec.Template.Spec) for i := range in.Template.Spec.Template.Spec.Volumes { @@ -314,6 +205,23 @@ func SetObjectDefaults_JobTemplate(in *JobTemplate) { if a.VolumeSource.AzureDisk != nil { v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Template.Spec.Template.Spec.InitContainers { a := &in.Template.Spec.Template.Spec.InitContainers[i] diff --git a/vendor/k8s.io/client-go/pkg/apis/batch/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/batch/zz_generated.deepcopy.go index 73c89eb565..4f07dbce16 100644 --- a/vendor/k8s.io/client-go/pkg/apis/batch/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/batch/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package batch import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" reflect "reflect" ) @@ -50,13 +50,16 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_batch_CronJob is an autogenerated deepcopy function. func DeepCopy_batch_CronJob(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJob) out := out.(*CronJob) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_batch_CronJobSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -68,12 +71,12 @@ func DeepCopy_batch_CronJob(in interface{}, out interface{}, c *conversion.Clone } } +// DeepCopy_batch_CronJobList is an autogenerated deepcopy function. func DeepCopy_batch_CronJobList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJobList) out := out.(*CronJobList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CronJob, len(*in)) @@ -82,71 +85,74 @@ func DeepCopy_batch_CronJobList(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_batch_CronJobSpec is an autogenerated deepcopy function. func DeepCopy_batch_CronJobSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJobSpec) out := out.(*CronJobSpec) - out.Schedule = in.Schedule + *out = *in if in.StartingDeadlineSeconds != nil { in, out := &in.StartingDeadlineSeconds, &out.StartingDeadlineSeconds *out = new(int64) **out = **in - } else { - out.StartingDeadlineSeconds = nil } - out.ConcurrencyPolicy = in.ConcurrencyPolicy if in.Suspend != nil { in, out := &in.Suspend, &out.Suspend *out = new(bool) **out = **in - } else { - out.Suspend = nil } if err := DeepCopy_batch_JobTemplateSpec(&in.JobTemplate, &out.JobTemplate, c); err != nil { return err } + if in.SuccessfulJobsHistoryLimit != nil { + in, out := &in.SuccessfulJobsHistoryLimit, &out.SuccessfulJobsHistoryLimit + *out = new(int32) + **out = **in + } + if in.FailedJobsHistoryLimit != nil { + in, out := &in.FailedJobsHistoryLimit, &out.FailedJobsHistoryLimit + *out = new(int32) + **out = **in + } return nil } } +// DeepCopy_batch_CronJobStatus is an autogenerated deepcopy function. func DeepCopy_batch_CronJobStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CronJobStatus) out := out.(*CronJobStatus) + *out = *in if in.Active != nil { in, out := &in.Active, &out.Active *out = make([]api.ObjectReference, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Active = nil + copy(*out, *in) } if in.LastScheduleTime != nil { in, out := &in.LastScheduleTime, &out.LastScheduleTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.LastScheduleTime = nil } return nil } } +// DeepCopy_batch_Job is an autogenerated deepcopy function. func DeepCopy_batch_Job(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Job) out := out.(*Job) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_batch_JobSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -158,26 +164,24 @@ func DeepCopy_batch_Job(in interface{}, out interface{}, c *conversion.Cloner) e } } +// DeepCopy_batch_JobCondition is an autogenerated deepcopy function. func DeepCopy_batch_JobCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobCondition) out := out.(*JobCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastProbeTime = in.LastProbeTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_batch_JobList is an autogenerated deepcopy function. func DeepCopy_batch_JobList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobList) out := out.(*JobList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Job, len(*in)) @@ -186,53 +190,44 @@ func DeepCopy_batch_JobList(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_batch_JobSpec is an autogenerated deepcopy function. func DeepCopy_batch_JobSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobSpec) out := out.(*JobSpec) + *out = *in if in.Parallelism != nil { in, out := &in.Parallelism, &out.Parallelism *out = new(int32) **out = **in - } else { - out.Parallelism = nil } if in.Completions != nil { in, out := &in.Completions, &out.Completions *out = new(int32) **out = **in - } else { - out.Completions = nil } if in.ActiveDeadlineSeconds != nil { in, out := &in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds *out = new(int64) **out = **in - } else { - out.ActiveDeadlineSeconds = nil } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } if in.ManualSelector != nil { in, out := &in.ManualSelector, &out.ManualSelector *out = new(bool) **out = **in - } else { - out.ManualSelector = nil } if err := api.DeepCopy_api_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -241,10 +236,12 @@ func DeepCopy_batch_JobSpec(in interface{}, out interface{}, c *conversion.Clone } } +// DeepCopy_batch_JobStatus is an autogenerated deepcopy function. func DeepCopy_batch_JobStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobStatus) out := out.(*JobStatus) + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]JobCondition, len(*in)) @@ -253,37 +250,31 @@ func DeepCopy_batch_JobStatus(in interface{}, out interface{}, c *conversion.Clo return err } } - } else { - out.Conditions = nil } if in.StartTime != nil { in, out := &in.StartTime, &out.StartTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.StartTime = nil } if in.CompletionTime != nil { in, out := &in.CompletionTime, &out.CompletionTime - *out = new(unversioned.Time) + *out = new(v1.Time) **out = (*in).DeepCopy() - } else { - out.CompletionTime = nil } - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed return nil } } +// DeepCopy_batch_JobTemplate is an autogenerated deepcopy function. func DeepCopy_batch_JobTemplate(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobTemplate) out := out.(*JobTemplate) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_batch_JobTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -292,12 +283,16 @@ func DeepCopy_batch_JobTemplate(in interface{}, out interface{}, c *conversion.C } } +// DeepCopy_batch_JobTemplateSpec is an autogenerated deepcopy function. func DeepCopy_batch_JobTemplateSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*JobTemplateSpec) out := out.(*JobTemplateSpec) - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_batch_JobSpec(&in.Spec, &out.Spec, c); err != nil { return err diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/BUILD b/vendor/k8s.io/client-go/pkg/apis/certificates/BUILD new file mode 100644 index 0000000000..0e128d1a31 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "helpers.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/OWNERS b/vendor/k8s.io/client-go/pkg/apis/certificates/OWNERS new file mode 100755 index 0000000000..c67bd1172a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/OWNERS @@ -0,0 +1,14 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- deads2k +- caesarxuchao +- liggitt +- sttts +- timothysc +- dims +- errordeveloper +- mbohlool +- david-mcmahon +- jianhuiz diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/doc.go b/vendor/k8s.io/client-go/pkg/apis/certificates/doc.go index 3a1b77095a..a101774691 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/doc.go @@ -14,8 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - // +groupName=certificates.k8s.io package certificates diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/helpers.go b/vendor/k8s.io/client-go/pkg/apis/certificates/helpers.go new file mode 100644 index 0000000000..2608e40762 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/helpers.go @@ -0,0 +1,38 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package certificates + +import ( + "crypto/x509" + "encoding/pem" + "errors" +) + +// ParseCSR extracts the CSR from the API object and decodes it. +func ParseCSR(obj *CertificateSigningRequest) (*x509.CertificateRequest, error) { + // extract PEM from request object + pemBytes := obj.Spec.Request + block, _ := pem.Decode(pemBytes) + if block == nil || block.Type != "CERTIFICATE REQUEST" { + return nil, errors.New("PEM block type must be CERTIFICATE REQUEST") + } + csr, err := x509.ParseCertificateRequest(block.Bytes) + if err != nil { + return nil, err + } + return csr, nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/install/install.go b/vendor/k8s.io/client-go/pkg/apis/certificates/install/install.go deleted file mode 100644 index 6abe6656a6..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the certificates API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/certificates" - "k8s.io/client-go/pkg/apis/certificates/v1alpha1" - "k8s.io/client-go/pkg/util/sets" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: certificates.GroupName, - VersionPreferenceOrder: []string{v1alpha1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/certificates", - RootScopedKinds: sets.NewString("CertificateSigningRequest"), - AddInternalObjectsToScheme: certificates.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1alpha1.SchemeGroupVersion.Version: v1alpha1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/register.go b/vendor/k8s.io/client-go/pkg/apis/certificates/register.go index e3f45969e5..085737583f 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/register.go @@ -17,9 +17,8 @@ limitations under the License. package certificates import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) var ( @@ -31,15 +30,15 @@ var ( const GroupName = "certificates.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -48,11 +47,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &CertificateSigningRequest{}, &CertificateSigningRequestList{}, - &api.ListOptions{}, - &api.DeleteOptions{}, ) return nil } - -func (obj *CertificateSigningRequest) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } -func (obj *CertificateSigningRequestList) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/certificates/types.generated.go deleted file mode 100644 index 5c17d300f3..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/types.generated.go +++ /dev/null @@ -1,1957 +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 certificates - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - "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 pkg2_api.ObjectMeta - var v1 pkg1_unversioned.TypeMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 - } -} - -func (x *CertificateSigningRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = true - yyq2[3] = true - yyq2[4] = true - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl19, d) - } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl19, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = CertificateSigningRequestSpec{} - } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = CertificateSigningRequestStatus{} - } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = CertificateSigningRequestSpec{} - } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = CertificateSigningRequestStatus{} - } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CertificateSigningRequestSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [4]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[1] = x.Username != "" - yyq33[2] = x.UID != "" - yyq33[3] = len(x.Groups) != 0 - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(4) - } else { - yynn33 = 1 - for _, b := range yyq33 { - if b { - yynn33++ - } - } - r.EncodeMapStart(yynn33) - yynn33 = 0 - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Request == nil { - r.EncodeNil() - } else { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Request)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("request")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Request == nil { - r.EncodeNil() - } else { - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Request)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Username)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("username")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Username)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[2] { - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym42 := z.EncBinary() - _ = yym42 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[3] { - if x.Groups == nil { - r.EncodeNil() - } else { - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq33[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("groups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Groups == nil { - r.EncodeNil() - } else { - yym45 := z.EncBinary() - _ = yym45 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym46 := z.DecBinary() - _ = yym46 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct47 := r.ContainerType() - if yyct47 == codecSelferValueTypeMap1234 { - yyl47 := r.ReadMapStart() - if yyl47 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl47, d) - } - } else if yyct47 == codecSelferValueTypeArray1234 { - yyl47 := r.ReadArrayStart() - if yyl47 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl47, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys48Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys48Slc - var yyhl48 bool = l >= 0 - for yyj48 := 0; ; yyj48++ { - if yyhl48 { - if yyj48 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys48Slc = r.DecodeBytes(yys48Slc, true, true) - yys48 := string(yys48Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys48 { - case "request": - if r.TryDecodeAsNil() { - x.Request = nil - } else { - yyv49 := &x.Request - yym50 := z.DecBinary() - _ = yym50 - if false { - } else { - *yyv49 = r.DecodeBytes(*(*[]byte)(yyv49), false, false) - } - } - case "username": - if r.TryDecodeAsNil() { - x.Username = "" - } else { - x.Username = string(r.DecodeString()) - } - case "uid": - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = string(r.DecodeString()) - } - case "groups": - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv53 := &x.Groups - yym54 := z.DecBinary() - _ = yym54 - if false { - } else { - z.F.DecSliceStringX(yyv53, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys48) - } // end switch yys48 - } // end for yyj48 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj55 int - var yyb55 bool - var yyhl55 bool = l >= 0 - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Request = nil - } else { - yyv56 := &x.Request - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - *yyv56 = r.DecodeBytes(*(*[]byte)(yyv56), false, false) - } - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Username = "" - } else { - x.Username = string(r.DecodeString()) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = string(r.DecodeString()) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv60 := &x.Groups - yym61 := z.DecBinary() - _ = yym61 - if false { - } else { - z.F.DecSliceStringX(yyv60, false, d) - } - } - for { - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj55-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CertificateSigningRequestStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym62 := z.EncBinary() - _ = yym62 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep63 := !z.EncBinary() - yy2arr63 := z.EncBasicHandle().StructToArray - var yyq63 [2]bool - _, _, _ = yysep63, yyq63, yy2arr63 - const yyr63 bool = false - yyq63[0] = len(x.Conditions) != 0 - yyq63[1] = len(x.Certificate) != 0 - var yynn63 int - if yyr63 || yy2arr63 { - r.EncodeArrayStart(2) - } else { - yynn63 = 0 - for _, b := range yyq63 { - if b { - yynn63++ - } - } - r.EncodeMapStart(yynn63) - yynn63 = 0 - } - if yyr63 || yy2arr63 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq63[0] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - h.encSliceCertificateSigningRequestCondition(([]CertificateSigningRequestCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq63[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym66 := z.EncBinary() - _ = yym66 - if false { - } else { - h.encSliceCertificateSigningRequestCondition(([]CertificateSigningRequestCondition)(x.Conditions), e) - } - } - } - } - if yyr63 || yy2arr63 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq63[1] { - if x.Certificate == nil { - r.EncodeNil() - } else { - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Certificate)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq63[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("certificate")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Certificate == nil { - r.EncodeNil() - } else { - yym69 := z.EncBinary() - _ = yym69 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Certificate)) - } - } - } - } - if yyr63 || yy2arr63 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym70 := z.DecBinary() - _ = yym70 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct71 := r.ContainerType() - if yyct71 == codecSelferValueTypeMap1234 { - yyl71 := r.ReadMapStart() - if yyl71 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl71, d) - } - } else if yyct71 == codecSelferValueTypeArray1234 { - yyl71 := r.ReadArrayStart() - if yyl71 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl71, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys72Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys72Slc - var yyhl72 bool = l >= 0 - for yyj72 := 0; ; yyj72++ { - if yyhl72 { - if yyj72 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys72Slc = r.DecodeBytes(yys72Slc, true, true) - yys72 := string(yys72Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys72 { - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv73 := &x.Conditions - yym74 := z.DecBinary() - _ = yym74 - if false { - } else { - h.decSliceCertificateSigningRequestCondition((*[]CertificateSigningRequestCondition)(yyv73), d) - } - } - case "certificate": - if r.TryDecodeAsNil() { - x.Certificate = nil - } else { - yyv75 := &x.Certificate - yym76 := z.DecBinary() - _ = yym76 - if false { - } else { - *yyv75 = r.DecodeBytes(*(*[]byte)(yyv75), false, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys72) - } // end switch yys72 - } // end for yyj72 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestStatus) 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.Conditions = nil - } else { - yyv78 := &x.Conditions - yym79 := z.DecBinary() - _ = yym79 - if false { - } else { - h.decSliceCertificateSigningRequestCondition((*[]CertificateSigningRequestCondition)(yyv78), 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.Certificate = nil - } else { - yyv80 := &x.Certificate - yym81 := z.DecBinary() - _ = yym81 - if false { - } else { - *yyv80 = r.DecodeBytes(*(*[]byte)(yyv80), false, false) - } - } - 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 RequestConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym82 := z.EncBinary() - _ = yym82 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *RequestConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym83 := z.DecBinary() - _ = yym83 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *CertificateSigningRequestCondition) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym84 := z.EncBinary() - _ = yym84 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep85 := !z.EncBinary() - yy2arr85 := z.EncBasicHandle().StructToArray - var yyq85 [4]bool - _, _, _ = yysep85, yyq85, yy2arr85 - const yyr85 bool = false - yyq85[1] = x.Reason != "" - yyq85[2] = x.Message != "" - yyq85[3] = true - var yynn85 int - if yyr85 || yy2arr85 { - r.EncodeArrayStart(4) - } else { - yynn85 = 1 - for _, b := range yyq85 { - if b { - yynn85++ - } - } - r.EncodeMapStart(yynn85) - yynn85 = 0 - } - if yyr85 || yy2arr85 { - 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 yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq85[1] { - yym88 := z.EncBinary() - _ = yym88 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq85[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym89 := z.EncBinary() - _ = yym89 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq85[2] { - yym91 := z.EncBinary() - _ = yym91 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq85[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym92 := z.EncBinary() - _ = yym92 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq85[3] { - yy94 := &x.LastUpdateTime - yym95 := z.EncBinary() - _ = yym95 - if false { - } else if z.HasExtensions() && z.EncExt(yy94) { - } else if yym95 { - z.EncBinaryMarshal(yy94) - } else if !yym95 && z.IsJSONHandle() { - z.EncJSONMarshal(yy94) - } else { - z.EncFallback(yy94) - } - } else { - r.EncodeNil() - } - } else { - if yyq85[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy96 := &x.LastUpdateTime - yym97 := z.EncBinary() - _ = yym97 - if false { - } else if z.HasExtensions() && z.EncExt(yy96) { - } else if yym97 { - z.EncBinaryMarshal(yy96) - } else if !yym97 && z.IsJSONHandle() { - z.EncJSONMarshal(yy96) - } else { - z.EncFallback(yy96) - } - } - } - if yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym98 := z.DecBinary() - _ = yym98 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct99 := r.ContainerType() - if yyct99 == codecSelferValueTypeMap1234 { - yyl99 := r.ReadMapStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl99, d) - } - } else if yyct99 == codecSelferValueTypeArray1234 { - yyl99 := r.ReadArrayStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl99, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys100Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys100Slc - var yyhl100 bool = l >= 0 - for yyj100 := 0; ; yyj100++ { - if yyhl100 { - if yyj100 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys100Slc = r.DecodeBytes(yys100Slc, true, true) - yys100 := string(yys100Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys100 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = RequestConditionType(r.DecodeString()) - } - 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 "lastUpdateTime": - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv104 := &x.LastUpdateTime - yym105 := z.DecBinary() - _ = yym105 - if false { - } else if z.HasExtensions() && z.DecExt(yyv104) { - } else if yym105 { - z.DecBinaryUnmarshal(yyv104) - } else if !yym105 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv104) - } else { - z.DecFallback(yyv104, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys100) - } // end switch yys100 - } // end for yyj100 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj106 int - var yyb106 bool - var yyhl106 bool = l >= 0 - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = RequestConditionType(r.DecodeString()) - } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv110 := &x.LastUpdateTime - yym111 := z.DecBinary() - _ = yym111 - if false { - } else if z.HasExtensions() && z.DecExt(yyv110) { - } else if yym111 { - z.DecBinaryUnmarshal(yyv110) - } else if !yym111 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv110) - } else { - z.DecFallback(yyv110, false) - } - } - for { - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj106-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CertificateSigningRequestList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym112 := z.EncBinary() - _ = yym112 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep113 := !z.EncBinary() - yy2arr113 := z.EncBasicHandle().StructToArray - var yyq113 [4]bool - _, _, _ = yysep113, yyq113, yy2arr113 - const yyr113 bool = false - yyq113[0] = x.Kind != "" - yyq113[1] = x.APIVersion != "" - yyq113[2] = true - yyq113[3] = len(x.Items) != 0 - var yynn113 int - if yyr113 || yy2arr113 { - r.EncodeArrayStart(4) - } else { - yynn113 = 0 - for _, b := range yyq113 { - if b { - yynn113++ - } - } - r.EncodeMapStart(yynn113) - yynn113 = 0 - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[0] { - yym115 := z.EncBinary() - _ = yym115 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq113[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym116 := z.EncBinary() - _ = yym116 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[1] { - yym118 := z.EncBinary() - _ = yym118 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq113[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym119 := z.EncBinary() - _ = yym119 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[2] { - yy121 := &x.ListMeta - yym122 := z.EncBinary() - _ = yym122 - if false { - } else if z.HasExtensions() && z.EncExt(yy121) { - } else { - z.EncFallback(yy121) - } - } else { - r.EncodeNil() - } - } else { - if yyq113[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy123 := &x.ListMeta - yym124 := z.EncBinary() - _ = yym124 - if false { - } else if z.HasExtensions() && z.EncExt(yy123) { - } else { - z.EncFallback(yy123) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[3] { - if x.Items == nil { - r.EncodeNil() - } else { - yym126 := z.EncBinary() - _ = yym126 - if false { - } else { - h.encSliceCertificateSigningRequest(([]CertificateSigningRequest)(x.Items), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq113[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym127 := z.EncBinary() - _ = yym127 - if false { - } else { - h.encSliceCertificateSigningRequest(([]CertificateSigningRequest)(x.Items), e) - } - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym128 := z.DecBinary() - _ = yym128 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct129 := r.ContainerType() - if yyct129 == codecSelferValueTypeMap1234 { - yyl129 := r.ReadMapStart() - if yyl129 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl129, d) - } - } else if yyct129 == codecSelferValueTypeArray1234 { - yyl129 := r.ReadArrayStart() - if yyl129 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl129, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys130Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys130Slc - var yyhl130 bool = l >= 0 - for yyj130 := 0; ; yyj130++ { - if yyhl130 { - if yyj130 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys130Slc = r.DecodeBytes(yys130Slc, true, true) - yys130 := string(yys130Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys130 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv133 := &x.ListMeta - yym134 := z.DecBinary() - _ = yym134 - if false { - } else if z.HasExtensions() && z.DecExt(yyv133) { - } else { - z.DecFallback(yyv133, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv135 := &x.Items - yym136 := z.DecBinary() - _ = yym136 - if false { - } else { - h.decSliceCertificateSigningRequest((*[]CertificateSigningRequest)(yyv135), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys130) - } // end switch yys130 - } // end for yyj130 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj137 int - var yyb137 bool - var yyhl137 bool = l >= 0 - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv140 := &x.ListMeta - yym141 := z.DecBinary() - _ = yym141 - if false { - } else if z.HasExtensions() && z.DecExt(yyv140) { - } else { - z.DecFallback(yyv140, false) - } - } - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv142 := &x.Items - yym143 := z.DecBinary() - _ = yym143 - if false { - } else { - h.decSliceCertificateSigningRequest((*[]CertificateSigningRequest)(yyv142), d) - } - } - for { - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj137-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceCertificateSigningRequestCondition(v []CertificateSigningRequestCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv144 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy145 := &yyv144 - yy145.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCertificateSigningRequestCondition(v *[]CertificateSigningRequestCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv146 := *v - yyh146, yyl146 := z.DecSliceHelperStart() - var yyc146 bool - if yyl146 == 0 { - if yyv146 == nil { - yyv146 = []CertificateSigningRequestCondition{} - yyc146 = true - } else if len(yyv146) != 0 { - yyv146 = yyv146[:0] - yyc146 = true - } - } else if yyl146 > 0 { - var yyrr146, yyrl146 int - var yyrt146 bool - if yyl146 > cap(yyv146) { - - yyrg146 := len(yyv146) > 0 - yyv2146 := yyv146 - yyrl146, yyrt146 = z.DecInferLen(yyl146, z.DecBasicHandle().MaxInitLen, 72) - if yyrt146 { - if yyrl146 <= cap(yyv146) { - yyv146 = yyv146[:yyrl146] - } else { - yyv146 = make([]CertificateSigningRequestCondition, yyrl146) - } - } else { - yyv146 = make([]CertificateSigningRequestCondition, yyrl146) - } - yyc146 = true - yyrr146 = len(yyv146) - if yyrg146 { - copy(yyv146, yyv2146) - } - } else if yyl146 != len(yyv146) { - yyv146 = yyv146[:yyl146] - yyc146 = true - } - yyj146 := 0 - for ; yyj146 < yyrr146; yyj146++ { - yyh146.ElemContainerState(yyj146) - if r.TryDecodeAsNil() { - yyv146[yyj146] = CertificateSigningRequestCondition{} - } else { - yyv147 := &yyv146[yyj146] - yyv147.CodecDecodeSelf(d) - } - - } - if yyrt146 { - for ; yyj146 < yyl146; yyj146++ { - yyv146 = append(yyv146, CertificateSigningRequestCondition{}) - yyh146.ElemContainerState(yyj146) - if r.TryDecodeAsNil() { - yyv146[yyj146] = CertificateSigningRequestCondition{} - } else { - yyv148 := &yyv146[yyj146] - yyv148.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj146 := 0 - for ; !r.CheckBreak(); yyj146++ { - - if yyj146 >= len(yyv146) { - yyv146 = append(yyv146, CertificateSigningRequestCondition{}) // var yyz146 CertificateSigningRequestCondition - yyc146 = true - } - yyh146.ElemContainerState(yyj146) - if yyj146 < len(yyv146) { - if r.TryDecodeAsNil() { - yyv146[yyj146] = CertificateSigningRequestCondition{} - } else { - yyv149 := &yyv146[yyj146] - yyv149.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj146 < len(yyv146) { - yyv146 = yyv146[:yyj146] - yyc146 = true - } else if yyj146 == 0 && yyv146 == nil { - yyv146 = []CertificateSigningRequestCondition{} - yyc146 = true - } - } - yyh146.End() - if yyc146 { - *v = yyv146 - } -} - -func (x codecSelfer1234) encSliceCertificateSigningRequest(v []CertificateSigningRequest, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv150 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy151 := &yyv150 - yy151.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCertificateSigningRequest(v *[]CertificateSigningRequest, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv152 := *v - yyh152, yyl152 := z.DecSliceHelperStart() - var yyc152 bool - if yyl152 == 0 { - if yyv152 == nil { - yyv152 = []CertificateSigningRequest{} - yyc152 = true - } else if len(yyv152) != 0 { - yyv152 = yyv152[:0] - yyc152 = true - } - } else if yyl152 > 0 { - var yyrr152, yyrl152 int - var yyrt152 bool - if yyl152 > cap(yyv152) { - - yyrg152 := len(yyv152) > 0 - yyv2152 := yyv152 - yyrl152, yyrt152 = z.DecInferLen(yyl152, z.DecBasicHandle().MaxInitLen, 384) - if yyrt152 { - if yyrl152 <= cap(yyv152) { - yyv152 = yyv152[:yyrl152] - } else { - yyv152 = make([]CertificateSigningRequest, yyrl152) - } - } else { - yyv152 = make([]CertificateSigningRequest, yyrl152) - } - yyc152 = true - yyrr152 = len(yyv152) - if yyrg152 { - copy(yyv152, yyv2152) - } - } else if yyl152 != len(yyv152) { - yyv152 = yyv152[:yyl152] - yyc152 = true - } - yyj152 := 0 - for ; yyj152 < yyrr152; yyj152++ { - yyh152.ElemContainerState(yyj152) - if r.TryDecodeAsNil() { - yyv152[yyj152] = CertificateSigningRequest{} - } else { - yyv153 := &yyv152[yyj152] - yyv153.CodecDecodeSelf(d) - } - - } - if yyrt152 { - for ; yyj152 < yyl152; yyj152++ { - yyv152 = append(yyv152, CertificateSigningRequest{}) - yyh152.ElemContainerState(yyj152) - if r.TryDecodeAsNil() { - yyv152[yyj152] = CertificateSigningRequest{} - } else { - yyv154 := &yyv152[yyj152] - yyv154.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj152 := 0 - for ; !r.CheckBreak(); yyj152++ { - - if yyj152 >= len(yyv152) { - yyv152 = append(yyv152, CertificateSigningRequest{}) // var yyz152 CertificateSigningRequest - yyc152 = true - } - yyh152.ElemContainerState(yyj152) - if yyj152 < len(yyv152) { - if r.TryDecodeAsNil() { - yyv152[yyj152] = CertificateSigningRequest{} - } else { - yyv155 := &yyv152[yyj152] - yyv155.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj152 < len(yyv152) { - yyv152 = yyv152[:yyj152] - yyc152 = true - } else if yyj152 == 0 && yyv152 == nil { - yyv152 = []CertificateSigningRequest{} - yyc152 = true - } - } - yyh152.End() - if yyc152 { - *v = yyv152 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/types.go b/vendor/k8s.io/client-go/pkg/apis/certificates/types.go index 4fb5b01faf..4a7884a1ea 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/types.go @@ -16,54 +16,68 @@ limitations under the License. package certificates -import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" -) +import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" // +genclient=true // +nonNamespaced=true // Describes a certificate signing request type CertificateSigningRequest struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // The certificate request itself and any additional information. // +optional - Spec CertificateSigningRequestSpec `json:"spec,omitempty"` + Spec CertificateSigningRequestSpec // Derived information about the request. // +optional - Status CertificateSigningRequestStatus `json:"status,omitempty"` + Status CertificateSigningRequestStatus } // This information is immutable after the request is created. Only the Request -// and ExtraInfo fields can be set on creation, other fields are derived by +// and Usages fields can be set on creation, other fields are derived by // Kubernetes and cannot be modified by users. type CertificateSigningRequestSpec struct { // Base64-encoded PKCS#10 CSR data - Request []byte `json:"request"` + Request []byte + + // usages specifies a set of usage contexts the key will be + // valid for. + // See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 + // https://tools.ietf.org/html/rfc5280#section-4.2.1.12 + Usages []KeyUsage - // Information about the requesting user (if relevant) - // See user.Info interface for details + // Information about the requesting user. + // See user.Info interface for details. // +optional - Username string `json:"username,omitempty"` + Username string + // UID information about the requesting user. + // See user.Info interface for details. // +optional - UID string `json:"uid,omitempty"` + UID string + // Group information about the requesting user. + // See user.Info interface for details. // +optional - Groups []string `json:"groups,omitempty"` + Groups []string + // Extra information about the requesting user. + // See user.Info interface for details. + // +optional + Extra map[string]ExtraValue } +// ExtraValue masks the value so protobuf can generate +type ExtraValue []string + type CertificateSigningRequestStatus struct { // Conditions applied to the request, such as approval or denial. // +optional - Conditions []CertificateSigningRequestCondition `json:"conditions,omitempty"` + Conditions []CertificateSigningRequestCondition // If request was approved, the controller will place the issued certificate here. // +optional - Certificate []byte `json:"certificate,omitempty"` + Certificate []byte } type RequestConditionType string @@ -76,23 +90,54 @@ const ( type CertificateSigningRequestCondition struct { // request approval state, currently Approved or Denied. - Type RequestConditionType `json:"type"` + Type RequestConditionType // brief reason for the request state // +optional - Reason string `json:"reason,omitempty"` + Reason string // human readable message with details about the request state // +optional - Message string `json:"message,omitempty"` + Message string // timestamp for the last update to this condition // +optional - LastUpdateTime unversioned.Time `json:"lastUpdateTime,omitempty"` + LastUpdateTime metav1.Time } type CertificateSigningRequestList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // +optional - Items []CertificateSigningRequest `json:"items,omitempty"` + Items []CertificateSigningRequest } + +// KeyUsages specifies valid usage contexts for keys. +// See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 +// https://tools.ietf.org/html/rfc5280#section-4.2.1.12 +type KeyUsage string + +const ( + UsageSigning KeyUsage = "signing" + UsageDigitalSignature KeyUsage = "digital signature" + UsageContentCommittment KeyUsage = "content committment" + UsageKeyEncipherment KeyUsage = "key encipherment" + UsageKeyAgreement KeyUsage = "key agreement" + UsageDataEncipherment KeyUsage = "data encipherment" + UsageCertSign KeyUsage = "cert sign" + UsageCRLSign KeyUsage = "crl sign" + UsageEncipherOnly KeyUsage = "encipher only" + UsageDecipherOnly KeyUsage = "decipher only" + UsageAny KeyUsage = "any" + UsageServerAuth KeyUsage = "server auth" + UsageClientAuth KeyUsage = "client auth" + UsageCodeSigning KeyUsage = "code signing" + UsageEmailProtection KeyUsage = "email protection" + UsageSMIME KeyUsage = "s/mime" + UsageIPsecEndSystem KeyUsage = "ipsec end system" + UsageIPsecTunnel KeyUsage = "ipsec tunnel" + UsageIPsecUser KeyUsage = "ipsec user" + UsageTimestamping KeyUsage = "timestamping" + UsageOCSPSigning KeyUsage = "ocsp signing" + UsageMicrosoftSGC KeyUsage = "microsoft sgc" + UsageNetscapSGC KeyUsage = "netscape sgc" +) diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.generated.go deleted file mode 100644 index 78f2d6086b..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.generated.go +++ /dev/null @@ -1,1950 +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 v1alpha1 - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" - "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 pkg1_unversioned.TypeMeta - var v1 pkg2_v1.ObjectMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 - } -} - -func (x *CertificateSigningRequest) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = true - yyq2[3] = true - yyq2[4] = true - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { - yy13 := &x.Spec - yy13.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy14 := &x.Spec - yy14.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - yy16 := &x.Status - yy16.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy17 := &x.Status - yy17.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequest) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl19, d) - } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl19, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - 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 = pkg2_v1.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = CertificateSigningRequestSpec{} - } else { - yyv24 := &x.Spec - yyv24.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = CertificateSigningRequestStatus{} - } else { - yyv25 := &x.Status - yyv25.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv29 := &x.ObjectMeta - yyv29.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = CertificateSigningRequestSpec{} - } else { - yyv30 := &x.Spec - yyv30.CodecDecodeSelf(d) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = CertificateSigningRequestStatus{} - } else { - yyv31 := &x.Status - yyv31.CodecDecodeSelf(d) - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CertificateSigningRequestSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym32 := z.EncBinary() - _ = yym32 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep33 := !z.EncBinary() - yy2arr33 := z.EncBasicHandle().StructToArray - var yyq33 [4]bool - _, _, _ = yysep33, yyq33, yy2arr33 - const yyr33 bool = false - yyq33[1] = x.Username != "" - yyq33[2] = x.UID != "" - yyq33[3] = len(x.Groups) != 0 - var yynn33 int - if yyr33 || yy2arr33 { - r.EncodeArrayStart(4) - } else { - yynn33 = 1 - for _, b := range yyq33 { - if b { - yynn33++ - } - } - r.EncodeMapStart(yynn33) - yynn33 = 0 - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Request == nil { - r.EncodeNil() - } else { - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Request)) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("request")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Request == nil { - r.EncodeNil() - } else { - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Request)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[1] { - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Username)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("username")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Username)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[2] { - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq33[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("uid")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym42 := z.EncBinary() - _ = yym42 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.UID)) - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq33[3] { - if x.Groups == nil { - r.EncodeNil() - } else { - yym44 := z.EncBinary() - _ = yym44 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq33[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("groups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Groups == nil { - r.EncodeNil() - } else { - yym45 := z.EncBinary() - _ = yym45 - if false { - } else { - z.F.EncSliceStringV(x.Groups, false, e) - } - } - } - } - if yyr33 || yy2arr33 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym46 := z.DecBinary() - _ = yym46 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct47 := r.ContainerType() - if yyct47 == codecSelferValueTypeMap1234 { - yyl47 := r.ReadMapStart() - if yyl47 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl47, d) - } - } else if yyct47 == codecSelferValueTypeArray1234 { - yyl47 := r.ReadArrayStart() - if yyl47 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl47, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys48Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys48Slc - var yyhl48 bool = l >= 0 - for yyj48 := 0; ; yyj48++ { - if yyhl48 { - if yyj48 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys48Slc = r.DecodeBytes(yys48Slc, true, true) - yys48 := string(yys48Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys48 { - case "request": - if r.TryDecodeAsNil() { - x.Request = nil - } else { - yyv49 := &x.Request - yym50 := z.DecBinary() - _ = yym50 - if false { - } else { - *yyv49 = r.DecodeBytes(*(*[]byte)(yyv49), false, false) - } - } - case "username": - if r.TryDecodeAsNil() { - x.Username = "" - } else { - x.Username = string(r.DecodeString()) - } - case "uid": - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = string(r.DecodeString()) - } - case "groups": - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv53 := &x.Groups - yym54 := z.DecBinary() - _ = yym54 - if false { - } else { - z.F.DecSliceStringX(yyv53, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys48) - } // end switch yys48 - } // end for yyj48 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj55 int - var yyb55 bool - var yyhl55 bool = l >= 0 - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Request = nil - } else { - yyv56 := &x.Request - yym57 := z.DecBinary() - _ = yym57 - if false { - } else { - *yyv56 = r.DecodeBytes(*(*[]byte)(yyv56), false, false) - } - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Username = "" - } else { - x.Username = string(r.DecodeString()) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UID = "" - } else { - x.UID = string(r.DecodeString()) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Groups = nil - } else { - yyv60 := &x.Groups - yym61 := z.DecBinary() - _ = yym61 - if false { - } else { - z.F.DecSliceStringX(yyv60, false, d) - } - } - for { - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj55-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CertificateSigningRequestStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym62 := z.EncBinary() - _ = yym62 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep63 := !z.EncBinary() - yy2arr63 := z.EncBasicHandle().StructToArray - var yyq63 [2]bool - _, _, _ = yysep63, yyq63, yy2arr63 - const yyr63 bool = false - yyq63[0] = len(x.Conditions) != 0 - yyq63[1] = len(x.Certificate) != 0 - var yynn63 int - if yyr63 || yy2arr63 { - r.EncodeArrayStart(2) - } else { - yynn63 = 0 - for _, b := range yyq63 { - if b { - yynn63++ - } - } - r.EncodeMapStart(yynn63) - yynn63 = 0 - } - if yyr63 || yy2arr63 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq63[0] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - h.encSliceCertificateSigningRequestCondition(([]CertificateSigningRequestCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq63[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym66 := z.EncBinary() - _ = yym66 - if false { - } else { - h.encSliceCertificateSigningRequestCondition(([]CertificateSigningRequestCondition)(x.Conditions), e) - } - } - } - } - if yyr63 || yy2arr63 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq63[1] { - if x.Certificate == nil { - r.EncodeNil() - } else { - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Certificate)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq63[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("certificate")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Certificate == nil { - r.EncodeNil() - } else { - yym69 := z.EncBinary() - _ = yym69 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Certificate)) - } - } - } - } - if yyr63 || yy2arr63 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym70 := z.DecBinary() - _ = yym70 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct71 := r.ContainerType() - if yyct71 == codecSelferValueTypeMap1234 { - yyl71 := r.ReadMapStart() - if yyl71 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl71, d) - } - } else if yyct71 == codecSelferValueTypeArray1234 { - yyl71 := r.ReadArrayStart() - if yyl71 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl71, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys72Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys72Slc - var yyhl72 bool = l >= 0 - for yyj72 := 0; ; yyj72++ { - if yyhl72 { - if yyj72 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys72Slc = r.DecodeBytes(yys72Slc, true, true) - yys72 := string(yys72Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys72 { - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv73 := &x.Conditions - yym74 := z.DecBinary() - _ = yym74 - if false { - } else { - h.decSliceCertificateSigningRequestCondition((*[]CertificateSigningRequestCondition)(yyv73), d) - } - } - case "certificate": - if r.TryDecodeAsNil() { - x.Certificate = nil - } else { - yyv75 := &x.Certificate - yym76 := z.DecBinary() - _ = yym76 - if false { - } else { - *yyv75 = r.DecodeBytes(*(*[]byte)(yyv75), false, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys72) - } // end switch yys72 - } // end for yyj72 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestStatus) 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.Conditions = nil - } else { - yyv78 := &x.Conditions - yym79 := z.DecBinary() - _ = yym79 - if false { - } else { - h.decSliceCertificateSigningRequestCondition((*[]CertificateSigningRequestCondition)(yyv78), 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.Certificate = nil - } else { - yyv80 := &x.Certificate - yym81 := z.DecBinary() - _ = yym81 - if false { - } else { - *yyv80 = r.DecodeBytes(*(*[]byte)(yyv80), false, false) - } - } - 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 RequestConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym82 := z.EncBinary() - _ = yym82 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *RequestConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym83 := z.DecBinary() - _ = yym83 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *CertificateSigningRequestCondition) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym84 := z.EncBinary() - _ = yym84 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep85 := !z.EncBinary() - yy2arr85 := z.EncBasicHandle().StructToArray - var yyq85 [4]bool - _, _, _ = yysep85, yyq85, yy2arr85 - const yyr85 bool = false - yyq85[1] = x.Reason != "" - yyq85[2] = x.Message != "" - yyq85[3] = true - var yynn85 int - if yyr85 || yy2arr85 { - r.EncodeArrayStart(4) - } else { - yynn85 = 1 - for _, b := range yyq85 { - if b { - yynn85++ - } - } - r.EncodeMapStart(yynn85) - yynn85 = 0 - } - if yyr85 || yy2arr85 { - 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 yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq85[1] { - yym88 := z.EncBinary() - _ = yym88 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq85[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym89 := z.EncBinary() - _ = yym89 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq85[2] { - yym91 := z.EncBinary() - _ = yym91 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq85[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym92 := z.EncBinary() - _ = yym92 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq85[3] { - yy94 := &x.LastUpdateTime - yym95 := z.EncBinary() - _ = yym95 - if false { - } else if z.HasExtensions() && z.EncExt(yy94) { - } else if yym95 { - z.EncBinaryMarshal(yy94) - } else if !yym95 && z.IsJSONHandle() { - z.EncJSONMarshal(yy94) - } else { - z.EncFallback(yy94) - } - } else { - r.EncodeNil() - } - } else { - if yyq85[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy96 := &x.LastUpdateTime - yym97 := z.EncBinary() - _ = yym97 - if false { - } else if z.HasExtensions() && z.EncExt(yy96) { - } else if yym97 { - z.EncBinaryMarshal(yy96) - } else if !yym97 && z.IsJSONHandle() { - z.EncJSONMarshal(yy96) - } else { - z.EncFallback(yy96) - } - } - } - if yyr85 || yy2arr85 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym98 := z.DecBinary() - _ = yym98 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct99 := r.ContainerType() - if yyct99 == codecSelferValueTypeMap1234 { - yyl99 := r.ReadMapStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl99, d) - } - } else if yyct99 == codecSelferValueTypeArray1234 { - yyl99 := r.ReadArrayStart() - if yyl99 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl99, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys100Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys100Slc - var yyhl100 bool = l >= 0 - for yyj100 := 0; ; yyj100++ { - if yyhl100 { - if yyj100 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys100Slc = r.DecodeBytes(yys100Slc, true, true) - yys100 := string(yys100Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys100 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = RequestConditionType(r.DecodeString()) - } - 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 "lastUpdateTime": - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv104 := &x.LastUpdateTime - yym105 := z.DecBinary() - _ = yym105 - if false { - } else if z.HasExtensions() && z.DecExt(yyv104) { - } else if yym105 { - z.DecBinaryUnmarshal(yyv104) - } else if !yym105 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv104) - } else { - z.DecFallback(yyv104, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys100) - } // end switch yys100 - } // end for yyj100 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj106 int - var yyb106 bool - var yyhl106 bool = l >= 0 - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = RequestConditionType(r.DecodeString()) - } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv110 := &x.LastUpdateTime - yym111 := z.DecBinary() - _ = yym111 - if false { - } else if z.HasExtensions() && z.DecExt(yyv110) { - } else if yym111 { - z.DecBinaryUnmarshal(yyv110) - } else if !yym111 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv110) - } else { - z.DecFallback(yyv110, false) - } - } - for { - yyj106++ - if yyhl106 { - yyb106 = yyj106 > l - } else { - yyb106 = r.CheckBreak() - } - if yyb106 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj106-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CertificateSigningRequestList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym112 := z.EncBinary() - _ = yym112 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep113 := !z.EncBinary() - yy2arr113 := z.EncBasicHandle().StructToArray - var yyq113 [4]bool - _, _, _ = yysep113, yyq113, yy2arr113 - const yyr113 bool = false - yyq113[0] = x.Kind != "" - yyq113[1] = x.APIVersion != "" - yyq113[2] = true - var yynn113 int - if yyr113 || yy2arr113 { - r.EncodeArrayStart(4) - } else { - yynn113 = 1 - for _, b := range yyq113 { - if b { - yynn113++ - } - } - r.EncodeMapStart(yynn113) - yynn113 = 0 - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[0] { - yym115 := z.EncBinary() - _ = yym115 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq113[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym116 := z.EncBinary() - _ = yym116 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[1] { - yym118 := z.EncBinary() - _ = yym118 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq113[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym119 := z.EncBinary() - _ = yym119 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq113[2] { - yy121 := &x.ListMeta - yym122 := z.EncBinary() - _ = yym122 - if false { - } else if z.HasExtensions() && z.EncExt(yy121) { - } else { - z.EncFallback(yy121) - } - } else { - r.EncodeNil() - } - } else { - if yyq113[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy123 := &x.ListMeta - yym124 := z.EncBinary() - _ = yym124 - if false { - } else if z.HasExtensions() && z.EncExt(yy123) { - } else { - z.EncFallback(yy123) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym126 := z.EncBinary() - _ = yym126 - if false { - } else { - h.encSliceCertificateSigningRequest(([]CertificateSigningRequest)(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 { - yym127 := z.EncBinary() - _ = yym127 - if false { - } else { - h.encSliceCertificateSigningRequest(([]CertificateSigningRequest)(x.Items), e) - } - } - } - if yyr113 || yy2arr113 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CertificateSigningRequestList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym128 := z.DecBinary() - _ = yym128 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct129 := r.ContainerType() - if yyct129 == codecSelferValueTypeMap1234 { - yyl129 := r.ReadMapStart() - if yyl129 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl129, d) - } - } else if yyct129 == codecSelferValueTypeArray1234 { - yyl129 := r.ReadArrayStart() - if yyl129 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl129, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CertificateSigningRequestList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys130Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys130Slc - var yyhl130 bool = l >= 0 - for yyj130 := 0; ; yyj130++ { - if yyhl130 { - if yyj130 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys130Slc = r.DecodeBytes(yys130Slc, true, true) - yys130 := string(yys130Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys130 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv133 := &x.ListMeta - yym134 := z.DecBinary() - _ = yym134 - if false { - } else if z.HasExtensions() && z.DecExt(yyv133) { - } else { - z.DecFallback(yyv133, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv135 := &x.Items - yym136 := z.DecBinary() - _ = yym136 - if false { - } else { - h.decSliceCertificateSigningRequest((*[]CertificateSigningRequest)(yyv135), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys130) - } // end switch yys130 - } // end for yyj130 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CertificateSigningRequestList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj137 int - var yyb137 bool - var yyhl137 bool = l >= 0 - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv140 := &x.ListMeta - yym141 := z.DecBinary() - _ = yym141 - if false { - } else if z.HasExtensions() && z.DecExt(yyv140) { - } else { - z.DecFallback(yyv140, false) - } - } - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv142 := &x.Items - yym143 := z.DecBinary() - _ = yym143 - if false { - } else { - h.decSliceCertificateSigningRequest((*[]CertificateSigningRequest)(yyv142), d) - } - } - for { - yyj137++ - if yyhl137 { - yyb137 = yyj137 > l - } else { - yyb137 = r.CheckBreak() - } - if yyb137 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj137-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceCertificateSigningRequestCondition(v []CertificateSigningRequestCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv144 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy145 := &yyv144 - yy145.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCertificateSigningRequestCondition(v *[]CertificateSigningRequestCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv146 := *v - yyh146, yyl146 := z.DecSliceHelperStart() - var yyc146 bool - if yyl146 == 0 { - if yyv146 == nil { - yyv146 = []CertificateSigningRequestCondition{} - yyc146 = true - } else if len(yyv146) != 0 { - yyv146 = yyv146[:0] - yyc146 = true - } - } else if yyl146 > 0 { - var yyrr146, yyrl146 int - var yyrt146 bool - if yyl146 > cap(yyv146) { - - yyrg146 := len(yyv146) > 0 - yyv2146 := yyv146 - yyrl146, yyrt146 = z.DecInferLen(yyl146, z.DecBasicHandle().MaxInitLen, 72) - if yyrt146 { - if yyrl146 <= cap(yyv146) { - yyv146 = yyv146[:yyrl146] - } else { - yyv146 = make([]CertificateSigningRequestCondition, yyrl146) - } - } else { - yyv146 = make([]CertificateSigningRequestCondition, yyrl146) - } - yyc146 = true - yyrr146 = len(yyv146) - if yyrg146 { - copy(yyv146, yyv2146) - } - } else if yyl146 != len(yyv146) { - yyv146 = yyv146[:yyl146] - yyc146 = true - } - yyj146 := 0 - for ; yyj146 < yyrr146; yyj146++ { - yyh146.ElemContainerState(yyj146) - if r.TryDecodeAsNil() { - yyv146[yyj146] = CertificateSigningRequestCondition{} - } else { - yyv147 := &yyv146[yyj146] - yyv147.CodecDecodeSelf(d) - } - - } - if yyrt146 { - for ; yyj146 < yyl146; yyj146++ { - yyv146 = append(yyv146, CertificateSigningRequestCondition{}) - yyh146.ElemContainerState(yyj146) - if r.TryDecodeAsNil() { - yyv146[yyj146] = CertificateSigningRequestCondition{} - } else { - yyv148 := &yyv146[yyj146] - yyv148.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj146 := 0 - for ; !r.CheckBreak(); yyj146++ { - - if yyj146 >= len(yyv146) { - yyv146 = append(yyv146, CertificateSigningRequestCondition{}) // var yyz146 CertificateSigningRequestCondition - yyc146 = true - } - yyh146.ElemContainerState(yyj146) - if yyj146 < len(yyv146) { - if r.TryDecodeAsNil() { - yyv146[yyj146] = CertificateSigningRequestCondition{} - } else { - yyv149 := &yyv146[yyj146] - yyv149.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj146 < len(yyv146) { - yyv146 = yyv146[:yyj146] - yyc146 = true - } else if yyj146 == 0 && yyv146 == nil { - yyv146 = []CertificateSigningRequestCondition{} - yyc146 = true - } - } - yyh146.End() - if yyc146 { - *v = yyv146 - } -} - -func (x codecSelfer1234) encSliceCertificateSigningRequest(v []CertificateSigningRequest, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv150 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy151 := &yyv150 - yy151.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCertificateSigningRequest(v *[]CertificateSigningRequest, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv152 := *v - yyh152, yyl152 := z.DecSliceHelperStart() - var yyc152 bool - if yyl152 == 0 { - if yyv152 == nil { - yyv152 = []CertificateSigningRequest{} - yyc152 = true - } else if len(yyv152) != 0 { - yyv152 = yyv152[:0] - yyc152 = true - } - } else if yyl152 > 0 { - var yyrr152, yyrl152 int - var yyrt152 bool - if yyl152 > cap(yyv152) { - - yyrg152 := len(yyv152) > 0 - yyv2152 := yyv152 - yyrl152, yyrt152 = z.DecInferLen(yyl152, z.DecBasicHandle().MaxInitLen, 384) - if yyrt152 { - if yyrl152 <= cap(yyv152) { - yyv152 = yyv152[:yyrl152] - } else { - yyv152 = make([]CertificateSigningRequest, yyrl152) - } - } else { - yyv152 = make([]CertificateSigningRequest, yyrl152) - } - yyc152 = true - yyrr152 = len(yyv152) - if yyrg152 { - copy(yyv152, yyv2152) - } - } else if yyl152 != len(yyv152) { - yyv152 = yyv152[:yyl152] - yyc152 = true - } - yyj152 := 0 - for ; yyj152 < yyrr152; yyj152++ { - yyh152.ElemContainerState(yyj152) - if r.TryDecodeAsNil() { - yyv152[yyj152] = CertificateSigningRequest{} - } else { - yyv153 := &yyv152[yyj152] - yyv153.CodecDecodeSelf(d) - } - - } - if yyrt152 { - for ; yyj152 < yyl152; yyj152++ { - yyv152 = append(yyv152, CertificateSigningRequest{}) - yyh152.ElemContainerState(yyj152) - if r.TryDecodeAsNil() { - yyv152[yyj152] = CertificateSigningRequest{} - } else { - yyv154 := &yyv152[yyj152] - yyv154.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj152 := 0 - for ; !r.CheckBreak(); yyj152++ { - - if yyj152 >= len(yyv152) { - yyv152 = append(yyv152, CertificateSigningRequest{}) // var yyz152 CertificateSigningRequest - yyc152 = true - } - yyh152.ElemContainerState(yyj152) - if yyj152 < len(yyv152) { - if r.TryDecodeAsNil() { - yyv152[yyj152] = CertificateSigningRequest{} - } else { - yyv155 := &yyv152[yyj152] - yyv155.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj152 < len(yyv152) { - yyv152 = yyv152[:yyj152] - yyc152 = true - } else if yyj152 == 0 && yyv152 == nil { - yyv152 = []CertificateSigningRequest{} - yyc152 = true - } - } - yyh152.End() - if yyc152 { - *v = yyv152 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.conversion.go deleted file mode 100644 index 8e45ea1301..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.conversion.go +++ /dev/null @@ -1,173 +0,0 @@ -// +build !ignore_autogenerated - -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// This file was autogenerated by conversion-gen. Do not edit it manually! - -package v1alpha1 - -import ( - certificates "k8s.io/client-go/pkg/apis/certificates" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - unsafe "unsafe" -) - -func init() { - SchemeBuilder.Register(RegisterConversions) -} - -// RegisterConversions adds conversion functions to the given scheme. -// Public to allow building arbitrary schemes. -func RegisterConversions(scheme *runtime.Scheme) error { - return scheme.AddGeneratedConversionFuncs( - Convert_v1alpha1_CertificateSigningRequest_To_certificates_CertificateSigningRequest, - Convert_certificates_CertificateSigningRequest_To_v1alpha1_CertificateSigningRequest, - Convert_v1alpha1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition, - Convert_certificates_CertificateSigningRequestCondition_To_v1alpha1_CertificateSigningRequestCondition, - Convert_v1alpha1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList, - Convert_certificates_CertificateSigningRequestList_To_v1alpha1_CertificateSigningRequestList, - Convert_v1alpha1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec, - Convert_certificates_CertificateSigningRequestSpec_To_v1alpha1_CertificateSigningRequestSpec, - Convert_v1alpha1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus, - Convert_certificates_CertificateSigningRequestStatus_To_v1alpha1_CertificateSigningRequestStatus, - ) -} - -func autoConvert_v1alpha1_CertificateSigningRequest_To_certificates_CertificateSigningRequest(in *CertificateSigningRequest, out *certificates.CertificateSigningRequest, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_v1alpha1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_v1alpha1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_v1alpha1_CertificateSigningRequest_To_certificates_CertificateSigningRequest(in *CertificateSigningRequest, out *certificates.CertificateSigningRequest, s conversion.Scope) error { - return autoConvert_v1alpha1_CertificateSigningRequest_To_certificates_CertificateSigningRequest(in, out, s) -} - -func autoConvert_certificates_CertificateSigningRequest_To_v1alpha1_CertificateSigningRequest(in *certificates.CertificateSigningRequest, out *CertificateSigningRequest, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_certificates_CertificateSigningRequestSpec_To_v1alpha1_CertificateSigningRequestSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_certificates_CertificateSigningRequestStatus_To_v1alpha1_CertificateSigningRequestStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_certificates_CertificateSigningRequest_To_v1alpha1_CertificateSigningRequest(in *certificates.CertificateSigningRequest, out *CertificateSigningRequest, s conversion.Scope) error { - return autoConvert_certificates_CertificateSigningRequest_To_v1alpha1_CertificateSigningRequest(in, out, s) -} - -func autoConvert_v1alpha1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition(in *CertificateSigningRequestCondition, out *certificates.CertificateSigningRequestCondition, s conversion.Scope) error { - out.Type = certificates.RequestConditionType(in.Type) - out.Reason = in.Reason - out.Message = in.Message - out.LastUpdateTime = in.LastUpdateTime - return nil -} - -func Convert_v1alpha1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition(in *CertificateSigningRequestCondition, out *certificates.CertificateSigningRequestCondition, s conversion.Scope) error { - return autoConvert_v1alpha1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition(in, out, s) -} - -func autoConvert_certificates_CertificateSigningRequestCondition_To_v1alpha1_CertificateSigningRequestCondition(in *certificates.CertificateSigningRequestCondition, out *CertificateSigningRequestCondition, s conversion.Scope) error { - out.Type = RequestConditionType(in.Type) - out.Reason = in.Reason - out.Message = in.Message - out.LastUpdateTime = in.LastUpdateTime - return nil -} - -func Convert_certificates_CertificateSigningRequestCondition_To_v1alpha1_CertificateSigningRequestCondition(in *certificates.CertificateSigningRequestCondition, out *CertificateSigningRequestCondition, s conversion.Scope) error { - return autoConvert_certificates_CertificateSigningRequestCondition_To_v1alpha1_CertificateSigningRequestCondition(in, out, s) -} - -func autoConvert_v1alpha1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList(in *CertificateSigningRequestList, out *certificates.CertificateSigningRequestList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - out.Items = *(*[]certificates.CertificateSigningRequest)(unsafe.Pointer(&in.Items)) - return nil -} - -func Convert_v1alpha1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList(in *CertificateSigningRequestList, out *certificates.CertificateSigningRequestList, s conversion.Scope) error { - return autoConvert_v1alpha1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList(in, out, s) -} - -func autoConvert_certificates_CertificateSigningRequestList_To_v1alpha1_CertificateSigningRequestList(in *certificates.CertificateSigningRequestList, out *CertificateSigningRequestList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - out.Items = *(*[]CertificateSigningRequest)(unsafe.Pointer(&in.Items)) - return nil -} - -func Convert_certificates_CertificateSigningRequestList_To_v1alpha1_CertificateSigningRequestList(in *certificates.CertificateSigningRequestList, out *CertificateSigningRequestList, s conversion.Scope) error { - return autoConvert_certificates_CertificateSigningRequestList_To_v1alpha1_CertificateSigningRequestList(in, out, s) -} - -func autoConvert_v1alpha1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(in *CertificateSigningRequestSpec, out *certificates.CertificateSigningRequestSpec, s conversion.Scope) error { - out.Request = *(*[]byte)(unsafe.Pointer(&in.Request)) - out.Username = in.Username - out.UID = in.UID - out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) - return nil -} - -func Convert_v1alpha1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(in *CertificateSigningRequestSpec, out *certificates.CertificateSigningRequestSpec, s conversion.Scope) error { - return autoConvert_v1alpha1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(in, out, s) -} - -func autoConvert_certificates_CertificateSigningRequestSpec_To_v1alpha1_CertificateSigningRequestSpec(in *certificates.CertificateSigningRequestSpec, out *CertificateSigningRequestSpec, s conversion.Scope) error { - out.Request = *(*[]byte)(unsafe.Pointer(&in.Request)) - out.Username = in.Username - out.UID = in.UID - out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) - return nil -} - -func Convert_certificates_CertificateSigningRequestSpec_To_v1alpha1_CertificateSigningRequestSpec(in *certificates.CertificateSigningRequestSpec, out *CertificateSigningRequestSpec, s conversion.Scope) error { - return autoConvert_certificates_CertificateSigningRequestSpec_To_v1alpha1_CertificateSigningRequestSpec(in, out, s) -} - -func autoConvert_v1alpha1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(in *CertificateSigningRequestStatus, out *certificates.CertificateSigningRequestStatus, s conversion.Scope) error { - out.Conditions = *(*[]certificates.CertificateSigningRequestCondition)(unsafe.Pointer(&in.Conditions)) - out.Certificate = *(*[]byte)(unsafe.Pointer(&in.Certificate)) - return nil -} - -func Convert_v1alpha1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(in *CertificateSigningRequestStatus, out *certificates.CertificateSigningRequestStatus, s conversion.Scope) error { - return autoConvert_v1alpha1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(in, out, s) -} - -func autoConvert_certificates_CertificateSigningRequestStatus_To_v1alpha1_CertificateSigningRequestStatus(in *certificates.CertificateSigningRequestStatus, out *CertificateSigningRequestStatus, s conversion.Scope) error { - out.Conditions = *(*[]CertificateSigningRequestCondition)(unsafe.Pointer(&in.Conditions)) - out.Certificate = *(*[]byte)(unsafe.Pointer(&in.Certificate)) - return nil -} - -func Convert_certificates_CertificateSigningRequestStatus_To_v1alpha1_CertificateSigningRequestStatus(in *certificates.CertificateSigningRequestStatus, out *CertificateSigningRequestStatus, s conversion.Scope) error { - return autoConvert_certificates_CertificateSigningRequestStatus_To_v1alpha1_CertificateSigningRequestStatus(in, out, s) -} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.deepcopy.go deleted file mode 100644 index f6991dff34..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/zz_generated.deepcopy.go +++ /dev/null @@ -1,145 +0,0 @@ -// +build !ignore_autogenerated - -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// This file was autogenerated by deepcopy-gen. Do not edit it manually! - -package v1alpha1 - -import ( - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - reflect "reflect" -) - -func init() { - SchemeBuilder.Register(RegisterDeepCopies) -} - -// RegisterDeepCopies adds deep-copy functions to the given scheme. Public -// to allow building arbitrary schemes. -func RegisterDeepCopies(scheme *runtime.Scheme) error { - return scheme.AddGeneratedDeepCopyFuncs( - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CertificateSigningRequest, InType: reflect.TypeOf(&CertificateSigningRequest{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CertificateSigningRequestCondition, InType: reflect.TypeOf(&CertificateSigningRequestCondition{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CertificateSigningRequestList, InType: reflect.TypeOf(&CertificateSigningRequestList{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CertificateSigningRequestSpec, InType: reflect.TypeOf(&CertificateSigningRequestSpec{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_CertificateSigningRequestStatus, InType: reflect.TypeOf(&CertificateSigningRequestStatus{})}, - ) -} - -func DeepCopy_v1alpha1_CertificateSigningRequest(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*CertificateSigningRequest) - out := out.(*CertificateSigningRequest) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { - return err - } - if err := DeepCopy_v1alpha1_CertificateSigningRequestSpec(&in.Spec, &out.Spec, c); err != nil { - return err - } - if err := DeepCopy_v1alpha1_CertificateSigningRequestStatus(&in.Status, &out.Status, c); err != nil { - return err - } - return nil - } -} - -func DeepCopy_v1alpha1_CertificateSigningRequestCondition(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*CertificateSigningRequestCondition) - out := out.(*CertificateSigningRequestCondition) - out.Type = in.Type - out.Reason = in.Reason - out.Message = in.Message - out.LastUpdateTime = in.LastUpdateTime.DeepCopy() - return nil - } -} - -func DeepCopy_v1alpha1_CertificateSigningRequestList(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*CertificateSigningRequestList) - out := out.(*CertificateSigningRequestList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]CertificateSigningRequest, len(*in)) - for i := range *in { - if err := DeepCopy_v1alpha1_CertificateSigningRequest(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil - } -} - -func DeepCopy_v1alpha1_CertificateSigningRequestSpec(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*CertificateSigningRequestSpec) - out := out.(*CertificateSigningRequestSpec) - if in.Request != nil { - in, out := &in.Request, &out.Request - *out = make([]byte, len(*in)) - copy(*out, *in) - } else { - out.Request = nil - } - out.Username = in.Username - out.UID = in.UID - if in.Groups != nil { - in, out := &in.Groups, &out.Groups - *out = make([]string, len(*in)) - copy(*out, *in) - } else { - out.Groups = nil - } - return nil - } -} - -func DeepCopy_v1alpha1_CertificateSigningRequestStatus(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*CertificateSigningRequestStatus) - out := out.(*CertificateSigningRequestStatus) - if in.Conditions != nil { - in, out := &in.Conditions, &out.Conditions - *out = make([]CertificateSigningRequestCondition, len(*in)) - for i := range *in { - if err := DeepCopy_v1alpha1_CertificateSigningRequestCondition(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Conditions = nil - } - if in.Certificate != nil { - in, out := &in.Certificate, &out.Certificate - *out = make([]byte, len(*in)) - copy(*out, *in) - } else { - out.Certificate = nil - } - return nil - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/BUILD new file mode 100644 index 0000000000..22e172a618 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/BUILD @@ -0,0 +1,38 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "helpers.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/certificates:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/conversion.go similarity index 83% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/conversion.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/conversion.go index e8e4a29741..b9cf0b0163 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/conversion.go @@ -14,19 +14,18 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( "fmt" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addConversionFuncs(scheme *runtime.Scheme) error { // Add non-generated conversion functions here. Currently there are none. - return api.Scheme.AddFieldLabelConversionFunc(SchemeGroupVersion.String(), "CertificateSigningRequest", + return scheme.AddFieldLabelConversionFunc(SchemeGroupVersion.String(), "CertificateSigningRequest", func(label, value string) (string, string, error) { switch label { case "metadata.name": diff --git a/vendor/k8s.io/client-go/pkg/api/unversioned/register.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/defaults.go similarity index 59% rename from vendor/k8s.io/client-go/pkg/api/unversioned/register.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/defaults.go index 907188bc74..e18af02f61 100644 --- a/vendor/k8s.io/client-go/pkg/api/unversioned/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/defaults.go @@ -1,5 +1,5 @@ /* -Copyright 2014 The Kubernetes Authors. +Copyright 2017 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. @@ -14,12 +14,15 @@ See the License for the specific language governing permissions and limitations under the License. */ -package unversioned +package v1beta1 -// SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = GroupVersion{Group: "", Version: ""} +import "k8s.io/apimachinery/pkg/runtime" -// Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) GroupKind { - return SchemeGroupVersion.WithKind(kind).GroupKind() +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} +func SetDefaults_CertificateSigningRequestSpec(obj *CertificateSigningRequestSpec) { + if obj.Usages == nil { + obj.Usages = []KeyUsage{UsageDigitalSignature, UsageKeyEncipherment} + } } diff --git a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/generated_expansion.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/doc.go similarity index 89% rename from vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/generated_expansion.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/doc.go index a2e74c84df..6f257909de 100644 --- a/vendor/k8s.io/client-go/kubernetes/typed/policy/v1alpha1/generated_expansion.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/doc.go @@ -14,6 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 - -type PodDisruptionBudgetExpansion interface{} +// +groupName=certificates.k8s.io +package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go similarity index 55% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/generated.pb.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go index 9d8377abcd..347df9826c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -15,14 +15,14 @@ limitations under the License. */ // Code generated by protoc-gen-gogo. -// source: k8s.io/kubernetes/pkg/apis/certificates/v1alpha1/generated.proto +// source: k8s.io/kubernetes/pkg/apis/certificates/v1beta1/generated.proto // DO NOT EDIT! /* - Package v1alpha1 is a generated protocol buffer package. + Package v1beta1 is a generated protocol buffer package. It is generated from these files: - k8s.io/kubernetes/pkg/apis/certificates/v1alpha1/generated.proto + k8s.io/kubernetes/pkg/apis/certificates/v1beta1/generated.proto It has these top-level messages: CertificateSigningRequest @@ -30,13 +30,16 @@ limitations under the License. CertificateSigningRequestList CertificateSigningRequestSpec CertificateSigningRequestStatus + ExtraValue */ -package v1alpha1 +package v1beta1 import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + import strings "strings" import reflect "reflect" @@ -49,7 +52,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *CertificateSigningRequest) Reset() { *m = CertificateSigningRequest{} } func (*CertificateSigningRequest) ProtoMessage() {} @@ -81,48 +86,53 @@ func (*CertificateSigningRequestStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } +func (m *ExtraValue) Reset() { *m = ExtraValue{} } +func (*ExtraValue) ProtoMessage() {} +func (*ExtraValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + func init() { - proto.RegisterType((*CertificateSigningRequest)(nil), "k8s.io.client-go.pkg.apis.certificates.v1alpha1.CertificateSigningRequest") - proto.RegisterType((*CertificateSigningRequestCondition)(nil), "k8s.io.client-go.pkg.apis.certificates.v1alpha1.CertificateSigningRequestCondition") - proto.RegisterType((*CertificateSigningRequestList)(nil), "k8s.io.client-go.pkg.apis.certificates.v1alpha1.CertificateSigningRequestList") - proto.RegisterType((*CertificateSigningRequestSpec)(nil), "k8s.io.client-go.pkg.apis.certificates.v1alpha1.CertificateSigningRequestSpec") - proto.RegisterType((*CertificateSigningRequestStatus)(nil), "k8s.io.client-go.pkg.apis.certificates.v1alpha1.CertificateSigningRequestStatus") + proto.RegisterType((*CertificateSigningRequest)(nil), "k8s.io.client-go.pkg.apis.certificates.v1beta1.CertificateSigningRequest") + proto.RegisterType((*CertificateSigningRequestCondition)(nil), "k8s.io.client-go.pkg.apis.certificates.v1beta1.CertificateSigningRequestCondition") + proto.RegisterType((*CertificateSigningRequestList)(nil), "k8s.io.client-go.pkg.apis.certificates.v1beta1.CertificateSigningRequestList") + proto.RegisterType((*CertificateSigningRequestSpec)(nil), "k8s.io.client-go.pkg.apis.certificates.v1beta1.CertificateSigningRequestSpec") + proto.RegisterType((*CertificateSigningRequestStatus)(nil), "k8s.io.client-go.pkg.apis.certificates.v1beta1.CertificateSigningRequestStatus") + proto.RegisterType((*ExtraValue)(nil), "k8s.io.client-go.pkg.apis.certificates.v1beta1.ExtraValue") } -func (m *CertificateSigningRequest) Marshal() (data []byte, err error) { +func (m *CertificateSigningRequest) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CertificateSigningRequest) MarshalTo(data []byte) (int, error) { +func (m *CertificateSigningRequest) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n2, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n3, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n3, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -130,37 +140,37 @@ func (m *CertificateSigningRequest) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CertificateSigningRequestCondition) Marshal() (data []byte, err error) { +func (m *CertificateSigningRequestCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CertificateSigningRequestCondition) MarshalTo(data []byte) (int, error) { +func (m *CertificateSigningRequestCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastUpdateTime.Size())) - n4, err := m.LastUpdateTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastUpdateTime.Size())) + n4, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -168,35 +178,35 @@ func (m *CertificateSigningRequestCondition) MarshalTo(data []byte) (int, error) return i, nil } -func (m *CertificateSigningRequestList) Marshal() (data []byte, err error) { +func (m *CertificateSigningRequestList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CertificateSigningRequestList) MarshalTo(data []byte) (int, error) { +func (m *CertificateSigningRequestList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n5, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n5, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n5 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -206,74 +216,120 @@ func (m *CertificateSigningRequestList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CertificateSigningRequestSpec) Marshal() (data []byte, err error) { +func (m *CertificateSigningRequestSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CertificateSigningRequestSpec) MarshalTo(data []byte) (int, error) { +func (m *CertificateSigningRequestSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Request != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Request))) - i += copy(data[i:], m.Request) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Request))) + i += copy(dAtA[i:], m.Request) } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Username))) - i += copy(data[i:], m.Username) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Username))) + i += copy(dAtA[i:], m.Username) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.UID))) - i += copy(data[i:], m.UID) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.UID))) + i += copy(dAtA[i:], m.UID) if len(m.Groups) > 0 { for _, s := range m.Groups { - data[i] = 0x22 + dAtA[i] = 0x22 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Usages) > 0 { + for _, s := range m.Usages { + dAtA[i] = 0x2a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Extra) > 0 { + keysForExtra := make([]string, 0, len(m.Extra)) + for k := range m.Extra { + keysForExtra = append(keysForExtra, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + for _, k := range keysForExtra { + dAtA[i] = 0x32 i++ - i += copy(data[i:], s) + v := m.Extra[string(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n6, err := (&v).MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 } } return i, nil } -func (m *CertificateSigningRequestStatus) Marshal() (data []byte, err error) { +func (m *CertificateSigningRequestStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CertificateSigningRequestStatus) MarshalTo(data []byte) (int, error) { +func (m *CertificateSigningRequestStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -281,39 +337,72 @@ func (m *CertificateSigningRequestStatus) MarshalTo(data []byte) (int, error) { } } if m.Certificate != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Certificate))) - i += copy(data[i:], m.Certificate) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Certificate))) + i += copy(dAtA[i:], m.Certificate) + } + return i, nil +} + +func (m ExtraValue) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m ExtraValue) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } } return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *CertificateSigningRequest) Size() (n int) { @@ -373,6 +462,21 @@ func (m *CertificateSigningRequestSpec) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) } } + if len(m.Usages) > 0 { + for _, s := range m.Usages { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Extra) > 0 { + for k, v := range m.Extra { + _ = k + _ = v + l = v.Size() + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + l + sovGenerated(uint64(l)) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } return n } @@ -392,6 +496,18 @@ func (m *CertificateSigningRequestStatus) Size() (n int) { return n } +func (m ExtraValue) Size() (n int) { + var l int + _ = l + if len(m) > 0 { + for _, s := range m { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + func sovGenerated(x uint64) (n int) { for { n++ @@ -410,7 +526,7 @@ func (this *CertificateSigningRequest) String() string { return "nil" } s := strings.Join([]string{`&CertificateSigningRequest{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "CertificateSigningRequestSpec", "CertificateSigningRequestSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "CertificateSigningRequestStatus", "CertificateSigningRequestStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -425,7 +541,7 @@ func (this *CertificateSigningRequestCondition) String() string { `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `LastUpdateTime:` + strings.Replace(strings.Replace(this.LastUpdateTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastUpdateTime:` + strings.Replace(strings.Replace(this.LastUpdateTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -435,7 +551,7 @@ func (this *CertificateSigningRequestList) String() string { return "nil" } s := strings.Join([]string{`&CertificateSigningRequestList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "CertificateSigningRequest", "CertificateSigningRequest", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -445,11 +561,23 @@ func (this *CertificateSigningRequestSpec) String() string { if this == nil { return "nil" } + keysForExtra := make([]string, 0, len(this.Extra)) + for k := range this.Extra { + keysForExtra = append(keysForExtra, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForExtra) + mapStringForExtra := "map[string]ExtraValue{" + for _, k := range keysForExtra { + mapStringForExtra += fmt.Sprintf("%v: %v,", k, this.Extra[k]) + } + mapStringForExtra += "}" s := strings.Join([]string{`&CertificateSigningRequestSpec{`, `Request:` + valueToStringGenerated(this.Request) + `,`, `Username:` + fmt.Sprintf("%v", this.Username) + `,`, `UID:` + fmt.Sprintf("%v", this.UID) + `,`, `Groups:` + fmt.Sprintf("%v", this.Groups) + `,`, + `Usages:` + fmt.Sprintf("%v", this.Usages) + `,`, + `Extra:` + mapStringForExtra + `,`, `}`, }, "") return s @@ -473,8 +601,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *CertificateSigningRequest) Unmarshal(data []byte) error { - l := len(data) +func (m *CertificateSigningRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -486,7 +614,7 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -514,7 +642,7 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -528,7 +656,7 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -544,7 +672,7 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -558,7 +686,7 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -574,7 +702,7 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -588,13 +716,13 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -613,8 +741,8 @@ func (m *CertificateSigningRequest) Unmarshal(data []byte) error { } return nil } -func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *CertificateSigningRequestCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -626,7 +754,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -654,7 +782,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -669,7 +797,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = RequestConditionType(data[iNdEx:postIndex]) + m.Type = RequestConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -683,7 +811,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -698,7 +826,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -712,7 +840,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -727,7 +855,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -741,7 +869,7 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -755,13 +883,13 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastUpdateTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastUpdateTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -780,8 +908,8 @@ func (m *CertificateSigningRequestCondition) Unmarshal(data []byte) error { } return nil } -func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { - l := len(data) +func (m *CertificateSigningRequestList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -793,7 +921,7 @@ func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -821,7 +949,7 @@ func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -835,7 +963,7 @@ func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -851,7 +979,7 @@ func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -866,13 +994,13 @@ func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, CertificateSigningRequest{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -891,8 +1019,8 @@ func (m *CertificateSigningRequestList) Unmarshal(data []byte) error { } return nil } -func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *CertificateSigningRequestSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -904,7 +1032,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -932,7 +1060,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -946,7 +1074,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Request = append(m.Request[:0], data[iNdEx:postIndex]...) + m.Request = append(m.Request[:0], dAtA[iNdEx:postIndex]...) if m.Request == nil { m.Request = []byte{} } @@ -963,7 +1091,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -978,7 +1106,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Username = string(data[iNdEx:postIndex]) + m.Username = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -992,7 +1120,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1007,7 +1135,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.UID = string(data[iNdEx:postIndex]) + m.UID = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -1021,7 +1149,7 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1036,11 +1164,161 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Groups = append(m.Groups, string(data[iNdEx:postIndex])) + m.Groups = append(m.Groups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Usages", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Usages = append(m.Usages, KeyUsage(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Extra", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Extra == nil { + m.Extra = make(map[string]ExtraValue) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue := &ExtraValue{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + m.Extra[mapkey] = *mapvalue + } else { + var mapvalue ExtraValue + m.Extra[mapkey] = mapvalue + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1059,8 +1337,8 @@ func (m *CertificateSigningRequestSpec) Unmarshal(data []byte) error { } return nil } -func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *CertificateSigningRequestStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1072,7 +1350,7 @@ func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1100,7 +1378,7 @@ func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1115,7 +1393,7 @@ func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, CertificateSigningRequestCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1131,7 +1409,7 @@ func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1145,14 +1423,14 @@ func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Certificate = append(m.Certificate[:0], data[iNdEx:postIndex]...) + m.Certificate = append(m.Certificate[:0], dAtA[iNdEx:postIndex]...) if m.Certificate == nil { m.Certificate = []byte{} } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1171,8 +1449,87 @@ func (m *CertificateSigningRequestStatus) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func (m *ExtraValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ExtraValue: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ExtraValue: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + *m = append(*m, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -1183,7 +1540,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1201,7 +1558,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -1218,7 +1575,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1241,7 +1598,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1252,7 +1609,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1276,50 +1633,62 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 692 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xac, 0x54, 0xcd, 0x6e, 0xd3, 0x4a, - 0x14, 0x8e, 0x93, 0x34, 0x4d, 0x26, 0xbd, 0xed, 0xd5, 0xe8, 0xea, 0x2a, 0x37, 0x52, 0x9d, 0x2a, - 0xba, 0xa0, 0x00, 0xed, 0x98, 0x54, 0x42, 0xea, 0x12, 0xb9, 0x48, 0xa8, 0xa2, 0x55, 0xc5, 0xb4, - 0x95, 0x10, 0x12, 0x8b, 0x89, 0x73, 0xea, 0x0e, 0x69, 0x6c, 0xd7, 0x33, 0x8e, 0xd4, 0x1d, 0x4b, - 0x96, 0x3c, 0x01, 0xaf, 0xc1, 0x2b, 0x74, 0xd9, 0x25, 0xab, 0x40, 0xd3, 0x17, 0x60, 0xcd, 0x0a, - 0x79, 0x32, 0x4e, 0x4c, 0x52, 0x17, 0x90, 0xba, 0xcb, 0xf9, 0xe6, 0x9c, 0xef, 0x3b, 0x3f, 0x9f, - 0x83, 0x9e, 0xf6, 0xb6, 0x04, 0xe1, 0xbe, 0xd5, 0x8b, 0x3a, 0x10, 0x7a, 0x20, 0x41, 0x58, 0x41, - 0xcf, 0xb5, 0x58, 0xc0, 0x85, 0xe5, 0x40, 0x28, 0xf9, 0x31, 0x77, 0x58, 0x8c, 0x0e, 0xda, 0xec, - 0x34, 0x38, 0x61, 0x6d, 0xcb, 0x05, 0x0f, 0x42, 0x26, 0xa1, 0x4b, 0x82, 0xd0, 0x97, 0x3e, 0x7e, - 0x3c, 0x66, 0x20, 0x53, 0x06, 0x12, 0xf4, 0x5c, 0x12, 0x33, 0x90, 0x34, 0x03, 0x49, 0x18, 0xea, - 0x1b, 0x2e, 0x97, 0x27, 0x51, 0x87, 0x38, 0x7e, 0xdf, 0x72, 0x7d, 0xd7, 0xb7, 0x14, 0x51, 0x27, - 0x3a, 0x56, 0x91, 0x0a, 0xd4, 0xaf, 0xb1, 0x40, 0x7d, 0x33, 0xb3, 0x45, 0x2b, 0x04, 0xe1, 0x47, - 0xa1, 0x03, 0xb3, 0x4d, 0xd5, 0x9f, 0x64, 0xd7, 0x44, 0xde, 0x00, 0x42, 0xc1, 0x7d, 0x0f, 0xba, - 0x73, 0x65, 0xeb, 0xd9, 0x65, 0x83, 0xb9, 0xc9, 0xeb, 0x1b, 0x37, 0x67, 0x87, 0x91, 0x27, 0x79, - 0x7f, 0xbe, 0xa7, 0xf6, 0xcd, 0xe9, 0x91, 0xe4, 0xa7, 0x16, 0xf7, 0xa4, 0x90, 0xe1, 0x6c, 0x49, - 0xf3, 0x3a, 0x8f, 0xfe, 0xdb, 0x9e, 0xee, 0xf0, 0x80, 0xbb, 0x1e, 0xf7, 0x5c, 0x0a, 0x67, 0x11, - 0x08, 0x89, 0x5f, 0xa1, 0x72, 0x1f, 0x24, 0xeb, 0x32, 0xc9, 0x6a, 0xc6, 0x9a, 0xd1, 0xaa, 0x6e, - 0xb6, 0x48, 0xe6, 0x31, 0xc8, 0xa0, 0x4d, 0xf6, 0x3b, 0x6f, 0xc1, 0x91, 0x7b, 0x20, 0x99, 0x8d, - 0x2f, 0x86, 0x8d, 0xdc, 0x68, 0xd8, 0x40, 0x53, 0x8c, 0x4e, 0xd8, 0xf0, 0x19, 0x2a, 0x8a, 0x00, - 0x9c, 0x5a, 0x5e, 0xb1, 0xee, 0x93, 0x3f, 0x3d, 0x31, 0xc9, 0x6c, 0xfa, 0x20, 0x00, 0xc7, 0x5e, - 0xd2, 0xe2, 0xc5, 0x38, 0xa2, 0x4a, 0x0a, 0x9f, 0xa3, 0x92, 0x90, 0x4c, 0x46, 0xa2, 0x56, 0x50, - 0xa2, 0x2f, 0xef, 0x52, 0x54, 0x11, 0xdb, 0xcb, 0x5a, 0xb6, 0x34, 0x8e, 0xa9, 0x16, 0x6c, 0x7e, - 0xcc, 0xa3, 0x66, 0x66, 0xed, 0xb6, 0xef, 0x75, 0xb9, 0xe4, 0xbe, 0x87, 0xb7, 0x50, 0x51, 0x9e, - 0x07, 0xa0, 0x56, 0x5d, 0xb1, 0xff, 0x4f, 0x66, 0x38, 0x3c, 0x0f, 0xe0, 0xfb, 0xb0, 0xf1, 0xcf, - 0x6c, 0x7e, 0x8c, 0x53, 0x55, 0x81, 0xef, 0xa3, 0x52, 0x08, 0x4c, 0xf8, 0x9e, 0x5a, 0x68, 0x65, - 0xda, 0x08, 0x55, 0x28, 0xd5, 0xaf, 0xf8, 0x01, 0x5a, 0xec, 0x83, 0x10, 0xcc, 0x05, 0xb5, 0x84, - 0x8a, 0xbd, 0xa2, 0x13, 0x17, 0xf7, 0xc6, 0x30, 0x4d, 0xde, 0x71, 0x0f, 0x2d, 0x9f, 0x32, 0x21, - 0x8f, 0x82, 0x2e, 0x93, 0x70, 0xc8, 0xfb, 0x50, 0x2b, 0xaa, 0xb5, 0x3d, 0xba, 0xc5, 0x01, 0x29, - 0xe7, 0x93, 0xb8, 0xc4, 0xfe, 0x57, 0xd3, 0x2f, 0xef, 0xfe, 0x44, 0x45, 0x67, 0xa8, 0x9b, 0xdf, - 0x0c, 0xb4, 0x9a, 0xb9, 0xa0, 0x5d, 0x2e, 0x24, 0x7e, 0x33, 0x67, 0x45, 0xeb, 0x37, 0x1b, 0x89, - 0xcb, 0x95, 0x23, 0xff, 0xd6, 0xcd, 0x94, 0x13, 0x24, 0xe5, 0xc7, 0x00, 0x2d, 0x70, 0x09, 0x7d, - 0x51, 0xcb, 0xaf, 0x15, 0x5a, 0xd5, 0xcd, 0x17, 0x77, 0xe8, 0x0d, 0xfb, 0x2f, 0xad, 0xbb, 0xb0, - 0x13, 0x2b, 0xd0, 0xb1, 0x50, 0xf3, 0xd3, 0x6d, 0x23, 0xc7, 0xb6, 0xc5, 0xf7, 0xd0, 0x62, 0x38, - 0x0e, 0xd5, 0xc4, 0x4b, 0x76, 0x35, 0x3e, 0x94, 0xce, 0xa0, 0xc9, 0x1b, 0x5e, 0x47, 0xe5, 0x48, - 0x40, 0xe8, 0xb1, 0x3e, 0xe8, 0xeb, 0x4f, 0x06, 0x3d, 0xd2, 0x38, 0x9d, 0x64, 0xe0, 0x55, 0x54, - 0x88, 0x78, 0x57, 0x5f, 0xbf, 0xaa, 0x13, 0x0b, 0x47, 0x3b, 0xcf, 0x68, 0x8c, 0xe3, 0x26, 0x2a, - 0xb9, 0xa1, 0x1f, 0x05, 0xa2, 0x56, 0x5c, 0x2b, 0xb4, 0x2a, 0x36, 0x8a, 0x4d, 0xf4, 0x5c, 0x21, - 0x54, 0xbf, 0x34, 0xbf, 0x18, 0xa8, 0xf1, 0x8b, 0x2f, 0x01, 0xbf, 0x37, 0x10, 0x72, 0x12, 0xa3, - 0x8a, 0x9a, 0xa1, 0xb6, 0x7a, 0x78, 0x87, 0x5b, 0x9d, 0x7c, 0x05, 0xd3, 0x3f, 0x9a, 0x09, 0x24, - 0x68, 0x4a, 0x1b, 0xb7, 0x51, 0x35, 0xc5, 0xad, 0x56, 0xb4, 0x64, 0xaf, 0x8c, 0x86, 0x8d, 0x6a, - 0x8a, 0x9c, 0xa6, 0x73, 0xec, 0x87, 0x17, 0x57, 0x66, 0xee, 0xf2, 0xca, 0xcc, 0x7d, 0xbe, 0x32, - 0x73, 0xef, 0x46, 0xa6, 0x71, 0x31, 0x32, 0x8d, 0xcb, 0x91, 0x69, 0x7c, 0x1d, 0x99, 0xc6, 0x87, - 0x6b, 0x33, 0xf7, 0xba, 0x9c, 0x74, 0xf8, 0x23, 0x00, 0x00, 0xff, 0xff, 0x29, 0x0b, 0xef, 0x6d, - 0xe0, 0x06, 0x00, 0x00, + // 820 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x8f, 0xdb, 0x44, + 0x14, 0x8e, 0xf3, 0x6b, 0x93, 0xc9, 0xb2, 0xad, 0x46, 0xa8, 0x32, 0x2b, 0xd5, 0x8e, 0x2c, 0x40, + 0x0b, 0xa2, 0x36, 0x59, 0x10, 0xac, 0xca, 0x01, 0xc9, 0xa5, 0x42, 0x85, 0x96, 0x1f, 0xb3, 0x0d, + 0x12, 0x88, 0x03, 0x13, 0xe7, 0xd5, 0x3b, 0xcd, 0xfa, 0x07, 0x9e, 0x71, 0xd4, 0x5c, 0x50, 0x6f, + 0x5c, 0x39, 0x72, 0x41, 0xe2, 0xcf, 0xd9, 0x63, 0x8f, 0x3d, 0xa0, 0x88, 0x35, 0x27, 0x2e, 0xfc, + 0x01, 0x3d, 0xa1, 0x19, 0x4f, 0xe2, 0x90, 0x28, 0xb4, 0x95, 0x72, 0x9b, 0xf9, 0xe6, 0xbd, 0xef, + 0x7b, 0xef, 0x9b, 0x37, 0x83, 0x3e, 0x9e, 0x9c, 0x70, 0x97, 0x25, 0xde, 0x24, 0x1f, 0x41, 0x16, + 0x83, 0x00, 0xee, 0xa5, 0x93, 0xd0, 0xa3, 0x29, 0xe3, 0x5e, 0x00, 0x99, 0x60, 0x0f, 0x58, 0x40, + 0x25, 0x3a, 0x1d, 0x8c, 0x40, 0xd0, 0x81, 0x17, 0x42, 0x0c, 0x19, 0x15, 0x30, 0x76, 0xd3, 0x2c, + 0x11, 0x09, 0xf6, 0x4a, 0x02, 0xb7, 0x22, 0x70, 0xd3, 0x49, 0xe8, 0x4a, 0x02, 0x77, 0x95, 0xc0, + 0xd5, 0x04, 0x87, 0x37, 0x42, 0x26, 0xce, 0xf2, 0x91, 0x1b, 0x24, 0x91, 0x17, 0x26, 0x61, 0xe2, + 0x29, 0x9e, 0x51, 0xfe, 0x40, 0xed, 0xd4, 0x46, 0xad, 0x4a, 0xfe, 0xc3, 0xf7, 0x75, 0x81, 0x34, + 0x65, 0x11, 0x0d, 0xce, 0x58, 0x0c, 0xd9, 0xac, 0x2a, 0x31, 0x02, 0x41, 0xbd, 0xe9, 0x46, 0x55, + 0x87, 0xde, 0xb6, 0xac, 0x2c, 0x8f, 0x05, 0x8b, 0x60, 0x23, 0xe1, 0x83, 0xe7, 0x25, 0xf0, 0xe0, + 0x0c, 0x22, 0xba, 0x91, 0xf7, 0xde, 0xb6, 0xbc, 0x5c, 0xb0, 0x73, 0x8f, 0xc5, 0x82, 0x8b, 0x6c, + 0x3d, 0xc9, 0xf9, 0xbb, 0x8e, 0x5e, 0xbb, 0x55, 0x79, 0x73, 0xca, 0xc2, 0x98, 0xc5, 0x21, 0x81, + 0x1f, 0x73, 0xe0, 0x02, 0xff, 0x80, 0x3a, 0xb2, 0xad, 0x31, 0x15, 0xd4, 0x34, 0xfa, 0xc6, 0x51, + 0xef, 0xf8, 0x5d, 0x57, 0x9b, 0xbc, 0xaa, 0x52, 0xd9, 0x2c, 0xa3, 0xdd, 0xe9, 0xc0, 0xfd, 0x72, + 0xf4, 0x10, 0x02, 0x71, 0x0f, 0x04, 0xf5, 0xf1, 0xc5, 0xdc, 0xae, 0x15, 0x73, 0x1b, 0x55, 0x18, + 0x59, 0xb2, 0xe2, 0x14, 0x35, 0x79, 0x0a, 0x81, 0x59, 0x57, 0xec, 0x5f, 0xb8, 0x2f, 0x79, 0x85, + 0xee, 0xd6, 0xda, 0x4f, 0x53, 0x08, 0xfc, 0x7d, 0xad, 0xdd, 0x94, 0x3b, 0xa2, 0x94, 0xf0, 0x23, + 0xd4, 0xe6, 0x82, 0x8a, 0x9c, 0x9b, 0x0d, 0xa5, 0xf9, 0xd5, 0x0e, 0x35, 0x15, 0xaf, 0x7f, 0xa0, + 0x55, 0xdb, 0xe5, 0x9e, 0x68, 0x3d, 0xe7, 0xb7, 0x3a, 0x72, 0xb6, 0xe6, 0xde, 0x4a, 0xe2, 0x31, + 0x13, 0x2c, 0x89, 0xf1, 0x09, 0x6a, 0x8a, 0x59, 0x0a, 0xca, 0xf0, 0xae, 0xff, 0xfa, 0xa2, 0x85, + 0xfb, 0xb3, 0x14, 0x9e, 0xcd, 0xed, 0x57, 0xd7, 0xe3, 0x25, 0x4e, 0x54, 0x06, 0x7e, 0x13, 0xb5, + 0x33, 0xa0, 0x3c, 0x89, 0x95, 0x9d, 0xdd, 0xaa, 0x10, 0xa2, 0x50, 0xa2, 0x4f, 0xf1, 0x5b, 0x68, + 0x2f, 0x02, 0xce, 0x69, 0x08, 0xca, 0x83, 0xae, 0x7f, 0x45, 0x07, 0xee, 0xdd, 0x2b, 0x61, 0xb2, + 0x38, 0xc7, 0x0f, 0xd1, 0xc1, 0x39, 0xe5, 0x62, 0x98, 0x8e, 0xa9, 0x80, 0xfb, 0x2c, 0x02, 0xb3, + 0xa9, 0x5c, 0x7b, 0xfb, 0xc5, 0xe6, 0x40, 0x66, 0xf8, 0xd7, 0x34, 0xfb, 0xc1, 0xdd, 0xff, 0x30, + 0x91, 0x35, 0x66, 0xe7, 0x1f, 0x03, 0x5d, 0xdf, 0xea, 0xcf, 0x5d, 0xc6, 0x05, 0xfe, 0x7e, 0x63, + 0x1e, 0xdd, 0x17, 0xab, 0x43, 0x66, 0xab, 0x69, 0xbc, 0xaa, 0x6b, 0xe9, 0x2c, 0x90, 0x95, 0x59, + 0x4c, 0x50, 0x8b, 0x09, 0x88, 0xb8, 0x59, 0xef, 0x37, 0x8e, 0x7a, 0xc7, 0x9f, 0xed, 0x6e, 0x30, + 0xfc, 0x57, 0xb4, 0x6c, 0xeb, 0x8e, 0x14, 0x20, 0xa5, 0x8e, 0x53, 0x34, 0xfe, 0xa7, 0x61, 0x39, + 0xb2, 0xf8, 0x0d, 0xb4, 0x97, 0x95, 0x5b, 0xd5, 0xef, 0xbe, 0xdf, 0x93, 0xb7, 0xa4, 0x23, 0xc8, + 0xe2, 0x0c, 0xbf, 0x83, 0x3a, 0x39, 0x87, 0x2c, 0xa6, 0x11, 0xe8, 0xab, 0x5f, 0xf6, 0x39, 0xd4, + 0x38, 0x59, 0x46, 0xe0, 0xeb, 0xa8, 0x91, 0xb3, 0xb1, 0xbe, 0xfa, 0x9e, 0x0e, 0x6c, 0x0c, 0xef, + 0x7c, 0x42, 0x24, 0x8e, 0x1d, 0xd4, 0x0e, 0xb3, 0x24, 0x4f, 0xb9, 0xd9, 0xec, 0x37, 0x8e, 0xba, + 0x3e, 0x92, 0x13, 0xf4, 0xa9, 0x42, 0x88, 0x3e, 0xc1, 0xc7, 0xa8, 0x33, 0x81, 0xd9, 0x50, 0x8d, + 0x50, 0x4b, 0x45, 0x5d, 0x93, 0x51, 0x0a, 0xe0, 0xcf, 0xe6, 0x76, 0xe7, 0x73, 0x7d, 0x4a, 0x96, + 0x71, 0xf8, 0x27, 0xd4, 0x82, 0x47, 0x22, 0xa3, 0x66, 0x5b, 0xd9, 0xfb, 0xed, 0x6e, 0xdf, 0xba, + 0x7b, 0x5b, 0x72, 0xdf, 0x8e, 0x45, 0x36, 0xab, 0xdc, 0x56, 0x18, 0x29, 0x65, 0x0f, 0x73, 0x84, + 0xaa, 0x18, 0x7c, 0x15, 0x35, 0x26, 0x30, 0x2b, 0x1f, 0x19, 0x91, 0x4b, 0xfc, 0x35, 0x6a, 0x4d, + 0xe9, 0x79, 0x0e, 0xfa, 0x2f, 0xfa, 0xe8, 0xa5, 0xeb, 0x53, 0xec, 0xdf, 0x48, 0x0a, 0x52, 0x32, + 0xdd, 0xac, 0x9f, 0x18, 0xce, 0xdc, 0x40, 0xf6, 0x73, 0x7e, 0x0c, 0xfc, 0xb3, 0x81, 0x50, 0xb0, + 0x78, 0xd0, 0xdc, 0x34, 0x94, 0x41, 0xa7, 0xbb, 0x33, 0x68, 0xf9, 0x59, 0x54, 0xbf, 0xf1, 0x12, + 0xe2, 0x64, 0x45, 0x1a, 0x0f, 0x50, 0x6f, 0x85, 0x5a, 0x59, 0xb1, 0xef, 0x5f, 0x29, 0xe6, 0x76, + 0x6f, 0x85, 0x9c, 0xac, 0xc6, 0x38, 0x1f, 0x6a, 0x5f, 0x55, 0xe7, 0xd8, 0x5e, 0x3c, 0x22, 0x43, + 0x8d, 0x45, 0x77, 0x7d, 0xe8, 0x6f, 0x76, 0x7e, 0xfd, 0xdd, 0xae, 0x3d, 0xfe, 0xa3, 0x5f, 0xf3, + 0x6f, 0x5c, 0x5c, 0x5a, 0xb5, 0x27, 0x97, 0x56, 0xed, 0xe9, 0xa5, 0x55, 0x7b, 0x5c, 0x58, 0xc6, + 0x45, 0x61, 0x19, 0x4f, 0x0a, 0xcb, 0x78, 0x5a, 0x58, 0xc6, 0x9f, 0x85, 0x65, 0xfc, 0xf2, 0x97, + 0x55, 0xfb, 0x6e, 0x4f, 0x77, 0xf7, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xe1, 0xa1, 0xbb, 0xcc, + 0x20, 0x08, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto similarity index 58% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/generated.proto rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto index 5c576a2e29..e62bd5724d 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,21 +19,20 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.certificates.v1alpha1; +package k8s.io.client_go.pkg.apis.certificates.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; -import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". -option go_package = "v1alpha1"; +option go_package = "v1beta1"; // Describes a certificate signing request message CertificateSigningRequest { // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // The certificate request itself and any additional information. // +optional @@ -58,33 +57,48 @@ message CertificateSigningRequestCondition { // timestamp for the last update to this condition // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastUpdateTime = 4; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastUpdateTime = 4; } message CertificateSigningRequestList { // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; repeated CertificateSigningRequest items = 2; } // This information is immutable after the request is created. Only the Request -// and ExtraInfo fields can be set on creation, other fields are derived by +// and Usages fields can be set on creation, other fields are derived by // Kubernetes and cannot be modified by users. message CertificateSigningRequestSpec { // Base64-encoded PKCS#10 CSR data optional bytes request = 1; - // Information about the requesting user (if relevant) - // See user.Info interface for details + // allowedUsages specifies a set of usage contexts the key will be + // valid for. + // See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 + // https://tools.ietf.org/html/rfc5280#section-4.2.1.12 + repeated string keyUsage = 5; + + // Information about the requesting user. + // See user.Info interface for details. // +optional optional string username = 2; + // UID information about the requesting user. + // See user.Info interface for details. // +optional optional string uid = 3; + // Group information about the requesting user. + // See user.Info interface for details. // +optional repeated string groups = 4; + + // Extra information about the requesting user. + // See user.Info interface for details. + // +optional + map extra = 6; } message CertificateSigningRequestStatus { @@ -97,3 +111,12 @@ message CertificateSigningRequestStatus { optional bytes certificate = 2; } +// ExtraValue masks the value so protobuf can generate +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +message ExtraValue { + // items, if empty, will result in an empty slice + + repeated string items = 1; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/helpers.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/helpers.go new file mode 100644 index 0000000000..1375063c10 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/helpers.go @@ -0,0 +1,38 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + "crypto/x509" + "encoding/pem" + "errors" +) + +// ParseCSR extracts the CSR from the API object and decodes it. +func ParseCSR(obj *CertificateSigningRequest) (*x509.CertificateRequest, error) { + // extract PEM from request object + pemBytes := obj.Spec.Request + block, _ := pem.Decode(pemBytes) + if block == nil || block.Type != "CERTIFICATE REQUEST" { + return nil, errors.New("PEM block type must be CERTIFICATE REQUEST") + } + csr, err := x509.ParseCertificateRequest(block.Bytes) + if err != nil { + return nil, err + } + return csr, nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/register.go similarity index 55% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/register.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/register.go index 5cf65b9654..582916c8b6 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/register.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,50 +14,53 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "certificates.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1alpha1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addConversionFuncs, addDefaultingFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &CertificateSigningRequest{}, &CertificateSigningRequestList{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, ) // Add the watch version that applies - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } - -func (obj *CertificateSigningRequest) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } -func (obj *CertificateSigningRequestList) GetObjectKind() unversioned.ObjectKind { return &obj.TypeMeta } diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.generated.go new file mode 100644 index 0000000000..3c4771bbd4 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.generated.go @@ -0,0 +1,2624 @@ +/* +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 v1beta1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + "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 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 + } +} + +func (x *CertificateSigningRequest) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *CertificateSigningRequest) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *CertificateSigningRequest) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = CertificateSigningRequestSpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + case "status": + if r.TryDecodeAsNil() { + x.Status = CertificateSigningRequestStatus{} + } else { + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *CertificateSigningRequest) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = CertificateSigningRequestSpec{} + } else { + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Status = CertificateSigningRequestStatus{} + } else { + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *CertificateSigningRequestSpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Usages) != 0 + yyq2[2] = x.Username != "" + yyq2[3] = x.UID != "" + yyq2[4] = len(x.Groups) != 0 + yyq2[5] = len(x.Extra) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Request == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Request)) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("request")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Request == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Request)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Usages == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceKeyUsage(([]KeyUsage)(x.Usages), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("usages")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Usages == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceKeyUsage(([]KeyUsage)(x.Usages), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Username)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("username")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Username)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.UID)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("uid")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.UID)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.Groups == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("groups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Groups == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + z.F.EncSliceStringV(x.Groups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + if x.Extra == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("extra")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Extra == nil { + r.EncodeNil() + } else { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + h.encMapstringExtraValue((map[string]ExtraValue)(x.Extra), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *CertificateSigningRequestSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *CertificateSigningRequestSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "request": + if r.TryDecodeAsNil() { + x.Request = nil + } else { + yyv4 := &x.Request + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *yyv4 = r.DecodeBytes(*(*[]byte)(yyv4), false, false) + } + } + case "usages": + if r.TryDecodeAsNil() { + x.Usages = nil + } else { + yyv6 := &x.Usages + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceKeyUsage((*[]KeyUsage)(yyv6), d) + } + } + case "username": + if r.TryDecodeAsNil() { + x.Username = "" + } else { + yyv8 := &x.Username + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "uid": + if r.TryDecodeAsNil() { + x.UID = "" + } else { + yyv10 := &x.UID + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "groups": + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv12 := &x.Groups + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + z.F.DecSliceStringX(yyv12, false, d) + } + } + case "extra": + if r.TryDecodeAsNil() { + x.Extra = nil + } else { + yyv14 := &x.Extra + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv14), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *CertificateSigningRequestSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Request = nil + } else { + yyv17 := &x.Request + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *yyv17 = r.DecodeBytes(*(*[]byte)(yyv17), false, false) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Usages = nil + } else { + yyv19 := &x.Usages + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceKeyUsage((*[]KeyUsage)(yyv19), d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Username = "" + } else { + yyv21 := &x.Username + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.UID = "" + } else { + yyv23 := &x.UID + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Groups = nil + } else { + yyv25 := &x.Groups + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + z.F.DecSliceStringX(yyv25, false, d) + } + } + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Extra = nil + } else { + yyv27 := &x.Extra + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + h.decMapstringExtraValue((*map[string]ExtraValue)(yyv27), d) + } + } + for { + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l + } else { + yyb16 = r.CheckBreak() + } + if yyb16 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj16-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x ExtraValue) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + h.encExtraValue((ExtraValue)(x), e) + } + } +} + +func (x *ExtraValue) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + h.decExtraValue((*ExtraValue)(x), d) + } +} + +func (x *CertificateSigningRequestStatus) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Conditions) != 0 + yyq2[1] = len(x.Certificate) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Conditions == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceCertificateSigningRequestCondition(([]CertificateSigningRequestCondition)(x.Conditions), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("conditions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Conditions == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceCertificateSigningRequestCondition(([]CertificateSigningRequestCondition)(x.Conditions), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Certificate == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Certificate)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("certificate")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Certificate == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Certificate)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *CertificateSigningRequestStatus) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *CertificateSigningRequestStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "conditions": + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv4 := &x.Conditions + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceCertificateSigningRequestCondition((*[]CertificateSigningRequestCondition)(yyv4), d) + } + } + case "certificate": + if r.TryDecodeAsNil() { + x.Certificate = nil + } else { + yyv6 := &x.Certificate + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *yyv6 = r.DecodeBytes(*(*[]byte)(yyv6), false, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *CertificateSigningRequestStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv9 := &x.Conditions + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSliceCertificateSigningRequestCondition((*[]CertificateSigningRequestCondition)(yyv9), d) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Certificate = nil + } else { + yyv11 := &x.Certificate + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *yyv11 = r.DecodeBytes(*(*[]byte)(yyv11), false, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x RequestConditionType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *RequestConditionType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *CertificateSigningRequestCondition) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.Reason != "" + yyq2[2] = x.Message != "" + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("reason")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("message")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy13 := &x.LastUpdateTime + yym14 := z.EncBinary() + _ = yym14 + if false { + } else if z.HasExtensions() && z.EncExt(yy13) { + } else if yym14 { + z.EncBinaryMarshal(yy13) + } else if !yym14 && z.IsJSONHandle() { + z.EncJSONMarshal(yy13) + } else { + z.EncFallback(yy13) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy15 := &x.LastUpdateTime + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) + } else { + z.EncFallback(yy15) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *CertificateSigningRequestCondition) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *CertificateSigningRequestCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "reason": + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv5 := &x.Reason + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + case "message": + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv7 := &x.Message + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*string)(yyv7)) = r.DecodeString() + } + } + case "lastUpdateTime": + if r.TryDecodeAsNil() { + x.LastUpdateTime = pkg1_v1.Time{} + } else { + yyv9 := &x.LastUpdateTime + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else if yym10 { + z.DecBinaryUnmarshal(yyv9) + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv9) + } else { + z.DecFallback(yyv9, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *CertificateSigningRequestCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv12 := &x.Type + yyv12.CodecDecodeSelf(d) + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Reason = "" + } else { + yyv13 := &x.Reason + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Message = "" + } else { + yyv15 := &x.Message + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.LastUpdateTime = pkg1_v1.Time{} + } else { + yyv17 := &x.LastUpdateTime + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) + } else { + z.DecFallback(yyv17, false) + } + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *CertificateSigningRequestList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceCertificateSigningRequest(([]CertificateSigningRequest)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceCertificateSigningRequest(([]CertificateSigningRequest)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *CertificateSigningRequestList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *CertificateSigningRequestList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceCertificateSigningRequest((*[]CertificateSigningRequest)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *CertificateSigningRequestList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceCertificateSigningRequest((*[]CertificateSigningRequest)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x KeyUsage) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *KeyUsage) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x codecSelfer1234) encSliceKeyUsage(v []KeyUsage, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yyv1.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceKeyUsage(v *[]KeyUsage, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []KeyUsage{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]KeyUsage, yyrl1) + } + } else { + yyv1 = make([]KeyUsage, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 KeyUsage + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []KeyUsage{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encMapstringExtraValue(v map[string]ExtraValue, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeMapStart(len(v)) + for yyk1, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yyk1)) + } + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if yyv1 == nil { + r.EncodeNil() + } else { + yyv1.CodecEncodeSelf(e) + } + } + z.EncSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x codecSelfer1234) decMapstringExtraValue(v *map[string]ExtraValue, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string]ExtraValue, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 ExtraValue + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey1234) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue1234) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv4 := &yymv1 + yyv4.CodecDecodeSelf(d) + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { + z.DecSendContainerState(codecSelfer_containerMapKey1234) + if r.TryDecodeAsNil() { + yymk1 = "" + } else { + yyv5 := &yymk1 + yym6 := z.DecBinary() + _ = yym6 + if false { + } else { + *((*string)(yyv5)) = r.DecodeString() + } + } + + if yymg1 { + yymv1 = yyv1[yymk1] + } else { + yymv1 = nil + } + z.DecSendContainerState(codecSelfer_containerMapValue1234) + if r.TryDecodeAsNil() { + yymv1 = nil + } else { + yyv7 := &yymv1 + yyv7.CodecDecodeSelf(d) + } + + if yyv1 != nil { + yyv1[yymk1] = yymv1 + } + } + } // else len==0: TODO: Should we clear map entries? + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x codecSelfer1234) encExtraValue(v ExtraValue, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym2 := z.EncBinary() + _ = yym2 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(yyv1)) + } + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decExtraValue(v *ExtraValue, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]string, yyrl1) + } + } else { + yyv1 = make([]string, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv2 := &yyv1[yyj1] + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv4 := &yyv1[yyj1] + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 string + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = "" + } else { + yyv6 := &yyv1[yyj1] + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []string{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceCertificateSigningRequestCondition(v []CertificateSigningRequestCondition, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceCertificateSigningRequestCondition(v *[]CertificateSigningRequestCondition, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []CertificateSigningRequestCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]CertificateSigningRequestCondition, yyrl1) + } + } else { + yyv1 = make([]CertificateSigningRequestCondition, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = CertificateSigningRequestCondition{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, CertificateSigningRequestCondition{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = CertificateSigningRequestCondition{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, CertificateSigningRequestCondition{}) // var yyz1 CertificateSigningRequestCondition + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = CertificateSigningRequestCondition{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []CertificateSigningRequestCondition{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceCertificateSigningRequest(v []CertificateSigningRequest, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceCertificateSigningRequest(v *[]CertificateSigningRequest, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []CertificateSigningRequest{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 424) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]CertificateSigningRequest, yyrl1) + } + } else { + yyv1 = make([]CertificateSigningRequest, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = CertificateSigningRequest{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, CertificateSigningRequest{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = CertificateSigningRequest{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, CertificateSigningRequest{}) // var yyz1 CertificateSigningRequest + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = CertificateSigningRequest{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []CertificateSigningRequest{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.go similarity index 51% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.go index fb1a4d3415..a9149ba8df 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types.go @@ -14,11 +14,12 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" + "fmt" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // +genclient=true @@ -26,9 +27,9 @@ import ( // Describes a certificate signing request type CertificateSigningRequest struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // The certificate request itself and any additional information. // +optional @@ -40,20 +41,43 @@ type CertificateSigningRequest struct { } // This information is immutable after the request is created. Only the Request -// and ExtraInfo fields can be set on creation, other fields are derived by +// and Usages fields can be set on creation, other fields are derived by // Kubernetes and cannot be modified by users. type CertificateSigningRequestSpec struct { // Base64-encoded PKCS#10 CSR data Request []byte `json:"request" protobuf:"bytes,1,opt,name=request"` - // Information about the requesting user (if relevant) - // See user.Info interface for details + // allowedUsages specifies a set of usage contexts the key will be + // valid for. + // See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 + // https://tools.ietf.org/html/rfc5280#section-4.2.1.12 + Usages []KeyUsage `json:"usages,omitempty" protobuf:"bytes,5,opt,name=keyUsage"` + + // Information about the requesting user. + // See user.Info interface for details. // +optional Username string `json:"username,omitempty" protobuf:"bytes,2,opt,name=username"` + // UID information about the requesting user. + // See user.Info interface for details. // +optional UID string `json:"uid,omitempty" protobuf:"bytes,3,opt,name=uid"` + // Group information about the requesting user. + // See user.Info interface for details. // +optional Groups []string `json:"groups,omitempty" protobuf:"bytes,4,rep,name=groups"` + // Extra information about the requesting user. + // See user.Info interface for details. + // +optional + Extra map[string]ExtraValue `json:"extra,omitempty" protobuf:"bytes,6,rep,name=extra"` +} + +// ExtraValue masks the value so protobuf can generate +// +protobuf.nullable=true +// +protobuf.options.(gogoproto.goproto_stringer)=false +type ExtraValue []string + +func (t ExtraValue) String() string { + return fmt.Sprintf("%v", []string(t)) } type CertificateSigningRequestStatus struct { @@ -85,13 +109,44 @@ type CertificateSigningRequestCondition struct { Message string `json:"message,omitempty" protobuf:"bytes,3,opt,name=message"` // timestamp for the last update to this condition // +optional - LastUpdateTime unversioned.Time `json:"lastUpdateTime,omitempty" protobuf:"bytes,4,opt,name=lastUpdateTime"` + LastUpdateTime metav1.Time `json:"lastUpdateTime,omitempty" protobuf:"bytes,4,opt,name=lastUpdateTime"` } type CertificateSigningRequestList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` Items []CertificateSigningRequest `json:"items" protobuf:"bytes,2,rep,name=items"` } + +// KeyUsages specifies valid usage contexts for keys. +// See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3 +// https://tools.ietf.org/html/rfc5280#section-4.2.1.12 +type KeyUsage string + +const ( + UsageSigning KeyUsage = "signing" + UsageDigitalSignature KeyUsage = "digital signature" + UsageContentCommittment KeyUsage = "content committment" + UsageKeyEncipherment KeyUsage = "key encipherment" + UsageKeyAgreement KeyUsage = "key agreement" + UsageDataEncipherment KeyUsage = "data encipherment" + UsageCertSign KeyUsage = "cert sign" + UsageCRLSign KeyUsage = "crl sign" + UsageEncipherOnly KeyUsage = "encipher only" + UsageDecipherOnly KeyUsage = "decipher only" + UsageAny KeyUsage = "any" + UsageServerAuth KeyUsage = "server auth" + UsageClientAuth KeyUsage = "client auth" + UsageCodeSigning KeyUsage = "code signing" + UsageEmailProtection KeyUsage = "email protection" + UsageSMIME KeyUsage = "s/mime" + UsageIPsecEndSystem KeyUsage = "ipsec end system" + UsageIPsecTunnel KeyUsage = "ipsec tunnel" + UsageIPsecUser KeyUsage = "ipsec user" + UsageTimestamping KeyUsage = "timestamping" + UsageOCSPSigning KeyUsage = "ocsp signing" + UsageMicrosoftSGC KeyUsage = "microsoft sgc" + UsageNetscapSGC KeyUsage = "netscape sgc" +) diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types_swagger_doc_generated.go similarity index 78% rename from vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types_swagger_doc_generated.go rename to vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types_swagger_doc_generated.go index cf66d07467..4fd91df061 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/v1alpha1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/types_swagger_doc_generated.go @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package v1beta1 // This file contains a collection of methods that can be used from go-restful to // generate Swagger API documentation for its models. Please read this PR for more @@ -49,9 +49,13 @@ func (CertificateSigningRequestCondition) SwaggerDoc() map[string]string { } var map_CertificateSigningRequestSpec = map[string]string{ - "": "This information is immutable after the request is created. Only the Request and ExtraInfo fields can be set on creation, other fields are derived by Kubernetes and cannot be modified by users.", + "": "This information is immutable after the request is created. Only the Request and Usages fields can be set on creation, other fields are derived by Kubernetes and cannot be modified by users.", "request": "Base64-encoded PKCS#10 CSR data", - "username": "Information about the requesting user (if relevant) See user.Info interface for details", + "usages": "allowedUsages specifies a set of usage contexts the key will be valid for. See: https://tools.ietf.org/html/rfc5280#section-4.2.1.3\n https://tools.ietf.org/html/rfc5280#section-4.2.1.12", + "username": "Information about the requesting user. See user.Info interface for details.", + "uid": "UID information about the requesting user. See user.Info interface for details.", + "groups": "Group information about the requesting user. See user.Info interface for details.", + "extra": "Extra information about the requesting user. See user.Info interface for details.", } func (CertificateSigningRequestSpec) SwaggerDoc() map[string]string { diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.conversion.go new file mode 100644 index 0000000000..f133178485 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.conversion.go @@ -0,0 +1,189 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1beta1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + certificates "k8s.io/client-go/pkg/apis/certificates" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1beta1_CertificateSigningRequest_To_certificates_CertificateSigningRequest, + Convert_certificates_CertificateSigningRequest_To_v1beta1_CertificateSigningRequest, + Convert_v1beta1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition, + Convert_certificates_CertificateSigningRequestCondition_To_v1beta1_CertificateSigningRequestCondition, + Convert_v1beta1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList, + Convert_certificates_CertificateSigningRequestList_To_v1beta1_CertificateSigningRequestList, + Convert_v1beta1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec, + Convert_certificates_CertificateSigningRequestSpec_To_v1beta1_CertificateSigningRequestSpec, + Convert_v1beta1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus, + Convert_certificates_CertificateSigningRequestStatus_To_v1beta1_CertificateSigningRequestStatus, + ) +} + +func autoConvert_v1beta1_CertificateSigningRequest_To_certificates_CertificateSigningRequest(in *CertificateSigningRequest, out *certificates.CertificateSigningRequest, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1beta1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_v1beta1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_CertificateSigningRequest_To_certificates_CertificateSigningRequest is an autogenerated conversion function. +func Convert_v1beta1_CertificateSigningRequest_To_certificates_CertificateSigningRequest(in *CertificateSigningRequest, out *certificates.CertificateSigningRequest, s conversion.Scope) error { + return autoConvert_v1beta1_CertificateSigningRequest_To_certificates_CertificateSigningRequest(in, out, s) +} + +func autoConvert_certificates_CertificateSigningRequest_To_v1beta1_CertificateSigningRequest(in *certificates.CertificateSigningRequest, out *CertificateSigningRequest, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_certificates_CertificateSigningRequestSpec_To_v1beta1_CertificateSigningRequestSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + if err := Convert_certificates_CertificateSigningRequestStatus_To_v1beta1_CertificateSigningRequestStatus(&in.Status, &out.Status, s); err != nil { + return err + } + return nil +} + +// Convert_certificates_CertificateSigningRequest_To_v1beta1_CertificateSigningRequest is an autogenerated conversion function. +func Convert_certificates_CertificateSigningRequest_To_v1beta1_CertificateSigningRequest(in *certificates.CertificateSigningRequest, out *CertificateSigningRequest, s conversion.Scope) error { + return autoConvert_certificates_CertificateSigningRequest_To_v1beta1_CertificateSigningRequest(in, out, s) +} + +func autoConvert_v1beta1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition(in *CertificateSigningRequestCondition, out *certificates.CertificateSigningRequestCondition, s conversion.Scope) error { + out.Type = certificates.RequestConditionType(in.Type) + out.Reason = in.Reason + out.Message = in.Message + out.LastUpdateTime = in.LastUpdateTime + return nil +} + +// Convert_v1beta1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition is an autogenerated conversion function. +func Convert_v1beta1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition(in *CertificateSigningRequestCondition, out *certificates.CertificateSigningRequestCondition, s conversion.Scope) error { + return autoConvert_v1beta1_CertificateSigningRequestCondition_To_certificates_CertificateSigningRequestCondition(in, out, s) +} + +func autoConvert_certificates_CertificateSigningRequestCondition_To_v1beta1_CertificateSigningRequestCondition(in *certificates.CertificateSigningRequestCondition, out *CertificateSigningRequestCondition, s conversion.Scope) error { + out.Type = RequestConditionType(in.Type) + out.Reason = in.Reason + out.Message = in.Message + out.LastUpdateTime = in.LastUpdateTime + return nil +} + +// Convert_certificates_CertificateSigningRequestCondition_To_v1beta1_CertificateSigningRequestCondition is an autogenerated conversion function. +func Convert_certificates_CertificateSigningRequestCondition_To_v1beta1_CertificateSigningRequestCondition(in *certificates.CertificateSigningRequestCondition, out *CertificateSigningRequestCondition, s conversion.Scope) error { + return autoConvert_certificates_CertificateSigningRequestCondition_To_v1beta1_CertificateSigningRequestCondition(in, out, s) +} + +func autoConvert_v1beta1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList(in *CertificateSigningRequestList, out *certificates.CertificateSigningRequestList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]certificates.CertificateSigningRequest)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1beta1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList is an autogenerated conversion function. +func Convert_v1beta1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList(in *CertificateSigningRequestList, out *certificates.CertificateSigningRequestList, s conversion.Scope) error { + return autoConvert_v1beta1_CertificateSigningRequestList_To_certificates_CertificateSigningRequestList(in, out, s) +} + +func autoConvert_certificates_CertificateSigningRequestList_To_v1beta1_CertificateSigningRequestList(in *certificates.CertificateSigningRequestList, out *CertificateSigningRequestList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]CertificateSigningRequest, 0) + } else { + out.Items = *(*[]CertificateSigningRequest)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_certificates_CertificateSigningRequestList_To_v1beta1_CertificateSigningRequestList is an autogenerated conversion function. +func Convert_certificates_CertificateSigningRequestList_To_v1beta1_CertificateSigningRequestList(in *certificates.CertificateSigningRequestList, out *CertificateSigningRequestList, s conversion.Scope) error { + return autoConvert_certificates_CertificateSigningRequestList_To_v1beta1_CertificateSigningRequestList(in, out, s) +} + +func autoConvert_v1beta1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(in *CertificateSigningRequestSpec, out *certificates.CertificateSigningRequestSpec, s conversion.Scope) error { + out.Request = *(*[]byte)(unsafe.Pointer(&in.Request)) + out.Usages = *(*[]certificates.KeyUsage)(unsafe.Pointer(&in.Usages)) + out.Username = in.Username + out.UID = in.UID + out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) + out.Extra = *(*map[string]certificates.ExtraValue)(unsafe.Pointer(&in.Extra)) + return nil +} + +// Convert_v1beta1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec is an autogenerated conversion function. +func Convert_v1beta1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(in *CertificateSigningRequestSpec, out *certificates.CertificateSigningRequestSpec, s conversion.Scope) error { + return autoConvert_v1beta1_CertificateSigningRequestSpec_To_certificates_CertificateSigningRequestSpec(in, out, s) +} + +func autoConvert_certificates_CertificateSigningRequestSpec_To_v1beta1_CertificateSigningRequestSpec(in *certificates.CertificateSigningRequestSpec, out *CertificateSigningRequestSpec, s conversion.Scope) error { + if in.Request == nil { + out.Request = make([]byte, 0) + } else { + out.Request = *(*[]byte)(unsafe.Pointer(&in.Request)) + } + out.Usages = *(*[]KeyUsage)(unsafe.Pointer(&in.Usages)) + out.Username = in.Username + out.UID = in.UID + out.Groups = *(*[]string)(unsafe.Pointer(&in.Groups)) + out.Extra = *(*map[string]ExtraValue)(unsafe.Pointer(&in.Extra)) + return nil +} + +// Convert_certificates_CertificateSigningRequestSpec_To_v1beta1_CertificateSigningRequestSpec is an autogenerated conversion function. +func Convert_certificates_CertificateSigningRequestSpec_To_v1beta1_CertificateSigningRequestSpec(in *certificates.CertificateSigningRequestSpec, out *CertificateSigningRequestSpec, s conversion.Scope) error { + return autoConvert_certificates_CertificateSigningRequestSpec_To_v1beta1_CertificateSigningRequestSpec(in, out, s) +} + +func autoConvert_v1beta1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(in *CertificateSigningRequestStatus, out *certificates.CertificateSigningRequestStatus, s conversion.Scope) error { + out.Conditions = *(*[]certificates.CertificateSigningRequestCondition)(unsafe.Pointer(&in.Conditions)) + out.Certificate = *(*[]byte)(unsafe.Pointer(&in.Certificate)) + return nil +} + +// Convert_v1beta1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus is an autogenerated conversion function. +func Convert_v1beta1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(in *CertificateSigningRequestStatus, out *certificates.CertificateSigningRequestStatus, s conversion.Scope) error { + return autoConvert_v1beta1_CertificateSigningRequestStatus_To_certificates_CertificateSigningRequestStatus(in, out, s) +} + +func autoConvert_certificates_CertificateSigningRequestStatus_To_v1beta1_CertificateSigningRequestStatus(in *certificates.CertificateSigningRequestStatus, out *CertificateSigningRequestStatus, s conversion.Scope) error { + out.Conditions = *(*[]CertificateSigningRequestCondition)(unsafe.Pointer(&in.Conditions)) + out.Certificate = *(*[]byte)(unsafe.Pointer(&in.Certificate)) + return nil +} + +// Convert_certificates_CertificateSigningRequestStatus_To_v1beta1_CertificateSigningRequestStatus is an autogenerated conversion function. +func Convert_certificates_CertificateSigningRequestStatus_To_v1beta1_CertificateSigningRequestStatus(in *certificates.CertificateSigningRequestStatus, out *CertificateSigningRequestStatus, s conversion.Scope) error { + return autoConvert_certificates_CertificateSigningRequestStatus_To_v1beta1_CertificateSigningRequestStatus(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..f3f172c700 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.deepcopy.go @@ -0,0 +1,155 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CertificateSigningRequest, InType: reflect.TypeOf(&CertificateSigningRequest{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CertificateSigningRequestCondition, InType: reflect.TypeOf(&CertificateSigningRequestCondition{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CertificateSigningRequestList, InType: reflect.TypeOf(&CertificateSigningRequestList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CertificateSigningRequestSpec, InType: reflect.TypeOf(&CertificateSigningRequestSpec{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CertificateSigningRequestStatus, InType: reflect.TypeOf(&CertificateSigningRequestStatus{})}, + ) +} + +// DeepCopy_v1beta1_CertificateSigningRequest is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CertificateSigningRequest(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*CertificateSigningRequest) + out := out.(*CertificateSigningRequest) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_v1beta1_CertificateSigningRequestSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + if err := DeepCopy_v1beta1_CertificateSigningRequestStatus(&in.Status, &out.Status, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1beta1_CertificateSigningRequestCondition is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CertificateSigningRequestCondition(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*CertificateSigningRequestCondition) + out := out.(*CertificateSigningRequestCondition) + *out = *in + out.LastUpdateTime = in.LastUpdateTime.DeepCopy() + return nil + } +} + +// DeepCopy_v1beta1_CertificateSigningRequestList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CertificateSigningRequestList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*CertificateSigningRequestList) + out := out.(*CertificateSigningRequestList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]CertificateSigningRequest, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_CertificateSigningRequest(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_CertificateSigningRequestSpec is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CertificateSigningRequestSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*CertificateSigningRequestSpec) + out := out.(*CertificateSigningRequestSpec) + *out = *in + if in.Request != nil { + in, out := &in.Request, &out.Request + *out = make([]byte, len(*in)) + copy(*out, *in) + } + if in.Usages != nil { + in, out := &in.Usages, &out.Usages + *out = make([]KeyUsage, len(*in)) + copy(*out, *in) + } + if in.Groups != nil { + in, out := &in.Groups, &out.Groups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Extra != nil { + in, out := &in.Extra, &out.Extra + *out = make(map[string]ExtraValue) + for key, val := range *in { + if newVal, err := c.DeepCopy(&val); err != nil { + return err + } else { + (*out)[key] = *newVal.(*ExtraValue) + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_CertificateSigningRequestStatus is an autogenerated deepcopy function. +func DeepCopy_v1beta1_CertificateSigningRequestStatus(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*CertificateSigningRequestStatus) + out := out.(*CertificateSigningRequestStatus) + *out = *in + if in.Conditions != nil { + in, out := &in.Conditions, &out.Conditions + *out = make([]CertificateSigningRequestCondition, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_CertificateSigningRequestCondition(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Certificate != nil { + in, out := &in.Certificate, &out.Certificate + *out = make([]byte, len(*in)) + copy(*out, *in) + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.defaults.go new file mode 100644 index 0000000000..3c5ae03627 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/v1beta1/zz_generated.defaults.go @@ -0,0 +1,47 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1beta1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&CertificateSigningRequest{}, func(obj interface{}) { SetObjectDefaults_CertificateSigningRequest(obj.(*CertificateSigningRequest)) }) + scheme.AddTypeDefaultingFunc(&CertificateSigningRequestList{}, func(obj interface{}) { + SetObjectDefaults_CertificateSigningRequestList(obj.(*CertificateSigningRequestList)) + }) + return nil +} + +func SetObjectDefaults_CertificateSigningRequest(in *CertificateSigningRequest) { + SetDefaults_CertificateSigningRequestSpec(&in.Spec) +} + +func SetObjectDefaults_CertificateSigningRequestList(in *CertificateSigningRequestList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_CertificateSigningRequest(a) + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/certificates/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/certificates/zz_generated.deepcopy.go index 6b4580c01c..589e94c0e1 100644 --- a/vendor/k8s.io/client-go/pkg/apis/certificates/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/certificates/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package certificates import ( - api "k8s.io/client-go/pkg/api" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -43,13 +43,16 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_certificates_CertificateSigningRequest is an autogenerated deepcopy function. func DeepCopy_certificates_CertificateSigningRequest(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CertificateSigningRequest) out := out.(*CertificateSigningRequest) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_certificates_CertificateSigningRequestSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -61,24 +64,23 @@ func DeepCopy_certificates_CertificateSigningRequest(in interface{}, out interfa } } +// DeepCopy_certificates_CertificateSigningRequestCondition is an autogenerated deepcopy function. func DeepCopy_certificates_CertificateSigningRequestCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CertificateSigningRequestCondition) out := out.(*CertificateSigningRequestCondition) - out.Type = in.Type - out.Reason = in.Reason - out.Message = in.Message + *out = *in out.LastUpdateTime = in.LastUpdateTime.DeepCopy() return nil } } +// DeepCopy_certificates_CertificateSigningRequestList is an autogenerated deepcopy function. func DeepCopy_certificates_CertificateSigningRequestList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CertificateSigningRequestList) out := out.(*CertificateSigningRequestList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CertificateSigningRequest, len(*in)) @@ -87,41 +89,53 @@ func DeepCopy_certificates_CertificateSigningRequestList(in interface{}, out int return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_certificates_CertificateSigningRequestSpec is an autogenerated deepcopy function. func DeepCopy_certificates_CertificateSigningRequestSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CertificateSigningRequestSpec) out := out.(*CertificateSigningRequestSpec) + *out = *in if in.Request != nil { in, out := &in.Request, &out.Request *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Request = nil } - out.Username = in.Username - out.UID = in.UID + if in.Usages != nil { + in, out := &in.Usages, &out.Usages + *out = make([]KeyUsage, len(*in)) + copy(*out, *in) + } if in.Groups != nil { in, out := &in.Groups, &out.Groups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Groups = nil + } + if in.Extra != nil { + in, out := &in.Extra, &out.Extra + *out = make(map[string]ExtraValue) + for key, val := range *in { + if newVal, err := c.DeepCopy(&val); err != nil { + return err + } else { + (*out)[key] = *newVal.(*ExtraValue) + } + } } return nil } } +// DeepCopy_certificates_CertificateSigningRequestStatus is an autogenerated deepcopy function. func DeepCopy_certificates_CertificateSigningRequestStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CertificateSigningRequestStatus) out := out.(*CertificateSigningRequestStatus) + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]CertificateSigningRequestCondition, len(*in)) @@ -130,15 +144,11 @@ func DeepCopy_certificates_CertificateSigningRequestStatus(in interface{}, out i return err } } - } else { - out.Conditions = nil } if in.Certificate != nil { in, out := &in.Certificate, &out.Certificate *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Certificate = nil } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/BUILD b/vendor/k8s.io/client-go/pkg/apis/extensions/BUILD new file mode 100644 index 0000000000..95cb77d78a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/BUILD @@ -0,0 +1,29 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "helpers.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/OWNERS b/vendor/k8s.io/client-go/pkg/apis/extensions/OWNERS new file mode 100755 index 0000000000..494763a693 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/OWNERS @@ -0,0 +1,41 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- brendandburns +- derekwaynecarr +- caesarxuchao +- mikedanese +- liggitt +- nikhiljindal +- bprashanth +- erictune +- pmorie +- sttts +- kargakis +- saad-ali +- janetkuo +- justinsb +- ncdc +- timstclair +- mwielgus +- timothysc +- soltysh +- piosz +- dims +- errordeveloper +- madhusudancs +- rootfs +- jszczepkowski +- mml +- resouer +- mbohlool +- david-mcmahon +- therc +- pweil- +- tmrts +- mqliang +- lukaszo +- jianhuiz diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/doc.go b/vendor/k8s.io/client-go/pkg/apis/extensions/doc.go index 6b51a43e8b..87edee41cb 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/doc.go @@ -14,7 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - package extensions diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/install/install.go b/vendor/k8s.io/client-go/pkg/apis/extensions/install/install.go deleted file mode 100644 index f774a2b81f..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the experimental API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/extensions" - "k8s.io/client-go/pkg/apis/extensions/v1beta1" - "k8s.io/client-go/pkg/util/sets" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: extensions.GroupName, - VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/extensions", - RootScopedKinds: sets.NewString("PodSecurityPolicy", "ThirdPartyResource"), - AddInternalObjectsToScheme: extensions.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/register.go b/vendor/k8s.io/client-go/pkg/apis/extensions/register.go index 074a7f74d4..5983636c22 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/register.go @@ -17,26 +17,23 @@ limitations under the License. package extensions import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/apis/autoscaling" - "k8s.io/client-go/pkg/apis/batch" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "extensions" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -52,11 +49,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { &Deployment{}, &DeploymentList{}, &DeploymentRollback{}, - &autoscaling.HorizontalPodAutoscaler{}, - &autoscaling.HorizontalPodAutoscalerList{}, - &batch.Job{}, - &batch.JobList{}, - &batch.JobTemplate{}, &ReplicationControllerDummy{}, &Scale{}, &ThirdPartyResource{}, @@ -67,11 +59,8 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ThirdPartyResourceDataList{}, &Ingress{}, &IngressList{}, - &api.ListOptions{}, - &api.DeleteOptions{}, &ReplicaSet{}, &ReplicaSetList{}, - &api.ExportOptions{}, &PodSecurityPolicy{}, &PodSecurityPolicyList{}, &NetworkPolicy{}, diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/extensions/types.generated.go deleted file mode 100644 index 7f5ab23963..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/types.generated.go +++ /dev/null @@ -1,19454 +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 extensions - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/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 pkg2_api.ObjectMeta - var v1 pkg4_resource.Quantity - var v2 pkg1_unversioned.LabelSelector - var v3 pkg3_types.UID - var v4 pkg5_intstr.IntOrString - var v5 time.Time - _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 - } -} - -func (x *ScaleSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [1]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Replicas != 0 - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(1) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ScaleSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym6 := z.DecBinary() - _ = yym6 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct7 := r.ContainerType() - if yyct7 == codecSelferValueTypeMap1234 { - yyl7 := r.ReadMapStart() - if yyl7 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl7, d) - } - } else if yyct7 == codecSelferValueTypeArray1234 { - yyl7 := r.ReadArrayStart() - if yyl7 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl7, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys8Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys8Slc - var yyhl8 bool = l >= 0 - for yyj8 := 0; ; yyj8++ { - if yyhl8 { - if yyj8 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys8Slc = r.DecodeBytes(yys8Slc, true, true) - yys8 := string(yys8Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys8 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys8) - } // end switch yys8 - } // end for yyj8 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l - } else { - yyb10 = r.CheckBreak() - } - if yyb10 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj10-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym12 := z.EncBinary() - _ = yym12 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep13 := !z.EncBinary() - yy2arr13 := z.EncBasicHandle().StructToArray - var yyq13 [2]bool - _, _, _ = yysep13, yyq13, yy2arr13 - const yyr13 bool = false - yyq13[1] = x.Selector != nil - var yynn13 int - if yyr13 || yy2arr13 { - r.EncodeArrayStart(2) - } else { - yynn13 = 1 - for _, b := range yyq13 { - if b { - yynn13++ - } - } - r.EncodeMapStart(yynn13) - yynn13 = 0 - } - if yyr13 || yy2arr13 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym15 := z.EncBinary() - _ = yym15 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr13 || yy2arr13 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq13[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym18 := z.EncBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq13[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym19 := z.EncBinary() - _ = yym19 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr13 || yy2arr13 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ScaleStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym20 := z.DecBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct21 := r.ContainerType() - if yyct21 == codecSelferValueTypeMap1234 { - yyl21 := r.ReadMapStart() - if yyl21 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl21, d) - } - } else if yyct21 == codecSelferValueTypeArray1234 { - yyl21 := r.ReadArrayStart() - if yyl21 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl21, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys22Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys22Slc - var yyhl22 bool = l >= 0 - for yyj22 := 0; ; yyj22++ { - if yyhl22 { - if yyj22 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys22Slc = r.DecodeBytes(yys22Slc, true, true) - yys22 := string(yys22Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys22 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym25 := z.DecBinary() - _ = yym25 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys22) - } // end switch yys22 - } // end for yyj22 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj26 int - var yyb26 bool - var yyhl26 bool = l >= 0 - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - 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(pkg1_unversioned.LabelSelector) - } - yym29 := z.DecBinary() - _ = yym29 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - for { - yyj26++ - if yyhl26 { - yyb26 = yyj26 > l - } else { - yyb26 = r.CheckBreak() - } - if yyb26 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj26-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym30 := z.EncBinary() - _ = yym30 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep31 := !z.EncBinary() - yy2arr31 := z.EncBasicHandle().StructToArray - var yyq31 [5]bool - _, _, _ = yysep31, yyq31, yy2arr31 - const yyr31 bool = false - yyq31[0] = x.Kind != "" - yyq31[1] = x.APIVersion != "" - yyq31[2] = true - yyq31[3] = true - yyq31[4] = true - var yynn31 int - if yyr31 || yy2arr31 { - r.EncodeArrayStart(5) - } else { - yynn31 = 0 - for _, b := range yyq31 { - if b { - yynn31++ - } - } - r.EncodeMapStart(yynn31) - yynn31 = 0 - } - if yyr31 || yy2arr31 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq31[0] { - yym33 := z.EncBinary() - _ = yym33 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq31[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym34 := z.EncBinary() - _ = yym34 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr31 || yy2arr31 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq31[1] { - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq31[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr31 || yy2arr31 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq31[2] { - yy39 := &x.ObjectMeta - yy39.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq31[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy40 := &x.ObjectMeta - yy40.CodecEncodeSelf(e) - } - } - if yyr31 || yy2arr31 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq31[3] { - yy42 := &x.Spec - yy42.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq31[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy43 := &x.Spec - yy43.CodecEncodeSelf(e) - } - } - if yyr31 || yy2arr31 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq31[4] { - yy45 := &x.Status - yy45.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq31[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy46 := &x.Status - yy46.CodecEncodeSelf(e) - } - } - if yyr31 || yy2arr31 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Scale) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym47 := z.DecBinary() - _ = yym47 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct48 := r.ContainerType() - if yyct48 == codecSelferValueTypeMap1234 { - yyl48 := r.ReadMapStart() - if yyl48 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl48, d) - } - } else if yyct48 == codecSelferValueTypeArray1234 { - yyl48 := r.ReadArrayStart() - if yyl48 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl48, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *Scale) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys49Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys49Slc - var yyhl49 bool = l >= 0 - for yyj49 := 0; ; yyj49++ { - if yyhl49 { - if yyj49 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys49Slc = r.DecodeBytes(yys49Slc, true, true) - yys49 := string(yys49Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys49 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv52 := &x.ObjectMeta - yyv52.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ScaleSpec{} - } else { - yyv53 := &x.Spec - yyv53.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ScaleStatus{} - } else { - yyv54 := &x.Status - yyv54.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys49) - } // end switch yys49 - } // end for yyj49 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj55 int - var yyb55 bool - var yyhl55 bool = l >= 0 - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv58 := &x.ObjectMeta - yyv58.CodecDecodeSelf(d) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ScaleSpec{} - } else { - yyv59 := &x.Spec - yyv59.CodecDecodeSelf(d) - } - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ScaleStatus{} - } else { - yyv60 := &x.Status - yyv60.CodecDecodeSelf(d) - } - for { - yyj55++ - if yyhl55 { - yyb55 = yyj55 > l - } else { - yyb55 = r.CheckBreak() - } - if yyb55 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj55-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ReplicationControllerDummy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym61 := z.EncBinary() - _ = yym61 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep62 := !z.EncBinary() - yy2arr62 := z.EncBasicHandle().StructToArray - var yyq62 [2]bool - _, _, _ = yysep62, yyq62, yy2arr62 - const yyr62 bool = false - yyq62[0] = x.Kind != "" - yyq62[1] = x.APIVersion != "" - var yynn62 int - if yyr62 || yy2arr62 { - r.EncodeArrayStart(2) - } else { - yynn62 = 0 - for _, b := range yyq62 { - if b { - yynn62++ - } - } - r.EncodeMapStart(yynn62) - yynn62 = 0 - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[0] { - yym64 := z.EncBinary() - _ = yym64 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq62[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[1] { - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq62[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicationControllerDummy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym69 := z.DecBinary() - _ = yym69 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct70 := r.ContainerType() - if yyct70 == codecSelferValueTypeMap1234 { - yyl70 := r.ReadMapStart() - if yyl70 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl70, d) - } - } else if yyct70 == codecSelferValueTypeArray1234 { - yyl70 := r.ReadArrayStart() - if yyl70 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl70, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicationControllerDummy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys71Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys71Slc - var yyhl71 bool = l >= 0 - for yyj71 := 0; ; yyj71++ { - if yyhl71 { - if yyj71 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys71Slc = r.DecodeBytes(yys71Slc, true, true) - yys71 := string(yys71Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys71 { - case "kind": - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - case "apiVersion": - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys71) - } // end switch yys71 - } // end for yyj71 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicationControllerDummy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj74 int - var yyb74 bool - var yyhl74 bool = l >= 0 - yyj74++ - if yyhl74 { - yyb74 = yyj74 > l - } else { - yyb74 = r.CheckBreak() - } - if yyb74 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj74++ - if yyhl74 { - yyb74 = yyj74 > l - } else { - yyb74 = r.CheckBreak() - } - if yyb74 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - for { - yyj74++ - if yyhl74 { - yyb74 = yyj74 > l - } else { - yyb74 = r.CheckBreak() - } - if yyb74 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj74-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CustomMetricTarget) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym77 := z.EncBinary() - _ = yym77 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep78 := !z.EncBinary() - yy2arr78 := z.EncBasicHandle().StructToArray - var yyq78 [2]bool - _, _, _ = yysep78, yyq78, yy2arr78 - const yyr78 bool = false - var yynn78 int - if yyr78 || yy2arr78 { - r.EncodeArrayStart(2) - } else { - yynn78 = 2 - for _, b := range yyq78 { - if b { - yynn78++ - } - } - r.EncodeMapStart(yynn78) - yynn78 = 0 - } - if yyr78 || yy2arr78 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym80 := z.EncBinary() - _ = yym80 - 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) - yym81 := z.EncBinary() - _ = yym81 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr78 || yy2arr78 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy83 := &x.TargetValue - yym84 := z.EncBinary() - _ = yym84 - if false { - } else if z.HasExtensions() && z.EncExt(yy83) { - } else if !yym84 && z.IsJSONHandle() { - z.EncJSONMarshal(yy83) - } else { - z.EncFallback(yy83) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy85 := &x.TargetValue - yym86 := z.EncBinary() - _ = yym86 - if false { - } else if z.HasExtensions() && z.EncExt(yy85) { - } else if !yym86 && z.IsJSONHandle() { - z.EncJSONMarshal(yy85) - } else { - z.EncFallback(yy85) - } - } - if yyr78 || yy2arr78 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CustomMetricTarget) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym87 := z.DecBinary() - _ = yym87 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct88 := r.ContainerType() - if yyct88 == codecSelferValueTypeMap1234 { - yyl88 := r.ReadMapStart() - if yyl88 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl88, d) - } - } else if yyct88 == codecSelferValueTypeArray1234 { - yyl88 := r.ReadArrayStart() - if yyl88 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl88, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CustomMetricTarget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys89Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys89Slc - var yyhl89 bool = l >= 0 - for yyj89 := 0; ; yyj89++ { - if yyhl89 { - if yyj89 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys89Slc = r.DecodeBytes(yys89Slc, true, true) - yys89 := string(yys89Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys89 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "value": - if r.TryDecodeAsNil() { - x.TargetValue = pkg4_resource.Quantity{} - } else { - yyv91 := &x.TargetValue - yym92 := z.DecBinary() - _ = yym92 - if false { - } else if z.HasExtensions() && z.DecExt(yyv91) { - } else if !yym92 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv91) - } else { - z.DecFallback(yyv91, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys89) - } // end switch yys89 - } // end for yyj89 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CustomMetricTarget) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj93 int - var yyb93 bool - var yyhl93 bool = l >= 0 - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TargetValue = pkg4_resource.Quantity{} - } else { - yyv95 := &x.TargetValue - yym96 := z.DecBinary() - _ = yym96 - if false { - } else if z.HasExtensions() && z.DecExt(yyv95) { - } else if !yym96 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv95) - } else { - z.DecFallback(yyv95, false) - } - } - for { - yyj93++ - if yyhl93 { - yyb93 = yyj93 > l - } else { - yyb93 = r.CheckBreak() - } - if yyb93 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj93-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CustomMetricTargetList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym97 := z.EncBinary() - _ = yym97 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep98 := !z.EncBinary() - yy2arr98 := z.EncBasicHandle().StructToArray - var yyq98 [1]bool - _, _, _ = yysep98, yyq98, yy2arr98 - const yyr98 bool = false - var yynn98 int - if yyr98 || yy2arr98 { - r.EncodeArrayStart(1) - } else { - yynn98 = 1 - for _, b := range yyq98 { - if b { - yynn98++ - } - } - r.EncodeMapStart(yynn98) - yynn98 = 0 - } - if yyr98 || yy2arr98 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym100 := z.EncBinary() - _ = yym100 - if false { - } else { - h.encSliceCustomMetricTarget(([]CustomMetricTarget)(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 { - yym101 := z.EncBinary() - _ = yym101 - if false { - } else { - h.encSliceCustomMetricTarget(([]CustomMetricTarget)(x.Items), e) - } - } - } - if yyr98 || yy2arr98 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CustomMetricTargetList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym102 := z.DecBinary() - _ = yym102 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct103 := r.ContainerType() - if yyct103 == codecSelferValueTypeMap1234 { - yyl103 := r.ReadMapStart() - if yyl103 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl103, d) - } - } else if yyct103 == codecSelferValueTypeArray1234 { - yyl103 := r.ReadArrayStart() - if yyl103 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl103, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CustomMetricTargetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys104Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys104Slc - var yyhl104 bool = l >= 0 - for yyj104 := 0; ; yyj104++ { - if yyhl104 { - if yyj104 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys104Slc = r.DecodeBytes(yys104Slc, true, true) - yys104 := string(yys104Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys104 { - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv105 := &x.Items - yym106 := z.DecBinary() - _ = yym106 - if false { - } else { - h.decSliceCustomMetricTarget((*[]CustomMetricTarget)(yyv105), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys104) - } // end switch yys104 - } // end for yyj104 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CustomMetricTargetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj107 int - var yyb107 bool - var yyhl107 bool = l >= 0 - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv108 := &x.Items - yym109 := z.DecBinary() - _ = yym109 - if false { - } else { - h.decSliceCustomMetricTarget((*[]CustomMetricTarget)(yyv108), d) - } - } - for { - yyj107++ - if yyhl107 { - yyb107 = yyj107 > l - } else { - yyb107 = r.CheckBreak() - } - if yyb107 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj107-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CustomMetricCurrentStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym110 := z.EncBinary() - _ = yym110 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep111 := !z.EncBinary() - yy2arr111 := z.EncBasicHandle().StructToArray - var yyq111 [2]bool - _, _, _ = yysep111, yyq111, yy2arr111 - const yyr111 bool = false - var yynn111 int - if yyr111 || yy2arr111 { - r.EncodeArrayStart(2) - } else { - yynn111 = 2 - for _, b := range yyq111 { - if b { - yynn111++ - } - } - r.EncodeMapStart(yynn111) - yynn111 = 0 - } - if yyr111 || yy2arr111 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym113 := z.EncBinary() - _ = yym113 - 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) - yym114 := z.EncBinary() - _ = yym114 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr111 || yy2arr111 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy116 := &x.CurrentValue - yym117 := z.EncBinary() - _ = yym117 - if false { - } else if z.HasExtensions() && z.EncExt(yy116) { - } else if !yym117 && z.IsJSONHandle() { - z.EncJSONMarshal(yy116) - } else { - z.EncFallback(yy116) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy118 := &x.CurrentValue - yym119 := z.EncBinary() - _ = yym119 - if false { - } else if z.HasExtensions() && z.EncExt(yy118) { - } else if !yym119 && z.IsJSONHandle() { - z.EncJSONMarshal(yy118) - } else { - z.EncFallback(yy118) - } - } - if yyr111 || yy2arr111 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CustomMetricCurrentStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym120 := z.DecBinary() - _ = yym120 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct121 := r.ContainerType() - if yyct121 == codecSelferValueTypeMap1234 { - yyl121 := r.ReadMapStart() - if yyl121 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl121, d) - } - } else if yyct121 == codecSelferValueTypeArray1234 { - yyl121 := r.ReadArrayStart() - if yyl121 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl121, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CustomMetricCurrentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys122Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys122Slc - var yyhl122 bool = l >= 0 - for yyj122 := 0; ; yyj122++ { - if yyhl122 { - if yyj122 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys122Slc = r.DecodeBytes(yys122Slc, true, true) - yys122 := string(yys122Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys122 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "value": - if r.TryDecodeAsNil() { - x.CurrentValue = pkg4_resource.Quantity{} - } else { - yyv124 := &x.CurrentValue - yym125 := z.DecBinary() - _ = yym125 - if false { - } else if z.HasExtensions() && z.DecExt(yyv124) { - } else if !yym125 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv124) - } else { - z.DecFallback(yyv124, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys122) - } // end switch yys122 - } // end for yyj122 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CustomMetricCurrentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj126 int - var yyb126 bool - var yyhl126 bool = l >= 0 - yyj126++ - if yyhl126 { - yyb126 = yyj126 > l - } else { - yyb126 = r.CheckBreak() - } - if yyb126 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj126++ - if yyhl126 { - yyb126 = yyj126 > l - } else { - yyb126 = r.CheckBreak() - } - if yyb126 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CurrentValue = pkg4_resource.Quantity{} - } else { - yyv128 := &x.CurrentValue - yym129 := z.DecBinary() - _ = yym129 - if false { - } else if z.HasExtensions() && z.DecExt(yyv128) { - } else if !yym129 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv128) - } else { - z.DecFallback(yyv128, false) - } - } - for { - yyj126++ - if yyhl126 { - yyb126 = yyj126 > l - } else { - yyb126 = r.CheckBreak() - } - if yyb126 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj126-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *CustomMetricCurrentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym130 := z.EncBinary() - _ = yym130 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep131 := !z.EncBinary() - yy2arr131 := z.EncBasicHandle().StructToArray - var yyq131 [1]bool - _, _, _ = yysep131, yyq131, yy2arr131 - const yyr131 bool = false - var yynn131 int - if yyr131 || yy2arr131 { - r.EncodeArrayStart(1) - } else { - yynn131 = 1 - for _, b := range yyq131 { - if b { - yynn131++ - } - } - r.EncodeMapStart(yynn131) - yynn131 = 0 - } - if yyr131 || yy2arr131 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym133 := z.EncBinary() - _ = yym133 - if false { - } else { - h.encSliceCustomMetricCurrentStatus(([]CustomMetricCurrentStatus)(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 { - yym134 := z.EncBinary() - _ = yym134 - if false { - } else { - h.encSliceCustomMetricCurrentStatus(([]CustomMetricCurrentStatus)(x.Items), e) - } - } - } - if yyr131 || yy2arr131 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *CustomMetricCurrentStatusList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym135 := z.DecBinary() - _ = yym135 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct136 := r.ContainerType() - if yyct136 == codecSelferValueTypeMap1234 { - yyl136 := r.ReadMapStart() - if yyl136 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl136, d) - } - } else if yyct136 == codecSelferValueTypeArray1234 { - yyl136 := r.ReadArrayStart() - if yyl136 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl136, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys137Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys137Slc - var yyhl137 bool = l >= 0 - for yyj137 := 0; ; yyj137++ { - if yyhl137 { - if yyj137 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys137Slc = r.DecodeBytes(yys137Slc, true, true) - yys137 := string(yys137Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys137 { - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv138 := &x.Items - yym139 := z.DecBinary() - _ = yym139 - if false { - } else { - h.decSliceCustomMetricCurrentStatus((*[]CustomMetricCurrentStatus)(yyv138), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys137) - } // end switch yys137 - } // end for yyj137 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj140 int - var yyb140 bool - var yyhl140 bool = l >= 0 - yyj140++ - if yyhl140 { - yyb140 = yyj140 > l - } else { - yyb140 = r.CheckBreak() - } - if yyb140 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv141 := &x.Items - yym142 := z.DecBinary() - _ = yym142 - if false { - } else { - h.decSliceCustomMetricCurrentStatus((*[]CustomMetricCurrentStatus)(yyv141), d) - } - } - for { - yyj140++ - if yyhl140 { - yyb140 = yyj140 > l - } else { - yyb140 = r.CheckBreak() - } - if yyb140 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj140-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ThirdPartyResource) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym143 := z.EncBinary() - _ = yym143 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep144 := !z.EncBinary() - yy2arr144 := z.EncBasicHandle().StructToArray - var yyq144 [5]bool - _, _, _ = yysep144, yyq144, yy2arr144 - const yyr144 bool = false - yyq144[0] = x.Kind != "" - yyq144[1] = x.APIVersion != "" - yyq144[2] = true - yyq144[3] = x.Description != "" - yyq144[4] = len(x.Versions) != 0 - var yynn144 int - if yyr144 || yy2arr144 { - r.EncodeArrayStart(5) - } else { - yynn144 = 0 - for _, b := range yyq144 { - if b { - yynn144++ - } - } - r.EncodeMapStart(yynn144) - yynn144 = 0 - } - if yyr144 || yy2arr144 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq144[0] { - yym146 := z.EncBinary() - _ = yym146 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq144[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym147 := z.EncBinary() - _ = yym147 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr144 || yy2arr144 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq144[1] { - yym149 := z.EncBinary() - _ = yym149 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq144[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym150 := z.EncBinary() - _ = yym150 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr144 || yy2arr144 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq144[2] { - yy152 := &x.ObjectMeta - yy152.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq144[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy153 := &x.ObjectMeta - yy153.CodecEncodeSelf(e) - } - } - if yyr144 || yy2arr144 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq144[3] { - yym155 := z.EncBinary() - _ = yym155 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Description)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq144[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("description")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym156 := z.EncBinary() - _ = yym156 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Description)) - } - } - } - if yyr144 || yy2arr144 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq144[4] { - if x.Versions == nil { - r.EncodeNil() - } else { - yym158 := z.EncBinary() - _ = yym158 - if false { - } else { - h.encSliceAPIVersion(([]APIVersion)(x.Versions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq144[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("versions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Versions == nil { - r.EncodeNil() - } else { - yym159 := z.EncBinary() - _ = yym159 - if false { - } else { - h.encSliceAPIVersion(([]APIVersion)(x.Versions), e) - } - } - } - } - if yyr144 || yy2arr144 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ThirdPartyResource) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym160 := z.DecBinary() - _ = yym160 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct161 := r.ContainerType() - if yyct161 == codecSelferValueTypeMap1234 { - yyl161 := r.ReadMapStart() - if yyl161 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl161, d) - } - } else if yyct161 == codecSelferValueTypeArray1234 { - yyl161 := r.ReadArrayStart() - if yyl161 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl161, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ThirdPartyResource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys162Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys162Slc - var yyhl162 bool = l >= 0 - for yyj162 := 0; ; yyj162++ { - if yyhl162 { - if yyj162 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys162Slc = r.DecodeBytes(yys162Slc, true, true) - yys162 := string(yys162Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys162 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv165 := &x.ObjectMeta - yyv165.CodecDecodeSelf(d) - } - case "description": - if r.TryDecodeAsNil() { - x.Description = "" - } else { - x.Description = string(r.DecodeString()) - } - case "versions": - if r.TryDecodeAsNil() { - x.Versions = nil - } else { - yyv167 := &x.Versions - yym168 := z.DecBinary() - _ = yym168 - if false { - } else { - h.decSliceAPIVersion((*[]APIVersion)(yyv167), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys162) - } // end switch yys162 - } // end for yyj162 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ThirdPartyResource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj169 int - var yyb169 bool - var yyhl169 bool = l >= 0 - yyj169++ - if yyhl169 { - yyb169 = yyj169 > l - } else { - yyb169 = r.CheckBreak() - } - if yyb169 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj169++ - if yyhl169 { - yyb169 = yyj169 > l - } else { - yyb169 = r.CheckBreak() - } - if yyb169 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj169++ - if yyhl169 { - yyb169 = yyj169 > l - } else { - yyb169 = r.CheckBreak() - } - if yyb169 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv172 := &x.ObjectMeta - yyv172.CodecDecodeSelf(d) - } - yyj169++ - if yyhl169 { - yyb169 = yyj169 > l - } else { - yyb169 = r.CheckBreak() - } - if yyb169 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Description = "" - } else { - x.Description = string(r.DecodeString()) - } - yyj169++ - if yyhl169 { - yyb169 = yyj169 > l - } else { - yyb169 = r.CheckBreak() - } - if yyb169 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Versions = nil - } else { - yyv174 := &x.Versions - yym175 := z.DecBinary() - _ = yym175 - if false { - } else { - h.decSliceAPIVersion((*[]APIVersion)(yyv174), d) - } - } - for { - yyj169++ - if yyhl169 { - yyb169 = yyj169 > l - } else { - yyb169 = r.CheckBreak() - } - if yyb169 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj169-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ThirdPartyResourceList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym176 := z.EncBinary() - _ = yym176 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep177 := !z.EncBinary() - yy2arr177 := z.EncBasicHandle().StructToArray - var yyq177 [4]bool - _, _, _ = yysep177, yyq177, yy2arr177 - const yyr177 bool = false - yyq177[0] = x.Kind != "" - yyq177[1] = x.APIVersion != "" - yyq177[2] = true - var yynn177 int - if yyr177 || yy2arr177 { - r.EncodeArrayStart(4) - } else { - yynn177 = 1 - for _, b := range yyq177 { - if b { - yynn177++ - } - } - r.EncodeMapStart(yynn177) - yynn177 = 0 - } - if yyr177 || yy2arr177 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq177[0] { - yym179 := z.EncBinary() - _ = yym179 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq177[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym180 := z.EncBinary() - _ = yym180 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr177 || yy2arr177 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq177[1] { - yym182 := z.EncBinary() - _ = yym182 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq177[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym183 := z.EncBinary() - _ = yym183 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr177 || yy2arr177 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq177[2] { - yy185 := &x.ListMeta - yym186 := z.EncBinary() - _ = yym186 - if false { - } else if z.HasExtensions() && z.EncExt(yy185) { - } else { - z.EncFallback(yy185) - } - } else { - r.EncodeNil() - } - } else { - if yyq177[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy187 := &x.ListMeta - yym188 := z.EncBinary() - _ = yym188 - if false { - } else if z.HasExtensions() && z.EncExt(yy187) { - } else { - z.EncFallback(yy187) - } - } - } - if yyr177 || yy2arr177 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym190 := z.EncBinary() - _ = yym190 - if false { - } else { - h.encSliceThirdPartyResource(([]ThirdPartyResource)(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 { - yym191 := z.EncBinary() - _ = yym191 - if false { - } else { - h.encSliceThirdPartyResource(([]ThirdPartyResource)(x.Items), e) - } - } - } - if yyr177 || yy2arr177 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ThirdPartyResourceList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym192 := z.DecBinary() - _ = yym192 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct193 := r.ContainerType() - if yyct193 == codecSelferValueTypeMap1234 { - yyl193 := r.ReadMapStart() - if yyl193 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl193, d) - } - } else if yyct193 == codecSelferValueTypeArray1234 { - yyl193 := r.ReadArrayStart() - if yyl193 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl193, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ThirdPartyResourceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys194Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys194Slc - var yyhl194 bool = l >= 0 - for yyj194 := 0; ; yyj194++ { - if yyhl194 { - if yyj194 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys194Slc = r.DecodeBytes(yys194Slc, true, true) - yys194 := string(yys194Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys194 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv197 := &x.ListMeta - yym198 := z.DecBinary() - _ = yym198 - if false { - } else if z.HasExtensions() && z.DecExt(yyv197) { - } else { - z.DecFallback(yyv197, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv199 := &x.Items - yym200 := z.DecBinary() - _ = yym200 - if false { - } else { - h.decSliceThirdPartyResource((*[]ThirdPartyResource)(yyv199), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys194) - } // end switch yys194 - } // end for yyj194 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ThirdPartyResourceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj201 int - var yyb201 bool - var yyhl201 bool = l >= 0 - yyj201++ - if yyhl201 { - yyb201 = yyj201 > l - } else { - yyb201 = r.CheckBreak() - } - if yyb201 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj201++ - if yyhl201 { - yyb201 = yyj201 > l - } else { - yyb201 = r.CheckBreak() - } - if yyb201 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj201++ - if yyhl201 { - yyb201 = yyj201 > l - } else { - yyb201 = r.CheckBreak() - } - if yyb201 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv204 := &x.ListMeta - yym205 := z.DecBinary() - _ = yym205 - if false { - } else if z.HasExtensions() && z.DecExt(yyv204) { - } else { - z.DecFallback(yyv204, false) - } - } - yyj201++ - if yyhl201 { - yyb201 = yyj201 > l - } else { - yyb201 = r.CheckBreak() - } - if yyb201 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv206 := &x.Items - yym207 := z.DecBinary() - _ = yym207 - if false { - } else { - h.decSliceThirdPartyResource((*[]ThirdPartyResource)(yyv206), d) - } - } - for { - yyj201++ - if yyhl201 { - yyb201 = yyj201 > l - } else { - yyb201 = r.CheckBreak() - } - if yyb201 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj201-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *APIVersion) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym208 := z.EncBinary() - _ = yym208 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep209 := !z.EncBinary() - yy2arr209 := z.EncBasicHandle().StructToArray - var yyq209 [1]bool - _, _, _ = yysep209, yyq209, yy2arr209 - const yyr209 bool = false - yyq209[0] = x.Name != "" - var yynn209 int - if yyr209 || yy2arr209 { - r.EncodeArrayStart(1) - } else { - yynn209 = 0 - for _, b := range yyq209 { - if b { - yynn209++ - } - } - r.EncodeMapStart(yynn209) - yynn209 = 0 - } - if yyr209 || yy2arr209 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq209[0] { - yym211 := z.EncBinary() - _ = yym211 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq209[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym212 := z.EncBinary() - _ = yym212 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - } - if yyr209 || yy2arr209 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *APIVersion) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym213 := z.DecBinary() - _ = yym213 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct214 := r.ContainerType() - if yyct214 == codecSelferValueTypeMap1234 { - yyl214 := r.ReadMapStart() - if yyl214 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl214, d) - } - } else if yyct214 == codecSelferValueTypeArray1234 { - yyl214 := r.ReadArrayStart() - if yyl214 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl214, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *APIVersion) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys215Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys215Slc - var yyhl215 bool = l >= 0 - for yyj215 := 0; ; yyj215++ { - if yyhl215 { - if yyj215 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys215Slc = r.DecodeBytes(yys215Slc, true, true) - yys215 := string(yys215Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys215 { - case "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys215) - } // end switch yys215 - } // end for yyj215 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *APIVersion) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj217 int - var yyb217 bool - var yyhl217 bool = l >= 0 - yyj217++ - if yyhl217 { - yyb217 = yyj217 > l - } else { - yyb217 = r.CheckBreak() - } - if yyb217 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - for { - yyj217++ - if yyhl217 { - yyb217 = yyj217 > l - } else { - yyb217 = r.CheckBreak() - } - if yyb217 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj217-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ThirdPartyResourceData) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym219 := z.EncBinary() - _ = yym219 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep220 := !z.EncBinary() - yy2arr220 := z.EncBasicHandle().StructToArray - var yyq220 [4]bool - _, _, _ = yysep220, yyq220, yy2arr220 - const yyr220 bool = false - yyq220[0] = x.Kind != "" - yyq220[1] = x.APIVersion != "" - yyq220[2] = true - yyq220[3] = len(x.Data) != 0 - var yynn220 int - if yyr220 || yy2arr220 { - r.EncodeArrayStart(4) - } else { - yynn220 = 0 - for _, b := range yyq220 { - if b { - yynn220++ - } - } - r.EncodeMapStart(yynn220) - yynn220 = 0 - } - if yyr220 || yy2arr220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq220[0] { - yym222 := z.EncBinary() - _ = yym222 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq220[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym223 := z.EncBinary() - _ = yym223 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr220 || yy2arr220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq220[1] { - yym225 := z.EncBinary() - _ = yym225 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq220[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym226 := z.EncBinary() - _ = yym226 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr220 || yy2arr220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq220[2] { - yy228 := &x.ObjectMeta - yy228.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq220[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy229 := &x.ObjectMeta - yy229.CodecEncodeSelf(e) - } - } - if yyr220 || yy2arr220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq220[3] { - if x.Data == nil { - r.EncodeNil() - } else { - yym231 := z.EncBinary() - _ = yym231 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq220[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("data")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Data == nil { - r.EncodeNil() - } else { - yym232 := z.EncBinary() - _ = yym232 - if false { - } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) - } - } - } - } - if yyr220 || yy2arr220 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ThirdPartyResourceData) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym233 := z.DecBinary() - _ = yym233 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct234 := r.ContainerType() - if yyct234 == codecSelferValueTypeMap1234 { - yyl234 := r.ReadMapStart() - if yyl234 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl234, d) - } - } else if yyct234 == codecSelferValueTypeArray1234 { - yyl234 := r.ReadArrayStart() - if yyl234 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl234, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ThirdPartyResourceData) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys235Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys235Slc - var yyhl235 bool = l >= 0 - for yyj235 := 0; ; yyj235++ { - if yyhl235 { - if yyj235 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys235Slc = r.DecodeBytes(yys235Slc, true, true) - yys235 := string(yys235Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys235 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv238 := &x.ObjectMeta - yyv238.CodecDecodeSelf(d) - } - case "data": - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv239 := &x.Data - yym240 := z.DecBinary() - _ = yym240 - if false { - } else { - *yyv239 = r.DecodeBytes(*(*[]byte)(yyv239), false, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys235) - } // end switch yys235 - } // end for yyj235 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ThirdPartyResourceData) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj241 int - var yyb241 bool - var yyhl241 bool = l >= 0 - yyj241++ - if yyhl241 { - yyb241 = yyj241 > l - } else { - yyb241 = r.CheckBreak() - } - if yyb241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj241++ - if yyhl241 { - yyb241 = yyj241 > l - } else { - yyb241 = r.CheckBreak() - } - if yyb241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj241++ - if yyhl241 { - yyb241 = yyj241 > l - } else { - yyb241 = r.CheckBreak() - } - if yyb241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv244 := &x.ObjectMeta - yyv244.CodecDecodeSelf(d) - } - yyj241++ - if yyhl241 { - yyb241 = yyj241 > l - } else { - yyb241 = r.CheckBreak() - } - if yyb241 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv245 := &x.Data - yym246 := z.DecBinary() - _ = yym246 - if false { - } else { - *yyv245 = r.DecodeBytes(*(*[]byte)(yyv245), false, false) - } - } - for { - yyj241++ - if yyhl241 { - yyb241 = yyj241 > l - } else { - yyb241 = r.CheckBreak() - } - if yyb241 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj241-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym247 := z.EncBinary() - _ = yym247 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep248 := !z.EncBinary() - yy2arr248 := z.EncBasicHandle().StructToArray - var yyq248 [5]bool - _, _, _ = yysep248, yyq248, yy2arr248 - const yyr248 bool = false - yyq248[0] = x.Kind != "" - yyq248[1] = x.APIVersion != "" - yyq248[2] = true - yyq248[3] = true - yyq248[4] = true - var yynn248 int - if yyr248 || yy2arr248 { - r.EncodeArrayStart(5) - } else { - yynn248 = 0 - for _, b := range yyq248 { - if b { - yynn248++ - } - } - r.EncodeMapStart(yynn248) - yynn248 = 0 - } - if yyr248 || yy2arr248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq248[0] { - yym250 := z.EncBinary() - _ = yym250 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq248[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym251 := z.EncBinary() - _ = yym251 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr248 || yy2arr248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq248[1] { - yym253 := z.EncBinary() - _ = yym253 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq248[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym254 := z.EncBinary() - _ = yym254 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr248 || yy2arr248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq248[2] { - yy256 := &x.ObjectMeta - yy256.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq248[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy257 := &x.ObjectMeta - yy257.CodecEncodeSelf(e) - } - } - if yyr248 || yy2arr248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq248[3] { - yy259 := &x.Spec - yy259.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq248[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy260 := &x.Spec - yy260.CodecEncodeSelf(e) - } - } - if yyr248 || yy2arr248 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq248[4] { - yy262 := &x.Status - yy262.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq248[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy263 := &x.Status - yy263.CodecEncodeSelf(e) - } - } - if yyr248 || yy2arr248 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym264 := z.DecBinary() - _ = yym264 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct265 := r.ContainerType() - if yyct265 == codecSelferValueTypeMap1234 { - yyl265 := r.ReadMapStart() - if yyl265 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl265, d) - } - } else if yyct265 == codecSelferValueTypeArray1234 { - yyl265 := r.ReadArrayStart() - if yyl265 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl265, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys266Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys266Slc - var yyhl266 bool = l >= 0 - for yyj266 := 0; ; yyj266++ { - if yyhl266 { - if yyj266 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys266Slc = r.DecodeBytes(yys266Slc, true, true) - yys266 := string(yys266Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys266 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv269 := &x.ObjectMeta - yyv269.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = DeploymentSpec{} - } else { - yyv270 := &x.Spec - yyv270.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = DeploymentStatus{} - } else { - yyv271 := &x.Status - yyv271.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys266) - } // end switch yys266 - } // end for yyj266 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Deployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj272 int - var yyb272 bool - var yyhl272 bool = l >= 0 - yyj272++ - if yyhl272 { - yyb272 = yyj272 > l - } else { - yyb272 = r.CheckBreak() - } - if yyb272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj272++ - if yyhl272 { - yyb272 = yyj272 > l - } else { - yyb272 = r.CheckBreak() - } - if yyb272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj272++ - if yyhl272 { - yyb272 = yyj272 > l - } else { - yyb272 = r.CheckBreak() - } - if yyb272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv275 := &x.ObjectMeta - yyv275.CodecDecodeSelf(d) - } - yyj272++ - if yyhl272 { - yyb272 = yyj272 > l - } else { - yyb272 = r.CheckBreak() - } - if yyb272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = DeploymentSpec{} - } else { - yyv276 := &x.Spec - yyv276.CodecDecodeSelf(d) - } - yyj272++ - if yyhl272 { - yyb272 = yyj272 > l - } else { - yyb272 = r.CheckBreak() - } - if yyb272 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = DeploymentStatus{} - } else { - yyv277 := &x.Status - yyv277.CodecDecodeSelf(d) - } - for { - yyj272++ - if yyhl272 { - yyb272 = yyj272 > l - } else { - yyb272 = r.CheckBreak() - } - if yyb272 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj272-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym278 := z.EncBinary() - _ = yym278 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep279 := !z.EncBinary() - yy2arr279 := z.EncBasicHandle().StructToArray - var yyq279 [9]bool - _, _, _ = yysep279, yyq279, yy2arr279 - const yyr279 bool = false - yyq279[0] = x.Replicas != 0 - yyq279[1] = x.Selector != nil - yyq279[3] = true - yyq279[4] = x.MinReadySeconds != 0 - yyq279[5] = x.RevisionHistoryLimit != nil - yyq279[6] = x.Paused != false - yyq279[7] = x.RollbackTo != nil - yyq279[8] = x.ProgressDeadlineSeconds != nil - var yynn279 int - if yyr279 || yy2arr279 { - r.EncodeArrayStart(9) - } else { - yynn279 = 1 - for _, b := range yyq279 { - if b { - yynn279++ - } - } - r.EncodeMapStart(yynn279) - yynn279 = 0 - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[0] { - yym281 := z.EncBinary() - _ = yym281 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq279[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym282 := z.EncBinary() - _ = yym282 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym284 := z.EncBinary() - _ = yym284 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq279[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym285 := z.EncBinary() - _ = yym285 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy287 := &x.Template - yy287.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy288 := &x.Template - yy288.CodecEncodeSelf(e) - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[3] { - yy290 := &x.Strategy - yy290.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq279[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("strategy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy291 := &x.Strategy - yy291.CodecEncodeSelf(e) - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[4] { - yym293 := z.EncBinary() - _ = yym293 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq279[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym294 := z.EncBinary() - _ = yym294 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[5] { - if x.RevisionHistoryLimit == nil { - r.EncodeNil() - } else { - yy296 := *x.RevisionHistoryLimit - yym297 := z.EncBinary() - _ = yym297 - if false { - } else { - r.EncodeInt(int64(yy296)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq279[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RevisionHistoryLimit == nil { - r.EncodeNil() - } else { - yy298 := *x.RevisionHistoryLimit - yym299 := z.EncBinary() - _ = yym299 - if false { - } else { - r.EncodeInt(int64(yy298)) - } - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[6] { - yym301 := z.EncBinary() - _ = yym301 - if false { - } else { - r.EncodeBool(bool(x.Paused)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq279[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("paused")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym302 := z.EncBinary() - _ = yym302 - if false { - } else { - r.EncodeBool(bool(x.Paused)) - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[7] { - if x.RollbackTo == nil { - r.EncodeNil() - } else { - x.RollbackTo.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq279[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RollbackTo == nil { - r.EncodeNil() - } else { - x.RollbackTo.CodecEncodeSelf(e) - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq279[8] { - if x.ProgressDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy305 := *x.ProgressDeadlineSeconds - yym306 := z.EncBinary() - _ = yym306 - if false { - } else { - r.EncodeInt(int64(yy305)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq279[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("progressDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ProgressDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy307 := *x.ProgressDeadlineSeconds - yym308 := z.EncBinary() - _ = yym308 - if false { - } else { - r.EncodeInt(int64(yy307)) - } - } - } - } - if yyr279 || yy2arr279 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym309 := z.DecBinary() - _ = yym309 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct310 := r.ContainerType() - if yyct310 == codecSelferValueTypeMap1234 { - yyl310 := r.ReadMapStart() - if yyl310 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl310, d) - } - } else if yyct310 == codecSelferValueTypeArray1234 { - yyl310 := r.ReadArrayStart() - if yyl310 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl310, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys311Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys311Slc - var yyhl311 bool = l >= 0 - for yyj311 := 0; ; yyj311++ { - if yyhl311 { - if yyj311 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys311Slc = r.DecodeBytes(yys311Slc, true, true) - yys311 := string(yys311Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys311 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym314 := z.DecBinary() - _ = yym314 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv315 := &x.Template - yyv315.CodecDecodeSelf(d) - } - case "strategy": - if r.TryDecodeAsNil() { - x.Strategy = DeploymentStrategy{} - } else { - yyv316 := &x.Strategy - yyv316.CodecDecodeSelf(d) - } - case "minReadySeconds": - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - case "revisionHistoryLimit": - if r.TryDecodeAsNil() { - if x.RevisionHistoryLimit != nil { - x.RevisionHistoryLimit = nil - } - } else { - if x.RevisionHistoryLimit == nil { - x.RevisionHistoryLimit = new(int32) - } - yym319 := z.DecBinary() - _ = yym319 - if false { - } else { - *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) - } - } - case "paused": - if r.TryDecodeAsNil() { - x.Paused = false - } else { - x.Paused = bool(r.DecodeBool()) - } - case "rollbackTo": - if r.TryDecodeAsNil() { - if x.RollbackTo != nil { - x.RollbackTo = nil - } - } else { - if x.RollbackTo == nil { - x.RollbackTo = new(RollbackConfig) - } - x.RollbackTo.CodecDecodeSelf(d) - } - case "progressDeadlineSeconds": - if r.TryDecodeAsNil() { - if x.ProgressDeadlineSeconds != nil { - x.ProgressDeadlineSeconds = nil - } - } else { - if x.ProgressDeadlineSeconds == nil { - x.ProgressDeadlineSeconds = new(int32) - } - yym323 := z.DecBinary() - _ = yym323 - if false { - } else { - *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys311) - } // end switch yys311 - } // end for yyj311 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj324 int - var yyb324 bool - var yyhl324 bool = l >= 0 - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - 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(pkg1_unversioned.LabelSelector) - } - yym327 := z.DecBinary() - _ = yym327 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv328 := &x.Template - yyv328.CodecDecodeSelf(d) - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Strategy = DeploymentStrategy{} - } else { - yyv329 := &x.Strategy - yyv329.CodecDecodeSelf(d) - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.RevisionHistoryLimit != nil { - x.RevisionHistoryLimit = nil - } - } else { - if x.RevisionHistoryLimit == nil { - x.RevisionHistoryLimit = new(int32) - } - yym332 := z.DecBinary() - _ = yym332 - if false { - } else { - *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) - } - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Paused = false - } else { - x.Paused = bool(r.DecodeBool()) - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.RollbackTo != nil { - x.RollbackTo = nil - } - } else { - if x.RollbackTo == nil { - x.RollbackTo = new(RollbackConfig) - } - x.RollbackTo.CodecDecodeSelf(d) - } - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ProgressDeadlineSeconds != nil { - x.ProgressDeadlineSeconds = nil - } - } else { - if x.ProgressDeadlineSeconds == nil { - x.ProgressDeadlineSeconds = new(int32) - } - yym336 := z.DecBinary() - _ = yym336 - if false { - } else { - *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) - } - } - for { - yyj324++ - if yyhl324 { - yyb324 = yyj324 > l - } else { - yyb324 = r.CheckBreak() - } - if yyb324 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj324-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym337 := z.EncBinary() - _ = yym337 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep338 := !z.EncBinary() - yy2arr338 := z.EncBasicHandle().StructToArray - var yyq338 [5]bool - _, _, _ = yysep338, yyq338, yy2arr338 - const yyr338 bool = false - yyq338[0] = x.Kind != "" - yyq338[1] = x.APIVersion != "" - yyq338[3] = len(x.UpdatedAnnotations) != 0 - var yynn338 int - if yyr338 || yy2arr338 { - r.EncodeArrayStart(5) - } else { - yynn338 = 2 - for _, b := range yyq338 { - if b { - yynn338++ - } - } - r.EncodeMapStart(yynn338) - yynn338 = 0 - } - if yyr338 || yy2arr338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq338[0] { - yym340 := z.EncBinary() - _ = yym340 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq338[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym341 := z.EncBinary() - _ = yym341 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr338 || yy2arr338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq338[1] { - yym343 := z.EncBinary() - _ = yym343 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq338[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym344 := z.EncBinary() - _ = yym344 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr338 || yy2arr338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym346 := z.EncBinary() - _ = yym346 - 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) - yym347 := z.EncBinary() - _ = yym347 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr338 || yy2arr338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq338[3] { - if x.UpdatedAnnotations == nil { - r.EncodeNil() - } else { - yym349 := z.EncBinary() - _ = yym349 - if false { - } else { - z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq338[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("updatedAnnotations")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.UpdatedAnnotations == nil { - r.EncodeNil() - } else { - yym350 := z.EncBinary() - _ = yym350 - if false { - } else { - z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) - } - } - } - } - if yyr338 || yy2arr338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy352 := &x.RollbackTo - yy352.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy353 := &x.RollbackTo - yy353.CodecEncodeSelf(e) - } - if yyr338 || yy2arr338 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentRollback) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym354 := z.DecBinary() - _ = yym354 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct355 := r.ContainerType() - if yyct355 == codecSelferValueTypeMap1234 { - yyl355 := r.ReadMapStart() - if yyl355 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl355, d) - } - } else if yyct355 == codecSelferValueTypeArray1234 { - yyl355 := r.ReadArrayStart() - if yyl355 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl355, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys356Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys356Slc - var yyhl356 bool = l >= 0 - for yyj356 := 0; ; yyj356++ { - if yyhl356 { - if yyj356 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys356Slc = r.DecodeBytes(yys356Slc, true, true) - yys356 := string(yys356Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys356 { - 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 "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "updatedAnnotations": - if r.TryDecodeAsNil() { - x.UpdatedAnnotations = nil - } else { - yyv360 := &x.UpdatedAnnotations - yym361 := z.DecBinary() - _ = yym361 - if false { - } else { - z.F.DecMapStringStringX(yyv360, false, d) - } - } - case "rollbackTo": - if r.TryDecodeAsNil() { - x.RollbackTo = RollbackConfig{} - } else { - yyv362 := &x.RollbackTo - yyv362.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys356) - } // end switch yys356 - } // end for yyj356 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj363 int - var yyb363 bool - var yyhl363 bool = l >= 0 - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UpdatedAnnotations = nil - } else { - yyv367 := &x.UpdatedAnnotations - yym368 := z.DecBinary() - _ = yym368 - if false { - } else { - z.F.DecMapStringStringX(yyv367, false, d) - } - } - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RollbackTo = RollbackConfig{} - } else { - yyv369 := &x.RollbackTo - yyv369.CodecDecodeSelf(d) - } - for { - yyj363++ - if yyhl363 { - yyb363 = yyj363 > l - } else { - yyb363 = r.CheckBreak() - } - if yyb363 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj363-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym370 := z.EncBinary() - _ = yym370 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep371 := !z.EncBinary() - yy2arr371 := z.EncBasicHandle().StructToArray - var yyq371 [1]bool - _, _, _ = yysep371, yyq371, yy2arr371 - const yyr371 bool = false - yyq371[0] = x.Revision != 0 - var yynn371 int - if yyr371 || yy2arr371 { - r.EncodeArrayStart(1) - } else { - yynn371 = 0 - for _, b := range yyq371 { - if b { - yynn371++ - } - } - r.EncodeMapStart(yynn371) - yynn371 = 0 - } - if yyr371 || yy2arr371 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq371[0] { - yym373 := z.EncBinary() - _ = yym373 - if false { - } else { - r.EncodeInt(int64(x.Revision)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq371[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revision")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym374 := z.EncBinary() - _ = yym374 - if false { - } else { - r.EncodeInt(int64(x.Revision)) - } - } - } - if yyr371 || yy2arr371 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *RollbackConfig) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym375 := z.DecBinary() - _ = yym375 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct376 := r.ContainerType() - if yyct376 == codecSelferValueTypeMap1234 { - yyl376 := r.ReadMapStart() - if yyl376 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl376, d) - } - } else if yyct376 == codecSelferValueTypeArray1234 { - yyl376 := r.ReadArrayStart() - if yyl376 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl376, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys377Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys377Slc - var yyhl377 bool = l >= 0 - for yyj377 := 0; ; yyj377++ { - if yyhl377 { - if yyj377 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys377Slc = r.DecodeBytes(yys377Slc, true, true) - yys377 := string(yys377Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys377 { - case "revision": - if r.TryDecodeAsNil() { - x.Revision = 0 - } else { - x.Revision = int64(r.DecodeInt(64)) - } - default: - z.DecStructFieldNotFound(-1, yys377) - } // end switch yys377 - } // end for yyj377 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj379 int - var yyb379 bool - var yyhl379 bool = l >= 0 - yyj379++ - if yyhl379 { - yyb379 = yyj379 > l - } else { - yyb379 = r.CheckBreak() - } - if yyb379 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Revision = 0 - } else { - x.Revision = int64(r.DecodeInt(64)) - } - for { - yyj379++ - if yyhl379 { - yyb379 = yyj379 > l - } else { - yyb379 = r.CheckBreak() - } - if yyb379 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj379-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym381 := z.EncBinary() - _ = yym381 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep382 := !z.EncBinary() - yy2arr382 := z.EncBasicHandle().StructToArray - var yyq382 [2]bool - _, _, _ = yysep382, yyq382, yy2arr382 - const yyr382 bool = false - yyq382[0] = x.Type != "" - yyq382[1] = x.RollingUpdate != nil - var yynn382 int - if yyr382 || yy2arr382 { - r.EncodeArrayStart(2) - } else { - yynn382 = 0 - for _, b := range yyq382 { - if b { - yynn382++ - } - } - r.EncodeMapStart(yynn382) - yynn382 = 0 - } - if yyr382 || yy2arr382 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq382[0] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq382[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr382 || yy2arr382 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq382[1] { - if x.RollingUpdate == nil { - r.EncodeNil() - } else { - x.RollingUpdate.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq382[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RollingUpdate == nil { - r.EncodeNil() - } else { - x.RollingUpdate.CodecEncodeSelf(e) - } - } - } - if yyr382 || yy2arr382 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentStrategy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym385 := z.DecBinary() - _ = yym385 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct386 := r.ContainerType() - if yyct386 == codecSelferValueTypeMap1234 { - yyl386 := r.ReadMapStart() - if yyl386 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl386, d) - } - } else if yyct386 == codecSelferValueTypeArray1234 { - yyl386 := r.ReadArrayStart() - if yyl386 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl386, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys387Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys387Slc - var yyhl387 bool = l >= 0 - for yyj387 := 0; ; yyj387++ { - if yyhl387 { - if yyj387 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys387Slc = r.DecodeBytes(yys387Slc, true, true) - yys387 := string(yys387Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys387 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentStrategyType(r.DecodeString()) - } - case "rollingUpdate": - if r.TryDecodeAsNil() { - if x.RollingUpdate != nil { - x.RollingUpdate = nil - } - } else { - if x.RollingUpdate == nil { - x.RollingUpdate = new(RollingUpdateDeployment) - } - x.RollingUpdate.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys387) - } // end switch yys387 - } // end for yyj387 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj390 int - var yyb390 bool - var yyhl390 bool = l >= 0 - yyj390++ - if yyhl390 { - yyb390 = yyj390 > l - } else { - yyb390 = r.CheckBreak() - } - if yyb390 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentStrategyType(r.DecodeString()) - } - yyj390++ - if yyhl390 { - yyb390 = yyj390 > l - } else { - yyb390 = r.CheckBreak() - } - if yyb390 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.RollingUpdate != nil { - x.RollingUpdate = nil - } - } else { - if x.RollingUpdate == nil { - x.RollingUpdate = new(RollingUpdateDeployment) - } - x.RollingUpdate.CodecDecodeSelf(d) - } - for { - yyj390++ - if yyhl390 { - yyb390 = yyj390 > l - } else { - yyb390 = r.CheckBreak() - } - if yyb390 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj390-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x DeploymentStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym393 := z.EncBinary() - _ = yym393 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *DeploymentStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym394 := z.DecBinary() - _ = yym394 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym395 := z.EncBinary() - _ = yym395 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep396 := !z.EncBinary() - yy2arr396 := z.EncBasicHandle().StructToArray - var yyq396 [2]bool - _, _, _ = yysep396, yyq396, yy2arr396 - const yyr396 bool = false - yyq396[0] = true - yyq396[1] = true - var yynn396 int - if yyr396 || yy2arr396 { - r.EncodeArrayStart(2) - } else { - yynn396 = 0 - for _, b := range yyq396 { - if b { - yynn396++ - } - } - r.EncodeMapStart(yynn396) - yynn396 = 0 - } - if yyr396 || yy2arr396 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq396[0] { - yy398 := &x.MaxUnavailable - yym399 := z.EncBinary() - _ = yym399 - if false { - } else if z.HasExtensions() && z.EncExt(yy398) { - } else if !yym399 && z.IsJSONHandle() { - z.EncJSONMarshal(yy398) - } else { - z.EncFallback(yy398) - } - } else { - r.EncodeNil() - } - } else { - if yyq396[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy400 := &x.MaxUnavailable - yym401 := z.EncBinary() - _ = yym401 - if false { - } else if z.HasExtensions() && z.EncExt(yy400) { - } else if !yym401 && z.IsJSONHandle() { - z.EncJSONMarshal(yy400) - } else { - z.EncFallback(yy400) - } - } - } - if yyr396 || yy2arr396 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq396[1] { - yy403 := &x.MaxSurge - yym404 := z.EncBinary() - _ = yym404 - if false { - } else if z.HasExtensions() && z.EncExt(yy403) { - } else if !yym404 && z.IsJSONHandle() { - z.EncJSONMarshal(yy403) - } else { - z.EncFallback(yy403) - } - } else { - r.EncodeNil() - } - } else { - if yyq396[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy405 := &x.MaxSurge - yym406 := z.EncBinary() - _ = yym406 - if false { - } else if z.HasExtensions() && z.EncExt(yy405) { - } else if !yym406 && z.IsJSONHandle() { - z.EncJSONMarshal(yy405) - } else { - z.EncFallback(yy405) - } - } - } - if yyr396 || yy2arr396 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *RollingUpdateDeployment) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym407 := z.DecBinary() - _ = yym407 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct408 := r.ContainerType() - if yyct408 == codecSelferValueTypeMap1234 { - yyl408 := r.ReadMapStart() - if yyl408 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl408, d) - } - } else if yyct408 == codecSelferValueTypeArray1234 { - yyl408 := r.ReadArrayStart() - if yyl408 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl408, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys409Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys409Slc - var yyhl409 bool = l >= 0 - for yyj409 := 0; ; yyj409++ { - if yyhl409 { - if yyj409 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys409Slc = r.DecodeBytes(yys409Slc, true, true) - yys409 := string(yys409Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys409 { - case "maxUnavailable": - if r.TryDecodeAsNil() { - x.MaxUnavailable = pkg5_intstr.IntOrString{} - } else { - yyv410 := &x.MaxUnavailable - yym411 := z.DecBinary() - _ = yym411 - if false { - } else if z.HasExtensions() && z.DecExt(yyv410) { - } else if !yym411 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv410) - } else { - z.DecFallback(yyv410, false) - } - } - case "maxSurge": - if r.TryDecodeAsNil() { - x.MaxSurge = pkg5_intstr.IntOrString{} - } else { - yyv412 := &x.MaxSurge - yym413 := z.DecBinary() - _ = yym413 - if false { - } else if z.HasExtensions() && z.DecExt(yyv412) { - } else if !yym413 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv412) - } else { - z.DecFallback(yyv412, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys409) - } // end switch yys409 - } // end for yyj409 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj414 int - var yyb414 bool - var yyhl414 bool = l >= 0 - yyj414++ - if yyhl414 { - yyb414 = yyj414 > l - } else { - yyb414 = r.CheckBreak() - } - if yyb414 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MaxUnavailable = pkg5_intstr.IntOrString{} - } else { - yyv415 := &x.MaxUnavailable - yym416 := z.DecBinary() - _ = yym416 - if false { - } else if z.HasExtensions() && z.DecExt(yyv415) { - } else if !yym416 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv415) - } else { - z.DecFallback(yyv415, false) - } - } - yyj414++ - if yyhl414 { - yyb414 = yyj414 > l - } else { - yyb414 = r.CheckBreak() - } - if yyb414 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MaxSurge = pkg5_intstr.IntOrString{} - } else { - yyv417 := &x.MaxSurge - yym418 := z.DecBinary() - _ = yym418 - if false { - } else if z.HasExtensions() && z.DecExt(yyv417) { - } else if !yym418 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv417) - } else { - z.DecFallback(yyv417, false) - } - } - for { - yyj414++ - if yyhl414 { - yyb414 = yyj414 > l - } else { - yyb414 = r.CheckBreak() - } - if yyb414 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj414-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym419 := z.EncBinary() - _ = yym419 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep420 := !z.EncBinary() - yy2arr420 := z.EncBasicHandle().StructToArray - var yyq420 [6]bool - _, _, _ = yysep420, yyq420, yy2arr420 - const yyr420 bool = false - yyq420[0] = x.ObservedGeneration != 0 - yyq420[1] = x.Replicas != 0 - yyq420[2] = x.UpdatedReplicas != 0 - yyq420[3] = x.AvailableReplicas != 0 - yyq420[4] = x.UnavailableReplicas != 0 - yyq420[5] = len(x.Conditions) != 0 - var yynn420 int - if yyr420 || yy2arr420 { - r.EncodeArrayStart(6) - } else { - yynn420 = 0 - for _, b := range yyq420 { - if b { - yynn420++ - } - } - r.EncodeMapStart(yynn420) - yynn420 = 0 - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq420[0] { - yym422 := z.EncBinary() - _ = yym422 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq420[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym423 := z.EncBinary() - _ = yym423 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq420[1] { - yym425 := z.EncBinary() - _ = yym425 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq420[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym426 := z.EncBinary() - _ = yym426 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq420[2] { - yym428 := z.EncBinary() - _ = yym428 - if false { - } else { - r.EncodeInt(int64(x.UpdatedReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq420[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("updatedReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym429 := z.EncBinary() - _ = yym429 - if false { - } else { - r.EncodeInt(int64(x.UpdatedReplicas)) - } - } - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq420[3] { - yym431 := z.EncBinary() - _ = yym431 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq420[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym432 := z.EncBinary() - _ = yym432 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq420[4] { - yym434 := z.EncBinary() - _ = yym434 - if false { - } else { - r.EncodeInt(int64(x.UnavailableReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq420[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("unavailableReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym435 := z.EncBinary() - _ = yym435 - if false { - } else { - r.EncodeInt(int64(x.UnavailableReplicas)) - } - } - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq420[5] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym437 := z.EncBinary() - _ = yym437 - if false { - } else { - h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq420[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym438 := z.EncBinary() - _ = yym438 - if false { - } else { - h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) - } - } - } - } - if yyr420 || yy2arr420 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym439 := z.DecBinary() - _ = yym439 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct440 := r.ContainerType() - if yyct440 == codecSelferValueTypeMap1234 { - yyl440 := r.ReadMapStart() - if yyl440 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl440, d) - } - } else if yyct440 == codecSelferValueTypeArray1234 { - yyl440 := r.ReadArrayStart() - if yyl440 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl440, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys441Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys441Slc - var yyhl441 bool = l >= 0 - for yyj441 := 0; ; yyj441++ { - if yyhl441 { - if yyj441 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys441Slc = r.DecodeBytes(yys441Slc, true, true) - yys441 := string(yys441Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys441 { - case "observedGeneration": - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "updatedReplicas": - if r.TryDecodeAsNil() { - x.UpdatedReplicas = 0 - } else { - x.UpdatedReplicas = int32(r.DecodeInt(32)) - } - case "availableReplicas": - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - case "unavailableReplicas": - if r.TryDecodeAsNil() { - x.UnavailableReplicas = 0 - } else { - x.UnavailableReplicas = int32(r.DecodeInt(32)) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv447 := &x.Conditions - yym448 := z.DecBinary() - _ = yym448 - if false { - } else { - h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv447), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys441) - } // end switch yys441 - } // end for yyj441 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj449 int - var yyb449 bool - var yyhl449 bool = l >= 0 - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UpdatedReplicas = 0 - } else { - x.UpdatedReplicas = int32(r.DecodeInt(32)) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UnavailableReplicas = 0 - } else { - x.UnavailableReplicas = int32(r.DecodeInt(32)) - } - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv455 := &x.Conditions - yym456 := z.DecBinary() - _ = yym456 - if false { - } else { - h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv455), d) - } - } - for { - yyj449++ - if yyhl449 { - yyb449 = yyj449 > l - } else { - yyb449 = r.CheckBreak() - } - if yyb449 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj449-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x DeploymentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym457 := z.EncBinary() - _ = yym457 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *DeploymentConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym458 := z.DecBinary() - _ = yym458 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *DeploymentCondition) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym459 := z.EncBinary() - _ = yym459 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep460 := !z.EncBinary() - yy2arr460 := z.EncBasicHandle().StructToArray - var yyq460 [6]bool - _, _, _ = yysep460, yyq460, yy2arr460 - const yyr460 bool = false - yyq460[2] = true - yyq460[3] = true - yyq460[4] = x.Reason != "" - yyq460[5] = x.Message != "" - var yynn460 int - if yyr460 || yy2arr460 { - r.EncodeArrayStart(6) - } else { - yynn460 = 2 - for _, b := range yyq460 { - if b { - yynn460++ - } - } - r.EncodeMapStart(yynn460) - yynn460 = 0 - } - if yyr460 || yy2arr460 { - 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 yyr460 || yy2arr460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym463 := z.EncBinary() - _ = yym463 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym464 := z.EncBinary() - _ = yym464 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } - if yyr460 || yy2arr460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq460[2] { - yy466 := &x.LastUpdateTime - yym467 := z.EncBinary() - _ = yym467 - if false { - } else if z.HasExtensions() && z.EncExt(yy466) { - } else if yym467 { - z.EncBinaryMarshal(yy466) - } else if !yym467 && z.IsJSONHandle() { - z.EncJSONMarshal(yy466) - } else { - z.EncFallback(yy466) - } - } else { - r.EncodeNil() - } - } else { - if yyq460[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy468 := &x.LastUpdateTime - yym469 := z.EncBinary() - _ = yym469 - if false { - } else if z.HasExtensions() && z.EncExt(yy468) { - } else if yym469 { - z.EncBinaryMarshal(yy468) - } else if !yym469 && z.IsJSONHandle() { - z.EncJSONMarshal(yy468) - } else { - z.EncFallback(yy468) - } - } - } - if yyr460 || yy2arr460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq460[3] { - yy471 := &x.LastTransitionTime - yym472 := z.EncBinary() - _ = yym472 - if false { - } else if z.HasExtensions() && z.EncExt(yy471) { - } else if yym472 { - z.EncBinaryMarshal(yy471) - } else if !yym472 && z.IsJSONHandle() { - z.EncJSONMarshal(yy471) - } else { - z.EncFallback(yy471) - } - } else { - r.EncodeNil() - } - } else { - if yyq460[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy473 := &x.LastTransitionTime - yym474 := z.EncBinary() - _ = yym474 - if false { - } else if z.HasExtensions() && z.EncExt(yy473) { - } else if yym474 { - z.EncBinaryMarshal(yy473) - } else if !yym474 && z.IsJSONHandle() { - z.EncJSONMarshal(yy473) - } else { - z.EncFallback(yy473) - } - } - } - if yyr460 || yy2arr460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq460[4] { - yym476 := z.EncBinary() - _ = yym476 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq460[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym477 := z.EncBinary() - _ = yym477 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr460 || yy2arr460 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq460[5] { - yym479 := z.EncBinary() - _ = yym479 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq460[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym480 := z.EncBinary() - _ = yym480 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr460 || yy2arr460 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym481 := z.DecBinary() - _ = yym481 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct482 := r.ContainerType() - if yyct482 == codecSelferValueTypeMap1234 { - yyl482 := r.ReadMapStart() - if yyl482 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl482, d) - } - } else if yyct482 == codecSelferValueTypeArray1234 { - yyl482 := r.ReadArrayStart() - if yyl482 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl482, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys483Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys483Slc - var yyhl483 bool = l >= 0 - for yyj483 := 0; ; yyj483++ { - if yyhl483 { - if yyj483 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys483Slc = r.DecodeBytes(yys483Slc, true, true) - yys483 := string(yys483Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys483 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_api.ConditionStatus(r.DecodeString()) - } - case "lastUpdateTime": - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv486 := &x.LastUpdateTime - yym487 := z.DecBinary() - _ = yym487 - if false { - } else if z.HasExtensions() && z.DecExt(yyv486) { - } else if yym487 { - z.DecBinaryUnmarshal(yyv486) - } else if !yym487 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv486) - } else { - z.DecFallback(yyv486, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv488 := &x.LastTransitionTime - yym489 := z.DecBinary() - _ = yym489 - if false { - } else if z.HasExtensions() && z.DecExt(yyv488) { - } else if yym489 { - z.DecBinaryUnmarshal(yyv488) - } else if !yym489 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv488) - } else { - z.DecFallback(yyv488, 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, yys483) - } // end switch yys483 - } // end for yyj483 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj492 int - var yyb492 bool - var yyhl492 bool = l >= 0 - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentConditionType(r.DecodeString()) - } - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_api.ConditionStatus(r.DecodeString()) - } - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv495 := &x.LastUpdateTime - yym496 := z.DecBinary() - _ = yym496 - if false { - } else if z.HasExtensions() && z.DecExt(yyv495) { - } else if yym496 { - z.DecBinaryUnmarshal(yyv495) - } else if !yym496 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv495) - } else { - z.DecFallback(yyv495, false) - } - } - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv497 := &x.LastTransitionTime - yym498 := z.DecBinary() - _ = yym498 - if false { - } else if z.HasExtensions() && z.DecExt(yyv497) { - } else if yym498 { - z.DecBinaryUnmarshal(yyv497) - } else if !yym498 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv497) - } else { - z.DecFallback(yyv497, false) - } - } - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj492++ - if yyhl492 { - yyb492 = yyj492 > l - } else { - yyb492 = r.CheckBreak() - } - if yyb492 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj492-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym501 := z.EncBinary() - _ = yym501 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep502 := !z.EncBinary() - yy2arr502 := z.EncBasicHandle().StructToArray - var yyq502 [4]bool - _, _, _ = yysep502, yyq502, yy2arr502 - const yyr502 bool = false - yyq502[0] = x.Kind != "" - yyq502[1] = x.APIVersion != "" - yyq502[2] = true - var yynn502 int - if yyr502 || yy2arr502 { - r.EncodeArrayStart(4) - } else { - yynn502 = 1 - for _, b := range yyq502 { - if b { - yynn502++ - } - } - r.EncodeMapStart(yynn502) - yynn502 = 0 - } - if yyr502 || yy2arr502 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq502[0] { - yym504 := z.EncBinary() - _ = yym504 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq502[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym505 := z.EncBinary() - _ = yym505 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr502 || yy2arr502 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq502[1] { - yym507 := z.EncBinary() - _ = yym507 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq502[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym508 := z.EncBinary() - _ = yym508 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr502 || yy2arr502 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq502[2] { - yy510 := &x.ListMeta - yym511 := z.EncBinary() - _ = yym511 - if false { - } else if z.HasExtensions() && z.EncExt(yy510) { - } else { - z.EncFallback(yy510) - } - } else { - r.EncodeNil() - } - } else { - if yyq502[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy512 := &x.ListMeta - yym513 := z.EncBinary() - _ = yym513 - if false { - } else if z.HasExtensions() && z.EncExt(yy512) { - } else { - z.EncFallback(yy512) - } - } - } - if yyr502 || yy2arr502 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym515 := z.EncBinary() - _ = yym515 - if false { - } else { - h.encSliceDeployment(([]Deployment)(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 { - yym516 := z.EncBinary() - _ = yym516 - if false { - } else { - h.encSliceDeployment(([]Deployment)(x.Items), e) - } - } - } - if yyr502 || yy2arr502 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym517 := z.DecBinary() - _ = yym517 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct518 := r.ContainerType() - if yyct518 == codecSelferValueTypeMap1234 { - yyl518 := r.ReadMapStart() - if yyl518 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl518, d) - } - } else if yyct518 == codecSelferValueTypeArray1234 { - yyl518 := r.ReadArrayStart() - if yyl518 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl518, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys519Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys519Slc - var yyhl519 bool = l >= 0 - for yyj519 := 0; ; yyj519++ { - if yyhl519 { - if yyj519 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys519Slc = r.DecodeBytes(yys519Slc, true, true) - yys519 := string(yys519Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys519 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv522 := &x.ListMeta - yym523 := z.DecBinary() - _ = yym523 - if false { - } else if z.HasExtensions() && z.DecExt(yyv522) { - } else { - z.DecFallback(yyv522, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv524 := &x.Items - yym525 := z.DecBinary() - _ = yym525 - if false { - } else { - h.decSliceDeployment((*[]Deployment)(yyv524), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys519) - } // end switch yys519 - } // end for yyj519 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj526 int - var yyb526 bool - var yyhl526 bool = l >= 0 - yyj526++ - if yyhl526 { - yyb526 = yyj526 > l - } else { - yyb526 = r.CheckBreak() - } - if yyb526 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj526++ - if yyhl526 { - yyb526 = yyj526 > l - } else { - yyb526 = r.CheckBreak() - } - if yyb526 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj526++ - if yyhl526 { - yyb526 = yyj526 > l - } else { - yyb526 = r.CheckBreak() - } - if yyb526 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv529 := &x.ListMeta - yym530 := z.DecBinary() - _ = yym530 - if false { - } else if z.HasExtensions() && z.DecExt(yyv529) { - } else { - z.DecFallback(yyv529, false) - } - } - yyj526++ - if yyhl526 { - yyb526 = yyj526 > l - } else { - yyb526 = r.CheckBreak() - } - if yyb526 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv531 := &x.Items - yym532 := z.DecBinary() - _ = yym532 - if false { - } else { - h.decSliceDeployment((*[]Deployment)(yyv531), d) - } - } - for { - yyj526++ - if yyhl526 { - yyb526 = yyj526 > l - } else { - yyb526 = r.CheckBreak() - } - if yyb526 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj526-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DaemonSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym533 := z.EncBinary() - _ = yym533 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep534 := !z.EncBinary() - yy2arr534 := z.EncBasicHandle().StructToArray - var yyq534 [2]bool - _, _, _ = yysep534, yyq534, yy2arr534 - const yyr534 bool = false - yyq534[0] = x.Selector != nil - var yynn534 int - if yyr534 || yy2arr534 { - r.EncodeArrayStart(2) - } else { - yynn534 = 1 - for _, b := range yyq534 { - if b { - yynn534++ - } - } - r.EncodeMapStart(yynn534) - yynn534 = 0 - } - if yyr534 || yy2arr534 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq534[0] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym536 := z.EncBinary() - _ = yym536 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq534[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym537 := z.EncBinary() - _ = yym537 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr534 || yy2arr534 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy539 := &x.Template - yy539.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy540 := &x.Template - yy540.CodecEncodeSelf(e) - } - if yyr534 || yy2arr534 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DaemonSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym541 := z.DecBinary() - _ = yym541 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct542 := r.ContainerType() - if yyct542 == codecSelferValueTypeMap1234 { - yyl542 := r.ReadMapStart() - if yyl542 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl542, d) - } - } else if yyct542 == codecSelferValueTypeArray1234 { - yyl542 := r.ReadArrayStart() - if yyl542 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl542, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DaemonSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys543Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys543Slc - var yyhl543 bool = l >= 0 - for yyj543 := 0; ; yyj543++ { - if yyhl543 { - if yyj543 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys543Slc = r.DecodeBytes(yys543Slc, true, true) - yys543 := string(yys543Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys543 { - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym545 := z.DecBinary() - _ = yym545 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv546 := &x.Template - yyv546.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys543) - } // end switch yys543 - } // end for yyj543 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DaemonSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj547 int - var yyb547 bool - var yyhl547 bool = l >= 0 - yyj547++ - if yyhl547 { - yyb547 = yyj547 > l - } else { - yyb547 = r.CheckBreak() - } - if yyb547 { - 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(pkg1_unversioned.LabelSelector) - } - yym549 := z.DecBinary() - _ = yym549 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj547++ - if yyhl547 { - yyb547 = yyj547 > l - } else { - yyb547 = r.CheckBreak() - } - if yyb547 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv550 := &x.Template - yyv550.CodecDecodeSelf(d) - } - for { - yyj547++ - if yyhl547 { - yyb547 = yyj547 > l - } else { - yyb547 = r.CheckBreak() - } - if yyb547 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj547-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DaemonSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym551 := z.EncBinary() - _ = yym551 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep552 := !z.EncBinary() - yy2arr552 := z.EncBasicHandle().StructToArray - var yyq552 [4]bool - _, _, _ = yysep552, yyq552, yy2arr552 - const yyr552 bool = false - var yynn552 int - if yyr552 || yy2arr552 { - r.EncodeArrayStart(4) - } else { - yynn552 = 4 - for _, b := range yyq552 { - if b { - yynn552++ - } - } - r.EncodeMapStart(yynn552) - yynn552 = 0 - } - if yyr552 || yy2arr552 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym554 := z.EncBinary() - _ = yym554 - if false { - } else { - r.EncodeInt(int64(x.CurrentNumberScheduled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentNumberScheduled")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym555 := z.EncBinary() - _ = yym555 - if false { - } else { - r.EncodeInt(int64(x.CurrentNumberScheduled)) - } - } - if yyr552 || yy2arr552 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym557 := z.EncBinary() - _ = yym557 - if false { - } else { - r.EncodeInt(int64(x.NumberMisscheduled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("numberMisscheduled")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym558 := z.EncBinary() - _ = yym558 - if false { - } else { - r.EncodeInt(int64(x.NumberMisscheduled)) - } - } - if yyr552 || yy2arr552 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym560 := z.EncBinary() - _ = yym560 - if false { - } else { - r.EncodeInt(int64(x.DesiredNumberScheduled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("desiredNumberScheduled")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym561 := z.EncBinary() - _ = yym561 - if false { - } else { - r.EncodeInt(int64(x.DesiredNumberScheduled)) - } - } - if yyr552 || yy2arr552 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym563 := z.EncBinary() - _ = yym563 - if false { - } else { - r.EncodeInt(int64(x.NumberReady)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("numberReady")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym564 := z.EncBinary() - _ = yym564 - if false { - } else { - r.EncodeInt(int64(x.NumberReady)) - } - } - if yyr552 || yy2arr552 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DaemonSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym565 := z.DecBinary() - _ = yym565 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct566 := r.ContainerType() - if yyct566 == codecSelferValueTypeMap1234 { - yyl566 := r.ReadMapStart() - if yyl566 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl566, d) - } - } else if yyct566 == codecSelferValueTypeArray1234 { - yyl566 := r.ReadArrayStart() - if yyl566 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl566, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DaemonSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys567Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys567Slc - var yyhl567 bool = l >= 0 - for yyj567 := 0; ; yyj567++ { - if yyhl567 { - if yyj567 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys567Slc = r.DecodeBytes(yys567Slc, true, true) - yys567 := string(yys567Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys567 { - case "currentNumberScheduled": - if r.TryDecodeAsNil() { - x.CurrentNumberScheduled = 0 - } else { - x.CurrentNumberScheduled = int32(r.DecodeInt(32)) - } - case "numberMisscheduled": - if r.TryDecodeAsNil() { - x.NumberMisscheduled = 0 - } else { - x.NumberMisscheduled = int32(r.DecodeInt(32)) - } - case "desiredNumberScheduled": - if r.TryDecodeAsNil() { - x.DesiredNumberScheduled = 0 - } else { - x.DesiredNumberScheduled = int32(r.DecodeInt(32)) - } - case "numberReady": - if r.TryDecodeAsNil() { - x.NumberReady = 0 - } else { - x.NumberReady = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys567) - } // end switch yys567 - } // end for yyj567 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DaemonSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj572 int - var yyb572 bool - var yyhl572 bool = l >= 0 - yyj572++ - if yyhl572 { - yyb572 = yyj572 > l - } else { - yyb572 = r.CheckBreak() - } - if yyb572 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CurrentNumberScheduled = 0 - } else { - x.CurrentNumberScheduled = int32(r.DecodeInt(32)) - } - yyj572++ - if yyhl572 { - yyb572 = yyj572 > l - } else { - yyb572 = r.CheckBreak() - } - if yyb572 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NumberMisscheduled = 0 - } else { - x.NumberMisscheduled = int32(r.DecodeInt(32)) - } - yyj572++ - if yyhl572 { - yyb572 = yyj572 > l - } else { - yyb572 = r.CheckBreak() - } - if yyb572 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DesiredNumberScheduled = 0 - } else { - x.DesiredNumberScheduled = int32(r.DecodeInt(32)) - } - yyj572++ - if yyhl572 { - yyb572 = yyj572 > l - } else { - yyb572 = r.CheckBreak() - } - if yyb572 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.NumberReady = 0 - } else { - x.NumberReady = int32(r.DecodeInt(32)) - } - for { - yyj572++ - if yyhl572 { - yyb572 = yyj572 > l - } else { - yyb572 = r.CheckBreak() - } - if yyb572 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj572-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DaemonSet) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym577 := z.EncBinary() - _ = yym577 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep578 := !z.EncBinary() - yy2arr578 := z.EncBasicHandle().StructToArray - var yyq578 [5]bool - _, _, _ = yysep578, yyq578, yy2arr578 - const yyr578 bool = false - yyq578[0] = x.Kind != "" - yyq578[1] = x.APIVersion != "" - yyq578[2] = true - yyq578[3] = true - yyq578[4] = true - var yynn578 int - if yyr578 || yy2arr578 { - r.EncodeArrayStart(5) - } else { - yynn578 = 0 - for _, b := range yyq578 { - if b { - yynn578++ - } - } - r.EncodeMapStart(yynn578) - yynn578 = 0 - } - if yyr578 || yy2arr578 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq578[0] { - yym580 := z.EncBinary() - _ = yym580 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq578[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym581 := z.EncBinary() - _ = yym581 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr578 || yy2arr578 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq578[1] { - yym583 := z.EncBinary() - _ = yym583 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq578[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym584 := z.EncBinary() - _ = yym584 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr578 || yy2arr578 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq578[2] { - yy586 := &x.ObjectMeta - yy586.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq578[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy587 := &x.ObjectMeta - yy587.CodecEncodeSelf(e) - } - } - if yyr578 || yy2arr578 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq578[3] { - yy589 := &x.Spec - yy589.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq578[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy590 := &x.Spec - yy590.CodecEncodeSelf(e) - } - } - if yyr578 || yy2arr578 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq578[4] { - yy592 := &x.Status - yy592.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq578[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy593 := &x.Status - yy593.CodecEncodeSelf(e) - } - } - if yyr578 || yy2arr578 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DaemonSet) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym594 := z.DecBinary() - _ = yym594 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct595 := r.ContainerType() - if yyct595 == codecSelferValueTypeMap1234 { - yyl595 := r.ReadMapStart() - if yyl595 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl595, d) - } - } else if yyct595 == codecSelferValueTypeArray1234 { - yyl595 := r.ReadArrayStart() - if yyl595 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl595, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DaemonSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys596Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys596Slc - var yyhl596 bool = l >= 0 - for yyj596 := 0; ; yyj596++ { - if yyhl596 { - if yyj596 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys596Slc = r.DecodeBytes(yys596Slc, true, true) - yys596 := string(yys596Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys596 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv599 := &x.ObjectMeta - yyv599.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = DaemonSetSpec{} - } else { - yyv600 := &x.Spec - yyv600.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = DaemonSetStatus{} - } else { - yyv601 := &x.Status - yyv601.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys596) - } // end switch yys596 - } // end for yyj596 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DaemonSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj602 int - var yyb602 bool - var yyhl602 bool = l >= 0 - yyj602++ - if yyhl602 { - yyb602 = yyj602 > l - } else { - yyb602 = r.CheckBreak() - } - if yyb602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj602++ - if yyhl602 { - yyb602 = yyj602 > l - } else { - yyb602 = r.CheckBreak() - } - if yyb602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj602++ - if yyhl602 { - yyb602 = yyj602 > l - } else { - yyb602 = r.CheckBreak() - } - if yyb602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv605 := &x.ObjectMeta - yyv605.CodecDecodeSelf(d) - } - yyj602++ - if yyhl602 { - yyb602 = yyj602 > l - } else { - yyb602 = r.CheckBreak() - } - if yyb602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = DaemonSetSpec{} - } else { - yyv606 := &x.Spec - yyv606.CodecDecodeSelf(d) - } - yyj602++ - if yyhl602 { - yyb602 = yyj602 > l - } else { - yyb602 = r.CheckBreak() - } - if yyb602 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = DaemonSetStatus{} - } else { - yyv607 := &x.Status - yyv607.CodecDecodeSelf(d) - } - for { - yyj602++ - if yyhl602 { - yyb602 = yyj602 > l - } else { - yyb602 = r.CheckBreak() - } - if yyb602 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj602-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym608 := z.EncBinary() - _ = yym608 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep609 := !z.EncBinary() - yy2arr609 := z.EncBasicHandle().StructToArray - var yyq609 [4]bool - _, _, _ = yysep609, yyq609, yy2arr609 - const yyr609 bool = false - yyq609[0] = x.Kind != "" - yyq609[1] = x.APIVersion != "" - yyq609[2] = true - var yynn609 int - if yyr609 || yy2arr609 { - r.EncodeArrayStart(4) - } else { - yynn609 = 1 - for _, b := range yyq609 { - if b { - yynn609++ - } - } - r.EncodeMapStart(yynn609) - yynn609 = 0 - } - if yyr609 || yy2arr609 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq609[0] { - yym611 := z.EncBinary() - _ = yym611 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq609[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym612 := z.EncBinary() - _ = yym612 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr609 || yy2arr609 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq609[1] { - yym614 := z.EncBinary() - _ = yym614 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq609[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym615 := z.EncBinary() - _ = yym615 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr609 || yy2arr609 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq609[2] { - yy617 := &x.ListMeta - yym618 := z.EncBinary() - _ = yym618 - if false { - } else if z.HasExtensions() && z.EncExt(yy617) { - } else { - z.EncFallback(yy617) - } - } else { - r.EncodeNil() - } - } else { - if yyq609[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy619 := &x.ListMeta - yym620 := z.EncBinary() - _ = yym620 - if false { - } else if z.HasExtensions() && z.EncExt(yy619) { - } else { - z.EncFallback(yy619) - } - } - } - if yyr609 || yy2arr609 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym622 := z.EncBinary() - _ = yym622 - if false { - } else { - h.encSliceDaemonSet(([]DaemonSet)(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 { - yym623 := z.EncBinary() - _ = yym623 - if false { - } else { - h.encSliceDaemonSet(([]DaemonSet)(x.Items), e) - } - } - } - if yyr609 || yy2arr609 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DaemonSetList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym624 := z.DecBinary() - _ = yym624 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct625 := r.ContainerType() - if yyct625 == codecSelferValueTypeMap1234 { - yyl625 := r.ReadMapStart() - if yyl625 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl625, d) - } - } else if yyct625 == codecSelferValueTypeArray1234 { - yyl625 := r.ReadArrayStart() - if yyl625 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl625, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DaemonSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys626Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys626Slc - var yyhl626 bool = l >= 0 - for yyj626 := 0; ; yyj626++ { - if yyhl626 { - if yyj626 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys626Slc = r.DecodeBytes(yys626Slc, true, true) - yys626 := string(yys626Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys626 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv629 := &x.ListMeta - yym630 := z.DecBinary() - _ = yym630 - if false { - } else if z.HasExtensions() && z.DecExt(yyv629) { - } else { - z.DecFallback(yyv629, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv631 := &x.Items - yym632 := z.DecBinary() - _ = yym632 - if false { - } else { - h.decSliceDaemonSet((*[]DaemonSet)(yyv631), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys626) - } // end switch yys626 - } // end for yyj626 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DaemonSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj633 int - var yyb633 bool - var yyhl633 bool = l >= 0 - yyj633++ - if yyhl633 { - yyb633 = yyj633 > l - } else { - yyb633 = r.CheckBreak() - } - if yyb633 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj633++ - if yyhl633 { - yyb633 = yyj633 > l - } else { - yyb633 = r.CheckBreak() - } - if yyb633 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj633++ - if yyhl633 { - yyb633 = yyj633 > l - } else { - yyb633 = r.CheckBreak() - } - if yyb633 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv636 := &x.ListMeta - yym637 := z.DecBinary() - _ = yym637 - if false { - } else if z.HasExtensions() && z.DecExt(yyv636) { - } else { - z.DecFallback(yyv636, false) - } - } - yyj633++ - if yyhl633 { - yyb633 = yyj633 > l - } else { - yyb633 = r.CheckBreak() - } - if yyb633 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv638 := &x.Items - yym639 := z.DecBinary() - _ = yym639 - if false { - } else { - h.decSliceDaemonSet((*[]DaemonSet)(yyv638), d) - } - } - for { - yyj633++ - if yyhl633 { - yyb633 = yyj633 > l - } else { - yyb633 = r.CheckBreak() - } - if yyb633 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj633-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ThirdPartyResourceDataList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym640 := z.EncBinary() - _ = yym640 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep641 := !z.EncBinary() - yy2arr641 := z.EncBasicHandle().StructToArray - var yyq641 [4]bool - _, _, _ = yysep641, yyq641, yy2arr641 - const yyr641 bool = false - yyq641[0] = x.Kind != "" - yyq641[1] = x.APIVersion != "" - yyq641[2] = true - var yynn641 int - if yyr641 || yy2arr641 { - r.EncodeArrayStart(4) - } else { - yynn641 = 1 - for _, b := range yyq641 { - if b { - yynn641++ - } - } - r.EncodeMapStart(yynn641) - yynn641 = 0 - } - if yyr641 || yy2arr641 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq641[0] { - yym643 := z.EncBinary() - _ = yym643 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq641[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym644 := z.EncBinary() - _ = yym644 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr641 || yy2arr641 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq641[1] { - yym646 := z.EncBinary() - _ = yym646 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq641[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym647 := z.EncBinary() - _ = yym647 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr641 || yy2arr641 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq641[2] { - yy649 := &x.ListMeta - yym650 := z.EncBinary() - _ = yym650 - if false { - } else if z.HasExtensions() && z.EncExt(yy649) { - } else { - z.EncFallback(yy649) - } - } else { - r.EncodeNil() - } - } else { - if yyq641[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy651 := &x.ListMeta - yym652 := z.EncBinary() - _ = yym652 - if false { - } else if z.HasExtensions() && z.EncExt(yy651) { - } else { - z.EncFallback(yy651) - } - } - } - if yyr641 || yy2arr641 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym654 := z.EncBinary() - _ = yym654 - if false { - } else { - h.encSliceThirdPartyResourceData(([]ThirdPartyResourceData)(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 { - yym655 := z.EncBinary() - _ = yym655 - if false { - } else { - h.encSliceThirdPartyResourceData(([]ThirdPartyResourceData)(x.Items), e) - } - } - } - if yyr641 || yy2arr641 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ThirdPartyResourceDataList) 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 *ThirdPartyResourceDataList) 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 "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 = pkg1_unversioned.ListMeta{} - } else { - yyv661 := &x.ListMeta - yym662 := z.DecBinary() - _ = yym662 - if false { - } else if z.HasExtensions() && z.DecExt(yyv661) { - } else { - z.DecFallback(yyv661, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv663 := &x.Items - yym664 := z.DecBinary() - _ = yym664 - if false { - } else { - h.decSliceThirdPartyResourceData((*[]ThirdPartyResourceData)(yyv663), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys658) - } // end switch yys658 - } // end for yyj658 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ThirdPartyResourceDataList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj665 int - var yyb665 bool - var yyhl665 bool = l >= 0 - yyj665++ - if yyhl665 { - yyb665 = yyj665 > l - } else { - yyb665 = r.CheckBreak() - } - if yyb665 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj665++ - if yyhl665 { - yyb665 = yyj665 > l - } else { - yyb665 = r.CheckBreak() - } - if yyb665 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj665++ - if yyhl665 { - yyb665 = yyj665 > l - } else { - yyb665 = r.CheckBreak() - } - if yyb665 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv668 := &x.ListMeta - yym669 := z.DecBinary() - _ = yym669 - if false { - } else if z.HasExtensions() && z.DecExt(yyv668) { - } else { - z.DecFallback(yyv668, false) - } - } - yyj665++ - if yyhl665 { - yyb665 = yyj665 > l - } else { - yyb665 = r.CheckBreak() - } - if yyb665 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv670 := &x.Items - yym671 := z.DecBinary() - _ = yym671 - if false { - } else { - h.decSliceThirdPartyResourceData((*[]ThirdPartyResourceData)(yyv670), d) - } - } - for { - yyj665++ - if yyhl665 { - yyb665 = yyj665 > l - } else { - yyb665 = r.CheckBreak() - } - if yyb665 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj665-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *Ingress) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym672 := z.EncBinary() - _ = yym672 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep673 := !z.EncBinary() - yy2arr673 := z.EncBasicHandle().StructToArray - var yyq673 [5]bool - _, _, _ = yysep673, yyq673, yy2arr673 - const yyr673 bool = false - yyq673[0] = x.Kind != "" - yyq673[1] = x.APIVersion != "" - yyq673[2] = true - yyq673[3] = true - yyq673[4] = true - var yynn673 int - if yyr673 || yy2arr673 { - r.EncodeArrayStart(5) - } else { - yynn673 = 0 - for _, b := range yyq673 { - if b { - yynn673++ - } - } - r.EncodeMapStart(yynn673) - yynn673 = 0 - } - if yyr673 || yy2arr673 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq673[0] { - yym675 := z.EncBinary() - _ = yym675 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq673[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym676 := z.EncBinary() - _ = yym676 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr673 || yy2arr673 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq673[1] { - yym678 := z.EncBinary() - _ = yym678 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq673[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym679 := z.EncBinary() - _ = yym679 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr673 || yy2arr673 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq673[2] { - yy681 := &x.ObjectMeta - yy681.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq673[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy682 := &x.ObjectMeta - yy682.CodecEncodeSelf(e) - } - } - if yyr673 || yy2arr673 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq673[3] { - yy684 := &x.Spec - yy684.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq673[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy685 := &x.Spec - yy685.CodecEncodeSelf(e) - } - } - if yyr673 || yy2arr673 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq673[4] { - yy687 := &x.Status - yy687.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq673[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy688 := &x.Status - yy688.CodecEncodeSelf(e) - } - } - if yyr673 || yy2arr673 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Ingress) 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 *Ingress) 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 "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 = pkg2_api.ObjectMeta{} - } else { - yyv694 := &x.ObjectMeta - yyv694.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = IngressSpec{} - } else { - yyv695 := &x.Spec - yyv695.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = IngressStatus{} - } else { - yyv696 := &x.Status - yyv696.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys691) - } // end switch yys691 - } // end for yyj691 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Ingress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj697 int - var yyb697 bool - var yyhl697 bool = l >= 0 - yyj697++ - if yyhl697 { - yyb697 = yyj697 > l - } else { - yyb697 = r.CheckBreak() - } - if yyb697 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj697++ - if yyhl697 { - yyb697 = yyj697 > l - } else { - yyb697 = r.CheckBreak() - } - if yyb697 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj697++ - if yyhl697 { - yyb697 = yyj697 > l - } else { - yyb697 = r.CheckBreak() - } - if yyb697 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv700 := &x.ObjectMeta - yyv700.CodecDecodeSelf(d) - } - yyj697++ - if yyhl697 { - yyb697 = yyj697 > l - } else { - yyb697 = r.CheckBreak() - } - if yyb697 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = IngressSpec{} - } else { - yyv701 := &x.Spec - yyv701.CodecDecodeSelf(d) - } - yyj697++ - if yyhl697 { - yyb697 = yyj697 > l - } else { - yyb697 = r.CheckBreak() - } - if yyb697 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = IngressStatus{} - } else { - yyv702 := &x.Status - yyv702.CodecDecodeSelf(d) - } - for { - yyj697++ - if yyhl697 { - yyb697 = yyj697 > l - } else { - yyb697 = r.CheckBreak() - } - if yyb697 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj697-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym703 := z.EncBinary() - _ = yym703 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep704 := !z.EncBinary() - yy2arr704 := z.EncBasicHandle().StructToArray - var yyq704 [4]bool - _, _, _ = yysep704, yyq704, yy2arr704 - const yyr704 bool = false - yyq704[0] = x.Kind != "" - yyq704[1] = x.APIVersion != "" - yyq704[2] = true - var yynn704 int - if yyr704 || yy2arr704 { - r.EncodeArrayStart(4) - } else { - yynn704 = 1 - for _, b := range yyq704 { - if b { - yynn704++ - } - } - r.EncodeMapStart(yynn704) - yynn704 = 0 - } - if yyr704 || yy2arr704 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq704[0] { - yym706 := z.EncBinary() - _ = yym706 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq704[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym707 := z.EncBinary() - _ = yym707 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr704 || yy2arr704 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq704[1] { - yym709 := z.EncBinary() - _ = yym709 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq704[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym710 := z.EncBinary() - _ = yym710 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr704 || yy2arr704 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq704[2] { - yy712 := &x.ListMeta - yym713 := z.EncBinary() - _ = yym713 - if false { - } else if z.HasExtensions() && z.EncExt(yy712) { - } else { - z.EncFallback(yy712) - } - } else { - r.EncodeNil() - } - } else { - if yyq704[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy714 := &x.ListMeta - yym715 := z.EncBinary() - _ = yym715 - if false { - } else if z.HasExtensions() && z.EncExt(yy714) { - } else { - z.EncFallback(yy714) - } - } - } - if yyr704 || yy2arr704 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym717 := z.EncBinary() - _ = yym717 - if false { - } else { - h.encSliceIngress(([]Ingress)(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 { - yym718 := z.EncBinary() - _ = yym718 - if false { - } else { - h.encSliceIngress(([]Ingress)(x.Items), e) - } - } - } - if yyr704 || yy2arr704 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym719 := z.DecBinary() - _ = yym719 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct720 := r.ContainerType() - if yyct720 == codecSelferValueTypeMap1234 { - yyl720 := r.ReadMapStart() - if yyl720 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl720, d) - } - } else if yyct720 == codecSelferValueTypeArray1234 { - yyl720 := r.ReadArrayStart() - if yyl720 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl720, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IngressList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys721Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys721Slc - var yyhl721 bool = l >= 0 - for yyj721 := 0; ; yyj721++ { - if yyhl721 { - if yyj721 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys721Slc = r.DecodeBytes(yys721Slc, true, true) - yys721 := string(yys721Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys721 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv724 := &x.ListMeta - yym725 := z.DecBinary() - _ = yym725 - if false { - } else if z.HasExtensions() && z.DecExt(yyv724) { - } else { - z.DecFallback(yyv724, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv726 := &x.Items - yym727 := z.DecBinary() - _ = yym727 - if false { - } else { - h.decSliceIngress((*[]Ingress)(yyv726), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys721) - } // end switch yys721 - } // end for yyj721 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj728 int - var yyb728 bool - var yyhl728 bool = l >= 0 - yyj728++ - if yyhl728 { - yyb728 = yyj728 > l - } else { - yyb728 = r.CheckBreak() - } - if yyb728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj728++ - if yyhl728 { - yyb728 = yyj728 > l - } else { - yyb728 = r.CheckBreak() - } - if yyb728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj728++ - if yyhl728 { - yyb728 = yyj728 > l - } else { - yyb728 = r.CheckBreak() - } - if yyb728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv731 := &x.ListMeta - yym732 := z.DecBinary() - _ = yym732 - if false { - } else if z.HasExtensions() && z.DecExt(yyv731) { - } else { - z.DecFallback(yyv731, false) - } - } - yyj728++ - if yyhl728 { - yyb728 = yyj728 > l - } else { - yyb728 = r.CheckBreak() - } - if yyb728 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv733 := &x.Items - yym734 := z.DecBinary() - _ = yym734 - if false { - } else { - h.decSliceIngress((*[]Ingress)(yyv733), d) - } - } - for { - yyj728++ - if yyhl728 { - yyb728 = yyj728 > l - } else { - yyb728 = r.CheckBreak() - } - if yyb728 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj728-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressSpec) 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 [3]bool - _, _, _ = yysep736, yyq736, yy2arr736 - const yyr736 bool = false - yyq736[0] = x.Backend != nil - yyq736[1] = len(x.TLS) != 0 - yyq736[2] = len(x.Rules) != 0 - var yynn736 int - if yyr736 || yy2arr736 { - r.EncodeArrayStart(3) - } else { - yynn736 = 0 - for _, b := range yyq736 { - if b { - yynn736++ - } - } - r.EncodeMapStart(yynn736) - yynn736 = 0 - } - if yyr736 || yy2arr736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq736[0] { - if x.Backend == nil { - r.EncodeNil() - } else { - x.Backend.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq736[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("backend")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Backend == nil { - r.EncodeNil() - } else { - x.Backend.CodecEncodeSelf(e) - } - } - } - if yyr736 || yy2arr736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq736[1] { - if x.TLS == nil { - r.EncodeNil() - } else { - yym739 := z.EncBinary() - _ = yym739 - if false { - } else { - h.encSliceIngressTLS(([]IngressTLS)(x.TLS), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq736[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("tls")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.TLS == nil { - r.EncodeNil() - } else { - yym740 := z.EncBinary() - _ = yym740 - if false { - } else { - h.encSliceIngressTLS(([]IngressTLS)(x.TLS), e) - } - } - } - } - if yyr736 || yy2arr736 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq736[2] { - if x.Rules == nil { - r.EncodeNil() - } else { - yym742 := z.EncBinary() - _ = yym742 - if false { - } else { - h.encSliceIngressRule(([]IngressRule)(x.Rules), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq736[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rules")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Rules == nil { - r.EncodeNil() - } else { - yym743 := z.EncBinary() - _ = yym743 - if false { - } else { - h.encSliceIngressRule(([]IngressRule)(x.Rules), e) - } - } - } - } - if yyr736 || yy2arr736 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym744 := z.DecBinary() - _ = yym744 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct745 := r.ContainerType() - if yyct745 == codecSelferValueTypeMap1234 { - yyl745 := r.ReadMapStart() - if yyl745 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl745, d) - } - } else if yyct745 == codecSelferValueTypeArray1234 { - yyl745 := r.ReadArrayStart() - if yyl745 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl745, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IngressSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys746Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys746Slc - var yyhl746 bool = l >= 0 - for yyj746 := 0; ; yyj746++ { - if yyhl746 { - if yyj746 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys746Slc = r.DecodeBytes(yys746Slc, true, true) - yys746 := string(yys746Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys746 { - case "backend": - if r.TryDecodeAsNil() { - if x.Backend != nil { - x.Backend = nil - } - } else { - if x.Backend == nil { - x.Backend = new(IngressBackend) - } - x.Backend.CodecDecodeSelf(d) - } - case "tls": - if r.TryDecodeAsNil() { - x.TLS = nil - } else { - yyv748 := &x.TLS - yym749 := z.DecBinary() - _ = yym749 - if false { - } else { - h.decSliceIngressTLS((*[]IngressTLS)(yyv748), d) - } - } - case "rules": - if r.TryDecodeAsNil() { - x.Rules = nil - } else { - yyv750 := &x.Rules - yym751 := z.DecBinary() - _ = yym751 - if false { - } else { - h.decSliceIngressRule((*[]IngressRule)(yyv750), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys746) - } // end switch yys746 - } // end for yyj746 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj752 int - var yyb752 bool - var yyhl752 bool = l >= 0 - yyj752++ - if yyhl752 { - yyb752 = yyj752 > l - } else { - yyb752 = r.CheckBreak() - } - if yyb752 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Backend != nil { - x.Backend = nil - } - } else { - if x.Backend == nil { - x.Backend = new(IngressBackend) - } - x.Backend.CodecDecodeSelf(d) - } - yyj752++ - if yyhl752 { - yyb752 = yyj752 > l - } else { - yyb752 = r.CheckBreak() - } - if yyb752 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.TLS = nil - } else { - yyv754 := &x.TLS - yym755 := z.DecBinary() - _ = yym755 - if false { - } else { - h.decSliceIngressTLS((*[]IngressTLS)(yyv754), d) - } - } - yyj752++ - if yyhl752 { - yyb752 = yyj752 > l - } else { - yyb752 = r.CheckBreak() - } - if yyb752 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Rules = nil - } else { - yyv756 := &x.Rules - yym757 := z.DecBinary() - _ = yym757 - if false { - } else { - h.decSliceIngressRule((*[]IngressRule)(yyv756), d) - } - } - for { - yyj752++ - if yyhl752 { - yyb752 = yyj752 > l - } else { - yyb752 = r.CheckBreak() - } - if yyb752 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj752-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressTLS) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym758 := z.EncBinary() - _ = yym758 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep759 := !z.EncBinary() - yy2arr759 := z.EncBasicHandle().StructToArray - var yyq759 [2]bool - _, _, _ = yysep759, yyq759, yy2arr759 - const yyr759 bool = false - yyq759[0] = len(x.Hosts) != 0 - yyq759[1] = x.SecretName != "" - var yynn759 int - if yyr759 || yy2arr759 { - r.EncodeArrayStart(2) - } else { - yynn759 = 0 - for _, b := range yyq759 { - if b { - yynn759++ - } - } - r.EncodeMapStart(yynn759) - yynn759 = 0 - } - if yyr759 || yy2arr759 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq759[0] { - if x.Hosts == nil { - r.EncodeNil() - } else { - yym761 := z.EncBinary() - _ = yym761 - if false { - } else { - z.F.EncSliceStringV(x.Hosts, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq759[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hosts")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Hosts == nil { - r.EncodeNil() - } else { - yym762 := z.EncBinary() - _ = yym762 - if false { - } else { - z.F.EncSliceStringV(x.Hosts, false, e) - } - } - } - } - if yyr759 || yy2arr759 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq759[1] { - yym764 := z.EncBinary() - _ = yym764 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq759[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("secretName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym765 := z.EncBinary() - _ = yym765 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) - } - } - } - if yyr759 || yy2arr759 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressTLS) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym766 := z.DecBinary() - _ = yym766 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct767 := r.ContainerType() - if yyct767 == codecSelferValueTypeMap1234 { - yyl767 := r.ReadMapStart() - if yyl767 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl767, d) - } - } else if yyct767 == codecSelferValueTypeArray1234 { - yyl767 := r.ReadArrayStart() - if yyl767 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl767, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IngressTLS) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys768Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys768Slc - var yyhl768 bool = l >= 0 - for yyj768 := 0; ; yyj768++ { - if yyhl768 { - if yyj768 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys768Slc = r.DecodeBytes(yys768Slc, true, true) - yys768 := string(yys768Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys768 { - case "hosts": - if r.TryDecodeAsNil() { - x.Hosts = nil - } else { - yyv769 := &x.Hosts - yym770 := z.DecBinary() - _ = yym770 - if false { - } else { - z.F.DecSliceStringX(yyv769, false, d) - } - } - case "secretName": - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - default: - z.DecStructFieldNotFound(-1, yys768) - } // end switch yys768 - } // end for yyj768 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressTLS) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj772 int - var yyb772 bool - var yyhl772 bool = l >= 0 - yyj772++ - if yyhl772 { - yyb772 = yyj772 > l - } else { - yyb772 = r.CheckBreak() - } - if yyb772 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Hosts = nil - } else { - yyv773 := &x.Hosts - yym774 := z.DecBinary() - _ = yym774 - if false { - } else { - z.F.DecSliceStringX(yyv773, false, d) - } - } - yyj772++ - if yyhl772 { - yyb772 = yyj772 > l - } else { - yyb772 = r.CheckBreak() - } - if yyb772 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SecretName = "" - } else { - x.SecretName = string(r.DecodeString()) - } - for { - yyj772++ - if yyhl772 { - yyb772 = yyj772 > l - } else { - yyb772 = r.CheckBreak() - } - if yyb772 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj772-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressStatus) 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 [1]bool - _, _, _ = yysep777, yyq777, yy2arr777 - const yyr777 bool = false - yyq777[0] = true - var yynn777 int - if yyr777 || yy2arr777 { - r.EncodeArrayStart(1) - } else { - yynn777 = 0 - for _, b := range yyq777 { - if b { - yynn777++ - } - } - r.EncodeMapStart(yynn777) - yynn777 = 0 - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq777[0] { - yy779 := &x.LoadBalancer - yy779.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq777[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("loadBalancer")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy780 := &x.LoadBalancer - yy780.CodecEncodeSelf(e) - } - } - if yyr777 || yy2arr777 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym781 := z.DecBinary() - _ = yym781 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct782 := r.ContainerType() - if yyct782 == codecSelferValueTypeMap1234 { - yyl782 := r.ReadMapStart() - if yyl782 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl782, d) - } - } else if yyct782 == codecSelferValueTypeArray1234 { - yyl782 := r.ReadArrayStart() - if yyl782 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl782, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IngressStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys783Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys783Slc - var yyhl783 bool = l >= 0 - for yyj783 := 0; ; yyj783++ { - if yyhl783 { - if yyj783 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys783Slc = r.DecodeBytes(yys783Slc, true, true) - yys783 := string(yys783Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys783 { - case "loadBalancer": - if r.TryDecodeAsNil() { - x.LoadBalancer = pkg2_api.LoadBalancerStatus{} - } else { - yyv784 := &x.LoadBalancer - yyv784.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys783) - } // end switch yys783 - } // end for yyj783 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj785 int - var yyb785 bool - var yyhl785 bool = l >= 0 - yyj785++ - if yyhl785 { - yyb785 = yyj785 > l - } else { - yyb785 = r.CheckBreak() - } - if yyb785 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LoadBalancer = pkg2_api.LoadBalancerStatus{} - } else { - yyv786 := &x.LoadBalancer - yyv786.CodecDecodeSelf(d) - } - for { - yyj785++ - if yyhl785 { - yyb785 = yyj785 > l - } else { - yyb785 = r.CheckBreak() - } - if yyb785 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj785-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressRule) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym787 := z.EncBinary() - _ = yym787 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep788 := !z.EncBinary() - yy2arr788 := z.EncBasicHandle().StructToArray - var yyq788 [2]bool - _, _, _ = yysep788, yyq788, yy2arr788 - const yyr788 bool = false - yyq788[0] = x.Host != "" - yyq788[1] = x.IngressRuleValue.HTTP != nil && x.HTTP != nil - var yynn788 int - if yyr788 || yy2arr788 { - r.EncodeArrayStart(2) - } else { - yynn788 = 0 - for _, b := range yyq788 { - if b { - yynn788++ - } - } - r.EncodeMapStart(yynn788) - yynn788 = 0 - } - if yyr788 || yy2arr788 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq788[0] { - yym790 := z.EncBinary() - _ = yym790 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq788[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("host")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym791 := z.EncBinary() - _ = yym791 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Host)) - } - } - } - var yyn792 bool - if x.IngressRuleValue.HTTP == nil { - yyn792 = true - goto LABEL792 - } - LABEL792: - if yyr788 || yy2arr788 { - if yyn792 { - r.EncodeNil() - } else { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq788[1] { - if x.HTTP == nil { - r.EncodeNil() - } else { - x.HTTP.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } - } else { - if yyq788[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("http")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn792 { - r.EncodeNil() - } else { - if x.HTTP == nil { - r.EncodeNil() - } else { - x.HTTP.CodecEncodeSelf(e) - } - } - } - } - if yyr788 || yy2arr788 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressRule) 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 *IngressRule) 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 "host": - if r.TryDecodeAsNil() { - x.Host = "" - } else { - x.Host = string(r.DecodeString()) - } - case "http": - if x.IngressRuleValue.HTTP == nil { - x.IngressRuleValue.HTTP = new(HTTPIngressRuleValue) - } - if r.TryDecodeAsNil() { - if x.HTTP != nil { - x.HTTP = nil - } - } else { - if x.HTTP == nil { - x.HTTP = new(HTTPIngressRuleValue) - } - x.HTTP.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys795) - } // end switch yys795 - } // end for yyj795 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj798 int - var yyb798 bool - var yyhl798 bool = l >= 0 - yyj798++ - if yyhl798 { - yyb798 = yyj798 > l - } else { - yyb798 = r.CheckBreak() - } - if yyb798 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Host = "" - } else { - x.Host = string(r.DecodeString()) - } - if x.IngressRuleValue.HTTP == nil { - x.IngressRuleValue.HTTP = new(HTTPIngressRuleValue) - } - yyj798++ - if yyhl798 { - yyb798 = yyj798 > l - } else { - yyb798 = r.CheckBreak() - } - if yyb798 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.HTTP != nil { - x.HTTP = nil - } - } else { - if x.HTTP == nil { - x.HTTP = new(HTTPIngressRuleValue) - } - x.HTTP.CodecDecodeSelf(d) - } - for { - yyj798++ - if yyhl798 { - yyb798 = yyj798 > l - } else { - yyb798 = r.CheckBreak() - } - if yyb798 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj798-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym801 := z.EncBinary() - _ = yym801 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep802 := !z.EncBinary() - yy2arr802 := z.EncBasicHandle().StructToArray - var yyq802 [1]bool - _, _, _ = yysep802, yyq802, yy2arr802 - const yyr802 bool = false - yyq802[0] = x.HTTP != nil - var yynn802 int - if yyr802 || yy2arr802 { - r.EncodeArrayStart(1) - } else { - yynn802 = 0 - for _, b := range yyq802 { - if b { - yynn802++ - } - } - r.EncodeMapStart(yynn802) - yynn802 = 0 - } - if yyr802 || yy2arr802 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq802[0] { - if x.HTTP == nil { - r.EncodeNil() - } else { - x.HTTP.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq802[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("http")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.HTTP == nil { - r.EncodeNil() - } else { - x.HTTP.CodecEncodeSelf(e) - } - } - } - if yyr802 || yy2arr802 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressRuleValue) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym804 := z.DecBinary() - _ = yym804 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct805 := r.ContainerType() - if yyct805 == codecSelferValueTypeMap1234 { - yyl805 := r.ReadMapStart() - if yyl805 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl805, d) - } - } else if yyct805 == codecSelferValueTypeArray1234 { - yyl805 := r.ReadArrayStart() - if yyl805 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl805, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys806Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys806Slc - var yyhl806 bool = l >= 0 - for yyj806 := 0; ; yyj806++ { - if yyhl806 { - if yyj806 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys806Slc = r.DecodeBytes(yys806Slc, true, true) - yys806 := string(yys806Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys806 { - case "http": - if r.TryDecodeAsNil() { - if x.HTTP != nil { - x.HTTP = nil - } - } else { - if x.HTTP == nil { - x.HTTP = new(HTTPIngressRuleValue) - } - x.HTTP.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys806) - } // end switch yys806 - } // end for yyj806 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressRuleValue) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj808 int - var yyb808 bool - var yyhl808 bool = l >= 0 - yyj808++ - if yyhl808 { - yyb808 = yyj808 > l - } else { - yyb808 = r.CheckBreak() - } - if yyb808 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.HTTP != nil { - x.HTTP = nil - } - } else { - if x.HTTP == nil { - x.HTTP = new(HTTPIngressRuleValue) - } - x.HTTP.CodecDecodeSelf(d) - } - for { - yyj808++ - if yyhl808 { - yyb808 = yyj808 > l - } else { - yyb808 = r.CheckBreak() - } - if yyb808 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj808-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HTTPIngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym810 := z.EncBinary() - _ = yym810 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep811 := !z.EncBinary() - yy2arr811 := z.EncBasicHandle().StructToArray - var yyq811 [1]bool - _, _, _ = yysep811, yyq811, yy2arr811 - const yyr811 bool = false - var yynn811 int - if yyr811 || yy2arr811 { - r.EncodeArrayStart(1) - } else { - yynn811 = 1 - for _, b := range yyq811 { - if b { - yynn811++ - } - } - r.EncodeMapStart(yynn811) - yynn811 = 0 - } - if yyr811 || yy2arr811 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Paths == nil { - r.EncodeNil() - } else { - yym813 := z.EncBinary() - _ = yym813 - if false { - } else { - h.encSliceHTTPIngressPath(([]HTTPIngressPath)(x.Paths), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("paths")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Paths == nil { - r.EncodeNil() - } else { - yym814 := z.EncBinary() - _ = yym814 - if false { - } else { - h.encSliceHTTPIngressPath(([]HTTPIngressPath)(x.Paths), e) - } - } - } - if yyr811 || yy2arr811 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HTTPIngressRuleValue) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym815 := z.DecBinary() - _ = yym815 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct816 := r.ContainerType() - if yyct816 == codecSelferValueTypeMap1234 { - yyl816 := r.ReadMapStart() - if yyl816 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl816, d) - } - } else if yyct816 == codecSelferValueTypeArray1234 { - yyl816 := r.ReadArrayStart() - if yyl816 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl816, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HTTPIngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys817Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys817Slc - var yyhl817 bool = l >= 0 - for yyj817 := 0; ; yyj817++ { - if yyhl817 { - if yyj817 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys817Slc = r.DecodeBytes(yys817Slc, true, true) - yys817 := string(yys817Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys817 { - case "paths": - if r.TryDecodeAsNil() { - x.Paths = nil - } else { - yyv818 := &x.Paths - yym819 := z.DecBinary() - _ = yym819 - if false { - } else { - h.decSliceHTTPIngressPath((*[]HTTPIngressPath)(yyv818), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys817) - } // end switch yys817 - } // end for yyj817 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HTTPIngressRuleValue) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj820 int - var yyb820 bool - var yyhl820 bool = l >= 0 - yyj820++ - if yyhl820 { - yyb820 = yyj820 > l - } else { - yyb820 = r.CheckBreak() - } - if yyb820 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Paths = nil - } else { - yyv821 := &x.Paths - yym822 := z.DecBinary() - _ = yym822 - if false { - } else { - h.decSliceHTTPIngressPath((*[]HTTPIngressPath)(yyv821), d) - } - } - for { - yyj820++ - if yyhl820 { - yyb820 = yyj820 > l - } else { - yyb820 = r.CheckBreak() - } - if yyb820 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj820-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HTTPIngressPath) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym823 := z.EncBinary() - _ = yym823 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep824 := !z.EncBinary() - yy2arr824 := z.EncBasicHandle().StructToArray - var yyq824 [2]bool - _, _, _ = yysep824, yyq824, yy2arr824 - const yyr824 bool = false - yyq824[0] = x.Path != "" - var yynn824 int - if yyr824 || yy2arr824 { - r.EncodeArrayStart(2) - } else { - yynn824 = 1 - for _, b := range yyq824 { - if b { - yynn824++ - } - } - r.EncodeMapStart(yynn824) - yynn824 = 0 - } - if yyr824 || yy2arr824 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq824[0] { - yym826 := z.EncBinary() - _ = yym826 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq824[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("path")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym827 := z.EncBinary() - _ = yym827 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Path)) - } - } - } - if yyr824 || yy2arr824 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy829 := &x.Backend - yy829.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("backend")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy830 := &x.Backend - yy830.CodecEncodeSelf(e) - } - if yyr824 || yy2arr824 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HTTPIngressPath) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym831 := z.DecBinary() - _ = yym831 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct832 := r.ContainerType() - if yyct832 == codecSelferValueTypeMap1234 { - yyl832 := r.ReadMapStart() - if yyl832 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl832, d) - } - } else if yyct832 == codecSelferValueTypeArray1234 { - yyl832 := r.ReadArrayStart() - if yyl832 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl832, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HTTPIngressPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys833Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys833Slc - var yyhl833 bool = l >= 0 - for yyj833 := 0; ; yyj833++ { - if yyhl833 { - if yyj833 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys833Slc = r.DecodeBytes(yys833Slc, true, true) - yys833 := string(yys833Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys833 { - case "path": - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - case "backend": - if r.TryDecodeAsNil() { - x.Backend = IngressBackend{} - } else { - yyv835 := &x.Backend - yyv835.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys833) - } // end switch yys833 - } // end for yyj833 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HTTPIngressPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj836 int - var yyb836 bool - var yyhl836 bool = l >= 0 - yyj836++ - if yyhl836 { - yyb836 = yyj836 > l - } else { - yyb836 = r.CheckBreak() - } - if yyb836 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Path = "" - } else { - x.Path = string(r.DecodeString()) - } - yyj836++ - if yyhl836 { - yyb836 = yyj836 > l - } else { - yyb836 = r.CheckBreak() - } - if yyb836 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Backend = IngressBackend{} - } else { - yyv838 := &x.Backend - yyv838.CodecDecodeSelf(d) - } - for { - yyj836++ - if yyhl836 { - yyb836 = yyj836 > l - } else { - yyb836 = r.CheckBreak() - } - if yyb836 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj836-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IngressBackend) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym839 := z.EncBinary() - _ = yym839 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep840 := !z.EncBinary() - yy2arr840 := z.EncBasicHandle().StructToArray - var yyq840 [2]bool - _, _, _ = yysep840, yyq840, yy2arr840 - const yyr840 bool = false - var yynn840 int - if yyr840 || yy2arr840 { - r.EncodeArrayStart(2) - } else { - yynn840 = 2 - for _, b := range yyq840 { - if b { - yynn840++ - } - } - r.EncodeMapStart(yynn840) - yynn840 = 0 - } - if yyr840 || yy2arr840 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym842 := z.EncBinary() - _ = yym842 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("serviceName")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym843 := z.EncBinary() - _ = yym843 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) - } - } - if yyr840 || yy2arr840 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy845 := &x.ServicePort - yym846 := z.EncBinary() - _ = yym846 - if false { - } else if z.HasExtensions() && z.EncExt(yy845) { - } else if !yym846 && z.IsJSONHandle() { - z.EncJSONMarshal(yy845) - } else { - z.EncFallback(yy845) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("servicePort")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy847 := &x.ServicePort - yym848 := z.EncBinary() - _ = yym848 - if false { - } else if z.HasExtensions() && z.EncExt(yy847) { - } else if !yym848 && z.IsJSONHandle() { - z.EncJSONMarshal(yy847) - } else { - z.EncFallback(yy847) - } - } - if yyr840 || yy2arr840 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IngressBackend) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym849 := z.DecBinary() - _ = yym849 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct850 := r.ContainerType() - if yyct850 == codecSelferValueTypeMap1234 { - yyl850 := r.ReadMapStart() - if yyl850 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl850, d) - } - } else if yyct850 == codecSelferValueTypeArray1234 { - yyl850 := r.ReadArrayStart() - if yyl850 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl850, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IngressBackend) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys851Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys851Slc - var yyhl851 bool = l >= 0 - for yyj851 := 0; ; yyj851++ { - if yyhl851 { - if yyj851 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys851Slc = r.DecodeBytes(yys851Slc, true, true) - yys851 := string(yys851Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys851 { - case "serviceName": - if r.TryDecodeAsNil() { - x.ServiceName = "" - } else { - x.ServiceName = string(r.DecodeString()) - } - case "servicePort": - if r.TryDecodeAsNil() { - x.ServicePort = pkg5_intstr.IntOrString{} - } else { - yyv853 := &x.ServicePort - yym854 := z.DecBinary() - _ = yym854 - if false { - } else if z.HasExtensions() && z.DecExt(yyv853) { - } else if !yym854 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv853) - } else { - z.DecFallback(yyv853, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys851) - } // end switch yys851 - } // end for yyj851 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IngressBackend) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj855 int - var yyb855 bool - var yyhl855 bool = l >= 0 - yyj855++ - if yyhl855 { - yyb855 = yyj855 > l - } else { - yyb855 = r.CheckBreak() - } - if yyb855 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ServiceName = "" - } else { - x.ServiceName = string(r.DecodeString()) - } - yyj855++ - if yyhl855 { - yyb855 = yyj855 > l - } else { - yyb855 = r.CheckBreak() - } - if yyb855 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ServicePort = pkg5_intstr.IntOrString{} - } else { - yyv857 := &x.ServicePort - yym858 := z.DecBinary() - _ = yym858 - if false { - } else if z.HasExtensions() && z.DecExt(yyv857) { - } else if !yym858 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv857) - } else { - z.DecFallback(yyv857, false) - } - } - for { - yyj855++ - if yyhl855 { - yyb855 = yyj855 > l - } else { - yyb855 = r.CheckBreak() - } - if yyb855 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj855-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ReplicaSet) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym859 := z.EncBinary() - _ = yym859 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep860 := !z.EncBinary() - yy2arr860 := z.EncBasicHandle().StructToArray - var yyq860 [5]bool - _, _, _ = yysep860, yyq860, yy2arr860 - const yyr860 bool = false - yyq860[0] = x.Kind != "" - yyq860[1] = x.APIVersion != "" - yyq860[2] = true - yyq860[3] = true - yyq860[4] = true - var yynn860 int - if yyr860 || yy2arr860 { - r.EncodeArrayStart(5) - } else { - yynn860 = 0 - for _, b := range yyq860 { - if b { - yynn860++ - } - } - r.EncodeMapStart(yynn860) - yynn860 = 0 - } - if yyr860 || yy2arr860 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq860[0] { - yym862 := z.EncBinary() - _ = yym862 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq860[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym863 := z.EncBinary() - _ = yym863 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr860 || yy2arr860 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq860[1] { - yym865 := z.EncBinary() - _ = yym865 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq860[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym866 := z.EncBinary() - _ = yym866 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr860 || yy2arr860 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq860[2] { - yy868 := &x.ObjectMeta - yy868.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq860[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy869 := &x.ObjectMeta - yy869.CodecEncodeSelf(e) - } - } - if yyr860 || yy2arr860 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq860[3] { - yy871 := &x.Spec - yy871.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq860[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy872 := &x.Spec - yy872.CodecEncodeSelf(e) - } - } - if yyr860 || yy2arr860 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq860[4] { - yy874 := &x.Status - yy874.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq860[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy875 := &x.Status - yy875.CodecEncodeSelf(e) - } - } - if yyr860 || yy2arr860 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicaSet) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym876 := z.DecBinary() - _ = yym876 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct877 := r.ContainerType() - if yyct877 == codecSelferValueTypeMap1234 { - yyl877 := r.ReadMapStart() - if yyl877 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl877, d) - } - } else if yyct877 == codecSelferValueTypeArray1234 { - yyl877 := r.ReadArrayStart() - if yyl877 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl877, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicaSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys878Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys878Slc - var yyhl878 bool = l >= 0 - for yyj878 := 0; ; yyj878++ { - if yyhl878 { - if yyj878 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys878Slc = r.DecodeBytes(yys878Slc, true, true) - yys878 := string(yys878Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys878 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv881 := &x.ObjectMeta - yyv881.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = ReplicaSetSpec{} - } else { - yyv882 := &x.Spec - yyv882.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = ReplicaSetStatus{} - } else { - yyv883 := &x.Status - yyv883.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys878) - } // end switch yys878 - } // end for yyj878 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicaSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj884 int - var yyb884 bool - var yyhl884 bool = l >= 0 - yyj884++ - if yyhl884 { - yyb884 = yyj884 > l - } else { - yyb884 = r.CheckBreak() - } - if yyb884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj884++ - if yyhl884 { - yyb884 = yyj884 > l - } else { - yyb884 = r.CheckBreak() - } - if yyb884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj884++ - if yyhl884 { - yyb884 = yyj884 > l - } else { - yyb884 = r.CheckBreak() - } - if yyb884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv887 := &x.ObjectMeta - yyv887.CodecDecodeSelf(d) - } - yyj884++ - if yyhl884 { - yyb884 = yyj884 > l - } else { - yyb884 = r.CheckBreak() - } - if yyb884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = ReplicaSetSpec{} - } else { - yyv888 := &x.Spec - yyv888.CodecDecodeSelf(d) - } - yyj884++ - if yyhl884 { - yyb884 = yyj884 > l - } else { - yyb884 = r.CheckBreak() - } - if yyb884 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = ReplicaSetStatus{} - } else { - yyv889 := &x.Status - yyv889.CodecDecodeSelf(d) - } - for { - yyj884++ - if yyhl884 { - yyb884 = yyj884 > l - } else { - yyb884 = r.CheckBreak() - } - if yyb884 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj884-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ReplicaSetList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym890 := z.EncBinary() - _ = yym890 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep891 := !z.EncBinary() - yy2arr891 := z.EncBasicHandle().StructToArray - var yyq891 [4]bool - _, _, _ = yysep891, yyq891, yy2arr891 - const yyr891 bool = false - yyq891[0] = x.Kind != "" - yyq891[1] = x.APIVersion != "" - yyq891[2] = true - var yynn891 int - if yyr891 || yy2arr891 { - r.EncodeArrayStart(4) - } else { - yynn891 = 1 - for _, b := range yyq891 { - if b { - yynn891++ - } - } - r.EncodeMapStart(yynn891) - yynn891 = 0 - } - if yyr891 || yy2arr891 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq891[0] { - yym893 := z.EncBinary() - _ = yym893 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq891[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym894 := z.EncBinary() - _ = yym894 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr891 || yy2arr891 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq891[1] { - yym896 := z.EncBinary() - _ = yym896 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq891[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym897 := z.EncBinary() - _ = yym897 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr891 || yy2arr891 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq891[2] { - yy899 := &x.ListMeta - yym900 := z.EncBinary() - _ = yym900 - if false { - } else if z.HasExtensions() && z.EncExt(yy899) { - } else { - z.EncFallback(yy899) - } - } else { - r.EncodeNil() - } - } else { - if yyq891[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy901 := &x.ListMeta - yym902 := z.EncBinary() - _ = yym902 - if false { - } else if z.HasExtensions() && z.EncExt(yy901) { - } else { - z.EncFallback(yy901) - } - } - } - if yyr891 || yy2arr891 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym904 := z.EncBinary() - _ = yym904 - if false { - } else { - h.encSliceReplicaSet(([]ReplicaSet)(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 { - yym905 := z.EncBinary() - _ = yym905 - if false { - } else { - h.encSliceReplicaSet(([]ReplicaSet)(x.Items), e) - } - } - } - if yyr891 || yy2arr891 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicaSetList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym906 := z.DecBinary() - _ = yym906 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct907 := r.ContainerType() - if yyct907 == codecSelferValueTypeMap1234 { - yyl907 := r.ReadMapStart() - if yyl907 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl907, d) - } - } else if yyct907 == codecSelferValueTypeArray1234 { - yyl907 := r.ReadArrayStart() - if yyl907 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl907, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicaSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys908Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys908Slc - var yyhl908 bool = l >= 0 - for yyj908 := 0; ; yyj908++ { - if yyhl908 { - if yyj908 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys908Slc = r.DecodeBytes(yys908Slc, true, true) - yys908 := string(yys908Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys908 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv911 := &x.ListMeta - yym912 := z.DecBinary() - _ = yym912 - if false { - } else if z.HasExtensions() && z.DecExt(yyv911) { - } else { - z.DecFallback(yyv911, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv913 := &x.Items - yym914 := z.DecBinary() - _ = yym914 - if false { - } else { - h.decSliceReplicaSet((*[]ReplicaSet)(yyv913), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys908) - } // end switch yys908 - } // end for yyj908 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicaSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj915 int - var yyb915 bool - var yyhl915 bool = l >= 0 - yyj915++ - if yyhl915 { - yyb915 = yyj915 > l - } else { - yyb915 = r.CheckBreak() - } - if yyb915 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj915++ - if yyhl915 { - yyb915 = yyj915 > l - } else { - yyb915 = r.CheckBreak() - } - if yyb915 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj915++ - if yyhl915 { - yyb915 = yyj915 > l - } else { - yyb915 = r.CheckBreak() - } - if yyb915 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv918 := &x.ListMeta - yym919 := z.DecBinary() - _ = yym919 - if false { - } else if z.HasExtensions() && z.DecExt(yyv918) { - } else { - z.DecFallback(yyv918, false) - } - } - yyj915++ - if yyhl915 { - yyb915 = yyj915 > l - } else { - yyb915 = r.CheckBreak() - } - if yyb915 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv920 := &x.Items - yym921 := z.DecBinary() - _ = yym921 - if false { - } else { - h.decSliceReplicaSet((*[]ReplicaSet)(yyv920), d) - } - } - for { - yyj915++ - if yyhl915 { - yyb915 = yyj915 > l - } else { - yyb915 = r.CheckBreak() - } - if yyb915 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj915-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ReplicaSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym922 := z.EncBinary() - _ = yym922 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep923 := !z.EncBinary() - yy2arr923 := z.EncBasicHandle().StructToArray - var yyq923 [4]bool - _, _, _ = yysep923, yyq923, yy2arr923 - const yyr923 bool = false - yyq923[1] = x.MinReadySeconds != 0 - yyq923[2] = x.Selector != nil - yyq923[3] = true - var yynn923 int - if yyr923 || yy2arr923 { - r.EncodeArrayStart(4) - } else { - yynn923 = 1 - for _, b := range yyq923 { - if b { - yynn923++ - } - } - r.EncodeMapStart(yynn923) - yynn923 = 0 - } - if yyr923 || yy2arr923 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym925 := z.EncBinary() - _ = yym925 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym926 := z.EncBinary() - _ = yym926 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr923 || yy2arr923 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq923[1] { - yym928 := z.EncBinary() - _ = yym928 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq923[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym929 := z.EncBinary() - _ = yym929 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } - } - if yyr923 || yy2arr923 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq923[2] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym931 := z.EncBinary() - _ = yym931 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq923[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym932 := z.EncBinary() - _ = yym932 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr923 || yy2arr923 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq923[3] { - yy934 := &x.Template - yy934.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq923[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy935 := &x.Template - yy935.CodecEncodeSelf(e) - } - } - if yyr923 || yy2arr923 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicaSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym936 := z.DecBinary() - _ = yym936 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct937 := r.ContainerType() - if yyct937 == codecSelferValueTypeMap1234 { - yyl937 := r.ReadMapStart() - if yyl937 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl937, d) - } - } else if yyct937 == codecSelferValueTypeArray1234 { - yyl937 := r.ReadArrayStart() - if yyl937 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl937, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys938Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys938Slc - var yyhl938 bool = l >= 0 - for yyj938 := 0; ; yyj938++ { - if yyhl938 { - if yyj938 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys938Slc = r.DecodeBytes(yys938Slc, true, true) - yys938 := string(yys938Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys938 { - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "minReadySeconds": - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym942 := z.DecBinary() - _ = yym942 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv943 := &x.Template - yyv943.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys938) - } // end switch yys938 - } // end for yyj938 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicaSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj944 int - var yyb944 bool - var yyhl944 bool = l >= 0 - yyj944++ - if yyhl944 { - yyb944 = yyj944 > l - } else { - yyb944 = r.CheckBreak() - } - if yyb944 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj944++ - if yyhl944 { - yyb944 = yyj944 > l - } else { - yyb944 = r.CheckBreak() - } - if yyb944 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - yyj944++ - if yyhl944 { - yyb944 = yyj944 > l - } else { - yyb944 = r.CheckBreak() - } - if yyb944 { - 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(pkg1_unversioned.LabelSelector) - } - yym948 := z.DecBinary() - _ = yym948 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj944++ - if yyhl944 { - yyb944 = yyj944 > l - } else { - yyb944 = r.CheckBreak() - } - if yyb944 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_api.PodTemplateSpec{} - } else { - yyv949 := &x.Template - yyv949.CodecDecodeSelf(d) - } - for { - yyj944++ - if yyhl944 { - yyb944 = yyj944 > l - } else { - yyb944 = r.CheckBreak() - } - if yyb944 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj944-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym950 := z.EncBinary() - _ = yym950 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep951 := !z.EncBinary() - yy2arr951 := z.EncBasicHandle().StructToArray - var yyq951 [6]bool - _, _, _ = yysep951, yyq951, yy2arr951 - const yyr951 bool = false - yyq951[1] = x.FullyLabeledReplicas != 0 - yyq951[2] = x.ReadyReplicas != 0 - yyq951[3] = x.AvailableReplicas != 0 - yyq951[4] = x.ObservedGeneration != 0 - yyq951[5] = len(x.Conditions) != 0 - var yynn951 int - if yyr951 || yy2arr951 { - r.EncodeArrayStart(6) - } else { - yynn951 = 1 - for _, b := range yyq951 { - if b { - yynn951++ - } - } - r.EncodeMapStart(yynn951) - yynn951 = 0 - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym953 := z.EncBinary() - _ = yym953 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym954 := z.EncBinary() - _ = yym954 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[1] { - yym956 := z.EncBinary() - _ = yym956 - if false { - } else { - r.EncodeInt(int64(x.FullyLabeledReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq951[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fullyLabeledReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym957 := z.EncBinary() - _ = yym957 - if false { - } else { - r.EncodeInt(int64(x.FullyLabeledReplicas)) - } - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[2] { - yym959 := z.EncBinary() - _ = yym959 - if false { - } else { - r.EncodeInt(int64(x.ReadyReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq951[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym960 := z.EncBinary() - _ = yym960 - if false { - } else { - r.EncodeInt(int64(x.ReadyReplicas)) - } - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[3] { - yym962 := z.EncBinary() - _ = yym962 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq951[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym963 := z.EncBinary() - _ = yym963 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[4] { - yym965 := z.EncBinary() - _ = yym965 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq951[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym966 := z.EncBinary() - _ = yym966 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq951[5] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym968 := z.EncBinary() - _ = yym968 - if false { - } else { - h.encSliceReplicaSetCondition(([]ReplicaSetCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq951[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym969 := z.EncBinary() - _ = yym969 - if false { - } else { - h.encSliceReplicaSetCondition(([]ReplicaSetCondition)(x.Conditions), e) - } - } - } - } - if yyr951 || yy2arr951 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicaSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym970 := z.DecBinary() - _ = yym970 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct971 := r.ContainerType() - if yyct971 == codecSelferValueTypeMap1234 { - yyl971 := r.ReadMapStart() - if yyl971 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl971, d) - } - } else if yyct971 == codecSelferValueTypeArray1234 { - yyl971 := r.ReadArrayStart() - if yyl971 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl971, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicaSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys972Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys972Slc - var yyhl972 bool = l >= 0 - for yyj972 := 0; ; yyj972++ { - if yyhl972 { - if yyj972 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys972Slc = r.DecodeBytes(yys972Slc, true, true) - yys972 := string(yys972Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys972 { - 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 "availableReplicas": - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - case "observedGeneration": - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv978 := &x.Conditions - yym979 := z.DecBinary() - _ = yym979 - if false { - } else { - h.decSliceReplicaSetCondition((*[]ReplicaSetCondition)(yyv978), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys972) - } // end switch yys972 - } // end for yyj972 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj980 int - var yyb980 bool - var yyhl980 bool = l >= 0 - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FullyLabeledReplicas = 0 - } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) - } - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadyReplicas = 0 - } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) - } - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv986 := &x.Conditions - yym987 := z.DecBinary() - _ = yym987 - if false { - } else { - h.decSliceReplicaSetCondition((*[]ReplicaSetCondition)(yyv986), d) - } - } - for { - yyj980++ - if yyhl980 { - yyb980 = yyj980 > l - } else { - yyb980 = r.CheckBreak() - } - if yyb980 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj980-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x ReplicaSetConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym988 := z.EncBinary() - _ = yym988 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *ReplicaSetConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym989 := z.DecBinary() - _ = yym989 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *ReplicaSetCondition) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym990 := z.EncBinary() - _ = yym990 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep991 := !z.EncBinary() - yy2arr991 := z.EncBasicHandle().StructToArray - var yyq991 [5]bool - _, _, _ = yysep991, yyq991, yy2arr991 - const yyr991 bool = false - yyq991[2] = true - yyq991[3] = x.Reason != "" - yyq991[4] = x.Message != "" - var yynn991 int - if yyr991 || yy2arr991 { - r.EncodeArrayStart(5) - } else { - yynn991 = 2 - for _, b := range yyq991 { - if b { - yynn991++ - } - } - r.EncodeMapStart(yynn991) - yynn991 = 0 - } - if yyr991 || yy2arr991 { - 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 yyr991 || yy2arr991 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym994 := z.EncBinary() - _ = yym994 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym995 := z.EncBinary() - _ = yym995 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } - if yyr991 || yy2arr991 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq991[2] { - yy997 := &x.LastTransitionTime - yym998 := z.EncBinary() - _ = yym998 - if false { - } else if z.HasExtensions() && z.EncExt(yy997) { - } else if yym998 { - z.EncBinaryMarshal(yy997) - } else if !yym998 && z.IsJSONHandle() { - z.EncJSONMarshal(yy997) - } else { - z.EncFallback(yy997) - } - } else { - r.EncodeNil() - } - } else { - if yyq991[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy999 := &x.LastTransitionTime - yym1000 := z.EncBinary() - _ = yym1000 - if false { - } else if z.HasExtensions() && z.EncExt(yy999) { - } else if yym1000 { - z.EncBinaryMarshal(yy999) - } else if !yym1000 && z.IsJSONHandle() { - z.EncJSONMarshal(yy999) - } else { - z.EncFallback(yy999) - } - } - } - if yyr991 || yy2arr991 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq991[3] { - yym1002 := z.EncBinary() - _ = yym1002 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq991[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1003 := z.EncBinary() - _ = yym1003 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr991 || yy2arr991 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq991[4] { - yym1005 := z.EncBinary() - _ = yym1005 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq991[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1006 := z.EncBinary() - _ = yym1006 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr991 || yy2arr991 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *ReplicaSetCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1007 := z.DecBinary() - _ = yym1007 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1008 := r.ContainerType() - if yyct1008 == codecSelferValueTypeMap1234 { - yyl1008 := r.ReadMapStart() - if yyl1008 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1008, d) - } - } else if yyct1008 == codecSelferValueTypeArray1234 { - yyl1008 := r.ReadArrayStart() - if yyl1008 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1008, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *ReplicaSetCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1009Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1009Slc - var yyhl1009 bool = l >= 0 - for yyj1009 := 0; ; yyj1009++ { - if yyhl1009 { - if yyj1009 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1009Slc = r.DecodeBytes(yys1009Slc, true, true) - yys1009 := string(yys1009Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1009 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ReplicaSetConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_api.ConditionStatus(r.DecodeString()) - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv1012 := &x.LastTransitionTime - yym1013 := z.DecBinary() - _ = yym1013 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1012) { - } else if yym1013 { - z.DecBinaryUnmarshal(yyv1012) - } else if !yym1013 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1012) - } else { - z.DecFallback(yyv1012, 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, yys1009) - } // end switch yys1009 - } // end for yyj1009 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *ReplicaSetCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1016 int - var yyb1016 bool - var yyhl1016 bool = l >= 0 - yyj1016++ - if yyhl1016 { - yyb1016 = yyj1016 > l - } else { - yyb1016 = r.CheckBreak() - } - if yyb1016 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = ReplicaSetConditionType(r.DecodeString()) - } - yyj1016++ - if yyhl1016 { - yyb1016 = yyj1016 > l - } else { - yyb1016 = r.CheckBreak() - } - if yyb1016 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_api.ConditionStatus(r.DecodeString()) - } - yyj1016++ - if yyhl1016 { - yyb1016 = yyj1016 > l - } else { - yyb1016 = r.CheckBreak() - } - if yyb1016 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv1019 := &x.LastTransitionTime - yym1020 := z.DecBinary() - _ = yym1020 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1019) { - } else if yym1020 { - z.DecBinaryUnmarshal(yyv1019) - } else if !yym1020 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1019) - } else { - z.DecFallback(yyv1019, false) - } - } - yyj1016++ - if yyhl1016 { - yyb1016 = yyj1016 > l - } else { - yyb1016 = r.CheckBreak() - } - if yyb1016 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj1016++ - if yyhl1016 { - yyb1016 = yyj1016 > l - } else { - yyb1016 = r.CheckBreak() - } - if yyb1016 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj1016++ - if yyhl1016 { - yyb1016 = yyj1016 > l - } else { - yyb1016 = r.CheckBreak() - } - if yyb1016 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1016-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PodSecurityPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1023 := z.EncBinary() - _ = yym1023 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1024 := !z.EncBinary() - yy2arr1024 := z.EncBasicHandle().StructToArray - var yyq1024 [4]bool - _, _, _ = yysep1024, yyq1024, yy2arr1024 - const yyr1024 bool = false - yyq1024[0] = x.Kind != "" - yyq1024[1] = x.APIVersion != "" - yyq1024[2] = true - yyq1024[3] = true - var yynn1024 int - if yyr1024 || yy2arr1024 { - r.EncodeArrayStart(4) - } else { - yynn1024 = 0 - for _, b := range yyq1024 { - if b { - yynn1024++ - } - } - r.EncodeMapStart(yynn1024) - yynn1024 = 0 - } - if yyr1024 || yy2arr1024 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1024[0] { - yym1026 := z.EncBinary() - _ = yym1026 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1024[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1027 := z.EncBinary() - _ = yym1027 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr1024 || yy2arr1024 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1024[1] { - yym1029 := z.EncBinary() - _ = yym1029 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1024[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1030 := z.EncBinary() - _ = yym1030 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1024 || yy2arr1024 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1024[2] { - yy1032 := &x.ObjectMeta - yy1032.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1024[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1033 := &x.ObjectMeta - yy1033.CodecEncodeSelf(e) - } - } - if yyr1024 || yy2arr1024 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1024[3] { - yy1035 := &x.Spec - yy1035.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1024[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1036 := &x.Spec - yy1036.CodecEncodeSelf(e) - } - } - if yyr1024 || yy2arr1024 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodSecurityPolicy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1037 := z.DecBinary() - _ = yym1037 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1038 := r.ContainerType() - if yyct1038 == codecSelferValueTypeMap1234 { - yyl1038 := r.ReadMapStart() - if yyl1038 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1038, d) - } - } else if yyct1038 == codecSelferValueTypeArray1234 { - yyl1038 := r.ReadArrayStart() - if yyl1038 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1038, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodSecurityPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1039Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1039Slc - var yyhl1039 bool = l >= 0 - for yyj1039 := 0; ; yyj1039++ { - if yyhl1039 { - if yyj1039 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1039Slc = r.DecodeBytes(yys1039Slc, true, true) - yys1039 := string(yys1039Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1039 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv1042 := &x.ObjectMeta - yyv1042.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PodSecurityPolicySpec{} - } else { - yyv1043 := &x.Spec - yyv1043.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1039) - } // end switch yys1039 - } // end for yyj1039 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodSecurityPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1044 int - var yyb1044 bool - var yyhl1044 bool = l >= 0 - yyj1044++ - if yyhl1044 { - yyb1044 = yyj1044 > l - } else { - yyb1044 = r.CheckBreak() - } - if yyb1044 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj1044++ - if yyhl1044 { - yyb1044 = yyj1044 > l - } else { - yyb1044 = r.CheckBreak() - } - if yyb1044 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1044++ - if yyhl1044 { - yyb1044 = yyj1044 > l - } else { - yyb1044 = r.CheckBreak() - } - if yyb1044 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv1047 := &x.ObjectMeta - yyv1047.CodecDecodeSelf(d) - } - yyj1044++ - if yyhl1044 { - yyb1044 = yyj1044 > l - } else { - yyb1044 = r.CheckBreak() - } - if yyb1044 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PodSecurityPolicySpec{} - } else { - yyv1048 := &x.Spec - yyv1048.CodecDecodeSelf(d) - } - for { - yyj1044++ - if yyhl1044 { - yyb1044 = yyj1044 > l - } else { - yyb1044 = r.CheckBreak() - } - if yyb1044 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1044-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1049 := z.EncBinary() - _ = yym1049 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1050 := !z.EncBinary() - yy2arr1050 := z.EncBasicHandle().StructToArray - var yyq1050 [14]bool - _, _, _ = yysep1050, yyq1050, yy2arr1050 - const yyr1050 bool = false - yyq1050[0] = x.Privileged != false - yyq1050[1] = len(x.DefaultAddCapabilities) != 0 - yyq1050[2] = len(x.RequiredDropCapabilities) != 0 - yyq1050[3] = len(x.AllowedCapabilities) != 0 - yyq1050[4] = len(x.Volumes) != 0 - yyq1050[5] = x.HostNetwork != false - yyq1050[6] = len(x.HostPorts) != 0 - yyq1050[7] = x.HostPID != false - yyq1050[8] = x.HostIPC != false - yyq1050[13] = x.ReadOnlyRootFilesystem != false - var yynn1050 int - if yyr1050 || yy2arr1050 { - r.EncodeArrayStart(14) - } else { - yynn1050 = 4 - for _, b := range yyq1050 { - if b { - yynn1050++ - } - } - r.EncodeMapStart(yynn1050) - yynn1050 = 0 - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[0] { - yym1052 := z.EncBinary() - _ = yym1052 - if false { - } else { - r.EncodeBool(bool(x.Privileged)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1050[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("privileged")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1053 := z.EncBinary() - _ = yym1053 - if false { - } else { - r.EncodeBool(bool(x.Privileged)) - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[1] { - if x.DefaultAddCapabilities == nil { - r.EncodeNil() - } else { - yym1055 := z.EncBinary() - _ = yym1055 - if false { - } else { - h.encSliceapi_Capability(([]pkg2_api.Capability)(x.DefaultAddCapabilities), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1050[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("defaultAddCapabilities")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DefaultAddCapabilities == nil { - r.EncodeNil() - } else { - yym1056 := z.EncBinary() - _ = yym1056 - if false { - } else { - h.encSliceapi_Capability(([]pkg2_api.Capability)(x.DefaultAddCapabilities), e) - } - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[2] { - if x.RequiredDropCapabilities == nil { - r.EncodeNil() - } else { - yym1058 := z.EncBinary() - _ = yym1058 - if false { - } else { - h.encSliceapi_Capability(([]pkg2_api.Capability)(x.RequiredDropCapabilities), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1050[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("requiredDropCapabilities")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RequiredDropCapabilities == nil { - r.EncodeNil() - } else { - yym1059 := z.EncBinary() - _ = yym1059 - if false { - } else { - h.encSliceapi_Capability(([]pkg2_api.Capability)(x.RequiredDropCapabilities), e) - } - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[3] { - if x.AllowedCapabilities == nil { - r.EncodeNil() - } else { - yym1061 := z.EncBinary() - _ = yym1061 - if false { - } else { - h.encSliceapi_Capability(([]pkg2_api.Capability)(x.AllowedCapabilities), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1050[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("allowedCapabilities")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AllowedCapabilities == nil { - r.EncodeNil() - } else { - yym1062 := z.EncBinary() - _ = yym1062 - if false { - } else { - h.encSliceapi_Capability(([]pkg2_api.Capability)(x.AllowedCapabilities), e) - } - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[4] { - if x.Volumes == nil { - r.EncodeNil() - } else { - yym1064 := z.EncBinary() - _ = yym1064 - if false { - } else { - h.encSliceFSType(([]FSType)(x.Volumes), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1050[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("volumes")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Volumes == nil { - r.EncodeNil() - } else { - yym1065 := z.EncBinary() - _ = yym1065 - if false { - } else { - h.encSliceFSType(([]FSType)(x.Volumes), e) - } - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[5] { - yym1067 := z.EncBinary() - _ = yym1067 - if false { - } else { - r.EncodeBool(bool(x.HostNetwork)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1050[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostNetwork")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1068 := z.EncBinary() - _ = yym1068 - if false { - } else { - r.EncodeBool(bool(x.HostNetwork)) - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[6] { - if x.HostPorts == nil { - r.EncodeNil() - } else { - yym1070 := z.EncBinary() - _ = yym1070 - if false { - } else { - h.encSliceHostPortRange(([]HostPortRange)(x.HostPorts), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1050[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPorts")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.HostPorts == nil { - r.EncodeNil() - } else { - yym1071 := z.EncBinary() - _ = yym1071 - if false { - } else { - h.encSliceHostPortRange(([]HostPortRange)(x.HostPorts), e) - } - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[7] { - yym1073 := z.EncBinary() - _ = yym1073 - if false { - } else { - r.EncodeBool(bool(x.HostPID)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1050[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostPID")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1074 := z.EncBinary() - _ = yym1074 - if false { - } else { - r.EncodeBool(bool(x.HostPID)) - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[8] { - yym1076 := z.EncBinary() - _ = yym1076 - if false { - } else { - r.EncodeBool(bool(x.HostIPC)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1050[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("hostIPC")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1077 := z.EncBinary() - _ = yym1077 - if false { - } else { - r.EncodeBool(bool(x.HostIPC)) - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1079 := &x.SELinux - yy1079.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("seLinux")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1080 := &x.SELinux - yy1080.CodecEncodeSelf(e) - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1082 := &x.RunAsUser - yy1082.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1083 := &x.RunAsUser - yy1083.CodecEncodeSelf(e) - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1085 := &x.SupplementalGroups - yy1085.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("supplementalGroups")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1086 := &x.SupplementalGroups - yy1086.CodecEncodeSelf(e) - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1088 := &x.FSGroup - yy1088.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("fsGroup")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1089 := &x.FSGroup - yy1089.CodecEncodeSelf(e) - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[13] { - yym1091 := z.EncBinary() - _ = yym1091 - if false { - } else { - r.EncodeBool(bool(x.ReadOnlyRootFilesystem)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq1050[13] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("readOnlyRootFilesystem")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1092 := z.EncBinary() - _ = yym1092 - if false { - } else { - r.EncodeBool(bool(x.ReadOnlyRootFilesystem)) - } - } - } - if yyr1050 || yy2arr1050 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodSecurityPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1093 := z.DecBinary() - _ = yym1093 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1094 := r.ContainerType() - if yyct1094 == codecSelferValueTypeMap1234 { - yyl1094 := r.ReadMapStart() - if yyl1094 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1094, d) - } - } else if yyct1094 == codecSelferValueTypeArray1234 { - yyl1094 := r.ReadArrayStart() - if yyl1094 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1094, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodSecurityPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1095Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1095Slc - var yyhl1095 bool = l >= 0 - for yyj1095 := 0; ; yyj1095++ { - if yyhl1095 { - if yyj1095 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1095Slc = r.DecodeBytes(yys1095Slc, true, true) - yys1095 := string(yys1095Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1095 { - case "privileged": - if r.TryDecodeAsNil() { - x.Privileged = false - } else { - x.Privileged = bool(r.DecodeBool()) - } - case "defaultAddCapabilities": - if r.TryDecodeAsNil() { - x.DefaultAddCapabilities = nil - } else { - yyv1097 := &x.DefaultAddCapabilities - yym1098 := z.DecBinary() - _ = yym1098 - if false { - } else { - h.decSliceapi_Capability((*[]pkg2_api.Capability)(yyv1097), d) - } - } - case "requiredDropCapabilities": - if r.TryDecodeAsNil() { - x.RequiredDropCapabilities = nil - } else { - yyv1099 := &x.RequiredDropCapabilities - yym1100 := z.DecBinary() - _ = yym1100 - if false { - } else { - h.decSliceapi_Capability((*[]pkg2_api.Capability)(yyv1099), d) - } - } - case "allowedCapabilities": - if r.TryDecodeAsNil() { - x.AllowedCapabilities = nil - } else { - yyv1101 := &x.AllowedCapabilities - yym1102 := z.DecBinary() - _ = yym1102 - if false { - } else { - h.decSliceapi_Capability((*[]pkg2_api.Capability)(yyv1101), d) - } - } - case "volumes": - if r.TryDecodeAsNil() { - x.Volumes = nil - } else { - yyv1103 := &x.Volumes - yym1104 := z.DecBinary() - _ = yym1104 - if false { - } else { - h.decSliceFSType((*[]FSType)(yyv1103), d) - } - } - case "hostNetwork": - if r.TryDecodeAsNil() { - x.HostNetwork = false - } else { - x.HostNetwork = bool(r.DecodeBool()) - } - case "hostPorts": - if r.TryDecodeAsNil() { - x.HostPorts = nil - } else { - yyv1106 := &x.HostPorts - yym1107 := z.DecBinary() - _ = yym1107 - if false { - } else { - h.decSliceHostPortRange((*[]HostPortRange)(yyv1106), d) - } - } - 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 "seLinux": - if r.TryDecodeAsNil() { - x.SELinux = SELinuxStrategyOptions{} - } else { - yyv1110 := &x.SELinux - yyv1110.CodecDecodeSelf(d) - } - case "runAsUser": - if r.TryDecodeAsNil() { - x.RunAsUser = RunAsUserStrategyOptions{} - } else { - yyv1111 := &x.RunAsUser - yyv1111.CodecDecodeSelf(d) - } - case "supplementalGroups": - if r.TryDecodeAsNil() { - x.SupplementalGroups = SupplementalGroupsStrategyOptions{} - } else { - yyv1112 := &x.SupplementalGroups - yyv1112.CodecDecodeSelf(d) - } - case "fsGroup": - if r.TryDecodeAsNil() { - x.FSGroup = FSGroupStrategyOptions{} - } else { - yyv1113 := &x.FSGroup - yyv1113.CodecDecodeSelf(d) - } - case "readOnlyRootFilesystem": - if r.TryDecodeAsNil() { - x.ReadOnlyRootFilesystem = false - } else { - x.ReadOnlyRootFilesystem = bool(r.DecodeBool()) - } - default: - z.DecStructFieldNotFound(-1, yys1095) - } // end switch yys1095 - } // end for yyj1095 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1115 int - var yyb1115 bool - var yyhl1115 bool = l >= 0 - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Privileged = false - } else { - x.Privileged = bool(r.DecodeBool()) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DefaultAddCapabilities = nil - } else { - yyv1117 := &x.DefaultAddCapabilities - yym1118 := z.DecBinary() - _ = yym1118 - if false { - } else { - h.decSliceapi_Capability((*[]pkg2_api.Capability)(yyv1117), d) - } - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RequiredDropCapabilities = nil - } else { - yyv1119 := &x.RequiredDropCapabilities - yym1120 := z.DecBinary() - _ = yym1120 - if false { - } else { - h.decSliceapi_Capability((*[]pkg2_api.Capability)(yyv1119), d) - } - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AllowedCapabilities = nil - } else { - yyv1121 := &x.AllowedCapabilities - yym1122 := z.DecBinary() - _ = yym1122 - if false { - } else { - h.decSliceapi_Capability((*[]pkg2_api.Capability)(yyv1121), d) - } - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Volumes = nil - } else { - yyv1123 := &x.Volumes - yym1124 := z.DecBinary() - _ = yym1124 - if false { - } else { - h.decSliceFSType((*[]FSType)(yyv1123), d) - } - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostNetwork = false - } else { - x.HostNetwork = bool(r.DecodeBool()) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostPorts = nil - } else { - yyv1126 := &x.HostPorts - yym1127 := z.DecBinary() - _ = yym1127 - if false { - } else { - h.decSliceHostPortRange((*[]HostPortRange)(yyv1126), d) - } - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostPID = false - } else { - x.HostPID = bool(r.DecodeBool()) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.HostIPC = false - } else { - x.HostIPC = bool(r.DecodeBool()) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SELinux = SELinuxStrategyOptions{} - } else { - yyv1130 := &x.SELinux - yyv1130.CodecDecodeSelf(d) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RunAsUser = RunAsUserStrategyOptions{} - } else { - yyv1131 := &x.RunAsUser - yyv1131.CodecDecodeSelf(d) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.SupplementalGroups = SupplementalGroupsStrategyOptions{} - } else { - yyv1132 := &x.SupplementalGroups - yyv1132.CodecDecodeSelf(d) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.FSGroup = FSGroupStrategyOptions{} - } else { - yyv1133 := &x.FSGroup - yyv1133.CodecDecodeSelf(d) - } - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ReadOnlyRootFilesystem = false - } else { - x.ReadOnlyRootFilesystem = bool(r.DecodeBool()) - } - for { - yyj1115++ - if yyhl1115 { - yyb1115 = yyj1115 > l - } else { - yyb1115 = r.CheckBreak() - } - if yyb1115 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1115-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HostPortRange) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1135 := z.EncBinary() - _ = yym1135 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1136 := !z.EncBinary() - yy2arr1136 := z.EncBasicHandle().StructToArray - var yyq1136 [2]bool - _, _, _ = yysep1136, yyq1136, yy2arr1136 - const yyr1136 bool = false - var yynn1136 int - if yyr1136 || yy2arr1136 { - r.EncodeArrayStart(2) - } else { - yynn1136 = 2 - for _, b := range yyq1136 { - if b { - yynn1136++ - } - } - r.EncodeMapStart(yynn1136) - yynn1136 = 0 - } - if yyr1136 || yy2arr1136 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1138 := z.EncBinary() - _ = yym1138 - if false { - } else { - r.EncodeInt(int64(x.Min)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("min")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1139 := z.EncBinary() - _ = yym1139 - if false { - } else { - r.EncodeInt(int64(x.Min)) - } - } - if yyr1136 || yy2arr1136 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1141 := z.EncBinary() - _ = yym1141 - if false { - } else { - r.EncodeInt(int64(x.Max)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("max")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1142 := z.EncBinary() - _ = yym1142 - if false { - } else { - r.EncodeInt(int64(x.Max)) - } - } - if yyr1136 || yy2arr1136 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *HostPortRange) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1143 := z.DecBinary() - _ = yym1143 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1144 := r.ContainerType() - if yyct1144 == codecSelferValueTypeMap1234 { - yyl1144 := r.ReadMapStart() - if yyl1144 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1144, d) - } - } else if yyct1144 == codecSelferValueTypeArray1234 { - yyl1144 := r.ReadArrayStart() - if yyl1144 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1144, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *HostPortRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1145Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1145Slc - var yyhl1145 bool = l >= 0 - for yyj1145 := 0; ; yyj1145++ { - if yyhl1145 { - if yyj1145 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1145Slc = r.DecodeBytes(yys1145Slc, true, true) - yys1145 := string(yys1145Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1145 { - case "min": - if r.TryDecodeAsNil() { - x.Min = 0 - } else { - x.Min = int(r.DecodeInt(codecSelferBitsize1234)) - } - case "max": - if r.TryDecodeAsNil() { - x.Max = 0 - } else { - x.Max = int(r.DecodeInt(codecSelferBitsize1234)) - } - default: - z.DecStructFieldNotFound(-1, yys1145) - } // end switch yys1145 - } // end for yyj1145 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *HostPortRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1148 int - var yyb1148 bool - var yyhl1148 bool = l >= 0 - yyj1148++ - if yyhl1148 { - yyb1148 = yyj1148 > l - } else { - yyb1148 = r.CheckBreak() - } - if yyb1148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Min = 0 - } else { - x.Min = int(r.DecodeInt(codecSelferBitsize1234)) - } - yyj1148++ - if yyhl1148 { - yyb1148 = yyj1148 > l - } else { - yyb1148 = r.CheckBreak() - } - if yyb1148 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Max = 0 - } else { - x.Max = int(r.DecodeInt(codecSelferBitsize1234)) - } - for { - yyj1148++ - if yyhl1148 { - yyb1148 = yyj1148 > l - } else { - yyb1148 = r.CheckBreak() - } - if yyb1148 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1148-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x FSType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1151 := z.EncBinary() - _ = yym1151 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *FSType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1152 := z.DecBinary() - _ = yym1152 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *SELinuxStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1153 := z.EncBinary() - _ = yym1153 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1154 := !z.EncBinary() - yy2arr1154 := z.EncBasicHandle().StructToArray - var yyq1154 [2]bool - _, _, _ = yysep1154, yyq1154, yy2arr1154 - const yyr1154 bool = false - yyq1154[1] = x.SELinuxOptions != nil - var yynn1154 int - if yyr1154 || yy2arr1154 { - r.EncodeArrayStart(2) - } else { - yynn1154 = 1 - for _, b := range yyq1154 { - if b { - yynn1154++ - } - } - r.EncodeMapStart(yynn1154) - yynn1154 = 0 - } - if yyr1154 || yy2arr1154 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - x.Rule.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rule")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Rule.CodecEncodeSelf(e) - } - if yyr1154 || yy2arr1154 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1154[1] { - if x.SELinuxOptions == nil { - r.EncodeNil() - } else { - x.SELinuxOptions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq1154[1] { - 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 yyr1154 || yy2arr1154 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SELinuxStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1157 := z.DecBinary() - _ = yym1157 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1158 := r.ContainerType() - if yyct1158 == codecSelferValueTypeMap1234 { - yyl1158 := r.ReadMapStart() - if yyl1158 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1158, d) - } - } else if yyct1158 == codecSelferValueTypeArray1234 { - yyl1158 := r.ReadArrayStart() - if yyl1158 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1158, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SELinuxStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1159Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1159Slc - var yyhl1159 bool = l >= 0 - for yyj1159 := 0; ; yyj1159++ { - if yyhl1159 { - if yyj1159 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1159Slc = r.DecodeBytes(yys1159Slc, true, true) - yys1159 := string(yys1159Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1159 { - case "rule": - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = SELinuxStrategy(r.DecodeString()) - } - case "seLinuxOptions": - if r.TryDecodeAsNil() { - if x.SELinuxOptions != nil { - x.SELinuxOptions = nil - } - } else { - if x.SELinuxOptions == nil { - x.SELinuxOptions = new(pkg2_api.SELinuxOptions) - } - x.SELinuxOptions.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1159) - } // end switch yys1159 - } // end for yyj1159 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SELinuxStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1162 int - var yyb1162 bool - var yyhl1162 bool = l >= 0 - yyj1162++ - if yyhl1162 { - yyb1162 = yyj1162 > l - } else { - yyb1162 = r.CheckBreak() - } - if yyb1162 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = SELinuxStrategy(r.DecodeString()) - } - yyj1162++ - if yyhl1162 { - yyb1162 = yyj1162 > l - } else { - yyb1162 = r.CheckBreak() - } - if yyb1162 { - 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(pkg2_api.SELinuxOptions) - } - x.SELinuxOptions.CodecDecodeSelf(d) - } - for { - yyj1162++ - if yyhl1162 { - yyb1162 = yyj1162 > l - } else { - yyb1162 = r.CheckBreak() - } - if yyb1162 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1162-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x SELinuxStrategy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1165 := z.EncBinary() - _ = yym1165 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *SELinuxStrategy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1166 := z.DecBinary() - _ = yym1166 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *RunAsUserStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1167 := z.EncBinary() - _ = yym1167 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1168 := !z.EncBinary() - yy2arr1168 := z.EncBasicHandle().StructToArray - var yyq1168 [2]bool - _, _, _ = yysep1168, yyq1168, yy2arr1168 - const yyr1168 bool = false - yyq1168[1] = len(x.Ranges) != 0 - var yynn1168 int - if yyr1168 || yy2arr1168 { - r.EncodeArrayStart(2) - } else { - yynn1168 = 1 - for _, b := range yyq1168 { - if b { - yynn1168++ - } - } - r.EncodeMapStart(yynn1168) - yynn1168 = 0 - } - if yyr1168 || yy2arr1168 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - x.Rule.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rule")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Rule.CodecEncodeSelf(e) - } - if yyr1168 || yy2arr1168 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1168[1] { - if x.Ranges == nil { - r.EncodeNil() - } else { - yym1171 := z.EncBinary() - _ = yym1171 - if false { - } else { - h.encSliceIDRange(([]IDRange)(x.Ranges), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1168[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ranges")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ranges == nil { - r.EncodeNil() - } else { - yym1172 := z.EncBinary() - _ = yym1172 - if false { - } else { - h.encSliceIDRange(([]IDRange)(x.Ranges), e) - } - } - } - } - if yyr1168 || yy2arr1168 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *RunAsUserStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1173 := z.DecBinary() - _ = yym1173 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1174 := r.ContainerType() - if yyct1174 == codecSelferValueTypeMap1234 { - yyl1174 := r.ReadMapStart() - if yyl1174 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1174, d) - } - } else if yyct1174 == codecSelferValueTypeArray1234 { - yyl1174 := r.ReadArrayStart() - if yyl1174 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1174, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *RunAsUserStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1175Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1175Slc - var yyhl1175 bool = l >= 0 - for yyj1175 := 0; ; yyj1175++ { - if yyhl1175 { - if yyj1175 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1175Slc = r.DecodeBytes(yys1175Slc, true, true) - yys1175 := string(yys1175Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1175 { - case "rule": - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = RunAsUserStrategy(r.DecodeString()) - } - case "ranges": - if r.TryDecodeAsNil() { - x.Ranges = nil - } else { - yyv1177 := &x.Ranges - yym1178 := z.DecBinary() - _ = yym1178 - if false { - } else { - h.decSliceIDRange((*[]IDRange)(yyv1177), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1175) - } // end switch yys1175 - } // end for yyj1175 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *RunAsUserStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1179 int - var yyb1179 bool - var yyhl1179 bool = l >= 0 - yyj1179++ - if yyhl1179 { - yyb1179 = yyj1179 > l - } else { - yyb1179 = r.CheckBreak() - } - if yyb1179 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = RunAsUserStrategy(r.DecodeString()) - } - yyj1179++ - if yyhl1179 { - yyb1179 = yyj1179 > l - } else { - yyb1179 = r.CheckBreak() - } - if yyb1179 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ranges = nil - } else { - yyv1181 := &x.Ranges - yym1182 := z.DecBinary() - _ = yym1182 - if false { - } else { - h.decSliceIDRange((*[]IDRange)(yyv1181), d) - } - } - for { - yyj1179++ - if yyhl1179 { - yyb1179 = yyj1179 > l - } else { - yyb1179 = r.CheckBreak() - } - if yyb1179 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1179-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *IDRange) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1183 := z.EncBinary() - _ = yym1183 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1184 := !z.EncBinary() - yy2arr1184 := z.EncBasicHandle().StructToArray - var yyq1184 [2]bool - _, _, _ = yysep1184, yyq1184, yy2arr1184 - const yyr1184 bool = false - var yynn1184 int - if yyr1184 || yy2arr1184 { - r.EncodeArrayStart(2) - } else { - yynn1184 = 2 - for _, b := range yyq1184 { - if b { - yynn1184++ - } - } - r.EncodeMapStart(yynn1184) - yynn1184 = 0 - } - if yyr1184 || yy2arr1184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1186 := z.EncBinary() - _ = yym1186 - if false { - } else { - r.EncodeInt(int64(x.Min)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("min")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1187 := z.EncBinary() - _ = yym1187 - if false { - } else { - r.EncodeInt(int64(x.Min)) - } - } - if yyr1184 || yy2arr1184 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1189 := z.EncBinary() - _ = yym1189 - if false { - } else { - r.EncodeInt(int64(x.Max)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("max")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1190 := z.EncBinary() - _ = yym1190 - if false { - } else { - r.EncodeInt(int64(x.Max)) - } - } - if yyr1184 || yy2arr1184 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *IDRange) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1191 := z.DecBinary() - _ = yym1191 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1192 := r.ContainerType() - if yyct1192 == codecSelferValueTypeMap1234 { - yyl1192 := r.ReadMapStart() - if yyl1192 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1192, d) - } - } else if yyct1192 == codecSelferValueTypeArray1234 { - yyl1192 := r.ReadArrayStart() - if yyl1192 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1192, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *IDRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1193Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1193Slc - var yyhl1193 bool = l >= 0 - for yyj1193 := 0; ; yyj1193++ { - if yyhl1193 { - if yyj1193 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1193Slc = r.DecodeBytes(yys1193Slc, true, true) - yys1193 := string(yys1193Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1193 { - case "min": - if r.TryDecodeAsNil() { - x.Min = 0 - } else { - x.Min = int64(r.DecodeInt(64)) - } - case "max": - if r.TryDecodeAsNil() { - x.Max = 0 - } else { - x.Max = int64(r.DecodeInt(64)) - } - default: - z.DecStructFieldNotFound(-1, yys1193) - } // end switch yys1193 - } // end for yyj1193 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *IDRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1196 int - var yyb1196 bool - var yyhl1196 bool = l >= 0 - yyj1196++ - if yyhl1196 { - yyb1196 = yyj1196 > l - } else { - yyb1196 = r.CheckBreak() - } - if yyb1196 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Min = 0 - } else { - x.Min = int64(r.DecodeInt(64)) - } - yyj1196++ - if yyhl1196 { - yyb1196 = yyj1196 > l - } else { - yyb1196 = r.CheckBreak() - } - if yyb1196 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Max = 0 - } else { - x.Max = int64(r.DecodeInt(64)) - } - for { - yyj1196++ - if yyhl1196 { - yyb1196 = yyj1196 > l - } else { - yyb1196 = r.CheckBreak() - } - if yyb1196 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1196-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x RunAsUserStrategy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1199 := z.EncBinary() - _ = yym1199 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *RunAsUserStrategy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1200 := z.DecBinary() - _ = yym1200 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *FSGroupStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1201 := z.EncBinary() - _ = yym1201 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1202 := !z.EncBinary() - yy2arr1202 := z.EncBasicHandle().StructToArray - var yyq1202 [2]bool - _, _, _ = yysep1202, yyq1202, yy2arr1202 - const yyr1202 bool = false - yyq1202[0] = x.Rule != "" - yyq1202[1] = len(x.Ranges) != 0 - var yynn1202 int - if yyr1202 || yy2arr1202 { - r.EncodeArrayStart(2) - } else { - yynn1202 = 0 - for _, b := range yyq1202 { - if b { - yynn1202++ - } - } - r.EncodeMapStart(yynn1202) - yynn1202 = 0 - } - if yyr1202 || yy2arr1202 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1202[0] { - x.Rule.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1202[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rule")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Rule.CodecEncodeSelf(e) - } - } - if yyr1202 || yy2arr1202 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1202[1] { - if x.Ranges == nil { - r.EncodeNil() - } else { - yym1205 := z.EncBinary() - _ = yym1205 - if false { - } else { - h.encSliceIDRange(([]IDRange)(x.Ranges), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1202[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ranges")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ranges == nil { - r.EncodeNil() - } else { - yym1206 := z.EncBinary() - _ = yym1206 - if false { - } else { - h.encSliceIDRange(([]IDRange)(x.Ranges), e) - } - } - } - } - if yyr1202 || yy2arr1202 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *FSGroupStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1207 := z.DecBinary() - _ = yym1207 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1208 := r.ContainerType() - if yyct1208 == codecSelferValueTypeMap1234 { - yyl1208 := r.ReadMapStart() - if yyl1208 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1208, d) - } - } else if yyct1208 == codecSelferValueTypeArray1234 { - yyl1208 := r.ReadArrayStart() - if yyl1208 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1208, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *FSGroupStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1209Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1209Slc - var yyhl1209 bool = l >= 0 - for yyj1209 := 0; ; yyj1209++ { - if yyhl1209 { - if yyj1209 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1209Slc = r.DecodeBytes(yys1209Slc, true, true) - yys1209 := string(yys1209Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1209 { - case "rule": - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = FSGroupStrategyType(r.DecodeString()) - } - case "ranges": - if r.TryDecodeAsNil() { - x.Ranges = nil - } else { - yyv1211 := &x.Ranges - yym1212 := z.DecBinary() - _ = yym1212 - if false { - } else { - h.decSliceIDRange((*[]IDRange)(yyv1211), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1209) - } // end switch yys1209 - } // end for yyj1209 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *FSGroupStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1213 int - var yyb1213 bool - var yyhl1213 bool = l >= 0 - yyj1213++ - if yyhl1213 { - yyb1213 = yyj1213 > l - } else { - yyb1213 = r.CheckBreak() - } - if yyb1213 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = FSGroupStrategyType(r.DecodeString()) - } - yyj1213++ - if yyhl1213 { - yyb1213 = yyj1213 > l - } else { - yyb1213 = r.CheckBreak() - } - if yyb1213 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ranges = nil - } else { - yyv1215 := &x.Ranges - yym1216 := z.DecBinary() - _ = yym1216 - if false { - } else { - h.decSliceIDRange((*[]IDRange)(yyv1215), d) - } - } - for { - yyj1213++ - if yyhl1213 { - yyb1213 = yyj1213 > l - } else { - yyb1213 = r.CheckBreak() - } - if yyb1213 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1213-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x FSGroupStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1217 := z.EncBinary() - _ = yym1217 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *FSGroupStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1218 := z.DecBinary() - _ = yym1218 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *SupplementalGroupsStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1219 := z.EncBinary() - _ = yym1219 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1220 := !z.EncBinary() - yy2arr1220 := z.EncBasicHandle().StructToArray - var yyq1220 [2]bool - _, _, _ = yysep1220, yyq1220, yy2arr1220 - const yyr1220 bool = false - yyq1220[0] = x.Rule != "" - yyq1220[1] = len(x.Ranges) != 0 - var yynn1220 int - if yyr1220 || yy2arr1220 { - r.EncodeArrayStart(2) - } else { - yynn1220 = 0 - for _, b := range yyq1220 { - if b { - yynn1220++ - } - } - r.EncodeMapStart(yynn1220) - yynn1220 = 0 - } - if yyr1220 || yy2arr1220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1220[0] { - x.Rule.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1220[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rule")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Rule.CodecEncodeSelf(e) - } - } - if yyr1220 || yy2arr1220 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1220[1] { - if x.Ranges == nil { - r.EncodeNil() - } else { - yym1223 := z.EncBinary() - _ = yym1223 - if false { - } else { - h.encSliceIDRange(([]IDRange)(x.Ranges), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1220[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ranges")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ranges == nil { - r.EncodeNil() - } else { - yym1224 := z.EncBinary() - _ = yym1224 - if false { - } else { - h.encSliceIDRange(([]IDRange)(x.Ranges), e) - } - } - } - } - if yyr1220 || yy2arr1220 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *SupplementalGroupsStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1225 := z.DecBinary() - _ = yym1225 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1226 := r.ContainerType() - if yyct1226 == codecSelferValueTypeMap1234 { - yyl1226 := r.ReadMapStart() - if yyl1226 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1226, d) - } - } else if yyct1226 == codecSelferValueTypeArray1234 { - yyl1226 := r.ReadArrayStart() - if yyl1226 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1226, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1227Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1227Slc - var yyhl1227 bool = l >= 0 - for yyj1227 := 0; ; yyj1227++ { - if yyhl1227 { - if yyj1227 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1227Slc = r.DecodeBytes(yys1227Slc, true, true) - yys1227 := string(yys1227Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1227 { - case "rule": - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = SupplementalGroupsStrategyType(r.DecodeString()) - } - case "ranges": - if r.TryDecodeAsNil() { - x.Ranges = nil - } else { - yyv1229 := &x.Ranges - yym1230 := z.DecBinary() - _ = yym1230 - if false { - } else { - h.decSliceIDRange((*[]IDRange)(yyv1229), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1227) - } // end switch yys1227 - } // end for yyj1227 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1231 int - var yyb1231 bool - var yyhl1231 bool = l >= 0 - yyj1231++ - if yyhl1231 { - yyb1231 = yyj1231 > l - } else { - yyb1231 = r.CheckBreak() - } - if yyb1231 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Rule = "" - } else { - x.Rule = SupplementalGroupsStrategyType(r.DecodeString()) - } - yyj1231++ - if yyhl1231 { - yyb1231 = yyj1231 > l - } else { - yyb1231 = r.CheckBreak() - } - if yyb1231 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ranges = nil - } else { - yyv1233 := &x.Ranges - yym1234 := z.DecBinary() - _ = yym1234 - if false { - } else { - h.decSliceIDRange((*[]IDRange)(yyv1233), d) - } - } - for { - yyj1231++ - if yyhl1231 { - yyb1231 = yyj1231 > l - } else { - yyb1231 = r.CheckBreak() - } - if yyb1231 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1231-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x SupplementalGroupsStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1235 := z.EncBinary() - _ = yym1235 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *SupplementalGroupsStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1236 := z.DecBinary() - _ = yym1236 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *PodSecurityPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1237 := z.EncBinary() - _ = yym1237 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1238 := !z.EncBinary() - yy2arr1238 := z.EncBasicHandle().StructToArray - var yyq1238 [4]bool - _, _, _ = yysep1238, yyq1238, yy2arr1238 - const yyr1238 bool = false - yyq1238[0] = x.Kind != "" - yyq1238[1] = x.APIVersion != "" - yyq1238[2] = true - var yynn1238 int - if yyr1238 || yy2arr1238 { - r.EncodeArrayStart(4) - } else { - yynn1238 = 1 - for _, b := range yyq1238 { - if b { - yynn1238++ - } - } - r.EncodeMapStart(yynn1238) - yynn1238 = 0 - } - if yyr1238 || yy2arr1238 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1238[0] { - yym1240 := z.EncBinary() - _ = yym1240 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1238[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1241 := z.EncBinary() - _ = yym1241 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr1238 || yy2arr1238 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1238[1] { - yym1243 := z.EncBinary() - _ = yym1243 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1238[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1244 := z.EncBinary() - _ = yym1244 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1238 || yy2arr1238 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1238[2] { - yy1246 := &x.ListMeta - yym1247 := z.EncBinary() - _ = yym1247 - if false { - } else if z.HasExtensions() && z.EncExt(yy1246) { - } else { - z.EncFallback(yy1246) - } - } else { - r.EncodeNil() - } - } else { - if yyq1238[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1248 := &x.ListMeta - yym1249 := z.EncBinary() - _ = yym1249 - if false { - } else if z.HasExtensions() && z.EncExt(yy1248) { - } else { - z.EncFallback(yy1248) - } - } - } - if yyr1238 || yy2arr1238 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1251 := z.EncBinary() - _ = yym1251 - if false { - } else { - h.encSlicePodSecurityPolicy(([]PodSecurityPolicy)(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 { - yym1252 := z.EncBinary() - _ = yym1252 - if false { - } else { - h.encSlicePodSecurityPolicy(([]PodSecurityPolicy)(x.Items), e) - } - } - } - if yyr1238 || yy2arr1238 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodSecurityPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1253 := z.DecBinary() - _ = yym1253 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1254 := r.ContainerType() - if yyct1254 == codecSelferValueTypeMap1234 { - yyl1254 := r.ReadMapStart() - if yyl1254 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1254, d) - } - } else if yyct1254 == codecSelferValueTypeArray1234 { - yyl1254 := r.ReadArrayStart() - if yyl1254 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1254, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodSecurityPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1255Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1255Slc - var yyhl1255 bool = l >= 0 - for yyj1255 := 0; ; yyj1255++ { - if yyhl1255 { - if yyj1255 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1255Slc = r.DecodeBytes(yys1255Slc, true, true) - yys1255 := string(yys1255Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1255 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv1258 := &x.ListMeta - yym1259 := z.DecBinary() - _ = yym1259 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1258) { - } else { - z.DecFallback(yyv1258, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1260 := &x.Items - yym1261 := z.DecBinary() - _ = yym1261 - if false { - } else { - h.decSlicePodSecurityPolicy((*[]PodSecurityPolicy)(yyv1260), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1255) - } // end switch yys1255 - } // end for yyj1255 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodSecurityPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1262 int - var yyb1262 bool - var yyhl1262 bool = l >= 0 - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv1265 := &x.ListMeta - yym1266 := z.DecBinary() - _ = yym1266 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1265) { - } else { - z.DecFallback(yyv1265, false) - } - } - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1267 := &x.Items - yym1268 := z.DecBinary() - _ = yym1268 - if false { - } else { - h.decSlicePodSecurityPolicy((*[]PodSecurityPolicy)(yyv1267), d) - } - } - for { - yyj1262++ - if yyhl1262 { - yyb1262 = yyj1262 > l - } else { - yyb1262 = r.CheckBreak() - } - if yyb1262 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1262-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1269 := z.EncBinary() - _ = yym1269 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1270 := !z.EncBinary() - yy2arr1270 := z.EncBasicHandle().StructToArray - var yyq1270 [4]bool - _, _, _ = yysep1270, yyq1270, yy2arr1270 - const yyr1270 bool = false - yyq1270[0] = x.Kind != "" - yyq1270[1] = x.APIVersion != "" - yyq1270[2] = true - yyq1270[3] = true - var yynn1270 int - if yyr1270 || yy2arr1270 { - r.EncodeArrayStart(4) - } else { - yynn1270 = 0 - for _, b := range yyq1270 { - if b { - yynn1270++ - } - } - r.EncodeMapStart(yynn1270) - yynn1270 = 0 - } - if yyr1270 || yy2arr1270 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1270[0] { - yym1272 := z.EncBinary() - _ = yym1272 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1270[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1273 := z.EncBinary() - _ = yym1273 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr1270 || yy2arr1270 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1270[1] { - yym1275 := z.EncBinary() - _ = yym1275 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1270[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1276 := z.EncBinary() - _ = yym1276 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1270 || yy2arr1270 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1270[2] { - yy1278 := &x.ObjectMeta - yy1278.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1270[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1279 := &x.ObjectMeta - yy1279.CodecEncodeSelf(e) - } - } - if yyr1270 || yy2arr1270 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1270[3] { - yy1281 := &x.Spec - yy1281.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq1270[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1282 := &x.Spec - yy1282.CodecEncodeSelf(e) - } - } - if yyr1270 || yy2arr1270 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NetworkPolicy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1283 := z.DecBinary() - _ = yym1283 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1284 := r.ContainerType() - if yyct1284 == codecSelferValueTypeMap1234 { - yyl1284 := r.ReadMapStart() - if yyl1284 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1284, d) - } - } else if yyct1284 == codecSelferValueTypeArray1234 { - yyl1284 := r.ReadArrayStart() - if yyl1284 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1284, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NetworkPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1285Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1285Slc - var yyhl1285 bool = l >= 0 - for yyj1285 := 0; ; yyj1285++ { - if yyhl1285 { - if yyj1285 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1285Slc = r.DecodeBytes(yys1285Slc, true, true) - yys1285 := string(yys1285Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1285 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv1288 := &x.ObjectMeta - yyv1288.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = NetworkPolicySpec{} - } else { - yyv1289 := &x.Spec - yyv1289.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys1285) - } // end switch yys1285 - } // end for yyj1285 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1290 int - var yyb1290 bool - var yyhl1290 bool = l >= 0 - yyj1290++ - if yyhl1290 { - yyb1290 = yyj1290 > l - } else { - yyb1290 = r.CheckBreak() - } - if yyb1290 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj1290++ - if yyhl1290 { - yyb1290 = yyj1290 > l - } else { - yyb1290 = r.CheckBreak() - } - if yyb1290 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1290++ - if yyhl1290 { - yyb1290 = yyj1290 > l - } else { - yyb1290 = r.CheckBreak() - } - if yyb1290 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv1293 := &x.ObjectMeta - yyv1293.CodecDecodeSelf(d) - } - yyj1290++ - if yyhl1290 { - yyb1290 = yyj1290 > l - } else { - yyb1290 = r.CheckBreak() - } - if yyb1290 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = NetworkPolicySpec{} - } else { - yyv1294 := &x.Spec - yyv1294.CodecDecodeSelf(d) - } - for { - yyj1290++ - if yyhl1290 { - yyb1290 = yyj1290 > l - } else { - yyb1290 = r.CheckBreak() - } - if yyb1290 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1290-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1295 := z.EncBinary() - _ = yym1295 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1296 := !z.EncBinary() - yy2arr1296 := z.EncBasicHandle().StructToArray - var yyq1296 [2]bool - _, _, _ = yysep1296, yyq1296, yy2arr1296 - const yyr1296 bool = false - yyq1296[1] = len(x.Ingress) != 0 - var yynn1296 int - if yyr1296 || yy2arr1296 { - r.EncodeArrayStart(2) - } else { - yynn1296 = 1 - for _, b := range yyq1296 { - if b { - yynn1296++ - } - } - r.EncodeMapStart(yynn1296) - yynn1296 = 0 - } - if yyr1296 || yy2arr1296 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1298 := &x.PodSelector - yym1299 := z.EncBinary() - _ = yym1299 - if false { - } else if z.HasExtensions() && z.EncExt(yy1298) { - } else { - z.EncFallback(yy1298) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1300 := &x.PodSelector - yym1301 := z.EncBinary() - _ = yym1301 - if false { - } else if z.HasExtensions() && z.EncExt(yy1300) { - } else { - z.EncFallback(yy1300) - } - } - if yyr1296 || yy2arr1296 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1296[1] { - if x.Ingress == nil { - r.EncodeNil() - } else { - yym1303 := z.EncBinary() - _ = yym1303 - if false { - } else { - h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1296[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ingress")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ingress == nil { - r.EncodeNil() - } else { - yym1304 := z.EncBinary() - _ = yym1304 - if false { - } else { - h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) - } - } - } - } - if yyr1296 || yy2arr1296 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NetworkPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1305 := z.DecBinary() - _ = yym1305 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1306 := r.ContainerType() - if yyct1306 == codecSelferValueTypeMap1234 { - yyl1306 := r.ReadMapStart() - if yyl1306 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1306, d) - } - } else if yyct1306 == codecSelferValueTypeArray1234 { - yyl1306 := r.ReadArrayStart() - if yyl1306 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1306, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NetworkPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1307Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1307Slc - var yyhl1307 bool = l >= 0 - for yyj1307 := 0; ; yyj1307++ { - if yyhl1307 { - if yyj1307 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1307Slc = r.DecodeBytes(yys1307Slc, true, true) - yys1307 := string(yys1307Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1307 { - case "podSelector": - if r.TryDecodeAsNil() { - x.PodSelector = pkg1_unversioned.LabelSelector{} - } else { - yyv1308 := &x.PodSelector - yym1309 := z.DecBinary() - _ = yym1309 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1308) { - } else { - z.DecFallback(yyv1308, false) - } - } - case "ingress": - if r.TryDecodeAsNil() { - x.Ingress = nil - } else { - yyv1310 := &x.Ingress - yym1311 := z.DecBinary() - _ = yym1311 - if false { - } else { - h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv1310), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1307) - } // end switch yys1307 - } // end for yyj1307 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NetworkPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1312 int - var yyb1312 bool - var yyhl1312 bool = l >= 0 - yyj1312++ - if yyhl1312 { - yyb1312 = yyj1312 > l - } else { - yyb1312 = r.CheckBreak() - } - if yyb1312 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodSelector = pkg1_unversioned.LabelSelector{} - } else { - yyv1313 := &x.PodSelector - yym1314 := z.DecBinary() - _ = yym1314 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1313) { - } else { - z.DecFallback(yyv1313, false) - } - } - yyj1312++ - if yyhl1312 { - yyb1312 = yyj1312 > l - } else { - yyb1312 = r.CheckBreak() - } - if yyb1312 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ingress = nil - } else { - yyv1315 := &x.Ingress - yym1316 := z.DecBinary() - _ = yym1316 - if false { - } else { - h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv1315), d) - } - } - for { - yyj1312++ - if yyhl1312 { - yyb1312 = yyj1312 > l - } else { - yyb1312 = r.CheckBreak() - } - if yyb1312 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1312-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1317 := z.EncBinary() - _ = yym1317 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1318 := !z.EncBinary() - yy2arr1318 := z.EncBasicHandle().StructToArray - var yyq1318 [2]bool - _, _, _ = yysep1318, yyq1318, yy2arr1318 - const yyr1318 bool = false - yyq1318[0] = len(x.Ports) != 0 - yyq1318[1] = len(x.From) != 0 - var yynn1318 int - if yyr1318 || yy2arr1318 { - r.EncodeArrayStart(2) - } else { - yynn1318 = 0 - for _, b := range yyq1318 { - if b { - yynn1318++ - } - } - r.EncodeMapStart(yynn1318) - yynn1318 = 0 - } - if yyr1318 || yy2arr1318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1318[0] { - if x.Ports == nil { - r.EncodeNil() - } else { - yym1320 := z.EncBinary() - _ = yym1320 - if false { - } else { - h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1318[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("ports")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Ports == nil { - r.EncodeNil() - } else { - yym1321 := z.EncBinary() - _ = yym1321 - if false { - } else { - h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) - } - } - } - } - if yyr1318 || yy2arr1318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1318[1] { - if x.From == nil { - r.EncodeNil() - } else { - yym1323 := z.EncBinary() - _ = yym1323 - if false { - } else { - h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1318[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("from")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.From == nil { - r.EncodeNil() - } else { - yym1324 := z.EncBinary() - _ = yym1324 - if false { - } else { - h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) - } - } - } - } - if yyr1318 || yy2arr1318 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NetworkPolicyIngressRule) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1325 := z.DecBinary() - _ = yym1325 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1326 := r.ContainerType() - if yyct1326 == codecSelferValueTypeMap1234 { - yyl1326 := r.ReadMapStart() - if yyl1326 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1326, d) - } - } else if yyct1326 == codecSelferValueTypeArray1234 { - yyl1326 := r.ReadArrayStart() - if yyl1326 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1326, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NetworkPolicyIngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1327Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1327Slc - var yyhl1327 bool = l >= 0 - for yyj1327 := 0; ; yyj1327++ { - if yyhl1327 { - if yyj1327 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1327Slc = r.DecodeBytes(yys1327Slc, true, true) - yys1327 := string(yys1327Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1327 { - case "ports": - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv1328 := &x.Ports - yym1329 := z.DecBinary() - _ = yym1329 - if false { - } else { - h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv1328), d) - } - } - case "from": - if r.TryDecodeAsNil() { - x.From = nil - } else { - yyv1330 := &x.From - yym1331 := z.DecBinary() - _ = yym1331 - if false { - } else { - h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv1330), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1327) - } // end switch yys1327 - } // end for yyj1327 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1332 int - var yyb1332 bool - var yyhl1332 bool = l >= 0 - yyj1332++ - if yyhl1332 { - yyb1332 = yyj1332 > l - } else { - yyb1332 = r.CheckBreak() - } - if yyb1332 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Ports = nil - } else { - yyv1333 := &x.Ports - yym1334 := z.DecBinary() - _ = yym1334 - if false { - } else { - h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv1333), d) - } - } - yyj1332++ - if yyhl1332 { - yyb1332 = yyj1332 > l - } else { - yyb1332 = r.CheckBreak() - } - if yyb1332 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.From = nil - } else { - yyv1335 := &x.From - yym1336 := z.DecBinary() - _ = yym1336 - if false { - } else { - h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv1335), d) - } - } - for { - yyj1332++ - if yyhl1332 { - yyb1332 = yyj1332 > l - } else { - yyb1332 = r.CheckBreak() - } - if yyb1332 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1332-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1337 := z.EncBinary() - _ = yym1337 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1338 := !z.EncBinary() - yy2arr1338 := z.EncBasicHandle().StructToArray - var yyq1338 [2]bool - _, _, _ = yysep1338, yyq1338, yy2arr1338 - const yyr1338 bool = false - yyq1338[0] = x.Protocol != nil - yyq1338[1] = x.Port != nil - var yynn1338 int - if yyr1338 || yy2arr1338 { - r.EncodeArrayStart(2) - } else { - yynn1338 = 0 - for _, b := range yyq1338 { - if b { - yynn1338++ - } - } - r.EncodeMapStart(yynn1338) - yynn1338 = 0 - } - if yyr1338 || yy2arr1338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1338[0] { - if x.Protocol == nil { - r.EncodeNil() - } else { - yy1340 := *x.Protocol - yym1341 := z.EncBinary() - _ = yym1341 - if false { - } else if z.HasExtensions() && z.EncExt(yy1340) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1340)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1338[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("protocol")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Protocol == nil { - r.EncodeNil() - } else { - yy1342 := *x.Protocol - yym1343 := z.EncBinary() - _ = yym1343 - if false { - } else if z.HasExtensions() && z.EncExt(yy1342) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1342)) - } - } - } - } - if yyr1338 || yy2arr1338 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1338[1] { - if x.Port == nil { - r.EncodeNil() - } else { - yym1345 := z.EncBinary() - _ = yym1345 - if false { - } else if z.HasExtensions() && z.EncExt(x.Port) { - } else if !yym1345 && z.IsJSONHandle() { - z.EncJSONMarshal(x.Port) - } else { - z.EncFallback(x.Port) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1338[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("port")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Port == nil { - r.EncodeNil() - } else { - yym1346 := z.EncBinary() - _ = yym1346 - if false { - } else if z.HasExtensions() && z.EncExt(x.Port) { - } else if !yym1346 && z.IsJSONHandle() { - z.EncJSONMarshal(x.Port) - } else { - z.EncFallback(x.Port) - } - } - } - } - if yyr1338 || yy2arr1338 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NetworkPolicyPort) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1347 := z.DecBinary() - _ = yym1347 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1348 := r.ContainerType() - if yyct1348 == codecSelferValueTypeMap1234 { - yyl1348 := r.ReadMapStart() - if yyl1348 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1348, d) - } - } else if yyct1348 == codecSelferValueTypeArray1234 { - yyl1348 := r.ReadArrayStart() - if yyl1348 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1348, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1349Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1349Slc - var yyhl1349 bool = l >= 0 - for yyj1349 := 0; ; yyj1349++ { - if yyhl1349 { - if yyj1349 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1349Slc = r.DecodeBytes(yys1349Slc, true, true) - yys1349 := string(yys1349Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1349 { - case "protocol": - if r.TryDecodeAsNil() { - if x.Protocol != nil { - x.Protocol = nil - } - } else { - if x.Protocol == nil { - x.Protocol = new(pkg2_api.Protocol) - } - x.Protocol.CodecDecodeSelf(d) - } - case "port": - if r.TryDecodeAsNil() { - if x.Port != nil { - x.Port = nil - } - } else { - if x.Port == nil { - x.Port = new(pkg5_intstr.IntOrString) - } - yym1352 := z.DecBinary() - _ = yym1352 - if false { - } else if z.HasExtensions() && z.DecExt(x.Port) { - } else if !yym1352 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.Port) - } else { - z.DecFallback(x.Port, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1349) - } // end switch yys1349 - } // end for yyj1349 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1353 int - var yyb1353 bool - var yyhl1353 bool = l >= 0 - yyj1353++ - if yyhl1353 { - yyb1353 = yyj1353 > l - } else { - yyb1353 = r.CheckBreak() - } - if yyb1353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Protocol != nil { - x.Protocol = nil - } - } else { - if x.Protocol == nil { - x.Protocol = new(pkg2_api.Protocol) - } - x.Protocol.CodecDecodeSelf(d) - } - yyj1353++ - if yyhl1353 { - yyb1353 = yyj1353 > l - } else { - yyb1353 = r.CheckBreak() - } - if yyb1353 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Port != nil { - x.Port = nil - } - } else { - if x.Port == nil { - x.Port = new(pkg5_intstr.IntOrString) - } - yym1356 := z.DecBinary() - _ = yym1356 - if false { - } else if z.HasExtensions() && z.DecExt(x.Port) { - } else if !yym1356 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.Port) - } else { - z.DecFallback(x.Port, false) - } - } - for { - yyj1353++ - if yyhl1353 { - yyb1353 = yyj1353 > l - } else { - yyb1353 = r.CheckBreak() - } - if yyb1353 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1353-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1357 := z.EncBinary() - _ = yym1357 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1358 := !z.EncBinary() - yy2arr1358 := z.EncBasicHandle().StructToArray - var yyq1358 [2]bool - _, _, _ = yysep1358, yyq1358, yy2arr1358 - const yyr1358 bool = false - yyq1358[0] = x.PodSelector != nil - yyq1358[1] = x.NamespaceSelector != nil - var yynn1358 int - if yyr1358 || yy2arr1358 { - r.EncodeArrayStart(2) - } else { - yynn1358 = 0 - for _, b := range yyq1358 { - if b { - yynn1358++ - } - } - r.EncodeMapStart(yynn1358) - yynn1358 = 0 - } - if yyr1358 || yy2arr1358 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[0] { - if x.PodSelector == nil { - r.EncodeNil() - } else { - yym1360 := z.EncBinary() - _ = yym1360 - if false { - } else if z.HasExtensions() && z.EncExt(x.PodSelector) { - } else { - z.EncFallback(x.PodSelector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1358[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("podSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.PodSelector == nil { - r.EncodeNil() - } else { - yym1361 := z.EncBinary() - _ = yym1361 - if false { - } else if z.HasExtensions() && z.EncExt(x.PodSelector) { - } else { - z.EncFallback(x.PodSelector) - } - } - } - } - if yyr1358 || yy2arr1358 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[1] { - if x.NamespaceSelector == nil { - r.EncodeNil() - } else { - yym1363 := z.EncBinary() - _ = yym1363 - if false { - } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { - } else { - z.EncFallback(x.NamespaceSelector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq1358[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("namespaceSelector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.NamespaceSelector == nil { - r.EncodeNil() - } else { - yym1364 := z.EncBinary() - _ = yym1364 - if false { - } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { - } else { - z.EncFallback(x.NamespaceSelector) - } - } - } - } - if yyr1358 || yy2arr1358 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NetworkPolicyPeer) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1365 := z.DecBinary() - _ = yym1365 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1366 := r.ContainerType() - if yyct1366 == codecSelferValueTypeMap1234 { - yyl1366 := r.ReadMapStart() - if yyl1366 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1366, d) - } - } else if yyct1366 == codecSelferValueTypeArray1234 { - yyl1366 := r.ReadArrayStart() - if yyl1366 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1366, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1367Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1367Slc - var yyhl1367 bool = l >= 0 - for yyj1367 := 0; ; yyj1367++ { - if yyhl1367 { - if yyj1367 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1367Slc = r.DecodeBytes(yys1367Slc, true, true) - yys1367 := string(yys1367Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1367 { - case "podSelector": - if r.TryDecodeAsNil() { - if x.PodSelector != nil { - x.PodSelector = nil - } - } else { - if x.PodSelector == nil { - x.PodSelector = new(pkg1_unversioned.LabelSelector) - } - yym1369 := z.DecBinary() - _ = yym1369 - if false { - } else if z.HasExtensions() && z.DecExt(x.PodSelector) { - } else { - z.DecFallback(x.PodSelector, false) - } - } - case "namespaceSelector": - if r.TryDecodeAsNil() { - if x.NamespaceSelector != nil { - x.NamespaceSelector = nil - } - } else { - if x.NamespaceSelector == nil { - x.NamespaceSelector = new(pkg1_unversioned.LabelSelector) - } - yym1371 := z.DecBinary() - _ = yym1371 - if false { - } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { - } else { - z.DecFallback(x.NamespaceSelector, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys1367) - } // end switch yys1367 - } // end for yyj1367 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1372 int - var yyb1372 bool - var yyhl1372 bool = l >= 0 - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l - } else { - yyb1372 = r.CheckBreak() - } - if yyb1372 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.PodSelector != nil { - x.PodSelector = nil - } - } else { - if x.PodSelector == nil { - x.PodSelector = new(pkg1_unversioned.LabelSelector) - } - yym1374 := z.DecBinary() - _ = yym1374 - if false { - } else if z.HasExtensions() && z.DecExt(x.PodSelector) { - } else { - z.DecFallback(x.PodSelector, false) - } - } - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l - } else { - yyb1372 = r.CheckBreak() - } - if yyb1372 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.NamespaceSelector != nil { - x.NamespaceSelector = nil - } - } else { - if x.NamespaceSelector == nil { - x.NamespaceSelector = new(pkg1_unversioned.LabelSelector) - } - yym1376 := z.DecBinary() - _ = yym1376 - if false { - } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { - } else { - z.DecFallback(x.NamespaceSelector, false) - } - } - for { - yyj1372++ - if yyhl1372 { - yyb1372 = yyj1372 > l - } else { - yyb1372 = r.CheckBreak() - } - if yyb1372 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1372-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *NetworkPolicyList) 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 [4]bool - _, _, _ = yysep1378, yyq1378, yy2arr1378 - const yyr1378 bool = false - yyq1378[0] = x.Kind != "" - yyq1378[1] = x.APIVersion != "" - yyq1378[2] = true - var yynn1378 int - if yyr1378 || yy2arr1378 { - r.EncodeArrayStart(4) - } else { - yynn1378 = 1 - for _, b := range yyq1378 { - if b { - yynn1378++ - } - } - r.EncodeMapStart(yynn1378) - yynn1378 = 0 - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[0] { - yym1380 := z.EncBinary() - _ = yym1380 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1378[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1381 := z.EncBinary() - _ = yym1381 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[1] { - yym1383 := z.EncBinary() - _ = yym1383 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1378[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1384 := z.EncBinary() - _ = yym1384 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1378[2] { - yy1386 := &x.ListMeta - yym1387 := z.EncBinary() - _ = yym1387 - if false { - } else if z.HasExtensions() && z.EncExt(yy1386) { - } else { - z.EncFallback(yy1386) - } - } else { - r.EncodeNil() - } - } else { - if yyq1378[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1388 := &x.ListMeta - yym1389 := z.EncBinary() - _ = yym1389 - if false { - } else if z.HasExtensions() && z.EncExt(yy1388) { - } else { - z.EncFallback(yy1388) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym1391 := z.EncBinary() - _ = yym1391 - if false { - } else { - h.encSliceNetworkPolicy(([]NetworkPolicy)(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 { - yym1392 := z.EncBinary() - _ = yym1392 - if false { - } else { - h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) - } - } - } - if yyr1378 || yy2arr1378 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *NetworkPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1393 := z.DecBinary() - _ = yym1393 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1394 := r.ContainerType() - if yyct1394 == codecSelferValueTypeMap1234 { - yyl1394 := r.ReadMapStart() - if yyl1394 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1394, d) - } - } else if yyct1394 == codecSelferValueTypeArray1234 { - yyl1394 := r.ReadArrayStart() - if yyl1394 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1394, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *NetworkPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys1395Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1395Slc - var yyhl1395 bool = l >= 0 - for yyj1395 := 0; ; yyj1395++ { - if yyhl1395 { - if yyj1395 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1395Slc = r.DecodeBytes(yys1395Slc, true, true) - yys1395 := string(yys1395Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1395 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv1398 := &x.ListMeta - yym1399 := z.DecBinary() - _ = yym1399 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1398) { - } else { - z.DecFallback(yyv1398, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1400 := &x.Items - yym1401 := z.DecBinary() - _ = yym1401 - if false { - } else { - h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv1400), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys1395) - } // end switch yys1395 - } // end for yyj1395 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj1402 int - var yyb1402 bool - var yyhl1402 bool = l >= 0 - yyj1402++ - if yyhl1402 { - yyb1402 = yyj1402 > l - } else { - yyb1402 = r.CheckBreak() - } - if yyb1402 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj1402++ - if yyhl1402 { - yyb1402 = yyj1402 > l - } else { - yyb1402 = r.CheckBreak() - } - if yyb1402 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1402++ - if yyhl1402 { - yyb1402 = yyj1402 > l - } else { - yyb1402 = r.CheckBreak() - } - if yyb1402 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv1405 := &x.ListMeta - yym1406 := z.DecBinary() - _ = yym1406 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1405) { - } else { - z.DecFallback(yyv1405, false) - } - } - yyj1402++ - if yyhl1402 { - yyb1402 = yyj1402 > l - } else { - yyb1402 = r.CheckBreak() - } - if yyb1402 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv1407 := &x.Items - yym1408 := z.DecBinary() - _ = yym1408 - if false { - } else { - h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv1407), d) - } - } - for { - yyj1402++ - if yyhl1402 { - yyb1402 = yyj1402 > l - } else { - yyb1402 = r.CheckBreak() - } - if yyb1402 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1402-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceCustomMetricTarget(v []CustomMetricTarget, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1409 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1410 := &yyv1409 - yy1410.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCustomMetricTarget(v *[]CustomMetricTarget, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1411 := *v - yyh1411, yyl1411 := z.DecSliceHelperStart() - var yyc1411 bool - if yyl1411 == 0 { - if yyv1411 == nil { - yyv1411 = []CustomMetricTarget{} - yyc1411 = true - } else if len(yyv1411) != 0 { - yyv1411 = yyv1411[:0] - yyc1411 = true - } - } else if yyl1411 > 0 { - var yyrr1411, yyrl1411 int - var yyrt1411 bool - if yyl1411 > cap(yyv1411) { - - yyrg1411 := len(yyv1411) > 0 - yyv21411 := yyv1411 - yyrl1411, yyrt1411 = z.DecInferLen(yyl1411, z.DecBasicHandle().MaxInitLen, 72) - if yyrt1411 { - if yyrl1411 <= cap(yyv1411) { - yyv1411 = yyv1411[:yyrl1411] - } else { - yyv1411 = make([]CustomMetricTarget, yyrl1411) - } - } else { - yyv1411 = make([]CustomMetricTarget, yyrl1411) - } - yyc1411 = true - yyrr1411 = len(yyv1411) - if yyrg1411 { - copy(yyv1411, yyv21411) - } - } else if yyl1411 != len(yyv1411) { - yyv1411 = yyv1411[:yyl1411] - yyc1411 = true - } - yyj1411 := 0 - for ; yyj1411 < yyrr1411; yyj1411++ { - yyh1411.ElemContainerState(yyj1411) - if r.TryDecodeAsNil() { - yyv1411[yyj1411] = CustomMetricTarget{} - } else { - yyv1412 := &yyv1411[yyj1411] - yyv1412.CodecDecodeSelf(d) - } - - } - if yyrt1411 { - for ; yyj1411 < yyl1411; yyj1411++ { - yyv1411 = append(yyv1411, CustomMetricTarget{}) - yyh1411.ElemContainerState(yyj1411) - if r.TryDecodeAsNil() { - yyv1411[yyj1411] = CustomMetricTarget{} - } else { - yyv1413 := &yyv1411[yyj1411] - yyv1413.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1411 := 0 - for ; !r.CheckBreak(); yyj1411++ { - - if yyj1411 >= len(yyv1411) { - yyv1411 = append(yyv1411, CustomMetricTarget{}) // var yyz1411 CustomMetricTarget - yyc1411 = true - } - yyh1411.ElemContainerState(yyj1411) - if yyj1411 < len(yyv1411) { - if r.TryDecodeAsNil() { - yyv1411[yyj1411] = CustomMetricTarget{} - } else { - yyv1414 := &yyv1411[yyj1411] - yyv1414.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1411 < len(yyv1411) { - yyv1411 = yyv1411[:yyj1411] - yyc1411 = true - } else if yyj1411 == 0 && yyv1411 == nil { - yyv1411 = []CustomMetricTarget{} - yyc1411 = true - } - } - yyh1411.End() - if yyc1411 { - *v = yyv1411 - } -} - -func (x codecSelfer1234) encSliceCustomMetricCurrentStatus(v []CustomMetricCurrentStatus, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1415 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1416 := &yyv1415 - yy1416.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceCustomMetricCurrentStatus(v *[]CustomMetricCurrentStatus, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1417 := *v - yyh1417, yyl1417 := z.DecSliceHelperStart() - var yyc1417 bool - if yyl1417 == 0 { - if yyv1417 == nil { - yyv1417 = []CustomMetricCurrentStatus{} - yyc1417 = true - } else if len(yyv1417) != 0 { - yyv1417 = yyv1417[:0] - yyc1417 = true - } - } else if yyl1417 > 0 { - var yyrr1417, yyrl1417 int - var yyrt1417 bool - if yyl1417 > cap(yyv1417) { - - yyrg1417 := len(yyv1417) > 0 - yyv21417 := yyv1417 - yyrl1417, yyrt1417 = z.DecInferLen(yyl1417, z.DecBasicHandle().MaxInitLen, 72) - if yyrt1417 { - if yyrl1417 <= cap(yyv1417) { - yyv1417 = yyv1417[:yyrl1417] - } else { - yyv1417 = make([]CustomMetricCurrentStatus, yyrl1417) - } - } else { - yyv1417 = make([]CustomMetricCurrentStatus, yyrl1417) - } - yyc1417 = true - yyrr1417 = len(yyv1417) - if yyrg1417 { - copy(yyv1417, yyv21417) - } - } else if yyl1417 != len(yyv1417) { - yyv1417 = yyv1417[:yyl1417] - yyc1417 = true - } - yyj1417 := 0 - for ; yyj1417 < yyrr1417; yyj1417++ { - yyh1417.ElemContainerState(yyj1417) - if r.TryDecodeAsNil() { - yyv1417[yyj1417] = CustomMetricCurrentStatus{} - } else { - yyv1418 := &yyv1417[yyj1417] - yyv1418.CodecDecodeSelf(d) - } - - } - if yyrt1417 { - for ; yyj1417 < yyl1417; yyj1417++ { - yyv1417 = append(yyv1417, CustomMetricCurrentStatus{}) - yyh1417.ElemContainerState(yyj1417) - if r.TryDecodeAsNil() { - yyv1417[yyj1417] = CustomMetricCurrentStatus{} - } else { - yyv1419 := &yyv1417[yyj1417] - yyv1419.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1417 := 0 - for ; !r.CheckBreak(); yyj1417++ { - - if yyj1417 >= len(yyv1417) { - yyv1417 = append(yyv1417, CustomMetricCurrentStatus{}) // var yyz1417 CustomMetricCurrentStatus - yyc1417 = true - } - yyh1417.ElemContainerState(yyj1417) - if yyj1417 < len(yyv1417) { - if r.TryDecodeAsNil() { - yyv1417[yyj1417] = CustomMetricCurrentStatus{} - } else { - yyv1420 := &yyv1417[yyj1417] - yyv1420.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1417 < len(yyv1417) { - yyv1417 = yyv1417[:yyj1417] - yyc1417 = true - } else if yyj1417 == 0 && yyv1417 == nil { - yyv1417 = []CustomMetricCurrentStatus{} - yyc1417 = true - } - } - yyh1417.End() - if yyc1417 { - *v = yyv1417 - } -} - -func (x codecSelfer1234) encSliceAPIVersion(v []APIVersion, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1421 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1422 := &yyv1421 - yy1422.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceAPIVersion(v *[]APIVersion, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1423 := *v - yyh1423, yyl1423 := z.DecSliceHelperStart() - var yyc1423 bool - if yyl1423 == 0 { - if yyv1423 == nil { - yyv1423 = []APIVersion{} - yyc1423 = true - } else if len(yyv1423) != 0 { - yyv1423 = yyv1423[:0] - yyc1423 = true - } - } else if yyl1423 > 0 { - var yyrr1423, yyrl1423 int - var yyrt1423 bool - if yyl1423 > cap(yyv1423) { - - yyrg1423 := len(yyv1423) > 0 - yyv21423 := yyv1423 - yyrl1423, yyrt1423 = z.DecInferLen(yyl1423, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1423 { - if yyrl1423 <= cap(yyv1423) { - yyv1423 = yyv1423[:yyrl1423] - } else { - yyv1423 = make([]APIVersion, yyrl1423) - } - } else { - yyv1423 = make([]APIVersion, yyrl1423) - } - yyc1423 = true - yyrr1423 = len(yyv1423) - if yyrg1423 { - copy(yyv1423, yyv21423) - } - } else if yyl1423 != len(yyv1423) { - yyv1423 = yyv1423[:yyl1423] - yyc1423 = true - } - yyj1423 := 0 - for ; yyj1423 < yyrr1423; yyj1423++ { - yyh1423.ElemContainerState(yyj1423) - if r.TryDecodeAsNil() { - yyv1423[yyj1423] = APIVersion{} - } else { - yyv1424 := &yyv1423[yyj1423] - yyv1424.CodecDecodeSelf(d) - } - - } - if yyrt1423 { - for ; yyj1423 < yyl1423; yyj1423++ { - yyv1423 = append(yyv1423, APIVersion{}) - yyh1423.ElemContainerState(yyj1423) - if r.TryDecodeAsNil() { - yyv1423[yyj1423] = APIVersion{} - } else { - yyv1425 := &yyv1423[yyj1423] - yyv1425.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1423 := 0 - for ; !r.CheckBreak(); yyj1423++ { - - if yyj1423 >= len(yyv1423) { - yyv1423 = append(yyv1423, APIVersion{}) // var yyz1423 APIVersion - yyc1423 = true - } - yyh1423.ElemContainerState(yyj1423) - if yyj1423 < len(yyv1423) { - if r.TryDecodeAsNil() { - yyv1423[yyj1423] = APIVersion{} - } else { - yyv1426 := &yyv1423[yyj1423] - yyv1426.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1423 < len(yyv1423) { - yyv1423 = yyv1423[:yyj1423] - yyc1423 = true - } else if yyj1423 == 0 && yyv1423 == nil { - yyv1423 = []APIVersion{} - yyc1423 = true - } - } - yyh1423.End() - if yyc1423 { - *v = yyv1423 - } -} - -func (x codecSelfer1234) encSliceThirdPartyResource(v []ThirdPartyResource, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1427 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1428 := &yyv1427 - yy1428.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceThirdPartyResource(v *[]ThirdPartyResource, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1429 := *v - yyh1429, yyl1429 := z.DecSliceHelperStart() - var yyc1429 bool - if yyl1429 == 0 { - if yyv1429 == nil { - yyv1429 = []ThirdPartyResource{} - yyc1429 = true - } else if len(yyv1429) != 0 { - yyv1429 = yyv1429[:0] - yyc1429 = true - } - } else if yyl1429 > 0 { - var yyrr1429, yyrl1429 int - var yyrt1429 bool - if yyl1429 > cap(yyv1429) { - - yyrg1429 := len(yyv1429) > 0 - yyv21429 := yyv1429 - yyrl1429, yyrt1429 = z.DecInferLen(yyl1429, z.DecBasicHandle().MaxInitLen, 296) - if yyrt1429 { - if yyrl1429 <= cap(yyv1429) { - yyv1429 = yyv1429[:yyrl1429] - } else { - yyv1429 = make([]ThirdPartyResource, yyrl1429) - } - } else { - yyv1429 = make([]ThirdPartyResource, yyrl1429) - } - yyc1429 = true - yyrr1429 = len(yyv1429) - if yyrg1429 { - copy(yyv1429, yyv21429) - } - } else if yyl1429 != len(yyv1429) { - yyv1429 = yyv1429[:yyl1429] - yyc1429 = true - } - yyj1429 := 0 - for ; yyj1429 < yyrr1429; yyj1429++ { - yyh1429.ElemContainerState(yyj1429) - if r.TryDecodeAsNil() { - yyv1429[yyj1429] = ThirdPartyResource{} - } else { - yyv1430 := &yyv1429[yyj1429] - yyv1430.CodecDecodeSelf(d) - } - - } - if yyrt1429 { - for ; yyj1429 < yyl1429; yyj1429++ { - yyv1429 = append(yyv1429, ThirdPartyResource{}) - yyh1429.ElemContainerState(yyj1429) - if r.TryDecodeAsNil() { - yyv1429[yyj1429] = ThirdPartyResource{} - } else { - yyv1431 := &yyv1429[yyj1429] - yyv1431.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1429 := 0 - for ; !r.CheckBreak(); yyj1429++ { - - if yyj1429 >= len(yyv1429) { - yyv1429 = append(yyv1429, ThirdPartyResource{}) // var yyz1429 ThirdPartyResource - yyc1429 = true - } - yyh1429.ElemContainerState(yyj1429) - if yyj1429 < len(yyv1429) { - if r.TryDecodeAsNil() { - yyv1429[yyj1429] = ThirdPartyResource{} - } else { - yyv1432 := &yyv1429[yyj1429] - yyv1432.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1429 < len(yyv1429) { - yyv1429 = yyv1429[:yyj1429] - yyc1429 = true - } else if yyj1429 == 0 && yyv1429 == nil { - yyv1429 = []ThirdPartyResource{} - yyc1429 = true - } - } - yyh1429.End() - if yyc1429 { - *v = yyv1429 - } -} - -func (x codecSelfer1234) encSliceDeploymentCondition(v []DeploymentCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1433 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1434 := &yyv1433 - yy1434.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceDeploymentCondition(v *[]DeploymentCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1435 := *v - yyh1435, yyl1435 := z.DecSliceHelperStart() - var yyc1435 bool - if yyl1435 == 0 { - if yyv1435 == nil { - yyv1435 = []DeploymentCondition{} - yyc1435 = true - } else if len(yyv1435) != 0 { - yyv1435 = yyv1435[:0] - yyc1435 = true - } - } else if yyl1435 > 0 { - var yyrr1435, yyrl1435 int - var yyrt1435 bool - if yyl1435 > cap(yyv1435) { - - yyrg1435 := len(yyv1435) > 0 - yyv21435 := yyv1435 - yyrl1435, yyrt1435 = z.DecInferLen(yyl1435, z.DecBasicHandle().MaxInitLen, 112) - if yyrt1435 { - if yyrl1435 <= cap(yyv1435) { - yyv1435 = yyv1435[:yyrl1435] - } else { - yyv1435 = make([]DeploymentCondition, yyrl1435) - } - } else { - yyv1435 = make([]DeploymentCondition, yyrl1435) - } - yyc1435 = true - yyrr1435 = len(yyv1435) - if yyrg1435 { - copy(yyv1435, yyv21435) - } - } else if yyl1435 != len(yyv1435) { - yyv1435 = yyv1435[:yyl1435] - yyc1435 = true - } - yyj1435 := 0 - for ; yyj1435 < yyrr1435; yyj1435++ { - yyh1435.ElemContainerState(yyj1435) - if r.TryDecodeAsNil() { - yyv1435[yyj1435] = DeploymentCondition{} - } else { - yyv1436 := &yyv1435[yyj1435] - yyv1436.CodecDecodeSelf(d) - } - - } - if yyrt1435 { - for ; yyj1435 < yyl1435; yyj1435++ { - yyv1435 = append(yyv1435, DeploymentCondition{}) - yyh1435.ElemContainerState(yyj1435) - if r.TryDecodeAsNil() { - yyv1435[yyj1435] = DeploymentCondition{} - } else { - yyv1437 := &yyv1435[yyj1435] - yyv1437.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1435 := 0 - for ; !r.CheckBreak(); yyj1435++ { - - if yyj1435 >= len(yyv1435) { - yyv1435 = append(yyv1435, DeploymentCondition{}) // var yyz1435 DeploymentCondition - yyc1435 = true - } - yyh1435.ElemContainerState(yyj1435) - if yyj1435 < len(yyv1435) { - if r.TryDecodeAsNil() { - yyv1435[yyj1435] = DeploymentCondition{} - } else { - yyv1438 := &yyv1435[yyj1435] - yyv1438.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1435 < len(yyv1435) { - yyv1435 = yyv1435[:yyj1435] - yyc1435 = true - } else if yyj1435 == 0 && yyv1435 == nil { - yyv1435 = []DeploymentCondition{} - yyc1435 = true - } - } - yyh1435.End() - if yyc1435 { - *v = yyv1435 - } -} - -func (x codecSelfer1234) encSliceDeployment(v []Deployment, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1439 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1440 := &yyv1439 - yy1440.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1441 := *v - yyh1441, yyl1441 := z.DecSliceHelperStart() - var yyc1441 bool - if yyl1441 == 0 { - if yyv1441 == nil { - yyv1441 = []Deployment{} - yyc1441 = true - } else if len(yyv1441) != 0 { - yyv1441 = yyv1441[:0] - yyc1441 = true - } - } else if yyl1441 > 0 { - var yyrr1441, yyrl1441 int - var yyrt1441 bool - if yyl1441 > cap(yyv1441) { - - yyrg1441 := len(yyv1441) > 0 - yyv21441 := yyv1441 - yyrl1441, yyrt1441 = z.DecInferLen(yyl1441, z.DecBasicHandle().MaxInitLen, 832) - if yyrt1441 { - if yyrl1441 <= cap(yyv1441) { - yyv1441 = yyv1441[:yyrl1441] - } else { - yyv1441 = make([]Deployment, yyrl1441) - } - } else { - yyv1441 = make([]Deployment, yyrl1441) - } - yyc1441 = true - yyrr1441 = len(yyv1441) - if yyrg1441 { - copy(yyv1441, yyv21441) - } - } else if yyl1441 != len(yyv1441) { - yyv1441 = yyv1441[:yyl1441] - yyc1441 = true - } - yyj1441 := 0 - for ; yyj1441 < yyrr1441; yyj1441++ { - yyh1441.ElemContainerState(yyj1441) - if r.TryDecodeAsNil() { - yyv1441[yyj1441] = Deployment{} - } else { - yyv1442 := &yyv1441[yyj1441] - yyv1442.CodecDecodeSelf(d) - } - - } - if yyrt1441 { - for ; yyj1441 < yyl1441; yyj1441++ { - yyv1441 = append(yyv1441, Deployment{}) - yyh1441.ElemContainerState(yyj1441) - if r.TryDecodeAsNil() { - yyv1441[yyj1441] = Deployment{} - } else { - yyv1443 := &yyv1441[yyj1441] - yyv1443.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1441 := 0 - for ; !r.CheckBreak(); yyj1441++ { - - if yyj1441 >= len(yyv1441) { - yyv1441 = append(yyv1441, Deployment{}) // var yyz1441 Deployment - yyc1441 = true - } - yyh1441.ElemContainerState(yyj1441) - if yyj1441 < len(yyv1441) { - if r.TryDecodeAsNil() { - yyv1441[yyj1441] = Deployment{} - } else { - yyv1444 := &yyv1441[yyj1441] - yyv1444.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1441 < len(yyv1441) { - yyv1441 = yyv1441[:yyj1441] - yyc1441 = true - } else if yyj1441 == 0 && yyv1441 == nil { - yyv1441 = []Deployment{} - yyc1441 = true - } - } - yyh1441.End() - if yyc1441 { - *v = yyv1441 - } -} - -func (x codecSelfer1234) encSliceDaemonSet(v []DaemonSet, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1445 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1446 := &yyv1445 - yy1446.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceDaemonSet(v *[]DaemonSet, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1447 := *v - yyh1447, yyl1447 := z.DecSliceHelperStart() - var yyc1447 bool - if yyl1447 == 0 { - if yyv1447 == nil { - yyv1447 = []DaemonSet{} - yyc1447 = true - } else if len(yyv1447) != 0 { - yyv1447 = yyv1447[:0] - yyc1447 = true - } - } else if yyl1447 > 0 { - var yyrr1447, yyrl1447 int - var yyrt1447 bool - if yyl1447 > cap(yyv1447) { - - yyrg1447 := len(yyv1447) > 0 - yyv21447 := yyv1447 - yyrl1447, yyrt1447 = z.DecInferLen(yyl1447, z.DecBasicHandle().MaxInitLen, 728) - if yyrt1447 { - if yyrl1447 <= cap(yyv1447) { - yyv1447 = yyv1447[:yyrl1447] - } else { - yyv1447 = make([]DaemonSet, yyrl1447) - } - } else { - yyv1447 = make([]DaemonSet, yyrl1447) - } - yyc1447 = true - yyrr1447 = len(yyv1447) - if yyrg1447 { - copy(yyv1447, yyv21447) - } - } else if yyl1447 != len(yyv1447) { - yyv1447 = yyv1447[:yyl1447] - yyc1447 = true - } - yyj1447 := 0 - for ; yyj1447 < yyrr1447; yyj1447++ { - yyh1447.ElemContainerState(yyj1447) - if r.TryDecodeAsNil() { - yyv1447[yyj1447] = DaemonSet{} - } else { - yyv1448 := &yyv1447[yyj1447] - yyv1448.CodecDecodeSelf(d) - } - - } - if yyrt1447 { - for ; yyj1447 < yyl1447; yyj1447++ { - yyv1447 = append(yyv1447, DaemonSet{}) - yyh1447.ElemContainerState(yyj1447) - if r.TryDecodeAsNil() { - yyv1447[yyj1447] = DaemonSet{} - } else { - yyv1449 := &yyv1447[yyj1447] - yyv1449.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1447 := 0 - for ; !r.CheckBreak(); yyj1447++ { - - if yyj1447 >= len(yyv1447) { - yyv1447 = append(yyv1447, DaemonSet{}) // var yyz1447 DaemonSet - yyc1447 = true - } - yyh1447.ElemContainerState(yyj1447) - if yyj1447 < len(yyv1447) { - if r.TryDecodeAsNil() { - yyv1447[yyj1447] = DaemonSet{} - } else { - yyv1450 := &yyv1447[yyj1447] - yyv1450.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1447 < len(yyv1447) { - yyv1447 = yyv1447[:yyj1447] - yyc1447 = true - } else if yyj1447 == 0 && yyv1447 == nil { - yyv1447 = []DaemonSet{} - yyc1447 = true - } - } - yyh1447.End() - if yyc1447 { - *v = yyv1447 - } -} - -func (x codecSelfer1234) encSliceThirdPartyResourceData(v []ThirdPartyResourceData, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1451 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1452 := &yyv1451 - yy1452.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceThirdPartyResourceData(v *[]ThirdPartyResourceData, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1453 := *v - yyh1453, yyl1453 := z.DecSliceHelperStart() - var yyc1453 bool - if yyl1453 == 0 { - if yyv1453 == nil { - yyv1453 = []ThirdPartyResourceData{} - yyc1453 = true - } else if len(yyv1453) != 0 { - yyv1453 = yyv1453[:0] - yyc1453 = true - } - } else if yyl1453 > 0 { - var yyrr1453, yyrl1453 int - var yyrt1453 bool - if yyl1453 > cap(yyv1453) { - - yyrg1453 := len(yyv1453) > 0 - yyv21453 := yyv1453 - yyrl1453, yyrt1453 = z.DecInferLen(yyl1453, z.DecBasicHandle().MaxInitLen, 280) - if yyrt1453 { - if yyrl1453 <= cap(yyv1453) { - yyv1453 = yyv1453[:yyrl1453] - } else { - yyv1453 = make([]ThirdPartyResourceData, yyrl1453) - } - } else { - yyv1453 = make([]ThirdPartyResourceData, yyrl1453) - } - yyc1453 = true - yyrr1453 = len(yyv1453) - if yyrg1453 { - copy(yyv1453, yyv21453) - } - } else if yyl1453 != len(yyv1453) { - yyv1453 = yyv1453[:yyl1453] - yyc1453 = true - } - yyj1453 := 0 - for ; yyj1453 < yyrr1453; yyj1453++ { - yyh1453.ElemContainerState(yyj1453) - if r.TryDecodeAsNil() { - yyv1453[yyj1453] = ThirdPartyResourceData{} - } else { - yyv1454 := &yyv1453[yyj1453] - yyv1454.CodecDecodeSelf(d) - } - - } - if yyrt1453 { - for ; yyj1453 < yyl1453; yyj1453++ { - yyv1453 = append(yyv1453, ThirdPartyResourceData{}) - yyh1453.ElemContainerState(yyj1453) - if r.TryDecodeAsNil() { - yyv1453[yyj1453] = ThirdPartyResourceData{} - } else { - yyv1455 := &yyv1453[yyj1453] - yyv1455.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1453 := 0 - for ; !r.CheckBreak(); yyj1453++ { - - if yyj1453 >= len(yyv1453) { - yyv1453 = append(yyv1453, ThirdPartyResourceData{}) // var yyz1453 ThirdPartyResourceData - yyc1453 = true - } - yyh1453.ElemContainerState(yyj1453) - if yyj1453 < len(yyv1453) { - if r.TryDecodeAsNil() { - yyv1453[yyj1453] = ThirdPartyResourceData{} - } else { - yyv1456 := &yyv1453[yyj1453] - yyv1456.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1453 < len(yyv1453) { - yyv1453 = yyv1453[:yyj1453] - yyc1453 = true - } else if yyj1453 == 0 && yyv1453 == nil { - yyv1453 = []ThirdPartyResourceData{} - yyc1453 = true - } - } - yyh1453.End() - if yyc1453 { - *v = yyv1453 - } -} - -func (x codecSelfer1234) encSliceIngress(v []Ingress, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1457 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1458 := &yyv1457 - yy1458.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceIngress(v *[]Ingress, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1459 := *v - yyh1459, yyl1459 := z.DecSliceHelperStart() - var yyc1459 bool - if yyl1459 == 0 { - if yyv1459 == nil { - yyv1459 = []Ingress{} - yyc1459 = true - } else if len(yyv1459) != 0 { - yyv1459 = yyv1459[:0] - yyc1459 = true - } - } else if yyl1459 > 0 { - var yyrr1459, yyrl1459 int - var yyrt1459 bool - if yyl1459 > cap(yyv1459) { - - yyrg1459 := len(yyv1459) > 0 - yyv21459 := yyv1459 - yyrl1459, yyrt1459 = z.DecInferLen(yyl1459, z.DecBasicHandle().MaxInitLen, 336) - if yyrt1459 { - if yyrl1459 <= cap(yyv1459) { - yyv1459 = yyv1459[:yyrl1459] - } else { - yyv1459 = make([]Ingress, yyrl1459) - } - } else { - yyv1459 = make([]Ingress, yyrl1459) - } - yyc1459 = true - yyrr1459 = len(yyv1459) - if yyrg1459 { - copy(yyv1459, yyv21459) - } - } else if yyl1459 != len(yyv1459) { - yyv1459 = yyv1459[:yyl1459] - yyc1459 = true - } - yyj1459 := 0 - for ; yyj1459 < yyrr1459; yyj1459++ { - yyh1459.ElemContainerState(yyj1459) - if r.TryDecodeAsNil() { - yyv1459[yyj1459] = Ingress{} - } else { - yyv1460 := &yyv1459[yyj1459] - yyv1460.CodecDecodeSelf(d) - } - - } - if yyrt1459 { - for ; yyj1459 < yyl1459; yyj1459++ { - yyv1459 = append(yyv1459, Ingress{}) - yyh1459.ElemContainerState(yyj1459) - if r.TryDecodeAsNil() { - yyv1459[yyj1459] = Ingress{} - } else { - yyv1461 := &yyv1459[yyj1459] - yyv1461.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1459 := 0 - for ; !r.CheckBreak(); yyj1459++ { - - if yyj1459 >= len(yyv1459) { - yyv1459 = append(yyv1459, Ingress{}) // var yyz1459 Ingress - yyc1459 = true - } - yyh1459.ElemContainerState(yyj1459) - if yyj1459 < len(yyv1459) { - if r.TryDecodeAsNil() { - yyv1459[yyj1459] = Ingress{} - } else { - yyv1462 := &yyv1459[yyj1459] - yyv1462.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1459 < len(yyv1459) { - yyv1459 = yyv1459[:yyj1459] - yyc1459 = true - } else if yyj1459 == 0 && yyv1459 == nil { - yyv1459 = []Ingress{} - yyc1459 = true - } - } - yyh1459.End() - if yyc1459 { - *v = yyv1459 - } -} - -func (x codecSelfer1234) encSliceIngressTLS(v []IngressTLS, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1463 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1464 := &yyv1463 - yy1464.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceIngressTLS(v *[]IngressTLS, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1465 := *v - yyh1465, yyl1465 := z.DecSliceHelperStart() - var yyc1465 bool - if yyl1465 == 0 { - if yyv1465 == nil { - yyv1465 = []IngressTLS{} - yyc1465 = true - } else if len(yyv1465) != 0 { - yyv1465 = yyv1465[:0] - yyc1465 = true - } - } else if yyl1465 > 0 { - var yyrr1465, yyrl1465 int - var yyrt1465 bool - if yyl1465 > cap(yyv1465) { - - yyrg1465 := len(yyv1465) > 0 - yyv21465 := yyv1465 - yyrl1465, yyrt1465 = z.DecInferLen(yyl1465, z.DecBasicHandle().MaxInitLen, 40) - if yyrt1465 { - if yyrl1465 <= cap(yyv1465) { - yyv1465 = yyv1465[:yyrl1465] - } else { - yyv1465 = make([]IngressTLS, yyrl1465) - } - } else { - yyv1465 = make([]IngressTLS, yyrl1465) - } - yyc1465 = true - yyrr1465 = len(yyv1465) - if yyrg1465 { - copy(yyv1465, yyv21465) - } - } else if yyl1465 != len(yyv1465) { - yyv1465 = yyv1465[:yyl1465] - yyc1465 = true - } - yyj1465 := 0 - for ; yyj1465 < yyrr1465; yyj1465++ { - yyh1465.ElemContainerState(yyj1465) - if r.TryDecodeAsNil() { - yyv1465[yyj1465] = IngressTLS{} - } else { - yyv1466 := &yyv1465[yyj1465] - yyv1466.CodecDecodeSelf(d) - } - - } - if yyrt1465 { - for ; yyj1465 < yyl1465; yyj1465++ { - yyv1465 = append(yyv1465, IngressTLS{}) - yyh1465.ElemContainerState(yyj1465) - if r.TryDecodeAsNil() { - yyv1465[yyj1465] = IngressTLS{} - } else { - yyv1467 := &yyv1465[yyj1465] - yyv1467.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1465 := 0 - for ; !r.CheckBreak(); yyj1465++ { - - if yyj1465 >= len(yyv1465) { - yyv1465 = append(yyv1465, IngressTLS{}) // var yyz1465 IngressTLS - yyc1465 = true - } - yyh1465.ElemContainerState(yyj1465) - if yyj1465 < len(yyv1465) { - if r.TryDecodeAsNil() { - yyv1465[yyj1465] = IngressTLS{} - } else { - yyv1468 := &yyv1465[yyj1465] - yyv1468.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1465 < len(yyv1465) { - yyv1465 = yyv1465[:yyj1465] - yyc1465 = true - } else if yyj1465 == 0 && yyv1465 == nil { - yyv1465 = []IngressTLS{} - yyc1465 = true - } - } - yyh1465.End() - if yyc1465 { - *v = yyv1465 - } -} - -func (x codecSelfer1234) encSliceIngressRule(v []IngressRule, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1469 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1470 := &yyv1469 - yy1470.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceIngressRule(v *[]IngressRule, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1471 := *v - yyh1471, yyl1471 := z.DecSliceHelperStart() - var yyc1471 bool - if yyl1471 == 0 { - if yyv1471 == nil { - yyv1471 = []IngressRule{} - yyc1471 = true - } else if len(yyv1471) != 0 { - yyv1471 = yyv1471[:0] - yyc1471 = true - } - } else if yyl1471 > 0 { - var yyrr1471, yyrl1471 int - var yyrt1471 bool - if yyl1471 > cap(yyv1471) { - - yyrg1471 := len(yyv1471) > 0 - yyv21471 := yyv1471 - yyrl1471, yyrt1471 = z.DecInferLen(yyl1471, z.DecBasicHandle().MaxInitLen, 24) - if yyrt1471 { - if yyrl1471 <= cap(yyv1471) { - yyv1471 = yyv1471[:yyrl1471] - } else { - yyv1471 = make([]IngressRule, yyrl1471) - } - } else { - yyv1471 = make([]IngressRule, yyrl1471) - } - yyc1471 = true - yyrr1471 = len(yyv1471) - if yyrg1471 { - copy(yyv1471, yyv21471) - } - } else if yyl1471 != len(yyv1471) { - yyv1471 = yyv1471[:yyl1471] - yyc1471 = true - } - yyj1471 := 0 - for ; yyj1471 < yyrr1471; yyj1471++ { - yyh1471.ElemContainerState(yyj1471) - if r.TryDecodeAsNil() { - yyv1471[yyj1471] = IngressRule{} - } else { - yyv1472 := &yyv1471[yyj1471] - yyv1472.CodecDecodeSelf(d) - } - - } - if yyrt1471 { - for ; yyj1471 < yyl1471; yyj1471++ { - yyv1471 = append(yyv1471, IngressRule{}) - yyh1471.ElemContainerState(yyj1471) - if r.TryDecodeAsNil() { - yyv1471[yyj1471] = IngressRule{} - } else { - yyv1473 := &yyv1471[yyj1471] - yyv1473.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1471 := 0 - for ; !r.CheckBreak(); yyj1471++ { - - if yyj1471 >= len(yyv1471) { - yyv1471 = append(yyv1471, IngressRule{}) // var yyz1471 IngressRule - yyc1471 = true - } - yyh1471.ElemContainerState(yyj1471) - if yyj1471 < len(yyv1471) { - if r.TryDecodeAsNil() { - yyv1471[yyj1471] = IngressRule{} - } else { - yyv1474 := &yyv1471[yyj1471] - yyv1474.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1471 < len(yyv1471) { - yyv1471 = yyv1471[:yyj1471] - yyc1471 = true - } else if yyj1471 == 0 && yyv1471 == nil { - yyv1471 = []IngressRule{} - yyc1471 = true - } - } - yyh1471.End() - if yyc1471 { - *v = yyv1471 - } -} - -func (x codecSelfer1234) encSliceHTTPIngressPath(v []HTTPIngressPath, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1475 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1476 := &yyv1475 - yy1476.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceHTTPIngressPath(v *[]HTTPIngressPath, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1477 := *v - yyh1477, yyl1477 := z.DecSliceHelperStart() - var yyc1477 bool - if yyl1477 == 0 { - if yyv1477 == nil { - yyv1477 = []HTTPIngressPath{} - yyc1477 = true - } else if len(yyv1477) != 0 { - yyv1477 = yyv1477[:0] - yyc1477 = true - } - } else if yyl1477 > 0 { - var yyrr1477, yyrl1477 int - var yyrt1477 bool - if yyl1477 > cap(yyv1477) { - - yyrg1477 := len(yyv1477) > 0 - yyv21477 := yyv1477 - yyrl1477, yyrt1477 = z.DecInferLen(yyl1477, z.DecBasicHandle().MaxInitLen, 64) - if yyrt1477 { - if yyrl1477 <= cap(yyv1477) { - yyv1477 = yyv1477[:yyrl1477] - } else { - yyv1477 = make([]HTTPIngressPath, yyrl1477) - } - } else { - yyv1477 = make([]HTTPIngressPath, yyrl1477) - } - yyc1477 = true - yyrr1477 = len(yyv1477) - if yyrg1477 { - copy(yyv1477, yyv21477) - } - } else if yyl1477 != len(yyv1477) { - yyv1477 = yyv1477[:yyl1477] - yyc1477 = true - } - yyj1477 := 0 - for ; yyj1477 < yyrr1477; yyj1477++ { - yyh1477.ElemContainerState(yyj1477) - if r.TryDecodeAsNil() { - yyv1477[yyj1477] = HTTPIngressPath{} - } else { - yyv1478 := &yyv1477[yyj1477] - yyv1478.CodecDecodeSelf(d) - } - - } - if yyrt1477 { - for ; yyj1477 < yyl1477; yyj1477++ { - yyv1477 = append(yyv1477, HTTPIngressPath{}) - yyh1477.ElemContainerState(yyj1477) - if r.TryDecodeAsNil() { - yyv1477[yyj1477] = HTTPIngressPath{} - } else { - yyv1479 := &yyv1477[yyj1477] - yyv1479.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1477 := 0 - for ; !r.CheckBreak(); yyj1477++ { - - if yyj1477 >= len(yyv1477) { - yyv1477 = append(yyv1477, HTTPIngressPath{}) // var yyz1477 HTTPIngressPath - yyc1477 = true - } - yyh1477.ElemContainerState(yyj1477) - if yyj1477 < len(yyv1477) { - if r.TryDecodeAsNil() { - yyv1477[yyj1477] = HTTPIngressPath{} - } else { - yyv1480 := &yyv1477[yyj1477] - yyv1480.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1477 < len(yyv1477) { - yyv1477 = yyv1477[:yyj1477] - yyc1477 = true - } else if yyj1477 == 0 && yyv1477 == nil { - yyv1477 = []HTTPIngressPath{} - yyc1477 = true - } - } - yyh1477.End() - if yyc1477 { - *v = yyv1477 - } -} - -func (x codecSelfer1234) encSliceReplicaSet(v []ReplicaSet, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1481 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1482 := &yyv1481 - yy1482.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceReplicaSet(v *[]ReplicaSet, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1483 := *v - yyh1483, yyl1483 := z.DecSliceHelperStart() - var yyc1483 bool - if yyl1483 == 0 { - if yyv1483 == nil { - yyv1483 = []ReplicaSet{} - yyc1483 = true - } else if len(yyv1483) != 0 { - yyv1483 = yyv1483[:0] - yyc1483 = true - } - } else if yyl1483 > 0 { - var yyrr1483, yyrl1483 int - var yyrt1483 bool - if yyl1483 > cap(yyv1483) { - - yyrg1483 := len(yyv1483) > 0 - yyv21483 := yyv1483 - yyrl1483, yyrt1483 = z.DecInferLen(yyl1483, z.DecBasicHandle().MaxInitLen, 768) - if yyrt1483 { - if yyrl1483 <= cap(yyv1483) { - yyv1483 = yyv1483[:yyrl1483] - } else { - yyv1483 = make([]ReplicaSet, yyrl1483) - } - } else { - yyv1483 = make([]ReplicaSet, yyrl1483) - } - yyc1483 = true - yyrr1483 = len(yyv1483) - if yyrg1483 { - copy(yyv1483, yyv21483) - } - } else if yyl1483 != len(yyv1483) { - yyv1483 = yyv1483[:yyl1483] - yyc1483 = true - } - yyj1483 := 0 - for ; yyj1483 < yyrr1483; yyj1483++ { - yyh1483.ElemContainerState(yyj1483) - if r.TryDecodeAsNil() { - yyv1483[yyj1483] = ReplicaSet{} - } else { - yyv1484 := &yyv1483[yyj1483] - yyv1484.CodecDecodeSelf(d) - } - - } - if yyrt1483 { - for ; yyj1483 < yyl1483; yyj1483++ { - yyv1483 = append(yyv1483, ReplicaSet{}) - yyh1483.ElemContainerState(yyj1483) - if r.TryDecodeAsNil() { - yyv1483[yyj1483] = ReplicaSet{} - } else { - yyv1485 := &yyv1483[yyj1483] - yyv1485.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1483 := 0 - for ; !r.CheckBreak(); yyj1483++ { - - if yyj1483 >= len(yyv1483) { - yyv1483 = append(yyv1483, ReplicaSet{}) // var yyz1483 ReplicaSet - yyc1483 = true - } - yyh1483.ElemContainerState(yyj1483) - if yyj1483 < len(yyv1483) { - if r.TryDecodeAsNil() { - yyv1483[yyj1483] = ReplicaSet{} - } else { - yyv1486 := &yyv1483[yyj1483] - yyv1486.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1483 < len(yyv1483) { - yyv1483 = yyv1483[:yyj1483] - yyc1483 = true - } else if yyj1483 == 0 && yyv1483 == nil { - yyv1483 = []ReplicaSet{} - yyc1483 = true - } - } - yyh1483.End() - if yyc1483 { - *v = yyv1483 - } -} - -func (x codecSelfer1234) encSliceReplicaSetCondition(v []ReplicaSetCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1487 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1488 := &yyv1487 - yy1488.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceReplicaSetCondition(v *[]ReplicaSetCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1489 := *v - yyh1489, yyl1489 := z.DecSliceHelperStart() - var yyc1489 bool - if yyl1489 == 0 { - if yyv1489 == nil { - yyv1489 = []ReplicaSetCondition{} - yyc1489 = true - } else if len(yyv1489) != 0 { - yyv1489 = yyv1489[:0] - yyc1489 = true - } - } else if yyl1489 > 0 { - var yyrr1489, yyrl1489 int - var yyrt1489 bool - if yyl1489 > cap(yyv1489) { - - yyrg1489 := len(yyv1489) > 0 - yyv21489 := yyv1489 - yyrl1489, yyrt1489 = z.DecInferLen(yyl1489, z.DecBasicHandle().MaxInitLen, 88) - if yyrt1489 { - if yyrl1489 <= cap(yyv1489) { - yyv1489 = yyv1489[:yyrl1489] - } else { - yyv1489 = make([]ReplicaSetCondition, yyrl1489) - } - } else { - yyv1489 = make([]ReplicaSetCondition, yyrl1489) - } - yyc1489 = true - yyrr1489 = len(yyv1489) - if yyrg1489 { - copy(yyv1489, yyv21489) - } - } else if yyl1489 != len(yyv1489) { - yyv1489 = yyv1489[:yyl1489] - yyc1489 = true - } - yyj1489 := 0 - for ; yyj1489 < yyrr1489; yyj1489++ { - yyh1489.ElemContainerState(yyj1489) - if r.TryDecodeAsNil() { - yyv1489[yyj1489] = ReplicaSetCondition{} - } else { - yyv1490 := &yyv1489[yyj1489] - yyv1490.CodecDecodeSelf(d) - } - - } - if yyrt1489 { - for ; yyj1489 < yyl1489; yyj1489++ { - yyv1489 = append(yyv1489, ReplicaSetCondition{}) - yyh1489.ElemContainerState(yyj1489) - if r.TryDecodeAsNil() { - yyv1489[yyj1489] = ReplicaSetCondition{} - } else { - yyv1491 := &yyv1489[yyj1489] - yyv1491.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1489 := 0 - for ; !r.CheckBreak(); yyj1489++ { - - if yyj1489 >= len(yyv1489) { - yyv1489 = append(yyv1489, ReplicaSetCondition{}) // var yyz1489 ReplicaSetCondition - yyc1489 = true - } - yyh1489.ElemContainerState(yyj1489) - if yyj1489 < len(yyv1489) { - if r.TryDecodeAsNil() { - yyv1489[yyj1489] = ReplicaSetCondition{} - } else { - yyv1492 := &yyv1489[yyj1489] - yyv1492.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1489 < len(yyv1489) { - yyv1489 = yyv1489[:yyj1489] - yyc1489 = true - } else if yyj1489 == 0 && yyv1489 == nil { - yyv1489 = []ReplicaSetCondition{} - yyc1489 = true - } - } - yyh1489.End() - if yyc1489 { - *v = yyv1489 - } -} - -func (x codecSelfer1234) encSliceapi_Capability(v []pkg2_api.Capability, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1493 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1494 := z.EncBinary() - _ = yym1494 - if false { - } else if z.HasExtensions() && z.EncExt(yyv1493) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyv1493)) - } - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceapi_Capability(v *[]pkg2_api.Capability, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1495 := *v - yyh1495, yyl1495 := z.DecSliceHelperStart() - var yyc1495 bool - if yyl1495 == 0 { - if yyv1495 == nil { - yyv1495 = []pkg2_api.Capability{} - yyc1495 = true - } else if len(yyv1495) != 0 { - yyv1495 = yyv1495[:0] - yyc1495 = true - } - } else if yyl1495 > 0 { - var yyrr1495, yyrl1495 int - var yyrt1495 bool - if yyl1495 > cap(yyv1495) { - - yyrl1495, yyrt1495 = z.DecInferLen(yyl1495, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1495 { - if yyrl1495 <= cap(yyv1495) { - yyv1495 = yyv1495[:yyrl1495] - } else { - yyv1495 = make([]pkg2_api.Capability, yyrl1495) - } - } else { - yyv1495 = make([]pkg2_api.Capability, yyrl1495) - } - yyc1495 = true - yyrr1495 = len(yyv1495) - } else if yyl1495 != len(yyv1495) { - yyv1495 = yyv1495[:yyl1495] - yyc1495 = true - } - yyj1495 := 0 - for ; yyj1495 < yyrr1495; yyj1495++ { - yyh1495.ElemContainerState(yyj1495) - if r.TryDecodeAsNil() { - yyv1495[yyj1495] = "" - } else { - yyv1495[yyj1495] = pkg2_api.Capability(r.DecodeString()) - } - - } - if yyrt1495 { - for ; yyj1495 < yyl1495; yyj1495++ { - yyv1495 = append(yyv1495, "") - yyh1495.ElemContainerState(yyj1495) - if r.TryDecodeAsNil() { - yyv1495[yyj1495] = "" - } else { - yyv1495[yyj1495] = pkg2_api.Capability(r.DecodeString()) - } - - } - } - - } else { - yyj1495 := 0 - for ; !r.CheckBreak(); yyj1495++ { - - if yyj1495 >= len(yyv1495) { - yyv1495 = append(yyv1495, "") // var yyz1495 pkg2_api.Capability - yyc1495 = true - } - yyh1495.ElemContainerState(yyj1495) - if yyj1495 < len(yyv1495) { - if r.TryDecodeAsNil() { - yyv1495[yyj1495] = "" - } else { - yyv1495[yyj1495] = pkg2_api.Capability(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj1495 < len(yyv1495) { - yyv1495 = yyv1495[:yyj1495] - yyc1495 = true - } else if yyj1495 == 0 && yyv1495 == nil { - yyv1495 = []pkg2_api.Capability{} - yyc1495 = true - } - } - yyh1495.End() - if yyc1495 { - *v = yyv1495 - } -} - -func (x codecSelfer1234) encSliceFSType(v []FSType, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1499 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv1499.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceFSType(v *[]FSType, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1500 := *v - yyh1500, yyl1500 := z.DecSliceHelperStart() - var yyc1500 bool - if yyl1500 == 0 { - if yyv1500 == nil { - yyv1500 = []FSType{} - yyc1500 = true - } else if len(yyv1500) != 0 { - yyv1500 = yyv1500[:0] - yyc1500 = true - } - } else if yyl1500 > 0 { - var yyrr1500, yyrl1500 int - var yyrt1500 bool - if yyl1500 > cap(yyv1500) { - - yyrl1500, yyrt1500 = z.DecInferLen(yyl1500, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1500 { - if yyrl1500 <= cap(yyv1500) { - yyv1500 = yyv1500[:yyrl1500] - } else { - yyv1500 = make([]FSType, yyrl1500) - } - } else { - yyv1500 = make([]FSType, yyrl1500) - } - yyc1500 = true - yyrr1500 = len(yyv1500) - } else if yyl1500 != len(yyv1500) { - yyv1500 = yyv1500[:yyl1500] - yyc1500 = true - } - yyj1500 := 0 - for ; yyj1500 < yyrr1500; yyj1500++ { - yyh1500.ElemContainerState(yyj1500) - if r.TryDecodeAsNil() { - yyv1500[yyj1500] = "" - } else { - yyv1500[yyj1500] = FSType(r.DecodeString()) - } - - } - if yyrt1500 { - for ; yyj1500 < yyl1500; yyj1500++ { - yyv1500 = append(yyv1500, "") - yyh1500.ElemContainerState(yyj1500) - if r.TryDecodeAsNil() { - yyv1500[yyj1500] = "" - } else { - yyv1500[yyj1500] = FSType(r.DecodeString()) - } - - } - } - - } else { - yyj1500 := 0 - for ; !r.CheckBreak(); yyj1500++ { - - if yyj1500 >= len(yyv1500) { - yyv1500 = append(yyv1500, "") // var yyz1500 FSType - yyc1500 = true - } - yyh1500.ElemContainerState(yyj1500) - if yyj1500 < len(yyv1500) { - if r.TryDecodeAsNil() { - yyv1500[yyj1500] = "" - } else { - yyv1500[yyj1500] = FSType(r.DecodeString()) - } - - } else { - z.DecSwallow() - } - - } - if yyj1500 < len(yyv1500) { - yyv1500 = yyv1500[:yyj1500] - yyc1500 = true - } else if yyj1500 == 0 && yyv1500 == nil { - yyv1500 = []FSType{} - yyc1500 = true - } - } - yyh1500.End() - if yyc1500 { - *v = yyv1500 - } -} - -func (x codecSelfer1234) encSliceHostPortRange(v []HostPortRange, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1504 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1505 := &yyv1504 - yy1505.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceHostPortRange(v *[]HostPortRange, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1506 := *v - yyh1506, yyl1506 := z.DecSliceHelperStart() - var yyc1506 bool - if yyl1506 == 0 { - if yyv1506 == nil { - yyv1506 = []HostPortRange{} - yyc1506 = true - } else if len(yyv1506) != 0 { - yyv1506 = yyv1506[:0] - yyc1506 = true - } - } else if yyl1506 > 0 { - var yyrr1506, yyrl1506 int - var yyrt1506 bool - if yyl1506 > cap(yyv1506) { - - yyrg1506 := len(yyv1506) > 0 - yyv21506 := yyv1506 - yyrl1506, yyrt1506 = z.DecInferLen(yyl1506, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1506 { - if yyrl1506 <= cap(yyv1506) { - yyv1506 = yyv1506[:yyrl1506] - } else { - yyv1506 = make([]HostPortRange, yyrl1506) - } - } else { - yyv1506 = make([]HostPortRange, yyrl1506) - } - yyc1506 = true - yyrr1506 = len(yyv1506) - if yyrg1506 { - copy(yyv1506, yyv21506) - } - } else if yyl1506 != len(yyv1506) { - yyv1506 = yyv1506[:yyl1506] - yyc1506 = true - } - yyj1506 := 0 - for ; yyj1506 < yyrr1506; yyj1506++ { - yyh1506.ElemContainerState(yyj1506) - if r.TryDecodeAsNil() { - yyv1506[yyj1506] = HostPortRange{} - } else { - yyv1507 := &yyv1506[yyj1506] - yyv1507.CodecDecodeSelf(d) - } - - } - if yyrt1506 { - for ; yyj1506 < yyl1506; yyj1506++ { - yyv1506 = append(yyv1506, HostPortRange{}) - yyh1506.ElemContainerState(yyj1506) - if r.TryDecodeAsNil() { - yyv1506[yyj1506] = HostPortRange{} - } else { - yyv1508 := &yyv1506[yyj1506] - yyv1508.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1506 := 0 - for ; !r.CheckBreak(); yyj1506++ { - - if yyj1506 >= len(yyv1506) { - yyv1506 = append(yyv1506, HostPortRange{}) // var yyz1506 HostPortRange - yyc1506 = true - } - yyh1506.ElemContainerState(yyj1506) - if yyj1506 < len(yyv1506) { - if r.TryDecodeAsNil() { - yyv1506[yyj1506] = HostPortRange{} - } else { - yyv1509 := &yyv1506[yyj1506] - yyv1509.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1506 < len(yyv1506) { - yyv1506 = yyv1506[:yyj1506] - yyc1506 = true - } else if yyj1506 == 0 && yyv1506 == nil { - yyv1506 = []HostPortRange{} - yyc1506 = true - } - } - yyh1506.End() - if yyc1506 { - *v = yyv1506 - } -} - -func (x codecSelfer1234) encSliceIDRange(v []IDRange, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1510 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1511 := &yyv1510 - yy1511.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceIDRange(v *[]IDRange, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1512 := *v - yyh1512, yyl1512 := z.DecSliceHelperStart() - var yyc1512 bool - if yyl1512 == 0 { - if yyv1512 == nil { - yyv1512 = []IDRange{} - yyc1512 = true - } else if len(yyv1512) != 0 { - yyv1512 = yyv1512[:0] - yyc1512 = true - } - } else if yyl1512 > 0 { - var yyrr1512, yyrl1512 int - var yyrt1512 bool - if yyl1512 > cap(yyv1512) { - - yyrg1512 := len(yyv1512) > 0 - yyv21512 := yyv1512 - yyrl1512, yyrt1512 = z.DecInferLen(yyl1512, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1512 { - if yyrl1512 <= cap(yyv1512) { - yyv1512 = yyv1512[:yyrl1512] - } else { - yyv1512 = make([]IDRange, yyrl1512) - } - } else { - yyv1512 = make([]IDRange, yyrl1512) - } - yyc1512 = true - yyrr1512 = len(yyv1512) - if yyrg1512 { - copy(yyv1512, yyv21512) - } - } else if yyl1512 != len(yyv1512) { - yyv1512 = yyv1512[:yyl1512] - yyc1512 = true - } - yyj1512 := 0 - for ; yyj1512 < yyrr1512; yyj1512++ { - yyh1512.ElemContainerState(yyj1512) - if r.TryDecodeAsNil() { - yyv1512[yyj1512] = IDRange{} - } else { - yyv1513 := &yyv1512[yyj1512] - yyv1513.CodecDecodeSelf(d) - } - - } - if yyrt1512 { - for ; yyj1512 < yyl1512; yyj1512++ { - yyv1512 = append(yyv1512, IDRange{}) - yyh1512.ElemContainerState(yyj1512) - if r.TryDecodeAsNil() { - yyv1512[yyj1512] = IDRange{} - } else { - yyv1514 := &yyv1512[yyj1512] - yyv1514.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1512 := 0 - for ; !r.CheckBreak(); yyj1512++ { - - if yyj1512 >= len(yyv1512) { - yyv1512 = append(yyv1512, IDRange{}) // var yyz1512 IDRange - yyc1512 = true - } - yyh1512.ElemContainerState(yyj1512) - if yyj1512 < len(yyv1512) { - if r.TryDecodeAsNil() { - yyv1512[yyj1512] = IDRange{} - } else { - yyv1515 := &yyv1512[yyj1512] - yyv1515.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1512 < len(yyv1512) { - yyv1512 = yyv1512[:yyj1512] - yyc1512 = true - } else if yyj1512 == 0 && yyv1512 == nil { - yyv1512 = []IDRange{} - yyc1512 = true - } - } - yyh1512.End() - if yyc1512 { - *v = yyv1512 - } -} - -func (x codecSelfer1234) encSlicePodSecurityPolicy(v []PodSecurityPolicy, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1516 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1517 := &yyv1516 - yy1517.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSlicePodSecurityPolicy(v *[]PodSecurityPolicy, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1518 := *v - yyh1518, yyl1518 := z.DecSliceHelperStart() - var yyc1518 bool - if yyl1518 == 0 { - if yyv1518 == nil { - yyv1518 = []PodSecurityPolicy{} - yyc1518 = true - } else if len(yyv1518) != 0 { - yyv1518 = yyv1518[:0] - yyc1518 = true - } - } else if yyl1518 > 0 { - var yyrr1518, yyrl1518 int - var yyrt1518 bool - if yyl1518 > cap(yyv1518) { - - yyrg1518 := len(yyv1518) > 0 - yyv21518 := yyv1518 - yyrl1518, yyrt1518 = z.DecInferLen(yyl1518, z.DecBasicHandle().MaxInitLen, 552) - if yyrt1518 { - if yyrl1518 <= cap(yyv1518) { - yyv1518 = yyv1518[:yyrl1518] - } else { - yyv1518 = make([]PodSecurityPolicy, yyrl1518) - } - } else { - yyv1518 = make([]PodSecurityPolicy, yyrl1518) - } - yyc1518 = true - yyrr1518 = len(yyv1518) - if yyrg1518 { - copy(yyv1518, yyv21518) - } - } else if yyl1518 != len(yyv1518) { - yyv1518 = yyv1518[:yyl1518] - yyc1518 = true - } - yyj1518 := 0 - for ; yyj1518 < yyrr1518; yyj1518++ { - yyh1518.ElemContainerState(yyj1518) - if r.TryDecodeAsNil() { - yyv1518[yyj1518] = PodSecurityPolicy{} - } else { - yyv1519 := &yyv1518[yyj1518] - yyv1519.CodecDecodeSelf(d) - } - - } - if yyrt1518 { - for ; yyj1518 < yyl1518; yyj1518++ { - yyv1518 = append(yyv1518, PodSecurityPolicy{}) - yyh1518.ElemContainerState(yyj1518) - if r.TryDecodeAsNil() { - yyv1518[yyj1518] = PodSecurityPolicy{} - } else { - yyv1520 := &yyv1518[yyj1518] - yyv1520.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1518 := 0 - for ; !r.CheckBreak(); yyj1518++ { - - if yyj1518 >= len(yyv1518) { - yyv1518 = append(yyv1518, PodSecurityPolicy{}) // var yyz1518 PodSecurityPolicy - yyc1518 = true - } - yyh1518.ElemContainerState(yyj1518) - if yyj1518 < len(yyv1518) { - if r.TryDecodeAsNil() { - yyv1518[yyj1518] = PodSecurityPolicy{} - } else { - yyv1521 := &yyv1518[yyj1518] - yyv1521.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1518 < len(yyv1518) { - yyv1518 = yyv1518[:yyj1518] - yyc1518 = true - } else if yyj1518 == 0 && yyv1518 == nil { - yyv1518 = []PodSecurityPolicy{} - yyc1518 = true - } - } - yyh1518.End() - if yyc1518 { - *v = yyv1518 - } -} - -func (x codecSelfer1234) encSliceNetworkPolicyIngressRule(v []NetworkPolicyIngressRule, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1522 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1523 := &yyv1522 - yy1523.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceNetworkPolicyIngressRule(v *[]NetworkPolicyIngressRule, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1524 := *v - yyh1524, yyl1524 := z.DecSliceHelperStart() - var yyc1524 bool - if yyl1524 == 0 { - if yyv1524 == nil { - yyv1524 = []NetworkPolicyIngressRule{} - yyc1524 = true - } else if len(yyv1524) != 0 { - yyv1524 = yyv1524[:0] - yyc1524 = true - } - } else if yyl1524 > 0 { - var yyrr1524, yyrl1524 int - var yyrt1524 bool - if yyl1524 > cap(yyv1524) { - - yyrg1524 := len(yyv1524) > 0 - yyv21524 := yyv1524 - yyrl1524, yyrt1524 = z.DecInferLen(yyl1524, z.DecBasicHandle().MaxInitLen, 48) - if yyrt1524 { - if yyrl1524 <= cap(yyv1524) { - yyv1524 = yyv1524[:yyrl1524] - } else { - yyv1524 = make([]NetworkPolicyIngressRule, yyrl1524) - } - } else { - yyv1524 = make([]NetworkPolicyIngressRule, yyrl1524) - } - yyc1524 = true - yyrr1524 = len(yyv1524) - if yyrg1524 { - copy(yyv1524, yyv21524) - } - } else if yyl1524 != len(yyv1524) { - yyv1524 = yyv1524[:yyl1524] - yyc1524 = true - } - yyj1524 := 0 - for ; yyj1524 < yyrr1524; yyj1524++ { - yyh1524.ElemContainerState(yyj1524) - if r.TryDecodeAsNil() { - yyv1524[yyj1524] = NetworkPolicyIngressRule{} - } else { - yyv1525 := &yyv1524[yyj1524] - yyv1525.CodecDecodeSelf(d) - } - - } - if yyrt1524 { - for ; yyj1524 < yyl1524; yyj1524++ { - yyv1524 = append(yyv1524, NetworkPolicyIngressRule{}) - yyh1524.ElemContainerState(yyj1524) - if r.TryDecodeAsNil() { - yyv1524[yyj1524] = NetworkPolicyIngressRule{} - } else { - yyv1526 := &yyv1524[yyj1524] - yyv1526.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1524 := 0 - for ; !r.CheckBreak(); yyj1524++ { - - if yyj1524 >= len(yyv1524) { - yyv1524 = append(yyv1524, NetworkPolicyIngressRule{}) // var yyz1524 NetworkPolicyIngressRule - yyc1524 = true - } - yyh1524.ElemContainerState(yyj1524) - if yyj1524 < len(yyv1524) { - if r.TryDecodeAsNil() { - yyv1524[yyj1524] = NetworkPolicyIngressRule{} - } else { - yyv1527 := &yyv1524[yyj1524] - yyv1527.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1524 < len(yyv1524) { - yyv1524 = yyv1524[:yyj1524] - yyc1524 = true - } else if yyj1524 == 0 && yyv1524 == nil { - yyv1524 = []NetworkPolicyIngressRule{} - yyc1524 = true - } - } - yyh1524.End() - if yyc1524 { - *v = yyv1524 - } -} - -func (x codecSelfer1234) encSliceNetworkPolicyPort(v []NetworkPolicyPort, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1528 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1529 := &yyv1528 - yy1529.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceNetworkPolicyPort(v *[]NetworkPolicyPort, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1530 := *v - yyh1530, yyl1530 := z.DecSliceHelperStart() - var yyc1530 bool - if yyl1530 == 0 { - if yyv1530 == nil { - yyv1530 = []NetworkPolicyPort{} - yyc1530 = true - } else if len(yyv1530) != 0 { - yyv1530 = yyv1530[:0] - yyc1530 = true - } - } else if yyl1530 > 0 { - var yyrr1530, yyrl1530 int - var yyrt1530 bool - if yyl1530 > cap(yyv1530) { - - yyrg1530 := len(yyv1530) > 0 - yyv21530 := yyv1530 - yyrl1530, yyrt1530 = z.DecInferLen(yyl1530, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1530 { - if yyrl1530 <= cap(yyv1530) { - yyv1530 = yyv1530[:yyrl1530] - } else { - yyv1530 = make([]NetworkPolicyPort, yyrl1530) - } - } else { - yyv1530 = make([]NetworkPolicyPort, yyrl1530) - } - yyc1530 = true - yyrr1530 = len(yyv1530) - if yyrg1530 { - copy(yyv1530, yyv21530) - } - } else if yyl1530 != len(yyv1530) { - yyv1530 = yyv1530[:yyl1530] - yyc1530 = true - } - yyj1530 := 0 - for ; yyj1530 < yyrr1530; yyj1530++ { - yyh1530.ElemContainerState(yyj1530) - if r.TryDecodeAsNil() { - yyv1530[yyj1530] = NetworkPolicyPort{} - } else { - yyv1531 := &yyv1530[yyj1530] - yyv1531.CodecDecodeSelf(d) - } - - } - if yyrt1530 { - for ; yyj1530 < yyl1530; yyj1530++ { - yyv1530 = append(yyv1530, NetworkPolicyPort{}) - yyh1530.ElemContainerState(yyj1530) - if r.TryDecodeAsNil() { - yyv1530[yyj1530] = NetworkPolicyPort{} - } else { - yyv1532 := &yyv1530[yyj1530] - yyv1532.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1530 := 0 - for ; !r.CheckBreak(); yyj1530++ { - - if yyj1530 >= len(yyv1530) { - yyv1530 = append(yyv1530, NetworkPolicyPort{}) // var yyz1530 NetworkPolicyPort - yyc1530 = true - } - yyh1530.ElemContainerState(yyj1530) - if yyj1530 < len(yyv1530) { - if r.TryDecodeAsNil() { - yyv1530[yyj1530] = NetworkPolicyPort{} - } else { - yyv1533 := &yyv1530[yyj1530] - yyv1533.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1530 < len(yyv1530) { - yyv1530 = yyv1530[:yyj1530] - yyc1530 = true - } else if yyj1530 == 0 && yyv1530 == nil { - yyv1530 = []NetworkPolicyPort{} - yyc1530 = true - } - } - yyh1530.End() - if yyc1530 { - *v = yyv1530 - } -} - -func (x codecSelfer1234) encSliceNetworkPolicyPeer(v []NetworkPolicyPeer, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1534 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1535 := &yyv1534 - yy1535.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceNetworkPolicyPeer(v *[]NetworkPolicyPeer, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1536 := *v - yyh1536, yyl1536 := z.DecSliceHelperStart() - var yyc1536 bool - if yyl1536 == 0 { - if yyv1536 == nil { - yyv1536 = []NetworkPolicyPeer{} - yyc1536 = true - } else if len(yyv1536) != 0 { - yyv1536 = yyv1536[:0] - yyc1536 = true - } - } else if yyl1536 > 0 { - var yyrr1536, yyrl1536 int - var yyrt1536 bool - if yyl1536 > cap(yyv1536) { - - yyrg1536 := len(yyv1536) > 0 - yyv21536 := yyv1536 - yyrl1536, yyrt1536 = z.DecInferLen(yyl1536, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1536 { - if yyrl1536 <= cap(yyv1536) { - yyv1536 = yyv1536[:yyrl1536] - } else { - yyv1536 = make([]NetworkPolicyPeer, yyrl1536) - } - } else { - yyv1536 = make([]NetworkPolicyPeer, yyrl1536) - } - yyc1536 = true - yyrr1536 = len(yyv1536) - if yyrg1536 { - copy(yyv1536, yyv21536) - } - } else if yyl1536 != len(yyv1536) { - yyv1536 = yyv1536[:yyl1536] - yyc1536 = true - } - yyj1536 := 0 - for ; yyj1536 < yyrr1536; yyj1536++ { - yyh1536.ElemContainerState(yyj1536) - if r.TryDecodeAsNil() { - yyv1536[yyj1536] = NetworkPolicyPeer{} - } else { - yyv1537 := &yyv1536[yyj1536] - yyv1537.CodecDecodeSelf(d) - } - - } - if yyrt1536 { - for ; yyj1536 < yyl1536; yyj1536++ { - yyv1536 = append(yyv1536, NetworkPolicyPeer{}) - yyh1536.ElemContainerState(yyj1536) - if r.TryDecodeAsNil() { - yyv1536[yyj1536] = NetworkPolicyPeer{} - } else { - yyv1538 := &yyv1536[yyj1536] - yyv1538.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1536 := 0 - for ; !r.CheckBreak(); yyj1536++ { - - if yyj1536 >= len(yyv1536) { - yyv1536 = append(yyv1536, NetworkPolicyPeer{}) // var yyz1536 NetworkPolicyPeer - yyc1536 = true - } - yyh1536.ElemContainerState(yyj1536) - if yyj1536 < len(yyv1536) { - if r.TryDecodeAsNil() { - yyv1536[yyj1536] = NetworkPolicyPeer{} - } else { - yyv1539 := &yyv1536[yyj1536] - yyv1539.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1536 < len(yyv1536) { - yyv1536 = yyv1536[:yyj1536] - yyc1536 = true - } else if yyj1536 == 0 && yyv1536 == nil { - yyv1536 = []NetworkPolicyPeer{} - yyc1536 = true - } - } - yyh1536.End() - if yyc1536 { - *v = yyv1536 - } -} - -func (x codecSelfer1234) encSliceNetworkPolicy(v []NetworkPolicy, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1540 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1541 := &yyv1540 - yy1541.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceNetworkPolicy(v *[]NetworkPolicy, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1542 := *v - yyh1542, yyl1542 := z.DecSliceHelperStart() - var yyc1542 bool - if yyl1542 == 0 { - if yyv1542 == nil { - yyv1542 = []NetworkPolicy{} - yyc1542 = true - } else if len(yyv1542) != 0 { - yyv1542 = yyv1542[:0] - yyc1542 = true - } - } else if yyl1542 > 0 { - var yyrr1542, yyrl1542 int - var yyrt1542 bool - if yyl1542 > cap(yyv1542) { - - yyrg1542 := len(yyv1542) > 0 - yyv21542 := yyv1542 - yyrl1542, yyrt1542 = z.DecInferLen(yyl1542, z.DecBasicHandle().MaxInitLen, 312) - if yyrt1542 { - if yyrl1542 <= cap(yyv1542) { - yyv1542 = yyv1542[:yyrl1542] - } else { - yyv1542 = make([]NetworkPolicy, yyrl1542) - } - } else { - yyv1542 = make([]NetworkPolicy, yyrl1542) - } - yyc1542 = true - yyrr1542 = len(yyv1542) - if yyrg1542 { - copy(yyv1542, yyv21542) - } - } else if yyl1542 != len(yyv1542) { - yyv1542 = yyv1542[:yyl1542] - yyc1542 = true - } - yyj1542 := 0 - for ; yyj1542 < yyrr1542; yyj1542++ { - yyh1542.ElemContainerState(yyj1542) - if r.TryDecodeAsNil() { - yyv1542[yyj1542] = NetworkPolicy{} - } else { - yyv1543 := &yyv1542[yyj1542] - yyv1543.CodecDecodeSelf(d) - } - - } - if yyrt1542 { - for ; yyj1542 < yyl1542; yyj1542++ { - yyv1542 = append(yyv1542, NetworkPolicy{}) - yyh1542.ElemContainerState(yyj1542) - if r.TryDecodeAsNil() { - yyv1542[yyj1542] = NetworkPolicy{} - } else { - yyv1544 := &yyv1542[yyj1542] - yyv1544.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1542 := 0 - for ; !r.CheckBreak(); yyj1542++ { - - if yyj1542 >= len(yyv1542) { - yyv1542 = append(yyv1542, NetworkPolicy{}) // var yyz1542 NetworkPolicy - yyc1542 = true - } - yyh1542.ElemContainerState(yyj1542) - if yyj1542 < len(yyv1542) { - if r.TryDecodeAsNil() { - yyv1542[yyj1542] = NetworkPolicy{} - } else { - yyv1545 := &yyv1542[yyj1542] - yyv1545.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1542 < len(yyv1542) { - yyv1542 = yyv1542[:yyj1542] - yyc1542 = true - } else if yyj1542 == 0 && yyv1542 == nil { - yyv1542 = []NetworkPolicy{} - yyc1542 = true - } - } - yyh1542.End() - if yyc1542 { - *v = yyv1542 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/types.go b/vendor/k8s.io/client-go/pkg/apis/extensions/types.go index a932322618..48031d8df2 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/types.go @@ -29,10 +29,10 @@ support is experimental. package extensions import ( + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/util/intstr" ) const ( @@ -46,18 +46,18 @@ const ( type ScaleSpec struct { // desired number of instances for the scaled object. // +optional - Replicas int32 `json:"replicas,omitempty"` + Replicas int32 } // represents the current status of a scale subresource. type ScaleStatus struct { // actual number of observed instances of the scaled object. - Replicas int32 `json:"replicas"` + Replicas int32 // label query over pods that should match the replicas count. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector } // +genclient=true @@ -65,46 +65,46 @@ type ScaleStatus struct { // represents a scaling request for a resource. type Scale struct { - unversioned.TypeMeta `json:",inline"` - // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + metav1.TypeMeta + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional - Spec ScaleSpec `json:"spec,omitempty"` + Spec ScaleSpec - // current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only. + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. // +optional - Status ScaleStatus `json:"status,omitempty"` + Status ScaleStatus } // Dummy definition type ReplicationControllerDummy struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta } // Alpha-level support for Custom Metrics in HPA (as annotations). type CustomMetricTarget struct { // Custom Metric name. - Name string `json:"name"` + Name string // Custom Metric value (average). - TargetValue resource.Quantity `json:"value"` + TargetValue resource.Quantity } type CustomMetricTargetList struct { - Items []CustomMetricTarget `json:"items"` + Items []CustomMetricTarget } type CustomMetricCurrentStatus struct { // Custom Metric name. - Name string `json:"name"` + Name string // Custom Metric value (average). - CurrentValue resource.Quantity `json:"value"` + CurrentValue resource.Quantity } type CustomMetricCurrentStatusList struct { - Items []CustomMetricCurrentStatus `json:"items"` + Items []CustomMetricCurrentStatus } // +genclient=true @@ -113,105 +113,103 @@ type CustomMetricCurrentStatusList struct { // A ThirdPartyResource is a generic representation of a resource, it is used by add-ons and plugins to add new resource // types to the API. It consists of one or more Versions of the api. type ThirdPartyResource struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Description is the description of this object. // +optional - Description string `json:"description,omitempty"` + Description string // Versions are versions for this third party object - // +optional - Versions []APIVersion `json:"versions,omitempty"` + Versions []APIVersion } type ThirdPartyResourceList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard list metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is the list of horizontal pod autoscalers. - Items []ThirdPartyResource `json:"items"` + Items []ThirdPartyResource } // An APIVersion represents a single concrete version of an object model. -// TODO: we should consider merge this struct with GroupVersion in unversioned.go +// TODO: we should consider merge this struct with GroupVersion in metav1.go type APIVersion struct { // Name of this version (e.g. 'v1'). - // +optional - Name string `json:"name,omitempty"` + Name string } // An internal object, used for versioned storage in etcd. Not exposed to the end user. type ThirdPartyResourceData struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object metadata. // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Data is the raw JSON data for this data. // +optional - Data []byte `json:"data,omitempty"` + Data []byte } // +genclient=true type Deployment struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Specification of the desired behavior of the Deployment. // +optional - Spec DeploymentSpec `json:"spec,omitempty"` + Spec DeploymentSpec // Most recently observed status of the Deployment. // +optional - Status DeploymentStatus `json:"status,omitempty"` + Status DeploymentStatus } type DeploymentSpec struct { // Number of desired pods. This is a pointer to distinguish between explicit // zero and not specified. Defaults to 1. // +optional - Replicas int32 `json:"replicas,omitempty"` + Replicas int32 // Label selector for pods. Existing ReplicaSets whose pods are // selected by this will be the ones affected by this deployment. // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector // Template describes the pods that will be created. - Template api.PodTemplateSpec `json:"template"` + Template api.PodTemplateSpec // The deployment strategy to use to replace existing pods with new ones. // +optional - Strategy DeploymentStrategy `json:"strategy,omitempty"` + Strategy DeploymentStrategy // Minimum number of seconds for which a newly created pod should be ready // without any of its container crashing, for it to be considered available. // Defaults to 0 (pod will be considered available as soon as it is ready) // +optional - MinReadySeconds int32 `json:"minReadySeconds,omitempty"` + MinReadySeconds int32 // The number of old ReplicaSets to retain to allow rollback. // This is a pointer to distinguish between explicit zero and not specified. // +optional - RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty"` + RevisionHistoryLimit *int32 // Indicates that the deployment is paused and will not be processed by the // deployment controller. // +optional - Paused bool `json:"paused,omitempty"` + Paused bool // The config this deployment is rolling back to. Will be cleared after rollback is done. // +optional - RollbackTo *RollbackConfig `json:"rollbackTo,omitempty"` + RollbackTo *RollbackConfig // The maximum time in seconds for a deployment to make progress before it // is considered to be failed. The deployment controller will continue to @@ -220,25 +218,25 @@ type DeploymentSpec struct { // implemented, the deployment controller will automatically rollback failed // deployments. Note that progress will not be estimated during the time a // deployment is paused. This is not set by default. - ProgressDeadlineSeconds *int32 `json:"progressDeadlineSeconds,omitempty"` + ProgressDeadlineSeconds *int32 } // DeploymentRollback stores the information required to rollback a deployment. type DeploymentRollback struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Required: This must match the Name of a deployment. - Name string `json:"name"` + Name string // The annotations to be updated to a deployment // +optional - UpdatedAnnotations map[string]string `json:"updatedAnnotations,omitempty"` + UpdatedAnnotations map[string]string // The config of this deployment rollback. - RollbackTo RollbackConfig `json:"rollbackTo"` + RollbackTo RollbackConfig } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional - Revision int64 `json:"revision,omitempty"` + Revision int64 } const ( @@ -251,7 +249,7 @@ const ( type DeploymentStrategy struct { // Type of deployment. Can be "Recreate" or "RollingUpdate". Default is RollingUpdate. // +optional - Type DeploymentStrategyType `json:"type,omitempty"` + Type DeploymentStrategyType // Rolling update config params. Present only if DeploymentStrategyType = // RollingUpdate. @@ -259,7 +257,7 @@ type DeploymentStrategy struct { // TODO: Update this to follow our convention for oneOf, whatever we decide it // to be. // +optional - RollingUpdate *RollingUpdateDeployment `json:"rollingUpdate,omitempty"` + RollingUpdate *RollingUpdateDeployment } type DeploymentStrategyType string @@ -276,7 +274,7 @@ const ( type RollingUpdateDeployment struct { // The maximum number of pods that can be unavailable during the update. // Value can be an absolute number (ex: 5) or a percentage of total pods at the start of update (ex: 10%). - // Absolute number is calculated from percentage by rounding up. + // Absolute number is calculated from percentage by rounding down. // This can not be 0 if MaxSurge is 0. // By default, a fixed value of 1 is used. // Example: when this is set to 30%, the old RC can be scaled down by 30% @@ -285,7 +283,7 @@ type RollingUpdateDeployment struct { // that at least 70% of original number of pods are available at all times // during the update. // +optional - MaxUnavailable intstr.IntOrString `json:"maxUnavailable,omitempty"` + MaxUnavailable intstr.IntOrString // The maximum number of pods that can be scheduled above the original number of // pods. @@ -298,32 +296,42 @@ type RollingUpdateDeployment struct { // new RC can be scaled up further, ensuring that total number of pods running // at any time during the update is atmost 130% of original pods. // +optional - MaxSurge intstr.IntOrString `json:"maxSurge,omitempty"` + MaxSurge intstr.IntOrString } type DeploymentStatus struct { // The generation observed by the deployment controller. // +optional - ObservedGeneration int64 `json:"observedGeneration,omitempty"` + ObservedGeneration int64 // Total number of non-terminated pods targeted by this deployment (their labels match the selector). // +optional - Replicas int32 `json:"replicas,omitempty"` + Replicas int32 // Total number of non-terminated pods targeted by this deployment that have the desired template spec. // +optional - UpdatedReplicas int32 `json:"updatedReplicas,omitempty"` + UpdatedReplicas int32 + + // Total number of ready pods targeted by this deployment. + // +optional + ReadyReplicas int32 // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. // +optional - AvailableReplicas int32 `json:"availableReplicas,omitempty"` + AvailableReplicas int32 // Total number of unavailable pods targeted by this deployment. // +optional - UnavailableReplicas int32 `json:"unavailableReplicas,omitempty"` + UnavailableReplicas int32 // Represents the latest available observations of a deployment's current state. - Conditions []DeploymentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` + Conditions []DeploymentCondition + + // Count of hash collisions for the Deployment. The Deployment controller uses this + // field as a collision avoidance mechanism when it needs to create the name for the + // newest ReplicaSet. + // +optional + CollisionCount *int64 } type DeploymentConditionType string @@ -346,42 +354,41 @@ const ( // DeploymentCondition describes the state of a deployment at a certain point. type DeploymentCondition struct { // Type of deployment condition. - Type DeploymentConditionType `json:"type"` + Type DeploymentConditionType // Status of the condition, one of True, False, Unknown. - Status api.ConditionStatus `json:"status"` + Status api.ConditionStatus // The last time this condition was updated. - LastUpdateTime unversioned.Time `json:"lastUpdateTime,omitempty"` + LastUpdateTime metav1.Time // Last time the condition transitioned from one status to another. - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"` + LastTransitionTime metav1.Time // The reason for the condition's last transition. - Reason string `json:"reason,omitempty"` + Reason string // A human readable message indicating details about the transition. - Message string `json:"message,omitempty"` + Message string } type DeploymentList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is the list of deployments. - Items []Deployment `json:"items"` + Items []Deployment } -// TODO(madhusudancs): Uncomment while implementing DaemonSet updates. -/* Commenting out for v1.2. We are planning to bring these types back with a more robust DaemonSet update implementation in v1.3, hence not deleting but just commenting the types out. type DaemonSetUpdateStrategy struct { - // Type of daemon set update. Only "RollingUpdate" is supported at this time. Default is RollingUpdate. -// +optional - Type DaemonSetUpdateStrategyType `json:"type,omitempty"` + // Type of daemon set update. Can be "RollingUpdate" or "OnDelete". + // Default is OnDelete. + // +optional + Type DaemonSetUpdateStrategyType - // Rolling update config params. Present only if DaemonSetUpdateStrategy = - // RollingUpdate. + // Rolling update config params. Present only if type = "RollingUpdate". //--- // TODO: Update this to follow our convention for oneOf, whatever we decide it - // to be. Same as DeploymentStrategy.RollingUpdate. -// +optional - RollingUpdate *RollingUpdateDaemonSet `json:"rollingUpdate,omitempty"` + // to be. Same as Deployment `strategy.rollingUpdate`. + // See https://github.com/kubernetes/kubernetes/issues/35345 + // +optional + RollingUpdate *RollingUpdateDaemonSet } type DaemonSetUpdateStrategyType string @@ -389,6 +396,9 @@ type DaemonSetUpdateStrategyType string const ( // Replace the old daemons by new ones using rolling update i.e replace them on each node one after the other. RollingUpdateDaemonSetStrategyType DaemonSetUpdateStrategyType = "RollingUpdate" + + // Replace the old daemons only when it's killed + OnDeleteDaemonSetStrategyType DaemonSetUpdateStrategyType = "OnDelete" ) // Spec to control the desired behavior of daemon set rolling update. @@ -399,129 +409,155 @@ type RollingUpdateDaemonSet struct { // number is calculated from percentage by rounding up. // This cannot be 0. // Default value is 1. - // Example: when this is set to 30%, 30% of the currently running DaemonSet - // pods can be stopped for an update at any given time. The update starts - // by stopping at most 30% of the currently running DaemonSet pods and then - // brings up new DaemonSet pods in their place. Once the new pods are ready, - // it then proceeds onto other DaemonSet pods, thus ensuring that at least - // 70% of original number of DaemonSet pods are available at all times - // during the update. -// +optional - MaxUnavailable intstr.IntOrString `json:"maxUnavailable,omitempty"` - - // Minimum number of seconds for which a newly created DaemonSet pod should - // be ready without any of its container crashing, for it to be considered - // available. Defaults to 0 (pod will be considered available as soon as it - // is ready). -// +optional - MinReadySeconds int `json:"minReadySeconds,omitempty"` + // Example: when this is set to 30%, at most 30% of the total number of nodes + // that should be running the daemon pod (i.e. status.desiredNumberScheduled) + // can have their pods stopped for an update at any given + // time. The update starts by stopping at most 30% of those DaemonSet pods + // and then brings up new DaemonSet pods in their place. Once the new pods + // are available, it then proceeds onto other DaemonSet pods, thus ensuring + // that at least 70% of original number of DaemonSet pods are available at + // all times during the update. + // +optional + MaxUnavailable intstr.IntOrString } -*/ // DaemonSetSpec is the specification of a daemon set. type DaemonSetSpec struct { - // Selector is a label query over pods that are managed by the daemon set. + // A label query over pods that are managed by the daemon set. // Must match in order to be controlled. // If empty, defaulted to labels on Pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector - // Template is the object that describes the pod that will be created. + // An object that describes the pod that will be created. // The DaemonSet will create exactly one copy of this pod on every node // that matches the template's node selector (or on every node if no node // selector is specified). - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template - Template api.PodTemplateSpec `json:"template"` + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template + Template api.PodTemplateSpec - // TODO(madhusudancs): Uncomment while implementing DaemonSet updates. - /* Commenting out for v1.2. We are planning to bring these fields back with a more robust DaemonSet update implementation in v1.3, hence not deleting but just commenting these fields out. - // Update strategy to replace existing DaemonSet pods with new pods. + // An update strategy to replace existing DaemonSet pods with new pods. // +optional - UpdateStrategy DaemonSetUpdateStrategy `json:"updateStrategy,omitempty"` + UpdateStrategy DaemonSetUpdateStrategy - // Label key that is added to DaemonSet pods to distinguish between old and - // new pod templates during DaemonSet update. - // Users can set this to an empty string to indicate that the system should - // not add any label. If unspecified, system uses - // DefaultDaemonSetUniqueLabelKey("daemonset.kubernetes.io/podTemplateHash"). - // Value of this key is hash of DaemonSetSpec.PodTemplateSpec. - // No label is added if this is set to empty string. + // The minimum number of seconds for which a newly created DaemonSet pod should + // be ready without any of its container crashing, for it to be considered + // available. Defaults to 0 (pod will be considered available as soon as it + // is ready). // +optional - UniqueLabelKey string `json:"uniqueLabelKey,omitempty"` - */ -} + MinReadySeconds int32 -const ( - // DefaultDaemonSetUniqueLabelKey is the default key of the labels that is added - // to daemon set pods to distinguish between old and new pod templates during - // DaemonSet update. See DaemonSetSpec's UniqueLabelKey field for more information. - DefaultDaemonSetUniqueLabelKey string = "daemonset.kubernetes.io/podTemplateHash" -) + // DEPRECATED. + // A sequence number representing a specific generation of the template. + // Populated by the system. It can be set only during the creation. + // +optional + TemplateGeneration int64 + + // The number of old history to retain to allow rollback. + // This is a pointer to distinguish between explicit zero and not specified. + // Defaults to 10. + // +optional + RevisionHistoryLimit *int32 +} // DaemonSetStatus represents the current status of a daemon set. type DaemonSetStatus struct { - // CurrentNumberScheduled is the number of nodes that are running at least 1 + // The number of nodes that are running at least 1 // daemon pod and are supposed to run the daemon pod. - CurrentNumberScheduled int32 `json:"currentNumberScheduled"` + CurrentNumberScheduled int32 - // NumberMisscheduled is the number of nodes that are running the daemon pod, but are + // The number of nodes that are running the daemon pod, but are // not supposed to run the daemon pod. - NumberMisscheduled int32 `json:"numberMisscheduled"` + NumberMisscheduled int32 - // DesiredNumberScheduled is the total number of nodes that should be running the daemon + // The total number of nodes that should be running the daemon // pod (including nodes correctly running the daemon pod). - DesiredNumberScheduled int32 `json:"desiredNumberScheduled"` + DesiredNumberScheduled int32 - // NumberReady is the number of nodes that should be running the daemon pod and have one + // The number of nodes that should be running the daemon pod and have one // or more of the daemon pod running and ready. - NumberReady int32 `json:"numberReady"` + NumberReady int32 + + // The most recent generation observed by the daemon set controller. + // +optional + ObservedGeneration int64 + + // The total number of nodes that are running updated daemon pod + // +optional + UpdatedNumberScheduled int32 + + // The number of nodes that should be running the + // daemon pod and have one or more of the daemon pod running and + // available (ready for at least spec.minReadySeconds) + // +optional + NumberAvailable int32 + + // The number of nodes that should be running the + // daemon pod and have none of the daemon pod running and available + // (ready for at least spec.minReadySeconds) + // +optional + NumberUnavailable int32 + + // Count of hash collisions for the DaemonSet. The DaemonSet controller + // uses this field as a collision avoidance mechanism when it needs to + // create the name for the newest ControllerRevision. + // +optional + CollisionCount *int64 } // +genclient=true // DaemonSet represents the configuration of a daemon set. type DaemonSet struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta - // Spec defines the desired behavior of this daemon set. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // The desired behavior of this daemon set. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Spec DaemonSetSpec `json:"spec,omitempty"` + Spec DaemonSetSpec - // Status is the current status of this daemon set. This data may be + // The current status of this daemon set. This data may be // out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Status DaemonSetStatus `json:"status,omitempty"` + Status DaemonSetStatus } +const ( + // DEPRECATED: DefaultDaemonSetUniqueLabelKey is used instead. + // DaemonSetTemplateGenerationKey is the key of the labels that is added + // to daemon set pods to distinguish between old and new pod templates + // during DaemonSet template update. + DaemonSetTemplateGenerationKey string = "pod-template-generation" +) + // DaemonSetList is a collection of daemon sets. type DaemonSetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - // Items is a list of daemon sets. - Items []DaemonSet `json:"items"` + // A list of daemon sets. + Items []DaemonSet } type ThirdPartyResourceDataList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is a list of third party objects - Items []ThirdPartyResourceData `json:"items"` + Items []ThirdPartyResourceData } // +genclient=true @@ -531,33 +567,33 @@ type ThirdPartyResourceDataList struct { // externally-reachable urls, load balance traffic, terminate SSL, offer name // based virtual hosting etc. type Ingress struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec is the desired state of the Ingress. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Spec IngressSpec `json:"spec,omitempty"` + Spec IngressSpec // Status is the current state of the Ingress. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional - Status IngressStatus `json:"status,omitempty"` + Status IngressStatus } // IngressList is a collection of Ingress. type IngressList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is the list of Ingress. - Items []Ingress `json:"items"` + Items []Ingress } // IngressSpec describes the Ingress the user wishes to exist. @@ -567,7 +603,7 @@ type IngressSpec struct { // is optional to allow the loadbalancer controller or defaulting logic to // specify a global default. // +optional - Backend *IngressBackend `json:"backend,omitempty"` + Backend *IngressBackend // TLS configuration. Currently the Ingress only supports a single TLS // port, 443. If multiple members of this list specify different hosts, they @@ -575,12 +611,12 @@ type IngressSpec struct { // through the SNI TLS extension, if the ingress controller fulfilling the // ingress supports SNI. // +optional - TLS []IngressTLS `json:"tls,omitempty"` + TLS []IngressTLS // A list of host rules used to configure the Ingress. If unspecified, or // no rule matches, all traffic is sent to the default backend. // +optional - Rules []IngressRule `json:"rules,omitempty"` + Rules []IngressRule // TODO: Add the ability to specify load-balancer IP through claims } @@ -591,14 +627,14 @@ type IngressTLS struct { // wildcard host setting for the loadbalancer controller fulfilling this // Ingress, if left unspecified. // +optional - Hosts []string `json:"hosts,omitempty"` + Hosts []string // SecretName is the name of the secret used to terminate SSL traffic on 443. // Field is left optional to allow SSL routing based on SNI hostname alone. // If the SNI host in a listener conflicts with the "Host" header field used // by an IngressRule, the SNI host is used for termination and value of the // Host header is used for routing. // +optional - SecretName string `json:"secretName,omitempty"` + SecretName string // TODO: Consider specifying different modes of termination, protocols etc. } @@ -606,7 +642,7 @@ type IngressTLS struct { type IngressStatus struct { // LoadBalancer contains the current status of the load-balancer. // +optional - LoadBalancer api.LoadBalancerStatus `json:"loadBalancer,omitempty"` + LoadBalancer api.LoadBalancerStatus } // IngressRule represents the rules mapping the paths under a specified host to @@ -626,14 +662,14 @@ type IngressRule struct { // If the host is unspecified, the Ingress routes all traffic based on the // specified IngressRuleValue. // +optional - Host string `json:"host,omitempty"` + Host string // IngressRuleValue represents a rule to route requests for this IngressRule. // If unspecified, the rule defaults to a http catch-all. Whether that sends // just traffic matching the host to the default backend or all traffic to the // default backend, is left to the controller fulfilling the Ingress. Http is // currently the only supported IngressRuleValue. // +optional - IngressRuleValue `json:",inline,omitempty"` + IngressRuleValue } // IngressRuleValue represents a rule to apply against incoming requests. If the @@ -648,7 +684,7 @@ type IngressRuleValue struct { // usable by a loadbalancer, like http keep-alive. // +optional - HTTP *HTTPIngressRuleValue `json:"http,omitempty"` + HTTP *HTTPIngressRuleValue } // HTTPIngressRuleValue is a list of http selectors pointing to backends. @@ -658,7 +694,7 @@ type IngressRuleValue struct { // or '#'. type HTTPIngressRuleValue struct { // A collection of paths that map requests to backends. - Paths []HTTPIngressPath `json:"paths"` + Paths []HTTPIngressPath // TODO: Consider adding fields for ingress-type specific global // options usable by a loadbalancer, like http keep-alive. } @@ -674,47 +710,47 @@ type HTTPIngressPath struct { // a '/'. If unspecified, the path defaults to a catch all sending // traffic to the backend. // +optional - Path string `json:"path,omitempty"` + Path string // Backend defines the referenced service endpoint to which the traffic // will be forwarded to. - Backend IngressBackend `json:"backend"` + Backend IngressBackend } // IngressBackend describes all endpoints for a given service and port. type IngressBackend struct { // Specifies the name of the referenced service. - ServiceName string `json:"serviceName"` + ServiceName string // Specifies the port of the referenced service. - ServicePort intstr.IntOrString `json:"servicePort"` + ServicePort intstr.IntOrString } // +genclient=true // ReplicaSet represents the configuration of a replica set. type ReplicaSet struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the desired behavior of this ReplicaSet. // +optional - Spec ReplicaSetSpec `json:"spec,omitempty"` + Spec ReplicaSetSpec // Status is the current status of this ReplicaSet. This data may be // out of date by some window of time. // +optional - Status ReplicaSetStatus `json:"status,omitempty"` + Status ReplicaSetStatus } // ReplicaSetList is a collection of ReplicaSets. type ReplicaSetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []ReplicaSet `json:"items"` + Items []ReplicaSet } // ReplicaSetSpec is the specification of a ReplicaSet. @@ -722,51 +758,51 @@ type ReplicaSetList struct { // a Template set. type ReplicaSetSpec struct { // Replicas is the number of desired replicas. - Replicas int32 `json:"replicas"` + Replicas int32 // Minimum number of seconds for which a newly created pod should be ready // without any of its container crashing, for it to be considered available. // Defaults to 0 (pod will be considered available as soon as it is ready) // +optional - MinReadySeconds int32 `json:"minReadySeconds,omitempty"` + MinReadySeconds int32 // Selector is a label query over pods that should match the replica count. // Must match in order to be controlled. // If empty, defaulted to labels on pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector // Template is the object that describes the pod that will be created if // insufficient replicas are detected. // +optional - Template api.PodTemplateSpec `json:"template,omitempty"` + Template api.PodTemplateSpec } // ReplicaSetStatus represents the current status of a ReplicaSet. type ReplicaSetStatus struct { // Replicas is the number of actual replicas. - Replicas int32 `json:"replicas"` + Replicas int32 // The number of pods that have labels matching the labels of the pod template of the replicaset. // +optional - FullyLabeledReplicas int32 `json:"fullyLabeledReplicas,omitempty"` + FullyLabeledReplicas int32 // The number of ready replicas for this replica set. // +optional - ReadyReplicas int32 `json:"readyReplicas,omitempty"` + ReadyReplicas int32 // The number of available replicas (ready for at least minReadySeconds) for this replica set. // +optional - AvailableReplicas int32 `json:"availableReplicas,omitempty"` + AvailableReplicas int32 // ObservedGeneration is the most recent generation observed by the controller. // +optional - ObservedGeneration int64 `json:"observedGeneration,omitempty"` + ObservedGeneration int64 // Represents the latest available observations of a replica set's current state. // +optional - Conditions []ReplicaSetCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type"` + Conditions []ReplicaSetCondition } type ReplicaSetConditionType string @@ -782,18 +818,18 @@ const ( // ReplicaSetCondition describes the state of a replica set at a certain point. type ReplicaSetCondition struct { // Type of replica set condition. - Type ReplicaSetConditionType `json:"type"` + Type ReplicaSetConditionType // Status of the condition, one of True, False, Unknown. - Status api.ConditionStatus `json:"status"` + Status api.ConditionStatus // The last time the condition transitioned from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty"` + LastTransitionTime metav1.Time // The reason for the condition's last transition. // +optional - Reason string `json:"reason,omitempty"` + Reason string // A human readable message indicating details about the transition. // +optional - Message string `json:"message,omitempty"` + Message string } // +genclient=true @@ -802,74 +838,74 @@ type ReplicaSetCondition struct { // PodSecurityPolicy governs the ability to make requests that affect the SecurityContext // that will be applied to a pod and container. type PodSecurityPolicy struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Spec defines the policy enforced. // +optional - Spec PodSecurityPolicySpec `json:"spec,omitempty"` + Spec PodSecurityPolicySpec } // PodSecurityPolicySpec defines the policy enforced. type PodSecurityPolicySpec struct { // Privileged determines if a pod can request to be run as privileged. // +optional - Privileged bool `json:"privileged,omitempty"` + Privileged bool // DefaultAddCapabilities is the default set of capabilities that will be added to the container // unless the pod spec specifically drops the capability. You may not list a capability in both // DefaultAddCapabilities and RequiredDropCapabilities. // +optional - DefaultAddCapabilities []api.Capability `json:"defaultAddCapabilities,omitempty"` + DefaultAddCapabilities []api.Capability // RequiredDropCapabilities are the capabilities that will be dropped from the container. These // are required to be dropped and cannot be added. // +optional - RequiredDropCapabilities []api.Capability `json:"requiredDropCapabilities,omitempty"` + RequiredDropCapabilities []api.Capability // AllowedCapabilities is a list of capabilities that can be requested to add to the container. // Capabilities in this field may be added at the pod author's discretion. // You must not list a capability in both AllowedCapabilities and RequiredDropCapabilities. // +optional - AllowedCapabilities []api.Capability `json:"allowedCapabilities,omitempty"` + AllowedCapabilities []api.Capability // Volumes is a white list of allowed volume plugins. Empty indicates that all plugins // may be used. // +optional - Volumes []FSType `json:"volumes,omitempty"` + Volumes []FSType // HostNetwork determines if the policy allows the use of HostNetwork in the pod spec. // +optional - HostNetwork bool `json:"hostNetwork,omitempty"` + HostNetwork bool // HostPorts determines which host port ranges are allowed to be exposed. // +optional - HostPorts []HostPortRange `json:"hostPorts,omitempty"` + HostPorts []HostPortRange // HostPID determines if the policy allows the use of HostPID in the pod spec. // +optional - HostPID bool `json:"hostPID,omitempty"` + HostPID bool // HostIPC determines if the policy allows the use of HostIPC in the pod spec. // +optional - HostIPC bool `json:"hostIPC,omitempty"` + HostIPC bool // SELinux is the strategy that will dictate the allowable labels that may be set. - SELinux SELinuxStrategyOptions `json:"seLinux"` + SELinux SELinuxStrategyOptions // RunAsUser is the strategy that will dictate the allowable RunAsUser values that may be set. - RunAsUser RunAsUserStrategyOptions `json:"runAsUser"` + RunAsUser RunAsUserStrategyOptions // SupplementalGroups is the strategy that will dictate what supplemental groups are used by the SecurityContext. - SupplementalGroups SupplementalGroupsStrategyOptions `json:"supplementalGroups"` + SupplementalGroups SupplementalGroupsStrategyOptions // FSGroup is the strategy that will dictate what fs group is used by the SecurityContext. - FSGroup FSGroupStrategyOptions `json:"fsGroup"` + FSGroup FSGroupStrategyOptions // ReadOnlyRootFilesystem when set to true will force containers to run with a read only root file // system. If the container specifically requests to run with a non-read only root file system // the PSP should deny the pod. // If set to false the container may run with a read only root file system if it wishes but it // will not be forced to. // +optional - ReadOnlyRootFilesystem bool `json:"readOnlyRootFilesystem,omitempty"` + ReadOnlyRootFilesystem bool } // HostPortRange defines a range of host ports that will be enabled by a policy // for pods to use. It requires both the start and end to be defined. type HostPortRange struct { // Min is the start of the range, inclusive. - Min int `json:"min"` + Min int // Max is the end of the range, inclusive. - Max int `json:"max"` + Max int } // FSType gives strong typing to different file systems that are used by volumes. @@ -899,17 +935,21 @@ var ( Quobyte FSType = "quobyte" AzureDisk FSType = "azureDisk" PhotonPersistentDisk FSType = "photonPersistentDisk" + StorageOS FSType = "storageos" + Projected FSType = "projected" + PortworxVolume FSType = "portworxVolume" + ScaleIO FSType = "scaleIO" All FSType = "*" ) // SELinuxStrategyOptions defines the strategy type and any options used to create the strategy. type SELinuxStrategyOptions struct { // Rule is the strategy that will dictate the allowable labels that may be set. - Rule SELinuxStrategy `json:"rule"` + Rule SELinuxStrategy // seLinuxOptions required to run as; required for MustRunAs - // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context + // More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md // +optional - SELinuxOptions *api.SELinuxOptions `json:"seLinuxOptions,omitempty"` + SELinuxOptions *api.SELinuxOptions } // SELinuxStrategy denotes strategy types for generating SELinux options for a @@ -926,18 +966,26 @@ const ( // RunAsUserStrategyOptions defines the strategy type and any options used to create the strategy. type RunAsUserStrategyOptions struct { // Rule is the strategy that will dictate the allowable RunAsUser values that may be set. - Rule RunAsUserStrategy `json:"rule"` + Rule RunAsUserStrategy // Ranges are the allowed ranges of uids that may be used. // +optional - Ranges []IDRange `json:"ranges,omitempty"` + Ranges []UserIDRange +} + +// UserIDRange provides a min/max of an allowed range of UserIDs. +type UserIDRange struct { + // Min is the start of the range, inclusive. + Min int64 + // Max is the end of the range, inclusive. + Max int64 } -// IDRange provides a min/max of an allowed range of IDs. -type IDRange struct { +// GroupIDRange provides a min/max of an allowed range of GroupIDs. +type GroupIDRange struct { // Min is the start of the range, inclusive. - Min int64 `json:"min"` + Min int64 // Max is the end of the range, inclusive. - Max int64 `json:"max"` + Max int64 } // RunAsUserStrategy denotes strategy types for generating RunAsUser values for a @@ -957,11 +1005,11 @@ const ( type FSGroupStrategyOptions struct { // Rule is the strategy that will dictate what FSGroup is used in the SecurityContext. // +optional - Rule FSGroupStrategyType `json:"rule,omitempty"` + Rule FSGroupStrategyType // Ranges are the allowed ranges of fs groups. If you would like to force a single // fs group then supply a single range with the same start and end. // +optional - Ranges []IDRange `json:"ranges,omitempty"` + Ranges []GroupIDRange } // FSGroupStrategyType denotes strategy types for generating FSGroup values for a @@ -979,11 +1027,11 @@ const ( type SupplementalGroupsStrategyOptions struct { // Rule is the strategy that will dictate what supplemental groups is used in the SecurityContext. // +optional - Rule SupplementalGroupsStrategyType `json:"rule,omitempty"` + Rule SupplementalGroupsStrategyType // Ranges are the allowed ranges of supplemental groups. If you would like to force a single // supplemental group then supply a single range with the same start and end. // +optional - Ranges []IDRange `json:"ranges,omitempty"` + Ranges []GroupIDRange } // SupplementalGroupsStrategyType denotes strategy types for determining valid supplemental @@ -999,23 +1047,24 @@ const ( // PodSecurityPolicyList is a list of PodSecurityPolicy objects. type PodSecurityPolicyList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []PodSecurityPolicy `json:"items"` + Items []PodSecurityPolicy } // +genclient=true +// NetworkPolicy describes what network traffic is allowed for a set of Pods type NetworkPolicy struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Specification of the desired behavior for this NetworkPolicy. // +optional - Spec NetworkPolicySpec `json:"spec,omitempty"` + Spec NetworkPolicySpec } type NetworkPolicySpec struct { @@ -1024,48 +1073,43 @@ type NetworkPolicySpec struct { // same set of pods. In this case, the ingress rules for each are combined additively. // This field is NOT optional and follows standard label selector semantics. // An empty podSelector matches all pods in this namespace. - PodSelector unversioned.LabelSelector `json:"podSelector"` + PodSelector metav1.LabelSelector // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional - Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty"` + Ingress []NetworkPolicyIngressRule } // This NetworkPolicyIngressRule matches traffic if and only if the traffic matches both ports AND from. type NetworkPolicyIngressRule struct { // List of ports which should be made accessible on the pods selected for this rule. // Each item in this list is combined using a logical OR. - // If this field is not provided, this rule matches all ports (traffic not restricted by port). - // If this field is empty, this rule matches no ports (no traffic matches). + // If this field is empty or missing, this rule matches all ports (traffic not restricted by port). // If this field is present and contains at least one item, then this rule allows traffic // only if the traffic matches at least one port in the list. - // TODO: Update this to be a pointer to slice as soon as auto-generation supports it. // +optional - Ports []NetworkPolicyPort `json:"ports,omitempty"` + Ports []NetworkPolicyPort // List of sources which should be able to access the pods selected for this rule. // Items in this list are combined using a logical OR operation. - // If this field is not provided, this rule matches all sources (traffic not restricted by source). - // If this field is empty, this rule matches no sources (no traffic matches). + // If this field is empty or missing, this rule matches all sources (traffic not restricted by source). // If this field is present and contains at least on item, this rule allows traffic only if the // traffic matches at least one item in the from list. - // TODO: Update this to be a pointer to slice as soon as auto-generation supports it. // +optional - From []NetworkPolicyPeer `json:"from,omitempty"` + From []NetworkPolicyPeer } type NetworkPolicyPort struct { // Optional. The protocol (TCP or UDP) which traffic must match. // If not specified, this field defaults to TCP. // +optional - Protocol *api.Protocol `json:"protocol,omitempty"` + Protocol *api.Protocol // If specified, the port on the given protocol. This can // either be a numerical or named port on a pod. If this field is not provided, @@ -1073,7 +1117,7 @@ type NetworkPolicyPort struct { // If present, only traffic on the specified protocol AND port // will be matched. // +optional - Port *intstr.IntOrString `json:"port,omitempty"` + Port *intstr.IntOrString } type NetworkPolicyPeer struct { @@ -1081,25 +1125,23 @@ type NetworkPolicyPeer struct { // This is a label selector which selects Pods in this namespace. // This field follows standard label selector semantics. - // If not provided, this selector selects no pods. // If present but empty, this selector selects all pods in this namespace. // +optional - PodSelector *unversioned.LabelSelector `json:"podSelector,omitempty"` + PodSelector *metav1.LabelSelector // Selects Namespaces using cluster scoped-labels. This // matches all pods in all namespaces selected by this label selector. // This field follows standard label selector semantics. - // If omitted, this selector selects no namespaces. // If present but empty, this selector selects all namespaces. // +optional - NamespaceSelector *unversioned.LabelSelector `json:"namespaceSelector,omitempty"` + NamespaceSelector *metav1.LabelSelector } // NetworkPolicyList is a list of NetworkPolicy objects. type NetworkPolicyList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta - Items []NetworkPolicy `json:"items"` + Items []NetworkPolicy } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD new file mode 100644 index 0000000000..bb6b964147 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/BUILD @@ -0,0 +1,43 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/resource:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/apps/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go index 38f7a2766e..cec1e5e435 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/conversion.go @@ -19,15 +19,14 @@ package v1beta1 import ( "fmt" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" v1 "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/apis/autoscaling" - "k8s.io/client-go/pkg/apis/batch" "k8s.io/client-go/pkg/apis/extensions" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/intstr" + "k8s.io/client-go/pkg/apis/networking" ) func addConversionFuncs(scheme *runtime.Scheme) error { @@ -41,16 +40,22 @@ func addConversionFuncs(scheme *runtime.Scheme) error { Convert_v1beta1_DeploymentStrategy_To_extensions_DeploymentStrategy, Convert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployment, Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployment, + Convert_extensions_RollingUpdateDaemonSet_To_v1beta1_RollingUpdateDaemonSet, + Convert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet, Convert_extensions_ReplicaSetSpec_To_v1beta1_ReplicaSetSpec, Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec, - // autoscaling - Convert_autoscaling_CrossVersionObjectReference_To_v1beta1_SubresourceReference, - Convert_v1beta1_SubresourceReference_To_autoscaling_CrossVersionObjectReference, - Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1beta1_HorizontalPodAutoscalerSpec, - Convert_v1beta1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec, - // batch - Convert_batch_JobSpec_To_v1beta1_JobSpec, - Convert_v1beta1_JobSpec_To_batch_JobSpec, + Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy, + Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy, + Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule, + Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule, + Convert_v1beta1_NetworkPolicyList_To_networking_NetworkPolicyList, + Convert_networking_NetworkPolicyList_To_v1beta1_NetworkPolicyList, + Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer, + Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer, + Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort, + Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort, + Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec, + Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec, ) if err != nil { return err @@ -59,7 +64,7 @@ func addConversionFuncs(scheme *runtime.Scheme) error { // Add field label conversions for kinds having selectable nothing but ObjectMeta fields. for _, k := range []string{"DaemonSet", "Deployment", "Ingress"} { kind := k // don't close over range variables - err = api.Scheme.AddFieldLabelConversionFunc("extensions/v1beta1", kind, + err = scheme.AddFieldLabelConversionFunc("extensions/v1beta1", kind, func(label, value string) (string, string, error) { switch label { case "metadata.name", "metadata.namespace": @@ -74,16 +79,7 @@ func addConversionFuncs(scheme *runtime.Scheme) error { } } - return api.Scheme.AddFieldLabelConversionFunc("extensions/v1beta1", "Job", - func(label, value string) (string, string, error) { - switch label { - case "metadata.name", "metadata.namespace", "status.successful": - return label, value, nil - default: - return "", "", fmt.Errorf("field label not supported: %s", label) - } - }, - ) + return nil } func Convert_extensions_ScaleStatus_To_v1beta1_ScaleStatus(in *extensions.ScaleStatus, out *ScaleStatus, s conversion.Scope) error { @@ -96,7 +92,7 @@ func Convert_extensions_ScaleStatus_To_v1beta1_ScaleStatus(in *extensions.ScaleS out.Selector = in.Selector.MatchLabels } - selector, err := unversioned.LabelSelectorAsSelector(in.Selector) + selector, err := metav1.LabelSelectorAsSelector(in.Selector) if err != nil { return fmt.Errorf("invalid label selector: %v", err) } @@ -113,14 +109,14 @@ func Convert_v1beta1_ScaleStatus_To_extensions_ScaleStatus(in *ScaleStatus, out // new field can be expected to know about the old field (though that's not quite true, due // to kubectl apply). However, these fields are readonly, so any non-nil value should work. if in.TargetSelector != "" { - labelSelector, err := unversioned.ParseToLabelSelector(in.TargetSelector) + labelSelector, err := metav1.ParseToLabelSelector(in.TargetSelector) if err != nil { out.Selector = nil return fmt.Errorf("failed to parse target selector: %v", err) } out.Selector = labelSelector } else if in.Selector != nil { - out.Selector = new(unversioned.LabelSelector) + out.Selector = new(metav1.LabelSelector) selector := make(map[string]string) for key, val := range in.Selector { selector[key] = val @@ -239,6 +235,23 @@ func Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployme return nil } +func Convert_extensions_RollingUpdateDaemonSet_To_v1beta1_RollingUpdateDaemonSet(in *extensions.RollingUpdateDaemonSet, out *RollingUpdateDaemonSet, s conversion.Scope) error { + if out.MaxUnavailable == nil { + out.MaxUnavailable = &intstr.IntOrString{} + } + if err := s.Convert(&in.MaxUnavailable, out.MaxUnavailable, 0); err != nil { + return err + } + return nil +} + +func Convert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet(in *RollingUpdateDaemonSet, out *extensions.RollingUpdateDaemonSet, s conversion.Scope) error { + if err := s.Convert(in.MaxUnavailable, &out.MaxUnavailable, 0); err != nil { + return err + } + return nil +} + func Convert_extensions_ReplicaSetSpec_To_v1beta1_ReplicaSetSpec(in *extensions.ReplicaSetSpec, out *ReplicaSetSpec, s conversion.Scope) error { out.Replicas = new(int32) *out.Replicas = int32(in.Replicas) @@ -262,102 +275,154 @@ func Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec(in *ReplicaSetS return nil } -func Convert_batch_JobSpec_To_v1beta1_JobSpec(in *batch.JobSpec, out *JobSpec, s conversion.Scope) error { - out.Parallelism = in.Parallelism - out.Completions = in.Completions - out.ActiveDeadlineSeconds = in.ActiveDeadlineSeconds - out.Selector = in.Selector - // BEGIN non-standard conversion - // autoSelector has opposite meaning as manualSelector. - // in both cases, unset means false, and unset is always preferred to false. - // unset vs set-false distinction is not preserved. - manualSelector := in.ManualSelector != nil && *in.ManualSelector - autoSelector := !manualSelector - if autoSelector { - out.AutoSelector = new(bool) - *out.AutoSelector = true - } else { - out.AutoSelector = nil - } - // END non-standard conversion +func Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { +func Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_v1beta1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { return err } + out.Ingress = make([]networking.NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } return nil } -func Convert_v1beta1_JobSpec_To_batch_JobSpec(in *JobSpec, out *batch.JobSpec, s conversion.Scope) error { - out.Parallelism = in.Parallelism - out.Completions = in.Completions - out.ActiveDeadlineSeconds = in.ActiveDeadlineSeconds - out.Selector = in.Selector - // BEGIN non-standard conversion - // autoSelector has opposite meaning as manualSelector. - // in both cases, unset means false, and unset is always preferred to false. - // unset vs set-false distinction is not preserved. - autoSelector := bool(in.AutoSelector != nil && *in.AutoSelector) - manualSelector := !autoSelector - if manualSelector { - out.ManualSelector = new(bool) - *out.ManualSelector = true - } else { - out.ManualSelector = nil - } - // END non-standard conversion - - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { +func Convert_networking_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { return err } + out.Ingress = make([]NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } return nil } -func Convert_autoscaling_CrossVersionObjectReference_To_v1beta1_SubresourceReference(in *autoscaling.CrossVersionObjectReference, out *SubresourceReference, s conversion.Scope) error { - out.Kind = in.Kind - out.Name = in.Name - out.APIVersion = in.APIVersion - out.Subresource = "scale" +func Convert_v1beta1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]networking.NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]networking.NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } return nil } -func Convert_v1beta1_SubresourceReference_To_autoscaling_CrossVersionObjectReference(in *SubresourceReference, out *autoscaling.CrossVersionObjectReference, s conversion.Scope) error { - out.Kind = in.Kind - out.Name = in.Name - out.APIVersion = in.APIVersion +func Convert_networking_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } return nil } -func Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1beta1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { - if err := Convert_autoscaling_CrossVersionObjectReference_To_v1beta1_SubresourceReference(&in.ScaleTargetRef, &out.ScaleRef, s); err != nil { - return err +func Convert_v1beta1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil } - if in.MinReplicas != nil { - out.MinReplicas = new(int32) - *out.MinReplicas = *in.MinReplicas + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } } else { - out.MinReplicas = nil + out.NamespaceSelector = nil } - out.MaxReplicas = in.MaxReplicas - if in.TargetCPUUtilizationPercentage != nil { - out.CPUUtilization = &CPUTargetUtilization{TargetPercentage: *in.TargetCPUUtilizationPercentage} + return nil +} + +func Convert_networking_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil } return nil } -func Convert_v1beta1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in *HorizontalPodAutoscalerSpec, out *autoscaling.HorizontalPodAutoscalerSpec, s conversion.Scope) error { - if err := Convert_v1beta1_SubresourceReference_To_autoscaling_CrossVersionObjectReference(&in.ScaleRef, &out.ScaleTargetRef, s); err != nil { - return err +func Convert_v1beta1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(api.Protocol) + *out.Protocol = api.Protocol(*in.Protocol) + } else { + out.Protocol = nil } - if in.MinReplicas != nil { - out.MinReplicas = new(int32) - *out.MinReplicas = int32(*in.MinReplicas) + out.Port = in.Port + return nil +} + +func Convert_networking_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(v1.Protocol) + *out.Protocol = v1.Protocol(*in.Protocol) } else { - out.MinReplicas = nil + out.Protocol = nil } - out.MaxReplicas = int32(in.MaxReplicas) - if in.CPUUtilization != nil { - out.TargetCPUUtilizationPercentage = new(int32) - *out.TargetCPUUtilizationPercentage = int32(in.CPUUtilization.TargetPercentage) + out.Port = in.Port + return nil +} + +func Convert_v1beta1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]networking.NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_v1beta1_NetworkPolicy_To_networking_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_networking_NetworkPolicyList_To_v1beta1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_networking_NetworkPolicy_To_v1beta1_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/defaults.go index 2704d67f3f..a644e5ab9d 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/defaults.go @@ -17,22 +17,14 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/intstr" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_DaemonSet, - SetDefaults_Deployment, - SetDefaults_Job, - SetDefaults_HorizontalPodAutoscaler, - SetDefaults_ReplicaSet, - SetDefaults_NetworkPolicy, - ) + return RegisterDefaults(scheme) } func SetDefaults_DaemonSet(obj *DaemonSet) { @@ -41,7 +33,7 @@ func SetDefaults_DaemonSet(obj *DaemonSet) { // TODO: support templates defined elsewhere when we support them in the API if labels != nil { if obj.Spec.Selector == nil { - obj.Spec.Selector = &unversioned.LabelSelector{ + obj.Spec.Selector = &metav1.LabelSelector{ MatchLabels: labels, } } @@ -49,6 +41,25 @@ func SetDefaults_DaemonSet(obj *DaemonSet) { obj.Labels = labels } } + updateStrategy := &obj.Spec.UpdateStrategy + if updateStrategy.Type == "" { + updateStrategy.Type = OnDeleteDaemonSetStrategyType + } + if updateStrategy.Type == RollingUpdateDaemonSetStrategyType { + if updateStrategy.RollingUpdate == nil { + rollingUpdate := RollingUpdateDaemonSet{} + updateStrategy.RollingUpdate = &rollingUpdate + } + if updateStrategy.RollingUpdate.MaxUnavailable == nil { + // Set default MaxUnavailable as 1 by default. + maxUnavailable := intstr.FromInt(1) + updateStrategy.RollingUpdate.MaxUnavailable = &maxUnavailable + } + } + if obj.Spec.RevisionHistoryLimit == nil { + obj.Spec.RevisionHistoryLimit = new(int32) + *obj.Spec.RevisionHistoryLimit = 10 + } } func SetDefaults_Deployment(obj *Deployment) { @@ -57,7 +68,7 @@ func SetDefaults_Deployment(obj *Deployment) { if labels != nil { if obj.Spec.Selector == nil { - obj.Spec.Selector = &unversioned.LabelSelector{MatchLabels: labels} + obj.Spec.Selector = &metav1.LabelSelector{MatchLabels: labels} } if len(obj.Labels) == 0 { obj.Labels = labels @@ -91,57 +102,13 @@ func SetDefaults_Deployment(obj *Deployment) { } } -func SetDefaults_Job(obj *Job) { - labels := obj.Spec.Template.Labels - // TODO: support templates defined elsewhere when we support them in the API - if labels != nil { - // if an autoselector is requested, we'll build the selector later with controller-uid and job-name - autoSelector := bool(obj.Spec.AutoSelector != nil && *obj.Spec.AutoSelector) - - // otherwise, we are using a manual selector - manualSelector := !autoSelector - - // and default behavior for an unspecified manual selector is to use the pod template labels - if manualSelector && obj.Spec.Selector == nil { - obj.Spec.Selector = &unversioned.LabelSelector{ - MatchLabels: labels, - } - } - if len(obj.Labels) == 0 { - obj.Labels = labels - } - } - // For a non-parallel job, you can leave both `.spec.completions` and - // `.spec.parallelism` unset. When both are unset, both are defaulted to 1. - if obj.Spec.Completions == nil && obj.Spec.Parallelism == nil { - obj.Spec.Completions = new(int32) - *obj.Spec.Completions = 1 - obj.Spec.Parallelism = new(int32) - *obj.Spec.Parallelism = 1 - } - if obj.Spec.Parallelism == nil { - obj.Spec.Parallelism = new(int32) - *obj.Spec.Parallelism = 1 - } -} - -func SetDefaults_HorizontalPodAutoscaler(obj *HorizontalPodAutoscaler) { - if obj.Spec.MinReplicas == nil { - minReplicas := int32(1) - obj.Spec.MinReplicas = &minReplicas - } - if obj.Spec.CPUUtilization == nil { - obj.Spec.CPUUtilization = &CPUTargetUtilization{TargetPercentage: 80} - } -} - func SetDefaults_ReplicaSet(obj *ReplicaSet) { labels := obj.Spec.Template.Labels // TODO: support templates defined elsewhere when we support them in the API if labels != nil { if obj.Spec.Selector == nil { - obj.Spec.Selector = &unversioned.LabelSelector{ + obj.Spec.Selector = &metav1.LabelSelector{ MatchLabels: labels, } } @@ -158,7 +125,6 @@ func SetDefaults_ReplicaSet(obj *ReplicaSet) { func SetDefaults_NetworkPolicy(obj *NetworkPolicy) { // Default any undefined Protocol fields to TCP. for _, i := range obj.Spec.Ingress { - // TODO: Update Ports to be a pointer to slice as soon as auto-generation supports it. for _, p := range i.Ports { if p.Protocol == nil { proto := v1.ProtocolTCP diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/doc.go index 2a7ce91344..a397b30e92 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/doc.go @@ -14,11 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/extensions -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/autoscaling -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/batch -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go index 0260da7dd5..871bd924df 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -26,7 +26,6 @@ limitations under the License. It has these top-level messages: APIVersion - CPUTargetUtilization CustomMetricCurrentStatus CustomMetricCurrentStatusList CustomMetricTarget @@ -35,6 +34,7 @@ limitations under the License. DaemonSetList DaemonSetSpec DaemonSetStatus + DaemonSetUpdateStrategy Deployment DeploymentCondition DeploymentList @@ -42,14 +42,9 @@ limitations under the License. DeploymentSpec DeploymentStatus DeploymentStrategy - ExportOptions FSGroupStrategyOptions HTTPIngressPath HTTPIngressRuleValue - HorizontalPodAutoscaler - HorizontalPodAutoscalerList - HorizontalPodAutoscalerSpec - HorizontalPodAutoscalerStatus HostPortRange IDRange Ingress @@ -60,11 +55,6 @@ limitations under the License. IngressSpec IngressStatus IngressTLS - Job - JobCondition - JobList - JobSpec - JobStatus NetworkPolicy NetworkPolicyIngressRule NetworkPolicyList @@ -81,13 +71,13 @@ limitations under the License. ReplicaSetStatus ReplicationControllerDummy RollbackConfig + RollingUpdateDaemonSet RollingUpdateDeployment RunAsUserStrategyOptions SELinuxStrategyOptions Scale ScaleSpec ScaleStatus - SubresourceReference SupplementalGroupsStrategyOptions ThirdPartyResource ThirdPartyResourceData @@ -100,14 +90,15 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" -import k8s_io_kubernetes_pkg_util_intstr "k8s.io/client-go/pkg/util/intstr" +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import strings "strings" import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import io "io" @@ -118,51 +109,53 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *APIVersion) Reset() { *m = APIVersion{} } func (*APIVersion) ProtoMessage() {} func (*APIVersion) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } -func (m *CPUTargetUtilization) Reset() { *m = CPUTargetUtilization{} } -func (*CPUTargetUtilization) ProtoMessage() {} -func (*CPUTargetUtilization) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } - func (m *CustomMetricCurrentStatus) Reset() { *m = CustomMetricCurrentStatus{} } func (*CustomMetricCurrentStatus) ProtoMessage() {} func (*CustomMetricCurrentStatus) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{2} + return fileDescriptorGenerated, []int{1} } func (m *CustomMetricCurrentStatusList) Reset() { *m = CustomMetricCurrentStatusList{} } func (*CustomMetricCurrentStatusList) ProtoMessage() {} func (*CustomMetricCurrentStatusList) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{3} + return fileDescriptorGenerated, []int{2} } func (m *CustomMetricTarget) Reset() { *m = CustomMetricTarget{} } func (*CustomMetricTarget) ProtoMessage() {} -func (*CustomMetricTarget) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } +func (*CustomMetricTarget) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } func (m *CustomMetricTargetList) Reset() { *m = CustomMetricTargetList{} } func (*CustomMetricTargetList) ProtoMessage() {} -func (*CustomMetricTargetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } +func (*CustomMetricTargetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } func (m *DaemonSet) Reset() { *m = DaemonSet{} } func (*DaemonSet) ProtoMessage() {} -func (*DaemonSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } +func (*DaemonSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } func (m *DaemonSetList) Reset() { *m = DaemonSetList{} } func (*DaemonSetList) ProtoMessage() {} -func (*DaemonSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } +func (*DaemonSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } func (m *DaemonSetSpec) Reset() { *m = DaemonSetSpec{} } func (*DaemonSetSpec) ProtoMessage() {} -func (*DaemonSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } +func (*DaemonSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } func (m *DaemonSetStatus) Reset() { *m = DaemonSetStatus{} } func (*DaemonSetStatus) ProtoMessage() {} -func (*DaemonSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } +func (*DaemonSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *DaemonSetUpdateStrategy) Reset() { *m = DaemonSetUpdateStrategy{} } +func (*DaemonSetUpdateStrategy) ProtoMessage() {} +func (*DaemonSetUpdateStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } func (m *Deployment) Reset() { *m = Deployment{} } func (*Deployment) ProtoMessage() {} @@ -192,233 +185,184 @@ func (m *DeploymentStrategy) Reset() { *m = DeploymentStrateg func (*DeploymentStrategy) ProtoMessage() {} func (*DeploymentStrategy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{16} } -func (m *ExportOptions) Reset() { *m = ExportOptions{} } -func (*ExportOptions) ProtoMessage() {} -func (*ExportOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } - func (m *FSGroupStrategyOptions) Reset() { *m = FSGroupStrategyOptions{} } func (*FSGroupStrategyOptions) ProtoMessage() {} -func (*FSGroupStrategyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} } +func (*FSGroupStrategyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{17} } func (m *HTTPIngressPath) Reset() { *m = HTTPIngressPath{} } func (*HTTPIngressPath) ProtoMessage() {} -func (*HTTPIngressPath) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{19} } +func (*HTTPIngressPath) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{18} } func (m *HTTPIngressRuleValue) Reset() { *m = HTTPIngressRuleValue{} } func (*HTTPIngressRuleValue) ProtoMessage() {} -func (*HTTPIngressRuleValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } - -func (m *HorizontalPodAutoscaler) Reset() { *m = HorizontalPodAutoscaler{} } -func (*HorizontalPodAutoscaler) ProtoMessage() {} -func (*HorizontalPodAutoscaler) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{21} -} - -func (m *HorizontalPodAutoscalerList) Reset() { *m = HorizontalPodAutoscalerList{} } -func (*HorizontalPodAutoscalerList) ProtoMessage() {} -func (*HorizontalPodAutoscalerList) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{22} -} - -func (m *HorizontalPodAutoscalerSpec) Reset() { *m = HorizontalPodAutoscalerSpec{} } -func (*HorizontalPodAutoscalerSpec) ProtoMessage() {} -func (*HorizontalPodAutoscalerSpec) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{23} -} - -func (m *HorizontalPodAutoscalerStatus) Reset() { *m = HorizontalPodAutoscalerStatus{} } -func (*HorizontalPodAutoscalerStatus) ProtoMessage() {} -func (*HorizontalPodAutoscalerStatus) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{24} -} +func (*HTTPIngressRuleValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{19} } func (m *HostPortRange) Reset() { *m = HostPortRange{} } func (*HostPortRange) ProtoMessage() {} -func (*HostPortRange) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{25} } +func (*HostPortRange) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{20} } func (m *IDRange) Reset() { *m = IDRange{} } func (*IDRange) ProtoMessage() {} -func (*IDRange) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{26} } +func (*IDRange) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{21} } func (m *Ingress) Reset() { *m = Ingress{} } func (*Ingress) ProtoMessage() {} -func (*Ingress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } +func (*Ingress) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{22} } func (m *IngressBackend) Reset() { *m = IngressBackend{} } func (*IngressBackend) ProtoMessage() {} -func (*IngressBackend) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{28} } +func (*IngressBackend) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{23} } func (m *IngressList) Reset() { *m = IngressList{} } func (*IngressList) ProtoMessage() {} -func (*IngressList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } +func (*IngressList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{24} } func (m *IngressRule) Reset() { *m = IngressRule{} } func (*IngressRule) ProtoMessage() {} -func (*IngressRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } +func (*IngressRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{25} } func (m *IngressRuleValue) Reset() { *m = IngressRuleValue{} } func (*IngressRuleValue) ProtoMessage() {} -func (*IngressRuleValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{31} } +func (*IngressRuleValue) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{26} } func (m *IngressSpec) Reset() { *m = IngressSpec{} } func (*IngressSpec) ProtoMessage() {} -func (*IngressSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } +func (*IngressSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{27} } func (m *IngressStatus) Reset() { *m = IngressStatus{} } func (*IngressStatus) ProtoMessage() {} -func (*IngressStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } +func (*IngressStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{28} } func (m *IngressTLS) Reset() { *m = IngressTLS{} } func (*IngressTLS) ProtoMessage() {} -func (*IngressTLS) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{34} } - -func (m *Job) Reset() { *m = Job{} } -func (*Job) ProtoMessage() {} -func (*Job) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{35} } - -func (m *JobCondition) Reset() { *m = JobCondition{} } -func (*JobCondition) ProtoMessage() {} -func (*JobCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{36} } - -func (m *JobList) Reset() { *m = JobList{} } -func (*JobList) ProtoMessage() {} -func (*JobList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{37} } - -func (m *JobSpec) Reset() { *m = JobSpec{} } -func (*JobSpec) ProtoMessage() {} -func (*JobSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{38} } - -func (m *JobStatus) Reset() { *m = JobStatus{} } -func (*JobStatus) ProtoMessage() {} -func (*JobStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{39} } +func (*IngressTLS) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{29} } func (m *NetworkPolicy) Reset() { *m = NetworkPolicy{} } func (*NetworkPolicy) ProtoMessage() {} -func (*NetworkPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{40} } +func (*NetworkPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{30} } func (m *NetworkPolicyIngressRule) Reset() { *m = NetworkPolicyIngressRule{} } func (*NetworkPolicyIngressRule) ProtoMessage() {} func (*NetworkPolicyIngressRule) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{41} + return fileDescriptorGenerated, []int{31} } func (m *NetworkPolicyList) Reset() { *m = NetworkPolicyList{} } func (*NetworkPolicyList) ProtoMessage() {} -func (*NetworkPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{42} } +func (*NetworkPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{32} } func (m *NetworkPolicyPeer) Reset() { *m = NetworkPolicyPeer{} } func (*NetworkPolicyPeer) ProtoMessage() {} -func (*NetworkPolicyPeer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{43} } +func (*NetworkPolicyPeer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{33} } func (m *NetworkPolicyPort) Reset() { *m = NetworkPolicyPort{} } func (*NetworkPolicyPort) ProtoMessage() {} -func (*NetworkPolicyPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{44} } +func (*NetworkPolicyPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{34} } func (m *NetworkPolicySpec) Reset() { *m = NetworkPolicySpec{} } func (*NetworkPolicySpec) ProtoMessage() {} -func (*NetworkPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{45} } +func (*NetworkPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{35} } func (m *PodSecurityPolicy) Reset() { *m = PodSecurityPolicy{} } func (*PodSecurityPolicy) ProtoMessage() {} -func (*PodSecurityPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{46} } +func (*PodSecurityPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{36} } func (m *PodSecurityPolicyList) Reset() { *m = PodSecurityPolicyList{} } func (*PodSecurityPolicyList) ProtoMessage() {} -func (*PodSecurityPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{47} } +func (*PodSecurityPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{37} } func (m *PodSecurityPolicySpec) Reset() { *m = PodSecurityPolicySpec{} } func (*PodSecurityPolicySpec) ProtoMessage() {} -func (*PodSecurityPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{48} } +func (*PodSecurityPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{38} } func (m *ReplicaSet) Reset() { *m = ReplicaSet{} } func (*ReplicaSet) ProtoMessage() {} -func (*ReplicaSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{49} } +func (*ReplicaSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{39} } func (m *ReplicaSetCondition) Reset() { *m = ReplicaSetCondition{} } func (*ReplicaSetCondition) ProtoMessage() {} -func (*ReplicaSetCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{50} } +func (*ReplicaSetCondition) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{40} } func (m *ReplicaSetList) Reset() { *m = ReplicaSetList{} } func (*ReplicaSetList) ProtoMessage() {} -func (*ReplicaSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{51} } +func (*ReplicaSetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{41} } func (m *ReplicaSetSpec) Reset() { *m = ReplicaSetSpec{} } func (*ReplicaSetSpec) ProtoMessage() {} -func (*ReplicaSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{52} } +func (*ReplicaSetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{42} } func (m *ReplicaSetStatus) Reset() { *m = ReplicaSetStatus{} } func (*ReplicaSetStatus) ProtoMessage() {} -func (*ReplicaSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{53} } +func (*ReplicaSetStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{43} } func (m *ReplicationControllerDummy) Reset() { *m = ReplicationControllerDummy{} } func (*ReplicationControllerDummy) ProtoMessage() {} func (*ReplicationControllerDummy) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{54} + return fileDescriptorGenerated, []int{44} } func (m *RollbackConfig) Reset() { *m = RollbackConfig{} } func (*RollbackConfig) ProtoMessage() {} -func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{55} } +func (*RollbackConfig) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{45} } + +func (m *RollingUpdateDaemonSet) Reset() { *m = RollingUpdateDaemonSet{} } +func (*RollingUpdateDaemonSet) ProtoMessage() {} +func (*RollingUpdateDaemonSet) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{46} } func (m *RollingUpdateDeployment) Reset() { *m = RollingUpdateDeployment{} } func (*RollingUpdateDeployment) ProtoMessage() {} func (*RollingUpdateDeployment) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{56} + return fileDescriptorGenerated, []int{47} } func (m *RunAsUserStrategyOptions) Reset() { *m = RunAsUserStrategyOptions{} } func (*RunAsUserStrategyOptions) ProtoMessage() {} func (*RunAsUserStrategyOptions) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{57} + return fileDescriptorGenerated, []int{48} } func (m *SELinuxStrategyOptions) Reset() { *m = SELinuxStrategyOptions{} } func (*SELinuxStrategyOptions) ProtoMessage() {} -func (*SELinuxStrategyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{58} } +func (*SELinuxStrategyOptions) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{49} } func (m *Scale) Reset() { *m = Scale{} } func (*Scale) ProtoMessage() {} -func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{59} } +func (*Scale) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{50} } func (m *ScaleSpec) Reset() { *m = ScaleSpec{} } func (*ScaleSpec) ProtoMessage() {} -func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{60} } +func (*ScaleSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{51} } func (m *ScaleStatus) Reset() { *m = ScaleStatus{} } func (*ScaleStatus) ProtoMessage() {} -func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{61} } - -func (m *SubresourceReference) Reset() { *m = SubresourceReference{} } -func (*SubresourceReference) ProtoMessage() {} -func (*SubresourceReference) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{62} } +func (*ScaleStatus) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{52} } func (m *SupplementalGroupsStrategyOptions) Reset() { *m = SupplementalGroupsStrategyOptions{} } func (*SupplementalGroupsStrategyOptions) ProtoMessage() {} func (*SupplementalGroupsStrategyOptions) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{63} + return fileDescriptorGenerated, []int{53} } func (m *ThirdPartyResource) Reset() { *m = ThirdPartyResource{} } func (*ThirdPartyResource) ProtoMessage() {} -func (*ThirdPartyResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{64} } +func (*ThirdPartyResource) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{54} } func (m *ThirdPartyResourceData) Reset() { *m = ThirdPartyResourceData{} } func (*ThirdPartyResourceData) ProtoMessage() {} -func (*ThirdPartyResourceData) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{65} } +func (*ThirdPartyResourceData) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{55} } func (m *ThirdPartyResourceDataList) Reset() { *m = ThirdPartyResourceDataList{} } func (*ThirdPartyResourceDataList) ProtoMessage() {} func (*ThirdPartyResourceDataList) Descriptor() ([]byte, []int) { - return fileDescriptorGenerated, []int{66} + return fileDescriptorGenerated, []int{56} } func (m *ThirdPartyResourceList) Reset() { *m = ThirdPartyResourceList{} } func (*ThirdPartyResourceList) ProtoMessage() {} -func (*ThirdPartyResourceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{67} } +func (*ThirdPartyResourceList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{57} } func init() { proto.RegisterType((*APIVersion)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.APIVersion") - proto.RegisterType((*CPUTargetUtilization)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.CPUTargetUtilization") proto.RegisterType((*CustomMetricCurrentStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.CustomMetricCurrentStatus") proto.RegisterType((*CustomMetricCurrentStatusList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.CustomMetricCurrentStatusList") proto.RegisterType((*CustomMetricTarget)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.CustomMetricTarget") @@ -427,6 +371,7 @@ func init() { proto.RegisterType((*DaemonSetList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DaemonSetList") proto.RegisterType((*DaemonSetSpec)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DaemonSetSpec") proto.RegisterType((*DaemonSetStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DaemonSetStatus") + proto.RegisterType((*DaemonSetUpdateStrategy)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DaemonSetUpdateStrategy") proto.RegisterType((*Deployment)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.Deployment") proto.RegisterType((*DeploymentCondition)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DeploymentCondition") proto.RegisterType((*DeploymentList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DeploymentList") @@ -434,14 +379,9 @@ func init() { proto.RegisterType((*DeploymentSpec)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DeploymentSpec") proto.RegisterType((*DeploymentStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DeploymentStatus") proto.RegisterType((*DeploymentStrategy)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.DeploymentStrategy") - proto.RegisterType((*ExportOptions)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ExportOptions") proto.RegisterType((*FSGroupStrategyOptions)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.FSGroupStrategyOptions") proto.RegisterType((*HTTPIngressPath)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HTTPIngressPath") proto.RegisterType((*HTTPIngressRuleValue)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HTTPIngressRuleValue") - proto.RegisterType((*HorizontalPodAutoscaler)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HorizontalPodAutoscaler") - proto.RegisterType((*HorizontalPodAutoscalerList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HorizontalPodAutoscalerList") - proto.RegisterType((*HorizontalPodAutoscalerSpec)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HorizontalPodAutoscalerSpec") - proto.RegisterType((*HorizontalPodAutoscalerStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HorizontalPodAutoscalerStatus") proto.RegisterType((*HostPortRange)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.HostPortRange") proto.RegisterType((*IDRange)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.IDRange") proto.RegisterType((*Ingress)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.Ingress") @@ -452,11 +392,6 @@ func init() { proto.RegisterType((*IngressSpec)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.IngressSpec") proto.RegisterType((*IngressStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.IngressStatus") proto.RegisterType((*IngressTLS)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.IngressTLS") - proto.RegisterType((*Job)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.Job") - proto.RegisterType((*JobCondition)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.JobCondition") - proto.RegisterType((*JobList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.JobList") - proto.RegisterType((*JobSpec)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.JobSpec") - proto.RegisterType((*JobStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.JobStatus") proto.RegisterType((*NetworkPolicy)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.NetworkPolicy") proto.RegisterType((*NetworkPolicyIngressRule)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.NetworkPolicyIngressRule") proto.RegisterType((*NetworkPolicyList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.NetworkPolicyList") @@ -473,85 +408,64 @@ func init() { proto.RegisterType((*ReplicaSetStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ReplicaSetStatus") proto.RegisterType((*ReplicationControllerDummy)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ReplicationControllerDummy") proto.RegisterType((*RollbackConfig)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.RollbackConfig") + proto.RegisterType((*RollingUpdateDaemonSet)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.RollingUpdateDaemonSet") proto.RegisterType((*RollingUpdateDeployment)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.RollingUpdateDeployment") proto.RegisterType((*RunAsUserStrategyOptions)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.RunAsUserStrategyOptions") proto.RegisterType((*SELinuxStrategyOptions)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.SELinuxStrategyOptions") proto.RegisterType((*Scale)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.Scale") proto.RegisterType((*ScaleSpec)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ScaleSpec") proto.RegisterType((*ScaleStatus)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ScaleStatus") - proto.RegisterType((*SubresourceReference)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.SubresourceReference") proto.RegisterType((*SupplementalGroupsStrategyOptions)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.SupplementalGroupsStrategyOptions") proto.RegisterType((*ThirdPartyResource)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ThirdPartyResource") proto.RegisterType((*ThirdPartyResourceData)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ThirdPartyResourceData") proto.RegisterType((*ThirdPartyResourceDataList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ThirdPartyResourceDataList") proto.RegisterType((*ThirdPartyResourceList)(nil), "k8s.io.client-go.pkg.apis.extensions.v1beta1.ThirdPartyResourceList") } -func (m *APIVersion) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *APIVersion) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - return i, nil -} - -func (m *CPUTargetUtilization) Marshal() (data []byte, err error) { +func (m *APIVersion) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CPUTargetUtilization) MarshalTo(data []byte) (int, error) { +func (m *APIVersion) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.TargetPercentage)) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) return i, nil } -func (m *CustomMetricCurrentStatus) Marshal() (data []byte, err error) { +func (m *CustomMetricCurrentStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CustomMetricCurrentStatus) MarshalTo(data []byte) (int, error) { +func (m *CustomMetricCurrentStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.CurrentValue.Size())) - n1, err := m.CurrentValue.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentValue.Size())) + n1, err := m.CurrentValue.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -559,27 +473,27 @@ func (m *CustomMetricCurrentStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CustomMetricCurrentStatusList) Marshal() (data []byte, err error) { +func (m *CustomMetricCurrentStatusList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CustomMetricCurrentStatusList) MarshalTo(data []byte) (int, error) { +func (m *CustomMetricCurrentStatusList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -589,29 +503,29 @@ func (m *CustomMetricCurrentStatusList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CustomMetricTarget) Marshal() (data []byte, err error) { +func (m *CustomMetricTarget) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CustomMetricTarget) MarshalTo(data []byte) (int, error) { +func (m *CustomMetricTarget) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.TargetValue.Size())) - n2, err := m.TargetValue.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.TargetValue.Size())) + n2, err := m.TargetValue.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -619,27 +533,27 @@ func (m *CustomMetricTarget) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *CustomMetricTargetList) Marshal() (data []byte, err error) { +func (m *CustomMetricTargetList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *CustomMetricTargetList) MarshalTo(data []byte) (int, error) { +func (m *CustomMetricTargetList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -649,41 +563,41 @@ func (m *CustomMetricTargetList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *DaemonSet) Marshal() (data []byte, err error) { +func (m *DaemonSet) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DaemonSet) MarshalTo(data []byte) (int, error) { +func (m *DaemonSet) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n3, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n3, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n3 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n4, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n4, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n5, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n5, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -691,35 +605,35 @@ func (m *DaemonSet) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *DaemonSetList) Marshal() (data []byte, err error) { +func (m *DaemonSetList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DaemonSetList) MarshalTo(data []byte) (int, error) { +func (m *DaemonSetList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n6, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n6 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -729,193 +643,261 @@ func (m *DaemonSetList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *DaemonSetSpec) Marshal() (data []byte, err error) { +func (m *DaemonSetSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DaemonSetSpec) MarshalTo(data []byte) (int, error) { +func (m *DaemonSetSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Selector != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n7, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n7, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n8, err := m.Template.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n8, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n8 + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.UpdateStrategy.Size())) + n9, err := m.UpdateStrategy.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + dAtA[i] = 0x20 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) + dAtA[i] = 0x28 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.TemplateGeneration)) + if m.RevisionHistoryLimit != nil { + dAtA[i] = 0x30 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.RevisionHistoryLimit)) + } return i, nil } -func (m *DaemonSetStatus) Marshal() (data []byte, err error) { +func (m *DaemonSetStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DaemonSetStatus) MarshalTo(data []byte) (int, error) { +func (m *DaemonSetStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentNumberScheduled)) + dAtA[i] = 0x10 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NumberMisscheduled)) + dAtA[i] = 0x18 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.DesiredNumberScheduled)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.CurrentNumberScheduled)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.NumberReady)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.NumberMisscheduled)) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.ObservedGeneration)) + dAtA[i] = 0x30 i++ - i = encodeVarintGenerated(data, i, uint64(m.DesiredNumberScheduled)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.UpdatedNumberScheduled)) + dAtA[i] = 0x38 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NumberAvailable)) + dAtA[i] = 0x40 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NumberUnavailable)) + if m.CollisionCount != nil { + dAtA[i] = 0x48 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.CollisionCount)) + } + return i, nil +} + +func (m *DaemonSetUpdateStrategy) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *DaemonSetUpdateStrategy) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.NumberReady)) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + if m.RollingUpdate != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RollingUpdate.Size())) + n10, err := m.RollingUpdate.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + } return i, nil } -func (m *Deployment) Marshal() (data []byte, err error) { +func (m *Deployment) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Deployment) MarshalTo(data []byte) (int, error) { +func (m *Deployment) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n9, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n11, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n9 - data[i] = 0x12 + i += n11 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n10, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n12, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n10 - data[i] = 0x1a + i += n12 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n11, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n13, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n11 + i += n13 return i, nil } -func (m *DeploymentCondition) Marshal() (data []byte, err error) { +func (m *DeploymentCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeploymentCondition) MarshalTo(data []byte) (int, error) { +func (m *DeploymentCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - data[i] = 0x32 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(m.LastUpdateTime.Size())) - n12, err := m.LastUpdateTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastUpdateTime.Size())) + n14, err := m.LastUpdateTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n12 - data[i] = 0x3a + i += n14 + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n13, err := m.LastTransitionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n15, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n13 + i += n15 return i, nil } -func (m *DeploymentList) Marshal() (data []byte, err error) { +func (m *DeploymentList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeploymentList) MarshalTo(data []byte) (int, error) { +func (m *DeploymentList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n14, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n16, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n14 + i += n16 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -925,269 +907,248 @@ func (m *DeploymentList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *DeploymentRollback) Marshal() (data []byte, err error) { +func (m *DeploymentRollback) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeploymentRollback) MarshalTo(data []byte) (int, error) { +func (m *DeploymentRollback) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) if len(m.UpdatedAnnotations) > 0 { + keysForUpdatedAnnotations := make([]string, 0, len(m.UpdatedAnnotations)) for k := range m.UpdatedAnnotations { - data[i] = 0x12 + keysForUpdatedAnnotations = append(keysForUpdatedAnnotations, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForUpdatedAnnotations) + for _, k := range keysForUpdatedAnnotations { + dAtA[i] = 0x12 i++ - v := m.UpdatedAnnotations[k] + v := m.UpdatedAnnotations[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.RollbackTo.Size())) - n15, err := m.RollbackTo.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) + n17, err := m.RollbackTo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n15 + i += n17 return i, nil } -func (m *DeploymentSpec) Marshal() (data []byte, err error) { +func (m *DeploymentSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeploymentSpec) MarshalTo(data []byte) (int, error) { +func (m *DeploymentSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Replicas != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Replicas)) } if m.Selector != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n16, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n18, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n16 + i += n18 } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n17, err := m.Template.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n19, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n17 - data[i] = 0x22 + i += n19 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(m.Strategy.Size())) - n18, err := m.Strategy.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Strategy.Size())) + n20, err := m.Strategy.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n18 - data[i] = 0x28 + i += n20 + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.MinReadySeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) if m.RevisionHistoryLimit != nil { - data[i] = 0x30 + dAtA[i] = 0x30 i++ - i = encodeVarintGenerated(data, i, uint64(*m.RevisionHistoryLimit)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.RevisionHistoryLimit)) } - data[i] = 0x38 + dAtA[i] = 0x38 i++ if m.Paused { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if m.RollbackTo != nil { - data[i] = 0x42 + dAtA[i] = 0x42 i++ - i = encodeVarintGenerated(data, i, uint64(m.RollbackTo.Size())) - n19, err := m.RollbackTo.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RollbackTo.Size())) + n21, err := m.RollbackTo.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n19 + i += n21 } if m.ProgressDeadlineSeconds != nil { - data[i] = 0x48 + dAtA[i] = 0x48 i++ - i = encodeVarintGenerated(data, i, uint64(*m.ProgressDeadlineSeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.ProgressDeadlineSeconds)) } return i, nil } -func (m *DeploymentStatus) Marshal() (data []byte, err error) { +func (m *DeploymentStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeploymentStatus) MarshalTo(data []byte) (int, error) { +func (m *DeploymentStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.ObservedGeneration)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.ObservedGeneration)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.UpdatedReplicas)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.UpdatedReplicas)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.AvailableReplicas)) - data[i] = 0x28 + i = encodeVarintGenerated(dAtA, i, uint64(m.AvailableReplicas)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.UnavailableReplicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.UnavailableReplicas)) if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } + dAtA[i] = 0x38 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ReadyReplicas)) + if m.CollisionCount != nil { + dAtA[i] = 0x40 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(*m.CollisionCount)) + } return i, nil } -func (m *DeploymentStrategy) Marshal() (data []byte, err error) { +func (m *DeploymentStrategy) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *DeploymentStrategy) MarshalTo(data []byte) (int, error) { +func (m *DeploymentStrategy) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) if m.RollingUpdate != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.RollingUpdate.Size())) - n20, err := m.RollingUpdate.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RollingUpdate.Size())) + n22, err := m.RollingUpdate.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n20 - } - return i, nil -} - -func (m *ExportOptions) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *ExportOptions) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0x8 - i++ - if m.Export { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - data[i] = 0x10 - i++ - if m.Exact { - data[i] = 1 - } else { - data[i] = 0 + i += n22 } - i++ return i, nil } -func (m *FSGroupStrategyOptions) Marshal() (data []byte, err error) { +func (m *FSGroupStrategyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *FSGroupStrategyOptions) MarshalTo(data []byte) (int, error) { +func (m *FSGroupStrategyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Rule))) - i += copy(data[i:], m.Rule) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Rule))) + i += copy(dAtA[i:], m.Rule) if len(m.Ranges) > 0 { for _, msg := range m.Ranges { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1197,137 +1158,57 @@ func (m *FSGroupStrategyOptions) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *HTTPIngressPath) Marshal() (data []byte, err error) { +func (m *HTTPIngressPath) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HTTPIngressPath) MarshalTo(data []byte) (int, error) { +func (m *HTTPIngressPath) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Path))) - i += copy(data[i:], m.Path) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Path))) + i += copy(dAtA[i:], m.Path) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Backend.Size())) - n21, err := m.Backend.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Backend.Size())) + n23, err := m.Backend.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n21 + i += n23 return i, nil } -func (m *HTTPIngressRuleValue) Marshal() (data []byte, err error) { +func (m *HTTPIngressRuleValue) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HTTPIngressRuleValue) MarshalTo(data []byte) (int, error) { +func (m *HTTPIngressRuleValue) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Paths) > 0 { for _, msg := range m.Paths { - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *HorizontalPodAutoscaler) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *HorizontalPodAutoscaler) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n22, err := m.ObjectMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n22 - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n23, err := m.Spec.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n23 - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n24, err := m.Status.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n24 - return i, nil -} - -func (m *HorizontalPodAutoscalerList) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *HorizontalPodAutoscalerList) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n25, err := m.ListMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n25 - if len(m.Items) > 0 { - for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1337,243 +1218,155 @@ func (m *HorizontalPodAutoscalerList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *HorizontalPodAutoscalerSpec) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *HorizontalPodAutoscalerSpec) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ScaleRef.Size())) - n26, err := m.ScaleRef.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n26 - if m.MinReplicas != nil { - data[i] = 0x10 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.MinReplicas)) - } - data[i] = 0x18 - i++ - i = encodeVarintGenerated(data, i, uint64(m.MaxReplicas)) - if m.CPUUtilization != nil { - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(m.CPUUtilization.Size())) - n27, err := m.CPUUtilization.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n27 - } - return i, nil -} - -func (m *HorizontalPodAutoscalerStatus) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *HorizontalPodAutoscalerStatus) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if m.ObservedGeneration != nil { - data[i] = 0x8 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.ObservedGeneration)) - } - if m.LastScaleTime != nil { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.LastScaleTime.Size())) - n28, err := m.LastScaleTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n28 - } - data[i] = 0x18 - i++ - i = encodeVarintGenerated(data, i, uint64(m.CurrentReplicas)) - data[i] = 0x20 - i++ - i = encodeVarintGenerated(data, i, uint64(m.DesiredReplicas)) - if m.CurrentCPUUtilizationPercentage != nil { - data[i] = 0x28 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.CurrentCPUUtilizationPercentage)) - } - return i, nil -} - -func (m *HostPortRange) Marshal() (data []byte, err error) { +func (m *HostPortRange) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *HostPortRange) MarshalTo(data []byte) (int, error) { +func (m *HostPortRange) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Min)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.Min)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.Max)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Max)) return i, nil } -func (m *IDRange) Marshal() (data []byte, err error) { +func (m *IDRange) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IDRange) MarshalTo(data []byte) (int, error) { +func (m *IDRange) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Min)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.Min)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.Max)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Max)) return i, nil } -func (m *Ingress) Marshal() (data []byte, err error) { +func (m *Ingress) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Ingress) MarshalTo(data []byte) (int, error) { +func (m *Ingress) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n29, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n24, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n29 - data[i] = 0x12 + i += n24 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n30, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n25, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n30 - data[i] = 0x1a + i += n25 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n31, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n26, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n31 + i += n26 return i, nil } -func (m *IngressBackend) Marshal() (data []byte, err error) { +func (m *IngressBackend) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressBackend) MarshalTo(data []byte) (int, error) { +func (m *IngressBackend) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.ServiceName))) - i += copy(data[i:], m.ServiceName) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.ServiceName))) + i += copy(dAtA[i:], m.ServiceName) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.ServicePort.Size())) - n32, err := m.ServicePort.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ServicePort.Size())) + n27, err := m.ServicePort.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n32 + i += n27 return i, nil } -func (m *IngressList) Marshal() (data []byte, err error) { +func (m *IngressList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressList) MarshalTo(data []byte) (int, error) { +func (m *IngressList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n33, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n28, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n33 + i += n28 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1583,95 +1376,95 @@ func (m *IngressList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *IngressRule) Marshal() (data []byte, err error) { +func (m *IngressRule) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressRule) MarshalTo(data []byte) (int, error) { +func (m *IngressRule) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Host))) - i += copy(data[i:], m.Host) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Host))) + i += copy(dAtA[i:], m.Host) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.IngressRuleValue.Size())) - n34, err := m.IngressRuleValue.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.IngressRuleValue.Size())) + n29, err := m.IngressRuleValue.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n34 + i += n29 return i, nil } -func (m *IngressRuleValue) Marshal() (data []byte, err error) { +func (m *IngressRuleValue) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressRuleValue) MarshalTo(data []byte) (int, error) { +func (m *IngressRuleValue) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.HTTP != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.HTTP.Size())) - n35, err := m.HTTP.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.HTTP.Size())) + n30, err := m.HTTP.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n35 + i += n30 } return i, nil } -func (m *IngressSpec) Marshal() (data []byte, err error) { +func (m *IngressSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressSpec) MarshalTo(data []byte) (int, error) { +func (m *IngressSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Backend != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Backend.Size())) - n36, err := m.Backend.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Backend.Size())) + n31, err := m.Backend.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n36 + i += n31 } if len(m.TLS) > 0 { for _, msg := range m.TLS { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1680,10 +1473,10 @@ func (m *IngressSpec) MarshalTo(data []byte) (int, error) { } if len(m.Rules) > 0 { for _, msg := range m.Rules { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -1693,386 +1486,136 @@ func (m *IngressSpec) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *IngressStatus) Marshal() (data []byte, err error) { +func (m *IngressStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressStatus) MarshalTo(data []byte) (int, error) { +func (m *IngressStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.LoadBalancer.Size())) - n37, err := m.LoadBalancer.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LoadBalancer.Size())) + n32, err := m.LoadBalancer.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n37 + i += n32 return i, nil } -func (m *IngressTLS) Marshal() (data []byte, err error) { +func (m *IngressTLS) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *IngressTLS) MarshalTo(data []byte) (int, error) { +func (m *IngressTLS) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Hosts) > 0 { for _, s := range m.Hosts { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.SecretName))) - i += copy(data[i:], m.SecretName) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.SecretName))) + i += copy(dAtA[i:], m.SecretName) return i, nil } -func (m *Job) Marshal() (data []byte, err error) { +func (m *NetworkPolicy) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Job) MarshalTo(data []byte) (int, error) { +func (m *NetworkPolicy) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n38, err := m.ObjectMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n38 - data[i] = 0x12 + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n39, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n33, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n39 - data[i] = 0x1a + i += n33 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n40, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n34, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n40 + i += n34 return i, nil } -func (m *JobCondition) Marshal() (data []byte, err error) { +func (m *NetworkPolicyIngressRule) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *JobCondition) MarshalTo(data []byte) (int, error) { +func (m *NetworkPolicyIngressRule) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.LastProbeTime.Size())) - n41, err := m.LastProbeTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n41 - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n42, err := m.LastTransitionTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n42 - data[i] = 0x2a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x32 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) - return i, nil -} - -func (m *JobList) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobList) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n43, err := m.ListMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n43 - if len(m.Items) > 0 { - for _, msg := range m.Items { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - return i, nil -} - -func (m *JobSpec) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobSpec) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if m.Parallelism != nil { - data[i] = 0x8 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.Parallelism)) - } - if m.Completions != nil { - data[i] = 0x10 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.Completions)) - } - if m.ActiveDeadlineSeconds != nil { - data[i] = 0x18 - i++ - i = encodeVarintGenerated(data, i, uint64(*m.ActiveDeadlineSeconds)) - } - if m.Selector != nil { - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n44, err := m.Selector.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n44 - } - if m.AutoSelector != nil { - data[i] = 0x28 - i++ - if *m.AutoSelector { - data[i] = 1 - } else { - data[i] = 0 - } - i++ - } - data[i] = 0x32 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n45, err := m.Template.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n45 - return i, nil -} - -func (m *JobStatus) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *JobStatus) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Conditions) > 0 { - for _, msg := range m.Conditions { - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } - } - if m.StartTime != nil { - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.StartTime.Size())) - n46, err := m.StartTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n46 - } - if m.CompletionTime != nil { - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(m.CompletionTime.Size())) - n47, err := m.CompletionTime.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n47 - } - data[i] = 0x20 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Active)) - data[i] = 0x28 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Succeeded)) - data[i] = 0x30 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Failed)) - return i, nil -} - -func (m *NetworkPolicy) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *NetworkPolicy) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n48, err := m.ObjectMeta.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n48 - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n49, err := m.Spec.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n49 - return i, nil -} - -func (m *NetworkPolicyIngressRule) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *NetworkPolicyIngressRule) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - if len(m.Ports) > 0 { - for _, msg := range m.Ports { - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n - } + if len(m.Ports) > 0 { + for _, msg := range m.Ports { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } } if len(m.From) > 0 { for _, msg := range m.From { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2082,35 +1625,35 @@ func (m *NetworkPolicyIngressRule) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NetworkPolicyList) Marshal() (data []byte, err error) { +func (m *NetworkPolicyList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NetworkPolicyList) MarshalTo(data []byte) (int, error) { +func (m *NetworkPolicyList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n50, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n35, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n50 + i += n35 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2120,107 +1663,107 @@ func (m *NetworkPolicyList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *NetworkPolicyPeer) Marshal() (data []byte, err error) { +func (m *NetworkPolicyPeer) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NetworkPolicyPeer) MarshalTo(data []byte) (int, error) { +func (m *NetworkPolicyPeer) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.PodSelector != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.PodSelector.Size())) - n51, err := m.PodSelector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n36, err := m.PodSelector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n51 + i += n36 } if m.NamespaceSelector != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.NamespaceSelector.Size())) - n52, err := m.NamespaceSelector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.NamespaceSelector.Size())) + n37, err := m.NamespaceSelector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n52 + i += n37 } return i, nil } -func (m *NetworkPolicyPort) Marshal() (data []byte, err error) { +func (m *NetworkPolicyPort) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NetworkPolicyPort) MarshalTo(data []byte) (int, error) { +func (m *NetworkPolicyPort) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Protocol != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(*m.Protocol))) - i += copy(data[i:], *m.Protocol) + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Protocol))) + i += copy(dAtA[i:], *m.Protocol) } if m.Port != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Port.Size())) - n53, err := m.Port.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) + n38, err := m.Port.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n53 + i += n38 } return i, nil } -func (m *NetworkPolicySpec) Marshal() (data []byte, err error) { +func (m *NetworkPolicySpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *NetworkPolicySpec) MarshalTo(data []byte) (int, error) { +func (m *NetworkPolicySpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.PodSelector.Size())) - n54, err := m.PodSelector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n39, err := m.PodSelector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n54 + i += n39 if len(m.Ingress) > 0 { for _, msg := range m.Ingress { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2230,69 +1773,69 @@ func (m *NetworkPolicySpec) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodSecurityPolicy) Marshal() (data []byte, err error) { +func (m *PodSecurityPolicy) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodSecurityPolicy) MarshalTo(data []byte) (int, error) { +func (m *PodSecurityPolicy) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n55, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n40, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n55 - data[i] = 0x12 + i += n40 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n56, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n41, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n56 + i += n41 return i, nil } -func (m *PodSecurityPolicyList) Marshal() (data []byte, err error) { +func (m *PodSecurityPolicyList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodSecurityPolicyList) MarshalTo(data []byte) (int, error) { +func (m *PodSecurityPolicyList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n57, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n42, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n57 + i += n42 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2302,281 +1845,281 @@ func (m *PodSecurityPolicyList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodSecurityPolicySpec) Marshal() (data []byte, err error) { +func (m *PodSecurityPolicySpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodSecurityPolicySpec) MarshalTo(data []byte) (int, error) { +func (m *PodSecurityPolicySpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ if m.Privileged { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if len(m.DefaultAddCapabilities) > 0 { for _, s := range m.DefaultAddCapabilities { - data[i] = 0x12 + dAtA[i] = 0x12 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.RequiredDropCapabilities) > 0 { for _, s := range m.RequiredDropCapabilities { - data[i] = 0x1a + dAtA[i] = 0x1a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.AllowedCapabilities) > 0 { for _, s := range m.AllowedCapabilities { - data[i] = 0x22 + dAtA[i] = 0x22 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Volumes) > 0 { for _, s := range m.Volumes { - data[i] = 0x2a + dAtA[i] = 0x2a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x30 + dAtA[i] = 0x30 i++ if m.HostNetwork { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ if len(m.HostPorts) > 0 { for _, msg := range m.HostPorts { - data[i] = 0x3a + dAtA[i] = 0x3a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x40 + dAtA[i] = 0x40 i++ if m.HostPID { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x48 + dAtA[i] = 0x48 i++ if m.HostIPC { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ - data[i] = 0x52 + dAtA[i] = 0x52 i++ - i = encodeVarintGenerated(data, i, uint64(m.SELinux.Size())) - n58, err := m.SELinux.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SELinux.Size())) + n43, err := m.SELinux.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n58 - data[i] = 0x5a + i += n43 + dAtA[i] = 0x5a i++ - i = encodeVarintGenerated(data, i, uint64(m.RunAsUser.Size())) - n59, err := m.RunAsUser.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RunAsUser.Size())) + n44, err := m.RunAsUser.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n59 - data[i] = 0x62 + i += n44 + dAtA[i] = 0x62 i++ - i = encodeVarintGenerated(data, i, uint64(m.SupplementalGroups.Size())) - n60, err := m.SupplementalGroups.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SupplementalGroups.Size())) + n45, err := m.SupplementalGroups.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n60 - data[i] = 0x6a + i += n45 + dAtA[i] = 0x6a i++ - i = encodeVarintGenerated(data, i, uint64(m.FSGroup.Size())) - n61, err := m.FSGroup.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.FSGroup.Size())) + n46, err := m.FSGroup.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n61 - data[i] = 0x70 + i += n46 + dAtA[i] = 0x70 i++ if m.ReadOnlyRootFilesystem { - data[i] = 1 + dAtA[i] = 1 } else { - data[i] = 0 + dAtA[i] = 0 } i++ return i, nil } -func (m *ReplicaSet) Marshal() (data []byte, err error) { +func (m *ReplicaSet) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicaSet) MarshalTo(data []byte) (int, error) { +func (m *ReplicaSet) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n62, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n47, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n62 - data[i] = 0x12 + i += n47 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n63, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n48, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n63 - data[i] = 0x1a + i += n48 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n64, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n49, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n64 + i += n49 return i, nil } -func (m *ReplicaSetCondition) Marshal() (data []byte, err error) { +func (m *ReplicaSetCondition) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicaSetCondition) MarshalTo(data []byte) (int, error) { +func (m *ReplicaSetCondition) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Type))) + i += copy(dAtA[i:], m.Type) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Status))) - i += copy(data[i:], m.Status) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Status))) + i += copy(dAtA[i:], m.Status) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.LastTransitionTime.Size())) - n65, err := m.LastTransitionTime.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.LastTransitionTime.Size())) + n50, err := m.LastTransitionTime.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n65 - data[i] = 0x22 + i += n50 + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Reason))) - i += copy(data[i:], m.Reason) - data[i] = 0x2a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Reason))) + i += copy(dAtA[i:], m.Reason) + dAtA[i] = 0x2a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Message))) - i += copy(data[i:], m.Message) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Message))) + i += copy(dAtA[i:], m.Message) return i, nil } -func (m *ReplicaSetList) Marshal() (data []byte, err error) { +func (m *ReplicaSetList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicaSetList) MarshalTo(data []byte) (int, error) { +func (m *ReplicaSetList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n66, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n51, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n66 + i += n51 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2586,86 +2129,86 @@ func (m *ReplicaSetList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ReplicaSetSpec) Marshal() (data []byte, err error) { +func (m *ReplicaSetSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicaSetSpec) MarshalTo(data []byte) (int, error) { +func (m *ReplicaSetSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.Replicas != nil { - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(*m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(*m.Replicas)) } if m.Selector != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n67, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n52, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n67 + i += n52 } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Template.Size())) - n68, err := m.Template.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Template.Size())) + n53, err := m.Template.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n68 - data[i] = 0x20 + i += n53 + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.MinReadySeconds)) + i = encodeVarintGenerated(dAtA, i, uint64(m.MinReadySeconds)) return i, nil } -func (m *ReplicaSetStatus) Marshal() (data []byte, err error) { +func (m *ReplicaSetStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicaSetStatus) MarshalTo(data []byte) (int, error) { +func (m *ReplicaSetStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) - data[i] = 0x10 + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) + dAtA[i] = 0x10 i++ - i = encodeVarintGenerated(data, i, uint64(m.FullyLabeledReplicas)) - data[i] = 0x18 + i = encodeVarintGenerated(dAtA, i, uint64(m.FullyLabeledReplicas)) + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.ObservedGeneration)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.ObservedGeneration)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.ReadyReplicas)) - data[i] = 0x28 + i = encodeVarintGenerated(dAtA, i, uint64(m.ReadyReplicas)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.AvailableReplicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.AvailableReplicas)) if len(m.Conditions) > 0 { for _, msg := range m.Conditions { - data[i] = 0x32 + dAtA[i] = 0x32 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2675,17 +2218,17 @@ func (m *ReplicaSetStatus) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ReplicationControllerDummy) Marshal() (data []byte, err error) { +func (m *ReplicationControllerDummy) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ReplicationControllerDummy) MarshalTo(data []byte) (int, error) { +func (m *ReplicationControllerDummy) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int @@ -2693,90 +2236,118 @@ func (m *ReplicationControllerDummy) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *RollbackConfig) Marshal() (data []byte, err error) { +func (m *RollbackConfig) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RollbackConfig) MarshalTo(data []byte) (int, error) { +func (m *RollbackConfig) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Revision)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Revision)) + return i, nil +} + +func (m *RollingUpdateDaemonSet) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RollingUpdateDaemonSet) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.MaxUnavailable != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxUnavailable.Size())) + n54, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n54 + } return i, nil } -func (m *RollingUpdateDeployment) Marshal() (data []byte, err error) { +func (m *RollingUpdateDeployment) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RollingUpdateDeployment) MarshalTo(data []byte) (int, error) { +func (m *RollingUpdateDeployment) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if m.MaxUnavailable != nil { - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.MaxUnavailable.Size())) - n69, err := m.MaxUnavailable.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxUnavailable.Size())) + n55, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n69 + i += n55 } if m.MaxSurge != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.MaxSurge.Size())) - n70, err := m.MaxSurge.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxSurge.Size())) + n56, err := m.MaxSurge.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n70 + i += n56 } return i, nil } -func (m *RunAsUserStrategyOptions) Marshal() (data []byte, err error) { +func (m *RunAsUserStrategyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RunAsUserStrategyOptions) MarshalTo(data []byte) (int, error) { +func (m *RunAsUserStrategyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Rule))) - i += copy(data[i:], m.Rule) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Rule))) + i += copy(dAtA[i:], m.Rule) if len(m.Ranges) > 0 { for _, msg := range m.Ranges { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2786,202 +2357,173 @@ func (m *RunAsUserStrategyOptions) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *SELinuxStrategyOptions) Marshal() (data []byte, err error) { +func (m *SELinuxStrategyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SELinuxStrategyOptions) MarshalTo(data []byte) (int, error) { +func (m *SELinuxStrategyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Rule))) - i += copy(data[i:], m.Rule) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Rule))) + i += copy(dAtA[i:], m.Rule) if m.SELinuxOptions != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.SELinuxOptions.Size())) - n71, err := m.SELinuxOptions.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.SELinuxOptions.Size())) + n57, err := m.SELinuxOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n71 + i += n57 } return i, nil } -func (m *Scale) Marshal() (data []byte, err error) { +func (m *Scale) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Scale) MarshalTo(data []byte) (int, error) { +func (m *Scale) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n72, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n58, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n72 - data[i] = 0x12 + i += n58 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n73, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n59, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n73 - data[i] = 0x1a + i += n59 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n74, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n60, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n74 + i += n60 return i, nil } -func (m *ScaleSpec) Marshal() (data []byte, err error) { +func (m *ScaleSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ScaleSpec) MarshalTo(data []byte) (int, error) { +func (m *ScaleSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) return i, nil } -func (m *ScaleStatus) Marshal() (data []byte, err error) { +func (m *ScaleStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ScaleStatus) MarshalTo(data []byte) (int, error) { +func (m *ScaleStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.Replicas)) + i = encodeVarintGenerated(dAtA, i, uint64(m.Replicas)) if len(m.Selector) > 0 { + keysForSelector := make([]string, 0, len(m.Selector)) for k := range m.Selector { - data[i] = 0x12 + keysForSelector = append(keysForSelector, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForSelector) + for _, k := range keysForSelector { + dAtA[i] = 0x12 i++ - v := m.Selector[k] + v := m.Selector[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.TargetSelector))) - i += copy(data[i:], m.TargetSelector) - return i, nil -} - -func (m *SubresourceReference) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *SubresourceReference) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x12 + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x1a - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - data[i] = 0x22 - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Subresource))) - i += copy(data[i:], m.Subresource) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.TargetSelector))) + i += copy(dAtA[i:], m.TargetSelector) return i, nil } -func (m *SupplementalGroupsStrategyOptions) Marshal() (data []byte, err error) { +func (m *SupplementalGroupsStrategyOptions) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *SupplementalGroupsStrategyOptions) MarshalTo(data []byte) (int, error) { +func (m *SupplementalGroupsStrategyOptions) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Rule))) - i += copy(data[i:], m.Rule) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Rule))) + i += copy(dAtA[i:], m.Rule) if len(m.Ranges) > 0 { for _, msg := range m.Ranges { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -2991,39 +2533,39 @@ func (m *SupplementalGroupsStrategyOptions) MarshalTo(data []byte) (int, error) return i, nil } -func (m *ThirdPartyResource) Marshal() (data []byte, err error) { +func (m *ThirdPartyResource) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ThirdPartyResource) MarshalTo(data []byte) (int, error) { +func (m *ThirdPartyResource) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n75, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n61, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n75 - data[i] = 0x12 + i += n61 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Description))) - i += copy(data[i:], m.Description) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Description))) + i += copy(dAtA[i:], m.Description) if len(m.Versions) > 0 { for _, msg := range m.Versions { - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3033,67 +2575,67 @@ func (m *ThirdPartyResource) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ThirdPartyResourceData) Marshal() (data []byte, err error) { +func (m *ThirdPartyResourceData) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ThirdPartyResourceData) MarshalTo(data []byte) (int, error) { +func (m *ThirdPartyResourceData) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n76, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n62, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n76 + i += n62 if m.Data != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Data))) - i += copy(data[i:], m.Data) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Data))) + i += copy(dAtA[i:], m.Data) } return i, nil } -func (m *ThirdPartyResourceDataList) Marshal() (data []byte, err error) { +func (m *ThirdPartyResourceDataList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ThirdPartyResourceDataList) MarshalTo(data []byte) (int, error) { +func (m *ThirdPartyResourceDataList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n77, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n63, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n77 + i += n63 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3103,35 +2645,35 @@ func (m *ThirdPartyResourceDataList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ThirdPartyResourceList) Marshal() (data []byte, err error) { +func (m *ThirdPartyResourceList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ThirdPartyResourceList) MarshalTo(data []byte) (int, error) { +func (m *ThirdPartyResourceList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n78, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n64, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n78 + i += n64 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -3141,31 +2683,31 @@ func (m *ThirdPartyResourceList) MarshalTo(data []byte) (int, error) { return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *APIVersion) Size() (n int) { @@ -3176,13 +2718,6 @@ func (m *APIVersion) Size() (n int) { return n } -func (m *CPUTargetUtilization) Size() (n int) { - var l int - _ = l - n += 1 + sovGenerated(uint64(m.TargetPercentage)) - return n -} - func (m *CustomMetricCurrentStatus) Size() (n int) { var l int _ = l @@ -3262,6 +2797,13 @@ func (m *DaemonSetSpec) Size() (n int) { } l = m.Template.Size() n += 1 + l + sovGenerated(uint64(l)) + l = m.UpdateStrategy.Size() + n += 1 + l + sovGenerated(uint64(l)) + n += 1 + sovGenerated(uint64(m.MinReadySeconds)) + n += 1 + sovGenerated(uint64(m.TemplateGeneration)) + if m.RevisionHistoryLimit != nil { + n += 1 + sovGenerated(uint64(*m.RevisionHistoryLimit)) + } return n } @@ -3272,6 +2814,25 @@ func (m *DaemonSetStatus) Size() (n int) { n += 1 + sovGenerated(uint64(m.NumberMisscheduled)) n += 1 + sovGenerated(uint64(m.DesiredNumberScheduled)) n += 1 + sovGenerated(uint64(m.NumberReady)) + n += 1 + sovGenerated(uint64(m.ObservedGeneration)) + n += 1 + sovGenerated(uint64(m.UpdatedNumberScheduled)) + n += 1 + sovGenerated(uint64(m.NumberAvailable)) + n += 1 + sovGenerated(uint64(m.NumberUnavailable)) + if m.CollisionCount != nil { + n += 1 + sovGenerated(uint64(*m.CollisionCount)) + } + return n +} + +func (m *DaemonSetUpdateStrategy) Size() (n int) { + var l int + _ = l + l = len(m.Type) + n += 1 + l + sovGenerated(uint64(l)) + if m.RollingUpdate != nil { + l = m.RollingUpdate.Size() + n += 1 + l + sovGenerated(uint64(l)) + } return n } @@ -3380,6 +2941,10 @@ func (m *DeploymentStatus) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) } } + n += 1 + sovGenerated(uint64(m.ReadyReplicas)) + if m.CollisionCount != nil { + n += 1 + sovGenerated(uint64(*m.CollisionCount)) + } return n } @@ -3395,14 +2960,6 @@ func (m *DeploymentStrategy) Size() (n int) { return n } -func (m *ExportOptions) Size() (n int) { - var l int - _ = l - n += 2 - n += 2 - return n -} - func (m *FSGroupStrategyOptions) Size() (n int) { var l int _ = l @@ -3439,7 +2996,23 @@ func (m *HTTPIngressRuleValue) Size() (n int) { return n } -func (m *HorizontalPodAutoscaler) Size() (n int) { +func (m *HostPortRange) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Min)) + n += 1 + sovGenerated(uint64(m.Max)) + return n +} + +func (m *IDRange) Size() (n int) { + var l int + _ = l + n += 1 + sovGenerated(uint64(m.Min)) + n += 1 + sovGenerated(uint64(m.Max)) + return n +} + +func (m *Ingress) Size() (n int) { var l int _ = l l = m.ObjectMeta.Size() @@ -3451,83 +3024,7 @@ func (m *HorizontalPodAutoscaler) Size() (n int) { return n } -func (m *HorizontalPodAutoscalerList) Size() (n int) { - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *HorizontalPodAutoscalerSpec) Size() (n int) { - var l int - _ = l - l = m.ScaleRef.Size() - n += 1 + l + sovGenerated(uint64(l)) - if m.MinReplicas != nil { - n += 1 + sovGenerated(uint64(*m.MinReplicas)) - } - n += 1 + sovGenerated(uint64(m.MaxReplicas)) - if m.CPUUtilization != nil { - l = m.CPUUtilization.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - return n -} - -func (m *HorizontalPodAutoscalerStatus) Size() (n int) { - var l int - _ = l - if m.ObservedGeneration != nil { - n += 1 + sovGenerated(uint64(*m.ObservedGeneration)) - } - if m.LastScaleTime != nil { - l = m.LastScaleTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - n += 1 + sovGenerated(uint64(m.CurrentReplicas)) - n += 1 + sovGenerated(uint64(m.DesiredReplicas)) - if m.CurrentCPUUtilizationPercentage != nil { - n += 1 + sovGenerated(uint64(*m.CurrentCPUUtilizationPercentage)) - } - return n -} - -func (m *HostPortRange) Size() (n int) { - var l int - _ = l - n += 1 + sovGenerated(uint64(m.Min)) - n += 1 + sovGenerated(uint64(m.Max)) - return n -} - -func (m *IDRange) Size() (n int) { - var l int - _ = l - n += 1 + sovGenerated(uint64(m.Min)) - n += 1 + sovGenerated(uint64(m.Max)) - return n -} - -func (m *Ingress) Size() (n int) { - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *IngressBackend) Size() (n int) { +func (m *IngressBackend) Size() (n int) { var l int _ = l l = len(m.ServiceName) @@ -3615,97 +3112,6 @@ func (m *IngressTLS) Size() (n int) { return n } -func (m *Job) Size() (n int) { - var l int - _ = l - l = m.ObjectMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Spec.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.Status.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *JobCondition) Size() (n int) { - var l int - _ = l - l = len(m.Type) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Status) - n += 1 + l + sovGenerated(uint64(l)) - l = m.LastProbeTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = m.LastTransitionTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Reason) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Message) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *JobList) Size() (n int) { - var l int - _ = l - l = m.ListMeta.Size() - n += 1 + l + sovGenerated(uint64(l)) - if len(m.Items) > 0 { - for _, e := range m.Items { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - return n -} - -func (m *JobSpec) Size() (n int) { - var l int - _ = l - if m.Parallelism != nil { - n += 1 + sovGenerated(uint64(*m.Parallelism)) - } - if m.Completions != nil { - n += 1 + sovGenerated(uint64(*m.Completions)) - } - if m.ActiveDeadlineSeconds != nil { - n += 1 + sovGenerated(uint64(*m.ActiveDeadlineSeconds)) - } - if m.Selector != nil { - l = m.Selector.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - if m.AutoSelector != nil { - n += 2 - } - l = m.Template.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func (m *JobStatus) Size() (n int) { - var l int - _ = l - if len(m.Conditions) > 0 { - for _, e := range m.Conditions { - l = e.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - } - if m.StartTime != nil { - l = m.StartTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - if m.CompletionTime != nil { - l = m.CompletionTime.Size() - n += 1 + l + sovGenerated(uint64(l)) - } - n += 1 + sovGenerated(uint64(m.Active)) - n += 1 + sovGenerated(uint64(m.Succeeded)) - n += 1 + sovGenerated(uint64(m.Failed)) - return n -} - func (m *NetworkPolicy) Size() (n int) { var l int _ = l @@ -3951,6 +3357,16 @@ func (m *RollbackConfig) Size() (n int) { return n } +func (m *RollingUpdateDaemonSet) Size() (n int) { + var l int + _ = l + if m.MaxUnavailable != nil { + l = m.MaxUnavailable.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + func (m *RollingUpdateDeployment) Size() (n int) { var l int _ = l @@ -4027,20 +3443,6 @@ func (m *ScaleStatus) Size() (n int) { return n } -func (m *SubresourceReference) Size() (n int) { - var l int - _ = l - l = len(m.Kind) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Name) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.APIVersion) - n += 1 + l + sovGenerated(uint64(l)) - l = len(m.Subresource) - n += 1 + l + sovGenerated(uint64(l)) - return n -} - func (m *SupplementalGroupsStrategyOptions) Size() (n int) { var l int _ = l @@ -4134,23 +3536,13 @@ func (this *APIVersion) String() string { }, "") return s } -func (this *CPUTargetUtilization) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&CPUTargetUtilization{`, - `TargetPercentage:` + fmt.Sprintf("%v", this.TargetPercentage) + `,`, - `}`, - }, "") - return s -} func (this *CustomMetricCurrentStatus) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&CustomMetricCurrentStatus{`, `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `CurrentValue:` + strings.Replace(strings.Replace(this.CurrentValue.String(), "Quantity", "k8s_io_kubernetes_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `CurrentValue:` + strings.Replace(strings.Replace(this.CurrentValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -4171,7 +3563,7 @@ func (this *CustomMetricTarget) String() string { } s := strings.Join([]string{`&CustomMetricTarget{`, `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `TargetValue:` + strings.Replace(strings.Replace(this.TargetValue.String(), "Quantity", "k8s_io_kubernetes_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, + `TargetValue:` + strings.Replace(strings.Replace(this.TargetValue.String(), "Quantity", "k8s_io_apimachinery_pkg_api_resource.Quantity", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -4191,7 +3583,7 @@ func (this *DaemonSet) String() string { return "nil" } s := strings.Join([]string{`&DaemonSet{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DaemonSetSpec", "DaemonSetSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DaemonSetStatus", "DaemonSetStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -4203,7 +3595,7 @@ func (this *DaemonSetList) String() string { return "nil" } s := strings.Join([]string{`&DaemonSetList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "DaemonSet", "DaemonSet", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4214,8 +3606,12 @@ func (this *DaemonSetSpec) String() string { return "nil" } s := strings.Join([]string{`&DaemonSetSpec{`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, + `UpdateStrategy:` + strings.Replace(strings.Replace(this.UpdateStrategy.String(), "DaemonSetUpdateStrategy", "DaemonSetUpdateStrategy", 1), `&`, ``, 1) + `,`, + `MinReadySeconds:` + fmt.Sprintf("%v", this.MinReadySeconds) + `,`, + `TemplateGeneration:` + fmt.Sprintf("%v", this.TemplateGeneration) + `,`, + `RevisionHistoryLimit:` + valueToStringGenerated(this.RevisionHistoryLimit) + `,`, `}`, }, "") return s @@ -4229,6 +3625,22 @@ func (this *DaemonSetStatus) String() string { `NumberMisscheduled:` + fmt.Sprintf("%v", this.NumberMisscheduled) + `,`, `DesiredNumberScheduled:` + fmt.Sprintf("%v", this.DesiredNumberScheduled) + `,`, `NumberReady:` + fmt.Sprintf("%v", this.NumberReady) + `,`, + `ObservedGeneration:` + fmt.Sprintf("%v", this.ObservedGeneration) + `,`, + `UpdatedNumberScheduled:` + fmt.Sprintf("%v", this.UpdatedNumberScheduled) + `,`, + `NumberAvailable:` + fmt.Sprintf("%v", this.NumberAvailable) + `,`, + `NumberUnavailable:` + fmt.Sprintf("%v", this.NumberUnavailable) + `,`, + `CollisionCount:` + valueToStringGenerated(this.CollisionCount) + `,`, + `}`, + }, "") + return s +} +func (this *DaemonSetUpdateStrategy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&DaemonSetUpdateStrategy{`, + `Type:` + fmt.Sprintf("%v", this.Type) + `,`, + `RollingUpdate:` + strings.Replace(fmt.Sprintf("%v", this.RollingUpdate), "RollingUpdateDaemonSet", "RollingUpdateDaemonSet", 1) + `,`, `}`, }, "") return s @@ -4238,7 +3650,7 @@ func (this *Deployment) String() string { return "nil" } s := strings.Join([]string{`&Deployment{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "DeploymentSpec", "DeploymentSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "DeploymentStatus", "DeploymentStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -4254,8 +3666,8 @@ func (this *DeploymentCondition) String() string { `Status:` + fmt.Sprintf("%v", this.Status) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `LastUpdateTime:` + strings.Replace(strings.Replace(this.LastUpdateTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastUpdateTime:` + strings.Replace(strings.Replace(this.LastUpdateTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -4265,7 +3677,7 @@ func (this *DeploymentList) String() string { return "nil" } s := strings.Join([]string{`&DeploymentList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Deployment", "Deployment", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4299,7 +3711,7 @@ func (this *DeploymentSpec) String() string { } s := strings.Join([]string{`&DeploymentSpec{`, `Replicas:` + valueToStringGenerated(this.Replicas) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, `Strategy:` + strings.Replace(strings.Replace(this.Strategy.String(), "DeploymentStrategy", "DeploymentStrategy", 1), `&`, ``, 1) + `,`, `MinReadySeconds:` + fmt.Sprintf("%v", this.MinReadySeconds) + `,`, @@ -4322,6 +3734,8 @@ func (this *DeploymentStatus) String() string { `AvailableReplicas:` + fmt.Sprintf("%v", this.AvailableReplicas) + `,`, `UnavailableReplicas:` + fmt.Sprintf("%v", this.UnavailableReplicas) + `,`, `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "DeploymentCondition", "DeploymentCondition", 1), `&`, ``, 1) + `,`, + `ReadyReplicas:` + fmt.Sprintf("%v", this.ReadyReplicas) + `,`, + `CollisionCount:` + valueToStringGenerated(this.CollisionCount) + `,`, `}`, }, "") return s @@ -4337,17 +3751,6 @@ func (this *DeploymentStrategy) String() string { }, "") return s } -func (this *ExportOptions) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&ExportOptions{`, - `Export:` + fmt.Sprintf("%v", this.Export) + `,`, - `Exact:` + fmt.Sprintf("%v", this.Exact) + `,`, - `}`, - }, "") - return s -} func (this *FSGroupStrategyOptions) String() string { if this == nil { return "nil" @@ -4380,56 +3783,6 @@ func (this *HTTPIngressRuleValue) String() string { }, "") return s } -func (this *HorizontalPodAutoscaler) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&HorizontalPodAutoscaler{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "HorizontalPodAutoscalerSpec", "HorizontalPodAutoscalerSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "HorizontalPodAutoscalerStatus", "HorizontalPodAutoscalerStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *HorizontalPodAutoscalerList) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&HorizontalPodAutoscalerList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "HorizontalPodAutoscaler", "HorizontalPodAutoscaler", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *HorizontalPodAutoscalerSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&HorizontalPodAutoscalerSpec{`, - `ScaleRef:` + strings.Replace(strings.Replace(this.ScaleRef.String(), "SubresourceReference", "SubresourceReference", 1), `&`, ``, 1) + `,`, - `MinReplicas:` + valueToStringGenerated(this.MinReplicas) + `,`, - `MaxReplicas:` + fmt.Sprintf("%v", this.MaxReplicas) + `,`, - `CPUUtilization:` + strings.Replace(fmt.Sprintf("%v", this.CPUUtilization), "CPUTargetUtilization", "CPUTargetUtilization", 1) + `,`, - `}`, - }, "") - return s -} -func (this *HorizontalPodAutoscalerStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&HorizontalPodAutoscalerStatus{`, - `ObservedGeneration:` + valueToStringGenerated(this.ObservedGeneration) + `,`, - `LastScaleTime:` + strings.Replace(fmt.Sprintf("%v", this.LastScaleTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `CurrentReplicas:` + fmt.Sprintf("%v", this.CurrentReplicas) + `,`, - `DesiredReplicas:` + fmt.Sprintf("%v", this.DesiredReplicas) + `,`, - `CurrentCPUUtilizationPercentage:` + valueToStringGenerated(this.CurrentCPUUtilizationPercentage) + `,`, - `}`, - }, "") - return s -} func (this *HostPortRange) String() string { if this == nil { return "nil" @@ -4457,7 +3810,7 @@ func (this *Ingress) String() string { return "nil" } s := strings.Join([]string{`&Ingress{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "IngressSpec", "IngressSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "IngressStatus", "IngressStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -4470,7 +3823,7 @@ func (this *IngressBackend) String() string { } s := strings.Join([]string{`&IngressBackend{`, `ServiceName:` + fmt.Sprintf("%v", this.ServiceName) + `,`, - `ServicePort:` + strings.Replace(strings.Replace(this.ServicePort.String(), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, + `ServicePort:` + strings.Replace(strings.Replace(this.ServicePort.String(), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -4480,7 +3833,7 @@ func (this *IngressList) String() string { return "nil" } s := strings.Join([]string{`&IngressList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Ingress", "Ingress", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4540,80 +3893,12 @@ func (this *IngressTLS) String() string { }, "") return s } -func (this *Job) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Job{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "JobSpec", "JobSpec", 1), `&`, ``, 1) + `,`, - `Status:` + strings.Replace(strings.Replace(this.Status.String(), "JobStatus", "JobStatus", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *JobCondition) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobCondition{`, - `Type:` + fmt.Sprintf("%v", this.Type) + `,`, - `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastProbeTime:` + strings.Replace(strings.Replace(this.LastProbeTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, - `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, - `Message:` + fmt.Sprintf("%v", this.Message) + `,`, - `}`, - }, "") - return s -} -func (this *JobList) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, - `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Job", "Job", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *JobSpec) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobSpec{`, - `Parallelism:` + valueToStringGenerated(this.Parallelism) + `,`, - `Completions:` + valueToStringGenerated(this.Completions) + `,`, - `ActiveDeadlineSeconds:` + valueToStringGenerated(this.ActiveDeadlineSeconds) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, - `AutoSelector:` + valueToStringGenerated(this.AutoSelector) + `,`, - `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func (this *JobStatus) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&JobStatus{`, - `Conditions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Conditions), "JobCondition", "JobCondition", 1), `&`, ``, 1) + `,`, - `StartTime:` + strings.Replace(fmt.Sprintf("%v", this.StartTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `CompletionTime:` + strings.Replace(fmt.Sprintf("%v", this.CompletionTime), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1) + `,`, - `Active:` + fmt.Sprintf("%v", this.Active) + `,`, - `Succeeded:` + fmt.Sprintf("%v", this.Succeeded) + `,`, - `Failed:` + fmt.Sprintf("%v", this.Failed) + `,`, - `}`, - }, "") - return s -} func (this *NetworkPolicy) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&NetworkPolicy{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "NetworkPolicySpec", "NetworkPolicySpec", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4635,7 +3920,7 @@ func (this *NetworkPolicyList) String() string { return "nil" } s := strings.Join([]string{`&NetworkPolicyList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "NetworkPolicy", "NetworkPolicy", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4646,8 +3931,8 @@ func (this *NetworkPolicyPeer) String() string { return "nil" } s := strings.Join([]string{`&NetworkPolicyPeer{`, - `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, - `NamespaceSelector:` + strings.Replace(fmt.Sprintf("%v", this.NamespaceSelector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `NamespaceSelector:` + strings.Replace(fmt.Sprintf("%v", this.NamespaceSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, `}`, }, "") return s @@ -4658,7 +3943,7 @@ func (this *NetworkPolicyPort) String() string { } s := strings.Join([]string{`&NetworkPolicyPort{`, `Protocol:` + valueToStringGenerated(this.Protocol) + `,`, - `Port:` + strings.Replace(fmt.Sprintf("%v", this.Port), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1) + `,`, + `Port:` + strings.Replace(fmt.Sprintf("%v", this.Port), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, `}`, }, "") return s @@ -4668,7 +3953,7 @@ func (this *NetworkPolicySpec) String() string { return "nil" } s := strings.Join([]string{`&NetworkPolicySpec{`, - `PodSelector:` + strings.Replace(strings.Replace(this.PodSelector.String(), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1), `&`, ``, 1) + `,`, + `PodSelector:` + strings.Replace(strings.Replace(this.PodSelector.String(), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1), `&`, ``, 1) + `,`, `Ingress:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ingress), "NetworkPolicyIngressRule", "NetworkPolicyIngressRule", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4679,7 +3964,7 @@ func (this *PodSecurityPolicy) String() string { return "nil" } s := strings.Join([]string{`&PodSecurityPolicy{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PodSecurityPolicySpec", "PodSecurityPolicySpec", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4690,7 +3975,7 @@ func (this *PodSecurityPolicyList) String() string { return "nil" } s := strings.Join([]string{`&PodSecurityPolicyList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "PodSecurityPolicy", "PodSecurityPolicy", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4724,7 +4009,7 @@ func (this *ReplicaSet) String() string { return "nil" } s := strings.Join([]string{`&ReplicaSet{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ReplicaSetSpec", "ReplicaSetSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ReplicaSetStatus", "ReplicaSetStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -4738,7 +4023,7 @@ func (this *ReplicaSetCondition) String() string { s := strings.Join([]string{`&ReplicaSetCondition{`, `Type:` + fmt.Sprintf("%v", this.Type) + `,`, `Status:` + fmt.Sprintf("%v", this.Status) + `,`, - `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_kubernetes_pkg_api_unversioned.Time", 1), `&`, ``, 1) + `,`, + `LastTransitionTime:` + strings.Replace(strings.Replace(this.LastTransitionTime.String(), "Time", "k8s_io_apimachinery_pkg_apis_meta_v1.Time", 1), `&`, ``, 1) + `,`, `Reason:` + fmt.Sprintf("%v", this.Reason) + `,`, `Message:` + fmt.Sprintf("%v", this.Message) + `,`, `}`, @@ -4750,7 +4035,7 @@ func (this *ReplicaSetList) String() string { return "nil" } s := strings.Join([]string{`&ReplicaSetList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ReplicaSet", "ReplicaSet", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4762,7 +4047,7 @@ func (this *ReplicaSetSpec) String() string { } s := strings.Join([]string{`&ReplicaSetSpec{`, `Replicas:` + valueToStringGenerated(this.Replicas) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, `Template:` + strings.Replace(strings.Replace(this.Template.String(), "PodTemplateSpec", "k8s_io_kubernetes_pkg_api_v1.PodTemplateSpec", 1), `&`, ``, 1) + `,`, `MinReadySeconds:` + fmt.Sprintf("%v", this.MinReadySeconds) + `,`, `}`, @@ -4803,13 +4088,23 @@ func (this *RollbackConfig) String() string { }, "") return s } +func (this *RollingUpdateDaemonSet) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RollingUpdateDaemonSet{`, + `MaxUnavailable:` + strings.Replace(fmt.Sprintf("%v", this.MaxUnavailable), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `}`, + }, "") + return s +} func (this *RollingUpdateDeployment) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&RollingUpdateDeployment{`, - `MaxUnavailable:` + strings.Replace(fmt.Sprintf("%v", this.MaxUnavailable), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1) + `,`, - `MaxSurge:` + strings.Replace(fmt.Sprintf("%v", this.MaxSurge), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1) + `,`, + `MaxUnavailable:` + strings.Replace(fmt.Sprintf("%v", this.MaxUnavailable), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `MaxSurge:` + strings.Replace(fmt.Sprintf("%v", this.MaxSurge), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, `}`, }, "") return s @@ -4841,7 +4136,7 @@ func (this *Scale) String() string { return "nil" } s := strings.Join([]string{`&Scale{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "ScaleSpec", "ScaleSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "ScaleStatus", "ScaleStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -4880,26 +4175,13 @@ func (this *ScaleStatus) String() string { }, "") return s } -func (this *SubresourceReference) String() string { +func (this *SupplementalGroupsStrategyOptions) String() string { if this == nil { return "nil" } - s := strings.Join([]string{`&SubresourceReference{`, - `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, - `Name:` + fmt.Sprintf("%v", this.Name) + `,`, - `APIVersion:` + fmt.Sprintf("%v", this.APIVersion) + `,`, - `Subresource:` + fmt.Sprintf("%v", this.Subresource) + `,`, - `}`, - }, "") - return s -} -func (this *SupplementalGroupsStrategyOptions) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&SupplementalGroupsStrategyOptions{`, - `Rule:` + fmt.Sprintf("%v", this.Rule) + `,`, - `Ranges:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ranges), "IDRange", "IDRange", 1), `&`, ``, 1) + `,`, + s := strings.Join([]string{`&SupplementalGroupsStrategyOptions{`, + `Rule:` + fmt.Sprintf("%v", this.Rule) + `,`, + `Ranges:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ranges), "IDRange", "IDRange", 1), `&`, ``, 1) + `,`, `}`, }, "") return s @@ -4909,7 +4191,7 @@ func (this *ThirdPartyResource) String() string { return "nil" } s := strings.Join([]string{`&ThirdPartyResource{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Description:` + fmt.Sprintf("%v", this.Description) + `,`, `Versions:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Versions), "APIVersion", "APIVersion", 1), `&`, ``, 1) + `,`, `}`, @@ -4921,7 +4203,7 @@ func (this *ThirdPartyResourceData) String() string { return "nil" } s := strings.Join([]string{`&ThirdPartyResourceData{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Data:` + valueToStringGenerated(this.Data) + `,`, `}`, }, "") @@ -4932,7 +4214,7 @@ func (this *ThirdPartyResourceDataList) String() string { return "nil" } s := strings.Join([]string{`&ThirdPartyResourceDataList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ThirdPartyResourceData", "ThirdPartyResourceData", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4943,7 +4225,7 @@ func (this *ThirdPartyResourceList) String() string { return "nil" } s := strings.Join([]string{`&ThirdPartyResourceList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ThirdPartyResource", "ThirdPartyResource", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -4957,8 +4239,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *APIVersion) Unmarshal(data []byte) error { - l := len(data) +func (m *APIVersion) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -4970,7 +4252,7 @@ func (m *APIVersion) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -4998,7 +4280,7 @@ func (m *APIVersion) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5013,80 +4295,11 @@ func (m *APIVersion) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *CPUTargetUtilization) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: CPUTargetUtilization: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: CPUTargetUtilization: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetPercentage", wireType) - } - m.TargetPercentage = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.TargetPercentage |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5105,8 +4318,8 @@ func (m *CPUTargetUtilization) Unmarshal(data []byte) error { } return nil } -func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *CustomMetricCurrentStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5118,7 +4331,7 @@ func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5146,7 +4359,7 @@ func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5161,7 +4374,7 @@ func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -5175,7 +4388,7 @@ func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5189,13 +4402,13 @@ func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.CurrentValue.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.CurrentValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5214,8 +4427,8 @@ func (m *CustomMetricCurrentStatus) Unmarshal(data []byte) error { } return nil } -func (m *CustomMetricCurrentStatusList) Unmarshal(data []byte) error { - l := len(data) +func (m *CustomMetricCurrentStatusList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5227,7 +4440,7 @@ func (m *CustomMetricCurrentStatusList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5255,7 +4468,7 @@ func (m *CustomMetricCurrentStatusList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5270,13 +4483,13 @@ func (m *CustomMetricCurrentStatusList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, CustomMetricCurrentStatus{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5295,8 +4508,8 @@ func (m *CustomMetricCurrentStatusList) Unmarshal(data []byte) error { } return nil } -func (m *CustomMetricTarget) Unmarshal(data []byte) error { - l := len(data) +func (m *CustomMetricTarget) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5308,7 +4521,7 @@ func (m *CustomMetricTarget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5336,7 +4549,7 @@ func (m *CustomMetricTarget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5351,7 +4564,7 @@ func (m *CustomMetricTarget) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -5365,7 +4578,7 @@ func (m *CustomMetricTarget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5379,13 +4592,13 @@ func (m *CustomMetricTarget) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.TargetValue.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.TargetValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5404,8 +4617,8 @@ func (m *CustomMetricTarget) Unmarshal(data []byte) error { } return nil } -func (m *CustomMetricTargetList) Unmarshal(data []byte) error { - l := len(data) +func (m *CustomMetricTargetList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5417,7 +4630,7 @@ func (m *CustomMetricTargetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5445,7 +4658,7 @@ func (m *CustomMetricTargetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5460,13 +4673,13 @@ func (m *CustomMetricTargetList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, CustomMetricTarget{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5485,8 +4698,8 @@ func (m *CustomMetricTargetList) Unmarshal(data []byte) error { } return nil } -func (m *DaemonSet) Unmarshal(data []byte) error { - l := len(data) +func (m *DaemonSet) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5498,7 +4711,7 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5526,7 +4739,7 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5540,7 +4753,7 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5556,7 +4769,7 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5570,7 +4783,7 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5586,7 +4799,7 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5600,13 +4813,13 @@ func (m *DaemonSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5625,8 +4838,8 @@ func (m *DaemonSet) Unmarshal(data []byte) error { } return nil } -func (m *DaemonSetList) Unmarshal(data []byte) error { - l := len(data) +func (m *DaemonSetList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5638,7 +4851,7 @@ func (m *DaemonSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5666,7 +4879,7 @@ func (m *DaemonSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5680,7 +4893,7 @@ func (m *DaemonSetList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5696,7 +4909,7 @@ func (m *DaemonSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5711,13 +4924,13 @@ func (m *DaemonSetList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, DaemonSet{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5736,8 +4949,8 @@ func (m *DaemonSetList) Unmarshal(data []byte) error { } return nil } -func (m *DaemonSetSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *DaemonSetSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5749,7 +4962,7 @@ func (m *DaemonSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5777,7 +4990,7 @@ func (m *DaemonSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5792,9 +5005,9 @@ func (m *DaemonSetSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -5810,7 +5023,37 @@ func (m *DaemonSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field UpdateStrategy", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -5824,13 +5067,71 @@ func (m *DaemonSetSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.UpdateStrategy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field MinReadySeconds", wireType) + } + m.MinReadySeconds = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.MinReadySeconds |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field TemplateGeneration", wireType) + } + m.TemplateGeneration = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.TemplateGeneration |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field RevisionHistoryLimit", wireType) + } + var v int32 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.RevisionHistoryLimit = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5849,8 +5150,8 @@ func (m *DaemonSetSpec) Unmarshal(data []byte) error { } return nil } -func (m *DaemonSetStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *DaemonSetStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5862,7 +5163,7 @@ func (m *DaemonSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5890,7 +5191,7 @@ func (m *DaemonSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.CurrentNumberScheduled |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -5909,7 +5210,7 @@ func (m *DaemonSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.NumberMisscheduled |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -5928,7 +5229,7 @@ func (m *DaemonSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.DesiredNumberScheduled |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -5947,16 +5248,112 @@ func (m *DaemonSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.NumberReady |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } + case 5: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + } + m.ObservedGeneration = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ObservedGeneration |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 6: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field UpdatedNumberScheduled", wireType) + } + m.UpdatedNumberScheduled = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.UpdatedNumberScheduled |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field NumberAvailable", wireType) + } + m.NumberAvailable = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.NumberAvailable |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field NumberUnavailable", wireType) + } + m.NumberUnavailable = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.NumberUnavailable |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 9: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CollisionCount", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.CollisionCount = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -5975,8 +5372,8 @@ func (m *DaemonSetStatus) Unmarshal(data []byte) error { } return nil } -func (m *Deployment) Unmarshal(data []byte) error { - l := len(data) +func (m *DaemonSetUpdateStrategy) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -5988,7 +5385,7 @@ func (m *Deployment) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -5998,17 +5395,17 @@ func (m *Deployment) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: Deployment: wiretype end group for non-group") + return fmt.Errorf("proto: DaemonSetUpdateStrategy: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: Deployment: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: DaemonSetUpdateStrategy: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -6016,27 +5413,26 @@ func (m *Deployment) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Type = DaemonSetUpdateStrategyType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field RollingUpdate", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -6046,7 +5442,7 @@ func (m *Deployment) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6060,23 +5456,136 @@ func (m *Deployment) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.RollingUpdate == nil { + m.RollingUpdate = &RollingUpdateDaemonSet{} + } + if err := m.RollingUpdate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - var msglen int - for shift := uint(0); ; shift += 7 { + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Deployment) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Deployment: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Deployment: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated } if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6090,13 +5599,13 @@ func (m *Deployment) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -6115,8 +5624,8 @@ func (m *Deployment) Unmarshal(data []byte) error { } return nil } -func (m *DeploymentCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *DeploymentCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -6128,7 +5637,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6156,7 +5665,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6171,7 +5680,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = DeploymentConditionType(data[iNdEx:postIndex]) + m.Type = DeploymentConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -6185,7 +5694,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6200,7 +5709,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(data[iNdEx:postIndex]) + m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -6214,7 +5723,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6229,7 +5738,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -6243,7 +5752,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6258,7 +5767,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 6: if wireType != 2 { @@ -6272,7 +5781,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6286,7 +5795,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastUpdateTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastUpdateTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6302,7 +5811,7 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6316,13 +5825,13 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -6341,8 +5850,8 @@ func (m *DeploymentCondition) Unmarshal(data []byte) error { } return nil } -func (m *DeploymentList) Unmarshal(data []byte) error { - l := len(data) +func (m *DeploymentList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -6354,7 +5863,7 @@ func (m *DeploymentList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6382,7 +5891,7 @@ func (m *DeploymentList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6396,7 +5905,7 @@ func (m *DeploymentList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6412,7 +5921,7 @@ func (m *DeploymentList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6427,13 +5936,13 @@ func (m *DeploymentList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Deployment{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -6452,8 +5961,8 @@ func (m *DeploymentList) Unmarshal(data []byte) error { } return nil } -func (m *DeploymentRollback) Unmarshal(data []byte) error { - l := len(data) +func (m *DeploymentRollback) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -6465,7 +5974,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6493,7 +6002,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6508,7 +6017,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -6522,7 +6031,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6544,7 +6053,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6559,7 +6068,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6574,52 +6083,57 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.UpdatedAnnotations == nil { + m.UpdatedAnnotations = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.UpdatedAnnotations[mapkey] = mapvalue + } else { + var mapvalue string + m.UpdatedAnnotations[mapkey] = mapvalue } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.UpdatedAnnotations == nil { - m.UpdatedAnnotations = make(map[string]string) - } - m.UpdatedAnnotations[mapkey] = mapvalue iNdEx = postIndex case 3: if wireType != 2 { @@ -6633,7 +6147,7 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6647,13 +6161,13 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.RollbackTo.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RollbackTo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -6672,8 +6186,8 @@ func (m *DeploymentRollback) Unmarshal(data []byte) error { } return nil } -func (m *DeploymentSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *DeploymentSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -6685,7 +6199,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6713,7 +6227,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -6733,7 +6247,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6748,9 +6262,9 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6766,7 +6280,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6780,7 +6294,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6796,7 +6310,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6810,7 +6324,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Strategy.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Strategy.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6826,7 +6340,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.MinReadySeconds |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -6845,7 +6359,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -6865,7 +6379,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6885,7 +6399,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -6902,7 +6416,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if m.RollbackTo == nil { m.RollbackTo = &RollbackConfig{} } - if err := m.RollbackTo.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RollbackTo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -6918,7 +6432,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -6928,7 +6442,7 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { m.ProgressDeadlineSeconds = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -6947,8 +6461,8 @@ func (m *DeploymentSpec) Unmarshal(data []byte) error { } return nil } -func (m *DeploymentStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *DeploymentStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -6960,7 +6474,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -6988,7 +6502,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ObservedGeneration |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -7007,7 +6521,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -7026,7 +6540,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.UpdatedReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -7045,7 +6559,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.AvailableReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -7064,7 +6578,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.UnavailableReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -7083,7 +6597,7 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7098,13 +6612,52 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Conditions = append(m.Conditions, DeploymentCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex + case 7: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field ReadyReplicas", wireType) + } + m.ReadyReplicas = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.ReadyReplicas |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + case 8: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field CollisionCount", wireType) + } + var v int64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + m.CollisionCount = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7123,8 +6676,8 @@ func (m *DeploymentStatus) Unmarshal(data []byte) error { } return nil } -func (m *DeploymentStrategy) Unmarshal(data []byte) error { - l := len(data) +func (m *DeploymentStrategy) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7136,7 +6689,7 @@ func (m *DeploymentStrategy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7164,7 +6717,7 @@ func (m *DeploymentStrategy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7179,7 +6732,7 @@ func (m *DeploymentStrategy) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = DeploymentStrategyType(data[iNdEx:postIndex]) + m.Type = DeploymentStrategyType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -7193,7 +6746,7 @@ func (m *DeploymentStrategy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7210,13 +6763,13 @@ func (m *DeploymentStrategy) Unmarshal(data []byte) error { if m.RollingUpdate == nil { m.RollingUpdate = &RollingUpdateDeployment{} } - if err := m.RollingUpdate.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RollingUpdate.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7235,8 +6788,8 @@ func (m *DeploymentStrategy) Unmarshal(data []byte) error { } return nil } -func (m *ExportOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *FSGroupStrategyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7248,7 +6801,7 @@ func (m *ExportOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7258,17 +6811,17 @@ func (m *ExportOptions) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ExportOptions: wiretype end group for non-group") + return fmt.Errorf("proto: FSGroupStrategyOptions: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ExportOptions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: FSGroupStrategyOptions: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Export", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rule", wireType) } - var v int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7276,19 +6829,28 @@ func (m *ExportOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.Export = bool(v != 0) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rule = FSGroupStrategyType(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Exact", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ranges", wireType) } - var v int + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7296,17 +6858,28 @@ func (m *ExportOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Exact = bool(v != 0) + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ranges = append(m.Ranges, IDRange{}) + if err := m.Ranges[len(m.Ranges)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7325,8 +6898,8 @@ func (m *ExportOptions) Unmarshal(data []byte) error { } return nil } -func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *HTTPIngressPath) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7338,7 +6911,7 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7348,15 +6921,15 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: FSGroupStrategyOptions: wiretype end group for non-group") + return fmt.Errorf("proto: HTTPIngressPath: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: FSGroupStrategyOptions: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: HTTPIngressPath: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Rule", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -7366,7 +6939,7 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7381,11 +6954,11 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Rule = FSGroupStrategyType(data[iNdEx:postIndex]) + m.Path = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Ranges", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Backend", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7395,7 +6968,7 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7409,14 +6982,13 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Ranges = append(m.Ranges, IDRange{}) - if err := m.Ranges[len(m.Ranges)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Backend.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7435,8 +7007,8 @@ func (m *FSGroupStrategyOptions) Unmarshal(data []byte) error { } return nil } -func (m *HTTPIngressPath) Unmarshal(data []byte) error { - l := len(data) +func (m *HTTPIngressRuleValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7448,7 +7020,7 @@ func (m *HTTPIngressPath) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7458,17 +7030,17 @@ func (m *HTTPIngressPath) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HTTPIngressPath: wiretype end group for non-group") + return fmt.Errorf("proto: HTTPIngressRuleValue: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HTTPIngressPath: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: HTTPIngressRuleValue: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7476,56 +7048,116 @@ func (m *HTTPIngressPath) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.Path = string(data[iNdEx:postIndex]) + m.Paths = append(m.Paths, HTTPIngressPath{}) + if err := m.Paths[len(m.Paths)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Backend", wireType) + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - var msglen int - for shift := uint(0); ; shift += 7 { + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *HostPortRange) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HostPortRange: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HostPortRange: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType) + } + m.Min = 0 + for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated } if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.Min |= (int32(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType) } - if err := m.Backend.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + m.Max = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Max |= (int32(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7544,8 +7176,8 @@ func (m *HTTPIngressPath) Unmarshal(data []byte) error { } return nil } -func (m *HTTPIngressRuleValue) Unmarshal(data []byte) error { - l := len(data) +func (m *IDRange) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7557,7 +7189,7 @@ func (m *HTTPIngressRuleValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7567,17 +7199,17 @@ func (m *HTTPIngressRuleValue) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HTTPIngressRuleValue: wiretype end group for non-group") + return fmt.Errorf("proto: IDRange: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HTTPIngressRuleValue: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: IDRange: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Paths", wireType) + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType) } - var msglen int + m.Min = 0 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7585,28 +7217,35 @@ func (m *HTTPIngressRuleValue) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + m.Min |= (int64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType) } - m.Paths = append(m.Paths, HTTPIngressPath{}) - if err := m.Paths[len(m.Paths)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + m.Max = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Max |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7625,8 +7264,8 @@ func (m *HTTPIngressRuleValue) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { - l := len(data) +func (m *Ingress) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7638,7 +7277,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7648,10 +7287,10 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscaler: wiretype end group for non-group") + return fmt.Errorf("proto: Ingress: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscaler: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: Ingress: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: @@ -7666,7 +7305,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7680,7 +7319,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -7696,7 +7335,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7710,7 +7349,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -7726,7 +7365,7 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7740,13 +7379,13 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7765,8 +7404,8 @@ func (m *HorizontalPodAutoscaler) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { - l := len(data) +func (m *IngressBackend) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7778,7 +7417,7 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7788,17 +7427,17 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscalerList: wiretype end group for non-group") + return fmt.Errorf("proto: IngressBackend: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscalerList: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: IngressBackend: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ServiceName", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -7806,27 +7445,26 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.ServiceName = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ServicePort", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7836,7 +7474,7 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7850,14 +7488,13 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, HorizontalPodAutoscaler{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ServicePort.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -7876,8 +7513,8 @@ func (m *HorizontalPodAutoscalerList) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *IngressList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -7889,7 +7526,7 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -7899,15 +7536,15 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: wiretype end group for non-group") + return fmt.Errorf("proto: IngressList: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscalerSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: IngressList: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ScaleRef", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7917,7 +7554,7 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -7931,52 +7568,13 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ScaleRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field MinReplicas", wireType) - } - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.MinReplicas = &v - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field MaxReplicas", wireType) - } - m.MaxReplicas = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.MaxReplicas |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CPUUtilization", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -7986,7 +7584,7 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -8000,16 +7598,14 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.CPUUtilization == nil { - m.CPUUtilization = &CPUTargetUtilization{} - } - if err := m.CPUUtilization.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Items = append(m.Items, Ingress{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -8028,8 +7624,8 @@ func (m *HorizontalPodAutoscalerSpec) Unmarshal(data []byte) error { } return nil } -func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *IngressRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -8041,7 +7637,7 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -8051,17 +7647,17 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: wiretype end group for non-group") + return fmt.Errorf("proto: IngressRule: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: HorizontalPodAutoscalerStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: IngressRule: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ObservedGeneration", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType) } - var v int64 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -8069,17 +7665,26 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int64(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - m.ObservedGeneration = &v + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Host = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastScaleTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field IngressRuleValue", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -8089,7 +7694,7 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -8103,74 +7708,13 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.LastScaleTime == nil { - m.LastScaleTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} - } - if err := m.LastScaleTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.IngressRuleValue.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CurrentReplicas", wireType) - } - m.CurrentReplicas = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.CurrentReplicas |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field DesiredReplicas", wireType) - } - m.DesiredReplicas = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.DesiredReplicas |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field CurrentCPUUtilizationPercentage", wireType) - } - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - m.CurrentCPUUtilizationPercentage = &v default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -8189,8 +7733,8 @@ func (m *HorizontalPodAutoscalerStatus) Unmarshal(data []byte) error { } return nil } -func (m *HostPortRange) Unmarshal(data []byte) error { - l := len(data) +func (m *IngressRuleValue) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -8199,1485 +7743,28 @@ func (m *HostPortRange) Unmarshal(data []byte) error { if shift >= 64 { return ErrIntOverflowGenerated } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: HostPortRange: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: HostPortRange: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType) - } - m.Min = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Min |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType) - } - m.Max = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Max |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IDRange) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IDRange: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IDRange: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Min", wireType) - } - m.Min = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Min |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Max", wireType) - } - m.Max = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Max |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Ingress) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Ingress: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Ingress: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressBackend) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressBackend: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressBackend: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServiceName", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.ServiceName = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ServicePort", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ServicePort.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressList) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Items = append(m.Items, Ingress{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressRule) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressRule: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressRule: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Host", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Host = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field IngressRuleValue", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.IngressRuleValue.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressRuleValue) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressRuleValue: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressRuleValue: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field HTTP", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.HTTP == nil { - m.HTTP = &HTTPIngressRuleValue{} - } - if err := m.HTTP.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressSpec) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressSpec: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressSpec: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Backend", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if m.Backend == nil { - m.Backend = &IngressBackend{} - } - if err := m.Backend.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TLS", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.TLS = append(m.TLS, IngressTLS{}) - if err := m.TLS[len(m.TLS)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Rules = append(m.Rules, IngressRule{}) - if err := m.Rules[len(m.Rules)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressStatus) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressStatus: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressStatus: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancer", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.LoadBalancer.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *IngressTLS) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: IngressTLS: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: IngressTLS: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Hosts", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Hosts = append(m.Hosts, string(data[iNdEx:postIndex])) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field SecretName", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.SecretName = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *Job) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Job: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Job: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *JobCondition) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: JobCondition: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: JobCondition: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Type = JobConditionType(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Status", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(data[iNdEx:postIndex]) - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastProbeTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.LastProbeTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field LastTransitionTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - case 5: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Reason", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Reason = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 6: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Message = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *JobList) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: JobList: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: JobList: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { + if iNdEx >= l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex - case 2: + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: IngressRuleValue: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: IngressRuleValue: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field HTTP", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9687,7 +7774,7 @@ func (m *JobList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -9701,14 +7788,16 @@ func (m *JobList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Items = append(m.Items, Job{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.HTTP == nil { + m.HTTP = &HTTPIngressRuleValue{} + } + if err := m.HTTP.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -9727,8 +7816,8 @@ func (m *JobList) Unmarshal(data []byte) error { } return nil } -func (m *JobSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *IngressSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -9740,7 +7829,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -9750,17 +7839,17 @@ func (m *JobSpec) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: JobSpec: wiretype end group for non-group") + return fmt.Errorf("proto: IngressSpec: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: JobSpec: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: IngressSpec: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Parallelism", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Backend", wireType) } - var v int32 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -9768,57 +7857,30 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - v |= (int32(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - m.Parallelism = &v - case 2: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Completions", wireType) + if msglen < 0 { + return ErrInvalidLengthGenerated } - var v int32 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF } - m.Completions = &v - case 3: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field ActiveDeadlineSeconds", wireType) + if m.Backend == nil { + m.Backend = &IngressBackend{} } - var v int64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int64(b) & 0x7F) << shift - if b < 0x80 { - break - } + if err := m.Backend.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err } - m.ActiveDeadlineSeconds = &v - case 4: + iNdEx = postIndex + case 2: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TLS", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9828,7 +7890,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -9842,37 +7904,14 @@ func (m *JobSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} - } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.TLS = append(m.TLS, IngressTLS{}) + if err := m.TLS[len(m.TLS)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field AutoSelector", wireType) - } - var v int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - v |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - b := bool(v != 0) - m.AutoSelector = &b - case 6: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Template", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9882,7 +7921,7 @@ func (m *JobSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -9896,13 +7935,14 @@ func (m *JobSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + m.Rules = append(m.Rules, IngressRule{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -9921,8 +7961,8 @@ func (m *JobSpec) Unmarshal(data []byte) error { } return nil } -func (m *JobStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *IngressStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -9934,7 +7974,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -9944,15 +7984,15 @@ func (m *JobStatus) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: JobStatus: wiretype end group for non-group") + return fmt.Errorf("proto: IngressStatus: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: JobStatus: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: IngressStatus: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Conditions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field LoadBalancer", wireType) } var msglen int for shift := uint(0); ; shift += 7 { @@ -9962,7 +8002,7 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -9976,49 +8016,65 @@ func (m *JobStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Conditions = append(m.Conditions, JobCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LoadBalancer.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field StartTime", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err } - if msglen < 0 { + if skippy < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen - if postIndex > l { + if (iNdEx + skippy) > l { return io.ErrUnexpectedEOF } - if m.StartTime == nil { - m.StartTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *IngressTLS) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF } - if err := m.StartTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex - case 3: + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: IngressTLS: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: IngressTLS: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field CompletionTime", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Hosts", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -10026,51 +8082,28 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if m.CompletionTime == nil { - m.CompletionTime = &k8s_io_kubernetes_pkg_api_unversioned.Time{} - } - if err := m.CompletionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.Hosts = append(m.Hosts, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 4: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Active", wireType) - } - m.Active = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Active |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - case 5: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Succeeded", wireType) + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SecretName", wireType) } - m.Succeeded = 0 + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -10078,35 +8111,26 @@ func (m *JobStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.Succeeded |= (int32(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - case 6: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Failed", wireType) + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated } - m.Failed = 0 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - m.Failed |= (int32(b) & 0x7F) << shift - if b < 0x80 { - break - } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF } + m.SecretName = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10125,8 +8149,8 @@ func (m *JobStatus) Unmarshal(data []byte) error { } return nil } -func (m *NetworkPolicy) Unmarshal(data []byte) error { - l := len(data) +func (m *NetworkPolicy) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10138,7 +8162,7 @@ func (m *NetworkPolicy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10166,7 +8190,7 @@ func (m *NetworkPolicy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10180,7 +8204,7 @@ func (m *NetworkPolicy) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10196,7 +8220,7 @@ func (m *NetworkPolicy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10210,13 +8234,13 @@ func (m *NetworkPolicy) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10235,8 +8259,8 @@ func (m *NetworkPolicy) Unmarshal(data []byte) error { } return nil } -func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { - l := len(data) +func (m *NetworkPolicyIngressRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10248,7 +8272,7 @@ func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10276,7 +8300,7 @@ func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10291,7 +8315,7 @@ func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ports = append(m.Ports, NetworkPolicyPort{}) - if err := m.Ports[len(m.Ports)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10307,7 +8331,7 @@ func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10322,13 +8346,13 @@ func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.From = append(m.From, NetworkPolicyPeer{}) - if err := m.From[len(m.From)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.From[len(m.From)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10347,8 +8371,8 @@ func (m *NetworkPolicyIngressRule) Unmarshal(data []byte) error { } return nil } -func (m *NetworkPolicyList) Unmarshal(data []byte) error { - l := len(data) +func (m *NetworkPolicyList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10360,7 +8384,7 @@ func (m *NetworkPolicyList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10388,7 +8412,7 @@ func (m *NetworkPolicyList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10402,7 +8426,7 @@ func (m *NetworkPolicyList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10418,7 +8442,7 @@ func (m *NetworkPolicyList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10433,13 +8457,13 @@ func (m *NetworkPolicyList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, NetworkPolicy{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10458,8 +8482,8 @@ func (m *NetworkPolicyList) Unmarshal(data []byte) error { } return nil } -func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { - l := len(data) +func (m *NetworkPolicyPeer) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10471,7 +8495,7 @@ func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10499,7 +8523,7 @@ func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10514,9 +8538,9 @@ func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.PodSelector == nil { - m.PodSelector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.PodSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - if err := m.PodSelector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10532,7 +8556,7 @@ func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10547,15 +8571,15 @@ func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.NamespaceSelector == nil { - m.NamespaceSelector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.NamespaceSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - if err := m.NamespaceSelector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.NamespaceSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10574,8 +8598,8 @@ func (m *NetworkPolicyPeer) Unmarshal(data []byte) error { } return nil } -func (m *NetworkPolicyPort) Unmarshal(data []byte) error { - l := len(data) +func (m *NetworkPolicyPort) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10587,7 +8611,7 @@ func (m *NetworkPolicyPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10615,7 +8639,7 @@ func (m *NetworkPolicyPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10630,7 +8654,7 @@ func (m *NetworkPolicyPort) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - s := k8s_io_kubernetes_pkg_api_v1.Protocol(data[iNdEx:postIndex]) + s := k8s_io_kubernetes_pkg_api_v1.Protocol(dAtA[iNdEx:postIndex]) m.Protocol = &s iNdEx = postIndex case 2: @@ -10645,7 +8669,7 @@ func (m *NetworkPolicyPort) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10660,15 +8684,15 @@ func (m *NetworkPolicyPort) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.Port == nil { - m.Port = &k8s_io_kubernetes_pkg_util_intstr.IntOrString{} + m.Port = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} } - if err := m.Port.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Port.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10687,8 +8711,8 @@ func (m *NetworkPolicyPort) Unmarshal(data []byte) error { } return nil } -func (m *NetworkPolicySpec) Unmarshal(data []byte) error { - l := len(data) +func (m *NetworkPolicySpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10700,7 +8724,7 @@ func (m *NetworkPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10728,7 +8752,7 @@ func (m *NetworkPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10742,7 +8766,7 @@ func (m *NetworkPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.PodSelector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10758,7 +8782,7 @@ func (m *NetworkPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10773,13 +8797,13 @@ func (m *NetworkPolicySpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ingress = append(m.Ingress, NetworkPolicyIngressRule{}) - if err := m.Ingress[len(m.Ingress)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ingress[len(m.Ingress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10798,8 +8822,8 @@ func (m *NetworkPolicySpec) Unmarshal(data []byte) error { } return nil } -func (m *PodSecurityPolicy) Unmarshal(data []byte) error { - l := len(data) +func (m *PodSecurityPolicy) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10811,7 +8835,7 @@ func (m *PodSecurityPolicy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10839,7 +8863,7 @@ func (m *PodSecurityPolicy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10853,7 +8877,7 @@ func (m *PodSecurityPolicy) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10869,7 +8893,7 @@ func (m *PodSecurityPolicy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10883,13 +8907,13 @@ func (m *PodSecurityPolicy) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -10908,8 +8932,8 @@ func (m *PodSecurityPolicy) Unmarshal(data []byte) error { } return nil } -func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { - l := len(data) +func (m *PodSecurityPolicyList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -10921,7 +8945,7 @@ func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -10949,7 +8973,7 @@ func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10963,7 +8987,7 @@ func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -10979,7 +9003,7 @@ func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -10994,13 +9018,13 @@ func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, PodSecurityPolicy{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -11019,8 +9043,8 @@ func (m *PodSecurityPolicyList) Unmarshal(data []byte) error { } return nil } -func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { - l := len(data) +func (m *PodSecurityPolicySpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -11032,7 +9056,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11060,7 +9084,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11080,7 +9104,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11095,7 +9119,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.DefaultAddCapabilities = append(m.DefaultAddCapabilities, k8s_io_kubernetes_pkg_api_v1.Capability(data[iNdEx:postIndex])) + m.DefaultAddCapabilities = append(m.DefaultAddCapabilities, k8s_io_kubernetes_pkg_api_v1.Capability(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 3: if wireType != 2 { @@ -11109,7 +9133,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11124,7 +9148,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.RequiredDropCapabilities = append(m.RequiredDropCapabilities, k8s_io_kubernetes_pkg_api_v1.Capability(data[iNdEx:postIndex])) + m.RequiredDropCapabilities = append(m.RequiredDropCapabilities, k8s_io_kubernetes_pkg_api_v1.Capability(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 4: if wireType != 2 { @@ -11138,7 +9162,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11153,7 +9177,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.AllowedCapabilities = append(m.AllowedCapabilities, k8s_io_kubernetes_pkg_api_v1.Capability(data[iNdEx:postIndex])) + m.AllowedCapabilities = append(m.AllowedCapabilities, k8s_io_kubernetes_pkg_api_v1.Capability(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 5: if wireType != 2 { @@ -11167,7 +9191,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11182,7 +9206,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Volumes = append(m.Volumes, FSType(data[iNdEx:postIndex])) + m.Volumes = append(m.Volumes, FSType(dAtA[iNdEx:postIndex])) iNdEx = postIndex case 6: if wireType != 0 { @@ -11196,7 +9220,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11216,7 +9240,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11231,7 +9255,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.HostPorts = append(m.HostPorts, HostPortRange{}) - if err := m.HostPorts[len(m.HostPorts)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.HostPorts[len(m.HostPorts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11247,7 +9271,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11267,7 +9291,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11287,7 +9311,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11301,7 +9325,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.SELinux.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SELinux.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11317,7 +9341,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11331,7 +9355,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.RunAsUser.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RunAsUser.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11347,7 +9371,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11361,7 +9385,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.SupplementalGroups.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SupplementalGroups.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11377,7 +9401,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11391,7 +9415,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.FSGroup.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.FSGroup.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11407,7 +9431,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11417,7 +9441,7 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { m.ReadOnlyRootFilesystem = bool(v != 0) default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -11436,8 +9460,8 @@ func (m *PodSecurityPolicySpec) Unmarshal(data []byte) error { } return nil } -func (m *ReplicaSet) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicaSet) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -11449,7 +9473,7 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11477,7 +9501,7 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11491,7 +9515,7 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11507,7 +9531,7 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11521,7 +9545,7 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11537,7 +9561,7 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11551,13 +9575,13 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -11576,8 +9600,8 @@ func (m *ReplicaSet) Unmarshal(data []byte) error { } return nil } -func (m *ReplicaSetCondition) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicaSetCondition) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -11589,7 +9613,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11617,7 +9641,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11632,7 +9656,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Type = ReplicaSetConditionType(data[iNdEx:postIndex]) + m.Type = ReplicaSetConditionType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -11646,7 +9670,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11661,7 +9685,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(data[iNdEx:postIndex]) + m.Status = k8s_io_kubernetes_pkg_api_v1.ConditionStatus(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -11675,7 +9699,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11689,7 +9713,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.LastTransitionTime.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.LastTransitionTime.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11705,7 +9729,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11720,7 +9744,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Reason = string(data[iNdEx:postIndex]) + m.Reason = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 5: if wireType != 2 { @@ -11734,7 +9758,7 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11749,11 +9773,11 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Message = string(data[iNdEx:postIndex]) + m.Message = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -11772,8 +9796,8 @@ func (m *ReplicaSetCondition) Unmarshal(data []byte) error { } return nil } -func (m *ReplicaSetList) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicaSetList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -11785,7 +9809,7 @@ func (m *ReplicaSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11813,7 +9837,7 @@ func (m *ReplicaSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11827,7 +9851,7 @@ func (m *ReplicaSetList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11843,7 +9867,7 @@ func (m *ReplicaSetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11858,13 +9882,13 @@ func (m *ReplicaSetList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ReplicaSet{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -11883,8 +9907,8 @@ func (m *ReplicaSetList) Unmarshal(data []byte) error { } return nil } -func (m *ReplicaSetSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicaSetSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -11896,7 +9920,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -11924,7 +9948,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ v |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -11944,7 +9968,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11959,9 +9983,9 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -11977,7 +10001,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -11991,7 +10015,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Template.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Template.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12007,7 +10031,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.MinReadySeconds |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12016,7 +10040,7 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12035,8 +10059,8 @@ func (m *ReplicaSetSpec) Unmarshal(data []byte) error { } return nil } -func (m *ReplicaSetStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ReplicaSetStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12048,7 +10072,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12076,7 +10100,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12095,7 +10119,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.FullyLabeledReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12114,7 +10138,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ObservedGeneration |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -12133,7 +10157,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ReadyReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12152,7 +10176,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.AvailableReplicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12171,7 +10195,7 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12185,14 +10209,64 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Conditions = append(m.Conditions, ReplicaSetCondition{}) - if err := m.Conditions[len(m.Conditions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { - return err + m.Conditions = append(m.Conditions, ReplicaSetCondition{}) + if err := m.Conditions[len(m.Conditions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ReplicationControllerDummy) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break } - iNdEx = postIndex + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ReplicationControllerDummy: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ReplicationControllerDummy: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12211,8 +10285,8 @@ func (m *ReplicaSetStatus) Unmarshal(data []byte) error { } return nil } -func (m *ReplicationControllerDummy) Unmarshal(data []byte) error { - l := len(data) +func (m *RollbackConfig) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12224,7 +10298,7 @@ func (m *ReplicationControllerDummy) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12234,15 +10308,34 @@ func (m *ReplicationControllerDummy) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: ReplicationControllerDummy: wiretype end group for non-group") + return fmt.Errorf("proto: RollbackConfig: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: ReplicationControllerDummy: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RollbackConfig: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType) + } + m.Revision = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Revision |= (int64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12261,8 +10354,8 @@ func (m *ReplicationControllerDummy) Unmarshal(data []byte) error { } return nil } -func (m *RollbackConfig) Unmarshal(data []byte) error { - l := len(data) +func (m *RollingUpdateDaemonSet) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12274,7 +10367,7 @@ func (m *RollbackConfig) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12284,17 +10377,17 @@ func (m *RollbackConfig) Unmarshal(data []byte) error { fieldNum := int32(wire >> 3) wireType := int(wire & 0x7) if wireType == 4 { - return fmt.Errorf("proto: RollbackConfig: wiretype end group for non-group") + return fmt.Errorf("proto: RollingUpdateDaemonSet: wiretype end group for non-group") } if fieldNum <= 0 { - return fmt.Errorf("proto: RollbackConfig: illegal tag %d (wire type %d)", fieldNum, wire) + return fmt.Errorf("proto: RollingUpdateDaemonSet: illegal tag %d (wire type %d)", fieldNum, wire) } switch fieldNum { case 1: - if wireType != 0 { - return fmt.Errorf("proto: wrong wireType = %d for field Revision", wireType) + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MaxUnavailable", wireType) } - m.Revision = 0 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -12302,16 +10395,30 @@ func (m *RollbackConfig) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - m.Revision |= (int64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.MaxUnavailable == nil { + m.MaxUnavailable = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.MaxUnavailable.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12330,8 +10437,8 @@ func (m *RollbackConfig) Unmarshal(data []byte) error { } return nil } -func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { - l := len(data) +func (m *RollingUpdateDeployment) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12343,7 +10450,7 @@ func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12371,7 +10478,7 @@ func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12386,9 +10493,9 @@ func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.MaxUnavailable == nil { - m.MaxUnavailable = &k8s_io_kubernetes_pkg_util_intstr.IntOrString{} + m.MaxUnavailable = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} } - if err := m.MaxUnavailable.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.MaxUnavailable.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12404,7 +10511,7 @@ func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12419,15 +10526,15 @@ func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.MaxSurge == nil { - m.MaxSurge = &k8s_io_kubernetes_pkg_util_intstr.IntOrString{} + m.MaxSurge = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} } - if err := m.MaxSurge.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.MaxSurge.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12446,8 +10553,8 @@ func (m *RollingUpdateDeployment) Unmarshal(data []byte) error { } return nil } -func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *RunAsUserStrategyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12459,7 +10566,7 @@ func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12487,7 +10594,7 @@ func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12502,7 +10609,7 @@ func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Rule = RunAsUserStrategy(data[iNdEx:postIndex]) + m.Rule = RunAsUserStrategy(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -12516,7 +10623,7 @@ func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12531,13 +10638,13 @@ func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ranges = append(m.Ranges, IDRange{}) - if err := m.Ranges[len(m.Ranges)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ranges[len(m.Ranges)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12556,8 +10663,8 @@ func (m *RunAsUserStrategyOptions) Unmarshal(data []byte) error { } return nil } -func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *SELinuxStrategyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12569,7 +10676,7 @@ func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12597,7 +10704,7 @@ func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12612,7 +10719,7 @@ func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Rule = SELinuxStrategy(data[iNdEx:postIndex]) + m.Rule = SELinuxStrategy(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -12626,7 +10733,7 @@ func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12643,13 +10750,13 @@ func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { if m.SELinuxOptions == nil { m.SELinuxOptions = &k8s_io_kubernetes_pkg_api_v1.SELinuxOptions{} } - if err := m.SELinuxOptions.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.SELinuxOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12668,8 +10775,8 @@ func (m *SELinuxStrategyOptions) Unmarshal(data []byte) error { } return nil } -func (m *Scale) Unmarshal(data []byte) error { - l := len(data) +func (m *Scale) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12681,7 +10788,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12709,7 +10816,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12723,7 +10830,7 @@ func (m *Scale) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12739,7 +10846,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12753,7 +10860,7 @@ func (m *Scale) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -12769,7 +10876,7 @@ func (m *Scale) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12783,13 +10890,13 @@ func (m *Scale) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12808,8 +10915,8 @@ func (m *Scale) Unmarshal(data []byte) error { } return nil } -func (m *ScaleSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *ScaleSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12821,7 +10928,7 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12849,7 +10956,7 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12858,7 +10965,7 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -12877,8 +10984,8 @@ func (m *ScaleSpec) Unmarshal(data []byte) error { } return nil } -func (m *ScaleStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *ScaleStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -12890,7 +10997,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12918,7 +11025,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.Replicas |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -12937,7 +11044,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -12959,7 +11066,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12974,7 +11081,7 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -12989,222 +11096,61 @@ func (m *ScaleStatus) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF - } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue if m.Selector == nil { m.Selector = make(map[string]string) } - m.Selector[mapkey] = mapvalue - iNdEx = postIndex - case 3: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.TargetSelector = string(data[iNdEx:postIndex]) - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func (m *SubresourceReference) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: SubresourceReference: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: SubresourceReference: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Kind = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Selector[mapkey] = mapvalue + } else { + var mapvalue string + m.Selector[mapkey] = mapvalue } - m.Name = string(data[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field APIVersion", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.APIVersion = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 4: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Subresource", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field TargetSelector", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -13214,7 +11160,7 @@ func (m *SubresourceReference) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13229,11 +11175,11 @@ func (m *SubresourceReference) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Subresource = string(data[iNdEx:postIndex]) + m.TargetSelector = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13252,8 +11198,8 @@ func (m *SubresourceReference) Unmarshal(data []byte) error { } return nil } -func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { - l := len(data) +func (m *SupplementalGroupsStrategyOptions) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13265,7 +11211,7 @@ func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13293,7 +11239,7 @@ func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13308,7 +11254,7 @@ func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Rule = SupplementalGroupsStrategyType(data[iNdEx:postIndex]) + m.Rule = SupplementalGroupsStrategyType(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -13322,7 +11268,7 @@ func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13337,13 +11283,13 @@ func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Ranges = append(m.Ranges, IDRange{}) - if err := m.Ranges[len(m.Ranges)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Ranges[len(m.Ranges)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13362,8 +11308,8 @@ func (m *SupplementalGroupsStrategyOptions) Unmarshal(data []byte) error { } return nil } -func (m *ThirdPartyResource) Unmarshal(data []byte) error { - l := len(data) +func (m *ThirdPartyResource) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13375,7 +11321,7 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13403,7 +11349,7 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13417,7 +11363,7 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13433,7 +11379,7 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13448,7 +11394,7 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Description = string(data[iNdEx:postIndex]) + m.Description = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -13462,7 +11408,7 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13477,13 +11423,13 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Versions = append(m.Versions, APIVersion{}) - if err := m.Versions[len(m.Versions)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Versions[len(m.Versions)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13502,8 +11448,8 @@ func (m *ThirdPartyResource) Unmarshal(data []byte) error { } return nil } -func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { - l := len(data) +func (m *ThirdPartyResourceData) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13515,7 +11461,7 @@ func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13543,7 +11489,7 @@ func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13557,7 +11503,7 @@ func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13573,7 +11519,7 @@ func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ byteLen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13587,14 +11533,14 @@ func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Data = append(m.Data[:0], data[iNdEx:postIndex]...) + m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...) if m.Data == nil { m.Data = []byte{} } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13613,8 +11559,8 @@ func (m *ThirdPartyResourceData) Unmarshal(data []byte) error { } return nil } -func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { - l := len(data) +func (m *ThirdPartyResourceDataList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13626,7 +11572,7 @@ func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13654,7 +11600,7 @@ func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13668,7 +11614,7 @@ func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13684,7 +11630,7 @@ func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13699,13 +11645,13 @@ func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ThirdPartyResourceData{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13724,8 +11670,8 @@ func (m *ThirdPartyResourceDataList) Unmarshal(data []byte) error { } return nil } -func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { - l := len(data) +func (m *ThirdPartyResourceList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -13737,7 +11683,7 @@ func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13765,7 +11711,7 @@ func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13779,7 +11725,7 @@ func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -13795,7 +11741,7 @@ func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13810,13 +11756,13 @@ func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ThirdPartyResource{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -13835,8 +11781,8 @@ func (m *ThirdPartyResourceList) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -13847,7 +11793,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13865,7 +11811,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -13882,7 +11828,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -13905,7 +11851,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -13916,7 +11862,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -13940,251 +11886,223 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 3908 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xe4, 0x5b, 0x5d, 0x6c, 0x24, 0xd9, - 0x55, 0x9e, 0xea, 0x76, 0xdb, 0xed, 0xd3, 0x63, 0x8f, 0xe7, 0x8e, 0xc7, 0xd3, 0xeb, 0xdd, 0x75, - 0x4f, 0x6a, 0xc5, 0x66, 0x22, 0x76, 0xdb, 0xcc, 0xb0, 0x13, 0x36, 0xbb, 0x9b, 0x4d, 0xdc, 0xf6, - 0xfc, 0x62, 0xcf, 0x74, 0x6e, 0xdb, 0x93, 0x21, 0xd9, 0x6c, 0xa8, 0xee, 0xba, 0x6e, 0xd7, 0xba, - 0xfe, 0xb6, 0xea, 0x96, 0xd7, 0x9d, 0x08, 0x25, 0x12, 0xe2, 0x35, 0xe4, 0x0d, 0x24, 0xe0, 0x81, - 0x07, 0xc4, 0x13, 0x11, 0x11, 0x48, 0x91, 0x78, 0x02, 0x04, 0x62, 0x91, 0x40, 0x04, 0x24, 0x04, - 0x0f, 0xd0, 0xcb, 0x3a, 0x42, 0x11, 0xef, 0x08, 0xa4, 0xe1, 0x05, 0xdd, 0x5b, 0xb7, 0x7e, 0xbb, - 0xaa, 0xc7, 0xd5, 0xfe, 0x91, 0x10, 0x6f, 0xdd, 0xf7, 0x9e, 0xf3, 0x9d, 0x73, 0x4f, 0x9d, 0x3a, - 0xe7, 0xdc, 0x7b, 0x4f, 0xc1, 0x17, 0xf7, 0xdf, 0x74, 0x9b, 0x9a, 0xb5, 0xba, 0xef, 0x75, 0x89, - 0x63, 0x12, 0x4a, 0xdc, 0x55, 0x7b, 0xbf, 0xbf, 0xaa, 0xd8, 0x9a, 0xbb, 0x4a, 0x0e, 0x29, 0x31, - 0x5d, 0xcd, 0x32, 0xdd, 0xd5, 0x83, 0x9b, 0x5d, 0x42, 0x95, 0x9b, 0xab, 0x7d, 0x62, 0x12, 0x47, - 0xa1, 0x44, 0x6d, 0xda, 0x8e, 0x45, 0x2d, 0xf4, 0xba, 0xcf, 0xde, 0x8c, 0xd8, 0x9b, 0xf6, 0x7e, - 0xbf, 0xc9, 0xd8, 0x9b, 0x11, 0x7b, 0x53, 0xb0, 0x2f, 0xbf, 0xde, 0xd7, 0xe8, 0x9e, 0xd7, 0x6d, - 0xf6, 0x2c, 0x63, 0xb5, 0x6f, 0xf5, 0xad, 0x55, 0x8e, 0xd2, 0xf5, 0x76, 0xf9, 0x3f, 0xfe, 0x87, - 0xff, 0xf2, 0xd1, 0x97, 0x6f, 0xe5, 0x2a, 0xb7, 0xea, 0x10, 0xd7, 0xf2, 0x9c, 0x1e, 0x49, 0x6b, - 0xb4, 0x7c, 0x3b, 0x9f, 0xc7, 0x33, 0x0f, 0x88, 0xc3, 0x14, 0x22, 0xea, 0x08, 0xdb, 0x6b, 0xf9, - 0x6c, 0x07, 0x23, 0xcb, 0x5e, 0x7e, 0x3d, 0x9b, 0xda, 0xf1, 0x4c, 0xaa, 0x19, 0xa3, 0x3a, 0xdd, - 0xcc, 0x26, 0xf7, 0xa8, 0xa6, 0xaf, 0x6a, 0x26, 0x75, 0xa9, 0x93, 0x66, 0x91, 0x9b, 0x00, 0x6b, - 0xed, 0x07, 0x4f, 0x7c, 0x7d, 0xd1, 0x75, 0x98, 0x32, 0x15, 0x83, 0xd4, 0xa5, 0xeb, 0xd2, 0x8d, - 0xd9, 0xd6, 0xc5, 0x8f, 0x87, 0x8d, 0x0b, 0x47, 0xc3, 0xc6, 0xd4, 0x23, 0xc5, 0x20, 0x98, 0xcf, - 0xc8, 0xef, 0xc1, 0xe2, 0x7a, 0x7b, 0x67, 0x5b, 0x71, 0xfa, 0x84, 0xee, 0x50, 0x4d, 0xd7, 0xbe, - 0xa5, 0x50, 0xc6, 0xb9, 0x01, 0x0b, 0x94, 0x0f, 0xb6, 0x89, 0xd3, 0x23, 0x26, 0x55, 0xfa, 0x3e, - 0x4a, 0xa5, 0x55, 0x17, 0x28, 0x0b, 0xdb, 0xa9, 0x79, 0x3c, 0xc2, 0x21, 0xff, 0x86, 0x04, 0x2f, - 0xac, 0x7b, 0x2e, 0xb5, 0x8c, 0x2d, 0x42, 0x1d, 0xad, 0xb7, 0xee, 0x39, 0x0e, 0x31, 0x69, 0x87, - 0x2a, 0xd4, 0x73, 0x9f, 0xaf, 0x1d, 0x7a, 0x0a, 0x95, 0x03, 0x45, 0xf7, 0x48, 0xbd, 0x74, 0x5d, - 0xba, 0x51, 0xbb, 0xf5, 0x5a, 0x33, 0xd7, 0x6d, 0x9a, 0xc1, 0x83, 0x6d, 0x7e, 0xc5, 0x53, 0x4c, - 0xaa, 0xd1, 0x41, 0x6b, 0x51, 0x00, 0x5e, 0x14, 0x52, 0x9f, 0x30, 0x24, 0xec, 0x03, 0xca, 0xdf, - 0x93, 0xe0, 0xe5, 0x5c, 0xcd, 0x36, 0x35, 0x97, 0x22, 0x03, 0x2a, 0x1a, 0x25, 0x86, 0x5b, 0x97, - 0xae, 0x97, 0x6f, 0xd4, 0x6e, 0xdd, 0x6f, 0x16, 0x72, 0xd9, 0x66, 0x2e, 0x78, 0x6b, 0x4e, 0xe8, - 0x55, 0x79, 0xc0, 0xe0, 0xb1, 0x2f, 0x45, 0xfe, 0x75, 0x09, 0x50, 0x9c, 0xc7, 0xb7, 0xee, 0x31, - 0x6c, 0xf4, 0xd5, 0x93, 0xd8, 0xe8, 0x8a, 0x00, 0xac, 0xf9, 0xe2, 0x12, 0x26, 0xfa, 0xae, 0x04, - 0x4b, 0xa3, 0x1a, 0x71, 0xdb, 0xec, 0x26, 0x6d, 0xb3, 0x76, 0x02, 0xdb, 0xf8, 0xa8, 0x39, 0x46, - 0xf9, 0x83, 0x12, 0xcc, 0x6e, 0x28, 0xc4, 0xb0, 0xcc, 0x0e, 0xa1, 0xe8, 0x29, 0x54, 0x0d, 0x42, - 0x15, 0x55, 0xa1, 0x0a, 0xb7, 0x47, 0xed, 0xd6, 0x8d, 0x31, 0x8b, 0x3d, 0xb8, 0xd9, 0x7c, 0xdc, - 0xfd, 0x80, 0xf4, 0xe8, 0x16, 0xa1, 0x4a, 0x0b, 0x09, 0x7c, 0x88, 0xc6, 0x70, 0x88, 0x86, 0xde, - 0x87, 0x29, 0xd7, 0x26, 0x3d, 0x61, 0xc2, 0x77, 0x0a, 0x2e, 0x27, 0xd4, 0xb0, 0x63, 0x93, 0x5e, - 0xf4, 0x8c, 0xd8, 0x3f, 0xcc, 0x71, 0xd1, 0x2e, 0x4c, 0xbb, 0xfc, 0xe1, 0xd7, 0xcb, 0x5c, 0xc2, - 0xbb, 0x13, 0x4b, 0xf0, 0x5d, 0x68, 0x5e, 0xc8, 0x98, 0xf6, 0xff, 0x63, 0x81, 0x2e, 0xff, 0xad, - 0x04, 0x73, 0x21, 0x2d, 0x7f, 0x52, 0xdf, 0x18, 0xb1, 0xd9, 0xea, 0x18, 0x9b, 0xc5, 0x22, 0x5d, - 0x93, 0xb1, 0x73, 0xd3, 0x2d, 0x08, 0x61, 0xd5, 0x60, 0x24, 0x66, 0xb8, 0x6f, 0x04, 0x8e, 0x50, - 0xe2, 0x8e, 0xf0, 0xe6, 0xa4, 0xeb, 0xca, 0x79, 0xfe, 0x7f, 0x13, 0x5f, 0x0f, 0xb3, 0x27, 0x7a, - 0x1f, 0xaa, 0x2e, 0xd1, 0x49, 0x8f, 0x5a, 0x8e, 0x58, 0xcf, 0x1b, 0xc7, 0x5d, 0x8f, 0xd2, 0x25, - 0x7a, 0x47, 0xf0, 0xb6, 0x2e, 0xb2, 0x05, 0x05, 0xff, 0x70, 0x88, 0x89, 0xbe, 0x0e, 0x55, 0x4a, - 0x0c, 0x5b, 0x57, 0x68, 0xf0, 0x42, 0xbd, 0x3e, 0xde, 0xc7, 0xda, 0x96, 0xba, 0x2d, 0x18, 0xf8, - 0xe3, 0x0f, 0xad, 0x15, 0x8c, 0xe2, 0x10, 0x50, 0xfe, 0x8b, 0x12, 0x5c, 0x4a, 0x3d, 0x4a, 0xf4, - 0x04, 0x96, 0x7a, 0x7e, 0x78, 0x78, 0xe4, 0x19, 0x5d, 0xe2, 0x74, 0x7a, 0x7b, 0x44, 0xf5, 0x74, - 0xa2, 0x8a, 0x70, 0xbb, 0x22, 0xf0, 0x96, 0xd6, 0x33, 0xa9, 0x70, 0x0e, 0x37, 0x7a, 0x08, 0xc8, - 0xe4, 0x43, 0x5b, 0x9a, 0xeb, 0x86, 0x98, 0x25, 0x8e, 0xb9, 0x2c, 0x30, 0xd1, 0xa3, 0x11, 0x0a, - 0x9c, 0xc1, 0xc5, 0x74, 0x54, 0x89, 0xab, 0x39, 0x44, 0x4d, 0xeb, 0x58, 0x4e, 0xea, 0xb8, 0x91, - 0x49, 0x85, 0x73, 0xb8, 0xd1, 0x6d, 0xa8, 0xf9, 0xd2, 0x30, 0x51, 0xd4, 0x41, 0x7d, 0x8a, 0x83, - 0x85, 0x21, 0xe9, 0x51, 0x34, 0x85, 0xe3, 0x74, 0xf2, 0x1f, 0x96, 0x00, 0x36, 0x88, 0xad, 0x5b, - 0x03, 0x83, 0x98, 0x67, 0x19, 0x16, 0xbe, 0x99, 0x08, 0x0b, 0x5f, 0x2c, 0xea, 0xdc, 0xa1, 0x8a, - 0xb9, 0x71, 0xa1, 0x9f, 0x8a, 0x0b, 0x5f, 0x9a, 0x5c, 0xc4, 0xf8, 0xc0, 0xf0, 0x93, 0x32, 0x5c, - 0x89, 0x88, 0xd7, 0x2d, 0x53, 0xd5, 0x78, 0x9a, 0x7f, 0x1b, 0xa6, 0xe8, 0xc0, 0x0e, 0xd2, 0xcb, - 0x67, 0x03, 0x15, 0xb7, 0x07, 0x36, 0x79, 0x36, 0x6c, 0x5c, 0xcb, 0x60, 0x61, 0x53, 0x98, 0x33, - 0xa1, 0x27, 0xa1, 0xf6, 0x25, 0xce, 0xfe, 0x6e, 0x52, 0xf8, 0xb3, 0x61, 0x63, 0x6c, 0x75, 0xd4, - 0x0c, 0x31, 0x93, 0xca, 0xa2, 0x57, 0x61, 0xda, 0x21, 0x8a, 0x6b, 0x99, 0xdc, 0x23, 0x66, 0xa3, - 0x45, 0x61, 0x3e, 0x8a, 0xc5, 0x2c, 0xfa, 0x1c, 0xcc, 0x18, 0xc4, 0x75, 0x59, 0x69, 0x52, 0xe1, - 0x84, 0x97, 0x04, 0xe1, 0xcc, 0x96, 0x3f, 0x8c, 0x83, 0x79, 0xb4, 0x0f, 0xf3, 0xba, 0xe2, 0xd2, - 0x1d, 0x5b, 0x55, 0x28, 0xd9, 0xd6, 0x0c, 0x52, 0x9f, 0xe6, 0x06, 0xff, 0xd9, 0x63, 0x06, 0x0f, - 0xc6, 0xd2, 0x5a, 0x12, 0xf0, 0xf3, 0x9b, 0x09, 0x28, 0x9c, 0x82, 0x46, 0x1f, 0x01, 0x62, 0x23, - 0xdb, 0x8e, 0x62, 0xba, 0xbe, 0xcd, 0x98, 0xc0, 0x99, 0xe2, 0x02, 0xc3, 0xf7, 0x74, 0x73, 0x04, - 0x0e, 0x67, 0x88, 0x90, 0xff, 0x4e, 0x82, 0xf9, 0xe8, 0x91, 0x9d, 0x47, 0xfc, 0x7f, 0x3f, 0x19, - 0xff, 0xbf, 0x30, 0xb1, 0xff, 0xe6, 0x24, 0x80, 0xdf, 0x2c, 0x03, 0x8a, 0x88, 0xb0, 0xa5, 0xeb, - 0x5d, 0xa5, 0xb7, 0x7f, 0x8c, 0xaa, 0xe8, 0xf7, 0x24, 0x40, 0x1e, 0x7f, 0x24, 0xea, 0x9a, 0x69, - 0x5a, 0x94, 0x57, 0xb5, 0x81, 0x9a, 0xbf, 0x34, 0xb1, 0x9a, 0x81, 0x06, 0xcd, 0x9d, 0x11, 0xec, - 0x3b, 0x26, 0x75, 0x06, 0xd1, 0x23, 0x1b, 0x25, 0xc0, 0x19, 0x0a, 0xa1, 0x0f, 0x01, 0x1c, 0x81, - 0xb9, 0x6d, 0x89, 0x28, 0x50, 0x34, 0xd0, 0x04, 0x4a, 0xad, 0x5b, 0xe6, 0xae, 0xd6, 0x8f, 0x62, - 0x1a, 0x0e, 0x81, 0x71, 0x4c, 0xc8, 0xf2, 0x1d, 0xb8, 0x96, 0xa3, 0x3d, 0x5a, 0x80, 0xf2, 0x3e, - 0x19, 0xf8, 0x66, 0xc5, 0xec, 0x27, 0x5a, 0x8c, 0x57, 0x97, 0xb3, 0xa2, 0x34, 0x7c, 0xab, 0xf4, - 0xa6, 0x24, 0xff, 0xb4, 0x12, 0x77, 0x36, 0x9e, 0x9c, 0x6f, 0x40, 0xd5, 0x21, 0xb6, 0xae, 0xf5, - 0x14, 0x57, 0x64, 0x2f, 0x9e, 0x66, 0xb1, 0x18, 0xc3, 0xe1, 0x6c, 0x22, 0x8d, 0x97, 0xce, 0x38, - 0x8d, 0x97, 0x4f, 0x39, 0x8d, 0x23, 0x0b, 0xaa, 0x2e, 0x65, 0x9b, 0xae, 0xbe, 0x9f, 0xb3, 0x8a, - 0x17, 0xc0, 0xf1, 0xb8, 0xed, 0x03, 0x45, 0x02, 0x83, 0x11, 0x1c, 0x0a, 0x41, 0x6b, 0x70, 0xc9, - 0xd0, 0x4c, 0x9e, 0xfc, 0x3a, 0xa4, 0x67, 0x99, 0xaa, 0xcb, 0x03, 0x5e, 0xa5, 0x75, 0x4d, 0x30, - 0x5d, 0xda, 0x4a, 0x4e, 0xe3, 0x34, 0x3d, 0xda, 0x84, 0x45, 0x87, 0x1c, 0x68, 0x4c, 0x8d, 0xfb, - 0x9a, 0x4b, 0x2d, 0x67, 0xb0, 0xa9, 0x19, 0x1a, 0xe5, 0x61, 0xb0, 0xd2, 0xaa, 0x1f, 0x0d, 0x1b, - 0x8b, 0x38, 0x63, 0x1e, 0x67, 0x72, 0xb1, 0x08, 0x6d, 0x2b, 0x9e, 0x4b, 0x54, 0x1e, 0xd5, 0xaa, - 0x51, 0x84, 0x6e, 0xf3, 0x51, 0x2c, 0x66, 0x91, 0x91, 0xf0, 0xee, 0xea, 0x69, 0x78, 0xf7, 0x7c, - 0xbe, 0x67, 0xa3, 0x1d, 0xb8, 0x66, 0x3b, 0x56, 0xdf, 0x21, 0xae, 0xbb, 0x41, 0x14, 0x55, 0xd7, - 0x4c, 0x12, 0xd8, 0x6b, 0x96, 0xaf, 0xf3, 0xc5, 0xa3, 0x61, 0xe3, 0x5a, 0x3b, 0x9b, 0x04, 0xe7, - 0xf1, 0xca, 0x9f, 0x94, 0x61, 0x21, 0x9d, 0x69, 0x59, 0x7d, 0x65, 0x75, 0x5d, 0xe2, 0x1c, 0x10, - 0xf5, 0x9e, 0xbf, 0x07, 0xd7, 0x2c, 0x93, 0x7b, 0x7d, 0x39, 0x0a, 0x02, 0x8f, 0x47, 0x28, 0x70, - 0x06, 0x17, 0x7a, 0x2d, 0xf6, 0xde, 0xf8, 0x15, 0x5a, 0xe8, 0x0d, 0x19, 0xef, 0xce, 0x1a, 0x5c, - 0x12, 0x81, 0x24, 0x98, 0x14, 0x65, 0x58, 0xe8, 0x0d, 0x3b, 0xc9, 0x69, 0x9c, 0xa6, 0x47, 0xf7, - 0xe0, 0xb2, 0x72, 0xa0, 0x68, 0xba, 0xd2, 0xd5, 0x49, 0x08, 0xe2, 0x97, 0x5f, 0x2f, 0x08, 0x90, - 0xcb, 0x6b, 0x69, 0x02, 0x3c, 0xca, 0x83, 0xb6, 0xe0, 0x8a, 0x67, 0x8e, 0x42, 0xf9, 0xde, 0xf9, - 0xa2, 0x80, 0xba, 0xb2, 0x33, 0x4a, 0x82, 0xb3, 0xf8, 0xd0, 0x01, 0x40, 0x2f, 0x28, 0x0a, 0xdc, - 0xfa, 0x34, 0x0f, 0xd6, 0xad, 0x89, 0xdf, 0xad, 0xb0, 0xbe, 0x88, 0x42, 0x62, 0x38, 0xe4, 0xe2, - 0x98, 0x24, 0xf9, 0xef, 0xa5, 0x78, 0x9a, 0x09, 0xde, 0x40, 0xf4, 0x56, 0xa2, 0x3a, 0x7a, 0x35, - 0x55, 0x1d, 0x2d, 0x8d, 0x72, 0xc4, 0x8a, 0xa3, 0xef, 0xc0, 0x1c, 0xf3, 0x4c, 0xcd, 0xec, 0xfb, - 0x4f, 0x43, 0x84, 0xb9, 0xbb, 0x13, 0x78, 0x7f, 0x88, 0x11, 0x4b, 0x97, 0x97, 0x8f, 0x86, 0x8d, - 0xb9, 0xc4, 0x24, 0x4e, 0xca, 0x93, 0xdf, 0x83, 0xb9, 0x3b, 0x87, 0xb6, 0xe5, 0xd0, 0xc7, 0xb6, - 0x9f, 0x6a, 0x5e, 0x85, 0x69, 0xc2, 0x07, 0xf8, 0x7a, 0x62, 0x2f, 0xad, 0x4f, 0x86, 0xc5, 0x2c, - 0x7a, 0x05, 0x2a, 0xe4, 0x50, 0xe9, 0x51, 0xae, 0x71, 0x35, 0x4a, 0xcc, 0x77, 0xd8, 0x20, 0xf6, - 0xe7, 0xe4, 0x1f, 0x4a, 0xb0, 0x74, 0xb7, 0x73, 0xcf, 0xb1, 0x3c, 0x3b, 0x58, 0x7c, 0x20, 0xe7, - 0x17, 0x60, 0xca, 0xf1, 0xf4, 0xc0, 0x6a, 0xaf, 0x04, 0x56, 0xc3, 0x9e, 0xce, 0xac, 0x76, 0x25, - 0xc5, 0xe5, 0x9b, 0x8c, 0x31, 0xa0, 0xf7, 0x61, 0xda, 0x51, 0xcc, 0x3e, 0x09, 0xd2, 0xf4, 0xe7, - 0x0b, 0xda, 0xea, 0xc1, 0x06, 0x66, 0xec, 0xb1, 0x7a, 0x91, 0xa3, 0x61, 0x81, 0x2a, 0xff, 0x8e, - 0x04, 0x97, 0xee, 0x6f, 0x6f, 0xb7, 0x1f, 0x98, 0xfc, 0x35, 0x6f, 0x2b, 0x74, 0x8f, 0x55, 0x12, - 0xb6, 0x42, 0xf7, 0xd2, 0x95, 0x04, 0x9b, 0xc3, 0x7c, 0x06, 0xed, 0xc1, 0x0c, 0x0b, 0x2f, 0xc4, - 0x54, 0x27, 0xdc, 0x07, 0x08, 0x71, 0x2d, 0x1f, 0x24, 0x2a, 0x52, 0xc5, 0x00, 0x0e, 0xe0, 0xe5, - 0x6f, 0xc3, 0x62, 0x4c, 0x3d, 0x66, 0x2f, 0x7e, 0x1e, 0x83, 0x7a, 0x50, 0x61, 0x9a, 0x04, 0xa7, - 0x2d, 0x45, 0x0f, 0x0f, 0x52, 0x4b, 0x8e, 0x1e, 0x28, 0xfb, 0xe7, 0x62, 0x1f, 0x5b, 0xfe, 0xa7, - 0x12, 0x5c, 0xbb, 0x6f, 0x39, 0xda, 0xb7, 0x2c, 0x93, 0x2a, 0x7a, 0xdb, 0x52, 0xd7, 0x3c, 0x6a, - 0xb9, 0x3d, 0x45, 0x27, 0xce, 0x19, 0xee, 0xb0, 0xf4, 0xc4, 0x0e, 0xeb, 0x61, 0xd1, 0x95, 0x65, - 0xeb, 0x9b, 0xbb, 0xdd, 0xa2, 0xa9, 0xed, 0xd6, 0xe6, 0x29, 0xc9, 0x1b, 0xbf, 0xf7, 0xfa, 0x0f, - 0x09, 0x5e, 0xcc, 0xe1, 0x3c, 0x8f, 0x12, 0x7d, 0x3f, 0x59, 0xa2, 0xdf, 0x3d, 0x9d, 0x35, 0xe7, - 0xd4, 0xeb, 0xff, 0x53, 0xca, 0x5d, 0x2b, 0xaf, 0x10, 0x3f, 0x84, 0x2a, 0xff, 0x87, 0xc9, 0xae, - 0x58, 0xeb, 0x7a, 0x41, 0x7d, 0x3a, 0x5e, 0x37, 0x38, 0xc6, 0xc4, 0x64, 0x97, 0x38, 0xc4, 0xec, - 0x91, 0x58, 0xf1, 0x24, 0xc0, 0x71, 0x28, 0x06, 0xdd, 0x84, 0x1a, 0x2f, 0x86, 0x12, 0xf9, 0xf5, - 0xd2, 0xd1, 0xb0, 0x51, 0xdb, 0x8a, 0x86, 0x71, 0x9c, 0x06, 0xdd, 0x86, 0x9a, 0xa1, 0x1c, 0xa6, - 0xb2, 0x6b, 0x78, 0x2e, 0xb1, 0x15, 0x4d, 0xe1, 0x38, 0x1d, 0xfa, 0x0e, 0xcc, 0xf7, 0x6c, 0x2f, - 0x76, 0x8a, 0x2e, 0xaa, 0xc3, 0xa2, 0x4b, 0xcc, 0x3a, 0x90, 0x6f, 0x21, 0xb6, 0xf1, 0x5c, 0x6f, - 0xef, 0xc4, 0xc6, 0x70, 0x4a, 0x9c, 0xfc, 0xe7, 0x65, 0x78, 0x79, 0xac, 0x8f, 0xa2, 0xbb, 0x63, - 0xaa, 0x96, 0xa5, 0x02, 0x15, 0x8b, 0x0a, 0x73, 0x6c, 0xff, 0xc9, 0xcd, 0xcd, 0x77, 0xb7, 0xa5, - 0xe2, 0xbb, 0x5b, 0x9e, 0xc2, 0x36, 0xe3, 0x28, 0x38, 0x09, 0xca, 0x2a, 0x1d, 0x71, 0xba, 0x95, - 0x57, 0xe9, 0xac, 0x27, 0xa7, 0x71, 0x9a, 0x9e, 0x41, 0x88, 0xc3, 0xa7, 0x54, 0x9d, 0x13, 0x42, - 0x6c, 0x24, 0xa7, 0x71, 0x9a, 0x1e, 0x19, 0xd0, 0x10, 0xa8, 0x49, 0xf3, 0xc7, 0x6e, 0x46, 0xfc, - 0x7a, 0xe7, 0x95, 0xa3, 0x61, 0xa3, 0xb1, 0x3e, 0x9e, 0x14, 0x3f, 0x0f, 0x4b, 0xde, 0x82, 0xb9, - 0xfb, 0x96, 0x4b, 0xdb, 0x2c, 0x25, 0xb3, 0xbc, 0x85, 0x5e, 0x86, 0xb2, 0xa1, 0x99, 0x62, 0x43, - 0x55, 0x13, 0x6a, 0x97, 0x99, 0xf3, 0xb2, 0x71, 0x3e, 0xad, 0x1c, 0x0a, 0xbf, 0x8e, 0xa6, 0x95, - 0x43, 0xcc, 0xc6, 0xe5, 0x7b, 0x30, 0x23, 0xf2, 0x62, 0x1c, 0xa8, 0x3c, 0x1e, 0xa8, 0x9c, 0x01, - 0xf4, 0xfb, 0x25, 0x98, 0x11, 0x69, 0xe4, 0x0c, 0x13, 0xc2, 0x7b, 0x89, 0x84, 0xf0, 0xd6, 0x64, - 0xa9, 0x36, 0x37, 0x01, 0xa8, 0xa9, 0x04, 0xf0, 0xce, 0x84, 0xf8, 0xe3, 0x03, 0xfe, 0x0f, 0x24, - 0x98, 0x4f, 0x26, 0x7d, 0x16, 0x51, 0xd8, 0x3b, 0xa4, 0xf5, 0xc8, 0xa3, 0xe8, 0xdc, 0x22, 0x8c, - 0x28, 0x9d, 0x68, 0x0a, 0xc7, 0xe9, 0x10, 0x09, 0xd9, 0x98, 0x3b, 0x08, 0xa3, 0x34, 0x73, 0x94, - 0xf6, 0xa8, 0xa6, 0x37, 0xfd, 0x6b, 0xc1, 0xe6, 0x03, 0x93, 0x3e, 0x76, 0x3a, 0xd4, 0xd1, 0xcc, - 0xfe, 0x88, 0x18, 0xee, 0x59, 0x71, 0x5c, 0xf9, 0xaf, 0x25, 0xa8, 0x09, 0x85, 0xcf, 0x23, 0x23, - 0x7d, 0x3d, 0x99, 0x91, 0x3e, 0x3f, 0x61, 0x3d, 0x95, 0x9d, 0x81, 0x7e, 0x14, 0xad, 0x85, 0x55, - 0x50, 0xac, 0xc0, 0xdb, 0xb3, 0x5c, 0x9a, 0x2e, 0xf0, 0xd8, 0x2b, 0x86, 0xf9, 0x0c, 0xfa, 0x35, - 0x09, 0x16, 0xb4, 0x54, 0xcd, 0x25, 0x4c, 0xfd, 0xa5, 0xc9, 0x54, 0x0b, 0x61, 0xa2, 0xcb, 0xd2, - 0xf4, 0x0c, 0x1e, 0x11, 0x29, 0x7b, 0x30, 0x42, 0x85, 0x14, 0x98, 0xda, 0xa3, 0xd4, 0x9e, 0x30, - 0x57, 0x66, 0x55, 0x93, 0xad, 0x2a, 0x5f, 0xfe, 0xf6, 0x76, 0x1b, 0x73, 0x68, 0xf9, 0x07, 0xa5, - 0xd0, 0x60, 0x1d, 0xff, 0x1d, 0x09, 0xeb, 0x5d, 0xe9, 0x34, 0xea, 0xdd, 0x5a, 0x56, 0xad, 0x8b, - 0x9e, 0x42, 0x99, 0xea, 0x93, 0x1e, 0x1b, 0x0a, 0x09, 0xdb, 0x9b, 0x9d, 0x28, 0x4e, 0x6d, 0x6f, - 0x76, 0x30, 0x83, 0x44, 0xdf, 0x84, 0x0a, 0xdb, 0x4d, 0xb0, 0x57, 0xbc, 0x3c, 0x79, 0x08, 0x61, - 0xf6, 0x8a, 0x3c, 0x8c, 0xfd, 0x73, 0xb1, 0x8f, 0x2b, 0x7f, 0x1b, 0xe6, 0x12, 0x71, 0x00, 0x7d, - 0x00, 0x17, 0x75, 0x4b, 0x51, 0x5b, 0x8a, 0xae, 0x98, 0x3d, 0x12, 0xdc, 0x4b, 0xfd, 0xdc, 0xf8, - 0x88, 0xb8, 0x19, 0xe3, 0x10, 0xf1, 0x24, 0xbc, 0xb0, 0x8e, 0xcf, 0xe1, 0x04, 0xb6, 0xac, 0x00, - 0x44, 0xab, 0x47, 0x0d, 0xa8, 0x30, 0x17, 0xf6, 0x77, 0x06, 0xb3, 0xad, 0x59, 0xa6, 0x2b, 0xf3, - 0x6c, 0x17, 0xfb, 0xe3, 0xe8, 0x16, 0x80, 0x4b, 0x7a, 0x0e, 0xa1, 0x3c, 0xec, 0xf8, 0xc7, 0xf4, - 0x61, 0x00, 0xee, 0x84, 0x33, 0x38, 0x46, 0x25, 0xff, 0x56, 0x09, 0xca, 0x0f, 0xad, 0xee, 0x19, - 0x06, 0xf9, 0xa7, 0x89, 0x20, 0x5f, 0xf4, 0xfd, 0x7f, 0x68, 0x75, 0x73, 0x03, 0xfc, 0x2f, 0xa7, - 0x02, 0xfc, 0x9b, 0x13, 0x60, 0x8f, 0x0f, 0xee, 0xff, 0x50, 0x86, 0x8b, 0x0f, 0xad, 0x6e, 0x74, - 0x85, 0xf2, 0x46, 0xe2, 0x90, 0xe0, 0x7a, 0xea, 0x90, 0x60, 0x21, 0x4e, 0x7b, 0x0e, 0x77, 0x27, - 0x7b, 0x7e, 0x61, 0xd6, 0x76, 0xac, 0xae, 0x5f, 0x98, 0x95, 0x8b, 0x17, 0x66, 0x57, 0x85, 0x2e, - 0xbc, 0x38, 0x0b, 0x91, 0x70, 0x12, 0x38, 0xe7, 0x96, 0x63, 0xea, 0xcc, 0x6f, 0x39, 0x62, 0xd7, - 0x43, 0x95, 0xe3, 0x5e, 0x0f, 0x4d, 0x8f, 0xbf, 0x1e, 0x92, 0xff, 0x4c, 0x82, 0x99, 0x87, 0x56, - 0xf7, 0x3c, 0x92, 0xdf, 0x57, 0x93, 0xc9, 0xef, 0x56, 0x71, 0x07, 0xcd, 0x49, 0x7c, 0x7f, 0x54, - 0xe6, 0x6b, 0xe0, 0x31, 0xfc, 0x26, 0xd4, 0x6c, 0xc5, 0x51, 0x74, 0x9d, 0xe8, 0x9a, 0x6b, 0x88, - 0xd2, 0x91, 0xef, 0x79, 0xda, 0xd1, 0x30, 0x8e, 0xd3, 0x30, 0x96, 0x9e, 0x65, 0xd8, 0x3a, 0x09, - 0x2e, 0x4a, 0x42, 0x96, 0xf5, 0x68, 0x18, 0xc7, 0x69, 0xd0, 0x63, 0xb8, 0xaa, 0xf4, 0xa8, 0x76, - 0x40, 0xd2, 0x87, 0xad, 0x65, 0x5e, 0x42, 0xbe, 0x70, 0x34, 0x6c, 0x5c, 0x5d, 0xcb, 0x22, 0xc0, - 0xd9, 0x7c, 0x89, 0x5b, 0x81, 0xa9, 0x33, 0xb8, 0x15, 0x78, 0x03, 0x2e, 0x2a, 0x1e, 0xb5, 0x82, - 0x19, 0xee, 0x3f, 0xd5, 0xd6, 0x02, 0x0b, 0xb9, 0x6b, 0xb1, 0x71, 0x9c, 0xa0, 0x4a, 0xdc, 0x25, - 0x4c, 0x9f, 0x76, 0x4b, 0xc0, 0x9f, 0x96, 0x61, 0x36, 0x0c, 0x3a, 0xc8, 0x4a, 0x9c, 0x7f, 0xfa, - 0xc7, 0x3d, 0x6f, 0x17, 0xf7, 0x90, 0x63, 0x1f, 0x7c, 0xa2, 0xa7, 0x30, 0xeb, 0x52, 0xc5, 0xa1, - 0x93, 0xee, 0xe1, 0xe6, 0x8e, 0x86, 0x8d, 0xd9, 0x4e, 0x80, 0x80, 0x23, 0x30, 0xd4, 0x87, 0xf9, - 0xc8, 0x57, 0x26, 0x8d, 0x44, 0xfe, 0xa6, 0x37, 0x01, 0x83, 0x53, 0xb0, 0x2c, 0x1c, 0xf8, 0xde, - 0x24, 0x36, 0x76, 0x61, 0x38, 0xf0, 0x5d, 0x0f, 0x8b, 0x59, 0xb4, 0x0a, 0xb3, 0xae, 0xd7, 0xeb, - 0x11, 0xa2, 0x12, 0x55, 0x6c, 0xd8, 0x2e, 0x0b, 0xd2, 0xd9, 0x4e, 0x30, 0x81, 0x23, 0x1a, 0x06, - 0xbc, 0xab, 0x68, 0x3a, 0x51, 0xc5, 0x25, 0x49, 0x08, 0x7c, 0x97, 0x8f, 0x62, 0x31, 0xcb, 0x9b, - 0x6e, 0x1e, 0x11, 0xfa, 0x91, 0xe5, 0xec, 0xb7, 0x2d, 0x5d, 0xeb, 0x0d, 0xce, 0x30, 0x73, 0x76, - 0x13, 0x99, 0xf3, 0xcb, 0x05, 0x5d, 0x23, 0xa1, 0x65, 0x5e, 0x0e, 0x95, 0xff, 0x5d, 0x82, 0x7a, - 0x82, 0x32, 0x5e, 0x4e, 0x13, 0xa8, 0xd8, 0x96, 0x43, 0x03, 0xe7, 0x3c, 0x91, 0x06, 0x6c, 0xef, - 0x11, 0x3b, 0x8d, 0x64, 0xb0, 0xd8, 0x47, 0x67, 0xeb, 0xdc, 0x75, 0x2c, 0x43, 0x04, 0xc9, 0x93, - 0x49, 0x21, 0xc4, 0x89, 0xd6, 0x79, 0xd7, 0xb1, 0x0c, 0xcc, 0xb1, 0xe5, 0x7f, 0x94, 0xe0, 0x72, - 0x82, 0xf2, 0x3c, 0xc2, 0xbf, 0x92, 0x0c, 0xff, 0xef, 0x9c, 0x64, 0x65, 0x39, 0x89, 0xe0, 0xbf, - 0xd3, 0xeb, 0x62, 0x16, 0x40, 0x7d, 0xa8, 0xd9, 0x96, 0xda, 0x39, 0x8d, 0xde, 0x29, 0x3f, 0x91, - 0x44, 0x60, 0x38, 0x8e, 0x8c, 0x06, 0x70, 0xd9, 0x54, 0x0c, 0xe2, 0xda, 0x4a, 0x8f, 0x74, 0x4e, - 0xe3, 0x8e, 0xf7, 0xea, 0xd1, 0xb0, 0x71, 0xf9, 0x51, 0x1a, 0x12, 0x8f, 0x4a, 0x91, 0xff, 0x78, - 0x64, 0xe5, 0x96, 0x43, 0xd1, 0x57, 0xa0, 0xca, 0x7b, 0x63, 0x7b, 0x96, 0x2e, 0x8a, 0xb4, 0xdb, - 0xec, 0xe1, 0xb4, 0xc5, 0xd8, 0xb3, 0x61, 0xe3, 0x67, 0xc6, 0x96, 0x5a, 0x01, 0x21, 0x0e, 0x61, - 0xd0, 0x26, 0x4c, 0xd9, 0x93, 0x6f, 0xc8, 0xf9, 0x0e, 0x8c, 0xef, 0xc2, 0x39, 0x8a, 0xfc, 0x9f, - 0x69, 0xb5, 0x79, 0x0e, 0xdf, 0x3f, 0xbd, 0x07, 0x16, 0x9e, 0x00, 0xe4, 0x3e, 0x34, 0x07, 0x66, - 0xc4, 0x7e, 0x54, 0x38, 0xe6, 0xbd, 0x93, 0x38, 0x66, 0x7c, 0x0f, 0x15, 0x16, 0x5d, 0xc1, 0x60, - 0x20, 0x88, 0xbf, 0x7f, 0x5c, 0xa1, 0x9e, 0xe7, 0x68, 0x74, 0x70, 0xe6, 0xb1, 0x73, 0x37, 0x11, - 0x3b, 0x37, 0x0a, 0x2e, 0x70, 0x44, 0xd3, 0xdc, 0xf8, 0xf9, 0xaf, 0x12, 0x5c, 0x1d, 0xa1, 0x3e, - 0x8f, 0xd8, 0x42, 0x92, 0xb1, 0xe5, 0xcb, 0x27, 0x5d, 0x61, 0x4e, 0x7c, 0xf9, 0x18, 0x32, 0xd6, - 0xc7, 0x5d, 0xf6, 0x16, 0x80, 0xed, 0x68, 0x07, 0x9a, 0x4e, 0xfa, 0xa2, 0x7f, 0xb1, 0x1a, 0x3d, - 0x93, 0x76, 0x38, 0x83, 0x63, 0x54, 0xe8, 0x57, 0x60, 0x49, 0x25, 0xbb, 0x8a, 0xa7, 0xd3, 0x35, - 0x55, 0x5d, 0x57, 0x6c, 0xa5, 0xab, 0xe9, 0x1a, 0xd5, 0xc4, 0x25, 0xe0, 0x6c, 0xeb, 0x8e, 0xdf, - 0x57, 0x98, 0x45, 0xf1, 0x6c, 0xd8, 0xf8, 0xec, 0xf8, 0x4d, 0x52, 0x40, 0x3c, 0xc0, 0x39, 0x42, - 0xd0, 0xaf, 0x4a, 0x50, 0x77, 0xc8, 0x87, 0x9e, 0xe6, 0x10, 0x75, 0xc3, 0xb1, 0xec, 0x84, 0x06, - 0x65, 0xae, 0xc1, 0xbd, 0xa3, 0x61, 0xa3, 0x8e, 0x73, 0x68, 0x8a, 0xe8, 0x90, 0x2b, 0x08, 0x51, - 0xb8, 0xa2, 0xe8, 0xba, 0xf5, 0x11, 0x49, 0x5a, 0x60, 0x8a, 0xcb, 0x6f, 0x1d, 0x0d, 0x1b, 0x57, - 0xd6, 0x46, 0xa7, 0x8b, 0x88, 0xce, 0x82, 0x47, 0xab, 0x30, 0x73, 0x60, 0xe9, 0x9e, 0x41, 0xdc, - 0x7a, 0x85, 0x4b, 0x62, 0x91, 0x76, 0xe6, 0x89, 0x3f, 0xf4, 0x8c, 0x15, 0x3a, 0x1d, 0xbe, 0x63, - 0x0d, 0xa8, 0xd0, 0x6d, 0xa8, 0xed, 0x59, 0x2e, 0x15, 0xef, 0x3a, 0x2f, 0x8b, 0xaa, 0x51, 0x70, - 0xb9, 0x1f, 0x4d, 0xe1, 0x38, 0x1d, 0x32, 0x60, 0x76, 0x4f, 0x9c, 0x68, 0xbb, 0xf5, 0x99, 0x89, - 0xf2, 0x5e, 0xe2, 0x44, 0x3c, 0xaa, 0xdb, 0x82, 0x61, 0x17, 0x47, 0x12, 0xd8, 0xbe, 0x8f, 0xff, - 0x79, 0xb0, 0xc1, 0x3b, 0x4e, 0xaa, 0x51, 0x08, 0xba, 0xef, 0x0f, 0xe3, 0x60, 0x3e, 0x20, 0x7d, - 0xd0, 0x5e, 0xe7, 0x0d, 0x22, 0x29, 0xd2, 0x07, 0xed, 0x75, 0x1c, 0xcc, 0x23, 0x1b, 0x66, 0x5c, - 0xb2, 0xa9, 0x99, 0xde, 0x61, 0x1d, 0xf8, 0xab, 0x7b, 0xa7, 0xe8, 0xc5, 0xd5, 0x1d, 0xce, 0x9d, - 0xba, 0x2d, 0x8f, 0x24, 0x8a, 0x79, 0x1c, 0x88, 0x41, 0x87, 0x30, 0xeb, 0x78, 0xe6, 0x9a, 0xbb, - 0xe3, 0x12, 0xa7, 0x5e, 0xe3, 0x32, 0x8b, 0x46, 0x65, 0x1c, 0xf0, 0xa7, 0xa5, 0x86, 0x16, 0x0c, - 0x29, 0x70, 0x24, 0x0c, 0xfd, 0xb6, 0x04, 0xc8, 0xf5, 0x6c, 0x5b, 0x27, 0x06, 0x31, 0xa9, 0xa2, - 0xf3, 0x0b, 0x7b, 0xb7, 0x7e, 0x91, 0xeb, 0xd0, 0x2e, 0x7c, 0x61, 0x97, 0x06, 0x4a, 0x2b, 0x13, - 0x1e, 0x00, 0x8c, 0x92, 0xe2, 0x0c, 0x3d, 0xd8, 0xa3, 0xd8, 0x75, 0xf9, 0xef, 0xfa, 0xdc, 0x44, - 0x8f, 0x22, 0xbb, 0x71, 0x21, 0x7a, 0x14, 0x62, 0x1e, 0x07, 0x62, 0xd0, 0x13, 0x58, 0x72, 0x88, - 0xa2, 0x3e, 0x36, 0xf5, 0x01, 0xb6, 0x2c, 0x7a, 0x57, 0xd3, 0x89, 0x3b, 0x70, 0x29, 0x31, 0xea, - 0xf3, 0xdc, 0x6d, 0xc2, 0x06, 0x68, 0x9c, 0x49, 0x85, 0x73, 0xb8, 0x79, 0x27, 0xb3, 0xb8, 0x67, - 0x3a, 0xdb, 0x0f, 0x1c, 0x4e, 0xd6, 0xc9, 0x1c, 0xa9, 0x78, 0x66, 0x9d, 0xcc, 0x31, 0x11, 0xe3, - 0xcf, 0xdf, 0xfe, 0xab, 0x04, 0x57, 0x22, 0xe2, 0x63, 0x77, 0x32, 0x67, 0xb0, 0x9c, 0xc3, 0x69, - 0x5c, 0xf6, 0x19, 0x59, 0xf9, 0x3c, 0xcf, 0xc8, 0x4e, 0xab, 0x85, 0x9a, 0x37, 0x17, 0x47, 0x56, - 0xfc, 0x3f, 0xd0, 0x5c, 0x1c, 0x29, 0x9b, 0x53, 0xc8, 0xfc, 0x49, 0x29, 0xbe, 0xa2, 0xff, 0x4f, - 0x1d, 0xac, 0x19, 0x0d, 0xa5, 0x53, 0xc5, 0x1a, 0x4a, 0xe5, 0x7f, 0x29, 0xc3, 0x42, 0xfa, 0xa5, - 0x4d, 0x34, 0x32, 0x4a, 0xcf, 0x6d, 0x64, 0x6c, 0xc3, 0xe2, 0xae, 0xa7, 0xeb, 0x03, 0x6e, 0x90, - 0xd8, 0x05, 0xbd, 0x7f, 0xf6, 0xf8, 0x92, 0xe0, 0x5c, 0xbc, 0x9b, 0x41, 0x83, 0x33, 0x39, 0x73, - 0x9a, 0x32, 0xcb, 0x13, 0x35, 0x65, 0xbe, 0x0d, 0x73, 0x0e, 0xff, 0xf6, 0x24, 0xd9, 0x37, 0x10, - 0x1e, 0x8e, 0xe3, 0xf8, 0x24, 0x4e, 0xd2, 0x66, 0x37, 0x58, 0x56, 0x26, 0x68, 0xb0, 0x3c, 0x8d, - 0x8e, 0xc8, 0x8c, 0xd8, 0xf7, 0xdc, 0x8e, 0xc8, 0x97, 0x60, 0x59, 0xb0, 0xb1, 0xff, 0xeb, 0x96, - 0x49, 0x1d, 0x4b, 0xd7, 0x89, 0xb3, 0xe1, 0x19, 0xc6, 0x40, 0x7e, 0x17, 0xe6, 0x93, 0x6d, 0xb9, - 0xfe, 0x93, 0xf7, 0x3b, 0x85, 0x45, 0x83, 0x41, 0xec, 0xc9, 0xfb, 0xe3, 0x38, 0xa4, 0x90, 0x3f, - 0x91, 0xe0, 0x5a, 0x4e, 0x67, 0x23, 0xfa, 0x00, 0xe6, 0x0d, 0xe5, 0x30, 0xd6, 0x32, 0x2a, 0x42, - 0x4b, 0xd1, 0x5d, 0x36, 0x3f, 0x3b, 0xdc, 0x4a, 0x20, 0xe1, 0x14, 0x32, 0x4f, 0xb8, 0xca, 0x61, - 0xc7, 0x73, 0xfa, 0x64, 0xc2, 0xbd, 0x3c, 0x7f, 0x7d, 0xb7, 0x04, 0x06, 0x0e, 0xd1, 0xe4, 0x1f, - 0x4a, 0x50, 0xcf, 0xab, 0xbe, 0xd0, 0xed, 0x44, 0x87, 0xe4, 0x67, 0x52, 0x1d, 0x92, 0x97, 0x47, - 0xf8, 0xce, 0xa9, 0x3f, 0xf2, 0x47, 0x12, 0x2c, 0x65, 0x57, 0xa9, 0xe8, 0xe7, 0x13, 0x1a, 0x37, - 0x52, 0x1a, 0x5f, 0x4a, 0x71, 0x09, 0x7d, 0xf7, 0x60, 0x5e, 0xd4, 0xb2, 0x02, 0xe6, 0x18, 0x9f, - 0xa8, 0x1e, 0x84, 0x85, 0x72, 0x50, 0x95, 0xf1, 0xe7, 0x98, 0x1c, 0xc3, 0x29, 0x5c, 0xf9, 0x77, - 0x4b, 0x50, 0xe1, 0x6d, 0x43, 0x67, 0x58, 0x42, 0x7d, 0x2d, 0x51, 0x42, 0x15, 0xbd, 0x58, 0xe4, - 0xda, 0xe5, 0x56, 0x4f, 0xdd, 0x54, 0xf5, 0xf4, 0xd6, 0x44, 0xe8, 0xe3, 0x0b, 0xa7, 0x2f, 0xc0, - 0x6c, 0xa8, 0x44, 0xb1, 0x40, 0xcd, 0xca, 0xd4, 0x5a, 0x4c, 0x44, 0xc1, 0x30, 0x7f, 0x90, 0xc8, - 0x94, 0x93, 0x7c, 0x4b, 0x1d, 0x93, 0xdd, 0x0c, 0x52, 0xa5, 0xff, 0xb9, 0x4d, 0xd4, 0xf8, 0x37, - 0x9a, 0x41, 0xdf, 0x85, 0x79, 0xff, 0x83, 0xf4, 0xf0, 0x0c, 0xad, 0xcc, 0xbd, 0x37, 0xfc, 0x8c, - 0x6b, 0x3b, 0x31, 0x8b, 0x53, 0xd4, 0xcb, 0x6f, 0xc3, 0x5c, 0x42, 0x58, 0xa1, 0xaf, 0x63, 0xfe, - 0x52, 0x82, 0xc5, 0xac, 0x56, 0x45, 0x74, 0x1d, 0xa6, 0xf6, 0x35, 0xd1, 0x5b, 0x11, 0xeb, 0x47, - 0xf9, 0x45, 0xcd, 0x54, 0x31, 0x9f, 0x09, 0x3f, 0x6e, 0x2a, 0xe5, 0x7e, 0xdc, 0x74, 0x0b, 0x40, - 0xb1, 0x35, 0xf1, 0x91, 0xbf, 0x58, 0x55, 0xe8, 0xbc, 0xd1, 0xe7, 0xff, 0x38, 0x46, 0xc5, 0x3b, - 0x90, 0x22, 0x7d, 0x44, 0x59, 0x18, 0xb5, 0x06, 0xc5, 0x54, 0x8d, 0xd3, 0xc9, 0x7f, 0x25, 0xc1, - 0x67, 0x9e, 0xbb, 0x83, 0x43, 0xad, 0x44, 0x78, 0x68, 0xa6, 0xc2, 0xc3, 0x4a, 0x3e, 0xc0, 0x39, - 0x76, 0x7f, 0x7f, 0xaf, 0x04, 0x68, 0x7b, 0x4f, 0x73, 0xd4, 0xb6, 0xe2, 0xd0, 0x01, 0x16, 0x0b, - 0x3c, 0xc3, 0x80, 0x71, 0x1b, 0x6a, 0x2a, 0x71, 0x7b, 0x8e, 0xc6, 0x8d, 0x24, 0x1e, 0x67, 0x68, - 0xf1, 0x8d, 0x68, 0x0a, 0xc7, 0xe9, 0x50, 0x1f, 0xaa, 0xa2, 0x56, 0x0c, 0x5a, 0x58, 0x8a, 0x16, - 0xbe, 0x91, 0x07, 0x44, 0xef, 0x87, 0x18, 0x70, 0x71, 0x08, 0x2e, 0x7f, 0x5f, 0x82, 0xa5, 0x51, - 0x83, 0x6c, 0xf8, 0x0d, 0x1a, 0x67, 0x65, 0x94, 0x97, 0x60, 0x8a, 0xa3, 0x32, 0x6b, 0x5c, 0xf4, - 0x4f, 0xc2, 0x99, 0x44, 0xcc, 0x47, 0xe5, 0x9f, 0x4a, 0xb0, 0x9c, 0xad, 0xd2, 0x79, 0xec, 0x37, - 0x3e, 0x48, 0xee, 0x37, 0x8a, 0x9e, 0x2a, 0x64, 0x2b, 0x9e, 0xb3, 0xf7, 0xf8, 0x24, 0xd3, 0xf8, - 0xe7, 0xb1, 0xca, 0xdd, 0xe4, 0x2a, 0xd7, 0x4e, 0xbc, 0xca, 0xec, 0x15, 0xb6, 0x3e, 0xf7, 0xf1, - 0xa7, 0x2b, 0x17, 0x7e, 0xfc, 0xe9, 0xca, 0x85, 0x7f, 0xfe, 0x74, 0xe5, 0xc2, 0x77, 0x8f, 0x56, - 0xa4, 0x8f, 0x8f, 0x56, 0xa4, 0x1f, 0x1f, 0xad, 0x48, 0xff, 0x76, 0xb4, 0x22, 0x7d, 0xff, 0x27, - 0x2b, 0x17, 0xbe, 0x36, 0x23, 0x30, 0xff, 0x37, 0x00, 0x00, 0xff, 0xff, 0x18, 0x07, 0xfd, 0xe8, - 0x4d, 0x46, 0x00, 0x00, + // 3406 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5b, 0xdd, 0x6f, 0x1b, 0xc7, + 0xb5, 0xf7, 0x8a, 0xa4, 0x44, 0x1d, 0x59, 0x92, 0x35, 0x72, 0x64, 0x46, 0x49, 0x24, 0x67, 0x2f, + 0x6e, 0xe2, 0xdc, 0x1b, 0x53, 0x37, 0xce, 0x75, 0x6e, 0xe2, 0x24, 0x4e, 0x44, 0xc9, 0x1f, 0xba, + 0x90, 0x64, 0x66, 0x48, 0x19, 0x8d, 0xf3, 0xd5, 0x15, 0x39, 0xa2, 0xd6, 0xde, 0xaf, 0xec, 0xce, + 0x2a, 0x22, 0x82, 0xb6, 0x01, 0x8a, 0xe6, 0xb1, 0x68, 0x5f, 0x8a, 0x14, 0x68, 0x1f, 0xfb, 0xd0, + 0x97, 0x36, 0x79, 0x68, 0xd3, 0xfe, 0x05, 0xf5, 0x43, 0x51, 0xa4, 0x40, 0x0b, 0x04, 0x45, 0x2a, + 0xd4, 0x0a, 0x9a, 0x7f, 0xa0, 0xc8, 0x8b, 0x9f, 0x8a, 0x99, 0x9d, 0xfd, 0xde, 0x95, 0x4d, 0x4a, + 0x26, 0x0a, 0xf4, 0x4d, 0x9c, 0x39, 0xe7, 0x77, 0x3e, 0xe6, 0xcc, 0x99, 0x33, 0x73, 0x56, 0xf0, + 0xf2, 0xad, 0xe7, 0x9d, 0xaa, 0x6a, 0x2e, 0xdc, 0x72, 0x37, 0x89, 0x6d, 0x10, 0x4a, 0x9c, 0x05, + 0xeb, 0x56, 0x67, 0x41, 0xb1, 0x54, 0x67, 0x81, 0xec, 0x52, 0x62, 0x38, 0xaa, 0x69, 0x38, 0x0b, + 0x3b, 0xcf, 0x6c, 0x12, 0xaa, 0x3c, 0xb3, 0xd0, 0x21, 0x06, 0xb1, 0x15, 0x4a, 0xda, 0x55, 0xcb, + 0x36, 0xa9, 0x89, 0xce, 0x7a, 0xec, 0xd5, 0x90, 0xbd, 0x6a, 0xdd, 0xea, 0x54, 0x19, 0x7b, 0x35, + 0x64, 0xaf, 0x0a, 0xf6, 0xd9, 0xb3, 0x1d, 0x95, 0x6e, 0xbb, 0x9b, 0xd5, 0x96, 0xa9, 0x2f, 0x74, + 0xcc, 0x8e, 0xb9, 0xc0, 0x51, 0x36, 0xdd, 0x2d, 0xfe, 0x8b, 0xff, 0xe0, 0x7f, 0x79, 0xe8, 0xb3, + 0xff, 0x2b, 0x94, 0x53, 0x2c, 0x55, 0x57, 0x5a, 0xdb, 0xaa, 0x41, 0xec, 0xae, 0xaf, 0xde, 0x82, + 0x4d, 0x1c, 0xd3, 0xb5, 0x5b, 0x24, 0xa9, 0xd3, 0x81, 0x5c, 0xce, 0x82, 0x4e, 0xa8, 0xb2, 0xb0, + 0x93, 0xb2, 0x64, 0x76, 0x21, 0x8f, 0xcb, 0x76, 0x0d, 0xaa, 0xea, 0x69, 0x31, 0xcf, 0xdd, 0x8b, + 0xc1, 0x69, 0x6d, 0x13, 0x5d, 0x49, 0xf1, 0x3d, 0x9b, 0xc7, 0xe7, 0x52, 0x55, 0x5b, 0x50, 0x0d, + 0xea, 0x50, 0x3b, 0xc5, 0xf4, 0x74, 0xee, 0x32, 0x65, 0xd9, 0xf2, 0xc2, 0x01, 0x8b, 0x6a, 0x99, + 0x9a, 0xda, 0xea, 0xe6, 0x2d, 0xa8, 0x5c, 0x05, 0x58, 0xac, 0xaf, 0x5c, 0x27, 0x36, 0x5b, 0x38, + 0x74, 0x1a, 0x8a, 0x86, 0xa2, 0x93, 0x8a, 0x74, 0x5a, 0x3a, 0x33, 0x5a, 0x3b, 0x7e, 0x7b, 0x6f, + 0xfe, 0xd8, 0xfe, 0xde, 0x7c, 0x71, 0x5d, 0xd1, 0x09, 0xe6, 0x33, 0xf2, 0x8f, 0x25, 0x78, 0x78, + 0xc9, 0x75, 0xa8, 0xa9, 0xaf, 0x11, 0x6a, 0xab, 0xad, 0x25, 0xd7, 0xb6, 0x89, 0x41, 0x1b, 0x54, + 0xa1, 0xae, 0x73, 0x6f, 0x7e, 0x74, 0x03, 0x4a, 0x3b, 0x8a, 0xe6, 0x92, 0xca, 0xd0, 0x69, 0xe9, + 0xcc, 0xd8, 0xb9, 0x6a, 0x55, 0x04, 0x54, 0xd4, 0x3b, 0x7e, 0x48, 0x55, 0xfd, 0x25, 0xaf, 0xbe, + 0xe6, 0x2a, 0x06, 0x55, 0x69, 0xb7, 0x76, 0x52, 0x40, 0x1e, 0x17, 0x72, 0xaf, 0x33, 0x2c, 0xec, + 0x41, 0xca, 0xdf, 0x97, 0xe0, 0xb1, 0x5c, 0xdd, 0x56, 0x55, 0x87, 0x22, 0x1d, 0x4a, 0x2a, 0x25, + 0xba, 0x53, 0x91, 0x4e, 0x17, 0xce, 0x8c, 0x9d, 0xbb, 0x5a, 0xed, 0x29, 0x9c, 0xab, 0xb9, 0xe0, + 0xb5, 0x71, 0xa1, 0x57, 0x69, 0x85, 0xc1, 0x63, 0x4f, 0x8a, 0xfc, 0x43, 0x09, 0x50, 0x94, 0xa7, + 0xa9, 0xd8, 0x1d, 0x42, 0xef, 0xc3, 0x4b, 0xaf, 0x1f, 0xce, 0x4b, 0xd3, 0x02, 0x72, 0xcc, 0x13, + 0x18, 0x73, 0xd2, 0x07, 0x12, 0xcc, 0xa4, 0x75, 0xe2, 0xde, 0xd9, 0x8a, 0x7b, 0x67, 0xf1, 0x10, + 0xde, 0xf1, 0x50, 0x73, 0xdc, 0xf2, 0xab, 0x21, 0x18, 0x5d, 0x56, 0x88, 0x6e, 0x1a, 0x0d, 0x42, + 0xd1, 0x37, 0xa1, 0xcc, 0xf6, 0x68, 0x5b, 0xa1, 0x0a, 0xf7, 0xc8, 0xd8, 0xb9, 0xff, 0x39, 0xc8, + 0x5c, 0xa7, 0xca, 0xa8, 0xab, 0x3b, 0xcf, 0x54, 0xaf, 0x6d, 0xde, 0x24, 0x2d, 0xba, 0x46, 0xa8, + 0x52, 0x43, 0x42, 0x0e, 0x84, 0x63, 0x38, 0x40, 0x45, 0x6f, 0x43, 0xd1, 0xb1, 0x48, 0x4b, 0x38, + 0xf3, 0xa5, 0x1e, 0xcd, 0x0a, 0x34, 0x6d, 0x58, 0xa4, 0x15, 0xae, 0x16, 0xfb, 0x85, 0x39, 0x2e, + 0xda, 0x82, 0x61, 0x87, 0x87, 0x41, 0xa5, 0xc0, 0x25, 0x5c, 0xec, 0x5b, 0x82, 0x17, 0x4c, 0x13, + 0x42, 0xc6, 0xb0, 0xf7, 0x1b, 0x0b, 0x74, 0xf9, 0xf7, 0x12, 0x8c, 0x07, 0xb4, 0x7c, 0xc5, 0xde, + 0x4c, 0xf9, 0xae, 0x7a, 0x7f, 0xbe, 0x63, 0xdc, 0xdc, 0x73, 0x27, 0x84, 0xac, 0xb2, 0x3f, 0x12, + 0xf1, 0xdb, 0x5b, 0x7e, 0x3c, 0x0c, 0xf1, 0x78, 0x78, 0xbe, 0x5f, 0xb3, 0x72, 0xc2, 0xe0, 0x93, + 0x62, 0xc4, 0x1c, 0xe6, 0x4e, 0xf4, 0x16, 0x94, 0x1d, 0xa2, 0x91, 0x16, 0x35, 0x6d, 0x61, 0xce, + 0xb3, 0xf7, 0x69, 0x8e, 0xb2, 0x49, 0xb4, 0x86, 0x60, 0xad, 0x1d, 0x67, 0xf6, 0xf8, 0xbf, 0x70, + 0x00, 0x89, 0xde, 0x80, 0x32, 0x25, 0xba, 0xa5, 0x29, 0xd4, 0xdf, 0x58, 0x67, 0xf3, 0x4d, 0x62, + 0xb0, 0x75, 0xb3, 0xdd, 0x14, 0x0c, 0x7c, 0xf1, 0x03, 0x67, 0xf9, 0xa3, 0x38, 0x00, 0x44, 0x1f, + 0x4a, 0x30, 0xe1, 0x5a, 0x6d, 0x46, 0x4a, 0x59, 0x82, 0xed, 0x74, 0x45, 0x34, 0x5c, 0xee, 0xd7, + 0x6d, 0x1b, 0x31, 0xb4, 0xda, 0x8c, 0x10, 0x3e, 0x11, 0x1f, 0xc7, 0x09, 0xa9, 0x68, 0x11, 0x26, + 0x75, 0xd5, 0xc0, 0x44, 0x69, 0x77, 0x1b, 0xa4, 0x65, 0x1a, 0x6d, 0xa7, 0x52, 0x3c, 0x2d, 0x9d, + 0x29, 0xd5, 0x4e, 0x09, 0x80, 0xc9, 0xb5, 0xf8, 0x34, 0x4e, 0xd2, 0xa3, 0xff, 0x07, 0xe4, 0xdb, + 0x75, 0xc5, 0x3b, 0x2f, 0x54, 0xd3, 0xa8, 0x94, 0x4e, 0x4b, 0x67, 0x0a, 0xb5, 0x59, 0x81, 0x82, + 0x9a, 0x29, 0x0a, 0x9c, 0xc1, 0x85, 0x56, 0xe1, 0xa4, 0x4d, 0x76, 0x54, 0x66, 0xe3, 0x55, 0xd5, + 0xa1, 0xa6, 0xdd, 0x5d, 0x55, 0x75, 0x95, 0x56, 0x86, 0xb9, 0x4e, 0x95, 0xfd, 0xbd, 0xf9, 0x93, + 0x38, 0x63, 0x1e, 0x67, 0x72, 0xc9, 0x1f, 0x97, 0x60, 0x32, 0xb1, 0x5d, 0xd0, 0x75, 0x98, 0x69, + 0x79, 0xc9, 0x78, 0xdd, 0xd5, 0x37, 0x89, 0xdd, 0x68, 0x6d, 0x93, 0xb6, 0xab, 0x91, 0x36, 0x8f, + 0xa1, 0x52, 0x6d, 0x4e, 0x68, 0x3c, 0xb3, 0x94, 0x49, 0x85, 0x73, 0xb8, 0x99, 0x17, 0x0c, 0x3e, + 0xb4, 0xa6, 0x3a, 0x4e, 0x80, 0x39, 0xc4, 0x31, 0x03, 0x2f, 0xac, 0xa7, 0x28, 0x70, 0x06, 0x17, + 0xd3, 0xb1, 0x4d, 0x1c, 0xd5, 0x26, 0xed, 0xa4, 0x8e, 0x85, 0xb8, 0x8e, 0xcb, 0x99, 0x54, 0x38, + 0x87, 0x1b, 0x9d, 0x87, 0x31, 0x4f, 0x1a, 0x5f, 0x3f, 0xb1, 0xd0, 0x41, 0xfa, 0x5f, 0x0f, 0xa7, + 0x70, 0x94, 0x8e, 0x99, 0x66, 0x6e, 0x3a, 0xc4, 0xde, 0x21, 0xed, 0xfc, 0x05, 0xbe, 0x96, 0xa2, + 0xc0, 0x19, 0x5c, 0xcc, 0x34, 0x2f, 0x02, 0x53, 0xa6, 0x0d, 0xc7, 0x4d, 0xdb, 0xc8, 0xa4, 0xc2, + 0x39, 0xdc, 0x2c, 0x8e, 0x3d, 0x95, 0x17, 0x77, 0x14, 0x55, 0x53, 0x36, 0x35, 0x52, 0x19, 0x89, + 0xc7, 0xf1, 0x7a, 0x7c, 0x1a, 0x27, 0xe9, 0xd1, 0x15, 0x98, 0xf2, 0x86, 0x36, 0x0c, 0x25, 0x00, + 0x29, 0x73, 0x90, 0x87, 0x05, 0xc8, 0xd4, 0x7a, 0x92, 0x00, 0xa7, 0x79, 0xd0, 0x05, 0x98, 0x68, + 0x99, 0x9a, 0xc6, 0xe3, 0x71, 0xc9, 0x74, 0x0d, 0x5a, 0x19, 0xe5, 0xbe, 0x42, 0x6c, 0x3f, 0x2e, + 0xc5, 0x66, 0x70, 0x82, 0x52, 0xfe, 0x8b, 0x04, 0xa7, 0x72, 0xf6, 0x34, 0x7a, 0x05, 0x8a, 0xb4, + 0x6b, 0xf9, 0x95, 0xc0, 0x7f, 0xfb, 0x67, 0x4b, 0xb3, 0x6b, 0x91, 0xbb, 0x7b, 0xf3, 0x8f, 0xe4, + 0xb0, 0xb1, 0x69, 0xcc, 0x19, 0xd1, 0xb7, 0x61, 0xdc, 0x66, 0xe2, 0x8c, 0x8e, 0x47, 0x22, 0xf2, + 0xda, 0xa5, 0x1e, 0x73, 0x0e, 0x8e, 0x62, 0x84, 0x79, 0x7b, 0x6a, 0x7f, 0x6f, 0x7e, 0x3c, 0x36, + 0x87, 0xe3, 0xe2, 0xe4, 0xdf, 0x0c, 0x01, 0x2c, 0x13, 0x4b, 0x33, 0xbb, 0x3a, 0x31, 0x06, 0x71, + 0x96, 0xbf, 0x13, 0x3b, 0xcb, 0x5f, 0xee, 0x35, 0xb7, 0x06, 0xaa, 0xe6, 0x1e, 0xe6, 0x9d, 0xc4, + 0x61, 0xfe, 0x4a, 0xff, 0x22, 0x0e, 0x3e, 0xcd, 0xef, 0x14, 0x60, 0x3a, 0x24, 0x5e, 0x32, 0x8d, + 0xb6, 0xca, 0xf7, 0xd3, 0x8b, 0xb1, 0x98, 0x78, 0x32, 0x11, 0x13, 0xa7, 0x32, 0x58, 0x22, 0xf1, + 0x70, 0x3d, 0xd0, 0x7e, 0x88, 0xb3, 0x5f, 0x8c, 0x0b, 0xbf, 0xbb, 0x37, 0x7f, 0xe0, 0xcd, 0xa2, + 0x1a, 0x60, 0xc6, 0x95, 0x45, 0x4f, 0xc0, 0xb0, 0x4d, 0x14, 0xc7, 0x34, 0x78, 0x8a, 0x19, 0x0d, + 0x8d, 0xc2, 0x7c, 0x14, 0x8b, 0x59, 0xf4, 0x14, 0x8c, 0xe8, 0xc4, 0x71, 0x94, 0x0e, 0xe1, 0xd9, + 0x64, 0xb4, 0x36, 0x29, 0x08, 0x47, 0xd6, 0xbc, 0x61, 0xec, 0xcf, 0xa3, 0x9b, 0x30, 0xa1, 0x29, + 0x8e, 0x08, 0xed, 0xa6, 0xaa, 0x13, 0x9e, 0x2f, 0xc6, 0xce, 0xfd, 0xd7, 0xfd, 0x45, 0x0c, 0xe3, + 0x08, 0xcf, 0xc4, 0xd5, 0x18, 0x12, 0x4e, 0x20, 0xa3, 0x1d, 0x40, 0x6c, 0xa4, 0x69, 0x2b, 0x86, + 0xe3, 0xb9, 0x8c, 0xc9, 0x1b, 0xe9, 0x59, 0x5e, 0x90, 0x1b, 0x57, 0x53, 0x68, 0x38, 0x43, 0x82, + 0xfc, 0x07, 0x09, 0x26, 0xc2, 0x05, 0x1b, 0x40, 0xc9, 0xf6, 0x76, 0xbc, 0x64, 0x7b, 0xa1, 0xef, + 0xe0, 0xcd, 0xa9, 0xd9, 0x3e, 0x2a, 0x00, 0x0a, 0x89, 0x58, 0x6a, 0xd8, 0x54, 0x5a, 0xb7, 0xee, + 0xe3, 0x46, 0xf3, 0x33, 0x09, 0x90, 0x48, 0xf4, 0x8b, 0x86, 0x61, 0x52, 0x7e, 0x76, 0xf8, 0x6a, + 0xbe, 0xde, 0xb7, 0x9a, 0xbe, 0x06, 0xd5, 0x8d, 0x14, 0xf6, 0x25, 0x83, 0xda, 0xdd, 0x70, 0xc5, + 0xd2, 0x04, 0x38, 0x43, 0x21, 0xf4, 0x2e, 0x80, 0x2d, 0x30, 0x9b, 0xa6, 0x48, 0x01, 0x2f, 0xf7, + 0x91, 0x4d, 0x19, 0xc0, 0x92, 0x69, 0x6c, 0xa9, 0x9d, 0x30, 0xa1, 0xe1, 0x00, 0x18, 0x47, 0x84, + 0xcc, 0x5e, 0x82, 0x53, 0x39, 0xda, 0xa3, 0x13, 0x50, 0xb8, 0x45, 0xba, 0x9e, 0x5b, 0x31, 0xfb, + 0x13, 0x9d, 0x8c, 0xde, 0x0c, 0x47, 0xc5, 0xa5, 0xee, 0xc2, 0xd0, 0xf3, 0x92, 0xfc, 0x55, 0x29, + 0x1a, 0x6b, 0xbc, 0x9e, 0x3e, 0x03, 0x65, 0x9b, 0x58, 0x9a, 0xda, 0x52, 0x1c, 0x51, 0x0b, 0xf1, + 0xd2, 0x18, 0x8b, 0x31, 0x1c, 0xcc, 0xc6, 0x2a, 0xef, 0xa1, 0x07, 0x5b, 0x79, 0x17, 0x8e, 0xba, + 0xf2, 0x36, 0xa1, 0xec, 0xf8, 0x25, 0x77, 0x91, 0x83, 0x2f, 0x1e, 0x22, 0x67, 0x8b, 0x6a, 0x3b, + 0x10, 0x18, 0xd4, 0xd9, 0x81, 0x90, 0xac, 0x0a, 0xbb, 0xd4, 0x63, 0x85, 0x7d, 0xa4, 0x55, 0x31, + 0xcb, 0xce, 0x96, 0xe2, 0x3a, 0xa4, 0xcd, 0x53, 0x5a, 0x39, 0xcc, 0xce, 0x75, 0x3e, 0x8a, 0xc5, + 0x2c, 0xd2, 0x63, 0xc1, 0x5d, 0x3e, 0x8a, 0xe0, 0x9e, 0xc8, 0x0f, 0x6c, 0xb4, 0x01, 0xa7, 0x2c, + 0xdb, 0xec, 0xd8, 0xc4, 0x71, 0x96, 0x89, 0xd2, 0xd6, 0x54, 0x83, 0xf8, 0xfe, 0x1a, 0xe5, 0x76, + 0x3e, 0xb2, 0xbf, 0x37, 0x7f, 0xaa, 0x9e, 0x4d, 0x82, 0xf3, 0x78, 0xe5, 0xcf, 0x8b, 0x70, 0x22, + 0x79, 0xca, 0xe6, 0x54, 0xb4, 0x52, 0x5f, 0x15, 0xed, 0xd3, 0x91, 0x6d, 0xe3, 0x95, 0xfb, 0x41, + 0x34, 0x64, 0x6c, 0x9d, 0x45, 0x98, 0x14, 0x79, 0xc4, 0x9f, 0x14, 0x35, 0x7d, 0x10, 0x0d, 0x1b, + 0xf1, 0x69, 0x9c, 0xa4, 0x67, 0x75, 0x6a, 0x58, 0x7e, 0xfa, 0x20, 0xc5, 0x78, 0x9d, 0xba, 0x98, + 0x24, 0xc0, 0x69, 0x1e, 0xb4, 0x06, 0xd3, 0xae, 0x91, 0x86, 0xf2, 0xa2, 0xf3, 0x11, 0x01, 0x35, + 0xbd, 0x91, 0x26, 0xc1, 0x59, 0x7c, 0x68, 0x07, 0xa0, 0xe5, 0x17, 0x04, 0x4e, 0x65, 0x98, 0xe7, + 0xea, 0x5a, 0xdf, 0x7b, 0x2b, 0xa8, 0x2d, 0xc2, 0x8c, 0x18, 0x0c, 0x39, 0x38, 0x22, 0x09, 0xbd, + 0x08, 0xe3, 0x36, 0xbf, 0xb4, 0xf8, 0x06, 0x78, 0x85, 0xff, 0x43, 0x82, 0x6d, 0x1c, 0x47, 0x27, + 0x71, 0x9c, 0x36, 0xa3, 0x56, 0x2f, 0xdf, 0x77, 0xad, 0xfe, 0x47, 0x29, 0x7a, 0xbc, 0x05, 0x65, + 0xfa, 0x85, 0x58, 0x49, 0xf6, 0x44, 0xa2, 0x24, 0x9b, 0x49, 0x73, 0x44, 0x2a, 0xb2, 0xef, 0x64, + 0x57, 0xe8, 0x97, 0x0f, 0x55, 0xa1, 0x87, 0xc7, 0xf4, 0xbd, 0x4b, 0xf4, 0x4f, 0x24, 0x98, 0xb9, + 0xdc, 0xb8, 0x62, 0x9b, 0xae, 0xe5, 0xab, 0x77, 0xcd, 0xf2, 0xfc, 0xfc, 0x7f, 0x50, 0xb4, 0x5d, + 0xcd, 0xb7, 0xeb, 0x3f, 0x7c, 0xbb, 0xb0, 0xab, 0x31, 0xbb, 0xa6, 0x13, 0x5c, 0x9e, 0x51, 0x8c, + 0x01, 0xbd, 0x0d, 0xc3, 0xb6, 0x62, 0x74, 0x88, 0x7f, 0x80, 0x3f, 0xd7, 0xa3, 0x35, 0x2b, 0xcb, + 0x98, 0xb1, 0x47, 0xca, 0x48, 0x8e, 0x86, 0x05, 0xaa, 0xfc, 0x53, 0x09, 0x26, 0xaf, 0x36, 0x9b, + 0xf5, 0x15, 0x83, 0x67, 0x80, 0xba, 0x42, 0xb7, 0x59, 0x8d, 0x61, 0x29, 0x74, 0x3b, 0x59, 0x63, + 0xb0, 0x39, 0xcc, 0x67, 0xd0, 0x36, 0x8c, 0xb0, 0xcc, 0x43, 0x8c, 0x76, 0x9f, 0xd7, 0x03, 0x21, + 0xae, 0xe6, 0x81, 0x84, 0xb5, 0xab, 0x18, 0xc0, 0x3e, 0xbc, 0xfc, 0x3e, 0x9c, 0x8c, 0xa8, 0xc7, + 0xfc, 0xc5, 0xdf, 0x58, 0x51, 0x0b, 0x4a, 0x4c, 0x13, 0xff, 0x05, 0xb5, 0xd7, 0x87, 0xc0, 0x84, + 0xc9, 0x61, 0x0d, 0xc6, 0x7e, 0x39, 0xd8, 0xc3, 0x96, 0xd7, 0x60, 0xfc, 0xaa, 0xe9, 0xd0, 0xba, + 0x69, 0x53, 0xee, 0x36, 0xf4, 0x18, 0x14, 0x74, 0xd5, 0x10, 0x27, 0xfc, 0x98, 0xe0, 0x29, 0xb0, + 0x33, 0x88, 0x8d, 0xf3, 0x69, 0x65, 0x57, 0x64, 0xb2, 0x70, 0x5a, 0xd9, 0xc5, 0x6c, 0x5c, 0xbe, + 0x02, 0x23, 0x62, 0x39, 0xa2, 0x40, 0x85, 0x83, 0x81, 0x0a, 0x19, 0x40, 0xbf, 0x1c, 0x82, 0x11, + 0xa1, 0xfd, 0x00, 0x2e, 0x82, 0x6f, 0xc6, 0x2e, 0x82, 0x17, 0xfa, 0x5b, 0xe9, 0xdc, 0x5b, 0x60, + 0x3b, 0x71, 0x0b, 0x7c, 0xa9, 0x4f, 0xfc, 0x83, 0xaf, 0x80, 0x1f, 0x4b, 0x30, 0x11, 0x8f, 0x39, + 0x74, 0x1e, 0xc6, 0xd8, 0x79, 0xa4, 0xb6, 0xc8, 0x7a, 0x58, 0x50, 0x07, 0x0f, 0x3a, 0x8d, 0x70, + 0x0a, 0x47, 0xe9, 0x50, 0x27, 0x60, 0x63, 0x61, 0x21, 0x9c, 0x92, 0xef, 0x72, 0x97, 0xaa, 0x5a, + 0xd5, 0x6b, 0x3d, 0x55, 0x57, 0x0c, 0x7a, 0xcd, 0x6e, 0x50, 0x5b, 0x35, 0x3a, 0x29, 0x41, 0x3c, + 0xc6, 0xa2, 0xc8, 0xf2, 0x6d, 0x09, 0xc6, 0x84, 0xca, 0x03, 0xb8, 0xce, 0xbc, 0x11, 0xbf, 0xce, + 0x3c, 0xd7, 0xe7, 0x7e, 0xce, 0xbe, 0xcb, 0x7c, 0x1a, 0x9a, 0xc2, 0x76, 0x30, 0x4b, 0x30, 0xdb, + 0xa6, 0x43, 0x93, 0x09, 0x86, 0xed, 0x35, 0xcc, 0x67, 0xd0, 0xf7, 0x24, 0x38, 0xa1, 0x26, 0xf6, + 0xbc, 0xf0, 0xf5, 0x2b, 0xfd, 0xa9, 0x16, 0xc0, 0xd4, 0x2a, 0x42, 0xde, 0x89, 0xe4, 0x0c, 0x4e, + 0x89, 0x94, 0x5d, 0x48, 0x51, 0x21, 0x05, 0x8a, 0xdb, 0x94, 0x5a, 0x62, 0x11, 0x96, 0xfa, 0xcf, + 0x3c, 0xa1, 0x4a, 0x65, 0x6e, 0x7e, 0xb3, 0x59, 0xc7, 0x1c, 0x5a, 0xfe, 0xc5, 0x50, 0xe0, 0xb0, + 0x86, 0xb7, 0x49, 0x82, 0x7c, 0x2b, 0x1d, 0x45, 0xbe, 0x1d, 0xcb, 0xca, 0xb5, 0xe8, 0x1b, 0x50, + 0xa0, 0x5a, 0xbf, 0x17, 0x5a, 0x21, 0xa1, 0xb9, 0xda, 0x08, 0x13, 0x56, 0x73, 0xb5, 0x81, 0x19, + 0x24, 0x7a, 0x07, 0x4a, 0xec, 0x34, 0x63, 0x7b, 0xbc, 0xd0, 0x7f, 0x0e, 0x61, 0xfe, 0x0a, 0x23, + 0x8c, 0xfd, 0x72, 0xb0, 0x87, 0x2b, 0xbf, 0x0f, 0xe3, 0xb1, 0x44, 0x80, 0x6e, 0xc2, 0x71, 0xcd, + 0x54, 0xda, 0x35, 0x45, 0x53, 0x8c, 0x16, 0xb1, 0x93, 0xa9, 0x31, 0xfb, 0x2e, 0xb4, 0x1a, 0xe1, + 0x10, 0x09, 0x25, 0x68, 0x83, 0x46, 0xe7, 0x70, 0x0c, 0x5b, 0x56, 0x00, 0x42, 0xeb, 0xd1, 0x3c, + 0x94, 0x58, 0x08, 0x7b, 0x27, 0xd3, 0x68, 0x6d, 0x94, 0xe9, 0xca, 0x22, 0xdb, 0xc1, 0xde, 0x38, + 0x3a, 0x07, 0xe0, 0x90, 0x96, 0x4d, 0x28, 0xcf, 0x3b, 0xde, 0xeb, 0x51, 0x90, 0x81, 0x1b, 0xc1, + 0x0c, 0x8e, 0x50, 0xc9, 0x7f, 0x96, 0x60, 0x7c, 0x9d, 0xd0, 0xf7, 0x4c, 0xfb, 0x56, 0x9d, 0xb7, + 0x99, 0x07, 0x90, 0xf7, 0x37, 0x63, 0x79, 0xff, 0xd5, 0x1e, 0xd7, 0x2c, 0xa6, 0x6d, 0x5e, 0xf6, + 0x97, 0xff, 0x2e, 0x41, 0x25, 0x46, 0x19, 0x4d, 0x13, 0x04, 0x4a, 0x96, 0x69, 0x53, 0xff, 0x8c, + 0x3f, 0x94, 0x06, 0x2c, 0xa5, 0x46, 0x4e, 0x79, 0x06, 0x8b, 0x3d, 0x74, 0x66, 0xe7, 0x96, 0x6d, + 0xea, 0x22, 0xee, 0x0f, 0x27, 0x85, 0x10, 0x3b, 0xb4, 0xf3, 0xb2, 0x6d, 0xea, 0x98, 0x63, 0xcb, + 0x7f, 0x92, 0x60, 0x2a, 0x46, 0x39, 0x80, 0x94, 0xae, 0xc4, 0x53, 0xfa, 0x4b, 0x87, 0x31, 0x2c, + 0x27, 0xb1, 0x7f, 0x9d, 0x34, 0x8b, 0x39, 0x00, 0x6d, 0xc1, 0x98, 0x65, 0xb6, 0x1b, 0x47, 0xd0, + 0x5f, 0x9c, 0x64, 0x27, 0x64, 0x3d, 0xc4, 0xc2, 0x51, 0x60, 0xb4, 0x0b, 0x53, 0x86, 0xa2, 0x13, + 0xc7, 0x52, 0x5a, 0xa4, 0x71, 0x04, 0x6f, 0x2a, 0x0f, 0xf1, 0x2e, 0x45, 0x12, 0x11, 0xa7, 0x85, + 0xc8, 0xbf, 0x4e, 0xd9, 0x6d, 0xda, 0x14, 0xbd, 0x06, 0x65, 0xfe, 0xa9, 0x47, 0xcb, 0xd4, 0xc4, + 0xd1, 0x76, 0x9e, 0x2d, 0x4d, 0x5d, 0x8c, 0xdd, 0xdd, 0x9b, 0xff, 0xcf, 0x03, 0x9f, 0x84, 0x7d, + 0x42, 0x1c, 0xc0, 0xa0, 0x75, 0x28, 0x5a, 0x87, 0x29, 0x33, 0xf8, 0xc1, 0xc2, 0x6b, 0x0b, 0x8e, + 0x23, 0xff, 0x23, 0xa9, 0x38, 0x3f, 0x5e, 0x6e, 0x1e, 0xd9, 0x82, 0x05, 0x65, 0x4d, 0xee, 0xa2, + 0xd9, 0x30, 0x22, 0x4e, 0x59, 0x11, 0x97, 0x57, 0x0e, 0x13, 0x97, 0xd1, 0x93, 0x21, 0xb8, 0x44, + 0xf8, 0x83, 0xbe, 0x20, 0xf9, 0xaf, 0x12, 0x4c, 0x71, 0x85, 0x5a, 0xae, 0xad, 0xd2, 0xee, 0xc0, + 0x32, 0xe8, 0x56, 0x2c, 0x83, 0x2e, 0xf7, 0x68, 0x68, 0x4a, 0xe3, 0xdc, 0x2c, 0xfa, 0x85, 0x04, + 0x0f, 0xa5, 0xa8, 0x07, 0x90, 0x61, 0x48, 0x3c, 0xc3, 0xbc, 0x7a, 0x58, 0x03, 0x73, 0xb2, 0xcc, + 0x6d, 0xc8, 0x30, 0x8f, 0x07, 0xee, 0x39, 0x00, 0xcb, 0x56, 0x77, 0x54, 0x8d, 0x74, 0x44, 0x13, + 0xba, 0x1c, 0x2e, 0x49, 0x3d, 0x98, 0xc1, 0x11, 0x2a, 0xf4, 0x2d, 0x98, 0x69, 0x93, 0x2d, 0xc5, + 0xd5, 0xe8, 0x62, 0xbb, 0xbd, 0xa4, 0x58, 0xca, 0xa6, 0xaa, 0xa9, 0x54, 0x15, 0x37, 0xec, 0xd1, + 0xda, 0x25, 0xaf, 0x39, 0x9c, 0x45, 0x71, 0x77, 0x6f, 0xfe, 0xc9, 0x83, 0x9b, 0x3a, 0x3e, 0x71, + 0x17, 0xe7, 0x08, 0x41, 0xdf, 0x95, 0xa0, 0x62, 0x93, 0x77, 0x5d, 0xd5, 0x26, 0xed, 0x65, 0xdb, + 0xb4, 0x62, 0x1a, 0x14, 0xb8, 0x06, 0x57, 0xf6, 0xf7, 0xe6, 0x2b, 0x38, 0x87, 0xa6, 0x17, 0x1d, + 0x72, 0x05, 0x21, 0x0a, 0xd3, 0x8a, 0xa6, 0x99, 0xef, 0x91, 0xb8, 0x07, 0x8a, 0x5c, 0x7e, 0x6d, + 0x7f, 0x6f, 0x7e, 0x7a, 0x31, 0x3d, 0xdd, 0x8b, 0xe8, 0x2c, 0x78, 0xb4, 0x00, 0x23, 0x3b, 0xa6, + 0xe6, 0xea, 0xc4, 0xa9, 0x94, 0xb8, 0x24, 0x96, 0x71, 0x47, 0xae, 0x7b, 0x43, 0x77, 0xf7, 0xe6, + 0x87, 0x2f, 0x37, 0xf8, 0xd3, 0x87, 0x4f, 0xc5, 0xee, 0x68, 0xac, 0x66, 0x12, 0x5b, 0x9e, 0xbf, + 0xd9, 0x96, 0xc3, 0x1c, 0x73, 0x35, 0x9c, 0xc2, 0x51, 0x3a, 0xa4, 0xc3, 0xe8, 0xb6, 0xb8, 0xb7, + 0x3b, 0x95, 0x91, 0xbe, 0x4e, 0xbf, 0xd8, 0xbd, 0xbf, 0x36, 0x25, 0x44, 0x8e, 0xfa, 0xc3, 0x0e, + 0x0e, 0x25, 0xa0, 0xa7, 0x60, 0x84, 0xff, 0x58, 0x59, 0xe6, 0x0f, 0x60, 0xe5, 0x30, 0x13, 0x5d, + 0xf5, 0x86, 0xb1, 0x3f, 0xef, 0x93, 0xae, 0xd4, 0x97, 0xf8, 0xc3, 0x6c, 0x82, 0x74, 0xa5, 0xbe, + 0x84, 0xfd, 0x79, 0x64, 0xc1, 0x88, 0x43, 0x56, 0x55, 0xc3, 0xdd, 0xad, 0x40, 0x5f, 0xad, 0xe6, + 0xc6, 0x25, 0xce, 0x9d, 0x78, 0x8a, 0x0a, 0x25, 0x8a, 0x79, 0xec, 0x8b, 0x41, 0xbb, 0x30, 0x6a, + 0xbb, 0xc6, 0xa2, 0xb3, 0xe1, 0x10, 0xbb, 0x32, 0xc6, 0x65, 0xf6, 0x9a, 0x9c, 0xb1, 0xcf, 0x9f, + 0x94, 0x1a, 0x78, 0x30, 0xa0, 0xc0, 0xa1, 0x30, 0xf4, 0x13, 0x09, 0x90, 0xe3, 0x5a, 0x96, 0x46, + 0x74, 0x62, 0x50, 0x45, 0xe3, 0xaf, 0x61, 0x4e, 0xe5, 0x38, 0xd7, 0xa1, 0xde, 0xab, 0xdd, 0x29, + 0xa0, 0xa4, 0x32, 0xc1, 0x33, 0x75, 0x9a, 0x14, 0x67, 0xe8, 0xc1, 0x96, 0x62, 0xcb, 0xe1, 0x7f, + 0x57, 0xc6, 0xfb, 0x5a, 0x8a, 0xec, 0x57, 0xc1, 0x70, 0x29, 0xc4, 0x3c, 0xf6, 0xc5, 0xa0, 0xeb, + 0x30, 0x63, 0x13, 0xa5, 0x7d, 0xcd, 0xd0, 0xba, 0xd8, 0x34, 0xe9, 0x65, 0x55, 0x23, 0x4e, 0xd7, + 0xa1, 0x44, 0xaf, 0x4c, 0xf0, 0xb0, 0x09, 0x3e, 0xf5, 0xc0, 0x99, 0x54, 0x38, 0x87, 0x9b, 0x7f, + 0x45, 0x20, 0xde, 0x6f, 0x07, 0xf3, 0x45, 0xe0, 0xe1, 0xbe, 0x22, 0x08, 0x55, 0x7d, 0x60, 0x5f, + 0x11, 0x44, 0x44, 0x1c, 0xfc, 0x84, 0xf4, 0xf5, 0x10, 0x4c, 0x87, 0xc4, 0xf7, 0xfd, 0x15, 0x41, + 0x06, 0xcb, 0x00, 0xbe, 0x22, 0xc8, 0x6e, 0xc3, 0x17, 0x1e, 0x74, 0x1b, 0xfe, 0x01, 0x7c, 0xbd, + 0xc0, 0x3b, 0xfb, 0xa1, 0x13, 0xff, 0xf5, 0x3b, 0xfb, 0xa1, 0xae, 0x39, 0xe5, 0xcc, 0x6f, 0x87, + 0xa2, 0x06, 0xfd, 0x1b, 0xb5, 0x8f, 0x0f, 0xff, 0xbd, 0xa4, 0xfc, 0x45, 0x01, 0x4e, 0x24, 0x77, + 0x6c, 0xac, 0x8b, 0x28, 0xdd, 0xb3, 0x8b, 0x58, 0x87, 0x93, 0x5b, 0xae, 0xa6, 0x75, 0xb9, 0x43, + 0x22, 0xad, 0x44, 0xef, 0xd5, 0xfe, 0x51, 0xc1, 0x79, 0xf2, 0x72, 0x06, 0x0d, 0xce, 0xe4, 0xcc, + 0xe9, 0x88, 0x16, 0xfa, 0xea, 0x88, 0xa6, 0x1a, 0x72, 0xc5, 0x1e, 0x1a, 0x72, 0x99, 0xdd, 0xcd, + 0x52, 0x1f, 0xdd, 0xcd, 0xa3, 0x68, 0x47, 0x66, 0x24, 0xbe, 0x7b, 0xb5, 0x23, 0xe5, 0x47, 0x61, + 0x56, 0xb0, 0x51, 0xde, 0x29, 0x34, 0xa8, 0x6d, 0x6a, 0x1a, 0xb1, 0x97, 0x5d, 0x5d, 0xef, 0xca, + 0x17, 0x61, 0x22, 0xde, 0x13, 0xf7, 0x56, 0xde, 0x6b, 0xd3, 0x8b, 0x5e, 0x4a, 0x64, 0xe5, 0xbd, + 0x71, 0x1c, 0x50, 0xc8, 0x1f, 0x4a, 0x30, 0x93, 0xfd, 0xfd, 0x1d, 0xd2, 0x60, 0x42, 0x57, 0x76, + 0xa3, 0x1f, 0x2f, 0x4a, 0x7d, 0xde, 0xb8, 0x79, 0xf3, 0x73, 0x2d, 0x86, 0x85, 0x13, 0xd8, 0xf2, + 0x97, 0x12, 0x9c, 0xca, 0x69, 0x33, 0x0e, 0x56, 0x13, 0x74, 0x03, 0xca, 0xba, 0xb2, 0xdb, 0x70, + 0xed, 0x0e, 0xe9, 0xfb, 0x8d, 0x81, 0xe7, 0x92, 0x35, 0x81, 0x82, 0x03, 0x3c, 0xf9, 0x13, 0x09, + 0x2a, 0x79, 0xf5, 0x20, 0x3a, 0x1f, 0x6b, 0x88, 0x3e, 0x9e, 0x68, 0x88, 0x4e, 0xa5, 0xf8, 0x06, + 0xd4, 0x0e, 0xfd, 0x54, 0x82, 0x99, 0xec, 0xba, 0x19, 0x3d, 0x1b, 0xd3, 0x78, 0x3e, 0xa1, 0xf1, + 0x64, 0x82, 0x4b, 0xe8, 0xbb, 0x0d, 0x13, 0xa2, 0xba, 0x16, 0x30, 0xc2, 0xcb, 0x4f, 0x1f, 0x9c, + 0x55, 0x05, 0x98, 0x5f, 0x27, 0xf2, 0x95, 0x8c, 0x8f, 0xe1, 0x04, 0xae, 0xfc, 0xf3, 0x21, 0x28, + 0x35, 0x5a, 0x8a, 0x46, 0x06, 0x50, 0xd4, 0xdd, 0x88, 0x15, 0x75, 0xbd, 0xfe, 0xb7, 0x02, 0xd7, + 0x32, 0xb7, 0x9e, 0xdb, 0x4c, 0xd4, 0x73, 0x17, 0xfa, 0x42, 0x3f, 0xb8, 0x94, 0x7b, 0x01, 0x46, + 0x03, 0x25, 0x7a, 0x3b, 0x3d, 0xe4, 0x8f, 0x87, 0x60, 0x2c, 0x22, 0xa2, 0xc7, 0xb3, 0x67, 0x27, + 0x76, 0x7a, 0xf7, 0xf3, 0x8f, 0x51, 0x11, 0xd9, 0x55, 0xff, 0xfc, 0xf6, 0xbe, 0xbf, 0x0b, 0xbf, + 0xa3, 0x4a, 0x1f, 0xeb, 0x17, 0x61, 0x82, 0xf2, 0xff, 0x13, 0x0a, 0xde, 0xf8, 0x0a, 0x3c, 0x8a, + 0x83, 0xaf, 0x3a, 0x9b, 0xb1, 0x59, 0x9c, 0xa0, 0x9e, 0x7d, 0x11, 0xc6, 0x63, 0xc2, 0x7a, 0xfa, + 0x5c, 0xee, 0x77, 0x12, 0x3c, 0x7e, 0xcf, 0x3b, 0x19, 0xaa, 0xc5, 0xb6, 0x57, 0x35, 0xb1, 0xbd, + 0xe6, 0xf2, 0x01, 0x06, 0xf8, 0xb1, 0xc4, 0x8f, 0x86, 0x00, 0x35, 0xb7, 0x55, 0xbb, 0x5d, 0x57, + 0x6c, 0xda, 0xc5, 0xe2, 0xbf, 0xc1, 0x06, 0xb0, 0xe1, 0xce, 0xc3, 0x58, 0x9b, 0x38, 0x2d, 0x5b, + 0xe5, 0xce, 0x12, 0x77, 0x85, 0xe0, 0x1d, 0x64, 0x39, 0x9c, 0xc2, 0x51, 0x3a, 0xd4, 0x81, 0xf2, + 0x8e, 0xf7, 0xff, 0x86, 0x7e, 0xe7, 0xad, 0xd7, 0x62, 0x36, 0xfc, 0x8f, 0xc5, 0x30, 0xbe, 0xc4, + 0x80, 0x83, 0x03, 0x70, 0xf9, 0x23, 0x09, 0x66, 0xd2, 0x8e, 0x59, 0x66, 0xaa, 0x3f, 0x78, 0xe7, + 0x3c, 0x0a, 0x45, 0x8e, 0xce, 0xbc, 0x72, 0xdc, 0x7b, 0xf1, 0x66, 0x92, 0x31, 0x1f, 0x95, 0xbf, + 0x92, 0x60, 0x36, 0x5b, 0xb5, 0x01, 0x5c, 0x25, 0x6e, 0xc6, 0xaf, 0x12, 0xbd, 0x3e, 0x1b, 0x64, + 0xeb, 0x9d, 0x73, 0xad, 0xd8, 0xcb, 0x5c, 0x83, 0x01, 0x18, 0xb9, 0x15, 0x37, 0x72, 0xf1, 0xd0, + 0x46, 0x66, 0x1b, 0x58, 0x3b, 0x7b, 0xfb, 0xce, 0xdc, 0xb1, 0xcf, 0xee, 0xcc, 0x1d, 0xfb, 0xfc, + 0xce, 0xdc, 0xb1, 0x0f, 0xf6, 0xe7, 0xa4, 0xdb, 0xfb, 0x73, 0xd2, 0x67, 0xfb, 0x73, 0xd2, 0xe7, + 0xfb, 0x73, 0xd2, 0xdf, 0xf6, 0xe7, 0xa4, 0x1f, 0x7c, 0x39, 0x77, 0xec, 0xc6, 0x88, 0xc0, 0xfd, + 0x67, 0x00, 0x00, 0x00, 0xff, 0xff, 0x1b, 0x10, 0x0e, 0x63, 0x80, 0x3d, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto index da5d6d3bd7..3777741c5e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,15 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.extensions.v1beta1; +package k8s.io.client_go.pkg.apis.extensions.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; +import "k8s.io/apimachinery/pkg/api/resource/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; @@ -37,18 +39,12 @@ message APIVersion { optional string name = 1; } -message CPUTargetUtilization { - // fraction of the requested CPU that should be utilized/used, - // e.g. 70 means that 70% of the requested CPU should be in use. - optional int32 targetPercentage = 1; -} - message CustomMetricCurrentStatus { // Custom Metric name. optional string name = 1; // Custom Metric value (average). - optional k8s.io.kubernetes.pkg.api.resource.Quantity value = 2; + optional k8s.io.apimachinery.pkg.api.resource.Quantity value = 2; } message CustomMetricCurrentStatusList { @@ -61,7 +57,7 @@ message CustomMetricTarget { optional string name = 1; // Custom Metric value (average). - optional k8s.io.kubernetes.pkg.api.resource.Quantity value = 2; + optional k8s.io.apimachinery.pkg.api.resource.Quantity value = 2; } message CustomMetricTargetList { @@ -71,20 +67,20 @@ message CustomMetricTargetList { // DaemonSet represents the configuration of a daemon set. message DaemonSet { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // Spec defines the desired behavior of this daemon set. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // The desired behavior of this daemon set. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional DaemonSetSpec spec = 2; - // Status is the current status of this daemon set. This data may be + // The current status of this daemon set. This data may be // out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional DaemonSetStatus status = 3; } @@ -92,58 +88,122 @@ message DaemonSet { // DaemonSetList is a collection of daemon sets. message DaemonSetList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; - // Items is a list of daemon sets. + // A list of daemon sets. repeated DaemonSet items = 2; } // DaemonSetSpec is the specification of a daemon set. message DaemonSetSpec { - // Selector is a label query over pods that are managed by the daemon set. + // A label query over pods that are managed by the daemon set. // Must match in order to be controlled. // If empty, defaulted to labels on Pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 1; - // Template is the object that describes the pod that will be created. + // An object that describes the pod that will be created. // The DaemonSet will create exactly one copy of this pod on every node // that matches the template's node selector (or on every node if no node // selector is specified). - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 2; + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 2; + + // An update strategy to replace existing DaemonSet pods with new pods. + // +optional + optional DaemonSetUpdateStrategy updateStrategy = 3; + + // The minimum number of seconds for which a newly created DaemonSet pod should + // be ready without any of its container crashing, for it to be considered + // available. Defaults to 0 (pod will be considered available as soon as it + // is ready). + // +optional + optional int32 minReadySeconds = 4; + + // DEPRECATED. + // A sequence number representing a specific generation of the template. + // Populated by the system. It can be set only during the creation. + // +optional + optional int64 templateGeneration = 5; + + // The number of old history to retain to allow rollback. + // This is a pointer to distinguish between explicit zero and not specified. + // Defaults to 10. + // +optional + optional int32 revisionHistoryLimit = 6; } // DaemonSetStatus represents the current status of a daemon set. message DaemonSetStatus { - // CurrentNumberScheduled is the number of nodes that are running at least 1 + // The number of nodes that are running at least 1 // daemon pod and are supposed to run the daemon pod. - // More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ optional int32 currentNumberScheduled = 1; - // NumberMisscheduled is the number of nodes that are running the daemon pod, but are + // The number of nodes that are running the daemon pod, but are // not supposed to run the daemon pod. - // More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ optional int32 numberMisscheduled = 2; - // DesiredNumberScheduled is the total number of nodes that should be running the daemon + // The total number of nodes that should be running the daemon // pod (including nodes correctly running the daemon pod). - // More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ optional int32 desiredNumberScheduled = 3; - // NumberReady is the number of nodes that should be running the daemon pod and have one + // The number of nodes that should be running the daemon pod and have one // or more of the daemon pod running and ready. optional int32 numberReady = 4; + + // The most recent generation observed by the daemon set controller. + // +optional + optional int64 observedGeneration = 5; + + // The total number of nodes that are running updated daemon pod + // +optional + optional int32 updatedNumberScheduled = 6; + + // The number of nodes that should be running the + // daemon pod and have one or more of the daemon pod running and + // available (ready for at least spec.minReadySeconds) + // +optional + optional int32 numberAvailable = 7; + + // The number of nodes that should be running the + // daemon pod and have none of the daemon pod running and available + // (ready for at least spec.minReadySeconds) + // +optional + optional int32 numberUnavailable = 8; + + // Count of hash collisions for the DaemonSet. The DaemonSet controller + // uses this field as a collision avoidance mechanism when it needs to + // create the name for the newest ControllerRevision. + // +optional + optional int64 collisionCount = 9; +} + +message DaemonSetUpdateStrategy { + // Type of daemon set update. Can be "RollingUpdate" or "OnDelete". + // Default is OnDelete. + // +optional + optional string type = 1; + + // Rolling update config params. Present only if type = "RollingUpdate". + // --- + // TODO: Update this to follow our convention for oneOf, whatever we decide it + // to be. Same as Deployment `strategy.rollingUpdate`. + // See https://github.com/kubernetes/kubernetes/issues/35345 + // +optional + optional RollingUpdateDaemonSet rollingUpdate = 2; } // Deployment enables declarative updates for Pods and ReplicaSets. message Deployment { // Standard object metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Specification of the desired behavior of the Deployment. // +optional @@ -163,10 +223,10 @@ message DeploymentCondition { optional string status = 2; // The last time this condition was updated. - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastUpdateTime = 6; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastUpdateTime = 6; // Last time the condition transitioned from one status to another. - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 7; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 7; // The reason for the condition's last transition. optional string reason = 4; @@ -179,7 +239,7 @@ message DeploymentCondition { message DeploymentList { // Standard list metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of Deployments. repeated Deployment items = 2; @@ -208,10 +268,10 @@ message DeploymentSpec { // Label selector for pods. Existing ReplicaSets whose pods are // selected by this will be the ones affected by this deployment. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; // Template describes the pods that will be created. - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; // The deployment strategy to use to replace existing pods with new ones. // +optional @@ -261,6 +321,10 @@ message DeploymentStatus { // +optional optional int32 updatedReplicas = 3; + // Total number of ready pods targeted by this deployment. + // +optional + optional int32 readyReplicas = 7; + // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. // +optional optional int32 availableReplicas = 4; @@ -270,7 +334,15 @@ message DeploymentStatus { optional int32 unavailableReplicas = 5; // Represents the latest available observations of a deployment's current state. + // +patchMergeKey=type + // +patchStrategy=merge repeated DeploymentCondition conditions = 6; + + // Count of hash collisions for the Deployment. The Deployment controller uses this + // field as a collision avoidance mechanism when it needs to create the name for the + // newest ReplicaSet. + // +optional + optional int64 collisionCount = 8; } // DeploymentStrategy describes how to replace existing pods with new ones. @@ -288,15 +360,6 @@ message DeploymentStrategy { optional RollingUpdateDeployment rollingUpdate = 2; } -// ExportOptions is the query options to the standard REST get call. -message ExportOptions { - // Should this value be exported. Export strips fields that a user can not specify. - optional bool export = 1; - - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' - optional bool exact = 2; -} - // FSGroupStrategyOptions defines the strategy type and options used to create the strategy. message FSGroupStrategyOptions { // Rule is the strategy that will dictate what FSGroup is used in the SecurityContext. @@ -337,73 +400,6 @@ message HTTPIngressRuleValue { repeated HTTPIngressPath paths = 1; } -// configuration of a horizontal pod autoscaler. -message HorizontalPodAutoscaler { - // Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; - - // behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. - // +optional - optional HorizontalPodAutoscalerSpec spec = 2; - - // current information about the autoscaler. - // +optional - optional HorizontalPodAutoscalerStatus status = 3; -} - -// list of horizontal pod autoscaler objects. -message HorizontalPodAutoscalerList { - // Standard list metadata. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; - - // list of horizontal pod autoscaler objects. - repeated HorizontalPodAutoscaler items = 2; -} - -// specification of a horizontal pod autoscaler. -message HorizontalPodAutoscalerSpec { - // reference to Scale subresource; horizontal pod autoscaler will learn the current resource consumption from its status, - // and will set the desired number of pods by modifying its spec. - optional SubresourceReference scaleRef = 1; - - // lower limit for the number of pods that can be set by the autoscaler, default 1. - // +optional - optional int32 minReplicas = 2; - - // upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas. - optional int32 maxReplicas = 3; - - // target average CPU utilization (represented as a percentage of requested CPU) over all the pods; - // if not specified it defaults to the target CPU utilization at 80% of the requested resources. - // +optional - optional CPUTargetUtilization cpuUtilization = 4; -} - -// current status of a horizontal pod autoscaler -message HorizontalPodAutoscalerStatus { - // most recent generation observed by this autoscaler. - // +optional - optional int64 observedGeneration = 1; - - // last time the HorizontalPodAutoscaler scaled the number of pods; - // used by the autoscaler to control how often the number of pods is changed. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastScaleTime = 2; - - // current number of replicas of pods managed by this autoscaler. - optional int32 currentReplicas = 3; - - // desired number of replicas of pods managed by this autoscaler. - optional int32 desiredReplicas = 4; - - // current average CPU utilization over all pods, represented as a percentage of requested CPU, - // e.g. 70 means that an average pod is using now 70% of its requested CPU. - // +optional - optional int32 currentCPUUtilizationPercentage = 5; -} - // Host Port Range defines a range of host ports that will be enabled by a policy // for pods to use. It requires both the start and end to be defined. message HostPortRange { @@ -429,17 +425,17 @@ message IDRange { // based virtual hosting etc. message Ingress { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec is the desired state of the Ingress. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional IngressSpec spec = 2; // Status is the current state of the Ingress. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional IngressStatus status = 3; } @@ -450,15 +446,15 @@ message IngressBackend { optional string serviceName = 1; // Specifies the port of the referenced service. - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString servicePort = 2; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString servicePort = 2; } // IngressList is a collection of Ingress. message IngressList { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of Ingress. repeated Ingress items = 2; @@ -528,7 +524,7 @@ message IngressSpec { message IngressStatus { // LoadBalancer contains the current status of the load-balancer. // +optional - optional k8s.io.kubernetes.pkg.api.v1.LoadBalancerStatus loadBalancer = 1; + optional k8s.io.client_go.pkg.api.v1.LoadBalancerStatus loadBalancer = 1; } // IngressTLS describes the transport layer security associated with an Ingress. @@ -549,143 +545,12 @@ message IngressTLS { optional string secretName = 2; } -// Job represents the configuration of a single job. -// DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead. -message Job { - // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; - - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - optional JobSpec spec = 2; - - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - optional JobStatus status = 3; -} - -// JobCondition describes current state of a job. -message JobCondition { - // Type of job condition, Complete or Failed. - optional string type = 1; - - // Status of the condition, one of True, False, Unknown. - optional string status = 2; - - // Last time the condition was checked. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastProbeTime = 3; - - // Last time the condition transit from one status to another. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 4; - - // (brief) reason for the condition's last transition. - // +optional - optional string reason = 5; - - // Human readable message indicating details about last transition. - // +optional - optional string message = 6; -} - -// JobList is a collection of jobs. -// DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead. -message JobList { - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; - - // Items is the list of Job. - repeated Job items = 2; -} - -// JobSpec describes how the job execution will look like. -message JobSpec { - // Parallelism specifies the maximum desired number of pods the job should - // run at any given time. The actual number of pods running in steady state will - // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), - // i.e. when the work left to do is less than max parallelism. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - optional int32 parallelism = 1; - - // Completions specifies the desired number of successfully finished pods the - // job should be run with. Setting to nil means that the success of any - // pod signals the success of all pods, and allows parallelism to have any positive - // value. Setting to 1 means that parallelism is limited to 1 and the success of that - // pod signals the success of the job. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - optional int32 completions = 2; - - // Optional duration in seconds relative to the startTime that the job may be active - // before the system tries to terminate it; value must be positive integer - // +optional - optional int64 activeDeadlineSeconds = 3; - - // Selector is a label query over pods that should match the pod count. - // Normally, the system sets this field for you. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 4; - - // AutoSelector controls generation of pod labels and pod selectors. - // It was not present in the original extensions/v1beta1 Job definition, but exists - // to allow conversion from batch/v1 Jobs, where it corresponds to, but has the opposite - // meaning as, ManualSelector. - // More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md - // +optional - optional bool autoSelector = 5; - - // Template is the object that describes the pod that will be created when - // executing a job. - // More info: http://kubernetes.io/docs/user-guide/jobs - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 6; -} - -// JobStatus represents the current state of a Job. -message JobStatus { - // Conditions represent the latest available observations of an object's current state. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - repeated JobCondition conditions = 1; - - // StartTime represents time when the job was acknowledged by the Job Manager. - // It is not guaranteed to be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time startTime = 2; - - // CompletionTime represents time when the job was completed. It is not guaranteed to - // be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time completionTime = 3; - - // Active is the number of actively running pods. - // +optional - optional int32 active = 4; - - // Succeeded is the number of pods which reached Phase Succeeded. - // +optional - optional int32 succeeded = 5; - - // Failed is the number of pods which reached Phase Failed. - // +optional - optional int32 failed = 6; -} - +// NetworkPolicy describes what network traffic is allowed for a set of Pods message NetworkPolicy { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Specification of the desired behavior for this NetworkPolicy. // +optional @@ -696,21 +561,17 @@ message NetworkPolicy { message NetworkPolicyIngressRule { // List of ports which should be made accessible on the pods selected for this rule. // Each item in this list is combined using a logical OR. - // If this field is not provided, this rule matches all ports (traffic not restricted by port). - // If this field is empty, this rule matches no ports (no traffic matches). + // If this field is empty or missing, this rule matches all ports (traffic not restricted by port). // If this field is present and contains at least one item, then this rule allows traffic // only if the traffic matches at least one port in the list. - // TODO: Update this to be a pointer to slice as soon as auto-generation supports it. // +optional repeated NetworkPolicyPort ports = 1; // List of sources which should be able to access the pods selected for this rule. // Items in this list are combined using a logical OR operation. - // If this field is not provided, this rule matches all sources (traffic not restricted by source). - // If this field is empty, this rule matches no sources (no traffic matches). + // If this field is empty or missing, this rule matches all sources (traffic not restricted by source). // If this field is present and contains at least on item, this rule allows traffic only if the // traffic matches at least one item in the from list. - // TODO: Update this to be a pointer to slice as soon as auto-generation supports it. // +optional repeated NetworkPolicyPeer from = 2; } @@ -718,9 +579,9 @@ message NetworkPolicyIngressRule { // Network Policy List is a list of NetworkPolicy objects. message NetworkPolicyList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of schema objects. repeated NetworkPolicy items = 2; @@ -729,18 +590,16 @@ message NetworkPolicyList { message NetworkPolicyPeer { // This is a label selector which selects Pods in this namespace. // This field follows standard label selector semantics. - // If not provided, this selector selects no pods. // If present but empty, this selector selects all pods in this namespace. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector podSelector = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; // Selects Namespaces using cluster scoped-labels. This // matches all pods in all namespaces selected by this label selector. // This field follows standard label selector semantics. - // If omitted, this selector selects no namespaces. // If present but empty, this selector selects all namespaces. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector namespaceSelector = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 2; } message NetworkPolicyPort { @@ -755,7 +614,7 @@ message NetworkPolicyPort { // If present, only traffic on the specified protocol AND port // will be matched. // +optional - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString port = 2; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 2; } message NetworkPolicySpec { @@ -764,16 +623,15 @@ message NetworkPolicySpec { // same set of pods. In this case, the ingress rules for each are combined additively. // This field is NOT optional and follows standard label selector semantics. // An empty podSelector matches all pods in this namespace. - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector podSelector = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional repeated NetworkPolicyIngressRule ingress = 2; } @@ -782,9 +640,9 @@ message NetworkPolicySpec { // that will be applied to a pod and container. message PodSecurityPolicy { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // spec defines the policy enforced. // +optional @@ -794,9 +652,9 @@ message PodSecurityPolicy { // Pod Security Policy List is a list of PodSecurityPolicy objects. message PodSecurityPolicyList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of schema objects. repeated PodSecurityPolicy items = 2; @@ -871,12 +729,12 @@ message PodSecurityPolicySpec { message ReplicaSet { // If the Labels of a ReplicaSet are empty, they are defaulted to // be the same as the Pod(s) that the ReplicaSet manages. - // Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Spec defines the specification of the desired behavior of the ReplicaSet. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ReplicaSetSpec spec = 2; @@ -884,7 +742,7 @@ message ReplicaSet { // This data may be out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional optional ReplicaSetStatus status = 3; } @@ -899,7 +757,7 @@ message ReplicaSetCondition { // The last time the condition transitioned from one status to another. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.Time lastTransitionTime = 3; + optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 3; // The reason for the condition's last transition. // +optional @@ -913,12 +771,12 @@ message ReplicaSetCondition { // ReplicaSetList is a collection of ReplicaSets. message ReplicaSetList { // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // List of ReplicaSets. - // More info: http://kubernetes.io/docs/user-guide/replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller repeated ReplicaSet items = 2; } @@ -927,7 +785,7 @@ message ReplicaSetSpec { // Replicas is the number of desired replicas. // This is a pointer to distinguish between explicit zero and unspecified. // Defaults to 1. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller // +optional optional int32 replicas = 1; @@ -940,21 +798,21 @@ message ReplicaSetSpec { // Selector is a label query over pods that should match the replica count. // If the selector is empty, it is defaulted to the labels present on the pod template. // Label keys and values that must match in order to be controlled by this replica set. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; // Template is the object that describes the pod that will be created if // insufficient replicas are detected. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template // +optional - optional k8s.io.kubernetes.pkg.api.v1.PodTemplateSpec template = 3; + optional k8s.io.client_go.pkg.api.v1.PodTemplateSpec template = 3; } // ReplicaSetStatus represents the current status of a ReplicaSet. message ReplicaSetStatus { // Replicas is the most recently oberved number of replicas. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller optional int32 replicas = 1; // The number of pods that have labels matching the labels of the pod template of the replicaset. @@ -975,6 +833,8 @@ message ReplicaSetStatus { // Represents the latest available observations of a replica set's current state. // +optional + // +patchMergeKey=type + // +patchStrategy=merge repeated ReplicaSetCondition conditions = 6; } @@ -983,16 +843,36 @@ message ReplicationControllerDummy { } message RollbackConfig { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional optional int64 revision = 1; } +// Spec to control the desired behavior of daemon set rolling update. +message RollingUpdateDaemonSet { + // The maximum number of DaemonSet pods that can be unavailable during the + // update. Value can be an absolute number (ex: 5) or a percentage of total + // number of DaemonSet pods at the start of the update (ex: 10%). Absolute + // number is calculated from percentage by rounding up. + // This cannot be 0. + // Default value is 1. + // Example: when this is set to 30%, at most 30% of the total number of nodes + // that should be running the daemon pod (i.e. status.desiredNumberScheduled) + // can have their pods stopped for an update at any given + // time. The update starts by stopping at most 30% of those DaemonSet pods + // and then brings up new DaemonSet pods in their place. Once the new pods + // are available, it then proceeds onto other DaemonSet pods, thus ensuring + // that at least 70% of original number of DaemonSet pods are available at + // all times during the update. + // +optional + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString maxUnavailable = 1; +} + // Spec to control the desired behavior of rolling update. message RollingUpdateDeployment { // The maximum number of pods that can be unavailable during the update. // Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). - // Absolute number is calculated from percentage by rounding up. + // Absolute number is calculated from percentage by rounding down. // This can not be 0 if MaxSurge is 0. // By default, a fixed value of 1 is used. // Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods @@ -1001,7 +881,7 @@ message RollingUpdateDeployment { // that the total number of pods available at all times during the update is at // least 70% of desired pods. // +optional - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString maxUnavailable = 1; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString maxUnavailable = 1; // The maximum number of pods that can be scheduled above the desired number of // pods. @@ -1015,7 +895,7 @@ message RollingUpdateDeployment { // new RC can be scaled up further, ensuring that total number of pods running // at any time during the update is atmost 130% of desired pods. // +optional - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString maxSurge = 2; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString maxSurge = 2; } // Run A sUser Strategy Options defines the strategy type and any options used to create the strategy. @@ -1034,22 +914,22 @@ message SELinuxStrategyOptions { optional string rule = 1; // seLinuxOptions required to run as; required for MustRunAs - // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context + // More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md // +optional - optional k8s.io.kubernetes.pkg.api.v1.SELinuxOptions seLinuxOptions = 2; + optional k8s.io.client_go.pkg.api.v1.SELinuxOptions seLinuxOptions = 2; } // represents a scaling request for a resource. message Scale { - // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; - // defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional optional ScaleSpec spec = 2; - // current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only. + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. // +optional optional ScaleStatus status = 3; } @@ -1075,30 +955,11 @@ message ScaleStatus { // avoid introspection in the clients. The string will be in the same format as the // query-param syntax. If the target type only supports map-based selectors, both this // field and map-based selector field are populated. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional optional string targetSelector = 3; } -// SubresourceReference contains enough information to let you inspect or modify the referred subresource. -message SubresourceReference { - // Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - // +optional - optional string kind = 1; - - // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names - // +optional - optional string name = 2; - - // API version of the referent - // +optional - optional string apiVersion = 3; - - // Subresource name of the referent - // +optional - optional string subresource = 4; -} - // SupplementalGroupsStrategyOptions defines the strategy type and options used to create the strategy. message SupplementalGroupsStrategyOptions { // Rule is the strategy that will dictate what supplemental groups is used in the SecurityContext. @@ -1116,7 +977,7 @@ message SupplementalGroupsStrategyOptions { message ThirdPartyResource { // Standard object metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Description is the description of this object. // +optional @@ -1131,7 +992,7 @@ message ThirdPartyResource { message ThirdPartyResourceData { // Standard object metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Data is the raw JSON data for this data. // +optional @@ -1141,9 +1002,9 @@ message ThirdPartyResourceData { // ThirdPartyResrouceDataList is a list of ThirdPartyResourceData. message ThirdPartyResourceDataList { // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of ThirdpartyResourceData. repeated ThirdPartyResourceData items = 2; @@ -1153,7 +1014,7 @@ message ThirdPartyResourceDataList { message ThirdPartyResourceList { // Standard list metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of ThirdPartyResources. repeated ThirdPartyResource items = 2; diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/register.go index f8e81972bc..bf8616b888 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/register.go @@ -17,33 +17,43 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "extensions" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1beta1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs, addConversionFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &Deployment{}, &DeploymentList{}, &DeploymentRollback{}, - &HorizontalPodAutoscaler{}, - &HorizontalPodAutoscalerList{}, - &Job{}, - &JobList{}, &ReplicationControllerDummy{}, &Scale{}, &ThirdPartyResource{}, @@ -54,9 +64,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ThirdPartyResourceDataList{}, &Ingress{}, &IngressList{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, &ReplicaSet{}, &ReplicaSetList{}, &PodSecurityPolicy{}, @@ -65,6 +72,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { &NetworkPolicyList{}, ) // Add the watch version that applies - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go index 752fb71ec7..8d4e39b66e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.generated.go @@ -25,11 +25,11 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg4_resource "k8s.io/client-go/pkg/api/resource" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" - pkg5_intstr "k8s.io/client-go/pkg/util/intstr" + pkg3_resource "k8s.io/apimachinery/pkg/api/resource" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg5_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg4_v1 "k8s.io/client-go/pkg/api/v1" "reflect" "runtime" time "time" @@ -65,11 +65,11 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg4_resource.Quantity - var v1 pkg1_unversioned.TypeMeta - var v2 pkg2_v1.ObjectMeta - var v3 pkg3_types.UID - var v4 pkg5_intstr.IntOrString + var v0 pkg3_resource.Quantity + var v1 pkg1_v1.TypeMeta + var v2 pkg2_types.UID + var v3 pkg5_intstr.IntOrString + var v4 pkg4_v1.PodTemplateSpec var v5 time.Time _, _, _, _, _, _ = v0, v1, v2, v3, v4, v5 } @@ -144,25 +144,25 @@ func (x *ScaleSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym6 := z.DecBinary() - _ = yym6 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct7 := r.ContainerType() - if yyct7 == codecSelferValueTypeMap1234 { - yyl7 := r.ReadMapStart() - if yyl7 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl7, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct7 == codecSelferValueTypeArray1234 { - yyl7 := r.ReadArrayStart() - if yyl7 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl7, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -174,12 +174,12 @@ func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys8Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys8Slc - var yyhl8 bool = l >= 0 - for yyj8 := 0; ; yyj8++ { - if yyhl8 { - if yyj8 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -188,20 +188,26 @@ func (x *ScaleSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys8Slc = r.DecodeBytes(yys8Slc, true, true) - yys8 := string(yys8Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys8 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys8) - } // end switch yys8 - } // end for yyj8 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -209,16 +215,16 @@ func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj10 int - var yyb10 bool - var yyhl10 bool = l >= 0 - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb10 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb10 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -226,20 +232,26 @@ func (x *ScaleSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv7 := &x.Replicas + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + *((*int32)(yyv7)) = int32(r.DecodeInt(32)) + } } for { - yyj10++ - if yyhl10 { - yyb10 = yyj10 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb10 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb10 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj10-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -251,35 +263,35 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym12 := z.EncBinary() - _ = yym12 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep13 := !z.EncBinary() - yy2arr13 := z.EncBasicHandle().StructToArray - var yyq13 [3]bool - _, _, _ = yysep13, yyq13, yy2arr13 - const yyr13 bool = false - yyq13[1] = len(x.Selector) != 0 - yyq13[2] = x.TargetSelector != "" - var yynn13 int - if yyr13 || yy2arr13 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Selector) != 0 + yyq2[2] = x.TargetSelector != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn13 = 1 - for _, b := range yyq13 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn13++ + yynn2++ } } - r.EncodeMapStart(yynn13) - yynn13 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr13 || yy2arr13 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym15 := z.EncBinary() - _ = yym15 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Replicas)) @@ -288,21 +300,21 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym16 := z.EncBinary() - _ = yym16 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Replicas)) } } - if yyr13 || yy2arr13 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq13[1] { + if yyq2[1] { if x.Selector == nil { r.EncodeNil() } else { - yym18 := z.EncBinary() - _ = yym18 + yym7 := z.EncBinary() + _ = yym7 if false { } else { z.F.EncMapStringStringV(x.Selector, false, e) @@ -312,15 +324,15 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq13[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Selector == nil { r.EncodeNil() } else { - yym19 := z.EncBinary() - _ = yym19 + yym8 := z.EncBinary() + _ = yym8 if false { } else { z.F.EncMapStringStringV(x.Selector, false, e) @@ -328,11 +340,11 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr13 || yy2arr13 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq13[2] { - yym21 := z.EncBinary() - _ = yym21 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.TargetSelector)) @@ -341,19 +353,19 @@ func (x *ScaleStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq13[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("targetSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym22 := z.EncBinary() - _ = yym22 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.TargetSelector)) } } } - if yyr13 || yy2arr13 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -366,25 +378,25 @@ func (x *ScaleStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym23 := z.DecBinary() - _ = yym23 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct24 := r.ContainerType() - if yyct24 == codecSelferValueTypeMap1234 { - yyl24 := r.ReadMapStart() - if yyl24 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl24, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct24 == codecSelferValueTypeArray1234 { - yyl24 := r.ReadArrayStart() - if yyl24 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl24, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -396,12 +408,12 @@ func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys25Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys25Slc - var yyhl25 bool = l >= 0 - for yyj25 := 0; ; yyj25++ { - if yyhl25 { - if yyj25 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -410,38 +422,50 @@ func (x *ScaleStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys25Slc = r.DecodeBytes(yys25Slc, true, true) - yys25 := string(yys25Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys25 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "selector": if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv27 := &x.Selector - yym28 := z.DecBinary() - _ = yym28 + yyv6 := &x.Selector + yym7 := z.DecBinary() + _ = yym7 if false { } else { - z.F.DecMapStringStringX(yyv27, false, d) + z.F.DecMapStringStringX(yyv6, false, d) } } case "targetSelector": if r.TryDecodeAsNil() { x.TargetSelector = "" } else { - x.TargetSelector = string(r.DecodeString()) + yyv8 := &x.TargetSelector + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys25) - } // end switch yys25 - } // end for yyj25 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -449,16 +473,16 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj30 int - var yyb30 bool - var yyhl30 bool = l >= 0 - yyj30++ - if yyhl30 { - yyb30 = yyj30 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb30 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb30 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -466,15 +490,21 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv11 := &x.Replicas + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(yyv11)) = int32(r.DecodeInt(32)) + } } - yyj30++ - if yyhl30 { - yyb30 = yyj30 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb30 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb30 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -482,21 +512,21 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Selector = nil } else { - yyv32 := &x.Selector - yym33 := z.DecBinary() - _ = yym33 + yyv13 := &x.Selector + yym14 := z.DecBinary() + _ = yym14 if false { } else { - z.F.DecMapStringStringX(yyv32, false, d) + z.F.DecMapStringStringX(yyv13, false, d) } } - yyj30++ - if yyhl30 { - yyb30 = yyj30 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb30 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb30 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -504,20 +534,26 @@ func (x *ScaleStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TargetSelector = "" } else { - x.TargetSelector = string(r.DecodeString()) + yyv15 := &x.TargetSelector + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj30++ - if yyhl30 { - yyb30 = yyj30 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb30 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb30 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj30-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -529,39 +565,39 @@ func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym35 := z.EncBinary() - _ = yym35 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep36 := !z.EncBinary() - yy2arr36 := z.EncBasicHandle().StructToArray - var yyq36 [5]bool - _, _, _ = yysep36, yyq36, yy2arr36 - const yyr36 bool = false - yyq36[0] = x.Kind != "" - yyq36[1] = x.APIVersion != "" - yyq36[2] = true - yyq36[3] = true - yyq36[4] = true - var yynn36 int - if yyr36 || yy2arr36 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn36 = 0 - for _, b := range yyq36 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn36++ + yynn2++ } } - r.EncodeMapStart(yynn36) - yynn36 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr36 || yy2arr36 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq36[0] { - yym38 := z.EncBinary() - _ = yym38 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -570,23 +606,23 @@ func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq36[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr36 || yy2arr36 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq36[1] { - yym41 := z.EncBinary() - _ = yym41 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -595,70 +631,82 @@ func (x *Scale) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq36[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym42 := z.EncBinary() - _ = yym42 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr36 || yy2arr36 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq36[2] { - yy44 := &x.ObjectMeta - yy44.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq36[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy45 := &x.ObjectMeta - yy45.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr36 || yy2arr36 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq36[3] { - yy47 := &x.Spec - yy47.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq36[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy48 := &x.Spec - yy48.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr36 || yy2arr36 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq36[4] { - yy50 := &x.Status - yy50.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq36[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy51 := &x.Status - yy51.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr36 || yy2arr36 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -671,25 +719,25 @@ func (x *Scale) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym52 := z.DecBinary() - _ = yym52 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct53 := r.ContainerType() - if yyct53 == codecSelferValueTypeMap1234 { - yyl53 := r.ReadMapStart() - if yyl53 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl53, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct53 == codecSelferValueTypeArray1234 { - yyl53 := r.ReadArrayStart() - if yyl53 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl53, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -701,12 +749,12 @@ func (x *Scale) 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 { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -715,47 +763,65 @@ func (x *Scale) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys54Slc = r.DecodeBytes(yys54Slc, true, true) - yys54 := string(yys54Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys54 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv57 := &x.ObjectMeta - yyv57.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = ScaleSpec{} } else { - yyv58 := &x.Spec - yyv58.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = ScaleStatus{} } else { - yyv59 := &x.Status - yyv59.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys54) - } // end switch yys54 - } // end for yyj54 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -763,16 +829,16 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj60 int - var yyb60 bool - var yyhl60 bool = l >= 0 - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb60 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb60 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -780,15 +846,21 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb60 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb60 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -796,32 +868,44 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb60 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb60 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv63 := &x.ObjectMeta - yyv63.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb60 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb60 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -829,16 +913,16 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = ScaleSpec{} } else { - yyv64 := &x.Spec - yyv64.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb60 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb60 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -846,21 +930,21 @@ func (x *Scale) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = ScaleStatus{} } else { - yyv65 := &x.Status - yyv65.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj60++ - if yyhl60 { - yyb60 = yyj60 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb60 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb60 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj60-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -872,36 +956,36 @@ func (x *ReplicationControllerDummy) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym66 := z.EncBinary() - _ = yym66 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep67 := !z.EncBinary() - yy2arr67 := z.EncBasicHandle().StructToArray - var yyq67 [2]bool - _, _, _ = yysep67, yyq67, yy2arr67 - const yyr67 bool = false - yyq67[0] = x.Kind != "" - yyq67[1] = x.APIVersion != "" - var yynn67 int - if yyr67 || yy2arr67 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn67 = 0 - for _, b := range yyq67 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn67++ + yynn2++ } } - r.EncodeMapStart(yynn67) - yynn67 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr67 || yy2arr67 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq67[0] { - yym69 := z.EncBinary() - _ = yym69 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -910,23 +994,23 @@ func (x *ReplicationControllerDummy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq67[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym70 := z.EncBinary() - _ = yym70 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr67 || yy2arr67 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq67[1] { - yym72 := z.EncBinary() - _ = yym72 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -935,19 +1019,19 @@ func (x *ReplicationControllerDummy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq67[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym73 := z.EncBinary() - _ = yym73 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr67 || yy2arr67 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -960,25 +1044,25 @@ func (x *ReplicationControllerDummy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym74 := z.DecBinary() - _ = yym74 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct75 := r.ContainerType() - if yyct75 == codecSelferValueTypeMap1234 { - yyl75 := r.ReadMapStart() - if yyl75 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl75, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct75 == codecSelferValueTypeArray1234 { - yyl75 := r.ReadArrayStart() - if yyl75 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl75, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -990,12 +1074,12 @@ func (x *ReplicationControllerDummy) codecDecodeSelfFromMap(l int, d *codec1978. var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys76Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys76Slc - var yyhl76 bool = l >= 0 - for yyj76 := 0; ; yyj76++ { - if yyhl76 { - if yyj76 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1004,26 +1088,38 @@ func (x *ReplicationControllerDummy) codecDecodeSelfFromMap(l int, d *codec1978. } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys76Slc = r.DecodeBytes(yys76Slc, true, true) - yys76 := string(yys76Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys76 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys76) - } // end switch yys76 - } // end for yyj76 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1031,16 +1127,16 @@ func (x *ReplicationControllerDummy) codecDecodeSelfFromArray(l int, d *codec197 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj79 int - var yyb79 bool - var yyhl79 bool = l >= 0 - yyj79++ - if yyhl79 { - yyb79 = yyj79 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb79 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb79 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1048,15 +1144,21 @@ func (x *ReplicationControllerDummy) codecDecodeSelfFromArray(l int, d *codec197 if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv9 := &x.Kind + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj79++ - if yyhl79 { - yyb79 = yyj79 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb79 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb79 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1064,159 +1166,107 @@ func (x *ReplicationControllerDummy) codecDecodeSelfFromArray(l int, d *codec197 if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv11 := &x.APIVersion + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj79++ - if yyhl79 { - yyb79 = yyj79 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb79 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb79 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj79-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *SubresourceReference) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *CustomMetricTarget) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym82 := z.EncBinary() - _ = yym82 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep83 := !z.EncBinary() - yy2arr83 := z.EncBasicHandle().StructToArray - var yyq83 [4]bool - _, _, _ = yysep83, yyq83, yy2arr83 - const yyr83 bool = false - yyq83[0] = x.Kind != "" - yyq83[1] = x.Name != "" - yyq83[2] = x.APIVersion != "" - yyq83[3] = x.Subresource != "" - var yynn83 int - if yyr83 || yy2arr83 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn83 = 0 - for _, b := range yyq83 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn83++ + yynn2++ } } - r.EncodeMapStart(yynn83) - yynn83 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr83 || yy2arr83 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq83[0] { - yym85 := z.EncBinary() - _ = yym85 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } else { - if yyq83[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym86 := z.EncBinary() - _ = yym86 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr83 || yy2arr83 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq83[1] { - yym88 := z.EncBinary() - _ = yym88 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } + 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, "") - } - } else { - if yyq83[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym89 := z.EncBinary() - _ = yym89 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr83 || yy2arr83 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq83[2] { - yym91 := z.EncBinary() - _ = yym91 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } + yy7 := &x.TargetValue + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) } else { - r.EncodeString(codecSelferC_UTF81234, "") + z.EncFallback(yy7) } } else { - if yyq83[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym92 := z.EncBinary() - _ = yym92 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr83 || yy2arr83 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq83[3] { - yym94 := z.EncBinary() - _ = yym94 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) - } + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("value")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.TargetValue + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq83[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("subresource")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym95 := z.EncBinary() - _ = yym95 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Subresource)) - } + z.EncFallback(yy9) } } - if yyr83 || yy2arr83 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1225,29 +1275,29 @@ func (x *SubresourceReference) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *SubresourceReference) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *CustomMetricTarget) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym96 := z.DecBinary() - _ = yym96 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct97 := r.ContainerType() - if yyct97 == codecSelferValueTypeMap1234 { - yyl97 := r.ReadMapStart() - if yyl97 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl97, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct97 == codecSelferValueTypeArray1234 { - yyl97 := r.ReadArrayStart() - if yyl97 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl97, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1255,16 +1305,16 @@ func (x *SubresourceReference) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *SubresourceReference) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *CustomMetricTarget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys98Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys98Slc - var yyhl98 bool = l >= 0 - for yyj98 := 0; ; yyj98++ { - if yyhl98 { - if yyj98 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1273,71 +1323,58 @@ func (x *SubresourceReference) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys98Slc = r.DecodeBytes(yys98Slc, true, true) - yys98 := string(yys98Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys98 { - case "kind": - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) - } - case "apiVersion": - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "subresource": + case "value": if r.TryDecodeAsNil() { - x.Subresource = "" + x.TargetValue = pkg3_resource.Quantity{} } else { - x.Subresource = string(r.DecodeString()) + yyv6 := &x.TargetValue + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } } default: - z.DecStructFieldNotFound(-1, yys98) - } // end switch yys98 - } // end for yyj98 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *SubresourceReference) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *CustomMetricTarget) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj103 int - var yyb103 bool - var yyhl103 bool = l >= 0 - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb103 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb103 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1345,106 +1382,113 @@ func (x *SubresourceReference) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) - } - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l - } else { - yyb103 = r.CheckBreak() - } - if yyb103 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) + yyv9 := &x.Name + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb103 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb103 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Subresource = "" + x.TargetValue = pkg3_resource.Quantity{} } else { - x.Subresource = string(r.DecodeString()) + yyv11 := &x.TargetValue + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) + } else { + z.DecFallback(yyv11, false) + } } for { - yyj103++ - if yyhl103 { - yyb103 = yyj103 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb103 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb103 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj103-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *CPUTargetUtilization) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *CustomMetricTargetList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym108 := z.EncBinary() - _ = yym108 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep109 := !z.EncBinary() - yy2arr109 := z.EncBasicHandle().StructToArray - var yyq109 [1]bool - _, _, _ = yysep109, yyq109, yy2arr109 - const yyr109 bool = false - var yynn109 int - if yyr109 || yy2arr109 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn109 = 1 - for _, b := range yyq109 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn109++ + yynn2++ } } - r.EncodeMapStart(yynn109) - yynn109 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr109 || yy2arr109 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym111 := z.EncBinary() - _ = yym111 - if false { + if x.Items == nil { + r.EncodeNil() } else { - r.EncodeInt(int64(x.TargetPercentage)) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceCustomMetricTarget(([]CustomMetricTarget)(x.Items), e) + } } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("targetPercentage")) + r.EncodeString(codecSelferC_UTF81234, string("items")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym112 := z.EncBinary() - _ = yym112 - if false { + if x.Items == nil { + r.EncodeNil() } else { - r.EncodeInt(int64(x.TargetPercentage)) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceCustomMetricTarget(([]CustomMetricTarget)(x.Items), e) + } } } - if yyr109 || yy2arr109 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1453,29 +1497,29 @@ func (x *CPUTargetUtilization) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *CPUTargetUtilization) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *CustomMetricTargetList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym113 := z.DecBinary() - _ = yym113 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct114 := r.ContainerType() - if yyct114 == codecSelferValueTypeMap1234 { - yyl114 := r.ReadMapStart() - if yyl114 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl114, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct114 == codecSelferValueTypeArray1234 { - yyl114 := r.ReadArrayStart() - if yyl114 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl114, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1483,16 +1527,16 @@ func (x *CPUTargetUtilization) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *CPUTargetUtilization) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *CustomMetricTargetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys115Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys115Slc - var yyhl115 bool = l >= 0 - for yyj115 := 0; ; yyj115++ { - if yyhl115 { - if yyj115 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1501,96 +1545,108 @@ func (x *CPUTargetUtilization) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys115Slc = r.DecodeBytes(yys115Slc, true, true) - yys115 := string(yys115Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys115 { - case "targetPercentage": + switch yys3 { + case "items": if r.TryDecodeAsNil() { - x.TargetPercentage = 0 + x.Items = nil } else { - x.TargetPercentage = int32(r.DecodeInt(32)) + yyv4 := &x.Items + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceCustomMetricTarget((*[]CustomMetricTarget)(yyv4), d) + } } default: - z.DecStructFieldNotFound(-1, yys115) - } // end switch yys115 - } // end for yyj115 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *CPUTargetUtilization) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *CustomMetricTargetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj117 int - var yyb117 bool - var yyhl117 bool = l >= 0 - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb117 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb117 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.TargetPercentage = 0 + x.Items = nil } else { - x.TargetPercentage = int32(r.DecodeInt(32)) + yyv7 := &x.Items + yym8 := z.DecBinary() + _ = yym8 + if false { + } else { + h.decSliceCustomMetricTarget((*[]CustomMetricTarget)(yyv7), d) + } } for { - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb117 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb117 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj117-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *CustomMetricTarget) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *CustomMetricCurrentStatus) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym119 := z.EncBinary() - _ = yym119 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep120 := !z.EncBinary() - yy2arr120 := z.EncBasicHandle().StructToArray - var yyq120 [2]bool - _, _, _ = yysep120, yyq120, yy2arr120 - const yyr120 bool = false - var yynn120 int - if yyr120 || yy2arr120 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn120 = 2 - for _, b := range yyq120 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn120++ + yynn2++ } } - r.EncodeMapStart(yynn120) - yynn120 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr120 || yy2arr120 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym122 := z.EncBinary() - _ = yym122 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -1599,41 +1655,41 @@ func (x *CustomMetricTarget) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym123 := z.EncBinary() - _ = yym123 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr120 || yy2arr120 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy125 := &x.TargetValue - yym126 := z.EncBinary() - _ = yym126 + yy7 := &x.CurrentValue + yym8 := z.EncBinary() + _ = yym8 if false { - } else if z.HasExtensions() && z.EncExt(yy125) { - } else if !yym126 && z.IsJSONHandle() { - z.EncJSONMarshal(yy125) + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) } else { - z.EncFallback(yy125) + z.EncFallback(yy7) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("value")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy127 := &x.TargetValue - yym128 := z.EncBinary() - _ = yym128 + yy9 := &x.CurrentValue + yym10 := z.EncBinary() + _ = yym10 if false { - } else if z.HasExtensions() && z.EncExt(yy127) { - } else if !yym128 && z.IsJSONHandle() { - z.EncJSONMarshal(yy127) + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) } else { - z.EncFallback(yy127) + z.EncFallback(yy9) } } - if yyr120 || yy2arr120 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1642,29 +1698,29 @@ func (x *CustomMetricTarget) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *CustomMetricTarget) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *CustomMetricCurrentStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym129 := z.DecBinary() - _ = yym129 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct130 := r.ContainerType() - if yyct130 == codecSelferValueTypeMap1234 { - yyl130 := r.ReadMapStart() - if yyl130 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl130, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct130 == codecSelferValueTypeArray1234 { - yyl130 := r.ReadArrayStart() - if yyl130 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl130, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1672,16 +1728,16 @@ func (x *CustomMetricTarget) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *CustomMetricTarget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *CustomMetricCurrentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys131Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys131Slc - var yyhl131 bool = l >= 0 - for yyj131 := 0; ; yyj131++ { - if yyhl131 { - if yyj131 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1690,52 +1746,58 @@ func (x *CustomMetricTarget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys131Slc = r.DecodeBytes(yys131Slc, true, true) - yys131 := string(yys131Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys131 { + switch yys3 { case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "value": if r.TryDecodeAsNil() { - x.TargetValue = pkg4_resource.Quantity{} + x.CurrentValue = pkg3_resource.Quantity{} } else { - yyv133 := &x.TargetValue - yym134 := z.DecBinary() - _ = yym134 + yyv6 := &x.CurrentValue + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv133) { - } else if !yym134 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv133) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv133, false) + z.DecFallback(yyv6, false) } } default: - z.DecStructFieldNotFound(-1, yys131) - } // end switch yys131 - } // end for yyj131 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *CustomMetricTarget) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *CustomMetricCurrentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj135 int - var yyb135 bool - var yyhl135 bool = l >= 0 - yyj135++ - if yyhl135 { - yyb135 = yyj135 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb135 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb135 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1743,89 +1805,95 @@ func (x *CustomMetricTarget) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv9 := &x.Name + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj135++ - if yyhl135 { - yyb135 = yyj135 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb135 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb135 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.TargetValue = pkg4_resource.Quantity{} + x.CurrentValue = pkg3_resource.Quantity{} } else { - yyv137 := &x.TargetValue - yym138 := z.DecBinary() - _ = yym138 + yyv11 := &x.CurrentValue + yym12 := z.DecBinary() + _ = yym12 if false { - } else if z.HasExtensions() && z.DecExt(yyv137) { - } else if !yym138 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv137) + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) } else { - z.DecFallback(yyv137, false) + z.DecFallback(yyv11, false) } } for { - yyj135++ - if yyhl135 { - yyb135 = yyj135 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb135 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb135 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj135-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *CustomMetricTargetList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *CustomMetricCurrentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym139 := z.EncBinary() - _ = yym139 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep140 := !z.EncBinary() - yy2arr140 := z.EncBasicHandle().StructToArray - var yyq140 [1]bool - _, _, _ = yysep140, yyq140, yy2arr140 - const yyr140 bool = false - var yynn140 int - if yyr140 || yy2arr140 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn140 = 1 - for _, b := range yyq140 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn140++ + yynn2++ } } - r.EncodeMapStart(yynn140) - yynn140 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr140 || yy2arr140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym142 := z.EncBinary() - _ = yym142 + yym4 := z.EncBinary() + _ = yym4 if false { } else { - h.encSliceCustomMetricTarget(([]CustomMetricTarget)(x.Items), e) + h.encSliceCustomMetricCurrentStatus(([]CustomMetricCurrentStatus)(x.Items), e) } } } else { @@ -1835,15 +1903,15 @@ func (x *CustomMetricTargetList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym143 := z.EncBinary() - _ = yym143 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - h.encSliceCustomMetricTarget(([]CustomMetricTarget)(x.Items), e) + h.encSliceCustomMetricCurrentStatus(([]CustomMetricCurrentStatus)(x.Items), e) } } } - if yyr140 || yy2arr140 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1852,29 +1920,29 @@ func (x *CustomMetricTargetList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *CustomMetricTargetList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *CustomMetricCurrentStatusList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym144 := z.DecBinary() - _ = yym144 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct145 := r.ContainerType() - if yyct145 == codecSelferValueTypeMap1234 { - yyl145 := r.ReadMapStart() - if yyl145 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl145, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct145 == codecSelferValueTypeArray1234 { - yyl145 := r.ReadArrayStart() - if yyl145 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl145, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1882,16 +1950,16 @@ func (x *CustomMetricTargetList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *CustomMetricTargetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys146Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys146Slc - var yyhl146 bool = l >= 0 - for yyj146 := 0; ; yyj146++ { - if yyhl146 { - if yyj146 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1900,43 +1968,43 @@ func (x *CustomMetricTargetList) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys146Slc = r.DecodeBytes(yys146Slc, true, true) - yys146 := string(yys146Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys146 { + switch yys3 { case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv147 := &x.Items - yym148 := z.DecBinary() - _ = yym148 + yyv4 := &x.Items + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceCustomMetricTarget((*[]CustomMetricTarget)(yyv147), d) + h.decSliceCustomMetricCurrentStatus((*[]CustomMetricCurrentStatus)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys146) - } // end switch yys146 - } // end for yyj146 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *CustomMetricTargetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj149 int - var yyb149 bool - var yyhl149 bool = l >= 0 - yyj149++ - if yyhl149 { - yyb149 = yyj149 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb149 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb149 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1944,138 +2012,234 @@ func (x *CustomMetricTargetList) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Items = nil } else { - yyv150 := &x.Items - yym151 := z.DecBinary() - _ = yym151 + yyv7 := &x.Items + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceCustomMetricTarget((*[]CustomMetricTarget)(yyv150), d) + h.decSliceCustomMetricCurrentStatus((*[]CustomMetricCurrentStatus)(yyv7), d) } } for { - yyj149++ - if yyhl149 { - yyb149 = yyj149 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb149 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb149 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj149-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *CustomMetricCurrentStatus) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ThirdPartyResource) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym152 := z.EncBinary() - _ = yym152 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep153 := !z.EncBinary() - yy2arr153 := z.EncBasicHandle().StructToArray - var yyq153 [2]bool - _, _, _ = yysep153, yyq153, yy2arr153 - const yyr153 bool = false - var yynn153 int - if yyr153 || yy2arr153 { - r.EncodeArrayStart(2) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = x.Description != "" + yyq2[4] = len(x.Versions) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) } else { - yynn153 = 2 - for _, b := range yyq153 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn153++ + yynn2++ } } - r.EncodeMapStart(yynn153) - yynn153 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr153 || yy2arr153 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym155 := z.EncBinary() - _ = yym155 - if false { + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym156 := z.EncBinary() - _ = yym156 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } } } - if yyr153 || yy2arr153 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy158 := &x.CurrentValue - yym159 := z.EncBinary() - _ = yym159 - if false { - } else if z.HasExtensions() && z.EncExt(yy158) { - } else if !yym159 && z.IsJSONHandle() { - z.EncJSONMarshal(yy158) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } } else { - z.EncFallback(yy158) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("value")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy160 := &x.CurrentValue - yym161 := z.EncBinary() - _ = yym161 - if false { - } else if z.HasExtensions() && z.EncExt(yy160) { - } else if !yym161 && z.IsJSONHandle() { - z.EncJSONMarshal(yy160) + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { - z.EncFallback(yy160) + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr153 || yy2arr153 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Description)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("description")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Description)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.Versions == nil { + r.EncodeNil() + } else { + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + h.encSliceAPIVersion(([]APIVersion)(x.Versions), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("versions")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Versions == nil { + r.EncodeNil() + } else { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + h.encSliceAPIVersion(([]APIVersion)(x.Versions), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) } } } } -func (x *CustomMetricCurrentStatus) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ThirdPartyResource) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym162 := z.DecBinary() - _ = yym162 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct163 := r.ContainerType() - if yyct163 == codecSelferValueTypeMap1234 { - yyl163 := r.ReadMapStart() - if yyl163 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl163, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct163 == codecSelferValueTypeArray1234 { - yyl163 := r.ReadArrayStart() - if yyl163 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl163, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2083,16 +2247,16 @@ func (x *CustomMetricCurrentStatus) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *CustomMetricCurrentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys164Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys164Slc - var yyhl164 bool = l >= 0 - for yyj164 := 0; ; yyj164++ { - if yyhl164 { - if yyj164 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2101,142 +2265,334 @@ func (x *CustomMetricCurrentStatus) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys164Slc = r.DecodeBytes(yys164Slc, true, true) - yys164 := string(yys164Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys164 { - case "name": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - x.Name = "" + x.Kind = "" } else { - x.Name = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } - case "value": + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "description": if r.TryDecodeAsNil() { - x.CurrentValue = pkg4_resource.Quantity{} + x.Description = "" + } else { + yyv10 := &x.Description + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + case "versions": + if r.TryDecodeAsNil() { + x.Versions = nil } else { - yyv166 := &x.CurrentValue - yym167 := z.DecBinary() - _ = yym167 + yyv12 := &x.Versions + yym13 := z.DecBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.DecExt(yyv166) { - } else if !yym167 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv166) } else { - z.DecFallback(yyv166, false) + h.decSliceAPIVersion((*[]APIVersion)(yyv12), d) } } default: - z.DecStructFieldNotFound(-1, yys164) - } // end switch yys164 - } // end for yyj164 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *CustomMetricCurrentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj168 int - var yyb168 bool - var yyhl168 bool = l >= 0 - yyj168++ - if yyhl168 { - yyb168 = yyj168 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb168 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb168 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Name = "" + x.Kind = "" + } else { + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv19 := &x.ObjectMeta + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + z.DecFallback(yyv19, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Description = "" } else { - x.Name = string(r.DecodeString()) + yyv21 := &x.Description + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj168++ - if yyhl168 { - yyb168 = yyj168 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb168 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb168 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.CurrentValue = pkg4_resource.Quantity{} + x.Versions = nil } else { - yyv170 := &x.CurrentValue - yym171 := z.DecBinary() - _ = yym171 + yyv23 := &x.Versions + yym24 := z.DecBinary() + _ = yym24 if false { - } else if z.HasExtensions() && z.DecExt(yyv170) { - } else if !yym171 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv170) } else { - z.DecFallback(yyv170, false) + h.decSliceAPIVersion((*[]APIVersion)(yyv23), d) } } for { - yyj168++ - if yyhl168 { - yyb168 = yyj168 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb168 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb168 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj168-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *CustomMetricCurrentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ThirdPartyResourceList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym172 := z.EncBinary() - _ = yym172 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep173 := !z.EncBinary() - yy2arr173 := z.EncBasicHandle().StructToArray - var yyq173 [1]bool - _, _, _ = yysep173, yyq173, yy2arr173 - const yyr173 bool = false - var yynn173 int - if yyr173 || yy2arr173 { - r.EncodeArrayStart(1) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn173 = 1 - for _, b := range yyq173 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn173++ + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) } } - r.EncodeMapStart(yynn173) - yynn173 = 0 } - if yyr173 || yy2arr173 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym175 := z.EncBinary() - _ = yym175 + yym15 := z.EncBinary() + _ = yym15 if false { } else { - h.encSliceCustomMetricCurrentStatus(([]CustomMetricCurrentStatus)(x.Items), e) + h.encSliceThirdPartyResource(([]ThirdPartyResource)(x.Items), e) } } } else { @@ -2246,15 +2602,15 @@ func (x *CustomMetricCurrentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym176 := z.EncBinary() - _ = yym176 + yym16 := z.EncBinary() + _ = yym16 if false { } else { - h.encSliceCustomMetricCurrentStatus(([]CustomMetricCurrentStatus)(x.Items), e) + h.encSliceThirdPartyResource(([]ThirdPartyResource)(x.Items), e) } } } - if yyr173 || yy2arr173 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2263,29 +2619,29 @@ func (x *CustomMetricCurrentStatusList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *CustomMetricCurrentStatusList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ThirdPartyResourceList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym177 := z.DecBinary() - _ = yym177 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct178 := r.ContainerType() - if yyct178 == codecSelferValueTypeMap1234 { - yyl178 := r.ReadMapStart() - if yyl178 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl178, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct178 == codecSelferValueTypeArray1234 { - yyl178 := r.ReadArrayStart() - if yyl178 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl178, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2293,16 +2649,16 @@ func (x *CustomMetricCurrentStatusList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResourceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys179Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys179Slc - var yyhl179 bool = l >= 0 - for yyj179 := 0; ; yyj179++ { - if yyhl179 { - if yyj179 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2311,195 +2667,235 @@ func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromMap(l int, d *codec19 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys179Slc = r.DecodeBytes(yys179Slc, true, true) - yys179 := string(yys179Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys179 { + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv180 := &x.Items - yym181 := z.DecBinary() - _ = yym181 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceCustomMetricCurrentStatus((*[]CustomMetricCurrentStatus)(yyv180), d) + h.decSliceThirdPartyResource((*[]ThirdPartyResource)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys179) - } // end switch yys179 - } // end for yyj179 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *CustomMetricCurrentStatusList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResourceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj182 int - var yyb182 bool - var yyhl182 bool = l >= 0 - yyj182++ - if yyhl182 { - yyb182 = yyj182 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb182 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb182 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Items = nil + x.Kind = "" } else { - yyv183 := &x.Items - yym184 := z.DecBinary() - _ = yym184 + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 if false { } else { - h.decSliceCustomMetricCurrentStatus((*[]CustomMetricCurrentStatus)(yyv183), d) + *((*string)(yyv13)) = r.DecodeString() } } - for { - yyj182++ - if yyhl182 { - yyb182 = yyj182 > l - } else { - yyb182 = r.CheckBreak() - } - if yyb182 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj182-1, "") + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *HorizontalPodAutoscalerSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" } else { - yym185 := z.EncBinary() - _ = yym185 + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep186 := !z.EncBinary() - yy2arr186 := z.EncBasicHandle().StructToArray - var yyq186 [4]bool - _, _, _ = yysep186, yyq186, yy2arr186 - const yyr186 bool = false - yyq186[1] = x.MinReplicas != nil - yyq186[3] = x.CPUUtilization != nil - var yynn186 int - if yyr186 || yy2arr186 { - r.EncodeArrayStart(4) + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceThirdPartyResource((*[]ThirdPartyResource)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *APIVersion) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Name != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) } else { - yynn186 = 2 - for _, b := range yyq186 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn186++ - } - } - r.EncodeMapStart(yynn186) - yynn186 = 0 - } - if yyr186 || yy2arr186 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy188 := &x.ScaleRef - yy188.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("scaleRef")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy189 := &x.ScaleRef - yy189.CodecEncodeSelf(e) - } - if yyr186 || yy2arr186 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq186[1] { - if x.MinReplicas == nil { - r.EncodeNil() - } else { - yy191 := *x.MinReplicas - yym192 := z.EncBinary() - _ = yym192 - if false { - } else { - r.EncodeInt(int64(yy191)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq186[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.MinReplicas == nil { - r.EncodeNil() - } else { - yy193 := *x.MinReplicas - yym194 := z.EncBinary() - _ = yym194 - if false { - } else { - r.EncodeInt(int64(yy193)) - } + yynn2++ } } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr186 || yy2arr186 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym196 := z.EncBinary() - _ = yym196 - if false { - } else { - r.EncodeInt(int64(x.MaxReplicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym197 := z.EncBinary() - _ = yym197 - if false { - } else { - r.EncodeInt(int64(x.MaxReplicas)) - } - } - if yyr186 || yy2arr186 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq186[3] { - if x.CPUUtilization == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - x.CPUUtilization.CodecEncodeSelf(e) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq186[3] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("cpuUtilization")) + r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CPUUtilization == nil { - r.EncodeNil() + yym5 := z.EncBinary() + _ = yym5 + if false { } else { - x.CPUUtilization.CodecEncodeSelf(e) + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } } - if yyr186 || yy2arr186 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2508,29 +2904,29 @@ func (x *HorizontalPodAutoscalerSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *HorizontalPodAutoscalerSpec) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *APIVersion) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym199 := z.DecBinary() - _ = yym199 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct200 := r.ContainerType() - if yyct200 == codecSelferValueTypeMap1234 { - yyl200 := r.ReadMapStart() - if yyl200 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl200, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct200 == codecSelferValueTypeArray1234 { - yyl200 := r.ReadArrayStart() - if yyl200 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl200, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2538,16 +2934,16 @@ func (x *HorizontalPodAutoscalerSpec) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *APIVersion) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys201Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys201Slc - var yyhl201 bool = l >= 0 - for yyj201 := 0; ; yyj201++ { - if yyhl201 { - if yyj201 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2556,345 +2952,221 @@ func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys201Slc = r.DecodeBytes(yys201Slc, true, true) - yys201 := string(yys201Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys201 { - case "scaleRef": - if r.TryDecodeAsNil() { - x.ScaleRef = SubresourceReference{} - } else { - yyv202 := &x.ScaleRef - yyv202.CodecDecodeSelf(d) - } - case "minReplicas": + switch yys3 { + case "name": if r.TryDecodeAsNil() { - if x.MinReplicas != nil { - x.MinReplicas = nil - } + x.Name = "" } else { - if x.MinReplicas == nil { - x.MinReplicas = new(int32) - } - yym204 := z.DecBinary() - _ = yym204 + yyv4 := &x.Name + yym5 := z.DecBinary() + _ = yym5 if false { } else { - *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) - } - } - case "maxReplicas": - if r.TryDecodeAsNil() { - x.MaxReplicas = 0 - } else { - x.MaxReplicas = int32(r.DecodeInt(32)) - } - case "cpuUtilization": - if r.TryDecodeAsNil() { - if x.CPUUtilization != nil { - x.CPUUtilization = nil - } - } else { - if x.CPUUtilization == nil { - x.CPUUtilization = new(CPUTargetUtilization) + *((*string)(yyv4)) = r.DecodeString() } - x.CPUUtilization.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys201) - } // end switch yys201 - } // end for yyj201 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *HorizontalPodAutoscalerSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *APIVersion) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj207 int - var yyb207 bool - var yyhl207 bool = l >= 0 - yyj207++ - if yyhl207 { - yyb207 = yyj207 > l - } else { - yyb207 = r.CheckBreak() - } - if yyb207 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ScaleRef = SubresourceReference{} - } else { - yyv208 := &x.ScaleRef - yyv208.CodecDecodeSelf(d) - } - yyj207++ - if yyhl207 { - yyb207 = yyj207 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb207 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb207 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.MinReplicas != nil { - x.MinReplicas = nil - } + x.Name = "" } else { - if x.MinReplicas == nil { - x.MinReplicas = new(int32) - } - yym210 := z.DecBinary() - _ = yym210 + yyv7 := &x.Name + yym8 := z.DecBinary() + _ = yym8 if false { } else { - *((*int32)(x.MinReplicas)) = int32(r.DecodeInt(32)) - } - } - yyj207++ - if yyhl207 { - yyb207 = yyj207 > l - } else { - yyb207 = r.CheckBreak() - } - if yyb207 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MaxReplicas = 0 - } else { - x.MaxReplicas = int32(r.DecodeInt(32)) - } - yyj207++ - if yyhl207 { - yyb207 = yyj207 > l - } else { - yyb207 = r.CheckBreak() - } - if yyb207 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.CPUUtilization != nil { - x.CPUUtilization = nil + *((*string)(yyv7)) = r.DecodeString() } - } else { - if x.CPUUtilization == nil { - x.CPUUtilization = new(CPUTargetUtilization) - } - x.CPUUtilization.CodecDecodeSelf(d) } for { - yyj207++ - if yyhl207 { - yyb207 = yyj207 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb207 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb207 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj207-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ThirdPartyResourceData) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym213 := z.EncBinary() - _ = yym213 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep214 := !z.EncBinary() - yy2arr214 := z.EncBasicHandle().StructToArray - var yyq214 [5]bool - _, _, _ = yysep214, yyq214, yy2arr214 - const yyr214 bool = false - yyq214[0] = x.ObservedGeneration != nil - yyq214[1] = x.LastScaleTime != nil - yyq214[4] = x.CurrentCPUUtilizationPercentage != nil - var yynn214 int - if yyr214 || yy2arr214 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = len(x.Data) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn214 = 2 - for _, b := range yyq214 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn214++ + yynn2++ } } - r.EncodeMapStart(yynn214) - yynn214 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr214 || yy2arr214 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq214[0] { - if x.ObservedGeneration == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - yy216 := *x.ObservedGeneration - yym217 := z.EncBinary() - _ = yym217 - if false { - } else { - r.EncodeInt(int64(yy216)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq214[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) + r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ObservedGeneration == nil { - r.EncodeNil() + yym5 := z.EncBinary() + _ = yym5 + if false { } else { - yy218 := *x.ObservedGeneration - yym219 := z.EncBinary() - _ = yym219 - if false { - } else { - r.EncodeInt(int64(yy218)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr214 || yy2arr214 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq214[1] { - if x.LastScaleTime == nil { - r.EncodeNil() + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { } else { - yym221 := z.EncBinary() - _ = yym221 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { - } else if yym221 { - z.EncBinaryMarshal(x.LastScaleTime) - } else if !yym221 && z.IsJSONHandle() { - z.EncJSONMarshal(x.LastScaleTime) - } else { - z.EncFallback(x.LastScaleTime) - } + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq214[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastScaleTime")) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.LastScaleTime == nil { - r.EncodeNil() + yym8 := z.EncBinary() + _ = yym8 + if false { } else { - yym222 := z.EncBinary() - _ = yym222 - if false { - } else if z.HasExtensions() && z.EncExt(x.LastScaleTime) { - } else if yym222 { - z.EncBinaryMarshal(x.LastScaleTime) - } else if !yym222 && z.IsJSONHandle() { - z.EncJSONMarshal(x.LastScaleTime) - } else { - z.EncFallback(x.LastScaleTime) - } + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr214 || yy2arr214 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym224 := z.EncBinary() - _ = yym224 - if false { - } else { - r.EncodeInt(int64(x.CurrentReplicas)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym225 := z.EncBinary() - _ = yym225 - if false { - } else { - r.EncodeInt(int64(x.CurrentReplicas)) - } - } - if yyr214 || yy2arr214 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym227 := z.EncBinary() - _ = yym227 - if false { + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { - r.EncodeInt(int64(x.DesiredReplicas)) + r.EncodeNil() } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("desiredReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym228 := z.EncBinary() - _ = yym228 - if false { - } else { - r.EncodeInt(int64(x.DesiredReplicas)) + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr214 || yy2arr214 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq214[4] { - if x.CurrentCPUUtilizationPercentage == nil { + if yyq2[3] { + if x.Data == nil { r.EncodeNil() } else { - yy230 := *x.CurrentCPUUtilizationPercentage - yym231 := z.EncBinary() - _ = yym231 + yym15 := z.EncBinary() + _ = yym15 if false { } else { - r.EncodeInt(int64(yy230)) + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) } } } else { r.EncodeNil() } } else { - if yyq214[4] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentCPUUtilizationPercentage")) + r.EncodeString(codecSelferC_UTF81234, string("data")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CurrentCPUUtilizationPercentage == nil { + if x.Data == nil { r.EncodeNil() } else { - yy232 := *x.CurrentCPUUtilizationPercentage - yym233 := z.EncBinary() - _ = yym233 + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeInt(int64(yy232)) + r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) } } } } - if yyr214 || yy2arr214 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2903,29 +3175,29 @@ func (x *HorizontalPodAutoscalerStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *HorizontalPodAutoscalerStatus) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ThirdPartyResourceData) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym234 := z.DecBinary() - _ = yym234 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct235 := r.ContainerType() - if yyct235 == codecSelferValueTypeMap1234 { - yyl235 := r.ReadMapStart() - if yyl235 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl235, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct235 == codecSelferValueTypeArray1234 { - yyl235 := r.ReadArrayStart() - if yyl235 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl235, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2933,16 +3205,16 @@ func (x *HorizontalPodAutoscalerStatus) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResourceData) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys236Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys236Slc - var yyhl236 bool = l >= 0 - for yyj236 := 0; ; yyj236++ { - if yyhl236 { - if yyj236 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2951,260 +3223,218 @@ func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromMap(l int, d *codec19 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys236Slc = r.DecodeBytes(yys236Slc, true, true) - yys236 := string(yys236Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys236 { - case "observedGeneration": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil - } + x.Kind = "" } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) - } - yym238 := z.DecBinary() - _ = yym238 + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 if false { } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + *((*string)(yyv4)) = r.DecodeString() } } - case "lastScaleTime": + case "apiVersion": if r.TryDecodeAsNil() { - if x.LastScaleTime != nil { - x.LastScaleTime = nil - } + x.APIVersion = "" } else { - if x.LastScaleTime == nil { - x.LastScaleTime = new(pkg1_unversioned.Time) - } - yym240 := z.DecBinary() - _ = yym240 + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { - } else if yym240 { - z.DecBinaryUnmarshal(x.LastScaleTime) - } else if !yym240 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.LastScaleTime) } else { - z.DecFallback(x.LastScaleTime, false) + *((*string)(yyv6)) = r.DecodeString() } } - case "currentReplicas": - if r.TryDecodeAsNil() { - x.CurrentReplicas = 0 - } else { - x.CurrentReplicas = int32(r.DecodeInt(32)) - } - case "desiredReplicas": + case "metadata": if r.TryDecodeAsNil() { - x.DesiredReplicas = 0 + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - x.DesiredReplicas = int32(r.DecodeInt(32)) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } - case "currentCPUUtilizationPercentage": + case "data": if r.TryDecodeAsNil() { - if x.CurrentCPUUtilizationPercentage != nil { - x.CurrentCPUUtilizationPercentage = nil - } + x.Data = nil } else { - if x.CurrentCPUUtilizationPercentage == nil { - x.CurrentCPUUtilizationPercentage = new(int32) - } - yym244 := z.DecBinary() - _ = yym244 + yyv10 := &x.Data + yym11 := z.DecBinary() + _ = yym11 if false { } else { - *((*int32)(x.CurrentCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) + *yyv10 = r.DecodeBytes(*(*[]byte)(yyv10), false, false) } } default: - z.DecStructFieldNotFound(-1, yys236) - } // end switch yys236 - } // end for yyj236 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *HorizontalPodAutoscalerStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResourceData) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj245 int - var yyb245 bool - var yyhl245 bool = l >= 0 - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ObservedGeneration != nil { - x.ObservedGeneration = nil - } + x.Kind = "" } else { - if x.ObservedGeneration == nil { - x.ObservedGeneration = new(int64) - } - yym247 := z.DecBinary() - _ = yym247 + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 if false { } else { - *((*int64)(x.ObservedGeneration)) = int64(r.DecodeInt(64)) + *((*string)(yyv13)) = r.DecodeString() } } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.LastScaleTime != nil { - x.LastScaleTime = nil - } + x.APIVersion = "" } else { - if x.LastScaleTime == nil { - x.LastScaleTime = new(pkg1_unversioned.Time) - } - yym249 := z.DecBinary() - _ = yym249 + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(x.LastScaleTime) { - } else if yym249 { - z.DecBinaryUnmarshal(x.LastScaleTime) - } else if !yym249 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.LastScaleTime) } else { - z.DecFallback(x.LastScaleTime, false) + *((*string)(yyv15)) = r.DecodeString() } } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l - } else { - yyb245 = r.CheckBreak() - } - if yyb245 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CurrentReplicas = 0 - } else { - x.CurrentReplicas = int32(r.DecodeInt(32)) - } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DesiredReplicas = 0 + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - x.DesiredReplicas = int32(r.DecodeInt(32)) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.CurrentCPUUtilizationPercentage != nil { - x.CurrentCPUUtilizationPercentage = nil - } + x.Data = nil } else { - if x.CurrentCPUUtilizationPercentage == nil { - x.CurrentCPUUtilizationPercentage = new(int32) - } - yym253 := z.DecBinary() - _ = yym253 + yyv19 := &x.Data + yym20 := z.DecBinary() + _ = yym20 if false { } else { - *((*int32)(x.CurrentCPUUtilizationPercentage)) = int32(r.DecodeInt(32)) + *yyv19 = r.DecodeBytes(*(*[]byte)(yyv19), false, false) } } for { - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj245-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym254 := z.EncBinary() - _ = yym254 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep255 := !z.EncBinary() - yy2arr255 := z.EncBasicHandle().StructToArray - var yyq255 [5]bool - _, _, _ = yysep255, yyq255, yy2arr255 - const yyr255 bool = false - yyq255[0] = x.Kind != "" - yyq255[1] = x.APIVersion != "" - yyq255[2] = true - yyq255[3] = true - yyq255[4] = true - var yynn255 int - if yyr255 || yy2arr255 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn255 = 0 - for _, b := range yyq255 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn255++ + yynn2++ } } - r.EncodeMapStart(yynn255) - yynn255 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr255 || yy2arr255 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq255[0] { - yym257 := z.EncBinary() - _ = yym257 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -3213,23 +3443,23 @@ func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq255[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym258 := z.EncBinary() - _ = yym258 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr255 || yy2arr255 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq255[1] { - yym260 := z.EncBinary() - _ = yym260 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -3238,70 +3468,82 @@ func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq255[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym261 := z.EncBinary() - _ = yym261 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr255 || yy2arr255 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq255[2] { - yy263 := &x.ObjectMeta - yy263.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq255[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy264 := &x.ObjectMeta - yy264.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr255 || yy2arr255 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq255[3] { - yy266 := &x.Spec - yy266.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq255[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy267 := &x.Spec - yy267.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr255 || yy2arr255 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq255[4] { - yy269 := &x.Status - yy269.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq255[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy270 := &x.Status - yy270.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr255 || yy2arr255 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -3310,29 +3552,29 @@ func (x *HorizontalPodAutoscaler) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *HorizontalPodAutoscaler) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym271 := z.DecBinary() - _ = yym271 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct272 := r.ContainerType() - if yyct272 == codecSelferValueTypeMap1234 { - yyl272 := r.ReadMapStart() - if yyl272 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl272, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct272 == codecSelferValueTypeArray1234 { - yyl272 := r.ReadArrayStart() - if yyl272 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl272, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3340,16 +3582,16 @@ func (x *HorizontalPodAutoscaler) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *HorizontalPodAutoscaler) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys273Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys273Slc - var yyhl273 bool = l >= 0 - for yyj273 := 0; ; yyj273++ { - if yyhl273 { - if yyj273 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3358,64 +3600,82 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys273Slc = r.DecodeBytes(yys273Slc, true, true) - yys273 := string(yys273Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys273 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv276 := &x.ObjectMeta - yyv276.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { - x.Spec = HorizontalPodAutoscalerSpec{} + x.Spec = DeploymentSpec{} } else { - yyv277 := &x.Spec - yyv277.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { - x.Status = HorizontalPodAutoscalerStatus{} + x.Status = DeploymentStatus{} } else { - yyv278 := &x.Status - yyv278.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys273) - } // end switch yys273 - } // end for yyj273 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *Deployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj279 int - var yyb279 bool - var yyhl279 bool = l >= 0 - yyj279++ - if yyhl279 { - yyb279 = yyj279 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb279 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb279 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3423,15 +3683,21 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj279++ - if yyhl279 { - yyb279 = yyj279 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb279 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb279 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3439,246 +3705,398 @@ func (x *HorizontalPodAutoscaler) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj279++ - if yyhl279 { - yyb279 = yyj279 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb279 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb279 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv282 := &x.ObjectMeta - yyv282.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj279++ - if yyhl279 { - yyb279 = yyj279 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb279 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb279 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Spec = HorizontalPodAutoscalerSpec{} + x.Spec = DeploymentSpec{} } else { - yyv283 := &x.Spec - yyv283.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj279++ - if yyhl279 { - yyb279 = yyj279 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb279 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb279 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Status = HorizontalPodAutoscalerStatus{} + x.Status = DeploymentStatus{} } else { - yyv284 := &x.Status - yyv284.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj279++ - if yyhl279 { - yyb279 = yyj279 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb279 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb279 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj279-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *HorizontalPodAutoscalerList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym285 := z.EncBinary() - _ = yym285 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep286 := !z.EncBinary() - yy2arr286 := z.EncBasicHandle().StructToArray - var yyq286 [4]bool - _, _, _ = yysep286, yyq286, yy2arr286 - const yyr286 bool = false - yyq286[0] = x.Kind != "" - yyq286[1] = x.APIVersion != "" - yyq286[2] = true - var yynn286 int - if yyr286 || yy2arr286 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != nil + yyq2[1] = x.Selector != nil + yyq2[3] = true + yyq2[4] = x.MinReadySeconds != 0 + yyq2[5] = x.RevisionHistoryLimit != nil + yyq2[6] = x.Paused != false + yyq2[7] = x.RollbackTo != nil + yyq2[8] = x.ProgressDeadlineSeconds != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) } else { - yynn286 = 1 - for _, b := range yyq286 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn286++ + yynn2++ } } - r.EncodeMapStart(yynn286) - yynn286 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr286 || yy2arr286 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq286[0] { - yym288 := z.EncBinary() - _ = yym288 - if false { + if yyq2[0] { + if x.Replicas == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + yy4 := *x.Replicas + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(yy4)) + } } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq286[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym289 := z.EncBinary() - _ = yym289 - if false { + if x.Replicas == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + yy6 := *x.Replicas + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(yy6)) + } } } } - if yyr286 || yy2arr286 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq286[1] { - yym291 := z.EncBinary() - _ = yym291 - if false { + if yyq2[1] { + if x.Selector == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq286[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym292 := z.EncBinary() - _ = yym292 - if false { + if x.Selector == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } } } } - if yyr286 || yy2arr286 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy12 := &x.Template + yy12.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("template")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy14 := &x.Template + yy14.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy17 := &x.Strategy + yy17.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("strategy")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy19 := &x.Strategy + yy19.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq286[2] { - yy294 := &x.ListMeta - yym295 := z.EncBinary() - _ = yym295 + if yyq2[4] { + yym22 := z.EncBinary() + _ = yym22 if false { - } else if z.HasExtensions() && z.EncExt(yy294) { } else { - z.EncFallback(yy294) + r.EncodeInt(int64(x.MinReadySeconds)) } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq286[2] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) + r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy296 := &x.ListMeta - yym297 := z.EncBinary() - _ = yym297 + yym23 := z.EncBinary() + _ = yym23 if false { - } else if z.HasExtensions() && z.EncExt(yy296) { } else { - z.EncFallback(yy296) + r.EncodeInt(int64(x.MinReadySeconds)) } } } - if yyr286 || yy2arr286 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() + if yyq2[5] { + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy25 := *x.RevisionHistoryLimit + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(yy25)) + } + } } else { - yym299 := z.EncBinary() - _ = yym299 + r.EncodeNil() + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy27 := *x.RevisionHistoryLimit + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeInt(int64(yy27)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[6] { + yym30 := z.EncBinary() + _ = yym30 if false { } else { - h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(x.Items), e) + r.EncodeBool(bool(x.Paused)) } + } else { + r.EncodeBool(false) } } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym300 := z.EncBinary() - _ = yym300 + if yyq2[6] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("paused")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym31 := z.EncBinary() + _ = yym31 if false { } else { - h.encSliceHorizontalPodAutoscaler(([]HorizontalPodAutoscaler)(x.Items), e) + r.EncodeBool(bool(x.Paused)) } } } - if yyr286 || yy2arr286 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[7] { + if x.RollbackTo == nil { + r.EncodeNil() + } else { + x.RollbackTo.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) + if yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.RollbackTo == nil { + r.EncodeNil() + } else { + x.RollbackTo.CodecEncodeSelf(e) + } + } } - } - } -} - -func (x *HorizontalPodAutoscalerList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym301 := z.DecBinary() - _ = yym301 - if false { - } else if z.HasExtensions() && z.DecExt(x) { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[8] { + if x.ProgressDeadlineSeconds == nil { + r.EncodeNil() + } else { + yy36 := *x.ProgressDeadlineSeconds + yym37 := z.EncBinary() + _ = yym37 + if false { + } else { + r.EncodeInt(int64(yy36)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[8] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("progressDeadlineSeconds")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ProgressDeadlineSeconds == nil { + r.EncodeNil() + } else { + yy38 := *x.ProgressDeadlineSeconds + yym39 := z.EncBinary() + _ = yym39 + if false { + } else { + r.EncodeInt(int64(yy38)) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DeploymentSpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct302 := r.ContainerType() - if yyct302 == codecSelferValueTypeMap1234 { - yyl302 := r.ReadMapStart() - if yyl302 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl302, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct302 == codecSelferValueTypeArray1234 { - yyl302 := r.ReadArrayStart() - if yyl302 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl302, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3686,16 +4104,16 @@ func (x *HorizontalPodAutoscalerList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys303Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys303Slc - var yyhl303 bool = l >= 0 - for yyj303 := 0; ; yyj303++ { - if yyhl303 { - if yyj303 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3704,194 +4122,396 @@ func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromMap(l int, d *codec1978 } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys303Slc = r.DecodeBytes(yys303Slc, true, true) - yys303 := string(yys303Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys303 { - case "kind": + switch yys3 { + case "replicas": if r.TryDecodeAsNil() { - x.Kind = "" + if x.Replicas != nil { + x.Replicas = nil + } } else { - x.Kind = string(r.DecodeString()) + if x.Replicas == nil { + x.Replicas = new(int32) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + } } - case "apiVersion": + case "selector": if r.TryDecodeAsNil() { - x.APIVersion = "" + if x.Selector != nil { + x.Selector = nil + } + } else { + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + case "template": + if r.TryDecodeAsNil() { + x.Template = pkg4_v1.PodTemplateSpec{} } else { - x.APIVersion = string(r.DecodeString()) + yyv8 := &x.Template + yyv8.CodecDecodeSelf(d) } - case "metadata": + case "strategy": + if r.TryDecodeAsNil() { + x.Strategy = DeploymentStrategy{} + } else { + yyv9 := &x.Strategy + yyv9.CodecDecodeSelf(d) + } + case "minReadySeconds": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.MinReadySeconds = 0 } else { - yyv306 := &x.ListMeta - yym307 := z.DecBinary() - _ = yym307 + yyv10 := &x.MinReadySeconds + yym11 := z.DecBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.DecExt(yyv306) { } else { - z.DecFallback(yyv306, false) + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) } } - case "items": + case "revisionHistoryLimit": if r.TryDecodeAsNil() { - x.Items = nil + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } + } else { + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + case "paused": + if r.TryDecodeAsNil() { + x.Paused = false + } else { + yyv14 := &x.Paused + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } + } + case "rollbackTo": + if r.TryDecodeAsNil() { + if x.RollbackTo != nil { + x.RollbackTo = nil + } + } else { + if x.RollbackTo == nil { + x.RollbackTo = new(RollbackConfig) + } + x.RollbackTo.CodecDecodeSelf(d) + } + case "progressDeadlineSeconds": + if r.TryDecodeAsNil() { + if x.ProgressDeadlineSeconds != nil { + x.ProgressDeadlineSeconds = nil + } } else { - yyv308 := &x.Items - yym309 := z.DecBinary() - _ = yym309 + if x.ProgressDeadlineSeconds == nil { + x.ProgressDeadlineSeconds = new(int32) + } + yym18 := z.DecBinary() + _ = yym18 if false { } else { - h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv308), d) + *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) } } default: - z.DecStructFieldNotFound(-1, yys303) - } // end switch yys303 - } // end for yyj303 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *HorizontalPodAutoscalerList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj310 int - var yyb310 bool - var yyhl310 bool = l >= 0 - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + var yyj19 int + var yyb19 bool + var yyhl19 bool = l >= 0 + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb310 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb310 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" + if x.Replicas != nil { + x.Replicas = nil + } } else { - x.Kind = string(r.DecodeString()) + if x.Replicas == nil { + x.Replicas = new(int32) + } + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) + } } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb310 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb310 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + if x.Selector != nil { + x.Selector = nil + } + } else { + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym23 := z.DecBinary() + _ = yym23 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Template = pkg4_v1.PodTemplateSpec{} + } else { + yyv24 := &x.Template + yyv24.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Strategy = DeploymentStrategy{} } else { - x.APIVersion = string(r.DecodeString()) + yyv25 := &x.Strategy + yyv25.CodecDecodeSelf(d) } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb310 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb310 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.MinReadySeconds = 0 } else { - yyv313 := &x.ListMeta - yym314 := z.DecBinary() - _ = yym314 + yyv26 := &x.MinReadySeconds + yym27 := z.DecBinary() + _ = yym27 if false { - } else if z.HasExtensions() && z.DecExt(yyv313) { } else { - z.DecFallback(yyv313, false) + *((*int32)(yyv26)) = int32(r.DecodeInt(32)) } } - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb310 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb310 { + if yyb19 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Items = nil + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } + } else { + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym29 := z.DecBinary() + _ = yym29 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Paused = false + } else { + yyv30 := &x.Paused + yym31 := z.DecBinary() + _ = yym31 + if false { + } else { + *((*bool)(yyv30)) = r.DecodeBool() + } + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyv315 := &x.Items - yym316 := z.DecBinary() - _ = yym316 + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RollbackTo != nil { + x.RollbackTo = nil + } + } else { + if x.RollbackTo == nil { + x.RollbackTo = new(RollbackConfig) + } + x.RollbackTo.CodecDecodeSelf(d) + } + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l + } else { + yyb19 = r.CheckBreak() + } + if yyb19 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.ProgressDeadlineSeconds != nil { + x.ProgressDeadlineSeconds = nil + } + } else { + if x.ProgressDeadlineSeconds == nil { + x.ProgressDeadlineSeconds = new(int32) + } + yym34 := z.DecBinary() + _ = yym34 if false { } else { - h.decSliceHorizontalPodAutoscaler((*[]HorizontalPodAutoscaler)(yyv315), d) + *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) } } for { - yyj310++ - if yyhl310 { - yyb310 = yyj310 > l + yyj19++ + if yyhl19 { + yyb19 = yyj19 > l } else { - yyb310 = r.CheckBreak() + yyb19 = r.CheckBreak() } - if yyb310 { + if yyb19 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj310-1, "") + z.DecStructFieldNotFound(yyj19-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ThirdPartyResource) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym317 := z.EncBinary() - _ = yym317 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep318 := !z.EncBinary() - yy2arr318 := z.EncBasicHandle().StructToArray - var yyq318 [5]bool - _, _, _ = yysep318, yyq318, yy2arr318 - const yyr318 bool = false - yyq318[0] = x.Kind != "" - yyq318[1] = x.APIVersion != "" - yyq318[2] = true - yyq318[3] = x.Description != "" - yyq318[4] = len(x.Versions) != 0 - var yynn318 int - if yyr318 || yy2arr318 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[3] = len(x.UpdatedAnnotations) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn318 = 0 - for _, b := range yyq318 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn318++ + yynn2++ } } - r.EncodeMapStart(yynn318) - yynn318 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr318 || yy2arr318 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq318[0] { - yym320 := z.EncBinary() - _ = yym320 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -3900,23 +4520,23 @@ func (x *ThirdPartyResource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq318[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym321 := z.EncBinary() - _ = yym321 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr318 || yy2arr318 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq318[1] { - yym323 := z.EncBinary() - _ = yym323 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -3925,94 +4545,82 @@ func (x *ThirdPartyResource) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq318[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym324 := z.EncBinary() - _ = yym324 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr318 || yy2arr318 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq318[2] { - yy326 := &x.ObjectMeta - yy326.CodecEncodeSelf(e) + yym10 := z.EncBinary() + _ = yym10 + if false { } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } else { - if yyq318[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy327 := &x.ObjectMeta - yy327.CodecEncodeSelf(e) - } - } - if yyr318 || yy2arr318 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq318[3] { - yym329 := z.EncBinary() - _ = yym329 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Description)) - } + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq318[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("description")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym330 := z.EncBinary() - _ = yym330 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Description)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr318 || yy2arr318 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq318[4] { - if x.Versions == nil { + if yyq2[3] { + if x.UpdatedAnnotations == nil { r.EncodeNil() } else { - yym332 := z.EncBinary() - _ = yym332 + yym13 := z.EncBinary() + _ = yym13 if false { } else { - h.encSliceAPIVersion(([]APIVersion)(x.Versions), e) + z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) } } } else { r.EncodeNil() } } else { - if yyq318[4] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("versions")) + r.EncodeString(codecSelferC_UTF81234, string("updatedAnnotations")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Versions == nil { + if x.UpdatedAnnotations == nil { r.EncodeNil() } else { - yym333 := z.EncBinary() - _ = yym333 + yym14 := z.EncBinary() + _ = yym14 if false { } else { - h.encSliceAPIVersion(([]APIVersion)(x.Versions), e) + z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) } } } } - if yyr318 || yy2arr318 { + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy16 := &x.RollbackTo + yy16.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy18 := &x.RollbackTo + yy18.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -4021,29 +4629,29 @@ func (x *ThirdPartyResource) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ThirdPartyResource) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentRollback) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym334 := z.DecBinary() - _ = yym334 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct335 := r.ContainerType() - if yyct335 == codecSelferValueTypeMap1234 { - yyl335 := r.ReadMapStart() - if yyl335 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl335, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct335 == codecSelferValueTypeArray1234 { - yyl335 := r.ReadArrayStart() - if yyl335 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl335, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -4051,16 +4659,16 @@ func (x *ThirdPartyResource) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ThirdPartyResource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys336Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys336Slc - var yyhl336 bool = l >= 0 - for yyj336 := 0; ; yyj336++ { - if yyhl336 { - if yyj336 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -4069,68 +4677,86 @@ func (x *ThirdPartyResource) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys336Slc = r.DecodeBytes(yys336Slc, true, true) - yys336 := string(yys336Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys336 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) - } - case "metadata": - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv339 := &x.ObjectMeta - yyv339.CodecDecodeSelf(d) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - case "description": + case "name": if r.TryDecodeAsNil() { - x.Description = "" + x.Name = "" } else { - x.Description = string(r.DecodeString()) + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } - case "versions": + case "updatedAnnotations": if r.TryDecodeAsNil() { - x.Versions = nil + x.UpdatedAnnotations = nil } else { - yyv341 := &x.Versions - yym342 := z.DecBinary() - _ = yym342 + yyv10 := &x.UpdatedAnnotations + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceAPIVersion((*[]APIVersion)(yyv341), d) + z.F.DecMapStringStringX(yyv10, false, d) } } + case "rollbackTo": + if r.TryDecodeAsNil() { + x.RollbackTo = RollbackConfig{} + } else { + yyv12 := &x.RollbackTo + yyv12.CodecDecodeSelf(d) + } default: - z.DecStructFieldNotFound(-1, yys336) - } // end switch yys336 - } // end for yyj336 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ThirdPartyResource) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj343 int - var yyb343 bool - var yyhl343 bool = l >= 0 - yyj343++ - if yyhl343 { - yyb343 = yyj343 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb343 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb343 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4138,15 +4764,21 @@ func (x *ThirdPartyResource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv14 := &x.Kind + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj343++ - if yyhl343 { - yyb343 = yyj343 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb343 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb343 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -4154,219 +4786,148 @@ func (x *ThirdPartyResource) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv16 := &x.APIVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } - yyj343++ - if yyhl343 { - yyb343 = yyj343 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb343 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb343 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.Name = "" } else { - yyv346 := &x.ObjectMeta - yyv346.CodecDecodeSelf(d) + yyv18 := &x.Name + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*string)(yyv18)) = r.DecodeString() + } } - yyj343++ - if yyhl343 { - yyb343 = yyj343 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb343 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb343 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Description = "" + x.UpdatedAnnotations = nil } else { - x.Description = string(r.DecodeString()) + yyv20 := &x.UpdatedAnnotations + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + z.F.DecMapStringStringX(yyv20, false, d) + } } - yyj343++ - if yyhl343 { - yyb343 = yyj343 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb343 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb343 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Versions = nil + x.RollbackTo = RollbackConfig{} } else { - yyv348 := &x.Versions - yym349 := z.DecBinary() - _ = yym349 - if false { - } else { - h.decSliceAPIVersion((*[]APIVersion)(yyv348), d) - } + yyv22 := &x.RollbackTo + yyv22.CodecDecodeSelf(d) } for { - yyj343++ - if yyhl343 { - yyb343 = yyj343 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb343 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb343 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj343-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ThirdPartyResourceList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *RollbackConfig) 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 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep351 := !z.EncBinary() - yy2arr351 := z.EncBasicHandle().StructToArray - var yyq351 [4]bool - _, _, _ = yysep351, yyq351, yy2arr351 - const yyr351 bool = false - yyq351[0] = x.Kind != "" - yyq351[1] = x.APIVersion != "" - yyq351[2] = true - var yynn351 int - if yyr351 || yy2arr351 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Revision != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) } else { - yynn351 = 1 - for _, b := range yyq351 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn351++ - } - } - r.EncodeMapStart(yynn351) - yynn351 = 0 - } - if yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[0] { - yym353 := z.EncBinary() - _ = yym353 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq351[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym354 := z.EncBinary() - _ = yym354 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[1] { - yym356 := z.EncBinary() - _ = yym356 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq351[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym357 := z.EncBinary() - _ = yym357 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + yynn2++ } } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr351 || yy2arr351 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq351[2] { - yy359 := &x.ListMeta - yym360 := z.EncBinary() - _ = yym360 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { - } else if z.HasExtensions() && z.EncExt(yy359) { } else { - z.EncFallback(yy359) + r.EncodeInt(int64(x.Revision)) } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq351[2] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) + r.EncodeString(codecSelferC_UTF81234, string("revision")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy361 := &x.ListMeta - yym362 := z.EncBinary() - _ = yym362 - if false { - } else if z.HasExtensions() && z.EncExt(yy361) { - } else { - z.EncFallback(yy361) - } - } - } - if yyr351 || yy2arr351 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym364 := z.EncBinary() - _ = yym364 - if false { - } else { - h.encSliceThirdPartyResource(([]ThirdPartyResource)(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 { - yym365 := z.EncBinary() - _ = yym365 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - h.encSliceThirdPartyResource(([]ThirdPartyResource)(x.Items), e) + r.EncodeInt(int64(x.Revision)) } } } - if yyr351 || yy2arr351 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -4375,29 +4936,29 @@ func (x *ThirdPartyResourceList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ThirdPartyResourceList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *RollbackConfig) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym366 := z.DecBinary() - _ = yym366 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct367 := r.ContainerType() - if yyct367 == codecSelferValueTypeMap1234 { - yyl367 := r.ReadMapStart() - if yyl367 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl367, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct367 == codecSelferValueTypeArray1234 { - yyl367 := r.ReadArrayStart() - if yyl367 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl367, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -4405,16 +4966,16 @@ func (x *ThirdPartyResourceList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ThirdPartyResourceList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys368Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys368Slc - var yyhl368 bool = l >= 0 - for yyj368 := 0; ; yyj368++ { - if yyhl368 { - if yyj368 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -4423,211 +4984,145 @@ func (x *ThirdPartyResourceList) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys368Slc = r.DecodeBytes(yys368Slc, true, true) - yys368 := string(yys368Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys368 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv371 := &x.ListMeta - yym372 := z.DecBinary() - _ = yym372 - if false { - } else if z.HasExtensions() && z.DecExt(yyv371) { - } else { - z.DecFallback(yyv371, false) - } - } - case "items": + switch yys3 { + case "revision": if r.TryDecodeAsNil() { - x.Items = nil + x.Revision = 0 } else { - yyv373 := &x.Items - yym374 := z.DecBinary() - _ = yym374 + yyv4 := &x.Revision + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceThirdPartyResource((*[]ThirdPartyResource)(yyv373), d) + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) } } default: - z.DecStructFieldNotFound(-1, yys368) - } // end switch yys368 - } // end for yyj368 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ThirdPartyResourceList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj375 int - var yyb375 bool - var yyhl375 bool = l >= 0 - yyj375++ - if yyhl375 { - yyb375 = yyj375 > l - } else { - yyb375 = r.CheckBreak() - } - if yyb375 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj375++ - if yyhl375 { - yyb375 = yyj375 > l - } else { - yyb375 = r.CheckBreak() - } - if yyb375 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj375++ - if yyhl375 { - yyb375 = yyj375 > l - } else { - yyb375 = r.CheckBreak() - } - if yyb375 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyv378 := &x.ListMeta - yym379 := z.DecBinary() - _ = yym379 - if false { - } else if z.HasExtensions() && z.DecExt(yyv378) { - } else { - z.DecFallback(yyv378, false) - } - } - yyj375++ - if yyhl375 { - yyb375 = yyj375 > l - } else { - yyb375 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb375 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Items = nil + x.Revision = 0 } else { - yyv380 := &x.Items - yym381 := z.DecBinary() - _ = yym381 + yyv7 := &x.Revision + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceThirdPartyResource((*[]ThirdPartyResource)(yyv380), d) + *((*int64)(yyv7)) = int64(r.DecodeInt(64)) } } for { - yyj375++ - if yyhl375 { - yyb375 = yyj375 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb375 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb375 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj375-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *APIVersion) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym382 := z.EncBinary() - _ = yym382 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep383 := !z.EncBinary() - yy2arr383 := z.EncBasicHandle().StructToArray - var yyq383 [1]bool - _, _, _ = yysep383, yyq383, yy2arr383 - const yyr383 bool = false - yyq383[0] = x.Name != "" - var yynn383 int - if yyr383 || yy2arr383 { - r.EncodeArrayStart(1) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Type != "" + yyq2[1] = x.RollingUpdate != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn383 = 0 - for _, b := range yyq383 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn383++ + yynn2++ } } - r.EncodeMapStart(yynn383) - yynn383 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr383 || yy2arr383 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq383[0] { - yym385 := z.EncBinary() - _ = yym385 - if false { + if yyq2[0] { + x.Type.CodecEncodeSelf(e) + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.RollingUpdate == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + x.RollingUpdate.CodecEncodeSelf(e) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq383[0] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("name")) + r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym386 := z.EncBinary() - _ = yym386 - if false { + if x.RollingUpdate == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + x.RollingUpdate.CodecEncodeSelf(e) } } } - if yyr383 || yy2arr383 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -4636,29 +5131,29 @@ func (x *APIVersion) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *APIVersion) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentStrategy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym387 := z.DecBinary() - _ = yym387 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct388 := r.ContainerType() - if yyct388 == codecSelferValueTypeMap1234 { - yyl388 := r.ReadMapStart() - if yyl388 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl388, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct388 == codecSelferValueTypeArray1234 { - yyl388 := r.ReadArrayStart() - if yyl388 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl388, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -4666,16 +5161,16 @@ func (x *APIVersion) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *APIVersion) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys389Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys389Slc - var yyhl389 bool = l >= 0 - for yyj389 := 0; ; yyj389++ { - if yyhl389 { - if yyj389 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -4684,197 +5179,233 @@ func (x *APIVersion) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys389Slc = r.DecodeBytes(yys389Slc, true, true) - yys389 := string(yys389Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys389 { - case "name": + switch yys3 { + case "type": if r.TryDecodeAsNil() { - x.Name = "" + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "rollingUpdate": + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } } else { - x.Name = string(r.DecodeString()) + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateDeployment) + } + x.RollingUpdate.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys389) - } // end switch yys389 - } // end for yyj389 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *APIVersion) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj391 int - var yyb391 bool - var yyhl391 bool = l >= 0 - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb391 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb391 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Name = "" + x.Type = "" + } else { + yyv7 := &x.Type + yyv7.CodecDecodeSelf(d) + } + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } } else { - x.Name = string(r.DecodeString()) + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateDeployment) + } + x.RollingUpdate.CodecDecodeSelf(d) } for { - yyj391++ - if yyhl391 { - yyb391 = yyj391 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb391 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb391 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj391-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ThirdPartyResourceData) CodecEncodeSelf(e *codec1978.Encoder) { +func (x DeploymentStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *DeploymentStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym393 := z.EncBinary() - _ = yym393 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep394 := !z.EncBinary() - yy2arr394 := z.EncBasicHandle().StructToArray - var yyq394 [4]bool - _, _, _ = yysep394, yyq394, yy2arr394 - const yyr394 bool = false - yyq394[0] = x.Kind != "" - yyq394[1] = x.APIVersion != "" - yyq394[2] = true - yyq394[3] = len(x.Data) != 0 - var yynn394 int - if yyr394 || yy2arr394 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.MaxUnavailable != nil + yyq2[1] = x.MaxSurge != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn394 = 0 - for _, b := range yyq394 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn394++ - } - } - r.EncodeMapStart(yynn394) - yynn394 = 0 - } - if yyr394 || yy2arr394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq394[0] { - yym396 := z.EncBinary() - _ = yym396 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq394[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym397 := z.EncBinary() - _ = yym397 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + yynn2++ } } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr394 || yy2arr394 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq394[1] { - yym399 := z.EncBinary() - _ = yym399 - if false { + if yyq2[0] { + if x.MaxUnavailable == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym4 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq394[1] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym400 := z.EncBinary() - _ = yym400 - if false { + if x.MaxUnavailable == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym5 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } } } } - if yyr394 || yy2arr394 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq394[2] { - yy402 := &x.ObjectMeta - yy402.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq394[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy403 := &x.ObjectMeta - yy403.CodecEncodeSelf(e) - } - } - if yyr394 || yy2arr394 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq394[3] { - if x.Data == nil { + if yyq2[1] { + if x.MaxSurge == nil { r.EncodeNil() } else { - yym405 := z.EncBinary() - _ = yym405 + yym7 := z.EncBinary() + _ = yym7 if false { + } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { + } else if !yym7 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxSurge) } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) + z.EncFallback(x.MaxSurge) } } } else { r.EncodeNil() } } else { - if yyq394[3] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("data")) + r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Data == nil { + if x.MaxSurge == nil { r.EncodeNil() } else { - yym406 := z.EncBinary() - _ = yym406 + yym8 := z.EncBinary() + _ = yym8 if false { + } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxSurge) } else { - r.EncodeStringBytes(codecSelferC_RAW1234, []byte(x.Data)) + z.EncFallback(x.MaxSurge) } } } } - if yyr394 || yy2arr394 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -4883,29 +5414,29 @@ func (x *ThirdPartyResourceData) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ThirdPartyResourceData) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *RollingUpdateDeployment) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym407 := z.DecBinary() - _ = yym407 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct408 := r.ContainerType() - if yyct408 == codecSelferValueTypeMap1234 { - yyl408 := r.ReadMapStart() - if yyl408 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl408, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct408 == codecSelferValueTypeArray1234 { - yyl408 := r.ReadArrayStart() - if yyl408 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl408, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -4913,16 +5444,16 @@ func (x *ThirdPartyResourceData) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ThirdPartyResourceData) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys409Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys409Slc - var yyhl409 bool = l >= 0 - for yyj409 := 0; ; yyj409++ { - if yyhl409 { - if yyj409 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -4931,279 +5462,393 @@ func (x *ThirdPartyResourceData) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys409Slc = r.DecodeBytes(yys409Slc, true, true) - yys409 := string(yys409Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys409 { - 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": + switch yys3 { + case "maxUnavailable": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil + } } else { - yyv412 := &x.ObjectMeta - yyv412.CodecDecodeSelf(d) + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg5_intstr.IntOrString) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) + } else { + z.DecFallback(x.MaxUnavailable, false) + } } - case "data": + case "maxSurge": if r.TryDecodeAsNil() { - x.Data = nil + if x.MaxSurge != nil { + x.MaxSurge = nil + } } else { - yyv413 := &x.Data - yym414 := z.DecBinary() - _ = yym414 + if x.MaxSurge == nil { + x.MaxSurge = new(pkg5_intstr.IntOrString) + } + yym7 := z.DecBinary() + _ = yym7 if false { + } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxSurge) } else { - *yyv413 = r.DecodeBytes(*(*[]byte)(yyv413), false, false) + z.DecFallback(x.MaxSurge, false) } } default: - z.DecStructFieldNotFound(-1, yys409) - } // end switch yys409 - } // end for yyj409 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ThirdPartyResourceData) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj415 int - var yyb415 bool - var yyhl415 bool = l >= 0 - yyj415++ - if yyhl415 { - yyb415 = yyj415 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb415 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb415 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil + } } else { - x.Kind = string(r.DecodeString()) + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg5_intstr.IntOrString) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) + } else { + z.DecFallback(x.MaxUnavailable, false) + } } - yyj415++ - if yyhl415 { - yyb415 = yyj415 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb415 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb415 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj415++ - if yyhl415 { - yyb415 = yyj415 > l + if x.MaxSurge != nil { + x.MaxSurge = nil + } } else { - yyb415 = r.CheckBreak() - } - if yyb415 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} - } else { - yyv418 := &x.ObjectMeta - yyv418.CodecDecodeSelf(d) - } - yyj415++ - if yyhl415 { - yyb415 = yyj415 > l - } else { - yyb415 = r.CheckBreak() - } - if yyb415 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Data = nil - } else { - yyv419 := &x.Data - yym420 := z.DecBinary() - _ = yym420 - if false { - } else { - *yyv419 = r.DecodeBytes(*(*[]byte)(yyv419), false, false) - } + if x.MaxSurge == nil { + x.MaxSurge = new(pkg5_intstr.IntOrString) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxSurge) + } else { + z.DecFallback(x.MaxSurge, false) + } } for { - yyj415++ - if yyhl415 { - yyb415 = yyj415 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb415 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb415 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj415-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DeploymentStatus) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym421 := z.EncBinary() - _ = yym421 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep422 := !z.EncBinary() - yy2arr422 := z.EncBasicHandle().StructToArray - var yyq422 [5]bool - _, _, _ = yysep422, yyq422, yy2arr422 - const yyr422 bool = false - yyq422[0] = x.Kind != "" - yyq422[1] = x.APIVersion != "" - yyq422[2] = true - yyq422[3] = true - yyq422[4] = true - var yynn422 int - if yyr422 || yy2arr422 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [8]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ObservedGeneration != 0 + yyq2[1] = x.Replicas != 0 + yyq2[2] = x.UpdatedReplicas != 0 + yyq2[3] = x.ReadyReplicas != 0 + yyq2[4] = x.AvailableReplicas != 0 + yyq2[5] = x.UnavailableReplicas != 0 + yyq2[6] = len(x.Conditions) != 0 + yyq2[7] = x.CollisionCount != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(8) } else { - yynn422 = 0 - for _, b := range yyq422 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn422++ + yynn2++ } } - r.EncodeMapStart(yynn422) - yynn422 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr422 || yy2arr422 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq422[0] { - yym424 := z.EncBinary() - _ = yym424 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + r.EncodeInt(int64(x.ObservedGeneration)) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeInt(0) } } else { - if yyq422[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym425 := z.EncBinary() - _ = yym425 + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + r.EncodeInt(int64(x.ObservedGeneration)) } } } - if yyr422 || yy2arr422 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq422[1] { - yym427 := z.EncBinary() - _ = yym427 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + r.EncodeInt(int64(x.Replicas)) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeInt(0) } } else { - if yyq422[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym428 := z.EncBinary() - _ = yym428 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + r.EncodeInt(int64(x.Replicas)) } } } - if yyr422 || yy2arr422 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq422[2] { - yy430 := &x.ObjectMeta - yy430.CodecEncodeSelf(e) + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.UpdatedReplicas)) + } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq422[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) + r.EncodeString(codecSelferC_UTF81234, string("updatedReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.UpdatedReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.ReadyReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.ReadyReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + r.EncodeInt(int64(x.AvailableReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.AvailableReplicas)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 + if false { + } else { + r.EncodeInt(int64(x.UnavailableReplicas)) + } + } else { + r.EncodeInt(0) + } + } else { + if yyq2[5] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("unavailableReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy431 := &x.ObjectMeta - yy431.CodecEncodeSelf(e) + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.UnavailableReplicas)) + } } } - if yyr422 || yy2arr422 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq422[3] { - yy433 := &x.Spec - yy433.CodecEncodeSelf(e) + if yyq2[6] { + if x.Conditions == nil { + r.EncodeNil() + } else { + yym22 := z.EncBinary() + _ = yym22 + if false { + } else { + h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) + } + } } else { r.EncodeNil() } } else { - if yyq422[3] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) + r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy434 := &x.Spec - yy434.CodecEncodeSelf(e) + if x.Conditions == nil { + r.EncodeNil() + } else { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) + } + } } } - if yyr422 || yy2arr422 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq422[4] { - yy436 := &x.Status - yy436.CodecEncodeSelf(e) + if yyq2[7] { + if x.CollisionCount == nil { + r.EncodeNil() + } else { + yy25 := *x.CollisionCount + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(yy25)) + } + } } else { r.EncodeNil() } } else { - if yyq422[4] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) + r.EncodeString(codecSelferC_UTF81234, string("collisionCount")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy437 := &x.Status - yy437.CodecEncodeSelf(e) + if x.CollisionCount == nil { + r.EncodeNil() + } else { + yy27 := *x.CollisionCount + yym28 := z.EncBinary() + _ = yym28 + if false { + } else { + r.EncodeInt(int64(yy27)) + } + } } } - if yyr422 || yy2arr422 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -5212,29 +5857,29 @@ func (x *Deployment) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym438 := z.DecBinary() - _ = yym438 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct439 := r.ContainerType() - if yyct439 == codecSelferValueTypeMap1234 { - yyl439 := r.ReadMapStart() - if yyl439 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl439, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct439 == codecSelferValueTypeArray1234 { - yyl439 := r.ReadArrayStart() - if yyl439 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl439, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -5242,16 +5887,16 @@ func (x *Deployment) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys440Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys440Slc - var yyhl440 bool = l >= 0 - for yyj440 := 0; ; yyj440++ { - if yyhl440 { - if yyj440 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -5260,3800 +5905,525 @@ func (x *Deployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys440Slc = r.DecodeBytes(yys440Slc, true, true) - yys440 := string(yys440Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys440 { - case "kind": + switch yys3 { + case "observedGeneration": if r.TryDecodeAsNil() { - x.Kind = "" + x.ObservedGeneration = 0 } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.ObservedGeneration + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } } - case "apiVersion": + case "replicas": if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Replicas = 0 } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.Replicas + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } - case "metadata": + case "updatedReplicas": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.UpdatedReplicas = 0 } else { - yyv443 := &x.ObjectMeta - yyv443.CodecDecodeSelf(d) + yyv8 := &x.UpdatedReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } - case "spec": + case "readyReplicas": if r.TryDecodeAsNil() { - x.Spec = DeploymentSpec{} + x.ReadyReplicas = 0 + } else { + yyv10 := &x.ReadyReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } + } + case "availableReplicas": + if r.TryDecodeAsNil() { + x.AvailableReplicas = 0 } else { - yyv444 := &x.Spec - yyv444.CodecDecodeSelf(d) + yyv12 := &x.AvailableReplicas + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(yyv12)) = int32(r.DecodeInt(32)) + } } - case "status": + case "unavailableReplicas": if r.TryDecodeAsNil() { - x.Status = DeploymentStatus{} + x.UnavailableReplicas = 0 + } else { + yyv14 := &x.UnavailableReplicas + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } + } + case "conditions": + if r.TryDecodeAsNil() { + x.Conditions = nil + } else { + yyv16 := &x.Conditions + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv16), d) + } + } + case "collisionCount": + if r.TryDecodeAsNil() { + if x.CollisionCount != nil { + x.CollisionCount = nil + } } else { - yyv445 := &x.Status - yyv445.CodecDecodeSelf(d) + if x.CollisionCount == nil { + x.CollisionCount = new(int64) + } + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int64)(x.CollisionCount)) = int64(r.DecodeInt(64)) + } } default: - z.DecStructFieldNotFound(-1, yys440) - } // end switch yys440 - } // end for yyj440 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *Deployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj446 int - var yyb446 bool - var yyhl446 bool = l >= 0 - yyj446++ - if yyhl446 { - yyb446 = yyj446 > l - } else { - yyb446 = r.CheckBreak() - } - if yyb446 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj446++ - if yyhl446 { - yyb446 = yyj446 > l + var yyj20 int + var yyb20 bool + var yyhl20 bool = l >= 0 + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb446 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb446 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + x.ObservedGeneration = 0 } else { - x.APIVersion = string(r.DecodeString()) + yyv21 := &x.ObservedGeneration + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } } - yyj446++ - if yyhl446 { - yyb446 = yyj446 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb446 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb446 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.Replicas = 0 } else { - yyv449 := &x.ObjectMeta - yyv449.CodecDecodeSelf(d) + yyv23 := &x.Replicas + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } } - yyj446++ - if yyhl446 { - yyb446 = yyj446 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb446 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb446 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Spec = DeploymentSpec{} + x.UpdatedReplicas = 0 } else { - yyv450 := &x.Spec - yyv450.CodecDecodeSelf(d) + yyv25 := &x.UpdatedReplicas + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } } - yyj446++ - if yyhl446 { - yyb446 = yyj446 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb446 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb446 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = DeploymentStatus{} - } else { - yyv451 := &x.Status - yyv451.CodecDecodeSelf(d) - } - for { - yyj446++ - if yyhl446 { - yyb446 = yyj446 > l - } else { - yyb446 = r.CheckBreak() - } - if yyb446 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj446-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym452 := z.EncBinary() - _ = yym452 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep453 := !z.EncBinary() - yy2arr453 := z.EncBasicHandle().StructToArray - var yyq453 [9]bool - _, _, _ = yysep453, yyq453, yy2arr453 - const yyr453 bool = false - yyq453[0] = x.Replicas != nil - yyq453[1] = x.Selector != nil - yyq453[3] = true - yyq453[4] = x.MinReadySeconds != 0 - yyq453[5] = x.RevisionHistoryLimit != nil - yyq453[6] = x.Paused != false - yyq453[7] = x.RollbackTo != nil - yyq453[8] = x.ProgressDeadlineSeconds != nil - var yynn453 int - if yyr453 || yy2arr453 { - r.EncodeArrayStart(9) - } else { - yynn453 = 1 - for _, b := range yyq453 { - if b { - yynn453++ - } - } - r.EncodeMapStart(yynn453) - yynn453 = 0 - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[0] { - if x.Replicas == nil { - r.EncodeNil() - } else { - yy455 := *x.Replicas - yym456 := z.EncBinary() - _ = yym456 - if false { - } else { - r.EncodeInt(int64(yy455)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq453[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Replicas == nil { - r.EncodeNil() - } else { - yy457 := *x.Replicas - yym458 := z.EncBinary() - _ = yym458 - if false { - } else { - r.EncodeInt(int64(yy457)) - } - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym460 := z.EncBinary() - _ = yym460 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq453[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym461 := z.EncBinary() - _ = yym461 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy463 := &x.Template - yy463.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy464 := &x.Template - yy464.CodecEncodeSelf(e) - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[3] { - yy466 := &x.Strategy - yy466.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq453[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("strategy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy467 := &x.Strategy - yy467.CodecEncodeSelf(e) - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[4] { - yym469 := z.EncBinary() - _ = yym469 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq453[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym470 := z.EncBinary() - _ = yym470 - if false { - } else { - r.EncodeInt(int64(x.MinReadySeconds)) - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[5] { - if x.RevisionHistoryLimit == nil { - r.EncodeNil() - } else { - yy472 := *x.RevisionHistoryLimit - yym473 := z.EncBinary() - _ = yym473 - if false { - } else { - r.EncodeInt(int64(yy472)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq453[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RevisionHistoryLimit == nil { - r.EncodeNil() - } else { - yy474 := *x.RevisionHistoryLimit - yym475 := z.EncBinary() - _ = yym475 - if false { - } else { - r.EncodeInt(int64(yy474)) - } - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[6] { - yym477 := z.EncBinary() - _ = yym477 - if false { - } else { - r.EncodeBool(bool(x.Paused)) - } - } else { - r.EncodeBool(false) - } - } else { - if yyq453[6] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("paused")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym478 := z.EncBinary() - _ = yym478 - if false { - } else { - r.EncodeBool(bool(x.Paused)) - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[7] { - if x.RollbackTo == nil { - r.EncodeNil() - } else { - x.RollbackTo.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq453[7] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RollbackTo == nil { - r.EncodeNil() - } else { - x.RollbackTo.CodecEncodeSelf(e) - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq453[8] { - if x.ProgressDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy481 := *x.ProgressDeadlineSeconds - yym482 := z.EncBinary() - _ = yym482 - if false { - } else { - r.EncodeInt(int64(yy481)) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq453[8] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("progressDeadlineSeconds")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ProgressDeadlineSeconds == nil { - r.EncodeNil() - } else { - yy483 := *x.ProgressDeadlineSeconds - yym484 := z.EncBinary() - _ = yym484 - if false { - } else { - r.EncodeInt(int64(yy483)) - } - } - } - } - if yyr453 || yy2arr453 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym485 := z.DecBinary() - _ = yym485 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct486 := r.ContainerType() - if yyct486 == codecSelferValueTypeMap1234 { - yyl486 := r.ReadMapStart() - if yyl486 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl486, d) - } - } else if yyct486 == codecSelferValueTypeArray1234 { - yyl486 := r.ReadArrayStart() - if yyl486 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl486, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys487Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys487Slc - var yyhl487 bool = l >= 0 - for yyj487 := 0; ; yyj487++ { - if yyhl487 { - if yyj487 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys487Slc = r.DecodeBytes(yys487Slc, true, true) - yys487 := string(yys487Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys487 { - case "replicas": - if r.TryDecodeAsNil() { - if x.Replicas != nil { - x.Replicas = nil - } - } else { - if x.Replicas == nil { - x.Replicas = new(int32) - } - yym489 := z.DecBinary() - _ = yym489 - if false { - } else { - *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) - } - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym491 := z.DecBinary() - _ = yym491 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv492 := &x.Template - yyv492.CodecDecodeSelf(d) - } - case "strategy": - if r.TryDecodeAsNil() { - x.Strategy = DeploymentStrategy{} - } else { - yyv493 := &x.Strategy - yyv493.CodecDecodeSelf(d) - } - case "minReadySeconds": - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - case "revisionHistoryLimit": - if r.TryDecodeAsNil() { - if x.RevisionHistoryLimit != nil { - x.RevisionHistoryLimit = nil - } - } else { - if x.RevisionHistoryLimit == nil { - x.RevisionHistoryLimit = new(int32) - } - yym496 := z.DecBinary() - _ = yym496 - if false { - } else { - *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) - } - } - case "paused": - if r.TryDecodeAsNil() { - x.Paused = false - } else { - x.Paused = bool(r.DecodeBool()) - } - case "rollbackTo": - if r.TryDecodeAsNil() { - if x.RollbackTo != nil { - x.RollbackTo = nil - } - } else { - if x.RollbackTo == nil { - x.RollbackTo = new(RollbackConfig) - } - x.RollbackTo.CodecDecodeSelf(d) - } - case "progressDeadlineSeconds": - if r.TryDecodeAsNil() { - if x.ProgressDeadlineSeconds != nil { - x.ProgressDeadlineSeconds = nil - } - } else { - if x.ProgressDeadlineSeconds == nil { - x.ProgressDeadlineSeconds = new(int32) - } - yym500 := z.DecBinary() - _ = yym500 - if false { - } else { - *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) - } - } - default: - z.DecStructFieldNotFound(-1, yys487) - } // end switch yys487 - } // end for yyj487 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj501 int - var yyb501 bool - var yyhl501 bool = l >= 0 - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - 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) - } - yym503 := z.DecBinary() - _ = yym503 - if false { - } else { - *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) - } - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - 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(pkg1_unversioned.LabelSelector) - } - yym505 := z.DecBinary() - _ = yym505 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv506 := &x.Template - yyv506.CodecDecodeSelf(d) - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Strategy = DeploymentStrategy{} - } else { - yyv507 := &x.Strategy - yyv507.CodecDecodeSelf(d) - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinReadySeconds = 0 - } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.RevisionHistoryLimit != nil { - x.RevisionHistoryLimit = nil - } - } else { - if x.RevisionHistoryLimit == nil { - x.RevisionHistoryLimit = new(int32) - } - yym510 := z.DecBinary() - _ = yym510 - if false { - } else { - *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) - } - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Paused = false - } else { - x.Paused = bool(r.DecodeBool()) - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.RollbackTo != nil { - x.RollbackTo = nil - } - } else { - if x.RollbackTo == nil { - x.RollbackTo = new(RollbackConfig) - } - x.RollbackTo.CodecDecodeSelf(d) - } - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.ProgressDeadlineSeconds != nil { - x.ProgressDeadlineSeconds = nil - } - } else { - if x.ProgressDeadlineSeconds == nil { - x.ProgressDeadlineSeconds = new(int32) - } - yym514 := z.DecBinary() - _ = yym514 - if false { - } else { - *((*int32)(x.ProgressDeadlineSeconds)) = int32(r.DecodeInt(32)) - } - } - for { - yyj501++ - if yyhl501 { - yyb501 = yyj501 > l - } else { - yyb501 = r.CheckBreak() - } - if yyb501 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj501-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentRollback) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym515 := z.EncBinary() - _ = yym515 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep516 := !z.EncBinary() - yy2arr516 := z.EncBasicHandle().StructToArray - var yyq516 [5]bool - _, _, _ = yysep516, yyq516, yy2arr516 - const yyr516 bool = false - yyq516[0] = x.Kind != "" - yyq516[1] = x.APIVersion != "" - yyq516[3] = len(x.UpdatedAnnotations) != 0 - var yynn516 int - if yyr516 || yy2arr516 { - r.EncodeArrayStart(5) - } else { - yynn516 = 2 - for _, b := range yyq516 { - if b { - yynn516++ - } - } - r.EncodeMapStart(yynn516) - yynn516 = 0 - } - if yyr516 || yy2arr516 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq516[0] { - yym518 := z.EncBinary() - _ = yym518 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq516[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym519 := z.EncBinary() - _ = yym519 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr516 || yy2arr516 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq516[1] { - yym521 := z.EncBinary() - _ = yym521 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq516[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym522 := z.EncBinary() - _ = yym522 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr516 || yy2arr516 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym524 := z.EncBinary() - _ = yym524 - 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) - yym525 := z.EncBinary() - _ = yym525 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Name)) - } - } - if yyr516 || yy2arr516 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq516[3] { - if x.UpdatedAnnotations == nil { - r.EncodeNil() - } else { - yym527 := z.EncBinary() - _ = yym527 - if false { - } else { - z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq516[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("updatedAnnotations")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.UpdatedAnnotations == nil { - r.EncodeNil() - } else { - yym528 := z.EncBinary() - _ = yym528 - if false { - } else { - z.F.EncMapStringStringV(x.UpdatedAnnotations, false, e) - } - } - } - } - if yyr516 || yy2arr516 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy530 := &x.RollbackTo - yy530.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rollbackTo")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy531 := &x.RollbackTo - yy531.CodecEncodeSelf(e) - } - if yyr516 || yy2arr516 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentRollback) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym532 := z.DecBinary() - _ = yym532 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct533 := r.ContainerType() - if yyct533 == codecSelferValueTypeMap1234 { - yyl533 := r.ReadMapStart() - if yyl533 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl533, d) - } - } else if yyct533 == codecSelferValueTypeArray1234 { - yyl533 := r.ReadArrayStart() - if yyl533 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl533, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentRollback) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys534Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys534Slc - var yyhl534 bool = l >= 0 - for yyj534 := 0; ; yyj534++ { - if yyhl534 { - if yyj534 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys534Slc = r.DecodeBytes(yys534Slc, true, true) - yys534 := string(yys534Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys534 { - 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 "name": - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - case "updatedAnnotations": - if r.TryDecodeAsNil() { - x.UpdatedAnnotations = nil - } else { - yyv538 := &x.UpdatedAnnotations - yym539 := z.DecBinary() - _ = yym539 - if false { - } else { - z.F.DecMapStringStringX(yyv538, false, d) - } - } - case "rollbackTo": - if r.TryDecodeAsNil() { - x.RollbackTo = RollbackConfig{} - } else { - yyv540 := &x.RollbackTo - yyv540.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys534) - } // end switch yys534 - } // end for yyj534 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentRollback) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj541 int - var yyb541 bool - var yyhl541 bool = l >= 0 - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Name = "" - } else { - x.Name = string(r.DecodeString()) - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UpdatedAnnotations = nil - } else { - yyv545 := &x.UpdatedAnnotations - yym546 := z.DecBinary() - _ = yym546 - if false { - } else { - z.F.DecMapStringStringX(yyv545, false, d) - } - } - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.RollbackTo = RollbackConfig{} - } else { - yyv547 := &x.RollbackTo - yyv547.CodecDecodeSelf(d) - } - for { - yyj541++ - if yyhl541 { - yyb541 = yyj541 > l - } else { - yyb541 = r.CheckBreak() - } - if yyb541 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj541-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *RollbackConfig) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym548 := z.EncBinary() - _ = yym548 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep549 := !z.EncBinary() - yy2arr549 := z.EncBasicHandle().StructToArray - var yyq549 [1]bool - _, _, _ = yysep549, yyq549, yy2arr549 - const yyr549 bool = false - yyq549[0] = x.Revision != 0 - var yynn549 int - if yyr549 || yy2arr549 { - r.EncodeArrayStart(1) - } else { - yynn549 = 0 - for _, b := range yyq549 { - if b { - yynn549++ - } - } - r.EncodeMapStart(yynn549) - yynn549 = 0 - } - if yyr549 || yy2arr549 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq549[0] { - yym551 := z.EncBinary() - _ = yym551 - if false { - } else { - r.EncodeInt(int64(x.Revision)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq549[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("revision")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym552 := z.EncBinary() - _ = yym552 - if false { - } else { - r.EncodeInt(int64(x.Revision)) - } - } - } - if yyr549 || yy2arr549 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *RollbackConfig) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym553 := z.DecBinary() - _ = yym553 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct554 := r.ContainerType() - if yyct554 == codecSelferValueTypeMap1234 { - yyl554 := r.ReadMapStart() - if yyl554 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl554, d) - } - } else if yyct554 == codecSelferValueTypeArray1234 { - yyl554 := r.ReadArrayStart() - if yyl554 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl554, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *RollbackConfig) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys555Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys555Slc - var yyhl555 bool = l >= 0 - for yyj555 := 0; ; yyj555++ { - if yyhl555 { - if yyj555 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys555Slc = r.DecodeBytes(yys555Slc, true, true) - yys555 := string(yys555Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys555 { - case "revision": - if r.TryDecodeAsNil() { - x.Revision = 0 - } else { - x.Revision = int64(r.DecodeInt(64)) - } - default: - z.DecStructFieldNotFound(-1, yys555) - } // end switch yys555 - } // end for yyj555 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *RollbackConfig) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj557 int - var yyb557 bool - var yyhl557 bool = l >= 0 - yyj557++ - if yyhl557 { - yyb557 = yyj557 > l - } else { - yyb557 = r.CheckBreak() - } - if yyb557 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Revision = 0 - } else { - x.Revision = int64(r.DecodeInt(64)) - } - for { - yyj557++ - if yyhl557 { - yyb557 = yyj557 > l - } else { - yyb557 = r.CheckBreak() - } - if yyb557 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj557-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentStrategy) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym559 := z.EncBinary() - _ = yym559 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep560 := !z.EncBinary() - yy2arr560 := z.EncBasicHandle().StructToArray - var yyq560 [2]bool - _, _, _ = yysep560, yyq560, yy2arr560 - const yyr560 bool = false - yyq560[0] = x.Type != "" - yyq560[1] = x.RollingUpdate != nil - var yynn560 int - if yyr560 || yy2arr560 { - r.EncodeArrayStart(2) - } else { - yynn560 = 0 - for _, b := range yyq560 { - if b { - yynn560++ - } - } - r.EncodeMapStart(yynn560) - yynn560 = 0 - } - if yyr560 || yy2arr560 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq560[0] { - x.Type.CodecEncodeSelf(e) - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq560[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("type")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - x.Type.CodecEncodeSelf(e) - } - } - if yyr560 || yy2arr560 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq560[1] { - if x.RollingUpdate == nil { - r.EncodeNil() - } else { - x.RollingUpdate.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq560[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.RollingUpdate == nil { - r.EncodeNil() - } else { - x.RollingUpdate.CodecEncodeSelf(e) - } - } - } - if yyr560 || yy2arr560 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentStrategy) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym563 := z.DecBinary() - _ = yym563 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct564 := r.ContainerType() - if yyct564 == codecSelferValueTypeMap1234 { - yyl564 := r.ReadMapStart() - if yyl564 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl564, d) - } - } else if yyct564 == codecSelferValueTypeArray1234 { - yyl564 := r.ReadArrayStart() - if yyl564 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl564, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys565Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys565Slc - var yyhl565 bool = l >= 0 - for yyj565 := 0; ; yyj565++ { - if yyhl565 { - if yyj565 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys565Slc = r.DecodeBytes(yys565Slc, true, true) - yys565 := string(yys565Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys565 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentStrategyType(r.DecodeString()) - } - case "rollingUpdate": - if r.TryDecodeAsNil() { - if x.RollingUpdate != nil { - x.RollingUpdate = nil - } - } else { - if x.RollingUpdate == nil { - x.RollingUpdate = new(RollingUpdateDeployment) - } - x.RollingUpdate.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys565) - } // end switch yys565 - } // end for yyj565 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj568 int - var yyb568 bool - var yyhl568 bool = l >= 0 - yyj568++ - if yyhl568 { - yyb568 = yyj568 > l - } else { - yyb568 = r.CheckBreak() - } - if yyb568 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentStrategyType(r.DecodeString()) - } - yyj568++ - if yyhl568 { - yyb568 = yyj568 > l - } else { - yyb568 = r.CheckBreak() - } - if yyb568 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.RollingUpdate != nil { - x.RollingUpdate = nil - } - } else { - if x.RollingUpdate == nil { - x.RollingUpdate = new(RollingUpdateDeployment) - } - x.RollingUpdate.CodecDecodeSelf(d) - } - for { - yyj568++ - if yyhl568 { - yyb568 = yyj568 > l - } else { - yyb568 = r.CheckBreak() - } - if yyb568 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj568-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x DeploymentStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym571 := z.EncBinary() - _ = yym571 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *DeploymentStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym572 := z.DecBinary() - _ = yym572 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *RollingUpdateDeployment) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym573 := z.EncBinary() - _ = yym573 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep574 := !z.EncBinary() - yy2arr574 := z.EncBasicHandle().StructToArray - var yyq574 [2]bool - _, _, _ = yysep574, yyq574, yy2arr574 - const yyr574 bool = false - yyq574[0] = x.MaxUnavailable != nil - yyq574[1] = x.MaxSurge != nil - var yynn574 int - if yyr574 || yy2arr574 { - r.EncodeArrayStart(2) - } else { - yynn574 = 0 - for _, b := range yyq574 { - if b { - yynn574++ - } - } - r.EncodeMapStart(yynn574) - yynn574 = 0 - } - if yyr574 || yy2arr574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq574[0] { - if x.MaxUnavailable == nil { - r.EncodeNil() - } else { - yym576 := z.EncBinary() - _ = yym576 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { - } else if !yym576 && z.IsJSONHandle() { - z.EncJSONMarshal(x.MaxUnavailable) - } else { - z.EncFallback(x.MaxUnavailable) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq574[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.MaxUnavailable == nil { - r.EncodeNil() - } else { - yym577 := z.EncBinary() - _ = yym577 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { - } else if !yym577 && z.IsJSONHandle() { - z.EncJSONMarshal(x.MaxUnavailable) - } else { - z.EncFallback(x.MaxUnavailable) - } - } - } - } - if yyr574 || yy2arr574 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq574[1] { - if x.MaxSurge == nil { - r.EncodeNil() - } else { - yym579 := z.EncBinary() - _ = yym579 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { - } else if !yym579 && z.IsJSONHandle() { - z.EncJSONMarshal(x.MaxSurge) - } else { - z.EncFallback(x.MaxSurge) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq574[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("maxSurge")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.MaxSurge == nil { - r.EncodeNil() - } else { - yym580 := z.EncBinary() - _ = yym580 - if false { - } else if z.HasExtensions() && z.EncExt(x.MaxSurge) { - } else if !yym580 && z.IsJSONHandle() { - z.EncJSONMarshal(x.MaxSurge) - } else { - z.EncFallback(x.MaxSurge) - } - } - } - } - if yyr574 || yy2arr574 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *RollingUpdateDeployment) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym581 := z.DecBinary() - _ = yym581 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct582 := r.ContainerType() - if yyct582 == codecSelferValueTypeMap1234 { - yyl582 := r.ReadMapStart() - if yyl582 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl582, d) - } - } else if yyct582 == codecSelferValueTypeArray1234 { - yyl582 := r.ReadArrayStart() - if yyl582 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl582, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *RollingUpdateDeployment) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys583Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys583Slc - var yyhl583 bool = l >= 0 - for yyj583 := 0; ; yyj583++ { - if yyhl583 { - if yyj583 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys583Slc = r.DecodeBytes(yys583Slc, true, true) - yys583 := string(yys583Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys583 { - case "maxUnavailable": - if r.TryDecodeAsNil() { - if x.MaxUnavailable != nil { - x.MaxUnavailable = nil - } - } else { - if x.MaxUnavailable == nil { - x.MaxUnavailable = new(pkg5_intstr.IntOrString) - } - yym585 := z.DecBinary() - _ = yym585 - if false { - } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { - } else if !yym585 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.MaxUnavailable) - } else { - z.DecFallback(x.MaxUnavailable, false) - } - } - case "maxSurge": - if r.TryDecodeAsNil() { - if x.MaxSurge != nil { - x.MaxSurge = nil - } - } else { - if x.MaxSurge == nil { - x.MaxSurge = new(pkg5_intstr.IntOrString) - } - yym587 := z.DecBinary() - _ = yym587 - if false { - } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { - } else if !yym587 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.MaxSurge) - } else { - z.DecFallback(x.MaxSurge, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys583) - } // end switch yys583 - } // end for yyj583 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *RollingUpdateDeployment) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj588 int - var yyb588 bool - var yyhl588 bool = l >= 0 - yyj588++ - if yyhl588 { - yyb588 = yyj588 > l - } else { - yyb588 = r.CheckBreak() - } - if yyb588 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.MaxUnavailable != nil { - x.MaxUnavailable = nil - } - } else { - if x.MaxUnavailable == nil { - x.MaxUnavailable = new(pkg5_intstr.IntOrString) - } - yym590 := z.DecBinary() - _ = yym590 - if false { - } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { - } else if !yym590 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.MaxUnavailable) - } else { - z.DecFallback(x.MaxUnavailable, false) - } - } - yyj588++ - if yyhl588 { - yyb588 = yyj588 > l - } else { - yyb588 = r.CheckBreak() - } - if yyb588 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.MaxSurge != nil { - x.MaxSurge = nil - } - } else { - if x.MaxSurge == nil { - x.MaxSurge = new(pkg5_intstr.IntOrString) - } - yym592 := z.DecBinary() - _ = yym592 - if false { - } else if z.HasExtensions() && z.DecExt(x.MaxSurge) { - } else if !yym592 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.MaxSurge) - } else { - z.DecFallback(x.MaxSurge, false) - } - } - for { - yyj588++ - if yyhl588 { - yyb588 = yyj588 > l - } else { - yyb588 = r.CheckBreak() - } - if yyb588 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj588-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym593 := z.EncBinary() - _ = yym593 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep594 := !z.EncBinary() - yy2arr594 := z.EncBasicHandle().StructToArray - var yyq594 [6]bool - _, _, _ = yysep594, yyq594, yy2arr594 - const yyr594 bool = false - yyq594[0] = x.ObservedGeneration != 0 - yyq594[1] = x.Replicas != 0 - yyq594[2] = x.UpdatedReplicas != 0 - yyq594[3] = x.AvailableReplicas != 0 - yyq594[4] = x.UnavailableReplicas != 0 - yyq594[5] = len(x.Conditions) != 0 - var yynn594 int - if yyr594 || yy2arr594 { - r.EncodeArrayStart(6) - } else { - yynn594 = 0 - for _, b := range yyq594 { - if b { - yynn594++ - } - } - r.EncodeMapStart(yynn594) - yynn594 = 0 - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq594[0] { - yym596 := z.EncBinary() - _ = yym596 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq594[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym597 := z.EncBinary() - _ = yym597 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq594[1] { - yym599 := z.EncBinary() - _ = yym599 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq594[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("replicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym600 := z.EncBinary() - _ = yym600 - if false { - } else { - r.EncodeInt(int64(x.Replicas)) - } - } - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq594[2] { - yym602 := z.EncBinary() - _ = yym602 - if false { - } else { - r.EncodeInt(int64(x.UpdatedReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq594[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("updatedReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym603 := z.EncBinary() - _ = yym603 - if false { - } else { - r.EncodeInt(int64(x.UpdatedReplicas)) - } - } - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq594[3] { - yym605 := z.EncBinary() - _ = yym605 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq594[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym606 := z.EncBinary() - _ = yym606 - if false { - } else { - r.EncodeInt(int64(x.AvailableReplicas)) - } - } - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq594[4] { - yym608 := z.EncBinary() - _ = yym608 - if false { - } else { - r.EncodeInt(int64(x.UnavailableReplicas)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq594[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("unavailableReplicas")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym609 := z.EncBinary() - _ = yym609 - if false { - } else { - r.EncodeInt(int64(x.UnavailableReplicas)) - } - } - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq594[5] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym611 := z.EncBinary() - _ = yym611 - if false { - } else { - h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq594[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym612 := z.EncBinary() - _ = yym612 - if false { - } else { - h.encSliceDeploymentCondition(([]DeploymentCondition)(x.Conditions), e) - } - } - } - } - if yyr594 || yy2arr594 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym613 := z.DecBinary() - _ = yym613 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct614 := r.ContainerType() - if yyct614 == codecSelferValueTypeMap1234 { - yyl614 := r.ReadMapStart() - if yyl614 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl614, d) - } - } else if yyct614 == codecSelferValueTypeArray1234 { - yyl614 := r.ReadArrayStart() - if yyl614 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl614, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys615Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys615Slc - var yyhl615 bool = l >= 0 - for yyj615 := 0; ; yyj615++ { - if yyhl615 { - if yyj615 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys615Slc = r.DecodeBytes(yys615Slc, true, true) - yys615 := string(yys615Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys615 { - case "observedGeneration": - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - case "replicas": - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - case "updatedReplicas": - if r.TryDecodeAsNil() { - x.UpdatedReplicas = 0 - } else { - x.UpdatedReplicas = int32(r.DecodeInt(32)) - } - case "availableReplicas": - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - case "unavailableReplicas": - if r.TryDecodeAsNil() { - x.UnavailableReplicas = 0 - } else { - x.UnavailableReplicas = int32(r.DecodeInt(32)) - } - case "conditions": - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv621 := &x.Conditions - yym622 := z.DecBinary() - _ = yym622 - if false { - } else { - h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv621), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys615) - } // end switch yys615 - } // end for yyj615 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj623 int - var yyb623 bool - var yyhl623 bool = l >= 0 - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Replicas = 0 - } else { - x.Replicas = int32(r.DecodeInt(32)) - } - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UpdatedReplicas = 0 - } else { - x.UpdatedReplicas = int32(r.DecodeInt(32)) - } - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AvailableReplicas = 0 - } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) - } - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.UnavailableReplicas = 0 - } else { - x.UnavailableReplicas = int32(r.DecodeInt(32)) - } - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Conditions = nil - } else { - yyv629 := &x.Conditions - yym630 := z.DecBinary() - _ = yym630 - if false { - } else { - h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv629), d) - } - } - for { - yyj623++ - if yyhl623 { - yyb623 = yyj623 > l - } else { - yyb623 = r.CheckBreak() - } - if yyb623 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj623-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x DeploymentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym631 := z.EncBinary() - _ = yym631 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *DeploymentConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym632 := z.DecBinary() - _ = yym632 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *DeploymentCondition) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym633 := z.EncBinary() - _ = yym633 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep634 := !z.EncBinary() - yy2arr634 := z.EncBasicHandle().StructToArray - var yyq634 [6]bool - _, _, _ = yysep634, yyq634, yy2arr634 - const yyr634 bool = false - yyq634[2] = true - yyq634[3] = true - yyq634[4] = x.Reason != "" - yyq634[5] = x.Message != "" - var yynn634 int - if yyr634 || yy2arr634 { - r.EncodeArrayStart(6) - } else { - yynn634 = 2 - for _, b := range yyq634 { - if b { - yynn634++ - } - } - r.EncodeMapStart(yynn634) - yynn634 = 0 - } - if yyr634 || yy2arr634 { - 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 yyr634 || yy2arr634 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym637 := z.EncBinary() - _ = yym637 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym638 := z.EncBinary() - _ = yym638 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } - if yyr634 || yy2arr634 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq634[2] { - yy640 := &x.LastUpdateTime - yym641 := z.EncBinary() - _ = yym641 - if false { - } else if z.HasExtensions() && z.EncExt(yy640) { - } else if yym641 { - z.EncBinaryMarshal(yy640) - } else if !yym641 && z.IsJSONHandle() { - z.EncJSONMarshal(yy640) - } else { - z.EncFallback(yy640) - } - } else { - r.EncodeNil() - } - } else { - if yyq634[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy642 := &x.LastUpdateTime - yym643 := z.EncBinary() - _ = yym643 - if false { - } else if z.HasExtensions() && z.EncExt(yy642) { - } else if yym643 { - z.EncBinaryMarshal(yy642) - } else if !yym643 && z.IsJSONHandle() { - z.EncJSONMarshal(yy642) - } else { - z.EncFallback(yy642) - } - } - } - if yyr634 || yy2arr634 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq634[3] { - yy645 := &x.LastTransitionTime - yym646 := z.EncBinary() - _ = yym646 - if false { - } else if z.HasExtensions() && z.EncExt(yy645) { - } else if yym646 { - z.EncBinaryMarshal(yy645) - } else if !yym646 && z.IsJSONHandle() { - z.EncJSONMarshal(yy645) - } else { - z.EncFallback(yy645) - } - } else { - r.EncodeNil() - } - } else { - if yyq634[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy647 := &x.LastTransitionTime - yym648 := z.EncBinary() - _ = yym648 - if false { - } else if z.HasExtensions() && z.EncExt(yy647) { - } else if yym648 { - z.EncBinaryMarshal(yy647) - } else if !yym648 && z.IsJSONHandle() { - z.EncJSONMarshal(yy647) - } else { - z.EncFallback(yy647) - } - } - } - if yyr634 || yy2arr634 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq634[4] { - yym650 := z.EncBinary() - _ = yym650 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq634[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym651 := z.EncBinary() - _ = yym651 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) - } - } - } - if yyr634 || yy2arr634 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq634[5] { - yym653 := z.EncBinary() - _ = yym653 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq634[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym654 := z.EncBinary() - _ = yym654 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) - } - } - } - if yyr634 || yy2arr634 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentCondition) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym655 := z.DecBinary() - _ = yym655 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct656 := r.ContainerType() - if yyct656 == codecSelferValueTypeMap1234 { - yyl656 := r.ReadMapStart() - if yyl656 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl656, d) - } - } else if yyct656 == codecSelferValueTypeArray1234 { - yyl656 := r.ReadArrayStart() - if yyl656 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl656, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys657Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys657Slc - var yyhl657 bool = l >= 0 - for yyj657 := 0; ; yyj657++ { - if yyhl657 { - if yyj657 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys657Slc = r.DecodeBytes(yys657Slc, true, true) - yys657 := string(yys657Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys657 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) - } - case "lastUpdateTime": - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv660 := &x.LastUpdateTime - yym661 := z.DecBinary() - _ = yym661 - if false { - } else if z.HasExtensions() && z.DecExt(yyv660) { - } else if yym661 { - z.DecBinaryUnmarshal(yyv660) - } else if !yym661 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv660) - } else { - z.DecFallback(yyv660, false) - } - } - case "lastTransitionTime": - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv662 := &x.LastTransitionTime - yym663 := z.DecBinary() - _ = yym663 - if false { - } else if z.HasExtensions() && z.DecExt(yyv662) { - } else if yym663 { - z.DecBinaryUnmarshal(yyv662) - } else if !yym663 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv662) - } else { - z.DecFallback(yyv662, 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, yys657) - } // end switch yys657 - } // end for yyj657 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj666 int - var yyb666 bool - var yyhl666 bool = l >= 0 - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = DeploymentConditionType(r.DecodeString()) - } - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) - } - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastUpdateTime = pkg1_unversioned.Time{} - } else { - yyv669 := &x.LastUpdateTime - yym670 := z.DecBinary() - _ = yym670 - if false { - } else if z.HasExtensions() && z.DecExt(yyv669) { - } else if yym670 { - z.DecBinaryUnmarshal(yyv669) - } else if !yym670 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv669) - } else { - z.DecFallback(yyv669, false) - } - } - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} - } else { - yyv671 := &x.LastTransitionTime - yym672 := z.DecBinary() - _ = yym672 - if false { - } else if z.HasExtensions() && z.DecExt(yyv671) { - } else if yym672 { - z.DecBinaryUnmarshal(yyv671) - } else if !yym672 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv671) - } else { - z.DecFallback(yyv671, false) - } - } - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Reason = "" - } else { - x.Reason = string(r.DecodeString()) - } - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Message = "" - } else { - x.Message = string(r.DecodeString()) - } - for { - yyj666++ - if yyhl666 { - yyb666 = yyj666 > l - } else { - yyb666 = r.CheckBreak() - } - if yyb666 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj666-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DeploymentList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym675 := z.EncBinary() - _ = yym675 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep676 := !z.EncBinary() - yy2arr676 := z.EncBasicHandle().StructToArray - var yyq676 [4]bool - _, _, _ = yysep676, yyq676, yy2arr676 - const yyr676 bool = false - yyq676[0] = x.Kind != "" - yyq676[1] = x.APIVersion != "" - yyq676[2] = true - var yynn676 int - if yyr676 || yy2arr676 { - r.EncodeArrayStart(4) - } else { - yynn676 = 1 - for _, b := range yyq676 { - if b { - yynn676++ - } - } - r.EncodeMapStart(yynn676) - yynn676 = 0 - } - if yyr676 || yy2arr676 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq676[0] { - yym678 := z.EncBinary() - _ = yym678 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq676[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym679 := z.EncBinary() - _ = yym679 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr676 || yy2arr676 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq676[1] { - yym681 := z.EncBinary() - _ = yym681 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq676[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym682 := z.EncBinary() - _ = yym682 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr676 || yy2arr676 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq676[2] { - yy684 := &x.ListMeta - yym685 := z.EncBinary() - _ = yym685 - if false { - } else if z.HasExtensions() && z.EncExt(yy684) { - } else { - z.EncFallback(yy684) - } - } else { - r.EncodeNil() - } - } else { - if yyq676[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy686 := &x.ListMeta - yym687 := z.EncBinary() - _ = yym687 - if false { - } else if z.HasExtensions() && z.EncExt(yy686) { - } else { - z.EncFallback(yy686) - } - } - } - if yyr676 || yy2arr676 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym689 := z.EncBinary() - _ = yym689 - if false { - } else { - h.encSliceDeployment(([]Deployment)(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 { - yym690 := z.EncBinary() - _ = yym690 - if false { - } else { - h.encSliceDeployment(([]Deployment)(x.Items), e) - } - } - } - if yyr676 || yy2arr676 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DeploymentList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym691 := z.DecBinary() - _ = yym691 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct692 := r.ContainerType() - if yyct692 == codecSelferValueTypeMap1234 { - yyl692 := r.ReadMapStart() - if yyl692 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl692, d) - } - } else if yyct692 == codecSelferValueTypeArray1234 { - yyl692 := r.ReadArrayStart() - if yyl692 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl692, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DeploymentList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys693Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys693Slc - var yyhl693 bool = l >= 0 - for yyj693 := 0; ; yyj693++ { - if yyhl693 { - if yyj693 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys693Slc = r.DecodeBytes(yys693Slc, true, true) - yys693 := string(yys693Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys693 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv696 := &x.ListMeta - yym697 := z.DecBinary() - _ = yym697 - if false { - } else if z.HasExtensions() && z.DecExt(yyv696) { - } else { - z.DecFallback(yyv696, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv698 := &x.Items - yym699 := z.DecBinary() - _ = yym699 - if false { - } else { - h.decSliceDeployment((*[]Deployment)(yyv698), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys693) - } // end switch yys693 - } // end for yyj693 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DeploymentList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj700 int - var yyb700 bool - var yyhl700 bool = l >= 0 - yyj700++ - if yyhl700 { - yyb700 = yyj700 > l - } else { - yyb700 = r.CheckBreak() - } - if yyb700 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj700++ - if yyhl700 { - yyb700 = yyj700 > l - } else { - yyb700 = r.CheckBreak() - } - if yyb700 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj700++ - if yyhl700 { - yyb700 = yyj700 > l - } else { - yyb700 = r.CheckBreak() - } - if yyb700 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv703 := &x.ListMeta - yym704 := z.DecBinary() - _ = yym704 - if false { - } else if z.HasExtensions() && z.DecExt(yyv703) { - } else { - z.DecFallback(yyv703, false) - } - } - yyj700++ - if yyhl700 { - yyb700 = yyj700 > l - } else { - yyb700 = r.CheckBreak() - } - if yyb700 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv705 := &x.Items - yym706 := z.DecBinary() - _ = yym706 - if false { - } else { - h.decSliceDeployment((*[]Deployment)(yyv705), d) - } - } - for { - yyj700++ - if yyhl700 { - yyb700 = yyj700 > l - } else { - yyb700 = r.CheckBreak() - } - if yyb700 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj700-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DaemonSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym707 := z.EncBinary() - _ = yym707 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep708 := !z.EncBinary() - yy2arr708 := z.EncBasicHandle().StructToArray - var yyq708 [2]bool - _, _, _ = yysep708, yyq708, yy2arr708 - const yyr708 bool = false - yyq708[0] = x.Selector != nil - var yynn708 int - if yyr708 || yy2arr708 { - r.EncodeArrayStart(2) - } else { - yynn708 = 1 - for _, b := range yyq708 { - if b { - yynn708++ - } - } - r.EncodeMapStart(yynn708) - yynn708 = 0 - } - if yyr708 || yy2arr708 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq708[0] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym710 := z.EncBinary() - _ = yym710 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq708[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym711 := z.EncBinary() - _ = yym711 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr708 || yy2arr708 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy713 := &x.Template - yy713.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy714 := &x.Template - yy714.CodecEncodeSelf(e) - } - if yyr708 || yy2arr708 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DaemonSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym715 := z.DecBinary() - _ = yym715 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct716 := r.ContainerType() - if yyct716 == codecSelferValueTypeMap1234 { - yyl716 := r.ReadMapStart() - if yyl716 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl716, d) - } - } else if yyct716 == codecSelferValueTypeArray1234 { - yyl716 := r.ReadArrayStart() - if yyl716 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl716, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DaemonSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys717Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys717Slc - var yyhl717 bool = l >= 0 - for yyj717 := 0; ; yyj717++ { - if yyhl717 { - if yyj717 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys717Slc = r.DecodeBytes(yys717Slc, true, true) - yys717 := string(yys717Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys717 { - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym719 := z.DecBinary() - _ = yym719 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - case "template": - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv720 := &x.Template - yyv720.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys717) - } // end switch yys717 - } // end for yyj717 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DaemonSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj721 int - var yyb721 bool - var yyhl721 bool = l >= 0 - yyj721++ - if yyhl721 { - yyb721 = yyj721 > l - } else { - yyb721 = r.CheckBreak() - } - if yyb721 { - 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(pkg1_unversioned.LabelSelector) - } - yym723 := z.DecBinary() - _ = yym723 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - yyj721++ - if yyhl721 { - yyb721 = yyj721 > l - } else { - yyb721 = r.CheckBreak() - } - if yyb721 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} - } else { - yyv724 := &x.Template - yyv724.CodecDecodeSelf(d) - } - for { - yyj721++ - if yyhl721 { - yyb721 = yyj721 > l - } else { - yyb721 = r.CheckBreak() - } - if yyb721 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj721-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *DaemonSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym725 := z.EncBinary() - _ = yym725 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep726 := !z.EncBinary() - yy2arr726 := z.EncBasicHandle().StructToArray - var yyq726 [4]bool - _, _, _ = yysep726, yyq726, yy2arr726 - const yyr726 bool = false - var yynn726 int - if yyr726 || yy2arr726 { - r.EncodeArrayStart(4) - } else { - yynn726 = 4 - for _, b := range yyq726 { - if b { - yynn726++ - } - } - r.EncodeMapStart(yynn726) - yynn726 = 0 - } - if yyr726 || yy2arr726 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym728 := z.EncBinary() - _ = yym728 - if false { - } else { - r.EncodeInt(int64(x.CurrentNumberScheduled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentNumberScheduled")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym729 := z.EncBinary() - _ = yym729 - if false { - } else { - r.EncodeInt(int64(x.CurrentNumberScheduled)) - } - } - if yyr726 || yy2arr726 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym731 := z.EncBinary() - _ = yym731 - if false { - } else { - r.EncodeInt(int64(x.NumberMisscheduled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("numberMisscheduled")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym732 := z.EncBinary() - _ = yym732 - if false { - } else { - r.EncodeInt(int64(x.NumberMisscheduled)) - } - } - if yyr726 || yy2arr726 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym734 := z.EncBinary() - _ = yym734 - if false { - } else { - r.EncodeInt(int64(x.DesiredNumberScheduled)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("desiredNumberScheduled")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym735 := z.EncBinary() - _ = yym735 - if false { - } else { - r.EncodeInt(int64(x.DesiredNumberScheduled)) - } - } - if yyr726 || yy2arr726 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym737 := z.EncBinary() - _ = yym737 - if false { - } else { - r.EncodeInt(int64(x.NumberReady)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("numberReady")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym738 := z.EncBinary() - _ = yym738 - if false { - } else { - r.EncodeInt(int64(x.NumberReady)) - } - } - if yyr726 || yy2arr726 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *DaemonSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym739 := z.DecBinary() - _ = yym739 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct740 := r.ContainerType() - if yyct740 == codecSelferValueTypeMap1234 { - yyl740 := r.ReadMapStart() - if yyl740 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl740, d) - } - } else if yyct740 == codecSelferValueTypeArray1234 { - yyl740 := r.ReadArrayStart() - if yyl740 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl740, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *DaemonSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys741Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys741Slc - var yyhl741 bool = l >= 0 - for yyj741 := 0; ; yyj741++ { - if yyhl741 { - if yyj741 >= l { - break - } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ReadyReplicas = 0 + } else { + yyv27 := &x.ReadyReplicas + yym28 := z.DecBinary() + _ = yym28 + if false { } else { - if r.CheckBreak() { - break - } + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys741Slc = r.DecodeBytes(yys741Slc, true, true) - yys741 := string(yys741Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys741 { - case "currentNumberScheduled": - if r.TryDecodeAsNil() { - x.CurrentNumberScheduled = 0 - } else { - x.CurrentNumberScheduled = int32(r.DecodeInt(32)) - } - case "numberMisscheduled": - if r.TryDecodeAsNil() { - x.NumberMisscheduled = 0 - } else { - x.NumberMisscheduled = int32(r.DecodeInt(32)) - } - case "desiredNumberScheduled": - if r.TryDecodeAsNil() { - x.DesiredNumberScheduled = 0 - } else { - x.DesiredNumberScheduled = int32(r.DecodeInt(32)) - } - case "numberReady": - if r.TryDecodeAsNil() { - x.NumberReady = 0 - } else { - x.NumberReady = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys741) - } // end switch yys741 - } // end for yyj741 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *DaemonSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj746 int - var yyb746 bool - var yyhl746 bool = l >= 0 - yyj746++ - if yyhl746 { - yyb746 = yyj746 > l + } + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb746 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb746 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.CurrentNumberScheduled = 0 + x.AvailableReplicas = 0 } else { - x.CurrentNumberScheduled = int32(r.DecodeInt(32)) + yyv29 := &x.AvailableReplicas + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int32)(yyv29)) = int32(r.DecodeInt(32)) + } } - yyj746++ - if yyhl746 { - yyb746 = yyj746 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb746 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb746 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.NumberMisscheduled = 0 + x.UnavailableReplicas = 0 } else { - x.NumberMisscheduled = int32(r.DecodeInt(32)) + yyv31 := &x.UnavailableReplicas + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int32)(yyv31)) = int32(r.DecodeInt(32)) + } } - yyj746++ - if yyhl746 { - yyb746 = yyj746 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb746 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb746 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.DesiredNumberScheduled = 0 + x.Conditions = nil } else { - x.DesiredNumberScheduled = int32(r.DecodeInt(32)) + yyv33 := &x.Conditions + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + h.decSliceDeploymentCondition((*[]DeploymentCondition)(yyv33), d) + } } - yyj746++ - if yyhl746 { - yyb746 = yyj746 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb746 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb746 { + if yyb20 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.NumberReady = 0 + if x.CollisionCount != nil { + x.CollisionCount = nil + } } else { - x.NumberReady = int32(r.DecodeInt(32)) + if x.CollisionCount == nil { + x.CollisionCount = new(int64) + } + yym36 := z.DecBinary() + _ = yym36 + if false { + } else { + *((*int64)(x.CollisionCount)) = int64(r.DecodeInt(64)) + } } for { - yyj746++ - if yyhl746 { - yyb746 = yyj746 > l + yyj20++ + if yyhl20 { + yyb20 = yyj20 > l } else { - yyb746 = r.CheckBreak() + yyb20 = r.CheckBreak() } - if yyb746 { + if yyb20 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj746-1, "") + z.DecStructFieldNotFound(yyj20-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *DaemonSet) CodecEncodeSelf(e *codec1978.Encoder) { +func (x DeploymentConditionType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *DeploymentConditionType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *DeploymentCondition) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym751 := z.EncBinary() - _ = yym751 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep752 := !z.EncBinary() - yy2arr752 := z.EncBasicHandle().StructToArray - var yyq752 [5]bool - _, _, _ = yysep752, yyq752, yy2arr752 - const yyr752 bool = false - yyq752[0] = x.Kind != "" - yyq752[1] = x.APIVersion != "" - yyq752[2] = true - yyq752[3] = true - yyq752[4] = true - var yynn752 int - if yyr752 || yy2arr752 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = true + yyq2[4] = x.Reason != "" + yyq2[5] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) } else { - yynn752 = 0 - for _, b := range yyq752 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn752++ + yynn2++ } } - r.EncodeMapStart(yynn752) - yynn752 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + x.Type.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("type")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + x.Type.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yysf7 := &x.Status + yysf7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("status")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yysf8 := &x.Status + yysf8.CodecEncodeSelf(e) } - if yyr752 || yy2arr752 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq752[0] { - yym754 := z.EncBinary() - _ = yym754 + if yyq2[2] { + yy10 := &x.LastUpdateTime + yym11 := z.EncBinary() + _ = yym11 if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + z.EncFallback(yy10) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq752[0] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("lastUpdateTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym755 := z.EncBinary() - _ = yym755 + yy12 := &x.LastUpdateTime + yym13 := z.EncBinary() + _ = yym13 if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + z.EncFallback(yy12) } } } - if yyr752 || yy2arr752 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq752[1] { - yym757 := z.EncBinary() - _ = yym757 + if yyq2[3] { + yy15 := &x.LastTransitionTime + yym16 := z.EncBinary() + _ = yym16 if false { + } else if z.HasExtensions() && z.EncExt(yy15) { + } else if yym16 { + z.EncBinaryMarshal(yy15) + } else if !yym16 && z.IsJSONHandle() { + z.EncJSONMarshal(yy15) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + z.EncFallback(yy15) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq752[1] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym758 := z.EncBinary() - _ = yym758 + yy17 := &x.LastTransitionTime + yym18 := z.EncBinary() + _ = yym18 if false { + } else if z.HasExtensions() && z.EncExt(yy17) { + } else if yym18 { + z.EncBinaryMarshal(yy17) + } else if !yym18 && z.IsJSONHandle() { + z.EncJSONMarshal(yy17) } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + z.EncFallback(yy17) } } } - if yyr752 || yy2arr752 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq752[2] { - yy760 := &x.ObjectMeta - yy760.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq752[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy761 := &x.ObjectMeta - yy761.CodecEncodeSelf(e) - } - } - if yyr752 || yy2arr752 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq752[3] { - yy763 := &x.Spec - yy763.CodecEncodeSelf(e) + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq752[3] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) + r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy764 := &x.Spec - yy764.CodecEncodeSelf(e) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + } } } - if yyr752 || yy2arr752 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq752[4] { - yy766 := &x.Status - yy766.CodecEncodeSelf(e) + if yyq2[5] { + yym23 := z.EncBinary() + _ = yym23 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq752[4] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) + r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy767 := &x.Status - yy767.CodecEncodeSelf(e) + yym24 := z.EncBinary() + _ = yym24 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + } } } - if yyr752 || yy2arr752 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9062,29 +6432,29 @@ func (x *DaemonSet) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *DaemonSet) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym768 := z.DecBinary() - _ = yym768 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct769 := r.ContainerType() - if yyct769 == codecSelferValueTypeMap1234 { - yyl769 := r.ReadMapStart() - if yyl769 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl769, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct769 == codecSelferValueTypeArray1234 { - yyl769 := r.ReadArrayStart() - if yyl769 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl769, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9092,16 +6462,16 @@ func (x *DaemonSet) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *DaemonSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys770Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys770Slc - var yyhl770 bool = l >= 0 - for yyj770 := 0; ; yyj770++ { - if yyhl770 { - if yyj770 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9110,194 +6480,282 @@ func (x *DaemonSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys770Slc = r.DecodeBytes(yys770Slc, true, true) - yys770 := string(yys770Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys770 { - case "kind": + switch yys3 { + case "type": if r.TryDecodeAsNil() { - x.Kind = "" + x.Type = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } - case "apiVersion": + case "status": if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Status = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } - case "metadata": + case "lastUpdateTime": + if r.TryDecodeAsNil() { + x.LastUpdateTime = pkg1_v1.Time{} + } else { + yyv6 := &x.LastUpdateTime + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) + } else { + z.DecFallback(yyv6, false) + } + } + case "lastTransitionTime": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv773 := &x.ObjectMeta - yyv773.CodecDecodeSelf(d) + yyv8 := &x.LastTransitionTime + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) + } else { + z.DecFallback(yyv8, false) + } } - case "spec": + case "reason": if r.TryDecodeAsNil() { - x.Spec = DaemonSetSpec{} + x.Reason = "" } else { - yyv774 := &x.Spec - yyv774.CodecDecodeSelf(d) + yyv10 := &x.Reason + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } - case "status": + case "message": if r.TryDecodeAsNil() { - x.Status = DaemonSetStatus{} + x.Message = "" } else { - yyv775 := &x.Status - yyv775.CodecDecodeSelf(d) + yyv12 := &x.Message + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys770) - } // end switch yys770 - } // end for yyj770 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *DaemonSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj776 int - var yyb776 bool - var yyhl776 bool = l >= 0 - yyj776++ - if yyhl776 { - yyb776 = yyj776 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb776 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb776 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" + x.Type = "" } else { - x.Kind = string(r.DecodeString()) + yyv15 := &x.Type + yyv15.CodecDecodeSelf(d) } - yyj776++ - if yyhl776 { - yyb776 = yyj776 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb776 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb776 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Status = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv16 := &x.Status + yyv16.CodecDecodeSelf(d) } - yyj776++ - if yyhl776 { - yyb776 = yyj776 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb776 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb776 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.LastUpdateTime = pkg1_v1.Time{} } else { - yyv779 := &x.ObjectMeta - yyv779.CodecDecodeSelf(d) + yyv17 := &x.LastUpdateTime + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else if yym18 { + z.DecBinaryUnmarshal(yyv17) + } else if !yym18 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv17) + } else { + z.DecFallback(yyv17, false) + } } - yyj776++ - if yyhl776 { - yyb776 = yyj776 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb776 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb776 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Spec = DaemonSetSpec{} + x.LastTransitionTime = pkg1_v1.Time{} + } else { + yyv19 := &x.LastTransitionTime + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else if yym20 { + z.DecBinaryUnmarshal(yyv19) + } else if !yym20 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv19) + } else { + z.DecFallback(yyv19, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Reason = "" } else { - yyv780 := &x.Spec - yyv780.CodecDecodeSelf(d) + yyv21 := &x.Reason + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj776++ - if yyhl776 { - yyb776 = yyj776 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb776 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb776 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Status = DaemonSetStatus{} + x.Message = "" } else { - yyv781 := &x.Status - yyv781.CodecDecodeSelf(d) + yyv23 := &x.Message + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*string)(yyv23)) = r.DecodeString() + } } for { - yyj776++ - if yyhl776 { - yyb776 = yyj776 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb776 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb776 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj776-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DeploymentList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym782 := z.EncBinary() - _ = yym782 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep783 := !z.EncBinary() - yy2arr783 := z.EncBasicHandle().StructToArray - var yyq783 [4]bool - _, _, _ = yysep783, yyq783, yy2arr783 - const yyr783 bool = false - yyq783[0] = x.Kind != "" - yyq783[1] = x.APIVersion != "" - yyq783[2] = true - var yynn783 int - if yyr783 || yy2arr783 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn783 = 1 - for _, b := range yyq783 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn783++ + yynn2++ } } - r.EncodeMapStart(yynn783) - yynn783 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr783 || yy2arr783 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq783[0] { - yym785 := z.EncBinary() - _ = yym785 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -9306,23 +6764,23 @@ func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq783[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym786 := z.EncBinary() - _ = yym786 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr783 || yy2arr783 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq783[1] { - yym788 := z.EncBinary() - _ = yym788 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -9331,57 +6789,57 @@ func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq783[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym789 := z.EncBinary() - _ = yym789 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr783 || yy2arr783 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq783[2] { - yy791 := &x.ListMeta - yym792 := z.EncBinary() - _ = yym792 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy791) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy791) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq783[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy793 := &x.ListMeta - yym794 := z.EncBinary() - _ = yym794 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy793) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy793) + z.EncFallback(yy12) } } } - if yyr783 || yy2arr783 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym796 := z.EncBinary() - _ = yym796 + yym15 := z.EncBinary() + _ = yym15 if false { } else { - h.encSliceDaemonSet(([]DaemonSet)(x.Items), e) + h.encSliceDeployment(([]Deployment)(x.Items), e) } } } else { @@ -9391,15 +6849,15 @@ func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym797 := z.EncBinary() - _ = yym797 + yym16 := z.EncBinary() + _ = yym16 if false { } else { - h.encSliceDaemonSet(([]DaemonSet)(x.Items), e) + h.encSliceDeployment(([]Deployment)(x.Items), e) } } } - if yyr783 || yy2arr783 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9408,29 +6866,29 @@ func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *DaemonSetList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DeploymentList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym798 := z.DecBinary() - _ = yym798 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct799 := r.ContainerType() - if yyct799 == codecSelferValueTypeMap1234 { - yyl799 := r.ReadMapStart() - if yyl799 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl799, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct799 == codecSelferValueTypeArray1234 { - yyl799 := r.ReadArrayStart() - if yyl799 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl799, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9438,16 +6896,16 @@ func (x *DaemonSetList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *DaemonSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DeploymentList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys800Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys800Slc - var yyhl800 bool = l >= 0 - for yyj800 := 0; ; yyj800++ { - if yyhl800 { - if yyj800 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9456,68 +6914,80 @@ func (x *DaemonSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys800Slc = r.DecodeBytes(yys800Slc, true, true) - yys800 := string(yys800Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys800 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv803 := &x.ListMeta - yym804 := z.DecBinary() - _ = yym804 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv803) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv803, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv805 := &x.Items - yym806 := z.DecBinary() - _ = yym806 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceDaemonSet((*[]DaemonSet)(yyv805), d) + h.decSliceDeployment((*[]Deployment)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys800) - } // end switch yys800 - } // end for yyj800 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *DaemonSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DeploymentList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj807 int - var yyb807 bool - var yyhl807 bool = l >= 0 - yyj807++ - if yyhl807 { - yyb807 = yyj807 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb807 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb807 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9525,15 +6995,21 @@ func (x *DaemonSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj807++ - if yyhl807 { - yyb807 = yyj807 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb807 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb807 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9541,38 +7017,44 @@ func (x *DaemonSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj807++ - if yyhl807 { - yyb807 = yyj807 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb807 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb807 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv810 := &x.ListMeta - yym811 := z.DecBinary() - _ = yym811 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv810) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv810, false) + z.DecFallback(yyv17, false) } } - yyj807++ - if yyhl807 { - yyb807 = yyj807 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb807 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb807 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -9580,170 +7062,344 @@ func (x *DaemonSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv812 := &x.Items - yym813 := z.DecBinary() - _ = yym813 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceDaemonSet((*[]DaemonSet)(yyv812), d) + h.decSliceDeployment((*[]Deployment)(yyv19), d) } } for { - yyj807++ - if yyhl807 { - yyb807 = yyj807 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb807 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb807 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj807-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *ThirdPartyResourceDataList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DaemonSetUpdateStrategy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym814 := z.EncBinary() - _ = yym814 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep815 := !z.EncBinary() - yy2arr815 := z.EncBasicHandle().StructToArray - var yyq815 [4]bool - _, _, _ = yysep815, yyq815, yy2arr815 - const yyr815 bool = false - yyq815[0] = x.Kind != "" - yyq815[1] = x.APIVersion != "" - yyq815[2] = true - var yynn815 int - if yyr815 || yy2arr815 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Type != "" + yyq2[1] = x.RollingUpdate != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) } else { - yynn815 = 1 - for _, b := range yyq815 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn815++ + yynn2++ } } - r.EncodeMapStart(yynn815) - yynn815 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr815 || yy2arr815 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq815[0] { - yym817 := z.EncBinary() - _ = yym817 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } + if yyq2[0] { + x.Type.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq815[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("type")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym818 := z.EncBinary() - _ = yym818 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } + x.Type.CodecEncodeSelf(e) } } - if yyr815 || yy2arr815 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq815[1] { - yym820 := z.EncBinary() - _ = yym820 - if false { + if yyq2[1] { + if x.RollingUpdate == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + x.RollingUpdate.CodecEncodeSelf(e) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq815[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("rollingUpdate")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym821 := z.EncBinary() - _ = yym821 - if false { + if x.RollingUpdate == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + x.RollingUpdate.CodecEncodeSelf(e) } } } - if yyr815 || yy2arr815 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq815[2] { - yy823 := &x.ListMeta - yym824 := z.EncBinary() - _ = yym824 - if false { - } else if z.HasExtensions() && z.EncExt(yy823) { - } else { - z.EncFallback(yy823) - } - } else { - r.EncodeNil() + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *DaemonSetUpdateStrategy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *DaemonSetUpdateStrategy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "type": + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) + } + case "rollingUpdate": + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil } } else { - if yyq815[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy825 := &x.ListMeta - yym826 := z.EncBinary() - _ = yym826 - if false { - } else if z.HasExtensions() && z.EncExt(yy825) { - } else { - z.EncFallback(yy825) + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateDaemonSet) + } + x.RollingUpdate.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *DaemonSetUpdateStrategy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Type = "" + } else { + yyv7 := &x.Type + yyv7.CodecDecodeSelf(d) + } + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.RollingUpdate != nil { + x.RollingUpdate = nil + } + } else { + if x.RollingUpdate == nil { + x.RollingUpdate = new(RollingUpdateDaemonSet) + } + x.RollingUpdate.CodecDecodeSelf(d) + } + for { + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l + } else { + yyb6 = r.CheckBreak() + } + if yyb6 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj6-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x DaemonSetUpdateStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x)) + } +} + +func (x *DaemonSetUpdateStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + *((*string)(x)) = r.DecodeString() + } +} + +func (x *RollingUpdateDaemonSet) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.MaxUnavailable != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(1) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ } } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr815 || yy2arr815 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym828 := z.EncBinary() - _ = yym828 - if false { + if yyq2[0] { + if x.MaxUnavailable == nil { + r.EncodeNil() } else { - h.encSliceThirdPartyResourceData(([]ThirdPartyResourceData)(x.Items), e) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym4 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("items")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Items == nil { - r.EncodeNil() } else { - yym829 := z.EncBinary() - _ = yym829 - if false { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.MaxUnavailable == nil { + r.EncodeNil() } else { - h.encSliceThirdPartyResourceData(([]ThirdPartyResourceData)(x.Items), e) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym5 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } } } } - if yyr815 || yy2arr815 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -9752,29 +7408,29 @@ func (x *ThirdPartyResourceDataList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *ThirdPartyResourceDataList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *RollingUpdateDaemonSet) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym830 := z.DecBinary() - _ = yym830 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct831 := r.ContainerType() - if yyct831 == codecSelferValueTypeMap1234 { - yyl831 := r.ReadMapStart() - if yyl831 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl831, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct831 == codecSelferValueTypeArray1234 { - yyl831 := r.ReadArrayStart() - if yyl831 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl831, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -9782,16 +7438,16 @@ func (x *ThirdPartyResourceDataList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *ThirdPartyResourceDataList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *RollingUpdateDaemonSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys832Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys832Slc - var yyhl832 bool = l >= 0 - for yyj832 := 0; ; yyj832++ { - if yyhl832 { - if yyj832 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -9800,291 +7456,272 @@ func (x *ThirdPartyResourceDataList) codecDecodeSelfFromMap(l int, d *codec1978. } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys832Slc = r.DecodeBytes(yys832Slc, true, true) - yys832 := string(yys832Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys832 { - 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": + switch yys3 { + case "maxUnavailable": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv835 := &x.ListMeta - yym836 := z.DecBinary() - _ = yym836 - if false { - } else if z.HasExtensions() && z.DecExt(yyv835) { - } else { - z.DecFallback(yyv835, false) + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil } else { - yyv837 := &x.Items - yym838 := z.DecBinary() - _ = yym838 + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg5_intstr.IntOrString) + } + yym5 := z.DecBinary() + _ = yym5 if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) } else { - h.decSliceThirdPartyResourceData((*[]ThirdPartyResourceData)(yyv837), d) + z.DecFallback(x.MaxUnavailable, false) } } default: - z.DecStructFieldNotFound(-1, yys832) - } // end switch yys832 - } // end for yyj832 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *ThirdPartyResourceDataList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *RollingUpdateDaemonSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj839 int - var yyb839 bool - var yyhl839 bool = l >= 0 - yyj839++ - if yyhl839 { - yyb839 = yyj839 > l - } else { - yyb839 = r.CheckBreak() - } - if yyb839 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj839++ - if yyhl839 { - yyb839 = yyj839 > l - } else { - yyb839 = r.CheckBreak() - } - if yyb839 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - x.APIVersion = string(r.DecodeString()) + yyb6 = r.CheckBreak() } - yyj839++ - if yyhl839 { - yyb839 = yyj839 > l - } else { - yyb839 = r.CheckBreak() - } - if yyb839 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv842 := &x.ListMeta - yym843 := z.DecBinary() - _ = yym843 - if false { - } else if z.HasExtensions() && z.DecExt(yyv842) { - } else { - z.DecFallback(yyv842, false) + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil } - } - yyj839++ - if yyhl839 { - yyb839 = yyj839 > l - } else { - yyb839 = r.CheckBreak() - } - if yyb839 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil } else { - yyv844 := &x.Items - yym845 := z.DecBinary() - _ = yym845 + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg5_intstr.IntOrString) + } + yym8 := z.DecBinary() + _ = yym8 if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym8 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) } else { - h.decSliceThirdPartyResourceData((*[]ThirdPartyResourceData)(yyv844), d) + z.DecFallback(x.MaxUnavailable, false) } } for { - yyj839++ - if yyhl839 { - yyb839 = yyj839 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb839 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb839 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj839-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DaemonSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym846 := z.EncBinary() - _ = yym846 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep847 := !z.EncBinary() - yy2arr847 := z.EncBasicHandle().StructToArray - var yyq847 [5]bool - _, _, _ = yysep847, yyq847, yy2arr847 - const yyr847 bool = false - yyq847[0] = x.Kind != "" - yyq847[1] = x.APIVersion != "" - yyq847[2] = true - yyq847[3] = true - yyq847[4] = true - var yynn847 int - if yyr847 || yy2arr847 { - r.EncodeArrayStart(5) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Selector != nil + yyq2[2] = true + yyq2[3] = x.MinReadySeconds != 0 + yyq2[4] = x.TemplateGeneration != 0 + yyq2[5] = x.RevisionHistoryLimit != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(6) } else { - yynn847 = 0 - for _, b := range yyq847 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn847++ + yynn2++ } } - r.EncodeMapStart(yynn847) - yynn847 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr847 || yy2arr847 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq847[0] { - yym849 := z.EncBinary() - _ = yym849 - if false { + if yyq2[0] { + if x.Selector == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq847[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym850 := z.EncBinary() - _ = yym850 - if false { + if x.Selector == nil { + r.EncodeNil() } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.Selector) { + } else { + z.EncFallback(x.Selector) + } } } } - if yyr847 || yy2arr847 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq847[1] { - yym852 := z.EncBinary() - _ = yym852 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } + yy7 := &x.Template + yy7.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("template")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy9 := &x.Template + yy9.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy12 := &x.UpdateStrategy + yy12.CodecEncodeSelf(e) } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq847[1] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("updateStrategy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym853 := z.EncBinary() - _ = yym853 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } + yy14 := &x.UpdateStrategy + yy14.CodecEncodeSelf(e) } } - if yyr847 || yy2arr847 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq847[2] { - yy855 := &x.ObjectMeta - yy855.CodecEncodeSelf(e) + if yyq2[3] { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + r.EncodeInt(int64(x.MinReadySeconds)) + } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq847[2] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) + r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy856 := &x.ObjectMeta - yy856.CodecEncodeSelf(e) + yym18 := z.EncBinary() + _ = yym18 + if false { + } else { + r.EncodeInt(int64(x.MinReadySeconds)) + } } } - if yyr847 || yy2arr847 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq847[3] { - yy858 := &x.Spec - yy858.CodecEncodeSelf(e) + if yyq2[4] { + yym20 := z.EncBinary() + _ = yym20 + if false { + } else { + r.EncodeInt(int64(x.TemplateGeneration)) + } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq847[3] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) + r.EncodeString(codecSelferC_UTF81234, string("templateGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy859 := &x.Spec - yy859.CodecEncodeSelf(e) + yym21 := z.EncBinary() + _ = yym21 + if false { + } else { + r.EncodeInt(int64(x.TemplateGeneration)) + } } } - if yyr847 || yy2arr847 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq847[4] { - yy861 := &x.Status - yy861.CodecEncodeSelf(e) + if yyq2[5] { + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy23 := *x.RevisionHistoryLimit + yym24 := z.EncBinary() + _ = yym24 + if false { + } else { + r.EncodeInt(int64(yy23)) + } + } } else { r.EncodeNil() } } else { - if yyq847[4] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) + r.EncodeString(codecSelferC_UTF81234, string("revisionHistoryLimit")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy862 := &x.Status - yy862.CodecEncodeSelf(e) + if x.RevisionHistoryLimit == nil { + r.EncodeNil() + } else { + yy25 := *x.RevisionHistoryLimit + yym26 := z.EncBinary() + _ = yym26 + if false { + } else { + r.EncodeInt(int64(yy25)) + } + } } } - if yyr847 || yy2arr847 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -10093,29 +7730,29 @@ func (x *Job) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DaemonSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym863 := z.DecBinary() - _ = yym863 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct864 := r.ContainerType() - if yyct864 == codecSelferValueTypeMap1234 { - yyl864 := r.ReadMapStart() - if yyl864 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl864, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct864 == codecSelferValueTypeArray1234 { - yyl864 := r.ReadArrayStart() - if yyl864 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl864, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -10123,16 +7760,16 @@ func (x *Job) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DaemonSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys865Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys865Slc - var yyhl865 bool = l >= 0 - for yyj865 := 0; ; yyj865++ { - if yyhl865 { - if yyj865 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -10141,296 +7778,489 @@ func (x *Job) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys865Slc = r.DecodeBytes(yys865Slc, true, true) - yys865 := string(yys865Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys865 { - case "kind": + switch yys3 { + case "selector": if r.TryDecodeAsNil() { - x.Kind = "" + if x.Selector != nil { + x.Selector = nil + } } else { - x.Kind = string(r.DecodeString()) + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } } - case "apiVersion": + case "template": if r.TryDecodeAsNil() { - x.APIVersion = "" + x.Template = pkg4_v1.PodTemplateSpec{} } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.Template + yyv6.CodecDecodeSelf(d) } - case "metadata": + case "updateStrategy": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.UpdateStrategy = DaemonSetUpdateStrategy{} } else { - yyv868 := &x.ObjectMeta - yyv868.CodecDecodeSelf(d) + yyv7 := &x.UpdateStrategy + yyv7.CodecDecodeSelf(d) } - case "spec": + case "minReadySeconds": if r.TryDecodeAsNil() { - x.Spec = JobSpec{} + x.MinReadySeconds = 0 } else { - yyv869 := &x.Spec - yyv869.CodecDecodeSelf(d) + yyv8 := &x.MinReadySeconds + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } - case "status": + case "templateGeneration": + if r.TryDecodeAsNil() { + x.TemplateGeneration = 0 + } else { + yyv10 := &x.TemplateGeneration + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int64)(yyv10)) = int64(r.DecodeInt(64)) + } + } + case "revisionHistoryLimit": if r.TryDecodeAsNil() { - x.Status = JobStatus{} + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } } else { - yyv870 := &x.Status - yyv870.CodecDecodeSelf(d) + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys865) - } // end switch yys865 - } // end for yyj865 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *Job) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DaemonSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj871 int - var yyb871 bool - var yyhl871 bool = l >= 0 - yyj871++ - if yyhl871 { - yyb871 = yyj871 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb871 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb871 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" + if x.Selector != nil { + x.Selector = nil + } + } else { + if x.Selector == nil { + x.Selector = new(pkg1_v1.LabelSelector) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else { + z.DecFallback(x.Selector, false) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Template = pkg4_v1.PodTemplateSpec{} } else { - x.Kind = string(r.DecodeString()) + yyv17 := &x.Template + yyv17.CodecDecodeSelf(d) } - yyj871++ - if yyhl871 { - yyb871 = yyj871 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb871 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb871 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + x.UpdateStrategy = DaemonSetUpdateStrategy{} } else { - x.APIVersion = string(r.DecodeString()) + yyv18 := &x.UpdateStrategy + yyv18.CodecDecodeSelf(d) } - yyj871++ - if yyhl871 { - yyb871 = yyj871 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb871 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb871 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.MinReadySeconds = 0 } else { - yyv874 := &x.ObjectMeta - yyv874.CodecDecodeSelf(d) + yyv19 := &x.MinReadySeconds + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int32)(yyv19)) = int32(r.DecodeInt(32)) + } } - yyj871++ - if yyhl871 { - yyb871 = yyj871 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb871 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb871 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Spec = JobSpec{} + x.TemplateGeneration = 0 } else { - yyv875 := &x.Spec - yyv875.CodecDecodeSelf(d) + yyv21 := &x.TemplateGeneration + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int64)(yyv21)) = int64(r.DecodeInt(64)) + } } - yyj871++ - if yyhl871 { - yyb871 = yyj871 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb871 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb871 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Status = JobStatus{} + if x.RevisionHistoryLimit != nil { + x.RevisionHistoryLimit = nil + } } else { - yyv876 := &x.Status - yyv876.CodecDecodeSelf(d) + if x.RevisionHistoryLimit == nil { + x.RevisionHistoryLimit = new(int32) + } + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(x.RevisionHistoryLimit)) = int32(r.DecodeInt(32)) + } } for { - yyj871++ - if yyhl871 { - yyb871 = yyj871 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb871 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb871 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj871-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DaemonSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym877 := z.EncBinary() - _ = yym877 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep878 := !z.EncBinary() - yy2arr878 := z.EncBasicHandle().StructToArray - var yyq878 [4]bool - _, _, _ = yysep878, yyq878, yy2arr878 - const yyr878 bool = false - yyq878[0] = x.Kind != "" - yyq878[1] = x.APIVersion != "" - yyq878[2] = true - var yynn878 int - if yyr878 || yy2arr878 { - r.EncodeArrayStart(4) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [9]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[4] = x.ObservedGeneration != 0 + yyq2[5] = x.UpdatedNumberScheduled != 0 + yyq2[6] = x.NumberAvailable != 0 + yyq2[7] = x.NumberUnavailable != 0 + yyq2[8] = x.CollisionCount != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(9) } else { - yynn878 = 1 - for _, b := range yyq878 { + yynn2 = 4 + for _, b := range yyq2 { if b { - yynn878++ + yynn2++ } } - r.EncodeMapStart(yynn878) - yynn878 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeInt(int64(x.CurrentNumberScheduled)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("currentNumberScheduled")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeInt(int64(x.CurrentNumberScheduled)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeInt(int64(x.NumberMisscheduled)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("numberMisscheduled")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeInt(int64(x.NumberMisscheduled)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeInt(int64(x.DesiredNumberScheduled)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("desiredNumberScheduled")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeInt(int64(x.DesiredNumberScheduled)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeInt(int64(x.NumberReady)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("numberReady")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeInt(int64(x.NumberReady)) + } } - if yyr878 || yy2arr878 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq878[0] { - yym880 := z.EncBinary() - _ = yym880 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + r.EncodeInt(int64(x.ObservedGeneration)) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeInt(0) } } else { - if yyq878[0] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) + r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym881 := z.EncBinary() - _ = yym881 + yym17 := z.EncBinary() + _ = yym17 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + r.EncodeInt(int64(x.ObservedGeneration)) } } } - if yyr878 || yy2arr878 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq878[1] { - yym883 := z.EncBinary() - _ = yym883 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + r.EncodeInt(int64(x.UpdatedNumberScheduled)) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeInt(0) } } else { - if yyq878[1] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + r.EncodeString(codecSelferC_UTF81234, string("updatedNumberScheduled")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym884 := z.EncBinary() - _ = yym884 + yym20 := z.EncBinary() + _ = yym20 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + r.EncodeInt(int64(x.UpdatedNumberScheduled)) } } } - if yyr878 || yy2arr878 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq878[2] { - yy886 := &x.ListMeta - yym887 := z.EncBinary() - _ = yym887 + if yyq2[6] { + yym22 := z.EncBinary() + _ = yym22 if false { - } else if z.HasExtensions() && z.EncExt(yy886) { } else { - z.EncFallback(yy886) + r.EncodeInt(int64(x.NumberAvailable)) } } else { - r.EncodeNil() + r.EncodeInt(0) } } else { - if yyq878[2] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) + r.EncodeString(codecSelferC_UTF81234, string("numberAvailable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy888 := &x.ListMeta - yym889 := z.EncBinary() - _ = yym889 + yym23 := z.EncBinary() + _ = yym23 if false { - } else if z.HasExtensions() && z.EncExt(yy888) { } else { - z.EncFallback(yy888) + r.EncodeInt(int64(x.NumberAvailable)) } } } - if yyr878 || yy2arr878 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym891 := z.EncBinary() - _ = yym891 + if yyq2[7] { + yym25 := z.EncBinary() + _ = yym25 if false { } else { - h.encSliceJob(([]Job)(x.Items), e) + r.EncodeInt(int64(x.NumberUnavailable)) } + } else { + r.EncodeInt(0) } } else { - 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 yyq2[7] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("numberUnavailable")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym26 := z.EncBinary() + _ = yym26 if false { } else { - h.encSliceJob(([]Job)(x.Items), e) + r.EncodeInt(int64(x.NumberUnavailable)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[8] { + if x.CollisionCount == nil { + r.EncodeNil() + } else { + yy28 := *x.CollisionCount + yym29 := z.EncBinary() + _ = yym29 + if false { + } else { + r.EncodeInt(int64(yy28)) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[8] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("collisionCount")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.CollisionCount == nil { + r.EncodeNil() + } else { + yy30 := *x.CollisionCount + yym31 := z.EncBinary() + _ = yym31 + if false { + } else { + r.EncodeInt(int64(yy30)) + } } } } - if yyr878 || yy2arr878 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -10439,29 +8269,29 @@ func (x *JobList) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *JobList) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DaemonSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym893 := z.DecBinary() - _ = yym893 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct894 := r.ContainerType() - if yyct894 == codecSelferValueTypeMap1234 { - yyl894 := r.ReadMapStart() - if yyl894 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl894, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct894 == codecSelferValueTypeArray1234 { - yyl894 := r.ReadArrayStart() - if yyl894 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl894, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -10469,16 +8299,16 @@ func (x *JobList) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *JobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DaemonSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys895Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys895Slc - var yyhl895 bool = l >= 0 - for yyj895 := 0; ; yyj895++ { - if yyhl895 { - if yyj895 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -10487,376 +8317,503 @@ func (x *JobList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys895Slc = r.DecodeBytes(yys895Slc, true, true) - yys895 := string(yys895Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys895 { - case "kind": + switch yys3 { + case "currentNumberScheduled": if r.TryDecodeAsNil() { - x.Kind = "" + x.CurrentNumberScheduled = 0 } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.CurrentNumberScheduled + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } - case "apiVersion": + case "numberMisscheduled": if r.TryDecodeAsNil() { - x.APIVersion = "" + x.NumberMisscheduled = 0 } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.NumberMisscheduled + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } - case "metadata": + case "desiredNumberScheduled": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.DesiredNumberScheduled = 0 } else { - yyv898 := &x.ListMeta - yym899 := z.DecBinary() - _ = yym899 + yyv8 := &x.DesiredNumberScheduled + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv898) { } else { - z.DecFallback(yyv898, false) + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) } } - case "items": + case "numberReady": if r.TryDecodeAsNil() { - x.Items = nil + x.NumberReady = 0 + } else { + yyv10 := &x.NumberReady + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } + } + case "observedGeneration": + if r.TryDecodeAsNil() { + x.ObservedGeneration = 0 + } else { + yyv12 := &x.ObservedGeneration + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } + } + case "updatedNumberScheduled": + if r.TryDecodeAsNil() { + x.UpdatedNumberScheduled = 0 + } else { + yyv14 := &x.UpdatedNumberScheduled + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } + } + case "numberAvailable": + if r.TryDecodeAsNil() { + x.NumberAvailable = 0 + } else { + yyv16 := &x.NumberAvailable + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*int32)(yyv16)) = int32(r.DecodeInt(32)) + } + } + case "numberUnavailable": + if r.TryDecodeAsNil() { + x.NumberUnavailable = 0 + } else { + yyv18 := &x.NumberUnavailable + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*int32)(yyv18)) = int32(r.DecodeInt(32)) + } + } + case "collisionCount": + if r.TryDecodeAsNil() { + if x.CollisionCount != nil { + x.CollisionCount = nil + } } else { - yyv900 := &x.Items - yym901 := z.DecBinary() - _ = yym901 + if x.CollisionCount == nil { + x.CollisionCount = new(int64) + } + yym21 := z.DecBinary() + _ = yym21 if false { } else { - h.decSliceJob((*[]Job)(yyv900), d) + *((*int64)(x.CollisionCount)) = int64(r.DecodeInt(64)) } } default: - z.DecStructFieldNotFound(-1, yys895) - } // end switch yys895 - } // end for yyj895 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *JobList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DaemonSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj902 int - var yyb902 bool - var yyhl902 bool = l >= 0 - yyj902++ - if yyhl902 { - yyb902 = yyj902 > l + var yyj22 int + var yyb22 bool + var yyhl22 bool = l >= 0 + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.CurrentNumberScheduled = 0 + } else { + yyv23 := &x.CurrentNumberScheduled + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.NumberMisscheduled = 0 + } else { + yyv25 := &x.NumberMisscheduled + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.DesiredNumberScheduled = 0 + } else { + yyv27 := &x.DesiredNumberScheduled + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.NumberReady = 0 + } else { + yyv29 := &x.NumberReady + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*int32)(yyv29)) = int32(r.DecodeInt(32)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb902 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb902 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Kind = "" + x.ObservedGeneration = 0 } else { - x.Kind = string(r.DecodeString()) + yyv31 := &x.ObservedGeneration + yym32 := z.DecBinary() + _ = yym32 + if false { + } else { + *((*int64)(yyv31)) = int64(r.DecodeInt(64)) + } } - yyj902++ - if yyhl902 { - yyb902 = yyj902 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb902 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb902 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.APIVersion = "" + x.UpdatedNumberScheduled = 0 } else { - x.APIVersion = string(r.DecodeString()) + yyv33 := &x.UpdatedNumberScheduled + yym34 := z.DecBinary() + _ = yym34 + if false { + } else { + *((*int32)(yyv33)) = int32(r.DecodeInt(32)) + } } - yyj902++ - if yyhl902 { - yyb902 = yyj902 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb902 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb902 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.NumberAvailable = 0 } else { - yyv905 := &x.ListMeta - yym906 := z.DecBinary() - _ = yym906 + yyv35 := &x.NumberAvailable + yym36 := z.DecBinary() + _ = yym36 if false { - } else if z.HasExtensions() && z.DecExt(yyv905) { } else { - z.DecFallback(yyv905, false) + *((*int32)(yyv35)) = int32(r.DecodeInt(32)) } } - yyj902++ - if yyhl902 { - yyb902 = yyj902 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb902 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb902 { + if yyb22 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Items = nil + x.NumberUnavailable = 0 + } else { + yyv37 := &x.NumberUnavailable + yym38 := z.DecBinary() + _ = yym38 + if false { + } else { + *((*int32)(yyv37)) = int32(r.DecodeInt(32)) + } + } + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l + } else { + yyb22 = r.CheckBreak() + } + if yyb22 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.CollisionCount != nil { + x.CollisionCount = nil + } } else { - yyv907 := &x.Items - yym908 := z.DecBinary() - _ = yym908 + if x.CollisionCount == nil { + x.CollisionCount = new(int64) + } + yym40 := z.DecBinary() + _ = yym40 if false { } else { - h.decSliceJob((*[]Job)(yyv907), d) + *((*int64)(x.CollisionCount)) = int64(r.DecodeInt(64)) } } for { - yyj902++ - if yyhl902 { - yyb902 = yyj902 > l + yyj22++ + if yyhl22 { + yyb22 = yyj22 > l } else { - yyb902 = r.CheckBreak() + yyb22 = r.CheckBreak() } - if yyb902 { + if yyb22 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj902-1, "") + z.DecStructFieldNotFound(yyj22-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *DaemonSet) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym909 := z.EncBinary() - _ = yym909 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep910 := !z.EncBinary() - yy2arr910 := z.EncBasicHandle().StructToArray - var yyq910 [6]bool - _, _, _ = yysep910, yyq910, yy2arr910 - const yyr910 bool = false - yyq910[0] = x.Parallelism != nil - yyq910[1] = x.Completions != nil - yyq910[2] = x.ActiveDeadlineSeconds != nil - yyq910[3] = x.Selector != nil - yyq910[4] = x.AutoSelector != nil - var yynn910 int - if yyr910 || yy2arr910 { - r.EncodeArrayStart(6) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) } else { - yynn910 = 1 - for _, b := range yyq910 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn910++ + yynn2++ } } - r.EncodeMapStart(yynn910) - yynn910 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr910 || yy2arr910 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq910[0] { - if x.Parallelism == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - yy912 := *x.Parallelism - yym913 := z.EncBinary() - _ = yym913 - if false { - } else { - r.EncodeInt(int64(yy912)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq910[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("parallelism")) + r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Parallelism == nil { - r.EncodeNil() + yym5 := z.EncBinary() + _ = yym5 + if false { } else { - yy914 := *x.Parallelism - yym915 := z.EncBinary() - _ = yym915 - if false { - } else { - r.EncodeInt(int64(yy914)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr910 || yy2arr910 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq910[1] { - if x.Completions == nil { - r.EncodeNil() + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { } else { - yy917 := *x.Completions - yym918 := z.EncBinary() - _ = yym918 - if false { - } else { - r.EncodeInt(int64(yy917)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq910[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("completions")) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Completions == nil { - r.EncodeNil() + yym8 := z.EncBinary() + _ = yym8 + if false { } else { - yy919 := *x.Completions - yym920 := z.EncBinary() - _ = yym920 - if false { - } else { - r.EncodeInt(int64(yy919)) - } + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr910 || yy2arr910 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq910[2] { - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - yy922 := *x.ActiveDeadlineSeconds - yym923 := z.EncBinary() - _ = yym923 - if false { - } else { - r.EncodeInt(int64(yy922)) - } + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq910[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("activeDeadlineSeconds")) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.ActiveDeadlineSeconds == nil { - r.EncodeNil() + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - yy924 := *x.ActiveDeadlineSeconds - yym925 := z.EncBinary() - _ = yym925 - if false { - } else { - r.EncodeInt(int64(yy924)) - } + z.EncFallback(yy12) } } } - if yyr910 || yy2arr910 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq910[3] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym927 := z.EncBinary() - _ = yym927 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq910[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) + r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym928 := z.EncBinary() - _ = yym928 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr910 || yy2arr910 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq910[4] { - if x.AutoSelector == nil { - r.EncodeNil() - } else { - yy930 := *x.AutoSelector - yym931 := z.EncBinary() - _ = yym931 - if false { - } else { - r.EncodeBool(bool(yy930)) - } - } + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq910[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("autoSelector")) + r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.AutoSelector == nil { - r.EncodeNil() - } else { - yy932 := *x.AutoSelector - yym933 := z.EncBinary() - _ = yym933 - if false { - } else { - r.EncodeBool(bool(yy932)) - } - } + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr910 || yy2arr910 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy935 := &x.Template - yy935.CodecEncodeSelf(e) - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("template")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy936 := &x.Template - yy936.CodecEncodeSelf(e) - } - if yyr910 || yy2arr910 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -10865,29 +8822,29 @@ func (x *JobSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *JobSpec) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DaemonSet) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym937 := z.DecBinary() - _ = yym937 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct938 := r.ContainerType() - if yyct938 == codecSelferValueTypeMap1234 { - yyl938 := r.ReadMapStart() - if yyl938 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl938, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct938 == codecSelferValueTypeArray1234 { - yyl938 := r.ReadArrayStart() - if yyl938 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl938, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -10895,16 +8852,16 @@ func (x *JobSpec) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DaemonSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys939Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys939Slc - var yyhl939 bool = l >= 0 - for yyj939 := 0; ; yyj939++ { - if yyhl939 { - if yyj939 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -10913,507 +8870,332 @@ func (x *JobSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys939Slc = r.DecodeBytes(yys939Slc, true, true) - yys939 := string(yys939Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys939 { - case "parallelism": - if r.TryDecodeAsNil() { - if x.Parallelism != nil { - x.Parallelism = nil - } - } else { - if x.Parallelism == nil { - x.Parallelism = new(int32) - } - yym941 := z.DecBinary() - _ = yym941 - if false { - } else { - *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) - } - } - case "completions": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - if x.Completions != nil { - x.Completions = nil - } + x.Kind = "" } else { - if x.Completions == nil { - x.Completions = new(int32) - } - yym943 := z.DecBinary() - _ = yym943 + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 if false { } else { - *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) + *((*string)(yyv4)) = r.DecodeString() } } - case "activeDeadlineSeconds": + case "apiVersion": if r.TryDecodeAsNil() { - if x.ActiveDeadlineSeconds != nil { - x.ActiveDeadlineSeconds = nil - } + x.APIVersion = "" } else { - if x.ActiveDeadlineSeconds == nil { - x.ActiveDeadlineSeconds = new(int64) - } - yym945 := z.DecBinary() - _ = yym945 + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 if false { } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) + *((*string)(yyv6)) = r.DecodeString() } } - case "selector": + case "metadata": if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym947 := z.DecBinary() - _ = yym947 + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(x.Selector, false) + z.DecFallback(yyv8, false) } } - case "autoSelector": + case "spec": if r.TryDecodeAsNil() { - if x.AutoSelector != nil { - x.AutoSelector = nil - } + x.Spec = DaemonSetSpec{} } else { - if x.AutoSelector == nil { - x.AutoSelector = new(bool) - } - yym949 := z.DecBinary() - _ = yym949 - if false { - } else { - *((*bool)(x.AutoSelector)) = r.DecodeBool() - } + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } - case "template": + case "status": if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} + x.Status = DaemonSetStatus{} } else { - yyv950 := &x.Template - yyv950.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys939) - } // end switch yys939 - } // end for yyj939 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *JobSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DaemonSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj951 int - var yyb951 bool - var yyhl951 bool = l >= 0 - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l - } else { - yyb951 = r.CheckBreak() - } - if yyb951 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Parallelism != nil { - x.Parallelism = nil - } - } else { - if x.Parallelism == nil { - x.Parallelism = new(int32) - } - yym953 := z.DecBinary() - _ = yym953 - if false { - } else { - *((*int32)(x.Parallelism)) = int32(r.DecodeInt(32)) - } - } - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb951 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb951 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Completions != nil { - x.Completions = nil - } + x.Kind = "" } else { - if x.Completions == nil { - x.Completions = new(int32) - } - yym955 := z.DecBinary() - _ = yym955 + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 if false { } else { - *((*int32)(x.Completions)) = int32(r.DecodeInt(32)) + *((*string)(yyv13)) = r.DecodeString() } } - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb951 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb951 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.ActiveDeadlineSeconds != nil { - x.ActiveDeadlineSeconds = nil - } + x.APIVersion = "" } else { - if x.ActiveDeadlineSeconds == nil { - x.ActiveDeadlineSeconds = new(int64) - } - yym957 := z.DecBinary() - _ = yym957 + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 if false { } else { - *((*int64)(x.ActiveDeadlineSeconds)) = int64(r.DecodeInt(64)) + *((*string)(yyv15)) = r.DecodeString() } } - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb951 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb951 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) - } - yym959 := z.DecBinary() - _ = yym959 + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(x.Selector, false) + z.DecFallback(yyv17, false) } } - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb951 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb951 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.AutoSelector != nil { - x.AutoSelector = nil - } + x.Spec = DaemonSetSpec{} } else { - if x.AutoSelector == nil { - x.AutoSelector = new(bool) - } - yym961 := z.DecBinary() - _ = yym961 - if false { - } else { - *((*bool)(x.AutoSelector)) = r.DecodeBool() - } + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb951 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb951 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} + x.Status = DaemonSetStatus{} } else { - yyv962 := &x.Template - yyv962.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj951++ - if yyhl951 { - yyb951 = yyj951 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb951 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb951 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj951-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } - -func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym963 := z.EncBinary() - _ = yym963 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep964 := !z.EncBinary() - yy2arr964 := z.EncBasicHandle().StructToArray - var yyq964 [6]bool - _, _, _ = yysep964, yyq964, yy2arr964 - const yyr964 bool = false - yyq964[0] = len(x.Conditions) != 0 - yyq964[1] = x.StartTime != nil - yyq964[2] = x.CompletionTime != nil - yyq964[3] = x.Active != 0 - yyq964[4] = x.Succeeded != 0 - yyq964[5] = x.Failed != 0 - var yynn964 int - if yyr964 || yy2arr964 { - r.EncodeArrayStart(6) - } else { - yynn964 = 0 - for _, b := range yyq964 { - if b { - yynn964++ - } - } - r.EncodeMapStart(yynn964) - yynn964 = 0 - } - if yyr964 || yy2arr964 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq964[0] { - if x.Conditions == nil { - r.EncodeNil() - } else { - yym966 := z.EncBinary() - _ = yym966 - if false { - } else { - h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq964[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("conditions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Conditions == nil { - r.EncodeNil() - } else { - yym967 := z.EncBinary() - _ = yym967 - if false { - } else { - h.encSliceJobCondition(([]JobCondition)(x.Conditions), e) - } - } - } - } - if yyr964 || yy2arr964 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq964[1] { - if x.StartTime == nil { - r.EncodeNil() - } else { - yym969 := z.EncBinary() - _ = yym969 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym969 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym969 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } - } - } else { - r.EncodeNil() - } + +func (x *DaemonSetList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - if yyq964[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("startTime")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.StartTime == nil { - r.EncodeNil() - } else { - yym970 := z.EncBinary() - _ = yym970 - if false { - } else if z.HasExtensions() && z.EncExt(x.StartTime) { - } else if yym970 { - z.EncBinaryMarshal(x.StartTime) - } else if !yym970 && z.IsJSONHandle() { - z.EncJSONMarshal(x.StartTime) - } else { - z.EncFallback(x.StartTime) - } + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ } } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr964 || yy2arr964 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq964[2] { - if x.CompletionTime == nil { - r.EncodeNil() + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { } else { - yym972 := z.EncBinary() - _ = yym972 - if false { - } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym972 { - z.EncBinaryMarshal(x.CompletionTime) - } else if !yym972 && z.IsJSONHandle() { - z.EncJSONMarshal(x.CompletionTime) - } else { - z.EncFallback(x.CompletionTime) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq964[2] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("completionTime")) + r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.CompletionTime == nil { - r.EncodeNil() + yym5 := z.EncBinary() + _ = yym5 + if false { } else { - yym973 := z.EncBinary() - _ = yym973 - if false { - } else if z.HasExtensions() && z.EncExt(x.CompletionTime) { - } else if yym973 { - z.EncBinaryMarshal(x.CompletionTime) - } else if !yym973 && z.IsJSONHandle() { - z.EncJSONMarshal(x.CompletionTime) - } else { - z.EncFallback(x.CompletionTime) - } + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr964 || yy2arr964 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq964[3] { - yym975 := z.EncBinary() - _ = yym975 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeInt(int64(x.Active)) + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } else { - r.EncodeInt(0) + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq964[3] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("active")) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym976 := z.EncBinary() - _ = yym976 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - r.EncodeInt(int64(x.Active)) + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr964 || yy2arr964 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq964[4] { - yym978 := z.EncBinary() - _ = yym978 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - r.EncodeInt(int64(x.Succeeded)) + z.EncFallback(yy10) } } else { - r.EncodeInt(0) + r.EncodeNil() } } else { - if yyq964[4] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("succeeded")) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym979 := z.EncBinary() - _ = yym979 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - r.EncodeInt(int64(x.Succeeded)) + z.EncFallback(yy12) } } } - if yyr964 || yy2arr964 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq964[5] { - yym981 := z.EncBinary() - _ = yym981 + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 if false { } else { - r.EncodeInt(int64(x.Failed)) + h.encSliceDaemonSet(([]DaemonSet)(x.Items), e) } - } else { - r.EncodeInt(0) } } else { - if yyq964[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("failed")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym982 := z.EncBinary() - _ = yym982 + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeInt(int64(x.Failed)) + h.encSliceDaemonSet(([]DaemonSet)(x.Items), e) } } } - if yyr964 || yy2arr964 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -11422,29 +9204,29 @@ func (x *JobStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *JobStatus) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *DaemonSetList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym983 := z.DecBinary() - _ = yym983 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct984 := r.ContainerType() - if yyct984 == codecSelferValueTypeMap1234 { - yyl984 := r.ReadMapStart() - if yyl984 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl984, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct984 == codecSelferValueTypeArray1234 { - yyl984 := r.ReadArrayStart() - if yyl984 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl984, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -11452,16 +9234,16 @@ func (x *JobStatus) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *DaemonSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys985Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys985Slc - var yyhl985 bool = l >= 0 - for yyj985 := 0; ; yyj985++ { - if yyhl985 { - if yyj985 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -11470,459 +9252,318 @@ func (x *JobStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys985Slc = r.DecodeBytes(yys985Slc, true, true) - yys985 := string(yys985Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys985 { - case "conditions": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - x.Conditions = nil + x.Kind = "" } else { - yyv986 := &x.Conditions - yym987 := z.DecBinary() - _ = yym987 + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceJobCondition((*[]JobCondition)(yyv986), d) + *((*string)(yyv4)) = r.DecodeString() } } - case "startTime": + case "apiVersion": if r.TryDecodeAsNil() { - if x.StartTime != nil { - x.StartTime = nil - } + x.APIVersion = "" } else { - if x.StartTime == nil { - x.StartTime = new(pkg1_unversioned.Time) - } - yym989 := z.DecBinary() - _ = yym989 + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym989 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym989 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) } else { - z.DecFallback(x.StartTime, false) + *((*string)(yyv6)) = r.DecodeString() } } - case "completionTime": + case "metadata": if r.TryDecodeAsNil() { - if x.CompletionTime != nil { - x.CompletionTime = nil - } + x.ListMeta = pkg1_v1.ListMeta{} } else { - if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) - } - yym991 := z.DecBinary() - _ = yym991 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym991 { - z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym991 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.CompletionTime) + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(x.CompletionTime, false) + z.DecFallback(yyv8, false) } } - case "active": - if r.TryDecodeAsNil() { - x.Active = 0 - } else { - x.Active = int32(r.DecodeInt(32)) - } - case "succeeded": - if r.TryDecodeAsNil() { - x.Succeeded = 0 - } else { - x.Succeeded = int32(r.DecodeInt(32)) - } - case "failed": + case "items": if r.TryDecodeAsNil() { - x.Failed = 0 + x.Items = nil } else { - x.Failed = int32(r.DecodeInt(32)) + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceDaemonSet((*[]DaemonSet)(yyv10), d) + } } default: - z.DecStructFieldNotFound(-1, yys985) - } // end switch yys985 - } // end for yyj985 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *JobStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *DaemonSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj995 int - var yyb995 bool - var yyhl995 bool = l >= 0 - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb995 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb995 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Conditions = nil + x.Kind = "" } else { - yyv996 := &x.Conditions - yym997 := z.DecBinary() - _ = yym997 + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 if false { } else { - h.decSliceJobCondition((*[]JobCondition)(yyv996), d) + *((*string)(yyv13)) = r.DecodeString() } } - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb995 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb995 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.StartTime != nil { - x.StartTime = nil - } + x.APIVersion = "" } else { - if x.StartTime == nil { - x.StartTime = new(pkg1_unversioned.Time) - } - yym999 := z.DecBinary() - _ = yym999 + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(x.StartTime) { - } else if yym999 { - z.DecBinaryUnmarshal(x.StartTime) - } else if !yym999 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.StartTime) } else { - z.DecFallback(x.StartTime, false) + *((*string)(yyv15)) = r.DecodeString() } } - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb995 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb995 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - if x.CompletionTime != nil { - x.CompletionTime = nil - } + x.ListMeta = pkg1_v1.ListMeta{} } else { - if x.CompletionTime == nil { - x.CompletionTime = new(pkg1_unversioned.Time) - } - yym1001 := z.DecBinary() - _ = yym1001 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(x.CompletionTime) { - } else if yym1001 { - z.DecBinaryUnmarshal(x.CompletionTime) - } else if !yym1001 && z.IsJSONHandle() { - z.DecJSONUnmarshal(x.CompletionTime) + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(x.CompletionTime, false) + z.DecFallback(yyv17, false) } } - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l - } else { - yyb995 = r.CheckBreak() - } - if yyb995 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Active = 0 - } else { - x.Active = int32(r.DecodeInt(32)) - } - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l - } else { - yyb995 = r.CheckBreak() - } - if yyb995 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Succeeded = 0 - } else { - x.Succeeded = int32(r.DecodeInt(32)) - } - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb995 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb995 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Failed = 0 + x.Items = nil } else { - x.Failed = int32(r.DecodeInt(32)) + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceDaemonSet((*[]DaemonSet)(yyv19), d) + } } for { - yyj995++ - if yyhl995 { - yyb995 = yyj995 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb995 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb995 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj995-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x JobConditionType) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - yym1005 := z.EncBinary() - _ = yym1005 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x)) - } -} - -func (x *JobConditionType) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym1006 := z.DecBinary() - _ = yym1006 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - *((*string)(x)) = r.DecodeString() - } -} - -func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { +func (x *ThirdPartyResourceDataList) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r if x == nil { r.EncodeNil() } else { - yym1007 := z.EncBinary() - _ = yym1007 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1008 := !z.EncBinary() - yy2arr1008 := z.EncBasicHandle().StructToArray - var yyq1008 [6]bool - _, _, _ = yysep1008, yyq1008, yy2arr1008 - const yyr1008 bool = false - yyq1008[2] = true - yyq1008[3] = true - yyq1008[4] = x.Reason != "" - yyq1008[5] = x.Message != "" - var yynn1008 int - if yyr1008 || yy2arr1008 { - r.EncodeArrayStart(6) + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) } else { - yynn1008 = 2 - for _, b := range yyq1008 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1008++ + yynn2++ } } - r.EncodeMapStart(yynn1008) - yynn1008 = 0 - } - if yyr1008 || yy2arr1008 { - 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 yyr1008 || yy2arr1008 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1011 := z.EncBinary() - _ = yym1011 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1012 := z.EncBinary() - _ = yym1012 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1008 || yy2arr1008 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1008[2] { - yy1014 := &x.LastProbeTime - yym1015 := z.EncBinary() - _ = yym1015 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { - } else if z.HasExtensions() && z.EncExt(yy1014) { - } else if yym1015 { - z.EncBinaryMarshal(yy1014) - } else if !yym1015 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1014) } else { - z.EncFallback(yy1014) + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1008[2] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastProbeTime")) + r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1016 := &x.LastProbeTime - yym1017 := z.EncBinary() - _ = yym1017 + yym5 := z.EncBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.EncExt(yy1016) { - } else if yym1017 { - z.EncBinaryMarshal(yy1016) - } else if !yym1017 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1016) } else { - z.EncFallback(yy1016) + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1008 || yy2arr1008 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1008[3] { - yy1019 := &x.LastTransitionTime - yym1020 := z.EncBinary() - _ = yym1020 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.EncExt(yy1019) { - } else if yym1020 { - z.EncBinaryMarshal(yy1019) - } else if !yym1020 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1019) } else { - z.EncFallback(yy1019) + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } else { - r.EncodeNil() + r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1008[3] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1021 := &x.LastTransitionTime - yym1022 := z.EncBinary() - _ = yym1022 + yym8 := z.EncBinary() + _ = yym8 if false { - } else if z.HasExtensions() && z.EncExt(yy1021) { - } else if yym1022 { - z.EncBinaryMarshal(yy1021) - } else if !yym1022 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1021) } else { - z.EncFallback(yy1021) + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1008 || yy2arr1008 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1008[4] { - yym1024 := z.EncBinary() - _ = yym1024 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + z.EncFallback(yy10) } } else { - r.EncodeString(codecSelferC_UTF81234, "") + r.EncodeNil() } } else { - if yyq1008[4] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("reason")) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1025 := z.EncBinary() - _ = yym1025 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) + z.EncFallback(yy12) } } } - if yyr1008 || yy2arr1008 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1008[5] { - yym1027 := z.EncBinary() - _ = yym1027 + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + h.encSliceThirdPartyResourceData(([]ThirdPartyResourceData)(x.Items), e) } - } else { - r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1008[5] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("message")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1028 := z.EncBinary() - _ = yym1028 + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("items")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Message)) + h.encSliceThirdPartyResourceData(([]ThirdPartyResourceData)(x.Items), e) } } } - if yyr1008 || yy2arr1008 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -11931,29 +9572,29 @@ func (x *JobCondition) CodecEncodeSelf(e *codec1978.Encoder) { } } -func (x *JobCondition) CodecDecodeSelf(d *codec1978.Decoder) { +func (x *ThirdPartyResourceDataList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1029 := z.DecBinary() - _ = yym1029 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1030 := r.ContainerType() - if yyct1030 == codecSelferValueTypeMap1234 { - yyl1030 := r.ReadMapStart() - if yyl1030 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1030, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1030 == codecSelferValueTypeArray1234 { - yyl1030 := r.ReadArrayStart() - if yyl1030 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1030, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -11961,16 +9602,16 @@ func (x *JobCondition) CodecDecodeSelf(d *codec1978.Decoder) { } } -func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResourceDataList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1031Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1031Slc - var yyhl1031 bool = l >= 0 - for yyj1031 := 0; ; yyj1031++ { - if yyhl1031 { - if yyj1031 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -11979,212 +9620,174 @@ func (x *JobCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1031Slc = r.DecodeBytes(yys1031Slc, true, true) - yys1031 := string(yys1031Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1031 { - case "type": - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = JobConditionType(r.DecodeString()) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) - } - case "lastProbeTime": + switch yys3 { + case "kind": if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} + x.Kind = "" } else { - yyv1034 := &x.LastProbeTime - yym1035 := z.DecBinary() - _ = yym1035 + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv1034) { - } else if yym1035 { - z.DecBinaryUnmarshal(yyv1034) - } else if !yym1035 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1034) } else { - z.DecFallback(yyv1034, false) + *((*string)(yyv4)) = r.DecodeString() } } - case "lastTransitionTime": + case "apiVersion": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.APIVersion = "" } else { - yyv1036 := &x.LastTransitionTime - yym1037 := z.DecBinary() - _ = yym1037 + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv1036) { - } else if yym1037 { - z.DecBinaryUnmarshal(yyv1036) - } else if !yym1037 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1036) } else { - z.DecFallback(yyv1036, false) + *((*string)(yyv6)) = r.DecodeString() } } - case "reason": + case "metadata": if r.TryDecodeAsNil() { - x.Reason = "" + x.ListMeta = pkg1_v1.ListMeta{} } else { - x.Reason = string(r.DecodeString()) + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } - case "message": + case "items": if r.TryDecodeAsNil() { - x.Message = "" + x.Items = nil } else { - x.Message = string(r.DecodeString()) + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceThirdPartyResourceData((*[]ThirdPartyResourceData)(yyv10), d) + } } default: - z.DecStructFieldNotFound(-1, yys1031) - } // end switch yys1031 - } // end for yyj1031 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } -func (x *JobCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { +func (x *ThirdPartyResourceDataList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1040 int - var yyb1040 bool - var yyhl1040 bool = l >= 0 - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l - } else { - yyb1040 = r.CheckBreak() - } - if yyb1040 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Type = "" - } else { - x.Type = JobConditionType(r.DecodeString()) - } - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l - } else { - yyb1040 = r.CheckBreak() - } - if yyb1040 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = "" - } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) - } - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1040 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1040 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastProbeTime = pkg1_unversioned.Time{} + x.Kind = "" } else { - yyv1043 := &x.LastProbeTime - yym1044 := z.DecBinary() - _ = yym1044 + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 if false { - } else if z.HasExtensions() && z.DecExt(yyv1043) { - } else if yym1044 { - z.DecBinaryUnmarshal(yyv1043) - } else if !yym1044 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1043) } else { - z.DecFallback(yyv1043, false) + *((*string)(yyv13)) = r.DecodeString() } } - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1040 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1040 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.APIVersion = "" } else { - yyv1045 := &x.LastTransitionTime - yym1046 := z.DecBinary() - _ = yym1046 + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(yyv1045) { - } else if yym1046 { - z.DecBinaryUnmarshal(yyv1045) - } else if !yym1046 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1045) } else { - z.DecFallback(yyv1045, false) + *((*string)(yyv15)) = r.DecodeString() } } - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1040 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1040 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Reason = "" + x.ListMeta = pkg1_v1.ListMeta{} } else { - x.Reason = string(r.DecodeString()) + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1040 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1040 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Message = "" + x.Items = nil } else { - x.Message = string(r.DecodeString()) + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceThirdPartyResourceData((*[]ThirdPartyResourceData)(yyv19), d) + } } for { - yyj1040++ - if yyhl1040 { - yyb1040 = yyj1040 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1040 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1040 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1040-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -12196,39 +9799,39 @@ func (x *Ingress) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1049 := z.EncBinary() - _ = yym1049 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1050 := !z.EncBinary() - yy2arr1050 := z.EncBasicHandle().StructToArray - var yyq1050 [5]bool - _, _, _ = yysep1050, yyq1050, yy2arr1050 - const yyr1050 bool = false - yyq1050[0] = x.Kind != "" - yyq1050[1] = x.APIVersion != "" - yyq1050[2] = true - yyq1050[3] = true - yyq1050[4] = true - var yynn1050 int - if yyr1050 || yy2arr1050 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn1050 = 0 - for _, b := range yyq1050 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1050++ + yynn2++ } } - r.EncodeMapStart(yynn1050) - yynn1050 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1050 || yy2arr1050 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[0] { - yym1052 := z.EncBinary() - _ = yym1052 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -12237,23 +9840,23 @@ func (x *Ingress) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1050[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1053 := z.EncBinary() - _ = yym1053 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1050 || yy2arr1050 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[1] { - yym1055 := z.EncBinary() - _ = yym1055 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -12262,70 +9865,82 @@ func (x *Ingress) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1050[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1056 := z.EncBinary() - _ = yym1056 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1050 || yy2arr1050 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[2] { - yy1058 := &x.ObjectMeta - yy1058.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq1050[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1059 := &x.ObjectMeta - yy1059.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr1050 || yy2arr1050 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[3] { - yy1061 := &x.Spec - yy1061.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1050[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1062 := &x.Spec - yy1062.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr1050 || yy2arr1050 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1050[4] { - yy1064 := &x.Status - yy1064.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1050[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1065 := &x.Status - yy1065.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr1050 || yy2arr1050 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -12338,25 +9953,25 @@ func (x *Ingress) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1066 := z.DecBinary() - _ = yym1066 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1067 := r.ContainerType() - if yyct1067 == codecSelferValueTypeMap1234 { - yyl1067 := r.ReadMapStart() - if yyl1067 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1067, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1067 == codecSelferValueTypeArray1234 { - yyl1067 := r.ReadArrayStart() - if yyl1067 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1067, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -12368,12 +9983,12 @@ func (x *Ingress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1068Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1068Slc - var yyhl1068 bool = l >= 0 - for yyj1068 := 0; ; yyj1068++ { - if yyhl1068 { - if yyj1068 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -12382,47 +9997,65 @@ func (x *Ingress) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1068Slc = r.DecodeBytes(yys1068Slc, true, true) - yys1068 := string(yys1068Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1068 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1071 := &x.ObjectMeta - yyv1071.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = IngressSpec{} } else { - yyv1072 := &x.Spec - yyv1072.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = IngressStatus{} } else { - yyv1073 := &x.Status - yyv1073.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1068) - } // end switch yys1068 - } // end for yyj1068 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -12430,16 +10063,16 @@ func (x *Ingress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1074 int - var yyb1074 bool - var yyhl1074 bool = l >= 0 - yyj1074++ - if yyhl1074 { - yyb1074 = yyj1074 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1074 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1074 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12447,15 +10080,21 @@ func (x *Ingress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1074++ - if yyhl1074 { - yyb1074 = yyj1074 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1074 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1074 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12463,32 +10102,44 @@ func (x *Ingress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj1074++ - if yyhl1074 { - yyb1074 = yyj1074 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1074 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1074 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1077 := &x.ObjectMeta - yyv1077.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj1074++ - if yyhl1074 { - yyb1074 = yyj1074 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1074 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1074 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12496,16 +10147,16 @@ func (x *Ingress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = IngressSpec{} } else { - yyv1078 := &x.Spec - yyv1078.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj1074++ - if yyhl1074 { - yyb1074 = yyj1074 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1074 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1074 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12513,21 +10164,21 @@ func (x *Ingress) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = IngressStatus{} } else { - yyv1079 := &x.Status - yyv1079.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj1074++ - if yyhl1074 { - yyb1074 = yyj1074 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1074 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1074 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1074-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -12539,37 +10190,37 @@ func (x *IngressList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1080 := z.EncBinary() - _ = yym1080 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1081 := !z.EncBinary() - yy2arr1081 := z.EncBasicHandle().StructToArray - var yyq1081 [4]bool - _, _, _ = yysep1081, yyq1081, yy2arr1081 - const yyr1081 bool = false - yyq1081[0] = x.Kind != "" - yyq1081[1] = x.APIVersion != "" - yyq1081[2] = true - var yynn1081 int - if yyr1081 || yy2arr1081 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1081 = 1 - for _, b := range yyq1081 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1081++ + yynn2++ } } - r.EncodeMapStart(yynn1081) - yynn1081 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1081 || yy2arr1081 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1081[0] { - yym1083 := z.EncBinary() - _ = yym1083 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -12578,23 +10229,23 @@ func (x *IngressList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1081[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1084 := z.EncBinary() - _ = yym1084 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1081 || yy2arr1081 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1081[1] { - yym1086 := z.EncBinary() - _ = yym1086 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -12603,54 +10254,54 @@ func (x *IngressList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1081[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1087 := z.EncBinary() - _ = yym1087 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1081 || yy2arr1081 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1081[2] { - yy1089 := &x.ListMeta - yym1090 := z.EncBinary() - _ = yym1090 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy1089) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy1089) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1081[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1091 := &x.ListMeta - yym1092 := z.EncBinary() - _ = yym1092 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy1091) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy1091) + z.EncFallback(yy12) } } } - if yyr1081 || yy2arr1081 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym1094 := z.EncBinary() - _ = yym1094 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceIngress(([]Ingress)(x.Items), e) @@ -12663,15 +10314,15 @@ func (x *IngressList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym1095 := z.EncBinary() - _ = yym1095 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceIngress(([]Ingress)(x.Items), e) } } } - if yyr1081 || yy2arr1081 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -12684,25 +10335,25 @@ func (x *IngressList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1096 := z.DecBinary() - _ = yym1096 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1097 := r.ContainerType() - if yyct1097 == codecSelferValueTypeMap1234 { - yyl1097 := r.ReadMapStart() - if yyl1097 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1097, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1097 == codecSelferValueTypeArray1234 { - yyl1097 := r.ReadArrayStart() - if yyl1097 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1097, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -12714,12 +10365,12 @@ func (x *IngressList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1098Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1098Slc - var yyhl1098 bool = l >= 0 - for yyj1098 := 0; ; yyj1098++ { - if yyhl1098 { - if yyj1098 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -12728,51 +10379,63 @@ func (x *IngressList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1098Slc = r.DecodeBytes(yys1098Slc, true, true) - yys1098 := string(yys1098Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1098 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1101 := &x.ListMeta - yym1102 := z.DecBinary() - _ = yym1102 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv1101) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv1101, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1103 := &x.Items - yym1104 := z.DecBinary() - _ = yym1104 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceIngress((*[]Ingress)(yyv1103), d) + h.decSliceIngress((*[]Ingress)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys1098) - } // end switch yys1098 - } // end for yyj1098 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -12780,16 +10443,16 @@ func (x *IngressList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1105 int - var yyb1105 bool - var yyhl1105 bool = l >= 0 - yyj1105++ - if yyhl1105 { - yyb1105 = yyj1105 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1105 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1105 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12797,15 +10460,21 @@ func (x *IngressList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1105++ - if yyhl1105 { - yyb1105 = yyj1105 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1105 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1105 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12813,38 +10482,44 @@ func (x *IngressList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj1105++ - if yyhl1105 { - yyb1105 = yyj1105 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1105 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1105 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1108 := &x.ListMeta - yym1109 := z.DecBinary() - _ = yym1109 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv1108) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv1108, false) + z.DecFallback(yyv17, false) } } - yyj1105++ - if yyhl1105 { - yyb1105 = yyj1105 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1105 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1105 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -12852,26 +10527,26 @@ func (x *IngressList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1110 := &x.Items - yym1111 := z.DecBinary() - _ = yym1111 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceIngress((*[]Ingress)(yyv1110), d) + h.decSliceIngress((*[]Ingress)(yyv19), d) } } for { - yyj1105++ - if yyhl1105 { - yyb1105 = yyj1105 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1105 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1105 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1105-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -12883,35 +10558,35 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1112 := z.EncBinary() - _ = yym1112 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1113 := !z.EncBinary() - yy2arr1113 := z.EncBasicHandle().StructToArray - var yyq1113 [3]bool - _, _, _ = yysep1113, yyq1113, yy2arr1113 - const yyr1113 bool = false - yyq1113[0] = x.Backend != nil - yyq1113[1] = len(x.TLS) != 0 - yyq1113[2] = len(x.Rules) != 0 - var yynn1113 int - if yyr1113 || yy2arr1113 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Backend != nil + yyq2[1] = len(x.TLS) != 0 + yyq2[2] = len(x.Rules) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn1113 = 0 - for _, b := range yyq1113 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1113++ + yynn2++ } } - r.EncodeMapStart(yynn1113) - yynn1113 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1113[0] { + if yyq2[0] { if x.Backend == nil { r.EncodeNil() } else { @@ -12921,7 +10596,7 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1113[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("backend")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -12932,14 +10607,14 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1113[1] { + if yyq2[1] { if x.TLS == nil { r.EncodeNil() } else { - yym1116 := z.EncBinary() - _ = yym1116 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceIngressTLS(([]IngressTLS)(x.TLS), e) @@ -12949,15 +10624,15 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1113[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("tls")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.TLS == nil { r.EncodeNil() } else { - yym1117 := z.EncBinary() - _ = yym1117 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceIngressTLS(([]IngressTLS)(x.TLS), e) @@ -12965,14 +10640,14 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1113[2] { + if yyq2[2] { if x.Rules == nil { r.EncodeNil() } else { - yym1119 := z.EncBinary() - _ = yym1119 + yym10 := z.EncBinary() + _ = yym10 if false { } else { h.encSliceIngressRule(([]IngressRule)(x.Rules), e) @@ -12982,15 +10657,15 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1113[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rules")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Rules == nil { r.EncodeNil() } else { - yym1120 := z.EncBinary() - _ = yym1120 + yym11 := z.EncBinary() + _ = yym11 if false { } else { h.encSliceIngressRule(([]IngressRule)(x.Rules), e) @@ -12998,7 +10673,7 @@ func (x *IngressSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1113 || yy2arr1113 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13011,25 +10686,25 @@ func (x *IngressSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1121 := z.DecBinary() - _ = yym1121 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1122 := r.ContainerType() - if yyct1122 == codecSelferValueTypeMap1234 { - yyl1122 := r.ReadMapStart() - if yyl1122 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1122, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1122 == codecSelferValueTypeArray1234 { - yyl1122 := r.ReadArrayStart() - if yyl1122 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1122, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13041,12 +10716,12 @@ func (x *IngressSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1123Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1123Slc - var yyhl1123 bool = l >= 0 - for yyj1123 := 0; ; yyj1123++ { - if yyhl1123 { - if yyj1123 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13055,10 +10730,10 @@ func (x *IngressSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1123Slc = r.DecodeBytes(yys1123Slc, true, true) - yys1123 := string(yys1123Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1123 { + switch yys3 { case "backend": if r.TryDecodeAsNil() { if x.Backend != nil { @@ -13074,30 +10749,30 @@ func (x *IngressSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TLS = nil } else { - yyv1125 := &x.TLS - yym1126 := z.DecBinary() - _ = yym1126 + yyv5 := &x.TLS + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSliceIngressTLS((*[]IngressTLS)(yyv1125), d) + h.decSliceIngressTLS((*[]IngressTLS)(yyv5), d) } } case "rules": if r.TryDecodeAsNil() { x.Rules = nil } else { - yyv1127 := &x.Rules - yym1128 := z.DecBinary() - _ = yym1128 + yyv7 := &x.Rules + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceIngressRule((*[]IngressRule)(yyv1127), d) + h.decSliceIngressRule((*[]IngressRule)(yyv7), d) } } default: - z.DecStructFieldNotFound(-1, yys1123) - } // end switch yys1123 - } // end for yyj1123 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13105,16 +10780,16 @@ func (x *IngressSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1129 int - var yyb1129 bool - var yyhl1129 bool = l >= 0 - yyj1129++ - if yyhl1129 { - yyb1129 = yyj1129 > l + var yyj9 int + var yyb9 bool + var yyhl9 bool = l >= 0 + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1129 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1129 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13129,13 +10804,13 @@ func (x *IngressSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } x.Backend.CodecDecodeSelf(d) } - yyj1129++ - if yyhl1129 { - yyb1129 = yyj1129 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1129 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1129 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13143,21 +10818,21 @@ func (x *IngressSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.TLS = nil } else { - yyv1131 := &x.TLS - yym1132 := z.DecBinary() - _ = yym1132 + yyv11 := &x.TLS + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceIngressTLS((*[]IngressTLS)(yyv1131), d) + h.decSliceIngressTLS((*[]IngressTLS)(yyv11), d) } } - yyj1129++ - if yyhl1129 { - yyb1129 = yyj1129 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1129 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1129 { + if yyb9 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13165,26 +10840,26 @@ func (x *IngressSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Rules = nil } else { - yyv1133 := &x.Rules - yym1134 := z.DecBinary() - _ = yym1134 + yyv13 := &x.Rules + yym14 := z.DecBinary() + _ = yym14 if false { } else { - h.decSliceIngressRule((*[]IngressRule)(yyv1133), d) + h.decSliceIngressRule((*[]IngressRule)(yyv13), d) } } for { - yyj1129++ - if yyhl1129 { - yyb1129 = yyj1129 > l + yyj9++ + if yyhl9 { + yyb9 = yyj9 > l } else { - yyb1129 = r.CheckBreak() + yyb9 = r.CheckBreak() } - if yyb1129 { + if yyb9 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1129-1, "") + z.DecStructFieldNotFound(yyj9-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -13196,39 +10871,39 @@ func (x *IngressTLS) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1135 := z.EncBinary() - _ = yym1135 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1136 := !z.EncBinary() - yy2arr1136 := z.EncBasicHandle().StructToArray - var yyq1136 [2]bool - _, _, _ = yysep1136, yyq1136, yy2arr1136 - const yyr1136 bool = false - yyq1136[0] = len(x.Hosts) != 0 - yyq1136[1] = x.SecretName != "" - var yynn1136 int - if yyr1136 || yy2arr1136 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Hosts) != 0 + yyq2[1] = x.SecretName != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1136 = 0 - for _, b := range yyq1136 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1136++ + yynn2++ } } - r.EncodeMapStart(yynn1136) - yynn1136 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1136 || yy2arr1136 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1136[0] { + if yyq2[0] { if x.Hosts == nil { r.EncodeNil() } else { - yym1138 := z.EncBinary() - _ = yym1138 + yym4 := z.EncBinary() + _ = yym4 if false { } else { z.F.EncSliceStringV(x.Hosts, false, e) @@ -13238,15 +10913,15 @@ func (x *IngressTLS) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1136[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hosts")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Hosts == nil { r.EncodeNil() } else { - yym1139 := z.EncBinary() - _ = yym1139 + yym5 := z.EncBinary() + _ = yym5 if false { } else { z.F.EncSliceStringV(x.Hosts, false, e) @@ -13254,11 +10929,11 @@ func (x *IngressTLS) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1136 || yy2arr1136 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1136[1] { - yym1141 := z.EncBinary() - _ = yym1141 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) @@ -13267,19 +10942,19 @@ func (x *IngressTLS) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1136[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("secretName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1142 := z.EncBinary() - _ = yym1142 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.SecretName)) } } } - if yyr1136 || yy2arr1136 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13292,25 +10967,25 @@ func (x *IngressTLS) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1143 := z.DecBinary() - _ = yym1143 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1144 := r.ContainerType() - if yyct1144 == codecSelferValueTypeMap1234 { - yyl1144 := r.ReadMapStart() - if yyl1144 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1144, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1144 == codecSelferValueTypeArray1234 { - yyl1144 := r.ReadArrayStart() - if yyl1144 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1144, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13322,12 +10997,12 @@ func (x *IngressTLS) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1145Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1145Slc - var yyhl1145 bool = l >= 0 - for yyj1145 := 0; ; yyj1145++ { - if yyhl1145 { - if yyj1145 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13336,32 +11011,38 @@ func (x *IngressTLS) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1145Slc = r.DecodeBytes(yys1145Slc, true, true) - yys1145 := string(yys1145Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1145 { + switch yys3 { case "hosts": if r.TryDecodeAsNil() { x.Hosts = nil } else { - yyv1146 := &x.Hosts - yym1147 := z.DecBinary() - _ = yym1147 + yyv4 := &x.Hosts + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv1146, false, d) + z.F.DecSliceStringX(yyv4, false, d) } } case "secretName": if r.TryDecodeAsNil() { x.SecretName = "" } else { - x.SecretName = string(r.DecodeString()) + yyv6 := &x.SecretName + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1145) - } // end switch yys1145 - } // end for yyj1145 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13369,16 +11050,16 @@ func (x *IngressTLS) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1149 int - var yyb1149 bool - var yyhl1149 bool = l >= 0 - yyj1149++ - if yyhl1149 { - yyb1149 = yyj1149 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1149 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1149 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13386,21 +11067,21 @@ func (x *IngressTLS) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Hosts = nil } else { - yyv1150 := &x.Hosts - yym1151 := z.DecBinary() - _ = yym1151 + yyv9 := &x.Hosts + yym10 := z.DecBinary() + _ = yym10 if false { } else { - z.F.DecSliceStringX(yyv1150, false, d) + z.F.DecSliceStringX(yyv9, false, d) } } - yyj1149++ - if yyhl1149 { - yyb1149 = yyj1149 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1149 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1149 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13408,20 +11089,26 @@ func (x *IngressTLS) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.SecretName = "" } else { - x.SecretName = string(r.DecodeString()) + yyv11 := &x.SecretName + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } for { - yyj1149++ - if yyhl1149 { - yyb1149 = yyj1149 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1149 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1149 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1149-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -13433,48 +11120,48 @@ func (x *IngressStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1153 := z.EncBinary() - _ = yym1153 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1154 := !z.EncBinary() - yy2arr1154 := z.EncBasicHandle().StructToArray - var yyq1154 [1]bool - _, _, _ = yysep1154, yyq1154, yy2arr1154 - const yyr1154 bool = false - yyq1154[0] = true - var yynn1154 int - if yyr1154 || yy2arr1154 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1154 = 0 - for _, b := range yyq1154 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1154++ + yynn2++ } } - r.EncodeMapStart(yynn1154) - yynn1154 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1154 || yy2arr1154 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1154[0] { - yy1156 := &x.LoadBalancer - yy1156.CodecEncodeSelf(e) + if yyq2[0] { + yy4 := &x.LoadBalancer + yy4.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1154[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("loadBalancer")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1157 := &x.LoadBalancer - yy1157.CodecEncodeSelf(e) + yy6 := &x.LoadBalancer + yy6.CodecEncodeSelf(e) } } - if yyr1154 || yy2arr1154 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13487,25 +11174,25 @@ func (x *IngressStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1158 := z.DecBinary() - _ = yym1158 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1159 := r.ContainerType() - if yyct1159 == codecSelferValueTypeMap1234 { - yyl1159 := r.ReadMapStart() - if yyl1159 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1159, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1159 == codecSelferValueTypeArray1234 { - yyl1159 := r.ReadArrayStart() - if yyl1159 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1159, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13517,12 +11204,12 @@ func (x *IngressStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1160Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1160Slc - var yyhl1160 bool = l >= 0 - for yyj1160 := 0; ; yyj1160++ { - if yyhl1160 { - if yyj1160 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13531,21 +11218,21 @@ func (x *IngressStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1160Slc = r.DecodeBytes(yys1160Slc, true, true) - yys1160 := string(yys1160Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1160 { + switch yys3 { case "loadBalancer": if r.TryDecodeAsNil() { - x.LoadBalancer = pkg2_v1.LoadBalancerStatus{} + x.LoadBalancer = pkg4_v1.LoadBalancerStatus{} } else { - yyv1161 := &x.LoadBalancer - yyv1161.CodecDecodeSelf(d) + yyv4 := &x.LoadBalancer + yyv4.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1160) - } // end switch yys1160 - } // end for yyj1160 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13553,38 +11240,38 @@ func (x *IngressStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1162 int - var yyb1162 bool - var yyhl1162 bool = l >= 0 - yyj1162++ - if yyhl1162 { - yyb1162 = yyj1162 > l + var yyj5 int + var yyb5 bool + var yyhl5 bool = l >= 0 + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb1162 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb1162 { + if yyb5 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LoadBalancer = pkg2_v1.LoadBalancerStatus{} + x.LoadBalancer = pkg4_v1.LoadBalancerStatus{} } else { - yyv1163 := &x.LoadBalancer - yyv1163.CodecDecodeSelf(d) + yyv6 := &x.LoadBalancer + yyv6.CodecDecodeSelf(d) } for { - yyj1162++ - if yyhl1162 { - yyb1162 = yyj1162 > l + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb1162 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb1162 { + if yyb5 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1162-1, "") + z.DecStructFieldNotFound(yyj5-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -13596,36 +11283,36 @@ func (x *IngressRule) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1164 := z.EncBinary() - _ = yym1164 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1165 := !z.EncBinary() - yy2arr1165 := z.EncBasicHandle().StructToArray - var yyq1165 [2]bool - _, _, _ = yysep1165, yyq1165, yy2arr1165 - const yyr1165 bool = false - yyq1165[0] = x.Host != "" - yyq1165[1] = x.IngressRuleValue.HTTP != nil && x.HTTP != nil - var yynn1165 int - if yyr1165 || yy2arr1165 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Host != "" + yyq2[1] = x.IngressRuleValue.HTTP != nil && x.HTTP != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1165 = 0 - for _, b := range yyq1165 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1165++ + yynn2++ } } - r.EncodeMapStart(yynn1165) - yynn1165 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1165[0] { - yym1167 := z.EncBinary() - _ = yym1167 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Host)) @@ -13634,30 +11321,30 @@ func (x *IngressRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1165[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("host")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1168 := z.EncBinary() - _ = yym1168 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Host)) } } } - var yyn1169 bool + var yyn6 bool if x.IngressRuleValue.HTTP == nil { - yyn1169 = true - goto LABEL1169 + yyn6 = true + goto LABEL6 } - LABEL1169: - if yyr1165 || yy2arr1165 { - if yyn1169 { + LABEL6: + if yyr2 || yy2arr2 { + if yyn6 { r.EncodeNil() } else { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1165[1] { + if yyq2[1] { if x.HTTP == nil { r.EncodeNil() } else { @@ -13668,11 +11355,11 @@ func (x *IngressRule) CodecEncodeSelf(e *codec1978.Encoder) { } } } else { - if yyq1165[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("http")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - if yyn1169 { + if yyn6 { r.EncodeNil() } else { if x.HTTP == nil { @@ -13683,7 +11370,7 @@ func (x *IngressRule) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1165 || yy2arr1165 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13696,25 +11383,25 @@ func (x *IngressRule) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1170 := z.DecBinary() - _ = yym1170 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1171 := r.ContainerType() - if yyct1171 == codecSelferValueTypeMap1234 { - yyl1171 := r.ReadMapStart() - if yyl1171 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1171, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1171 == codecSelferValueTypeArray1234 { - yyl1171 := r.ReadArrayStart() - if yyl1171 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1171, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13726,12 +11413,12 @@ func (x *IngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1172Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1172Slc - var yyhl1172 bool = l >= 0 - for yyj1172 := 0; ; yyj1172++ { - if yyhl1172 { - if yyj1172 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13740,15 +11427,21 @@ func (x *IngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1172Slc = r.DecodeBytes(yys1172Slc, true, true) - yys1172 := string(yys1172Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1172 { + switch yys3 { case "host": if r.TryDecodeAsNil() { x.Host = "" } else { - x.Host = string(r.DecodeString()) + yyv4 := &x.Host + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "http": if x.IngressRuleValue.HTTP == nil { @@ -13765,9 +11458,9 @@ func (x *IngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.HTTP.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1172) - } // end switch yys1172 - } // end for yyj1172 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13775,16 +11468,16 @@ func (x *IngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1175 int - var yyb1175 bool - var yyhl1175 bool = l >= 0 - yyj1175++ - if yyhl1175 { - yyb1175 = yyj1175 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1175 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1175 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13792,18 +11485,24 @@ func (x *IngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Host = "" } else { - x.Host = string(r.DecodeString()) + yyv8 := &x.Host + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } if x.IngressRuleValue.HTTP == nil { x.IngressRuleValue.HTTP = new(HTTPIngressRuleValue) } - yyj1175++ - if yyhl1175 { - yyb1175 = yyj1175 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1175 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1175 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13819,17 +11518,17 @@ func (x *IngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { x.HTTP.CodecDecodeSelf(d) } for { - yyj1175++ - if yyhl1175 { - yyb1175 = yyj1175 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1175 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1175 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1175-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -13841,33 +11540,33 @@ func (x *IngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1178 := z.EncBinary() - _ = yym1178 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1179 := !z.EncBinary() - yy2arr1179 := z.EncBasicHandle().StructToArray - var yyq1179 [1]bool - _, _, _ = yysep1179, yyq1179, yy2arr1179 - const yyr1179 bool = false - yyq1179[0] = x.HTTP != nil - var yynn1179 int - if yyr1179 || yy2arr1179 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.HTTP != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1179 = 0 - for _, b := range yyq1179 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1179++ + yynn2++ } } - r.EncodeMapStart(yynn1179) - yynn1179 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1179 || yy2arr1179 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1179[0] { + if yyq2[0] { if x.HTTP == nil { r.EncodeNil() } else { @@ -13877,7 +11576,7 @@ func (x *IngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1179[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("http")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -13888,7 +11587,7 @@ func (x *IngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1179 || yy2arr1179 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -13901,25 +11600,25 @@ func (x *IngressRuleValue) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1181 := z.DecBinary() - _ = yym1181 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1182 := r.ContainerType() - if yyct1182 == codecSelferValueTypeMap1234 { - yyl1182 := r.ReadMapStart() - if yyl1182 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1182, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1182 == codecSelferValueTypeArray1234 { - yyl1182 := r.ReadArrayStart() - if yyl1182 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1182, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -13931,12 +11630,12 @@ func (x *IngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1183Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1183Slc - var yyhl1183 bool = l >= 0 - for yyj1183 := 0; ; yyj1183++ { - if yyhl1183 { - if yyj1183 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -13945,10 +11644,10 @@ func (x *IngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1183Slc = r.DecodeBytes(yys1183Slc, true, true) - yys1183 := string(yys1183Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1183 { + switch yys3 { case "http": if r.TryDecodeAsNil() { if x.HTTP != nil { @@ -13961,9 +11660,9 @@ func (x *IngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { x.HTTP.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1183) - } // end switch yys1183 - } // end for yyj1183 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -13971,16 +11670,16 @@ func (x *IngressRuleValue) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1185 int - var yyb1185 bool - var yyhl1185 bool = l >= 0 - yyj1185++ - if yyhl1185 { - yyb1185 = yyj1185 > l + var yyj5 int + var yyb5 bool + var yyhl5 bool = l >= 0 + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb1185 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb1185 { + if yyb5 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -13996,17 +11695,17 @@ func (x *IngressRuleValue) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) x.HTTP.CodecDecodeSelf(d) } for { - yyj1185++ - if yyhl1185 { - yyb1185 = yyj1185 > l + yyj5++ + if yyhl5 { + yyb5 = yyj5 > l } else { - yyb1185 = r.CheckBreak() + yyb5 = r.CheckBreak() } - if yyb1185 { + if yyb5 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1185-1, "") + z.DecStructFieldNotFound(yyj5-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -14018,36 +11717,36 @@ func (x *HTTPIngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1187 := z.EncBinary() - _ = yym1187 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1188 := !z.EncBinary() - yy2arr1188 := z.EncBasicHandle().StructToArray - var yyq1188 [1]bool - _, _, _ = yysep1188, yyq1188, yy2arr1188 - const yyr1188 bool = false - var yynn1188 int - if yyr1188 || yy2arr1188 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [1]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(1) } else { - yynn1188 = 1 - for _, b := range yyq1188 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1188++ + yynn2++ } } - r.EncodeMapStart(yynn1188) - yynn1188 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1188 || yy2arr1188 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Paths == nil { r.EncodeNil() } else { - yym1190 := z.EncBinary() - _ = yym1190 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceHTTPIngressPath(([]HTTPIngressPath)(x.Paths), e) @@ -14060,15 +11759,15 @@ func (x *HTTPIngressRuleValue) CodecEncodeSelf(e *codec1978.Encoder) { if x.Paths == nil { r.EncodeNil() } else { - yym1191 := z.EncBinary() - _ = yym1191 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceHTTPIngressPath(([]HTTPIngressPath)(x.Paths), e) } } } - if yyr1188 || yy2arr1188 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14081,25 +11780,25 @@ func (x *HTTPIngressRuleValue) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1192 := z.DecBinary() - _ = yym1192 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1193 := r.ContainerType() - if yyct1193 == codecSelferValueTypeMap1234 { - yyl1193 := r.ReadMapStart() - if yyl1193 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1193, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1193 == codecSelferValueTypeArray1234 { - yyl1193 := r.ReadArrayStart() - if yyl1193 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1193, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -14111,12 +11810,12 @@ func (x *HTTPIngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1194Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1194Slc - var yyhl1194 bool = l >= 0 - for yyj1194 := 0; ; yyj1194++ { - if yyhl1194 { - if yyj1194 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -14125,26 +11824,26 @@ func (x *HTTPIngressRuleValue) codecDecodeSelfFromMap(l int, d *codec1978.Decode } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1194Slc = r.DecodeBytes(yys1194Slc, true, true) - yys1194 := string(yys1194Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1194 { + switch yys3 { case "paths": if r.TryDecodeAsNil() { x.Paths = nil } else { - yyv1195 := &x.Paths - yym1196 := z.DecBinary() - _ = yym1196 + yyv4 := &x.Paths + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceHTTPIngressPath((*[]HTTPIngressPath)(yyv1195), d) + h.decSliceHTTPIngressPath((*[]HTTPIngressPath)(yyv4), d) } } default: - z.DecStructFieldNotFound(-1, yys1194) - } // end switch yys1194 - } // end for yyj1194 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -14152,16 +11851,16 @@ func (x *HTTPIngressRuleValue) codecDecodeSelfFromArray(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1197 int - var yyb1197 bool - var yyhl1197 bool = l >= 0 - yyj1197++ - if yyhl1197 { - yyb1197 = yyj1197 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1197 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1197 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14169,26 +11868,26 @@ func (x *HTTPIngressRuleValue) codecDecodeSelfFromArray(l int, d *codec1978.Deco if r.TryDecodeAsNil() { x.Paths = nil } else { - yyv1198 := &x.Paths - yym1199 := z.DecBinary() - _ = yym1199 + yyv7 := &x.Paths + yym8 := z.DecBinary() + _ = yym8 if false { } else { - h.decSliceHTTPIngressPath((*[]HTTPIngressPath)(yyv1198), d) + h.decSliceHTTPIngressPath((*[]HTTPIngressPath)(yyv7), d) } } for { - yyj1197++ - if yyhl1197 { - yyb1197 = yyj1197 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1197 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1197 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1197-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -14200,35 +11899,35 @@ func (x *HTTPIngressPath) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1200 := z.EncBinary() - _ = yym1200 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1201 := !z.EncBinary() - yy2arr1201 := z.EncBasicHandle().StructToArray - var yyq1201 [2]bool - _, _, _ = yysep1201, yyq1201, yy2arr1201 - const yyr1201 bool = false - yyq1201[0] = x.Path != "" - var yynn1201 int - if yyr1201 || yy2arr1201 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Path != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1201 = 1 - for _, b := range yyq1201 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1201++ + yynn2++ } } - r.EncodeMapStart(yynn1201) - yynn1201 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1201 || yy2arr1201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1201[0] { - yym1203 := z.EncBinary() - _ = yym1203 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) @@ -14237,30 +11936,30 @@ func (x *HTTPIngressPath) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1201[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("path")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1204 := z.EncBinary() - _ = yym1204 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Path)) } } } - if yyr1201 || yy2arr1201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1206 := &x.Backend - yy1206.CodecEncodeSelf(e) + yy7 := &x.Backend + yy7.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("backend")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1207 := &x.Backend - yy1207.CodecEncodeSelf(e) + yy9 := &x.Backend + yy9.CodecEncodeSelf(e) } - if yyr1201 || yy2arr1201 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14273,25 +11972,25 @@ func (x *HTTPIngressPath) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1208 := z.DecBinary() - _ = yym1208 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1209 := r.ContainerType() - if yyct1209 == codecSelferValueTypeMap1234 { - yyl1209 := r.ReadMapStart() - if yyl1209 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1209, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1209 == codecSelferValueTypeArray1234 { - yyl1209 := r.ReadArrayStart() - if yyl1209 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1209, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -14303,12 +12002,12 @@ func (x *HTTPIngressPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1210Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1210Slc - var yyhl1210 bool = l >= 0 - for yyj1210 := 0; ; yyj1210++ { - if yyhl1210 { - if yyj1210 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -14317,27 +12016,33 @@ func (x *HTTPIngressPath) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1210Slc = r.DecodeBytes(yys1210Slc, true, true) - yys1210 := string(yys1210Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1210 { + switch yys3 { case "path": if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv4 := &x.Path + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "backend": if r.TryDecodeAsNil() { x.Backend = IngressBackend{} } else { - yyv1212 := &x.Backend - yyv1212.CodecDecodeSelf(d) + yyv6 := &x.Backend + yyv6.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1210) - } // end switch yys1210 - } // end for yyj1210 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -14345,16 +12050,16 @@ func (x *HTTPIngressPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1213 int - var yyb1213 bool - var yyhl1213 bool = l >= 0 - yyj1213++ - if yyhl1213 { - yyb1213 = yyj1213 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1213 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1213 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14362,15 +12067,21 @@ func (x *HTTPIngressPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Path = "" } else { - x.Path = string(r.DecodeString()) + yyv8 := &x.Path + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } - yyj1213++ - if yyhl1213 { - yyb1213 = yyj1213 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1213 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1213 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14378,21 +12089,21 @@ func (x *HTTPIngressPath) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Backend = IngressBackend{} } else { - yyv1215 := &x.Backend - yyv1215.CodecDecodeSelf(d) + yyv10 := &x.Backend + yyv10.CodecDecodeSelf(d) } for { - yyj1213++ - if yyhl1213 { - yyb1213 = yyj1213 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1213 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1213 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1213-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -14404,33 +12115,33 @@ func (x *IngressBackend) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1216 := z.EncBinary() - _ = yym1216 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1217 := !z.EncBinary() - yy2arr1217 := z.EncBasicHandle().StructToArray - var yyq1217 [2]bool - _, _, _ = yysep1217, yyq1217, yy2arr1217 - const yyr1217 bool = false - var yynn1217 int - if yyr1217 || yy2arr1217 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1217 = 2 - for _, b := range yyq1217 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1217++ + yynn2++ } } - r.EncodeMapStart(yynn1217) - yynn1217 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1217 || yy2arr1217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1219 := z.EncBinary() - _ = yym1219 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) @@ -14439,41 +12150,41 @@ func (x *IngressBackend) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("serviceName")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1220 := z.EncBinary() - _ = yym1220 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.ServiceName)) } } - if yyr1217 || yy2arr1217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1222 := &x.ServicePort - yym1223 := z.EncBinary() - _ = yym1223 + yy7 := &x.ServicePort + yym8 := z.EncBinary() + _ = yym8 if false { - } else if z.HasExtensions() && z.EncExt(yy1222) { - } else if !yym1223 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1222) + } else if z.HasExtensions() && z.EncExt(yy7) { + } else if !yym8 && z.IsJSONHandle() { + z.EncJSONMarshal(yy7) } else { - z.EncFallback(yy1222) + z.EncFallback(yy7) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("servicePort")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1224 := &x.ServicePort - yym1225 := z.EncBinary() - _ = yym1225 + yy9 := &x.ServicePort + yym10 := z.EncBinary() + _ = yym10 if false { - } else if z.HasExtensions() && z.EncExt(yy1224) { - } else if !yym1225 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1224) + } else if z.HasExtensions() && z.EncExt(yy9) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(yy9) } else { - z.EncFallback(yy1224) + z.EncFallback(yy9) } } - if yyr1217 || yy2arr1217 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -14486,25 +12197,25 @@ func (x *IngressBackend) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1226 := z.DecBinary() - _ = yym1226 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1227 := r.ContainerType() - if yyct1227 == codecSelferValueTypeMap1234 { - yyl1227 := r.ReadMapStart() - if yyl1227 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1227, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1227 == codecSelferValueTypeArray1234 { - yyl1227 := r.ReadArrayStart() - if yyl1227 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1227, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -14516,12 +12227,12 @@ func (x *IngressBackend) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1228Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1228Slc - var yyhl1228 bool = l >= 0 - for yyj1228 := 0; ; yyj1228++ { - if yyhl1228 { - if yyj1228 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -14530,35 +12241,41 @@ func (x *IngressBackend) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1228Slc = r.DecodeBytes(yys1228Slc, true, true) - yys1228 := string(yys1228Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1228 { + switch yys3 { case "serviceName": if r.TryDecodeAsNil() { x.ServiceName = "" } else { - x.ServiceName = string(r.DecodeString()) + yyv4 := &x.ServiceName + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "servicePort": if r.TryDecodeAsNil() { x.ServicePort = pkg5_intstr.IntOrString{} } else { - yyv1230 := &x.ServicePort - yym1231 := z.DecBinary() - _ = yym1231 + yyv6 := &x.ServicePort + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv1230) { - } else if !yym1231 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1230) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv1230, false) + z.DecFallback(yyv6, false) } } default: - z.DecStructFieldNotFound(-1, yys1228) - } // end switch yys1228 - } // end for yyj1228 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -14566,16 +12283,16 @@ func (x *IngressBackend) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1232 int - var yyb1232 bool - var yyhl1232 bool = l >= 0 - yyj1232++ - if yyhl1232 { - yyb1232 = yyj1232 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1232 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1232 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14583,15 +12300,21 @@ func (x *IngressBackend) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ServiceName = "" } else { - x.ServiceName = string(r.DecodeString()) + yyv9 := &x.ServiceName + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*string)(yyv9)) = r.DecodeString() + } } - yyj1232++ - if yyhl1232 { - yyb1232 = yyj1232 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1232 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1232 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -14599,328 +12322,29 @@ func (x *IngressBackend) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ServicePort = pkg5_intstr.IntOrString{} } else { - yyv1234 := &x.ServicePort - yym1235 := z.DecBinary() - _ = yym1235 - if false { - } else if z.HasExtensions() && z.DecExt(yyv1234) { - } else if !yym1235 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1234) - } else { - z.DecFallback(yyv1234, false) - } - } - for { - yyj1232++ - if yyhl1232 { - yyb1232 = yyj1232 > l - } else { - yyb1232 = r.CheckBreak() - } - if yyb1232 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1232-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 { - yym1236 := z.EncBinary() - _ = yym1236 + yyv11 := &x.ServicePort + yym12 := z.DecBinary() + _ = yym12 if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep1237 := !z.EncBinary() - yy2arr1237 := z.EncBasicHandle().StructToArray - var yyq1237 [4]bool - _, _, _ = yysep1237, yyq1237, yy2arr1237 - const yyr1237 bool = false - yyq1237[0] = x.Kind != "" - yyq1237[1] = x.APIVersion != "" - var yynn1237 int - if yyr1237 || yy2arr1237 { - r.EncodeArrayStart(4) - } else { - yynn1237 = 2 - for _, b := range yyq1237 { - if b { - yynn1237++ - } - } - r.EncodeMapStart(yynn1237) - yynn1237 = 0 - } - if yyr1237 || yy2arr1237 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1237[0] { - yym1239 := z.EncBinary() - _ = yym1239 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1237[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1240 := z.EncBinary() - _ = yym1240 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr1237 || yy2arr1237 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1237[1] { - yym1242 := z.EncBinary() - _ = yym1242 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq1237[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1243 := z.EncBinary() - _ = yym1243 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr1237 || yy2arr1237 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1245 := z.EncBinary() - _ = yym1245 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("export")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1246 := z.EncBinary() - _ = yym1246 - if false { - } else { - r.EncodeBool(bool(x.Export)) - } - } - if yyr1237 || yy2arr1237 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1248 := z.EncBinary() - _ = yym1248 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("exact")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1249 := z.EncBinary() - _ = yym1249 - if false { - } else { - r.EncodeBool(bool(x.Exact)) - } - } - if yyr1237 || yy2arr1237 { - 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 - yym1250 := z.DecBinary() - _ = yym1250 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct1251 := r.ContainerType() - if yyct1251 == codecSelferValueTypeMap1234 { - yyl1251 := r.ReadMapStart() - if yyl1251 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl1251, d) - } - } else if yyct1251 == codecSelferValueTypeArray1234 { - yyl1251 := r.ReadArrayStart() - if yyl1251 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl1251, 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 yys1252Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1252Slc - var yyhl1252 bool = l >= 0 - for yyj1252 := 0; ; yyj1252++ { - if yyhl1252 { - if yyj1252 >= l { - break - } + } else if z.HasExtensions() && z.DecExt(yyv11) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv11) } else { - if r.CheckBreak() { - break - } + z.DecFallback(yyv11, false) } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1252Slc = r.DecodeBytes(yys1252Slc, true, true) - yys1252 := string(yys1252Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1252 { - 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, yys1252) - } // end switch yys1252 - } // end for yyj1252 - 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 yyj1257 int - var yyb1257 bool - var yyhl1257 bool = l >= 0 - yyj1257++ - if yyhl1257 { - yyb1257 = yyj1257 > l - } else { - yyb1257 = r.CheckBreak() - } - if yyb1257 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj1257++ - if yyhl1257 { - yyb1257 = yyj1257 > l - } else { - yyb1257 = r.CheckBreak() - } - if yyb1257 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj1257++ - if yyhl1257 { - yyb1257 = yyj1257 > l - } else { - yyb1257 = r.CheckBreak() - } - if yyb1257 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Export = false - } else { - x.Export = bool(r.DecodeBool()) - } - yyj1257++ - if yyhl1257 { - yyb1257 = yyj1257 > l - } else { - yyb1257 = r.CheckBreak() - } - if yyb1257 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Exact = false - } else { - x.Exact = bool(r.DecodeBool()) } for { - yyj1257++ - if yyhl1257 { - yyb1257 = yyj1257 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1257 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1257 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1257-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -14932,39 +12356,39 @@ func (x *ReplicaSet) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1262 := z.EncBinary() - _ = yym1262 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1263 := !z.EncBinary() - yy2arr1263 := z.EncBasicHandle().StructToArray - var yyq1263 [5]bool - _, _, _ = yysep1263, yyq1263, yy2arr1263 - const yyr1263 bool = false - yyq1263[0] = x.Kind != "" - yyq1263[1] = x.APIVersion != "" - yyq1263[2] = true - yyq1263[3] = true - yyq1263[4] = true - var yynn1263 int - if yyr1263 || yy2arr1263 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn1263 = 0 - for _, b := range yyq1263 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1263++ + yynn2++ } } - r.EncodeMapStart(yynn1263) - yynn1263 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1263 || yy2arr1263 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1263[0] { - yym1265 := z.EncBinary() - _ = yym1265 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -14973,23 +12397,23 @@ func (x *ReplicaSet) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1263[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1266 := z.EncBinary() - _ = yym1266 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1263 || yy2arr1263 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1263[1] { - yym1268 := z.EncBinary() - _ = yym1268 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -14998,70 +12422,82 @@ func (x *ReplicaSet) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1263[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1269 := z.EncBinary() - _ = yym1269 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1263 || yy2arr1263 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1263[2] { - yy1271 := &x.ObjectMeta - yy1271.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq1263[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1272 := &x.ObjectMeta - yy1272.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr1263 || yy2arr1263 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1263[3] { - yy1274 := &x.Spec - yy1274.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1263[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1275 := &x.Spec - yy1275.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr1263 || yy2arr1263 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1263[4] { - yy1277 := &x.Status - yy1277.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1263[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1278 := &x.Status - yy1278.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr1263 || yy2arr1263 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -15074,25 +12510,25 @@ func (x *ReplicaSet) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1279 := z.DecBinary() - _ = yym1279 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1280 := r.ContainerType() - if yyct1280 == codecSelferValueTypeMap1234 { - yyl1280 := r.ReadMapStart() - if yyl1280 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1280, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1280 == codecSelferValueTypeArray1234 { - yyl1280 := r.ReadArrayStart() - if yyl1280 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1280, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15104,12 +12540,12 @@ func (x *ReplicaSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1281Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1281Slc - var yyhl1281 bool = l >= 0 - for yyj1281 := 0; ; yyj1281++ { - if yyhl1281 { - if yyj1281 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15118,47 +12554,65 @@ func (x *ReplicaSet) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1281Slc = r.DecodeBytes(yys1281Slc, true, true) - yys1281 := string(yys1281Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1281 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1284 := &x.ObjectMeta - yyv1284.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = ReplicaSetSpec{} } else { - yyv1285 := &x.Spec - yyv1285.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = ReplicaSetStatus{} } else { - yyv1286 := &x.Status - yyv1286.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1281) - } // end switch yys1281 - } // end for yyj1281 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -15166,16 +12620,16 @@ func (x *ReplicaSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1287 int - var yyb1287 bool - var yyhl1287 bool = l >= 0 - yyj1287++ - if yyhl1287 { - yyb1287 = yyj1287 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1287 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1287 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15183,15 +12637,21 @@ func (x *ReplicaSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1287++ - if yyhl1287 { - yyb1287 = yyj1287 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1287 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1287 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15199,32 +12659,44 @@ func (x *ReplicaSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj1287++ - if yyhl1287 { - yyb1287 = yyj1287 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1287 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1287 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1290 := &x.ObjectMeta - yyv1290.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj1287++ - if yyhl1287 { - yyb1287 = yyj1287 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1287 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1287 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15232,16 +12704,16 @@ func (x *ReplicaSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = ReplicaSetSpec{} } else { - yyv1291 := &x.Spec - yyv1291.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj1287++ - if yyhl1287 { - yyb1287 = yyj1287 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1287 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1287 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15249,21 +12721,21 @@ func (x *ReplicaSet) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Status = ReplicaSetStatus{} } else { - yyv1292 := &x.Status - yyv1292.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj1287++ - if yyhl1287 { - yyb1287 = yyj1287 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1287 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1287 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1287-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -15275,37 +12747,37 @@ func (x *ReplicaSetList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1293 := z.EncBinary() - _ = yym1293 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1294 := !z.EncBinary() - yy2arr1294 := z.EncBasicHandle().StructToArray - var yyq1294 [4]bool - _, _, _ = yysep1294, yyq1294, yy2arr1294 - const yyr1294 bool = false - yyq1294[0] = x.Kind != "" - yyq1294[1] = x.APIVersion != "" - yyq1294[2] = true - var yynn1294 int - if yyr1294 || yy2arr1294 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1294 = 1 - for _, b := range yyq1294 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1294++ + yynn2++ } } - r.EncodeMapStart(yynn1294) - yynn1294 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1294 || yy2arr1294 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1294[0] { - yym1296 := z.EncBinary() - _ = yym1296 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -15314,23 +12786,23 @@ func (x *ReplicaSetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1294[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1297 := z.EncBinary() - _ = yym1297 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1294 || yy2arr1294 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1294[1] { - yym1299 := z.EncBinary() - _ = yym1299 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -15339,54 +12811,54 @@ func (x *ReplicaSetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1294[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1300 := z.EncBinary() - _ = yym1300 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1294 || yy2arr1294 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1294[2] { - yy1302 := &x.ListMeta - yym1303 := z.EncBinary() - _ = yym1303 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy1302) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy1302) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1294[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1304 := &x.ListMeta - yym1305 := z.EncBinary() - _ = yym1305 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy1304) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy1304) + z.EncFallback(yy12) } } } - if yyr1294 || yy2arr1294 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym1307 := z.EncBinary() - _ = yym1307 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceReplicaSet(([]ReplicaSet)(x.Items), e) @@ -15399,15 +12871,15 @@ func (x *ReplicaSetList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym1308 := z.EncBinary() - _ = yym1308 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceReplicaSet(([]ReplicaSet)(x.Items), e) } } } - if yyr1294 || yy2arr1294 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -15420,25 +12892,25 @@ func (x *ReplicaSetList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1309 := z.DecBinary() - _ = yym1309 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1310 := r.ContainerType() - if yyct1310 == codecSelferValueTypeMap1234 { - yyl1310 := r.ReadMapStart() - if yyl1310 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1310, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1310 == codecSelferValueTypeArray1234 { - yyl1310 := r.ReadArrayStart() - if yyl1310 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1310, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15450,12 +12922,12 @@ func (x *ReplicaSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1311Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1311Slc - var yyhl1311 bool = l >= 0 - for yyj1311 := 0; ; yyj1311++ { - if yyhl1311 { - if yyj1311 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15464,51 +12936,63 @@ func (x *ReplicaSetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1311Slc = r.DecodeBytes(yys1311Slc, true, true) - yys1311 := string(yys1311Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1311 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1314 := &x.ListMeta - yym1315 := z.DecBinary() - _ = yym1315 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv1314) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv1314, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1316 := &x.Items - yym1317 := z.DecBinary() - _ = yym1317 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceReplicaSet((*[]ReplicaSet)(yyv1316), d) + h.decSliceReplicaSet((*[]ReplicaSet)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys1311) - } // end switch yys1311 - } // end for yyj1311 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -15516,16 +13000,16 @@ func (x *ReplicaSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1318 int - var yyb1318 bool - var yyhl1318 bool = l >= 0 - yyj1318++ - if yyhl1318 { - yyb1318 = yyj1318 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1318 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1318 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15533,15 +13017,21 @@ func (x *ReplicaSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1318++ - if yyhl1318 { - yyb1318 = yyj1318 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1318 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1318 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15549,38 +13039,44 @@ func (x *ReplicaSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj1318++ - if yyhl1318 { - yyb1318 = yyj1318 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1318 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1318 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1321 := &x.ListMeta - yym1322 := z.DecBinary() - _ = yym1322 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv1321) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv1321, false) + z.DecFallback(yyv17, false) } } - yyj1318++ - if yyhl1318 { - yyb1318 = yyj1318 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1318 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1318 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15588,26 +13084,26 @@ func (x *ReplicaSetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1323 := &x.Items - yym1324 := z.DecBinary() - _ = yym1324 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceReplicaSet((*[]ReplicaSet)(yyv1323), d) + h.decSliceReplicaSet((*[]ReplicaSet)(yyv19), d) } } for { - yyj1318++ - if yyhl1318 { - yyb1318 = yyj1318 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1318 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1318 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1318-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -15619,73 +13115,73 @@ func (x *ReplicaSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1325 := z.EncBinary() - _ = yym1325 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1326 := !z.EncBinary() - yy2arr1326 := z.EncBasicHandle().StructToArray - var yyq1326 [4]bool - _, _, _ = yysep1326, yyq1326, yy2arr1326 - const yyr1326 bool = false - yyq1326[0] = x.Replicas != nil - yyq1326[1] = x.MinReadySeconds != 0 - yyq1326[2] = x.Selector != nil - yyq1326[3] = true - var yynn1326 int - if yyr1326 || yy2arr1326 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Replicas != nil + yyq2[1] = x.MinReadySeconds != 0 + yyq2[2] = x.Selector != nil + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1326 = 0 - for _, b := range yyq1326 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1326++ + yynn2++ } } - r.EncodeMapStart(yynn1326) - yynn1326 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1326 || yy2arr1326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1326[0] { + if yyq2[0] { if x.Replicas == nil { r.EncodeNil() } else { - yy1328 := *x.Replicas - yym1329 := z.EncBinary() - _ = yym1329 + yy4 := *x.Replicas + yym5 := z.EncBinary() + _ = yym5 if false { } else { - r.EncodeInt(int64(yy1328)) + r.EncodeInt(int64(yy4)) } } } else { r.EncodeNil() } } else { - if yyq1326[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Replicas == nil { r.EncodeNil() } else { - yy1330 := *x.Replicas - yym1331 := z.EncBinary() - _ = yym1331 + yy6 := *x.Replicas + yym7 := z.EncBinary() + _ = yym7 if false { } else { - r.EncodeInt(int64(yy1330)) + r.EncodeInt(int64(yy6)) } } } } - if yyr1326 || yy2arr1326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1326[1] { - yym1333 := z.EncBinary() - _ = yym1333 + if yyq2[1] { + yym9 := z.EncBinary() + _ = yym9 if false { } else { r.EncodeInt(int64(x.MinReadySeconds)) @@ -15694,26 +13190,26 @@ func (x *ReplicaSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1326[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("minReadySeconds")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1334 := z.EncBinary() - _ = yym1334 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.MinReadySeconds)) } } } - if yyr1326 || yy2arr1326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1326[2] { + if yyq2[2] { if x.Selector == nil { r.EncodeNil() } else { - yym1336 := z.EncBinary() - _ = yym1336 + yym12 := z.EncBinary() + _ = yym12 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -15724,15 +13220,15 @@ func (x *ReplicaSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1326[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("selector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Selector == nil { r.EncodeNil() } else { - yym1337 := z.EncBinary() - _ = yym1337 + yym13 := z.EncBinary() + _ = yym13 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -15741,24 +13237,24 @@ func (x *ReplicaSetSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1326 || yy2arr1326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1326[3] { - yy1339 := &x.Template - yy1339.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Template + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1326[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("template")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1340 := &x.Template - yy1340.CodecEncodeSelf(e) + yy17 := &x.Template + yy17.CodecEncodeSelf(e) } } - if yyr1326 || yy2arr1326 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -15771,25 +13267,25 @@ func (x *ReplicaSetSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1341 := z.DecBinary() - _ = yym1341 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1342 := r.ContainerType() - if yyct1342 == codecSelferValueTypeMap1234 { - yyl1342 := r.ReadMapStart() - if yyl1342 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1342, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1342 == codecSelferValueTypeArray1234 { - yyl1342 := r.ReadArrayStart() - if yyl1342 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1342, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -15801,12 +13297,12 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1343Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1343Slc - var yyhl1343 bool = l >= 0 - for yyj1343 := 0; ; yyj1343++ { - if yyhl1343 { - if yyj1343 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -15815,10 +13311,10 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1343Slc = r.DecodeBytes(yys1343Slc, true, true) - yys1343 := string(yys1343Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1343 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { if x.Replicas != nil { @@ -15828,8 +13324,8 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if x.Replicas == nil { x.Replicas = new(int32) } - yym1345 := z.DecBinary() - _ = yym1345 + yym5 := z.DecBinary() + _ = yym5 if false { } else { *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) @@ -15839,7 +13335,13 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.MinReadySeconds = 0 } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) + yyv6 := &x.MinReadySeconds + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } case "selector": if r.TryDecodeAsNil() { @@ -15848,10 +13350,10 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) + x.Selector = new(pkg1_v1.LabelSelector) } - yym1348 := z.DecBinary() - _ = yym1348 + yym9 := z.DecBinary() + _ = yym9 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { @@ -15860,15 +13362,15 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } case "template": if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} + x.Template = pkg4_v1.PodTemplateSpec{} } else { - yyv1349 := &x.Template - yyv1349.CodecDecodeSelf(d) + yyv10 := &x.Template + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1343) - } // end switch yys1343 - } // end for yyj1343 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -15876,16 +13378,16 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1350 int - var yyb1350 bool - var yyhl1350 bool = l >= 0 - yyj1350++ - if yyhl1350 { - yyb1350 = yyj1350 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1350 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1350 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15898,20 +13400,20 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if x.Replicas == nil { x.Replicas = new(int32) } - yym1352 := z.DecBinary() - _ = yym1352 + yym13 := z.DecBinary() + _ = yym13 if false { } else { *((*int32)(x.Replicas)) = int32(r.DecodeInt(32)) } } - yyj1350++ - if yyhl1350 { - yyb1350 = yyj1350 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1350 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1350 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15919,15 +13421,21 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.MinReadySeconds = 0 } else { - x.MinReadySeconds = int32(r.DecodeInt(32)) + yyv14 := &x.MinReadySeconds + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } } - yyj1350++ - if yyhl1350 { - yyb1350 = yyj1350 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1350 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1350 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -15938,45 +13446,45 @@ func (x *ReplicaSetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.Selector == nil { - x.Selector = new(pkg1_unversioned.LabelSelector) + x.Selector = new(pkg1_v1.LabelSelector) } - yym1355 := z.DecBinary() - _ = yym1355 + yym17 := z.DecBinary() + _ = yym17 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { z.DecFallback(x.Selector, false) } } - yyj1350++ - if yyhl1350 { - yyb1350 = yyj1350 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1350 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1350 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.Template = pkg2_v1.PodTemplateSpec{} + x.Template = pkg4_v1.PodTemplateSpec{} } else { - yyv1356 := &x.Template - yyv1356.CodecDecodeSelf(d) + yyv18 := &x.Template + yyv18.CodecDecodeSelf(d) } for { - yyj1350++ - if yyhl1350 { - yyb1350 = yyj1350 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1350 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1350 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1350-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -15988,38 +13496,38 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1357 := z.EncBinary() - _ = yym1357 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1358 := !z.EncBinary() - yy2arr1358 := z.EncBasicHandle().StructToArray - var yyq1358 [6]bool - _, _, _ = yysep1358, yyq1358, yy2arr1358 - const yyr1358 bool = false - yyq1358[1] = x.FullyLabeledReplicas != 0 - yyq1358[2] = x.ReadyReplicas != 0 - yyq1358[3] = x.AvailableReplicas != 0 - yyq1358[4] = x.ObservedGeneration != 0 - yyq1358[5] = len(x.Conditions) != 0 - var yynn1358 int - if yyr1358 || yy2arr1358 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.FullyLabeledReplicas != 0 + yyq2[2] = x.ReadyReplicas != 0 + yyq2[3] = x.AvailableReplicas != 0 + yyq2[4] = x.ObservedGeneration != 0 + yyq2[5] = len(x.Conditions) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn1358 = 1 - for _, b := range yyq1358 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1358++ + yynn2++ } } - r.EncodeMapStart(yynn1358) - yynn1358 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1360 := z.EncBinary() - _ = yym1360 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Replicas)) @@ -16028,18 +13536,18 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("replicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1361 := z.EncBinary() - _ = yym1361 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Replicas)) } } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[1] { - yym1363 := z.EncBinary() - _ = yym1363 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.FullyLabeledReplicas)) @@ -16048,23 +13556,23 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1358[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fullyLabeledReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1364 := z.EncBinary() - _ = yym1364 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.FullyLabeledReplicas)) } } } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[2] { - yym1366 := z.EncBinary() - _ = yym1366 + if yyq2[2] { + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.ReadyReplicas)) @@ -16073,23 +13581,23 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1358[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readyReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1367 := z.EncBinary() - _ = yym1367 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeInt(int64(x.ReadyReplicas)) } } } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[3] { - yym1369 := z.EncBinary() - _ = yym1369 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeInt(int64(x.AvailableReplicas)) @@ -16098,23 +13606,23 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1358[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("availableReplicas")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1370 := z.EncBinary() - _ = yym1370 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeInt(int64(x.AvailableReplicas)) } } } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[4] { - yym1372 := z.EncBinary() - _ = yym1372 + if yyq2[4] { + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeInt(int64(x.ObservedGeneration)) @@ -16123,26 +13631,26 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq1358[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1373 := z.EncBinary() - _ = yym1373 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeInt(int64(x.ObservedGeneration)) } } } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1358[5] { + if yyq2[5] { if x.Conditions == nil { r.EncodeNil() } else { - yym1375 := z.EncBinary() - _ = yym1375 + yym19 := z.EncBinary() + _ = yym19 if false { } else { h.encSliceReplicaSetCondition(([]ReplicaSetCondition)(x.Conditions), e) @@ -16152,15 +13660,15 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1358[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("conditions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Conditions == nil { r.EncodeNil() } else { - yym1376 := z.EncBinary() - _ = yym1376 + yym20 := z.EncBinary() + _ = yym20 if false { } else { h.encSliceReplicaSetCondition(([]ReplicaSetCondition)(x.Conditions), e) @@ -16168,7 +13676,7 @@ func (x *ReplicaSetStatus) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1358 || yy2arr1358 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -16181,25 +13689,25 @@ func (x *ReplicaSetStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1377 := z.DecBinary() - _ = yym1377 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1378 := r.ContainerType() - if yyct1378 == codecSelferValueTypeMap1234 { - yyl1378 := r.ReadMapStart() - if yyl1378 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1378, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1378 == codecSelferValueTypeArray1234 { - yyl1378 := r.ReadArrayStart() - if yyl1378 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1378, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -16211,12 +13719,12 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1379Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1379Slc - var yyhl1379 bool = l >= 0 - for yyj1379 := 0; ; yyj1379++ { - if yyhl1379 { - if yyj1379 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -16225,56 +13733,86 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1379Slc = r.DecodeBytes(yys1379Slc, true, true) - yys1379 := string(yys1379Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1379 { + switch yys3 { case "replicas": if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv4 := &x.Replicas + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "fullyLabeledReplicas": if r.TryDecodeAsNil() { x.FullyLabeledReplicas = 0 } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) + yyv6 := &x.FullyLabeledReplicas + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } case "readyReplicas": if r.TryDecodeAsNil() { x.ReadyReplicas = 0 } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) + yyv8 := &x.ReadyReplicas + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } case "availableReplicas": if r.TryDecodeAsNil() { x.AvailableReplicas = 0 } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) + yyv10 := &x.AvailableReplicas + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } } case "observedGeneration": if r.TryDecodeAsNil() { x.ObservedGeneration = 0 } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) + yyv12 := &x.ObservedGeneration + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int64)(yyv12)) = int64(r.DecodeInt(64)) + } } case "conditions": if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv1385 := &x.Conditions - yym1386 := z.DecBinary() - _ = yym1386 + yyv14 := &x.Conditions + yym15 := z.DecBinary() + _ = yym15 if false { } else { - h.decSliceReplicaSetCondition((*[]ReplicaSetCondition)(yyv1385), d) + h.decSliceReplicaSetCondition((*[]ReplicaSetCondition)(yyv14), d) } } default: - z.DecStructFieldNotFound(-1, yys1379) - } // end switch yys1379 - } // end for yyj1379 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -16282,16 +13820,16 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1387 int - var yyb1387 bool - var yyhl1387 bool = l >= 0 - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16299,15 +13837,21 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Replicas = 0 } else { - x.Replicas = int32(r.DecodeInt(32)) + yyv17 := &x.Replicas + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int32)(yyv17)) = int32(r.DecodeInt(32)) + } } - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16315,15 +13859,21 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.FullyLabeledReplicas = 0 } else { - x.FullyLabeledReplicas = int32(r.DecodeInt(32)) + yyv19 := &x.FullyLabeledReplicas + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*int32)(yyv19)) = int32(r.DecodeInt(32)) + } } - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16331,15 +13881,21 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ReadyReplicas = 0 } else { - x.ReadyReplicas = int32(r.DecodeInt(32)) + yyv21 := &x.ReadyReplicas + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16347,15 +13903,21 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.AvailableReplicas = 0 } else { - x.AvailableReplicas = int32(r.DecodeInt(32)) + yyv23 := &x.AvailableReplicas + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } } - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16363,15 +13925,21 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.ObservedGeneration = 0 } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) + yyv25 := &x.ObservedGeneration + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int64)(yyv25)) = int64(r.DecodeInt(64)) + } } - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16379,26 +13947,26 @@ func (x *ReplicaSetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Conditions = nil } else { - yyv1393 := &x.Conditions - yym1394 := z.DecBinary() - _ = yym1394 + yyv27 := &x.Conditions + yym28 := z.DecBinary() + _ = yym28 if false { } else { - h.decSliceReplicaSetCondition((*[]ReplicaSetCondition)(yyv1393), d) + h.decSliceReplicaSetCondition((*[]ReplicaSetCondition)(yyv27), d) } } for { - yyj1387++ - if yyhl1387 { - yyb1387 = yyj1387 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb1387 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb1387 { + if yyb16 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1387-1, "") + z.DecStructFieldNotFound(yyj16-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -16407,8 +13975,8 @@ func (x ReplicaSetConditionType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1395 := z.EncBinary() - _ = yym1395 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -16420,8 +13988,8 @@ func (x *ReplicaSetConditionType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1396 := z.DecBinary() - _ = yym1396 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -16436,33 +14004,33 @@ func (x *ReplicaSetCondition) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1397 := z.EncBinary() - _ = yym1397 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1398 := !z.EncBinary() - yy2arr1398 := z.EncBasicHandle().StructToArray - var yyq1398 [5]bool - _, _, _ = yysep1398, yyq1398, yy2arr1398 - const yyr1398 bool = false - yyq1398[2] = true - yyq1398[3] = x.Reason != "" - yyq1398[4] = x.Message != "" - var yynn1398 int - if yyr1398 || yy2arr1398 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[2] = true + yyq2[3] = x.Reason != "" + yyq2[4] = x.Message != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn1398 = 2 - for _, b := range yyq1398 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1398++ + yynn2++ } } - r.EncodeMapStart(yynn1398) - yynn1398 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Type.CodecEncodeSelf(e) } else { @@ -16471,69 +14039,59 @@ func (x *ReplicaSetCondition) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Type.CodecEncodeSelf(e) } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1401 := z.EncBinary() - _ = yym1401 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } + yysf7 := &x.Status + yysf7.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1402 := z.EncBinary() - _ = yym1402 - if false { - } else if z.HasExtensions() && z.EncExt(x.Status) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Status)) - } + yysf8 := &x.Status + yysf8.CodecEncodeSelf(e) } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1398[2] { - yy1404 := &x.LastTransitionTime - yym1405 := z.EncBinary() - _ = yym1405 + if yyq2[2] { + yy10 := &x.LastTransitionTime + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy1404) { - } else if yym1405 { - z.EncBinaryMarshal(yy1404) - } else if !yym1405 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1404) + } else if z.HasExtensions() && z.EncExt(yy10) { + } else if yym11 { + z.EncBinaryMarshal(yy10) + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(yy10) } else { - z.EncFallback(yy1404) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1398[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("lastTransitionTime")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1406 := &x.LastTransitionTime - yym1407 := z.EncBinary() - _ = yym1407 + yy12 := &x.LastTransitionTime + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy1406) { - } else if yym1407 { - z.EncBinaryMarshal(yy1406) - } else if !yym1407 && z.IsJSONHandle() { - z.EncJSONMarshal(yy1406) + } else if z.HasExtensions() && z.EncExt(yy12) { + } else if yym13 { + z.EncBinaryMarshal(yy12) + } else if !yym13 && z.IsJSONHandle() { + z.EncJSONMarshal(yy12) } else { - z.EncFallback(yy1406) + z.EncFallback(yy12) } } } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1398[3] { - yym1409 := z.EncBinary() - _ = yym1409 + if yyq2[3] { + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) @@ -16542,23 +14100,23 @@ func (x *ReplicaSetCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1398[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("reason")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1410 := z.EncBinary() - _ = yym1410 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Reason)) } } } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1398[4] { - yym1412 := z.EncBinary() - _ = yym1412 + if yyq2[4] { + yym18 := z.EncBinary() + _ = yym18 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) @@ -16567,19 +14125,19 @@ func (x *ReplicaSetCondition) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1398[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("message")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1413 := z.EncBinary() - _ = yym1413 + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Message)) } } } - if yyr1398 || yy2arr1398 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -16592,25 +14150,25 @@ func (x *ReplicaSetCondition) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1414 := z.DecBinary() - _ = yym1414 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1415 := r.ContainerType() - if yyct1415 == codecSelferValueTypeMap1234 { - yyl1415 := r.ReadMapStart() - if yyl1415 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1415, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1415 == codecSelferValueTypeArray1234 { - yyl1415 := r.ReadArrayStart() - if yyl1415 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1415, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -16622,12 +14180,12 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1416Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1416Slc - var yyhl1416 bool = l >= 0 - for yyj1416 := 0; ; yyj1416++ { - if yyhl1416 { - if yyj1416 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -16636,55 +14194,69 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1416Slc = r.DecodeBytes(yys1416Slc, true, true) - yys1416 := string(yys1416Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1416 { + switch yys3 { case "type": if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ReplicaSetConditionType(r.DecodeString()) + yyv4 := &x.Type + yyv4.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) + yyv5 := &x.Status + yyv5.CodecDecodeSelf(d) } case "lastTransitionTime": if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv1419 := &x.LastTransitionTime - yym1420 := z.DecBinary() - _ = yym1420 + yyv6 := &x.LastTransitionTime + yym7 := z.DecBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.DecExt(yyv1419) { - } else if yym1420 { - z.DecBinaryUnmarshal(yyv1419) - } else if !yym1420 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1419) + } else if z.HasExtensions() && z.DecExt(yyv6) { + } else if yym7 { + z.DecBinaryUnmarshal(yyv6) + } else if !yym7 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv6) } else { - z.DecFallback(yyv1419, false) + z.DecFallback(yyv6, false) } } case "reason": if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv8 := &x.Reason + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "message": if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv10 := &x.Message + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys1416) - } // end switch yys1416 - } // end for yyj1416 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -16692,16 +14264,16 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1423 int - var yyb1423 bool - var yyhl1423 bool = l >= 0 - yyj1423++ - if yyhl1423 { - yyb1423 = yyj1423 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1423 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1423 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16709,15 +14281,16 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Type = "" } else { - x.Type = ReplicaSetConditionType(r.DecodeString()) + yyv13 := &x.Type + yyv13.CodecDecodeSelf(d) } - yyj1423++ - if yyhl1423 { - yyb1423 = yyj1423 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1423 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1423 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16725,42 +14298,43 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Status = "" } else { - x.Status = pkg2_v1.ConditionStatus(r.DecodeString()) + yyv14 := &x.Status + yyv14.CodecDecodeSelf(d) } - yyj1423++ - if yyhl1423 { - yyb1423 = yyj1423 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1423 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1423 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.LastTransitionTime = pkg1_unversioned.Time{} + x.LastTransitionTime = pkg1_v1.Time{} } else { - yyv1426 := &x.LastTransitionTime - yym1427 := z.DecBinary() - _ = yym1427 + yyv15 := &x.LastTransitionTime + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(yyv1426) { - } else if yym1427 { - z.DecBinaryUnmarshal(yyv1426) - } else if !yym1427 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv1426) + } else if z.HasExtensions() && z.DecExt(yyv15) { + } else if yym16 { + z.DecBinaryUnmarshal(yyv15) + } else if !yym16 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv15) } else { - z.DecFallback(yyv1426, false) + z.DecFallback(yyv15, false) } } - yyj1423++ - if yyhl1423 { - yyb1423 = yyj1423 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1423 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1423 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16768,15 +14342,21 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Reason = "" } else { - x.Reason = string(r.DecodeString()) + yyv17 := &x.Reason + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj1423++ - if yyhl1423 { - yyb1423 = yyj1423 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1423 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1423 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -16784,20 +14364,26 @@ func (x *ReplicaSetCondition) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Message = "" } else { - x.Message = string(r.DecodeString()) + yyv19 := &x.Message + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } for { - yyj1423++ - if yyhl1423 { - yyb1423 = yyj1423 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1423 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1423 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1423-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -16809,38 +14395,38 @@ func (x *PodSecurityPolicy) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1430 := z.EncBinary() - _ = yym1430 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1431 := !z.EncBinary() - yy2arr1431 := z.EncBasicHandle().StructToArray - var yyq1431 [4]bool - _, _, _ = yysep1431, yyq1431, yy2arr1431 - const yyr1431 bool = false - yyq1431[0] = x.Kind != "" - yyq1431[1] = x.APIVersion != "" - yyq1431[2] = true - yyq1431[3] = true - var yynn1431 int - if yyr1431 || yy2arr1431 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1431 = 0 - for _, b := range yyq1431 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1431++ + yynn2++ } } - r.EncodeMapStart(yynn1431) - yynn1431 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1431 || yy2arr1431 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1431[0] { - yym1433 := z.EncBinary() - _ = yym1433 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -16849,23 +14435,23 @@ func (x *PodSecurityPolicy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1431[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1434 := z.EncBinary() - _ = yym1434 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1431 || yy2arr1431 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1431[1] { - yym1436 := z.EncBinary() - _ = yym1436 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -16874,53 +14460,65 @@ func (x *PodSecurityPolicy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1431[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1437 := z.EncBinary() - _ = yym1437 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1431 || yy2arr1431 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1431[2] { - yy1439 := &x.ObjectMeta - yy1439.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq1431[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1440 := &x.ObjectMeta - yy1440.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr1431 || yy2arr1431 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1431[3] { - yy1442 := &x.Spec - yy1442.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1431[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1443 := &x.Spec - yy1443.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr1431 || yy2arr1431 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -16933,25 +14531,25 @@ func (x *PodSecurityPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1444 := z.DecBinary() - _ = yym1444 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1445 := r.ContainerType() - if yyct1445 == codecSelferValueTypeMap1234 { - yyl1445 := r.ReadMapStart() - if yyl1445 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1445, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1445 == codecSelferValueTypeArray1234 { - yyl1445 := r.ReadArrayStart() - if yyl1445 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1445, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -16963,12 +14561,12 @@ func (x *PodSecurityPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1446Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1446Slc - var yyhl1446 bool = l >= 0 - for yyj1446 := 0; ; yyj1446++ { - if yyhl1446 { - if yyj1446 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -16977,40 +14575,58 @@ func (x *PodSecurityPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1446Slc = r.DecodeBytes(yys1446Slc, true, true) - yys1446 := string(yys1446Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1446 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1449 := &x.ObjectMeta - yyv1449.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = PodSecurityPolicySpec{} } else { - yyv1450 := &x.Spec - yyv1450.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1446) - } // end switch yys1446 - } // end for yyj1446 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -17018,16 +14634,16 @@ func (x *PodSecurityPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1451 int - var yyb1451 bool - var yyhl1451 bool = l >= 0 - yyj1451++ - if yyhl1451 { - yyb1451 = yyj1451 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1451 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1451 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17035,15 +14651,21 @@ func (x *PodSecurityPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj1451++ - if yyhl1451 { - yyb1451 = yyj1451 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1451 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1451 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17051,32 +14673,44 @@ func (x *PodSecurityPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj1451++ - if yyhl1451 { - yyb1451 = yyj1451 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1451 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1451 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1454 := &x.ObjectMeta - yyv1454.CodecDecodeSelf(d) + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } } - yyj1451++ - if yyhl1451 { - yyb1451 = yyj1451 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1451 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1451 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17084,21 +14718,21 @@ func (x *PodSecurityPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Spec = PodSecurityPolicySpec{} } else { - yyv1455 := &x.Spec - yyv1455.CodecDecodeSelf(d) + yyv18 := &x.Spec + yyv18.CodecDecodeSelf(d) } for { - yyj1451++ - if yyhl1451 { - yyb1451 = yyj1451 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1451 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1451 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1451-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -17110,44 +14744,44 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1456 := z.EncBinary() - _ = yym1456 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1457 := !z.EncBinary() - yy2arr1457 := z.EncBasicHandle().StructToArray - var yyq1457 [14]bool - _, _, _ = yysep1457, yyq1457, yy2arr1457 - const yyr1457 bool = false - yyq1457[0] = x.Privileged != false - yyq1457[1] = len(x.DefaultAddCapabilities) != 0 - yyq1457[2] = len(x.RequiredDropCapabilities) != 0 - yyq1457[3] = len(x.AllowedCapabilities) != 0 - yyq1457[4] = len(x.Volumes) != 0 - yyq1457[5] = x.HostNetwork != false - yyq1457[6] = len(x.HostPorts) != 0 - yyq1457[7] = x.HostPID != false - yyq1457[8] = x.HostIPC != false - yyq1457[13] = x.ReadOnlyRootFilesystem != false - var yynn1457 int - if yyr1457 || yy2arr1457 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [14]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Privileged != false + yyq2[1] = len(x.DefaultAddCapabilities) != 0 + yyq2[2] = len(x.RequiredDropCapabilities) != 0 + yyq2[3] = len(x.AllowedCapabilities) != 0 + yyq2[4] = len(x.Volumes) != 0 + yyq2[5] = x.HostNetwork != false + yyq2[6] = len(x.HostPorts) != 0 + yyq2[7] = x.HostPID != false + yyq2[8] = x.HostIPC != false + yyq2[13] = x.ReadOnlyRootFilesystem != false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(14) } else { - yynn1457 = 4 - for _, b := range yyq1457 { + yynn2 = 4 + for _, b := range yyq2 { if b { - yynn1457++ + yynn2++ } } - r.EncodeMapStart(yynn1457) - yynn1457 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[0] { - yym1459 := z.EncBinary() - _ = yym1459 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeBool(bool(x.Privileged)) @@ -17156,125 +14790,125 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1457[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("privileged")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1460 := z.EncBinary() - _ = yym1460 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeBool(bool(x.Privileged)) } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[1] { + if yyq2[1] { if x.DefaultAddCapabilities == nil { r.EncodeNil() } else { - yym1462 := z.EncBinary() - _ = yym1462 + yym7 := z.EncBinary() + _ = yym7 if false { } else { - h.encSlicev1_Capability(([]pkg2_v1.Capability)(x.DefaultAddCapabilities), e) + h.encSlicev1_Capability(([]pkg4_v1.Capability)(x.DefaultAddCapabilities), e) } } } else { r.EncodeNil() } } else { - if yyq1457[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("defaultAddCapabilities")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.DefaultAddCapabilities == nil { r.EncodeNil() } else { - yym1463 := z.EncBinary() - _ = yym1463 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - h.encSlicev1_Capability(([]pkg2_v1.Capability)(x.DefaultAddCapabilities), e) + h.encSlicev1_Capability(([]pkg4_v1.Capability)(x.DefaultAddCapabilities), e) } } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[2] { + if yyq2[2] { if x.RequiredDropCapabilities == nil { r.EncodeNil() } else { - yym1465 := z.EncBinary() - _ = yym1465 + yym10 := z.EncBinary() + _ = yym10 if false { } else { - h.encSlicev1_Capability(([]pkg2_v1.Capability)(x.RequiredDropCapabilities), e) + h.encSlicev1_Capability(([]pkg4_v1.Capability)(x.RequiredDropCapabilities), e) } } } else { r.EncodeNil() } } else { - if yyq1457[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("requiredDropCapabilities")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.RequiredDropCapabilities == nil { r.EncodeNil() } else { - yym1466 := z.EncBinary() - _ = yym1466 + yym11 := z.EncBinary() + _ = yym11 if false { } else { - h.encSlicev1_Capability(([]pkg2_v1.Capability)(x.RequiredDropCapabilities), e) + h.encSlicev1_Capability(([]pkg4_v1.Capability)(x.RequiredDropCapabilities), e) } } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[3] { + if yyq2[3] { if x.AllowedCapabilities == nil { r.EncodeNil() } else { - yym1468 := z.EncBinary() - _ = yym1468 + yym13 := z.EncBinary() + _ = yym13 if false { } else { - h.encSlicev1_Capability(([]pkg2_v1.Capability)(x.AllowedCapabilities), e) + h.encSlicev1_Capability(([]pkg4_v1.Capability)(x.AllowedCapabilities), e) } } } else { r.EncodeNil() } } else { - if yyq1457[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("allowedCapabilities")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.AllowedCapabilities == nil { r.EncodeNil() } else { - yym1469 := z.EncBinary() - _ = yym1469 + yym14 := z.EncBinary() + _ = yym14 if false { } else { - h.encSlicev1_Capability(([]pkg2_v1.Capability)(x.AllowedCapabilities), e) + h.encSlicev1_Capability(([]pkg4_v1.Capability)(x.AllowedCapabilities), e) } } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[4] { + if yyq2[4] { if x.Volumes == nil { r.EncodeNil() } else { - yym1471 := z.EncBinary() - _ = yym1471 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceFSType(([]FSType)(x.Volumes), e) @@ -17284,15 +14918,15 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1457[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("volumes")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Volumes == nil { r.EncodeNil() } else { - yym1472 := z.EncBinary() - _ = yym1472 + yym17 := z.EncBinary() + _ = yym17 if false { } else { h.encSliceFSType(([]FSType)(x.Volumes), e) @@ -17300,11 +14934,11 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[5] { - yym1474 := z.EncBinary() - _ = yym1474 + if yyq2[5] { + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeBool(bool(x.HostNetwork)) @@ -17313,26 +14947,26 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1457[5] { + if yyq2[5] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostNetwork")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1475 := z.EncBinary() - _ = yym1475 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeBool(bool(x.HostNetwork)) } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[6] { + if yyq2[6] { if x.HostPorts == nil { r.EncodeNil() } else { - yym1477 := z.EncBinary() - _ = yym1477 + yym22 := z.EncBinary() + _ = yym22 if false { } else { h.encSliceHostPortRange(([]HostPortRange)(x.HostPorts), e) @@ -17342,15 +14976,15 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1457[6] { + if yyq2[6] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPorts")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.HostPorts == nil { r.EncodeNil() } else { - yym1478 := z.EncBinary() - _ = yym1478 + yym23 := z.EncBinary() + _ = yym23 if false { } else { h.encSliceHostPortRange(([]HostPortRange)(x.HostPorts), e) @@ -17358,11 +14992,11 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[7] { - yym1480 := z.EncBinary() - _ = yym1480 + if yyq2[7] { + yym25 := z.EncBinary() + _ = yym25 if false { } else { r.EncodeBool(bool(x.HostPID)) @@ -17371,23 +15005,23 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1457[7] { + if yyq2[7] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostPID")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1481 := z.EncBinary() - _ = yym1481 + yym26 := z.EncBinary() + _ = yym26 if false { } else { r.EncodeBool(bool(x.HostPID)) } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[8] { - yym1483 := z.EncBinary() - _ = yym1483 + if yyq2[8] { + yym28 := z.EncBinary() + _ = yym28 if false { } else { r.EncodeBool(bool(x.HostIPC)) @@ -17396,67 +15030,67 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1457[8] { + if yyq2[8] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("hostIPC")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1484 := z.EncBinary() - _ = yym1484 + yym29 := z.EncBinary() + _ = yym29 if false { } else { r.EncodeBool(bool(x.HostIPC)) } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1486 := &x.SELinux - yy1486.CodecEncodeSelf(e) + yy31 := &x.SELinux + yy31.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("seLinux")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1487 := &x.SELinux - yy1487.CodecEncodeSelf(e) + yy33 := &x.SELinux + yy33.CodecEncodeSelf(e) } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1489 := &x.RunAsUser - yy1489.CodecEncodeSelf(e) + yy36 := &x.RunAsUser + yy36.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("runAsUser")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1490 := &x.RunAsUser - yy1490.CodecEncodeSelf(e) + yy38 := &x.RunAsUser + yy38.CodecEncodeSelf(e) } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1492 := &x.SupplementalGroups - yy1492.CodecEncodeSelf(e) + yy41 := &x.SupplementalGroups + yy41.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("supplementalGroups")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1493 := &x.SupplementalGroups - yy1493.CodecEncodeSelf(e) + yy43 := &x.SupplementalGroups + yy43.CodecEncodeSelf(e) } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1495 := &x.FSGroup - yy1495.CodecEncodeSelf(e) + yy46 := &x.FSGroup + yy46.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("fsGroup")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1496 := &x.FSGroup - yy1496.CodecEncodeSelf(e) + yy48 := &x.FSGroup + yy48.CodecEncodeSelf(e) } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1457[13] { - yym1498 := z.EncBinary() - _ = yym1498 + if yyq2[13] { + yym51 := z.EncBinary() + _ = yym51 if false { } else { r.EncodeBool(bool(x.ReadOnlyRootFilesystem)) @@ -17465,19 +15099,19 @@ func (x *PodSecurityPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeBool(false) } } else { - if yyq1457[13] { + if yyq2[13] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("readOnlyRootFilesystem")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1499 := z.EncBinary() - _ = yym1499 + yym52 := z.EncBinary() + _ = yym52 if false { } else { r.EncodeBool(bool(x.ReadOnlyRootFilesystem)) } } } - if yyr1457 || yy2arr1457 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -17490,25 +15124,25 @@ func (x *PodSecurityPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1500 := z.DecBinary() - _ = yym1500 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1501 := r.ContainerType() - if yyct1501 == codecSelferValueTypeMap1234 { - yyl1501 := r.ReadMapStart() - if yyl1501 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1501, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1501 == codecSelferValueTypeArray1234 { - yyl1501 := r.ReadArrayStart() - if yyl1501 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1501, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -17520,12 +15154,12 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1502Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1502Slc - var yyhl1502 bool = l >= 0 - for yyj1502 := 0; ; yyj1502++ { - if yyhl1502 { - if yyj1502 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -17534,132 +15168,162 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1502Slc = r.DecodeBytes(yys1502Slc, true, true) - yys1502 := string(yys1502Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1502 { + switch yys3 { case "privileged": if r.TryDecodeAsNil() { x.Privileged = false } else { - x.Privileged = bool(r.DecodeBool()) + yyv4 := &x.Privileged + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*bool)(yyv4)) = r.DecodeBool() + } } case "defaultAddCapabilities": if r.TryDecodeAsNil() { x.DefaultAddCapabilities = nil } else { - yyv1504 := &x.DefaultAddCapabilities - yym1505 := z.DecBinary() - _ = yym1505 + yyv6 := &x.DefaultAddCapabilities + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSlicev1_Capability((*[]pkg2_v1.Capability)(yyv1504), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv6), d) } } case "requiredDropCapabilities": if r.TryDecodeAsNil() { x.RequiredDropCapabilities = nil } else { - yyv1506 := &x.RequiredDropCapabilities - yym1507 := z.DecBinary() - _ = yym1507 + yyv8 := &x.RequiredDropCapabilities + yym9 := z.DecBinary() + _ = yym9 if false { } else { - h.decSlicev1_Capability((*[]pkg2_v1.Capability)(yyv1506), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv8), d) } } case "allowedCapabilities": if r.TryDecodeAsNil() { x.AllowedCapabilities = nil } else { - yyv1508 := &x.AllowedCapabilities - yym1509 := z.DecBinary() - _ = yym1509 + yyv10 := &x.AllowedCapabilities + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicev1_Capability((*[]pkg2_v1.Capability)(yyv1508), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv10), d) } } case "volumes": if r.TryDecodeAsNil() { x.Volumes = nil } else { - yyv1510 := &x.Volumes - yym1511 := z.DecBinary() - _ = yym1511 + yyv12 := &x.Volumes + yym13 := z.DecBinary() + _ = yym13 if false { } else { - h.decSliceFSType((*[]FSType)(yyv1510), d) + h.decSliceFSType((*[]FSType)(yyv12), d) } } case "hostNetwork": if r.TryDecodeAsNil() { x.HostNetwork = false } else { - x.HostNetwork = bool(r.DecodeBool()) + yyv14 := &x.HostNetwork + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*bool)(yyv14)) = r.DecodeBool() + } } case "hostPorts": if r.TryDecodeAsNil() { x.HostPorts = nil } else { - yyv1513 := &x.HostPorts - yym1514 := z.DecBinary() - _ = yym1514 + yyv16 := &x.HostPorts + yym17 := z.DecBinary() + _ = yym17 if false { } else { - h.decSliceHostPortRange((*[]HostPortRange)(yyv1513), d) + h.decSliceHostPortRange((*[]HostPortRange)(yyv16), d) } } case "hostPID": if r.TryDecodeAsNil() { x.HostPID = false } else { - x.HostPID = bool(r.DecodeBool()) + yyv18 := &x.HostPID + yym19 := z.DecBinary() + _ = yym19 + if false { + } else { + *((*bool)(yyv18)) = r.DecodeBool() + } } case "hostIPC": if r.TryDecodeAsNil() { x.HostIPC = false } else { - x.HostIPC = bool(r.DecodeBool()) + yyv20 := &x.HostIPC + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + *((*bool)(yyv20)) = r.DecodeBool() + } } case "seLinux": if r.TryDecodeAsNil() { x.SELinux = SELinuxStrategyOptions{} } else { - yyv1517 := &x.SELinux - yyv1517.CodecDecodeSelf(d) + yyv22 := &x.SELinux + yyv22.CodecDecodeSelf(d) } case "runAsUser": if r.TryDecodeAsNil() { x.RunAsUser = RunAsUserStrategyOptions{} } else { - yyv1518 := &x.RunAsUser - yyv1518.CodecDecodeSelf(d) + yyv23 := &x.RunAsUser + yyv23.CodecDecodeSelf(d) } case "supplementalGroups": if r.TryDecodeAsNil() { x.SupplementalGroups = SupplementalGroupsStrategyOptions{} } else { - yyv1519 := &x.SupplementalGroups - yyv1519.CodecDecodeSelf(d) + yyv24 := &x.SupplementalGroups + yyv24.CodecDecodeSelf(d) } case "fsGroup": if r.TryDecodeAsNil() { x.FSGroup = FSGroupStrategyOptions{} } else { - yyv1520 := &x.FSGroup - yyv1520.CodecDecodeSelf(d) + yyv25 := &x.FSGroup + yyv25.CodecDecodeSelf(d) } case "readOnlyRootFilesystem": if r.TryDecodeAsNil() { x.ReadOnlyRootFilesystem = false } else { - x.ReadOnlyRootFilesystem = bool(r.DecodeBool()) + yyv26 := &x.ReadOnlyRootFilesystem + yym27 := z.DecBinary() + _ = yym27 + if false { + } else { + *((*bool)(yyv26)) = r.DecodeBool() + } } default: - z.DecStructFieldNotFound(-1, yys1502) - } // end switch yys1502 - } // end for yyj1502 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -17667,16 +15331,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1522 int - var yyb1522 bool - var yyhl1522 bool = l >= 0 - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + var yyj28 int + var yyb28 bool + var yyhl28 bool = l >= 0 + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17684,15 +15348,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Privileged = false } else { - x.Privileged = bool(r.DecodeBool()) + yyv29 := &x.Privileged + yym30 := z.DecBinary() + _ = yym30 + if false { + } else { + *((*bool)(yyv29)) = r.DecodeBool() + } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17700,21 +15370,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.DefaultAddCapabilities = nil } else { - yyv1524 := &x.DefaultAddCapabilities - yym1525 := z.DecBinary() - _ = yym1525 + yyv31 := &x.DefaultAddCapabilities + yym32 := z.DecBinary() + _ = yym32 if false { } else { - h.decSlicev1_Capability((*[]pkg2_v1.Capability)(yyv1524), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv31), d) } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17722,21 +15392,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.RequiredDropCapabilities = nil } else { - yyv1526 := &x.RequiredDropCapabilities - yym1527 := z.DecBinary() - _ = yym1527 + yyv33 := &x.RequiredDropCapabilities + yym34 := z.DecBinary() + _ = yym34 if false { } else { - h.decSlicev1_Capability((*[]pkg2_v1.Capability)(yyv1526), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv33), d) } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17744,21 +15414,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.AllowedCapabilities = nil } else { - yyv1528 := &x.AllowedCapabilities - yym1529 := z.DecBinary() - _ = yym1529 + yyv35 := &x.AllowedCapabilities + yym36 := z.DecBinary() + _ = yym36 if false { } else { - h.decSlicev1_Capability((*[]pkg2_v1.Capability)(yyv1528), d) + h.decSlicev1_Capability((*[]pkg4_v1.Capability)(yyv35), d) } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17766,21 +15436,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Volumes = nil } else { - yyv1530 := &x.Volumes - yym1531 := z.DecBinary() - _ = yym1531 + yyv37 := &x.Volumes + yym38 := z.DecBinary() + _ = yym38 if false { } else { - h.decSliceFSType((*[]FSType)(yyv1530), d) + h.decSliceFSType((*[]FSType)(yyv37), d) } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17788,15 +15458,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostNetwork = false } else { - x.HostNetwork = bool(r.DecodeBool()) + yyv39 := &x.HostNetwork + yym40 := z.DecBinary() + _ = yym40 + if false { + } else { + *((*bool)(yyv39)) = r.DecodeBool() + } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17804,21 +15480,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostPorts = nil } else { - yyv1533 := &x.HostPorts - yym1534 := z.DecBinary() - _ = yym1534 + yyv41 := &x.HostPorts + yym42 := z.DecBinary() + _ = yym42 if false { } else { - h.decSliceHostPortRange((*[]HostPortRange)(yyv1533), d) + h.decSliceHostPortRange((*[]HostPortRange)(yyv41), d) } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17826,15 +15502,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostPID = false } else { - x.HostPID = bool(r.DecodeBool()) + yyv43 := &x.HostPID + yym44 := z.DecBinary() + _ = yym44 + if false { + } else { + *((*bool)(yyv43)) = r.DecodeBool() + } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17842,15 +15524,21 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.HostIPC = false } else { - x.HostIPC = bool(r.DecodeBool()) + yyv45 := &x.HostIPC + yym46 := z.DecBinary() + _ = yym46 + if false { + } else { + *((*bool)(yyv45)) = r.DecodeBool() + } } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17858,16 +15546,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.SELinux = SELinuxStrategyOptions{} } else { - yyv1537 := &x.SELinux - yyv1537.CodecDecodeSelf(d) + yyv47 := &x.SELinux + yyv47.CodecDecodeSelf(d) } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17875,16 +15563,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.RunAsUser = RunAsUserStrategyOptions{} } else { - yyv1538 := &x.RunAsUser - yyv1538.CodecDecodeSelf(d) + yyv48 := &x.RunAsUser + yyv48.CodecDecodeSelf(d) } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17892,16 +15580,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.SupplementalGroups = SupplementalGroupsStrategyOptions{} } else { - yyv1539 := &x.SupplementalGroups - yyv1539.CodecDecodeSelf(d) + yyv49 := &x.SupplementalGroups + yyv49.CodecDecodeSelf(d) } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17909,16 +15597,16 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.FSGroup = FSGroupStrategyOptions{} } else { - yyv1540 := &x.FSGroup - yyv1540.CodecDecodeSelf(d) + yyv50 := &x.FSGroup + yyv50.CodecDecodeSelf(d) } - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -17926,20 +15614,26 @@ func (x *PodSecurityPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.ReadOnlyRootFilesystem = false } else { - x.ReadOnlyRootFilesystem = bool(r.DecodeBool()) + yyv51 := &x.ReadOnlyRootFilesystem + yym52 := z.DecBinary() + _ = yym52 + if false { + } else { + *((*bool)(yyv51)) = r.DecodeBool() + } } for { - yyj1522++ - if yyhl1522 { - yyb1522 = yyj1522 > l + yyj28++ + if yyhl28 { + yyb28 = yyj28 > l } else { - yyb1522 = r.CheckBreak() + yyb28 = r.CheckBreak() } - if yyb1522 { + if yyb28 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1522-1, "") + z.DecStructFieldNotFound(yyj28-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -17948,8 +15642,8 @@ func (x FSType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1542 := z.EncBinary() - _ = yym1542 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -17961,8 +15655,8 @@ func (x *FSType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1543 := z.DecBinary() - _ = yym1543 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -17977,33 +15671,33 @@ func (x *HostPortRange) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1544 := z.EncBinary() - _ = yym1544 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1545 := !z.EncBinary() - yy2arr1545 := z.EncBasicHandle().StructToArray - var yyq1545 [2]bool - _, _, _ = yysep1545, yyq1545, yy2arr1545 - const yyr1545 bool = false - var yynn1545 int - if yyr1545 || yy2arr1545 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1545 = 2 - for _, b := range yyq1545 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1545++ + yynn2++ } } - r.EncodeMapStart(yynn1545) - yynn1545 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1545 || yy2arr1545 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1547 := z.EncBinary() - _ = yym1547 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Min)) @@ -18012,17 +15706,17 @@ func (x *HostPortRange) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("min")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1548 := z.EncBinary() - _ = yym1548 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Min)) } } - if yyr1545 || yy2arr1545 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1550 := z.EncBinary() - _ = yym1550 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.Max)) @@ -18031,14 +15725,14 @@ func (x *HostPortRange) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("max")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1551 := z.EncBinary() - _ = yym1551 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.Max)) } } - if yyr1545 || yy2arr1545 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18051,25 +15745,25 @@ func (x *HostPortRange) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1552 := z.DecBinary() - _ = yym1552 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1553 := r.ContainerType() - if yyct1553 == codecSelferValueTypeMap1234 { - yyl1553 := r.ReadMapStart() - if yyl1553 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1553, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1553 == codecSelferValueTypeArray1234 { - yyl1553 := r.ReadArrayStart() - if yyl1553 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1553, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18081,12 +15775,12 @@ func (x *HostPortRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1554Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1554Slc - var yyhl1554 bool = l >= 0 - for yyj1554 := 0; ; yyj1554++ { - if yyhl1554 { - if yyj1554 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18095,26 +15789,38 @@ func (x *HostPortRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1554Slc = r.DecodeBytes(yys1554Slc, true, true) - yys1554 := string(yys1554Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1554 { + switch yys3 { case "min": if r.TryDecodeAsNil() { x.Min = 0 } else { - x.Min = int32(r.DecodeInt(32)) + yyv4 := &x.Min + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int32)(yyv4)) = int32(r.DecodeInt(32)) + } } case "max": if r.TryDecodeAsNil() { x.Max = 0 } else { - x.Max = int32(r.DecodeInt(32)) + yyv6 := &x.Max + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int32)(yyv6)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys1554) - } // end switch yys1554 - } // end for yyj1554 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -18122,16 +15828,16 @@ func (x *HostPortRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1557 int - var yyb1557 bool - var yyhl1557 bool = l >= 0 - yyj1557++ - if yyhl1557 { - yyb1557 = yyj1557 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1557 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1557 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18139,15 +15845,21 @@ func (x *HostPortRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Min = 0 } else { - x.Min = int32(r.DecodeInt(32)) + yyv9 := &x.Min + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*int32)(yyv9)) = int32(r.DecodeInt(32)) + } } - yyj1557++ - if yyhl1557 { - yyb1557 = yyj1557 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1557 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1557 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18155,20 +15867,26 @@ func (x *HostPortRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Max = 0 } else { - x.Max = int32(r.DecodeInt(32)) + yyv11 := &x.Max + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int32)(yyv11)) = int32(r.DecodeInt(32)) + } } for { - yyj1557++ - if yyhl1557 { - yyb1557 = yyj1557 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1557 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1557 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1557-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18180,31 +15898,31 @@ func (x *SELinuxStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1560 := z.EncBinary() - _ = yym1560 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1561 := !z.EncBinary() - yy2arr1561 := z.EncBasicHandle().StructToArray - var yyq1561 [2]bool - _, _, _ = yysep1561, yyq1561, yy2arr1561 - const yyr1561 bool = false - yyq1561[1] = x.SELinuxOptions != nil - var yynn1561 int - if yyr1561 || yy2arr1561 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.SELinuxOptions != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1561 = 1 - for _, b := range yyq1561 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1561++ + yynn2++ } } - r.EncodeMapStart(yynn1561) - yynn1561 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1561 || yy2arr1561 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Rule.CodecEncodeSelf(e) } else { @@ -18213,9 +15931,9 @@ func (x *SELinuxStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Rule.CodecEncodeSelf(e) } - if yyr1561 || yy2arr1561 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1561[1] { + if yyq2[1] { if x.SELinuxOptions == nil { r.EncodeNil() } else { @@ -18225,7 +15943,7 @@ func (x *SELinuxStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1561[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("seLinuxOptions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) @@ -18236,7 +15954,7 @@ func (x *SELinuxStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1561 || yy2arr1561 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18249,25 +15967,25 @@ func (x *SELinuxStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1564 := z.DecBinary() - _ = yym1564 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1565 := r.ContainerType() - if yyct1565 == codecSelferValueTypeMap1234 { - yyl1565 := r.ReadMapStart() - if yyl1565 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1565, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1565 == codecSelferValueTypeArray1234 { - yyl1565 := r.ReadArrayStart() - if yyl1565 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1565, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18279,12 +15997,12 @@ func (x *SELinuxStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1566Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1566Slc - var yyhl1566 bool = l >= 0 - for yyj1566 := 0; ; yyj1566++ { - if yyhl1566 { - if yyj1566 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18293,15 +16011,16 @@ func (x *SELinuxStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1566Slc = r.DecodeBytes(yys1566Slc, true, true) - yys1566 := string(yys1566Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1566 { + switch yys3 { case "rule": if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = SELinuxStrategy(r.DecodeString()) + yyv4 := &x.Rule + yyv4.CodecDecodeSelf(d) } case "seLinuxOptions": if r.TryDecodeAsNil() { @@ -18310,14 +16029,14 @@ func (x *SELinuxStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } else { if x.SELinuxOptions == nil { - x.SELinuxOptions = new(pkg2_v1.SELinuxOptions) + x.SELinuxOptions = new(pkg4_v1.SELinuxOptions) } x.SELinuxOptions.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1566) - } // end switch yys1566 - } // end for yyj1566 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -18325,16 +16044,16 @@ func (x *SELinuxStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1569 int - var yyb1569 bool - var yyhl1569 bool = l >= 0 - yyj1569++ - if yyhl1569 { - yyb1569 = yyj1569 > l + var yyj6 int + var yyb6 bool + var yyhl6 bool = l >= 0 + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1569 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1569 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18342,15 +16061,16 @@ func (x *SELinuxStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = SELinuxStrategy(r.DecodeString()) + yyv7 := &x.Rule + yyv7.CodecDecodeSelf(d) } - yyj1569++ - if yyhl1569 { - yyb1569 = yyj1569 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1569 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1569 { + if yyb6 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18361,22 +16081,22 @@ func (x *SELinuxStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.De } } else { if x.SELinuxOptions == nil { - x.SELinuxOptions = new(pkg2_v1.SELinuxOptions) + x.SELinuxOptions = new(pkg4_v1.SELinuxOptions) } x.SELinuxOptions.CodecDecodeSelf(d) } for { - yyj1569++ - if yyhl1569 { - yyb1569 = yyj1569 > l + yyj6++ + if yyhl6 { + yyb6 = yyj6 > l } else { - yyb1569 = r.CheckBreak() + yyb6 = r.CheckBreak() } - if yyb1569 { + if yyb6 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1569-1, "") + z.DecStructFieldNotFound(yyj6-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18385,8 +16105,8 @@ func (x SELinuxStrategy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1572 := z.EncBinary() - _ = yym1572 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -18398,8 +16118,8 @@ func (x *SELinuxStrategy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1573 := z.DecBinary() - _ = yym1573 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -18414,31 +16134,31 @@ func (x *RunAsUserStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1574 := z.EncBinary() - _ = yym1574 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1575 := !z.EncBinary() - yy2arr1575 := z.EncBasicHandle().StructToArray - var yyq1575 [2]bool - _, _, _ = yysep1575, yyq1575, yy2arr1575 - const yyr1575 bool = false - yyq1575[1] = len(x.Ranges) != 0 - var yynn1575 int - if yyr1575 || yy2arr1575 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Ranges) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1575 = 1 - for _, b := range yyq1575 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1575++ + yynn2++ } } - r.EncodeMapStart(yynn1575) - yynn1575 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1575 || yy2arr1575 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) x.Rule.CodecEncodeSelf(e) } else { @@ -18447,14 +16167,14 @@ func (x *RunAsUserStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Rule.CodecEncodeSelf(e) } - if yyr1575 || yy2arr1575 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1575[1] { + if yyq2[1] { if x.Ranges == nil { r.EncodeNil() } else { - yym1578 := z.EncBinary() - _ = yym1578 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceIDRange(([]IDRange)(x.Ranges), e) @@ -18464,15 +16184,15 @@ func (x *RunAsUserStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1575[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ranges")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ranges == nil { r.EncodeNil() } else { - yym1579 := z.EncBinary() - _ = yym1579 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceIDRange(([]IDRange)(x.Ranges), e) @@ -18480,7 +16200,7 @@ func (x *RunAsUserStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1575 || yy2arr1575 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18493,25 +16213,25 @@ func (x *RunAsUserStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1580 := z.DecBinary() - _ = yym1580 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1581 := r.ContainerType() - if yyct1581 == codecSelferValueTypeMap1234 { - yyl1581 := r.ReadMapStart() - if yyl1581 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1581, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1581 == codecSelferValueTypeArray1234 { - yyl1581 := r.ReadArrayStart() - if yyl1581 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1581, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18523,12 +16243,12 @@ func (x *RunAsUserStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1582Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1582Slc - var yyhl1582 bool = l >= 0 - for yyj1582 := 0; ; yyj1582++ { - if yyhl1582 { - if yyj1582 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18537,32 +16257,33 @@ func (x *RunAsUserStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.De } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1582Slc = r.DecodeBytes(yys1582Slc, true, true) - yys1582 := string(yys1582Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1582 { + switch yys3 { case "rule": if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = RunAsUserStrategy(r.DecodeString()) + yyv4 := &x.Rule + yyv4.CodecDecodeSelf(d) } case "ranges": if r.TryDecodeAsNil() { x.Ranges = nil } else { - yyv1584 := &x.Ranges - yym1585 := z.DecBinary() - _ = yym1585 + yyv5 := &x.Ranges + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSliceIDRange((*[]IDRange)(yyv1584), d) + h.decSliceIDRange((*[]IDRange)(yyv5), d) } } default: - z.DecStructFieldNotFound(-1, yys1582) - } // end switch yys1582 - } // end for yyj1582 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -18570,16 +16291,16 @@ func (x *RunAsUserStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978. var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1586 int - var yyb1586 bool - var yyhl1586 bool = l >= 0 - yyj1586++ - if yyhl1586 { - yyb1586 = yyj1586 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1586 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1586 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18587,15 +16308,16 @@ func (x *RunAsUserStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = RunAsUserStrategy(r.DecodeString()) + yyv8 := &x.Rule + yyv8.CodecDecodeSelf(d) } - yyj1586++ - if yyhl1586 { - yyb1586 = yyj1586 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1586 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1586 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18603,26 +16325,26 @@ func (x *RunAsUserStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Ranges = nil } else { - yyv1588 := &x.Ranges - yym1589 := z.DecBinary() - _ = yym1589 + yyv9 := &x.Ranges + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceIDRange((*[]IDRange)(yyv1588), d) + h.decSliceIDRange((*[]IDRange)(yyv9), d) } } for { - yyj1586++ - if yyhl1586 { - yyb1586 = yyj1586 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1586 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1586 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1586-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18634,33 +16356,33 @@ func (x *IDRange) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1590 := z.EncBinary() - _ = yym1590 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1591 := !z.EncBinary() - yy2arr1591 := z.EncBasicHandle().StructToArray - var yyq1591 [2]bool - _, _, _ = yysep1591, yyq1591, yy2arr1591 - const yyr1591 bool = false - var yynn1591 int - if yyr1591 || yy2arr1591 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1591 = 2 - for _, b := range yyq1591 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn1591++ + yynn2++ } } - r.EncodeMapStart(yynn1591) - yynn1591 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1591 || yy2arr1591 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1593 := z.EncBinary() - _ = yym1593 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.Min)) @@ -18669,17 +16391,17 @@ func (x *IDRange) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("min")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1594 := z.EncBinary() - _ = yym1594 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.Min)) } } - if yyr1591 || yy2arr1591 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1596 := z.EncBinary() - _ = yym1596 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeInt(int64(x.Max)) @@ -18688,14 +16410,14 @@ func (x *IDRange) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("max")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1597 := z.EncBinary() - _ = yym1597 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeInt(int64(x.Max)) } } - if yyr1591 || yy2arr1591 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18708,25 +16430,25 @@ func (x *IDRange) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1598 := z.DecBinary() - _ = yym1598 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1599 := r.ContainerType() - if yyct1599 == codecSelferValueTypeMap1234 { - yyl1599 := r.ReadMapStart() - if yyl1599 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1599, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1599 == codecSelferValueTypeArray1234 { - yyl1599 := r.ReadArrayStart() - if yyl1599 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1599, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18738,12 +16460,12 @@ func (x *IDRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1600Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1600Slc - var yyhl1600 bool = l >= 0 - for yyj1600 := 0; ; yyj1600++ { - if yyhl1600 { - if yyj1600 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18752,26 +16474,38 @@ func (x *IDRange) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1600Slc = r.DecodeBytes(yys1600Slc, true, true) - yys1600 := string(yys1600Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1600 { + switch yys3 { case "min": if r.TryDecodeAsNil() { x.Min = 0 } else { - x.Min = int64(r.DecodeInt(64)) + yyv4 := &x.Min + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } } case "max": if r.TryDecodeAsNil() { x.Max = 0 } else { - x.Max = int64(r.DecodeInt(64)) + yyv6 := &x.Max + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*int64)(yyv6)) = int64(r.DecodeInt(64)) + } } default: - z.DecStructFieldNotFound(-1, yys1600) - } // end switch yys1600 - } // end for yyj1600 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -18779,16 +16513,16 @@ func (x *IDRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1603 int - var yyb1603 bool - var yyhl1603 bool = l >= 0 - yyj1603++ - if yyhl1603 { - yyb1603 = yyj1603 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1603 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1603 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18796,15 +16530,21 @@ func (x *IDRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Min = 0 } else { - x.Min = int64(r.DecodeInt(64)) + yyv9 := &x.Min + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + *((*int64)(yyv9)) = int64(r.DecodeInt(64)) + } } - yyj1603++ - if yyhl1603 { - yyb1603 = yyj1603 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1603 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1603 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -18812,20 +16552,26 @@ func (x *IDRange) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Max = 0 } else { - x.Max = int64(r.DecodeInt(64)) + yyv11 := &x.Max + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*int64)(yyv11)) = int64(r.DecodeInt(64)) + } } for { - yyj1603++ - if yyhl1603 { - yyb1603 = yyj1603 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1603 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1603 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1603-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -18834,8 +16580,8 @@ func (x RunAsUserStrategy) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1606 := z.EncBinary() - _ = yym1606 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -18847,8 +16593,8 @@ func (x *RunAsUserStrategy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1607 := z.DecBinary() - _ = yym1607 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -18863,54 +16609,54 @@ func (x *FSGroupStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1608 := z.EncBinary() - _ = yym1608 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1609 := !z.EncBinary() - yy2arr1609 := z.EncBasicHandle().StructToArray - var yyq1609 [2]bool - _, _, _ = yysep1609, yyq1609, yy2arr1609 - const yyr1609 bool = false - yyq1609[0] = x.Rule != "" - yyq1609[1] = len(x.Ranges) != 0 - var yynn1609 int - if yyr1609 || yy2arr1609 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Rule != "" + yyq2[1] = len(x.Ranges) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1609 = 0 - for _, b := range yyq1609 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1609++ + yynn2++ } } - r.EncodeMapStart(yynn1609) - yynn1609 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1609 || yy2arr1609 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1609[0] { + if yyq2[0] { x.Rule.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1609[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rule")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Rule.CodecEncodeSelf(e) } } - if yyr1609 || yy2arr1609 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1609[1] { + if yyq2[1] { if x.Ranges == nil { r.EncodeNil() } else { - yym1612 := z.EncBinary() - _ = yym1612 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceIDRange(([]IDRange)(x.Ranges), e) @@ -18920,15 +16666,15 @@ func (x *FSGroupStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1609[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ranges")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ranges == nil { r.EncodeNil() } else { - yym1613 := z.EncBinary() - _ = yym1613 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceIDRange(([]IDRange)(x.Ranges), e) @@ -18936,7 +16682,7 @@ func (x *FSGroupStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1609 || yy2arr1609 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -18949,25 +16695,25 @@ func (x *FSGroupStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1614 := z.DecBinary() - _ = yym1614 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1615 := r.ContainerType() - if yyct1615 == codecSelferValueTypeMap1234 { - yyl1615 := r.ReadMapStart() - if yyl1615 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1615, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1615 == codecSelferValueTypeArray1234 { - yyl1615 := r.ReadArrayStart() - if yyl1615 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1615, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -18979,12 +16725,12 @@ func (x *FSGroupStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1616Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1616Slc - var yyhl1616 bool = l >= 0 - for yyj1616 := 0; ; yyj1616++ { - if yyhl1616 { - if yyj1616 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -18993,32 +16739,33 @@ func (x *FSGroupStrategyOptions) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1616Slc = r.DecodeBytes(yys1616Slc, true, true) - yys1616 := string(yys1616Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1616 { + switch yys3 { case "rule": if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = FSGroupStrategyType(r.DecodeString()) + yyv4 := &x.Rule + yyv4.CodecDecodeSelf(d) } case "ranges": if r.TryDecodeAsNil() { x.Ranges = nil } else { - yyv1618 := &x.Ranges - yym1619 := z.DecBinary() - _ = yym1619 + yyv5 := &x.Ranges + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSliceIDRange((*[]IDRange)(yyv1618), d) + h.decSliceIDRange((*[]IDRange)(yyv5), d) } } default: - z.DecStructFieldNotFound(-1, yys1616) - } // end switch yys1616 - } // end for yyj1616 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19026,16 +16773,16 @@ func (x *FSGroupStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1620 int - var yyb1620 bool - var yyhl1620 bool = l >= 0 - yyj1620++ - if yyhl1620 { - yyb1620 = yyj1620 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1620 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1620 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19043,15 +16790,16 @@ func (x *FSGroupStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = FSGroupStrategyType(r.DecodeString()) + yyv8 := &x.Rule + yyv8.CodecDecodeSelf(d) } - yyj1620++ - if yyhl1620 { - yyb1620 = yyj1620 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1620 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1620 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19059,26 +16807,26 @@ func (x *FSGroupStrategyOptions) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Ranges = nil } else { - yyv1622 := &x.Ranges - yym1623 := z.DecBinary() - _ = yym1623 + yyv9 := &x.Ranges + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceIDRange((*[]IDRange)(yyv1622), d) + h.decSliceIDRange((*[]IDRange)(yyv9), d) } } for { - yyj1620++ - if yyhl1620 { - yyb1620 = yyj1620 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1620 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1620 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1620-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -19087,8 +16835,8 @@ func (x FSGroupStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1624 := z.EncBinary() - _ = yym1624 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -19100,8 +16848,8 @@ func (x *FSGroupStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1625 := z.DecBinary() - _ = yym1625 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -19116,54 +16864,54 @@ func (x *SupplementalGroupsStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder if x == nil { r.EncodeNil() } else { - yym1626 := z.EncBinary() - _ = yym1626 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1627 := !z.EncBinary() - yy2arr1627 := z.EncBasicHandle().StructToArray - var yyq1627 [2]bool - _, _, _ = yysep1627, yyq1627, yy2arr1627 - const yyr1627 bool = false - yyq1627[0] = x.Rule != "" - yyq1627[1] = len(x.Ranges) != 0 - var yynn1627 int - if yyr1627 || yy2arr1627 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Rule != "" + yyq2[1] = len(x.Ranges) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1627 = 0 - for _, b := range yyq1627 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1627++ + yynn2++ } } - r.EncodeMapStart(yynn1627) - yynn1627 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1627 || yy2arr1627 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1627[0] { + if yyq2[0] { x.Rule.CodecEncodeSelf(e) } else { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1627[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("rule")) z.EncSendContainerState(codecSelfer_containerMapValue1234) x.Rule.CodecEncodeSelf(e) } } - if yyr1627 || yy2arr1627 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1627[1] { + if yyq2[1] { if x.Ranges == nil { r.EncodeNil() } else { - yym1630 := z.EncBinary() - _ = yym1630 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceIDRange(([]IDRange)(x.Ranges), e) @@ -19173,15 +16921,15 @@ func (x *SupplementalGroupsStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder r.EncodeNil() } } else { - if yyq1627[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ranges")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ranges == nil { r.EncodeNil() } else { - yym1631 := z.EncBinary() - _ = yym1631 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceIDRange(([]IDRange)(x.Ranges), e) @@ -19189,7 +16937,7 @@ func (x *SupplementalGroupsStrategyOptions) CodecEncodeSelf(e *codec1978.Encoder } } } - if yyr1627 || yy2arr1627 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -19202,25 +16950,25 @@ func (x *SupplementalGroupsStrategyOptions) CodecDecodeSelf(d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1632 := z.DecBinary() - _ = yym1632 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1633 := r.ContainerType() - if yyct1633 == codecSelferValueTypeMap1234 { - yyl1633 := r.ReadMapStart() - if yyl1633 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1633, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1633 == codecSelferValueTypeArray1234 { - yyl1633 := r.ReadArrayStart() - if yyl1633 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1633, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -19232,12 +16980,12 @@ func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromMap(l int, d *cod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1634Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1634Slc - var yyhl1634 bool = l >= 0 - for yyj1634 := 0; ; yyj1634++ { - if yyhl1634 { - if yyj1634 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -19246,32 +16994,33 @@ func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromMap(l int, d *cod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1634Slc = r.DecodeBytes(yys1634Slc, true, true) - yys1634 := string(yys1634Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1634 { + switch yys3 { case "rule": if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = SupplementalGroupsStrategyType(r.DecodeString()) + yyv4 := &x.Rule + yyv4.CodecDecodeSelf(d) } case "ranges": if r.TryDecodeAsNil() { x.Ranges = nil } else { - yyv1636 := &x.Ranges - yym1637 := z.DecBinary() - _ = yym1637 + yyv5 := &x.Ranges + yym6 := z.DecBinary() + _ = yym6 if false { } else { - h.decSliceIDRange((*[]IDRange)(yyv1636), d) + h.decSliceIDRange((*[]IDRange)(yyv5), d) } } default: - z.DecStructFieldNotFound(-1, yys1634) - } // end switch yys1634 - } // end for yyj1634 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19279,16 +17028,16 @@ func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromArray(l int, d *c var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1638 int - var yyb1638 bool - var yyhl1638 bool = l >= 0 - yyj1638++ - if yyhl1638 { - yyb1638 = yyj1638 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1638 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1638 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19296,15 +17045,16 @@ func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromArray(l int, d *c if r.TryDecodeAsNil() { x.Rule = "" } else { - x.Rule = SupplementalGroupsStrategyType(r.DecodeString()) + yyv8 := &x.Rule + yyv8.CodecDecodeSelf(d) } - yyj1638++ - if yyhl1638 { - yyb1638 = yyj1638 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1638 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1638 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19312,26 +17062,26 @@ func (x *SupplementalGroupsStrategyOptions) codecDecodeSelfFromArray(l int, d *c if r.TryDecodeAsNil() { x.Ranges = nil } else { - yyv1640 := &x.Ranges - yym1641 := z.DecBinary() - _ = yym1641 + yyv9 := &x.Ranges + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceIDRange((*[]IDRange)(yyv1640), d) + h.decSliceIDRange((*[]IDRange)(yyv9), d) } } for { - yyj1638++ - if yyhl1638 { - yyb1638 = yyj1638 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1638 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1638 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1638-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -19340,8 +17090,8 @@ func (x SupplementalGroupsStrategyType) CodecEncodeSelf(e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r - yym1642 := z.EncBinary() - _ = yym1642 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { @@ -19353,8 +17103,8 @@ func (x *SupplementalGroupsStrategyType) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1643 := z.DecBinary() - _ = yym1643 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { @@ -19369,37 +17119,37 @@ func (x *PodSecurityPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1644 := z.EncBinary() - _ = yym1644 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1645 := !z.EncBinary() - yy2arr1645 := z.EncBasicHandle().StructToArray - var yyq1645 [4]bool - _, _, _ = yysep1645, yyq1645, yy2arr1645 - const yyr1645 bool = false - yyq1645[0] = x.Kind != "" - yyq1645[1] = x.APIVersion != "" - yyq1645[2] = true - var yynn1645 int - if yyr1645 || yy2arr1645 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1645 = 1 - for _, b := range yyq1645 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1645++ + yynn2++ } } - r.EncodeMapStart(yynn1645) - yynn1645 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1645 || yy2arr1645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1645[0] { - yym1647 := z.EncBinary() - _ = yym1647 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -19408,23 +17158,23 @@ func (x *PodSecurityPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1645[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1648 := z.EncBinary() - _ = yym1648 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1645 || yy2arr1645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1645[1] { - yym1650 := z.EncBinary() - _ = yym1650 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -19433,54 +17183,54 @@ func (x *PodSecurityPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1645[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1651 := z.EncBinary() - _ = yym1651 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1645 || yy2arr1645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1645[2] { - yy1653 := &x.ListMeta - yym1654 := z.EncBinary() - _ = yym1654 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy1653) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy1653) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1645[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1655 := &x.ListMeta - yym1656 := z.EncBinary() - _ = yym1656 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy1655) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy1655) + z.EncFallback(yy12) } } } - if yyr1645 || yy2arr1645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym1658 := z.EncBinary() - _ = yym1658 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePodSecurityPolicy(([]PodSecurityPolicy)(x.Items), e) @@ -19493,15 +17243,15 @@ func (x *PodSecurityPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym1659 := z.EncBinary() - _ = yym1659 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePodSecurityPolicy(([]PodSecurityPolicy)(x.Items), e) } } } - if yyr1645 || yy2arr1645 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -19514,25 +17264,25 @@ func (x *PodSecurityPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1660 := z.DecBinary() - _ = yym1660 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1661 := r.ContainerType() - if yyct1661 == codecSelferValueTypeMap1234 { - yyl1661 := r.ReadMapStart() - if yyl1661 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1661, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1661 == codecSelferValueTypeArray1234 { - yyl1661 := r.ReadArrayStart() - if yyl1661 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1661, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -19544,12 +17294,12 @@ func (x *PodSecurityPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1662Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1662Slc - var yyhl1662 bool = l >= 0 - for yyj1662 := 0; ; yyj1662++ { - if yyhl1662 { - if yyj1662 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -19558,51 +17308,63 @@ func (x *PodSecurityPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decod } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1662Slc = r.DecodeBytes(yys1662Slc, true, true) - yys1662 := string(yys1662Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1662 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1665 := &x.ListMeta - yym1666 := z.DecBinary() - _ = yym1666 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv1665) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv1665, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1667 := &x.Items - yym1668 := z.DecBinary() - _ = yym1668 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePodSecurityPolicy((*[]PodSecurityPolicy)(yyv1667), d) + h.decSlicePodSecurityPolicy((*[]PodSecurityPolicy)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys1662) - } // end switch yys1662 - } // end for yyj1662 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19610,16 +17372,16 @@ func (x *PodSecurityPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Dec 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 + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1669 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1669 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19627,15 +17389,21 @@ func (x *PodSecurityPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1669 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1669 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19643,38 +17411,44 @@ func (x *PodSecurityPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1669 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1669 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1672 := &x.ListMeta - yym1673 := z.DecBinary() - _ = yym1673 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv1672) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv1672, false) + z.DecFallback(yyv17, false) } } - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1669 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1669 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19682,26 +17456,26 @@ func (x *PodSecurityPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Dec if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1674 := &x.Items - yym1675 := z.DecBinary() - _ = yym1675 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePodSecurityPolicy((*[]PodSecurityPolicy)(yyv1674), d) + h.decSlicePodSecurityPolicy((*[]PodSecurityPolicy)(yyv19), d) } } for { - yyj1669++ - if yyhl1669 { - yyb1669 = yyj1669 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1669 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1669 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1669-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -19713,38 +17487,38 @@ func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1676 := z.EncBinary() - _ = yym1676 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1677 := !z.EncBinary() - yy2arr1677 := z.EncBasicHandle().StructToArray - var yyq1677 [4]bool - _, _, _ = yysep1677, yyq1677, yy2arr1677 - const yyr1677 bool = false - yyq1677[0] = x.Kind != "" - yyq1677[1] = x.APIVersion != "" - yyq1677[2] = true - yyq1677[3] = true - var yynn1677 int - if yyr1677 || yy2arr1677 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1677 = 0 - for _, b := range yyq1677 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1677++ + yynn2++ } } - r.EncodeMapStart(yynn1677) - yynn1677 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1677 || yy2arr1677 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1677[0] { - yym1679 := z.EncBinary() - _ = yym1679 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -19753,23 +17527,23 @@ func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1677[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1680 := z.EncBinary() - _ = yym1680 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1677 || yy2arr1677 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1677[1] { - yym1682 := z.EncBinary() - _ = yym1682 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -19778,53 +17552,65 @@ func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1677[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1683 := z.EncBinary() - _ = yym1683 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1677 || yy2arr1677 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1677[2] { - yy1685 := &x.ObjectMeta - yy1685.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq1677[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1686 := &x.ObjectMeta - yy1686.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr1677 || yy2arr1677 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1677[3] { - yy1688 := &x.Spec - yy1688.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq1677[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1689 := &x.Spec - yy1689.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr1677 || yy2arr1677 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -19837,25 +17623,25 @@ func (x *NetworkPolicy) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1690 := z.DecBinary() - _ = yym1690 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1691 := r.ContainerType() - if yyct1691 == codecSelferValueTypeMap1234 { - yyl1691 := r.ReadMapStart() - if yyl1691 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1691, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1691 == codecSelferValueTypeArray1234 { - yyl1691 := r.ReadArrayStart() - if yyl1691 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1691, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -19867,12 +17653,12 @@ func (x *NetworkPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1692Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1692Slc - var yyhl1692 bool = l >= 0 - for yyj1692 := 0; ; yyj1692++ { - if yyhl1692 { - if yyj1692 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -19881,40 +17667,58 @@ func (x *NetworkPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1692Slc = r.DecodeBytes(yys1692Slc, true, true) - yys1692 := string(yys1692Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1692 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1695 := &x.ObjectMeta - yyv1695.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = NetworkPolicySpec{} } else { - yyv1696 := &x.Spec - yyv1696.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys1692) - } // end switch yys1692 - } // end for yyj1692 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -19922,16 +17726,16 @@ func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1697 int - var yyb1697 bool - var yyhl1697 bool = l >= 0 - yyj1697++ - if yyhl1697 { - yyb1697 = yyj1697 > l + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1697 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1697 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19939,15 +17743,21 @@ func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } } - yyj1697++ - if yyhl1697 { - yyb1697 = yyj1697 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1697 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1697 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19955,32 +17765,44 @@ func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj1697++ - if yyhl1697 { - yyb1697 = yyj1697 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1697 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1697 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv1700 := &x.ObjectMeta - yyv1700.CodecDecodeSelf(d) + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } } - yyj1697++ - if yyhl1697 { - yyb1697 = yyj1697 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1697 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1697 { + if yyb11 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -19988,21 +17810,21 @@ func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Spec = NetworkPolicySpec{} } else { - yyv1701 := &x.Spec - yyv1701.CodecDecodeSelf(d) + yyv18 := &x.Spec + yyv18.CodecDecodeSelf(d) } for { - yyj1697++ - if yyhl1697 { - yyb1697 = yyj1697 > l + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l } else { - yyb1697 = r.CheckBreak() + yyb11 = r.CheckBreak() } - if yyb1697 { + if yyb11 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1697-1, "") + z.DecStructFieldNotFound(yyj11-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20014,61 +17836,61 @@ func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1702 := z.EncBinary() - _ = yym1702 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1703 := !z.EncBinary() - yy2arr1703 := z.EncBasicHandle().StructToArray - var yyq1703 [2]bool - _, _, _ = yysep1703, yyq1703, yy2arr1703 - const yyr1703 bool = false - yyq1703[1] = len(x.Ingress) != 0 - var yynn1703 int - if yyr1703 || yy2arr1703 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Ingress) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1703 = 1 - for _, b := range yyq1703 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1703++ + yynn2++ } } - r.EncodeMapStart(yynn1703) - yynn1703 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1703 || yy2arr1703 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1705 := &x.PodSelector - yym1706 := z.EncBinary() - _ = yym1706 + yy4 := &x.PodSelector + yym5 := z.EncBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.EncExt(yy1705) { + } else if z.HasExtensions() && z.EncExt(yy4) { } else { - z.EncFallback(yy1705) + z.EncFallback(yy4) } } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1707 := &x.PodSelector - yym1708 := z.EncBinary() - _ = yym1708 + yy6 := &x.PodSelector + yym7 := z.EncBinary() + _ = yym7 if false { - } else if z.HasExtensions() && z.EncExt(yy1707) { + } else if z.HasExtensions() && z.EncExt(yy6) { } else { - z.EncFallback(yy1707) + z.EncFallback(yy6) } } - if yyr1703 || yy2arr1703 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1703[1] { + if yyq2[1] { if x.Ingress == nil { r.EncodeNil() } else { - yym1710 := z.EncBinary() - _ = yym1710 + yym9 := z.EncBinary() + _ = yym9 if false { } else { h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) @@ -20078,15 +17900,15 @@ func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1703[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ingress")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ingress == nil { r.EncodeNil() } else { - yym1711 := z.EncBinary() - _ = yym1711 + yym10 := z.EncBinary() + _ = yym10 if false { } else { h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) @@ -20094,7 +17916,7 @@ func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1703 || yy2arr1703 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -20107,25 +17929,25 @@ func (x *NetworkPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1712 := z.DecBinary() - _ = yym1712 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1713 := r.ContainerType() - if yyct1713 == codecSelferValueTypeMap1234 { - yyl1713 := r.ReadMapStart() - if yyl1713 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1713, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1713 == codecSelferValueTypeArray1234 { - yyl1713 := r.ReadArrayStart() - if yyl1713 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1713, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -20137,12 +17959,12 @@ func (x *NetworkPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1714Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1714Slc - var yyhl1714 bool = l >= 0 - for yyj1714 := 0; ; yyj1714++ { - if yyhl1714 { - if yyj1714 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -20151,39 +17973,39 @@ func (x *NetworkPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1714Slc = r.DecodeBytes(yys1714Slc, true, true) - yys1714 := string(yys1714Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1714 { + switch yys3 { case "podSelector": if r.TryDecodeAsNil() { - x.PodSelector = pkg1_unversioned.LabelSelector{} + x.PodSelector = pkg1_v1.LabelSelector{} } else { - yyv1715 := &x.PodSelector - yym1716 := z.DecBinary() - _ = yym1716 + yyv4 := &x.PodSelector + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv1715) { + } else if z.HasExtensions() && z.DecExt(yyv4) { } else { - z.DecFallback(yyv1715, false) + z.DecFallback(yyv4, false) } } case "ingress": if r.TryDecodeAsNil() { x.Ingress = nil } else { - yyv1717 := &x.Ingress - yym1718 := z.DecBinary() - _ = yym1718 + yyv6 := &x.Ingress + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv1717), d) + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv6), d) } } default: - z.DecStructFieldNotFound(-1, yys1714) - } // end switch yys1714 - } // end for yyj1714 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -20191,39 +18013,39 @@ func (x *NetworkPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1719 int - var yyb1719 bool - var yyhl1719 bool = l >= 0 - yyj1719++ - if yyhl1719 { - yyb1719 = yyj1719 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1719 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1719 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.PodSelector = pkg1_unversioned.LabelSelector{} + x.PodSelector = pkg1_v1.LabelSelector{} } else { - yyv1720 := &x.PodSelector - yym1721 := z.DecBinary() - _ = yym1721 + yyv9 := &x.PodSelector + yym10 := z.DecBinary() + _ = yym10 if false { - } else if z.HasExtensions() && z.DecExt(yyv1720) { + } else if z.HasExtensions() && z.DecExt(yyv9) { } else { - z.DecFallback(yyv1720, false) + z.DecFallback(yyv9, false) } } - yyj1719++ - if yyhl1719 { - yyb1719 = yyj1719 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1719 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1719 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20231,26 +18053,26 @@ func (x *NetworkPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Ingress = nil } else { - yyv1722 := &x.Ingress - yym1723 := z.DecBinary() - _ = yym1723 + yyv11 := &x.Ingress + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv1722), d) + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv11), d) } } for { - yyj1719++ - if yyhl1719 { - yyb1719 = yyj1719 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1719 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1719 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1719-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20262,39 +18084,39 @@ func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1724 := z.EncBinary() - _ = yym1724 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1725 := !z.EncBinary() - yy2arr1725 := z.EncBasicHandle().StructToArray - var yyq1725 [2]bool - _, _, _ = yysep1725, yyq1725, yy2arr1725 - const yyr1725 bool = false - yyq1725[0] = len(x.Ports) != 0 - yyq1725[1] = len(x.From) != 0 - var yynn1725 int - if yyr1725 || yy2arr1725 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Ports) != 0 + yyq2[1] = len(x.From) != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1725 = 0 - for _, b := range yyq1725 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1725++ + yynn2++ } } - r.EncodeMapStart(yynn1725) - yynn1725 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1725 || yy2arr1725 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1725[0] { + if yyq2[0] { if x.Ports == nil { r.EncodeNil() } else { - yym1727 := z.EncBinary() - _ = yym1727 + yym4 := z.EncBinary() + _ = yym4 if false { } else { h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) @@ -20304,15 +18126,15 @@ func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1725[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("ports")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Ports == nil { r.EncodeNil() } else { - yym1728 := z.EncBinary() - _ = yym1728 + yym5 := z.EncBinary() + _ = yym5 if false { } else { h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) @@ -20320,14 +18142,14 @@ func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1725 || yy2arr1725 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1725[1] { + if yyq2[1] { if x.From == nil { r.EncodeNil() } else { - yym1730 := z.EncBinary() - _ = yym1730 + yym7 := z.EncBinary() + _ = yym7 if false { } else { h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) @@ -20337,15 +18159,15 @@ func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1725[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("from")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.From == nil { r.EncodeNil() } else { - yym1731 := z.EncBinary() - _ = yym1731 + yym8 := z.EncBinary() + _ = yym8 if false { } else { h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) @@ -20353,7 +18175,7 @@ func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1725 || yy2arr1725 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -20366,25 +18188,25 @@ func (x *NetworkPolicyIngressRule) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1732 := z.DecBinary() - _ = yym1732 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1733 := r.ContainerType() - if yyct1733 == codecSelferValueTypeMap1234 { - yyl1733 := r.ReadMapStart() - if yyl1733 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1733, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1733 == codecSelferValueTypeArray1234 { - yyl1733 := r.ReadArrayStart() - if yyl1733 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1733, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -20396,12 +18218,12 @@ func (x *NetworkPolicyIngressRule) codecDecodeSelfFromMap(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1734Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1734Slc - var yyhl1734 bool = l >= 0 - for yyj1734 := 0; ; yyj1734++ { - if yyhl1734 { - if yyj1734 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -20410,38 +18232,38 @@ func (x *NetworkPolicyIngressRule) codecDecodeSelfFromMap(l int, d *codec1978.De } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1734Slc = r.DecodeBytes(yys1734Slc, true, true) - yys1734 := string(yys1734Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1734 { + switch yys3 { case "ports": if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv1735 := &x.Ports - yym1736 := z.DecBinary() - _ = yym1736 + yyv4 := &x.Ports + yym5 := z.DecBinary() + _ = yym5 if false { } else { - h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv1735), d) + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv4), d) } } case "from": if r.TryDecodeAsNil() { x.From = nil } else { - yyv1737 := &x.From - yym1738 := z.DecBinary() - _ = yym1738 + yyv6 := &x.From + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv1737), d) + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv6), d) } } default: - z.DecStructFieldNotFound(-1, yys1734) - } // end switch yys1734 - } // end for yyj1734 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -20449,16 +18271,16 @@ func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978. var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1739 int - var yyb1739 bool - var yyhl1739 bool = l >= 0 - yyj1739++ - if yyhl1739 { - yyb1739 = yyj1739 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1739 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1739 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20466,21 +18288,21 @@ func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.Ports = nil } else { - yyv1740 := &x.Ports - yym1741 := z.DecBinary() - _ = yym1741 + yyv9 := &x.Ports + yym10 := z.DecBinary() + _ = yym10 if false { } else { - h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv1740), d) + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv9), d) } } - yyj1739++ - if yyhl1739 { - yyb1739 = yyj1739 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1739 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1739 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20488,26 +18310,26 @@ func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978. if r.TryDecodeAsNil() { x.From = nil } else { - yyv1742 := &x.From - yym1743 := z.DecBinary() - _ = yym1743 + yyv11 := &x.From + yym12 := z.DecBinary() + _ = yym12 if false { } else { - h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv1742), d) + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv11), d) } } for { - yyj1739++ - if yyhl1739 { - yyb1739 = yyj1739 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1739 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1739 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1739-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20519,79 +18341,69 @@ func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1744 := z.EncBinary() - _ = yym1744 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1745 := !z.EncBinary() - yy2arr1745 := z.EncBasicHandle().StructToArray - var yyq1745 [2]bool - _, _, _ = yysep1745, yyq1745, yy2arr1745 - const yyr1745 bool = false - yyq1745[0] = x.Protocol != nil - yyq1745[1] = x.Port != nil - var yynn1745 int - if yyr1745 || yy2arr1745 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Protocol != nil + yyq2[1] = x.Port != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1745 = 0 - for _, b := range yyq1745 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1745++ + yynn2++ } } - r.EncodeMapStart(yynn1745) - yynn1745 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1745 || yy2arr1745 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1745[0] { + if yyq2[0] { if x.Protocol == nil { r.EncodeNil() } else { - yy1747 := *x.Protocol - yym1748 := z.EncBinary() - _ = yym1748 - if false { - } else if z.HasExtensions() && z.EncExt(yy1747) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1747)) - } + yy4 := *x.Protocol + yysf5 := &yy4 + yysf5.CodecEncodeSelf(e) } } else { r.EncodeNil() } } else { - if yyq1745[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("protocol")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Protocol == nil { r.EncodeNil() } else { - yy1749 := *x.Protocol - yym1750 := z.EncBinary() - _ = yym1750 - if false { - } else if z.HasExtensions() && z.EncExt(yy1749) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yy1749)) - } + yy6 := *x.Protocol + yysf7 := &yy6 + yysf7.CodecEncodeSelf(e) } } } - if yyr1745 || yy2arr1745 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1745[1] { + if yyq2[1] { if x.Port == nil { r.EncodeNil() } else { - yym1752 := z.EncBinary() - _ = yym1752 + yym9 := z.EncBinary() + _ = yym9 if false { } else if z.HasExtensions() && z.EncExt(x.Port) { - } else if !yym1752 && z.IsJSONHandle() { + } else if !yym9 && z.IsJSONHandle() { z.EncJSONMarshal(x.Port) } else { z.EncFallback(x.Port) @@ -20601,18 +18413,18 @@ func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1745[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("port")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Port == nil { r.EncodeNil() } else { - yym1753 := z.EncBinary() - _ = yym1753 + yym10 := z.EncBinary() + _ = yym10 if false { } else if z.HasExtensions() && z.EncExt(x.Port) { - } else if !yym1753 && z.IsJSONHandle() { + } else if !yym10 && z.IsJSONHandle() { z.EncJSONMarshal(x.Port) } else { z.EncFallback(x.Port) @@ -20620,7 +18432,7 @@ func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1745 || yy2arr1745 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -20633,25 +18445,25 @@ func (x *NetworkPolicyPort) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1754 := z.DecBinary() - _ = yym1754 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1755 := r.ContainerType() - if yyct1755 == codecSelferValueTypeMap1234 { - yyl1755 := r.ReadMapStart() - if yyl1755 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1755, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1755 == codecSelferValueTypeArray1234 { - yyl1755 := r.ReadArrayStart() - if yyl1755 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1755, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -20663,12 +18475,12 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1756Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1756Slc - var yyhl1756 bool = l >= 0 - for yyj1756 := 0; ; yyj1756++ { - if yyhl1756 { - if yyj1756 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -20677,10 +18489,10 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1756Slc = r.DecodeBytes(yys1756Slc, true, true) - yys1756 := string(yys1756Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1756 { + switch yys3 { case "protocol": if r.TryDecodeAsNil() { if x.Protocol != nil { @@ -20688,7 +18500,7 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } else { if x.Protocol == nil { - x.Protocol = new(pkg2_v1.Protocol) + x.Protocol = new(pkg4_v1.Protocol) } x.Protocol.CodecDecodeSelf(d) } @@ -20701,20 +18513,20 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) if x.Port == nil { x.Port = new(pkg5_intstr.IntOrString) } - yym1759 := z.DecBinary() - _ = yym1759 + yym6 := z.DecBinary() + _ = yym6 if false { } else if z.HasExtensions() && z.DecExt(x.Port) { - } else if !yym1759 && z.IsJSONHandle() { + } else if !yym6 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.Port) } else { z.DecFallback(x.Port, false) } } default: - z.DecStructFieldNotFound(-1, yys1756) - } // end switch yys1756 - } // end for yyj1756 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -20722,16 +18534,16 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1760 int - var yyb1760 bool - var yyhl1760 bool = l >= 0 - yyj1760++ - if yyhl1760 { - yyb1760 = yyj1760 > l + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1760 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1760 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20742,17 +18554,17 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder } } else { if x.Protocol == nil { - x.Protocol = new(pkg2_v1.Protocol) + x.Protocol = new(pkg4_v1.Protocol) } x.Protocol.CodecDecodeSelf(d) } - yyj1760++ - if yyhl1760 { - yyb1760 = yyj1760 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1760 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1760 { + if yyb7 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -20765,28 +18577,28 @@ func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if x.Port == nil { x.Port = new(pkg5_intstr.IntOrString) } - yym1763 := z.DecBinary() - _ = yym1763 + yym10 := z.DecBinary() + _ = yym10 if false { } else if z.HasExtensions() && z.DecExt(x.Port) { - } else if !yym1763 && z.IsJSONHandle() { + } else if !yym10 && z.IsJSONHandle() { z.DecJSONUnmarshal(x.Port) } else { z.DecFallback(x.Port, false) } } for { - yyj1760++ - if yyhl1760 { - yyb1760 = yyj1760 > l + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l } else { - yyb1760 = r.CheckBreak() + yyb7 = r.CheckBreak() } - if yyb1760 { + if yyb7 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1760-1, "") + z.DecStructFieldNotFound(yyj7-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -20798,39 +18610,39 @@ func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1764 := z.EncBinary() - _ = yym1764 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1765 := !z.EncBinary() - yy2arr1765 := z.EncBasicHandle().StructToArray - var yyq1765 [2]bool - _, _, _ = yysep1765, yyq1765, yy2arr1765 - const yyr1765 bool = false - yyq1765[0] = x.PodSelector != nil - yyq1765[1] = x.NamespaceSelector != nil - var yynn1765 int - if yyr1765 || yy2arr1765 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PodSelector != nil + yyq2[1] = x.NamespaceSelector != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(2) } else { - yynn1765 = 0 - for _, b := range yyq1765 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn1765++ + yynn2++ } } - r.EncodeMapStart(yynn1765) - yynn1765 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1765 || yy2arr1765 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1765[0] { + if yyq2[0] { if x.PodSelector == nil { r.EncodeNil() } else { - yym1767 := z.EncBinary() - _ = yym1767 + yym4 := z.EncBinary() + _ = yym4 if false { } else if z.HasExtensions() && z.EncExt(x.PodSelector) { } else { @@ -20841,15 +18653,15 @@ func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1765[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("podSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.PodSelector == nil { r.EncodeNil() } else { - yym1768 := z.EncBinary() - _ = yym1768 + yym5 := z.EncBinary() + _ = yym5 if false { } else if z.HasExtensions() && z.EncExt(x.PodSelector) { } else { @@ -20858,14 +18670,14 @@ func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1765 || yy2arr1765 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1765[1] { + if yyq2[1] { if x.NamespaceSelector == nil { r.EncodeNil() } else { - yym1770 := z.EncBinary() - _ = yym1770 + yym7 := z.EncBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { } else { @@ -20876,15 +18688,15 @@ func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq1765[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("namespaceSelector")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.NamespaceSelector == nil { r.EncodeNil() } else { - yym1771 := z.EncBinary() - _ = yym1771 + yym8 := z.EncBinary() + _ = yym8 if false { } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { } else { @@ -20893,7 +18705,7 @@ func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { } } } - if yyr1765 || yy2arr1765 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -20906,25 +18718,25 @@ func (x *NetworkPolicyPeer) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1772 := z.DecBinary() - _ = yym1772 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1773 := r.ContainerType() - if yyct1773 == codecSelferValueTypeMap1234 { - yyl1773 := r.ReadMapStart() - if yyl1773 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1773, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1773 == codecSelferValueTypeArray1234 { - yyl1773 := r.ReadArrayStart() - if yyl1773 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1773, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -20936,12 +18748,12 @@ func (x *NetworkPolicyPeer) 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 { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -20950,10 +18762,10 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1774Slc = r.DecodeBytes(yys1774Slc, true, true) - yys1774 := string(yys1774Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1774 { + switch yys3 { case "podSelector": if r.TryDecodeAsNil() { if x.PodSelector != nil { @@ -20961,10 +18773,10 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } else { if x.PodSelector == nil { - x.PodSelector = new(pkg1_unversioned.LabelSelector) + x.PodSelector = new(pkg1_v1.LabelSelector) } - yym1776 := z.DecBinary() - _ = yym1776 + yym5 := z.DecBinary() + _ = yym5 if false { } else if z.HasExtensions() && z.DecExt(x.PodSelector) { } else { @@ -20978,10 +18790,10 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } else { if x.NamespaceSelector == nil { - x.NamespaceSelector = new(pkg1_unversioned.LabelSelector) + x.NamespaceSelector = new(pkg1_v1.LabelSelector) } - yym1778 := z.DecBinary() - _ = yym1778 + yym7 := z.DecBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { } else { @@ -20989,9 +18801,9 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } default: - z.DecStructFieldNotFound(-1, yys1774) - } // end switch yys1774 - } // end for yyj1774 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -20999,16 +18811,16 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj1779 int - var yyb1779 bool - var yyhl1779 bool = l >= 0 - yyj1779++ - if yyhl1779 { - yyb1779 = yyj1779 > l + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1779 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1779 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21019,23 +18831,23 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder } } else { if x.PodSelector == nil { - x.PodSelector = new(pkg1_unversioned.LabelSelector) + x.PodSelector = new(pkg1_v1.LabelSelector) } - yym1781 := z.DecBinary() - _ = yym1781 + yym10 := z.DecBinary() + _ = yym10 if false { } else if z.HasExtensions() && z.DecExt(x.PodSelector) { } else { z.DecFallback(x.PodSelector, false) } } - yyj1779++ - if yyhl1779 { - yyb1779 = yyj1779 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1779 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1779 { + if yyb8 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21046,10 +18858,10 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder } } else { if x.NamespaceSelector == nil { - x.NamespaceSelector = new(pkg1_unversioned.LabelSelector) + x.NamespaceSelector = new(pkg1_v1.LabelSelector) } - yym1783 := z.DecBinary() - _ = yym1783 + yym12 := z.DecBinary() + _ = yym12 if false { } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { } else { @@ -21057,17 +18869,17 @@ func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder } } for { - yyj1779++ - if yyhl1779 { - yyb1779 = yyj1779 > l + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l } else { - yyb1779 = r.CheckBreak() + yyb8 = r.CheckBreak() } - if yyb1779 { + if yyb8 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1779-1, "") + z.DecStructFieldNotFound(yyj8-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21079,37 +18891,37 @@ func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym1784 := z.EncBinary() - _ = yym1784 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep1785 := !z.EncBinary() - yy2arr1785 := z.EncBasicHandle().StructToArray - var yyq1785 [4]bool - _, _, _ = yysep1785, yyq1785, yy2arr1785 - const yyr1785 bool = false - yyq1785[0] = x.Kind != "" - yyq1785[1] = x.APIVersion != "" - yyq1785[2] = true - var yynn1785 int - if yyr1785 || yy2arr1785 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn1785 = 1 - for _, b := range yyq1785 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn1785++ + yynn2++ } } - r.EncodeMapStart(yynn1785) - yynn1785 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr1785 || yy2arr1785 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1785[0] { - yym1787 := z.EncBinary() - _ = yym1787 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -21118,23 +18930,23 @@ func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1785[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1788 := z.EncBinary() - _ = yym1788 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr1785 || yy2arr1785 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1785[1] { - yym1790 := z.EncBinary() - _ = yym1790 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -21143,54 +18955,54 @@ func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq1785[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym1791 := z.EncBinary() - _ = yym1791 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr1785 || yy2arr1785 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq1785[2] { - yy1793 := &x.ListMeta - yym1794 := z.EncBinary() - _ = yym1794 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy1793) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy1793) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq1785[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy1795 := &x.ListMeta - yym1796 := z.EncBinary() - _ = yym1796 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy1795) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy1795) + z.EncFallback(yy12) } } } - if yyr1785 || yy2arr1785 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym1798 := z.EncBinary() - _ = yym1798 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) @@ -21203,15 +19015,15 @@ func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym1799 := z.EncBinary() - _ = yym1799 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) } } } - if yyr1785 || yy2arr1785 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -21224,25 +19036,25 @@ func (x *NetworkPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym1800 := z.DecBinary() - _ = yym1800 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct1801 := r.ContainerType() - if yyct1801 == codecSelferValueTypeMap1234 { - yyl1801 := r.ReadMapStart() - if yyl1801 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl1801, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct1801 == codecSelferValueTypeArray1234 { - yyl1801 := r.ReadArrayStart() - if yyl1801 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl1801, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -21254,12 +19066,12 @@ func (x *NetworkPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys1802Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys1802Slc - var yyhl1802 bool = l >= 0 - for yyj1802 := 0; ; yyj1802++ { - if yyhl1802 { - if yyj1802 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -21268,51 +19080,63 @@ func (x *NetworkPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys1802Slc = r.DecodeBytes(yys1802Slc, true, true) - yys1802 := string(yys1802Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys1802 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1805 := &x.ListMeta - yym1806 := z.DecBinary() - _ = yym1806 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv1805) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv1805, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1807 := &x.Items - yym1808 := z.DecBinary() - _ = yym1808 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv1807), d) + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys1802) - } // end switch yys1802 - } // end for yyj1802 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -21320,16 +19144,16 @@ func (x *NetworkPolicyList) 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 + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1809 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1809 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21337,15 +19161,21 @@ func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1809 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1809 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21353,38 +19183,44 @@ func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1809 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1809 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv1812 := &x.ListMeta - yym1813 := z.DecBinary() - _ = yym1813 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv1812) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv1812, false) + z.DecFallback(yyv17, false) } } - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1809 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1809 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -21392,26 +19228,26 @@ func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder if r.TryDecodeAsNil() { x.Items = nil } else { - yyv1814 := &x.Items - yym1815 := z.DecBinary() - _ = yym1815 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv1814), d) + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv19), d) } } for { - yyj1809++ - if yyhl1809 { - yyb1809 = yyj1809 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb1809 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb1809 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj1809-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21421,10 +19257,10 @@ func (x codecSelfer1234) encSliceCustomMetricTarget(v []CustomMetricTarget, e *c z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1816 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1817 := &yyv1816 - yy1817.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21434,83 +19270,86 @@ func (x codecSelfer1234) decSliceCustomMetricTarget(v *[]CustomMetricTarget, d * z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1818 := *v - yyh1818, yyl1818 := z.DecSliceHelperStart() - var yyc1818 bool - if yyl1818 == 0 { - if yyv1818 == nil { - yyv1818 = []CustomMetricTarget{} - yyc1818 = true - } else if len(yyv1818) != 0 { - yyv1818 = yyv1818[:0] - yyc1818 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []CustomMetricTarget{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1818 > 0 { - var yyrr1818, yyrl1818 int - var yyrt1818 bool - if yyl1818 > cap(yyv1818) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1818 := len(yyv1818) > 0 - yyv21818 := yyv1818 - yyrl1818, yyrt1818 = z.DecInferLen(yyl1818, z.DecBasicHandle().MaxInitLen, 72) - if yyrt1818 { - if yyrl1818 <= cap(yyv1818) { - yyv1818 = yyv1818[:yyrl1818] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1818 = make([]CustomMetricTarget, yyrl1818) + yyv1 = make([]CustomMetricTarget, yyrl1) } } else { - yyv1818 = make([]CustomMetricTarget, yyrl1818) + yyv1 = make([]CustomMetricTarget, yyrl1) } - yyc1818 = true - yyrr1818 = len(yyv1818) - if yyrg1818 { - copy(yyv1818, yyv21818) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1818 != len(yyv1818) { - yyv1818 = yyv1818[:yyl1818] - yyc1818 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1818 := 0 - for ; yyj1818 < yyrr1818; yyj1818++ { - yyh1818.ElemContainerState(yyj1818) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1818[yyj1818] = CustomMetricTarget{} + yyv1[yyj1] = CustomMetricTarget{} } else { - yyv1819 := &yyv1818[yyj1818] - yyv1819.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1818 { - for ; yyj1818 < yyl1818; yyj1818++ { - yyv1818 = append(yyv1818, CustomMetricTarget{}) - yyh1818.ElemContainerState(yyj1818) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, CustomMetricTarget{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1818[yyj1818] = CustomMetricTarget{} + yyv1[yyj1] = CustomMetricTarget{} } else { - yyv1820 := &yyv1818[yyj1818] - yyv1820.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1818 := 0 - for ; !r.CheckBreak(); yyj1818++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1818 >= len(yyv1818) { - yyv1818 = append(yyv1818, CustomMetricTarget{}) // var yyz1818 CustomMetricTarget - yyc1818 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, CustomMetricTarget{}) // var yyz1 CustomMetricTarget + yyc1 = true } - yyh1818.ElemContainerState(yyj1818) - if yyj1818 < len(yyv1818) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1818[yyj1818] = CustomMetricTarget{} + yyv1[yyj1] = CustomMetricTarget{} } else { - yyv1821 := &yyv1818[yyj1818] - yyv1821.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -21518,17 +19357,17 @@ func (x codecSelfer1234) decSliceCustomMetricTarget(v *[]CustomMetricTarget, d * } } - if yyj1818 < len(yyv1818) { - yyv1818 = yyv1818[:yyj1818] - yyc1818 = true - } else if yyj1818 == 0 && yyv1818 == nil { - yyv1818 = []CustomMetricTarget{} - yyc1818 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []CustomMetricTarget{} + yyc1 = true } } - yyh1818.End() - if yyc1818 { - *v = yyv1818 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -21537,10 +19376,10 @@ func (x codecSelfer1234) encSliceCustomMetricCurrentStatus(v []CustomMetricCurre z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1822 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1823 := &yyv1822 - yy1823.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21550,199 +19389,86 @@ func (x codecSelfer1234) decSliceCustomMetricCurrentStatus(v *[]CustomMetricCurr z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1824 := *v - yyh1824, yyl1824 := z.DecSliceHelperStart() - var yyc1824 bool - if yyl1824 == 0 { - if yyv1824 == nil { - yyv1824 = []CustomMetricCurrentStatus{} - yyc1824 = true - } else if len(yyv1824) != 0 { - yyv1824 = yyv1824[:0] - yyc1824 = true - } - } else if yyl1824 > 0 { - var yyrr1824, yyrl1824 int - var yyrt1824 bool - if yyl1824 > cap(yyv1824) { - - yyrg1824 := len(yyv1824) > 0 - yyv21824 := yyv1824 - yyrl1824, yyrt1824 = z.DecInferLen(yyl1824, z.DecBasicHandle().MaxInitLen, 72) - if yyrt1824 { - if yyrl1824 <= cap(yyv1824) { - yyv1824 = yyv1824[:yyrl1824] - } else { - yyv1824 = make([]CustomMetricCurrentStatus, yyrl1824) - } - } else { - yyv1824 = make([]CustomMetricCurrentStatus, yyrl1824) - } - yyc1824 = true - yyrr1824 = len(yyv1824) - if yyrg1824 { - copy(yyv1824, yyv21824) - } - } else if yyl1824 != len(yyv1824) { - yyv1824 = yyv1824[:yyl1824] - yyc1824 = true - } - yyj1824 := 0 - for ; yyj1824 < yyrr1824; yyj1824++ { - yyh1824.ElemContainerState(yyj1824) - if r.TryDecodeAsNil() { - yyv1824[yyj1824] = CustomMetricCurrentStatus{} - } else { - yyv1825 := &yyv1824[yyj1824] - yyv1825.CodecDecodeSelf(d) - } - - } - if yyrt1824 { - for ; yyj1824 < yyl1824; yyj1824++ { - yyv1824 = append(yyv1824, CustomMetricCurrentStatus{}) - yyh1824.ElemContainerState(yyj1824) - if r.TryDecodeAsNil() { - yyv1824[yyj1824] = CustomMetricCurrentStatus{} - } else { - yyv1826 := &yyv1824[yyj1824] - yyv1826.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1824 := 0 - for ; !r.CheckBreak(); yyj1824++ { - - if yyj1824 >= len(yyv1824) { - yyv1824 = append(yyv1824, CustomMetricCurrentStatus{}) // var yyz1824 CustomMetricCurrentStatus - yyc1824 = true - } - yyh1824.ElemContainerState(yyj1824) - if yyj1824 < len(yyv1824) { - if r.TryDecodeAsNil() { - yyv1824[yyj1824] = CustomMetricCurrentStatus{} - } else { - yyv1827 := &yyv1824[yyj1824] - yyv1827.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1824 < len(yyv1824) { - yyv1824 = yyv1824[:yyj1824] - yyc1824 = true - } else if yyj1824 == 0 && yyv1824 == nil { - yyv1824 = []CustomMetricCurrentStatus{} - yyc1824 = true - } - } - yyh1824.End() - if yyc1824 { - *v = yyv1824 - } -} - -func (x codecSelfer1234) encSliceHorizontalPodAutoscaler(v []HorizontalPodAutoscaler, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1828 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1829 := &yyv1828 - yy1829.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceHorizontalPodAutoscaler(v *[]HorizontalPodAutoscaler, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1830 := *v - yyh1830, yyl1830 := z.DecSliceHelperStart() - var yyc1830 bool - if yyl1830 == 0 { - if yyv1830 == nil { - yyv1830 = []HorizontalPodAutoscaler{} - yyc1830 = true - } else if len(yyv1830) != 0 { - yyv1830 = yyv1830[:0] - yyc1830 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []CustomMetricCurrentStatus{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1830 > 0 { - var yyrr1830, yyrl1830 int - var yyrt1830 bool - if yyl1830 > cap(yyv1830) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1830 := len(yyv1830) > 0 - yyv21830 := yyv1830 - yyrl1830, yyrt1830 = z.DecInferLen(yyl1830, z.DecBasicHandle().MaxInitLen, 376) - if yyrt1830 { - if yyrl1830 <= cap(yyv1830) { - yyv1830 = yyv1830[:yyrl1830] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 72) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1830 = make([]HorizontalPodAutoscaler, yyrl1830) + yyv1 = make([]CustomMetricCurrentStatus, yyrl1) } } else { - yyv1830 = make([]HorizontalPodAutoscaler, yyrl1830) + yyv1 = make([]CustomMetricCurrentStatus, yyrl1) } - yyc1830 = true - yyrr1830 = len(yyv1830) - if yyrg1830 { - copy(yyv1830, yyv21830) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1830 != len(yyv1830) { - yyv1830 = yyv1830[:yyl1830] - yyc1830 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1830 := 0 - for ; yyj1830 < yyrr1830; yyj1830++ { - yyh1830.ElemContainerState(yyj1830) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1830[yyj1830] = HorizontalPodAutoscaler{} + yyv1[yyj1] = CustomMetricCurrentStatus{} } else { - yyv1831 := &yyv1830[yyj1830] - yyv1831.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1830 { - for ; yyj1830 < yyl1830; yyj1830++ { - yyv1830 = append(yyv1830, HorizontalPodAutoscaler{}) - yyh1830.ElemContainerState(yyj1830) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, CustomMetricCurrentStatus{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1830[yyj1830] = HorizontalPodAutoscaler{} + yyv1[yyj1] = CustomMetricCurrentStatus{} } else { - yyv1832 := &yyv1830[yyj1830] - yyv1832.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1830 := 0 - for ; !r.CheckBreak(); yyj1830++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1830 >= len(yyv1830) { - yyv1830 = append(yyv1830, HorizontalPodAutoscaler{}) // var yyz1830 HorizontalPodAutoscaler - yyc1830 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, CustomMetricCurrentStatus{}) // var yyz1 CustomMetricCurrentStatus + yyc1 = true } - yyh1830.ElemContainerState(yyj1830) - if yyj1830 < len(yyv1830) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1830[yyj1830] = HorizontalPodAutoscaler{} + yyv1[yyj1] = CustomMetricCurrentStatus{} } else { - yyv1833 := &yyv1830[yyj1830] - yyv1833.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -21750,17 +19476,17 @@ func (x codecSelfer1234) decSliceHorizontalPodAutoscaler(v *[]HorizontalPodAutos } } - if yyj1830 < len(yyv1830) { - yyv1830 = yyv1830[:yyj1830] - yyc1830 = true - } else if yyj1830 == 0 && yyv1830 == nil { - yyv1830 = []HorizontalPodAutoscaler{} - yyc1830 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []CustomMetricCurrentStatus{} + yyc1 = true } } - yyh1830.End() - if yyc1830 { - *v = yyv1830 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -21769,10 +19495,10 @@ func (x codecSelfer1234) encSliceAPIVersion(v []APIVersion, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1834 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1835 := &yyv1834 - yy1835.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21782,83 +19508,86 @@ func (x codecSelfer1234) decSliceAPIVersion(v *[]APIVersion, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1836 := *v - yyh1836, yyl1836 := z.DecSliceHelperStart() - var yyc1836 bool - if yyl1836 == 0 { - if yyv1836 == nil { - yyv1836 = []APIVersion{} - yyc1836 = true - } else if len(yyv1836) != 0 { - yyv1836 = yyv1836[:0] - yyc1836 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []APIVersion{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1836 > 0 { - var yyrr1836, yyrl1836 int - var yyrt1836 bool - if yyl1836 > cap(yyv1836) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1836 := len(yyv1836) > 0 - yyv21836 := yyv1836 - yyrl1836, yyrt1836 = z.DecInferLen(yyl1836, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1836 { - if yyrl1836 <= cap(yyv1836) { - yyv1836 = yyv1836[:yyrl1836] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1836 = make([]APIVersion, yyrl1836) + yyv1 = make([]APIVersion, yyrl1) } } else { - yyv1836 = make([]APIVersion, yyrl1836) + yyv1 = make([]APIVersion, yyrl1) } - yyc1836 = true - yyrr1836 = len(yyv1836) - if yyrg1836 { - copy(yyv1836, yyv21836) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1836 != len(yyv1836) { - yyv1836 = yyv1836[:yyl1836] - yyc1836 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1836 := 0 - for ; yyj1836 < yyrr1836; yyj1836++ { - yyh1836.ElemContainerState(yyj1836) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1836[yyj1836] = APIVersion{} + yyv1[yyj1] = APIVersion{} } else { - yyv1837 := &yyv1836[yyj1836] - yyv1837.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1836 { - for ; yyj1836 < yyl1836; yyj1836++ { - yyv1836 = append(yyv1836, APIVersion{}) - yyh1836.ElemContainerState(yyj1836) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, APIVersion{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1836[yyj1836] = APIVersion{} + yyv1[yyj1] = APIVersion{} } else { - yyv1838 := &yyv1836[yyj1836] - yyv1838.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1836 := 0 - for ; !r.CheckBreak(); yyj1836++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1836 >= len(yyv1836) { - yyv1836 = append(yyv1836, APIVersion{}) // var yyz1836 APIVersion - yyc1836 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, APIVersion{}) // var yyz1 APIVersion + yyc1 = true } - yyh1836.ElemContainerState(yyj1836) - if yyj1836 < len(yyv1836) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1836[yyj1836] = APIVersion{} + yyv1[yyj1] = APIVersion{} } else { - yyv1839 := &yyv1836[yyj1836] - yyv1839.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -21866,17 +19595,17 @@ func (x codecSelfer1234) decSliceAPIVersion(v *[]APIVersion, d *codec1978.Decode } } - if yyj1836 < len(yyv1836) { - yyv1836 = yyv1836[:yyj1836] - yyc1836 = true - } else if yyj1836 == 0 && yyv1836 == nil { - yyv1836 = []APIVersion{} - yyc1836 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []APIVersion{} + yyc1 = true } } - yyh1836.End() - if yyc1836 { - *v = yyv1836 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -21885,10 +19614,10 @@ func (x codecSelfer1234) encSliceThirdPartyResource(v []ThirdPartyResource, e *c z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1840 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1841 := &yyv1840 - yy1841.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -21898,83 +19627,86 @@ func (x codecSelfer1234) decSliceThirdPartyResource(v *[]ThirdPartyResource, d * z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1842 := *v - yyh1842, yyl1842 := z.DecSliceHelperStart() - var yyc1842 bool - if yyl1842 == 0 { - if yyv1842 == nil { - yyv1842 = []ThirdPartyResource{} - yyc1842 = true - } else if len(yyv1842) != 0 { - yyv1842 = yyv1842[:0] - yyc1842 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ThirdPartyResource{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1842 > 0 { - var yyrr1842, yyrl1842 int - var yyrt1842 bool - if yyl1842 > cap(yyv1842) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1842 := len(yyv1842) > 0 - yyv21842 := yyv1842 - yyrl1842, yyrt1842 = z.DecInferLen(yyl1842, z.DecBasicHandle().MaxInitLen, 296) - if yyrt1842 { - if yyrl1842 <= cap(yyv1842) { - yyv1842 = yyv1842[:yyrl1842] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 304) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1842 = make([]ThirdPartyResource, yyrl1842) + yyv1 = make([]ThirdPartyResource, yyrl1) } } else { - yyv1842 = make([]ThirdPartyResource, yyrl1842) + yyv1 = make([]ThirdPartyResource, yyrl1) } - yyc1842 = true - yyrr1842 = len(yyv1842) - if yyrg1842 { - copy(yyv1842, yyv21842) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1842 != len(yyv1842) { - yyv1842 = yyv1842[:yyl1842] - yyc1842 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1842 := 0 - for ; yyj1842 < yyrr1842; yyj1842++ { - yyh1842.ElemContainerState(yyj1842) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1842[yyj1842] = ThirdPartyResource{} + yyv1[yyj1] = ThirdPartyResource{} } else { - yyv1843 := &yyv1842[yyj1842] - yyv1843.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1842 { - for ; yyj1842 < yyl1842; yyj1842++ { - yyv1842 = append(yyv1842, ThirdPartyResource{}) - yyh1842.ElemContainerState(yyj1842) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ThirdPartyResource{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1842[yyj1842] = ThirdPartyResource{} + yyv1[yyj1] = ThirdPartyResource{} } else { - yyv1844 := &yyv1842[yyj1842] - yyv1844.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1842 := 0 - for ; !r.CheckBreak(); yyj1842++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1842 >= len(yyv1842) { - yyv1842 = append(yyv1842, ThirdPartyResource{}) // var yyz1842 ThirdPartyResource - yyc1842 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ThirdPartyResource{}) // var yyz1 ThirdPartyResource + yyc1 = true } - yyh1842.ElemContainerState(yyj1842) - if yyj1842 < len(yyv1842) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1842[yyj1842] = ThirdPartyResource{} + yyv1[yyj1] = ThirdPartyResource{} } else { - yyv1845 := &yyv1842[yyj1842] - yyv1845.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -21982,17 +19714,17 @@ func (x codecSelfer1234) decSliceThirdPartyResource(v *[]ThirdPartyResource, d * } } - if yyj1842 < len(yyv1842) { - yyv1842 = yyv1842[:yyj1842] - yyc1842 = true - } else if yyj1842 == 0 && yyv1842 == nil { - yyv1842 = []ThirdPartyResource{} - yyc1842 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ThirdPartyResource{} + yyc1 = true } } - yyh1842.End() - if yyc1842 { - *v = yyv1842 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22001,10 +19733,10 @@ func (x codecSelfer1234) encSliceDeploymentCondition(v []DeploymentCondition, e z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1846 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1847 := &yyv1846 - yy1847.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22014,83 +19746,86 @@ func (x codecSelfer1234) decSliceDeploymentCondition(v *[]DeploymentCondition, d z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1848 := *v - yyh1848, yyl1848 := z.DecSliceHelperStart() - var yyc1848 bool - if yyl1848 == 0 { - if yyv1848 == nil { - yyv1848 = []DeploymentCondition{} - yyc1848 = true - } else if len(yyv1848) != 0 { - yyv1848 = yyv1848[:0] - yyc1848 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []DeploymentCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1848 > 0 { - var yyrr1848, yyrl1848 int - var yyrt1848 bool - if yyl1848 > cap(yyv1848) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1848 := len(yyv1848) > 0 - yyv21848 := yyv1848 - yyrl1848, yyrt1848 = z.DecInferLen(yyl1848, z.DecBasicHandle().MaxInitLen, 112) - if yyrt1848 { - if yyrl1848 <= cap(yyv1848) { - yyv1848 = yyv1848[:yyrl1848] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 112) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1848 = make([]DeploymentCondition, yyrl1848) + yyv1 = make([]DeploymentCondition, yyrl1) } } else { - yyv1848 = make([]DeploymentCondition, yyrl1848) + yyv1 = make([]DeploymentCondition, yyrl1) } - yyc1848 = true - yyrr1848 = len(yyv1848) - if yyrg1848 { - copy(yyv1848, yyv21848) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1848 != len(yyv1848) { - yyv1848 = yyv1848[:yyl1848] - yyc1848 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1848 := 0 - for ; yyj1848 < yyrr1848; yyj1848++ { - yyh1848.ElemContainerState(yyj1848) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1848[yyj1848] = DeploymentCondition{} + yyv1[yyj1] = DeploymentCondition{} } else { - yyv1849 := &yyv1848[yyj1848] - yyv1849.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1848 { - for ; yyj1848 < yyl1848; yyj1848++ { - yyv1848 = append(yyv1848, DeploymentCondition{}) - yyh1848.ElemContainerState(yyj1848) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, DeploymentCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1848[yyj1848] = DeploymentCondition{} + yyv1[yyj1] = DeploymentCondition{} } else { - yyv1850 := &yyv1848[yyj1848] - yyv1850.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1848 := 0 - for ; !r.CheckBreak(); yyj1848++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1848 >= len(yyv1848) { - yyv1848 = append(yyv1848, DeploymentCondition{}) // var yyz1848 DeploymentCondition - yyc1848 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, DeploymentCondition{}) // var yyz1 DeploymentCondition + yyc1 = true } - yyh1848.ElemContainerState(yyj1848) - if yyj1848 < len(yyv1848) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1848[yyj1848] = DeploymentCondition{} + yyv1[yyj1] = DeploymentCondition{} } else { - yyv1851 := &yyv1848[yyj1848] - yyv1851.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -22098,17 +19833,17 @@ func (x codecSelfer1234) decSliceDeploymentCondition(v *[]DeploymentCondition, d } } - if yyj1848 < len(yyv1848) { - yyv1848 = yyv1848[:yyj1848] - yyc1848 = true - } else if yyj1848 == 0 && yyv1848 == nil { - yyv1848 = []DeploymentCondition{} - yyc1848 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []DeploymentCondition{} + yyc1 = true } } - yyh1848.End() - if yyc1848 { - *v = yyv1848 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22117,10 +19852,10 @@ func (x codecSelfer1234) encSliceDeployment(v []Deployment, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1852 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1853 := &yyv1852 - yy1853.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22130,83 +19865,86 @@ func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1854 := *v - yyh1854, yyl1854 := z.DecSliceHelperStart() - var yyc1854 bool - if yyl1854 == 0 { - if yyv1854 == nil { - yyv1854 = []Deployment{} - yyc1854 = true - } else if len(yyv1854) != 0 { - yyv1854 = yyv1854[:0] - yyc1854 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Deployment{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1854 > 0 { - var yyrr1854, yyrl1854 int - var yyrt1854 bool - if yyl1854 > cap(yyv1854) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1854 := len(yyv1854) > 0 - yyv21854 := yyv1854 - yyrl1854, yyrt1854 = z.DecInferLen(yyl1854, z.DecBasicHandle().MaxInitLen, 856) - if yyrt1854 { - if yyrl1854 <= cap(yyv1854) { - yyv1854 = yyv1854[:yyrl1854] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 968) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1854 = make([]Deployment, yyrl1854) + yyv1 = make([]Deployment, yyrl1) } } else { - yyv1854 = make([]Deployment, yyrl1854) + yyv1 = make([]Deployment, yyrl1) } - yyc1854 = true - yyrr1854 = len(yyv1854) - if yyrg1854 { - copy(yyv1854, yyv21854) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1854 != len(yyv1854) { - yyv1854 = yyv1854[:yyl1854] - yyc1854 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1854 := 0 - for ; yyj1854 < yyrr1854; yyj1854++ { - yyh1854.ElemContainerState(yyj1854) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1854[yyj1854] = Deployment{} + yyv1[yyj1] = Deployment{} } else { - yyv1855 := &yyv1854[yyj1854] - yyv1855.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1854 { - for ; yyj1854 < yyl1854; yyj1854++ { - yyv1854 = append(yyv1854, Deployment{}) - yyh1854.ElemContainerState(yyj1854) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Deployment{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1854[yyj1854] = Deployment{} + yyv1[yyj1] = Deployment{} } else { - yyv1856 := &yyv1854[yyj1854] - yyv1856.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1854 := 0 - for ; !r.CheckBreak(); yyj1854++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1854 >= len(yyv1854) { - yyv1854 = append(yyv1854, Deployment{}) // var yyz1854 Deployment - yyc1854 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Deployment{}) // var yyz1 Deployment + yyc1 = true } - yyh1854.ElemContainerState(yyj1854) - if yyj1854 < len(yyv1854) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1854[yyj1854] = Deployment{} + yyv1[yyj1] = Deployment{} } else { - yyv1857 := &yyv1854[yyj1854] - yyv1857.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -22214,17 +19952,17 @@ func (x codecSelfer1234) decSliceDeployment(v *[]Deployment, d *codec1978.Decode } } - if yyj1854 < len(yyv1854) { - yyv1854 = yyv1854[:yyj1854] - yyc1854 = true - } else if yyj1854 == 0 && yyv1854 == nil { - yyv1854 = []Deployment{} - yyc1854 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Deployment{} + yyc1 = true } } - yyh1854.End() - if yyc1854 { - *v = yyv1854 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22233,10 +19971,10 @@ func (x codecSelfer1234) encSliceDaemonSet(v []DaemonSet, e *codec1978.Encoder) z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1858 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1859 := &yyv1858 - yy1859.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22246,83 +19984,86 @@ func (x codecSelfer1234) decSliceDaemonSet(v *[]DaemonSet, d *codec1978.Decoder) z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1860 := *v - yyh1860, yyl1860 := z.DecSliceHelperStart() - var yyc1860 bool - if yyl1860 == 0 { - if yyv1860 == nil { - yyv1860 = []DaemonSet{} - yyc1860 = true - } else if len(yyv1860) != 0 { - yyv1860 = yyv1860[:0] - yyc1860 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []DaemonSet{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1860 > 0 { - var yyrr1860, yyrl1860 int - var yyrt1860 bool - if yyl1860 > cap(yyv1860) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1860 := len(yyv1860) > 0 - yyv21860 := yyv1860 - yyrl1860, yyrt1860 = z.DecInferLen(yyl1860, z.DecBasicHandle().MaxInitLen, 752) - if yyrt1860 { - if yyrl1860 <= cap(yyv1860) { - yyv1860 = yyv1860[:yyrl1860] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 928) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1860 = make([]DaemonSet, yyrl1860) + yyv1 = make([]DaemonSet, yyrl1) } } else { - yyv1860 = make([]DaemonSet, yyrl1860) + yyv1 = make([]DaemonSet, yyrl1) } - yyc1860 = true - yyrr1860 = len(yyv1860) - if yyrg1860 { - copy(yyv1860, yyv21860) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1860 != len(yyv1860) { - yyv1860 = yyv1860[:yyl1860] - yyc1860 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1860 := 0 - for ; yyj1860 < yyrr1860; yyj1860++ { - yyh1860.ElemContainerState(yyj1860) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1860[yyj1860] = DaemonSet{} + yyv1[yyj1] = DaemonSet{} } else { - yyv1861 := &yyv1860[yyj1860] - yyv1861.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1860 { - for ; yyj1860 < yyl1860; yyj1860++ { - yyv1860 = append(yyv1860, DaemonSet{}) - yyh1860.ElemContainerState(yyj1860) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, DaemonSet{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1860[yyj1860] = DaemonSet{} + yyv1[yyj1] = DaemonSet{} } else { - yyv1862 := &yyv1860[yyj1860] - yyv1862.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1860 := 0 - for ; !r.CheckBreak(); yyj1860++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1860 >= len(yyv1860) { - yyv1860 = append(yyv1860, DaemonSet{}) // var yyz1860 DaemonSet - yyc1860 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, DaemonSet{}) // var yyz1 DaemonSet + yyc1 = true } - yyh1860.ElemContainerState(yyj1860) - if yyj1860 < len(yyv1860) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1860[yyj1860] = DaemonSet{} + yyv1[yyj1] = DaemonSet{} } else { - yyv1863 := &yyv1860[yyj1860] - yyv1863.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -22330,17 +20071,17 @@ func (x codecSelfer1234) decSliceDaemonSet(v *[]DaemonSet, d *codec1978.Decoder) } } - if yyj1860 < len(yyv1860) { - yyv1860 = yyv1860[:yyj1860] - yyc1860 = true - } else if yyj1860 == 0 && yyv1860 == nil { - yyv1860 = []DaemonSet{} - yyc1860 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []DaemonSet{} + yyc1 = true } } - yyh1860.End() - if yyc1860 { - *v = yyv1860 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22349,10 +20090,10 @@ func (x codecSelfer1234) encSliceThirdPartyResourceData(v []ThirdPartyResourceDa z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1864 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1865 := &yyv1864 - yy1865.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22362,315 +20103,86 @@ func (x codecSelfer1234) decSliceThirdPartyResourceData(v *[]ThirdPartyResourceD z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1866 := *v - yyh1866, yyl1866 := z.DecSliceHelperStart() - var yyc1866 bool - if yyl1866 == 0 { - if yyv1866 == nil { - yyv1866 = []ThirdPartyResourceData{} - yyc1866 = true - } else if len(yyv1866) != 0 { - yyv1866 = yyv1866[:0] - yyc1866 = true - } - } else if yyl1866 > 0 { - var yyrr1866, yyrl1866 int - var yyrt1866 bool - if yyl1866 > cap(yyv1866) { - - yyrg1866 := len(yyv1866) > 0 - yyv21866 := yyv1866 - yyrl1866, yyrt1866 = z.DecInferLen(yyl1866, z.DecBasicHandle().MaxInitLen, 280) - if yyrt1866 { - if yyrl1866 <= cap(yyv1866) { - yyv1866 = yyv1866[:yyrl1866] - } else { - yyv1866 = make([]ThirdPartyResourceData, yyrl1866) - } - } else { - yyv1866 = make([]ThirdPartyResourceData, yyrl1866) - } - yyc1866 = true - yyrr1866 = len(yyv1866) - if yyrg1866 { - copy(yyv1866, yyv21866) - } - } else if yyl1866 != len(yyv1866) { - yyv1866 = yyv1866[:yyl1866] - yyc1866 = true - } - yyj1866 := 0 - for ; yyj1866 < yyrr1866; yyj1866++ { - yyh1866.ElemContainerState(yyj1866) - if r.TryDecodeAsNil() { - yyv1866[yyj1866] = ThirdPartyResourceData{} - } else { - yyv1867 := &yyv1866[yyj1866] - yyv1867.CodecDecodeSelf(d) - } - - } - if yyrt1866 { - for ; yyj1866 < yyl1866; yyj1866++ { - yyv1866 = append(yyv1866, ThirdPartyResourceData{}) - yyh1866.ElemContainerState(yyj1866) - if r.TryDecodeAsNil() { - yyv1866[yyj1866] = ThirdPartyResourceData{} - } else { - yyv1868 := &yyv1866[yyj1866] - yyv1868.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1866 := 0 - for ; !r.CheckBreak(); yyj1866++ { - - if yyj1866 >= len(yyv1866) { - yyv1866 = append(yyv1866, ThirdPartyResourceData{}) // var yyz1866 ThirdPartyResourceData - yyc1866 = true - } - yyh1866.ElemContainerState(yyj1866) - if yyj1866 < len(yyv1866) { - if r.TryDecodeAsNil() { - yyv1866[yyj1866] = ThirdPartyResourceData{} - } else { - yyv1869 := &yyv1866[yyj1866] - yyv1869.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1866 < len(yyv1866) { - yyv1866 = yyv1866[:yyj1866] - yyc1866 = true - } else if yyj1866 == 0 && yyv1866 == nil { - yyv1866 = []ThirdPartyResourceData{} - yyc1866 = true - } - } - yyh1866.End() - if yyc1866 { - *v = yyv1866 - } -} - -func (x codecSelfer1234) encSliceJob(v []Job, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1870 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1871 := &yyv1870 - yy1871.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceJob(v *[]Job, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1872 := *v - yyh1872, yyl1872 := z.DecSliceHelperStart() - var yyc1872 bool - if yyl1872 == 0 { - if yyv1872 == nil { - yyv1872 = []Job{} - yyc1872 = true - } else if len(yyv1872) != 0 { - yyv1872 = yyv1872[:0] - yyc1872 = true - } - } else if yyl1872 > 0 { - var yyrr1872, yyrl1872 int - var yyrt1872 bool - if yyl1872 > cap(yyv1872) { - - yyrg1872 := len(yyv1872) > 0 - yyv21872 := yyv1872 - yyrl1872, yyrt1872 = z.DecInferLen(yyl1872, z.DecBasicHandle().MaxInitLen, 824) - if yyrt1872 { - if yyrl1872 <= cap(yyv1872) { - yyv1872 = yyv1872[:yyrl1872] - } else { - yyv1872 = make([]Job, yyrl1872) - } - } else { - yyv1872 = make([]Job, yyrl1872) - } - yyc1872 = true - yyrr1872 = len(yyv1872) - if yyrg1872 { - copy(yyv1872, yyv21872) - } - } else if yyl1872 != len(yyv1872) { - yyv1872 = yyv1872[:yyl1872] - yyc1872 = true - } - yyj1872 := 0 - for ; yyj1872 < yyrr1872; yyj1872++ { - yyh1872.ElemContainerState(yyj1872) - if r.TryDecodeAsNil() { - yyv1872[yyj1872] = Job{} - } else { - yyv1873 := &yyv1872[yyj1872] - yyv1873.CodecDecodeSelf(d) - } - - } - if yyrt1872 { - for ; yyj1872 < yyl1872; yyj1872++ { - yyv1872 = append(yyv1872, Job{}) - yyh1872.ElemContainerState(yyj1872) - if r.TryDecodeAsNil() { - yyv1872[yyj1872] = Job{} - } else { - yyv1874 := &yyv1872[yyj1872] - yyv1874.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj1872 := 0 - for ; !r.CheckBreak(); yyj1872++ { - - if yyj1872 >= len(yyv1872) { - yyv1872 = append(yyv1872, Job{}) // var yyz1872 Job - yyc1872 = true - } - yyh1872.ElemContainerState(yyj1872) - if yyj1872 < len(yyv1872) { - if r.TryDecodeAsNil() { - yyv1872[yyj1872] = Job{} - } else { - yyv1875 := &yyv1872[yyj1872] - yyv1875.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj1872 < len(yyv1872) { - yyv1872 = yyv1872[:yyj1872] - yyc1872 = true - } else if yyj1872 == 0 && yyv1872 == nil { - yyv1872 = []Job{} - yyc1872 = true - } - } - yyh1872.End() - if yyc1872 { - *v = yyv1872 - } -} - -func (x codecSelfer1234) encSliceJobCondition(v []JobCondition, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv1876 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1877 := &yyv1876 - yy1877.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceJobCondition(v *[]JobCondition, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv1878 := *v - yyh1878, yyl1878 := z.DecSliceHelperStart() - var yyc1878 bool - if yyl1878 == 0 { - if yyv1878 == nil { - yyv1878 = []JobCondition{} - yyc1878 = true - } else if len(yyv1878) != 0 { - yyv1878 = yyv1878[:0] - yyc1878 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ThirdPartyResourceData{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1878 > 0 { - var yyrr1878, yyrl1878 int - var yyrt1878 bool - if yyl1878 > cap(yyv1878) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1878 := len(yyv1878) > 0 - yyv21878 := yyv1878 - yyrl1878, yyrt1878 = z.DecInferLen(yyl1878, z.DecBasicHandle().MaxInitLen, 112) - if yyrt1878 { - if yyrl1878 <= cap(yyv1878) { - yyv1878 = yyv1878[:yyrl1878] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1878 = make([]JobCondition, yyrl1878) + yyv1 = make([]ThirdPartyResourceData, yyrl1) } } else { - yyv1878 = make([]JobCondition, yyrl1878) + yyv1 = make([]ThirdPartyResourceData, yyrl1) } - yyc1878 = true - yyrr1878 = len(yyv1878) - if yyrg1878 { - copy(yyv1878, yyv21878) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1878 != len(yyv1878) { - yyv1878 = yyv1878[:yyl1878] - yyc1878 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1878 := 0 - for ; yyj1878 < yyrr1878; yyj1878++ { - yyh1878.ElemContainerState(yyj1878) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1878[yyj1878] = JobCondition{} + yyv1[yyj1] = ThirdPartyResourceData{} } else { - yyv1879 := &yyv1878[yyj1878] - yyv1879.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1878 { - for ; yyj1878 < yyl1878; yyj1878++ { - yyv1878 = append(yyv1878, JobCondition{}) - yyh1878.ElemContainerState(yyj1878) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ThirdPartyResourceData{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1878[yyj1878] = JobCondition{} + yyv1[yyj1] = ThirdPartyResourceData{} } else { - yyv1880 := &yyv1878[yyj1878] - yyv1880.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1878 := 0 - for ; !r.CheckBreak(); yyj1878++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1878 >= len(yyv1878) { - yyv1878 = append(yyv1878, JobCondition{}) // var yyz1878 JobCondition - yyc1878 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ThirdPartyResourceData{}) // var yyz1 ThirdPartyResourceData + yyc1 = true } - yyh1878.ElemContainerState(yyj1878) - if yyj1878 < len(yyv1878) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1878[yyj1878] = JobCondition{} + yyv1[yyj1] = ThirdPartyResourceData{} } else { - yyv1881 := &yyv1878[yyj1878] - yyv1881.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -22678,17 +20190,17 @@ func (x codecSelfer1234) decSliceJobCondition(v *[]JobCondition, d *codec1978.De } } - if yyj1878 < len(yyv1878) { - yyv1878 = yyv1878[:yyj1878] - yyc1878 = true - } else if yyj1878 == 0 && yyv1878 == nil { - yyv1878 = []JobCondition{} - yyc1878 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ThirdPartyResourceData{} + yyc1 = true } } - yyh1878.End() - if yyc1878 { - *v = yyv1878 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22697,10 +20209,10 @@ func (x codecSelfer1234) encSliceIngress(v []Ingress, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1882 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1883 := &yyv1882 - yy1883.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22710,83 +20222,86 @@ func (x codecSelfer1234) decSliceIngress(v *[]Ingress, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1884 := *v - yyh1884, yyl1884 := z.DecSliceHelperStart() - var yyc1884 bool - if yyl1884 == 0 { - if yyv1884 == nil { - yyv1884 = []Ingress{} - yyc1884 = true - } else if len(yyv1884) != 0 { - yyv1884 = yyv1884[:0] - yyc1884 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Ingress{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1884 > 0 { - var yyrr1884, yyrl1884 int - var yyrt1884 bool - if yyl1884 > cap(yyv1884) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1884 := len(yyv1884) > 0 - yyv21884 := yyv1884 - yyrl1884, yyrt1884 = z.DecInferLen(yyl1884, z.DecBasicHandle().MaxInitLen, 336) - if yyrt1884 { - if yyrl1884 <= cap(yyv1884) { - yyv1884 = yyv1884[:yyrl1884] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 344) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1884 = make([]Ingress, yyrl1884) + yyv1 = make([]Ingress, yyrl1) } } else { - yyv1884 = make([]Ingress, yyrl1884) + yyv1 = make([]Ingress, yyrl1) } - yyc1884 = true - yyrr1884 = len(yyv1884) - if yyrg1884 { - copy(yyv1884, yyv21884) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1884 != len(yyv1884) { - yyv1884 = yyv1884[:yyl1884] - yyc1884 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1884 := 0 - for ; yyj1884 < yyrr1884; yyj1884++ { - yyh1884.ElemContainerState(yyj1884) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1884[yyj1884] = Ingress{} + yyv1[yyj1] = Ingress{} } else { - yyv1885 := &yyv1884[yyj1884] - yyv1885.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1884 { - for ; yyj1884 < yyl1884; yyj1884++ { - yyv1884 = append(yyv1884, Ingress{}) - yyh1884.ElemContainerState(yyj1884) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Ingress{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1884[yyj1884] = Ingress{} + yyv1[yyj1] = Ingress{} } else { - yyv1886 := &yyv1884[yyj1884] - yyv1886.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1884 := 0 - for ; !r.CheckBreak(); yyj1884++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1884 >= len(yyv1884) { - yyv1884 = append(yyv1884, Ingress{}) // var yyz1884 Ingress - yyc1884 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Ingress{}) // var yyz1 Ingress + yyc1 = true } - yyh1884.ElemContainerState(yyj1884) - if yyj1884 < len(yyv1884) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1884[yyj1884] = Ingress{} + yyv1[yyj1] = Ingress{} } else { - yyv1887 := &yyv1884[yyj1884] - yyv1887.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -22794,17 +20309,17 @@ func (x codecSelfer1234) decSliceIngress(v *[]Ingress, d *codec1978.Decoder) { } } - if yyj1884 < len(yyv1884) { - yyv1884 = yyv1884[:yyj1884] - yyc1884 = true - } else if yyj1884 == 0 && yyv1884 == nil { - yyv1884 = []Ingress{} - yyc1884 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Ingress{} + yyc1 = true } } - yyh1884.End() - if yyc1884 { - *v = yyv1884 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22813,10 +20328,10 @@ func (x codecSelfer1234) encSliceIngressTLS(v []IngressTLS, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1888 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1889 := &yyv1888 - yy1889.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22826,83 +20341,86 @@ func (x codecSelfer1234) decSliceIngressTLS(v *[]IngressTLS, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1890 := *v - yyh1890, yyl1890 := z.DecSliceHelperStart() - var yyc1890 bool - if yyl1890 == 0 { - if yyv1890 == nil { - yyv1890 = []IngressTLS{} - yyc1890 = true - } else if len(yyv1890) != 0 { - yyv1890 = yyv1890[:0] - yyc1890 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []IngressTLS{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1890 > 0 { - var yyrr1890, yyrl1890 int - var yyrt1890 bool - if yyl1890 > cap(yyv1890) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1890 := len(yyv1890) > 0 - yyv21890 := yyv1890 - yyrl1890, yyrt1890 = z.DecInferLen(yyl1890, z.DecBasicHandle().MaxInitLen, 40) - if yyrt1890 { - if yyrl1890 <= cap(yyv1890) { - yyv1890 = yyv1890[:yyrl1890] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 40) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1890 = make([]IngressTLS, yyrl1890) + yyv1 = make([]IngressTLS, yyrl1) } } else { - yyv1890 = make([]IngressTLS, yyrl1890) + yyv1 = make([]IngressTLS, yyrl1) } - yyc1890 = true - yyrr1890 = len(yyv1890) - if yyrg1890 { - copy(yyv1890, yyv21890) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1890 != len(yyv1890) { - yyv1890 = yyv1890[:yyl1890] - yyc1890 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1890 := 0 - for ; yyj1890 < yyrr1890; yyj1890++ { - yyh1890.ElemContainerState(yyj1890) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1890[yyj1890] = IngressTLS{} + yyv1[yyj1] = IngressTLS{} } else { - yyv1891 := &yyv1890[yyj1890] - yyv1891.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1890 { - for ; yyj1890 < yyl1890; yyj1890++ { - yyv1890 = append(yyv1890, IngressTLS{}) - yyh1890.ElemContainerState(yyj1890) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, IngressTLS{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1890[yyj1890] = IngressTLS{} + yyv1[yyj1] = IngressTLS{} } else { - yyv1892 := &yyv1890[yyj1890] - yyv1892.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1890 := 0 - for ; !r.CheckBreak(); yyj1890++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1890 >= len(yyv1890) { - yyv1890 = append(yyv1890, IngressTLS{}) // var yyz1890 IngressTLS - yyc1890 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, IngressTLS{}) // var yyz1 IngressTLS + yyc1 = true } - yyh1890.ElemContainerState(yyj1890) - if yyj1890 < len(yyv1890) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1890[yyj1890] = IngressTLS{} + yyv1[yyj1] = IngressTLS{} } else { - yyv1893 := &yyv1890[yyj1890] - yyv1893.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -22910,17 +20428,17 @@ func (x codecSelfer1234) decSliceIngressTLS(v *[]IngressTLS, d *codec1978.Decode } } - if yyj1890 < len(yyv1890) { - yyv1890 = yyv1890[:yyj1890] - yyc1890 = true - } else if yyj1890 == 0 && yyv1890 == nil { - yyv1890 = []IngressTLS{} - yyc1890 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []IngressTLS{} + yyc1 = true } } - yyh1890.End() - if yyc1890 { - *v = yyv1890 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -22929,10 +20447,10 @@ func (x codecSelfer1234) encSliceIngressRule(v []IngressRule, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1894 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1895 := &yyv1894 - yy1895.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -22942,83 +20460,86 @@ func (x codecSelfer1234) decSliceIngressRule(v *[]IngressRule, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1896 := *v - yyh1896, yyl1896 := z.DecSliceHelperStart() - var yyc1896 bool - if yyl1896 == 0 { - if yyv1896 == nil { - yyv1896 = []IngressRule{} - yyc1896 = true - } else if len(yyv1896) != 0 { - yyv1896 = yyv1896[:0] - yyc1896 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []IngressRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1896 > 0 { - var yyrr1896, yyrl1896 int - var yyrt1896 bool - if yyl1896 > cap(yyv1896) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1896 := len(yyv1896) > 0 - yyv21896 := yyv1896 - yyrl1896, yyrt1896 = z.DecInferLen(yyl1896, z.DecBasicHandle().MaxInitLen, 24) - if yyrt1896 { - if yyrl1896 <= cap(yyv1896) { - yyv1896 = yyv1896[:yyrl1896] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 24) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1896 = make([]IngressRule, yyrl1896) + yyv1 = make([]IngressRule, yyrl1) } } else { - yyv1896 = make([]IngressRule, yyrl1896) + yyv1 = make([]IngressRule, yyrl1) } - yyc1896 = true - yyrr1896 = len(yyv1896) - if yyrg1896 { - copy(yyv1896, yyv21896) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1896 != len(yyv1896) { - yyv1896 = yyv1896[:yyl1896] - yyc1896 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1896 := 0 - for ; yyj1896 < yyrr1896; yyj1896++ { - yyh1896.ElemContainerState(yyj1896) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1896[yyj1896] = IngressRule{} + yyv1[yyj1] = IngressRule{} } else { - yyv1897 := &yyv1896[yyj1896] - yyv1897.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1896 { - for ; yyj1896 < yyl1896; yyj1896++ { - yyv1896 = append(yyv1896, IngressRule{}) - yyh1896.ElemContainerState(yyj1896) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, IngressRule{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1896[yyj1896] = IngressRule{} + yyv1[yyj1] = IngressRule{} } else { - yyv1898 := &yyv1896[yyj1896] - yyv1898.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1896 := 0 - for ; !r.CheckBreak(); yyj1896++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1896 >= len(yyv1896) { - yyv1896 = append(yyv1896, IngressRule{}) // var yyz1896 IngressRule - yyc1896 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, IngressRule{}) // var yyz1 IngressRule + yyc1 = true } - yyh1896.ElemContainerState(yyj1896) - if yyj1896 < len(yyv1896) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1896[yyj1896] = IngressRule{} + yyv1[yyj1] = IngressRule{} } else { - yyv1899 := &yyv1896[yyj1896] - yyv1899.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23026,17 +20547,17 @@ func (x codecSelfer1234) decSliceIngressRule(v *[]IngressRule, d *codec1978.Deco } } - if yyj1896 < len(yyv1896) { - yyv1896 = yyv1896[:yyj1896] - yyc1896 = true - } else if yyj1896 == 0 && yyv1896 == nil { - yyv1896 = []IngressRule{} - yyc1896 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []IngressRule{} + yyc1 = true } } - yyh1896.End() - if yyc1896 { - *v = yyv1896 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23045,10 +20566,10 @@ func (x codecSelfer1234) encSliceHTTPIngressPath(v []HTTPIngressPath, e *codec19 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1900 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1901 := &yyv1900 - yy1901.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23058,83 +20579,86 @@ func (x codecSelfer1234) decSliceHTTPIngressPath(v *[]HTTPIngressPath, d *codec1 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1902 := *v - yyh1902, yyl1902 := z.DecSliceHelperStart() - var yyc1902 bool - if yyl1902 == 0 { - if yyv1902 == nil { - yyv1902 = []HTTPIngressPath{} - yyc1902 = true - } else if len(yyv1902) != 0 { - yyv1902 = yyv1902[:0] - yyc1902 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HTTPIngressPath{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1902 > 0 { - var yyrr1902, yyrl1902 int - var yyrt1902 bool - if yyl1902 > cap(yyv1902) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1902 := len(yyv1902) > 0 - yyv21902 := yyv1902 - yyrl1902, yyrt1902 = z.DecInferLen(yyl1902, z.DecBasicHandle().MaxInitLen, 64) - if yyrt1902 { - if yyrl1902 <= cap(yyv1902) { - yyv1902 = yyv1902[:yyrl1902] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 64) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1902 = make([]HTTPIngressPath, yyrl1902) + yyv1 = make([]HTTPIngressPath, yyrl1) } } else { - yyv1902 = make([]HTTPIngressPath, yyrl1902) + yyv1 = make([]HTTPIngressPath, yyrl1) } - yyc1902 = true - yyrr1902 = len(yyv1902) - if yyrg1902 { - copy(yyv1902, yyv21902) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1902 != len(yyv1902) { - yyv1902 = yyv1902[:yyl1902] - yyc1902 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1902 := 0 - for ; yyj1902 < yyrr1902; yyj1902++ { - yyh1902.ElemContainerState(yyj1902) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1902[yyj1902] = HTTPIngressPath{} + yyv1[yyj1] = HTTPIngressPath{} } else { - yyv1903 := &yyv1902[yyj1902] - yyv1903.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1902 { - for ; yyj1902 < yyl1902; yyj1902++ { - yyv1902 = append(yyv1902, HTTPIngressPath{}) - yyh1902.ElemContainerState(yyj1902) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HTTPIngressPath{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1902[yyj1902] = HTTPIngressPath{} + yyv1[yyj1] = HTTPIngressPath{} } else { - yyv1904 := &yyv1902[yyj1902] - yyv1904.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1902 := 0 - for ; !r.CheckBreak(); yyj1902++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1902 >= len(yyv1902) { - yyv1902 = append(yyv1902, HTTPIngressPath{}) // var yyz1902 HTTPIngressPath - yyc1902 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HTTPIngressPath{}) // var yyz1 HTTPIngressPath + yyc1 = true } - yyh1902.ElemContainerState(yyj1902) - if yyj1902 < len(yyv1902) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1902[yyj1902] = HTTPIngressPath{} + yyv1[yyj1] = HTTPIngressPath{} } else { - yyv1905 := &yyv1902[yyj1902] - yyv1905.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23142,17 +20666,17 @@ func (x codecSelfer1234) decSliceHTTPIngressPath(v *[]HTTPIngressPath, d *codec1 } } - if yyj1902 < len(yyv1902) { - yyv1902 = yyv1902[:yyj1902] - yyc1902 = true - } else if yyj1902 == 0 && yyv1902 == nil { - yyv1902 = []HTTPIngressPath{} - yyc1902 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HTTPIngressPath{} + yyc1 = true } } - yyh1902.End() - if yyc1902 { - *v = yyv1902 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23161,10 +20685,10 @@ func (x codecSelfer1234) encSliceReplicaSet(v []ReplicaSet, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1906 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1907 := &yyv1906 - yy1907.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23174,83 +20698,86 @@ func (x codecSelfer1234) decSliceReplicaSet(v *[]ReplicaSet, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1908 := *v - yyh1908, yyl1908 := z.DecSliceHelperStart() - var yyc1908 bool - if yyl1908 == 0 { - if yyv1908 == nil { - yyv1908 = []ReplicaSet{} - yyc1908 = true - } else if len(yyv1908) != 0 { - yyv1908 = yyv1908[:0] - yyc1908 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ReplicaSet{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1908 > 0 { - var yyrr1908, yyrl1908 int - var yyrt1908 bool - if yyl1908 > cap(yyv1908) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1908 := len(yyv1908) > 0 - yyv21908 := yyv1908 - yyrl1908, yyrt1908 = z.DecInferLen(yyl1908, z.DecBasicHandle().MaxInitLen, 800) - if yyrt1908 { - if yyrl1908 <= cap(yyv1908) { - yyv1908 = yyv1908[:yyrl1908] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 896) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1908 = make([]ReplicaSet, yyrl1908) + yyv1 = make([]ReplicaSet, yyrl1) } } else { - yyv1908 = make([]ReplicaSet, yyrl1908) + yyv1 = make([]ReplicaSet, yyrl1) } - yyc1908 = true - yyrr1908 = len(yyv1908) - if yyrg1908 { - copy(yyv1908, yyv21908) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1908 != len(yyv1908) { - yyv1908 = yyv1908[:yyl1908] - yyc1908 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1908 := 0 - for ; yyj1908 < yyrr1908; yyj1908++ { - yyh1908.ElemContainerState(yyj1908) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1908[yyj1908] = ReplicaSet{} + yyv1[yyj1] = ReplicaSet{} } else { - yyv1909 := &yyv1908[yyj1908] - yyv1909.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1908 { - for ; yyj1908 < yyl1908; yyj1908++ { - yyv1908 = append(yyv1908, ReplicaSet{}) - yyh1908.ElemContainerState(yyj1908) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ReplicaSet{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1908[yyj1908] = ReplicaSet{} + yyv1[yyj1] = ReplicaSet{} } else { - yyv1910 := &yyv1908[yyj1908] - yyv1910.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1908 := 0 - for ; !r.CheckBreak(); yyj1908++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1908 >= len(yyv1908) { - yyv1908 = append(yyv1908, ReplicaSet{}) // var yyz1908 ReplicaSet - yyc1908 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ReplicaSet{}) // var yyz1 ReplicaSet + yyc1 = true } - yyh1908.ElemContainerState(yyj1908) - if yyj1908 < len(yyv1908) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1908[yyj1908] = ReplicaSet{} + yyv1[yyj1] = ReplicaSet{} } else { - yyv1911 := &yyv1908[yyj1908] - yyv1911.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23258,17 +20785,17 @@ func (x codecSelfer1234) decSliceReplicaSet(v *[]ReplicaSet, d *codec1978.Decode } } - if yyj1908 < len(yyv1908) { - yyv1908 = yyv1908[:yyj1908] - yyc1908 = true - } else if yyj1908 == 0 && yyv1908 == nil { - yyv1908 = []ReplicaSet{} - yyc1908 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ReplicaSet{} + yyc1 = true } } - yyh1908.End() - if yyc1908 { - *v = yyv1908 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23277,10 +20804,10 @@ func (x codecSelfer1234) encSliceReplicaSetCondition(v []ReplicaSetCondition, e z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1912 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1913 := &yyv1912 - yy1913.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23290,83 +20817,86 @@ func (x codecSelfer1234) decSliceReplicaSetCondition(v *[]ReplicaSetCondition, d z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1914 := *v - yyh1914, yyl1914 := z.DecSliceHelperStart() - var yyc1914 bool - if yyl1914 == 0 { - if yyv1914 == nil { - yyv1914 = []ReplicaSetCondition{} - yyc1914 = true - } else if len(yyv1914) != 0 { - yyv1914 = yyv1914[:0] - yyc1914 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ReplicaSetCondition{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1914 > 0 { - var yyrr1914, yyrl1914 int - var yyrt1914 bool - if yyl1914 > cap(yyv1914) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1914 := len(yyv1914) > 0 - yyv21914 := yyv1914 - yyrl1914, yyrt1914 = z.DecInferLen(yyl1914, z.DecBasicHandle().MaxInitLen, 88) - if yyrt1914 { - if yyrl1914 <= cap(yyv1914) { - yyv1914 = yyv1914[:yyrl1914] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 88) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1914 = make([]ReplicaSetCondition, yyrl1914) + yyv1 = make([]ReplicaSetCondition, yyrl1) } } else { - yyv1914 = make([]ReplicaSetCondition, yyrl1914) + yyv1 = make([]ReplicaSetCondition, yyrl1) } - yyc1914 = true - yyrr1914 = len(yyv1914) - if yyrg1914 { - copy(yyv1914, yyv21914) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1914 != len(yyv1914) { - yyv1914 = yyv1914[:yyl1914] - yyc1914 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1914 := 0 - for ; yyj1914 < yyrr1914; yyj1914++ { - yyh1914.ElemContainerState(yyj1914) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1914[yyj1914] = ReplicaSetCondition{} + yyv1[yyj1] = ReplicaSetCondition{} } else { - yyv1915 := &yyv1914[yyj1914] - yyv1915.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1914 { - for ; yyj1914 < yyl1914; yyj1914++ { - yyv1914 = append(yyv1914, ReplicaSetCondition{}) - yyh1914.ElemContainerState(yyj1914) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ReplicaSetCondition{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1914[yyj1914] = ReplicaSetCondition{} + yyv1[yyj1] = ReplicaSetCondition{} } else { - yyv1916 := &yyv1914[yyj1914] - yyv1916.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1914 := 0 - for ; !r.CheckBreak(); yyj1914++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1914 >= len(yyv1914) { - yyv1914 = append(yyv1914, ReplicaSetCondition{}) // var yyz1914 ReplicaSetCondition - yyc1914 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ReplicaSetCondition{}) // var yyz1 ReplicaSetCondition + yyc1 = true } - yyh1914.ElemContainerState(yyj1914) - if yyj1914 < len(yyv1914) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1914[yyj1914] = ReplicaSetCondition{} + yyv1[yyj1] = ReplicaSetCondition{} } else { - yyv1917 := &yyv1914[yyj1914] - yyv1917.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23374,112 +20904,113 @@ func (x codecSelfer1234) decSliceReplicaSetCondition(v *[]ReplicaSetCondition, d } } - if yyj1914 < len(yyv1914) { - yyv1914 = yyv1914[:yyj1914] - yyc1914 = true - } else if yyj1914 == 0 && yyv1914 == nil { - yyv1914 = []ReplicaSetCondition{} - yyc1914 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ReplicaSetCondition{} + yyc1 = true } } - yyh1914.End() - if yyc1914 { - *v = yyv1914 + yyh1.End() + if yyc1 { + *v = yyv1 } } -func (x codecSelfer1234) encSlicev1_Capability(v []pkg2_v1.Capability, e *codec1978.Encoder) { +func (x codecSelfer1234) encSlicev1_Capability(v []pkg4_v1.Capability, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1918 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym1919 := z.EncBinary() - _ = yym1919 - if false { - } else if z.HasExtensions() && z.EncExt(yyv1918) { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyv1918)) - } + yysf2 := &yyv1 + yysf2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) decSlicev1_Capability(v *[]pkg2_v1.Capability, d *codec1978.Decoder) { +func (x codecSelfer1234) decSlicev1_Capability(v *[]pkg4_v1.Capability, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1920 := *v - yyh1920, yyl1920 := z.DecSliceHelperStart() - var yyc1920 bool - if yyl1920 == 0 { - if yyv1920 == nil { - yyv1920 = []pkg2_v1.Capability{} - yyc1920 = true - } else if len(yyv1920) != 0 { - yyv1920 = yyv1920[:0] - yyc1920 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []pkg4_v1.Capability{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1920 > 0 { - var yyrr1920, yyrl1920 int - var yyrt1920 bool - if yyl1920 > cap(yyv1920) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl1920, yyrt1920 = z.DecInferLen(yyl1920, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1920 { - if yyrl1920 <= cap(yyv1920) { - yyv1920 = yyv1920[:yyrl1920] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1920 = make([]pkg2_v1.Capability, yyrl1920) + yyv1 = make([]pkg4_v1.Capability, yyrl1) } } else { - yyv1920 = make([]pkg2_v1.Capability, yyrl1920) + yyv1 = make([]pkg4_v1.Capability, yyrl1) } - yyc1920 = true - yyrr1920 = len(yyv1920) - } else if yyl1920 != len(yyv1920) { - yyv1920 = yyv1920[:yyl1920] - yyc1920 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1920 := 0 - for ; yyj1920 < yyrr1920; yyj1920++ { - yyh1920.ElemContainerState(yyj1920) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1920[yyj1920] = "" + yyv1[yyj1] = "" } else { - yyv1920[yyj1920] = pkg2_v1.Capability(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1920 { - for ; yyj1920 < yyl1920; yyj1920++ { - yyv1920 = append(yyv1920, "") - yyh1920.ElemContainerState(yyj1920) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1920[yyj1920] = "" + yyv1[yyj1] = "" } else { - yyv1920[yyj1920] = pkg2_v1.Capability(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1920 := 0 - for ; !r.CheckBreak(); yyj1920++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1920 >= len(yyv1920) { - yyv1920 = append(yyv1920, "") // var yyz1920 pkg2_v1.Capability - yyc1920 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 pkg4_v1.Capability + yyc1 = true } - yyh1920.ElemContainerState(yyj1920) - if yyj1920 < len(yyv1920) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1920[yyj1920] = "" + yyv1[yyj1] = "" } else { - yyv1920[yyj1920] = pkg2_v1.Capability(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23487,17 +21018,17 @@ func (x codecSelfer1234) decSlicev1_Capability(v *[]pkg2_v1.Capability, d *codec } } - if yyj1920 < len(yyv1920) { - yyv1920 = yyv1920[:yyj1920] - yyc1920 = true - } else if yyj1920 == 0 && yyv1920 == nil { - yyv1920 = []pkg2_v1.Capability{} - yyc1920 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []pkg4_v1.Capability{} + yyc1 = true } } - yyh1920.End() - if yyc1920 { - *v = yyv1920 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23506,9 +21037,9 @@ func (x codecSelfer1234) encSliceFSType(v []FSType, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1924 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yyv1924.CodecEncodeSelf(e) + yyv1.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23518,75 +21049,81 @@ func (x codecSelfer1234) decSliceFSType(v *[]FSType, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1925 := *v - yyh1925, yyl1925 := z.DecSliceHelperStart() - var yyc1925 bool - if yyl1925 == 0 { - if yyv1925 == nil { - yyv1925 = []FSType{} - yyc1925 = true - } else if len(yyv1925) != 0 { - yyv1925 = yyv1925[:0] - yyc1925 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []FSType{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1925 > 0 { - var yyrr1925, yyrl1925 int - var yyrt1925 bool - if yyl1925 > cap(yyv1925) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrl1925, yyrt1925 = z.DecInferLen(yyl1925, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1925 { - if yyrl1925 <= cap(yyv1925) { - yyv1925 = yyv1925[:yyrl1925] + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1925 = make([]FSType, yyrl1925) + yyv1 = make([]FSType, yyrl1) } } else { - yyv1925 = make([]FSType, yyrl1925) + yyv1 = make([]FSType, yyrl1) } - yyc1925 = true - yyrr1925 = len(yyv1925) - } else if yyl1925 != len(yyv1925) { - yyv1925 = yyv1925[:yyl1925] - yyc1925 = true + yyc1 = true + yyrr1 = len(yyv1) + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1925 := 0 - for ; yyj1925 < yyrr1925; yyj1925++ { - yyh1925.ElemContainerState(yyj1925) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1925[yyj1925] = "" + yyv1[yyj1] = "" } else { - yyv1925[yyj1925] = FSType(r.DecodeString()) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1925 { - for ; yyj1925 < yyl1925; yyj1925++ { - yyv1925 = append(yyv1925, "") - yyh1925.ElemContainerState(yyj1925) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, "") + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1925[yyj1925] = "" + yyv1[yyj1] = "" } else { - yyv1925[yyj1925] = FSType(r.DecodeString()) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1925 := 0 - for ; !r.CheckBreak(); yyj1925++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1925 >= len(yyv1925) { - yyv1925 = append(yyv1925, "") // var yyz1925 FSType - yyc1925 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, "") // var yyz1 FSType + yyc1 = true } - yyh1925.ElemContainerState(yyj1925) - if yyj1925 < len(yyv1925) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1925[yyj1925] = "" + yyv1[yyj1] = "" } else { - yyv1925[yyj1925] = FSType(r.DecodeString()) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23594,17 +21131,17 @@ func (x codecSelfer1234) decSliceFSType(v *[]FSType, d *codec1978.Decoder) { } } - if yyj1925 < len(yyv1925) { - yyv1925 = yyv1925[:yyj1925] - yyc1925 = true - } else if yyj1925 == 0 && yyv1925 == nil { - yyv1925 = []FSType{} - yyc1925 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []FSType{} + yyc1 = true } } - yyh1925.End() - if yyc1925 { - *v = yyv1925 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23613,10 +21150,10 @@ func (x codecSelfer1234) encSliceHostPortRange(v []HostPortRange, e *codec1978.E z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1929 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1930 := &yyv1929 - yy1930.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23626,83 +21163,86 @@ func (x codecSelfer1234) decSliceHostPortRange(v *[]HostPortRange, d *codec1978. z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1931 := *v - yyh1931, yyl1931 := z.DecSliceHelperStart() - var yyc1931 bool - if yyl1931 == 0 { - if yyv1931 == nil { - yyv1931 = []HostPortRange{} - yyc1931 = true - } else if len(yyv1931) != 0 { - yyv1931 = yyv1931[:0] - yyc1931 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []HostPortRange{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1931 > 0 { - var yyrr1931, yyrl1931 int - var yyrt1931 bool - if yyl1931 > cap(yyv1931) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1931 := len(yyv1931) > 0 - yyv21931 := yyv1931 - yyrl1931, yyrt1931 = z.DecInferLen(yyl1931, z.DecBasicHandle().MaxInitLen, 8) - if yyrt1931 { - if yyrl1931 <= cap(yyv1931) { - yyv1931 = yyv1931[:yyrl1931] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 8) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1931 = make([]HostPortRange, yyrl1931) + yyv1 = make([]HostPortRange, yyrl1) } } else { - yyv1931 = make([]HostPortRange, yyrl1931) + yyv1 = make([]HostPortRange, yyrl1) } - yyc1931 = true - yyrr1931 = len(yyv1931) - if yyrg1931 { - copy(yyv1931, yyv21931) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1931 != len(yyv1931) { - yyv1931 = yyv1931[:yyl1931] - yyc1931 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1931 := 0 - for ; yyj1931 < yyrr1931; yyj1931++ { - yyh1931.ElemContainerState(yyj1931) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1931[yyj1931] = HostPortRange{} + yyv1[yyj1] = HostPortRange{} } else { - yyv1932 := &yyv1931[yyj1931] - yyv1932.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1931 { - for ; yyj1931 < yyl1931; yyj1931++ { - yyv1931 = append(yyv1931, HostPortRange{}) - yyh1931.ElemContainerState(yyj1931) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, HostPortRange{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1931[yyj1931] = HostPortRange{} + yyv1[yyj1] = HostPortRange{} } else { - yyv1933 := &yyv1931[yyj1931] - yyv1933.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1931 := 0 - for ; !r.CheckBreak(); yyj1931++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1931 >= len(yyv1931) { - yyv1931 = append(yyv1931, HostPortRange{}) // var yyz1931 HostPortRange - yyc1931 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, HostPortRange{}) // var yyz1 HostPortRange + yyc1 = true } - yyh1931.ElemContainerState(yyj1931) - if yyj1931 < len(yyv1931) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1931[yyj1931] = HostPortRange{} + yyv1[yyj1] = HostPortRange{} } else { - yyv1934 := &yyv1931[yyj1931] - yyv1934.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23710,17 +21250,17 @@ func (x codecSelfer1234) decSliceHostPortRange(v *[]HostPortRange, d *codec1978. } } - if yyj1931 < len(yyv1931) { - yyv1931 = yyv1931[:yyj1931] - yyc1931 = true - } else if yyj1931 == 0 && yyv1931 == nil { - yyv1931 = []HostPortRange{} - yyc1931 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []HostPortRange{} + yyc1 = true } } - yyh1931.End() - if yyc1931 { - *v = yyv1931 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23729,10 +21269,10 @@ func (x codecSelfer1234) encSliceIDRange(v []IDRange, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1935 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1936 := &yyv1935 - yy1936.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23742,83 +21282,86 @@ func (x codecSelfer1234) decSliceIDRange(v *[]IDRange, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1937 := *v - yyh1937, yyl1937 := z.DecSliceHelperStart() - var yyc1937 bool - if yyl1937 == 0 { - if yyv1937 == nil { - yyv1937 = []IDRange{} - yyc1937 = true - } else if len(yyv1937) != 0 { - yyv1937 = yyv1937[:0] - yyc1937 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []IDRange{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1937 > 0 { - var yyrr1937, yyrl1937 int - var yyrt1937 bool - if yyl1937 > cap(yyv1937) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1937 := len(yyv1937) > 0 - yyv21937 := yyv1937 - yyrl1937, yyrt1937 = z.DecInferLen(yyl1937, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1937 { - if yyrl1937 <= cap(yyv1937) { - yyv1937 = yyv1937[:yyrl1937] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1937 = make([]IDRange, yyrl1937) + yyv1 = make([]IDRange, yyrl1) } } else { - yyv1937 = make([]IDRange, yyrl1937) + yyv1 = make([]IDRange, yyrl1) } - yyc1937 = true - yyrr1937 = len(yyv1937) - if yyrg1937 { - copy(yyv1937, yyv21937) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1937 != len(yyv1937) { - yyv1937 = yyv1937[:yyl1937] - yyc1937 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1937 := 0 - for ; yyj1937 < yyrr1937; yyj1937++ { - yyh1937.ElemContainerState(yyj1937) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1937[yyj1937] = IDRange{} + yyv1[yyj1] = IDRange{} } else { - yyv1938 := &yyv1937[yyj1937] - yyv1938.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1937 { - for ; yyj1937 < yyl1937; yyj1937++ { - yyv1937 = append(yyv1937, IDRange{}) - yyh1937.ElemContainerState(yyj1937) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, IDRange{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1937[yyj1937] = IDRange{} + yyv1[yyj1] = IDRange{} } else { - yyv1939 := &yyv1937[yyj1937] - yyv1939.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1937 := 0 - for ; !r.CheckBreak(); yyj1937++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1937 >= len(yyv1937) { - yyv1937 = append(yyv1937, IDRange{}) // var yyz1937 IDRange - yyc1937 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, IDRange{}) // var yyz1 IDRange + yyc1 = true } - yyh1937.ElemContainerState(yyj1937) - if yyj1937 < len(yyv1937) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1937[yyj1937] = IDRange{} + yyv1[yyj1] = IDRange{} } else { - yyv1940 := &yyv1937[yyj1937] - yyv1940.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23826,17 +21369,17 @@ func (x codecSelfer1234) decSliceIDRange(v *[]IDRange, d *codec1978.Decoder) { } } - if yyj1937 < len(yyv1937) { - yyv1937 = yyv1937[:yyj1937] - yyc1937 = true - } else if yyj1937 == 0 && yyv1937 == nil { - yyv1937 = []IDRange{} - yyc1937 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []IDRange{} + yyc1 = true } } - yyh1937.End() - if yyc1937 { - *v = yyv1937 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23845,10 +21388,10 @@ func (x codecSelfer1234) encSlicePodSecurityPolicy(v []PodSecurityPolicy, e *cod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1941 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1942 := &yyv1941 - yy1942.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23858,83 +21401,86 @@ func (x codecSelfer1234) decSlicePodSecurityPolicy(v *[]PodSecurityPolicy, d *co z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1943 := *v - yyh1943, yyl1943 := z.DecSliceHelperStart() - var yyc1943 bool - if yyl1943 == 0 { - if yyv1943 == nil { - yyv1943 = []PodSecurityPolicy{} - yyc1943 = true - } else if len(yyv1943) != 0 { - yyv1943 = yyv1943[:0] - yyc1943 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PodSecurityPolicy{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1943 > 0 { - var yyrr1943, yyrl1943 int - var yyrt1943 bool - if yyl1943 > cap(yyv1943) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1943 := len(yyv1943) > 0 - yyv21943 := yyv1943 - yyrl1943, yyrt1943 = z.DecInferLen(yyl1943, z.DecBasicHandle().MaxInitLen, 552) - if yyrt1943 { - if yyrl1943 <= cap(yyv1943) { - yyv1943 = yyv1943[:yyrl1943] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 560) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1943 = make([]PodSecurityPolicy, yyrl1943) + yyv1 = make([]PodSecurityPolicy, yyrl1) } } else { - yyv1943 = make([]PodSecurityPolicy, yyrl1943) + yyv1 = make([]PodSecurityPolicy, yyrl1) } - yyc1943 = true - yyrr1943 = len(yyv1943) - if yyrg1943 { - copy(yyv1943, yyv21943) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1943 != len(yyv1943) { - yyv1943 = yyv1943[:yyl1943] - yyc1943 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1943 := 0 - for ; yyj1943 < yyrr1943; yyj1943++ { - yyh1943.ElemContainerState(yyj1943) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1943[yyj1943] = PodSecurityPolicy{} + yyv1[yyj1] = PodSecurityPolicy{} } else { - yyv1944 := &yyv1943[yyj1943] - yyv1944.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1943 { - for ; yyj1943 < yyl1943; yyj1943++ { - yyv1943 = append(yyv1943, PodSecurityPolicy{}) - yyh1943.ElemContainerState(yyj1943) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PodSecurityPolicy{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1943[yyj1943] = PodSecurityPolicy{} + yyv1[yyj1] = PodSecurityPolicy{} } else { - yyv1945 := &yyv1943[yyj1943] - yyv1945.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1943 := 0 - for ; !r.CheckBreak(); yyj1943++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1943 >= len(yyv1943) { - yyv1943 = append(yyv1943, PodSecurityPolicy{}) // var yyz1943 PodSecurityPolicy - yyc1943 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PodSecurityPolicy{}) // var yyz1 PodSecurityPolicy + yyc1 = true } - yyh1943.ElemContainerState(yyj1943) - if yyj1943 < len(yyv1943) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1943[yyj1943] = PodSecurityPolicy{} + yyv1[yyj1] = PodSecurityPolicy{} } else { - yyv1946 := &yyv1943[yyj1943] - yyv1946.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -23942,17 +21488,17 @@ func (x codecSelfer1234) decSlicePodSecurityPolicy(v *[]PodSecurityPolicy, d *co } } - if yyj1943 < len(yyv1943) { - yyv1943 = yyv1943[:yyj1943] - yyc1943 = true - } else if yyj1943 == 0 && yyv1943 == nil { - yyv1943 = []PodSecurityPolicy{} - yyc1943 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PodSecurityPolicy{} + yyc1 = true } } - yyh1943.End() - if yyc1943 { - *v = yyv1943 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -23961,10 +21507,10 @@ func (x codecSelfer1234) encSliceNetworkPolicyIngressRule(v []NetworkPolicyIngre z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1947 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1948 := &yyv1947 - yy1948.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -23974,83 +21520,86 @@ func (x codecSelfer1234) decSliceNetworkPolicyIngressRule(v *[]NetworkPolicyIngr z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1949 := *v - yyh1949, yyl1949 := z.DecSliceHelperStart() - var yyc1949 bool - if yyl1949 == 0 { - if yyv1949 == nil { - yyv1949 = []NetworkPolicyIngressRule{} - yyc1949 = true - } else if len(yyv1949) != 0 { - yyv1949 = yyv1949[:0] - yyc1949 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1949 > 0 { - var yyrr1949, yyrl1949 int - var yyrt1949 bool - if yyl1949 > cap(yyv1949) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1949 := len(yyv1949) > 0 - yyv21949 := yyv1949 - yyrl1949, yyrt1949 = z.DecInferLen(yyl1949, z.DecBasicHandle().MaxInitLen, 48) - if yyrt1949 { - if yyrl1949 <= cap(yyv1949) { - yyv1949 = yyv1949[:yyrl1949] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1949 = make([]NetworkPolicyIngressRule, yyrl1949) + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) } } else { - yyv1949 = make([]NetworkPolicyIngressRule, yyrl1949) + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) } - yyc1949 = true - yyrr1949 = len(yyv1949) - if yyrg1949 { - copy(yyv1949, yyv21949) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1949 != len(yyv1949) { - yyv1949 = yyv1949[:yyl1949] - yyc1949 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1949 := 0 - for ; yyj1949 < yyrr1949; yyj1949++ { - yyh1949.ElemContainerState(yyj1949) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1949[yyj1949] = NetworkPolicyIngressRule{} + yyv1[yyj1] = NetworkPolicyIngressRule{} } else { - yyv1950 := &yyv1949[yyj1949] - yyv1950.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1949 { - for ; yyj1949 < yyl1949; yyj1949++ { - yyv1949 = append(yyv1949, NetworkPolicyIngressRule{}) - yyh1949.ElemContainerState(yyj1949) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1949[yyj1949] = NetworkPolicyIngressRule{} + yyv1[yyj1] = NetworkPolicyIngressRule{} } else { - yyv1951 := &yyv1949[yyj1949] - yyv1951.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1949 := 0 - for ; !r.CheckBreak(); yyj1949++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1949 >= len(yyv1949) { - yyv1949 = append(yyv1949, NetworkPolicyIngressRule{}) // var yyz1949 NetworkPolicyIngressRule - yyc1949 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) // var yyz1 NetworkPolicyIngressRule + yyc1 = true } - yyh1949.ElemContainerState(yyj1949) - if yyj1949 < len(yyv1949) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1949[yyj1949] = NetworkPolicyIngressRule{} + yyv1[yyj1] = NetworkPolicyIngressRule{} } else { - yyv1952 := &yyv1949[yyj1949] - yyv1952.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -24058,17 +21607,17 @@ func (x codecSelfer1234) decSliceNetworkPolicyIngressRule(v *[]NetworkPolicyIngr } } - if yyj1949 < len(yyv1949) { - yyv1949 = yyv1949[:yyj1949] - yyc1949 = true - } else if yyj1949 == 0 && yyv1949 == nil { - yyv1949 = []NetworkPolicyIngressRule{} - yyc1949 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true } } - yyh1949.End() - if yyc1949 { - *v = yyv1949 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -24077,10 +21626,10 @@ func (x codecSelfer1234) encSliceNetworkPolicyPort(v []NetworkPolicyPort, e *cod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1953 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1954 := &yyv1953 - yy1954.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -24090,83 +21639,86 @@ func (x codecSelfer1234) decSliceNetworkPolicyPort(v *[]NetworkPolicyPort, d *co z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1955 := *v - yyh1955, yyl1955 := z.DecSliceHelperStart() - var yyc1955 bool - if yyl1955 == 0 { - if yyv1955 == nil { - yyv1955 = []NetworkPolicyPort{} - yyc1955 = true - } else if len(yyv1955) != 0 { - yyv1955 = yyv1955[:0] - yyc1955 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1955 > 0 { - var yyrr1955, yyrl1955 int - var yyrt1955 bool - if yyl1955 > cap(yyv1955) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1955 := len(yyv1955) > 0 - yyv21955 := yyv1955 - yyrl1955, yyrt1955 = z.DecInferLen(yyl1955, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1955 { - if yyrl1955 <= cap(yyv1955) { - yyv1955 = yyv1955[:yyrl1955] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1955 = make([]NetworkPolicyPort, yyrl1955) + yyv1 = make([]NetworkPolicyPort, yyrl1) } } else { - yyv1955 = make([]NetworkPolicyPort, yyrl1955) + yyv1 = make([]NetworkPolicyPort, yyrl1) } - yyc1955 = true - yyrr1955 = len(yyv1955) - if yyrg1955 { - copy(yyv1955, yyv21955) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1955 != len(yyv1955) { - yyv1955 = yyv1955[:yyl1955] - yyc1955 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1955 := 0 - for ; yyj1955 < yyrr1955; yyj1955++ { - yyh1955.ElemContainerState(yyj1955) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1955[yyj1955] = NetworkPolicyPort{} + yyv1[yyj1] = NetworkPolicyPort{} } else { - yyv1956 := &yyv1955[yyj1955] - yyv1956.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1955 { - for ; yyj1955 < yyl1955; yyj1955++ { - yyv1955 = append(yyv1955, NetworkPolicyPort{}) - yyh1955.ElemContainerState(yyj1955) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPort{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1955[yyj1955] = NetworkPolicyPort{} + yyv1[yyj1] = NetworkPolicyPort{} } else { - yyv1957 := &yyv1955[yyj1955] - yyv1957.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1955 := 0 - for ; !r.CheckBreak(); yyj1955++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1955 >= len(yyv1955) { - yyv1955 = append(yyv1955, NetworkPolicyPort{}) // var yyz1955 NetworkPolicyPort - yyc1955 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPort{}) // var yyz1 NetworkPolicyPort + yyc1 = true } - yyh1955.ElemContainerState(yyj1955) - if yyj1955 < len(yyv1955) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1955[yyj1955] = NetworkPolicyPort{} + yyv1[yyj1] = NetworkPolicyPort{} } else { - yyv1958 := &yyv1955[yyj1955] - yyv1958.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -24174,17 +21726,17 @@ func (x codecSelfer1234) decSliceNetworkPolicyPort(v *[]NetworkPolicyPort, d *co } } - if yyj1955 < len(yyv1955) { - yyv1955 = yyv1955[:yyj1955] - yyc1955 = true - } else if yyj1955 == 0 && yyv1955 == nil { - yyv1955 = []NetworkPolicyPort{} - yyc1955 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true } } - yyh1955.End() - if yyc1955 { - *v = yyv1955 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -24193,10 +21745,10 @@ func (x codecSelfer1234) encSliceNetworkPolicyPeer(v []NetworkPolicyPeer, e *cod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1959 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1960 := &yyv1959 - yy1960.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -24206,83 +21758,86 @@ func (x codecSelfer1234) decSliceNetworkPolicyPeer(v *[]NetworkPolicyPeer, d *co z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1961 := *v - yyh1961, yyl1961 := z.DecSliceHelperStart() - var yyc1961 bool - if yyl1961 == 0 { - if yyv1961 == nil { - yyv1961 = []NetworkPolicyPeer{} - yyc1961 = true - } else if len(yyv1961) != 0 { - yyv1961 = yyv1961[:0] - yyc1961 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1961 > 0 { - var yyrr1961, yyrl1961 int - var yyrt1961 bool - if yyl1961 > cap(yyv1961) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1961 := len(yyv1961) > 0 - yyv21961 := yyv1961 - yyrl1961, yyrt1961 = z.DecInferLen(yyl1961, z.DecBasicHandle().MaxInitLen, 16) - if yyrt1961 { - if yyrl1961 <= cap(yyv1961) { - yyv1961 = yyv1961[:yyrl1961] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1961 = make([]NetworkPolicyPeer, yyrl1961) + yyv1 = make([]NetworkPolicyPeer, yyrl1) } } else { - yyv1961 = make([]NetworkPolicyPeer, yyrl1961) + yyv1 = make([]NetworkPolicyPeer, yyrl1) } - yyc1961 = true - yyrr1961 = len(yyv1961) - if yyrg1961 { - copy(yyv1961, yyv21961) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1961 != len(yyv1961) { - yyv1961 = yyv1961[:yyl1961] - yyc1961 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1961 := 0 - for ; yyj1961 < yyrr1961; yyj1961++ { - yyh1961.ElemContainerState(yyj1961) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1961[yyj1961] = NetworkPolicyPeer{} + yyv1[yyj1] = NetworkPolicyPeer{} } else { - yyv1962 := &yyv1961[yyj1961] - yyv1962.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1961 { - for ; yyj1961 < yyl1961; yyj1961++ { - yyv1961 = append(yyv1961, NetworkPolicyPeer{}) - yyh1961.ElemContainerState(yyj1961) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPeer{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1961[yyj1961] = NetworkPolicyPeer{} + yyv1[yyj1] = NetworkPolicyPeer{} } else { - yyv1963 := &yyv1961[yyj1961] - yyv1963.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1961 := 0 - for ; !r.CheckBreak(); yyj1961++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1961 >= len(yyv1961) { - yyv1961 = append(yyv1961, NetworkPolicyPeer{}) // var yyz1961 NetworkPolicyPeer - yyc1961 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPeer{}) // var yyz1 NetworkPolicyPeer + yyc1 = true } - yyh1961.ElemContainerState(yyj1961) - if yyj1961 < len(yyv1961) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1961[yyj1961] = NetworkPolicyPeer{} + yyv1[yyj1] = NetworkPolicyPeer{} } else { - yyv1964 := &yyv1961[yyj1961] - yyv1964.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -24290,17 +21845,17 @@ func (x codecSelfer1234) decSliceNetworkPolicyPeer(v *[]NetworkPolicyPeer, d *co } } - if yyj1961 < len(yyv1961) { - yyv1961 = yyv1961[:yyj1961] - yyc1961 = true - } else if yyj1961 == 0 && yyv1961 == nil { - yyv1961 = []NetworkPolicyPeer{} - yyc1961 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true } } - yyh1961.End() - if yyc1961 { - *v = yyv1961 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -24309,10 +21864,10 @@ func (x codecSelfer1234) encSliceNetworkPolicy(v []NetworkPolicy, e *codec1978.E z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv1965 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy1966 := &yyv1965 - yy1966.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -24322,83 +21877,86 @@ func (x codecSelfer1234) decSliceNetworkPolicy(v *[]NetworkPolicy, d *codec1978. z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv1967 := *v - yyh1967, yyl1967 := z.DecSliceHelperStart() - var yyc1967 bool - if yyl1967 == 0 { - if yyv1967 == nil { - yyv1967 = []NetworkPolicy{} - yyc1967 = true - } else if len(yyv1967) != 0 { - yyv1967 = yyv1967[:0] - yyc1967 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl1967 > 0 { - var yyrr1967, yyrl1967 int - var yyrt1967 bool - if yyl1967 > cap(yyv1967) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg1967 := len(yyv1967) > 0 - yyv21967 := yyv1967 - yyrl1967, yyrt1967 = z.DecInferLen(yyl1967, z.DecBasicHandle().MaxInitLen, 312) - if yyrt1967 { - if yyrl1967 <= cap(yyv1967) { - yyv1967 = yyv1967[:yyrl1967] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 320) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv1967 = make([]NetworkPolicy, yyrl1967) + yyv1 = make([]NetworkPolicy, yyrl1) } } else { - yyv1967 = make([]NetworkPolicy, yyrl1967) + yyv1 = make([]NetworkPolicy, yyrl1) } - yyc1967 = true - yyrr1967 = len(yyv1967) - if yyrg1967 { - copy(yyv1967, yyv21967) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl1967 != len(yyv1967) { - yyv1967 = yyv1967[:yyl1967] - yyc1967 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj1967 := 0 - for ; yyj1967 < yyrr1967; yyj1967++ { - yyh1967.ElemContainerState(yyj1967) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1967[yyj1967] = NetworkPolicy{} + yyv1[yyj1] = NetworkPolicy{} } else { - yyv1968 := &yyv1967[yyj1967] - yyv1968.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt1967 { - for ; yyj1967 < yyl1967; yyj1967++ { - yyv1967 = append(yyv1967, NetworkPolicy{}) - yyh1967.ElemContainerState(yyj1967) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicy{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv1967[yyj1967] = NetworkPolicy{} + yyv1[yyj1] = NetworkPolicy{} } else { - yyv1969 := &yyv1967[yyj1967] - yyv1969.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj1967 := 0 - for ; !r.CheckBreak(); yyj1967++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj1967 >= len(yyv1967) { - yyv1967 = append(yyv1967, NetworkPolicy{}) // var yyz1967 NetworkPolicy - yyc1967 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicy{}) // var yyz1 NetworkPolicy + yyc1 = true } - yyh1967.ElemContainerState(yyj1967) - if yyj1967 < len(yyv1967) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv1967[yyj1967] = NetworkPolicy{} + yyv1[yyj1] = NetworkPolicy{} } else { - yyv1970 := &yyv1967[yyj1967] - yyv1970.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -24406,16 +21964,16 @@ func (x codecSelfer1234) decSliceNetworkPolicy(v *[]NetworkPolicy, d *codec1978. } } - if yyj1967 < len(yyv1967) { - yyv1967 = yyv1967[:yyj1967] - yyc1967 = true - } else if yyj1967 == 0 && yyv1967 == nil { - yyv1967 = []NetworkPolicy{} - yyc1967 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true } } - yyh1967.End() - if yyc1967 { - *v = yyv1967 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go index 0f7b44ef7a..8f5ad4807c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types.go @@ -17,10 +17,11 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/resource" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/api/resource" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/util/intstr" + appsv1beta1 "k8s.io/client-go/pkg/apis/apps/v1beta1" ) // describes the attributes of a scale subresource @@ -44,7 +45,7 @@ type ScaleStatus struct { // avoid introspection in the clients. The string will be in the same format as the // query-param syntax. If the target type only supports map-based selectors, both this // field and map-based selector field are populated. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional TargetSelector string `json:"targetSelector,omitempty" protobuf:"bytes,3,opt,name=targetSelector"` } @@ -54,45 +55,23 @@ type ScaleStatus struct { // represents a scaling request for a resource. type Scale struct { - unversioned.TypeMeta `json:",inline"` - // Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata. + metav1.TypeMeta `json:",inline"` + // Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. + // defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. // +optional Spec ScaleSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - // current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only. + // current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only. // +optional Status ScaleStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // Dummy definition type ReplicationControllerDummy struct { - unversioned.TypeMeta `json:",inline"` -} - -// SubresourceReference contains enough information to let you inspect or modify the referred subresource. -type SubresourceReference struct { - // Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds - // +optional - Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"` - // Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names - // +optional - Name string `json:"name,omitempty" protobuf:"bytes,2,opt,name=name"` - // API version of the referent - // +optional - APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,3,opt,name=apiVersion"` - // Subresource name of the referent - // +optional - Subresource string `json:"subresource,omitempty" protobuf:"bytes,4,opt,name=subresource"` -} - -type CPUTargetUtilization struct { - // fraction of the requested CPU that should be utilized/used, - // e.g. 70 means that 70% of the requested CPU should be in use. - TargetPercentage int32 `json:"targetPercentage" protobuf:"varint,1,opt,name=targetPercentage"` + metav1.TypeMeta `json:",inline"` } // Alpha-level support for Custom Metrics in HPA (as annotations). @@ -118,83 +97,17 @@ type CustomMetricCurrentStatusList struct { Items []CustomMetricCurrentStatus `json:"items" protobuf:"bytes,1,rep,name=items"` } -// specification of a horizontal pod autoscaler. -type HorizontalPodAutoscalerSpec struct { - // reference to Scale subresource; horizontal pod autoscaler will learn the current resource consumption from its status, - // and will set the desired number of pods by modifying its spec. - ScaleRef SubresourceReference `json:"scaleRef" protobuf:"bytes,1,opt,name=scaleRef"` - // lower limit for the number of pods that can be set by the autoscaler, default 1. - // +optional - MinReplicas *int32 `json:"minReplicas,omitempty" protobuf:"varint,2,opt,name=minReplicas"` - // upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas. - MaxReplicas int32 `json:"maxReplicas" protobuf:"varint,3,opt,name=maxReplicas"` - // target average CPU utilization (represented as a percentage of requested CPU) over all the pods; - // if not specified it defaults to the target CPU utilization at 80% of the requested resources. - // +optional - CPUUtilization *CPUTargetUtilization `json:"cpuUtilization,omitempty" protobuf:"bytes,4,opt,name=cpuUtilization"` -} - -// current status of a horizontal pod autoscaler -type HorizontalPodAutoscalerStatus struct { - // most recent generation observed by this autoscaler. - // +optional - ObservedGeneration *int64 `json:"observedGeneration,omitempty" protobuf:"varint,1,opt,name=observedGeneration"` - - // last time the HorizontalPodAutoscaler scaled the number of pods; - // used by the autoscaler to control how often the number of pods is changed. - // +optional - LastScaleTime *unversioned.Time `json:"lastScaleTime,omitempty" protobuf:"bytes,2,opt,name=lastScaleTime"` - - // current number of replicas of pods managed by this autoscaler. - CurrentReplicas int32 `json:"currentReplicas" protobuf:"varint,3,opt,name=currentReplicas"` - - // desired number of replicas of pods managed by this autoscaler. - DesiredReplicas int32 `json:"desiredReplicas" protobuf:"varint,4,opt,name=desiredReplicas"` - - // current average CPU utilization over all pods, represented as a percentage of requested CPU, - // e.g. 70 means that an average pod is using now 70% of its requested CPU. - // +optional - CurrentCPUUtilizationPercentage *int32 `json:"currentCPUUtilizationPercentage,omitempty" protobuf:"varint,5,opt,name=currentCPUUtilizationPercentage"` -} - -// configuration of a horizontal pod autoscaler. -type HorizontalPodAutoscaler struct { - unversioned.TypeMeta `json:",inline"` - // Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. - // +optional - Spec HorizontalPodAutoscalerSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - - // current information about the autoscaler. - // +optional - Status HorizontalPodAutoscalerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` -} - -// list of horizontal pod autoscaler objects. -type HorizontalPodAutoscalerList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata. - // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // list of horizontal pod autoscaler objects. - Items []HorizontalPodAutoscaler `json:"items" protobuf:"bytes,2,rep,name=items"` -} - // +genclient=true // +nonNamespaced=true // A ThirdPartyResource is a generic representation of a resource, it is used by add-ons and plugins to add new resource // types to the API. It consists of one or more Versions of the api. type ThirdPartyResource struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Description is the description of this object. // +optional @@ -207,11 +120,11 @@ type ThirdPartyResource struct { // ThirdPartyResourceList is a list of ThirdPartyResources. type ThirdPartyResourceList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of ThirdPartyResources. Items []ThirdPartyResource `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -226,10 +139,10 @@ type APIVersion struct { // An internal object, used for versioned storage in etcd. Not exposed to the end user. type ThirdPartyResourceData struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Data is the raw JSON data for this data. // +optional @@ -240,10 +153,10 @@ type ThirdPartyResourceData struct { // Deployment enables declarative updates for Pods and ReplicaSets. type Deployment struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Specification of the desired behavior of the Deployment. // +optional @@ -264,7 +177,7 @@ type DeploymentSpec struct { // Label selector for pods. Existing ReplicaSets whose pods are // selected by this will be the ones affected by this deployment. // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` // Template describes the pods that will be created. Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,3,opt,name=template"` @@ -305,7 +218,7 @@ type DeploymentSpec struct { // DeploymentRollback stores the information required to rollback a deployment. type DeploymentRollback struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Required: This must match the Name of a deployment. Name string `json:"name" protobuf:"bytes,1,opt,name=name"` // The annotations to be updated to a deployment @@ -316,7 +229,7 @@ type DeploymentRollback struct { } type RollbackConfig struct { - // The revision to rollback to. If set to 0, rollbck to the last revision. + // The revision to rollback to. If set to 0, rollback to the last revision. // +optional Revision int64 `json:"revision,omitempty" protobuf:"varint,1,opt,name=revision"` } @@ -357,7 +270,7 @@ const ( type RollingUpdateDeployment struct { // The maximum number of pods that can be unavailable during the update. // Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). - // Absolute number is calculated from percentage by rounding up. + // Absolute number is calculated from percentage by rounding down. // This can not be 0 if MaxSurge is 0. // By default, a fixed value of 1 is used. // Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods @@ -397,6 +310,10 @@ type DeploymentStatus struct { // +optional UpdatedReplicas int32 `json:"updatedReplicas,omitempty" protobuf:"varint,3,opt,name=updatedReplicas"` + // Total number of ready pods targeted by this deployment. + // +optional + ReadyReplicas int32 `json:"readyReplicas,omitempty" protobuf:"varint,7,opt,name=readyReplicas"` + // Total number of available pods (ready for at least minReadySeconds) targeted by this deployment. // +optional AvailableReplicas int32 `json:"availableReplicas,omitempty" protobuf:"varint,4,opt,name=availableReplicas"` @@ -406,7 +323,15 @@ type DeploymentStatus struct { UnavailableReplicas int32 `json:"unavailableReplicas,omitempty" protobuf:"varint,5,opt,name=unavailableReplicas"` // Represents the latest available observations of a deployment's current state. + // +patchMergeKey=type + // +patchStrategy=merge Conditions []DeploymentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,6,rep,name=conditions"` + + // Count of hash collisions for the Deployment. The Deployment controller uses this + // field as a collision avoidance mechanism when it needs to create the name for the + // newest ReplicaSet. + // +optional + CollisionCount *int64 `json:"collisionCount,omitempty" protobuf:"varint,8,opt,name=collisionCount"` } type DeploymentConditionType string @@ -433,9 +358,9 @@ type DeploymentCondition struct { // Status of the condition, one of True, False, Unknown. Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"` // The last time this condition was updated. - LastUpdateTime unversioned.Time `json:"lastUpdateTime,omitempty" protobuf:"bytes,6,opt,name=lastUpdateTime"` + LastUpdateTime metav1.Time `json:"lastUpdateTime,omitempty" protobuf:"bytes,6,opt,name=lastUpdateTime"` // Last time the condition transitioned from one status to another. - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,7,opt,name=lastTransitionTime"` + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,7,opt,name=lastTransitionTime"` // The reason for the condition's last transition. Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` // A human readable message indicating details about the transition. @@ -444,29 +369,28 @@ type DeploymentCondition struct { // DeploymentList is a list of Deployments. type DeploymentList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of Deployments. Items []Deployment `json:"items" protobuf:"bytes,2,rep,name=items"` } -// TODO(madhusudancs): Uncomment while implementing DaemonSet updates. -/* Commenting out for v1.2. We are planning to bring these types back with a more robust DaemonSet update implementation in v1.3, hence not deleting but just commenting the types out. type DaemonSetUpdateStrategy struct { - // Type of daemon set update. Only "RollingUpdate" is supported at this time. Default is RollingUpdate. -// +optional - Type DaemonSetUpdateStrategyType `json:"type,omitempty"` + // Type of daemon set update. Can be "RollingUpdate" or "OnDelete". + // Default is OnDelete. + // +optional + Type DaemonSetUpdateStrategyType `json:"type,omitempty" protobuf:"bytes,1,opt,name=type"` - // Rolling update config params. Present only if DaemonSetUpdateStrategy = - // RollingUpdate. + // Rolling update config params. Present only if type = "RollingUpdate". //--- // TODO: Update this to follow our convention for oneOf, whatever we decide it - // to be. Same as DeploymentStrategy.RollingUpdate. -// +optional - RollingUpdate *RollingUpdateDaemonSet `json:"rollingUpdate,omitempty"` + // to be. Same as Deployment `strategy.rollingUpdate`. + // See https://github.com/kubernetes/kubernetes/issues/35345 + // +optional + RollingUpdate *RollingUpdateDaemonSet `json:"rollingUpdate,omitempty" protobuf:"bytes,2,opt,name=rollingUpdate"` } type DaemonSetUpdateStrategyType string @@ -474,6 +398,9 @@ type DaemonSetUpdateStrategyType string const ( // Replace the old daemons by new ones using rolling update i.e replace them on each node one after the other. RollingUpdateDaemonSetStrategyType DaemonSetUpdateStrategyType = "RollingUpdate" + + // Replace the old daemons only when it's killed + OnDeleteDaemonSetStrategyType DaemonSetUpdateStrategyType = "OnDelete" ) // Spec to control the desired behavior of daemon set rolling update. @@ -484,131 +411,162 @@ type RollingUpdateDaemonSet struct { // number is calculated from percentage by rounding up. // This cannot be 0. // Default value is 1. - // Example: when this is set to 30%, 30% of the currently running DaemonSet - // pods can be stopped for an update at any given time. The update starts - // by stopping at most 30% of the currently running DaemonSet pods and then - // brings up new DaemonSet pods in their place. Once the new pods are ready, - // it then proceeds onto other DaemonSet pods, thus ensuring that at least - // 70% of original number of DaemonSet pods are available at all times - // during the update. -// +optional - MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty"` - - // Minimum number of seconds for which a newly created DaemonSet pod should - // be ready without any of its container crashing, for it to be considered - // available. Defaults to 0 (pod will be considered available as soon as it - // is ready). -// +optional - MinReadySeconds int32 `json:"minReadySeconds,omitempty"` + // Example: when this is set to 30%, at most 30% of the total number of nodes + // that should be running the daemon pod (i.e. status.desiredNumberScheduled) + // can have their pods stopped for an update at any given + // time. The update starts by stopping at most 30% of those DaemonSet pods + // and then brings up new DaemonSet pods in their place. Once the new pods + // are available, it then proceeds onto other DaemonSet pods, thus ensuring + // that at least 70% of original number of DaemonSet pods are available at + // all times during the update. + // +optional + MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty" protobuf:"bytes,1,opt,name=maxUnavailable"` } -*/ // DaemonSetSpec is the specification of a daemon set. type DaemonSetSpec struct { - // Selector is a label query over pods that are managed by the daemon set. + // A label query over pods that are managed by the daemon set. // Must match in order to be controlled. // If empty, defaulted to labels on Pod template. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,1,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,1,opt,name=selector"` - // Template is the object that describes the pod that will be created. + // An object that describes the pod that will be created. // The DaemonSet will create exactly one copy of this pod on every node // that matches the template's node selector (or on every node if no node // selector is specified). - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,2,opt,name=template"` - // TODO(madhusudancs): Uncomment while implementing DaemonSet updates. - /* Commenting out for v1.2. We are planning to bring these fields back with a more robust DaemonSet update implementation in v1.3, hence not deleting but just commenting these fields out. - // Update strategy to replace existing DaemonSet pods with new pods. + // An update strategy to replace existing DaemonSet pods with new pods. + // +optional + UpdateStrategy DaemonSetUpdateStrategy `json:"updateStrategy,omitempty" protobuf:"bytes,3,opt,name=updateStrategy"` + + // The minimum number of seconds for which a newly created DaemonSet pod should + // be ready without any of its container crashing, for it to be considered + // available. Defaults to 0 (pod will be considered available as soon as it + // is ready). // +optional - UpdateStrategy DaemonSetUpdateStrategy `json:"updateStrategy,omitempty"` + MinReadySeconds int32 `json:"minReadySeconds,omitempty" protobuf:"varint,4,opt,name=minReadySeconds"` - // Label key that is added to DaemonSet pods to distinguish between old and - // new pod templates during DaemonSet update. - // Users can set this to an empty string to indicate that the system should - // not add any label. If unspecified, system uses - // DefaultDaemonSetUniqueLabelKey("daemonset.kubernetes.io/podTemplateHash"). - // Value of this key is hash of DaemonSetSpec.PodTemplateSpec. - // No label is added if this is set to empty string. + // DEPRECATED. + // A sequence number representing a specific generation of the template. + // Populated by the system. It can be set only during the creation. // +optional - UniqueLabelKey *string `json:"uniqueLabelKey,omitempty"` - */ -} + TemplateGeneration int64 `json:"templateGeneration,omitempty" protobuf:"varint,5,opt,name=templateGeneration"` -const ( - // DefaultDaemonSetUniqueLabelKey is the default key of the labels that is added - // to daemon set pods to distinguish between old and new pod templates during - // DaemonSet update. See DaemonSetSpec's UniqueLabelKey field for more information. - DefaultDaemonSetUniqueLabelKey string = "daemonset.kubernetes.io/podTemplateHash" -) + // The number of old history to retain to allow rollback. + // This is a pointer to distinguish between explicit zero and not specified. + // Defaults to 10. + // +optional + RevisionHistoryLimit *int32 `json:"revisionHistoryLimit,omitempty" protobuf:"varint,6,opt,name=revisionHistoryLimit"` +} // DaemonSetStatus represents the current status of a daemon set. type DaemonSetStatus struct { - // CurrentNumberScheduled is the number of nodes that are running at least 1 + // The number of nodes that are running at least 1 // daemon pod and are supposed to run the daemon pod. - // More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ CurrentNumberScheduled int32 `json:"currentNumberScheduled" protobuf:"varint,1,opt,name=currentNumberScheduled"` - // NumberMisscheduled is the number of nodes that are running the daemon pod, but are + // The number of nodes that are running the daemon pod, but are // not supposed to run the daemon pod. - // More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ NumberMisscheduled int32 `json:"numberMisscheduled" protobuf:"varint,2,opt,name=numberMisscheduled"` - // DesiredNumberScheduled is the total number of nodes that should be running the daemon + // The total number of nodes that should be running the daemon // pod (including nodes correctly running the daemon pod). - // More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/ DesiredNumberScheduled int32 `json:"desiredNumberScheduled" protobuf:"varint,3,opt,name=desiredNumberScheduled"` - // NumberReady is the number of nodes that should be running the daemon pod and have one + // The number of nodes that should be running the daemon pod and have one // or more of the daemon pod running and ready. NumberReady int32 `json:"numberReady" protobuf:"varint,4,opt,name=numberReady"` + + // The most recent generation observed by the daemon set controller. + // +optional + ObservedGeneration int64 `json:"observedGeneration,omitempty" protobuf:"varint,5,opt,name=observedGeneration"` + + // The total number of nodes that are running updated daemon pod + // +optional + UpdatedNumberScheduled int32 `json:"updatedNumberScheduled,omitempty" protobuf:"varint,6,opt,name=updatedNumberScheduled"` + + // The number of nodes that should be running the + // daemon pod and have one or more of the daemon pod running and + // available (ready for at least spec.minReadySeconds) + // +optional + NumberAvailable int32 `json:"numberAvailable,omitempty" protobuf:"varint,7,opt,name=numberAvailable"` + + // The number of nodes that should be running the + // daemon pod and have none of the daemon pod running and available + // (ready for at least spec.minReadySeconds) + // +optional + NumberUnavailable int32 `json:"numberUnavailable,omitempty" protobuf:"varint,8,opt,name=numberUnavailable"` + + // Count of hash collisions for the DaemonSet. The DaemonSet controller + // uses this field as a collision avoidance mechanism when it needs to + // create the name for the newest ControllerRevision. + // +optional + CollisionCount *int64 `json:"collisionCount,omitempty" protobuf:"varint,9,opt,name=collisionCount"` } // +genclient=true // DaemonSet represents the configuration of a daemon set. type DaemonSet struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Spec defines the desired behavior of this daemon set. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // The desired behavior of this daemon set. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec DaemonSetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - // Status is the current status of this daemon set. This data may be + // The current status of this daemon set. This data may be // out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status DaemonSetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } +const ( + // DEPRECATED: DefaultDaemonSetUniqueLabelKey is used instead. + // DaemonSetTemplateGenerationKey is the key of the labels that is added + // to daemon set pods to distinguish between old and new pod templates + // during DaemonSet template update. + DaemonSetTemplateGenerationKey string = "pod-template-generation" + + // DefaultDaemonSetUniqueLabelKey is the default label key that is added + // to existing DaemonSet pods to distinguish between old and new + // DaemonSet pods during DaemonSet template updates. + DefaultDaemonSetUniqueLabelKey = appsv1beta1.ControllerRevisionHashLabelKey +) + // DaemonSetList is a collection of daemon sets. type DaemonSetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - // Items is a list of daemon sets. + // A list of daemon sets. Items []DaemonSet `json:"items" protobuf:"bytes,2,rep,name=items"` } // ThirdPartyResrouceDataList is a list of ThirdPartyResourceData. type ThirdPartyResourceDataList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of ThirdpartyResourceData. Items []ThirdPartyResourceData `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -616,178 +574,35 @@ type ThirdPartyResourceDataList struct { // +genclient=true -// Job represents the configuration of a single job. -// DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead. -type Job struct { - unversioned.TypeMeta `json:",inline"` - // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Spec is a structure defining the expected behavior of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - Spec JobSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - - // Status is a structure describing current status of a job. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status - // +optional - Status JobStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` -} - -// JobList is a collection of jobs. -// DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead. -type JobList struct { - unversioned.TypeMeta `json:",inline"` - // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata - // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Items is the list of Job. - Items []Job `json:"items" protobuf:"bytes,2,rep,name=items"` -} - -// JobSpec describes how the job execution will look like. -type JobSpec struct { - - // Parallelism specifies the maximum desired number of pods the job should - // run at any given time. The actual number of pods running in steady state will - // be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), - // i.e. when the work left to do is less than max parallelism. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - Parallelism *int32 `json:"parallelism,omitempty" protobuf:"varint,1,opt,name=parallelism"` - - // Completions specifies the desired number of successfully finished pods the - // job should be run with. Setting to nil means that the success of any - // pod signals the success of all pods, and allows parallelism to have any positive - // value. Setting to 1 means that parallelism is limited to 1 and the success of that - // pod signals the success of the job. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - Completions *int32 `json:"completions,omitempty" protobuf:"varint,2,opt,name=completions"` - - // Optional duration in seconds relative to the startTime that the job may be active - // before the system tries to terminate it; value must be positive integer - // +optional - ActiveDeadlineSeconds *int64 `json:"activeDeadlineSeconds,omitempty" protobuf:"varint,3,opt,name=activeDeadlineSeconds"` - - // Selector is a label query over pods that should match the pod count. - // Normally, the system sets this field for you. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors - // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,4,opt,name=selector"` - - // AutoSelector controls generation of pod labels and pod selectors. - // It was not present in the original extensions/v1beta1 Job definition, but exists - // to allow conversion from batch/v1 Jobs, where it corresponds to, but has the opposite - // meaning as, ManualSelector. - // More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md - // +optional - AutoSelector *bool `json:"autoSelector,omitempty" protobuf:"varint,5,opt,name=autoSelector"` - - // Template is the object that describes the pod that will be created when - // executing a job. - // More info: http://kubernetes.io/docs/user-guide/jobs - Template v1.PodTemplateSpec `json:"template" protobuf:"bytes,6,opt,name=template"` -} - -// JobStatus represents the current state of a Job. -type JobStatus struct { - - // Conditions represent the latest available observations of an object's current state. - // More info: http://kubernetes.io/docs/user-guide/jobs - // +optional - Conditions []JobCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,1,rep,name=conditions"` - - // StartTime represents time when the job was acknowledged by the Job Manager. - // It is not guaranteed to be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - StartTime *unversioned.Time `json:"startTime,omitempty" protobuf:"bytes,2,opt,name=startTime"` - - // CompletionTime represents time when the job was completed. It is not guaranteed to - // be set in happens-before order across separate operations. - // It is represented in RFC3339 form and is in UTC. - // +optional - CompletionTime *unversioned.Time `json:"completionTime,omitempty" protobuf:"bytes,3,opt,name=completionTime"` - - // Active is the number of actively running pods. - // +optional - Active int32 `json:"active,omitempty" protobuf:"varint,4,opt,name=active"` - - // Succeeded is the number of pods which reached Phase Succeeded. - // +optional - Succeeded int32 `json:"succeeded,omitempty" protobuf:"varint,5,opt,name=succeeded"` - - // Failed is the number of pods which reached Phase Failed. - // +optional - Failed int32 `json:"failed,omitempty" protobuf:"varint,6,opt,name=failed"` -} - -type JobConditionType string - -// These are valid conditions of a job. -const ( - // JobComplete means the job has completed its execution. - JobComplete JobConditionType = "Complete" - // JobFailed means the job has failed its execution. - JobFailed JobConditionType = "Failed" -) - -// JobCondition describes current state of a job. -type JobCondition struct { - // Type of job condition, Complete or Failed. - Type JobConditionType `json:"type" protobuf:"bytes,1,opt,name=type,casttype=JobConditionType"` - // Status of the condition, one of True, False, Unknown. - Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"` - // Last time the condition was checked. - // +optional - LastProbeTime unversioned.Time `json:"lastProbeTime,omitempty" protobuf:"bytes,3,opt,name=lastProbeTime"` - // Last time the condition transit from one status to another. - // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,4,opt,name=lastTransitionTime"` - // (brief) reason for the condition's last transition. - // +optional - Reason string `json:"reason,omitempty" protobuf:"bytes,5,opt,name=reason"` - // Human readable message indicating details about last transition. - // +optional - Message string `json:"message,omitempty" protobuf:"bytes,6,opt,name=message"` -} - -// +genclient=true - // Ingress is a collection of rules that allow inbound connections to reach the // endpoints defined by a backend. An Ingress can be configured to give services // externally-reachable urls, load balance traffic, terminate SSL, offer name // based virtual hosting etc. type Ingress struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec is the desired state of the Ingress. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec IngressSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` // Status is the current state of the Ingress. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status IngressStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // IngressList is a collection of Ingress. type IngressList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of Ingress. Items []Ingress `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -923,29 +738,20 @@ type IngressBackend struct { ServicePort intstr.IntOrString `json:"servicePort" protobuf:"bytes,2,opt,name=servicePort"` } -// ExportOptions is the query options to the standard REST get call. -type ExportOptions struct { - unversioned.TypeMeta `json:",inline"` - // Should this value be exported. Export strips fields that a user can not specify. - Export bool `json:"export" protobuf:"varint,1,opt,name=export"` - // Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace' - Exact bool `json:"exact" protobuf:"varint,2,opt,name=exact"` -} - // +genclient=true // ReplicaSet represents the configuration of a ReplicaSet. type ReplicaSet struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // If the Labels of a ReplicaSet are empty, they are defaulted to // be the same as the Pod(s) that the ReplicaSet manages. - // Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Spec defines the specification of the desired behavior of the ReplicaSet. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Spec ReplicaSetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` @@ -953,21 +759,21 @@ type ReplicaSet struct { // This data may be out of date by some window of time. // Populated by the system. // Read-only. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status // +optional Status ReplicaSetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` } // ReplicaSetList is a collection of ReplicaSets. type ReplicaSetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // List of ReplicaSets. - // More info: http://kubernetes.io/docs/user-guide/replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller Items []ReplicaSet `json:"items" protobuf:"bytes,2,rep,name=items"` } @@ -976,7 +782,7 @@ type ReplicaSetSpec struct { // Replicas is the number of desired replicas. // This is a pointer to distinguish between explicit zero and unspecified. // Defaults to 1. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller // +optional Replicas *int32 `json:"replicas,omitempty" protobuf:"varint,1,opt,name=replicas"` @@ -989,13 +795,13 @@ type ReplicaSetSpec struct { // Selector is a label query over pods that should match the replica count. // If the selector is empty, it is defaulted to the labels present on the pod template. // Label keys and values that must match in order to be controlled by this replica set. - // More info: http://kubernetes.io/docs/user-guide/labels#label-selectors + // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` // Template is the object that describes the pod that will be created if // insufficient replicas are detected. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template // +optional Template v1.PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,3,opt,name=template"` } @@ -1003,7 +809,7 @@ type ReplicaSetSpec struct { // ReplicaSetStatus represents the current status of a ReplicaSet. type ReplicaSetStatus struct { // Replicas is the most recently oberved number of replicas. - // More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller + // More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller Replicas int32 `json:"replicas" protobuf:"varint,1,opt,name=replicas"` // The number of pods that have labels matching the labels of the pod template of the replicaset. @@ -1024,6 +830,8 @@ type ReplicaSetStatus struct { // Represents the latest available observations of a replica set's current state. // +optional + // +patchMergeKey=type + // +patchStrategy=merge Conditions []ReplicaSetCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,6,rep,name=conditions"` } @@ -1045,7 +853,7 @@ type ReplicaSetCondition struct { Status v1.ConditionStatus `json:"status" protobuf:"bytes,2,opt,name=status,casttype=k8s.io/kubernetes/pkg/api/v1.ConditionStatus"` // The last time the condition transitioned from one status to another. // +optional - LastTransitionTime unversioned.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,3,opt,name=lastTransitionTime"` + LastTransitionTime metav1.Time `json:"lastTransitionTime,omitempty" protobuf:"bytes,3,opt,name=lastTransitionTime"` // The reason for the condition's last transition. // +optional Reason string `json:"reason,omitempty" protobuf:"bytes,4,opt,name=reason"` @@ -1060,11 +868,11 @@ type ReplicaSetCondition struct { // Pod Security Policy governs the ability to make requests that affect the Security Context // that will be applied to a pod and container. type PodSecurityPolicy struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // spec defines the policy enforced. // +optional @@ -1165,7 +973,7 @@ type SELinuxStrategyOptions struct { // type is the strategy that will dictate the allowable labels that may be set. Rule SELinuxStrategy `json:"rule" protobuf:"bytes,1,opt,name=rule,casttype=SELinuxStrategy"` // seLinuxOptions required to run as; required for MustRunAs - // More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context + // More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md // +optional SELinuxOptions *v1.SELinuxOptions `json:"seLinuxOptions,omitempty" protobuf:"bytes,2,opt,name=seLinuxOptions"` } @@ -1257,22 +1065,23 @@ const ( // Pod Security Policy List is a list of PodSecurityPolicy objects. type PodSecurityPolicyList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of schema objects. Items []PodSecurityPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` } +// NetworkPolicy describes what network traffic is allowed for a set of Pods type NetworkPolicy struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Specification of the desired behavior for this NetworkPolicy. // +optional @@ -1285,16 +1094,15 @@ type NetworkPolicySpec struct { // same set of pods. In this case, the ingress rules for each are combined additively. // This field is NOT optional and follows standard label selector semantics. // An empty podSelector matches all pods in this namespace. - PodSelector unversioned.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` + PodSelector metav1.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` // List of ingress rules to be applied to the selected pods. - // Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, + // Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod // OR if the traffic source is the pod's local node, // OR if the traffic matches at least one ingress rule across all of the NetworkPolicy // objects whose podSelector matches the pod. - // If this field is empty then this NetworkPolicy does not affect ingress isolation. - // If this field is present and contains at least one rule, this policy allows any traffic - // which matches at least one of the ingress rules in this list. + // If this field is empty then this NetworkPolicy does not allow any traffic + // (and serves solely to ensure that the pods it selects are isolated by default). // +optional Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty" protobuf:"bytes,2,rep,name=ingress"` } @@ -1303,21 +1111,17 @@ type NetworkPolicySpec struct { type NetworkPolicyIngressRule struct { // List of ports which should be made accessible on the pods selected for this rule. // Each item in this list is combined using a logical OR. - // If this field is not provided, this rule matches all ports (traffic not restricted by port). - // If this field is empty, this rule matches no ports (no traffic matches). + // If this field is empty or missing, this rule matches all ports (traffic not restricted by port). // If this field is present and contains at least one item, then this rule allows traffic // only if the traffic matches at least one port in the list. - // TODO: Update this to be a pointer to slice as soon as auto-generation supports it. // +optional Ports []NetworkPolicyPort `json:"ports,omitempty" protobuf:"bytes,1,rep,name=ports"` // List of sources which should be able to access the pods selected for this rule. // Items in this list are combined using a logical OR operation. - // If this field is not provided, this rule matches all sources (traffic not restricted by source). - // If this field is empty, this rule matches no sources (no traffic matches). + // If this field is empty or missing, this rule matches all sources (traffic not restricted by source). // If this field is present and contains at least on item, this rule allows traffic only if the // traffic matches at least one item in the from list. - // TODO: Update this to be a pointer to slice as soon as auto-generation supports it. // +optional From []NetworkPolicyPeer `json:"from,omitempty" protobuf:"bytes,2,rep,name=from"` } @@ -1342,27 +1146,25 @@ type NetworkPolicyPeer struct { // This is a label selector which selects Pods in this namespace. // This field follows standard label selector semantics. - // If not provided, this selector selects no pods. // If present but empty, this selector selects all pods in this namespace. // +optional - PodSelector *unversioned.LabelSelector `json:"podSelector,omitempty" protobuf:"bytes,1,opt,name=podSelector"` + PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" protobuf:"bytes,1,opt,name=podSelector"` // Selects Namespaces using cluster scoped-labels. This // matches all pods in all namespaces selected by this label selector. // This field follows standard label selector semantics. - // If omitted, this selector selects no namespaces. // If present but empty, this selector selects all namespaces. // +optional - NamespaceSelector *unversioned.LabelSelector `json:"namespaceSelector,omitempty" protobuf:"bytes,2,opt,name=namespaceSelector"` + NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty" protobuf:"bytes,2,opt,name=namespaceSelector"` } // Network Policy List is a list of NetworkPolicy objects. type NetworkPolicyList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of schema objects. Items []NetworkPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go index 1fd1fd5beb..d9cc1d13e7 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/types_swagger_doc_generated.go @@ -36,14 +36,6 @@ func (APIVersion) SwaggerDoc() map[string]string { return map_APIVersion } -var map_CPUTargetUtilization = map[string]string{ - "targetPercentage": "fraction of the requested CPU that should be utilized/used, e.g. 70 means that 70% of the requested CPU should be in use.", -} - -func (CPUTargetUtilization) SwaggerDoc() map[string]string { - return map_CPUTargetUtilization -} - var map_CustomMetricCurrentStatus = map[string]string{ "name": "Custom Metric name.", "value": "Custom Metric value (average).", @@ -65,9 +57,9 @@ func (CustomMetricTarget) SwaggerDoc() map[string]string { var map_DaemonSet = map[string]string{ "": "DaemonSet represents the configuration of a daemon set.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the desired behavior of this daemon set. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is the current status of this daemon set. This data may be out of date by some window of time. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "The desired behavior of this daemon set. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "The current status of this daemon set. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (DaemonSet) SwaggerDoc() map[string]string { @@ -76,8 +68,8 @@ func (DaemonSet) SwaggerDoc() map[string]string { var map_DaemonSetList = map[string]string{ "": "DaemonSetList is a collection of daemon sets.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "items": "Items is a list of daemon sets.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "A list of daemon sets.", } func (DaemonSetList) SwaggerDoc() map[string]string { @@ -85,9 +77,13 @@ func (DaemonSetList) SwaggerDoc() map[string]string { } var map_DaemonSetSpec = map[string]string{ - "": "DaemonSetSpec is the specification of a daemon set.", - "selector": "Selector is a label query over pods that are managed by the daemon set. Must match in order to be controlled. If empty, defaulted to labels on Pod template. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "template": "Template is the object that describes the pod that will be created. The DaemonSet will create exactly one copy of this pod on every node that matches the template's node selector (or on every node if no node selector is specified). More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template", + "": "DaemonSetSpec is the specification of a daemon set.", + "selector": "A label query over pods that are managed by the daemon set. Must match in order to be controlled. If empty, defaulted to labels on Pod template. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", + "template": "An object that describes the pod that will be created. The DaemonSet will create exactly one copy of this pod on every node that matches the template's node selector (or on every node if no node selector is specified). More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template", + "updateStrategy": "An update strategy to replace existing DaemonSet pods with new pods.", + "minReadySeconds": "The minimum number of seconds for which a newly created DaemonSet pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready).", + "templateGeneration": "DEPRECATED. A sequence number representing a specific generation of the template. Populated by the system. It can be set only during the creation.", + "revisionHistoryLimit": "The number of old history to retain to allow rollback. This is a pointer to distinguish between explicit zero and not specified. Defaults to 10.", } func (DaemonSetSpec) SwaggerDoc() map[string]string { @@ -96,16 +92,30 @@ func (DaemonSetSpec) SwaggerDoc() map[string]string { var map_DaemonSetStatus = map[string]string{ "": "DaemonSetStatus represents the current status of a daemon set.", - "currentNumberScheduled": "CurrentNumberScheduled is the number of nodes that are running at least 1 daemon pod and are supposed to run the daemon pod. More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md", - "numberMisscheduled": "NumberMisscheduled is the number of nodes that are running the daemon pod, but are not supposed to run the daemon pod. More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md", - "desiredNumberScheduled": "DesiredNumberScheduled is the total number of nodes that should be running the daemon pod (including nodes correctly running the daemon pod). More info: http://releases.k8s.io/HEAD/docs/admin/daemons.md", - "numberReady": "NumberReady is the number of nodes that should be running the daemon pod and have one or more of the daemon pod running and ready.", + "currentNumberScheduled": "The number of nodes that are running at least 1 daemon pod and are supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/", + "numberMisscheduled": "The number of nodes that are running the daemon pod, but are not supposed to run the daemon pod. More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/", + "desiredNumberScheduled": "The total number of nodes that should be running the daemon pod (including nodes correctly running the daemon pod). More info: https://kubernetes.io/docs/concepts/workloads/controllers/daemonset/", + "numberReady": "The number of nodes that should be running the daemon pod and have one or more of the daemon pod running and ready.", + "observedGeneration": "The most recent generation observed by the daemon set controller.", + "updatedNumberScheduled": "The total number of nodes that are running updated daemon pod", + "numberAvailable": "The number of nodes that should be running the daemon pod and have one or more of the daemon pod running and available (ready for at least spec.minReadySeconds)", + "numberUnavailable": "The number of nodes that should be running the daemon pod and have none of the daemon pod running and available (ready for at least spec.minReadySeconds)", + "collisionCount": "Count of hash collisions for the DaemonSet. The DaemonSet controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ControllerRevision.", } func (DaemonSetStatus) SwaggerDoc() map[string]string { return map_DaemonSetStatus } +var map_DaemonSetUpdateStrategy = map[string]string{ + "type": "Type of daemon set update. Can be \"RollingUpdate\" or \"OnDelete\". Default is OnDelete.", + "rollingUpdate": "Rolling update config params. Present only if type = \"RollingUpdate\".", +} + +func (DaemonSetUpdateStrategy) SwaggerDoc() map[string]string { + return map_DaemonSetUpdateStrategy +} + var map_Deployment = map[string]string{ "": "Deployment enables declarative updates for Pods and ReplicaSets.", "metadata": "Standard object metadata.", @@ -174,9 +184,11 @@ var map_DeploymentStatus = map[string]string{ "observedGeneration": "The generation observed by the deployment controller.", "replicas": "Total number of non-terminated pods targeted by this deployment (their labels match the selector).", "updatedReplicas": "Total number of non-terminated pods targeted by this deployment that have the desired template spec.", + "readyReplicas": "Total number of ready pods targeted by this deployment.", "availableReplicas": "Total number of available pods (ready for at least minReadySeconds) targeted by this deployment.", "unavailableReplicas": "Total number of unavailable pods targeted by this deployment.", "conditions": "Represents the latest available observations of a deployment's current state.", + "collisionCount": "Count of hash collisions for the Deployment. The Deployment controller uses this field as a collision avoidance mechanism when it needs to create the name for the newest ReplicaSet.", } func (DeploymentStatus) SwaggerDoc() map[string]string { @@ -193,16 +205,6 @@ func (DeploymentStrategy) SwaggerDoc() map[string]string { return map_DeploymentStrategy } -var map_ExportOptions = map[string]string{ - "": "ExportOptions is the query options to the standard REST get call.", - "export": "Should this value be exported. Export strips fields that a user can not specify.", - "exact": "Should the export be exact. Exact export maintains cluster-specific fields like 'Namespace'", -} - -func (ExportOptions) SwaggerDoc() map[string]string { - return map_ExportOptions -} - var map_FSGroupStrategyOptions = map[string]string{ "": "FSGroupStrategyOptions defines the strategy type and options used to create the strategy.", "rule": "Rule is the strategy that will dictate what FSGroup is used in the SecurityContext.", @@ -232,52 +234,6 @@ func (HTTPIngressRuleValue) SwaggerDoc() map[string]string { return map_HTTPIngressRuleValue } -var map_HorizontalPodAutoscaler = map[string]string{ - "": "configuration of a horizontal pod autoscaler.", - "metadata": "Standard object metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "behaviour of autoscaler. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.", - "status": "current information about the autoscaler.", -} - -func (HorizontalPodAutoscaler) SwaggerDoc() map[string]string { - return map_HorizontalPodAutoscaler -} - -var map_HorizontalPodAutoscalerList = map[string]string{ - "": "list of horizontal pod autoscaler objects.", - "metadata": "Standard list metadata.", - "items": "list of horizontal pod autoscaler objects.", -} - -func (HorizontalPodAutoscalerList) SwaggerDoc() map[string]string { - return map_HorizontalPodAutoscalerList -} - -var map_HorizontalPodAutoscalerSpec = map[string]string{ - "": "specification of a horizontal pod autoscaler.", - "scaleRef": "reference to Scale subresource; horizontal pod autoscaler will learn the current resource consumption from its status, and will set the desired number of pods by modifying its spec.", - "minReplicas": "lower limit for the number of pods that can be set by the autoscaler, default 1.", - "maxReplicas": "upper limit for the number of pods that can be set by the autoscaler; cannot be smaller than MinReplicas.", - "cpuUtilization": "target average CPU utilization (represented as a percentage of requested CPU) over all the pods; if not specified it defaults to the target CPU utilization at 80% of the requested resources.", -} - -func (HorizontalPodAutoscalerSpec) SwaggerDoc() map[string]string { - return map_HorizontalPodAutoscalerSpec -} - -var map_HorizontalPodAutoscalerStatus = map[string]string{ - "": "current status of a horizontal pod autoscaler", - "observedGeneration": "most recent generation observed by this autoscaler.", - "lastScaleTime": "last time the HorizontalPodAutoscaler scaled the number of pods; used by the autoscaler to control how often the number of pods is changed.", - "currentReplicas": "current number of replicas of pods managed by this autoscaler.", - "desiredReplicas": "desired number of replicas of pods managed by this autoscaler.", - "currentCPUUtilizationPercentage": "current average CPU utilization over all pods, represented as a percentage of requested CPU, e.g. 70 means that an average pod is using now 70% of its requested CPU.", -} - -func (HorizontalPodAutoscalerStatus) SwaggerDoc() map[string]string { - return map_HorizontalPodAutoscalerStatus -} - var map_HostPortRange = map[string]string{ "": "Host Port Range defines a range of host ports that will be enabled by a policy for pods to use. It requires both the start and end to be defined.", "min": "min is the start of the range, inclusive.", @@ -300,9 +256,9 @@ func (IDRange) SwaggerDoc() map[string]string { var map_Ingress = map[string]string{ "": "Ingress is a collection of rules that allow inbound connections to reach the endpoints defined by a backend. An Ingress can be configured to give services externally-reachable urls, load balance traffic, terminate SSL, offer name based virtual hosting etc.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec is the desired state of the Ingress. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is the current state of the Ingress. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec is the desired state of the Ingress. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Status is the current state of the Ingress. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (Ingress) SwaggerDoc() map[string]string { @@ -321,7 +277,7 @@ func (IngressBackend) SwaggerDoc() map[string]string { var map_IngressList = map[string]string{ "": "IngressList is a collection of Ingress.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "items": "Items is the list of Ingress.", } @@ -376,71 +332,9 @@ func (IngressTLS) SwaggerDoc() map[string]string { return map_IngressTLS } -var map_Job = map[string]string{ - "": "Job represents the configuration of a single job. DEPRECATED: extensions/v1beta1.Job is deprecated, use batch/v1.Job instead.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec is a structure defining the expected behavior of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is a structure describing current status of a job. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", -} - -func (Job) SwaggerDoc() map[string]string { - return map_Job -} - -var map_JobCondition = map[string]string{ - "": "JobCondition describes current state of a job.", - "type": "Type of job condition, Complete or Failed.", - "status": "Status of the condition, one of True, False, Unknown.", - "lastProbeTime": "Last time the condition was checked.", - "lastTransitionTime": "Last time the condition transit from one status to another.", - "reason": "(brief) reason for the condition's last transition.", - "message": "Human readable message indicating details about last transition.", -} - -func (JobCondition) SwaggerDoc() map[string]string { - return map_JobCondition -} - -var map_JobList = map[string]string{ - "": "JobList is a collection of jobs. DEPRECATED: extensions/v1beta1.JobList is deprecated, use batch/v1.JobList instead.", - "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "items": "Items is the list of Job.", -} - -func (JobList) SwaggerDoc() map[string]string { - return map_JobList -} - -var map_JobSpec = map[string]string{ - "": "JobSpec describes how the job execution will look like.", - "parallelism": "Parallelism specifies the maximum desired number of pods the job should run at any given time. The actual number of pods running in steady state will be less than this number when ((.spec.completions - .status.successful) < .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: http://kubernetes.io/docs/user-guide/jobs", - "completions": "Completions specifies the desired number of successfully finished pods the job should be run with. Setting to nil means that the success of any pod signals the success of all pods, and allows parallelism to have any positive value. Setting to 1 means that parallelism is limited to 1 and the success of that pod signals the success of the job. More info: http://kubernetes.io/docs/user-guide/jobs", - "activeDeadlineSeconds": "Optional duration in seconds relative to the startTime that the job may be active before the system tries to terminate it; value must be positive integer", - "selector": "Selector is a label query over pods that should match the pod count. Normally, the system sets this field for you. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "autoSelector": "AutoSelector controls generation of pod labels and pod selectors. It was not present in the original extensions/v1beta1 Job definition, but exists to allow conversion from batch/v1 Jobs, where it corresponds to, but has the opposite meaning as, ManualSelector. More info: http://releases.k8s.io/HEAD/docs/design/selector-generation.md", - "template": "Template is the object that describes the pod that will be created when executing a job. More info: http://kubernetes.io/docs/user-guide/jobs", -} - -func (JobSpec) SwaggerDoc() map[string]string { - return map_JobSpec -} - -var map_JobStatus = map[string]string{ - "": "JobStatus represents the current state of a Job.", - "conditions": "Conditions represent the latest available observations of an object's current state. More info: http://kubernetes.io/docs/user-guide/jobs", - "startTime": "StartTime represents time when the job was acknowledged by the Job Manager. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", - "completionTime": "CompletionTime represents time when the job was completed. It is not guaranteed to be set in happens-before order across separate operations. It is represented in RFC3339 form and is in UTC.", - "active": "Active is the number of actively running pods.", - "succeeded": "Succeeded is the number of pods which reached Phase Succeeded.", - "failed": "Failed is the number of pods which reached Phase Failed.", -} - -func (JobStatus) SwaggerDoc() map[string]string { - return map_JobStatus -} - var map_NetworkPolicy = map[string]string{ - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "": "NetworkPolicy describes what network traffic is allowed for a set of Pods", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "spec": "Specification of the desired behavior for this NetworkPolicy.", } @@ -450,8 +344,8 @@ func (NetworkPolicy) SwaggerDoc() map[string]string { var map_NetworkPolicyIngressRule = map[string]string{ "": "This NetworkPolicyIngressRule matches traffic if and only if the traffic matches both ports AND from.", - "ports": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is not provided, this rule matches all ports (traffic not restricted by port). If this field is empty, this rule matches no ports (no traffic matches). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.", - "from": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is not provided, this rule matches all sources (traffic not restricted by source). If this field is empty, this rule matches no sources (no traffic matches). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.", + "ports": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.", + "from": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.", } func (NetworkPolicyIngressRule) SwaggerDoc() map[string]string { @@ -460,7 +354,7 @@ func (NetworkPolicyIngressRule) SwaggerDoc() map[string]string { var map_NetworkPolicyList = map[string]string{ "": "Network Policy List is a list of NetworkPolicy objects.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "items": "Items is a list of schema objects.", } @@ -469,8 +363,8 @@ func (NetworkPolicyList) SwaggerDoc() map[string]string { } var map_NetworkPolicyPeer = map[string]string{ - "podSelector": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If not provided, this selector selects no pods. If present but empty, this selector selects all pods in this namespace.", - "namespaceSelector": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If omitted, this selector selects no namespaces. If present but empty, this selector selects all namespaces.", + "podSelector": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace.", + "namespaceSelector": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces.", } func (NetworkPolicyPeer) SwaggerDoc() map[string]string { @@ -488,7 +382,7 @@ func (NetworkPolicyPort) SwaggerDoc() map[string]string { var map_NetworkPolicySpec = map[string]string{ "podSelector": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", - "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if namespace.networkPolicy.ingress.isolation is undefined and cluster policy allows it, OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not affect ingress isolation. If this field is present and contains at least one rule, this policy allows any traffic which matches at least one of the ingress rules in this list.", + "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default).", } func (NetworkPolicySpec) SwaggerDoc() map[string]string { @@ -497,7 +391,7 @@ func (NetworkPolicySpec) SwaggerDoc() map[string]string { var map_PodSecurityPolicy = map[string]string{ "": "Pod Security Policy governs the ability to make requests that affect the Security Context that will be applied to a pod and container.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "spec": "spec defines the policy enforced.", } @@ -507,7 +401,7 @@ func (PodSecurityPolicy) SwaggerDoc() map[string]string { var map_PodSecurityPolicyList = map[string]string{ "": "Pod Security Policy List is a list of PodSecurityPolicy objects.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "items": "Items is a list of schema objects.", } @@ -539,9 +433,9 @@ func (PodSecurityPolicySpec) SwaggerDoc() map[string]string { var map_ReplicaSet = map[string]string{ "": "ReplicaSet represents the configuration of a ReplicaSet.", - "metadata": "If the Labels of a ReplicaSet are empty, they are defaulted to be the same as the Pod(s) that the ReplicaSet manages. Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", - "spec": "Spec defines the specification of the desired behavior of the ReplicaSet. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", - "status": "Status is the most recently observed status of the ReplicaSet. This data may be out of date by some window of time. Populated by the system. Read-only. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status", + "metadata": "If the Labels of a ReplicaSet are empty, they are defaulted to be the same as the Pod(s) that the ReplicaSet manages. Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Spec defines the specification of the desired behavior of the ReplicaSet. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", + "status": "Status is the most recently observed status of the ReplicaSet. This data may be out of date by some window of time. Populated by the system. Read-only. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status", } func (ReplicaSet) SwaggerDoc() map[string]string { @@ -563,8 +457,8 @@ func (ReplicaSetCondition) SwaggerDoc() map[string]string { var map_ReplicaSetList = map[string]string{ "": "ReplicaSetList is a collection of ReplicaSets.", - "metadata": "Standard list metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "items": "List of ReplicaSets. More info: http://kubernetes.io/docs/user-guide/replication-controller", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds", + "items": "List of ReplicaSets. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller", } func (ReplicaSetList) SwaggerDoc() map[string]string { @@ -573,10 +467,10 @@ func (ReplicaSetList) SwaggerDoc() map[string]string { var map_ReplicaSetSpec = map[string]string{ "": "ReplicaSetSpec is the specification of a ReplicaSet.", - "replicas": "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller", + "replicas": "Replicas is the number of desired replicas. This is a pointer to distinguish between explicit zero and unspecified. Defaults to 1. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller", "minReadySeconds": "Minimum number of seconds for which a newly created pod should be ready without any of its container crashing, for it to be considered available. Defaults to 0 (pod will be considered available as soon as it is ready)", - "selector": "Selector is a label query over pods that should match the replica count. If the selector is empty, it is defaulted to the labels present on the pod template. Label keys and values that must match in order to be controlled by this replica set. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "template": "Template is the object that describes the pod that will be created if insufficient replicas are detected. More info: http://kubernetes.io/docs/user-guide/replication-controller#pod-template", + "selector": "Selector is a label query over pods that should match the replica count. If the selector is empty, it is defaulted to the labels present on the pod template. Label keys and values that must match in order to be controlled by this replica set. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", + "template": "Template is the object that describes the pod that will be created if insufficient replicas are detected. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller#pod-template", } func (ReplicaSetSpec) SwaggerDoc() map[string]string { @@ -585,7 +479,7 @@ func (ReplicaSetSpec) SwaggerDoc() map[string]string { var map_ReplicaSetStatus = map[string]string{ "": "ReplicaSetStatus represents the current status of a ReplicaSet.", - "replicas": "Replicas is the most recently oberved number of replicas. More info: http://kubernetes.io/docs/user-guide/replication-controller#what-is-a-replication-controller", + "replicas": "Replicas is the most recently oberved number of replicas. More info: https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/#what-is-a-replicationcontroller", "fullyLabeledReplicas": "The number of pods that have labels matching the labels of the pod template of the replicaset.", "readyReplicas": "The number of ready replicas for this replica set.", "availableReplicas": "The number of available replicas (ready for at least minReadySeconds) for this replica set.", @@ -606,16 +500,25 @@ func (ReplicationControllerDummy) SwaggerDoc() map[string]string { } var map_RollbackConfig = map[string]string{ - "revision": "The revision to rollback to. If set to 0, rollbck to the last revision.", + "revision": "The revision to rollback to. If set to 0, rollback to the last revision.", } func (RollbackConfig) SwaggerDoc() map[string]string { return map_RollbackConfig } +var map_RollingUpdateDaemonSet = map[string]string{ + "": "Spec to control the desired behavior of daemon set rolling update.", + "maxUnavailable": "The maximum number of DaemonSet pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of total number of DaemonSet pods at the start of the update (ex: 10%). Absolute number is calculated from percentage by rounding up. This cannot be 0. Default value is 1. Example: when this is set to 30%, at most 30% of the total number of nodes that should be running the daemon pod (i.e. status.desiredNumberScheduled) can have their pods stopped for an update at any given time. The update starts by stopping at most 30% of those DaemonSet pods and then brings up new DaemonSet pods in their place. Once the new pods are available, it then proceeds onto other DaemonSet pods, thus ensuring that at least 70% of original number of DaemonSet pods are available at all times during the update.", +} + +func (RollingUpdateDaemonSet) SwaggerDoc() map[string]string { + return map_RollingUpdateDaemonSet +} + var map_RollingUpdateDeployment = map[string]string{ "": "Spec to control the desired behavior of rolling update.", - "maxUnavailable": "The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding up. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods.", + "maxUnavailable": "The maximum number of pods that can be unavailable during the update. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). Absolute number is calculated from percentage by rounding down. This can not be 0 if MaxSurge is 0. By default, a fixed value of 1 is used. Example: when this is set to 30%, the old RC can be scaled down to 70% of desired pods immediately when the rolling update starts. Once new pods are ready, old RC can be scaled down further, followed by scaling up the new RC, ensuring that the total number of pods available at all times during the update is at least 70% of desired pods.", "maxSurge": "The maximum number of pods that can be scheduled above the desired number of pods. Value can be an absolute number (ex: 5) or a percentage of desired pods (ex: 10%). This can not be 0 if MaxUnavailable is 0. Absolute number is calculated from percentage by rounding up. By default, a value of 1 is used. Example: when this is set to 30%, the new RC can be scaled up immediately when the rolling update starts, such that the total number of old and new pods do not exceed 130% of desired pods. Once old pods have been killed, new RC can be scaled up further, ensuring that total number of pods running at any time during the update is atmost 130% of desired pods.", } @@ -636,7 +539,7 @@ func (RunAsUserStrategyOptions) SwaggerDoc() map[string]string { var map_SELinuxStrategyOptions = map[string]string{ "": "SELinux Strategy Options defines the strategy type and any options used to create the strategy.", "rule": "type is the strategy that will dictate the allowable labels that may be set.", - "seLinuxOptions": "seLinuxOptions required to run as; required for MustRunAs More info: http://releases.k8s.io/HEAD/docs/design/security_context.md#security-context", + "seLinuxOptions": "seLinuxOptions required to run as; required for MustRunAs More info: https://git.k8s.io/community/contributors/design-proposals/security_context.md", } func (SELinuxStrategyOptions) SwaggerDoc() map[string]string { @@ -645,9 +548,9 @@ func (SELinuxStrategyOptions) SwaggerDoc() map[string]string { var map_Scale = map[string]string{ "": "represents a scaling request for a resource.", - "metadata": "Standard object metadata; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata.", - "spec": "defines the behavior of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status.", - "status": "current status of the scale. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#spec-and-status. Read-only.", + "metadata": "Standard object metadata; More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata.", + "spec": "defines the behavior of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status.", + "status": "current status of the scale. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#spec-and-status. Read-only.", } func (Scale) SwaggerDoc() map[string]string { @@ -667,25 +570,13 @@ var map_ScaleStatus = map[string]string{ "": "represents the current status of a scale subresource.", "replicas": "actual number of observed instances of the scaled object.", "selector": "label query over pods that should match the replicas count. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", - "targetSelector": "label selector for pods that should match the replicas count. This is a serializated version of both map-based and more expressive set-based selectors. This is done to avoid introspection in the clients. The string will be in the same format as the query-param syntax. If the target type only supports map-based selectors, both this field and map-based selector field are populated. More info: http://kubernetes.io/docs/user-guide/labels#label-selectors", + "targetSelector": "label selector for pods that should match the replicas count. This is a serializated version of both map-based and more expressive set-based selectors. This is done to avoid introspection in the clients. The string will be in the same format as the query-param syntax. If the target type only supports map-based selectors, both this field and map-based selector field are populated. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors", } func (ScaleStatus) SwaggerDoc() map[string]string { return map_ScaleStatus } -var map_SubresourceReference = map[string]string{ - "": "SubresourceReference contains enough information to let you inspect or modify the referred subresource.", - "kind": "Kind of the referent; More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#types-kinds", - "name": "Name of the referent; More info: http://kubernetes.io/docs/user-guide/identifiers#names", - "apiVersion": "API version of the referent", - "subresource": "Subresource name of the referent", -} - -func (SubresourceReference) SwaggerDoc() map[string]string { - return map_SubresourceReference -} - var map_SupplementalGroupsStrategyOptions = map[string]string{ "": "SupplementalGroupsStrategyOptions defines the strategy type and options used to create the strategy.", "rule": "Rule is the strategy that will dictate what supplemental groups is used in the SecurityContext.", @@ -719,7 +610,7 @@ func (ThirdPartyResourceData) SwaggerDoc() map[string]string { var map_ThirdPartyResourceDataList = map[string]string{ "": "ThirdPartyResrouceDataList is a list of ThirdPartyResourceData.", - "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard list metadata More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "items": "Items is the list of ThirdpartyResourceData.", } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go index ea0292d94b..efb81430a3 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,15 +21,13 @@ limitations under the License. package v1beta1 import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" - autoscaling "k8s.io/client-go/pkg/apis/autoscaling" - batch "k8s.io/client-go/pkg/apis/batch" + api_v1 "k8s.io/client-go/pkg/api/v1" extensions "k8s.io/client-go/pkg/apis/extensions" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - intstr "k8s.io/client-go/pkg/util/intstr" unsafe "unsafe" ) @@ -59,6 +57,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_extensions_DaemonSetSpec_To_v1beta1_DaemonSetSpec, Convert_v1beta1_DaemonSetStatus_To_extensions_DaemonSetStatus, Convert_extensions_DaemonSetStatus_To_v1beta1_DaemonSetStatus, + Convert_v1beta1_DaemonSetUpdateStrategy_To_extensions_DaemonSetUpdateStrategy, + Convert_extensions_DaemonSetUpdateStrategy_To_v1beta1_DaemonSetUpdateStrategy, Convert_v1beta1_Deployment_To_extensions_Deployment, Convert_extensions_Deployment_To_v1beta1_Deployment, Convert_v1beta1_DeploymentCondition_To_extensions_DeploymentCondition, @@ -73,26 +73,14 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_extensions_DeploymentStatus_To_v1beta1_DeploymentStatus, Convert_v1beta1_DeploymentStrategy_To_extensions_DeploymentStrategy, Convert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy, - Convert_v1beta1_ExportOptions_To_api_ExportOptions, - Convert_api_ExportOptions_To_v1beta1_ExportOptions, Convert_v1beta1_FSGroupStrategyOptions_To_extensions_FSGroupStrategyOptions, Convert_extensions_FSGroupStrategyOptions_To_v1beta1_FSGroupStrategyOptions, Convert_v1beta1_HTTPIngressPath_To_extensions_HTTPIngressPath, Convert_extensions_HTTPIngressPath_To_v1beta1_HTTPIngressPath, Convert_v1beta1_HTTPIngressRuleValue_To_extensions_HTTPIngressRuleValue, Convert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue, - Convert_v1beta1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler, - Convert_autoscaling_HorizontalPodAutoscaler_To_v1beta1_HorizontalPodAutoscaler, - Convert_v1beta1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList, - Convert_autoscaling_HorizontalPodAutoscalerList_To_v1beta1_HorizontalPodAutoscalerList, - Convert_v1beta1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec, - Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1beta1_HorizontalPodAutoscalerSpec, - Convert_v1beta1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus, - Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1beta1_HorizontalPodAutoscalerStatus, Convert_v1beta1_HostPortRange_To_extensions_HostPortRange, Convert_extensions_HostPortRange_To_v1beta1_HostPortRange, - Convert_v1beta1_IDRange_To_extensions_IDRange, - Convert_extensions_IDRange_To_v1beta1_IDRange, Convert_v1beta1_Ingress_To_extensions_Ingress, Convert_extensions_Ingress_To_v1beta1_Ingress, Convert_v1beta1_IngressBackend_To_extensions_IngressBackend, @@ -109,16 +97,6 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_extensions_IngressStatus_To_v1beta1_IngressStatus, Convert_v1beta1_IngressTLS_To_extensions_IngressTLS, Convert_extensions_IngressTLS_To_v1beta1_IngressTLS, - Convert_v1beta1_Job_To_batch_Job, - Convert_batch_Job_To_v1beta1_Job, - Convert_v1beta1_JobCondition_To_batch_JobCondition, - Convert_batch_JobCondition_To_v1beta1_JobCondition, - Convert_v1beta1_JobList_To_batch_JobList, - Convert_batch_JobList_To_v1beta1_JobList, - Convert_v1beta1_JobSpec_To_batch_JobSpec, - Convert_batch_JobSpec_To_v1beta1_JobSpec, - Convert_v1beta1_JobStatus_To_batch_JobStatus, - Convert_batch_JobStatus_To_v1beta1_JobStatus, Convert_v1beta1_NetworkPolicy_To_extensions_NetworkPolicy, Convert_extensions_NetworkPolicy_To_v1beta1_NetworkPolicy, Convert_v1beta1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule, @@ -151,6 +129,8 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_extensions_ReplicationControllerDummy_To_v1beta1_ReplicationControllerDummy, Convert_v1beta1_RollbackConfig_To_extensions_RollbackConfig, Convert_extensions_RollbackConfig_To_v1beta1_RollbackConfig, + Convert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet, + Convert_extensions_RollingUpdateDaemonSet_To_v1beta1_RollingUpdateDaemonSet, Convert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployment, Convert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployment, Convert_v1beta1_RunAsUserStrategyOptions_To_extensions_RunAsUserStrategyOptions, @@ -181,6 +161,7 @@ func autoConvert_v1beta1_APIVersion_To_extensions_APIVersion(in *APIVersion, out return nil } +// Convert_v1beta1_APIVersion_To_extensions_APIVersion is an autogenerated conversion function. func Convert_v1beta1_APIVersion_To_extensions_APIVersion(in *APIVersion, out *extensions.APIVersion, s conversion.Scope) error { return autoConvert_v1beta1_APIVersion_To_extensions_APIVersion(in, out, s) } @@ -190,6 +171,7 @@ func autoConvert_extensions_APIVersion_To_v1beta1_APIVersion(in *extensions.APIV return nil } +// Convert_extensions_APIVersion_To_v1beta1_APIVersion is an autogenerated conversion function. func Convert_extensions_APIVersion_To_v1beta1_APIVersion(in *extensions.APIVersion, out *APIVersion, s conversion.Scope) error { return autoConvert_extensions_APIVersion_To_v1beta1_APIVersion(in, out, s) } @@ -200,6 +182,7 @@ func autoConvert_v1beta1_CustomMetricCurrentStatus_To_extensions_CustomMetricCur return nil } +// Convert_v1beta1_CustomMetricCurrentStatus_To_extensions_CustomMetricCurrentStatus is an autogenerated conversion function. func Convert_v1beta1_CustomMetricCurrentStatus_To_extensions_CustomMetricCurrentStatus(in *CustomMetricCurrentStatus, out *extensions.CustomMetricCurrentStatus, s conversion.Scope) error { return autoConvert_v1beta1_CustomMetricCurrentStatus_To_extensions_CustomMetricCurrentStatus(in, out, s) } @@ -210,6 +193,7 @@ func autoConvert_extensions_CustomMetricCurrentStatus_To_v1beta1_CustomMetricCur return nil } +// Convert_extensions_CustomMetricCurrentStatus_To_v1beta1_CustomMetricCurrentStatus is an autogenerated conversion function. func Convert_extensions_CustomMetricCurrentStatus_To_v1beta1_CustomMetricCurrentStatus(in *extensions.CustomMetricCurrentStatus, out *CustomMetricCurrentStatus, s conversion.Scope) error { return autoConvert_extensions_CustomMetricCurrentStatus_To_v1beta1_CustomMetricCurrentStatus(in, out, s) } @@ -219,15 +203,21 @@ func autoConvert_v1beta1_CustomMetricCurrentStatusList_To_extensions_CustomMetri return nil } +// Convert_v1beta1_CustomMetricCurrentStatusList_To_extensions_CustomMetricCurrentStatusList is an autogenerated conversion function. func Convert_v1beta1_CustomMetricCurrentStatusList_To_extensions_CustomMetricCurrentStatusList(in *CustomMetricCurrentStatusList, out *extensions.CustomMetricCurrentStatusList, s conversion.Scope) error { return autoConvert_v1beta1_CustomMetricCurrentStatusList_To_extensions_CustomMetricCurrentStatusList(in, out, s) } func autoConvert_extensions_CustomMetricCurrentStatusList_To_v1beta1_CustomMetricCurrentStatusList(in *extensions.CustomMetricCurrentStatusList, out *CustomMetricCurrentStatusList, s conversion.Scope) error { - out.Items = *(*[]CustomMetricCurrentStatus)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]CustomMetricCurrentStatus, 0) + } else { + out.Items = *(*[]CustomMetricCurrentStatus)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_extensions_CustomMetricCurrentStatusList_To_v1beta1_CustomMetricCurrentStatusList is an autogenerated conversion function. func Convert_extensions_CustomMetricCurrentStatusList_To_v1beta1_CustomMetricCurrentStatusList(in *extensions.CustomMetricCurrentStatusList, out *CustomMetricCurrentStatusList, s conversion.Scope) error { return autoConvert_extensions_CustomMetricCurrentStatusList_To_v1beta1_CustomMetricCurrentStatusList(in, out, s) } @@ -238,6 +228,7 @@ func autoConvert_v1beta1_CustomMetricTarget_To_extensions_CustomMetricTarget(in return nil } +// Convert_v1beta1_CustomMetricTarget_To_extensions_CustomMetricTarget is an autogenerated conversion function. func Convert_v1beta1_CustomMetricTarget_To_extensions_CustomMetricTarget(in *CustomMetricTarget, out *extensions.CustomMetricTarget, s conversion.Scope) error { return autoConvert_v1beta1_CustomMetricTarget_To_extensions_CustomMetricTarget(in, out, s) } @@ -248,6 +239,7 @@ func autoConvert_extensions_CustomMetricTarget_To_v1beta1_CustomMetricTarget(in return nil } +// Convert_extensions_CustomMetricTarget_To_v1beta1_CustomMetricTarget is an autogenerated conversion function. func Convert_extensions_CustomMetricTarget_To_v1beta1_CustomMetricTarget(in *extensions.CustomMetricTarget, out *CustomMetricTarget, s conversion.Scope) error { return autoConvert_extensions_CustomMetricTarget_To_v1beta1_CustomMetricTarget(in, out, s) } @@ -257,24 +249,27 @@ func autoConvert_v1beta1_CustomMetricTargetList_To_extensions_CustomMetricTarget return nil } +// Convert_v1beta1_CustomMetricTargetList_To_extensions_CustomMetricTargetList is an autogenerated conversion function. func Convert_v1beta1_CustomMetricTargetList_To_extensions_CustomMetricTargetList(in *CustomMetricTargetList, out *extensions.CustomMetricTargetList, s conversion.Scope) error { return autoConvert_v1beta1_CustomMetricTargetList_To_extensions_CustomMetricTargetList(in, out, s) } func autoConvert_extensions_CustomMetricTargetList_To_v1beta1_CustomMetricTargetList(in *extensions.CustomMetricTargetList, out *CustomMetricTargetList, s conversion.Scope) error { - out.Items = *(*[]CustomMetricTarget)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]CustomMetricTarget, 0) + } else { + out.Items = *(*[]CustomMetricTarget)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_extensions_CustomMetricTargetList_To_v1beta1_CustomMetricTargetList is an autogenerated conversion function. func Convert_extensions_CustomMetricTargetList_To_v1beta1_CustomMetricTargetList(in *extensions.CustomMetricTargetList, out *CustomMetricTargetList, s conversion.Scope) error { return autoConvert_extensions_CustomMetricTargetList_To_v1beta1_CustomMetricTargetList(in, out, s) } func autoConvert_v1beta1_DaemonSet_To_extensions_DaemonSet(in *DaemonSet, out *extensions.DaemonSet, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_DaemonSetSpec_To_extensions_DaemonSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -284,15 +279,13 @@ func autoConvert_v1beta1_DaemonSet_To_extensions_DaemonSet(in *DaemonSet, out *e return nil } +// Convert_v1beta1_DaemonSet_To_extensions_DaemonSet is an autogenerated conversion function. func Convert_v1beta1_DaemonSet_To_extensions_DaemonSet(in *DaemonSet, out *extensions.DaemonSet, s conversion.Scope) error { return autoConvert_v1beta1_DaemonSet_To_extensions_DaemonSet(in, out, s) } func autoConvert_extensions_DaemonSet_To_v1beta1_DaemonSet(in *extensions.DaemonSet, out *DaemonSet, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_DaemonSetSpec_To_v1beta1_DaemonSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -302,6 +295,7 @@ func autoConvert_extensions_DaemonSet_To_v1beta1_DaemonSet(in *extensions.Daemon return nil } +// Convert_extensions_DaemonSet_To_v1beta1_DaemonSet is an autogenerated conversion function. func Convert_extensions_DaemonSet_To_v1beta1_DaemonSet(in *extensions.DaemonSet, out *DaemonSet, s conversion.Scope) error { return autoConvert_extensions_DaemonSet_To_v1beta1_DaemonSet(in, out, s) } @@ -322,6 +316,7 @@ func autoConvert_v1beta1_DaemonSetList_To_extensions_DaemonSetList(in *DaemonSet return nil } +// Convert_v1beta1_DaemonSetList_To_extensions_DaemonSetList is an autogenerated conversion function. func Convert_v1beta1_DaemonSetList_To_extensions_DaemonSetList(in *DaemonSetList, out *extensions.DaemonSetList, s conversion.Scope) error { return autoConvert_v1beta1_DaemonSetList_To_extensions_DaemonSetList(in, out, s) } @@ -337,35 +332,50 @@ func autoConvert_extensions_DaemonSetList_To_v1beta1_DaemonSetList(in *extension } } } else { - out.Items = nil + out.Items = make([]DaemonSet, 0) } return nil } +// Convert_extensions_DaemonSetList_To_v1beta1_DaemonSetList is an autogenerated conversion function. func Convert_extensions_DaemonSetList_To_v1beta1_DaemonSetList(in *extensions.DaemonSetList, out *DaemonSetList, s conversion.Scope) error { return autoConvert_extensions_DaemonSetList_To_v1beta1_DaemonSetList(in, out, s) } func autoConvert_v1beta1_DaemonSetSpec_To_extensions_DaemonSetSpec(in *DaemonSetSpec, out *extensions.DaemonSetSpec, s conversion.Scope) error { - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + return err + } + if err := Convert_v1beta1_DaemonSetUpdateStrategy_To_extensions_DaemonSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, s); err != nil { return err } + out.MinReadySeconds = in.MinReadySeconds + out.TemplateGeneration = in.TemplateGeneration + out.RevisionHistoryLimit = (*int32)(unsafe.Pointer(in.RevisionHistoryLimit)) return nil } +// Convert_v1beta1_DaemonSetSpec_To_extensions_DaemonSetSpec is an autogenerated conversion function. func Convert_v1beta1_DaemonSetSpec_To_extensions_DaemonSetSpec(in *DaemonSetSpec, out *extensions.DaemonSetSpec, s conversion.Scope) error { return autoConvert_v1beta1_DaemonSetSpec_To_extensions_DaemonSetSpec(in, out, s) } func autoConvert_extensions_DaemonSetSpec_To_v1beta1_DaemonSetSpec(in *extensions.DaemonSetSpec, out *DaemonSetSpec, s conversion.Scope) error { - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } + if err := Convert_extensions_DaemonSetUpdateStrategy_To_v1beta1_DaemonSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, s); err != nil { + return err + } + out.MinReadySeconds = in.MinReadySeconds + out.TemplateGeneration = in.TemplateGeneration + out.RevisionHistoryLimit = (*int32)(unsafe.Pointer(in.RevisionHistoryLimit)) return nil } +// Convert_extensions_DaemonSetSpec_To_v1beta1_DaemonSetSpec is an autogenerated conversion function. func Convert_extensions_DaemonSetSpec_To_v1beta1_DaemonSetSpec(in *extensions.DaemonSetSpec, out *DaemonSetSpec, s conversion.Scope) error { return autoConvert_extensions_DaemonSetSpec_To_v1beta1_DaemonSetSpec(in, out, s) } @@ -375,9 +385,15 @@ func autoConvert_v1beta1_DaemonSetStatus_To_extensions_DaemonSetStatus(in *Daemo out.NumberMisscheduled = in.NumberMisscheduled out.DesiredNumberScheduled = in.DesiredNumberScheduled out.NumberReady = in.NumberReady + out.ObservedGeneration = in.ObservedGeneration + out.UpdatedNumberScheduled = in.UpdatedNumberScheduled + out.NumberAvailable = in.NumberAvailable + out.NumberUnavailable = in.NumberUnavailable + out.CollisionCount = (*int64)(unsafe.Pointer(in.CollisionCount)) return nil } +// Convert_v1beta1_DaemonSetStatus_To_extensions_DaemonSetStatus is an autogenerated conversion function. func Convert_v1beta1_DaemonSetStatus_To_extensions_DaemonSetStatus(in *DaemonSetStatus, out *extensions.DaemonSetStatus, s conversion.Scope) error { return autoConvert_v1beta1_DaemonSetStatus_To_extensions_DaemonSetStatus(in, out, s) } @@ -387,18 +403,59 @@ func autoConvert_extensions_DaemonSetStatus_To_v1beta1_DaemonSetStatus(in *exten out.NumberMisscheduled = in.NumberMisscheduled out.DesiredNumberScheduled = in.DesiredNumberScheduled out.NumberReady = in.NumberReady + out.ObservedGeneration = in.ObservedGeneration + out.UpdatedNumberScheduled = in.UpdatedNumberScheduled + out.NumberAvailable = in.NumberAvailable + out.NumberUnavailable = in.NumberUnavailable + out.CollisionCount = (*int64)(unsafe.Pointer(in.CollisionCount)) return nil } +// Convert_extensions_DaemonSetStatus_To_v1beta1_DaemonSetStatus is an autogenerated conversion function. func Convert_extensions_DaemonSetStatus_To_v1beta1_DaemonSetStatus(in *extensions.DaemonSetStatus, out *DaemonSetStatus, s conversion.Scope) error { return autoConvert_extensions_DaemonSetStatus_To_v1beta1_DaemonSetStatus(in, out, s) } -func autoConvert_v1beta1_Deployment_To_extensions_Deployment(in *Deployment, out *extensions.Deployment, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err +func autoConvert_v1beta1_DaemonSetUpdateStrategy_To_extensions_DaemonSetUpdateStrategy(in *DaemonSetUpdateStrategy, out *extensions.DaemonSetUpdateStrategy, s conversion.Scope) error { + out.Type = extensions.DaemonSetUpdateStrategyType(in.Type) + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(extensions.RollingUpdateDaemonSet) + if err := Convert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet(*in, *out, s); err != nil { + return err + } + } else { + out.RollingUpdate = nil + } + return nil +} + +// Convert_v1beta1_DaemonSetUpdateStrategy_To_extensions_DaemonSetUpdateStrategy is an autogenerated conversion function. +func Convert_v1beta1_DaemonSetUpdateStrategy_To_extensions_DaemonSetUpdateStrategy(in *DaemonSetUpdateStrategy, out *extensions.DaemonSetUpdateStrategy, s conversion.Scope) error { + return autoConvert_v1beta1_DaemonSetUpdateStrategy_To_extensions_DaemonSetUpdateStrategy(in, out, s) +} + +func autoConvert_extensions_DaemonSetUpdateStrategy_To_v1beta1_DaemonSetUpdateStrategy(in *extensions.DaemonSetUpdateStrategy, out *DaemonSetUpdateStrategy, s conversion.Scope) error { + out.Type = DaemonSetUpdateStrategyType(in.Type) + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateDaemonSet) + if err := Convert_extensions_RollingUpdateDaemonSet_To_v1beta1_RollingUpdateDaemonSet(*in, *out, s); err != nil { + return err + } + } else { + out.RollingUpdate = nil } + return nil +} + +// Convert_extensions_DaemonSetUpdateStrategy_To_v1beta1_DaemonSetUpdateStrategy is an autogenerated conversion function. +func Convert_extensions_DaemonSetUpdateStrategy_To_v1beta1_DaemonSetUpdateStrategy(in *extensions.DaemonSetUpdateStrategy, out *DaemonSetUpdateStrategy, s conversion.Scope) error { + return autoConvert_extensions_DaemonSetUpdateStrategy_To_v1beta1_DaemonSetUpdateStrategy(in, out, s) +} + +func autoConvert_v1beta1_Deployment_To_extensions_Deployment(in *Deployment, out *extensions.Deployment, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -408,15 +465,13 @@ func autoConvert_v1beta1_Deployment_To_extensions_Deployment(in *Deployment, out return nil } +// Convert_v1beta1_Deployment_To_extensions_Deployment is an autogenerated conversion function. func Convert_v1beta1_Deployment_To_extensions_Deployment(in *Deployment, out *extensions.Deployment, s conversion.Scope) error { return autoConvert_v1beta1_Deployment_To_extensions_Deployment(in, out, s) } func autoConvert_extensions_Deployment_To_v1beta1_Deployment(in *extensions.Deployment, out *Deployment, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_DeploymentSpec_To_v1beta1_DeploymentSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -426,6 +481,7 @@ func autoConvert_extensions_Deployment_To_v1beta1_Deployment(in *extensions.Depl return nil } +// Convert_extensions_Deployment_To_v1beta1_Deployment is an autogenerated conversion function. func Convert_extensions_Deployment_To_v1beta1_Deployment(in *extensions.Deployment, out *Deployment, s conversion.Scope) error { return autoConvert_extensions_Deployment_To_v1beta1_Deployment(in, out, s) } @@ -440,13 +496,14 @@ func autoConvert_v1beta1_DeploymentCondition_To_extensions_DeploymentCondition(i return nil } +// Convert_v1beta1_DeploymentCondition_To_extensions_DeploymentCondition is an autogenerated conversion function. func Convert_v1beta1_DeploymentCondition_To_extensions_DeploymentCondition(in *DeploymentCondition, out *extensions.DeploymentCondition, s conversion.Scope) error { return autoConvert_v1beta1_DeploymentCondition_To_extensions_DeploymentCondition(in, out, s) } func autoConvert_extensions_DeploymentCondition_To_v1beta1_DeploymentCondition(in *extensions.DeploymentCondition, out *DeploymentCondition, s conversion.Scope) error { out.Type = DeploymentConditionType(in.Type) - out.Status = v1.ConditionStatus(in.Status) + out.Status = api_v1.ConditionStatus(in.Status) out.LastUpdateTime = in.LastUpdateTime out.LastTransitionTime = in.LastTransitionTime out.Reason = in.Reason @@ -454,6 +511,7 @@ func autoConvert_extensions_DeploymentCondition_To_v1beta1_DeploymentCondition(i return nil } +// Convert_extensions_DeploymentCondition_To_v1beta1_DeploymentCondition is an autogenerated conversion function. func Convert_extensions_DeploymentCondition_To_v1beta1_DeploymentCondition(in *extensions.DeploymentCondition, out *DeploymentCondition, s conversion.Scope) error { return autoConvert_extensions_DeploymentCondition_To_v1beta1_DeploymentCondition(in, out, s) } @@ -474,6 +532,7 @@ func autoConvert_v1beta1_DeploymentList_To_extensions_DeploymentList(in *Deploym return nil } +// Convert_v1beta1_DeploymentList_To_extensions_DeploymentList is an autogenerated conversion function. func Convert_v1beta1_DeploymentList_To_extensions_DeploymentList(in *DeploymentList, out *extensions.DeploymentList, s conversion.Scope) error { return autoConvert_v1beta1_DeploymentList_To_extensions_DeploymentList(in, out, s) } @@ -489,11 +548,12 @@ func autoConvert_extensions_DeploymentList_To_v1beta1_DeploymentList(in *extensi } } } else { - out.Items = nil + out.Items = make([]Deployment, 0) } return nil } +// Convert_extensions_DeploymentList_To_v1beta1_DeploymentList is an autogenerated conversion function. func Convert_extensions_DeploymentList_To_v1beta1_DeploymentList(in *extensions.DeploymentList, out *DeploymentList, s conversion.Scope) error { return autoConvert_extensions_DeploymentList_To_v1beta1_DeploymentList(in, out, s) } @@ -507,6 +567,7 @@ func autoConvert_v1beta1_DeploymentRollback_To_extensions_DeploymentRollback(in return nil } +// Convert_v1beta1_DeploymentRollback_To_extensions_DeploymentRollback is an autogenerated conversion function. func Convert_v1beta1_DeploymentRollback_To_extensions_DeploymentRollback(in *DeploymentRollback, out *extensions.DeploymentRollback, s conversion.Scope) error { return autoConvert_v1beta1_DeploymentRollback_To_extensions_DeploymentRollback(in, out, s) } @@ -520,16 +581,17 @@ func autoConvert_extensions_DeploymentRollback_To_v1beta1_DeploymentRollback(in return nil } +// Convert_extensions_DeploymentRollback_To_v1beta1_DeploymentRollback is an autogenerated conversion function. func Convert_extensions_DeploymentRollback_To_v1beta1_DeploymentRollback(in *extensions.DeploymentRollback, out *DeploymentRollback, s conversion.Scope) error { return autoConvert_extensions_DeploymentRollback_To_v1beta1_DeploymentRollback(in, out, s) } func autoConvert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec(in *DeploymentSpec, out *extensions.DeploymentSpec, s conversion.Scope) error { - if err := api.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := v1.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } if err := Convert_v1beta1_DeploymentStrategy_To_extensions_DeploymentStrategy(&in.Strategy, &out.Strategy, s); err != nil { @@ -544,11 +606,11 @@ func autoConvert_v1beta1_DeploymentSpec_To_extensions_DeploymentSpec(in *Deploym } func autoConvert_extensions_DeploymentSpec_To_v1beta1_DeploymentSpec(in *extensions.DeploymentSpec, out *DeploymentSpec, s conversion.Scope) error { - if err := api.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := v1.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } if err := Convert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy(&in.Strategy, &out.Strategy, s); err != nil { @@ -566,12 +628,15 @@ func autoConvert_v1beta1_DeploymentStatus_To_extensions_DeploymentStatus(in *Dep out.ObservedGeneration = in.ObservedGeneration out.Replicas = in.Replicas out.UpdatedReplicas = in.UpdatedReplicas + out.ReadyReplicas = in.ReadyReplicas out.AvailableReplicas = in.AvailableReplicas out.UnavailableReplicas = in.UnavailableReplicas out.Conditions = *(*[]extensions.DeploymentCondition)(unsafe.Pointer(&in.Conditions)) + out.CollisionCount = (*int64)(unsafe.Pointer(in.CollisionCount)) return nil } +// Convert_v1beta1_DeploymentStatus_To_extensions_DeploymentStatus is an autogenerated conversion function. func Convert_v1beta1_DeploymentStatus_To_extensions_DeploymentStatus(in *DeploymentStatus, out *extensions.DeploymentStatus, s conversion.Scope) error { return autoConvert_v1beta1_DeploymentStatus_To_extensions_DeploymentStatus(in, out, s) } @@ -580,12 +645,15 @@ func autoConvert_extensions_DeploymentStatus_To_v1beta1_DeploymentStatus(in *ext out.ObservedGeneration = in.ObservedGeneration out.Replicas = in.Replicas out.UpdatedReplicas = in.UpdatedReplicas + out.ReadyReplicas = in.ReadyReplicas out.AvailableReplicas = in.AvailableReplicas out.UnavailableReplicas = in.UnavailableReplicas out.Conditions = *(*[]DeploymentCondition)(unsafe.Pointer(&in.Conditions)) + out.CollisionCount = (*int64)(unsafe.Pointer(in.CollisionCount)) return nil } +// Convert_extensions_DeploymentStatus_To_v1beta1_DeploymentStatus is an autogenerated conversion function. func Convert_extensions_DeploymentStatus_To_v1beta1_DeploymentStatus(in *extensions.DeploymentStatus, out *DeploymentStatus, s conversion.Scope) error { return autoConvert_extensions_DeploymentStatus_To_v1beta1_DeploymentStatus(in, out, s) } @@ -618,32 +686,13 @@ func autoConvert_extensions_DeploymentStrategy_To_v1beta1_DeploymentStrategy(in return nil } -func autoConvert_v1beta1_ExportOptions_To_api_ExportOptions(in *ExportOptions, out *api.ExportOptions, s conversion.Scope) error { - out.Export = in.Export - out.Exact = in.Exact - return nil -} - -func Convert_v1beta1_ExportOptions_To_api_ExportOptions(in *ExportOptions, out *api.ExportOptions, s conversion.Scope) error { - return autoConvert_v1beta1_ExportOptions_To_api_ExportOptions(in, out, s) -} - -func autoConvert_api_ExportOptions_To_v1beta1_ExportOptions(in *api.ExportOptions, out *ExportOptions, s conversion.Scope) error { - out.Export = in.Export - out.Exact = in.Exact - return nil -} - -func Convert_api_ExportOptions_To_v1beta1_ExportOptions(in *api.ExportOptions, out *ExportOptions, s conversion.Scope) error { - return autoConvert_api_ExportOptions_To_v1beta1_ExportOptions(in, out, s) -} - func autoConvert_v1beta1_FSGroupStrategyOptions_To_extensions_FSGroupStrategyOptions(in *FSGroupStrategyOptions, out *extensions.FSGroupStrategyOptions, s conversion.Scope) error { out.Rule = extensions.FSGroupStrategyType(in.Rule) - out.Ranges = *(*[]extensions.IDRange)(unsafe.Pointer(&in.Ranges)) + out.Ranges = *(*[]extensions.GroupIDRange)(unsafe.Pointer(&in.Ranges)) return nil } +// Convert_v1beta1_FSGroupStrategyOptions_To_extensions_FSGroupStrategyOptions is an autogenerated conversion function. func Convert_v1beta1_FSGroupStrategyOptions_To_extensions_FSGroupStrategyOptions(in *FSGroupStrategyOptions, out *extensions.FSGroupStrategyOptions, s conversion.Scope) error { return autoConvert_v1beta1_FSGroupStrategyOptions_To_extensions_FSGroupStrategyOptions(in, out, s) } @@ -654,6 +703,7 @@ func autoConvert_extensions_FSGroupStrategyOptions_To_v1beta1_FSGroupStrategyOpt return nil } +// Convert_extensions_FSGroupStrategyOptions_To_v1beta1_FSGroupStrategyOptions is an autogenerated conversion function. func Convert_extensions_FSGroupStrategyOptions_To_v1beta1_FSGroupStrategyOptions(in *extensions.FSGroupStrategyOptions, out *FSGroupStrategyOptions, s conversion.Scope) error { return autoConvert_extensions_FSGroupStrategyOptions_To_v1beta1_FSGroupStrategyOptions(in, out, s) } @@ -666,6 +716,7 @@ func autoConvert_v1beta1_HTTPIngressPath_To_extensions_HTTPIngressPath(in *HTTPI return nil } +// Convert_v1beta1_HTTPIngressPath_To_extensions_HTTPIngressPath is an autogenerated conversion function. func Convert_v1beta1_HTTPIngressPath_To_extensions_HTTPIngressPath(in *HTTPIngressPath, out *extensions.HTTPIngressPath, s conversion.Scope) error { return autoConvert_v1beta1_HTTPIngressPath_To_extensions_HTTPIngressPath(in, out, s) } @@ -678,6 +729,7 @@ func autoConvert_extensions_HTTPIngressPath_To_v1beta1_HTTPIngressPath(in *exten return nil } +// Convert_extensions_HTTPIngressPath_To_v1beta1_HTTPIngressPath is an autogenerated conversion function. func Convert_extensions_HTTPIngressPath_To_v1beta1_HTTPIngressPath(in *extensions.HTTPIngressPath, out *HTTPIngressPath, s conversion.Scope) error { return autoConvert_extensions_HTTPIngressPath_To_v1beta1_HTTPIngressPath(in, out, s) } @@ -687,135 +739,23 @@ func autoConvert_v1beta1_HTTPIngressRuleValue_To_extensions_HTTPIngressRuleValue return nil } +// Convert_v1beta1_HTTPIngressRuleValue_To_extensions_HTTPIngressRuleValue is an autogenerated conversion function. func Convert_v1beta1_HTTPIngressRuleValue_To_extensions_HTTPIngressRuleValue(in *HTTPIngressRuleValue, out *extensions.HTTPIngressRuleValue, s conversion.Scope) error { return autoConvert_v1beta1_HTTPIngressRuleValue_To_extensions_HTTPIngressRuleValue(in, out, s) } func autoConvert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue(in *extensions.HTTPIngressRuleValue, out *HTTPIngressRuleValue, s conversion.Scope) error { - out.Paths = *(*[]HTTPIngressPath)(unsafe.Pointer(&in.Paths)) - return nil -} - -func Convert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue(in *extensions.HTTPIngressRuleValue, out *HTTPIngressRuleValue, s conversion.Scope) error { - return autoConvert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue(in, out, s) -} - -func autoConvert_v1beta1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_v1beta1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_v1beta1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_v1beta1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler, out *autoscaling.HorizontalPodAutoscaler, s conversion.Scope) error { - return autoConvert_v1beta1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(in, out, s) -} - -func autoConvert_autoscaling_HorizontalPodAutoscaler_To_v1beta1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_autoscaling_HorizontalPodAutoscalerSpec_To_v1beta1_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1beta1_HorizontalPodAutoscalerStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_autoscaling_HorizontalPodAutoscaler_To_v1beta1_HorizontalPodAutoscaler(in *autoscaling.HorizontalPodAutoscaler, out *HorizontalPodAutoscaler, s conversion.Scope) error { - return autoConvert_autoscaling_HorizontalPodAutoscaler_To_v1beta1_HorizontalPodAutoscaler(in, out, s) -} - -func autoConvert_v1beta1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList, out *autoscaling.HorizontalPodAutoscalerList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]autoscaling.HorizontalPodAutoscaler, len(*in)) - for i := range *in { - if err := Convert_v1beta1_HorizontalPodAutoscaler_To_autoscaling_HorizontalPodAutoscaler(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil -} - -func Convert_v1beta1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList, out *autoscaling.HorizontalPodAutoscalerList, s conversion.Scope) error { - return autoConvert_v1beta1_HorizontalPodAutoscalerList_To_autoscaling_HorizontalPodAutoscalerList(in, out, s) -} - -func autoConvert_autoscaling_HorizontalPodAutoscalerList_To_v1beta1_HorizontalPodAutoscalerList(in *autoscaling.HorizontalPodAutoscalerList, out *HorizontalPodAutoscalerList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]HorizontalPodAutoscaler, len(*in)) - for i := range *in { - if err := Convert_autoscaling_HorizontalPodAutoscaler_To_v1beta1_HorizontalPodAutoscaler(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } + if in.Paths == nil { + out.Paths = make([]HTTPIngressPath, 0) } else { - out.Items = nil + out.Paths = *(*[]HTTPIngressPath)(unsafe.Pointer(&in.Paths)) } return nil } -func Convert_autoscaling_HorizontalPodAutoscalerList_To_v1beta1_HorizontalPodAutoscalerList(in *autoscaling.HorizontalPodAutoscalerList, out *HorizontalPodAutoscalerList, s conversion.Scope) error { - return autoConvert_autoscaling_HorizontalPodAutoscalerList_To_v1beta1_HorizontalPodAutoscalerList(in, out, s) -} - -func autoConvert_v1beta1_HorizontalPodAutoscalerSpec_To_autoscaling_HorizontalPodAutoscalerSpec(in *HorizontalPodAutoscalerSpec, out *autoscaling.HorizontalPodAutoscalerSpec, s conversion.Scope) error { - // WARNING: in.ScaleRef requires manual conversion: does not exist in peer-type - out.MinReplicas = (*int32)(unsafe.Pointer(in.MinReplicas)) - out.MaxReplicas = in.MaxReplicas - // WARNING: in.CPUUtilization requires manual conversion: does not exist in peer-type - return nil -} - -func autoConvert_autoscaling_HorizontalPodAutoscalerSpec_To_v1beta1_HorizontalPodAutoscalerSpec(in *autoscaling.HorizontalPodAutoscalerSpec, out *HorizontalPodAutoscalerSpec, s conversion.Scope) error { - // WARNING: in.ScaleTargetRef requires manual conversion: does not exist in peer-type - out.MinReplicas = (*int32)(unsafe.Pointer(in.MinReplicas)) - out.MaxReplicas = in.MaxReplicas - // WARNING: in.TargetCPUUtilizationPercentage requires manual conversion: does not exist in peer-type - return nil -} - -func autoConvert_v1beta1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { - out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) - out.LastScaleTime = (*unversioned.Time)(unsafe.Pointer(in.LastScaleTime)) - out.CurrentReplicas = in.CurrentReplicas - out.DesiredReplicas = in.DesiredReplicas - out.CurrentCPUUtilizationPercentage = (*int32)(unsafe.Pointer(in.CurrentCPUUtilizationPercentage)) - return nil -} - -func Convert_v1beta1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in *HorizontalPodAutoscalerStatus, out *autoscaling.HorizontalPodAutoscalerStatus, s conversion.Scope) error { - return autoConvert_v1beta1_HorizontalPodAutoscalerStatus_To_autoscaling_HorizontalPodAutoscalerStatus(in, out, s) -} - -func autoConvert_autoscaling_HorizontalPodAutoscalerStatus_To_v1beta1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { - out.ObservedGeneration = (*int64)(unsafe.Pointer(in.ObservedGeneration)) - out.LastScaleTime = (*unversioned.Time)(unsafe.Pointer(in.LastScaleTime)) - out.CurrentReplicas = in.CurrentReplicas - out.DesiredReplicas = in.DesiredReplicas - out.CurrentCPUUtilizationPercentage = (*int32)(unsafe.Pointer(in.CurrentCPUUtilizationPercentage)) - return nil -} - -func Convert_autoscaling_HorizontalPodAutoscalerStatus_To_v1beta1_HorizontalPodAutoscalerStatus(in *autoscaling.HorizontalPodAutoscalerStatus, out *HorizontalPodAutoscalerStatus, s conversion.Scope) error { - return autoConvert_autoscaling_HorizontalPodAutoscalerStatus_To_v1beta1_HorizontalPodAutoscalerStatus(in, out, s) +// Convert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue is an autogenerated conversion function. +func Convert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue(in *extensions.HTTPIngressRuleValue, out *HTTPIngressRuleValue, s conversion.Scope) error { + return autoConvert_extensions_HTTPIngressRuleValue_To_v1beta1_HTTPIngressRuleValue(in, out, s) } func autoConvert_v1beta1_HostPortRange_To_extensions_HostPortRange(in *HostPortRange, out *extensions.HostPortRange, s conversion.Scope) error { @@ -824,6 +764,7 @@ func autoConvert_v1beta1_HostPortRange_To_extensions_HostPortRange(in *HostPortR return nil } +// Convert_v1beta1_HostPortRange_To_extensions_HostPortRange is an autogenerated conversion function. func Convert_v1beta1_HostPortRange_To_extensions_HostPortRange(in *HostPortRange, out *extensions.HostPortRange, s conversion.Scope) error { return autoConvert_v1beta1_HostPortRange_To_extensions_HostPortRange(in, out, s) } @@ -834,35 +775,13 @@ func autoConvert_extensions_HostPortRange_To_v1beta1_HostPortRange(in *extension return nil } +// Convert_extensions_HostPortRange_To_v1beta1_HostPortRange is an autogenerated conversion function. func Convert_extensions_HostPortRange_To_v1beta1_HostPortRange(in *extensions.HostPortRange, out *HostPortRange, s conversion.Scope) error { return autoConvert_extensions_HostPortRange_To_v1beta1_HostPortRange(in, out, s) } -func autoConvert_v1beta1_IDRange_To_extensions_IDRange(in *IDRange, out *extensions.IDRange, s conversion.Scope) error { - out.Min = in.Min - out.Max = in.Max - return nil -} - -func Convert_v1beta1_IDRange_To_extensions_IDRange(in *IDRange, out *extensions.IDRange, s conversion.Scope) error { - return autoConvert_v1beta1_IDRange_To_extensions_IDRange(in, out, s) -} - -func autoConvert_extensions_IDRange_To_v1beta1_IDRange(in *extensions.IDRange, out *IDRange, s conversion.Scope) error { - out.Min = in.Min - out.Max = in.Max - return nil -} - -func Convert_extensions_IDRange_To_v1beta1_IDRange(in *extensions.IDRange, out *IDRange, s conversion.Scope) error { - return autoConvert_extensions_IDRange_To_v1beta1_IDRange(in, out, s) -} - func autoConvert_v1beta1_Ingress_To_extensions_Ingress(in *Ingress, out *extensions.Ingress, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_IngressSpec_To_extensions_IngressSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -872,15 +791,13 @@ func autoConvert_v1beta1_Ingress_To_extensions_Ingress(in *Ingress, out *extensi return nil } +// Convert_v1beta1_Ingress_To_extensions_Ingress is an autogenerated conversion function. func Convert_v1beta1_Ingress_To_extensions_Ingress(in *Ingress, out *extensions.Ingress, s conversion.Scope) error { return autoConvert_v1beta1_Ingress_To_extensions_Ingress(in, out, s) } func autoConvert_extensions_Ingress_To_v1beta1_Ingress(in *extensions.Ingress, out *Ingress, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_IngressSpec_To_v1beta1_IngressSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -890,6 +807,7 @@ func autoConvert_extensions_Ingress_To_v1beta1_Ingress(in *extensions.Ingress, o return nil } +// Convert_extensions_Ingress_To_v1beta1_Ingress is an autogenerated conversion function. func Convert_extensions_Ingress_To_v1beta1_Ingress(in *extensions.Ingress, out *Ingress, s conversion.Scope) error { return autoConvert_extensions_Ingress_To_v1beta1_Ingress(in, out, s) } @@ -900,6 +818,7 @@ func autoConvert_v1beta1_IngressBackend_To_extensions_IngressBackend(in *Ingress return nil } +// Convert_v1beta1_IngressBackend_To_extensions_IngressBackend is an autogenerated conversion function. func Convert_v1beta1_IngressBackend_To_extensions_IngressBackend(in *IngressBackend, out *extensions.IngressBackend, s conversion.Scope) error { return autoConvert_v1beta1_IngressBackend_To_extensions_IngressBackend(in, out, s) } @@ -910,6 +829,7 @@ func autoConvert_extensions_IngressBackend_To_v1beta1_IngressBackend(in *extensi return nil } +// Convert_extensions_IngressBackend_To_v1beta1_IngressBackend is an autogenerated conversion function. func Convert_extensions_IngressBackend_To_v1beta1_IngressBackend(in *extensions.IngressBackend, out *IngressBackend, s conversion.Scope) error { return autoConvert_extensions_IngressBackend_To_v1beta1_IngressBackend(in, out, s) } @@ -920,16 +840,22 @@ func autoConvert_v1beta1_IngressList_To_extensions_IngressList(in *IngressList, return nil } +// Convert_v1beta1_IngressList_To_extensions_IngressList is an autogenerated conversion function. func Convert_v1beta1_IngressList_To_extensions_IngressList(in *IngressList, out *extensions.IngressList, s conversion.Scope) error { return autoConvert_v1beta1_IngressList_To_extensions_IngressList(in, out, s) } func autoConvert_extensions_IngressList_To_v1beta1_IngressList(in *extensions.IngressList, out *IngressList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]Ingress)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]Ingress, 0) + } else { + out.Items = *(*[]Ingress)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_extensions_IngressList_To_v1beta1_IngressList is an autogenerated conversion function. func Convert_extensions_IngressList_To_v1beta1_IngressList(in *extensions.IngressList, out *IngressList, s conversion.Scope) error { return autoConvert_extensions_IngressList_To_v1beta1_IngressList(in, out, s) } @@ -942,6 +868,7 @@ func autoConvert_v1beta1_IngressRule_To_extensions_IngressRule(in *IngressRule, return nil } +// Convert_v1beta1_IngressRule_To_extensions_IngressRule is an autogenerated conversion function. func Convert_v1beta1_IngressRule_To_extensions_IngressRule(in *IngressRule, out *extensions.IngressRule, s conversion.Scope) error { return autoConvert_v1beta1_IngressRule_To_extensions_IngressRule(in, out, s) } @@ -954,6 +881,7 @@ func autoConvert_extensions_IngressRule_To_v1beta1_IngressRule(in *extensions.In return nil } +// Convert_extensions_IngressRule_To_v1beta1_IngressRule is an autogenerated conversion function. func Convert_extensions_IngressRule_To_v1beta1_IngressRule(in *extensions.IngressRule, out *IngressRule, s conversion.Scope) error { return autoConvert_extensions_IngressRule_To_v1beta1_IngressRule(in, out, s) } @@ -963,6 +891,7 @@ func autoConvert_v1beta1_IngressRuleValue_To_extensions_IngressRuleValue(in *Ing return nil } +// Convert_v1beta1_IngressRuleValue_To_extensions_IngressRuleValue is an autogenerated conversion function. func Convert_v1beta1_IngressRuleValue_To_extensions_IngressRuleValue(in *IngressRuleValue, out *extensions.IngressRuleValue, s conversion.Scope) error { return autoConvert_v1beta1_IngressRuleValue_To_extensions_IngressRuleValue(in, out, s) } @@ -972,6 +901,7 @@ func autoConvert_extensions_IngressRuleValue_To_v1beta1_IngressRuleValue(in *ext return nil } +// Convert_extensions_IngressRuleValue_To_v1beta1_IngressRuleValue is an autogenerated conversion function. func Convert_extensions_IngressRuleValue_To_v1beta1_IngressRuleValue(in *extensions.IngressRuleValue, out *IngressRuleValue, s conversion.Scope) error { return autoConvert_extensions_IngressRuleValue_To_v1beta1_IngressRuleValue(in, out, s) } @@ -983,6 +913,7 @@ func autoConvert_v1beta1_IngressSpec_To_extensions_IngressSpec(in *IngressSpec, return nil } +// Convert_v1beta1_IngressSpec_To_extensions_IngressSpec is an autogenerated conversion function. func Convert_v1beta1_IngressSpec_To_extensions_IngressSpec(in *IngressSpec, out *extensions.IngressSpec, s conversion.Scope) error { return autoConvert_v1beta1_IngressSpec_To_extensions_IngressSpec(in, out, s) } @@ -994,6 +925,7 @@ func autoConvert_extensions_IngressSpec_To_v1beta1_IngressSpec(in *extensions.In return nil } +// Convert_extensions_IngressSpec_To_v1beta1_IngressSpec is an autogenerated conversion function. func Convert_extensions_IngressSpec_To_v1beta1_IngressSpec(in *extensions.IngressSpec, out *IngressSpec, s conversion.Scope) error { return autoConvert_extensions_IngressSpec_To_v1beta1_IngressSpec(in, out, s) } @@ -1006,6 +938,7 @@ func autoConvert_v1beta1_IngressStatus_To_extensions_IngressStatus(in *IngressSt return nil } +// Convert_v1beta1_IngressStatus_To_extensions_IngressStatus is an autogenerated conversion function. func Convert_v1beta1_IngressStatus_To_extensions_IngressStatus(in *IngressStatus, out *extensions.IngressStatus, s conversion.Scope) error { return autoConvert_v1beta1_IngressStatus_To_extensions_IngressStatus(in, out, s) } @@ -1018,6 +951,7 @@ func autoConvert_extensions_IngressStatus_To_v1beta1_IngressStatus(in *extension return nil } +// Convert_extensions_IngressStatus_To_v1beta1_IngressStatus is an autogenerated conversion function. func Convert_extensions_IngressStatus_To_v1beta1_IngressStatus(in *extensions.IngressStatus, out *IngressStatus, s conversion.Scope) error { return autoConvert_extensions_IngressStatus_To_v1beta1_IngressStatus(in, out, s) } @@ -1028,6 +962,7 @@ func autoConvert_v1beta1_IngressTLS_To_extensions_IngressTLS(in *IngressTLS, out return nil } +// Convert_v1beta1_IngressTLS_To_extensions_IngressTLS is an autogenerated conversion function. func Convert_v1beta1_IngressTLS_To_extensions_IngressTLS(in *IngressTLS, out *extensions.IngressTLS, s conversion.Scope) error { return autoConvert_v1beta1_IngressTLS_To_extensions_IngressTLS(in, out, s) } @@ -1038,192 +973,33 @@ func autoConvert_extensions_IngressTLS_To_v1beta1_IngressTLS(in *extensions.Ingr return nil } +// Convert_extensions_IngressTLS_To_v1beta1_IngressTLS is an autogenerated conversion function. func Convert_extensions_IngressTLS_To_v1beta1_IngressTLS(in *extensions.IngressTLS, out *IngressTLS, s conversion.Scope) error { return autoConvert_extensions_IngressTLS_To_v1beta1_IngressTLS(in, out, s) } -func autoConvert_v1beta1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_v1beta1_JobSpec_To_batch_JobSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_v1beta1_JobStatus_To_batch_JobStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_v1beta1_Job_To_batch_Job(in *Job, out *batch.Job, s conversion.Scope) error { - return autoConvert_v1beta1_Job_To_batch_Job(in, out, s) -} - -func autoConvert_batch_Job_To_v1beta1_Job(in *batch.Job, out *Job, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if err := Convert_batch_JobSpec_To_v1beta1_JobSpec(&in.Spec, &out.Spec, s); err != nil { - return err - } - if err := Convert_batch_JobStatus_To_v1beta1_JobStatus(&in.Status, &out.Status, s); err != nil { - return err - } - return nil -} - -func Convert_batch_Job_To_v1beta1_Job(in *batch.Job, out *Job, s conversion.Scope) error { - return autoConvert_batch_Job_To_v1beta1_Job(in, out, s) -} - -func autoConvert_v1beta1_JobCondition_To_batch_JobCondition(in *JobCondition, out *batch.JobCondition, s conversion.Scope) error { - out.Type = batch.JobConditionType(in.Type) - out.Status = api.ConditionStatus(in.Status) - out.LastProbeTime = in.LastProbeTime - out.LastTransitionTime = in.LastTransitionTime - out.Reason = in.Reason - out.Message = in.Message - return nil -} - -func Convert_v1beta1_JobCondition_To_batch_JobCondition(in *JobCondition, out *batch.JobCondition, s conversion.Scope) error { - return autoConvert_v1beta1_JobCondition_To_batch_JobCondition(in, out, s) -} - -func autoConvert_batch_JobCondition_To_v1beta1_JobCondition(in *batch.JobCondition, out *JobCondition, s conversion.Scope) error { - out.Type = JobConditionType(in.Type) - out.Status = v1.ConditionStatus(in.Status) - out.LastProbeTime = in.LastProbeTime - out.LastTransitionTime = in.LastTransitionTime - out.Reason = in.Reason - out.Message = in.Message - return nil -} - -func Convert_batch_JobCondition_To_v1beta1_JobCondition(in *batch.JobCondition, out *JobCondition, s conversion.Scope) error { - return autoConvert_batch_JobCondition_To_v1beta1_JobCondition(in, out, s) -} - -func autoConvert_v1beta1_JobList_To_batch_JobList(in *JobList, out *batch.JobList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]batch.Job, len(*in)) - for i := range *in { - if err := Convert_v1beta1_Job_To_batch_Job(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil -} - -func Convert_v1beta1_JobList_To_batch_JobList(in *JobList, out *batch.JobList, s conversion.Scope) error { - return autoConvert_v1beta1_JobList_To_batch_JobList(in, out, s) -} - -func autoConvert_batch_JobList_To_v1beta1_JobList(in *batch.JobList, out *JobList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Job, len(*in)) - for i := range *in { - if err := Convert_batch_Job_To_v1beta1_Job(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil -} - -func Convert_batch_JobList_To_v1beta1_JobList(in *batch.JobList, out *JobList, s conversion.Scope) error { - return autoConvert_batch_JobList_To_v1beta1_JobList(in, out, s) -} - -func autoConvert_v1beta1_JobSpec_To_batch_JobSpec(in *JobSpec, out *batch.JobSpec, s conversion.Scope) error { - out.Parallelism = (*int32)(unsafe.Pointer(in.Parallelism)) - out.Completions = (*int32)(unsafe.Pointer(in.Completions)) - out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - // WARNING: in.AutoSelector requires manual conversion: does not exist in peer-type - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { - return err - } - return nil -} - -func autoConvert_batch_JobSpec_To_v1beta1_JobSpec(in *batch.JobSpec, out *JobSpec, s conversion.Scope) error { - out.Parallelism = (*int32)(unsafe.Pointer(in.Parallelism)) - out.Completions = (*int32)(unsafe.Pointer(in.Completions)) - out.ActiveDeadlineSeconds = (*int64)(unsafe.Pointer(in.ActiveDeadlineSeconds)) - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - // WARNING: in.ManualSelector requires manual conversion: does not exist in peer-type - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { - return err - } - return nil -} - -func autoConvert_v1beta1_JobStatus_To_batch_JobStatus(in *JobStatus, out *batch.JobStatus, s conversion.Scope) error { - out.Conditions = *(*[]batch.JobCondition)(unsafe.Pointer(&in.Conditions)) - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) - out.CompletionTime = (*unversioned.Time)(unsafe.Pointer(in.CompletionTime)) - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed - return nil -} - -func Convert_v1beta1_JobStatus_To_batch_JobStatus(in *JobStatus, out *batch.JobStatus, s conversion.Scope) error { - return autoConvert_v1beta1_JobStatus_To_batch_JobStatus(in, out, s) -} - -func autoConvert_batch_JobStatus_To_v1beta1_JobStatus(in *batch.JobStatus, out *JobStatus, s conversion.Scope) error { - out.Conditions = *(*[]JobCondition)(unsafe.Pointer(&in.Conditions)) - out.StartTime = (*unversioned.Time)(unsafe.Pointer(in.StartTime)) - out.CompletionTime = (*unversioned.Time)(unsafe.Pointer(in.CompletionTime)) - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed - return nil -} - -func Convert_batch_JobStatus_To_v1beta1_JobStatus(in *batch.JobStatus, out *JobStatus, s conversion.Scope) error { - return autoConvert_batch_JobStatus_To_v1beta1_JobStatus(in, out, s) -} - func autoConvert_v1beta1_NetworkPolicy_To_extensions_NetworkPolicy(in *NetworkPolicy, out *extensions.NetworkPolicy, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_v1beta1_NetworkPolicy_To_extensions_NetworkPolicy is an autogenerated conversion function. func Convert_v1beta1_NetworkPolicy_To_extensions_NetworkPolicy(in *NetworkPolicy, out *extensions.NetworkPolicy, s conversion.Scope) error { return autoConvert_v1beta1_NetworkPolicy_To_extensions_NetworkPolicy(in, out, s) } func autoConvert_extensions_NetworkPolicy_To_v1beta1_NetworkPolicy(in *extensions.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_extensions_NetworkPolicy_To_v1beta1_NetworkPolicy is an autogenerated conversion function. func Convert_extensions_NetworkPolicy_To_v1beta1_NetworkPolicy(in *extensions.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { return autoConvert_extensions_NetworkPolicy_To_v1beta1_NetworkPolicy(in, out, s) } @@ -1234,6 +1010,7 @@ func autoConvert_v1beta1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIng return nil } +// Convert_v1beta1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule is an autogenerated conversion function. func Convert_v1beta1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *extensions.NetworkPolicyIngressRule, s conversion.Scope) error { return autoConvert_v1beta1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(in, out, s) } @@ -1244,6 +1021,7 @@ func autoConvert_extensions_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIng return nil } +// Convert_extensions_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule is an autogenerated conversion function. func Convert_extensions_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(in *extensions.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { return autoConvert_extensions_NetworkPolicyIngressRule_To_v1beta1_NetworkPolicyIngressRule(in, out, s) } @@ -1254,36 +1032,44 @@ func autoConvert_v1beta1_NetworkPolicyList_To_extensions_NetworkPolicyList(in *N return nil } +// Convert_v1beta1_NetworkPolicyList_To_extensions_NetworkPolicyList is an autogenerated conversion function. func Convert_v1beta1_NetworkPolicyList_To_extensions_NetworkPolicyList(in *NetworkPolicyList, out *extensions.NetworkPolicyList, s conversion.Scope) error { return autoConvert_v1beta1_NetworkPolicyList_To_extensions_NetworkPolicyList(in, out, s) } func autoConvert_extensions_NetworkPolicyList_To_v1beta1_NetworkPolicyList(in *extensions.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]NetworkPolicy)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]NetworkPolicy, 0) + } else { + out.Items = *(*[]NetworkPolicy)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_extensions_NetworkPolicyList_To_v1beta1_NetworkPolicyList is an autogenerated conversion function. func Convert_extensions_NetworkPolicyList_To_v1beta1_NetworkPolicyList(in *extensions.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { return autoConvert_extensions_NetworkPolicyList_To_v1beta1_NetworkPolicyList(in, out, s) } func autoConvert_v1beta1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(in *NetworkPolicyPeer, out *extensions.NetworkPolicyPeer, s conversion.Scope) error { - out.PodSelector = (*unversioned.LabelSelector)(unsafe.Pointer(in.PodSelector)) - out.NamespaceSelector = (*unversioned.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + out.PodSelector = (*v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) return nil } +// Convert_v1beta1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer is an autogenerated conversion function. func Convert_v1beta1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(in *NetworkPolicyPeer, out *extensions.NetworkPolicyPeer, s conversion.Scope) error { return autoConvert_v1beta1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(in, out, s) } func autoConvert_extensions_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(in *extensions.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { - out.PodSelector = (*unversioned.LabelSelector)(unsafe.Pointer(in.PodSelector)) - out.NamespaceSelector = (*unversioned.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + out.PodSelector = (*v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) return nil } +// Convert_extensions_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer is an autogenerated conversion function. func Convert_extensions_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(in *extensions.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { return autoConvert_extensions_NetworkPolicyPeer_To_v1beta1_NetworkPolicyPeer(in, out, s) } @@ -1294,16 +1080,18 @@ func autoConvert_v1beta1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(in *N return nil } +// Convert_v1beta1_NetworkPolicyPort_To_extensions_NetworkPolicyPort is an autogenerated conversion function. func Convert_v1beta1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(in *NetworkPolicyPort, out *extensions.NetworkPolicyPort, s conversion.Scope) error { return autoConvert_v1beta1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(in, out, s) } func autoConvert_extensions_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(in *extensions.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { - out.Protocol = (*v1.Protocol)(unsafe.Pointer(in.Protocol)) + out.Protocol = (*api_v1.Protocol)(unsafe.Pointer(in.Protocol)) out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) return nil } +// Convert_extensions_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort is an autogenerated conversion function. func Convert_extensions_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(in *extensions.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { return autoConvert_extensions_NetworkPolicyPort_To_v1beta1_NetworkPolicyPort(in, out, s) } @@ -1314,6 +1102,7 @@ func autoConvert_v1beta1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(in *N return nil } +// Convert_v1beta1_NetworkPolicySpec_To_extensions_NetworkPolicySpec is an autogenerated conversion function. func Convert_v1beta1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(in *NetworkPolicySpec, out *extensions.NetworkPolicySpec, s conversion.Scope) error { return autoConvert_v1beta1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(in, out, s) } @@ -1324,36 +1113,33 @@ func autoConvert_extensions_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(in *e return nil } +// Convert_extensions_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec is an autogenerated conversion function. func Convert_extensions_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(in *extensions.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { return autoConvert_extensions_NetworkPolicySpec_To_v1beta1_NetworkPolicySpec(in, out, s) } func autoConvert_v1beta1_PodSecurityPolicy_To_extensions_PodSecurityPolicy(in *PodSecurityPolicy, out *extensions.PodSecurityPolicy, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_v1beta1_PodSecurityPolicy_To_extensions_PodSecurityPolicy is an autogenerated conversion function. func Convert_v1beta1_PodSecurityPolicy_To_extensions_PodSecurityPolicy(in *PodSecurityPolicy, out *extensions.PodSecurityPolicy, s conversion.Scope) error { return autoConvert_v1beta1_PodSecurityPolicy_To_extensions_PodSecurityPolicy(in, out, s) } func autoConvert_extensions_PodSecurityPolicy_To_v1beta1_PodSecurityPolicy(in *extensions.PodSecurityPolicy, out *PodSecurityPolicy, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySpec(&in.Spec, &out.Spec, s); err != nil { return err } return nil } +// Convert_extensions_PodSecurityPolicy_To_v1beta1_PodSecurityPolicy is an autogenerated conversion function. func Convert_extensions_PodSecurityPolicy_To_v1beta1_PodSecurityPolicy(in *extensions.PodSecurityPolicy, out *PodSecurityPolicy, s conversion.Scope) error { return autoConvert_extensions_PodSecurityPolicy_To_v1beta1_PodSecurityPolicy(in, out, s) } @@ -1374,6 +1160,7 @@ func autoConvert_v1beta1_PodSecurityPolicyList_To_extensions_PodSecurityPolicyLi return nil } +// Convert_v1beta1_PodSecurityPolicyList_To_extensions_PodSecurityPolicyList is an autogenerated conversion function. func Convert_v1beta1_PodSecurityPolicyList_To_extensions_PodSecurityPolicyList(in *PodSecurityPolicyList, out *extensions.PodSecurityPolicyList, s conversion.Scope) error { return autoConvert_v1beta1_PodSecurityPolicyList_To_extensions_PodSecurityPolicyList(in, out, s) } @@ -1389,11 +1176,12 @@ func autoConvert_extensions_PodSecurityPolicyList_To_v1beta1_PodSecurityPolicyLi } } } else { - out.Items = nil + out.Items = make([]PodSecurityPolicy, 0) } return nil } +// Convert_extensions_PodSecurityPolicyList_To_v1beta1_PodSecurityPolicyList is an autogenerated conversion function. func Convert_extensions_PodSecurityPolicyList_To_v1beta1_PodSecurityPolicyList(in *extensions.PodSecurityPolicyList, out *PodSecurityPolicyList, s conversion.Scope) error { return autoConvert_extensions_PodSecurityPolicyList_To_v1beta1_PodSecurityPolicyList(in, out, s) } @@ -1434,15 +1222,16 @@ func autoConvert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySp return nil } +// Convert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySpec is an autogenerated conversion function. func Convert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySpec(in *PodSecurityPolicySpec, out *extensions.PodSecurityPolicySpec, s conversion.Scope) error { return autoConvert_v1beta1_PodSecurityPolicySpec_To_extensions_PodSecurityPolicySpec(in, out, s) } func autoConvert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySpec(in *extensions.PodSecurityPolicySpec, out *PodSecurityPolicySpec, s conversion.Scope) error { out.Privileged = in.Privileged - out.DefaultAddCapabilities = *(*[]v1.Capability)(unsafe.Pointer(&in.DefaultAddCapabilities)) - out.RequiredDropCapabilities = *(*[]v1.Capability)(unsafe.Pointer(&in.RequiredDropCapabilities)) - out.AllowedCapabilities = *(*[]v1.Capability)(unsafe.Pointer(&in.AllowedCapabilities)) + out.DefaultAddCapabilities = *(*[]api_v1.Capability)(unsafe.Pointer(&in.DefaultAddCapabilities)) + out.RequiredDropCapabilities = *(*[]api_v1.Capability)(unsafe.Pointer(&in.RequiredDropCapabilities)) + out.AllowedCapabilities = *(*[]api_v1.Capability)(unsafe.Pointer(&in.AllowedCapabilities)) out.Volumes = *(*[]FSType)(unsafe.Pointer(&in.Volumes)) out.HostNetwork = in.HostNetwork if in.HostPorts != nil { @@ -1474,15 +1263,13 @@ func autoConvert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySp return nil } +// Convert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySpec is an autogenerated conversion function. func Convert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySpec(in *extensions.PodSecurityPolicySpec, out *PodSecurityPolicySpec, s conversion.Scope) error { return autoConvert_extensions_PodSecurityPolicySpec_To_v1beta1_PodSecurityPolicySpec(in, out, s) } func autoConvert_v1beta1_ReplicaSet_To_extensions_ReplicaSet(in *ReplicaSet, out *extensions.ReplicaSet, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -1492,15 +1279,13 @@ func autoConvert_v1beta1_ReplicaSet_To_extensions_ReplicaSet(in *ReplicaSet, out return nil } +// Convert_v1beta1_ReplicaSet_To_extensions_ReplicaSet is an autogenerated conversion function. func Convert_v1beta1_ReplicaSet_To_extensions_ReplicaSet(in *ReplicaSet, out *extensions.ReplicaSet, s conversion.Scope) error { return autoConvert_v1beta1_ReplicaSet_To_extensions_ReplicaSet(in, out, s) } func autoConvert_extensions_ReplicaSet_To_v1beta1_ReplicaSet(in *extensions.ReplicaSet, out *ReplicaSet, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_ReplicaSetSpec_To_v1beta1_ReplicaSetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -1510,6 +1295,7 @@ func autoConvert_extensions_ReplicaSet_To_v1beta1_ReplicaSet(in *extensions.Repl return nil } +// Convert_extensions_ReplicaSet_To_v1beta1_ReplicaSet is an autogenerated conversion function. func Convert_extensions_ReplicaSet_To_v1beta1_ReplicaSet(in *extensions.ReplicaSet, out *ReplicaSet, s conversion.Scope) error { return autoConvert_extensions_ReplicaSet_To_v1beta1_ReplicaSet(in, out, s) } @@ -1523,19 +1309,21 @@ func autoConvert_v1beta1_ReplicaSetCondition_To_extensions_ReplicaSetCondition(i return nil } +// Convert_v1beta1_ReplicaSetCondition_To_extensions_ReplicaSetCondition is an autogenerated conversion function. func Convert_v1beta1_ReplicaSetCondition_To_extensions_ReplicaSetCondition(in *ReplicaSetCondition, out *extensions.ReplicaSetCondition, s conversion.Scope) error { return autoConvert_v1beta1_ReplicaSetCondition_To_extensions_ReplicaSetCondition(in, out, s) } func autoConvert_extensions_ReplicaSetCondition_To_v1beta1_ReplicaSetCondition(in *extensions.ReplicaSetCondition, out *ReplicaSetCondition, s conversion.Scope) error { out.Type = ReplicaSetConditionType(in.Type) - out.Status = v1.ConditionStatus(in.Status) + out.Status = api_v1.ConditionStatus(in.Status) out.LastTransitionTime = in.LastTransitionTime out.Reason = in.Reason out.Message = in.Message return nil } +// Convert_extensions_ReplicaSetCondition_To_v1beta1_ReplicaSetCondition is an autogenerated conversion function. func Convert_extensions_ReplicaSetCondition_To_v1beta1_ReplicaSetCondition(in *extensions.ReplicaSetCondition, out *ReplicaSetCondition, s conversion.Scope) error { return autoConvert_extensions_ReplicaSetCondition_To_v1beta1_ReplicaSetCondition(in, out, s) } @@ -1556,6 +1344,7 @@ func autoConvert_v1beta1_ReplicaSetList_To_extensions_ReplicaSetList(in *Replica return nil } +// Convert_v1beta1_ReplicaSetList_To_extensions_ReplicaSetList is an autogenerated conversion function. func Convert_v1beta1_ReplicaSetList_To_extensions_ReplicaSetList(in *ReplicaSetList, out *extensions.ReplicaSetList, s conversion.Scope) error { return autoConvert_v1beta1_ReplicaSetList_To_extensions_ReplicaSetList(in, out, s) } @@ -1571,34 +1360,35 @@ func autoConvert_extensions_ReplicaSetList_To_v1beta1_ReplicaSetList(in *extensi } } } else { - out.Items = nil + out.Items = make([]ReplicaSet, 0) } return nil } +// Convert_extensions_ReplicaSetList_To_v1beta1_ReplicaSetList is an autogenerated conversion function. func Convert_extensions_ReplicaSetList_To_v1beta1_ReplicaSetList(in *extensions.ReplicaSetList, out *ReplicaSetList, s conversion.Scope) error { return autoConvert_extensions_ReplicaSetList_To_v1beta1_ReplicaSetList(in, out, s) } func autoConvert_v1beta1_ReplicaSetSpec_To_extensions_ReplicaSetSpec(in *ReplicaSetSpec, out *extensions.ReplicaSetSpec, s conversion.Scope) error { - if err := api.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := v1.Convert_Pointer_int32_To_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } out.MinReadySeconds = in.MinReadySeconds - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_v1_PodTemplateSpec_To_api_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } return nil } func autoConvert_extensions_ReplicaSetSpec_To_v1beta1_ReplicaSetSpec(in *extensions.ReplicaSetSpec, out *ReplicaSetSpec, s conversion.Scope) error { - if err := api.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { + if err := v1.Convert_int32_To_Pointer_int32(&in.Replicas, &out.Replicas, s); err != nil { return err } out.MinReadySeconds = in.MinReadySeconds - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) - if err := v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + if err := api_v1.Convert_api_PodTemplateSpec_To_v1_PodTemplateSpec(&in.Template, &out.Template, s); err != nil { return err } return nil @@ -1614,6 +1404,7 @@ func autoConvert_v1beta1_ReplicaSetStatus_To_extensions_ReplicaSetStatus(in *Rep return nil } +// Convert_v1beta1_ReplicaSetStatus_To_extensions_ReplicaSetStatus is an autogenerated conversion function. func Convert_v1beta1_ReplicaSetStatus_To_extensions_ReplicaSetStatus(in *ReplicaSetStatus, out *extensions.ReplicaSetStatus, s conversion.Scope) error { return autoConvert_v1beta1_ReplicaSetStatus_To_extensions_ReplicaSetStatus(in, out, s) } @@ -1628,6 +1419,7 @@ func autoConvert_extensions_ReplicaSetStatus_To_v1beta1_ReplicaSetStatus(in *ext return nil } +// Convert_extensions_ReplicaSetStatus_To_v1beta1_ReplicaSetStatus is an autogenerated conversion function. func Convert_extensions_ReplicaSetStatus_To_v1beta1_ReplicaSetStatus(in *extensions.ReplicaSetStatus, out *ReplicaSetStatus, s conversion.Scope) error { return autoConvert_extensions_ReplicaSetStatus_To_v1beta1_ReplicaSetStatus(in, out, s) } @@ -1636,6 +1428,7 @@ func autoConvert_v1beta1_ReplicationControllerDummy_To_extensions_ReplicationCon return nil } +// Convert_v1beta1_ReplicationControllerDummy_To_extensions_ReplicationControllerDummy is an autogenerated conversion function. func Convert_v1beta1_ReplicationControllerDummy_To_extensions_ReplicationControllerDummy(in *ReplicationControllerDummy, out *extensions.ReplicationControllerDummy, s conversion.Scope) error { return autoConvert_v1beta1_ReplicationControllerDummy_To_extensions_ReplicationControllerDummy(in, out, s) } @@ -1644,6 +1437,7 @@ func autoConvert_extensions_ReplicationControllerDummy_To_v1beta1_ReplicationCon return nil } +// Convert_extensions_ReplicationControllerDummy_To_v1beta1_ReplicationControllerDummy is an autogenerated conversion function. func Convert_extensions_ReplicationControllerDummy_To_v1beta1_ReplicationControllerDummy(in *extensions.ReplicationControllerDummy, out *ReplicationControllerDummy, s conversion.Scope) error { return autoConvert_extensions_ReplicationControllerDummy_To_v1beta1_ReplicationControllerDummy(in, out, s) } @@ -1653,6 +1447,7 @@ func autoConvert_v1beta1_RollbackConfig_To_extensions_RollbackConfig(in *Rollbac return nil } +// Convert_v1beta1_RollbackConfig_To_extensions_RollbackConfig is an autogenerated conversion function. func Convert_v1beta1_RollbackConfig_To_extensions_RollbackConfig(in *RollbackConfig, out *extensions.RollbackConfig, s conversion.Scope) error { return autoConvert_v1beta1_RollbackConfig_To_extensions_RollbackConfig(in, out, s) } @@ -1662,28 +1457,40 @@ func autoConvert_extensions_RollbackConfig_To_v1beta1_RollbackConfig(in *extensi return nil } +// Convert_extensions_RollbackConfig_To_v1beta1_RollbackConfig is an autogenerated conversion function. func Convert_extensions_RollbackConfig_To_v1beta1_RollbackConfig(in *extensions.RollbackConfig, out *RollbackConfig, s conversion.Scope) error { return autoConvert_extensions_RollbackConfig_To_v1beta1_RollbackConfig(in, out, s) } +func autoConvert_v1beta1_RollingUpdateDaemonSet_To_extensions_RollingUpdateDaemonSet(in *RollingUpdateDaemonSet, out *extensions.RollingUpdateDaemonSet, s conversion.Scope) error { + // WARNING: in.MaxUnavailable requires manual conversion: inconvertible types (*k8s.io/apimachinery/pkg/util/intstr.IntOrString vs k8s.io/apimachinery/pkg/util/intstr.IntOrString) + return nil +} + +func autoConvert_extensions_RollingUpdateDaemonSet_To_v1beta1_RollingUpdateDaemonSet(in *extensions.RollingUpdateDaemonSet, out *RollingUpdateDaemonSet, s conversion.Scope) error { + // WARNING: in.MaxUnavailable requires manual conversion: inconvertible types (k8s.io/apimachinery/pkg/util/intstr.IntOrString vs *k8s.io/apimachinery/pkg/util/intstr.IntOrString) + return nil +} + func autoConvert_v1beta1_RollingUpdateDeployment_To_extensions_RollingUpdateDeployment(in *RollingUpdateDeployment, out *extensions.RollingUpdateDeployment, s conversion.Scope) error { - // WARNING: in.MaxUnavailable requires manual conversion: inconvertible types (*k8s.io/kubernetes/pkg/util/intstr.IntOrString vs k8s.io/kubernetes/pkg/util/intstr.IntOrString) - // WARNING: in.MaxSurge requires manual conversion: inconvertible types (*k8s.io/kubernetes/pkg/util/intstr.IntOrString vs k8s.io/kubernetes/pkg/util/intstr.IntOrString) + // WARNING: in.MaxUnavailable requires manual conversion: inconvertible types (*k8s.io/apimachinery/pkg/util/intstr.IntOrString vs k8s.io/apimachinery/pkg/util/intstr.IntOrString) + // WARNING: in.MaxSurge requires manual conversion: inconvertible types (*k8s.io/apimachinery/pkg/util/intstr.IntOrString vs k8s.io/apimachinery/pkg/util/intstr.IntOrString) return nil } func autoConvert_extensions_RollingUpdateDeployment_To_v1beta1_RollingUpdateDeployment(in *extensions.RollingUpdateDeployment, out *RollingUpdateDeployment, s conversion.Scope) error { - // WARNING: in.MaxUnavailable requires manual conversion: inconvertible types (k8s.io/kubernetes/pkg/util/intstr.IntOrString vs *k8s.io/kubernetes/pkg/util/intstr.IntOrString) - // WARNING: in.MaxSurge requires manual conversion: inconvertible types (k8s.io/kubernetes/pkg/util/intstr.IntOrString vs *k8s.io/kubernetes/pkg/util/intstr.IntOrString) + // WARNING: in.MaxUnavailable requires manual conversion: inconvertible types (k8s.io/apimachinery/pkg/util/intstr.IntOrString vs *k8s.io/apimachinery/pkg/util/intstr.IntOrString) + // WARNING: in.MaxSurge requires manual conversion: inconvertible types (k8s.io/apimachinery/pkg/util/intstr.IntOrString vs *k8s.io/apimachinery/pkg/util/intstr.IntOrString) return nil } func autoConvert_v1beta1_RunAsUserStrategyOptions_To_extensions_RunAsUserStrategyOptions(in *RunAsUserStrategyOptions, out *extensions.RunAsUserStrategyOptions, s conversion.Scope) error { out.Rule = extensions.RunAsUserStrategy(in.Rule) - out.Ranges = *(*[]extensions.IDRange)(unsafe.Pointer(&in.Ranges)) + out.Ranges = *(*[]extensions.UserIDRange)(unsafe.Pointer(&in.Ranges)) return nil } +// Convert_v1beta1_RunAsUserStrategyOptions_To_extensions_RunAsUserStrategyOptions is an autogenerated conversion function. func Convert_v1beta1_RunAsUserStrategyOptions_To_extensions_RunAsUserStrategyOptions(in *RunAsUserStrategyOptions, out *extensions.RunAsUserStrategyOptions, s conversion.Scope) error { return autoConvert_v1beta1_RunAsUserStrategyOptions_To_extensions_RunAsUserStrategyOptions(in, out, s) } @@ -1694,6 +1501,7 @@ func autoConvert_extensions_RunAsUserStrategyOptions_To_v1beta1_RunAsUserStrateg return nil } +// Convert_extensions_RunAsUserStrategyOptions_To_v1beta1_RunAsUserStrategyOptions is an autogenerated conversion function. func Convert_extensions_RunAsUserStrategyOptions_To_v1beta1_RunAsUserStrategyOptions(in *extensions.RunAsUserStrategyOptions, out *RunAsUserStrategyOptions, s conversion.Scope) error { return autoConvert_extensions_RunAsUserStrategyOptions_To_v1beta1_RunAsUserStrategyOptions(in, out, s) } @@ -1704,25 +1512,24 @@ func autoConvert_v1beta1_SELinuxStrategyOptions_To_extensions_SELinuxStrategyOpt return nil } +// Convert_v1beta1_SELinuxStrategyOptions_To_extensions_SELinuxStrategyOptions is an autogenerated conversion function. func Convert_v1beta1_SELinuxStrategyOptions_To_extensions_SELinuxStrategyOptions(in *SELinuxStrategyOptions, out *extensions.SELinuxStrategyOptions, s conversion.Scope) error { return autoConvert_v1beta1_SELinuxStrategyOptions_To_extensions_SELinuxStrategyOptions(in, out, s) } func autoConvert_extensions_SELinuxStrategyOptions_To_v1beta1_SELinuxStrategyOptions(in *extensions.SELinuxStrategyOptions, out *SELinuxStrategyOptions, s conversion.Scope) error { out.Rule = SELinuxStrategy(in.Rule) - out.SELinuxOptions = (*v1.SELinuxOptions)(unsafe.Pointer(in.SELinuxOptions)) + out.SELinuxOptions = (*api_v1.SELinuxOptions)(unsafe.Pointer(in.SELinuxOptions)) return nil } +// Convert_extensions_SELinuxStrategyOptions_To_v1beta1_SELinuxStrategyOptions is an autogenerated conversion function. func Convert_extensions_SELinuxStrategyOptions_To_v1beta1_SELinuxStrategyOptions(in *extensions.SELinuxStrategyOptions, out *SELinuxStrategyOptions, s conversion.Scope) error { return autoConvert_extensions_SELinuxStrategyOptions_To_v1beta1_SELinuxStrategyOptions(in, out, s) } func autoConvert_v1beta1_Scale_To_extensions_Scale(in *Scale, out *extensions.Scale, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_ScaleSpec_To_extensions_ScaleSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -1732,15 +1539,13 @@ func autoConvert_v1beta1_Scale_To_extensions_Scale(in *Scale, out *extensions.Sc return nil } +// Convert_v1beta1_Scale_To_extensions_Scale is an autogenerated conversion function. func Convert_v1beta1_Scale_To_extensions_Scale(in *Scale, out *extensions.Scale, s conversion.Scope) error { return autoConvert_v1beta1_Scale_To_extensions_Scale(in, out, s) } func autoConvert_extensions_Scale_To_v1beta1_Scale(in *extensions.Scale, out *Scale, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_extensions_ScaleSpec_To_v1beta1_ScaleSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -1750,6 +1555,7 @@ func autoConvert_extensions_Scale_To_v1beta1_Scale(in *extensions.Scale, out *Sc return nil } +// Convert_extensions_Scale_To_v1beta1_Scale is an autogenerated conversion function. func Convert_extensions_Scale_To_v1beta1_Scale(in *extensions.Scale, out *Scale, s conversion.Scope) error { return autoConvert_extensions_Scale_To_v1beta1_Scale(in, out, s) } @@ -1759,6 +1565,7 @@ func autoConvert_v1beta1_ScaleSpec_To_extensions_ScaleSpec(in *ScaleSpec, out *e return nil } +// Convert_v1beta1_ScaleSpec_To_extensions_ScaleSpec is an autogenerated conversion function. func Convert_v1beta1_ScaleSpec_To_extensions_ScaleSpec(in *ScaleSpec, out *extensions.ScaleSpec, s conversion.Scope) error { return autoConvert_v1beta1_ScaleSpec_To_extensions_ScaleSpec(in, out, s) } @@ -1768,29 +1575,31 @@ func autoConvert_extensions_ScaleSpec_To_v1beta1_ScaleSpec(in *extensions.ScaleS return nil } +// Convert_extensions_ScaleSpec_To_v1beta1_ScaleSpec is an autogenerated conversion function. func Convert_extensions_ScaleSpec_To_v1beta1_ScaleSpec(in *extensions.ScaleSpec, out *ScaleSpec, s conversion.Scope) error { return autoConvert_extensions_ScaleSpec_To_v1beta1_ScaleSpec(in, out, s) } func autoConvert_v1beta1_ScaleStatus_To_extensions_ScaleStatus(in *ScaleStatus, out *extensions.ScaleStatus, s conversion.Scope) error { out.Replicas = in.Replicas - // WARNING: in.Selector requires manual conversion: inconvertible types (map[string]string vs *k8s.io/kubernetes/pkg/api/unversioned.LabelSelector) + // WARNING: in.Selector requires manual conversion: inconvertible types (map[string]string vs *k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector) // WARNING: in.TargetSelector requires manual conversion: does not exist in peer-type return nil } func autoConvert_extensions_ScaleStatus_To_v1beta1_ScaleStatus(in *extensions.ScaleStatus, out *ScaleStatus, s conversion.Scope) error { out.Replicas = in.Replicas - // WARNING: in.Selector requires manual conversion: inconvertible types (*k8s.io/kubernetes/pkg/api/unversioned.LabelSelector vs map[string]string) + // WARNING: in.Selector requires manual conversion: inconvertible types (*k8s.io/apimachinery/pkg/apis/meta/v1.LabelSelector vs map[string]string) return nil } func autoConvert_v1beta1_SupplementalGroupsStrategyOptions_To_extensions_SupplementalGroupsStrategyOptions(in *SupplementalGroupsStrategyOptions, out *extensions.SupplementalGroupsStrategyOptions, s conversion.Scope) error { out.Rule = extensions.SupplementalGroupsStrategyType(in.Rule) - out.Ranges = *(*[]extensions.IDRange)(unsafe.Pointer(&in.Ranges)) + out.Ranges = *(*[]extensions.GroupIDRange)(unsafe.Pointer(&in.Ranges)) return nil } +// Convert_v1beta1_SupplementalGroupsStrategyOptions_To_extensions_SupplementalGroupsStrategyOptions is an autogenerated conversion function. func Convert_v1beta1_SupplementalGroupsStrategyOptions_To_extensions_SupplementalGroupsStrategyOptions(in *SupplementalGroupsStrategyOptions, out *extensions.SupplementalGroupsStrategyOptions, s conversion.Scope) error { return autoConvert_v1beta1_SupplementalGroupsStrategyOptions_To_extensions_SupplementalGroupsStrategyOptions(in, out, s) } @@ -1801,60 +1610,53 @@ func autoConvert_extensions_SupplementalGroupsStrategyOptions_To_v1beta1_Supplem return nil } +// Convert_extensions_SupplementalGroupsStrategyOptions_To_v1beta1_SupplementalGroupsStrategyOptions is an autogenerated conversion function. func Convert_extensions_SupplementalGroupsStrategyOptions_To_v1beta1_SupplementalGroupsStrategyOptions(in *extensions.SupplementalGroupsStrategyOptions, out *SupplementalGroupsStrategyOptions, s conversion.Scope) error { return autoConvert_extensions_SupplementalGroupsStrategyOptions_To_v1beta1_SupplementalGroupsStrategyOptions(in, out, s) } func autoConvert_v1beta1_ThirdPartyResource_To_extensions_ThirdPartyResource(in *ThirdPartyResource, out *extensions.ThirdPartyResource, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Description = in.Description out.Versions = *(*[]extensions.APIVersion)(unsafe.Pointer(&in.Versions)) return nil } +// Convert_v1beta1_ThirdPartyResource_To_extensions_ThirdPartyResource is an autogenerated conversion function. func Convert_v1beta1_ThirdPartyResource_To_extensions_ThirdPartyResource(in *ThirdPartyResource, out *extensions.ThirdPartyResource, s conversion.Scope) error { return autoConvert_v1beta1_ThirdPartyResource_To_extensions_ThirdPartyResource(in, out, s) } func autoConvert_extensions_ThirdPartyResource_To_v1beta1_ThirdPartyResource(in *extensions.ThirdPartyResource, out *ThirdPartyResource, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Description = in.Description out.Versions = *(*[]APIVersion)(unsafe.Pointer(&in.Versions)) return nil } +// Convert_extensions_ThirdPartyResource_To_v1beta1_ThirdPartyResource is an autogenerated conversion function. func Convert_extensions_ThirdPartyResource_To_v1beta1_ThirdPartyResource(in *extensions.ThirdPartyResource, out *ThirdPartyResource, s conversion.Scope) error { return autoConvert_extensions_ThirdPartyResource_To_v1beta1_ThirdPartyResource(in, out, s) } func autoConvert_v1beta1_ThirdPartyResourceData_To_extensions_ThirdPartyResourceData(in *ThirdPartyResourceData, out *extensions.ThirdPartyResourceData, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Data = *(*[]byte)(unsafe.Pointer(&in.Data)) return nil } +// Convert_v1beta1_ThirdPartyResourceData_To_extensions_ThirdPartyResourceData is an autogenerated conversion function. func Convert_v1beta1_ThirdPartyResourceData_To_extensions_ThirdPartyResourceData(in *ThirdPartyResourceData, out *extensions.ThirdPartyResourceData, s conversion.Scope) error { return autoConvert_v1beta1_ThirdPartyResourceData_To_extensions_ThirdPartyResourceData(in, out, s) } func autoConvert_extensions_ThirdPartyResourceData_To_v1beta1_ThirdPartyResourceData(in *extensions.ThirdPartyResourceData, out *ThirdPartyResourceData, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Data = *(*[]byte)(unsafe.Pointer(&in.Data)) return nil } +// Convert_extensions_ThirdPartyResourceData_To_v1beta1_ThirdPartyResourceData is an autogenerated conversion function. func Convert_extensions_ThirdPartyResourceData_To_v1beta1_ThirdPartyResourceData(in *extensions.ThirdPartyResourceData, out *ThirdPartyResourceData, s conversion.Scope) error { return autoConvert_extensions_ThirdPartyResourceData_To_v1beta1_ThirdPartyResourceData(in, out, s) } @@ -1865,16 +1667,22 @@ func autoConvert_v1beta1_ThirdPartyResourceDataList_To_extensions_ThirdPartyReso return nil } +// Convert_v1beta1_ThirdPartyResourceDataList_To_extensions_ThirdPartyResourceDataList is an autogenerated conversion function. func Convert_v1beta1_ThirdPartyResourceDataList_To_extensions_ThirdPartyResourceDataList(in *ThirdPartyResourceDataList, out *extensions.ThirdPartyResourceDataList, s conversion.Scope) error { return autoConvert_v1beta1_ThirdPartyResourceDataList_To_extensions_ThirdPartyResourceDataList(in, out, s) } func autoConvert_extensions_ThirdPartyResourceDataList_To_v1beta1_ThirdPartyResourceDataList(in *extensions.ThirdPartyResourceDataList, out *ThirdPartyResourceDataList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]ThirdPartyResourceData)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]ThirdPartyResourceData, 0) + } else { + out.Items = *(*[]ThirdPartyResourceData)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_extensions_ThirdPartyResourceDataList_To_v1beta1_ThirdPartyResourceDataList is an autogenerated conversion function. func Convert_extensions_ThirdPartyResourceDataList_To_v1beta1_ThirdPartyResourceDataList(in *extensions.ThirdPartyResourceDataList, out *ThirdPartyResourceDataList, s conversion.Scope) error { return autoConvert_extensions_ThirdPartyResourceDataList_To_v1beta1_ThirdPartyResourceDataList(in, out, s) } @@ -1885,16 +1693,22 @@ func autoConvert_v1beta1_ThirdPartyResourceList_To_extensions_ThirdPartyResource return nil } +// Convert_v1beta1_ThirdPartyResourceList_To_extensions_ThirdPartyResourceList is an autogenerated conversion function. func Convert_v1beta1_ThirdPartyResourceList_To_extensions_ThirdPartyResourceList(in *ThirdPartyResourceList, out *extensions.ThirdPartyResourceList, s conversion.Scope) error { return autoConvert_v1beta1_ThirdPartyResourceList_To_extensions_ThirdPartyResourceList(in, out, s) } func autoConvert_extensions_ThirdPartyResourceList_To_v1beta1_ThirdPartyResourceList(in *extensions.ThirdPartyResourceList, out *ThirdPartyResourceList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]ThirdPartyResource)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]ThirdPartyResource, 0) + } else { + out.Items = *(*[]ThirdPartyResource)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_extensions_ThirdPartyResourceList_To_v1beta1_ThirdPartyResourceList is an autogenerated conversion function. func Convert_extensions_ThirdPartyResourceList_To_v1beta1_ThirdPartyResourceList(in *extensions.ThirdPartyResourceList, out *ThirdPartyResourceList, s conversion.Scope) error { return autoConvert_extensions_ThirdPartyResourceList_To_v1beta1_ThirdPartyResourceList(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go index c7f858fadb..e6d3c55261 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,11 +21,11 @@ limitations under the License. package v1beta1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - intstr "k8s.io/client-go/pkg/util/intstr" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api_v1 "k8s.io/client-go/pkg/api/v1" reflect "reflect" ) @@ -38,7 +38,6 @@ func init() { func RegisterDeepCopies(scheme *runtime.Scheme) error { return scheme.AddGeneratedDeepCopyFuncs( conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_APIVersion, InType: reflect.TypeOf(&APIVersion{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CPUTargetUtilization, InType: reflect.TypeOf(&CPUTargetUtilization{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomMetricCurrentStatus, InType: reflect.TypeOf(&CustomMetricCurrentStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomMetricCurrentStatusList, InType: reflect.TypeOf(&CustomMetricCurrentStatusList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_CustomMetricTarget, InType: reflect.TypeOf(&CustomMetricTarget{})}, @@ -47,6 +46,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DaemonSetList, InType: reflect.TypeOf(&DaemonSetList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DaemonSetSpec, InType: reflect.TypeOf(&DaemonSetSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DaemonSetStatus, InType: reflect.TypeOf(&DaemonSetStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DaemonSetUpdateStrategy, InType: reflect.TypeOf(&DaemonSetUpdateStrategy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Deployment, InType: reflect.TypeOf(&Deployment{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentCondition, InType: reflect.TypeOf(&DeploymentCondition{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentList, InType: reflect.TypeOf(&DeploymentList{})}, @@ -54,14 +54,9 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentSpec, InType: reflect.TypeOf(&DeploymentSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentStatus, InType: reflect.TypeOf(&DeploymentStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_DeploymentStrategy, InType: reflect.TypeOf(&DeploymentStrategy{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ExportOptions, InType: reflect.TypeOf(&ExportOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_FSGroupStrategyOptions, InType: reflect.TypeOf(&FSGroupStrategyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HTTPIngressPath, InType: reflect.TypeOf(&HTTPIngressPath{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HTTPIngressRuleValue, InType: reflect.TypeOf(&HTTPIngressRuleValue{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HorizontalPodAutoscaler, InType: reflect.TypeOf(&HorizontalPodAutoscaler{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HorizontalPodAutoscalerList, InType: reflect.TypeOf(&HorizontalPodAutoscalerList{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HorizontalPodAutoscalerSpec, InType: reflect.TypeOf(&HorizontalPodAutoscalerSpec{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HorizontalPodAutoscalerStatus, InType: reflect.TypeOf(&HorizontalPodAutoscalerStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_HostPortRange, InType: reflect.TypeOf(&HostPortRange{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_IDRange, InType: reflect.TypeOf(&IDRange{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Ingress, InType: reflect.TypeOf(&Ingress{})}, @@ -72,11 +67,6 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_IngressSpec, InType: reflect.TypeOf(&IngressSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_IngressStatus, InType: reflect.TypeOf(&IngressStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_IngressTLS, InType: reflect.TypeOf(&IngressTLS{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Job, InType: reflect.TypeOf(&Job{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_JobCondition, InType: reflect.TypeOf(&JobCondition{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_JobList, InType: reflect.TypeOf(&JobList{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_JobSpec, InType: reflect.TypeOf(&JobSpec{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_JobStatus, InType: reflect.TypeOf(&JobStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, @@ -93,13 +83,13 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ReplicaSetStatus, InType: reflect.TypeOf(&ReplicaSetStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ReplicationControllerDummy, InType: reflect.TypeOf(&ReplicationControllerDummy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RollbackConfig, InType: reflect.TypeOf(&RollbackConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RollingUpdateDaemonSet, InType: reflect.TypeOf(&RollingUpdateDaemonSet{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RollingUpdateDeployment, InType: reflect.TypeOf(&RollingUpdateDeployment{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RunAsUserStrategyOptions, InType: reflect.TypeOf(&RunAsUserStrategyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_SELinuxStrategyOptions, InType: reflect.TypeOf(&SELinuxStrategyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Scale, InType: reflect.TypeOf(&Scale{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ScaleSpec, InType: reflect.TypeOf(&ScaleSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ScaleStatus, InType: reflect.TypeOf(&ScaleStatus{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_SubresourceReference, InType: reflect.TypeOf(&SubresourceReference{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_SupplementalGroupsStrategyOptions, InType: reflect.TypeOf(&SupplementalGroupsStrategyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ThirdPartyResource, InType: reflect.TypeOf(&ThirdPartyResource{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ThirdPartyResourceData, InType: reflect.TypeOf(&ThirdPartyResourceData{})}, @@ -108,38 +98,33 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_APIVersion is an autogenerated deepcopy function. func DeepCopy_v1beta1_APIVersion(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*APIVersion) out := out.(*APIVersion) - out.Name = in.Name - return nil - } -} - -func DeepCopy_v1beta1_CPUTargetUtilization(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*CPUTargetUtilization) - out := out.(*CPUTargetUtilization) - out.TargetPercentage = in.TargetPercentage + *out = *in return nil } } +// DeepCopy_v1beta1_CustomMetricCurrentStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_CustomMetricCurrentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricCurrentStatus) out := out.(*CustomMetricCurrentStatus) - out.Name = in.Name + *out = *in out.CurrentValue = in.CurrentValue.DeepCopy() return nil } } +// DeepCopy_v1beta1_CustomMetricCurrentStatusList is an autogenerated deepcopy function. func DeepCopy_v1beta1_CustomMetricCurrentStatusList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricCurrentStatusList) out := out.(*CustomMetricCurrentStatusList) + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CustomMetricCurrentStatus, len(*in)) @@ -148,27 +133,28 @@ func DeepCopy_v1beta1_CustomMetricCurrentStatusList(in interface{}, out interfac return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_CustomMetricTarget is an autogenerated deepcopy function. func DeepCopy_v1beta1_CustomMetricTarget(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricTarget) out := out.(*CustomMetricTarget) - out.Name = in.Name + *out = *in out.TargetValue = in.TargetValue.DeepCopy() return nil } } +// DeepCopy_v1beta1_CustomMetricTargetList is an autogenerated deepcopy function. func DeepCopy_v1beta1_CustomMetricTargetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricTargetList) out := out.(*CustomMetricTargetList) + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CustomMetricTarget, len(*in)) @@ -177,35 +163,38 @@ func DeepCopy_v1beta1_CustomMetricTargetList(in interface{}, out interface{}, c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_DaemonSet is an autogenerated deepcopy function. func DeepCopy_v1beta1_DaemonSet(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSet) out := out.(*DaemonSet) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_DaemonSetSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status + if err := DeepCopy_v1beta1_DaemonSetStatus(&in.Status, &out.Status, c); err != nil { + return err + } return nil } } +// DeepCopy_v1beta1_DaemonSetList is an autogenerated deepcopy function. func DeepCopy_v1beta1_DaemonSetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSetList) out := out.(*DaemonSetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]DaemonSet, len(*in)) @@ -214,52 +203,82 @@ func DeepCopy_v1beta1_DaemonSetList(in interface{}, out interface{}, c *conversi return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_DaemonSetSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_DaemonSetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSetSpec) out := out.(*DaemonSetSpec) + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } - if err := v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { + if err := api_v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { + return err + } + if err := DeepCopy_v1beta1_DaemonSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, c); err != nil { return err } + if in.RevisionHistoryLimit != nil { + in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit + *out = new(int32) + **out = **in + } return nil } } +// DeepCopy_v1beta1_DaemonSetStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_DaemonSetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSetStatus) out := out.(*DaemonSetStatus) - out.CurrentNumberScheduled = in.CurrentNumberScheduled - out.NumberMisscheduled = in.NumberMisscheduled - out.DesiredNumberScheduled = in.DesiredNumberScheduled - out.NumberReady = in.NumberReady + *out = *in + if in.CollisionCount != nil { + in, out := &in.CollisionCount, &out.CollisionCount + *out = new(int64) + **out = **in + } return nil } } +// DeepCopy_v1beta1_DaemonSetUpdateStrategy is an autogenerated deepcopy function. +func DeepCopy_v1beta1_DaemonSetUpdateStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DaemonSetUpdateStrategy) + out := out.(*DaemonSetUpdateStrategy) + *out = *in + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateDaemonSet) + if err := DeepCopy_v1beta1_RollingUpdateDaemonSet(*in, *out, c); err != nil { + return err + } + } + return nil + } +} + +// DeepCopy_v1beta1_Deployment is an autogenerated deepcopy function. func DeepCopy_v1beta1_Deployment(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Deployment) out := out.(*Deployment) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_DeploymentSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -271,26 +290,24 @@ func DeepCopy_v1beta1_Deployment(in interface{}, out interface{}, c *conversion. } } +// DeepCopy_v1beta1_DeploymentCondition is an autogenerated deepcopy function. func DeepCopy_v1beta1_DeploymentCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentCondition) out := out.(*DeploymentCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastUpdateTime = in.LastUpdateTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1beta1_DeploymentList is an autogenerated deepcopy function. func DeepCopy_v1beta1_DeploymentList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentList) out := out.(*DeploymentList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Deployment, len(*in)) @@ -299,95 +316,78 @@ func DeepCopy_v1beta1_DeploymentList(in interface{}, out interface{}, c *convers return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_DeploymentRollback is an autogenerated deepcopy function. func DeepCopy_v1beta1_DeploymentRollback(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentRollback) out := out.(*DeploymentRollback) - out.TypeMeta = in.TypeMeta - out.Name = in.Name + *out = *in if in.UpdatedAnnotations != nil { in, out := &in.UpdatedAnnotations, &out.UpdatedAnnotations *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.UpdatedAnnotations = nil } - out.RollbackTo = in.RollbackTo return nil } } +// DeepCopy_v1beta1_DeploymentSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_DeploymentSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentSpec) out := out.(*DeploymentSpec) + *out = *in if in.Replicas != nil { in, out := &in.Replicas, &out.Replicas *out = new(int32) **out = **in - } else { - out.Replicas = nil } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } - if err := v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { + if err := api_v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err } if err := DeepCopy_v1beta1_DeploymentStrategy(&in.Strategy, &out.Strategy, c); err != nil { return err } - out.MinReadySeconds = in.MinReadySeconds if in.RevisionHistoryLimit != nil { in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit *out = new(int32) **out = **in - } else { - out.RevisionHistoryLimit = nil } - out.Paused = in.Paused if in.RollbackTo != nil { in, out := &in.RollbackTo, &out.RollbackTo *out = new(RollbackConfig) **out = **in - } else { - out.RollbackTo = nil } if in.ProgressDeadlineSeconds != nil { in, out := &in.ProgressDeadlineSeconds, &out.ProgressDeadlineSeconds *out = new(int32) **out = **in - } else { - out.ProgressDeadlineSeconds = nil } return nil } } +// DeepCopy_v1beta1_DeploymentStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_DeploymentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentStatus) out := out.(*DeploymentStatus) - out.ObservedGeneration = in.ObservedGeneration - out.Replicas = in.Replicas - out.UpdatedReplicas = in.UpdatedReplicas - out.AvailableReplicas = in.AvailableReplicas - out.UnavailableReplicas = in.UnavailableReplicas + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]DeploymentCondition, len(*in)) @@ -396,208 +396,103 @@ func DeepCopy_v1beta1_DeploymentStatus(in interface{}, out interface{}, c *conve return err } } - } else { - out.Conditions = nil + } + if in.CollisionCount != nil { + in, out := &in.CollisionCount, &out.CollisionCount + *out = new(int64) + **out = **in } return nil } } +// DeepCopy_v1beta1_DeploymentStrategy is an autogenerated deepcopy function. func DeepCopy_v1beta1_DeploymentStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentStrategy) out := out.(*DeploymentStrategy) - out.Type = in.Type + *out = *in if in.RollingUpdate != nil { in, out := &in.RollingUpdate, &out.RollingUpdate *out = new(RollingUpdateDeployment) if err := DeepCopy_v1beta1_RollingUpdateDeployment(*in, *out, c); err != nil { return err } - } else { - out.RollingUpdate = nil } return nil } } -func DeepCopy_v1beta1_ExportOptions(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*ExportOptions) - out := out.(*ExportOptions) - out.TypeMeta = in.TypeMeta - out.Export = in.Export - out.Exact = in.Exact - return nil - } -} - +// DeepCopy_v1beta1_FSGroupStrategyOptions is an autogenerated deepcopy function. func DeepCopy_v1beta1_FSGroupStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FSGroupStrategyOptions) out := out.(*FSGroupStrategyOptions) - out.Rule = in.Rule + *out = *in if in.Ranges != nil { in, out := &in.Ranges, &out.Ranges *out = make([]IDRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ranges = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1beta1_HTTPIngressPath is an autogenerated deepcopy function. func DeepCopy_v1beta1_HTTPIngressPath(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPIngressPath) out := out.(*HTTPIngressPath) - out.Path = in.Path - out.Backend = in.Backend + *out = *in return nil } } +// DeepCopy_v1beta1_HTTPIngressRuleValue is an autogenerated deepcopy function. func DeepCopy_v1beta1_HTTPIngressRuleValue(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPIngressRuleValue) out := out.(*HTTPIngressRuleValue) + *out = *in if in.Paths != nil { in, out := &in.Paths, &out.Paths *out = make([]HTTPIngressPath, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Paths = nil - } - return nil - } -} - -func DeepCopy_v1beta1_HorizontalPodAutoscaler(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*HorizontalPodAutoscaler) - out := out.(*HorizontalPodAutoscaler) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { - return err - } - if err := DeepCopy_v1beta1_HorizontalPodAutoscalerSpec(&in.Spec, &out.Spec, c); err != nil { - return err - } - if err := DeepCopy_v1beta1_HorizontalPodAutoscalerStatus(&in.Status, &out.Status, c); err != nil { - return err - } - return nil - } -} - -func DeepCopy_v1beta1_HorizontalPodAutoscalerList(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*HorizontalPodAutoscalerList) - out := out.(*HorizontalPodAutoscalerList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]HorizontalPodAutoscaler, len(*in)) - for i := range *in { - if err := DeepCopy_v1beta1_HorizontalPodAutoscaler(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil - } -} - -func DeepCopy_v1beta1_HorizontalPodAutoscalerSpec(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*HorizontalPodAutoscalerSpec) - out := out.(*HorizontalPodAutoscalerSpec) - out.ScaleRef = in.ScaleRef - if in.MinReplicas != nil { - in, out := &in.MinReplicas, &out.MinReplicas - *out = new(int32) - **out = **in - } else { - out.MinReplicas = nil - } - out.MaxReplicas = in.MaxReplicas - if in.CPUUtilization != nil { - in, out := &in.CPUUtilization, &out.CPUUtilization - *out = new(CPUTargetUtilization) - **out = **in - } else { - out.CPUUtilization = nil - } - return nil - } -} - -func DeepCopy_v1beta1_HorizontalPodAutoscalerStatus(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*HorizontalPodAutoscalerStatus) - out := out.(*HorizontalPodAutoscalerStatus) - if in.ObservedGeneration != nil { - in, out := &in.ObservedGeneration, &out.ObservedGeneration - *out = new(int64) - **out = **in - } else { - out.ObservedGeneration = nil - } - if in.LastScaleTime != nil { - in, out := &in.LastScaleTime, &out.LastScaleTime - *out = new(unversioned.Time) - **out = (*in).DeepCopy() - } else { - out.LastScaleTime = nil - } - out.CurrentReplicas = in.CurrentReplicas - out.DesiredReplicas = in.DesiredReplicas - if in.CurrentCPUUtilizationPercentage != nil { - in, out := &in.CurrentCPUUtilizationPercentage, &out.CurrentCPUUtilizationPercentage - *out = new(int32) - **out = **in - } else { - out.CurrentCPUUtilizationPercentage = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1beta1_HostPortRange is an autogenerated deepcopy function. func DeepCopy_v1beta1_HostPortRange(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HostPortRange) out := out.(*HostPortRange) - out.Min = in.Min - out.Max = in.Max + *out = *in return nil } } +// DeepCopy_v1beta1_IDRange is an autogenerated deepcopy function. func DeepCopy_v1beta1_IDRange(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IDRange) out := out.(*IDRange) - out.Min = in.Min - out.Max = in.Max + *out = *in return nil } } +// DeepCopy_v1beta1_Ingress is an autogenerated deepcopy function. func DeepCopy_v1beta1_Ingress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Ingress) out := out.(*Ingress) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_IngressSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -609,22 +504,22 @@ func DeepCopy_v1beta1_Ingress(in interface{}, out interface{}, c *conversion.Clo } } +// DeepCopy_v1beta1_IngressBackend is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressBackend(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressBackend) out := out.(*IngressBackend) - out.ServiceName = in.ServiceName - out.ServicePort = in.ServicePort + *out = *in return nil } } +// DeepCopy_v1beta1_IngressList is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressList) out := out.(*IngressList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Ingress, len(*in)) @@ -633,18 +528,17 @@ func DeepCopy_v1beta1_IngressList(in interface{}, out interface{}, c *conversion return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_IngressRule is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressRule) out := out.(*IngressRule) - out.Host = in.Host + *out = *in if err := DeepCopy_v1beta1_IngressRuleValue(&in.IngressRuleValue, &out.IngressRuleValue, c); err != nil { return err } @@ -652,33 +546,33 @@ func DeepCopy_v1beta1_IngressRule(in interface{}, out interface{}, c *conversion } } +// DeepCopy_v1beta1_IngressRuleValue is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressRuleValue(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressRuleValue) out := out.(*IngressRuleValue) + *out = *in if in.HTTP != nil { in, out := &in.HTTP, &out.HTTP *out = new(HTTPIngressRuleValue) if err := DeepCopy_v1beta1_HTTPIngressRuleValue(*in, *out, c); err != nil { return err } - } else { - out.HTTP = nil } return nil } } +// DeepCopy_v1beta1_IngressSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressSpec) out := out.(*IngressSpec) + *out = *in if in.Backend != nil { in, out := &in.Backend, &out.Backend *out = new(IngressBackend) **out = **in - } else { - out.Backend = nil } if in.TLS != nil { in, out := &in.TLS, &out.TLS @@ -688,8 +582,6 @@ func DeepCopy_v1beta1_IngressSpec(in interface{}, out interface{}, c *conversion return err } } - } else { - out.TLS = nil } if in.Rules != nil { in, out := &in.Rules, &out.Rules @@ -699,184 +591,49 @@ func DeepCopy_v1beta1_IngressSpec(in interface{}, out interface{}, c *conversion return err } } - } else { - out.Rules = nil } return nil } } +// DeepCopy_v1beta1_IngressStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressStatus) out := out.(*IngressStatus) - if err := v1.DeepCopy_v1_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, c); err != nil { + *out = *in + if err := api_v1.DeepCopy_v1_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, c); err != nil { return err } return nil } } +// DeepCopy_v1beta1_IngressTLS is an autogenerated deepcopy function. func DeepCopy_v1beta1_IngressTLS(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressTLS) out := out.(*IngressTLS) + *out = *in if in.Hosts != nil { in, out := &in.Hosts, &out.Hosts *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Hosts = nil } - out.SecretName = in.SecretName - return nil - } -} - -func DeepCopy_v1beta1_Job(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*Job) - out := out.(*Job) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { - return err - } - if err := DeepCopy_v1beta1_JobSpec(&in.Spec, &out.Spec, c); err != nil { - return err - } - if err := DeepCopy_v1beta1_JobStatus(&in.Status, &out.Status, c); err != nil { - return err - } - return nil - } -} - -func DeepCopy_v1beta1_JobCondition(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobCondition) - out := out.(*JobCondition) - out.Type = in.Type - out.Status = in.Status - out.LastProbeTime = in.LastProbeTime.DeepCopy() - out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message - return nil - } -} - -func DeepCopy_v1beta1_JobList(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobList) - out := out.(*JobList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Job, len(*in)) - for i := range *in { - if err := DeepCopy_v1beta1_Job(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Items = nil - } - return nil - } -} - -func DeepCopy_v1beta1_JobSpec(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobSpec) - out := out.(*JobSpec) - if in.Parallelism != nil { - in, out := &in.Parallelism, &out.Parallelism - *out = new(int32) - **out = **in - } else { - out.Parallelism = nil - } - if in.Completions != nil { - in, out := &in.Completions, &out.Completions - *out = new(int32) - **out = **in - } else { - out.Completions = nil - } - if in.ActiveDeadlineSeconds != nil { - in, out := &in.ActiveDeadlineSeconds, &out.ActiveDeadlineSeconds - *out = new(int64) - **out = **in - } else { - out.ActiveDeadlineSeconds = nil - } - if in.Selector != nil { - in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { - return err - } - } else { - out.Selector = nil - } - if in.AutoSelector != nil { - in, out := &in.AutoSelector, &out.AutoSelector - *out = new(bool) - **out = **in - } else { - out.AutoSelector = nil - } - if err := v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { - return err - } - return nil - } -} - -func DeepCopy_v1beta1_JobStatus(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*JobStatus) - out := out.(*JobStatus) - if in.Conditions != nil { - in, out := &in.Conditions, &out.Conditions - *out = make([]JobCondition, len(*in)) - for i := range *in { - if err := DeepCopy_v1beta1_JobCondition(&(*in)[i], &(*out)[i], c); err != nil { - return err - } - } - } else { - out.Conditions = nil - } - if in.StartTime != nil { - in, out := &in.StartTime, &out.StartTime - *out = new(unversioned.Time) - **out = (*in).DeepCopy() - } else { - out.StartTime = nil - } - if in.CompletionTime != nil { - in, out := &in.CompletionTime, &out.CompletionTime - *out = new(unversioned.Time) - **out = (*in).DeepCopy() - } else { - out.CompletionTime = nil - } - out.Active = in.Active - out.Succeeded = in.Succeeded - out.Failed = in.Failed return nil } } +// DeepCopy_v1beta1_NetworkPolicy is an autogenerated deepcopy function. func DeepCopy_v1beta1_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicy) out := out.(*NetworkPolicy) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -885,10 +642,12 @@ func DeepCopy_v1beta1_NetworkPolicy(in interface{}, out interface{}, c *conversi } } +// DeepCopy_v1beta1_NetworkPolicyIngressRule is an autogenerated deepcopy function. func DeepCopy_v1beta1_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyIngressRule) out := out.(*NetworkPolicyIngressRule) + *out = *in if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]NetworkPolicyPort, len(*in)) @@ -897,8 +656,6 @@ func DeepCopy_v1beta1_NetworkPolicyIngressRule(in interface{}, out interface{}, return err } } - } else { - out.Ports = nil } if in.From != nil { in, out := &in.From, &out.From @@ -908,19 +665,17 @@ func DeepCopy_v1beta1_NetworkPolicyIngressRule(in interface{}, out interface{}, return err } } - } else { - out.From = nil } return nil } } +// DeepCopy_v1beta1_NetworkPolicyList is an autogenerated deepcopy function. func DeepCopy_v1beta1_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyList) out := out.(*NetworkPolicyList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]NetworkPolicy, len(*in)) @@ -929,67 +684,67 @@ func DeepCopy_v1beta1_NetworkPolicyList(in interface{}, out interface{}, c *conv return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_NetworkPolicyPeer is an autogenerated deepcopy function. func DeepCopy_v1beta1_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyPeer) out := out.(*NetworkPolicyPeer) + *out = *in if in.PodSelector != nil { in, out := &in.PodSelector, &out.PodSelector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.PodSelector = nil } if in.NamespaceSelector != nil { in, out := &in.NamespaceSelector, &out.NamespaceSelector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.NamespaceSelector = nil } return nil } } +// DeepCopy_v1beta1_NetworkPolicyPort is an autogenerated deepcopy function. func DeepCopy_v1beta1_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyPort) out := out.(*NetworkPolicyPort) + *out = *in if in.Protocol != nil { in, out := &in.Protocol, &out.Protocol - *out = new(v1.Protocol) + *out = new(api_v1.Protocol) **out = **in - } else { - out.Protocol = nil } if in.Port != nil { in, out := &in.Port, &out.Port *out = new(intstr.IntOrString) **out = **in - } else { - out.Port = nil } return nil } } +// DeepCopy_v1beta1_NetworkPolicySpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicySpec) out := out.(*NetworkPolicySpec) - if err := unversioned.DeepCopy_unversioned_LabelSelector(&in.PodSelector, &out.PodSelector, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { return err + } else { + out.PodSelector = *newVal.(*v1.LabelSelector) } if in.Ingress != nil { in, out := &in.Ingress, &out.Ingress @@ -999,20 +754,21 @@ func DeepCopy_v1beta1_NetworkPolicySpec(in interface{}, out interface{}, c *conv return err } } - } else { - out.Ingress = nil } return nil } } +// DeepCopy_v1beta1_PodSecurityPolicy is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodSecurityPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityPolicy) out := out.(*PodSecurityPolicy) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_PodSecurityPolicySpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -1021,12 +777,12 @@ func DeepCopy_v1beta1_PodSecurityPolicy(in interface{}, out interface{}, c *conv } } +// DeepCopy_v1beta1_PodSecurityPolicyList is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodSecurityPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityPolicyList) out := out.(*PodSecurityPolicyList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PodSecurityPolicy, len(*in)) @@ -1035,66 +791,42 @@ func DeepCopy_v1beta1_PodSecurityPolicyList(in interface{}, out interface{}, c * return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_PodSecurityPolicySpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodSecurityPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityPolicySpec) out := out.(*PodSecurityPolicySpec) - out.Privileged = in.Privileged + *out = *in if in.DefaultAddCapabilities != nil { in, out := &in.DefaultAddCapabilities, &out.DefaultAddCapabilities - *out = make([]v1.Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.DefaultAddCapabilities = nil + *out = make([]api_v1.Capability, len(*in)) + copy(*out, *in) } if in.RequiredDropCapabilities != nil { in, out := &in.RequiredDropCapabilities, &out.RequiredDropCapabilities - *out = make([]v1.Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.RequiredDropCapabilities = nil + *out = make([]api_v1.Capability, len(*in)) + copy(*out, *in) } if in.AllowedCapabilities != nil { in, out := &in.AllowedCapabilities, &out.AllowedCapabilities - *out = make([]v1.Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AllowedCapabilities = nil + *out = make([]api_v1.Capability, len(*in)) + copy(*out, *in) } if in.Volumes != nil { in, out := &in.Volumes, &out.Volumes *out = make([]FSType, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Volumes = nil + copy(*out, *in) } - out.HostNetwork = in.HostNetwork if in.HostPorts != nil { in, out := &in.HostPorts, &out.HostPorts *out = make([]HostPortRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.HostPorts = nil + copy(*out, *in) } - out.HostPID = in.HostPID - out.HostIPC = in.HostIPC if err := DeepCopy_v1beta1_SELinuxStrategyOptions(&in.SELinux, &out.SELinux, c); err != nil { return err } @@ -1107,18 +839,20 @@ func DeepCopy_v1beta1_PodSecurityPolicySpec(in interface{}, out interface{}, c * if err := DeepCopy_v1beta1_FSGroupStrategyOptions(&in.FSGroup, &out.FSGroup, c); err != nil { return err } - out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem return nil } } +// DeepCopy_v1beta1_ReplicaSet is an autogenerated deepcopy function. func DeepCopy_v1beta1_ReplicaSet(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSet) out := out.(*ReplicaSet) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_ReplicaSetSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -1130,25 +864,23 @@ func DeepCopy_v1beta1_ReplicaSet(in interface{}, out interface{}, c *conversion. } } +// DeepCopy_v1beta1_ReplicaSetCondition is an autogenerated deepcopy function. func DeepCopy_v1beta1_ReplicaSetCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetCondition) out := out.(*ReplicaSetCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_v1beta1_ReplicaSetList is an autogenerated deepcopy function. func DeepCopy_v1beta1_ReplicaSetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetList) out := out.(*ReplicaSetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ReplicaSet, len(*in)) @@ -1157,50 +889,43 @@ func DeepCopy_v1beta1_ReplicaSetList(in interface{}, out interface{}, c *convers return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_ReplicaSetSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_ReplicaSetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetSpec) out := out.(*ReplicaSetSpec) + *out = *in if in.Replicas != nil { in, out := &in.Replicas, &out.Replicas *out = new(int32) **out = **in - } else { - out.Replicas = nil } - out.MinReadySeconds = in.MinReadySeconds if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } - if err := v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { + if err := api_v1.DeepCopy_v1_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err } return nil } } +// DeepCopy_v1beta1_ReplicaSetStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_ReplicaSetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetStatus) out := out.(*ReplicaSetStatus) - out.Replicas = in.Replicas - out.FullyLabeledReplicas = in.FullyLabeledReplicas - out.ReadyReplicas = in.ReadyReplicas - out.AvailableReplicas = in.AvailableReplicas - out.ObservedGeneration = in.ObservedGeneration + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]ReplicaSetCondition, len(*in)) @@ -1209,96 +934,107 @@ func DeepCopy_v1beta1_ReplicaSetStatus(in interface{}, out interface{}, c *conve return err } } - } else { - out.Conditions = nil } return nil } } +// DeepCopy_v1beta1_ReplicationControllerDummy is an autogenerated deepcopy function. func DeepCopy_v1beta1_ReplicationControllerDummy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerDummy) out := out.(*ReplicationControllerDummy) - out.TypeMeta = in.TypeMeta + *out = *in return nil } } +// DeepCopy_v1beta1_RollbackConfig is an autogenerated deepcopy function. func DeepCopy_v1beta1_RollbackConfig(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RollbackConfig) out := out.(*RollbackConfig) - out.Revision = in.Revision + *out = *in + return nil + } +} + +// DeepCopy_v1beta1_RollingUpdateDaemonSet is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RollingUpdateDaemonSet(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RollingUpdateDaemonSet) + out := out.(*RollingUpdateDaemonSet) + *out = *in + if in.MaxUnavailable != nil { + in, out := &in.MaxUnavailable, &out.MaxUnavailable + *out = new(intstr.IntOrString) + **out = **in + } return nil } } +// DeepCopy_v1beta1_RollingUpdateDeployment is an autogenerated deepcopy function. func DeepCopy_v1beta1_RollingUpdateDeployment(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RollingUpdateDeployment) out := out.(*RollingUpdateDeployment) + *out = *in if in.MaxUnavailable != nil { in, out := &in.MaxUnavailable, &out.MaxUnavailable *out = new(intstr.IntOrString) **out = **in - } else { - out.MaxUnavailable = nil } if in.MaxSurge != nil { in, out := &in.MaxSurge, &out.MaxSurge *out = new(intstr.IntOrString) **out = **in - } else { - out.MaxSurge = nil } return nil } } +// DeepCopy_v1beta1_RunAsUserStrategyOptions is an autogenerated deepcopy function. func DeepCopy_v1beta1_RunAsUserStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RunAsUserStrategyOptions) out := out.(*RunAsUserStrategyOptions) - out.Rule = in.Rule + *out = *in if in.Ranges != nil { in, out := &in.Ranges, &out.Ranges *out = make([]IDRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ranges = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1beta1_SELinuxStrategyOptions is an autogenerated deepcopy function. func DeepCopy_v1beta1_SELinuxStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SELinuxStrategyOptions) out := out.(*SELinuxStrategyOptions) - out.Rule = in.Rule + *out = *in if in.SELinuxOptions != nil { in, out := &in.SELinuxOptions, &out.SELinuxOptions - *out = new(v1.SELinuxOptions) + *out = new(api_v1.SELinuxOptions) **out = **in - } else { - out.SELinuxOptions = nil } return nil } } +// DeepCopy_v1beta1_Scale is an autogenerated deepcopy function. func DeepCopy_v1beta1_Scale(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Scale) out := out.(*Scale) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Spec = in.Spec if err := DeepCopy_v1beta1_ScaleStatus(&in.Status, &out.Status, c); err != nil { return err } @@ -1306,111 +1042,94 @@ func DeepCopy_v1beta1_Scale(in interface{}, out interface{}, c *conversion.Clone } } +// DeepCopy_v1beta1_ScaleSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_ScaleSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleSpec) out := out.(*ScaleSpec) - out.Replicas = in.Replicas + *out = *in return nil } } +// DeepCopy_v1beta1_ScaleStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_ScaleStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleStatus) out := out.(*ScaleStatus) - out.Replicas = in.Replicas + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Selector = nil } - out.TargetSelector = in.TargetSelector - return nil - } -} - -func DeepCopy_v1beta1_SubresourceReference(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*SubresourceReference) - out := out.(*SubresourceReference) - out.Kind = in.Kind - out.Name = in.Name - out.APIVersion = in.APIVersion - out.Subresource = in.Subresource return nil } } +// DeepCopy_v1beta1_SupplementalGroupsStrategyOptions is an autogenerated deepcopy function. func DeepCopy_v1beta1_SupplementalGroupsStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SupplementalGroupsStrategyOptions) out := out.(*SupplementalGroupsStrategyOptions) - out.Rule = in.Rule + *out = *in if in.Ranges != nil { in, out := &in.Ranges, &out.Ranges *out = make([]IDRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ranges = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1beta1_ThirdPartyResource is an autogenerated deepcopy function. func DeepCopy_v1beta1_ThirdPartyResource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResource) out := out.(*ThirdPartyResource) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Description = in.Description if in.Versions != nil { in, out := &in.Versions, &out.Versions *out = make([]APIVersion, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Versions = nil + copy(*out, *in) } return nil } } +// DeepCopy_v1beta1_ThirdPartyResourceData is an autogenerated deepcopy function. func DeepCopy_v1beta1_ThirdPartyResourceData(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResourceData) out := out.(*ThirdPartyResourceData) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Data != nil { in, out := &in.Data, &out.Data *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Data = nil } return nil } } +// DeepCopy_v1beta1_ThirdPartyResourceDataList is an autogenerated deepcopy function. func DeepCopy_v1beta1_ThirdPartyResourceDataList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResourceDataList) out := out.(*ThirdPartyResourceDataList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ThirdPartyResourceData, len(*in)) @@ -1419,19 +1138,17 @@ func DeepCopy_v1beta1_ThirdPartyResourceDataList(in interface{}, out interface{} return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_ThirdPartyResourceList is an autogenerated deepcopy function. func DeepCopy_v1beta1_ThirdPartyResourceList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResourceList) out := out.(*ThirdPartyResourceList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ThirdPartyResource, len(*in)) @@ -1440,8 +1157,6 @@ func DeepCopy_v1beta1_ThirdPartyResourceList(in interface{}, out interface{}, c return err } } - } else { - out.Items = nil } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.defaults.go index 000645c654..770faa513f 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,8 +21,8 @@ limitations under the License. package v1beta1 import ( + runtime "k8s.io/apimachinery/pkg/runtime" v1 "k8s.io/client-go/pkg/api/v1" - runtime "k8s.io/client-go/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. @@ -33,12 +33,6 @@ func RegisterDefaults(scheme *runtime.Scheme) error { scheme.AddTypeDefaultingFunc(&DaemonSetList{}, func(obj interface{}) { SetObjectDefaults_DaemonSetList(obj.(*DaemonSetList)) }) scheme.AddTypeDefaultingFunc(&Deployment{}, func(obj interface{}) { SetObjectDefaults_Deployment(obj.(*Deployment)) }) scheme.AddTypeDefaultingFunc(&DeploymentList{}, func(obj interface{}) { SetObjectDefaults_DeploymentList(obj.(*DeploymentList)) }) - scheme.AddTypeDefaultingFunc(&HorizontalPodAutoscaler{}, func(obj interface{}) { SetObjectDefaults_HorizontalPodAutoscaler(obj.(*HorizontalPodAutoscaler)) }) - scheme.AddTypeDefaultingFunc(&HorizontalPodAutoscalerList{}, func(obj interface{}) { - SetObjectDefaults_HorizontalPodAutoscalerList(obj.(*HorizontalPodAutoscalerList)) - }) - scheme.AddTypeDefaultingFunc(&Job{}, func(obj interface{}) { SetObjectDefaults_Job(obj.(*Job)) }) - scheme.AddTypeDefaultingFunc(&JobList{}, func(obj interface{}) { SetObjectDefaults_JobList(obj.(*JobList)) }) scheme.AddTypeDefaultingFunc(&NetworkPolicy{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicy(obj.(*NetworkPolicy)) }) scheme.AddTypeDefaultingFunc(&NetworkPolicyList{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicyList(obj.(*NetworkPolicyList)) }) scheme.AddTypeDefaultingFunc(&ReplicaSet{}, func(obj interface{}) { SetObjectDefaults_ReplicaSet(obj.(*ReplicaSet)) }) @@ -76,6 +70,23 @@ func SetObjectDefaults_DaemonSet(in *DaemonSet) { if a.VolumeSource.AzureDisk != nil { v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.Template.Spec.InitContainers { a := &in.Spec.Template.Spec.InitContainers[i] @@ -200,140 +211,22 @@ func SetObjectDefaults_Deployment(in *Deployment) { if a.VolumeSource.AzureDisk != nil { v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } - } - for i := range in.Spec.Template.Spec.InitContainers { - a := &in.Spec.Template.Spec.InitContainers[i] - v1.SetDefaults_Container(a) - for j := range a.Ports { - b := &a.Ports[j] - v1.SetDefaults_ContainerPort(b) - } - for j := range a.Env { - b := &a.Env[j] - if b.ValueFrom != nil { - if b.ValueFrom.FieldRef != nil { - v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef) + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } } } } - v1.SetDefaults_ResourceList(&a.Resources.Limits) - v1.SetDefaults_ResourceList(&a.Resources.Requests) - if a.LivenessProbe != nil { - v1.SetDefaults_Probe(a.LivenessProbe) - if a.LivenessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.LivenessProbe.Handler.HTTPGet) - } - } - if a.ReadinessProbe != nil { - v1.SetDefaults_Probe(a.ReadinessProbe) - if a.ReadinessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.Handler.HTTPGet) - } - } - if a.Lifecycle != nil { - if a.Lifecycle.PostStart != nil { - if a.Lifecycle.PostStart.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet) - } - } - if a.Lifecycle.PreStop != nil { - if a.Lifecycle.PreStop.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet) - } - } - } - } - for i := range in.Spec.Template.Spec.Containers { - a := &in.Spec.Template.Spec.Containers[i] - v1.SetDefaults_Container(a) - for j := range a.Ports { - b := &a.Ports[j] - v1.SetDefaults_ContainerPort(b) - } - for j := range a.Env { - b := &a.Env[j] - if b.ValueFrom != nil { - if b.ValueFrom.FieldRef != nil { - v1.SetDefaults_ObjectFieldSelector(b.ValueFrom.FieldRef) - } - } - } - v1.SetDefaults_ResourceList(&a.Resources.Limits) - v1.SetDefaults_ResourceList(&a.Resources.Requests) - if a.LivenessProbe != nil { - v1.SetDefaults_Probe(a.LivenessProbe) - if a.LivenessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.LivenessProbe.Handler.HTTPGet) - } - } - if a.ReadinessProbe != nil { - v1.SetDefaults_Probe(a.ReadinessProbe) - if a.ReadinessProbe.Handler.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.ReadinessProbe.Handler.HTTPGet) - } - } - if a.Lifecycle != nil { - if a.Lifecycle.PostStart != nil { - if a.Lifecycle.PostStart.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PostStart.HTTPGet) - } - } - if a.Lifecycle.PreStop != nil { - if a.Lifecycle.PreStop.HTTPGet != nil { - v1.SetDefaults_HTTPGetAction(a.Lifecycle.PreStop.HTTPGet) - } - } - } - } -} - -func SetObjectDefaults_DeploymentList(in *DeploymentList) { - for i := range in.Items { - a := &in.Items[i] - SetObjectDefaults_Deployment(a) - } -} - -func SetObjectDefaults_HorizontalPodAutoscaler(in *HorizontalPodAutoscaler) { - SetDefaults_HorizontalPodAutoscaler(in) -} - -func SetObjectDefaults_HorizontalPodAutoscalerList(in *HorizontalPodAutoscalerList) { - for i := range in.Items { - a := &in.Items[i] - SetObjectDefaults_HorizontalPodAutoscaler(a) - } -} - -func SetObjectDefaults_Job(in *Job) { - SetDefaults_Job(in) - v1.SetDefaults_PodSpec(&in.Spec.Template.Spec) - for i := range in.Spec.Template.Spec.Volumes { - a := &in.Spec.Template.Spec.Volumes[i] - v1.SetDefaults_Volume(a) - if a.VolumeSource.Secret != nil { - v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret) - } - if a.VolumeSource.ISCSI != nil { - v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI) - } - if a.VolumeSource.RBD != nil { - v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD) - } - if a.VolumeSource.DownwardAPI != nil { - v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI) - for j := range a.VolumeSource.DownwardAPI.Items { - b := &a.VolumeSource.DownwardAPI.Items[j] - if b.FieldRef != nil { - v1.SetDefaults_ObjectFieldSelector(b.FieldRef) - } - } - } - if a.VolumeSource.ConfigMap != nil { - v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap) - } - if a.VolumeSource.AzureDisk != nil { - v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) } } for i := range in.Spec.Template.Spec.InitContainers { @@ -422,10 +315,10 @@ func SetObjectDefaults_Job(in *Job) { } } -func SetObjectDefaults_JobList(in *JobList) { +func SetObjectDefaults_DeploymentList(in *DeploymentList) { for i := range in.Items { a := &in.Items[i] - SetObjectDefaults_Job(a) + SetObjectDefaults_Deployment(a) } } @@ -470,6 +363,23 @@ func SetObjectDefaults_ReplicaSet(in *ReplicaSet) { if a.VolumeSource.AzureDisk != nil { v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } } for i := range in.Spec.Template.Spec.InitContainers { a := &in.Spec.Template.Spec.InitContainers[i] diff --git a/vendor/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go index 19003a9ea1..2d88c85e7b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/extensions/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,11 +21,11 @@ limitations under the License. package extensions import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" - intstr "k8s.io/client-go/pkg/util/intstr" reflect "reflect" ) @@ -46,6 +46,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DaemonSetList, InType: reflect.TypeOf(&DaemonSetList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DaemonSetSpec, InType: reflect.TypeOf(&DaemonSetSpec{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DaemonSetStatus, InType: reflect.TypeOf(&DaemonSetStatus{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DaemonSetUpdateStrategy, InType: reflect.TypeOf(&DaemonSetUpdateStrategy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_Deployment, InType: reflect.TypeOf(&Deployment{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DeploymentCondition, InType: reflect.TypeOf(&DeploymentCondition{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DeploymentList, InType: reflect.TypeOf(&DeploymentList{})}, @@ -54,10 +55,10 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DeploymentStatus, InType: reflect.TypeOf(&DeploymentStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_DeploymentStrategy, InType: reflect.TypeOf(&DeploymentStrategy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_FSGroupStrategyOptions, InType: reflect.TypeOf(&FSGroupStrategyOptions{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_GroupIDRange, InType: reflect.TypeOf(&GroupIDRange{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_HTTPIngressPath, InType: reflect.TypeOf(&HTTPIngressPath{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_HTTPIngressRuleValue, InType: reflect.TypeOf(&HTTPIngressRuleValue{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_HostPortRange, InType: reflect.TypeOf(&HostPortRange{})}, - conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_IDRange, InType: reflect.TypeOf(&IDRange{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_Ingress, InType: reflect.TypeOf(&Ingress{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_IngressBackend, InType: reflect.TypeOf(&IngressBackend{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_IngressList, InType: reflect.TypeOf(&IngressList{})}, @@ -82,6 +83,7 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_ReplicaSetStatus, InType: reflect.TypeOf(&ReplicaSetStatus{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_ReplicationControllerDummy, InType: reflect.TypeOf(&ReplicationControllerDummy{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_RollbackConfig, InType: reflect.TypeOf(&RollbackConfig{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_RollingUpdateDaemonSet, InType: reflect.TypeOf(&RollingUpdateDaemonSet{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_RollingUpdateDeployment, InType: reflect.TypeOf(&RollingUpdateDeployment{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_RunAsUserStrategyOptions, InType: reflect.TypeOf(&RunAsUserStrategyOptions{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_SELinuxStrategyOptions, InType: reflect.TypeOf(&SELinuxStrategyOptions{})}, @@ -93,32 +95,37 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_ThirdPartyResourceData, InType: reflect.TypeOf(&ThirdPartyResourceData{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_ThirdPartyResourceDataList, InType: reflect.TypeOf(&ThirdPartyResourceDataList{})}, conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_ThirdPartyResourceList, InType: reflect.TypeOf(&ThirdPartyResourceList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_extensions_UserIDRange, InType: reflect.TypeOf(&UserIDRange{})}, ) } +// DeepCopy_extensions_APIVersion is an autogenerated deepcopy function. func DeepCopy_extensions_APIVersion(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*APIVersion) out := out.(*APIVersion) - out.Name = in.Name + *out = *in return nil } } +// DeepCopy_extensions_CustomMetricCurrentStatus is an autogenerated deepcopy function. func DeepCopy_extensions_CustomMetricCurrentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricCurrentStatus) out := out.(*CustomMetricCurrentStatus) - out.Name = in.Name + *out = *in out.CurrentValue = in.CurrentValue.DeepCopy() return nil } } +// DeepCopy_extensions_CustomMetricCurrentStatusList is an autogenerated deepcopy function. func DeepCopy_extensions_CustomMetricCurrentStatusList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricCurrentStatusList) out := out.(*CustomMetricCurrentStatusList) + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CustomMetricCurrentStatus, len(*in)) @@ -127,27 +134,28 @@ func DeepCopy_extensions_CustomMetricCurrentStatusList(in interface{}, out inter return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_CustomMetricTarget is an autogenerated deepcopy function. func DeepCopy_extensions_CustomMetricTarget(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricTarget) out := out.(*CustomMetricTarget) - out.Name = in.Name + *out = *in out.TargetValue = in.TargetValue.DeepCopy() return nil } } +// DeepCopy_extensions_CustomMetricTargetList is an autogenerated deepcopy function. func DeepCopy_extensions_CustomMetricTargetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*CustomMetricTargetList) out := out.(*CustomMetricTargetList) + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]CustomMetricTarget, len(*in)) @@ -156,35 +164,38 @@ func DeepCopy_extensions_CustomMetricTargetList(in interface{}, out interface{}, return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_DaemonSet is an autogenerated deepcopy function. func DeepCopy_extensions_DaemonSet(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSet) out := out.(*DaemonSet) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_extensions_DaemonSetSpec(&in.Spec, &out.Spec, c); err != nil { return err } - out.Status = in.Status + if err := DeepCopy_extensions_DaemonSetStatus(&in.Status, &out.Status, c); err != nil { + return err + } return nil } } +// DeepCopy_extensions_DaemonSetList is an autogenerated deepcopy function. func DeepCopy_extensions_DaemonSetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSetList) out := out.(*DaemonSetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]DaemonSet, len(*in)) @@ -193,52 +204,80 @@ func DeepCopy_extensions_DaemonSetList(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_DaemonSetSpec is an autogenerated deepcopy function. func DeepCopy_extensions_DaemonSetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSetSpec) out := out.(*DaemonSetSpec) + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } if err := api.DeepCopy_api_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err } + if err := DeepCopy_extensions_DaemonSetUpdateStrategy(&in.UpdateStrategy, &out.UpdateStrategy, c); err != nil { + return err + } + if in.RevisionHistoryLimit != nil { + in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit + *out = new(int32) + **out = **in + } return nil } } +// DeepCopy_extensions_DaemonSetStatus is an autogenerated deepcopy function. func DeepCopy_extensions_DaemonSetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DaemonSetStatus) out := out.(*DaemonSetStatus) - out.CurrentNumberScheduled = in.CurrentNumberScheduled - out.NumberMisscheduled = in.NumberMisscheduled - out.DesiredNumberScheduled = in.DesiredNumberScheduled - out.NumberReady = in.NumberReady + *out = *in + if in.CollisionCount != nil { + in, out := &in.CollisionCount, &out.CollisionCount + *out = new(int64) + **out = **in + } return nil } } +// DeepCopy_extensions_DaemonSetUpdateStrategy is an autogenerated deepcopy function. +func DeepCopy_extensions_DaemonSetUpdateStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*DaemonSetUpdateStrategy) + out := out.(*DaemonSetUpdateStrategy) + *out = *in + if in.RollingUpdate != nil { + in, out := &in.RollingUpdate, &out.RollingUpdate + *out = new(RollingUpdateDaemonSet) + **out = **in + } + return nil + } +} + +// DeepCopy_extensions_Deployment is an autogenerated deepcopy function. func DeepCopy_extensions_Deployment(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Deployment) out := out.(*Deployment) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_extensions_DeploymentSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -250,26 +289,24 @@ func DeepCopy_extensions_Deployment(in interface{}, out interface{}, c *conversi } } +// DeepCopy_extensions_DeploymentCondition is an autogenerated deepcopy function. func DeepCopy_extensions_DeploymentCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentCondition) out := out.(*DeploymentCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastUpdateTime = in.LastUpdateTime.DeepCopy() out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_extensions_DeploymentList is an autogenerated deepcopy function. func DeepCopy_extensions_DeploymentList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentList) out := out.(*DeploymentList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Deployment, len(*in)) @@ -278,46 +315,41 @@ func DeepCopy_extensions_DeploymentList(in interface{}, out interface{}, c *conv return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_DeploymentRollback is an autogenerated deepcopy function. func DeepCopy_extensions_DeploymentRollback(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentRollback) out := out.(*DeploymentRollback) - out.TypeMeta = in.TypeMeta - out.Name = in.Name + *out = *in if in.UpdatedAnnotations != nil { in, out := &in.UpdatedAnnotations, &out.UpdatedAnnotations *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.UpdatedAnnotations = nil } - out.RollbackTo = in.RollbackTo return nil } } +// DeepCopy_extensions_DeploymentSpec is an autogenerated deepcopy function. func DeepCopy_extensions_DeploymentSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentSpec) out := out.(*DeploymentSpec) - out.Replicas = in.Replicas + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } if err := api.DeepCopy_api_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -325,42 +357,31 @@ func DeepCopy_extensions_DeploymentSpec(in interface{}, out interface{}, c *conv if err := DeepCopy_extensions_DeploymentStrategy(&in.Strategy, &out.Strategy, c); err != nil { return err } - out.MinReadySeconds = in.MinReadySeconds if in.RevisionHistoryLimit != nil { in, out := &in.RevisionHistoryLimit, &out.RevisionHistoryLimit *out = new(int32) **out = **in - } else { - out.RevisionHistoryLimit = nil } - out.Paused = in.Paused if in.RollbackTo != nil { in, out := &in.RollbackTo, &out.RollbackTo *out = new(RollbackConfig) **out = **in - } else { - out.RollbackTo = nil } if in.ProgressDeadlineSeconds != nil { in, out := &in.ProgressDeadlineSeconds, &out.ProgressDeadlineSeconds *out = new(int32) **out = **in - } else { - out.ProgressDeadlineSeconds = nil } return nil } } +// DeepCopy_extensions_DeploymentStatus is an autogenerated deepcopy function. func DeepCopy_extensions_DeploymentStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentStatus) out := out.(*DeploymentStatus) - out.ObservedGeneration = in.ObservedGeneration - out.Replicas = in.Replicas - out.UpdatedReplicas = in.UpdatedReplicas - out.AvailableReplicas = in.AvailableReplicas - out.UnavailableReplicas = in.UnavailableReplicas + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]DeploymentCondition, len(*in)) @@ -369,101 +390,101 @@ func DeepCopy_extensions_DeploymentStatus(in interface{}, out interface{}, c *co return err } } - } else { - out.Conditions = nil + } + if in.CollisionCount != nil { + in, out := &in.CollisionCount, &out.CollisionCount + *out = new(int64) + **out = **in } return nil } } +// DeepCopy_extensions_DeploymentStrategy is an autogenerated deepcopy function. func DeepCopy_extensions_DeploymentStrategy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*DeploymentStrategy) out := out.(*DeploymentStrategy) - out.Type = in.Type + *out = *in if in.RollingUpdate != nil { in, out := &in.RollingUpdate, &out.RollingUpdate *out = new(RollingUpdateDeployment) **out = **in - } else { - out.RollingUpdate = nil } return nil } } +// DeepCopy_extensions_FSGroupStrategyOptions is an autogenerated deepcopy function. func DeepCopy_extensions_FSGroupStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*FSGroupStrategyOptions) out := out.(*FSGroupStrategyOptions) - out.Rule = in.Rule + *out = *in if in.Ranges != nil { in, out := &in.Ranges, &out.Ranges - *out = make([]IDRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ranges = nil + *out = make([]GroupIDRange, len(*in)) + copy(*out, *in) } return nil } } +// DeepCopy_extensions_GroupIDRange is an autogenerated deepcopy function. +func DeepCopy_extensions_GroupIDRange(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*GroupIDRange) + out := out.(*GroupIDRange) + *out = *in + return nil + } +} + +// DeepCopy_extensions_HTTPIngressPath is an autogenerated deepcopy function. func DeepCopy_extensions_HTTPIngressPath(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPIngressPath) out := out.(*HTTPIngressPath) - out.Path = in.Path - out.Backend = in.Backend + *out = *in return nil } } +// DeepCopy_extensions_HTTPIngressRuleValue is an autogenerated deepcopy function. func DeepCopy_extensions_HTTPIngressRuleValue(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HTTPIngressRuleValue) out := out.(*HTTPIngressRuleValue) + *out = *in if in.Paths != nil { in, out := &in.Paths, &out.Paths *out = make([]HTTPIngressPath, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Paths = nil + copy(*out, *in) } return nil } } +// DeepCopy_extensions_HostPortRange is an autogenerated deepcopy function. func DeepCopy_extensions_HostPortRange(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*HostPortRange) out := out.(*HostPortRange) - out.Min = in.Min - out.Max = in.Max - return nil - } -} - -func DeepCopy_extensions_IDRange(in interface{}, out interface{}, c *conversion.Cloner) error { - { - in := in.(*IDRange) - out := out.(*IDRange) - out.Min = in.Min - out.Max = in.Max + *out = *in return nil } } +// DeepCopy_extensions_Ingress is an autogenerated deepcopy function. func DeepCopy_extensions_Ingress(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Ingress) out := out.(*Ingress) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_extensions_IngressSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -475,22 +496,22 @@ func DeepCopy_extensions_Ingress(in interface{}, out interface{}, c *conversion. } } +// DeepCopy_extensions_IngressBackend is an autogenerated deepcopy function. func DeepCopy_extensions_IngressBackend(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressBackend) out := out.(*IngressBackend) - out.ServiceName = in.ServiceName - out.ServicePort = in.ServicePort + *out = *in return nil } } +// DeepCopy_extensions_IngressList is an autogenerated deepcopy function. func DeepCopy_extensions_IngressList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressList) out := out.(*IngressList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Ingress, len(*in)) @@ -499,18 +520,17 @@ func DeepCopy_extensions_IngressList(in interface{}, out interface{}, c *convers return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_IngressRule is an autogenerated deepcopy function. func DeepCopy_extensions_IngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressRule) out := out.(*IngressRule) - out.Host = in.Host + *out = *in if err := DeepCopy_extensions_IngressRuleValue(&in.IngressRuleValue, &out.IngressRuleValue, c); err != nil { return err } @@ -518,33 +538,33 @@ func DeepCopy_extensions_IngressRule(in interface{}, out interface{}, c *convers } } +// DeepCopy_extensions_IngressRuleValue is an autogenerated deepcopy function. func DeepCopy_extensions_IngressRuleValue(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressRuleValue) out := out.(*IngressRuleValue) + *out = *in if in.HTTP != nil { in, out := &in.HTTP, &out.HTTP *out = new(HTTPIngressRuleValue) if err := DeepCopy_extensions_HTTPIngressRuleValue(*in, *out, c); err != nil { return err } - } else { - out.HTTP = nil } return nil } } +// DeepCopy_extensions_IngressSpec is an autogenerated deepcopy function. func DeepCopy_extensions_IngressSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressSpec) out := out.(*IngressSpec) + *out = *in if in.Backend != nil { in, out := &in.Backend, &out.Backend *out = new(IngressBackend) **out = **in - } else { - out.Backend = nil } if in.TLS != nil { in, out := &in.TLS, &out.TLS @@ -554,8 +574,6 @@ func DeepCopy_extensions_IngressSpec(in interface{}, out interface{}, c *convers return err } } - } else { - out.TLS = nil } if in.Rules != nil { in, out := &in.Rules, &out.Rules @@ -565,17 +583,17 @@ func DeepCopy_extensions_IngressSpec(in interface{}, out interface{}, c *convers return err } } - } else { - out.Rules = nil } return nil } } +// DeepCopy_extensions_IngressStatus is an autogenerated deepcopy function. func DeepCopy_extensions_IngressStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressStatus) out := out.(*IngressStatus) + *out = *in if err := api.DeepCopy_api_LoadBalancerStatus(&in.LoadBalancer, &out.LoadBalancer, c); err != nil { return err } @@ -583,29 +601,31 @@ func DeepCopy_extensions_IngressStatus(in interface{}, out interface{}, c *conve } } +// DeepCopy_extensions_IngressTLS is an autogenerated deepcopy function. func DeepCopy_extensions_IngressTLS(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*IngressTLS) out := out.(*IngressTLS) + *out = *in if in.Hosts != nil { in, out := &in.Hosts, &out.Hosts *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Hosts = nil } - out.SecretName = in.SecretName return nil } } +// DeepCopy_extensions_NetworkPolicy is an autogenerated deepcopy function. func DeepCopy_extensions_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicy) out := out.(*NetworkPolicy) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_extensions_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -614,10 +634,12 @@ func DeepCopy_extensions_NetworkPolicy(in interface{}, out interface{}, c *conve } } +// DeepCopy_extensions_NetworkPolicyIngressRule is an autogenerated deepcopy function. func DeepCopy_extensions_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyIngressRule) out := out.(*NetworkPolicyIngressRule) + *out = *in if in.Ports != nil { in, out := &in.Ports, &out.Ports *out = make([]NetworkPolicyPort, len(*in)) @@ -626,8 +648,6 @@ func DeepCopy_extensions_NetworkPolicyIngressRule(in interface{}, out interface{ return err } } - } else { - out.Ports = nil } if in.From != nil { in, out := &in.From, &out.From @@ -637,19 +657,17 @@ func DeepCopy_extensions_NetworkPolicyIngressRule(in interface{}, out interface{ return err } } - } else { - out.From = nil } return nil } } +// DeepCopy_extensions_NetworkPolicyList is an autogenerated deepcopy function. func DeepCopy_extensions_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyList) out := out.(*NetworkPolicyList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]NetworkPolicy, len(*in)) @@ -658,67 +676,67 @@ func DeepCopy_extensions_NetworkPolicyList(in interface{}, out interface{}, c *c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_NetworkPolicyPeer is an autogenerated deepcopy function. func DeepCopy_extensions_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyPeer) out := out.(*NetworkPolicyPeer) + *out = *in if in.PodSelector != nil { in, out := &in.PodSelector, &out.PodSelector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.PodSelector = nil } if in.NamespaceSelector != nil { in, out := &in.NamespaceSelector, &out.NamespaceSelector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.NamespaceSelector = nil } return nil } } +// DeepCopy_extensions_NetworkPolicyPort is an autogenerated deepcopy function. func DeepCopy_extensions_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicyPort) out := out.(*NetworkPolicyPort) + *out = *in if in.Protocol != nil { in, out := &in.Protocol, &out.Protocol *out = new(api.Protocol) **out = **in - } else { - out.Protocol = nil } if in.Port != nil { in, out := &in.Port, &out.Port *out = new(intstr.IntOrString) **out = **in - } else { - out.Port = nil } return nil } } +// DeepCopy_extensions_NetworkPolicySpec is an autogenerated deepcopy function. func DeepCopy_extensions_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*NetworkPolicySpec) out := out.(*NetworkPolicySpec) - if err := unversioned.DeepCopy_unversioned_LabelSelector(&in.PodSelector, &out.PodSelector, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { return err + } else { + out.PodSelector = *newVal.(*v1.LabelSelector) } if in.Ingress != nil { in, out := &in.Ingress, &out.Ingress @@ -728,20 +746,21 @@ func DeepCopy_extensions_NetworkPolicySpec(in interface{}, out interface{}, c *c return err } } - } else { - out.Ingress = nil } return nil } } +// DeepCopy_extensions_PodSecurityPolicy is an autogenerated deepcopy function. func DeepCopy_extensions_PodSecurityPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityPolicy) out := out.(*PodSecurityPolicy) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_extensions_PodSecurityPolicySpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -750,12 +769,12 @@ func DeepCopy_extensions_PodSecurityPolicy(in interface{}, out interface{}, c *c } } +// DeepCopy_extensions_PodSecurityPolicyList is an autogenerated deepcopy function. func DeepCopy_extensions_PodSecurityPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityPolicyList) out := out.(*PodSecurityPolicyList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PodSecurityPolicy, len(*in)) @@ -764,66 +783,42 @@ func DeepCopy_extensions_PodSecurityPolicyList(in interface{}, out interface{}, return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_PodSecurityPolicySpec is an autogenerated deepcopy function. func DeepCopy_extensions_PodSecurityPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodSecurityPolicySpec) out := out.(*PodSecurityPolicySpec) - out.Privileged = in.Privileged + *out = *in if in.DefaultAddCapabilities != nil { in, out := &in.DefaultAddCapabilities, &out.DefaultAddCapabilities *out = make([]api.Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.DefaultAddCapabilities = nil + copy(*out, *in) } if in.RequiredDropCapabilities != nil { in, out := &in.RequiredDropCapabilities, &out.RequiredDropCapabilities *out = make([]api.Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.RequiredDropCapabilities = nil + copy(*out, *in) } if in.AllowedCapabilities != nil { in, out := &in.AllowedCapabilities, &out.AllowedCapabilities *out = make([]api.Capability, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.AllowedCapabilities = nil + copy(*out, *in) } if in.Volumes != nil { in, out := &in.Volumes, &out.Volumes *out = make([]FSType, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Volumes = nil + copy(*out, *in) } - out.HostNetwork = in.HostNetwork if in.HostPorts != nil { in, out := &in.HostPorts, &out.HostPorts *out = make([]HostPortRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.HostPorts = nil + copy(*out, *in) } - out.HostPID = in.HostPID - out.HostIPC = in.HostIPC if err := DeepCopy_extensions_SELinuxStrategyOptions(&in.SELinux, &out.SELinux, c); err != nil { return err } @@ -836,18 +831,20 @@ func DeepCopy_extensions_PodSecurityPolicySpec(in interface{}, out interface{}, if err := DeepCopy_extensions_FSGroupStrategyOptions(&in.FSGroup, &out.FSGroup, c); err != nil { return err } - out.ReadOnlyRootFilesystem = in.ReadOnlyRootFilesystem return nil } } +// DeepCopy_extensions_ReplicaSet is an autogenerated deepcopy function. func DeepCopy_extensions_ReplicaSet(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSet) out := out.(*ReplicaSet) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_extensions_ReplicaSetSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -859,25 +856,23 @@ func DeepCopy_extensions_ReplicaSet(in interface{}, out interface{}, c *conversi } } +// DeepCopy_extensions_ReplicaSetCondition is an autogenerated deepcopy function. func DeepCopy_extensions_ReplicaSetCondition(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetCondition) out := out.(*ReplicaSetCondition) - out.Type = in.Type - out.Status = in.Status + *out = *in out.LastTransitionTime = in.LastTransitionTime.DeepCopy() - out.Reason = in.Reason - out.Message = in.Message return nil } } +// DeepCopy_extensions_ReplicaSetList is an autogenerated deepcopy function. func DeepCopy_extensions_ReplicaSetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetList) out := out.(*ReplicaSetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ReplicaSet, len(*in)) @@ -886,27 +881,24 @@ func DeepCopy_extensions_ReplicaSetList(in interface{}, out interface{}, c *conv return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_ReplicaSetSpec is an autogenerated deepcopy function. func DeepCopy_extensions_ReplicaSetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetSpec) out := out.(*ReplicaSetSpec) - out.Replicas = in.Replicas - out.MinReadySeconds = in.MinReadySeconds + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } if err := api.DeepCopy_api_PodTemplateSpec(&in.Template, &out.Template, c); err != nil { return err @@ -915,15 +907,12 @@ func DeepCopy_extensions_ReplicaSetSpec(in interface{}, out interface{}, c *conv } } +// DeepCopy_extensions_ReplicaSetStatus is an autogenerated deepcopy function. func DeepCopy_extensions_ReplicaSetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicaSetStatus) out := out.(*ReplicaSetStatus) - out.Replicas = in.Replicas - out.FullyLabeledReplicas = in.FullyLabeledReplicas - out.ReadyReplicas = in.ReadyReplicas - out.AvailableReplicas = in.AvailableReplicas - out.ObservedGeneration = in.ObservedGeneration + *out = *in if in.Conditions != nil { in, out := &in.Conditions, &out.Conditions *out = make([]ReplicaSetCondition, len(*in)) @@ -932,84 +921,92 @@ func DeepCopy_extensions_ReplicaSetStatus(in interface{}, out interface{}, c *co return err } } - } else { - out.Conditions = nil } return nil } } +// DeepCopy_extensions_ReplicationControllerDummy is an autogenerated deepcopy function. func DeepCopy_extensions_ReplicationControllerDummy(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ReplicationControllerDummy) out := out.(*ReplicationControllerDummy) - out.TypeMeta = in.TypeMeta + *out = *in return nil } } +// DeepCopy_extensions_RollbackConfig is an autogenerated deepcopy function. func DeepCopy_extensions_RollbackConfig(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RollbackConfig) out := out.(*RollbackConfig) - out.Revision = in.Revision + *out = *in + return nil + } +} + +// DeepCopy_extensions_RollingUpdateDaemonSet is an autogenerated deepcopy function. +func DeepCopy_extensions_RollingUpdateDaemonSet(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RollingUpdateDaemonSet) + out := out.(*RollingUpdateDaemonSet) + *out = *in return nil } } +// DeepCopy_extensions_RollingUpdateDeployment is an autogenerated deepcopy function. func DeepCopy_extensions_RollingUpdateDeployment(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RollingUpdateDeployment) out := out.(*RollingUpdateDeployment) - out.MaxUnavailable = in.MaxUnavailable - out.MaxSurge = in.MaxSurge + *out = *in return nil } } +// DeepCopy_extensions_RunAsUserStrategyOptions is an autogenerated deepcopy function. func DeepCopy_extensions_RunAsUserStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RunAsUserStrategyOptions) out := out.(*RunAsUserStrategyOptions) - out.Rule = in.Rule + *out = *in if in.Ranges != nil { in, out := &in.Ranges, &out.Ranges - *out = make([]IDRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ranges = nil + *out = make([]UserIDRange, len(*in)) + copy(*out, *in) } return nil } } +// DeepCopy_extensions_SELinuxStrategyOptions is an autogenerated deepcopy function. func DeepCopy_extensions_SELinuxStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SELinuxStrategyOptions) out := out.(*SELinuxStrategyOptions) - out.Rule = in.Rule + *out = *in if in.SELinuxOptions != nil { in, out := &in.SELinuxOptions, &out.SELinuxOptions *out = new(api.SELinuxOptions) **out = **in - } else { - out.SELinuxOptions = nil } return nil } } +// DeepCopy_extensions_Scale is an autogenerated deepcopy function. func DeepCopy_extensions_Scale(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Scale) out := out.(*Scale) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Spec = in.Spec if err := DeepCopy_extensions_ScaleStatus(&in.Status, &out.Status, c); err != nil { return err } @@ -1017,98 +1014,95 @@ func DeepCopy_extensions_Scale(in interface{}, out interface{}, c *conversion.Cl } } +// DeepCopy_extensions_ScaleSpec is an autogenerated deepcopy function. func DeepCopy_extensions_ScaleSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleSpec) out := out.(*ScaleSpec) - out.Replicas = in.Replicas + *out = *in return nil } } +// DeepCopy_extensions_ScaleStatus is an autogenerated deepcopy function. func DeepCopy_extensions_ScaleStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ScaleStatus) out := out.(*ScaleStatus) - out.Replicas = in.Replicas + *out = *in if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil } return nil } } +// DeepCopy_extensions_SupplementalGroupsStrategyOptions is an autogenerated deepcopy function. func DeepCopy_extensions_SupplementalGroupsStrategyOptions(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*SupplementalGroupsStrategyOptions) out := out.(*SupplementalGroupsStrategyOptions) - out.Rule = in.Rule + *out = *in if in.Ranges != nil { in, out := &in.Ranges, &out.Ranges - *out = make([]IDRange, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Ranges = nil + *out = make([]GroupIDRange, len(*in)) + copy(*out, *in) } return nil } } +// DeepCopy_extensions_ThirdPartyResource is an autogenerated deepcopy function. func DeepCopy_extensions_ThirdPartyResource(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResource) out := out.(*ThirdPartyResource) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Description = in.Description if in.Versions != nil { in, out := &in.Versions, &out.Versions *out = make([]APIVersion, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Versions = nil + copy(*out, *in) } return nil } } +// DeepCopy_extensions_ThirdPartyResourceData is an autogenerated deepcopy function. func DeepCopy_extensions_ThirdPartyResourceData(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResourceData) out := out.(*ThirdPartyResourceData) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Data != nil { in, out := &in.Data, &out.Data *out = make([]byte, len(*in)) copy(*out, *in) - } else { - out.Data = nil } return nil } } +// DeepCopy_extensions_ThirdPartyResourceDataList is an autogenerated deepcopy function. func DeepCopy_extensions_ThirdPartyResourceDataList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResourceDataList) out := out.(*ThirdPartyResourceDataList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ThirdPartyResourceData, len(*in)) @@ -1117,19 +1111,17 @@ func DeepCopy_extensions_ThirdPartyResourceDataList(in interface{}, out interfac return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_extensions_ThirdPartyResourceList is an autogenerated deepcopy function. func DeepCopy_extensions_ThirdPartyResourceList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ThirdPartyResourceList) out := out.(*ThirdPartyResourceList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ThirdPartyResource, len(*in)) @@ -1138,9 +1130,17 @@ func DeepCopy_extensions_ThirdPartyResourceList(in interface{}, out interface{}, return err } } - } else { - out.Items = nil } return nil } } + +// DeepCopy_extensions_UserIDRange is an autogenerated deepcopy function. +func DeepCopy_extensions_UserIDRange(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*UserIDRange) + out := out.(*UserIDRange) + *out = *in + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/BUILD b/vendor/k8s.io/client-go/pkg/apis/networking/BUILD new file mode 100644 index 0000000000..bcb0a04849 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/OWNERS b/vendor/k8s.io/client-go/pkg/apis/networking/OWNERS new file mode 100755 index 0000000000..97bde97282 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/OWNERS @@ -0,0 +1,4 @@ +reviewers: +- caseydavenport +- danwinship +- thockin diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/doc.go b/vendor/k8s.io/client-go/pkg/apis/networking/doc.go new file mode 100644 index 0000000000..bf91d786a2 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=networking.k8s.io +package networking diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/register.go b/vendor/k8s.io/client-go/pkg/apis/networking/register.go new file mode 100644 index 0000000000..4d58a210da --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/register.go @@ -0,0 +1,51 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package networking + +import ( + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "networking.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) + AddToScheme = SchemeBuilder.AddToScheme +) + +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &NetworkPolicy{}, + &NetworkPolicyList{}, + ) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/types.go b/vendor/k8s.io/client-go/pkg/apis/networking/types.go new file mode 100644 index 0000000000..010736f1b6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/types.go @@ -0,0 +1,115 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package networking + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/client-go/pkg/api" +) + +// +genclient=true + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +type NetworkPolicy struct { + metav1.TypeMeta + // +optional + metav1.ObjectMeta + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + Spec NetworkPolicySpec +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +type NetworkPolicySpec struct { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + PodSelector metav1.LabelSelector + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + Ingress []NetworkPolicyIngressRule +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +type NetworkPolicyIngressRule struct { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + Ports []NetworkPolicyPort + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + From []NetworkPolicyPeer +} + +// NetworkPolicyPort describes a port to allow traffic on +type NetworkPolicyPort struct { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + Protocol *api.Protocol + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + Port *intstr.IntOrString +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +type NetworkPolicyPeer struct { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + PodSelector *metav1.LabelSelector + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + NamespaceSelector *metav1.LabelSelector +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +type NetworkPolicyList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + Items []NetworkPolicy +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/BUILD b/vendor/k8s.io/client-go/pkg/apis/networking/v1/BUILD new file mode 100644 index 0000000000..b55e1b8cb2 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/BUILD @@ -0,0 +1,40 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/networking:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/conversion.go new file mode 100644 index 0000000000..21ec62576d --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/conversion.go @@ -0,0 +1,195 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api" + "k8s.io/client-go/pkg/api/v1" + "k8s.io/client-go/pkg/apis/extensions" +) + +func addConversionFuncs(scheme *runtime.Scheme) error { + return scheme.AddConversionFuncs( + Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy, + Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy, + Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule, + Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule, + Convert_v1_NetworkPolicyList_To_extensions_NetworkPolicyList, + Convert_extensions_NetworkPolicyList_To_v1_NetworkPolicyList, + Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer, + Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer, + Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort, + Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort, + Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec, + Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec, + ) +} + +func Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy(in *NetworkPolicy, out *extensions.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy(in *extensions.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + return Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec(&in.Spec, &out.Spec, s) +} + +func Convert_v1_NetworkPolicySpec_To_extensions_NetworkPolicySpec(in *NetworkPolicySpec, out *extensions.NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]extensions.NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *extensions.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + if err := s.Convert(&in.PodSelector, &out.PodSelector, 0); err != nil { + return err + } + out.Ingress = make([]NetworkPolicyIngressRule, len(in.Ingress)) + for i := range in.Ingress { + if err := Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(&in.Ingress[i], &out.Ingress[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1_NetworkPolicyIngressRule_To_extensions_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *extensions.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]extensions.NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]extensions.NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *extensions.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = make([]NetworkPolicyPort, len(in.Ports)) + for i := range in.Ports { + if err := Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort(&in.Ports[i], &out.Ports[i], s); err != nil { + return err + } + } + out.From = make([]NetworkPolicyPeer, len(in.From)) + for i := range in.From { + if err := Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(&in.From[i], &out.From[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_v1_NetworkPolicyPeer_To_extensions_NetworkPolicyPeer(in *NetworkPolicyPeer, out *extensions.NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_extensions_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *extensions.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + if in.PodSelector != nil { + out.PodSelector = new(metav1.LabelSelector) + if err := s.Convert(in.PodSelector, out.PodSelector, 0); err != nil { + return err + } + } else { + out.PodSelector = nil + } + if in.NamespaceSelector != nil { + out.NamespaceSelector = new(metav1.LabelSelector) + if err := s.Convert(in.NamespaceSelector, out.NamespaceSelector, 0); err != nil { + return err + } + } else { + out.NamespaceSelector = nil + } + return nil +} + +func Convert_v1_NetworkPolicyPort_To_extensions_NetworkPolicyPort(in *NetworkPolicyPort, out *extensions.NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(api.Protocol) + *out.Protocol = api.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_extensions_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *extensions.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + if in.Protocol != nil { + out.Protocol = new(v1.Protocol) + *out.Protocol = v1.Protocol(*in.Protocol) + } else { + out.Protocol = nil + } + out.Port = in.Port + return nil +} + +func Convert_v1_NetworkPolicyList_To_extensions_NetworkPolicyList(in *NetworkPolicyList, out *extensions.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]extensions.NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_v1_NetworkPolicy_To_extensions_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} + +func Convert_extensions_NetworkPolicyList_To_v1_NetworkPolicyList(in *extensions.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = make([]NetworkPolicy, len(in.Items)) + for i := range in.Items { + if err := Convert_extensions_NetworkPolicy_To_v1_NetworkPolicy(&in.Items[i], &out.Items[i], s); err != nil { + return err + } + } + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/api/defaults.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/defaults.go similarity index 61% rename from vendor/k8s.io/client-go/pkg/api/defaults.go rename to vendor/k8s.io/client-go/pkg/apis/networking/v1/defaults.go index 745f610eef..7567cf751a 100644 --- a/vendor/k8s.io/client-go/pkg/api/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/defaults.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -14,23 +14,21 @@ See the License for the specific language governing permissions and limitations under the License. */ -package api +package v1 import ( - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/client-go/pkg/api/v1" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - return scheme.AddDefaultingFuncs( - func(obj *ListOptions) { - if obj.LabelSelector == nil { - obj.LabelSelector = labels.Everything() - } - if obj.FieldSelector == nil { - obj.FieldSelector = fields.Everything() - } - }, - ) + return RegisterDefaults(scheme) +} + +func SetDefaults_NetworkPolicyPort(obj *NetworkPolicyPort) { + // Default any undefined Protocol fields to TCP. + if obj.Protocol == nil { + proto := v1.ProtocolTCP + obj.Protocol = &proto + } } diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/doc.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/doc.go new file mode 100644 index 0000000000..f1250e70e5 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=networking.k8s.io +package v1 diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go new file mode 100644 index 0000000000..671557dd56 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.pb.go @@ -0,0 +1,1345 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/networking/v1/generated.proto + + It has these top-level messages: + NetworkPolicy + NetworkPolicyIngressRule + NetworkPolicyList + NetworkPolicyPeer + NetworkPolicyPort + NetworkPolicySpec +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" + +import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *NetworkPolicy) Reset() { *m = NetworkPolicy{} } +func (*NetworkPolicy) ProtoMessage() {} +func (*NetworkPolicy) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *NetworkPolicyIngressRule) Reset() { *m = NetworkPolicyIngressRule{} } +func (*NetworkPolicyIngressRule) ProtoMessage() {} +func (*NetworkPolicyIngressRule) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{1} +} + +func (m *NetworkPolicyList) Reset() { *m = NetworkPolicyList{} } +func (*NetworkPolicyList) ProtoMessage() {} +func (*NetworkPolicyList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func (m *NetworkPolicyPeer) Reset() { *m = NetworkPolicyPeer{} } +func (*NetworkPolicyPeer) ProtoMessage() {} +func (*NetworkPolicyPeer) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *NetworkPolicyPort) Reset() { *m = NetworkPolicyPort{} } +func (*NetworkPolicyPort) ProtoMessage() {} +func (*NetworkPolicyPort) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *NetworkPolicySpec) Reset() { *m = NetworkPolicySpec{} } +func (*NetworkPolicySpec) ProtoMessage() {} +func (*NetworkPolicySpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func init() { + proto.RegisterType((*NetworkPolicy)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicy") + proto.RegisterType((*NetworkPolicyIngressRule)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyIngressRule") + proto.RegisterType((*NetworkPolicyList)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyList") + proto.RegisterType((*NetworkPolicyPeer)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyPeer") + proto.RegisterType((*NetworkPolicyPort)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicyPort") + proto.RegisterType((*NetworkPolicySpec)(nil), "k8s.io.client-go.pkg.apis.networking.v1.NetworkPolicySpec") +} +func (m *NetworkPolicy) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicy) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + return i, nil +} + +func (m *NetworkPolicyIngressRule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyIngressRule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Ports) > 0 { + for _, msg := range m.Ports { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.From) > 0 { + for _, msg := range m.From { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *NetworkPolicyList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *NetworkPolicyPeer) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyPeer) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.PodSelector != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n4, err := m.PodSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + } + if m.NamespaceSelector != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.NamespaceSelector.Size())) + n5, err := m.NamespaceSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + } + return i, nil +} + +func (m *NetworkPolicyPort) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicyPort) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if m.Protocol != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(*m.Protocol))) + i += copy(dAtA[i:], *m.Protocol) + } + if m.Port != nil { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Port.Size())) + n6, err := m.Port.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + } + return i, nil +} + +func (m *NetworkPolicySpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *NetworkPolicySpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PodSelector.Size())) + n7, err := m.PodSelector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + if len(m.Ingress) > 0 { + for _, msg := range m.Ingress { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *NetworkPolicy) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *NetworkPolicyIngressRule) Size() (n int) { + var l int + _ = l + if len(m.Ports) > 0 { + for _, e := range m.Ports { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.From) > 0 { + for _, e := range m.From { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *NetworkPolicyList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *NetworkPolicyPeer) Size() (n int) { + var l int + _ = l + if m.PodSelector != nil { + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + if m.NamespaceSelector != nil { + l = m.NamespaceSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *NetworkPolicyPort) Size() (n int) { + var l int + _ = l + if m.Protocol != nil { + l = len(*m.Protocol) + n += 1 + l + sovGenerated(uint64(l)) + } + if m.Port != nil { + l = m.Port.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + return n +} + +func (m *NetworkPolicySpec) Size() (n int) { + var l int + _ = l + l = m.PodSelector.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Ingress) > 0 { + for _, e := range m.Ingress { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *NetworkPolicy) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicy{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "NetworkPolicySpec", "NetworkPolicySpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyIngressRule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyIngressRule{`, + `Ports:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ports), "NetworkPolicyPort", "NetworkPolicyPort", 1), `&`, ``, 1) + `,`, + `From:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.From), "NetworkPolicyPeer", "NetworkPolicyPeer", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "NetworkPolicy", "NetworkPolicy", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyPeer) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyPeer{`, + `PodSelector:` + strings.Replace(fmt.Sprintf("%v", this.PodSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `NamespaceSelector:` + strings.Replace(fmt.Sprintf("%v", this.NamespaceSelector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicyPort) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicyPort{`, + `Protocol:` + valueToStringGenerated(this.Protocol) + `,`, + `Port:` + strings.Replace(fmt.Sprintf("%v", this.Port), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `}`, + }, "") + return s +} +func (this *NetworkPolicySpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&NetworkPolicySpec{`, + `PodSelector:` + strings.Replace(strings.Replace(this.PodSelector.String(), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1), `&`, ``, 1) + `,`, + `Ingress:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Ingress), "NetworkPolicyIngressRule", "NetworkPolicyIngressRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *NetworkPolicy) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicy: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicy: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyIngressRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyIngressRule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyIngressRule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ports", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ports = append(m.Ports, NetworkPolicyPort{}) + if err := m.Ports[len(m.Ports)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field From", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.From = append(m.From, NetworkPolicyPeer{}) + if err := m.From[len(m.From)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, NetworkPolicy{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyPeer) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyPeer: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyPeer: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.PodSelector == nil { + m.PodSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NamespaceSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.NamespaceSelector == nil { + m.NamespaceSelector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.NamespaceSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicyPort) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicyPort: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicyPort: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Protocol", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + s := k8s_io_kubernetes_pkg_api_v1.Protocol(dAtA[iNdEx:postIndex]) + m.Protocol = &s + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Port", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Port == nil { + m.Port = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.Port.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *NetworkPolicySpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: NetworkPolicySpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: NetworkPolicySpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PodSelector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.PodSelector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Ingress", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Ingress = append(m.Ingress, NetworkPolicyIngressRule{}) + if err := m.Ingress[len(m.Ingress)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/networking/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 666 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x54, 0xcf, 0x4f, 0x13, 0x41, + 0x18, 0xed, 0x56, 0x08, 0x75, 0x90, 0x20, 0x6b, 0x4c, 0x1a, 0x0e, 0x5b, 0xd2, 0xc4, 0x84, 0x83, + 0xce, 0x5a, 0xf1, 0x07, 0xc6, 0x78, 0xd9, 0x83, 0x09, 0x89, 0x42, 0x5d, 0x6e, 0x06, 0x13, 0xa6, + 0xcb, 0xc7, 0x32, 0xb4, 0x3b, 0xb3, 0x99, 0x99, 0x56, 0xb8, 0xf9, 0x27, 0xf8, 0xd7, 0xf8, 0x37, + 0x70, 0x93, 0x23, 0x89, 0x49, 0x23, 0xeb, 0xdd, 0x9b, 0x17, 0x4f, 0x66, 0x76, 0xa7, 0x6c, 0x61, + 0x59, 0x24, 0xc5, 0xdb, 0xcc, 0xe4, 0x7b, 0xef, 0x7d, 0x6f, 0xde, 0x37, 0x83, 0x56, 0xbb, 0xab, + 0x12, 0x53, 0xee, 0x76, 0xfb, 0x1d, 0x10, 0x0c, 0x14, 0x48, 0x37, 0xee, 0x86, 0x2e, 0x89, 0xa9, + 0x74, 0x19, 0xa8, 0x4f, 0x5c, 0x74, 0x29, 0x0b, 0xdd, 0x41, 0xcb, 0x0d, 0x81, 0x81, 0x20, 0x0a, + 0x76, 0x70, 0x2c, 0xb8, 0xe2, 0xf6, 0x72, 0x86, 0xc4, 0x39, 0x12, 0xc7, 0xdd, 0x10, 0x6b, 0x24, + 0xce, 0x91, 0x78, 0xd0, 0x5a, 0x7c, 0x14, 0x52, 0xb5, 0xd7, 0xef, 0xe0, 0x80, 0x47, 0x6e, 0xc8, + 0x43, 0xee, 0xa6, 0x04, 0x9d, 0xfe, 0x6e, 0xba, 0x4b, 0x37, 0xe9, 0x2a, 0x23, 0x5e, 0x7c, 0x6a, + 0x5a, 0x22, 0x31, 0x8d, 0x48, 0xb0, 0x47, 0x19, 0x88, 0xc3, 0xbc, 0xa9, 0x08, 0x14, 0xb9, 0xa4, + 0x9d, 0x45, 0xb7, 0x0c, 0x25, 0xfa, 0x4c, 0xd1, 0x08, 0x0a, 0x80, 0xe7, 0xff, 0x02, 0xc8, 0x60, + 0x0f, 0x22, 0x52, 0xc0, 0xad, 0x94, 0xe1, 0xfa, 0x8a, 0xf6, 0x5c, 0xca, 0x94, 0x54, 0xa2, 0x00, + 0x7a, 0x58, 0x7a, 0xcd, 0x97, 0x79, 0x79, 0x7d, 0x45, 0x28, 0x70, 0xa0, 0x80, 0x49, 0xca, 0x99, + 0x74, 0x07, 0xad, 0x0e, 0x28, 0x52, 0x84, 0xbf, 0xbc, 0x02, 0x1e, 0xf3, 0x1e, 0x0d, 0x0e, 0xcb, + 0xa0, 0xcd, 0x63, 0x0b, 0xcd, 0xad, 0x67, 0xe1, 0xb5, 0xd3, 0x4a, 0x7b, 0x1b, 0xd5, 0xf4, 0x95, + 0xef, 0x10, 0x45, 0xea, 0xd6, 0x92, 0xb5, 0x3c, 0xfb, 0xe4, 0x31, 0x36, 0xc9, 0x8f, 0xdf, 0x40, + 0x9e, 0xbd, 0xae, 0xc6, 0x83, 0x16, 0xde, 0xe8, 0xec, 0x43, 0xa0, 0xde, 0x81, 0x22, 0x9e, 0x7d, + 0x34, 0x6c, 0x54, 0x92, 0x61, 0x03, 0xe5, 0x67, 0xfe, 0x19, 0xab, 0xfd, 0x11, 0x4d, 0xc9, 0x18, + 0x82, 0x7a, 0x35, 0x65, 0x7f, 0x85, 0xaf, 0x3b, 0x57, 0xf8, 0x5c, 0xa3, 0x9b, 0x31, 0x04, 0xde, + 0x1d, 0x23, 0x34, 0xa5, 0x77, 0x7e, 0x4a, 0xdb, 0xfc, 0x6e, 0xa1, 0xfa, 0xb9, 0xca, 0x35, 0x16, + 0x0a, 0x90, 0xd2, 0xef, 0xf7, 0xc0, 0xde, 0x46, 0xd3, 0x31, 0x17, 0x4a, 0xd6, 0xad, 0xa5, 0x5b, + 0x37, 0x10, 0x6f, 0x73, 0xa1, 0xbc, 0x39, 0x23, 0x3e, 0xad, 0x77, 0xd2, 0xcf, 0x88, 0xb5, 0xbb, + 0x5d, 0xc1, 0xa3, 0x7a, 0xf5, 0x66, 0x02, 0x00, 0x22, 0x77, 0xf7, 0x46, 0xf0, 0xc8, 0x4f, 0x69, + 0x9b, 0xdf, 0x2c, 0xb4, 0x70, 0xae, 0xf2, 0x2d, 0x95, 0xca, 0xde, 0x2a, 0x84, 0x86, 0xaf, 0x17, + 0x9a, 0x46, 0xa7, 0x91, 0xdd, 0x35, 0x5a, 0xb5, 0xd1, 0xc9, 0x58, 0x60, 0x5b, 0x68, 0x9a, 0x2a, + 0x88, 0xa4, 0xf1, 0xf4, 0x62, 0x42, 0x4f, 0xf9, 0x85, 0xad, 0x69, 0x36, 0x3f, 0x23, 0x6d, 0xfe, + 0xbe, 0xe8, 0x48, 0x7b, 0xb7, 0x77, 0xd1, 0x6c, 0xcc, 0x77, 0x36, 0xa1, 0x07, 0x81, 0xe2, 0xc2, + 0x98, 0x5a, 0xb9, 0xa6, 0x29, 0xd2, 0x81, 0xde, 0x08, 0xea, 0xcd, 0x27, 0xc3, 0xc6, 0x6c, 0x3b, + 0xe7, 0xf2, 0xc7, 0x89, 0xed, 0x03, 0xb4, 0xc0, 0x48, 0x04, 0x32, 0x26, 0x01, 0x9c, 0xa9, 0x55, + 0x27, 0x57, 0xbb, 0x9f, 0x0c, 0x1b, 0x0b, 0xeb, 0x17, 0x19, 0xfd, 0xa2, 0x48, 0xf3, 0x6b, 0xc1, + 0x37, 0x17, 0xca, 0x7e, 0x8f, 0x6a, 0xe9, 0xcb, 0x0c, 0x78, 0x2f, 0x35, 0x7d, 0xdb, 0x7b, 0xa6, + 0x53, 0x69, 0x9b, 0xb3, 0x3f, 0xc3, 0xc6, 0x83, 0xab, 0xbe, 0x16, 0x3c, 0x2a, 0xf4, 0xcf, 0x68, + 0xec, 0x75, 0x34, 0xa5, 0x47, 0xd3, 0xb8, 0x2a, 0x7f, 0xcd, 0xfa, 0x3f, 0xc3, 0xd9, 0x7f, 0x86, + 0xd7, 0x98, 0xda, 0x10, 0x9b, 0x4a, 0x50, 0x16, 0x7a, 0x35, 0x3d, 0x82, 0xba, 0x39, 0x3f, 0xe5, + 0x69, 0xfe, 0xba, 0xd8, 0xb8, 0x7e, 0x7c, 0xf6, 0xfe, 0x7f, 0x0b, 0xec, 0x9e, 0x19, 0x93, 0xf2, + 0xd0, 0x22, 0x34, 0x43, 0xb3, 0x47, 0x6d, 0x46, 0xd2, 0x9b, 0x70, 0x24, 0xc7, 0xbe, 0x06, 0x6f, + 0xde, 0xc8, 0xce, 0x8c, 0x0e, 0x47, 0x1a, 0xde, 0xf2, 0xd1, 0xa9, 0x53, 0x39, 0x3e, 0x75, 0x2a, + 0x27, 0xa7, 0x4e, 0xe5, 0x73, 0xe2, 0x58, 0x47, 0x89, 0x63, 0x1d, 0x27, 0x8e, 0x75, 0x92, 0x38, + 0xd6, 0x8f, 0xc4, 0xb1, 0xbe, 0xfc, 0x74, 0x2a, 0x1f, 0xaa, 0x83, 0xd6, 0xdf, 0x00, 0x00, 0x00, + 0xff, 0xff, 0xfa, 0x8d, 0x62, 0x1f, 0x5e, 0x07, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.proto new file mode 100644 index 0000000000..3170b55f8b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/generated.proto @@ -0,0 +1,127 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.networking.v1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; +import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/extensions/v1beta1/generated.proto"; +import "k8s.io/kubernetes/pkg/apis/policy/v1beta1/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +message NetworkPolicy { + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + optional NetworkPolicySpec spec = 2; +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +message NetworkPolicyIngressRule { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + repeated NetworkPolicyPort ports = 1; + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + repeated NetworkPolicyPeer from = 2; +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +message NetworkPolicyList { + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of schema objects. + repeated NetworkPolicy items = 2; +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +message NetworkPolicyPeer { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector namespaceSelector = 2; +} + +// NetworkPolicyPort describes a port to allow traffic on +message NetworkPolicyPort { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + optional string protocol = 1; + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString port = 2; +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +message NetworkPolicySpec { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector podSelector = 1; + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + repeated NetworkPolicyIngressRule ingress = 2; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/register.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/register.go new file mode 100644 index 0000000000..c8d3c83bcc --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/register.go @@ -0,0 +1,50 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "networking.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs, addConversionFuncs) + AddToScheme = SchemeBuilder.AddToScheme +) + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &NetworkPolicy{}, + &NetworkPolicyList{}, + ) + + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go new file mode 100644 index 0000000000..da04aee421 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/types.generated.go @@ -0,0 +1,2322 @@ +/* +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" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + pkg4_intstr "k8s.io/apimachinery/pkg/util/intstr" + pkg3_v1 "k8s.io/client-go/pkg/api/v1" + "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 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 pkg4_intstr.IntOrString + var v3 pkg3_v1.Protocol + var v4 time.Time + _, _, _, _, _ = v0, v1, v2, v3, v4 + } +} + +func (x *NetworkPolicy) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("spec")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicy) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicy) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "spec": + if r.TryDecodeAsNil() { + x.Spec = NetworkPolicySpec{} + } else { + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicy) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj11 int + var yyb11 bool + var yyhl11 bool = l >= 0 + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv12 := &x.Kind + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*string)(yyv12)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv14 := &x.APIVersion + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv16 := &x.ObjectMeta + yym17 := z.DecBinary() + _ = yym17 + if false { + } else if z.HasExtensions() && z.DecExt(yyv16) { + } else { + z.DecFallback(yyv16, false) + } + } + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Spec = NetworkPolicySpec{} + } else { + yyv18 := &x.Spec + yyv18.CodecDecodeSelf(d) + } + for { + yyj11++ + if yyhl11 { + yyb11 = yyj11 > l + } else { + yyb11 = r.CheckBreak() + } + if yyb11 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj11-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicySpec) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.Ingress) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy4 := &x.PodSelector + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(yy4) { + } else { + z.EncFallback(yy4) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy6 := &x.PodSelector + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(yy6) { + } else { + z.EncFallback(yy6) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Ingress == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else { + h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ingress")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ingress == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + h.encSliceNetworkPolicyIngressRule(([]NetworkPolicyIngressRule)(x.Ingress), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicySpec) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicySpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "podSelector": + if r.TryDecodeAsNil() { + x.PodSelector = pkg1_v1.LabelSelector{} + } else { + yyv4 := &x.PodSelector + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else { + z.DecFallback(yyv4, false) + } + } + case "ingress": + if r.TryDecodeAsNil() { + x.Ingress = nil + } else { + yyv6 := &x.Ingress + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv6), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicySpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.PodSelector = pkg1_v1.LabelSelector{} + } else { + yyv9 := &x.PodSelector + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(yyv9) { + } else { + z.DecFallback(yyv9, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ingress = nil + } else { + yyv11 := &x.Ingress + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + h.decSliceNetworkPolicyIngressRule((*[]NetworkPolicyIngressRule)(yyv11), d) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyIngressRule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = len(x.Ports) != 0 + yyq2[1] = len(x.From) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Ports == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("ports")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Ports == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + h.encSliceNetworkPolicyPort(([]NetworkPolicyPort)(x.Ports), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.From == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("from")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.From == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + h.encSliceNetworkPolicyPeer(([]NetworkPolicyPeer)(x.From), e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyIngressRule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyIngressRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "ports": + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv4 := &x.Ports + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv4), d) + } + } + case "from": + if r.TryDecodeAsNil() { + x.From = nil + } else { + yyv6 := &x.From + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv6), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyIngressRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Ports = nil + } else { + yyv9 := &x.Ports + yym10 := z.DecBinary() + _ = yym10 + if false { + } else { + h.decSliceNetworkPolicyPort((*[]NetworkPolicyPort)(yyv9), d) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.From = nil + } else { + yyv11 := &x.From + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + h.decSliceNetworkPolicyPeer((*[]NetworkPolicyPeer)(yyv11), d) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyPort) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Protocol != nil + yyq2[1] = x.Port != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.Protocol == nil { + r.EncodeNil() + } else { + yy4 := *x.Protocol + yysf5 := &yy4 + yysf5.CodecEncodeSelf(e) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("protocol")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Protocol == nil { + r.EncodeNil() + } else { + yy6 := *x.Protocol + yysf7 := &yy6 + yysf7.CodecEncodeSelf(e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.Port == nil { + r.EncodeNil() + } else { + yym9 := z.EncBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.EncExt(x.Port) { + } else if !yym9 && z.IsJSONHandle() { + z.EncJSONMarshal(x.Port) + } else { + z.EncFallback(x.Port) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("port")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Port == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.Port) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(x.Port) + } else { + z.EncFallback(x.Port) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyPort) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyPort) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "protocol": + if r.TryDecodeAsNil() { + if x.Protocol != nil { + x.Protocol = nil + } + } else { + if x.Protocol == nil { + x.Protocol = new(pkg3_v1.Protocol) + } + x.Protocol.CodecDecodeSelf(d) + } + case "port": + if r.TryDecodeAsNil() { + if x.Port != nil { + x.Port = nil + } + } else { + if x.Port == nil { + x.Port = new(pkg4_intstr.IntOrString) + } + yym6 := z.DecBinary() + _ = yym6 + if false { + } else if z.HasExtensions() && z.DecExt(x.Port) { + } else if !yym6 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.Port) + } else { + z.DecFallback(x.Port, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyPort) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj7 int + var yyb7 bool + var yyhl7 bool = l >= 0 + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Protocol != nil { + x.Protocol = nil + } + } else { + if x.Protocol == nil { + x.Protocol = new(pkg3_v1.Protocol) + } + x.Protocol.CodecDecodeSelf(d) + } + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.Port != nil { + x.Port = nil + } + } else { + if x.Port == nil { + x.Port = new(pkg4_intstr.IntOrString) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.Port) { + } else if !yym10 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.Port) + } else { + z.DecFallback(x.Port, false) + } + } + for { + yyj7++ + if yyhl7 { + yyb7 = yyj7 > l + } else { + yyb7 = r.CheckBreak() + } + if yyb7 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj7-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyPeer) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [2]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.PodSelector != nil + yyq2[1] = x.NamespaceSelector != nil + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(2) + } else { + yynn2 = 0 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + if x.PodSelector == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodSelector) { + } else { + z.EncFallback(x.PodSelector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("podSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.PodSelector == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.PodSelector) { + } else { + z.EncFallback(x.PodSelector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.NamespaceSelector == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { + } else { + z.EncFallback(x.NamespaceSelector) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespaceSelector")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.NamespaceSelector == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else if z.HasExtensions() && z.EncExt(x.NamespaceSelector) { + } else { + z.EncFallback(x.NamespaceSelector) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyPeer) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyPeer) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "podSelector": + if r.TryDecodeAsNil() { + if x.PodSelector != nil { + x.PodSelector = nil + } + } else { + if x.PodSelector == nil { + x.PodSelector = new(pkg1_v1.LabelSelector) + } + yym5 := z.DecBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodSelector) { + } else { + z.DecFallback(x.PodSelector, false) + } + } + case "namespaceSelector": + if r.TryDecodeAsNil() { + if x.NamespaceSelector != nil { + x.NamespaceSelector = nil + } + } else { + if x.NamespaceSelector == nil { + x.NamespaceSelector = new(pkg1_v1.LabelSelector) + } + yym7 := z.DecBinary() + _ = yym7 + if false { + } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { + } else { + z.DecFallback(x.NamespaceSelector, false) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyPeer) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj8 int + var yyb8 bool + var yyhl8 bool = l >= 0 + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.PodSelector != nil { + x.PodSelector = nil + } + } else { + if x.PodSelector == nil { + x.PodSelector = new(pkg1_v1.LabelSelector) + } + yym10 := z.DecBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.DecExt(x.PodSelector) { + } else { + z.DecFallback(x.PodSelector, false) + } + } + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.NamespaceSelector != nil { + x.NamespaceSelector = nil + } + } else { + if x.NamespaceSelector == nil { + x.NamespaceSelector = new(pkg1_v1.LabelSelector) + } + yym12 := z.DecBinary() + _ = yym12 + if false { + } else if z.HasExtensions() && z.DecExt(x.NamespaceSelector) { + } else { + z.DecFallback(x.NamespaceSelector, false) + } + } + for { + yyj8++ + if yyhl8 { + yyb8 = yyj8 > l + } else { + yyb8 = r.CheckBreak() + } + if yyb8 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj8-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *NetworkPolicyList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceNetworkPolicy(([]NetworkPolicy)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceNetworkPolicy(([]NetworkPolicy)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *NetworkPolicyList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *NetworkPolicyList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *NetworkPolicyList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceNetworkPolicy((*[]NetworkPolicy)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSliceNetworkPolicyIngressRule(v []NetworkPolicyIngressRule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyIngressRule(v *[]NetworkPolicyIngressRule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 48) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyIngressRule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyIngressRule{}) // var yyz1 NetworkPolicyIngressRule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyIngressRule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyIngressRule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicyPort(v []NetworkPolicyPort, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyPort(v *[]NetworkPolicyPort, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyPort, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyPort, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPort{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPort{}) // var yyz1 NetworkPolicyPort + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPort{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPort{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicyPeer(v []NetworkPolicyPeer, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicyPeer(v *[]NetworkPolicyPeer, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 16) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicyPeer, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicyPeer, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicyPeer{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicyPeer{}) // var yyz1 NetworkPolicyPeer + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicyPeer{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicyPeer{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceNetworkPolicy(v []NetworkPolicy, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceNetworkPolicy(v *[]NetworkPolicy, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 320) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]NetworkPolicy, yyrl1) + } + } else { + yyv1 = make([]NetworkPolicy, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, NetworkPolicy{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, NetworkPolicy{}) // var yyz1 NetworkPolicy + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = NetworkPolicy{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []NetworkPolicy{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/types.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/types.go new file mode 100644 index 0000000000..a31026a67d --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/types.go @@ -0,0 +1,120 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" + "k8s.io/client-go/pkg/api/v1" +) + +// +genclient=true + +// NetworkPolicy describes what network traffic is allowed for a set of Pods +type NetworkPolicy struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Specification of the desired behavior for this NetworkPolicy. + // +optional + Spec NetworkPolicySpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` +} + +// NetworkPolicySpec provides the specification of a NetworkPolicy +type NetworkPolicySpec struct { + // Selects the pods to which this NetworkPolicy object applies. The array of + // ingress rules is applied to any pods selected by this field. Multiple network + // policies can select the same set of pods. In this case, the ingress rules for + // each are combined additively. This field is NOT optional and follows standard + // label selector semantics. An empty podSelector matches all pods in this + // namespace. + PodSelector metav1.LabelSelector `json:"podSelector" protobuf:"bytes,1,opt,name=podSelector"` + + // List of ingress rules to be applied to the selected pods. Traffic is allowed to + // a pod if there are no NetworkPolicies selecting the pod + // (and cluster policy otherwise allows the traffic), OR if the traffic source is + // the pod's local node, OR if the traffic matches at least one ingress rule + // across all of the NetworkPolicy objects whose podSelector matches the pod. If + // this field is empty then this NetworkPolicy does not allow any traffic (and serves + // solely to ensure that the pods it selects are isolated by default) + // +optional + Ingress []NetworkPolicyIngressRule `json:"ingress,omitempty" protobuf:"bytes,2,rep,name=ingress"` +} + +// NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods +// matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from. +type NetworkPolicyIngressRule struct { + // List of ports which should be made accessible on the pods selected for this + // rule. Each item in this list is combined using a logical OR. If this field is + // empty or missing, this rule matches all ports (traffic not restricted by port). + // If this field is present and contains at least one item, then this rule allows + // traffic only if the traffic matches at least one port in the list. + // +optional + Ports []NetworkPolicyPort `json:"ports,omitempty" protobuf:"bytes,1,rep,name=ports"` + + // List of sources which should be able to access the pods selected for this rule. + // Items in this list are combined using a logical OR operation. If this field is + // empty or missing, this rule matches all sources (traffic not restricted by + // source). If this field is present and contains at least on item, this rule + // allows traffic only if the traffic matches at least one item in the from list. + // +optional + From []NetworkPolicyPeer `json:"from,omitempty" protobuf:"bytes,2,rep,name=from"` +} + +// NetworkPolicyPort describes a port to allow traffic on +type NetworkPolicyPort struct { + // The protocol (TCP or UDP) which traffic must match. If not specified, this + // field defaults to TCP. + // +optional + Protocol *v1.Protocol `json:"protocol,omitempty" protobuf:"bytes,1,opt,name=protocol,casttype=k8s.io/kubernetes/pkg/api/v1.Protocol"` + + // The port on the given protocol. This can either be a numerical or named port on + // a pod. If this field is not provided, this matches all port names and numbers. + // +optional + Port *intstr.IntOrString `json:"port,omitempty" protobuf:"bytes,2,opt,name=port"` +} + +// NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields +// must be specified. +type NetworkPolicyPeer struct { + // This is a label selector which selects Pods in this namespace. This field + // follows standard label selector semantics. If present but empty, this selector + // selects all pods in this namespace. + // +optional + PodSelector *metav1.LabelSelector `json:"podSelector,omitempty" protobuf:"bytes,1,opt,name=podSelector"` + + // Selects Namespaces using cluster scoped-labels. This matches all pods in all + // namespaces selected by this label selector. This field follows standard label + // selector semantics. If present but empty, this selector selects all namespaces. + // +optional + NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty" protobuf:"bytes,2,opt,name=namespaceSelector"` +} + +// NetworkPolicyList is a list of NetworkPolicy objects. +type NetworkPolicyList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of schema objects. + Items []NetworkPolicy `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..c3c9116313 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/types_swagger_doc_generated.go @@ -0,0 +1,90 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_NetworkPolicy = map[string]string{ + "": "NetworkPolicy describes what network traffic is allowed for a set of Pods", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "spec": "Specification of the desired behavior for this NetworkPolicy.", +} + +func (NetworkPolicy) SwaggerDoc() map[string]string { + return map_NetworkPolicy +} + +var map_NetworkPolicyIngressRule = map[string]string{ + "": "NetworkPolicyIngressRule describes a particular set of traffic that is allowed to the pods matched by a NetworkPolicySpec's podSelector. The traffic must match both ports and from.", + "ports": "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. If this field is empty or missing, this rule matches all ports (traffic not restricted by port). If this field is present and contains at least one item, then this rule allows traffic only if the traffic matches at least one port in the list.", + "from": "List of sources which should be able to access the pods selected for this rule. Items in this list are combined using a logical OR operation. If this field is empty or missing, this rule matches all sources (traffic not restricted by source). If this field is present and contains at least on item, this rule allows traffic only if the traffic matches at least one item in the from list.", +} + +func (NetworkPolicyIngressRule) SwaggerDoc() map[string]string { + return map_NetworkPolicyIngressRule +} + +var map_NetworkPolicyList = map[string]string{ + "": "NetworkPolicyList is a list of NetworkPolicy objects.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "Items is a list of schema objects.", +} + +func (NetworkPolicyList) SwaggerDoc() map[string]string { + return map_NetworkPolicyList +} + +var map_NetworkPolicyPeer = map[string]string{ + "": "NetworkPolicyPeer describes a peer to allow traffic from. Exactly one of its fields must be specified.", + "podSelector": "This is a label selector which selects Pods in this namespace. This field follows standard label selector semantics. If present but empty, this selector selects all pods in this namespace.", + "namespaceSelector": "Selects Namespaces using cluster scoped-labels. This matches all pods in all namespaces selected by this label selector. This field follows standard label selector semantics. If present but empty, this selector selects all namespaces.", +} + +func (NetworkPolicyPeer) SwaggerDoc() map[string]string { + return map_NetworkPolicyPeer +} + +var map_NetworkPolicyPort = map[string]string{ + "": "NetworkPolicyPort describes a port to allow traffic on", + "protocol": "The protocol (TCP or UDP) which traffic must match. If not specified, this field defaults to TCP.", + "port": "The port on the given protocol. This can either be a numerical or named port on a pod. If this field is not provided, this matches all port names and numbers.", +} + +func (NetworkPolicyPort) SwaggerDoc() map[string]string { + return map_NetworkPolicyPort +} + +var map_NetworkPolicySpec = map[string]string{ + "": "NetworkPolicySpec provides the specification of a NetworkPolicy", + "podSelector": "Selects the pods to which this NetworkPolicy object applies. The array of ingress rules is applied to any pods selected by this field. Multiple network policies can select the same set of pods. In this case, the ingress rules for each are combined additively. This field is NOT optional and follows standard label selector semantics. An empty podSelector matches all pods in this namespace.", + "ingress": "List of ingress rules to be applied to the selected pods. Traffic is allowed to a pod if there are no NetworkPolicies selecting the pod (and cluster policy otherwise allows the traffic), OR if the traffic source is the pod's local node, OR if the traffic matches at least one ingress rule across all of the NetworkPolicy objects whose podSelector matches the pod. If this field is empty then this NetworkPolicy does not allow any traffic (and serves solely to ensure that the pods it selects are isolated by default)", +} + +func (NetworkPolicySpec) SwaggerDoc() map[string]string { + return map_NetworkPolicySpec +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go new file mode 100644 index 0000000000..500438e92f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.conversion.go @@ -0,0 +1,195 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api "k8s.io/client-go/pkg/api" + api_v1 "k8s.io/client-go/pkg/api/v1" + networking "k8s.io/client-go/pkg/apis/networking" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1_NetworkPolicy_To_networking_NetworkPolicy, + Convert_networking_NetworkPolicy_To_v1_NetworkPolicy, + Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule, + Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule, + Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList, + Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList, + Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer, + Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer, + Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort, + Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort, + Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec, + Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec, + ) +} + +func autoConvert_v1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_v1_NetworkPolicy_To_networking_NetworkPolicy is an autogenerated conversion function. +func Convert_v1_NetworkPolicy_To_networking_NetworkPolicy(in *NetworkPolicy, out *networking.NetworkPolicy, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicy_To_networking_NetworkPolicy(in, out, s) +} + +func autoConvert_networking_NetworkPolicy_To_v1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_networking_NetworkPolicy_To_v1_NetworkPolicy is an autogenerated conversion function. +func Convert_networking_NetworkPolicy_To_v1_NetworkPolicy(in *networking.NetworkPolicy, out *NetworkPolicy, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicy_To_v1_NetworkPolicy(in, out, s) +} + +func autoConvert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = *(*[]networking.NetworkPolicyPort)(unsafe.Pointer(&in.Ports)) + out.From = *(*[]networking.NetworkPolicyPeer)(unsafe.Pointer(&in.From)) + return nil +} + +// Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule is an autogenerated conversion function. +func Convert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in *NetworkPolicyIngressRule, out *networking.NetworkPolicyIngressRule, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyIngressRule_To_networking_NetworkPolicyIngressRule(in, out, s) +} + +func autoConvert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + out.Ports = *(*[]NetworkPolicyPort)(unsafe.Pointer(&in.Ports)) + out.From = *(*[]NetworkPolicyPeer)(unsafe.Pointer(&in.From)) + return nil +} + +// Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule is an autogenerated conversion function. +func Convert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in *networking.NetworkPolicyIngressRule, out *NetworkPolicyIngressRule, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyIngressRule_To_v1_NetworkPolicyIngressRule(in, out, s) +} + +func autoConvert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]networking.NetworkPolicy)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList is an autogenerated conversion function. +func Convert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in *NetworkPolicyList, out *networking.NetworkPolicyList, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyList_To_networking_NetworkPolicyList(in, out, s) +} + +func autoConvert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]NetworkPolicy, 0) + } else { + out.Items = *(*[]NetworkPolicy)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList is an autogenerated conversion function. +func Convert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in *networking.NetworkPolicyList, out *NetworkPolicyList, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyList_To_v1_NetworkPolicyList(in, out, s) +} + +func autoConvert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + out.PodSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + return nil +} + +// Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer is an autogenerated conversion function. +func Convert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in *NetworkPolicyPeer, out *networking.NetworkPolicyPeer, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyPeer_To_networking_NetworkPolicyPeer(in, out, s) +} + +func autoConvert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + out.PodSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.PodSelector)) + out.NamespaceSelector = (*meta_v1.LabelSelector)(unsafe.Pointer(in.NamespaceSelector)) + return nil +} + +// Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer is an autogenerated conversion function. +func Convert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in *networking.NetworkPolicyPeer, out *NetworkPolicyPeer, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyPeer_To_v1_NetworkPolicyPeer(in, out, s) +} + +func autoConvert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + out.Protocol = (*api.Protocol)(unsafe.Pointer(in.Protocol)) + out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) + return nil +} + +// Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort is an autogenerated conversion function. +func Convert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in *NetworkPolicyPort, out *networking.NetworkPolicyPort, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicyPort_To_networking_NetworkPolicyPort(in, out, s) +} + +func autoConvert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + out.Protocol = (*api_v1.Protocol)(unsafe.Pointer(in.Protocol)) + out.Port = (*intstr.IntOrString)(unsafe.Pointer(in.Port)) + return nil +} + +// Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort is an autogenerated conversion function. +func Convert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in *networking.NetworkPolicyPort, out *NetworkPolicyPort, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicyPort_To_v1_NetworkPolicyPort(in, out, s) +} + +func autoConvert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + out.PodSelector = in.PodSelector + out.Ingress = *(*[]networking.NetworkPolicyIngressRule)(unsafe.Pointer(&in.Ingress)) + return nil +} + +// Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec is an autogenerated conversion function. +func Convert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in *NetworkPolicySpec, out *networking.NetworkPolicySpec, s conversion.Scope) error { + return autoConvert_v1_NetworkPolicySpec_To_networking_NetworkPolicySpec(in, out, s) +} + +func autoConvert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + out.PodSelector = in.PodSelector + out.Ingress = *(*[]NetworkPolicyIngressRule)(unsafe.Pointer(&in.Ingress)) + return nil +} + +// Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec is an autogenerated conversion function. +func Convert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in *networking.NetworkPolicySpec, out *NetworkPolicySpec, s conversion.Scope) error { + return autoConvert_networking_NetworkPolicySpec_To_v1_NetworkPolicySpec(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..6d9b335d42 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.deepcopy.go @@ -0,0 +1,182 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api_v1 "k8s.io/client-go/pkg/api/v1" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyPeer, InType: reflect.TypeOf(&NetworkPolicyPeer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicyPort, InType: reflect.TypeOf(&NetworkPolicyPort{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_NetworkPolicySpec, InType: reflect.TypeOf(&NetworkPolicySpec{})}, + ) +} + +// DeepCopy_v1_NetworkPolicy is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicy) + out := out.(*NetworkPolicy) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if err := DeepCopy_v1_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyIngressRule is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyIngressRule) + out := out.(*NetworkPolicyIngressRule) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]NetworkPolicyPort, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyPort(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.From != nil { + in, out := &in.From, &out.From + *out = make([]NetworkPolicyPeer, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyPeer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyList is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyList) + out := out.(*NetworkPolicyList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]NetworkPolicy, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicy(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyPeer is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPeer) + out := out.(*NetworkPolicyPeer) + *out = *in + if in.PodSelector != nil { + in, out := &in.PodSelector, &out.PodSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.LabelSelector) + } + } + if in.NamespaceSelector != nil { + in, out := &in.NamespaceSelector, &out.NamespaceSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*meta_v1.LabelSelector) + } + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicyPort is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPort) + out := out.(*NetworkPolicyPort) + *out = *in + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(api_v1.Protocol) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_v1_NetworkPolicySpec is an autogenerated deepcopy function. +func DeepCopy_v1_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicySpec) + out := out.(*NetworkPolicySpec) + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { + return err + } else { + out.PodSelector = *newVal.(*meta_v1.LabelSelector) + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]NetworkPolicyIngressRule, len(*in)) + for i := range *in { + if err := DeepCopy_v1_NetworkPolicyIngressRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go new file mode 100644 index 0000000000..0319c88a76 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/v1/zz_generated.defaults.go @@ -0,0 +1,51 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&NetworkPolicy{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicy(obj.(*NetworkPolicy)) }) + scheme.AddTypeDefaultingFunc(&NetworkPolicyList{}, func(obj interface{}) { SetObjectDefaults_NetworkPolicyList(obj.(*NetworkPolicyList)) }) + return nil +} + +func SetObjectDefaults_NetworkPolicy(in *NetworkPolicy) { + for i := range in.Spec.Ingress { + a := &in.Spec.Ingress[i] + for j := range a.Ports { + b := &a.Ports[j] + SetDefaults_NetworkPolicyPort(b) + } + } +} + +func SetObjectDefaults_NetworkPolicyList(in *NetworkPolicyList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_NetworkPolicy(a) + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go new file mode 100644 index 0000000000..802868447c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/networking/zz_generated.deepcopy.go @@ -0,0 +1,182 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package networking + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" + api "k8s.io/client-go/pkg/api" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicy, InType: reflect.TypeOf(&NetworkPolicy{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyIngressRule, InType: reflect.TypeOf(&NetworkPolicyIngressRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyList, InType: reflect.TypeOf(&NetworkPolicyList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyPeer, InType: reflect.TypeOf(&NetworkPolicyPeer{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicyPort, InType: reflect.TypeOf(&NetworkPolicyPort{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_networking_NetworkPolicySpec, InType: reflect.TypeOf(&NetworkPolicySpec{})}, + ) +} + +// DeepCopy_networking_NetworkPolicy is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicy(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicy) + out := out.(*NetworkPolicy) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_networking_NetworkPolicySpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyIngressRule is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyIngressRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyIngressRule) + out := out.(*NetworkPolicyIngressRule) + *out = *in + if in.Ports != nil { + in, out := &in.Ports, &out.Ports + *out = make([]NetworkPolicyPort, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyPort(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.From != nil { + in, out := &in.From, &out.From + *out = make([]NetworkPolicyPeer, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyPeer(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyList is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyList) + out := out.(*NetworkPolicyList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]NetworkPolicy, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicy(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyPeer is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyPeer(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPeer) + out := out.(*NetworkPolicyPeer) + *out = *in + if in.PodSelector != nil { + in, out := &in.PodSelector, &out.PodSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + if in.NamespaceSelector != nil { + in, out := &in.NamespaceSelector, &out.NamespaceSelector + if newVal, err := c.DeepCopy(*in); err != nil { + return err + } else { + *out = newVal.(*v1.LabelSelector) + } + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicyPort is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicyPort(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicyPort) + out := out.(*NetworkPolicyPort) + *out = *in + if in.Protocol != nil { + in, out := &in.Protocol, &out.Protocol + *out = new(api.Protocol) + **out = **in + } + if in.Port != nil { + in, out := &in.Port, &out.Port + *out = new(intstr.IntOrString) + **out = **in + } + return nil + } +} + +// DeepCopy_networking_NetworkPolicySpec is an autogenerated deepcopy function. +func DeepCopy_networking_NetworkPolicySpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*NetworkPolicySpec) + out := out.(*NetworkPolicySpec) + *out = *in + if newVal, err := c.DeepCopy(&in.PodSelector); err != nil { + return err + } else { + out.PodSelector = *newVal.(*v1.LabelSelector) + } + if in.Ingress != nil { + in, out := &in.Ingress, &out.Ingress + *out = make([]NetworkPolicyIngressRule, len(*in)) + for i := range *in { + if err := DeepCopy_networking_NetworkPolicyIngressRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/BUILD b/vendor/k8s.io/client-go/pkg/apis/policy/BUILD new file mode 100644 index 0000000000..3fce625945 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/policy/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/OWNERS b/vendor/k8s.io/client-go/pkg/apis/policy/OWNERS new file mode 100755 index 0000000000..99e0bffb53 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/policy/OWNERS @@ -0,0 +1,4 @@ +approvers: +- sig-apps-api-approvers +reviewers: +- sig-apps-reviewers diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/doc.go b/vendor/k8s.io/client-go/pkg/apis/policy/doc.go index 6536d5c964..8feeef8e41 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/doc.go @@ -14,7 +14,4 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - package policy diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/install/install.go b/vendor/k8s.io/client-go/pkg/apis/policy/install/install.go deleted file mode 100644 index 674b904333..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/policy/install/install.go +++ /dev/null @@ -1,41 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the experimental API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/policy" - "k8s.io/client-go/pkg/apis/policy/v1beta1" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: policy.GroupName, - VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/policy", - AddInternalObjectsToScheme: policy.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/register.go b/vendor/k8s.io/client-go/pkg/apis/policy/register.go index af378cbd77..5aadc3f1b8 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/register.go @@ -17,24 +17,23 @@ limitations under the License. package policy import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "policy" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -49,7 +48,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &PodDisruptionBudget{}, &PodDisruptionBudgetList{}, - &api.ListOptions{}, &Eviction{}, ) return nil diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/policy/types.generated.go deleted file mode 100644 index fd1a669b70..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/policy/types.generated.go +++ /dev/null @@ -1,1986 +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 policy - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg3_api "k8s.io/client-go/pkg/api" - pkg2_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg4_types "k8s.io/client-go/pkg/types" - pkg1_intstr "k8s.io/client-go/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_api.ObjectMeta - var v1 pkg2_unversioned.LabelSelector - var v2 pkg4_types.UID - var v3 pkg1_intstr.IntOrString - var v4 time.Time - _, _, _, _, _ = v0, v1, v2, v3, v4 - } -} - -func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = true - yyq2[1] = x.Selector != nil - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) - } else { - yynn2 = 0 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yy4 := &x.MinAvailable - yym5 := z.EncBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.EncExt(yy4) { - } else if !yym5 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4) - } else { - z.EncFallback(yy4) - } - } else { - r.EncodeNil() - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("minAvailable")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy6 := &x.MinAvailable - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(yy6) { - } else if !yym7 && z.IsJSONHandle() { - z.EncJSONMarshal(yy6) - } else { - z.EncFallback(yy6) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - if x.Selector == nil { - r.EncodeNil() - } else { - yym9 := z.EncBinary() - _ = yym9 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("selector")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Selector == nil { - r.EncodeNil() - } else { - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(x.Selector) { - } else { - z.EncFallback(x.Selector) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodDisruptionBudgetSpec) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym11 := z.DecBinary() - _ = yym11 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct12 := r.ContainerType() - if yyct12 == codecSelferValueTypeMap1234 { - yyl12 := r.ReadMapStart() - if yyl12 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl12, d) - } - } else if yyct12 == codecSelferValueTypeArray1234 { - yyl12 := r.ReadArrayStart() - if yyl12 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl12, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys13Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys13Slc - var yyhl13 bool = l >= 0 - for yyj13 := 0; ; yyj13++ { - if yyhl13 { - if yyj13 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys13Slc = r.DecodeBytes(yys13Slc, true, true) - yys13 := string(yys13Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys13 { - case "minAvailable": - if r.TryDecodeAsNil() { - x.MinAvailable = pkg1_intstr.IntOrString{} - } else { - yyv14 := &x.MinAvailable - yym15 := z.DecBinary() - _ = yym15 - if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else if !yym15 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv14) - } else { - z.DecFallback(yyv14, false) - } - } - case "selector": - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) - } - yym17 := z.DecBinary() - _ = yym17 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - default: - z.DecStructFieldNotFound(-1, yys13) - } // end switch yys13 - } // end for yyj13 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.MinAvailable = pkg1_intstr.IntOrString{} - } else { - yyv19 := &x.MinAvailable - yym20 := z.DecBinary() - _ = yym20 - if false { - } else if z.HasExtensions() && z.DecExt(yyv19) { - } else if !yym20 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv19) - } else { - z.DecFallback(yyv19, false) - } - } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.Selector != nil { - x.Selector = nil - } - } else { - if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) - } - yym22 := z.DecBinary() - _ = yym22 - if false { - } else if z.HasExtensions() && z.DecExt(x.Selector) { - } else { - z.DecFallback(x.Selector, false) - } - } - for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l - } else { - yyb18 = r.CheckBreak() - } - if yyb18 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj18-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym23 := z.EncBinary() - _ = yym23 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep24 := !z.EncBinary() - yy2arr24 := z.EncBasicHandle().StructToArray - var yyq24 [6]bool - _, _, _ = yysep24, yyq24, yy2arr24 - const yyr24 bool = false - yyq24[0] = x.ObservedGeneration != 0 - var yynn24 int - if yyr24 || yy2arr24 { - r.EncodeArrayStart(6) - } else { - yynn24 = 5 - for _, b := range yyq24 { - if b { - yynn24++ - } - } - r.EncodeMapStart(yynn24) - yynn24 = 0 - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq24[0] { - yym26 := z.EncBinary() - _ = yym26 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } else { - r.EncodeInt(0) - } - } else { - if yyq24[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym27 := z.EncBinary() - _ = yym27 - if false { - } else { - r.EncodeInt(int64(x.ObservedGeneration)) - } - } - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.DisruptedPods == nil { - r.EncodeNil() - } else { - yym29 := z.EncBinary() - _ = yym29 - if false { - } else { - h.encMapstringunversioned_Time((map[string]pkg2_unversioned.Time)(x.DisruptedPods), e) - } - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("disruptedPods")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DisruptedPods == nil { - r.EncodeNil() - } else { - yym30 := z.EncBinary() - _ = yym30 - if false { - } else { - h.encMapstringunversioned_Time((map[string]pkg2_unversioned.Time)(x.DisruptedPods), e) - } - } - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym32 := z.EncBinary() - _ = yym32 - if false { - } else { - r.EncodeInt(int64(x.PodDisruptionsAllowed)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("disruptionsAllowed")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym33 := z.EncBinary() - _ = yym33 - if false { - } else { - r.EncodeInt(int64(x.PodDisruptionsAllowed)) - } - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym35 := z.EncBinary() - _ = yym35 - if false { - } else { - r.EncodeInt(int64(x.CurrentHealthy)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("currentHealthy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 - if false { - } else { - r.EncodeInt(int64(x.CurrentHealthy)) - } - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeInt(int64(x.DesiredHealthy)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("desiredHealthy")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 - if false { - } else { - r.EncodeInt(int64(x.DesiredHealthy)) - } - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeInt(int64(x.ExpectedPods)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("expectedPods")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym42 := z.EncBinary() - _ = yym42 - if false { - } else { - r.EncodeInt(int64(x.ExpectedPods)) - } - } - if yyr24 || yy2arr24 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodDisruptionBudgetStatus) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym43 := z.DecBinary() - _ = yym43 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct44 := r.ContainerType() - if yyct44 == codecSelferValueTypeMap1234 { - yyl44 := r.ReadMapStart() - if yyl44 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl44, d) - } - } else if yyct44 == codecSelferValueTypeArray1234 { - yyl44 := r.ReadArrayStart() - if yyl44 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl44, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys45Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys45Slc - var yyhl45 bool = l >= 0 - for yyj45 := 0; ; yyj45++ { - if yyhl45 { - if yyj45 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys45Slc = r.DecodeBytes(yys45Slc, true, true) - yys45 := string(yys45Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys45 { - case "observedGeneration": - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - case "disruptedPods": - if r.TryDecodeAsNil() { - x.DisruptedPods = nil - } else { - yyv47 := &x.DisruptedPods - yym48 := z.DecBinary() - _ = yym48 - if false { - } else { - h.decMapstringunversioned_Time((*map[string]pkg2_unversioned.Time)(yyv47), d) - } - } - case "disruptionsAllowed": - if r.TryDecodeAsNil() { - x.PodDisruptionsAllowed = 0 - } else { - x.PodDisruptionsAllowed = int32(r.DecodeInt(32)) - } - case "currentHealthy": - if r.TryDecodeAsNil() { - x.CurrentHealthy = 0 - } else { - x.CurrentHealthy = int32(r.DecodeInt(32)) - } - case "desiredHealthy": - if r.TryDecodeAsNil() { - x.DesiredHealthy = 0 - } else { - x.DesiredHealthy = int32(r.DecodeInt(32)) - } - case "expectedPods": - if r.TryDecodeAsNil() { - x.ExpectedPods = 0 - } else { - x.ExpectedPods = int32(r.DecodeInt(32)) - } - default: - z.DecStructFieldNotFound(-1, yys45) - } // end switch yys45 - } // end for yyj45 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj53 int - var yyb53 bool - var yyhl53 bool = l >= 0 - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObservedGeneration = 0 - } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DisruptedPods = nil - } else { - yyv55 := &x.DisruptedPods - yym56 := z.DecBinary() - _ = yym56 - if false { - } else { - h.decMapstringunversioned_Time((*map[string]pkg2_unversioned.Time)(yyv55), d) - } - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.PodDisruptionsAllowed = 0 - } else { - x.PodDisruptionsAllowed = int32(r.DecodeInt(32)) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.CurrentHealthy = 0 - } else { - x.CurrentHealthy = int32(r.DecodeInt(32)) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.DesiredHealthy = 0 - } else { - x.DesiredHealthy = int32(r.DecodeInt(32)) - } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ExpectedPods = 0 - } else { - x.ExpectedPods = int32(r.DecodeInt(32)) - } - for { - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l - } else { - yyb53 = r.CheckBreak() - } - if yyb53 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj53-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PodDisruptionBudget) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym61 := z.EncBinary() - _ = yym61 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep62 := !z.EncBinary() - yy2arr62 := z.EncBasicHandle().StructToArray - var yyq62 [5]bool - _, _, _ = yysep62, yyq62, yy2arr62 - const yyr62 bool = false - yyq62[0] = x.Kind != "" - yyq62[1] = x.APIVersion != "" - yyq62[2] = true - yyq62[3] = true - yyq62[4] = true - var yynn62 int - if yyr62 || yy2arr62 { - r.EncodeArrayStart(5) - } else { - yynn62 = 0 - for _, b := range yyq62 { - if b { - yynn62++ - } - } - r.EncodeMapStart(yynn62) - yynn62 = 0 - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[0] { - yym64 := z.EncBinary() - _ = yym64 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq62[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym65 := z.EncBinary() - _ = yym65 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[1] { - yym67 := z.EncBinary() - _ = yym67 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq62[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[2] { - yy70 := &x.ObjectMeta - yy70.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq62[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy71 := &x.ObjectMeta - yy71.CodecEncodeSelf(e) - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[3] { - yy73 := &x.Spec - yy73.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq62[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("spec")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy74 := &x.Spec - yy74.CodecEncodeSelf(e) - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[4] { - yy76 := &x.Status - yy76.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq62[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("status")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy77 := &x.Status - yy77.CodecEncodeSelf(e) - } - } - if yyr62 || yy2arr62 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodDisruptionBudget) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym78 := z.DecBinary() - _ = yym78 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct79 := r.ContainerType() - if yyct79 == codecSelferValueTypeMap1234 { - yyl79 := r.ReadMapStart() - if yyl79 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl79, d) - } - } else if yyct79 == codecSelferValueTypeArray1234 { - yyl79 := r.ReadArrayStart() - if yyl79 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl79, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodDisruptionBudget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys80Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys80Slc - var yyhl80 bool = l >= 0 - for yyj80 := 0; ; yyj80++ { - if yyhl80 { - if yyj80 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys80Slc = r.DecodeBytes(yys80Slc, true, true) - yys80 := string(yys80Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys80 { - 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 = pkg3_api.ObjectMeta{} - } else { - yyv83 := &x.ObjectMeta - yyv83.CodecDecodeSelf(d) - } - case "spec": - if r.TryDecodeAsNil() { - x.Spec = PodDisruptionBudgetSpec{} - } else { - yyv84 := &x.Spec - yyv84.CodecDecodeSelf(d) - } - case "status": - if r.TryDecodeAsNil() { - x.Status = PodDisruptionBudgetStatus{} - } else { - yyv85 := &x.Status - yyv85.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys80) - } // end switch yys80 - } // end for yyj80 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodDisruptionBudget) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj86 int - var yyb86 bool - var yyhl86 bool = l >= 0 - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l - } else { - yyb86 = r.CheckBreak() - } - if yyb86 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l - } else { - yyb86 = r.CheckBreak() - } - if yyb86 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l - } else { - yyb86 = r.CheckBreak() - } - if yyb86 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_api.ObjectMeta{} - } else { - yyv89 := &x.ObjectMeta - yyv89.CodecDecodeSelf(d) - } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l - } else { - yyb86 = r.CheckBreak() - } - if yyb86 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Spec = PodDisruptionBudgetSpec{} - } else { - yyv90 := &x.Spec - yyv90.CodecDecodeSelf(d) - } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l - } else { - yyb86 = r.CheckBreak() - } - if yyb86 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Status = PodDisruptionBudgetStatus{} - } else { - yyv91 := &x.Status - yyv91.CodecDecodeSelf(d) - } - for { - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l - } else { - yyb86 = r.CheckBreak() - } - if yyb86 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj86-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *PodDisruptionBudgetList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym92 := z.EncBinary() - _ = yym92 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep93 := !z.EncBinary() - yy2arr93 := z.EncBasicHandle().StructToArray - var yyq93 [4]bool - _, _, _ = yysep93, yyq93, yy2arr93 - const yyr93 bool = false - yyq93[0] = x.Kind != "" - yyq93[1] = x.APIVersion != "" - yyq93[2] = true - var yynn93 int - if yyr93 || yy2arr93 { - r.EncodeArrayStart(4) - } else { - yynn93 = 1 - for _, b := range yyq93 { - if b { - yynn93++ - } - } - r.EncodeMapStart(yynn93) - yynn93 = 0 - } - if yyr93 || yy2arr93 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq93[0] { - yym95 := z.EncBinary() - _ = yym95 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq93[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym96 := z.EncBinary() - _ = yym96 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr93 || yy2arr93 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq93[1] { - yym98 := z.EncBinary() - _ = yym98 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq93[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym99 := z.EncBinary() - _ = yym99 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr93 || yy2arr93 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq93[2] { - yy101 := &x.ListMeta - yym102 := z.EncBinary() - _ = yym102 - if false { - } else if z.HasExtensions() && z.EncExt(yy101) { - } else { - z.EncFallback(yy101) - } - } else { - r.EncodeNil() - } - } else { - if yyq93[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy103 := &x.ListMeta - yym104 := z.EncBinary() - _ = yym104 - if false { - } else if z.HasExtensions() && z.EncExt(yy103) { - } else { - z.EncFallback(yy103) - } - } - } - if yyr93 || yy2arr93 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym106 := z.EncBinary() - _ = yym106 - if false { - } else { - h.encSlicePodDisruptionBudget(([]PodDisruptionBudget)(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 { - yym107 := z.EncBinary() - _ = yym107 - if false { - } else { - h.encSlicePodDisruptionBudget(([]PodDisruptionBudget)(x.Items), e) - } - } - } - if yyr93 || yy2arr93 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *PodDisruptionBudgetList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym108 := z.DecBinary() - _ = yym108 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct109 := r.ContainerType() - if yyct109 == codecSelferValueTypeMap1234 { - yyl109 := r.ReadMapStart() - if yyl109 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl109, d) - } - } else if yyct109 == codecSelferValueTypeArray1234 { - yyl109 := r.ReadArrayStart() - if yyl109 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl109, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *PodDisruptionBudgetList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys110Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys110Slc - var yyhl110 bool = l >= 0 - for yyj110 := 0; ; yyj110++ { - if yyhl110 { - if yyj110 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys110Slc = r.DecodeBytes(yys110Slc, true, true) - yys110 := string(yys110Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys110 { - 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 { - yyv113 := &x.ListMeta - yym114 := z.DecBinary() - _ = yym114 - if false { - } else if z.HasExtensions() && z.DecExt(yyv113) { - } else { - z.DecFallback(yyv113, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv115 := &x.Items - yym116 := z.DecBinary() - _ = yym116 - if false { - } else { - h.decSlicePodDisruptionBudget((*[]PodDisruptionBudget)(yyv115), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys110) - } // end switch yys110 - } // end for yyj110 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *PodDisruptionBudgetList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj117 int - var yyb117 bool - var yyhl117 bool = l >= 0 - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l - } else { - yyb117 = r.CheckBreak() - } - if yyb117 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l - } else { - yyb117 = r.CheckBreak() - } - if yyb117 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l - } else { - yyb117 = r.CheckBreak() - } - if yyb117 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} - } else { - yyv120 := &x.ListMeta - yym121 := z.DecBinary() - _ = yym121 - if false { - } else if z.HasExtensions() && z.DecExt(yyv120) { - } else { - z.DecFallback(yyv120, false) - } - } - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l - } else { - yyb117 = r.CheckBreak() - } - if yyb117 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv122 := &x.Items - yym123 := z.DecBinary() - _ = yym123 - if false { - } else { - h.decSlicePodDisruptionBudget((*[]PodDisruptionBudget)(yyv122), d) - } - } - for { - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l - } else { - yyb117 = r.CheckBreak() - } - if yyb117 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj117-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *Eviction) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym124 := z.EncBinary() - _ = yym124 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep125 := !z.EncBinary() - yy2arr125 := z.EncBasicHandle().StructToArray - var yyq125 [4]bool - _, _, _ = yysep125, yyq125, yy2arr125 - const yyr125 bool = false - yyq125[0] = x.Kind != "" - yyq125[1] = x.APIVersion != "" - yyq125[2] = true - yyq125[3] = x.DeleteOptions != nil - var yynn125 int - if yyr125 || yy2arr125 { - r.EncodeArrayStart(4) - } else { - yynn125 = 0 - for _, b := range yyq125 { - if b { - yynn125++ - } - } - r.EncodeMapStart(yynn125) - yynn125 = 0 - } - if yyr125 || yy2arr125 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[0] { - yym127 := z.EncBinary() - _ = yym127 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq125[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym128 := z.EncBinary() - _ = yym128 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr125 || yy2arr125 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[1] { - yym130 := z.EncBinary() - _ = yym130 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq125[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym131 := z.EncBinary() - _ = yym131 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr125 || yy2arr125 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[2] { - yy133 := &x.ObjectMeta - yy133.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq125[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy134 := &x.ObjectMeta - yy134.CodecEncodeSelf(e) - } - } - if yyr125 || yy2arr125 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[3] { - if x.DeleteOptions == nil { - r.EncodeNil() - } else { - x.DeleteOptions.CodecEncodeSelf(e) - } - } else { - r.EncodeNil() - } - } else { - if yyq125[3] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("deleteOptions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.DeleteOptions == nil { - r.EncodeNil() - } else { - x.DeleteOptions.CodecEncodeSelf(e) - } - } - } - if yyr125 || yy2arr125 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *Eviction) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym136 := z.DecBinary() - _ = yym136 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct137 := r.ContainerType() - if yyct137 == codecSelferValueTypeMap1234 { - yyl137 := r.ReadMapStart() - if yyl137 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl137, d) - } - } else if yyct137 == codecSelferValueTypeArray1234 { - yyl137 := r.ReadArrayStart() - if yyl137 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl137, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *Eviction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys138Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys138Slc - var yyhl138 bool = l >= 0 - for yyj138 := 0; ; yyj138++ { - if yyhl138 { - if yyj138 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys138Slc = r.DecodeBytes(yys138Slc, true, true) - yys138 := string(yys138Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys138 { - 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 = pkg3_api.ObjectMeta{} - } else { - yyv141 := &x.ObjectMeta - yyv141.CodecDecodeSelf(d) - } - case "deleteOptions": - if r.TryDecodeAsNil() { - if x.DeleteOptions != nil { - x.DeleteOptions = nil - } - } else { - if x.DeleteOptions == nil { - x.DeleteOptions = new(pkg3_api.DeleteOptions) - } - x.DeleteOptions.CodecDecodeSelf(d) - } - default: - z.DecStructFieldNotFound(-1, yys138) - } // end switch yys138 - } // end for yyj138 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *Eviction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj143 int - var yyb143 bool - var yyhl143 bool = l >= 0 - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l - } else { - yyb143 = r.CheckBreak() - } - if yyb143 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l - } else { - yyb143 = r.CheckBreak() - } - if yyb143 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l - } else { - yyb143 = r.CheckBreak() - } - if yyb143 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_api.ObjectMeta{} - } else { - yyv146 := &x.ObjectMeta - yyv146.CodecDecodeSelf(d) - } - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l - } else { - yyb143 = r.CheckBreak() - } - if yyb143 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - if x.DeleteOptions != nil { - x.DeleteOptions = nil - } - } else { - if x.DeleteOptions == nil { - x.DeleteOptions = new(pkg3_api.DeleteOptions) - } - x.DeleteOptions.CodecDecodeSelf(d) - } - for { - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l - } else { - yyb143 = r.CheckBreak() - } - if yyb143 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj143-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encMapstringunversioned_Time(v map[string]pkg2_unversioned.Time, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeMapStart(len(v)) - for yyk148, yyv148 := range v { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym149 := z.EncBinary() - _ = yym149 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk148)) - } - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy150 := &yyv148 - yym151 := z.EncBinary() - _ = yym151 - if false { - } else if z.HasExtensions() && z.EncExt(yy150) { - } else if yym151 { - z.EncBinaryMarshal(yy150) - } else if !yym151 && z.IsJSONHandle() { - z.EncJSONMarshal(yy150) - } else { - z.EncFallback(yy150) - } - } - z.EncSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) decMapstringunversioned_Time(v *map[string]pkg2_unversioned.Time, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv152 := *v - yyl152 := r.ReadMapStart() - yybh152 := z.DecBasicHandle() - if yyv152 == nil { - yyrl152, _ := z.DecInferLen(yyl152, yybh152.MaxInitLen, 40) - yyv152 = make(map[string]pkg2_unversioned.Time, yyrl152) - *v = yyv152 - } - var yymk152 string - var yymv152 pkg2_unversioned.Time - var yymg152 bool - if yybh152.MapValueReset { - yymg152 = true - } - if yyl152 > 0 { - for yyj152 := 0; yyj152 < yyl152; yyj152++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk152 = "" - } else { - yymk152 = string(r.DecodeString()) - } - - if yymg152 { - yymv152 = yyv152[yymk152] - } else { - yymv152 = pkg2_unversioned.Time{} - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv152 = pkg2_unversioned.Time{} - } else { - yyv154 := &yymv152 - yym155 := z.DecBinary() - _ = yym155 - if false { - } else if z.HasExtensions() && z.DecExt(yyv154) { - } else if yym155 { - z.DecBinaryUnmarshal(yyv154) - } else if !yym155 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv154) - } else { - z.DecFallback(yyv154, false) - } - } - - if yyv152 != nil { - yyv152[yymk152] = yymv152 - } - } - } else if yyl152 < 0 { - for yyj152 := 0; !r.CheckBreak(); yyj152++ { - z.DecSendContainerState(codecSelfer_containerMapKey1234) - if r.TryDecodeAsNil() { - yymk152 = "" - } else { - yymk152 = string(r.DecodeString()) - } - - if yymg152 { - yymv152 = yyv152[yymk152] - } else { - yymv152 = pkg2_unversioned.Time{} - } - z.DecSendContainerState(codecSelfer_containerMapValue1234) - if r.TryDecodeAsNil() { - yymv152 = pkg2_unversioned.Time{} - } else { - yyv157 := &yymv152 - yym158 := z.DecBinary() - _ = yym158 - if false { - } else if z.HasExtensions() && z.DecExt(yyv157) { - } else if yym158 { - z.DecBinaryUnmarshal(yyv157) - } else if !yym158 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv157) - } else { - z.DecFallback(yyv157, false) - } - } - - if yyv152 != nil { - yyv152[yymk152] = yymv152 - } - } - } // else len==0: TODO: Should we clear map entries? - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x codecSelfer1234) encSlicePodDisruptionBudget(v []PodDisruptionBudget, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv159 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy160 := &yyv159 - yy160.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSlicePodDisruptionBudget(v *[]PodDisruptionBudget, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv161 := *v - yyh161, yyl161 := z.DecSliceHelperStart() - var yyc161 bool - if yyl161 == 0 { - if yyv161 == nil { - yyv161 = []PodDisruptionBudget{} - yyc161 = true - } else if len(yyv161) != 0 { - yyv161 = yyv161[:0] - yyc161 = true - } - } else if yyl161 > 0 { - var yyrr161, yyrl161 int - var yyrt161 bool - if yyl161 > cap(yyv161) { - - yyrg161 := len(yyv161) > 0 - yyv2161 := yyv161 - yyrl161, yyrt161 = z.DecInferLen(yyl161, z.DecBasicHandle().MaxInitLen, 328) - if yyrt161 { - if yyrl161 <= cap(yyv161) { - yyv161 = yyv161[:yyrl161] - } else { - yyv161 = make([]PodDisruptionBudget, yyrl161) - } - } else { - yyv161 = make([]PodDisruptionBudget, yyrl161) - } - yyc161 = true - yyrr161 = len(yyv161) - if yyrg161 { - copy(yyv161, yyv2161) - } - } else if yyl161 != len(yyv161) { - yyv161 = yyv161[:yyl161] - yyc161 = true - } - yyj161 := 0 - for ; yyj161 < yyrr161; yyj161++ { - yyh161.ElemContainerState(yyj161) - if r.TryDecodeAsNil() { - yyv161[yyj161] = PodDisruptionBudget{} - } else { - yyv162 := &yyv161[yyj161] - yyv162.CodecDecodeSelf(d) - } - - } - if yyrt161 { - for ; yyj161 < yyl161; yyj161++ { - yyv161 = append(yyv161, PodDisruptionBudget{}) - yyh161.ElemContainerState(yyj161) - if r.TryDecodeAsNil() { - yyv161[yyj161] = PodDisruptionBudget{} - } else { - yyv163 := &yyv161[yyj161] - yyv163.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj161 := 0 - for ; !r.CheckBreak(); yyj161++ { - - if yyj161 >= len(yyv161) { - yyv161 = append(yyv161, PodDisruptionBudget{}) // var yyz161 PodDisruptionBudget - yyc161 = true - } - yyh161.ElemContainerState(yyj161) - if yyj161 < len(yyv161) { - if r.TryDecodeAsNil() { - yyv161[yyj161] = PodDisruptionBudget{} - } else { - yyv164 := &yyv161[yyj161] - yyv164.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj161 < len(yyv161) { - yyv161 = yyv161[:yyj161] - yyc161 = true - } else if yyj161 == 0 && yyv161 == nil { - yyv161 = []PodDisruptionBudget{} - yyc161 = true - } - } - yyh161.End() - if yyc161 { - *v = yyv161 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/types.go b/vendor/k8s.io/client-go/pkg/apis/policy/types.go index 1b753f0f43..4d49da1747 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/types.go @@ -17,9 +17,8 @@ limitations under the License. package policy import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/util/intstr" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" ) // PodDisruptionBudgetSpec is a description of a PodDisruptionBudget. @@ -29,12 +28,19 @@ type PodDisruptionBudgetSpec struct { // absence of the evicted pod. So for example you can prevent all voluntary // evictions by specifying "100%". // +optional - MinAvailable intstr.IntOrString `json:"minAvailable,omitempty"` + MinAvailable *intstr.IntOrString // Label query over pods whose evictions are managed by the disruption // budget. // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty"` + Selector *metav1.LabelSelector + + // An eviction is allowed if at most "maxUnavailable" pods selected by + // "selector" are unavailable after the eviction, i.e. even in absence of + // the evicted pod. For example, one can prevent all voluntary evictions + // by specifying 0. This is a mutually exclusive setting with "minAvailable". + // +optional + MaxUnavailable *intstr.IntOrString } // PodDisruptionBudgetStatus represents information about the status of a @@ -43,7 +49,7 @@ type PodDisruptionBudgetStatus struct { // Most recent generation observed when updating this PDB status. PodDisruptionsAllowed and other // status informatio is valid only if observedGeneration equals to PDB's object generation. // +optional - ObservedGeneration int64 `json:"observedGeneration,omitempty"` + ObservedGeneration int64 // DisruptedPods contains information about pods whose eviction was // processed by the API server eviction subresource handler but has not @@ -56,43 +62,43 @@ type PodDisruptionBudgetStatus struct { // the list automatically by PodDisruptionBudget controller after some time. // If everything goes smooth this map should be empty for the most of the time. // Large number of entries in the map may indicate problems with pod deletions. - DisruptedPods map[string]unversioned.Time `json:"disruptedPods" protobuf:"bytes,5,rep,name=disruptedPods"` + DisruptedPods map[string]metav1.Time // Number of pod disruptions that are currently allowed. - PodDisruptionsAllowed int32 `json:"disruptionsAllowed"` + PodDisruptionsAllowed int32 // current number of healthy pods - CurrentHealthy int32 `json:"currentHealthy"` + CurrentHealthy int32 // minimum desired number of healthy pods - DesiredHealthy int32 `json:"desiredHealthy"` + DesiredHealthy int32 // total number of pods counted by this disruption budget - ExpectedPods int32 `json:"expectedPods"` + ExpectedPods int32 } // +genclient=true // PodDisruptionBudget is an object to define the max disruption that can be caused to a collection of pods type PodDisruptionBudget struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // Specification of the desired behavior of the PodDisruptionBudget. // +optional - Spec PodDisruptionBudgetSpec `json:"spec,omitempty"` + Spec PodDisruptionBudgetSpec // Most recently observed status of the PodDisruptionBudget. // +optional - Status PodDisruptionBudgetStatus `json:"status,omitempty"` + Status PodDisruptionBudgetStatus } // PodDisruptionBudgetList is a collection of PodDisruptionBudgets. type PodDisruptionBudgetList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - unversioned.ListMeta `json:"metadata,omitempty"` - Items []PodDisruptionBudget `json:"items"` + metav1.ListMeta + Items []PodDisruptionBudget } // +genclient=true @@ -102,13 +108,13 @@ type PodDisruptionBudgetList struct { // This is a subresource of Pod. A request to cause such an eviction is // created by POSTing to .../pods//eviction. type Eviction struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // ObjectMeta describes the pod that is being evicted. // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // DeleteOptions may be provided // +optional - DeleteOptions *api.DeleteOptions `json:"deleteOptions,omitempty"` + DeleteOptions *metav1.DeleteOptions } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/types.go deleted file mode 100644 index 3affb1bd46..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/types.go +++ /dev/null @@ -1,93 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package v1alpha1 - -import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/util/intstr" -) - -// PodDisruptionBudgetSpec is a description of a PodDisruptionBudget. -type PodDisruptionBudgetSpec struct { - // An eviction is allowed if at least "minAvailable" pods selected by - // "selector" will still be available after the eviction, i.e. even in the - // absence of the evicted pod. So for example you can prevent all voluntary - // evictions by specifying "100%". - // +optional - MinAvailable intstr.IntOrString `json:"minAvailable,omitempty" protobuf:"bytes,1,opt,name=minAvailable"` - - // Label query over pods whose evictions are managed by the disruption - // budget. - // +optional - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` -} - -// PodDisruptionBudgetStatus represents information about the status of a -// PodDisruptionBudget. Status may trail the actual state of a system. -type PodDisruptionBudgetStatus struct { - // Whether or not a disruption is currently allowed. - PodDisruptionAllowed bool `json:"disruptionAllowed" protobuf:"varint,1,opt,name=disruptionAllowed"` - - // current number of healthy pods - CurrentHealthy int32 `json:"currentHealthy" protobuf:"varint,2,opt,name=currentHealthy"` - - // minimum desired number of healthy pods - DesiredHealthy int32 `json:"desiredHealthy" protobuf:"varint,3,opt,name=desiredHealthy"` - - // total number of pods counted by this disruption budget - ExpectedPods int32 `json:"expectedPods" protobuf:"varint,4,opt,name=expectedPods"` -} - -// +genclient=true - -// PodDisruptionBudget is an object to define the max disruption that can be caused to a collection of pods -type PodDisruptionBudget struct { - unversioned.TypeMeta `json:",inline"` - // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // Specification of the desired behavior of the PodDisruptionBudget. - // +optional - Spec PodDisruptionBudgetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` - // Most recently observed status of the PodDisruptionBudget. - // +optional - Status PodDisruptionBudgetStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"` -} - -// PodDisruptionBudgetList is a collection of PodDisruptionBudgets. -type PodDisruptionBudgetList struct { - unversioned.TypeMeta `json:",inline"` - // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []PodDisruptionBudget `json:"items" protobuf:"bytes,2,rep,name=items"` -} - -// Eviction evicts a pod from its node subject to certain policies and safety constraints. -// This is a subresource of Pod. A request to cause such an eviction is -// created by POSTing to .../pods//eviction. -type Eviction struct { - unversioned.TypeMeta `json:",inline"` - - // ObjectMeta describes the pod that is being evicted. - // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - - // DeleteOptions may be provided - // +optional - DeleteOptions *v1.DeleteOptions `json:"deleteOptions,omitempty" protobuf:"bytes,2,opt,name=deleteOptions"` -} diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/BUILD new file mode 100644 index 0000000000..cd97fbaba7 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/policy:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/doc.go index 5a33899476..aadbe14164 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/doc.go @@ -14,11 +14,7 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/policy - // Package policy is for any kind of policy object. Suitable examples, even if // they aren't all here, are PodDisruptionBudget, PodSecurityPolicy, // NetworkPolicy, etc. -// +k8s:openapi-gen=true package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go index a2cad53513..0116ded29b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -37,12 +37,14 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import k8s_io_kubernetes_pkg_api_unversioned "k8s.io/client-go/pkg/api/unversioned" -import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" +import k8s_io_apimachinery_pkg_apis_meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + +import k8s_io_apimachinery_pkg_util_intstr "k8s.io/apimachinery/pkg/util/intstr" + +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import strings "strings" import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import io "io" @@ -53,7 +55,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *Eviction) Reset() { *m = Eviction{} } func (*Eviction) ProtoMessage() {} @@ -84,34 +88,34 @@ func init() { proto.RegisterType((*PodDisruptionBudgetSpec)(nil), "k8s.io.client-go.pkg.apis.policy.v1beta1.PodDisruptionBudgetSpec") proto.RegisterType((*PodDisruptionBudgetStatus)(nil), "k8s.io.client-go.pkg.apis.policy.v1beta1.PodDisruptionBudgetStatus") } -func (m *Eviction) Marshal() (data []byte, err error) { +func (m *Eviction) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Eviction) MarshalTo(data []byte) (int, error) { +func (m *Eviction) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 if m.DeleteOptions != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.DeleteOptions.Size())) - n2, err := m.DeleteOptions.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.DeleteOptions.Size())) + n2, err := m.DeleteOptions.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -120,41 +124,41 @@ func (m *Eviction) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodDisruptionBudget) Marshal() (data []byte, err error) { +func (m *PodDisruptionBudget) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodDisruptionBudget) MarshalTo(data []byte) (int, error) { +func (m *PodDisruptionBudget) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n3, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n3, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n3 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Spec.Size())) - n4, err := m.Spec.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n4, err := m.Spec.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.Status.Size())) - n5, err := m.Status.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Status.Size())) + n5, err := m.Status.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -162,35 +166,35 @@ func (m *PodDisruptionBudget) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodDisruptionBudgetList) Marshal() (data []byte, err error) { +func (m *PodDisruptionBudgetList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodDisruptionBudgetList) MarshalTo(data []byte) (int, error) { +func (m *PodDisruptionBudgetList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n6, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n6 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -200,122 +204,143 @@ func (m *PodDisruptionBudgetList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PodDisruptionBudgetSpec) Marshal() (data []byte, err error) { +func (m *PodDisruptionBudgetSpec) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodDisruptionBudgetSpec) MarshalTo(data []byte) (int, error) { +func (m *PodDisruptionBudgetSpec) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(m.MinAvailable.Size())) - n7, err := m.MinAvailable.MarshalTo(data[i:]) - if err != nil { - return 0, err + if m.MinAvailable != nil { + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MinAvailable.Size())) + n7, err := m.MinAvailable.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 } - i += n7 if m.Selector != nil { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(m.Selector.Size())) - n8, err := m.Selector.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n8, err := m.Selector.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n8 } + if m.MaxUnavailable != nil { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.MaxUnavailable.Size())) + n9, err := m.MaxUnavailable.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + } return i, nil } -func (m *PodDisruptionBudgetStatus) Marshal() (data []byte, err error) { +func (m *PodDisruptionBudgetStatus) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PodDisruptionBudgetStatus) MarshalTo(data []byte) (int, error) { +func (m *PodDisruptionBudgetStatus) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0x8 + dAtA[i] = 0x8 i++ - i = encodeVarintGenerated(data, i, uint64(m.ObservedGeneration)) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObservedGeneration)) if len(m.DisruptedPods) > 0 { + keysForDisruptedPods := make([]string, 0, len(m.DisruptedPods)) for k := range m.DisruptedPods { - data[i] = 0x12 + keysForDisruptedPods = append(keysForDisruptedPods, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForDisruptedPods) + for _, k := range keysForDisruptedPods { + dAtA[i] = 0x12 i++ - v := m.DisruptedPods[k] - msgSize := (&v).Size() - mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + msgSize + sovGenerated(uint64(msgSize)) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + v := m.DisruptedPods[string(k)] + msgSize := 0 + if (&v) != nil { + msgSize = (&v).Size() + msgSize += 1 + sovGenerated(uint64(msgSize)) + } + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + msgSize + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64((&v).Size())) - n9, err := (&v).MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64((&v).Size())) + n10, err := (&v).MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n9 + i += n10 } } - data[i] = 0x18 + dAtA[i] = 0x18 i++ - i = encodeVarintGenerated(data, i, uint64(m.PodDisruptionsAllowed)) - data[i] = 0x20 + i = encodeVarintGenerated(dAtA, i, uint64(m.PodDisruptionsAllowed)) + dAtA[i] = 0x20 i++ - i = encodeVarintGenerated(data, i, uint64(m.CurrentHealthy)) - data[i] = 0x28 + i = encodeVarintGenerated(dAtA, i, uint64(m.CurrentHealthy)) + dAtA[i] = 0x28 i++ - i = encodeVarintGenerated(data, i, uint64(m.DesiredHealthy)) - data[i] = 0x30 + i = encodeVarintGenerated(dAtA, i, uint64(m.DesiredHealthy)) + dAtA[i] = 0x30 i++ - i = encodeVarintGenerated(data, i, uint64(m.ExpectedPods)) + i = encodeVarintGenerated(dAtA, i, uint64(m.ExpectedPods)) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *Eviction) Size() (n int) { @@ -359,12 +384,18 @@ func (m *PodDisruptionBudgetList) Size() (n int) { func (m *PodDisruptionBudgetSpec) Size() (n int) { var l int _ = l - l = m.MinAvailable.Size() - n += 1 + l + sovGenerated(uint64(l)) + if m.MinAvailable != nil { + l = m.MinAvailable.Size() + n += 1 + l + sovGenerated(uint64(l)) + } if m.Selector != nil { l = m.Selector.Size() n += 1 + l + sovGenerated(uint64(l)) } + if m.MaxUnavailable != nil { + l = m.MaxUnavailable.Size() + n += 1 + l + sovGenerated(uint64(l)) + } return n } @@ -406,8 +437,8 @@ func (this *Eviction) String() string { return "nil" } s := strings.Join([]string{`&Eviction{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, - `DeleteOptions:` + strings.Replace(fmt.Sprintf("%v", this.DeleteOptions), "DeleteOptions", "k8s_io_kubernetes_pkg_api_v1.DeleteOptions", 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `DeleteOptions:` + strings.Replace(fmt.Sprintf("%v", this.DeleteOptions), "DeleteOptions", "k8s_io_apimachinery_pkg_apis_meta_v1.DeleteOptions", 1) + `,`, `}`, }, "") return s @@ -417,7 +448,7 @@ func (this *PodDisruptionBudget) String() string { return "nil" } s := strings.Join([]string{`&PodDisruptionBudget{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PodDisruptionBudgetSpec", "PodDisruptionBudgetSpec", 1), `&`, ``, 1) + `,`, `Status:` + strings.Replace(strings.Replace(this.Status.String(), "PodDisruptionBudgetStatus", "PodDisruptionBudgetStatus", 1), `&`, ``, 1) + `,`, `}`, @@ -429,7 +460,7 @@ func (this *PodDisruptionBudgetList) String() string { return "nil" } s := strings.Join([]string{`&PodDisruptionBudgetList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "PodDisruptionBudget", "PodDisruptionBudget", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -440,8 +471,9 @@ func (this *PodDisruptionBudgetSpec) String() string { return "nil" } s := strings.Join([]string{`&PodDisruptionBudgetSpec{`, - `MinAvailable:` + strings.Replace(strings.Replace(this.MinAvailable.String(), "IntOrString", "k8s_io_kubernetes_pkg_util_intstr.IntOrString", 1), `&`, ``, 1) + `,`, - `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_kubernetes_pkg_api_unversioned.LabelSelector", 1) + `,`, + `MinAvailable:` + strings.Replace(fmt.Sprintf("%v", this.MinAvailable), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, + `Selector:` + strings.Replace(fmt.Sprintf("%v", this.Selector), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1) + `,`, + `MaxUnavailable:` + strings.Replace(fmt.Sprintf("%v", this.MaxUnavailable), "IntOrString", "k8s_io_apimachinery_pkg_util_intstr.IntOrString", 1) + `,`, `}`, }, "") return s @@ -455,7 +487,7 @@ func (this *PodDisruptionBudgetStatus) String() string { keysForDisruptedPods = append(keysForDisruptedPods, k) } github_com_gogo_protobuf_sortkeys.Strings(keysForDisruptedPods) - mapStringForDisruptedPods := "map[string]k8s_io_kubernetes_pkg_api_unversioned.Time{" + mapStringForDisruptedPods := "map[string]k8s_io_apimachinery_pkg_apis_meta_v1.Time{" for _, k := range keysForDisruptedPods { mapStringForDisruptedPods += fmt.Sprintf("%v: %v,", k, this.DisruptedPods[k]) } @@ -479,8 +511,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *Eviction) Unmarshal(data []byte) error { - l := len(data) +func (m *Eviction) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -492,7 +524,7 @@ func (m *Eviction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -520,7 +552,7 @@ func (m *Eviction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -534,7 +566,7 @@ func (m *Eviction) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -550,7 +582,7 @@ func (m *Eviction) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -565,15 +597,15 @@ func (m *Eviction) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.DeleteOptions == nil { - m.DeleteOptions = &k8s_io_kubernetes_pkg_api_v1.DeleteOptions{} + m.DeleteOptions = &k8s_io_apimachinery_pkg_apis_meta_v1.DeleteOptions{} } - if err := m.DeleteOptions.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.DeleteOptions.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -592,8 +624,8 @@ func (m *Eviction) Unmarshal(data []byte) error { } return nil } -func (m *PodDisruptionBudget) Unmarshal(data []byte) error { - l := len(data) +func (m *PodDisruptionBudget) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -605,7 +637,7 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -633,7 +665,7 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -647,7 +679,7 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -663,7 +695,7 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -677,7 +709,7 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Spec.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -693,7 +725,7 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -707,13 +739,13 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.Status.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Status.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -732,8 +764,8 @@ func (m *PodDisruptionBudget) Unmarshal(data []byte) error { } return nil } -func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { - l := len(data) +func (m *PodDisruptionBudgetList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -745,7 +777,7 @@ func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -773,7 +805,7 @@ func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -787,7 +819,7 @@ func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -803,7 +835,7 @@ func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -818,13 +850,13 @@ func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, PodDisruptionBudget{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -843,8 +875,8 @@ func (m *PodDisruptionBudgetList) Unmarshal(data []byte) error { } return nil } -func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { - l := len(data) +func (m *PodDisruptionBudgetSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -856,7 +888,7 @@ func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -884,7 +916,7 @@ func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -898,7 +930,10 @@ func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.MinAvailable.Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.MinAvailable == nil { + m.MinAvailable = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.MinAvailable.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -914,7 +949,7 @@ func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -929,15 +964,48 @@ func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } if m.Selector == nil { - m.Selector = &k8s_io_kubernetes_pkg_api_unversioned.LabelSelector{} + m.Selector = &k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector{} + } + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MaxUnavailable", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF } - if err := m.Selector.Unmarshal(data[iNdEx:postIndex]); err != nil { + if m.MaxUnavailable == nil { + m.MaxUnavailable = &k8s_io_apimachinery_pkg_util_intstr.IntOrString{} + } + if err := m.MaxUnavailable.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -956,8 +1024,8 @@ func (m *PodDisruptionBudgetSpec) Unmarshal(data []byte) error { } return nil } -func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { - l := len(data) +func (m *PodDisruptionBudgetStatus) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -969,7 +1037,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -997,7 +1065,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ObservedGeneration |= (int64(b) & 0x7F) << shift if b < 0x80 { @@ -1016,7 +1084,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1038,7 +1106,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1053,7 +1121,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1068,57 +1136,62 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + if m.DisruptedPods == nil { + m.DisruptedPods = make(map[string]k8s_io_apimachinery_pkg_apis_meta_v1.Time) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - if iNdEx >= l { - return io.ErrUnexpectedEOF + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - } - var mapmsglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + postmsgIndex := iNdEx + mapmsglen + if mapmsglen < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + if postmsgIndex > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - mapmsglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break + mapvalue := &k8s_io_apimachinery_pkg_apis_meta_v1.Time{} + if err := mapvalue.Unmarshal(dAtA[iNdEx:postmsgIndex]); err != nil { + return err } + iNdEx = postmsgIndex + m.DisruptedPods[mapkey] = *mapvalue + } else { + var mapvalue k8s_io_apimachinery_pkg_apis_meta_v1.Time + m.DisruptedPods[mapkey] = mapvalue } - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - postmsgIndex := iNdEx + mapmsglen - if mapmsglen < 0 { - return ErrInvalidLengthGenerated - } - if postmsgIndex > l { - return io.ErrUnexpectedEOF - } - mapvalue := &k8s_io_kubernetes_pkg_api_unversioned.Time{} - if err := mapvalue.Unmarshal(data[iNdEx:postmsgIndex]); err != nil { - return err - } - iNdEx = postmsgIndex - if m.DisruptedPods == nil { - m.DisruptedPods = make(map[string]k8s_io_kubernetes_pkg_api_unversioned.Time) - } - m.DisruptedPods[mapkey] = *mapvalue iNdEx = postIndex case 3: if wireType != 0 { @@ -1132,7 +1205,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.PodDisruptionsAllowed |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1151,7 +1224,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.CurrentHealthy |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1170,7 +1243,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.DesiredHealthy |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1189,7 +1262,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ m.ExpectedPods |= (int32(b) & 0x7F) << shift if b < 0x80 { @@ -1198,7 +1271,7 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { } default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1217,8 +1290,8 @@ func (m *PodDisruptionBudgetStatus) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -1229,7 +1302,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1247,7 +1320,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -1264,7 +1337,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1287,7 +1360,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1298,7 +1371,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -1322,54 +1395,60 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 758 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xb4, 0x94, 0xcf, 0x6f, 0xdb, 0x36, - 0x14, 0xc7, 0xad, 0xd8, 0xce, 0x3c, 0xc6, 0x0e, 0x32, 0x6e, 0xd9, 0x3c, 0x03, 0x53, 0x06, 0x9f, - 0x12, 0x6c, 0xa1, 0xe0, 0x60, 0x03, 0xb2, 0x1d, 0x02, 0x44, 0x73, 0xb0, 0x65, 0x58, 0xe0, 0x40, - 0x19, 0xb0, 0x61, 0xc0, 0x0a, 0xe8, 0xc7, 0xab, 0xc2, 0x5a, 0x16, 0x05, 0x92, 0x52, 0xeb, 0x5b, - 0xff, 0x84, 0x1e, 0xfa, 0x1f, 0xf5, 0x12, 0xf4, 0x94, 0x63, 0x2f, 0x0d, 0x1a, 0xe7, 0x7f, 0xe8, - 0xb9, 0x90, 0x44, 0x3b, 0x96, 0x7f, 0x04, 0x01, 0xd2, 0xde, 0x44, 0xf2, 0x7d, 0xbe, 0xdf, 0xf7, - 0x1e, 0x1f, 0x85, 0x7e, 0xe9, 0xef, 0x0b, 0x42, 0x99, 0xd1, 0x8f, 0x1d, 0xe0, 0x21, 0x48, 0x10, - 0x46, 0xd4, 0xf7, 0x0d, 0x3b, 0xa2, 0xc2, 0x88, 0x58, 0x40, 0xdd, 0xa1, 0x91, 0x74, 0x1c, 0x90, - 0x76, 0xc7, 0xf0, 0x21, 0x04, 0x6e, 0x4b, 0xf0, 0x48, 0xc4, 0x99, 0x64, 0x78, 0x27, 0x47, 0xc9, - 0x2d, 0x4a, 0xa2, 0xbe, 0x4f, 0x52, 0x94, 0xe4, 0x28, 0x51, 0x68, 0x6b, 0xd7, 0xa7, 0xf2, 0x3c, - 0x76, 0x88, 0xcb, 0x06, 0x86, 0xcf, 0x7c, 0x66, 0x64, 0x0a, 0x4e, 0xfc, 0x38, 0x5b, 0x65, 0x8b, - 0xec, 0x2b, 0x57, 0x6e, 0xed, 0x2d, 0x4d, 0xca, 0xe0, 0x20, 0x58, 0xcc, 0x5d, 0x98, 0xcd, 0xa6, - 0xf5, 0xf3, 0x72, 0x26, 0x0e, 0x13, 0xe0, 0x82, 0xb2, 0x10, 0xbc, 0x39, 0xec, 0xc7, 0xe5, 0x58, - 0x32, 0x57, 0x72, 0x6b, 0x77, 0x71, 0x34, 0x8f, 0x43, 0x49, 0x07, 0xf3, 0x39, 0x75, 0x16, 0x87, - 0xc7, 0x92, 0x06, 0x06, 0x0d, 0xa5, 0x90, 0x7c, 0x16, 0x69, 0xbf, 0xd6, 0x50, 0xed, 0x28, 0xa1, - 0xae, 0xa4, 0x2c, 0xc4, 0xff, 0xa2, 0xda, 0x00, 0xa4, 0xed, 0xd9, 0xd2, 0x6e, 0x6a, 0xdf, 0x6b, - 0xdb, 0x6b, 0x7b, 0xdb, 0x64, 0x69, 0xd3, 0x49, 0xd2, 0x21, 0x3d, 0xe7, 0x09, 0xb8, 0xf2, 0x04, - 0xa4, 0x6d, 0xe2, 0x8b, 0xab, 0xad, 0xd2, 0xe8, 0x6a, 0x0b, 0xdd, 0xee, 0x59, 0x13, 0x35, 0xec, - 0xa1, 0x86, 0x07, 0x01, 0x48, 0xe8, 0x45, 0xa9, 0x93, 0x68, 0xae, 0x64, 0xf2, 0x3f, 0xdc, 0x2d, - 0xdf, 0x9d, 0x46, 0xcc, 0x2f, 0x46, 0x57, 0x5b, 0x8d, 0xc2, 0x96, 0x55, 0x14, 0x6d, 0xbf, 0x5a, - 0x41, 0x5f, 0x9e, 0x32, 0xaf, 0x4b, 0x05, 0x8f, 0xb3, 0x2d, 0x33, 0xf6, 0x7c, 0x90, 0x9f, 0xb4, - 0xae, 0x8a, 0x88, 0xc0, 0x55, 0xe5, 0x98, 0xe4, 0xde, 0x23, 0x4a, 0x16, 0xe4, 0x79, 0x16, 0x81, - 0x6b, 0xd6, 0x95, 0x5f, 0x25, 0x5d, 0x59, 0x99, 0x3a, 0x0e, 0xd0, 0xaa, 0x90, 0xb6, 0x8c, 0x45, - 0xb3, 0x9c, 0xf9, 0x74, 0x1f, 0xe8, 0x93, 0x69, 0x99, 0xeb, 0xca, 0x69, 0x35, 0x5f, 0x5b, 0xca, - 0xa3, 0xfd, 0x56, 0x43, 0xdf, 0x2c, 0xa0, 0xfe, 0xa2, 0x42, 0xe2, 0xff, 0xe7, 0x3a, 0x69, 0xdc, - 0xd1, 0xc9, 0xa9, 0x87, 0x40, 0x52, 0x3c, 0x6b, 0xe8, 0x86, 0xb2, 0xad, 0x8d, 0x77, 0xa6, 0xda, - 0xe9, 0xa2, 0x2a, 0x95, 0x30, 0x48, 0xc7, 0xa3, 0xbc, 0xbd, 0xb6, 0x77, 0xf0, 0xb0, 0x3a, 0xcd, - 0x86, 0xb2, 0xaa, 0x1e, 0xa7, 0xa2, 0x56, 0xae, 0xdd, 0xbe, 0x59, 0x5c, 0x5f, 0xda, 0x6f, 0x7c, - 0x8e, 0xea, 0x03, 0x1a, 0x1e, 0x26, 0x36, 0x0d, 0x6c, 0x27, 0x00, 0x55, 0x23, 0x59, 0x92, 0x47, - 0xfa, 0xb0, 0x48, 0xfe, 0xb0, 0xc8, 0x71, 0x28, 0x7b, 0xfc, 0x4c, 0x72, 0x1a, 0xfa, 0xe6, 0x57, - 0xca, 0xb7, 0x7e, 0x32, 0xa5, 0x65, 0x15, 0x94, 0xf1, 0x23, 0x54, 0x13, 0x10, 0x80, 0x2b, 0x19, - 0x57, 0xd3, 0xf3, 0xd3, 0x7d, 0x3b, 0x69, 0x3b, 0x10, 0x9c, 0x29, 0xd6, 0xac, 0xa7, 0xad, 0x1c, - 0xaf, 0xac, 0x89, 0x66, 0xfb, 0x7d, 0x05, 0x7d, 0xbb, 0xf4, 0xee, 0xf1, 0x9f, 0x08, 0x33, 0x47, - 0x00, 0x4f, 0xc0, 0xfb, 0x3d, 0xff, 0x23, 0x50, 0x16, 0x66, 0xd5, 0x96, 0xcd, 0x96, 0xca, 0x1e, - 0xf7, 0xe6, 0x22, 0xac, 0x05, 0x14, 0x7e, 0xa9, 0xa1, 0x86, 0x97, 0xdb, 0x80, 0x77, 0xca, 0xbc, - 0xf1, 0xed, 0xfd, 0xf3, 0x31, 0xa6, 0x94, 0x74, 0xa7, 0x95, 0x8f, 0x42, 0xc9, 0x87, 0xe6, 0xa6, - 0x4a, 0xb0, 0x51, 0x38, 0xb3, 0x8a, 0x49, 0xe0, 0x13, 0x84, 0xbd, 0x89, 0xa4, 0x38, 0x0c, 0x02, - 0xf6, 0x14, 0xbc, 0xec, 0x01, 0x55, 0xcd, 0xef, 0x94, 0xc2, 0x66, 0xc1, 0x77, 0x1c, 0x64, 0x2d, - 0x00, 0xf1, 0x01, 0x5a, 0x77, 0x63, 0xce, 0x21, 0x94, 0x7f, 0x80, 0x1d, 0xc8, 0xf3, 0x61, 0xb3, - 0x92, 0x49, 0x7d, 0xad, 0xa4, 0xd6, 0x7f, 0x2b, 0x9c, 0x5a, 0x33, 0xd1, 0x29, 0xef, 0x81, 0xa0, - 0x1c, 0xbc, 0x31, 0x5f, 0x2d, 0xf2, 0xdd, 0xc2, 0xa9, 0x35, 0x13, 0x8d, 0xf7, 0x51, 0x1d, 0x9e, - 0x45, 0xe0, 0x8e, 0x7b, 0xbc, 0x9a, 0xd1, 0x93, 0x49, 0x3b, 0x9a, 0x3a, 0xb3, 0x0a, 0x91, 0xad, - 0x01, 0xc2, 0xf3, 0x4d, 0xc4, 0x1b, 0xa8, 0xdc, 0x87, 0x61, 0x76, 0xe5, 0x9f, 0x5b, 0xe9, 0x27, - 0x3e, 0x44, 0xd5, 0xc4, 0x0e, 0x62, 0xb8, 0xc7, 0xbf, 0x79, 0x7a, 0x1c, 0xff, 0xa6, 0x03, 0xb0, - 0x72, 0xf2, 0xd7, 0x95, 0x7d, 0xcd, 0xdc, 0xb9, 0xb8, 0xd6, 0x4b, 0x97, 0xd7, 0x7a, 0xe9, 0xcd, - 0xb5, 0x5e, 0x7a, 0x3e, 0xd2, 0xb5, 0x8b, 0x91, 0xae, 0x5d, 0x8e, 0x74, 0xed, 0xdd, 0x48, 0xd7, - 0x5e, 0xdc, 0xe8, 0xa5, 0xff, 0x3e, 0x53, 0xb7, 0xfe, 0x21, 0x00, 0x00, 0xff, 0xff, 0x59, 0x3e, - 0xe1, 0xf8, 0x0d, 0x08, 0x00, 0x00, + // 791 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xbc, 0x94, 0x5b, 0x6f, 0xe3, 0x44, + 0x14, 0xc7, 0xe3, 0x5c, 0x4a, 0x98, 0x4d, 0xa2, 0x32, 0xb0, 0x10, 0x22, 0xe1, 0xa0, 0x3c, 0x2d, + 0x88, 0x1d, 0xd3, 0x5d, 0x84, 0x0a, 0x0f, 0x2b, 0xd6, 0xa4, 0x82, 0xa2, 0x46, 0xa9, 0xa6, 0x20, + 0x24, 0x04, 0x12, 0x63, 0xfb, 0xd4, 0x19, 0xe2, 0x9b, 0xec, 0x71, 0x68, 0xde, 0xf8, 0x08, 0x3c, + 0xf0, 0xa1, 0x2a, 0x21, 0xa1, 0x3e, 0x56, 0x08, 0x45, 0xd4, 0x7c, 0x06, 0xde, 0x91, 0xed, 0xc9, + 0xc5, 0x4d, 0xa2, 0x06, 0x8a, 0xf6, 0x2d, 0x73, 0xf9, 0xfd, 0xff, 0xe7, 0xfc, 0x7d, 0x26, 0xe8, + 0xa3, 0xf1, 0x61, 0x44, 0xb8, 0xaf, 0x8d, 0x63, 0x03, 0x42, 0x0f, 0x04, 0x44, 0x5a, 0x30, 0xb6, + 0x35, 0x16, 0xf0, 0x48, 0x0b, 0x7c, 0x87, 0x9b, 0x53, 0x6d, 0x72, 0x60, 0x80, 0x60, 0x07, 0x9a, + 0x0d, 0x1e, 0x84, 0x4c, 0x80, 0x45, 0x82, 0xd0, 0x17, 0x3e, 0x7e, 0x27, 0x47, 0xc9, 0x12, 0x25, + 0xc1, 0xd8, 0x26, 0x29, 0x4a, 0x72, 0x94, 0x48, 0xb4, 0xf3, 0xd8, 0xe6, 0x62, 0x14, 0x1b, 0xc4, + 0xf4, 0x5d, 0xcd, 0xf6, 0x6d, 0x5f, 0xcb, 0x14, 0x8c, 0xf8, 0x3c, 0x5b, 0x65, 0x8b, 0xec, 0x57, + 0xae, 0xdc, 0xf9, 0x40, 0x16, 0xc5, 0x02, 0xee, 0x32, 0x73, 0xc4, 0x3d, 0x08, 0xa7, 0xcb, 0xb2, + 0x5c, 0x10, 0x4c, 0x9b, 0xac, 0xd5, 0xd3, 0xd1, 0xb6, 0x51, 0x61, 0xec, 0x09, 0xee, 0xc2, 0x1a, + 0xf0, 0xe1, 0x5d, 0x40, 0x64, 0x8e, 0xc0, 0x65, 0x6b, 0xdc, 0xd3, 0x6d, 0x5c, 0x2c, 0xb8, 0xa3, + 0x71, 0x4f, 0x44, 0x22, 0x5c, 0x83, 0xde, 0xdb, 0x1a, 0xf4, 0x86, 0x5e, 0x7a, 0xbf, 0x2b, 0xa8, + 0x7e, 0x34, 0xe1, 0xa6, 0xe0, 0xbe, 0x87, 0xbf, 0x47, 0xf5, 0xb4, 0x67, 0x8b, 0x09, 0xd6, 0x56, + 0xde, 0x56, 0x1e, 0x3d, 0x78, 0xf2, 0x3e, 0x91, 0xd9, 0xaf, 0x96, 0xb0, 0x4c, 0x3f, 0xbd, 0x4d, + 0x26, 0x07, 0x64, 0x68, 0xfc, 0x00, 0xa6, 0x18, 0x80, 0x60, 0x3a, 0xbe, 0x9c, 0x75, 0x4b, 0xc9, + 0xac, 0x8b, 0x96, 0x7b, 0x74, 0xa1, 0x8a, 0x1d, 0xd4, 0xb4, 0xc0, 0x01, 0x01, 0xc3, 0x20, 0x75, + 0x8c, 0xda, 0xe5, 0xcc, 0xe6, 0xe9, 0x6e, 0x36, 0xfd, 0x55, 0x54, 0x7f, 0x25, 0x99, 0x75, 0x9b, + 0x85, 0x2d, 0x5a, 0x14, 0xef, 0xfd, 0x5a, 0x46, 0xaf, 0x9e, 0xfa, 0x56, 0x9f, 0x47, 0x61, 0x9c, + 0x6d, 0xe9, 0xb1, 0x65, 0x83, 0x78, 0x01, 0x7d, 0x5a, 0xa8, 0x1a, 0x05, 0x60, 0xca, 0xf6, 0x74, + 0xb2, 0xf3, 0x04, 0x93, 0x0d, 0xf5, 0x9e, 0x05, 0x60, 0xea, 0x0d, 0xe9, 0x57, 0x4d, 0x57, 0x34, + 0x53, 0xc7, 0x0e, 0xda, 0x8b, 0x04, 0x13, 0x71, 0xd4, 0xae, 0x64, 0x3e, 0xfd, 0x7b, 0xfa, 0x64, + 0x5a, 0x7a, 0x4b, 0x3a, 0xed, 0xe5, 0x6b, 0x2a, 0x3d, 0x7a, 0x7f, 0x28, 0xe8, 0x8d, 0x0d, 0xd4, + 0x09, 0x8f, 0x04, 0xfe, 0x76, 0x2d, 0x51, 0xb2, 0x5b, 0xa2, 0x29, 0x9d, 0xe5, 0xb9, 0x2f, 0x5d, + 0xeb, 0xf3, 0x9d, 0x95, 0x34, 0x4d, 0x54, 0xe3, 0x02, 0xdc, 0x74, 0x5a, 0x2a, 0x8f, 0x1e, 0x3c, + 0x79, 0x76, 0xbf, 0x36, 0xf5, 0xa6, 0xb4, 0xaa, 0x1d, 0xa7, 0xa2, 0x34, 0xd7, 0xee, 0xfd, 0x56, + 0xde, 0xd8, 0x5e, 0x1a, 0x37, 0x3e, 0x47, 0x0d, 0x97, 0x7b, 0xcf, 0x27, 0x8c, 0x3b, 0xcc, 0x70, + 0xe0, 0xce, 0xa1, 0x49, 0xdf, 0x27, 0xc9, 0xdf, 0x27, 0x39, 0xf6, 0xc4, 0x30, 0x3c, 0x13, 0x21, + 0xf7, 0x6c, 0x7d, 0x3f, 0x99, 0x75, 0x1b, 0x83, 0x15, 0x25, 0x5a, 0xd0, 0xc5, 0xdf, 0xa1, 0x7a, + 0x04, 0x0e, 0x98, 0xc2, 0x0f, 0xff, 0xdd, 0xcb, 0x38, 0x61, 0x06, 0x38, 0x67, 0x12, 0xd5, 0x1b, + 0x69, 0x8e, 0xf3, 0x15, 0x5d, 0x48, 0x62, 0x07, 0xb5, 0x5c, 0x76, 0xf1, 0x95, 0xc7, 0x16, 0x8d, + 0x54, 0xfe, 0x63, 0x23, 0x38, 0x99, 0x75, 0x5b, 0x83, 0x82, 0x16, 0xbd, 0xa5, 0xdd, 0xfb, 0xbb, + 0x8a, 0xde, 0xdc, 0x3a, 0x65, 0xf8, 0x0b, 0x84, 0x7d, 0x23, 0x82, 0x70, 0x02, 0xd6, 0x67, 0xf9, + 0x7f, 0x12, 0xf7, 0xbd, 0x2c, 0xd8, 0x8a, 0xde, 0x91, 0x1f, 0x08, 0x0f, 0xd7, 0x6e, 0xd0, 0x0d, + 0x14, 0xfe, 0x45, 0x41, 0x4d, 0x2b, 0xb7, 0x01, 0xeb, 0xd4, 0xb7, 0xe6, 0x83, 0xf2, 0xf5, 0xff, + 0xf1, 0x1e, 0x48, 0x7f, 0x55, 0xf9, 0xc8, 0x13, 0xe1, 0x54, 0x7f, 0x28, 0x0b, 0x6c, 0x16, 0xce, + 0x68, 0xb1, 0x08, 0x3c, 0x40, 0xd8, 0x5a, 0x48, 0x46, 0xcf, 0x1d, 0xc7, 0xff, 0x11, 0xac, 0x2c, + 0xf2, 0x9a, 0xfe, 0x96, 0x54, 0x78, 0x58, 0xf0, 0x9d, 0x5f, 0xa2, 0x1b, 0x40, 0xfc, 0x0c, 0xb5, + 0xcc, 0x38, 0x0c, 0xc1, 0x13, 0x9f, 0x03, 0x73, 0xc4, 0x68, 0xda, 0xae, 0x66, 0x52, 0xaf, 0x4b, + 0xa9, 0xd6, 0xa7, 0x85, 0x53, 0x7a, 0xeb, 0x76, 0xca, 0x5b, 0x10, 0xf1, 0x10, 0xac, 0x39, 0x5f, + 0x2b, 0xf2, 0xfd, 0xc2, 0x29, 0xbd, 0x75, 0x1b, 0x1f, 0xa2, 0x06, 0x5c, 0x04, 0x60, 0xce, 0x33, + 0xde, 0xcb, 0xe8, 0xd7, 0x24, 0xdd, 0x38, 0x5a, 0x39, 0xa3, 0x85, 0x9b, 0x1d, 0x07, 0xe1, 0xf5, + 0x10, 0xf1, 0x3e, 0xaa, 0x8c, 0x61, 0x9a, 0x7d, 0xf2, 0x97, 0x69, 0xfa, 0x13, 0x7f, 0x82, 0x6a, + 0x13, 0xe6, 0xc4, 0x20, 0x67, 0xff, 0xdd, 0xdd, 0x66, 0xff, 0x4b, 0xee, 0x02, 0xcd, 0xc1, 0x8f, + 0xcb, 0x87, 0x8a, 0xfe, 0xf8, 0xf2, 0x46, 0x2d, 0x5d, 0xdd, 0xa8, 0xa5, 0xeb, 0x1b, 0xb5, 0xf4, + 0x53, 0xa2, 0x2a, 0x97, 0x89, 0xaa, 0x5c, 0x25, 0xaa, 0x72, 0x9d, 0xa8, 0xca, 0x9f, 0x89, 0xaa, + 0xfc, 0xfc, 0x97, 0x5a, 0xfa, 0xe6, 0x25, 0xf9, 0xe1, 0xff, 0x09, 0x00, 0x00, 0xff, 0xff, 0x58, + 0xfb, 0xa1, 0x14, 0x99, 0x08, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto index 7782fd5253..1cdde5a183 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,13 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.policy.v1beta1; +package k8s.io.client_go.pkg.apis.policy.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; @@ -35,15 +35,15 @@ option go_package = "v1beta1"; // created by POSTing to .../pods//evictions. message Eviction { // ObjectMeta describes the pod that is being evicted. - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // DeleteOptions may be provided - optional k8s.io.kubernetes.pkg.api.v1.DeleteOptions deleteOptions = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.DeleteOptions deleteOptions = 2; } // PodDisruptionBudget is an object to define the max disruption that can be caused to a collection of pods message PodDisruptionBudget { - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Specification of the desired behavior of the PodDisruptionBudget. optional PodDisruptionBudgetSpec spec = 2; @@ -54,7 +54,7 @@ message PodDisruptionBudget { // PodDisruptionBudgetList is a collection of PodDisruptionBudgets. message PodDisruptionBudgetList { - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; repeated PodDisruptionBudget items = 2; } @@ -65,11 +65,17 @@ message PodDisruptionBudgetSpec { // "selector" will still be available after the eviction, i.e. even in the // absence of the evicted pod. So for example you can prevent all voluntary // evictions by specifying "100%". - optional k8s.io.kubernetes.pkg.util.intstr.IntOrString minAvailable = 1; + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString minAvailable = 1; // Label query over pods whose evictions are managed by the disruption // budget. - optional k8s.io.kubernetes.pkg.api.unversioned.LabelSelector selector = 2; + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 2; + + // An eviction is allowed if at most "maxUnavailable" pods selected by + // "selector" are unavailable after the eviction, i.e. even in absence of + // the evicted pod. For example, one can prevent all voluntary evictions + // by specifying 0. This is a mutually exclusive setting with "minAvailable". + optional k8s.io.apimachinery.pkg.util.intstr.IntOrString maxUnavailable = 3; } // PodDisruptionBudgetStatus represents information about the status of a @@ -91,7 +97,7 @@ message PodDisruptionBudgetStatus { // the list automatically by PodDisruptionBudget controller after some time. // If everything goes smooth this map should be empty for the most of the time. // Large number of entries in the map may indicate problems with pod deletions. - map disruptedPods = 2; + map disruptedPods = 2; // Number of pod disruptions that are currently allowed. optional int32 disruptionsAllowed = 3; diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/register.go index 9901c28b2f..a3ccc94e6d 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/register.go @@ -17,34 +17,45 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "policy" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1beta1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, RegisterDefaults) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &PodDisruptionBudget{}, &PodDisruptionBudgetList{}, &Eviction{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, ) // Add the watch version that applies - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.generated.go index 387b3f5784..a4636a80ab 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.generated.go @@ -25,10 +25,9 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg2_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_v1 "k8s.io/client-go/pkg/api/v1" - pkg4_types "k8s.io/client-go/pkg/types" - pkg1_intstr "k8s.io/client-go/pkg/util/intstr" + pkg2_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg3_types "k8s.io/apimachinery/pkg/types" + pkg1_intstr "k8s.io/apimachinery/pkg/util/intstr" "reflect" "runtime" time "time" @@ -64,12 +63,11 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg2_unversioned.LabelSelector - var v1 pkg3_v1.ObjectMeta - var v2 pkg4_types.UID - var v3 pkg1_intstr.IntOrString - var v4 time.Time - _, _, _, _, _ = v0, v1, v2, v3, v4 + var v0 pkg2_v1.LabelSelector + var v1 pkg3_types.UID + var v2 pkg1_intstr.IntOrString + var v3 time.Time + _, _, _, _ = v0, v1, v2, v3 } } @@ -87,14 +85,15 @@ func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [2]bool + var yyq2 [3]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false - yyq2[0] = true + yyq2[0] = x.MinAvailable != nil yyq2[1] = x.Selector != nil + yyq2[2] = x.MaxUnavailable != nil var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(2) + r.EncodeArrayStart(3) } else { yynn2 = 0 for _, b := range yyq2 { @@ -108,15 +107,18 @@ func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[0] { - yy4 := &x.MinAvailable - yym5 := z.EncBinary() - _ = yym5 - if false { - } else if z.HasExtensions() && z.EncExt(yy4) { - } else if !yym5 && z.IsJSONHandle() { - z.EncJSONMarshal(yy4) + if x.MinAvailable == nil { + r.EncodeNil() } else { - z.EncFallback(yy4) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else if z.HasExtensions() && z.EncExt(x.MinAvailable) { + } else if !yym4 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MinAvailable) + } else { + z.EncFallback(x.MinAvailable) + } } } else { r.EncodeNil() @@ -126,15 +128,18 @@ func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("minAvailable")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy6 := &x.MinAvailable - yym7 := z.EncBinary() - _ = yym7 - if false { - } else if z.HasExtensions() && z.EncExt(yy6) { - } else if !yym7 && z.IsJSONHandle() { - z.EncJSONMarshal(yy6) + if x.MinAvailable == nil { + r.EncodeNil() } else { - z.EncFallback(yy6) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else if z.HasExtensions() && z.EncExt(x.MinAvailable) { + } else if !yym5 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MinAvailable) + } else { + z.EncFallback(x.MinAvailable) + } } } } @@ -144,8 +149,8 @@ func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x.Selector == nil { r.EncodeNil() } else { - yym9 := z.EncBinary() - _ = yym9 + yym7 := z.EncBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -163,8 +168,8 @@ func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { if x.Selector == nil { r.EncodeNil() } else { - yym10 := z.EncBinary() - _ = yym10 + yym8 := z.EncBinary() + _ = yym8 if false { } else if z.HasExtensions() && z.EncExt(x.Selector) { } else { @@ -173,6 +178,45 @@ func (x *PodDisruptionBudgetSpec) CodecEncodeSelf(e *codec1978.Encoder) { } } } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.MaxUnavailable == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym10 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("maxUnavailable")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.MaxUnavailable == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(x.MaxUnavailable) { + } else if !yym11 && z.IsJSONHandle() { + z.EncJSONMarshal(x.MaxUnavailable) + } else { + z.EncFallback(x.MaxUnavailable) + } + } + } + } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { @@ -186,25 +230,25 @@ func (x *PodDisruptionBudgetSpec) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym11 := z.DecBinary() - _ = yym11 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct12 := r.ContainerType() - if yyct12 == codecSelferValueTypeMap1234 { - yyl12 := r.ReadMapStart() - if yyl12 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl12, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct12 == codecSelferValueTypeArray1234 { - yyl12 := r.ReadArrayStart() - if yyl12 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl12, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -216,12 +260,12 @@ func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys13Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys13Slc - var yyhl13 bool = l >= 0 - for yyj13 := 0; ; yyj13++ { - if yyhl13 { - if yyj13 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -230,23 +274,27 @@ func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys13Slc = r.DecodeBytes(yys13Slc, true, true) - yys13 := string(yys13Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys13 { + switch yys3 { case "minAvailable": if r.TryDecodeAsNil() { - x.MinAvailable = pkg1_intstr.IntOrString{} + if x.MinAvailable != nil { + x.MinAvailable = nil + } } else { - yyv14 := &x.MinAvailable - yym15 := z.DecBinary() - _ = yym15 + if x.MinAvailable == nil { + x.MinAvailable = new(pkg1_intstr.IntOrString) + } + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv14) { - } else if !yym15 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv14) + } else if z.HasExtensions() && z.DecExt(x.MinAvailable) { + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MinAvailable) } else { - z.DecFallback(yyv14, false) + z.DecFallback(x.MinAvailable, false) } } case "selector": @@ -256,20 +304,39 @@ func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } else { if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) + x.Selector = new(pkg2_v1.LabelSelector) } - yym17 := z.DecBinary() - _ = yym17 + yym7 := z.DecBinary() + _ = yym7 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { z.DecFallback(x.Selector, false) } } + case "maxUnavailable": + if r.TryDecodeAsNil() { + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil + } + } else { + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg1_intstr.IntOrString) + } + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) + } else { + z.DecFallback(x.MaxUnavailable, false) + } + } default: - z.DecStructFieldNotFound(-1, yys13) - } // end switch yys13 - } // end for yyj13 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -277,41 +344,45 @@ func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj18 int - var yyb18 bool - var yyhl18 bool = l >= 0 - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.MinAvailable = pkg1_intstr.IntOrString{} + if x.MinAvailable != nil { + x.MinAvailable = nil + } } else { - yyv19 := &x.MinAvailable - yym20 := z.DecBinary() - _ = yym20 + if x.MinAvailable == nil { + x.MinAvailable = new(pkg1_intstr.IntOrString) + } + yym12 := z.DecBinary() + _ = yym12 if false { - } else if z.HasExtensions() && z.DecExt(yyv19) { - } else if !yym20 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv19) + } else if z.HasExtensions() && z.DecExt(x.MinAvailable) { + } else if !yym12 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MinAvailable) } else { - z.DecFallback(yyv19, false) + z.DecFallback(x.MinAvailable, false) } } - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -322,28 +393,57 @@ func (x *PodDisruptionBudgetSpec) codecDecodeSelfFromArray(l int, d *codec1978.D } } else { if x.Selector == nil { - x.Selector = new(pkg2_unversioned.LabelSelector) + x.Selector = new(pkg2_v1.LabelSelector) } - yym22 := z.DecBinary() - _ = yym22 + yym14 := z.DecBinary() + _ = yym14 if false { } else if z.HasExtensions() && z.DecExt(x.Selector) { } else { z.DecFallback(x.Selector, false) } } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + if x.MaxUnavailable != nil { + x.MaxUnavailable = nil + } + } else { + if x.MaxUnavailable == nil { + x.MaxUnavailable = new(pkg1_intstr.IntOrString) + } + yym16 := z.DecBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.DecExt(x.MaxUnavailable) { + } else if !yym16 && z.IsJSONHandle() { + z.DecJSONUnmarshal(x.MaxUnavailable) + } else { + z.DecFallback(x.MaxUnavailable, false) + } + } for { - yyj18++ - if yyhl18 { - yyb18 = yyj18 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb18 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb18 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj18-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -355,35 +455,35 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym23 := z.EncBinary() - _ = yym23 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep24 := !z.EncBinary() - yy2arr24 := z.EncBasicHandle().StructToArray - var yyq24 [6]bool - _, _, _ = yysep24, yyq24, yy2arr24 - const yyr24 bool = false - yyq24[0] = x.ObservedGeneration != 0 - var yynn24 int - if yyr24 || yy2arr24 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [6]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.ObservedGeneration != 0 + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(6) } else { - yynn24 = 5 - for _, b := range yyq24 { + yynn2 = 5 + for _, b := range yyq2 { if b { - yynn24++ + yynn2++ } } - r.EncodeMapStart(yynn24) - yynn24 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq24[0] { - yym26 := z.EncBinary() - _ = yym26 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeInt(int64(x.ObservedGeneration)) @@ -392,28 +492,28 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeInt(0) } } else { - if yyq24[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("observedGeneration")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym27 := z.EncBinary() - _ = yym27 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeInt(int64(x.ObservedGeneration)) } } } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.DisruptedPods == nil { r.EncodeNil() } else { - yym29 := z.EncBinary() - _ = yym29 + yym7 := z.EncBinary() + _ = yym7 if false { } else { - h.encMapstringunversioned_Time((map[string]pkg2_unversioned.Time)(x.DisruptedPods), e) + h.encMapstringv1_Time((map[string]pkg2_v1.Time)(x.DisruptedPods), e) } } } else { @@ -423,18 +523,18 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { if x.DisruptedPods == nil { r.EncodeNil() } else { - yym30 := z.EncBinary() - _ = yym30 + yym8 := z.EncBinary() + _ = yym8 if false { } else { - h.encMapstringunversioned_Time((map[string]pkg2_unversioned.Time)(x.DisruptedPods), e) + h.encMapstringv1_Time((map[string]pkg2_v1.Time)(x.DisruptedPods), e) } } } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym32 := z.EncBinary() - _ = yym32 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeInt(int64(x.PodDisruptionsAllowed)) @@ -443,17 +543,17 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("disruptionsAllowed")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym33 := z.EncBinary() - _ = yym33 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeInt(int64(x.PodDisruptionsAllowed)) } } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym35 := z.EncBinary() - _ = yym35 + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeInt(int64(x.CurrentHealthy)) @@ -462,17 +562,17 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("currentHealthy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym36 := z.EncBinary() - _ = yym36 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeInt(int64(x.CurrentHealthy)) } } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym38 := z.EncBinary() - _ = yym38 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeInt(int64(x.DesiredHealthy)) @@ -481,17 +581,17 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("desiredHealthy")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym39 := z.EncBinary() - _ = yym39 + yym17 := z.EncBinary() + _ = yym17 if false { } else { r.EncodeInt(int64(x.DesiredHealthy)) } } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym41 := z.EncBinary() - _ = yym41 + yym19 := z.EncBinary() + _ = yym19 if false { } else { r.EncodeInt(int64(x.ExpectedPods)) @@ -500,14 +600,14 @@ func (x *PodDisruptionBudgetStatus) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("expectedPods")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym42 := z.EncBinary() - _ = yym42 + yym20 := z.EncBinary() + _ = yym20 if false { } else { r.EncodeInt(int64(x.ExpectedPods)) } } - if yyr24 || yy2arr24 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -520,25 +620,25 @@ func (x *PodDisruptionBudgetStatus) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym43 := z.DecBinary() - _ = yym43 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct44 := r.ContainerType() - if yyct44 == codecSelferValueTypeMap1234 { - yyl44 := r.ReadMapStart() - if yyl44 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl44, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct44 == codecSelferValueTypeArray1234 { - yyl44 := r.ReadArrayStart() - if yyl44 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl44, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -550,12 +650,12 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromMap(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys45Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys45Slc - var yyhl45 bool = l >= 0 - for yyj45 := 0; ; yyj45++ { - if yyhl45 { - if yyj45 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -564,56 +664,86 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromMap(l int, d *codec1978.D } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys45Slc = r.DecodeBytes(yys45Slc, true, true) - yys45 := string(yys45Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys45 { + switch yys3 { case "observedGeneration": if r.TryDecodeAsNil() { x.ObservedGeneration = 0 } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) + yyv4 := &x.ObservedGeneration + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*int64)(yyv4)) = int64(r.DecodeInt(64)) + } } case "disruptedPods": if r.TryDecodeAsNil() { x.DisruptedPods = nil } else { - yyv47 := &x.DisruptedPods - yym48 := z.DecBinary() - _ = yym48 + yyv6 := &x.DisruptedPods + yym7 := z.DecBinary() + _ = yym7 if false { } else { - h.decMapstringunversioned_Time((*map[string]pkg2_unversioned.Time)(yyv47), d) + h.decMapstringv1_Time((*map[string]pkg2_v1.Time)(yyv6), d) } } case "disruptionsAllowed": if r.TryDecodeAsNil() { x.PodDisruptionsAllowed = 0 } else { - x.PodDisruptionsAllowed = int32(r.DecodeInt(32)) + yyv8 := &x.PodDisruptionsAllowed + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*int32)(yyv8)) = int32(r.DecodeInt(32)) + } } case "currentHealthy": if r.TryDecodeAsNil() { x.CurrentHealthy = 0 } else { - x.CurrentHealthy = int32(r.DecodeInt(32)) + yyv10 := &x.CurrentHealthy + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*int32)(yyv10)) = int32(r.DecodeInt(32)) + } } case "desiredHealthy": if r.TryDecodeAsNil() { x.DesiredHealthy = 0 } else { - x.DesiredHealthy = int32(r.DecodeInt(32)) + yyv12 := &x.DesiredHealthy + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + *((*int32)(yyv12)) = int32(r.DecodeInt(32)) + } } case "expectedPods": if r.TryDecodeAsNil() { x.ExpectedPods = 0 } else { - x.ExpectedPods = int32(r.DecodeInt(32)) + yyv14 := &x.ExpectedPods + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*int32)(yyv14)) = int32(r.DecodeInt(32)) + } } default: - z.DecStructFieldNotFound(-1, yys45) - } // end switch yys45 - } // end for yyj45 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -621,16 +751,16 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj53 int - var yyb53 bool - var yyhl53 bool = l >= 0 - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + var yyj16 int + var yyb16 bool + var yyhl16 bool = l >= 0 + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -638,15 +768,21 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.ObservedGeneration = 0 } else { - x.ObservedGeneration = int64(r.DecodeInt(64)) + yyv17 := &x.ObservedGeneration + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*int64)(yyv17)) = int64(r.DecodeInt(64)) + } } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -654,21 +790,21 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.DisruptedPods = nil } else { - yyv55 := &x.DisruptedPods - yym56 := z.DecBinary() - _ = yym56 + yyv19 := &x.DisruptedPods + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decMapstringunversioned_Time((*map[string]pkg2_unversioned.Time)(yyv55), d) + h.decMapstringv1_Time((*map[string]pkg2_v1.Time)(yyv19), d) } } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -676,15 +812,21 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.PodDisruptionsAllowed = 0 } else { - x.PodDisruptionsAllowed = int32(r.DecodeInt(32)) + yyv21 := &x.PodDisruptionsAllowed + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*int32)(yyv21)) = int32(r.DecodeInt(32)) + } } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -692,15 +834,21 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.CurrentHealthy = 0 } else { - x.CurrentHealthy = int32(r.DecodeInt(32)) + yyv23 := &x.CurrentHealthy + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + *((*int32)(yyv23)) = int32(r.DecodeInt(32)) + } } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -708,15 +856,21 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.DesiredHealthy = 0 } else { - x.DesiredHealthy = int32(r.DecodeInt(32)) + yyv25 := &x.DesiredHealthy + yym26 := z.DecBinary() + _ = yym26 + if false { + } else { + *((*int32)(yyv25)) = int32(r.DecodeInt(32)) + } } - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -724,20 +878,26 @@ func (x *PodDisruptionBudgetStatus) codecDecodeSelfFromArray(l int, d *codec1978 if r.TryDecodeAsNil() { x.ExpectedPods = 0 } else { - x.ExpectedPods = int32(r.DecodeInt(32)) + yyv27 := &x.ExpectedPods + yym28 := z.DecBinary() + _ = yym28 + if false { + } else { + *((*int32)(yyv27)) = int32(r.DecodeInt(32)) + } } for { - yyj53++ - if yyhl53 { - yyb53 = yyj53 > l + yyj16++ + if yyhl16 { + yyb16 = yyj16 > l } else { - yyb53 = r.CheckBreak() + yyb16 = r.CheckBreak() } - if yyb53 { + if yyb16 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj53-1, "") + z.DecStructFieldNotFound(yyj16-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -749,39 +909,39 @@ func (x *PodDisruptionBudget) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym61 := z.EncBinary() - _ = yym61 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep62 := !z.EncBinary() - yy2arr62 := z.EncBasicHandle().StructToArray - var yyq62 [5]bool - _, _, _ = yysep62, yyq62, yy2arr62 - const yyr62 bool = false - yyq62[0] = x.Kind != "" - yyq62[1] = x.APIVersion != "" - yyq62[2] = true - yyq62[3] = true - yyq62[4] = true - var yynn62 int - if yyr62 || yy2arr62 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = true + yyq2[4] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn62 = 0 - for _, b := range yyq62 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn62++ + yynn2++ } } - r.EncodeMapStart(yynn62) - yynn62 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr62 || yy2arr62 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[0] { - yym64 := z.EncBinary() - _ = yym64 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -790,23 +950,23 @@ func (x *PodDisruptionBudget) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq62[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym65 := z.EncBinary() - _ = yym65 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr62 || yy2arr62 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[1] { - yym67 := z.EncBinary() - _ = yym67 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -815,70 +975,82 @@ func (x *PodDisruptionBudget) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq62[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym68 := z.EncBinary() - _ = yym68 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr62 || yy2arr62 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[2] { - yy70 := &x.ObjectMeta - yy70.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq62[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy71 := &x.ObjectMeta - yy71.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr62 || yy2arr62 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[3] { - yy73 := &x.Spec - yy73.CodecEncodeSelf(e) + if yyq2[3] { + yy15 := &x.Spec + yy15.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq62[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("spec")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy74 := &x.Spec - yy74.CodecEncodeSelf(e) + yy17 := &x.Spec + yy17.CodecEncodeSelf(e) } } - if yyr62 || yy2arr62 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq62[4] { - yy76 := &x.Status - yy76.CodecEncodeSelf(e) + if yyq2[4] { + yy20 := &x.Status + yy20.CodecEncodeSelf(e) } else { r.EncodeNil() } } else { - if yyq62[4] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("status")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy77 := &x.Status - yy77.CodecEncodeSelf(e) + yy22 := &x.Status + yy22.CodecEncodeSelf(e) } } - if yyr62 || yy2arr62 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -891,25 +1063,25 @@ func (x *PodDisruptionBudget) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym78 := z.DecBinary() - _ = yym78 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct79 := r.ContainerType() - if yyct79 == codecSelferValueTypeMap1234 { - yyl79 := r.ReadMapStart() - if yyl79 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl79, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct79 == codecSelferValueTypeArray1234 { - yyl79 := r.ReadArrayStart() - if yyl79 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl79, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -921,12 +1093,12 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys80Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys80Slc - var yyhl80 bool = l >= 0 - for yyj80 := 0; ; yyj80++ { - if yyhl80 { - if yyj80 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -935,47 +1107,65 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromMap(l int, d *codec1978.Decoder } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys80Slc = r.DecodeBytes(yys80Slc, true, true) - yys80 := string(yys80Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys80 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv83 := &x.ObjectMeta - yyv83.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "spec": if r.TryDecodeAsNil() { x.Spec = PodDisruptionBudgetSpec{} } else { - yyv84 := &x.Spec - yyv84.CodecDecodeSelf(d) + yyv10 := &x.Spec + yyv10.CodecDecodeSelf(d) } case "status": if r.TryDecodeAsNil() { x.Status = PodDisruptionBudgetStatus{} } else { - yyv85 := &x.Status - yyv85.CodecDecodeSelf(d) + yyv11 := &x.Status + yyv11.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys80) - } // end switch yys80 - } // end for yyj80 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -983,16 +1173,16 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromArray(l int, d *codec1978.Decod var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj86 int - var yyb86 bool - var yyhl86 bool = l >= 0 - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb86 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb86 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1000,15 +1190,21 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb86 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb86 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1016,32 +1212,44 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb86 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb86 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv89 := &x.ObjectMeta - yyv89.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb86 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb86 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1049,16 +1257,16 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Spec = PodDisruptionBudgetSpec{} } else { - yyv90 := &x.Spec - yyv90.CodecDecodeSelf(d) + yyv19 := &x.Spec + yyv19.CodecDecodeSelf(d) } - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb86 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb86 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1066,21 +1274,21 @@ func (x *PodDisruptionBudget) codecDecodeSelfFromArray(l int, d *codec1978.Decod if r.TryDecodeAsNil() { x.Status = PodDisruptionBudgetStatus{} } else { - yyv91 := &x.Status - yyv91.CodecDecodeSelf(d) + yyv20 := &x.Status + yyv20.CodecDecodeSelf(d) } for { - yyj86++ - if yyhl86 { - yyb86 = yyj86 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb86 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb86 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj86-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1092,37 +1300,37 @@ func (x *PodDisruptionBudgetList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym92 := z.EncBinary() - _ = yym92 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep93 := !z.EncBinary() - yy2arr93 := z.EncBasicHandle().StructToArray - var yyq93 [4]bool - _, _, _ = yysep93, yyq93, yy2arr93 - const yyr93 bool = false - yyq93[0] = x.Kind != "" - yyq93[1] = x.APIVersion != "" - yyq93[2] = true - var yynn93 int - if yyr93 || yy2arr93 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn93 = 1 - for _, b := range yyq93 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn93++ + yynn2++ } } - r.EncodeMapStart(yynn93) - yynn93 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr93 || yy2arr93 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq93[0] { - yym95 := z.EncBinary() - _ = yym95 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1131,23 +1339,23 @@ func (x *PodDisruptionBudgetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq93[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym96 := z.EncBinary() - _ = yym96 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr93 || yy2arr93 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq93[1] { - yym98 := z.EncBinary() - _ = yym98 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1156,54 +1364,54 @@ func (x *PodDisruptionBudgetList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq93[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym99 := z.EncBinary() - _ = yym99 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr93 || yy2arr93 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq93[2] { - yy101 := &x.ListMeta - yym102 := z.EncBinary() - _ = yym102 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy101) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy101) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq93[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy103 := &x.ListMeta - yym104 := z.EncBinary() - _ = yym104 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy103) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy103) + z.EncFallback(yy12) } } } - if yyr93 || yy2arr93 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym106 := z.EncBinary() - _ = yym106 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePodDisruptionBudget(([]PodDisruptionBudget)(x.Items), e) @@ -1216,15 +1424,15 @@ func (x *PodDisruptionBudgetList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym107 := z.EncBinary() - _ = yym107 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePodDisruptionBudget(([]PodDisruptionBudget)(x.Items), e) } } } - if yyr93 || yy2arr93 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1237,25 +1445,25 @@ func (x *PodDisruptionBudgetList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym108 := z.DecBinary() - _ = yym108 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct109 := r.ContainerType() - if yyct109 == codecSelferValueTypeMap1234 { - yyl109 := r.ReadMapStart() - if yyl109 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl109, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct109 == codecSelferValueTypeArray1234 { - yyl109 := r.ReadArrayStart() - if yyl109 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl109, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1267,12 +1475,12 @@ func (x *PodDisruptionBudgetList) codecDecodeSelfFromMap(l int, d *codec1978.Dec var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys110Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys110Slc - var yyhl110 bool = l >= 0 - for yyj110 := 0; ; yyj110++ { - if yyhl110 { - if yyj110 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1281,51 +1489,63 @@ func (x *PodDisruptionBudgetList) codecDecodeSelfFromMap(l int, d *codec1978.Dec } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys110Slc = r.DecodeBytes(yys110Slc, true, true) - yys110 := string(yys110Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys110 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv113 := &x.ListMeta - yym114 := z.DecBinary() - _ = yym114 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv113) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv113, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv115 := &x.Items - yym116 := z.DecBinary() - _ = yym116 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePodDisruptionBudget((*[]PodDisruptionBudget)(yyv115), d) + h.decSlicePodDisruptionBudget((*[]PodDisruptionBudget)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys110) - } // end switch yys110 - } // end for yyj110 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1333,16 +1553,16 @@ func (x *PodDisruptionBudgetList) codecDecodeSelfFromArray(l int, d *codec1978.D var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj117 int - var yyb117 bool - var yyhl117 bool = l >= 0 - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb117 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb117 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1350,15 +1570,21 @@ func (x *PodDisruptionBudgetList) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb117 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb117 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1366,38 +1592,44 @@ func (x *PodDisruptionBudgetList) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb117 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb117 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg2_v1.ListMeta{} } else { - yyv120 := &x.ListMeta - yym121 := z.DecBinary() - _ = yym121 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv120) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv120, false) + z.DecFallback(yyv17, false) } } - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb117 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb117 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1405,26 +1637,26 @@ func (x *PodDisruptionBudgetList) codecDecodeSelfFromArray(l int, d *codec1978.D if r.TryDecodeAsNil() { x.Items = nil } else { - yyv122 := &x.Items - yym123 := z.DecBinary() - _ = yym123 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePodDisruptionBudget((*[]PodDisruptionBudget)(yyv122), d) + h.decSlicePodDisruptionBudget((*[]PodDisruptionBudget)(yyv19), d) } } for { - yyj117++ - if yyhl117 { - yyb117 = yyj117 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb117 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb117 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj117-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1436,38 +1668,38 @@ func (x *Eviction) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym124 := z.EncBinary() - _ = yym124 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep125 := !z.EncBinary() - yy2arr125 := z.EncBasicHandle().StructToArray - var yyq125 [4]bool - _, _, _ = yysep125, yyq125, yy2arr125 - const yyr125 bool = false - yyq125[0] = x.Kind != "" - yyq125[1] = x.APIVersion != "" - yyq125[2] = true - yyq125[3] = x.DeleteOptions != nil - var yynn125 int - if yyr125 || yy2arr125 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + yyq2[3] = x.DeleteOptions != nil + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn125 = 0 - for _, b := range yyq125 { + yynn2 = 0 + for _, b := range yyq2 { if b { - yynn125++ + yynn2++ } } - r.EncodeMapStart(yynn125) - yynn125 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr125 || yy2arr125 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[0] { - yym127 := z.EncBinary() - _ = yym127 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1476,23 +1708,23 @@ func (x *Eviction) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq125[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym128 := z.EncBinary() - _ = yym128 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr125 || yy2arr125 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[1] { - yym130 := z.EncBinary() - _ = yym130 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1501,59 +1733,83 @@ func (x *Eviction) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq125[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym131 := z.EncBinary() - _ = yym131 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr125 || yy2arr125 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[2] { - yy133 := &x.ObjectMeta - yy133.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq125[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy134 := &x.ObjectMeta - yy134.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr125 || yy2arr125 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq125[3] { + if yyq2[3] { if x.DeleteOptions == nil { r.EncodeNil() } else { - x.DeleteOptions.CodecEncodeSelf(e) + yym15 := z.EncBinary() + _ = yym15 + if false { + } else if z.HasExtensions() && z.EncExt(x.DeleteOptions) { + } else { + z.EncFallback(x.DeleteOptions) + } } } else { r.EncodeNil() } } else { - if yyq125[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("deleteOptions")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.DeleteOptions == nil { r.EncodeNil() } else { - x.DeleteOptions.CodecEncodeSelf(e) + yym16 := z.EncBinary() + _ = yym16 + if false { + } else if z.HasExtensions() && z.EncExt(x.DeleteOptions) { + } else { + z.EncFallback(x.DeleteOptions) + } } } } - if yyr125 || yy2arr125 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1566,25 +1822,25 @@ func (x *Eviction) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym136 := z.DecBinary() - _ = yym136 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct137 := r.ContainerType() - if yyct137 == codecSelferValueTypeMap1234 { - yyl137 := r.ReadMapStart() - if yyl137 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl137, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct137 == codecSelferValueTypeArray1234 { - yyl137 := r.ReadArrayStart() - if yyl137 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl137, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1596,12 +1852,12 @@ func (x *Eviction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys138Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys138Slc - var yyhl138 bool = l >= 0 - for yyj138 := 0; ; yyj138++ { - if yyhl138 { - if yyj138 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1610,28 +1866,46 @@ func (x *Eviction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys138Slc = r.DecodeBytes(yys138Slc, true, true) - yys138 := string(yys138Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys138 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv141 := &x.ObjectMeta - yyv141.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "deleteOptions": if r.TryDecodeAsNil() { @@ -1640,14 +1914,20 @@ func (x *Eviction) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } else { if x.DeleteOptions == nil { - x.DeleteOptions = new(pkg3_v1.DeleteOptions) + x.DeleteOptions = new(pkg2_v1.DeleteOptions) + } + yym11 := z.DecBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.DecExt(x.DeleteOptions) { + } else { + z.DecFallback(x.DeleteOptions, false) } - x.DeleteOptions.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys138) - } // end switch yys138 - } // end for yyj138 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1655,16 +1935,16 @@ func (x *Eviction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj143 int - var yyb143 bool - var yyhl143 bool = l >= 0 - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb143 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb143 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1672,15 +1952,21 @@ func (x *Eviction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb143 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb143 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1688,32 +1974,44 @@ func (x *Eviction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb143 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb143 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg2_v1.ObjectMeta{} } else { - yyv146 := &x.ObjectMeta - yyv146.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb143 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb143 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1724,145 +2022,163 @@ func (x *Eviction) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { } } else { if x.DeleteOptions == nil { - x.DeleteOptions = new(pkg3_v1.DeleteOptions) + x.DeleteOptions = new(pkg2_v1.DeleteOptions) + } + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(x.DeleteOptions) { + } else { + z.DecFallback(x.DeleteOptions, false) } - x.DeleteOptions.CodecDecodeSelf(d) } for { - yyj143++ - if yyhl143 { - yyb143 = yyj143 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb143 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb143 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj143-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } -func (x codecSelfer1234) encMapstringunversioned_Time(v map[string]pkg2_unversioned.Time, e *codec1978.Encoder) { +func (x codecSelfer1234) encMapstringv1_Time(v map[string]pkg2_v1.Time, e *codec1978.Encoder) { var h codecSelfer1234 z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeMapStart(len(v)) - for yyk148, yyv148 := range v { + for yyk1, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerMapKey1234) - yym149 := z.EncBinary() - _ = yym149 + yym2 := z.EncBinary() + _ = yym2 if false { } else { - r.EncodeString(codecSelferC_UTF81234, string(yyk148)) + r.EncodeString(codecSelferC_UTF81234, string(yyk1)) } z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy150 := &yyv148 - yym151 := z.EncBinary() - _ = yym151 + yy3 := &yyv1 + yym4 := z.EncBinary() + _ = yym4 if false { - } else if z.HasExtensions() && z.EncExt(yy150) { - } else if yym151 { - z.EncBinaryMarshal(yy150) - } else if !yym151 && z.IsJSONHandle() { - z.EncJSONMarshal(yy150) + } else if z.HasExtensions() && z.EncExt(yy3) { + } else if yym4 { + z.EncBinaryMarshal(yy3) + } else if !yym4 && z.IsJSONHandle() { + z.EncJSONMarshal(yy3) } else { - z.EncFallback(yy150) + z.EncFallback(yy3) } } z.EncSendContainerState(codecSelfer_containerMapEnd1234) } -func (x codecSelfer1234) decMapstringunversioned_Time(v *map[string]pkg2_unversioned.Time, d *codec1978.Decoder) { +func (x codecSelfer1234) decMapstringv1_Time(v *map[string]pkg2_v1.Time, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv152 := *v - yyl152 := r.ReadMapStart() - yybh152 := z.DecBasicHandle() - if yyv152 == nil { - yyrl152, _ := z.DecInferLen(yyl152, yybh152.MaxInitLen, 40) - yyv152 = make(map[string]pkg2_unversioned.Time, yyrl152) - *v = yyv152 - } - var yymk152 string - var yymv152 pkg2_unversioned.Time - var yymg152 bool - if yybh152.MapValueReset { - yymg152 = true - } - if yyl152 > 0 { - for yyj152 := 0; yyj152 < yyl152; yyj152++ { + yyv1 := *v + yyl1 := r.ReadMapStart() + yybh1 := z.DecBasicHandle() + if yyv1 == nil { + yyrl1, _ := z.DecInferLen(yyl1, yybh1.MaxInitLen, 40) + yyv1 = make(map[string]pkg2_v1.Time, yyrl1) + *v = yyv1 + } + var yymk1 string + var yymv1 pkg2_v1.Time + var yymg1 bool + if yybh1.MapValueReset { + yymg1 = true + } + if yyl1 > 0 { + for yyj1 := 0; yyj1 < yyl1; yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk152 = "" + yymk1 = "" } else { - yymk152 = string(r.DecodeString()) + yyv2 := &yymk1 + yym3 := z.DecBinary() + _ = yym3 + if false { + } else { + *((*string)(yyv2)) = r.DecodeString() + } } - if yymg152 { - yymv152 = yyv152[yymk152] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv152 = pkg2_unversioned.Time{} + yymv1 = pkg2_v1.Time{} } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv152 = pkg2_unversioned.Time{} + yymv1 = pkg2_v1.Time{} } else { - yyv154 := &yymv152 - yym155 := z.DecBinary() - _ = yym155 + yyv4 := &yymv1 + yym5 := z.DecBinary() + _ = yym5 if false { - } else if z.HasExtensions() && z.DecExt(yyv154) { - } else if yym155 { - z.DecBinaryUnmarshal(yyv154) - } else if !yym155 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv154) + } else if z.HasExtensions() && z.DecExt(yyv4) { + } else if yym5 { + z.DecBinaryUnmarshal(yyv4) + } else if !yym5 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv4) } else { - z.DecFallback(yyv154, false) + z.DecFallback(yyv4, false) } } - if yyv152 != nil { - yyv152[yymk152] = yymv152 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } - } else if yyl152 < 0 { - for yyj152 := 0; !r.CheckBreak(); yyj152++ { + } else if yyl1 < 0 { + for yyj1 := 0; !r.CheckBreak(); yyj1++ { z.DecSendContainerState(codecSelfer_containerMapKey1234) if r.TryDecodeAsNil() { - yymk152 = "" + yymk1 = "" } else { - yymk152 = string(r.DecodeString()) + yyv6 := &yymk1 + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } - if yymg152 { - yymv152 = yyv152[yymk152] + if yymg1 { + yymv1 = yyv1[yymk1] } else { - yymv152 = pkg2_unversioned.Time{} + yymv1 = pkg2_v1.Time{} } z.DecSendContainerState(codecSelfer_containerMapValue1234) if r.TryDecodeAsNil() { - yymv152 = pkg2_unversioned.Time{} + yymv1 = pkg2_v1.Time{} } else { - yyv157 := &yymv152 - yym158 := z.DecBinary() - _ = yym158 + yyv8 := &yymv1 + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv157) { - } else if yym158 { - z.DecBinaryUnmarshal(yyv157) - } else if !yym158 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv157) + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else if yym9 { + z.DecBinaryUnmarshal(yyv8) + } else if !yym9 && z.IsJSONHandle() { + z.DecJSONUnmarshal(yyv8) } else { - z.DecFallback(yyv157, false) + z.DecFallback(yyv8, false) } } - if yyv152 != nil { - yyv152[yymk152] = yymv152 + if yyv1 != nil { + yyv1[yymk1] = yymv1 } } } // else len==0: TODO: Should we clear map entries? @@ -1874,10 +2190,10 @@ func (x codecSelfer1234) encSlicePodDisruptionBudget(v []PodDisruptionBudget, e z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv159 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy160 := &yyv159 - yy160.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1887,83 +2203,86 @@ func (x codecSelfer1234) decSlicePodDisruptionBudget(v *[]PodDisruptionBudget, d z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv161 := *v - yyh161, yyl161 := z.DecSliceHelperStart() - var yyc161 bool - if yyl161 == 0 { - if yyv161 == nil { - yyv161 = []PodDisruptionBudget{} - yyc161 = true - } else if len(yyv161) != 0 { - yyv161 = yyv161[:0] - yyc161 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PodDisruptionBudget{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl161 > 0 { - var yyrr161, yyrl161 int - var yyrt161 bool - if yyl161 > cap(yyv161) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg161 := len(yyv161) > 0 - yyv2161 := yyv161 - yyrl161, yyrt161 = z.DecInferLen(yyl161, z.DecBasicHandle().MaxInitLen, 328) - if yyrt161 { - if yyrl161 <= cap(yyv161) { - yyv161 = yyv161[:yyrl161] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 320) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv161 = make([]PodDisruptionBudget, yyrl161) + yyv1 = make([]PodDisruptionBudget, yyrl1) } } else { - yyv161 = make([]PodDisruptionBudget, yyrl161) + yyv1 = make([]PodDisruptionBudget, yyrl1) } - yyc161 = true - yyrr161 = len(yyv161) - if yyrg161 { - copy(yyv161, yyv2161) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl161 != len(yyv161) { - yyv161 = yyv161[:yyl161] - yyc161 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj161 := 0 - for ; yyj161 < yyrr161; yyj161++ { - yyh161.ElemContainerState(yyj161) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv161[yyj161] = PodDisruptionBudget{} + yyv1[yyj1] = PodDisruptionBudget{} } else { - yyv162 := &yyv161[yyj161] - yyv162.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt161 { - for ; yyj161 < yyl161; yyj161++ { - yyv161 = append(yyv161, PodDisruptionBudget{}) - yyh161.ElemContainerState(yyj161) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PodDisruptionBudget{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv161[yyj161] = PodDisruptionBudget{} + yyv1[yyj1] = PodDisruptionBudget{} } else { - yyv163 := &yyv161[yyj161] - yyv163.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj161 := 0 - for ; !r.CheckBreak(); yyj161++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj161 >= len(yyv161) { - yyv161 = append(yyv161, PodDisruptionBudget{}) // var yyz161 PodDisruptionBudget - yyc161 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PodDisruptionBudget{}) // var yyz1 PodDisruptionBudget + yyc1 = true } - yyh161.ElemContainerState(yyj161) - if yyj161 < len(yyv161) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv161[yyj161] = PodDisruptionBudget{} + yyv1[yyj1] = PodDisruptionBudget{} } else { - yyv164 := &yyv161[yyj161] - yyv164.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -1971,16 +2290,16 @@ func (x codecSelfer1234) decSlicePodDisruptionBudget(v *[]PodDisruptionBudget, d } } - if yyj161 < len(yyv161) { - yyv161 = yyv161[:yyj161] - yyc161 = true - } else if yyj161 == 0 && yyv161 == nil { - yyv161 = []PodDisruptionBudget{} - yyc161 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PodDisruptionBudget{} + yyc1 = true } } - yyh161.End() - if yyc161 { - *v = yyv161 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.go index cc892d965a..6cc56256a6 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types.go @@ -17,9 +17,8 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/util/intstr" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/util/intstr" ) // PodDisruptionBudgetSpec is a description of a PodDisruptionBudget. @@ -28,11 +27,17 @@ type PodDisruptionBudgetSpec struct { // "selector" will still be available after the eviction, i.e. even in the // absence of the evicted pod. So for example you can prevent all voluntary // evictions by specifying "100%". - MinAvailable intstr.IntOrString `json:"minAvailable,omitempty" protobuf:"bytes,1,opt,name=minAvailable"` + MinAvailable *intstr.IntOrString `json:"minAvailable,omitempty" protobuf:"bytes,1,opt,name=minAvailable"` // Label query over pods whose evictions are managed by the disruption // budget. - Selector *unversioned.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` + Selector *metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,2,opt,name=selector"` + + // An eviction is allowed if at most "maxUnavailable" pods selected by + // "selector" are unavailable after the eviction, i.e. even in absence of + // the evicted pod. For example, one can prevent all voluntary evictions + // by specifying 0. This is a mutually exclusive setting with "minAvailable". + MaxUnavailable *intstr.IntOrString `json:"maxUnavailable,omitempty" protobuf:"bytes,3,opt,name=maxUnavailable"` } // PodDisruptionBudgetStatus represents information about the status of a @@ -54,7 +59,7 @@ type PodDisruptionBudgetStatus struct { // the list automatically by PodDisruptionBudget controller after some time. // If everything goes smooth this map should be empty for the most of the time. // Large number of entries in the map may indicate problems with pod deletions. - DisruptedPods map[string]unversioned.Time `json:"disruptedPods" protobuf:"bytes,2,rep,name=disruptedPods"` + DisruptedPods map[string]metav1.Time `json:"disruptedPods" protobuf:"bytes,2,rep,name=disruptedPods"` // Number of pod disruptions that are currently allowed. PodDisruptionsAllowed int32 `json:"disruptionsAllowed" protobuf:"varint,3,opt,name=disruptionsAllowed"` @@ -73,8 +78,8 @@ type PodDisruptionBudgetStatus struct { // PodDisruptionBudget is an object to define the max disruption that can be caused to a collection of pods type PodDisruptionBudget struct { - unversioned.TypeMeta `json:",inline"` - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.TypeMeta `json:",inline"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Specification of the desired behavior of the PodDisruptionBudget. Spec PodDisruptionBudgetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` @@ -84,20 +89,23 @@ type PodDisruptionBudget struct { // PodDisruptionBudgetList is a collection of PodDisruptionBudgets. type PodDisruptionBudgetList struct { - unversioned.TypeMeta `json:",inline"` - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` - Items []PodDisruptionBudget `json:"items" protobuf:"bytes,2,rep,name=items"` + metav1.TypeMeta `json:",inline"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + Items []PodDisruptionBudget `json:"items" protobuf:"bytes,2,rep,name=items"` } +// +genclient=true +// +noMethods=true + // Eviction evicts a pod from its node subject to certain policies and safety constraints. // This is a subresource of Pod. A request to cause such an eviction is // created by POSTing to .../pods//evictions. type Eviction struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // ObjectMeta describes the pod that is being evicted. - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // DeleteOptions may be provided - DeleteOptions *v1.DeleteOptions `json:"deleteOptions,omitempty" protobuf:"bytes,2,opt,name=deleteOptions"` + DeleteOptions *metav1.DeleteOptions `json:"deleteOptions,omitempty" protobuf:"bytes,2,opt,name=deleteOptions"` } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types_swagger_doc_generated.go index d919856b25..29432506df 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/types_swagger_doc_generated.go @@ -56,9 +56,10 @@ func (PodDisruptionBudgetList) SwaggerDoc() map[string]string { } var map_PodDisruptionBudgetSpec = map[string]string{ - "": "PodDisruptionBudgetSpec is a description of a PodDisruptionBudget.", - "minAvailable": "An eviction is allowed if at least \"minAvailable\" pods selected by \"selector\" will still be available after the eviction, i.e. even in the absence of the evicted pod. So for example you can prevent all voluntary evictions by specifying \"100%\".", - "selector": "Label query over pods whose evictions are managed by the disruption budget.", + "": "PodDisruptionBudgetSpec is a description of a PodDisruptionBudget.", + "minAvailable": "An eviction is allowed if at least \"minAvailable\" pods selected by \"selector\" will still be available after the eviction, i.e. even in the absence of the evicted pod. So for example you can prevent all voluntary evictions by specifying \"100%\".", + "selector": "Label query over pods whose evictions are managed by the disruption budget.", + "maxUnavailable": "An eviction is allowed if at most \"maxUnavailable\" pods selected by \"selector\" are unavailable after the eviction, i.e. even in absence of the evicted pod. For example, one can prevent all voluntary evictions by specifying 0. This is a mutually exclusive setting with \"minAvailable\".", } func (PodDisruptionBudgetSpec) SwaggerDoc() map[string]string { diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.conversion.go index 1cb8af3b74..b10663a02c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,12 +21,11 @@ limitations under the License. package v1beta1 import ( - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" policy "k8s.io/client-go/pkg/apis/policy" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -52,36 +51,29 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v1beta1_Eviction_To_policy_Eviction(in *Eviction, out *policy.Eviction, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - out.DeleteOptions = (*api.DeleteOptions)(unsafe.Pointer(in.DeleteOptions)) + out.ObjectMeta = in.ObjectMeta + out.DeleteOptions = (*v1.DeleteOptions)(unsafe.Pointer(in.DeleteOptions)) return nil } +// Convert_v1beta1_Eviction_To_policy_Eviction is an autogenerated conversion function. func Convert_v1beta1_Eviction_To_policy_Eviction(in *Eviction, out *policy.Eviction, s conversion.Scope) error { return autoConvert_v1beta1_Eviction_To_policy_Eviction(in, out, s) } func autoConvert_policy_Eviction_To_v1beta1_Eviction(in *policy.Eviction, out *Eviction, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.DeleteOptions = (*v1.DeleteOptions)(unsafe.Pointer(in.DeleteOptions)) return nil } +// Convert_policy_Eviction_To_v1beta1_Eviction is an autogenerated conversion function. func Convert_policy_Eviction_To_v1beta1_Eviction(in *policy.Eviction, out *Eviction, s conversion.Scope) error { return autoConvert_policy_Eviction_To_v1beta1_Eviction(in, out, s) } func autoConvert_v1beta1_PodDisruptionBudget_To_policy_PodDisruptionBudget(in *PodDisruptionBudget, out *policy.PodDisruptionBudget, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_v1beta1_PodDisruptionBudgetSpec_To_policy_PodDisruptionBudgetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -91,15 +83,13 @@ func autoConvert_v1beta1_PodDisruptionBudget_To_policy_PodDisruptionBudget(in *P return nil } +// Convert_v1beta1_PodDisruptionBudget_To_policy_PodDisruptionBudget is an autogenerated conversion function. func Convert_v1beta1_PodDisruptionBudget_To_policy_PodDisruptionBudget(in *PodDisruptionBudget, out *policy.PodDisruptionBudget, s conversion.Scope) error { return autoConvert_v1beta1_PodDisruptionBudget_To_policy_PodDisruptionBudget(in, out, s) } func autoConvert_policy_PodDisruptionBudget_To_v1beta1_PodDisruptionBudget(in *policy.PodDisruptionBudget, out *PodDisruptionBudget, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta if err := Convert_policy_PodDisruptionBudgetSpec_To_v1beta1_PodDisruptionBudgetSpec(&in.Spec, &out.Spec, s); err != nil { return err } @@ -109,6 +99,7 @@ func autoConvert_policy_PodDisruptionBudget_To_v1beta1_PodDisruptionBudget(in *p return nil } +// Convert_policy_PodDisruptionBudget_To_v1beta1_PodDisruptionBudget is an autogenerated conversion function. func Convert_policy_PodDisruptionBudget_To_v1beta1_PodDisruptionBudget(in *policy.PodDisruptionBudget, out *PodDisruptionBudget, s conversion.Scope) error { return autoConvert_policy_PodDisruptionBudget_To_v1beta1_PodDisruptionBudget(in, out, s) } @@ -119,43 +110,53 @@ func autoConvert_v1beta1_PodDisruptionBudgetList_To_policy_PodDisruptionBudgetLi return nil } +// Convert_v1beta1_PodDisruptionBudgetList_To_policy_PodDisruptionBudgetList is an autogenerated conversion function. func Convert_v1beta1_PodDisruptionBudgetList_To_policy_PodDisruptionBudgetList(in *PodDisruptionBudgetList, out *policy.PodDisruptionBudgetList, s conversion.Scope) error { return autoConvert_v1beta1_PodDisruptionBudgetList_To_policy_PodDisruptionBudgetList(in, out, s) } func autoConvert_policy_PodDisruptionBudgetList_To_v1beta1_PodDisruptionBudgetList(in *policy.PodDisruptionBudgetList, out *PodDisruptionBudgetList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]PodDisruptionBudget)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]PodDisruptionBudget, 0) + } else { + out.Items = *(*[]PodDisruptionBudget)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_policy_PodDisruptionBudgetList_To_v1beta1_PodDisruptionBudgetList is an autogenerated conversion function. func Convert_policy_PodDisruptionBudgetList_To_v1beta1_PodDisruptionBudgetList(in *policy.PodDisruptionBudgetList, out *PodDisruptionBudgetList, s conversion.Scope) error { return autoConvert_policy_PodDisruptionBudgetList_To_v1beta1_PodDisruptionBudgetList(in, out, s) } func autoConvert_v1beta1_PodDisruptionBudgetSpec_To_policy_PodDisruptionBudgetSpec(in *PodDisruptionBudgetSpec, out *policy.PodDisruptionBudgetSpec, s conversion.Scope) error { - out.MinAvailable = in.MinAvailable - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) + out.MinAvailable = (*intstr.IntOrString)(unsafe.Pointer(in.MinAvailable)) + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + out.MaxUnavailable = (*intstr.IntOrString)(unsafe.Pointer(in.MaxUnavailable)) return nil } +// Convert_v1beta1_PodDisruptionBudgetSpec_To_policy_PodDisruptionBudgetSpec is an autogenerated conversion function. func Convert_v1beta1_PodDisruptionBudgetSpec_To_policy_PodDisruptionBudgetSpec(in *PodDisruptionBudgetSpec, out *policy.PodDisruptionBudgetSpec, s conversion.Scope) error { return autoConvert_v1beta1_PodDisruptionBudgetSpec_To_policy_PodDisruptionBudgetSpec(in, out, s) } func autoConvert_policy_PodDisruptionBudgetSpec_To_v1beta1_PodDisruptionBudgetSpec(in *policy.PodDisruptionBudgetSpec, out *PodDisruptionBudgetSpec, s conversion.Scope) error { - out.MinAvailable = in.MinAvailable - out.Selector = (*unversioned.LabelSelector)(unsafe.Pointer(in.Selector)) + out.MinAvailable = (*intstr.IntOrString)(unsafe.Pointer(in.MinAvailable)) + out.Selector = (*v1.LabelSelector)(unsafe.Pointer(in.Selector)) + out.MaxUnavailable = (*intstr.IntOrString)(unsafe.Pointer(in.MaxUnavailable)) return nil } +// Convert_policy_PodDisruptionBudgetSpec_To_v1beta1_PodDisruptionBudgetSpec is an autogenerated conversion function. func Convert_policy_PodDisruptionBudgetSpec_To_v1beta1_PodDisruptionBudgetSpec(in *policy.PodDisruptionBudgetSpec, out *PodDisruptionBudgetSpec, s conversion.Scope) error { return autoConvert_policy_PodDisruptionBudgetSpec_To_v1beta1_PodDisruptionBudgetSpec(in, out, s) } func autoConvert_v1beta1_PodDisruptionBudgetStatus_To_policy_PodDisruptionBudgetStatus(in *PodDisruptionBudgetStatus, out *policy.PodDisruptionBudgetStatus, s conversion.Scope) error { out.ObservedGeneration = in.ObservedGeneration - out.DisruptedPods = *(*map[string]unversioned.Time)(unsafe.Pointer(&in.DisruptedPods)) + out.DisruptedPods = *(*map[string]v1.Time)(unsafe.Pointer(&in.DisruptedPods)) out.PodDisruptionsAllowed = in.PodDisruptionsAllowed out.CurrentHealthy = in.CurrentHealthy out.DesiredHealthy = in.DesiredHealthy @@ -163,13 +164,14 @@ func autoConvert_v1beta1_PodDisruptionBudgetStatus_To_policy_PodDisruptionBudget return nil } +// Convert_v1beta1_PodDisruptionBudgetStatus_To_policy_PodDisruptionBudgetStatus is an autogenerated conversion function. func Convert_v1beta1_PodDisruptionBudgetStatus_To_policy_PodDisruptionBudgetStatus(in *PodDisruptionBudgetStatus, out *policy.PodDisruptionBudgetStatus, s conversion.Scope) error { return autoConvert_v1beta1_PodDisruptionBudgetStatus_To_policy_PodDisruptionBudgetStatus(in, out, s) } func autoConvert_policy_PodDisruptionBudgetStatus_To_v1beta1_PodDisruptionBudgetStatus(in *policy.PodDisruptionBudgetStatus, out *PodDisruptionBudgetStatus, s conversion.Scope) error { out.ObservedGeneration = in.ObservedGeneration - out.DisruptedPods = *(*map[string]unversioned.Time)(unsafe.Pointer(&in.DisruptedPods)) + out.DisruptedPods = *(*map[string]v1.Time)(unsafe.Pointer(&in.DisruptedPods)) out.PodDisruptionsAllowed = in.PodDisruptionsAllowed out.CurrentHealthy = in.CurrentHealthy out.DesiredHealthy = in.DesiredHealthy @@ -177,6 +179,7 @@ func autoConvert_policy_PodDisruptionBudgetStatus_To_v1beta1_PodDisruptionBudget return nil } +// Convert_policy_PodDisruptionBudgetStatus_To_v1beta1_PodDisruptionBudgetStatus is an autogenerated conversion function. func Convert_policy_PodDisruptionBudgetStatus_To_v1beta1_PodDisruptionBudgetStatus(in *policy.PodDisruptionBudgetStatus, out *PodDisruptionBudgetStatus, s conversion.Scope) error { return autoConvert_policy_PodDisruptionBudgetStatus_To_v1beta1_PodDisruptionBudgetStatus(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.deepcopy.go index 08f58fde52..cf8ddbd623 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package v1beta1 import ( - unversioned "k8s.io/client-go/pkg/api/unversioned" - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" reflect "reflect" ) @@ -44,34 +44,39 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_Eviction is an autogenerated deepcopy function. func DeepCopy_v1beta1_Eviction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Eviction) out := out.(*Eviction) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.DeleteOptions != nil { in, out := &in.DeleteOptions, &out.DeleteOptions - *out = new(v1.DeleteOptions) - if err := v1.DeepCopy_v1_DeleteOptions(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.DeleteOptions) } - } else { - out.DeleteOptions = nil } return nil } } +// DeepCopy_v1beta1_PodDisruptionBudget is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodDisruptionBudget(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudget) out := out.(*PodDisruptionBudget) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_v1beta1_PodDisruptionBudgetSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -83,12 +88,12 @@ func DeepCopy_v1beta1_PodDisruptionBudget(in interface{}, out interface{}, c *co } } +// DeepCopy_v1beta1_PodDisruptionBudgetList is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodDisruptionBudgetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudgetList) out := out.(*PodDisruptionBudgetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PodDisruptionBudget, len(*in)) @@ -97,49 +102,52 @@ func DeepCopy_v1beta1_PodDisruptionBudgetList(in interface{}, out interface{}, c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1beta1_PodDisruptionBudgetSpec is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodDisruptionBudgetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudgetSpec) out := out.(*PodDisruptionBudgetSpec) - out.MinAvailable = in.MinAvailable + *out = *in + if in.MinAvailable != nil { + in, out := &in.MinAvailable, &out.MinAvailable + *out = new(intstr.IntOrString) + **out = **in + } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil + } + if in.MaxUnavailable != nil { + in, out := &in.MaxUnavailable, &out.MaxUnavailable + *out = new(intstr.IntOrString) + **out = **in } return nil } } +// DeepCopy_v1beta1_PodDisruptionBudgetStatus is an autogenerated deepcopy function. func DeepCopy_v1beta1_PodDisruptionBudgetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudgetStatus) out := out.(*PodDisruptionBudgetStatus) - out.ObservedGeneration = in.ObservedGeneration + *out = *in if in.DisruptedPods != nil { in, out := &in.DisruptedPods, &out.DisruptedPods - *out = make(map[string]unversioned.Time) + *out = make(map[string]v1.Time) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.DisruptedPods = nil } - out.PodDisruptionsAllowed = in.PodDisruptionsAllowed - out.CurrentHealthy = in.CurrentHealthy - out.DesiredHealthy = in.DesiredHealthy - out.ExpectedPods = in.ExpectedPods return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.defaults.go new file mode 100644 index 0000000000..e24e70be38 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/policy/v1beta1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1beta1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/policy/zz_generated.deepcopy.go index 6d9dd0e9c1..ba27f9072e 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/policy/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,10 +21,10 @@ limitations under the License. package policy import ( - api "k8s.io/client-go/pkg/api" - unversioned "k8s.io/client-go/pkg/api/unversioned" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + intstr "k8s.io/apimachinery/pkg/util/intstr" reflect "reflect" ) @@ -44,34 +44,39 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_policy_Eviction is an autogenerated deepcopy function. func DeepCopy_policy_Eviction(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Eviction) out := out.(*Eviction) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.DeleteOptions != nil { in, out := &in.DeleteOptions, &out.DeleteOptions - *out = new(api.DeleteOptions) - if err := api.DeepCopy_api_DeleteOptions(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.DeleteOptions) } - } else { - out.DeleteOptions = nil } return nil } } +// DeepCopy_policy_PodDisruptionBudget is an autogenerated deepcopy function. func DeepCopy_policy_PodDisruptionBudget(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudget) out := out.(*PodDisruptionBudget) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if err := DeepCopy_policy_PodDisruptionBudgetSpec(&in.Spec, &out.Spec, c); err != nil { return err @@ -83,12 +88,12 @@ func DeepCopy_policy_PodDisruptionBudget(in interface{}, out interface{}, c *con } } +// DeepCopy_policy_PodDisruptionBudgetList is an autogenerated deepcopy function. func DeepCopy_policy_PodDisruptionBudgetList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudgetList) out := out.(*PodDisruptionBudgetList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]PodDisruptionBudget, len(*in)) @@ -97,49 +102,52 @@ func DeepCopy_policy_PodDisruptionBudgetList(in interface{}, out interface{}, c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_policy_PodDisruptionBudgetSpec is an autogenerated deepcopy function. func DeepCopy_policy_PodDisruptionBudgetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudgetSpec) out := out.(*PodDisruptionBudgetSpec) - out.MinAvailable = in.MinAvailable + *out = *in + if in.MinAvailable != nil { + in, out := &in.MinAvailable, &out.MinAvailable + *out = new(intstr.IntOrString) + **out = **in + } if in.Selector != nil { in, out := &in.Selector, &out.Selector - *out = new(unversioned.LabelSelector) - if err := unversioned.DeepCopy_unversioned_LabelSelector(*in, *out, c); err != nil { + if newVal, err := c.DeepCopy(*in); err != nil { return err + } else { + *out = newVal.(*v1.LabelSelector) } - } else { - out.Selector = nil + } + if in.MaxUnavailable != nil { + in, out := &in.MaxUnavailable, &out.MaxUnavailable + *out = new(intstr.IntOrString) + **out = **in } return nil } } +// DeepCopy_policy_PodDisruptionBudgetStatus is an autogenerated deepcopy function. func DeepCopy_policy_PodDisruptionBudgetStatus(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PodDisruptionBudgetStatus) out := out.(*PodDisruptionBudgetStatus) - out.ObservedGeneration = in.ObservedGeneration + *out = *in if in.DisruptedPods != nil { in, out := &in.DisruptedPods, &out.DisruptedPods - *out = make(map[string]unversioned.Time) + *out = make(map[string]v1.Time) for key, val := range *in { (*out)[key] = val.DeepCopy() } - } else { - out.DisruptedPods = nil } - out.PodDisruptionsAllowed = in.PodDisruptionsAllowed - out.CurrentHealthy = in.CurrentHealthy - out.DesiredHealthy = in.DesiredHealthy - out.ExpectedPods = in.ExpectedPods return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/BUILD b/vendor/k8s.io/client-go/pkg/apis/rbac/BUILD new file mode 100644 index 0000000000..2825eb324b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/BUILD @@ -0,0 +1,27 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "helpers.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/OWNERS b/vendor/k8s.io/client-go/pkg/apis/rbac/OWNERS new file mode 100755 index 0000000000..a35477b920 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/OWNERS @@ -0,0 +1,17 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- deads2k +- sttts +- ncdc +- timothysc +- dims +- krousey +- mml +- mbohlool +- david-mcmahon +- ericchiang +- lixiaobing10051267 +- jianhuiz +- liggitt diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/doc.go b/vendor/k8s.io/client-go/pkg/apis/rbac/doc.go index aefe6e09b1..c5f057484c 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/doc.go @@ -14,8 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:openapi-gen=true - // +groupName=rbac.authorization.k8s.io package rbac diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/helpers.go b/vendor/k8s.io/client-go/pkg/apis/rbac/helpers.go index f9a770bb02..9895b484b0 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/helpers.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/helpers.go @@ -20,15 +20,16 @@ import ( "fmt" "strings" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/util/sets" ) -func RoleRefGroupKind(roleRef RoleRef) unversioned.GroupKind { - return unversioned.GroupKind{Group: roleRef.APIGroup, Kind: roleRef.Kind} +func RoleRefGroupKind(roleRef RoleRef) schema.GroupKind { + return schema.GroupKind{Group: roleRef.APIGroup, Kind: roleRef.Kind} } -func VerbMatches(rule PolicyRule, requestedVerb string) bool { +func VerbMatches(rule *PolicyRule, requestedVerb string) bool { for _, ruleVerb := range rule.Verbs { if ruleVerb == VerbAll { return true @@ -41,7 +42,7 @@ func VerbMatches(rule PolicyRule, requestedVerb string) bool { return false } -func APIGroupMatches(rule PolicyRule, requestedGroup string) bool { +func APIGroupMatches(rule *PolicyRule, requestedGroup string) bool { for _, ruleGroup := range rule.APIGroups { if ruleGroup == APIGroupAll { return true @@ -54,7 +55,7 @@ func APIGroupMatches(rule PolicyRule, requestedGroup string) bool { return false } -func ResourceMatches(rule PolicyRule, requestedResource string) bool { +func ResourceMatches(rule *PolicyRule, requestedResource string) bool { for _, ruleResource := range rule.Resources { if ruleResource == ResourceAll { return true @@ -67,7 +68,7 @@ func ResourceMatches(rule PolicyRule, requestedResource string) bool { return false } -func ResourceNameMatches(rule PolicyRule, requestedName string) bool { +func ResourceNameMatches(rule *PolicyRule, requestedName string) bool { if len(rule.ResourceNames) == 0 { return true } @@ -81,7 +82,7 @@ func ResourceNameMatches(rule PolicyRule, requestedName string) bool { return false } -func NonResourceURLMatches(rule PolicyRule, requestedURL string) bool { +func NonResourceURLMatches(rule *PolicyRule, requestedURL string) bool { for _, ruleURL := range rule.NonResourceURLs { if ruleURL == NonResourceAll { return true @@ -97,7 +98,64 @@ func NonResourceURLMatches(rule PolicyRule, requestedURL string) bool { return false } -// +k8s:deepcopy-gen=false +// subjectsStrings returns users, groups, serviceaccounts, unknown for display purposes. +func SubjectsStrings(subjects []Subject) ([]string, []string, []string, []string) { + users := []string{} + groups := []string{} + sas := []string{} + others := []string{} + + for _, subject := range subjects { + switch subject.Kind { + case ServiceAccountKind: + sas = append(sas, fmt.Sprintf("%s/%s", subject.Namespace, subject.Name)) + + case UserKind: + users = append(users, subject.Name) + + case GroupKind: + groups = append(groups, subject.Name) + + default: + others = append(others, fmt.Sprintf("%s/%s/%s", subject.Kind, subject.Namespace, subject.Name)) + } + } + + return users, groups, sas, others +} + +func (r PolicyRule) String() string { + return "PolicyRule" + r.CompactString() +} + +// CompactString exposes a compact string representation for use in escalation error messages +func (r PolicyRule) CompactString() string { + formatStringParts := []string{} + formatArgs := []interface{}{} + if len(r.Resources) > 0 { + formatStringParts = append(formatStringParts, "Resources:%q") + formatArgs = append(formatArgs, r.Resources) + } + if len(r.NonResourceURLs) > 0 { + formatStringParts = append(formatStringParts, "NonResourceURLs:%q") + formatArgs = append(formatArgs, r.NonResourceURLs) + } + if len(r.ResourceNames) > 0 { + formatStringParts = append(formatStringParts, "ResourceNames:%q") + formatArgs = append(formatArgs, r.ResourceNames) + } + if len(r.APIGroups) > 0 { + formatStringParts = append(formatStringParts, "APIGroups:%q") + formatArgs = append(formatArgs, r.APIGroups) + } + if len(r.Verbs) > 0 { + formatStringParts = append(formatStringParts, "Verbs:%q") + formatArgs = append(formatArgs, r.Verbs) + } + formatString := "{" + strings.Join(formatStringParts, ", ") + "}" + return fmt.Sprintf(formatString, formatArgs...) +} + // PolicyRuleBuilder let's us attach methods. A no-no for API types. // We use it to construct rules in code. It's more compact than trying to write them // out in a literal and allows us to perform some basic checking during construction @@ -107,27 +165,27 @@ type PolicyRuleBuilder struct { func NewRule(verbs ...string) *PolicyRuleBuilder { return &PolicyRuleBuilder{ - PolicyRule: PolicyRule{Verbs: verbs}, + PolicyRule: PolicyRule{Verbs: sets.NewString(verbs...).List()}, } } func (r *PolicyRuleBuilder) Groups(groups ...string) *PolicyRuleBuilder { - r.PolicyRule.APIGroups = append(r.PolicyRule.APIGroups, groups...) + r.PolicyRule.APIGroups = combine(r.PolicyRule.APIGroups, groups) return r } func (r *PolicyRuleBuilder) Resources(resources ...string) *PolicyRuleBuilder { - r.PolicyRule.Resources = append(r.PolicyRule.Resources, resources...) + r.PolicyRule.Resources = combine(r.PolicyRule.Resources, resources) return r } func (r *PolicyRuleBuilder) Names(names ...string) *PolicyRuleBuilder { - r.PolicyRule.ResourceNames = append(r.PolicyRule.ResourceNames, names...) + r.PolicyRule.ResourceNames = combine(r.PolicyRule.ResourceNames, names) return r } func (r *PolicyRuleBuilder) URLs(urls ...string) *PolicyRuleBuilder { - r.PolicyRule.NonResourceURLs = append(r.PolicyRule.NonResourceURLs, urls...) + r.PolicyRule.NonResourceURLs = combine(r.PolicyRule.NonResourceURLs, urls) return r } @@ -139,6 +197,12 @@ func (r *PolicyRuleBuilder) RuleOrDie() PolicyRule { return ret } +func combine(s1, s2 []string) []string { + s := sets.NewString(s1...) + s.Insert(s2...) + return s.List() +} + func (r *PolicyRuleBuilder) Rule() (PolicyRule, error) { if len(r.PolicyRule.Verbs) == 0 { return PolicyRule{}, fmt.Errorf("verbs are required: %#v", r.PolicyRule) @@ -157,6 +221,22 @@ func (r *PolicyRuleBuilder) Rule() (PolicyRule, error) { // this a common bug return PolicyRule{}, fmt.Errorf("resource rule must have apiGroups: %#v", r.PolicyRule) } + // if resource names are set, then the verb must not be list, watch, create, or deletecollection + // since verbs are largely opaque, we don't want to accidentally prevent things like "impersonate", so + // we will backlist common mistakes, not whitelist acceptable options. + if len(r.PolicyRule.ResourceNames) != 0 { + illegalVerbs := []string{} + for _, verb := range r.PolicyRule.Verbs { + switch verb { + case "list", "watch", "create", "deletecollection": + illegalVerbs = append(illegalVerbs, verb) + } + } + if len(illegalVerbs) > 0 { + return PolicyRule{}, fmt.Errorf("verbs %v do not have names available: %#v", illegalVerbs, r.PolicyRule) + } + } + default: return PolicyRule{}, fmt.Errorf("a rule must have either nonResourceURLs or resources: %#v", r.PolicyRule) } @@ -164,7 +244,6 @@ func (r *PolicyRuleBuilder) Rule() (PolicyRule, error) { return r.PolicyRule, nil } -// +k8s:deepcopy-gen=false // ClusterRoleBindingBuilder let's us attach methods. A no-no for API types. // We use it to construct bindings in code. It's more compact than trying to write them // out in a literal. @@ -175,7 +254,7 @@ type ClusterRoleBindingBuilder struct { func NewClusterBinding(clusterRoleName string) *ClusterRoleBindingBuilder { return &ClusterRoleBindingBuilder{ ClusterRoleBinding: ClusterRoleBinding{ - ObjectMeta: api.ObjectMeta{Name: clusterRoleName}, + ObjectMeta: metav1.ObjectMeta{Name: clusterRoleName}, RoleRef: RoleRef{ APIGroup: GroupName, Kind: "ClusterRole", @@ -187,14 +266,14 @@ func NewClusterBinding(clusterRoleName string) *ClusterRoleBindingBuilder { func (r *ClusterRoleBindingBuilder) Groups(groups ...string) *ClusterRoleBindingBuilder { for _, group := range groups { - r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: GroupKind, Name: group}) + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: GroupKind, APIGroup: GroupName, Name: group}) } return r } func (r *ClusterRoleBindingBuilder) Users(users ...string) *ClusterRoleBindingBuilder { for _, user := range users { - r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: UserKind, Name: user}) + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: UserKind, APIGroup: GroupName, Name: user}) } return r } @@ -221,3 +300,97 @@ func (r *ClusterRoleBindingBuilder) Binding() (ClusterRoleBinding, error) { return r.ClusterRoleBinding, nil } + +// RoleBindingBuilder let's us attach methods. It is similar to +// ClusterRoleBindingBuilder above. +type RoleBindingBuilder struct { + RoleBinding RoleBinding +} + +// NewRoleBinding creates a RoleBinding builder that can be used +// to define the subjects of a role binding. At least one of +// the `Groups`, `Users` or `SAs` method must be called before +// calling the `Binding*` methods. +func NewRoleBinding(roleName, namespace string) *RoleBindingBuilder { + return &RoleBindingBuilder{ + RoleBinding: RoleBinding{ + ObjectMeta: metav1.ObjectMeta{ + Name: roleName, + Namespace: namespace, + }, + RoleRef: RoleRef{ + APIGroup: GroupName, + Kind: "Role", + Name: roleName, + }, + }, + } +} + +func NewRoleBindingForClusterRole(roleName, namespace string) *RoleBindingBuilder { + return &RoleBindingBuilder{ + RoleBinding: RoleBinding{ + ObjectMeta: metav1.ObjectMeta{ + Name: roleName, + Namespace: namespace, + }, + RoleRef: RoleRef{ + APIGroup: GroupName, + Kind: "ClusterRole", + Name: roleName, + }, + }, + } +} + +// Groups adds the specified groups as the subjects of the RoleBinding. +func (r *RoleBindingBuilder) Groups(groups ...string) *RoleBindingBuilder { + for _, group := range groups { + r.RoleBinding.Subjects = append(r.RoleBinding.Subjects, Subject{Kind: GroupKind, Name: group}) + } + return r +} + +// Users adds the specified users as the subjects of the RoleBinding. +func (r *RoleBindingBuilder) Users(users ...string) *RoleBindingBuilder { + for _, user := range users { + r.RoleBinding.Subjects = append(r.RoleBinding.Subjects, Subject{Kind: UserKind, Name: user}) + } + return r +} + +// SAs adds the specified service accounts as the subjects of the +// RoleBinding. +func (r *RoleBindingBuilder) SAs(namespace string, serviceAccountNames ...string) *RoleBindingBuilder { + for _, saName := range serviceAccountNames { + r.RoleBinding.Subjects = append(r.RoleBinding.Subjects, Subject{Kind: ServiceAccountKind, Namespace: namespace, Name: saName}) + } + return r +} + +// BindingOrDie calls the binding method and panics if there is an error. +func (r *RoleBindingBuilder) BindingOrDie() RoleBinding { + ret, err := r.Binding() + if err != nil { + panic(err) + } + return ret +} + +// Binding builds and returns the RoleBinding API object from the builder +// object. +func (r *RoleBindingBuilder) Binding() (RoleBinding, error) { + if len(r.RoleBinding.Subjects) == 0 { + return RoleBinding{}, fmt.Errorf("subjects are required: %#v", r.RoleBinding) + } + + return r.RoleBinding, nil +} + +type SortableRuleSlice []PolicyRule + +func (s SortableRuleSlice) Len() int { return len(s) } +func (s SortableRuleSlice) Swap(i, j int) { s[i], s[j] = s[j], s[i] } +func (s SortableRuleSlice) Less(i, j int) bool { + return strings.Compare(s[i].String(), s[j].String()) < 0 +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/install/install.go b/vendor/k8s.io/client-go/pkg/apis/rbac/install/install.go deleted file mode 100644 index 37e5b91a55..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the batch API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/rbac" - "k8s.io/client-go/pkg/apis/rbac/v1alpha1" - "k8s.io/client-go/pkg/util/sets" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: rbac.GroupName, - VersionPreferenceOrder: []string{v1alpha1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/rbac", - RootScopedKinds: sets.NewString("ClusterRole", "ClusterRoleBinding"), - AddInternalObjectsToScheme: rbac.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1alpha1.SchemeGroupVersion.Version: v1alpha1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/register.go b/vendor/k8s.io/client-go/pkg/apis/rbac/register.go index d50d55745c..f4a838bd89 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/register.go @@ -17,24 +17,22 @@ limitations under the License. package rbac import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/watch/versioned" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) const GroupName = "rbac.authorization.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -55,11 +53,6 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ClusterRoleBinding{}, &ClusterRoleBindingList{}, &ClusterRoleList{}, - - &api.ListOptions{}, - &api.DeleteOptions{}, - &api.ExportOptions{}, ) - versioned.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/types.go b/vendor/k8s.io/client-go/pkg/apis/rbac/types.go index 0d8ec843fd..ddc2456a02 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/types.go @@ -17,9 +17,7 @@ limitations under the License. package rbac import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // Authorization is calculated against @@ -37,7 +35,8 @@ const ( ServiceAccountKind = "ServiceAccount" UserKind = "User" - UserAll = "*" + // AutoUpdateAnnotationKey is the name of an annotation which prevents reconciliation if set to "false" + AutoUpdateAnnotationKey = "rbac.authorization.kubernetes.io/autoupdate" ) // PolicyRule holds information that describes a policy rule, but does not contain information @@ -45,12 +44,9 @@ const ( type PolicyRule struct { // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. Verbs []string - // AttributeRestrictions will vary depending on what the Authorizer/AuthorizationAttributeBuilder pair supports. - // If the Authorizer does not recognize how to handle the AttributeRestrictions, the Authorizer should report an error. - AttributeRestrictions runtime.Object + // APIGroups is the name of the APIGroup that contains the resources. // If multiple API groups are specified, any action requested against one of the enumerated resources in any API group will be allowed. - APIGroups []string // Resources is a list of resources this rule applies to. ResourceAll represents all resources. Resources []string @@ -70,9 +66,10 @@ type Subject struct { // Kind of object being referenced. Values defined by this API group are "User", "Group", and "ServiceAccount". // If the Authorizer does not recognized the kind value, the Authorizer should report an error. Kind string - // APIVersion holds the API group and version of the referenced object. For non-object references such as "Group" and "User" this is - // expected to be API version of this API group. For example, "rbac/v1alpha1". - APIVersion string + // APIGroup holds the API group of the referenced subject. + // Defaults to "" for ServiceAccount subjects. + // Defaults to "rbac.authorization.k8s.io" for User and Group subjects. + APIGroup string // Name of the object being referenced. Name string // Namespace of the referenced object. If the object kind is non-namespace, such as "User" or "Group", and this value is not empty @@ -94,9 +91,9 @@ type RoleRef struct { // Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. type Role struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - api.ObjectMeta + metav1.ObjectMeta // Rules holds all the PolicyRules for this Role Rules []PolicyRule @@ -108,8 +105,8 @@ type Role struct { // It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given // namespace only have effect in that namespace. type RoleBinding struct { - unversioned.TypeMeta - api.ObjectMeta + metav1.TypeMeta + metav1.ObjectMeta // Subjects holds references to the objects the role applies to. Subjects []Subject @@ -121,9 +118,9 @@ type RoleBinding struct { // RoleBindingList is a collection of RoleBindings type RoleBindingList struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - unversioned.ListMeta + metav1.ListMeta // Items is a list of roleBindings Items []RoleBinding @@ -131,9 +128,9 @@ type RoleBindingList struct { // RoleList is a collection of Roles type RoleList struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - unversioned.ListMeta + metav1.ListMeta // Items is a list of roles Items []Role @@ -144,9 +141,9 @@ type RoleList struct { // ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. type ClusterRole struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - api.ObjectMeta + metav1.ObjectMeta // Rules holds all the PolicyRules for this ClusterRole Rules []PolicyRule @@ -158,9 +155,9 @@ type ClusterRole struct { // ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, // and adds who information via Subject. type ClusterRoleBinding struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - api.ObjectMeta + metav1.ObjectMeta // Subjects holds references to the objects the role applies to. Subjects []Subject @@ -172,9 +169,9 @@ type ClusterRoleBinding struct { // ClusterRoleBindingList is a collection of ClusterRoleBindings type ClusterRoleBindingList struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - unversioned.ListMeta + metav1.ListMeta // Items is a list of ClusterRoleBindings Items []ClusterRoleBinding @@ -182,9 +179,9 @@ type ClusterRoleBindingList struct { // ClusterRoleList is a collection of ClusterRoles type ClusterRoleList struct { - unversioned.TypeMeta + metav1.TypeMeta // Standard object's metadata. - unversioned.ListMeta + metav1.ListMeta // Items is a list of ClusterRoles Items []ClusterRole diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/BUILD b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/BUILD new file mode 100644 index 0000000000..13f1a850ca --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/BUILD @@ -0,0 +1,37 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "defaults.go", + "doc.go", + "generated.pb.go", + "helpers.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/rbac:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/conversion.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/conversion.go new file mode 100644 index 0000000000..22b3c40767 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/conversion.go @@ -0,0 +1,81 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime/schema" + api "k8s.io/client-go/pkg/apis/rbac" +) + +// allAuthenticated matches k8s.io/apiserver/pkg/authentication/user.AllAuthenticated, +// but we don't want an client library (which must include types), depending on a server library +const allAuthenticated = "system:authenticated" + +func Convert_v1alpha1_Subject_To_rbac_Subject(in *Subject, out *api.Subject, s conversion.Scope) error { + if err := autoConvert_v1alpha1_Subject_To_rbac_Subject(in, out, s); err != nil { + return err + } + + // specifically set the APIGroup for the three subjects recognized in v1alpha1 + switch { + case in.Kind == ServiceAccountKind: + out.APIGroup = "" + case in.Kind == UserKind: + out.APIGroup = GroupName + case in.Kind == GroupKind: + out.APIGroup = GroupName + default: + // For unrecognized kinds, use the group portion of the APIVersion if we can get it + if gv, err := schema.ParseGroupVersion(in.APIVersion); err == nil { + out.APIGroup = gv.Group + } + } + + // User * in v1alpha1 will only match all authenticated users + // This is only for compatibility with old RBAC bindings + // Special treatment for * should not be included in v1beta1 + if out.Kind == UserKind && out.APIGroup == GroupName && out.Name == "*" { + out.Kind = GroupKind + out.Name = allAuthenticated + } + + return nil +} + +func Convert_rbac_Subject_To_v1alpha1_Subject(in *api.Subject, out *Subject, s conversion.Scope) error { + if err := autoConvert_rbac_Subject_To_v1alpha1_Subject(in, out, s); err != nil { + return err + } + + switch { + case in.Kind == ServiceAccountKind && in.APIGroup == "": + // Make service accounts v1 + out.APIVersion = "v1" + case in.Kind == UserKind && in.APIGroup == GroupName: + // users in the rbac API group get v1alpha + out.APIVersion = SchemeGroupVersion.String() + case in.Kind == GroupKind && in.APIGroup == GroupName: + // groups in the rbac API group get v1alpha + out.APIVersion = SchemeGroupVersion.String() + default: + // otherwise, they get an unspecified version of a group + out.APIVersion = schema.GroupVersion{Group: in.APIGroup}.String() + } + + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/defaults.go index 51f51e5ae0..daa86a0e16 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/defaults.go @@ -17,15 +17,11 @@ limitations under the License. package v1alpha1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) func addDefaultingFuncs(scheme *runtime.Scheme) error { - RegisterDefaults(scheme) - return scheme.AddDefaultingFuncs( - SetDefaults_ClusterRoleBinding, - SetDefaults_RoleBinding, - ) + return RegisterDefaults(scheme) } func SetDefaults_ClusterRoleBinding(obj *ClusterRoleBinding) { @@ -38,3 +34,15 @@ func SetDefaults_RoleBinding(obj *RoleBinding) { obj.RoleRef.APIGroup = GroupName } } +func SetDefaults_Subject(obj *Subject) { + if len(obj.APIVersion) == 0 { + switch obj.Kind { + case ServiceAccountKind: + obj.APIVersion = "v1" + case UserKind: + obj.APIVersion = SchemeGroupVersion.String() + case GroupKind: + obj.APIVersion = SchemeGroupVersion.String() + } + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/doc.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/doc.go index 0540241e8f..f43f7bc084 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/doc.go @@ -14,10 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/rbac -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta - // +groupName=rbac.authorization.k8s.io package v1alpha1 diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go index 829e1d29a6..3977142e46 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -27,9 +27,11 @@ limitations under the License. It has these top-level messages: ClusterRole ClusterRoleBinding + ClusterRoleBindingBuilder ClusterRoleBindingList ClusterRoleList PolicyRule + PolicyRuleBuilder Role RoleBinding RoleBindingList @@ -55,7 +57,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *ClusterRole) Reset() { *m = ClusterRole{} } func (*ClusterRole) ProtoMessage() {} @@ -65,48 +69,60 @@ func (m *ClusterRoleBinding) Reset() { *m = ClusterRoleBindin func (*ClusterRoleBinding) ProtoMessage() {} func (*ClusterRoleBinding) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } +func (m *ClusterRoleBindingBuilder) Reset() { *m = ClusterRoleBindingBuilder{} } +func (*ClusterRoleBindingBuilder) ProtoMessage() {} +func (*ClusterRoleBindingBuilder) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + func (m *ClusterRoleBindingList) Reset() { *m = ClusterRoleBindingList{} } func (*ClusterRoleBindingList) ProtoMessage() {} -func (*ClusterRoleBindingList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } +func (*ClusterRoleBindingList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } func (m *ClusterRoleList) Reset() { *m = ClusterRoleList{} } func (*ClusterRoleList) ProtoMessage() {} -func (*ClusterRoleList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } +func (*ClusterRoleList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } func (m *PolicyRule) Reset() { *m = PolicyRule{} } func (*PolicyRule) ProtoMessage() {} -func (*PolicyRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } +func (*PolicyRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func (m *PolicyRuleBuilder) Reset() { *m = PolicyRuleBuilder{} } +func (*PolicyRuleBuilder) ProtoMessage() {} +func (*PolicyRuleBuilder) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } func (m *Role) Reset() { *m = Role{} } func (*Role) ProtoMessage() {} -func (*Role) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } +func (*Role) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } func (m *RoleBinding) Reset() { *m = RoleBinding{} } func (*RoleBinding) ProtoMessage() {} -func (*RoleBinding) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } +func (*RoleBinding) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } func (m *RoleBindingList) Reset() { *m = RoleBindingList{} } func (*RoleBindingList) ProtoMessage() {} -func (*RoleBindingList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } +func (*RoleBindingList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } func (m *RoleList) Reset() { *m = RoleList{} } func (*RoleList) ProtoMessage() {} -func (*RoleList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } +func (*RoleList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } func (m *RoleRef) Reset() { *m = RoleRef{} } func (*RoleRef) ProtoMessage() {} -func (*RoleRef) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } +func (*RoleRef) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } func (m *Subject) Reset() { *m = Subject{} } func (*Subject) ProtoMessage() {} -func (*Subject) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } +func (*Subject) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } func init() { proto.RegisterType((*ClusterRole)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.ClusterRole") proto.RegisterType((*ClusterRoleBinding)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.ClusterRoleBinding") + proto.RegisterType((*ClusterRoleBindingBuilder)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.ClusterRoleBindingBuilder") proto.RegisterType((*ClusterRoleBindingList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.ClusterRoleBindingList") proto.RegisterType((*ClusterRoleList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.ClusterRoleList") proto.RegisterType((*PolicyRule)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.PolicyRule") + proto.RegisterType((*PolicyRuleBuilder)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.PolicyRuleBuilder") proto.RegisterType((*Role)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.Role") proto.RegisterType((*RoleBinding)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.RoleBinding") proto.RegisterType((*RoleBindingList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.RoleBindingList") @@ -114,35 +130,35 @@ func init() { proto.RegisterType((*RoleRef)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.RoleRef") proto.RegisterType((*Subject)(nil), "k8s.io.client-go.pkg.apis.rbac.v1alpha1.Subject") } -func (m *ClusterRole) Marshal() (data []byte, err error) { +func (m *ClusterRole) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ClusterRole) MarshalTo(data []byte) (int, error) { +func (m *ClusterRole) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 if len(m.Rules) > 0 { for _, msg := range m.Rules { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -152,45 +168,45 @@ func (m *ClusterRole) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ClusterRoleBinding) Marshal() (data []byte, err error) { +func (m *ClusterRoleBinding) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ClusterRoleBinding) MarshalTo(data []byte) (int, error) { +func (m *ClusterRoleBinding) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n2, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n2, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 if len(m.Subjects) > 0 { for _, msg := range m.Subjects { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.RoleRef.Size())) - n3, err := m.RoleRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RoleRef.Size())) + n3, err := m.RoleRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -198,35 +214,61 @@ func (m *ClusterRoleBinding) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ClusterRoleBindingList) Marshal() (data []byte, err error) { +func (m *ClusterRoleBindingBuilder) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ClusterRoleBindingList) MarshalTo(data []byte) (int, error) { +func (m *ClusterRoleBindingBuilder) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n4, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ClusterRoleBinding.Size())) + n4, err := m.ClusterRoleBinding.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n4 + return i, nil +} + +func (m *ClusterRoleBindingList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ClusterRoleBindingList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n5, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -236,35 +278,35 @@ func (m *ClusterRoleBindingList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *ClusterRoleList) Marshal() (data []byte, err error) { +func (m *ClusterRoleList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *ClusterRoleList) MarshalTo(data []byte) (int, error) { +func (m *ClusterRoleList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n5, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n5 + i += n6 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -274,136 +316,154 @@ func (m *ClusterRoleList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *PolicyRule) Marshal() (data []byte, err error) { +func (m *PolicyRule) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *PolicyRule) MarshalTo(data []byte) (int, error) { +func (m *PolicyRule) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l if len(m.Verbs) > 0 { for _, s := range m.Verbs { - data[i] = 0xa + dAtA[i] = 0xa i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.AttributeRestrictions.Size())) - n6, err := m.AttributeRestrictions.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n6 if len(m.APIGroups) > 0 { for _, s := range m.APIGroups { - data[i] = 0x1a + dAtA[i] = 0x1a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.Resources) > 0 { for _, s := range m.Resources { - data[i] = 0x22 + dAtA[i] = 0x22 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.ResourceNames) > 0 { for _, s := range m.ResourceNames { - data[i] = 0x2a + dAtA[i] = 0x2a i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } if len(m.NonResourceURLs) > 0 { for _, s := range m.NonResourceURLs { - data[i] = 0x32 + dAtA[i] = 0x32 i++ l = len(s) for l >= 1<<7 { - data[i] = uint8(uint64(l)&0x7f | 0x80) + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) l >>= 7 i++ } - data[i] = uint8(l) + dAtA[i] = uint8(l) i++ - i += copy(data[i:], s) + i += copy(dAtA[i:], s) } } return i, nil } -func (m *Role) Marshal() (data []byte, err error) { +func (m *PolicyRuleBuilder) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Role) MarshalTo(data []byte) (int, error) { +func (m *PolicyRuleBuilder) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n7, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.PolicyRule.Size())) + n7, err := m.PolicyRule.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n7 + return i, nil +} + +func (m *Role) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Role) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n8, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 if len(m.Rules) > 0 { for _, msg := range m.Rules { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -413,81 +473,81 @@ func (m *Role) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *RoleBinding) Marshal() (data []byte, err error) { +func (m *RoleBinding) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RoleBinding) MarshalTo(data []byte) (int, error) { +func (m *RoleBinding) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n8, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n8 + i += n9 if len(m.Subjects) > 0 { for _, msg := range m.Subjects { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n } } - data[i] = 0x1a + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(m.RoleRef.Size())) - n9, err := m.RoleRef.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.RoleRef.Size())) + n10, err := m.RoleRef.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n9 + i += n10 return i, nil } -func (m *RoleBindingList) Marshal() (data []byte, err error) { +func (m *RoleBindingList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RoleBindingList) MarshalTo(data []byte) (int, error) { +func (m *RoleBindingList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n10, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n11, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n10 + i += n11 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -497,35 +557,35 @@ func (m *RoleBindingList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *RoleList) Marshal() (data []byte, err error) { +func (m *RoleList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RoleList) MarshalTo(data []byte) (int, error) { +func (m *RoleList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n11, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n12, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } - i += n11 + i += n12 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -535,95 +595,95 @@ func (m *RoleList) MarshalTo(data []byte) (int, error) { return i, nil } -func (m *RoleRef) Marshal() (data []byte, err error) { +func (m *RoleRef) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *RoleRef) MarshalTo(data []byte) (int, error) { +func (m *RoleRef) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIGroup))) - i += copy(data[i:], m.APIGroup) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIGroup))) + i += copy(dAtA[i:], m.APIGroup) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) return i, nil } -func (m *Subject) Marshal() (data []byte, err error) { +func (m *Subject) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *Subject) MarshalTo(data []byte) (int, error) { +func (m *Subject) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Kind))) - i += copy(data[i:], m.Kind) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.APIVersion))) - i += copy(data[i:], m.APIVersion) - data[i] = 0x1a + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIVersion))) + i += copy(dAtA[i:], m.APIVersion) + dAtA[i] = 0x1a i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Name))) - i += copy(data[i:], m.Name) - data[i] = 0x22 + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x22 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Namespace))) - i += copy(data[i:], m.Namespace) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *ClusterRole) Size() (n int) { @@ -656,6 +716,14 @@ func (m *ClusterRoleBinding) Size() (n int) { return n } +func (m *ClusterRoleBindingBuilder) Size() (n int) { + var l int + _ = l + l = m.ClusterRoleBinding.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + func (m *ClusterRoleBindingList) Size() (n int) { var l int _ = l @@ -693,8 +761,6 @@ func (m *PolicyRule) Size() (n int) { n += 1 + l + sovGenerated(uint64(l)) } } - l = m.AttributeRestrictions.Size() - n += 1 + l + sovGenerated(uint64(l)) if len(m.APIGroups) > 0 { for _, s := range m.APIGroups { l = len(s) @@ -722,6 +788,14 @@ func (m *PolicyRule) Size() (n int) { return n } +func (m *PolicyRuleBuilder) Size() (n int) { + var l int + _ = l + l = m.PolicyRule.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + func (m *Role) Size() (n int) { var l int _ = l @@ -824,7 +898,7 @@ func (this *ClusterRole) String() string { return "nil" } s := strings.Join([]string{`&ClusterRole{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "PolicyRule", "PolicyRule", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -835,19 +909,29 @@ func (this *ClusterRoleBinding) String() string { return "nil" } s := strings.Join([]string{`&ClusterRoleBinding{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Subjects:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Subjects), "Subject", "Subject", 1), `&`, ``, 1) + `,`, `RoleRef:` + strings.Replace(strings.Replace(this.RoleRef.String(), "RoleRef", "RoleRef", 1), `&`, ``, 1) + `,`, `}`, }, "") return s } +func (this *ClusterRoleBindingBuilder) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ClusterRoleBindingBuilder{`, + `ClusterRoleBinding:` + strings.Replace(strings.Replace(this.ClusterRoleBinding.String(), "ClusterRoleBinding", "ClusterRoleBinding", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} func (this *ClusterRoleBindingList) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&ClusterRoleBindingList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ClusterRoleBinding", "ClusterRoleBinding", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -858,7 +942,7 @@ func (this *ClusterRoleList) String() string { return "nil" } s := strings.Join([]string{`&ClusterRoleList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ClusterRole", "ClusterRole", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -870,7 +954,6 @@ func (this *PolicyRule) String() string { } s := strings.Join([]string{`&PolicyRule{`, `Verbs:` + fmt.Sprintf("%v", this.Verbs) + `,`, - `AttributeRestrictions:` + strings.Replace(strings.Replace(this.AttributeRestrictions.String(), "RawExtension", "k8s_io_kubernetes_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, `APIGroups:` + fmt.Sprintf("%v", this.APIGroups) + `,`, `Resources:` + fmt.Sprintf("%v", this.Resources) + `,`, `ResourceNames:` + fmt.Sprintf("%v", this.ResourceNames) + `,`, @@ -879,12 +962,22 @@ func (this *PolicyRule) String() string { }, "") return s } +func (this *PolicyRuleBuilder) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PolicyRuleBuilder{`, + `PolicyRule:` + strings.Replace(strings.Replace(this.PolicyRule.String(), "PolicyRule", "PolicyRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} func (this *Role) String() string { if this == nil { return "nil" } s := strings.Join([]string{`&Role{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "PolicyRule", "PolicyRule", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -895,7 +988,7 @@ func (this *RoleBinding) String() string { return "nil" } s := strings.Join([]string{`&RoleBinding{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Subjects:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Subjects), "Subject", "Subject", 1), `&`, ``, 1) + `,`, `RoleRef:` + strings.Replace(strings.Replace(this.RoleRef.String(), "RoleRef", "RoleRef", 1), `&`, ``, 1) + `,`, `}`, @@ -907,7 +1000,7 @@ func (this *RoleBindingList) String() string { return "nil" } s := strings.Join([]string{`&RoleBindingList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "RoleBinding", "RoleBinding", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -918,7 +1011,7 @@ func (this *RoleList) String() string { return "nil" } s := strings.Join([]string{`&RoleList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Role", "Role", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -957,8 +1050,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *ClusterRole) Unmarshal(data []byte) error { - l := len(data) +func (m *ClusterRole) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -970,7 +1063,7 @@ func (m *ClusterRole) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -998,7 +1091,7 @@ func (m *ClusterRole) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1012,7 +1105,7 @@ func (m *ClusterRole) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1028,7 +1121,7 @@ func (m *ClusterRole) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1043,13 +1136,13 @@ func (m *ClusterRole) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Rules = append(m.Rules, PolicyRule{}) - if err := m.Rules[len(m.Rules)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1068,8 +1161,8 @@ func (m *ClusterRole) Unmarshal(data []byte) error { } return nil } -func (m *ClusterRoleBinding) Unmarshal(data []byte) error { - l := len(data) +func (m *ClusterRoleBinding) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1081,7 +1174,7 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1109,7 +1202,7 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1123,7 +1216,7 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1139,7 +1232,7 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1154,7 +1247,7 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Subjects = append(m.Subjects, Subject{}) - if err := m.Subjects[len(m.Subjects)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Subjects[len(m.Subjects)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1170,7 +1263,87 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.RoleRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ClusterRoleBindingBuilder) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ClusterRoleBindingBuilder: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ClusterRoleBindingBuilder: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClusterRoleBinding", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1184,13 +1357,13 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.RoleRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ClusterRoleBinding.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1209,8 +1382,8 @@ func (m *ClusterRoleBinding) Unmarshal(data []byte) error { } return nil } -func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { - l := len(data) +func (m *ClusterRoleBindingList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1222,7 +1395,7 @@ func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1250,7 +1423,7 @@ func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1264,7 +1437,7 @@ func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1280,7 +1453,7 @@ func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1295,13 +1468,13 @@ func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ClusterRoleBinding{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1320,8 +1493,8 @@ func (m *ClusterRoleBindingList) Unmarshal(data []byte) error { } return nil } -func (m *ClusterRoleList) Unmarshal(data []byte) error { - l := len(data) +func (m *ClusterRoleList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1333,7 +1506,7 @@ func (m *ClusterRoleList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1361,7 +1534,7 @@ func (m *ClusterRoleList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1375,7 +1548,7 @@ func (m *ClusterRoleList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1391,7 +1564,7 @@ func (m *ClusterRoleList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1406,13 +1579,13 @@ func (m *ClusterRoleList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, ClusterRole{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1431,8 +1604,8 @@ func (m *ClusterRoleList) Unmarshal(data []byte) error { } return nil } -func (m *PolicyRule) Unmarshal(data []byte) error { - l := len(data) +func (m *PolicyRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1444,7 +1617,7 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1472,7 +1645,7 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1487,13 +1660,13 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Verbs = append(m.Verbs, string(data[iNdEx:postIndex])) + m.Verbs = append(m.Verbs, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 2: + case 3: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field AttributeRestrictions", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) } - var msglen int + var stringLen uint64 for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1501,27 +1674,26 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - msglen |= (int(b) & 0x7F) << shift + stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { break } } - if msglen < 0 { + intStringLen := int(stringLen) + if intStringLen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + msglen + postIndex := iNdEx + intStringLen if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.AttributeRestrictions.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } + m.APIGroups = append(m.APIGroups, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 3: + case 4: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -1531,7 +1703,7 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1546,11 +1718,11 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.APIGroups = append(m.APIGroups, string(data[iNdEx:postIndex])) + m.Resources = append(m.Resources, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 4: + case 5: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field ResourceNames", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -1560,7 +1732,7 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1575,11 +1747,11 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Resources = append(m.Resources, string(data[iNdEx:postIndex])) + m.ResourceNames = append(m.ResourceNames, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 5: + case 6: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field ResourceNames", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field NonResourceURLs", wireType) } var stringLen uint64 for shift := uint(0); ; shift += 7 { @@ -1589,7 +1761,7 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1604,13 +1776,63 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.ResourceNames = append(m.ResourceNames, string(data[iNdEx:postIndex])) + m.NonResourceURLs = append(m.NonResourceURLs, string(dAtA[iNdEx:postIndex])) iNdEx = postIndex - case 6: + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PolicyRuleBuilder) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PolicyRuleBuilder: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PolicyRuleBuilder: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field NonResourceURLs", wireType) + return fmt.Errorf("proto: wrong wireType = %d for field PolicyRule", wireType) } - var stringLen uint64 + var msglen int for shift := uint(0); ; shift += 7 { if shift >= 64 { return ErrIntOverflowGenerated @@ -1618,26 +1840,27 @@ func (m *PolicyRule) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift + msglen |= (int(b) & 0x7F) << shift if b < 0x80 { break } } - intStringLen := int(stringLen) - if intStringLen < 0 { + if msglen < 0 { return ErrInvalidLengthGenerated } - postIndex := iNdEx + intStringLen + postIndex := iNdEx + msglen if postIndex > l { return io.ErrUnexpectedEOF } - m.NonResourceURLs = append(m.NonResourceURLs, string(data[iNdEx:postIndex])) + if err := m.PolicyRule.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1656,8 +1879,8 @@ func (m *PolicyRule) Unmarshal(data []byte) error { } return nil } -func (m *Role) Unmarshal(data []byte) error { - l := len(data) +func (m *Role) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1669,7 +1892,7 @@ func (m *Role) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1697,7 +1920,7 @@ func (m *Role) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1711,7 +1934,7 @@ func (m *Role) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1727,7 +1950,7 @@ func (m *Role) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1742,13 +1965,13 @@ func (m *Role) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Rules = append(m.Rules, PolicyRule{}) - if err := m.Rules[len(m.Rules)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1767,8 +1990,8 @@ func (m *Role) Unmarshal(data []byte) error { } return nil } -func (m *RoleBinding) Unmarshal(data []byte) error { - l := len(data) +func (m *RoleBinding) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1780,7 +2003,7 @@ func (m *RoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1808,7 +2031,7 @@ func (m *RoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1822,7 +2045,7 @@ func (m *RoleBinding) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1838,7 +2061,7 @@ func (m *RoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1853,7 +2076,7 @@ func (m *RoleBinding) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Subjects = append(m.Subjects, Subject{}) - if err := m.Subjects[len(m.Subjects)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Subjects[len(m.Subjects)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1869,7 +2092,7 @@ func (m *RoleBinding) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1883,13 +2106,13 @@ func (m *RoleBinding) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.RoleRef.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.RoleRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -1908,8 +2131,8 @@ func (m *RoleBinding) Unmarshal(data []byte) error { } return nil } -func (m *RoleBindingList) Unmarshal(data []byte) error { - l := len(data) +func (m *RoleBindingList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -1921,7 +2144,7 @@ func (m *RoleBindingList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -1949,7 +2172,7 @@ func (m *RoleBindingList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1963,7 +2186,7 @@ func (m *RoleBindingList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -1979,7 +2202,7 @@ func (m *RoleBindingList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -1994,13 +2217,13 @@ func (m *RoleBindingList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, RoleBinding{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2019,8 +2242,8 @@ func (m *RoleBindingList) Unmarshal(data []byte) error { } return nil } -func (m *RoleList) Unmarshal(data []byte) error { - l := len(data) +func (m *RoleList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2032,7 +2255,7 @@ func (m *RoleList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2060,7 +2283,7 @@ func (m *RoleList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2074,7 +2297,7 @@ func (m *RoleList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -2090,7 +2313,7 @@ func (m *RoleList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2105,13 +2328,13 @@ func (m *RoleList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, Role{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2130,8 +2353,8 @@ func (m *RoleList) Unmarshal(data []byte) error { } return nil } -func (m *RoleRef) Unmarshal(data []byte) error { - l := len(data) +func (m *RoleRef) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2143,7 +2366,7 @@ func (m *RoleRef) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2171,7 +2394,7 @@ func (m *RoleRef) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2186,7 +2409,7 @@ func (m *RoleRef) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.APIGroup = string(data[iNdEx:postIndex]) + m.APIGroup = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -2200,7 +2423,7 @@ func (m *RoleRef) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2215,7 +2438,7 @@ func (m *RoleRef) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = string(data[iNdEx:postIndex]) + m.Kind = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -2229,7 +2452,7 @@ func (m *RoleRef) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2244,11 +2467,11 @@ func (m *RoleRef) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2267,8 +2490,8 @@ func (m *RoleRef) Unmarshal(data []byte) error { } return nil } -func (m *Subject) Unmarshal(data []byte) error { - l := len(data) +func (m *Subject) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -2280,7 +2503,7 @@ func (m *Subject) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2308,7 +2531,7 @@ func (m *Subject) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2323,7 +2546,7 @@ func (m *Subject) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Kind = string(data[iNdEx:postIndex]) + m.Kind = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 2: if wireType != 2 { @@ -2337,7 +2560,7 @@ func (m *Subject) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2352,7 +2575,7 @@ func (m *Subject) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.APIVersion = string(data[iNdEx:postIndex]) + m.APIVersion = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -2366,7 +2589,7 @@ func (m *Subject) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2381,7 +2604,7 @@ func (m *Subject) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Name = string(data[iNdEx:postIndex]) + m.Name = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 4: if wireType != 2 { @@ -2395,7 +2618,7 @@ func (m *Subject) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2410,11 +2633,11 @@ func (m *Subject) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Namespace = string(data[iNdEx:postIndex]) + m.Namespace = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -2433,8 +2656,8 @@ func (m *Subject) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -2445,7 +2668,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2463,7 +2686,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -2480,7 +2703,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -2503,7 +2726,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -2514,7 +2737,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -2538,57 +2761,62 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 815 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xec, 0x54, 0x41, 0x6b, 0xe3, 0x46, - 0x18, 0xb5, 0x62, 0xbb, 0xb1, 0xc6, 0x35, 0x6e, 0x54, 0x52, 0x84, 0xa1, 0xb2, 0xf1, 0xc9, 0x34, - 0xc9, 0x08, 0x9b, 0x86, 0xe6, 0xd0, 0x1e, 0xa2, 0x52, 0x4a, 0x68, 0x9a, 0x86, 0x09, 0x0d, 0x6d, - 0x68, 0x29, 0x63, 0x7b, 0xe2, 0x4c, 0x2d, 0x4b, 0x62, 0x66, 0xe4, 0xb6, 0xf4, 0x12, 0xf6, 0x17, - 0xec, 0xaf, 0xd8, 0xdb, 0x5e, 0xf6, 0xba, 0xb0, 0x87, 0x3d, 0xe5, 0xb0, 0x87, 0x1c, 0x97, 0x3d, - 0x98, 0x8d, 0xf6, 0x8f, 0x2c, 0x1a, 0x49, 0x96, 0x1d, 0xdb, 0x1b, 0x27, 0xb0, 0x81, 0x85, 0x3d, - 0x25, 0xf3, 0x7d, 0xef, 0xbd, 0xf9, 0xde, 0xe7, 0xd1, 0x03, 0x3b, 0xfd, 0x1d, 0x0e, 0xa9, 0x6b, - 0xf6, 0xfd, 0x36, 0x61, 0x0e, 0x11, 0x84, 0x9b, 0x5e, 0xbf, 0x67, 0x62, 0x8f, 0x72, 0x93, 0xb5, - 0x71, 0xc7, 0x1c, 0x36, 0xb1, 0xed, 0x9d, 0xe1, 0xa6, 0xd9, 0x23, 0x0e, 0x61, 0x58, 0x90, 0x2e, - 0xf4, 0x98, 0x2b, 0x5c, 0xad, 0x11, 0x31, 0x61, 0xca, 0x84, 0x5e, 0xbf, 0x07, 0x43, 0x26, 0x0c, - 0x99, 0x30, 0x61, 0x56, 0xb6, 0x7a, 0x54, 0x9c, 0xf9, 0x6d, 0xd8, 0x71, 0x07, 0x66, 0xcf, 0xed, - 0xb9, 0xa6, 0x14, 0x68, 0xfb, 0xa7, 0xf2, 0x24, 0x0f, 0xf2, 0xbf, 0x48, 0xb8, 0xd2, 0x5a, 0x38, - 0x92, 0xc9, 0x08, 0x77, 0x7d, 0xd6, 0x21, 0xd7, 0x87, 0xa9, 0x6c, 0x2f, 0xe6, 0xf8, 0xce, 0x90, - 0x30, 0x4e, 0x5d, 0x87, 0x74, 0x67, 0x68, 0x9b, 0x8b, 0x69, 0xc3, 0x19, 0xc7, 0x95, 0xad, 0xf9, - 0x68, 0xe6, 0x3b, 0x82, 0x0e, 0x66, 0x67, 0x6a, 0xce, 0x87, 0xfb, 0x82, 0xda, 0x26, 0x75, 0x04, - 0x17, 0xec, 0x3a, 0xa5, 0xfe, 0x5c, 0x01, 0xc5, 0xef, 0x6d, 0x9f, 0x0b, 0xc2, 0x90, 0x6b, 0x13, - 0xed, 0x37, 0x50, 0x18, 0x10, 0x81, 0xbb, 0x58, 0x60, 0x5d, 0xa9, 0x29, 0x8d, 0x62, 0xab, 0x01, - 0x17, 0xae, 0x1d, 0x0e, 0x9b, 0xf0, 0x97, 0xf6, 0xdf, 0xa4, 0x23, 0x7e, 0x26, 0x02, 0x5b, 0xda, - 0xc5, 0xa8, 0x9a, 0x09, 0x46, 0x55, 0x90, 0xd6, 0xd0, 0x58, 0x4d, 0xfb, 0x1d, 0xe4, 0x99, 0x6f, - 0x13, 0xae, 0xaf, 0xd4, 0xb2, 0x8d, 0x62, 0xeb, 0x6b, 0xb8, 0xec, 0xaf, 0x09, 0x0f, 0x5d, 0x9b, - 0x76, 0xfe, 0x43, 0xbe, 0x4d, 0xac, 0x52, 0x7c, 0x45, 0x3e, 0x3c, 0x71, 0x14, 0x29, 0xd6, 0x1f, - 0xaf, 0x00, 0x6d, 0xc2, 0x84, 0x45, 0x9d, 0x2e, 0x75, 0x7a, 0xef, 0xd1, 0xcb, 0x5f, 0xa0, 0xc0, - 0x7d, 0xd9, 0x48, 0xec, 0x34, 0x97, 0xb7, 0x73, 0x14, 0x31, 0xad, 0xcf, 0xe2, 0x2b, 0x0a, 0x71, - 0x81, 0xa3, 0xb1, 0xa8, 0xf6, 0x07, 0x58, 0x65, 0xae, 0x4d, 0x10, 0x39, 0xd5, 0xb3, 0x72, 0xf2, - 0x5b, 0xe8, 0xa3, 0x88, 0x68, 0x95, 0x63, 0xfd, 0xd5, 0xb8, 0x80, 0x12, 0xc9, 0xfa, 0x2b, 0x05, - 0x7c, 0x31, 0xbb, 0xaf, 0x7d, 0xca, 0x85, 0xf6, 0xe7, 0xcc, 0xce, 0xcc, 0x77, 0xec, 0x6c, 0xe2, - 0xa5, 0xc3, 0x90, 0x2e, 0x57, 0x37, 0xf6, 0x95, 0x54, 0x26, 0x16, 0x87, 0x41, 0x9e, 0x0a, 0x32, - 0x48, 0xb6, 0xf6, 0xed, 0xf2, 0xae, 0x66, 0xe7, 0x4d, 0x1f, 0xc3, 0x5e, 0x28, 0x89, 0x22, 0xe5, - 0xfa, 0x0b, 0x05, 0x94, 0x27, 0xc0, 0xf7, 0xe1, 0xea, 0x64, 0xda, 0xd5, 0xf6, 0xdd, 0x5c, 0xcd, - 0xb7, 0xf3, 0x20, 0x0b, 0x40, 0xfa, 0x01, 0x68, 0x55, 0x90, 0x1f, 0x12, 0xd6, 0xe6, 0xba, 0x52, - 0xcb, 0x36, 0x54, 0x4b, 0x0d, 0xf1, 0xc7, 0x61, 0x01, 0x45, 0x75, 0xed, 0x5c, 0x01, 0xeb, 0x58, - 0x08, 0x46, 0xdb, 0xbe, 0x20, 0x88, 0x70, 0xc1, 0x68, 0x47, 0x50, 0xd7, 0x09, 0x87, 0x0b, 0x8d, - 0x6f, 0x2c, 0x18, 0x2e, 0xce, 0x14, 0x88, 0xf0, 0x3f, 0x3f, 0xfc, 0x2b, 0x88, 0x13, 0xfa, 0xb7, - 0xbe, 0x8c, 0x47, 0x5a, 0xdf, 0x9d, 0xa7, 0x88, 0xe6, 0x5f, 0xa4, 0x6d, 0x00, 0x15, 0x7b, 0xf4, - 0x47, 0xe6, 0xfa, 0x1e, 0xd7, 0xb3, 0x72, 0xce, 0x52, 0x30, 0xaa, 0xaa, 0xbb, 0x87, 0x7b, 0x51, - 0x11, 0xa5, 0xfd, 0x10, 0x9c, 0x64, 0x2c, 0xd7, 0x73, 0x29, 0x18, 0x25, 0x45, 0x94, 0xf6, 0xb5, - 0x6f, 0x40, 0x29, 0x39, 0x1c, 0xe0, 0x01, 0xe1, 0x7a, 0x5e, 0x12, 0xd6, 0x82, 0x51, 0xb5, 0x84, - 0x26, 0x1b, 0x68, 0x1a, 0xa7, 0x7d, 0x07, 0xca, 0x8e, 0xeb, 0x24, 0x90, 0x5f, 0xd1, 0x3e, 0xd7, - 0x3f, 0x91, 0xd4, 0xcf, 0x83, 0x51, 0xb5, 0x7c, 0x30, 0xdd, 0x42, 0xd7, 0xb1, 0xf5, 0xa7, 0x0a, - 0xc8, 0x7d, 0xb8, 0xf1, 0xf8, 0x68, 0x05, 0x14, 0x3f, 0xe6, 0xe2, 0x12, 0xb9, 0x18, 0x46, 0xc7, - 0x3d, 0x07, 0xe2, 0xdd, 0xa3, 0xe3, 0xe6, 0x24, 0x7c, 0xa6, 0x80, 0xc2, 0x7d, 0x45, 0xe0, 0xd1, - 0xb4, 0x0f, 0x78, 0x4b, 0x1f, 0xf3, 0x0d, 0xfc, 0x0f, 0x92, 0xdf, 0x48, 0xdb, 0x04, 0x85, 0x24, - 0x33, 0xe4, 0xf8, 0x6a, 0x3a, 0x4d, 0x12, 0x2b, 0x68, 0x8c, 0xd0, 0x6a, 0x20, 0xd7, 0xa7, 0x4e, - 0x57, 0x46, 0x9e, 0x6a, 0x7d, 0x1a, 0x23, 0x73, 0x3f, 0x51, 0xa7, 0x8b, 0x64, 0x27, 0x44, 0x38, - 0x78, 0x40, 0xe4, 0x2b, 0x9a, 0x40, 0x84, 0x69, 0x81, 0x64, 0xa7, 0xfe, 0x44, 0x01, 0xab, 0xf1, - 0x0b, 0x1c, 0xeb, 0x29, 0x0b, 0xf5, 0x5a, 0x00, 0x60, 0x8f, 0x1e, 0x47, 0x4b, 0x8b, 0xef, 0x1d, - 0x7f, 0x2b, 0xbb, 0x87, 0x7b, 0x71, 0x07, 0x4d, 0xa0, 0x6e, 0x9e, 0x41, 0x33, 0x81, 0x1a, 0xfe, - 0xe5, 0x1e, 0xee, 0x10, 0x3d, 0x27, 0x61, 0x6b, 0x31, 0x4c, 0x3d, 0x48, 0x1a, 0x28, 0xc5, 0x58, - 0x5f, 0x5d, 0x5c, 0x19, 0x99, 0xcb, 0x2b, 0x23, 0xf3, 0xf2, 0xca, 0xc8, 0x9c, 0x07, 0x86, 0x72, - 0x11, 0x18, 0xca, 0x65, 0x60, 0x28, 0xaf, 0x03, 0x43, 0x79, 0xf8, 0xc6, 0xc8, 0x9c, 0x14, 0x92, - 0xc5, 0xbf, 0x0d, 0x00, 0x00, 0xff, 0xff, 0x62, 0x32, 0x8a, 0x1f, 0x89, 0x0b, 0x00, 0x00, + // 829 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0xcf, 0x6b, 0x24, 0x45, + 0x14, 0x9e, 0x4a, 0x66, 0xcc, 0xcc, 0x8b, 0x21, 0xa6, 0x04, 0x69, 0x73, 0xe8, 0x09, 0x7d, 0x0a, + 0xa8, 0xd5, 0x26, 0xae, 0xba, 0x07, 0x3d, 0x6c, 0x7b, 0x90, 0xe0, 0x1a, 0x43, 0x2d, 0x2e, 0xb8, + 0x2c, 0x68, 0x4d, 0x4f, 0xed, 0x4c, 0x39, 0xfd, 0x8b, 0xaa, 0xee, 0xc0, 0x22, 0x82, 0x47, 0x8f, + 0xfe, 0x15, 0x1e, 0x3d, 0x08, 0x1e, 0x3d, 0x79, 0x09, 0x7a, 0xd9, 0xe3, 0x7a, 0x19, 0x4c, 0xfb, + 0x87, 0x28, 0x5d, 0x5d, 0xfd, 0x23, 0x99, 0x09, 0xf9, 0x21, 0x04, 0x84, 0x3d, 0xcd, 0xf4, 0x7b, + 0xdf, 0xf7, 0xd5, 0xfb, 0xea, 0x75, 0x7f, 0x70, 0x77, 0x76, 0x57, 0x11, 0x11, 0xbb, 0xb3, 0x6c, + 0xc4, 0x65, 0xc4, 0x53, 0xae, 0xdc, 0x64, 0x36, 0x71, 0x59, 0x22, 0x94, 0x2b, 0x47, 0xcc, 0x77, + 0x8f, 0xf7, 0x58, 0x90, 0x4c, 0xd9, 0x9e, 0x3b, 0xe1, 0x11, 0x97, 0x2c, 0xe5, 0x63, 0x92, 0xc8, + 0x38, 0x8d, 0xf1, 0x6e, 0xc9, 0x24, 0x0d, 0x93, 0x24, 0xb3, 0x09, 0x29, 0x98, 0xa4, 0x60, 0x92, + 0x8a, 0xb9, 0xfd, 0xd6, 0x44, 0xa4, 0xd3, 0x6c, 0x44, 0xfc, 0x38, 0x74, 0x27, 0xf1, 0x24, 0x76, + 0xb5, 0xc0, 0x28, 0x7b, 0xa2, 0x9f, 0xf4, 0x83, 0xfe, 0x57, 0x0a, 0x6f, 0xdf, 0x31, 0x23, 0xb1, + 0x44, 0x84, 0xcc, 0x9f, 0x8a, 0x88, 0xcb, 0xa7, 0xcd, 0x50, 0x21, 0x4f, 0x99, 0x7b, 0xbc, 0x30, + 0xce, 0xb6, 0x7b, 0x11, 0x4b, 0x66, 0x51, 0x2a, 0x42, 0xbe, 0x40, 0x78, 0xef, 0x32, 0x82, 0xf2, + 0xa7, 0x3c, 0x64, 0x0b, 0xbc, 0x77, 0x2e, 0xe2, 0x65, 0xa9, 0x08, 0x5c, 0x11, 0xa5, 0x2a, 0x95, + 0xe7, 0x49, 0xce, 0xef, 0x08, 0xd6, 0x3f, 0x0a, 0x32, 0x95, 0x72, 0x49, 0xe3, 0x80, 0xe3, 0xaf, + 0xa0, 0x5f, 0x18, 0x19, 0xb3, 0x94, 0x59, 0x68, 0x07, 0xed, 0xae, 0xef, 0xbf, 0x4d, 0xcc, 0x7d, + 0xb6, 0x75, 0x9b, 0x1b, 0x2d, 0xd0, 0xe4, 0x78, 0x8f, 0x7c, 0x36, 0xfa, 0x9a, 0xfb, 0xe9, 0xa7, + 0x3c, 0x65, 0x1e, 0x3e, 0x99, 0x0f, 0x3b, 0xf9, 0x7c, 0x08, 0x4d, 0x8d, 0xd6, 0xaa, 0xf8, 0x0b, + 0xe8, 0xc9, 0x2c, 0xe0, 0xca, 0x5a, 0xd9, 0x59, 0xdd, 0x5d, 0xdf, 0xbf, 0x43, 0xae, 0xba, 0x2e, + 0x72, 0x14, 0x07, 0xc2, 0x7f, 0x4a, 0xb3, 0x80, 0x7b, 0x1b, 0xe6, 0x88, 0x5e, 0xf1, 0xa4, 0x68, + 0xa9, 0xe8, 0xfc, 0xb2, 0x02, 0xb8, 0x65, 0xc6, 0x13, 0xd1, 0x58, 0x44, 0x93, 0x5b, 0xf0, 0xf4, + 0x25, 0xf4, 0x55, 0xa6, 0x1b, 0x95, 0xad, 0xbd, 0xab, 0xdb, 0x7a, 0x50, 0x32, 0xbd, 0x57, 0xcc, + 0x11, 0x7d, 0x53, 0x50, 0xb4, 0x16, 0xc5, 0x8f, 0x61, 0x4d, 0xc6, 0x01, 0xa7, 0xfc, 0x89, 0xb5, + 0xaa, 0x1d, 0x5c, 0x43, 0x9f, 0x96, 0x44, 0x6f, 0xd3, 0xe8, 0xaf, 0x99, 0x02, 0xad, 0x24, 0x9d, + 0x1f, 0x11, 0xbc, 0xbe, 0x78, 0x6f, 0x5e, 0x26, 0x82, 0x31, 0x97, 0xf8, 0x7b, 0x04, 0xd8, 0x5f, + 0xe8, 0x9a, 0x9b, 0xfc, 0xe0, 0xea, 0x73, 0x2c, 0x39, 0x61, 0xdb, 0x8c, 0xb4, 0x64, 0x6b, 0x74, + 0xc9, 0x99, 0xce, 0x9f, 0x08, 0x5e, 0x5b, 0x84, 0xde, 0x17, 0x2a, 0xc5, 0x8f, 0x17, 0x96, 0x4c, + 0xae, 0xb6, 0xe4, 0x82, 0xad, 0x57, 0x5c, 0xdf, 0x7f, 0x55, 0x69, 0x2d, 0x98, 0x41, 0x4f, 0xa4, + 0x3c, 0xac, 0xb6, 0xfb, 0xdf, 0x5c, 0xd7, 0x2f, 0xef, 0x41, 0x21, 0x49, 0x4b, 0x65, 0xe7, 0x0f, + 0x04, 0x9b, 0x2d, 0xf0, 0x2d, 0x98, 0x7a, 0x74, 0xd6, 0xd4, 0xbb, 0x37, 0x33, 0xb5, 0xdc, 0xcd, + 0x3f, 0x08, 0xa0, 0xf9, 0x5e, 0xf1, 0x10, 0x7a, 0xc7, 0x5c, 0x8e, 0x94, 0x85, 0x76, 0x56, 0x77, + 0x07, 0xde, 0xa0, 0xc0, 0x3f, 0x2c, 0x0a, 0xb4, 0xac, 0xe3, 0x37, 0x60, 0xc0, 0x12, 0xf1, 0xb1, + 0x8c, 0xb3, 0x44, 0x59, 0xab, 0x1a, 0xb4, 0x91, 0xcf, 0x87, 0x83, 0x7b, 0x47, 0x07, 0x65, 0x91, + 0x36, 0xfd, 0x02, 0x2c, 0xb9, 0x8a, 0x33, 0xe9, 0x73, 0x65, 0x75, 0x1b, 0x30, 0xad, 0x8a, 0xb4, + 0xe9, 0xe3, 0xf7, 0x61, 0xa3, 0x7a, 0x38, 0x64, 0x21, 0x57, 0x56, 0x4f, 0x13, 0xb6, 0xf2, 0xf9, + 0x70, 0x83, 0xb6, 0x1b, 0xf4, 0x2c, 0x0e, 0x7f, 0x08, 0x9b, 0x51, 0x1c, 0x55, 0x90, 0xcf, 0xe9, + 0x7d, 0x65, 0xbd, 0xa4, 0xa9, 0xaf, 0xe6, 0xf3, 0xe1, 0xe6, 0xe1, 0xd9, 0x16, 0x3d, 0x8f, 0x75, + 0xbe, 0x85, 0xad, 0x56, 0x60, 0x99, 0x6f, 0x69, 0x0a, 0x90, 0xd4, 0x45, 0xb3, 0xd2, 0x9b, 0x25, + 0x60, 0x1d, 0x48, 0x4d, 0x8d, 0xb6, 0xb4, 0x9d, 0xdf, 0x10, 0x74, 0xff, 0xff, 0x89, 0xfe, 0xd3, + 0x0a, 0xac, 0xbf, 0x88, 0xf2, 0x6b, 0x44, 0x79, 0x91, 0x22, 0xb7, 0x1b, 0x8d, 0x37, 0x4f, 0x91, + 0xcb, 0x33, 0xf1, 0x57, 0x04, 0xfd, 0x5b, 0x0a, 0xc3, 0x07, 0x67, 0x6d, 0x90, 0x6b, 0xda, 0x58, + 0x3e, 0xff, 0x37, 0x50, 0x6d, 0x08, 0xbf, 0x09, 0xfd, 0x2a, 0xc0, 0xf4, 0xf4, 0x83, 0x66, 0x9a, + 0x2a, 0xe3, 0x68, 0x8d, 0xc0, 0x3b, 0xd0, 0x9d, 0x89, 0x68, 0x6c, 0xad, 0x68, 0xe4, 0xcb, 0x06, + 0xd9, 0xfd, 0x44, 0x44, 0x63, 0xaa, 0x3b, 0x05, 0x22, 0x62, 0x21, 0xd7, 0xef, 0x50, 0x0b, 0x51, + 0x44, 0x17, 0xd5, 0x1d, 0xe7, 0x67, 0x04, 0x6b, 0xe6, 0xfd, 0xab, 0xf5, 0xd0, 0x85, 0x7a, 0xfb, + 0x00, 0x2c, 0x11, 0x0f, 0xb9, 0x54, 0x22, 0x8e, 0xcc, 0xb9, 0xf5, 0x97, 0x72, 0xef, 0xe8, 0xc0, + 0x74, 0x68, 0x0b, 0x75, 0xf9, 0x0c, 0xd8, 0x85, 0x41, 0xf1, 0xab, 0x12, 0xe6, 0x73, 0xab, 0xab, + 0x61, 0x5b, 0x06, 0x36, 0x38, 0xac, 0x1a, 0xb4, 0xc1, 0x78, 0xe4, 0xe4, 0xd4, 0xee, 0x3c, 0x3b, + 0xb5, 0x3b, 0xcf, 0x4f, 0xed, 0xce, 0x77, 0xb9, 0x8d, 0x4e, 0x72, 0x1b, 0x3d, 0xcb, 0x6d, 0xf4, + 0x3c, 0xb7, 0xd1, 0x5f, 0xb9, 0x8d, 0x7e, 0xf8, 0xdb, 0xee, 0x3c, 0xea, 0x57, 0x97, 0xff, 0x6f, + 0x00, 0x00, 0x00, 0xff, 0xff, 0x20, 0x76, 0x05, 0x2e, 0x27, 0x0c, 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto index 09f11e33b0..ba462c669f 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.rbac.v1alpha1; +package k8s.io.client_go.pkg.apis.rbac.v1alpha1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; -import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1alpha1"; @@ -34,7 +33,7 @@ option go_package = "v1alpha1"; message ClusterRole { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Rules holds all the PolicyRules for this ClusterRole repeated PolicyRule rules = 2; @@ -45,7 +44,7 @@ message ClusterRole { message ClusterRoleBinding { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Subjects holds references to the objects the role applies to. repeated Subject subjects = 2; @@ -55,11 +54,19 @@ message ClusterRoleBinding { optional RoleRef roleRef = 3; } +// +k8s:deepcopy-gen=false +// ClusterRoleBindingBuilder let's us attach methods. A no-no for API types. +// We use it to construct bindings in code. It's more compact than trying to write them +// out in a literal. +message ClusterRoleBindingBuilder { + optional ClusterRoleBinding clusterRoleBinding = 1; +} + // ClusterRoleBindingList is a collection of ClusterRoleBindings message ClusterRoleBindingList { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of ClusterRoleBindings repeated ClusterRoleBinding items = 2; @@ -69,7 +76,7 @@ message ClusterRoleBindingList { message ClusterRoleList { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of ClusterRoles repeated ClusterRole items = 2; @@ -81,11 +88,6 @@ message PolicyRule { // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. repeated string verbs = 1; - // AttributeRestrictions will vary depending on what the Authorizer/AuthorizationAttributeBuilder pair supports. - // If the Authorizer does not recognize how to handle the AttributeRestrictions, the Authorizer should report an error. - // +optional - optional k8s.io.kubernetes.pkg.runtime.RawExtension attributeRestrictions = 2; - // APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of // the enumerated resources in any API group will be allowed. // +optional @@ -107,11 +109,19 @@ message PolicyRule { repeated string nonResourceURLs = 6; } +// +k8s:deepcopy-gen=false +// PolicyRuleBuilder let's us attach methods. A no-no for API types. +// We use it to construct rules in code. It's more compact than trying to write them +// out in a literal and allows us to perform some basic checking during construction +message PolicyRuleBuilder { + optional PolicyRule policyRule = 1; +} + // Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. message Role { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Rules holds all the PolicyRules for this Role repeated PolicyRule rules = 2; @@ -123,7 +133,7 @@ message Role { message RoleBinding { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Subjects holds references to the objects the role applies to. repeated Subject subjects = 2; @@ -137,7 +147,7 @@ message RoleBinding { message RoleBindingList { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of RoleBindings repeated RoleBinding items = 2; @@ -147,7 +157,7 @@ message RoleBindingList { message RoleList { // Standard object's metadata. // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is a list of Roles repeated Role items = 2; @@ -172,7 +182,10 @@ message Subject { // If the Authorizer does not recognized the kind value, the Authorizer should report an error. optional string kind = 1; - // APIVersion holds the API group and version of the referenced object. + // APIVersion holds the API group and version of the referenced subject. + // Defaults to "v1" for ServiceAccount subjects. + // Defaults to "rbac.authorization.k8s.io/v1alpha1" for User and Group subjects. + // +k8s:conversion-gen=false // +optional optional string apiVersion = 2; diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/helpers.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/helpers.go new file mode 100644 index 0000000000..f417f3be05 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/helpers.go @@ -0,0 +1,146 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + "fmt" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// PolicyRuleBuilder let's us attach methods. A no-no for API types. +// We use it to construct rules in code. It's more compact than trying to write them +// out in a literal and allows us to perform some basic checking during construction +type PolicyRuleBuilder struct { + PolicyRule PolicyRule `protobuf:"bytes,1,opt,name=policyRule"` +} + +func NewRule(verbs ...string) *PolicyRuleBuilder { + return &PolicyRuleBuilder{ + PolicyRule: PolicyRule{Verbs: verbs}, + } +} + +func (r *PolicyRuleBuilder) Groups(groups ...string) *PolicyRuleBuilder { + r.PolicyRule.APIGroups = append(r.PolicyRule.APIGroups, groups...) + return r +} + +func (r *PolicyRuleBuilder) Resources(resources ...string) *PolicyRuleBuilder { + r.PolicyRule.Resources = append(r.PolicyRule.Resources, resources...) + return r +} + +func (r *PolicyRuleBuilder) Names(names ...string) *PolicyRuleBuilder { + r.PolicyRule.ResourceNames = append(r.PolicyRule.ResourceNames, names...) + return r +} + +func (r *PolicyRuleBuilder) URLs(urls ...string) *PolicyRuleBuilder { + r.PolicyRule.NonResourceURLs = append(r.PolicyRule.NonResourceURLs, urls...) + return r +} + +func (r *PolicyRuleBuilder) RuleOrDie() PolicyRule { + ret, err := r.Rule() + if err != nil { + panic(err) + } + return ret +} + +func (r *PolicyRuleBuilder) Rule() (PolicyRule, error) { + if len(r.PolicyRule.Verbs) == 0 { + return PolicyRule{}, fmt.Errorf("verbs are required: %#v", r.PolicyRule) + } + + switch { + case len(r.PolicyRule.NonResourceURLs) > 0: + if len(r.PolicyRule.APIGroups) != 0 || len(r.PolicyRule.Resources) != 0 || len(r.PolicyRule.ResourceNames) != 0 { + return PolicyRule{}, fmt.Errorf("non-resource rule may not have apiGroups, resources, or resourceNames: %#v", r.PolicyRule) + } + case len(r.PolicyRule.Resources) > 0: + if len(r.PolicyRule.NonResourceURLs) != 0 { + return PolicyRule{}, fmt.Errorf("resource rule may not have nonResourceURLs: %#v", r.PolicyRule) + } + if len(r.PolicyRule.APIGroups) == 0 { + // this a common bug + return PolicyRule{}, fmt.Errorf("resource rule must have apiGroups: %#v", r.PolicyRule) + } + default: + return PolicyRule{}, fmt.Errorf("a rule must have either nonResourceURLs or resources: %#v", r.PolicyRule) + } + + return r.PolicyRule, nil +} + +// ClusterRoleBindingBuilder let's us attach methods. A no-no for API types. +// We use it to construct bindings in code. It's more compact than trying to write them +// out in a literal. +type ClusterRoleBindingBuilder struct { + ClusterRoleBinding ClusterRoleBinding `protobuf:"bytes,1,opt,name=clusterRoleBinding"` +} + +func NewClusterBinding(clusterRoleName string) *ClusterRoleBindingBuilder { + return &ClusterRoleBindingBuilder{ + ClusterRoleBinding: ClusterRoleBinding{ + ObjectMeta: metav1.ObjectMeta{Name: clusterRoleName}, + RoleRef: RoleRef{ + APIGroup: GroupName, + Kind: "ClusterRole", + Name: clusterRoleName, + }, + }, + } +} + +func (r *ClusterRoleBindingBuilder) Groups(groups ...string) *ClusterRoleBindingBuilder { + for _, group := range groups { + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: GroupKind, Name: group}) + } + return r +} + +func (r *ClusterRoleBindingBuilder) Users(users ...string) *ClusterRoleBindingBuilder { + for _, user := range users { + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: UserKind, Name: user}) + } + return r +} + +func (r *ClusterRoleBindingBuilder) SAs(namespace string, serviceAccountNames ...string) *ClusterRoleBindingBuilder { + for _, saName := range serviceAccountNames { + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: ServiceAccountKind, Namespace: namespace, Name: saName}) + } + return r +} + +func (r *ClusterRoleBindingBuilder) BindingOrDie() ClusterRoleBinding { + ret, err := r.Binding() + if err != nil { + panic(err) + } + return ret +} + +func (r *ClusterRoleBindingBuilder) Binding() (ClusterRoleBinding, error) { + if len(r.ClusterRoleBinding.Subjects) == 0 { + return ClusterRoleBinding{}, fmt.Errorf("subjects are required: %#v", r.ClusterRoleBinding) + } + + return r.ClusterRoleBinding, nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/register.go index 069071139d..956c800da9 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/register.go @@ -17,22 +17,36 @@ limitations under the License. package v1alpha1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) const GroupName = "rbac.authorization.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1alpha1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addDefaultingFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, @@ -45,11 +59,7 @@ func addKnownTypes(scheme *runtime.Scheme) error { &ClusterRoleBinding{}, &ClusterRoleBindingList{}, &ClusterRoleList{}, - - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, ) - versioned.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.generated.go index 3e0824d3f3..03ae6182a7 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.generated.go @@ -25,10 +25,8 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg2_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_v1 "k8s.io/client-go/pkg/api/v1" - pkg1_runtime "k8s.io/client-go/pkg/runtime" - pkg4_types "k8s.io/client-go/pkg/types" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" "reflect" "runtime" time "time" @@ -64,12 +62,10 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg2_unversioned.TypeMeta - var v1 pkg3_v1.ObjectMeta - var v2 pkg1_runtime.RawExtension - var v3 pkg4_types.UID - var v4 time.Time - _, _, _, _, _ = v0, v1, v2, v3, v4 + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 } } @@ -87,17 +83,16 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { } else { yysep2 := !z.EncBinary() yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [6]bool + var yyq2 [5]bool _, _, _ = yysep2, yyq2, yy2arr2 const yyr2 bool = false - yyq2[1] = true - yyq2[2] = len(x.APIGroups) != 0 - yyq2[3] = len(x.Resources) != 0 - yyq2[4] = len(x.ResourceNames) != 0 - yyq2[5] = len(x.NonResourceURLs) != 0 + yyq2[1] = len(x.APIGroups) != 0 + yyq2[2] = len(x.Resources) != 0 + yyq2[3] = len(x.ResourceNames) != 0 + yyq2[4] = len(x.NonResourceURLs) != 0 var yynn2 int if yyr2 || yy2arr2 { - r.EncodeArrayStart(6) + r.EncodeArrayStart(5) } else { yynn2 = 1 for _, b := range yyq2 { @@ -138,44 +133,11 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[1] { - yy7 := &x.AttributeRestrictions - yym8 := z.EncBinary() - _ = yym8 - if false { - } else if z.HasExtensions() && z.EncExt(yy7) { - } else if !yym8 && z.IsJSONHandle() { - z.EncJSONMarshal(yy7) - } else { - z.EncFallback(yy7) - } - } else { - r.EncodeNil() - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("attributeRestrictions")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy9 := &x.AttributeRestrictions - yym10 := z.EncBinary() - _ = yym10 - if false { - } else if z.HasExtensions() && z.EncExt(yy9) { - } else if !yym10 && z.IsJSONHandle() { - z.EncJSONMarshal(yy9) - } else { - z.EncFallback(yy9) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { if x.APIGroups == nil { r.EncodeNil() } else { - yym12 := z.EncBinary() - _ = yym12 + yym7 := z.EncBinary() + _ = yym7 if false { } else { z.F.EncSliceStringV(x.APIGroups, false, e) @@ -185,15 +147,15 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2[2] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.APIGroups == nil { r.EncodeNil() } else { - yym13 := z.EncBinary() - _ = yym13 + yym8 := z.EncBinary() + _ = yym8 if false { } else { z.F.EncSliceStringV(x.APIGroups, false, e) @@ -203,12 +165,12 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[3] { + if yyq2[2] { if x.Resources == nil { r.EncodeNil() } else { - yym15 := z.EncBinary() - _ = yym15 + yym10 := z.EncBinary() + _ = yym10 if false { } else { z.F.EncSliceStringV(x.Resources, false, e) @@ -218,15 +180,15 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2[3] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resources")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.Resources == nil { r.EncodeNil() } else { - yym16 := z.EncBinary() - _ = yym16 + yym11 := z.EncBinary() + _ = yym11 if false { } else { z.F.EncSliceStringV(x.Resources, false, e) @@ -236,12 +198,12 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { + if yyq2[3] { if x.ResourceNames == nil { r.EncodeNil() } else { - yym18 := z.EncBinary() - _ = yym18 + yym13 := z.EncBinary() + _ = yym13 if false { } else { z.F.EncSliceStringV(x.ResourceNames, false, e) @@ -251,15 +213,15 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2[4] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("resourceNames")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.ResourceNames == nil { r.EncodeNil() } else { - yym19 := z.EncBinary() - _ = yym19 + yym14 := z.EncBinary() + _ = yym14 if false { } else { z.F.EncSliceStringV(x.ResourceNames, false, e) @@ -269,12 +231,12 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[5] { + if yyq2[4] { if x.NonResourceURLs == nil { r.EncodeNil() } else { - yym21 := z.EncBinary() - _ = yym21 + yym16 := z.EncBinary() + _ = yym16 if false { } else { z.F.EncSliceStringV(x.NonResourceURLs, false, e) @@ -284,15 +246,15 @@ func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeNil() } } else { - if yyq2[5] { + if yyq2[4] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("nonResourceURLs")) z.EncSendContainerState(codecSelfer_containerMapValue1234) if x.NonResourceURLs == nil { r.EncodeNil() } else { - yym22 := z.EncBinary() - _ = yym22 + yym17 := z.EncBinary() + _ = yym17 if false { } else { z.F.EncSliceStringV(x.NonResourceURLs, false, e) @@ -313,25 +275,25 @@ func (x *PolicyRule) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym23 := z.DecBinary() - _ = yym23 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct24 := r.ContainerType() - if yyct24 == codecSelferValueTypeMap1234 { - yyl24 := r.ReadMapStart() - if yyl24 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl24, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct24 == codecSelferValueTypeArray1234 { - yyl24 := r.ReadArrayStart() - if yyl24 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl24, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -343,12 +305,12 @@ func (x *PolicyRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys25Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys25Slc - var yyhl25 bool = l >= 0 - for yyj25 := 0; ; yyj25++ { - if yyhl25 { - if yyj25 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -357,89 +319,74 @@ func (x *PolicyRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys25Slc = r.DecodeBytes(yys25Slc, true, true) - yys25 := string(yys25Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys25 { + switch yys3 { case "verbs": if r.TryDecodeAsNil() { x.Verbs = nil } else { - yyv26 := &x.Verbs - yym27 := z.DecBinary() - _ = yym27 + yyv4 := &x.Verbs + yym5 := z.DecBinary() + _ = yym5 if false { } else { - z.F.DecSliceStringX(yyv26, false, d) - } - } - case "attributeRestrictions": - if r.TryDecodeAsNil() { - x.AttributeRestrictions = pkg1_runtime.RawExtension{} - } else { - yyv28 := &x.AttributeRestrictions - yym29 := z.DecBinary() - _ = yym29 - if false { - } else if z.HasExtensions() && z.DecExt(yyv28) { - } else if !yym29 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv28) - } else { - z.DecFallback(yyv28, false) + z.F.DecSliceStringX(yyv4, false, d) } } case "apiGroups": if r.TryDecodeAsNil() { x.APIGroups = nil } else { - yyv30 := &x.APIGroups - yym31 := z.DecBinary() - _ = yym31 + yyv6 := &x.APIGroups + yym7 := z.DecBinary() + _ = yym7 if false { } else { - z.F.DecSliceStringX(yyv30, false, d) + z.F.DecSliceStringX(yyv6, false, d) } } case "resources": if r.TryDecodeAsNil() { x.Resources = nil } else { - yyv32 := &x.Resources - yym33 := z.DecBinary() - _ = yym33 + yyv8 := &x.Resources + yym9 := z.DecBinary() + _ = yym9 if false { } else { - z.F.DecSliceStringX(yyv32, false, d) + z.F.DecSliceStringX(yyv8, false, d) } } case "resourceNames": if r.TryDecodeAsNil() { x.ResourceNames = nil } else { - yyv34 := &x.ResourceNames - yym35 := z.DecBinary() - _ = yym35 + yyv10 := &x.ResourceNames + yym11 := z.DecBinary() + _ = yym11 if false { } else { - z.F.DecSliceStringX(yyv34, false, d) + z.F.DecSliceStringX(yyv10, false, d) } } case "nonResourceURLs": if r.TryDecodeAsNil() { x.NonResourceURLs = nil } else { - yyv36 := &x.NonResourceURLs - yym37 := z.DecBinary() - _ = yym37 + yyv12 := &x.NonResourceURLs + yym13 := z.DecBinary() + _ = yym13 if false { } else { - z.F.DecSliceStringX(yyv36, false, d) + z.F.DecSliceStringX(yyv12, false, d) } } default: - z.DecStructFieldNotFound(-1, yys25) - } // end switch yys25 - } // end for yyj25 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -447,16 +394,16 @@ func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj38 int - var yyb38 bool - var yyhl38 bool = l >= 0 - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb38 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb38 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -464,46 +411,21 @@ func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Verbs = nil } else { - yyv39 := &x.Verbs - yym40 := z.DecBinary() - _ = yym40 - if false { - } else { - z.F.DecSliceStringX(yyv39, false, d) - } - } - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l - } else { - yyb38 = r.CheckBreak() - } - if yyb38 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.AttributeRestrictions = pkg1_runtime.RawExtension{} - } else { - yyv41 := &x.AttributeRestrictions - yym42 := z.DecBinary() - _ = yym42 + yyv15 := &x.Verbs + yym16 := z.DecBinary() + _ = yym16 if false { - } else if z.HasExtensions() && z.DecExt(yyv41) { - } else if !yym42 && z.IsJSONHandle() { - z.DecJSONUnmarshal(yyv41) } else { - z.DecFallback(yyv41, false) + z.F.DecSliceStringX(yyv15, false, d) } } - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb38 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb38 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -511,21 +433,21 @@ func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIGroups = nil } else { - yyv43 := &x.APIGroups - yym44 := z.DecBinary() - _ = yym44 + yyv17 := &x.APIGroups + yym18 := z.DecBinary() + _ = yym18 if false { } else { - z.F.DecSliceStringX(yyv43, false, d) + z.F.DecSliceStringX(yyv17, false, d) } } - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb38 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb38 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -533,21 +455,21 @@ func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Resources = nil } else { - yyv45 := &x.Resources - yym46 := z.DecBinary() - _ = yym46 + yyv19 := &x.Resources + yym20 := z.DecBinary() + _ = yym20 if false { } else { - z.F.DecSliceStringX(yyv45, false, d) + z.F.DecSliceStringX(yyv19, false, d) } } - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb38 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb38 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -555,21 +477,21 @@ func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.ResourceNames = nil } else { - yyv47 := &x.ResourceNames - yym48 := z.DecBinary() - _ = yym48 + yyv21 := &x.ResourceNames + yym22 := z.DecBinary() + _ = yym22 if false { } else { - z.F.DecSliceStringX(yyv47, false, d) + z.F.DecSliceStringX(yyv21, false, d) } } - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb38 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb38 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -577,26 +499,26 @@ func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.NonResourceURLs = nil } else { - yyv49 := &x.NonResourceURLs - yym50 := z.DecBinary() - _ = yym50 + yyv23 := &x.NonResourceURLs + yym24 := z.DecBinary() + _ = yym24 if false { } else { - z.F.DecSliceStringX(yyv49, false, d) + z.F.DecSliceStringX(yyv23, false, d) } } for { - yyj38++ - if yyhl38 { - yyb38 = yyj38 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb38 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb38 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj38-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -608,35 +530,35 @@ func (x *Subject) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym51 := z.EncBinary() - _ = yym51 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep52 := !z.EncBinary() - yy2arr52 := z.EncBasicHandle().StructToArray - var yyq52 [4]bool - _, _, _ = yysep52, yyq52, yy2arr52 - const yyr52 bool = false - yyq52[1] = x.APIVersion != "" - yyq52[3] = x.Namespace != "" - var yynn52 int - if yyr52 || yy2arr52 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.APIVersion != "" + yyq2[3] = x.Namespace != "" + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn52 = 2 - for _, b := range yyq52 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn52++ + yynn2++ } } - r.EncodeMapStart(yynn52) - yynn52 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr52 || yy2arr52 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym54 := z.EncBinary() - _ = yym54 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -645,18 +567,18 @@ func (x *Subject) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym55 := z.EncBinary() - _ = yym55 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } - if yyr52 || yy2arr52 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq52[1] { - yym57 := z.EncBinary() - _ = yym57 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -665,22 +587,22 @@ func (x *Subject) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq52[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym58 := z.EncBinary() - _ = yym58 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr52 || yy2arr52 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym60 := z.EncBinary() - _ = yym60 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -689,18 +611,18 @@ func (x *Subject) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym61 := z.EncBinary() - _ = yym61 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr52 || yy2arr52 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq52[3] { - yym63 := z.EncBinary() - _ = yym63 + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) @@ -709,19 +631,19 @@ func (x *Subject) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq52[3] { + if yyq2[3] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("namespace")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym64 := z.EncBinary() - _ = yym64 + yym14 := z.EncBinary() + _ = yym14 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) } } } - if yyr52 || yy2arr52 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -734,25 +656,25 @@ func (x *Subject) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym65 := z.DecBinary() - _ = yym65 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct66 := r.ContainerType() - if yyct66 == codecSelferValueTypeMap1234 { - yyl66 := r.ReadMapStart() - if yyl66 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl66, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct66 == codecSelferValueTypeArray1234 { - yyl66 := r.ReadArrayStart() - if yyl66 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl66, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -764,12 +686,12 @@ func (x *Subject) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys67Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys67Slc - var yyhl67 bool = l >= 0 - for yyj67 := 0; ; yyj67++ { - if yyhl67 { - if yyj67 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -778,38 +700,62 @@ func (x *Subject) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys67Slc = r.DecodeBytes(yys67Slc, true, true) - yys67 := string(yys67Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys67 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } case "namespace": if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys67) - } // end switch yys67 - } // end for yyj67 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -817,16 +763,16 @@ func (x *Subject) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj72 int - var yyb72 bool - var yyhl72 bool = l >= 0 - yyj72++ - if yyhl72 { - yyb72 = yyj72 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb72 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb72 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -834,15 +780,21 @@ func (x *Subject) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj72++ - if yyhl72 { - yyb72 = yyj72 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb72 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb72 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -850,15 +802,21 @@ func (x *Subject) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj72++ - if yyhl72 { - yyb72 = yyj72 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb72 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb72 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -866,15 +824,21 @@ func (x *Subject) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv17 := &x.Name + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj72++ - if yyhl72 { - yyb72 = yyj72 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb72 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb72 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -882,20 +846,26 @@ func (x *Subject) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Namespace = "" } else { - x.Namespace = string(r.DecodeString()) + yyv19 := &x.Namespace + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } } for { - yyj72++ - if yyhl72 { - yyb72 = yyj72 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb72 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb72 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj72-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -907,33 +877,33 @@ func (x *RoleRef) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym77 := z.EncBinary() - _ = yym77 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep78 := !z.EncBinary() - yy2arr78 := z.EncBasicHandle().StructToArray - var yyq78 [3]bool - _, _, _ = yysep78, yyq78, yy2arr78 - const yyr78 bool = false - var yynn78 int - if yyr78 || yy2arr78 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(3) } else { - yynn78 = 3 - for _, b := range yyq78 { + yynn2 = 3 + for _, b := range yyq2 { if b { - yynn78++ + yynn2++ } } - r.EncodeMapStart(yynn78) - yynn78 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr78 || yy2arr78 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym80 := z.EncBinary() - _ = yym80 + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIGroup)) @@ -942,17 +912,17 @@ func (x *RoleRef) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiGroup")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym81 := z.EncBinary() - _ = yym81 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIGroup)) } } - if yyr78 || yy2arr78 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym83 := z.EncBinary() - _ = yym83 + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -961,17 +931,17 @@ func (x *RoleRef) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym84 := z.EncBinary() - _ = yym84 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } - if yyr78 || yy2arr78 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym86 := z.EncBinary() - _ = yym86 + yym10 := z.EncBinary() + _ = yym10 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) @@ -980,14 +950,14 @@ func (x *RoleRef) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("name")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym87 := z.EncBinary() - _ = yym87 + yym11 := z.EncBinary() + _ = yym11 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Name)) } } - if yyr78 || yy2arr78 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1000,25 +970,25 @@ func (x *RoleRef) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym88 := z.DecBinary() - _ = yym88 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct89 := r.ContainerType() - if yyct89 == codecSelferValueTypeMap1234 { - yyl89 := r.ReadMapStart() - if yyl89 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl89, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct89 == codecSelferValueTypeArray1234 { - yyl89 := r.ReadArrayStart() - if yyl89 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl89, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1030,12 +1000,12 @@ func (x *RoleRef) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys90Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys90Slc - var yyhl90 bool = l >= 0 - for yyj90 := 0; ; yyj90++ { - if yyhl90 { - if yyj90 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1044,32 +1014,50 @@ func (x *RoleRef) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys90Slc = r.DecodeBytes(yys90Slc, true, true) - yys90 := string(yys90Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys90 { + switch yys3 { case "apiGroup": if r.TryDecodeAsNil() { x.APIGroup = "" } else { - x.APIGroup = string(r.DecodeString()) + yyv4 := &x.APIGroup + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv6 := &x.Kind + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "name": if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } } default: - z.DecStructFieldNotFound(-1, yys90) - } // end switch yys90 - } // end for yyj90 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1077,16 +1065,16 @@ func (x *RoleRef) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj94 int - var yyb94 bool - var yyhl94 bool = l >= 0 - yyj94++ - if yyhl94 { - yyb94 = yyj94 > l + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb94 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb94 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1094,15 +1082,21 @@ func (x *RoleRef) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIGroup = "" } else { - x.APIGroup = string(r.DecodeString()) + yyv11 := &x.APIGroup + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } } - yyj94++ - if yyhl94 { - yyb94 = yyj94 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb94 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb94 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1110,15 +1104,21 @@ func (x *RoleRef) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj94++ - if yyhl94 { - yyb94 = yyj94 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb94 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb94 { + if yyb10 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1126,20 +1126,26 @@ func (x *RoleRef) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Name = "" } else { - x.Name = string(r.DecodeString()) + yyv15 := &x.Name + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } for { - yyj94++ - if yyhl94 { - yyb94 = yyj94 > l + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l } else { - yyb94 = r.CheckBreak() + yyb10 = r.CheckBreak() } - if yyb94 { + if yyb10 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj94-1, "") + z.DecStructFieldNotFound(yyj10-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1151,37 +1157,37 @@ func (x *Role) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym98 := z.EncBinary() - _ = yym98 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep99 := !z.EncBinary() - yy2arr99 := z.EncBasicHandle().StructToArray - var yyq99 [4]bool - _, _, _ = yysep99, yyq99, yy2arr99 - const yyr99 bool = false - yyq99[0] = x.Kind != "" - yyq99[1] = x.APIVersion != "" - yyq99[2] = true - var yynn99 int - if yyr99 || yy2arr99 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn99 = 1 - for _, b := range yyq99 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn99++ + yynn2++ } } - r.EncodeMapStart(yynn99) - yynn99 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr99 || yy2arr99 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq99[0] { - yym101 := z.EncBinary() - _ = yym101 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1190,23 +1196,23 @@ func (x *Role) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq99[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym102 := z.EncBinary() - _ = yym102 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr99 || yy2arr99 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq99[1] { - yym104 := z.EncBinary() - _ = yym104 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1215,42 +1221,54 @@ func (x *Role) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq99[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym105 := z.EncBinary() - _ = yym105 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr99 || yy2arr99 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq99[2] { - yy107 := &x.ObjectMeta - yy107.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq99[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy108 := &x.ObjectMeta - yy108.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr99 || yy2arr99 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Rules == nil { r.EncodeNil() } else { - yym110 := z.EncBinary() - _ = yym110 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) @@ -1263,15 +1281,15 @@ func (x *Role) CodecEncodeSelf(e *codec1978.Encoder) { if x.Rules == nil { r.EncodeNil() } else { - yym111 := z.EncBinary() - _ = yym111 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) } } } - if yyr99 || yy2arr99 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1284,25 +1302,25 @@ func (x *Role) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym112 := z.DecBinary() - _ = yym112 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct113 := r.ContainerType() - if yyct113 == codecSelferValueTypeMap1234 { - yyl113 := r.ReadMapStart() - if yyl113 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl113, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct113 == codecSelferValueTypeArray1234 { - yyl113 := r.ReadArrayStart() - if yyl113 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl113, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1314,12 +1332,12 @@ func (x *Role) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys114Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys114Slc - var yyhl114 bool = l >= 0 - for yyj114 := 0; ; yyj114++ { - if yyhl114 { - if yyj114 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1328,45 +1346,63 @@ func (x *Role) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys114Slc = r.DecodeBytes(yys114Slc, true, true) - yys114 := string(yys114Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys114 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv117 := &x.ObjectMeta - yyv117.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "rules": if r.TryDecodeAsNil() { x.Rules = nil } else { - yyv118 := &x.Rules - yym119 := z.DecBinary() - _ = yym119 + yyv10 := &x.Rules + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePolicyRule((*[]PolicyRule)(yyv118), d) + h.decSlicePolicyRule((*[]PolicyRule)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys114) - } // end switch yys114 - } // end for yyj114 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1374,16 +1410,16 @@ func (x *Role) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj120 int - var yyb120 bool - var yyhl120 bool = l >= 0 - yyj120++ - if yyhl120 { - yyb120 = yyj120 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb120 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb120 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1391,15 +1427,21 @@ func (x *Role) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj120++ - if yyhl120 { - yyb120 = yyj120 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb120 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb120 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1407,32 +1449,44 @@ func (x *Role) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj120++ - if yyhl120 { - yyb120 = yyj120 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb120 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb120 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv123 := &x.ObjectMeta - yyv123.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj120++ - if yyhl120 { - yyb120 = yyj120 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb120 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb120 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1440,26 +1494,26 @@ func (x *Role) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Rules = nil } else { - yyv124 := &x.Rules - yym125 := z.DecBinary() - _ = yym125 + yyv19 := &x.Rules + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePolicyRule((*[]PolicyRule)(yyv124), d) + h.decSlicePolicyRule((*[]PolicyRule)(yyv19), d) } } for { - yyj120++ - if yyhl120 { - yyb120 = yyj120 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb120 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb120 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj120-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1471,37 +1525,37 @@ func (x *RoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym126 := z.EncBinary() - _ = yym126 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep127 := !z.EncBinary() - yy2arr127 := z.EncBasicHandle().StructToArray - var yyq127 [5]bool - _, _, _ = yysep127, yyq127, yy2arr127 - const yyr127 bool = false - yyq127[0] = x.Kind != "" - yyq127[1] = x.APIVersion != "" - yyq127[2] = true - var yynn127 int - if yyr127 || yy2arr127 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn127 = 2 - for _, b := range yyq127 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn127++ + yynn2++ } } - r.EncodeMapStart(yynn127) - yynn127 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr127 || yy2arr127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq127[0] { - yym129 := z.EncBinary() - _ = yym129 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1510,23 +1564,23 @@ func (x *RoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq127[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym130 := z.EncBinary() - _ = yym130 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr127 || yy2arr127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq127[1] { - yym132 := z.EncBinary() - _ = yym132 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1535,42 +1589,54 @@ func (x *RoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq127[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym133 := z.EncBinary() - _ = yym133 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr127 || yy2arr127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq127[2] { - yy135 := &x.ObjectMeta - yy135.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq127[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy136 := &x.ObjectMeta - yy136.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr127 || yy2arr127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Subjects == nil { r.EncodeNil() } else { - yym138 := z.EncBinary() - _ = yym138 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceSubject(([]Subject)(x.Subjects), e) @@ -1583,26 +1649,26 @@ func (x *RoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { if x.Subjects == nil { r.EncodeNil() } else { - yym139 := z.EncBinary() - _ = yym139 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceSubject(([]Subject)(x.Subjects), e) } } } - if yyr127 || yy2arr127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy141 := &x.RoleRef - yy141.CodecEncodeSelf(e) + yy18 := &x.RoleRef + yy18.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("roleRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy142 := &x.RoleRef - yy142.CodecEncodeSelf(e) + yy20 := &x.RoleRef + yy20.CodecEncodeSelf(e) } - if yyr127 || yy2arr127 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1615,25 +1681,25 @@ func (x *RoleBinding) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym143 := z.DecBinary() - _ = yym143 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct144 := r.ContainerType() - if yyct144 == codecSelferValueTypeMap1234 { - yyl144 := r.ReadMapStart() - if yyl144 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl144, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct144 == codecSelferValueTypeArray1234 { - yyl144 := r.ReadArrayStart() - if yyl144 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl144, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -1645,12 +1711,12 @@ func (x *RoleBinding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys145Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys145Slc - var yyhl145 bool = l >= 0 - for yyj145 := 0; ; yyj145++ { - if yyhl145 { - if yyj145 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -1659,52 +1725,70 @@ func (x *RoleBinding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys145Slc = r.DecodeBytes(yys145Slc, true, true) - yys145 := string(yys145Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys145 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv148 := &x.ObjectMeta - yyv148.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "subjects": if r.TryDecodeAsNil() { x.Subjects = nil } else { - yyv149 := &x.Subjects - yym150 := z.DecBinary() - _ = yym150 + yyv10 := &x.Subjects + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceSubject((*[]Subject)(yyv149), d) + h.decSliceSubject((*[]Subject)(yyv10), d) } } case "roleRef": if r.TryDecodeAsNil() { x.RoleRef = RoleRef{} } else { - yyv151 := &x.RoleRef - yyv151.CodecDecodeSelf(d) + yyv12 := &x.RoleRef + yyv12.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys145) - } // end switch yys145 - } // end for yyj145 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -1712,16 +1796,16 @@ func (x *RoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj152 int - var yyb152 bool - var yyhl152 bool = l >= 0 - yyj152++ - if yyhl152 { - yyb152 = yyj152 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb152 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb152 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1729,15 +1813,21 @@ func (x *RoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv14 := &x.Kind + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj152++ - if yyhl152 { - yyb152 = yyj152 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb152 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb152 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1745,32 +1835,44 @@ func (x *RoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv16 := &x.APIVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } - yyj152++ - if yyhl152 { - yyb152 = yyj152 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb152 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb152 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv155 := &x.ObjectMeta - yyv155.CodecDecodeSelf(d) + yyv18 := &x.ObjectMeta + yym19 := z.DecBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else { + z.DecFallback(yyv18, false) + } } - yyj152++ - if yyhl152 { - yyb152 = yyj152 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb152 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb152 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1778,21 +1880,21 @@ func (x *RoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Subjects = nil } else { - yyv156 := &x.Subjects - yym157 := z.DecBinary() - _ = yym157 + yyv20 := &x.Subjects + yym21 := z.DecBinary() + _ = yym21 if false { } else { - h.decSliceSubject((*[]Subject)(yyv156), d) + h.decSliceSubject((*[]Subject)(yyv20), d) } } - yyj152++ - if yyhl152 { - yyb152 = yyj152 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb152 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb152 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -1800,21 +1902,21 @@ func (x *RoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.RoleRef = RoleRef{} } else { - yyv158 := &x.RoleRef - yyv158.CodecDecodeSelf(d) + yyv22 := &x.RoleRef + yyv22.CodecDecodeSelf(d) } for { - yyj152++ - if yyhl152 { - yyb152 = yyj152 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb152 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb152 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj152-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -1826,37 +1928,37 @@ func (x *RoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym159 := z.EncBinary() - _ = yym159 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep160 := !z.EncBinary() - yy2arr160 := z.EncBasicHandle().StructToArray - var yyq160 [4]bool - _, _, _ = yysep160, yyq160, yy2arr160 - const yyr160 bool = false - yyq160[0] = x.Kind != "" - yyq160[1] = x.APIVersion != "" - yyq160[2] = true - var yynn160 int - if yyr160 || yy2arr160 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn160 = 1 - for _, b := range yyq160 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn160++ + yynn2++ } } - r.EncodeMapStart(yynn160) - yynn160 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr160 || yy2arr160 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq160[0] { - yym162 := z.EncBinary() - _ = yym162 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -1865,23 +1967,23 @@ func (x *RoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq160[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym163 := z.EncBinary() - _ = yym163 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr160 || yy2arr160 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq160[1] { - yym165 := z.EncBinary() - _ = yym165 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -1890,54 +1992,54 @@ func (x *RoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq160[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym166 := z.EncBinary() - _ = yym166 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr160 || yy2arr160 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq160[2] { - yy168 := &x.ListMeta - yym169 := z.EncBinary() - _ = yym169 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy168) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy168) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq160[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy170 := &x.ListMeta - yym171 := z.EncBinary() - _ = yym171 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy170) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy170) + z.EncFallback(yy12) } } } - if yyr160 || yy2arr160 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym173 := z.EncBinary() - _ = yym173 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceRoleBinding(([]RoleBinding)(x.Items), e) @@ -1950,15 +2052,15 @@ func (x *RoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym174 := z.EncBinary() - _ = yym174 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceRoleBinding(([]RoleBinding)(x.Items), e) } } } - if yyr160 || yy2arr160 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -1971,25 +2073,25 @@ func (x *RoleBindingList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym175 := z.DecBinary() - _ = yym175 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct176 := r.ContainerType() - if yyct176 == codecSelferValueTypeMap1234 { - yyl176 := r.ReadMapStart() - if yyl176 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl176, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct176 == codecSelferValueTypeArray1234 { - yyl176 := r.ReadArrayStart() - if yyl176 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl176, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2001,12 +2103,12 @@ func (x *RoleBindingList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys177Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys177Slc - var yyhl177 bool = l >= 0 - for yyj177 := 0; ; yyj177++ { - if yyhl177 { - if yyj177 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2015,51 +2117,63 @@ func (x *RoleBindingList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys177Slc = r.DecodeBytes(yys177Slc, true, true) - yys177 := string(yys177Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys177 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv180 := &x.ListMeta - yym181 := z.DecBinary() - _ = yym181 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv180) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv180, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv182 := &x.Items - yym183 := z.DecBinary() - _ = yym183 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceRoleBinding((*[]RoleBinding)(yyv182), d) + h.decSliceRoleBinding((*[]RoleBinding)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys177) - } // end switch yys177 - } // end for yyj177 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2067,16 +2181,16 @@ func (x *RoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj184 int - var yyb184 bool - var yyhl184 bool = l >= 0 - yyj184++ - if yyhl184 { - yyb184 = yyj184 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb184 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb184 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2084,15 +2198,21 @@ func (x *RoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj184++ - if yyhl184 { - yyb184 = yyj184 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb184 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb184 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2100,38 +2220,44 @@ func (x *RoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj184++ - if yyhl184 { - yyb184 = yyj184 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb184 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb184 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv187 := &x.ListMeta - yym188 := z.DecBinary() - _ = yym188 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv187) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv187, false) + z.DecFallback(yyv17, false) } } - yyj184++ - if yyhl184 { - yyb184 = yyj184 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb184 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb184 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2139,26 +2265,26 @@ func (x *RoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Items = nil } else { - yyv189 := &x.Items - yym190 := z.DecBinary() - _ = yym190 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceRoleBinding((*[]RoleBinding)(yyv189), d) + h.decSliceRoleBinding((*[]RoleBinding)(yyv19), d) } } for { - yyj184++ - if yyhl184 { - yyb184 = yyj184 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb184 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb184 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj184-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2170,37 +2296,37 @@ func (x *RoleList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym191 := z.EncBinary() - _ = yym191 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep192 := !z.EncBinary() - yy2arr192 := z.EncBasicHandle().StructToArray - var yyq192 [4]bool - _, _, _ = yysep192, yyq192, yy2arr192 - const yyr192 bool = false - yyq192[0] = x.Kind != "" - yyq192[1] = x.APIVersion != "" - yyq192[2] = true - var yynn192 int - if yyr192 || yy2arr192 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn192 = 1 - for _, b := range yyq192 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn192++ + yynn2++ } } - r.EncodeMapStart(yynn192) - yynn192 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq192[0] { - yym194 := z.EncBinary() - _ = yym194 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -2209,23 +2335,23 @@ func (x *RoleList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq192[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym195 := z.EncBinary() - _ = yym195 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq192[1] { - yym197 := z.EncBinary() - _ = yym197 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -2234,54 +2360,54 @@ func (x *RoleList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq192[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym198 := z.EncBinary() - _ = yym198 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq192[2] { - yy200 := &x.ListMeta - yym201 := z.EncBinary() - _ = yym201 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy200) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy200) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq192[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy202 := &x.ListMeta - yym203 := z.EncBinary() - _ = yym203 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy202) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy202) + z.EncFallback(yy12) } } } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym205 := z.EncBinary() - _ = yym205 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceRole(([]Role)(x.Items), e) @@ -2294,15 +2420,15 @@ func (x *RoleList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym206 := z.EncBinary() - _ = yym206 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceRole(([]Role)(x.Items), e) } } } - if yyr192 || yy2arr192 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2315,25 +2441,25 @@ func (x *RoleList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym207 := z.DecBinary() - _ = yym207 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct208 := r.ContainerType() - if yyct208 == codecSelferValueTypeMap1234 { - yyl208 := r.ReadMapStart() - if yyl208 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl208, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct208 == codecSelferValueTypeArray1234 { - yyl208 := r.ReadArrayStart() - if yyl208 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl208, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2345,12 +2471,12 @@ func (x *RoleList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys209Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys209Slc - var yyhl209 bool = l >= 0 - for yyj209 := 0; ; yyj209++ { - if yyhl209 { - if yyj209 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2359,51 +2485,63 @@ func (x *RoleList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys209Slc = r.DecodeBytes(yys209Slc, true, true) - yys209 := string(yys209Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys209 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv212 := &x.ListMeta - yym213 := z.DecBinary() - _ = yym213 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv212) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv212, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv214 := &x.Items - yym215 := z.DecBinary() - _ = yym215 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceRole((*[]Role)(yyv214), d) + h.decSliceRole((*[]Role)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys209) - } // end switch yys209 - } // end for yyj209 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2411,16 +2549,16 @@ func (x *RoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj216 int - var yyb216 bool - var yyhl216 bool = l >= 0 - yyj216++ - if yyhl216 { - yyb216 = yyj216 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb216 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb216 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2428,15 +2566,21 @@ func (x *RoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj216++ - if yyhl216 { - yyb216 = yyj216 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb216 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb216 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2444,38 +2588,44 @@ func (x *RoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj216++ - if yyhl216 { - yyb216 = yyj216 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb216 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb216 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv219 := &x.ListMeta - yym220 := z.DecBinary() - _ = yym220 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv219) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv219, false) + z.DecFallback(yyv17, false) } } - yyj216++ - if yyhl216 { - yyb216 = yyj216 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb216 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb216 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2483,26 +2633,26 @@ func (x *RoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Items = nil } else { - yyv221 := &x.Items - yym222 := z.DecBinary() - _ = yym222 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceRole((*[]Role)(yyv221), d) + h.decSliceRole((*[]Role)(yyv19), d) } } for { - yyj216++ - if yyhl216 { - yyb216 = yyj216 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb216 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb216 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj216-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2514,37 +2664,37 @@ func (x *ClusterRole) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym223 := z.EncBinary() - _ = yym223 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep224 := !z.EncBinary() - yy2arr224 := z.EncBasicHandle().StructToArray - var yyq224 [4]bool - _, _, _ = yysep224, yyq224, yy2arr224 - const yyr224 bool = false - yyq224[0] = x.Kind != "" - yyq224[1] = x.APIVersion != "" - yyq224[2] = true - var yynn224 int - if yyr224 || yy2arr224 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn224 = 1 - for _, b := range yyq224 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn224++ + yynn2++ } } - r.EncodeMapStart(yynn224) - yynn224 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr224 || yy2arr224 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq224[0] { - yym226 := z.EncBinary() - _ = yym226 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -2553,23 +2703,23 @@ func (x *ClusterRole) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq224[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym227 := z.EncBinary() - _ = yym227 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr224 || yy2arr224 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq224[1] { - yym229 := z.EncBinary() - _ = yym229 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -2578,42 +2728,54 @@ func (x *ClusterRole) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq224[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym230 := z.EncBinary() - _ = yym230 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr224 || yy2arr224 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq224[2] { - yy232 := &x.ObjectMeta - yy232.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq224[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy233 := &x.ObjectMeta - yy233.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr224 || yy2arr224 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Rules == nil { r.EncodeNil() } else { - yym235 := z.EncBinary() - _ = yym235 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) @@ -2626,15 +2788,15 @@ func (x *ClusterRole) CodecEncodeSelf(e *codec1978.Encoder) { if x.Rules == nil { r.EncodeNil() } else { - yym236 := z.EncBinary() - _ = yym236 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) } } } - if yyr224 || yy2arr224 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2647,25 +2809,25 @@ func (x *ClusterRole) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym237 := z.DecBinary() - _ = yym237 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct238 := r.ContainerType() - if yyct238 == codecSelferValueTypeMap1234 { - yyl238 := r.ReadMapStart() - if yyl238 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl238, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct238 == codecSelferValueTypeArray1234 { - yyl238 := r.ReadArrayStart() - if yyl238 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl238, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -2677,12 +2839,12 @@ func (x *ClusterRole) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys239Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys239Slc - var yyhl239 bool = l >= 0 - for yyj239 := 0; ; yyj239++ { - if yyhl239 { - if yyj239 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -2691,45 +2853,63 @@ func (x *ClusterRole) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys239Slc = r.DecodeBytes(yys239Slc, true, true) - yys239 := string(yys239Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys239 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv242 := &x.ObjectMeta - yyv242.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "rules": if r.TryDecodeAsNil() { x.Rules = nil } else { - yyv243 := &x.Rules - yym244 := z.DecBinary() - _ = yym244 + yyv10 := &x.Rules + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSlicePolicyRule((*[]PolicyRule)(yyv243), d) + h.decSlicePolicyRule((*[]PolicyRule)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys239) - } // end switch yys239 - } // end for yyj239 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -2737,16 +2917,16 @@ func (x *ClusterRole) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj245 int - var yyb245 bool - var yyhl245 bool = l >= 0 - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2754,15 +2934,21 @@ func (x *ClusterRole) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2770,32 +2956,44 @@ func (x *ClusterRole) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv248 := &x.ObjectMeta - yyv248.CodecDecodeSelf(d) + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } } - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -2803,26 +3001,26 @@ func (x *ClusterRole) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Rules = nil } else { - yyv249 := &x.Rules - yym250 := z.DecBinary() - _ = yym250 + yyv19 := &x.Rules + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSlicePolicyRule((*[]PolicyRule)(yyv249), d) + h.decSlicePolicyRule((*[]PolicyRule)(yyv19), d) } } for { - yyj245++ - if yyhl245 { - yyb245 = yyj245 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb245 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb245 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj245-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -2834,37 +3032,37 @@ func (x *ClusterRoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym251 := z.EncBinary() - _ = yym251 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep252 := !z.EncBinary() - yy2arr252 := z.EncBasicHandle().StructToArray - var yyq252 [5]bool - _, _, _ = yysep252, yyq252, yy2arr252 - const yyr252 bool = false - yyq252[0] = x.Kind != "" - yyq252[1] = x.APIVersion != "" - yyq252[2] = true - var yynn252 int - if yyr252 || yy2arr252 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(5) } else { - yynn252 = 2 - for _, b := range yyq252 { + yynn2 = 2 + for _, b := range yyq2 { if b { - yynn252++ + yynn2++ } } - r.EncodeMapStart(yynn252) - yynn252 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr252 || yy2arr252 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq252[0] { - yym254 := z.EncBinary() - _ = yym254 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -2873,23 +3071,23 @@ func (x *ClusterRoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq252[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym255 := z.EncBinary() - _ = yym255 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr252 || yy2arr252 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq252[1] { - yym257 := z.EncBinary() - _ = yym257 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -2898,42 +3096,54 @@ func (x *ClusterRoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq252[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym258 := z.EncBinary() - _ = yym258 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr252 || yy2arr252 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq252[2] { - yy260 := &x.ObjectMeta - yy260.CodecEncodeSelf(e) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } } else { - if yyq252[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy261 := &x.ObjectMeta - yy261.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } - if yyr252 || yy2arr252 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Subjects == nil { r.EncodeNil() } else { - yym263 := z.EncBinary() - _ = yym263 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceSubject(([]Subject)(x.Subjects), e) @@ -2946,26 +3156,26 @@ func (x *ClusterRoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { if x.Subjects == nil { r.EncodeNil() } else { - yym264 := z.EncBinary() - _ = yym264 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceSubject(([]Subject)(x.Subjects), e) } } } - if yyr252 || yy2arr252 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy266 := &x.RoleRef - yy266.CodecEncodeSelf(e) + yy18 := &x.RoleRef + yy18.CodecEncodeSelf(e) } else { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("roleRef")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy267 := &x.RoleRef - yy267.CodecEncodeSelf(e) + yy20 := &x.RoleRef + yy20.CodecEncodeSelf(e) } - if yyr252 || yy2arr252 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -2978,25 +3188,25 @@ func (x *ClusterRoleBinding) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym268 := z.DecBinary() - _ = yym268 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct269 := r.ContainerType() - if yyct269 == codecSelferValueTypeMap1234 { - yyl269 := r.ReadMapStart() - if yyl269 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl269, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct269 == codecSelferValueTypeArray1234 { - yyl269 := r.ReadArrayStart() - if yyl269 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl269, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3008,12 +3218,12 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys270Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys270Slc - var yyhl270 bool = l >= 0 - for yyj270 := 0; ; yyj270++ { - if yyhl270 { - if yyj270 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3022,52 +3232,70 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys270Slc = r.DecodeBytes(yys270Slc, true, true) - yys270 := string(yys270Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys270 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv273 := &x.ObjectMeta - yyv273.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "subjects": if r.TryDecodeAsNil() { x.Subjects = nil } else { - yyv274 := &x.Subjects - yym275 := z.DecBinary() - _ = yym275 + yyv10 := &x.Subjects + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceSubject((*[]Subject)(yyv274), d) + h.decSliceSubject((*[]Subject)(yyv10), d) } } case "roleRef": if r.TryDecodeAsNil() { x.RoleRef = RoleRef{} } else { - yyv276 := &x.RoleRef - yyv276.CodecDecodeSelf(d) + yyv12 := &x.RoleRef + yyv12.CodecDecodeSelf(d) } default: - z.DecStructFieldNotFound(-1, yys270) - } // end switch yys270 - } // end for yyj270 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3075,16 +3303,16 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decode var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj277 int - var yyb277 bool - var yyhl277 bool = l >= 0 - yyj277++ - if yyhl277 { - yyb277 = yyj277 > l + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb277 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb277 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3092,15 +3320,21 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv14 := &x.Kind + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } } - yyj277++ - if yyhl277 { - yyb277 = yyj277 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb277 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb277 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3108,32 +3342,44 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv16 := &x.APIVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } } - yyj277++ - if yyhl277 { - yyb277 = yyj277 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb277 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb277 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg3_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv280 := &x.ObjectMeta - yyv280.CodecDecodeSelf(d) + yyv18 := &x.ObjectMeta + yym19 := z.DecBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else { + z.DecFallback(yyv18, false) + } } - yyj277++ - if yyhl277 { - yyb277 = yyj277 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb277 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb277 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3141,21 +3387,21 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.Subjects = nil } else { - yyv281 := &x.Subjects - yym282 := z.DecBinary() - _ = yym282 + yyv20 := &x.Subjects + yym21 := z.DecBinary() + _ = yym21 if false { } else { - h.decSliceSubject((*[]Subject)(yyv281), d) + h.decSliceSubject((*[]Subject)(yyv20), d) } } - yyj277++ - if yyhl277 { - yyb277 = yyj277 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb277 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb277 { + if yyb13 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3163,21 +3409,21 @@ func (x *ClusterRoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decode if r.TryDecodeAsNil() { x.RoleRef = RoleRef{} } else { - yyv283 := &x.RoleRef - yyv283.CodecDecodeSelf(d) + yyv22 := &x.RoleRef + yyv22.CodecDecodeSelf(d) } for { - yyj277++ - if yyhl277 { - yyb277 = yyj277 > l + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l } else { - yyb277 = r.CheckBreak() + yyb13 = r.CheckBreak() } - if yyb277 { + if yyb13 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj277-1, "") + z.DecStructFieldNotFound(yyj13-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3189,37 +3435,37 @@ func (x *ClusterRoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym284 := z.EncBinary() - _ = yym284 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep285 := !z.EncBinary() - yy2arr285 := z.EncBasicHandle().StructToArray - var yyq285 [4]bool - _, _, _ = yysep285, yyq285, yy2arr285 - const yyr285 bool = false - yyq285[0] = x.Kind != "" - yyq285[1] = x.APIVersion != "" - yyq285[2] = true - var yynn285 int - if yyr285 || yy2arr285 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn285 = 1 - for _, b := range yyq285 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn285++ + yynn2++ } } - r.EncodeMapStart(yynn285) - yynn285 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr285 || yy2arr285 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq285[0] { - yym287 := z.EncBinary() - _ = yym287 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -3228,23 +3474,23 @@ func (x *ClusterRoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq285[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym288 := z.EncBinary() - _ = yym288 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr285 || yy2arr285 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq285[1] { - yym290 := z.EncBinary() - _ = yym290 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -3253,54 +3499,54 @@ func (x *ClusterRoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq285[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym291 := z.EncBinary() - _ = yym291 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr285 || yy2arr285 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq285[2] { - yy293 := &x.ListMeta - yym294 := z.EncBinary() - _ = yym294 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy293) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy293) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq285[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy295 := &x.ListMeta - yym296 := z.EncBinary() - _ = yym296 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy295) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy295) + z.EncFallback(yy12) } } } - if yyr285 || yy2arr285 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym298 := z.EncBinary() - _ = yym298 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceClusterRoleBinding(([]ClusterRoleBinding)(x.Items), e) @@ -3313,15 +3559,15 @@ func (x *ClusterRoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym299 := z.EncBinary() - _ = yym299 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceClusterRoleBinding(([]ClusterRoleBinding)(x.Items), e) } } } - if yyr285 || yy2arr285 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -3334,25 +3580,25 @@ func (x *ClusterRoleBindingList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym300 := z.DecBinary() - _ = yym300 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct301 := r.ContainerType() - if yyct301 == codecSelferValueTypeMap1234 { - yyl301 := r.ReadMapStart() - if yyl301 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl301, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct301 == codecSelferValueTypeArray1234 { - yyl301 := r.ReadArrayStart() - if yyl301 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl301, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3364,12 +3610,12 @@ func (x *ClusterRoleBindingList) codecDecodeSelfFromMap(l int, d *codec1978.Deco var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys302Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys302Slc - var yyhl302 bool = l >= 0 - for yyj302 := 0; ; yyj302++ { - if yyhl302 { - if yyj302 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3378,51 +3624,63 @@ func (x *ClusterRoleBindingList) codecDecodeSelfFromMap(l int, d *codec1978.Deco } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys302Slc = r.DecodeBytes(yys302Slc, true, true) - yys302 := string(yys302Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys302 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv305 := &x.ListMeta - yym306 := z.DecBinary() - _ = yym306 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv305) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv305, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv307 := &x.Items - yym308 := z.DecBinary() - _ = yym308 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceClusterRoleBinding((*[]ClusterRoleBinding)(yyv307), d) + h.decSliceClusterRoleBinding((*[]ClusterRoleBinding)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys302) - } // end switch yys302 - } // end for yyj302 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3430,16 +3688,16 @@ func (x *ClusterRoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.De var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj309 int - var yyb309 bool - var yyhl309 bool = l >= 0 - yyj309++ - if yyhl309 { - yyb309 = yyj309 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb309 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb309 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3447,15 +3705,21 @@ func (x *ClusterRoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj309++ - if yyhl309 { - yyb309 = yyj309 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb309 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb309 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3463,38 +3727,44 @@ func (x *ClusterRoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj309++ - if yyhl309 { - yyb309 = yyj309 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb309 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb309 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv312 := &x.ListMeta - yym313 := z.DecBinary() - _ = yym313 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv312) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv312, false) + z.DecFallback(yyv17, false) } } - yyj309++ - if yyhl309 { - yyb309 = yyj309 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb309 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb309 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3502,26 +3772,26 @@ func (x *ClusterRoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.De if r.TryDecodeAsNil() { x.Items = nil } else { - yyv314 := &x.Items - yym315 := z.DecBinary() - _ = yym315 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceClusterRoleBinding((*[]ClusterRoleBinding)(yyv314), d) + h.decSliceClusterRoleBinding((*[]ClusterRoleBinding)(yyv19), d) } } for { - yyj309++ - if yyhl309 { - yyb309 = yyj309 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb309 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb309 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj309-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3533,37 +3803,37 @@ func (x *ClusterRoleList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym316 := z.EncBinary() - _ = yym316 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep317 := !z.EncBinary() - yy2arr317 := z.EncBasicHandle().StructToArray - var yyq317 [4]bool - _, _, _ = yysep317, yyq317, yy2arr317 - const yyr317 bool = false - yyq317[0] = x.Kind != "" - yyq317[1] = x.APIVersion != "" - yyq317[2] = true - var yynn317 int - if yyr317 || yy2arr317 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn317 = 1 - for _, b := range yyq317 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn317++ + yynn2++ } } - r.EncodeMapStart(yynn317) - yynn317 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr317 || yy2arr317 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq317[0] { - yym319 := z.EncBinary() - _ = yym319 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -3572,23 +3842,23 @@ func (x *ClusterRoleList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq317[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym320 := z.EncBinary() - _ = yym320 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr317 || yy2arr317 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq317[1] { - yym322 := z.EncBinary() - _ = yym322 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -3597,54 +3867,54 @@ func (x *ClusterRoleList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq317[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym323 := z.EncBinary() - _ = yym323 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr317 || yy2arr317 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq317[2] { - yy325 := &x.ListMeta - yym326 := z.EncBinary() - _ = yym326 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy325) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy325) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq317[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy327 := &x.ListMeta - yym328 := z.EncBinary() - _ = yym328 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy327) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy327) + z.EncFallback(yy12) } } } - if yyr317 || yy2arr317 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym330 := z.EncBinary() - _ = yym330 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceClusterRole(([]ClusterRole)(x.Items), e) @@ -3657,15 +3927,15 @@ func (x *ClusterRoleList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym331 := z.EncBinary() - _ = yym331 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceClusterRole(([]ClusterRole)(x.Items), e) } } } - if yyr317 || yy2arr317 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -3678,25 +3948,25 @@ func (x *ClusterRoleList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym332 := z.DecBinary() - _ = yym332 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct333 := r.ContainerType() - if yyct333 == codecSelferValueTypeMap1234 { - yyl333 := r.ReadMapStart() - if yyl333 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl333, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct333 == codecSelferValueTypeArray1234 { - yyl333 := r.ReadArrayStart() - if yyl333 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl333, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -3708,12 +3978,12 @@ func (x *ClusterRoleList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys334Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys334Slc - var yyhl334 bool = l >= 0 - for yyj334 := 0; ; yyj334++ { - if yyhl334 { - if yyj334 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -3722,51 +3992,63 @@ func (x *ClusterRoleList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys334Slc = r.DecodeBytes(yys334Slc, true, true) - yys334 := string(yys334Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys334 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv337 := &x.ListMeta - yym338 := z.DecBinary() - _ = yym338 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv337) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv337, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv339 := &x.Items - yym340 := z.DecBinary() - _ = yym340 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceClusterRole((*[]ClusterRole)(yyv339), d) + h.decSliceClusterRole((*[]ClusterRole)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys334) - } // end switch yys334 - } // end for yyj334 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -3774,16 +4056,16 @@ func (x *ClusterRoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj341 int - var yyb341 bool - var yyhl341 bool = l >= 0 - yyj341++ - if yyhl341 { - yyb341 = yyj341 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb341 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb341 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3791,15 +4073,21 @@ func (x *ClusterRoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj341++ - if yyhl341 { - yyb341 = yyj341 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb341 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb341 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3807,38 +4095,44 @@ func (x *ClusterRoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj341++ - if yyhl341 { - yyb341 = yyj341 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb341 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb341 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg2_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv344 := &x.ListMeta - yym345 := z.DecBinary() - _ = yym345 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv344) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv344, false) + z.DecFallback(yyv17, false) } } - yyj341++ - if yyhl341 { - yyb341 = yyj341 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb341 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb341 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -3846,26 +4140,26 @@ func (x *ClusterRoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Items = nil } else { - yyv346 := &x.Items - yym347 := z.DecBinary() - _ = yym347 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceClusterRole((*[]ClusterRole)(yyv346), d) + h.decSliceClusterRole((*[]ClusterRole)(yyv19), d) } } for { - yyj341++ - if yyhl341 { - yyb341 = yyj341 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb341 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb341 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj341-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3875,10 +4169,10 @@ func (x codecSelfer1234) encSlicePolicyRule(v []PolicyRule, e *codec1978.Encoder z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv348 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy349 := &yyv348 - yy349.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -3888,83 +4182,86 @@ func (x codecSelfer1234) decSlicePolicyRule(v *[]PolicyRule, d *codec1978.Decode z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv350 := *v - yyh350, yyl350 := z.DecSliceHelperStart() - var yyc350 bool - if yyl350 == 0 { - if yyv350 == nil { - yyv350 = []PolicyRule{} - yyc350 = true - } else if len(yyv350) != 0 { - yyv350 = yyv350[:0] - yyc350 = true - } - } else if yyl350 > 0 { - var yyrr350, yyrl350 int - var yyrt350 bool - if yyl350 > cap(yyv350) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PolicyRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg350 := len(yyv350) > 0 - yyv2350 := yyv350 - yyrl350, yyrt350 = z.DecInferLen(yyl350, z.DecBasicHandle().MaxInitLen, 160) - if yyrt350 { - if yyrl350 <= cap(yyv350) { - yyv350 = yyv350[:yyrl350] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 120) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv350 = make([]PolicyRule, yyrl350) + yyv1 = make([]PolicyRule, yyrl1) } } else { - yyv350 = make([]PolicyRule, yyrl350) + yyv1 = make([]PolicyRule, yyrl1) } - yyc350 = true - yyrr350 = len(yyv350) - if yyrg350 { - copy(yyv350, yyv2350) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl350 != len(yyv350) { - yyv350 = yyv350[:yyl350] - yyc350 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj350 := 0 - for ; yyj350 < yyrr350; yyj350++ { - yyh350.ElemContainerState(yyj350) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv350[yyj350] = PolicyRule{} + yyv1[yyj1] = PolicyRule{} } else { - yyv351 := &yyv350[yyj350] - yyv351.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt350 { - for ; yyj350 < yyl350; yyj350++ { - yyv350 = append(yyv350, PolicyRule{}) - yyh350.ElemContainerState(yyj350) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PolicyRule{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv350[yyj350] = PolicyRule{} + yyv1[yyj1] = PolicyRule{} } else { - yyv352 := &yyv350[yyj350] - yyv352.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj350 := 0 - for ; !r.CheckBreak(); yyj350++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj350 >= len(yyv350) { - yyv350 = append(yyv350, PolicyRule{}) // var yyz350 PolicyRule - yyc350 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PolicyRule{}) // var yyz1 PolicyRule + yyc1 = true } - yyh350.ElemContainerState(yyj350) - if yyj350 < len(yyv350) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv350[yyj350] = PolicyRule{} + yyv1[yyj1] = PolicyRule{} } else { - yyv353 := &yyv350[yyj350] - yyv353.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -3972,17 +4269,17 @@ func (x codecSelfer1234) decSlicePolicyRule(v *[]PolicyRule, d *codec1978.Decode } } - if yyj350 < len(yyv350) { - yyv350 = yyv350[:yyj350] - yyc350 = true - } else if yyj350 == 0 && yyv350 == nil { - yyv350 = []PolicyRule{} - yyc350 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PolicyRule{} + yyc1 = true } } - yyh350.End() - if yyc350 { - *v = yyv350 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -3991,10 +4288,10 @@ func (x codecSelfer1234) encSliceSubject(v []Subject, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv354 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy355 := &yyv354 - yy355.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4004,83 +4301,86 @@ func (x codecSelfer1234) decSliceSubject(v *[]Subject, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv356 := *v - yyh356, yyl356 := z.DecSliceHelperStart() - var yyc356 bool - if yyl356 == 0 { - if yyv356 == nil { - yyv356 = []Subject{} - yyc356 = true - } else if len(yyv356) != 0 { - yyv356 = yyv356[:0] - yyc356 = true - } - } else if yyl356 > 0 { - var yyrr356, yyrl356 int - var yyrt356 bool - if yyl356 > cap(yyv356) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Subject{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg356 := len(yyv356) > 0 - yyv2356 := yyv356 - yyrl356, yyrt356 = z.DecInferLen(yyl356, z.DecBasicHandle().MaxInitLen, 64) - if yyrt356 { - if yyrl356 <= cap(yyv356) { - yyv356 = yyv356[:yyrl356] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 64) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv356 = make([]Subject, yyrl356) + yyv1 = make([]Subject, yyrl1) } } else { - yyv356 = make([]Subject, yyrl356) + yyv1 = make([]Subject, yyrl1) } - yyc356 = true - yyrr356 = len(yyv356) - if yyrg356 { - copy(yyv356, yyv2356) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl356 != len(yyv356) { - yyv356 = yyv356[:yyl356] - yyc356 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj356 := 0 - for ; yyj356 < yyrr356; yyj356++ { - yyh356.ElemContainerState(yyj356) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv356[yyj356] = Subject{} + yyv1[yyj1] = Subject{} } else { - yyv357 := &yyv356[yyj356] - yyv357.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt356 { - for ; yyj356 < yyl356; yyj356++ { - yyv356 = append(yyv356, Subject{}) - yyh356.ElemContainerState(yyj356) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Subject{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv356[yyj356] = Subject{} + yyv1[yyj1] = Subject{} } else { - yyv358 := &yyv356[yyj356] - yyv358.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj356 := 0 - for ; !r.CheckBreak(); yyj356++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj356 >= len(yyv356) { - yyv356 = append(yyv356, Subject{}) // var yyz356 Subject - yyc356 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Subject{}) // var yyz1 Subject + yyc1 = true } - yyh356.ElemContainerState(yyj356) - if yyj356 < len(yyv356) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv356[yyj356] = Subject{} + yyv1[yyj1] = Subject{} } else { - yyv359 := &yyv356[yyj356] - yyv359.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4088,17 +4388,17 @@ func (x codecSelfer1234) decSliceSubject(v *[]Subject, d *codec1978.Decoder) { } } - if yyj356 < len(yyv356) { - yyv356 = yyv356[:yyj356] - yyc356 = true - } else if yyj356 == 0 && yyv356 == nil { - yyv356 = []Subject{} - yyc356 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Subject{} + yyc1 = true } } - yyh356.End() - if yyc356 { - *v = yyv356 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -4107,10 +4407,10 @@ func (x codecSelfer1234) encSliceRoleBinding(v []RoleBinding, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv360 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy361 := &yyv360 - yy361.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4120,83 +4420,86 @@ func (x codecSelfer1234) decSliceRoleBinding(v *[]RoleBinding, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv362 := *v - yyh362, yyl362 := z.DecSliceHelperStart() - var yyc362 bool - if yyl362 == 0 { - if yyv362 == nil { - yyv362 = []RoleBinding{} - yyc362 = true - } else if len(yyv362) != 0 { - yyv362 = yyv362[:0] - yyc362 = true - } - } else if yyl362 > 0 { - var yyrr362, yyrl362 int - var yyrt362 bool - if yyl362 > cap(yyv362) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []RoleBinding{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg362 := len(yyv362) > 0 - yyv2362 := yyv362 - yyrl362, yyrt362 = z.DecInferLen(yyl362, z.DecBasicHandle().MaxInitLen, 328) - if yyrt362 { - if yyrl362 <= cap(yyv362) { - yyv362 = yyv362[:yyrl362] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 336) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv362 = make([]RoleBinding, yyrl362) + yyv1 = make([]RoleBinding, yyrl1) } } else { - yyv362 = make([]RoleBinding, yyrl362) + yyv1 = make([]RoleBinding, yyrl1) } - yyc362 = true - yyrr362 = len(yyv362) - if yyrg362 { - copy(yyv362, yyv2362) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl362 != len(yyv362) { - yyv362 = yyv362[:yyl362] - yyc362 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj362 := 0 - for ; yyj362 < yyrr362; yyj362++ { - yyh362.ElemContainerState(yyj362) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv362[yyj362] = RoleBinding{} + yyv1[yyj1] = RoleBinding{} } else { - yyv363 := &yyv362[yyj362] - yyv363.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt362 { - for ; yyj362 < yyl362; yyj362++ { - yyv362 = append(yyv362, RoleBinding{}) - yyh362.ElemContainerState(yyj362) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, RoleBinding{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv362[yyj362] = RoleBinding{} + yyv1[yyj1] = RoleBinding{} } else { - yyv364 := &yyv362[yyj362] - yyv364.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj362 := 0 - for ; !r.CheckBreak(); yyj362++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj362 >= len(yyv362) { - yyv362 = append(yyv362, RoleBinding{}) // var yyz362 RoleBinding - yyc362 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, RoleBinding{}) // var yyz1 RoleBinding + yyc1 = true } - yyh362.ElemContainerState(yyj362) - if yyj362 < len(yyv362) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv362[yyj362] = RoleBinding{} + yyv1[yyj1] = RoleBinding{} } else { - yyv365 := &yyv362[yyj362] - yyv365.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4204,17 +4507,17 @@ func (x codecSelfer1234) decSliceRoleBinding(v *[]RoleBinding, d *codec1978.Deco } } - if yyj362 < len(yyv362) { - yyv362 = yyv362[:yyj362] - yyc362 = true - } else if yyj362 == 0 && yyv362 == nil { - yyv362 = []RoleBinding{} - yyc362 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []RoleBinding{} + yyc1 = true } } - yyh362.End() - if yyc362 { - *v = yyv362 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -4223,10 +4526,10 @@ func (x codecSelfer1234) encSliceRole(v []Role, e *codec1978.Encoder) { z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv366 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy367 := &yyv366 - yy367.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4236,83 +4539,86 @@ func (x codecSelfer1234) decSliceRole(v *[]Role, d *codec1978.Decoder) { z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv368 := *v - yyh368, yyl368 := z.DecSliceHelperStart() - var yyc368 bool - if yyl368 == 0 { - if yyv368 == nil { - yyv368 = []Role{} - yyc368 = true - } else if len(yyv368) != 0 { - yyv368 = yyv368[:0] - yyc368 = true - } - } else if yyl368 > 0 { - var yyrr368, yyrl368 int - var yyrt368 bool - if yyl368 > cap(yyv368) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Role{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg368 := len(yyv368) > 0 - yyv2368 := yyv368 - yyrl368, yyrt368 = z.DecInferLen(yyl368, z.DecBasicHandle().MaxInitLen, 280) - if yyrt368 { - if yyrl368 <= cap(yyv368) { - yyv368 = yyv368[:yyrl368] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv368 = make([]Role, yyrl368) + yyv1 = make([]Role, yyrl1) } } else { - yyv368 = make([]Role, yyrl368) + yyv1 = make([]Role, yyrl1) } - yyc368 = true - yyrr368 = len(yyv368) - if yyrg368 { - copy(yyv368, yyv2368) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl368 != len(yyv368) { - yyv368 = yyv368[:yyl368] - yyc368 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj368 := 0 - for ; yyj368 < yyrr368; yyj368++ { - yyh368.ElemContainerState(yyj368) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv368[yyj368] = Role{} + yyv1[yyj1] = Role{} } else { - yyv369 := &yyv368[yyj368] - yyv369.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt368 { - for ; yyj368 < yyl368; yyj368++ { - yyv368 = append(yyv368, Role{}) - yyh368.ElemContainerState(yyj368) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Role{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv368[yyj368] = Role{} + yyv1[yyj1] = Role{} } else { - yyv370 := &yyv368[yyj368] - yyv370.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj368 := 0 - for ; !r.CheckBreak(); yyj368++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj368 >= len(yyv368) { - yyv368 = append(yyv368, Role{}) // var yyz368 Role - yyc368 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Role{}) // var yyz1 Role + yyc1 = true } - yyh368.ElemContainerState(yyj368) - if yyj368 < len(yyv368) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv368[yyj368] = Role{} + yyv1[yyj1] = Role{} } else { - yyv371 := &yyv368[yyj368] - yyv371.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4320,17 +4626,17 @@ func (x codecSelfer1234) decSliceRole(v *[]Role, d *codec1978.Decoder) { } } - if yyj368 < len(yyv368) { - yyv368 = yyv368[:yyj368] - yyc368 = true - } else if yyj368 == 0 && yyv368 == nil { - yyv368 = []Role{} - yyc368 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Role{} + yyc1 = true } } - yyh368.End() - if yyc368 { - *v = yyv368 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -4339,10 +4645,10 @@ func (x codecSelfer1234) encSliceClusterRoleBinding(v []ClusterRoleBinding, e *c z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv372 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy373 := &yyv372 - yy373.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4352,83 +4658,86 @@ func (x codecSelfer1234) decSliceClusterRoleBinding(v *[]ClusterRoleBinding, d * z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv374 := *v - yyh374, yyl374 := z.DecSliceHelperStart() - var yyc374 bool - if yyl374 == 0 { - if yyv374 == nil { - yyv374 = []ClusterRoleBinding{} - yyc374 = true - } else if len(yyv374) != 0 { - yyv374 = yyv374[:0] - yyc374 = true - } - } else if yyl374 > 0 { - var yyrr374, yyrl374 int - var yyrt374 bool - if yyl374 > cap(yyv374) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ClusterRoleBinding{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg374 := len(yyv374) > 0 - yyv2374 := yyv374 - yyrl374, yyrt374 = z.DecInferLen(yyl374, z.DecBasicHandle().MaxInitLen, 328) - if yyrt374 { - if yyrl374 <= cap(yyv374) { - yyv374 = yyv374[:yyrl374] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 336) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv374 = make([]ClusterRoleBinding, yyrl374) + yyv1 = make([]ClusterRoleBinding, yyrl1) } } else { - yyv374 = make([]ClusterRoleBinding, yyrl374) + yyv1 = make([]ClusterRoleBinding, yyrl1) } - yyc374 = true - yyrr374 = len(yyv374) - if yyrg374 { - copy(yyv374, yyv2374) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl374 != len(yyv374) { - yyv374 = yyv374[:yyl374] - yyc374 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj374 := 0 - for ; yyj374 < yyrr374; yyj374++ { - yyh374.ElemContainerState(yyj374) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv374[yyj374] = ClusterRoleBinding{} + yyv1[yyj1] = ClusterRoleBinding{} } else { - yyv375 := &yyv374[yyj374] - yyv375.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt374 { - for ; yyj374 < yyl374; yyj374++ { - yyv374 = append(yyv374, ClusterRoleBinding{}) - yyh374.ElemContainerState(yyj374) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ClusterRoleBinding{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv374[yyj374] = ClusterRoleBinding{} + yyv1[yyj1] = ClusterRoleBinding{} } else { - yyv376 := &yyv374[yyj374] - yyv376.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj374 := 0 - for ; !r.CheckBreak(); yyj374++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj374 >= len(yyv374) { - yyv374 = append(yyv374, ClusterRoleBinding{}) // var yyz374 ClusterRoleBinding - yyc374 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ClusterRoleBinding{}) // var yyz1 ClusterRoleBinding + yyc1 = true } - yyh374.ElemContainerState(yyj374) - if yyj374 < len(yyv374) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv374[yyj374] = ClusterRoleBinding{} + yyv1[yyj1] = ClusterRoleBinding{} } else { - yyv377 := &yyv374[yyj374] - yyv377.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4436,17 +4745,17 @@ func (x codecSelfer1234) decSliceClusterRoleBinding(v *[]ClusterRoleBinding, d * } } - if yyj374 < len(yyv374) { - yyv374 = yyv374[:yyj374] - yyc374 = true - } else if yyj374 == 0 && yyv374 == nil { - yyv374 = []ClusterRoleBinding{} - yyc374 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ClusterRoleBinding{} + yyc1 = true } } - yyh374.End() - if yyc374 { - *v = yyv374 + yyh1.End() + if yyc1 { + *v = yyv1 } } @@ -4455,10 +4764,10 @@ func (x codecSelfer1234) encSliceClusterRole(v []ClusterRole, e *codec1978.Encod z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv378 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy379 := &yyv378 - yy379.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -4468,83 +4777,86 @@ func (x codecSelfer1234) decSliceClusterRole(v *[]ClusterRole, d *codec1978.Deco z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv380 := *v - yyh380, yyl380 := z.DecSliceHelperStart() - var yyc380 bool - if yyl380 == 0 { - if yyv380 == nil { - yyv380 = []ClusterRole{} - yyc380 = true - } else if len(yyv380) != 0 { - yyv380 = yyv380[:0] - yyc380 = true - } - } else if yyl380 > 0 { - var yyrr380, yyrl380 int - var yyrt380 bool - if yyl380 > cap(yyv380) { + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ClusterRole{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg380 := len(yyv380) > 0 - yyv2380 := yyv380 - yyrl380, yyrt380 = z.DecInferLen(yyl380, z.DecBasicHandle().MaxInitLen, 280) - if yyrt380 { - if yyrl380 <= cap(yyv380) { - yyv380 = yyv380[:yyrl380] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv380 = make([]ClusterRole, yyrl380) + yyv1 = make([]ClusterRole, yyrl1) } } else { - yyv380 = make([]ClusterRole, yyrl380) + yyv1 = make([]ClusterRole, yyrl1) } - yyc380 = true - yyrr380 = len(yyv380) - if yyrg380 { - copy(yyv380, yyv2380) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl380 != len(yyv380) { - yyv380 = yyv380[:yyl380] - yyc380 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj380 := 0 - for ; yyj380 < yyrr380; yyj380++ { - yyh380.ElemContainerState(yyj380) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv380[yyj380] = ClusterRole{} + yyv1[yyj1] = ClusterRole{} } else { - yyv381 := &yyv380[yyj380] - yyv381.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt380 { - for ; yyj380 < yyl380; yyj380++ { - yyv380 = append(yyv380, ClusterRole{}) - yyh380.ElemContainerState(yyj380) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ClusterRole{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv380[yyj380] = ClusterRole{} + yyv1[yyj1] = ClusterRole{} } else { - yyv382 := &yyv380[yyj380] - yyv382.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj380 := 0 - for ; !r.CheckBreak(); yyj380++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj380 >= len(yyv380) { - yyv380 = append(yyv380, ClusterRole{}) // var yyz380 ClusterRole - yyc380 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ClusterRole{}) // var yyz1 ClusterRole + yyc1 = true } - yyh380.ElemContainerState(yyj380) - if yyj380 < len(yyv380) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv380[yyj380] = ClusterRole{} + yyv1[yyj1] = ClusterRole{} } else { - yyv383 := &yyv380[yyj380] - yyv383.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -4552,16 +4864,16 @@ func (x codecSelfer1234) decSliceClusterRole(v *[]ClusterRole, d *codec1978.Deco } } - if yyj380 < len(yyv380) { - yyv380 = yyv380[:yyj380] - yyc380 = true - } else if yyj380 == 0 && yyv380 == nil { - yyv380 = []ClusterRole{} - yyc380 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ClusterRole{} + yyc1 = true } } - yyh380.End() - if yyc380 { - *v = yyv380 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.go index a8b8b22949..e9f8efb3b4 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types.go @@ -17,9 +17,26 @@ limitations under the License. package v1alpha1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// Authorization is calculated against +// 1. evaluation of ClusterRoleBindings - short circuit on match +// 2. evaluation of RoleBindings in the namespace requested - short circuit on match +// 3. deny by default + +const ( + APIGroupAll = "*" + ResourceAll = "*" + VerbAll = "*" + NonResourceAll = "*" + + GroupKind = "Group" + ServiceAccountKind = "ServiceAccount" + UserKind = "User" + + // AutoUpdateAnnotationKey is the name of an annotation which prevents reconciliation if set to "false" + AutoUpdateAnnotationKey = "rbac.authorization.kubernetes.io/autoupdate" ) // Authorization is calculated against @@ -32,10 +49,6 @@ import ( type PolicyRule struct { // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. Verbs []string `json:"verbs" protobuf:"bytes,1,rep,name=verbs"` - // AttributeRestrictions will vary depending on what the Authorizer/AuthorizationAttributeBuilder pair supports. - // If the Authorizer does not recognize how to handle the AttributeRestrictions, the Authorizer should report an error. - // +optional - AttributeRestrictions runtime.RawExtension `json:"attributeRestrictions,omitempty" protobuf:"bytes,2,opt,name=attributeRestrictions"` // APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of // the enumerated resources in any API group will be allowed. @@ -62,7 +75,10 @@ type Subject struct { // Kind of object being referenced. Values defined by this API group are "User", "Group", and "ServiceAccount". // If the Authorizer does not recognized the kind value, the Authorizer should report an error. Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` - // APIVersion holds the API group and version of the referenced object. + // APIVersion holds the API group and version of the referenced subject. + // Defaults to "v1" for ServiceAccount subjects. + // Defaults to "rbac.authorization.k8s.io/v1alpha1" for User and Group subjects. + // +k8s:conversion-gen=false // +optional APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,2,opt.name=apiVersion"` // Name of the object being referenced. @@ -87,10 +103,10 @@ type RoleRef struct { // Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. type Role struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Rules holds all the PolicyRules for this Role Rules []PolicyRule `json:"rules" protobuf:"bytes,2,rep,name=rules"` @@ -102,10 +118,10 @@ type Role struct { // It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given // namespace only have effect in that namespace. type RoleBinding struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Subjects holds references to the objects the role applies to. Subjects []Subject `json:"subjects" protobuf:"bytes,2,rep,name=subjects"` @@ -117,10 +133,10 @@ type RoleBinding struct { // RoleBindingList is a collection of RoleBindings type RoleBindingList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of RoleBindings Items []RoleBinding `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -128,10 +144,10 @@ type RoleBindingList struct { // RoleList is a collection of Roles type RoleList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of Roles Items []Role `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -142,10 +158,10 @@ type RoleList struct { // ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. type ClusterRole struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Rules holds all the PolicyRules for this ClusterRole Rules []PolicyRule `json:"rules" protobuf:"bytes,2,rep,name=rules"` @@ -157,10 +173,10 @@ type ClusterRole struct { // ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, // and adds who information via Subject. type ClusterRoleBinding struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Subjects holds references to the objects the role applies to. Subjects []Subject `json:"subjects" protobuf:"bytes,2,rep,name=subjects"` @@ -172,10 +188,10 @@ type ClusterRoleBinding struct { // ClusterRoleBindingList is a collection of ClusterRoleBindings type ClusterRoleBindingList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of ClusterRoleBindings Items []ClusterRoleBinding `json:"items" protobuf:"bytes,2,rep,name=items"` @@ -183,10 +199,10 @@ type ClusterRoleBindingList struct { // ClusterRoleList is a collection of ClusterRoles type ClusterRoleList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is a list of ClusterRoles Items []ClusterRole `json:"items" protobuf:"bytes,2,rep,name=items"` diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types_swagger_doc_generated.go index 633bae9799..d58a722af1 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/types_swagger_doc_generated.go @@ -69,13 +69,12 @@ func (ClusterRoleList) SwaggerDoc() map[string]string { } var map_PolicyRule = map[string]string{ - "": "PolicyRule holds information that describes a policy rule, but does not contain information about who the rule applies to or which namespace the rule applies to.", - "verbs": "Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds.", - "attributeRestrictions": "AttributeRestrictions will vary depending on what the Authorizer/AuthorizationAttributeBuilder pair supports. If the Authorizer does not recognize how to handle the AttributeRestrictions, the Authorizer should report an error.", - "apiGroups": "APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of the enumerated resources in any API group will be allowed.", - "resources": "Resources is a list of resources this rule applies to. ResourceAll represents all resources.", - "resourceNames": "ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed.", - "nonResourceURLs": "NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path This name is intentionally different than the internal type so that the DefaultConvert works nicely and because the ordering may be different. Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. Rules can either apply to API resources (such as \"pods\" or \"secrets\") or non-resource URL paths (such as \"/api\"), but not both.", + "": "PolicyRule holds information that describes a policy rule, but does not contain information about who the rule applies to or which namespace the rule applies to.", + "verbs": "Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds.", + "apiGroups": "APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of the enumerated resources in any API group will be allowed.", + "resources": "Resources is a list of resources this rule applies to. ResourceAll represents all resources.", + "resourceNames": "ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed.", + "nonResourceURLs": "NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path This name is intentionally different than the internal type so that the DefaultConvert works nicely and because the ordering may be different. Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. Rules can either apply to API resources (such as \"pods\" or \"secrets\") or non-resource URL paths (such as \"/api\"), but not both.", } func (PolicyRule) SwaggerDoc() map[string]string { @@ -137,7 +136,7 @@ func (RoleRef) SwaggerDoc() map[string]string { var map_Subject = map[string]string{ "": "Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names.", "kind": "Kind of object being referenced. Values defined by this API group are \"User\", \"Group\", and \"ServiceAccount\". If the Authorizer does not recognized the kind value, the Authorizer should report an error.", - "apiVersion": "APIVersion holds the API group and version of the referenced object.", + "apiVersion": "APIVersion holds the API group and version of the referenced subject. Defaults to \"v1\" for ServiceAccount subjects. Defaults to \"rbac.authorization.k8s.io/v1alpha1\" for User and Group subjects.", "name": "Name of the object being referenced.", "namespace": "Namespace of the referenced object. If the object kind is non-namespace, such as \"User\" or \"Group\", and this value is not empty the Authorizer should report an error.", } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.conversion.go index 1181cf7fff..a3315156fd 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1alpha1 import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" rbac "k8s.io/client-go/pkg/apis/rbac" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -39,12 +39,16 @@ func RegisterConversions(scheme *runtime.Scheme) error { Convert_rbac_ClusterRole_To_v1alpha1_ClusterRole, Convert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding, Convert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding, + Convert_v1alpha1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder, + Convert_rbac_ClusterRoleBindingBuilder_To_v1alpha1_ClusterRoleBindingBuilder, Convert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList, Convert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList, Convert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList, Convert_rbac_ClusterRoleList_To_v1alpha1_ClusterRoleList, Convert_v1alpha1_PolicyRule_To_rbac_PolicyRule, Convert_rbac_PolicyRule_To_v1alpha1_PolicyRule, + Convert_v1alpha1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder, + Convert_rbac_PolicyRuleBuilder_To_v1alpha1_PolicyRuleBuilder, Convert_v1alpha1_Role_To_rbac_Role, Convert_rbac_Role_To_v1alpha1_Role, Convert_v1alpha1_RoleBinding_To_rbac_RoleBinding, @@ -61,110 +65,110 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v1alpha1_ClusterRole_To_rbac_ClusterRole(in *ClusterRole, out *rbac.ClusterRole, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if in.Rules != nil { - in, out := &in.Rules, &out.Rules - *out = make([]rbac.PolicyRule, len(*in)) - for i := range *in { - if err := Convert_v1alpha1_PolicyRule_To_rbac_PolicyRule(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Rules = nil - } + out.ObjectMeta = in.ObjectMeta + out.Rules = *(*[]rbac.PolicyRule)(unsafe.Pointer(&in.Rules)) return nil } +// Convert_v1alpha1_ClusterRole_To_rbac_ClusterRole is an autogenerated conversion function. func Convert_v1alpha1_ClusterRole_To_rbac_ClusterRole(in *ClusterRole, out *rbac.ClusterRole, s conversion.Scope) error { return autoConvert_v1alpha1_ClusterRole_To_rbac_ClusterRole(in, out, s) } func autoConvert_rbac_ClusterRole_To_v1alpha1_ClusterRole(in *rbac.ClusterRole, out *ClusterRole, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if in.Rules != nil { - in, out := &in.Rules, &out.Rules - *out = make([]PolicyRule, len(*in)) - for i := range *in { - if err := Convert_rbac_PolicyRule_To_v1alpha1_PolicyRule(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } + out.ObjectMeta = in.ObjectMeta + if in.Rules == nil { + out.Rules = make([]PolicyRule, 0) } else { - out.Rules = nil + out.Rules = *(*[]PolicyRule)(unsafe.Pointer(&in.Rules)) } return nil } +// Convert_rbac_ClusterRole_To_v1alpha1_ClusterRole is an autogenerated conversion function. func Convert_rbac_ClusterRole_To_v1alpha1_ClusterRole(in *rbac.ClusterRole, out *ClusterRole, s conversion.Scope) error { return autoConvert_rbac_ClusterRole_To_v1alpha1_ClusterRole(in, out, s) } func autoConvert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(in *ClusterRoleBinding, out *rbac.ClusterRoleBinding, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err + out.ObjectMeta = in.ObjectMeta + if in.Subjects != nil { + in, out := &in.Subjects, &out.Subjects + *out = make([]rbac.Subject, len(*in)) + for i := range *in { + if err := Convert_v1alpha1_Subject_To_rbac_Subject(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Subjects = nil } - out.Subjects = *(*[]rbac.Subject)(unsafe.Pointer(&in.Subjects)) if err := Convert_v1alpha1_RoleRef_To_rbac_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { return err } return nil } +// Convert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding is an autogenerated conversion function. func Convert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(in *ClusterRoleBinding, out *rbac.ClusterRoleBinding, s conversion.Scope) error { return autoConvert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(in, out, s) } func autoConvert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding(in *rbac.ClusterRoleBinding, out *ClusterRoleBinding, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err + out.ObjectMeta = in.ObjectMeta + if in.Subjects != nil { + in, out := &in.Subjects, &out.Subjects + *out = make([]Subject, len(*in)) + for i := range *in { + if err := Convert_rbac_Subject_To_v1alpha1_Subject(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Subjects = make([]Subject, 0) } - out.Subjects = *(*[]Subject)(unsafe.Pointer(&in.Subjects)) if err := Convert_rbac_RoleRef_To_v1alpha1_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { return err } return nil } +// Convert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding is an autogenerated conversion function. func Convert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding(in *rbac.ClusterRoleBinding, out *ClusterRoleBinding, s conversion.Scope) error { return autoConvert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding(in, out, s) } -func autoConvert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in *ClusterRoleBindingList, out *rbac.ClusterRoleBindingList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - out.Items = *(*[]rbac.ClusterRoleBinding)(unsafe.Pointer(&in.Items)) +func autoConvert_v1alpha1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder(in *ClusterRoleBindingBuilder, out *rbac.ClusterRoleBindingBuilder, s conversion.Scope) error { + if err := Convert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(&in.ClusterRoleBinding, &out.ClusterRoleBinding, s); err != nil { + return err + } return nil } -func Convert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in *ClusterRoleBindingList, out *rbac.ClusterRoleBindingList, s conversion.Scope) error { - return autoConvert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in, out, s) +// Convert_v1alpha1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder is an autogenerated conversion function. +func Convert_v1alpha1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder(in *ClusterRoleBindingBuilder, out *rbac.ClusterRoleBindingBuilder, s conversion.Scope) error { + return autoConvert_v1alpha1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder(in, out, s) } -func autoConvert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList(in *rbac.ClusterRoleBindingList, out *ClusterRoleBindingList, s conversion.Scope) error { - out.ListMeta = in.ListMeta - out.Items = *(*[]ClusterRoleBinding)(unsafe.Pointer(&in.Items)) +func autoConvert_rbac_ClusterRoleBindingBuilder_To_v1alpha1_ClusterRoleBindingBuilder(in *rbac.ClusterRoleBindingBuilder, out *ClusterRoleBindingBuilder, s conversion.Scope) error { + if err := Convert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding(&in.ClusterRoleBinding, &out.ClusterRoleBinding, s); err != nil { + return err + } return nil } -func Convert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList(in *rbac.ClusterRoleBindingList, out *ClusterRoleBindingList, s conversion.Scope) error { - return autoConvert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList(in, out, s) +// Convert_rbac_ClusterRoleBindingBuilder_To_v1alpha1_ClusterRoleBindingBuilder is an autogenerated conversion function. +func Convert_rbac_ClusterRoleBindingBuilder_To_v1alpha1_ClusterRoleBindingBuilder(in *rbac.ClusterRoleBindingBuilder, out *ClusterRoleBindingBuilder, s conversion.Scope) error { + return autoConvert_rbac_ClusterRoleBindingBuilder_To_v1alpha1_ClusterRoleBindingBuilder(in, out, s) } -func autoConvert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRoleList, out *rbac.ClusterRoleList, s conversion.Scope) error { +func autoConvert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in *ClusterRoleBindingList, out *rbac.ClusterRoleBindingList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]rbac.ClusterRole, len(*in)) + *out = make([]rbac.ClusterRoleBinding, len(*in)) for i := range *in { - if err := Convert_v1alpha1_ClusterRole_To_rbac_ClusterRole(&(*in)[i], &(*out)[i], s); err != nil { + if err := Convert_v1alpha1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(&(*in)[i], &(*out)[i], s); err != nil { return err } } @@ -174,35 +178,60 @@ func autoConvert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRol return nil } -func Convert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRoleList, out *rbac.ClusterRoleList, s conversion.Scope) error { - return autoConvert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in, out, s) +// Convert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList is an autogenerated conversion function. +func Convert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in *ClusterRoleBindingList, out *rbac.ClusterRoleBindingList, s conversion.Scope) error { + return autoConvert_v1alpha1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in, out, s) } -func autoConvert_rbac_ClusterRoleList_To_v1alpha1_ClusterRoleList(in *rbac.ClusterRoleList, out *ClusterRoleList, s conversion.Scope) error { +func autoConvert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList(in *rbac.ClusterRoleBindingList, out *ClusterRoleBindingList, s conversion.Scope) error { out.ListMeta = in.ListMeta if in.Items != nil { in, out := &in.Items, &out.Items - *out = make([]ClusterRole, len(*in)) + *out = make([]ClusterRoleBinding, len(*in)) for i := range *in { - if err := Convert_rbac_ClusterRole_To_v1alpha1_ClusterRole(&(*in)[i], &(*out)[i], s); err != nil { + if err := Convert_rbac_ClusterRoleBinding_To_v1alpha1_ClusterRoleBinding(&(*in)[i], &(*out)[i], s); err != nil { return err } } } else { - out.Items = nil + out.Items = make([]ClusterRoleBinding, 0) + } + return nil +} + +// Convert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList is an autogenerated conversion function. +func Convert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList(in *rbac.ClusterRoleBindingList, out *ClusterRoleBindingList, s conversion.Scope) error { + return autoConvert_rbac_ClusterRoleBindingList_To_v1alpha1_ClusterRoleBindingList(in, out, s) +} + +func autoConvert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRoleList, out *rbac.ClusterRoleList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]rbac.ClusterRole)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList is an autogenerated conversion function. +func Convert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRoleList, out *rbac.ClusterRoleList, s conversion.Scope) error { + return autoConvert_v1alpha1_ClusterRoleList_To_rbac_ClusterRoleList(in, out, s) +} + +func autoConvert_rbac_ClusterRoleList_To_v1alpha1_ClusterRoleList(in *rbac.ClusterRoleList, out *ClusterRoleList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]ClusterRole, 0) + } else { + out.Items = *(*[]ClusterRole)(unsafe.Pointer(&in.Items)) } return nil } +// Convert_rbac_ClusterRoleList_To_v1alpha1_ClusterRoleList is an autogenerated conversion function. func Convert_rbac_ClusterRoleList_To_v1alpha1_ClusterRoleList(in *rbac.ClusterRoleList, out *ClusterRoleList, s conversion.Scope) error { return autoConvert_rbac_ClusterRoleList_To_v1alpha1_ClusterRoleList(in, out, s) } func autoConvert_v1alpha1_PolicyRule_To_rbac_PolicyRule(in *PolicyRule, out *rbac.PolicyRule, s conversion.Scope) error { out.Verbs = *(*[]string)(unsafe.Pointer(&in.Verbs)) - if err := runtime.Convert_runtime_RawExtension_To_runtime_Object(&in.AttributeRestrictions, &out.AttributeRestrictions, s); err != nil { - return err - } out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) out.ResourceNames = *(*[]string)(unsafe.Pointer(&in.ResourceNames)) @@ -210,14 +239,16 @@ func autoConvert_v1alpha1_PolicyRule_To_rbac_PolicyRule(in *PolicyRule, out *rba return nil } +// Convert_v1alpha1_PolicyRule_To_rbac_PolicyRule is an autogenerated conversion function. func Convert_v1alpha1_PolicyRule_To_rbac_PolicyRule(in *PolicyRule, out *rbac.PolicyRule, s conversion.Scope) error { return autoConvert_v1alpha1_PolicyRule_To_rbac_PolicyRule(in, out, s) } func autoConvert_rbac_PolicyRule_To_v1alpha1_PolicyRule(in *rbac.PolicyRule, out *PolicyRule, s conversion.Scope) error { - out.Verbs = *(*[]string)(unsafe.Pointer(&in.Verbs)) - if err := runtime.Convert_runtime_Object_To_runtime_RawExtension(&in.AttributeRestrictions, &out.AttributeRestrictions, s); err != nil { - return err + if in.Verbs == nil { + out.Verbs = make([]string, 0) + } else { + out.Verbs = *(*[]string)(unsafe.Pointer(&in.Verbs)) } out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) @@ -226,144 +257,173 @@ func autoConvert_rbac_PolicyRule_To_v1alpha1_PolicyRule(in *rbac.PolicyRule, out return nil } +// Convert_rbac_PolicyRule_To_v1alpha1_PolicyRule is an autogenerated conversion function. func Convert_rbac_PolicyRule_To_v1alpha1_PolicyRule(in *rbac.PolicyRule, out *PolicyRule, s conversion.Scope) error { return autoConvert_rbac_PolicyRule_To_v1alpha1_PolicyRule(in, out, s) } -func autoConvert_v1alpha1_Role_To_rbac_Role(in *Role, out *rbac.Role, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { +func autoConvert_v1alpha1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder(in *PolicyRuleBuilder, out *rbac.PolicyRuleBuilder, s conversion.Scope) error { + if err := Convert_v1alpha1_PolicyRule_To_rbac_PolicyRule(&in.PolicyRule, &out.PolicyRule, s); err != nil { return err } - if in.Rules != nil { - in, out := &in.Rules, &out.Rules - *out = make([]rbac.PolicyRule, len(*in)) - for i := range *in { - if err := Convert_v1alpha1_PolicyRule_To_rbac_PolicyRule(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Rules = nil + return nil +} + +// Convert_v1alpha1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder is an autogenerated conversion function. +func Convert_v1alpha1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder(in *PolicyRuleBuilder, out *rbac.PolicyRuleBuilder, s conversion.Scope) error { + return autoConvert_v1alpha1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder(in, out, s) +} + +func autoConvert_rbac_PolicyRuleBuilder_To_v1alpha1_PolicyRuleBuilder(in *rbac.PolicyRuleBuilder, out *PolicyRuleBuilder, s conversion.Scope) error { + if err := Convert_rbac_PolicyRule_To_v1alpha1_PolicyRule(&in.PolicyRule, &out.PolicyRule, s); err != nil { + return err } return nil } +// Convert_rbac_PolicyRuleBuilder_To_v1alpha1_PolicyRuleBuilder is an autogenerated conversion function. +func Convert_rbac_PolicyRuleBuilder_To_v1alpha1_PolicyRuleBuilder(in *rbac.PolicyRuleBuilder, out *PolicyRuleBuilder, s conversion.Scope) error { + return autoConvert_rbac_PolicyRuleBuilder_To_v1alpha1_PolicyRuleBuilder(in, out, s) +} + +func autoConvert_v1alpha1_Role_To_rbac_Role(in *Role, out *rbac.Role, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Rules = *(*[]rbac.PolicyRule)(unsafe.Pointer(&in.Rules)) + return nil +} + +// Convert_v1alpha1_Role_To_rbac_Role is an autogenerated conversion function. func Convert_v1alpha1_Role_To_rbac_Role(in *Role, out *rbac.Role, s conversion.Scope) error { return autoConvert_v1alpha1_Role_To_rbac_Role(in, out, s) } func autoConvert_rbac_Role_To_v1alpha1_Role(in *rbac.Role, out *Role, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } - if in.Rules != nil { - in, out := &in.Rules, &out.Rules - *out = make([]PolicyRule, len(*in)) - for i := range *in { - if err := Convert_rbac_PolicyRule_To_v1alpha1_PolicyRule(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } + out.ObjectMeta = in.ObjectMeta + if in.Rules == nil { + out.Rules = make([]PolicyRule, 0) } else { - out.Rules = nil + out.Rules = *(*[]PolicyRule)(unsafe.Pointer(&in.Rules)) } return nil } +// Convert_rbac_Role_To_v1alpha1_Role is an autogenerated conversion function. func Convert_rbac_Role_To_v1alpha1_Role(in *rbac.Role, out *Role, s conversion.Scope) error { return autoConvert_rbac_Role_To_v1alpha1_Role(in, out, s) } func autoConvert_v1alpha1_RoleBinding_To_rbac_RoleBinding(in *RoleBinding, out *rbac.RoleBinding, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err + out.ObjectMeta = in.ObjectMeta + if in.Subjects != nil { + in, out := &in.Subjects, &out.Subjects + *out = make([]rbac.Subject, len(*in)) + for i := range *in { + if err := Convert_v1alpha1_Subject_To_rbac_Subject(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Subjects = nil } - out.Subjects = *(*[]rbac.Subject)(unsafe.Pointer(&in.Subjects)) if err := Convert_v1alpha1_RoleRef_To_rbac_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { return err } return nil } +// Convert_v1alpha1_RoleBinding_To_rbac_RoleBinding is an autogenerated conversion function. func Convert_v1alpha1_RoleBinding_To_rbac_RoleBinding(in *RoleBinding, out *rbac.RoleBinding, s conversion.Scope) error { return autoConvert_v1alpha1_RoleBinding_To_rbac_RoleBinding(in, out, s) } func autoConvert_rbac_RoleBinding_To_v1alpha1_RoleBinding(in *rbac.RoleBinding, out *RoleBinding, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err + out.ObjectMeta = in.ObjectMeta + if in.Subjects != nil { + in, out := &in.Subjects, &out.Subjects + *out = make([]Subject, len(*in)) + for i := range *in { + if err := Convert_rbac_Subject_To_v1alpha1_Subject(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Subjects = make([]Subject, 0) } - out.Subjects = *(*[]Subject)(unsafe.Pointer(&in.Subjects)) if err := Convert_rbac_RoleRef_To_v1alpha1_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { return err } return nil } +// Convert_rbac_RoleBinding_To_v1alpha1_RoleBinding is an autogenerated conversion function. func Convert_rbac_RoleBinding_To_v1alpha1_RoleBinding(in *rbac.RoleBinding, out *RoleBinding, s conversion.Scope) error { return autoConvert_rbac_RoleBinding_To_v1alpha1_RoleBinding(in, out, s) } func autoConvert_v1alpha1_RoleBindingList_To_rbac_RoleBindingList(in *RoleBindingList, out *rbac.RoleBindingList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]rbac.RoleBinding)(unsafe.Pointer(&in.Items)) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]rbac.RoleBinding, len(*in)) + for i := range *in { + if err := Convert_v1alpha1_RoleBinding_To_rbac_RoleBinding(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } return nil } +// Convert_v1alpha1_RoleBindingList_To_rbac_RoleBindingList is an autogenerated conversion function. func Convert_v1alpha1_RoleBindingList_To_rbac_RoleBindingList(in *RoleBindingList, out *rbac.RoleBindingList, s conversion.Scope) error { return autoConvert_v1alpha1_RoleBindingList_To_rbac_RoleBindingList(in, out, s) } func autoConvert_rbac_RoleBindingList_To_v1alpha1_RoleBindingList(in *rbac.RoleBindingList, out *RoleBindingList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]RoleBinding)(unsafe.Pointer(&in.Items)) + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]RoleBinding, len(*in)) + for i := range *in { + if err := Convert_rbac_RoleBinding_To_v1alpha1_RoleBinding(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = make([]RoleBinding, 0) + } return nil } +// Convert_rbac_RoleBindingList_To_v1alpha1_RoleBindingList is an autogenerated conversion function. func Convert_rbac_RoleBindingList_To_v1alpha1_RoleBindingList(in *rbac.RoleBindingList, out *RoleBindingList, s conversion.Scope) error { return autoConvert_rbac_RoleBindingList_To_v1alpha1_RoleBindingList(in, out, s) } func autoConvert_v1alpha1_RoleList_To_rbac_RoleList(in *RoleList, out *rbac.RoleList, s conversion.Scope) error { out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]rbac.Role, len(*in)) - for i := range *in { - if err := Convert_v1alpha1_Role_To_rbac_Role(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } - } else { - out.Items = nil - } + out.Items = *(*[]rbac.Role)(unsafe.Pointer(&in.Items)) return nil } +// Convert_v1alpha1_RoleList_To_rbac_RoleList is an autogenerated conversion function. func Convert_v1alpha1_RoleList_To_rbac_RoleList(in *RoleList, out *rbac.RoleList, s conversion.Scope) error { return autoConvert_v1alpha1_RoleList_To_rbac_RoleList(in, out, s) } func autoConvert_rbac_RoleList_To_v1alpha1_RoleList(in *rbac.RoleList, out *RoleList, s conversion.Scope) error { out.ListMeta = in.ListMeta - if in.Items != nil { - in, out := &in.Items, &out.Items - *out = make([]Role, len(*in)) - for i := range *in { - if err := Convert_rbac_Role_To_v1alpha1_Role(&(*in)[i], &(*out)[i], s); err != nil { - return err - } - } + if in.Items == nil { + out.Items = make([]Role, 0) } else { - out.Items = nil + out.Items = *(*[]Role)(unsafe.Pointer(&in.Items)) } return nil } +// Convert_rbac_RoleList_To_v1alpha1_RoleList is an autogenerated conversion function. func Convert_rbac_RoleList_To_v1alpha1_RoleList(in *rbac.RoleList, out *RoleList, s conversion.Scope) error { return autoConvert_rbac_RoleList_To_v1alpha1_RoleList(in, out, s) } @@ -375,6 +435,7 @@ func autoConvert_v1alpha1_RoleRef_To_rbac_RoleRef(in *RoleRef, out *rbac.RoleRef return nil } +// Convert_v1alpha1_RoleRef_To_rbac_RoleRef is an autogenerated conversion function. func Convert_v1alpha1_RoleRef_To_rbac_RoleRef(in *RoleRef, out *rbac.RoleRef, s conversion.Scope) error { return autoConvert_v1alpha1_RoleRef_To_rbac_RoleRef(in, out, s) } @@ -386,30 +447,23 @@ func autoConvert_rbac_RoleRef_To_v1alpha1_RoleRef(in *rbac.RoleRef, out *RoleRef return nil } +// Convert_rbac_RoleRef_To_v1alpha1_RoleRef is an autogenerated conversion function. func Convert_rbac_RoleRef_To_v1alpha1_RoleRef(in *rbac.RoleRef, out *RoleRef, s conversion.Scope) error { return autoConvert_rbac_RoleRef_To_v1alpha1_RoleRef(in, out, s) } func autoConvert_v1alpha1_Subject_To_rbac_Subject(in *Subject, out *rbac.Subject, s conversion.Scope) error { out.Kind = in.Kind - out.APIVersion = in.APIVersion + // INFO: in.APIVersion opted out of conversion generation out.Name = in.Name out.Namespace = in.Namespace return nil } -func Convert_v1alpha1_Subject_To_rbac_Subject(in *Subject, out *rbac.Subject, s conversion.Scope) error { - return autoConvert_v1alpha1_Subject_To_rbac_Subject(in, out, s) -} - func autoConvert_rbac_Subject_To_v1alpha1_Subject(in *rbac.Subject, out *Subject, s conversion.Scope) error { out.Kind = in.Kind - out.APIVersion = in.APIVersion + // WARNING: in.APIGroup requires manual conversion: does not exist in peer-type out.Name = in.Name out.Namespace = in.Namespace return nil } - -func Convert_rbac_Subject_To_v1alpha1_Subject(in *rbac.Subject, out *Subject, s conversion.Scope) error { - return autoConvert_rbac_Subject_To_v1alpha1_Subject(in, out, s) -} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.deepcopy.go index 0631bb7cc2..21b4b8dc47 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1alpha1 import ( - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -49,13 +49,16 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1alpha1_ClusterRole is an autogenerated deepcopy function. func DeepCopy_v1alpha1_ClusterRole(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRole) out := out.(*ClusterRole) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Rules != nil { in, out := &in.Rules, &out.Rules @@ -65,41 +68,37 @@ func DeepCopy_v1alpha1_ClusterRole(in interface{}, out interface{}, c *conversio return err } } - } else { - out.Rules = nil } return nil } } +// DeepCopy_v1alpha1_ClusterRoleBinding is an autogenerated deepcopy function. func DeepCopy_v1alpha1_ClusterRoleBinding(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRoleBinding) out := out.(*ClusterRoleBinding) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Subjects != nil { in, out := &in.Subjects, &out.Subjects *out = make([]Subject, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Subjects = nil + copy(*out, *in) } - out.RoleRef = in.RoleRef return nil } } +// DeepCopy_v1alpha1_ClusterRoleBindingList is an autogenerated deepcopy function. func DeepCopy_v1alpha1_ClusterRoleBindingList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRoleBindingList) out := out.(*ClusterRoleBindingList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ClusterRoleBinding, len(*in)) @@ -108,19 +107,17 @@ func DeepCopy_v1alpha1_ClusterRoleBindingList(in interface{}, out interface{}, c return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1alpha1_ClusterRoleList is an autogenerated deepcopy function. func DeepCopy_v1alpha1_ClusterRoleList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRoleList) out := out.(*ClusterRoleList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ClusterRole, len(*in)) @@ -129,66 +126,56 @@ func DeepCopy_v1alpha1_ClusterRoleList(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1alpha1_PolicyRule is an autogenerated deepcopy function. func DeepCopy_v1alpha1_PolicyRule(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PolicyRule) out := out.(*PolicyRule) + *out = *in if in.Verbs != nil { in, out := &in.Verbs, &out.Verbs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Verbs = nil - } - if err := runtime.DeepCopy_runtime_RawExtension(&in.AttributeRestrictions, &out.AttributeRestrictions, c); err != nil { - return err } if in.APIGroups != nil { in, out := &in.APIGroups, &out.APIGroups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.APIGroups = nil } if in.Resources != nil { in, out := &in.Resources, &out.Resources *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Resources = nil } if in.ResourceNames != nil { in, out := &in.ResourceNames, &out.ResourceNames *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.ResourceNames = nil } if in.NonResourceURLs != nil { in, out := &in.NonResourceURLs, &out.NonResourceURLs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.NonResourceURLs = nil } return nil } } +// DeepCopy_v1alpha1_Role is an autogenerated deepcopy function. func DeepCopy_v1alpha1_Role(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Role) out := out.(*Role) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Rules != nil { in, out := &in.Rules, &out.Rules @@ -198,41 +185,37 @@ func DeepCopy_v1alpha1_Role(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Rules = nil } return nil } } +// DeepCopy_v1alpha1_RoleBinding is an autogenerated deepcopy function. func DeepCopy_v1alpha1_RoleBinding(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleBinding) out := out.(*RoleBinding) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Subjects != nil { in, out := &in.Subjects, &out.Subjects *out = make([]Subject, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Subjects = nil + copy(*out, *in) } - out.RoleRef = in.RoleRef return nil } } +// DeepCopy_v1alpha1_RoleBindingList is an autogenerated deepcopy function. func DeepCopy_v1alpha1_RoleBindingList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleBindingList) out := out.(*RoleBindingList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]RoleBinding, len(*in)) @@ -241,19 +224,17 @@ func DeepCopy_v1alpha1_RoleBindingList(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1alpha1_RoleList is an autogenerated deepcopy function. func DeepCopy_v1alpha1_RoleList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleList) out := out.(*RoleList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Role, len(*in)) @@ -262,32 +243,27 @@ func DeepCopy_v1alpha1_RoleList(in interface{}, out interface{}, c *conversion.C return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_v1alpha1_RoleRef is an autogenerated deepcopy function. func DeepCopy_v1alpha1_RoleRef(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleRef) out := out.(*RoleRef) - out.APIGroup = in.APIGroup - out.Kind = in.Kind - out.Name = in.Name + *out = *in return nil } } +// DeepCopy_v1alpha1_Subject is an autogenerated deepcopy function. func DeepCopy_v1alpha1_Subject(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Subject) out := out.(*Subject) - out.Kind = in.Kind - out.APIVersion = in.APIVersion - out.Name = in.Name - out.Namespace = in.Namespace + *out = *in return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.defaults.go index c41b12d2ce..1a5749be30 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.defaults.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1alpha1/zz_generated.defaults.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,7 +21,7 @@ limitations under the License. package v1alpha1 import ( - runtime "k8s.io/client-go/pkg/runtime" + runtime "k8s.io/apimachinery/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. @@ -37,6 +37,10 @@ func RegisterDefaults(scheme *runtime.Scheme) error { func SetObjectDefaults_ClusterRoleBinding(in *ClusterRoleBinding) { SetDefaults_ClusterRoleBinding(in) + for i := range in.Subjects { + a := &in.Subjects[i] + SetDefaults_Subject(a) + } } func SetObjectDefaults_ClusterRoleBindingList(in *ClusterRoleBindingList) { @@ -48,6 +52,10 @@ func SetObjectDefaults_ClusterRoleBindingList(in *ClusterRoleBindingList) { func SetObjectDefaults_RoleBinding(in *RoleBinding) { SetDefaults_RoleBinding(in) + for i := range in.Subjects { + a := &in.Subjects[i] + SetDefaults_Subject(a) + } } func SetObjectDefaults_RoleBindingList(in *RoleBindingList) { diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/BUILD new file mode 100644 index 0000000000..48e4d70efa --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "defaults.go", + "doc.go", + "generated.pb.go", + "helpers.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/rbac:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/defaults.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/defaults.go new file mode 100644 index 0000000000..c1cf8c23c1 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/defaults.go @@ -0,0 +1,48 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + "k8s.io/apimachinery/pkg/runtime" +) + +func addDefaultingFuncs(scheme *runtime.Scheme) error { + return RegisterDefaults(scheme) +} + +func SetDefaults_ClusterRoleBinding(obj *ClusterRoleBinding) { + if len(obj.RoleRef.APIGroup) == 0 { + obj.RoleRef.APIGroup = GroupName + } +} +func SetDefaults_RoleBinding(obj *RoleBinding) { + if len(obj.RoleRef.APIGroup) == 0 { + obj.RoleRef.APIGroup = GroupName + } +} +func SetDefaults_Subject(obj *Subject) { + if len(obj.APIGroup) == 0 { + switch obj.Kind { + case ServiceAccountKind: + obj.APIGroup = "" + case UserKind: + obj.APIGroup = GroupName + case GroupKind: + obj.APIGroup = GroupName + } + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/doc.go new file mode 100644 index 0000000000..a9ad4296ed --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=rbac.authorization.k8s.io +package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go new file mode 100644 index 0000000000..07a719394a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.pb.go @@ -0,0 +1,2821 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/rbac/v1beta1/generated.proto +// DO NOT EDIT! + +/* + Package v1beta1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/rbac/v1beta1/generated.proto + + It has these top-level messages: + ClusterRole + ClusterRoleBinding + ClusterRoleBindingBuilder + ClusterRoleBindingList + ClusterRoleList + PolicyRule + PolicyRuleBuilder + Role + RoleBinding + RoleBindingList + RoleList + RoleRef + Subject +*/ +package v1beta1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *ClusterRole) Reset() { *m = ClusterRole{} } +func (*ClusterRole) ProtoMessage() {} +func (*ClusterRole) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *ClusterRoleBinding) Reset() { *m = ClusterRoleBinding{} } +func (*ClusterRoleBinding) ProtoMessage() {} +func (*ClusterRoleBinding) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *ClusterRoleBindingBuilder) Reset() { *m = ClusterRoleBindingBuilder{} } +func (*ClusterRoleBindingBuilder) ProtoMessage() {} +func (*ClusterRoleBindingBuilder) Descriptor() ([]byte, []int) { + return fileDescriptorGenerated, []int{2} +} + +func (m *ClusterRoleBindingList) Reset() { *m = ClusterRoleBindingList{} } +func (*ClusterRoleBindingList) ProtoMessage() {} +func (*ClusterRoleBindingList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{3} } + +func (m *ClusterRoleList) Reset() { *m = ClusterRoleList{} } +func (*ClusterRoleList) ProtoMessage() {} +func (*ClusterRoleList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{4} } + +func (m *PolicyRule) Reset() { *m = PolicyRule{} } +func (*PolicyRule) ProtoMessage() {} +func (*PolicyRule) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{5} } + +func (m *PolicyRuleBuilder) Reset() { *m = PolicyRuleBuilder{} } +func (*PolicyRuleBuilder) ProtoMessage() {} +func (*PolicyRuleBuilder) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{6} } + +func (m *Role) Reset() { *m = Role{} } +func (*Role) ProtoMessage() {} +func (*Role) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{7} } + +func (m *RoleBinding) Reset() { *m = RoleBinding{} } +func (*RoleBinding) ProtoMessage() {} +func (*RoleBinding) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{8} } + +func (m *RoleBindingList) Reset() { *m = RoleBindingList{} } +func (*RoleBindingList) ProtoMessage() {} +func (*RoleBindingList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{9} } + +func (m *RoleList) Reset() { *m = RoleList{} } +func (*RoleList) ProtoMessage() {} +func (*RoleList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{10} } + +func (m *RoleRef) Reset() { *m = RoleRef{} } +func (*RoleRef) ProtoMessage() {} +func (*RoleRef) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{11} } + +func (m *Subject) Reset() { *m = Subject{} } +func (*Subject) ProtoMessage() {} +func (*Subject) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{12} } + +func init() { + proto.RegisterType((*ClusterRole)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.ClusterRole") + proto.RegisterType((*ClusterRoleBinding)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.ClusterRoleBinding") + proto.RegisterType((*ClusterRoleBindingBuilder)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.ClusterRoleBindingBuilder") + proto.RegisterType((*ClusterRoleBindingList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.ClusterRoleBindingList") + proto.RegisterType((*ClusterRoleList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.ClusterRoleList") + proto.RegisterType((*PolicyRule)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.PolicyRule") + proto.RegisterType((*PolicyRuleBuilder)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.PolicyRuleBuilder") + proto.RegisterType((*Role)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.Role") + proto.RegisterType((*RoleBinding)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.RoleBinding") + proto.RegisterType((*RoleBindingList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.RoleBindingList") + proto.RegisterType((*RoleList)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.RoleList") + proto.RegisterType((*RoleRef)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.RoleRef") + proto.RegisterType((*Subject)(nil), "k8s.io.client-go.pkg.apis.rbac.v1beta1.Subject") +} +func (m *ClusterRole) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ClusterRole) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *ClusterRoleBinding) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ClusterRoleBinding) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n2, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + if len(m.Subjects) > 0 { + for _, msg := range m.Subjects { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RoleRef.Size())) + n3, err := m.RoleRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + return i, nil +} + +func (m *ClusterRoleBindingBuilder) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ClusterRoleBindingBuilder) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ClusterRoleBinding.Size())) + n4, err := m.ClusterRoleBinding.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + return i, nil +} + +func (m *ClusterRoleBindingList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ClusterRoleBindingList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n5, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n5 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *ClusterRoleList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ClusterRoleList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n6, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n6 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *PolicyRule) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PolicyRule) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + if len(m.Verbs) > 0 { + for _, s := range m.Verbs { + dAtA[i] = 0xa + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + dAtA[i] = 0x12 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + dAtA[i] = 0x1a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.ResourceNames) > 0 { + for _, s := range m.ResourceNames { + dAtA[i] = 0x22 + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + if len(m.NonResourceURLs) > 0 { + for _, s := range m.NonResourceURLs { + dAtA[i] = 0x2a + i++ + l = len(s) + for l >= 1<<7 { + dAtA[i] = uint8(uint64(l)&0x7f | 0x80) + l >>= 7 + i++ + } + dAtA[i] = uint8(l) + i++ + i += copy(dAtA[i:], s) + } + } + return i, nil +} + +func (m *PolicyRuleBuilder) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PolicyRuleBuilder) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.PolicyRule.Size())) + n7, err := m.PolicyRule.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n7 + return i, nil +} + +func (m *Role) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Role) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n8, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n8 + if len(m.Rules) > 0 { + for _, msg := range m.Rules { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *RoleBinding) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RoleBinding) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n9, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n9 + if len(m.Subjects) > 0 { + for _, msg := range m.Subjects { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.RoleRef.Size())) + n10, err := m.RoleRef.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n10 + return i, nil +} + +func (m *RoleBindingList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RoleBindingList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n11, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n11 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *RoleList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RoleList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n12, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n12 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *RoleRef) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RoleRef) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIGroup))) + i += copy(dAtA[i:], m.APIGroup) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + return i, nil +} + +func (m *Subject) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Subject) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Kind))) + i += copy(dAtA[i:], m.Kind) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.APIGroup))) + i += copy(dAtA[i:], m.APIGroup) + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Name))) + i += copy(dAtA[i:], m.Name) + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Namespace))) + i += copy(dAtA[i:], m.Namespace) + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *ClusterRole) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ClusterRoleBinding) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Subjects) > 0 { + for _, e := range m.Subjects { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.RoleRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ClusterRoleBindingBuilder) Size() (n int) { + var l int + _ = l + l = m.ClusterRoleBinding.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *ClusterRoleBindingList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *ClusterRoleList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *PolicyRule) Size() (n int) { + var l int + _ = l + if len(m.Verbs) > 0 { + for _, s := range m.Verbs { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.APIGroups) > 0 { + for _, s := range m.APIGroups { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Resources) > 0 { + for _, s := range m.Resources { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.ResourceNames) > 0 { + for _, s := range m.ResourceNames { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.NonResourceURLs) > 0 { + for _, s := range m.NonResourceURLs { + l = len(s) + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *PolicyRuleBuilder) Size() (n int) { + var l int + _ = l + l = m.PolicyRule.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Role) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Rules) > 0 { + for _, e := range m.Rules { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *RoleBinding) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Subjects) > 0 { + for _, e := range m.Subjects { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + l = m.RoleRef.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *RoleBindingList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *RoleList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *RoleRef) Size() (n int) { + var l int + _ = l + l = len(m.APIGroup) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *Subject) Size() (n int) { + var l int + _ = l + l = len(m.Kind) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.APIGroup) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Name) + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Namespace) + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *ClusterRole) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ClusterRole{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "PolicyRule", "PolicyRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ClusterRoleBinding) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ClusterRoleBinding{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Subjects:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Subjects), "Subject", "Subject", 1), `&`, ``, 1) + `,`, + `RoleRef:` + strings.Replace(strings.Replace(this.RoleRef.String(), "RoleRef", "RoleRef", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ClusterRoleBindingBuilder) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ClusterRoleBindingBuilder{`, + `ClusterRoleBinding:` + strings.Replace(strings.Replace(this.ClusterRoleBinding.String(), "ClusterRoleBinding", "ClusterRoleBinding", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ClusterRoleBindingList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ClusterRoleBindingList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ClusterRoleBinding", "ClusterRoleBinding", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *ClusterRoleList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&ClusterRoleList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "ClusterRole", "ClusterRole", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PolicyRule) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PolicyRule{`, + `Verbs:` + fmt.Sprintf("%v", this.Verbs) + `,`, + `APIGroups:` + fmt.Sprintf("%v", this.APIGroups) + `,`, + `Resources:` + fmt.Sprintf("%v", this.Resources) + `,`, + `ResourceNames:` + fmt.Sprintf("%v", this.ResourceNames) + `,`, + `NonResourceURLs:` + fmt.Sprintf("%v", this.NonResourceURLs) + `,`, + `}`, + }, "") + return s +} +func (this *PolicyRuleBuilder) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PolicyRuleBuilder{`, + `PolicyRule:` + strings.Replace(strings.Replace(this.PolicyRule.String(), "PolicyRule", "PolicyRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *Role) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Role{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Rules:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Rules), "PolicyRule", "PolicyRule", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *RoleBinding) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RoleBinding{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Subjects:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Subjects), "Subject", "Subject", 1), `&`, ``, 1) + `,`, + `RoleRef:` + strings.Replace(strings.Replace(this.RoleRef.String(), "RoleRef", "RoleRef", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *RoleBindingList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RoleBindingList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "RoleBinding", "RoleBinding", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *RoleList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RoleList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "Role", "Role", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *RoleRef) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&RoleRef{`, + `APIGroup:` + fmt.Sprintf("%v", this.APIGroup) + `,`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `}`, + }, "") + return s +} +func (this *Subject) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&Subject{`, + `Kind:` + fmt.Sprintf("%v", this.Kind) + `,`, + `APIGroup:` + fmt.Sprintf("%v", this.APIGroup) + `,`, + `Name:` + fmt.Sprintf("%v", this.Name) + `,`, + `Namespace:` + fmt.Sprintf("%v", this.Namespace) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *ClusterRole) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ClusterRole: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ClusterRole: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, PolicyRule{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ClusterRoleBinding) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ClusterRoleBinding: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ClusterRoleBinding: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Subjects", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Subjects = append(m.Subjects, Subject{}) + if err := m.Subjects[len(m.Subjects)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RoleRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.RoleRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ClusterRoleBindingBuilder) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ClusterRoleBindingBuilder: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ClusterRoleBindingBuilder: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ClusterRoleBinding", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ClusterRoleBinding.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ClusterRoleBindingList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ClusterRoleBindingList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ClusterRoleBindingList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ClusterRoleBinding{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *ClusterRoleList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ClusterRoleList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ClusterRoleList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, ClusterRole{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PolicyRule) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PolicyRule: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PolicyRule: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Verbs", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Verbs = append(m.Verbs, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIGroups", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIGroups = append(m.APIGroups, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Resources", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Resources = append(m.Resources, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ResourceNames", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ResourceNames = append(m.ResourceNames, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NonResourceURLs", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.NonResourceURLs = append(m.NonResourceURLs, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PolicyRuleBuilder) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PolicyRuleBuilder: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PolicyRuleBuilder: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field PolicyRule", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.PolicyRule.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Role) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Role: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Role: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Rules", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Rules = append(m.Rules, PolicyRule{}) + if err := m.Rules[len(m.Rules)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RoleBinding) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RoleBinding: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RoleBinding: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Subjects", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Subjects = append(m.Subjects, Subject{}) + if err := m.Subjects[len(m.Subjects)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field RoleRef", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.RoleRef.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RoleBindingList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RoleBindingList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RoleBindingList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, RoleBinding{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RoleList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RoleList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RoleList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, Role{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *RoleRef) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RoleRef: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RoleRef: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIGroup", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIGroup = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Subject) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Subject: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Subject: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Kind", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Kind = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field APIGroup", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.APIGroup = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Name", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Name = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Namespace", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Namespace = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 806 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x54, 0x3d, 0x6f, 0xc3, 0x44, + 0x18, 0xce, 0xe5, 0x43, 0x89, 0x2f, 0x44, 0xa1, 0x87, 0x84, 0x4c, 0x06, 0x27, 0xf2, 0x42, 0x25, + 0xa8, 0xdd, 0x2f, 0x51, 0x24, 0xc4, 0x80, 0x19, 0x50, 0x45, 0x29, 0xd5, 0x21, 0x10, 0x5f, 0x42, + 0x75, 0x9c, 0xab, 0x7b, 0xc4, 0x5f, 0xf2, 0x9d, 0x23, 0x55, 0x30, 0xb0, 0xb1, 0xf2, 0x27, 0xd8, + 0xba, 0xb1, 0x32, 0x31, 0x15, 0xa6, 0x8e, 0x9d, 0x22, 0x6a, 0x7e, 0x08, 0xc8, 0xf6, 0xf9, 0x23, + 0x4d, 0x4a, 0x43, 0x91, 0x22, 0x21, 0x31, 0xb5, 0xf7, 0xbe, 0xcf, 0xf3, 0xdc, 0xfb, 0xdc, 0xeb, + 0x3c, 0xf0, 0x68, 0xfa, 0x26, 0xd3, 0xa8, 0xaf, 0x4f, 0xa3, 0x31, 0x09, 0x3d, 0xc2, 0x09, 0xd3, + 0x83, 0xa9, 0xad, 0x9b, 0x01, 0x65, 0x7a, 0x38, 0x36, 0x2d, 0x7d, 0xb6, 0x37, 0x26, 0xdc, 0xdc, + 0xd3, 0x6d, 0xe2, 0x91, 0xd0, 0xe4, 0x64, 0xa2, 0x05, 0xa1, 0xcf, 0x7d, 0xf4, 0x6a, 0x46, 0xd4, + 0x4a, 0xa2, 0x16, 0x4c, 0x6d, 0x2d, 0x21, 0x6a, 0x09, 0x51, 0x13, 0xc4, 0xc1, 0x8e, 0x4d, 0xf9, + 0x65, 0x34, 0xd6, 0x2c, 0xdf, 0xd5, 0x6d, 0xdf, 0xf6, 0xf5, 0x94, 0x3f, 0x8e, 0x2e, 0xd2, 0x53, + 0x7a, 0x48, 0xff, 0xcb, 0x74, 0x07, 0x87, 0x62, 0x20, 0x33, 0xa0, 0xae, 0x69, 0x5d, 0x52, 0x8f, + 0x84, 0x57, 0xe5, 0x48, 0x2e, 0xe1, 0xa6, 0x3e, 0x5b, 0x9a, 0x66, 0xa0, 0x3f, 0xc6, 0x0a, 0x23, + 0x8f, 0x53, 0x97, 0x2c, 0x11, 0xde, 0x78, 0x8a, 0xc0, 0xac, 0x4b, 0xe2, 0x9a, 0x4b, 0xbc, 0x83, + 0xc7, 0x78, 0x11, 0xa7, 0x8e, 0x4e, 0x3d, 0xce, 0x78, 0xf8, 0x90, 0xa4, 0xfe, 0x0a, 0x60, 0xf7, + 0x5d, 0x27, 0x62, 0x9c, 0x84, 0xd8, 0x77, 0x08, 0x3a, 0x87, 0x9d, 0xc4, 0xc8, 0xc4, 0xe4, 0xa6, + 0x0c, 0x46, 0x60, 0xbb, 0xbb, 0xbf, 0xab, 0x89, 0xe7, 0xac, 0xea, 0x96, 0x0f, 0x9a, 0xa0, 0xb5, + 0xd9, 0x9e, 0xf6, 0xe1, 0xf8, 0x6b, 0x62, 0xf1, 0x0f, 0x08, 0x37, 0x0d, 0x74, 0x33, 0x1f, 0xd6, + 0xe2, 0xf9, 0x10, 0x96, 0x35, 0x5c, 0xa8, 0xa2, 0x4f, 0x61, 0x2b, 0x8c, 0x1c, 0xc2, 0xe4, 0xfa, + 0xa8, 0xb1, 0xdd, 0xdd, 0x3f, 0xd0, 0xd6, 0xdc, 0x96, 0x76, 0xe6, 0x3b, 0xd4, 0xba, 0xc2, 0x91, + 0x43, 0x8c, 0x9e, 0xb8, 0xa1, 0x95, 0x9c, 0x18, 0xce, 0x04, 0xd5, 0x9f, 0xea, 0x10, 0x55, 0xbc, + 0x18, 0xd4, 0x9b, 0x50, 0xcf, 0xde, 0x80, 0xa5, 0xaf, 0x60, 0x87, 0x45, 0x69, 0x23, 0x77, 0xb5, + 0xbb, 0xb6, 0xab, 0x8f, 0x32, 0xa2, 0xf1, 0xa2, 0xb8, 0xa1, 0x23, 0x0a, 0x0c, 0x17, 0x9a, 0xe8, + 0x0b, 0xd8, 0x0e, 0x7d, 0x87, 0x60, 0x72, 0x21, 0x37, 0x16, 0x0d, 0x3c, 0x29, 0x8f, 0x33, 0x9e, + 0xd1, 0x17, 0xf2, 0x6d, 0x51, 0xc0, 0xb9, 0xa2, 0xfa, 0x23, 0x80, 0xaf, 0x2c, 0xbf, 0x9a, 0x11, + 0x51, 0x67, 0x42, 0x42, 0xf4, 0x3d, 0x80, 0xc8, 0x5a, 0xea, 0x8a, 0x77, 0x7c, 0x6b, 0xed, 0x31, + 0x56, 0x5c, 0x30, 0x10, 0x13, 0xad, 0x58, 0x19, 0x5e, 0x71, 0xa5, 0x7a, 0x07, 0xe0, 0xcb, 0xcb, + 0xd0, 0x13, 0xca, 0x38, 0xfa, 0x72, 0x69, 0xc3, 0xda, 0x7a, 0x1b, 0x4e, 0xd8, 0xe9, 0x7e, 0x8b, + 0xd7, 0xcf, 0x2b, 0x95, 0xed, 0x9e, 0xc3, 0x16, 0xe5, 0xc4, 0xcd, 0x57, 0xfb, 0xaf, 0x4c, 0x17, + 0x1f, 0xee, 0x71, 0xa2, 0x88, 0x33, 0x61, 0xf5, 0x37, 0x00, 0xfb, 0x15, 0xf0, 0x06, 0x3c, 0x7d, + 0xb6, 0xe8, 0xe9, 0xf0, 0x59, 0x9e, 0x56, 0x9b, 0xf9, 0x13, 0x40, 0x58, 0xfe, 0x54, 0xd1, 0x10, + 0xb6, 0x66, 0x24, 0x1c, 0x33, 0x19, 0x8c, 0x1a, 0xdb, 0x92, 0x21, 0x25, 0xf8, 0x4f, 0x92, 0x02, + 0xce, 0xea, 0xe8, 0x35, 0x28, 0x99, 0x01, 0x7d, 0x2f, 0xf4, 0xa3, 0x20, 0x1b, 0x47, 0x32, 0x7a, + 0xf1, 0x7c, 0x28, 0xbd, 0x73, 0x76, 0x9c, 0x15, 0x71, 0xd9, 0x4f, 0xc0, 0x21, 0x61, 0x7e, 0x14, + 0x5a, 0x84, 0xc9, 0x8d, 0x12, 0x8c, 0xf3, 0x22, 0x2e, 0xfb, 0xe8, 0x08, 0xf6, 0xf2, 0xc3, 0xa9, + 0xe9, 0x12, 0x26, 0x37, 0x53, 0xc2, 0x56, 0x3c, 0x1f, 0xf6, 0x70, 0xb5, 0x81, 0x17, 0x71, 0xe8, + 0x6d, 0xd8, 0xf7, 0x7c, 0x2f, 0x87, 0x7c, 0x8c, 0x4f, 0x98, 0xdc, 0x4a, 0xa9, 0x2f, 0xc5, 0xf3, + 0x61, 0xff, 0x74, 0xb1, 0x85, 0x1f, 0x62, 0xd5, 0x6f, 0xe1, 0x56, 0x25, 0xab, 0xc4, 0x0f, 0xc9, + 0x86, 0x30, 0x28, 0x8a, 0x62, 0xa3, 0xcf, 0xca, 0xbe, 0x22, 0x8a, 0xca, 0x1a, 0xae, 0x48, 0xab, + 0xbf, 0x00, 0xd8, 0xfc, 0xcf, 0x47, 0xf9, 0x75, 0x1d, 0x76, 0xff, 0xcf, 0xf0, 0xb5, 0x33, 0x3c, + 0x09, 0x90, 0xcd, 0x86, 0xe2, 0xb3, 0x03, 0xe4, 0xe9, 0x34, 0xfc, 0x19, 0xc0, 0xce, 0x86, 0x62, + 0x10, 0x2f, 0xba, 0xd8, 0xf9, 0x67, 0x2e, 0x56, 0x8f, 0xff, 0x0d, 0xcc, 0xf7, 0x83, 0x5e, 0x87, + 0x9d, 0x3c, 0xba, 0xd2, 0xe1, 0xa5, 0x72, 0x98, 0x3c, 0xdd, 0x70, 0x81, 0x40, 0x23, 0xd8, 0x9c, + 0x52, 0x6f, 0x22, 0xd7, 0x53, 0xe4, 0x0b, 0x02, 0xd9, 0x7c, 0x9f, 0x7a, 0x13, 0x9c, 0x76, 0x12, + 0x84, 0x67, 0xba, 0x24, 0xfd, 0x80, 0x2a, 0x88, 0x24, 0xb4, 0x70, 0xda, 0x51, 0xaf, 0x01, 0x6c, + 0x8b, 0x8f, 0xaf, 0xd0, 0x03, 0x8f, 0xea, 0x55, 0xe7, 0xab, 0xaf, 0x33, 0xdf, 0xdf, 0xdf, 0x8e, + 0x74, 0x28, 0x25, 0x7f, 0x59, 0x60, 0x5a, 0x44, 0x6e, 0xa6, 0xb0, 0x2d, 0x01, 0x93, 0x4e, 0xf3, + 0x06, 0x2e, 0x31, 0xc6, 0xce, 0xcd, 0xbd, 0x52, 0xbb, 0xbd, 0x57, 0x6a, 0x77, 0xf7, 0x4a, 0xed, + 0xbb, 0x58, 0x01, 0x37, 0xb1, 0x02, 0x6e, 0x63, 0x05, 0xdc, 0xc5, 0x0a, 0xf8, 0x3d, 0x56, 0xc0, + 0x0f, 0x7f, 0x28, 0xb5, 0xcf, 0xdb, 0xe2, 0xd5, 0xff, 0x0a, 0x00, 0x00, 0xff, 0xff, 0x6d, 0x2c, + 0xb9, 0x90, 0x12, 0x0c, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto new file mode 100644 index 0000000000..d4a6ebcf66 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/generated.proto @@ -0,0 +1,198 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.rbac.v1beta1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1beta1"; + +// ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. +message ClusterRole { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Rules holds all the PolicyRules for this ClusterRole + repeated PolicyRule rules = 2; +} + +// ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, +// and adds who information via Subject. +message ClusterRoleBinding { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Subjects holds references to the objects the role applies to. + repeated Subject subjects = 2; + + // RoleRef can only reference a ClusterRole in the global namespace. + // If the RoleRef cannot be resolved, the Authorizer must return an error. + optional RoleRef roleRef = 3; +} + +// +k8s:deepcopy-gen=false +// ClusterRoleBindingBuilder let's us attach methods. A no-no for API types. +// We use it to construct bindings in code. It's more compact than trying to write them +// out in a literal. +message ClusterRoleBindingBuilder { + optional ClusterRoleBinding clusterRoleBinding = 1; +} + +// ClusterRoleBindingList is a collection of ClusterRoleBindings +message ClusterRoleBindingList { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of ClusterRoleBindings + repeated ClusterRoleBinding items = 2; +} + +// ClusterRoleList is a collection of ClusterRoles +message ClusterRoleList { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of ClusterRoles + repeated ClusterRole items = 2; +} + +// PolicyRule holds information that describes a policy rule, but does not contain information +// about who the rule applies to or which namespace the rule applies to. +message PolicyRule { + // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. + repeated string verbs = 1; + + // APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of + // the enumerated resources in any API group will be allowed. + // +optional + repeated string apiGroups = 2; + + // Resources is a list of resources this rule applies to. ResourceAll represents all resources. + // +optional + repeated string resources = 3; + + // ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed. + // +optional + repeated string resourceNames = 4; + + // NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path + // Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. + // Rules can either apply to API resources (such as "pods" or "secrets") or non-resource URL paths (such as "/api"), but not both. + // +optional + repeated string nonResourceURLs = 5; +} + +// +k8s:deepcopy-gen=false +// PolicyRuleBuilder let's us attach methods. A no-no for API types. +// We use it to construct rules in code. It's more compact than trying to write them +// out in a literal and allows us to perform some basic checking during construction +message PolicyRuleBuilder { + optional PolicyRule policyRule = 1; +} + +// Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. +message Role { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Rules holds all the PolicyRules for this Role + repeated PolicyRule rules = 2; +} + +// RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. +// It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given +// namespace only have effect in that namespace. +message RoleBinding { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Subjects holds references to the objects the role applies to. + repeated Subject subjects = 2; + + // RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace. + // If the RoleRef cannot be resolved, the Authorizer must return an error. + optional RoleRef roleRef = 3; +} + +// RoleBindingList is a collection of RoleBindings +message RoleBindingList { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of RoleBindings + repeated RoleBinding items = 2; +} + +// RoleList is a collection of Roles +message RoleList { + // Standard object's metadata. + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of Roles + repeated Role items = 2; +} + +// RoleRef contains information that points to the role being used +message RoleRef { + // APIGroup is the group for the resource being referenced + optional string apiGroup = 1; + + // Kind is the type of resource being referenced + optional string kind = 2; + + // Name is the name of resource being referenced + optional string name = 3; +} + +// Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, +// or a value for non-objects such as user and group names. +message Subject { + // Kind of object being referenced. Values defined by this API group are "User", "Group", and "ServiceAccount". + // If the Authorizer does not recognized the kind value, the Authorizer should report an error. + optional string kind = 1; + + // APIGroup holds the API group of the referenced subject. + // Defaults to "" for ServiceAccount subjects. + // Defaults to "rbac.authorization.k8s.io" for User and Group subjects. + // +optional + optional string apiGroup = 2; + + // Name of the object being referenced. + optional string name = 3; + + // Namespace of the referenced object. If the object kind is non-namespace, such as "User" or "Group", and this value is not empty + // the Authorizer should report an error. + // +optional + optional string namespace = 4; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/helpers.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/helpers.go new file mode 100644 index 0000000000..063b9ed3f6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/helpers.go @@ -0,0 +1,146 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + "fmt" + + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// PolicyRuleBuilder let's us attach methods. A no-no for API types. +// We use it to construct rules in code. It's more compact than trying to write them +// out in a literal and allows us to perform some basic checking during construction +type PolicyRuleBuilder struct { + PolicyRule PolicyRule `protobuf:"bytes,1,opt,name=policyRule"` +} + +func NewRule(verbs ...string) *PolicyRuleBuilder { + return &PolicyRuleBuilder{ + PolicyRule: PolicyRule{Verbs: verbs}, + } +} + +func (r *PolicyRuleBuilder) Groups(groups ...string) *PolicyRuleBuilder { + r.PolicyRule.APIGroups = append(r.PolicyRule.APIGroups, groups...) + return r +} + +func (r *PolicyRuleBuilder) Resources(resources ...string) *PolicyRuleBuilder { + r.PolicyRule.Resources = append(r.PolicyRule.Resources, resources...) + return r +} + +func (r *PolicyRuleBuilder) Names(names ...string) *PolicyRuleBuilder { + r.PolicyRule.ResourceNames = append(r.PolicyRule.ResourceNames, names...) + return r +} + +func (r *PolicyRuleBuilder) URLs(urls ...string) *PolicyRuleBuilder { + r.PolicyRule.NonResourceURLs = append(r.PolicyRule.NonResourceURLs, urls...) + return r +} + +func (r *PolicyRuleBuilder) RuleOrDie() PolicyRule { + ret, err := r.Rule() + if err != nil { + panic(err) + } + return ret +} + +func (r *PolicyRuleBuilder) Rule() (PolicyRule, error) { + if len(r.PolicyRule.Verbs) == 0 { + return PolicyRule{}, fmt.Errorf("verbs are required: %#v", r.PolicyRule) + } + + switch { + case len(r.PolicyRule.NonResourceURLs) > 0: + if len(r.PolicyRule.APIGroups) != 0 || len(r.PolicyRule.Resources) != 0 || len(r.PolicyRule.ResourceNames) != 0 { + return PolicyRule{}, fmt.Errorf("non-resource rule may not have apiGroups, resources, or resourceNames: %#v", r.PolicyRule) + } + case len(r.PolicyRule.Resources) > 0: + if len(r.PolicyRule.NonResourceURLs) != 0 { + return PolicyRule{}, fmt.Errorf("resource rule may not have nonResourceURLs: %#v", r.PolicyRule) + } + if len(r.PolicyRule.APIGroups) == 0 { + // this a common bug + return PolicyRule{}, fmt.Errorf("resource rule must have apiGroups: %#v", r.PolicyRule) + } + default: + return PolicyRule{}, fmt.Errorf("a rule must have either nonResourceURLs or resources: %#v", r.PolicyRule) + } + + return r.PolicyRule, nil +} + +// ClusterRoleBindingBuilder let's us attach methods. A no-no for API types. +// We use it to construct bindings in code. It's more compact than trying to write them +// out in a literal. +type ClusterRoleBindingBuilder struct { + ClusterRoleBinding ClusterRoleBinding `protobuf:"bytes,1,opt,name=clusterRoleBinding"` +} + +func NewClusterBinding(clusterRoleName string) *ClusterRoleBindingBuilder { + return &ClusterRoleBindingBuilder{ + ClusterRoleBinding: ClusterRoleBinding{ + ObjectMeta: metav1.ObjectMeta{Name: clusterRoleName}, + RoleRef: RoleRef{ + APIGroup: GroupName, + Kind: "ClusterRole", + Name: clusterRoleName, + }, + }, + } +} + +func (r *ClusterRoleBindingBuilder) Groups(groups ...string) *ClusterRoleBindingBuilder { + for _, group := range groups { + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: GroupKind, Name: group}) + } + return r +} + +func (r *ClusterRoleBindingBuilder) Users(users ...string) *ClusterRoleBindingBuilder { + for _, user := range users { + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: UserKind, Name: user}) + } + return r +} + +func (r *ClusterRoleBindingBuilder) SAs(namespace string, serviceAccountNames ...string) *ClusterRoleBindingBuilder { + for _, saName := range serviceAccountNames { + r.ClusterRoleBinding.Subjects = append(r.ClusterRoleBinding.Subjects, Subject{Kind: ServiceAccountKind, Namespace: namespace, Name: saName}) + } + return r +} + +func (r *ClusterRoleBindingBuilder) BindingOrDie() ClusterRoleBinding { + ret, err := r.Binding() + if err != nil { + panic(err) + } + return ret +} + +func (r *ClusterRoleBindingBuilder) Binding() (ClusterRoleBinding, error) { + if len(r.ClusterRoleBinding.Subjects) == 0 { + return ClusterRoleBinding{}, fmt.Errorf("subjects are required: %#v", r.ClusterRoleBinding) + } + + return r.ClusterRoleBinding, nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/register.go new file mode 100644 index 0000000000..aa64c0c6f6 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/register.go @@ -0,0 +1,65 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +const GroupName = "rbac.authorization.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addDefaultingFuncs) +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &Role{}, + &RoleBinding{}, + &RoleBindingList{}, + &RoleList{}, + + &ClusterRole{}, + &ClusterRoleBinding{}, + &ClusterRoleBindingList{}, + &ClusterRoleList{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.generated.go new file mode 100644 index 0000000000..bcb865cf8f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.generated.go @@ -0,0 +1,4879 @@ +/* +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 v1beta1 + +import ( + "errors" + "fmt" + codec1978 "github.com/ugorji/go/codec" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" + "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 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 + } +} + +func (x *PolicyRule) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = len(x.APIGroups) != 0 + yyq2[2] = len(x.Resources) != 0 + yyq2[3] = len(x.ResourceNames) != 0 + yyq2[4] = len(x.NonResourceURLs) != 0 + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Verbs == nil { + r.EncodeNil() + } else { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + z.F.EncSliceStringV(x.Verbs, false, e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("verbs")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Verbs == nil { + r.EncodeNil() + } else { + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + z.F.EncSliceStringV(x.Verbs, false, e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroups")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.APIGroups == nil { + r.EncodeNil() + } else { + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + z.F.EncSliceStringV(x.APIGroups, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + if x.Resources == nil { + r.EncodeNil() + } else { + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resources")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Resources == nil { + r.EncodeNil() + } else { + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + z.F.EncSliceStringV(x.Resources, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + if x.ResourceNames == nil { + r.EncodeNil() + } else { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + z.F.EncSliceStringV(x.ResourceNames, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("resourceNames")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.ResourceNames == nil { + r.EncodeNil() + } else { + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + z.F.EncSliceStringV(x.ResourceNames, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[4] { + if x.NonResourceURLs == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + z.F.EncSliceStringV(x.NonResourceURLs, false, e) + } + } + } else { + r.EncodeNil() + } + } else { + if yyq2[4] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("nonResourceURLs")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.NonResourceURLs == nil { + r.EncodeNil() + } else { + yym17 := z.EncBinary() + _ = yym17 + if false { + } else { + z.F.EncSliceStringV(x.NonResourceURLs, false, e) + } + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *PolicyRule) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *PolicyRule) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "verbs": + if r.TryDecodeAsNil() { + x.Verbs = nil + } else { + yyv4 := &x.Verbs + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + z.F.DecSliceStringX(yyv4, false, d) + } + } + case "apiGroups": + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv6 := &x.APIGroups + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + z.F.DecSliceStringX(yyv6, false, d) + } + } + case "resources": + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv8 := &x.Resources + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + z.F.DecSliceStringX(yyv8, false, d) + } + } + case "resourceNames": + if r.TryDecodeAsNil() { + x.ResourceNames = nil + } else { + yyv10 := &x.ResourceNames + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + z.F.DecSliceStringX(yyv10, false, d) + } + } + case "nonResourceURLs": + if r.TryDecodeAsNil() { + x.NonResourceURLs = nil + } else { + yyv12 := &x.NonResourceURLs + yym13 := z.DecBinary() + _ = yym13 + if false { + } else { + z.F.DecSliceStringX(yyv12, false, d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *PolicyRule) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Verbs = nil + } else { + yyv15 := &x.Verbs + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + z.F.DecSliceStringX(yyv15, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroups = nil + } else { + yyv17 := &x.APIGroups + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + z.F.DecSliceStringX(yyv17, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Resources = nil + } else { + yyv19 := &x.Resources + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + z.F.DecSliceStringX(yyv19, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ResourceNames = nil + } else { + yyv21 := &x.ResourceNames + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + z.F.DecSliceStringX(yyv21, false, d) + } + } + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.NonResourceURLs = nil + } else { + yyv23 := &x.NonResourceURLs + yym24 := z.DecBinary() + _ = yym24 + if false { + } else { + z.F.DecSliceStringX(yyv23, false, d) + } + } + for { + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l + } else { + yyb14 = r.CheckBreak() + } + if yyb14 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj14-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Subject) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[1] = x.APIGroup != "" + yyq2[3] = x.Namespace != "" + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIGroup)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroup")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIGroup)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[3] { + yym13 := z.EncBinary() + _ = yym13 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[3] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("namespace")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym14 := z.EncBinary() + _ = yym14 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Namespace)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Subject) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Subject) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiGroup": + if r.TryDecodeAsNil() { + x.APIGroup = "" + } else { + yyv6 := &x.APIGroup + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + case "namespace": + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv10 := &x.Namespace + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Subject) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroup = "" + } else { + yyv15 := &x.APIGroup + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv17 := &x.Name + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Namespace = "" + } else { + yyv19 := &x.Namespace + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + *((*string)(yyv19)) = r.DecodeString() + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RoleRef) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [3]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(3) + } else { + yynn2 = 3 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIGroup)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiGroup")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIGroup)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yym10 := z.EncBinary() + _ = yym10 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("name")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Name)) + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RoleRef) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RoleRef) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "apiGroup": + if r.TryDecodeAsNil() { + x.APIGroup = "" + } else { + yyv4 := &x.APIGroup + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv6 := &x.Kind + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "name": + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv8 := &x.Name + yym9 := z.DecBinary() + _ = yym9 + if false { + } else { + *((*string)(yyv8)) = r.DecodeString() + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RoleRef) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj10 int + var yyb10 bool + var yyhl10 bool = l >= 0 + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIGroup = "" + } else { + yyv11 := &x.APIGroup + yym12 := z.DecBinary() + _ = yym12 + if false { + } else { + *((*string)(yyv11)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Name = "" + } else { + yyv15 := &x.Name + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + for { + yyj10++ + if yyhl10 { + yyb10 = yyj10 > l + } else { + yyb10 = r.CheckBreak() + } + if yyb10 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj10-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *Role) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *Role) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *Role) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv10 := &x.Rules + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSlicePolicyRule((*[]PolicyRule)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *Role) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv19 := &x.Rules + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePolicyRule((*[]PolicyRule)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Subjects == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceSubject(([]Subject)(x.Subjects), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("subjects")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Subjects == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceSubject(([]Subject)(x.Subjects), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy18 := &x.RoleRef + yy18.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("roleRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy20 := &x.RoleRef + yy20.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RoleBinding) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RoleBinding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "subjects": + if r.TryDecodeAsNil() { + x.Subjects = nil + } else { + yyv10 := &x.Subjects + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceSubject((*[]Subject)(yyv10), d) + } + } + case "roleRef": + if r.TryDecodeAsNil() { + x.RoleRef = RoleRef{} + } else { + yyv12 := &x.RoleRef + yyv12.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv14 := &x.Kind + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv16 := &x.APIVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv18 := &x.ObjectMeta + yym19 := z.DecBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else { + z.DecFallback(yyv18, false) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Subjects = nil + } else { + yyv20 := &x.Subjects + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + h.decSliceSubject((*[]Subject)(yyv20), d) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.RoleRef = RoleRef{} + } else { + yyv22 := &x.RoleRef + yyv22.CodecDecodeSelf(d) + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceRoleBinding(([]RoleBinding)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceRoleBinding(([]RoleBinding)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RoleBindingList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RoleBindingList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceRoleBinding((*[]RoleBinding)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceRoleBinding((*[]RoleBinding)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *RoleList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceRole(([]Role)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceRole(([]Role)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *RoleList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *RoleList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceRole((*[]Role)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *RoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceRole((*[]Role)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ClusterRole) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("rules")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Rules == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSlicePolicyRule(([]PolicyRule)(x.Rules), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ClusterRole) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ClusterRole) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "rules": + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv10 := &x.Rules + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSlicePolicyRule((*[]PolicyRule)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ClusterRole) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv17 := &x.ObjectMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Rules = nil + } else { + yyv19 := &x.Rules + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSlicePolicyRule((*[]PolicyRule)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ClusterRoleBinding) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [5]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(5) + } else { + yynn2 = 2 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ObjectMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Subjects == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceSubject(([]Subject)(x.Subjects), e) + } + } + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("subjects")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + if x.Subjects == nil { + r.EncodeNil() + } else { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceSubject(([]Subject)(x.Subjects), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy18 := &x.RoleRef + yy18.CodecEncodeSelf(e) + } else { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("roleRef")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy20 := &x.RoleRef + yy20.CodecEncodeSelf(e) + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ClusterRoleBinding) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ClusterRoleBinding) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "subjects": + if r.TryDecodeAsNil() { + x.Subjects = nil + } else { + yyv10 := &x.Subjects + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceSubject((*[]Subject)(yyv10), d) + } + } + case "roleRef": + if r.TryDecodeAsNil() { + x.RoleRef = RoleRef{} + } else { + yyv12 := &x.RoleRef + yyv12.CodecDecodeSelf(d) + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ClusterRoleBinding) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj13 int + var yyb13 bool + var yyhl13 bool = l >= 0 + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv14 := &x.Kind + yym15 := z.DecBinary() + _ = yym15 + if false { + } else { + *((*string)(yyv14)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv16 := &x.APIVersion + yym17 := z.DecBinary() + _ = yym17 + if false { + } else { + *((*string)(yyv16)) = r.DecodeString() + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ObjectMeta = pkg1_v1.ObjectMeta{} + } else { + yyv18 := &x.ObjectMeta + yym19 := z.DecBinary() + _ = yym19 + if false { + } else if z.HasExtensions() && z.DecExt(yyv18) { + } else { + z.DecFallback(yyv18, false) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Subjects = nil + } else { + yyv20 := &x.Subjects + yym21 := z.DecBinary() + _ = yym21 + if false { + } else { + h.decSliceSubject((*[]Subject)(yyv20), d) + } + } + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.RoleRef = RoleRef{} + } else { + yyv22 := &x.RoleRef + yyv22.CodecDecodeSelf(d) + } + for { + yyj13++ + if yyhl13 { + yyb13 = yyj13 > l + } else { + yyb13 = r.CheckBreak() + } + if yyb13 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj13-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ClusterRoleBindingList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceClusterRoleBinding(([]ClusterRoleBinding)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceClusterRoleBinding(([]ClusterRoleBinding)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ClusterRoleBindingList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ClusterRoleBindingList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceClusterRoleBinding((*[]ClusterRoleBinding)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ClusterRoleBindingList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceClusterRoleBinding((*[]ClusterRoleBinding)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x *ClusterRoleList) CodecEncodeSelf(e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + if x == nil { + r.EncodeNil() + } else { + yym1 := z.EncBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.EncExt(x) { + } else { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { + r.EncodeArrayStart(4) + } else { + yynn2 = 1 + for _, b := range yyq2 { + if b { + yynn2++ + } + } + r.EncodeMapStart(yynn2) + yynn2 = 0 + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[0] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("kind")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym5 := z.EncBinary() + _ = yym5 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } else { + r.EncodeString(codecSelferC_UTF81234, "") + } + } else { + if yyq2[1] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yym8 := z.EncBinary() + _ = yym8 + if false { + } else { + r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } + } else { + r.EncodeNil() + } + } else { + if yyq2[2] { + z.EncSendContainerState(codecSelfer_containerMapKey1234) + r.EncodeString(codecSelferC_UTF81234, string("metadata")) + z.EncSendContainerState(codecSelfer_containerMapValue1234) + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + if x.Items == nil { + r.EncodeNil() + } else { + yym15 := z.EncBinary() + _ = yym15 + if false { + } else { + h.encSliceClusterRole(([]ClusterRole)(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 { + yym16 := z.EncBinary() + _ = yym16 + if false { + } else { + h.encSliceClusterRole(([]ClusterRole)(x.Items), e) + } + } + } + if yyr2 || yy2arr2 { + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + z.EncSendContainerState(codecSelfer_containerMapEnd1234) + } + } + } +} + +func (x *ClusterRoleList) CodecDecodeSelf(d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + yym1 := z.DecBinary() + _ = yym1 + if false { + } else if z.HasExtensions() && z.DecExt(x) { + } else { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerMapEnd1234) + } else { + x.codecDecodeSelfFromMap(yyl2, d) + } + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + } else { + x.codecDecodeSelfFromArray(yyl2, d) + } + } else { + panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) + } + } +} + +func (x *ClusterRoleList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { + break + } + } else { + if r.CheckBreak() { + break + } + } + z.DecSendContainerState(codecSelfer_containerMapKey1234) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) + z.DecSendContainerState(codecSelfer_containerMapValue1234) + switch yys3 { + case "kind": + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } + } + case "apiVersion": + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } + } + case "metadata": + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } + } + case "items": + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + h.decSliceClusterRole((*[]ClusterRole)(yyv10), d) + } + } + default: + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 + z.DecSendContainerState(codecSelfer_containerMapEnd1234) +} + +func (x *ClusterRoleList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Kind = "" + } else { + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.APIVersion = "" + } else { + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.ListMeta = pkg1_v1.ListMeta{} + } else { + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 + if false { + } else if z.HasExtensions() && z.DecExt(yyv17) { + } else { + z.DecFallback(yyv17, false) + } + } + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) + return + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + if r.TryDecodeAsNil() { + x.Items = nil + } else { + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 + if false { + } else { + h.decSliceClusterRole((*[]ClusterRole)(yyv19), d) + } + } + for { + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l + } else { + yyb12 = r.CheckBreak() + } + if yyb12 { + break + } + z.DecSendContainerState(codecSelfer_containerArrayElem1234) + z.DecStructFieldNotFound(yyj12-1, "") + } + z.DecSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) encSlicePolicyRule(v []PolicyRule, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSlicePolicyRule(v *[]PolicyRule, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []PolicyRule{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 120) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]PolicyRule, yyrl1) + } + } else { + yyv1 = make([]PolicyRule, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = PolicyRule{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, PolicyRule{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = PolicyRule{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, PolicyRule{}) // var yyz1 PolicyRule + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = PolicyRule{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []PolicyRule{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceSubject(v []Subject, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceSubject(v *[]Subject, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Subject{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 64) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Subject, yyrl1) + } + } else { + yyv1 = make([]Subject, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Subject{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Subject{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Subject{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Subject{}) // var yyz1 Subject + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Subject{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Subject{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRoleBinding(v []RoleBinding, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRoleBinding(v *[]RoleBinding, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []RoleBinding{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 336) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]RoleBinding, yyrl1) + } + } else { + yyv1 = make([]RoleBinding, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RoleBinding{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, RoleBinding{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = RoleBinding{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, RoleBinding{}) // var yyz1 RoleBinding + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = RoleBinding{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []RoleBinding{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceRole(v []Role, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceRole(v *[]Role, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []Role{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]Role, yyrl1) + } + } else { + yyv1 = make([]Role, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Role{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, Role{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = Role{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, Role{}) // var yyz1 Role + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = Role{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []Role{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceClusterRoleBinding(v []ClusterRoleBinding, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceClusterRoleBinding(v *[]ClusterRoleBinding, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ClusterRoleBinding{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 336) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ClusterRoleBinding, yyrl1) + } + } else { + yyv1 = make([]ClusterRoleBinding, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ClusterRoleBinding{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ClusterRoleBinding{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ClusterRoleBinding{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ClusterRoleBinding{}) // var yyz1 ClusterRoleBinding + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ClusterRoleBinding{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ClusterRoleBinding{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} + +func (x codecSelfer1234) encSliceClusterRole(v []ClusterRole, e *codec1978.Encoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperEncoder(e) + _, _, _ = h, z, r + r.EncodeArrayStart(len(v)) + for _, yyv1 := range v { + z.EncSendContainerState(codecSelfer_containerArrayElem1234) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) + } + z.EncSendContainerState(codecSelfer_containerArrayEnd1234) +} + +func (x codecSelfer1234) decSliceClusterRole(v *[]ClusterRole, d *codec1978.Decoder) { + var h codecSelfer1234 + z, r := codec1978.GenHelperDecoder(d) + _, _, _ = h, z, r + + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []ClusterRole{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true + } + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { + + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] + } else { + yyv1 = make([]ClusterRole, yyrl1) + } + } else { + yyv1 = make([]ClusterRole, yyrl1) + } + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) + } + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true + } + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ClusterRole{} + } else { + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) + } + + } + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, ClusterRole{}) + yyh1.ElemContainerState(yyj1) + if r.TryDecodeAsNil() { + yyv1[yyj1] = ClusterRole{} + } else { + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) + } + + } + } + + } else { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { + + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, ClusterRole{}) // var yyz1 ClusterRole + yyc1 = true + } + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { + if r.TryDecodeAsNil() { + yyv1[yyj1] = ClusterRole{} + } else { + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) + } + + } else { + z.DecSwallow() + } + + } + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []ClusterRole{} + yyc1 = true + } + } + yyh1.End() + if yyc1 { + *v = yyv1 + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.go new file mode 100644 index 0000000000..89a47db9e3 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types.go @@ -0,0 +1,207 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// Authorization is calculated against +// 1. evaluation of ClusterRoleBindings - short circuit on match +// 2. evaluation of RoleBindings in the namespace requested - short circuit on match +// 3. deny by default + +const ( + APIGroupAll = "*" + ResourceAll = "*" + VerbAll = "*" + NonResourceAll = "*" + + GroupKind = "Group" + ServiceAccountKind = "ServiceAccount" + UserKind = "User" + + // AutoUpdateAnnotationKey is the name of an annotation which prevents reconciliation if set to "false" + AutoUpdateAnnotationKey = "rbac.authorization.kubernetes.io/autoupdate" +) + +// Authorization is calculated against +// 1. evaluation of ClusterRoleBindings - short circuit on match +// 2. evaluation of RoleBindings in the namespace requested - short circuit on match +// 3. deny by default + +// PolicyRule holds information that describes a policy rule, but does not contain information +// about who the rule applies to or which namespace the rule applies to. +type PolicyRule struct { + // Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds. + Verbs []string `json:"verbs" protobuf:"bytes,1,rep,name=verbs"` + + // APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of + // the enumerated resources in any API group will be allowed. + // +optional + APIGroups []string `json:"apiGroups,omitempty" protobuf:"bytes,2,rep,name=apiGroups"` + // Resources is a list of resources this rule applies to. ResourceAll represents all resources. + // +optional + Resources []string `json:"resources,omitempty" protobuf:"bytes,3,rep,name=resources"` + // ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed. + // +optional + ResourceNames []string `json:"resourceNames,omitempty" protobuf:"bytes,4,rep,name=resourceNames"` + + // NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path + // Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. + // Rules can either apply to API resources (such as "pods" or "secrets") or non-resource URL paths (such as "/api"), but not both. + // +optional + NonResourceURLs []string `json:"nonResourceURLs,omitempty" protobuf:"bytes,5,rep,name=nonResourceURLs"` +} + +// Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, +// or a value for non-objects such as user and group names. +type Subject struct { + // Kind of object being referenced. Values defined by this API group are "User", "Group", and "ServiceAccount". + // If the Authorizer does not recognized the kind value, the Authorizer should report an error. + Kind string `json:"kind" protobuf:"bytes,1,opt,name=kind"` + // APIGroup holds the API group of the referenced subject. + // Defaults to "" for ServiceAccount subjects. + // Defaults to "rbac.authorization.k8s.io" for User and Group subjects. + // +optional + APIGroup string `json:"apiGroup,omitempty" protobuf:"bytes,2,opt.name=apiGroup"` + // Name of the object being referenced. + Name string `json:"name" protobuf:"bytes,3,opt,name=name"` + // Namespace of the referenced object. If the object kind is non-namespace, such as "User" or "Group", and this value is not empty + // the Authorizer should report an error. + // +optional + Namespace string `json:"namespace,omitempty" protobuf:"bytes,4,opt,name=namespace"` +} + +// RoleRef contains information that points to the role being used +type RoleRef struct { + // APIGroup is the group for the resource being referenced + APIGroup string `json:"apiGroup" protobuf:"bytes,1,opt,name=apiGroup"` + // Kind is the type of resource being referenced + Kind string `json:"kind" protobuf:"bytes,2,opt,name=kind"` + // Name is the name of resource being referenced + Name string `json:"name" protobuf:"bytes,3,opt,name=name"` +} + +// +genclient=true + +// Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding. +type Role struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Rules holds all the PolicyRules for this Role + Rules []PolicyRule `json:"rules" protobuf:"bytes,2,rep,name=rules"` +} + +// +genclient=true + +// RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. +// It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given +// namespace only have effect in that namespace. +type RoleBinding struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Subjects holds references to the objects the role applies to. + Subjects []Subject `json:"subjects" protobuf:"bytes,2,rep,name=subjects"` + + // RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace. + // If the RoleRef cannot be resolved, the Authorizer must return an error. + RoleRef RoleRef `json:"roleRef" protobuf:"bytes,3,opt,name=roleRef"` +} + +// RoleBindingList is a collection of RoleBindings +type RoleBindingList struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of RoleBindings + Items []RoleBinding `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// RoleList is a collection of Roles +type RoleList struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of Roles + Items []Role `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// +genclient=true +// +nonNamespaced=true + +// ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding. +type ClusterRole struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Rules holds all the PolicyRules for this ClusterRole + Rules []PolicyRule `json:"rules" protobuf:"bytes,2,rep,name=rules"` +} + +// +genclient=true +// +nonNamespaced=true + +// ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, +// and adds who information via Subject. +type ClusterRoleBinding struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Subjects holds references to the objects the role applies to. + Subjects []Subject `json:"subjects" protobuf:"bytes,2,rep,name=subjects"` + + // RoleRef can only reference a ClusterRole in the global namespace. + // If the RoleRef cannot be resolved, the Authorizer must return an error. + RoleRef RoleRef `json:"roleRef" protobuf:"bytes,3,opt,name=roleRef"` +} + +// ClusterRoleBindingList is a collection of ClusterRoleBindings +type ClusterRoleBindingList struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of ClusterRoleBindings + Items []ClusterRoleBinding `json:"items" protobuf:"bytes,2,rep,name=items"` +} + +// ClusterRoleList is a collection of ClusterRoles +type ClusterRoleList struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of ClusterRoles + Items []ClusterRole `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..1463d8feac --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/types_swagger_doc_generated.go @@ -0,0 +1,148 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1beta1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_ClusterRole = map[string]string{ + "": "ClusterRole is a cluster level, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding or ClusterRoleBinding.", + "metadata": "Standard object's metadata.", + "rules": "Rules holds all the PolicyRules for this ClusterRole", +} + +func (ClusterRole) SwaggerDoc() map[string]string { + return map_ClusterRole +} + +var map_ClusterRoleBinding = map[string]string{ + "": "ClusterRoleBinding references a ClusterRole, but not contain it. It can reference a ClusterRole in the global namespace, and adds who information via Subject.", + "metadata": "Standard object's metadata.", + "subjects": "Subjects holds references to the objects the role applies to.", + "roleRef": "RoleRef can only reference a ClusterRole in the global namespace. If the RoleRef cannot be resolved, the Authorizer must return an error.", +} + +func (ClusterRoleBinding) SwaggerDoc() map[string]string { + return map_ClusterRoleBinding +} + +var map_ClusterRoleBindingList = map[string]string{ + "": "ClusterRoleBindingList is a collection of ClusterRoleBindings", + "metadata": "Standard object's metadata.", + "items": "Items is a list of ClusterRoleBindings", +} + +func (ClusterRoleBindingList) SwaggerDoc() map[string]string { + return map_ClusterRoleBindingList +} + +var map_ClusterRoleList = map[string]string{ + "": "ClusterRoleList is a collection of ClusterRoles", + "metadata": "Standard object's metadata.", + "items": "Items is a list of ClusterRoles", +} + +func (ClusterRoleList) SwaggerDoc() map[string]string { + return map_ClusterRoleList +} + +var map_PolicyRule = map[string]string{ + "": "PolicyRule holds information that describes a policy rule, but does not contain information about who the rule applies to or which namespace the rule applies to.", + "verbs": "Verbs is a list of Verbs that apply to ALL the ResourceKinds and AttributeRestrictions contained in this rule. VerbAll represents all kinds.", + "apiGroups": "APIGroups is the name of the APIGroup that contains the resources. If multiple API groups are specified, any action requested against one of the enumerated resources in any API group will be allowed.", + "resources": "Resources is a list of resources this rule applies to. ResourceAll represents all resources.", + "resourceNames": "ResourceNames is an optional white list of names that the rule applies to. An empty set means that everything is allowed.", + "nonResourceURLs": "NonResourceURLs is a set of partial urls that a user should have access to. *s are allowed, but only as the full, final step in the path Since non-resource URLs are not namespaced, this field is only applicable for ClusterRoles referenced from a ClusterRoleBinding. Rules can either apply to API resources (such as \"pods\" or \"secrets\") or non-resource URL paths (such as \"/api\"), but not both.", +} + +func (PolicyRule) SwaggerDoc() map[string]string { + return map_PolicyRule +} + +var map_Role = map[string]string{ + "": "Role is a namespaced, logical grouping of PolicyRules that can be referenced as a unit by a RoleBinding.", + "metadata": "Standard object's metadata.", + "rules": "Rules holds all the PolicyRules for this Role", +} + +func (Role) SwaggerDoc() map[string]string { + return map_Role +} + +var map_RoleBinding = map[string]string{ + "": "RoleBinding references a role, but does not contain it. It can reference a Role in the same namespace or a ClusterRole in the global namespace. It adds who information via Subjects and namespace information by which namespace it exists in. RoleBindings in a given namespace only have effect in that namespace.", + "metadata": "Standard object's metadata.", + "subjects": "Subjects holds references to the objects the role applies to.", + "roleRef": "RoleRef can reference a Role in the current namespace or a ClusterRole in the global namespace. If the RoleRef cannot be resolved, the Authorizer must return an error.", +} + +func (RoleBinding) SwaggerDoc() map[string]string { + return map_RoleBinding +} + +var map_RoleBindingList = map[string]string{ + "": "RoleBindingList is a collection of RoleBindings", + "metadata": "Standard object's metadata.", + "items": "Items is a list of RoleBindings", +} + +func (RoleBindingList) SwaggerDoc() map[string]string { + return map_RoleBindingList +} + +var map_RoleList = map[string]string{ + "": "RoleList is a collection of Roles", + "metadata": "Standard object's metadata.", + "items": "Items is a list of Roles", +} + +func (RoleList) SwaggerDoc() map[string]string { + return map_RoleList +} + +var map_RoleRef = map[string]string{ + "": "RoleRef contains information that points to the role being used", + "apiGroup": "APIGroup is the group for the resource being referenced", + "kind": "Kind is the type of resource being referenced", + "name": "Name is the name of resource being referenced", +} + +func (RoleRef) SwaggerDoc() map[string]string { + return map_RoleRef +} + +var map_Subject = map[string]string{ + "": "Subject contains a reference to the object or user identities a role binding applies to. This can either hold a direct API object reference, or a value for non-objects such as user and group names.", + "kind": "Kind of object being referenced. Values defined by this API group are \"User\", \"Group\", and \"ServiceAccount\". If the Authorizer does not recognized the kind value, the Authorizer should report an error.", + "apiGroup": "APIGroup holds the API group of the referenced subject. Defaults to \"\" for ServiceAccount subjects. Defaults to \"rbac.authorization.k8s.io\" for User and Group subjects.", + "name": "Name of the object being referenced.", + "namespace": "Namespace of the referenced object. If the object kind is non-namespace, such as \"User\" or \"Group\", and this value is not empty the Authorizer should report an error.", +} + +func (Subject) SwaggerDoc() map[string]string { + return map_Subject +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.conversion.go new file mode 100644 index 0000000000..56e2c4ee42 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.conversion.go @@ -0,0 +1,415 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1beta1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + rbac "k8s.io/client-go/pkg/apis/rbac" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1beta1_ClusterRole_To_rbac_ClusterRole, + Convert_rbac_ClusterRole_To_v1beta1_ClusterRole, + Convert_v1beta1_ClusterRoleBinding_To_rbac_ClusterRoleBinding, + Convert_rbac_ClusterRoleBinding_To_v1beta1_ClusterRoleBinding, + Convert_v1beta1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder, + Convert_rbac_ClusterRoleBindingBuilder_To_v1beta1_ClusterRoleBindingBuilder, + Convert_v1beta1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList, + Convert_rbac_ClusterRoleBindingList_To_v1beta1_ClusterRoleBindingList, + Convert_v1beta1_ClusterRoleList_To_rbac_ClusterRoleList, + Convert_rbac_ClusterRoleList_To_v1beta1_ClusterRoleList, + Convert_v1beta1_PolicyRule_To_rbac_PolicyRule, + Convert_rbac_PolicyRule_To_v1beta1_PolicyRule, + Convert_v1beta1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder, + Convert_rbac_PolicyRuleBuilder_To_v1beta1_PolicyRuleBuilder, + Convert_v1beta1_Role_To_rbac_Role, + Convert_rbac_Role_To_v1beta1_Role, + Convert_v1beta1_RoleBinding_To_rbac_RoleBinding, + Convert_rbac_RoleBinding_To_v1beta1_RoleBinding, + Convert_v1beta1_RoleBindingList_To_rbac_RoleBindingList, + Convert_rbac_RoleBindingList_To_v1beta1_RoleBindingList, + Convert_v1beta1_RoleList_To_rbac_RoleList, + Convert_rbac_RoleList_To_v1beta1_RoleList, + Convert_v1beta1_RoleRef_To_rbac_RoleRef, + Convert_rbac_RoleRef_To_v1beta1_RoleRef, + Convert_v1beta1_Subject_To_rbac_Subject, + Convert_rbac_Subject_To_v1beta1_Subject, + ) +} + +func autoConvert_v1beta1_ClusterRole_To_rbac_ClusterRole(in *ClusterRole, out *rbac.ClusterRole, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Rules = *(*[]rbac.PolicyRule)(unsafe.Pointer(&in.Rules)) + return nil +} + +// Convert_v1beta1_ClusterRole_To_rbac_ClusterRole is an autogenerated conversion function. +func Convert_v1beta1_ClusterRole_To_rbac_ClusterRole(in *ClusterRole, out *rbac.ClusterRole, s conversion.Scope) error { + return autoConvert_v1beta1_ClusterRole_To_rbac_ClusterRole(in, out, s) +} + +func autoConvert_rbac_ClusterRole_To_v1beta1_ClusterRole(in *rbac.ClusterRole, out *ClusterRole, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if in.Rules == nil { + out.Rules = make([]PolicyRule, 0) + } else { + out.Rules = *(*[]PolicyRule)(unsafe.Pointer(&in.Rules)) + } + return nil +} + +// Convert_rbac_ClusterRole_To_v1beta1_ClusterRole is an autogenerated conversion function. +func Convert_rbac_ClusterRole_To_v1beta1_ClusterRole(in *rbac.ClusterRole, out *ClusterRole, s conversion.Scope) error { + return autoConvert_rbac_ClusterRole_To_v1beta1_ClusterRole(in, out, s) +} + +func autoConvert_v1beta1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(in *ClusterRoleBinding, out *rbac.ClusterRoleBinding, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Subjects = *(*[]rbac.Subject)(unsafe.Pointer(&in.Subjects)) + if err := Convert_v1beta1_RoleRef_To_rbac_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_ClusterRoleBinding_To_rbac_ClusterRoleBinding is an autogenerated conversion function. +func Convert_v1beta1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(in *ClusterRoleBinding, out *rbac.ClusterRoleBinding, s conversion.Scope) error { + return autoConvert_v1beta1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(in, out, s) +} + +func autoConvert_rbac_ClusterRoleBinding_To_v1beta1_ClusterRoleBinding(in *rbac.ClusterRoleBinding, out *ClusterRoleBinding, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if in.Subjects == nil { + out.Subjects = make([]Subject, 0) + } else { + out.Subjects = *(*[]Subject)(unsafe.Pointer(&in.Subjects)) + } + if err := Convert_rbac_RoleRef_To_v1beta1_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { + return err + } + return nil +} + +// Convert_rbac_ClusterRoleBinding_To_v1beta1_ClusterRoleBinding is an autogenerated conversion function. +func Convert_rbac_ClusterRoleBinding_To_v1beta1_ClusterRoleBinding(in *rbac.ClusterRoleBinding, out *ClusterRoleBinding, s conversion.Scope) error { + return autoConvert_rbac_ClusterRoleBinding_To_v1beta1_ClusterRoleBinding(in, out, s) +} + +func autoConvert_v1beta1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder(in *ClusterRoleBindingBuilder, out *rbac.ClusterRoleBindingBuilder, s conversion.Scope) error { + if err := Convert_v1beta1_ClusterRoleBinding_To_rbac_ClusterRoleBinding(&in.ClusterRoleBinding, &out.ClusterRoleBinding, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder is an autogenerated conversion function. +func Convert_v1beta1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder(in *ClusterRoleBindingBuilder, out *rbac.ClusterRoleBindingBuilder, s conversion.Scope) error { + return autoConvert_v1beta1_ClusterRoleBindingBuilder_To_rbac_ClusterRoleBindingBuilder(in, out, s) +} + +func autoConvert_rbac_ClusterRoleBindingBuilder_To_v1beta1_ClusterRoleBindingBuilder(in *rbac.ClusterRoleBindingBuilder, out *ClusterRoleBindingBuilder, s conversion.Scope) error { + if err := Convert_rbac_ClusterRoleBinding_To_v1beta1_ClusterRoleBinding(&in.ClusterRoleBinding, &out.ClusterRoleBinding, s); err != nil { + return err + } + return nil +} + +// Convert_rbac_ClusterRoleBindingBuilder_To_v1beta1_ClusterRoleBindingBuilder is an autogenerated conversion function. +func Convert_rbac_ClusterRoleBindingBuilder_To_v1beta1_ClusterRoleBindingBuilder(in *rbac.ClusterRoleBindingBuilder, out *ClusterRoleBindingBuilder, s conversion.Scope) error { + return autoConvert_rbac_ClusterRoleBindingBuilder_To_v1beta1_ClusterRoleBindingBuilder(in, out, s) +} + +func autoConvert_v1beta1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in *ClusterRoleBindingList, out *rbac.ClusterRoleBindingList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]rbac.ClusterRoleBinding)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1beta1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList is an autogenerated conversion function. +func Convert_v1beta1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in *ClusterRoleBindingList, out *rbac.ClusterRoleBindingList, s conversion.Scope) error { + return autoConvert_v1beta1_ClusterRoleBindingList_To_rbac_ClusterRoleBindingList(in, out, s) +} + +func autoConvert_rbac_ClusterRoleBindingList_To_v1beta1_ClusterRoleBindingList(in *rbac.ClusterRoleBindingList, out *ClusterRoleBindingList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]ClusterRoleBinding, 0) + } else { + out.Items = *(*[]ClusterRoleBinding)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_rbac_ClusterRoleBindingList_To_v1beta1_ClusterRoleBindingList is an autogenerated conversion function. +func Convert_rbac_ClusterRoleBindingList_To_v1beta1_ClusterRoleBindingList(in *rbac.ClusterRoleBindingList, out *ClusterRoleBindingList, s conversion.Scope) error { + return autoConvert_rbac_ClusterRoleBindingList_To_v1beta1_ClusterRoleBindingList(in, out, s) +} + +func autoConvert_v1beta1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRoleList, out *rbac.ClusterRoleList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]rbac.ClusterRole)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1beta1_ClusterRoleList_To_rbac_ClusterRoleList is an autogenerated conversion function. +func Convert_v1beta1_ClusterRoleList_To_rbac_ClusterRoleList(in *ClusterRoleList, out *rbac.ClusterRoleList, s conversion.Scope) error { + return autoConvert_v1beta1_ClusterRoleList_To_rbac_ClusterRoleList(in, out, s) +} + +func autoConvert_rbac_ClusterRoleList_To_v1beta1_ClusterRoleList(in *rbac.ClusterRoleList, out *ClusterRoleList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]ClusterRole, 0) + } else { + out.Items = *(*[]ClusterRole)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_rbac_ClusterRoleList_To_v1beta1_ClusterRoleList is an autogenerated conversion function. +func Convert_rbac_ClusterRoleList_To_v1beta1_ClusterRoleList(in *rbac.ClusterRoleList, out *ClusterRoleList, s conversion.Scope) error { + return autoConvert_rbac_ClusterRoleList_To_v1beta1_ClusterRoleList(in, out, s) +} + +func autoConvert_v1beta1_PolicyRule_To_rbac_PolicyRule(in *PolicyRule, out *rbac.PolicyRule, s conversion.Scope) error { + out.Verbs = *(*[]string)(unsafe.Pointer(&in.Verbs)) + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + out.ResourceNames = *(*[]string)(unsafe.Pointer(&in.ResourceNames)) + out.NonResourceURLs = *(*[]string)(unsafe.Pointer(&in.NonResourceURLs)) + return nil +} + +// Convert_v1beta1_PolicyRule_To_rbac_PolicyRule is an autogenerated conversion function. +func Convert_v1beta1_PolicyRule_To_rbac_PolicyRule(in *PolicyRule, out *rbac.PolicyRule, s conversion.Scope) error { + return autoConvert_v1beta1_PolicyRule_To_rbac_PolicyRule(in, out, s) +} + +func autoConvert_rbac_PolicyRule_To_v1beta1_PolicyRule(in *rbac.PolicyRule, out *PolicyRule, s conversion.Scope) error { + if in.Verbs == nil { + out.Verbs = make([]string, 0) + } else { + out.Verbs = *(*[]string)(unsafe.Pointer(&in.Verbs)) + } + out.APIGroups = *(*[]string)(unsafe.Pointer(&in.APIGroups)) + out.Resources = *(*[]string)(unsafe.Pointer(&in.Resources)) + out.ResourceNames = *(*[]string)(unsafe.Pointer(&in.ResourceNames)) + out.NonResourceURLs = *(*[]string)(unsafe.Pointer(&in.NonResourceURLs)) + return nil +} + +// Convert_rbac_PolicyRule_To_v1beta1_PolicyRule is an autogenerated conversion function. +func Convert_rbac_PolicyRule_To_v1beta1_PolicyRule(in *rbac.PolicyRule, out *PolicyRule, s conversion.Scope) error { + return autoConvert_rbac_PolicyRule_To_v1beta1_PolicyRule(in, out, s) +} + +func autoConvert_v1beta1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder(in *PolicyRuleBuilder, out *rbac.PolicyRuleBuilder, s conversion.Scope) error { + if err := Convert_v1beta1_PolicyRule_To_rbac_PolicyRule(&in.PolicyRule, &out.PolicyRule, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder is an autogenerated conversion function. +func Convert_v1beta1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder(in *PolicyRuleBuilder, out *rbac.PolicyRuleBuilder, s conversion.Scope) error { + return autoConvert_v1beta1_PolicyRuleBuilder_To_rbac_PolicyRuleBuilder(in, out, s) +} + +func autoConvert_rbac_PolicyRuleBuilder_To_v1beta1_PolicyRuleBuilder(in *rbac.PolicyRuleBuilder, out *PolicyRuleBuilder, s conversion.Scope) error { + if err := Convert_rbac_PolicyRule_To_v1beta1_PolicyRule(&in.PolicyRule, &out.PolicyRule, s); err != nil { + return err + } + return nil +} + +// Convert_rbac_PolicyRuleBuilder_To_v1beta1_PolicyRuleBuilder is an autogenerated conversion function. +func Convert_rbac_PolicyRuleBuilder_To_v1beta1_PolicyRuleBuilder(in *rbac.PolicyRuleBuilder, out *PolicyRuleBuilder, s conversion.Scope) error { + return autoConvert_rbac_PolicyRuleBuilder_To_v1beta1_PolicyRuleBuilder(in, out, s) +} + +func autoConvert_v1beta1_Role_To_rbac_Role(in *Role, out *rbac.Role, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Rules = *(*[]rbac.PolicyRule)(unsafe.Pointer(&in.Rules)) + return nil +} + +// Convert_v1beta1_Role_To_rbac_Role is an autogenerated conversion function. +func Convert_v1beta1_Role_To_rbac_Role(in *Role, out *rbac.Role, s conversion.Scope) error { + return autoConvert_v1beta1_Role_To_rbac_Role(in, out, s) +} + +func autoConvert_rbac_Role_To_v1beta1_Role(in *rbac.Role, out *Role, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if in.Rules == nil { + out.Rules = make([]PolicyRule, 0) + } else { + out.Rules = *(*[]PolicyRule)(unsafe.Pointer(&in.Rules)) + } + return nil +} + +// Convert_rbac_Role_To_v1beta1_Role is an autogenerated conversion function. +func Convert_rbac_Role_To_v1beta1_Role(in *rbac.Role, out *Role, s conversion.Scope) error { + return autoConvert_rbac_Role_To_v1beta1_Role(in, out, s) +} + +func autoConvert_v1beta1_RoleBinding_To_rbac_RoleBinding(in *RoleBinding, out *rbac.RoleBinding, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Subjects = *(*[]rbac.Subject)(unsafe.Pointer(&in.Subjects)) + if err := Convert_v1beta1_RoleRef_To_rbac_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { + return err + } + return nil +} + +// Convert_v1beta1_RoleBinding_To_rbac_RoleBinding is an autogenerated conversion function. +func Convert_v1beta1_RoleBinding_To_rbac_RoleBinding(in *RoleBinding, out *rbac.RoleBinding, s conversion.Scope) error { + return autoConvert_v1beta1_RoleBinding_To_rbac_RoleBinding(in, out, s) +} + +func autoConvert_rbac_RoleBinding_To_v1beta1_RoleBinding(in *rbac.RoleBinding, out *RoleBinding, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if in.Subjects == nil { + out.Subjects = make([]Subject, 0) + } else { + out.Subjects = *(*[]Subject)(unsafe.Pointer(&in.Subjects)) + } + if err := Convert_rbac_RoleRef_To_v1beta1_RoleRef(&in.RoleRef, &out.RoleRef, s); err != nil { + return err + } + return nil +} + +// Convert_rbac_RoleBinding_To_v1beta1_RoleBinding is an autogenerated conversion function. +func Convert_rbac_RoleBinding_To_v1beta1_RoleBinding(in *rbac.RoleBinding, out *RoleBinding, s conversion.Scope) error { + return autoConvert_rbac_RoleBinding_To_v1beta1_RoleBinding(in, out, s) +} + +func autoConvert_v1beta1_RoleBindingList_To_rbac_RoleBindingList(in *RoleBindingList, out *rbac.RoleBindingList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]rbac.RoleBinding)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1beta1_RoleBindingList_To_rbac_RoleBindingList is an autogenerated conversion function. +func Convert_v1beta1_RoleBindingList_To_rbac_RoleBindingList(in *RoleBindingList, out *rbac.RoleBindingList, s conversion.Scope) error { + return autoConvert_v1beta1_RoleBindingList_To_rbac_RoleBindingList(in, out, s) +} + +func autoConvert_rbac_RoleBindingList_To_v1beta1_RoleBindingList(in *rbac.RoleBindingList, out *RoleBindingList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]RoleBinding, 0) + } else { + out.Items = *(*[]RoleBinding)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_rbac_RoleBindingList_To_v1beta1_RoleBindingList is an autogenerated conversion function. +func Convert_rbac_RoleBindingList_To_v1beta1_RoleBindingList(in *rbac.RoleBindingList, out *RoleBindingList, s conversion.Scope) error { + return autoConvert_rbac_RoleBindingList_To_v1beta1_RoleBindingList(in, out, s) +} + +func autoConvert_v1beta1_RoleList_To_rbac_RoleList(in *RoleList, out *rbac.RoleList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]rbac.Role)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1beta1_RoleList_To_rbac_RoleList is an autogenerated conversion function. +func Convert_v1beta1_RoleList_To_rbac_RoleList(in *RoleList, out *rbac.RoleList, s conversion.Scope) error { + return autoConvert_v1beta1_RoleList_To_rbac_RoleList(in, out, s) +} + +func autoConvert_rbac_RoleList_To_v1beta1_RoleList(in *rbac.RoleList, out *RoleList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]Role, 0) + } else { + out.Items = *(*[]Role)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_rbac_RoleList_To_v1beta1_RoleList is an autogenerated conversion function. +func Convert_rbac_RoleList_To_v1beta1_RoleList(in *rbac.RoleList, out *RoleList, s conversion.Scope) error { + return autoConvert_rbac_RoleList_To_v1beta1_RoleList(in, out, s) +} + +func autoConvert_v1beta1_RoleRef_To_rbac_RoleRef(in *RoleRef, out *rbac.RoleRef, s conversion.Scope) error { + out.APIGroup = in.APIGroup + out.Kind = in.Kind + out.Name = in.Name + return nil +} + +// Convert_v1beta1_RoleRef_To_rbac_RoleRef is an autogenerated conversion function. +func Convert_v1beta1_RoleRef_To_rbac_RoleRef(in *RoleRef, out *rbac.RoleRef, s conversion.Scope) error { + return autoConvert_v1beta1_RoleRef_To_rbac_RoleRef(in, out, s) +} + +func autoConvert_rbac_RoleRef_To_v1beta1_RoleRef(in *rbac.RoleRef, out *RoleRef, s conversion.Scope) error { + out.APIGroup = in.APIGroup + out.Kind = in.Kind + out.Name = in.Name + return nil +} + +// Convert_rbac_RoleRef_To_v1beta1_RoleRef is an autogenerated conversion function. +func Convert_rbac_RoleRef_To_v1beta1_RoleRef(in *rbac.RoleRef, out *RoleRef, s conversion.Scope) error { + return autoConvert_rbac_RoleRef_To_v1beta1_RoleRef(in, out, s) +} + +func autoConvert_v1beta1_Subject_To_rbac_Subject(in *Subject, out *rbac.Subject, s conversion.Scope) error { + out.Kind = in.Kind + out.APIGroup = in.APIGroup + out.Name = in.Name + out.Namespace = in.Namespace + return nil +} + +// Convert_v1beta1_Subject_To_rbac_Subject is an autogenerated conversion function. +func Convert_v1beta1_Subject_To_rbac_Subject(in *Subject, out *rbac.Subject, s conversion.Scope) error { + return autoConvert_v1beta1_Subject_To_rbac_Subject(in, out, s) +} + +func autoConvert_rbac_Subject_To_v1beta1_Subject(in *rbac.Subject, out *Subject, s conversion.Scope) error { + out.Kind = in.Kind + out.APIGroup = in.APIGroup + out.Name = in.Name + out.Namespace = in.Namespace + return nil +} + +// Convert_rbac_Subject_To_v1beta1_Subject is an autogenerated conversion function. +func Convert_rbac_Subject_To_v1beta1_Subject(in *rbac.Subject, out *Subject, s conversion.Scope) error { + return autoConvert_rbac_Subject_To_v1beta1_Subject(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..57c331ea9b --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.deepcopy.go @@ -0,0 +1,269 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1beta1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ClusterRole, InType: reflect.TypeOf(&ClusterRole{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ClusterRoleBinding, InType: reflect.TypeOf(&ClusterRoleBinding{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ClusterRoleBindingList, InType: reflect.TypeOf(&ClusterRoleBindingList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_ClusterRoleList, InType: reflect.TypeOf(&ClusterRoleList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_PolicyRule, InType: reflect.TypeOf(&PolicyRule{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Role, InType: reflect.TypeOf(&Role{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RoleBinding, InType: reflect.TypeOf(&RoleBinding{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RoleBindingList, InType: reflect.TypeOf(&RoleBindingList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RoleList, InType: reflect.TypeOf(&RoleList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_RoleRef, InType: reflect.TypeOf(&RoleRef{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1beta1_Subject, InType: reflect.TypeOf(&Subject{})}, + ) +} + +// DeepCopy_v1beta1_ClusterRole is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ClusterRole(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ClusterRole) + out := out.(*ClusterRole) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]PolicyRule, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_PolicyRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_ClusterRoleBinding is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ClusterRoleBinding(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ClusterRoleBinding) + out := out.(*ClusterRoleBinding) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Subjects != nil { + in, out := &in.Subjects, &out.Subjects + *out = make([]Subject, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1beta1_ClusterRoleBindingList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ClusterRoleBindingList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ClusterRoleBindingList) + out := out.(*ClusterRoleBindingList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ClusterRoleBinding, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_ClusterRoleBinding(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_ClusterRoleList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_ClusterRoleList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*ClusterRoleList) + out := out.(*ClusterRoleList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]ClusterRole, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_ClusterRole(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_PolicyRule is an autogenerated deepcopy function. +func DeepCopy_v1beta1_PolicyRule(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PolicyRule) + out := out.(*PolicyRule) + *out = *in + if in.Verbs != nil { + in, out := &in.Verbs, &out.Verbs + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.APIGroups != nil { + in, out := &in.APIGroups, &out.APIGroups + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.Resources != nil { + in, out := &in.Resources, &out.Resources + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.ResourceNames != nil { + in, out := &in.ResourceNames, &out.ResourceNames + *out = make([]string, len(*in)) + copy(*out, *in) + } + if in.NonResourceURLs != nil { + in, out := &in.NonResourceURLs, &out.NonResourceURLs + *out = make([]string, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1beta1_Role is an autogenerated deepcopy function. +func DeepCopy_v1beta1_Role(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Role) + out := out.(*Role) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Rules != nil { + in, out := &in.Rules, &out.Rules + *out = make([]PolicyRule, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_PolicyRule(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_RoleBinding is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RoleBinding(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RoleBinding) + out := out.(*RoleBinding) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if in.Subjects != nil { + in, out := &in.Subjects, &out.Subjects + *out = make([]Subject, len(*in)) + copy(*out, *in) + } + return nil + } +} + +// DeepCopy_v1beta1_RoleBindingList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RoleBindingList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RoleBindingList) + out := out.(*RoleBindingList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]RoleBinding, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_RoleBinding(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_RoleList is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RoleList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RoleList) + out := out.(*RoleList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]Role, len(*in)) + for i := range *in { + if err := DeepCopy_v1beta1_Role(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1beta1_RoleRef is an autogenerated deepcopy function. +func DeepCopy_v1beta1_RoleRef(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*RoleRef) + out := out.(*RoleRef) + *out = *in + return nil + } +} + +// DeepCopy_v1beta1_Subject is an autogenerated deepcopy function. +func DeepCopy_v1beta1_Subject(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*Subject) + out := out.(*Subject) + *out = *in + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.defaults.go new file mode 100644 index 0000000000..fa5bfb6abb --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/v1beta1/zz_generated.defaults.go @@ -0,0 +1,66 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1beta1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&ClusterRoleBinding{}, func(obj interface{}) { SetObjectDefaults_ClusterRoleBinding(obj.(*ClusterRoleBinding)) }) + scheme.AddTypeDefaultingFunc(&ClusterRoleBindingList{}, func(obj interface{}) { SetObjectDefaults_ClusterRoleBindingList(obj.(*ClusterRoleBindingList)) }) + scheme.AddTypeDefaultingFunc(&RoleBinding{}, func(obj interface{}) { SetObjectDefaults_RoleBinding(obj.(*RoleBinding)) }) + scheme.AddTypeDefaultingFunc(&RoleBindingList{}, func(obj interface{}) { SetObjectDefaults_RoleBindingList(obj.(*RoleBindingList)) }) + return nil +} + +func SetObjectDefaults_ClusterRoleBinding(in *ClusterRoleBinding) { + SetDefaults_ClusterRoleBinding(in) + for i := range in.Subjects { + a := &in.Subjects[i] + SetDefaults_Subject(a) + } +} + +func SetObjectDefaults_ClusterRoleBindingList(in *ClusterRoleBindingList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_ClusterRoleBinding(a) + } +} + +func SetObjectDefaults_RoleBinding(in *RoleBinding) { + SetDefaults_RoleBinding(in) + for i := range in.Subjects { + a := &in.Subjects[i] + SetDefaults_Subject(a) + } +} + +func SetObjectDefaults_RoleBindingList(in *RoleBindingList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_RoleBinding(a) + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/rbac/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/rbac/zz_generated.deepcopy.go index 253c1517f1..ed8507e7f8 100644 --- a/vendor/k8s.io/client-go/pkg/apis/rbac/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/rbac/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package rbac import ( - api "k8s.io/client-go/pkg/api" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -49,13 +49,16 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_rbac_ClusterRole is an autogenerated deepcopy function. func DeepCopy_rbac_ClusterRole(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRole) out := out.(*ClusterRole) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Rules != nil { in, out := &in.Rules, &out.Rules @@ -65,41 +68,37 @@ func DeepCopy_rbac_ClusterRole(in interface{}, out interface{}, c *conversion.Cl return err } } - } else { - out.Rules = nil } return nil } } +// DeepCopy_rbac_ClusterRoleBinding is an autogenerated deepcopy function. func DeepCopy_rbac_ClusterRoleBinding(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRoleBinding) out := out.(*ClusterRoleBinding) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Subjects != nil { in, out := &in.Subjects, &out.Subjects *out = make([]Subject, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Subjects = nil + copy(*out, *in) } - out.RoleRef = in.RoleRef return nil } } +// DeepCopy_rbac_ClusterRoleBindingList is an autogenerated deepcopy function. func DeepCopy_rbac_ClusterRoleBindingList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRoleBindingList) out := out.(*ClusterRoleBindingList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ClusterRoleBinding, len(*in)) @@ -108,19 +107,17 @@ func DeepCopy_rbac_ClusterRoleBindingList(in interface{}, out interface{}, c *co return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_rbac_ClusterRoleList is an autogenerated deepcopy function. func DeepCopy_rbac_ClusterRoleList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*ClusterRoleList) out := out.(*ClusterRoleList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]ClusterRole, len(*in)) @@ -129,70 +126,56 @@ func DeepCopy_rbac_ClusterRoleList(in interface{}, out interface{}, c *conversio return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_rbac_PolicyRule is an autogenerated deepcopy function. func DeepCopy_rbac_PolicyRule(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*PolicyRule) out := out.(*PolicyRule) + *out = *in if in.Verbs != nil { in, out := &in.Verbs, &out.Verbs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Verbs = nil - } - if in.AttributeRestrictions == nil { - out.AttributeRestrictions = nil - } else if newVal, err := c.DeepCopy(&in.AttributeRestrictions); err != nil { - return err - } else { - out.AttributeRestrictions = *newVal.(*runtime.Object) } if in.APIGroups != nil { in, out := &in.APIGroups, &out.APIGroups *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.APIGroups = nil } if in.Resources != nil { in, out := &in.Resources, &out.Resources *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.Resources = nil } if in.ResourceNames != nil { in, out := &in.ResourceNames, &out.ResourceNames *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.ResourceNames = nil } if in.NonResourceURLs != nil { in, out := &in.NonResourceURLs, &out.NonResourceURLs *out = make([]string, len(*in)) copy(*out, *in) - } else { - out.NonResourceURLs = nil } return nil } } +// DeepCopy_rbac_Role is an autogenerated deepcopy function. func DeepCopy_rbac_Role(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Role) out := out.(*Role) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Rules != nil { in, out := &in.Rules, &out.Rules @@ -202,41 +185,37 @@ func DeepCopy_rbac_Role(in interface{}, out interface{}, c *conversion.Cloner) e return err } } - } else { - out.Rules = nil } return nil } } +// DeepCopy_rbac_RoleBinding is an autogenerated deepcopy function. func DeepCopy_rbac_RoleBinding(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleBinding) out := out.(*RoleBinding) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } if in.Subjects != nil { in, out := &in.Subjects, &out.Subjects *out = make([]Subject, len(*in)) - for i := range *in { - (*out)[i] = (*in)[i] - } - } else { - out.Subjects = nil + copy(*out, *in) } - out.RoleRef = in.RoleRef return nil } } +// DeepCopy_rbac_RoleBindingList is an autogenerated deepcopy function. func DeepCopy_rbac_RoleBindingList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleBindingList) out := out.(*RoleBindingList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]RoleBinding, len(*in)) @@ -245,19 +224,17 @@ func DeepCopy_rbac_RoleBindingList(in interface{}, out interface{}, c *conversio return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_rbac_RoleList is an autogenerated deepcopy function. func DeepCopy_rbac_RoleList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleList) out := out.(*RoleList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]Role, len(*in)) @@ -266,32 +243,27 @@ func DeepCopy_rbac_RoleList(in interface{}, out interface{}, c *conversion.Clone return err } } - } else { - out.Items = nil } return nil } } +// DeepCopy_rbac_RoleRef is an autogenerated deepcopy function. func DeepCopy_rbac_RoleRef(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*RoleRef) out := out.(*RoleRef) - out.APIGroup = in.APIGroup - out.Kind = in.Kind - out.Name = in.Name + *out = *in return nil } } +// DeepCopy_rbac_Subject is an autogenerated deepcopy function. func DeepCopy_rbac_Subject(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*Subject) out := out.(*Subject) - out.Kind = in.Kind - out.APIVersion = in.APIVersion - out.Name = in.Name - out.Namespace = in.Namespace + *out = *in return nil } } diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/BUILD b/vendor/k8s.io/client-go/pkg/apis/settings/BUILD new file mode 100644 index 0000000000..f0ff3f2ce1 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/BUILD @@ -0,0 +1,26 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/labels/doc.go b/vendor/k8s.io/client-go/pkg/apis/settings/doc.go similarity index 87% rename from vendor/k8s.io/client-go/pkg/util/labels/doc.go rename to vendor/k8s.io/client-go/pkg/apis/settings/doc.go index c87305fb09..90ccf882a2 100644 --- a/vendor/k8s.io/client-go/pkg/util/labels/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/settings/doc.go @@ -14,5 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// Package labels provides utilities to work with Kubernetes labels. -package labels +// +groupName=settings.k8s.io +package settings diff --git a/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/settings/register.go similarity index 57% rename from vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/register.go rename to vendor/k8s.io/client-go/pkg/apis/settings/register.go index 5317fdcfd1..8584701279 100644 --- a/vendor/k8s.io/client-go/pkg/apis/policy/v1alpha1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/settings/register.go @@ -1,5 +1,5 @@ /* -Copyright 2015 The Kubernetes Authors. +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. @@ -14,37 +14,39 @@ See the License for the specific language governing permissions and limitations under the License. */ -package v1alpha1 +package settings import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) -// GroupName is the group name use in this package -const GroupName = "policy" - -// SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1alpha1"} - var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme ) +// GroupName is the group name use in this package +const GroupName = "settings.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} + +// Kind takes an unqualified kind and returns a Group qualified GroupKind +func Kind(kind string) schema.GroupKind { + return SchemeGroupVersion.WithKind(kind).GroupKind() +} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &PodDisruptionBudget{}, - &PodDisruptionBudgetList{}, - &Eviction{}, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, + &PodPreset{}, + &PodPresetList{}, ) - // Add the watch version that applies - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/types.go b/vendor/k8s.io/client-go/pkg/apis/settings/types.go new file mode 100644 index 0000000000..b0589eedf7 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/types.go @@ -0,0 +1,63 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package settings + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/pkg/api" +) + +// +genclient=true + +// PodPreset is a policy resource that defines additional runtime +// requirements for a Pod. +type PodPreset struct { + metav1.TypeMeta + // +optional + metav1.ObjectMeta + + // +optional + Spec PodPresetSpec +} + +// PodPresetSpec is a description of a pod preset. +type PodPresetSpec struct { + // Selector is a label query over a set of resources, in this case pods. + // Required. + Selector metav1.LabelSelector + // Env defines the collection of EnvVar to inject into containers. + // +optional + Env []api.EnvVar + // EnvFrom defines the collection of EnvFromSource to inject into containers. + // +optional + EnvFrom []api.EnvFromSource + // Volumes defines the collection of Volume to inject into the pod. + // +optional + Volumes []api.Volume + // VolumeMounts defines the collection of VolumeMount to inject into containers. + // +optional + VolumeMounts []api.VolumeMount +} + +// PodPresetList is a list of PodPreset objects. +type PodPresetList struct { + metav1.TypeMeta + // +optional + metav1.ListMeta + + Items []PodPreset +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/BUILD b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/BUILD new file mode 100644 index 0000000000..31b65cc669 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/BUILD @@ -0,0 +1,33 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated.pb.go", + "register.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/api:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/settings:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/doc.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/doc.go new file mode 100644 index 0000000000..86390b5237 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=settings.k8s.io +package v1alpha1 diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go new file mode 100644 index 0000000000..64b15b1d22 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.pb.go @@ -0,0 +1,929 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/settings/v1alpha1/generated.proto +// DO NOT EDIT! + +/* + Package v1alpha1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/settings/v1alpha1/generated.proto + + It has these top-level messages: + PodPreset + PodPresetList + PodPresetSpec +*/ +package v1alpha1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import k8s_io_kubernetes_pkg_api_v1 "k8s.io/client-go/pkg/api/v1" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *PodPreset) Reset() { *m = PodPreset{} } +func (*PodPreset) ProtoMessage() {} +func (*PodPreset) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *PodPresetList) Reset() { *m = PodPresetList{} } +func (*PodPresetList) ProtoMessage() {} +func (*PodPresetList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func (m *PodPresetSpec) Reset() { *m = PodPresetSpec{} } +func (*PodPresetSpec) ProtoMessage() {} +func (*PodPresetSpec) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{2} } + +func init() { + proto.RegisterType((*PodPreset)(nil), "k8s.io.client-go.pkg.apis.settings.v1alpha1.PodPreset") + proto.RegisterType((*PodPresetList)(nil), "k8s.io.client-go.pkg.apis.settings.v1alpha1.PodPresetList") + proto.RegisterType((*PodPresetSpec)(nil), "k8s.io.client-go.pkg.apis.settings.v1alpha1.PodPresetSpec") +} +func (m *PodPreset) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodPreset) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Spec.Size())) + n2, err := m.Spec.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + return i, nil +} + +func (m *PodPresetList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodPresetList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n3, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n3 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func (m *PodPresetSpec) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *PodPresetSpec) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.Selector.Size())) + n4, err := m.Selector.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n4 + if len(m.Env) > 0 { + for _, msg := range m.Env { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.EnvFrom) > 0 { + for _, msg := range m.EnvFrom { + dAtA[i] = 0x1a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.Volumes) > 0 { + for _, msg := range m.Volumes { + dAtA[i] = 0x22 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + if len(m.VolumeMounts) > 0 { + for _, msg := range m.VolumeMounts { + dAtA[i] = 0x2a + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *PodPreset) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = m.Spec.Size() + n += 1 + l + sovGenerated(uint64(l)) + return n +} + +func (m *PodPresetList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func (m *PodPresetSpec) Size() (n int) { + var l int + _ = l + l = m.Selector.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Env) > 0 { + for _, e := range m.Env { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.EnvFrom) > 0 { + for _, e := range m.EnvFrom { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.Volumes) > 0 { + for _, e := range m.Volumes { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + if len(m.VolumeMounts) > 0 { + for _, e := range m.VolumeMounts { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *PodPreset) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodPreset{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Spec:` + strings.Replace(strings.Replace(this.Spec.String(), "PodPresetSpec", "PodPresetSpec", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PodPresetList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodPresetList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "PodPreset", "PodPreset", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func (this *PodPresetSpec) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&PodPresetSpec{`, + `Selector:` + strings.Replace(strings.Replace(this.Selector.String(), "LabelSelector", "k8s_io_apimachinery_pkg_apis_meta_v1.LabelSelector", 1), `&`, ``, 1) + `,`, + `Env:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Env), "EnvVar", "k8s_io_kubernetes_pkg_api_v1.EnvVar", 1), `&`, ``, 1) + `,`, + `EnvFrom:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.EnvFrom), "EnvFromSource", "k8s_io_kubernetes_pkg_api_v1.EnvFromSource", 1), `&`, ``, 1) + `,`, + `Volumes:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Volumes), "Volume", "k8s_io_kubernetes_pkg_api_v1.Volume", 1), `&`, ``, 1) + `,`, + `VolumeMounts:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.VolumeMounts), "VolumeMount", "k8s_io_kubernetes_pkg_api_v1.VolumeMount", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *PodPreset) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodPreset: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodPreset: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Spec", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Spec.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodPresetList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodPresetList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodPresetList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, PodPreset{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *PodPresetSpec) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: PodPresetSpec: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: PodPresetSpec: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Selector", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.Selector.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Env", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Env = append(m.Env, k8s_io_kubernetes_pkg_api_v1.EnvVar{}) + if err := m.Env[len(m.Env)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field EnvFrom", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.EnvFrom = append(m.EnvFrom, k8s_io_kubernetes_pkg_api_v1.EnvFromSource{}) + if err := m.EnvFrom[len(m.EnvFrom)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Volumes", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Volumes = append(m.Volumes, k8s_io_kubernetes_pkg_api_v1.Volume{}) + if err := m.Volumes[len(m.Volumes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field VolumeMounts", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.VolumeMounts = append(m.VolumeMounts, k8s_io_kubernetes_pkg_api_v1.VolumeMount{}) + if err := m.VolumeMounts[len(m.VolumeMounts)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 538 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x92, 0x41, 0x8b, 0xd3, 0x40, + 0x14, 0xc7, 0x9b, 0xed, 0x96, 0xd6, 0x69, 0x17, 0x25, 0x78, 0x08, 0x3d, 0x64, 0x97, 0xe2, 0x61, + 0xc5, 0x75, 0x62, 0x57, 0x51, 0x41, 0x4f, 0x91, 0x15, 0x04, 0x97, 0x5d, 0x52, 0xe8, 0x41, 0x56, + 0x70, 0x9a, 0x3e, 0xd3, 0xd8, 0x26, 0x13, 0x66, 0x26, 0x01, 0x6f, 0x7e, 0x04, 0xbf, 0x94, 0x50, + 0xd0, 0xc3, 0x1e, 0xf7, 0xb4, 0xd8, 0xf8, 0x45, 0x64, 0x26, 0x93, 0xa6, 0x52, 0xcb, 0x56, 0x6f, + 0xf3, 0x1e, 0xef, 0xff, 0x7b, 0xff, 0xff, 0x4b, 0xd0, 0xcb, 0xe9, 0x73, 0x8e, 0x43, 0xea, 0x4c, + 0xd3, 0x11, 0xb0, 0x18, 0x04, 0x70, 0x27, 0x99, 0x06, 0x0e, 0x49, 0x42, 0xee, 0x70, 0x10, 0x22, + 0x8c, 0x03, 0xee, 0x64, 0x7d, 0x32, 0x4b, 0x26, 0xa4, 0xef, 0x04, 0x10, 0x03, 0x23, 0x02, 0xc6, + 0x38, 0x61, 0x54, 0x50, 0xf3, 0xa8, 0x50, 0xe3, 0x4a, 0x8d, 0x93, 0x69, 0x80, 0xa5, 0x1a, 0x97, + 0x6a, 0x5c, 0xaa, 0xbb, 0x0f, 0x83, 0x50, 0x4c, 0xd2, 0x11, 0xf6, 0x69, 0xe4, 0x04, 0x34, 0xa0, + 0x8e, 0x82, 0x8c, 0xd2, 0x8f, 0xaa, 0x52, 0x85, 0x7a, 0x15, 0xf0, 0xee, 0x13, 0x6d, 0x8d, 0x24, + 0x61, 0x44, 0xfc, 0x49, 0x18, 0x03, 0xfb, 0x5c, 0x99, 0x8b, 0x40, 0x10, 0x27, 0x5b, 0xb3, 0xd4, + 0x75, 0x36, 0xa9, 0x58, 0x1a, 0x8b, 0x30, 0x82, 0x35, 0xc1, 0xd3, 0x9b, 0x04, 0xdc, 0x9f, 0x40, + 0x44, 0xd6, 0x74, 0x47, 0x1b, 0x2f, 0xf7, 0x17, 0x5b, 0xbd, 0x1f, 0x06, 0xba, 0x75, 0x4e, 0xc7, + 0xe7, 0x0c, 0x38, 0x08, 0xf3, 0x03, 0x6a, 0x49, 0xff, 0x63, 0x22, 0x88, 0x65, 0x1c, 0x18, 0x87, + 0xed, 0xe3, 0x47, 0x58, 0x9f, 0x72, 0xd5, 0x46, 0x75, 0x4c, 0x39, 0x8d, 0xb3, 0x3e, 0x3e, 0x1b, + 0x7d, 0x02, 0x5f, 0x9c, 0x82, 0x20, 0xae, 0x39, 0xbf, 0xde, 0xaf, 0xe5, 0xd7, 0xfb, 0xa8, 0xea, + 0x79, 0x4b, 0xaa, 0xf9, 0x1e, 0xed, 0xf2, 0x04, 0x7c, 0x6b, 0x47, 0xd1, 0x5f, 0xe0, 0x7f, 0xf9, + 0x50, 0x78, 0x69, 0x74, 0x90, 0x80, 0xef, 0x76, 0xf4, 0xa2, 0x5d, 0x59, 0x79, 0x0a, 0xdb, 0xfb, + 0x6e, 0xa0, 0xbd, 0xe5, 0xd4, 0xdb, 0x90, 0x0b, 0xf3, 0x62, 0x2d, 0x12, 0xde, 0x2e, 0x92, 0x54, + 0xab, 0x40, 0x77, 0xf4, 0x9e, 0x56, 0xd9, 0x59, 0x89, 0x73, 0x81, 0x1a, 0xa1, 0x80, 0x88, 0x5b, + 0x3b, 0x07, 0xf5, 0xc3, 0xf6, 0xf1, 0xb3, 0xff, 0xcc, 0xe3, 0xee, 0xe9, 0x1d, 0x8d, 0x37, 0x92, + 0xe6, 0x15, 0xd0, 0xde, 0xb7, 0xfa, 0x4a, 0x1a, 0x99, 0xd2, 0x24, 0xa8, 0xc5, 0x61, 0x06, 0xbe, + 0xa0, 0x4c, 0xa7, 0x79, 0xbc, 0x65, 0x1a, 0x32, 0x82, 0xd9, 0x40, 0x4b, 0xab, 0x48, 0x65, 0xc7, + 0x5b, 0x62, 0xcd, 0x57, 0xa8, 0x0e, 0x71, 0xa6, 0x03, 0xdd, 0xdb, 0x1c, 0x48, 0x52, 0x4f, 0xe2, + 0x6c, 0x48, 0x98, 0xdb, 0xd6, 0xb8, 0xfa, 0x49, 0x9c, 0x79, 0x52, 0x6d, 0x0e, 0x51, 0x13, 0xe2, + 0xec, 0x35, 0xa3, 0x91, 0x55, 0x57, 0xa0, 0x07, 0x37, 0x82, 0xe4, 0xf0, 0x80, 0xa6, 0xcc, 0x07, + 0xf7, 0xb6, 0xe6, 0x35, 0x75, 0xdb, 0x2b, 0x61, 0xe6, 0x19, 0x6a, 0x66, 0x74, 0x96, 0x46, 0xc0, + 0xad, 0xdd, 0x6d, 0x0c, 0x0e, 0xd5, 0x70, 0x05, 0x2c, 0x6a, 0xee, 0x95, 0x14, 0xd3, 0x47, 0x9d, + 0xe2, 0x79, 0x4a, 0xd3, 0x58, 0x70, 0xab, 0xa1, 0xa8, 0xf7, 0xb7, 0xa1, 0x2a, 0x85, 0x7b, 0x57, + 0xa3, 0x3b, 0x2b, 0x4d, 0xee, 0xfd, 0x01, 0x75, 0xf1, 0x7c, 0x61, 0xd7, 0x2e, 0x17, 0x76, 0xed, + 0x6a, 0x61, 0xd7, 0xbe, 0xe4, 0xb6, 0x31, 0xcf, 0x6d, 0xe3, 0x32, 0xb7, 0x8d, 0xab, 0xdc, 0x36, + 0x7e, 0xe6, 0xb6, 0xf1, 0xf5, 0x97, 0x5d, 0x7b, 0xd7, 0x2a, 0xff, 0x8b, 0xdf, 0x01, 0x00, 0x00, + 0xff, 0xff, 0x80, 0x75, 0x96, 0xb8, 0xfd, 0x04, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto new file mode 100644 index 0000000000..5b0c9e5cbc --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/generated.proto @@ -0,0 +1,75 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.settings.v1alpha1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1alpha1"; + +// PodPreset is a policy resource that defines additional runtime +// requirements for a Pod. +message PodPreset { + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // +optional + optional PodPresetSpec spec = 2; +} + +// PodPresetList is a list of PodPreset objects. +message PodPresetList { + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is a list of schema objects. + repeated PodPreset items = 2; +} + +// PodPresetSpec is a description of a pod preset. +message PodPresetSpec { + // Selector is a label query over a set of resources, in this case pods. + // Required. + optional k8s.io.apimachinery.pkg.apis.meta.v1.LabelSelector selector = 1; + + // Env defines the collection of EnvVar to inject into containers. + // +optional + repeated k8s.io.client_go.pkg.api.v1.EnvVar env = 2; + + // EnvFrom defines the collection of EnvFromSource to inject into containers. + // +optional + repeated k8s.io.client_go.pkg.api.v1.EnvFromSource envFrom = 3; + + // Volumes defines the collection of Volume to inject into the pod. + // +optional + repeated k8s.io.client_go.pkg.api.v1.Volume volumes = 4; + + // VolumeMounts defines the collection of VolumeMount to inject into containers. + // +optional + repeated k8s.io.client_go.pkg.api.v1.VolumeMount volumeMounts = 5; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/register.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/register.go new file mode 100644 index 0000000000..ddcd2259cb --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/register.go @@ -0,0 +1,59 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "settings.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, RegisterDefaults) +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &PodPreset{}, + &PodPresetList{}, + ) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types.go new file mode 100644 index 0000000000..0565f7c60a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types.go @@ -0,0 +1,67 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/client-go/pkg/api/v1" +) + +// +genclient=true + +// PodPreset is a policy resource that defines additional runtime +// requirements for a Pod. +type PodPreset struct { + metav1.TypeMeta `json:",inline"` + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // +optional + Spec PodPresetSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"` +} + +// PodPresetSpec is a description of a pod preset. +type PodPresetSpec struct { + // Selector is a label query over a set of resources, in this case pods. + // Required. + Selector metav1.LabelSelector `json:"selector,omitempty" protobuf:"bytes,1,opt,name=selector"` + + // Env defines the collection of EnvVar to inject into containers. + // +optional + Env []v1.EnvVar `json:"env,omitempty" protobuf:"bytes,2,rep,name=env"` + // EnvFrom defines the collection of EnvFromSource to inject into containers. + // +optional + EnvFrom []v1.EnvFromSource `json:"envFrom,omitempty" protobuf:"bytes,3,rep,name=envFrom"` + // Volumes defines the collection of Volume to inject into the pod. + // +optional + Volumes []v1.Volume `json:"volumes,omitempty" protobuf:"bytes,4,rep,name=volumes"` + // VolumeMounts defines the collection of VolumeMount to inject into containers. + // +optional + VolumeMounts []v1.VolumeMount `json:"volumeMounts,omitempty" protobuf:"bytes,5,rep,name=volumeMounts"` +} + +// PodPresetList is a list of PodPreset objects. +type PodPresetList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is a list of schema objects. + Items []PodPreset `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..2a89e5566d --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/types_swagger_doc_generated.go @@ -0,0 +1,61 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1alpha1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_PodPreset = map[string]string{ + "": "PodPreset is a policy resource that defines additional runtime requirements for a Pod.", +} + +func (PodPreset) SwaggerDoc() map[string]string { + return map_PodPreset +} + +var map_PodPresetList = map[string]string{ + "": "PodPresetList is a list of PodPreset objects.", + "metadata": "Standard list metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "Items is a list of schema objects.", +} + +func (PodPresetList) SwaggerDoc() map[string]string { + return map_PodPresetList +} + +var map_PodPresetSpec = map[string]string{ + "": "PodPresetSpec is a description of a pod preset.", + "selector": "Selector is a label query over a set of resources, in this case pods. Required.", + "env": "Env defines the collection of EnvVar to inject into containers.", + "envFrom": "EnvFrom defines the collection of EnvFromSource to inject into containers.", + "volumes": "Volumes defines the collection of Volume to inject into the pod.", + "volumeMounts": "VolumeMounts defines the collection of VolumeMount to inject into containers.", +} + +func (PodPresetSpec) SwaggerDoc() map[string]string { + return map_PodPresetSpec +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.conversion.go new file mode 100644 index 0000000000..4533018616 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.conversion.go @@ -0,0 +1,165 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1alpha1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + api "k8s.io/client-go/pkg/api" + v1 "k8s.io/client-go/pkg/api/v1" + settings "k8s.io/client-go/pkg/apis/settings" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1alpha1_PodPreset_To_settings_PodPreset, + Convert_settings_PodPreset_To_v1alpha1_PodPreset, + Convert_v1alpha1_PodPresetList_To_settings_PodPresetList, + Convert_settings_PodPresetList_To_v1alpha1_PodPresetList, + Convert_v1alpha1_PodPresetSpec_To_settings_PodPresetSpec, + Convert_settings_PodPresetSpec_To_v1alpha1_PodPresetSpec, + ) +} + +func autoConvert_v1alpha1_PodPreset_To_settings_PodPreset(in *PodPreset, out *settings.PodPreset, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_v1alpha1_PodPresetSpec_To_settings_PodPresetSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_v1alpha1_PodPreset_To_settings_PodPreset is an autogenerated conversion function. +func Convert_v1alpha1_PodPreset_To_settings_PodPreset(in *PodPreset, out *settings.PodPreset, s conversion.Scope) error { + return autoConvert_v1alpha1_PodPreset_To_settings_PodPreset(in, out, s) +} + +func autoConvert_settings_PodPreset_To_v1alpha1_PodPreset(in *settings.PodPreset, out *PodPreset, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + if err := Convert_settings_PodPresetSpec_To_v1alpha1_PodPresetSpec(&in.Spec, &out.Spec, s); err != nil { + return err + } + return nil +} + +// Convert_settings_PodPreset_To_v1alpha1_PodPreset is an autogenerated conversion function. +func Convert_settings_PodPreset_To_v1alpha1_PodPreset(in *settings.PodPreset, out *PodPreset, s conversion.Scope) error { + return autoConvert_settings_PodPreset_To_v1alpha1_PodPreset(in, out, s) +} + +func autoConvert_v1alpha1_PodPresetList_To_settings_PodPresetList(in *PodPresetList, out *settings.PodPresetList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]settings.PodPreset, len(*in)) + for i := range *in { + if err := Convert_v1alpha1_PodPreset_To_settings_PodPreset(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = nil + } + return nil +} + +// Convert_v1alpha1_PodPresetList_To_settings_PodPresetList is an autogenerated conversion function. +func Convert_v1alpha1_PodPresetList_To_settings_PodPresetList(in *PodPresetList, out *settings.PodPresetList, s conversion.Scope) error { + return autoConvert_v1alpha1_PodPresetList_To_settings_PodPresetList(in, out, s) +} + +func autoConvert_settings_PodPresetList_To_v1alpha1_PodPresetList(in *settings.PodPresetList, out *PodPresetList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]PodPreset, len(*in)) + for i := range *in { + if err := Convert_settings_PodPreset_To_v1alpha1_PodPreset(&(*in)[i], &(*out)[i], s); err != nil { + return err + } + } + } else { + out.Items = make([]PodPreset, 0) + } + return nil +} + +// Convert_settings_PodPresetList_To_v1alpha1_PodPresetList is an autogenerated conversion function. +func Convert_settings_PodPresetList_To_v1alpha1_PodPresetList(in *settings.PodPresetList, out *PodPresetList, s conversion.Scope) error { + return autoConvert_settings_PodPresetList_To_v1alpha1_PodPresetList(in, out, s) +} + +func autoConvert_v1alpha1_PodPresetSpec_To_settings_PodPresetSpec(in *PodPresetSpec, out *settings.PodPresetSpec, s conversion.Scope) error { + out.Selector = in.Selector + out.Env = *(*[]api.EnvVar)(unsafe.Pointer(&in.Env)) + out.EnvFrom = *(*[]api.EnvFromSource)(unsafe.Pointer(&in.EnvFrom)) + if in.Volumes != nil { + in, out := &in.Volumes, &out.Volumes + *out = make([]api.Volume, len(*in)) + for i := range *in { + // TODO: Inefficient conversion - can we improve it? + if err := s.Convert(&(*in)[i], &(*out)[i], 0); err != nil { + return err + } + } + } else { + out.Volumes = nil + } + out.VolumeMounts = *(*[]api.VolumeMount)(unsafe.Pointer(&in.VolumeMounts)) + return nil +} + +// Convert_v1alpha1_PodPresetSpec_To_settings_PodPresetSpec is an autogenerated conversion function. +func Convert_v1alpha1_PodPresetSpec_To_settings_PodPresetSpec(in *PodPresetSpec, out *settings.PodPresetSpec, s conversion.Scope) error { + return autoConvert_v1alpha1_PodPresetSpec_To_settings_PodPresetSpec(in, out, s) +} + +func autoConvert_settings_PodPresetSpec_To_v1alpha1_PodPresetSpec(in *settings.PodPresetSpec, out *PodPresetSpec, s conversion.Scope) error { + out.Selector = in.Selector + out.Env = *(*[]v1.EnvVar)(unsafe.Pointer(&in.Env)) + out.EnvFrom = *(*[]v1.EnvFromSource)(unsafe.Pointer(&in.EnvFrom)) + if in.Volumes != nil { + in, out := &in.Volumes, &out.Volumes + *out = make([]v1.Volume, len(*in)) + for i := range *in { + // TODO: Inefficient conversion - can we improve it? + if err := s.Convert(&(*in)[i], &(*out)[i], 0); err != nil { + return err + } + } + } else { + out.Volumes = nil + } + out.VolumeMounts = *(*[]v1.VolumeMount)(unsafe.Pointer(&in.VolumeMounts)) + return nil +} + +// Convert_settings_PodPresetSpec_To_v1alpha1_PodPresetSpec is an autogenerated conversion function. +func Convert_settings_PodPresetSpec_To_v1alpha1_PodPresetSpec(in *settings.PodPresetSpec, out *PodPresetSpec, s conversion.Scope) error { + return autoConvert_settings_PodPresetSpec_To_v1alpha1_PodPresetSpec(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..4f2e35494c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.deepcopy.go @@ -0,0 +1,127 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1alpha1 + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + api_v1 "k8s.io/client-go/pkg/api/v1" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_PodPreset, InType: reflect.TypeOf(&PodPreset{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_PodPresetList, InType: reflect.TypeOf(&PodPresetList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1alpha1_PodPresetSpec, InType: reflect.TypeOf(&PodPresetSpec{})}, + ) +} + +// DeepCopy_v1alpha1_PodPreset is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_PodPreset(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPreset) + out := out.(*PodPreset) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_v1alpha1_PodPresetSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_v1alpha1_PodPresetList is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_PodPresetList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPresetList) + out := out.(*PodPresetList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]PodPreset, len(*in)) + for i := range *in { + if err := DeepCopy_v1alpha1_PodPreset(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_v1alpha1_PodPresetSpec is an autogenerated deepcopy function. +func DeepCopy_v1alpha1_PodPresetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPresetSpec) + out := out.(*PodPresetSpec) + *out = *in + if newVal, err := c.DeepCopy(&in.Selector); err != nil { + return err + } else { + out.Selector = *newVal.(*v1.LabelSelector) + } + if in.Env != nil { + in, out := &in.Env, &out.Env + *out = make([]api_v1.EnvVar, len(*in)) + for i := range *in { + if err := api_v1.DeepCopy_v1_EnvVar(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.EnvFrom != nil { + in, out := &in.EnvFrom, &out.EnvFrom + *out = make([]api_v1.EnvFromSource, len(*in)) + for i := range *in { + if err := api_v1.DeepCopy_v1_EnvFromSource(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Volumes != nil { + in, out := &in.Volumes, &out.Volumes + *out = make([]api_v1.Volume, len(*in)) + for i := range *in { + if err := api_v1.DeepCopy_v1_Volume(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.VolumeMounts != nil { + in, out := &in.VolumeMounts, &out.VolumeMounts + *out = make([]api_v1.VolumeMount, len(*in)) + copy(*out, *in) + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.defaults.go new file mode 100644 index 0000000000..c178a3072c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/v1alpha1/zz_generated.defaults.go @@ -0,0 +1,98 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1alpha1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" + v1 "k8s.io/client-go/pkg/api/v1" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + scheme.AddTypeDefaultingFunc(&PodPreset{}, func(obj interface{}) { SetObjectDefaults_PodPreset(obj.(*PodPreset)) }) + scheme.AddTypeDefaultingFunc(&PodPresetList{}, func(obj interface{}) { SetObjectDefaults_PodPresetList(obj.(*PodPresetList)) }) + return nil +} + +func SetObjectDefaults_PodPreset(in *PodPreset) { + for i := range in.Spec.Env { + a := &in.Spec.Env[i] + if a.ValueFrom != nil { + if a.ValueFrom.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(a.ValueFrom.FieldRef) + } + } + } + for i := range in.Spec.Volumes { + a := &in.Spec.Volumes[i] + v1.SetDefaults_Volume(a) + if a.VolumeSource.Secret != nil { + v1.SetDefaults_SecretVolumeSource(a.VolumeSource.Secret) + } + if a.VolumeSource.ISCSI != nil { + v1.SetDefaults_ISCSIVolumeSource(a.VolumeSource.ISCSI) + } + if a.VolumeSource.RBD != nil { + v1.SetDefaults_RBDVolumeSource(a.VolumeSource.RBD) + } + if a.VolumeSource.DownwardAPI != nil { + v1.SetDefaults_DownwardAPIVolumeSource(a.VolumeSource.DownwardAPI) + for j := range a.VolumeSource.DownwardAPI.Items { + b := &a.VolumeSource.DownwardAPI.Items[j] + if b.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(b.FieldRef) + } + } + } + if a.VolumeSource.ConfigMap != nil { + v1.SetDefaults_ConfigMapVolumeSource(a.VolumeSource.ConfigMap) + } + if a.VolumeSource.AzureDisk != nil { + v1.SetDefaults_AzureDiskVolumeSource(a.VolumeSource.AzureDisk) + } + if a.VolumeSource.Projected != nil { + v1.SetDefaults_ProjectedVolumeSource(a.VolumeSource.Projected) + for j := range a.VolumeSource.Projected.Sources { + b := &a.VolumeSource.Projected.Sources[j] + if b.DownwardAPI != nil { + for k := range b.DownwardAPI.Items { + c := &b.DownwardAPI.Items[k] + if c.FieldRef != nil { + v1.SetDefaults_ObjectFieldSelector(c.FieldRef) + } + } + } + } + } + if a.VolumeSource.ScaleIO != nil { + v1.SetDefaults_ScaleIOVolumeSource(a.VolumeSource.ScaleIO) + } + } +} + +func SetObjectDefaults_PodPresetList(in *PodPresetList) { + for i := range in.Items { + a := &in.Items[i] + SetObjectDefaults_PodPreset(a) + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/settings/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/settings/zz_generated.deepcopy.go new file mode 100644 index 0000000000..2e475f7cea --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/settings/zz_generated.deepcopy.go @@ -0,0 +1,127 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package settings + +import ( + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + api "k8s.io/client-go/pkg/api" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_settings_PodPreset, InType: reflect.TypeOf(&PodPreset{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_settings_PodPresetList, InType: reflect.TypeOf(&PodPresetList{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_settings_PodPresetSpec, InType: reflect.TypeOf(&PodPresetSpec{})}, + ) +} + +// DeepCopy_settings_PodPreset is an autogenerated deepcopy function. +func DeepCopy_settings_PodPreset(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPreset) + out := out.(*PodPreset) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) + } + if err := DeepCopy_settings_PodPresetSpec(&in.Spec, &out.Spec, c); err != nil { + return err + } + return nil + } +} + +// DeepCopy_settings_PodPresetList is an autogenerated deepcopy function. +func DeepCopy_settings_PodPresetList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPresetList) + out := out.(*PodPresetList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]PodPreset, len(*in)) + for i := range *in { + if err := DeepCopy_settings_PodPreset(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} + +// DeepCopy_settings_PodPresetSpec is an autogenerated deepcopy function. +func DeepCopy_settings_PodPresetSpec(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*PodPresetSpec) + out := out.(*PodPresetSpec) + *out = *in + if newVal, err := c.DeepCopy(&in.Selector); err != nil { + return err + } else { + out.Selector = *newVal.(*v1.LabelSelector) + } + if in.Env != nil { + in, out := &in.Env, &out.Env + *out = make([]api.EnvVar, len(*in)) + for i := range *in { + if err := api.DeepCopy_api_EnvVar(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.EnvFrom != nil { + in, out := &in.EnvFrom, &out.EnvFrom + *out = make([]api.EnvFromSource, len(*in)) + for i := range *in { + if err := api.DeepCopy_api_EnvFromSource(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.Volumes != nil { + in, out := &in.Volumes, &out.Volumes + *out = make([]api.Volume, len(*in)) + for i := range *in { + if err := api.DeepCopy_api_Volume(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + if in.VolumeMounts != nil { + in, out := &in.VolumeMounts, &out.VolumeMounts + *out = make([]api.VolumeMount, len(*in)) + copy(*out, *in) + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/BUILD b/vendor/k8s.io/client-go/pkg/apis/storage/BUILD new file mode 100644 index 0000000000..6e2604388a --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/BUILD @@ -0,0 +1,25 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "register.go", + "types.go", + "zz_generated.deepcopy.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/OWNERS b/vendor/k8s.io/client-go/pkg/apis/storage/OWNERS new file mode 100755 index 0000000000..d59ed6e1d8 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/OWNERS @@ -0,0 +1,3 @@ +reviewers: +- deads2k +- mbohlool diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/doc.go b/vendor/k8s.io/client-go/pkg/apis/storage/doc.go index 0294d1350b..ef6d2a9bad 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/doc.go @@ -14,7 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register // +groupName=storage.k8s.io -// +g8k:openapi-gen=true package storage diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/install/install.go b/vendor/k8s.io/client-go/pkg/apis/storage/install/install.go deleted file mode 100644 index 4fc5ac7ed9..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/storage/install/install.go +++ /dev/null @@ -1,43 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package install installs the experimental API group, making it available as -// an option to all of the API encoding/decoding machinery. -package install - -import ( - "k8s.io/client-go/pkg/apimachinery/announced" - "k8s.io/client-go/pkg/apis/storage" - "k8s.io/client-go/pkg/apis/storage/v1beta1" - "k8s.io/client-go/pkg/util/sets" -) - -func init() { - if err := announced.NewGroupMetaFactory( - &announced.GroupMetaFactoryArgs{ - GroupName: storage.GroupName, - VersionPreferenceOrder: []string{v1beta1.SchemeGroupVersion.Version}, - ImportPrefix: "k8s.io/client-go/pkg/apis/storage", - RootScopedKinds: sets.NewString("StorageClass"), - AddInternalObjectsToScheme: storage.AddToScheme, - }, - announced.VersionToSchemeFunc{ - v1beta1.SchemeGroupVersion.Version: v1beta1.AddToScheme, - }, - ).Announce().RegisterAndEnable(); err != nil { - panic(err) - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/register.go b/vendor/k8s.io/client-go/pkg/apis/storage/register.go index a924b77587..aaa619b4d9 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/register.go @@ -17,24 +17,23 @@ limitations under the License. package storage import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "storage.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: runtime.APIVersionInternal} // Kind takes an unqualified kind and returns a Group qualified GroupKind -func Kind(kind string) unversioned.GroupKind { +func Kind(kind string) schema.GroupKind { return SchemeGroupVersion.WithKind(kind).GroupKind() } // Resource takes an unqualified resource and returns a Group qualified GroupResource -func Resource(resource string) unversioned.GroupResource { +func Resource(resource string) schema.GroupResource { return SchemeGroupVersion.WithResource(resource).GroupResource() } @@ -45,10 +44,6 @@ var ( func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &api.ListOptions{}, - &api.DeleteOptions{}, - &api.ExportOptions{}, - &StorageClass{}, &StorageClassList{}, ) diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/storage/types.generated.go deleted file mode 100644 index 9d8d7bf960..0000000000 --- a/vendor/k8s.io/client-go/pkg/apis/storage/types.generated.go +++ /dev/null @@ -1,900 +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 storage - -import ( - "errors" - "fmt" - codec1978 "github.com/ugorji/go/codec" - pkg2_api "k8s.io/client-go/pkg/api" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg3_types "k8s.io/client-go/pkg/types" - "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 pkg2_api.ObjectMeta - var v1 pkg1_unversioned.TypeMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 - } -} - -func (x *StorageClass) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym1 := z.EncBinary() - _ = yym1 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep2 := !z.EncBinary() - yy2arr2 := z.EncBasicHandle().StructToArray - var yyq2 [5]bool - _, _, _ = yysep2, yyq2, yy2arr2 - const yyr2 bool = false - yyq2[0] = x.Kind != "" - yyq2[1] = x.APIVersion != "" - yyq2[2] = true - yyq2[4] = len(x.Parameters) != 0 - var yynn2 int - if yyr2 || yy2arr2 { - r.EncodeArrayStart(5) - } else { - yynn2 = 1 - for _, b := range yyq2 { - if b { - yynn2++ - } - } - r.EncodeMapStart(yynn2) - yynn2 = 0 - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[0] { - yym4 := z.EncBinary() - _ = yym4 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym5 := z.EncBinary() - _ = yym5 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[1] { - yym7 := z.EncBinary() - _ = yym7 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq2[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym8 := z.EncBinary() - _ = yym8 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[2] { - yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) - } else { - r.EncodeNil() - } - } else { - if yyq2[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym13 := z.EncBinary() - _ = yym13 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Provisioner)) - } - } else { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("provisioner")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym14 := z.EncBinary() - _ = yym14 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Provisioner)) - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq2[4] { - if x.Parameters == nil { - r.EncodeNil() - } else { - yym16 := z.EncBinary() - _ = yym16 - if false { - } else { - z.F.EncMapStringStringV(x.Parameters, false, e) - } - } - } else { - r.EncodeNil() - } - } else { - if yyq2[4] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("parameters")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - if x.Parameters == nil { - r.EncodeNil() - } else { - yym17 := z.EncBinary() - _ = yym17 - if false { - } else { - z.F.EncMapStringStringV(x.Parameters, false, e) - } - } - } - } - if yyr2 || yy2arr2 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *StorageClass) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl19, d) - } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl19, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *StorageClass) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { - 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 = pkg2_api.ObjectMeta{} - } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) - } - case "provisioner": - if r.TryDecodeAsNil() { - x.Provisioner = "" - } else { - x.Provisioner = string(r.DecodeString()) - } - case "parameters": - if r.TryDecodeAsNil() { - x.Parameters = nil - } else { - yyv25 := &x.Parameters - yym26 := z.DecBinary() - _ = yym26 - if false { - } else { - z.F.DecMapStringStringX(yyv25, false, d) - } - } - default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *StorageClass) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj27 int - var yyb27 bool - var yyhl27 bool = l >= 0 - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l - } else { - yyb27 = r.CheckBreak() - } - if yyb27 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l - } else { - yyb27 = r.CheckBreak() - } - if yyb27 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l - } else { - yyb27 = r.CheckBreak() - } - if yyb27 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_api.ObjectMeta{} - } else { - yyv30 := &x.ObjectMeta - yyv30.CodecDecodeSelf(d) - } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l - } else { - yyb27 = r.CheckBreak() - } - if yyb27 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Provisioner = "" - } else { - x.Provisioner = string(r.DecodeString()) - } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l - } else { - yyb27 = r.CheckBreak() - } - if yyb27 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Parameters = nil - } else { - yyv32 := &x.Parameters - yym33 := z.DecBinary() - _ = yym33 - if false { - } else { - z.F.DecMapStringStringX(yyv32, false, d) - } - } - for { - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l - } else { - yyb27 = r.CheckBreak() - } - if yyb27 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj27-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x *StorageClassList) CodecEncodeSelf(e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - if x == nil { - r.EncodeNil() - } else { - yym34 := z.EncBinary() - _ = yym34 - if false { - } else if z.HasExtensions() && z.EncExt(x) { - } else { - yysep35 := !z.EncBinary() - yy2arr35 := z.EncBasicHandle().StructToArray - var yyq35 [4]bool - _, _, _ = yysep35, yyq35, yy2arr35 - const yyr35 bool = false - yyq35[0] = x.Kind != "" - yyq35[1] = x.APIVersion != "" - yyq35[2] = true - var yynn35 int - if yyr35 || yy2arr35 { - r.EncodeArrayStart(4) - } else { - yynn35 = 1 - for _, b := range yyq35 { - if b { - yynn35++ - } - } - r.EncodeMapStart(yynn35) - yynn35 = 0 - } - if yyr35 || yy2arr35 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq35[0] { - yym37 := z.EncBinary() - _ = yym37 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq35[0] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("kind")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym38 := z.EncBinary() - _ = yym38 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) - } - } - } - if yyr35 || yy2arr35 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq35[1] { - yym40 := z.EncBinary() - _ = yym40 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } else { - r.EncodeString(codecSelferC_UTF81234, "") - } - } else { - if yyq35[1] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym41 := z.EncBinary() - _ = yym41 - if false { - } else { - r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) - } - } - } - if yyr35 || yy2arr35 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq35[2] { - yy43 := &x.ListMeta - yym44 := z.EncBinary() - _ = yym44 - if false { - } else if z.HasExtensions() && z.EncExt(yy43) { - } else { - z.EncFallback(yy43) - } - } else { - r.EncodeNil() - } - } else { - if yyq35[2] { - z.EncSendContainerState(codecSelfer_containerMapKey1234) - r.EncodeString(codecSelferC_UTF81234, string("metadata")) - z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy45 := &x.ListMeta - yym46 := z.EncBinary() - _ = yym46 - if false { - } else if z.HasExtensions() && z.EncExt(yy45) { - } else { - z.EncFallback(yy45) - } - } - } - if yyr35 || yy2arr35 { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if x.Items == nil { - r.EncodeNil() - } else { - yym48 := z.EncBinary() - _ = yym48 - if false { - } else { - h.encSliceStorageClass(([]StorageClass)(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 { - yym49 := z.EncBinary() - _ = yym49 - if false { - } else { - h.encSliceStorageClass(([]StorageClass)(x.Items), e) - } - } - } - if yyr35 || yy2arr35 { - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - z.EncSendContainerState(codecSelfer_containerMapEnd1234) - } - } - } -} - -func (x *StorageClassList) CodecDecodeSelf(d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - yym50 := z.DecBinary() - _ = yym50 - if false { - } else if z.HasExtensions() && z.DecExt(x) { - } else { - yyct51 := r.ContainerType() - if yyct51 == codecSelferValueTypeMap1234 { - yyl51 := r.ReadMapStart() - if yyl51 == 0 { - z.DecSendContainerState(codecSelfer_containerMapEnd1234) - } else { - x.codecDecodeSelfFromMap(yyl51, d) - } - } else if yyct51 == codecSelferValueTypeArray1234 { - yyl51 := r.ReadArrayStart() - if yyl51 == 0 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - } else { - x.codecDecodeSelfFromArray(yyl51, d) - } - } else { - panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) - } - } -} - -func (x *StorageClassList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yys52Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys52Slc - var yyhl52 bool = l >= 0 - for yyj52 := 0; ; yyj52++ { - if yyhl52 { - if yyj52 >= l { - break - } - } else { - if r.CheckBreak() { - break - } - } - z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys52Slc = r.DecodeBytes(yys52Slc, true, true) - yys52 := string(yys52Slc) - z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys52 { - 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 = pkg1_unversioned.ListMeta{} - } else { - yyv55 := &x.ListMeta - yym56 := z.DecBinary() - _ = yym56 - if false { - } else if z.HasExtensions() && z.DecExt(yyv55) { - } else { - z.DecFallback(yyv55, false) - } - } - case "items": - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv57 := &x.Items - yym58 := z.DecBinary() - _ = yym58 - if false { - } else { - h.decSliceStorageClass((*[]StorageClass)(yyv57), d) - } - } - default: - z.DecStructFieldNotFound(-1, yys52) - } // end switch yys52 - } // end for yyj52 - z.DecSendContainerState(codecSelfer_containerMapEnd1234) -} - -func (x *StorageClassList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - var yyj59 int - var yyb59 bool - var yyhl59 bool = l >= 0 - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Kind = "" - } else { - x.Kind = string(r.DecodeString()) - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.APIVersion = "" - } else { - x.APIVersion = string(r.DecodeString()) - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} - } else { - yyv62 := &x.ListMeta - yym63 := z.DecBinary() - _ = yym63 - if false { - } else if z.HasExtensions() && z.DecExt(yyv62) { - } else { - z.DecFallback(yyv62, false) - } - } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) - return - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - if r.TryDecodeAsNil() { - x.Items = nil - } else { - yyv64 := &x.Items - yym65 := z.DecBinary() - _ = yym65 - if false { - } else { - h.decSliceStorageClass((*[]StorageClass)(yyv64), d) - } - } - for { - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l - } else { - yyb59 = r.CheckBreak() - } - if yyb59 { - break - } - z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj59-1, "") - } - z.DecSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) encSliceStorageClass(v []StorageClass, e *codec1978.Encoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperEncoder(e) - _, _, _ = h, z, r - r.EncodeArrayStart(len(v)) - for _, yyv66 := range v { - z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy67 := &yyv66 - yy67.CodecEncodeSelf(e) - } - z.EncSendContainerState(codecSelfer_containerArrayEnd1234) -} - -func (x codecSelfer1234) decSliceStorageClass(v *[]StorageClass, d *codec1978.Decoder) { - var h codecSelfer1234 - z, r := codec1978.GenHelperDecoder(d) - _, _, _ = h, z, r - - yyv68 := *v - yyh68, yyl68 := z.DecSliceHelperStart() - var yyc68 bool - if yyl68 == 0 { - if yyv68 == nil { - yyv68 = []StorageClass{} - yyc68 = true - } else if len(yyv68) != 0 { - yyv68 = yyv68[:0] - yyc68 = true - } - } else if yyl68 > 0 { - var yyrr68, yyrl68 int - var yyrt68 bool - if yyl68 > cap(yyv68) { - - yyrg68 := len(yyv68) > 0 - yyv268 := yyv68 - yyrl68, yyrt68 = z.DecInferLen(yyl68, z.DecBasicHandle().MaxInitLen, 280) - if yyrt68 { - if yyrl68 <= cap(yyv68) { - yyv68 = yyv68[:yyrl68] - } else { - yyv68 = make([]StorageClass, yyrl68) - } - } else { - yyv68 = make([]StorageClass, yyrl68) - } - yyc68 = true - yyrr68 = len(yyv68) - if yyrg68 { - copy(yyv68, yyv268) - } - } else if yyl68 != len(yyv68) { - yyv68 = yyv68[:yyl68] - yyc68 = true - } - yyj68 := 0 - for ; yyj68 < yyrr68; yyj68++ { - yyh68.ElemContainerState(yyj68) - if r.TryDecodeAsNil() { - yyv68[yyj68] = StorageClass{} - } else { - yyv69 := &yyv68[yyj68] - yyv69.CodecDecodeSelf(d) - } - - } - if yyrt68 { - for ; yyj68 < yyl68; yyj68++ { - yyv68 = append(yyv68, StorageClass{}) - yyh68.ElemContainerState(yyj68) - if r.TryDecodeAsNil() { - yyv68[yyj68] = StorageClass{} - } else { - yyv70 := &yyv68[yyj68] - yyv70.CodecDecodeSelf(d) - } - - } - } - - } else { - yyj68 := 0 - for ; !r.CheckBreak(); yyj68++ { - - if yyj68 >= len(yyv68) { - yyv68 = append(yyv68, StorageClass{}) // var yyz68 StorageClass - yyc68 = true - } - yyh68.ElemContainerState(yyj68) - if yyj68 < len(yyv68) { - if r.TryDecodeAsNil() { - yyv68[yyj68] = StorageClass{} - } else { - yyv71 := &yyv68[yyj68] - yyv71.CodecDecodeSelf(d) - } - - } else { - z.DecSwallow() - } - - } - if yyj68 < len(yyv68) { - yyv68 = yyv68[:yyj68] - yyc68 = true - } else if yyj68 == 0 && yyv68 == nil { - yyv68 = []StorageClass{} - yyc68 = true - } - } - yyh68.End() - if yyc68 { - *v = yyv68 - } -} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/types.go b/vendor/k8s.io/client-go/pkg/apis/storage/types.go index 4d4a18f60d..827e7c6665 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/types.go @@ -16,10 +16,7 @@ limitations under the License. package storage -import ( - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" -) +import metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" // +genclient=true // +nonNamespaced=true @@ -31,15 +28,15 @@ import ( // called "profiles" in other storage systems. // The name of a StorageClass object is significant, and is how users can request a particular class. type StorageClass struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // +optional - api.ObjectMeta `json:"metadata,omitempty"` + metav1.ObjectMeta // provisioner is the driver expected to handle this StorageClass. // This is an optionally-prefixed name, like a label key. // For example: "kubernetes.io/gce-pd" or "kubernetes.io/aws-ebs". // This value may not be empty. - Provisioner string `json:"provisioner"` + Provisioner string // parameters holds parameters for the provisioner. // These values are opaque to the system and are passed directly @@ -47,17 +44,17 @@ type StorageClass struct { // not empty. The maximum number of parameters is // 512, with a cumulative max size of 256K // +optional - Parameters map[string]string `json:"parameters,omitempty"` + Parameters map[string]string } // StorageClassList is a collection of storage classes. type StorageClassList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty"` + metav1.ListMeta // Items is the list of StorageClasses - Items []StorageClass `json:"items"` + Items []StorageClass } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/BUILD b/vendor/k8s.io/client-go/pkg/apis/storage/v1/BUILD new file mode 100644 index 0000000000..7f0ecf24df --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/BUILD @@ -0,0 +1,32 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated.pb.go", + "register.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/storage:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/doc.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/doc.go new file mode 100644 index 0000000000..2b8d05cfd5 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/doc.go @@ -0,0 +1,18 @@ +/* +Copyright 2017 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. +*/ + +// +groupName=storage.k8s.io +package v1 diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go new file mode 100644 index 0000000000..cc241c5b08 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.pb.go @@ -0,0 +1,746 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Code generated by protoc-gen-gogo. +// source: k8s.io/kubernetes/pkg/apis/storage/v1/generated.proto +// DO NOT EDIT! + +/* + Package v1 is a generated protocol buffer package. + + It is generated from these files: + k8s.io/kubernetes/pkg/apis/storage/v1/generated.proto + + It has these top-level messages: + StorageClass + StorageClassList +*/ +package v1 + +import proto "github.com/gogo/protobuf/proto" +import fmt "fmt" +import math "math" + +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + +import strings "strings" +import reflect "reflect" + +import io "io" + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package + +func (m *StorageClass) Reset() { *m = StorageClass{} } +func (*StorageClass) ProtoMessage() {} +func (*StorageClass) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } + +func (m *StorageClassList) Reset() { *m = StorageClassList{} } +func (*StorageClassList) ProtoMessage() {} +func (*StorageClassList) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{1} } + +func init() { + proto.RegisterType((*StorageClass)(nil), "k8s.io.client-go.pkg.apis.storage.v1.StorageClass") + proto.RegisterType((*StorageClassList)(nil), "k8s.io.client-go.pkg.apis.storage.v1.StorageClassList") +} +func (m *StorageClass) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StorageClass) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n1 + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provisioner))) + i += copy(dAtA[i:], m.Provisioner) + if len(m.Parameters) > 0 { + keysForParameters := make([]string, 0, len(m.Parameters)) + for k := range m.Parameters { + keysForParameters = append(keysForParameters, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForParameters) + for _, k := range keysForParameters { + dAtA[i] = 0x1a + i++ + v := m.Parameters[string(k)] + mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) + } + } + return i, nil +} + +func (m *StorageClassList) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *StorageClassList) MarshalTo(dAtA []byte) (int, error) { + var i int + _ = i + var l int + _ = l + dAtA[i] = 0xa + i++ + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n2, err := m.ListMeta.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n2 + if len(m.Items) > 0 { + for _, msg := range m.Items { + dAtA[i] = 0x12 + i++ + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) + if err != nil { + return 0, err + } + i += n + } + } + return i, nil +} + +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) + return offset + 8 +} +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + return offset + 4 +} +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return offset + 1 +} +func (m *StorageClass) Size() (n int) { + var l int + _ = l + l = m.ObjectMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + l = len(m.Provisioner) + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Parameters) > 0 { + for k, v := range m.Parameters { + _ = k + _ = v + mapEntrySize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) + n += mapEntrySize + 1 + sovGenerated(uint64(mapEntrySize)) + } + } + return n +} + +func (m *StorageClassList) Size() (n int) { + var l int + _ = l + l = m.ListMeta.Size() + n += 1 + l + sovGenerated(uint64(l)) + if len(m.Items) > 0 { + for _, e := range m.Items { + l = e.Size() + n += 1 + l + sovGenerated(uint64(l)) + } + } + return n +} + +func sovGenerated(x uint64) (n int) { + for { + n++ + x >>= 7 + if x == 0 { + break + } + } + return n +} +func sozGenerated(x uint64) (n int) { + return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (this *StorageClass) String() string { + if this == nil { + return "nil" + } + keysForParameters := make([]string, 0, len(this.Parameters)) + for k := range this.Parameters { + keysForParameters = append(keysForParameters, k) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForParameters) + mapStringForParameters := "map[string]string{" + for _, k := range keysForParameters { + mapStringForParameters += fmt.Sprintf("%v: %v,", k, this.Parameters[k]) + } + mapStringForParameters += "}" + s := strings.Join([]string{`&StorageClass{`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `Provisioner:` + fmt.Sprintf("%v", this.Provisioner) + `,`, + `Parameters:` + mapStringForParameters + `,`, + `}`, + }, "") + return s +} +func (this *StorageClassList) String() string { + if this == nil { + return "nil" + } + s := strings.Join([]string{`&StorageClassList{`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, + `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "StorageClass", "StorageClass", 1), `&`, ``, 1) + `,`, + `}`, + }, "") + return s +} +func valueToStringGenerated(v interface{}) string { + rv := reflect.ValueOf(v) + if rv.IsNil() { + return "nil" + } + pv := reflect.Indirect(rv).Interface() + return fmt.Sprintf("*%v", pv) +} +func (m *StorageClass) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StorageClass: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StorageClass: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ObjectMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Provisioner", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + intStringLen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Provisioner = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Parameters", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + var keykey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + keykey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + if m.Parameters == nil { + m.Parameters = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Parameters[mapkey] = mapvalue + } else { + var mapvalue string + m.Parameters[mapkey] = mapvalue + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *StorageClassList) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: StorageClassList: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: StorageClassList: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ListMeta", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Items", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthGenerated + } + postIndex := iNdEx + msglen + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Items = append(m.Items, StorageClass{}) + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipGenerated(dAtA[iNdEx:]) + if err != nil { + return err + } + if skippy < 0 { + return ErrInvalidLengthGenerated + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + return iNdEx, nil + case 1: + iNdEx += 8 + return iNdEx, nil + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + iNdEx += length + if length < 0 { + return 0, ErrInvalidLengthGenerated + } + return iNdEx, nil + case 3: + for { + var innerWire uint64 + var start int = iNdEx + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowGenerated + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + innerWire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + innerWireType := int(innerWire & 0x7) + if innerWireType == 4 { + break + } + next, err := skipGenerated(dAtA[start:]) + if err != nil { + return 0, err + } + iNdEx = start + next + } + return iNdEx, nil + case 4: + return iNdEx, nil + case 5: + iNdEx += 4 + return iNdEx, nil + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + } + panic("unreachable") +} + +var ( + ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") +) + +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/storage/v1/generated.proto", fileDescriptorGenerated) +} + +var fileDescriptorGenerated = []byte{ + // 460 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xcf, 0x6f, 0xd3, 0x30, + 0x14, 0xc7, 0xe3, 0x54, 0x95, 0x36, 0x17, 0x44, 0x15, 0x38, 0x54, 0x3d, 0x78, 0xd5, 0x24, 0xa4, + 0x5e, 0xb0, 0xe9, 0xc6, 0xd0, 0x84, 0xc4, 0xa5, 0x13, 0x07, 0x24, 0x10, 0x53, 0xb8, 0x20, 0xc4, + 0x01, 0xb7, 0x7b, 0xa4, 0x26, 0x4d, 0x1c, 0xd9, 0x2f, 0x41, 0xbd, 0xf1, 0x27, 0xf0, 0x67, 0x55, + 0x9c, 0x76, 0xdc, 0x69, 0xd0, 0xf0, 0x8f, 0xa0, 0xfc, 0x60, 0x89, 0x56, 0x26, 0x26, 0x6e, 0x7e, + 0xb6, 0x3f, 0x5f, 0xbf, 0xf7, 0x31, 0x3d, 0x0a, 0x8f, 0x2d, 0x57, 0x5a, 0x84, 0xe9, 0x0c, 0x4c, + 0x0c, 0x08, 0x56, 0x24, 0x61, 0x20, 0x64, 0xa2, 0xac, 0xb0, 0xa8, 0x8d, 0x0c, 0x40, 0x64, 0x13, + 0x11, 0x40, 0x0c, 0x46, 0x22, 0x9c, 0xf1, 0xc4, 0x68, 0xd4, 0xde, 0xc3, 0x0a, 0xe3, 0x0d, 0xc6, + 0x93, 0x30, 0xe0, 0x05, 0xc6, 0x6b, 0x8c, 0x67, 0x93, 0xe1, 0xa3, 0x40, 0xe1, 0x22, 0x9d, 0xf1, + 0xb9, 0x8e, 0x44, 0xa0, 0x03, 0x2d, 0x4a, 0x7a, 0x96, 0x7e, 0x2a, 0xab, 0xb2, 0x28, 0x57, 0x55, + 0xea, 0xf0, 0x49, 0xdd, 0x8c, 0x4c, 0x54, 0x24, 0xe7, 0x0b, 0x15, 0x83, 0x59, 0x35, 0xed, 0x44, + 0x80, 0xf2, 0x2f, 0xbd, 0x0c, 0xc5, 0x4d, 0x94, 0x49, 0x63, 0x54, 0x11, 0x6c, 0x01, 0x4f, 0xff, + 0x05, 0xd8, 0xf9, 0x02, 0x22, 0xb9, 0xc5, 0x1d, 0xde, 0xc4, 0xa5, 0xa8, 0x96, 0x42, 0xc5, 0x68, + 0xd1, 0x5c, 0x87, 0xf6, 0x7f, 0xb8, 0xf4, 0xce, 0xdb, 0xca, 0xc8, 0xc9, 0x52, 0x5a, 0xeb, 0x7d, + 0xa4, 0x3b, 0xc5, 0x24, 0x67, 0x12, 0xe5, 0x80, 0x8c, 0xc8, 0xb8, 0x77, 0xf0, 0x98, 0xd7, 0x36, + 0xdb, 0xc1, 0x8d, 0xcf, 0xe2, 0x36, 0xcf, 0x26, 0xfc, 0xcd, 0xec, 0x33, 0xcc, 0xf1, 0x35, 0xa0, + 0x9c, 0x7a, 0xeb, 0xcb, 0x3d, 0x27, 0xbf, 0xdc, 0xa3, 0xcd, 0x9e, 0x7f, 0x95, 0xea, 0x1d, 0xd1, + 0x5e, 0x62, 0x74, 0xa6, 0xac, 0xd2, 0x31, 0x98, 0x81, 0x3b, 0x22, 0xe3, 0xdd, 0xe9, 0xfd, 0x1a, + 0xe9, 0x9d, 0x36, 0x47, 0x7e, 0xfb, 0x9e, 0xf7, 0x85, 0xd2, 0x44, 0x1a, 0x19, 0x01, 0x82, 0xb1, + 0x83, 0xce, 0xa8, 0x33, 0xee, 0x1d, 0x9c, 0xf0, 0x5b, 0x7d, 0x34, 0x6f, 0x4f, 0xc8, 0x4f, 0xaf, + 0x52, 0x5e, 0xc4, 0x68, 0x56, 0x4d, 0xb7, 0xcd, 0x81, 0xdf, 0x7a, 0x6a, 0xf8, 0x9c, 0xde, 0xbb, + 0x86, 0x78, 0x7d, 0xda, 0x09, 0x61, 0x55, 0xfa, 0xd9, 0xf5, 0x8b, 0xa5, 0xf7, 0x80, 0x76, 0x33, + 0xb9, 0x4c, 0xa1, 0x1a, 0xc7, 0xaf, 0x8a, 0x67, 0xee, 0x31, 0xd9, 0xff, 0x4e, 0x68, 0xbf, 0xfd, + 0xfe, 0x2b, 0x65, 0xd1, 0xfb, 0xb0, 0x65, 0x99, 0xdf, 0xce, 0x72, 0x41, 0x97, 0x8e, 0xfb, 0x75, + 0xd7, 0x3b, 0x7f, 0x76, 0x5a, 0x86, 0xdf, 0xd1, 0xae, 0x42, 0x88, 0xec, 0xc0, 0x2d, 0x2d, 0x1d, + 0xfe, 0x87, 0xa5, 0xe9, 0xdd, 0x3a, 0xbf, 0xfb, 0xb2, 0x48, 0xf2, 0xab, 0xc0, 0xe9, 0x78, 0xbd, + 0x61, 0xce, 0xf9, 0x86, 0x39, 0x17, 0x1b, 0xe6, 0x7c, 0xcd, 0x19, 0x59, 0xe7, 0x8c, 0x9c, 0xe7, + 0x8c, 0x5c, 0xe4, 0x8c, 0xfc, 0xcc, 0x19, 0xf9, 0xf6, 0x8b, 0x39, 0xef, 0xdd, 0x6c, 0xf2, 0x3b, + 0x00, 0x00, 0xff, 0xff, 0x0b, 0xb7, 0x00, 0xe1, 0xba, 0x03, 0x00, 0x00, +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.proto new file mode 100644 index 0000000000..1a7849eaa8 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/generated.proto @@ -0,0 +1,62 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + + +// This file was autogenerated by go-to-protobuf. Do not edit it manually! + +syntax = 'proto2'; + +package k8s.io.client_go.pkg.apis.storage.v1; + +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; + +// Package-wide variables from generator "generated". +option go_package = "v1"; + +// StorageClass describes the parameters for a class of storage for +// which PersistentVolumes can be dynamically provisioned. +// +// StorageClasses are non-namespaced; the name of the storage class +// according to etcd is in ObjectMeta.Name. +message StorageClass { + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; + + // Provisioner indicates the type of the provisioner. + optional string provisioner = 2; + + // Parameters holds the parameters for the provisioner that should + // create volumes of this storage class. + // +optional + map parameters = 3; +} + +// StorageClassList is a collection of storage classes. +message StorageClassList { + // Standard list metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; + + // Items is the list of StorageClasses + repeated StorageClass items = 2; +} + diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/register.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/register.go new file mode 100644 index 0000000000..a727a9b206 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/register.go @@ -0,0 +1,60 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" +) + +// GroupName is the group name use in this package +const GroupName = "storage.k8s.io" + +// SchemeGroupVersion is group version used to register these objects +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} + +var ( + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme +) + +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, RegisterDefaults) +} + +// Adds the list of known types to api.Scheme. +func addKnownTypes(scheme *runtime.Scheme) error { + scheme.AddKnownTypes(SchemeGroupVersion, + &StorageClass{}, + &StorageClassList{}, + ) + + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/types.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/types.go new file mode 100644 index 0000000000..971db769e0 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/types.go @@ -0,0 +1,57 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +import ( + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" +) + +// +genclient=true +// +nonNamespaced=true + +// StorageClass describes the parameters for a class of storage for +// which PersistentVolumes can be dynamically provisioned. +// +// StorageClasses are non-namespaced; the name of the storage class +// according to etcd is in ObjectMeta.Name. +type StorageClass struct { + metav1.TypeMeta `json:",inline"` + // Standard object's metadata. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Provisioner indicates the type of the provisioner. + Provisioner string `json:"provisioner" protobuf:"bytes,2,opt,name=provisioner"` + + // Parameters holds the parameters for the provisioner that should + // create volumes of this storage class. + // +optional + Parameters map[string]string `json:"parameters,omitempty" protobuf:"bytes,3,rep,name=parameters"` +} + +// StorageClassList is a collection of storage classes. +type StorageClassList struct { + metav1.TypeMeta `json:",inline"` + // Standard list metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata + // +optional + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + + // Items is the list of StorageClasses + Items []StorageClass `json:"items" protobuf:"bytes,2,rep,name=items"` +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/types_swagger_doc_generated.go new file mode 100644 index 0000000000..a13106fa3c --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/types_swagger_doc_generated.go @@ -0,0 +1,51 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package v1 + +// This file contains a collection of methods that can be used from go-restful to +// generate Swagger API documentation for its models. Please read this PR for more +// information on the implementation: https://github.com/emicklei/go-restful/pull/215 +// +// TODOs are ignored from the parser (e.g. TODO(andronat):... || TODO:...) if and only if +// they are on one line! For multiple line or blocks that you want to ignore use ---. +// Any context after a --- is ignored. +// +// Those methods can be generated by using hack/update-generated-swagger-docs.sh + +// AUTO-GENERATED FUNCTIONS START HERE +var map_StorageClass = map[string]string{ + "": "StorageClass describes the parameters for a class of storage for which PersistentVolumes can be dynamically provisioned.\n\nStorageClasses are non-namespaced; the name of the storage class according to etcd is in ObjectMeta.Name.", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "provisioner": "Provisioner indicates the type of the provisioner.", + "parameters": "Parameters holds the parameters for the provisioner that should create volumes of this storage class.", +} + +func (StorageClass) SwaggerDoc() map[string]string { + return map_StorageClass +} + +var map_StorageClassList = map[string]string{ + "": "StorageClassList is a collection of storage classes.", + "metadata": "Standard list metadata More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", + "items": "Items is the list of StorageClasses", +} + +func (StorageClassList) SwaggerDoc() map[string]string { + return map_StorageClassList +} + +// AUTO-GENERATED FUNCTIONS END HERE diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.conversion.go new file mode 100644 index 0000000000..aac6bac295 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.conversion.go @@ -0,0 +1,93 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by conversion-gen. Do not edit it manually! + +package v1 + +import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + storage "k8s.io/client-go/pkg/apis/storage" + unsafe "unsafe" +) + +func init() { + SchemeBuilder.Register(RegisterConversions) +} + +// RegisterConversions adds conversion functions to the given scheme. +// Public to allow building arbitrary schemes. +func RegisterConversions(scheme *runtime.Scheme) error { + return scheme.AddGeneratedConversionFuncs( + Convert_v1_StorageClass_To_storage_StorageClass, + Convert_storage_StorageClass_To_v1_StorageClass, + Convert_v1_StorageClassList_To_storage_StorageClassList, + Convert_storage_StorageClassList_To_v1_StorageClassList, + ) +} + +func autoConvert_v1_StorageClass_To_storage_StorageClass(in *StorageClass, out *storage.StorageClass, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Provisioner = in.Provisioner + out.Parameters = *(*map[string]string)(unsafe.Pointer(&in.Parameters)) + return nil +} + +// Convert_v1_StorageClass_To_storage_StorageClass is an autogenerated conversion function. +func Convert_v1_StorageClass_To_storage_StorageClass(in *StorageClass, out *storage.StorageClass, s conversion.Scope) error { + return autoConvert_v1_StorageClass_To_storage_StorageClass(in, out, s) +} + +func autoConvert_storage_StorageClass_To_v1_StorageClass(in *storage.StorageClass, out *StorageClass, s conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + out.Provisioner = in.Provisioner + out.Parameters = *(*map[string]string)(unsafe.Pointer(&in.Parameters)) + return nil +} + +// Convert_storage_StorageClass_To_v1_StorageClass is an autogenerated conversion function. +func Convert_storage_StorageClass_To_v1_StorageClass(in *storage.StorageClass, out *StorageClass, s conversion.Scope) error { + return autoConvert_storage_StorageClass_To_v1_StorageClass(in, out, s) +} + +func autoConvert_v1_StorageClassList_To_storage_StorageClassList(in *StorageClassList, out *storage.StorageClassList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + out.Items = *(*[]storage.StorageClass)(unsafe.Pointer(&in.Items)) + return nil +} + +// Convert_v1_StorageClassList_To_storage_StorageClassList is an autogenerated conversion function. +func Convert_v1_StorageClassList_To_storage_StorageClassList(in *StorageClassList, out *storage.StorageClassList, s conversion.Scope) error { + return autoConvert_v1_StorageClassList_To_storage_StorageClassList(in, out, s) +} + +func autoConvert_storage_StorageClassList_To_v1_StorageClassList(in *storage.StorageClassList, out *StorageClassList, s conversion.Scope) error { + out.ListMeta = in.ListMeta + if in.Items == nil { + out.Items = make([]StorageClass, 0) + } else { + out.Items = *(*[]StorageClass)(unsafe.Pointer(&in.Items)) + } + return nil +} + +// Convert_storage_StorageClassList_To_v1_StorageClassList is an autogenerated conversion function. +func Convert_storage_StorageClassList_To_v1_StorageClassList(in *storage.StorageClassList, out *StorageClassList, s conversion.Scope) error { + return autoConvert_storage_StorageClassList_To_v1_StorageClassList(in, out, s) +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.deepcopy.go new file mode 100644 index 0000000000..649b354f25 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.deepcopy.go @@ -0,0 +1,82 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by deepcopy-gen. Do not edit it manually! + +package v1 + +import ( + meta_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" + reflect "reflect" +) + +func init() { + SchemeBuilder.Register(RegisterDeepCopies) +} + +// RegisterDeepCopies adds deep-copy functions to the given scheme. Public +// to allow building arbitrary schemes. +func RegisterDeepCopies(scheme *runtime.Scheme) error { + return scheme.AddGeneratedDeepCopyFuncs( + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_StorageClass, InType: reflect.TypeOf(&StorageClass{})}, + conversion.GeneratedDeepCopyFunc{Fn: DeepCopy_v1_StorageClassList, InType: reflect.TypeOf(&StorageClassList{})}, + ) +} + +// DeepCopy_v1_StorageClass is an autogenerated deepcopy function. +func DeepCopy_v1_StorageClass(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StorageClass) + out := out.(*StorageClass) + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { + return err + } else { + out.ObjectMeta = *newVal.(*meta_v1.ObjectMeta) + } + if in.Parameters != nil { + in, out := &in.Parameters, &out.Parameters + *out = make(map[string]string) + for key, val := range *in { + (*out)[key] = val + } + } + return nil + } +} + +// DeepCopy_v1_StorageClassList is an autogenerated deepcopy function. +func DeepCopy_v1_StorageClassList(in interface{}, out interface{}, c *conversion.Cloner) error { + { + in := in.(*StorageClassList) + out := out.(*StorageClassList) + *out = *in + if in.Items != nil { + in, out := &in.Items, &out.Items + *out = make([]StorageClass, len(*in)) + for i := range *in { + if err := DeepCopy_v1_StorageClass(&(*in)[i], &(*out)[i], c); err != nil { + return err + } + } + } + return nil + } +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.defaults.go new file mode 100644 index 0000000000..6df448eb9f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/BUILD b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/BUILD new file mode 100644 index 0000000000..65eff7879e --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "generated.pb.go", + "register.go", + "types.generated.go", + "types.go", + "types_swagger_doc_generated.go", + "zz_generated.conversion.go", + "zz_generated.deepcopy.go", + "zz_generated.defaults.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/gogo/protobuf/proto:go_default_library", + "//vendor/github.com/gogo/protobuf/sortkeys:go_default_library", + "//vendor/github.com/ugorji/go/codec:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/storage:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/doc.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/doc.go index a25066e966..3643217106 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/doc.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/doc.go @@ -14,9 +14,5 @@ See the License for the specific language governing permissions and limitations under the License. */ -// +k8s:deepcopy-gen=package,register -// +k8s:conversion-gen=k8s.io/kubernetes/pkg/apis/storage // +groupName=storage.k8s.io -// +k8s:openapi-gen=true -// +k8s:defaulter-gen=TypeMeta package v1beta1 diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go index 8ec0b14863..8f446c0bfd 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.pb.go @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -34,9 +34,10 @@ import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" +import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" + import strings "strings" import reflect "reflect" -import github_com_gogo_protobuf_sortkeys "github.com/gogo/protobuf/sortkeys" import io "io" @@ -47,7 +48,9 @@ var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package func (m *StorageClass) Reset() { *m = StorageClass{} } func (*StorageClass) ProtoMessage() {} @@ -61,82 +64,87 @@ func init() { proto.RegisterType((*StorageClass)(nil), "k8s.io.client-go.pkg.apis.storage.v1beta1.StorageClass") proto.RegisterType((*StorageClassList)(nil), "k8s.io.client-go.pkg.apis.storage.v1beta1.StorageClassList") } -func (m *StorageClass) Marshal() (data []byte, err error) { +func (m *StorageClass) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *StorageClass) MarshalTo(data []byte) (int, error) { +func (m *StorageClass) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ObjectMeta.Size())) - n1, err := m.ObjectMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ObjectMeta.Size())) + n1, err := m.ObjectMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n1 - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Provisioner))) - i += copy(data[i:], m.Provisioner) + i = encodeVarintGenerated(dAtA, i, uint64(len(m.Provisioner))) + i += copy(dAtA[i:], m.Provisioner) if len(m.Parameters) > 0 { + keysForParameters := make([]string, 0, len(m.Parameters)) for k := range m.Parameters { - data[i] = 0x1a + keysForParameters = append(keysForParameters, string(k)) + } + github_com_gogo_protobuf_sortkeys.Strings(keysForParameters) + for _, k := range keysForParameters { + dAtA[i] = 0x1a i++ - v := m.Parameters[k] + v := m.Parameters[string(k)] mapSize := 1 + len(k) + sovGenerated(uint64(len(k))) + 1 + len(v) + sovGenerated(uint64(len(v))) - i = encodeVarintGenerated(data, i, uint64(mapSize)) - data[i] = 0xa + i = encodeVarintGenerated(dAtA, i, uint64(mapSize)) + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(len(k))) - i += copy(data[i:], k) - data[i] = 0x12 + i = encodeVarintGenerated(dAtA, i, uint64(len(k))) + i += copy(dAtA[i:], k) + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(len(v))) - i += copy(data[i:], v) + i = encodeVarintGenerated(dAtA, i, uint64(len(v))) + i += copy(dAtA[i:], v) } } return i, nil } -func (m *StorageClassList) Marshal() (data []byte, err error) { +func (m *StorageClassList) Marshal() (dAtA []byte, err error) { size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) + dAtA = make([]byte, size) + n, err := m.MarshalTo(dAtA) if err != nil { return nil, err } - return data[:n], nil + return dAtA[:n], nil } -func (m *StorageClassList) MarshalTo(data []byte) (int, error) { +func (m *StorageClassList) MarshalTo(dAtA []byte) (int, error) { var i int _ = i var l int _ = l - data[i] = 0xa + dAtA[i] = 0xa i++ - i = encodeVarintGenerated(data, i, uint64(m.ListMeta.Size())) - n2, err := m.ListMeta.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(m.ListMeta.Size())) + n2, err := m.ListMeta.MarshalTo(dAtA[i:]) if err != nil { return 0, err } i += n2 if len(m.Items) > 0 { for _, msg := range m.Items { - data[i] = 0x12 + dAtA[i] = 0x12 i++ - i = encodeVarintGenerated(data, i, uint64(msg.Size())) - n, err := msg.MarshalTo(data[i:]) + i = encodeVarintGenerated(dAtA, i, uint64(msg.Size())) + n, err := msg.MarshalTo(dAtA[i:]) if err != nil { return 0, err } @@ -146,31 +154,31 @@ func (m *StorageClassList) MarshalTo(data []byte) (int, error) { return i, nil } -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) +func encodeFixed64Generated(dAtA []byte, offset int, v uint64) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) + dAtA[offset+4] = uint8(v >> 32) + dAtA[offset+5] = uint8(v >> 40) + dAtA[offset+6] = uint8(v >> 48) + dAtA[offset+7] = uint8(v >> 56) return offset + 8 } -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) +func encodeFixed32Generated(dAtA []byte, offset int, v uint32) int { + dAtA[offset] = uint8(v) + dAtA[offset+1] = uint8(v >> 8) + dAtA[offset+2] = uint8(v >> 16) + dAtA[offset+3] = uint8(v >> 24) return offset + 4 } -func encodeVarintGenerated(data []byte, offset int, v uint64) int { +func encodeVarintGenerated(dAtA []byte, offset int, v uint64) int { for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) + dAtA[offset] = uint8(v&0x7f | 0x80) v >>= 7 offset++ } - data[offset] = uint8(v) + dAtA[offset] = uint8(v) return offset + 1 } func (m *StorageClass) Size() (n int) { @@ -233,7 +241,7 @@ func (this *StorageClass) String() string { } mapStringForParameters += "}" s := strings.Join([]string{`&StorageClass{`, - `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_kubernetes_pkg_api_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, + `ObjectMeta:` + strings.Replace(strings.Replace(this.ObjectMeta.String(), "ObjectMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ObjectMeta", 1), `&`, ``, 1) + `,`, `Provisioner:` + fmt.Sprintf("%v", this.Provisioner) + `,`, `Parameters:` + mapStringForParameters + `,`, `}`, @@ -245,7 +253,7 @@ func (this *StorageClassList) String() string { return "nil" } s := strings.Join([]string{`&StorageClassList{`, - `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_kubernetes_pkg_api_unversioned.ListMeta", 1), `&`, ``, 1) + `,`, + `ListMeta:` + strings.Replace(strings.Replace(this.ListMeta.String(), "ListMeta", "k8s_io_apimachinery_pkg_apis_meta_v1.ListMeta", 1), `&`, ``, 1) + `,`, `Items:` + strings.Replace(strings.Replace(fmt.Sprintf("%v", this.Items), "StorageClass", "StorageClass", 1), `&`, ``, 1) + `,`, `}`, }, "") @@ -259,8 +267,8 @@ func valueToStringGenerated(v interface{}) string { pv := reflect.Indirect(rv).Interface() return fmt.Sprintf("*%v", pv) } -func (m *StorageClass) Unmarshal(data []byte) error { - l := len(data) +func (m *StorageClass) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -272,7 +280,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -300,7 +308,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -314,7 +322,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ObjectMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ObjectMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -330,7 +338,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLen |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -345,7 +353,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - m.Provisioner = string(data[iNdEx:postIndex]) + m.Provisioner = string(dAtA[iNdEx:postIndex]) iNdEx = postIndex case 3: if wireType != 2 { @@ -359,7 +367,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -381,7 +389,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ keykey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -396,7 +404,7 @@ func (m *StorageClass) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ stringLenmapkey |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -411,56 +419,61 @@ func (m *StorageClass) Unmarshal(data []byte) error { if postStringIndexmapkey > l { return io.ErrUnexpectedEOF } - mapkey := string(data[iNdEx:postStringIndexmapkey]) + mapkey := string(dAtA[iNdEx:postStringIndexmapkey]) iNdEx = postStringIndexmapkey - var valuekey uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF + if m.Parameters == nil { + m.Parameters = make(map[string]string) + } + if iNdEx < postIndex { + var valuekey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + valuekey |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - b := data[iNdEx] - iNdEx++ - valuekey |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowGenerated + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } } - } - var stringLenmapvalue uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return ErrInvalidLengthGenerated } - if iNdEx >= l { + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue > l { return io.ErrUnexpectedEOF } - b := data[iNdEx] - iNdEx++ - stringLenmapvalue |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLenmapvalue := int(stringLenmapvalue) - if intStringLenmapvalue < 0 { - return ErrInvalidLengthGenerated - } - postStringIndexmapvalue := iNdEx + intStringLenmapvalue - if postStringIndexmapvalue > l { - return io.ErrUnexpectedEOF + mapvalue := string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + m.Parameters[mapkey] = mapvalue + } else { + var mapvalue string + m.Parameters[mapkey] = mapvalue } - mapvalue := string(data[iNdEx:postStringIndexmapvalue]) - iNdEx = postStringIndexmapvalue - if m.Parameters == nil { - m.Parameters = make(map[string]string) - } - m.Parameters[mapkey] = mapvalue iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -479,8 +492,8 @@ func (m *StorageClass) Unmarshal(data []byte) error { } return nil } -func (m *StorageClassList) Unmarshal(data []byte) error { - l := len(data) +func (m *StorageClassList) Unmarshal(dAtA []byte) error { + l := len(dAtA) iNdEx := 0 for iNdEx < l { preIndex := iNdEx @@ -492,7 +505,7 @@ func (m *StorageClassList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -520,7 +533,7 @@ func (m *StorageClassList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -534,7 +547,7 @@ func (m *StorageClassList) Unmarshal(data []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - if err := m.ListMeta.Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.ListMeta.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex @@ -550,7 +563,7 @@ func (m *StorageClassList) Unmarshal(data []byte) error { if iNdEx >= l { return io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ msglen |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -565,13 +578,13 @@ func (m *StorageClassList) Unmarshal(data []byte) error { return io.ErrUnexpectedEOF } m.Items = append(m.Items, StorageClass{}) - if err := m.Items[len(m.Items)-1].Unmarshal(data[iNdEx:postIndex]); err != nil { + if err := m.Items[len(m.Items)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } iNdEx = postIndex default: iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) + skippy, err := skipGenerated(dAtA[iNdEx:]) if err != nil { return err } @@ -590,8 +603,8 @@ func (m *StorageClassList) Unmarshal(data []byte) error { } return nil } -func skipGenerated(data []byte) (n int, err error) { - l := len(data) +func skipGenerated(dAtA []byte) (n int, err error) { + l := len(dAtA) iNdEx := 0 for iNdEx < l { var wire uint64 @@ -602,7 +615,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ wire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -620,7 +633,7 @@ func skipGenerated(data []byte) (n int, err error) { return 0, io.ErrUnexpectedEOF } iNdEx++ - if data[iNdEx-1] < 0x80 { + if dAtA[iNdEx-1] < 0x80 { break } } @@ -637,7 +650,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ length |= (int(b) & 0x7F) << shift if b < 0x80 { @@ -660,7 +673,7 @@ func skipGenerated(data []byte) (n int, err error) { if iNdEx >= l { return 0, io.ErrUnexpectedEOF } - b := data[iNdEx] + b := dAtA[iNdEx] iNdEx++ innerWire |= (uint64(b) & 0x7F) << shift if b < 0x80 { @@ -671,7 +684,7 @@ func skipGenerated(data []byte) (n int, err error) { if innerWireType == 4 { break } - next, err := skipGenerated(data[start:]) + next, err := skipGenerated(dAtA[start:]) if err != nil { return 0, err } @@ -695,35 +708,40 @@ var ( ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") ) +func init() { + proto.RegisterFile("k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto", fileDescriptorGenerated) +} + var fileDescriptorGenerated = []byte{ - // 462 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x9c, 0x92, 0xcf, 0x8b, 0xd3, 0x40, - 0x14, 0xc7, 0x33, 0x2d, 0xc5, 0xdd, 0xa9, 0x62, 0x89, 0x1e, 0x4a, 0x0e, 0xd9, 0xb2, 0xa7, 0x2a, - 0xee, 0x0c, 0x2d, 0x2c, 0x94, 0x05, 0x2f, 0x15, 0x41, 0x41, 0x71, 0x89, 0x17, 0x11, 0xf6, 0x30, - 0x69, 0x9f, 0x71, 0x4c, 0x93, 0x09, 0x33, 0x2f, 0x81, 0x05, 0x0f, 0xfe, 0x09, 0xfe, 0x59, 0x3d, - 0xf6, 0xe8, 0x41, 0x16, 0x1b, 0xff, 0x11, 0x69, 0x12, 0x37, 0xa1, 0x3f, 0x44, 0xf6, 0x36, 0x6f, - 0xe6, 0x7d, 0xbe, 0xef, 0xfb, 0xbe, 0x0c, 0xbd, 0x08, 0x27, 0x86, 0x49, 0xc5, 0xc3, 0xd4, 0x07, - 0x1d, 0x03, 0x82, 0xe1, 0x49, 0x18, 0x70, 0x91, 0x48, 0xc3, 0x0d, 0x2a, 0x2d, 0x02, 0xe0, 0xd9, - 0xc8, 0x07, 0x14, 0x23, 0x1e, 0x40, 0x0c, 0x5a, 0x20, 0xcc, 0x59, 0xa2, 0x15, 0x2a, 0xfb, 0x69, - 0xc9, 0xb2, 0x9a, 0x65, 0x49, 0x18, 0xb0, 0x0d, 0xcb, 0x2a, 0x96, 0x55, 0xac, 0x73, 0x16, 0x48, - 0xfc, 0x9c, 0xfa, 0x6c, 0xa6, 0x22, 0x1e, 0xa8, 0x40, 0xf1, 0x42, 0xc2, 0x4f, 0x3f, 0x15, 0x55, - 0x51, 0x14, 0xa7, 0x52, 0xda, 0x19, 0x1f, 0xb4, 0xc5, 0x35, 0x18, 0x95, 0xea, 0x19, 0x6c, 0xdb, - 0x71, 0xce, 0x0f, 0x33, 0x69, 0x9c, 0x81, 0x36, 0x52, 0xc5, 0x30, 0xdf, 0xc1, 0x9e, 0x1d, 0xc6, - 0xb2, 0x9d, 0x9d, 0x9d, 0xb3, 0xfd, 0xdd, 0x3a, 0x8d, 0x51, 0x46, 0xbb, 0x9e, 0x46, 0xfb, 0xdb, - 0x53, 0x94, 0x0b, 0x2e, 0x63, 0x34, 0xa8, 0xb7, 0x91, 0xd3, 0x9f, 0x2d, 0x7a, 0xff, 0x7d, 0x99, - 0xde, 0x8b, 0x85, 0x30, 0xc6, 0xfe, 0x40, 0x8f, 0x22, 0x40, 0x31, 0x17, 0x28, 0xfa, 0x64, 0x40, - 0x86, 0xdd, 0xf1, 0x90, 0x1d, 0x4c, 0x9e, 0x65, 0x23, 0xf6, 0xce, 0xff, 0x02, 0x33, 0x7c, 0x0b, - 0x28, 0xa6, 0xf6, 0xf2, 0xe6, 0xc4, 0xca, 0x6f, 0x4e, 0x68, 0x7d, 0xe7, 0xdd, 0xaa, 0xd9, 0xe7, - 0xb4, 0x9b, 0x68, 0x95, 0xc9, 0x22, 0x19, 0xdd, 0x6f, 0x0d, 0xc8, 0xf0, 0x78, 0xfa, 0xa8, 0x42, - 0xba, 0x97, 0xf5, 0x93, 0xd7, 0xec, 0xb3, 0xbf, 0x52, 0x9a, 0x08, 0x2d, 0x22, 0x40, 0xd0, 0xa6, - 0xdf, 0x1e, 0xb4, 0x87, 0xdd, 0xf1, 0x2b, 0xf6, 0xff, 0x9f, 0x81, 0x35, 0xd7, 0x63, 0x97, 0xb7, - 0x52, 0x2f, 0x63, 0xd4, 0xd7, 0xb5, 0xe5, 0xfa, 0xc1, 0x6b, 0xcc, 0x73, 0x9e, 0xd3, 0x87, 0x5b, - 0x88, 0xdd, 0xa3, 0xed, 0x10, 0xae, 0x8b, 0x70, 0x8e, 0xbd, 0xcd, 0xd1, 0x7e, 0x4c, 0x3b, 0x99, - 0x58, 0xa4, 0x50, 0xee, 0xe4, 0x95, 0xc5, 0x45, 0x6b, 0x42, 0x4e, 0x57, 0x84, 0xf6, 0x9a, 0xf3, - 0xdf, 0x48, 0x83, 0xf6, 0xd5, 0x4e, 0xc4, 0xfc, 0x1f, 0x11, 0x37, 0x7e, 0x13, 0xdb, 0xe0, 0x45, - 0xd2, 0xbd, 0xca, 0xf6, 0xd1, 0xdf, 0x9b, 0x46, 0xce, 0x57, 0xb4, 0x23, 0x11, 0x22, 0xd3, 0x6f, - 0x15, 0x59, 0x4d, 0xee, 0x9a, 0xd5, 0xf4, 0x41, 0x35, 0xa4, 0xf3, 0x7a, 0x23, 0xe7, 0x95, 0xaa, - 0xd3, 0x27, 0xcb, 0xb5, 0x6b, 0xad, 0xd6, 0xae, 0xf5, 0x63, 0xed, 0x5a, 0xdf, 0x72, 0x97, 0x2c, - 0x73, 0x97, 0xac, 0x72, 0x97, 0xfc, 0xca, 0x5d, 0xf2, 0xfd, 0xb7, 0x6b, 0x7d, 0xbc, 0x57, 0xa9, - 0xfd, 0x09, 0x00, 0x00, 0xff, 0xff, 0x86, 0x21, 0xa9, 0x43, 0xef, 0x03, 0x00, 0x00, + // 466 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x9c, 0x91, 0xcf, 0x6b, 0x13, 0x41, + 0x14, 0xc7, 0x77, 0x52, 0x82, 0xed, 0x44, 0x31, 0xac, 0x1e, 0x42, 0x0e, 0xd3, 0xd0, 0x53, 0x10, + 0x3a, 0x63, 0xea, 0x0f, 0x42, 0xc1, 0x4b, 0x44, 0x50, 0x50, 0x2c, 0xeb, 0x4d, 0x14, 0x9c, 0x4d, + 0x9f, 0x9b, 0x71, 0xb3, 0x3b, 0xcb, 0xcc, 0xdb, 0x85, 0x80, 0x07, 0xff, 0x04, 0xff, 0xac, 0xdc, + 0xec, 0xb1, 0xa7, 0x62, 0x56, 0xff, 0x10, 0xd9, 0x1f, 0x76, 0x97, 0x86, 0x62, 0xf1, 0xb6, 0x6f, + 0x66, 0x3e, 0xdf, 0xf7, 0xde, 0x67, 0xe9, 0x71, 0x38, 0xb5, 0x5c, 0x69, 0x11, 0xa6, 0x3e, 0x98, + 0x18, 0x10, 0xac, 0x48, 0xc2, 0x40, 0xc8, 0x44, 0x59, 0x61, 0x51, 0x1b, 0x19, 0x80, 0xc8, 0x26, + 0x3e, 0xa0, 0x9c, 0x88, 0x00, 0x62, 0x30, 0x12, 0xe1, 0x94, 0x27, 0x46, 0xa3, 0x76, 0x1f, 0x54, + 0x2c, 0x6f, 0x58, 0x9e, 0x84, 0x01, 0x2f, 0x58, 0x5e, 0xb3, 0xbc, 0x66, 0x87, 0x87, 0x81, 0xc2, + 0x45, 0xea, 0xf3, 0xb9, 0x8e, 0x44, 0xa0, 0x03, 0x2d, 0xca, 0x08, 0x3f, 0xfd, 0x5c, 0x56, 0x65, + 0x51, 0x7e, 0x55, 0xd1, 0xc3, 0xc7, 0xf5, 0x58, 0x32, 0x51, 0x91, 0x9c, 0x2f, 0x54, 0x0c, 0x66, + 0xd5, 0x0c, 0x16, 0x01, 0x4a, 0x91, 0x6d, 0x0d, 0x34, 0x14, 0xd7, 0x51, 0x26, 0x8d, 0x51, 0x45, + 0xb0, 0x05, 0x3c, 0xfd, 0x17, 0x60, 0xe7, 0x0b, 0x88, 0xe4, 0x16, 0xf7, 0xe8, 0x3a, 0x2e, 0x45, + 0xb5, 0x14, 0x2a, 0x46, 0x8b, 0xe6, 0x2a, 0x74, 0xf0, 0xbb, 0x43, 0x6f, 0xbf, 0xab, 0xb4, 0x3c, + 0x5f, 0x4a, 0x6b, 0xdd, 0x4f, 0x74, 0xb7, 0xd8, 0xe4, 0x54, 0xa2, 0x1c, 0x90, 0x11, 0x19, 0xf7, + 0x8e, 0x1e, 0xf2, 0x5a, 0x69, 0x3b, 0xb8, 0x91, 0x5a, 0xbc, 0xe6, 0xd9, 0x84, 0xbf, 0xf5, 0xbf, + 0xc0, 0x1c, 0xdf, 0x00, 0xca, 0x99, 0xbb, 0xbe, 0xd8, 0x77, 0xf2, 0x8b, 0x7d, 0xda, 0x9c, 0x79, + 0x97, 0xa9, 0xee, 0x13, 0xda, 0x4b, 0x8c, 0xce, 0x94, 0x55, 0x3a, 0x06, 0x33, 0xe8, 0x8c, 0xc8, + 0x78, 0x6f, 0x76, 0xaf, 0x46, 0x7a, 0x27, 0xcd, 0x95, 0xd7, 0x7e, 0xe7, 0x7e, 0xa5, 0x34, 0x91, + 0x46, 0x46, 0x80, 0x60, 0xec, 0x60, 0x67, 0xb4, 0x33, 0xee, 0x1d, 0xbd, 0xe4, 0x37, 0xff, 0xdb, + 0xbc, 0xbd, 0x26, 0x3f, 0xb9, 0x8c, 0x7a, 0x11, 0xa3, 0x59, 0x35, 0x23, 0x37, 0x17, 0x5e, 0xab, + 0xdf, 0xf0, 0x19, 0xbd, 0x7b, 0x05, 0x71, 0xfb, 0x74, 0x27, 0x84, 0x55, 0x29, 0x69, 0xcf, 0x2b, + 0x3e, 0xdd, 0xfb, 0xb4, 0x9b, 0xc9, 0x65, 0x0a, 0xd5, 0x4e, 0x5e, 0x55, 0x1c, 0x77, 0xa6, 0xe4, + 0xe0, 0x07, 0xa1, 0xfd, 0x76, 0xff, 0xd7, 0xca, 0xa2, 0xfb, 0x61, 0x4b, 0x35, 0xbf, 0x99, 0xea, + 0x82, 0x2e, 0x45, 0xf7, 0xeb, 0xa9, 0x77, 0xff, 0x9e, 0xb4, 0x34, 0x7f, 0xa4, 0x5d, 0x85, 0x10, + 0xd9, 0x41, 0xa7, 0x54, 0x35, 0xfd, 0x5f, 0x55, 0xb3, 0x3b, 0x75, 0x93, 0xee, 0xab, 0x22, 0xce, + 0xab, 0x52, 0x67, 0x87, 0xeb, 0x0d, 0x73, 0xce, 0x36, 0xcc, 0x39, 0xdf, 0x30, 0xe7, 0x5b, 0xce, + 0xc8, 0x3a, 0x67, 0xe4, 0x2c, 0x67, 0xe4, 0x3c, 0x67, 0xe4, 0x67, 0xce, 0xc8, 0xf7, 0x5f, 0xcc, + 0x79, 0x7f, 0xab, 0x4e, 0xfc, 0x13, 0x00, 0x00, 0xff, 0xff, 0xaf, 0x85, 0xaa, 0xb3, 0xd3, 0x03, + 0x00, 0x00, } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto index bdc0631cf2..5fb696598b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/generated.proto @@ -1,5 +1,5 @@ /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -19,13 +19,12 @@ limitations under the License. syntax = 'proto2'; -package k8s.io.kubernetes.pkg.apis.storage.v1beta1; +package k8s.io.client_go.pkg.apis.storage.v1beta1; -import "k8s.io/kubernetes/pkg/api/resource/generated.proto"; -import "k8s.io/kubernetes/pkg/api/unversioned/generated.proto"; -import "k8s.io/kubernetes/pkg/api/v1/generated.proto"; -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; +import "k8s.io/apimachinery/pkg/apis/meta/v1/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/generated.proto"; +import "k8s.io/apimachinery/pkg/runtime/schema/generated.proto"; +import "k8s.io/apimachinery/pkg/util/intstr/generated.proto"; // Package-wide variables from generator "generated". option go_package = "v1beta1"; @@ -37,9 +36,9 @@ option go_package = "v1beta1"; // according to etcd is in ObjectMeta.Name. message StorageClass { // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.v1.ObjectMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1; // Provisioner indicates the type of the provisioner. optional string provisioner = 2; @@ -53,9 +52,9 @@ message StorageClass { // StorageClassList is a collection of storage classes. message StorageClassList { // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - optional k8s.io.kubernetes.pkg.api.unversioned.ListMeta metadata = 1; + optional k8s.io.apimachinery.pkg.apis.meta.v1.ListMeta metadata = 1; // Items is the list of StorageClasses repeated StorageClass items = 2; diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/register.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/register.go index 0408811774..f10a1a5723 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/register.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/register.go @@ -17,34 +17,44 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" - "k8s.io/client-go/pkg/runtime" - versionedwatch "k8s.io/client-go/pkg/watch/versioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // GroupName is the group name use in this package const GroupName = "storage.k8s.io" // SchemeGroupVersion is group version used to register these objects -var SchemeGroupVersion = unversioned.GroupVersion{Group: GroupName, Version: "v1beta1"} +var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1beta1"} + +// Resource takes an unqualified resource and returns a Group qualified GroupResource +func Resource(resource string) schema.GroupResource { + return SchemeGroupVersion.WithResource(resource).GroupResource() +} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, RegisterDefaults) +} + // Adds the list of known types to api.Scheme. func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, - &v1.ListOptions{}, - &v1.DeleteOptions{}, - &v1.ExportOptions{}, - &StorageClass{}, &StorageClassList{}, ) - versionedwatch.AddToGroupVersion(scheme, SchemeGroupVersion) + metav1.AddToGroupVersion(scheme, SchemeGroupVersion) return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.generated.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.generated.go index 39e9245636..d9f5d5f77d 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.generated.go @@ -25,9 +25,8 @@ import ( "errors" "fmt" codec1978 "github.com/ugorji/go/codec" - pkg1_unversioned "k8s.io/client-go/pkg/api/unversioned" - pkg2_v1 "k8s.io/client-go/pkg/api/v1" - pkg3_types "k8s.io/client-go/pkg/types" + pkg1_v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + pkg2_types "k8s.io/apimachinery/pkg/types" "reflect" "runtime" time "time" @@ -63,11 +62,10 @@ func init() { panic(err) } if false { // reference the types, but skip this branch at build/run time - var v0 pkg1_unversioned.TypeMeta - var v1 pkg2_v1.ObjectMeta - var v2 pkg3_types.UID - var v3 time.Time - _, _, _, _ = v0, v1, v2, v3 + var v0 pkg1_v1.TypeMeta + var v1 pkg2_types.UID + var v2 time.Time + _, _, _ = v0, v1, v2 } } @@ -159,7 +157,13 @@ func (x *StorageClass) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if yyq2[2] { yy10 := &x.ObjectMeta - yy10.CodecEncodeSelf(e) + yym11 := z.EncBinary() + _ = yym11 + if false { + } else if z.HasExtensions() && z.EncExt(yy10) { + } else { + z.EncFallback(yy10) + } } else { r.EncodeNil() } @@ -168,14 +172,20 @@ func (x *StorageClass) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy11 := &x.ObjectMeta - yy11.CodecEncodeSelf(e) + yy12 := &x.ObjectMeta + yym13 := z.EncBinary() + _ = yym13 + if false { + } else if z.HasExtensions() && z.EncExt(yy12) { + } else { + z.EncFallback(yy12) + } } } if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yym13 := z.EncBinary() - _ = yym13 + yym15 := z.EncBinary() + _ = yym15 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Provisioner)) @@ -184,8 +194,8 @@ func (x *StorageClass) CodecEncodeSelf(e *codec1978.Encoder) { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("provisioner")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym14 := z.EncBinary() - _ = yym14 + yym16 := z.EncBinary() + _ = yym16 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Provisioner)) @@ -197,8 +207,8 @@ func (x *StorageClass) CodecEncodeSelf(e *codec1978.Encoder) { if x.Parameters == nil { r.EncodeNil() } else { - yym16 := z.EncBinary() - _ = yym16 + yym18 := z.EncBinary() + _ = yym18 if false { } else { z.F.EncMapStringStringV(x.Parameters, false, e) @@ -215,8 +225,8 @@ func (x *StorageClass) CodecEncodeSelf(e *codec1978.Encoder) { if x.Parameters == nil { r.EncodeNil() } else { - yym17 := z.EncBinary() - _ = yym17 + yym19 := z.EncBinary() + _ = yym19 if false { } else { z.F.EncMapStringStringV(x.Parameters, false, e) @@ -237,25 +247,25 @@ func (x *StorageClass) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym18 := z.DecBinary() - _ = yym18 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct19 := r.ContainerType() - if yyct19 == codecSelferValueTypeMap1234 { - yyl19 := r.ReadMapStart() - if yyl19 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl19, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct19 == codecSelferValueTypeArray1234 { - yyl19 := r.ReadArrayStart() - if yyl19 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl19, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -267,12 +277,12 @@ func (x *StorageClass) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys20Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys20Slc - var yyhl20 bool = l >= 0 - for yyj20 := 0; ; yyj20++ { - if yyhl20 { - if yyj20 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -281,51 +291,75 @@ func (x *StorageClass) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys20Slc = r.DecodeBytes(yys20Slc, true, true) - yys20 := string(yys20Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys20 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv23 := &x.ObjectMeta - yyv23.CodecDecodeSelf(d) + yyv8 := &x.ObjectMeta + yym9 := z.DecBinary() + _ = yym9 + if false { + } else if z.HasExtensions() && z.DecExt(yyv8) { + } else { + z.DecFallback(yyv8, false) + } } case "provisioner": if r.TryDecodeAsNil() { x.Provisioner = "" } else { - x.Provisioner = string(r.DecodeString()) + yyv10 := &x.Provisioner + yym11 := z.DecBinary() + _ = yym11 + if false { + } else { + *((*string)(yyv10)) = r.DecodeString() + } } case "parameters": if r.TryDecodeAsNil() { x.Parameters = nil } else { - yyv25 := &x.Parameters - yym26 := z.DecBinary() - _ = yym26 + yyv12 := &x.Parameters + yym13 := z.DecBinary() + _ = yym13 if false { } else { - z.F.DecMapStringStringX(yyv25, false, d) + z.F.DecMapStringStringX(yyv12, false, d) } } default: - z.DecStructFieldNotFound(-1, yys20) - } // end switch yys20 - } // end for yyj20 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -333,16 +367,16 @@ func (x *StorageClass) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj27 int - var yyb27 bool - var yyhl27 bool = l >= 0 - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l + var yyj14 int + var yyb14 bool + var yyhl14 bool = l >= 0 + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb27 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb27 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -350,15 +384,21 @@ func (x *StorageClass) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv15 := &x.Kind + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb27 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb27 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -366,32 +406,44 @@ func (x *StorageClass) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv17 := &x.APIVersion + yym18 := z.DecBinary() + _ = yym18 + if false { + } else { + *((*string)(yyv17)) = r.DecodeString() + } } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb27 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb27 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ObjectMeta = pkg2_v1.ObjectMeta{} + x.ObjectMeta = pkg1_v1.ObjectMeta{} } else { - yyv30 := &x.ObjectMeta - yyv30.CodecDecodeSelf(d) + yyv19 := &x.ObjectMeta + yym20 := z.DecBinary() + _ = yym20 + if false { + } else if z.HasExtensions() && z.DecExt(yyv19) { + } else { + z.DecFallback(yyv19, false) + } } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb27 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb27 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -399,15 +451,21 @@ func (x *StorageClass) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Provisioner = "" } else { - x.Provisioner = string(r.DecodeString()) + yyv21 := &x.Provisioner + yym22 := z.DecBinary() + _ = yym22 + if false { + } else { + *((*string)(yyv21)) = r.DecodeString() + } } - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb27 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb27 { + if yyb14 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -415,26 +473,26 @@ func (x *StorageClass) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) { if r.TryDecodeAsNil() { x.Parameters = nil } else { - yyv32 := &x.Parameters - yym33 := z.DecBinary() - _ = yym33 + yyv23 := &x.Parameters + yym24 := z.DecBinary() + _ = yym24 if false { } else { - z.F.DecMapStringStringX(yyv32, false, d) + z.F.DecMapStringStringX(yyv23, false, d) } } for { - yyj27++ - if yyhl27 { - yyb27 = yyj27 > l + yyj14++ + if yyhl14 { + yyb14 = yyj14 > l } else { - yyb27 = r.CheckBreak() + yyb14 = r.CheckBreak() } - if yyb27 { + if yyb14 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj27-1, "") + z.DecStructFieldNotFound(yyj14-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -446,37 +504,37 @@ func (x *StorageClassList) CodecEncodeSelf(e *codec1978.Encoder) { if x == nil { r.EncodeNil() } else { - yym34 := z.EncBinary() - _ = yym34 + yym1 := z.EncBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.EncExt(x) { } else { - yysep35 := !z.EncBinary() - yy2arr35 := z.EncBasicHandle().StructToArray - var yyq35 [4]bool - _, _, _ = yysep35, yyq35, yy2arr35 - const yyr35 bool = false - yyq35[0] = x.Kind != "" - yyq35[1] = x.APIVersion != "" - yyq35[2] = true - var yynn35 int - if yyr35 || yy2arr35 { + yysep2 := !z.EncBinary() + yy2arr2 := z.EncBasicHandle().StructToArray + var yyq2 [4]bool + _, _, _ = yysep2, yyq2, yy2arr2 + const yyr2 bool = false + yyq2[0] = x.Kind != "" + yyq2[1] = x.APIVersion != "" + yyq2[2] = true + var yynn2 int + if yyr2 || yy2arr2 { r.EncodeArrayStart(4) } else { - yynn35 = 1 - for _, b := range yyq35 { + yynn2 = 1 + for _, b := range yyq2 { if b { - yynn35++ + yynn2++ } } - r.EncodeMapStart(yynn35) - yynn35 = 0 + r.EncodeMapStart(yynn2) + yynn2 = 0 } - if yyr35 || yy2arr35 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq35[0] { - yym37 := z.EncBinary() - _ = yym37 + if yyq2[0] { + yym4 := z.EncBinary() + _ = yym4 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) @@ -485,23 +543,23 @@ func (x *StorageClassList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq35[0] { + if yyq2[0] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("kind")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym38 := z.EncBinary() - _ = yym38 + yym5 := z.EncBinary() + _ = yym5 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.Kind)) } } } - if yyr35 || yy2arr35 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq35[1] { - yym40 := z.EncBinary() - _ = yym40 + if yyq2[1] { + yym7 := z.EncBinary() + _ = yym7 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) @@ -510,54 +568,54 @@ func (x *StorageClassList) CodecEncodeSelf(e *codec1978.Encoder) { r.EncodeString(codecSelferC_UTF81234, "") } } else { - if yyq35[1] { + if yyq2[1] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("apiVersion")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yym41 := z.EncBinary() - _ = yym41 + yym8 := z.EncBinary() + _ = yym8 if false { } else { r.EncodeString(codecSelferC_UTF81234, string(x.APIVersion)) } } } - if yyr35 || yy2arr35 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - if yyq35[2] { - yy43 := &x.ListMeta - yym44 := z.EncBinary() - _ = yym44 + if yyq2[2] { + yy10 := &x.ListMeta + yym11 := z.EncBinary() + _ = yym11 if false { - } else if z.HasExtensions() && z.EncExt(yy43) { + } else if z.HasExtensions() && z.EncExt(yy10) { } else { - z.EncFallback(yy43) + z.EncFallback(yy10) } } else { r.EncodeNil() } } else { - if yyq35[2] { + if yyq2[2] { z.EncSendContainerState(codecSelfer_containerMapKey1234) r.EncodeString(codecSelferC_UTF81234, string("metadata")) z.EncSendContainerState(codecSelfer_containerMapValue1234) - yy45 := &x.ListMeta - yym46 := z.EncBinary() - _ = yym46 + yy12 := &x.ListMeta + yym13 := z.EncBinary() + _ = yym13 if false { - } else if z.HasExtensions() && z.EncExt(yy45) { + } else if z.HasExtensions() && z.EncExt(yy12) { } else { - z.EncFallback(yy45) + z.EncFallback(yy12) } } } - if yyr35 || yy2arr35 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayElem1234) if x.Items == nil { r.EncodeNil() } else { - yym48 := z.EncBinary() - _ = yym48 + yym15 := z.EncBinary() + _ = yym15 if false { } else { h.encSliceStorageClass(([]StorageClass)(x.Items), e) @@ -570,15 +628,15 @@ func (x *StorageClassList) CodecEncodeSelf(e *codec1978.Encoder) { if x.Items == nil { r.EncodeNil() } else { - yym49 := z.EncBinary() - _ = yym49 + yym16 := z.EncBinary() + _ = yym16 if false { } else { h.encSliceStorageClass(([]StorageClass)(x.Items), e) } } } - if yyr35 || yy2arr35 { + if yyr2 || yy2arr2 { z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } else { z.EncSendContainerState(codecSelfer_containerMapEnd1234) @@ -591,25 +649,25 @@ func (x *StorageClassList) CodecDecodeSelf(d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yym50 := z.DecBinary() - _ = yym50 + yym1 := z.DecBinary() + _ = yym1 if false { } else if z.HasExtensions() && z.DecExt(x) { } else { - yyct51 := r.ContainerType() - if yyct51 == codecSelferValueTypeMap1234 { - yyl51 := r.ReadMapStart() - if yyl51 == 0 { + yyct2 := r.ContainerType() + if yyct2 == codecSelferValueTypeMap1234 { + yyl2 := r.ReadMapStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerMapEnd1234) } else { - x.codecDecodeSelfFromMap(yyl51, d) + x.codecDecodeSelfFromMap(yyl2, d) } - } else if yyct51 == codecSelferValueTypeArray1234 { - yyl51 := r.ReadArrayStart() - if yyl51 == 0 { + } else if yyct2 == codecSelferValueTypeArray1234 { + yyl2 := r.ReadArrayStart() + if yyl2 == 0 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } else { - x.codecDecodeSelfFromArray(yyl51, d) + x.codecDecodeSelfFromArray(yyl2, d) } } else { panic(codecSelferOnlyMapOrArrayEncodeToStructErr1234) @@ -621,12 +679,12 @@ func (x *StorageClassList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yys52Slc = z.DecScratchBuffer() // default slice to decode into - _ = yys52Slc - var yyhl52 bool = l >= 0 - for yyj52 := 0; ; yyj52++ { - if yyhl52 { - if yyj52 >= l { + var yys3Slc = z.DecScratchBuffer() // default slice to decode into + _ = yys3Slc + var yyhl3 bool = l >= 0 + for yyj3 := 0; ; yyj3++ { + if yyhl3 { + if yyj3 >= l { break } } else { @@ -635,51 +693,63 @@ func (x *StorageClassList) codecDecodeSelfFromMap(l int, d *codec1978.Decoder) { } } z.DecSendContainerState(codecSelfer_containerMapKey1234) - yys52Slc = r.DecodeBytes(yys52Slc, true, true) - yys52 := string(yys52Slc) + yys3Slc = r.DecodeBytes(yys3Slc, true, true) + yys3 := string(yys3Slc) z.DecSendContainerState(codecSelfer_containerMapValue1234) - switch yys52 { + switch yys3 { case "kind": if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv4 := &x.Kind + yym5 := z.DecBinary() + _ = yym5 + if false { + } else { + *((*string)(yyv4)) = r.DecodeString() + } } case "apiVersion": if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv6 := &x.APIVersion + yym7 := z.DecBinary() + _ = yym7 + if false { + } else { + *((*string)(yyv6)) = r.DecodeString() + } } case "metadata": if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv55 := &x.ListMeta - yym56 := z.DecBinary() - _ = yym56 + yyv8 := &x.ListMeta + yym9 := z.DecBinary() + _ = yym9 if false { - } else if z.HasExtensions() && z.DecExt(yyv55) { + } else if z.HasExtensions() && z.DecExt(yyv8) { } else { - z.DecFallback(yyv55, false) + z.DecFallback(yyv8, false) } } case "items": if r.TryDecodeAsNil() { x.Items = nil } else { - yyv57 := &x.Items - yym58 := z.DecBinary() - _ = yym58 + yyv10 := &x.Items + yym11 := z.DecBinary() + _ = yym11 if false { } else { - h.decSliceStorageClass((*[]StorageClass)(yyv57), d) + h.decSliceStorageClass((*[]StorageClass)(yyv10), d) } } default: - z.DecStructFieldNotFound(-1, yys52) - } // end switch yys52 - } // end for yyj52 + z.DecStructFieldNotFound(-1, yys3) + } // end switch yys3 + } // end for yyj3 z.DecSendContainerState(codecSelfer_containerMapEnd1234) } @@ -687,16 +757,16 @@ func (x *StorageClassList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) var h codecSelfer1234 z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - var yyj59 int - var yyb59 bool - var yyhl59 bool = l >= 0 - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l + var yyj12 int + var yyb12 bool + var yyhl12 bool = l >= 0 + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb59 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb59 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -704,15 +774,21 @@ func (x *StorageClassList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Kind = "" } else { - x.Kind = string(r.DecodeString()) + yyv13 := &x.Kind + yym14 := z.DecBinary() + _ = yym14 + if false { + } else { + *((*string)(yyv13)) = r.DecodeString() + } } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb59 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb59 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -720,38 +796,44 @@ func (x *StorageClassList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.APIVersion = "" } else { - x.APIVersion = string(r.DecodeString()) + yyv15 := &x.APIVersion + yym16 := z.DecBinary() + _ = yym16 + if false { + } else { + *((*string)(yyv15)) = r.DecodeString() + } } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb59 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb59 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } z.DecSendContainerState(codecSelfer_containerArrayElem1234) if r.TryDecodeAsNil() { - x.ListMeta = pkg1_unversioned.ListMeta{} + x.ListMeta = pkg1_v1.ListMeta{} } else { - yyv62 := &x.ListMeta - yym63 := z.DecBinary() - _ = yym63 + yyv17 := &x.ListMeta + yym18 := z.DecBinary() + _ = yym18 if false { - } else if z.HasExtensions() && z.DecExt(yyv62) { + } else if z.HasExtensions() && z.DecExt(yyv17) { } else { - z.DecFallback(yyv62, false) + z.DecFallback(yyv17, false) } } - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb59 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb59 { + if yyb12 { z.DecSendContainerState(codecSelfer_containerArrayEnd1234) return } @@ -759,26 +841,26 @@ func (x *StorageClassList) codecDecodeSelfFromArray(l int, d *codec1978.Decoder) if r.TryDecodeAsNil() { x.Items = nil } else { - yyv64 := &x.Items - yym65 := z.DecBinary() - _ = yym65 + yyv19 := &x.Items + yym20 := z.DecBinary() + _ = yym20 if false { } else { - h.decSliceStorageClass((*[]StorageClass)(yyv64), d) + h.decSliceStorageClass((*[]StorageClass)(yyv19), d) } } for { - yyj59++ - if yyhl59 { - yyb59 = yyj59 > l + yyj12++ + if yyhl12 { + yyb12 = yyj12 > l } else { - yyb59 = r.CheckBreak() + yyb12 = r.CheckBreak() } - if yyb59 { + if yyb12 { break } z.DecSendContainerState(codecSelfer_containerArrayElem1234) - z.DecStructFieldNotFound(yyj59-1, "") + z.DecStructFieldNotFound(yyj12-1, "") } z.DecSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -788,10 +870,10 @@ func (x codecSelfer1234) encSliceStorageClass(v []StorageClass, e *codec1978.Enc z, r := codec1978.GenHelperEncoder(e) _, _, _ = h, z, r r.EncodeArrayStart(len(v)) - for _, yyv66 := range v { + for _, yyv1 := range v { z.EncSendContainerState(codecSelfer_containerArrayElem1234) - yy67 := &yyv66 - yy67.CodecEncodeSelf(e) + yy2 := &yyv1 + yy2.CodecEncodeSelf(e) } z.EncSendContainerState(codecSelfer_containerArrayEnd1234) } @@ -801,83 +883,86 @@ func (x codecSelfer1234) decSliceStorageClass(v *[]StorageClass, d *codec1978.De z, r := codec1978.GenHelperDecoder(d) _, _, _ = h, z, r - yyv68 := *v - yyh68, yyl68 := z.DecSliceHelperStart() - var yyc68 bool - if yyl68 == 0 { - if yyv68 == nil { - yyv68 = []StorageClass{} - yyc68 = true - } else if len(yyv68) != 0 { - yyv68 = yyv68[:0] - yyc68 = true + yyv1 := *v + yyh1, yyl1 := z.DecSliceHelperStart() + var yyc1 bool + _ = yyc1 + if yyl1 == 0 { + if yyv1 == nil { + yyv1 = []StorageClass{} + yyc1 = true + } else if len(yyv1) != 0 { + yyv1 = yyv1[:0] + yyc1 = true } - } else if yyl68 > 0 { - var yyrr68, yyrl68 int - var yyrt68 bool - if yyl68 > cap(yyv68) { + } else if yyl1 > 0 { + var yyrr1, yyrl1 int + var yyrt1 bool + _, _ = yyrl1, yyrt1 + yyrr1 = yyl1 // len(yyv1) + if yyl1 > cap(yyv1) { - yyrg68 := len(yyv68) > 0 - yyv268 := yyv68 - yyrl68, yyrt68 = z.DecInferLen(yyl68, z.DecBasicHandle().MaxInitLen, 280) - if yyrt68 { - if yyrl68 <= cap(yyv68) { - yyv68 = yyv68[:yyrl68] + yyrg1 := len(yyv1) > 0 + yyv21 := yyv1 + yyrl1, yyrt1 = z.DecInferLen(yyl1, z.DecBasicHandle().MaxInitLen, 288) + if yyrt1 { + if yyrl1 <= cap(yyv1) { + yyv1 = yyv1[:yyrl1] } else { - yyv68 = make([]StorageClass, yyrl68) + yyv1 = make([]StorageClass, yyrl1) } } else { - yyv68 = make([]StorageClass, yyrl68) + yyv1 = make([]StorageClass, yyrl1) } - yyc68 = true - yyrr68 = len(yyv68) - if yyrg68 { - copy(yyv68, yyv268) + yyc1 = true + yyrr1 = len(yyv1) + if yyrg1 { + copy(yyv1, yyv21) } - } else if yyl68 != len(yyv68) { - yyv68 = yyv68[:yyl68] - yyc68 = true + } else if yyl1 != len(yyv1) { + yyv1 = yyv1[:yyl1] + yyc1 = true } - yyj68 := 0 - for ; yyj68 < yyrr68; yyj68++ { - yyh68.ElemContainerState(yyj68) + yyj1 := 0 + for ; yyj1 < yyrr1; yyj1++ { + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv68[yyj68] = StorageClass{} + yyv1[yyj1] = StorageClass{} } else { - yyv69 := &yyv68[yyj68] - yyv69.CodecDecodeSelf(d) + yyv2 := &yyv1[yyj1] + yyv2.CodecDecodeSelf(d) } } - if yyrt68 { - for ; yyj68 < yyl68; yyj68++ { - yyv68 = append(yyv68, StorageClass{}) - yyh68.ElemContainerState(yyj68) + if yyrt1 { + for ; yyj1 < yyl1; yyj1++ { + yyv1 = append(yyv1, StorageClass{}) + yyh1.ElemContainerState(yyj1) if r.TryDecodeAsNil() { - yyv68[yyj68] = StorageClass{} + yyv1[yyj1] = StorageClass{} } else { - yyv70 := &yyv68[yyj68] - yyv70.CodecDecodeSelf(d) + yyv3 := &yyv1[yyj1] + yyv3.CodecDecodeSelf(d) } } } } else { - yyj68 := 0 - for ; !r.CheckBreak(); yyj68++ { + yyj1 := 0 + for ; !r.CheckBreak(); yyj1++ { - if yyj68 >= len(yyv68) { - yyv68 = append(yyv68, StorageClass{}) // var yyz68 StorageClass - yyc68 = true + if yyj1 >= len(yyv1) { + yyv1 = append(yyv1, StorageClass{}) // var yyz1 StorageClass + yyc1 = true } - yyh68.ElemContainerState(yyj68) - if yyj68 < len(yyv68) { + yyh1.ElemContainerState(yyj1) + if yyj1 < len(yyv1) { if r.TryDecodeAsNil() { - yyv68[yyj68] = StorageClass{} + yyv1[yyj1] = StorageClass{} } else { - yyv71 := &yyv68[yyj68] - yyv71.CodecDecodeSelf(d) + yyv4 := &yyv1[yyj1] + yyv4.CodecDecodeSelf(d) } } else { @@ -885,16 +970,16 @@ func (x codecSelfer1234) decSliceStorageClass(v *[]StorageClass, d *codec1978.De } } - if yyj68 < len(yyv68) { - yyv68 = yyv68[:yyj68] - yyc68 = true - } else if yyj68 == 0 && yyv68 == nil { - yyv68 = []StorageClass{} - yyc68 = true + if yyj1 < len(yyv1) { + yyv1 = yyv1[:yyj1] + yyc1 = true + } else if yyj1 == 0 && yyv1 == nil { + yyv1 = []StorageClass{} + yyc1 = true } } - yyh68.End() - if yyc68 { - *v = yyv68 + yyh1.End() + if yyc1 { + *v = yyv1 } } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.go index c48bfde51f..8b47567849 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types.go @@ -17,8 +17,7 @@ limitations under the License. package v1beta1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/api/v1" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) // +genclient=true @@ -30,11 +29,11 @@ import ( // StorageClasses are non-namespaced; the name of the storage class // according to etcd is in ObjectMeta.Name. type StorageClass struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard object's metadata. - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - v1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ObjectMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Provisioner indicates the type of the provisioner. Provisioner string `json:"provisioner" protobuf:"bytes,2,opt,name=provisioner"` @@ -47,11 +46,11 @@ type StorageClass struct { // StorageClassList is a collection of storage classes. type StorageClassList struct { - unversioned.TypeMeta `json:",inline"` + metav1.TypeMeta `json:",inline"` // Standard list metadata - // More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata // +optional - unversioned.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` + metav1.ListMeta `json:"metadata,omitempty" protobuf:"bytes,1,opt,name=metadata"` // Items is the list of StorageClasses Items []StorageClass `json:"items" protobuf:"bytes,2,rep,name=items"` diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types_swagger_doc_generated.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types_swagger_doc_generated.go index e8362e381f..0d43bb03c3 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types_swagger_doc_generated.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/types_swagger_doc_generated.go @@ -29,7 +29,7 @@ package v1beta1 // AUTO-GENERATED FUNCTIONS START HERE var map_StorageClass = map[string]string{ "": "StorageClass describes the parameters for a class of storage for which PersistentVolumes can be dynamically provisioned.\n\nStorageClasses are non-namespaced; the name of the storage class according to etcd is in ObjectMeta.Name.", - "metadata": "Standard object's metadata. More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard object's metadata. More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "provisioner": "Provisioner indicates the type of the provisioner.", "parameters": "Parameters holds the parameters for the provisioner that should create volumes of this storage class.", } @@ -40,7 +40,7 @@ func (StorageClass) SwaggerDoc() map[string]string { var map_StorageClassList = map[string]string{ "": "StorageClassList is a collection of storage classes.", - "metadata": "Standard list metadata More info: http://releases.k8s.io/HEAD/docs/devel/api-conventions.md#metadata", + "metadata": "Standard list metadata More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#metadata", "items": "Items is the list of StorageClasses", } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.conversion.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.conversion.go index e72c797768..630fff327b 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.conversion.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.conversion.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1beta1 import ( + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" storage "k8s.io/client-go/pkg/apis/storage" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" unsafe "unsafe" ) @@ -43,29 +43,25 @@ func RegisterConversions(scheme *runtime.Scheme) error { } func autoConvert_v1beta1_StorageClass_To_storage_StorageClass(in *StorageClass, out *storage.StorageClass, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Provisioner = in.Provisioner out.Parameters = *(*map[string]string)(unsafe.Pointer(&in.Parameters)) return nil } +// Convert_v1beta1_StorageClass_To_storage_StorageClass is an autogenerated conversion function. func Convert_v1beta1_StorageClass_To_storage_StorageClass(in *StorageClass, out *storage.StorageClass, s conversion.Scope) error { return autoConvert_v1beta1_StorageClass_To_storage_StorageClass(in, out, s) } func autoConvert_storage_StorageClass_To_v1beta1_StorageClass(in *storage.StorageClass, out *StorageClass, s conversion.Scope) error { - // TODO: Inefficient conversion - can we improve it? - if err := s.Convert(&in.ObjectMeta, &out.ObjectMeta, 0); err != nil { - return err - } + out.ObjectMeta = in.ObjectMeta out.Provisioner = in.Provisioner out.Parameters = *(*map[string]string)(unsafe.Pointer(&in.Parameters)) return nil } +// Convert_storage_StorageClass_To_v1beta1_StorageClass is an autogenerated conversion function. func Convert_storage_StorageClass_To_v1beta1_StorageClass(in *storage.StorageClass, out *StorageClass, s conversion.Scope) error { return autoConvert_storage_StorageClass_To_v1beta1_StorageClass(in, out, s) } @@ -76,16 +72,22 @@ func autoConvert_v1beta1_StorageClassList_To_storage_StorageClassList(in *Storag return nil } +// Convert_v1beta1_StorageClassList_To_storage_StorageClassList is an autogenerated conversion function. func Convert_v1beta1_StorageClassList_To_storage_StorageClassList(in *StorageClassList, out *storage.StorageClassList, s conversion.Scope) error { return autoConvert_v1beta1_StorageClassList_To_storage_StorageClassList(in, out, s) } func autoConvert_storage_StorageClassList_To_v1beta1_StorageClassList(in *storage.StorageClassList, out *StorageClassList, s conversion.Scope) error { out.ListMeta = in.ListMeta - out.Items = *(*[]StorageClass)(unsafe.Pointer(&in.Items)) + if in.Items == nil { + out.Items = make([]StorageClass, 0) + } else { + out.Items = *(*[]StorageClass)(unsafe.Pointer(&in.Items)) + } return nil } +// Convert_storage_StorageClassList_To_v1beta1_StorageClassList is an autogenerated conversion function. func Convert_storage_StorageClassList_To_v1beta1_StorageClassList(in *storage.StorageClassList, out *StorageClassList, s conversion.Scope) error { return autoConvert_storage_StorageClassList_To_v1beta1_StorageClassList(in, out, s) } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.deepcopy.go index 05b9feca81..1f21769946 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package v1beta1 import ( - v1 "k8s.io/client-go/pkg/api/v1" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -40,34 +40,34 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_v1beta1_StorageClass is an autogenerated deepcopy function. func DeepCopy_v1beta1_StorageClass(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StorageClass) out := out.(*StorageClass) - out.TypeMeta = in.TypeMeta - if err := v1.DeepCopy_v1_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Provisioner = in.Provisioner if in.Parameters != nil { in, out := &in.Parameters, &out.Parameters *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Parameters = nil } return nil } } +// DeepCopy_v1beta1_StorageClassList is an autogenerated deepcopy function. func DeepCopy_v1beta1_StorageClassList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StorageClassList) out := out.(*StorageClassList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]StorageClass, len(*in)) @@ -76,8 +76,6 @@ func DeepCopy_v1beta1_StorageClassList(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } return nil } diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.defaults.go b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.defaults.go new file mode 100644 index 0000000000..e24e70be38 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/apis/storage/v1beta1/zz_generated.defaults.go @@ -0,0 +1,32 @@ +// +build !ignore_autogenerated + +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// This file was autogenerated by defaulter-gen. Do not edit it manually! + +package v1beta1 + +import ( + runtime "k8s.io/apimachinery/pkg/runtime" +) + +// RegisterDefaults adds defaulters functions to the given scheme. +// Public to allow building arbitrary schemes. +// All generated defaulters are covering - they call all nested defaulters. +func RegisterDefaults(scheme *runtime.Scheme) error { + return nil +} diff --git a/vendor/k8s.io/client-go/pkg/apis/storage/zz_generated.deepcopy.go b/vendor/k8s.io/client-go/pkg/apis/storage/zz_generated.deepcopy.go index a1c1817537..bf8ba1b805 100644 --- a/vendor/k8s.io/client-go/pkg/apis/storage/zz_generated.deepcopy.go +++ b/vendor/k8s.io/client-go/pkg/apis/storage/zz_generated.deepcopy.go @@ -1,7 +1,7 @@ // +build !ignore_autogenerated /* -Copyright 2016 The Kubernetes Authors. +Copyright 2017 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. @@ -21,9 +21,9 @@ limitations under the License. package storage import ( - api "k8s.io/client-go/pkg/api" - conversion "k8s.io/client-go/pkg/conversion" - runtime "k8s.io/client-go/pkg/runtime" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + conversion "k8s.io/apimachinery/pkg/conversion" + runtime "k8s.io/apimachinery/pkg/runtime" reflect "reflect" ) @@ -40,34 +40,34 @@ func RegisterDeepCopies(scheme *runtime.Scheme) error { ) } +// DeepCopy_storage_StorageClass is an autogenerated deepcopy function. func DeepCopy_storage_StorageClass(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StorageClass) out := out.(*StorageClass) - out.TypeMeta = in.TypeMeta - if err := api.DeepCopy_api_ObjectMeta(&in.ObjectMeta, &out.ObjectMeta, c); err != nil { + *out = *in + if newVal, err := c.DeepCopy(&in.ObjectMeta); err != nil { return err + } else { + out.ObjectMeta = *newVal.(*v1.ObjectMeta) } - out.Provisioner = in.Provisioner if in.Parameters != nil { in, out := &in.Parameters, &out.Parameters *out = make(map[string]string) for key, val := range *in { (*out)[key] = val } - } else { - out.Parameters = nil } return nil } } +// DeepCopy_storage_StorageClassList is an autogenerated deepcopy function. func DeepCopy_storage_StorageClassList(in interface{}, out interface{}, c *conversion.Cloner) error { { in := in.(*StorageClassList) out := out.(*StorageClassList) - out.TypeMeta = in.TypeMeta - out.ListMeta = in.ListMeta + *out = *in if in.Items != nil { in, out := &in.Items, &out.Items *out = make([]StorageClass, len(*in)) @@ -76,8 +76,6 @@ func DeepCopy_storage_StorageClassList(in interface{}, out interface{}, c *conve return err } } - } else { - out.Items = nil } return nil } diff --git a/vendor/k8s.io/client-go/pkg/auth/user/doc.go b/vendor/k8s.io/client-go/pkg/auth/user/doc.go deleted file mode 100644 index 570c51ae99..0000000000 --- a/vendor/k8s.io/client-go/pkg/auth/user/doc.go +++ /dev/null @@ -1,19 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package user contains utilities for dealing with simple user exchange in the auth -// packages. The user.Info interface defines an interface for exchanging that info. -package user diff --git a/vendor/k8s.io/client-go/pkg/auth/user/user.go b/vendor/k8s.io/client-go/pkg/auth/user/user.go deleted file mode 100644 index 3af1959888..0000000000 --- a/vendor/k8s.io/client-go/pkg/auth/user/user.go +++ /dev/null @@ -1,78 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package user - -// Info describes a user that has been authenticated to the system. -type Info interface { - // GetName returns the name that uniquely identifies this user among all - // other active users. - GetName() string - // GetUID returns a unique value for a particular user that will change - // if the user is removed from the system and another user is added with - // the same name. - GetUID() string - // GetGroups returns the names of the groups the user is a member of - GetGroups() []string - - // GetExtra can contain any additional information that the authenticator - // thought was interesting. One example would be scopes on a token. - // Keys in this map should be namespaced to the authenticator or - // authenticator/authorizer pair making use of them. - // For instance: "example.org/foo" instead of "foo" - // This is a map[string][]string because it needs to be serializeable into - // a SubjectAccessReviewSpec.authorization.k8s.io for proper authorization - // delegation flows - // In order to faithfully round-trip through an impersonation flow, these keys - // MUST be lowercase. - GetExtra() map[string][]string -} - -// DefaultInfo provides a simple user information exchange object -// for components that implement the UserInfo interface. -type DefaultInfo struct { - Name string - UID string - Groups []string - Extra map[string][]string -} - -func (i *DefaultInfo) GetName() string { - return i.Name -} - -func (i *DefaultInfo) GetUID() string { - return i.UID -} - -func (i *DefaultInfo) GetGroups() []string { - return i.Groups -} - -func (i *DefaultInfo) GetExtra() map[string][]string { - return i.Extra -} - -// well-known user and group names -const ( - SystemPrivilegedGroup = "system:masters" - NodesGroup = "system:nodes" - AllUnauthenticated = "system:unauthenticated" - AllAuthenticated = "system:authenticated" - - Anonymous = "system:anonymous" - APIServerUser = "system:apiserver" -) diff --git a/vendor/k8s.io/client-go/pkg/conversion/OWNERS b/vendor/k8s.io/client-go/pkg/conversion/OWNERS deleted file mode 100644 index a046efc0c2..0000000000 --- a/vendor/k8s.io/client-go/pkg/conversion/OWNERS +++ /dev/null @@ -1,5 +0,0 @@ -assignees: - - derekwaynecarr - - lavalamp - - smarterclayton - - wojtek-t diff --git a/vendor/k8s.io/client-go/pkg/runtime/OWNERS b/vendor/k8s.io/client-go/pkg/runtime/OWNERS deleted file mode 100644 index d038b5e9b9..0000000000 --- a/vendor/k8s.io/client-go/pkg/runtime/OWNERS +++ /dev/null @@ -1,5 +0,0 @@ -assignees: - - caesarxuchao - - deads2k - - lavalamp - - smarterclayton diff --git a/vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/exec.go b/vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/exec.go deleted file mode 100644 index 739fd3509c..0000000000 --- a/vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/exec.go +++ /dev/null @@ -1,94 +0,0 @@ -//This package is copied from Go library text/template. -//The original private functions indirect and printableValue -//are exported as public functions. -package template - -import ( - "fmt" - "reflect" -) - -var Indirect = indirect -var PrintableValue = printableValue - -var ( - errorType = reflect.TypeOf((*error)(nil)).Elem() - fmtStringerType = reflect.TypeOf((*fmt.Stringer)(nil)).Elem() -) - -// indirect returns the item at the end of indirection, and a bool to indicate if it's nil. -// We indirect through pointers and empty interfaces (only) because -// non-empty interfaces have methods we might need. -func indirect(v reflect.Value) (rv reflect.Value, isNil bool) { - for ; v.Kind() == reflect.Ptr || v.Kind() == reflect.Interface; v = v.Elem() { - if v.IsNil() { - return v, true - } - if v.Kind() == reflect.Interface && v.NumMethod() > 0 { - break - } - } - return v, false -} - -// printableValue returns the, possibly indirected, interface value inside v that -// is best for a call to formatted printer. -func printableValue(v reflect.Value) (interface{}, bool) { - if v.Kind() == reflect.Ptr { - v, _ = indirect(v) // fmt.Fprint handles nil. - } - if !v.IsValid() { - return "", true - } - - if !v.Type().Implements(errorType) && !v.Type().Implements(fmtStringerType) { - if v.CanAddr() && (reflect.PtrTo(v.Type()).Implements(errorType) || reflect.PtrTo(v.Type()).Implements(fmtStringerType)) { - v = v.Addr() - } else { - switch v.Kind() { - case reflect.Chan, reflect.Func: - return nil, false - } - } - } - return v.Interface(), true -} - -// canBeNil reports whether an untyped nil can be assigned to the type. See reflect.Zero. -func canBeNil(typ reflect.Type) bool { - switch typ.Kind() { - case reflect.Chan, reflect.Func, reflect.Interface, reflect.Map, reflect.Ptr, reflect.Slice: - return true - } - return false -} - -// isTrue reports whether the value is 'true', in the sense of not the zero of its type, -// and whether the value has a meaningful truth value. -func isTrue(val reflect.Value) (truth, ok bool) { - if !val.IsValid() { - // Something like var x interface{}, never set. It's a form of nil. - return false, true - } - switch val.Kind() { - case reflect.Array, reflect.Map, reflect.Slice, reflect.String: - truth = val.Len() > 0 - case reflect.Bool: - truth = val.Bool() - case reflect.Complex64, reflect.Complex128: - truth = val.Complex() != 0 - case reflect.Chan, reflect.Func, reflect.Ptr, reflect.Interface: - truth = !val.IsNil() - case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: - truth = val.Int() != 0 - case reflect.Float32, reflect.Float64: - truth = val.Float() != 0 - case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr: - truth = val.Uint() != 0 - case reflect.Struct: - truth = true // Struct values are always true. - default: - return - } - return truth, true -} diff --git a/vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/funcs.go b/vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/funcs.go deleted file mode 100644 index 27a008b0a7..0000000000 --- a/vendor/k8s.io/client-go/pkg/third_party/forked/golang/template/funcs.go +++ /dev/null @@ -1,599 +0,0 @@ -//This package is copied from Go library text/template. -//The original private functions eq, ge, gt, le, lt, and ne -//are exported as public functions. -package template - -import ( - "bytes" - "errors" - "fmt" - "io" - "net/url" - "reflect" - "strings" - "unicode" - "unicode/utf8" -) - -var Equal = eq -var GreaterEqual = ge -var Greater = gt -var LessEqual = le -var Less = lt -var NotEqual = ne - -// FuncMap is the type of the map defining the mapping from names to functions. -// Each function must have either a single return value, or two return values of -// which the second has type error. In that case, if the second (error) -// return value evaluates to non-nil during execution, execution terminates and -// Execute returns that error. -type FuncMap map[string]interface{} - -var builtins = FuncMap{ - "and": and, - "call": call, - "html": HTMLEscaper, - "index": index, - "js": JSEscaper, - "len": length, - "not": not, - "or": or, - "print": fmt.Sprint, - "printf": fmt.Sprintf, - "println": fmt.Sprintln, - "urlquery": URLQueryEscaper, - - // Comparisons - "eq": eq, // == - "ge": ge, // >= - "gt": gt, // > - "le": le, // <= - "lt": lt, // < - "ne": ne, // != -} - -var builtinFuncs = createValueFuncs(builtins) - -// createValueFuncs turns a FuncMap into a map[string]reflect.Value -func createValueFuncs(funcMap FuncMap) map[string]reflect.Value { - m := make(map[string]reflect.Value) - addValueFuncs(m, funcMap) - return m -} - -// addValueFuncs adds to values the functions in funcs, converting them to reflect.Values. -func addValueFuncs(out map[string]reflect.Value, in FuncMap) { - for name, fn := range in { - v := reflect.ValueOf(fn) - if v.Kind() != reflect.Func { - panic("value for " + name + " not a function") - } - if !goodFunc(v.Type()) { - panic(fmt.Errorf("can't install method/function %q with %d results", name, v.Type().NumOut())) - } - out[name] = v - } -} - -// AddFuncs adds to values the functions in funcs. It does no checking of the input - -// call addValueFuncs first. -func addFuncs(out, in FuncMap) { - for name, fn := range in { - out[name] = fn - } -} - -// goodFunc checks that the function or method has the right result signature. -func goodFunc(typ reflect.Type) bool { - // We allow functions with 1 result or 2 results where the second is an error. - switch { - case typ.NumOut() == 1: - return true - case typ.NumOut() == 2 && typ.Out(1) == errorType: - return true - } - return false -} - -// findFunction looks for a function in the template, and global map. -func findFunction(name string) (reflect.Value, bool) { - if fn := builtinFuncs[name]; fn.IsValid() { - return fn, true - } - return reflect.Value{}, false -} - -// Indexing. - -// index returns the result of indexing its first argument by the following -// arguments. Thus "index x 1 2 3" is, in Go syntax, x[1][2][3]. Each -// indexed item must be a map, slice, or array. -func index(item interface{}, indices ...interface{}) (interface{}, error) { - v := reflect.ValueOf(item) - for _, i := range indices { - index := reflect.ValueOf(i) - var isNil bool - if v, isNil = indirect(v); isNil { - return nil, fmt.Errorf("index of nil pointer") - } - switch v.Kind() { - case reflect.Array, reflect.Slice, reflect.String: - var x int64 - switch index.Kind() { - case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: - x = index.Int() - case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr: - x = int64(index.Uint()) - default: - return nil, fmt.Errorf("cannot index slice/array with type %s", index.Type()) - } - if x < 0 || x >= int64(v.Len()) { - return nil, fmt.Errorf("index out of range: %d", x) - } - v = v.Index(int(x)) - case reflect.Map: - if !index.IsValid() { - index = reflect.Zero(v.Type().Key()) - } - if !index.Type().AssignableTo(v.Type().Key()) { - return nil, fmt.Errorf("%s is not index type for %s", index.Type(), v.Type()) - } - if x := v.MapIndex(index); x.IsValid() { - v = x - } else { - v = reflect.Zero(v.Type().Elem()) - } - default: - return nil, fmt.Errorf("can't index item of type %s", v.Type()) - } - } - return v.Interface(), nil -} - -// Length - -// length returns the length of the item, with an error if it has no defined length. -func length(item interface{}) (int, error) { - v, isNil := indirect(reflect.ValueOf(item)) - if isNil { - return 0, fmt.Errorf("len of nil pointer") - } - switch v.Kind() { - case reflect.Array, reflect.Chan, reflect.Map, reflect.Slice, reflect.String: - return v.Len(), nil - } - return 0, fmt.Errorf("len of type %s", v.Type()) -} - -// Function invocation - -// call returns the result of evaluating the first argument as a function. -// The function must return 1 result, or 2 results, the second of which is an error. -func call(fn interface{}, args ...interface{}) (interface{}, error) { - v := reflect.ValueOf(fn) - typ := v.Type() - if typ.Kind() != reflect.Func { - return nil, fmt.Errorf("non-function of type %s", typ) - } - if !goodFunc(typ) { - return nil, fmt.Errorf("function called with %d args; should be 1 or 2", typ.NumOut()) - } - numIn := typ.NumIn() - var dddType reflect.Type - if typ.IsVariadic() { - if len(args) < numIn-1 { - return nil, fmt.Errorf("wrong number of args: got %d want at least %d", len(args), numIn-1) - } - dddType = typ.In(numIn - 1).Elem() - } else { - if len(args) != numIn { - return nil, fmt.Errorf("wrong number of args: got %d want %d", len(args), numIn) - } - } - argv := make([]reflect.Value, len(args)) - for i, arg := range args { - value := reflect.ValueOf(arg) - // Compute the expected type. Clumsy because of variadics. - var argType reflect.Type - if !typ.IsVariadic() || i < numIn-1 { - argType = typ.In(i) - } else { - argType = dddType - } - if !value.IsValid() && canBeNil(argType) { - value = reflect.Zero(argType) - } - if !value.Type().AssignableTo(argType) { - return nil, fmt.Errorf("arg %d has type %s; should be %s", i, value.Type(), argType) - } - argv[i] = value - } - result := v.Call(argv) - if len(result) == 2 && !result[1].IsNil() { - return result[0].Interface(), result[1].Interface().(error) - } - return result[0].Interface(), nil -} - -// Boolean logic. - -func truth(a interface{}) bool { - t, _ := isTrue(reflect.ValueOf(a)) - return t -} - -// and computes the Boolean AND of its arguments, returning -// the first false argument it encounters, or the last argument. -func and(arg0 interface{}, args ...interface{}) interface{} { - if !truth(arg0) { - return arg0 - } - for i := range args { - arg0 = args[i] - if !truth(arg0) { - break - } - } - return arg0 -} - -// or computes the Boolean OR of its arguments, returning -// the first true argument it encounters, or the last argument. -func or(arg0 interface{}, args ...interface{}) interface{} { - if truth(arg0) { - return arg0 - } - for i := range args { - arg0 = args[i] - if truth(arg0) { - break - } - } - return arg0 -} - -// not returns the Boolean negation of its argument. -func not(arg interface{}) (truth bool) { - truth, _ = isTrue(reflect.ValueOf(arg)) - return !truth -} - -// Comparison. - -// TODO: Perhaps allow comparison between signed and unsigned integers. - -var ( - errBadComparisonType = errors.New("invalid type for comparison") - errBadComparison = errors.New("incompatible types for comparison") - errNoComparison = errors.New("missing argument for comparison") -) - -type kind int - -const ( - invalidKind kind = iota - boolKind - complexKind - intKind - floatKind - integerKind - stringKind - uintKind -) - -func basicKind(v reflect.Value) (kind, error) { - switch v.Kind() { - case reflect.Bool: - return boolKind, nil - case reflect.Int, reflect.Int8, reflect.Int16, reflect.Int32, reflect.Int64: - return intKind, nil - case reflect.Uint, reflect.Uint8, reflect.Uint16, reflect.Uint32, reflect.Uint64, reflect.Uintptr: - return uintKind, nil - case reflect.Float32, reflect.Float64: - return floatKind, nil - case reflect.Complex64, reflect.Complex128: - return complexKind, nil - case reflect.String: - return stringKind, nil - } - return invalidKind, errBadComparisonType -} - -// eq evaluates the comparison a == b || a == c || ... -func eq(arg1 interface{}, arg2 ...interface{}) (bool, error) { - v1 := reflect.ValueOf(arg1) - k1, err := basicKind(v1) - if err != nil { - return false, err - } - if len(arg2) == 0 { - return false, errNoComparison - } - for _, arg := range arg2 { - v2 := reflect.ValueOf(arg) - k2, err := basicKind(v2) - if err != nil { - return false, err - } - truth := false - if k1 != k2 { - // Special case: Can compare integer values regardless of type's sign. - switch { - case k1 == intKind && k2 == uintKind: - truth = v1.Int() >= 0 && uint64(v1.Int()) == v2.Uint() - case k1 == uintKind && k2 == intKind: - truth = v2.Int() >= 0 && v1.Uint() == uint64(v2.Int()) - default: - return false, errBadComparison - } - } else { - switch k1 { - case boolKind: - truth = v1.Bool() == v2.Bool() - case complexKind: - truth = v1.Complex() == v2.Complex() - case floatKind: - truth = v1.Float() == v2.Float() - case intKind: - truth = v1.Int() == v2.Int() - case stringKind: - truth = v1.String() == v2.String() - case uintKind: - truth = v1.Uint() == v2.Uint() - default: - panic("invalid kind") - } - } - if truth { - return true, nil - } - } - return false, nil -} - -// ne evaluates the comparison a != b. -func ne(arg1, arg2 interface{}) (bool, error) { - // != is the inverse of ==. - equal, err := eq(arg1, arg2) - return !equal, err -} - -// lt evaluates the comparison a < b. -func lt(arg1, arg2 interface{}) (bool, error) { - v1 := reflect.ValueOf(arg1) - k1, err := basicKind(v1) - if err != nil { - return false, err - } - v2 := reflect.ValueOf(arg2) - k2, err := basicKind(v2) - if err != nil { - return false, err - } - truth := false - if k1 != k2 { - // Special case: Can compare integer values regardless of type's sign. - switch { - case k1 == intKind && k2 == uintKind: - truth = v1.Int() < 0 || uint64(v1.Int()) < v2.Uint() - case k1 == uintKind && k2 == intKind: - truth = v2.Int() >= 0 && v1.Uint() < uint64(v2.Int()) - default: - return false, errBadComparison - } - } else { - switch k1 { - case boolKind, complexKind: - return false, errBadComparisonType - case floatKind: - truth = v1.Float() < v2.Float() - case intKind: - truth = v1.Int() < v2.Int() - case stringKind: - truth = v1.String() < v2.String() - case uintKind: - truth = v1.Uint() < v2.Uint() - default: - panic("invalid kind") - } - } - return truth, nil -} - -// le evaluates the comparison <= b. -func le(arg1, arg2 interface{}) (bool, error) { - // <= is < or ==. - lessThan, err := lt(arg1, arg2) - if lessThan || err != nil { - return lessThan, err - } - return eq(arg1, arg2) -} - -// gt evaluates the comparison a > b. -func gt(arg1, arg2 interface{}) (bool, error) { - // > is the inverse of <=. - lessOrEqual, err := le(arg1, arg2) - if err != nil { - return false, err - } - return !lessOrEqual, nil -} - -// ge evaluates the comparison a >= b. -func ge(arg1, arg2 interface{}) (bool, error) { - // >= is the inverse of <. - lessThan, err := lt(arg1, arg2) - if err != nil { - return false, err - } - return !lessThan, nil -} - -// HTML escaping. - -var ( - htmlQuot = []byte(""") // shorter than """ - htmlApos = []byte("'") // shorter than "'" and apos was not in HTML until HTML5 - htmlAmp = []byte("&") - htmlLt = []byte("<") - htmlGt = []byte(">") -) - -// HTMLEscape writes to w the escaped HTML equivalent of the plain text data b. -func HTMLEscape(w io.Writer, b []byte) { - last := 0 - for i, c := range b { - var html []byte - switch c { - case '"': - html = htmlQuot - case '\'': - html = htmlApos - case '&': - html = htmlAmp - case '<': - html = htmlLt - case '>': - html = htmlGt - default: - continue - } - w.Write(b[last:i]) - w.Write(html) - last = i + 1 - } - w.Write(b[last:]) -} - -// HTMLEscapeString returns the escaped HTML equivalent of the plain text data s. -func HTMLEscapeString(s string) string { - // Avoid allocation if we can. - if strings.IndexAny(s, `'"&<>`) < 0 { - return s - } - var b bytes.Buffer - HTMLEscape(&b, []byte(s)) - return b.String() -} - -// HTMLEscaper returns the escaped HTML equivalent of the textual -// representation of its arguments. -func HTMLEscaper(args ...interface{}) string { - return HTMLEscapeString(evalArgs(args)) -} - -// JavaScript escaping. - -var ( - jsLowUni = []byte(`\u00`) - hex = []byte("0123456789ABCDEF") - - jsBackslash = []byte(`\\`) - jsApos = []byte(`\'`) - jsQuot = []byte(`\"`) - jsLt = []byte(`\x3C`) - jsGt = []byte(`\x3E`) -) - -// JSEscape writes to w the escaped JavaScript equivalent of the plain text data b. -func JSEscape(w io.Writer, b []byte) { - last := 0 - for i := 0; i < len(b); i++ { - c := b[i] - - if !jsIsSpecial(rune(c)) { - // fast path: nothing to do - continue - } - w.Write(b[last:i]) - - if c < utf8.RuneSelf { - // Quotes, slashes and angle brackets get quoted. - // Control characters get written as \u00XX. - switch c { - case '\\': - w.Write(jsBackslash) - case '\'': - w.Write(jsApos) - case '"': - w.Write(jsQuot) - case '<': - w.Write(jsLt) - case '>': - w.Write(jsGt) - default: - w.Write(jsLowUni) - t, b := c>>4, c&0x0f - w.Write(hex[t : t+1]) - w.Write(hex[b : b+1]) - } - } else { - // Unicode rune. - r, size := utf8.DecodeRune(b[i:]) - if unicode.IsPrint(r) { - w.Write(b[i : i+size]) - } else { - fmt.Fprintf(w, "\\u%04X", r) - } - i += size - 1 - } - last = i + 1 - } - w.Write(b[last:]) -} - -// JSEscapeString returns the escaped JavaScript equivalent of the plain text data s. -func JSEscapeString(s string) string { - // Avoid allocation if we can. - if strings.IndexFunc(s, jsIsSpecial) < 0 { - return s - } - var b bytes.Buffer - JSEscape(&b, []byte(s)) - return b.String() -} - -func jsIsSpecial(r rune) bool { - switch r { - case '\\', '\'', '"', '<', '>': - return true - } - return r < ' ' || utf8.RuneSelf <= r -} - -// JSEscaper returns the escaped JavaScript equivalent of the textual -// representation of its arguments. -func JSEscaper(args ...interface{}) string { - return JSEscapeString(evalArgs(args)) -} - -// URLQueryEscaper returns the escaped value of the textual representation of -// its arguments in a form suitable for embedding in a URL query. -func URLQueryEscaper(args ...interface{}) string { - return url.QueryEscape(evalArgs(args)) -} - -// evalArgs formats the list of arguments into a string. It is therefore equivalent to -// fmt.Sprint(args...) -// except that each argument is indirected (if a pointer), as required, -// using the same rules as the default string evaluation during template -// execution. -func evalArgs(args []interface{}) string { - ok := false - var s string - // Fast path for simple common case. - if len(args) == 1 { - s, ok = args[0].(string) - } - if !ok { - for i, arg := range args { - a, ok := printableValue(reflect.ValueOf(arg)) - if ok { - args[i] = a - } // else left fmt do its thing - } - s = fmt.Sprint(args...) - } - return s -} diff --git a/vendor/k8s.io/client-go/pkg/util/BUILD b/vendor/k8s.io/client-go/pkg/util/BUILD new file mode 100644 index 0000000000..ff028a804f --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/util/BUILD @@ -0,0 +1,19 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "doc.go", + "template.go", + "umask.go", + "util.go", + ], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/jsonpath/jsonpath.go b/vendor/k8s.io/client-go/pkg/util/jsonpath/jsonpath.go deleted file mode 100644 index 11a1c521a1..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/jsonpath/jsonpath.go +++ /dev/null @@ -1,498 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package jsonpath - -import ( - "bytes" - "fmt" - "io" - "reflect" - "strings" - - "k8s.io/client-go/pkg/third_party/forked/golang/template" -) - -type JSONPath struct { - name string - parser *Parser - stack [][]reflect.Value //push and pop values in different scopes - cur []reflect.Value //current scope values - beginRange int - inRange int - endRange int - - allowMissingKeys bool -} - -func New(name string) *JSONPath { - return &JSONPath{ - name: name, - beginRange: 0, - inRange: 0, - endRange: 0, - } -} - -// AllowMissingKeys allows a caller to specify whether they want an error if a field or map key -// cannot be located, or simply an empty result. The receiver is returned for chaining. -func (j *JSONPath) AllowMissingKeys(allow bool) *JSONPath { - j.allowMissingKeys = allow - return j -} - -// Parse parse the given template, return error -func (j *JSONPath) Parse(text string) (err error) { - j.parser, err = Parse(j.name, text) - return -} - -// Execute bounds data into template and write the result -func (j *JSONPath) Execute(wr io.Writer, data interface{}) error { - fullResults, err := j.FindResults(data) - if err != nil { - return err - } - for ix := range fullResults { - if err := j.PrintResults(wr, fullResults[ix]); err != nil { - return err - } - } - return nil -} - -func (j *JSONPath) FindResults(data interface{}) ([][]reflect.Value, error) { - if j.parser == nil { - return nil, fmt.Errorf("%s is an incomplete jsonpath template", j.name) - } - - j.cur = []reflect.Value{reflect.ValueOf(data)} - nodes := j.parser.Root.Nodes - fullResult := [][]reflect.Value{} - for i := 0; i < len(nodes); i++ { - node := nodes[i] - results, err := j.walk(j.cur, node) - if err != nil { - return nil, err - } - - //encounter an end node, break the current block - if j.endRange > 0 && j.endRange <= j.inRange { - j.endRange -= 1 - break - } - //encounter a range node, start a range loop - if j.beginRange > 0 { - j.beginRange -= 1 - j.inRange += 1 - for k, value := range results { - j.parser.Root.Nodes = nodes[i+1:] - if k == len(results)-1 { - j.inRange -= 1 - } - nextResults, err := j.FindResults(value.Interface()) - if err != nil { - return nil, err - } - fullResult = append(fullResult, nextResults...) - } - break - } - fullResult = append(fullResult, results) - } - return fullResult, nil -} - -// PrintResults write the results into writer -func (j *JSONPath) PrintResults(wr io.Writer, results []reflect.Value) error { - for i, r := range results { - text, err := j.evalToText(r) - if err != nil { - return err - } - if i != len(results)-1 { - text = append(text, ' ') - } - if _, err = wr.Write(text); err != nil { - return err - } - } - return nil -} - -// walk visits tree rooted at the given node in DFS order -func (j *JSONPath) walk(value []reflect.Value, node Node) ([]reflect.Value, error) { - switch node := node.(type) { - case *ListNode: - return j.evalList(value, node) - case *TextNode: - return []reflect.Value{reflect.ValueOf(node.Text)}, nil - case *FieldNode: - return j.evalField(value, node) - case *ArrayNode: - return j.evalArray(value, node) - case *FilterNode: - return j.evalFilter(value, node) - case *IntNode: - return j.evalInt(value, node) - case *FloatNode: - return j.evalFloat(value, node) - case *WildcardNode: - return j.evalWildcard(value, node) - case *RecursiveNode: - return j.evalRecursive(value, node) - case *UnionNode: - return j.evalUnion(value, node) - case *IdentifierNode: - return j.evalIdentifier(value, node) - default: - return value, fmt.Errorf("unexpected Node %v", node) - } -} - -// evalInt evaluates IntNode -func (j *JSONPath) evalInt(input []reflect.Value, node *IntNode) ([]reflect.Value, error) { - result := make([]reflect.Value, len(input)) - for i := range input { - result[i] = reflect.ValueOf(node.Value) - } - return result, nil -} - -// evalFloat evaluates FloatNode -func (j *JSONPath) evalFloat(input []reflect.Value, node *FloatNode) ([]reflect.Value, error) { - result := make([]reflect.Value, len(input)) - for i := range input { - result[i] = reflect.ValueOf(node.Value) - } - return result, nil -} - -// evalList evaluates ListNode -func (j *JSONPath) evalList(value []reflect.Value, node *ListNode) ([]reflect.Value, error) { - var err error - curValue := value - for _, node := range node.Nodes { - curValue, err = j.walk(curValue, node) - if err != nil { - return curValue, err - } - } - return curValue, nil -} - -// evalIdentifier evaluates IdentifierNode -func (j *JSONPath) evalIdentifier(input []reflect.Value, node *IdentifierNode) ([]reflect.Value, error) { - results := []reflect.Value{} - switch node.Name { - case "range": - j.stack = append(j.stack, j.cur) - j.beginRange += 1 - results = input - case "end": - if j.endRange < j.inRange { //inside a loop, break the current block - j.endRange += 1 - break - } - // the loop is about to end, pop value and continue the following execution - if len(j.stack) > 0 { - j.cur, j.stack = j.stack[len(j.stack)-1], j.stack[:len(j.stack)-1] - } else { - return results, fmt.Errorf("not in range, nothing to end") - } - default: - return input, fmt.Errorf("unrecognized identifier %v", node.Name) - } - return results, nil -} - -// evalArray evaluates ArrayNode -func (j *JSONPath) evalArray(input []reflect.Value, node *ArrayNode) ([]reflect.Value, error) { - result := []reflect.Value{} - for _, value := range input { - - value, isNil := template.Indirect(value) - if isNil { - continue - } - if value.Kind() != reflect.Array && value.Kind() != reflect.Slice { - return input, fmt.Errorf("%v is not array or slice", value.Type()) - } - params := node.Params - if !params[0].Known { - params[0].Value = 0 - } - if params[0].Value < 0 { - params[0].Value += value.Len() - } - if !params[1].Known { - params[1].Value = value.Len() - } - - if params[1].Value < 0 { - params[1].Value += value.Len() - } - - sliceLength := value.Len() - if params[1].Value != params[0].Value { // if you're requesting zero elements, allow it through. - if params[0].Value >= sliceLength { - return input, fmt.Errorf("array index out of bounds: index %d, length %d", params[0].Value, sliceLength) - } - if params[1].Value > sliceLength { - return input, fmt.Errorf("array index out of bounds: index %d, length %d", params[1].Value-1, sliceLength) - } - } - - if !params[2].Known { - value = value.Slice(params[0].Value, params[1].Value) - } else { - value = value.Slice3(params[0].Value, params[1].Value, params[2].Value) - } - for i := 0; i < value.Len(); i++ { - result = append(result, value.Index(i)) - } - } - return result, nil -} - -// evalUnion evaluates UnionNode -func (j *JSONPath) evalUnion(input []reflect.Value, node *UnionNode) ([]reflect.Value, error) { - result := []reflect.Value{} - for _, listNode := range node.Nodes { - temp, err := j.evalList(input, listNode) - if err != nil { - return input, err - } - result = append(result, temp...) - } - return result, nil -} - -func (j *JSONPath) findFieldInValue(value *reflect.Value, node *FieldNode) (reflect.Value, error) { - t := value.Type() - var inlineValue *reflect.Value - for ix := 0; ix < t.NumField(); ix++ { - f := t.Field(ix) - jsonTag := f.Tag.Get("json") - parts := strings.Split(jsonTag, ",") - if len(parts) == 0 { - continue - } - if parts[0] == node.Value { - return value.Field(ix), nil - } - if len(parts[0]) == 0 { - val := value.Field(ix) - inlineValue = &val - } - } - if inlineValue != nil { - if inlineValue.Kind() == reflect.Struct { - // handle 'inline' - match, err := j.findFieldInValue(inlineValue, node) - if err != nil { - return reflect.Value{}, err - } - if match.IsValid() { - return match, nil - } - } - } - return value.FieldByName(node.Value), nil -} - -// evalField evaluates field of struct or key of map. -func (j *JSONPath) evalField(input []reflect.Value, node *FieldNode) ([]reflect.Value, error) { - results := []reflect.Value{} - // If there's no input, there's no output - if len(input) == 0 { - return results, nil - } - for _, value := range input { - var result reflect.Value - value, isNil := template.Indirect(value) - if isNil { - continue - } - - if value.Kind() == reflect.Struct { - var err error - if result, err = j.findFieldInValue(&value, node); err != nil { - return nil, err - } - } else if value.Kind() == reflect.Map { - mapKeyType := value.Type().Key() - nodeValue := reflect.ValueOf(node.Value) - // node value type must be convertible to map key type - if !nodeValue.Type().ConvertibleTo(mapKeyType) { - return results, fmt.Errorf("%s is not convertible to %s", nodeValue, mapKeyType) - } - result = value.MapIndex(nodeValue.Convert(mapKeyType)) - } - if result.IsValid() { - results = append(results, result) - } - } - if len(results) == 0 { - if j.allowMissingKeys { - return results, nil - } - return results, fmt.Errorf("%s is not found", node.Value) - } - return results, nil -} - -// evalWildcard extract all contents of the given value -func (j *JSONPath) evalWildcard(input []reflect.Value, node *WildcardNode) ([]reflect.Value, error) { - results := []reflect.Value{} - for _, value := range input { - value, isNil := template.Indirect(value) - if isNil { - continue - } - - kind := value.Kind() - if kind == reflect.Struct { - for i := 0; i < value.NumField(); i++ { - results = append(results, value.Field(i)) - } - } else if kind == reflect.Map { - for _, key := range value.MapKeys() { - results = append(results, value.MapIndex(key)) - } - } else if kind == reflect.Array || kind == reflect.Slice || kind == reflect.String { - for i := 0; i < value.Len(); i++ { - results = append(results, value.Index(i)) - } - } - } - return results, nil -} - -// evalRecursive visit the given value recursively and push all of them to result -func (j *JSONPath) evalRecursive(input []reflect.Value, node *RecursiveNode) ([]reflect.Value, error) { - result := []reflect.Value{} - for _, value := range input { - results := []reflect.Value{} - value, isNil := template.Indirect(value) - if isNil { - continue - } - - kind := value.Kind() - if kind == reflect.Struct { - for i := 0; i < value.NumField(); i++ { - results = append(results, value.Field(i)) - } - } else if kind == reflect.Map { - for _, key := range value.MapKeys() { - results = append(results, value.MapIndex(key)) - } - } else if kind == reflect.Array || kind == reflect.Slice || kind == reflect.String { - for i := 0; i < value.Len(); i++ { - results = append(results, value.Index(i)) - } - } - if len(results) != 0 { - result = append(result, value) - output, err := j.evalRecursive(results, node) - if err != nil { - return result, err - } - result = append(result, output...) - } - } - return result, nil -} - -// evalFilter filter array according to FilterNode -func (j *JSONPath) evalFilter(input []reflect.Value, node *FilterNode) ([]reflect.Value, error) { - results := []reflect.Value{} - for _, value := range input { - value, _ = template.Indirect(value) - - if value.Kind() != reflect.Array && value.Kind() != reflect.Slice { - return input, fmt.Errorf("%v is not array or slice and cannot be filtered", value) - } - for i := 0; i < value.Len(); i++ { - temp := []reflect.Value{value.Index(i)} - lefts, err := j.evalList(temp, node.Left) - - //case exists - if node.Operator == "exists" { - if len(lefts) > 0 { - results = append(results, value.Index(i)) - } - continue - } - - if err != nil { - return input, err - } - - var left, right interface{} - if len(lefts) != 1 { - return input, fmt.Errorf("can only compare one element at a time") - } - left = lefts[0].Interface() - - rights, err := j.evalList(temp, node.Right) - if err != nil { - return input, err - } - if len(rights) != 1 { - return input, fmt.Errorf("can only compare one element at a time") - } - right = rights[0].Interface() - - pass := false - switch node.Operator { - case "<": - pass, err = template.Less(left, right) - case ">": - pass, err = template.Greater(left, right) - case "==": - pass, err = template.Equal(left, right) - case "!=": - pass, err = template.NotEqual(left, right) - case "<=": - pass, err = template.LessEqual(left, right) - case ">=": - pass, err = template.GreaterEqual(left, right) - default: - return results, fmt.Errorf("unrecognized filter operator %s", node.Operator) - } - if err != nil { - return results, err - } - if pass { - results = append(results, value.Index(i)) - } - } - } - return results, nil -} - -// evalToText translates reflect value to corresponding text -func (j *JSONPath) evalToText(v reflect.Value) ([]byte, error) { - iface, ok := template.PrintableValue(v) - if !ok { - return nil, fmt.Errorf("can't print type %s", v.Type()) - } - var buffer bytes.Buffer - fmt.Fprint(&buffer, iface) - return buffer.Bytes(), nil -} diff --git a/vendor/k8s.io/client-go/pkg/util/jsonpath/node.go b/vendor/k8s.io/client-go/pkg/util/jsonpath/node.go deleted file mode 100644 index f0a27853d8..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/jsonpath/node.go +++ /dev/null @@ -1,239 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package jsonpath - -import "fmt" - -// NodeType identifies the type of a parse tree node. -type NodeType int - -// Type returns itself and provides an easy default implementation -func (t NodeType) Type() NodeType { - return t -} - -func (t NodeType) String() string { - return NodeTypeName[t] -} - -const ( - NodeText NodeType = iota - NodeArray - NodeList - NodeField - NodeIdentifier - NodeFilter - NodeInt - NodeFloat - NodeWildcard - NodeRecursive - NodeUnion -) - -var NodeTypeName = map[NodeType]string{ - NodeText: "NodeText", - NodeArray: "NodeArray", - NodeList: "NodeList", - NodeField: "NodeField", - NodeIdentifier: "NodeIdentifier", - NodeFilter: "NodeFilter", - NodeInt: "NodeInt", - NodeFloat: "NodeFloat", - NodeWildcard: "NodeWildcard", - NodeRecursive: "NodeRecursive", - NodeUnion: "NodeUnion", -} - -type Node interface { - Type() NodeType - String() string -} - -// ListNode holds a sequence of nodes. -type ListNode struct { - NodeType - Nodes []Node // The element nodes in lexical order. -} - -func newList() *ListNode { - return &ListNode{NodeType: NodeList} -} - -func (l *ListNode) append(n Node) { - l.Nodes = append(l.Nodes, n) -} - -func (l *ListNode) String() string { - return fmt.Sprintf("%s", l.Type()) -} - -// TextNode holds plain text. -type TextNode struct { - NodeType - Text string // The text; may span newlines. -} - -func newText(text string) *TextNode { - return &TextNode{NodeType: NodeText, Text: text} -} - -func (t *TextNode) String() string { - return fmt.Sprintf("%s: %s", t.Type(), t.Text) -} - -// FieldNode holds field of struct -type FieldNode struct { - NodeType - Value string -} - -func newField(value string) *FieldNode { - return &FieldNode{NodeType: NodeField, Value: value} -} - -func (f *FieldNode) String() string { - return fmt.Sprintf("%s: %s", f.Type(), f.Value) -} - -// IdentifierNode holds an identifier -type IdentifierNode struct { - NodeType - Name string -} - -func newIdentifier(value string) *IdentifierNode { - return &IdentifierNode{ - NodeType: NodeIdentifier, - Name: value, - } -} - -func (f *IdentifierNode) String() string { - return fmt.Sprintf("%s: %s", f.Type(), f.Name) -} - -// ParamsEntry holds param information for ArrayNode -type ParamsEntry struct { - Value int - Known bool //whether the value is known when parse it -} - -// ArrayNode holds start, end, step information for array index selection -type ArrayNode struct { - NodeType - Params [3]ParamsEntry //start, end, step -} - -func newArray(params [3]ParamsEntry) *ArrayNode { - return &ArrayNode{ - NodeType: NodeArray, - Params: params, - } -} - -func (a *ArrayNode) String() string { - return fmt.Sprintf("%s: %v", a.Type(), a.Params) -} - -// FilterNode holds operand and operator information for filter -type FilterNode struct { - NodeType - Left *ListNode - Right *ListNode - Operator string -} - -func newFilter(left, right *ListNode, operator string) *FilterNode { - return &FilterNode{ - NodeType: NodeFilter, - Left: left, - Right: right, - Operator: operator, - } -} - -func (f *FilterNode) String() string { - return fmt.Sprintf("%s: %s %s %s", f.Type(), f.Left, f.Operator, f.Right) -} - -// IntNode holds integer value -type IntNode struct { - NodeType - Value int -} - -func newInt(num int) *IntNode { - return &IntNode{NodeType: NodeInt, Value: num} -} - -func (i *IntNode) String() string { - return fmt.Sprintf("%s: %d", i.Type(), i.Value) -} - -// FloatNode holds float value -type FloatNode struct { - NodeType - Value float64 -} - -func newFloat(num float64) *FloatNode { - return &FloatNode{NodeType: NodeFloat, Value: num} -} - -func (i *FloatNode) String() string { - return fmt.Sprintf("%s: %f", i.Type(), i.Value) -} - -// WildcardNode means a wildcard -type WildcardNode struct { - NodeType -} - -func newWildcard() *WildcardNode { - return &WildcardNode{NodeType: NodeWildcard} -} - -func (i *WildcardNode) String() string { - return fmt.Sprintf("%s", i.Type()) -} - -// RecursiveNode means a recursive descent operator -type RecursiveNode struct { - NodeType -} - -func newRecursive() *RecursiveNode { - return &RecursiveNode{NodeType: NodeRecursive} -} - -func (r *RecursiveNode) String() string { - return fmt.Sprintf("%s", r.Type()) -} - -// UnionNode is union of ListNode -type UnionNode struct { - NodeType - Nodes []*ListNode -} - -func newUnion(nodes []*ListNode) *UnionNode { - return &UnionNode{NodeType: NodeUnion, Nodes: nodes} -} - -func (u *UnionNode) String() string { - return fmt.Sprintf("%s", u.Type()) -} diff --git a/vendor/k8s.io/client-go/pkg/util/jsonpath/parser.go b/vendor/k8s.io/client-go/pkg/util/jsonpath/parser.go deleted file mode 100644 index 7dc38d31fc..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/jsonpath/parser.go +++ /dev/null @@ -1,433 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package jsonpath - -import ( - "fmt" - "regexp" - "strconv" - "strings" - "unicode" - "unicode/utf8" -) - -const eof = -1 - -const ( - leftDelim = "{" - rightDelim = "}" -) - -type Parser struct { - Name string - Root *ListNode - input string - cur *ListNode - pos int - start int - width int -} - -// Parse parsed the given text and return a node Parser. -// If an error is encountered, parsing stops and an empty -// Parser is returned with the error -func Parse(name, text string) (*Parser, error) { - p := NewParser(name) - err := p.Parse(text) - if err != nil { - p = nil - } - return p, err -} - -func NewParser(name string) *Parser { - return &Parser{ - Name: name, - } -} - -// parseAction parsed the expression inside delimiter -func parseAction(name, text string) (*Parser, error) { - p, err := Parse(name, fmt.Sprintf("%s%s%s", leftDelim, text, rightDelim)) - // when error happens, p will be nil, so we need to return here - if err != nil { - return p, err - } - p.Root = p.Root.Nodes[0].(*ListNode) - return p, nil -} - -func (p *Parser) Parse(text string) error { - p.input = text - p.Root = newList() - p.pos = 0 - return p.parseText(p.Root) -} - -// consumeText return the parsed text since last cosumeText -func (p *Parser) consumeText() string { - value := p.input[p.start:p.pos] - p.start = p.pos - return value -} - -// next returns the next rune in the input. -func (p *Parser) next() rune { - if int(p.pos) >= len(p.input) { - p.width = 0 - return eof - } - r, w := utf8.DecodeRuneInString(p.input[p.pos:]) - p.width = w - p.pos += p.width - return r -} - -// peek returns but does not consume the next rune in the input. -func (p *Parser) peek() rune { - r := p.next() - p.backup() - return r -} - -// backup steps back one rune. Can only be called once per call of next. -func (p *Parser) backup() { - p.pos -= p.width -} - -func (p *Parser) parseText(cur *ListNode) error { - for { - if strings.HasPrefix(p.input[p.pos:], leftDelim) { - if p.pos > p.start { - cur.append(newText(p.consumeText())) - } - return p.parseLeftDelim(cur) - } - if p.next() == eof { - break - } - } - // Correctly reached EOF. - if p.pos > p.start { - cur.append(newText(p.consumeText())) - } - return nil -} - -// parseLeftDelim scans the left delimiter, which is known to be present. -func (p *Parser) parseLeftDelim(cur *ListNode) error { - p.pos += len(leftDelim) - p.consumeText() - newNode := newList() - cur.append(newNode) - cur = newNode - return p.parseInsideAction(cur) -} - -func (p *Parser) parseInsideAction(cur *ListNode) error { - prefixMap := map[string]func(*ListNode) error{ - rightDelim: p.parseRightDelim, - "[?(": p.parseFilter, - "..": p.parseRecursive, - } - for prefix, parseFunc := range prefixMap { - if strings.HasPrefix(p.input[p.pos:], prefix) { - return parseFunc(cur) - } - } - - switch r := p.next(); { - case r == eof || isEndOfLine(r): - return fmt.Errorf("unclosed action") - case r == ' ': - p.consumeText() - case r == '@' || r == '$': //the current object, just pass it - p.consumeText() - case r == '[': - return p.parseArray(cur) - case r == '"': - return p.parseQuote(cur) - case r == '.': - return p.parseField(cur) - case r == '+' || r == '-' || unicode.IsDigit(r): - p.backup() - return p.parseNumber(cur) - case isAlphaNumeric(r): - p.backup() - return p.parseIdentifier(cur) - default: - return fmt.Errorf("unrecognized character in action: %#U", r) - } - return p.parseInsideAction(cur) -} - -// parseRightDelim scans the right delimiter, which is known to be present. -func (p *Parser) parseRightDelim(cur *ListNode) error { - p.pos += len(rightDelim) - p.consumeText() - cur = p.Root - return p.parseText(cur) -} - -// parseIdentifier scans build-in keywords, like "range" "end" -func (p *Parser) parseIdentifier(cur *ListNode) error { - var r rune - for { - r = p.next() - if isTerminator(r) { - p.backup() - break - } - } - value := p.consumeText() - cur.append(newIdentifier(value)) - return p.parseInsideAction(cur) -} - -// parseRecursive scans the recursive desent operator .. -func (p *Parser) parseRecursive(cur *ListNode) error { - p.pos += len("..") - p.consumeText() - cur.append(newRecursive()) - if r := p.peek(); isAlphaNumeric(r) { - return p.parseField(cur) - } - return p.parseInsideAction(cur) -} - -// parseNumber scans number -func (p *Parser) parseNumber(cur *ListNode) error { - r := p.peek() - if r == '+' || r == '-' { - r = p.next() - } - for { - r = p.next() - if r != '.' && !unicode.IsDigit(r) { - p.backup() - break - } - } - value := p.consumeText() - i, err := strconv.Atoi(value) - if err == nil { - cur.append(newInt(i)) - return p.parseInsideAction(cur) - } - d, err := strconv.ParseFloat(value, 64) - if err == nil { - cur.append(newFloat(d)) - return p.parseInsideAction(cur) - } - return fmt.Errorf("cannot parse number %s", value) -} - -// parseArray scans array index selection -func (p *Parser) parseArray(cur *ListNode) error { -Loop: - for { - switch p.next() { - case eof, '\n': - return fmt.Errorf("unterminated array") - case ']': - break Loop - } - } - text := p.consumeText() - text = string(text[1 : len(text)-1]) - if text == "*" { - text = ":" - } - - //union operator - strs := strings.Split(text, ",") - if len(strs) > 1 { - union := []*ListNode{} - for _, str := range strs { - parser, err := parseAction("union", fmt.Sprintf("[%s]", strings.Trim(str, " "))) - if err != nil { - return err - } - union = append(union, parser.Root) - } - cur.append(newUnion(union)) - return p.parseInsideAction(cur) - } - - // dict key - reg := regexp.MustCompile(`^'([^']*)'$`) - value := reg.FindStringSubmatch(text) - if value != nil { - parser, err := parseAction("arraydict", fmt.Sprintf(".%s", value[1])) - if err != nil { - return err - } - for _, node := range parser.Root.Nodes { - cur.append(node) - } - return p.parseInsideAction(cur) - } - - //slice operator - reg = regexp.MustCompile(`^(-?[\d]*)(:-?[\d]*)?(:[\d]*)?$`) - value = reg.FindStringSubmatch(text) - if value == nil { - return fmt.Errorf("invalid array index %s", text) - } - value = value[1:] - params := [3]ParamsEntry{} - for i := 0; i < 3; i++ { - if value[i] != "" { - if i > 0 { - value[i] = value[i][1:] - } - if i > 0 && value[i] == "" { - params[i].Known = false - } else { - var err error - params[i].Known = true - params[i].Value, err = strconv.Atoi(value[i]) - if err != nil { - return fmt.Errorf("array index %s is not a number", value[i]) - } - } - } else { - if i == 1 { - params[i].Known = true - params[i].Value = params[0].Value + 1 - } else { - params[i].Known = false - params[i].Value = 0 - } - } - } - cur.append(newArray(params)) - return p.parseInsideAction(cur) -} - -// parseFilter scans filter inside array selection -func (p *Parser) parseFilter(cur *ListNode) error { - p.pos += len("[?(") - p.consumeText() -Loop: - for { - switch p.next() { - case eof, '\n': - return fmt.Errorf("unterminated filter") - case ')': - break Loop - } - } - if p.next() != ']' { - return fmt.Errorf("unclosed array expect ]") - } - reg := regexp.MustCompile(`^([^!<>=]+)([!<>=]+)(.+?)$`) - text := p.consumeText() - text = string(text[:len(text)-2]) - value := reg.FindStringSubmatch(text) - if value == nil { - parser, err := parseAction("text", text) - if err != nil { - return err - } - cur.append(newFilter(parser.Root, newList(), "exists")) - } else { - leftParser, err := parseAction("left", value[1]) - if err != nil { - return err - } - rightParser, err := parseAction("right", value[3]) - if err != nil { - return err - } - cur.append(newFilter(leftParser.Root, rightParser.Root, value[2])) - } - return p.parseInsideAction(cur) -} - -// parseQuote unquotes string inside double quote -func (p *Parser) parseQuote(cur *ListNode) error { -Loop: - for { - switch p.next() { - case eof, '\n': - return fmt.Errorf("unterminated quoted string") - case '"': - break Loop - } - } - value := p.consumeText() - s, err := strconv.Unquote(value) - if err != nil { - return fmt.Errorf("unquote string %s error %v", value, err) - } - cur.append(newText(s)) - return p.parseInsideAction(cur) -} - -// parseField scans a field until a terminator -func (p *Parser) parseField(cur *ListNode) error { - p.consumeText() - for p.advance() { - } - value := p.consumeText() - if value == "*" { - cur.append(newWildcard()) - } else { - cur.append(newField(strings.Replace(value, "\\", "", -1))) - } - return p.parseInsideAction(cur) -} - -// advance scans until next non-escaped terminator -func (p *Parser) advance() bool { - r := p.next() - if r == '\\' { - p.next() - } else if isTerminator(r) { - p.backup() - return false - } - return true -} - -// isTerminator reports whether the input is at valid termination character to appear after an identifier. -func isTerminator(r rune) bool { - if isSpace(r) || isEndOfLine(r) { - return true - } - switch r { - case eof, '.', ',', '[', ']', '$', '@', '{', '}': - return true - } - return false -} - -// isSpace reports whether r is a space character. -func isSpace(r rune) bool { - return r == ' ' || r == '\t' -} - -// isEndOfLine reports whether r is an end-of-line character. -func isEndOfLine(r rune) bool { - return r == '\r' || r == '\n' -} - -// isAlphaNumeric reports whether r is an alphabetic, digit, or underscore. -func isAlphaNumeric(r rune) bool { - return r == '_' || unicode.IsLetter(r) || unicode.IsDigit(r) -} diff --git a/vendor/k8s.io/client-go/pkg/util/parsers/BUILD b/vendor/k8s.io/client-go/pkg/util/parsers/BUILD new file mode 100644 index 0000000000..501d7a9b57 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/util/parsers/BUILD @@ -0,0 +1,15 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["parsers.go"], + tags = ["automanaged"], + deps = ["//vendor/github.com/docker/distribution/reference:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/ratelimit/bucket.go b/vendor/k8s.io/client-go/pkg/util/ratelimit/bucket.go deleted file mode 100644 index 752a251d05..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/ratelimit/bucket.go +++ /dev/null @@ -1,170 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package ratelimit - -import ( - "math" - "sync" - "time" -) - -// Bucket models a token bucket -type Bucket struct { - unitsPerNano float64 - nanosPerUnit float64 - capacity int64 - - mutex sync.Mutex - available int64 - lastRefill int64 - // fractionalAvailable "buffers" any amounts that flowed into the bucket smaller than one unit - // This lets us retain precision even with pathological refill rates like (1E9 + 1) per second - fractionalAvailable float64 -} - -// NewBucketWithRate creates a new token bucket, with maximum capacity = initial capacity, and a refill rate of qps -// We use floats for refill calculations, which introduces the possibility of truncation and rounding errors. -// For "sensible" qps values though, is is acceptable: jbeda did some tests here https://play.golang.org/p/LSKUOGz2LG -func NewBucketWithRate(qps float64, capacity int64) *Bucket { - unitsPerNano := qps / 1E9 - nanosPerUnit := 1E9 / qps - b := &Bucket{ - unitsPerNano: unitsPerNano, - nanosPerUnit: nanosPerUnit, - capacity: capacity, - available: capacity, - lastRefill: time.Now().UnixNano(), - } - return b -} - -// Take takes n units from the bucket, reducing the available quantity even below zero, -// but then returns the amount of time we should wait -func (b *Bucket) Take(n int64) time.Duration { - b.mutex.Lock() - defer b.mutex.Unlock() - - var d time.Duration - if b.available >= n { - // Fast path when bucket has sufficient availability before refilling - } else { - b.refill() - - if b.available < n { - deficit := n - b.available - d = time.Duration(int64(float64(deficit) * b.nanosPerUnit)) - } - } - - b.available -= n - - return d -} - -// TakeAvailable immediately takes whatever quantity is available, up to max -func (b *Bucket) TakeAvailable(max int64) int64 { - b.mutex.Lock() - defer b.mutex.Unlock() - - var took int64 - if b.available >= max { - // Fast path when bucket has sufficient availability before refilling - took = max - } else { - b.refill() - - took = b.available - - if took < 0 { - took = 0 - } else if took > max { - took = max - } - } - - if took > 0 { - b.available -= took - } - - return took -} - -// Wait combines a call to Take with a sleep call -func (b *Bucket) Wait(n int64) { - d := b.Take(n) - if d != 0 { - time.Sleep(d) - } -} - -// Capacity returns the maximum capacity of the bucket -func (b *Bucket) Capacity() int64 { - return b.capacity -} - -// Available returns the quantity available in the bucket (which may be negative), but does not take it. -// This function is for diagnostic / informational purposes only - the returned capacity may immediately -// be inaccurate if another thread is operating on the bucket concurrently. -func (b *Bucket) Available() int64 { - b.mutex.Lock() - defer b.mutex.Unlock() - - b.refill() - - return b.available -} - -// refill replenishes the bucket based on elapsed time; mutex must be held -func (b *Bucket) refill() { - // Note that we really want a monotonic clock here, but go says no: - // https://github.com/golang/go/issues/12914 - now := time.Now().UnixNano() - - b.refillAtTimestamp(now) -} - -// refillAtTimestamp is the logic of the refill function, for testing -func (b *Bucket) refillAtTimestamp(now int64) { - nanosSinceLastRefill := now - b.lastRefill - if nanosSinceLastRefill <= 0 { - // we really want monotonic - return - } - - // Compute units that have flowed into bucket - refillFloat := (float64(nanosSinceLastRefill) * b.unitsPerNano) + b.fractionalAvailable - if refillFloat > float64(b.capacity) { - // float64 > MaxInt64 can be converted to negative int64; side step this - b.available = b.capacity - - // Don't worry about the fractional units with huge refill rates - } else { - whole, fraction := math.Modf(refillFloat) - refill := int64(whole) - b.fractionalAvailable = fraction - if refill != 0 { - // Refill with overflow - b.available += refill - if b.available >= b.capacity { - b.available = b.capacity - b.fractionalAvailable = 0 - } - } - - } - b.lastRefill = now -} diff --git a/vendor/k8s.io/client-go/pkg/util/trace.go b/vendor/k8s.io/client-go/pkg/util/trace.go deleted file mode 100644 index fe93db8df6..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/trace.go +++ /dev/null @@ -1,72 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package util - -import ( - "bytes" - "fmt" - "time" - - "github.com/golang/glog" -) - -type traceStep struct { - stepTime time.Time - msg string -} - -type Trace struct { - name string - startTime time.Time - steps []traceStep -} - -func NewTrace(name string) *Trace { - return &Trace{name, time.Now(), nil} -} - -func (t *Trace) Step(msg string) { - if t.steps == nil { - // traces almost always have less than 6 steps, do this to avoid more than a single allocation - t.steps = make([]traceStep, 0, 6) - } - t.steps = append(t.steps, traceStep{time.Now(), msg}) -} - -func (t *Trace) Log() { - endTime := time.Now() - var buffer bytes.Buffer - - buffer.WriteString(fmt.Sprintf("Trace %q (started %v):\n", t.name, t.startTime)) - lastStepTime := t.startTime - for _, step := range t.steps { - buffer.WriteString(fmt.Sprintf("[%v] [%v] %v\n", step.stepTime.Sub(t.startTime), step.stepTime.Sub(lastStepTime), step.msg)) - lastStepTime = step.stepTime - } - buffer.WriteString(fmt.Sprintf("[%v] [%v] END\n", endTime.Sub(t.startTime), endTime.Sub(lastStepTime))) - glog.Info(buffer.String()) -} - -func (t *Trace) LogIfLong(threshold time.Duration) { - if time.Since(t.startTime) >= threshold { - t.Log() - } -} - -func (t *Trace) TotalTime() time.Duration { - return time.Since(t.startTime) -} diff --git a/vendor/k8s.io/client-go/pkg/util/trie.go b/vendor/k8s.io/client-go/pkg/util/trie.go deleted file mode 100644 index 0eeac436dc..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/trie.go +++ /dev/null @@ -1,79 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package util - -// A simple trie implementation with Add an HasPrefix methods only. -type Trie struct { - children map[byte]*Trie - wordTail bool - word string -} - -// CreateTrie creates a Trie and add all strings in the provided list to it. -func CreateTrie(list []string) Trie { - ret := Trie{ - children: make(map[byte]*Trie), - wordTail: false, - } - for _, v := range list { - ret.Add(v) - } - return ret -} - -// Add adds a word to this trie -func (t *Trie) Add(v string) { - root := t - for _, b := range []byte(v) { - child, exists := root.children[b] - if !exists { - child = &Trie{ - children: make(map[byte]*Trie), - wordTail: false, - } - root.children[b] = child - } - root = child - } - root.wordTail = true - root.word = v -} - -// HasPrefix returns true of v has any of the prefixes stored in this trie. -func (t *Trie) HasPrefix(v string) bool { - _, has := t.GetPrefix(v) - return has -} - -// GetPrefix is like HasPrefix but return the prefix in case of match or empty string otherwise. -func (t *Trie) GetPrefix(v string) (string, bool) { - root := t - if root.wordTail { - return root.word, true - } - for _, b := range []byte(v) { - child, exists := root.children[b] - if !exists { - return "", false - } - if child.wordTail { - return child.word, true - } - root = child - } - return "", false -} diff --git a/vendor/k8s.io/client-go/pkg/util/umask_windows.go b/vendor/k8s.io/client-go/pkg/util/umask_windows.go index 8c1b2cbc7d..7a1ba15386 100644 --- a/vendor/k8s.io/client-go/pkg/util/umask_windows.go +++ b/vendor/k8s.io/client-go/pkg/util/umask_windows.go @@ -22,6 +22,6 @@ import ( "errors" ) -func Umask(mask int) (old int, err error) { +func Umask(mask int) (int, error) { return 0, errors.New("platform and architecture is not supported") } diff --git a/vendor/k8s.io/client-go/pkg/util/uuid/uuid.go b/vendor/k8s.io/client-go/pkg/util/uuid/uuid.go deleted file mode 100644 index ad0e8a6a4f..0000000000 --- a/vendor/k8s.io/client-go/pkg/util/uuid/uuid.go +++ /dev/null @@ -1,42 +0,0 @@ -/* -Copyright 2014 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package uuid - -import ( - "sync" - - "github.com/pborman/uuid" - "k8s.io/client-go/pkg/types" -) - -var uuidLock sync.Mutex -var lastUUID uuid.UUID - -func NewUUID() types.UID { - uuidLock.Lock() - defer uuidLock.Unlock() - result := uuid.NewUUID() - // The UUID package is naive and can generate identical UUIDs if the - // time interval is quick enough. - // The UUID uses 100 ns increments so it's short enough to actively - // wait for a new value. - for uuid.Equal(lastUUID, result) == true { - result = uuid.NewUUID() - } - lastUUID = result - return types.UID(result.String()) -} diff --git a/vendor/k8s.io/client-go/pkg/version/BUILD b/vendor/k8s.io/client-go/pkg/version/BUILD new file mode 100644 index 0000000000..5b51d0dfef --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/version/BUILD @@ -0,0 +1,19 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "base.go", + "doc.go", + "version.go", + ], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/version:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/pkg/version/base.go b/vendor/k8s.io/client-go/pkg/version/base.go index 5909815202..0762697303 100644 --- a/vendor/k8s.io/client-go/pkg/version/base.go +++ b/vendor/k8s.io/client-go/pkg/version/base.go @@ -29,7 +29,7 @@ package version // works for GitHub tar downloads. // // When releasing a new Kubernetes version, this file is updated by -// build-tools/mark_new_version.sh to reflect the new version, and then a +// build/mark_new_version.sh to reflect the new version, and then a // git annotated tag (using format vX.Y where X == Major version and Y // == Minor version) is created to point to the commit that updates // pkg/version/base.go @@ -39,8 +39,8 @@ var ( // them irrelevant. (Next we'll take it out, which may muck with // scripts consuming the kubectl version output - but most of // these should be looking at gitVersion already anyways.) - gitMajor string = "" // major version, always numeric - gitMinor string = "" // minor version, numeric possibly followed by "+" + gitMajor string = "1" // major version, always numeric + gitMinor string = "7+" // minor version, numeric possibly followed by "+" // semantic version, derived by build scripts (see // https://github.com/kubernetes/kubernetes/blob/master/docs/design/versioning.md @@ -51,7 +51,7 @@ var ( // semantic version is a git hash, but the version itself is no // longer the direct output of "git describe", but a slight // translation to be semver compliant. - gitVersion string = "v0.0.0-master+$Format:%h$" + gitVersion string = "v1.7.1-beta.0+$Format:%h$" gitCommit string = "$Format:%H$" // sha1 from git, output of $(git rev-parse HEAD) gitTreeState string = "not a git tree" // state of git tree, either "clean" or "dirty" diff --git a/vendor/k8s.io/client-go/pkg/version/def.bzl b/vendor/k8s.io/client-go/pkg/version/def.bzl new file mode 100644 index 0000000000..bca85ab4b5 --- /dev/null +++ b/vendor/k8s.io/client-go/pkg/version/def.bzl @@ -0,0 +1,24 @@ +# Implements hack/lib/version.sh's kube::version::ldflags() for Bazel. +def version_x_defs(): + # This should match the list of packages in kube::version::ldflag + stamp_pkgs = [ + "k8s.io/kubernetes/pkg/version", + # In hack/lib/version.sh, this has a vendor/ prefix. That isn't needed here? + "k8s.io/client-go/pkg/version", + ] + # This should match the list of vars in kube::version::ldflags + # It should also match the list of vars set in hack/print-workspace-status.sh. + stamp_vars = [ + "buildDate", + "gitCommit", + "gitMajor", + "gitMinor", + "gitTreeState", + "gitVersion", + ] + # Generate the cross-product. + x_defs = {} + for pkg in stamp_pkgs: + for var in stamp_vars: + x_defs["%s.%s" % (pkg, var)] = "{%s}" % var + return x_defs diff --git a/vendor/k8s.io/client-go/pkg/version/doc.go b/vendor/k8s.io/client-go/pkg/version/doc.go index 3803957848..ccedec76f6 100644 --- a/vendor/k8s.io/client-go/pkg/version/doc.go +++ b/vendor/k8s.io/client-go/pkg/version/doc.go @@ -16,5 +16,4 @@ limitations under the License. // Package version supplies version information collected at build time to // kubernetes components. -// +k8s:openapi-gen=true package version diff --git a/vendor/k8s.io/client-go/pkg/version/semver.go b/vendor/k8s.io/client-go/pkg/version/semver.go deleted file mode 100644 index 1f4067e217..0000000000 --- a/vendor/k8s.io/client-go/pkg/version/semver.go +++ /dev/null @@ -1,50 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package version - -import ( - "strings" - "unicode" - - "github.com/blang/semver" - "github.com/golang/glog" -) - -func Parse(gitversion string) (semver.Version, error) { - // optionally trim leading spaces then one v - var seen bool - gitversion = strings.TrimLeftFunc(gitversion, func(ch rune) bool { - if seen { - return false - } - if ch == 'v' { - seen = true - return true - } - return unicode.IsSpace(ch) - }) - - return semver.Make(gitversion) -} - -func MustParse(gitversion string) semver.Version { - v, err := Parse(gitversion) - if err != nil { - glog.Fatalf("failed to parse semver from gitversion %q: %v", gitversion, err) - } - return v -} diff --git a/vendor/k8s.io/client-go/pkg/version/version.go b/vendor/k8s.io/client-go/pkg/version/version.go index 0da3aadde0..8c8350d13b 100644 --- a/vendor/k8s.io/client-go/pkg/version/version.go +++ b/vendor/k8s.io/client-go/pkg/version/version.go @@ -19,29 +19,16 @@ package version import ( "fmt" "runtime" -) -// Info contains versioning information. -// TODO: Add []string of api versions supported? It's still unclear -// how we'll want to distribute that information. -type Info struct { - Major string `json:"major"` - Minor string `json:"minor"` - GitVersion string `json:"gitVersion"` - GitCommit string `json:"gitCommit"` - GitTreeState string `json:"gitTreeState"` - BuildDate string `json:"buildDate"` - GoVersion string `json:"goVersion"` - Compiler string `json:"compiler"` - Platform string `json:"platform"` -} + apimachineryversion "k8s.io/apimachinery/pkg/version" +) // Get returns the overall codebase version. It's for detecting // what code a binary was built from. -func Get() Info { +func Get() apimachineryversion.Info { // These variables typically come from -ldflags settings and in // their absence fallback to the settings in pkg/version/base.go - return Info{ + return apimachineryversion.Info{ Major: gitMajor, Minor: gitMinor, GitVersion: gitVersion, @@ -53,8 +40,3 @@ func Get() Info { Platform: fmt.Sprintf("%s/%s", runtime.GOOS, runtime.GOARCH), } } - -// String returns info as a human-friendly version string. -func (info Info) String() string { - return info.GitVersion -} diff --git a/vendor/k8s.io/client-go/pkg/watch/versioned/generated.pb.go b/vendor/k8s.io/client-go/pkg/watch/versioned/generated.pb.go deleted file mode 100644 index b26080e7f6..0000000000 --- a/vendor/k8s.io/client-go/pkg/watch/versioned/generated.pb.go +++ /dev/null @@ -1,390 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Code generated by protoc-gen-gogo. -// source: k8s.io/kubernetes/pkg/watch/versioned/generated.proto -// DO NOT EDIT! - -/* - Package versioned is a generated protocol buffer package. - - It is generated from these files: - k8s.io/kubernetes/pkg/watch/versioned/generated.proto - - It has these top-level messages: - Event -*/ -package versioned - -import proto "github.com/gogo/protobuf/proto" -import fmt "fmt" -import math "math" - -import strings "strings" -import reflect "reflect" - -import io "io" - -// Reference imports to suppress errors if they are not otherwise used. -var _ = proto.Marshal -var _ = fmt.Errorf -var _ = math.Inf - -// This is a compile-time assertion to ensure that this generated file -// is compatible with the proto package it is being compiled against. -const _ = proto.GoGoProtoPackageIsVersion1 - -func (m *Event) Reset() { *m = Event{} } -func (*Event) ProtoMessage() {} -func (*Event) Descriptor() ([]byte, []int) { return fileDescriptorGenerated, []int{0} } - -func init() { - proto.RegisterType((*Event)(nil), "k8s.io.client-go.pkg.watch.versioned.Event") -} -func (m *Event) Marshal() (data []byte, err error) { - size := m.Size() - data = make([]byte, size) - n, err := m.MarshalTo(data) - if err != nil { - return nil, err - } - return data[:n], nil -} - -func (m *Event) MarshalTo(data []byte) (int, error) { - var i int - _ = i - var l int - _ = l - data[i] = 0xa - i++ - i = encodeVarintGenerated(data, i, uint64(len(m.Type))) - i += copy(data[i:], m.Type) - data[i] = 0x12 - i++ - i = encodeVarintGenerated(data, i, uint64(m.Object.Size())) - n1, err := m.Object.MarshalTo(data[i:]) - if err != nil { - return 0, err - } - i += n1 - return i, nil -} - -func encodeFixed64Generated(data []byte, offset int, v uint64) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - data[offset+4] = uint8(v >> 32) - data[offset+5] = uint8(v >> 40) - data[offset+6] = uint8(v >> 48) - data[offset+7] = uint8(v >> 56) - return offset + 8 -} -func encodeFixed32Generated(data []byte, offset int, v uint32) int { - data[offset] = uint8(v) - data[offset+1] = uint8(v >> 8) - data[offset+2] = uint8(v >> 16) - data[offset+3] = uint8(v >> 24) - return offset + 4 -} -func encodeVarintGenerated(data []byte, offset int, v uint64) int { - for v >= 1<<7 { - data[offset] = uint8(v&0x7f | 0x80) - v >>= 7 - offset++ - } - data[offset] = uint8(v) - return offset + 1 -} -func (m *Event) Size() (n int) { - var l int - _ = l - l = len(m.Type) - n += 1 + l + sovGenerated(uint64(l)) - l = m.Object.Size() - n += 1 + l + sovGenerated(uint64(l)) - return n -} - -func sovGenerated(x uint64) (n int) { - for { - n++ - x >>= 7 - if x == 0 { - break - } - } - return n -} -func sozGenerated(x uint64) (n int) { - return sovGenerated(uint64((x << 1) ^ uint64((int64(x) >> 63)))) -} -func (this *Event) String() string { - if this == nil { - return "nil" - } - s := strings.Join([]string{`&Event{`, - `Type:` + fmt.Sprintf("%v", this.Type) + `,`, - `Object:` + strings.Replace(strings.Replace(this.Object.String(), "RawExtension", "k8s_io_kubernetes_pkg_runtime.RawExtension", 1), `&`, ``, 1) + `,`, - `}`, - }, "") - return s -} -func valueToStringGenerated(v interface{}) string { - rv := reflect.ValueOf(v) - if rv.IsNil() { - return "nil" - } - pv := reflect.Indirect(rv).Interface() - return fmt.Sprintf("*%v", pv) -} -func (m *Event) Unmarshal(data []byte) error { - l := len(data) - iNdEx := 0 - for iNdEx < l { - preIndex := iNdEx - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - fieldNum := int32(wire >> 3) - wireType := int(wire & 0x7) - if wireType == 4 { - return fmt.Errorf("proto: Event: wiretype end group for non-group") - } - if fieldNum <= 0 { - return fmt.Errorf("proto: Event: illegal tag %d (wire type %d)", fieldNum, wire) - } - switch fieldNum { - case 1: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType) - } - var stringLen uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - stringLen |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - intStringLen := int(stringLen) - if intStringLen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + intStringLen - if postIndex > l { - return io.ErrUnexpectedEOF - } - m.Type = string(data[iNdEx:postIndex]) - iNdEx = postIndex - case 2: - if wireType != 2 { - return fmt.Errorf("proto: wrong wireType = %d for field Object", wireType) - } - var msglen int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return ErrIntOverflowGenerated - } - if iNdEx >= l { - return io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - msglen |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - if msglen < 0 { - return ErrInvalidLengthGenerated - } - postIndex := iNdEx + msglen - if postIndex > l { - return io.ErrUnexpectedEOF - } - if err := m.Object.Unmarshal(data[iNdEx:postIndex]); err != nil { - return err - } - iNdEx = postIndex - default: - iNdEx = preIndex - skippy, err := skipGenerated(data[iNdEx:]) - if err != nil { - return err - } - if skippy < 0 { - return ErrInvalidLengthGenerated - } - if (iNdEx + skippy) > l { - return io.ErrUnexpectedEOF - } - iNdEx += skippy - } - } - - if iNdEx > l { - return io.ErrUnexpectedEOF - } - return nil -} -func skipGenerated(data []byte) (n int, err error) { - l := len(data) - iNdEx := 0 - for iNdEx < l { - var wire uint64 - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - wire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - wireType := int(wire & 0x7) - switch wireType { - case 0: - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - iNdEx++ - if data[iNdEx-1] < 0x80 { - break - } - } - return iNdEx, nil - case 1: - iNdEx += 8 - return iNdEx, nil - case 2: - var length int - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - length |= (int(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - iNdEx += length - if length < 0 { - return 0, ErrInvalidLengthGenerated - } - return iNdEx, nil - case 3: - for { - var innerWire uint64 - var start int = iNdEx - for shift := uint(0); ; shift += 7 { - if shift >= 64 { - return 0, ErrIntOverflowGenerated - } - if iNdEx >= l { - return 0, io.ErrUnexpectedEOF - } - b := data[iNdEx] - iNdEx++ - innerWire |= (uint64(b) & 0x7F) << shift - if b < 0x80 { - break - } - } - innerWireType := int(innerWire & 0x7) - if innerWireType == 4 { - break - } - next, err := skipGenerated(data[start:]) - if err != nil { - return 0, err - } - iNdEx = start + next - } - return iNdEx, nil - case 4: - return iNdEx, nil - case 5: - iNdEx += 4 - return iNdEx, nil - default: - return 0, fmt.Errorf("proto: illegal wireType %d", wireType) - } - } - panic("unreachable") -} - -var ( - ErrInvalidLengthGenerated = fmt.Errorf("proto: negative length found during unmarshaling") - ErrIntOverflowGenerated = fmt.Errorf("proto: integer overflow") -) - -var fileDescriptorGenerated = []byte{ - // 280 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x6c, 0x90, 0x41, 0x4b, 0xc3, 0x30, - 0x18, 0x86, 0x1b, 0x99, 0x83, 0x55, 0xf1, 0xd0, 0xd3, 0xe8, 0x21, 0x2b, 0x82, 0x30, 0x18, 0x4b, - 0x50, 0x10, 0x3c, 0x17, 0x76, 0x16, 0xaa, 0x27, 0x6f, 0x6d, 0xf7, 0x99, 0xc5, 0xba, 0xa4, 0xa4, - 0x5f, 0x37, 0x77, 0x11, 0x7f, 0x82, 0x3f, 0xab, 0xc7, 0x1d, 0x3d, 0x0d, 0x5b, 0xff, 0x88, 0x98, - 0x95, 0x09, 0xa3, 0xb7, 0xbc, 0x24, 0xcf, 0xc3, 0xfb, 0xc6, 0xbd, 0xcd, 0xee, 0x0a, 0x26, 0x35, - 0xcf, 0xca, 0x04, 0x8c, 0x02, 0x84, 0x82, 0xe7, 0x99, 0xe0, 0xeb, 0x18, 0xd3, 0x05, 0x5f, 0x81, - 0x29, 0xa4, 0x56, 0x30, 0xe7, 0x02, 0x14, 0x98, 0x18, 0x61, 0xce, 0x72, 0xa3, 0x51, 0x7b, 0x57, - 0x7b, 0x8c, 0xfd, 0x63, 0x2c, 0xcf, 0x04, 0xb3, 0x18, 0x3b, 0x60, 0xfe, 0x54, 0x48, 0x5c, 0x94, - 0x09, 0x4b, 0xf5, 0x92, 0x0b, 0x2d, 0x34, 0xb7, 0x74, 0x52, 0x3e, 0xdb, 0x64, 0x83, 0x3d, 0xed, - 0xad, 0xfe, 0xb4, 0xbb, 0x8c, 0x29, 0x15, 0xca, 0x25, 0x1c, 0x97, 0xf0, 0xaf, 0xbb, 0x9f, 0x97, - 0x28, 0x5f, 0xb9, 0x54, 0x58, 0xa0, 0x39, 0x46, 0x2e, 0xdf, 0xdd, 0xd3, 0xd9, 0x0a, 0x14, 0x7a, - 0x81, 0xdb, 0xc3, 0x4d, 0x0e, 0x43, 0x12, 0x90, 0xf1, 0x20, 0x3c, 0xaf, 0x76, 0x23, 0xa7, 0xd9, - 0x8d, 0x7a, 0x8f, 0x9b, 0x1c, 0x22, 0x7b, 0xe3, 0x3d, 0xb8, 0x7d, 0x9d, 0xbc, 0x40, 0x8a, 0xc3, - 0x93, 0x80, 0x8c, 0xcf, 0x6e, 0x26, 0xac, 0x7b, 0x73, 0xdb, 0x8e, 0x45, 0xf1, 0x7a, 0xf6, 0x86, - 0xa0, 0xfe, 0xa6, 0x87, 0x17, 0xad, 0xb0, 0x7f, 0x6f, 0x15, 0x51, 0xab, 0x0a, 0x27, 0x55, 0x4d, - 0x9d, 0x6d, 0x4d, 0x9d, 0xaf, 0x9a, 0x3a, 0x1f, 0x0d, 0x25, 0x55, 0x43, 0xc9, 0xb6, 0xa1, 0xe4, - 0xbb, 0xa1, 0xe4, 0xf3, 0x87, 0x3a, 0x4f, 0x83, 0xc3, 0xef, 0xfd, 0x06, 0x00, 0x00, 0xff, 0xff, - 0x23, 0x3d, 0x7b, 0x7e, 0x9c, 0x01, 0x00, 0x00, -} diff --git a/vendor/k8s.io/client-go/pkg/watch/versioned/generated.proto b/vendor/k8s.io/client-go/pkg/watch/versioned/generated.proto deleted file mode 100644 index 340e18dad8..0000000000 --- a/vendor/k8s.io/client-go/pkg/watch/versioned/generated.proto +++ /dev/null @@ -1,44 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - - -// This file was autogenerated by go-to-protobuf. Do not edit it manually! - -syntax = 'proto2'; - -package k8s.io.kubernetes.pkg.watch.versioned; - -import "k8s.io/kubernetes/pkg/runtime/generated.proto"; -import "k8s.io/kubernetes/pkg/util/intstr/generated.proto"; - -// Package-wide variables from generator "generated". -option go_package = "versioned"; - -// Event represents a single event to a watched resource. -// -// +protobuf=true -// +k8s:openapi-gen=true -message Event { - optional string type = 1; - - // Object is: - // * If Type is Added or Modified: the new state of the object. - // * If Type is Deleted: the state of the object immediately before deletion. - // * If Type is Error: *api.Status is recommended; other types may make sense - // depending on context. - optional k8s.io.kubernetes.pkg.runtime.RawExtension object = 2; -} - diff --git a/vendor/k8s.io/client-go/pkg/watch/versioned/types.go b/vendor/k8s.io/client-go/pkg/watch/versioned/types.go deleted file mode 100644 index 16b8b02ecf..0000000000 --- a/vendor/k8s.io/client-go/pkg/watch/versioned/types.go +++ /dev/null @@ -1,38 +0,0 @@ -/* -Copyright 2015 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -// Package versioned contains the versioned types for watch. This is the first -// serialization version unless otherwise noted. -package versioned - -import ( - "k8s.io/client-go/pkg/runtime" -) - -// Event represents a single event to a watched resource. -// -// +protobuf=true -// +k8s:openapi-gen=true -type Event struct { - Type string `json:"type" protobuf:"bytes,1,opt,name=type"` - - // Object is: - // * If Type is Added or Modified: the new state of the object. - // * If Type is Deleted: the state of the object immediately before deletion. - // * If Type is Error: *api.Status is recommended; other types may make sense - // depending on context. - Object runtime.RawExtension `json:"object" protobuf:"bytes,2,opt,name=object"` -} diff --git a/vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/OWNERS b/vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/OWNERS deleted file mode 100644 index d75421c5ef..0000000000 --- a/vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/OWNERS +++ /dev/null @@ -1,3 +0,0 @@ -assignees: - - cjcullen - - jlowdermilk diff --git a/vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/gcp.go b/vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/gcp.go deleted file mode 100644 index bf5b253de5..0000000000 --- a/vendor/k8s.io/client-go/plugin/pkg/client/auth/gcp/gcp.go +++ /dev/null @@ -1,211 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package gcp - -import ( - "bytes" - "encoding/json" - "fmt" - "net/http" - "os/exec" - "strings" - "time" - - "github.com/golang/glog" - "golang.org/x/net/context" - "golang.org/x/oauth2" - "golang.org/x/oauth2/google" - "k8s.io/client-go/pkg/util/jsonpath" - "k8s.io/client-go/pkg/util/yaml" - "k8s.io/client-go/rest" -) - -func init() { - if err := rest.RegisterAuthProviderPlugin("gcp", newGCPAuthProvider); err != nil { - glog.Fatalf("Failed to register gcp auth plugin: %v", err) - } -} - -type gcpAuthProvider struct { - tokenSource oauth2.TokenSource - persister rest.AuthProviderConfigPersister -} - -func newGCPAuthProvider(_ string, gcpConfig map[string]string, persister rest.AuthProviderConfigPersister) (rest.AuthProvider, error) { - cmd, useCmd := gcpConfig["cmd-path"] - var ts oauth2.TokenSource - var err error - if useCmd { - ts, err = newCmdTokenSource(cmd, gcpConfig["token-key"], gcpConfig["expiry-key"], gcpConfig["time-fmt"]) - } else { - ts, err = google.DefaultTokenSource(context.Background(), "https://www.googleapis.com/auth/cloud-platform") - } - if err != nil { - return nil, err - } - cts, err := newCachedTokenSource(gcpConfig["access-token"], gcpConfig["expiry"], persister, ts, gcpConfig) - if err != nil { - return nil, err - } - return &gcpAuthProvider{cts, persister}, nil -} - -func (g *gcpAuthProvider) WrapTransport(rt http.RoundTripper) http.RoundTripper { - return &oauth2.Transport{ - Source: g.tokenSource, - Base: rt, - } -} - -func (g *gcpAuthProvider) Login() error { return nil } - -type cachedTokenSource struct { - source oauth2.TokenSource - accessToken string - expiry time.Time - persister rest.AuthProviderConfigPersister - cache map[string]string -} - -func newCachedTokenSource(accessToken, expiry string, persister rest.AuthProviderConfigPersister, ts oauth2.TokenSource, cache map[string]string) (*cachedTokenSource, error) { - var expiryTime time.Time - if parsedTime, err := time.Parse(time.RFC3339Nano, expiry); err == nil { - expiryTime = parsedTime - } - if cache == nil { - cache = make(map[string]string) - } - return &cachedTokenSource{ - source: ts, - accessToken: accessToken, - expiry: expiryTime, - persister: persister, - cache: cache, - }, nil -} - -func (t *cachedTokenSource) Token() (*oauth2.Token, error) { - tok := &oauth2.Token{ - AccessToken: t.accessToken, - TokenType: "Bearer", - Expiry: t.expiry, - } - if tok.Valid() && !tok.Expiry.IsZero() { - return tok, nil - } - tok, err := t.source.Token() - if err != nil { - return nil, err - } - if t.persister != nil { - t.cache["access-token"] = tok.AccessToken - t.cache["expiry"] = tok.Expiry.Format(time.RFC3339Nano) - if err := t.persister.Persist(t.cache); err != nil { - glog.V(4).Infof("Failed to persist token: %v", err) - } - } - return tok, nil -} - -type commandTokenSource struct { - cmd string - args []string - tokenKey string - expiryKey string - timeFmt string -} - -func newCmdTokenSource(cmd, tokenKey, expiryKey, timeFmt string) (*commandTokenSource, error) { - if len(timeFmt) == 0 { - timeFmt = time.RFC3339Nano - } - if len(tokenKey) == 0 { - tokenKey = "{.access_token}" - } - if len(expiryKey) == 0 { - expiryKey = "{.token_expiry}" - } - fields := strings.Fields(cmd) - if len(fields) == 0 { - return nil, fmt.Errorf("missing access token cmd") - } - return &commandTokenSource{ - cmd: fields[0], - args: fields[1:], - tokenKey: tokenKey, - expiryKey: expiryKey, - timeFmt: timeFmt, - }, nil -} - -func (c *commandTokenSource) Token() (*oauth2.Token, error) { - fullCmd := fmt.Sprintf("%s %s", c.cmd, strings.Join(c.args, " ")) - cmd := exec.Command(c.cmd, c.args...) - output, err := cmd.Output() - if err != nil { - return nil, fmt.Errorf("error executing access token command %q: %v", fullCmd, err) - } - token, err := c.parseTokenCmdOutput(output) - if err != nil { - return nil, fmt.Errorf("error parsing output for access token command %q: %v", fullCmd, err) - } - return token, nil -} - -func (c *commandTokenSource) parseTokenCmdOutput(output []byte) (*oauth2.Token, error) { - output, err := yaml.ToJSON(output) - if err != nil { - return nil, err - } - var data interface{} - if err := json.Unmarshal(output, &data); err != nil { - return nil, err - } - - accessToken, err := parseJSONPath(data, "token-key", c.tokenKey) - if err != nil { - return nil, fmt.Errorf("error parsing token-key %q: %v", c.tokenKey, err) - } - expiryStr, err := parseJSONPath(data, "expiry-key", c.expiryKey) - if err != nil { - return nil, fmt.Errorf("error parsing expiry-key %q: %v", c.expiryKey, err) - } - var expiry time.Time - if t, err := time.Parse(c.timeFmt, expiryStr); err != nil { - glog.V(4).Infof("Failed to parse token expiry from %s (fmt=%s): %v", expiryStr, c.timeFmt, err) - } else { - expiry = t - } - - return &oauth2.Token{ - AccessToken: accessToken, - TokenType: "Bearer", - Expiry: expiry, - }, nil -} - -func parseJSONPath(input interface{}, name, template string) (string, error) { - j := jsonpath.New(name) - buf := new(bytes.Buffer) - if err := j.Parse(template); err != nil { - return "", err - } - if err := j.Execute(buf, input); err != nil { - return "", err - } - return buf.String(), nil -} diff --git a/vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/OWNERS b/vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/OWNERS deleted file mode 100644 index 2f80bc7e10..0000000000 --- a/vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/OWNERS +++ /dev/null @@ -1,2 +0,0 @@ -assignees: - - ericchiang diff --git a/vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/oidc.go b/vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/oidc.go deleted file mode 100644 index f5da43906d..0000000000 --- a/vendor/k8s.io/client-go/plugin/pkg/client/auth/oidc/oidc.go +++ /dev/null @@ -1,270 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package oidc - -import ( - "encoding/base64" - "errors" - "fmt" - "net/http" - "strings" - "time" - - "github.com/coreos/go-oidc/jose" - "github.com/coreos/go-oidc/oauth2" - "github.com/coreos/go-oidc/oidc" - "github.com/golang/glog" - - "k8s.io/client-go/pkg/util/wait" - "k8s.io/client-go/rest" -) - -const ( - cfgIssuerUrl = "idp-issuer-url" - cfgClientID = "client-id" - cfgClientSecret = "client-secret" - cfgCertificateAuthority = "idp-certificate-authority" - cfgCertificateAuthorityData = "idp-certificate-authority-data" - cfgExtraScopes = "extra-scopes" - cfgIDToken = "id-token" - cfgRefreshToken = "refresh-token" -) - -var ( - backoff = wait.Backoff{ - Duration: 1 * time.Second, - Factor: 2, - Jitter: .1, - Steps: 5, - } -) - -func init() { - if err := rest.RegisterAuthProviderPlugin("oidc", newOIDCAuthProvider); err != nil { - glog.Fatalf("Failed to register oidc auth plugin: %v", err) - } -} - -func newOIDCAuthProvider(_ string, cfg map[string]string, persister rest.AuthProviderConfigPersister) (rest.AuthProvider, error) { - issuer := cfg[cfgIssuerUrl] - if issuer == "" { - return nil, fmt.Errorf("Must provide %s", cfgIssuerUrl) - } - - clientID := cfg[cfgClientID] - if clientID == "" { - return nil, fmt.Errorf("Must provide %s", cfgClientID) - } - - clientSecret := cfg[cfgClientSecret] - if clientSecret == "" { - return nil, fmt.Errorf("Must provide %s", cfgClientSecret) - } - - var certAuthData []byte - var err error - if cfg[cfgCertificateAuthorityData] != "" { - certAuthData, err = base64.StdEncoding.DecodeString(cfg[cfgCertificateAuthorityData]) - if err != nil { - return nil, err - } - } - - clientConfig := rest.Config{ - TLSClientConfig: rest.TLSClientConfig{ - CAFile: cfg[cfgCertificateAuthority], - CAData: certAuthData, - }, - } - - trans, err := rest.TransportFor(&clientConfig) - if err != nil { - return nil, err - } - hc := &http.Client{Transport: trans} - - providerCfg, err := oidc.FetchProviderConfig(hc, issuer) - if err != nil { - return nil, fmt.Errorf("error fetching provider config: %v", err) - } - - scopes := strings.Split(cfg[cfgExtraScopes], ",") - oidcCfg := oidc.ClientConfig{ - HTTPClient: hc, - Credentials: oidc.ClientCredentials{ - ID: clientID, - Secret: clientSecret, - }, - ProviderConfig: providerCfg, - Scope: append(scopes, oidc.DefaultScope...), - } - - client, err := oidc.NewClient(oidcCfg) - if err != nil { - return nil, fmt.Errorf("error creating OIDC Client: %v", err) - } - - oClient := &oidcClient{client} - - var initialIDToken jose.JWT - if cfg[cfgIDToken] != "" { - initialIDToken, err = jose.ParseJWT(cfg[cfgIDToken]) - if err != nil { - return nil, err - } - } - - return &oidcAuthProvider{ - initialIDToken: initialIDToken, - refresher: &idTokenRefresher{ - client: oClient, - cfg: cfg, - persister: persister, - }, - }, nil -} - -type oidcAuthProvider struct { - refresher *idTokenRefresher - initialIDToken jose.JWT -} - -func (g *oidcAuthProvider) WrapTransport(rt http.RoundTripper) http.RoundTripper { - at := &oidc.AuthenticatedTransport{ - TokenRefresher: g.refresher, - RoundTripper: rt, - } - at.SetJWT(g.initialIDToken) - return &roundTripper{ - wrapped: at, - refresher: g.refresher, - } -} - -func (g *oidcAuthProvider) Login() error { - return errors.New("not yet implemented") -} - -type OIDCClient interface { - refreshToken(rt string) (oauth2.TokenResponse, error) - verifyJWT(jwt jose.JWT) error -} - -type roundTripper struct { - refresher *idTokenRefresher - wrapped *oidc.AuthenticatedTransport -} - -func (r *roundTripper) RoundTrip(req *http.Request) (*http.Response, error) { - var res *http.Response - var err error - firstTime := true - wait.ExponentialBackoff(backoff, func() (bool, error) { - if !firstTime { - var jwt jose.JWT - jwt, err = r.refresher.Refresh() - if err != nil { - return true, nil - } - r.wrapped.SetJWT(jwt) - } else { - firstTime = false - } - - res, err = r.wrapped.RoundTrip(req) - if err != nil { - return true, nil - } - if res.StatusCode == http.StatusUnauthorized { - return false, nil - } - return true, nil - }) - return res, err -} - -type idTokenRefresher struct { - cfg map[string]string - client OIDCClient - persister rest.AuthProviderConfigPersister - intialIDToken jose.JWT -} - -func (r *idTokenRefresher) Verify(jwt jose.JWT) error { - claims, err := jwt.Claims() - if err != nil { - return err - } - - now := time.Now() - exp, ok, err := claims.TimeClaim("exp") - switch { - case err != nil: - return fmt.Errorf("failed to parse 'exp' claim: %v", err) - case !ok: - return errors.New("missing required 'exp' claim") - case exp.Before(now): - return fmt.Errorf("token already expired at: %v", exp) - } - - return nil -} - -func (r *idTokenRefresher) Refresh() (jose.JWT, error) { - rt, ok := r.cfg[cfgRefreshToken] - if !ok { - return jose.JWT{}, errors.New("No valid id-token, and cannot refresh without refresh-token") - } - - tokens, err := r.client.refreshToken(rt) - if err != nil { - return jose.JWT{}, fmt.Errorf("could not refresh token: %v", err) - } - jwt, err := jose.ParseJWT(tokens.IDToken) - if err != nil { - return jose.JWT{}, err - } - - if tokens.RefreshToken != "" && tokens.RefreshToken != rt { - r.cfg[cfgRefreshToken] = tokens.RefreshToken - } - r.cfg[cfgIDToken] = jwt.Encode() - - err = r.persister.Persist(r.cfg) - if err != nil { - return jose.JWT{}, fmt.Errorf("could not perist new tokens: %v", err) - } - - return jwt, r.client.verifyJWT(jwt) -} - -type oidcClient struct { - client *oidc.Client -} - -func (o *oidcClient) refreshToken(rt string) (oauth2.TokenResponse, error) { - oac, err := o.client.OAuthClient() - if err != nil { - return oauth2.TokenResponse{}, err - } - - return oac.RequestToken(oauth2.GrantTypeRefreshToken, rt) -} - -func (o *oidcClient) verifyJWT(jwt jose.JWT) error { - return o.client.VerifyJWT(jwt) -} diff --git a/vendor/k8s.io/client-go/rest/BUILD b/vendor/k8s.io/client-go/rest/BUILD new file mode 100644 index 0000000000..1719e5c897 --- /dev/null +++ b/vendor/k8s.io/client-go/rest/BUILD @@ -0,0 +1,85 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "client_test.go", + "config_test.go", + "plugin_test.go", + "request_test.go", + "url_utils_test.go", + "urlbackoff_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/github.com/stretchr/testify/assert:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/equality:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/httpstream:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/intstr:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/apis/extensions/v1beta1:go_default_library", + "//vendor/k8s.io/client-go/rest/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api:go_default_library", + "//vendor/k8s.io/client-go/util/flowcontrol:go_default_library", + "//vendor/k8s.io/client-go/util/testing:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "client.go", + "config.go", + "plugin.go", + "request.go", + "transport.go", + "url_utils.go", + "urlbackoff.go", + "versions.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/types:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/pkg/version:go_default_library", + "//vendor/k8s.io/client-go/rest/watch:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api:go_default_library", + "//vendor/k8s.io/client-go/tools/metrics:go_default_library", + "//vendor/k8s.io/client-go/transport:go_default_library", + "//vendor/k8s.io/client-go/util/cert:go_default_library", + "//vendor/k8s.io/client-go/util/flowcontrol:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/rest/OWNERS b/vendor/k8s.io/client-go/rest/OWNERS new file mode 100755 index 0000000000..8d97da007d --- /dev/null +++ b/vendor/k8s.io/client-go/rest/OWNERS @@ -0,0 +1,24 @@ +reviewers: +- thockin +- smarterclayton +- caesarxuchao +- wojtek-t +- deads2k +- brendandburns +- liggitt +- nikhiljindal +- gmarek +- erictune +- sttts +- luxas +- dims +- errordeveloper +- hongchaodeng +- krousey +- resouer +- cjcullen +- rmmh +- lixiaobing10051267 +- asalkeld +- juanvallejo +- lojies diff --git a/vendor/k8s.io/client-go/rest/client.go b/vendor/k8s.io/client-go/rest/client.go index 79559edb49..524e0d8eb9 100644 --- a/vendor/k8s.io/client-go/rest/client.go +++ b/vendor/k8s.io/client-go/rest/client.go @@ -26,10 +26,10 @@ import ( "strings" "time" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/flowcontrol" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/types" + "k8s.io/client-go/util/flowcontrol" ) const ( @@ -45,10 +45,10 @@ type Interface interface { Verb(verb string) *Request Post() *Request Put() *Request - Patch(pt api.PatchType) *Request + Patch(pt types.PatchType) *Request Get() *Request Delete() *Request - APIVersion() unversioned.GroupVersion + APIVersion() schema.GroupVersion } // RESTClient imposes common Kubernetes API conventions on a set of resource paths. @@ -100,7 +100,7 @@ func NewRESTClient(baseURL *url.URL, versionedAPIPath string, config ContentConf base.Fragment = "" if config.GroupVersion == nil { - config.GroupVersion = &unversioned.GroupVersion{} + config.GroupVersion = &schema.GroupVersion{} } if len(config.ContentType) == 0 { config.ContentType = "application/json" @@ -173,7 +173,7 @@ func createSerializers(config ContentConfig) (*Serializers, error) { info = mediaTypes[0] } - internalGV := unversioned.GroupVersions{ + internalGV := schema.GroupVersions{ { Group: config.GroupVersion.Group, Version: runtime.APIVersionInternal, @@ -238,7 +238,7 @@ func (c *RESTClient) Put() *Request { } // Patch begins a PATCH request. Short for c.Verb("Patch"). -func (c *RESTClient) Patch(pt api.PatchType) *Request { +func (c *RESTClient) Patch(pt types.PatchType) *Request { return c.Verb("PATCH").SetHeader("Content-Type", string(pt)) } @@ -253,6 +253,6 @@ func (c *RESTClient) Delete() *Request { } // APIVersion returns the APIVersion this RESTClient is expected to use. -func (c *RESTClient) APIVersion() unversioned.GroupVersion { +func (c *RESTClient) APIVersion() schema.GroupVersion { return *c.contentConfig.GroupVersion } diff --git a/vendor/k8s.io/client-go/rest/config.go b/vendor/k8s.io/client-go/rest/config.go index 37d8756494..b451148659 100644 --- a/vendor/k8s.io/client-go/rest/config.go +++ b/vendor/k8s.io/client-go/rest/config.go @@ -22,20 +22,21 @@ import ( "net" "net/http" "os" - "path" + "path/filepath" gruntime "runtime" "strings" "time" "github.com/golang/glog" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - certutil "k8s.io/client-go/pkg/util/cert" - "k8s.io/client-go/pkg/util/flowcontrol" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/client-go/pkg/api/v1" "k8s.io/client-go/pkg/version" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" + certutil "k8s.io/client-go/util/cert" + "k8s.io/client-go/util/flowcontrol" ) const ( @@ -70,8 +71,8 @@ type Config struct { // TODO: demonstrate an OAuth2 compatible client. BearerToken string - // Impersonate is the username that this RESTClient will impersonate - Impersonate string + // Impersonate is the configuration that RESTClient will use for impersonation. + Impersonate ImpersonationConfig // Server requires plugin-specified authentication. AuthProvider *clientcmdapi.AuthProviderConfig @@ -82,10 +83,6 @@ type Config struct { // TLSClientConfig contains settings to enable transport layer security TLSClientConfig - // Server should be accessed without verifying the TLS - // certificate. For testing only. - Insecure bool - // UserAgent is an optional field that specifies the caller of this request. UserAgent string @@ -118,8 +115,26 @@ type Config struct { // Version string } +// ImpersonationConfig has all the available impersonation options +type ImpersonationConfig struct { + // UserName is the username to impersonate on each request. + UserName string + // Groups are the groups to impersonate on each request. + Groups []string + // Extra is a free-form field which can be used to link some authentication information + // to authorization information. This field allows you to impersonate it. + Extra map[string][]string +} + // TLSClientConfig contains settings to enable transport layer security type TLSClientConfig struct { + // Server should be accessed without verifying the TLS certificate. For testing only. + Insecure bool + // ServerName is passed to the server for SNI and is used in the client to check server + // ceritificates against. If ServerName is empty, the hostname used to contact the + // server is used. + ServerName string + // Server requires TLS client certificate authentication CertFile string // Server requires TLS client certificate authentication @@ -150,7 +165,7 @@ type ContentConfig struct { // GroupVersion is the API version to talk to. Must be provided when initializing // a RESTClient directly. When initializing a Client, will be set with the default // code version. - GroupVersion *unversioned.GroupVersion + GroupVersion *schema.GroupVersion // NegotiatedSerializer is used for obtaining encoders and decoders for multiple // supported media types. NegotiatedSerializer runtime.NegotiatedSerializer @@ -224,7 +239,7 @@ func UnversionedRESTClientFor(config *Config) (*RESTClient, error) { versionConfig := config.ContentConfig if versionConfig.GroupVersion == nil { - v := unversioned.SchemeGroupVersion + v := metav1.SchemeGroupVersion versionConfig.GroupVersion = &v } @@ -240,19 +255,51 @@ func SetKubernetesDefaults(config *Config) error { return nil } -// DefaultKubernetesUserAgent returns the default user agent that clients can use. -func DefaultKubernetesUserAgent() string { - commit := version.Get().GitCommit - if len(commit) > 7 { - commit = commit[:7] +// adjustCommit returns sufficient significant figures of the commit's git hash. +func adjustCommit(c string) string { + if len(c) == 0 { + return "unknown" + } + if len(c) > 7 { + return c[:7] + } + return c +} + +// adjustVersion strips "alpha", "beta", etc. from version in form +// major.minor.patch-[alpha|beta|etc]. +func adjustVersion(v string) string { + if len(v) == 0 { + return "unknown" } - if len(commit) == 0 { - commit = "unknown" + seg := strings.SplitN(v, "-", 2) + return seg[0] +} + +// adjustCommand returns the last component of the +// OS-specific command path for use in User-Agent. +func adjustCommand(p string) string { + // Unlikely, but better than returning "". + if len(p) == 0 { + return "unknown" } - version := version.Get().GitVersion - seg := strings.SplitN(version, "-", 2) - version = seg[0] - return fmt.Sprintf("%s/%s (%s/%s) kubernetes/%s", path.Base(os.Args[0]), version, gruntime.GOOS, gruntime.GOARCH, commit) + return filepath.Base(p) +} + +// buildUserAgent builds a User-Agent string from given args. +func buildUserAgent(command, version, os, arch, commit string) string { + return fmt.Sprintf( + "%s/%s (%s/%s) kubernetes/%s", command, version, os, arch, commit) +} + +// DefaultKubernetesUserAgent returns a User-Agent string built from static global vars. +func DefaultKubernetesUserAgent() string { + return buildUserAgent( + adjustCommand(os.Args[0]), + adjustVersion(version.Get().GitVersion), + gruntime.GOOS, + gruntime.GOARCH, + adjustCommit(version.Get().GitCommit)) } // InClusterConfig returns a config object which uses the service account @@ -265,12 +312,12 @@ func InClusterConfig() (*Config, error) { return nil, fmt.Errorf("unable to load in-cluster configuration, KUBERNETES_SERVICE_HOST and KUBERNETES_SERVICE_PORT must be defined") } - token, err := ioutil.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/" + api.ServiceAccountTokenKey) + token, err := ioutil.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/" + v1.ServiceAccountTokenKey) if err != nil { return nil, err } tlsClientConfig := TLSClientConfig{} - rootCAFile := "/var/run/secrets/kubernetes.io/serviceaccount/" + api.ServiceAccountRootCAKey + rootCAFile := "/var/run/secrets/kubernetes.io/serviceaccount/" + v1.ServiceAccountRootCAKey if _, err := certutil.NewPool(rootCAFile); err != nil { glog.Errorf("Expected to load root CA config from %s, but got err: %v", rootCAFile, err) } else { @@ -353,11 +400,12 @@ func AnonymousClientConfig(config *Config) *Config { Prefix: config.Prefix, ContentConfig: config.ContentConfig, TLSClientConfig: TLSClientConfig{ - CAFile: config.TLSClientConfig.CAFile, - CAData: config.TLSClientConfig.CAData, + Insecure: config.Insecure, + ServerName: config.ServerName, + CAFile: config.TLSClientConfig.CAFile, + CAData: config.TLSClientConfig.CAData, }, RateLimiter: config.RateLimiter, - Insecure: config.Insecure, UserAgent: config.UserAgent, Transport: config.Transport, WrapTransport: config.WrapTransport, diff --git a/vendor/k8s.io/client-go/rest/request.go b/vendor/k8s.io/client-go/rest/request.go index f5926e3b9f..cfb4511bab 100644 --- a/vendor/k8s.io/client-go/rest/request.go +++ b/vendor/k8s.io/client-go/rest/request.go @@ -18,6 +18,7 @@ package rest import ( "bytes" + "context" "encoding/hex" "fmt" "io" @@ -32,20 +33,20 @@ import ( "time" "github.com/golang/glog" - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/api/errors" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer/streaming" + "k8s.io/apimachinery/pkg/util/net" + "k8s.io/apimachinery/pkg/util/sets" + "k8s.io/apimachinery/pkg/watch" "k8s.io/client-go/pkg/api/v1" - pathvalidation "k8s.io/client-go/pkg/api/validation/path" - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/streaming" - "k8s.io/client-go/pkg/util/flowcontrol" - "k8s.io/client-go/pkg/util/net" - "k8s.io/client-go/pkg/util/sets" - "k8s.io/client-go/pkg/watch" - "k8s.io/client-go/pkg/watch/versioned" + restclientwatch "k8s.io/client-go/rest/watch" "k8s.io/client-go/tools/metrics" + "k8s.io/client-go/util/flowcontrol" ) var ( @@ -104,16 +105,14 @@ type Request struct { resource string resourceName string subresource string - selector labels.Selector timeout time.Duration // output err error body io.Reader - // The constructed request and the response - req *http.Request - resp *http.Response + // This is only used for per-request timeouts, deadlines, and cancellations. + ctx context.Context backoffMgr BackoffManager throttle flowcontrol.RateLimiter @@ -179,7 +178,7 @@ func (r *Request) Resource(resource string) *Request { r.err = fmt.Errorf("resource already set to %q, cannot change to %q", r.resource, resource) return r } - if msgs := pathvalidation.IsValidPathSegmentName(resource); len(msgs) != 0 { + if msgs := IsValidPathSegmentName(resource); len(msgs) != 0 { r.err = fmt.Errorf("invalid resource %q: %v", resource, msgs) return r } @@ -199,7 +198,7 @@ func (r *Request) SubResource(subresources ...string) *Request { return r } for _, s := range subresources { - if msgs := pathvalidation.IsValidPathSegmentName(s); len(msgs) != 0 { + if msgs := IsValidPathSegmentName(s); len(msgs) != 0 { r.err = fmt.Errorf("invalid subresource %q: %v", s, msgs) return r } @@ -221,7 +220,7 @@ func (r *Request) Name(resourceName string) *Request { r.err = fmt.Errorf("resource name already set to %q, cannot change to %q", r.resourceName, resourceName) return r } - if msgs := pathvalidation.IsValidPathSegmentName(resourceName); len(msgs) != 0 { + if msgs := IsValidPathSegmentName(resourceName); len(msgs) != 0 { r.err = fmt.Errorf("invalid resource name %q: %v", resourceName, msgs) return r } @@ -238,7 +237,7 @@ func (r *Request) Namespace(namespace string) *Request { r.err = fmt.Errorf("namespace already set to %q, cannot change to %q", r.namespace, namespace) return r } - if msgs := pathvalidation.IsValidPathSegmentName(namespace); len(msgs) != 0 { + if msgs := IsValidPathSegmentName(namespace); len(msgs) != 0 { r.err = fmt.Errorf("invalid namespace %q: %v", namespace, msgs) return r } @@ -333,10 +332,10 @@ func (r resourceTypeToFieldMapping) filterField(resourceType, field, value strin return fMapping.filterField(field, value) } -type versionToResourceToFieldMapping map[unversioned.GroupVersion]resourceTypeToFieldMapping +type versionToResourceToFieldMapping map[schema.GroupVersion]resourceTypeToFieldMapping // filterField transforms the given field/value selector for the given groupVersion and resource -func (v versionToResourceToFieldMapping) filterField(groupVersion *unversioned.GroupVersion, resourceType, field, value string) (newField, newValue string, err error) { +func (v versionToResourceToFieldMapping) filterField(groupVersion *schema.GroupVersion, resourceType, field, value string) (newField, newValue string, err error) { rMapping, ok := v[*groupVersion] if !ok { // no groupVersion overrides registered, default to identity mapping @@ -404,7 +403,7 @@ func (r *Request) FieldsSelectorParam(s fields.Selector) *Request { r.err = err return r } - return r.setParam(unversioned.FieldSelectorQueryParam(r.content.GroupVersion.String()), s2.String()) + return r.setParam(metav1.FieldSelectorQueryParam(r.content.GroupVersion.String()), s2.String()) } // LabelsSelectorParam adds the given selector as a query parameter @@ -418,7 +417,7 @@ func (r *Request) LabelsSelectorParam(s labels.Selector) *Request { if s.Empty() { return r } - return r.setParam(unversioned.LabelSelectorQueryParam(r.content.GroupVersion.String()), s.String()) + return r.setParam(metav1.LabelSelectorQueryParam(r.content.GroupVersion.String()), s.String()) } // UintParam creates a query parameter with the given value. @@ -453,14 +452,14 @@ func (r *Request) VersionedParams(obj runtime.Object, codec runtime.ParameterCod for _, value := range v { // TODO: Move it to setParam method, once we get rid of // FieldSelectorParam & LabelSelectorParam methods. - if k == unversioned.LabelSelectorQueryParam(r.content.GroupVersion.String()) && value == "" { + if k == metav1.LabelSelectorQueryParam(r.content.GroupVersion.String()) && value == "" { // Don't set an empty selector for backward compatibility. // Since there is no way to get the difference between empty // and unspecified string, we don't set it to avoid having // labelSelector= param in every request. continue } - if k == unversioned.FieldSelectorQueryParam(r.content.GroupVersion.String()) { + if k == metav1.FieldSelectorQueryParam(r.content.GroupVersion.String()) { if len(value) == 0 { // Don't set an empty selector for backward compatibility. // Since there is no way to get the difference between empty @@ -539,10 +538,10 @@ func (r *Request) Body(obj interface{}) *Request { r.err = err return r } - glog.V(8).Infof("Request Body: %#v", string(data)) + glogBody("Request Body", data) r.body = bytes.NewReader(data) case []byte: - glog.V(8).Infof("Request Body: %#v", string(t)) + glogBody("Request Body", t) r.body = bytes.NewReader(t) case io.Reader: r.body = t @@ -556,7 +555,7 @@ func (r *Request) Body(obj interface{}) *Request { r.err = err return r } - glog.V(8).Infof("Request Body: %#v", string(data)) + glogBody("Request Body", data) r.body = bytes.NewReader(data) r.SetHeader("Content-Type", r.content.ContentType) default: @@ -565,6 +564,13 @@ func (r *Request) Body(obj interface{}) *Request { return r } +// Context adds a context to the request. Contexts are only used for +// timeouts, deadlines, and cancellations. +func (r *Request) Context(ctx context.Context) *Request { + r.ctx = ctx + return r +} + // URL returns the current working URL. func (r *Request) URL() *url.URL { p := r.pathPrefix @@ -650,6 +656,9 @@ func (r *Request) Watch() (watch.Interface, error) { if err != nil { return nil, err } + if r.ctx != nil { + req = req.WithContext(r.ctx) + } req.Header = r.headers client := r.client if client == nil { @@ -682,7 +691,7 @@ func (r *Request) Watch() (watch.Interface, error) { } framer := r.serializers.Framer.NewFrameReader(resp.Body) decoder := streaming.NewDecoder(framer, r.serializers.StreamingSerializer) - return watch.NewStreamWatcher(versioned.NewDecoder(decoder, r.serializers.Decoder)), nil + return watch.NewStreamWatcher(restclientwatch.NewDecoder(decoder, r.serializers.Decoder)), nil } // updateURLMetrics is a convenience function for pushing metrics. @@ -693,9 +702,10 @@ func updateURLMetrics(req *Request, resp *http.Response, err error) { url = req.baseURL.Host } - // If we have an error (i.e. apiserver down) we report that as a metric label. + // Errors can be arbitrary strings. Unbound label cardinality is not suitable for a metric + // system so we just report them as ``. if err != nil { - metrics.RequestResult.Increment(err.Error(), req.verb, url) + metrics.RequestResult.Increment("", req.verb, url) } else { //Metrics for failure codes metrics.RequestResult.Increment(strconv.Itoa(resp.StatusCode), req.verb, url) @@ -718,6 +728,9 @@ func (r *Request) Stream() (io.ReadCloser, error) { if err != nil { return nil, err } + if r.ctx != nil { + req = req.WithContext(r.ctx) + } req.Header = r.headers client := r.client if client == nil { @@ -746,10 +759,11 @@ func (r *Request) Stream() (io.ReadCloser, error) { defer resp.Body.Close() result := r.transformResponse(resp, req) - if result.err != nil { - return nil, result.err + err := result.Error() + if err == nil { + err = fmt.Errorf("%d while accessing %v: %s", result.statusCode, url, string(result.body)) } - return nil, fmt.Errorf("%d while accessing %v: %s", result.statusCode, url, string(result.body)) + return nil, err } } @@ -792,6 +806,9 @@ func (r *Request) request(fn func(*http.Request, *http.Response)) error { if err != nil { return err } + if r.ctx != nil { + req = req.WithContext(r.ctx) + } req.Header = r.headers r.backoffMgr.Sleep(r.backoffMgr.CalculateBackoff(r.URL())) @@ -809,7 +826,20 @@ func (r *Request) request(fn func(*http.Request, *http.Response)) error { r.backoffMgr.UpdateBackoff(r.URL(), err, resp.StatusCode) } if err != nil { - return err + // "Connection reset by peer" is usually a transient error. + // Thus in case of "GET" operations, we simply retry it. + // We are not automatically retrying "write" operations, as + // they are not idempotent. + if !net.IsConnectionReset(err) || r.verb != "GET" { + return err + } + // For the purpose of retry, we set the artificial "retry-after" response. + // TODO: Should we clean the original response if it exists? + resp = &http.Response{ + StatusCode: http.StatusInternalServerError, + Header: http.Header{"Retry-After": []string{"1"}}, + Body: ioutil.NopCloser(bytes.NewReader([]byte{})), + } } done := func() bool { @@ -876,6 +906,7 @@ func (r *Request) DoRaw() ([]byte, error) { var result Result err := r.request(func(req *http.Request, resp *http.Response) { result.body, result.err = ioutil.ReadAll(resp.Body) + glogBody("Response Body", result.body) if resp.StatusCode < http.StatusOK || resp.StatusCode > http.StatusPartialContent { result.err = r.transformUnstructuredResponseError(resp, req, result.body) } @@ -895,15 +926,7 @@ func (r *Request) transformResponse(resp *http.Response, req *http.Request) Resu } } - if glog.V(8) { - if bytes.IndexFunc(body, func(r rune) bool { - return r < 0x0a - }) != -1 { - glog.Infof("Response Body:\n%s", hex.Dump(body)) - } else { - glog.Infof("Response Body: %s", string(body)) - } - } + glogBody("Response Body", body) // verify the content type is accurate contentType := resp.Header.Get("Content-Type") @@ -955,6 +978,21 @@ func (r *Request) transformResponse(resp *http.Response, req *http.Request) Resu } } +// glogBody logs a body output that could be either JSON or protobuf. It explicitly guards against +// allocating a new string for the body output unless necessary. Uses a simple heuristic to determine +// whether the body is printable. +func glogBody(prefix string, body []byte) { + if glog.V(8) { + if bytes.IndexFunc(body, func(r rune) bool { + return r < 0x0a + }) != -1 { + glog.Infof("%s:\n%s", prefix, hex.Dump(body)) + } else { + glog.Infof("%s: %s", prefix, string(body)) + } + } +} + // maxUnstructuredResponseTextBytes is an upper bound on how much output to include in the unstructured error. const maxUnstructuredResponseTextBytes = 2048 @@ -992,19 +1030,20 @@ func (r *Request) newUnstructuredResponseError(body []byte, isTextResponse bool, if len(body) > maxUnstructuredResponseTextBytes { body = body[:maxUnstructuredResponseTextBytes] } - glog.V(8).Infof("Response Body: %#v", string(body)) message := "unknown" if isTextResponse { message = strings.TrimSpace(string(body)) } + var groupResource schema.GroupResource + if len(r.resource) > 0 { + groupResource.Group = r.content.GroupVersion.Group + groupResource.Resource = r.resource + } return errors.NewGenericServerResponse( statusCode, method, - unversioned.GroupResource{ - Group: r.content.GroupVersion.Group, - Resource: r.resource, - }, + groupResource, r.resourceName, message, retryAfter, @@ -1082,9 +1121,9 @@ func (r Result) Get() (runtime.Object, error) { return nil, err } switch t := out.(type) { - case *unversioned.Status: + case *metav1.Status: // any status besides StatusSuccess is considered an error. - if t.Status != unversioned.StatusSuccess { + if t.Status != metav1.StatusSuccess { return nil, errors.FromObject(t) } } @@ -1109,6 +1148,9 @@ func (r Result) Into(obj runtime.Object) error { if r.decoder == nil { return fmt.Errorf("serializer for %s doesn't exist", r.contentType) } + if len(r.body) == 0 { + return fmt.Errorf("0-length response") + } out, _, err := r.decoder.Decode(r.body, nil, obj) if err != nil || out == obj { @@ -1117,9 +1159,9 @@ func (r Result) Into(obj runtime.Object) error { // if a different object is returned, see if it is Status and avoid double decoding // the object. switch t := out.(type) { - case *unversioned.Status: + case *metav1.Status: // any status besides StatusSuccess is considered an error. - if t.Status != unversioned.StatusSuccess { + if t.Status != metav1.StatusSuccess { return errors.FromObject(t) } } @@ -1146,17 +1188,63 @@ func (r Result) Error() error { // attempt to convert the body into a Status object // to be backwards compatible with old servers that do not return a version, default to "v1" - out, _, err := r.decoder.Decode(r.body, &unversioned.GroupVersionKind{Version: "v1"}, nil) + out, _, err := r.decoder.Decode(r.body, &schema.GroupVersionKind{Version: "v1"}, nil) if err != nil { glog.V(5).Infof("body was not decodable (unable to check for Status): %v", err) return r.err } switch t := out.(type) { - case *unversioned.Status: + case *metav1.Status: // because we default the kind, we *must* check for StatusFailure - if t.Status == unversioned.StatusFailure { + if t.Status == metav1.StatusFailure { return errors.FromObject(t) } } return r.err } + +// NameMayNotBe specifies strings that cannot be used as names specified as path segments (like the REST API or etcd store) +var NameMayNotBe = []string{".", ".."} + +// NameMayNotContain specifies substrings that cannot be used in names specified as path segments (like the REST API or etcd store) +var NameMayNotContain = []string{"/", "%"} + +// IsValidPathSegmentName validates the name can be safely encoded as a path segment +func IsValidPathSegmentName(name string) []string { + for _, illegalName := range NameMayNotBe { + if name == illegalName { + return []string{fmt.Sprintf(`may not be '%s'`, illegalName)} + } + } + + var errors []string + for _, illegalContent := range NameMayNotContain { + if strings.Contains(name, illegalContent) { + errors = append(errors, fmt.Sprintf(`may not contain '%s'`, illegalContent)) + } + } + + return errors +} + +// IsValidPathSegmentPrefix validates the name can be used as a prefix for a name which will be encoded as a path segment +// It does not check for exact matches with disallowed names, since an arbitrary suffix might make the name valid +func IsValidPathSegmentPrefix(name string) []string { + var errors []string + for _, illegalContent := range NameMayNotContain { + if strings.Contains(name, illegalContent) { + errors = append(errors, fmt.Sprintf(`may not contain '%s'`, illegalContent)) + } + } + + return errors +} + +// ValidatePathSegmentName validates the name can be safely encoded as a path segment +func ValidatePathSegmentName(name string, prefix bool) []string { + if prefix { + return IsValidPathSegmentPrefix(name) + } else { + return IsValidPathSegmentName(name) + } +} diff --git a/vendor/k8s.io/client-go/rest/transport.go b/vendor/k8s.io/client-go/rest/transport.go index 0672fb46c8..ba43752bc9 100644 --- a/vendor/k8s.io/client-go/rest/transport.go +++ b/vendor/k8s.io/client-go/rest/transport.go @@ -78,17 +78,22 @@ func (c *Config) TransportConfig() (*transport.Config, error) { Transport: c.Transport, WrapTransport: wt, TLS: transport.TLSConfig{ - CAFile: c.CAFile, - CAData: c.CAData, - CertFile: c.CertFile, - CertData: c.CertData, - KeyFile: c.KeyFile, - KeyData: c.KeyData, - Insecure: c.Insecure, + Insecure: c.Insecure, + ServerName: c.ServerName, + CAFile: c.CAFile, + CAData: c.CAData, + CertFile: c.CertFile, + CertData: c.CertData, + KeyFile: c.KeyFile, + KeyData: c.KeyData, }, Username: c.Username, Password: c.Password, BearerToken: c.BearerToken, - Impersonate: c.Impersonate, + Impersonate: transport.ImpersonationConfig{ + UserName: c.Impersonate.UserName, + Groups: c.Impersonate.Groups, + Extra: c.Impersonate.Extra, + }, }, nil } diff --git a/vendor/k8s.io/client-go/rest/url_utils.go b/vendor/k8s.io/client-go/rest/url_utils.go index 46da991011..14f94650a9 100644 --- a/vendor/k8s.io/client-go/rest/url_utils.go +++ b/vendor/k8s.io/client-go/rest/url_utils.go @@ -21,22 +21,19 @@ import ( "net/url" "path" - "k8s.io/client-go/pkg/api/unversioned" + "k8s.io/apimachinery/pkg/runtime/schema" ) // DefaultServerURL converts a host, host:port, or URL string to the default base server API path // to use with a Client at a given API version following the standard conventions for a // Kubernetes API. -func DefaultServerURL(host, apiPath string, groupVersion unversioned.GroupVersion, defaultTLS bool) (*url.URL, string, error) { +func DefaultServerURL(host, apiPath string, groupVersion schema.GroupVersion, defaultTLS bool) (*url.URL, string, error) { if host == "" { return nil, "", fmt.Errorf("host must be a URL or a host:port pair") } base := host hostURL, err := url.Parse(base) - if err != nil { - return nil, "", err - } - if hostURL.Scheme == "" || hostURL.Host == "" { + if err != nil || hostURL.Scheme == "" || hostURL.Host == "" { scheme := "http://" if defaultTLS { scheme = "https://" @@ -89,5 +86,5 @@ func defaultServerUrlFor(config *Config) (*url.URL, string, error) { if config.GroupVersion != nil { return DefaultServerURL(host, config.APIPath, *config.GroupVersion, defaultTLS) } - return DefaultServerURL(host, config.APIPath, unversioned.GroupVersion{}, defaultTLS) + return DefaultServerURL(host, config.APIPath, schema.GroupVersion{}, defaultTLS) } diff --git a/vendor/k8s.io/client-go/rest/urlbackoff.go b/vendor/k8s.io/client-go/rest/urlbackoff.go index 1bfb61a61b..eff848abc1 100644 --- a/vendor/k8s.io/client-go/rest/urlbackoff.go +++ b/vendor/k8s.io/client-go/rest/urlbackoff.go @@ -21,8 +21,8 @@ import ( "time" "github.com/golang/glog" - "k8s.io/client-go/pkg/util/flowcontrol" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/sets" + "k8s.io/client-go/util/flowcontrol" ) // Set of resp. Codes that we backoff for. diff --git a/vendor/k8s.io/client-go/rest/versions.go b/vendor/k8s.io/client-go/rest/versions.go index 12ef828dd7..9d41812f26 100644 --- a/vendor/k8s.io/client-go/rest/versions.go +++ b/vendor/k8s.io/client-go/rest/versions.go @@ -22,7 +22,7 @@ import ( "net/http" "path" - "k8s.io/client-go/pkg/api/unversioned" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" ) const ( @@ -57,7 +57,7 @@ func ServerAPIVersions(c *Config) (groupVersions []string, err error) { if err != nil { return nil, err } - var v unversioned.APIVersions + var v metav1.APIVersions defer resp.Body.Close() err = json.NewDecoder(resp.Body).Decode(&v) if err != nil { @@ -71,7 +71,7 @@ func ServerAPIVersions(c *Config) (groupVersions []string, err error) { if err != nil { return nil, err } - var apiGroupList unversioned.APIGroupList + var apiGroupList metav1.APIGroupList defer resp2.Body.Close() err = json.NewDecoder(resp2.Body).Decode(&apiGroupList) if err != nil { diff --git a/vendor/k8s.io/client-go/rest/watch/BUILD b/vendor/k8s.io/client-go/rest/watch/BUILD new file mode 100644 index 0000000000..c78dcce174 --- /dev/null +++ b/vendor/k8s.io/client-go/rest/watch/BUILD @@ -0,0 +1,46 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = [ + "decoder.go", + "encoder.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + ], +) + +go_test( + name = "go_default_xtest", + srcs = [ + "decoder_test.go", + "encoder_test.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/api/equality:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/json:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/streaming:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/rest/watch:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/watch/versioned/decoder.go b/vendor/k8s.io/client-go/rest/watch/decoder.go similarity index 88% rename from vendor/k8s.io/client-go/pkg/watch/versioned/decoder.go rename to vendor/k8s.io/client-go/rest/watch/decoder.go index 25390c5e4e..73bb63addf 100644 --- a/vendor/k8s.io/client-go/pkg/watch/versioned/decoder.go +++ b/vendor/k8s.io/client-go/rest/watch/decoder.go @@ -19,9 +19,10 @@ package versioned import ( "fmt" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/streaming" - "k8s.io/client-go/pkg/watch" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/serializer/streaming" + "k8s.io/apimachinery/pkg/watch" ) // Decoder implements the watch.Decoder interface for io.ReadClosers that @@ -44,13 +45,13 @@ func NewDecoder(decoder streaming.Decoder, embeddedDecoder runtime.Decoder) *Dec // Decode blocks until it can return the next object in the reader. Returns an error // if the reader is closed or an object can't be decoded. func (d *Decoder) Decode() (watch.EventType, runtime.Object, error) { - var got Event + var got metav1.WatchEvent res, _, err := d.decoder.Decode(nil, &got) if err != nil { return "", nil, err } if res != &got { - return "", nil, fmt.Errorf("unable to decode to versioned.Event") + return "", nil, fmt.Errorf("unable to decode to metav1.Event") } switch got.Type { case string(watch.Added), string(watch.Modified), string(watch.Deleted), string(watch.Error): diff --git a/vendor/k8s.io/client-go/pkg/watch/versioned/encoder.go b/vendor/k8s.io/client-go/rest/watch/encoder.go similarity index 79% rename from vendor/k8s.io/client-go/pkg/watch/versioned/encoder.go rename to vendor/k8s.io/client-go/rest/watch/encoder.go index 3d7f436f87..e55aa12d9b 100644 --- a/vendor/k8s.io/client-go/pkg/watch/versioned/encoder.go +++ b/vendor/k8s.io/client-go/rest/watch/encoder.go @@ -19,14 +19,16 @@ package versioned import ( "encoding/json" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/streaming" - "k8s.io/client-go/pkg/watch" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/serializer/streaming" + "k8s.io/apimachinery/pkg/watch" ) // Encoder serializes watch.Events into io.Writer. The internal objects // are encoded using embedded encoder, and the outer Event is serialized // using encoder. +// TODO: this type is only used by tests type Encoder struct { encoder streaming.Encoder embeddedEncoder runtime.Encoder @@ -47,5 +49,8 @@ func (e *Encoder) Encode(event *watch.Event) error { return err } // FIXME: get rid of json.RawMessage. - return e.encoder.Encode(&Event{string(event.Type), runtime.RawExtension{Raw: json.RawMessage(data)}}) + return e.encoder.Encode(&metav1.WatchEvent{ + Type: string(event.Type), + Object: runtime.RawExtension{Raw: json.RawMessage(data)}, + }) } diff --git a/vendor/k8s.io/client-go/tools/auth/BUILD b/vendor/k8s.io/client-go/tools/auth/BUILD new file mode 100644 index 0000000000..af00eb6460 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/auth/BUILD @@ -0,0 +1,23 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_library( + name = "go_default_library", + srcs = ["clientauth.go"], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/client-go/rest:go_default_library"], +) + +go_test( + name = "go_default_xtest", + srcs = ["clientauth_test.go"], + tags = ["automanaged"], + deps = ["//vendor/k8s.io/client-go/tools/auth:go_default_library"], +) diff --git a/vendor/k8s.io/client-go/tools/auth/clientauth.go b/vendor/k8s.io/client-go/tools/auth/clientauth.go index d820adcafe..2213b98781 100644 --- a/vendor/k8s.io/client-go/tools/auth/clientauth.go +++ b/vendor/k8s.io/client-go/tools/auth/clientauth.go @@ -68,7 +68,7 @@ import ( "io/ioutil" "os" - "k8s.io/client-go/rest" + restclient "k8s.io/client-go/rest" ) // Info holds Kubernetes API authorization config. It is intended @@ -104,8 +104,8 @@ func LoadFromFile(path string) (*Info, error) { // MergeWithConfig returns a copy of a client.Config with values from the Info. // The fields of client.Config with a corresponding field in the Info are set // with the value from the Info. -func (info Info) MergeWithConfig(c rest.Config) (rest.Config, error) { - var config rest.Config = c +func (info Info) MergeWithConfig(c restclient.Config) (restclient.Config, error) { + var config restclient.Config = c config.Username = info.User config.Password = info.Password config.CAFile = info.CAFile diff --git a/vendor/k8s.io/client-go/tools/cache/BUILD b/vendor/k8s.io/client-go/tools/cache/BUILD new file mode 100644 index 0000000000..e2fd6f192a --- /dev/null +++ b/vendor/k8s.io/client-go/tools/cache/BUILD @@ -0,0 +1,84 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "controller_test.go", + "delta_fifo_test.go", + "expiration_cache_test.go", + "fifo_test.go", + "index_test.go", + "mutation_detector_test.go", + "processor_listener_test.go", + "reflector_test.go", + "shared_informer_test.go", + "store_test.go", + "undelta_store_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/tools/cache/testing:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "controller.go", + "delta_fifo.go", + "doc.go", + "expiration_cache.go", + "expiration_cache_fakes.go", + "fake_custom_store.go", + "fifo.go", + "index.go", + "listers.go", + "listwatch.go", + "mutation_cache.go", + "mutation_detector.go", + "reflector.go", + "shared_informer.go", + "store.go", + "thread_safe_store.go", + "undelta_store.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/api/meta:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/apis/meta/v1:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/fields:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/labels:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/cache:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/diff:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/sets:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/wait:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/watch:go_default_library", + "//vendor/k8s.io/client-go/kubernetes/scheme:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/tools/cache/OWNERS b/vendor/k8s.io/client-go/tools/cache/OWNERS new file mode 100755 index 0000000000..e923c77092 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/cache/OWNERS @@ -0,0 +1,41 @@ +reviewers: +- thockin +- lavalamp +- smarterclayton +- wojtek-t +- deads2k +- brendandburns +- derekwaynecarr +- caesarxuchao +- mikedanese +- liggitt +- nikhiljindal +- bprashanth +- erictune +- davidopp +- pmorie +- kargakis +- janetkuo +- justinsb +- eparis +- soltysh +- jsafrane +- dims +- madhusudancs +- hongchaodeng +- krousey +- markturansky +- fgrzadkowski +- xiang90 +- mml +- ingvagabund +- resouer +- jessfraz +- david-mcmahon +- mfojtik +- '249043822' +- lixiaobing10051267 +- ddysher +- mqliang +- feihujiang +- sdminonne diff --git a/vendor/k8s.io/client-go/tools/cache/controller.go b/vendor/k8s.io/client-go/tools/cache/controller.go index ff4ec0122a..2c97b86580 100644 --- a/vendor/k8s.io/client-go/tools/cache/controller.go +++ b/vendor/k8s.io/client-go/tools/cache/controller.go @@ -20,9 +20,10 @@ import ( "sync" "time" - "k8s.io/client-go/pkg/runtime" - utilruntime "k8s.io/client-go/pkg/util/runtime" - "k8s.io/client-go/pkg/util/wait" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/clock" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + "k8s.io/apimachinery/pkg/util/wait" ) // Config contains all the settings for a Controller. @@ -50,6 +51,11 @@ type Config struct { // queue. FullResyncPeriod time.Duration + // ShouldResync, if specified, is invoked when the controller's reflector determines the next + // periodic sync should occur. If this returns true, it means the reflector should proceed with + // the resync. + ShouldResync ShouldResyncFunc + // If true, when Process() returns an error, re-enqueue the object. // TODO: add interface to let you inject a delay/backoff or drop // the object completely if desired. Pass the object in @@ -57,26 +63,33 @@ type Config struct { RetryOnError bool } +// ShouldResyncFunc is a type of function that indicates if a reflector should perform a +// resync or not. It can be used by a shared informer to support multiple event handlers with custom +// resync periods. +type ShouldResyncFunc func() bool + // ProcessFunc processes a single object. type ProcessFunc func(obj interface{}) error // Controller is a generic controller framework. -type Controller struct { +type controller struct { config Config reflector *Reflector reflectorMutex sync.RWMutex + clock clock.Clock } -// TODO make the "Controller" private, and convert all references to use ControllerInterface instead -type ControllerInterface interface { +type Controller interface { Run(stopCh <-chan struct{}) HasSynced() bool + LastSyncResourceVersion() string } // New makes a new Controller from the given Config. -func New(c *Config) *Controller { - ctlr := &Controller{ +func New(c *Config) Controller { + ctlr := &controller{ config: *c, + clock: &clock.RealClock{}, } return ctlr } @@ -84,14 +97,20 @@ func New(c *Config) *Controller { // Run begins processing items, and will continue until a value is sent down stopCh. // It's an error to call Run more than once. // Run blocks; call via go. -func (c *Controller) Run(stopCh <-chan struct{}) { +func (c *controller) Run(stopCh <-chan struct{}) { defer utilruntime.HandleCrash() + go func() { + <-stopCh + c.config.Queue.Close() + }() r := NewReflector( c.config.ListerWatcher, c.config.ObjectType, c.config.Queue, c.config.FullResyncPeriod, ) + r.ShouldResync = c.config.ShouldResync + r.clock = c.clock c.reflectorMutex.Lock() c.reflector = r @@ -103,18 +122,15 @@ func (c *Controller) Run(stopCh <-chan struct{}) { } // Returns true once this controller has completed an initial resource listing -func (c *Controller) HasSynced() bool { +func (c *controller) HasSynced() bool { return c.config.Queue.HasSynced() } -// Requeue adds the provided object back into the queue if it does not already exist. -func (c *Controller) Requeue(obj interface{}) error { - return c.config.Queue.AddIfNotPresent(Deltas{ - Delta{ - Type: Sync, - Object: obj, - }, - }) +func (c *controller) LastSyncResourceVersion() string { + if c.reflector == nil { + return "" + } + return c.reflector.LastSyncResourceVersion() } // processLoop drains the work queue. @@ -126,10 +142,13 @@ func (c *Controller) Requeue(obj interface{}) error { // actually exit when the controller is stopped. Or just give up on this stuff // ever being stoppable. Converting this whole package to use Context would // also be helpful. -func (c *Controller) processLoop() { +func (c *controller) processLoop() { for { obj, err := c.config.Queue.Pop(PopProcessFunc(c.config.Process)) if err != nil { + if err == FIFOClosedError { + return + } if c.config.RetryOnError { // This is the safe way to re-enqueue. c.config.Queue.AddIfNotPresent(obj) @@ -188,6 +207,47 @@ func (r ResourceEventHandlerFuncs) OnDelete(obj interface{}) { } } +// FilteringResourceEventHandler applies the provided filter to all events coming +// in, ensuring the appropriate nested handler method is invoked. An object +// that starts passing the filter after an update is considered an add, and an +// object that stops passing the filter after an update is considered a delete. +type FilteringResourceEventHandler struct { + FilterFunc func(obj interface{}) bool + Handler ResourceEventHandler +} + +// OnAdd calls the nested handler only if the filter succeeds +func (r FilteringResourceEventHandler) OnAdd(obj interface{}) { + if !r.FilterFunc(obj) { + return + } + r.Handler.OnAdd(obj) +} + +// OnUpdate ensures the proper handler is called depending on whether the filter matches +func (r FilteringResourceEventHandler) OnUpdate(oldObj, newObj interface{}) { + newer := r.FilterFunc(newObj) + older := r.FilterFunc(oldObj) + switch { + case newer && older: + r.Handler.OnUpdate(oldObj, newObj) + case newer && !older: + r.Handler.OnAdd(newObj) + case !newer && older: + r.Handler.OnDelete(oldObj) + default: + // do nothing + } +} + +// OnDelete calls the nested handler only if the filter succeeds +func (r FilteringResourceEventHandler) OnDelete(obj interface{}) { + if !r.FilterFunc(obj) { + return + } + r.Handler.OnDelete(obj) +} + // DeletionHandlingMetaNamespaceKeyFunc checks for // DeletedFinalStateUnknown objects before calling // MetaNamespaceKeyFunc. @@ -218,7 +278,7 @@ func NewInformer( objType runtime.Object, resyncPeriod time.Duration, h ResourceEventHandler, -) (Store, *Controller) { +) (Store, Controller) { // This will hold the client state, as we know it. clientState := NewStore(DeletionHandlingMetaNamespaceKeyFunc) @@ -277,6 +337,7 @@ func NewInformer( // long as possible (until the upstream source closes the watch or times out, // or you stop the controller). // * h is the object you want notifications sent to. +// * indexers is the indexer for the received object type. // func NewIndexerInformer( lw ListerWatcher, @@ -284,7 +345,7 @@ func NewIndexerInformer( resyncPeriod time.Duration, h ResourceEventHandler, indexers Indexers, -) (Indexer, *Controller) { +) (Indexer, Controller) { // This will hold the client state, as we know it. clientState := NewIndexer(DeletionHandlingMetaNamespaceKeyFunc, indexers) diff --git a/vendor/k8s.io/client-go/tools/cache/delta_fifo.go b/vendor/k8s.io/client-go/tools/cache/delta_fifo.go index af7de8a976..a71db60488 100644 --- a/vendor/k8s.io/client-go/tools/cache/delta_fifo.go +++ b/vendor/k8s.io/client-go/tools/cache/delta_fifo.go @@ -21,7 +21,7 @@ import ( "fmt" "sync" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/sets" "github.com/golang/glog" ) @@ -118,6 +118,12 @@ type DeltaFIFO struct { // purpose of figuring out which items have been deleted // when Replace() or Delete() is called. knownObjects KeyListerGetter + + // Indication the queue is closed. + // Used to indicate a queue is closed so a control loop can exit when a queue is empty. + // Currently, not used to gate any of CRED operations. + closed bool + closedLock sync.Mutex } var ( @@ -132,6 +138,14 @@ var ( ErrZeroLengthDeltasObject = errors.New("0 length Deltas object; can't get key") ) +// Close the queue. +func (f *DeltaFIFO) Close() { + f.closedLock.Lock() + defer f.closedLock.Unlock() + f.closed = true + f.cond.Broadcast() +} + // KeyOf exposes f's keyFunc, but also detects the key of a Deltas object or // DeletedFinalStateUnknown objects. func (f *DeltaFIFO) KeyOf(obj interface{}) (string, error) { @@ -387,6 +401,16 @@ func (f *DeltaFIFO) GetByKey(key string) (item interface{}, exists bool, err err return d, exists, nil } +// Checks if the queue is closed +func (f *DeltaFIFO) IsClosed() bool { + f.closedLock.Lock() + defer f.closedLock.Unlock() + if f.closed { + return true + } + return false +} + // Pop blocks until an item is added to the queue, and then returns it. If // multiple items are ready, they are returned in the order in which they were // added/updated. The item is removed from the queue (and the store) before it @@ -404,6 +428,13 @@ func (f *DeltaFIFO) Pop(process PopProcessFunc) (interface{}, error) { defer f.lock.Unlock() for { for len(f.queue) == 0 { + // When the queue is empty, invocation of Pop() is blocked until new item is enqueued. + // When Close() is called, the f.closed is set and the condition is broadcasted. + // Which causes this loop to continue and return from the Pop(). + if f.IsClosed() { + return nil, FIFOClosedError + } + f.cond.Wait() } id := f.queue[0] @@ -505,14 +536,12 @@ func (f *DeltaFIFO) Replace(list []interface{}, resourceVersion string) error { // Resync will send a sync event for each item func (f *DeltaFIFO) Resync() error { - var keys []string - func() { - f.lock.RLock() - defer f.lock.RUnlock() - keys = f.knownObjects.ListKeys() - }() + f.lock.Lock() + defer f.lock.Unlock() + + keys := f.knownObjects.ListKeys() for _, k := range keys { - if err := f.syncKey(k); err != nil { + if err := f.syncKeyLocked(k); err != nil { return err } } @@ -522,6 +551,11 @@ func (f *DeltaFIFO) Resync() error { func (f *DeltaFIFO) syncKey(key string) error { f.lock.Lock() defer f.lock.Unlock() + + return f.syncKeyLocked(key) +} + +func (f *DeltaFIFO) syncKeyLocked(key string) error { obj, exists, err := f.knownObjects.GetByKey(key) if err != nil { glog.Errorf("Unexpected error %v during lookup of key %v, unable to queue object for sync", err, key) diff --git a/vendor/k8s.io/client-go/tools/cache/expiration_cache.go b/vendor/k8s.io/client-go/tools/cache/expiration_cache.go index 10d68c533a..fa88fc407e 100644 --- a/vendor/k8s.io/client-go/tools/cache/expiration_cache.go +++ b/vendor/k8s.io/client-go/tools/cache/expiration_cache.go @@ -21,7 +21,7 @@ import ( "time" "github.com/golang/glog" - "k8s.io/client-go/pkg/util/clock" + "k8s.io/apimachinery/pkg/util/clock" ) // ExpirationCache implements the store interface diff --git a/vendor/k8s.io/client-go/tools/cache/expiration_cache_fakes.go b/vendor/k8s.io/client-go/tools/cache/expiration_cache_fakes.go index 13f4e4c0f5..a096765f6b 100644 --- a/vendor/k8s.io/client-go/tools/cache/expiration_cache_fakes.go +++ b/vendor/k8s.io/client-go/tools/cache/expiration_cache_fakes.go @@ -17,8 +17,8 @@ limitations under the License. package cache import ( - "k8s.io/client-go/pkg/util/clock" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/clock" + "k8s.io/apimachinery/pkg/util/sets" ) type fakeThreadSafeMap struct { diff --git a/vendor/k8s.io/client-go/tools/cache/fifo.go b/vendor/k8s.io/client-go/tools/cache/fifo.go index 0e1c9a8bed..3f6e2a9480 100644 --- a/vendor/k8s.io/client-go/tools/cache/fifo.go +++ b/vendor/k8s.io/client-go/tools/cache/fifo.go @@ -17,9 +17,10 @@ limitations under the License. package cache import ( + "errors" "sync" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/sets" ) // PopProcessFunc is passed to Pop() method of Queue interface. @@ -33,6 +34,8 @@ type ErrRequeue struct { Err error } +var FIFOClosedError error = errors.New("DeltaFIFO: manipulating with closed queue") + func (e ErrRequeue) Error() string { if e.Err == nil { return "the popped item should be requeued without returning an error" @@ -58,6 +61,9 @@ type Queue interface { // Return true if the first batch of items has been popped HasSynced() bool + + // Close queue + Close() } // Helper function for popping from Queue. @@ -100,12 +106,26 @@ type FIFO struct { // keyFunc is used to make the key used for queued item insertion and retrieval, and // should be deterministic. keyFunc KeyFunc + + // Indication the queue is closed. + // Used to indicate a queue is closed so a control loop can exit when a queue is empty. + // Currently, not used to gate any of CRED operations. + closed bool + closedLock sync.Mutex } var ( _ = Queue(&FIFO{}) // FIFO is a Queue ) +// Close the queue. +func (f *FIFO) Close() { + f.closedLock.Lock() + defer f.closedLock.Unlock() + f.closed = true + f.cond.Broadcast() +} + // Return true if an Add/Update/Delete/AddIfNotPresent are called first, // or an Update called first but the first batch of items inserted by Replace() has been popped func (f *FIFO) HasSynced() bool { @@ -222,6 +242,16 @@ func (f *FIFO) GetByKey(key string) (item interface{}, exists bool, err error) { return item, exists, nil } +// Checks if the queue is closed +func (f *FIFO) IsClosed() bool { + f.closedLock.Lock() + defer f.closedLock.Unlock() + if f.closed { + return true + } + return false +} + // Pop waits until an item is ready and processes it. If multiple items are // ready, they are returned in the order in which they were added/updated. // The item is removed from the queue (and the store) before it is processed, @@ -233,6 +263,13 @@ func (f *FIFO) Pop(process PopProcessFunc) (interface{}, error) { defer f.lock.Unlock() for { for len(f.queue) == 0 { + // When the queue is empty, invocation of Pop() is blocked until new item is enqueued. + // When Close() is called, the f.closed is set and the condition is broadcasted. + // Which causes this loop to continue and return from the Pop(). + if f.IsClosed() { + return nil, FIFOClosedError + } + f.cond.Wait() } id := f.queue[0] diff --git a/vendor/k8s.io/client-go/tools/cache/index.go b/vendor/k8s.io/client-go/tools/cache/index.go index 25ad678058..15acb168ef 100644 --- a/vendor/k8s.io/client-go/tools/cache/index.go +++ b/vendor/k8s.io/client-go/tools/cache/index.go @@ -19,8 +19,8 @@ package cache import ( "fmt" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/util/sets" ) // Indexer is a storage interface that lets you list objects using multiple indexing functions @@ -28,6 +28,8 @@ type Indexer interface { Store // Retrieve list of objects that match on the named indexing function Index(indexName string, obj interface{}) ([]interface{}, error) + // IndexKeys returns the set of keys that match on the named indexing function. + IndexKeys(indexName, indexKey string) ([]string, error) // ListIndexFuncValues returns the list of generated values of an Index func ListIndexFuncValues(indexName string) []string // ByIndex lists object that match on the named indexing function with the exact key diff --git a/vendor/k8s.io/client-go/tools/cache/listers.go b/vendor/k8s.io/client-go/tools/cache/listers.go index eafac197af..27d51a6b38 100644 --- a/vendor/k8s.io/client-go/tools/cache/listers.go +++ b/vendor/k8s.io/client-go/tools/cache/listers.go @@ -17,20 +17,14 @@ limitations under the License. package cache import ( - "fmt" - "github.com/golang/glog" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/apis/apps" - "k8s.io/client-go/pkg/apis/certificates" - "k8s.io/client-go/pkg/apis/extensions" - "k8s.io/client-go/pkg/apis/policy" - "k8s.io/client-go/pkg/apis/storage" - "k8s.io/client-go/pkg/labels" - "k8s.io/client-go/pkg/runtime" + + "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/api/meta" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/labels" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // AppendFunc is used to add a matching item to whatever list the caller is using @@ -50,7 +44,7 @@ func ListAll(store Store, selector labels.Selector, appendFn AppendFunc) error { } func ListAllByNamespace(indexer Indexer, namespace string, selector labels.Selector, appendFn AppendFunc) error { - if namespace == api.NamespaceAll { + if namespace == metav1.NamespaceAll { for _, m := range indexer.List() { metadata, err := meta.Accessor(m) if err != nil { @@ -63,7 +57,7 @@ func ListAllByNamespace(indexer Indexer, namespace string, selector labels.Selec return nil } - items, err := indexer.Index(NamespaceIndex, &api.ObjectMeta{Namespace: namespace}) + items, err := indexer.Index(NamespaceIndex, &metav1.ObjectMeta{Namespace: namespace}) if err != nil { // Ignore error; do slow search without index. glog.Warningf("can not retrieve list of objects using index : %v", err) @@ -110,13 +104,13 @@ type GenericNamespaceLister interface { Get(name string) (runtime.Object, error) } -func NewGenericLister(indexer Indexer, resource unversioned.GroupResource) GenericLister { +func NewGenericLister(indexer Indexer, resource schema.GroupResource) GenericLister { return &genericLister{indexer: indexer, resource: resource} } type genericLister struct { indexer Indexer - resource unversioned.GroupResource + resource schema.GroupResource } func (s *genericLister) List(selector labels.Selector) (ret []runtime.Object, err error) { @@ -144,7 +138,7 @@ func (s *genericLister) Get(name string) (runtime.Object, error) { type genericNamespaceLister struct { indexer Indexer namespace string - resource unversioned.GroupResource + resource schema.GroupResource } func (s *genericNamespaceLister) List(selector labels.Selector) (ret []runtime.Object, err error) { @@ -164,315 +158,3 @@ func (s *genericNamespaceLister) Get(name string) (runtime.Object, error) { } return obj.(runtime.Object), nil } - -// TODO: generate these classes and methods for all resources of interest using -// a script. Can use "go generate" once 1.4 is supported by all users. - -// NodeConditionPredicate is a function that indicates whether the given node's conditions meet -// some set of criteria defined by the function. -type NodeConditionPredicate func(node *api.Node) bool - -// StoreToNodeLister makes a Store have the List method of the client.NodeInterface -// The Store must contain (only) Nodes. -type StoreToNodeLister struct { - Store -} - -func (s *StoreToNodeLister) List() (machines api.NodeList, err error) { - for _, m := range s.Store.List() { - machines.Items = append(machines.Items, *(m.(*api.Node))) - } - return machines, nil -} - -// NodeCondition returns a storeToNodeConditionLister -func (s *StoreToNodeLister) NodeCondition(predicate NodeConditionPredicate) storeToNodeConditionLister { - // TODO: Move this filtering server side. Currently our selectors don't facilitate searching through a list so we - // have the reflector filter out the Unschedulable field and sift through node conditions in the lister. - return storeToNodeConditionLister{s.Store, predicate} -} - -// storeToNodeConditionLister filters and returns nodes matching the given type and status from the store. -type storeToNodeConditionLister struct { - store Store - predicate NodeConditionPredicate -} - -// List returns a list of nodes that match the conditions defined by the predicate functions in the storeToNodeConditionLister. -func (s storeToNodeConditionLister) List() (nodes []*api.Node, err error) { - for _, m := range s.store.List() { - node := m.(*api.Node) - if s.predicate(node) { - nodes = append(nodes, node) - } else { - glog.V(5).Infof("Node %s matches none of the conditions", node.Name) - } - } - return -} - -// StoreToDaemonSetLister gives a store List and Exists methods. The store must contain only DaemonSets. -type StoreToDaemonSetLister struct { - Store -} - -// Exists checks if the given daemon set exists in the store. -func (s *StoreToDaemonSetLister) Exists(ds *extensions.DaemonSet) (bool, error) { - _, exists, err := s.Store.Get(ds) - if err != nil { - return false, err - } - return exists, nil -} - -// List lists all daemon sets in the store. -// TODO: converge on the interface in pkg/client -func (s *StoreToDaemonSetLister) List() (dss extensions.DaemonSetList, err error) { - for _, c := range s.Store.List() { - dss.Items = append(dss.Items, *(c.(*extensions.DaemonSet))) - } - return dss, nil -} - -// GetPodDaemonSets returns a list of daemon sets managing a pod. -// Returns an error if and only if no matching daemon sets are found. -func (s *StoreToDaemonSetLister) GetPodDaemonSets(pod *api.Pod) (daemonSets []extensions.DaemonSet, err error) { - var selector labels.Selector - var daemonSet extensions.DaemonSet - - if len(pod.Labels) == 0 { - err = fmt.Errorf("no daemon sets found for pod %v because it has no labels", pod.Name) - return - } - - for _, m := range s.Store.List() { - daemonSet = *m.(*extensions.DaemonSet) - if daemonSet.Namespace != pod.Namespace { - continue - } - selector, err = unversioned.LabelSelectorAsSelector(daemonSet.Spec.Selector) - if err != nil { - // this should not happen if the DaemonSet passed validation - return nil, err - } - - // If a daemonSet with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(pod.Labels)) { - continue - } - daemonSets = append(daemonSets, daemonSet) - } - if len(daemonSets) == 0 { - err = fmt.Errorf("could not find daemon set for pod %s in namespace %s with labels: %v", pod.Name, pod.Namespace, pod.Labels) - } - return -} - -// StoreToEndpointsLister makes a Store that lists endpoints. -type StoreToEndpointsLister struct { - Store -} - -// List lists all endpoints in the store. -func (s *StoreToEndpointsLister) List() (services api.EndpointsList, err error) { - for _, m := range s.Store.List() { - services.Items = append(services.Items, *(m.(*api.Endpoints))) - } - return services, nil -} - -// GetServiceEndpoints returns the endpoints of a service, matched on service name. -func (s *StoreToEndpointsLister) GetServiceEndpoints(svc *api.Service) (ep api.Endpoints, err error) { - for _, m := range s.Store.List() { - ep = *m.(*api.Endpoints) - if svc.Name == ep.Name && svc.Namespace == ep.Namespace { - return ep, nil - } - } - err = fmt.Errorf("could not find endpoints for service: %v", svc.Name) - return -} - -// Typed wrapper around a store of PersistentVolumes -type StoreToPVFetcher struct { - Store -} - -// GetPersistentVolumeInfo returns cached data for the PersistentVolume 'id'. -func (s *StoreToPVFetcher) GetPersistentVolumeInfo(id string) (*api.PersistentVolume, error) { - o, exists, err := s.Get(&api.PersistentVolume{ObjectMeta: api.ObjectMeta{Name: id}}) - - if err != nil { - return nil, fmt.Errorf("error retrieving PersistentVolume '%v' from cache: %v", id, err) - } - - if !exists { - return nil, fmt.Errorf("PersistentVolume '%v' not found", id) - } - - return o.(*api.PersistentVolume), nil -} - -// StoreToStatefulSetLister gives a store List and Exists methods. The store must contain only StatefulSets. -type StoreToStatefulSetLister struct { - Store -} - -// Exists checks if the given StatefulSet exists in the store. -func (s *StoreToStatefulSetLister) Exists(ps *apps.StatefulSet) (bool, error) { - _, exists, err := s.Store.Get(ps) - if err != nil { - return false, err - } - return exists, nil -} - -// List lists all StatefulSets in the store. -func (s *StoreToStatefulSetLister) List() (psList []apps.StatefulSet, err error) { - for _, ps := range s.Store.List() { - psList = append(psList, *(ps.(*apps.StatefulSet))) - } - return psList, nil -} - -type storeStatefulSetsNamespacer struct { - store Store - namespace string -} - -func (s *StoreToStatefulSetLister) StatefulSets(namespace string) storeStatefulSetsNamespacer { - return storeStatefulSetsNamespacer{s.Store, namespace} -} - -// GetPodStatefulSets returns a list of StatefulSets managing a pod. Returns an error only if no matching StatefulSets are found. -func (s *StoreToStatefulSetLister) GetPodStatefulSets(pod *api.Pod) (psList []apps.StatefulSet, err error) { - var selector labels.Selector - var ps apps.StatefulSet - - if len(pod.Labels) == 0 { - err = fmt.Errorf("no StatefulSets found for pod %v because it has no labels", pod.Name) - return - } - - for _, m := range s.Store.List() { - ps = *m.(*apps.StatefulSet) - if ps.Namespace != pod.Namespace { - continue - } - selector, err = unversioned.LabelSelectorAsSelector(ps.Spec.Selector) - if err != nil { - err = fmt.Errorf("invalid selector: %v", err) - return - } - - // If a StatefulSet with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(pod.Labels)) { - continue - } - psList = append(psList, ps) - } - if len(psList) == 0 { - err = fmt.Errorf("could not find StatefulSet for pod %s in namespace %s with labels: %v", pod.Name, pod.Namespace, pod.Labels) - } - return -} - -// StoreToCertificateRequestLister gives a store List and Exists methods. The store must contain only CertificateRequests. -type StoreToCertificateRequestLister struct { - Store -} - -// Exists checks if the given csr exists in the store. -func (s *StoreToCertificateRequestLister) Exists(csr *certificates.CertificateSigningRequest) (bool, error) { - _, exists, err := s.Store.Get(csr) - if err != nil { - return false, err - } - return exists, nil -} - -// StoreToCertificateRequestLister lists all csrs in the store. -func (s *StoreToCertificateRequestLister) List() (csrs certificates.CertificateSigningRequestList, err error) { - for _, c := range s.Store.List() { - csrs.Items = append(csrs.Items, *(c.(*certificates.CertificateSigningRequest))) - } - return csrs, nil -} - -type StoreToPodDisruptionBudgetLister struct { - Store -} - -// GetPodPodDisruptionBudgets returns a list of PodDisruptionBudgets matching a pod. Returns an error only if no matching PodDisruptionBudgets are found. -func (s *StoreToPodDisruptionBudgetLister) GetPodPodDisruptionBudgets(pod *api.Pod) (pdbList []policy.PodDisruptionBudget, err error) { - var selector labels.Selector - - if len(pod.Labels) == 0 { - err = fmt.Errorf("no PodDisruptionBudgets found for pod %v because it has no labels", pod.Name) - return - } - - for _, m := range s.Store.List() { - pdb, ok := m.(*policy.PodDisruptionBudget) - if !ok { - glog.Errorf("Unexpected: %v is not a PodDisruptionBudget", m) - continue - } - if pdb.Namespace != pod.Namespace { - continue - } - selector, err = unversioned.LabelSelectorAsSelector(pdb.Spec.Selector) - if err != nil { - glog.Warningf("invalid selector: %v", err) - // TODO(mml): add an event to the PDB - continue - } - - // If a PDB with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(pod.Labels)) { - continue - } - pdbList = append(pdbList, *pdb) - } - if len(pdbList) == 0 { - err = fmt.Errorf("could not find PodDisruptionBudget for pod %s in namespace %s with labels: %v", pod.Name, pod.Namespace, pod.Labels) - } - return -} - -// StorageClassLister knows how to list storage classes -type StorageClassLister interface { - List(selector labels.Selector) (ret []*storage.StorageClass, err error) - Get(name string) (*storage.StorageClass, error) -} - -// storageClassLister implements StorageClassLister -type storageClassLister struct { - indexer Indexer -} - -// NewStorageClassLister returns a new lister. -func NewStorageClassLister(indexer Indexer) StorageClassLister { - return &storageClassLister{indexer: indexer} -} - -// List returns a list of storage classes -func (s *storageClassLister) List(selector labels.Selector) (ret []*storage.StorageClass, err error) { - err = ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*storage.StorageClass)) - }) - return ret, err -} - -// List returns a list of storage classes -func (s *storageClassLister) Get(name string) (*storage.StorageClass, error) { - key := &storage.StorageClass{ObjectMeta: api.ObjectMeta{Name: name}} - obj, exists, err := s.indexer.Get(key) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(storage.Resource("storageclass"), name) - } - return obj.(*storage.StorageClass), nil -} diff --git a/vendor/k8s.io/client-go/tools/cache/listers_core.go b/vendor/k8s.io/client-go/tools/cache/listers_core.go deleted file mode 100644 index b9038e4ae7..0000000000 --- a/vendor/k8s.io/client-go/tools/cache/listers_core.go +++ /dev/null @@ -1,348 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package cache - -import ( - "fmt" - - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/labels" -) - -// TODO: generate these classes and methods for all resources of interest using -// a script. Can use "go generate" once 1.4 is supported by all users. - -// Lister makes an Index have the List method. The Stores must contain only the expected type -// Example: -// s := cache.NewStore() -// lw := cache.ListWatch{Client: c, FieldSelector: sel, Resource: "pods"} -// r := cache.NewReflector(lw, &api.Pod{}, s).Run() -// l := StoreToPodLister{s} -// l.List() - -// StoreToPodLister helps list pods -type StoreToPodLister struct { - Indexer Indexer -} - -func (s *StoreToPodLister) List(selector labels.Selector) (ret []*api.Pod, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.Pod)) - }) - return ret, err -} - -func (s *StoreToPodLister) Pods(namespace string) storePodsNamespacer { - return storePodsNamespacer{Indexer: s.Indexer, namespace: namespace} -} - -type storePodsNamespacer struct { - Indexer Indexer - namespace string -} - -func (s storePodsNamespacer) List(selector labels.Selector) (ret []*api.Pod, err error) { - err = ListAllByNamespace(s.Indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*api.Pod)) - }) - return ret, err -} - -func (s storePodsNamespacer) Get(name string) (*api.Pod, error) { - obj, exists, err := s.Indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("pod"), name) - } - return obj.(*api.Pod), nil -} - -// StoreToServiceLister helps list services -type StoreToServiceLister struct { - Indexer Indexer -} - -func (s *StoreToServiceLister) List(selector labels.Selector) (ret []*api.Service, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.Service)) - }) - return ret, err -} - -func (s *StoreToServiceLister) Services(namespace string) storeServicesNamespacer { - return storeServicesNamespacer{s.Indexer, namespace} -} - -type storeServicesNamespacer struct { - indexer Indexer - namespace string -} - -func (s storeServicesNamespacer) List(selector labels.Selector) (ret []*api.Service, err error) { - err = ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*api.Service)) - }) - return ret, err -} - -func (s storeServicesNamespacer) Get(name string) (*api.Service, error) { - obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("service"), name) - } - return obj.(*api.Service), nil -} - -// TODO: Move this back to scheduler as a helper function that takes a Store, -// rather than a method of StoreToServiceLister. -func (s *StoreToServiceLister) GetPodServices(pod *api.Pod) (services []*api.Service, err error) { - allServices, err := s.Services(pod.Namespace).List(labels.Everything()) - if err != nil { - return nil, err - } - - for i := range allServices { - service := allServices[i] - if service.Spec.Selector == nil { - // services with nil selectors match nothing, not everything. - continue - } - selector := labels.Set(service.Spec.Selector).AsSelectorPreValidated() - if selector.Matches(labels.Set(pod.Labels)) { - services = append(services, service) - } - } - - return services, nil -} - -// StoreToReplicationControllerLister helps list rcs -type StoreToReplicationControllerLister struct { - Indexer Indexer -} - -func (s *StoreToReplicationControllerLister) List(selector labels.Selector) (ret []*api.ReplicationController, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.ReplicationController)) - }) - return ret, err -} - -func (s *StoreToReplicationControllerLister) ReplicationControllers(namespace string) storeReplicationControllersNamespacer { - return storeReplicationControllersNamespacer{s.Indexer, namespace} -} - -type storeReplicationControllersNamespacer struct { - indexer Indexer - namespace string -} - -func (s storeReplicationControllersNamespacer) List(selector labels.Selector) (ret []*api.ReplicationController, err error) { - err = ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*api.ReplicationController)) - }) - return ret, err -} - -func (s storeReplicationControllersNamespacer) Get(name string) (*api.ReplicationController, error) { - obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("replicationcontroller"), name) - } - return obj.(*api.ReplicationController), nil -} - -// GetPodControllers returns a list of replication controllers managing a pod. Returns an error only if no matching controllers are found. -func (s *StoreToReplicationControllerLister) GetPodControllers(pod *api.Pod) (controllers []*api.ReplicationController, err error) { - if len(pod.Labels) == 0 { - err = fmt.Errorf("no controllers found for pod %v because it has no labels", pod.Name) - return - } - - key := &api.ReplicationController{ObjectMeta: api.ObjectMeta{Namespace: pod.Namespace}} - items, err := s.Indexer.Index(NamespaceIndex, key) - if err != nil { - return - } - - for _, m := range items { - rc := m.(*api.ReplicationController) - selector := labels.Set(rc.Spec.Selector).AsSelectorPreValidated() - - // If an rc with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(pod.Labels)) { - continue - } - controllers = append(controllers, rc) - } - if len(controllers) == 0 { - err = fmt.Errorf("could not find controller for pod %s in namespace %s with labels: %v", pod.Name, pod.Namespace, pod.Labels) - } - return -} - -// StoreToServiceAccountLister helps list service accounts -type StoreToServiceAccountLister struct { - Indexer Indexer -} - -func (s *StoreToServiceAccountLister) List(selector labels.Selector) (ret []*api.ServiceAccount, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.ServiceAccount)) - }) - return ret, err -} - -func (s *StoreToServiceAccountLister) ServiceAccounts(namespace string) storeServiceAccountsNamespacer { - return storeServiceAccountsNamespacer{s.Indexer, namespace} -} - -type storeServiceAccountsNamespacer struct { - indexer Indexer - namespace string -} - -func (s storeServiceAccountsNamespacer) List(selector labels.Selector) (ret []*api.ServiceAccount, err error) { - err = ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*api.ServiceAccount)) - }) - return ret, err -} - -func (s storeServiceAccountsNamespacer) Get(name string) (*api.ServiceAccount, error) { - obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("serviceaccount"), name) - } - return obj.(*api.ServiceAccount), nil -} - -// StoreToLimitRangeLister helps list limit ranges -type StoreToLimitRangeLister struct { - Indexer Indexer -} - -func (s *StoreToLimitRangeLister) List(selector labels.Selector) (ret []*api.LimitRange, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.LimitRange)) - }) - return ret, err -} - -// StoreToPersistentVolumeClaimLister helps list pvcs -type StoreToPersistentVolumeClaimLister struct { - Indexer Indexer -} - -// List returns all persistentvolumeclaims that match the specified selector -func (s *StoreToPersistentVolumeClaimLister) List(selector labels.Selector) (ret []*api.PersistentVolumeClaim, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.PersistentVolumeClaim)) - }) - return ret, err -} - -func (s *StoreToLimitRangeLister) LimitRanges(namespace string) storeLimitRangesNamespacer { - return storeLimitRangesNamespacer{s.Indexer, namespace} -} - -type storeLimitRangesNamespacer struct { - indexer Indexer - namespace string -} - -func (s storeLimitRangesNamespacer) List(selector labels.Selector) (ret []*api.LimitRange, err error) { - err = ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*api.LimitRange)) - }) - return ret, err -} - -func (s storeLimitRangesNamespacer) Get(name string) (*api.LimitRange, error) { - obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("limitrange"), name) - } - return obj.(*api.LimitRange), nil -} - -// PersistentVolumeClaims returns all claims in a specified namespace. -func (s *StoreToPersistentVolumeClaimLister) PersistentVolumeClaims(namespace string) storePersistentVolumeClaimsNamespacer { - return storePersistentVolumeClaimsNamespacer{Indexer: s.Indexer, namespace: namespace} -} - -type storePersistentVolumeClaimsNamespacer struct { - Indexer Indexer - namespace string -} - -func (s storePersistentVolumeClaimsNamespacer) List(selector labels.Selector) (ret []*api.PersistentVolumeClaim, err error) { - err = ListAllByNamespace(s.Indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*api.PersistentVolumeClaim)) - }) - return ret, err -} - -func (s storePersistentVolumeClaimsNamespacer) Get(name string) (*api.PersistentVolumeClaim, error) { - obj, exists, err := s.Indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("persistentvolumeclaims"), name) - } - return obj.(*api.PersistentVolumeClaim), nil -} - -// IndexerToNamespaceLister gives an Indexer List method -type IndexerToNamespaceLister struct { - Indexer -} - -// List returns a list of namespaces -func (i *IndexerToNamespaceLister) List(selector labels.Selector) (ret []*api.Namespace, err error) { - err = ListAll(i.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*api.Namespace)) - }) - return ret, err -} - -func (i *IndexerToNamespaceLister) Get(name string) (*api.Namespace, error) { - obj, exists, err := i.Indexer.GetByKey(name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(api.Resource("namespace"), name) - } - return obj.(*api.Namespace), nil -} diff --git a/vendor/k8s.io/client-go/tools/cache/listers_extensions.go b/vendor/k8s.io/client-go/tools/cache/listers_extensions.go deleted file mode 100644 index 7281df9e35..0000000000 --- a/vendor/k8s.io/client-go/tools/cache/listers_extensions.go +++ /dev/null @@ -1,210 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package cache - -import ( - "fmt" - - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/apis/extensions" - "k8s.io/client-go/pkg/labels" -) - -// TODO: generate these classes and methods for all resources of interest using -// a script. Can use "go generate" once 1.4 is supported by all users. - -// Lister makes an Index have the List method. The Stores must contain only the expected type -// Example: -// s := cache.NewStore() -// lw := cache.ListWatch{Client: c, FieldSelector: sel, Resource: "pods"} -// r := cache.NewReflector(lw, &extensions.Deployment{}, s).Run() -// l := StoreToDeploymentLister{s} -// l.List() - -// StoreToDeploymentLister helps list deployments -type StoreToDeploymentLister struct { - Indexer Indexer -} - -func (s *StoreToDeploymentLister) List(selector labels.Selector) (ret []*extensions.Deployment, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*extensions.Deployment)) - }) - return ret, err -} - -func (s *StoreToDeploymentLister) Deployments(namespace string) storeDeploymentsNamespacer { - return storeDeploymentsNamespacer{Indexer: s.Indexer, namespace: namespace} -} - -type storeDeploymentsNamespacer struct { - Indexer Indexer - namespace string -} - -func (s storeDeploymentsNamespacer) List(selector labels.Selector) (ret []*extensions.Deployment, err error) { - err = ListAllByNamespace(s.Indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*extensions.Deployment)) - }) - return ret, err -} - -func (s storeDeploymentsNamespacer) Get(name string) (*extensions.Deployment, error) { - obj, exists, err := s.Indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(extensions.Resource("deployment"), name) - } - return obj.(*extensions.Deployment), nil -} - -// GetDeploymentsForReplicaSet returns a list of deployments managing a replica set. Returns an error only if no matching deployments are found. -func (s *StoreToDeploymentLister) GetDeploymentsForReplicaSet(rs *extensions.ReplicaSet) (deployments []*extensions.Deployment, err error) { - if len(rs.Labels) == 0 { - err = fmt.Errorf("no deployments found for ReplicaSet %v because it has no labels", rs.Name) - return - } - - // TODO: MODIFY THIS METHOD so that it checks for the podTemplateSpecHash label - dList, err := s.Deployments(rs.Namespace).List(labels.Everything()) - if err != nil { - return - } - for _, d := range dList { - selector, err := unversioned.LabelSelectorAsSelector(d.Spec.Selector) - if err != nil { - return nil, fmt.Errorf("invalid label selector: %v", err) - } - // If a deployment with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(rs.Labels)) { - continue - } - deployments = append(deployments, d) - } - if len(deployments) == 0 { - err = fmt.Errorf("could not find deployments set for ReplicaSet %s in namespace %s with labels: %v", rs.Name, rs.Namespace, rs.Labels) - } - return -} - -// GetDeploymentsForDeployments returns a list of deployments managing a pod. Returns an error only if no matching deployments are found. -// TODO eliminate shallow copies -func (s *StoreToDeploymentLister) GetDeploymentsForPod(pod *api.Pod) (deployments []*extensions.Deployment, err error) { - if len(pod.Labels) == 0 { - err = fmt.Errorf("no deployments found for Pod %v because it has no labels", pod.Name) - return - } - - if len(pod.Labels[extensions.DefaultDeploymentUniqueLabelKey]) == 0 { - return - } - - dList, err := s.Deployments(pod.Namespace).List(labels.Everything()) - if err != nil { - return - } - for _, d := range dList { - selector, err := unversioned.LabelSelectorAsSelector(d.Spec.Selector) - if err != nil { - return nil, fmt.Errorf("invalid label selector: %v", err) - } - // If a deployment with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(pod.Labels)) { - continue - } - deployments = append(deployments, d) - } - if len(deployments) == 0 { - err = fmt.Errorf("could not find deployments set for Pod %s in namespace %s with labels: %v", pod.Name, pod.Namespace, pod.Labels) - } - return -} - -// StoreToReplicaSetLister helps list replicasets -type StoreToReplicaSetLister struct { - Indexer Indexer -} - -func (s *StoreToReplicaSetLister) List(selector labels.Selector) (ret []*extensions.ReplicaSet, err error) { - err = ListAll(s.Indexer, selector, func(m interface{}) { - ret = append(ret, m.(*extensions.ReplicaSet)) - }) - return ret, err -} - -func (s *StoreToReplicaSetLister) ReplicaSets(namespace string) storeReplicaSetsNamespacer { - return storeReplicaSetsNamespacer{Indexer: s.Indexer, namespace: namespace} -} - -type storeReplicaSetsNamespacer struct { - Indexer Indexer - namespace string -} - -func (s storeReplicaSetsNamespacer) List(selector labels.Selector) (ret []*extensions.ReplicaSet, err error) { - err = ListAllByNamespace(s.Indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*extensions.ReplicaSet)) - }) - return ret, err -} - -func (s storeReplicaSetsNamespacer) Get(name string) (*extensions.ReplicaSet, error) { - obj, exists, err := s.Indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(extensions.Resource("replicaset"), name) - } - return obj.(*extensions.ReplicaSet), nil -} - -// GetPodReplicaSets returns a list of ReplicaSets managing a pod. Returns an error only if no matching ReplicaSets are found. -func (s *StoreToReplicaSetLister) GetPodReplicaSets(pod *api.Pod) (rss []*extensions.ReplicaSet, err error) { - if len(pod.Labels) == 0 { - err = fmt.Errorf("no ReplicaSets found for pod %v because it has no labels", pod.Name) - return - } - - list, err := s.ReplicaSets(pod.Namespace).List(labels.Everything()) - if err != nil { - return - } - for _, rs := range list { - if rs.Namespace != pod.Namespace { - continue - } - selector, err := unversioned.LabelSelectorAsSelector(rs.Spec.Selector) - if err != nil { - return nil, fmt.Errorf("invalid selector: %v", err) - } - - // If a ReplicaSet with a nil or empty selector creeps in, it should match nothing, not everything. - if selector.Empty() || !selector.Matches(labels.Set(pod.Labels)) { - continue - } - rss = append(rss, rs) - } - if len(rss) == 0 { - err = fmt.Errorf("could not find ReplicaSet for pod %s in namespace %s with labels: %v", pod.Name, pod.Namespace, pod.Labels) - } - return -} diff --git a/vendor/k8s.io/client-go/tools/cache/listers_rbac.go b/vendor/k8s.io/client-go/tools/cache/listers_rbac.go deleted file mode 100644 index fb9906f19e..0000000000 --- a/vendor/k8s.io/client-go/tools/cache/listers_rbac.go +++ /dev/null @@ -1,234 +0,0 @@ -/* -Copyright 2016 The Kubernetes Authors. - -Licensed under the Apache License, Version 2.0 (the "License"); -you may not use this file except in compliance with the License. -You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - -Unless required by applicable law or agreed to in writing, software -distributed under the License is distributed on an "AS IS" BASIS, -WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -See the License for the specific language governing permissions and -limitations under the License. -*/ - -package cache - -import ( - "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/apis/rbac" - "k8s.io/client-go/pkg/labels" -) - -// TODO: generate these classes and methods for all resources of interest using -// a script. Can use "go generate" once 1.4 is supported by all users. - -// Lister makes an Index have the List method. The Stores must contain only the expected type -// Example: -// s := cache.NewStore() -// lw := cache.ListWatch{Client: c, FieldSelector: sel, Resource: "pods"} -// r := cache.NewReflector(lw, &rbac.ClusterRole{}, s).Run() -// l := clusterRoleLister{s} -// l.List() - -func NewClusterRoleLister(indexer Indexer) ClusterRoleLister { - return &clusterRoleLister{indexer: indexer} -} -func NewClusterRoleBindingLister(indexer Indexer) ClusterRoleBindingLister { - return &clusterRoleBindingLister{indexer: indexer} -} -func NewRoleLister(indexer Indexer) RoleLister { - return &roleLister{indexer: indexer} -} -func NewRoleBindingLister(indexer Indexer) RoleBindingLister { - return &roleBindingLister{indexer: indexer} -} - -// these interfaces are used by the rbac authorizer -type authorizerClusterRoleGetter interface { - GetClusterRole(name string) (*rbac.ClusterRole, error) -} - -type authorizerClusterRoleBindingLister interface { - ListClusterRoleBindings() ([]*rbac.ClusterRoleBinding, error) -} - -type authorizerRoleGetter interface { - GetRole(namespace, name string) (*rbac.Role, error) -} - -type authorizerRoleBindingLister interface { - ListRoleBindings(namespace string) ([]*rbac.RoleBinding, error) -} - -type ClusterRoleLister interface { - authorizerClusterRoleGetter - List(selector labels.Selector) (ret []*rbac.ClusterRole, err error) - Get(name string) (*rbac.ClusterRole, error) -} - -type clusterRoleLister struct { - indexer Indexer -} - -func (s *clusterRoleLister) List(selector labels.Selector) (ret []*rbac.ClusterRole, err error) { - err = ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*rbac.ClusterRole)) - }) - return ret, err -} - -func (s clusterRoleLister) Get(name string) (*rbac.ClusterRole, error) { - obj, exists, err := s.indexer.GetByKey(name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(rbac.Resource("clusterrole"), name) - } - return obj.(*rbac.ClusterRole), nil -} - -func (s clusterRoleLister) GetClusterRole(name string) (*rbac.ClusterRole, error) { - return s.Get(name) -} - -type ClusterRoleBindingLister interface { - authorizerClusterRoleBindingLister - List(selector labels.Selector) (ret []*rbac.ClusterRoleBinding, err error) - Get(name string) (*rbac.ClusterRoleBinding, error) -} - -type clusterRoleBindingLister struct { - indexer Indexer -} - -func (s *clusterRoleBindingLister) List(selector labels.Selector) (ret []*rbac.ClusterRoleBinding, err error) { - err = ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*rbac.ClusterRoleBinding)) - }) - return ret, err -} - -func (s clusterRoleBindingLister) Get(name string) (*rbac.ClusterRoleBinding, error) { - obj, exists, err := s.indexer.GetByKey(name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(rbac.Resource("clusterrolebinding"), name) - } - return obj.(*rbac.ClusterRoleBinding), nil -} - -func (s clusterRoleBindingLister) ListClusterRoleBindings() ([]*rbac.ClusterRoleBinding, error) { - return s.List(labels.Everything()) -} - -type RoleLister interface { - authorizerRoleGetter - List(selector labels.Selector) (ret []*rbac.Role, err error) - Roles(namespace string) RoleNamespaceLister -} - -type RoleNamespaceLister interface { - List(selector labels.Selector) (ret []*rbac.Role, err error) - Get(name string) (*rbac.Role, error) -} - -type roleLister struct { - indexer Indexer -} - -func (s *roleLister) List(selector labels.Selector) (ret []*rbac.Role, err error) { - err = ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*rbac.Role)) - }) - return ret, err -} - -func (s *roleLister) Roles(namespace string) RoleNamespaceLister { - return roleNamespaceLister{indexer: s.indexer, namespace: namespace} -} - -func (s roleLister) GetRole(namespace, name string) (*rbac.Role, error) { - return s.Roles(namespace).Get(name) -} - -type roleNamespaceLister struct { - indexer Indexer - namespace string -} - -func (s roleNamespaceLister) List(selector labels.Selector) (ret []*rbac.Role, err error) { - err = ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*rbac.Role)) - }) - return ret, err -} - -func (s roleNamespaceLister) Get(name string) (*rbac.Role, error) { - obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(rbac.Resource("role"), name) - } - return obj.(*rbac.Role), nil -} - -type RoleBindingLister interface { - authorizerRoleBindingLister - List(selector labels.Selector) (ret []*rbac.RoleBinding, err error) - RoleBindings(namespace string) RoleBindingNamespaceLister -} - -type RoleBindingNamespaceLister interface { - List(selector labels.Selector) (ret []*rbac.RoleBinding, err error) - Get(name string) (*rbac.RoleBinding, error) -} - -type roleBindingLister struct { - indexer Indexer -} - -func (s *roleBindingLister) List(selector labels.Selector) (ret []*rbac.RoleBinding, err error) { - err = ListAll(s.indexer, selector, func(m interface{}) { - ret = append(ret, m.(*rbac.RoleBinding)) - }) - return ret, err -} - -func (s *roleBindingLister) RoleBindings(namespace string) RoleBindingNamespaceLister { - return roleBindingNamespaceLister{indexer: s.indexer, namespace: namespace} -} - -func (s roleBindingLister) ListRoleBindings(namespace string) ([]*rbac.RoleBinding, error) { - return s.RoleBindings(namespace).List(labels.Everything()) -} - -type roleBindingNamespaceLister struct { - indexer Indexer - namespace string -} - -func (s roleBindingNamespaceLister) List(selector labels.Selector) (ret []*rbac.RoleBinding, err error) { - err = ListAllByNamespace(s.indexer, s.namespace, selector, func(m interface{}) { - ret = append(ret, m.(*rbac.RoleBinding)) - }) - return ret, err -} - -func (s roleBindingNamespaceLister) Get(name string) (*rbac.RoleBinding, error) { - obj, exists, err := s.indexer.GetByKey(s.namespace + "/" + name) - if err != nil { - return nil, err - } - if !exists { - return nil, errors.NewNotFound(rbac.Resource("rolebinding"), name) - } - return obj.(*rbac.RoleBinding), nil -} diff --git a/vendor/k8s.io/client-go/tools/cache/listwatch.go b/vendor/k8s.io/client-go/tools/cache/listwatch.go index d3c7d67dba..af01d47457 100644 --- a/vendor/k8s.io/client-go/tools/cache/listwatch.go +++ b/vendor/k8s.io/client-go/tools/cache/listwatch.go @@ -19,28 +19,28 @@ package cache import ( "time" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/fields" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/watch" - "k8s.io/client-go/rest" + "k8s.io/apimachinery/pkg/api/meta" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/fields" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/watch" + restclient "k8s.io/client-go/rest" ) // ListerWatcher is any object that knows how to perform an initial list and start a watch on a resource. type ListerWatcher interface { // List should return a list type object; the Items field will be extracted, and the // ResourceVersion field will be used to start the watch in the right place. - List(options api.ListOptions) (runtime.Object, error) + List(options metav1.ListOptions) (runtime.Object, error) // Watch should begin a watch at the specified version. - Watch(options api.ListOptions) (watch.Interface, error) + Watch(options metav1.ListOptions) (watch.Interface, error) } // ListFunc knows how to list resources -type ListFunc func(options api.ListOptions) (runtime.Object, error) +type ListFunc func(options metav1.ListOptions) (runtime.Object, error) // WatchFunc knows how to watch resources -type WatchFunc func(options api.ListOptions) (watch.Interface, error) +type WatchFunc func(options metav1.ListOptions) (watch.Interface, error) // ListWatch knows how to list and watch a set of apiserver resources. It satisfies the ListerWatcher interface. // It is a convenience function for users of NewReflector, etc. @@ -52,33 +52,33 @@ type ListWatch struct { // Getter interface knows how to access Get method from RESTClient. type Getter interface { - Get() *rest.Request + Get() *restclient.Request } // NewListWatchFromClient creates a new ListWatch from the specified client, resource, namespace and field selector. func NewListWatchFromClient(c Getter, resource string, namespace string, fieldSelector fields.Selector) *ListWatch { - listFunc := func(options api.ListOptions) (runtime.Object, error) { + listFunc := func(options metav1.ListOptions) (runtime.Object, error) { return c.Get(). Namespace(namespace). Resource(resource). - VersionedParams(&options, api.ParameterCodec). + VersionedParams(&options, metav1.ParameterCodec). FieldsSelectorParam(fieldSelector). Do(). Get() } - watchFunc := func(options api.ListOptions) (watch.Interface, error) { + watchFunc := func(options metav1.ListOptions) (watch.Interface, error) { + options.Watch = true return c.Get(). - Prefix("watch"). Namespace(namespace). Resource(resource). - VersionedParams(&options, api.ParameterCodec). + VersionedParams(&options, metav1.ParameterCodec). FieldsSelectorParam(fieldSelector). Watch() } return &ListWatch{ListFunc: listFunc, WatchFunc: watchFunc} } -func timeoutFromListOptions(options api.ListOptions) time.Duration { +func timeoutFromListOptions(options metav1.ListOptions) time.Duration { if options.TimeoutSeconds != nil { return time.Duration(*options.TimeoutSeconds) * time.Second } @@ -86,12 +86,12 @@ func timeoutFromListOptions(options api.ListOptions) time.Duration { } // List a set of apiserver resources -func (lw *ListWatch) List(options api.ListOptions) (runtime.Object, error) { +func (lw *ListWatch) List(options metav1.ListOptions) (runtime.Object, error) { return lw.ListFunc(options) } // Watch a set of apiserver resources -func (lw *ListWatch) Watch(options api.ListOptions) (watch.Interface, error) { +func (lw *ListWatch) Watch(options metav1.ListOptions) (watch.Interface, error) { return lw.WatchFunc(options) } @@ -101,7 +101,7 @@ func ListWatchUntil(timeout time.Duration, lw ListerWatcher, conditions ...watch return nil, nil } - list, err := lw.List(api.ListOptions{}) + list, err := lw.List(metav1.ListOptions{}) if err != nil { return nil, err } @@ -153,7 +153,7 @@ func ListWatchUntil(timeout time.Duration, lw ListerWatcher, conditions ...watch } currResourceVersion := metaObj.GetResourceVersion() - watchInterface, err := lw.Watch(api.ListOptions{ResourceVersion: currResourceVersion}) + watchInterface, err := lw.Watch(metav1.ListOptions{ResourceVersion: currResourceVersion}) if err != nil { return nil, err } diff --git a/vendor/k8s.io/client-go/tools/cache/mutation_cache.go b/vendor/k8s.io/client-go/tools/cache/mutation_cache.go new file mode 100644 index 0000000000..0fa06bf77d --- /dev/null +++ b/vendor/k8s.io/client-go/tools/cache/mutation_cache.go @@ -0,0 +1,261 @@ +/* +Copyright 2017 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package cache + +import ( + "fmt" + "strconv" + "sync" + "time" + + "github.com/golang/glog" + + "k8s.io/apimachinery/pkg/api/meta" + "k8s.io/apimachinery/pkg/runtime" + utilcache "k8s.io/apimachinery/pkg/util/cache" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + "k8s.io/apimachinery/pkg/util/sets" +) + +// MutationCache is able to take the result of update operations and stores them in an LRU +// that can be used to provide a more current view of a requested object. It requires interpreting +// resourceVersions for comparisons. +// Implementations must be thread-safe. +// TODO find a way to layer this into an informer/lister +type MutationCache interface { + GetByKey(key string) (interface{}, bool, error) + ByIndex(indexName, indexKey string) ([]interface{}, error) + Mutation(interface{}) +} + +type ResourceVersionComparator interface { + CompareResourceVersion(lhs, rhs runtime.Object) int +} + +// NewIntegerResourceVersionMutationCache returns a MutationCache that understands how to +// deal with objects that have a resource version that: +// +// - is an integer +// - increases when updated +// - is comparable across the same resource in a namespace +// +// Most backends will have these semantics. Indexer may be nil. ttl controls how long an item +// remains in the mutation cache before it is removed. +// +// If includeAdds is true, objects in the mutation cache will be returned even if they don't exist +// in the underlying store. This is only safe if your use of the cache can handle mutation entries +// remaining in the cache for up to ttl when mutations and deletes occur very closely in time. +func NewIntegerResourceVersionMutationCache(backingCache Store, indexer Indexer, ttl time.Duration, includeAdds bool) MutationCache { + return &mutationCache{ + backingCache: backingCache, + indexer: indexer, + mutationCache: utilcache.NewLRUExpireCache(100), + comparator: etcdObjectVersioner{}, + ttl: ttl, + includeAdds: includeAdds, + } +} + +// mutationCache doesn't guarantee that it returns values added via Mutation since they can page out and +// since you can't distinguish between, "didn't observe create" and "was deleted after create", +// if the key is missing from the backing cache, we always return it as missing +type mutationCache struct { + lock sync.Mutex + backingCache Store + indexer Indexer + mutationCache *utilcache.LRUExpireCache + includeAdds bool + ttl time.Duration + + comparator ResourceVersionComparator +} + +// GetByKey is never guaranteed to return back the value set in Mutation. It could be paged out, it could +// be older than another copy, the backingCache may be more recent or, you might have written twice into the same key. +// You get a value that was valid at some snapshot of time and will always return the newer of backingCache and mutationCache. +func (c *mutationCache) GetByKey(key string) (interface{}, bool, error) { + c.lock.Lock() + defer c.lock.Unlock() + + obj, exists, err := c.backingCache.GetByKey(key) + if err != nil { + return nil, false, err + } + if !exists { + if !c.includeAdds { + // we can't distinguish between, "didn't observe create" and "was deleted after create", so + // if the key is missing, we always return it as missing + return nil, false, nil + } + obj, exists = c.mutationCache.Get(key) + if !exists { + return nil, false, nil + } + } + objRuntime, ok := obj.(runtime.Object) + if !ok { + return obj, true, nil + } + return c.newerObject(key, objRuntime), true, nil +} + +// ByIndex returns the newer objects that match the provided index and indexer key. +// Will return an error if no indexer was provided. +func (c *mutationCache) ByIndex(name string, indexKey string) ([]interface{}, error) { + c.lock.Lock() + defer c.lock.Unlock() + if c.indexer == nil { + return nil, fmt.Errorf("no indexer has been provided to the mutation cache") + } + keys, err := c.indexer.IndexKeys(name, indexKey) + if err != nil { + return nil, err + } + var items []interface{} + keySet := sets.NewString() + for _, key := range keys { + keySet.Insert(key) + obj, exists, err := c.indexer.GetByKey(key) + if err != nil { + return nil, err + } + if !exists { + continue + } + if objRuntime, ok := obj.(runtime.Object); ok { + items = append(items, c.newerObject(key, objRuntime)) + } else { + items = append(items, obj) + } + } + + if c.includeAdds { + fn := c.indexer.GetIndexers()[name] + // Keys() is returned oldest to newest, so full traversal does not alter the LRU behavior + for _, key := range c.mutationCache.Keys() { + updated, ok := c.mutationCache.Get(key) + if !ok { + continue + } + if keySet.Has(key.(string)) { + continue + } + elements, err := fn(updated) + if err != nil { + glog.V(4).Info("Unable to calculate an index entry for mutation cache entry %s: %v", key, err) + continue + } + for _, inIndex := range elements { + if inIndex != indexKey { + continue + } + items = append(items, updated) + break + } + } + } + + return items, nil +} + +// newerObject checks the mutation cache for a newer object and returns one if found. If the +// mutated object is older than the backing object, it is removed from the Must be +// called while the lock is held. +func (c *mutationCache) newerObject(key string, backing runtime.Object) runtime.Object { + mutatedObj, exists := c.mutationCache.Get(key) + if !exists { + return backing + } + mutatedObjRuntime, ok := mutatedObj.(runtime.Object) + if !ok { + return backing + } + if c.comparator.CompareResourceVersion(backing, mutatedObjRuntime) >= 0 { + c.mutationCache.Remove(key) + return backing + } + return mutatedObjRuntime +} + +// Mutation adds a change to the cache that can be returned in GetByKey if it is newer than the backingCache +// copy. If you call Mutation twice with the same object on different threads, one will win, but its not defined +// which one. This doesn't affect correctness, since the GetByKey guaranteed of "later of these two caches" is +// preserved, but you may not get the version of the object you want. The object you get is only guaranteed to +// "one that was valid at some point in time", not "the one that I want". +func (c *mutationCache) Mutation(obj interface{}) { + c.lock.Lock() + defer c.lock.Unlock() + + key, err := DeletionHandlingMetaNamespaceKeyFunc(obj) + if err != nil { + // this is a "nice to have", so failures shouldn't do anything weird + utilruntime.HandleError(err) + return + } + + if objRuntime, ok := obj.(runtime.Object); ok { + if mutatedObj, exists := c.mutationCache.Get(key); exists { + if mutatedObjRuntime, ok := mutatedObj.(runtime.Object); ok { + if c.comparator.CompareResourceVersion(objRuntime, mutatedObjRuntime) < 0 { + return + } + } + } + } + c.mutationCache.Add(key, obj, c.ttl) +} + +// etcdObjectVersioner implements versioning and extracting etcd node information +// for objects that have an embedded ObjectMeta or ListMeta field. +type etcdObjectVersioner struct{} + +// ObjectResourceVersion implements Versioner +func (a etcdObjectVersioner) ObjectResourceVersion(obj runtime.Object) (uint64, error) { + accessor, err := meta.Accessor(obj) + if err != nil { + return 0, err + } + version := accessor.GetResourceVersion() + if len(version) == 0 { + return 0, nil + } + return strconv.ParseUint(version, 10, 64) +} + +// CompareResourceVersion compares etcd resource versions. Outside this API they are all strings, +// but etcd resource versions are special, they're actually ints, so we can easily compare them. +func (a etcdObjectVersioner) CompareResourceVersion(lhs, rhs runtime.Object) int { + lhsVersion, err := a.ObjectResourceVersion(lhs) + if err != nil { + // coder error + panic(err) + } + rhsVersion, err := a.ObjectResourceVersion(rhs) + if err != nil { + // coder error + panic(err) + } + + if lhsVersion == rhsVersion { + return 0 + } + if lhsVersion < rhsVersion { + return -1 + } + + return 1 +} diff --git a/vendor/k8s.io/client-go/tools/cache/mutation_detector.go b/vendor/k8s.io/client-go/tools/cache/mutation_detector.go index e27e339e02..cc6094ce4e 100644 --- a/vendor/k8s.io/client-go/tools/cache/mutation_detector.go +++ b/vendor/k8s.io/client-go/tools/cache/mutation_detector.go @@ -24,9 +24,9 @@ import ( "sync" "time" - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/util/diff" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/diff" + "k8s.io/client-go/kubernetes/scheme" ) var mutationDetectionEnabled = false @@ -102,7 +102,7 @@ func (d *defaultCacheMutationDetector) AddObject(obj interface{}) { return } - copiedObj, err := api.Scheme.Copy(obj.(runtime.Object)) + copiedObj, err := scheme.Scheme.Copy(obj.(runtime.Object)) if err != nil { return } diff --git a/vendor/k8s.io/client-go/tools/cache/reflector.go b/vendor/k8s.io/client-go/tools/cache/reflector.go index 55da33ee89..9a730610c6 100644 --- a/vendor/k8s.io/client-go/tools/cache/reflector.go +++ b/vendor/k8s.io/client-go/tools/cache/reflector.go @@ -34,13 +34,14 @@ import ( "time" "github.com/golang/glog" - "k8s.io/client-go/pkg/api" - apierrs "k8s.io/client-go/pkg/api/errors" - "k8s.io/client-go/pkg/api/meta" - "k8s.io/client-go/pkg/runtime" - utilruntime "k8s.io/client-go/pkg/util/runtime" - "k8s.io/client-go/pkg/util/wait" - "k8s.io/client-go/pkg/watch" + apierrs "k8s.io/apimachinery/pkg/api/errors" + "k8s.io/apimachinery/pkg/api/meta" + metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/clock" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + "k8s.io/apimachinery/pkg/util/wait" + "k8s.io/apimachinery/pkg/watch" ) // Reflector watches a specified resource and causes all changes to be reflected in the given store. @@ -58,8 +59,9 @@ type Reflector struct { // the beginning of the next one. period time.Duration resyncPeriod time.Duration - // now() returns current time - exposed for testing purposes - now func() time.Time + ShouldResync func() bool + // clock allows tests to manipulate time + clock clock.Clock // lastSyncResourceVersion is the resource version token last // observed when doing a sync with the underlying store // it is thread safe, but not synchronized with the underlying store @@ -103,14 +105,14 @@ func NewNamedReflector(name string, lw ListerWatcher, expectedType interface{}, expectedType: reflect.TypeOf(expectedType), period: time.Second, resyncPeriod: resyncPeriod, - now: time.Now, + clock: &clock.RealClock{}, } return r } // internalPackages are packages that ignored when creating a default reflector name. These packages are in the common // call chains to NewReflector, so they'd be low entropy names for reflectors -var internalPackages = []string{"kubernetes/pkg/client/cache/", "/runtime/asm_"} +var internalPackages = []string{"client-go/tools/cache/", "/runtime/asm_"} // getDefaultReflectorName walks back through the call stack until we find a caller from outside of the ignoredPackages // it returns back a shortpath/filename:line to aid in identification of this reflector when it starts logging @@ -223,8 +225,8 @@ func (r *Reflector) resyncChan() (<-chan time.Time, func() bool) { // always fail so we end up listing frequently. Then, if we don't // manually stop the timer, we could end up with many timers active // concurrently. - t := time.NewTimer(r.resyncPeriod) - return t.C, t.Stop + t := r.clock.NewTimer(r.resyncPeriod) + return t.C(), t.Stop } // ListAndWatch first lists all items and get the resource version at the moment of call, @@ -239,7 +241,7 @@ func (r *Reflector) ListAndWatch(stopCh <-chan struct{}) error { // Explicitly set "0" as resource version - it's fine for the List() // to be served from cache and potentially be delayed relative to // etcd contents. Reflector framework will catch up via Watch() eventually. - options := api.ListOptions{ResourceVersion: "0"} + options := metav1.ListOptions{ResourceVersion: "0"} list, err := r.listerWatcher.List(options) if err != nil { return fmt.Errorf("%s: Failed to list %v: %v", r.name, r.expectedType, err) @@ -259,18 +261,24 @@ func (r *Reflector) ListAndWatch(stopCh <-chan struct{}) error { r.setLastSyncResourceVersion(resourceVersion) resyncerrc := make(chan error, 1) + cancelCh := make(chan struct{}) + defer close(cancelCh) go func() { for { select { case <-resyncCh: case <-stopCh: return - } - glog.V(4).Infof("%s: forcing resync", r.name) - if err := r.store.Resync(); err != nil { - resyncerrc <- err + case <-cancelCh: return } + if r.ShouldResync == nil || r.ShouldResync() { + glog.V(4).Infof("%s: forcing resync", r.name) + if err := r.store.Resync(); err != nil { + resyncerrc <- err + return + } + } cleanup() resyncCh, cleanup = r.resyncChan() } @@ -278,7 +286,7 @@ func (r *Reflector) ListAndWatch(stopCh <-chan struct{}) error { for { timemoutseconds := int64(minWatchTimeout.Seconds() * (rand.Float64() + 1.0)) - options = api.ListOptions{ + options = metav1.ListOptions{ ResourceVersion: resourceVersion, // We want to avoid situations of hanging watchers. Stop any wachers that do not // receive any events within the timeout window. @@ -330,7 +338,7 @@ func (r *Reflector) syncWith(items []runtime.Object, resourceVersion string) err // watchHandler watches w and keeps *resourceVersion up to date. func (r *Reflector) watchHandler(w watch.Interface, resourceVersion *string, errc chan error, stopCh <-chan struct{}) error { - start := time.Now() + start := r.clock.Now() eventCount := 0 // Stopping the watcher should be idempotent and if we return from this function there's no way @@ -363,14 +371,23 @@ loop: newResourceVersion := meta.GetResourceVersion() switch event.Type { case watch.Added: - r.store.Add(event.Object) + err := r.store.Add(event.Object) + if err != nil { + utilruntime.HandleError(fmt.Errorf("%s: unable to add watch event object (%#v) to store: %v", r.name, event.Object, err)) + } case watch.Modified: - r.store.Update(event.Object) + err := r.store.Update(event.Object) + if err != nil { + utilruntime.HandleError(fmt.Errorf("%s: unable to update watch event object (%#v) to store: %v", r.name, event.Object, err)) + } case watch.Deleted: // TODO: Will any consumers need access to the "last known // state", which is passed in event.Object? If so, may need // to change this. - r.store.Delete(event.Object) + err := r.store.Delete(event.Object) + if err != nil { + utilruntime.HandleError(fmt.Errorf("%s: unable to delete watch event object (%#v) from store: %v", r.name, event.Object, err)) + } default: utilruntime.HandleError(fmt.Errorf("%s: unable to understand watch event %#v", r.name, event)) } @@ -380,7 +397,7 @@ loop: } } - watchDuration := time.Now().Sub(start) + watchDuration := r.clock.Now().Sub(start) if watchDuration < 1*time.Second && eventCount == 0 { glog.V(4).Infof("%s: Unexpected watch close - watch lasted less than a second and no items received", r.name) return errors.New("very short watch") diff --git a/vendor/k8s.io/client-go/tools/cache/shared_informer.go b/vendor/k8s.io/client-go/tools/cache/shared_informer.go index 7687bca476..a0dbbb697b 100644 --- a/vendor/k8s.io/client-go/tools/cache/shared_informer.go +++ b/vendor/k8s.io/client-go/tools/cache/shared_informer.go @@ -21,31 +21,43 @@ import ( "sync" "time" - "k8s.io/client-go/pkg/runtime" - utilruntime "k8s.io/client-go/pkg/util/runtime" - "k8s.io/client-go/pkg/util/wait" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/util/clock" + utilruntime "k8s.io/apimachinery/pkg/util/runtime" + "k8s.io/apimachinery/pkg/util/wait" "github.com/golang/glog" ) -// if you use this, there is one behavior change compared to a standard Informer. -// When you receive a notification, the cache will be AT LEAST as fresh as the -// notification, but it MAY be more fresh. You should NOT depend on the contents -// of the cache exactly matching the notification you've received in handler -// functions. If there was a create, followed by a delete, the cache may NOT -// have your item. This has advantages over the broadcaster since it allows us -// to share a common cache across many controllers. Extending the broadcaster -// would have required us keep duplicate caches for each watch. +// SharedInformer has a shared data cache and is capable of distributing notifications for changes +// to the cache to multiple listeners who registered via AddEventHandler. If you use this, there is +// one behavior change compared to a standard Informer. When you receive a notification, the cache +// will be AT LEAST as fresh as the notification, but it MAY be more fresh. You should NOT depend +// on the contents of the cache exactly matching the notification you've received in handler +// functions. If there was a create, followed by a delete, the cache may NOT have your item. This +// has advantages over the broadcaster since it allows us to share a common cache across many +// controllers. Extending the broadcaster would have required us keep duplicate caches for each +// watch. type SharedInformer interface { - // events to a single handler are delivered sequentially, but there is no coordination between different handlers - // You may NOT add a handler *after* the SharedInformer is running. That will result in an error being returned. - // TODO we should try to remove this restriction eventually. - AddEventHandler(handler ResourceEventHandler) error + // AddEventHandler adds an event handler to the shared informer using the shared informer's resync + // period. Events to a single handler are delivered sequentially, but there is no coordination + // between different handlers. + AddEventHandler(handler ResourceEventHandler) + // AddEventHandlerWithResyncPeriod adds an event handler to the shared informer using the + // specified resync period. Events to a single handler are delivered sequentially, but there is + // no coordination between different handlers. + AddEventHandlerWithResyncPeriod(handler ResourceEventHandler, resyncPeriod time.Duration) + // GetStore returns the Store. GetStore() Store // GetController gives back a synthetic interface that "votes" to start the informer - GetController() ControllerInterface + GetController() Controller + // Run starts the shared informer, which will be stopped when stopCh is closed. Run(stopCh <-chan struct{}) + // HasSynced returns true if the shared informer's store has synced. HasSynced() bool + // LastSyncResourceVersion is the resource version observed when last synced with the underlying + // store. The value returned is not synchronized with access to the underlying store and is not + // thread-safe. LastSyncResourceVersion() string } @@ -57,23 +69,22 @@ type SharedIndexInformer interface { } // NewSharedInformer creates a new instance for the listwatcher. -// TODO: create a cache/factory of these at a higher level for the list all, watch all of a given resource that can -// be shared amongst all consumers. func NewSharedInformer(lw ListerWatcher, objType runtime.Object, resyncPeriod time.Duration) SharedInformer { return NewSharedIndexInformer(lw, objType, resyncPeriod, Indexers{}) } // NewSharedIndexInformer creates a new instance for the listwatcher. -// TODO: create a cache/factory of these at a higher level for the list all, watch all of a given resource that can -// be shared amongst all consumers. -func NewSharedIndexInformer(lw ListerWatcher, objType runtime.Object, resyncPeriod time.Duration, indexers Indexers) SharedIndexInformer { +func NewSharedIndexInformer(lw ListerWatcher, objType runtime.Object, defaultEventHandlerResyncPeriod time.Duration, indexers Indexers) SharedIndexInformer { + realClock := &clock.RealClock{} sharedIndexInformer := &sharedIndexInformer{ - processor: &sharedProcessor{}, - indexer: NewIndexer(DeletionHandlingMetaNamespaceKeyFunc, indexers), - listerWatcher: lw, - objectType: objType, - fullResyncPeriod: resyncPeriod, - cacheMutationDetector: NewCacheMutationDetector(fmt.Sprintf("%T", objType)), + processor: &sharedProcessor{clock: realClock}, + indexer: NewIndexer(DeletionHandlingMetaNamespaceKeyFunc, indexers), + listerWatcher: lw, + objectType: objType, + resyncCheckPeriod: defaultEventHandlerResyncPeriod, + defaultEventHandlerResyncPeriod: defaultEventHandlerResyncPeriod, + cacheMutationDetector: NewCacheMutationDetector(fmt.Sprintf("%T", objType)), + clock: realClock, } return sharedIndexInformer } @@ -85,7 +96,7 @@ type InformerSynced func() bool const syncedPollPeriod = 100 * time.Millisecond // WaitForCacheSync waits for caches to populate. It returns true if it was successful, false -// if the contoller should shutdown +// if the controller should shutdown func WaitForCacheSync(stopCh <-chan struct{}, cacheSyncs ...InformerSynced) bool { err := wait.PollUntil(syncedPollPeriod, func() (bool, error) { @@ -108,15 +119,24 @@ func WaitForCacheSync(stopCh <-chan struct{}, cacheSyncs ...InformerSynced) bool type sharedIndexInformer struct { indexer Indexer - controller *Controller + controller Controller processor *sharedProcessor cacheMutationDetector CacheMutationDetector // This block is tracked to handle late initialization of the controller - listerWatcher ListerWatcher - objectType runtime.Object - fullResyncPeriod time.Duration + listerWatcher ListerWatcher + objectType runtime.Object + + // resyncCheckPeriod is how often we want the reflector's resync timer to fire so it can call + // shouldResync to check if any of our listeners need a resync. + resyncCheckPeriod time.Duration + // defaultEventHandlerResyncPeriod is the default resync period for any handlers added via + // AddEventHandler (i.e. they don't specify one and just want to use the shared informer's default + // value). + defaultEventHandlerResyncPeriod time.Duration + // clock allows for testability + clock clock.Clock started bool startedLock sync.Mutex @@ -130,7 +150,7 @@ type sharedIndexInformer struct { } // dummyController hides the fact that a SharedInformer is different from a dedicated one -// where a caller can `Run`. The run method is disonnected in this case, because higher +// where a caller can `Run`. The run method is disconnected in this case, because higher // level logic will decide when to start the SharedInformer and related controller. // Because returning information back is always asynchronous, the legacy callers shouldn't // notice any change in behavior. @@ -145,6 +165,10 @@ func (v *dummyController) HasSynced() bool { return v.informer.HasSynced() } +func (c *dummyController) LastSyncResourceVersion() string { + return "" +} + type updateNotification struct { oldObj interface{} newObj interface{} @@ -167,8 +191,9 @@ func (s *sharedIndexInformer) Run(stopCh <-chan struct{}) { Queue: fifo, ListerWatcher: s.listerWatcher, ObjectType: s.objectType, - FullResyncPeriod: s.fullResyncPeriod, + FullResyncPeriod: s.resyncCheckPeriod, RetryOnError: false, + ShouldResync: s.processor.shouldResync, Process: s.HandleDeltas, } @@ -178,6 +203,7 @@ func (s *sharedIndexInformer) Run(stopCh <-chan struct{}) { defer s.startedLock.Unlock() s.controller = New(cfg) + s.controller.(*controller).clock = s.clock s.started = true }() @@ -207,10 +233,10 @@ func (s *sharedIndexInformer) LastSyncResourceVersion() string { s.startedLock.Lock() defer s.startedLock.Unlock() - if s.controller == nil || s.controller.reflector == nil { + if s.controller == nil { return "" } - return s.controller.reflector.LastSyncResourceVersion() + return s.controller.LastSyncResourceVersion() } func (s *sharedIndexInformer) GetStore() Store { @@ -232,18 +258,60 @@ func (s *sharedIndexInformer) AddIndexers(indexers Indexers) error { return s.indexer.AddIndexers(indexers) } -func (s *sharedIndexInformer) GetController() ControllerInterface { +func (s *sharedIndexInformer) GetController() Controller { return &dummyController{informer: s} } -func (s *sharedIndexInformer) AddEventHandler(handler ResourceEventHandler) error { +func (s *sharedIndexInformer) AddEventHandler(handler ResourceEventHandler) { + s.AddEventHandlerWithResyncPeriod(handler, s.defaultEventHandlerResyncPeriod) +} + +func determineResyncPeriod(desired, check time.Duration) time.Duration { + if desired == 0 { + return desired + } + if check == 0 { + glog.Warningf("The specified resyncPeriod %v is invalid because this shared informer doesn't support resyncing", desired) + return 0 + } + if desired < check { + glog.Warningf("The specified resyncPeriod %v is being increased to the minimum resyncCheckPeriod %v", desired, check) + return check + } + return desired +} + +const minimumResyncPeriod = 1 * time.Second + +func (s *sharedIndexInformer) AddEventHandlerWithResyncPeriod(handler ResourceEventHandler, resyncPeriod time.Duration) { s.startedLock.Lock() defer s.startedLock.Unlock() + if resyncPeriod > 0 { + if resyncPeriod < minimumResyncPeriod { + glog.Warningf("resyncPeriod %d is too small. Changing it to the minimum allowed value of %d", resyncPeriod, minimumResyncPeriod) + resyncPeriod = minimumResyncPeriod + } + + if resyncPeriod < s.resyncCheckPeriod { + if s.started { + glog.Warningf("resyncPeriod %d is smaller than resyncCheckPeriod %d and the informer has already started. Changing it to %d", resyncPeriod, s.resyncCheckPeriod, s.resyncCheckPeriod) + resyncPeriod = s.resyncCheckPeriod + } else { + // if the event handler's resyncPeriod is smaller than the current resyncCheckPeriod, update + // resyncCheckPeriod to match resyncPeriod and adjust the resync periods of all the listeners + // accordingly + s.resyncCheckPeriod = resyncPeriod + s.processor.resyncCheckPeriodChanged(resyncPeriod) + } + } + } + + listener := newProcessListener(handler, resyncPeriod, determineResyncPeriod(resyncPeriod, s.resyncCheckPeriod), s.clock.Now()) + if !s.started { - listener := newProcessListener(handler) - s.processor.listeners = append(s.processor.listeners, listener) - return nil + s.processor.addListener(listener) + return } // in order to safely join, we have to @@ -254,8 +322,7 @@ func (s *sharedIndexInformer) AddEventHandler(handler ResourceEventHandler) erro s.blockDeltas.Lock() defer s.blockDeltas.Unlock() - listener := newProcessListener(handler) - s.processor.listeners = append(s.processor.listeners, listener) + s.processor.addListener(listener) go listener.run(s.stopCh) go listener.pop(s.stopCh) @@ -264,8 +331,6 @@ func (s *sharedIndexInformer) AddEventHandler(handler ResourceEventHandler) erro for i := range items { listener.add(addNotification{newObj: items[i]}) } - - return nil } func (s *sharedIndexInformer) HandleDeltas(obj interface{}) error { @@ -276,45 +341,101 @@ func (s *sharedIndexInformer) HandleDeltas(obj interface{}) error { for _, d := range obj.(Deltas) { switch d.Type { case Sync, Added, Updated: + isSync := d.Type == Sync s.cacheMutationDetector.AddObject(d.Object) if old, exists, err := s.indexer.Get(d.Object); err == nil && exists { if err := s.indexer.Update(d.Object); err != nil { return err } - s.processor.distribute(updateNotification{oldObj: old, newObj: d.Object}) + s.processor.distribute(updateNotification{oldObj: old, newObj: d.Object}, isSync) } else { if err := s.indexer.Add(d.Object); err != nil { return err } - s.processor.distribute(addNotification{newObj: d.Object}) + s.processor.distribute(addNotification{newObj: d.Object}, isSync) } case Deleted: if err := s.indexer.Delete(d.Object); err != nil { return err } - s.processor.distribute(deleteNotification{oldObj: d.Object}) + s.processor.distribute(deleteNotification{oldObj: d.Object}, false) } } return nil } type sharedProcessor struct { - listeners []*processorListener + listenersLock sync.RWMutex + listeners []*processorListener + syncingListeners []*processorListener + clock clock.Clock } -func (p *sharedProcessor) distribute(obj interface{}) { - for _, listener := range p.listeners { - listener.add(obj) +func (p *sharedProcessor) addListener(listener *processorListener) { + p.listenersLock.Lock() + defer p.listenersLock.Unlock() + + p.listeners = append(p.listeners, listener) + p.syncingListeners = append(p.syncingListeners, listener) +} + +func (p *sharedProcessor) distribute(obj interface{}, sync bool) { + p.listenersLock.RLock() + defer p.listenersLock.RUnlock() + + if sync { + for _, listener := range p.syncingListeners { + listener.add(obj) + } + } else { + for _, listener := range p.listeners { + listener.add(obj) + } } } func (p *sharedProcessor) run(stopCh <-chan struct{}) { + p.listenersLock.RLock() + defer p.listenersLock.RUnlock() + for _, listener := range p.listeners { go listener.run(stopCh) go listener.pop(stopCh) } } +// shouldResync queries every listener to determine if any of them need a resync, based on each +// listener's resyncPeriod. +func (p *sharedProcessor) shouldResync() bool { + p.listenersLock.Lock() + defer p.listenersLock.Unlock() + + p.syncingListeners = []*processorListener{} + + resyncNeeded := false + now := p.clock.Now() + for _, listener := range p.listeners { + // need to loop through all the listeners to see if they need to resync so we can prepare any + // listeners that are going to be resyncing. + if listener.shouldResync(now) { + resyncNeeded = true + p.syncingListeners = append(p.syncingListeners, listener) + listener.determineNextResync(now) + } + } + return resyncNeeded +} + +func (p *sharedProcessor) resyncCheckPeriodChanged(resyncCheckPeriod time.Duration) { + p.listenersLock.RLock() + defer p.listenersLock.RUnlock() + + for _, listener := range p.listeners { + resyncPeriod := determineResyncPeriod(listener.requestedResyncPeriod, resyncCheckPeriod) + listener.setResyncPeriod(resyncPeriod) + } +} + type processorListener struct { // lock/cond protects access to 'pendingNotifications'. lock sync.RWMutex @@ -330,16 +451,32 @@ type processorListener struct { nextCh chan interface{} handler ResourceEventHandler + + // requestedResyncPeriod is how frequently the listener wants a full resync from the shared informer + requestedResyncPeriod time.Duration + // resyncPeriod is how frequently the listener wants a full resync from the shared informer. This + // value may differ from requestedResyncPeriod if the shared informer adjusts it to align with the + // informer's overall resync check period. + resyncPeriod time.Duration + // nextResync is the earliest time the listener should get a full resync + nextResync time.Time + // resyncLock guards access to resyncPeriod and nextResync + resyncLock sync.Mutex } -func newProcessListener(handler ResourceEventHandler) *processorListener { +func newProcessListener(handler ResourceEventHandler, requestedResyncPeriod, resyncPeriod time.Duration, now time.Time) *processorListener { ret := &processorListener{ - pendingNotifications: []interface{}{}, - nextCh: make(chan interface{}), - handler: handler, + pendingNotifications: []interface{}{}, + nextCh: make(chan interface{}), + handler: handler, + requestedResyncPeriod: requestedResyncPeriod, + resyncPeriod: resyncPeriod, } ret.cond.L = &ret.lock + + ret.determineNextResync(now) + return ret } @@ -415,3 +552,30 @@ func (p *processorListener) run(stopCh <-chan struct{}) { } } } + +// shouldResync deterimines if the listener needs a resync. If the listener's resyncPeriod is 0, +// this always returns false. +func (p *processorListener) shouldResync(now time.Time) bool { + p.resyncLock.Lock() + defer p.resyncLock.Unlock() + + if p.resyncPeriod == 0 { + return false + } + + return now.After(p.nextResync) || now.Equal(p.nextResync) +} + +func (p *processorListener) determineNextResync(now time.Time) { + p.resyncLock.Lock() + defer p.resyncLock.Unlock() + + p.nextResync = now.Add(p.resyncPeriod) +} + +func (p *processorListener) setResyncPeriod(resyncPeriod time.Duration) { + p.resyncLock.Lock() + defer p.resyncLock.Unlock() + + p.resyncPeriod = resyncPeriod +} diff --git a/vendor/k8s.io/client-go/tools/cache/store.go b/vendor/k8s.io/client-go/tools/cache/store.go index d8e65e495c..4958987f0e 100755 --- a/vendor/k8s.io/client-go/tools/cache/store.go +++ b/vendor/k8s.io/client-go/tools/cache/store.go @@ -20,7 +20,7 @@ import ( "fmt" "strings" - "k8s.io/client-go/pkg/api/meta" + "k8s.io/apimachinery/pkg/api/meta" ) // Store is a generic object storage interface. Reflector knows how to watch a server @@ -172,6 +172,10 @@ func (c *cache) Index(indexName string, obj interface{}) ([]interface{}, error) return c.cacheStorage.Index(indexName, obj) } +func (c *cache) IndexKeys(indexName, indexKey string) ([]string, error) { + return c.cacheStorage.IndexKeys(indexName, indexKey) +} + // ListIndexFuncValues returns the list of generated values of an Index func func (c *cache) ListIndexFuncValues(indexName string) []string { return c.cacheStorage.ListIndexFuncValues(indexName) diff --git a/vendor/k8s.io/client-go/tools/cache/thread_safe_store.go b/vendor/k8s.io/client-go/tools/cache/thread_safe_store.go index 1f5fb35436..4eb350c439 100644 --- a/vendor/k8s.io/client-go/tools/cache/thread_safe_store.go +++ b/vendor/k8s.io/client-go/tools/cache/thread_safe_store.go @@ -20,7 +20,7 @@ import ( "fmt" "sync" - "k8s.io/client-go/pkg/util/sets" + "k8s.io/apimachinery/pkg/util/sets" ) // ThreadSafeStore is an interface that allows concurrent access to a storage backend. @@ -43,6 +43,7 @@ type ThreadSafeStore interface { ListKeys() []string Replace(map[string]interface{}, string) Index(indexName string, obj interface{}) ([]interface{}, error) + IndexKeys(indexName, indexKey string) ([]string, error) ListIndexFuncValues(name string) []string ByIndex(indexName, indexKey string) ([]interface{}, error) GetIndexers() Indexers @@ -184,6 +185,23 @@ func (c *threadSafeMap) ByIndex(indexName, indexKey string) ([]interface{}, erro return list, nil } +// IndexKeys returns a list of keys that match on the index function. +// IndexKeys is thread-safe so long as you treat all items as immutable. +func (c *threadSafeMap) IndexKeys(indexName, indexKey string) ([]string, error) { + c.lock.RLock() + defer c.lock.RUnlock() + + indexFunc := c.indexers[indexName] + if indexFunc == nil { + return nil, fmt.Errorf("Index with name %s does not exist", indexName) + } + + index := c.indices[indexName] + + set := index[indexKey] + return set.List(), nil +} + func (c *threadSafeMap) ListIndexFuncValues(indexName string) []string { c.lock.RLock() defer c.lock.RUnlock() diff --git a/vendor/k8s.io/client-go/tools/clientcmd/BUILD b/vendor/k8s.io/client-go/tools/clientcmd/BUILD new file mode 100644 index 0000000000..59df4b0dc4 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/clientcmd/BUILD @@ -0,0 +1,62 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "client_config_test.go", + "loader_test.go", + "merged_client_builder_test.go", + "validation_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = [ + "//vendor/github.com/ghodss/yaml:go_default_library", + "//vendor/github.com/imdario/mergo:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api/latest:go_default_library", + ], +) + +go_library( + name = "go_default_library", + srcs = [ + "auth_loaders.go", + "client_config.go", + "config.go", + "doc.go", + "helpers.go", + "loader.go", + "merged_client_builder.go", + "overrides.go", + "validation.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/github.com/howeyc/gopass:go_default_library", + "//vendor/github.com/imdario/mergo:go_default_library", + "//vendor/github.com/spf13/pflag:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/errors:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/validation:go_default_library", + "//vendor/k8s.io/client-go/pkg/api/v1:go_default_library", + "//vendor/k8s.io/client-go/rest:go_default_library", + "//vendor/k8s.io/client-go/tools/auth:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api/latest:go_default_library", + "//vendor/k8s.io/client-go/util/homedir:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/BUILD b/vendor/k8s.io/client-go/tools/clientcmd/api/BUILD new file mode 100644 index 0000000000..d82afcf378 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "helpers_test.go", + "types_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/github.com/ghodss/yaml:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "helpers.go", + "register.go", + "types.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/latest/BUILD b/vendor/k8s.io/client-go/tools/clientcmd/api/latest/BUILD new file mode 100644 index 0000000000..7be78c9608 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/latest/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["latest.go"], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/json:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/serializer/versioning:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api/v1:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/latest/latest.go b/vendor/k8s.io/client-go/tools/clientcmd/api/latest/latest.go index f9c24d6e5c..5fbbe3f13a 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/api/latest/latest.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/latest/latest.go @@ -17,10 +17,10 @@ limitations under the License. package latest import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - "k8s.io/client-go/pkg/runtime/serializer/json" - "k8s.io/client-go/pkg/runtime/serializer/versioning" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + "k8s.io/apimachinery/pkg/runtime/serializer/json" + "k8s.io/apimachinery/pkg/runtime/serializer/versioning" "k8s.io/client-go/tools/clientcmd/api" "k8s.io/client-go/tools/clientcmd/api/v1" ) @@ -28,7 +28,7 @@ import ( // Version is the string that represents the current external default version. const Version = "v1" -var ExternalVersion = unversioned.GroupVersion{Group: "", Version: "v1"} +var ExternalVersion = schema.GroupVersion{Group: "", Version: "v1"} // OldestVersion is the string that represents the oldest server version supported, // for client code that wants to hardcode the lowest common denominator. @@ -60,7 +60,7 @@ func init() { Scheme, yamlSerializer, yamlSerializer, - unversioned.GroupVersion{Version: Version}, + schema.GroupVersion{Version: Version}, runtime.InternalGroupVersioner, ) } diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/register.go b/vendor/k8s.io/client-go/tools/clientcmd/api/register.go index efca4eea14..2eec3881cd 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/api/register.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/register.go @@ -17,13 +17,13 @@ limitations under the License. package api import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // SchemeGroupVersion is group version used to register these objects // TODO this should be in the "kubeconfig" group -var SchemeGroupVersion = unversioned.GroupVersion{Group: "", Version: runtime.APIVersionInternal} +var SchemeGroupVersion = schema.GroupVersion{Group: "", Version: runtime.APIVersionInternal} var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) @@ -37,10 +37,10 @@ func addKnownTypes(scheme *runtime.Scheme) error { return nil } -func (obj *Config) GetObjectKind() unversioned.ObjectKind { return obj } -func (obj *Config) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { +func (obj *Config) GetObjectKind() schema.ObjectKind { return obj } +func (obj *Config) SetGroupVersionKind(gvk schema.GroupVersionKind) { obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() } -func (obj *Config) GroupVersionKind() unversioned.GroupVersionKind { - return unversioned.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) +func (obj *Config) GroupVersionKind() schema.GroupVersionKind { + return schema.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) } diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/types.go b/vendor/k8s.io/client-go/tools/clientcmd/api/types.go index af4d9fef0b..76090c6f56 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/api/types.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/types.go @@ -17,7 +17,7 @@ limitations under the License. package api import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) // Where possible, json tags match the cli argument names. @@ -30,11 +30,8 @@ type Config struct { // TODO(jlowdermilk): remove this after eliminating downstream dependencies. // +optional Kind string `json:"kind,omitempty"` - // DEPRECATED: APIVersion is the preferred api version for communicating with the kubernetes cluster (v1, v2, etc). - // Because a cluster can run multiple API groups and potentially multiple versions of each, it no longer makes sense to specify - // a single value for the cluster version. - // This field isn't really needed anyway, so we are deprecating it without replacement. - // It will be ignored if it is present. + // Legacy field from pkg/api/types.go TypeMeta. + // TODO(jlowdermilk): remove this after eliminating downstream dependencies. // +optional APIVersion string `json:"apiVersion,omitempty"` // Preferences holds general information to be use for cli interactions @@ -67,9 +64,6 @@ type Cluster struct { LocationOfOrigin string // Server is the address of the kubernetes cluster (https://hostname:port). Server string `json:"server"` - // APIVersion is the preferred api version for communicating with the kubernetes cluster (v1, v2, etc). - // +optional - APIVersion string `json:"api-version,omitempty"` // InsecureSkipTLSVerify skips the validity check for the server's certificate. This will make your HTTPS connections insecure. // +optional InsecureSkipTLSVerify bool `json:"insecure-skip-tls-verify,omitempty"` @@ -109,6 +103,12 @@ type AuthInfo struct { // Impersonate is the username to act-as. // +optional Impersonate string `json:"act-as,omitempty"` + // ImpersonateGroups is the groups to imperonate. + // +optional + ImpersonateGroups []string `json:"act-as-groups,omitempty"` + // ImpersonateUserExtra contains additional information for impersonated user. + // +optional + ImpersonateUserExtra map[string][]string `json:"act-as-user-extra,omitempty"` // Username is the username for basic authentication to the kubernetes cluster. // +optional Username string `json:"username,omitempty"` @@ -157,22 +157,29 @@ func NewConfig() *Config { } } -// NewConfig is a convenience function that returns a new Config object with non-nil maps +// NewContext is a convenience function that returns a new Context +// object with non-nil maps func NewContext() *Context { return &Context{Extensions: make(map[string]runtime.Object)} } -// NewConfig is a convenience function that returns a new Config object with non-nil maps +// NewCluster is a convenience function that returns a new Cluster +// object with non-nil maps func NewCluster() *Cluster { return &Cluster{Extensions: make(map[string]runtime.Object)} } -// NewConfig is a convenience function that returns a new Config object with non-nil maps +// NewAuthInfo is a convenience function that returns a new AuthInfo +// object with non-nil maps func NewAuthInfo() *AuthInfo { - return &AuthInfo{Extensions: make(map[string]runtime.Object)} + return &AuthInfo{ + Extensions: make(map[string]runtime.Object), + ImpersonateUserExtra: make(map[string][]string), + } } -// NewConfig is a convenience function that returns a new Config object with non-nil maps +// NewPreferences is a convenience function that returns a new +// Preferences object with non-nil maps func NewPreferences() *Preferences { return &Preferences{Extensions: make(map[string]runtime.Object)} } diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/BUILD b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/BUILD new file mode 100644 index 0000000000..365d2597f4 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/BUILD @@ -0,0 +1,24 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "conversion.go", + "register.go", + "types.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/k8s.io/apimachinery/pkg/conversion:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/runtime/schema:go_default_library", + "//vendor/k8s.io/client-go/tools/clientcmd/api:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/conversion.go b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/conversion.go index 61bc479326..b47bfbca23 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/conversion.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/conversion.go @@ -19,8 +19,8 @@ package v1 import ( "sort" - "k8s.io/client-go/pkg/conversion" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" "k8s.io/client-go/tools/clientcmd/api" ) diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/register.go b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/register.go index d8659354a6..7b91d50908 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/register.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/register.go @@ -17,19 +17,29 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" ) // SchemeGroupVersion is group version used to register these objects // TODO this should be in the "kubeconfig" group -var SchemeGroupVersion = unversioned.GroupVersion{Group: "", Version: "v1"} +var SchemeGroupVersion = schema.GroupVersion{Group: "", Version: "v1"} var ( - SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes, addConversionFuncs) - AddToScheme = SchemeBuilder.AddToScheme + // TODO: move SchemeBuilder with zz_generated.deepcopy.go to k8s.io/api. + // localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes. + SchemeBuilder runtime.SchemeBuilder + localSchemeBuilder = &SchemeBuilder + AddToScheme = localSchemeBuilder.AddToScheme ) +func init() { + // We only register manually written functions here. The registration of the + // generated functions takes place in the generated files. The separation + // makes the code compile even when the generated files are missing. + localSchemeBuilder.Register(addKnownTypes, addConversionFuncs) +} + func addKnownTypes(scheme *runtime.Scheme) error { scheme.AddKnownTypes(SchemeGroupVersion, &Config{}, @@ -37,10 +47,10 @@ func addKnownTypes(scheme *runtime.Scheme) error { return nil } -func (obj *Config) GetObjectKind() unversioned.ObjectKind { return obj } -func (obj *Config) SetGroupVersionKind(gvk unversioned.GroupVersionKind) { +func (obj *Config) GetObjectKind() schema.ObjectKind { return obj } +func (obj *Config) SetGroupVersionKind(gvk schema.GroupVersionKind) { obj.APIVersion, obj.Kind = gvk.ToAPIVersionAndKind() } -func (obj *Config) GroupVersionKind() unversioned.GroupVersionKind { - return unversioned.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) +func (obj *Config) GroupVersionKind() schema.GroupVersionKind { + return schema.FromAPIVersionAndKind(obj.APIVersion, obj.Kind) } diff --git a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/types.go b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/types.go index a61b6cb8a6..21b94d25fd 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/api/v1/types.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/api/v1/types.go @@ -17,7 +17,7 @@ limitations under the License. package v1 import ( - "k8s.io/client-go/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime" ) // Where possible, json tags match the cli argument names. @@ -29,11 +29,8 @@ type Config struct { // TODO(jlowdermilk): remove this after eliminating downstream dependencies. // +optional Kind string `json:"kind,omitempty"` - // DEPRECATED: APIVersion is the preferred api version for communicating with the kubernetes cluster (v1, v2, etc). - // Because a cluster can run multiple API groups and potentially multiple versions of each, it no longer makes sense to specify - // a single value for the cluster version. - // This field isn't really needed anyway, so we are deprecating it without replacement. - // It will be ignored if it is present. + // Legacy field from pkg/api/types.go TypeMeta. + // TODO(jlowdermilk): remove this after eliminating downstream dependencies. // +optional APIVersion string `json:"apiVersion,omitempty"` // Preferences holds general information to be use for cli interactions @@ -63,9 +60,6 @@ type Preferences struct { type Cluster struct { // Server is the address of the kubernetes cluster (https://hostname:port). Server string `json:"server"` - // APIVersion is the preferred api version for communicating with the kubernetes cluster (v1, v2, etc). - // +optional - APIVersion string `json:"api-version,omitempty"` // InsecureSkipTLSVerify skips the validity check for the server's certificate. This will make your HTTPS connections insecure. // +optional InsecureSkipTLSVerify bool `json:"insecure-skip-tls-verify,omitempty"` @@ -103,6 +97,12 @@ type AuthInfo struct { // Impersonate is the username to imperonate. The name matches the flag. // +optional Impersonate string `json:"as,omitempty"` + // ImpersonateGroups is the groups to imperonate. + // +optional + ImpersonateGroups []string `json:"as-groups,omitempty"` + // ImpersonateUserExtra contains additional information for impersonated user. + // +optional + ImpersonateUserExtra map[string][]string `json:"as-user-extra,omitempty"` // Username is the username for basic authentication to the kubernetes cluster. // +optional Username string `json:"username,omitempty"` diff --git a/vendor/k8s.io/client-go/tools/clientcmd/client_config.go b/vendor/k8s.io/client-go/tools/clientcmd/client_config.go index 61bda9f6be..103648f1dc 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/client_config.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/client_config.go @@ -27,11 +27,8 @@ import ( "github.com/golang/glog" "github.com/imdario/mergo" - "strconv" - "time" - - "k8s.io/client-go/pkg/api" - "k8s.io/client-go/rest" + "k8s.io/client-go/pkg/api/v1" + restclient "k8s.io/client-go/rest" clientauth "k8s.io/client-go/tools/auth" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" ) @@ -44,7 +41,7 @@ var ( // DEPRECATED will be replace DefaultClientConfig = DirectClientConfig{*clientcmdapi.NewConfig(), "", &ConfigOverrides{ ClusterDefaults: ClusterDefaults, - }, nil, NewDefaultClientConfigLoadingRules()} + }, nil, NewDefaultClientConfigLoadingRules(), promptedCredentials{}} ) // getDefaultServer returns a default setting for DefaultClientConfig @@ -61,7 +58,7 @@ type ClientConfig interface { // RawConfig returns the merged result of all overrides RawConfig() (clientcmdapi.Config, error) // ClientConfig returns a complete client config - ClientConfig() (*rest.Config, error) + ClientConfig() (*restclient.Config, error) // Namespace returns the namespace resulting from the merged // result of all overrides and a boolean indicating if it was // overridden @@ -70,7 +67,12 @@ type ClientConfig interface { ConfigAccess() ConfigAccess } -type PersistAuthProviderConfigForUser func(user string) rest.AuthProviderConfigPersister +type PersistAuthProviderConfigForUser func(user string) restclient.AuthProviderConfigPersister + +type promptedCredentials struct { + username string + password string +} // DirectClientConfig is a ClientConfig interface that is backed by a clientcmdapi.Config, options overrides, and an optional fallbackReader for auth information type DirectClientConfig struct { @@ -79,21 +81,23 @@ type DirectClientConfig struct { overrides *ConfigOverrides fallbackReader io.Reader configAccess ConfigAccess + // promptedCredentials store the credentials input by the user + promptedCredentials promptedCredentials } // NewDefaultClientConfig creates a DirectClientConfig using the config.CurrentContext as the context name func NewDefaultClientConfig(config clientcmdapi.Config, overrides *ConfigOverrides) ClientConfig { - return &DirectClientConfig{config, config.CurrentContext, overrides, nil, NewDefaultClientConfigLoadingRules()} + return &DirectClientConfig{config, config.CurrentContext, overrides, nil, NewDefaultClientConfigLoadingRules(), promptedCredentials{}} } // NewNonInteractiveClientConfig creates a DirectClientConfig using the passed context name and does not have a fallback reader for auth information func NewNonInteractiveClientConfig(config clientcmdapi.Config, contextName string, overrides *ConfigOverrides, configAccess ConfigAccess) ClientConfig { - return &DirectClientConfig{config, contextName, overrides, nil, configAccess} + return &DirectClientConfig{config, contextName, overrides, nil, configAccess, promptedCredentials{}} } // NewInteractiveClientConfig creates a DirectClientConfig using the passed context name and a reader in case auth information is not provided via files or flags func NewInteractiveClientConfig(config clientcmdapi.Config, contextName string, overrides *ConfigOverrides, fallbackReader io.Reader, configAccess ConfigAccess) ClientConfig { - return &DirectClientConfig{config, contextName, overrides, fallbackReader, configAccess} + return &DirectClientConfig{config, contextName, overrides, fallbackReader, configAccess, promptedCredentials{}} } func (config *DirectClientConfig) RawConfig() (clientcmdapi.Config, error) { @@ -101,7 +105,7 @@ func (config *DirectClientConfig) RawConfig() (clientcmdapi.Config, error) { } // ClientConfig implements ClientConfig -func (config *DirectClientConfig) ClientConfig() (*rest.Config, error) { +func (config *DirectClientConfig) ClientConfig() (*restclient.Config, error) { // check that getAuthInfo, getContext, and getCluster do not return an error. // Do this before checking if the curent config is usable in the event that an // AuthInfo, Context, or Cluster config with user-defined names are not found. @@ -125,17 +129,15 @@ func (config *DirectClientConfig) ClientConfig() (*rest.Config, error) { return nil, err } - clientConfig := &rest.Config{} + clientConfig := &restclient.Config{} clientConfig.Host = configClusterInfo.Server if len(config.overrides.Timeout) > 0 { - if i, err := strconv.ParseInt(config.overrides.Timeout, 10, 64); err == nil && i >= 0 { - clientConfig.Timeout = time.Duration(i) * time.Second - } else if requestTimeout, err := time.ParseDuration(config.overrides.Timeout); err == nil { - clientConfig.Timeout = requestTimeout - } else { - return nil, fmt.Errorf("Invalid value for option '--request-timeout'. Value must be a single integer, or an integer followed by a corresponding time unit (e.g. 1s | 2m | 3h)") + timeout, err := ParseTimeout(config.overrides.Timeout) + if err != nil { + return nil, err } + clientConfig.Timeout = timeout } if u, err := url.ParseRequestURI(clientConfig.Host); err == nil && u.Opaque == "" && len(u.Path) > 1 { @@ -144,22 +146,26 @@ func (config *DirectClientConfig) ClientConfig() (*rest.Config, error) { clientConfig.Host = u.String() } if len(configAuthInfo.Impersonate) > 0 { - clientConfig.Impersonate = configAuthInfo.Impersonate + clientConfig.Impersonate = restclient.ImpersonationConfig{ + UserName: configAuthInfo.Impersonate, + Groups: configAuthInfo.ImpersonateGroups, + Extra: configAuthInfo.ImpersonateUserExtra, + } } // only try to read the auth information if we are secure - if rest.IsConfigTransportTLS(*clientConfig) { + if restclient.IsConfigTransportTLS(*clientConfig) { var err error // mergo is a first write wins for map value and a last writing wins for interface values // NOTE: This behavior changed with https://github.com/imdario/mergo/commit/d304790b2ed594794496464fadd89d2bb266600a. // Our mergo.Merge version is older than this change. - var persister rest.AuthProviderConfigPersister + var persister restclient.AuthProviderConfigPersister if config.configAccess != nil { authInfoName, _ := config.getAuthInfoName() persister = PersisterForUser(config.configAccess, authInfoName) } - userAuthPartialConfig, err := getUserIdentificationPartialConfig(configAuthInfo, config.fallbackReader, persister) + userAuthPartialConfig, err := config.getUserIdentificationPartialConfig(configAuthInfo, config.fallbackReader, persister) if err != nil { return nil, err } @@ -181,11 +187,11 @@ func (config *DirectClientConfig) ClientConfig() (*rest.Config, error) { // 1. configClusterInfo (the final result of command line flags and merged .kubeconfig files) // 2. configAuthInfo.auth-path (this file can contain information that conflicts with #1, and we want #1 to win the priority) // 3. load the ~/.kubernetes_auth file as a default -func getServerIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, configClusterInfo clientcmdapi.Cluster) (*rest.Config, error) { - mergedConfig := &rest.Config{} +func getServerIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, configClusterInfo clientcmdapi.Cluster) (*restclient.Config, error) { + mergedConfig := &restclient.Config{} // configClusterInfo holds the information identify the server provided by .kubeconfig - configClientConfig := &rest.Config{} + configClientConfig := &restclient.Config{} configClientConfig.CAFile = configClusterInfo.CertificateAuthority configClientConfig.CAData = configClusterInfo.CertificateAuthorityData configClientConfig.Insecure = configClusterInfo.InsecureSkipTLSVerify @@ -199,10 +205,10 @@ func getServerIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, // we want this order of precedence for user identifcation // 1. configAuthInfo minus auth-path (the final result of command line flags and merged .kubeconfig files) // 2. configAuthInfo.auth-path (this file can contain information that conflicts with #1, and we want #1 to win the priority) -// 3. if there is not enough information to idenfity the user, load try the ~/.kubernetes_auth file +// 3. if there is not enough information to identify the user, load try the ~/.kubernetes_auth file // 4. if there is not enough information to identify the user, prompt if possible -func getUserIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, fallbackReader io.Reader, persistAuthConfig rest.AuthProviderConfigPersister) (*rest.Config, error) { - mergedConfig := &rest.Config{} +func (config *DirectClientConfig) getUserIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, fallbackReader io.Reader, persistAuthConfig restclient.AuthProviderConfigPersister) (*restclient.Config, error) { + mergedConfig := &restclient.Config{} // blindly overwrite existing values based on precedence if len(configAuthInfo.Token) > 0 { @@ -215,7 +221,11 @@ func getUserIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, fa mergedConfig.BearerToken = string(tokenBytes) } if len(configAuthInfo.Impersonate) > 0 { - mergedConfig.Impersonate = configAuthInfo.Impersonate + mergedConfig.Impersonate = restclient.ImpersonationConfig{ + UserName: configAuthInfo.Impersonate, + Groups: configAuthInfo.ImpersonateGroups, + Extra: configAuthInfo.ImpersonateUserExtra, + } } if len(configAuthInfo.ClientCertificate) > 0 || len(configAuthInfo.ClientCertificateData) > 0 { mergedConfig.CertFile = configAuthInfo.ClientCertificate @@ -234,6 +244,11 @@ func getUserIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, fa // if there still isn't enough information to authenticate the user, try prompting if !canIdentifyUser(*mergedConfig) && (fallbackReader != nil) { + if len(config.promptedCredentials.username) > 0 && len(config.promptedCredentials.password) > 0 { + mergedConfig.Username = config.promptedCredentials.username + mergedConfig.Password = config.promptedCredentials.password + return mergedConfig, nil + } prompter := NewPromptingAuthLoader(fallbackReader) promptedAuthInfo, err := prompter.Prompt() if err != nil { @@ -241,17 +256,19 @@ func getUserIdentificationPartialConfig(configAuthInfo clientcmdapi.AuthInfo, fa } promptedConfig := makeUserIdentificationConfig(*promptedAuthInfo) previouslyMergedConfig := mergedConfig - mergedConfig = &rest.Config{} + mergedConfig = &restclient.Config{} mergo.Merge(mergedConfig, promptedConfig) mergo.Merge(mergedConfig, previouslyMergedConfig) + config.promptedCredentials.username = mergedConfig.Username + config.promptedCredentials.password = mergedConfig.Password } return mergedConfig, nil } // makeUserIdentificationFieldsConfig returns a client.Config capable of being merged using mergo for only user identification information -func makeUserIdentificationConfig(info clientauth.Info) *rest.Config { - config := &rest.Config{} +func makeUserIdentificationConfig(info clientauth.Info) *restclient.Config { + config := &restclient.Config{} config.Username = info.User config.Password = info.Password config.CertFile = info.CertFile @@ -261,8 +278,8 @@ func makeUserIdentificationConfig(info clientauth.Info) *rest.Config { } // makeUserIdentificationFieldsConfig returns a client.Config capable of being merged using mergo for only server identification information -func makeServerIdentificationConfig(info clientauth.Info) rest.Config { - config := rest.Config{} +func makeServerIdentificationConfig(info clientauth.Info) restclient.Config { + config := restclient.Config{} config.CAFile = info.CAFile if info.Insecure != nil { config.Insecure = *info.Insecure @@ -270,7 +287,7 @@ func makeServerIdentificationConfig(info clientauth.Info) rest.Config { return config } -func canIdentifyUser(config rest.Config) bool { +func canIdentifyUser(config restclient.Config) bool { return len(config.Username) > 0 || (len(config.CertFile) > 0 || len(config.CertData) > 0) || len(config.BearerToken) > 0 || @@ -279,6 +296,14 @@ func canIdentifyUser(config rest.Config) bool { // Namespace implements ClientConfig func (config *DirectClientConfig) Namespace() (string, bool, error) { + if config.overrides != nil && config.overrides.Context.Namespace != "" { + // In the event we have an empty config but we do have a namespace override, we should return + // the namespace override instead of having config.ConfirmUsable() return an error. This allows + // things like in-cluster clients to execute `kubectl get pods --namespace=foo` and have the + // --namespace flag honored instead of being ignored. + return config.overrides.Context.Namespace, true, nil + } + if err := config.ConfirmUsable(); err != nil { return "", false, err } @@ -289,14 +314,10 @@ func (config *DirectClientConfig) Namespace() (string, bool, error) { } if len(configContext.Namespace) == 0 { - return api.NamespaceDefault, false, nil + return v1.NamespaceDefault, false, nil } - overridden := false - if config.overrides != nil && config.overrides.Context.Namespace != "" { - overridden = true - } - return configContext.Namespace, overridden, nil + return configContext.Namespace, false, nil } // ConfigAccess implements ClientConfig @@ -377,15 +398,15 @@ func (config *DirectClientConfig) getContext() (clientcmdapi.Context, error) { contexts := config.config.Contexts contextName, required := config.getContextName() - var mergedContext clientcmdapi.Context + mergedContext := clientcmdapi.NewContext() if configContext, exists := contexts[contextName]; exists { - mergo.Merge(&mergedContext, configContext) + mergo.Merge(mergedContext, configContext) } else if required { return clientcmdapi.Context{}, fmt.Errorf("context %q does not exist", contextName) } - mergo.Merge(&mergedContext, config.overrides.Context) + mergo.Merge(mergedContext, config.overrides.Context) - return mergedContext, nil + return *mergedContext, nil } // getAuthInfo returns the clientcmdapi.AuthInfo, or an error if a required auth info is not found. @@ -393,15 +414,15 @@ func (config *DirectClientConfig) getAuthInfo() (clientcmdapi.AuthInfo, error) { authInfos := config.config.AuthInfos authInfoName, required := config.getAuthInfoName() - var mergedAuthInfo clientcmdapi.AuthInfo + mergedAuthInfo := clientcmdapi.NewAuthInfo() if configAuthInfo, exists := authInfos[authInfoName]; exists { - mergo.Merge(&mergedAuthInfo, configAuthInfo) + mergo.Merge(mergedAuthInfo, configAuthInfo) } else if required { return clientcmdapi.AuthInfo{}, fmt.Errorf("auth info %q does not exist", authInfoName) } - mergo.Merge(&mergedAuthInfo, config.overrides.AuthInfo) + mergo.Merge(mergedAuthInfo, config.overrides.AuthInfo) - return mergedAuthInfo, nil + return *mergedAuthInfo, nil } // getCluster returns the clientcmdapi.Cluster, or an error if a required cluster is not found. @@ -409,14 +430,14 @@ func (config *DirectClientConfig) getCluster() (clientcmdapi.Cluster, error) { clusterInfos := config.config.Clusters clusterInfoName, required := config.getClusterName() - var mergedClusterInfo clientcmdapi.Cluster - mergo.Merge(&mergedClusterInfo, config.overrides.ClusterDefaults) + mergedClusterInfo := clientcmdapi.NewCluster() + mergo.Merge(mergedClusterInfo, config.overrides.ClusterDefaults) if configClusterInfo, exists := clusterInfos[clusterInfoName]; exists { - mergo.Merge(&mergedClusterInfo, configClusterInfo) + mergo.Merge(mergedClusterInfo, configClusterInfo) } else if required { return clientcmdapi.Cluster{}, fmt.Errorf("cluster %q does not exist", clusterInfoName) } - mergo.Merge(&mergedClusterInfo, config.overrides.ClusterInfo) + mergo.Merge(mergedClusterInfo, config.overrides.ClusterInfo) // An override of --insecure-skip-tls-verify=true and no accompanying CA/CA data should clear already-set CA/CA data // otherwise, a kubeconfig containing a CA reference would return an error that "CA and insecure-skip-tls-verify couldn't both be set" caLen := len(config.overrides.ClusterInfo.CertificateAuthority) @@ -426,45 +447,72 @@ func (config *DirectClientConfig) getCluster() (clientcmdapi.Cluster, error) { mergedClusterInfo.CertificateAuthorityData = nil } - return mergedClusterInfo, nil + return *mergedClusterInfo, nil } // inClusterClientConfig makes a config that will work from within a kubernetes cluster container environment. -type inClusterClientConfig struct{} +// Can take options overrides for flags explicitly provided to the command inside the cluster container. +type inClusterClientConfig struct { + overrides *ConfigOverrides + inClusterConfigProvider func() (*restclient.Config, error) +} -var _ ClientConfig = inClusterClientConfig{} +var _ ClientConfig = &inClusterClientConfig{} -func (inClusterClientConfig) RawConfig() (clientcmdapi.Config, error) { +func (config *inClusterClientConfig) RawConfig() (clientcmdapi.Config, error) { return clientcmdapi.Config{}, fmt.Errorf("inCluster environment config doesn't support multiple clusters") } -func (inClusterClientConfig) ClientConfig() (*rest.Config, error) { - return rest.InClusterConfig() +func (config *inClusterClientConfig) ClientConfig() (*restclient.Config, error) { + if config.inClusterConfigProvider == nil { + config.inClusterConfigProvider = restclient.InClusterConfig + } + + icc, err := config.inClusterConfigProvider() + if err != nil { + return nil, err + } + + // in-cluster configs only takes a host, token, or CA file + // if any of them were individually provided, ovewrite anything else + if config.overrides != nil { + if server := config.overrides.ClusterInfo.Server; len(server) > 0 { + icc.Host = server + } + if token := config.overrides.AuthInfo.Token; len(token) > 0 { + icc.BearerToken = token + } + if certificateAuthorityFile := config.overrides.ClusterInfo.CertificateAuthority; len(certificateAuthorityFile) > 0 { + icc.TLSClientConfig.CAFile = certificateAuthorityFile + } + } + + return icc, err } -func (inClusterClientConfig) Namespace() (string, bool, error) { +func (config *inClusterClientConfig) Namespace() (string, bool, error) { // This way assumes you've set the POD_NAMESPACE environment variable using the downward API. // This check has to be done first for backwards compatibility with the way InClusterConfig was originally set up if ns := os.Getenv("POD_NAMESPACE"); ns != "" { - return ns, true, nil + return ns, false, nil } // Fall back to the namespace associated with the service account token, if available if data, err := ioutil.ReadFile("/var/run/secrets/kubernetes.io/serviceaccount/namespace"); err == nil { if ns := strings.TrimSpace(string(data)); len(ns) > 0 { - return ns, true, nil + return ns, false, nil } } return "default", false, nil } -func (inClusterClientConfig) ConfigAccess() ConfigAccess { +func (config *inClusterClientConfig) ConfigAccess() ConfigAccess { return NewDefaultClientConfigLoadingRules() } // Possible returns true if loading an inside-kubernetes-cluster is possible. -func (inClusterClientConfig) Possible() bool { +func (config *inClusterClientConfig) Possible() bool { fi, err := os.Stat("/var/run/secrets/kubernetes.io/serviceaccount/token") return os.Getenv("KUBERNETES_SERVICE_HOST") != "" && os.Getenv("KUBERNETES_SERVICE_PORT") != "" && @@ -476,10 +524,10 @@ func (inClusterClientConfig) Possible() bool { // components. Warnings should reflect this usage. If neither masterUrl or kubeconfigPath // are passed in we fallback to inClusterConfig. If inClusterConfig fails, we fallback // to the default config. -func BuildConfigFromFlags(masterUrl, kubeconfigPath string) (*rest.Config, error) { +func BuildConfigFromFlags(masterUrl, kubeconfigPath string) (*restclient.Config, error) { if kubeconfigPath == "" && masterUrl == "" { glog.Warningf("Neither --kubeconfig nor --master was specified. Using the inClusterConfig. This might not work.") - kubeconfig, err := rest.InClusterConfig() + kubeconfig, err := restclient.InClusterConfig() if err == nil { return kubeconfig, nil } @@ -492,7 +540,7 @@ func BuildConfigFromFlags(masterUrl, kubeconfigPath string) (*rest.Config, error // BuildConfigFromKubeconfigGetter is a helper function that builds configs from a master // url and a kubeconfigGetter. -func BuildConfigFromKubeconfigGetter(masterUrl string, kubeconfigGetter KubeconfigGetter) (*rest.Config, error) { +func BuildConfigFromKubeconfigGetter(masterUrl string, kubeconfigGetter KubeconfigGetter) (*restclient.Config, error) { // TODO: We do not need a DeferredLoader here. Refactor code and see if we can use DirectClientConfig here. cc := NewNonInteractiveDeferredLoadingClientConfig( &ClientConfigGetter{kubeconfigGetter: kubeconfigGetter}, diff --git a/vendor/k8s.io/client-go/tools/clientcmd/config.go b/vendor/k8s.io/client-go/tools/clientcmd/config.go index 3e5aa49a38..16ccdaf20a 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/config.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/config.go @@ -26,7 +26,7 @@ import ( "github.com/golang/glog" - "k8s.io/client-go/rest" + restclient "k8s.io/client-go/rest" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" ) @@ -325,7 +325,7 @@ func ModifyConfig(configAccess ConfigAccess, newConfig clientcmdapi.Config, rela return nil } -func PersisterForUser(configAccess ConfigAccess, user string) rest.AuthProviderConfigPersister { +func PersisterForUser(configAccess ConfigAccess, user string) restclient.AuthProviderConfigPersister { return &persister{configAccess, user} } diff --git a/vendor/k8s.io/client-go/tools/clientcmd/doc.go b/vendor/k8s.io/client-go/tools/clientcmd/doc.go index 30ef6f36da..c07ace6a58 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/doc.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/doc.go @@ -31,7 +31,7 @@ Sample usage from merged .kubeconfig files (local directory, home directory) if err != nil { // Do something } - client, err := unversioned.New(config) + client, err := metav1.New(config) // ... */ package clientcmd diff --git a/vendor/k8s.io/client-go/tools/clientcmd/helpers.go b/vendor/k8s.io/client-go/tools/clientcmd/helpers.go new file mode 100644 index 0000000000..b609d1a766 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/clientcmd/helpers.go @@ -0,0 +1,35 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package clientcmd + +import ( + "fmt" + "strconv" + "time" +) + +// ParseTimeout returns a parsed duration from a string +// A duration string value must be a positive integer, optionally followed by a corresponding time unit (s|m|h). +func ParseTimeout(duration string) (time.Duration, error) { + if i, err := strconv.ParseInt(duration, 10, 64); err == nil && i >= 0 { + return (time.Duration(i) * time.Second), nil + } + if requestTimeout, err := time.ParseDuration(duration); err == nil { + return requestTimeout, nil + } + return 0, fmt.Errorf("Invalid timeout value. Timeout must be a single integer in seconds, or an integer followed by a corresponding time unit (e.g. 1s | 2m | 3h)") +} diff --git a/vendor/k8s.io/client-go/tools/clientcmd/loader.go b/vendor/k8s.io/client-go/tools/clientcmd/loader.go index d678e7fa20..6ac83b5c84 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/loader.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/loader.go @@ -30,13 +30,13 @@ import ( "github.com/golang/glog" "github.com/imdario/mergo" - "k8s.io/client-go/pkg/api/unversioned" - "k8s.io/client-go/pkg/runtime" - utilerrors "k8s.io/client-go/pkg/util/errors" - "k8s.io/client-go/pkg/util/homedir" - "k8s.io/client-go/rest" + "k8s.io/apimachinery/pkg/runtime" + "k8s.io/apimachinery/pkg/runtime/schema" + utilerrors "k8s.io/apimachinery/pkg/util/errors" + restclient "k8s.io/client-go/rest" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" clientcmdlatest "k8s.io/client-go/tools/clientcmd/api/latest" + "k8s.io/client-go/util/homedir" ) const ( @@ -47,8 +47,11 @@ const ( RecommendedSchemaName = "schema" ) -var RecommendedHomeFile = path.Join(homedir.HomeDir(), RecommendedHomeDir, RecommendedFileName) -var RecommendedSchemaFile = path.Join(homedir.HomeDir(), RecommendedHomeDir, RecommendedSchemaName) +var ( + RecommendedConfigDir = path.Join(homedir.HomeDir(), RecommendedHomeDir) + RecommendedHomeFile = path.Join(RecommendedConfigDir, RecommendedFileName) + RecommendedSchemaFile = path.Join(RecommendedConfigDir, RecommendedSchemaName) +) // currentMigrationRules returns a map that holds the history of recommended home directories used in previous versions. // Any future changes to RecommendedHomeFile and related are expected to add a migration rule here, in order to make @@ -68,7 +71,7 @@ func currentMigrationRules() map[string]string { type ClientConfigLoader interface { ConfigAccess // IsDefaultConfig returns true if the returned config matches the defaults. - IsDefaultConfig(*rest.Config) bool + IsDefaultConfig(*restclient.Config) bool // Load returns the latest config Load() (*clientcmdapi.Config, error) } @@ -101,7 +104,7 @@ func (g *ClientConfigGetter) IsExplicitFile() bool { func (g *ClientConfigGetter) GetExplicitFile() string { return "" } -func (g *ClientConfigGetter) IsDefaultConfig(config *rest.Config) bool { +func (g *ClientConfigGetter) IsDefaultConfig(config *restclient.Config) bool { return false } @@ -330,7 +333,7 @@ func (rules *ClientConfigLoadingRules) GetExplicitFile() string { } // IsDefaultConfig returns true if the provided configuration matches the default -func (rules *ClientConfigLoadingRules) IsDefaultConfig(config *rest.Config) bool { +func (rules *ClientConfigLoadingRules) IsDefaultConfig(config *restclient.Config) bool { if rules.DefaultClientConfig == nil { return false } @@ -388,7 +391,7 @@ func Load(data []byte) (*clientcmdapi.Config, error) { if len(data) == 0 { return config, nil } - decoded, _, err := clientcmdlatest.Codec.Decode(data, &unversioned.GroupVersionKind{Version: clientcmdlatest.Version, Kind: "Config"}, config) + decoded, _, err := clientcmdlatest.Codec.Decode(data, &schema.GroupVersionKind{Version: clientcmdlatest.Version, Kind: "Config"}, config) if err != nil { return nil, err } diff --git a/vendor/k8s.io/client-go/tools/clientcmd/merged_client_builder.go b/vendor/k8s.io/client-go/tools/clientcmd/merged_client_builder.go index 5343509c02..32ffd197ce 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/merged_client_builder.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/merged_client_builder.go @@ -22,7 +22,8 @@ import ( "github.com/golang/glog" - "k8s.io/client-go/rest" + "k8s.io/client-go/pkg/api/v1" + restclient "k8s.io/client-go/rest" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" ) @@ -51,12 +52,12 @@ type InClusterConfig interface { // NewNonInteractiveDeferredLoadingClientConfig creates a ConfigClientClientConfig using the passed context name func NewNonInteractiveDeferredLoadingClientConfig(loader ClientConfigLoader, overrides *ConfigOverrides) ClientConfig { - return &DeferredLoadingClientConfig{loader: loader, overrides: overrides, icc: inClusterClientConfig{}} + return &DeferredLoadingClientConfig{loader: loader, overrides: overrides, icc: &inClusterClientConfig{overrides: overrides}} } // NewInteractiveDeferredLoadingClientConfig creates a ConfigClientClientConfig using the passed context name and the fallback auth reader func NewInteractiveDeferredLoadingClientConfig(loader ClientConfigLoader, overrides *ConfigOverrides, fallbackReader io.Reader) ClientConfig { - return &DeferredLoadingClientConfig{loader: loader, overrides: overrides, icc: inClusterClientConfig{}, fallbackReader: fallbackReader} + return &DeferredLoadingClientConfig{loader: loader, overrides: overrides, icc: &inClusterClientConfig{overrides: overrides}, fallbackReader: fallbackReader} } func (config *DeferredLoadingClientConfig) createClientConfig() (ClientConfig, error) { @@ -94,7 +95,7 @@ func (config *DeferredLoadingClientConfig) RawConfig() (clientcmdapi.Config, err } // ClientConfig implements ClientConfig -func (config *DeferredLoadingClientConfig) ClientConfig() (*rest.Config, error) { +func (config *DeferredLoadingClientConfig) ClientConfig() (*restclient.Config, error) { mergedClientConfig, err := config.createClientConfig() if err != nil { return nil, err @@ -134,12 +135,26 @@ func (config *DeferredLoadingClientConfig) Namespace() (string, bool, error) { return "", false, err } - ns, ok, err := mergedKubeConfig.Namespace() + ns, overridden, err := mergedKubeConfig.Namespace() // if we get an error and it is not empty config, or if the merged config defined an explicit namespace, or // if in-cluster config is not possible, return immediately - if (err != nil && !IsEmptyConfig(err)) || ok || !config.icc.Possible() { + if (err != nil && !IsEmptyConfig(err)) || overridden || !config.icc.Possible() { // return on any error except empty config - return ns, ok, err + return ns, overridden, err + } + + if len(ns) > 0 { + // if we got a non-default namespace from the kubeconfig, use it + if ns != v1.NamespaceDefault { + return ns, false, nil + } + + // if we got a default namespace, determine whether it was explicit or implicit + if raw, err := mergedKubeConfig.RawConfig(); err == nil { + if context := raw.Contexts[raw.CurrentContext]; context != nil && len(context.Namespace) > 0 { + return ns, false, nil + } + } } glog.V(4).Infof("Using in-cluster namespace") diff --git a/vendor/k8s.io/client-go/tools/clientcmd/overrides.go b/vendor/k8s.io/client-go/tools/clientcmd/overrides.go index 965eca6440..963ac8fae9 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/overrides.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/overrides.go @@ -52,6 +52,7 @@ type AuthOverrideFlags struct { ClientKey FlagInfo Token FlagInfo Impersonate FlagInfo + ImpersonateGroups FlagInfo Username FlagInfo Password FlagInfo } @@ -85,16 +86,36 @@ type FlagInfo struct { Description string } +// AddSecretAnnotation add secret flag to Annotation. +func (f FlagInfo) AddSecretAnnotation(flags *pflag.FlagSet) FlagInfo { + flags.SetAnnotation(f.LongName, "classified", []string{"true"}) + return f +} + // BindStringFlag binds the flag based on the provided info. If LongName == "", nothing is registered -func (f FlagInfo) BindStringFlag(flags *pflag.FlagSet, target *string) { +func (f FlagInfo) BindStringFlag(flags *pflag.FlagSet, target *string) FlagInfo { // you can't register a flag without a long name if len(f.LongName) > 0 { flags.StringVarP(target, f.LongName, f.ShortName, f.Default, f.Description) } + return f +} + +// BindStringSliceFlag binds the flag based on the provided info. If LongName == "", nothing is registered +func (f FlagInfo) BindStringArrayFlag(flags *pflag.FlagSet, target *[]string) FlagInfo { + // you can't register a flag without a long name + if len(f.LongName) > 0 { + sliceVal := []string{} + if len(f.Default) > 0 { + sliceVal = []string{f.Default} + } + flags.StringArrayVarP(target, f.LongName, f.ShortName, sliceVal, f.Description) + } + return f } // BindBoolFlag binds the flag based on the provided info. If LongName == "", nothing is registered -func (f FlagInfo) BindBoolFlag(flags *pflag.FlagSet, target *bool) { +func (f FlagInfo) BindBoolFlag(flags *pflag.FlagSet, target *bool) FlagInfo { // you can't register a flag without a long name if len(f.LongName) > 0 { // try to parse Default as a bool. If it fails, assume false @@ -105,27 +126,40 @@ func (f FlagInfo) BindBoolFlag(flags *pflag.FlagSet, target *bool) { flags.BoolVarP(target, f.LongName, f.ShortName, boolVal, f.Description) } + return f } const ( - FlagClusterName = "cluster" - FlagAuthInfoName = "user" - FlagContext = "context" - FlagNamespace = "namespace" - FlagAPIServer = "server" - FlagAPIVersion = "api-version" - FlagInsecure = "insecure-skip-tls-verify" - FlagCertFile = "client-certificate" - FlagKeyFile = "client-key" - FlagCAFile = "certificate-authority" - FlagEmbedCerts = "embed-certs" - FlagBearerToken = "token" - FlagImpersonate = "as" - FlagUsername = "username" - FlagPassword = "password" - FlagTimeout = "request-timeout" + FlagClusterName = "cluster" + FlagAuthInfoName = "user" + FlagContext = "context" + FlagNamespace = "namespace" + FlagAPIServer = "server" + FlagInsecure = "insecure-skip-tls-verify" + FlagCertFile = "client-certificate" + FlagKeyFile = "client-key" + FlagCAFile = "certificate-authority" + FlagEmbedCerts = "embed-certs" + FlagBearerToken = "token" + FlagImpersonate = "as" + FlagImpersonateGroup = "as-group" + FlagUsername = "username" + FlagPassword = "password" + FlagTimeout = "request-timeout" ) +// RecommendedConfigOverrideFlags is a convenience method to return recommended flag names prefixed with a string of your choosing +func RecommendedConfigOverrideFlags(prefix string) ConfigOverrideFlags { + return ConfigOverrideFlags{ + AuthOverrideFlags: RecommendedAuthOverrideFlags(prefix), + ClusterOverrideFlags: RecommendedClusterOverrideFlags(prefix), + ContextOverrideFlags: RecommendedContextOverrideFlags(prefix), + + CurrentContext: FlagInfo{prefix + FlagContext, "", "", "The name of the kubeconfig context to use"}, + Timeout: FlagInfo{prefix + FlagTimeout, "", "0", "The length of time to wait before giving up on a single server request. Non-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests."}, + } +} + // RecommendedAuthOverrideFlags is a convenience method to return recommended flag names prefixed with a string of your choosing func RecommendedAuthOverrideFlags(prefix string) AuthOverrideFlags { return AuthOverrideFlags{ @@ -133,6 +167,7 @@ func RecommendedAuthOverrideFlags(prefix string) AuthOverrideFlags { ClientKey: FlagInfo{prefix + FlagKeyFile, "", "", "Path to a client key file for TLS"}, Token: FlagInfo{prefix + FlagBearerToken, "", "", "Bearer token for authentication to the API server"}, Impersonate: FlagInfo{prefix + FlagImpersonate, "", "", "Username to impersonate for the operation"}, + ImpersonateGroups: FlagInfo{prefix + FlagImpersonateGroup, "", "", "Group to impersonate for the operation, this flag can be repeated to specify multiple groups."}, Username: FlagInfo{prefix + FlagUsername, "", "", "Username for basic authentication to the API server"}, Password: FlagInfo{prefix + FlagPassword, "", "", "Password for basic authentication to the API server"}, } @@ -142,24 +177,11 @@ func RecommendedAuthOverrideFlags(prefix string) AuthOverrideFlags { func RecommendedClusterOverrideFlags(prefix string) ClusterOverrideFlags { return ClusterOverrideFlags{ APIServer: FlagInfo{prefix + FlagAPIServer, "", "", "The address and port of the Kubernetes API server"}, - APIVersion: FlagInfo{prefix + FlagAPIVersion, "", "", "DEPRECATED: The API version to use when talking to the server"}, - CertificateAuthority: FlagInfo{prefix + FlagCAFile, "", "", "Path to a cert. file for the certificate authority"}, + CertificateAuthority: FlagInfo{prefix + FlagCAFile, "", "", "Path to a cert file for the certificate authority"}, InsecureSkipTLSVerify: FlagInfo{prefix + FlagInsecure, "", "false", "If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure"}, } } -// RecommendedConfigOverrideFlags is a convenience method to return recommended flag names prefixed with a string of your choosing -func RecommendedConfigOverrideFlags(prefix string) ConfigOverrideFlags { - return ConfigOverrideFlags{ - AuthOverrideFlags: RecommendedAuthOverrideFlags(prefix), - ClusterOverrideFlags: RecommendedClusterOverrideFlags(prefix), - ContextOverrideFlags: RecommendedContextOverrideFlags(prefix), - - CurrentContext: FlagInfo{prefix + FlagContext, "", "", "The name of the kubeconfig context to use"}, - Timeout: FlagInfo{prefix + FlagTimeout, "", "0", "The length of time to wait before giving up on a single server request. Non-zero values should contain a corresponding time unit (e.g. 1s, 2m, 3h). A value of zero means don't timeout requests."}, - } -} - // RecommendedContextOverrideFlags is a convenience method to return recommended flag names prefixed with a string of your choosing func RecommendedContextOverrideFlags(prefix string) ContextOverrideFlags { return ContextOverrideFlags{ @@ -169,35 +191,33 @@ func RecommendedContextOverrideFlags(prefix string) ContextOverrideFlags { } } +// BindOverrideFlags is a convenience method to bind the specified flags to their associated variables +func BindOverrideFlags(overrides *ConfigOverrides, flags *pflag.FlagSet, flagNames ConfigOverrideFlags) { + BindAuthInfoFlags(&overrides.AuthInfo, flags, flagNames.AuthOverrideFlags) + BindClusterFlags(&overrides.ClusterInfo, flags, flagNames.ClusterOverrideFlags) + BindContextFlags(&overrides.Context, flags, flagNames.ContextOverrideFlags) + flagNames.CurrentContext.BindStringFlag(flags, &overrides.CurrentContext) + flagNames.Timeout.BindStringFlag(flags, &overrides.Timeout) +} + // BindAuthInfoFlags is a convenience method to bind the specified flags to their associated variables func BindAuthInfoFlags(authInfo *clientcmdapi.AuthInfo, flags *pflag.FlagSet, flagNames AuthOverrideFlags) { - flagNames.ClientCertificate.BindStringFlag(flags, &authInfo.ClientCertificate) - flagNames.ClientKey.BindStringFlag(flags, &authInfo.ClientKey) - flagNames.Token.BindStringFlag(flags, &authInfo.Token) - flagNames.Impersonate.BindStringFlag(flags, &authInfo.Impersonate) - flagNames.Username.BindStringFlag(flags, &authInfo.Username) - flagNames.Password.BindStringFlag(flags, &authInfo.Password) + flagNames.ClientCertificate.BindStringFlag(flags, &authInfo.ClientCertificate).AddSecretAnnotation(flags) + flagNames.ClientKey.BindStringFlag(flags, &authInfo.ClientKey).AddSecretAnnotation(flags) + flagNames.Token.BindStringFlag(flags, &authInfo.Token).AddSecretAnnotation(flags) + flagNames.Impersonate.BindStringFlag(flags, &authInfo.Impersonate).AddSecretAnnotation(flags) + flagNames.ImpersonateGroups.BindStringArrayFlag(flags, &authInfo.ImpersonateGroups).AddSecretAnnotation(flags) + flagNames.Username.BindStringFlag(flags, &authInfo.Username).AddSecretAnnotation(flags) + flagNames.Password.BindStringFlag(flags, &authInfo.Password).AddSecretAnnotation(flags) } // BindClusterFlags is a convenience method to bind the specified flags to their associated variables func BindClusterFlags(clusterInfo *clientcmdapi.Cluster, flags *pflag.FlagSet, flagNames ClusterOverrideFlags) { flagNames.APIServer.BindStringFlag(flags, &clusterInfo.Server) - // TODO: remove --api-version flag in 1.3. - flagNames.APIVersion.BindStringFlag(flags, &clusterInfo.APIVersion) - flags.MarkDeprecated(FlagAPIVersion, "flag is no longer respected and will be deleted in the next release") flagNames.CertificateAuthority.BindStringFlag(flags, &clusterInfo.CertificateAuthority) flagNames.InsecureSkipTLSVerify.BindBoolFlag(flags, &clusterInfo.InsecureSkipTLSVerify) } -// BindOverrideFlags is a convenience method to bind the specified flags to their associated variables -func BindOverrideFlags(overrides *ConfigOverrides, flags *pflag.FlagSet, flagNames ConfigOverrideFlags) { - BindAuthInfoFlags(&overrides.AuthInfo, flags, flagNames.AuthOverrideFlags) - BindClusterFlags(&overrides.ClusterInfo, flags, flagNames.ClusterOverrideFlags) - BindContextFlags(&overrides.Context, flags, flagNames.ContextOverrideFlags) - flagNames.CurrentContext.BindStringFlag(flags, &overrides.CurrentContext) - flagNames.Timeout.BindStringFlag(flags, &overrides.Timeout) -} - // BindFlags is a convenience method to bind the specified flags to their associated variables func BindContextFlags(contextInfo *clientcmdapi.Context, flags *pflag.FlagSet, flagNames ContextOverrideFlags) { flagNames.ClusterName.BindStringFlag(flags, &contextInfo.Cluster) diff --git a/vendor/k8s.io/client-go/tools/clientcmd/validation.go b/vendor/k8s.io/client-go/tools/clientcmd/validation.go index 284245e96d..2bae0c395d 100644 --- a/vendor/k8s.io/client-go/tools/clientcmd/validation.go +++ b/vendor/k8s.io/client-go/tools/clientcmd/validation.go @@ -23,8 +23,8 @@ import ( "reflect" "strings" - utilerrors "k8s.io/client-go/pkg/util/errors" - "k8s.io/client-go/pkg/util/validation" + utilerrors "k8s.io/apimachinery/pkg/util/errors" + "k8s.io/apimachinery/pkg/util/validation" clientcmdapi "k8s.io/client-go/tools/clientcmd/api" ) @@ -167,7 +167,8 @@ func ConfirmUsable(config clientcmdapi.Config, passedContextName string) error { func validateClusterInfo(clusterName string, clusterInfo clientcmdapi.Cluster) []error { validationErrors := make([]error, 0) - if reflect.DeepEqual(clientcmdapi.Cluster{}, clusterInfo) { + emptyCluster := clientcmdapi.NewCluster() + if reflect.DeepEqual(*emptyCluster, clusterInfo) { return []error{ErrEmptyCluster} } @@ -241,6 +242,10 @@ func validateAuthInfo(authInfoName string, authInfo clientcmdapi.AuthInfo) []err validationErrors = append(validationErrors, fmt.Errorf("more than one authentication method found for %v; found %v, only one is allowed", authInfoName, methods)) } + // ImpersonateGroups or ImpersonateUserExtra should be requested with a user + if (len(authInfo.ImpersonateGroups) > 0 || len(authInfo.ImpersonateUserExtra) > 0) && (len(authInfo.Impersonate) == 0) { + validationErrors = append(validationErrors, fmt.Errorf("requesting groups or user-extra for %v without impersonating a user", authInfoName)) + } return validationErrors } diff --git a/vendor/k8s.io/client-go/tools/metrics/BUILD b/vendor/k8s.io/client-go/tools/metrics/BUILD new file mode 100644 index 0000000000..9ae4546c91 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/metrics/BUILD @@ -0,0 +1,14 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["metrics.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/tools/metrics/OWNERS b/vendor/k8s.io/client-go/tools/metrics/OWNERS new file mode 100755 index 0000000000..ff51798071 --- /dev/null +++ b/vendor/k8s.io/client-go/tools/metrics/OWNERS @@ -0,0 +1,7 @@ +reviewers: +- wojtek-t +- eparis +- krousey +- jayunit100 +- fgrzadkowski +- tmrts diff --git a/vendor/k8s.io/client-go/transport/BUILD b/vendor/k8s.io/client-go/transport/BUILD new file mode 100644 index 0000000000..21ca514e07 --- /dev/null +++ b/vendor/k8s.io/client-go/transport/BUILD @@ -0,0 +1,35 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "cache_test.go", + "round_trippers_test.go", + "transport_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "cache.go", + "config.go", + "round_trippers.go", + "transport.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/golang/glog:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/net:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/transport/OWNERS b/vendor/k8s.io/client-go/transport/OWNERS new file mode 100755 index 0000000000..bf0ba5b9f9 --- /dev/null +++ b/vendor/k8s.io/client-go/transport/OWNERS @@ -0,0 +1,7 @@ +reviewers: +- smarterclayton +- wojtek-t +- deads2k +- liggitt +- krousey +- caesarxuchao diff --git a/vendor/k8s.io/client-go/transport/cache.go b/vendor/k8s.io/client-go/transport/cache.go index 6e52d771e9..8d76def345 100644 --- a/vendor/k8s.io/client-go/transport/cache.go +++ b/vendor/k8s.io/client-go/transport/cache.go @@ -23,7 +23,7 @@ import ( "sync" "time" - utilnet "k8s.io/client-go/pkg/util/net" + utilnet "k8s.io/apimachinery/pkg/util/net" ) // TlsTransportCache caches TLS http.RoundTrippers different configurations. The diff --git a/vendor/k8s.io/client-go/transport/config.go b/vendor/k8s.io/client-go/transport/config.go index 6e5c68a30b..820594ba35 100644 --- a/vendor/k8s.io/client-go/transport/config.go +++ b/vendor/k8s.io/client-go/transport/config.go @@ -34,8 +34,8 @@ type Config struct { // Bearer token for authentication BearerToken string - // Impersonate is the username that this Config will impersonate - Impersonate string + // Impersonate is the config that this Config will impersonate using + Impersonate ImpersonationConfig // Transport may be used for custom HTTP behavior. This attribute may // not be specified with the TLS client certificate options. Use @@ -50,6 +50,16 @@ type Config struct { WrapTransport func(rt http.RoundTripper) http.RoundTripper } +// ImpersonationConfig has all the available impersonation options +type ImpersonationConfig struct { + // UserName matches user.Info.GetName() + UserName string + // Groups matches user.Info.GetGroups() + Groups []string + // Extra matches user.Info.GetExtra() + Extra map[string][]string +} + // HasCA returns whether the configuration has a certificate authority or not. func (c *Config) HasCA() bool { return len(c.TLS.CAData) > 0 || len(c.TLS.CAFile) > 0 @@ -76,7 +86,8 @@ type TLSConfig struct { CertFile string // Path of the PEM-encoded client certificate. KeyFile string // Path of the PEM-encoded client key. - Insecure bool // Server should be accessed without verifying the certificate. For testing only. + Insecure bool // Server should be accessed without verifying the certificate. For testing only. + ServerName string // Override for the server name passed to the server for SNI and used to verify certificates. CAData []byte // Bytes of the PEM-encoded server trusted root certificates. Supercedes CAFile. CertData []byte // Bytes of the PEM-encoded client certificate. Supercedes CertFile. diff --git a/vendor/k8s.io/client-go/transport/round_trippers.go b/vendor/k8s.io/client-go/transport/round_trippers.go index aadf0cbf9a..c728b18775 100644 --- a/vendor/k8s.io/client-go/transport/round_trippers.go +++ b/vendor/k8s.io/client-go/transport/round_trippers.go @@ -19,9 +19,12 @@ package transport import ( "fmt" "net/http" + "strings" "time" "github.com/golang/glog" + + utilnet "k8s.io/apimachinery/pkg/util/net" ) // HTTPWrappersForConfig wraps a round tripper with any relevant layered @@ -48,7 +51,9 @@ func HTTPWrappersForConfig(config *Config, rt http.RoundTripper) (http.RoundTrip if len(config.UserAgent) > 0 { rt = NewUserAgentRoundTripper(config.UserAgent, rt) } - if len(config.Impersonate) > 0 { + if len(config.Impersonate.UserName) > 0 || + len(config.Impersonate.Groups) > 0 || + len(config.Impersonate.Extra) > 0 { rt = NewImpersonatingRoundTripper(config.Impersonate, rt) } return rt, nil @@ -74,6 +79,71 @@ type requestCanceler interface { CancelRequest(*http.Request) } +type authProxyRoundTripper struct { + username string + groups []string + extra map[string][]string + + rt http.RoundTripper +} + +// NewAuthProxyRoundTripper provides a roundtripper which will add auth proxy fields to requests for +// authentication terminating proxy cases +// assuming you pull the user from the context: +// username is the user.Info.GetName() of the user +// groups is the user.Info.GetGroups() of the user +// extra is the user.Info.GetExtra() of the user +// extra can contain any additional information that the authenticator +// thought was interesting, for example authorization scopes. +// In order to faithfully round-trip through an impersonation flow, these keys +// MUST be lowercase. +func NewAuthProxyRoundTripper(username string, groups []string, extra map[string][]string, rt http.RoundTripper) http.RoundTripper { + return &authProxyRoundTripper{ + username: username, + groups: groups, + extra: extra, + rt: rt, + } +} + +func (rt *authProxyRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) { + req = utilnet.CloneRequest(req) + SetAuthProxyHeaders(req, rt.username, rt.groups, rt.extra) + + return rt.rt.RoundTrip(req) +} + +// SetAuthProxyHeaders stomps the auth proxy header fields. It mutates its argument. +func SetAuthProxyHeaders(req *http.Request, username string, groups []string, extra map[string][]string) { + req.Header.Del("X-Remote-User") + req.Header.Del("X-Remote-Group") + for key := range req.Header { + if strings.HasPrefix(strings.ToLower(key), strings.ToLower("X-Remote-Extra-")) { + req.Header.Del(key) + } + } + + req.Header.Set("X-Remote-User", username) + for _, group := range groups { + req.Header.Add("X-Remote-Group", group) + } + for key, values := range extra { + for _, value := range values { + req.Header.Add("X-Remote-Extra-"+key, value) + } + } +} + +func (rt *authProxyRoundTripper) CancelRequest(req *http.Request) { + if canceler, ok := rt.rt.(requestCanceler); ok { + canceler.CancelRequest(req) + } else { + glog.Errorf("CancelRequest not implemented") + } +} + +func (rt *authProxyRoundTripper) WrappedRoundTripper() http.RoundTripper { return rt.rt } + type userAgentRoundTripper struct { agent string rt http.RoundTripper @@ -87,7 +157,7 @@ func (rt *userAgentRoundTripper) RoundTrip(req *http.Request) (*http.Response, e if len(req.Header.Get("User-Agent")) != 0 { return rt.rt.RoundTrip(req) } - req = cloneRequest(req) + req = utilnet.CloneRequest(req) req.Header.Set("User-Agent", rt.agent) return rt.rt.RoundTrip(req) } @@ -118,7 +188,7 @@ func (rt *basicAuthRoundTripper) RoundTrip(req *http.Request) (*http.Response, e if len(req.Header.Get("Authorization")) != 0 { return rt.rt.RoundTrip(req) } - req = cloneRequest(req) + req = utilnet.CloneRequest(req) req.SetBasicAuth(rt.username, rt.password) return rt.rt.RoundTrip(req) } @@ -133,22 +203,53 @@ func (rt *basicAuthRoundTripper) CancelRequest(req *http.Request) { func (rt *basicAuthRoundTripper) WrappedRoundTripper() http.RoundTripper { return rt.rt } +// These correspond to the headers used in pkg/apis/authentication. We don't want the package dependency, +// but you must not change the values. +const ( + // ImpersonateUserHeader is used to impersonate a particular user during an API server request + ImpersonateUserHeader = "Impersonate-User" + + // ImpersonateGroupHeader is used to impersonate a particular group during an API server request. + // It can be repeated multiplied times for multiple groups. + ImpersonateGroupHeader = "Impersonate-Group" + + // ImpersonateUserExtraHeaderPrefix is a prefix for a header used to impersonate an entry in the + // extra map[string][]string for user.Info. The key for the `extra` map is suffix. + // The same key can be repeated multiple times to have multiple elements in the slice under a single key. + // For instance: + // Impersonate-Extra-Foo: one + // Impersonate-Extra-Foo: two + // results in extra["Foo"] = []string{"one", "two"} + ImpersonateUserExtraHeaderPrefix = "Impersonate-Extra-" +) + type impersonatingRoundTripper struct { - impersonate string + impersonate ImpersonationConfig delegate http.RoundTripper } // NewImpersonatingRoundTripper will add an Act-As header to a request unless it has already been set. -func NewImpersonatingRoundTripper(impersonate string, delegate http.RoundTripper) http.RoundTripper { +func NewImpersonatingRoundTripper(impersonate ImpersonationConfig, delegate http.RoundTripper) http.RoundTripper { return &impersonatingRoundTripper{impersonate, delegate} } func (rt *impersonatingRoundTripper) RoundTrip(req *http.Request) (*http.Response, error) { - if len(req.Header.Get("Impersonate-User")) != 0 { + // use the user header as marker for the rest. + if len(req.Header.Get(ImpersonateUserHeader)) != 0 { return rt.delegate.RoundTrip(req) } - req = cloneRequest(req) - req.Header.Set("Impersonate-User", rt.impersonate) + req = utilnet.CloneRequest(req) + req.Header.Set(ImpersonateUserHeader, rt.impersonate.UserName) + + for _, group := range rt.impersonate.Groups { + req.Header.Add(ImpersonateGroupHeader, group) + } + for k, vv := range rt.impersonate.Extra { + for _, v := range vv { + req.Header.Add(ImpersonateUserExtraHeaderPrefix+k, v) + } + } + return rt.delegate.RoundTrip(req) } @@ -178,7 +279,7 @@ func (rt *bearerAuthRoundTripper) RoundTrip(req *http.Request) (*http.Response, return rt.rt.RoundTrip(req) } - req = cloneRequest(req) + req = utilnet.CloneRequest(req) req.Header.Set("Authorization", fmt.Sprintf("Bearer %s", rt.bearer)) return rt.rt.RoundTrip(req) } @@ -193,20 +294,6 @@ func (rt *bearerAuthRoundTripper) CancelRequest(req *http.Request) { func (rt *bearerAuthRoundTripper) WrappedRoundTripper() http.RoundTripper { return rt.rt } -// cloneRequest returns a clone of the provided *http.Request. -// The clone is a shallow copy of the struct and its Header map. -func cloneRequest(r *http.Request) *http.Request { - // shallow copy of the struct - r2 := new(http.Request) - *r2 = *r - // deep copy of the Header - r2.Header = make(http.Header) - for k, s := range r.Header { - r2.Header[k] = s - } - return r2 -} - // requestInfo keeps track of information about a request/response combination type requestInfo struct { RequestHeaders http.Header diff --git a/vendor/k8s.io/client-go/transport/transport.go b/vendor/k8s.io/client-go/transport/transport.go index 9c5b9ef3c3..15be0a3e6b 100644 --- a/vendor/k8s.io/client-go/transport/transport.go +++ b/vendor/k8s.io/client-go/transport/transport.go @@ -68,6 +68,7 @@ func TLSConfigFor(c *Config) (*tls.Config, error) { // Can't use TLSv1.1 because of RC4 cipher usage MinVersion: tls.VersionTLS12, InsecureSkipVerify: c.TLS.Insecure, + ServerName: c.TLS.ServerName, } if c.HasCA() { diff --git a/vendor/k8s.io/client-go/util/cert/BUILD b/vendor/k8s.io/client-go/util/cert/BUILD new file mode 100644 index 0000000000..2ae5eed7df --- /dev/null +++ b/vendor/k8s.io/client-go/util/cert/BUILD @@ -0,0 +1,30 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["csr_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = [ + "cert.go", + "csr.go", + "io.go", + "pem.go", + ], + data = [ + "testdata/dontUseThisKey.pem", + ], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/cert/cert.go b/vendor/k8s.io/client-go/util/cert/cert.go similarity index 91% rename from vendor/k8s.io/client-go/pkg/util/cert/cert.go rename to vendor/k8s.io/client-go/util/cert/cert.go index fff5b38d63..6854d4152f 100644 --- a/vendor/k8s.io/client-go/pkg/util/cert/cert.go +++ b/vendor/k8s.io/client-go/util/cert/cert.go @@ -25,6 +25,7 @@ import ( "crypto/x509" "crypto/x509/pkix" "encoding/pem" + "errors" "fmt" "math" "math/big" @@ -42,6 +43,7 @@ type Config struct { CommonName string Organization []string AltNames AltNames + Usages []x509.ExtKeyUsage } // AltNames contains the domain names and IP addresses that will be added @@ -86,11 +88,17 @@ func NewSignedCert(cfg Config, key *rsa.PrivateKey, caCert *x509.Certificate, ca if err != nil { return nil, err } + if len(cfg.CommonName) == 0 { + return nil, errors.New("must specify a CommonName") + } + if len(cfg.Usages) == 0 { + return nil, errors.New("must specify at least one ExtKeyUsage") + } certTmpl := x509.Certificate{ Subject: pkix.Name{ CommonName: cfg.CommonName, - Organization: caCert.Subject.Organization, + Organization: cfg.Organization, }, DNSNames: cfg.AltNames.DNSNames, IPAddresses: cfg.AltNames.IPs, @@ -98,7 +106,7 @@ func NewSignedCert(cfg Config, key *rsa.PrivateKey, caCert *x509.Certificate, ca NotBefore: caCert.NotBefore, NotAfter: time.Now().Add(duration365d).UTC(), KeyUsage: x509.KeyUsageKeyEncipherment | x509.KeyUsageDigitalSignature, - ExtKeyUsage: []x509.ExtKeyUsage{x509.ExtKeyUsageServerAuth, x509.ExtKeyUsageClientAuth}, + ExtKeyUsage: cfg.Usages, } certDERBytes, err := x509.CreateCertificate(cryptorand.Reader, &certTmpl, caCert, key.Public(), caKey) if err != nil { @@ -120,7 +128,7 @@ func MakeEllipticPrivateKeyPEM() ([]byte, error) { } privateKeyPemBlock := &pem.Block{ - Type: "EC PRIVATE KEY", + Type: ECPrivateKeyBlockType, Bytes: derBytes, } return pem.EncodeToMemory(privateKeyPemBlock), nil @@ -165,13 +173,13 @@ func GenerateSelfSignedCertKey(host string, alternateIPs []net.IP, alternateDNS // Generate cert certBuffer := bytes.Buffer{} - if err := pem.Encode(&certBuffer, &pem.Block{Type: "CERTIFICATE", Bytes: derBytes}); err != nil { + if err := pem.Encode(&certBuffer, &pem.Block{Type: CertificateBlockType, Bytes: derBytes}); err != nil { return nil, nil, err } // Generate key keyBuffer := bytes.Buffer{} - if err := pem.Encode(&keyBuffer, &pem.Block{Type: "RSA PRIVATE KEY", Bytes: x509.MarshalPKCS1PrivateKey(priv)}); err != nil { + if err := pem.Encode(&keyBuffer, &pem.Block{Type: RSAPrivateKeyBlockType, Bytes: x509.MarshalPKCS1PrivateKey(priv)}); err != nil { return nil, nil, err } diff --git a/vendor/k8s.io/client-go/pkg/util/cert/csr.go b/vendor/k8s.io/client-go/util/cert/csr.go similarity index 60% rename from vendor/k8s.io/client-go/pkg/util/cert/csr.go rename to vendor/k8s.io/client-go/util/cert/csr.go index 69846df6d3..39a6751f70 100644 --- a/vendor/k8s.io/client-go/pkg/util/cert/csr.go +++ b/vendor/k8s.io/client-go/util/cert/csr.go @@ -22,60 +22,54 @@ import ( "crypto/x509" "crypto/x509/pkix" "encoding/pem" - "errors" "net" - - "k8s.io/client-go/pkg/apis/certificates" ) -// ParseCSR extracts the CSR from the API object and decodes it. -func ParseCSR(obj *certificates.CertificateSigningRequest) (*x509.CertificateRequest, error) { - // extract PEM from request object - pemBytes := obj.Spec.Request - block, _ := pem.Decode(pemBytes) - if block == nil || block.Type != "CERTIFICATE REQUEST" { - return nil, errors.New("PEM block type must be CERTIFICATE REQUEST") +// MakeCSR generates a PEM-encoded CSR using the supplied private key, subject, and SANs. +// All key types that are implemented via crypto.Signer are supported (This includes *rsa.PrivateKey and *ecdsa.PrivateKey.) +func MakeCSR(privateKey interface{}, subject *pkix.Name, dnsSANs []string, ipSANs []net.IP) (csr []byte, err error) { + template := &x509.CertificateRequest{ + Subject: *subject, + DNSNames: dnsSANs, + IPAddresses: ipSANs, } - csr, err := x509.ParseCertificateRequest(block.Bytes) + + return MakeCSRFromTemplate(privateKey, template) +} + +// MakeCSRFromTemplate generates a PEM-encoded CSR using the supplied private +// key and certificate request as a template. All key types that are +// implemented via crypto.Signer are supported (This includes *rsa.PrivateKey +// and *ecdsa.PrivateKey.) +func MakeCSRFromTemplate(privateKey interface{}, template *x509.CertificateRequest) ([]byte, error) { + t := *template + t.SignatureAlgorithm = sigType(privateKey) + + csrDER, err := x509.CreateCertificateRequest(cryptorand.Reader, &t, privateKey) if err != nil { return nil, err } - return csr, nil + + csrPemBlock := &pem.Block{ + Type: CertificateRequestBlockType, + Bytes: csrDER, + } + + return pem.EncodeToMemory(csrPemBlock), nil } -// MakeCSR generates a PEM-encoded CSR using the supplied private key, subject, and SANs. -// All key types that are implemented via crypto.Signer are supported (This includes *rsa.PrivateKey and *ecdsa.PrivateKey.) -func MakeCSR(privateKey interface{}, subject *pkix.Name, dnsSANs []string, ipSANs []net.IP) (csr []byte, err error) { +func sigType(privateKey interface{}) x509.SignatureAlgorithm { // Customize the signature for RSA keys, depending on the key size - var sigType x509.SignatureAlgorithm if privateKey, ok := privateKey.(*rsa.PrivateKey); ok { keySize := privateKey.N.BitLen() switch { case keySize >= 4096: - sigType = x509.SHA512WithRSA + return x509.SHA512WithRSA case keySize >= 3072: - sigType = x509.SHA384WithRSA + return x509.SHA384WithRSA default: - sigType = x509.SHA256WithRSA + return x509.SHA256WithRSA } } - - template := &x509.CertificateRequest{ - Subject: *subject, - SignatureAlgorithm: sigType, - DNSNames: dnsSANs, - IPAddresses: ipSANs, - } - - csr, err = x509.CreateCertificateRequest(cryptorand.Reader, template, privateKey) - if err != nil { - return nil, err - } - - csrPemBlock := &pem.Block{ - Type: "CERTIFICATE REQUEST", - Bytes: csr, - } - - return pem.EncodeToMemory(csrPemBlock), nil + return x509.UnknownSignatureAlgorithm } diff --git a/vendor/k8s.io/client-go/pkg/util/cert/io.go b/vendor/k8s.io/client-go/util/cert/io.go similarity index 57% rename from vendor/k8s.io/client-go/pkg/util/cert/io.go rename to vendor/k8s.io/client-go/util/cert/io.go index 9a3e1622f3..b6b6903835 100644 --- a/vendor/k8s.io/client-go/pkg/util/cert/io.go +++ b/vendor/k8s.io/client-go/util/cert/io.go @@ -18,21 +18,31 @@ package cert import ( "crypto/x509" - "errors" "fmt" "io/ioutil" "os" "path/filepath" ) -// CanReadCertOrKey returns true if the certificate or key files already exists, -// otherwise returns false. -func CanReadCertOrKey(certPath, keyPath string) bool { - if canReadFile(certPath) || canReadFile(keyPath) { - return true +// CanReadCertAndKey returns true if the certificate and key files already exists, +// otherwise returns false. If lost one of cert and key, returns error. +func CanReadCertAndKey(certPath, keyPath string) (bool, error) { + certReadable := canReadFile(certPath) + keyReadable := canReadFile(keyPath) + + if certReadable == false && keyReadable == false { + return false, nil + } + + if certReadable == false { + return false, fmt.Errorf("error reading %s, certificate and key must be supplied as a pair", certPath) } - return false + if keyReadable == false { + return false, fmt.Errorf("error reading %s, certificate and key must be supplied as a pair", keyPath) + } + + return true, nil } // If the file represented by path exists and @@ -76,10 +86,31 @@ func WriteKey(keyPath string, data []byte) error { return nil } +// LoadOrGenerateKeyFile looks for a key in the file at the given path. If it +// can't find one, it will generate a new key and store it there. +func LoadOrGenerateKeyFile(keyPath string) (data []byte, wasGenerated bool, err error) { + loadedData, err := ioutil.ReadFile(keyPath) + if err == nil { + return loadedData, false, err + } + if !os.IsNotExist(err) { + return nil, false, fmt.Errorf("error loading key from %s: %v", keyPath, err) + } + + generatedData, err := MakeEllipticPrivateKeyPEM() + if err != nil { + return nil, false, fmt.Errorf("error generating key: %v", err) + } + if err := WriteKey(keyPath, generatedData); err != nil { + return nil, false, fmt.Errorf("error writing key to %s: %v", keyPath, err) + } + return generatedData, true, nil +} + // NewPool returns an x509.CertPool containing the certificates in the given PEM-encoded file. // Returns an error if the file could not be read, a certificate could not be parsed, or if the file does not contain any certificates func NewPool(filename string) (*x509.CertPool, error) { - certs, err := certsFromFile(filename) + certs, err := CertsFromFile(filename) if err != nil { return nil, err } @@ -90,12 +121,9 @@ func NewPool(filename string) (*x509.CertPool, error) { return pool, nil } -// certsFromFile returns the x509.Certificates contained in the given PEM-encoded file. +// CertsFromFile returns the x509.Certificates contained in the given PEM-encoded file. // Returns an error if the file could not be read, a certificate could not be parsed, or if the file does not contain any certificates -func certsFromFile(file string) ([]*x509.Certificate, error) { - if len(file) == 0 { - return nil, errors.New("error reading certificates from an empty filename") - } +func CertsFromFile(file string) ([]*x509.Certificate, error) { pemBlock, err := ioutil.ReadFile(file) if err != nil { return nil, err @@ -106,3 +134,17 @@ func certsFromFile(file string) ([]*x509.Certificate, error) { } return certs, nil } + +// PrivateKeyFromFile returns the private key in rsa.PrivateKey or ecdsa.PrivateKey format from a given PEM-encoded file. +// Returns an error if the file could not be read or if the private key could not be parsed. +func PrivateKeyFromFile(file string) (interface{}, error) { + pemBlock, err := ioutil.ReadFile(file) + if err != nil { + return nil, err + } + key, err := ParsePrivateKeyPEM(pemBlock) + if err != nil { + return nil, fmt.Errorf("error reading %s: %v", file, err) + } + return key, nil +} diff --git a/vendor/k8s.io/client-go/pkg/util/cert/pem.go b/vendor/k8s.io/client-go/util/cert/pem.go similarity index 56% rename from vendor/k8s.io/client-go/pkg/util/cert/pem.go rename to vendor/k8s.io/client-go/util/cert/pem.go index 59e602d2f1..899845857c 100644 --- a/vendor/k8s.io/client-go/pkg/util/cert/pem.go +++ b/vendor/k8s.io/client-go/util/cert/pem.go @@ -24,6 +24,21 @@ import ( "fmt" ) +const ( + // ECPrivateKeyBlockType is a possible value for pem.Block.Type. + ECPrivateKeyBlockType = "EC PRIVATE KEY" + // RSAPrivateKeyBlockType is a possible value for pem.Block.Type. + RSAPrivateKeyBlockType = "RSA PRIVATE KEY" + // CertificateBlockType is a possible value for pem.Block.Type. + CertificateBlockType = "CERTIFICATE" + // CertificateRequestBlockType is a possible value for pem.Block.Type. + CertificateRequestBlockType = "CERTIFICATE REQUEST" + // PrivateKeyBlockType is a possible value for pem.Block.Type. + PrivateKeyBlockType = "PRIVATE KEY" + // PublicKeyBlockType is a possible value for pem.Block.Type. + PublicKeyBlockType = "PUBLIC KEY" +) + // EncodePublicKeyPEM returns PEM-endcode public data func EncodePublicKeyPEM(key *rsa.PublicKey) ([]byte, error) { der, err := x509.MarshalPKIXPublicKey(key) @@ -31,7 +46,7 @@ func EncodePublicKeyPEM(key *rsa.PublicKey) ([]byte, error) { return []byte{}, err } block := pem.Block{ - Type: "PUBLIC KEY", + Type: PublicKeyBlockType, Bytes: der, } return pem.EncodeToMemory(&block), nil @@ -40,7 +55,7 @@ func EncodePublicKeyPEM(key *rsa.PublicKey) ([]byte, error) { // EncodePrivateKeyPEM returns PEM-encoded private key data func EncodePrivateKeyPEM(key *rsa.PrivateKey) []byte { block := pem.Block{ - Type: "RSA PRIVATE KEY", + Type: RSAPrivateKeyBlockType, Bytes: x509.MarshalPKCS1PrivateKey(key), } return pem.EncodeToMemory(&block) @@ -49,30 +64,46 @@ func EncodePrivateKeyPEM(key *rsa.PrivateKey) []byte { // EncodeCertPEM returns PEM-endcoded certificate data func EncodeCertPEM(cert *x509.Certificate) []byte { block := pem.Block{ - Type: "CERTIFICATE", + Type: CertificateBlockType, Bytes: cert.Raw, } return pem.EncodeToMemory(&block) } // ParsePrivateKeyPEM returns a private key parsed from a PEM block in the supplied data. -// Recognizes PEM blocks for "EC PRIVATE KEY" and "RSA PRIVATE KEY" +// Recognizes PEM blocks for "EC PRIVATE KEY", "RSA PRIVATE KEY", or "PRIVATE KEY" func ParsePrivateKeyPEM(keyData []byte) (interface{}, error) { + var privateKeyPemBlock *pem.Block for { - var privateKeyPemBlock *pem.Block privateKeyPemBlock, keyData = pem.Decode(keyData) if privateKeyPemBlock == nil { - // we read all the PEM blocks and didn't recognize one - return nil, fmt.Errorf("no private key PEM block found") + break } switch privateKeyPemBlock.Type { - case "EC PRIVATE KEY": - return x509.ParseECPrivateKey(privateKeyPemBlock.Bytes) - case "RSA PRIVATE KEY": - return x509.ParsePKCS1PrivateKey(privateKeyPemBlock.Bytes) + case ECPrivateKeyBlockType: + // ECDSA Private Key in ASN.1 format + if key, err := x509.ParseECPrivateKey(privateKeyPemBlock.Bytes); err == nil { + return key, nil + } + case RSAPrivateKeyBlockType: + // RSA Private Key in PKCS#1 format + if key, err := x509.ParsePKCS1PrivateKey(privateKeyPemBlock.Bytes); err == nil { + return key, nil + } + case PrivateKeyBlockType: + // RSA or ECDSA Private Key in unencrypted PKCS#8 format + if key, err := x509.ParsePKCS8PrivateKey(privateKeyPemBlock.Bytes); err == nil { + return key, nil + } } + + // tolerate non-key PEM blocks for compatibility with things like "EC PARAMETERS" blocks + // originally, only the first PEM block was parsed and expected to be a key block } + + // we read all the PEM blocks and didn't recognize one + return nil, fmt.Errorf("data does not contain a valid RSA or ECDSA private key") } // ParseCertsPEM returns the x509.Certificates contained in the given PEM-encoded byte array @@ -87,7 +118,7 @@ func ParseCertsPEM(pemCerts []byte) ([]*x509.Certificate, error) { break } // Only use PEM "CERTIFICATE" blocks without extra headers - if block.Type != "CERTIFICATE" || len(block.Headers) != 0 { + if block.Type != CertificateBlockType || len(block.Headers) != 0 { continue } diff --git a/vendor/k8s.io/client-go/util/flowcontrol/BUILD b/vendor/k8s.io/client-go/util/flowcontrol/BUILD new file mode 100644 index 0000000000..8b8a385199 --- /dev/null +++ b/vendor/k8s.io/client-go/util/flowcontrol/BUILD @@ -0,0 +1,34 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = [ + "backoff_test.go", + "throttle_test.go", + ], + library = ":go_default_library", + tags = ["automanaged"], + deps = ["//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library"], +) + +go_library( + name = "go_default_library", + srcs = [ + "backoff.go", + "throttle.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/juju/ratelimit:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/util/clock:go_default_library", + "//vendor/k8s.io/client-go/util/integer:go_default_library", + ], +) diff --git a/vendor/k8s.io/client-go/pkg/util/flowcontrol/backoff.go b/vendor/k8s.io/client-go/util/flowcontrol/backoff.go similarity index 98% rename from vendor/k8s.io/client-go/pkg/util/flowcontrol/backoff.go rename to vendor/k8s.io/client-go/util/flowcontrol/backoff.go index c3bf9582c7..71d442a62b 100644 --- a/vendor/k8s.io/client-go/pkg/util/flowcontrol/backoff.go +++ b/vendor/k8s.io/client-go/util/flowcontrol/backoff.go @@ -20,8 +20,8 @@ import ( "sync" "time" - "k8s.io/client-go/pkg/util/clock" - "k8s.io/client-go/pkg/util/integer" + "k8s.io/apimachinery/pkg/util/clock" + "k8s.io/client-go/util/integer" ) type backoffEntry struct { diff --git a/vendor/k8s.io/client-go/pkg/util/flowcontrol/throttle.go b/vendor/k8s.io/client-go/util/flowcontrol/throttle.go similarity index 84% rename from vendor/k8s.io/client-go/pkg/util/flowcontrol/throttle.go rename to vendor/k8s.io/client-go/util/flowcontrol/throttle.go index 4126d071c5..c45169c40f 100644 --- a/vendor/k8s.io/client-go/pkg/util/flowcontrol/throttle.go +++ b/vendor/k8s.io/client-go/util/flowcontrol/throttle.go @@ -19,7 +19,7 @@ package flowcontrol import ( "sync" - "k8s.io/client-go/pkg/util/ratelimit" + "github.com/juju/ratelimit" ) type RateLimiter interface { @@ -51,6 +51,22 @@ type tokenBucketRateLimiter struct { // The maximum number of tokens in the bucket is capped at 'burst'. func NewTokenBucketRateLimiter(qps float32, burst int) RateLimiter { limiter := ratelimit.NewBucketWithRate(float64(qps), int64(burst)) + return newTokenBucketRateLimiter(limiter, qps) +} + +// An injectable, mockable clock interface. +type Clock interface { + ratelimit.Clock +} + +// NewTokenBucketRateLimiterWithClock is identical to NewTokenBucketRateLimiter +// but allows an injectable clock, for testing. +func NewTokenBucketRateLimiterWithClock(qps float32, burst int, clock Clock) RateLimiter { + limiter := ratelimit.NewBucketWithRateAndClock(float64(qps), int64(burst), clock) + return newTokenBucketRateLimiter(limiter, qps) +} + +func newTokenBucketRateLimiter(limiter *ratelimit.Bucket, qps float32) RateLimiter { return &tokenBucketRateLimiter{ limiter: limiter, qps: qps, diff --git a/vendor/k8s.io/client-go/util/homedir/BUILD b/vendor/k8s.io/client-go/util/homedir/BUILD new file mode 100644 index 0000000000..aa49fefb55 --- /dev/null +++ b/vendor/k8s.io/client-go/util/homedir/BUILD @@ -0,0 +1,14 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = ["homedir.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/homedir/homedir.go b/vendor/k8s.io/client-go/util/homedir/homedir.go similarity index 87% rename from vendor/k8s.io/client-go/pkg/util/homedir/homedir.go rename to vendor/k8s.io/client-go/util/homedir/homedir.go index 403475491a..816db57f59 100644 --- a/vendor/k8s.io/client-go/pkg/util/homedir/homedir.go +++ b/vendor/k8s.io/client-go/util/homedir/homedir.go @@ -24,6 +24,13 @@ import ( // HomeDir returns the home directory for the current user func HomeDir() string { if runtime.GOOS == "windows" { + + // First prefer the HOME environmental variable + if home := os.Getenv("HOME"); len(home) > 0 { + if _, err := os.Stat(home); err == nil { + return home + } + } if homeDrive, homePath := os.Getenv("HOMEDRIVE"), os.Getenv("HOMEPATH"); len(homeDrive) > 0 && len(homePath) > 0 { homeDir := homeDrive + homePath if _, err := os.Stat(homeDir); err == nil { diff --git a/vendor/k8s.io/client-go/util/integer/BUILD b/vendor/k8s.io/client-go/util/integer/BUILD new file mode 100644 index 0000000000..631a160920 --- /dev/null +++ b/vendor/k8s.io/client-go/util/integer/BUILD @@ -0,0 +1,22 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", + "go_test", +) + +go_test( + name = "go_default_test", + srcs = ["integer_test.go"], + library = ":go_default_library", + tags = ["automanaged"], +) + +go_library( + name = "go_default_library", + srcs = ["integer.go"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/client-go/pkg/util/integer/integer.go b/vendor/k8s.io/client-go/util/integer/integer.go similarity index 100% rename from vendor/k8s.io/client-go/pkg/util/integer/integer.go rename to vendor/k8s.io/client-go/util/integer/integer.go diff --git a/vendor/github.com/coreos/go-oidc/LICENSE b/vendor/k8s.io/kubernetes/LICENSE similarity index 99% rename from vendor/github.com/coreos/go-oidc/LICENSE rename to vendor/k8s.io/kubernetes/LICENSE index e06d208186..d645695673 100644 --- a/vendor/github.com/coreos/go-oidc/LICENSE +++ b/vendor/k8s.io/kubernetes/LICENSE @@ -1,4 +1,5 @@ -Apache License + + Apache License Version 2.0, January 2004 http://www.apache.org/licenses/ @@ -178,7 +179,7 @@ Apache License APPENDIX: How to apply the Apache License to your work. To apply the Apache License to your work, attach the following - boilerplate notice, with the fields enclosed by brackets "{}" + boilerplate notice, with the fields enclosed by brackets "[]" replaced with your own identifying information. (Don't include the brackets!) The text should be enclosed in the appropriate comment syntax for the file format. We also recommend that a @@ -186,7 +187,7 @@ Apache License same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright {yyyy} {name of copyright owner} + Copyright [yyyy] [name of copyright owner] Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -199,4 +200,3 @@ Apache License 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. - diff --git a/vendor/k8s.io/kubernetes/pkg/api/unversioned/BUILD b/vendor/k8s.io/kubernetes/pkg/api/unversioned/BUILD new file mode 100644 index 0000000000..e22eba1b29 --- /dev/null +++ b/vendor/k8s.io/kubernetes/pkg/api/unversioned/BUILD @@ -0,0 +1,36 @@ +package(default_visibility = ["//visibility:public"]) + +licenses(["notice"]) + +load( + "@io_bazel_rules_go//go:def.bzl", + "go_library", +) + +go_library( + name = "go_default_library", + srcs = [ + "duration.go", + "time.go", + "types.go", + ], + tags = ["automanaged"], + deps = [ + "//vendor/github.com/go-openapi/spec:go_default_library", + "//vendor/github.com/google/gofuzz:go_default_library", + "//vendor/k8s.io/apimachinery/pkg/openapi:go_default_library", + ], +) + +filegroup( + name = "package-srcs", + srcs = glob(["**"]), + tags = ["automanaged"], + visibility = ["//visibility:private"], +) + +filegroup( + name = "all-srcs", + srcs = [":package-srcs"], + tags = ["automanaged"], +) diff --git a/vendor/k8s.io/kubernetes/pkg/api/unversioned/duration.go b/vendor/k8s.io/kubernetes/pkg/api/unversioned/duration.go new file mode 100644 index 0000000000..6b9a4371e6 --- /dev/null +++ b/vendor/k8s.io/kubernetes/pkg/api/unversioned/duration.go @@ -0,0 +1,47 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package unversioned + +import ( + "encoding/json" + "time" +) + +// Duration is a wrapper around time.Duration which supports correct +// marshaling to YAML and JSON. In particular, it marshals into strings, which +// can be used as map keys in json. +type Duration struct { + time.Duration `protobuf:"-"` +} + +// UnmarshalJSON implements the json.Unmarshaller interface. +func (d *Duration) UnmarshalJSON(b []byte) error { + var str string + json.Unmarshal(b, &str) + + pd, err := time.ParseDuration(str) + if err != nil { + return err + } + d.Duration = pd + return nil +} + +// MarshalJSON implements the json.Marshaler interface. +func (d Duration) MarshalJSON() ([]byte, error) { + return json.Marshal(d.Duration.String()) +} diff --git a/vendor/k8s.io/kubernetes/pkg/api/unversioned/time.go b/vendor/k8s.io/kubernetes/pkg/api/unversioned/time.go new file mode 100644 index 0000000000..c4244ed194 --- /dev/null +++ b/vendor/k8s.io/kubernetes/pkg/api/unversioned/time.go @@ -0,0 +1,176 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +package unversioned + +import ( + "encoding/json" + "time" + + "k8s.io/apimachinery/pkg/openapi" + + "github.com/go-openapi/spec" + "github.com/google/gofuzz" +) + +// Time is a wrapper around time.Time which supports correct +// marshaling to YAML and JSON. Wrappers are provided for many +// of the factory methods that the time package offers. +type Time struct { + time.Time `protobuf:"-"` +} + +// DeepCopy returns a deep-copy of the Time value. The underlying time.Time +// type is effectively immutable in the time API, so it is safe to +// copy-by-assign, despite the presence of (unexported) Pointer fields. +func (t Time) DeepCopy() Time { + return t +} + +// String returns the representation of the time. +func (t Time) String() string { + return t.Time.String() +} + +// NewTime returns a wrapped instance of the provided time +func NewTime(time time.Time) Time { + return Time{time} +} + +// Date returns the Time corresponding to the supplied parameters +// by wrapping time.Date. +func Date(year int, month time.Month, day, hour, min, sec, nsec int, loc *time.Location) Time { + return Time{time.Date(year, month, day, hour, min, sec, nsec, loc)} +} + +// Now returns the current local time. +func Now() Time { + return Time{time.Now()} +} + +// IsZero returns true if the value is nil or time is zero. +func (t *Time) IsZero() bool { + if t == nil { + return true + } + return t.Time.IsZero() +} + +// Before reports whether the time instant t is before u. +func (t Time) Before(u Time) bool { + return t.Time.Before(u.Time) +} + +// Equal reports whether the time instant t is equal to u. +func (t Time) Equal(u Time) bool { + return t.Time.Equal(u.Time) +} + +// Unix returns the local time corresponding to the given Unix time +// by wrapping time.Unix. +func Unix(sec int64, nsec int64) Time { + return Time{time.Unix(sec, nsec)} +} + +// Rfc3339Copy returns a copy of the Time at second-level precision. +func (t Time) Rfc3339Copy() Time { + copied, _ := time.Parse(time.RFC3339, t.Format(time.RFC3339)) + return Time{copied} +} + +// UnmarshalJSON implements the json.Unmarshaller interface. +func (t *Time) UnmarshalJSON(b []byte) error { + if len(b) == 4 && string(b) == "null" { + t.Time = time.Time{} + return nil + } + + var str string + json.Unmarshal(b, &str) + + pt, err := time.Parse(time.RFC3339, str) + if err != nil { + return err + } + + t.Time = pt.Local() + return nil +} + +// UnmarshalQueryParameter converts from a URL query parameter value to an object +func (t *Time) UnmarshalQueryParameter(str string) error { + if len(str) == 0 { + t.Time = time.Time{} + return nil + } + // Tolerate requests from older clients that used JSON serialization to build query params + if len(str) == 4 && str == "null" { + t.Time = time.Time{} + return nil + } + + pt, err := time.Parse(time.RFC3339, str) + if err != nil { + return err + } + + t.Time = pt.Local() + return nil +} + +// MarshalJSON implements the json.Marshaler interface. +func (t Time) MarshalJSON() ([]byte, error) { + if t.IsZero() { + // Encode unset/nil objects as JSON's "null". + return []byte("null"), nil + } + + return json.Marshal(t.UTC().Format(time.RFC3339)) +} + +func (_ Time) OpenAPIDefinition() openapi.OpenAPIDefinition { + return openapi.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"string"}, + Format: "date-time", + }, + }, + } +} + +// MarshalQueryParameter converts to a URL query parameter value +func (t Time) MarshalQueryParameter() (string, error) { + if t.IsZero() { + // Encode unset/nil objects as an empty string + return "", nil + } + + return t.UTC().Format(time.RFC3339), nil +} + +// Fuzz satisfies fuzz.Interface. +func (t *Time) Fuzz(c fuzz.Continue) { + if t == nil { + return + } + // Allow for about 1000 years of randomness. Leave off nanoseconds + // because JSON doesn't represent them so they can't round-trip + // properly. + t.Time = time.Unix(c.Rand.Int63n(1000*365*24*60*60), 0) +} + +var _ fuzz.Interface = &Time{} diff --git a/vendor/k8s.io/kubernetes/pkg/api/unversioned/types.go b/vendor/k8s.io/kubernetes/pkg/api/unversioned/types.go new file mode 100644 index 0000000000..61137725a6 --- /dev/null +++ b/vendor/k8s.io/kubernetes/pkg/api/unversioned/types.go @@ -0,0 +1,60 @@ +/* +Copyright 2016 The Kubernetes Authors. + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. +*/ + +// Package unversioned is deprecated and has been replaced with pkg/apis/meta/v1 +// +// DEPRECATED - Do not reference or add types to this package, it will be removed +// once Heapster is updated to use pkg/apis/meta/v1. +package unversioned + +// TypeMeta describes an individual object in an API response or request +// with strings representing the type of the object and its API schema version. +// Structures that are versioned or persisted should inline TypeMeta. +type TypeMeta struct { + // Kind is a string value representing the REST resource this object represents. + // Servers may infer this from the endpoint the client submits requests to. + // Cannot be updated. + // In CamelCase. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#types-kinds + // +optional + Kind string `json:"kind,omitempty" protobuf:"bytes,1,opt,name=kind"` + + // APIVersion defines the versioned schema of this representation of an object. + // Servers should convert recognized schemas to the latest internal value, and + // may reject unrecognized values. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#resources + // +optional + APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,2,opt,name=apiVersion"` +} + +// ListMeta describes metadata that synthetic resources must have, including lists and +// various status objects. A resource may have only one of {ObjectMeta, ListMeta}. +type ListMeta struct { + // SelfLink is a URL representing this object. + // Populated by the system. + // Read-only. + // +optional + SelfLink string `json:"selfLink,omitempty" protobuf:"bytes,1,opt,name=selfLink"` + + // String that identifies the server's internal version of this object that + // can be used by clients to determine when objects have changed. + // Value must be treated as opaque by clients and passed unmodified back to the server. + // Populated by the system. + // Read-only. + // More info: https://git.k8s.io/community/contributors/devel/api-conventions.md#concurrency-control-and-consistency + // +optional + ResourceVersion string `json:"resourceVersion,omitempty" protobuf:"bytes,2,opt,name=resourceVersion"` +}